|
Server : Apache/2.4.58 (Win64) OpenSSL/3.1.3 PHP/8.2.12 System : Windows NT SERVER-PC 10.0 build 26200 (Windows 11) AMD64 User : ServerPC ( 0) PHP Version : 8.2.12 Disable Function : NONE Directory : C:/Users/ServerPC/AppData/Local/Microsoft/Edge/User Data/Edge Shopping/2.0.6893.0/ |
Upload File : |
/*! For license information please see shopping.js.LICENSE.txt */
!function(){var e,t,i={56005:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(){(0,n.Z)(this,"timeStamp",void 0),(0,n.Z)(this,"allowed",void 0)}static GetAAConsentStorageKey(e){return"AAConsentData_"+e}}},51329:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(e){(0,n.Z)(this,"year",void 0),(0,n.Z)(this,"make",void 0),(0,n.Z)(this,"model",void 0),(0,n.Z)(this,"isValid",!1),e&&(this.make=e.make,this.model=e.model,this.year=e.year,this.isValid=void 0!==this.make&&void 0!==this.model&&void 0!==this.year)}}},66933:function(e,t,i){"use strict";var n=i(72370);class o{constructor(){(0,n.Z)(this,"commissionType",void 0),(0,n.Z)(this,"commissionValue",void 0),(0,n.Z)(this,"category",void 0),(0,n.Z)(this,"isRebatesSupportedDomain",void 0),(0,n.Z)(this,"isRebatesUser",void 0),(0,n.Z)(this,"merchantName",void 0),(0,n.Z)(this,"highestCashbackCategory",void 0)}static Create(e){const t=new o;return t.commissionType=e.highestCashbackCategory?.commissionType,t.commissionValue=e.highestCashbackCategory?.commissionValue,t.category=e.highestCashbackCategory?.category,t.isRebatesSupportedDomain=e.isRebatesSupportedDomain??null,t.isRebatesUser=e.userRebateResponse?.isRebatesUser??!1,t.merchantName=e.merchantName,t.highestCashbackCategory=e.highestCashbackCategory,t}}t.Z=o},35062:function(e,t,i){"use strict";var n=i(72370),o=i(29247),r=i(75383);class a{static Create(e){let t=JSON.parse(atob(e));const i=[],n=new Map,a=t?.[0]?.Group;if(a){let e=a;for(const i of t)if(i){const t=i.Group;if(t&&o.ZP.IsOnPage(i.PageUrl,location.pathname)){e=t;break}}t=t.map((t=>{if(t.Group===e)return t}))}for(const e of t)if(e){const t=e.Type;t&&!n.has(t)&&(i.push(t),n.set(t,new r.Z(e.PageUrl,t,e.checkoutElements)))}return{map:n,array:i}}constructor(e){if((0,n.Z)(this,"DomainName",void 0),(0,n.Z)(this,"AllcheckoutCompletionPages",void 0),(0,n.Z)(this,"AllPageTypeArr",void 0),(0,n.Z)(this,"AllCheckoutCompletionPagesStr",void 0),(0,n.Z)(this,"IsExpressCheckoutEnabled",void 0),(0,n.Z)(this,"CheckoutPageUrl",void 0),e){this.DomainName=e.domainName,this.CheckoutPageUrl=e.checkoutPageUrl,this.IsExpressCheckoutEnabled=e.isExpressCheckoutEnabled;const t=e.allCheckoutCompletionPagesStr;if(this.AllCheckoutCompletionPagesStr=t,t){const{map:e,array:i}=a.Create(t);this.AllcheckoutCompletionPages=e,this.AllPageTypeArr=i}}}}(0,n.Z)(a,"PageTypeArr",[]),t.Z=a},65902:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(e,t,i,o,r,a,s,l,c,d,u,h,p){(0,n.Z)(this,"Name",void 0),(0,n.Z)(this,"Type",void 0),(0,n.Z)(this,"Value",void 0),(0,n.Z)(this,"IsMandatory",void 0),(0,n.Z)(this,"Format",void 0),(0,n.Z)(this,"WaitForVisible",void 0),(0,n.Z)(this,"WaitForNotDisabled",void 0),(0,n.Z)(this,"WaitBefore",void 0),(0,n.Z)(this,"WaitAfter",void 0),(0,n.Z)(this,"WaitForNotVisible",void 0),(0,n.Z)(this,"NotAlwaysShown",void 0),(0,n.Z)(this,"DynamicFetch",void 0),(0,n.Z)(this,"ShouldValue",void 0),this.Name=e,this.Type=t,this.Value=i,this.IsMandatory=o,this.Format=r,this.WaitForVisible=a,this.WaitForNotDisabled=s,this.WaitBefore=l,this.WaitAfter=c,this.WaitForNotVisible=d,this.NotAlwaysShown=u,this.DynamicFetch=h,this.ShouldValue=p}}},75383:function(e,t,i){"use strict";var n=i(72370),o=i(65902);t.Z=class{constructor(e,t,i){if((0,n.Z)(this,"PageUrl",void 0),(0,n.Z)(this,"Type",void 0),(0,n.Z)(this,"CheckoutElements",void 0),this.PageUrl=e,this.Type=t,this.CheckoutElements=new Map,i)for(const e of i)if(e){const t=e.Name;let i=e.Value;t&&this.CheckoutElements.set(t,new o.Z(t,e.Type,i,e.IsMandatory,e.Format,e.WaitForVisible,e.WaitForNotDisabled,e.WaitBefore,e.WaitAfter,e.WaitForNotVisble,e.NotAlwaysShown,e.DynamicFetch,e.ShouldValue))}}}},41865:function(e,t,i){"use strict";var n=i(72370);class o{constructor(){(0,n.Z)(this,"isOffTheRecord",void 0),(0,n.Z)(this,"buildVersion",void 0)}static Create(e){const t=new o;return t.isOffTheRecord=e?.clientInfo?.isOffTheRecord??void 0,t.buildVersion=e?.clientInfo?.buildVersion,t}}t.Z=o},69886:function(e,t,i){"use strict";var n=i(72370);class o{constructor(){(0,n.Z)(this,"clipCouponSelector",void 0),(0,n.Z)(this,"signedInSelector",void 0),(0,n.Z)(this,"discountSelector",void 0),(0,n.Z)(this,"orderTotalDataElementSelector",void 0),(0,n.Z)(this,"clippedDiscountSelector",void 0),(0,n.Z)(this,"alreadyClippedSelector",void 0),(0,n.Z)(this,"waitForPageLoad",void 0),(0,n.Z)(this,"clickBeforeClipSelector",void 0),(0,n.Z)(this,"promoCodeSelector",void 0),(0,n.Z)(this,"isSalePriceNotDiscount",void 0),(0,n.Z)(this,"isSignInOptional",void 0)}static Create(e){const t=new o;return t.clipCouponSelector=e.clipCouponSelector,t.signedInSelector=e.signedInSelector,t.discountSelector=e.discountSelector,t.orderTotalDataElementSelector=e.orderTotalDataElementSelector,t.clippedDiscountSelector=e.clippedDiscountSelector,t.alreadyClippedSelector=e.alreadyClippedSelector,t.waitForPageLoad=e.waitForPageLoad,t.clickBeforeClipSelector=e.clickBeforeClipSelector,t.promoCodeSelector=e.promoCodeSelector,t.isSalePriceNotDiscount=e.isSalePriceNotDiscount,t.isSignInOptional=e.isSignInOptional,t}}t.Z=o},605:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(){(0,n.Z)(this,"attribution",void 0),(0,n.Z)(this,"couponCode",void 0),(0,n.Z)(this,"title",void 0),(0,n.Z)(this,"isLowSuccessRateCoupon",void 0),(0,n.Z)(this,"isStackable",void 0),(0,n.Z)(this,"successRate",void 0),(0,n.Z)(this,"minimumPurchase",void 0),(0,n.Z)(this,"shortHeader",void 0),(0,n.Z)(this,"calculatedCutoffPrice",void 0),(0,n.Z)(this,"discountPercent",void 0),(0,n.Z)(this,"discountValue",void 0),(0,n.Z)(this,"offerUrl",void 0),(0,n.Z)(this,"isPrivateCoupon",void 0),(0,n.Z)(this,"suggestedCouponType",void 0),(0,n.Z)(this,"isBlockedByCart",void 0),(0,n.Z)(this,"providerId",void 0)}}},4238:function(e,t,i){"use strict";i.d(t,{Z:function(){return o}});var n=i(72370);class o{constructor(e,t,i){(0,n.Z)(this,"ruleName",void 0),(0,n.Z)(this,"maskType",void 0),(0,n.Z)(this,"ruleValue",void 0),this.ruleName=e,this.maskType=t,this.ruleValue=i}}},95457:function(e,t,i){"use strict";var n=i(72370);class o{constructor(){(0,n.Z)(this,"SearchData",void 0),(0,n.Z)(this,"CategoryData",void 0),(0,n.Z)(this,"PdpData",void 0),(0,n.Z)(this,"AddedToCartData",void 0),(0,n.Z)(this,"CustomAutoShowData",void 0),(0,n.Z)(this,"categoryAutoShowCooldownInSeconds",void 0)}static Create(e){let t=new o;if(e)try{const i=atob(e);t=JSON.parse(i)}catch(e){}return t}}t.Z=o},88101:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(){(0,n.Z)(this,"name",void 0),(0,n.Z)(this,"supported",void 0),(0,n.Z)(this,"variant",void 0),(0,n.Z)(this,"multipleVariants",void 0)}}},4872:function(e,t,i){"use strict";i.d(t,{H:function(){return n}});let n=function(e){return e.sanConfirmationMessage="msShoppingExp0",e.onlineSelectorExtraction="msShoppingExp1",e.couponRedesignExperiment="msShoppingExp2",e.PCDouble="msShoppingExp3",e.PCOutOfStock="msShoppingExp4",e.blossomCampaign="msShoppingExp5",e.newNotificationManagementUI="msShoppingExp6",e.manualCoupon="msShoppingExp9",e.startShoppingRelatedProducts="msShoppingExp11",e.singleScrollingShoreline="msShoppingExp12",e.dealczarBackend="msShoppingExp13",e.sanConsent="msShoppingExp14",e.pcClickoutReverse="msShoppingExp15",e.optionalCheckoutPageUrl="msShoppingExp16",e.autosVinExtraction="msShoppingExp17",e.domMutationEnabled="msShoppingExp18",e.pdpSelectorExtraction="msShoppingExp19",e.newPriceHistoryGraph="msShoppingExp20",e.disableChatChips="msShoppingExp22",e.snoozeWithOptions="msShoppingExp23",e.searchInPane="msShoppingExp24",e.calculatedCutOffPriceFiltering="msShoppingExp25",e.pcbAddressBar="msShoppingExp29",e.checkoutSkuCashbackEstimation="msShoppingExp31",e.spbInstantAutoActivate="msShoppingExp33",e.productTracking="msShoppingExp34",e.spbAutoDismissTreatment="msShoppingExp35",e.suggestedCouponEnhancement="msShoppingExp36",e.autosApi="msShoppingExp37",e.pcboutofflownotification="msShoppingExp38",e.dynamicRanking="msShoppingExp39",e.trendingRecommendations="msShoppingExp40",e.groceryAnonymous="msShoppingExp41",e.spbAutoDismissControl="msShoppingExp42",e.buyingGuideMultiLine="msShoppingExp43",e.spbPdpWithActivated="msShoppingExp44",e.sanConsentStringUpdate="msShoppingExp45",e.autosJatoDeals="msShoppingExp46",e.startShoppingVisualSearch="msShoppingExp47",e.spbAutoSnoozeTreatment="msShoppingExp48",e.similarOffers="msShoppingExp49",e.alertSettings="msShoppingExp50",e.shorelineinboxcoupons="msShoppingExp52",e.spbPdpCashBack="msShoppingExp53",e.intersperseNativeAds="msShoppingExp54",e.sidepaneCashback="msShoppingExp55",e.spbAutoActivationOnSearch="msShoppingExp56",e.abandonedCartTracking="msShoppingExp57",e.startShoppingMomentInTimeModule="msShoppingExp58",e.triviaIcon="msShoppingExp59",e.groceryOffersSearch="msShoppingExp60",e.spbAutoShowFlagTreatmen="msShoppingExp61",e.rewardNotification="msShoppingExp62",e.discoverShopping="msShoppingExp63",e.cpsPDPcontrolFlag="msShoppingExp64",e.spbPDPShortDesign="msShoppingExp65",e.spbCheckoutAutoActivation="msShoppingExp66",e.domMutationExpansion="msShoppingExp67",e.temporalShoppingOnDiscover="msShoppingExp68",e.computeJourneyStage="msShoppingExp69",e.footerExperiments="msShoppingExp70",e.couponsConfidence="msShoppingExp71",e.ProductBestCouponConsent="msShoppingExp72",e.lowCouponExpectationExpansion="msShoppingExp73",e.spbExpiryMicroNotif="msShoppingExp74",e.spbShortNotification="msShoppingExp75",e.chatChipsOrder3="msShoppingExp76",e.spbHomePage="msShoppingExp77",e.enrollToRebateBonus="msShoppingExp78",e.instantAddToCart="msShoppingExp79",e.autoActivateInstantAtc="msShoppingExp80",e.buyingOptionsExperiment="msShoppingExp81",e.searchFeature="msShoppingExp99",e.sustainability="msShoppingExp100",e.startShoppingCategoryAds="msShoppingExp101",e.startShoppingNativeAds="msShoppingExp110",e.incentiveCampaign="msShoppingExp10000",e.pcEMI="msEdgeShoppingExp2000",e.autoOpenControllerScript="msEdgeShoppingAutoOpenControllerScript",e.autoOpenControllerMask="msEdgeShoppingServerSideAutoShow",e.autofillAutoPopup="msAutofillAutoPopup",e.bgaaService="msEdgeShoppingBackgroundAutoApply",e.bgaaUx="msEdgeShoppingBgaaUx",e.bgaaCheckoutOld="msEdgeShoppingAutoShowBackgroundAutoApply",e.bgaaNonCheckoutOld="msEdgeShoppingBackgroundAutoApplyForPDPAndHomePage",e.bannerShowCoupons="msEdgeShoppingBannerCoupons",e.categoryDeals="msEdgeShoppingPwiloNotificationsCategoryDeals",e.clarity="msEdgeShoppingClarityEnabled",e.clarityWithCookies="msEdgeShoppingClarityEnabledWithCookies",e.clientUrlNavigation="msEdgeShoppingClientUrlNavigation",e.coloredHeader="msShoppingColoredHeader",e.expressCheckout="msEdgeShoppingExpressCheckout",e.expressCheckoutFillDetails="msEdgeShoppingExpressCheckoutFillDetails",e.injectConfirmationScriptUponPurchaseCompletion="msEdgeShoppingAllowInjectConfirmationScriptNextNavigation",e.microNotification="msEdgeShoppingNotifications",e.rebatesSsoFlow="msEdgeShoppingRebatesV2Enroll",e.msWalletBNPL="msWalletBNPL",e.muidNotifications="msEdgeShoppingPwiloNotifications",e.myShopping="msEdgeShoppingMyShopping",e.pcBannerUXExperimentation1="msEdgeShoppingPCBannerUXExperimentation1",e.pcBannerUXExperimentation2="msEdgeShoppingPCBannerUXExperimentation2",e.pcBannerUXExperimentation3="msEdgeShoppingPCBannerUXExperimentation3",e.pcBannerUXExperimentation4="msEdgeShoppingPCBannerUXExperimentation4",e.pcBannerUXExperimentation5="msEdgeShoppingPCBannerUXExperimentation5",e.pcBannerUXExperimentation6="msEdgeShoppingPCBannerUXExperimentation6",e.priceDropNotification="msEdgeShoppingServerNotifications",e.pwiloOnOpenProcessing="msEdgeShoppingPwiloNotificationsOnOpenProcess",e.rewardFlyout="msEdgeShoppingRewards",e.showAmazonOtherSellers="msEdgeShoppingOtherSeller",e.showNudgeTipsOverlay="msShoppingExpNudge",e.showPaymentOptions="msZipPayVirtualCard",e.showPaymentOptionsOnProductPage="msEdgeShoppingProductFlyoutWallet",e.showProductHistory="msWebAssistQuery",e.showWalletFooter="msEnableWallet",e.signinRebates="msEdgeShoppingRebatesSignUp",e.snoozeAutoshow="msEdgeShoppingAutoShowMuteForFeature",e.socialCoupons="msEdgeShoppingExclusiveCoupons",e.socialCouponsAutoShow="msEdgeShoppingExclusiveCouponsAutoShow",e.rebatesOrganicNew="msEdgeShoppingRebatesAutoShowNewUser",e.paneOpenWithTab1="msEdgeShoppingMainTab1",e.paneOpenWithTab2="msEdgeShoppingMainTab2",e.paneOpenWithTab3="msEdgeShoppingMainTab3",e.axShopping="msEnableAXShoppingNavigation",e.shoppingOnDiscover="msEdgeShoppingOnDiscover",e.pcOfferLevel="msShoppingAutoShowPriceComparisonOfferLevel",e.discoverPdpTopPriority="msDiscoverPdpTopPriority",e.limitPdpNotificationsOnLowStages="msLimitPdpNotificationsOnLowStages",e.clientRequests="msEdgeShoppingGenericDealsService",e.shoppingCohorts="msEdgeShoppingCohorts",e.shoppingCohortsReclaimed="msEdgeShoppingCohortsReclaimed",e.shoppingCohortsVulnerable="msEdgeShoppingCohortsVulnerable",e.shoppingSettingsInPane="msEdgeShoppingSettingsInPane",e.shoppingSettingsInPaneNotificationBottomToggle="msEdgeShoppingSettingsInPaneNotificationBottomToggle",e.edgeShoppingRebatesForAADAccounts="msEdgeShoppingRebatesForAADAccounts",e.shoppingCjkProductUpsell="msEdgeShoppingCJKProductUpsell",e.pcAutoshowAvailable="msEdgeShoppingAutoShowPriceComparisonAvailable",e.travel1="msEdgeShoppingTravel1",e.travel2="msEdgeShoppingTravel2",e.travel3="msEdgeShoppingTravel3",e.travel4="msEdgeShoppingTravel4",e.travel5="msEdgeShoppingTravel5",e.travel6="msEdgeShoppingTravel6",e.settingsPaneNavigateFromFlyout="msEdgeShoppingSettingsInPaneNavigationFromFlyout",e.udaPriceComparison="msShoppingUapiExp41",e.autoApplyRewards="msEdgeShoppingAutoApplyRewards",e.cashbackActivationOmnibar="msEdgeShoppingCashbackActivationFromOmnibar",e.CashbackDashboard="edgeServerUX.shopping.cashbackDashboardEnabled",e.CouponsPersonalization="edgeServerUX.shopping.couponsPersonalization",e.PhPersonalization="edgeServerUX.shopping.phPersonalization",e.CashbackPersonalization="edgeServerUX.shopping.cashbackPersonalization",e.cashBackDelayedEnrollmentEdgeFlow="edgeServerUX.shopping.cashBackDelayedEnrollmentEdgeFlow",e.cashbackDismissTimeout="edgeServerUX.shopping.msEdgeShoppingCashbackDismissTimeout2s",e.CouponMessageFiltering="edgeServerUX.shopping.couponMessageFiltering",e.ShoppingTrips="edgeServerUX.shopping.shoppingTrips",e.ServerSideSearchInPane="edgeServerUX.shopping.searchInPane",e.campaign="edgeServerUX.shopping.campaign",e.wishlistModule="edgeServerUX.shopping.wishlistModule",e.campaignAwareness="edgeServerUX.shopping.campaignAwareness",e.cbAnimationVar1="edgeServerUX.shopping.cbAnimationVar1",e.cbAnimationVar4="edgeServerUX.shopping.cbAnimationVar4",e.compositeNotificationsPriceHistoryPlusCoupons="edgeServerUX.shopping.compositeNotificationsPriceHistoryPlusCoupons",e.compositeNotificationsPriceHistoryPlusCouponsV2="edgeServerUX.shopping.compositeNotificationsPriceHistoryPlusCouponsV2",e.cashbackPdpPlusCouponsNotification="edgeServerUX.shopping.compositeNotificationsCashbackPdpPlusCoupons",e.cashbackPdpPlusCouponsNotificationV2="edgeServerUX.shopping.compositeNotificationsV2UX",e.cashbackPdpPlusPriceDropNotification="edgeServerUX.shopping.compositeNotificationsPriceHistoryPlusCashback",e.cashbackPdpPlusPriceDropNotificationV2="edgeServerUX.shopping.compositeNotificationsPriceHistoryPlusCashbackV2",e.lowerPricePdpPlusCashbackPlusCoupons="edgeServerUX.shopping.compositeNotificationsLowerPricePdpPlusCashbackPlusCoupons",e.lowerPricePdpPlusCashbackPlusCouponsV2="edgeServerUX.shopping.compositeNotificationsLowerPricePdpPlusCashbackPlusCouponsV2",e.acTrackingToggle="edgeServerUX.shopping.acTrackingToggle",e.ptConciseUi="edgeServerUX.shopping.ptConciseUi",e.BingL2BRQ="edgeServerUX.shopping.BingL2BRQ",e.SeeAllClickout="edgeServerUX.shopping.SeeAllClickout",e.cartExtractionFromBody="edgeServerUX.shopping.cartExtractionFromBody",e.checkoutPageTypeCheck="edgeServerUX.shopping.checkoutPageTypeCheck",e.PTRecentVwd="edgeServerUX.shopping.PTRecentVwd",e.autosMyGarageEntryPoint="edgeServerUX.shopping.autosMyGarageEntryPoint",e.autosMyGarageEntryPointV2="edgeServerUX.shopping.autosMyGarageEntryPointV2",e.autosMarketValueV2="edgeServerUX.shopping.autosMarketValueV2",e.spbAddToCart="edgeServerUX.shopping.addToCartVariation",e.couponRedesignCompressed="edgeServerUX.shopping.couponRedesignCompressed",e.couponRedesignExpanded="edgeServerUX.shopping.couponRedesignExpanded",e.lostUsersCashBack="edgeServerUX.shopping.lostUsersCashback",e.lostUsersCouponClipping="edgeServerUX.shopping.lostUsersCouponClipping",e.lostUsersPriceComparison="edgeServerUX.shopping.lostUsersPriceComparison",e.lostUsersPriceComparisonRegular="edgeServerUX.shopping.lostUsersPriceComparisonRegular",e.inboxSavings="edgeServerUX.shopping.inboxSavings",e.rakutenJPClipping="edgeServerUX.shopping.rakutenJP",e.clippingV2="edgeServerUX.shopping.clippingV2",e.CouponsPipelineV2="shopping.couponsV2Pipeline",e.PTOutOfStockVariations="edgeServerUX.shopping.PTOutOfStockVariations",e.spbSearchAutoActivation="edgeServerUX.shopping.spbSearchAutoActivation",e.postPurchaseTracking="edgeServerUX.shopping.postPurchaseTracking",e.PTEmail="edgeServerUX.shopping.ptEmailConsent",e.pdpStorewideCashbackEstimation="edgeServerUX.shopping.pdpStorewideCashbackEstimation",e.blockLowPerformanceNotifications="edgeServerUX.shopping.blockLowPerformanceNotifications",e.instantAddToCartExperiment="edgeServerUX.shopping.InstantATC",e.pcbAmazonSearch="edgeServerUX.shopping.pcbAmazonSearch",e.suppressAutoApply="edgeServerUX.shopping.suppressAutoApply",e.cbSplitModules="edgeServerUX.shopping.SeparateCashBackModules",e.inboxCouponsAAFailureUpsell="edgeServerUX.shopping.inboxCouponsAAFailureUpsell",e.inboxCouponsAASuccessUpsell="edgeServerUX.shopping.inboxCouponsAASuccessUpsell",e.mobileCashbackModule="edgeServerUX.shopping.mobileCashbackModule",e.mobileProductModules="edgeServerUX.shopping.mobileProductModules",e.suppressAAAutoApplyThreshold="edgeServerUX.shopping.AAAutoApplyFailureThreshold",e.suppressAADomainSuccessThreshold="edgeServerUX.shopping.AADomainSuccessThreshold",e.ptCouponsCashbackNotification="edgeServerUX.shoppping.ptCouponsCashbackNotification",e.journeyStageTelemetry="edgeServerUX.shopping.journeyStageTelemetry",e.revampedPriceComparison="edgeServerUX.shopping.revampedPriceComparison",e.qtCartPageAutoActivation="edgeServerUX.shopping.qtAutoActivation",e.discoverChatChips="edgeServerUX.shopping.discoverChatChips",e.discoverNotification="edgeServerUX.shopping.discoverNotification",e.discoverNotification50="edgeServerUX.shopping.discoverNotification50",e.discoverNotification100="edgeServerUX.shopping.discoverNotification100",e.discoverNotification500="edgeServerUX.shopping.discoverNotification500",e.travelCheaperFlights="edgeServerUX.shopping.travelCheaperFlights",e.travelCheaperFlightsListView="edgeServerUX.shopping.travelCheaperFlightsListView",e.travelExecuteAutoOpenService="edgeServerUX.shopping.travelExecuteAutoOpenService",e.travelIsHotelExperimentActive="edgeServerUX.shopping.travelIsHotelExperimentActive",e.travelRenderCheaperFlightsNotification="edgeServerUX.shopping.travelRenderCheaperFlightsNotification",e.travelForceMarket="edgeServerUX.shopping.travelForceMarket",e.travelCheaperFlightsModule="edgeServerUX.shopping.travelCheaperFlightsModule",e.travelRenderCheaperHotelsNotification="edgeServerUX.shopping.travelRenderCheaperHotelsNotification",e.pageDetection="edgeServerUX.shopping.pageDetection",e.disableJourneyStageComputation="edgeServerUX.shopping.disableJourneyStageComputation",e.userInsights="edgeServerUX.shopping.userInsights",e.expertInsights="edgeServerUX.shopping.expertInsights",e.communityInsightsPH="edgeServerUX.shopping.communityInsightsPH",e.communityInsightsPC="edgeServerUX.shopping.communityInsightsPC",e.communityInsightsCB="edgeServerUX.shopping.communityInsightsCB",e.ptAbandonedCartNotificationToggle="edgeServerUX.shopping.ptAbandonedCartNotificationToggle",e.productSummaryCardEnabled="edgeServerUX.shopping.productSummaryCardTestExp99",e.productSummaryCardEnabledSticky="edgeServerUX.shopping.productSummaryCardStickyTestExp99",e.productSummaryInsights="edgeServerUX.shopping.productSummaryInsightsInShoppingPane",e.cbMerchantAbTesting="edgeServerUX.shopping.merchantAbTesting",e.cbMerchantAbTestingControl="edgeServerUX.shopping.merchantAbTestingCf",e.showSpbOffersOnShorelineOpen="edgeServerUX.shopping.showSpbOffersOnShorelineOpen",e.showSpbOffersOnShorelineOpenV2="edgeServerUX.shopping.showSpbOffersOnShorelineOpenV2",e.aaNoDontShowAgain="edgeServerUX.shopping.aaNoDontShowAgain",e.aaEarlyReturn="edgeServerUX.shopping.aaEarlyReturn",e.articlesCashbackNotification="edgeServerUX.shopping.artCashNotif",e.suppressLowCTR="edgeServerUX.shopping.suppressLowCTR",e.couponBackgroundDarkCode="edgeServerUX.shopping.couponBackgroundDarkCode",e.couponBackgroundLightCode="edgeServerUX.shopping.couponBackgroundLightCode",e.couponLightCode="edgeServerUX.shopping.couponLightCode",e.couponDarkCode="edgeServerUX.shopping.couponDarkCode",e.cashbackEUMarkets="edgeServerUX.shopping.cashbackEUMarkets",e.autoSuppressNegativeBGAA="edgeServerUX.shopping.autoSupperssNegativeBGAA",e.bgaaNoSnoozeTime="edgeServerUX.shopping.bgaaNoSnoozeTime",e.newHeader="edgeServerUX.shopping.newHeader",e.loggingThrottle="edgeServerUX.shopping.loggingThrottle",e.sellerIconCovIncr="edgeServerUX.shopping.sellerIconCovIncr",e.pcSeeMore="edgeServerUX.shopping.pcSeeMore",e.priceCompareV2="edgeServerUX.shopping.priceCompareV2",e.pcNotificationCashbackV2="edgeServerUX.shopping.pcNotifCbV2",e.couponValidityFix="edgeServerUX.shopping.couponValidityFix",e.domMutationReverseFlight="domMutationReverseFlight",e.fragmentPageTypeFiltering="edgeServerUX.shopping.fragmentPageTypeFiltering",e.cashbackConsolidationExp="edgeServerUX.shopping.cashbackRefactor_v4",e.collectAllFragments="edgeServerUX.shopping.collectAllFragments",e.disablePageTypeCollectionForFragments="edgeServerUX.shopping.disablePageTypeCollectionForFragments",e.smartDebounce="edgeServerUX.shopping.smartDebounceEnabled",e.suppressedCoupons="edgeServerUX.shopping.suppressedCoupons",e.autoShowNotificationForAmazonWarehouseSellers="edgeServerUX.shopping.AutoShowNotificationAmazonWarehouseSeller",e.pcAutoshowExpanded="edgeServerUX.shopping.pcAutoshowExpanded",e.pcNotificationButtonText="edgeServerUX.shopping.pcNotificationButtonText",e.pcCloseSnooze="edgeServerUX.shopping.pcCloseSnooze",e.cashbackCloseSnooze="edgeServerUX.shopping.cashbackCloseSnooze",e.phCloseSnooze="edgeServerUX.shopping.phCloseSnooze",e.clipCloseSnooze="edgeServerUX.shopping.clipCloseSnooze",e.aaCloseSnooze="edgeServerUX.shopping.aaCloseSnooze",e.autosCloseSnooze="edgeServerUX.shopping.autosCloseSnooze",e.disableNotificationForSimilarSellers="edgeServerUX.shopping.DisableNotificationSimilarSeller",e.disableCashbackOrganicNotification="edgeServerUX.shopping.disableCashbackOrganicNotification",e.disableSPBNotification="edgeServerUX.shopping.disableSPBNotification",e.spbOffersSearch="edgeServerUX.shopping.authoShowSpbT",e.shorelineUAPIBackfill="edgeServerUX.shopping.shorelineUAPIBackfill",e.spbDismissTimeout="edgeServerUX.shopping.spbDismissTimeout",e.spbCloseSnooze="edgeServerUX.shopping.spbCloseSnooze",e.purchaseExtractionRefactor="edgeServerUX.shopping.purchaseExtractionRefactor",e.fixCartUpdate="edgeServerUX.shopping.fixCartUpdate",e.buyingOptions="edgeServerUX.shopping.buyingOptions",e.ptOutOfStock="edgeServerUX.shopping.ptOutOfStock",e.loadingSpinnerWithTimeout="edgeServerUX.shopping.loadingSpinnerWithTimeout",e.pcbStorewideUXDesignChange="edgeServerUX.shopping.pcbStorewideUXDesignChangev3",e.personalizePromotionNewUser="edgeServerUX.shopping.ppNewUser",e.pdpRerank="edgeServerUX.shopping.pdpRerank",e.ptNotifications="edgeServerUX.shopping.ptNotifications",e.improvedCartModelCouponHandling="edgeServerUX.shopping.improvedCartModelCouponHandling",e.sendCouponsToCartModel="edgeServerUX.shopping.sendCouponsToCartModel",e.onlyShowAANotificationWithEligibleCoupons="edgeServerUX.shopping.onlyShowAANotificationWithEligibleCoupons",e.storewideRangeCashback="edgeServerUX.shopping.storewideRangeCashback",e.autoOpenPaneScenariosActive="edgeServerUX.shopping.autoOpenPaneScenariosActive",e.autoOpenPaneDismissTime="edgeServerUX.shopping.autoOpenPaneDismissTime",e.enablePurchaseDetectionRewardsAPI="edgeServerUX.shopping.enablePurchaseDetectionRewardsAPI",e.enableCashbackCampaignEmail="edgeServerUX.shopping.enableCashbackCampaignEmail",e.enablePostPurchaseMessage="edgeServerUX.shopping.enablePostPurchaseMessage",e}({})},31714:function(e,t,i){"use strict";i.d(t,{$T:function(){return u},AS:function(){return h},Az:function(){return r},Gc:function(){return s},K8:function(){return d},L0:function(){return g},LR:function(){return m},Nm:function(){return l},UD:function(){return n},YR:function(){return b},_K:function(){return o},cO:function(){return S},dB:function(){return p},l1:function(){return v},lA:function(){return y},nV:function(){return a},qG:function(){return f},sf:function(){return C},vr:function(){return c}});let n=function(e){return e.AS_ReRankDA="AS_ReRankDA",e.AS_FeatureOpt="AS_FeatureOpt",e.AS_DailyCache="AS_DailyCache",e}({}),o=function(e){return e.RemoveDontShowFeatureAgain="RemoveDontShowFeatureAgain",e.MenuClientTeam="MenuClientTeam",e.OnlySnooze="OnlySnooze",e}({}),r=function(e){return e.Rewards_50="Rewards50",e.Rewards_100="Rewards100",e.Rewards_200="Rewards200",e.Rewards_0="Rewards0",e}({}),a=function(e){return e.RuleBased="rule",e.ML="ml",e}({}),s=function(e){return e.Micro="mlmicro",e.Limit="mllimit",e}({}),l=function(e){return e.Micro="mlmicro",e.Limit="mllimit",e}({}),c=function(e){return e.FirstMask="msEdgeShoppingAutoShowScenariosFirstMask",e.SecondMask="msEdgeShoppingAutoShowScenariosSecondMask",e}({}),d=function(e){return e.NoAutoDismiss="NoAutoDismiss",e.AutoDismiss="AutoDismiss",e}({}),u=function(e){return e.Click="Click",e.Hover="Hover",e}({}),h=function(e){return e.Normal="normal",e.WithAnimation="withAnimation",e}({}),p=function(e){return e.Treatment="Treatment",e.Control="Control",e}({}),g=function(e){return e.Title="Title",e.OneClick="OneClick",e.TwoClick="TwoClick",e.Control="Control",e}({}),f=function(e){return e.CouponLevelThreshold="CouponLevelThreshold",e.DomainLevelThreshold="DomainLevelThreshold",e}({}),m=function(e){return e.second="second",e.third="third",e.control="control",e}({}),v=function(e){return e.CashBackActivateModule="shopCashBackActivateModule",e}({}),y=function(e){return e.ShopAt="ShopAt",e}({}),C=function(e){return e.OneClick="OneClick",e.TwoClick="TwoClick",e.Combined="Combined",e}({}),b=function(e){return e.CustomControl="CustomControl",e.Treatment="Treatment",e}({}),S=function(e){return e.BlockAccordingToPercentage="BlockAccordingToPercentage",e.NewDesign="NewDesign",e.BlockAccordingToTrackTime="BlockAccordingToTrackTime",e.DismissTimeout="DismissTimeout",e}({})},31656:function(e,t,i){"use strict";i.d(t,{R:function(){return c}});var n=i(72370),o=i(88101),r=i(4872),a=i(78938),s=i(47594),l=i(64865);const c=new class{constructor(){(0,n.Z)(this,"experiments",new Map),(0,n.Z)(this,"serviceExperiments",new Map),(0,n.Z)(this,"experimentsSet",new Set),(0,n.Z)(this,"serviceExperimentsSet",new Set),(0,n.Z)(this,"enablePCBannerUX",!1),(0,n.Z)(this,"expRawData",void 0),(0,n.Z)(this,"serviceFeatures",void 0),(0,n.Z)(this,"rawEnabledFeatures",void 0),(0,n.Z)(this,"rawEnabledServiceFeatures",void 0)}Create(e,t){this.experiments=new Map,this.serviceExperiments=new Map,this.experimentsSet=new Set,this.serviceExperimentsSet=new Set,"string"==typeof e?this.CreateFromJsonStr(e):this.CreateClientFeatures(e),t&&("string"==typeof t?this.CreateServiceFeaturesFromJsonStr(t):this.CreateServiceFeaturesFromJsonObj(t)),this.rawEnabledFeatures=e,this.rawEnabledServiceFeatures=t}GetEnabledFeaturesMap(){return this.experiments??new Map}GetExpRawData(){return this.expRawData}GetRawEnabledFeatures(){return this.rawEnabledFeatures}GetRawEnabledServiceFeatures(){return this.rawEnabledServiceFeatures}GetServiceExperiments(){return this.serviceFeatures}isExperimentActive(e){return this.experimentsSet.has(e)||this.serviceExperimentsSet.has(e)}getServiceExperimentValue(e){return this.serviceExperiments.get(e)?.value}getServiceExperimentParams(e){return this.serviceExperiments.get(e)?.params}isTestFlagActive(e){return this.experimentsSet.has(e.toString())||this.serviceExperimentsSet.has(e.toString())}setShowPCBannerUX(e,t,i,n){this.enablePCBannerUX=void 0!==e&&e||void 0!==t&&t&&void 0!==i&&i.CompetingPrices&&i.CompetingPrices.length>0&&void 0!==n&&n}isPCBannerUXExperimentActive(){return(this.experimentsSet.has(r.H.pcBannerUXExperimentation1)||this.experimentsSet.has(r.H.pcBannerUXExperimentation2)||this.experimentsSet.has(r.H.pcBannerUXExperimentation3)||this.experimentsSet.has(r.H.pcBannerUXExperimentation4)||this.experimentsSet.has(r.H.pcBannerUXExperimentation5)||this.experimentsSet.has(r.H.pcBannerUXExperimentation6))&&this.enablePCBannerUX}newFlyoutHeaderActive(){return this.experimentsSet.has(r.H.newHeader)}isVariantActive(e,t){return!!this.isExperimentActive(e)&&this.experiments.get(e)?.variant===t}isMultipleVariantActive(e,t,i){if(this.isExperimentActive(e)){const n=this.experiments.get(e);if(!n)return!1;if(n.variant===i)return!0;if(n.multipleVariants&&n.multipleVariants.length>0&&-1!==n.multipleVariants.findIndex((e=>e.key===t&&e.value===i)))return!0}return!1}getVariantValue(e,t,i){return parseInt(e.find((e=>e.key===t&&!(0,l.TF)(e.value)))?.value??i.toString(),void 0)}getVariantStringValue(e,t,i){return e.find((e=>e.key===t&&!(0,l.TF)(e.value)))?.value??i}getMultipleVariants(e){return this.isExperimentActive(e)?this.experiments.get(e)?.multipleVariants??[]:[]}getVariantName(e){const t=this.experiments.get(e);if(this.isExperimentActive(e)&&t&&t.variant)return t.variant}createServiceFeaturesFromMap(e){const t=new Map;e&&e.length>0&&e.forEach((e=>{const i=new a.Z,n=e[0];"object"==typeof e[1]?(i.value=e[1].value?.toString(),i.params=new Map(Object.entries(e[1].params))):(i.value=e[1],i.params=new Map),"false"!==i.value&&(t.set(n,i),this.serviceExperimentsSet.add(n))})),this.serviceExperiments=t}CreateClientFeatures(e){this.expRawData=e;const t=new Map;if(e&&e.length>0){const i=Object.values(r.H),n=Object.values(s.t);e.forEach((e=>{const r=new o.Z;r.name=e.name,r.supported=!1,e.params?.length>1?r.multipleVariants=e.params:e.params?.length>0&&(r.variant=e.params[0].value),(i.includes(e.name)||n.includes(e.name))&&(1===e.params?.length&&!1===e.params[0]?r.supported=!1:(r.supported=!0,this.experimentsSet.add(e.name))),t.set(r.name,r)}))}this.experiments=t}CreateFromJsonStr(e){try{if(e){const t=JSON.parse(e);this.CreateClientFeatures(t)}}catch(e){}}CreateServiceFeaturesFromJsonStr(e){if(!e)return;const t=JSON.parse(e);this.CreateServiceFeaturesFromJsonObj(t)}CreateServiceFeaturesFromJsonObj(e){e&&(this.serviceFeatures=e,this.createServiceFeaturesFromMap(Object.entries(e)))}}},78938:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(){(0,n.Z)(this,"value",void 0),(0,n.Z)(this,"params",void 0)}}},47594:function(e,t,i){"use strict";i.d(t,{t:function(){return n}});let n=function(e){return e.msShoppingTestExp1="msShoppingTestExp1",e.msShoppingTestExp2="msShoppingTestExp2",e.msShoppingTestExp3="msShoppingTestExp3",e.msShoppingTestExp4="msShoppingTestExp4",e.msShoppingTestExp5="msShoppingTestExp5",e.msShoppingTestExp6="msShoppingTestExp6",e.msShoppingTestExp7="msShoppingTestExp7",e.msShoppingTestExp8="msShoppingTestExp8",e.msShoppingTestExp9="msShoppingTestExp9",e.msShoppingTestExp10="msShoppingTestExp10",e.msShoppingTestExp11="msShoppingTestExp11",e.msShoppingTestExp12="msShoppingTestExp12",e.msShoppingTestExp13="msShoppingTestExp13",e.msShoppingTestExp14="msShoppingTestExp14",e.msShoppingTestExp15="msShoppingTestExp15",e.msShoppingTestExp16="msShoppingTestExp16",e.msShoppingTestExp17="msShoppingTestExp17",e.msShoppingTestExp18="msShoppingTestExp18",e.msShoppingTestExp99="msShoppingTestExp99",e}({})},57021:function(e,t,i){"use strict";var n=i(72370);class o{static Now(){return Math.round((new Date).getTime()/1e3)}constructor(e,t){(0,n.Z)(this,"Lifetime",void 0),(0,n.Z)(this,"Timestamp",void 0),this.Lifetime=e,this.Timestamp=t||o.Now()}Expired(){return o.Now()-this.Timestamp>=this.Lifetime}}t.Z=o},36818:function(e,t,i){"use strict";var n=i(72370),o=i(5144),r=i(58474);class a extends r.Z{constructor(e,t){super(),(0,n.Z)(this,"Domain",void 0),(0,n.Z)(this,"EntryPoint",void 0),(0,n.Z)(this,"AutoApplyResult",void 0),(0,n.Z)(this,"CouponResults",void 0),(0,n.Z)(this,"AutoApplyProcessTime",void 0),(0,n.Z)(this,"BestCoupon",void 0),(0,n.Z)(this,"Discount",void 0),(0,n.Z)(this,"StartingPrice",void 0),(0,n.Z)(this,"ErrorName",void 0),(0,n.Z)(this,"Currency",void 0),(0,n.Z)(this,"PageCurrency",void 0),(0,n.Z)(this,"IsStackable",void 0),(0,n.Z)(this,"AutoApplyScenario",void 0),(0,n.Z)(this,"ExtractedSelectors",void 0),(0,n.Z)(this,"CartExtractionId",void 0),(0,n.Z)(this,"Market",void 0),(0,n.Z)(this,"PageUrl",void 0),(0,n.Z)(this,"Metadata",void 0),this.Domain=e,this.EntryPoint=t??o.N9.Shopping,this.PageUrl=window?.location?.href??""}SetResultData(e,t,i,n,o,r,a,s,l,c,d,u){this.AutoApplyResult=e,this.AutoApplyProcessTime=t,this.BestCoupon=i,this.CouponResults=n,this.Discount=o,this.StartingPrice=r,this.IsStackable=a,this.AutoApplyScenario=s,this.ExtractedSelectors=l,this.CartExtractionId=c,this.Market=d,this.Metadata=JSON.stringify(u)}SetErrorData(e,t){this.AutoApplyResult=e,this.ErrorName=t}SetCurrencyInfo(e,t){this.Currency=e,this.PageCurrency=t}}t.Z=a},93209:function(e,t,i){"use strict";var n=i(72370),o=i(58474);class r extends o.Z{constructor(e,t,i,o,r){super(),(0,n.Z)(this,"ButtonClicked",void 0),(0,n.Z)(this,"ModuleId",void 0),(0,n.Z)(this,"Domain",void 0),(0,n.Z)(this,"Metadata",void 0),(0,n.Z)(this,"FlyoutId",void 0),this.ButtonClicked=e,this.ModuleId=t,this.Domain=i,this.Metadata=o,this.FlyoutId=r}}t.Z=r},84830:function(e,t,i){"use strict";i.d(t,{Z:function(){return l}});var n=i(72370),o=i(4872),r=i(31656);class a{static CreateInstance(e){a.instance=new a(e)}static async SetTag(e,t){a.instance&&t&&a.instance.clarityEnabled&&a.instance.WaitForClarityToLoad().then((()=>{window[a.clarityKey]("set",e,t)}))}static ReportClientInfo(e,t,i){a.reportedClientContextInfo||(a.SetTag(a.TAGNAME_CLIENTNAME,e),a.SetTag(a.TAGNAME_JSVERSION,t),a.SetTag(a.TAGNAME_EDGEVERSION,i),a.reportedClientContextInfo=!0)}constructor(e){(0,n.Z)(this,"clarityEnabled",!1),(r.R?.isExperimentActive(o.H.clarity)||r.R?.isExperimentActive(o.H.clarityWithCookies))&&(this.clarityEnabled=!0)}async WaitForClarityToLoad(){for(;!window.hasOwnProperty(a.clarityKey);)await new Promise((e=>{setTimeout(e,1e3)}))}}(0,n.Z)(a,"TAGNAME_DOMAIN","domain"),(0,n.Z)(a,"TAGNAME_FLIGHT","flight"),(0,n.Z)(a,"TAGNAME_VIEW","view"),(0,n.Z)(a,"TAGNAME_CLIENTNAME","appinfoclientname"),(0,n.Z)(a,"TAGNAME_JSVERSION","jsversion"),(0,n.Z)(a,"TAGNAME_EDGEVERSION","edgeversion"),(0,n.Z)(a,"clarityKey","clarity"),(0,n.Z)(a,"instance",void 0),(0,n.Z)(a,"reportedClientContextInfo",!1);var s=a,l=class{constructor(e,t,i,o,r,a,l){(0,n.Z)(this,"AppInfoClientName",void 0),(0,n.Z)(this,"JSVersion",void 0),(0,n.Z)(this,"BuildVersion",void 0),(0,n.Z)(this,"EnabledServiceFlights",void 0),(0,n.Z)(this,"MUID",void 0),(0,n.Z)(this,"EnabledServiceFeaturesV2",void 0),(0,n.Z)(this,"Channel",void 0),(0,n.Z)(this,"Enabledfeatures",void 0),this.AppInfoClientName=e,this.JSVersion=t,this.BuildVersion=i,this.EnabledServiceFlights=o,this.EnabledServiceFeaturesV2=r,s.ReportClientInfo(e,t,i),this.Channel=a,this.Enabledfeatures=l}}},80090:function(e,t,i){"use strict";var n=i(72370),o=i(58474);class r extends o.Z{constructor(e,t,i,o){super(),(0,n.Z)(this,"Domain",void 0),(0,n.Z)(this,"Data",void 0),(0,n.Z)(this,"ErrorType",void 0),(0,n.Z)(this,"StackTrace",void 0),this.Domain=e,this.StackTrace=o,this.Data=JSON.stringify(i),this.ErrorType=t}}t.Z=r},14732:function(e,t,i){"use strict";i.d(t,{i:function(){return r}});var n=i(72370),o=i(5144);const r=new class{constructor(){(0,n.Z)(this,"appName",void 0),this.appName=o.BN.Edge}SetAppName(e){this.appName=e}GetAppName(){return this.appName}}},12953:function(e,t,i){"use strict";var n=i(72370),o=i(58474);class r extends o.Z{constructor(e,t,i,o,r,a){super(),(0,n.Z)(this,"CouponCode",void 0),(0,n.Z)(this,"Domain",void 0),(0,n.Z)(this,"Scenario",void 0),(0,n.Z)(this,"PageUrl",void 0),(0,n.Z)(this,"data",void 0),(0,n.Z)(this,"description",void 0),this.CouponCode=e,this.Domain=t,this.Scenario=i,this.PageUrl=o,this.data=r??"",this.description=a}}t.Z=r},59645:function(e,t,i){"use strict";var n=i(72370),o=i(58474);class r extends o.Z{constructor(e,t,i,o,r){super(),(0,n.Z)(this,"EdgeFlyoutStatus",void 0),(0,n.Z)(this,"ComparableOffersCount",void 0),(0,n.Z)(this,"SavingsAmount",void 0),(0,n.Z)(this,"Domain",void 0),(0,n.Z)(this,"Metadata",void 0),(0,n.Z)(this,"FlyoutId",void 0),this.EdgeFlyoutStatus=e,this.ComparableOffersCount=t,this.SavingsAmount=i,this.Domain=o,this.Metadata=r}}t.Z=r},97861:function(e,t,i){"use strict";var n=i(72370),o=i(58474);class r extends o.Z{constructor(e,t,i,o,r,a,s,l,c,d,u){super(),(0,n.Z)(this,"Domain",void 0),(0,n.Z)(this,"ICStatusType",void 0),(0,n.Z)(this,"TimeToGetResponseSec",void 0),(0,n.Z)(this,"TimeToRenderSec",void 0),(0,n.Z)(this,"TimeFromSentToRender",void 0),(0,n.Z)(this,"Metadata",void 0),(0,n.Z)(this,"Message",void 0),(0,n.Z)(this,"PageType",void 0),(0,n.Z)(this,"OpenWith",void 0),(0,n.Z)(this,"PopupOrigination",void 0),(0,n.Z)(this,"IsPane",void 0),(0,n.Z)(this,"CurrentUrl",void 0),this.ICStatusType=e?.toString(),this.TimeToGetResponseSec=i,this.TimeToRenderSec=o,this.TimeFromSentToRender=r,this.Domain=t,this.Metadata=a,this.Message=s,this.PageType=l,this.PopupOrigination=c,this.IsPane=d,this.CurrentUrl=u}}t.Z=r},58474:function(e,t){"use strict";t.Z=class{ToString(){return JSON.stringify(this)}}},79308:function(e,t,i){"use strict";var n=i(72370),o=i(58474);class r extends o.Z{constructor(...e){super(...e),(0,n.Z)(this,"Domain",void 0),(0,n.Z)(this,"Savings",void 0),(0,n.Z)(this,"InitialPrice",void 0),(0,n.Z)(this,"Currency",void 0),(0,n.Z)(this,"Result",void 0),(0,n.Z)(this,"PageCurrency",void 0)}SetResultData(e,t,i,n,o,r){this.Domain=e,this.Savings=t??0,this.InitialPrice=i??0,this.Currency=n,this.PageCurrency=o,this.Result=r}}t.Z=r},73765:function(e,t,i){"use strict";var n=i(72370),o=i(58474);class r extends o.Z{constructor(e,t,i,o,r){super(),(0,n.Z)(this,"Domain",void 0),(0,n.Z)(this,"Scenario",void 0),(0,n.Z)(this,"PageUrl",void 0),(0,n.Z)(this,"event_metadata",void 0),(0,n.Z)(this,"event",void 0),this.Domain=e,this.Scenario=t,this.PageUrl=i,this.event_metadata=r??"",this.event=o}}t.Z=r},82960:function(e,t,i){"use strict";i.d(t,{v:function(){return o}});var n=i(72370);class o{static uuidv4(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(e=>{const t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)}))}constructor(e){(0,n.Z)(this,"Type",void 0),(0,n.Z)(this,"ID",void 0),this.Type=e,this.ID=""}toString(){return JSON.stringify(this)}}t.Z=o},17204:function(e,t,i){"use strict";i(5144)},15612:function(e,t,i){"use strict";i.d(t,{F:function(){return o}});var n=i(72370);const o=18e5;class r{constructor(){(0,n.Z)(this,"otherSellers",void 0),(0,n.Z)(this,"productImage",void 0),(0,n.Z)(this,"productPrice",void 0),(0,n.Z)(this,"currency",void 0),(0,n.Z)(this,"productUrl",void 0),(0,n.Z)(this,"dataCreationTime",void 0)}static Create(e){const t=new r;return t.productImage=e.productImage,t.productPrice=e.productPrice,t.productUrl=e.productUrl,t.currency=e.currency,t.otherSellers=new Array,e.otherSellers.forEach((e=>{t.otherSellers.push(e)})),t}}t.Z=r},18519:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(){(0,n.Z)(this,"perMinFirstTriggered",void 0),(0,n.Z)(this,"perMinCount",0),(0,n.Z)(this,"perHourFirstTriggered",void 0),(0,n.Z)(this,"perHourCount",0),(0,n.Z)(this,"perDayFirstTriggered",void 0),(0,n.Z)(this,"perDayCount",0)}}},17675:function(e,t,i){"use strict";i.d(t,{l:function(){return o}});var n=i(72370);class o{}(0,n.Z)(o,"ruleBasedTriggerDataKey","RuleBasedTriggerData"),(0,n.Z)(o,"defaultCouponExpectationWeight",2),(0,n.Z)(o,"positiveEngagementWeight",3),(0,n.Z)(o,"isSpiritedShopperWeight",1),(0,n.Z)(o,"mlWeight",3),(0,n.Z)(o,"defaultPriceDropWeight",2),(0,n.Z)(o,"defaultBestCompetingPriceWeight",2),(0,n.Z)(o,"scoreThreshold",.4),(0,n.Z)(o,"noPreviousUserDataAutoOpenRate",.6),(0,n.Z)(o,"noPreviousUserDataAlwaysOpenCouponExpectation",.5),(0,n.Z)(o,"noPreviousUserDataAlwaysOpenCouponExpectationV0",.2),(0,n.Z)(o,"noPreviousUserDataAlwaysOpenPriceDrop",.2),(0,n.Z)(o,"noPreviousUserDataAlwaysOpenBestCompetingPrice",.2),(0,n.Z)(o,"mlFirstHighConfidenceRange",.3),(0,n.Z)(o,"mlSecondHighConfidenceRange",.7),(0,n.Z)(o,"minEngagementCount",4),(0,n.Z)(o,"minEngagementCountV1",2),(0,n.Z)(o,"engagementScoreThreshold",.5),(0,n.Z)(o,"flyoutReintroduceDays",1)},13018:function(e,t,i){"use strict";var n=i(72370),o=i(17675);t.Z=class{constructor(e,t,i){(0,n.Z)(this,"userEngagementResults",void 0),(0,n.Z)(this,"couponExpectationWeight",void 0),(0,n.Z)(this,"firstTimeAutoOpenDisabled",void 0),(0,n.Z)(this,"flyoutReintroduceDays",o.l.flyoutReintroduceDays),(0,n.Z)(this,"flyoutReintroduceIsForced",!1),(0,n.Z)(this,"notificationTracker",void 0),this.userEngagementResults=e,this.couponExpectationWeight=t??o.l.defaultCouponExpectationWeight,this.firstTimeAutoOpenDisabled=i}}},12710:function(e,t,i){"use strict";i.d(t,{e:function(){return n}});const n={feedbackMessages:{feedbackAutofillDontWork:{message:"feedbackOptionAutofillDontWork",weight:5},feedbackCouponsDontWork:{message:"feedbackOptionCouponsDontWork",weight:5},feedbackIncorrectInfo:{message:"feedbackOptionIncorrectInfo",weight:3},feedbackOthers:{message:"feedbackOptionOthers",weight:2},feedbackTooFrequently:{message:"feedbackOptionTooFrequently",weight:3},feedbackTookTooMuchTime:{message:"feedbackOptionTookTooMuchTime",weight:4},feedbackUntrustworthy:{message:"feedbackOptionUntrustworthy",weight:2}},microNotificationWeights:{microNotificationClick:2},snoozeClickCountDaysEngagement:7,snoozeClickCountEngagement:3,storageKeys:{userEngagementDataKey:"UserEngagementData"},userEngagementCouponWeights:{autoApplyWeight:3,dislikeDefaultWeight:4,dismissWeight:.5,likeWeight:4,manuallyTriggeredWeight:1,seeMoreCouponsWeight:1,selectCouponWeight:1,snoozeBtnWeight:3,tooltipWeight:1},userEngagementPriceComparisonWeights:{competingPricesWeight:2},userEngagementPriceHistoryWeights:{priceHistoryGraphHoverWeight:1,priceHistoryMoreInfoWeight:1}}},54775:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(){(0,n.Z)(this,"positiveEngagementCount",0),(0,n.Z)(this,"negativeEngagementCount",0),(0,n.Z)(this,"snoozeClickTimes",void 0),(0,n.Z)(this,"lastClick",void 0),(0,n.Z)(this,"consecutiveDismissCount",0)}}},68793:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(){(0,n.Z)(this,"positiveEngagementScore",-1),(0,n.Z)(this,"totalEngagementsCount",0),this.positiveEngagementScore=-1,this.totalEngagementsCount=0}}},99182:function(e,t,i){"use strict";var n=i(72370);class o{constructor(){(0,n.Z)(this,"domainSelector",void 0),(0,n.Z)(this,"productTitleSelector",void 0),(0,n.Z)(this,"productImageSelector",void 0),(0,n.Z)(this,"productLinkSelector",void 0)}static Create(e){const t=new o;return t.domainSelector=e.domainSelector,t.productTitleSelector=e.productTitleSelector,t.productImageSelector=e.productImageSelector,t.productLinkSelector=e.productLinkSelector,t}}t.Z=o},95016:function(e,t,i){"use strict";var n=i(72370),o=i(88767);t.Z=class{constructor(e){if((0,n.Z)(this,"Url",void 0),(0,n.Z)(this,"Description",void 0),(0,n.Z)(this,"SellerName",void 0),(0,n.Z)(this,"Domain",void 0),(0,n.Z)(this,"InstallmentAmount",void 0),(0,n.Z)(this,"InstallmentDescription",void 0),(0,n.Z)(this,"LowPrice",void 0),(0,n.Z)(this,"Price",void 0),(0,n.Z)(this,"FavIcon",void 0),(0,n.Z)(this,"CurrencySymbol",void 0),(0,n.Z)(this,"ImpressionToken",void 0),(0,n.Z)(this,"position",void 0),(0,n.Z)(this,"ProductImageUrl",void 0),(0,n.Z)(this,"ProductImageName",void 0),(0,n.Z)(this,"ProductImageOriginalUrl",void 0),(0,n.Z)(this,"PriceId",void 0),(0,n.Z)(this,"shippingPrice",void 0),(0,n.Z)(this,"IntendedPrice",void 0),(0,n.Z)(this,"originalAdsExtensions",void 0),(0,n.Z)(this,"Extensions",void 0),(0,n.Z)(this,"BillingType",void 0),(0,n.Z)(this,"ShouldOnTop",void 0),(0,n.Z)(this,"PriceDifference",void 0),(0,n.Z)(this,"geoDistance",void 0),(0,n.Z)(this,"mileageUnit",void 0),(0,n.Z)(this,"mileageValue",void 0),(0,n.Z)(this,"isPopular",void 0),(0,n.Z)(this,"dealRating",void 0),(0,n.Z)(this,"marketHint",void 0),(0,n.Z)(this,"listingTypes",void 0),(0,n.Z)(this,"listingAccidentText",void 0),(0,n.Z)(this,"PriceCurrency",void 0),(0,n.Z)(this,"validAutosOffer",!1),(0,n.Z)(this,"Make",void 0),(0,n.Z)(this,"isSimilarOffer",void 0),(0,n.Z)(this,"globalOfferId",void 0),(0,n.Z)(this,"promotionInformation",void 0),(0,n.Z)(this,"sellerLogo",void 0),(0,n.Z)(this,"finalPrice",void 0),e){const t=e.installmentInfo;t&&(this.InstallmentAmount=t.amount,this.InstallmentDescription=t.description);const i=e.offer,n=e.offerLevelSignals;i&&(this.LowPrice=i.lowPrice,this.Price=i.price,this.PriceCurrency=i.priceCurrency,this.Make=i.metadata?.make,this.Description=i.itemOffered?.name,this.SellerName=i.seller?.name,this.Domain=i.seller?.domain,this.sellerLogo=i.seller?.logoUrl,this.FavIcon=i.seller?.favicon,this.Url=i.url,this.CurrencySymbol=i.priceCurrencySymbol,this.ProductImageUrl=i.itemOffered?.image?.contentUrl,this.ProductImageOriginalUrl=i.itemOffered?.image?.originalUrl,this.geoDistance=i.metadata?.geoDistance,this.mileageUnit=i.metadata?.mileageUnit,this.mileageValue=i.metadata?.mileageValue,this.isPopular=i.metadata?.isPopular,this.dealRating=i.metadata?.dealRating,this.marketHint=i.metadata?.marketHint,this.listingTypes=i.metadata?.listingTypes?.map((e=>e.toLowerCase())),this.listingAccidentText=i.metadata?.accidentsIconText,(this.ProductImageOriginalUrl||this.ProductImageUrl)&&i.price&&i.itemOffered?.name&&i.url&&(void 0===this.ProductImageOriginalUrl&&(this.ProductImageOriginalUrl=this.ProductImageUrl),this.validAutosOffer=!0)),n&&(this.ShouldOnTop="true"===n.autoshow,this.PriceDifference=n?.pricedifference??0),this.BillingType=e.billingType?.toLowerCase()??o.YO.Backfill,this.ImpressionToken=e.impressionToken??"",this.PriceId=e.price_comparison_id??"",this.position=e.position??o.zE.NOT_SPECIFIED,this.isSimilarOffer=this.position===o.zE.SIMILAR_OFFERS||this.position===o.zE.SIMILAR_OFFERS_FREE,this.shippingPrice=e.shippingInfo?.price??0,this.globalOfferId=e?.offerLevelSignals?.globalOfferId??"",this.globalOfferId&&0!==this.globalOfferId.length||(this.globalOfferId=e?.globalOfferId??""),this.promotionInformation=e.promotionInformation;const r=e.extensions;r&&r.length>0&&(this.Extensions=new Array,r.forEach((e=>{const t=e.text,i=e._type;this.Extensions.push({ExtensionText:t,ExtensionType:i})}))),this.originalAdsExtensions=e.originalAdsExtensions}}}},81977:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(e,t){(0,n.Z)(this,"dtg",void 0),(0,n.Z)(this,"minPrice",void 0),this.dtg=e,t&&(this.minPrice=t.minPrice)}}},1583:function(e,t,i){"use strict";i.d(t,{MU:function(){return c},pD:function(){return d},sh:function(){return l}});var n=i(72370),o=i(27689),r=i(11232),a=i(81977),s=i(83591);let l=function(e){return e[e.PRICEDROP=0]="PRICEDROP",e[e.PRICEINCREASE=1]="PRICEINCREASE",e[e.FAIRPRICE=2]="FAIRPRICE",e[e.NOINSIGHT=3]="NOINSIGHT",e}({}),c=function(e){return e.NoInsight="NoInsight",e.ShowInsight="ShowInsight",e}({});const d=2;t.ZP=class{constructor(e,t,i,o,a,l,d,u=!1){if((0,n.Z)(this,"TriggerPriceHistoryAlert",void 0),(0,n.Z)(this,"TriggerPriceHistoryIncreasedAlert",void 0),(0,n.Z)(this,"DailyPrices",[]),(0,n.Z)(this,"ProductDetails",void 0),(0,n.Z)(this,"CurrentPrice",void 0),(0,n.Z)(this,"DailyPriceDropPercentage",void 0),(0,n.Z)(this,"SourceType",void 0),(0,n.Z)(this,"MedianPrice",void 0),(0,n.Z)(this,"ShowPriceHistoryInsight",!0),(0,n.Z)(this,"PriceHistoryInsightType",void 0),(0,n.Z)(this,"PriceHistoryDebug",void 0),(0,n.Z)(this,"UseV2Insights",void 0),(0,n.Z)(this,"PriceHistoryInsightDisplayKey",void 0),(0,n.Z)(this,"PriceHistoryInsightDisplayValues",void 0),this.hasAllV2Fields(e)){const t=e.priceHistoryData.priceHistoryInsight;this.UseV2Insights=!0,this.TriggerPriceHistoryAlert=t.triggerPriceHistoryAlert,this.DailyPriceDropPercentage=t.dailyPriceDropPercentage,this.MedianPrice=t.medianPrice,this.PriceHistoryInsightDisplayKey=t.displayTextKey,this.PriceHistoryInsightDisplayValues=t.displayValues,this.TriggerPriceHistoryAlert=t.triggerPriceHistoryAlert,this.TriggerPriceHistoryIncreasedAlert=t.triggerPriceHistoryIncreasedAlert}else this.TriggerPriceHistoryAlert=e.triggerPriceHistoryAlert,this.TriggerPriceHistoryIncreasedAlert=e.triggerPriceHistoryIncreasedAlert,this.DailyPriceDropPercentage=e.priceHistoryData?.dailyPriceDropPercentage,this.MedianPrice=e.priceHistoryData?.medianPrice;this.SourceType=e.priceHistoryData?.sourceType,this.PriceHistoryDebug=new s.Z(e.debug),this.DailyPrices=this.getDailyPrices(e,a);const h=e.productDetails;h&&(this.ProductDetails=new r.Z(d??h.title,o??h.imageUrl,l??h.currency),this.ProductDetails.triggerPriceHistoryIncreasedAlert=e.triggerPriceHistoryIncreasedAlert,this.ProductDetails.triggerPriceHistoryMinorDropAlert=e.triggerPriceHistoryMinorDropAlert,this.ProductDetails.triggerPriceHistoryStableAlert=e.triggerPriceHistoryStableAlert,this.ProductDetails.price=h.latestPrice?.toString(),this.ProductDetails.originalPrice=h.originalPrice?.toString()),this.DailyPrices.length>0?(this.PriceHistoryInsightType=e.triggerInsight,u&&!t&&(this.PriceHistoryInsightType=c.NoInsight),this.PriceHistoryInsightType&&this.PriceHistoryInsightType===c.NoInsight||null==e.priceHistoryData?.dailyPriceDropPercentage?(this.CurrentPrice=t,this.ShowPriceHistoryInsight=!1):this.CurrentPrice=this.DailyPrices[this.DailyPrices.length-1].minPrice):this.CurrentPrice=t,i&&this.ProductDetails&&(this.ProductDetails.base64ProductImage=i),o&&this.ProductDetails&&(this.ProductDetails.extractedImage=o)}addBase64ProductImage(e){this.ProductDetails&&(this.ProductDetails.base64ProductImage=e)}getDaysDifference(e,t){return e=new Date(e.getFullYear(),e.getMonth(),e.getDate()),t=new Date(t.getFullYear(),t.getMonth(),t.getDate()),Math.abs(Math.floor((e.getTime()-t.getTime())/864e5))}getHoursDifference(e,t){return e=new Date(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours()),t=new Date(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours()),Math.abs((e.getTime()-t.getTime())/36e5)}getPriceHistoryType(){if(this.PriceHistoryInsightType===c.NoInsight)return l.NOINSIGHT;if(!this.UseV2Insights)return this.DailyPriceDropPercentage>=d?l.PRICEDROP:this.DailyPriceDropPercentage<=-1*d?l.PRICEINCREASE:l.FAIRPRICE;switch(this.PriceHistoryInsightDisplayKey){case"price_is_stable":return l.FAIRPRICE;case"lowestprice_in_x_month":case"lowestprice_in_x_months":case"secondlowestprice_in_x_month":case"secondlowestprice_in_x_months":case"x_percent_price_drop_from_usual":case"recent_x_percent_price_drop":return l.PRICEDROP;default:return l.PRICEINCREASE}}checkLastDate(e){const t=new Date;return Math.floor(t.getTime()-e.getTime())<0?t:e}getInsightString(e){const t=e[this.PriceHistoryInsightDisplayKey];let i;return i=this.PriceHistoryInsightDisplayKey.indexOf("percent")>-1?`${this.PriceHistoryInsightDisplayValues[0]}%`:`${this.PriceHistoryInsightDisplayValues[0]}`,(0,o.fZ)(t,t,i)}hasAllV2Fields(e){let t=e.priceHistoryData?.priceHistoryInsight;return!!t&&t&&Boolean(t.displayTextKey)&&t.displayValues&&t.displayValues.length>0&&t.medianPrice>0&&void 0!==t.dailyPriceDropPercentage}getDailyPrices(e,t){const i=[],n=e.priceHistoryData?.sourceType;if(e.priceHistoryData?.dailyPrice?.entries())for(const[o,r]of e.priceHistoryData.dailyPrice.entries()){const s=new Date(r.date);let l=new Date(s.getTime()+Math.abs(60*s.getTimezoneOffset()*1e3));o===e.priceHistoryData.dailyPrice.length-1&&(l=this.checkLastDate(l));const c=new a.Z(l,r.priceData);(0===n&&this.isDailyPriceValid(c,t)||0!==n)&&i.push(c)}return i}isDailyPriceValid(e,t){const i=new Date(2021,4,1),n=new Date(2021,8,24),o={"asos.com":n,"bestbuy.ca":n,"canadiantire.ca":n,"gapcanada.ca":n,"globalindustrial.ca":n,"homedepot.ca":n,"ikea.com":n,"sportchek.ca":n,"target.com":i,"walmart.com":i,"wayfair.ca":n};return!Object.keys(o).find((e=>e===t))||e.dtg>=o[t]}}},83591:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(e){(0,n.Z)(this,"nUrl",void 0),e&&(this.nUrl=e.nUrl)}}},81731:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(e){(0,n.Z)(this,"Timestamp",void 0),(0,n.Z)(this,"ProductId",void 0),(0,n.Z)(this,"Title",void 0),(0,n.Z)(this,"CurrencySymbol",void 0),(0,n.Z)(this,"ProductUrl",void 0),(0,n.Z)(this,"ImageUrl",void 0),(0,n.Z)(this,"CurrentPrice",void 0),(0,n.Z)(this,"OlderPrice",void 0),this.Timestamp=e?.timestamp,this.ProductId=e?.productId,this.Title=e?.title,this.CurrencySymbol=e?.currencySymbol,this.ProductUrl=e?.productUrl,this.ImageUrl=e?.imageUrl,this.CurrentPrice=e?.currentPrice,this.OlderPrice=e?.olderPrice}}},11232:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(e,t,i){(0,n.Z)(this,"title",void 0),(0,n.Z)(this,"imageUrl",void 0),(0,n.Z)(this,"currency",void 0),(0,n.Z)(this,"extractedImage",void 0),(0,n.Z)(this,"price",void 0),(0,n.Z)(this,"ProductUrl",void 0),(0,n.Z)(this,"base64ProductImage",void 0),(0,n.Z)(this,"triggerPriceHistoryIncreasedAlert",!1),(0,n.Z)(this,"triggerPriceHistoryMinorDropAlert",!1),(0,n.Z)(this,"triggerPriceHistoryStableAlert",!1),(0,n.Z)(this,"originalPrice",void 0),this.title=e,this.imageUrl=t,this.currency=i}}},40843:function(e,t,i){"use strict";var n=i(72370),o=i(65358),r=i(17609);t.Z=class{constructor(e){if((0,n.Z)(this,"trackedProducts",[]),(0,n.Z)(this,"_anid",void 0),(0,n.Z)(this,"_muid",void 0),(0,n.Z)(this,"_currentProduct",void 0),(0,n.Z)(this,"_abandonedCartNotificationToggle",void 0),(0,n.Z)(this,"timestamp",void 0),(0,n.Z)(this,"isUnsupportedDomain",void 0),(0,n.Z)(this,"trackingPreferences",void 0),e){this.trackingPreferences=new r.Z(e.trackingPreferences),this.isUnsupportedDomain=e.isUnsupportedDomain;for(const t of e.trackedProducts){const e=new o.ZP(t);e.Title&&e.ProductUrl&&this.trackedProducts.push(e)}}}}},65358:function(e,t,i){"use strict";i.d(t,{e7:function(){return a},$g:function(){return r},ZP:function(){return l}});var n=i(72370),o=i(81731);let r=function(e){return e.OutOfStock="OutOfStock",e.PriceDrop="PriceDrop",e}({}),a=function(e){return e.AbandonedCart="AbandonedCart",e.Explicit="Explicit",e.PostPurchase="PostPurchase",e}({});class s extends o.Z{constructor(e){super(e),(0,n.Z)(this,"basePrice",void 0),(0,n.Z)(this,"notificationEnabled",!1),(0,n.Z)(this,"notificationPercentageDrop",void 0),(0,n.Z)(this,"lastNotifiedAt",void 0),(0,n.Z)(this,"expirationDate",void 0),(0,n.Z)(this,"trackingType",void 0),(0,n.Z)(this,"metadata",void 0),(0,n.Z)(this,"imageUrl",void 0),(0,n.Z)(this,"durationInWeeks",void 0),(0,n.Z)(this,"trackingSource",a.Explicit),(0,n.Z)(this,"notifyForComparableProduct",!1),(0,n.Z)(this,"domain",void 0),(0,n.Z)(this,"comparableProductNotification",void 0),(0,n.Z)(this,"highSuccessRateCoupon",void 0),(0,n.Z)(this,"cashbackCommission",void 0),(0,n.Z)(this,"sellerName",void 0),(0,n.Z)(this,"lastPriceUpdateDate",void 0),(0,n.Z)(this,"lastNotificationEnabledDate",void 0),this.basePrice=e?.basePrice,void 0!==e?.notificationEnabled&&(this.notificationEnabled=e?.notificationEnabled),this.notificationPercentageDrop=e?.notificationPercentageDrop,this.lastNotifiedAt=e?.lastNotifiedAt,this.expirationDate=e?.expirationDate,this.trackingType=e?.trackingType,this.metadata=e?.metadata,this.imageUrl=e?.imageUrl,this.durationInWeeks=e?.durationInWeeks,void 0!==e?.trackingSource&&(this.trackingSource=e?.trackingSource),void 0!==e?.notifyForComparableProduct&&(this.notifyForComparableProduct=e?.notifyForComparableProduct),this.domain=e?.domain,this.comparableProductNotification=new class{constructor(e){(0,n.Z)(this,"url",void 0),(0,n.Z)(this,"productId",void 0),(0,n.Z)(this,"domain",void 0),(0,n.Z)(this,"price",void 0),(0,n.Z)(this,"globalOfferId",void 0),(0,n.Z)(this,"trackingUrl",void 0),this.url=e?.url,this.productId=e?.productId,this.domain=e?.domain,this.price=e?.price,this.globalOfferId=e?.globalOfferId,this.trackingUrl=e?.trackingUrl}}(e?.comparableProductNotification),this.highSuccessRateCoupon=e?.highSuccessRateCoupon?new class{constructor(e){(0,n.Z)(this,"couponCode",void 0),(0,n.Z)(this,"successRate",void 0),(0,n.Z)(this,"discountRate",void 0),(0,n.Z)(this,"sellerName",void 0),this.couponCode=e?.couponCode,this.successRate=e?.successRate,this.discountRate=e?.discountRate,this.sellerName=e?.sellerName}}(e?.highSuccessRateCoupon):void 0,this.cashbackCommission=e?.cashbackCommission?new class{constructor(e){(0,n.Z)(this,"domain",void 0),(0,n.Z)(this,"type",void 0),(0,n.Z)(this,"value",void 0),(0,n.Z)(this,"sellerName",void 0),this.domain=e?.domain,this.type=e?.type,this.value=e?.value,this.sellerName=e?.sellerName}}(e?.cashbackCommission):void 0,this.sellerName=e?.seller,this.lastPriceUpdateDate=e?.lastPriceUpdateDate,this.lastNotificationEnabledDate=e?.lastPriceUpdatePrice}}var l=s},17609:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(e){(0,n.Z)(this,"abandonedCartTrackingEnabled",void 0),(0,n.Z)(this,"lastUpdatedAt",void 0),(0,n.Z)(this,"IsAnidTrackingConsented",void 0),(0,n.Z)(this,"_abandonedCartTrackingUnset",void 0),void 0===e?(this.abandonedCartTrackingEnabled=!0,this._abandonedCartTrackingUnset=!0,this.IsAnidTrackingConsented=!1):(this.abandonedCartTrackingEnabled=e.abandonedCartTrackingEnabled,this.IsAnidTrackingConsented=e.isAnidTrackingConsented),this.lastUpdatedAt=e?.lastUpdatedAt}}},11501:function(e,t,i){"use strict";i.d(t,{Z:function(){return a}});var n=i(72370),o=i(45822),r=i(5144);class a{constructor(e){(0,n.Z)(this,"fragmentCollection",void 0),(0,n.Z)(this,"piiExtraction",void 0),(0,n.Z)(this,"transactionIdSettings",void 0),(0,n.Z)(this,"selectorTimeouts",void 0),(0,n.Z)(this,"isDisableProductNamesCollectionOnConfirmation",void 0),(0,n.Z)(this,"isDisablePurchaseTotalCollectionOnConfirmation",void 0),(0,n.Z)(this,"other",void 0),e&&(this.other=e.other,this.fragmentCollection=e.fragmentCollection,this.piiExtraction=e.piiExtraction,this.transactionIdSettings=e.transactionIdSettings,this.selectorTimeouts=e.selectorTimeouts,this.isDisableProductNamesCollectionOnConfirmation=e.isDisableProductNamesCollectionOnConfirmation,this.isDisablePurchaseTotalCollectionOnConfirmation=e.isDisablePurchaseTotalCollectionOnConfirmation)}GetOtherFeatureFlag(e,t=!1){return this.other&&this.other[e]?"true"===this.other[e].toLowerCase():t}IsAttibutionEnabled(){return this.GetOtherFeatureFlag("isEdgeAttributionEnabled")}GetFragmentCollectionTimeout(e){const t=this.fragmentCollection?.collectionRates;if(!t)return 0;const i=this.GetRatesForPageType(e,t);if(this.IsValidRate(i?.collectionTimeoutMs))return i?.collectionTimeoutMs??0;const n=t.allPages;return this.IsValidRate(n?.collectionTimeoutMs)?n?.collectionTimeoutMs??0:0}GetCollectionRate(e,t,i){if(!this.fragmentCollection?.isEnabled)return 0;const n=this.fragmentCollection?.collectionRates;if(!n)return 0;if(this.IsDisableCollectionOnPage(n,e))return 0;const o=this.GetRateFromObject(e,this.GetRatesForPageType(t,n),i);if(this.IsValidRate(o))return o??0;const r=this.GetRateFromObject(e,n.allPages,i);return this.IsValidRate(r)?r??0:0}IsDisableCollectionOnPage(e,t){return!!t&&!!(e.disableCollectionPages&&e.disableCollectionPages.length>0&&this.FindRegexMatch(t,e.disableCollectionPages))}GetRateFromObject(e,t,i){if(t){if(i)return this.IsValidRate(t.extractionIfBroken)?t.extractionIfBroken:this.other?.defaultExtractionIfBroken?this.ToValidRate(this.other?.defaultExtractionIfBroken):void 0;if(t.extractionForRegex&&e){const i=this.FindRateFromRegexMatch(e,t.extractionForRegex);if(this.IsValidRate(i))return i}return this.IsValidRate(t.defaultExtraction)?t.defaultExtraction:void 0}}FindRegexMatch(e,t){for(const i of t)if((0,o.io)(e,i))return i}FindRateFromRegexMatch(e,t){for(const i of Object.keys(t))if((0,o.io)(e,i))return t[i]??0}ToValidRate(e){const t=Number(e);return isNaN(t)?0:t}IsValidRate(e){const t=Number(e);return!isNaN(t)}GetRatesForPageType(e,t){switch(e){case r.GV.ConfirmationPage:return t.confirmationPage;case r.GV.CheckoutPage:return t.checkoutPage;case r.GV.UnknownPage:return t.unknownPage;case r.GV.ProductPage:return t.productPage;case r.GV.SearchPage:return t.searchPage;case r.GV.HomePage:return t.homePage;default:return t.otherPages}}}},59352:function(e,t,i){"use strict";i.d(t,{b:function(){return n}});let n=function(e){return e.variation1="variation1",e.variation2="variation2",e.variation3="variation3",e.variation4="variation4",e.variation5="variation5",e.variation6="variation6",e.variation7="variation7",e.variation8="variation8",e.variation9="variation9",e.autoActivationVariation="autoActivationVariation",e.pdpExactMatch="pdpExactMatch",e.spbCartPageAutoActivationVariation="spbCartPageAutoActivationVariation",e.spbAADLinkingNotification="spbAADLinkingNotification",e}({})},54774:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(e){(0,n.Z)(this,"EventInfoTime",void 0),(0,n.Z)(this,"EventInfoName",void 0),(0,n.Z)(this,"Domain",void 0),(0,n.Z)(this,"BestCoupon",void 0),(0,n.Z)(this,"CashbackCategory",void 0),(0,n.Z)(this,"StartingPrice",void 0),(0,n.Z)(this,"CashbackSavings",void 0),(0,n.Z)(this,"Discount",void 0),(0,n.Z)(this,"AutoApplyScenario",void 0),(0,n.Z)(this,"AutoApplyProcessTime",void 0),(0,n.Z)(this,"ImpressionId",void 0),(0,n.Z)(this,"JSVersion",void 0),(0,n.Z)(this,"BuildVersion",void 0),(0,n.Z)(this,"Currency",void 0),this.EventInfoTime=e?.eventInfo_Time,this.EventInfoName=e?.eventInfo_Name,this.Domain=e?.domain,this.BestCoupon=e?.bestCoupon,this.CashbackCategory=e?.cashbackCategory,this.StartingPrice=e?.startingPrice,this.CashbackSavings=e?.cashbackSavings,this.Discount=e?.discount,this.AutoApplyScenario=e?.autoApplyScenario,this.AutoApplyProcessTime=e?.autoApplyProcessTime,this.ImpressionId=e?.impressionId,this.JSVersion=e?.jSVersion,this.BuildVersion=e?.buildVersion,this.Currency=e?.currency}}},6747:function(e,t,i){"use strict";var n=i(72370);class o{constructor(){(0,n.Z)(this,"descriptionSelector",void 0),(0,n.Z)(this,"profileImageSelector",void 0),(0,n.Z)(this,"influencerInfoSelector",void 0),(0,n.Z)(this,"influencerIdSelector",void 0),(0,n.Z)(this,"influencerFollowers",void 0)}static Create(e){const t=new o;return t.descriptionSelector=e.descriptionSelector,t.profileImageSelector=e.profileImageSelector,t.influencerInfoSelector=e.influencerInfoSelector,t.influencerIdSelector=e.influencerIdSelector,t.influencerFollowers=e.influencerFollowers,t}}t.Z=o},57176:function(e,t,i){"use strict";i.d(t,{s3:function(){return r},x6:function(){return a}});var n=i(72370),o=i(605);let r=function(e){return e[e.ConfirmedProductPage=0]="ConfirmedProductPage",e[e.ProductPage=1]="ProductPage",e[e.Homepage=2]="Homepage",e[e.CheckoutPage=3]="CheckoutPage",e}({}),a=function(e){return e[e.Selector=0]="Selector",e[e.Automated=1]="Automated",e}({});class s extends o.Z{constructor(...e){super(...e),(0,n.Z)(this,"source",void 0),(0,n.Z)(this,"extraction",void 0),(0,n.Z)(this,"timestamp",void 0),(0,n.Z)(this,"numberOfFails",void 0)}}t.ZP=s},71951:function(e,t,i){"use strict";i.d(t,{A8:function(){return u},B8:function(){return h},M4:function(){return c},N0:function(){return s},eH:function(){return r},y$:function(){return d}});var n=i(72370),o=i(17928);let r=function(e){return e.RewardsPts="Points",e.RewardsMoney="Money",e}({}),a=function(e){return e.DistinctActions="Distinct",e.ContinuousActions="Continuous",e}({}),s=function(e){return e[e.NO_ACTIONS=0]="NO_ACTIONS",e[e.ONE_ACTION=1]="ONE_ACTION",e[e.TWO_ACTIONS=2]="TWO_ACTIONS",e[e.THREE_ACTIONS=3]="THREE_ACTIONS",e}({}),l=function(e){return e.AutoApply="UserCompletedAutoApply",e.Purchase="USerCompletedPurchase",e}({}),c=function(e){return e.ActionDetected="Detected",e.ActionReported="Reported",e}({}),d=function(e){return e.autoApplyStorageKey="ICAutoApplyCoupons",e.completedPurchaseStorageKey="ICCompletedPurchase",e}({}),u=function(e){return e.readUserInfoEndPoint="https://www.bing.com/api/shopping/v1/savings/threeActionsCampaign/readUserInfo",e.updateUserProgressEndPoint="https://www.bing.com/api/shopping/v1/savings/threeActionsCampaign/updateUserProgress",e}({}),h=function(e){return e.RewardProgress="Reward Progress",e.ClaimReward="Claim Reward",e}({});t.ZP=class{constructor(e){(0,n.Z)(this,"nuance",void 0),(0,n.Z)(this,"treatment",void 0),(0,n.Z)(this,"experiment",void 0),(0,n.Z)(this,"progress",void 0),(0,n.Z)(this,"isRewardClaimed",void 0),(0,n.Z)(this,"actionsCompletedCount",void 0),this.nuance=e?.nuance,this.treatment=e?.treatment,this.experiment=e?.experiment,this.progress=e?.progress,this.isRewardClaimed=e?.rewarded,this.calculateProgress()}calculateProgress(){let e=0;this.progress&&(this.progress.action1&&e++,this.progress.action2&&e++,this.progress.action3&&e++),this.actionsCompletedCount=e}async reportUserAction(e,t,i){if(i===c.ActionDetected&&(this.updateActionStatus(t),(await fetch(u.updateUserProgressEndPoint,{body:JSON.stringify({nuance:this.nuance,progress:{action1:this.progress?.action1,action2:this.progress?.action2,action3:this.progress?.action3}}),headers:{Accept:"application/json","Content-Type":"application/json"},method:"POST"})).ok)){let i=d.autoApplyStorageKey;t===l.Purchase&&(i=d.completedPurchaseStorageKey),e.setStorageString(i,c.ActionReported)}}async reportUserProgress(e){this.progress||(this.progress=new o.O);const t=await e.getStorageString(d.autoApplyStorageKey),i=await e.getStorageString(d.completedPurchaseStorageKey);await this.reportUserAction(e,l.AutoApply,t),await this.reportUserAction(e,l.Purchase,i)}updateActionStatus(e){switch(this.progress||(this.progress=new o.O),e){case l.Purchase:this.experiment===a.ContinuousActions&&(this.progress.action3=!0);break;case l.AutoApply:this.experiment===a.ContinuousActions?this.progress.action2=!0:this.experiment===a.DistinctActions&&(this.progress.action3=!0)}this.calculateProgress()}}},17928:function(e,t,i){"use strict";i.d(t,{O:function(){return o}});var n=i(72370);class o{constructor(){(0,n.Z)(this,"action1",void 0),(0,n.Z)(this,"action2",void 0),(0,n.Z)(this,"action3",void 0)}}},5144:function(e,t,i){"use strict";i.d(t,{$S:function(){return r},AM:function(){return A},BN:function(){return g},E_:function(){return w},G7:function(){return S},GV:function(){return u},Iy:function(){return x},KE:function(){return f},M_:function(){return y},My:function(){return s},N9:function(){return m},R:function(){return o},Sl:function(){return v},T4:function(){return O},Vm:function(){return p},Wm:function(){return a},YQ:function(){return P},e4:function(){return c},in:function(){return n},oN:function(){return b},pW:function(){return T},ps:function(){return d},u3:function(){return h},xu:function(){return l},zy:function(){return C}});let n=function(e){return e.Trace="Trace",e.Debug="Debug",e.Information="Information",e.Warning="Warning",e.Error="Error",e.Critical="Critical",e.None="None",e}({}),o=function(e){return e.AutoApply="AutoApply",e.ButtonClick="ButtonClick",e.ClientError="ClientError",e.DebugMessage="DebugMessage",e.EdgeFlyoutStatus="EdgeFlyoutStatus",e.CheckoutPageValidation="CheckoutPageValidation",e.CashbackInfo="CashbackInfo",e.CashbackInfoOfferDetails="CashbackInfoOfferDetails",e.OtherSellers="OtherSellers",e.RewardsActivity="RewardsActivity",e.ExpressCheckout="ExpressCheckout",e.EdgeFlyoutStatusDiagnostic="EdgeFlyoutStatusDiagnostic",e.RenderTime="RenderTime",e.RenderTimeline="RenderTimeline",e.RenderTimeBreakDown="RenderTimeBreakDown",e.PrintableGroceryCouponsOverlay="PrintableGroceryCouponsOverlay",e.CartExtraction="CartExtraction",e.CartExtractionError="CartExtractionError",e.FeedbackClicked="FeedbackClicked",e.ActiveExperiments="ActiveExperiments",e.ProductPageValidation="ProductPageValidation",e.VisibleClippingSelectors="VisibleClippingSelectors",e.PlatformDetection="PlatformDetection",e.ClippingExist="ClippingExist",e.CollectedCoupons="CollectedCoupons",e.PurchaseConfirmation="PurchaseConfirmation",e.CheckoutValidationPerf="CheckoutValidationPerf",e.AutoOpenControllerPerf="AutoOpenControllerPerf",e.AutoOpenControllerDataRecieved="AutoOpenControllerDataRecieved",e.ManualCouponApplication="ManualCouponApplication",e.EdgeDriverStatus="EdgeDriverStatus",e.EstimatedCashback="EstimatedCashback",e.CatalogExtractionRating="CatalogExtractionRating",e.CatalogExtractionReviews="CatalogExtractionReviews",e.TravelCheckoutExtraction="TravelCheckoutExtraction",e.UserPref="UserPref",e.AutoOpenController="AutoOpenController",e.ModuleQualityValidation="ModuleQualityValidation",e.HtmlFragment="HtmlFragment",e.ItemizedCashbackStatus="ItemizedCashbackStatus",e.ProductNameData="ProductNameData",e.CatalogExtractionPDPOffer="CatalogExtractionPDPOffer",e.UserAgreeToTerms="UserAgreeToTerms",e.UserDisagreeToTerms="UserDisagreeToTerms",e.CatalogExtractionSearchOffers="CatalogExtractionSearchOffers",e.SafariStatus="SafariStatus",e.AutomatedSelectorsDiagnostic="AutomatedSelectorsDiagnostic",e.JourneyStage="JourneyStage",e.PageDetectionRegexMatched="PageDetectionRegexMatched",e.ShoppingPersonalizedPromotionsRawTable="ShoppingPersonalizedPromotionsRawTable",e.PersonalizedPromotionsExtractionError="PersonalizedPromotionsExtractionError",e.ShoppingRewards="ShoppingRewards",e.ConfirmationPageValidation="ConfirmationPageValidation",e.ConfirmationPageDetails="ConfirmationPageDetails",e.SelectorDataExtraction="SelectorDataExtraction",e}({}),r=function(e){return e.AutoApply="AutoApply",e.BackgroundAutoApplyPositive="BackgroundAutoApplyPositive",e.BackgroundAutoApplyNegative="BackgroundAutoApplyNegative",e.PopupClose="PopupClose",e.CashbackInfoOfferDetails="CashbackInfoOfferDetails",e.CashbackNotificationCommision="CashbackNotificationCommision",e.ClippingPopupClose="ClippingPopupClose",e.ClipCoupon="ClipCoupon",e.AutoApplyNotificationClose="AutoApplyNotificationClose",e.CouponCopied="CouponCopied",e.SeeMoreCoupons="SeeMoreCoupons",e.SeeMoreRetailers="SeeMoreRetailers",e.SeeMoreSellers="SeeMoreSellers",e.SeeMorePaymentOptions="SeeMorePaymentOptions",e.SeeMorePersonalizedCashback="SeeMorePersonalizedCashback",e.SeeMoreGroceryCoupons="SeeMoreGroceryCoupons",e.SeeMoreSocialCoupons="SeeMoreSocialCoupons",e.SeeMoreShoppingTrips="SeeMoreShoppingTrips",e.SeeAllPrintableCoupons="SeeAllPrintableCoupons",e.SeeMoreItemizedCashback="SeeMoreItemizedCashback",e.SeeAllTrendingDeals="SeeAllTrendingDeals",e.SeeMoreOffers="SeeMoreOffers",e.ShoppingTripsCompletePurchase="ShoppingTripsCompletePurchase",e.PrintableCouponSelected="PrintableCouponSelected",e.PrintGroceryCoupons="PrintGroceryCoupons",e.FREManage="FREManage",e.FlyoutManage="FlyoutManage",e.FREDismiss="FREDismiss",e.FlyoutDismiss="FlyoutDismiss",e.FlyoutSnooze="FlyoutSnooze",e.DoNotShow="DoNotShow",e.DoNotShowFeatureForDomain="DoNotShowFeatureForDomain",e.FlyoutSnoozeUndo="FlyoutSnoozeUndo",e.RemindLater="RemindLater",e.BannerDismiss="BannerDismiss",e.AutoShowTurnedOff="AutoShowTurnedOff",e.AutoShowTurnedOn="AutoShowTurnedOn",e.ManageNotification="ManageNotification",e.ShoppingSettings="ShoppingSettings",e.FREGotIt="FREGotIt",e.FRENoThanks="FRENoThanks",e.NavigatedToAnotherRetailer="NavigatedToAnotherRetailer",e.ProceedToCheckoutWithImport="ProceedToCheckoutWithImport",e.ProceedToCheckoutWithOutImport="ProceedToCheckoutWithOutImport",e.ProceedToCheckout="ProceedToCheckout",e.UseCoupon="UseCoupon",e.UseRebates="UseRebates",e.CouponOverlayReceiptScannerBanner="CouponOverlayReceiptScannerBanner",e.ActivateCashBack="ActivateCashBack",e.JoinAndActivateCashback="JoinAndActivateCashback",e.CashbackSnoozeButton="CashbackSnoozeButton",e.CashbackDismissButton="CashbackDismissButton",e.CashbackDoNotShowButton="CashbackDoNotShowButton",e.CashbackDoNotShowOptionButton="CashbackDoNotShowOptionButton",e.PreviousCashBack="PreviousCashBack",e.ExpandedPreviousCashBack="ExpandedPreviousCashBack",e.NotificationDismiss="NotificationDismiss",e.OrganicFlowTurnedOff="OrganicFlowTurnedOff",e.OrganicFlowTurnedOn="OrganicFlowTurnedOn",e.PersonalizedRemindersTurnedOn="RemindersTurnedOn",e.PersonalizedRemindersTurnedOff="RemindersTurnedOff",e.SafariCrossSiteTrackingTurnedOn="SafariCrossSiteTrackingTurnedOn",e.SafariCrossSiteTrackingTurnedOff="SafariCrossSiteTrackingTurnedOff",e.RebatesLearnMore="RebatesLearnMore",e.RebatesLearnMoreFlyout="RebatesLearnMoreFlyout",e.RebatesViewInPane="RebatesViewInPane",e.RebatesAccount="RebatesAccount",e.CouponCopiedStackableWithCashBack="CouponCopiedStackableWithCashBack",e.CouponCopiedNonStackableWithCashBack="CouponCopiedNonStackableWithCashBack",e.ShareFB="ShareFB",e.ShareTwitter="ShareTwitter",e.ShareWhatsapp="ShareWhatsapp",e.ShareClipboard="ShareClipboard",e.ScrollVideoReviews="ScrollVideoReviews",e.ClickExpertReview="ClickExpertReview",e.ClickVideoReview="ClickVideoReview",e.NavigateToRetailerOffer="NavigateToRetailerOffer",e.CampaignShopNowPaneButton="CampaignShopNowPaneButton",e.CampaignAwarenessBannerButton="CampaignAwarenessBannerButton",e.CampaignCashbackBanner="CampaignCashbackBanner",e.WishlistSeeAllLink="WishlistSeeAllLink",e.WishlistSaveButton="WishlistSaveButton",e.WishlistUnsaveButton="WishlistUnsaveButton",e.ProductSummaryUnsaveWishlistButton="ProductSummaryUnsaveWishlistButton",e.ProductSummarySaveWishlistButton="ProductSummarySaveWishlistButton",e.NavigateToRecommendedDeal="NavigateToRecommendedDeal",e.NavigateToOtherSeller="NavigateToOtherSeller",e.AddToCart="AddToCart",e.TipsGotIt="TipsGotIt",e.TipsDwellTime="TipsDwellTime",e.SpbActivatedNotificationHeaderClick="SpbActivatedNotificationHeaderClick",e.HeroImageClick="HeroImageClick",e.AAWithoutEC="AAWithoutEC",e.AAWithEC="AAWithEC",e.ExpressCheckout="EC",e.RewardSignIn="RewardSignIn",e.RewardRedeem="RewardRedeem",e.RewardAdditionalLink="RewardAdditionalLink",e.RewardInfo="RewardInfo",e.ActivateCashbackToEarnReward="ActivateCashbackToEarnReward",e.ActivateCashbackToEarnRewardFail="ActivateCashbackToEarnRewardFail",e.HomePageNotificationHover="HomePageNotificationHover",e.DeletePackageTrackerByGuid="DeletePackageTrackerByGuid",e.PackageTrackingOptIn="PackageTrackingOptIn",e.PackageTrackingOptOut="PackageTrackingOptOut",e.PackageTrackingOrderClick="PackageTrackingOrderClick",e.PriceHistoryGotItBtn="PriceHistoryGotItBtn",e.DigitalGroceryCouponClick="DigitalGroceryCouponClick",e.DigitalGroceryCouponSeeAll="DigitalGroceryCouponSeeAll",e.RewardsClick="RewardsClick",e.ViewAccountActivity="ViewAccountActivity",e.CashbackRetailer="CashbackRetailer",e.SustainabilityShop="SustainabilityShop",e.ECWithoutPayment="ECWithoutPayment",e.ECWithBNPL="ECWithBNPL",e.FeedbackLike="FeedbackLike",e.FeedbackDislike="FeedbackDislike",e.FeedbackDislikeMenu0="FeedbackDislikeMenu0",e.FeedbackDislikeMenu1="FeedbackDislikeMenu1",e.FeedbackDislikeMenu2="FeedbackDislikeMenu2",e.FeedbackDislikeMenu3="FeedbackDislikeMenu3",e.FeedbackDislikeMenu4="FeedbackDislikeMenu4",e.FeedbackClose="FeedbackClose",e.FeedbackSubmit="FeedbackSubmit",e.FeedbackDismiss="FeedbackDismiss",e.SustainabilityLearnMore="SustainabilityLearnMore",e.PinterestNavigateToAnotherRetailer="PinterestNavigateToAnotherRetailer",e.YoutubeNavigateToAnohterRetailer="YoutubeNavigateToAnohterRetailer",e.SaveYoutubeCoupons="SaveYoutubeCoupons",e.DontSaveYoutubeCoupons="DontSaveYoutubeCoupons",e.ViewCouponsYoutube="ViewCouponsYoutube",e.PriceDropProductPage="PriceDropProductPage",e.PriceDropProductPageHover="PriceDropProductPageHover",e.SustainabilityConfirmationHover="SustainabilityConfirmationHover",e.AttainableInfoIcon="AttainableInfoIcon",e.AttainableInfoIconNotif="AttainableInfoIconNotif",e.AttainableContinueShopping="AttainableContinueShopping",e.DismissGiftCard="DismissGiftCard",e.GroceryItemShopAndActivate="GroceryItemShopAndActivate",e.GroceryItemTooltipViewed="GroceryItemTooltipViewed",e.GrocerySectionTooltipViewed="GrocerySectionTooltipViewed",e.GroceryItemDisclaimer="GroceryItemDisclaimer",e.JoinNow="JoinNow",e.MaybeLater="MaybeLater",e.NavigatedToMyGarage="NavigatedToMyGarage",e.NavigatedToAutosMarketplace="NavigatedToAutosMarketplace",e.NavigatedToAutosMarketplaceRecommendation="NavigatedToAutosMarketplaceRecommendation",e.NavigatedToAutosMarketplacePriceInsightsRatingURL="NavigatedToAutosMarketplacePriceInsightsRatingURL",e.NavigatedToAutosVideoReview="NavigatedToAutosVideoReview",e.NavigatedToAutosVideoReviewSeeNow="NavigatedToAutosVideoReviewSeeNow",e.ActivatedGroceryItem="ActivatedGroceryItem",e.MomentInTimeCard="MomentInTimeCard",e.TrendingOffersCard="TrendingOffersCard",e.TrendingOffersTitle="TrendingOffersTitle",e.SearchResultsCard="SearchResultsCard",e.TrendingOffersOnContextualTabCard="TrendingOffersOnContextualTabCard",e.TrendingOffersShowMore="TrendingOffersShowMore",e.SimilarOffersShowMore="SimilarOffersShowMore",e.SimilarOffersCard="SimilarOffersCard",e.SearchResultsShowMore="SearchResultsShowMore",e.TrendingOffersOnContextualTabShowMore="TrendingOffersOnContextualTabShowMore",e.DailyDealsCard="DailyDealsCard",e.RelatedProductsCard="RelatedProductsCard",e.NativeAdsCard="NativeAdsCard",e.AutoApplyConsent="AutoApplyConsent",e.AutoApplyBestCouponConsent="AutoApplyBestCouponConsent",e.DailyDealsShowMore="DailyDealsShowMore",e.DailyDealsTitle="DailyDealsTitle",e.RelatedProductsShowMore="RelatedProductsShowMore",e.NativeAdsShowMore="NativeAdsShowMore",e.VisualSearchCard="VisualSearchCard",e.VisualSearchShowMore="VisualSearchShowMore",e.BuyDirectCard="BuyDirectCard",e.BuyDirectShowMore="BuyDirectShowMore",e.BuyDirectTitle="BuyDirectTitle",e.ShoppingAdSlug="ShoppingAdSlug",e.InfiniteCategoryFeedCard="InfiniteCategoryFeedCard",e.InfiniteCategoryFeedAdCard="InfiniteCategoryFeedAdCard",e.InfiniteCategoryFeedShowMore="InfiniteCategoryFeedShowMore",e.InfiniteCategoryAdFeedShowMore="InfiniteCategoryAdFeedShowMore",e.InfiniteCategoryAdFeedTitle="InfiniteCategoryAdFeedTitle",e.AbandonedCartTile="AbandonedCartTile",e.AbandonedCartNotificationButton="AbandonedCartNotificationButton",e.GroceryCashbackPendingClaimClick="GroceryCashbackPendingClaimClick",e.MicrosoftCashbackAccountButton="MicrosoftCashbackAccountButton",e.PendingCashbackDisclaimer="PendingCashbackDisclaimer",e.ClaimedPendingCashbackDisclaimer="ClaimedPendingCashbackDisclaimer",e.ClaimedPendingCashbackTooltipViewed="ClaimedPendingCashbackTooltipViewed",e.PendingCashbackTooltipViewed="PendingCashbackTooltipViewed",e.cashbackUpsellJoinNowPath="cashbackUpsellJoinNowPathsJoinCashback",e.IncentiveCampaignProgress="IncentiveCampaignProgressButton",e.IncentiveCampaignClaim="IncentiveCampaignClaimButton",e.ChromeUserCampaignButton="ChromeUserCampaignButton",e.Unknown="Unknown",e.ProductTrackingCollectionsConsentRoam="ProductTrackingCollectionsConsentRoam",e.ProductTrackingCollectionsConsentSignIn="ProductTrackingCollectionsConsentSignIn",e.ProductTrackingCollectionsConsentSignInClose="ProductTrackingCollectionsConsentSignInClose",e.ProductTrackingCollectionsConsentRoamClose="ProductTrackingCollectionsConsentRoamClose",e.ProductTrackingCollectionsSeeAll="ProductTrackingCollectionsSeeAll",e.ProductTrackingTrackPrice="ProductTrackingTrackPrice",e.ProductTrackingTrackStock="ProductTrackingTrackStock",e.ProductTrackingUntrackPrice="ProductTrackingUntrackPrice",e.ProductTrackingUntrackStock="ProductTrackingUntrackStock",e.ProductTrackingUtilitiesTrackPrice="ProductTrackingUtilitiesTrackPrice",e.ProductTrackingUtilitiesTrackStock="ProductTrackingUtilitiesTrackStock",e.ProductTrackingUtilitiesUntrackPrice="ProductTrackingUtilitiesUntrackPrice",e.ProductTrackingUtilitiesUntrackStock="ProductTrackingUtilitiesUntrackStock",e.ProductTrackingTrackPriceAlertSettings="ProductTrackingTrackPriceAlertSettings",e.ProductTrackingTrackStockAlertSettings="ProductTrackingTrackStockAlertSettings",e.ProductTrackingAbandonedCartTrack="ProductTrackingAbandonedCartTrack",e.ProductTrackingAbandonedCartUntrack="ProductTrackingAbandonedCartUntrack",e.ProductCollectionTrackedProductsUntrack="ProductCollectionTrackedProductsUntrack",e.ProductCollectionsRecentlyViewedUntrack="ProductCollectionsRecentlyViewedUntrack",e.ProductCollectionsProduct="ProductCollectionsProduct",e.ProductCollectionsStartTracking="ProductCollectionsStartTracking",e.ProductCollectionsViewSteps="ProductCollectionsViewSteps",e.ProductTrackingOutOfStockPCVisitItem="ProductTrackingOutOfStockPCVisitItem",e.ProductTrackingOutOfStockConsentClose="ProductTrackingOutOfStockConsentClose",e.ProductTrackingBackInStockVisitItem="ProductTrackingBackInStockVisitItem",e.ProductTrackingPriceDropVisitItem="ProductTrackingPriceDropVisitItem",e.ProductTrackingPriceDropWithCouponVisitItem="ProductTrackingPriceDropWithCouponVisitItem",e.ProductTrackingPriceDropWithCashbackVisitItem="ProductTrackingPriceDropWithCouponVisitItem",e.ProductTrackingViewAllProducts="ProductTrackingViewAllProducts",e.ProductCollectionsRecentsTab="ProductCollectionsRecentsTab",e.ProductCollectionsTrackingTab="ProductCollectionsTrackingTab",e.ProductCollectionsTrack="ProductCollectionsTrack",e.RecommendationsViewPriceDrop="RecommendationsViewPriceDrop",e.SeePHGraph="SeePHGraph",e.PHGraphAndCouponsCompositeSeeMore="PHGraphAndCouponsCompositeSeeMore",e.lowePriceCashbackCouponsCompositeSeeMore="lowePriceCashbackCouponsCompositeSeeMore",e.TrendingCouponTile="TrendingCouponTile",e.SPBAutoActivateClick="SPBAutoActivateClick",e.TrendingCouponSeeMore="TrendingCouponSeeMore",e.SPBActivateButtonClick="SPBActivateButtonClick",e.SPBJoinAndActivateButtonClick="SPBJoinAndActivateButtonClick",e.ItemizedCashbackJoinAndActivateClick="ItemizedCashbackJoinAndActivateClick",e.SPBSeeMoreDealsButton="SPBSeeMoreDealsButton",e.SnoozeAllNotifications="SnoozeAllNotifications",e.SnoozeNotificationsForDomain="SnoozeNotificationsForDomain",e.SnoozeNotificationForDomain="SnoozeFeatureForDomain",e.SANConsentAcceptButton="SANConsentAcceptButton",e.SANConsentCloseButton="SANConsentCloseButton",e.SANConsentNotificationButton="SANConsentNotificationButton",e.SANConsentNotificationCloseButton="SANConsentNotificationCloseButton",e.ICSANConsentPaneButton="ICSANConsentPaneButton",e.ICSANConsentCloseButton="ICSANConsentCloseButton",e.ICPrivacyTooltipButton="ICPrivacyTooltipButton",e.ICTrackCashbackButton="ICTrackCashbackButton",e.ICTrackCashbackButtonNotification="ICTrackCashbackButtonNotification",e.ICClaimAndJoinButtonNotification="ICClaimAndJoinButtonNotification",e.ICClaimAndJoinButton="ICClaimAndJoinButton",e.InboxCouponsSignInToMicrosoftEdge="InboxCouponsSignInToMicrosoftEdge",e.InboxCouponsEdgeSwitchProfile="InboxCouponsEdgeSwitchProfile",e.InboxCouponsMicrosoftPrivacyStatement="InboxCouponsMicrosoftPrivacyStatement",e.InboxCouponsConnectYourEmail="InboxCouponsConnectYourEmail",e.InboxCouponsContinueWith="InboxCouponsContinueWith",e.InboxCouponsMicrosoftTermsOfUse="InboxCouponsMicrosoftTermsOfUse",e.InboxCouponsGoogleAPIServicesUserDataPolicy="InboxCouponsGoogleAPIServicesUserDataPolicy",e.InboxCouponsSwitchToPersonalProfile="InboxCouponsSwitchToPersonalProfile",e.InboxCouponsLearnAboutSupportedRetailers="InboxCouponsLearnAboutSupportedRetailers",e.InboxCouponsSeeMoreCoupons="InboxCouponsSeeMoreCoupons",e.InboxCouponsSeeMoreRetailers="InboxCouponsSeeMoreRetailers",e.InboxCouponsSeeOtherRetailers="InboxCouponsSeeOtherRetailers",e.InboxCouponsToggleExpansionRetailerCoupons="InboxCouponsToggleExpansionRetailerCoupons",e.InboxCouponsSettings="InboxCouponsSettings",e.InboxCouponsSeeOlderCoupons="InboxCouponsSeeOlderCoupons",e.InboxCouponsCouponClip="InboxCouponsCouponClip",e.InboxCouponsToggleExpansionModule="InboxCouponsToggleExpansionModule",e.InboxCouponsOpenDisconnectModal="InboxCouponsOpenDisconnectModal",e.InboxCouponsDisconnectEmail="InboxCouponsDisconnectEmail",e.InboxCouponsCancelDisconnectEmail="InboxCouponsCancelDisconnectEmail",e.InboxCouponsToggleExpansionPrivacy="InboxCouponsToggleExpansionPrivacy",e.InboxCouponsToggleExpansionRetailerSenders="InboxCouponsToggleExpansionRetailerSenders",e.InboxCouponsToggleRetailerSender="InboxCouponsToggleRetailerSender",e.InboxCouponsReconnectWith="InboxCouponsReconnectWith",e.InboxCouponsReconnect="InboxCouponsReconnect",e.InboxCouponsBack="InboxCouponsBack",e.InboxCouponsRefresh="InboxCouponsRefresh",e.InboxCouponsFreCarousel="InboxCouponsFreCarousel",e.InboxCouponsLearnMoreInfo="InboxCouponsLearnMoreInfo",e.ItemizedCashBackAddToCartButton="ItemizedCashBackAddToCartButton",e.ICGrocerySnoozeButton="ICGrocerySnoozeButton",e.ICGroceryDismissButton="ICGroceryDismissButton",e.ICGroceryDoNotShowButton="ICGroceryDoNotShowButton",e.ICGroceryDoNotShowButtonOption="ICGroceryDoNotShowButtonOption",e.SPBSnoozeButton="SPBSnoozeButton",e.SPBDoNotShowButton="SPBDoNotShowButton",e.SearchBoxInput="SearchBoxInput",e.FetchSearchResults="FetchSearchResults",e.FetchSearchResultsSpb="FetchSearchResultsSpb",e.PreviousSearchResults="PreviousSearchResults",e.NextSearchResults="NextSearchResults",e.SearchDismissButton="SearchDismissButton",e.SidepaneCashbackButton="SidepaneCashbackButton",e.SidepaneCashbackAnchor="SidepaneCashbackAnchor",e.winCartTile="winCartTile",e.UserAgreeToTerms="UserAgreeToTerms",e.UserDisagreeToTerms="UserDisagreeToTerms",e.ManuallyAppliedCoupon="ManuallyAppliedCoupon",e.BellIconNotification="BellIconNotification",e.CompositeNotificationsPriceComparisonComponent="CompositeNotificationsPriceComparisonComponent",e.AutoApplyPause="AutoApplyPause",e.PriceMatchOptIn="PriceMatchOptIn",e.PriceMatchOptOut="PriceMatchOptOut",e.PriceMatchCard="PriceMatchCard",e.PriceMatchRequestButton="PriceMatchRequestButton",e.PriceMatchNotificationButton="PriceMatchNotificationButton",e.SafariUpdateLinkButton="SafariUpdateLinkButton",e.LinkYourMSAButton="LinkYourMSAButton",e.AbandonedCartPcbVisitProductNotification="AbandonedCartPcbVisitProductNotification",e.TrackButtonSummaryCard="TrackButtonSummaryCard",e.TileButtonSummaryCard="TileButtonSummaryCard",e.OutsideAAOverlayClick="OutsideAAOverlayClick",e.AbandonedCartExclusiveCouponsNotification="AbandonedCartExclusiveCouponsNotification",e.TravelCardClicked="TravelCardClicked",e.TravelFlightCardClicked="TravelFlightCardClicked",e.TravelHotelCardClicked="TravelHotelCardClicked",e.TravelBookOnProviderClicked="TravelBookOnProviderClicked",e.TravelBookOnHotelProviderClicked="TravelBookOnHotelProviderClicked",e.UnifiedCashbackBtn="UnifiedCashbackBtn",e.PaneSettingTurnedOn="PaneSettingTurnedOn",e.PaneSettingTurnedOff="PaneSettingTurnedOff",e.BuyingOptionsFilterSelectionClicked="BuyingOptionsFilterSelectionClicked",e.PostPurchaseViewRewards="PostPurchaseViewRewards",e}({}),a=function(e){return e[e.BannerPriceComparisonModule=0]="BannerPriceComparisonModule",e[e.PriceComparisonNotificationHeader=1]="PriceComparisonNotificationHeader",e[e.PriceComparisonNotificationVisitItem=2]="PriceComparisonNotificationVisitItem",e[e.PriceComparisonModule=3]="PriceComparisonModule",e[e.MultiPriceComparisonNotification=4]="MultiPriceComparisonNotification",e}({}),s=function(e){return e.ICSPBNotificationLatency="ICSPBNotificationLatency",e}({}),l=function(e){return e.FavIconRenderStatus="FavIconRenderStatus",e.ProductSummaryTileStatus="ProductSummaryTileStatus",e.AppendNodeError="AppendNodeError",e.BadDataError="BadDataError",e.PaneFlagError="PaneFlagError",e.ItemizedCashbackActivateClick="ICActivateClick",e.OpenedInCheckout="OpenedInCheckout",e.EmptyCoupons="EmptyCoupons",e.AutoApplyButtonShown="AutoApplyButtonShown",e.AutoTrigger="AutoTrigger",e.ErrorWrongAutoTrigger="ErrorWrongAutoTrigger",e.ErrorPCNotificationPrice="ErrorPCNotificationPrice",e.UserTrigger="UserTrigger",e.BannerRendered="BannerRendered",e.OnErrorInvoked="OnErrorInvoked",e.BestPrice="BestPrice",e.YouCanSave="YouCanSave",e.RebatesConfirmationBlossomNotification="RebatesConfirmationBlossomNotification",e.RebatesConfirmationNotification="RebatesConfirmationNotification",e.RebatesTurnedOffNotification="RebatesTurnedOffNotification",e.StackableCouponWithCashback="StackableCouponWithCashback",e.NonStackableCouponWithCashback="NonStackableCouponWithCashback",e.CashBackNotActiveAutoApply="CashBackNotActiveAutoApply",e.PriceHistoryPriceDrop="PriceHistoryPriceDrop",e.PriceHistoryPriceIncrease="PriceHistoryPriceIncrease",e.PriceHistoryPriceStable="PriceHistoryPriceStable",e.PriceHistoryDwellTimeHover="PriceHistoryDwellTimeHover",e.PriceHistoryInfoButtonDwellTimeHover="PriceHistoryInfoButtonDwellTimeHover",e.PriceHistoryNotificationHover="PriceHistoryNotificationHover",e.PriceHistoryNoImage="PriceHistoryNoImage",e.PriceHistoryShowMoreInfoTooltip="PriceHistoryShowMoreInfoTooltip",e.PriceHistoryHideMoreInfoTooltip="PriceHistoryHideMoreInfoTooltip",e.NewPriceHistoryGraph="NewPriceHistoryGraph",e.PriceHistoryDiscoverHover="PriceHistoryDiscoverHover",e.PriceComparisonBackfillNoticeShowMoreInfoTooltip="PriceComparisonBackfillNoticeShowMoreInfoTooltip",e.PriceComparisonBackfillNoticeDwellTimeHover="PriceComparisonBackfillNoticeDwellTimeHover",e.PriceComparisonBackfillNoticeHideMoreInfoTooltip="PriceComparisonBackfillNoticeHideMoreInfoTooltip",e.PriceComparisonDiscoverView="PriceComparisonDiscoverView",e.PriceComparisonDiscoverHover="PriceComparisonDiscoverHover",e.PriceComparisonDiscoverClick="PriceComparisonDiscoverClick",e.BuyingOptionsCFLog="BuyingOptionsCFLog",e.CashBackWillNotRender="CashBackWillNotRender",e.ErrorPageHandlerFunction="ErrorPageHandlerFunction",e.FlyoutAutoPriceHistoryTrigger="FlyoutAutoPriceHistoryTrigger",e.FlyoutProductSummaryCardRightlyPlaced="FlyoutProductSummaryCardRightlyPlaced",e.ProductSummaryCardCollectionsPackageDeleteError="ProductSummaryCardCollectionsPackageDeleteError",e.FlyoutDiscoverPriceHistoryTrigger="FlyoutDiscoverPriceHistoryTrigger",e.FlyoutDismissedPriceHistoryTrigger="FlyoutDismissedPriceHistoryTrigger",e.AutoOpenUsingUrlParam="AutoOpenUsingUrlParam",e.ProductSummaryCardCollectionsPackageAddError="ProductSummaryCardCollectionsPackageAddError",e.ContextMenuInfo="ContextMenuInfo",e.AddedToCartNotification="AddedToCartNotification",e.CashBackBlossomCampaign="CashBackBlossomCampaign",e.CashbackError="CashbackError",e.CashbackInfo="CashbackInfo",e.CashBackActivated="CashBackActivated",e.ActivateCashBackNotificationImpression="ActivateCashBackNotificationImpression",e.CashBackNotificationImpression="CashBackNotificationImpression",e.ActivateCashBackNotificationInconsistentData="ActivateCashBackNotificationInconsistentData",e.ErrorCashBackActivation="ErrorCashBackActivation",e.CheckoutUserDataInvalid="CUDInvalid",e.ExpressCheckout="ECOnly",e.OtherSeller="OtherSeller",e.OtherSellerNotification="OtherSellerNotification",e.ModuleViewed="ModuleViewed",e.TrendingCouponsModuleRendered="TrendingCouponsModuleRendered",e.RewardWillBeRendered="RewardWillBeRendered",e.RewardSignInSuccess="RewardSignInSuccess",e.ErrorRewardSignIn="ErrorRewardSignIn",e.RewardNotification="RewardNotification",e.PackageTrackingCardViewed="PackageTrackingCardViewed",e.ViewedProductPriceDrop="ViewedProductPriceDrop",e.SustainabilityConfirmation="SustainabilityConfirmation",e.SustainabilityPDP="SustainabilityPDP",e.AutosMarketplaceRenderNotification="AutosMarketplaceRenderNotification",e.AutosReviewsRenderNotification="AutosReviewsRenderNotification",e.AutosMarketplaceRenderViewModule="AutosMarketplaceRenderViewModule",e.AutosRatingsAndReviewsRendered="AutosRatingsAndReviewsRendered",e.AutosMarketplaceListingHovered="AutosMarketplaceListingHovered",e.AutosMarketplaceRatingAndReviewHovered="AutosMarketplaceRatingAndReviewHovered",e.AutosMarketDwellTimeHover="AutosMarketDwellTimeHover",e.AutosMyGarageHovered="AutosMyGarageHovered",e.AutosMyGarageRenderViewModule="AutosMyGarageRenderViewModule",e.AutosMyGarageDwellTimeHover="AutosMyGarageDwellTimeHover",e.PerfCreateAndRender="PerfCreateAndRender",e.PerfPauseAutoShow="PerfPauseAutoShow",e.PerfSelectorExtraction="PerfSelectorExtraction",e.ErrorToRecordEngagement="ErrorToRecordEngagement",e.ErrorPaneStuckLoadingState="ErrorPaneStuckLoadingState",e.ErrorRecordingContentViewed="ErrorRecordingContentViewed",e.StartShoppingAPIErrorBaseAdsWorkflow="StartShoppingAPIErrorBaseAdsWorkflow",e.StartShoppingAPIEmptyBaseAdsWorkflow="StartShoppingAPIEmptyBaseAdsWorkflow",e.StartShoppingAPIErrorHubPageWorkflow="StartShoppingAPIErrorHubPageWorkflow",e.StartShoppingAPIErrorZIWorkflowWrapper="StartShoppingAPIErrorZIWorkflowWrapper",e.StartShoppingAPIEmptyResponseHubPageWorkflow="StartShoppingAPIEmptyResponseHubPageWorkflow",e.StartShoppingAPIHubPagePersonalized="StartShoppingAPIHubPagePersonalized",e.StartShoppingAPIEmptyResponseZIWorkflowWrapper="StartShoppingAPIEmptyResponseZIWorkflowWrapper",e.StartShoppingAPINativeAdsError="StartShoppingAPINativeAdsError",e.StartShoppingAPINoNativeAdsFound="StartShoppingAPINoNativeAdsFound",e.StartShoppingAPIVisualSearchError="StartShoppingAPIVisualSearchError",e.StartShoppingAPIVisualSearchCalled="StartShoppingAPIVisualSearchCalled",e.StartShoppingAPIVisualSearchNoResultsFound="StartShoppingAPIVisualSearchNoResultsFound",e.CashbackDataFetchError="CashbackDataFetchError",e.WishlistSaveButtonVisible="WishlistSaveButtonVisible",e.CollectionsPackageInjectionError="CollectionsPackageInjectionError",e.CollectionsPackageEntityParsingError="CollectionsPackageEntityParsingError",e.CollectionsPackageAddError="CollectionsPackageAddError",e.CollectionsPackageDeleteError="CollectionsPackageDeleteError",e.CampaignAPITopDealsError="CampaignAPITopDealsError",e.CampaignAPITopDealsNoResultsFound="CampaignAPITopDealsNoResultsFound",e.SavingsFoundShown="SavingsFoundShown",e.ErrorRewardsAdded="ErrorRewardsAdded",e.DiscoverShopping="DiscoverShopping",e.DiscoverChatChips="DiscoverChatChips",e.SmartCompare="SmartCompare",e.ProductSummary="ProductSummary",e.ProductSummaryInsightClick="ProductSummaryInsightClick",e.ProductSummaryHover="ProductSummaryHover",e.BuyingGuidesView="BuyingGuidesView",e.BuyingGuidesHover="BuyingGuidesHover",e.BuyingGuidesClick="BuyingGuidesClick",e.UserInsights="UserInsights",e.ExpertInsights="ExpertInsights",e.ItemizedCashbackWithPdpActivated="ICListWithActivatedPdp",e.ItemizedCashback="ICList",e.ItemizedCashbackRecentlyShown="ICListRecentlyShown",e.ItemizedCashbackQuotient="ICListQt",e.ItemizedCashbackActivated="ICActivedList",e.ItemizedCashbackActivatedSeeAll="ICActivedListSeeAll",e.ItemizedCashbackActivatedNavigateToRetailer="ICActivatedNavigateToRetailer",e.ItemizedCashbackActivatedHover="ICActivatedHover",e.ItemizedCashbackJoinAndActivatedHover="ItemizedCashbackJoinAndActivatedHover",e.ItemizedCashbackOfferClick="ICOfferClick",e.ItemizedCashbackShopCartClick="ICActivateShopCartClick",e.ItemizedCashbackHover="ICHoverItem",e.ICRelatedOfferNotification="ICRelatedOfferNotification",e.ICRelatedOfferNotificationHover="ICRelatedOfferNotificationHover",e.ICRelatedOfferNotificationClick="ICRelatedOfferNotificationClick",e.ICActivatedNotification="ICItemActivatedNotification",e.ICActivatedNotificationHover="ICItemActivatedNotificationHover",e.ICActivatedNotificationClick="ICItemActivatedNotificationClick",e.ICMultipleActivatedNotificationHover="ICMultipleActivatedNotificationHover",e.ICMultipleActivatedNotificationRender="ICMultipleActivatedNotificationRender",e.ICCategoryNotification="ICCategoryNotification",e.ICCategoryNotificationHover="ICCategoryNotificationHover",e.ICReceiptScannerBannerHover="ICReceiptScannerBannerHover",e.ICReceiptScannerBannerClick="ICReceiptScannerBannerClick",e.ICReceiptScannerBannerRender="ICReceiptScannerBannerRender",e.ICReceiptScannerDealHover="ICReceiptScannerDealHover",e.ICReceiptScannerDealClick="ICReceiptScannerDealClick",e.ICReceiptScannerDealRender="ICReceiptScannerDealRender",e.ICAddedToCartPDPRelatedOfferHover="ICAddedToCartPDPRelatedOfferHover",e.ICAddedToCartPDPRelatedOfferRender="ICAddedToCartPDPRelatedOfferRender",e.ICAddedToCartPDPRelatedOfferClick="ICAddedToCartPDPRelatedOfferClick",e.ICSearchNotification="ICSearchNotification",e.ICSearchNotificationHover="ICSearchNotificationHover",e.ICSearchNotificationClick="ICSearchNotificationClick",e.ICTotalCashbackNotification="ICTotalCashbackNotification",e.ICTotalCashbackHover="ICTotalCashbackHover",e.ICHomeNotificationError="ICHomeNotificationError",e.ICHomeNotificationSPB="ICHomeNotificationSPB",e.ICHomeNotificationSPBHover="ICHomeNotificationSPBHover",e.ICHomeNotificationSPBClick="ICHomeNotificationSPBClick",e.ICSearchNotificationSPB="ICSearchNotificationSPB",e.ICSearchNotificationSPBHover="ICSearchNotificationSPBHover",e.ICPdpNotificationSPB="ICPdpNotificationSPB",e.ICPdpNotificationSPBActivated="ICPdpNotificationSPBActivated",e.ICPdpNotificationSPBHover="ICPdpNotificationSPBHover",e.ICPDPActivatedHover="ICPDPActivatedHover",e.ICPdpCashback="ICPdpCashback",e.ICPdpCashbackHover="ICPdpCashbackHover",e.ICSearchCategoryResult="ICSearchCategoryResult",e.ICSearchCategoryResultHover="ICSearchCategoryResultHover",e.ICPdpCashbackNotification="ICPdpCashbackNotification",e.ICPdpCashbackNotificationHover="ICPdpCashbackNotificationHover",e.ICPdpCashbackNotificationClick="ICPdpCashbackNotificationClick",e.BlockedAutoOpenEngagement="BlockedAutoOpenEngagement",e.ICApiDataUnavailable="ICApiDataUnavailable",e.CouponExpectationTooltipOpen="CouponExpectationTooltipOpen",e.CouponExpectationTooltipRead="CouponExpectationTooltipRead",e.CouponDiscoverHover="CouponDiscoverHover",e.CouponDiscoverRender="CouponDiscoverRender",e.CouponDiscoverButtonClick="CouponDiscoverButtonClick",e.TrendingCouponDiscoverButtonClick="TrendingCouponDiscoverButtonClick",e.ProductCollectionsDiscoverHover="ProductCollectionsDiscoverHover",e.ProductCollectionsDiscoverRender="ProductCollectionsDiscoverRender",e.ProductCollectionsDiscoverClick="ProductCollectionsDiscoverClick",e.CouponCarouselHover="CouponCarouselHover",e.NotificationModuleRequired="NotificationModuleRequired",e.PersonalizedCashbackNotification="PersonalizedCashbackNotification",e.PersonalizedCashbackStoreWideNotification="PersonalizedCashbackStoreWideNotification",e.PersonalizedCashbackPaneModule="PersonalizedCashbackPaneModule",e.PersonalizedCashbackAddressBarNotification="PersonalizedCashbackAddressBarNotification",e.PersonalizedCashbackConfirmationNotification="PersonalizedCashbackConfirmationNotification",e.ViewedPrivacyFooter="ViewedPrivacyFooter",e.RenderedExtensionUpdateStatement="RenderedExtensionUpdateStatement",e.CategoryFilterClick="CategoryFilterClick",e.DiscoverSuggestionClick="DiscoverSuggestionClick",e.DiscoverChatSuggestionClick="DiscoverChatSuggestionClick",e.DiscoverChatDismissClick="DiscoverChatDismissClick",e.DiscoverChatHover="DiscoverChatHover",e.DiscoverChatChevronClick="DiscoverChatChevronClick",e.DiscoverChatChipMissingText="DiscoverChatChipMissingText",e.SmartCompareClick="SmartCompareClick",e.SmartCompareSpecCardClick="SmartCompareSpecCardClick",e.SmartCompareSpecCardBasicsClick="SmartCompareSpecCardBasicsClick",e.SmartCompareFullSpecsButtonClick="SmartCompareFullSpecsButtonClick",e.SmartCompareHover="SmartCompareHover",e.PersonalizedAutoTriggerOff="PersonalizedAutoTriggerOff",e.PaneTabClick="PaneTabClick",e.EstimatedCashbackShown="EstimatedCashbackShown",e.GroceryCouponsSeeMoreClick="GroceryCouponsSeeMoreClick",e.IncentiveCampaignProgressBanner="IncentiveCampaignProgressBanner",e.IncentiveCampaignClaimBanner="IncentiveCampaignClaimBanner",e.IncentiveCampaignProgressNotification="IncentiveCampaignProgressNotification",e.IncentiveCampaignClaimNotification="IncentiveCampaignClaimNotification",e.ErrorActivatingUpsell="ErrorActivatingUpsell",e.GroceryOfferCardClick="GroceryOfferCardClick",e.GroceryOfferCardHover="GroceryOfferCardHover",e.SponsoredTooltipHover="SponsoredTooltipHover",e.SponsoredTooltipFindMoreClick="SponsoredTooltipFindMoreClick",e.SPBDetailedPriceTooltipHover="SPBDetailedPriceTooltipHover",e.OfferDetailedPriceTooltipHover="OfferDetailedPriceTooltipHover",e.SPBActivatedOfferHover="SPBActivatedOfferHover",e.SPBActivatedOfferView="SPBActivatedOfferView",e.SPBActivatedNotificationShown="SPBActivatedNotificationShown",e.SPBCheckoutNotificationShown="SPBCheckoutNotificationShown",e.SPBCheckoutNotification="SPBCheckoutNotification",e.SPBInstantATCNotificationClick="SPBInstantATCNotificationClick",e.QuotientInstantATCNotificationClick="QuotientInstantATCNotificationClick",e.InstantATCCreationOverlay="InstantATCCreationOverlay",e.InstantATCSuccessOverlay="InstantATCSuccessOverlay",e.SPBOfferCardView="SPBOfferCardView",e.SPBOfferCardClick="SPBOfferCardClick",e.SPBOfferCardHover="SPBOfferCardHover",e.SPBActivateButtonHover="SPBActivateButtonHover",e.SPBPdpActivateButtonHover="SPBPdpActivateButtonHover",e.SPBJoinAndActivateButtonHover="SPBJoinAndActivateButtonHover",e.SPBConfirmationNotification="SPBConfirmationNotification",e.SPBConfirmationNotificationHover="SPBConfirmationNotificationHover",e.SPBConfirmationCardView="SPBConfirmationCardView",e.SPBConfirmationCardHover="SPBConfirmationCardHover",e.SPBAutoActivation="SPBAutoActivation",e.SPBAutoActivationTriggered="SPBAutoActivationTriggered",e.ICTotalCashBackSeeDealsClicked="ICTotalCashBackSeeDealsClicked",e.ICCategoryNotificationSeeDealsClicked="ICCategoryNotificationSeeDealsClicked",e.PopupMismatch="PopupMismatch",e.SignInToRebatesStarted="SignInToRebatesStarted",e.SignInToRebatesSuccess="SignInToRebatesSuccess",e.SignInToRebatesFailed="SignInToRebatesFailed",e.SeeActivatedDealsButtonClicked="SeeActivatedDealsButtonClicked",e.SignInButtonClicked="SignInButtonClicked",e.GroceryCashbackError="GroceryCashbackError",e.GroceryCashbackNotification="GroceryCashbackNotification",e.GroceryCashbackSubmitSuccess="GroceryCashbackSubmitSuccess",e.GroceryCashbackSubmitError="GroceryCashbackSubmitError",e.DiscoverModuleDataPrepError="DiscoverModuleDataPrepError",e.DiscoverModuleError="DiscoverModuleError",e.IsRebatesUserSource="IsRebatesUserSource",e.UserPref="UserPref",e.UserPrefMismatch="UserPrefMismatch",e.ProductTrackingNetworkError="ProductTrackingNetworkError",e.ProductTrackingDebug="ProductTrackingDebug",e.ProductTrackingBackInStockValidation="ProductTrackingBackInStockValidation",e.ProductTrackingPriceDropValidation="ProductTrackingPriceDropValidation",e.ProductTrackingOutOfStockExtraction="ProductTrackingOutOfStockExtraction",e.PinterestEngagement="PinterestEngagement",e.ProductTrackingCollectionsStatus="ProductTrackingCollectionsStatus",e.SanConsentViewed="SanConsentViewed",e.ICSanConsentNotificationHover="ICSanConsentNotificationHover",e.ICSanConsentNotification="ICSanConsentNotification",e.ICSanConsentViewed="ICSanConsentViewed",e.ICSanConsentHover="ICSanConsentHover",e.PCBackfillNoticeViewed="PCBackfillNoticeViewed",e.ICConfirmationNotification="ICItemConfirmNotification",e.ICPendingCashbackNotification="ICPendingCashbackNotification",e.ICConfirmationNotificationHover="ICConfirmationNotificationHover",e.ICPendingCashbackNotificationHover="ICPendingCashbackNotificationHover",e.ICConfirmationPaneCard="ICConfirmationPaneCard",e.ICPendingCashbackPaneCard="ICPendingCashbackPaneCard",e.ICConfirmationPaneCardHover="ICConfirmationPaneCardHover",e.ICPendingCashbackPaneCardHover="ICPendingCashbackPaneCardHover",e.ICQuotientPrivacyPolicyClicked="ICQuotientPrivacyPolicyClicked",e.ICPrivacyTooltip="ICPrivacyTooltip",e.ICPrivacyAndCookiesClicked="ICPrivacyAndCookiesClicked",e.ICMicrosoftRebatesClicked="ICMicrosoftRebatesClicked",e.ICTermsClicked="ICTermsClicked",e.SanConsentPaneBannerHover="SanConsentPaneBannerHover",e.ExclusiveOfferDomainVisited="ExclusiveOfferDomainVisited",e.ExclusiveBestOfferForRendered="ExclusiveBestOfferForRendered",e.ExclusiveOfferFromMicrosoftRendered="ExclusiveOfferFromMicrosoftRendered",e.ExclusiveOfferForRendered="ExclusiveOfferForRendered",e.ICQtPdpOffersNoShow="ICQtPdpOffersNoShow",e.ICQtPdpOffersShow="ICQtPdpOffersShow",e.ICSPBPdpOffersNoShow="ICSPBPdpOffersNoShow",e.ICSPBPdpOffersShow="ICSPBPdpOffersShow",e.ICSPBOffersNoShow="ICSPBOffersNoShow",e.ICSPBOffersCanShow="ICSPBOffersCanShow",e.ICSPBOfferSearchBar="ICSPBOfferSearchBar",e.ICSPBVisibilityFeedback="ICSPBVisibilityFeedback",e.ICSpbOffersNoShowHomePage="ICSpbOffersNoShowHomePage",e.CBNoShow="CBNoShow",e.ErrorToRecordTelemetry="ErrorToRecordTelemetry",e.SubmitGroceryDataErrorCardShow="SubmitGroceryDataErrorCardShow",e.InboxCouponsEmailConnectError="InboxCouponsEmailConnectError",e.InboxCouponsNoCouponsFoundOnRetailerSite="InboxCouponsNoCouponsFoundOnRetailerSite",e.InboxCouponsDisconnectEmailError="InboxCouponsDisconnectEmailError",e.InboxCouponsEmailDisconnected="InboxCouponsEmailDisconnected",e.InboxCouponsNotSupportedLanguage="InboxCouponsNotSupportedLanguage",e.InboxCouponsEdgeSignInSuccess="InboxCouponsEdgeSignInSuccess",e.InboxCouponsEdgeSignInSuccessWorkProfile="InboxCouponsEdgeSignInSuccessWorkProfile",e.InboxCouponsEdgeSignInNotCompleted="InboxCouponsEdgeSignInNotCompleted",e.InboxCouponsEdgeSignInError="InboxCouponsEdgeSignInError",e.InboxCouponsAAUpsellSuppressed="InboxCouponsAAUpsellSuppressed",e.InboxCouponsAAFailureUpsellViewed="InboxCouponsAAFailureUpsellViewed",e.InboxCouponsAAFailureUpsellClicked="InboxCouponsAAFailureUpsellClicked",e.InboxCouponsAAFailureUpsellPaneModuleViewed="InboxCouponsAAFailureUpsellPaneModuleViewed",e.InboxCouponsAASuccessUpsellViewed="InboxCouponsAASuccessUpsellViewed",e.InboxCouponsAASuccessUpsellClicked="InboxCouponsAASuccessUpsellClicked",e.InboxCouponsAASuccessUpsellPaneModuleViewed="InboxCouponsAASuccessUpsellPaneModuleViewed",e.InboxCouponsEmailConnected="InboxCouponsEmailConnected",e.ICAddToCartProductAdded="ICAddToCartProductAdded",e.ICAddToCartProductNotAdded="ICAddToCartProductNotAdded",e.SpbInstantATCOverlayShown="SpbInstantATCOverlayShown",e.QuotientInstantATCOverlayShown="QuotientInstantATCOverlayShown",e.InstantATCOverlayNotShown="InstantATCOverlayNotShown",e.DataValidation="DataValidation",e.FetchGetDataError="FetchGetDataError",e.FetchError="FetchError",e.ToastNotificationError="ToastNotificationError",e.CleaningStorageError="CleaningStorageError",e.StorageLimitReached="StorageLimitReached",e.SidepaneCashbackError="SidepaneCashbackError",e.DiscoverNotificationInfo="DiscoverNotificationInfo",e.DiscoverNotificationViewed="DiscoverNotificationViewed",e.DiscoverNotificationClicked="DiscoverNotificationClicked",e.CampaignCashbackBannerRendered="CampaignCashbackBannerRendered",e.DiscoverPaneError="DiscoverPaneError",e.DiscoverPaneInfo="DiscoverPaneInfo",e.AbandonedCartPersonalizedCashback="AbandonedCartPersonalizedCashback",e.ScrollbarWidthError="ScrollbarWidthError",e.FeatureLast30DSavingsTriviaRendered="FeatureLast30DSavingsTriviaRendered",e.FeatureAvrDailySavingsTriviaRendered="FeatureAvrDailySavingsTriviaRendered",e.CartPageCashbackNotification="CartPageCashbackNotification",e.FeatureSavingsTriviaRendered="FeatureSavingsTriviaRendered",e.FeatureSaversTriviaRendered="FeatureSaversTriviaRendered",e.PageHandlerInfo="PageHandlerInfo",e.PostPurchaseTrack="PostPurchaseTrack",e.PaneHeaderRendered="PaneHeaderRendered",e.PaneTabsRendered="PaneTabsRendered",e.UserInsightsView="UserInsightsView",e.ExpertInsightsView="ExpertInsightsView",e.SuppressAutoApply="SuppressAutoApply",e.HomePageOffersOnShorelineOpen="HomePageOffersOnShorelineOpen",e.HomePageSPBOfferHover="HomePageSPBOfferHover",e.HomePageSPBOfferClick="HomePageSPBOfferClick",e.NonCheckoutBgaaOpened="NonCheckoutBgaaOpened",e.AadUserLinking="AadUserLinking",e.JoinAndActivateImpression="JoinAndActivateImpression",e.ExclusiveCouponsNotificationRendered="ExclusiveCouponsNotificationRendered",e.CouponClippingElements="CouponClippingElements",e.AutoOpenSuppressed="AutoOpenSuppressed",e.CouponClippingSelectorsAvailable="CouponClippingSelectorsAvailable",e.FlyoutDataRecieved="FlyoutDataRecieved",e.UnifiedCashBackShorelineModule="UnifiedCashBackShorelineModule",e.UnifiedCashBackNotificationModule="UnifiedCashBackNotificationModule",e.UnifiedCashBackShorelineBtnClick="UnifiedCashBackShorelineBtnClick",e.UnifiedCashBackNotificationBtnClick="UnifiedCashBackNotificationBtnClick",e.UnifiedCashBackDebugLog="UnifiedCashBackDebugLog",e.PaneSettingsView="PaneSettingsView",e.AutoShowPaused="AutoShowPaused",e.BuyingOptionsRendered="BuyingOptionsRendered",e.BuyingOptionsDiscoverView="BuyingOptionsDiscoverView",e.BuyingOptionsDiscoverHover="BuyingOptionsDiscoverHover",e.BuyingOptionsDiscoverClick="BuyingOptionsDiscoverClick",e.BuyingOptionsFilters="BuyingOptionsFilters",e.BuyingOptionsRetailers="BuyingOptionsRetailers",e.BuyingOptionsNoFilter="BuyingOptionsNoFilter",e.BuyingOptionsNoRetailer="BuyingOptionsNoRetailer",e.BuyingOptionsRetailerHover="BuyingOptionsRetailerHover",e.PreEntityExtraction="PreEntityExtraction",e.ShoppingRewardsFlyoutNoShow="ShoppingRewardsFlyoutNoShow",e.ShoppingRewardsFlyoutShow="ShoppingRewardsFlyoutShow",e.RefreshError="RefreshError",e.PaneAutoOpened="PaneAutoOpened",e.AOPUserEngagement="AOPUserEngagement",e.AOPUserDsat="AOPUserDsat",e}({}),c=function(e){return e.HomePage="HomePage",e.HomePageNotification="HomePageNotification",e.PdpPage="ProductPage",e.SearchPage="SearchPage",e.SPBSearchPage="SPBSearchPage",e.SPBSearchNotification="SPBSearchNotification",e.SPBCategoryPage="SPBCategoryPage",e.SPBPdpPage="SPBPdpPage",e.CategorySearchPage="CategorySearchPage",e.ConfirmationPage="ConfirmationPage",e.ActivatedNotification="ActivatedNotification",e.MultipleActivatedNotification="MultipleActivatedNotification",e.PdpNotification="PdpNotification",e.PdpItemNotification="PdpItemNotification",e.RelatedItemNotification="PdpRelatedItemNotification",e.AddedToCartRelatedItemNotification="AddedToCartRelatedItemNotification",e.TotalCashBackNotification="TotalCashBackNotification",e.ICSanConsentNotification="ICSanConsentNotification",e.SPBpdpNotification="SPBpdpNotification",e.SPBCheckoutPageNotification="SPBCheckoutPageNotification",e.SPBpdpExactMatchNotification="SPBpdpExactMatchNotification",e.SPBActivatedNotification="SPBActivatedNotification",e.SPBConfirmationNotification="SPBConfirmationNotification",e.SPBNudgeExpiryNotification="SPBNudgeExpiryNotification",e.SPBAddToCartNotification="SPBAddToCartNotification",e.SPBSearchAutoActivateNotification="SPBSearchAutoActivateNotification",e.SPBSearchInstantATCNotification="SPBSearchInstantATCNotification",e.QuotientSearchInstantATCNotification="QuotientSearchInstantATCNotification",e.Unknown="",e}({}),d=function(e){return e.Error="Error",e.Negative="Negative",e.Positive="Positive",e.Cancelled="Cancelled",e.InProgress="InProgress",e}({}),u=function(e){return e.CheckoutPage="CheckoutPage",e.ProductPage="ProductPage",e.HomePage="HomePage",e.SearchPage="SearchPage",e.NonShoppingPage="NonShoppingPage",e.UnknownPage="UnknownPage",e.ConfirmationPage="ConfirmationPage",e}({}),h=function(e){return e.Cart="Cart",e.Checkout="Checkout",e.PurchaseConfirmed="PurchaseConfirmed",e.CancellationRequest="CancellationRequest",e.CancellationConfirmed="CancellationConfirmed",e}({}),p=function(e){return e[e.ApplyCouponsMessage=1]="ApplyCouponsMessage",e[e.AutoApplyCompletedMessage=2]="AutoApplyCompletedMessage",e[e.CheckoutPageMessage=3]="CheckoutPageMessage",e[e.CloseOverlayMessage=4]="CloseOverlayMessage",e[e.ClosedPopupMessage=5]="ClosedPopupMessage",e[e.CountElementsResponse=6]="CountElementsResponse",e[e.CreateOverlayMessage=7]="CreateOverlayMessage",e[e.CreatePopupMessage=8]="CreatePopupMessage",e[e.CreatePriceComparisonMessage=9]="CreatePriceComparisonMessage",e[e.EdgeApplyCouponsMessage=10]="EdgeApplyCouponsMessage",e[e.EmptyResponse=11]="EmptyResponse",e[e.ErrorResponse=12]="ErrorResponse",e[e.GetCompetingPricesMessage=13]="GetCompetingPricesMessage",e[e.GetCompetingPricesResponse=14]="GetCompetingPricesResponse",e[e.GetTextValueResponse=15]="GetTextValueResponse",e[e.GetUIStateMessage=16]="GetUIStateMessage",e[e.GetUIStateResponse=17]="GetUIStateResponse",e[e.MoveProgressBarMessage=18]="MoveProgressBarMessage",e[e.ShowResultMessage=19]="ShowResultMessage",e[e.TelemetryMessage=20]="TelemetryMessage",e[e.UpdateCurrentCouponMessage=21]="UpdateCurrentCouponMessage",e[e.OpalMessage=22]="OpalMessage",e[e.ProductPageMessage=23]="ProductPageMessage",e[e.ProductPageResponse=24]="ProductPageResponse",e[e.EdgeCreateOverlayMessage=25]="EdgeCreateOverlayMessage",e[e.EdgeShowResultMessage=26]="EdgeShowResultMessage",e[e.VerifySelectorsMessage=27]="VerifySelectorsMessage",e[e.VerifySelectorsResponse=28]="VerifySelectorsResponse",e[e.AutoApplyCancelledMessage=29]="AutoApplyCancelledMessage",e[e.ContentInitMessage=30]="ContentInitMessage",e[e.ClearDataMessage=31]="ClearDataMessage",e[e.DOMMutationMessage=32]="DOMMutationMessage",e[e.UpdateCurrencyMessage=33]="UpdateCurrencyMessage",e[e.CheckoutProgressMessage=34]="CheckoutProgressMessage",e[e.ECCreateOverlayMessage=35]="ECCreateOverlayMessage",e[e.ECShowResultMessage=36]="ECShowResultMessage",e[e.ECFieldErrorMessage=37]="ECFieldErrorMessage",e[e.ECCreateUpdatePaymentOverlayMessage=38]="ECCreateUpdatePaymentOverlayMessage",e[e.PrintableGroceryCouponsMessage=39]="PrintableGroceryCouponsMessage",e[e.WalletDrawerCreateOverlayMessage=40]="WalletDrawerCreateOverlayMessage",e[e.WalletDrawerCloseMessage=41]="WalletDrawerCloseMessage",e[e.BackgroundAutoApplyCancelledMessage=42]="BackgroundAutoApplyCancelledMessage",e[e.GetCheckedValueResponse=43]="GetCheckedValueResponse",e[e.SelectorSuccessResponse=44]="SelectorSuccessResponse",e[e.SelectorExtractionMessage=45]="SelectorExtractionMessage",e[e.SelectorExtractionResponse=46]="SelectorExtractionResponse",e[e.GetFieldValueResponse=48]="GetFieldValueResponse",e[e.UserAgreementStatusMessage=50]="UserAgreementStatusMessage",e[e.GetTabDataFromBackgroundMessage=51]="GetTabDataFromBackgroundMessage",e[e.GetTabDataFromBackgroundResponse=52]="GetTabDataFromBackgroundResponse",e[e.GetFileContentFromResourcesMessage=53]="GetFileContentFromResourcesMessage",e[e.GetFileContentFromResourcesResponse=54]="GetFileContentFromResourcesResponse",e[e.AutoApplyNotificationSafariMessage=55]="AutoApplyNotificationSafariMessage",e[e.InstantAddToCartMessage=56]="InstantAddToCartMessage",e[e.SetStorageValueMessage=57]="SetStorageValueMessage",e[e.GetStorageValueMessage=58]="GetStorageValueMessage",e[e.GetStorageValueResponse=59]="GetStorageValueResponse",e[e.CouponsClippingNotificationSafariMessage=60]="CouponsClippingNotificationSafariMessage",e[e.RunQuerySelectorAllOnBodyMessage=61]="RunQuerySelectorAllOnBodyMessage",e[e.RunQuerySelectorAllOnBodyResponse=62]="RunQuerySelectorAllOnBodyResponse",e[e.BackgroundExecuteCouponsClippingMessage=63]="BackgroundExecuteCouponsClippingMessage",e[e.ContentExecuteCouponsClippingMessage=64]="ContentExecuteCouponsClippingMessage",e[e.ContentExecuteCouponsClippingResponse=65]="ContentExecuteCouponsClippingResponse",e[e.WalletDrawerSkipCouponMessage=66]="WalletDrawerSkipCouponMessage",e[e.GetSafariLatestVersion=67]="GetSafariLatestVersion",e[e.GetSafariLatestVersionResponse=68]="GetSafariLatestVersionResponse",e[e.SuccessInstantAddToCartMessage=69]="SuccessInstantAddToCartMessage",e[e.RenderSafariTagInDomMessage=70]="RenderSafariTagInDomMessage",e[e.DomFlyoutMessage=71]="DomFlyoutMessage",e[e.GetCouponStatusMessagesResponse=72]="GetCouponStatusMessagesResponse",e[e.UpdateRewardsData=73]="UpdateRewardsData",e}({}),g=function(e){return e.Opal="Opal",e.Extension="Extension",e.SafariExtension="SafariExtension",e.SafariIOSExtension="SafariIOSExtension",e.Edge="Edge",e.EdgeMobile="EdgeMobile",e.Sapphire="Sapphire",e.RBC="RBC",e.EdgeAndroid="EdgeAndroid",e.EdgeiOS="EdgeiOS",e.EdgeDiscover="EdgeDiscover",e}({}),f=function(e){return e.AutoApplyCoupons="AutoApplyCoupons",e.CouponClipping="CouponClipping",e.BackgroundAutoApply="BackgroundAutoApply",e.FallBackAutoApply="FallBackAutoApply",e.ProductPageBackgroundAutoApply="ProductPageBackgroundAutoApply",e.BackgroundAAResult="BackgroundAAResult",e.AutoCouponClipping="AutoCouponClipping",e.ApplyCopiedCoupon="ApplyCopiedCoupon",e.ProductBestCoupon="ProductBestCoupon",e.BestCouponBackgroundAutoApply="BestCouponBackgroundAutoApply",e.ExclusiveCoupon="ExclusiveCoupon",e}({}),m=function(e){return e.Wallet="Wallet",e.Shopping="Shopping",e}({}),v=function(e){return e.AutoApplyTransactionsKey="ListOfAutoApplyTransactions",e.CouponClippingTransactionsKey="ListOfCouponClippingTransactions",e.CashbackTransactionsKey="ListOfCashbackTransactions",e}({}),y=function(e){return e.UserCouponFailed="UserCouponFailed",e.BetterInitialPrice="BetterInitialPrice",e.CouponNotInOurCorpus="CouponNotInOurCorpus",e.ManuallyAppliedCouponNotInOurCorpus="ManuallyAppliedCouponNotInOurCorpus",e.SuggestedCoupon="SuggestedCoupon",e.SuppressedSuggestedCoupons="SuppressedSuggestedCoupons",e}({}),C=function(e){return e.PromotionsDataUpdated="PromotionsDataUpdated",e.PromotionsBannerShown="PromotionsBannerShown",e.OrderPurchased="OrderPurchased",e.RewardsNotificationShown="RewardsNotificationShown",e.ViewRewardsClicked="ViewRewardsClicked",e.RewardsEligibleTowerControl="RewardsEligibleTowerControl",e.RewardsEligibleTowerTreatment="RewardsEligibleTowerTreatment",e}({}),b=function(e){return e.AARewards="AARewards",e}({}),S=function(e){return e.Flyout="Flyout",e.Validator="Validator",e.Driver="Driver",e.Controller="Controller",e}({}),x=function(e){return e.High="High",e.Medium="Medium",e.Low="Low",e.None="None",e}({}),T=function(e){return e[e.PositiveResultShown=6]="PositiveResultShown",e[e.NegativeResultShown=7]="NegativeResultShown",e[e.PositiveResultClicked=10]="PositiveResultClicked",e[e.NegativeResultClicked=11]="NegativeResultClicked",e}({}),w=function(e){return e.Bing="Bing",e.Edge="Edge",e}({}),O=function(e){return e.Zero="=0",e.One="=1",e.OneString="one",e.Few="few",e.Many="many",e.Other="other",e}({}),P=function(e){return e.LostUsers="Lost User Preference Override",e.LostUsersControl="Lost User Preference Override - Control Log",e}({}),A=function(e){return e.lostUsers="blocked but recovered",e.lostUsersRegular="Eligible for recovering",e}({})},56019:function(e,t,i){"use strict";i.d(t,{x:function(){return n}});let n=function(e){return e.GetBoxValue="GetBoxValue",e.GetCurrentCheckoutPage="GetCurrentCheckoutPage",e.BetterInitialPrice="BetterInitialPrice",e.CheckoutPageWithoutCoupons="CheckoutPageWithoutCoupons",e.AutoApplyWithoutCoupons="AutoApplyWithoutCoupons",e.AutoApplyWithoutCheckout="AutoApplyWithoutCheckout",e.RemoveCouponFailure="RemoveCouponFailure",e.ApplyButtonUndefined="ApplyButtonUndefined",e.InputUndefined="InputUndefined",e.GetAppliedCoupon="GetAppliedCoupon",e.CouponClippingFailed="CouponClippingFailed",e.OtherSellerFailed="OtherSellerFailed",e.ContinueButtonUndefined="ContinueButtonUndefined",e.ECIframeResponseNotReceived="ECIframeResponseNotReceived",e.ECFrameNameUndefined="ECFrameNameUndefined",e.ECFrameOriginMisMatch="ECFrameOriginMisMatch",e.ExpressCheckoutBNPLFailed="ExpressCheckoutBNPLFailed",e.ErrorParsingBackgroundAutoApplyState="ErrorParsingBackgroundAutoApplyState",e.ExpiredBackgroundAAState="ExpiredBackgroundAAState",e.GetSuggestedCoupon="GetSuggestedCoupon",e.UndefinedState="UndefinedState",e.DomainDisabled="DomainDisabled",e.BackgroundAAError="BackgroundAAError",e.BackgroundAAPDPDisabled="BackgroundAAPDPDisabled",e.SavingsFoundTransactionFailure="SavingsFoundTransactionFailure",e.ApplyButtonDisabled="ApplyButtonDisabled",e.ContinueButtonDisabled="ContinueButtonDisabled",e.CartBlockedCoupons="CartBlockedCoupons",e}({})},5491:function(e,t,i){"use strict";i.d(t,{V:function(){return o}});var n=i(72370);class o{constructor(){(0,n.Z)(this,"discount",void 0),(0,n.Z)(this,"initialPrice",void 0)}}},93078:function(e,t,i){"use strict";i.d(t,{B:function(){return r},v:function(){return o}});var n=i(72370);let o=function(e){return e[e.Clipping=0]="Clipping",e[e.OtherSellers=1]="OtherSellers",e[e.BackgroundAA=2]="BackgroundAA",e[e.PDPconsentAA=3]="PDPconsentAA",e[e.ApplyClickedCoupon=4]="ApplyClickedCoupon",e[e.ItemizedCashbackAddToCart=5]="ItemizedCashbackAddToCart",e[e.ScrollToItem=6]="ScrollToItem",e[e.InstantAddToCart=8]="InstantAddToCart",e[e.ApplyProductBestCoupon=9]="ApplyProductBestCoupon",e[e.ApplyExclusiveCoupon=10]="ApplyExclusiveCoupon",e}({});class r{constructor(){(0,n.Z)(this,"action",void 0),(0,n.Z)(this,"data",void 0)}}},93190:function(e,t,i){"use strict";i.d(t,{p:function(){return n}});let n=function(e){return e[e.COUPONS_CLIPPING=0]="COUPONS_CLIPPING",e[e.OTHER_SELLERS=1]="OTHER_SELLERS",e[e.OTHER_SELLERS_CONFIRMATION=2]="OTHER_SELLERS_CONFIRMATION",e[e.EXCLUSIVE_COUPONS=3]="EXCLUSIVE_COUPONS",e[e.OTHER_SELLERS_TRIGGER=4]="OTHER_SELLERS_TRIGGER",e[e.ATTAINABLE_COUPONS=5]="ATTAINABLE_COUPONS",e[e.REWARDS_GIFT_CARD=6]="REWARDS_GIFT_CARD",e[e.PRINT_GROCERY=7]="PRINT_GROCERY",e[e.GROCERY_ITEMIZED_CASHBACK=8]="GROCERY_ITEMIZED_CASHBACK",e[e.AUTOS_MARKETPLACE=9]="AUTOS_MARKETPLACE",e[e.ABANDONED_CART=11]="ABANDONED_CART",e[e.PRODUCT_TRACKING_OUT_OF_STOCK=12]="PRODUCT_TRACKING_OUT_OF_STOCK",e[e.GROCERY_ITEMIZED_CASHBACK_LANDING=13]="GROCERY_ITEMIZED_CASHBACK_LANDING",e[e.SPB_CASHBACK_LANDING=14]="SPB_CASHBACK_LANDING",e[e.AA_CONSENT=16]="AA_CONSENT",e}({})},54380:function(e,t,i){"use strict";i.d(t,{Q:function(){return n},_:function(){return o}});let n=function(e){return e.UserId="userId",e.ActiveUrl="activeUrl",e.LocalizedStrings="LocalizedStrings",e.ClientName="ClientName",e.ImportOptions="ImportOptions",e.Icon="Icon",e.AppName="AppName",e.CashBackActive="CashBackActive",e.NudgeTips="NudgeTips",e.CheckoutUserData="CheckoutUserData",e.CheckoutElementsData="CheckoutElementsData",e.ExpressCheckoutState="ExpressCheckoutState",e.BackgroundAutoApply="BackgroundAutoApply",e.ForegroundAutoApply="ForegroundAutoApply",e.FallBackAutoApply="FallBackAutoApply",e.ProductPageBackgroundAutoApply="ProductPageBackgroundAutoApply",e.ApiResponse="ApiResponse",e.UseWalletDrawer="UseWalletDrawer",e.ExpressCheckoutGMVData="ExpressCheckoutGMVData",e.BackgroundAutoApplyState="BackgroundAutoApplyState",e.AutoOpenData="AutoOpenData",e.LastCleanedData="LastCleanedData",e.DynamicSelectors="DynamicSelectors",e.EstimatedCashback="EstimatedCashback",e.CashbackAmount="CashbackAmount",e.Experiments="Experiments",e.ImpressionId="ImpressionId",e.CashbackShouldStandDown="CashbackShouldStandDown",e.WalletDrawerShouldSkipCoupon="WalletDrawerShouldSkipCoupon",e.InboxCouponsHashedUserId="InboxCouponsHashedUserId",e.InboxCouponsUserHashedEmail="InboxCouponsUserHashedEmail",e.CashBackOfferDetailsVisible="CashBackOfferDetailsVisible",e.AAEarlyReturnVariant="AAEarlyReturnVariant",e.BestCouponBackgroundAutoApply="BestCouponBackgroundAutoApply",e.DelayedCashbackActivatedDomains="DelayedCashbackActivatedDomains",e.OtherSellersAddedToCartDataKey="OtherSellersAddedToCartData",e.HasVisitedCashbackTab="HasVisitedCashbackTab",e}({}),o=function(e){return e.StopRefreshTimeout="StopRefreshTimeout",e.InboxCouponsUpsellOpen="inboxCouponsUpsellOpen",e}({})},93608:function(e,t,i){"use strict";i.d(t,{d:function(){return n}});let n=function(e){return e.NotSuggestedCoupon="NotSuggestedCoupon",e.NewSuggestedCoupon="NewSuggestedCoupon",e.ExistingSuggestedCoupon="ExistingSuggestedCoupon",e}({})},39088:function(e,t,i){"use strict";i.d(t,{HQ:function(){return s},Kr:function(){return o},T_:function(){return r},W1:function(){return n},yJ:function(){return a}});const n="2.363",o="3.518",r="2.514",a="2.997",s="1.613"},21488:function(e,t,i){"use strict";var n=i(72370),o=i(29247);class r{constructor(){(0,n.Z)(this,"isPersonalizationDataConsentEnabled",void 0),(0,n.Z)(this,"isPersonalizationDataConsentChanged",void 0),(0,n.Z)(this,"isAnonymousFlowEnabled",void 0),(0,n.Z)(this,"isBingSignedInUser",void 0),(0,n.Z)(this,"isMSASignedIn",void 0),(0,n.Z)(this,"isSSOEnabled",void 0),(0,n.Z)(this,"isRebatesUser",void 0),(0,n.Z)(this,"ageGroup",void 0),(0,n.Z)(this,"anonymousUserId",""),(0,n.Z)(this,"isAadEmailPresent",!1),(0,n.Z)(this,"isAADSignedIn",void 0),(0,n.Z)(this,"isMarketingCampaignEventEnrolled",void 0),(0,n.Z)(this,"isCashbackPlatformAcknowledged",void 0),(0,n.Z)(this,"isAADLinkedAccountValid",void 0),(0,n.Z)(this,"isLinkingPolicyEnabled",void 0),(0,n.Z)(this,"hanid",void 0)}static Create(e,t,i,n,a){const s=new r;return s.isRebatesUser=t||e?.cashback?.userRebateResponse?.isRebatesUser||!1,s.isBingSignedInUser=e?.userInfo?.isBingSignedInUser??!1,s.isMSASignedIn=e?.userInfo?.isMSASignedIn??!1,s.isSSOEnabled=e?.userInfo?.isSSOEnabled??!1,s.isPersonalizationDataConsentEnabled=e?.userInfo?.isPersonalizationDataConsentEnabled??!1,s.isPersonalizationDataConsentChanged=e?.userInfo?.isPersonalizationDataConsentChanged??!1,s.ageGroup=e?.userInfo?.ageGroup??void 0,s.isAnonymousFlowEnabled=e?.itemLevelCashBack?.isAnonymousFlowEnabled??!1,s.isAadEmailPresent=!!i,s.isAADSignedIn=e?.userInfo?.isAADSignedIn??!1,s.isMarketingCampaignEventEnrolled=e?.promotionalCampaignDealsResponse?.isEnrolled,s.isCashbackPlatformAcknowledged=e?.promotionalCampaignDealsResponse?.isCashbackPlatformAcknowledged,s.isAADLinkedAccountValid=o.ZP.parseBool(n)||e?.userInfo?.isAADLinkedAccountValid||!1,s.isLinkingPolicyEnabled=o.ZP.parseBool(a),s.hanid=e?.userInfo?.hanid??"",s}}t.Z=r},3634:function(e,t,i){"use strict";i.d(t,{$S:function(){return s},Jg:function(){return d},LJ:function(){return u},P5:function(){return c},PK:function(){return b},RY:function(){return o},SY:function(){return f},T2:function(){return v},Z3:function(){return r},d1:function(){return p},dX:function(){return g},eS:function(){return m},fU:function(){return y},js:function(){return a},kH:function(){return S},m7:function(){return l},oL:function(){return x},uv:function(){return C},wB:function(){return h}});var n=i(5144);n.BN.EdgeMobile,n.BN.EdgeAndroid,n.BN.EdgeiOS;n.BN.Edge;const o=new Set(["amazon.com","amazon.ca","amazon.co.uk","amazon.co.jp","alibaba.com"]),r=new Map(Object.entries({"etsy.com":"receipt_id","target.com":"referenceId","tmall.com":"bizOrderId"})),a="GET_ORDER_ID_FROM_URL",s="GET_TRANSACTION_ID_FROM_URL",l="GET_TRANSACTION_ID_FROM_PATH_URL",c="<TRANSACTION_ID>",d=864e5,u=216e5,h=3456e5,p="isRecommendationsModulePrioritized",g=5,f=90,m="microsoft exclusive offer",v="lateAutoOpenEvent",y="spbCartResponseEvent",C="COMPONENT_TO_FOCUS_IN_SHORELINE",b={"bestbuy.com":{policyDays:15,supportPageUrl:"https://www.bestbuy.com/site/help-topics/price-match-guarantee/pcmcat290300050002.c?id=pcmcat290300050002"},"costco.com":{policyDays:30,supportPageUrl:"https://customerservice.costco.com/app/answers/detail/a_id/628/~/price-adjustment---costco.com-orders",useCartAtPathname:"/checkoutcartdisplayview"},"kohls.com":{policyDays:14,supportPageUrl:"https://cs.kohls.com/app/answers/detail/a_id/90/~/price-match-policy"},"target.com":{policyDays:14,supportPageUrl:"https://help.target.com/help/subcategoryarticle?childcat=Price+Match+Guarantee&parentcat=Policies+%26+Guidelines&searchQuery=search+help",useCartAtPathname:"/cart"},"dickssportinggoods.com":{policyDays:14,supportPageUrl:"https://www.dickssportinggoods.com/s/price-match-policy",useCartAtPathname:"/orderitemdisplay"},"jcpenney.com":{policyDays:14,supportPageUrl:"https://www.jcpenney.com/m/customer-service/our-lowest-price-guarantee"},"macys.com":{policyDays:10,supportPageUrl:"https://customerservice-macys.com/articles/how-can-i-get-a-price-adjustment",useCartAtPathname:"/my-bag",hasCsrError:!0},"ashleyfurniture.com":{policyDays:30,supportPageUrl:"https://www.ashleyfurniture.com/price-match/"},"gap.com":{policyDays:14,supportPageUrl:"https://www.gap.com/customerService/info.do?cid=1192378"},"staples.com":{policyDays:14,supportPageUrl:"https://www.staples.com/sbd/cre/marketing/pmg/index.html"}},S=Object.keys(b),x="consented"},21597:function(e,t,i){"use strict";i.d(t,{$R:function(){return r},aE:function(){return o}});var n=i(72370);let o=function(e){return e[e.api_response=0]="api_response",e[e.nagivation_guid=1]="nagivation_guid",e[e.disabled_scenarios=2]="disabled_scenarios",e[e.enabled_features=3]="enabled_features",e[e.storage_param=4]="storage_param",e[e.auto_show_enabled=5]="auto_show_enabled",e[e.snoozed_values=6]="snoozed_values",e[e.disable_popup_originations_for_current_domain=7]="disable_popup_originations_for_current_domain",e[e.is_off_the_record=8]="is_off_the_record",e[e.is_bing_identity_valid_for_enroll=9]="is_bing_identity_valid_for_enroll",e[e.is_rebates_active=10]="is_rebates_active",e[e.is_rebates_activation_pending_for_last_committed_url=11]="is_rebates_activation_pending_for_last_committed_url",e[e.allow_organic_rebates=12]="allow_organic_rebates",e[e.get_activate_rebates_status=13]="get_activate_rebates_status",e[e.is_bing_rebates_flow=14]="is_bing_rebates_flow",e[e.is_personalized_cashback_active=15]="is_personalized_cashback_active",e[e.is_bing_ad_referred=16]="is_bing_ad_referred",e[e.has_msa_profile=17]="has_msa_profile",e[e.has_bing_campaign_guid=18]="has_bing_campaign_guid",e[e.show_rewards_coachmark=19]="show_rewards_coachmark",e[e.should_stand_down=20]="should_stand_down",e[e.personalization_in_context_can_prompt=21]="personalization_in_context_can_prompt",e[e.user_info=22]="user_info",e[e.enabled_service_flights=23]="enabled_service_flights",e[e.enabled_service_features=24]="enabled_service_features",e[e.is_checkout_page_using_url_match=25]="is_checkout_page_using_url_match",e[e.has_autofill_data=26]="has_autofill_data",e[e.is_personalized_cashback_enabled=27]="is_personalized_cashback_enabled",e[e.pane_state=28]="pane_state",e[e.is_edge_shopping_flag=29]="is_edge_shopping_flag",e[e.is_edge_profile=30]="is_edge_profile",e[e.edge_profile_data=31]="edge_profile_data",e[e.is_ax_shop_enabled_with_detected_screen_reader=32]="is_ax_shop_enabled_with_detected_screen_reader",e[e.discover_state=33]="discover_state",e[e.session_ids=34]="session_ids",e[e.package_tracking_data=35]="package_tracking_data",e[e.bing_redirect_chain=36]="bing_redirect_chain",e[e.enabled_service_features_v2=37]="enabled_service_features_v2",e[e.cjk_params=38]="cjk_params",e[e.user_cohort_data=39]="user_cohort_data",e}({}),r=function(e){return e[e.api_response=0]="api_response",e[e.nagivation_guid=1]="nagivation_guid",e[e.enabled_features=2]="enabled_features",e[e.storage_param=3]="storage_param",e[e.import_options=4]="import_options",e[e.user_info=6]="user_info",e[e.enabled_service_flights=7]="enabled_service_flights",e[e.enabled_service_features=8]="enabled_service_features",e[e.has_autofill_data=10]="has_autofill_data",e[e.checkout_enabled_service_features_v2=13]="checkout_enabled_service_features_v2",e[e.checkout_user_cohort_data=14]="checkout_user_cohort_data",e[e.confirmation_enabled_service_features_v2=17]="confirmation_enabled_service_features_v2",e[e.confirmation_user_cohort_data=18]="confirmation_user_cohort_data",e}({});t.ZP=class{constructor(){(0,n.Z)(this,"blockedList",void 0),(0,n.Z)(this,"paths",void 0),this.blockedList=[],this.paths=new Map}}},87720:function(e,t,i){"use strict";i.d(t,{CR:function(){return a},Gr:function(){return r},Nv:function(){return h},Q5:function(){return o},Sk:function(){return c},Zs:function(){return p},cv:function(){return l},fX:function(){return s},n1:function(){return d},z0:function(){return u}});var n=i(72370);const o="AutoOpenData",r="LastCleanedData",a="TotalNegativeEngagementData",s="EngagementDataKey",l="AutoOpenPrefData",c="AutoOpenDomainPrefData",d="LastShownData",u="StageAndCategoryLastShown",h="PopupOrigination",p=1728e5;t.ZP=class{constructor(){(0,n.Z)(this,"popupOrigination",void 0),(0,n.Z)(this,"timeLastAutoOpen",void 0),(0,n.Z)(this,"snoozeTime",void 0),(0,n.Z)(this,"blockedForSite",void 0),(0,n.Z)(this,"lostUserReblockedTime",void 0)}}},3141:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(){(0,n.Z)(this,"blockedListPath",void 0)}}},50033:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(){(0,n.Z)(this,"timeLastAutoOpen",void 0),(0,n.Z)(this,"categoryName",void 0)}}},20400:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(){(0,n.Z)(this,"categoriesBlocked",void 0)}}},35386:function(e,t,i){"use strict";i.d(t,{v:function(){return n}});let n=function(e){return e[e.UNDEFINED=0]="UNDEFINED",e[e.DISCOVER=1]="DISCOVER",e[e.RESEARCH=2]="RESEARCH",e[e.DECISION=3]="DECISION",e[e.PURCHASE=4]="PURCHASE",e[e.POST_PURCHASE=5]="POST_PURCHASE",e}({})},11050:function(e,t,i){"use strict";i.d(t,{h:function(){return n}});let n=function(e){return e.Quotient="q",e.Ibotta="i",e.Self="s",e.FirstParty="1p",e.SPB="spb",e.Unknown="unknown",e}({})},88767:function(e,t,i){"use strict";i.d(t,{$U:function(){return k},$k:function(){return x},AS:function(){return a},Bl:function(){return v},CS:function(){return r},De:function(){return w},Ee:function(){return m},Ex:function(){return s},FA:function(){return b},Fh:function(){return _},H7:function(){return f},Hp:function(){return L},J_:function(){return Z},Jk:function(){return E},M$:function(){return O},ModuleNames:function(){return y},N:function(){return R},P1:function(){return H},Q2:function(){return l},SV:function(){return T},Te:function(){return h},UB:function(){return B},VG:function(){return A},YO:function(){return d},_E:function(){return F},aE:function(){return S},aM:function(){return n},d$:function(){return M},fk:function(){return U},iM:function(){return p},jB:function(){return $},lg:function(){return V},lp:function(){return P},m5:function(){return u},sM:function(){return C},tl:function(){return D},vu:function(){return g},yA:function(){return I},z6:function(){return N},zE:function(){return c},zz:function(){return o}});let n=function(e){return e.Large="txtLarge",e.Medium="txtMedium",e.Small="txtSmall",e.XSmall="txtXSmall",e.EmptyCoupon="txtEmptyCoupons",e.EmptyCouponCjk="txtEmptyCouponsCjk",e}({}),o=function(e){return e.AutoOpen="AutoOpen",e.SaveMoneyPage="SaveMoneyPage",e.SaveMoneyOtherSites="SaveMoneyOtherSites",e.SaveMoneyRetailer="SaveMoneyRetailer",e.InformPage="InformPage",e.InformRetailer="InformRetailer",e.InformOtherSites="InformOtherSites",e.Unknown="Unknown",e}({}),r=function(e){return e[e.COUPON=4]="COUPON",e[e.SOCIAL_COUPONS=2]="SOCIAL_COUPONS",e[e.COUPONPANE=4]="COUPONPANE",e[e.DEAL=2]="DEAL",e[e.PRICECOMPARISON=4]="PRICECOMPARISON",e[e.RECOMMENDATIONS=4]="RECOMMENDATIONS",e[e.RECOMMENDATIONS_NOTIF=2]="RECOMMENDATIONS_NOTIF",e[e.SEARCH_SUGGESTIONS=6]="SEARCH_SUGGESTIONS",e[e.SIMILARSELLERS=1]="SIMILARSELLERS",e[e.PRODUCTHISTORY=3]="PRODUCTHISTORY",e[e.SHOPPING_TRIPS=3]="SHOPPING_TRIPS",e[e.PAYMENT_OPTIONS=3]="PAYMENT_OPTIONS",e[e.ORDERTRACKING=1]="ORDERTRACKING",e[e.GROCERY_COUPON=4]="GROCERY_COUPON",e[e.PRINTABLE_COUPON=4]="PRINTABLE_COUPON",e[e.PRINTABLE_COUPON_AUTO=2]="PRINTABLE_COUPON_AUTO",e[e.GROCERY_CASHBACK=4]="GROCERY_CASHBACK",e[e.PREVIOUS_CASHBACK=1]="PREVIOUS_CASHBACK",e[e.PREVIOUS_CASHBACKREFRESH=3]="PREVIOUS_CASHBACKREFRESH",e[e.AUTOSMARKETPLACE=3]="AUTOSMARKETPLACE",e[e.ABANDONED_CART=1]="ABANDONED_CART",e[e.TRACKED_PRODUCTS=3]="TRACKED_PRODUCTS",e[e.TRENDING_COUPONS=2]="TRENDING_COUPONS",e[e.TRENDING_COUPONS_PANE=3]="TRENDING_COUPONS_PANE",e[e.TWO_COUPON_ON_START=2]="TWO_COUPON_ON_START",e[e.CJK_SIMILAR_PRODUCTS=10]="CJK_SIMILAR_PRODUCTS",e}({}),a=function(e){return e[e.Desktop=1]="Desktop",e[e.Mobile=2]="Mobile",e}({}),s=function(e){return e[e.OfferActivated=1]="OfferActivated",e[e.MerchantProcessing=2]="MerchantProcessing",e[e.CashBackReceived=3]="CashBackReceived",e}({}),l=function(e){return e[e.Dark=1]="Dark",e[e.Light=2]="Light",e}({}),c=function(e){return e.PRICE_COMPARISON="Mainline",e.PRICE_COMPARISON_FREE="FreeAdMiddle",e.SIMILAR_OFFERS="SimilarMainline",e.SIMILAR_OFFERS_FREE="SimilarFreeAdMiddle",e.SPB_OFFERS="SponsoredPromotionsBrandMainline",e.NOT_SPECIFIED="NOT_SPECIFIED",e}({}),d=function(e){return e.Paid="cpc",e.Backfill="backfill",e.NoCharge="no charge",e.Affiliated="affiliate",e}({}),u=function(e){return e[e.LTR=1]="LTR",e[e.RTL=2]="RTL",e}({}),h=function(e){return e.Mouse="mouse",e.Keyboard="keyboard",e.Auto="auto",e.Banner="banner",e.Hover="hover",e}({}),p=function(e){return e.currency="placeholderCurrency",e}({}),g=function(e){return e.Shipping="shipping",e.Used="Used",e.New="New",e.Refurbished="Refurbished",e.PriceDrop="price drop",e}({}),f=function(e){return e[e.PRODUCTSUMMARYCARD=1]="PRODUCTSUMMARYCARD",e[e.DISCOVER_CHAT_CHIPS=1.1]="DISCOVER_CHAT_CHIPS",e[e.SAN_CONSENT=1.2]="SAN_CONSENT",e[e.AX_SHOPPING_NAV=1.3]="AX_SHOPPING_NAV",e[e.PRODUCT_SUMMARY=1.31]="PRODUCT_SUMMARY",e[e.SMART_COMPARE=1.4]="SMART_COMPARE",e[e.USER_INSIGHTS=1.41]="USER_INSIGHTS",e[e.EXPERT_INSIGHTS=1.42]="EXPERT_INSIGHTS",e[e.AMAZON_DEALS_DAY=1.5]="AMAZON_DEALS_DAY",e[e.CAMPAIGN_PDP_CASHBACK=1.51]="CAMPAIGN_PDP_CASHBACK",e[e.CAMPAIGN_BANNER=1.52]="CAMPAIGN_BANNER",e[e.FEED_CAMPAIGN=1.53]="FEED_CAMPAIGN",e[e.TRAVEL_CHEAPER_FLIGHTS=1.61]="TRAVEL_CHEAPER_FLIGHTS",e[e.POST_PURCHASE_REWARDS=1.62]="POST_PURCHASE_REWARDS",e[e.BUYING_GUIDES=1.8]="BUYING_GUIDES",e[e.PRINTABLE_COUPON=2]="PRINTABLE_COUPON",e[e.BGAA=2.5]="BGAA",e[e.GROCERY_COUPON=3]="GROCERY_COUPON",e[e.COUPONCLIPPING=4]="COUPONCLIPPING",e[e.SIMILARSELLERS=5]="SIMILARSELLERS",e[e.IC_CASHBACK=5.5]="IC_CASHBACK",e[e.GROCERY_CASHBACK=6]="GROCERY_CASHBACK",e[e.GROCERY_CASHBACK_PENDING=7.5]="GROCERY_CASHBACK_PENDING",e[e.COUPON=8]="COUPON",e[e.ACTIVE_RETAILER_INBOX_COUPONS=9]="ACTIVE_RETAILER_INBOX_COUPONS",e[e.PRICEHISTORY=10]="PRICEHISTORY",e[e.PRODUCT_TRACKING=10.5]="PRODUCT_TRACKING",e[e.PRICECOMPARISON=11]="PRICECOMPARISON",e[e.CJK_PRICECOMPARISON=11.1]="CJK_PRICECOMPARISON",e[e.WISHLIST=11.3]="WISHLIST",e[e.SIMILAR_OFFERS=11.5]="SIMILAR_OFFERS",e[e.VISUAL_SEARCH=11.7]="VISUAL_SEARCH",e[e.RELATED_PRODUCTS=11.8]="RELATED_PRODUCTS",e[e.CASHBACK=12.5]="CASHBACK",e[e.GROCERY_DIFFERENT_PRODUCT=13]="GROCERY_DIFFERENT_PRODUCT",e[e.DEALS=14]="DEALS",e[e.RECOMMENDATIONS=16]="RECOMMENDATIONS",e[e.ORDERSTATUSTRACKING=17]="ORDERSTATUSTRACKING",e[e.SHOPRUNNER=18]="SHOPRUNNER",e[e.TIPS=20]="TIPS",e[e.REWARD=21]="REWARD",e[e.PAYMENT_OPTIONS=22]="PAYMENT_OPTIONS",e[e.VIRTUAL_CARD=23]="VIRTUAL_CARD",e[e.SOCIALCOUPONS=24]="SOCIALCOUPONS",e[e.MOMENT_IN_TIME=25.5]="MOMENT_IN_TIME",e[e.PINTEREST=26]="PINTEREST",e[e.AUTOSMYGARAGE=27]="AUTOSMYGARAGE",e[e.AUTOSMARKETPLACE=27.05]="AUTOSMARKETPLACE",e[e.AUTOSREVIEWS=27.1]="AUTOSREVIEWS",e[e.ABANDONED_CART=28]="ABANDONED_CART",e[e.PRODUCTHISTORY=29]="PRODUCTHISTORY",e[e.PRODUCT_COLLECTIONS=29.3]="PRODUCT_COLLECTIONS",e[e.SHOPPING_TRIPS=29.5]="SHOPPING_TRIPS",e[e.INBOX_COUPONS=29.75]="INBOX_COUPONS",e[e.TRENDING_COUPONS_ON_HOME_TAB=29.65]="TRENDING_COUPONS_ON_HOME_TAB",e[e.TRENDING_OFFERS=30]="TRENDING_OFFERS",e[e.BUY_DIRECT=30.05]="BUY_DIRECT",e[e.DAILY_DEALS=31]="DAILY_DEALS",e[e.CJK_SIMILAR_PRODUCTS=32]="CJK_SIMILAR_PRODUCTS",e[e.CASHBACK_DASHBOARD=32.1]="CASHBACK_DASHBOARD",e[e.TRENDING_COUPONS=98.5]="TRENDING_COUPONS",e[e.TRENDING_OFFERS_ON_CONTEXTUAL_TAB=98.7]="TRENDING_OFFERS_ON_CONTEXTUAL_TAB",e[e.EMPTYCOUPON=99]="EMPTYCOUPON",e[e.SUSTAINABILITY=100]="SUSTAINABILITY",e[e.MAX=100]="MAX",e}({}),m=function(e){return e.CANARY="canary",e.DEV="dev",e.STABLE="stable",e}({}),v=function(e){return e.PRICECOMPARISON="3",e.PRICEHISTORY="4",e}({}),y=function(e){return e.COUPON="COUPON",e.PRICECOMPARISON="PRICECOMPARISON",e.SIMILAR_OFFERS="SIMILAR_OFFERS",e.CASHBACK="CASHBACK",e.UNIFIED_CASHBACK="UNIFIED_CASHBACK",e.CASHBACK_ACTIVATE="CASHBACK_ACTIVATE",e.CASHBACK_DELAYED_ENROLLMENT="CASHBACK_DELAYED_ENROLLMENT",e.EMPTYCOUPON="EMPTYCOUPON",e.PRICEHISTORY="PRICEHISTORY",e.COUPONCLIPPING="COUPONCLIPPING",e.DEALS="DEALS",e.RECOMMENDATIONS="RECOMMENDATIONS",e.SIMILARSELLERS="SIMILARSELLERS",e.PRODUCTHISTORY="PRODUCTHISTORY",e.REWARD="REWARD",e.PRODUCTSUMMARYCARD="PRODUCTSUMMARYCARD",e.PAYMENT_OPTIONS="PAYMENT_OPTIONS",e.SOCIALCOUPONS="SOCIALCOUPONS",e.ORDERSTATUSTRACKING="ORDERSTATUSTRACKING",e.VIRTUAL_CARD="VIRTUAL_CARD",e.SUSTAINABILITY="SUSTAINABILITY",e.PRINTABLE_COUPON="PRINTABLE_COUPON",e.TRACKING_CONFIRMATION="TRACKING_CONFIRMATION",e.FEEDBACK="FEEDBACK",e.ViewedProductPriceDrop="ViewedProductPriceDrop",e.PINTEREST="PINTEREST",e.GROCERY_CASHBACK="GROCERY_CASHBACK",e.GROCERY_CASHBACK_PENDING="GROCERY_CASHBACK_PENDING",e.AUTOSMARKETPLACE="AUTOSMARKETPLACE",e.AUTOSMYGARAGE="AUTOSMYGARAGE",e.AUTOSREVIEWS="AUTOSREVIEWS",e.MOMENT_IN_TIME="MOMENT_IN_TIME",e.TRENDING_OFFERS="TRENDING_OFFERS",e.TRENDING_OFFERS_ON_CONTEXTUAL_TAB="TRENDING_OFFERS_ON_CONTEXTUAL_TAB",e.DAILY_DEALS="DAILY_DEALS",e.RELATED_PRODUCTS="RELATED_PRODUCTS",e.VISUAL_SEARCH="VISUAL_SEARCH",e.INFINITE_CATEGORY_FEED="INFINITE_CATEGORY_FEED",e.BUY_DIRECT="BUY_DIRECT",e.PRODUCT_COLLECTIONS="PRODUCT_COLLECTIONS",e.SHOPPING_TRIPS="SHOPPING_TRIPS",e.ABANDONED_CART="ABANDONED_CART",e.PRODUCT_TRACKING_OUT_OF_STOCK="PRODUCT_TRACKING_OUT_OF_STOCK",e.PRODUCT_TRACKING_PRICE_DROP="PRODUCT_TRACKING_PRICE_DROP",e.ITEMIZED_CASHBACK="ITEMIZED_CASHBACK",e.DISCOVER_CHAT_CHIPS="DISCOVER_CHAT_CHIPS",e.SMART_COMPARE="SMART_COMPARE",e.USER_INSIGHTS="USER_INSIGHTS",e.EXPERT_INSIGHTS="EXPERT_INSIGHTS",e.PRODUCT_SUMMARY="PRODUCT_SUMMARY",e.BUYING_GUIDES="BUYING_GUIDES",e.INBOX_COUPONS="INBOX_COUPONS",e.ACTIVE_RETAILER_INBOX_COUPONS="ACTIVE_RETAILER_INBOX_COUPONS",e.TRENDING_COUPONS="TRENDING_COUPONS",e.SOCIALCOUPONS_PERSISTENT="SOCIALCOUPONS_PERSISTENT",e.SAN_CONSENT="SAN_CONSENT",e.SEARCH_RESULTS="SEARCH_RESULTS",e.SEARCH_IN_PANE="SEARCH_IN_PANE",e.SIDEPANE_CASHBACK="SIDEPANE_CASHBACK",e.AX_SHOPPING_NAV="AX_SHOPPING_NAV",e.SAFARI_FIRST_RUN_EXPERIENCE="SAFARI_FIRST_RUN_EXPERIENCE",e.CAMPAIGN_PDP_CASHBACK="CAMPAIGN_PDP_CASHBACK",e.CAMPAIGN_BANNER="CAMPAIGN_BANNER",e.FEED_CAMPAIGN="FEED_CAMPAIGN",e.WISHLIST="WISHLIST",e.CJK_SIMILAR_PRODUCTS="CJK_SIMILAR_PRODUCTS",e.PRODUCT_BEST_COUPON="PRODUCT_BEST_COUPON",e.MENU="MENU",e.PRODUCT_TRACKING_ALERT="PRODUCT_TRACKING_ALERT",e.SAFARI_NULL_STATE="SAFARI_NULL_STATE",e.TRAVEL_CHEAPER_FLIGHT="TRAVEL_CHEAPER_FLIGHT",e.BACKGROUND_AUTO_APPLY="BACKGROUND_AUTO_APPLY",e.POST_PURCHASE_REWARDS="POST_PURCHASE_REWARDS",e.CASHBACK_DASHBOARD="CASHBACK_DASHBOARD",e}({}),C=function(e){return e.CASHBACK="CASHBACK",e.CASHBACK_DASHBOARD="CASHBACK_DASHBOARD",e.UNIFIED_CASHBACK="UNIFIED_CASHBACK",e.CASHBACKCONFIRMATION="CASHBACKCONFIRMATION",e.CASHBACKTURNEDOFF="CASHBACKTURNEDOFF",e.CASHBACK_CHECKOUT_NOTIFICATION="CASHBACK_CHECKOUT_NOTIFICATION",e.CASHBACK_PDP_NOTIFICATION="CASHBACK_PDP_NOTIFICATION",e.REWARD="REWARD",e.SIMILARSELLERS_NOTIFICATION="SIMILARSELLERS_NOTIFICATION",e.SIMILARSELLERS_CONFIRMATION_NOTIFICATION="SIMILARSELLERS_CONFIRMATION_NOTIFICATION",e.PRICECOMPARISON="PRICECOMPARISON",e.SOCIALCOUPONS="SOCIALCOUPONS",e.TRACKING_CONFIRMATION="TRACKING_CONFIRMATION",e.VIRTUAL_CARD="VIRTUAL_CARD",e.ViewedProductPriceDrop="ViewedProductPriceDrop",e.SUSTAINABILITY="SUSTAINABILITY_NOTIFICATION",e.AUTOSMARKETPLACE_NOTIFICATION="AUTOSMARKETPLACE_NOTIFICATION",e.AUTOSREVIEW_NOTIFICATION="AUTOSREVIEW_NOTIFICATION",e.GROCERY_CASHBACK_NOTIFICATION="GROCERY_CASHBACK_NOTIFICATION",e.GROCERY_CASHBACK_PENDING_NOTIFICATION="GROCERY_CASHBACK_PENDING_NOTIFICATION",e.ITEMIZED_CASHBACK_NOTIFICATION="ITEMIZED_CASHBACK_NOTIFICATION",e.PRICEHISTORY="PRICEHISTORY",e.COUPON="COUPON",e.RECOMMENDATION="RECOMMENDATION",e.PRICE_DROP_PLUS_COUPONS_COMPOSITE="PRICE_DROP_PLUS_COUPONS_COMPOSITE",e.CASHBACK_PLUS_COUPONS_COMPOSITE="CASHBACK_PLUS_COUPONS_COMPOSITE",e.PRICE_DROP_PLUS_CASHBACK="PRICE_DROP_PLUS_CASHBACK",e.LOWER_PRICE_PLUS_CASHBACK_PLUS_COUPONS_COMPOSITE="LOWER_PRICE_PLUS_CASHBACK_PLUS_COUPONS_COMPOSITE",e.ABANDONED_CART="ABANDONED_CART",e.PRODUCT_TRACKING_OFFERS_COUPON_NOTIFICATION="PRODUCT_TRACKING_OFFERS_COUPON_NOTIFICATION",e.PRODUCT_TRACKING_BACK_IN_STOCK_NOTIFICATION="PRODUCT_TRACKING_BACK_IN_STOCK_NOTIFICATION",e.PRODUCT_TRACKING_OUT_OF_STOCK_NOTIFICATION="PRODUCT_TRACKING_OUT_OF_STOCK_NOTIFICATION",e.PRODUCT_TRACKING_PRICE_DROP_NOTIFICATION="PRODUCT_TRACKING_PRICE_DROP_NOTIFICATION",e.COUPONCLIPPING="COUPONCLIPPING",e.TRENDING_COUPONS="TRENDING_COUPONS",e.MOMENT_IN_TIME="MOMENT_IN_TIME",e.SAN_CONSENT_NOTIFICATION="SAN_CONSENT_NOTIFICATION",e.DISCOVER_CHAT="DISCOVER_CHAT",e.CAMPAIGN_PDP_CASHBACK_NOTIFICATION="CAMPAIGN_PDP_CASHBACK_NOTIFICATION",e.CAMPAIGN_AWARENESS_NOTIFICATION="CAMPAIGN_AWARENESS_NOTIFICATION",e.AX_SHOPPING_NAV="AX_SHOPPING_NAV",e.PRODUCT_BEST_COUPON="PRODUCT_BEST_COUPON",e.ENROLL_TO_CASHBACK_CONFIRMATION_NOTIFICATION="ENROLL_TO_CASHBACK_CONFIRMATION_NOTIFICATION",e.POST_PURCHASE_CONSENT_NOTIFICATION="POST_PURCHASE_CONSENT_NOTIFICATION",e.SEARCHBOXDEMO_NOTIFICATION="SEARCHBOXDEMO_NOTIFICATION",e.PRICE_MATCH_PRICE_DROP_NOTIFICATION="PRICE_MATCH_PRICE_DROP_NOTIFICATION",e.INBOX_PRICE_MATCH_PRICE_DROP_NOTIFICATION="INBOX_PRICE_MATCH_PRICE_DROP_NOTIFICATION",e.TRAVEL_CHEAPER_FLIGHT_NOTIFICATION="TRAVEL_CHEAPER_FLIGHT_NOTIFICATION",e.TRAVEL_CHEAPER_HOTEL_NOTIFICATION="TRAVEL_CHEAPER_HOTEL_NOTIFICATION",e.DISCOVER_NOTIFICATION="DISCOVER_NOTIFICATION",e.AX_SHOPPING_NAV_NOTIFICATION="AX_SHOPPING_NAV_NOTIFICATION",e.ARTICLES_CASHBACK_NOTIFICATION="ARTICLES_CASHBACK_NOTIFICATION",e.BGAA_NOTIFICATION="BGAA_NOTIFICATION",e.POST_PURCHASE_REWARDS_NOTIFICATION="POST_PURCHASE_REWARDS_NOTIFICATION",e}({}),b=function(e){return e[e.NOT_ACTIVATING=0]="NOT_ACTIVATING",e[e.STARTED=1]="STARTED",e[e.FAILED=2]="FAILED",e[e.FAILED_SWITCH_TO_MSA_PROFILE=3]="FAILED_SWITCH_TO_MSA_PROFILE",e[e.FAILED_SWITCH_TO_MSA_DECLINED=4]="FAILED_SWITCH_TO_MSA_DECLINED",e[e.FAILED_SIGN_INTO_PROFILE=5]="FAILED_SIGN_INTO_PROFILE",e[e.PENDING_ENROLL_REBATES_USER=6]="PENDING_ENROLL_REBATES_USER",e[e.PENDING_SWITCH_TO_MSA_PROFILE=7]="PENDING_SWITCH_TO_MSA_PROFILE",e[e.PENDING_SIGN_INTO_PROFILE=8]="PENDING_SIGN_INTO_PROFILE",e[e.PENDING_ACTIVATION_IN_PROFILE=9]="PENDING_ACTIVATION_IN_PROFILE",e[e.FAILED_ACTIVATION_NO_RETAILER_DATA=10]="FAILED_ACTIVATION_NO_RETAILER_DATA",e[e.FAILED_ACTIVATION_URL_FETCH=11]="FAILED_ACTIVATION_URL_FETCH",e[e.FAILED_ACTIVATION_INVALID_JSON=12]="FAILED_ACTIVATION_INVALID_JSON",e[e.FAILED_ACTIVATION_URL_PARSING=13]="FAILED_ACTIVATION_URL_PARSING",e[e.FAILED_ACTIVATION_URL_INVALID=14]="FAILED_ACTIVATION_URL_INVALID",e[e.FAILED_ACTIVATION_ENROLL_NAVIGATION_LOAD=15]="FAILED_ACTIVATION_ENROLL_NAVIGATION_LOAD",e[e.FAILED_ACTIVATION_ENROLL_NAVIGATION_TIMED_OUT=16]="FAILED_ACTIVATION_ENROLL_NAVIGATION_TIMED_OUT",e[e.FAILED_ACTIVATION_ATTRIBUTION_NAVIGATION_LOAD=17]="FAILED_ACTIVATION_ATTRIBUTION_NAVIGATION_LOAD",e[e.FAILED_ACTIVATION_ATTRIBUTION_NAVIGATION_TIMED_OUT=18]="FAILED_ACTIVATION_ATTRIBUTION_NAVIGATION_TIMED_OUT",e[e.ACTIVATED=19]="ACTIVATED",e[e.FAILED_ACTIVATION_UNIFIED_API_BACKED_OFF=20]="FAILED_ACTIVATION_UNIFIED_API_BACKED_OFF",e[e.FAILED_ACTIVATION_ENROLL_VERIFY_COOKIE=21]="FAILED_ACTIVATION_ENROLL_VERIFY_COOKIE",e[e.FAILED_ACTIVATION_ENROLL_COOKIE_TIMED_OUT=22]="FAILED_ACTIVATION_ENROLL_COOKIE_TIMED_OUT",e[e.PENDING_BING_SSO=23]="PENDING_BING_SSO",e[e.PENDING_BING_IDENTITY_CHECK=24]="PENDING_BING_IDENTITY_CHECK",e[e.FAILED_ACTIVATION_ENROLL_API=26]="FAILED_ACTIVATION_ENROLL_API",e[e.FAILED_FETCHING_USER_INFO=27]="FAILED_FETCHING_USER_INFO",e}({}),S=function(e){return e[e.NOT_ACTIVATING=0]="NOT_ACTIVATING",e[e.STARTED=1]="STARTED",e[e.FAILED=2]="FAILED",e[e.FAILED_SWITCH_TO_MSA_PROFILE=3]="FAILED_SWITCH_TO_MSA_PROFILE",e[e.FAILED_SWITCH_TO_MSA_DECLINED=4]="FAILED_SWITCH_TO_MSA_DECLINED",e[e.FAILED_SIGN_INTO_PROFILE=5]="FAILED_SIGN_INTO_PROFILE",e[e.PENDING_ENROLL_REWARDS_USER=6]="PENDING_ENROLL_REWARDS_USER",e[e.PENDING_SWITCH_TO_MSA_PROFILE=7]="PENDING_SWITCH_TO_MSA_PROFILE",e[e.PENDING_SIGN_INTO_PROFILE=8]="PENDING_SIGN_INTO_PROFILE",e[e.PENDING_ACTIVATION_IN_PROFILE=9]="PENDING_ACTIVATION_IN_PROFILE",e[e.FAILED_ACTIVATION_ENROLL_NAVIGATION_LOAD=10]="FAILED_ACTIVATION_ENROLL_NAVIGATION_LOAD",e[e.FAILED_ACTIVATION_ENROLL_NAVIGATION_TIMED_OUT=11]="FAILED_ACTIVATION_ENROLL_NAVIGATION_TIMED_OUT",e[e.FAILED_ACTIVATION_ATTRIBUTION_NAVIGATION_LOAD=12]="FAILED_ACTIVATION_ATTRIBUTION_NAVIGATION_LOAD",e[e.FAILED_ACTIVATION_ATTRIBUTION_NAVIGATION_TIMED_OUT=13]="FAILED_ACTIVATION_ATTRIBUTION_NAVIGATION_TIMED_OUT",e[e.ACTIVATED=14]="ACTIVATED",e}({}),x=function(e){return e.CONTEXTUAL="CONTEXTUAL",e.HOME="HOME",e.EXPLORE="EXPLORE",e.CASHBACK="CASHBACK",e}({}),T=function(e){return e.SQUARES="SQUARES",e.LIST="LIST",e.BLOCK="BLOCK",e}({}),w=function(e){return e.VIEWALL="viewAll",e.VIEWALLPC="viewAllPC",e.VIEWPRICEHISTORY="viewPriceHistory",e}({}),O=function(e){return e.CARD="card",e.ZIP="zipPay",e.AFFIRM="affirm",e.KLARNA="klarna",e}({}),P=function(e){return e.PRICEDROP="PRICEDROP",e.PRICEINCREASE="PRICEINCREASE",e}({}),A=function(e){return e.AUTOS="autos",e.EMPTYAUTOSSEGMENT="emptyautossegment",e}({}),E=function(e){return e.US="en-us",e.CA="en-ca",e.GB="en-gb",e}({}),k=function(e){return e.ONLINEONLY="online only",e}({}),I=function(e){return e.LISTING="Listing",e.REVIEW="REVIEW",e.MYGARAGE="MYGARAGE",e.NONE="",e}({}),D=function(e){return e.PDP="PDP",e.OEM="OEM",e.SERP="SERP",e.FEED="FEED",e.FAllBACK="FAllBACK",e.DISCOVERYUSERRECO="DISCOVERYUSERRECO",e.DISCOVERYSEARCH="DISCOVERYSEARCH",e}({}),_=function(e){return e.NO_ACCIDENT_OR_DAMAGE_REPORTED="no accident or damage reported",e.ACCIDENT_MINOR_DAMAGE="accident/minor damage",e.ACCIDENT_NO_DAMAGE="accident/no damage",e.DAMAGE_REPORTED="damage reported",e.HAIL_DAMAGE="hail damage",e.MINOR_DAMAGE="minor damage",e.VERY_MINOR_DAMAGE="very minor damage",e}({}),N=function(e){return e.CLOSE="btnFlyoutClose",e.MENU="btnMainMenu",e.MENU_CONTENT="divMenuContent",e.SIDEPANE_CASHBACK="btnSidepaneCashback",e.SIDEPANE_CASHBACK_CONTENT="divSidepaneCashbackContent",e.SNOOZE="btnFlyoutSnoozeOn",e.SNOOZE_CONTENT="divSnoozeContent",e}({}),R=function(e){return e[e.Shown=0]="Shown",e[e.Clicked=1]="Clicked",e[e.Dismissed=2]="Dismissed",e[e.Exit=3]="Exit",e[e.Snooze=4]="Snooze",e[e.Scroll=5]="Scroll",e[e.Ignored=6]="Ignored",e[e.ForceClosed=7]="ForceClosed",e[e.LastWPOEventName=7]="LastWPOEventName",e}({}),M=function(e){return e.Contextual="tabContexual",e.Home="tabHome",e.MyShopping="tabMyShopping",e.CouponsSavings="tabCouponsSavings",e.Explore="tabExplore",e.Cashback="tabCashback",e}({}),L=function(e){return e.MyShopping="myShoppingShopping",e.CouponsSavings="couponsSavingsShopping",e.Explore="exploreShopping",e.SingleScrolling="singleScrollingShopping",e}({}),B=function(e){return e.Contextual="panelContextual",e.Home="panelHome",e.SingleScrolling="panelSingleScrolling",e.Cashback="panelCashback",e}({}),F=function(e){return e.TrackedProducts="TRACKING",e.RecentlyViewed="RECENTS",e.Saved="WISHLIST",e}({}),U=function(e){return e.AllPurchases="ALLPURCHASES",e.Active="ACTIVE",e}({}),H=function(e){return e.PaneBanner="PaneBanner",e.SPBNotification="SPBNotification",e.OtherNotification="OtherNotification",e}({}),$=function(e){return e.NEW_USER="NEW_USER",e.PASSIVE_USER="PASSIVE_USER",e.COMPLETED_PURCHASE_UNKNOWN_VALUE="COMPLETED_PURCHASE_UNKNOWN_VALUE",e.COMPLETED_PURCHASE_KNOWN_VALUE="COMPLETED_PURCHASE_KNOWN_VALUE",e.PENDING_TO_AVAILABLE="PENDING_TO_AVAILABLE",e.CASHED_OUT="CASHED_OUT",e}({}),Z=function(e){return e.ROW_COMPOSITE_NOTIFICATION="ROW_COMPOSITE_NOTIFICATION",e.COLUMN_COMPOSITE_NOTIFICATION="COLUMN_COMPOSITE_NOTIFICATION",e}({}),V=function(e){return e[e.NotPresent=0]="NotPresent",e[e.Accepted=1]="Accepted",e[e.Declined=2]="Declined",e}({})},73557:function(e,t,i){"use strict";i.d(t,{Ke:function(){return o},W5:function(){return r},sR:function(){return n}});let n=function(e){return e[e.AUTO_SHOW_COUPONS_CHECKOUT=1]="AUTO_SHOW_COUPONS_CHECKOUT",e[e.AUTO_SHOW_LOWER_PRICE_FOUND=5]="AUTO_SHOW_LOWER_PRICE_FOUND",e[e.AUTO_SHOW_BING_SEARCH=6]="AUTO_SHOW_BING_SEARCH",e[e.AUTO_SHOW_REBATES=7]="AUTO_SHOW_REBATES",e[e.AUTO_SHOW_REBATES_CONFIRMATION=8]="AUTO_SHOW_REBATES_CONFIRMATION",e[e.AUTO_SHOW_REBATES_DEACTIVATED=9]="AUTO_SHOW_REBATES_DEACTIVATED",e[e.AUTO_SHOW_REBATES_ORGANIC=11]="AUTO_SHOW_REBATES_ORGANIC",e[e.AUTO_SHOW_PRICE_HISTORY=13]="AUTO_SHOW_PRICE_HISTORY",e[e.AUTO_SHOW_REBATES_ORGANIC_NEW=14]="AUTO_SHOW_REBATES_ORGANIC_NEW",e[e.AUTO_SHOW_REBATES_CHECKOUT=15]="AUTO_SHOW_REBATES_CHECKOUT",e[e.AUTO_SHOW_PERSONALIZED_CASHBACK=17]="AUTO_SHOW_PERSONALIZED_CASHBACK",e[e.AUTO_SHOW_PERSONALIZED_CASHBACK_CONFIRMATION=18]="AUTO_SHOW_PERSONALIZED_CASHBACK_CONFIRMATION",e[e.AUTO_SHOW_URL_PARAM_REBATES=19]="AUTO_SHOW_URL_PARAM_REBATES",e[e.AUTO_SHOW_URL_PARAM_PRICE_COMPARISON=20]="AUTO_SHOW_URL_PARAM_PRICE_COMPARISON",e[e.AUTO_SHOW_URL_PARAM_PRICE_HISTORY=21]="AUTO_SHOW_URL_PARAM_PRICE_HISTORY",e[e.AUTO_SHOW_EXPRESS_CHECKOUT=22]="AUTO_SHOW_EXPRESS_CHECKOUT",e[e.AUTO_SHOW_SERVER_DRIVEN_REWARDS=26]="AUTO_SHOW_SERVER_DRIVEN_REWARDS",e[e.AUTO_SHOW_COUPONS_CLIPPING=27]="AUTO_SHOW_COUPONS_CLIPPING",e[e.AUTO_SHOW_REBATES_ACTIVATION_FAILED=28]="AUTO_SHOW_REBATES_ACTIVATION_FAILED",e[e.AUTO_SHOW_REBATES_SWITCHED_TO_MSA=29]="AUTO_SHOW_REBATES_SWITCHED_TO_MSA",e[e.AUTO_SHOW_OTHER_SELLERS=31]="AUTO_SHOW_OTHER_SELLERS",e[e.AUTO_SHOW_ITEM_ADDED_TO_CART_FROM_OTHER_SELLER=32]="AUTO_SHOW_ITEM_ADDED_TO_CART_FROM_OTHER_SELLER",e[e.AUTO_SHOW_PROFESSIONAL_REVIEWS=33]="AUTO_SHOW_PROFESSIONAL_REVIEWS",e[e.AUTO_SHOW_VIRTUAL_CARD=35]="AUTO_SHOW_VIRTUAL_CARD",e[e.AUTO_SHOW_BING_CAMPAIGN=36]="AUTO_SHOW_BING_CAMPAIGN",e[e.AUTO_SHOW_PACKAGE_TRACKING=40]="AUTO_SHOW_PACKAGE_TRACKING",e[e.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION=41]="AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION",e[e.OPEN_FLYOUT_FROM_EDGE_DRIVER_EC=42]="OPEN_FLYOUT_FROM_EDGE_DRIVER_EC",e[e.AUTO_SHOW_GUEST_DOMAIN_COUPONS=43]="AUTO_SHOW_GUEST_DOMAIN_COUPONS",e[e.AUTO_SHOW_SOCIAL_COUPONS=44]="AUTO_SHOW_SOCIAL_COUPONS",e[e.AUTO_SHOW_SUSTAINABILITY_LANDING=45]="AUTO_SHOW_SUSTAINABILITY_LANDING",e[e.AUTO_SHOW_SUSTAINABILITY_PURCHASE=46]="AUTO_SHOW_SUSTAINABILITY_PURCHASE",e[e.AUTO_SHOW_REWARDS_ACTIVATION_FAILED=47]="AUTO_SHOW_REWARDS_ACTIVATION_FAILED",e[e.AUTO_SHOW_REWARDS_SWITCHED_TO_MSA=48]="AUTO_SHOW_REWARDS_SWITCHED_TO_MSA",e[e.AUTO_SHOW_ATTAINABLE_COUPONS=49]="AUTO_SHOW_ATTAINABLE_COUPONS",e[e.AUTO_SHOW_GIFT_CARD=50]="AUTO_SHOW_GIFT_CARD",e[e.AUTO_SHOW_RECOMMENDATIONS=51]="AUTO_SHOW_RECOMMENDATIONS",e[e.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK=52]="AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK",e[e.AUTO_SHOW_AOC=53]="AUTO_SHOW_AOC",e[e.AUTO_SHOW_AUTOS_MARKETPLACE=54]="AUTO_SHOW_AUTOS_MARKETPLACE",e[e.AUTO_PRODUCT_TRACKING_OUT_OF_STOCK=58]="AUTO_PRODUCT_TRACKING_OUT_OF_STOCK",e[e.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK_LANDING=59]="AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK_LANDING",e[e.AUTO_SHOW_SPB_CASHBACK_LANDING=60]="AUTO_SHOW_SPB_CASHBACK_LANDING",e[e.AA_CONSENT=62]="AA_CONSENT",e[e.AUTO_SHOW_SAN_CONSENT_CONFIRMATION=63]="AUTO_SHOW_SAN_CONSENT_CONFIRMATION",e[e.AUTO_SHOW_MOMENT_IN_TIME=65]="AUTO_SHOW_MOMENT_IN_TIME",e[e.AUTO_SHOW_TRENDING_COUPONS=67]="AUTO_SHOW_TRENDING_COUPONS",e[e.AUTO_SHOW_ABANDONED_CART=72]="AUTO_SHOW_ABANDONED_CART",e[e.AUTO_SHOW_PRODUCT_TRACKING_BACK_IN_STOCK=73]="AUTO_SHOW_PRODUCT_TRACKING_BACK_IN_STOCK",e[e.AUTO_PRODUCT_TRACKING_EXP_PRICE_DROP=74]="AUTO_PRODUCT_TRACKING_EXP_PRICE_DROP",e[e.AUTO_PRODUCT_TRACKING_IMP_PRICE_DROP=75]="AUTO_PRODUCT_TRACKING_IMP_PRICE_DROP",e[e.HOVER_BUTTON_SHOW_FLYOUT=86]="HOVER_BUTTON_SHOW_FLYOUT",e[e.CJK_OPEN_HUB_ICON=87]="CJK_OPEN_HUB_ICON",e[e.AUTO_SHOW_REBATES_PDP=89]="AUTO_SHOW_REBATES_PDP",e[e.AUTO_SHOW_PRODUCT_BEST_COUPON_CONSENT=90]="AUTO_SHOW_PRODUCT_BEST_COUPON_CONSENT",e[e.AUTO_SHOW_CAMPAIGN_PDP_NOTIFICATION=91]="AUTO_SHOW_CAMPAIGN_PDP_NOTIFICATION",e[e.AUTO_SHOW_CAMPAIGN_AWARENESS_NOTIFICATION=92]="AUTO_SHOW_CAMPAIGN_AWARENESS_NOTIFICATION",e[e.AUTO_SHOW_CASHBACK_PDP_PLUS_COUPONS=98]="AUTO_SHOW_CASHBACK_PDP_PLUS_COUPONS",e[e.AUTO_SHOW_PRICE_DROP_PLUS_CASHBACK=99]="AUTO_SHOW_PRICE_DROP_PLUS_CASHBACK",e[e.AUTO_SHOW_IBC_UPSELL=100]="AUTO_SHOW_IBC_UPSELL",e[e.AUTO_SHOW_POST_PURCHASE_TRACKING=101]="AUTO_SHOW_POST_PURCHASE_TRACKING",e[e.AUTO_SHOW_AMAZON_SEARCH_PC=102]="AUTO_SHOW_AMAZON_SEARCH_PC",e[e.AUTO_SHOW_LOWER_PRICE_PLUS_CASHBACK_PLUS_COUPONS=103]="AUTO_SHOW_LOWER_PRICE_PLUS_CASHBACK_PLUS_COUPONS",e[e.AUTO_SHOW_DISCOVER_NOTIFICATION=105]="AUTO_SHOW_DISCOVER_NOTIFICATION",e[e.AUTO_SHOW_COUPONS_BACKGROUND_AUTO_APPLY=107]="AUTO_SHOW_COUPONS_BACKGROUND_AUTO_APPLY",e[e.AUTO_SHOW_PERSONALIZED_CASHBACK_ADDRESSBAR=108]="AUTO_SHOW_PERSONALIZED_CASHBACK_ADDRESSBAR",e[e.AUTO_SHOW_TRAVEL_NOTIFICATION_CHEAPER_FLIGHTS=109]="AUTO_SHOW_TRAVEL_NOTIFICATION_CHEAPER_FLIGHTS",e[e.AUTO_SHOW_ARTICLES_CASHBACK_NOTIFICATION=110]="AUTO_SHOW_ARTICLES_CASHBACK_NOTIFICATION",e[e.AUTO_SHOW_CJK_PRICE_DROP=111]="AUTO_SHOW_CJK_PRICE_DROP",e[e.AUTO_SHOW_CJK_COUPON_FOUND=112]="AUTO_SHOW_CJK_COUPON_FOUND",e[e.AUTO_SHOW_SPB_CHECK_OUT_PAGE_NOTIFICATION=113]="AUTO_SHOW_SPB_CHECK_OUT_PAGE_NOTIFICATION",e[e.AUTO_SHOW_INBOX_PRICE_MATCH_NOTIFICATION=114]="AUTO_SHOW_INBOX_PRICE_MATCH_NOTIFICATION",e[e.AUTO_SHOW_TRAVEL_NOTIFICATION_CHEAPER_HOTEL_ROOM=115]="AUTO_SHOW_TRAVEL_NOTIFICATION_CHEAPER_HOTEL_ROOM",e[e.AUTO_SHOW_POST_PURCHASE_REWARDS_NOTIFICATION=116]="AUTO_SHOW_POST_PURCHASE_REWARDS_NOTIFICATION",e}({}),o=function(e){return e[e.NONE=0]="NONE",e[e.COUPONS_CHECKOUT=1]="COUPONS_CHECKOUT",e[e.COUPONS_CLIPPING=2]="COUPONS_CLIPPING",e[e.PRICE_COMPARE=4]="PRICE_COMPARE",e[e.PRICE_HISTORY=8]="PRICE_HISTORY",e[e.REBATES_CONFIRMATION=16]="REBATES_CONFIRMATION",e[e.REBATES_BING=32]="REBATES_BING",e[e.REBATES_ORGANIC=64]="REBATES_ORGANIC",e[e.REBATES_CHECKOUT=128]="REBATES_CHECKOUT",e[e.PERSONALIZED_CASHBACK=256]="PERSONALIZED_CASHBACK",e[e.PERSONALIZED_CASHBACK_CONFIRMATION=512]="PERSONALIZED_CASHBACK_CONFIRMATION",e[e.EXPRESS_CHECKOUT=1024]="EXPRESS_CHECKOUT",e[e.REWARDS=2048]="REWARDS",e[e.OTHER_SELLER=4096]="OTHER_SELLER",e[e.REVIEWS=8192]="REVIEWS",e[e.VIRTUAL_CARD=16384]="VIRTUAL_CARD",e[e.PACKAGE_TRACKING=32768]="PACKAGE_TRACKING",e[e.GUEST_COUPONS=65536]="GUEST_COUPONS",e[e.EXCLUSIVE_COUPONS=131072]="EXCLUSIVE_COUPONS",e[e.SUSTAINABILITY_LANDING=262144]="SUSTAINABILITY_LANDING",e[e.SUSTAINABILITY_PURCHASE=524288]="SUSTAINABILITY_PURCHASE",e[e.ATTAINABLE_COUPONS=1048576]="ATTAINABLE_COUPONS",e[e.REWARDS_GIFT_CARD=2097152]="REWARDS_GIFT_CARD",e[e.RECOMMENDATIONS=4194304]="RECOMMENDATIONS",e[e.GROCERY_ITEMIZED_CASHBACK=8388608]="GROCERY_ITEMIZED_CASHBACK",e[e.AUTOS_MARKETPLACE=16777216]="AUTOS_MARKETPLACE",e[e.SHOPRUNNER=33554432]="SHOPRUNNER",e[e.ABANDONED_CART=67108864]="ABANDONED_CART",e[e.SHOPRUNNER_CONFIRMATION=134217728]="SHOPRUNNER_CONFIRMATION",e[e.OUT_OF_STOCK=268435456]="OUT_OF_STOCK",e[e.GROCERY_ITEMIZED_CASHBACK_LANDING=536870912]="GROCERY_ITEMIZED_CASHBACK_LANDING",e[e.SPB_CASHBACK_LANDING=1073741824]="SPB_CASHBACK_LANDING",e[e.MIN_VALUE=0]="MIN_VALUE",e[e.MAX_VALUE=1073741824]="MAX_VALUE",e}({}),r=function(e){return e[e.NONE=0]="NONE",e[e.PRODUCT_TRACKING_IMP_PRICE_DROP=1]="PRODUCT_TRACKING_IMP_PRICE_DROP",e[e.PRODUCT_TRACKING_EXP_PRICE_DROP=2]="PRODUCT_TRACKING_EXP_PRICE_DROP",e[e.PRODUCT_TRACKING_OUT_OF_STOCK=3]="PRODUCT_TRACKING_OUT_OF_STOCK",e[e.PRODUCT_TRACKING_BACK_IN_STOCK=4]="PRODUCT_TRACKING_BACK_IN_STOCK",e[e.ABANDONED_CART_COUPONS=5]="ABANDONED_CART_COUPONS",e[e.PRODUCT_TRACKING_OFFERS_COUPONS=6]="PRODUCT_TRACKING_OFFERS_COUPONS",e}({})},12265:function(e,t,i){"use strict";i.d(t,{VS:function(){return r},_N:function(){return a},hB:function(){return n},mh:function(){return s},qx:function(){return o}});let n=function(e){return e.Storewide="Storewide",e.PCBStorewide="PCBStorewide",e.SPBSearchCashback="SPBSearchCashback",e.SPBPDPCashback="SpbPdpCashback",e.StorewideCashbackPinterest="StorewideCashbackPinterest",e.SPBorPPCashback="SPBorPPCashback",e}({}),o=function(e){return e.NonRebateUser="NotRebateUser",e.LinkableAAD="LinkableAAD",e.LinkedAAD="LinkedAAD",e.NotEnrollledUser="NotEnrollledUser",e.Rebate="Rebate",e}({}),r=function(e){return e.Activated="Activated",e.Activating="Activating",e.Failed="Failed",e.FetchUserInfoFailed="FetchUserInfoFailed",e.NonActivated="NonActivated",e}({}),a=function(e){return e[e.NOT_ENABLED=0]="NOT_ENABLED",e[e.NON_PURCHASE_OR_CHECKOUT_PAGE=1]="NON_PURCHASE_OR_CHECKOUT_PAGE",e[e.EXTRACTION_SUCCESSFULL=2]="EXTRACTION_SUCCESSFULL",e[e.EXTRACTION_SUCCESSFULL_BUT_MISSING_FIELDS=3]="EXTRACTION_SUCCESSFULL_BUT_MISSING_FIELDS",e[e.FAILED_TO_EXTRACT_DATA=4]="FAILED_TO_EXTRACT_DATA",e[e.SELECTORS_ABSENT=5]="SELECTORS_ABSENT",e[e.CACHED_CART_DATA_NOT_SENT=6]="CACHED_CART_DATA_NOT_SENT",e[e.PURCHASE_ALREADY_RECORDED=7]="PURCHASE_ALREADY_RECORDED",e[e.CONFIRMATION_LOG_NOT_ENABLED=8]="CONFIRMATION_LOG_NOT_ENABLED",e[e.UNKNOWN_ERROR=9]="UNKNOWN_ERROR",e[e.LOG_ONLY=10]="LOG_ONLY",e}({}),s=function(e){return e.CAROUSEL_JOIN_REBATES="CAROUSEL_JOIN_REBATES",e.CAROUSEL_LEARN_MORE="CAROUSEL_LEARN_MORE",e.CAROUSEL_MS_REWARDS="CAROUSEL_MS_REWARDS",e.CAROUSEL_TERMS="CAROUSEL_TERMS",e.CAROUSEL_PRIVACY_POLICY="CAROUSEL_PRIVACY_POLICY",e.CAROUSEL_WELCOME_LINK="CAROUSEL_WELCOME_LINK",e.CLOSE_REDEEM_BANNER="CLOSE_REDEEM_BANNER",e.TOGGLE_HISTORY_LENGTH="TOGGLE_HISTORY_LENGTH",e.ACTIVATED_OFFER_CLICK="ACTIVATED_OFFER_CLICK",e.REDEEM_BANNER_BUTTON="REDEEM_BANNER_BUTTON",e.SEE_FULL_HISTORY="SEE_FULL_HISTORY",e.BALANCE_BUTTON="BALANCE_BUTTON",e.SEE_FULL_ACTIVATED_OFFERS="SEE_FULL_ACTIVATED_OFFERS",e.TOP_OFFER_CLICK="TOP_OFFER_CLICK",e}({})},55590:function(e,t,i){"use strict";i.d(t,{Q:function(){return n}});let n=function(e){return e.ICLastAutoShowTime="ICLastAutoShowTime",e.ICNotificationType="ICNotificationType",e.ICIsRelatedOffer="ICIsRelatedOffer",e.ICMetadata="ICMetadata",e.ICCurrentPageInfo="ICCurrentPageInfo",e.GroceryCashbackItem="GroceryCashbackItem",e.GroceryCashbackActivated="GroceryCashbackActivated",e.GroceryAutoShowData="GroceryAutoShowData",e.GroceryCategoryAutoShowData="GroceryCategoryAutoShowData",e.ICRelatedPDPOffer="ICRelatedPDPOffer",e.ICActivationMigrationPending="ActivationMigrationPending",e.ICActivatedPending="ICActivatedPending",e.ICActivatedCashbackTotal="ActivatedCashbackTotal",e.ICActivatedCashbackImages="ActivatedCashbackImages",e.ICConfirmationPending="ICConfirmationPending",e.ICConfirmationCompleted="ICConfirmationCompleted",e.AutoClipData="AutoClipData",e.ICPendingTransaction="ICPendingTransaction",e.ICAutoShownOffers="ICAutoShownOffers",e.AutosMarketplace="AutosMarketplace",e.AutosMarketplaceNotification="AutosMarketplaceNotification",e.InboxCouponsGetAllCouponsResponseCache="InboxCouponsGetAllCouponsResponseCache",e.InboxCouponsAuthTokenKeyPrefix="InboxCouponsAuthToken|",e.InboxCouponsUserEmailsStatus="InboxCouponsUserEmailsStatus",e.InboxCouponsUserEmailsStatusCache="InboxCouponsUserEmailsStatusCache",e.InboxCouponsEdgeSignInStarted="InboxCouponsEdgeSignInStarted",e.InboxCouponsEdgeSignInSuccess="InboxCouponsEdgeSignInSuccess",e.InboxCouponsHashedUserId="InboxCouponsHashedUserId",e.InboxCouponsUserHashedEmail="InboxCouponsUserHashedEmail",e.InboxCouponsLogsMetadata="InboxCouponsLogsMetadata",e.InboxCouponsPaneOpen="InboxCouponsPaneOpen",e.TrendingCouponsData="TrendingCouponsData",e.PersonalizationContextCanPrompt="LoadTimePersonalizationContextPrompt",e.ReceiptScannerBannerImpressionIds="ReceiptScannerBannerImpressionIds",e.ReceiptScannerDealImpressionIds="ReceiptScannerDealImpressionIds",e.ReceiptScannerDealClicked="ReceiptScannerDealClicked",e.ICIsPendingTransactionPresent="ICIsPendingTransactionPresent",e.IsEntrolledInDealDaysNotifications="IsEntrolledInDealDaysNotifications",e.GroceryInstantAddToCart="GroceryInstantAddToCart",e.GroceryInstantAddToCartSpb="GroceryInstantAddToCartSpb",e.GroceryCheckoutPageOffersSpb="GroceryCheckoutPageOffersSpb",e.GroceryMatchedCartSpbOffers="GroceryMatchedCartSpbOffers",e.PackageTrackingConfirmationNotifLastShown="PackageTrackingConfirmationNotifLastShown",e.PackageTrackingUXOrderMetadata="PackageTrackingUXOrderMetadata",e.PcbNotificationLastShownAdCount="PcbNotificationLastShownAdCount",e.PersistentCartData="PersistentCartData",e.CartValues="CartValues",e.PersistentWinCartData="PersistentWinCartData",e.ValidCartsToSync="ValidCartsToSync",e.UnprocessedWinCartItems="UnprocessedWinCartItems",e.ProductCollectionBannerLastShown="ProductCollection/BannerLastShown",e.ProductTrackingOOSLastShown="ProductTrackingOOSLastShown",e.ProductTrackingTrackedProducts="productTrackingData",e.ProductTrackingOOSData="ProductTrackingData",e.ProductTrackingUrlProductCache="ProductTracking/UrlProductCache",e.ProductTrackingConsentStatus="ProductTracking/ConsentStatus",e.ProductTrackingAnidData="ProductTracking/AnidData",e.ClearedWinCarts="ClearedWinCarts",e.SidepaneCashback="SidepaneCashback",e.PaneOpenMicroNotificationPopupOrigination="PaneOpenMicroNotificationPopupOrigination",e.ProductBestCouponConsent="ProductBestCouponConsent",e.PackagesNotified="PackagesNotified",e.ValidPackage="ValidPackage",e.ProductBestCoupon="ProductBestCoupon",e.DealsForTopDomainsTimestamp="DealsForTopDomainsTimestamp",e.BestCoupons="BestCoupons",e.CashbackInfo="CashbackInfo",e.PCBStorewideAddressBar="PCBStorewideAddressBar",e.PCBStorewideAddressBarLastRequested="PCBStorewideAddressBarLastRequested",e.ICSpbHomePageShownTimestamp="ICSpbHomePageShownTimestamp",e.ICSpbExpiryNotificationShownTime="ICSpbExpiryNotificationShownTime",e.UserAnid="userAnid",e.ShippingFee="ShippingFee",e.InboxCouponsUserConsented="UserConsentedInboxCoupon",e.CartPageCashbackNotification="CartPageCashbackNotification",e.PriceMatchConsent="PriceMatchConsent",e.AmazonSearchPCBOffer="AmazonSearchPCBOffer",e.UnsuccessfulAutoApplyCount="UnsuccessfulAutoApplyCount",e.ShoppingTripsData="CashbackShoppingTripsData",e.InboxCouponsAAFailureUpsellTriggeredV2="InboxCouponsAAFailureUpsellTriggeredV2",e.InboxCouponsAASuccessUpsellTriggeredV2="InboxCouponsAASuccessUpsellTriggeredV2",e.ShoppingTripsActivateRebateDomain="ShoppingTripsActivateRebateDomain",e.ProductTrackingBackInStockValidationData="ProductTracking/BackInStockValidationData",e.ProductTrackingPriceDropValidationData="ProductTracking/PriceDropValidationData",e.PostPurchasePendingProducts="PostPurchasePendingProducts",e.PostPurchasePathnameProducts="PostPurchasePathnameProducts",e.TravelCheaperFlightData="TravelCheaperFlightData",e.TravelCheaperHotelData="TravelCheaperHotelData",e.IsNavigatedFromAddressBarPersonalizedCashback="IsNavigatedFromAddressBarPersonalizedCashback",e.IsNavigatedFromAddressBarCashback="IsNavigatedFromAddressBarCashback",e.IsNavigatedFromAddressBarCoupons="IsNavigatedFromAddressBarCoupons",e.PersonalizedPromotionsCartData="PersonalizedPromotionsCartData",e.AutoActivatedSpbOffer="AutoActivatedSpbOffer",e.ArticlesCashback="ArticlesCashback",e.ShorelineSpbOffers="ShorelineSpbOffers",e.PriceMatchNotification="PriceMatchNotification",e.BGAABestCouponResult="BGAABestCouponResult",e.BGAAApplyButtonClicked="BGAAApplyButtonClicked",e.ExclusiveCouponConsent="ExclusiveCouponConsent",e.BlossomCampaignUserStatus="BlossomCampaignUserStatus",e.BlossomCampaignUserStatusTimestamp="BlossomCampaignUserStatusTimestamp",e.BlossomShouldShowNotification="BlossomShouldShowNotification",e.BlossomShouldShowPostPurchaseUX="BlossomShouldShowPostPurchaseUX",e.PostPurchaseRewardsData="PostPurchaseRewardsData",e.CheckoutPageNavigatedTime="CheckoutPageNavigatedTime",e.DynamicTransactionId="DynamicTransactionId",e.PurchaseCart="PurchaseCart",e.ShouldOpenOfferDetails="ShouldOpenOfferDetails",e}({})},18491:function(e,t,i){"use strict";i.d(t,{x:function(){return n}});let n=function(e){return e.Search="search",e.Category="category",e.Offers="offers",e.SearchInPane="searchpane",e.SearchInPaneMain="searchpaneMain",e.CategoryInPane="categorypane",e.OnShorelineOpen="onShorelineOpen",e}({})},96658:function(e,t,i){"use strict";i.d(t,{r:function(){return n}});let n=function(e){return e.ActivateCashbackCTA="ActivateCashbackCTA",e.AutosMarketplaceOffers="AutosMarketplaceOffers",e.BlackFridayOffers="BlackFridayOffers",e.CyberMondayOffers="CyberMondayOffers",e.ThanksgivingOffers="ThanksgivingOffers",e.HolidaySeasonOffers="HolidaySeasonOffers",e.NewYearOffers="NewYearOffers",e.ValentinesOffers="ValentinesOffers",e}({})},56372:function(e,t,i){"use strict";var n=i(72370),o=i(4872),r=i(31656),a=i(47594),s=i(5144),l=i(21597),c=i(87720),d=i(3141),u=i(73557),h=i(29247),p=i(33491),g=i(27689);t.Z=class{constructor(){(0,n.Z)(this,"autoOpenPrefData",void 0),(0,n.Z)(this,"autoOpenDomainPrefData",void 0),(0,n.Z)(this,"genericDataStore",new Map),(0,n.Z)(this,"domainName",void 0),(0,n.Z)(this,"currentPath",void 0),(0,n.Z)(this,"impressionId",void 0),(0,n.Z)(this,"autoOpenDataStr",void 0),(0,n.Z)(this,"lastCleanedDataStr",void 0),(0,n.Z)(this,"autoOpenPrefDataStr",void 0),(0,n.Z)(this,"autoOpenDomainPrefDataStr",void 0),(0,n.Z)(this,"lastShownDataStr",void 0),(0,n.Z)(this,"stageAndCategoryLastShownStr",void 0),(0,n.Z)(this,"totalPrice",void 0),(0,n.Z)(this,"sendErrorMessage",void 0),(0,n.Z)(this,"sendStorageMessage",void 0),(0,n.Z)(this,"domainData",void 0),(0,n.Z)(this,"autoOpenData",void 0),(0,n.Z)(this,"lastCleanedData",void 0),(0,n.Z)(this,"lastShownData",void 0),(0,n.Z)(this,"stageAndCategoryLastShown",void 0),(0,n.Z)(this,"caller",void 0)}initCommonInfo(e,t,i,n){this.impressionId=e,this.domainName=t,this.currentPath=i,this.caller=n}isPopupOriginationUnblocked(e,t){if(!this.autoOpenDataStr)return!0;if(this.domainData){if(!this.checkBlockedList(this.domainData.blockedList,e))return t&&(t.Reason="Popup origination blocked due to domain"),!1;if(!this.shouldBlockForDomain(e))try{return!!this.isPopupOriginationUnblockedForPath(e)||(t&&(t.Reason="Popup origination blocked due to path"),!1)}catch(e){return this.sendErrorMessageHandler(":::AOC - "+e),!0}return!0}return!0}isPopupOriginationUnblockedForPath(e){if(!this.domainData)return!0;this.domainData.paths.get(this.currentPath)||this.domainData.paths.set(this.currentPath,new d.Z);const t=this.domainData.paths.get(this.currentPath);return t?this.checkBlockedList(t.blockedListPath,e):(this.sendErrorMessageHandler(":::AOC - pathData undefined"),!0)}setTotalPrice(e){this.totalPrice=e}getNumberParameter(e,t){return e&&e.length>t?parseInt(e[t],10):null}getStringParameter(e,t){return e&&e.length>t?e[t]:""}doesGroupHaveEnum(e,t){return!!(e&1<<t)}cleanLocalStorage(){try{this.lastCleanedData||(this.lastCleanedData=new Map),this.autoOpenData.forEach(((e,t)=>{const i=this.lastCleanedData.get(t);if(!i){this.lastCleanedData.set(t,Date.now());const e=JSON.stringify(this.lastCleanedData,h.ZP.StringifyMap);return void this.sendStorageMessage(c.Gr,JSON.stringify({value:e}))}if(void 0!==i&&Date.now()-i<c.Zs)return;let n=!1,o=!1;const r=e;if(r.blockedList&&r.blockedList.length>0){const e=r.blockedList,t=this.cleanList(e);t&&t.length>0?(n=!0,r.blockedList=t):r.blockedList=[]}if(r.paths&&r.paths.forEach(((e,t)=>{if(e){const i=e.blockedListPath,n=this.cleanList(i);n&&n.length>0?(o=!0,e.blockedListPath=n,r.paths.set(t,e)):r.paths.delete(t)}})),o||n){this.autoOpenData.set(t,r),this.lastCleanedData.set(t,Date.now());const e=JSON.stringify(this.lastCleanedData,h.ZP.StringifyMap);this.sendStorageMessage(c.Gr,JSON.stringify({value:e}))}else this.autoOpenData.delete(t)}));const e=JSON.stringify({value:JSON.stringify(this.autoOpenData,h.ZP.StringifyMap)});this.sendStorageMessage(c.Q5,e)}catch(e){this.sendErrorMessage(this.impressionId,":::AOC -"+e)}}getSnoozeTime(e,t){return e.snoozeTime?e.snoozeTime:this.shouldBlockForDomain(e.popupOrigination)?e.popupOrigination===u.sR.AUTO_SHOW_COUPONS_CHECKOUT?e.totalPrice&&this.totalPrice&&e.totalPrice!==this.totalPrice&&!t&&!e.blockedForSite?-1:288e5:e.popupOrigination===u.sR.AUTO_SHOW_GIFT_CARD?6048e5:e.popupOrigination===u.sR.AUTO_SHOW_AUTOS_MARKETPLACE?6e5:e.popupOrigination===u.sR.AUTO_SHOW_CASHBACK_PDP_PLUS_COUPONS?864e5:e.popupOrigination===u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_ADDRESSBAR?6e4:e.popupOrigination===u.sR.AUTO_SHOW_COUPONS_BACKGROUND_AUTO_APPLY?r.R.isExperimentActive(o.H.bgaaNoSnoozeTime)?1e3:288e5:e.popupOrigination===u.sR.AUTO_SHOW_POST_PURCHASE_REWARDS_NOTIFICATION?1e3:e.popupOrigination===u.sR.AUTO_SHOW_TRAVEL_NOTIFICATION_CHEAPER_FLIGHTS?648e5:864e5:this.shouldBlockForPath(e.popupOrigination)?e.popupOrigination===u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK?6e5:e.popupOrigination===u.sR.AUTO_SHOW_TRAVEL_NOTIFICATION_CHEAPER_HOTEL_ROOM?12e5:864e5:-1}shouldBlockForPath(e){return!![u.sR.AUTO_SHOW_LOWER_PRICE_FOUND,u.sR.AUTO_SHOW_PRICE_HISTORY,u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK,u.sR.AUTO_SHOW_COUPONS_CLIPPING,u.sR.AUTO_SHOW_OTHER_SELLERS,u.sR.AUTO_SHOW_ITEM_ADDED_TO_CART_FROM_OTHER_SELLER,u.sR.AUTO_SHOW_PROFESSIONAL_REVIEWS,u.sR.AUTO_SHOW_BING_CAMPAIGN,u.sR.AUTO_SHOW_GUEST_DOMAIN_COUPONS,u.sR.AUTO_SHOW_SOCIAL_COUPONS,u.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK,u.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK_LANDING,u.sR.AUTO_SHOW_SPB_CASHBACK_LANDING,u.sR.AUTO_SHOW_SPB_CHECK_OUT_PAGE_NOTIFICATION,u.sR.HOVER_BUTTON_SHOW_FLYOUT,u.sR.CJK_OPEN_HUB_ICON,u.sR.AUTO_SHOW_REBATES_PDP,u.sR.AUTO_SHOW_CAMPAIGN_PDP_NOTIFICATION,u.sR.AUTO_SHOW_PRICE_DROP_PLUS_CASHBACK,u.sR.AUTO_SHOW_AMAZON_SEARCH_PC,u.sR.AUTO_SHOW_LOWER_PRICE_PLUS_CASHBACK_PLUS_COUPONS,u.sR.AUTO_PRODUCT_TRACKING_OUT_OF_STOCK,u.sR.AUTO_SHOW_TRAVEL_NOTIFICATION_CHEAPER_FLIGHTS,u.sR.AUTO_SHOW_TRAVEL_NOTIFICATION_CHEAPER_HOTEL_ROOM].includes(e)}shouldBlockForDomain(e){return!![u.sR.AUTO_SHOW_COUPONS_CHECKOUT,u.sR.AUTO_SHOW_GIFT_CARD,u.sR.AUTO_SHOW_REBATES,u.sR.AUTO_SHOW_REBATES_CHECKOUT,u.sR.AUTO_SHOW_REBATES_ORGANIC,u.sR.AUTO_SHOW_REBATES_ORGANIC_NEW,u.sR.AUTO_SHOW_AUTOS_MARKETPLACE,u.sR.AUTO_SHOW_CASHBACK_PDP_PLUS_COUPONS,u.sR.AUTO_SHOW_PRODUCT_BEST_COUPON_CONSENT,u.sR.AUTO_SHOW_BING_SEARCH,u.sR.AUTO_SHOW_EXPRESS_CHECKOUT,u.sR.AUTO_SHOW_VIRTUAL_CARD,u.sR.AUTO_SHOW_PACKAGE_TRACKING,u.sR.OPEN_FLYOUT_FROM_EDGE_DRIVER_EC,u.sR.AUTO_SHOW_SUSTAINABILITY_LANDING,u.sR.AUTO_SHOW_SUSTAINABILITY_PURCHASE,u.sR.AUTO_SHOW_ATTAINABLE_COUPONS,u.sR.AA_CONSENT,u.sR.AUTO_SHOW_SAN_CONSENT_CONFIRMATION,u.sR.AUTO_SHOW_MOMENT_IN_TIME,u.sR.AUTO_SHOW_SERVER_DRIVEN_REWARDS,u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_ADDRESSBAR,u.sR.AUTO_SHOW_COUPONS_BACKGROUND_AUTO_APPLY,u.sR.AUTO_SHOW_CJK_COUPON_FOUND,u.sR.AUTO_SHOW_CJK_PRICE_DROP,u.sR.AUTO_SHOW_POST_PURCHASE_REWARDS_NOTIFICATION].includes(e)}reEnabledPopupOriginationForLostUser(e,t,i){return!(![u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK,u.sR.AUTO_SHOW_REBATES,u.sR.AUTO_SHOW_LOWER_PRICE_FOUND,u.sR.AUTO_SHOW_PRICE_HISTORY,u.sR.AUTO_SHOW_COUPONS_CHECKOUT,u.sR.AUTO_SHOW_COUPONS_CLIPPING].includes(e)||!this.isPopupOriginReenabledForLostUser(e,t,i))}GetMinCooldownForPopupOrigination(e){let t;switch(e){case u.sR.AUTO_SHOW_ARTICLES_CASHBACK_NOTIFICATION:t=36e5;break;case u.sR.AUTO_SHOW_CAMPAIGN_AWARENESS_NOTIFICATION:t=12096e5;break;case u.sR.AUTO_SHOW_TRENDING_COUPONS:t=2592e6;break;case u.sR.AUTO_SHOW_ABANDONED_CART:case u.sR.AUTO_SHOW_POST_PURCHASE_TRACKING:case u.sR.AUTO_SHOW_INBOX_PRICE_MATCH_NOTIFICATION:case u.sR.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION:t=864e5;break;case u.sR.AUTO_SHOW_RECOMMENDATIONS:t=432e5;break;case u.sR.AUTO_SHOW_IBC_UPSELL:t="true"===(0,p.Mw)("ibcUpsellDebug")?1e3:6048e5;break;case u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_CONFIRMATION:case u.sR.AUTO_SHOW_REBATES_CONFIRMATION:case u.sR.AUTO_SHOW_AOC:t=36e5;break;default:t=void 0}return t}shouldBlockForStageAndCategory(e){return e===u.sR.AUTO_SHOW_DISCOVER_NOTIFICATION}initializeData(){if(this.autoOpenDataStr)try{this.autoOpenData=(0,g.BQ)(this.autoOpenDataStr,!0),this.autoOpenData&&(this.domainData=this.autoOpenData.get(this.domainName),this.domainData||(this.domainData=new l.ZP))}catch(e){this.autoOpenData=new Map,this.sendErrorMessageHandler("AutoOpenController constructor "+e+" "+this.caller);const t=JSON.stringify({value:JSON.stringify(this.autoOpenData,h.ZP.StringifyMap)});this.sendStorageMessage(c.Q5,t)}else this.autoOpenData=new Map,this.domainData=new l.ZP;if(this.lastCleanedDataStr&&"{}"!==this.lastCleanedDataStr&&(this.lastCleanedData=(0,g.BQ)(this.lastCleanedDataStr,!0)),this.autoOpenPrefDataStr)try{this.autoOpenPrefData=(0,g.BQ)(this.autoOpenPrefDataStr)}catch(e){this.autoOpenPrefData=[],this.sendErrorMessageHandler("AutoOpenController constructor auto open pref"+e),this.sendStorageMessage(c.cv,JSON.stringify({value:null}))}else this.autoOpenPrefData=[];if(this.autoOpenDomainPrefDataStr)try{this.autoOpenDomainPrefData=(0,g.BQ)(this.autoOpenDomainPrefDataStr,!0)}catch(e){this.sendErrorMessageHandler("AutoOpenController constructor auto open domain pref"+e),this.sendStorageMessage(c.Sk,JSON.stringify({value:null}))}if(this.lastShownDataStr)try{this.lastShownData=(0,g.BQ)(this.lastShownDataStr,!0)}catch(e){this.sendErrorMessageHandler("AutoOpenController constructor last shown data"+e),this.sendStorageMessage(c.n1,JSON.stringify({value:null}))}else this.lastShownData=new Map;if(this.stageAndCategoryLastShownStr)try{this.stageAndCategoryLastShown=(0,g.BQ)(this.stageAndCategoryLastShownStr,!0)}catch(e){this.sendErrorMessageHandler("AutoOpenController constructor stage and category last shown "+e),this.sendStorageMessage(c.z0,JSON.stringify({value:null}))}else this.stageAndCategoryLastShown=new Map}writeSimilarSellers(e,t){this.sendStorageMessage(e,t)}isPopupOriginReenabledForLostUser(e,t,i){const n=t?.find((t=>t.popupOrigination===e));if(void 0===n)return!1;const o=new Date;return!(i.lostUserReblockedTime&&(o.getTime()-i.lostUserReblockedTime)/864e5<3)}writeToList(e,t,i){if(this.domainData){if(this.shouldBlockForDomain(t)||i){if(this.domainData.blockedList=e,t===u.sR.AUTO_SHOW_COUPONS_CHECKOUT&&this.totalPrice){const e=this.domainData.blockedList.findIndex((e=>e.popupOrigination===u.sR.AUTO_SHOW_COUPONS_CHECKOUT));-1!==e&&(this.domainData.blockedList[e].totalPrice=this.totalPrice)}}else{let t=this.domainData.paths.get(this.currentPath);t||(t=new d.Z),t.blockedListPath=e,this.domainData.paths.set(this.currentPath,t)}this.autoOpenData.set(this.domainName,this.domainData);const n=JSON.stringify({value:JSON.stringify(this.autoOpenData,h.ZP.StringifyMap)});this.sendStorageMessage(c.Q5,n)}}checkBlockedList(e,t){let i=-1;if(e&&(i=e?.findIndex((e=>e.popupOrigination===t))),-1!==i&&e){const n=e[i],o=Date.now();let s=this.getSnoozeTime(n,!1);if((t===u.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK&&r.R.isTestFlagActive(a.t.msShoppingTestExp10)||t===u.sR.AUTO_SHOW_SPB_CHECK_OUT_PAGE_NOTIFICATION)&&(s=-1),-1===s&&!n.blockedForSite){const i=e.filter((e=>e.popupOrigination!==t));return this.writeToList(i,t,!1),!0}return o-n.timeLastAutoOpen>=s&&!n.blockedForSite}return!0}sendErrorMessageHandler(e){this.caller===s.G7.Flyout||this.caller===s.G7.Driver?this.sendErrorMessage(e):this.sendErrorMessage(this.impressionId,e)}cleanList(e){let t=[];if(e&&e.length>0){const i=[];e.forEach((e=>{Date.now()-e.timeLastAutoOpen>=this.getSnoozeTime(e,!0)&&i.push(e.popupOrigination)})),t=e.filter((e=>!i.includes(e.popupOrigination)))}return t}}},71455:function(e,t,i){"use strict";i.d(t,{a:function(){return o}});var n=i(95016);let o=function(e){return e.AutosMarketplaceString="AutosMarketplace_",e.AutosReviewString="AutosReview_",e.AutosMyGarageString="MyGarage_",e.AutosGlobalCoolDownString="AutosLastNotification",e}({});class r{static getSERPComparableOffersData(e){if(e)try{const t=JSON.parse(e);if(t?.autosData?.comparableOffers&&t?.autosData?.comparableOffers?.length>0){const e=[];return t?.autosData?.comparableOffers.forEach((t=>{e.push(new n.Z(t))})),e}return[]}catch(e){return[]}return[]}static isSERPPage(e,t){if(e)try{const i=JSON.parse(e);return i?.currentUrl?.toLowerCase()===t}catch(e){return!1}return!1}static getOEMComparableOffersData(e,t){const i=r.getAutosDataSelector(e,t);if(i)try{const e=JSON.parse(i);if(e?.comparableOffers&&e?.comparableOffers?.length>0){const t=[];return e?.comparableOffers.forEach((e=>{t.push(new n.Z(e))})),t}return[]}catch(e){return[]}return[]}static getAutosDataSelector(e,t){if(!t)return null;const i=e;let n=null;return t?.allCheckoutPages?.forEach((e=>{-1!==i.indexOf(e.checkoutPageUrl?.toLowerCase())&&(n=e.autosDataSelector)})),n}static hasValidPriceInsights(e){try{if(!e)return!1;const t=JSON.parse(e),i=t?.priceInsights;return!!(i&&i?.buckets?.length>3)}catch(e){return!1}}static getCompetingVehicle(e){if(!e||0===e?.length)return null;for(const t of e)if(t.ShouldOnTop&&t.validAutosOffer)return t;return null}static checkPathAllowed(e,t,i){if(!e)return!1;if(t){if(null===i||0===i.length)return!0;for(const t of i)if(!RegExp(t).test(e))return!1}return!0}}t.Z=r},29247:function(e,t,i){"use strict";i.d(t,{A3:function(){return p},BX:function(){return l},Nx:function(){return s},UE:function(){return u},VJ:function(){return h},_R:function(){return r},dz:function(){return c},mE:function(){return g},uy:function(){return a},w:function(){return d}});var n=i(3634),o=i(33491);function r(e){return new Promise((t=>setTimeout(t,e)))}function a(e,t){return t instanceof Map?{dataType:"Map",value:Array.from(t.entries())}:t}function s(e){return"true"===e||!0===e}function l(e,t){return"object"==typeof t&&null!==t&&"Map"===t.dataType?new Map(t.value):t}async function c(e,t,i){const n=(new Date).getTime();for(;!await e()&&n+t>(new Date).getTime();)await r(i??100);return await e()}async function d(e,t){const i=(new Date).getTime();for(;i+t>(new Date).getTime();){if(e())return!0;await r(100)}return!1}function u(e){return null!=e&&e.length>0&&"null"!==e}function h(e,t,i,n){let o=!1;if(u(e)&&(o=function(e,t){if(u(e)){const i=e.toLowerCase().replace(/\s+/g,"").split(","),n=t.toLowerCase();let o=!1;for(const e of i)if(n.indexOf(e)>=0){o=!0;break}return o}return!1}(e,i)),u(t))try{!n&&location.href?.toLocaleLowerCase()?.includes(i.toLocaleLowerCase())&&"chrome-untrusted://shopping/"!==location.href&&(n=location.href?.toLocaleLowerCase()),o=function(e,t){return!!u(e)&&new RegExp(e).test(t.toLowerCase())}(t,n??i)}catch{}return o}function p(e,t){const i=new MutationObserver((async n=>{n[0].removedNodes&&!document.body.contains(e)&&(i.disconnect(),t())}));i.observe(document.body,{attributeFilter:["offsetWidth","offsetHeight"],childList:!0,subtree:!0})}function g(e,t){(0,o.Mw)(n.uv)===t&&setTimeout((()=>{e?.scrollIntoView({behavior:"smooth",block:"start"}),localStorage.removeItem(n.uv)}),500)}class f{static Sleep(e){return new Promise((t=>setTimeout(t,e)))}static StringifyMap(e,t){return t instanceof Map?{dataType:"Map",value:Array.from(t.entries())}:t}static parseBool(e){return"true"===e||!0===e}static ParseMap(e,t){return"object"==typeof t&&null!==t&&"Map"===t.dataType?new Map(t.value):t}static async WaitForCondition(e,t,i){const n=(new Date).getTime();for(;!await e()&&n+t>(new Date).getTime();)await f.Sleep(i??100);return await e()}static async WaitUntilCondition(e,t){const i=(new Date).getTime();for(;i+t>(new Date).getTime();){if(await e())return!0;await f.Sleep(100)}return!1}static async WaitForSyncCondition(e,t){const i=(new Date).getTime();for(;i+t>(new Date).getTime();){if(e())return!0;await f.Sleep(100)}return!1}static IsValidDataField(e){return null!=e&&e.length>0&&"null"!==e}static IsPageMatch(e,t,i,n){let o=!1;if(f.IsValidDataField(e)&&(o=f.IsOnPage(e,i)),f.IsValidDataField(t))try{!n&&location.href?.toLocaleLowerCase()?.includes(i.toLocaleLowerCase())&&"chrome-untrusted://shopping/"!==location.href&&(n=location.href?.toLocaleLowerCase()),o=f.IsPageRegexMatch(t,n??i)}catch{}return o}static IsPageRegexMatch(e,t){return!!f.IsValidDataField(e)&&new RegExp(e).test(t.toLowerCase())}static IsOnPage(e,t){if(f.IsValidDataField(e)){const i=e.toLowerCase().replace(/\s+/g,"").split(","),n=t.toLowerCase();let o=!1;for(const e of i)if(n.indexOf(e)>=0){o=!0;break}return o}return!1}static ObserveUntil(e,t){const i=new MutationObserver((async()=>{e()&&(i.disconnect(),t())}));i.observe(document.body,{attributeFilter:["offsetWidth","offsetHeight"],childList:!0,subtree:!0})}static async MeasureExecutionTime(e,t){const i=performance.now();return await e(),performance.now()-i}static DeepAssign(e,t){return Object.keys(t).forEach((i=>{if("object"==typeof t[i])e[i]||Object.assign(e,{[i]:{}}),f.DeepAssign(e[i],t[i]);else{let n=t[i];"urlRegex"===i&&"string"==typeof n&&n.endsWith("/")&&(n=n.substring(0,n.length-1)),Object.assign(e,{[i]:n})}})),e}static scrollToModuleIfTargeted(e,t){(0,o.Mw)(n.uv)===t&&setTimeout((()=>{e?.scrollIntoView({behavior:"smooth",block:"start"}),localStorage.removeItem(n.uv)}),500)}}t.ZP=f},56854:function(e,t,i){"use strict";i.d(t,{r:function(){return r}});var n=i(4872),o=i(31656);function r(){return o.R.isExperimentActive(n.H.bgaaUx)||o.R.isExperimentActive(n.H.bgaaCheckoutOld)||o.R.isExperimentActive(n.H.bgaaNonCheckoutOld)}},18435:function(e,t){"use strict";t.Z=class{static IsOnCheckoutPage(e,t){return!(!t||!t.retailerData)&&t.retailerData.UpdateCurrentCheckoutPage(e)}static getQuantity(e,t){let i=t.querySelector(e);i||(i=t?.parentElement?.querySelector(e));const n=i?.innerText?.trim();let o=Number(n);try{if(isNaN(o)||0===o)if(["select","input"].includes(i?.nodeName.toLowerCase())){const i=t.querySelector(e);o=Number(i.value)}else{const e=/[-]{0,1}[\d]*[.]{0,1}[\d]+/g,t=i?.innerText?.trim().match(e);t&&t?.length>0&&(o=Number(t[0]))}}catch(e){o=-1}return isNaN(o)&&(o=-1),o}static isElementDisabled(e){return"disabled"===e.getAttribute("disabled")}}},50616:function(e,t,i){"use strict";var n=i(36493);t.Z=class{static getInitialPrice(e){if(e)return(0,n.K)(e)}static getAmazonClippingDiscount(e,t){let i;if(t&&e){const o=t.substring(t.search(/\d+/g)),r=o.search(/\s|%/);let a=o;-1!==r&&(a=o.substring(0,r)),i=(0,n.K)(a),t.search(/%/)>0&&(i=e*i/100)}return i}static getSimpleDomainName(e){let t;if(e?.length>0){const i=e.indexOf(".");i>0&&(t=e.charAt(0).toUpperCase()+e.substring(1,i))}return t}}},71544:function(e,t,i){"use strict";var n=i(72370),o=i(4872),r=i(31656),a=i(14732),s=i(5144);class l{static GetBuildVersion(){try{const e=navigator.userAgent.match(/Edg(?:A|iOS)?\/([0-9]+\.[0-9]+\.[0-9]+\.[0-9]+)/);if(e&&2===e.length)return e[1];throw Error("Invalid build version.")}catch(e){}}static IsBuildVersionSupported(e){const t=l.GetBuildVersion();if(void 0===t)return!1;const i=l.CompareBuildVersions(t,e);return void 0!==i&&i>=0}static CompareBuildVersions(e,t){if(e&&t){const i=e.split("."),n=t.split(".");if(4!==i.length||4!==n.length)return;for(let e=0;e<4;e++){const t=parseInt(i[e],10),o=parseInt(n[e],10);if(isNaN(t)||isNaN(o))return;if(t>o)return 1;if(o>t)return-1}return 0}}static IsOtherSellersExpActive(e){return"walmart.com"===e||r.R.isExperimentActive(o.H.showAmazonOtherSellers)}static GetClientName(){try{if(-1!==navigator.userAgent.toLowerCase().indexOf("android"))return s.BN.EdgeAndroid;if(/iPad|iPhone|iPod/.test(navigator.userAgent))return s.BN.EdgeiOS}catch(e){throw Error("Error getting client name")}return a.i.GetAppName()}static IsMobile(){return[s.BN.EdgeAndroid,s.BN.EdgeiOS].includes(l.GetClientName())}}(0,n.Z)(l,"enabledServiceFlights",""),t.Z=l},45822:function(e,t,i){"use strict";i.d(t,{$1:function(){return c},Ak:function(){return d},I2:function(){return g},P4:function(){return l},dQ:function(){return h},hy:function(){return a},io:function(){return u},nY:function(){return s},p_:function(){return f}});var n=i(4872),o=i(31656),r=i(5144);const a=e=>!!o.R.isExperimentActive(n.H.purchaseExtractionRefactor)||!("True"!==e?.retailerData?.settings?.other?.isPurchaseRefactorExpEnabled);function s(){return o.R.isExperimentActive(n.H.fragmentPageTypeFiltering)}function l(){return o.R.isExperimentActive(n.H.collectAllFragments)}function c(){return o.R.isExperimentActive(n.H.disablePageTypeCollectionForFragments)}function d(e){return!e||function(e){return![r.GV.HomePage,r.GV.SearchPage,r.GV.ProductPage].includes(e)}(e)}const u=(e,t)=>!(!e||!t)&&(t=(t=(t="("+t.toLowerCase()+")").replace(",","|")).replace("/","/"),new RegExp(t.toLowerCase()).test(e.toLowerCase())),h=(e,t,i)=>p(e,t,i)?r.GV.HomePage:r.GV.UnknownPage,p=(e,t,i)=>{if(e&&t){const n=e.endsWith(t)||e.endsWith(`${t}/`);if(n)return n;if(i)return e.endsWith(`${t}/${i}`)||e.endsWith(`${t}/${i}/`)}return!1},g=(e,t)=>{try{if(e.length>0&&t)for(const i of e)if(i.urlRegex&&u(t,i.urlRegex))return i.type===r.u3.PurchaseConfirmed?r.GV.ConfirmationPage:i.type===r.u3.Checkout?r.GV.CheckoutPage:r.GV.UnknownPage;return r.GV.UnknownPage}catch(e){return r.GV.UnknownPage}},f=(e,t)=>e?.orderConfirmationPageUrl&&u(t,e.orderConfirmationPageUrl)?r.GV.ConfirmationPage:e?.checkoutPageUrl&&u(t,e.checkoutPageUrl)?r.GV.CheckoutPage:e?.productPageUrlRegex&&u(t,e.productPageUrlRegex)||e?.productPageUrl&&u(t,e.productPageUrl)?r.GV.ProductPage:e?.searchQueryUrlRegex&&u(t,e.searchQueryUrlRegex)?r.GV.SearchPage:r.GV.UnknownPage},64641:function(e,t,i){"use strict";i.d(t,{C9:function(){return s},gx:function(){return c},jK:function(){return d},kU:function(){return o},sc:function(){return a},u3:function(){return l}});var n=i(27689);const o=(e,t)=>"amazon.com"===t?r(e,"purchaseId"):"walmart.com"===t?r(e,"pcid"):"target.com"===t?r(e,"orderId"):"",r=(e,t)=>{const i=e.split("?"),n=i.length>1?i[1].split("&"):[];let o="";return n.forEach((e=>{const i=e.split("=");2===i.length&&i[0]===t&&(o=i[1])})),o},a=(e,t)=>{const i=e.split("?");if(i.length<=1)return"";const n=[];i.forEach((e=>{const t=e.split("&");n.push(...t)}));for(const e of n){const i=e.split("=");if(2===i.length&&i[0]===t)return i[1]}return""},s=(e,t)=>{const i=(0,n.BQ)(e)??void 0,o=i?i[t]:void 0;return o?.cartDataStorageInfo?o?.cartDataStorageInfo:void 0},l=()=>Math.round((new Date).getTime()/1e3),c=e=>{e=(e=(e=e.replace(/\([^)]*\)/g,"")).replace(/[^0-9\.,]+/g,"")).replace(/[,]+/g,"");const t=parseFloat(e);return isNaN(t)?0:t},d=e=>e.replace(/[\d\., ]/g,"")},12727:function(e,t,i){"use strict";var n=i(72370),o=i(29247);class r{constructor(e){(0,n.Z)(this,"dao",void 0),this.dao=e}deleteSecretsInURL(e){if(!this.dao.getFeatureFlagEnabledByDefault(r.FeatureName))return e;if(!e||""===e)return"";const t=this.dao.getDataMaskRules();try{if(t&&t.length>0){const i=new URL(e),n=new URLSearchParams(i.search);let a=i.toString();for(const e of t)e.maskType===r.RemoverUrlParameter&&(n.delete(e.ruleValue),i.search=n.toString(),a=i.toString());return o.ZP.IsValidDataField(a)?a:e}}catch(t){return e}return e}getCurrentUrlValue(e,t){if(!e)return t;return this.deleteSecretsInURL(t)||""}maskDataInAString(e){if(!this.dao.getFeatureFlagEnabledByDefault(r.FeatureName))return e||"";if(!e||""===e)return"";const t=this.dao.getDataMaskRules();if(t){let i=e;for(const e of t)e.maskType===r.RegexMaskRule&&(i=i.replace(new RegExp(e.ruleValue),e.ruleName));return i}return e||""}maskDataInADocument(e){if(!this.dao.getFeatureFlagEnabledByDefault(r.FeatureName))return;if(!e)return;const t=this.dao.getDataMaskRules();if(t)for(const i of t)if(i.maskType===r.RemoveAllBySelector){const t=e.querySelectorAll(i.ruleValue);for(const e of t)e.innerHTML=i.ruleName}else if(i.maskType===r.RemoveFirstBySelector){const t=e.querySelector(i.ruleValue);t&&(t.innerHTML=i.ruleName)}}}(0,n.Z)(r,"RegexMaskRule","REGEX"),(0,n.Z)(r,"RemoverUrlParameter","REMOVE_URL_PARAMETER"),(0,n.Z)(r,"FeatureName","data_masking"),(0,n.Z)(r,"RemoveFirstBySelector","REMOVE_FIRST_BY_SELCTOR"),(0,n.Z)(r,"RemoveAllBySelector","REMOVE_ALL_BY_SELECTOR"),t.Z=r},32389:function(e,t){"use strict";t.Z=class{static getQuotientDate(e){if(e)return this.getQuotientDateFromDate(e);const t=6e4*(new Date).getTimezoneOffset();return new Date(Date.now()-t).toISOString().slice(0,-1).split(".")[0]+this.getTimeZone()}static getQuotientDateFromDate(e){const t=6e4*(new Date).getTimezoneOffset();return new Date(new Date(e).getTime()-t).toISOString().slice(0,-1).split(".")[0]+this.getTimeZone(e)}static getTimeZone(e){const t=e?new Date(e).getTimezoneOffset():(new Date).getTimezoneOffset(),i=Math.abs(t);return(t<0?"+":"-")+("00"+Math.floor(i/60)).slice(-2)+":"+("00"+i%60).slice(-2)}}},57550:function(e,t,i){"use strict";i.d(t,{An:function(){return d},FL:function(){return h},MK:function(){return g},Sq:function(){return a},en:function(){return c},j_:function(){return m},q6:function(){return v},rP:function(){return s},ru:function(){return u},wu:function(){return l},xJ:function(){return p}});var n=i(72370),o=i(75434);function r(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function a(e){let t=[];return e&&e.itemizedCashBackResponse&&e.itemizedCashBackResponse.offers&&e.itemizedCashBackResponse.offers.length>0&&(t=e.itemizedCashBackResponse.offers),t}function s(e,t){if(!t||!e)return e;const i=new Set,n=new Set,o=new Set;f(i,o,n,t);const r=function(e,t,i,n){return e.filter((e=>{if(e.pathname)return!n.has(e.pathname);const t=c(u(e.adsOffer.destinationUrl));return!t||!n.has(t.pathname)}))}(e,0,0,o);return r}function l(e){return e?.itemizedCashBackResponse?.adsMetadata?.visibilityFeedbackUrl||""}function c(e){try{if(!e)return;return new URL(u(e))}catch(t){(0,o.F0)(void 0,void 0,"Error in GetUrl for "+e,t)}}function d(e){const t=new Set,i=new Set,n=new Set;if(e){t.add(e.offerId);const o=c(u(e.destinationUrl));o&&i.add(o),f(i,n,t,e)}return{activatedOfferIds:t,activatedDestinationUrls:i,activatedDestinationUrlPathnames:n}}function u(e){if(!e)return"";let t=e;if(e.includes("&l1=")){const i=e.split("&l1=");i.length>1&&(t=i[1])}else if(e.includes("dest_url=")){const i=e.split("dest_url=");i.length>1&&(t=i[1])}return t}function h(e,t,i){const a={adsCashbackItem:void 0,currentPageProductId:"",activatedProductIds:new Set};try{const n=this.GetUrl(e.common.lastCommittedURL);if(!n)return void(0,o.F0)(e,t,"Error in IsPdpPageForActivatedAd. Cannot create url",void 0);const r=p(n,i);if(!r.isPdp||!r.productId)return;a.currentPageProductId=r.productId;const s=e.dataStoreModule.CashBackData?.personalizedCashback?.adsCashback??[];if(0===s.length)return a;let l;for(const e of s){const t=this.GetDestinationUrl(e.destinationUrl)||this.GetDestinationUrl(e.productUrl),n=this.GetUrl(t),o=n?p(n,i):void 0,s=o?.productId;s&&(a.activatedProductIds.add(s),s===r.productId&&(l=e))}return a.adsCashbackItem=l,a}catch(i){return(0,o.F0)(e,t,"Error in IsPdpPageForActivatedAd",i,void 0,function(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?r(Object(i),!0).forEach((function(t){(0,n.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):r(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}({},a)),a}}function p(e,t){const i={isPdp:!1,productId:""};if(t&&t.PdpData){const n=this.IsUrlMatchAll(e,t.PdpData);i.isPdp=n.isMatch,i.productId=n.matchKey}return i}function g(e,t){return e?e.startsWith("/th?")?`https://th.bing.com${e}`:e.startsWith("edge://image?https")?e.substring(13):e:t?.common?.resourcesEndpoint?t.common.resourcesEndpoint+"common/defaultProduct.svg":""}function f(e,t,i,n){const o=Date.now();n.adsCashback?.forEach((n=>{if(!(o>1e3*n.expireTimeEpoch)&&(n.globalOfferId&&i.add(n.globalOfferId),n.destinationUrl)){const i=c(u(n.destinationUrl));i&&(t.add(i.pathname),e.add(i))}}))}function m(e){const t=e.dataStoreModule.SPBItemizedCashbackData?.homePageSpbOffers?.homePageSpbOffers||[];let i=0;return t.forEach((e=>{e?.adsOffer?.promotionInformation?.rebateValue>i&&(i=e.adsOffer.promotionInformation.rebateValue)})),i}function v(e){const t=e.dataStoreModule.SPBItemizedCashbackData?.homePageSpbOffers?.homePageSpbOffers||[],i=e.dataStoreModule.GroceryCashbackData?.Cashback?.ItemizedCashback||[];return t.length+i.length}},18549:function(e,t,i){"use strict";var n=i(72370),o=i(88767),r=i(73557);function a(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function s(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?a(Object(i),!0).forEach((function(t){(0,n.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):a(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}t.Z=class{constructor(e,t,i,o,a){(0,n.Z)(this,"lowestPrice",-1),(0,n.Z)(this,"bestOffer",void 0),(0,n.Z)(this,"shouldBeInPolePosition",void 0),(0,n.Z)(this,"shouldRenderNotification",void 0),(0,n.Z)(this,"shouldRenderPriceComparisonNotification",void 0),(0,n.Z)(this,"shouldRenderCompositeNotification",void 0),(0,n.Z)(this,"hasAnomalousData",void 0),(0,n.Z)(this,"anomalousDataReason",void 0),(0,n.Z)(this,"MarketAnomalyThresholds",new Map([["en-us",1]])),this.setLowestPriceOfferData(e,t,i,a),this.shouldBeInPolePosition=this.ShouldBeInPolePosition(t,i),this.shouldRenderNotification=this.ShouldRenderNotification(t,e),this.shouldRenderPriceComparisonNotification=this.shouldRenderNotification&&o===r.sR.AUTO_SHOW_LOWER_PRICE_FOUND,this.shouldRenderCompositeNotification=this.shouldRenderNotification&&o===r.sR.AUTO_SHOW_LOWER_PRICE_PLUS_CASHBACK_PLUS_COUPONS}ShouldRenderNotification(e,t){return(e&&e.length>0&&t===o.Te.Auto)??!1}ShouldBeInPolePosition(e,t){if(e&&e.length>0&&t&&-1!==t){const e=this.lowestPrice,i=t-e;if(e>0&&i>0&&i>Math.ceil(.05*t))return!0}return!1}setLowestPriceOfferData(e,t,i,n){if(i&&-1!==i&&t&&t.length>0){let r,a=i;if(t.forEach((e=>{const t=e.IntendedPrice;t&&(e.promotionInformation?.rebateValue&&e.BillingType!==o.YO.NoCharge?t-Number(e.promotionInformation.rebateValue)<a&&(a=t-Number(e.promotionInformation.rebateValue),r=e):t<a&&(a=t,r=e))})),a<i&&r&&(this.lowestPrice=a,this.bestOffer=s({},r)),e!==o.Te.Auto)return;a=i,r=void 0;for(const e of t)if(e.ShouldOnTop){const t=e.IntendedPrice,o=Number(e.promotionInformation?.rebateValue),s=o&&!isNaN(o)?o:0;if(t){const o=t-s;o<a&&(this.isAboveAnomalyThreshold(i,o,n)?(a=t-s,a=Number(a.toFixed(2)),r=e):this.hasAnomalousData=!0)}}a<i&&r?(this.lowestPrice=a,this.bestOffer=s({},r)):(this.lowestPrice=-1,this.bestOffer=void 0)}}isAboveAnomalyThreshold(e,t,i){if(!i)return!0;const n=Math.abs(e-t),o=100*n/e,r=this.MarketAnomalyThresholds.get(i.toLowerCase())??void 0;return!(r&&(n<r?(this.anomalousDataReason="Price difference under threshold",1):(o<5||o>70)&&(this.anomalousDataReason="Savings not between 5% and 70%",1)))}}},36493:function(e,t,i){"use strict";i.d(t,{$g:function(){return h},Cl:function(){return u},Jl:function(){return s},K:function(){return o},N6:function(){return l},So:function(){return f},Vv:function(){return c},_B:function(){return a},cU:function(){return g},nR:function(){return m},qk:function(){return d},qm:function(){return p}});var n=i(64865);function o(e,t){if(!e)return 0;if(e.indexOf("-")>-1){const t=e.substring(0,e.indexOf("-")),i=e.substring(e.indexOf("-")+1),n=o(t),r=o(i),a=Math.min(n,r);if(isNaN(a))return 0;e=a.toString()}e=(e=e.replace(/\([^)]*\)/g,"")).replace(/[^0-9\.,]+/g,"");try{!1===r(e,t)&&(e=function(e){return e.replace(/[,.]/g,(e=>","===e?".":","))}(e))}catch{}return e=e.replace(/[,]+/g,""),parseFloat(e)}function r(e,t){if("$"===t)return!0;const i=e.lastIndexOf(","),n=e.lastIndexOf(".");return!(n>-1&&i>-1&&i>n||n>-1&&e.length-n-1>2||i>-1&&e.length-i-1<=2||-1===i&&-1===n&&(e=e.trim(),/\s/.test(e)))}function a(e,t){return e%1!=0?new Intl.NumberFormat(t,{maximumFractionDigits:2,minimumFractionDigits:2}).format(e):new Intl.NumberFormat(t).format(e)}function s(e){return e&&!(0,n.TF)(e)&&h(e)?e:"$"}function l(e){return C.get(e)}function c(e){return S.get(e)}function d(e){return x.get(e?.toLocaleUpperCase())??"$"}function u(e,t){return"$"===e&&"en-us"!==t||!h(e)?function(e){return e?l(e)??"$":"$"}(t):e}function h(e){return!(!e||!y)&&y.has(e)}function p(e){return b.has(e)??!1}function g(e,t){const i=e.replace(/[0-9,. ]/g,"").trim();for(const e of v)if(i.includes(e))return e;return t?function(e){return e&&!(0,n.TF)(e)&&h(e)?e:""}(i):s(i)}function f(e){return e.replace(/([^A-Za-z])/g,"\\$1")}function m(e,t){let i,n,o;t&&(i=g(e),e=e.replace(i,"").trim());const a=(r(e)?/([0-9,]+)[.]*([0-9]*)/:/([0-9.\s]+)[,]*([0-9]*)/).exec(e);return a&&3===a.length?(n=a[1],o=a[2],t?i?{dollars:n,cents:o,currency:i}:e:{dollars:n,cents:o}):e}const v=["$","₹","£","£","€","¥","¥","₽","元","₩","₱","đ","₫","฿","US$","CA$","AU$","MX$","C$","A$","R$","NZ$","COL$","NT$","£E","SG$","zł","S$","USD","INR","GBP","CAD","EUR","AUD","JPY","BRL","MXN","NZD","CNY","KRW","RUB","IDR","PHP","VND","THB","TWD","EGP","DKK","SEK","RM","MYR","AMD","CHF","PLN","NOK","SGD","CZK","TL","TRY","COP","ZAR","CLP","SAR","AED","Rp","dr.","Fr.","Kč","Rs","kr.","kr","R"],y=new Set(v),C=new Map([["en-us","$"],["en-gb","£"],["en-ca","CA$"],["en-au","AU$"],["en-in","₹"],["fr-fr","€"],["de-de","€"],["ja-jp","¥"],["it-it","€"],["nl-nl","€"],["es-es","€"],["en-nz","NZ$"],["pt-br","R$"],["zh-cn","元"],["es-mx","MX$"],["ko-kr"," ₩"],["ru-ru","₽"],["id-id","Rp"],["fil-ph","₱"],["vi-vn","đ"],["th-th","฿"],["zh-tw","NT$"],["ar-eg","EGP"],["de-at","€"],["da-dk","kr."],["de-ch","Fr."],["pl-pl","zł"],["sv-se","kr"],["en-my","RM"],["no-no","NOK"],["en-sg","S$"],["fi-fi","€"],["fr-be","€"],["cs-cz","Kč"],["tr-tr","TL"],["es-co","COL$"],["en-za","R"],["en-sa","SAR"],["en-eg","EGP"],["ar-ae","AED"]]),b=new Set(["USD","INR","GBP","EUR","NZD","BRL","CAD","AUD","JPY","CNY","MXN","KRW","RUB","IDR","PHP","VND","THB","TWD","EGP","DKK","CHF","PLN","SEK","MYR","NOK","SGD","CZK","TRY","COP","ZAR","CLP","SAR","AED"]),S=new Map([["$","USD"],["₹","INR"],["£","GBP"],["€","EUR"],["NZ$","NZD"],["R$","BRL"],["CA$","CAD"],["C$","CAD"],["A$","AUD"],["AU$","AUD"],["¥","JPY"],["¥","JPY"],["元","CNY"],["MX$","MXN"],["£","GBP"],["₩","KRW"],["₽","RUB"],["Rp","IDR"],["₱","PHP"],["đ","VND"],["₫","VND"],["฿","THB"],["NT$","TWD"],["EGP","EGP"],["kr.","DKK"],["Fr.","CHF"],["zł","PLN"],["dr.","SEK"],["RM","MYR"],["NOK","NOK"],["S$","SGD"],["Kč","CZK"],["TL","TRY"],["COL$","COP"],["R","ZAR"],["kr","DKK"],["SG$","SGD"],["SAR","SAR"],["AED","AED"],["AMD","AMD"]]),x=new Map([["USD","$"],["INR","₹"],["GBP","£"],["EUR","€"],["NZD","NZ$"],["BRL","R$"],["CAD","CA$"],["AUD","AU$"],["JPY","¥"],["CNY","元"],["MXN","MX$"],["GBP","£"],["KRW","₩"],["RUB","₽"],["IDR","Rp"],["PHP","₱"],["VND","đ"],["THB","฿"],["TWD","NT$"],["EGP","EGP"],["DKK","kr."],["CHF","Fr."],["PLN","zł"],["SEK","dr."],["MYR","RM"],["NOK","NOK"],["SGD","S$"],["CZK","Kč"],["TRY","TL"],["COP","COL$"],["ZAR","R"],["SAR","SAR"],["AED","AED"]])},91495:function(e,t,i){"use strict";i.d(t,{Q:function(){return r}});var n=i(72370),o=i(55590);const r=new class{constructor(){(0,n.Z)(this,"rawStorageObj",{}),(0,n.Z)(this,"storageObjStr",""),(0,n.Z)(this,"ICIsPendingTransactionPresent",void 0),(0,n.Z)(this,"ICCurrentPageInfo",void 0),(0,n.Z)(this,"OtherSellersNotificationData",void 0),(0,n.Z)(this,"OtherSellersAutoShowCount",void 0),(0,n.Z)(this,"OtherSellersLastAutoShowTime",void 0),(0,n.Z)(this,"CanSaveYoutubeCoupons",void 0),(0,n.Z)(this,"SocialCoupons",void 0),(0,n.Z)(this,"IsEntrolledInDealDaysNotifications",void 0),(0,n.Z)(this,"CartValues",void 0),(0,n.Z)(this,"CompletedPurchase",void 0),(0,n.Z)(this,"CompletedPurchaseConf",void 0),(0,n.Z)(this,"GiftCardData",void 0),(0,n.Z)(this,"GroceryCashbackItem",void 0),(0,n.Z)(this,"Anid",void 0),(0,n.Z)(this,"GroceryCashbackActivated",void 0),(0,n.Z)(this,"ICRelatedPDPOffer",void 0),(0,n.Z)(this,"ICAutoShownOffers",void 0),(0,n.Z)(this,"AutoOpenData",void 0),(0,n.Z)(this,"AutoOpenPrefData",void 0),(0,n.Z)(this,"AutoOpenDomainPrefData",void 0),(0,n.Z)(this,"LastCleanedData",void 0),(0,n.Z)(this,"LastShownData",void 0),(0,n.Z)(this,"StageAndCategoryLastShown",void 0),(0,n.Z)(this,"ICLastAutoShowTime",void 0),(0,n.Z)(this,"ICMetadata",void 0),(0,n.Z)(this,"PersistentWinCartData",void 0),(0,n.Z)(this,"ICActivatedPending",void 0),(0,n.Z)(this,"PrivacyBadgeViewCount",void 0),(0,n.Z)(this,"PersistentCartData",void 0),(0,n.Z)(this,"PersonalizedPromotionsCartData",void 0),(0,n.Z)(this,"PersistentTravelData",void 0),(0,n.Z)(this,"AutoClipData",void 0),(0,n.Z)(this,"RuleBasedTriggerData",void 0),(0,n.Z)(this,"ICPendingTransaction",void 0),(0,n.Z)(this,"AutosMarketplace",void 0),(0,n.Z)(this,"AutosMarketplaceNotification",void 0),(0,n.Z)(this,"BestCoupons",void 0),(0,n.Z)(this,"ICNotificationType",void 0),(0,n.Z)(this,"CashbackInfo",void 0),(0,n.Z)(this,"ICIsRelatedOffer",void 0),(0,n.Z)(this,"GroceryInstantAddToCart",void 0),(0,n.Z)(this,"GroceryInstantAddToCartSpb",void 0),(0,n.Z)(this,"GroceryMatchedCartSpbOffers",void 0),(0,n.Z)(this,"CheckoutPageNavigatedTime",void 0),(0,n.Z)(this,"DynamicTransactionId",void 0),(0,n.Z)(this,"GroceryAutoShowData",void 0),(0,n.Z)(this,"GroceryCategoryAutoShowData",void 0),(0,n.Z)(this,"ProductTrackingOOSLastShown",void 0),(0,n.Z)(this,"PackageTrackingConfirmationNotifLastShown",void 0),(0,n.Z)(this,"PcbNotificationLastShownAdCount",void 0),(0,n.Z)(this,"TrackedProductsData",void 0),(0,n.Z)(this,"UrlToProductMap",void 0),(0,n.Z)(this,"SidepaneCashback",void 0),(0,n.Z)(this,"ProductBestCouponConsent",void 0),(0,n.Z)(this,"PackagesNotified",void 0),(0,n.Z)(this,"ValidPackage",void 0),(0,n.Z)(this,"DealsForTopDomainsTimestamp",void 0),(0,n.Z)(this,"ICSpbHomePageShownTimestamp",void 0),(0,n.Z)(this,"ICSpbExpiryNotificationShownTime",void 0),(0,n.Z)(this,"PCBStorewideAddressBar",void 0),(0,n.Z)(this,"PCBStorewideAddressBarLastRequested",void 0),(0,n.Z)(this,"ShippingFee",void 0),(0,n.Z)(this,"InboxCouponsUserConsent",void 0),(0,n.Z)(this,"CartPageCashbackNotification",void 0),(0,n.Z)(this,"PriceMatchConsent",void 0),(0,n.Z)(this,"UnsuccessfulAutoApplyCount",void 0),(0,n.Z)(this,"ProductTrackingBackInStockValidationData",void 0),(0,n.Z)(this,"ProductTrackingPriceDropValidationData",void 0),(0,n.Z)(this,"PostPurchasePendingProducts",void 0),(0,n.Z)(this,"PostPurchasePathnameProducts",void 0),(0,n.Z)(this,"InboxCouponsHashedUserId",void 0),(0,n.Z)(this,"InboxCouponsLogsMetadata",void 0),(0,n.Z)(this,"InboxCouponsPaneOpen",void 0),(0,n.Z)(this,"IsNavigatedFromAddressBarPersonalizedCashback",void 0),(0,n.Z)(this,"IsNavigatedFromAddressBarCashback",void 0),(0,n.Z)(this,"IsNavigatedFromAddressBarCoupons",void 0),(0,n.Z)(this,"anidTrackingData",void 0),(0,n.Z)(this,"articlesCashback",void 0),(0,n.Z)(this,"PriceMatchNotificationData",void 0),(0,n.Z)(this,"BGAAApplyButtonClicked",void 0),(0,n.Z)(this,"ExclusiveCouponConsent",void 0),(0,n.Z)(this,"BlossomCampaignUserStatus",void 0),(0,n.Z)(this,"PurchaseCart",void 0)}Create(e){r.ICSpbExpiryNotificationShownTime=e[o.Q.ICSpbExpiryNotificationShownTime]??null,r.ICSpbHomePageShownTimestamp=e[o.Q.ICSpbHomePageShownTimestamp]??null,r.OtherSellersNotificationData=e.OtherSellersNotificationData,r.OtherSellersAutoShowCount=e.OtherSellersAutoShowCount,r.OtherSellersLastAutoShowTime=e.OtherSellersLastAutoShowTime,r.CanSaveYoutubeCoupons=e.CanSaveYoutubeCoupons??null,r.SocialCoupons=e.socialCoupons??null,r.IsEntrolledInDealDaysNotifications=e[o.Q.IsEntrolledInDealDaysNotifications]??null,r.CartValues=e.CartValues,r.CompletedPurchase=e.CompletedPurchase,r.CompletedPurchaseConf=e.CompletedPurchaseConf,r.GroceryCashbackItem=e[o.Q.GroceryCashbackItem],r.Anid=e[o.Q.UserAnid],r.GroceryInstantAddToCart=e[o.Q.GroceryInstantAddToCart],r.GroceryInstantAddToCartSpb=e[o.Q.GroceryInstantAddToCartSpb],r.GroceryMatchedCartSpbOffers=e[o.Q.GroceryMatchedCartSpbOffers],r.GroceryCashbackActivated=e[o.Q.GroceryCashbackActivated],r.ICAutoShownOffers=e[o.Q.ICAutoShownOffers],r.AutoOpenData=e.AutoOpenData??null,r.AutoOpenPrefData=e.AutoOpenPrefData??null,r.AutoOpenDomainPrefData=e.AutoOpenDomainPrefData??null,r.LastCleanedData=e.LastCleanedData??null,r.LastShownData=e.LastShownData??null,r.StageAndCategoryLastShown=e.StageAndCategoryLastShown??null,r.ICLastAutoShowTime=e.ICLastAutoShowTime,r.ICMetadata=e[o.Q.ICMetadata],r.ICActivatedPending=e[o.Q.ICActivatedPending],r.PrivacyBadgeViewCount=e.PrivacyBadgeViewCount,r.GiftCardData=e.GiftCardData??null,r.PersistentCartData=e.PersistentCartData??null,r.PersistentWinCartData=e.PersistentWinCartData??null,r.PersistentTravelData=e.PersistentTravelData??null,r.AutoClipData=e.AutoClipData??null,r.RuleBasedTriggerData=e.RuleBasedTriggerData??null,r.ICPendingTransaction=e.ICPendingTransaction??null,r.AutosMarketplace=e[o.Q.AutosMarketplace],r.AutosMarketplaceNotification=e[o.Q.AutosMarketplaceNotification],r.BestCoupons=e[o.Q.BestCoupons],r.CashbackInfo=e[o.Q.CashbackInfo],r.ICNotificationType=e[o.Q.ICNotificationType],r.ICIsRelatedOffer=e[o.Q.ICIsRelatedOffer],r.GroceryAutoShowData=e[o.Q.GroceryAutoShowData],r.GroceryCategoryAutoShowData=e[o.Q.GroceryCategoryAutoShowData],r.ProductTrackingOOSLastShown=e[o.Q.ProductTrackingOOSLastShown],r.PackageTrackingConfirmationNotifLastShown=e[o.Q.PackageTrackingConfirmationNotifLastShown],r.ICIsPendingTransactionPresent=e[o.Q.ICIsPendingTransactionPresent],r.ICCurrentPageInfo=e[o.Q.ICCurrentPageInfo],r.ICRelatedPDPOffer=e[o.Q.ICRelatedPDPOffer],r.PcbNotificationLastShownAdCount=e[o.Q.PcbNotificationLastShownAdCount],r.TrackedProductsData=e[o.Q.ProductTrackingTrackedProducts],r.UrlToProductMap=e[o.Q.ProductTrackingUrlProductCache],r.SidepaneCashback=e[o.Q.SidepaneCashback],r.ProductBestCouponConsent=e[o.Q.ProductBestCouponConsent],r.PackagesNotified=e[o.Q.PackagesNotified],r.ValidPackage=e[o.Q.ValidPackage],r.DealsForTopDomainsTimestamp=e[o.Q.DealsForTopDomainsTimestamp],r.PCBStorewideAddressBar=e[o.Q.PCBStorewideAddressBar],r.PCBStorewideAddressBarLastRequested=e[o.Q.PCBStorewideAddressBarLastRequested],r.ShippingFee=e[o.Q.ShippingFee],r.InboxCouponsUserConsent=e[o.Q.InboxCouponsUserConsented],r.CartPageCashbackNotification=e[o.Q.CartPageCashbackNotification],r.PriceMatchConsent=e[o.Q.PriceMatchConsent],r.UnsuccessfulAutoApplyCount=e[o.Q.UnsuccessfulAutoApplyCount],r.ProductTrackingBackInStockValidationData=e[o.Q.ProductTrackingBackInStockValidationData],r.ProductTrackingPriceDropValidationData=e[o.Q.ProductTrackingPriceDropValidationData],r.PostPurchasePendingProducts=e[o.Q.PostPurchasePendingProducts],r.PostPurchasePathnameProducts=e[o.Q.PostPurchasePathnameProducts],r.InboxCouponsHashedUserId=e[o.Q.InboxCouponsHashedUserId],r.InboxCouponsLogsMetadata=e[o.Q.InboxCouponsLogsMetadata],r.InboxCouponsPaneOpen=e[o.Q.InboxCouponsPaneOpen],r.IsNavigatedFromAddressBarPersonalizedCashback=e[o.Q.IsNavigatedFromAddressBarPersonalizedCashback],r.anidTrackingData=e[o.Q.ProductTrackingAnidData],r.PersonalizedPromotionsCartData=e[o.Q.PersonalizedPromotionsCartData],r.IsNavigatedFromAddressBarCashback=e[o.Q.IsNavigatedFromAddressBarCashback],r.IsNavigatedFromAddressBarCoupons=e[o.Q.IsNavigatedFromAddressBarCoupons],r.articlesCashback=e[o.Q.ArticlesCashback],r.PriceMatchNotificationData=e[o.Q.PriceMatchNotification],r.BGAAApplyButtonClicked=e[o.Q.BGAAApplyButtonClicked],r.ExclusiveCouponConsent=e[o.Q.ExclusiveCouponConsent],r.BlossomCampaignUserStatus=e[o.Q.BlossomCampaignUserStatus],r.CheckoutPageNavigatedTime=e[o.Q.CheckoutPageNavigatedTime],r.DynamicTransactionId=e[o.Q.DynamicTransactionId],r.PurchaseCart=e[o.Q.PurchaseCart]}setRawStorageObject(e){this.rawStorageObj=e}setStorageObjStr(e){this.storageObjStr=e}}},44092:function(e,t,i){"use strict";function n(){try{const e="__storage__test";return window.sessionStorage.setItem(e,""),window.sessionStorage.removeItem(e),!0}catch(e){return!1}}function o(e){return n()?window.sessionStorage.getItem(e):null}function r(e,t){n()&&window.sessionStorage.setItem(e,t)}i.d(t,{Lt:function(){return o},i8:function(){return r}})},33491:function(e,t,i){"use strict";i.d(t,{Ev:function(){return d},Mw:function(){return s},NN:function(){return g},Oh:function(){return r},Si:function(){return h},TJ:function(){return l},UZ:function(){return p},WN:function(){return a},Xo:function(){return u},hS:function(){return c}});let n=null;const o="test-shopping-localstorage",r="openSettingsPane";function a(e){let t;const i=s(e);if(i)try{return t=JSON.parse(i),t}catch(e){}return t}function s(e){let t=null;return g()&&(t=window.localStorage.getItem(e)),t}function l(e){g()&&window.localStorage.removeItem(e)}function c(e){try{const t=s(e);return t&&"undefined"!==t?JSON.parse(t):{}}catch(e){return{}}}function d(e,t){u(e,JSON.stringify(t))}function u(e,t){g()&&window.localStorage.setItem(e,t)}function h(e,t){const i=c(t),n=new Date,o=i[e],r=o?new Date(o.timestamp):null,a=r?n.getTime()-r.getTime():0;return Math.floor(a/1e3/60/60/24)>0&&(i[e]={},u(t,JSON.stringify(i)),!0)}function p(e){g()&&localStorage.removeItem(e)}function g(){try{if(null!==n)return n;"undefined"!=typeof window&&window?.localStorage&&(window.localStorage.setItem(o,o),window.localStorage.getItem(o),window.localStorage.removeItem(o),n=!0)}catch(e){n=!1}return n}},91897:function(e,t,i){"use strict";i.d(t,{EA:function(){return r},nQ:function(){return o},r2:function(){return a}});var n=i(64865);const o=864e5;function r(e){const t=e?new Date(e):new Date;return new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate()))}function a(e,t){if((0,n.TF)(e))return-1;const i=new Date(e),o=void 0===t?new Date:new Date(t),r=i?o.getTime()-i.getTime():0;return Math.floor(r/1e3/60/60)}},27689:function(e,t,i){"use strict";i.d(t,{AL:function(){return f},Ad:function(){return T},B7:function(){return x},BQ:function(){return u},Ek:function(){return p},Mu:function(){return w},Ow:function(){return b},S8:function(){return c},Sk:function(){return I},Wf:function(){return P},cz:function(){return h},dK:function(){return S},fZ:function(){return y},fm:function(){return s},m2:function(){return A},oO:function(){return d},og:function(){return g},pq:function(){return O},q:function(){return D},sT:function(){return l},sk:function(){return C},uE:function(){return m},uf:function(){return v}}),i(17204);var n=i(5144),o=i(88767),r=i(29247),a=i(36493);function s(e){return 0===e.length?e:e[0].toUpperCase()+e.slice(1)}function l(){return"BackgroundAutoApplyData_"+c()}function c(){return m(window.location.hostname)}function d(e){return e?e.replace(/\"|'/g,'\\"'):e}function u(e,t=!1){try{if(!e||"null"===e)return null;if(e.value&&(e=e.value),"string"==typeof e){if(t){const t=JSON.parse(e,r.BX);return t.value?JSON.parse(t.value,r.BX):t}const i=JSON.parse(e);return i.value?JSON.parse(i.value):i}return e}catch(e){return null}}function h(){try{return window.self!==window.top}catch(e){return!0}}function p(){return window.location.toString()}function g(e,t){if(e&&t&&""!==t){const i=t.split("|");for(const t of i)if(e.match(t))return t}return""}function f(){return document.title}function m(e){if(!e)return"";const t=e.toLowerCase().match(/(w){3}.?\./);return t&&null!=t.index&&t[0]?e.substring(t.index+t[0].length):e}function v(e,t){return e||t||"en-us"}function y(e,t,...i){let n="",o=Array.prototype.slice.call(arguments);return o=o.slice(1),t?(n=t=t.replace(/\$(.|$|\n)/g,(e=>void 0!==o[e[1]]?"$$"===e?"$":o[e[1]]:"$2")),n):n}function C(e,t){const i=k(t);return e.replace(o.iM.currency,i)}function b(e,t){const i=k(t),n=/^[a-zA-Z]+$/.test(i)?`${i} `:i;return e.replace(o.iM.currency,n)}function S(e,t,i){const o=e?.split("plural,")[1];let r="";if(o){const e=/([^\s]+)\s+\{([^\}]+)\}/g;let a=e.exec(o);for(;a;){if(a.length>2&&a[1].trim()===t){r=a[2];break}a=e.exec(o)}t===n.T4.Other&&null!=i&&(r=r.replace("#",i.toString()))}return r}function x(e,t,...i){const n=t.split("*br*");if(n.length>1)!function(e,t,...i){const n=e.length;let o=0;for(let r=0;r<n;r++){if(e[r].includes("$"))if(0===r)o=x(t,e[r],...i);else if(2===e[r].trim()?.length)t.append([...i][o]),o+=1;else{const n=document.createElement("DIV");o+=x(n,e[r],...[...i].slice(o)),t.appendChild(n)}else{const i=document.createElement("p");i.style.margin="0px",i.style.display="inline-block",i.textContent=e[r],t.append(i)}if(r!==n-1){const e=document.createElement("br");e.setAttribute("aria-hidden","true"),t.appendChild(e)}}}(n,e,...i);else{if(window?.trustedTypes){const t=window.trustedTypes.emptyHTML;e.innerHTML=t}const n=t.split(/\$\d/),o=n.length,r=i.length;for(let t=0;t<o;t++){if(n[t]=C(n[t]),0===t)e.textContent=n[t];else if(t===r){const i=1===n.slice(t).length,o=document.createTextNode(E(n.slice(t),i));e.appendChild(o)}else{const i=document.createTextNode(n[t]);e.appendChild(i)}if(t===o-1||t===r)return t;e.appendChild(i[t])}}return 0}function T(e){try{return JSON.parse(e)}catch(e){return null}}function w(e,t){try{return new URL(e.offerUrl).hostname!==t&&e.attribution!==t}catch(e){return!1}}function O(e){return!(!e||0!==e.offsetX||0!==e.offsetY)}function P(e){if(e)try{const t=JSON.parse(e);for(const e of t)if(e.includes("bing.com"))return e}catch(e){}}function A(e,t){return e?e.includes("?")?e+"&"+t:e+"?"+t:""}function E(e,t){return 0===e.length?"":1===e.length?t?e[0]:"$1"+e[0]:e[0]+E(e.slice(1),!1)}function k(e){e||(e="en-us");let t=(0,a.N6)(e);return t||(t="$"),t}const I="https://www.microsoft.com/legal/terms-of-use",D="http://go.microsoft.com/fwlink/?LinkId=518021"},43315:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(){(0,n.Z)(this,"productNames",null),(0,n.Z)(this,"productSellerNames",null),(0,n.Z)(this,"productIdSku",null),(0,n.Z)(this,"transactionId",null),(0,n.Z)(this,"purchaseTotal",null),(0,n.Z)(this,"numberOfItems",null),(0,n.Z)(this,"pricePerItem",null),(0,n.Z)(this,"quantityPerItem",null),(0,n.Z)(this,"orderConfirmationPageUrl",null),(0,n.Z)(this,"orderSubTotalPrice",null),(0,n.Z)(this,"orderDiscountPrice",null),(0,n.Z)(this,"orderDiscountCode",null),(0,n.Z)(this,"orderShippingPrice",null),(0,n.Z)(this,"orderTaxesPrice",null),(0,n.Z)(this,"currency",null),(0,n.Z)(this,"productUrls",null),(0,n.Z)(this,"personalizationDataConsent",null),(0,n.Z)(this,"dynamicTransactionId",null),(0,n.Z)(this,"productBrandNames",null)}}},33408:function(e,t,i){"use strict";i.d(t,{_p:function(){return xe}});var n=i(72370),o=i(64865),r=i(3634),a=i(95457),s=i(4872),l=i(31656),c=i(84830),d=i(82960),u=i(71951),h=i(5144),p=i(39088),g=i(21488),f=i(21597),m=i(88767),v=i(73557),y=i(55590),C=i(29247),b=i(71544),S=i(36493),x=i(33491),T=i(91495),w=i(27689),O=i(91221),P=i(90066),A=i(27900),E=i(60269),k=i(46261),I=i(1094),D=i(34802),_=i(50978),N=i(90650),R=i(87869),M=i(46557),L=i(52056),B=i(83879),F=i(43315),U=i(69315),H=i(68813);let $=function(e){return e.LogScriptTelemetry="LogScriptTelemetry",e.PurchaseCashbackConfirmation="PurchaseCashbackConfirmation",e.SetStorageValue="SetStorageValue",e.ClearStorageValue="ClearStorageValue",e.UpdateLoadTimeData="UpdateLoadTimeData",e.AutoShowFeaturesAvailable="AutoShowFeaturesAvailable",e.ReportRewardsActivity="ReportRewardsActivity",e}({});var Z=i(64641),V=i(11542),G=i(8018);class j{static GetItemizedCashbackService(){return this.itemizedCashbackService}static GetEdgeMessageService(){return this.edgeMessageService}}(0,n.Z)(j,"edgeMessageService",new class{SendPurchaseConfirmationMessage(){this.SendMessge($.PurchaseCashbackConfirmation,[])}SendStorageMessage(e,t){this.SendMessge($.SetStorageValue,[e,t])}ClearStorageValue(e){this.SendMessge($.ClearStorageValue,[e])}SendUpdateLoadTimeMessge(e){this.SendMessge($.UpdateLoadTimeData,[e])}TrySendAutoShowFeaturesAvailableMessage(e,t){return!!(0,H.Oh)(e,(0,H.tW)(),B.Z.GetLocalDataService().GetUserSettingsData())&&(this.SendMessge($.AutoShowFeaturesAvailable,[e.toString(),t]),!0)}ReportRewardsActivity(e,t,i){this.SendMessge($.ReportRewardsActivity,[e,t,i])}SendMessge(e,t){U.R.postMessageToHost(e,t)}}),(0,n.Z)(j,"itemizedCashbackService",new class{constructor(e){(0,n.Z)(this,"edgeMessageService",void 0),this.edgeMessageService=e}CheckGroceryCashBack(e,t,i,n){try{const o=(0,Z.kU)(e,t);if(!o)return!1;const r=i.isRebatesUser,a=this.getPendingTransaction(o,t,r);if(a)return this.addTransactionToPersistentStorage(t,a),this.edgeMessageService.SendStorageMessage(y.Q.ICNotificationType,JSON.stringify({value:G.c.Confirmation})),this.edgeMessageService.SendStorageMessage(y.Q.ICConfirmationPending,JSON.stringify({value:!0})),this.edgeMessageService.SendPurchaseConfirmationMessage(),this.edgeMessageService.SendUpdateLoadTimeMessge(n),!0}catch(e){}return!1}getPendingTransaction(e,t,i){const n=T.Q?.GroceryCashbackActivated,o=(n?(0,w.BQ)(n):{})[t]??void 0,r=o?.fullItems?Object.keys(o.fullItems):[],a=[],s=[];for(const e of r){const t=o.fullItems[e];if(t&&t.cashbackProducts&&t.cashbackProducts.length>0)for(const e of t.cashbackProducts)e.title&&a.push(e.title),e.productId&&s.push(e.productId),e.url&&V.Z.GetProductIdsFromUrl(e.url).filter((e=>!s.includes(e))).forEach((e=>s.push(e)))}const l=T.Q?.PersistentCartData||"",c=(0,Z.C9)(l,t);if(a.length>0&&c?.Products)for(const n of c.Products)if(a.includes(n.productTitle)||this.isProductFromUrlActivated(`https://www.${t}${n.productUrl}`,s))return this.makePendingTransactionToStorage(c,o,i,e)}isProductFromUrlActivated(e,t){const i=V.Z.GetProductIdsFromUrl(e);return!!t&&t.some((e=>i.includes(e)))}makePendingTransactionToStorage(e,t,i,n){return{addedTimestamp:(0,Z.u3)(),groceryActivatedData:t,groceryOrder:e,isSigninBeforePurchase:i,purchaseIdFromUrl:n,transactionId:n}}addTransactionToPersistentStorage(e,t){const i=(0,w.BQ)(T.Q.ICPendingTransaction)??{};i[e]=t,this.edgeMessageService.SendStorageMessage(y.Q.ICPendingTransaction,JSON.stringify({value:JSON.stringify(i)}))}}(j.GetEdgeMessageService()));var z=j,W=i(56577),K=class{constructor(){(0,n.Z)(this,"productIdSelector",void 0),(0,n.Z)(this,"productIdSkuSelector",void 0),(0,n.Z)(this,"productPriceSelector",void 0),(0,n.Z)(this,"productQuantitySelector",void 0),(0,n.Z)(this,"productImageSelector",void 0)}},q=class{constructor(){(0,n.Z)(this,"confirmationPageUrl",void 0),(0,n.Z)(this,"bookingIdSelector",void 0),(0,n.Z)(this,"totalPriceSelector",void 0),(0,n.Z)(this,"startDateSelector",void 0),(0,n.Z)(this,"endDateSelector",void 0),(0,n.Z)(this,"domainType",void 0),(0,n.Z)(this,"nameSelector",void 0),(0,n.Z)(this,"isRoundTripSelector",void 0)}};class Y{constructor(){(0,n.Z)(this,"domainName",void 0),(0,n.Z)(this,"orderConfirmationPageUrl",void 0),(0,n.Z)(this,"orderConfirmationRegex",void 0),(0,n.Z)(this,"confirmationPageTelemetry",void 0),(0,n.Z)(this,"orderDetailsPageUrl",void 0),(0,n.Z)(this,"productNameSelector",void 0),(0,n.Z)(this,"productPageUrl",void 0),(0,n.Z)(this,"cancellationPageTelemetry",void 0),(0,n.Z)(this,"travelConfirmationPageTelemetry",void 0),(0,n.Z)(this,"exactConfirmationPageUrl",void 0),(0,n.Z)(this,"allAutomatedSelectors",void 0),(0,n.Z)(this,"settings",void 0)}static Create(e){const t=new Y;return e&&(t.domainName=e.domainName,t.orderConfirmationPageUrl=e.orderConfirmationPageUrl,t.orderConfirmationRegex=e.orderConfirmationRegex,t.orderDetailsPageUrl=e.orderDetailsPageUrl,t.productNameSelector=e.productNameSelector,t.productPageUrl=e.productPageUrl,t.exactConfirmationPageUrl=e.exactConfirmationPageUrl,t.settings=e.settings,e.confirmationPageTelemetry&&(t.confirmationPageTelemetry=this.CreateConfirmationPageTelemetryData(e.confirmationPageTelemetry)),e.cancellationPageTelemetry&&(t.cancellationPageTelemetry=this.CreateCancellationPageTelemetryData(e.cancellationPageTelemetry)),e.travelConfirmationPageTelemetry&&(t.travelConfirmationPageTelemetry=this.CreateTravelConfirmationPageTelemetryData(e.travelConfirmationPageTelemetry)),e.allAutomatedSelectors&&(t.allAutomatedSelectors=this.createAutomatedSelectorsPageList(e.allAutomatedSelectors))),t}static CreateCancellationPageTelemetryData(e){const t=new class{constructor(){(0,n.Z)(this,"cancellationPageUrlRegex",void 0),(0,n.Z)(this,"transactionIdSelector",void 0),(0,n.Z)(this,"cancellationTextSelector",void 0),(0,n.Z)(this,"productTitleSelector",void 0),(0,n.Z)(this,"productQuantitySelector",void 0),(0,n.Z)(this,"pricePerItemSelector",void 0),(0,n.Z)(this,"totalPriceSelector",void 0)}};return t.cancellationPageUrlRegex=e.cancellationPageUrlRegex,t.transactionIdSelector=e.transactionIdSelector,t.cancellationTextSelector=e.cancellationTextSelector,t.productTitleSelector=e.productTitleSelector,t.productQuantitySelector=e.productQuantitySelector,t.pricePerItemSelector=e.pricePerItemSelector,t.totalPriceSelector=e.totalPriceSelector,t}static CreateConfirmationPageTelemetryData(e){const t=new class{constructor(){(0,n.Z)(this,"transactionIdSelector",void 0),(0,n.Z)(this,"purchaseTotalSelector",void 0),(0,n.Z)(this,"numItemsSelector",void 0),(0,n.Z)(this,"productDetailsData",void 0),(0,n.Z)(this,"orderIdSelectors",void 0),(0,n.Z)(this,"orderSubTotalPriceSelector",void 0),(0,n.Z)(this,"orderDiscountPriceSelector",void 0),(0,n.Z)(this,"orderDiscountCodeSelector",void 0),(0,n.Z)(this,"orderShippingPriceSelector",void 0),(0,n.Z)(this,"orderTaxesPriceSelector",void 0),(0,n.Z)(this,"isHtmlFragmentCollectionEnabled",void 0),(0,n.Z)(this,"isCartCachingEnabled",void 0),(0,n.Z)(this,"confirmationPageValidationSelector",void 0)}};return t.purchaseTotalSelector=e.purchaseTotalSelector,t.transactionIdSelector=e.transactionIdSelector,t.numItemsSelector=e.numItemsSelector,t.orderIdSelectors=e.orderIdSelectors,t.orderDiscountCodeSelector=e.orderDiscountCodeSelector,t.orderDiscountPriceSelector=e.orderDiscountPriceSelector,t.orderShippingPriceSelector=e.orderShippingPriceSelector,t.orderSubTotalPriceSelector=e.orderSubTotalPriceSelector,t.orderTaxesPriceSelector=e.orderTaxesPriceSelector,t.isHtmlFragmentCollectionEnabled=e.isHtmlFragmentCollectionEnabled,t.isCartCachingEnabled=e.isCartCachingEnabled??!0,t.confirmationPageValidationSelector=e.confirmationPageValidationSelector,e&&e.productDetailsData&&(t.productDetailsData=this.CreateProductDetailsData(e.productDetailsData)),t}static CreateProductDetailsData(e){const t=[];for(const i of e)if(i){const e=new K;e.productIdSelector=i.productIdSelector,e.productIdSkuSelector=i.productIdSkuSelector,e.productPriceSelector=i.productPriceSelector,e.productQuantitySelector=i.productQuantitySelector,e.productImageSelector=i.productImageSelector,t.push(e)}return t}static CreateTravelConfirmationPageTelemetryData(e){const t=[];for(const i of e)if(i){const e=new q;e.bookingIdSelector=i.bookingIdSelector,e.confirmationPageUrl=i.confirmationPageUrl,e.domainType=i.domainType,e.startDateSelector=i.startDateSelector,e.endDateSelector=i.endDateSelector,e.totalPriceSelector=i.totalPriceSelector,e.nameSelector=i.nameSelector,t.push(e)}return t}static createAutomatedSelectorsPageList(e){const t=[];for(const i of e)t.push(C.ZP.DeepAssign(new W.ZP,i));return t}}var X=Y,J=class{constructor(){(0,n.Z)(this,"retailerData",void 0),(0,n.Z)(this,"impressionId",void 0),(0,n.Z)(this,"cashback",void 0),(0,n.Z)(this,"platform",void 0),(0,n.Z)(this,"orderConfirmationPageUrlRegex",void 0)}},Q=class{constructor(){(0,n.Z)(this,"name",void 0),(0,n.Z)(this,"domainType",void 0),(0,n.Z)(this,"bookingId",void 0),(0,n.Z)(this,"price",void 0),(0,n.Z)(this,"orderConfirmationPageUrl",void 0),(0,n.Z)(this,"startDate",void 0),(0,n.Z)(this,"endDate",void 0),(0,n.Z)(this,"currency",void 0),(0,n.Z)(this,"isRoundTrip",void 0),(0,n.Z)(this,"personalizationDataConsent",void 0)}},ee=i(92572),te=i(86743),ie=i(15267),ne=i(45822),oe=i(73765),re=i(82315);function ae(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function se(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?ae(Object(i),!0).forEach((function(t){(0,n.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):ae(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}let le="",ce="";async function de(e,t){try{const i=e[0],n=JSON.parse(i),c=function(e){if(e){const t=new J;return e.retailerData&&(t.retailerData=X.Create(e.retailerData),t.platform=e.retailerData.platform,t.orderConfirmationPageUrlRegex=e.retailerData.orderConfirmationPageUrl),e.impressionId&&(t.impressionId=e.impressionId),t}return new J}(n),d=n.aFDMarket,p=n.personalizedAdsResponse?.personalizedCashback,S=n?.isPackageTrackingEnabled??!1,O=n?.cashback;ce=c.impressionId??"",a.Z.Create(n?.itemLevelCashBack?.domainData);const A=n?.userInfo?.isAADSignedIn??!1,D=n?.userInfo?.isMSASignedIn??!1,_=n?.userInfo?.isPersonalizationDataConsentEnabled??!1;if(!t)return le=e[1],!0;let F,U,H=!1,$=!1;e.length>2&&(F=e[2]);try{U=function(e){let t;return e.length>f.$R.enabled_service_features&&e[f.$R.enabled_service_features].length>0?t=e[f.$R.enabled_service_features]:e.length>f.$R.confirmation_enabled_service_features_v2&&e[f.$R.confirmation_enabled_service_features_v2].length>0&&(t=e[f.$R.confirmation_enabled_service_features_v2]),t}(e),l.R.Create(F,U),H=l.R.isExperimentActive(s.H.sustainability),$=l.R.isExperimentActive(s.H.postPurchaseTracking)}catch(e){ge({Domain:(0,w.S8)(),PageUrl:(0,w.Ek)()},"ConfirmationPageValidation","Unable to find experiments: "+e,h.in.Error)}let Z,V="";if(e.length>3)try{if(V=e[3],!(0,o.TF)(V)){const e=JSON.parse(V);T.Q.Create(e),T.Q.setRawStorageObject(e)}}catch(e){ge({Domain:(0,w.S8)(),PageUrl:(0,w.Ek)()},"ConfirmationPageValidation","Unable to find persistentStorageData"+e,h.in.Error)}e.length>5&&(Z=e[5]),e.length>=8&&(b.Z.enabledServiceFlights=e[7]);let G=!1;e.length>=10&&(G="1"===e[9]);let j,W=!1;e.length>=11&&(W="1"===e[10]),e.length>=12&&(j=e[11]);let K="";e.length>=13&&(K=e[12]),B.Z.GetLocalDataService().SetUserSettingsData(e,f.$R.confirmation_user_cohort_data,l.R.isExperimentActive(s.H.shoppingCohorts));const q=function(e,t,i,n,o){try{if((0,ne.hy)(e)){const r=re.Z.createNewApiResponse(JSON.stringify(e),i,t),a=B.Z.GetLocalDataService()?.GetSessionIds();if(ee.Z.initFactory(r,a,n,o),ee.Z.getFactory().getPurchaseExtractionService().isPurchaseExtractionEnabled())return!1}}catch(e){fe("Failed to instantiate cashback injected factory")}return!0}(n,ce,le,Z??"",K??""),Y=function(e){const t=e.retailerData;try{if(t){const e=t.orderConfirmationRegex;if(e&&""!==e)return atob(e)}}catch(e){ge({Domain:(0,w.S8)(),PageUrl:(0,w.Ek)(),Status:"Error"},"ConfirmationPageValidation","ConfirmationPageValidationError: GetConfirmationPattern "+e+" Regex: "+t.orderConfirmationRegex,h.in.Error)}return null}(c);if(function(e,t){return e||t?.retailerData?.confirmationPageTelemetry?.transactionIdSelector||t?.retailerData?.confirmationPageTelemetry?.purchaseTotalSelector||t?.retailerData?.confirmationPageTelemetry?.confirmationPageValidationSelector||t?.retailerData?.travelConfirmationPageTelemetry?.length||t?.retailerData?.allAutomatedSelectors}(Y,c))(0,x.UZ)(k.Wi),(0,C.dz)((async()=>ue(Y,c.retailerData)),5e3).then((async i=>{if(!i){if(("super.com"===c?.retailerData.domainName||"livesuper.com"===c?.retailerData.domainName)&&c?.retailerData.confirmationPageTelemetry?.transactionIdSelector){const e=c?.retailerData.confirmationPageTelemetry?.transactionIdSelector??"";await(0,C.dz)((async()=>void 0!==P.Z.GetFirstVisibleElement(e)),25e3,250).then((e=>{e&&(i=!0)}))}const r=function(e,t){const i=e?.retailerData?.allFinalCheckoutPages;if(!i)return"";if((0,o.TF)(t))return"";const n=i.find((e=>t.includes(e?.checkoutPageUrl))),r=n?.finalCheckoutButtonSelector;return r}(n,c.retailerData.orderConfirmationPageUrl);!function(e,t){if((0,o.TF)(e))return;P.Z.GetAllVisibleElements(e).forEach((e=>function(e,t){e.addEventListener("click",t)}(e,t)))}(r,(async()=>{(0,C.dz)((async()=>ue(Y,c.retailerData)),2e4).then((i=>{i&&de(e,t)}))}))}let a=!1;const u=c?.retailerData?.domainName??"";if(i){const e=g.Z.Create(n);a=z.GetItemizedCashbackService().CheckGroceryCashBack(window.location.href,u,e,le)}i&&$&&function(e,t){const i=(0,w.S8)();if(r.kH.includes(i)&&t){const n=!0===(0,w.BQ)(T.Q.PriceMatchConsent),o=r.PK[i]?.hasCsrError,a={Domain:(0,w.S8)(),PageUrl:(0,w.Ek)(),DebugData:JSON.stringify({isUserConsented:n,hasCsrError:o})};if(ge(a,"ConfirmationPageValidation","TryAndSendPostPurchaseRequest: Eligible confirmation page detected",h.in.Information),n&&!o)(async function(e,t,i){try{const i=Re(e,t,"Extension/Injected/ConfirmationPage"),n="https://www.bing.com/api/shopping/v1/savings/product-tracking/track-batch-products",o=await fetch(n,i);return await o.json()}catch(e){return ge({Domain:(0,w.S8)(),PageUrl:(0,w.Ek)(),DebugData:JSON.stringify({e:e})},"ConfirmationPageValidation","sendPostPurchaseRequest: Uncaught error",h.in.Error),{success:!1}}})(e,t).then((e=>{e.success?ge(a,"ConfirmationPageValidation","TryAndSendPostPurchaseRequest: Tracking successful",h.in.Information):ge(a,"ConfirmationPageValidation","TryAndSendPostPurchaseRequest: Tracking unsuccessful",h.in.Error)})).catch((e=>{ge({Domain:(0,w.S8)(),PageUrl:(0,w.Ek)(),DebugData:JSON.stringify({error:e})},"ConfirmationPageValidation","TryAndSendPostPurchaseRequest: Uncaught error",h.in.Error)}));else{const i=Re(e,t,"Extension/UX/PendingProducts");i&&z.GetEdgeMessageService().SendStorageMessage(y.Q.PostPurchasePendingProducts,JSON.stringify({value:{request:i,timestamp:Date.now()}}))}}}(B.Z.GetCartExtractionService().GetAvailableCartData(),j);const f=B.Z.GetCancellationPageDataExtractionService();f.isCancellationPageValid(c.retailerData)&&(f.GetAndSendCancellationPageData(c.retailerData,ce),i=!1),me(i,c,p,O,S,Z,j,K,A,D,_,d,q),l.R.isExperimentActive(s.H.sanConsent)&&l.R.isExperimentActive(s.H.sanConfirmationMessage)&&i&&!a&&!G&&W&&(z.GetEdgeMessageService().TrySendAutoShowFeaturesAvailableMessage(v.sR.AUTO_SHOW_SAN_CONSENT_CONFIRMATION,m.sM.SAN_CONSENT_NOTIFICATION)||pe({},v.sR.AUTO_SHOW_SAN_CONSENT_CONFIRMATION))})).catch((e=>{fe(e?.message??"confirmationpage error.")}));else{const e=function(){try{const e=(0,x.Mw)(k.Wi);if(!e)return null;const t=JSON.parse(e);if(!t.CheckoutButtonClicked||Date.now()-t.CheckoutTime>k.LE){(0,x.UZ)(k.Wi);const e=t.CartValue;return he("Expired checkout status data in confirmation page script","Error",t.CartId,e?.OrderTotal,e?.Currency),null}return(0,x.UZ)(k.Wi),t}catch(e){return null}}();if(!e)return me(!1,c,p,O,S,Z,j,K,A,D,_,d,q),he("no checkout status","Failed",""),!1;const t=function(e){if(e){const t=new E.Z;return e.retailerData&&(t.retailerData=M.Z.Create(e.retailerData)),e.impressionId&&(t.impressionId=e.impressionId),t}return new E.Z}(n);let i=new R.L;(0,C.dz)((async()=>(i=function(e){e.retailerData.updateCurrentFinalCheckoutPage(I.Z.GetCurrentPathName());const t=e?.retailerData?.getCurrentFinalCheckoutPage();return function(e){const t=new R.L;if(t.indicators=[],t.purchaseFailed=!1,e&&P.Z.GetAllVisibleElements(e?.finalCheckoutButtonSelector).length>0)return t.purchaseFailed=!0,t.indicators.push(R.c.finalCheckoutButtonVisible),t;const i=P.Z.GetFirstVisibleElement("body");return N.ZP.PageIncludesPaymentKeyWords(i?.innerText.toLocaleLowerCase(),N.lD)?(t.purchaseFailed=!1,t.indicators.push(R.c.successfulPaymentKeywordsFound),t):(N.ZP.PageIncludesPaymentKeyWords(i?.innerText.toLocaleLowerCase(),N.si)&&(t.purchaseFailed=!0,t.indicators.push(R.c.failurePaymentKeywordsFound)),P.Z.GetAllVisibleElements("input").length>0&&(t.purchaseFailed=!0,t.indicators.push(R.c.inputFieldsFound)),t)}(t)}(t),i.indicators.length>0)),5e3).then((()=>{me(!!H&&!i.purchaseFailed,c,p,O,S,Z,j,K,A,D,_,d,q),function(e,t,i,n){const o=e?"Failed":"Succeeded";e||(0,x.Mw)(u.y$.autoApplyStorageKey)===u.M4.ActionDetected&&(L.Z.SendStringStorageMessage(u.y$.completedPurchaseStorageKey,u.M4.ActionDetected),(0,x.Xo)(u.y$.completedPurchaseStorageKey,u.M4.ActionDetected)),he(JSON.stringify(n),o,t,i.OrderTotal,i.Currency)}(i.purchaseFailed,e.CartId,e.CartValue,i.indicators)})).catch((t=>{me(!1,c,p,O,S,Z,j,K,A,D,_,d,q),he(t?.message??"Error evaluating purchase status on confirmation page","Error",e.CartId,e.CartValue?.OrderTotal,e.CartValue?.Currency)}))}return!1}catch(e){return ge({Domain:(0,w.S8)(),PageUrl:(0,w.Ek)(),Status:"Error"},"ConfirmationPageValidation","Confirmation page validation error: "+e,h.in.Error),!1}}function ue(e,t){if(t?.confirmationPageTelemetry?.confirmationPageValidationSelector){const e=L.Z.GetBoxValue(t.confirmationPageTelemetry.confirmationPageValidationSelector);return null!=e&&""!==e}if(e&&""!==e){const t=document?.body?.getElementsByTagName("*"),i=new RegExp(e,"i");for(let e=0;e<=t?.length;e++)if(void 0!==t[e]&&null!==t[e]&&null!==t[e].textContent&&t[e].textContent?.match(i))return!0}if(t?.confirmationPageTelemetry?.transactionIdSelector){const e=t.confirmationPageTelemetry.transactionIdSelector;let i=L.Z.GetBoxValue(e);if(i||(i=(0,ie.ql)(e,(0,w.Ek)())),i)return!0;ke("confirmation page detection Error",{message:`transaction id not found for selector ${e}`})}if(t?.travelConfirmationPageTelemetry?.length)for(const e of t.travelConfirmationPageTelemetry)if(e.bookingIdSelector&&""!==e.bookingIdSelector){const t=L.Z.GetBoxValue(e.bookingIdSelector);if(null!=t&&""!==t)return!0}return!!function(e){try{if(e?.allAutomatedSelectors){const t=(0,w.Ek)();for(const i of e.allAutomatedSelectors)if(i.type===h.u3.PurchaseConfirmed&&i.urlRegex&&(0,ne.io)(t,i.urlRegex))return!0}}catch(e){return ke("confirmation page detection Error",{message:"not a valid confirmation page"}),!1}return!1}(t)||(ke("confirmation page detection Error",{message:"not a valid confirmation page"}),!1)}function he(e,t,i,n,o){ge({CartId:i,Currency:o,Domain:(0,w.S8)(),PageUrl:(0,w.Ek)(),StartingPrice:n??-1,Status:t},"PurchaseConfirmation","Confirmation page: "+e,"Information")}function pe(e,t){const i={userSettingsData:B.Z.GetLocalDataService().GetUserSettingsData(),popupOrigination:v.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_CONFIRMATION};ge(e,"ConfirmationPageValidation",`Blocked by User Cohort:${JSON.stringify(i)}`,h.in.Information)}function ge(e,t,i,n){const o={};o.JsonData=JSON.stringify(e),o.EventType=t,o.LogLevel=n,o.Message=i,o.ClientContext=new c.Z(b.Z.GetClientName(),p.yJ,b.Z.GetBuildVersion(),b.Z.enabledServiceFlights),ce&&(o.ImpressionId=ce);const r=[JSON.stringify(o)];U.R.postMessageToHost("LogScriptTelemetry",r)}function fe(e){ge({Domain:(0,w.S8)(),PageUrl:(0,w.Ek)(),Status:"error"},"ConfirmationPageValidation",e,h.in.Information),U.R.postMessageToHost("ConfirmationPageValidationError",["error",le])}function me(e,t,i,n,o,a,u,g,f,C,S,E,k){o&&(O.Z.hasNotificationBeenShownRecently(y.Q.PackageTrackingConfirmationNotifLastShown,r.LJ)||(async function(e,t){const i=e?.retailerData?.confirmationPageTelemetry?.transactionIdSelector,n=e?.retailerData?.confirmationPageTelemetry?.orderIdSelectors;if(!i&&!n)return;let o="",a="";try{const s=(0,w.Ek)();if(o=L.Z.GetBoxValue(i??""),o&&""!==o)a=o;else if(r.Z3.has(e?.retailerData?.domainName)){const t=r.Z3.get(e?.retailerData?.domainName);t&&s.includes(t)&&(a=(0,ie.Tb)(t,s))}else if(n?.startsWith(r.js)){const e=(0,ie.vU)(n,s);e&&(a=e)}else if(n?.startsWith(r.m7)){const e=(0,ie.AS)(n,s);e&&(a=e)}else a=await Ee(n);if(a&&""!==a||r.RY.has(e?.retailerData?.domainName)){const i=/(?:#\s*)([^\s|]*)/gi;a=i.exec(a??"")?.at(1)??a??"";const n={email:null,isOrderConfirmationPage:t,orderNumber:a,phoneNumber:null,trackingUrl:e?.retailerData?.orderDetailsPageUrl},o=JSON.stringify(n);U.R.postMessageToHost("ConfirmationPageData",[o,le])}}catch(e){}}(t,e),L.Z.SendStorageMessage(y.Q.PackageTrackingConfirmationNotifLastShown,JSON.stringify({value:(new Date).toUTCString()})))),U.R.postMessageToHost("ConfirmationPageValidationStatus",[e?"true":"false",le]),e&&(function(e,t){const i="IS_ELIGIBLE_FOR_REWARDS_"+(0,w.S8)(),n=T.Q?.rawStorageObj[i];if("true"===n&&!_e(t.personalizedCashback)){z.GetEdgeMessageService().ClearStorageValue(i);const e=JSON.stringify({offerid:"coupons_50points_202403"}),t="712",n="1";z.GetEdgeMessageService().ReportRewardsActivity(e,t,n);const o=JSON.stringify({attributes:e,type:t,amount:n});ge(new oe.Z((0,w.S8)(),h.oN.AARewards,location.pathname,h.zy.OrderPurchased,o),h.R.ShoppingRewards,"Order Purchased",h.in.Information)}}(0,n),ge({Domain:(0,w.S8)(),PageUrl:(0,w.Ek)(),Status:"Success"},"ConfirmationPageValidation","Confirmation page detected",h.in.Information),async function(e,t,i,n,o,r,a,u,g,f,C){const S=B.Z.GetLocalDataService(),O=S.GetSessionIds()?.retailerSessionId??"",E=S.GetSessionIds()?.pageVisitId??"",k={Domain:(0,w.S8)(),PageUrl:(0,w.Ek)(),PageVisitId:E,RetailerSessionId:O};let I;try{if(e?.retailerData?.travelConfirmationPageTelemetry)I=await async function(e,t,i){if(null==e?.retailerData?.travelConfirmationPageTelemetry)return;let n,o=null;const r=e.retailerData.travelConfirmationPageTelemetry;for(const t of r)if(t.confirmationPageUrl&&new RegExp(t.confirmationPageUrl).test((0,w.Ek)())&&(n=await Ce(t,e.retailerData.domainName,e.platform,i),n?.travelConfirmationDetails)){o=n.travelConfirmationDetails;break}let a=d.Z.uuidv4();if(a&&""!==a||(a=Te()),o){let e=!0;if(o.bookingId){const t=(0,x.Mw)(o.bookingId);t&&Date.now()-Date.parse(t)<12096e5?e=!1:(0,x.Xo)(o.bookingId,Date.now().toString())}if(e){let e="Travel confirmation page telemetry";n?.error&&(e+="; "+n.error);const i=function(e,t,i,n){const o={BookingId:t.bookingId,Currency:t.currency,Domain:(0,w.S8)(),DomainType:t.domainType,EndDate:t.endDate,EventId:i,Name:t.name,OrderConfirmationPageUrl:t.orderConfirmationPageUrl,Price:t.price,RGuid:n?.rGuid,StartDate:t.startDate,IsRoundTrip:t.isRoundTrip,PersonalizationDataConsent:t.personalizationDataConsent},r={};r.JsonData=JSON.stringify(o),r.EventType="TravelConfirmationPageDetails",r.LogLevel="Information",r.Message=e,r.ClientContext={AppInfoClientName:b.Z.GetClientName(),JSVersion:p.yJ},ce&&(r.ImpressionId=ce);const a=[JSON.stringify(r)];return U.R.postMessageToHost("LogScriptTelemetry",a),o}(e,o,a,t);return await ye(a,"TravelConfirmationPage"),i}}else ge({Domain:(0,w.S8)(),PageUrl:(0,w.Ek)()},"ConfirmationPageValidation",(n?.error??" ")+"confirmationpage cart details extraction error.",h.in.Error)}(e,t,g);else if(e?.retailerData?.confirmationPageTelemetry){let o;const S=!!e?.retailerData?.settings?.other?.disableExpiredCartExtraction&&"true"===e.retailerData.settings.other.disableExpiredCartExtraction.toLowerCase(),O=await xe(e.retailerData.confirmationPageTelemetry,e.retailerData.domainName,e.platform,S);o=O?.confirmationDetails||null,o&&(o.personalizationDataConsent=g,o.dynamicTransactionId=T.Q?.DynamicTransactionId);try{if(o&&"primox.de"===(0,w.S8)()){const e="div.payment--content",t=P.Z.GetFirstVisibleElement(e);if(t){const e=t.textContent??"",i=/Transaktionsnummer:(.*?)Gewählte Zahlungsart:/,n=i?.exec(e);if(n){const e=n[1].trim();o.transactionId=e}}}}catch{}let E=d.Z.uuidv4();E&&""!==E||(E=Te());try{if(o&&!o.transactionId){const t=ve(e)??void 0,i=(0,ie.Im)(t),n=(0,ie.RT)(i,(0,w.Ek)());n&&(o.transactionId=n)}}catch(e){}if(o&&(o?.transactionId||o?.purchaseTotal||o?.numberOfItems||o?.productNames)){let d=!0,g="";if(0===e?.retailerData?.domainName.indexOf("amazon")&&(o.transactionId=(0,ie.Tb)("purchaseId",(0,w.Ek)())||""),o?.transactionId&&e?.retailerData?.confirmationPageTelemetry?.isCartCachingEnabled){const e=(0,x.Mw)(o.transactionId);e&&Date.now()-parseInt(e,10)<12096e5?(d=!1,g="do not send data. Expity not reached",(0,x.Xo)(o.transactionId,Date.now().toString())):(0,x.Xo)(o.transactionId,Date.now().toString())}if(C||(d=!1,g="do not send data. PurchaseExtractionService will send data"),d){let d="Confirmation page telemetry";if(e.retailerData.confirmationPageTelemetry.isCartCachingEnabled&&(!o.productNames||!o.purchaseTotal)){const e="no cart data cached";ge(k,"ConfirmationPageValidation",e,h.in.Error),d+=", "+e}if(O?.error&&(d+=", "+O.error),!o.productNames||!o.purchaseTotal||!o.transactionId){const t=`${o.productNames?"":"Empty productNames;"}${o.purchaseTotal?"":"Empty purchaseTotal;"}${o.transactionId?"":"Empty transactionId;"}`;B.Z.GetHtmlFragmentCollectionService().CollectFragmentOnConfirmationPage(e,f||"",t)}const g=T.Q?.CheckoutPageNavigatedTime;I=function(e,t,i,n,o,r,a,s,l){let c=null,d=null,u=null,p=null,g=!1;const f=window?.windowCallPhantom,m=window?._phantom,v=window?.phantom;document?.documentElement?.hasAttribute("__selenium_unwrapped")&&(c=document.documentElement.getAttribute("__selenium_unwrapped")),document?.documentElement?.hasAttribute("__webdriver_evaluate")&&(d=document.documentElement.getAttribute("__webdriver_evaluate")),document?.documentElement?.hasAttribute("__driver_evaluate")&&(u=document.documentElement.getAttribute("__driver_evaluate")),document?.documentElement?.hasAttribute("$cdc_asdjflasutopfhvcZLmcfl_")&&(p=typeof document.documentElement.getAttribute("$cdc_asdjflasutopfhvcZLmcfl_")),g="undefined"!=typeof window&&"object"==typeof window.process&&"renderer"===window.process?.type||!("undefined"==typeof process||"object"!=typeof process.versions||!process.versions.hasOwnProperty("electron"));let C=t.productNames,b=t.transactionId,S=t.orderConfirmationPageUrl;const x=ee.Z.getFactory()?.getPersonalDataRemover();x&&(b=x.maskDataInAString(b),C=x.maskDataInAString(C),S=x.deleteSecretsInURL(S));const T=B.Z.GetLocalDataService(),O=T.GetSessionIds()?.retailerSessionId??"",P=T.GetSessionIds()?.pageVisitId??"",A=function(e){try{if(""===e)return;const[t,i]=e.split(" "),[n,o,r]=t.split("-").map(Number),[a,s,l]=i.split(":").map(Number);return new Date(n,o-1,r,a,s,l)}catch(e){return}}(l??"");let E=!1;const k=A&&function(e,t){try{const i=t.getTime()-e.getTime(),n=Math.floor(i/1e3);return Math.floor(n/60)<=2}catch(e){return!1}}(A,new Date)?t?.dynamicTransactionId:"";try{o?.retailerData?.settings?.transactionIdSettings?.shouldAutoGenerate&&(b=k,E=!0)}catch(e){}z.GetEdgeMessageService().SendStorageMessage(y.Q.CheckoutPageNavigatedTime,JSON.stringify({value:""})),z.GetEdgeMessageService().SendStorageMessage(y.Q.DynamicTransactionId,JSON.stringify({value:""}));const I={Currency:t.currency??"",Domain:(0,w.S8)(),DriverEvaluate:u?JSON.stringify(u):"",EventId:i,IsChromeDriver:p??"",IsElectron:g,NavigatorWebdriver:navigator.webdriver??!1,NumberOfItems:t.numberOfItems??"",OrderConfirmationPageUrl:S??"",OrderConfirmationPageUrlRegex:(0,w.og)(S,o.orderConfirmationPageUrlRegex),OrderDiscountCode:t.orderDiscountCode??"",OrderDiscountPrice:t.orderDiscountPrice??"",OrderShippingPrice:t.orderShippingPrice??"",OrderSubTotalPrice:t.orderSubTotalPrice??"",OrderTaxesPrice:t.orderTaxesPrice??"",Platform:o.platform??"",PricePerItem:t.pricePerItem??"",ProductIdSku:t.productIdSku??"",ProductNames:C??"",ProductSellerNames:t.productSellerNames??"",PurchaseTotal:t.purchaseTotal??"",QuantityPerItem:t.quantityPerItem??"",ProductBrandNames:t.productBrandNames??"",PersonalizationDataConsent:t.personalizationDataConsent,Rguid:n?.rGuid??"",SeleniumUnwrapped:c?JSON.stringify(c):"",TransactionId:b??"",WebdriverEvaluate:d?JSON.stringify(d):"",WindowCallPhantom:f?JSON.stringify(f):"",WindowPhantom:v?JSON.stringify(v):"",Window_Phantom:m?JSON.stringify(m):"",DomainCountry:"",RetailerDataDomain:o.retailerData?.domainName??"",ExactConfirmationPageUrl:o.retailerData?.orderConfirmationPageUrl??"",ESF:r,Anid:a??"",ActiveCashbackOffers:n?JSON.stringify(n):"",IsAADSignedIn:s??null,PageUrlFields:ve(o)??null,PageVisitId:P??"",RetailerSessionId:O??"",DynamicTransactionId:k??"",IsDynamicTransaction:E??null};return ge(I,"ConfirmationPageDetails",e,h.in.Information),I}(d,o,E,t,e,r,n,a,g),await async function(e,t,i,n,o){if(e&&t.transactionId&&""!==t.transactionId&&t.productNames&&""!==t.productNames){const a=t.transactionId,s=n.retailerData.domainName,d=t.currency,u=t.purchaseTotal?Number(t.purchaseTotal.replace(/[^0-9\.]+/g,"")):0,g=t.numberOfItems?Number(t.numberOfItems):0,f=t.productNames,m=t.pricePerItem?.replace(/[^0-9\,]+/g,"")??null;let v="",y="",C="";if(i?.adsCashback&&i?.adsCashback?.length>0?(v=s,y="BingPersonalization"):o&&o.merchantId&&""!==o.merchantId&&o.affiliateNetwork&&""!==o.affiliateNetwork&&(v=o.merchantId,y=o.affiliateNetwork),o&&o.merchantFullName&&""!==o.merchantFullName&&(C=o.merchantFullName),""!==v&&""!==y){const t="https://www.bing.com/api/shopping/v1/savings/cashback/instant";var r;try{r=await function(e,t,i,n,o,r,a,s,d,u,h){return{Anid:e,CashbackAmount:0,Currency:a,Domain:r,MerchantName:i,MerchantId:n,AffiliateName:o,PurchaseTotal:s,NumOfItems:d,ProductNames:u,PricePerItem:h,TransactionDate:(new Date).toISOString(),TransactionId:t,Country:"",ClientContext:new c.Z(b.Z.GetClientName(),p.yJ,b.Z.GetBuildVersion(),b.Z.enabledServiceFlights,l.R.GetServiceExperiments(),void 0,l.R.GetExpRawData())}}(e,a,C,v,y,s,d,u,g,f,m);const i={body:JSON.stringify(r),headers:{"Content-Type":"application/json"},method:"POST"},n=await fetch(t,i);await n.json(),200===n.status&&De()}catch(e){!async function(e,t,i){if(ge({Domain:(0,w.S8)(),PageUrl:(0,w.Ek)(),DebugData:JSON.stringify({error:e})},"ConfirmationPageValidation",`Instant cash back call failed. ${i?"Making call through client using FetchShoppingApi instead":"requestBody not defined"}.`,h.in.Information),i){const e=[t,JSON.stringify(i)];U.R.postMessageToHost("FetchShoppingApi",e),De()}}(e,t,r)}}}}(n,o,t,e,i);const C=new RegExp(e.retailerData.orderConfirmationPageUrl,"i").test((0,w.Ek)());if(!(0,te.XB)()&&(D=o)&&D.transactionId&&D.purchaseTotal&&D.productNames&&i?.userRebateResponse?.isRebatesUser&&C)if(_e(t)){const i=se(se({},k),{},{DebugData:JSON.stringify({Source:"isInSessionClick",PersonalizedCashbackData:t,NotificationLastShownCount:T.Q?.PcbNotificationLastShownAdCount})});z.GetEdgeMessageService().TrySendAutoShowFeaturesAvailableMessage(v.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_CONFIRMATION,m.sM.CASHBACKCONFIRMATION)?ge(i,"ConfirmationPageValidation","ConfirmationPageNotification PP cashback",h.in.Information):pe(i,v.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_CONFIRMATION);const n=T.Q?.PcbNotificationLastShownAdCount??{};n&&(n[e?.retailerData.domainName]=null,z.GetEdgeMessageService().SendStorageMessage(y.Q.PcbNotificationLastShownAdCount,JSON.stringify({value:n})))}else if(function(e,t){const i=e?.adsCashback?.length>0&&""!==e?.adsCashback[0].commissionValue&&""!==e?.adsCashback[0].commissionType,n=T.Q?.PcbNotificationLastShownAdCount;let o={};return(!n||(o=n,"1"!==n[t]))&&(o[t]="1",z.GetEdgeMessageService().SendStorageMessage(y.Q.PcbNotificationLastShownAdCount,JSON.stringify({value:o})),i)}(t,e?.retailerData.domainName)){const e=se(se({},k),{},{DebugData:JSON.stringify({Source:"wasNotificationAlreadyShown",PersonalizedCashbackData:t,NotificationLastShownCount:T.Q?.PcbNotificationLastShownAdCount})});z.GetEdgeMessageService().TrySendAutoShowFeaturesAvailableMessage(v.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_CONFIRMATION,m.sM.CASHBACKCONFIRMATION)?ge(e,"ConfirmationPageValidation","ConfirmationPageNotification PP cashback",h.in.Information):pe(e,v.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_CONFIRMATION)}else ge(se(se({},k),{},{DebugData:JSON.stringify({PersonalizedCashbackData:t,NotificationLastShownCount:T.Q?.PcbNotificationLastShownAdCount})}),"ConfirmationPageValidation","ConfirmationPageNotification already shown",h.in.Information);else(0,te.XB)()||ge(se(se({},k),{},{DebugData:JSON.stringify({UserRebatesResponse:JSON.stringify(i?.userRebateResponse??{}),TransactionId:o?.transactionId,PurchaseTotal:o?.purchaseTotal,ProductNames:o?.productNames,IsConfirmationPage:C})}),"ConfirmationPageValidation","Data not valid for confirmation autoshow",h.in.Information);if(l.R.isExperimentActive(s.H.enrollToRebateBonus)&&C&&o?.purchaseTotal&&parseFloat(o.purchaseTotal.substring(1))>=50&&!i?.userRebateResponse?.isRebatesUser&&u&&(z.GetEdgeMessageService().TrySendAutoShowFeaturesAvailableMessage(v.sR.AUTO_SHOW_MOMENT_IN_TIME,m.sM.ENROLL_TO_CASHBACK_CONFIRMATION_NOTIFICATION)||pe({},v.sR.AUTO_SHOW_MOMENT_IN_TIME)),await ye(E,"ConfirmationPage"),e?.retailerData?.confirmationPageTelemetry?.isCartCachingEnabled){const t=e?.retailerData?.exactConfirmationPageUrl;if(t)try{new RegExp(t,"i").test((0,w.Ek)())&&(ke("Deleting cart data. exactConfirmationPageUrl matched"),(0,x.UZ)(A.OY),Ie(e.retailerData.domainName))}catch(t){ke("Deleting cart data. Error with regex"),(0,x.UZ)(A.OY),Ie(e.retailerData.domainName)}else ke("Deleting cart data. No exactConfirmationPageUrl"),(0,x.UZ)(A.OY),Ie(e.retailerData.domainName)}}else ge(se(se({},k),{},{DebugData:JSON.stringify({ConfirmationPageDetails:o})}),"ConfirmationPageValidation",g,h.in.Error)}else ge(se(se({},k),{},{DebugData:JSON.stringify({ConfirmationPageDetails:o,errorMsg:O?.error||""})}),"ConfirmationPageValidation","Confirmationpagedetails no data extracted",h.in.Error);try{await async function(e){try{if(null==e.retailerData?.allAutomatedSelectors)return void ke("PersonalizedPromotions Error",{message:"no automated selectors"});const t=e.retailerData.allAutomatedSelectors,i=(0,w.Ek)();for(const n of t)if(n?.type===h.u3.PurchaseConfirmed&&new RegExp(n.urlRegex?.toLowerCase()??"").test(i.toLowerCase())){if(null===n.details||0===Object.keys(n.details).length)continue;return void be(n,e.retailerData.domainName)}ke("PersonalizedPromotions Error",{message:"no PurchaseConfirmed selectors found"})}catch(e){ke("PersonalizedPromotions Error",{message:"catch error",error:e})}}(e),(0,x.UZ)(_.Vj),function(e){try{const t=T.Q?.PersonalizedPromotionsCartData??"",i=(0,w.BQ)(t)??{};i[e]={};const n=JSON.stringify({value:JSON.stringify(i)});z.GetEdgeMessageService().SendStorageMessage(y.Q.PersonalizedPromotionsCartData,n)}catch(e){ge({Domain:(0,w.S8)(),PageUrl:(0,w.Ek)()},"ConfirmationPageValidation",(e?.message??" ")+"error deleting persistent cart data",h.in.Error)}}(e.retailerData.domainName)}catch(e){ge(k,"ConfirmationPageValidation","Error when extracting automated selectors: "+(e?.message??""),h.in.Error)}}}catch(e){ge(k,"ConfirmationPageValidation",(e?.message??" ")+"confirmationpage cart details extraction error.",h.in.Error)}var D}(t,i,n,a,0,g,f,C,S,E,k))}function ve(e){try{const t=e?.retailerData?.allAutomatedSelectors||[],i=(0,w.Ek)();for(const e of t)if(e?.type===h.u3.PurchaseConfirmed&&new RegExp(e.urlRegex).test(i.toLowerCase()))return e?.urlFields}catch(e){}return null}async function ye(e,t){let i="",n="";await(0,C._R)(1e3);const o=document.querySelectorAll('[id^="batBeacon"] > img');if(o)for(const e of o)if(e?.currentSrc){const t=new URL(e.currentSrc),o=t?.searchParams.get("mid"),r=t?.searchParams.get("ti");o&&r&&(i+=o+",",n+=r+",")}i=i.length>0?i.substring(0,i.length-1):"",n=n.length>0?n.substring(0,n.length-1):"",ge({Domain:(0,w.S8)(),EventId:e,ImpressionId:ce,Mid:i,PageType:t,TagId:n},"ConfirmationPageUetEvent","ConfirmationPage UET Event",h.in.Information)}async function Ce(e,t,i,n){if(!e)return null;const r=new Q;let a,s,l,c,d,u=0,p="";r.personalizationDataConsent=n,r.orderConfirmationPageUrl=(0,w.Ek)(),r.domainType=r.domainType;try{let e=B.Z.GetCartExtractionService().GetLastTravelData();if(e)p+="cached:"+JSON.stringify(e??{})+"; ";else{const i=T.Q?.PersistentTravelData,n=((0,w.BQ)(i)??{})[t]??{},o=n?.travelDataStorageInfo??{};p+="persistent:"+JSON.stringify(o)+";",o&&Object.keys(o).length&&(e=o)}if(e){if(u+=e.Price,r.currency=e.Currency,r.domainType=e.DomainType,l="",c="",d="",e.flightLegs)for(const t of e.flightLegs)t.startDate&&(l+=t.startDate+"<SEP>"),t.endDate&&(c+=t.endDate+"<SEP>"),t.name&&(d+=t.name+"<SEP>");else e.StartDate&&(l=e.StartDate),e.EndDate&&(c=e.EndDate),d=e.Name;r.name=d,r.startDate=l,r.endDate=c}}catch(e){p+="error getting travel data from checkout: "+e+";",ge({Domain:(0,w.S8)(),PageUrl:(0,w.Ek)()},"ConfirmationPageValidation",p,h.in.Error)}if(e.bookingIdSelector&&""!==e.bookingIdSelector&&(s=L.Z.GetBoxValue(e.bookingIdSelector),s&&(r.bookingId=s)),e.nameSelector&&""!==e.nameSelector&&(d=L.Z.GetBoxValue(e.nameSelector),d&&(r.name=d)),e.totalPriceSelector&&""!==e.totalPriceSelector&&(a=L.Z.GetBoxValue(e.totalPriceSelector),a)){r.price=a;const e=(0,S.cU)(a,!0);(0,o.TF)(e)||(r.currency=e)}if(r.price&&""!==r.price||(r.price=u.toString()),e.startDateSelector&&""!==e.startDateSelector&&(l=L.Z.GetBoxValue(e.startDateSelector),l&&(r.startDate=l)),e.endDateSelector&&""!==e.endDateSelector&&(c=L.Z.GetBoxValue(e.endDateSelector),c&&(r.endDate=c)),e.isRoundTripSelector&&""!==e.isRoundTripSelector){const t=L.Z.GetBoxValue(e.isRoundTripSelector);t&&(r.isRoundTrip=t)}return r.bookingId&&""!==r.bookingId||(p+="no bookingId; "),r.domainType&&""!==r.domainType||(r.domainType=e.domainType),{travelConfirmationDetails:r,error:p}}async function be(e,t){try{if(!e)return void ke("PersonalizedPromotions Error",{message:"no automated selectors for personalized promotions pipeline found, aborting"});if(e?.type!==h.u3.PurchaseConfirmed)return void ke("PersonalizedPromotions Error",{message:"Not a confirmation page, pageType: "+e?.type});if(null===e.details)return void ke("PersonalizedPromotions Error",{message:"No selectors provided for page url"});const i=new D.Z;if(i.domain=t,i.pageType=e.type,i.pageUrl=(0,w.Ek)(),i.orderId=L.Z.GetBoxValue(e.details.orderId),i.orderTotal=Se(e.details.orderTotalPrice),i.orderSubtotal=L.Z.GetBoxValue(e.details.orderSubTotalPrice),i.productName=await Oe(e.details.productName),i.productItemPrice=await Oe(e.details.productItemPrice),i.productTotalPrice=await Oe(e.details.productTotalPrice),i.productPrice=await Oe(e.details.productPrice),i.productQuantity=await Oe(e.details.productQuantity),i.productId=await Oe(e.details.productId),(0,o.TF)(i.productName)&&"true"===e.details.getProductNamesFromImg&&e.details.productImgSelector){const t=P.Z.RunQuerySelectorAll(e.details.productImgSelector);let n="";for(const e of t){const t=e?.getAttribute("alt");t&&(n+=t+"<SEP>")}i.productNameFromImg=n}i.pageUrlFields=e.urlFields;const n="Successfully extracted Personalized Promotions Purchase Confirmation Information";ge(i,h.R.ShoppingPersonalizedPromotionsRawTable,n,h.in.Information)}catch(e){ke("PersonalizedPromotions Error",{message:"catch error",error:e})}}function Se(e){let t="";if(e&&e.includes(",")){const n=e.split(",").reverse();let o=!1;for(const e of n){const n=L.Z.GetBoxValue(e);if(n&&(i=n,new RegExp("/[0-9]/").test(i))){o=!0,t=n;break}}o||(t=L.Z.GetBoxValue(e))}else t=L.Z.GetBoxValue(e);var i;return t?t.trim():""}async function xe(e,t,i,n=!1){const r=B.Z.GetLocalDataService(),a=r.GetSessionIds()?.retailerSessionId??"",s=r.GetSessionIds()?.pageVisitId??"",l={Domain:(0,w.S8)(),PageUrl:(0,w.Ek)(),PageVisitId:s,RetailerSessionId:a};if(!e)return ge(l,"ConfirmationPageValidation","ConfirmationTelemetry selectors not found",h.in.Information),null;ge(l,"ConfirmationPageValidation","Data extraction started",h.in.Information);const c=new F.Z;let u,p,g,f,m,v,y,b,x;const O=e.orderIdSelectors??"";let E="";c.orderConfirmationPageUrl=(0,w.Ek)(),m="";try{if(e.isCartCachingEnabled){const e=B.Z.GetCartExtractionService();let i=e.GetLastCartData();const o=e.GetFastCart(),r=void 0!==i?.Products?.find((e=>!e.productTitle||""===e.productTitle));if(i||(E+="Cart data from local storage is empty;"),o&&(E+="fastCart:"+JSON.stringify(o??{})+";"),!i||null==i.Products||i.Products?.length<=0||r){const e=T.Q?.PersistentCartData,n=((0,w.BQ)(e)??{})[t]??{},o=n?.cartDataStorageInfo??{};E+="persistent:"+JSON.stringify(o)+"; ";const r=void 0!==o?.Products?.find((e=>!e.productTitle||""===e.productTitle));i=Object.keys(o).length&&!r?o:null}else E+="cached:"+JSON.stringify(i??{})+"; ";const a=Boolean(i&&Date.now()-i.CartDataCreationTime<=A.l$);if(!i||!a&&n)E+=`No cached cart data found; isCardDataPresent: ${!!i}; isNotExpiredCart: ${a}; Time: ${Date.now().toString()};`,ge(l,"ConfirmationPageValidation",E,h.in.Error);else{E+="Using cached cart data; ";const e="<SEP>";let t=0;g="",f="",v="",y="",x="";const n=void 0!==i?.Products?.find((e=>!0===e.buyNowItem));if(i.Products){c.numberOfItems=i.Products?.length.toString();for(const o of i.Products)n&&!0!==o.buyNowItem||(o.productTitle&&(g+=o.productTitle+e),o.productPrice&&(t+=o.productPrice,v+=i.Currency+o.productPrice?.toString()+e),o.productQuantity&&(y+=o.productQuantity?.toString()+e),o.productSeller&&(f+=(o.productSeller?.replace("Sold by:","")||"")+e),x+=(o.productBrand??"")+e)}g=g?g.trim():g,g&&(c.productNames=g),null!==v&&""!==v&&(c.pricePerItem=v),null!==y&&""!==y&&(c.quantityPerItem=y),i&&i.ProductIds&&""!==i.ProductIds&&(c.productIdSku=i.ProductIds),i&&i.ProductUrls&&""!==i.ProductUrls&&(c.productUrls=i.ProductUrls),f&&(c.productSellerNames=f),x&&(c.productBrandNames=x),void 0!==i.Currency&&(null==i.OrderTotal||isNaN(i.OrderTotal)||i.OrderTotal<0?c.purchaseTotal=i.Currency+t.toString():c.purchaseTotal=i.Currency+i.OrderTotal.toString(),c.currency=i.Currency),null!=i.OrderSubTotal&&!isNaN(i.OrderSubTotal)&&i.OrderSubTotal>=0&&(c.orderSubTotalPrice=i.Currency+i.OrderSubTotal.toString())}}else E+="cart caching not enabled;"}catch(e){E+="error during cart extraction from cache: "+e+"; ",ge(l,"ConfirmationPageValidation",E,h.in.Error)}if(e?.productDetailsData?.length&&e?.productDetailsData?.length>0){g="",v="",y="",b="";let i=0;for(const n of e?.productDetailsData){if("microsoft.com"===t){const e="div[class*='lineItemRow']",t="div[class*='bundleItems']";await(0,C.dz)((async()=>void 0!==P.Z.GetFirstVisibleElement(e)),5e3);const o=P.Z.RunQuerySelectorAll(e);if(o&&o.length>0)for(const e of o)if(null==P.Z.GetFirstVisibleElement(t,e)){await(0,C.dz)((async()=>void 0!==P.Z.GetFirstVisibleElement(n?.productIdSelector??"",e)),5e3);let t=P.Z.GetFirstVisibleElement(n?.productPriceSelector??"",e);t&&t.textContent&&(v+=t.textContent?.trim()+"<SEP>"),t=P.Z.GetFirstVisibleElement(n?.productIdSelector??"",e),t&&t.textContent&&(g+=t.textContent?.trim()+"<SEP>",i++),t=P.Z.GetFirstVisibleElement(n?.productQuantitySelector??"",e),t&&t.textContent&&(y+=t.textContent?.trim()+"<SEP>")}i>0&&(m=i.toString())}if("microsoft.com"!==t||""===g){const e="wayfair.com"===t?1e4:5e3;if(n?.productIdSelector&&""!==n?.productIdSelector){let t;await(0,C.dz)((async()=>(t=P.Z.GetFirstVisibleElement(n?.productIdSelector??""),void 0!==t)),e);let o=P.Z.RunQuerySelectorAll(n?.productIdSelector??"");if(o.length>0)for(const e of o)e&&e.textContent&&(g+=e.textContent?.trim()+"<SEP>",i++);else{o=Ae(n?.productIdSelector??"");for(const e of o)e&&e.textContent&&(g+=e.textContent?.trim()+"<SEP>",i++)}}v=await we(n,t),y=await Oe(n?.productQuantitySelector,0),b=await Oe(n?.productIdSkuSelector,0),i>0&&(m=i.toString())}}if(g=g?g.trim():g,g&&(c.productNames=g),null!==v&&""!==v)c.pricePerItem=v;else if("jossandmain.com"===t&&null!==g){E+="no price per item but there are product names;";for(const i of e?.productDetailsData)v=await we(i,t);E+=v+";",c.pricePerItem=v}null!==y&&""!==y&&(c.quantityPerItem=y),null!==b&&""!==b&&(c.productIdSku=b)}const k=await async function(e){try{if(!e)return"";const t=(0,ie.ql)(e,(0,w.Ek)());if(t)return t;const i=await async function(e){const t=(e?.split(",")??[]).filter((e=>!(0,ie.Ae)(e))).join(",");let i=await(0,C.dz)((async()=>P.Z.HasVisibleElement(t)),5e3).then((()=>L.Z.GetBoxValue(t))).catch((e=>L.Z.GetBoxValue(t)));return i=L.Z.GetBoxValue(t),i}(e);return i}catch(t){ke("Error getting transaction id",{message:t.message,transactionIdSelector:e??""})}return""}(e?.transactionIdSelector);if(c.transactionId=k,"replacements.com"===t||"us.puma.com"===t&&!c.transactionId){let e=d.Z.uuidv4();e&&""!==e||(e=Te());const t=Date.now()+"_"+e;c.transactionId=t}try{!O||""===O||c.transactionId&&""!==c.transactionId||(p=await Ee(O),c.transactionId=p)}catch(e){}if(null!==m&&""!==m?c.numberOfItems=m:e?.transactionIdSelector&&""!==e?.transactionIdSelector&&(m=L.Z.GetBoxValue(e?.numItemsSelector??""),null!=m&&""!==m&&(c.numberOfItems=m)),c.orderDiscountCode=Pe(e?.orderDiscountCodeSelector),c.orderDiscountPrice=Pe(e?.orderDiscountPriceSelector),c.orderShippingPrice=Pe(e?.orderShippingPriceSelector),c.orderTaxesPrice=Pe(e?.orderTaxesPriceSelector),c.orderSubTotalPrice=Pe(e?.orderSubTotalPriceSelector),e?.purchaseTotalSelector&&""!==e?.purchaseTotalSelector){if("petsmart.com"===t||"jlobeauty.com"===t||"homedepot.com"===t||"shopify"===i){const t=e?.purchaseTotalSelector;u=await(0,C.dz)((async()=>P.Z.HasVisibleElement(t)),5e3).then((()=>L.Z.GetBoxValue(t))).catch((e=>L.Z.GetBoxValue(t)))}else u=Se(e.purchaseTotalSelector);try{if(u){const e=(0,S.K)(u);!isNaN(e)&&e>0&&(c.purchaseTotal=u);const t=(0,S.cU)(u,!0);(0,o.TF)(t)||(c.currency=t)}else if(c.pricePerItem&&""!==c.pricePerItem){const e=(0,S.cU)(c.pricePerItem,!0);(0,o.TF)(e)||(c.currency=e)}}catch(e){ke("Error extracting currency",{message:"Could not extract currency: "+e})}}if(("wayfair.com"===t||e.isCartCachingEnabled||"jossandmain.com"===t)&&(void 0===c.purchaseTotal||""===c.purchaseTotal))try{const e=T.Q?.CartValues,i=((0,w.BQ)(e)??{})[t]??{},n=i?.cartValue??{};n&&n.OrderTotal&&n.OrderTotal>=0&&(c.purchaseTotal=n.Currency+n.OrderTotal.toString(),c.currency=n.Currency),E+="got purchaseTotal from CartValue "+c.purchaseTotal+"; "}catch(e){E+="error getting purchaseTotal from cart: "+e}if(!("walmart.com"!==t&&0!==t.indexOf("amazon")||null!=c.productNames&&""!==c.productNames)&&e?.productDetailsData){if(g="",e.productDetailsData.length>0){const t=e.productDetailsData[0].productImageSelector;if(null!=t){const e=P.Z.RunQuerySelectorAll(t);for(const t of e){const e=t.getAttribute("alt");g+=e?.trim()+"<SEP>"}}}g=g?g.trim():g,g&&(c.productNames=g,E+="got productNames from productImage: "+g+";")}return ge(l,"ConfirmationPageValidation","Data extraction complete",h.in.Information),{confirmationDetails:c,error:E}}function Te(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(e=>{const t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)}))}async function we(e,t){let i="";if(e?.productPriceSelector&&""!==e?.productPriceSelector){let n,o=[],r=5e3;"wayfair.com"===t&&(r=1e4),await(0,C.dz)((async()=>(n=P.Z.GetFirstVisibleElement(e?.productPriceSelector??""),void 0!==n)),r),o=P.Z.RunQuerySelectorAll(e?.productPriceSelector);for(const e of o)e&&e.textContent&&(i+=e.textContent?.trim()+"<SEP>");if((!o||0===o.length)&&(o=Ae(e?.productPriceSelector??""),o.length>0))for(const e of o)e&&e.textContent&&(i+=e.textContent?.trim()+"<SEP>")}return i}async function Oe(e,t=5e3){let i="";if(e&&""!==e){let n,o=[];await(0,C.dz)((async()=>(n=P.Z.GetFirstVisibleElement(e??""),void 0!==n)),t),o=P.Z.RunQuerySelectorAll(e);for(const e of o)e&&e.textContent&&(i+=e.textContent?.trim()+"<SEP>");if((!o||0===o.length)&&(o=Ae(e??""),o.length>0))for(const e of o)e&&e.textContent&&(i+=e.textContent?.trim()+"<SEP>")}return i}function Pe(e){if(e&&""!==e){const t=L.Z.GetBoxValue(e);if(null!=t&&""!==t)return t}return null}function Ae(e){return e&&""!==e?document.getElementsByClassName(e):[]}async function Ee(e){if(!e)return"";try{return await(0,C.dz)((async()=>P.Z.HasVisibleElement(e)),5e3).then((()=>{const t=e.split(";");for(const e of t){const t=L.Z.GetBoxValue(e);if(null!=t&&""!==t)return t}return""})).catch((e=>""))}catch(e){}return""}function ke(e,t=void 0){ge({Domain:(0,w.S8)(),PageUrl:(0,w.Ek)(),DebugData:t?JSON.stringify(t):""},"ConfirmationPageValidation",e,h.in.Information)}function Ie(e){try{const t=T.Q?.PersistentCartData??"",i=(0,w.BQ)(t)??{};i[e]={};const n=JSON.stringify({value:JSON.stringify(i)});z.GetEdgeMessageService().SendStorageMessage(y.Q.PersistentCartData,n);const o=T.Q?.CartValues??"",r=(0,w.BQ)(o)??{};r[e]={};const a=JSON.stringify({value:JSON.stringify(r)});z.GetEdgeMessageService().SendStorageMessage(y.Q.CartValues,a)}catch(e){ge({Domain:(0,w.S8)(),PageUrl:(0,w.Ek)()},"ConfirmationPageValidation",(e?.message??" ")+"error deleting persistent cart data",h.in.Error)}}function De(){"EligibleUser"===T.Q.BlossomCampaignUserStatus&&(z.GetEdgeMessageService().SendStorageMessage(y.Q.BlossomShouldShowNotification,JSON.stringify({value:"true"})),z.GetEdgeMessageService().SendStorageMessage(y.Q.BlossomShouldShowPostPurchaseUX,JSON.stringify({value:"true"})),z.GetEdgeMessageService().SendStorageMessage(y.Q.BlossomCampaignUserStatus,JSON.stringify({value:"OfferClaimed"})),z.GetEdgeMessageService().SendStorageMessage(y.Q.BlossomCampaignUserStatusTimestamp,JSON.stringify({value:(new Date).getTime().toString()})))}function _e(e){return e&&e.isAdClick&&e.commissionType&&e.commissionValue}function Ne(e){return e&&""!==e?["https://","http://","www."].some((t=>e.startsWith(t)))?e:location.origin+e:""}function Re(e,t,i){try{const n=function(e,t){if(!t||!t.Products?.length)return void ge({Domain:(0,w.S8)(),PageUrl:(0,w.Ek)()},"ConfirmationPageValidation","createPostPurchaseProducts: CartData not found.",h.in.Information);const i=[],n=[];for(const o of t.Products){const r=o.productTitle?o.productTitle:o.foundInWebAssist&&o.webAssistTitle?o.webAssistTitle:"",a=o.productImg?o.productImg:o.foundInWebAssist&&o.webAssistImg?o.webAssistImg:"",s=o.productPrice?o.productPrice:o.foundInWebAssist&&o.webAssistPrice?o.webAssistPrice:0,l=t?.Currency??"",c=Ne(o.productUrl),d=!!r.length&&0!==s&&!!c.length,u={Title:r,ImageUrl:a,Price:s,Currency:l,Muid:e,Url:c,isValid:d};d?i.push(u):n.push(u)}if(n?.length){const e=T.Q?.PostPurchasePathnameProducts,o=[];if(e){for(const t of n)if(t.Title.length)for(const i of e)t.Title===i.productTitle&&(t.ImageUrl=i.productImg,t.Price=i.productPrice,t.Url=Ne(i.productUrl),t.isValid=!!t.Title.length&&0!==t.Price&&!!t.Url.length,t.isValid&&o.push(t));const r={Domain:(0,w.S8)(),PageUrl:(0,w.Ek)(),DebugData:JSON.stringify({cartProducts:t?.Products,validProducts:i,invalidProducts:n,fixedProducts:o,pathnameProducts:e})};i.push(...o);let a="createPostPurchaseProducts: Invalid product(s) were ";o.length===n.length?a+="all fixed":o.length?a+="partially fixed":a+="not fixed",ge(r,"ConfirmationPageValidation",a,h.in.Information),z.GetEdgeMessageService().SendStorageMessage(y.Q.PostPurchasePathnameProducts,JSON.stringify([]))}else ge({Domain:(0,w.S8)(),PageUrl:(0,w.Ek)(),DebugData:JSON.stringify({cartProducts:t?.Products,validProducts:i,invalidProducts:n,fixedProducts:o,pathnameProducts:e})},"ConfirmationPageValidation","createPostPurchaseProducts: Invalid product(s) were found with no pathname products",h.in.Information)}return i}(t,e);if(void 0===n)return;return n&&n.length?{headers:{"Content-Type":"application/json",Source:"ProductTracking",Service:i},method:"POST",body:JSON.stringify({Muid:t,Products:n,TrackingSource:2})}:void ge({Domain:(0,w.S8)(),PageUrl:(0,w.Ek)(),DebugData:JSON.stringify({CartProducts:e?.Products,products:n,service:i})},"ConfirmationPageValidation","createPostPurchaseRequest: No request body",h.in.Error)}catch(e){ge({Domain:(0,w.S8)(),PageUrl:(0,w.Ek)(),DebugData:JSON.stringify({e:e})},"ConfirmationPageValidation","createPostPurchaseRequest: Uncaught error",h.in.Error)}}window.CheckAndIsConfirmationPageValid=function(e,t){(0,w.cz)()||de(e,t)},window.IsConfirmationPageValid=de,window.confirmationPageValidatorRuntime=U.R},69315:function(e,t,i){"use strict";i.d(t,{R:function(){return r}});var n=i(89366);class o extends n.Z{initializeRuntime(e){"complete"===document.readyState?window.IsConfirmationPageValid(e,!1):window.addEventListener&&window.addEventListener("load",(t=>{window.CheckAndIsConfirmationPageValid(e,!1)}))}handleMessages(e,t){if("ConfirmationPageValidation"===t)try{"complete"===document.readyState?window.IsConfirmationPageValid(e,!0):window.addEventListener&&window.addEventListener("load",(t=>{window.CheckAndIsConfirmationPageValid(e,!0)}))}catch(e){}}getNativeHandler(){return confirmationPageValidatorNativeHandler}}const r=new o},9448:function(e,t,i){"use strict";i.d(t,{H:function(){return n}});let n=function(e){return e.CheckoutPageValidationError="CheckoutPageValidationError",e.LogScriptTelemetry="LogScriptTelemetry",e.PageStatus="PageStatus",e.CheckoutPageGMV="CheckoutPageGMV",e.ExpressCheckoutPageGMV="ExpressCheckoutPageGMV",e.CheckoutPageValidationStatus="CheckoutPageValidationStatus",e.PurchaseCompleted="PurchaseCompleted",e.SetStorageValue="SetStorageValue",e.GuestDomain="GuestDomain",e.BackgroundAutoApplyStateValid="BackgroundAutoApplyStateValid",e.PlatformExpansionDomain="PlatformExpansionDomain",e.UpdateAddressBar="UpdateAddressBar",e.RecordShoppingUserEngagement="RecordShoppingUserEngagement",e.RecordShoppingUserAction="RecordShoppingUserAction",e.GetCashBack="GetCashBack",e.NavigateToUrlBackground="NavigateToUrlBackground",e.StartEdgeDriver="StartEdgeDriver",e.UpdateLoadTimeData="UpdateLoadTimeData",e}({})},79249:function(e,t,i){"use strict";var n=i(72370),o=i(23727),r=i(57021);class a extends r.Z{constructor(...e){super(...e),(0,n.Z)(this,"StartTime",void 0),(0,n.Z)(this,"CouponsApplied",void 0),(0,n.Z)(this,"ContextID",void 0),(0,n.Z)(this,"InitialPrice",void 0),(0,n.Z)(this,"TrueInitialPrice",void 0),(0,n.Z)(this,"UnremovedDiscountSum",void 0),(0,n.Z)(this,"BestCoupon",void 0),(0,n.Z)(this,"MaxDiscount",void 0),(0,n.Z)(this,"CouponResults",void 0),(0,n.Z)(this,"ImpressionId",void 0),(0,n.Z)(this,"StringifiedMap",void 0),(0,n.Z)(this,"ImportOptions",void 0),(0,n.Z)(this,"Currency",void 0),(0,n.Z)(this,"PageCurrency",void 0),(0,n.Z)(this,"CashBackActive",void 0),(0,n.Z)(this,"AppliedCoupon",void 0),(0,n.Z)(this,"BackgroundAACancelled",void 0),(0,n.Z)(this,"BackgroundAAStatus",void 0),(0,n.Z)(this,"SuggestedCoupons",void 0),(0,n.Z)(this,"ExtractedInputBox",void 0),(0,n.Z)(this,"ExtractedApplyButton",void 0),(0,n.Z)(this,"ExtractedOrderTotalElement",void 0),(0,n.Z)(this,"CartBlockedCoupons",void 0),(0,n.Z)(this,"HideProgressOverlay",void 0),(0,n.Z)(this,"Metadata",void 0)}static CreateNew(e,t){const i=new a(a.fourMinutesExpiryInSeconds);return i.ContextID=e,i.StartTime=Date.now(),i.CouponsApplied=new Map,i.UnremovedDiscountSum=0,i.MaxDiscount=0,i.CouponResults=[],i.BackgroundAAStatus=new o.Z,t&&(i.ImpressionId=t),i}static CreateFromObject(e){if(e&&null!==e.ContextID&&void 0!==e.ContextID){const t=a.CreateNew(e.ContextID);return e.StringifiedMap&&JSON.parse(e.StringifiedMap).forEach((e=>{const i=e[0],n=e[1];t.CouponsApplied.set(i,n)})),e.BestCoupon&&(t.BestCoupon=e.BestCoupon),null!==e.InitialPrice&&void 0!==e.InitialPrice&&(t.InitialPrice=e.InitialPrice),e.TrueInitialPrice&&(t.TrueInitialPrice=e.TrueInitialPrice),e.UnremovedDiscountSum&&(t.UnremovedDiscountSum=e.UnremovedDiscountSum),null!==e.MaxDiscount&&void 0!==e.MaxDiscount&&(t.MaxDiscount=e.MaxDiscount),e.CouponResults&&(t.CouponResults=e.CouponResults),e.ImpressionId&&(t.ImpressionId=e.ImpressionId),e.ImportOptions&&(t.ImportOptions=e.ImportOptions),e.CashBackActive&&(t.CashBackActive=e.CashBackActive),e.Currency&&(t.Currency=e.Currency),e.PageCurrency&&(t.PageCurrency=e.PageCurrency),e.StartTime&&(t.StartTime=e.StartTime),e.AppliedCoupon&&(t.AppliedCoupon=e.AppliedCoupon),e.BackgroundAACancelled&&(t.BackgroundAACancelled=e.BackgroundAACancelled),e.BackgroundAAStatus&&(t.BackgroundAAStatus=e.BackgroundAAStatus),e.SuggestedCoupons&&(t.SuggestedCoupons=e.SuggestedCoupons),e.ExtractedInputBox&&(t.ExtractedInputBox=e.ExtractedInputBox),e.ExtractedApplyButton&&(t.ExtractedApplyButton=e.ExtractedApplyButton),e.ExtractedOrderTotalElement&&(t.ExtractedOrderTotalElement=e.ExtractedOrderTotalElement),e.CartBlockedCoupons&&(t.CartBlockedCoupons=e.CartBlockedCoupons),e.HideProgressOverlay&&(t.HideProgressOverlay=e.HideProgressOverlay),e.Metadata&&(t.Metadata=e.Metadata),t}return null}StringifyMap(){this.StringifiedMap=JSON.stringify(Array.from(this.CouponsApplied.entries()))}ToString(){return this.StringifyMap(),JSON.stringify(this)}}(0,n.Z)(a,"fourMinutesExpiryInSeconds",480),t.Z=a},8018:function(e,t,i){"use strict";i.d(t,{c:function(){return n}});let n=function(e){return e.Confirmation="confirmation",e.Activated="activated",e.Search="search",e.Category="category",e.CategoryAutoshow="categoryAutoshow",e.PDP="pdp",e.SearchSPB="searchSPB",e.ActivatedOffers="activatedoffers",e.GroceryAutoShow="groceryAutoShow",e.PdpSPB="pdpSPB",e.AddedToCartPDP="AddedToCartPDP",e.SpbHomePage="SpbHomePage",e.CartPageNotification="CartPageNotification",e.SpbCartPageNotification="SpbCartPageNotification",e}({})},44445:function(e,t,i){"use strict";i.d(t,{a:function(){return a}});var n=i(89366),o=function(e){return e.StartAutoApply="StartAutoApply",e.GetZipUrlStatus="GetZipUrlStatus",e.UpdatePaymentDetails="UpdatePaymentDetails",e.WalletMessageFromHost="WalletMessageFromHost",e.BgaaMessageFromHost="BgaaMessageFromHost",e.RewardsPromotionsAvailable="RewardsPromotionsAvailable",e}(o||{});class r extends n.Z{initializeRuntime(e){window.SendSequenceSupportedMessage(),"interactive"===document.readyState||"complete"===document.readyState?window.TryExecuteAutoApply(e,!1):window.addEventListener&&window.addEventListener("DOMContentLoaded",(t=>{window.CheckAndExecuteAutoApply(e,!1)}))}handleMessages(e,t){switch(o[t]){case o.StartAutoApply:try{"interactive"===document.readyState||"complete"===document.readyState?window.TryExecuteAutoApply(e,!0):window.addEventListener&&window.addEventListener("DOMContentLoaded",(t=>{window.CheckAndExecuteAutoApply(e,!0)}))}catch(e){}break;case o.GetZipUrlStatus:window.handleBNPLResult(e[0]);break;case o.UpdatePaymentDetails:window.ExecuteUpdatePaymentDetails(e);break;case o.WalletMessageFromHost:window.HandleWalletMessageFromHost(e[0],e[1]);break;case o.BgaaMessageFromHost:const i=e[0];"RestartBgaa"===i?window.RestartBackgroundAutoApply():"CancelBgaa"===i&&window.CancelBackgroundAutoApply();break;case o.RewardsPromotionsAvailable:window.UpdateRewardsData(e);break;default:throw new Error("Unknown message type: "+t)}}getNativeHandler(){return autoApplyNativeHandler}}const a=new r},23727:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(){(0,n.Z)(this,"BgAutoApplyInProgress",void 0),(0,n.Z)(this,"ForegroundApplyingBestCoupon",void 0),(0,n.Z)(this,"progressBarStartPos",void 0),(0,n.Z)(this,"progressBarEndPos",void 0),(0,n.Z)(this,"currentCoupon",void 0),(0,n.Z)(this,"currentCouponIndex",void 0),(0,n.Z)(this,"couponsTotal",void 0),(0,n.Z)(this,"result",void 0),(0,n.Z)(this,"expiredState",void 0),(0,n.Z)(this,"pageUrl",void 0),(0,n.Z)(this,"domainName",void 0),(0,n.Z)(this,"isBgaaFinished",void 0),(0,n.Z)(this,"hasNotifiedUser",void 0)}}},28219:function(e,t,i){"use strict";var n=i(29247),o=i(90066);class r{static GetCouponStatusMessages(e,t,i){return{statusMessage:r.GetErrorMessage(e)||"",successMessages:t?.map((e=>o.Z.GetTextValue(e)))||[],failureMessages:i?.map((e=>o.Z.GetTextValue(e)))||[]}}static GetErrorMessage(e){if(e&&(0,n.UE)(e)&&o.Z.CountVisibleElements(e)>0)return o.Z.GetTextValue(e)}}t.Z=r},77776:function(e,t,i){"use strict";var n=i(35062),o=i(29247),r=i(36493),a=i(27689),s=i(9448),l=i(82315),c=i(1094),d=i(11849),u=i(52056),h=i(90066);class p{static IsECPage(e){if(e&&e.checkoutData){const t=new n.Z(e.checkoutData);if(p.IsECURLMatch(t,location.pathname)&&t.IsExpressCheckoutEnabled){const e=p.GetECValidationElements(t);return p.IsECElementsExist(e)}}return!1}static IsECElementsExist(e){for(const t of e)if(h.Z.HasVisibleElement(t.Value))return!0;return!1}static GetECValidationElements(e){const t=[],i=e?.AllcheckoutCompletionPages?.get("ShippingAddress");if(i){const e=i.CheckoutElements.get("address1"),n=i.CheckoutElements.get("clickBefore");e&&e.Value&&t.push(e),n&&n.Value&&t.push(n)}const n=e?.AllcheckoutCompletionPages?.get("ContactInfo");if(n){const e=n.CheckoutElements.get("email"),i=n.CheckoutElements.get("clickBefore");e&&e.Value&&t.push(e),i&&i.Value&&t.push(i)}return t}static IsECURLMatch(e,t){let i=!1;return e&&e.CheckoutPageUrl&&e.CheckoutPageUrl.split(",").forEach((e=>{i=i||o.ZP.IsOnPage(e,t)})),i}static GetExpressCheckoutGMVSelector(e){const t=e?.retailerData?.allFinalCheckoutPages??[],i=t?.filter((e=>"none"!==e?.enabledTips&&o.ZP.IsOnPage(e?.checkoutPageUrl,location.pathname)));let r;if(i?.length>0&&(r=i[0]?.orderTotalDataElementSelector),e.checkoutData){const t=new n.Z(e.checkoutData),i=t?.AllcheckoutCompletionPages?.get("OrderInfo");r=i?.CheckoutElements?.get("orderTotal")?.Value??r}return r}static async GetExpressCheckoutGMV(e,t,i){let n={OrderTotal:-1,Currency:"$",PageCurrency:""};if(e&&o.ZP.IsValidDataField(e)){await o.ZP.WaitForCondition((async()=>h.Z.HasVisibleElement(e)),i??5e3);const r=c.Z.CreateCheckoutPageData(t),s=(0,a.uf)(r?.market,r.retailerData?.exclusiveMarket);n=d.Z.GetCartValue(e,s)}return n}static async GetAndSendExpressCheckoutPageGMV(e){const t=l.Z.getApiResponse();try{const i=p.GetExpressCheckoutGMVSelector(e);if(i){const n=await p.GetExpressCheckoutGMV(i,e),{OrderTotal:o,Currency:r}=n;if(o&&o>0)return this.SendExpressCheckoutGMVMessage(o,r,e.traceId),void u.Z.SendLogEvent(t.impressionId,"Complete GetAndSendExpressCheckoutPageGMV","true",o);throw new Error(`Shopping cart value is invalid - ${o}`)}}catch(e){u.Z.SendLogEvent(t.impressionId,`GetAndSendExpressCheckoutPageGMV error. ${e?.message}`,"error")}}static SendExpressCheckoutGMVMessage(e,t,i){const n=(0,r.qm)(t)?t:(0,r.Vv)(t)??"USD";u.Z.SendMessage(s.H.ExpressCheckoutPageGMV,[i,e.toString(),n])}}t.Z=p},41310:function(e,t,i){"use strict";var n=i(72370),o=i(59645),r=i(5144),a=i(75434),s=i(52056);function l(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}t.Z=class{static LogSPBTelemetry(e,t,i,a,c,d={}){const u=new o.Z(e);u.Metadata=JSON.stringify(function(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?l(Object(i),!0).forEach((function(t){(0,n.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):l(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}({userInfo:a,responseData:i},d)),s.Z.SendLogEvent(c,t,"",void 0,void 0,r.R.EdgeFlyoutStatus,u)}static IsSearchPage(e,t){const i={isSerp:!1,searchKey:""};if(t&&t.SearchData){const n=this.IsUrlMatchAll(e,t.SearchData);i.isSerp=n.isMatch,i.searchKey=n.matchKey}return i}static IsUrlMatchAll(e,t){for(const i of t){const t=this.IsUrlMatch(e,i);if(t.isMatch)return t}return{isMatch:!1,matchKey:""}}static GetSPBCashbackOffersPdp(e){const t=e?.offer?e.offer:void 0,i=e?.relatedOffers;return{exactMatch:t,relatedOffers:i||[],visibilityFeedbackUrl:e?.adsMetadata?.visibilityFeedbackUrl||""}}static GetTotalCashback(e){const t=e?.map((e=>{const t=Number(e?.offerValue);return isNaN(t)?0:t})).reduce(((e,t)=>e+t),0);return t||0}static GetTotalCashbackFromOffers(e){const t=e?.map((e=>{const t=Number(e?.value);return isNaN(t)?0:t})).reduce(((e,t)=>e+t),0);return t||0}static IsVariationString(e,t,i){const n=e.GetData("variations"),o=(n?(0,a.rm)(n):{})[t];return!(!o||o!==i)}static IsUrlMatch(e,t){let i={isMatch:!1,matchKey:""};return"PathAndParameter"===t.type?i=this.UrlPathParameterMatch(e,t.path,t.parameter):"PathRegexAndParameter"===t.type?i=this.UrlPathRegexParameterMatch(e,t.path,t.parameter):"QueryParam"===t.type?i=this.UrlQueryParameterMatch(e,t.parameter):"PathRegex"===t.type?i=this.UrlPathRegextMatch(e,t.regexData):"ParamRegex"===t.type&&(i=this.UrlParamRegex(e,t.parameter,t.regexData)),i}static UrlParamRegex(e,t,i){let n="",o=!1;const r=e.searchParams.get(t);if(i&&r){const e=r.match(i.regex),t=i.indices;for(const i of t)if(e&&e.length>i&&e[i]){n=e[i],o=!0;break}}return{isMatch:o,matchKey:n}}static UrlPathParameterMatch(e,t,i){let n="";const o=e.searchParams.get(i),r=e.pathname.toLowerCase(),a=(r===(t=t.toLowerCase())||r===t+"/"||r.endsWith(t)||r.endsWith(t+"/"))&&null!=o;return a&&null!=o&&(n=o),{isMatch:a,matchKey:n}}static UrlPathRegexParameterMatch(e,t,i){let n="";const o=e.searchParams.get(i),r=new RegExp(t).test(e.pathname)&&null!=o;return r&&null!=o&&(n=o),{isMatch:r,matchKey:n}}static UrlQueryParameterMatch(e,t){let i="";const n=e.searchParams.get(t),o=null!=n;return o&&null!=n&&(i=n),{isMatch:o,matchKey:i}}static UrlPathRegextMatch(e,t){let i="",n=!1;if(t){const o=e.pathname.match(t.regex),r=t.indices;for(const e of r)if(o&&o.length>e&&o[e]){i=o[e],n=!0;break}}return{isMatch:n,matchKey:i}}}},90066:function(e,t,i){"use strict";var n=i(29247);class o{static HasVisibleElement(e){return o.CountVisibleElements(e)>0}static CountVisibleElements(e){if(!n.ZP.IsValidDataField(e))return 0;const t=e.split(";");for(const e of t){const t=o.CountVisibleElementsSingleSel(e);if(t>0)return t}return 0}static RunQuerySelectorAll(e,t){if(!n.ZP.IsValidDataField(e))return[];const i=(e=e.replace(/;/g,",")).split("<");let o;o=t?t.querySelectorAll(i[0]):document.querySelectorAll(i[0]);for(const e of i.slice(1)){const t=o[0]?.shadowRoot;if(!t)return[];o=t.querySelectorAll(e)}return o}static IsElementVisible(e){return e&&e.offsetWidth>0&&e.offsetHeight>0}static GetFirstVisibleElement(e,t){if(!n.ZP.IsValidDataField(e))return;const i=e.split(";");for(const e of i)try{const i=o.RunQuerySelectorAll(e,t);for(const e of i)if(o.IsElementVisible(e))return e}catch(e){}}static GetAllVisibleElements(e){if(!n.ZP.IsValidDataField(e))return[];const t=e.split(";"),i=[];for(const e of t){const t=o.RunQuerySelectorAll(e);for(const e of t)o.IsElementVisible(e)&&i.push(e)}return i}static GetTextValue(e,t){if(!e||!n.ZP.IsValidDataField(e))return"";const i=e.split(";"),r=i[0],a=o.GetFirstVisibleElement(r,t);if(!a)return"";let s=a,l=s.innerText;if(1===i.length)s=o.NormalizeIfSuperscripted(a),l=s.innerText;else{const e=s.cloneNode(!0);let n=i[1];const a=o.GetFirstVisibleElement(n,s)??o.GetFirstVisibleElement(n,t);let c="";if(a&&a.innerText){if(c="."+a.innerText,s.contains(a)){const t=o.GetFirstMatchingElement(n,e);if(t?.innerText)e.removeChild(t);else{n.startsWith(r)&&(n=n.slice(r.length));const t=this.GetFirstMatchingElement(n,e);t?.innerText&&e.removeChild(t)}l=e?.innerText?e.innerText:l}l+=c}if(i.length>2){for(const t of i.slice(2)){const i=this.GetFirstMatchingElement(t,e);i?.innerText&&e.removeChild(i)}l=e?.innerText?e.innerText:l}l+=c}return o.StripInvalidJSONCharacters(l)}static GetItemizedData(e,t,i){let n="";if(e&&""!==e){const r=o.RunQuerySelectorAll(e,i);for(const e of r)e&&e.textContent&&(n+=e.textContent?.trim()+t)}return n}static StripInvalidJSONCharacters(e){return e.replace(/\n/gi,"")}static NormalizeIfSuperscripted(e){if(e&&e.innerHTML&&e.innerHTML.toLowerCase().indexOf("</sup>")>-1)try{const t=e.cloneNode(!0),i=t.childNodes.length;for(let e=0;e<i;e++){const i=t.childNodes[e];if("SUP"===i.tagName){let e=i.innerText;const n=/[0-9\.]+/g.exec(e);if(null!==n)return e="."+n[0],i.innerText=e,t}}}catch(t){return e}return e}static GetFirstMatchingElement(e,t){if(!n.ZP.IsValidDataField(e))return;const i=e.split(";");for(const e of i){const i=o.RunQuerySelectorAll(e,t);for(const e of i)if(e)return e}}static GetAllMatchingElements(e){if(!n.ZP.IsValidDataField(e))return[];const t=e.split(";"),i=[];for(const e of t)try{const t=o.RunQuerySelectorAll(e);for(const e of t)e&&i.push(e)}catch(e){}return i}static CountVisibleElementsSingleSel(e){if(!n.ZP.IsValidDataField(e))return 0;const t=o.RunQuerySelectorAll(e);let i=0;for(const e of t)o.IsElementVisible(e)&&i++;return i}}t.Z=o},41290:function(e,t,i){"use strict";i.d(t,{Z:function(){return m}});var n=i(72370),o=i(36818),r=i(80090),a=i(58474);class s extends a.Z{constructor(e,t,i,o){super(),(0,n.Z)(this,"Domain",void 0),(0,n.Z)(this,"PreClippingVisibleSelectors",void 0),(0,n.Z)(this,"PostClippingVisibleSelectors",void 0),(0,n.Z)(this,"WasClippingSuccessful",void 0),this.Domain=e,this.PreClippingVisibleSelectors=t,this.PostClippingVisibleSelectors=i,this.WasClippingSuccessful=o}}var l=s,c=i(54774),d=i(5144),u=i(56019),h=i(29247),p=i(50616),g=i(36493),f=i(90066),m=class{constructor(e,t){(0,n.Z)(this,"logService",void 0),(0,n.Z)(this,"scenario",void 0),this.logService=e,this.scenario=t}async TryClipCoupons(e,t,i,n){const o=Date.now();return e.clipCouponSelector?await this.ClipCouponsAndLogResult(o,e,t,i,n).catch((e=>(this.LogError(o,e.message,t,i,n),!1))):(this.LogError(o,"ClipCoupon selector not found",t,i,n),!1)}async ClipCouponsAndLogResult(e,t,i,n,o){const r=this.GetPriceData(t,n);if(!await h.ZP.WaitForCondition((async()=>f.Z.HasVisibleElement(t.clipCouponSelector)),3e3)&&t.clickBeforeClipSelector){const n=f.Z.GetAllMatchingElements(t.clickBeforeClipSelector);for(const e of n)e.click();await h.ZP.WaitForCondition((async()=>f.Z.HasVisibleElement(t.clipCouponSelector)),3e3).then((async t=>{if(!t){const t="Clicked before element but never found Clip Button";return this.LogError(e,t,i,r,o),!1}}))}const a=f.Z.GetAllMatchingElements(t.clipCouponSelector),s=this.GetFirstVisibleIndices(t);if(0===a.length){let n="Clip button not found, no AlreadyClipped selector";return t.alreadyClippedSelector&&(n=f.Z.GetFirstVisibleElement(t.alreadyClippedSelector)?"Coupon Already Clipped":"Clip Button and Already Clipped not found"),this.LogError(e,n,i,r,o),this.LogVisibleSelectors(i,s,[],!1,o),!1}let l=!1;for(const e of a)e.click(),l=!0;return this.GetPostClippingSelectorsAndLog(i,t,s,l,o),l?this.LogClippingResult(e,d.ps.Positive,i,r,"Finished Clipping Coupon",o):this.LogError(e,"Coupon Clipping Failed",i,r,o),l}GetPriceData(e,t){let i=t.initialPrice??0,n=t.discount;try{if(!i&&e.orderTotalDataElementSelector){const t=f.Z.GetFirstVisibleElement(e.orderTotalDataElementSelector)?.innerText;t&&(i=(0,g.K)(t))}if(!n&&e.discountSelector){const t=f.Z.GetFirstVisibleElement(e.discountSelector)?.innerText;n=p.Z.getAmazonClippingDiscount(i,t)}}catch(e){}return{discount:n,initialPrice:i}}async GetPostClippingSelectorsAndLog(e,t,i,n,o){await h.ZP.Sleep(1e3);const r=this.GetFirstVisibleIndices(t);this.LogVisibleSelectors(e,i,r,n,o)}GetFirstVisibleIndices(e){return[this.GetFirstVisibleElementIndex(e.clipCouponSelector),this.GetFirstVisibleElementIndex(e.discountSelector),this.GetFirstVisibleElementIndex(e.orderTotalDataElementSelector),this.GetFirstVisibleElementIndex(e.clippedDiscountSelector),this.GetFirstVisibleElementIndex(e.alreadyClippedSelector)]}GetFirstVisibleElementIndex(e){if(!e)return-2;const t=e.split(";");for(let e=0;e<t.length;e++){const i=t[e];try{const t=document.querySelectorAll(i);for(const i of t)if(f.Z.IsElementVisible(i))return e}catch(e){}}return-1}LogVisibleSelectors(e,t,i,n,o){const r=d.R.VisibleClippingSelectors,a=d.in.Information,s=new l(e,t,i,n);this.logService.SendLogMessage(a,r,"",s,o)}LogClippingResult(e,t,i,n,r,a){const s=n.initialPrice??0,l=n.discount??0,u=Date.now()-e,h=new o.Z(i),p="Amazon Coupon";h.SetResultData(t,u,p,[],l??0,s,!1,this.scenario);const g=d.R.AutoApply,f=d.in.Information;if(this.logService.SendLogMessage(f,g,r,h,a),t===d.ps.Positive){this.logService.SendEdgeAAPositiveResult(p,s,l);try{const e=new c.Z({});e.EventInfoTime=(new Date).toISOString(),e.Domain=i,e.BestCoupon=p,e.StartingPrice=s.toString(),e.Discount=l.toString(),e.AutoApplyScenario=this.scenario,e.AutoApplyProcessTime=u.toString(),this.logService.SaveSavingsTransactionToEdge(e)}catch(e){}}else this.logService.SendEdgeAANegativeResult()}LogError(e,t,i,n,o){const a=u.x.CouponClippingFailed,s=new r.Z(i,a,{FunctionName:"ClipCoupons"},void 0);this.logService.SendLogMessage(d.in.Error,d.R.ClientError,t??"",s,o),this.logService.SendEdgeAAErrorMessage(a),this.LogClippingResult(e,d.ps.Error,i,n,t,o)}}},23825:function(e,t,i){"use strict";var n=i(72370),o=i(5144),r=i(57176),a=i(82315),s=i(29247),l=i(12953),c=i(4872),d=i(90066),u=i(36493),h=i(27689),p=i(52056),g=i(31656),f=i(64865),m=i(91495);t.Z=class{constructor(e,t=!1){(0,n.Z)(this,"EXPIRY_PERIOD",432e6),(0,n.Z)(this,"PAGE_WAIT_TIME",5e3),(0,n.Z)(this,"MAX_SUGGESTED_COUPONS_COUNT_FOR_AA",3),(0,n.Z)(this,"MAX_SUGGESTED_COUPONS_COUNT_TO_STORE",10),(0,n.Z)(this,"domainName",void 0),(0,n.Z)(this,"key",void 0),(0,n.Z)(this,"AllSuggestedCoupons",void 0),(0,n.Z)(this,"suggestedCoupons",void 0),(0,n.Z)(this,"fromPlatformDetection",void 0),(0,n.Z)(this,"suggestedCouponEnhancementExp",void 0),(0,n.Z)(this,"sendStorageMessage",void 0),(0,n.Z)(this,"invalidCouponList",["NOT_ELIGIBLE_CARD","INVALID_CARD","AMAZON_PAYMENT_V2","ERROR"]),this.sendStorageMessage=e,this.fromPlatformDetection=t,this.domainName=a.Z.getApiResponse().retailerData?.domainName??(0,h.S8)(),this.key="SuggestedCoupons",this.AllSuggestedCoupons=(0,h.BQ)(m.Q.rawStorageObj[this.key])??new Map,this.suggestedCoupons=this.AllSuggestedCoupons[this.domainName]??[]}GetSuggestedCoupons(){return this.suggestedCoupons.slice(0,this.MAX_SUGGESTED_COUPONS_COUNT_FOR_AA)}PostValidation(){return Promise.resolve()}Init(){return this.suggestedCouponEnhancementExp=g.R.isExperimentActive(c.H.suggestedCouponEnhancement)??!1,Object.keys(this.AllSuggestedCoupons).forEach((e=>{this.AllSuggestedCoupons[e]=this.AllSuggestedCoupons[e].filter((e=>e.timestamp+this.EXPIRY_PERIOD>Date.now())),0===this.AllSuggestedCoupons[e].length&&delete this.AllSuggestedCoupons[e]})),Promise.resolve()}async Update(e,t,i,n,o,a,l){let u=this.PAGE_WAIT_TIME;a&&(u=0,i&&await s.ZP.WaitForCondition((async()=>d.Z.HasVisibleElement(i)),this.PAGE_WAIT_TIME)),await s.ZP.Sleep(u).then((()=>{if(i){const a=d.Z.GetFirstVisibleElement(i);let s;if(void 0===n||(0,f.TF)(n))s=a?.textContent;else{const e=a?.textContent?.match(n);s=e&&e[1]?e[1]:""}(0,f.TF)(s)||this.AddCoupons([s],t,e,r.x6.Selector,o)}let a=[];if(this.suggestedCouponEnhancementExp){const e=document.body.cloneNode(!0);let t="";e.querySelectorAll("script").forEach((e=>{t+=e.innerHTML,e.remove()})),a=[...this.GetSuggestedCouponsFromStr(e.innerHTML,this.GetHTMLRegex()),...this.GetSuggestedCouponsFromStr(t,this.GetScriptRegex())],a=[...new Set(a)]}else a=[...new Set([...document.body.innerHTML.matchAll(/[^\w](?<!area\s?|zip\s?|postal\s?|no\s)(?:(?:coupon)?code|promotion)"?(?::|\s|<\w+>|>)+"?(\w+)/gi)].map((e=>e[1])).filter((e=>e.length>3&&e.length<20&&(/\d/.test(e)||e===e.toUpperCase()))))];this.AddCoupons(a,t,e,r.x6.Automated,o),g.R.isExperimentActive(c.H.suppressedCoupons)&&this.RemoveSuppressedCoupons(l,o),this.RemoveInvalidCoupons(),this.suggestedCoupons&&this.suggestedCoupons.length>0&&(this.suggestedCoupons.sort(((e,t)=>t.timestamp-e.timestamp)),this.suggestedCouponEnhancementExp?this.suggestedCoupons=this.suggestedCoupons.slice(0,this.MAX_SUGGESTED_COUPONS_COUNT_TO_STORE):this.suggestedCoupons=this.suggestedCoupons.slice(0,this.MAX_SUGGESTED_COUPONS_COUNT_FOR_AA),this.suggestedCoupons.sort(((e,t)=>this.GetScore(e)-this.GetScore(t))),this.AllSuggestedCoupons[this.domainName]=this.suggestedCoupons),this.sendStorageMessage(this.key,JSON.stringify({value:JSON.stringify(this.AllSuggestedCoupons)}))})).catch((e=>{}))}GetUpdatedAllSuggestedCouponsHistory(e){return e.forEach((e=>{if("NotApplicable"===e.Applicability){const t=e.Code;this.UpdateSuggestedCouponFails(t)}})),this.AllSuggestedCoupons[this.domainName]=this.suggestedCoupons,Object.keys(this.AllSuggestedCoupons).forEach((e=>{this.AllSuggestedCoupons[e]=this.AllSuggestedCoupons[e].sort(((e,t)=>t.timestamp-e.timestamp)),this.AllSuggestedCoupons[e]=this.AllSuggestedCoupons[e].slice(0,this.MAX_SUGGESTED_COUPONS_COUNT_TO_STORE),this.AllSuggestedCoupons[e]=this.AllSuggestedCoupons[e].filter((e=>e.timestamp+this.EXPIRY_PERIOD>Date.now())),0===this.AllSuggestedCoupons[e].length&&delete this.AllSuggestedCoupons[e]})),this.AllSuggestedCoupons}IsSuggestedCouponsEnhancementExpEnabled(){return this.suggestedCouponEnhancementExp}UpdateSuggestedCouponFails(e){const t=this.suggestedCoupons.findIndex((t=>t.couponCode.toLocaleLowerCase()===e.toLocaleLowerCase()));-1!==t&&this.suggestedCoupons[t].numberOfFails++}AddCoupons(e,t,i,n,a){e&&e.length>0&&e.forEach((e=>{const s=this.FindCoupon(t,e),c=this.FindCoupon(this.suggestedCoupons,e);if(c)c.timestamp=Date.now(),c.extraction=Math.min(c.extraction,n),void 0===c.numberOfFails&&(c.numberOfFails=0),i<c.source&&(c.source=i,c.title=`Coupon suggested by ${this.domainName}`);else{const t=new r.ZP;if(t.attribution=this.domainName,t.title=`Coupon suggested by ${this.domainName}`,t.couponCode=e,t.extraction=n,t.numberOfFails=0,t.providerId="SuggestedCoupon",t.source=i,t.timestamp=Date.now(),this.suggestedCoupons.push(t),!s){const i=new l.Z(e,this.domainName,o.M_.SuggestedCoupon,location.pathname,JSON.stringify(t)),n=this.fromPlatformDetection?"Site suggested a coupon we didn't have from platform detection":"Site suggested a coupon we didn't have";p.Z.SendLogEventMessage(i,o.R.CollectedCoupons,a??"",n,o.in.Information)}}}))}FindCoupon(e,t){return e.find((e=>e.couponCode.toLocaleLowerCase()===t.toLocaleLowerCase()))}RemoveInvalidCoupons(){this.suggestedCoupons&&this.suggestedCoupons.length>0&&(this.suggestedCoupons=this.suggestedCoupons.filter((e=>!this.invalidCouponList.find((t=>!(0,f.TF)(e.couponCode)&&t.toLocaleLowerCase()===e.couponCode.toLocaleLowerCase())))),this.AllSuggestedCoupons[this.domainName]=this.suggestedCoupons)}RemoveSuppressedCoupons(e,t){if(e)try{const i=[];if(e.forEach((e=>{const t=this.suggestedCoupons.findIndex((t=>t.couponCode.toLowerCase()===e.toLowerCase()));-1!==t&&(i.push(this.suggestedCoupons[t]),this.suggestedCoupons.splice(t,1))})),0===i.length)return;const n=new l.Z("",this.domainName,o.M_.SuppressedSuggestedCoupons,location.pathname,JSON.stringify(i)),r="Site suggested some coupons which are suppressed coupons";p.Z.SendLogEventMessage(n,o.R.CollectedCoupons,t??"",r,o.in.Information)}catch(e){}}GetScore(e){return this.suggestedCouponEnhancementExp?10*e.extraction+5*e.numberOfFails+e.source:10*e.extraction+e.source}GetSuggestedCouponsFromStr(e,t){return[...e.matchAll(t)].map((e=>e[1])).filter((e=>(e.length>3||3===e.length&&!(0,u.$g)(e))&&(/\d/.test(e)||e===e.toUpperCase())))}GetScriptRegex(){return/[^\w](?<!no\s|product\s)(?:(?:couponcode|aktionscode)"?|code|promotion)(?::|-|\s|<[^>]+>|>)+"?(\w+)/gi}GetHTMLRegex(){return/[^\w](?<!no\s|product\s)(?:(?:coupon|aktions)?code|promotion)"?(?::|-|\s|<[^>]+>|>)+"?(\w+)/gi}}},43916:function(e,t,i){"use strict";i.d(t,{Z:function(){return S}});var n=i(4872),o=i(31656),r=i(73557),a=i(82315),s=i(72370),l=class{constructor(e){(0,s.Z)(this,"userPersonalizationInfo",void 0),e.userPersonalizationInfo&&(this.userPersonalizationInfo=e.userPersonalizationInfo)}},c=class extends l{constructor(e){if(super(e),(0,s.Z)(this,"coupons",void 0),this.coupons=[],e.coupons)for(const t of e.coupons)this.coupons.push(t)}},d=class extends l{constructor(e){if(super(e),(0,s.Z)(this,"competingPrices",void 0),(0,s.Z)(this,"price",void 0),this.competingPrices=[],e?.comparableOffers?.apiPriceData?.value?.length>0)for(const t of e.comparableOffers.apiPriceData.value)this.competingPrices.push(t);e?.price&&(this.price=e.price)}},u=class extends l{constructor(e){super(e),(0,s.Z)(this,"priceDrop",void 0),e?.priceHistory?.priceHistoryData?.dailyPriceDropPercentage&&(this.priceDrop=e.priceHistory.priceHistoryData.dailyPriceDropPercentage/100)}},h=i(17675),p=i(31714),g=i(13018),f=i(29247),m=class{constructor(e,t,i,n,o,r,a){if((0,s.Z)(this,"popupOrigination",void 0),(0,s.Z)(this,"ruleBasedTriggerMap",new Map),(0,s.Z)(this,"isSpiritedShopper",void 0),(0,s.Z)(this,"mlPopUpProbability",void 0),(0,s.Z)(this,"personalizationAutoOpenTelemetryData",void 0),(0,s.Z)(this,"sendErrorMessage",void 0),(0,s.Z)(this,"sendStorageMessage",void 0),(0,s.Z)(this,"variant",void 0),(0,s.Z)(this,"impressionId",void 0),this.popupOrigination=e,this.sendErrorMessage=t,this.sendStorageMessage=i,this.impressionId=n,this.variant=a,this.personalizationAutoOpenTelemetryData=new class{constructor(){(0,s.Z)(this,"mlCouponAutoApplyPopUpProbability",void 0),(0,s.Z)(this,"mlCashbackProbability",void 0),(0,s.Z)(this,"mlPhProbability",void 0),(0,s.Z)(this,"scoreThreshold",void 0),(0,s.Z)(this,"normalizedScore",void 0),(0,s.Z)(this,"positiveEngagementScore",void 0),(0,s.Z)(this,"totalEngagementsCount",void 0),(0,s.Z)(this,"couponExpectation",void 0),(0,s.Z)(this,"priceDrop",void 0),(0,s.Z)(this,"bestCompetingPrice",void 0),(0,s.Z)(this,"isSpiritedShopper",void 0),(0,s.Z)(this,"noPreviousEngagements",void 0),(0,s.Z)(this,"isMLUsed",void 0),(0,s.Z)(this,"noPreviousUserDataAutoOpenRate",void 0),(0,s.Z)(this,"noPreviousUserDataAlwaysOpenCouponExpectation",void 0),(0,s.Z)(this,"minEngagementCount",void 0),(0,s.Z)(this,"message",void 0)}},this.personalizationAutoOpenTelemetryData.minEngagementCount=h.l.minEngagementCount,this.personalizationAutoOpenTelemetryData.noPreviousUserDataAutoOpenRate=h.l.noPreviousUserDataAutoOpenRate,this.personalizationAutoOpenTelemetryData.noPreviousUserDataAlwaysOpenCouponExpectation=h.l.noPreviousUserDataAlwaysOpenCouponExpectation,this.personalizationAutoOpenTelemetryData.message="",r)try{this.ruleBasedTriggerMap=JSON.parse(JSON.parse(r),f.ZP.ParseMap)}catch(e){this.sendErrorMessage(this.impressionId,`Cannot parse Rule Based Trigger Map: ${e}. ruleBasedTriggerMapStr = ${r}`)}this.isSpiritedShopper=o?.userPersonalizationInfo?.isSpiritedShopper,this.personalizationAutoOpenTelemetryData.isSpiritedShopper=this.isSpiritedShopper?1:0}canAutoOpen(){try{let e=this.canAutoOpenWithPersonalization();if(!e&&this.shouldReintroduceFlyout()){this.personalizationAutoOpenTelemetryData.message+=" - ReintroduceFlyout";let t=this.ruleBasedTriggerMap?.get(this.popupOrigination.toString());t||(t=new g.Z),t.flyoutReintroduceIsForced=!0,this.ruleBasedTriggerMap.set(this.popupOrigination.toString(),t);const i=JSON.stringify({value:JSON.stringify(JSON.stringify(this.ruleBasedTriggerMap,f.ZP.StringifyMap))});this.sendStorageMessage(h.l.ruleBasedTriggerDataKey,i),e=!0}return this.storeFirstTimeAutoOpenDisabled(e),e}catch(e){return this.sendErrorMessage(this.impressionId,`Couldn't check auto open ${e}`),!0}}getPersonalizationAutoOpenTelemetryData(){return this.personalizationAutoOpenTelemetryData}noPreviousEngagements(e){const t=e?.positiveEngagementScore??-1,i=e?.totalEngagementsCount??0,n=void 0!==this.variant?h.l.minEngagementCountV1:h.l.minEngagementCount;return-1===t||i<n}canAutoOpenBasedOnFeatures(e){const t=this.getNormalizedScore(e);return t>h.l.scoreThreshold||this.canAutoOpenWithRate(t)}shouldUseML(){return void 0!==this.mlPopUpProbability&&(this.mlPopUpProbability>h.l.mlSecondHighConfidenceRange||this.mlPopUpProbability<h.l.mlFirstHighConfidenceRange)}getRuleBasedTriggerFeaturesWithML(){return[{feature:this.mlPopUpProbability,name:"MLOutput",weight:h.l.mlWeight}]}canAutoOpenUsingRuleBased(e,t){return this.canAutoOpenBasedOnFeatures([{feature:t,name:"positiveEngagementScore",weight:h.l.positiveEngagementWeight}])}canAutoOpenWithRate(e){const t=Math.random(),i=`Random: ${t} Open probability: ${e}`;return this.personalizationAutoOpenTelemetryData.message+=` - ${i}`,t<e}getNormalizedScore(e){let t=0,i=0;const n=[];e.forEach((e=>{void 0!==e.feature&&(t+=e.feature*e.weight,i+=e.weight,n.push(`${e.name}(${e.feature}) * ${e.weight}`))}));const o=t/i,r=`score = ${n.join(" + ")} = ${t} => normalizedScore: ${o} [scoreThreshold: ${h.l.scoreThreshold}]`;return this.personalizationAutoOpenTelemetryData.message+=` - ${r}`,this.personalizationAutoOpenTelemetryData.normalizedScore=o,this.personalizationAutoOpenTelemetryData.scoreThreshold=h.l.scoreThreshold,o}canAutoOpenWithPersonalization(){const e=this.ruleBasedTriggerMap?.get(this.popupOrigination.toString())?.userEngagementResults,t=e?.positiveEngagementScore,i=this.noPreviousEngagements(e);if(this.personalizationAutoOpenTelemetryData.noPreviousEngagements=i,this.personalizationAutoOpenTelemetryData.positiveEngagementScore=t??null,this.personalizationAutoOpenTelemetryData.totalEngagementsCount=e?.totalEngagementsCount??0,this.personalizationAutoOpenTelemetryData.message+=`PopupOrigination: ${this.popupOrigination} - No previous client-side engagements: ${i}`,this.variant===p.nV.ML){const e=this.shouldUseML();if(this.personalizationAutoOpenTelemetryData.isMLUsed=e,this.personalizationAutoOpenTelemetryData.message+=` - shouldUseML: ${e}`,e)return this.canAutoOpenBasedOnFeatures(this.getRuleBasedTriggerFeaturesWithML())}return this.variant!==p.nV.RuleBased||this.canAutoOpenUsingRuleBased(i,t)}storeFirstTimeAutoOpenDisabled(e){let t=this.ruleBasedTriggerMap?.get(this.popupOrigination.toString()),i=t?.firstTimeAutoOpenDisabled;e&&(i=void 0),e||void 0!==i||(i=new Date),t||(t=new g.Z),t.firstTimeAutoOpenDisabled=i,this.ruleBasedTriggerMap.set(this.popupOrigination.toString(),t);const n=JSON.stringify({value:JSON.stringify(JSON.stringify(this.ruleBasedTriggerMap,f.ZP.StringifyMap))});this.sendStorageMessage(h.l.ruleBasedTriggerDataKey,n)}shouldReintroduceFlyout(){const e=this.ruleBasedTriggerMap?.get(this.popupOrigination.toString()),t=e?.firstTimeAutoOpenDisabled,i=e?.flyoutReintroduceDays??h.l.flyoutReintroduceDays;if(t){return((new Date).getTime()-new Date(t).getTime())/864e5>=i}return!1}},v=class extends m{constructor(e,t,i,n,o,r,a){super(e,t,i,n,o,r,a),(0,s.Z)(this,"couponExpectation",void 0),this.mlPopUpProbability=o?.userPersonalizationInfo?.mlCouponAutoApplyPopUpProbability,this.personalizationAutoOpenTelemetryData.mlCouponAutoApplyPopUpProbability=this.mlPopUpProbability??null,this.couponExpectation=this.calculateCouponExpectation(o.coupons??[]),this.personalizationAutoOpenTelemetryData.couponExpectation=this.couponExpectation??null}canAutoOpenUsingRuleBased(e,t){if(e||void 0===t)return!0;if(t>=h.l.engagementScoreThreshold){const e=`${this.variant}: open because engagement score is high enough`;return this.personalizationAutoOpenTelemetryData.message+=` - ${e}`,!0}{const e=`${this.variant}: open with ${t} rate because engagement score is not high enough.`;return this.personalizationAutoOpenTelemetryData.message+=` - ${e}`,this.canAutoOpenWithRate(t)}}calculateCouponExpectation(e){const t=this.getCouponSuccessRates(e);return this.getExpectation(t)}getCouponSuccessRates(e){return e&&e.length>0?e.filter((e=>void 0!==e.successRate)).map((e=>e.successRate)):[]}getExpectation(e){if(e&&0!==e.length)return Math.max.apply(null,e)/100}getCouponExpectationWeight(){return this.ruleBasedTriggerMap?.get(this.popupOrigination.toString())?.couponExpectationWeight??h.l.defaultCouponExpectationWeight}getRuleBasedTriggerFeaturesWithML(){const e=this.getCouponExpectationWeight();return[{feature:this.mlPopUpProbability,name:"MLOutput",weight:h.l.mlWeight},{feature:this.couponExpectation,name:"couponExpectation",weight:e}]}},y=class extends m{constructor(e,t,i,n,o,r,a){super(e,t,i,n,o,r,a),this.mlPopUpProbability=o?.userPersonalizationInfo?.mlCashbackProbability,this.personalizationAutoOpenTelemetryData.mlCashbackProbability=this.mlPopUpProbability??null}canAutoOpen(){let e="";if(this.variant===p.Nm.Micro){if(this.mlPopUpProbability&&this.mlPopUpProbability<=.6)return e="Cashback ML Micro: can't open normal notification because ML probability <= 0.6",this.personalizationAutoOpenTelemetryData.message+=` - ${e}`,!1}else if(this.mlPopUpProbability&&this.mlPopUpProbability<=.6){const t=this.getMaxNotificationCountPerMin(),i=this.getMaxNotificationCountPerHour(),n=this.getMaxNotificationCountPerDay(),o=this.ruleBasedTriggerMap?.get(this.popupOrigination.toString());if(!o)return!0;const r=o?.notificationTracker;if(!r)return!0;const a=new Date;return(a.getTime()-new Date(r.perMinFirstTriggered).getTime())/6e4<1&&r.perMinCount>=t?(e=`Cashback ML Limit: can't open normal notification because ML probability <= 0.6 and notification count exceeds the limit ${t} per min`,this.personalizationAutoOpenTelemetryData.message+=` - ${e}`,!1):(a.getTime()-new Date(r.perHourFirstTriggered).getTime())/36e5<1&&r.perHourCount>=i?(e=`Cashback ML Limit: can't open normal notification because ML probability <= 0.6 and notification count exceeds the limit ${i} per hour`,this.personalizationAutoOpenTelemetryData.message+=` - ${e}`,!1):!((a.getTime()-new Date(r.perDayFirstTriggered).getTime())/864e5<1&&r.perDayCount>=n&&(e=`Cashback ML Limit: can't open normal notification because ML probability <= 0.6 and notification count exceeds the limit ${n} per day`,this.personalizationAutoOpenTelemetryData.message+=` - ${e}`,1))}return!0}getMaxNotificationCountPerMin(){return this.mlPopUpProbability&&this.mlPopUpProbability<=.2||this.mlPopUpProbability&&this.mlPopUpProbability<=.3||this.mlPopUpProbability&&this.mlPopUpProbability,1}getMaxNotificationCountPerHour(){return this.mlPopUpProbability&&this.mlPopUpProbability<=.2?1:this.mlPopUpProbability&&this.mlPopUpProbability<=.3?2:this.mlPopUpProbability&&this.mlPopUpProbability<=.6?3:4}getMaxNotificationCountPerDay(){return this.mlPopUpProbability&&this.mlPopUpProbability<=.2?2:this.mlPopUpProbability&&this.mlPopUpProbability<=.3?4:this.mlPopUpProbability&&this.mlPopUpProbability<=.6?6:8}},C=class extends m{constructor(e,t,i,n,o,r,a){super(e,t,i,n,o,r,a),(0,s.Z)(this,"bestCompetingPrice",void 0),(0,s.Z)(this,"price",void 0),this.bestCompetingPrice=this.getBestCompetingPrice(o),this.price=o.price,this.personalizationAutoOpenTelemetryData.bestCompetingPrice=this.bestCompetingPrice??null}canAutoOpenUsingRuleBased(e,t){return e||void 0===t?!!(this.bestCompetingPrice&&this.price&&this.bestCompetingPrice/this.price>h.l.noPreviousUserDataAlwaysOpenBestCompetingPrice||this.isSpiritedShopper)||this.canAutoOpenWithRate(h.l.noPreviousUserDataAutoOpenRate):this.canAutoOpenBasedOnFeatures([{feature:t,name:"positiveEngagementScore",weight:h.l.positiveEngagementWeight},{feature:this.bestCompetingPrice,name:"couponExpectation",weight:h.l.defaultBestCompetingPriceWeight}])}getBestCompetingPrice(e){return Math.min.apply(null,e.competingPrices)}getRuleBasedTriggerFeaturesWithML(){return[{feature:this.mlPopUpProbability,name:"MLOutput",weight:h.l.mlWeight},{feature:this.bestCompetingPrice,name:"bestCompetingPrice",weight:h.l.defaultBestCompetingPriceWeight}]}},b=class extends m{constructor(e,t,i,n,o,r,a){super(e,t,i,n,o,r,a),(0,s.Z)(this,"priceDrop",void 0),this.mlPopUpProbability=o?.userPersonalizationInfo?.mlPhProbability,this.personalizationAutoOpenTelemetryData.mlPhProbability=this.mlPopUpProbability??null,this.priceDrop=this.getPriceDrop(o),this.personalizationAutoOpenTelemetryData.priceDrop=this.priceDrop??null}canAutoOpen(){let e="";if(this.variant===p.Gc.Micro){if(this.mlPopUpProbability&&this.mlPopUpProbability<=.5)return e="PH ML Micro: can't open normal notification because ml probability <= 0.5",this.personalizationAutoOpenTelemetryData.message+=` - ${e}`,!1}else if(this.mlPopUpProbability&&this.mlPopUpProbability<=.5){const t=this.getMaxNotificationCountPerMin(),i=this.getMaxNotificationCountPerHour(),n=this.getMaxNotificationCountPerDay(),o=this.ruleBasedTriggerMap?.get(this.popupOrigination.toString());if(!o)return!0;const r=o?.notificationTracker;if(!r)return!0;const a=new Date;return(a.getTime()-new Date(r.perMinFirstTriggered).getTime())/6e4<1&&r.perMinCount>=t?(e=`PH ML Limit: can't open normal notification because ml probability <= 0.5 and notification count exceeds the limit ${t} per min`,this.personalizationAutoOpenTelemetryData.message+=` - ${e}`,!1):(a.getTime()-new Date(r.perHourFirstTriggered).getTime())/36e5<1&&r.perHourCount>=i?(e=`PH ML Limit: can't open normal notification because ml probability <= 0.5 and notification count exceeds the limit ${i} per hour`,this.personalizationAutoOpenTelemetryData.message+=` - ${e}`,!1):!((a.getTime()-new Date(r.perDayFirstTriggered).getTime())/864e5<1&&r.perDayCount>=n&&(e=`PH ML Limit: can't open normal notification because ml probability <= 0.5 and notification count exceeds the limit ${n} per day`,this.personalizationAutoOpenTelemetryData.message+=` - ${e}`,1))}return!0}canAutoOpenUsingRuleBased(e,t){return e||void 0===t?!!(this.priceDrop&&this.priceDrop>h.l.noPreviousUserDataAlwaysOpenPriceDrop||this.isSpiritedShopper)||this.canAutoOpenWithRate(h.l.noPreviousUserDataAutoOpenRate):this.canAutoOpenBasedOnFeatures([{feature:t,name:"positiveEngagementScore",weight:h.l.positiveEngagementWeight},{feature:this.priceDrop,name:"priceDrop",weight:h.l.defaultPriceDropWeight}])}getPriceDrop(e){return e.priceDrop}getRuleBasedTriggerFeaturesWithML(){return[{feature:this.mlPopUpProbability,name:"MLOutput",weight:h.l.mlWeight},{feature:this.priceDrop,name:"priceDrop",weight:h.l.defaultPriceDropWeight}]}getMaxNotificationCountPerMin(){return this.mlPopUpProbability&&this.mlPopUpProbability<=.2||this.mlPopUpProbability&&this.mlPopUpProbability<=.3||this.mlPopUpProbability&&this.mlPopUpProbability,1}getMaxNotificationCountPerHour(){return this.mlPopUpProbability&&this.mlPopUpProbability<=.2?1:this.mlPopUpProbability&&this.mlPopUpProbability<=.3?2:this.mlPopUpProbability&&this.mlPopUpProbability<=.5?3:4}getMaxNotificationCountPerDay(){return this.mlPopUpProbability&&this.mlPopUpProbability<=.2?2:this.mlPopUpProbability&&this.mlPopUpProbability<=.3?4:this.mlPopUpProbability&&this.mlPopUpProbability<=.5?6:8}},S=class{static getRuleBasedTriggerController(e,t,i,s,h){let p,g;const f=a.Z.getApiResponse();switch(e){case r.sR.AUTO_SHOW_COUPONS_CHECKOUT:g=new c(f),p=new v(e,t,i,s,g,h,o.R.getServiceExperimentValue(n.H.CouponsPersonalization));break;case r.sR.AUTO_SHOW_PRICE_HISTORY:g=new u(f),p=new b(e,t,i,s,g,h,o.R.getServiceExperimentValue(n.H.PhPersonalization));break;case r.sR.AUTO_SHOW_REBATES_ORGANIC:g=new l(f),p=new y(e,t,i,s,g,h,o.R.getServiceExperimentValue(n.H.CashbackPersonalization));break;case r.sR.AUTO_SHOW_LOWER_PRICE_FOUND:g=new d(f),p=new C(e,t,i,s,g,h,void 0);break;default:g=new l(f),p=new m(e,t,i,s,g,h,void 0)}return p}}},89366:function(e,t,i){"use strict";i.d(t,{Z:function(){return n}});class n{initialize(e){e.splice(0,2);try{this.initializeRuntime(e)}catch(e){return!1}return!0}raiseMessageFromHost(e){const t=e.shift();if(t)try{this.handleMessages(e,t)}catch(e){}}postMessageToHost(e,t){try{this.getNativeHandler().sendMessageToHost(e,t)}catch(e){}}}},31024:function(e,t,i){"use strict";var n=i(27689),o=i(9448),r=i(52056);t.Z=class{static GetBackgroundAAKeyName(){return(0,n.sT)()}static CanCurrentPageDeleteBgaaState(e){return e===(0,n.Ek)()}static CanCurrentDomainDeleteBgaaState(e){return e===(0,n.S8)()}static ValidateBgAAState(e,t,i){return e.InitialPrice===t||e.TrueInitialPrice===t||this.AreEqualOrNear(e.InitialPrice-e.MaxDiscount,t)||e.InitialPrice===i||e.TrueInitialPrice===i||this.AreEqualOrNear(e.InitialPrice-e.MaxDiscount,i)}static AreEqualOrNear(e,t){return Math.abs(e-t)<.05}static SendBackgroundAAStateValidationMessage(e){r.Z.SendMessage(o.H.BackgroundAutoApplyStateValid,[e])}static ResetBackgroundAAStateValidationMessage(){r.Z.SendMessage(o.H.BackgroundAutoApplyStateValid,[""])}}},57459:function(e,t,i){"use strict";var n=i(93608);class o{static GetCartModelRequestCoupons(e,t){if(!e.length)return[];const i=o.FilterBlockedAutoApplyCoupons(e);return o.AddSuggestedCoupons(i,t)}static GetAutoApplyCoupons(e,t,i){return e.length?(e=o.AddSuggestedCoupons(e,t),e=o.HandleCartModelBlockedCoupons(e,i)):[]}static FilterUnblockedCoupons(e,t,i){return o.FilterBlockedAutoApplyCoupons(o.GetAutoApplyCoupons(e,t,i))}static AddSuggestedCoupons(e,t){if(t.length>0){const i=[...e];for(const e of[...t].reverse()){let t=e;const o=i.findIndex((t=>t.couponCode.toLowerCase()===e.couponCode.toLowerCase()));let r=n.d.NewSuggestedCoupon;-1!==o&&(t=i.splice(o,1)[0],r=n.d.ExistingSuggestedCoupon),t.suggestedCouponType=r,i.unshift(t)}return i}return e}static HandleCartModelBlockedCoupons(e,t){if(!e.length)return[];const i=[...e];if(t)for(const e of t){const t=i.findIndex((t=>t.couponCode.toLowerCase()===e.toLowerCase()));-1!==t&&(i[t].isBlockedByCart=!0)}return i}static FilterBlockedAutoApplyCoupons(e){return e.filter((e=>!e.isLowSuccessRateCoupon&&!e.isBlockedByCart))}}t.Z=o},82315:function(e,t,i){"use strict";var n=i(72370),o=i(21488),r=i(46557);class a{constructor(){(0,n.Z)(this,"retailerData",void 0),(0,n.Z)(this,"userInfo",void 0),(0,n.Z)(this,"traceId",void 0),(0,n.Z)(this,"disabledNotifications",void 0),(0,n.Z)(this,"impressionId",void 0),(0,n.Z)(this,"coupons",void 0),(0,n.Z)(this,"suppressedCoupons",void 0),(0,n.Z)(this,"cashback",void 0),(0,n.Z)(this,"market",void 0),(0,n.Z)(this,"page_locale",void 0),(0,n.Z)(this,"aFDMarket",void 0),(0,n.Z)(this,"userPersonalizationInfo",void 0),(0,n.Z)(this,"price",void 0),(0,n.Z)(this,"base64ProductImage",void 0),(0,n.Z)(this,"ranking",void 0),(0,n.Z)(this,"extracted_entity",void 0),(0,n.Z)(this,"comparableOffers",void 0),(0,n.Z)(this,"priceHistory",void 0),(0,n.Z)(this,"url",void 0),(0,n.Z)(this,"isAwarenessExpansionEnabled",void 0),(0,n.Z)(this,"personalizedAdsResponse",void 0),(0,n.Z)(this,"isCashbackEstimationSupportedForDomain",void 0),(0,n.Z)(this,"youtubeTemplates",void 0),(0,n.Z)(this,"youtubeData",void 0),(0,n.Z)(this,"trendingCoupons",void 0),(0,n.Z)(this,"productTracking",void 0),(0,n.Z)(this,"recommendations",void 0),(0,n.Z)(this,"isSSOEnabled",void 0),(0,n.Z)(this,"uHId",void 0),(0,n.Z)(this,"itemLevelCashBack",void 0),(0,n.Z)(this,"productItemizedCashBack",void 0),(0,n.Z)(this,"autos",void 0),(0,n.Z)(this,"shoppingDataContainer",void 0),(0,n.Z)(this,"checkoutData",void 0),(0,n.Z)(this,"dealDaysRetailerData",void 0),(0,n.Z)(this,"dealDaysPDP",void 0),(0,n.Z)(this,"isUserEnrolledInDealDays",void 0),(0,n.Z)(this,"completeExtractedEntity",void 0),(0,n.Z)(this,"isAmazonGiftCardEnabled",void 0),(0,n.Z)(this,"productBestCoupon",void 0),(0,n.Z)(this,"isPackageTrackingEnabled",void 0),(0,n.Z)(this,"inboxPriceMatchNotification",void 0)}static getApiResponse(){return this.apiResponse}static setApiResponse(e,t){this.apiResponse=JSON.parse(e),this.apiResponse?.retailerData&&(this.apiResponse.retailerData=r.Z.Create(this.apiResponse.retailerData),this.apiResponse.userInfo=o.Z.Create(this.apiResponse)),this.apiResponse.traceId=t}static createNewApiResponse(e,t,i){const n=JSON.parse(e);return n?.retailerData&&(n.retailerData=r.Z.Create(n.retailerData),n.userInfo=o.Z.Create(n)),n.traceId=t,n.impressionId=i,n}}(0,n.Z)(a,"apiResponse",new a),t.Z=a},49206:function(e,t,i){"use strict";i.d(t,{f:function(){return h}});var n=i(72370),o=i(31656),r=i(21597),a=i(89366),s=i(86743),l=i(3274),c=i(52056),d=i(60782);class u extends a.Z{constructor(...e){super(...e),(0,n.Z)(this,"initializeStartTime",performance.now()),(0,n.Z)(this,"scriptRunNum",0)}initializeRuntime(e){let t,i;d.M.handleInitializeRuntime(e),window.AutoOpenScriptInjected=!0,0!==this.scriptRunNum&&(this.initializeStartTime=performance.now()),e&&(e.length>r.aE.enabled_features&&(t=e[r.aE.enabled_features]),i=this.GetEnabledServiceFeatures(e)),o.R.Create(t,i);const n=(0,s.XB)();window.isAOCActive=n,c.Z.SetFullAOCActive(n),(0,l.g)(e,!1,this.initializeStartTime)}handleMessages(e,t){this.scriptRunNum=(0,l.U)(e,t,this.scriptRunNum,this.initializeStartTime)}getNativeHandler(){return AutoOpenControllerNativeHandler}GetEnabledServiceFeatures(e){let t;return e.length>r.aE.enabled_service_features&&e[r.aE.enabled_service_features].length>0?t=e[r.aE.enabled_service_features]:e.length>r.aE.enabled_service_features_v2&&e[r.aE.enabled_service_features_v2].length>0&&(t=e[r.aE.enabled_service_features_v2]),t}}const h=new u},23498:function(e,t,i){"use strict";var n=i(93209),o=i(5144),r=i(27689),a=i(2388),s=i(9448),l=i(52056),c=i(93970),d=i(9839);class u{static executeUrlParamActions(e,t){const i=(0,r.Wf)(t)??window.location.search,n=new URLSearchParams(i),o=u.getParamActionMap();n.forEach(((t,i)=>{const n=o.get(`${i}:${t}`);n&&n.forEach((t=>{t(e)}))}))}static fireAffiliateUrl(e){const t=e.retailerData?.domainName??(0,r.S8)(),i=e?.coupons?.find((e=>(0,r.Mu)(e,t)))?.offerUrl;i&&l.Z.SendNavigateToUrlMessage(i)}static getParamActionMap(){const e=new Map;return e.set("datasource:shoppingsaving",[u.sendBellIconNotificationTelemetry,u.fireAffiliateUrl]),e.set("formcode:edgeshopping",[u.fireAffiliateUrl]),e}static sendBellIconNotificationTelemetry(e){const t=e.retailerData?.domainName??(0,r.S8)();d.Q.sendMessage(s.H.RecordShoppingUserAction,[c.J6.BellIconNotifClick]),d.Q.sendMessage(s.H.RecordShoppingUserEngagement,[c.OE.BellIconNotifClick]);const i=new n.Z(o.$S.BellIconNotification,a.r.BELL_ICON,t);d.Q.sendLogEventMessage(i,o.R.ButtonClick,e.impressionId,"Bell Icon Notification Click",o.in.Information)}}t.Z=u},9839:function(e,t,i){"use strict";i.d(t,{Q:function(){return R}});var n=i(72370),o=i(4872),r=i(31656),a=i(84830),s=i(59645),l=i(58474);class c extends l.Z{constructor(e,t){super(),(0,n.Z)(this,"JourneyStage",void 0),(0,n.Z)(this,"PageVisitId",void 0),this.JourneyStage=e,this.PageVisitId=t}}var d=c,u=i(5144),h=i(39088),p=i(21597),g=i(87720),f=i(35386),m=i(73557),v=i(96658),y=i(56372),C=i(29247),b=i(71544),S=i(91495),x=i(27689),T=i(33105),w=i(65302),O=i(9448),P=i(43916),A=i(82315),E=i(86743),k=i(93970),I=i(83879),D=i(49206),_=i(68813);class N extends y.Z{constructor(...e){super(...e),(0,n.Z)(this,"traceId",void 0),(0,n.Z)(this,"apiResponse",void 0),(0,n.Z)(this,"journeyStage",f.v.UNDEFINED),(0,n.Z)(this,"sentSnoozeTelemetry",!1),(0,n.Z)(this,"snoozedPopupOriginationList",[]),(0,n.Z)(this,"bgaaComplete",void 0)}init(e){this.apiResponse=A.Z.getApiResponse(),this.initCommonInfo(this.apiResponse.impressionId,this.apiResponse.retailerData?.domainName??(0,x.S8)(),this.apiResponse.url??window.location.href,u.G7.Controller),this.traceId=e,this.sendErrorMessage=this.sendControllerErrorMessage.bind(this),this.sendStorageMessage=this.sendControllerStorageMessage.bind(this),this.sentSnoozeTelemetry=!1,this.initialize()}isCheckoutPageUsingUrlMatch(e){return!!this.getNumberParameter(e,p.aE.is_checkout_page_using_url_match)||!!this.apiResponse.retailerData?.checkoutPageUrl&&C.ZP.IsOnPage(this.apiResponse.retailerData.checkoutPageUrl,location.pathname)}isMockedCheckout(){const e=this.apiResponse.retailerData?.getCurrentCheckoutPage();if(e){if(!e?.pageType)return!1;if(e?.pageType!==u.GV.CheckoutPage)return!0}return!1}isProductPageCheckoutPageUsingUrlMatch(){if(!this.apiResponse.retailerData?.updateCurrentCheckoutPage(location.pathname))return!1;const e=this.apiResponse.retailerData?.getCurrentCheckoutPage();return e?.pageType===u.GV.ProductPage}async checkAndTriggerProductTracking(){const{retailerData:e}=this.apiResponse;if(!e)return!1;const t=this.apiResponse.retailerData?.getCurrentCheckoutPage();if(t?.pageType!==u.GV.ProductPage)return!1;const i=this.apiResponse.retailerData?.getCurrentCheckoutPage()?.catalogSelectors;return!!i&&k.ZP.ValidateProductOutOfStock(e,i,this.apiResponse?.impressionId,this.apiResponse?.productTracking)}getCurrentJourneyStage(){return this.journeyStage}resetCurrentJourneyStage(){this.journeyStage=f.v.UNDEFINED}computeCurrentJourneyStage(e){let t=f.v.UNDEFINED;if(r.R.isExperimentActive(o.H.disableJourneyStageComputation)){const e=r.R.getMultipleVariants(o.H.disableJourneyStageComputation),t=r.R.getVariantValue(e,"journeyStage",f.v.UNDEFINED);return void(this.journeyStage=t)}if(!(r.R.isExperimentActive(o.H.shoppingOnDiscover)&&r.R.isExperimentActive(o.H.temporalShoppingOnDiscover)||r.R.isExperimentActive(o.H.computeJourneyStage)))return;const i=r.R.getMultipleVariants(o.H.shoppingOnDiscover),n=r.R.getVariantValue(i,"maxCountThreshold",1),a=r.R.getVariantValue(i,"researchTotalCount",1),s=r.R.getVariantValue(i,"discoverTotalCount",1),l=r.R.getVariantValue(i,"decisionTotalCount",1),c=r.R.getVariantValue(i,"historyThresholdInMinutes",-1),h=A.Z.getApiResponse().shoppingDataContainer,g=h?.baseShoppingDataList;if(g){let e=0,i=0;for(const t of g)if(t?.contentDataType===T.q.PreviouslyViewedSimilar){const n=t;if(n)for(const[t,o]of Object.entries(n.urlTimestamps)){let t=0;for(const e of o)";"===e&&(t+=1);if(-1===c)e+=t,i=Math.max(i,t);else{let t=0;for(const e of o.split(";")){const i=Date.parse(e+" Z");Date.now()-i<1e3*c*60&&(t+=1)}e+=t,i=Math.max(i,t)}}}e>l?t=f.v.DECISION:i>n||e>a?t=f.v.RESEARCH:e>s&&(t=f.v.DISCOVER)}if(this.journeyStage=t,r.R.isExperimentActive(o.H.journeyStageTelemetry)){const i=this.getStringParameter(e,p.aE.session_ids),n=JSON.parse(i),o=new d(t,n?.pageVisitId);this.sendLogEventMessage(o,u.R.JourneyStage,this.impressionId,"",u.in.Information)}}getCurrentCategoryName(){const e=A.Z.getApiResponse().comparableOffers?.attributedatabag?.responseLevelSignals?.queryleafcategoryid;if(e&&"string"==typeof e)return e;const t=A.Z.getApiResponse().shoppingDataContainer;if(t){const e=t.baseShoppingDataList;for(const t of e)if(t?.contentDataType===T.q.CategoryInsights&&t)return t.rRCategoryInsights.leafCategoryId.toString()}return""}setAutoOpenPref(e){this.autoOpenPrefData=e,this.sendStorageMessage(g.cv,JSON.stringify({value:JSON.stringify(this.autoOpenPrefData)}))}async initializeUserPreference(e){try{const t=[],i=Object.keys(m.sR).filter((e=>!isNaN(Number(e))));for(const n of i){const i=parseInt(n,10),o=(0,w.H6)(i),r=this.getNumberParameter(e,p.aE.disabled_scenarios);if(null!=r&&r<117424127&&o&&(r&o)===o){const e=new g.ZP;e.popupOrigination=i,e.timeLastAutoOpen=Date.now(),t.push(e)}if(e.length>p.aE.snoozed_values){const n=JSON.parse(e[p.aE.snoozed_values]);if(n&&n.length>0&&n.includes(o.toString())){const e=new g.ZP;e.popupOrigination=i,e.timeLastAutoOpen=Date.now(),e.snoozeTime=864e5,t.push(e)}}}this.sendStorageMessage(g.cv,JSON.stringify({value:JSON.stringify(t)})),this.autoOpenPrefData=t}catch(e){this.sendErrorMessage(`error setting user pref for the first time ${e}`)}}setPreferenceForDomain(e,t){if(!this.autoOpenDomainPrefData||!this.autoOpenDomainPrefData?.get(t)){const i=new Map,n=[];if(t){const o=Object.keys(m.sR).filter((e=>!isNaN(Number(e))));if(e.length>p.aE.disable_popup_originations_for_current_domain){const t=JSON.parse(e[p.aE.disable_popup_originations_for_current_domain]);if(t&&2===t.length)for(const e of o){const i=parseInt(e,10),o=(0,w.H6)(i);(this.doesGroupHaveEnum(t[0],o)||this.doesGroupHaveEnum(t[1],o))&&n.push(i)}}i.set(t,n);const r=JSON.stringify({value:JSON.stringify(i,C.ZP.StringifyMap)});this.autoOpenDomainPrefData=i,this.sendStorageMessage(g.Sk,r)}}}isPopupOriginationUnblockedByMinCooldown(e){const t=this.lastShownData.get(e);if(t){const i=this.GetMinCooldownForPopupOrigination(e);if(i){return Date.now()-t>=i}}return!0}isPopupOriginationUnblockedByStageAndCategory(e){if(!r.R.isExperimentActive(o.H.shoppingOnDiscover)||!r.R.isExperimentActive(o.H.temporalShoppingOnDiscover))return!0;const t=r.R.getMultipleVariants(o.H.shoppingOnDiscover),i=r.R.getVariantValue(t,"journeyStageCooldownInMinutes",60),n=r.R.getVariantValue(t,"categoryCooldownInMinutes",1440),a=this.stageAndCategoryLastShown.get(e);let s=!0;if(a){const e=this.getCurrentJourneyStage(),t=this.getCurrentCategoryName(),o=a.categoriesBlocked.get(e);if(o&&o.length>0){Date.now()-o[o.length-1].timeLastAutoOpen<1e3*i*60&&(s=!1);for(const e of o)if(Date.now()-e.timeLastAutoOpen<1e3*n*60&&e.categoryName===t){s=!1;break}}}return s}sendControllerStorageMessage(e,t){this.sendMessage(k.EI.SetStorageValue,[e,t])}sendUpdateAddressBarMessage(e){this.sendMessage(k.EI.UpdateAddressBar,[e])}async checkIfCanUpdateOmniboxByCashbackActivationMessage(){r.R.isExperimentActive(o.H.cashbackActivationOmnibar)&&await I.Z.GetLocalDataService().GetIsCheckoutPage(this.apiResponse)&&R.sendUpdateAddressBarMessage(JSON.stringify({type:v.r.ActivateCashbackCTA}))}isPopupOriginationUnblockedByUserPref(e,t,i,n,a=!1){if(this.autoOpenPrefData&&r.R?.isExperimentActive(o.H.autoOpenControllerScript)){const o={PrefSize:this.autoOpenPrefData?.length,Reason:"",TelemetryData:i,Status:""},r=this.autoOpenPrefData.findIndex((e=>e.popupOrigination===t));if(-1!==r){const n=Date.now(),s=this.autoOpenPrefData[r].timeLastAutoOpen,l=this.autoOpenPrefData[r].snoozeTime;if(!l){if(this.reEnabledPopupOriginationForLostUser(t,i,this.autoOpenPrefData[r]))return this.sendLostUsersLogEvent(t,o,u.AM.lostUsers,u.YQ.LostUsers),!0;o.Reason="blocked";const n=this.autoOpenPrefData.filter((e=>!e.snoozeTime));return o.PrefSize=n?.length,n?.length>=29&&(this.autoOpenPrefData=this.autoOpenPrefData.filter((e=>e.snoozeTime)),this.setAutoOpenPref(this.autoOpenPrefData),o.Status="prefReset",o.Reason="maxedOut"),this.sendLogEventMessage(o,u.R.UserPref,this.impressionId,"",u.in.Information),this.sendAutoShowPreventedMessage(t,e),!1}if(n-s<l)return a&&this.snoozedPopupOriginationList.push(t),this.sendAutoShowPreventedMessage(t,e),!1}if(this.autoOpenDomainPrefData&&n&&this.autoOpenDomainPrefData.get(n)){const i=this.autoOpenDomainPrefData.get(n);if(i?.includes(t))return o.Reason="blocked for domain",this.sendLogEventMessage(o,u.R.UserPref,this.impressionId,"",u.in.Information),this.sendAutoShowPreventedMessage(t,e),!1}else{const i=(0,w.H6)(t);if(e?.length>p.aE.disable_popup_originations_for_current_domain){const n=JSON.parse(e[p.aE.disable_popup_originations_for_current_domain]);if(n&&2===n.length&&(this.doesGroupHaveEnum(n[0],i)||this.doesGroupHaveEnum(n[1],i)))return o.Reason="blocked for domain using params",this.sendLogEventMessage(o,u.R.UserPref,this.impressionId,"",u.in.Information),this.sendAutoShowPreventedMessage(t,e),!1}}return!0}if(e){const i=(0,w.H6)(t),n=this.getNumberParameter(e,p.aE.disabled_scenarios);if(null!=n&&i&&(n&i)===i)return this.sendAutoShowPreventedMessage(t,e),!1;if(e?.length>p.aE.disable_popup_originations_for_current_domain){const n=JSON.parse(e[p.aE.disable_popup_originations_for_current_domain]);if(n&&2===n.length&&(this.doesGroupHaveEnum(n[0],i)||this.doesGroupHaveEnum(n[1],i)))return this.sendAutoShowPreventedMessage(t,e),!1}if(e?.length>p.aE.snoozed_values){const n=JSON.parse(e[p.aE.snoozed_values]);if(n&&n.length>0&&n.includes(i.toString()))return this.sendAutoShowPreventedMessage(t,e),!1}}return!0}sendLogEventMessage(e,t,i,n,o){const r={};r.JsonData=JSON.stringify(e),r.EventType=t,r.LogLevel=o,r.Message=n,r.ClientContext=new a.Z(b.Z.GetClientName(),h.HQ,b.Z.GetBuildVersion(),b.Z.enabledServiceFlights),i&&(r.ImpressionId=i);const s=[JSON.stringify(r)];this.sendMessage(k.EI.LogScriptTelemetry,s)}sendLogEventMessageV2(e,t,i,n,o){const r={};r.JsonData=JSON.stringify(e),r.EventType=t,r.LogLevel=o,r.Message=n,r.ClientContext=new a.Z(b.Z.GetClientName(),h.HQ,b.Z.GetBuildVersion(),b.Z.enabledServiceFlights),i&&(r.ImpressionId=i);const s=[JSON.stringify(r)];try{this.sendMessage(k.EI.LogScriptTelemetryV2,s)}catch(e){}}sendThrottledLogEventMessage(e){r.R.getServiceExperimentValue(o.H.loggingThrottle)&&e()}isPopupOriginationUnblockedByServer(e){try{const t=this.apiResponse.retailerData?.disabledPopupOriginationList,i=t?.find((t=>t.popupOrigination===e));if(i){if(!i.jSVersionThreshold&&!i.serverExps)return!1;if(i.jSVersionThreshold&&Number(h.HQ)<Number(i.jSVersionThreshold))return!1;if(i.serverExps){const e=i.serverExps;for(const t of e){const e=`edgeServerUX.shopping.${t}`;if(r.R.isExperimentActive(e))return!1}}}}catch(e){this.sendLogEvent(this.apiResponse.impressionId,`popupOrgination unblocked by server ${e}`,"error")}return!0}isLowPerformingNotificationBlockedByExperiment(e){return r.R.isExperimentActive(o.H.blockLowPerformanceNotifications)&&N.lowPerformingNotificationsExp.includes(e)}CheckIfCanOpenForPopupOrigination(e,t,i,n,o){let r,a=!1,s=!1,l=!1,c=!1,d=!1,u=!1,h=!1;const p=this.apiResponse?.disabledNotifications;if(p){const t={PrefSize:this.autoOpenPrefData?.length};this.sendLogEvent("","NO LOST USERS DATA","Lost users not showing due to no lost users data",e.toString(),t)}let g;if(r=(0,E.Kv)(e),a=r.status,a&&(s=!this.shouldStandDown(t,e),a=s),a&&(a=!n),a&&(l=this.isPopupOriginationUnblockedByServer(e),a=l),a&&(c=this.isPopupOriginationUnblockedByMinCooldown(e),a=c),a&&(a=this.isPopupOriginationUnblockedByStageAndCategory(e)),a&&(a=this.checkIfCanOpenWithPersonalization(e)),a&&(d=this.isPopupOriginationUnblocked(e),a=d),a&&(u=this.isPopupOriginationUnblockedByUserPref(t,e,p,i,!0),a=u),a&&(h=(0,_.Oh)(e,(0,_.tW)(),I.Z.GetLocalDataService().GetUserSettingsData()),a=h),a&&(a=!this.isLowPerformingNotificationBlockedByExperiment(e)),!a){let t="Popup origination blocked";r.status?s?n?(t="Popup origination blocked due to already auto opened",g={featuresAlreadyOpened:JSON.stringify(o)}):l?c?d?u?h||(t="Popup origination blocked due to user cohort (e.g. vulnerable cohort)",g={userSettingsData:I.Z.GetLocalDataService().GetUserSettingsData()}):t="Popup origination blocked due to userPref":t="Popup origination blocked due to domain":t="Popup origination blocked due to MinCooldown":t="Popup origination blocked by server":t="Popup origination blocked due to stand down parameter":t=`Popup origination blocked due to reason: ${r.reason}`,this.sendLogEvent(this.apiResponse.impressionId,"BLOCKED POPUPORIGINATION",t,e.toString(),g)}return!!a}sendMessage(e,t){D.f.postMessageToHost(e,t)}sendCheckoutValidationStatus(e){const t=I.Z.GetLocalDataService(),i=[`${t.GetAutoApplyStatus()}`,t.GetTraceId(),`${e}`];R.sendMessage(O.H.CheckoutPageValidationStatus,i)}triggerExperiment(e){this.sendMessage(k.EI.TriggerExperiment,[e])}sendLogEvent(e,t,i,n,o,r){const a={Domain:(0,x.S8)(),PageUrl:(0,x.Ek)(),Status:i,PopupOrigination:n,Metadata:o?JSON.stringify(o):void 0};this.sendLogEventMessage(a,r??u.R.AutoOpenController,e,t,u.in.Information)}logDataRecieved(e,t){this.sendThrottledLogEventMessage((()=>{this.sendLogEvent(e?.impressionId||"",`Data recieved - ${t}`,t)}))}sendSnoozeTelemetry(){if(0===this.snoozedPopupOriginationList.length||this.sentSnoozeTelemetry)return;this.sentSnoozeTelemetry=!0;const e={Domain:(0,x.S8)(),Status:"blockedByPref",PopupOrigination:JSON.stringify(this.snoozedPopupOriginationList),Reason:"snoozed",PrefSize:0},t=this.autoOpenPrefData.filter((e=>e.snoozeTime));e.PrefSize=t?.length,this.sendLogEventMessage(e,u.R.UserPref,this.apiResponse.impressionId,"",u.in.Information)}checkUrlParam(e,t,i){return i.get(e)===t}setIsClientBgaaComplete(e){this.bgaaComplete=e}getIsClientBgaaComplete(){return this.bgaaComplete}sendLostUsersLogEvent(e,t,i,n){t.Reason=i,this.sendLogEvent(this.apiResponse.impressionId,n,"blockedByPref",e.toString(),t,u.R.EdgeFlyoutStatus)}shouldCheckIfCanOpenWithPersonalization(e){return!!(e===m.sR.AUTO_SHOW_COUPONS_CHECKOUT&&r.R.isExperimentActive(o.H.CouponsPersonalization)||e===m.sR.AUTO_SHOW_PRICE_HISTORY&&r.R.isExperimentActive(o.H.PhPersonalization)||e===m.sR.AUTO_SHOW_REBATES_ORGANIC&&r.R.isExperimentActive(o.H.CashbackPersonalization))}checkIfCanOpenWithPersonalization(e){if(!1===this.shouldCheckIfCanOpenWithPersonalization(e))return!0;try{const t=P.Z.getRuleBasedTriggerController(e,this.sendErrorMessage,this.sendStorageMessage,this.apiResponse.impressionId,S.Q?.RuleBasedTriggerData),i=t.canAutoOpen();if(i);else{const i=new s.Z(u.xu.PersonalizedAutoTriggerOff);i.Metadata=JSON.stringify({personalizationAutoOpenTelemetryData:t.getPersonalizationAutoOpenTelemetryData(),popupOriginationEnum:e}),this.sendLogEventMessage(i,u.R.EdgeFlyoutStatus,this.apiResponse.impressionId,"RuleBased Trigger Controller decides to not auto open the flyout",u.in.Information)}return i}catch(e){return this.sendErrorMessage(this.apiResponse.impressionId,`checkIfCanOpenWithPersonalization error ${(0,w.YU)(e)}`),!0}}shouldStandDown(e,t){return!(!R.getNumberParameter(e,p.aE.should_stand_down)||N.shouldNotStandDown.includes(t)||(R.isCheckoutPageUsingUrlMatch(e)&&(this.sendMessage(O.H.PageStatus,[this.traceId,""]),this.sendMessage(O.H.CheckoutPageValidationStatus,["false",this.traceId,"false"])),0))}initialize(){this.autoOpenDataStr=S.Q?.AutoOpenData,this.lastCleanedDataStr=S.Q?.LastCleanedData,this.autoOpenPrefDataStr=S.Q?.AutoOpenPrefData,this.autoOpenDomainPrefDataStr=S.Q?.AutoOpenDomainPrefData,this.lastShownDataStr=S.Q?.LastShownData,this.stageAndCategoryLastShownStr=S.Q?.StageAndCategoryLastShown,this.initializeData()}sendControllerErrorMessage(e,t){try{const i="error";this.sendLogEvent(e,t,i),this.sendMessage(k.EI.AutoOpenError,[i,this.traceId])}catch(e){}}sendAutoShowPreventedMessage(e,t){e?.toString()&&this.sendMessage(k.EI.RecordAutoShowPrevented,[t[p.aE.nagivation_guid],e.toString()])}}(0,n.Z)(N,"lowPerformingNotificationsExp",[m.sR.AUTO_SHOW_REBATES,m.sR.AUTO_SHOW_REBATES_ORGANIC_NEW,m.sR.AUTO_SHOW_EXPRESS_CHECKOUT,m.sR.AUTO_SHOW_SUSTAINABILITY_LANDING,m.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK,m.sR.AUTO_PRODUCT_TRACKING_OUT_OF_STOCK]),(0,n.Z)(N,"shouldNotStandDown",[m.sR.AUTO_SHOW_REBATES_ACTIVATION_FAILED,m.sR.AUTO_SHOW_REBATES_SWITCHED_TO_MSA,m.sR.AUTO_SHOW_REWARDS_ACTIVATION_FAILED,m.sR.AUTO_SHOW_REWARDS_SWITCHED_TO_MSA,m.sR.AUTO_SHOW_PERSONALIZED_CASHBACK,m.sR.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION,m.sR.AUTO_SHOW_REBATES_CONFIRMATION,m.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_CONFIRMATION]);const R=new N},60782:function(e,t,i){"use strict";i.d(t,{M:function(){return r}});var n=i(72370),o=i(21597);class r{static createListener(e,t,i,n){const o=n||window;let a=this.listeners.get(e);if(i&&i&&void 0!==a){for(const t of a)t.listenerContext.removeEventListener(e,t.callback);for(;a.length>0;)a.pop()}o.addEventListener(e,t),a||(a=[],r.listeners.set(e,a)),a.push({callback:t,listenerContext:n||window})}static handleInitializeRuntime(e){const t=e.length>o.aE.nagivation_guid?e[o.aE.nagivation_guid]:void 0;r.previousInitNavigationGuid&&t!==r.previousInitNavigationGuid&&r.removeListeners(),r.previousInitNavigationGuid=t}static removeListeners(){for(const[e,t]of r.listeners)for(const i of t)i.listenerContext.removeEventListener(e,i.callback);r.listeners.clear()}}(0,n.Z)(r,"listeners",new Map),(0,n.Z)(r,"previousInitNavigationGuid",void 0)},56577:function(e,t,i){"use strict";i.d(t,{Fw:function(){return o}});var n=i(72370);let o=function(e){return e.OrderId="orderId",e}({});t.ZP=class{constructor(){(0,n.Z)(this,"type",void 0),(0,n.Z)(this,"urlRegex",void 0),(0,n.Z)(this,"validationSelector",void 0),(0,n.Z)(this,"details",void 0),(0,n.Z)(this,"urlFields",void 0)}}},27900:function(e,t,i){"use strict";i.d(t,{D8:function(){return o},OY:function(){return a},Vr:function(){return c},hm:function(){return s},l$:function(){return l},xD:function(){return r}});var n=i(72370);const o="CartProductBrandCollection",r=50,a="CartDataStorageInfo",s="CartDataFastCollection",l=432e5;class c{constructor(){(0,n.Z)(this,"OrderTotal",void 0),(0,n.Z)(this,"OrderSubTotal",void 0),(0,n.Z)(this,"CartDataCreationTime",void 0),(0,n.Z)(this,"CartId",void 0),(0,n.Z)(this,"CartPreTax",void 0),(0,n.Z)(this,"CartEstimatedTax",void 0),(0,n.Z)(this,"ShipmentDate",void 0),(0,n.Z)(this,"Currency",void 0),(0,n.Z)(this,"Products",void 0),(0,n.Z)(this,"ProductIds",void 0),(0,n.Z)(this,"ProductUrls",void 0),(0,n.Z)(this,"ExtractionId",void 0),(0,n.Z)(this,"BlockedCouponsData",void 0)}}},43686:function(e,t,i){"use strict";var n=i(72370),o=i(14440);class r{constructor(){(0,n.Z)(this,"domain",void 0),(0,n.Z)(this,"cartValue",void 0),(0,n.Z)(this,"subTotal",void 0),(0,n.Z)(this,"currency",void 0),(0,n.Z)(this,"cartUrl",void 0),(0,n.Z)(this,"products",void 0),(0,n.Z)(this,"cartId",void 0),(0,n.Z)(this,"productIds",void 0)}static Create(e){const t=new r;return t.domain=e.domain??"",t.cartValue=e.cartValue??"",t.currency=e.currency??"",t.cartUrl=e.cartUrl??"",t.cartId=e.cartId??"",t.products=[],t.productIds="",e.products?.forEach((e=>{t.products.push(o.Z.Create(e))})),t}}t.Z=r},92572:function(e,t,i){"use strict";i.d(t,{Z:function(){return N}});var n=i(72370),o=i(12727),r=i(9839),a=i(91495),s=i(27689),l=i(15267),c=i(11501),d=i(29247),u=i(4238),h=i(43315),p=i(82960),g=i(5144),f=i(12265),m=i(55590),v=i(36493),y=i(27900),C=i(33491);function b(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function S(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?b(Object(i),!0).forEach((function(t){(0,n.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):b(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}const x="PurchaseCart",T="TransactionIds";class w{constructor(e,t,i,o){(0,n.Z)(this,"logger",void 0),(0,n.Z)(this,"cashbackDao",void 0),(0,n.Z)(this,"scraperService",void 0),(0,n.Z)(this,"personalDataRemover",void 0),(0,n.Z)(this,"DEFAULT_EXTRACTION_TIMEOUT",5e3),(0,n.Z)(this,"extractionId",""),this.logger=e,this.scraperService=t,this.cashbackDao=i,this.personalDataRemover=o,this.extractionId=(new Date).getTime().toString()}isPurchaseExtractionEnabled(){return this.cashbackDao.getRetailerSettings()?.GetOtherFeatureFlag("isNewCollectionEnabled")??!1}isPurchaseExtractionEnabledLogOnly(){return this.cashbackDao.getRetailerSettings()?.GetOtherFeatureFlag("isNewCollectionEnabledLog",!0)??!1}async runExtraction(){try{let e={status:f._N.NOT_ENABLED,shouldLogFragment:!1,extractionTime:0};if(!this.isPurchaseExtractionEnabled()){if(!this.isPurchaseExtractionEnabledLogOnly())return this.logDebuggMesageToConsole("Purchase extraction not enabled"),e;e.status=f._N.LOG_ONLY}const t=this.cashbackDao.getPageType();if(t===g.GV.CheckoutPage){const i=this.cashbackDao.getCheckoutPageInfo(),n=this.cashbackDao.getAutomatedSelectorsDataForPage(t);this.addCartMonitor(i,n,t),this.addBuyNowButtonListener(i,n,t);const o=performance.now();e=await this.extractDataFromCheckoutPage(i,n,t);const r=performance.now();e.extractionTime=r-o,this.logDebugOrErrorEvent("Extraction ended",t,"",void 0,!1,S({},e))}else if(t===g.GV.ConfirmationPage){const i=performance.now();e=await this.extractConfirmationPageData(t);const n=performance.now();e.extractionTime=n-i,this.logDebugOrErrorEvent("Extraction ended",t,"",void 0,!1,S({},e))}else this.logDebugOrErrorEvent("No extraction on this page",t,"",void 0,!1),this.addBuyNowButtonListener(void 0,void 0,void 0),e={status:f._N.NON_PURCHASE_OR_CHECKOUT_PAGE,shouldLogFragment:!1},this.logDebuggMesageToConsole("No extraction on this page",t);return e}catch(e){return this.logDebugOrErrorEvent("Error in extraction",g.GV.UnknownPage,"",void 0,!0,e),{status:f._N.UNKNOWN_ERROR,shouldLogFragment:!1}}}async extractConfirmationPageData(e=g.GV.ConfirmationPage){if(!this.canLogConfirmationPageData())return{status:f._N.CONFIRMATION_LOG_NOT_ENABLED,shouldLogFragment:!0};const t=this.cashbackDao.getAutomatedSelectorsDataForPage(e),i=this.getPageRegexData(void 0,t,this.cashbackDao.getConfirmationPageRegex()),n=this.getExtractionSelectorsForPurchasePage(),o=this.getExtractionSelectorsAutomated(t),r=this.cashbackDao.isCartCachingEnabled(),a=this.cashbackDao.getLastCommittedURL(),s=this.cashbackDao.getRetailerSettings(),l=r?this.readCartData():void 0;this.logDebugOrErrorEvent("Extraction started",e,i,l);const{extractionResultFromOld:c,extractionResultFromAutomated:d,extractionResult:u,extractedValuesMerged:h}=await this.extractData(n,o,!0,t,e,i,l,this.getFilteredTransactionIdSelector(!0)),p=s?.isDisablePurchaseTotalCollectionOnConfirmation??!1,m=s?.isDisableProductNamesCollectionOnConfirmation??!1,v=this.mergeConfirmationDataWithCartCahing(h,l,p,m,a);this.logDebuggMesageToConsole("result confirmationDetails after merge",v);const y=this.IsAtLeaseOneRequiredFieldPresent(v),C=this.GetMissingRequiredFieldsMessage(v);this.logExtractionResults(u,c,d,h,l,void 0,n,o,C,y,e,i,void 0);const b={isCartCachingEnabled:r,selectorsUsed:n,emptyRequiredFieldsMessage:C,pageType:e,pageRegexData:i};if(!y)return{status:f._N.FAILED_TO_EXTRACT_DATA,shouldLogFragment:!0,dataToLog:b};if(this.isTransactionIdSaved(v.transactionId)){const t=this.personalDataRemover.maskDataInAString(v.transactionId);return this.logDebugOrErrorEvent(`Purchase already recorded: ${t}`,e,i,l),{status:f._N.PURCHASE_ALREADY_RECORDED,shouldLogFragment:!1}}const S=this.cashbackDao.getAnid(),x=this.createLogData(v,S??"",t?.urlFields??null);return this.isPurchaseExtractionEnabled()?this.logPurchasePageData(x,l):this.logPurchasePageDataToDebug(x,l,e,i),this.clearCache(),this.saveTransactionIdToLocalStorage(v.transactionId),C?{status:f._N.EXTRACTION_SUCCESSFULL_BUT_MISSING_FIELDS,shouldLogFragment:!0,dataToLog:b}:{status:f._N.EXTRACTION_SUCCESSFULL,shouldLogFragment:!1}}async extractDataFromCheckoutPage(e=void 0,t=void 0,i=void 0){const n=i??g.GV.CheckoutPage,o=t??this.cashbackDao.getAutomatedSelectorsDataForPage(n),r=e??this.cashbackDao.getCheckoutPageInfo(),a=this.getPageRegexData(r,o),s=r?.cartSelectors,l=this.readCartData();this.logDebugOrErrorEvent("Extraction started",n,a,l);const c=this.getExtractionSelectors(s,r),d=this.getExtractionSelectorsAutomated(o),{extractionResultFromOld:u,extractionResultFromAutomated:h,extractionResult:m,extractedValuesMerged:y}=await this.extractData(c,d,!1,o,n,a,l),C={OrderTotal:(0,v.K)(y.orderTotal),ProductNames:y.productTitle,PricePerItem:y.productPrice,QuantityPerItem:y.productQuantity,Currency:this.getCurrency(y.orderTotal),ProductUrls:y.productSkus,ProductIds:y.productSkus,OrderSubTotal:(0,v.K)(y.orderSubTotal),ExtractionId:p.v.uuidv4(),CartDataCreationTime:Date.now(),CartId:p.v.uuidv4(),ExtractionPageRegex:a,ProductSelllers:y.productSellers};if(this.logDebuggMesageToConsole("newCartDataStorageInfo",C),!this.IsNewCart(C,l))return this.logDebugOrErrorEvent("Cached cart not sent, not new cart",n,a,C),{status:f._N.CACHED_CART_DATA_NOT_SENT,shouldLogFragment:!1};const b=this.mergeCartData(l,C);return this.logExtractionResults(m,u,h,y,l,C,c,d,"",!0,n,a,b),this.saveCartData(b),this.logCheckoutPageData(b,n,a),{status:f._N.EXTRACTION_SUCCESSFULL,shouldLogFragment:!1}}logExtractionError(e){const t=e.metadata||e.errorMessage?S({errorMessage:e.errorMessage??""},e.metadata||{}):void 0,i=this.createEventForSelectorLogger(e.pageType??g.GV.UnknownPage,e.pageRegexData??"",t,"Error in ScrapperService flow",e.msg,!0);i.IsBrokenSelectorDetected=e.isBrokenSelectorDetected??!1,i.IsPartialBrokenSelectorDetected=e.isPartialBrokenSelectorDetected??!1,i.FullSelectorUsed=e.fullSelectorUsed??"",i.PartialSelectorUsed=e.brokenSelectorPart??"",this.logSelectorDataEvent(i)}async extractData(e,t,i,n,o,r,a,s=""){const c=e=>{e.pageType=o,e.pageRegexData=r,e.cartCachingData=a,this.logExtractionError(e)},d=this.shouldEnableOldExtractionMethod()?this.scraperService.extractDataOld(e,c.bind(this)):Promise.resolve(void 0),u=this.scraperService.extractFrom(document,e,c.bind(this),!1),h=this.shouldDisableFallbackToAutomatedSelectors()?Promise.resolve(void 0):this.scraperService.extractFrom(document,t,c.bind(this),!0),[p,g,f]=await Promise.all([d,h,u]);let m="",v="";if(i){const e=this.cashbackDao.getLastCommittedURL();if(n){const t=(0,l.sB)(n);m=(0,l.RT)(t,e)}s&&(v=(0,l.ql)(s,e))}v&&(f&&(f.transactionId=v),p&&(p.transactionId=v)),m&&g&&(g.transactionId=m);const y=this.mergeExtractedData(f,p,g);return(v||m)&&(y.transactionId=v||m),{extractionResultFromOld:p,extractionResultFromAutomated:g,extractionResult:f,extractedValuesMerged:y}}shouldDisableFallbackToAutomatedSelectors(){return this.cashbackDao.getRetailerSettings()?.GetOtherFeatureFlag("isFallbackToAutomatedSelectorsDisabled")??!1}shouldEnableOldExtractionMethod(){return this.cashbackDao.getRetailerSettings()?.GetOtherFeatureFlag("isEnableOldExtractionMethod")??!1}canLogConfirmationPageData(){return this.cashbackDao.getRetailerSettings()?.IsAttibutionEnabled()??!1}async addBuyNowButtonListener(e,t,i){const n=e??this.cashbackDao.getPageInfo(),o=i??n?.pageType??g.GV.UnknownPage,r=n?.buyNowSelector??"";if(!r)return;const a=this.createSelectorSetting(r,"buyNowButton"),s=this.getPageRegexData(n,t),l=await this.scraperService.getElementForSelector(a,(e=>{e.pageType=o,e.pageRegexData=s,e.cartCachingData=void 0,this.logExtractionError(e)}).bind(this));l&&l.addEventListener("click",(()=>{this.logDebugOrErrorEvent("Buy Now clicked",o,s,void 0),this.extractDataFromCheckoutPage(n,t,o)}))}async addCartMonitor(e,t,i=g.GV.CheckoutPage){const n=e?.orderTotalDataElementSelector||t?.details?.orderTotalPrice||"";if(n){const o=this.getPageRegexData(e,t),r=e=>{e.pageType=i,e.pageRegexData=o,e.cartCachingData=void 0,this.logExtractionError(e)},a=()=>{this.extractDataFromCheckoutPage(e,t,i)},s=this.createSelectorSetting(n,"cartMutationObserver");await this.scraperService.addMutationObserver(s,r.bind(this),a.bind(this))}}getPageRegexData(e,t,i=""){return JSON.stringify({automated:t?.urlRegex??"",regular:e?.checkoutPageUrl||i})}saveCartData(e){const t=e?JSON.stringify(e):"";this.cashbackDao.saveToLocalCache(x,t),this.cashbackDao.saveToLocalCachePersistent(x,t)}getCurrency(e){const t=this.cashbackDao.getAfdMarket(),i=(0,v.N6)(t);return(e?(0,v.cU)(e,!0):"")||i||""}mergeCartData(e,t){return{OrderTotal:t?.OrderTotal||e?.OrderTotal||0,ProductNames:t?.ProductNames||e?.ProductNames||"",PricePerItem:t?.PricePerItem||e?.PricePerItem||"",QuantityPerItem:t?.QuantityPerItem||e?.QuantityPerItem||"",Currency:t?.Currency||e?.Currency||"",ProductUrls:t?.ProductUrls||e?.ProductUrls||"",ProductIds:t?.ProductIds||e?.ProductIds||"",OrderSubTotal:t?.OrderSubTotal||e?.OrderSubTotal||0,ExtractionId:t?.ExtractionId||e?.ExtractionId||"",CartDataCreationTime:t?.CartDataCreationTime||e?.CartDataCreationTime||0,CartId:t?.CartId||e?.CartId||"",ExtractionPageRegex:t?.ExtractionPageRegex||e?.ExtractionPageRegex||"",ProductSelllers:t?.ProductSelllers||e?.ProductSelllers||""}}mergeExtractedData(e,t,i){return{productQuantity:e?.productQuantity||t?.productQuantity||i?.productQuantity||"",productTitle:e?.productTitle||t?.productTitle||i?.productTitle||"",productPrice:e?.productPrice||t?.productPrice||i?.productPrice||"",productTitleFromImage:e?.productTitleFromImage||i?.productTitleFromImage||i?.productTitleFromImage||"",productSkus:e?.productSkus||t?.productSkus||i?.productSkus||"",orderTotal:e?.orderTotal||t?.orderTotal||i?.orderTotal||"",orderSubTotal:e?.orderSubTotal||t?.orderSubTotal||i?.orderSubTotal||"",transactionId:e?.transactionId||t?.transactionId||i?.transactionId||"",productSellers:e?.productSellers||t?.productSellers||i?.productSellers||""}}mergeConfirmationDataWithCartCahing(e,t,i,n,o){const r=new h.Z;if(r.orderConfirmationPageUrl=o,r.transactionId=e.transactionId,t&&this.setConfirmationDetailsFromCartCaching(t,r),r.productNames&&n||this.setProductNamesFromPurchasePageIfPresent(e,r),r.purchaseTotal&&i||this.setOrderTotalAndCurrencyIfPresent(e,r),e.orderSubTotal&&(r.orderSubTotalPrice=e.orderSubTotal),e.productQuantity&&(r.quantityPerItem=e.productQuantity),e.productPrice&&(r.pricePerItem=e.productPrice),r.productNames){const e=r.productNames.split(this.scraperService.getSeparator());r.numberOfItems=e.length.toString()}return r}createLogData(e,t,i){const{isElectron:n,isChromeDriver:o,driverEvaluate:r,webdriverEvaluate:a,seleniumUnwrapped:l,windowCallPhantom:c,WINDOW_PHANTOM:d,windowPhantom:u}=this.getBrowserData(),h=this.cashbackDao.getSessionIds(),p=h?.retailerSessionId??"",g=h?.pageVisitId??"";let f=e.productNames,m=e.transactionId??"";const v=this.getDynamicTransactionId();let y=e.orderConfirmationPageUrl,C=!1;m=this.personalDataRemover.maskDataInAString(m),f=this.personalDataRemover.maskDataInAString(f),y=this.personalDataRemover.deleteSecretsInURL(y);const b=this.cashbackDao.getPersonalizedCashback();return this.cashbackDao?.getRetailerSettings()?.transactionIdSettings?.shouldAutoGenerate&&(m=v,C=!0),{Currency:e.currency??"",Domain:(0,s.uE)(window.location.hostname),DriverEvaluate:r?JSON.stringify(r):"",EventId:this.GetEventId(),IsChromeDriver:o,IsElectron:n,NavigatorWebdriver:navigator.webdriver??!1,NumberOfItems:e.numberOfItems??"",OrderConfirmationPageUrl:y??"",OrderConfirmationPageUrlRegex:(0,s.og)(y,this.cashbackDao.getConfirmationPageRegex()),OrderDiscountCode:e.orderDiscountCode??"",OrderDiscountPrice:e.orderDiscountPrice??"",OrderShippingPrice:e.orderShippingPrice??"",OrderSubTotalPrice:e.orderSubTotalPrice??"",OrderTaxesPrice:e.orderTaxesPrice??"",Platform:this.cashbackDao.getPlatform(),PricePerItem:e.pricePerItem??"",ProductIdSku:e.productIdSku??"",ProductNames:f??"",ProductSellerNames:e.productSellerNames??"",PurchaseTotal:e.purchaseTotal??"",QuantityPerItem:e.quantityPerItem??"",PersonalizationDataConsent:this.cashbackDao.getSanConsentFlag(),Rguid:b?.rGuid??"",SeleniumUnwrapped:l??"",TransactionId:m,WebdriverEvaluate:a??"",WindowCallPhantom:c??"",WindowPhantom:u?JSON.stringify(u):"",Window_Phantom:d?JSON.stringify(d):"",DomainCountry:"",RetailerDataDomain:this.cashbackDao.getCurrentDomain(),ExactConfirmationPageUrl:this.cashbackDao.getConfirmationPageRegex()??"",ESF:this.cashbackDao.getESF(),Anid:t,ActiveCashbackOffers:b?JSON.stringify(b):"",IsAADSignedIn:this.cashbackDao.isAadSignedIn(),PageUrlFields:i,PageVisitId:g,RetailerSessionId:p,DynamicTransactionId:v,IsDynamicTransaction:C,ProductBrandNames:this.getBrandNamesFromCachedProductNames(f)??""}}getBrandNamesFromCachedProductNames(e){let t=[];if(e)try{let i=JSON.parse((0,C.Mw)(y.D8)||"[]");const n=e?.split(this.scraperService.getSeparator());n&&n.pop();for(const e of n){let n="";for(const t of i)t?.ProductName?.includes(e)&&(n=t?.ProductBrandName??"");t.push(n)}}catch(e){this.logDebugOrErrorEvent("Couldn't extract brand names from cached product PDP info;",g.GV.UnknownPage,"",void 0,!0,{error:e})}return t?.join(this.scraperService.getSeparator())+this.scraperService.getSeparator()}getDynamicTransactionId(){try{const e=a.Q?.CheckoutPageNavigatedTime,t=a.Q?.DynamicTransactionId??"",i=this.stringToDate(e??""),n=i&&this.isValidTimeDifference(i,new Date)?t:"";return this.logDebuggMesageToConsole("Dynamic Transaction Id ->",n),this.logDebuggMesageToConsole("Dynamic Transaction Id checkout time",i),n??""}catch(e){return""}}saveTransactionIdToLocalStorage(e){if(!e)return;const t=this.getSavedTransactionIds(),i=this.cashbackDao.getCurrentDomain();t[i]||(t[i]={});const n=new Date;t[i][e]=n.getTime().toString(),this.cashbackDao.saveToLocalCache(T,JSON.stringify(t))}isTransactionIdSaved(e){if(!e)return!1;const t=this.getSavedTransactionIds(),i=this.cashbackDao.getCurrentDomain();return Boolean(t&&t[i]&&t[i][e])}getSavedTransactionIds(){return this.cashbackDao.readFromLocalCache(T)??{}}clearCache(){this.cashbackDao.saveToLocalCachePersistent(m.Q.CheckoutPageNavigatedTime,JSON.stringify({value:""})),this.cashbackDao.saveToLocalCachePersistent(m.Q.DynamicTransactionId,JSON.stringify({value:""})),this.saveCartData()}logCheckoutPageData(e,t,i){this.logDebuggMesageToConsole("logging checkout page event",e);const n=this.createEventForSelectorLogger(t,i,void 0,"NewExtraction:::CheckoutData","",!1,e);this.logSelectorDataEvent(n)}logDebugOrErrorEvent(e,t,i,n,o=!1,r){const a=this.createEventForSelectorLogger(t,i,r,e,"",o,n);this.logSelectorDataEvent(a)}logSelectorDataEvent(e){this.logDebuggMesageToConsole(e.Message),this.logger.LogInfoWithEvenType(e.Message,g.R.SelectorDataExtraction,e,this.cashbackDao.getImpressionId())}logPurchasePageDataToDebug(e,t,i,n){e.Anid="",this.logDebuggMesageToConsole("logging purchase event to log table only",e);const o=this.createEventForSelectorLogger(i,n,{confirmationEvent:e},"New purchase extraction event","",!1,t);this.logger.LogInfoWithEvenType(o.Message,g.R.SelectorDataExtraction,o,this.cashbackDao.getImpressionId())}logPurchasePageData(e,t){this.logDebuggMesageToConsole("logging purchase event",e);const i={isNewExtraction:!0,cachedCart:t,extractionId:this.extractionId};this.logger.LogInfoWithEvenType(JSON.stringify(i),g.R.ConfirmationPageDetails,e,this.cashbackDao.getImpressionId())}readCartData(){const e=this.cashbackDao.readFromLocalCachePersistent(x);return this.cashbackDao.readFromLocalCache(x)||e}setProductNamesFromPurchasePageIfPresent(e,t){e.productTitle?t.productNames=e.productTitle:e.productTitleFromImage&&(t.productNames=e.productTitleFromImage)}setOrderTotalAndCurrencyIfPresent(e,t){let i=0;const n=(0,v.K)(e.orderTotal);if(n>0)i=n;else{const t=(0,v.K)(e.orderSubTotal);t>0&&(i=t)}let o=(0,v.cU)(e.orderTotal,!0);o||(o=e.productPrice?(0,v.cU)(e.productPrice,!0):""),o||(o=e.orderSubTotal?(0,v.cU)(e.orderSubTotal,!0):""),o&&(t.currency=o),i>0&&(t.purchaseTotal=`${t.currency}${i}`)}setConfirmationDetailsFromCartCaching(e,t){t.pricePerItem=e.PricePerItem??"",t.quantityPerItem=e.QuantityPerItem??"",t.productUrls=e.ProductUrls??"",t.productNames=e.ProductNames??"";const i=e.Currency??"",n=e.OrderTotal>0?e.OrderTotal:0,o=e.OrderSubTotal&&e.OrderSubTotal>=0?e.OrderSubTotal:0,r=n>0?n:o;t.orderSubTotalPrice=o>0?`${i}${o}`:"",t.purchaseTotal=r>0?`${i}${r}`:"",t.currency=i,t.productSellerNames=e.ProductSelllers??""}GetTimeoutForSelector(e){const t=this.cashbackDao.getRetailerSettings()?.selectorTimeouts;return e&&t&&void 0!==t[e]?t[e]:this.DEFAULT_EXTRACTION_TIMEOUT}IsAtLeaseOneRequiredFieldPresent(e){return Boolean(e.transactionId||e.productNames||e.purchaseTotal&&"0"!==e.purchaseTotal)}logExtractionResults(e,t,i,n,o,r,a,s,l,c,d,u,h=void 0){if(a&&this.logDebuggMesageToConsole("selectors extractByValues",a),s&&this.logDebuggMesageToConsole("selectors extractByValues_Automated",s),e&&this.logDebuggMesageToConsole("result extraction_Result",e),t&&this.logDebuggMesageToConsole("result extraction_Result_Old",t),i&&this.logDebuggMesageToConsole("result extraction_ResultFrom_Automated",i),this.logDebuggMesageToConsole("result extractedData_merged",n),o&&this.logDebuggMesageToConsole("old cartCachingData",o),r&&this.logDebuggMesageToConsole("new cartCachingData",r),h&&this.logDebuggMesageToConsole("mergedCart",h),this.LogMissingExtractedValuesForSelectors(a,e,"general",h??r??o,d,u),t&&this.LogMissingExtractedValuesForSelectors(a,t,"old",h??r??o,d,u),i&&this.LogMissingExtractedValuesForSelectors(s,i,"automated",h??r??o,d,u),!c){const e=this.cashbackDao.isCartCachingEnabled(),t=this.createEventForSelectorLogger(d,u,{isCartCachingEnabled:e,selectorsUsed:a},"No valid required fields",l,!0,h??r??o);this.logSelectorDataEvent(t)}}LogMissingExtractedValuesForSelectors(e,t,i,n,o,r){if(!e){const e=this.createEventForSelectorLogger(o,r,void 0,"No selectors for page",i,!0,n,t);return void this.logSelectorDataEvent(e)}const a={productTitle:!0,productTitleFromImage:!0,orderTotal:!0,orderSubTotal:!0,transactionId:!0,productQuantity:!1,productPrice:!1,productSkus:!1,productSellers:!1};let s={};if(Object.keys(e).forEach((i=>{if(a[i]){const n=e[i],o=t?t[i]:void 0;n?.selector&&!o&&(s[i]?s[i]+=`; ${n.selector}`:s[i]=n.selector)}})),Object.keys(s).length>0){const e=this.createEventForSelectorLogger(o,r,void 0,"Broken selectors found",i,!0,n,t);e.BrokenSelectors=JSON.stringify(s),e.IsBrokenSelectorDetected=!0,this.logSelectorDataEvent(e)}}GetMissingRequiredFieldsMessage(e){return e.productNames&&e.purchaseTotal&&"0"!==e.purchaseTotal&&e.transactionId?"":`${e.productNames?"":"Empty productNames;"}${e.purchaseTotal?"0"==e.purchaseTotal?"PurchaseTotal is 0":"":"Empty purchaseTotal;"}${e.transactionId?"":"Empty transactionId;"}`}GetEventId(){let e=p.v.uuidv4();return e&&""!==e||(e=this.uuidv4()),e}uuidv4(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(e=>{const t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)}))}isValidTimeDifference(e,t){try{const i=t.getTime()-e.getTime(),n=Math.floor(i/1e3),o=Math.floor(n/60);return this.logDebuggMesageToConsole("Dynamic Transaction Id - purchase time",t),this.logDebuggMesageToConsole("Dynamic Transaction Id - checkout time",e),this.logDebuggMesageToConsole("Dynamic Transaction Id - minutes",o),o>3&&this.logDebuggMesageToConsole("Dynamic Transaction Id waited more than 3 minutes"),o<=3}catch(e){return!1}}stringToDate(e){try{if(""===e)return;const[t,i]=e.split(" "),[n,o,r]=t.split("-").map(Number),[a,s,l]=i.split(":").map(Number);return new Date(n,o-1,r,a,s,l)}catch(e){return}}getBrowserData(){let e="",t="",i="",n="",o=!1;const r=window?.windowCallPhantom,a=window?._phantom,s=window?.phantom;return document?.documentElement?.hasAttribute("__selenium_unwrapped")&&(e=document.documentElement.getAttribute("__selenium_unwrapped")),document?.documentElement?.hasAttribute("__webdriver_evaluate")&&(t=document.documentElement.getAttribute("__webdriver_evaluate")),document?.documentElement?.hasAttribute("__driver_evaluate")&&(i=document.documentElement.getAttribute("__driver_evaluate")),document?.documentElement?.hasAttribute("$cdc_asdjflasutopfhvcZLmcfl_")&&(n=typeof document.documentElement.getAttribute("$cdc_asdjflasutopfhvcZLmcfl_")),o="undefined"!=typeof window&&"object"==typeof window.process&&"renderer"===window.process?.type||!("undefined"==typeof process||"object"!=typeof process.versions||!process.versions.hasOwnProperty("electron")),{isElectron:o,isChromeDriver:n,driverEvaluate:i,webdriverEvaluate:t,seleniumUnwrapped:e,windowCallPhantom:r,WINDOW_PHANTOM:a,windowPhantom:s}}createEventForSelectorLogger(e,t,i,n,o,r,a=void 0,s=void 0){let l;l=a||this.readCartData();const c=this.cashbackDao.getSanConsentFlag(),d=this.cashbackDao.getSessionIds();return{IsBrokenSelectorDetected:!1,IsPartialBrokenSelectorDetected:!1,BrokenSelectors:"",FullSelectorUsed:"",PartialSelectorUsed:"",Currency:a?.Currency??"",ExtractionResult:c&&s?JSON.stringify(s):"",CartData:c&&l?JSON.stringify(l):"",ErrorMessage:o,Metadata:i?JSON.stringify(i):"",Message:n,IsError:r,PageUrl:this.getCurrentUrlValue(!0),PageType:e,PageRegexUsed:t,Domain:this.cashbackDao.getCurrentDomain(),AFDMarket:this.cashbackDao.getAfdMarket(),IsSignedIn:this.cashbackDao.isSignedIn(),PageVisitId:d?.pageVisitId??"",RetailerSessionId:d?.retailerSessionId??"",PersonalizationDataConsent:c,ExtractionId:this.extractionId}}IsNewCart(e,t){return t?e.ExtractionPageRegex!==t.ExtractionPageRegex?(this.logDebuggMesageToConsole("New and old cart difference: ExtractionPageRegex"),!0):e.Currency!==t.Currency?(this.logDebuggMesageToConsole("New and old cart difference: Currency"),!0):e.OrderTotal!==t.OrderTotal?(this.logDebuggMesageToConsole("New and old cart difference: OrderTotal"),!0):e.ProductNames!==t.ProductNames?(this.logDebuggMesageToConsole("New and old cart difference: ProductNames"),!0):e.OrderSubTotal!==t.OrderSubTotal&&(this.logDebuggMesageToConsole("New and old cart difference: OrderSubTotal"),!0):(this.logDebuggMesageToConsole("no cached cart"),!0)}getExtractionSelectorsForPurchasePage(){const e=this.cashbackDao.getConfirmationPageTelemetryData(),t=e?.productDetailsData&&e.productDetailsData.length>0?e.productDetailsData[0]:void 0;if(!e&&!t)return;const i=this.getFilteredTransactionIdSelector(!1),n={productQuantity:this.createSelectorSetting(t?.productQuantitySelector,"productQuantity"),productTitle:this.createSelectorSetting(t?.productIdSelector,"productNames"),productTitleFromImage:this.createSelectorSetting(t?.productImageSelector,"productNamesFromImg"),productPrice:this.createSelectorSetting(t?.productPriceSelector,"productPrice"),productSkus:this.createSelectorSetting(t?.productIdSkuSelector,"productId"),orderTotal:this.createSelectorSetting(e?.purchaseTotalSelector,"orderTotalPrice"),orderSubTotal:this.createSelectorSetting(e?.orderSubTotalPriceSelector,"orderSubTotalPrice"),transactionId:this.createSelectorSetting(i,"transactionId"),productSellers:{selector:"",timeout:0}};return this.addExtractMultipleFlag(n)}getFilteredTransactionIdSelector(e){const t=this.cashbackDao.getConfirmationPageTelemetryData();return(t?.transactionIdSelector?.split(",")??[]).filter((t=>e?(0,l.Ae)(t):!(0,l.Ae)(t))).join(",")}getExtractionSelectors(e,t){if(!e&&!t)return;const i={productQuantity:this.createSelectorSetting(e?.productQuantitySelector,"productQuantity"),productTitle:this.createSelectorSetting(e?.productTitleSelector,"productNames"),productPrice:this.createSelectorSetting(e?.productPriceSelector,"productPrice"),productSkus:this.createSelectorSetting(e?.productIdSkuSelector,"productId"),productTitleFromImage:this.createSelectorSetting(e?.productImageSelector,"productNamesFromImg"),orderTotal:this.createSelectorSetting(t?.orderTotalDataElementSelector,"orderTotalPrice"),orderSubTotal:this.createSelectorSetting(t?.orderSubTotalElementSelector,"orderSubTotalPrice"),transactionId:{selector:"",timeout:0},productSellers:this.createSelectorSetting(e?.productSellerSelector,"productSeller")};return this.addExtractMultipleFlag(i)}getExtractionSelectorsAutomated(e){const t={productQuantity:this.createSelectorSetting(e?.details?.productQuantity,"productQuantity"),productTitle:this.createSelectorSetting(e?.details?.productName,"productNames"),productPrice:this.createSelectorSetting(e?.details?.productPrice,"productPrice"),productSkus:this.createSelectorSetting(e?.details?.productId,"productId"),productTitleFromImage:this.createSelectorSetting(e?.details?.getProductNamesFromImg,"productNamesFromImg"),orderTotal:this.createSelectorSetting(e?.details?.orderTotalPrice,"orderTotalPrice"),orderSubTotal:this.createSelectorSetting(e?.details?.orderSubTotalPrice,"orderSubTotalPrice"),transactionId:this.createSelectorSetting(e?.details?.orderId,"transactionId"),productSellers:{selector:"",timeout:0}};return this.addExtractMultipleFlag(t)}getCurrentUrlValue(e){return this.personalDataRemover.getCurrentUrlValue(e,this.cashbackDao.getLastCommittedURL())}createSelectorSetting(e,t){return{selector:e??"",timeout:this.GetTimeoutForSelector(t)}}addExtractMultipleFlag(e){const t={productQuantity:!0,productTitle:!0,productPrice:!0,orderTotal:!1,orderSubTotal:!1,transactionId:!1,productTitleFromImage:!0,productSkus:!0,productSellers:!0};return Object.keys(e).forEach((i=>{if(t[i]&&e[i]){const n=t[i]??!1;e[i].shouldExtractAll=n}})),e}logDebuggMesageToConsole(...e){}}class O{LogColdPathTelemetryEvent(e,t,i,n,o=!1){r.Q.sendLogEventMessageV2(i,t,n,e,o?g.in.Error:g.in.Information)}LogInfoWithEvenType(e,t,i,n){r.Q.sendLogEventMessage(i,t,n,e,g.in.Information)}}var P=i(45822),A=i(64865);function E(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function k(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?E(Object(i),!0).forEach((function(t){(0,n.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):E(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}class I{constructor(){(0,n.Z)(this,"mutationObserver",void 0)}getSeparator(){return I.SEP}async getElementForSelector(e,t){try{return e.timeout>0&&await(0,d._R)(e.timeout),this.GetFirstVisibleElement(e.selector)}catch(i){t({msg:"ERROR getElementForSelector",errorMessage:i.toString(),metadata:k({},e)})}}async extractFrom(e,t,i,n=!1){if(!t)return;let o=!1;const r={productQuantity:"",productTitle:"",productPrice:"",productTitleFromImage:"",productSkus:"",orderTotal:"",orderSubTotal:"",transactionId:"",productSellers:""};try{const a=[],s=Object.keys(t);s.forEach((o=>{const r=t[o];a.push(this.extractFromElement(r,e,r.shouldExtractAll??!1,i,n))}));const l=await Promise.all(a);for(let e=0;e<s.length;e++)r[s[e]]=l[e],o||(o=!!l[e])}catch(o){i({msg:"ERROR extractFrom",errorMessage:o.toString(),metadata:{element:typeof e,valueSelectors:t,isFromAutomated:n}})}return o?r:void 0}async extractDataOld(e,t){if(!e)return;const i=this.GetItemizedProductData(e.productTitle,t),n=this.GetItemizedProductData(e.productPrice,t),o=this.GetItemizedProductData(e.productQuantity,t),r=this.GetItemizedProductData(e.productSkus,t),a=this.GetProductNamesFromImage(e.productTitleFromImage.selector,t),s=this.GetDataBySelector(e.transactionId,this.isValidString,t),l=this.GetDataBySelector(e.orderTotal,this.IsStringContainNumbers,t),c=this.GetDataBySelector(e.orderSubTotal,this.IsStringContainNumbers,t),d=this.GetItemizedProductData(e.productSellers,t),[u,h,p,g,f,m,v,y]=await Promise.all([i,n,o,r,l,c,s,d]);return{productQuantity:p,productTitle:u,productPrice:h,productTitleFromImage:a,productSkus:g,orderTotal:f,orderSubTotal:m,transactionId:v,productSellers:y}}async addMutationObserver(e,t,i){try{const t={attributes:!0,characterData:!0,childList:!0,subtree:!0};if(this.mutationObserver||(this.mutationObserver=new MutationObserver((async e=>{await i()}))),e.selector){e.timeout>0&&await(0,d.dz)((async()=>void 0!==this.GetFirstVisibleElement(e.selector)),e.timeout);const i=this.GetFirstVisibleElement(e.selector);i&&(this.mutationObserver?.disconnect(),this.mutationObserver?.observe(i,t))}}catch(i){t({msg:"error adding monitor",errorMessage:i.toString(),metadata:{selectorSettings:e}})}}async extractFromElement(e,t,i,n,o){let r="";try{if(!e.selector)return"";r=this.extractDataFromElement(e.selector,t,i,n,e.useInnerText??!1,o),!r&&e.timeout&&(await(0,d._R)(e.timeout),r=this.extractDataFromElement(e.selector,t,i,n,e.useInnerText??!1,o))}catch(t){n({msg:"error in extractFromElement",errorMessage:t.toString(),fullSelectorUsed:e.selector,metadata:{isFromAutomated:o}})}return r}extractDataFromElement(e,t,i,n,o,r){if(e.includes(I.SHADOW_ROOT_SEP)){const n=this.getShadowRootData(e,t);return this.extractAsTextShadowRoots(n,i,o)}let a="";if(e&&e.includes(",")){const s=e.split(",").reverse();let l=!1;for(const c of s){const s=this.extractAsText(t,c,i,o);if(s){l=!0,a=s;break}n({msg:"Value not found for partial selector",brokenSelectorPart:c,isPartialBrokenSelectorDetected:!0,fullSelectorUsed:e,metadata:{isFromAutomated:r}})}l||(a=this.extractAsText(t,e,i,o),a||n({msg:"Broken selector full",fullSelectorUsed:e,isBrokenSelectorDetected:!0,metadata:{isFromAutomated:r}}))}else a=this.extractAsText(t,e,i,o),a||n({msg:"Broken selector full",fullSelectorUsed:e,isBrokenSelectorDetected:!0,metadata:{isFromAutomated:r}});return a}extractAsTextShadowRoots(e,t,i){let n="";for(let o of e)if(o){const e=this.getTextContent(o,i);if(e){if(!t)return e;n+=e+I.SEP}}return n}extractAsText(e,t,i,n){let o="";if(i)e.querySelectorAll(t).forEach((e=>{if(e){const t=this.getTextContent(e,n);t&&(o+=t+I.SEP)}}));else{const i=e.querySelector(t);o=this.getTextContent(i,n)}return o}getTextContent(e,t){let i="";if(e&&"select"===e.tagName.toLowerCase()){const t=e;i=t.options&&t.options[t.selectedIndex]?.text||""}else i=e&&"input"===e.tagName.toLowerCase()?e.value:t&&e?e.innerText??"":e?.textContent??"";return(i?this.StripMultipleSpaces(this.StripInvalidJSONCharacters(i)):"").trim()}isValidString(e){return!!e}IsStringContainNumbers(e){return new RegExp("/[0-9]/").test(e)}GetValueCommaSplit(e,t,i){let n="";if((e=e.replace(/;/g,","))&&e.includes(",")){const o=e.split(",").reverse();let r=!1;for(const e of o){const o=this.GetBoxValue(e,i);if(o&&t(o)){r=!0,n=o;break}}r||(n=this.GetBoxValue(e,i))}else n=this.GetBoxValue(e,i);return n?n.trim():""}GetBoxValue(e,t){if(e&&(0,d.UE)(e))try{const t=this.GetTextValue(e);if(t)return t.trim()}catch(e){t(e.message)}return""}GetTextValue(e){const t=e.split(";"),i=this.GetFirstVisibleElement(t[0]);let n=i;if(void 0===n)return"";let o=n.innerText;if(1===t.length)n=this.NormalizeIfSuperscripted(i),o=n?.innerText??"";else{const e=this.GetFirstVisibleElement(t[1]);if(e&&e.innerText){const t="."+e.innerText;if(n.contains(e)){const e=n.cloneNode(!0);e.childNodes.forEach((t=>{t.nodeType===Node.ELEMENT_NODE&&e.removeChild(t)})),o=e?.innerText?e.innerText:o}o+=t}}return this.StripInvalidJSONCharacters(o)}StripMultipleSpaces(e){return e.replace(/\s\s+/g," ")}StripInvalidJSONCharacters(e){return e.replace(/\n/gi,"")}NormalizeIfSuperscripted(e){if(e&&e.innerHTML&&e.innerHTML.toLowerCase().indexOf("</sup>")>-1){const t=e.cloneNode(!0),i=t.childNodes.length;for(let e=0;e<i;e++){const i=t.childNodes[e];if("SUP"===i.tagName){let e=i.innerText;const n=/[0-9\.]+/g.exec(e);if(null!==n)return e="."+n[0],i.innerText=e,t}}}return e}GetProductNamesFromImage(e,t){try{if((0,d.UE)(e)){const t=this.RunQuerySelectorAll(e);let i="";for(const e of t){const t=e?.getAttribute("alt");t&&(i+=t+I.SEP)}return i}return""}catch(i){t({msg:"error in GetProductNamesFromImage",errorMessage:i.toString(),fullSelectorUsed:e})}return""}async GetItemizedProductData(e,t){try{if(!e.selector||(0,A.TF)(e.selector)||!(0,d.UE)(e.selector))return"";let t;return await(0,d.dz)((async()=>(t=this.GetFirstVisibleElement(e.selector??""),void 0!==t)),e.timeout),this.GetItemizedData(e.selector??"",I.SEP)}catch(i){t({msg:"error in GetItemizedProductData",errorMessage:i.toString(),fullSelectorUsed:e.selector})}return""}async GetDataBySelector(e,t,i){return e.selector&&!(0,A.TF)(e.selector)&&(0,d.UE)(e.selector)?await(0,d.dz)((async()=>this.RunQuerySelectorAll(e.selector).length>0),e.timeout).then((async()=>this.GetValueCommaSplit(e.selector,t,i))).catch((t=>(i({msg:"error in GetDataBySelector",errorMessage:t.toString(),fullSelectorUsed:e.selector}),""))):""}GetItemizedData(e,t,i){let n="";if(e){const o=this.RunQuerySelectorAll(e,i);for(const e of o)e&&e.textContent&&(n+=e.textContent.trim()+t)}return n}GetFirstVisibleElement(e,t){if(!(0,d.UE)(e))return;const i=e.split(";");for(const e of i)try{const i=this.RunQuerySelectorAll(e,t);for(const e of i)if(this.IsElementVisible(e))return e}catch(e){}}RunQuerySelectorAll(e,t){if(!(0,d.UE)(e))return[];e=e.replace(/;/g,",");const i=t??document;return this.getShadowRootData(e,i)}getShadowRootData(e,t){const i=e.split(I.SHADOW_ROOT_SEP);let n=t.querySelectorAll(i[0]);for(const e of i.slice(1)){const t=n[0]?.shadowRoot;if(!t)break;n=t.querySelectorAll(e)}return n||[]}IsElementVisible(e){return e&&e.offsetWidth>0&&e.offsetHeight>0}}(0,n.Z)(I,"SEP","<SEP>"),(0,n.Z)(I,"SHADOW_ROOT_SEP","<");var D=I;class _{constructor(e,t,i,o){(0,n.Z)(this,"apiResponse",void 0),(0,n.Z)(this,"personalDataRemover",void 0),(0,n.Z)(this,"cashbackDAO",void 0),(0,n.Z)(this,"cartExtractionService",void 0),(0,n.Z)(this,"cashbackLogger",void 0),(0,n.Z)(this,"scraperService",void 0),(0,n.Z)(this,"sessionIds",void 0),(0,n.Z)(this,"anid",""),(0,n.Z)(this,"esf",""),this.apiResponse=e,this.sessionIds=t,this.anid=i||"",this.esf=o||""}getPersonalDataRemover(){return this.personalDataRemover||(this.personalDataRemover=new o.Z(this.getCashbackDao())),this.personalDataRemover}getCashbackLogger(){return this.cashbackLogger||(this.cashbackLogger=new O),this.cashbackLogger}getFragmentCollectionService(){return new class{constructor(e,t,i){(0,n.Z)(this,"cashbackDAO",void 0),(0,n.Z)(this,"cashbackLogger",void 0),(0,n.Z)(this,"personalDataRemover",void 0),(0,n.Z)(this,"DEFAULT_FRAGMENT_COLLECTION_TIMEOUT",2e3),(0,n.Z)(this,"currentUrlMasked",""),(0,n.Z)(this,"DISALLOWED_NAMES",new Set(["addr","city","cell","dob","email","data-gtm","mob","phone","secret","social","ssn","tel","zip","pass","payment","cvv","ccv"])),this.cashbackDAO=e,this.cashbackLogger=t,this.personalDataRemover=i,this.currentUrlMasked=this.getCurrentUrlValue(!0)}getBrokenAttributionCollectionRate(){const e=this.cashbackDAO.getRetailerSettings();if(!e)return 0;const t=this.cashbackDAO.getPageType();return e.GetCollectionRate(this.cashbackDAO.getLastCommittedURL(),t,!0)??0}isNewCollectionFlagEnabled(){return this.cashbackDAO.getFeatureFlagEnabledByDefault("edge.fragmentCollection")}async RunFragmentCollection(e=!1,t="",i){if(!this.isNewCollectionFlagEnabled())return void this.logDebuggMesageToConsole("New fragment collection is not enabled");if(!this.cashbackDAO.getLastCommittedURL()?.startsWith("https:"))return;if(!this.IsCollectionAllowed())return void this.logDebuggMesageToConsole("Collection is not allowed");const n=this.cashbackDAO.getHtmlCollectionRate()||"0",o=void 0!==i?i:parseFloat(n);if(!(0,P.P4)()&&Math.random()>o)return void this.logDebuggMesageToConsole("No collection. Generated number is above rate");const r=this.cashbackDAO.getPageType();if(!e&&!(0,P.Ak)(r))return void this.logDebuggMesageToConsole(`do not collect page of type ${r}`);const a=this.cashbackDAO.getRetailerSettings()?.GetFragmentCollectionTimeout(r)||this.DEFAULT_FRAGMENT_COLLECTION_TIMEOUT;await this.logHtmlFragment(o,r,n,t,a)}IsCollectionAllowed(){if(!this.cashbackDAO.isFragmentCollectionEnabled())return!1;const e=this.cashbackDAO.getAfdMarket();return!!e&&("en-us"!==e||this.isPrivacyBadgeShown())}isPrivacyBadgeShown(){return!!a.Q?.PrivacyBadgeViewCount&&parseInt(a.Q.PrivacyBadgeViewCount,10)>=2}async logHtmlFragment(e,t,i,n,o){this.logDebuggMesageToConsole("log html for pageType",t),await(0,d._R)(o);const r=this.cashbackDAO.getImpressionId(),a=this.getHtmlFragmentTelemetryMetadata(t,i);a.HtmlFragment=this.getHtmlFragment(),a.HtmlFragment?(a.HtmlFragment=btoa(encodeURIComponent(a.HtmlFragment)),this.cashbackLogger.LogColdPathTelemetryEvent(`Fragment collection form NewHtmlFragmentCollectionService;collectionRate:${e}. ${n}`,g.R.HtmlFragment,a,r)):this.logError(`HtmlFragmentTelemetry:::Failed to log fragment. ${n}`,t,"HtmlFragmentTelemetry error",{collectionRate:e,rateFromBackend:i})}logError(e,t,i="",n=void 0){const o=this.cashbackDAO.getSessionIds(),r={Metadata:n?JSON.stringify(n):"",Domain:this.cashbackDAO.getCurrentDomain(),AFDMarket:this.cashbackDAO.getAfdMarket(),IsSignedIn:this.cashbackDAO.isSignedIn(),PageVisitId:o?.pageVisitId??"",RetailerSessionId:o?.retailerSessionId??"",PersonalizationDataConsent:this.cashbackDAO.getSanConsentFlag(),ErrorMessage:i,Message:e,IsError:!0,PageUrl:this.currentUrlMasked,PageType:t??this.cashbackDAO.getPageType(),IsBrokenSelectorDetected:!1,IsPartialBrokenSelectorDetected:!1,BrokenSelectors:"",FullSelectorUsed:"",PartialSelectorUsed:"",Currency:"",ExtractionResult:"",CartData:"",PageRegexUsed:"",ExtractionId:""};this.logDebuggMesageToConsole(r.Message),this.cashbackLogger.LogInfoWithEvenType(e,g.R.SelectorDataExtraction,r,this.cashbackDAO.getImpressionId())}getHtmlFragmentTelemetryMetadata(e,t){const i=this.cashbackDAO.getCurrentDomain(),n=this.cashbackDAO.getSessionIds(),o=n?.retailerSessionId??"",r=n?.pageVisitId??"";return this.logDebuggMesageToConsole("retailerSessionId",o),this.logDebuggMesageToConsole("pageVisitId",r),{Domain:i,TimeToMask:"",PageType:e,PageUrl:this.currentUrlMasked,aOCFragmentCollectionRate:t,HtmlFragment:"",EncryptionKey:"",RetailerSessionId:o,PageVisitId:r}}getCurrentUrlValue(e){return this.personalDataRemover.getCurrentUrlValue(e,this.cashbackDAO.getLastCommittedURL())}getHtmlFragment(){const e=this.cloneNodeWithPlaceholders(document.documentElement,!1,performance.now());return e?.outerHTML??""}cloneNodeWithPlaceholders(e,t,i){if(performance.now()-i>12e4)return this.logError("Execution time exceeded 2 minutes. Aborting.",void 0,"HtmlFragmentTelemetry cloneNodeWithPlaceholders error"),null;if("SCRIPT"===e.tagName?.toLocaleUpperCase())return null;if(e.nodeType===Node.TEXT_NODE){const i=e.cloneNode(!1);return t&&(i.textContent="*****"),i}if(e.nodeType===Node.ELEMENT_NODE){if("hidden"===window.getComputedStyle(e).visibility)return null;const t=e.getAttribute("id");if(t&&t.startsWith("batBeacon"))return null;const n=e.cloneNode(!1);let o=!1;const r=e.getAttributeNames();for(const t of r){if(this.DISALLOWED_NAMES.has(t.toLowerCase())){o=!0;break}for(const i of this.DISALLOWED_NAMES)if(e.getAttribute(t)?.toLowerCase()?.includes(i)){o=!0;break}if(o)break}for(const t of e.childNodes){const e=this.cloneNodeWithPlaceholders(t,o,i);e&&n.appendChild(e)}return n}return null}logDebuggMesageToConsole(...e){}}(this.getCashbackDao(),this.getCashbackLogger(),this.getPersonalDataRemover())}getScrapperService(){return this.scraperService||(this.scraperService=new D),this.scraperService}getPurchaseExtractionService(){return this.cartExtractionService||(this.cartExtractionService=new w(this.getCashbackLogger(),this.getScrapperService(),this.getCashbackDao(),this.getPersonalDataRemover())),this.cartExtractionService}getCashbackDao(){return this.cashbackDAO||(this.cashbackDAO=new class{constructor(e,t,i,o){(0,n.Z)(this,"checkoutPages",void 0),(0,n.Z)(this,"apiResponse",void 0),(0,n.Z)(this,"sessionIds",void 0),(0,n.Z)(this,"settings",void 0),(0,n.Z)(this,"anid",""),(0,n.Z)(this,"esf",""),this.apiResponse=e,this.checkoutPages=this.setCheckoutPages(),this.sessionIds=t,this.anid=i,this.esf=o,this.settings=new c.Z(e?.retailerData?.settings)}getDataMaskRules(){const e=this.apiResponse?.retailerData?.dataMaskRules,t=[];if(e&&e.length>0)for(const i of e)if(i?.ruleName&&i?.ruleValue&&i?.maskType){const e=new u.Z(i?.ruleName,i?.maskType,i?.ruleValue);t.push(e)}return t}getConfirmationPageRegex(){return this.apiResponse?.retailerData?.orderConfirmationPageUrl}getPlatform(){return this.apiResponse?.retailerData?.platform??""}getSanConsentFlag(){return(0,d.Nx)(this.apiResponse?.userInfo?.isPersonalizationDataConsentEnabled)}getCurrentDomain(){return this.apiResponse?.retailerData?.domainName??""}getESF(){return this.esf}isAadSignedIn(){return this.apiResponse?.userInfo?.isAADSignedIn??null}isSignedIn(){return Boolean(this.isAadSignedIn()||this.anid)}getSessionIds(){return this.sessionIds}getRetailerSettings(){return this.settings}getImpressionId(){return this.apiResponse?.impressionId??""}getPersonalizedCashback(){return this.apiResponse?.personalizedAdsResponse?.personalizedCashback}getPageType(){return(0,l.E)(this.getLastCommittedURL(),this.getCurrentDomain(),this.getRetailerData(),this.getConfirmationPageTelemetryData(),this.getAfdMarket())}getAutomatedSelectorsDataForPage(e){return(0,l.IL)(e,this.getAutomatedSelectorsData(),this.getLastCommittedURL())}isCartCachingEnabled(){return this.getConfirmationPageTelemetryData()?.isCartCachingEnabled??!0}getAfdMarket(){return this.apiResponse?.aFDMarket??""}getLastCommittedURL(){return window.location.toString()}getCheckoutPageInfo(){return(0,l.aB)(this.getCheckoutPages(),this.getLastCommittedURL())}getAnid(){return this.anid}getPageInfo(){const e=this.apiResponse?.retailerData?.allCheckoutPages;return(0,l.aB)(e,this.getLastCommittedURL())}getConfirmationPageTelemetryData(){return this.apiResponse?.retailerData?.confirmationPageTelemetry}isFragmentCollectionEnabled(){return(0,d.Nx)(this.apiResponse?.retailerData?.isAOCFragmentCollectionEnabled)}getHtmlCollectionRate(){return this.apiResponse?.retailerData?.aOCFragmentCollectionRate?`${this.apiResponse?.retailerData?.aOCFragmentCollectionRate}`:"0"}getFeatureFlagEnabledByDefault(e){return"feature_disabled"!==this.apiResponse?.retailerData?.edgeFeatureFlag?.[e]}saveToLocalCache(e,t){window.localStorage.setItem(e,t)}saveToLocalCachePersistent(e,t){r.Q.sendControllerStorageMessage(e,t)}readFromLocalCachePersistent(e){try{const t=a.Q?a.Q[e]:void 0;return(t?(0,s.BQ)(t):void 0)||void 0}catch(e){return}}readFromLocalCache(e){try{const t=window.localStorage.getItem(e);if(t)return JSON.parse(t)}catch(e){return}}getAutomatedSelectorsData(){return this.apiResponse?.retailerData?.allAutomatedSelectors??[]}getCheckoutPages(){return this.checkoutPages}getRetailerData(){return this.apiResponse?.retailerData}setCheckoutPages(){const e=this.apiResponse?.retailerData?.allCheckoutPages,t=[];if(e)for(const i of e)"CheckoutPage"!==i.pageType&&i.pageType||t.push(i);return t}}(this.apiResponse,this.sessionIds,this.anid,this.esf)),this.cashbackDAO}static initFactory(e,t,i,n){return this.instance||(this.instance=new _(e,t,i,n)),this.instance}static getFactory(){return this.instance||(this.instance=new _(void 0,void 0,"","")),this.instance}static resetFactory(e,t,i,n){this.instance=new _(e,t,i,n),this.instance.resetFactoriesToNull()}resetFactoriesToNull(){this.personalDataRemover=void 0,this.cashbackDAO=void 0,this.cartExtractionService=void 0,this.cashbackLogger=void 0,this.scraperService=void 0}}(0,n.Z)(_,"instance",void 0);var N=_},60269:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(){(0,n.Z)(this,"retailerData",void 0),(0,n.Z)(this,"impressionId",void 0),(0,n.Z)(this,"coupons",void 0),(0,n.Z)(this,"suppressedCoupons",void 0),(0,n.Z)(this,"market",void 0),(0,n.Z)(this,"userPersonalizationInfo",void 0),(0,n.Z)(this,"cashback",void 0),(0,n.Z)(this,"isCashbackEstimationSupportedForDomain",void 0),(0,n.Z)(this,"userInfo",void 0)}}},29853:function(e,t,i){"use strict";i.d(t,{Z:function(){return y}});var n=i(72370),o=i(69886),r=i(99182),a=i(6747);class s{constructor(){(0,n.Z)(this,"cartSelector",void 0),(0,n.Z)(this,"collapsedCartProductImageSelector",void 0),(0,n.Z)(this,"productSelector",void 0),(0,n.Z)(this,"productTitleSelector",void 0),(0,n.Z)(this,"productPriceSelector",void 0),(0,n.Z)(this,"productImageSelector",void 0),(0,n.Z)(this,"productUrlSelector",void 0),(0,n.Z)(this,"productQuantitySelector",void 0),(0,n.Z)(this,"productSellerSelector",void 0),(0,n.Z)(this,"productSellerRegex",void 0),(0,n.Z)(this,"productIdSkuSelector",void 0),(0,n.Z)(this,"productIdSkuRegex",void 0),(0,n.Z)(this,"productIdSkuAttribute",void 0),(0,n.Z)(this,"productPriceRegex",void 0),(0,n.Z)(this,"emptyCartText",void 0)}static Create(e){const t=new s;return t.cartSelector=e.cartSelector,t.collapsedCartProductImageSelector=e.collapsedCartProductImageSelector,t.productSelector=e.productSelector,t.productTitleSelector=e.productTitleSelector,t.productPriceSelector=e.productPriceSelector,t.productImageSelector=e.productImageSelector,t.productUrlSelector=e.productUrlSelector,t.productQuantitySelector=e.productQuantitySelector,t.productSellerSelector=e.productSellerSelector,t.productSellerRegex=e.productSellerRegex,t.productIdSkuSelector=e.productIdSkuSelector,t.productIdSkuRegex=e.productIdSkuRegex,t.productIdSkuAttribute=e.productIdSkuAttribute,t.productPriceRegex=e.productPriceRegex,t.emptyCartText=e.emptyCartText,t}}var l=s;class c{constructor(){(0,n.Z)(this,"productTitleSelector",void 0),(0,n.Z)(this,"productSellerSelector",void 0),(0,n.Z)(this,"productBrandSelector",void 0),(0,n.Z)(this,"productImageSelector",void 0),(0,n.Z)(this,"productOutOfStockSelector",void 0),(0,n.Z)(this,"productPriceSelector",void 0),(0,n.Z)(this,"productASIN",void 0),(0,n.Z)(this,"productUPCSelector",void 0),(0,n.Z)(this,"aggregateRatingSelector",void 0),(0,n.Z)(this,"aggregateRatingNumberOfRatingsSelector",void 0),(0,n.Z)(this,"reviewSelector",void 0),(0,n.Z)(this,"reviewRatingSelector",void 0),(0,n.Z)(this,"reviewDateSelector",void 0),(0,n.Z)(this,"reviewerNameSelector",void 0)}static Create(e){const t=new c;return t.productTitleSelector=e.productTitleSelector,t.productSellerSelector=e.productSellerSelector,t.aggregateRatingSelector=e.aggregateRatingSelector,t.aggregateRatingNumberOfRatingsSelector=e.aggregateRatingNumberOfRatingsSelector,t.reviewSelector=e.reviewSelector,t.reviewRatingSelector=e.reviewRatingSelector,t.reviewDateSelector=e.reviewDateSelector,t.reviewerNameSelector=e.reviewerNameSelector,t.productImageSelector=e.productImageSelector,t.productPriceSelector=e.productPriceSelector,t.productOutOfStockSelector=e.productOutOfStockSelector,t.productBrandSelector=e.productBrandSelector,t.productASIN=e.productASIN,t.productUPCSelector=e.productUPCSelector,t}}var d=c;class u{constructor(){(0,n.Z)(this,"otherSellersOverlayLinkSelector",void 0),(0,n.Z)(this,"otherSellerOfferElementSelector",void 0),(0,n.Z)(this,"otherSellerHeadingSelector",void 0),(0,n.Z)(this,"otherSellerPriceSelector",void 0),(0,n.Z)(this,"otherSellerNameSelector",void 0),(0,n.Z)(this,"productImageSelector",void 0),(0,n.Z)(this,"otherSellerRatingSelector",void 0),(0,n.Z)(this,"otherSellerDeliverySelector",void 0),(0,n.Z)(this,"otherSellerAddButtonSelector",void 0),(0,n.Z)(this,"otherSellerAddedConfirmationSelector",void 0),(0,n.Z)(this,"otherSellerLowestPriceSelector",void 0),(0,n.Z)(this,"jSVersionThreshold",void 0)}static Create(e){const t=new u;return t.otherSellersOverlayLinkSelector=e.otherSellersOverlayLinkSelector,t.otherSellerOfferElementSelector=e.otherSellerOfferElementSelector,t.otherSellerHeadingSelector=e.otherSellerHeadingSelector,t.otherSellerPriceSelector=e.otherSellerPriceSelector,t.otherSellerNameSelector=e.otherSellerNameSelector,t.productImageSelector=e.productImageSelector,t.otherSellerRatingSelector=e.otherSellerRatingSelector,t.otherSellerDeliverySelector=e.otherSellerDeliverySelector,t.otherSellerAddButtonSelector=e.otherSellerAddButtonSelector,t.otherSellerAddedConfirmationSelector=e.otherSellerAddedConfirmationSelector,t.otherSellerLowestPriceSelector=e.otherSellerLowestPriceSelector,t.jSVersionThreshold=e.jSVersionThreshold,t}}var h=u;class p{constructor(){(0,n.Z)(this,"checkoutPageUrl",void 0),(0,n.Z)(this,"priceSelector",void 0),(0,n.Z)(this,"startDateSelector",void 0),(0,n.Z)(this,"endDateSelector",void 0),(0,n.Z)(this,"domainType",void 0),(0,n.Z)(this,"nameSelector",void 0),(0,n.Z)(this,"isRoundTripSelector",void 0)}static Create(e){const t=new p;return t.checkoutPageUrl=e.checkoutPageUrl,t.priceSelector=e.priceSelector,t.startDateSelector=e.startDateSelector,t.endDateSelector=e.endDateSelector,t.nameSelector=e.nameSelector,t.domainType=e.domainType,t.isRoundTripSelector=e.isRoundTripSelector,t}}var g=p;class f{constructor(){(0,n.Z)(this,"pageUrlMatchRegex",void 0),(0,n.Z)(this,"flightPriceSelector",void 0),(0,n.Z)(this,"returnFlightPriceSelector",void 0),(0,n.Z)(this,"startDateSelector",void 0),(0,n.Z)(this,"endDateSelector",void 0),(0,n.Z)(this,"domainType",void 0),(0,n.Z)(this,"sourceLocationSelector",void 0),(0,n.Z)(this,"destinationLocationSelector",void 0),(0,n.Z)(this,"isRoundTripSelector",void 0)}static Create(e){const t=new f;return t.pageUrlMatchRegex=e.pageUrlMatchRegex,t.flightPriceSelector=e.flightPriceSelector,t.returnFlightPriceSelector=e.returnFlightPriceSelector,t.startDateSelector=e.startDateSelector,t.endDateSelector=e.endDateSelector,t.domainType=e.domainType,t.sourceLocationSelector=e.sourceLocationSelector,t.destinationLocationSelector=e.destinationLocationSelector,t.isRoundTripSelector=e.isRoundTripSelector,t}}var m=f;class v{constructor(){(0,n.Z)(this,"inputBoxSelector",void 0),(0,n.Z)(this,"applyButtonSelector",void 0),(0,n.Z)(this,"removeCouponButtonSelector",void 0),(0,n.Z)(this,"orderTotalDataElementSelector",void 0),(0,n.Z)(this,"orderTotalDataContainerElementSelector",void 0),(0,n.Z)(this,"orderSubTotalElementSelector",void 0),(0,n.Z)(this,"disabled",void 0),(0,n.Z)(this,"checkoutPageUrl",void 0),(0,n.Z)(this,"layoutClickSelector",void 0),(0,n.Z)(this,"clickBeforeStartSelector",void 0),(0,n.Z)(this,"finalCheckoutButtonSelector",void 0),(0,n.Z)(this,"edgeEnabled",void 0),(0,n.Z)(this,"couponAcceptedMessageElementSelector",void 0),(0,n.Z)(this,"closeModal",void 0),(0,n.Z)(this,"appliedCouponSelector",void 0),(0,n.Z)(this,"errorMessageSelector",void 0),(0,n.Z)(this,"couponSuccessMessageSelectors",void 0),(0,n.Z)(this,"couponFailureMessageSelectors",void 0),(0,n.Z)(this,"enabledTips",void 0),(0,n.Z)(this,"otherSellerSelectors",void 0),(0,n.Z)(this,"clippingSelectors",void 0),(0,n.Z)(this,"cartSelectors",void 0),(0,n.Z)(this,"catalogSelectors",void 0),(0,n.Z)(this,"clickForCartSelector",void 0),(0,n.Z)(this,"socialSelectors",void 0),(0,n.Z)(this,"pinterestSelectors",void 0),(0,n.Z)(this,"automatedCartExtractionEnabled",void 0),(0,n.Z)(this,"shipmentSelector",void 0),(0,n.Z)(this,"preTaxSelector",void 0),(0,n.Z)(this,"estimatedTaxSelector",void 0),(0,n.Z)(this,"waitAfterApplyingCurrentCoupon",void 0),(0,n.Z)(this,"manualCouponApplyTrackingEnabled",void 0),(0,n.Z)(this,"autosDataSelector",void 0),(0,n.Z)(this,"suggestedCouponElementSelector",void 0),(0,n.Z)(this,"suggestedCouponRegex",void 0),(0,n.Z)(this,"suggestedCouponsOnlyPage",void 0),(0,n.Z)(this,"supportedNoOrderTotal",void 0),(0,n.Z)(this,"domMutationEnabled",void 0),(0,n.Z)(this,"pageType",void 0),(0,n.Z)(this,"automaticCouponSavingsSelector",void 0),(0,n.Z)(this,"travelCheckoutSelectors",void 0),(0,n.Z)(this,"isAutoShowDisabled",void 0),(0,n.Z)(this,"productAddToCartSelector",void 0),(0,n.Z)(this,"buyNowSelector",void 0),(0,n.Z)(this,"pageUrlRegex",void 0),(0,n.Z)(this,"pageTypeSelector",void 0),(0,n.Z)(this,"addToCartOverlaySelector",void 0),(0,n.Z)(this,"getProductNamesFromImg",void 0),(0,n.Z)(this,"productTitleSearchSelector",void 0),(0,n.Z)(this,"travelSearchSelectors",void 0),(0,n.Z)(this,"isHomePageSameAsCheckout",void 0),(0,n.Z)(this,"priceDivideByQuantity",void 0)}static Create(e){const t=new v;return t.inputBoxSelector=e.inputBoxSelector,t.removeCouponButtonSelector=e.removeCouponButtonSelector,t.orderTotalDataElementSelector=e.orderTotalDataElementSelector,t.orderTotalDataContainerElementSelector=e.orderTotalDataContainerElementSelector,t.checkoutPageUrl=e.checkoutPageUrl,t.clickBeforeStartSelector=e.clickBeforeStartSelector,t.clickForCartSelector=e.clickForCartSelector,t.layoutClickSelector=e.layoutClickSelector,t.finalCheckoutButtonSelector=e.finalCheckoutButtonSelector,t.disabled=e.disabled,t.edgeEnabled=e.edgeEnabled,t.orderSubTotalElementSelector=e.orderSubTotalElementSelector,t.couponAcceptedMessageElementSelector=e.couponAcceptedMessageElementSelector,t.closeModal=e.closeModal,t.appliedCouponSelector=e.appliedCouponSelector,t.errorMessageSelector=e.errorMessageSelector,t.couponSuccessMessageSelectors=e.couponSuccessMessageSelectors,t.couponFailureMessageSelectors=e.couponFailureMessageSelectors,t.enabledTips=e.enabledTips,t.automatedCartExtractionEnabled=e.automatedCartExtractionEnabled,t.shipmentSelector=e.shipmentSelector,t.preTaxSelector=e.preTaxSelector,t.priceDivideByQuantity=e.priceDivideByQuantity,t.estimatedTaxSelector=e.estimatedTaxSelector,t.applyButtonSelector=e.applyButtonSelector,t.waitAfterApplyingCurrentCoupon=e.waitAfterApplyingCurrentCoupon,t.manualCouponApplyTrackingEnabled=e.manualCouponApplyTrackingEnabled,t.autosDataSelector=e.autosDataSelector,t.suggestedCouponElementSelector=e.suggestedCouponElementSelector,t.suggestedCouponRegex=e.suggestedCouponRegex,t.suggestedCouponsOnlyPage=e.suggestedCouponsOnlyPage,t.supportedNoOrderTotal=e.supportedNoOrderTotal,t.domMutationEnabled=e.domMutationEnabled,t.pageType=e.pageType,t.automaticCouponSavingsSelector=e.automaticCouponSavingsSelector,t.isAutoShowDisabled=e.isAutoShowDisabled,t.productAddToCartSelector=e.productAddToCartSelector,t.buyNowSelector=e.buyNowSelector,t.pageTypeSelector=e.pageTypeSelector,t.pageUrlRegex=e.pageUrlRegex,t.addToCartOverlaySelector=e.addToCartOverlaySelector,t.productTitleSearchSelector=e.productTitleSearchSelector,t.getProductNamesFromImg=e.getProductNamesFromImg,t.isHomePageSameAsCheckout=e.isHomePageSameAsCheckout,e.otherSellerSelectors&&(t.otherSellerSelectors=h.Create(e.otherSellerSelectors)),e.clippingSelectors&&(t.clippingSelectors=o.Z.Create(e.clippingSelectors)),e.cartSelectors&&(t.cartSelectors=l.Create(e.cartSelectors)),e.catalogSelectors&&(t.catalogSelectors=d.Create(e.catalogSelectors)),e.socialSelectors&&(t.socialSelectors=a.Z.Create(e.socialSelectors)),e.pinterestSelectors&&(t.pinterestSelectors=r.Z.Create(e.pinterestSelectors)),e.travelCheckoutSelectors&&(t.travelCheckoutSelectors=g.Create(e.travelCheckoutSelectors)),e.travelSearchSelectors&&(t.travelSearchSelectors=m.Create(e.travelSearchSelectors)),t}}var y=v},77594:function(e,t,i){"use strict";i.d(t,{p:function(){return u}});var n=i(72370),o=i(31656),r=i(21597),a=i(89366),s=i(86743),l=i(3274),c=i(52056);class d extends a.Z{constructor(...e){super(...e),(0,n.Z)(this,"initializeStartTime",performance.now()),(0,n.Z)(this,"scriptRunNum",0),(0,n.Z)(this,"apiResponseParam",[])}initializeRuntime(e){0!==this.scriptRunNum&&(this.initializeStartTime=performance.now()),this.apiResponseParam=e}handleMessages(e,t){let i,n;this.apiResponseParam&&(this.apiResponseParam.length>r.$R.enabled_features&&(i=this.apiResponseParam[r.$R.enabled_features]),n=this.GetEnabledServiceFeatures()),o.R.Create(i,n);const a=(0,s.XB)();c.Z.SetFullAOCActive(a),a&&"OnGenericDealsServiceResponse"!==t&&"WebAssistQueryResults"!==t||(this.scriptRunNum=(0,l.U)(e,t,this.scriptRunNum,this.initializeStartTime))}getNativeHandler(){return checkoutPageValidatorNativeHandler}GetEnabledServiceFeatures(){let e;return this.apiResponseParam.length>r.$R.enabled_service_features&&this.apiResponseParam[r.$R.enabled_service_features].length>0?e=this.apiResponseParam[r.$R.enabled_service_features]:this.apiResponseParam.length>r.$R.checkout_enabled_service_features_v2&&this.apiResponseParam[r.$R.checkout_enabled_service_features_v2].length>0&&(e=this.apiResponseParam[r.$R.checkout_enabled_service_features_v2]),e}}const u=new d},46261:function(e,t,i){"use strict";i.d(t,{GA:function(){return a},LE:function(){return r},Wi:function(){return o}});var n=i(72370);const o="CheckoutStatus",r=18e4;class a{constructor(){(0,n.Z)(this,"CheckoutTime",void 0),(0,n.Z)(this,"CheckoutButtonClicked",void 0),(0,n.Z)(this,"CartId",void 0),(0,n.Z)(this,"CartValue",void 0)}}},1094:function(e,t,i){"use strict";i.d(t,{Z:function(){return w}});var n=i(66933),o=i(21488),r=i(29247),a=i(36493),s=i(91495),l=i(44092),c=i(27689),d=i(9448),u=i(90066),h=i(82315),p=i(72370),g=i(5144),f=i(56372),m=i(52056);class v extends f.Z{constructor(...e){super(...e),(0,p.Z)(this,"traceId",void 0)}init(e,t,i,n){this.initCommonInfo(e,t,i,g.G7.Validator),this.traceId=n,this.sendErrorMessage=this.sendValidatorErrorMessage.bind(this),this.sendStorageMessage=m.Z.SendStorageMessage.bind(this),this.initialize()}initialize(){this.autoOpenDataStr=s.Q?.AutoOpenData,this.lastCleanedDataStr=s.Q?.LastCleanedData,this.initializeData()}sendValidatorErrorMessage(e,t){try{const i="error";m.Z.SendLogEvent(e,t,i,void 0,void 0,void 0),m.Z.SendMessage(d.H.CheckoutPageValidationError,[i,this.traceId])}catch(e){}}}var y=v,C=i(60269),b=i(44922),S=i(46557),x=i(11849);class T{static CreateCheckoutPageData(e){if(e){const t=new C.Z;if(e.retailerData&&(t.retailerData=S.Z.Create(e.retailerData)),e.impressionId&&(t.impressionId=e.impressionId),e.coupons){t.coupons=[];for(const i of e.coupons)t.coupons.push(i)}if(e.suppressedCoupons){t.suppressedCoupons=[];for(const i of e.suppressedCoupons)t.suppressedCoupons.push(i)}return e.userPersonalizationInfo&&(t.userPersonalizationInfo=e.userPersonalizationInfo),e.market&&(t.market=e.market),e.cashback&&(t.cashback=n.Z.Create(e.cashback)),e.userInfo&&(t.userInfo=o.Z.Create(e)),t.isCashbackEstimationSupportedForDomain=e.isCashbackEstimationSupportedForDomain,t}return new C.Z}static GetInitialFields(e){const t=[],i=e.retailerData.getCurrentCheckoutPage();return i&&[i.inputBoxSelector,i.removeCouponButtonSelector,i.clickBeforeStartSelector,i.layoutClickSelector].forEach((e=>{r.ZP.IsValidDataField(e)&&t.push(e)})),t}static GetAndSendOrderTotal(e,t,i){let n=!1,o=!1;i!==b.S.NoCheckoutPageUrl&&i!==b.S.DisabledCheckoutPageData||(n=!0),i!==b.S.NoSelectors&&i!==b.S.PageIsInvalid&&i!==b.S.IsPageValidError||(o=!0);const r=this.getDefaultOrderTotalErrorMessage(i),a=h.Z.getApiResponse(),s=a.retailerData?.domainName;try{const i=a.retailerData.getCurrentCheckoutPage();this.GetOrderTotal(i,e,a.impressionId,s).then((e=>{this.SendValidationLog(t,a.impressionId,a.traceId,n,o,s,e.OrderTotal,e.Currency),e.OrderTotal>0&&((0,l.i8)("orderTotal",e.OrderTotal.toString()),(0,l.i8)("pageCurrency",e.PageCurrency.toString()))}))}catch(e){m.Z.SendLogEvent(a.impressionId,e?.message??r,"error")}}static GetCurrentPathName(){return location.pathname}static async isCheckoutPageBySelectors(e,t){const i=e.retailerData.getCurrentCheckoutPage(),n=location.pathname;if(!i||i.checkoutPageUrl!==n)return!1;const o=T.GetInitialFields(e);return 0!==o.length&&await(0,r.w)((()=>t.IsPageValid(o)),5e3).then((async e=>e)).catch((i=>(t.sendErrorMessage(e.impressionId,i?.message??"checkoutpage selectors check error."),!1)))}static SendValidationLog(e,t,i,n,o,r,a,s){const l=m.Z.GetValidationLogMessage(e,n,o);e?a&&-1!==a&&m.Z.SendLogEvent(t,l,"true",a,s,void 0,void 0,r):m.Z.SendLogEvent(t,l,"false",a,s,void 0,void 0,r),a&&-1!==a&&this.SendGMVMessage(a,s??"$",i)}static SendGMVMessage(e,t,i){const n=(0,a.qm)(t)?t:(0,a.Vv)(t)??"USD";m.Z.SendMessage(d.H.CheckoutPageGMV,[i,e.toString(),n])}static async GetOrderTotal(e,t,i,n){let o={OrderTotal:-1,Currency:(0,a.N6)(t)??"$",PageCurrency:""};e&&r.ZP.IsValidDataField(e.orderTotalDataElementSelector)&&(o=await r.ZP.WaitForCondition((async()=>u.Z.HasVisibleElement(e.orderTotalDataElementSelector)),5e3).then((()=>x.Z.GetCartValue(e.orderTotalDataElementSelector,t))).catch((e=>(m.Z.SendLogEvent(i,e?.message??"checkoutpage GMV error.","error"),o))));try{const e=s.Q?.CartValues,t=(0,c.BQ)(e,!0)??{},i=new Date;t[n]={cartValue:o,timestamp:i};const r=JSON.stringify({value:JSON.stringify(t)});m.Z.SendStorageMessage("CartValues",r)}catch(e){}return o}static GetValidatorAutoOpenController(){const e=h.Z.getApiResponse(),t=location.pathname,i=new y;return i.init(e.impressionId,e?.retailerData?.domainName,t,e.traceId),i}static getDefaultOrderTotalErrorMessage(e){switch(e){case b.S.DisabledCheckoutPageData:return"disabled checkoutpage GMV error.";case b.S.NoSelectors:return"no valid initial fields to check";case b.S.NoCoupons:return"no coupons";case b.S.AllCouponsBlocked:return"all coupons were blocked";case b.S.NoCheckoutPageUrl:return"no checkoutpage data GMV error."}return"checkoutpage GMV error."}}var w=T},50607:function(e,t,i){"use strict";i.d(t,{$d:function(){return u},LT:function(){return g},WL:function(){return d},cA:function(){return p},iQ:function(){return f},jV:function(){return m},mg:function(){return h}});var n=i(59645),o=i(5144),r=i(11050),a=i(91495),s=i(75434),l=i(41310),c=i(52056);const d=e=>!!e&&!!e.shouldAutoShow&&e.offersType===r.h.SPB&&!!(e.offer||e.relatedOffers&&0!==e.relatedOffers.length),u=(e,t,i)=>{if(e&&e.relatedOffers){const n=v(t),o=new Set([...i,...n]),r=e.relatedOffers.filter((e=>{if(e.cashbackProducts&&e.cashbackProducts.length>0){const t=e.cashbackProducts[0];if(e.value&&t.price&&t.image&&!o.has(e.id))return!0}return!1}));if(r.length>0)return r[0]}return null},h=(e,t,i,n,o)=>{if(!0===o)return!1;if(!e)return!1;if(!e.shouldAutoShow)return!1;if(e.offersType!==r.h.Quotient)return!1;if(!(e.offer||e.relatedOffers&&0!==e.relatedOffers.length))return!1;if(a.Q.ICIsPendingTransactionPresent)return!1;const s=new Set([...n,...v(t)]),l=new Set(i);let c=!1;return e.offer?.id&&(c=!s.has(e.offer.id)&&!l.has(e.offer.id)&&0!==e.offer.cashbackProducts.length),!!c},p=(e,t,i,r=!1)=>{const a=new n.Z(o.xu.ICSpbOffersNoShowHomePage);a.Metadata=JSON.stringify({userInfo:e,isError:r,pageTitle:document?.title,reason:i}),c.Z.SendLogEvent(t,"SPB notification not shown on home page","",void 0,void 0,o.R.EdgeFlyoutStatus,a)},g=(e,t,i,a,s=!1)=>{const l=e?.offersType===r.h.SPB,d=new n.Z(l?o.xu.ICSPBPdpOffersNoShow:o.xu.ICQtPdpOffersNoShow),u=`${e?.offersType} offer not shown`;d.Metadata=JSON.stringify({userInfo:t,responseData:e,isExactMatch:!!e?.offer,relatedOffersLength:e?.relatedOffers?.length||0,isPdpSpb:l,isPdpQt:e?.offersType===r.h.Quotient,isError:s,pageTitle:document?.title}),c.Z.SendLogEvent(i,u,"",void 0,void 0,o.R.EdgeFlyoutStatus,d)},f=(e,t,i)=>{const n={isExactMatch:!!e.offer,relatedOffersLength:e.relatedOffers?.length||0,isPdpSpb:!0,pageTitle:document?.title};l.Z.LogSPBTelemetry(o.xu.ICQtPdpOffersShow,"Qt pdp shown",e,t,i,n)},m=(e,t,i)=>{const n={isExactMatch:!!e.offer,relatedOffersLength:e.relatedOffers?.length||0,isPdpSpb:!0,pageTitle:document?.title};l.Z.LogSPBTelemetry(o.xu.ICSPBPdpOffersShow,"Spb pdp shown",e,t,i,n)},v=e=>{try{const t=a.Q?.GroceryCashbackActivated,i=((0,s.rm)(t)??{})[e]??void 0;return i?.fullItems?Object.keys(i.fullItems):[]}catch(e){return[]}}},44922:function(e,t,i){"use strict";i.d(t,{S:function(){return o}});var n=i(72370);let o=function(e){return e.ClippingGrocery="ClippingGrocery",e.GroceryNoClipping="GroceryNoClipping",e.Clipping="Clipping",e.SaveSocialCoupons="SaveSocialCoupons",e.GroceryCashback="GroceryCashback",e.Grocery="Grocery",e.OtherSellers="OtherSellers",e.NoRetailerData="NoRetailerData",e.FailUpdateCheckoutPage="FailUpdateCheckoutPage",e.NoCheckoutPageUrl="NoCheckoutPageUrl",e.NoPDPPage="NoPDPPage",e.NotGiftCard="NotGiftCard",e.NotGroceries="NotGroceries",e.PageIsValid="PageIsValid",e.PageIsInvalid="PageIsInvalid",e.IsPageValidError="IsPageValidError",e.NoPinterestDeals="NoPinterestDeals",e.PinterestDeals="PinterestDeals",e.NoSocialCoupons="NoSocialCoupons",e.NoSelectors="NoSelectors",e.FallbackValidation="FallbackValidation",e.FallbackError="FallbackError",e.NoCoupons="NoCoupons",e.AllCouponsBlocked="AllCouponsBlocked",e.PageBecameValid="PageBecameValid",e.CheckingOtherSellers="CheckingOtherSellers",e.AutosMarketplace="AutosMarketplace",e.TrendingDealsChina="TrendingDealsChina",e.SuggestedCouponsOnlyPage="SuggestedCouponsOnlyPage",e.AbandonedCart="AbandonedCart",e.ProductTracking="ProductTracking",e.AutoOpenControllerActive="AutoOpenControllerActive",e.DisabledCheckoutPageData="DisabledCheckoutPageData",e.AAConsent="AAConsent",e.EndofScript_ProductPage="EndofScript_ProductPage",e.EndofScript_CheckoutPage="EndofScript_CheckoutPage",e.EndofScript_HomePage="EndofScript_HomePage",e.EndofScript_SearchPage="EndofScript_SearchPage",e.SponsoredPromotions="SponsoredPromotions",e.EnablePersonalization="EnablePersonalization",e.InvalidCartTotal="InvalidCartTotal",e}({});t.Z=class{constructor(){(0,n.Z)(this,"domain",void 0),(0,n.Z)(this,"validationReason",void 0),(0,n.Z)(this,"time",void 0),(0,n.Z)(this,"initializeTime",void 0),(0,n.Z)(this,"preValidationTime",void 0),(0,n.Z)(this,"path",void 0),(0,n.Z)(this,"pageStatus",void 0),(0,n.Z)(this,"scriptRunNum",void 0),(0,n.Z)(this,"validationMsgNum",void 0)}}},34802:function(e,t,i){"use strict";var n=i(72370);class o{constructor(){(0,n.Z)(this,"domain",void 0),(0,n.Z)(this,"pageType",void 0),(0,n.Z)(this,"pageUrl",void 0),(0,n.Z)(this,"orderId",void 0),(0,n.Z)(this,"orderIdFromUrl",void 0),(0,n.Z)(this,"orderTotal",void 0),(0,n.Z)(this,"orderSubtotal",void 0),(0,n.Z)(this,"productName",void 0),(0,n.Z)(this,"productItemPrice",void 0),(0,n.Z)(this,"productTotalPrice",void 0),(0,n.Z)(this,"productQuantity",void 0),(0,n.Z)(this,"productId",void 0),(0,n.Z)(this,"currency",void 0),(0,n.Z)(this,"productPrice",void 0),(0,n.Z)(this,"productNameFromImg",void 0),(0,n.Z)(this,"randomId",void 0),(0,n.Z)(this,"pageUrlFields",void 0)}static Create(e){const t=new o;return t.domain=e.domain,t.pageType=e.pageType,t.pageUrl=e.pageUrl,t.currency=e.currency,t.orderId=e.orderId,t.orderIdFromUrl=e.orderIdFromUrl,t.orderSubtotal=e.orderSubtotal,t.orderTotal=e.orderTotal,t.productName=e.productName,t.productItemPrice=e.productItemPrice,t.productTotalPrice=e.productTotalPrice,t.productQuantity=e.productQuantity,t.productId=e.productId,t.productPrice=e.productPrice,t.productNameFromImg=e.productNameFromImg,t.randomId=e.randomId,t}}t.Z=o},50978:function(e,t,i){"use strict";i.d(t,{JR:function(){return r},Vj:function(){return o}});var n=i(72370);const o="PersonalizedPromotionsRawData";class r{constructor(){(0,n.Z)(this,"Domain",void 0),(0,n.Z)(this,"PageType",void 0),(0,n.Z)(this,"PageUrl",void 0),(0,n.Z)(this,"OrderId",void 0),(0,n.Z)(this,"OrderIdFromUrl",void 0),(0,n.Z)(this,"OrderTotal",void 0),(0,n.Z)(this,"OrderSubtotal",void 0),(0,n.Z)(this,"ProductName",void 0),(0,n.Z)(this,"ProductItemPrice",void 0),(0,n.Z)(this,"ProductTotalPrice",void 0),(0,n.Z)(this,"ProductPrice",void 0),(0,n.Z)(this,"ProductNameFromImg",void 0),(0,n.Z)(this,"RandomId",void 0),(0,n.Z)(this,"ProductQuantity",void 0),(0,n.Z)(this,"ProductId",void 0),(0,n.Z)(this,"Currency",void 0),(0,n.Z)(this,"ExtractionId",void 0),(0,n.Z)(this,"CartDataCreationTime",void 0)}}},14440:function(e,t,i){"use strict";var n=i(72370);class o{static Create(e){const t=new o;return t.productTitle=e.productTitle??"",t.productPrice=e.productPrice??0,t.productUrl=e.productUrl??"",t.productImg=e.productImg??"",t.productQuantity=e.productQuantity??0,t.productSeller=e.productSeller??"",t.buyNowItem=e.buyNowItem,t.productBrand=e.productBrand??"",t}constructor(){(0,n.Z)(this,"productTitle",void 0),(0,n.Z)(this,"productPrice",void 0),(0,n.Z)(this,"productUrl",void 0),(0,n.Z)(this,"productImg",void 0),(0,n.Z)(this,"productQuantity",void 0),(0,n.Z)(this,"productSeller",void 0),(0,n.Z)(this,"foundInWebAssist",void 0),(0,n.Z)(this,"webAssistTitle",void 0),(0,n.Z)(this,"webAssistPrice",void 0),(0,n.Z)(this,"webAssistImg",void 0),(0,n.Z)(this,"buyNowItem",void 0),(0,n.Z)(this,"productBrand",void 0),this.foundInWebAssist=!1}}t.Z=o},90650:function(e,t,i){"use strict";i.d(t,{lD:function(){return n},si:function(){return o}});const n=["confirmation number","confirmation email","thank you for your order","order placed","order was placed","track your order"],o=["cvv"];t.ZP=class{static PageIncludesPaymentKeyWords(e,t){if(e)for(const i of t)if(e.includes(i))return!0;return!1}}},87869:function(e,t,i){"use strict";i.d(t,{L:function(){return r},c:function(){return o}});var n=i(72370);let o=function(e){return e.finalCheckoutButtonVisible="finalCheckoutButtonVisible",e.successfulPaymentKeywordsFound="successfulPaymentKeywordsFound",e.failurePaymentKeywordsFound="failurePaymentKeywordsFound",e.inputFieldsFound="inputFieldsFound",e}({});class r{constructor(){(0,n.Z)(this,"purchaseFailed",void 0),(0,n.Z)(this,"indicators",void 0)}}},46557:function(e,t,i){"use strict";i.d(t,{Z:function(){return f}});var n=i(72370);class o{constructor(){(0,n.Z)(this,"hasLink",void 0),(0,n.Z)(this,"couponCodeElement",void 0),(0,n.Z)(this,"couponCodeHash",void 0),(0,n.Z)(this,"retailerElement",void 0),(0,n.Z)(this,"retailerHash",void 0),(0,n.Z)(this,"channelId",void 0),(0,n.Z)(this,"username",void 0)}static Create(e){const t=new o;return t.hasLink=e.hasLink,t.couponCodeElement=e.couponCodeElement,t.couponCodeHash=e.couponCodeHash,t.retailerElement=e.retailerElement,t.retailerHash=e.retailerHash,t.channelId=e.channelId,t.username=e.username,t}}var r=o,a=i(29247),s=i(56577),l=i(29853);class c{constructor(){(0,n.Z)(this,"productPageUrl",void 0),(0,n.Z)(this,"addToCartButtonSelector",void 0),(0,n.Z)(this,"backgroundAAEnabled",void 0),(0,n.Z)(this,"productAddedConfirmationSelector",void 0),(0,n.Z)(this,"addToCartButtonContainer",void 0),(0,n.Z)(this,"suggestedCouponElementSelector",void 0),(0,n.Z)(this,"suggestedCouponRegex",void 0)}static Create(e){const t=new c;return t.productPageUrl=e.productPageUrl,t.addToCartButtonSelector=e.addToCartButtonSelector,t.backgroundAAEnabled=e.backgroundAAEnabled,t.productAddedConfirmationSelector=e.productAddedConfirmationSelector,t.addToCartButtonContainer=e.addToCartButtonContainer,t.suggestedCouponElementSelector=e.suggestedCouponElementSelector,t.suggestedCouponRegex=e.suggestedCouponRegex,t}}var d=c,u=i(5144),h=i(4872),p=i(31656);class g{constructor(){(0,n.Z)(this,"platform",void 0),(0,n.Z)(this,"domainName",void 0),(0,n.Z)(this,"orderConfirmationPageUrl",void 0),(0,n.Z)(this,"searchQueryUrlRegex",void 0),(0,n.Z)(this,"allCheckoutPages",void 0),(0,n.Z)(this,"isTravelDomain",void 0),(0,n.Z)(this,"allFinalCheckoutPages",void 0),(0,n.Z)(this,"checkoutPageKey",void 0),(0,n.Z)(this,"finalCheckoutPageKey",void 0),(0,n.Z)(this,"productPageKey",void 0),(0,n.Z)(this,"exclusiveMarket",void 0),(0,n.Z)(this,"multiMsgValidationEnabled",void 0),(0,n.Z)(this,"youtubeTemplates",void 0),(0,n.Z)(this,"allProductPages",void 0),(0,n.Z)(this,"exactCheckoutPageUrl",void 0),(0,n.Z)(this,"productOutOfStockSelector",void 0),(0,n.Z)(this,"productNameSelector",void 0),(0,n.Z)(this,"productPriceSelector",void 0),(0,n.Z)(this,"productPageUrl",void 0),(0,n.Z)(this,"productImageSelector",void 0),(0,n.Z)(this,"aaConsentEnabled",void 0),(0,n.Z)(this,"isStorewideCashbackEstimationEnabled",void 0),(0,n.Z)(this,"storeCartInEdgeStorage",void 0),(0,n.Z)(this,"cartMonitorUrl",void 0),(0,n.Z)(this,"travelCheckoutPageKey",void 0),(0,n.Z)(this,"checkoutPageUrl",void 0),(0,n.Z)(this,"confirmationPageTelemetry",void 0),(0,n.Z)(this,"isAOCFragmentCollectionEnabled",void 0),(0,n.Z)(this,"aOCFragmentCollectionRate",void 0),(0,n.Z)(this,"addressBarExpansionEnabled",void 0),(0,n.Z)(this,"retailerTrivia",void 0),(0,n.Z)(this,"disabledPopupOriginationList",void 0),(0,n.Z)(this,"allAutomatedSelectors",void 0),(0,n.Z)(this,"automatedSelectorsKey",void 0),(0,n.Z)(this,"isAddressBarCashbackEnabled",void 0),(0,n.Z)(this,"isCompositeNotificationPhCExcludedRetailer",void 0),(0,n.Z)(this,"isCompositeNotificationPhCTopRetailer",void 0),(0,n.Z)(this,"productPageUrlRegex",void 0),(0,n.Z)(this,"settings",void 0),(0,n.Z)(this,"edgeFeatureFlag",void 0),(0,n.Z)(this,"isEligibleForRewards",void 0)}static Create(e){const t=new g;return e&&(t.domainName=e.domainName,t.orderConfirmationPageUrl=e.orderConfirmationPageUrl,t.exclusiveMarket=e.exclusiveMarket,t.multiMsgValidationEnabled=e.multiMsgValidationEnabled,t.exactCheckoutPageUrl=e.exactCheckoutPageUrl,t.productOutOfStockSelector=e.productOutOfStockSelector,t.productNameSelector=e.productNameSelector,t.productPriceSelector=e.productPriceSelector,t.productImageSelector=e.productImageSelector,t.aaConsentEnabled=e.aaConsentEnabled,t.storeCartInEdgeStorage=e.storeCartInEdgeStorage,t.cartMonitorUrl=e.cartMonitorUrl,t.checkoutPageUrl=e.checkoutPageUrl,t.isTravelDomain=e.isTravelDomain,t.isStorewideCashbackEstimationEnabled=e.isStorewideCashbackEstimationEnabled,t.createCheckoutPageList(e),t.createFinalCheckoutPageList(e),t.createYoutubeTemplateList(e),t.createProductPagesList(e),t.confirmationPageTelemetry=e.confirmationPageTelemetry,t.isAOCFragmentCollectionEnabled=e.isAOCFragmentCollectionEnabled,t.productPageUrl=e.productPageUrl,t.aOCFragmentCollectionRate=e.aOCFragmentCollectionRate,t.disabledPopupOriginationList=e.disabledPopupOriginationList,t.addressBarExpansionEnabled=e.addressBarExpansionEnabled,t.createTriviaData(e),t.createAutomatedSelectorsPageList(e),t.isAddressBarCashbackEnabled=e.isAddressBarCashbackEnabled,t.isCompositeNotificationPhCExcludedRetailer=e.isCompositeNotificationPhCExcludedRetailer,t.isCompositeNotificationPhCTopRetailer=e.isCompositeNotificationPhCTopRetailer,t.productPageUrlRegex=e.productPageUrlRegex,t.searchQueryUrlRegex=e.searchQueryUrlRegex,t.settings=e.settings,t.edgeFeatureFlag=e.edgeFeatureFlag,t.isEligibleForRewards=e.isEligibleForRewards,t.platform=e.platform,t.checkoutPageKey=e.checkoutPageKey,t.allCheckoutPages=e.allCheckoutPages,t.finalCheckoutPageKey=e.finalCheckoutPageKey,t.allFinalCheckoutPages=e.allFinalCheckoutPages),t}updateCurrentCheckoutPage(e){return this.checkoutPageKey=this.findCurrentPage(e,this.allCheckoutPages,u.GV.CheckoutPage),-1!==this.checkoutPageKey}getCurrentCheckoutPage(e){return null!==this.checkoutPageKey&&-1!==this.checkoutPageKey&&void 0!==this.checkoutPageKey||-1!==this.checkoutPageKey&&e&&(this.updateCurrentCheckoutPage(e),null!==this.checkoutPageKey&&-1!==this.checkoutPageKey&&void 0!==this.checkoutPageKey)?this.allCheckoutPages[this.checkoutPageKey]:void 0}updateCurrentFinalCheckoutPage(e){const t=this.findCurrentPage(e,this.allFinalCheckoutPages);return-1!==t?(this.finalCheckoutPageKey=t,!0):(this.finalCheckoutPageKey=null,!1)}getCurrentFinalCheckoutPage(){if(null!=this.finalCheckoutPageKey)return this.allFinalCheckoutPages[this.finalCheckoutPageKey]}getCurrentProductPage(e){if(null!=this.productPageKey)return this.allProductPages[this.productPageKey];{const t=this.findCurrentProductPage(e,this.allProductPages);return-1!==t?(this.productPageKey=t,this.allProductPages[this.productPageKey]):void(this.productPageKey=null)}}getCurrentAutomatedSelectorsPage(e){return null!==this.automatedSelectorsKey&&void 0!==this.automatedSelectorsKey&&this.automatedSelectorsKey<this.allAutomatedSelectors.length||e&&(this.updateCurrentAutomatedSelectorsPage(e),null!==this.automatedSelectorsKey&&-1!==this.automatedSelectorsKey&&void 0!==this.automatedSelectorsKey)?this.allAutomatedSelectors[this.automatedSelectorsKey]:void 0}getAutomatedSelectorsPageByRegex(e){for(let t=0;t<this.allAutomatedSelectors.length;t++){const i=this.allAutomatedSelectors[t];if(new RegExp(i.urlRegex).test(e))return this.automatedSelectorsKey=t,i}this.automatedSelectorsKey=-1}isConfirmationPage(e){return new RegExp(this.orderConfirmationPageUrl).test(e)}updateCurrentAutomatedSelectorsPage(e){const t=this.findCurrentAutomatedSelectorsPage(e,this.allAutomatedSelectors);return-1!==t?(this.automatedSelectorsKey=t,!0):(this.automatedSelectorsKey=null,!1)}createCheckoutPageList(e){if(this.allCheckoutPages=[],e.allCheckoutPages&&e.allCheckoutPages.length>0)for(const t of e.allCheckoutPages)this.allCheckoutPages.push(l.Z.Create(t))}createFinalCheckoutPageList(e){if(this.allFinalCheckoutPages=[],e.allFinalCheckoutPages&&e.allFinalCheckoutPages.length>0)for(const t of e.allFinalCheckoutPages)this.allFinalCheckoutPages.push(l.Z.Create(t))}createAutomatedSelectorsPageList(e){if(this.allAutomatedSelectors=[],e.allAutomatedSelectors&&e.allAutomatedSelectors.length>0)for(const t of e.allAutomatedSelectors)this.allAutomatedSelectors.push(a.ZP.DeepAssign(new s.ZP,t))}createProductPagesList(e){if(this.allProductPages=[],e.allProductPages&&e.allProductPages.length>0)for(const t of e.allProductPages)this.allProductPages.push(d.Create(t))}createYoutubeTemplateList(e){if(this.youtubeTemplates=[],e.youtubeTemplates&&e.youtubeTemplates.length>0)for(const t of e.youtubeTemplates)this.youtubeTemplates.push(r.Create(t))}findCurrentPage(e,t,i){for(let n=0;t&&n<t.length;n++)if(a.ZP.IsPageMatch(t[n].checkoutPageUrl,t[n].pageUrlRegex,e)){if(p.R.isExperimentActive(h.H.checkoutPageTypeCheck)&&i&&t[n].pageType&&t[n].pageType!==i)continue;return t[n].disabled?-1:n}return-1}findCurrentProductPage(e,t){for(let i=0;i<t.length;i++)if(a.ZP.IsOnPage(t[i].productPageUrl,e))return i;return-1}findCurrentAutomatedSelectorsPage(e,t){for(let i=0;i<t.length;i++)if(a.ZP.IsPageRegexMatch(t[i].urlRegex,e))return i;return-1}createTriviaData(e){this.retailerTrivia={successRate:e?.retailerTrivia?.successRate??null}}isProductPage(e){return null!=this.productPageUrlRegex&&a.ZP.IsPageRegexMatch(this.productPageUrlRegex,e)||null!=this.productPageUrl&&a.ZP.IsPageRegexMatch(this.productPageUrl,e)}getCurrentPageType(){const e=this.getCurrentCheckoutPage()?.pageType??u.GV.UnknownPage;return e!==u.GV.UnknownPage?e:this.isProductPage(location.href)?u.GV.ProductPage:u.GV.UnknownPage}}var f=g},55648:function(e,t,i){"use strict";i.d(t,{Z:function(){return v}});var n=i(72370),o=i(56005),r=i(93078),a=i(93190),s=i(73557),l=i(91495),c=i(44092),d=i(91897),u=i(44922),h=i(52056),p=i(83879),g=i(86743),f=i(82315),m=i(56854),v=class{constructor(){(0,n.Z)(this,"localDataService",void 0),(0,n.Z)(this,"aaConsentEnabled",void 0),(0,n.Z)(this,"aaConsentData",void 0),(0,n.Z)(this,"validatorModule",void 0),(0,n.Z)(this,"domainName",void 0),(0,n.Z)(this,"apiResponse",void 0)}async Init(){if(this.localDataService=p.Z.GetLocalDataService(),this.validatorModule=p.Z.GetValidatorModule(),this.domainName=this.localDataService.GetDomainName(),this.aaConsentEnabled=this.localDataService.GetCheckoutPageData().retailerData?.aaConsentEnabled??!1,this.apiResponse=f.Z.getApiResponse(),!this.aaConsentEnabled)return;const e=this.getAAConsentStr(l.Q.rawStorageObj,this.localDataService.GetDomainName());this.aaConsentData=this.getAAConsentData(e)}GetPopupOriginationList(){return[s.sR.AA_CONSENT]}async CanAutoOpenForFeature(e){if(!this.aaConsentEnabled)return!1;const t=this.apiResponse.retailerData.allProductPages;if((0,m.r)())for(let e=0;e<t.length;e++)if(this.apiResponse.retailerData.allProductPages[e].backgroundAAEnabled)return!1;let i=!0;if(this.aaConsentData){const e=(0,d.r2)(this.aaConsentData?.timeStamp);e>=0&&e<120&&(i=!1)}return i&&((0,c.i8)("CanOpenAAConsent","true"),this.validatorModule.SendValidationMessage(!1,u.S.AAConsent,this.domainName,[a.p.AA_CONSENT],!1,!(0,g.XB)())),i}async PostValidation(){}isAutoTriggeredAAAllowed(){if(!this.aaConsentEnabled||!this.aaConsentData?.allowed)return!1;const e=(0,d.r2)(this.aaConsentData.timeStamp);return e>=0&&e<1}AutoTriggerAutoApply(e){if(!this.aaConsentData)return;this.aaConsentData.allowed=!1;const t=o.Z.GetAAConsentStorageKey(this.localDataService.GetDomainName());h.Z.SendStorageMessage(t,JSON.stringify({value:JSON.stringify(this.aaConsentData)}));const i=new class{constructor(){(0,n.Z)(this,"BgaaResultAvailable",void 0)}};i.BgaaResultAvailable=e,h.Z.StartEdgeDriver("",JSON.stringify({action:r.v.PDPconsentAA,data:i}))}getAAConsentStr(e,t){const i=o.Z.GetAAConsentStorageKey(t);return"string"==typeof e[i]?e[i]:e[i]?.value??""}getAAConsentData(e){try{if(!e)return;return JSON.parse(e)}catch(e){return}}}},59518:function(e,t,i){"use strict";var n=i(72370),o=i(5144),r=i(55648),a=i(82315),s=i(29247),l=i(44922),c=i(1094),d=i(31714),u=i(59645),h=i(73557),p=i(4872),g=i(90066),f=i(55590),m=i(20546),v=i(52056),y=i(83879),C=i(9839),b=i(31656),S=i(86743),x=i(3634),T=i(91495),w=i(65559),O=i(56854),P=i(57459);t.Z=class{constructor(){(0,n.Z)(this,"checkoutPageUrlData",void 0),(0,n.Z)(this,"apiResponse",void 0),(0,n.Z)(this,"domainName",void 0),(0,n.Z)(this,"isPageValid",void 0),(0,n.Z)(this,"aaValidationReason",void 0),(0,n.Z)(this,"canOpen",void 0),(0,n.Z)(this,"autoOpenReasons",void 0),(0,n.Z)(this,"totalPrice",void 0),(0,n.Z)(this,"localDataService",void 0),(0,n.Z)(this,"validator",void 0),(0,n.Z)(this,"aocValidatorUtilities",void 0),(0,n.Z)(this,"bgaaService",void 0)}GetPopupOriginationList(){return[h.sR.AUTO_SHOW_COUPONS_CHECKOUT]}async CanAutoOpenForFeature(e){if(this.classifiedAsNonCheckoutPage())return Promise.resolve(!1);b.R.isExperimentActive(p.H.autofillAutoPopup)&&this.setAttributeForInputBox(),this.totalPrice=this.GetTotalPrice(),this.aaValidationReason=await this.IsAAValid(),this.isPageValid=this.aaValidationReason===l.S.PageIsValid,this.autoOpenReasons=[];const t=this.localDataService.IsExpressCheckoutPage(),i={auto_apply_status:this.isPageValid,express_checkout_status:t,open_micro_notifcation:!1,page_validations:[],page_validations_auto_open:[],auto_open_reasons:[]};if(!this.isPageValid){if(this.aaValidationReason===l.S.PageIsInvalid&&this.apiResponse.retailerData?.multiMsgValidationEnabled){const e=c.Z.GetInitialFields(this.apiResponse);s.ZP.ObserveUntil((()=>this.validator.IsPageValid(e)),(()=>{this.validator.SendValidationMessage(!0,l.S.PageBecameValid,this.domainName,void 0,!(0,S.XB)(),!1,i);const e=new CustomEvent(x.T2,{detail:{popupOrigination:h.sR.AUTO_SHOW_COUPONS_CHECKOUT}});window.dispatchEvent(e)}))}return this.validator.SendValidationMessage(this.isPageValid,this.aaValidationReason,this.domainName,void 0,!1,!1,i),Promise.resolve(!1)}let n=null;const a=v.Z.ParseBackgroundAutoApplyStateData(T.Q.rawStorageObj);a&&this.checkoutPageUrlData&&(n=await this.bgaaService.TryValidateBackgroundAutoApplyState(a,this.localDataService.GetMarket(),this.checkoutPageUrlData)),this.SetTotalPrice(),this.canOpen=await this.shouldAutoOpenForAA(i);const d=this.canOpen;let g=d;const y=T.Q.BGAAApplyButtonClicked,C=b.R.isExperimentActive(p.H.suppressAAAutoApplyThreshold),P=(0,O.r)();let A;if(P&&this.canOpen&&(n===o.ps.Positive&&y==="true_"+this.domainName||n===o.ps.Negative)&&(this.canOpen=!1,this.autoOpenReasons.push("BGAA is active"),g=!1,v.Z.SendStringStorageMessage(f.Q.BGAAApplyButtonClicked,"false_"+this.domainName)),C)try{const e=b.R.getServiceExperimentValue(p.H.suppressAAAutoApplyThreshold),t=b.R.getServiceExperimentValue(p.H.suppressAADomainSuccessThreshold);if(t&&e){const i=parseInt(t,10),n=parseInt(e,10),r=T.Q.UnsuccessfulAutoApplyCount;r&&n>0&&i>0&&this.canOpen&&r>=n&&(this.canOpen=this.HasHighConfidenceCouponsDomainLevel(i),this.canOpen||this.autoOpenReasons.push("Unsuccessful AA count is above threshold"));const a=new u.Z(o.xu.SuppressAutoApply),s=this.apiResponse?.retailerData?.retailerTrivia?.successRate;s&&0===s&&(this.canOpen=!1,this.autoOpenReasons.push("Domain success rate is 0"));const l=this.canOpen;A=l,a.Domain=this.domainName,a.Metadata=JSON.stringify({unsuccessfulAACount:r,aaFailureThreshold:n,domainThreshold:i,currentDomainSuccesRate:s,canOpen:l,autoOpenReasons:this.autoOpenReasons}),v.Z.SendLogEvent(this.apiResponse.impressionId,"Suppress auto apply experiement result telemetry","",void 0,void 0,o.R.EdgeFlyoutStatus,a,this.domainName)}}catch(e){v.Z.SendLogEvent(this.apiResponse.impressionId,"Suppress auto apply experiment error:"+e?.message,"error",void 0,void 0,o.R.AutoApply)}const E=new r.Z;E.Init();const k=new m.Z;k.Init();const I=new w.Z;if(I.Init(),i.auto_open_reasons.push(...this.autoOpenReasons),E.isAutoTriggeredAAAllowed()?(this.autoOpenReasons.push("Auto Triggered AA Allowed"),i.auto_open_reasons.push("Auto Triggered AA Allowed"),this.validator.SendValidationMessage(this.isPageValid,this.aaValidationReason,this.domainName,void 0,!1,!1,i),this.canOpen=!1,E.AutoTriggerAutoApply(null!=n)):k.isAutoApplyingBestCouponAllowed()?((0,S.XB)()&&(this.autoOpenReasons.push("AOC is active, deferred to AOC"),i.auto_open_reasons.push("AOC is active, deferred to AOC")),this.validator.SendValidationMessage(this.isPageValid,this.aaValidationReason,this.domainName,void 0,!(0,S.XB)()&&this.canOpen,!1,i),k.AutoApplyBestCoupon()):I.isAutoApplyingExclusiveCouponAllowed()?(this.autoOpenReasons.push("Auto Triggered Exclusive Coupon Allowed"),i.auto_open_reasons.push("Auto Triggered Exclusive Coupon Allowed"),this.validator.SendValidationMessage(this.isPageValid,this.aaValidationReason,this.domainName,void 0,!1,!1,i),I.AutoApplyExclusiveCoupon()):((0,S.XB)()&&(this.autoOpenReasons.push("AOC is active, deferred to AOC"),i.auto_open_reasons.push("AOC is active, deferred to AOC")),this.validator.SendValidationMessage(this.isPageValid,this.aaValidationReason,this.domainName,void 0,!(0,S.XB)()&&this.canOpen,!1,i)),P){const e=this.canOpen,t=new u.Z(o.xu.SuppressAutoApply);t.Domain=this.domainName,t.Metadata=JSON.stringify({bgaaApplyButtonClicked:y,bgaaResult:n,canOpenInitial:d,canOpenWithBGAA:g,canOpenFinal:e,isSuppressAAActive:C,canOpenWithIsSuppressAAActive:A}),v.Z.SendLogEvent(this.apiResponse.impressionId,"BGAA checkout page - canOpen status for AUTO_SHOW_COUPONS_CHECKOUT","",void 0,void 0,o.R.EdgeFlyoutStatus,t,this.domainName)}return Promise.resolve(this.canOpen)}Init(){return this.apiResponse=a.Z.getApiResponse(),this.apiResponse.retailerData.updateCurrentCheckoutPage(c.Z.GetCurrentPathName()),this.checkoutPageUrlData=this.apiResponse.retailerData.getCurrentCheckoutPage(),this.domainName=this.apiResponse.retailerData.domainName,this.localDataService=y.Z.GetLocalDataService(),this.validator=y.Z.GetValidatorModule(),this.aocValidatorUtilities=c.Z.GetValidatorAutoOpenController(),this.bgaaService=y.Z.GetBackgroundAAService(),Promise.resolve()}PostValidation(){return this.classifiedAsNonCheckoutPage()||c.Z.GetAndSendOrderTotal(this.localDataService.GetMarket(),this.isPageValid,this.aaValidationReason),Promise.resolve()}classifiedAsNonCheckoutPage(){return(this.checkoutPageUrlData?.pageType??o.GV.CheckoutPage)!==o.GV.CheckoutPage}GetTotalPrice(){return this.checkoutPageUrlData&&!this.checkoutPageUrlData.supportedNoOrderTotal?v.Z.GetOrderTotalString(this.checkoutPageUrlData.orderTotalDataElementSelector):""}SetTotalPrice(){this.aocValidatorUtilities&&!this.checkoutPageUrlData?.supportedNoOrderTotal&&(v.Z.SendStorageMessage("price"+this.domainName,JSON.stringify({value:this.totalPrice})),(0,S.XB)()?C.Q.setTotalPrice(this.totalPrice):this.aocValidatorUtilities.setTotalPrice(this.totalPrice))}async HasEligibleCoupons(){if(!b.R.isExperimentActive(p.H.onlyShowAANotificationWithEligibleCoupons))return!0;try{const e=y.Z.GetSuggestedCouponService().GetSuggestedCoupons(),t=await y.Z.GetCartExtractionService().WaitForCartExtractionAndBlockedCouponsThenGetCartData();return P.Z.FilterUnblockedCoupons(this.apiResponse.coupons,e,t?.BlockedCouponsData?.BlockedCoupons??[]).length>0}catch(e){return!0}}async IsAAValid(){if(!this.checkoutPageUrlData)return this.validator.sendErrorMessage(this.apiResponse.impressionId,"no checkout page url data"),l.S.IsPageValidError;if(!this.IsAutoApplyEnabled())return l.S.DisabledCheckoutPageData;if(0===c.Z.GetInitialFields(this.apiResponse).length)return l.S.NoSelectors;if(this.apiResponse.coupons?.length>0==0)return l.S.NoCoupons;if(this.checkoutPageUrlData.isHomePageSameAsCheckout&&!this.checkoutPageUrlData.supportedNoOrderTotal)try{const e=+this.totalPrice;if(!e||e<=0)return l.S.InvalidCartTotal}catch{return l.S.InvalidCartTotal}try{const e=this.HasEligibleCoupons(),t=this.localDataService.GetIsCheckoutPage(this.apiResponse);return await e?await t?(this.PrefetchAutoApplyResources(),l.S.PageIsValid):l.S.PageIsInvalid:l.S.AllCouponsBlocked}catch(e){return this.validator.sendErrorMessage(this.apiResponse.impressionId,e?.message??"checkoutpage error."),l.S.IsPageValidError}}PrefetchAutoApplyResources(){if(document?.body){let e=!1;const t="https://edgeshoppingstatic.azureedge.net/shoppingjsstatic/v2/Assets";window&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches&&(e=!0);const i=document.createElement("LINK");i.setAttribute("rel","prefetch"),i.href=e?t+"Shopping_Progress_Dark_01.mp4":t+"Shopping_Progress_01.mp4",i.setAttribute("as","fetch");const n=document.createElement("LINK");n.setAttribute("rel","prefetch"),n.href=e?t+"Shopping_Success_Dark_01.mp4":t+"Shopping_Success_01.mp4",n.setAttribute("as","fetch");const o=document.createElement("LINK");o.setAttribute("rel","prefetch"),o.href=e?t+"Shopping_Finished_Dark_01.mp4":t+"Shopping_Finished_01.mp4",o.setAttribute("as","fetch"),document.body.appendChild(i),document.body.appendChild(n),document.body.appendChild(o)}}IsAutoApplyEnabled(){return!0===this.checkoutPageUrlData?.edgeEnabled}setAttributeForInputBox(){const e=this.checkoutPageUrlData?.isAutoShowDisabled;if(void 0!==this.checkoutPageUrlData&&this.checkoutPageUrlData.inputBoxSelector&&!e){const e=g.Z.GetFirstVisibleElement(this.checkoutPageUrlData.inputBoxSelector);e?.setAttribute("edge-shopping-apply-coupon-input-box-tag","")}}async shouldAutoOpenForAA(e){const t=e.auto_apply_status;let i=!0;if(!(0,S.XB)()){const e={Reason:""};i=this.aocValidatorUtilities.isPopupOriginationUnblocked(h.sR.AUTO_SHOW_COUPONS_CHECKOUT,e),e.Reason&&this.autoOpenReasons.push(e.Reason)}const n=b.R.isExperimentActive(p.H.CouponsPersonalization),r=this.validator.GetRuleBasedTriggerController();if(i&&n&&r&&this.apiResponse?.coupons&&this.apiResponse.coupons.length>0&&!(0,S.XB)())if(i=r.canAutoOpen(),i)e.personalizationAutoOpenTelemetryData=r.getPersonalizationAutoOpenTelemetryData();else{this.autoOpenReasons.push("RuleBased Trigger Controller decides to not auto open the flyout");const e=new u.Z(o.xu.PersonalizedAutoTriggerOff);e.Metadata=JSON.stringify({personalizationAutoOpenTelemetryData:r.getPersonalizationAutoOpenTelemetryData(),popupOriginationEnum:h.sR.AUTO_SHOW_COUPONS_CHECKOUT}),v.Z.SendLogEvent(this.apiResponse.impressionId,"RuleBased Trigger Controller decides to not auto open the flyout",t?"true":"false",void 0,void 0,o.R.EdgeFlyoutStatus,e)}const a=b.R.getMultipleVariants(p.H.couponsConfidence),s=b.R.getVariantValue(a,d.qG.CouponLevelThreshold,-1),l=b.R.getVariantValue(a,d.qG.DomainLevelThreshold,-1);if(i&&s>=0){const e=this.HasHighConfidenceCouponsCouponsLevel(s);i=i&&e,i||this.autoOpenReasons.push("No high confidence coupons available above threshold at coupons level")}if(i&&l>=0){const e=this.HasHighConfidenceCouponsDomainLevel(l);i=i&&e,i||this.autoOpenReasons.push("No high confidence coupons available above threshold at domain level")}return i}HasHighConfidenceCouponsCouponsLevel(e){let t=!1,i=!1;if(this.apiResponse?.coupons?.length)for(const n of this.apiResponse.coupons){const o=void 0===n.successRate?0:n.successRate;if(i||void 0===o||0===o||(i=!0),o>=e){t=!0;break}}return!i||t}HasHighConfidenceCouponsDomainLevel(e){let t=!0;return this.apiResponse?.retailerData?.retailerTrivia?.successRate&&(t=this.apiResponse?.retailerData?.retailerTrivia?.successRate>=e),t}}},98574:function(e,t,i){"use strict";var n=i(72370),o=i(5144),r=i(73557),a=i(91495),s=i(82315),l=i(1094),c=i(52056),d=i(11849),u=i(83879),h=i(86743),p=i(31024),g=i(55648),f=i(44922),m=i(27689),v=i(33491),y=i(3634),C=i(56854);t.Z=class{constructor(){(0,n.Z)(this,"apiResponse",void 0),(0,n.Z)(this,"domainName",void 0),(0,n.Z)(this,"canOpen",void 0),(0,n.Z)(this,"localDataService",void 0),(0,n.Z)(this,"validator",void 0),(0,n.Z)(this,"aocValidatorUtilities",void 0),(0,n.Z)(this,"BestCouponConsentData",void 0),(0,n.Z)(this,"checkoutPageUrlData",void 0)}Init(){return this.apiResponse=s.Z.getApiResponse(),this.domainName=this.apiResponse.retailerData.domainName,this.localDataService=u.Z.GetLocalDataService(),this.validator=u.Z.GetValidatorModule(),this.aocValidatorUtilities=l.Z.GetValidatorAutoOpenController(),this.BestCouponConsentData=(0,m.BQ)(a.Q.ProductBestCouponConsent),this.checkoutPageUrlData=this.apiResponse.retailerData.getCurrentCheckoutPage(),Promise.resolve()}PostValidation(){return Promise.resolve()}GetPopupOriginationList(){return[r.sR.AUTO_SHOW_COUPONS_BACKGROUND_AUTO_APPLY]}GetAutoOpenParams(){return JSON.stringify({bestCouponConsentData:this.BestCouponConsentData})}async CanAutoOpenForFeature(e){const t=(0,v.WN)("isBgaaComplete");if(this.isCheckoutPage()||!1===t)return Promise.resolve(!1);const i=c.Z.ParseBackgroundAutoApplyStateData(a.Q.rawStorageObj),n=i?.BackgroundAAStatus.domainName===this.domainName;let s=null;if(i&&n&&t&&(s=await this.TryValidateBackgroundAutoApplyState(i,this.localDataService.GetMarket())),this.canOpen=await this.shouldAutoOpenForBGAA(),this.canOpen&&s&&s===o.ps.Positive){const e=new CustomEvent(y.T2,{detail:{popupOrigination:r.sR.AUTO_SHOW_COUPONS_BACKGROUND_AUTO_APPLY}});window.dispatchEvent(e)}else this.canOpen=!1;return(new g.Z).Init(),this.canOpen&&t&&this.validator.SendValidationMessage(!0,f.S.PageIsValid,this.domainName,void 0,!(0,h.XB)()&&this.canOpen,!1,void 0),(0,v.Ev)("isBgaaComplete",!1),Promise.resolve(this.canOpen)}async TryValidateBackgroundAutoApplyState(e,t,i){try{return await this.ValidateBackgroundAutoApplyState(e,t,i)}catch(e){}return null}async ValidateBackgroundAutoApplyState(e,t,i){const n=p.Z.GetBackgroundAAKeyName();if(Date.now()-e.StartTime>864e5)return this.validator.DeleteKeyFromPersistentStorage(n),p.Z.SendBackgroundAAStateValidationMessage(""),null;const o=p.Z.CanCurrentDomainDeleteBgaaState(e.BackgroundAAStatus.domainName);if(!o&&e.BackgroundAAStatus.expiredState)return p.Z.SendBackgroundAAStateValidationMessage(""),null;const r=e.BackgroundAAStatus.result,a=p.Z.CanCurrentPageDeleteBgaaState(e.BackgroundAAStatus.pageUrl);if(!a&&e.BackgroundAAStatus.expiredState)return p.Z.SendBackgroundAAStateValidationMessage(""),null;if(a&&i){const o=await d.Z.WaitAndGetCartValue(i.orderTotalDataElementSelector,t),s=await d.Z.WaitAndGetCartValue(i.orderSubTotalElementSelector,t,1e3);return p.Z.ValidateBgAAState(e,o.OrderTotal,s.OrderTotal)?this.GetBgaaResult(e,r):(a?this.validator.DeleteKeyFromPersistentStorage(n):(e.BackgroundAAStatus.expiredState=!0,this.validator.SendStorageMessage(n,JSON.stringify({value:e.ToString()}))),p.Z.SendBackgroundAAStateValidationMessage(""),null)}return o?this.GetBgaaResult(e,r):null}GetBgaaResult(e,t){const i=Math.round(100*e.MaxDiscount)/100;(t===o.ps.InProgress||t===o.ps.Cancelled)&&i>0&&(t=o.ps.Positive);const n={BestCoupon:e.BestCoupon?.couponCode,Result:t,Savings:i,SuccessfulCoupons:e.CouponResults.filter((e=>e.Discount>0)).map((e=>e.Code))};return p.Z.SendBackgroundAAStateValidationMessage(JSON.stringify(n)),t}isCheckoutPage(){return!!this.checkoutPageUrlData&&this.checkoutPageUrlData.pageType!==o.GV.ProductPage&&!(!this.checkoutPageUrlData.checkoutPageUrl||"/"===this.checkoutPageUrlData.checkoutPageUrl)}async shouldAutoOpenForBGAA(){if(!(0,C.r)())return!1;let e=!0;return(0,h.XB)()||(e=this.aocValidatorUtilities.isPopupOriginationUnblocked(r.sR.AUTO_SHOW_COUPONS_BACKGROUND_AUTO_APPLY)),e}}},74113:function(e,t,i){"use strict";i.d(t,{Z:function(){return k}});var n=i(72370),o=i(59645),r=i(58474);class a extends r.Z{constructor(e,t,i,o,r){super(),(0,n.Z)(this,"Discount",void 0),(0,n.Z)(this,"StartingPrice",void 0),(0,n.Z)(this,"Domain",void 0),(0,n.Z)(this,"ProductUrl",void 0),(0,n.Z)(this,"DiscountString",void 0),this.StartingPrice=t??0,this.Discount=i??0,this.ProductUrl=e,this.DiscountString=o,this.Domain=r}}var s=a,l=i(5144),c=i(5491),d=i(93190),u=i(73557),h=i(55590),p=i(29247),g=i(50616),f=i(36493),m=i(91495),v=i(27689),y=i(9448),C=i(90066),b=i(41290),S=i(44922),x=i(52056),T=i(83879),w=i(93970),O=i(1094),P=i(86743),A=i(31656),E=i(4872),k=class{constructor(){(0,n.Z)(this,"checkoutPageUrlData",void 0),(0,n.Z)(this,"localDataService",void 0),(0,n.Z)(this,"domainName",void 0),(0,n.Z)(this,"impressionId",void 0),(0,n.Z)(this,"traceId",void 0),(0,n.Z)(this,"validator",void 0),(0,n.Z)(this,"aocValidatorUtilities",void 0),(0,n.Z)(this,"rakutenJP","rakuten.co.jp")}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_COUPONS_CLIPPING]}async CanAutoOpenForFeature(e){const t=await this.waitForIsClippingScenario(this.checkoutPageUrlData);if(A.R.getServiceExperimentValue(E.H.clipCloseSnooze)&&!(0,P.XB)()&&!this.aocValidatorUtilities.isPopupOriginationUnblocked(u.sR.AUTO_SHOW_COUPONS_CLIPPING))return Promise.resolve(!1);if(this.checkoutPageUrlData?.clippingSelectors){const e=new o.Z(l.xu.CouponClippingSelectorsAvailable);e.Metadata=JSON.stringify({Domain:this.domainName,isClippingValid:t,Url:location.pathname}),x.Z.SendLogEventMessage(e,l.R.EdgeFlyoutStatus,this.impressionId,`Clipping selectors is available for ${this.domainName}. The selectors are: ${JSON.stringify(this.checkoutPageUrlData.clippingSelectors)}`,l.in.Information)}if(!t||!this.checkoutPageUrlData?.clippingSelectors)return Promise.resolve(!1);const i=this.getAutoClipData();if(!i?.includes(this.domainName))return t&&(this.validator.SendValidationMessage(!1,S.S.Clipping,this.domainName,[d.p.COUPONS_CLIPPING]),this.localDataService.SetIsClippingSent(!0)),Promise.resolve(t);const n=new b.Z(new class{SendLogMessage(e,t,i,n,o){x.Z.SendLogEventMessage(n,t,o,i,e)}SaveSavingsTransactionToEdge(e){x.Z.SendStorageMessage(l.Sl.CouponClippingTransactionsKey,JSON.stringify({value:JSON.stringify(e)}))}SendEdgeAANegativeResult(){}SendEdgeAAPositiveResult(e,t,i){}SendEdgeAAErrorMessage(e){}},l.KE.AutoCouponClipping);return await n.TryClipCoupons(this.checkoutPageUrlData.clippingSelectors,this.domainName,new c.V,this.impressionId)&&(x.Z.SendMessage(y.H.RecordShoppingUserEngagement,[w.OE.CouponClipping]),x.Z.SendMessage(y.H.RecordShoppingUserAction,[w.J6.CouponClipping])),Promise.resolve(!1)}Init(){return this.localDataService=T.Z.GetLocalDataService(),this.domainName=this.localDataService.GetDomainName(),this.checkoutPageUrlData=this.localDataService.GetCheckoutPageData().retailerData.getCurrentCheckoutPage(location.pathname),this.validator=T.Z.GetValidatorModule(),this.aocValidatorUtilities=O.Z.GetValidatorAutoOpenController(),this.impressionId=this.localDataService.GetImpressionId(),this.checkoutPageUrlData,Promise.resolve()}PostValidation(){return Promise.resolve()}async waitForIsClippingScenario(e){const t=e?.clippingSelectors;if(!t?.discountSelector||!t?.signedInSelector)return!1;const i=t.waitForPageLoad;i&&await p.ZP.Sleep(i);const n=await this.isClippingPage(t),o=await this.isClippingScenario(t,n),r=await this.logIfClippingExist(t,n);return o&&r}getAutoClipData(){if(m.Q?.AutoClipData){let e=new class{constructor(){(0,n.Z)(this,"enabledDomains",void 0)}};try{e=(0,v.BQ)(m.Q.AutoClipData)}catch{x.Z.DeleteKeyFromPersistentStorage(h.Q.AutoClipData)}return e.enabledDomains}}isClippingScenario(e,t){let i;const n=C.Z.HasVisibleElement(e.signedInSelector);if(this.domainName===this.rakutenJP){let o=C.Z.HasVisibleElement(e.clipCouponSelector);if(!o){const t=C.Z.GetFirstVisibleElement(e.clickBeforeClipSelector);t?.click(),o=C.Z.HasVisibleElement(e.clipCouponSelector)}i=t&&(n||!!e.isSignInOptional)&&o}else{const o=C.Z.HasVisibleElement(e.alreadyClippedSelector);i=t&&(n||!!e.isSignInOptional)&&!o}if(i){const t=new o.Z(l.xu.CouponClippingElements);t.Metadata=JSON.stringify({signedInSelector:e.signedInSelector,alreadyClippedSelector:e.alreadyClippedSelector,isSignInOptional:e.isSignInOptional,Url:location.pathname}),x.Z.SendLogEventMessage(t,l.R.EdgeFlyoutStatus,this.impressionId,"isClippingScenario",l.in.Information)}return i}logIfClippingExist(e,t){if(!t)return!1;try{const t=C.Z.GetFirstVisibleElement(e.orderTotalDataElementSelector),i=t?.innerText??"";let n,o;if(i.includes("-")){const e=i.split("-");n=g.Z.getInitialPrice(e[0]),o=g.Z.getInitialPrice(e[1])}else n=g.Z.getInitialPrice(i);const r=this.getDiscount(n,o,e);if(void 0===r||0===r.discount)return!1;const a=new s(location.pathname,n,r?.discount,r?.discountString,(0,v.S8)());x.Z.SendLogEventMessage(a,l.R.ClippingExist,this.impressionId,"There is clipping",l.in.Information)}catch(e){x.Z.SendLogEvent(this.impressionId,"Error while logging clipping data : "+e?.message,"error",void 0,void 0,void 0),x.Z.SendMessage(y.H.CheckoutPageValidationError,["error",this.traceId])}return!0}isClippingPage(e){const t=C.Z.HasVisibleElement(e.clickBeforeClipSelector),i=C.Z.HasVisibleElement(e.clipCouponSelector);if(t||i){const t=new o.Z(l.xu.CouponClippingElements);t.Metadata=JSON.stringify({clickBeforeClipSelector:e.clickBeforeClipSelector,clipCouponSelector:e.clipCouponSelector,Url:location.pathname}),x.Z.SendLogEventMessage(t,l.R.EdgeFlyoutStatus,this.impressionId,"isClippingPage",l.in.Information)}return t||i}getDiscount(e,t,i){let n;if(this.domainName===this.rakutenJP){const t=[];let o=C.Z.GetAllMatchingElements(i.discountSelector);if(!o.length){const e=C.Z.GetFirstVisibleElement(i.clickBeforeClipSelector);if(e?.click(),o=C.Z.GetAllMatchingElements(i.discountSelector),!o)return}o.forEach((i=>{const n="%"===i.childNodes[1].textContent||"%"===i.childNodes[1].textContent?(0,f.K)(i.childNodes[0].textContent??"0")*e:(0,f.K)(i.childNodes[0].textContent??"0");t.push(n)})),t.sort(((e,t)=>e-t)),n={discount:t[0],maxDiscount:t[t.length-1],discountString:t[0].toString()}}else{const o=C.Z.GetFirstVisibleElement(i.discountSelector),r=o?.innerText??"";if(r.includes("-")){const a=r.split("-"),s=g.Z.getAmazonClippingDiscount(e,a[0])??0,l=g.Z.getAmazonClippingDiscount(e,a[1])??0;let c=0,d=0;if(i.isSalePriceNotDiscount)if(t){const i=0===s?0:e-s,n=0===l?0:t-l;c=Math.min(i,n),d=Math.max(i,n)}else d=0===s?0:e-s,c=0===l?0:e-l;else c=s,d=l;n={discount:c,maxDiscount:d,discountString:o?.innerText??""}}else{let t=g.Z.getAmazonClippingDiscount(e,r)??0;i.isSalePriceNotDiscount&&(t=0===t?0:e-t),n={discount:t??0,maxDiscount:t??0,discountString:o?.innerText??""}}}return n}}},65559:function(e,t,i){"use strict";var n=i(72370),o=i(56005),r=i(93078),a=i(73557),s=i(55590),l=i(91495),c=i(44092),d=i(91897),u=i(27689),h=i(82315),p=i(23498),g=i(52056),f=i(56854);t.Z=class{constructor(){(0,n.Z)(this,"apiResponse",void 0),(0,n.Z)(this,"domainName",void 0),(0,n.Z)(this,"ExclusiveCouponConsentWithDomain",void 0),(0,n.Z)(this,"aaConsentData",void 0)}async Init(){this.apiResponse=h.Z.getApiResponse(),this.domainName=this.apiResponse.retailerData?.domainName??(0,u.S8)(),this.ExclusiveCouponConsentWithDomain=(0,u.BQ)(l.Q.ExclusiveCouponConsent)??{},this.apiResponse.retailerData?.aaConsentEnabled&&(this.aaConsentData=(0,u.BQ)(l.Q.rawStorageObj[o.Z.GetAAConsentStorageKey(this.domainName)]))}GetPopupOriginationList(){return[a.sR.AUTO_SHOW_ABANDONED_CART]}async CanAutoOpenForFeature(e){const t=this.apiResponse.retailerData.allProductPages;if((0,f.r)()&&t.length>0)for(let e=0;e<t.length;e++)if(this.apiResponse.retailerData.allProductPages[e].backgroundAAEnabled)return!1;return"true"!==(0,c.Lt)("CanOpenAAConsent")&&!this.isAutoTriggeredAAAllowed()}async PostValidation(){}isAutoApplyingExclusiveCouponAllowed(){if(!this.ExclusiveCouponConsentWithDomain||!this.ExclusiveCouponConsentWithDomain[this.domainName]?.allowed)return!1;const e=(0,d.r2)(this.ExclusiveCouponConsentWithDomain[this.domainName].timeStamp);return e>=0&&e<1||(delete this.ExclusiveCouponConsentWithDomain[this.domainName],g.Z.SendStorageMessage(s.Q.ExclusiveCouponConsent,JSON.stringify({value:JSON.stringify(this.ExclusiveCouponConsentWithDomain)})),!1)}AutoApplyExclusiveCoupon(){this.ExclusiveCouponConsentWithDomain&&this.ExclusiveCouponConsentWithDomain[this.domainName]?.exclusiveCoupon&&(g.Z.StartEdgeDriver("",JSON.stringify({action:r.v.ApplyExclusiveCoupon,data:{exclusiveCoupon:this.ExclusiveCouponConsentWithDomain[this.domainName].exclusiveCoupon}})),p.Z.fireAffiliateUrl(this.apiResponse),delete this.ExclusiveCouponConsentWithDomain[this.domainName],g.Z.SendStorageMessage(s.Q.ExclusiveCouponConsent,JSON.stringify({value:JSON.stringify(this.ExclusiveCouponConsentWithDomain)})))}isAutoTriggeredAAAllowed(){if(!this.aaConsentData?.allowed)return!1;const e=(0,d.r2)(this.aaConsentData.timeStamp);return e>=0&&e<1}}},98011:function(e,t,i){"use strict";i.d(t,{M:function(){return L}});var n=i(72370),o=i(41865),r=i(3634),a=i(95457),s=i(4872),l=i(31656),c=i(47594),d=i(59645),u=i(59352),h=i(5144),p=i(93078),g=i(93190),f=i(11050),m=i(88767),v=i(73557),y=i(55590),C=i(18491),b=i(71544),S=i(33491),x=i(91495),T=i(27689),w=i(4724),O=i(47746),P=i(8018),A=i(57550),E=i(82315),k=i(9839),I=i(1094),D=i(50607),_=i(44922),N=i(52056),R=i(83879),M=i(86743);function L(e,t=!1){const i=(e?.value||[]).find((e=>e.position===m.zE.SPB_OFFERS));return!(!(i&&i?.offer&&i?.promotionInformation)||t&&"true"!==i.offerLevelSignals?.autoshow)}class B{constructor(){(0,n.Z)(this,"apiResponse",void 0),(0,n.Z)(this,"hasSpbExpiryNotifyVariation",!1),(0,n.Z)(this,"hasSpbAddToCartNotifyVariation",!1),(0,n.Z)(this,"autoActivationOnCartPage",!1),(0,n.Z)(this,"itemLevelCashback",void 0),(0,n.Z)(this,"domainName",void 0),(0,n.Z)(this,"cartExtractionService",void 0)}Init(){this.apiResponse=E.Z.getApiResponse();const e=this.apiResponse?.itemLevelCashBack?.variations?new Map(Object.entries(this.apiResponse?.itemLevelCashBack?.variations)):new Map;this.hasSpbExpiryNotifyVariation=e?.get("spbExpiryNotifyVariation")===u.b.variation1;const t=l.R.getServiceExperimentValue(s.H.spbAddToCart);if(this.hasSpbAddToCartNotifyVariation="variation1"===t,this.autoActivationOnCartPage=l.R.isTestFlagActive(c.t.msShoppingTestExp10)||l.R.isExperimentActive(s.H.spbCheckoutAutoActivation)||l.R.isExperimentActive(s.H.qtCartPageAutoActivation),this.itemLevelCashback=this.apiResponse.itemLevelCashBack,this.domainName=this.apiResponse.retailerData.domainName,this.autoActivationOnCartPage){try{if("amazon.com"===this.domainName||"target.com"===this.domainName||"walmart.com"===this.domainName){const e=R.Z.GetLocalDataService(),t=(e?.GetCheckoutPageData()||this.apiResponse).retailerData.getCurrentCheckoutPage(location.pathname);if(t?.pageType===h.GV.CheckoutPage){let e;const t=new Promise((t=>setTimeout(e=t,2e3)));return this.cartExtractionService=R.Z.GetCartExtractionService(),this.cartExtractionService.subscribe(e),this.cartExtractionService.Init(),t}}}catch(e){const t=new d.Z(h.xu.CartPageCashbackNotification);t.Metadata=JSON.stringify({}),t.Domain=this.domainName,N.Z.SendLogEventMessage(t,h.R.EdgeFlyoutStatus,this.apiResponse.impressionId,e.message,h.in.Error)}this.autoActivationOnCartPage=!1}return Promise.resolve()}PostValidation(){return Promise.resolve()}GetPopupOriginationList(){return[v.sR.AUTO_SHOW_SPB_CASHBACK_LANDING,v.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK,v.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK_LANDING,v.sR.AUTO_SHOW_SPB_CHECK_OUT_PAGE_NOTIFICATION]}async CanAutoOpenForFeature(e){const t=x.Q?.ICIsPendingTransactionPresent??!1,i=R.Z.GetICValidatorService();if(i.GetPopupOriginationList().includes(e)){if((0,M.XB)()&&(await i.Init(),await i.CanAutoOpen(e))){const e=R.Z.GetLocalDataService(),t=R.Z.GetValidatorModule();(e.GetICNotificationType()===P.c.GroceryAutoShow||e.GetICNotificationType()===P.c.AddedToCartPDP||e.GetICNotificationType()===P.c.SpbHomePage)&&t.SendValidationMessage(!1,_.S.GroceryCashback,this.apiResponse.retailerData?.domainName??"",[g.p.GROCERY_ITEMIZED_CASHBACK_LANDING])}return await this.handleICGroceryCashback(e,t)}if(this.isSpbCheckoutFlagActive()&&e===v.sR.AUTO_SHOW_SPB_CHECK_OUT_PAGE_NOTIFICATION)try{if(this.isCheckoutPage()){const t=this.cartExtractionService.GetAvailableCartData(),i=[];this.GetSpbCartOffers(i).then((()=>{const n=this.ProcessSpbCheckOutPage(i,t);if(n&&n.length>0){k.Q.sendControllerStorageMessage(y.Q.GroceryMatchedCartSpbOffers,JSON.stringify({value:n})),k.Q.sendControllerStorageMessage(y.Q.ICNotificationType,JSON.stringify({value:P.c.SpbCartPageNotification}));const t=new CustomEvent(r.T2,{detail:{popupOrigination:e}});window.dispatchEvent(t)}}))}}catch(e){const t=new d.Z(h.xu.SPBCheckoutNotification);t.Metadata=JSON.stringify({}),t.Domain=this.domainName,N.Z.SendLogEventMessage(t,h.R.EdgeFlyoutStatus,this.apiResponse.impressionId,e.message,h.in.Error)}return Promise.resolve(!1)}handleICGroceryCashback(e,t){if(e===v.sR.AUTO_SHOW_SPB_CASHBACK_LANDING){if(this.hasHomePageSpbData(this.apiResponse)){const e=P.c.SpbHomePage;return k.Q.sendControllerStorageMessage(y.Q.ICNotificationType,JSON.stringify({value:e})),Promise.resolve(!0)}const t=this.apiResponse.retailerData?.domainName;if(L(this.apiResponse.comparableOffers)){if(l.R.isExperimentActive(s.H.cpsPDPcontrolFlag)){const i={spbOffer:B.GetSpbOffer(this.apiResponse.comparableOffers),exp:"pdp won't be shown due to control flag"};return this.logCanAutoOpenForFeature(e,t,!1,i),Promise.resolve(!1)}const i={spbOffer:B.GetSpbOffer(this.apiResponse.comparableOffers)};return this.logCanAutoOpenForFeature(e,t,!0,i),Promise.resolve(!0)}const i=this.hasDataForPdpSpb(this.apiResponse);return i&&this.logCanAutoOpenForFeature(e,t,i),Promise.resolve(i)}if(e===v.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK_LANDING)return t?((0,D.LT)(this.apiResponse.productItemizedCashBack,this.apiResponse.userInfo,this.apiResponse.impressionId,"Pending transaction is present"),Promise.resolve(!1)):Promise.resolve(this.hasDataForPdpQt(this.apiResponse));if(e===v.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK){if(this.autoActivationOnCartPage){const e=this.ActivateQTOfferOnCartPageNotification();return Promise.resolve(e)}const e=this.IsInstantAddToCart(),t=this.hasActivatedQt()||this.shouldShowcofirmationNotification();if(e&&t)try{const e=this.apiResponse.productItemizedCashBack.offer?.value,t=this.apiResponse.productItemizedCashBack.offer?.minQty,i=this.apiResponse.productItemizedCashBack.offer?.description,n=this.apiResponse.productItemizedCashBack.offer?.expiryDate,o=this.apiResponse.productItemizedCashBack.offer?.source,r=this.apiResponse.productItemizedCashBack.offer?.id,a=this.domainName,s=(0,T.Ek)(),l=this.apiResponse.productItemizedCashBack.offer?.cashbackProducts.find((e=>e.url===s));return N.Z.StartEdgeDriver("",JSON.stringify({action:p.v.InstantAddToCart,data:{value:e,minQty:t,description:i,expiryDate:n,source:o,id:r,domain:a,productUrl:s,quotientProductDetails:l}})),Promise.resolve(!1)}catch{return Promise.resolve(!1)}return Promise.resolve(t)}return Promise.resolve(!1)}hasHomePageSpbData(e){try{const t=e?.itemLevelCashBack?.spbHomePageOffers;if(!t)return!1;if(!t.find((e=>e.shouldAutoshow&&e.offersType===f.h.SPB&&e.offers?.length>0)))return(0,D.cA)(e.userInfo,e.impressionId,"no spb home offer to autoshow for micro notification",!1),!1;const i=R.Z.GetLocalDataService(),n=i?.GetCheckoutPageData()||e,o=n?.retailerData?.getCurrentCheckoutPage();return o?.pageType===h.GV.HomePage}catch(t){(0,D.cA)(e.userInfo,e.impressionId,"has error processing home page data for SPB",!0)}return!1}static GetSpbOffer(e){const t=(e?.value||[]).find((e=>e.position===m.zE.SPB_OFFERS));if(t&&t.offer&&t.promotionInformation)return t}logCanAutoOpenForFeature(e,t,i,n){const o={Domain:t,PageUrl:(0,T.Ek)(),Status:"",PopupOrigination:e,Metadata:n?JSON.stringify(n):void 0};k.Q.sendLogEventMessage(o,h.R.AutoOpenController,this.apiResponse.impressionId,`Can ${i?"":"not "}auto open cashback notification`,h.in.Information)}IsInstantAddToCart(){const e=this.domainName,t=l.R.isExperimentActive(s.H.instantAddToCart)||l.R.isExperimentActive(s.H.instantAddToCartExperiment),i="amazon.com"===e,n=this.hasInstantAddToCartConsent();return t&&i&&n}hasInstantAddToCartConsent(){const e=!!x.Q?.GroceryInstantAddToCart;return e&&k.Q.sendControllerStorageMessage(y.Q.GroceryInstantAddToCart,JSON.stringify({value:!1})),e}IsConfirmationPage(e){const t=R.Z.GetLocalDataService(),i=t?.GetCheckoutPageData()||e,n=i?.retailerData?.getCurrentCheckoutPage();return n?.pageType===h.GV.ConfirmationPage}ActivateQTOfferOnCartPageNotification(){this.apiResponse.personalizedAdsResponse;try{const e=R.Z.GetLocalDataService(),t=e?.GetCheckoutPageData()||this.apiResponse,i=t.retailerData.getCurrentCheckoutPage(location.pathname);if(t&&this.cartExtractionService&&i?.pageType===h.GV.CheckoutPage&&this.itemLevelCashback?.itemizedCashback&&this.itemLevelCashback?.itemizedCashback?.length>0&&this.itemLevelCashback?.domainData){const e=a.Z.Create(this.itemLevelCashback.domainData);if(t.retailerData.getCurrentCheckoutPage(location.pathname)){const t=new Map,i=new Map;this.itemLevelCashback.itemizedCashback.forEach((e=>{e.cashbackProducts.forEach((n=>{t.set(n.productId,n),i.set(n.productId,e)}))}));const n=l.R.isExperimentActive(s.H.autosJatoDeals);if(this.itemLevelCashback.activatedOffers&&!n){this.itemLevelCashback.activatedOffers.forEach((e=>{e.cashbackProducts.forEach((e=>{t.delete(e.productId)}))}));const e=(0,S.Mw)("activatedProductId");e&&t.delete(e)}const o=this.cartExtractionService.GetAvailableCartData();if(o?.Products){let n;if(o.Products.forEach((o=>{const r=this.normalizeUrl(this.domainName,o.productUrl);if(r){const o=(0,A.xJ)(r,e),a=i.get(o.productId),s=t.get(o.productId);a&&s&&(n=O.Z.CreateFromUAPI(a),n.cashbackProducts=[],n.cashbackProducts.push(w.Z.CreateFromUAPI(s)))}})),null!==n&&n){(0,S.Xo)("activatedProductId",n.cashbackProducts[0].productId),n.expAfterActivatingDate||(n.expAfterActivatingDate=(new Date).getTime()+864e5),k.Q.sendControllerStorageMessage(y.Q.CartPageCashbackNotification,JSON.stringify({value:n})),k.Q.sendControllerStorageMessage(y.Q.ICNotificationType,JSON.stringify({value:P.c.CartPageNotification}));const e=new d.Z(h.xu.CartPageCashbackNotification);return e.Metadata=JSON.stringify({offer:n}),e.Domain=this.domainName,N.Z.SendLogEventMessage(e,h.R.EdgeFlyoutStatus,this.apiResponse.impressionId,"QT product for auto actiovation found",h.in.Information),!0}}}}}catch(e){const t=new d.Z(h.xu.CartPageCashbackNotification);t.Metadata=JSON.stringify({}),t.Domain=this.domainName,N.Z.SendLogEventMessage(t,h.R.EdgeFlyoutStatus,this.apiResponse.impressionId,e.message,h.in.Error)}return!1}shouldShowcofirmationNotification(){const e=(0,T.BQ)(x.Q.ICPendingTransaction)??{},t=this.apiResponse.retailerData?.domainName||"";return!!(e&&e[t]&&this.IsConfirmationPage(this.apiResponse))}hasActivatedQt(){const e=!!x.Q?.GroceryCashbackItem&&!!x.Q?.ICActivatedPending;if(e){const e=P.c.Activated;k.Q.sendControllerStorageMessage(y.Q.ICNotificationType,JSON.stringify({value:e})),k.Q.sendControllerStorageMessage(y.Q.ICActivatedPending,JSON.stringify({value:!1}))}return e}hasDataForPdpSpb(e){try{if(!(0,D.WL)(e.productItemizedCashBack))return!1;const t=P.c.PdpSPB,i={};return i.cashbackData=this.apiResponse.productItemizedCashBack,i.currentUrl=(0,T.Ek)(),i.type=t,i.pageTitle=(0,T.AL)(),(0,D.jV)(e.productItemizedCashBack,e.userInfo,e.impressionId),k.Q.sendControllerStorageMessage(y.Q.ICCurrentPageInfo,JSON.stringify({value:JSON.stringify(i)})),k.Q.sendControllerStorageMessage(y.Q.ICNotificationType,JSON.stringify({value:t})),!0}catch(t){(0,D.LT)(e.productItemizedCashBack,e.userInfo,e.impressionId,"has error processing pdp data for SPB",!0)}return!1}ProcessSpbCheckOutPage(e,t){try{if(t){const i=this.GetCartProductIds(t),n=this.GetRelatedCartSpbOffers(e),o=this.FilterActivatedOffers(n);return this.GetMatchedSpbOffers(i,o)}}catch(e){const t=new d.Z(h.xu.SPBCheckoutNotification);return t.Metadata=JSON.stringify({}),t.Domain=this.domainName,void N.Z.SendLogEventMessage(t,h.R.EdgeFlyoutStatus,this.apiResponse.impressionId,e.message,h.in.Error)}}GetMatchedSpbOffers(e,t){const i=[];return e.forEach((e=>{const n=t[e];n&&n.adsOffer&&n.adsOffer.promotionInformation&&i.push(n)})),i}GetCartProductIds(e){const t=[],i=e?.Products.map((e=>this.normalizeUrl(this.domainName,e.productUrl)));for(const e of i)if(e){const i=this.GetProductId(e);i&&t.push(i)}return t}GetProductId(e){if(this.itemLevelCashback?.domainData){const t=a.Z.Create(this.itemLevelCashback.domainData);if(e){const i=(0,A.xJ)(e,t);if(i)return i.productId}}}FilterSpbOffers(e,t){return e.forEach((e=>{e&&e.source&&"spb"===e.source&&t.push(e)})),t}FilterActivatedOffers(e){const t=[],i=Object.keys(e),n=this.apiResponse?.personalizedAdsResponse?.personalizedCashback,o=n||void 0;if(o?.adsCashback&&o?.adsCashback?.length>0){const e=o?.adsCashback;e.forEach((e=>{if(e&&e?.destinationUrl){const i=this.normalizeUrl(this.domainName,e?.destinationUrl);if(i){const e=this.GetProductId(i);e&&t.push(e)}}}))}const r=i.filter((e=>!t.includes(e))),a={};for(const t of r)a[t]=e[t];return a}GetRelatedCartSpbOffers(e){const t=[];e.forEach((e=>{if(e.cashbackData&&e.cashbackData.itemizedCashBackResponse&&e.cashbackData.itemizedCashBackResponse.offers){const i=e.cashbackData.itemizedCashBackResponse.offers;this.FilterSpbOffers(i,t)}}));const i={};for(const e of t)if(e.adsOffer&&e.adsOffer.destinationUrl){const t=this.GetProductId(new URL(e.adsOffer.destinationUrl));t&&(i[t]=e)}return i}normalizeUrl(e,t){return t?t.startsWith("http")?new URL(t):new URL(`https://www.${e}${t}`):null}hasDataForPdpQt(e){try{const t=e.retailerData?.domainName||"",i=e.itemLevelCashBack?.submittedOfferIds||[],n=e.itemLevelCashBack?.activatedOffers?.map((e=>e.id))||[];if(!(0,D.mg)(e.productItemizedCashBack,t,i,n))return!1;const o=P.c.PDP,r={};return r.cashbackData=e.productItemizedCashBack,r.currentUrl=(0,T.Ek)(),r.type=o,r.pageTitle=(0,T.AL)(),k.Q.sendControllerStorageMessage(y.Q.ICCurrentPageInfo,JSON.stringify({value:JSON.stringify(r)})),k.Q.sendControllerStorageMessage(y.Q.ICNotificationType,JSON.stringify({value:o})),(0,D.iQ)(e.productItemizedCashBack,e.userInfo,e.impressionId),!0}catch(t){(0,D.LT)(e.productItemizedCashBack,e.userInfo,e.impressionId,"Error procesing PDP data for Quotient auto show",!0)}return!1}async GetSpbCartOffers(e){return new Promise((t=>{const i=this.cartExtractionService.GetAvailableCartData();if(i?.Products&&this.isCheckoutPage()&&this.isSpbCheckoutFlagActive()){const n=i?.Products.map((e=>e.productTitle));this.searchWithKeywords(n);const o=i=>{e.push(i?.detail?.jsonResponse),e.length===n.length&&t(!0)};window.addEventListener(r.fU,o),setTimeout((()=>{window.removeEventListener(r.fU,o),t(!0)}),700)}else t(!0)}))}isCheckoutPage(){const e=I.Z.CreateCheckoutPageData(this.apiResponse).retailerData.getCurrentCheckoutPage(location.pathname);return e&&e.pageType===h.GV.CheckoutPage}isSpbCheckoutFlagActive(){return"amazon.com"===this.domainName&&l.R.isExperimentActive(s.H.spbCheckoutAutoActivation)}async searchWithKeywords(e){const t=this.apiResponse.retailerData.domainName,i=o.Z.Create(this.apiResponse),n=R.Z.GetICValidatorService();await n.Init();const r={appName:b.Z.GetClientName(),buildVersion:i?.buildVersion,enabledfeatures:l.R.GetExpRawData()},a=e.map((async e=>{try{return n.SendGetCashbackMessage(t,e,C.x.Search,r)}catch(e){return null}}));return await Promise.all(a)}}t.Z=B},43263:function(e,t,i){"use strict";i.d(t,{Z:function(){return A}});var n=i(72370),o=i(64865),r=i(4872),a=i(31656),s=i(79308);class l{constructor(){(0,n.Z)(this,"heading",void 0),(0,n.Z)(this,"price",void 0),(0,n.Z)(this,"delivery",void 0),(0,n.Z)(this,"soldBy",void 0),(0,n.Z)(this,"rating",void 0),(0,n.Z)(this,"sellerUrl",void 0),(0,n.Z)(this,"index",void 0),(0,n.Z)(this,"totalPrice",void 0),(0,n.Z)(this,"currency",void 0),(0,n.Z)(this,"addedToCart",void 0)}static Create(e){const t=new l;return t.heading=e.heading,t.price=e.price,t.soldBy=e.soldBy,t.delivery=e.delivery,t.rating=e.rating,t.sellerUrl=e.sellerUrl,t.currency=e.currency,t.addedToCart=e.addedToCart,t}}var c=l,d=i(15612),u=i(5144),h=i(93190),p=i(39088),g=i(73557),f=i(29247),m=i(36493),v=i(91495),y=i(27689),C=i(90066),b=i(1094);class S{constructor(){(0,n.Z)(this,"ProductAddedNotification",void 0),(0,n.Z)(this,"Url",void 0)}static Create(e){const t=new S;return t.ProductAddedNotification=e.ProductAddedNotification,t.Url=e.Url,t}}var x=S,T=i(44922),w=i(52056),O=i(83879),P=i(86743),A=class{constructor(){(0,n.Z)(this,"localDataService",void 0),(0,n.Z)(this,"validatorModule",void 0),(0,n.Z)(this,"isConfirmationScenario",void 0),(0,n.Z)(this,"domainName",void 0),(0,n.Z)(this,"checkoutPageUrlData",void 0)}async Init(){try{if(this.localDataService=O.Z.GetLocalDataService(),this.validatorModule=O.Z.GetValidatorModule(),this.domainName=this.localDataService.GetDomainName(),this.checkoutPageUrlData=this.localDataService.GetCheckoutPageData().retailerData.getCurrentCheckoutPage(b.Z.GetCurrentPathName()),!this.checkoutPageUrlData||!this.ShouldTriggerOtherSellers(this.checkoutPageUrlData))return;this.ManageOtherSellersData(b.Z.GetCurrentPathName(),v.Q.storageObjStr,v.Q.rawStorageObj);const e=this.GetOtherSellersNotificationData(b.Z.GetCurrentPathName(),v.Q.rawStorageObj);this.isConfirmationScenario=this.ValidateOtherSellerConfirmationScenario(this.domainName,this.checkoutPageUrlData,e)}catch(e){}}GetPopupOriginationList(){return[g.sR.AUTO_SHOW_OTHER_SELLERS]}async CanAutoOpenForFeature(e){if(!this.checkoutPageUrlData||!this.ShouldTriggerOtherSellers(this.checkoutPageUrlData))return!1;if(a.R.getServiceExperimentValue(r.H.disableNotificationForSimilarSellers)||!(0,P.XB)()&&this.validatorModule.validationMsgNum>0)return this.ValidateOtherSellersScenario(this.domainName,this.checkoutPageUrlData,this.localDataService.GetMarket(),this.isConfirmationScenario),!1;this.validatorModule.SendValidationMessage(!1,T.S.CheckingOtherSellers,this.domainName);const t=await this.ValidateOtherSellersScenario(this.domainName,this.checkoutPageUrlData,this.localDataService.GetMarket(),this.isConfirmationScenario);return t&&this.validatorModule.SendValidationMessage(!1,T.S.OtherSellers,this.domainName,[h.p.OTHER_SELLERS],!1,!(0,P.XB)()),t}async PostValidation(){}ShouldTriggerOtherSellers(e){return void 0!==e.otherSellerSelectors&&this.IsVersionAllowed(p.W1,e.otherSellerSelectors.jSVersionThreshold)}isOtherSellersScenario(e){const t=e?.otherSellerSelectors?.otherSellersOverlayLinkSelector;return!(!t||(0,o.TF)(t))&&C.Z.HasVisibleElement(t)}CheckOtherSellersAutoOpen(e){const t=e.otherSellerSelectors.otherSellerLowestPriceSelector,i=C.Z.GetFirstVisibleElement(t);if(i&&i.innerText){const i=w.Z.GetOrderTotalString(e.orderTotalDataElementSelector),n=new c;if(n.price=w.Z.GetOrderTotalString(t),n.delivery="",!this.OtherSellerHasLowerPrice("amazon",i,n,""))return!1}return!0}async StoreOtherSellersInfo(e,t,i){if(!t)return null;if(!this.ValidateDataFields(e,t))return null;const n="OtherSellersData_"+b.Z.GetCurrentPathName(),o="OtherSellersIframe";try{const r=t.otherSellerSelectors.otherSellersOverlayLinkSelector,a=C.Z.GetFirstVisibleElement(r);if(a){const l=a.getAttribute("href");if(l&&e.includes("amazon")){const r=this.CreateIframe(o,l);document.body.insertBefore(r,document.body.children[0]);const a=await this.CollectOtherSellersInfo(e,t,o,i);try{this.RankOtherSellers(a)}catch(t){const i="Error while ranking other sellers. "+t,n=new s.Z;n.SetResultData(e,0,(0,m.K)(a?.productPrice??""),"",a?.currency??"$","Error"),w.Z.SendLogEventMessage(n,u.R.OtherSellers,this.validatorModule.impressionId,i,u.in.Information)}if(a&&a.otherSellers?.length>0)return w.Z.SendStorageMessage(n,JSON.stringify({value:JSON.stringify(a)})),a}else if("walmart.com"===e){const a=this.CreateIframe(o,b.Z.GetCurrentPathName());document.body.appendChild(a),await f.ZP.WaitForCondition((async()=>{const e=document.querySelectorAll("#"+o)[0],t=e?.contentDocument?.body,i=t?.querySelector(r);return void 0!==i?.innerText}),13e4);const s=document.querySelectorAll("#"+o)[0],l=s?.contentDocument?.body,c=l?.querySelector(r);c&&(c.click(),await setTimeout((()=>{c.click()}),3e3));const d=await this.CollectOtherSellersInfo(e,t,o,i);if(d&&d.otherSellers?.length>0)return w.Z.SendStorageMessage(n,JSON.stringify({value:JSON.stringify(d)})),d}}}catch(t){const i="Error while getting collecting other sellers data. "+t,n=new s.Z;n.SetResultData(e,0,0,"","","Error"),w.Z.SendLogEventMessage(n,u.R.OtherSellers,this.validatorModule.impressionId,i,u.in.Information)}return null}ResetOtherSellersNotificationFlag(){w.Z.SendStorageMessage("OtherSellersNotificationData_"+b.Z.GetCurrentPathName(),JSON.stringify({value:null}))}ValidateOtherSellerConfirmationScenario(e,t,i){return!(!this.ShouldTriggerOtherSellers(t)||!this.isOtherSellersConfirmationScenario(i)||(this.ResetOtherSellersNotificationFlag(),0))}IsVersionAllowed(e,t){if((0,o.TF)(t))return!0;try{return parseFloat(e)>=parseFloat(t)}catch(e){}return!1}isOtherSellersConfirmationScenario(e){if(e?.ProductAddedNotification){if(e?.Url===b.Z.GetCurrentPathName())return!0;this.ResetOtherSellersNotificationFlag()}return!1}ManageOtherSellersData(e,t,i){const n="OtherSellersData_"+e;!(0,o.TF)(i[n])&&w.Z.DeleteKeyFromPersistentStorage(n);const r=t.replace(/[,{]"OtherSellersData_[^\s{]*":null/g,"").replace(/[,{]"OtherSellersConfirmationData_[^\s{]*":null/g,"").match(/[,{]"OtherSellersData_[^\s{]*":|[,{]"OtherSellersConfirmationData_[^\s{]*":/g);r&&r.length>20&&this.ClearOtherSellersStorage(r,i)}ClearOtherSellersStorage(e,t){if(null!==e&&null!=t)for(const i of e){const e=i.slice(2,-2);if((0,o.TF)(t[e])){const e="Tried to delete key that doesn't exist from persistent storage",t=new s.Z;t.SetResultData((0,y.S8)(),0,0,"","","Error"),w.Z.SendLogEventMessage(t,u.R.OtherSellers,this.validatorModule.impressionId,e,u.in.Information)}else w.Z.DeleteKeyFromPersistentStorage(e)}}GetOtherSellersNotificationData(e,t){const i="OtherSellersNotificationData_"+e;return(0,o.TF)(t[i])?new x:x.Create((0,y.BQ)(t[i]))}async ValidateOtherSellersScenario(e,t,i,n){return!!this.isOtherSellersScenario(t)&&(n?(this.TryStoreOtherSellersInfo(e,t,i,!1),!1):this.ShouldAutoShowForOtherSellers(e,v.Q.OtherSellersAutoShowCount??0,v.Q.OtherSellersLastAutoShowTime)?e.includes("amazon")&&!this.CheckOtherSellersAutoOpen(t)?(this.TryStoreOtherSellersInfo(e,t,i,!1),!1):await this.TryStoreOtherSellersInfo(e,t,i,!0):(this.TryStoreOtherSellersInfo(e,t,i,!1),!1))}async TryStoreOtherSellersInfo(e,t,i,n){const o=await this.StoreOtherSellersInfo(e,t,i),r=null!==o;if(!r)return!1;let a=!0;if("amazon.com"===e&&o&&o.otherSellers?.length>0){const e=o.otherSellers[0].heading?.toLowerCase()??"";a=e.includes("new")&&!e.includes("like")}return!!(r&&a&&n)}ShouldAutoShowForOtherSellers(e,t,i){if((0,o.TF)(i)||t<2)return!0;const n=this.ParseLastAutoShowTime(e,i);return n<=0||Date.now()-n>72e5&&(w.Z.SendStorageMessage("OtherSellersAutoShowCount",JSON.stringify({value:null})),w.Z.SendStorageMessage("OtherSellersLastAutoShowTime",JSON.stringify({value:null})),!0)}ParseLastAutoShowTime(e,t){try{return Date.parse(t)}catch(t){const i="Error while parsing other sellers autoshow date. "+t,n=new s.Z;return n.SetResultData(e,0,0,"","","Error"),w.Z.SendLogEventMessage(n,u.R.OtherSellers,this.validatorModule.impressionId,i,u.in.Information),0}}OtherSellerHasLowerPrice(e,t,i,n,o,r){try{const a=(0,m.K)(t);let s=(0,m.K)(i.price);const l=this.GetDeliveryRegex(e,n,r??"");let c=0;const d=i.delivery.trim().match(l);d&&d.length>0&&(c=(0,m.K)(d[0])),c>0&&(s+=c),i.totalPrice=s;const u=a-s;if(a&&s&&u>=(o??.6)&&u/a>=.01)return!0}catch(e){}return!1}GetDeliveryRegex(e,t,i){if("walmart.com"===e)return/\$[0-9.,]+/;try{const e=(0,m.Cl)(t,i),n="^"+(0,m.So)(e)+"\\s*[0-9.,]+",o="[0-9.,]+\\s*"+(0,m.So)(e);return new RegExp(n+"|"+o)}catch(t){switch(e){case"amazon.com":return/^\$[0-9.,]+/;case"amazon.co.uk":return/^\£[0-9.,]+/;default:return/\$[0-9.,]+/}}}async CollectOtherSellersInfo(e,t,i,n){const r=new d.Z;r.otherSellers=[];const a=t.otherSellerSelectors;await f.ZP.WaitForCondition((async()=>{const e=document.querySelectorAll("#"+i)[0],t=e?.contentDocument?.body,n=t?.querySelector(a.otherSellerOfferElementSelector);return void 0!==n?.innerText}),13e4);const s=document.querySelectorAll("#"+i)[0],l=s?.contentDocument?.body,u=l?.querySelectorAll(a.otherSellerOfferElementSelector);if(!u)return r;let h=w.Z.GetOrderTotalString(t.orderTotalDataElementSelector);h?.includes("(")&&h?.includes(")")&&(h=h.slice(0,h.indexOf("("))),r.productPrice=h,r.currency=(0,m.cU)(h);let p=0;for(const t of u){if(0===p&&"walmart.com"===e){p+=1;continue}const i=new c,o=t.querySelector(a.otherSellerPriceSelector);i.price=o?.innerText??"",i.currency=(0,m.cU)(o?.innerText??"");const s=t.querySelector(a.otherSellerDeliverySelector);if(i.delivery=s?.innerText??"","walmart.com"===e){const e=o?.innerText?.split("\n");if(e&&(i.price=e[0],i.currency="$",e.length>1)){const t=e[1];!t.toLowerCase().includes("free")&&i.delivery&&(i.delivery+=t)}}if(!this.OtherSellerHasLowerPrice(e,h,i,i.currency,void 0,n))break;const l=t.querySelector(a.otherSellerHeadingSelector),d=t.querySelector(a.otherSellerNameSelector),u=t.querySelector(a.otherSellerRatingSelector),g=/a-star-mini-([0-9\-]+)/.test(u?.className)?RegExp.$1:"-1";i.heading=l?.innerText,i.soldBy=d?.innerText,i.sellerUrl=d?.getAttribute("href")??"","-1"!==g&&(i.rating=parseFloat(g.replace("-","."))),i.index=p,r.otherSellers.push(i),p+=1}const g=l?.querySelector(a.productImageSelector);return g&&!(0,o.TF)(g.src)&&(r.productImage=g.src),r.productUrl=b.Z.GetCurrentPathName(),r.dataCreationTime=Date.now(),r}ValidateDataFields(e,t){const i=t.otherSellerSelectors;if(void 0===i)return!1;const n=f.ZP.IsValidDataField(i.otherSellersOverlayLinkSelector)&&f.ZP.IsValidDataField(i.otherSellerOfferElementSelector)&&f.ZP.IsValidDataField(i.otherSellerHeadingSelector)&&f.ZP.IsValidDataField(i.otherSellerPriceSelector)&&f.ZP.IsValidDataField(i.otherSellerDeliverySelector)&&f.ZP.IsValidDataField(i.productImageSelector)&&f.ZP.IsValidDataField(i.otherSellerNameSelector)&&f.ZP.IsValidDataField(i.otherSellerAddButtonSelector)&&f.ZP.IsValidDataField(i.otherSellerAddedConfirmationSelector),o=f.ZP.IsValidDataField(i.otherSellerRatingSelector),r=f.ZP.IsValidDataField(t.errorMessageSelector);if(e.includes("amazon"))return n&&o;if("walmart.com"===e)return n&&r;{const t="Other sellers scenario for wrong domain: "+e,i=new s.Z;return i.SetResultData(e,0,0,"","","Error"),w.Z.SendLogEventMessage(i,u.R.OtherSellers,this.validatorModule.impressionId,t,u.in.Information),!1}}CreateIframe(e,t){const i=document.createElement("iframe");return i.id=e,i.src=t,i.style.position="absolute",i.style.width="0",i.style.height="0",i.style.border="none",i.style.visibility="hidden",i.style.left="0",i.style.top="0",i.hidden=!0,i.tabIndex=-1,i.title="empty",i.style.display="none",i}RankOtherSellers(e){const t=[],i=[];for(const n of e.otherSellers){let o=!1;if(n.heading?.toLowerCase().includes("new")){const t=n.totalPrice,i=(0,m.K)(e.productPrice);let r=1;n.heading?.toLowerCase().includes("like new")&&(r=3),i-t>=r&&(o=!0)}o?t.push(n):i.push(n)}return e.otherSellers=t.concat(i),e}}},20546:function(e,t,i){"use strict";var n=i(72370),o=i(56005),r=i(3634),a=i(5144),s=i(93078),l=i(73557),c=i(55590),d=i(29247),u=i(91495),h=i(44092),p=i(91897),g=i(27689),f=i(90066),m=i(82315),v=i(23498),y=i(9839),C=i(52056),b=i(56854);t.Z=class{constructor(){(0,n.Z)(this,"apiResponse",void 0),(0,n.Z)(this,"BestCouponConsentData",void 0),(0,n.Z)(this,"domainName",void 0),(0,n.Z)(this,"aaConsentData",void 0)}async Init(){this.apiResponse=m.Z.getApiResponse(),this.domainName=this.apiResponse.retailerData?.domainName??(0,g.S8)(),this.BestCouponConsentData=(0,g.BQ)(u.Q.ProductBestCouponConsent),this.apiResponse.retailerData?.aaConsentEnabled&&(this.aaConsentData=(0,g.BQ)(u.Q.rawStorageObj[o.Z.GetAAConsentStorageKey(this.domainName)]))}GetPopupOriginationList(){return[l.sR.AUTO_SHOW_PRODUCT_BEST_COUPON_CONSENT]}async CanAutoOpenForFeature(e){const t=this.apiResponse.retailerData.allProductPages;if((0,b.r)()&&t.length>0)for(let e=0;e<t.length;e++)if(this.apiResponse.retailerData.allProductPages[e].backgroundAAEnabled)return!1;return!!("true"!==(0,h.Lt)("CanOpenAAConsent")&&!this.isAutoTriggeredAAAllowed()&&this.apiResponse.productBestCoupon?.coupon||await this.searchHasBestCoupon(e))}async PostValidation(){}isAutoApplyingBestCouponAllowed(){if(!this.BestCouponConsentData||!this.BestCouponConsentData[this.domainName]?.allowed)return!1;const e=(0,p.r2)(this.BestCouponConsentData[this.domainName].timeStamp);return e>=0&&e<1||(delete this.BestCouponConsentData[this.domainName],C.Z.SendStorageMessage(c.Q.ProductBestCouponConsent,JSON.stringify({value:JSON.stringify(this.BestCouponConsentData)})),!1)}AutoApplyBestCoupon(){this.BestCouponConsentData&&this.BestCouponConsentData[this.domainName]?.productBestCoupon&&(C.Z.StartEdgeDriver("",JSON.stringify({action:s.v.ApplyProductBestCoupon,data:{productBestCoupon:this.BestCouponConsentData[this.domainName].productBestCoupon}})),v.Z.fireAffiliateUrl(this.apiResponse),delete this.BestCouponConsentData[this.domainName],C.Z.SendStorageMessage(c.Q.ProductBestCouponConsent,JSON.stringify({value:JSON.stringify(this.BestCouponConsentData)})))}isAutoTriggeredAAAllowed(){if(!this.aaConsentData?.allowed)return!1;const e=(0,p.r2)(this.aaConsentData.timeStamp);return e>=0&&e<1}async searchHasBestCoupon(e){const t=this.apiResponse.retailerData.allCheckoutPages.find((e=>e.pageType===a.GV.SearchPage)),i=t?.checkoutPageUrl,n=window.location.href.toLocaleLowerCase();let o=!1;if(i&&n&&t.productTitleSearchSelector){const e=i.split(",");for(const t of e){const e=new RegExp(t).exec(n);if(e&&e.length>0){o=!0;break}}}return t&&o&&d.ZP.WaitForCondition((async()=>f.Z.HasVisibleElement(t.productTitleSearchSelector)),1e3).then((async()=>{const i=document.querySelectorAll(t.productTitleSearchSelector);if(i?.length>0)for(let t=0;t<i.length&&t<3;t++){let n=i[t].textContent?.replace(/[\n\r]+|[\s]{2,}/g," ")?.trim()??"";const o=this.apiResponse.retailerData?.domainName??(0,g.S8)();"macys.com"===o&&n&&(n=n.replace(/[\w]+ /g,"")),await this.fetchBestCouponForProduct(n,o).then((t=>{if(void 0!==t?.coupon&&void 0!==t?.couponType){t.product=n,y.Q.sendControllerStorageMessage(c.Q.ProductBestCoupon,JSON.stringify({value:JSON.stringify(t)}));const i=new CustomEvent(r.T2,{detail:{popupOrigination:e}});return window.dispatchEvent(i),!0}}))}})),!1}async fetchBestCouponForProduct(e,t){const i={Domain:t,ProductName:e},n={headers:{"Content-Type":"application/json"},method:"POST",body:JSON.stringify(i)};try{const e="https://www.bing.com/api/shopping/v1/savings/cartProcessing/getProductBestCoupon",t=await fetch(e,n);return await t.json()}catch(e){}}}},73688:function(e,t,i){"use strict";var n=i(72370),o=i(51329),r=i(4872),a=i(31656),s=i(93190),l=i(3634),c=i(88767),d=i(73557),u=i(55590),h=i(96658),p=i(71455),g=i(33491),f=i(27689),m=i(9448),v=i(44922),y=i(52056),C=i(83879),b=i(86743),S=i(84178);class x{constructor(){(0,n.Z)(this,"lastUrl",""),(0,n.Z)(this,"validationMessageService",new S.Z)}InvokeOEMScenario(e,t,i){let n=!1;const o=this.ExtractVehicleDetails(i?.autosDataSelector);return this.isAutosCommunityDomain(e)?!0!==this.autosCommunityDomainIgnoreVehicleDetails(e)&&null==o||this.InvokeSERPScenario(t?.retailerData?.domainName,o):!0===t?.autos?.isAutosSupportedDomain&&this.passCheckAutoShowInStorage(p.a.AutosReviewString)&&this.canOEMReviewsAutoShow(i?.autosDataSelector)&&(this.InvokeSERPScenario(t?.retailerData?.domainName,o),this.updateNotificationModuleToStorage(c.yA.REVIEW),this.sendCanOpenMessage(e),this.AddGlobalCoolDownSignal(),n=!0),n}processCashBackResponseForAutosMarketplace(e){const t={};t.autosData=e,t.currentUrl=(0,f.Ek)();const i=JSON.stringify(t),n=(0,f.S8)();if(this.validationMessageService.SendStringStorageMessage(u.Q.AutosMarketplace,i),this.updateAddressBar(),this.isLastNotificationInsideCooldownPeriod())return;const o=this.CanMyGarageAutoShow(e?.vehicleInfo);if(o&&this.CanMyGarageAutoShowFirst(e?.vehicleInfo)&&this.passCheckAutoShowInStorage(p.a.AutosMyGarageString))return this.updateNotificationModuleToStorage(c.yA.MYGARAGE),this.sendCanOpenMessage(n),void this.AddGlobalCoolDownSignal();e?.shouldAutoshow&&this.canComparableOffersAutoshow(e?.comparableOffers)&&this.passCheckAutoShowInStorage(p.a.AutosMarketplaceString)?(this.updateNotificationModuleToStorage(c.yA.LISTING),this.sendCanOpenMessage(n),this.AddGlobalCoolDownSignal()):o&&this.passCheckAutoShowInStorage(p.a.AutosMyGarageString)?(this.updateNotificationModuleToStorage(c.yA.MYGARAGE),this.sendCanOpenMessage(n),this.AddGlobalCoolDownSignal()):e?.shouldAutoshow&&this.canReviewsAutoShow(e?.ratingReview)&&this.passCheckAutoShowInStorage(p.a.AutosReviewString)&&(this.updateNotificationModuleToStorage(c.yA.REVIEW),this.sendCanOpenMessage(n),this.AddGlobalCoolDownSignal())}canComparableOffersAutoshow(e){if(e&&e?.length>0){let t=!1;return e.forEach((e=>{e&&e?.offerLevelSignals&&"true"===e?.offerLevelSignals?.autoshow&&(t=!0)})),t}return!1}canReviewsAutoShow(e){return!1}passCheckAutoShowInStorage(e,t){const i=e+t,n=(0,g.Mw)(i);if(null==n)return(0,g.Xo)(i,(new Date).toString()),!0;try{let e=216e5;const t=new Date,i=new Date(n);if(t.getTime()-i.getTime()<e)return!1}catch{}return(0,g.Xo)(i,(new Date).toString()),!0}AddGlobalCoolDownSignal(){(0,g.Xo)(p.a.AutosGlobalCoolDownString,(new Date).toString())}isLastNotificationInsideCooldownPeriod(){const e=(0,g.Mw)(p.a.AutosGlobalCoolDownString);if(null==e)return!1;try{const t=3e5,i=new Date,n=new Date(e);if(i.getTime()-n.getTime()<t)return!0}catch{return!1}return!1}updateNotificationModuleToStorage(e){this.validationMessageService.SendStringStorageMessage(u.Q.AutosMarketplaceNotification,e)}InvokeSERPScenario(e,t){if(this.lastUrl===(0,f.Ek)())return;this.lastUrl=(0,f.Ek)();const i=[];i.push({keyword:""});const n={domainName:e,queries:i,autosQuery:{url:(0,f.Ek)(),vehicleDetails:t,title:(0,f.AL)()},queryType:"search"};y.Z.SendMessage(m.H.GetCashBack,[JSON.stringify(n)])}sendCanOpenMessage(e){if((0,b.XB)()){const e=new CustomEvent(l.T2,{detail:{popupOrigination:d.sR.AUTO_SHOW_AUTOS_MARKETPLACE}});window.dispatchEvent(e)}else C.Z.GetValidatorModule().SendValidationMessage(!0,v.S.AutosMarketplace,e,[s.p.AUTOS_MARKETPLACE])}CanMyGarageAutoShow(e){if(!a.R.isExperimentActive(r.H.autosMyGarageEntryPoint)&&!a.R.isExperimentActive(r.H.autosMyGarageEntryPointV2)&&!a.R.isExperimentActive(r.H.autosMarketValueV2))return!1;const t=new o.Z(e);return t?.isValid}CanMyGarageAutoShowFirst(e){if(!a.R.isExperimentActive(r.H.autosMyGarageEntryPoint))return!1;const t=new o.Z(e);return t?.isValid}ExtractVehicleDetails(e){let t=null;try{if(void 0===e)return t;const i=JSON.parse(e),n=i?.Make||i?.ratingReview?.metaData?.make,o=i?.Model||i?.ratingReview?.metaData?.model,r=i?.Year||(new Date).getFullYear();return null===n&&null===o&&null===r?null:(t={Make:n,Model:o,Year:r},t)}catch(e){return t}}canOEMReviewsAutoShow(e){try{if(void 0===e)return!1;const t=JSON.parse(e);return t?.ratingReview?.videoReviews?.reviews?.length>0}catch(e){return!1}}isAutosCommunityDomain(e){return null!=e&&x.CommunityDomains.has(e)}autosCommunityDomainIgnoreVehicleDetails(e){return null!=e&&!0===x.CommunityDomains.get(e)}updateAddressBar(){(new S.Z).SendMessage(m.H.UpdateAddressBar,[JSON.stringify({type:h.r.AutosMarketplaceOffers})])}}(0,n.Z)(x,"CommunityDomains",new Map([["reddit.com",!1],["motortrend.com",!0]])),t.Z=x},7664:function(e,t,i){"use strict";i.d(t,{X:function(){return $}});var n=i(72370),o=i(27900),r=i(5144);const a="TravelDataStorageInfo";class s{constructor(){(0,n.Z)(this,"Price",void 0),(0,n.Z)(this,"TravelDataCreationTime",void 0),(0,n.Z)(this,"CheckoutId",void 0),(0,n.Z)(this,"StartDate",void 0),(0,n.Z)(this,"EndDate",void 0),(0,n.Z)(this,"Currency",void 0),(0,n.Z)(this,"Name",void 0),(0,n.Z)(this,"DomainType",void 0),(0,n.Z)(this,"flightLegs",void 0),(0,n.Z)(this,"isRoundTrip",void 0),(0,n.Z)(this,"PageUrl",void 0)}}var l=i(33491),c=i(29247),d=i(43686),u=i(18435),h=i(84830),p=i(71544),g=i(4872);class f{constructor(){(0,n.Z)(this,"name",void 0),(0,n.Z)(this,"startDate",void 0),(0,n.Z)(this,"endDate",void 0)}static Create(e){const t=new f;return t.name=e.name,t.startDate=e.startDate,t.endDate=e.endDate,t}}var m=f,v=i(39088),y=i(82960),C=i(3634),b=i(90066),S=i(55590),x=i(36493),T=i(14440);class w{}(0,n.Z)(w,"ProductIdsGetter",{"amazon.com":e=>{const t=document.querySelectorAll(e);if(t){let e="";return t.forEach((t=>{const i=t.defaultValue.split("|")[0];e+=i+w.sep})),e}return null},"walmart.com":e=>{const t=document.querySelector(e);if(t){const e=t?.src,i=/item_ids=([^&]*)/,n=e?.match(i);let o="";return n&&n.length>=2&&n[1].split("%2C").forEach((e=>{o+=e+w.sep})),o}return null},"jcpenney.com":e=>{const t=document.querySelectorAll(e);if(t){let e="";return t.forEach((t=>{const i=t.dataset.ppid;e+=i+w.sep})),e}return null}}),(0,n.Z)(w,"sep","<SEP>");var O=w;class P{constructor(){(0,n.Z)(this,"checkoutUrl",void 0),(0,n.Z)(this,"domain",void 0),(0,n.Z)(this,"domainType",void 0),(0,n.Z)(this,"checkoutId",void 0),(0,n.Z)(this,"startDate",void 0),(0,n.Z)(this,"endDate",void 0),(0,n.Z)(this,"name",void 0),(0,n.Z)(this,"currency",void 0),(0,n.Z)(this,"price",void 0),(0,n.Z)(this,"flightLegs",void 0),(0,n.Z)(this,"isRoundTrip",void 0)}static Create(e){const t=new P;return t.domain=e.domain,t.price=e.price,t.currency=e.currency,t.checkoutUrl=e.checkoutUrl,t.domainType=e.domainType,t.startDate=e.startDate,t.endDate=e.endDate,e.flightLegs?.forEach((e=>{t.flightLegs.push(m.Create(e))})),t}}var A=P,E=i(27689),k=i(11849),I=i(52056),D=i(83879),_=i(93970),N=i(31656),R=i(64865),M=i(91495),L=i(57459);function B(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function F(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?B(Object(i),!0).forEach((function(t){(0,n.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):B(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}class U{constructor(){(0,n.Z)(this,"cartExtractionSuccessful",void 0),(0,n.Z)(this,"mutationObserver",void 0),(0,n.Z)(this,"isPersonalizationDataConsentEnabled",void 0),(0,n.Z)(this,"onCartExtractionCallback",void 0)}subscribe(e){this.onCartExtractionCallback=e}async Init(){const e=D.Z.GetLocalDataService(),t=e.GetCheckoutPageData();if(this.isPersonalizationDataConsentEnabled=t.userInfo?.isPersonalizationDataConsentEnabled??e.IsP13nEnabled()??!1,!t.retailerData)return;this.logInfo("Starting cart collection",t.retailerData.domainName??"","","");const i=e.GetIsFinalCheckoutPage(),n=(0,E.uf)(t?.market,t.retailerData?.exclusiveMarket),o=e.GetImpressionId(),a=e.GetDomainName(),s=t?.retailerData?.cartMonitorUrl,l=t.retailerData.getCurrentFinalCheckoutPage(),c=t?.retailerData?.storeCartInEdgeStorage||!1,d=e.GetIsAOCActive(),u=t.retailerData.getCurrentAutomatedSelectorsPage(location.href);if(i){const e=y.Z.uuidv4();this.logInfo("Attempting cart extraction from final checkout page",a,o,e),this.TryCheckAndCollectCartInformation(a,o,l,n,d,u,!1,t.isCashbackEstimationSupportedForDomain,c,s,void 0,e)}const h=this.ShouldAddCartButtonListener(t.retailerData.getCurrentCheckoutPage(),a);if(h.shouldAddListener&&h.cartButtonSelector){const e=y.Z.uuidv4();this.AddCartButtonListener(h.cartButtonSelector,location.pathname,t,a,o,n,t,c,s,d,u,e)}const p=t.retailerData?.getCurrentCheckoutPage(location.pathname);if(!p)return;const g=p.pageType??r.GV.CheckoutPage;if(g===r.GV.CheckoutPage||i){const e=this.dateToString(new Date);I.Z.SendStorageMessage(S.Q.CheckoutPageNavigatedTime,JSON.stringify({value:e}))}if(g===r.GV.CheckoutPage)if(i){const e=y.Z.uuidv4();this.TryShouldAttemptCartCollectionAgain(a,o,p,n,d,u,p?.automatedCartExtractionEnabled,t.isCashbackEstimationSupportedForDomain,c,void 0,e)}else{const e=y.Z.uuidv4();this.logInfo("Attempting cart extraction from not final checkout page",a,o,e),this.TryCheckAndCollectCartInformation(a,o,p,n,d,u,p?.automatedCartExtractionEnabled,t.isCashbackEstimationSupportedForDomain,c,s,void 0,e)}if(g===r.GV.ProductPage){const e=y.Z.uuidv4();this.logInfo("Attempting cart extraction from product page",a,o,e),this.CollectCartInfoFromProductPage(a,t,o,n,d,u,c,s,e)}}async PostValidation(){}dateToString(e){return`${e.getFullYear()}-${String(e.getMonth()+1).padStart(2,"0")}-${String(e.getDate()).padStart(2,"0")} ${String(e.getHours()).padStart(2,"0")}:${String(e.getMinutes()).padStart(2,"0")}:${String(e.getSeconds()).padStart(2,"0")}`}async TryShouldAttemptCartCollectionAgain(e,t,i,n,o,a,s,l,c,d,u){this.ShouldAttemptCartCollectionAgain(i,s).then((r=>{r&&this.TryCheckAndCollectCartInformation(e,t,i,n,o,a,s,l,c,d,void 0,u)})).catch((i=>{const n={domain:e,cartUrl:location.pathname};this.LogCartExtractionEvent(n,r.R.CartExtractionError,i?.message,r.in.Error,t,u)}))}async ShouldAttemptCartCollectionAgain(e,t){return e&&(e?.cartSelectors||!0===t||e?.travelCheckoutSelectors)?(await c.ZP.WaitForCondition((async()=>void 0!==this.cartExtractionSuccessful),3e4),!0!==this.cartExtractionSuccessful):(this.notifyCartDataListeners(),!1)}async TryCheckAndCollectCartInformation(e,t,i,n,o,a,s,l,c,d,u,h){i?.travelCheckoutSelectors&&this.CheckAndCollectTravelCheckoutInformation(e,t,i.travelCheckoutSelectors,n,c).catch((i=>{const n={domain:e,cartUrl:location.pathname,isTravel:!0};this.LogCartExtractionEvent(n,r.R.CartExtractionError,i?.message,r.in.Error,t,h)})),this.CheckAndCollectCartInformation(e,t,i,n,o,a,s,l,c,d,u,i?.getProductNamesFromImg,h).catch((i=>{const n={domain:e,cartUrl:location.pathname};this.LogCartExtractionEvent(n,r.R.CartExtractionError,i?.message,r.in.Error,t,h)}))}GetLastTravelData(){const e=(0,l.Mw)(a);return e&&!(0,R.TF)(e)?JSON.parse(e):null}async WaitForBlockedCouponsThenGetCartData(){return await c.ZP.WaitForCondition((async()=>!0!==this.GetBlockedCouponsRequestPending()),1e4,1e3),this.GetLastCartData()}async WaitForCartExtractionAndBlockedCouponsThenGetCartData(){return await c.ZP.WaitForCondition((async()=>!this.GetBlockedCouponsRequestPending()&&void 0!==this.cartExtractionSuccessful),1e4,1e3),this.GetLastCartData()}GetLastCartExtractionId(){const e=this.GetLastCartData();if(e&&e?.ExtractionId?.length>0)return e.ExtractionId}GetLastCartData(){const e=(0,l.Mw)(o.OY);return e&&!(0,R.TF)(e)?JSON.parse(e):null}GetFastCart(){try{const e=(0,l.Mw)(o.hm);if(e&&!(0,R.TF)(e))return JSON.parse(e)}catch(e){}return null}GetAvailableCartData(){const e=this.GetLastCartData(),t=(0,l.Mw)(o.hm);let i=null;t&&!(0,R.TF)(t)&&(i=JSON.parse(t));const n=i?.CartDataCreationTime??0;return e?.CartDataCreationTime&&e?.CartDataCreationTime>n?e:i}async CheckAndCollectCartInformation(e,t,i,n,o,a,s,l,d,u,h,p,g){if(!i||!i?.cartSelectors&&!0!==s&&!a?.details?.productName){this.cartExtractionSuccessful=!1;const i="Unable to get cart data: No Selectors",n={cartId:"",cartUrl:location.pathname,domain:e};return"rei.com"===e&&(n.cartUrl=location.pathname+location.hash),void this.LogCartExtractionEvent(n,r.R.CartExtractionError,i,r.in.Error,t,g)}const f=i?.pageType===r.GV.ProductPage,m=this.GetLastCartData(),v=performance.now(),y=i.orderTotalDataElementSelector;let C={OrderTotal:-1,Currency:(0,x.N6)(n)??"",PageCurrency:""};c.ZP.IsValidDataField(y)&&(C=await c.ZP.WaitForCondition((async()=>b.Z.RunQuerySelectorAll(y)?.length>0),5e3).then((async()=>await k.Z.WaitAndGetCartValue(y,n))).catch((i=>{const n={cartId:m?.CartId??"",cartUrl:location.pathname,domain:e};return this.LogCartExtractionEvent(n,r.R.CartExtractionError,i?.message,r.in.Error,t,g),C}))),C.OrderTotal>0||(C=await k.Z.WaitAndGetCartValue2(y,n));const S=performance.now(),T=this.GetTimeDiff(v,S);this.logInfo(`Cart value extracted. timeToExtract: ${T} ms, extracted total: ${C?.OrderTotal}`,e,t,g);try{const r=new URL(window.location.href);u&&this.MonitorCart(e,t,r,i,n,o,a,s,l,d,u,g)}catch(i){const n={cartId:m?.CartId??"",cartUrl:location.pathname,domain:e};this.LogCartExtractionEvent(n,r.R.CartExtractionError,"error adding cart monitor: "+i?.message,r.in.Error,t,g)}if(m&&!this.ShouldCollectStorageData(C,m))return this.notifyCartDataListeners(),void this.logInfo("Stopping cart extraction: cart hasn't changed",e,t,g);if(!i?.cartSelectors&&!a?.details?.productName)return this.logInfo("Extracting cart from automatedSelectorsData",e,t,g),void D.Z.GetAutomaticCartExtractionService().TryCollectCartInformation(e,C,n,t,_.ZP.traceId,o,m?.CartId);const w=i.cartSelectors;try{await this.CollectCartInformation(e,C,w,t,i,o,n,a,m?.CartId,d,f,h,p,g)}catch(i){const n={cartId:m?.CartId??"",cartUrl:location.pathname,domain:e};"rei.com"===e&&(n.cartUrl=location.pathname+location.hash),this.LogCartExtractionEvent(n,r.R.CartExtractionError,i?.message,r.in.Error,t,g)}const O=performance.now(),P=this.GetTimeDiff(v,O);this.logInfo(`Cart extraction finished. Total time: ${P} ms`,e,t,g)}async TryCheckAndCollectTravelCheckoutInformation(e,t,i,n){this.CheckAndCollectTravelCheckoutInformation(e,t,i,n).catch((e=>{}))}async CheckAndCollectTravelCheckoutInformation(e,t,i,n,o){if(!i)return;const a=this.GetLastTravelData(),s=i.priceSelector;let l={OrderTotal:-1,Currency:"$",PageCurrency:""};if(c.ZP.IsValidDataField(s)&&(l=await c.ZP.WaitForCondition((async()=>b.Z.RunQuerySelectorAll(s)?.length>0),5e3).then((async()=>await k.Z.WaitAndGetCartValue2(s,n))).catch((i=>{const n={cartId:a?.CheckoutId??"",cartUrl:location.pathname,domain:e};return this.LogCartExtractionEvent(n,r.R.CartExtractionError,i?.message,r.in.Error,t),l}))),!a||this.ShouldCollectTravelStorageData(l,a))try{await this.CollectTravelCheckoutInformation(e,t,i,a?.CheckoutId,o)}catch(i){const n={cartId:a?.CheckoutId??"",cartUrl:location.pathname,domain:e};return this.LogCartExtractionEvent(n,r.R.CartExtractionError,i?.message,r.in.Error,t),l}}ShouldCollectTravelStorageData(e,t){return!(t&&t.Price===e.OrderTotal&&-1!==e.OrderTotal&&!(0,R.TF)(t.CheckoutId)&&Date.now()-t.TravelDataCreationTime<=432e5)}async CollectTravelCheckoutInformation(e,t,i,n,o){const d=new A;let u;if(d.domain=e,d.domainType=i.domainType,d.checkoutId=n??y.Z.uuidv4(),d.checkoutUrl=location.pathname,await c.ZP.WaitForCondition((async()=>(u=b.Z.GetFirstVisibleElement(i.startDateSelector),void 0!==u)),5e3),void 0===u)return;d.flightLegs=[];const h=b.Z.GetAllVisibleElements(i.startDateSelector),p=b.Z.GetAllVisibleElements(i.endDateSelector),g=b.Z.GetAllVisibleElements(i.nameSelector);if(h.length>1)for(let e=0;e<h.length;e++){const t=new m;t.startDate=h[e].innerText?.trim()??"",e<p.length&&(t.endDate=p[e].innerText?.trim()??""),e<g.length&&(t.name=g[e].innerText?.trim()??""),d.flightLegs.push(t)}d.startDate=u?.innerText?.trim();const f=b.Z.GetFirstVisibleElement(i.endDateSelector),v=b.Z.GetFirstVisibleElement(i.nameSelector);d.endDate=f?.innerText?.trim()??"",d.name=v?.innerText?.trim()??"";const C=I.Z.GetOrderTotalString(i.priceSelector),S=(0,x.cU)(C),T=(0,x.K)(C);d.price=T,d.currency=S,this.LogCartExtractionEvent(d,r.R.TravelCheckoutExtraction,"Successfully extracted Travel Checkout Information",r.in.Information,t);const w=new s;w.Price=d.price,w.CheckoutId=d.checkoutId,w.StartDate=d.startDate,w.EndDate=d.endDate,w.Name=d.name,w.DomainType=d.domainType,w.Currency=d.currency,w.TravelDataCreationTime=Date.now(),w.PageUrl=location.pathname,(0,l.Xo)(a,JSON.stringify(w)),o&&this.SendPersistentTravelCheckoutMessage(e,w,t)}async MonitorCart(e,t,i,n,o,r,a,s,l,d,u,h){if(u===i.pathname||l){const s={attributes:!0,characterData:!0,childList:!0,subtree:!0};this.mutationObserver||(this.mutationObserver=new MutationObserver((async i=>{this.CheckAndCollectCartInformation(e,t,n,o,r,a,n?.automatedCartExtractionEnabled,l,d,u,void 0,n?.getProductNamesFromImg,h),window.dispatchEvent(new Event("CartUpdate"))})));const p=n?.orderTotalDataElementSelector,g=n?.orderTotalDataContainerElementSelector;if(p){await c.ZP.WaitForCondition((async()=>{const e=b.Z.GetFirstVisibleElement(p);return void 0!==e?.innerText}),5e3);const e=b.Z.GetFirstVisibleElement(p);if(e&&(this.mutationObserver?.disconnect(),this.mutationObserver?.observe(e,s),g)){const e=b.Z.GetFirstVisibleElement(g);e&&this.mutationObserver?.observe(e,s)}}if("kohls.com"===e&&"/checkout/shopping_cart.jsp"===i.pathname){const e="shoppingBagHook",t=document.getElementById(e);t&&this.mutationObserver?.observe(t,s)}else if("bedbathandbeyond.com"===e&&"/store/checkout"===i.pathname){const e="ul[class*='ProgressBar']",t=b.Z.GetFirstVisibleElement(e);t&&(this.mutationObserver?.disconnect(),this.mutationObserver?.observe(t,s))}else if("macys.com"===e&&i.pathname===u){const e="bag-summary",t=document.getElementById(e);t&&this.mutationObserver?.observe(t,s)}else if("rei.com"===e&&i.pathname===u){const e=b.Z.GetFirstVisibleElement("section-navigation");e&&this.mutationObserver?.observe(e,s)}}else this.mutationObserver?.disconnect()}ShouldCollectStorageData(e,t){return!(t&&t.OrderTotal===e.OrderTotal&&-1!==e.OrderTotal&&!(0,R.TF)(t.CartId)&&Date.now()-t.CartDataCreationTime<=o.l$)||(this.cartExtractionSuccessful=!0,!1)}async GetProductNamesDirectly(e,t,i,n,o,a,s,l,d,u,h){let p;if(await c.ZP.WaitForCondition((async()=>(p=this.QueryAllWithAutomatedFallback(document,i?.productTitleSelector,s?.details?.productName,t,n,!1),void 0!==p&&p.length>0)),5e3),p=this.QueryAllWithAutomatedFallback(document,i?.productTitleSelector,s?.details?.productName,t,n,!0),!(p&&p.length>0)){const t="No cart selector provided, unable to find products with product title selector.";return void this.LogCartExtractionEvent(e,r.R.CartExtractionError,t,r.in.Error,n,h)}for(const t of p){const i=new T.Z;i.productTitle=t?.textContent?.trim()??"",e.products.push(i)}const f=N.R.isExperimentActive(g.H.improvedCartModelCouponHandling);f&&this.SetBlockedCouponsRequestPending(!0),this.logInfo("Log cart from product names directly",t,n,h),this.LogCartInfo(e,t,n,o,a,l,d,u,void 0,h),f&&this.CheckAndSendCartProcessingRequest(o,e,t).then((()=>this.SetBlockedCouponsRequestPending(!1))).catch((e=>{this.SetBlockedCouponsRequestPending(!1)}))}QueryWithAutomatedFallback(e,t,i,n,o){const r=this.QueryAllWithAutomatedFallback(e,t,i,n,o,e===document);return r&&r.length>0?r[0]:void 0}QueryAllWithAutomatedFallback(e,t,i,n,o,a,s){const l=t?e.querySelectorAll(t):void 0,c=i?e.querySelectorAll(i):void 0;if(a&&t&&i){const e={Domain:n,PageUrl:location.href,ManualSelector:t,AutomatedSelector:i,ManualMatchCount:l?.length??0,AutomatedMatchCount:c?.length??0},a="QueryAll with automated fallback";this.LogCartExtractionEvent(e,r.R.AutomatedSelectorsDiagnostic,a,r.in.Information,o,s,!0)}return l??c}isEmptyCart(e){try{const t=document?.body?.innerText?.toLocaleLowerCase()??"",i="",n=e?.emptyCartText?.toLocaleLowerCase()??"";if(i&&t.includes(i))return!0;if(!(0,R.TF)(n)&&t.includes(n))return!0}catch(e){}return!1}async CollectCartInformation(e,t,i,n,o,a,s,l,u,h,p,f,m,v){const C=new d.Z;C.domain=e,C.cartValue=t.OrderTotal,C.currency=t.Currency,C.cartUrl=location.pathname,C.cartId=u??y.Z.uuidv4(),C.products=[],"rei.com"===e&&(C.cartUrl=location.pathname+location.hash),!i||"amazon.com"!==e&&"walmart.com"!==e&&"jcpenney.com"!==e||(C.productIds=O.ProductIdsGetter[e](i.productIdSkuSelector));const S=N.R.isExperimentActive(g.H.cartExtractionFromBody);if(!(i?.cartSelector||(0,R.TF)(i?.productTitleSelector??"")&&(0,R.TF)(l?.details?.productName??""))){const t="no cart selector provided but has product title selector.";return C.cartUrl=location.pathname,this.LogCartExtractionEvent(C,r.R.CartExtractionError,t,r.in.Error,n,v),this.GetProductNamesDirectly(C,e,i,n,o,s,l,h,p,f,v),void this.notifyCartDataListeners()}if(!i||!i.cartSelector||!i.productSelector){const e="Unable to find cart, no cartSelector and no title/name selector provided.";return C.cartUrl=location.pathname,void this.LogCartExtractionEvent(C,r.R.CartExtractionError,e,r.in.Error,n,v)}const x=performance.now();let w;await c.ZP.WaitForCondition((async()=>(w=b.Z.GetFirstVisibleElement(i.cartSelector),void 0!==w)),5e3);const P=performance.now();let A;if(this.GetTimeDiff(x,P),void 0===w){if(this.isEmptyCart(i))return void this.handleSuccessfulCartExtraction(C,e,n,o,a,s,h,p,f,!0);if(!S){const e="Unable to find cart";return void this.LogCartExtractionEvent(C,r.R.CartExtractionError,e,r.in.Error,n,v)}{const e="Unable to find cart, using document body as fallback";this.LogCartExtractionEvent(C,r.R.CartExtractionError,e,r.in.Error,n,v),w=document.body}}if(await c.ZP.WaitForCondition((async()=>(A=w?.querySelectorAll(i.productSelector),void 0!==A&&A.length>0)),"bedbathandbeyond.com"===e?1e4:5e3),"bedbathandbeyond.com"===e||"target.com"===e||"cvs.com"===e){let e;await c.ZP.WaitForCondition((async()=>(e=w?.querySelectorAll(i.productTitleSelector),void 0!==e&&e.length>0&&e.length===A?.length)),1e4),A=w?.querySelectorAll(i.productSelector)}if("walmart.com"===e){const e=this.CollectProductInformationFromCollapsedCart(o,w);C.products.push(...e)}const E=this.GetLastCartData(),k=void 0!==E?.Products?.find((e=>!e.productTitle||""===e.productTitle));if("walmart.com"===e&&(void 0===A||A.length<=0)&&(null==E||null!=E&&k)){const e=w?.querySelectorAll(i.productImageSelector);if(void 0!==e&&e.length>0)for(const t of e){const e=t.getAttribute("alt");if(e){const i=new T.Z;i.productTitle=e.trim(),i.productImg=t?.src??"",C.products.push(i)}}else if(C.products.length<=0){const e="Unable to find products in cart by product image";return void this.LogCartExtractionEvent(C,r.R.CartExtractionError,e,r.in.Error,n,v)}}else if((void 0===A||A.length<=0)&&C.products.length<=0){const t="Unable to find products in cart";return this.LogCartExtractionEvent(C,r.R.CartExtractionError,t,r.in.Error,n,v),void(!S||(0,R.TF)(i?.productTitleSelector??"")&&(0,R.TF)(l?.details?.productName??"")||this.GetProductNamesDirectly(C,e,i,n,o,s,l,h,p,f,v))}if(A&&A.length>0)for(const t of A){const a=await this.CollectProductInfo(t,i,l,e,n,m,o.priceDivideByQuantity);if(null!=a)p&&!f&&(a.buyNowItem=!0),C.products.push(a);else{const e="Could not extract product info";this.LogCartExtractionEvent(C,r.R.CartExtractionError,e,r.in.Error,n,v)}}if(this.IsNewCart(C,E))this.handleSuccessfulCartExtraction(C,e,n,o,a,s,h,p,f,!1,v);else{const e="Unneccessary Cart Extraction: Cart is the same as the last cart, not collecting again";this.LogCartExtractionEvent(C,r.R.CartExtractionError,e,r.in.Error,n,v)}}async handleSuccessfulCartExtraction(e,t,i,n,o,r,a,s,l,c,d){this.saveNonAugmentedCart(e);const u=performance.now();try{const i=D.Z.GetAutomaticCartExtractionService();await i.augmentWithWebAssist(e.products,t,_.ZP.traceId,o)}catch(e){this.logInfo("Error augmenting cart with WebAssist",t,i,d)}const h=performance.now(),p=`Time to augment with WebAssist:, ${this.GetTimeDiff(u,h)} ms`;this.SetBlockedCouponsRequestPending(!0),this.logInfo(`Log cart from handleSuccessfulCartExtraction. ${p}`,t,i,d),this.LogCartInfo(e,t,i,n,r,a,s,l,c),this.CheckAndSendCartProcessingRequest(n,e,t).then((()=>this.SetBlockedCouponsRequestPending(!1))).catch((e=>{this.SetBlockedCouponsRequestPending(!1)}))}async saveNonAugmentedCart(e){const t=new o.Vr;t.OrderTotal=e.cartValue,t.CartDataCreationTime=Date.now(),t.CartId=e.cartId,t.ProductIds=e.productIds,t.Products=e.products,(0,l.Xo)(o.hm,JSON.stringify(t)),this.notifyCartDataListeners()}async CheckAndSendCartProcessingRequest(e,t,i){const n=e?.pageType??r.GV.CheckoutPage;if("amazon.com"!==i&&n===r.GV.CheckoutPage&&t.products.length>0){const e=await this.SendBlockedCouponsRequest(D.Z.GetLocalDataService().GetMuid(),i,t);this.ProcessBlockedCoupons(e)}}async SendBlockedCouponsRequest(e,t,i){if(e&&e.length>0&&t&&t.length>0)try{const n=D.Z.GetLocalDataService(),o=new h.Z(p.Z.GetClientName(),v.Kr,void 0,p.Z.enabledServiceFlights,N.R.GetServiceExperiments()),r=this.GetCartModelRequestCoupons(),a={muid:e,domain:t,clientContext:o,cartExtractionId:this.GetLastCartExtractionId(),impressionId:n.GetImpressionId(),coupons:r},s=i.products.filter((e=>e.productTitle&&e.productTitle.length>0)).map((e=>e.productTitle));a.productNames=s.slice(0,10);const l=D.Z.GetClientRequestsService(),c=(await l.SendRequest("cartProcessing","getBlockedCoupons",a)).couponCodes;return{OriginalCoupons:r?.map((e=>e.couponCode))??null,BlockedCoupons:c??null}}catch(e){}return{OriginalCoupons:[],BlockedCoupons:[]}}GetCartModelRequestCoupons(){const e=D.Z.GetLocalDataService();if(N.R.isExperimentActive(g.H.sendCouponsToCartModel))try{const t=D.Z.GetSuggestedCouponService().GetSuggestedCoupons();return L.Z.GetCartModelRequestCoupons(e.GetCoupons()??[],t).map((e=>({couponCode:e.couponCode,couponTitle:e.title})))}catch(e){}}ProcessBlockedCoupons(e){const t=this.GetLastCartData();t&&(t.BlockedCouponsData=e,(0,l.Xo)(o.OY,JSON.stringify(t)))}SetBlockedCouponsRequestPending(e){(0,l.Xo)("blockedCouponsRequestPending",e.toString())}GetBlockedCouponsRequestPending(){return"true"===(0,l.Mw)("blockedCouponsRequestPending")}CartProductNameResolution(e,t,i){try{let n=!1;for(const e of t.products)if(void 0===e.productTitle||""===e.productTitle){n=!0;break}if(!n)return{cartInfo:t,message:"products from current cart used"};if(i?.Products){n=!1;for(const e of i.Products)if(void 0===e.productTitle||""===e.productTitle){n=!0;break}if(!n)return t.products=i.Products,{cartInfo:t,message:"products from last cached cart used"}}const o=M.Q?.PersistentCartData,r=((0,E.BQ)(o)??{})[e]??{},a=r?.cartDataStorageInfo??{};if(a?.Products){n=!1;for(const e of a.Products)if(void 0===e.productTitle||""===e.productTitle){n=!0;break}if(!n)return t.products=a.Products,{cartInfo:t,message:"products from persistent cart used"}}for(const e of t.products)if(void 0===e.productTitle||""===e.productTitle){let t=this.FindProductByUrl(e.productUrl,e.productImg,i);null==t&&(t=this.FindProductByUrl(e.productUrl,e.productImg,a)),t&&(e.productTitle=t.productTitle,void 0===e.productQuantity&&(e.productQuantity=t.productQuantity))}}catch(e){return{cartInfo:t,message:"error getting products from cache or persistent cart: "+e}}return{cartInfo:t,message:"could not get products from cache or persistent cart"}}FindProductByUrl(e,t,i){if(!i?.Products)return null;for(const n of i.Products)if((n.productUrl===e||n.productImg===t)&&n.productTitle&&""!==n.productTitle)return n;return null}CollectProductInfo(e,t,i,n,r,a,s){const d=this.QueryWithAutomatedFallback(e,t.productTitleSelector,i?.details?.productName,n,r),h=e.querySelector(t.productUrlSelector),p=e.querySelector(t.productImageSelector),g=e.querySelector(t.productSellerSelector);let f=d?.innerText?.trim()||d?.textContent?.trim()||"";const m=I.Z.GetOrderTotalString(t.productPriceSelector,e),v=(0,x.K)(m)??-1,y=u.Z.getQuantity(t.productQuantitySelector,e);let C=g?.innerText?.trim()||g?.textContent?.trim()||"";const b=p?.src??"",S=h?.getAttribute("href")??"";if(C&&c.ZP.IsValidDataField(t.productSellerRegex)&&(C=C.replace(t.productSellerRegex,"")),("walmart.com"===n||"target.com"===n||"jcpenney.com"===n||a)&&(0,R.TF)(f)){const e=p?.getAttribute("alt");e&&(f=e.trim())}if((0,R.TF)(f)&&(0,R.TF)(S)&&(0,R.TF)(b))return null;let w="";try{let e=JSON.parse((0,l.Mw)(o.D8)||"[]");for(const t of e)if(f.includes(t?.ProductName)){w=t?.ProductBrandName??"";break}}catch(e){}const O=new T.Z;return O.productTitle=f,O.productBrand=w,O.productPrice=v,O.productUrl=S,O.productImg=b,O.productQuantity=y,O.productSeller=C,s&&y>1&&(O.productPrice=Number((v/y).toFixed(2))),O}IsNewCart(e,t){if(null==e?.products||0===e.products.length)return!1;if(null==t?.Products||0===t.Products.length)return!0;if(e.products.length!==t.Products.length)return!0;let i=!0,n=!1;for(let o=0;o<e.products.length;o++){const r=e.products[o];if(-1===t.Products.findIndex((e=>e.productTitle===r.productTitle)))return!0;i=i&&Boolean(r.productUrl),n=n||Boolean(r.productSeller)}let o=!0,r=!0;t.Products.forEach((e=>{o=o&&Boolean(e.productUrl),r=r&&Boolean(e.productSeller)}));const a=n&&!r,s=i&&!o;return!(!N.R.isExperimentActive(g.H.fixCartUpdate)||!a)||s}LogCartInfo(e,t,i,n,a,s,c,d,u,h){let p={OrderTotal:-1,Currency:(0,x.N6)(a)??"",PageCurrency:""};p=k.Z.GetCartValue(n.orderTotalDataElementSelector,a),p.OrderTotal>0||(p=k.Z.TrySimpleGetCartValue(n.orderTotalDataElementSelector,a)),e.cartValue=p.OrderTotal,e.currency=p.Currency;const f=this.GetLastCartData(),m=N.R.isExperimentActive(g.H.fixCartUpdate);if((0,R.TF)(n.orderSubTotalElementSelector)||(e.subTotal=I.Z.GetOrderTotalString(n.orderSubTotalElementSelector)),u||e.products?.length>0){const a=performance.now();let p=u?"Empty Cart Extraction":"Successfully extracted Cart Information",g={cartInfo:e,message:""},v=!1;("walmart.com"===t&&"/checkout/review-order"===e.cartUrl||"kohls.com"===t&&"/checkout/shopping_cart.jsp"!==e.cartUrl)&&(g=this.CartProductNameResolution(t,e,f),p+="; "+g.message+"; "+JSON.stringify(g.cartInfo),v=!0);const b=y.Z.uuidv4();if(this.LogCartExtractionEvent(e,r.R.CartExtraction,p,r.in.Information,i,`${b}_${h}`),m&&!this.IsNewCart(e,f))return void this.logInfo("No cart log. fixCartUpdate and not new cart",t,i,h);I.Z.SendStorageMessage(S.Q.DynamicTransactionId,JSON.stringify({value:b}));const T=new o.Vr;if(T.OrderTotal=e.cartValue,T.CartDataCreationTime=Date.now(),T.CartId=e.cartId,T.ProductIds=e.productIds,T.Products=v?g.cartInfo.products:e.products,T.Currency=e.currency??"",e.subTotal&&(T.OrderSubTotal=(0,x.K)(e.subTotal)??-1),(0,l.NN)()||this.LogCartExtractionEvent(e,r.R.CartExtractionError,"No access to local storage",r.in.Error,i,h),c&&void 0!==f?.Products){const t=e.products[0],i=location.pathname;if(!(0,R.TF)(t.productTitle)){let e=!1;for(const n of f.Products)if(n.productQuantity>0&&(0===n.productUrl.indexOf(i)||n.productTitle===t.productTitle)){t.productQuantity&&!isNaN(t.productQuantity)?n.productQuantity=n.productQuantity+t.productQuantity:n.productQuantity=n.productQuantity+1,n.buyNowItem=!d,e=!0;break}if(!e){const e=f.Products;t.buyNowItem=!d,e.push(t),T.Products=e}}}const w=this.CollectGroceryInfo(n);T.CartPreTax=w.preTaxTotal,T.CartEstimatedTax=w.estimatedTax,T.ShipmentDate=w.shipmentDate,T.ExtractionId=b;const O=performance.now();this.logInfo(`Writing to local storage, timeTook: ${this.GetTimeDiff(a,O)}`,t,i,h),(0,l.Xo)(o.OY,JSON.stringify(T)),(0,l.TJ)(o.hm);const P=C.PK[t]?.useCartAtPathname;P&&location.pathname.toLocaleLowerCase().includes(P)&&I.Z.SendStorageMessage(S.Q.PostPurchasePathnameProducts,JSON.stringify({value:T.Products})),s&&this.SendPersistentCartMessage(t,T,i,h)}else{const t="Unable to get enough info about products in cart";this.LogCartExtractionEvent(e,r.R.CartExtractionError,t,r.in.Error,i,h)}}CollectGroceryInfo(e){const t=e.shipmentSelector,i=e.preTaxSelector,n=e.estimatedTaxSelector;let o,r,a;if(c.ZP.IsValidDataField(t)&&c.ZP.IsValidDataField(i)&&c.ZP.IsValidDataField(n))try{o=this.GetShipmentDate(t);const e=I.Z.GetOrderTotalString(i);r=(0,x.K)(e)??-1;const s=I.Z.GetOrderTotalString(n);a=(0,x.K)(s)??-1}catch(e){}return{shipmentDate:o,preTaxTotal:r,estimatedTax:a}}GetShipmentDate(e,t){const i=e.split(","),n=I.Z.GetOrderTotalString(i[0]);if(n)try{const e=I.Z.parseDate(n);return"Invalid Date"===e.toString()?"":e}catch(e){}else if(4===i.length){const e=I.Z.GetOrderTotalString(i[1])?.trim(),t=I.Z.GetOrderTotalString(i[2])?.trim(),n=I.Z.GetOrderTotalString(i[3])?.trim();return new Date(`${e} ${t} ${n}`)}return""}SendPersistentCartMessage(e,t,i,n){try{const i=M.Q?.PersistentCartData??"",n=(0,E.BQ)(i)??{};n[e]={cartDataStorageInfo:t,timestamp:new Date};const o=JSON.stringify({value:JSON.stringify(n)});I.Z.SendStorageMessage("PersistentCartData",o)}catch(e){this.LogCartExtractionEvent(t,r.R.CartExtractionError,"Could not send cart data to storage: "+e?.message,r.in.Error,i,n)}}SendPersistentTravelCheckoutMessage(e,t,i,n){try{const i=M.Q?.PersistentTravelData??"",n=(0,E.BQ)(i)??{};n[e]={travelDataStorageInfo:t,timestamp:new Date};const o=JSON.stringify({value:JSON.stringify(n)});I.Z.SendStorageMessage("PersistentTravelData",o)}catch(e){this.LogCartExtractionEvent(t,r.R.CartExtractionError,"Could not send travel data to storage: "+e?.message,r.in.Error,i,n)}}ShouldSendTelemetryData(e){return this.isPersonalizationDataConsentEnabled||e!==r.R.CartExtraction&&e!==r.R.TravelCheckoutExtraction}LogCartExtractionEvent(e,t,i,n,o,a,s){let l={};if(this.ShouldSendTelemetryData(t)&&(l=e),!s){void 0===this.cartExtractionSuccessful&&(t===r.R.CartExtraction?this.cartExtractionSuccessful=!0:this.cartExtractionSuccessful=!1);const e=D.Z.GetLocalDataService(),i=e.GetSessionIds()?.retailerSessionId??"",n=e.GetSessionIds()?.pageVisitId??"";l=F(F({},l),{},{isPersonalizationDataConsentEnabled:this.isPersonalizationDataConsentEnabled,extractionId:a??null,PageVisitId:n,RetailerSessionId:i})}I.Z.SendLogEventMessage(l,t,o,i,n)}logInfo(e,t,i,n){const o=D.Z?.GetLocalDataService(),a=o?.GetSessionIds()?.retailerSessionId??"",s=o?.GetSessionIds()?.pageVisitId??"",l={domain:t||location.hostname,cartUrl:location.pathname,isPersonalizationDataConsentEnabled:this.isPersonalizationDataConsentEnabled,extractionId:n??null,PageVisitId:s,RetailerSessionId:a};I.Z.SendLogEventMessage(l,r.R.CartExtractionError,i,e,r.in.Information)}CollectProductInformationFromCollapsedCart(e,t){let i;const n=[];i=e.cartSelectors.collapsedCartProductImageSelector?e.cartSelectors.collapsedCartProductImageSelector:"[aria-label='collapsed item list'] img";const o=t?.querySelectorAll(i);if(void 0!==o&&o.length>0)for(const e of o){const t=e.getAttribute("alt");if(t){let i,o;const r=t.match(" quantity \\d+$");r&&r.length>0?(i=t.replace(r[0],""),o=parseInt(r[0].split(" quantity ")[1],10)):(i=t,o=1);const a=new T.Z;a.productTitle=i.trim(),a.productQuantity=o,a.productImg=e?.src??"",n.push(a)}}return n}ShouldAddCartButtonListener(e,t){let i=e?.clickForCartSelector;return i||"walmart.com"!==t||(i="#cart-button-header"),i&&b.Z.GetAllVisibleElements(i).length>0?{shouldAddListener:!0,cartButtonSelector:i}:{shouldAddListener:!1,cartButtonSelector:""}}AddCartButtonListener(e,t,i,n,o,r,a,s,l,d,u,h){const p=b.Z.GetFirstVisibleElement(e);p?.addEventListener("click",(async()=>{c.ZP.WaitForCondition((async()=>{const e=this.GetCartCheckoutPage(i.retailerData.allCheckoutPages);if(e&&e.checkoutPageUrl!==t)return!1;i.retailerData.updateCurrentCheckoutPage(t);const n=i.retailerData.getCurrentCheckoutPage();return!!n?.cartSelectors?.cartSelector&&b.Z.HasVisibleElement(n?.cartSelectors?.cartSelector)}),1e3).then((e=>{if(e){i.retailerData.updateCurrentCheckoutPage(t);const e=i.retailerData.getCurrentCheckoutPage();this.TryCheckAndCollectCartInformation(n,o,e,r,d,u,e?.automatedCartExtractionEnabled,a.isCashbackEstimationSupportedForDomain,s,l,void 0,h)}}))}))}GetTimeDiff(e,t){return(t-e).toFixed(1)}GetCartCheckoutPage(e){const t=e.filter((e=>e.pageType&&e.pageType===r.GV.CheckoutPage));return t.length>0?t[0]:null}async CollectCartInfoFromProductPage(e,t,i,n,o,r,a,s,l){const d=t.retailerData.getCurrentCheckoutPage();if(d)if(d.addToCartOverlaySelector&&d.cartSelectors){let c=!1;const u={attributes:!0,characterData:!0,childList:!0,subtree:!0};new MutationObserver((async u=>{if(!b.Z.GetFirstVisibleElement(d.addToCartOverlaySelector))return void(c=!1);if(c)return;c=!0;const h=t.retailerData.getCurrentCheckoutPage();this.TryCheckAndCollectCartInformation(e,i,h,n,o,r,h?.automatedCartExtractionEnabled,t.isCashbackEstimationSupportedForDomain,a,s,!0,l)})).observe(document.body,u)}else if(d?.buyNowSelector&&d?.cartSelectors){const u=d.buyNowSelector,h=await c.ZP.WaitForCondition((async()=>b.Z.HasVisibleElement(u)),5e3).then((async()=>b.Z.GetFirstVisibleElement(u)));h?.addEventListener("click",(async()=>{const c=t.retailerData.getCurrentCheckoutPage();this.TryCheckAndCollectCartInformation(e,i,c,n,o,r,c?.automatedCartExtractionEnabled,t.isCashbackEstimationSupportedForDomain,a,s,void 0,l)}))}}notifyCartDataListeners(){try{this.onCartExtractionCallback&&this.onCartExtractionCallback()}catch(e){}}}let H;function $(){return H||(H=new U),H}},61241:function(e,t,i){"use strict";i.d(t,{Z:function(){return k}});var n=i(72370),o=i(33491),r=i(95457),a=i(4872),s=i(31656),l=i(5144),c=i(29247),d=i(36493),u=i(27689),h=i(93978),p=i(41310),g=i(90066),f=i(82315),m=i(9839),v=i(1094);class y{constructor(){(0,n.Z)(this,"Domain",void 0),(0,n.Z)(this,"ProductName",void 0),(0,n.Z)(this,"ProductSellerName",void 0),(0,n.Z)(this,"ProductBrandName",void 0),(0,n.Z)(this,"Url",void 0),(0,n.Z)(this,"PageUrl",void 0),(0,n.Z)(this,"Price",void 0),(0,n.Z)(this,"ImageUrl",void 0),(0,n.Z)(this,"ProductUpc",void 0),(0,n.Z)(this,"ProductAsin",void 0),(0,n.Z)(this,"Currency",void 0),(0,n.Z)(this,"Market",void 0),(0,n.Z)(this,"ProductVariant",void 0),(0,n.Z)(this,"Badges",void 0),(0,n.Z)(this,"OutOfStock",void 0)}static Create(e){const t=new y;return t.ProductName=e.ProductName,t.Url=e.Url,t.Price=e.Price,t.ImageUrl=e.ImageUrl,t}}var C=y;class b{constructor(){(0,n.Z)(this,"ProductName",void 0),(0,n.Z)(this,"Url",void 0),(0,n.Z)(this,"AggregateRating",void 0),(0,n.Z)(this,"AggregateRatingCount",void 0)}static Create(e){const t=new b;return t.ProductName=e.ProductName,t.Url=e.Url,t.AggregateRating=e.AggregateRating,t.AggregateRatingCount=e.AggregateRatingCount,t}}var S=b;class x{constructor(){(0,n.Z)(this,"ProductName",void 0),(0,n.Z)(this,"Url",void 0),(0,n.Z)(this,"Reviews",void 0)}static Create(e){const t=new x;return t.ProductName=e.ProductName,t.Url=e.Url,t.Reviews=e.Reviews,t}}var T=x,w=i(52056),O=i(83879),P=i(93970),A=class{static CreateVariant(e){return"amazon.com"===e.toLowerCase()?new class{constructor(){(0,n.Z)(this,"pdpUrl","pdp_url"),(0,n.Z)(this,"imageUrl","image_icon_url"),(0,n.Z)(this,"asin","asin"),(0,n.Z)(this,"productVariant","product_variant")}ExtractVariants(){let e="{product_variant: {",t="";const i={};for(let e=0;e<25&&(t="#color_name_"+e,null!=g.Z.GetFirstMatchingElement(t));e++){const n=this.ExtractVariantUrl(t);if(null===n)continue;const o=this.ExtractVariantImageUrl(t);if(null===o)continue;const r=this.ExtractVariantAsin(t);if(null===r)continue;const a=this.ExtractVariantAttribute(t),s={};s[this.pdpUrl]=n,s[this.imageUrl]=o,s[this.asin]=r,"none"!==a[0]&&(s[a[0]]=a[1]),i["variant_"+(e+1)]=s}const n={};return n[this.productVariant]=i,e=JSON.stringify(n),e}ExtractVariantUrl(e){const t=g.Z.GetFirstMatchingElement(e);let i="default-data-url";const n=t?.getAttribute("data-dp-url");return""!==n&&null!=n&&(i=n),"default-data-url"===i||null==i?null:i}ExtractVariantImageUrl(e){const t=e+" .a-button",i=g.Z.GetFirstMatchingElement(t),n=i?.getAttribute("id");if(null==n)return null;const o="#"+n+"-announce > div > div > img",r=g.Z.GetFirstMatchingElement(o),a=r?.src??"";return null==a?null:a}ExtractVariantAsin(e){const t=g.Z.GetFirstMatchingElement(e),i=t?.getAttribute("data-defaultasin");return i}ExtractVariantAttribute(e){const t=g.Z.GetFirstMatchingElement("#variation_color_name > div > label")?.innerText,i=g.Z.GetFirstMatchingElement("#variation_color_name > div > span")?.innerText;return void 0!==t&&void 0!==i&&null!==t&&null!==i?[t,i]:["none","none"]}}:new class{ExtractVariants(){return""}}}},E=i(27900),k=class{constructor(){(0,n.Z)(this,"currentPageUrl",void 0),(0,n.Z)(this,"cashBackResponseStr",void 0)}SetServiceUrl(e){this.currentPageUrl=e}SetCashbackResponseStr(e){this.cashBackResponseStr=e}async Init(){this.SetServiceUrl(new URL(window.location.href));const e=O.Z.GetLocalDataService(),t=e.GetCheckoutPageData(),i=e.GetItemLevelCashbackData();t.retailerData.updateCurrentCheckoutPage(v.Z.GetCurrentPathName());const n=t.retailerData.getCurrentCheckoutPage(),o=n?.catalogSelectors,c=t.retailerData.domainName,d=t.impressionId;if(n?.pageType===l.GV.ProductPage){let e=o?.productPriceSelector,i=o?.productImageSelector,n=o?.productTitleSelector,r=o?.productOutOfStockSelector;s.R.isExperimentActive.bind(a.H.pdpSelectorExtraction)&&(e=e??t?.retailerData?.productPriceSelector,i=i??t?.retailerData?.productImageSelector,n=n??t?.retailerData?.productNameSelector,r=r??t?.retailerData?.productOutOfStockSelector),this.ExtractReviews(c,d,o?.reviewSelector,o?.reviewRatingSelector,o?.reviewDateSelector,o?.reviewerNameSelector,o?.productTitleSelector).catch((e=>{})),this.ExtractRatings(c,d,o?.aggregateRatingSelector,o?.aggregateRatingNumberOfRatingsSelector,o?.productTitleSelector).catch((e=>{}));const u=(new Date).getTime();this.ExtractPDPOffer(c,d,e,i,n,o?.productSellerSelector,o?.productBrandSelector,o?.productUPCSelector,o?.productASIN,r).catch((e=>{const t=(new Date).getTime();this.LogCatalogExtractionEvent({},l.R.CatalogExtractionPDPOffer,JSON.stringify({extractionTime:t-u}),l.in.Information,d),s.R.isExperimentActive(a.H.pdpSelectorExtraction)&&m.Q.sendMessage(P.EI.DataExtracted,[f.Z.getApiResponse().traceId,"{}"])})).then((e=>{this.CachePdpOffer(e);const t=(new Date).getTime();this.LogCatalogExtractionEvent(e??{},l.R.CatalogExtractionPDPOffer,JSON.stringify({extractionTime:t-u}),l.in.Information,d),s.R.isExperimentActive(a.H.pdpSelectorExtraction)&&m.Q.sendMessage(P.EI.DataExtracted,[f.Z.getApiResponse().traceId,JSON.stringify(e)])}))}else if(n?.pageType===l.GV.SearchPage&&i?.domainData){const e=r.Z.Create(i.domainData),t=p.Z.IsSearchPage(this.currentPageUrl,e);t?.searchKey&&this.ExtractSearchProduct(c,d,o?.productTitleSelector,o?.productPriceSelector,t.searchKey)}}async CachePdpOffer(e){try{let t=JSON.parse((0,o.Mw)(E.D8)||"[]");e?.ProductName&&t.push(e),t.length>E.xD&&t.shift(),(0,o.Xo)(E.D8,JSON.stringify(t))}catch(e){}}async PostValidation(){}async ExtractReviews(e,t,i,n,o,r,a){if(i){await c.ZP.WaitForCondition((async()=>{if(void 0===i)return!1;const e=g.Z.RunQuerySelectorAll(i);return void 0!==e&&e.length>0}),5e3);try{const s=i?g.Z.RunQuerySelectorAll(i):[],c=n?g.Z.RunQuerySelectorAll(n):[],d=o?g.Z.RunQuerySelectorAll(o):[],u=r?g.Z.RunQuerySelectorAll(r):[],h=a?g.Z.GetFirstVisibleElement(a)?.innerText:"",p=new URL(window.location.href),f=Array.from(s).flatMap((e=>e.innerText)),m=Array.from(c).flatMap((t=>this.GetReviewRating(t,e))),v=Array.from(d).flatMap((e=>e.innerText)),y=Array.from(u).flatMap((e=>e.innerText)),C=new T;C.Reviews=JSON.stringify([f,m,v,y,[this.currentPageUrl.toString().split("?")[0]]]),C.Url=p.toString().split("?")[0],void 0!==h&&(C.ProductName=h),this.LogCatalogExtractionEvent(C,l.R.CatalogExtractionReviews,"",l.in.Information,t)}catch(e){}}}async ExtractRatings(e,t,i,n,o){if(i&&n){await c.ZP.WaitForCondition((async()=>void 0!==i&&void 0!==g.Z.GetFirstVisibleElement(i)),5e3);try{const r=new URL(window.location.href),a=g.Z.GetFirstVisibleElement(i)??void 0,s=g.Z.GetFirstVisibleElement(n)?.innerText,c=o?g.Z.GetFirstVisibleElement(o)?.innerText:"";if(void 0!==a&&void 0!==s){const i=new S;i.AggregateRating=this.GetAggregateRating(a,e),i.AggregateRatingCount=s,i.Url=r.toString().split("?")[0],i.ProductName=c??"",this.LogCatalogExtractionEvent(i,l.R.CatalogExtractionRating,"",l.in.Information,t)}}catch(e){}}}async ExtractPDPOffer(e,t,i,n,o,r,a,s,l,h){const p=new C;if(!i||!n||!o)return p;await c.ZP.WaitForCondition((async()=>{if(void 0===o)return!1;const e=g.Z.GetFirstVisibleElement(o),t=g.Z.GetFirstVisibleElement(i);return void 0!==e&&(!i||void 0!==t)}),5e3);try{const t=new URL(window.location.href),c=g.Z.GetFirstVisibleElement(o)?.innerText,f=g.Z.GetFirstMatchingElement(n),m=f?.src??"",v=g.Z.GetFirstVisibleElement(i)?.innerText;let y="$",C=0,b="",S="USD";const x=(0,u.S8)(),T=A.CreateVariant(x);let w="";const O=T.ExtractVariants();if(null!==O&&(w=O),v&&v.length){y=(0,d.cU)(v),C=(0,d.K)(v);const e=(0,d.Vv)(y);void 0!==e&&(S=e),b=C.toString()}let P,E,k,I,D;r&&a&&(P=g.Z.GetFirstVisibleElement(r)?.innerText,E=g.Z.GetFirstVisibleElement(a)?.innerText),s&&(k=g.Z.GetFirstVisibleElement(s)?.innerText),l&&(I=g.Z.GetFirstVisibleElement(l)?.innerText),h&&(D=g.Z.GetFirstVisibleElement(h)?.innerText),p.Domain=e,p.Price=b,p.ProductVariant=w,p.ImageUrl=m,p.Url=t.toString().split("?")[0],p.PageUrl=t.toString(),p.ProductName=c??"",p.ProductSellerName=P,p.ProductBrandName=E,p.ProductAsin=I,p.ProductUpc=k,p.Currency=S,p.OutOfStock=D;const _=[navigator.language],N=this.GetMarket(_,this.GetSupportedMarkets());let R="en-us";if(void 0!==N&&(R=N,"USD"===S)){const e=(0,d.N6)(R);if(void 0!==e){const t=(0,d.Vv)(e);p.Currency=t}}return p.Market=R,p}catch(e){return p}}async ExtractSearchProduct(e,t,i,n,o){if(!n||!i||!this.cashBackResponseStr)return;const r=JSON.parse(this.cashBackResponseStr);let a,s;r?.itemizedCashBackResponse?.offers?.length>0&&(a=r?.itemizedCashBackResponse?.offers[0]?.adsOffer?.name,s=r?.itemizedCashBackResponse?.offers[0]?.adsOffer?.price),await c.ZP.WaitForCondition((async()=>void 0!==i&&void 0!==g.Z.GetFirstVisibleElement(i)),5e3);try{const r=g.Z.GetAllVisibleElements(i),c=g.Z.GetAllVisibleElements(n),u=[];if(r&&c){for(let e=0;e<10;e++)if(e<r.length&&e<c.length){const t={ProductTitle:r[e]?.innerText,ProductPrice:(0,d.K)(c[e]?.innerText)??-1};u.push(t)}if(u.length>0&&a&&s){const i={Domain:e,products:u,QueryKeyword:o,currentPageUrl:this.currentPageUrl,spbTitle:a,spbPrice:s};this.LogCatalogExtractionEvent(i,l.R.CatalogExtractionSearchOffers,"",l.in.Information,t)}}}catch(e){}}LogCatalogExtractionEvent(e,t,i,n,o){w.Z.SendLogEventMessage(e,t,o,i,n)}GetReviewRating(e,t){return t.match("ebay.")||t.match("lowes.")||t.match("macys.")||t.match("thriftbooks.")||t.match("manomano.")||t.match("hsn.")||t.match("casasbahia.")||t.match("webstaurantstore.")?e.getAttribute("aria-label")??"":"overstock.com"===t?e.getAttribute("data-rating")??"":"quill.com"===t?e.getAttribute("rating")??"":"etsy.com"===t?e.getAttribute("value")??"":"otto.de"===t?e.getAttribute("content")??"":"onbuy.com"===t||"lightinthebox.com"===t?e.getAttribute("title")??"":e.innerText}GetAggregateRating(e,t){return void 0===e?"":t.match("onbuy.")?e.getAttribute("title")??"":e.innerText}GetSupportedMarkets(){return h.YE}GetMarket(e,t){if(!e||0===e.length)return"en-us";let i;for(const t of e){if(t.indexOf("-")>=0)return t.toLowerCase();i||(i=t.toLowerCase())}for(const e of t)if(e.startsWith(`${i}-`))return e}}},82270:function(e,t,i){"use strict";var n=i(72370),o=i(5144),r=i(29247),a=i(1094),s=i(93209),l=i(12953),c=i(87605),d=i(2388),u=i(84901),h=i(90066),p=i(28219),g=i(27689),f=i(11849),m=i(52056),v=i(83879),y=i(44445),C=i(64865);t.Z=class{constructor(){(0,n.Z)(this,"divIDOverlay","#divOverlayWrapper"),(0,n.Z)(this,"localDataService",void 0),(0,n.Z)(this,"validatorModule",void 0),(0,n.Z)(this,"isCashbackDomain",void 0),(0,n.Z)(this,"checkoutPageUrlData",void 0),(0,n.Z)(this,"exclusiveMarket",void 0),(0,n.Z)(this,"impressionId",void 0),(0,n.Z)(this,"coupons",void 0),(0,n.Z)(this,"fromPlatformDetection",void 0),(0,n.Z)(this,"applyButtonAvailable",!1),(0,n.Z)(this,"textInput",void 0),(0,n.Z)(this,"cartValue",void 0),(0,n.Z)(this,"startTime",void 0),(0,n.Z)(this,"InputHandler",(()=>{const e=h.Z.GetFirstVisibleElement(this.checkoutPageUrlData.inputBoxSelector);if(e&&e.value&&(this.textInput=e.value,this.startTime=(new Date).getTime(),!this.cartValue)){if(this.cartValue=this.GetCartValue(),this.applyButtonAvailable)return;this.WaitForCondition((async()=>this.GetCartValue().OrderTotal!==this.cartValue?.OrderTotal),1e4).then((async e=>{e?await this.GetCouponAndDiscount(!1):this.Reset()}))}})),(0,n.Z)(this,"ApplyHandler",(async()=>{await this.GetCouponAndDiscount(!0)}))}async Init(){this.localDataService=v.Z.GetLocalDataService(),this.validatorModule=v.Z.GetValidatorModule();const e=this.localDataService.GetCheckoutPageData(),t=e?.cashback;this.isCashbackDomain=t&&(t.isRebatesSupportedDomain??!0);const i=e?.retailerData?.getCurrentCheckoutPage(a.Z.GetCurrentPathName());i?.manualCouponApplyTrackingEnabled&&this.TryListenForCoupon(i,e.coupons,this.localDataService.GetMarket(),this.validatorModule.impressionId)}async PostValidation(){}async TryListenForCoupon(e,t,i,n,o){try{r.ZP.IsValidDataField(e.inputBoxSelector)&&r.ZP.IsValidDataField(e.orderTotalDataElementSelector)&&(this.checkoutPageUrlData=e,this.coupons=t??[],this.exclusiveMarket=i,this.impressionId=n,this.fromPlatformDetection=o??!1,this.TrySetUpCouponListener(!1,!1,!0))}catch(e){this.LogError(e?.message)}}async TrySetUpCouponListener(e,t,i){let n=!1;if(n=e?await r.ZP.WaitUntilCondition((async()=>await this.SetUpCouponListener(e)),5e3):await this.SetUpCouponListener(e,t),!n){let e="Unable to add coupon savings listener";i||(e+=" No longer listening"),this.LogError(e)}}async SetUpCouponListener(e,t){return await this.isInputBoxAvailable(e?1:5)?this.ListenForCoupon():await this.CheckRemoveAndClickBeforeStartButtons(t)}async ListenForCoupon(){const e=h.Z.GetFirstVisibleElement(this.checkoutPageUrlData.inputBoxSelector);if(!e)return this.LogError("Called ListenForCoupon without input box available"),!1;const t=h.Z.GetFirstVisibleElement(this.checkoutPageUrlData.applyButtonSelector);return t&&(this.applyButtonAvailable=!0,t.addEventListener("click",this.ApplyHandler)),e.addEventListener("keyup",this.InputHandler),!0}async WaitForCondition(e,t){if(!this.startTime)return!1;for(;!await e()&&this.startTime+t>(new Date).getTime();)await r.ZP.Sleep(100);return this.startTime=null,await e()}async GetCouponAndDiscount(e){e&&await r.ZP.Sleep(this.checkoutPageUrlData.waitAfterApplyingCurrentCoupon??2e3);const t=this.textInput;if(t){let i=this.GetCartValue();i.OrderTotal===this.cartValue?.OrderTotal&&e&&(await r.ZP.Sleep(2e3),i=this.GetCartValue());let n=-1,o="";this.cartValue?.OrderTotal&&i.OrderTotal&&(n=this.cartValue.OrderTotal-i.OrderTotal,o=n>0?"Positive":"Negative"),this.isAutoApplyOn()||(0,C.TF)(o)||this.LogCouponSavings(t,o,n,this.cartValue?.OrderTotal??-1,i.OrderTotal,i.Currency,i.PageCurrency)}this.Reset(),await this.TrySetUpCouponListener(!0)}Reset(){this.textInput="",this.cartValue=null,this.startTime=null}async isInputBoxAvailable(e){return!!await r.ZP.WaitForCondition((async()=>h.Z.HasVisibleElement(this.checkoutPageUrlData.inputBoxSelector)),1e3*e)}CheckRemoveAndClickBeforeStartButtons(e){const t=h.Z.HasVisibleElement(this.checkoutPageUrlData.clickBeforeStartSelector);return!(e||!t||!this.AddClickBeforeStartListener())||!!h.Z.HasVisibleElement(this.checkoutPageUrlData.removeCouponButtonSelector)&&this.AddRemoveButtonListener()}AddClickBeforeStartListener(){const e=h.Z.GetFirstVisibleElement(this.checkoutPageUrlData.clickBeforeStartSelector);return!!e&&(e.addEventListener("click",(async()=>{await this.TrySetUpCouponListener(!1,!0)})),!0)}AddRemoveButtonListener(){const e=h.Z.GetFirstVisibleElement(this.checkoutPageUrlData.removeCouponButtonSelector);return!!e&&(e.addEventListener("click",(async()=>{await this.TrySetUpCouponListener(!1,!1)})),!0)}GetCartValue(){let e={OrderTotal:-1,Currency:"$",PageCurrency:""};try{e=f.Z.GetCartValue(this.checkoutPageUrlData.orderTotalDataElementSelector,this.exclusiveMarket)}catch(e){this.LogError(e?.message)}return e}IsCouponInOurCorpus(e){return this.coupons.find((t=>t.couponCode.toLowerCase().trim()===e.toLowerCase().trim()))}isAutoApplyOn(){return h.Z.HasVisibleElement(this.divIDOverlay)}LogCouponSavings(e,t,i,n,r,a,s){const d=this.IsCouponInOurCorpus(e),h=(0,g.S8)();let p=e;try{p=d?e:btoa(e)}catch(e){p="USERCOUPON"}const f=this.TryGetCouponStatusMessages(),y={CouponCode:p,Currency:a,Discount:i,Domain:(0,g.S8)(),FinalPrice:r,PageCurrency:s,PageUrl:(0,g.Ek)(),Result:t,StartingPrice:n,StatusMessage:f.statusMessage,SuccessMessages:f.successMessages,FailureMessages:f.failureMessages,ProviderId:d?.providerId??"",IsPrivateCoupon:d?.isPrivateCoupon??!1,CartExtractionId:v.Z.GetCartExtractionService().GetLastCartExtractionId()},b=this.fromPlatformDetection?"User applied a coupon from platform detection":"User applied a coupon";if(d)(0,C.TF)(d.offerUrl)||this.isCashbackDomain||m.Z.SendNavigateToUrlMessage(d.offerUrl),m.Z.SendLogEventMessage(y,o.R.ManualCouponApplication,this.impressionId,b,o.in.Information);else{const e=new l.Z(p,h,o.M_.ManuallyAppliedCouponNotInOurCorpus,location.pathname,JSON.stringify(y));m.Z.SendLogEventMessage(e,o.R.CollectedCoupons,this.impressionId,b,o.in.Information)}(i>0||d)&&this.SendEngagementTelemetry(o.$S.ManuallyAppliedCoupon,c.bS.COUPONS_COPIED,u.FV.COUPONS_COPIED)}TryGetCouponStatusMessages(){try{return p.Z.GetCouponStatusMessages(this.checkoutPageUrlData?.errorMessageSelector,this.checkoutPageUrlData?.couponSuccessMessageSelectors,this.checkoutPageUrlData?.couponFailureMessageSelectors)}catch(e){this.LogError("Error extracting coupon status messages")}return{statusMessage:"",successMessages:[],failureMessages:[]}}async SendEngagementTelemetry(e,t,i){const n=new s.Z(e,d.r.COUPONS_AVAILABLE,(0,g.S8)());m.Z.SendLogEventMessage(n,o.R.ButtonClick,this.impressionId,"User applied a coupon manually",o.in.Information),y.a.postMessageToHost("recordAsUserAction",[t]),y.a.postMessageToHost("recordAsUserEngagement",[i])}LogError(e){const t={Domain:(0,g.S8)(),PageUrl:(0,g.Ek)(),Status:"Error"};m.Z.SendLogEventMessage(t,o.R.ManualCouponApplication,this.impressionId,e??"Error getting coupon savings",o.in.Information)}}},86743:function(e,t,i){"use strict";i.d(t,{Kv:function(){return p},XB:function(){return u},sy:function(){return h}});var n=i(4872),o=i(31656),r=i(31714),a=i(73557);const s=190624,l=84541440,c=-809239298,d=-9;function u(){try{return!(!o.R.isExperimentActive(n.H.autoOpenControllerMask)||!o.R.isExperimentActive(n.H.autoOpenControllerScript)||h())}catch(e){return!1}}function h(){const[e,t]=g();return e!==c||d!==t}function p(e){let t=!1,i="";if(e>=63)return t=!0,i="64above",{status:t,reason:i};if(e===a.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK)return t=!0,i="activatedGrocery",{status:t,reason:i};if(e===a.sR.AUTO_SHOW_SPB_CASHBACK_LANDING)return t=!0,i="spbPriority",{status:t,reason:i};const[n,o]=g();let r;return r=e<32?n:o,(1<<e&r)==1<<e?(t=!0,i="variantmaskcheck"):i="variantmaskcheckblocked",{status:t,reason:i}}function g(){const e=o.R.getMultipleVariants(n.H.autoOpenControllerMask);if(e&&e.length>0){const t=e.find((e=>e.key===r.vr.FirstMask)),i=e.find((e=>e.key===r.vr.SecondMask));if(t?.value&&i?.value)return[parseInt(t.value,10),parseInt(i.value,10)]}return[s,l]}},3274:function(e,t,i){"use strict";function n(e,t,i,n){if("CheckoutPageValidation"===t){window.InitializeExposedMethods();try{const t=performance.now();"interactive"===document.readyState||"complete"===document.readyState?window.TryIsAutoApplyValid(e,i,n,t):window.addEventListener&&window.addEventListener("DOMContentLoaded",(o=>{window.CheckAndIsAutoApplyValid(e,i,n,t)})),i++}catch(e){}}else if("ExtractCheckoutPageGMV"===t)try{window.GetAndSnedExpressCheckoutGMV(e[0]??null)}catch(e){}else if("GetCashBackResponse"===t)try{window.ProcessCashBackResponse(e[0])}catch(e){}else if("WebAssistQueryResults"===t)window.ProcessWebAssistResponse(e[1]);else if("PdpValidation"===t)try{window.ProcessPdpCashBackResponse(e[0])}catch(e){}else"SharePriceComparisonData"===t||"ShareCompleteExtractionData"===t?o(e,!0,n):"OnGenericDealsServiceResponse"===t?window.ProcessClientRequestResponse(e):("BackgroundAutoApplyComplete"===t||"PostPurchaseRewardsNotify"===t)&&o(e,!1,n,t);return i}function o(e,t,i,n){try{if(window.AOCInitializeExposedMethods(),"interactive"===document.readyState||"complete"===document.readyState){const o=performance.now();"BackgroundAutoApplyComplete"===n?window.CanAutoOpenAfterBGAAComplete(i,o,n):"PostPurchaseRewardsNotify"===n?window.CanAutoOpenAfterPostPurchaseRewards(e):t?window.CanAutoOpenAfterPDPData(e):window.CanAutoOpen(e,i,o)}else window.addEventListener&&window.addEventListener("DOMContentLoaded",(n=>{t?window.CheckAndCanAutoOpenAfterPDPData(e):window.CheckAndCanAutoOpen(e,i)}))}catch(e){return!1}}i.d(t,{U:function(){return n},g:function(){return o}})},7355:function(e,t,i){"use strict";var n=i(72370),o=i(82315),r=i(44922),a=i(83879);t.Z=class{constructor(){(0,n.Z)(this,"retailerData",void 0)}async Init(){this.retailerData=o.Z.getApiResponse()?.retailerData??null,this.isPinterestScenario()&&await this.triggerPinterestScenario()}PostValidation(){return Promise.resolve()}isPinterestScenario(){return"pinterest.com"===this.retailerData?.domainName}async triggerPinterestScenario(){try{if(!this.retailerData)return;const e=a.Z.GetValidatorModule();let t;return t=await e.RetrieveGuestDomain(this.retailerData.getCurrentCheckoutPage())?r.S.PinterestDeals:r.S.NoPinterestDeals,void e.SendValidationMessage(!1,t,this.retailerData.domainName)}catch(e){}}}},84178:function(e,t,i){"use strict";var n=i(52056);t.Z=class{SendMessage(e,t){n.Z.SendMessage(e,t)}SendStringStorageMessage(e,t){n.Z.SendStringStorageMessage(e,t)}SendBoolStorageMessage(e,t){n.Z.SendStorageMessage(e,JSON.stringify({value:t}))}}},69442:function(e,t,i){"use strict";var n=i(4872),o=i(31656),r=i(77776),a=i(82315);t.Z=class{Init(){const e=a.Z.getApiResponse();return o.R.isExperimentActive(n.H.showPaymentOptions)&&r.Z.GetAndSendExpressCheckoutPageGMV(e),Promise.resolve()}PostValidation(){return Promise.resolve()}}},15267:function(e,t,i){"use strict";i.d(t,{AS:function(){return c},Ae:function(){return f},E:function(){return v},IL:function(){return m},Im:function(){return b},RT:function(){return u},Tb:function(){return h},aB:function(){return S},ql:function(){return g},sB:function(){return C},vU:function(){return l}});var n=i(5144),o=i(3634),r=i(29247),a=i(45822),s=i(56577);const l=(e,t)=>{const i=e.split(":")[1];return i&&t.includes(i)?h(i,t):""},c=(e,t)=>{try{const i=e.split(":")[1];if(!i)return"";const n=p(t),r=n?.pathname;if(!r)return"";const[a,s]=i.split(o.P5),l=r.split(a)[1];return s?l.split(s)[0]:l}catch(e){return""}},d=(e,t)=>{try{const i=new RegExp(e.toLowerCase());if(i){const e=t.toLowerCase().match(i),n=e?.groups&&e.groups.orderid||"";if(n)return n}}catch(e){}return""},u=(e,t)=>{try{if(!e||!t)return"";const i=d(e,t);if(i)return i;const n=e.replace("\\","\\\\");return d(n,t)}catch(e){return""}},h=(e,t)=>{const i=t.split("?")[1],n=new URLSearchParams(i);for(const t of n.entries())if(t[0].includes(e))return t[1];return null},p=e=>{try{return new URL(e)}catch(e){return}},g=(e,t)=>{const i=e?.split(",")??[];for(let e of i)if(e.startsWith(o.$S)||e.startsWith(o.js)){const i=l(e,t);if(i)return i}else if(e.startsWith(o.m7)){const i=c(e,t);if(i)return i}return""},f=e=>e.startsWith(o.$S)||e.startsWith(o.m7)||e.startsWith(o.js),m=(e,t,i)=>{try{if(t.length>0&&i){const o=(e=>{switch(e){case n.GV.CheckoutPage:return n.u3.Checkout;case n.GV.ConfirmationPage:return n.u3.PurchaseConfirmed}})(e);for(const e of t)if(e.urlRegex&&(!o||e.type===o)&&(0,a.io)(i,e.urlRegex))return e}return}catch(e){return}},v=(e,t,i,o,r)=>{const s=(0,a.dQ)(e,t,r);if(s!==n.GV.UnknownPage)return s;const l=((e,t,i)=>{if(e?.orderConfirmationPageUrl&&(0,a.io)(t,e.orderConfirmationPageUrl)&&i){if(!i.confirmationPageValidationSelector)return n.GV.ConfirmationPage;if(y(i,t))return n.GV.ConfirmationPage}return e?.checkoutPageUrl&&(0,a.io)(t,e.checkoutPageUrl)?n.GV.CheckoutPage:e?.productPageUrlRegex&&(0,a.io)(t,e.productPageUrlRegex)||e?.productPageUrl&&(0,a.io)(t,e.productPageUrl)?n.GV.ProductPage:e?.searchQueryUrlRegex&&(0,a.io)(t,e.searchQueryUrlRegex)?n.GV.SearchPage:n.GV.UnknownPage})(i,e,o);return l!==n.GV.UnknownPage&&l!==n.GV.HomePage?l:((e,t)=>{try{if(e.length>0&&t)for(const i of e)if(i.urlRegex&&(0,a.io)(t,i.urlRegex)){if(i.type!==n.u3.PurchaseConfirmed)return i.type===n.u3.Checkout?n.GV.CheckoutPage:n.GV.UnknownPage;{if(!i.validationSelector)return n.GV.ConfirmationPage;if(document.querySelector(i.validationSelector))return n.GV.ConfirmationPage;const e=C(i);if(u(e,t))return n.GV.ConfirmationPage}}return n.GV.UnknownPage}catch(e){return n.GV.UnknownPage}})(i?.allAutomatedSelectors||[],e)},y=(e,t)=>{if(e.confirmationPageValidationSelector&&document.querySelector(e.confirmationPageValidationSelector))return!0;const i=e.transactionIdSelector||"";if(i){if(document.querySelector(i))return!0;if(g(i,t))return!0}return!1},C=e=>b(e?.urlFields),b=e=>e?e[s.Fw.OrderId]??"":"",S=(e,t)=>{if(e&&e.length>0)for(let i=0;i<e.length;i++)if((0,r.VJ)(e[i].checkoutPageUrl,e[i].pageUrlRegex,t))return e[i]}},68813:function(e,t,i){"use strict";i.d(t,{Oh:function(){return h},ZQ:function(){return p},tW:function(){return d}});var n=i(4872),o=i(31656),r=i(73557),a=i(65302);let s=function(e){return e.Vulnerable="Vulnerable",e.Campaign="Campaign",e}({});const l=new Map([[s.Vulnerable,n.H.shoppingCohortsVulnerable],[s.Campaign,n.H.shoppingCohortsReclaimed]]);function c(e){if(!o.R.isExperimentActive(e))return[];try{const t=o.R.getMultipleVariants(e);let i=o.R.getVariantStringValue(t,"allowedCohortIds","");return""===i&&(i=o.R.getVariantName(e)||""),""===i?[]:i.split(",").map((e=>parseInt(e)))}catch{return[]}}function d(){const e=new Set([]);for(const t of l.values())c(t)?.forEach((t=>e.add(t)));return e}function u(e,t){if(t?.cohortsConfig)for(const i of t.cohortsConfig)if(void 0!==i.enabledPopupOriginations&&void 0!==i.cohortId&&e.has(i.cohortId))return i.enabledPopupOriginations}function h(e,t,i){const n=u(t,i);return void 0===n||n.findIndex((t=>t===e))>-1}function p(e,t,i,n){const o=u(t,n);if(void 0===o)return!0;const s=(void 0===i?[]:i).map((e=>(0,a.Pw)(e)||r.sR.AUTO_SHOW_COUPONS_CHECKOUT));0===s.length&&s.push(r.sR.AUTO_SHOW_COUPONS_CHECKOUT);const l=s.every((e=>o.includes(e)));if(!l){const t={pageValidations:i,popupOriginations:s,userSettings:n};e(JSON.stringify(t))}return l}},11849:function(e,t,i){"use strict";var n=i(29247),o=i(36493),r=i(52056);class a{static async WaitAndGetCartValue(e,t,i){const r=e;let s={OrderTotal:-1,Currency:(0,o.N6)(t)??"$",PageCurrency:""};return n.ZP.IsValidDataField(r)&&(s=await n.ZP.WaitForCondition((async()=>a.GetCartValue(r,t)?.OrderTotal>0),i??1e4).then((()=>a.GetCartValue(r,t))).catch((()=>s))),s}static async WaitAndGetCartValue2(e,t,i){let r={OrderTotal:-1,Currency:(0,o.N6)(t)??"$",PageCurrency:""};return n.ZP.IsValidDataField(e)&&(r=await n.ZP.WaitForCondition((async()=>a.TrySimpleGetCartValue(e,t)?.OrderTotal>0),i??1e4).then((()=>a.TrySimpleGetCartValue(e,t))).catch((()=>r))),r}static TrySimpleGetCartValue(e,t){const i=document.querySelector(e);let n=-1,r=(0,o.N6)(t)??"$";const a=i?.textContent??"";n=(0,o.K)(a);const s=(0,o.cU)(a,!0);return r=(0,o.Cl)(s,t),{OrderTotal:n,Currency:r,PageCurrency:s}}static GetCartValue(e,t){let i=-1,n=(0,o.N6)(t)??"$";const a=r.Z.GetOrderTotalString(e);i=(0,o.K)(a)??-1;const s=(0,o.cU)(a,!0);return n=(0,o.Cl)(s,t),{OrderTotal:i,Currency:n,PageCurrency:s}}}t.Z=a},52056:function(e,t,i){"use strict";var n=i(72370),o=i(64865),r=i(84830),a=i(5144),s=i(39088),l=i(29247),c=i(71544),d=i(27689),u=i(9448),h=i(79249),p=i(90066),g=i(31024),f=i(49206),m=i(77594);class v{static SetFullAOCActive(e){this.isFullAOCActive=e}static GetBoxValue(e){if(l.ZP.IsValidDataField(e))try{const t=v.GetTextValue(e);return t?t.trim():t}catch(e){throw Error(e.message)}return""}static ParseBackgroundAutoApplyStateData(e){const t=v.GetBackgroundAutoApplyStateString(e);return(0,o.TF)(t)?null:h.Z.CreateFromObject(JSON.parse(t))}static GetBackgroundAutoApplyStateString(e){const t=g.Z.GetBackgroundAAKeyName();return"string"==typeof e[t]?e[t]:e[t]?.value}static parseDate(e){const t=e?.split(",");let i,n="";if(1===t?.length){const o=(new Date).getDate(),r=new Date;if(r.setHours(0,0,0,0),r.setDate(o+1),i=r,n=t[0].trim().split("-")[1],!n)throw new Error(`Unable to parse date: ${e}`)}else if(2===t?.length){const e=t[1].trim(),n=t[0].trim().split(" "),o=n[1].trim(),r=n[0].trim();i=new Date(`${o} ${r} ${e}`)}else if(3===t?.length){if(t[0].toLowerCase().includes("today"))i=new Date,i.setHours(0,0,0,0);else{const e=(new Date).getFullYear(),n=t[1].trim().split(" "),o=n[1].trim(),r=n[0].trim();i=new Date(`${r} ${o}, ${e}`)}if(n=t[2].trim().split("-")[1],!n)throw new Error(`Unable to parse date: ${e}`)}else i=new Date("");if(!n)return i;try{const e=this.parseHour(n);if(Number.isNaN(e))return i;i.setHours(e)}catch(e){}return i}static parseHour(e){let t=+e?.match(/\d{1,2}/i)[0];const i=e?.match(/(A|P)M/i)[0];return"pm"===i.toLowerCase()&&(t+=12),+t}static SendLogEvent(e,t,i,n,o,r,s,l){const c={Currency:o,Domain:l??(0,d.S8)(),EdgeFlyoutStatus:s?.EdgeFlyoutStatus,Metadata:s?.Metadata,PageUrl:(0,d.Ek)(),StartingPrice:n??-1,Status:i};v.SendLogEventMessage(c,r??a.R.CheckoutPageValidation,e,t,a.in.Information)}static SendLogEventMessage(e,t,i,n,o){const a={};a.JsonData=JSON.stringify(e),a.EventType=t,a.LogLevel=o,a.Message=n,a.ClientContext=new r.Z(c.Z.GetClientName(),s.W1,c.Z.GetBuildVersion(),c.Z.enabledServiceFlights),i&&(a.ImpressionId=i);const l=[JSON.stringify(a)];v.SendMessage(u.H.LogScriptTelemetry,l)}static SendMessage(e,t){this.isFullAOCActive?f.f.postMessageToHost(e,t):m.p.postMessageToHost(e,t)}static StartEdgeDriver(e,t){this.Invoke(u.H.StartEdgeDriver,e,t)}static SendStorageMessage(e,t){v.SendMessage(u.H.SetStorageValue,[e,t])}static DeleteKeyFromPersistentStorage(e){v.SendStorageMessage(e,JSON.stringify({value:null}))}static SendNavigateToUrlMessage(e){v.SendMessage(u.H.NavigateToUrlBackground,[e,e])}static SendStringStorageMessage(e,t){v.SendMessage(u.H.SetStorageValue,[e,JSON.stringify({value:t})])}static SendNumberStorageMessage(e,t){v.SendMessage(u.H.SetStorageValue,[e,JSON.stringify({value:t})])}static SendBooleanStorageMessage(e,t){v.SendMessage(u.H.SetStorageValue,[e,JSON.stringify({value:t})])}static SendPurchaseConfirmationLog(e,t,i,n,o,r){const s={CartId:o,Currency:r?.Currency,Domain:e,PageCurrency:r?.PageCurrency,PageUrl:(0,d.Ek)(),StartingPrice:r?.OrderTotal??-1,Status:n};v.SendLogEventMessage(s,a.R.PurchaseConfirmation,t,i,a.in.Information)}static GetValidationLogMessage(e,t,i){return e?"Checkout Page is Valid":t?"Checkout Page is disabled or does not exist":i?"Checkout Page is Invalid - Invalid Selectors":"Checkout Page is Invalid"}static GetOrderTotalString(e,t){if(!l.ZP.IsValidDataField(e))return"";const i=e.split(",");for(let e=0;e<i.length;e++){const n=i[e];try{const e=v.GetBoxValuePageQueryUtils(n,t);if(e&&e.match(/[0-9]/))return e}catch(t){if(e===i.length-1)return""}}return""}static IsValidPDPUrlHeuristic(e,t=""){return!(0,o.TF)(e)&&e.includes(t)&&e.includes("/")&&!e.endsWith("#")&&!["help","credit","conditions","privacy","terms","about","faq","returns","careers","account"].some((t=>e.includes(t)))}static Invoke(e,...t){this.isFullAOCActive?f.f.postMessageToHost("Invoke",[e,...t]):m.p.postMessageToHost("Invoke",[e,...t])}static GetBoxValuePageQueryUtils(e,t){if(l.ZP.IsValidDataField(e))try{return p.Z.GetTextValue(e,t)}catch(e){throw Error(e.message)}return""}static GetTextValue(e){const t=e.split(";"),i=p.Z.GetFirstVisibleElement(t[0]);let n=i;if(void 0===n)return"";let o=n.innerText;if(1===t.length)n=p.Z.NormalizeIfSuperscripted(i),o=n.innerText;else{const e=p.Z.GetFirstVisibleElement(t[1]);if(e&&e.innerText){const t="."+e.innerText;if(n.contains(e)){const e=n.cloneNode(!0);e.childNodes.forEach((t=>{t.nodeType===Node.ELEMENT_NODE&&e.removeChild(t)})),o=e?.innerText?e.innerText:o}o+=t}}return p.Z.StripInvalidJSONCharacters(o)}}(0,n.Z)(v,"isFullAOCActive",!1),t.Z=v},83879:function(e,t,i){"use strict";i.d(t,{Z:function(){return Ne}});var n=i(72370),o=i(23825),r=i(55648),a=i(59518),s=i(98574),l=i(74113),c=i(98011),d=i(43263),u=i(20546),h=i(82960),p=i(5144),g=i(29247),f=i(36493),m=i(33491),v=i(27900),y=i(43686),C=i(14440),b=i(52056);function S(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function x(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?S(Object(i),!0).forEach((function(t){(0,n.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):S(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var T=i(73688),w=i(39088),O=i(71544),P=i(27689),A=i(69315),E=i(90066),k=class{isCancellationPageValid(e){return!(!e.cancellationPageTelemetry?.cancellationPageUrlRegex||""===e.cancellationPageTelemetry.cancellationPageUrlRegex)&&new RegExp(e.cancellationPageTelemetry.cancellationPageUrlRegex,"i").test((0,P.Ek)())}GetAndSendCancellationPageData(e,t){let i="";e?.cancellationPageTelemetry?.transactionIdSelector&&""!==e?.cancellationPageTelemetry?.transactionIdSelector&&(i=b.Z.GetBoxValue(e.cancellationPageTelemetry.transactionIdSelector));let n="";e?.cancellationPageTelemetry?.totalPriceSelector&&""!==e?.cancellationPageTelemetry?.totalPriceSelector&&(n=b.Z.GetBoxValue(e.cancellationPageTelemetry.totalPriceSelector));let o="";e?.cancellationPageTelemetry?.cancellationTextSelector&&""!==e?.cancellationPageTelemetry?.cancellationTextSelector&&(o=b.Z.GetBoxValue(e.cancellationPageTelemetry.cancellationTextSelector));let r="",a="";if(e?.cancellationPageTelemetry?.productTitleSelector&&""!==e?.cancellationPageTelemetry?.productTitleSelector){const t=E.Z.RunQuerySelectorAll(e?.cancellationPageTelemetry?.productTitleSelector);if(t.length>0)for(const e of t)e&&e.textContent&&(r+=e.textContent?.trim()+"<SEP>")}let s="";if(e?.cancellationPageTelemetry?.pricePerItemSelector&&""!==e?.cancellationPageTelemetry?.pricePerItemSelector){const t=E.Z.RunQuerySelectorAll(e?.cancellationPageTelemetry?.pricePerItemSelector);if(t.length>0)for(const e of t)e&&e.textContent&&(s+=e.textContent?.trim()+"<SEP>")}if(e?.cancellationPageTelemetry?.productQuantitySelector&&""!==e?.cancellationPageTelemetry?.productQuantitySelector){const t=E.Z.RunQuerySelectorAll(e?.cancellationPageTelemetry?.productQuantitySelector);if(t.length>0)for(const e of t)e&&e.textContent&&(a+=e.textContent?.trim()+"<SEP>")}const l={CancellationPageUrl:(0,P.Ek)(),Domain:(0,P.S8)(),TransactionId:i,CancellationPageText:o,ProductNames:r,QuantityPerItem:a,PricePerItem:s,TotalPrice:n},c={};c.JsonData=JSON.stringify(l),c.EventType="CancellationPageDetails",c.LogLevel="Information",c.Message="Cancellation Page Details",c.ClientContext={AppInfoClientName:O.Z.GetClientName(),JSVersion:w.yJ},t&&(c.ImpressionId=t);const d=[JSON.stringify(c)];A.R.postMessageToHost("LogScriptTelemetry",d)}},I=i(7664),D=i(61241),_=i(49206),N=i(77594),R=i(82270),M=i(91495),L=i(9839),B=i(45822),F=i(92572),U=i(11501),H=class{constructor(){(0,n.Z)(this,"IsBatBeaconFound",!1),(0,n.Z)(this,"DISALLOWED_NAMES",new Set(["addr","city","cell","dob","email","data-gtm","mob","phone","secret","social","ssn","tel","zip","pass","payment","cvv","ccv"]))}GetPageType(e,t,i){if((0,B.$1)())return p.GV.UnknownPage;const n=(0,B.dQ)(t,i,e?.aFDMarket??"");if(n!==p.GV.UnknownPage)return n;const o=(0,B.p_)(e?.retailerData,t);return o!==p.GV.UnknownPage&&o!==p.GV.HomePage?o:(0,B.I2)(e?.retailerData?.allAutomatedSelectors||[],t)}IsCollectionAllowed(e){return"en-us"!==e||this.isPrivacyBadgeShown()}isPrivacyBadgeShown(){return!!M.Q?.PrivacyBadgeViewCount&&parseInt(M.Q.PrivacyBadgeViewCount,10)>=2}collectCheckoutPurchaseEventAndFragment(){const e=F.Z.getFactory().getPurchaseExtractionService(),t=F.Z.getFactory().getFragmentCollectionService();e.runExtraction().then((({shouldLogFragment:e,dataToLog:i})=>{if(e){const e=t.getBrokenAttributionCollectionRate(),n=i?JSON.stringify(i):"";t.RunFragmentCollection(!0,`Broken required fields: ${n}`,e)}})),t.RunFragmentCollection()}CollectData(e){try{const t=Ne.GetLocalDataService()?.GetSessionIds(),i=this.getAnid(),n="";F.Z.initFactory(e,t,i,n);const o=F.Z.getFactory().getFragmentCollectionService();return"complete"===document.readyState?this.collectCheckoutPurchaseEventAndFragment():document.onreadystatechange=()=>{"complete"===document.readyState&&this.collectCheckoutPurchaseEventAndFragment()},o.isNewCollectionFlagEnabled()}catch(e){const t={errorMsg:e.Message};return L.Q.sendLogEventMessageV2(t,p.R.HtmlFragment,"","CollectData:::failed to extract data from page",p.in.Error),!1}}CollectFragment(e){if((0,B.hy)(e)&&this.CollectData(e))return;const t=(0,B.P4)();if((e.retailerData?.isAOCFragmentCollectionEnabled||t)&&(0,P.Ek)()?.startsWith("https:")&&this.IsCollectionAllowed(e?.aFDMarket)){const i=(0,P.Ek)(),n=t?"1":e.retailerData?.aOCFragmentCollectionRate??"0",o=Math.random();if(n&&o<parseFloat(n)){const t=e.retailerData?.domainName??(0,P.S8)(),o=this.GetPageType(e,i,t),r=(0,B.nY)(),a=!r||r&&(0,B.Ak)(o),s=Ne.GetLocalDataService(),l=s.GetSessionIds()?.retailerSessionId??"",c=s.GetSessionIds()?.pageVisitId??"";if(a){const i=new U.Z(e?.retailerData?.settings).GetFragmentCollectionTimeout(o)??0;"complete"===document.readyState?setTimeout((async()=>{this.sendHtmlFragment(t,"",n,o,e?.impressionId??"",l,c)}),i):document.onreadystatechange=()=>{"complete"===document.readyState&&setTimeout((async()=>{this.sendHtmlFragment(t,"",n,o,e?.impressionId??"",l,c)}),i)}}}}}async CollectFragmentOnConfirmationPage(e,t,i,n=!0){try{const o=(0,B.P4)();if(!this.IsCollectionAllowed(t)&&!o)return;const r=p.GV.ConfirmationPage,a=(0,P.Ek)(),s=new U.Z(e?.retailerData?.settings),l=o?1:s.GetCollectionRate(a,r,n)??0;if(l>0&&Math.random()>=l)return;const c=Ne.GetLocalDataService(),d=c.GetSessionIds()?.retailerSessionId??"",u=c.GetSessionIds()?.pageVisitId??"",h=e?.retailerData?.domainName??"";this.sendHtmlFragment(h,"",`${l}`,r,e.impressionId,d,u,i,!0)}catch(e){}}getAnid(){try{const e=M.Q.rawStorageObj,t=e?.productTrackingData?JSON.parse(e.productTrackingData):void 0;return t?._anid||""}catch(e){}return""}async sendHtmlFragment(e,t,i,n,o,r,a,s="",l=!1){let c=-1,d=null;if(l){d=this.cloneNodeWithPlaceholders(document.body,!1,performance.now());const t=performance.now();this.MaskPiiData(d,e),c=performance.now()-t}else{const e=performance.now();d=this.cloneNodeWithPlaceholders(document.body,!1,performance.now()),this.IsBatBeaconFound=!1,c=performance.now()-e}const u={Domain:e,TimeToMask:c.toString(),PageType:n,PageUrl:(0,P.Ek)(),EncryptionKey:"",HtmlFragment:"",aOCFragmentCollectionRate:i,RetailerSessionId:r,PageVisitId:a,isConfirmationPage:`${l}`};if(!d)return;if(t){const e=await this.getSymmetricEncryptionKey(),i=await this.encryptData(e,d.outerHTML),n=await this.encryptSymmetricKey(t,e);u.EncryptionKey=n,u.HtmlFragment=i}else{let e=d;const t=document?.head?.querySelector("title")?.textContent;if(t){const i=document.createElement("html"),n=document.createElement("head"),o=document.createElement("title");o.textContent=t,n.appendChild(o),i.appendChild(n),d&&i.appendChild(d),e=i}u.HtmlFragment=btoa(encodeURIComponent(e?.outerHTML))}if(!u.HtmlFragment)return;let h=l?"[Confirmation] Html Fragment collection":"[AOC] Html Fragment collection";s&&(h=`${h}; ${s}`),l?this.sendConfirmtionPageLog(u,h):L.Q.sendLogEventMessageV2(u,p.R.HtmlFragment,o,h,p.in.Information)}sendConfirmtionPageLog(e,t,i=!1){const n={};n.JsonData=JSON.stringify(e),n.EventType="HtmlFragment",n.LogLevel=i?"Error":"Information",n.Message=t,n.ClientContext={AppInfoClientName:O.Z.GetClientName(),JSVersion:w.yJ};const o=[JSON.stringify(n)];A.R.postMessageToHost("LogScriptTelemetryV2",o)}MaskPiiData(e,t){const i=e?.getElementsByTagName("*"),n=new Set(["script"]),o=performance.now();try{for(let e=0;e<=i?.length;e++){let r=!1;const a=performance.now();if(a-o>3e5)return void this.sendConfirmationPageHtmlFragmentLogError(window.location.pathname,t,"Masking timeout",(a-o).toString());if(void 0!==i[e]&&null!==i[e]&&null!==i[e].textContent){if("yes"===i[e].getAttribute("data-processed"))continue;(n.has(i[e].tagName?.toLowerCase())||this.DISALLOWED_NAMES.has(i[e].getAttribute("name")))&&(this.maskTextNodes(i[e]),r=!0);const t=i[e].getAttributeNames();for(const n of t)for(const t of this.DISALLOWED_NAMES)if(i[e].getAttribute(n)?.toLowerCase()?.includes(t)){r||(this.maskTextNodes(i[e]),r=!0),i[e].setAttribute("value","****");break}i[e].setAttribute("data-processed","yes")}}}catch(e){this.sendConfirmationPageHtmlFragmentLogError(window.location.pathname,t,"Masking error: "+e,(performance.now()-o).toString())}return!0}maskTextNodes(e){if(e&&"yes"!==e.getAttribute("data-processed")){"SCRIPT"===e.tagName?.toLocaleUpperCase()&&(e.textContent="Mask script content");for(const t of e.children)3===t.nodeType||4===t.nodeType?t.textContent="Masked":this.maskTextNodes(t),t.setAttribute("data-processed","yes");e.setAttribute("data-processed","yes")}}cloneNodeWithPlaceholders(e,t,i){if(performance.now()-i>12e4)return null;if("SCRIPT"===e.tagName?.toLocaleUpperCase())return null;if(e.nodeType===Node.TEXT_NODE){const i=e.cloneNode(!1);return t&&(i.textContent="*****"),i}if(e.nodeType===Node.ELEMENT_NODE){if("hidden"===window.getComputedStyle(e).visibility)return null;if(!this.IsBatBeaconFound){const t=e.getAttribute("id");if(t&&t.startsWith("batBeacon"))return null;this.IsBatBeaconFound=!0}const t=e.cloneNode(!1);let n=!1;const o=e.getAttributeNames();for(const t of o){if(this.DISALLOWED_NAMES.has(t.toLowerCase())){n=!0;break}for(const i of this.DISALLOWED_NAMES)if(e.getAttribute(t)?.toLowerCase()?.includes(i)){n=!0;break}if(n)break}for(const o of e.childNodes){const e=this.cloneNodeWithPlaceholders(o,n,i);e&&t.appendChild(e)}return t}return null}async getSymmetricEncryptionKey(){const e=await window.crypto.subtle.generateKey({name:"AES-GCM",length:128},!0,["encrypt","decrypt"]),t=await window.crypto.subtle.exportKey("raw",e);return this.bufferToBase64(t)}bufferToBase64(e){return window.btoa(String.fromCharCode(...new Uint8Array(e)))}base64ToBuffer(e){const t=window.atob(e),i=t.length,n=new Uint8Array(i);for(let e=0;e<i;e++)n[e]=t.charCodeAt(e);return n.buffer}concatArrayBuffers(e,t){const i=new Uint8Array(e.byteLength+t.byteLength);return i.set(new Uint8Array(e),0),i.set(new Uint8Array(t),e.byteLength),i.buffer}async encryptData(e,t){const i=(new TextEncoder).encode(t),n=await window.crypto.subtle.importKey("raw",this.base64ToBuffer(e),"AES-GCM",!0,["encrypt","decrypt"]),o=window.crypto.getRandomValues(new Uint8Array(12)),r={iv:o,name:"AES-GCM"},a=await window.crypto.subtle.encrypt(r,n,i),s=this.concatArrayBuffers(o.buffer,a);return this.bufferToBase64(s)}async encryptSymmetricKey(e,t){const i=await crypto.subtle.importKey("spki",this.base64ToBuffer(e),{name:"RSA-OAEP",hash:{name:"SHA-256"}},!1,["encrypt"]),n=await crypto.subtle.encrypt({name:"RSA-OAEP"},i,(new TextEncoder).encode(t));return this.bufferToBase64(n)}sendConfirmationPageHtmlFragmentLogError(e,t,i,n){const o={Domain:t,EncryptionKey:"",HtmlFragment:"",OrderConfirmationPageUrl:e,TimeToMask:n};this.sendConfirmtionPageLog(o,i,!0)}},$=i(11050),Z=i(73557),V=i(55590),G=i(8018),j=i(50607),z=i(3634),W=i(4872),K=i(31656),q=i(18491),Y=i(47746),X=class{constructor(e){(0,n.Z)(this,"ShownOffers",void 0),(0,n.Z)(this,"ImpressionId",void 0),e?(this.ShownOffers=e.ShownOffers??[],this.ImpressionId=e.ImpressionId):(this.ShownOffers=[],this.ImpressionId="")}},J=i(9448),Q=i(41310),ee=i(57550),te=i(82315),ie=i(1094),ne=i(41865),oe=i(95457),re=i(47594),ae=i(21488),se=class{constructor(){(0,n.Z)(this,"AutoShowEventsMap",void 0),(0,n.Z)(this,"ActiveAutoShowType",void 0),(0,n.Z)(this,"TotalCashbackAmount",0),this.AutoShowEventsMap={},this.ActiveAutoShowType=null}};class le{constructor(){(0,n.Z)(this,"pageVisitId",void 0),(0,n.Z)(this,"retailerSessionId",void 0),(0,n.Z)(this,"sessionId",void 0)}static Create(e){const t=new le;return t.pageVisitId=e?.pageVisitId,t.retailerSessionId=e?.retailerSessionId,t.sessionId=e?.sessionId,t}}var ce=le,de=i(33408);function ue(e){const t=e?.confirmationDetails;return!!(t&&t.transactionId&&t.purchaseTotal&&t.productNames)}var he=i(64865),pe=i(34802),ge=i(50978);function fe(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function me(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?fe(Object(i),!0).forEach((function(t){(0,n.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):fe(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var ve=class{constructor(){(0,n.Z)(this,"isPersonalizationDataConsentEnabled",void 0),(0,n.Z)(this,"cartExtractionSuccessful",void 0),(0,n.Z)(this,"mutationObserver",void 0)}async Init(){const e=Ne.GetLocalDataService(),t=e.GetCheckoutPageData(),i=e.GetImpressionId(),n=e.GetDomainName();if(!t.retailerData)return;this.isPersonalizationDataConsentEnabled=t.userInfo?.isPersonalizationDataConsentEnabled??e.IsP13nEnabled()??!1;const o=t.retailerData.getAutomatedSelectorsPageByRegex(location.href);o&&(o?.type!==p.u3.Checkout&&o?.type!==p.u3.Cart||(this.AddPersonalizedPromotionsButtonListeners(n,i,o),this.TryCheckAndCollectPersonalizedPromotionsRawInformation(n,i,o)))}async PostValidation(){}GetLastPersonalizedPromotionsCartData(){const e=(0,m.Mw)(ge.Vj);return e&&!(0,he.TF)(e)?JSON.parse(e):null}async TryCheckAndCollectPersonalizedPromotionsRawInformation(e,t,i,n){i&&this.CollectPersonalizedPromotionsCartData(e,t,i,n).catch((i=>{const n={domain:e,cartUrl:location.pathname};this.LogCartExtractionEvent(n,p.R.PersonalizedPromotionsExtractionError,i?.message,p.in.Error,t)}))}async ShouldCollectPersonalizedPromotionsCartData(e,t){const i=Date.now();return!(e&&!(0,he.TF)(t)&&t===e.OrderTotal&&!(0,he.TF)(e.RandomId)&&e.PageUrl===(0,P.Ek)()&&i-e.CartDataCreationTime<=v.l$)}async CollectPersonalizedPromotionsCartData(e,t,i,n){if(!i?.details)return;const o=new pe.Z;o.domain=e,o.pageType=i.type,o.pageUrl=(0,P.Ek)(),o.orderId=b.Z.GetBoxValue(i.details.orderId),o.randomId=h.Z.uuidv4();const r=i.details.orderTotalPrice;let a="";g.ZP.IsValidDataField(r)&&(a=await g.ZP.WaitForCondition((async()=>E.Z.RunQuerySelectorAll(r).length>0),5e3).then((async()=>b.Z.GetBoxValue(r))).catch((i=>{const n={cartId:o.randomId??"",cartUrl:location.pathname,domain:e};return this.LogCartExtractionEvent(n,p.R.PersonalizedPromotionsExtractionError,i?.message,p.in.Error,t),""})));const s=this.GetLastPersonalizedPromotionsCartData();if(!s||this.ShouldCollectPersonalizedPromotionsCartData(s,a)){try{const o=new URL(window.location.href);this.AddPageMonitor(e,t,o,i,n)}catch(e){}try{if(o.orderTotal=a,o.orderSubtotal=b.Z.GetBoxValue(i.details.orderSubTotalPrice),o.productName=await this.GetItemizedProductData(i.details.productName),o.productItemPrice=await this.GetItemizedProductData(i.details.productItemPrice),o.productTotalPrice=await this.GetItemizedProductData(i.details.productTotalPrice),o.productPrice=await this.GetItemizedProductData(i.details.productPrice),o.productQuantity=await this.GetItemizedProductData(i.details.productQuantity),o.productId=await this.GetItemizedProductData(i.details.productId),g.ZP.IsValidDataField(i.details.productImgSelector)){const e=E.Z.RunQuerySelectorAll(i.details.productImgSelector);let t="";for(const i of e){const e=i?.getAttribute("alt");e&&(t+=e+"<SEP>")}o.productNameFromImg=t}this.LogPersonalizedPromotionsCartInfo(o,e,t)}catch(e){}}}LogPersonalizedPromotionsCartInfo(e,t,i){const n=h.Z.uuidv4();this.LogCartExtractionEvent(e,p.R.ShoppingPersonalizedPromotionsRawTable,"Successfully extracted Personalized Promotions Cart Information",p.in.Information,i,n,!0);const o=new ge.JR;o.Domain=e.domain,o.OrderTotal=e.orderTotal,o.PageType=e.pageType,o.PageUrl=e.pageUrl,o.OrderId=e.orderId,o.OrderSubtotal=e.orderSubtotal,o.ProductName=e.productName,o.ProductTotalPrice=e.productTotalPrice,o.ProductItemPrice=e.productItemPrice,o.ProductQuantity=e.productQuantity,o.ProductId=e.productId,o.ExtractionId=h.Z.uuidv4(),o.CartDataCreationTime=Date.now(),o.ProductPrice=e.productPrice,o.ProductNameFromImg=e.productNameFromImg,o.RandomId=e.randomId,(0,m.NN)()||this.LogCartExtractionEvent(e,p.R.PersonalizedPromotionsExtractionError,"No access to local storage",p.in.Error,i),(0,m.Xo)(ge.Vj,JSON.stringify(o)),this.SendPersistentPersonalizedPromotionsCartMessage(t,o,i)}async GetItemizedProductData(e,t=5e3){if(!e||(0,he.TF)(e))return"";let i;return await g.ZP.WaitForCondition((async()=>(i=E.Z.GetFirstVisibleElement(e??""),void 0!==i)),t),E.Z.GetItemizedData(e??"","<SEP>")}async AddPageMonitor(e,t,i,n,o){const r="true"===n.details?.addCartMonitor,a=n.details?.cartMonitorSelector;if(r){const i={attributes:!0,characterData:!0,childList:!0,subtree:!0};this.mutationObserver||(this.mutationObserver=new MutationObserver((async i=>{this.TryCheckAndCollectPersonalizedPromotionsRawInformation(e,t,n,o)})));const r=a??n?.details?.orderTotalPrice;if(r){await g.ZP.WaitForCondition((async()=>void 0!==E.Z.GetFirstVisibleElement(r)),5e3);const e=E.Z.GetFirstVisibleElement(r);e&&(this.mutationObserver?.disconnect(),this.mutationObserver?.observe(e,i))}}else this.mutationObserver?.disconnect()}SendPersistentPersonalizedPromotionsCartMessage(e,t,i){try{const i=M.Q?.PersonalizedPromotionsCartData??"",n=(0,P.BQ)(i)??{};n[e]={cartDataStorageInfo:t,timestamp:new Date};const o=JSON.stringify({value:JSON.stringify(n)});b.Z.SendStorageMessage("PersonalizedPromotionsCartData",o)}catch(e){this.LogCartExtractionEvent(t,p.R.PersonalizedPromotionsExtractionError,"Could not send cart data to storage: "+e?.message,p.in.Error,i)}}async AddPersonalizedPromotionsButtonListeners(e,t,i){if(i?.details?.addToCartButton){const n=i.details.addToCartButton,o=await g.ZP.WaitForCondition((async()=>E.Z.HasVisibleElement(n)),5e3).then((async()=>E.Z.GetFirstVisibleElement(n)));o?.addEventListener("click",(async()=>{this.TryCheckAndCollectPersonalizedPromotionsRawInformation(e,t,i,!0)}))}else if(i?.details?.placeOrderButton){const n=i.details.placeOrderButton,o=await g.ZP.WaitForCondition((async()=>E.Z.HasVisibleElement(n)),5e3).then((async()=>E.Z.GetFirstVisibleElement(n)));o?.addEventListener("click",(async()=>{this.TryCheckAndCollectPersonalizedPromotionsRawInformation(e,t,i,!1)}))}}ShouldSendTelemetryData(e){return this.isPersonalizationDataConsentEnabled||e!==p.R.CartExtraction&&e!==p.R.TravelCheckoutExtraction&&e!==p.R.ShoppingPersonalizedPromotionsRawTable}LogCartExtractionEvent(e,t,i,n,o,r,a){let s={};this.ShouldSendTelemetryData(t)&&(s=e),a||(void 0===this.cartExtractionSuccessful&&(t===p.R.CartExtraction?this.cartExtractionSuccessful=!0:this.cartExtractionSuccessful=!1),s=me(me({},s),{},{isPersonalizationDataConsentEnabled:this.isPersonalizationDataConsentEnabled,extractionId:r??null})),b.Z.SendLogEventMessage(s,t,o,i,n)}},ye=i(7355),Ce=i(57176),be=i(29853),Se=class{constructor(){(0,n.Z)(this,"noMatchYet",void 0),(0,n.Z)(this,"passedStorageValues",void 0),(0,n.Z)(this,"supportedPlatforms",[{checkoutPages:[{selectors:["[name='reductions'],#Form0 > div:nth-child(1) > div > button,#checkout_clear_discount + button","div > aside > div > div > div > div > section:nth-child(5)>div>div>div>div>div>strong"],url:"/checkouts/c"},{selectors:["#checkout_reduction_code,.field__input-btn,#checkout_clear_discount + button,.order-summary__toggle-discount","SPAN.payment-due__price"],url:"/checkouts"},{selectors:["#checkout_reduction_code,.field__input-btn,#checkout_clear_discount + button,.order-summary__toggle-discount","SPAN.payment-due__price"],url:"/securecheckout"}],name:"Shopify"},{checkoutPages:[{selectors:["INPUT[name='couponcode'],INPUT[name='couponcode'] + .button,INPUT[name='couponcode'] + .btn,.CouponCode .button,[class*='coupon'] .button,A[href*='removecoupon'],[class*='coupon-code-add']","[class*='cart-total-grand'],tr.SubTotal:nth-last-child(1) SPAN.ProductPrice"],url:"/cart.php"},{selectors:["INPUT[name='redeemableCode'],#applyRedeemableButton,A[data-test='cart-price-callback'],A.redeemable-label","DIV.cart-priceItem--total SPAN[data-test='cart-price-value']"],url:"/checkout"},{selectors:["#couponcode,#apply_code","TR.SubTotal:nth-last-child(1) .ProductPrice"],url:"/checkout.php"}],name:"BigCommerce"},{checkoutPages:[{selectors:["#coupon_code,#discount-coupon-form BUTTON.apply,#discount-coupon-form BUTTON.cancel",".grand.totals .amount SPAN.price"],url:"/checkout/cart"},{selectors:["#discount-code,#discount-form BUTTON.action-apply,#discount-form BUTTON.action-cancel",".grand.totals .amount SPAN.price"],url:"/checkout/"}],name:"Magento"},{checkoutPages:[{selectors:["#coupon_code,#discount-coupon-form BUTTON.apply,#discount-coupon-form BUTTON.cancel,[class*='showcoupon']","#shopping-cart-totals-table tfoot .price"],url:"/checkout/cart"}],name:"Magent2"},{checkoutPages:[{selectors:["#coupon_code,#discount-coupon-form BUTTON.apply,#discount-coupon-form BUTTON.cancel,#block-discount",".grand.totals .amount SPAN.price"],url:"/checkout/cart"},{selectors:["#discount-code,#discount-form > div > button,#discount-coupon-form BUTTON.cancel,#discount-accordion",".grand.totals .amount SPAN.price"],url:"/checkout/"}],name:"Magneto1"}])}TryCheckIfPlatformDomain(e){try{this.passedStorageValues=e,this.noMatchYet=!0,this.CheckIfPlatformDomain()}catch(e){this.LogError(e)}}CheckIfPlatformDomain(){for(const e of this.supportedPlatforms)for(const t of e.checkoutPages)g.ZP.IsOnPage(t.url,location.pathname)&&g.ZP.WaitForSyncCondition((()=>this.CheckIfRequiredSelectorsExist(t.selectors)),1e4).then((t=>this.LogPlatformMatch(e.name,t)))}CheckIfRequiredSelectorsExist(e){for(const t of e)if(!E.Z.GetFirstMatchingElement(t))return!1;return this.noMatchYet&&(this.noMatchYet=!1,this.TriggerSuggestedCouponService(),this.TriggerCouponSavingsService(e)),!0}LogPlatformMatch(e,t){t?this.SendPlatformFoundMessage(e):this.SendPlatformFoundMessage("Not"+e)}LogError(e){const t={Domain:(0,P.S8)(),PageUrl:"",Status:"Error"};b.Z.SendLogEventMessage(t,p.R.PlatformDetection,"",e?.message??"Error detecting platform",p.in.Information)}SendPlatformFoundMessage(e){b.Z.SendMessage(J.H.PlatformExpansionDomain,[e])}TriggerSuggestedCouponService(){this.passedStorageValues&&(Ne.GetSuggestedCouponService(!0).Init(),Ne.GetSuggestedCouponService(!0).Update(Ce.s3.CheckoutPage,[]))}TriggerCouponSavingsService(e){const t=[...e[0].split(","),e[1]],i=this.CreateCheckoutPageUrlData(t);Ne.GetCouponSavingsService().TryListenForCoupon(i,[],"","",!0)}CreateCheckoutPageUrlData(e){const t=new be.Z;return t.inputBoxSelector=e[0],t.orderTotalDataElementSelector=e[e.length-1],t.applyButtonSelector=e.length>=3?e[1]:"",t}},xe=i(71951),Te=i(46261),we=i(90650),Oe=i(87869),Pe=i(93970),Ae=class{constructor(e,t){(0,n.Z)(this,"validator",void 0),(0,n.Z)(this,"CEService",void 0),(0,n.Z)(this,"domainName",void 0),this.validator=e,this.CEService=t}async SetUpPurchaseConfirmation(e,t,i,n,o){try{this.domainName=i;const r=await this.IsFinalCheckoutPage(e),a=e.retailerData.getCurrentFinalCheckoutPage(),s=(0,P.uf)(e?.market,e.retailerData?.exclusiveMarket);let l=await ie.Z.GetOrderTotal(a,s,t,i);Pe.ZP.sendFinalCheckoutValidationLog(this.domainName,r,t,"",l);const c=this.CEService.GetLastCartData();r?this.ListenForPurchaseConfirmation(e,l,t,c?.CartId??"",n,o):a?.domMutationEnabled&&g.ZP.ObserveUntil((()=>E.Z.HasVisibleElement(a.finalCheckoutButtonSelector)),(async()=>{l=await ie.Z.GetOrderTotal(a,s,t,i),Pe.ZP.sendFinalCheckoutValidationLog(this.domainName,!0,t,"",l),this.ListenForPurchaseConfirmation(e,l,t,c?.CartId??"",n,o)}))}catch(e){const i=e?.message??"checkoutpage purchase confirmation error.";b.Z.SendPurchaseConfirmationLog(this.domainName,t,i,"error","",void 0)}}async IsFinalCheckoutPage(e){const t=e.retailerData.getCurrentFinalCheckoutPage();return!(!t||(0,he.TF)(t.finalCheckoutButtonSelector))&&(await g.ZP.WaitForCondition((async()=>E.Z.HasVisibleElement(t.finalCheckoutButtonSelector)),5e3),E.Z.HasVisibleElement(t.finalCheckoutButtonSelector))}ListenForPurchaseConfirmation(e,t,i,n,o,r){const a=e.retailerData.getCurrentFinalCheckoutPage();if(a&&!(0,he.TF)(a.finalCheckoutButtonSelector)){const s=E.Z.GetAllVisibleElements(a.finalCheckoutButtonSelector);for(const l of s)l.addEventListener("click",(async()=>{this.validator.SendPurchaseConfirmationMessage(),b.Z.SendPurchaseConfirmationLog(this.domainName,i,"User completed purchase","completed",n,t),this.ConfirmPurchase(a,n,i,t);try{const t=(0,P.uf)(e?.market,e.retailerData?.exclusiveMarket),n=e.retailerData?.getCurrentAutomatedSelectorsPage(location.href);this.CEService.TryCheckAndCollectCartInformation(e.retailerData.domainName,i,a,t,r,n,o)}catch{}try{K.R.isExperimentActive(W.H.injectConfirmationScriptUponPurchaseCompletion)&&b.Z.SendStorageMessage("CompletedPurchase",JSON.stringify({value:!0})),b.Z.SendStorageMessage("CompletedPurchaseConf",JSON.stringify({value:!0}))}catch(e){}}))}}async ConfirmPurchase(e,t,i,n){const o=new Te.GA;o.CheckoutButtonClicked=!0,o.CheckoutTime=Date.now(),o.CartId=t,o.CartValue=n,(0,m.Xo)(Te.Wi,JSON.stringify(o)),await g.ZP.Sleep(5e3);let r=new Oe.L;g.ZP.WaitForCondition((async()=>(r=this.DidPurchaseSucceed(e),r.indicators.length>0)),5e3).then((()=>{this.LogPurchaseStatusAndCleanUp(r.purchaseFailed,i,t,n,r.indicators),r.purchaseFailed||(0,m.UZ)(v.OY)})).catch((e=>{b.Z.SendPurchaseConfirmationLog(this.domainName,i,e?.message??"Error evaluating purchase status on checkout script","error",t,n)}))}DidPurchaseSucceed(e){const t=new Oe.L;if(t.indicators=[],t.purchaseFailed=!1,E.Z.GetAllVisibleElements(e.finalCheckoutButtonSelector).length>0)return t.purchaseFailed=!0,t.indicators.push(Oe.c.finalCheckoutButtonVisible),t;const i=E.Z.GetFirstVisibleElement("body");return we.ZP.PageIncludesPaymentKeyWords(i?.innerText.toLocaleLowerCase(),we.lD)?(t.indicators.push(Oe.c.successfulPaymentKeywordsFound),t.purchaseFailed=!1,t):(we.ZP.PageIncludesPaymentKeyWords(i?.innerText.toLocaleLowerCase(),we.si)&&(t.purchaseFailed=!0,t.indicators.push(Oe.c.failurePaymentKeywordsFound)),E.Z.GetAllVisibleElements("input").length>0&&(t.purchaseFailed=!0,t.indicators.push(Oe.c.inputFieldsFound)),t)}LogPurchaseStatusAndCleanUp(e,t,i,n,o){(0,m.UZ)(Te.Wi),e||(0,m.Mw)(xe.y$.autoApplyStorageKey)===xe.M4.ActionDetected&&(b.Z.SendStringStorageMessage(xe.y$.completedPurchaseStorageKey,xe.M4.ActionDetected),(0,m.Xo)(xe.y$.completedPurchaseStorageKey,xe.M4.ActionDetected));const r=e?"Failed":"Succeeded";b.Z.SendPurchaseConfirmationLog(this.domainName,t,JSON.stringify(o),r,i,n)}},Ee=i(84178);class ke{async QueryWebAssistUrls(e,t,i){return ke.waiting=!0,ke.mojomResponse=void 0,N.p.postMessageToHost("QueryWebAssistUrls",[e,...t]),await g.ZP.WaitForCondition((async()=>!ke.waiting),7e3),ke.mojomResponse}ProcessWebAssistResponse(e){try{ke.mojomResponse=JSON.parse(e)}catch(e){ke.mojomResponse=void 0}finally{ke.waiting=!1}}}(0,n.Z)(ke,"waiting",void 0),(0,n.Z)(ke,"mojomResponse",void 0);var Ie=ke,De=i(69442);class _e{static GetValidatorModule(){return this.validator}static GetGroceryCBService(){return this.groceryCBService||(this.groceryCBService=new c.Z),this.groceryCBService}static GetZipCardService(){return this.zipCardService||(this.zipCardService=new De.Z),this.zipCardService}static GetCartExtractionService(){return(0,I.X)()}static GetPersonalizedPromotionsCartExtractionService(){return this.personalizedPromotionsCartExtractionService||(this.personalizedPromotionsCartExtractionService=new ve),this.personalizedPromotionsCartExtractionService}static GetPinterestService(){return this.pinterestService||(this.pinterestService=new ye.Z),this.pinterestService}static GetCatalogExtractionService(){return this.catalogExtractionServie||(this.catalogExtractionServie=new D.Z),this.catalogExtractionServie}static GetPlatformDetectionService(){return this.platformDetectionService||(this.platformDetectionService=new Se),this.platformDetectionService}static GetAutoApplyService(){return this.autoApplyService||(this.autoApplyService=new a.Z),this.autoApplyService}static GetHtmlFragmentCollectionService(){return this.htmlFragmentCollectionService||(this.htmlFragmentCollectionService=new H),this.htmlFragmentCollectionService}static GetCancellationPageDataExtractionService(){return this.cancellationPageDataExtractionService||(this.cancellationPageDataExtractionService=new k),this.cancellationPageDataExtractionService}static GetCouponSavingsService(){return this.couponSavingsService||(this.couponSavingsService=new R.Z),this.couponSavingsService}static GetAutomaticCartExtractionService(){return this.automaticCartExtractionService||(this.automaticCartExtractionService=new class{constructor(e){(0,n.Z)(this,"webAssistQueryService",void 0),this.webAssistQueryService=e}async TryCollectCartInformation(e,t,i,n,o,r,a){try{await this.CollectCartInformation(e,t,i,n,o,r,a)}catch(t){const i={cartId:a??"",cartUrl:location.pathname,domain:e};this.LogCartExtractionEvent(i,p.R.CartExtraction,t?.message,p.in.Error,n)}}async CollectCartInformation(e,t,i,n,o,r,a){const s=new y.Z;s.domain=e,s.cartValue=t.OrderTotal,s.currency=t.Currency,s.cartUrl=location.pathname,s.cartId=a??h.Z.uuidv4(),s.products=[];let l,c=0,d=null,u=null;if(await(0,g.dz)((async()=>(l=document.querySelectorAll("img"),void 0!==l&&l.length>0)),5e3),await(0,g._R)(1e4),l=document.querySelectorAll("img"),void 0===l||l.length<=0){const e="Unable to automatically find products in cart";this.LogCartExtractionEvent(s,p.R.CartExtractionError,e,p.in.Error,n)}else{for(const t of l){if(!this.isVisible(t))continue;if(this.isAtTopOfPage(t))continue;if(0===c&&!this.isInViewPort(t))continue;const i=this.findProductContainer(t);if(0===c&&t.offsetHeight>0){const n=this.isPotentialCartItem(t,i,e);if(!n||!i)continue;c=t.offsetHeight,d=i,s.products.push(n)}else if(c===t.offsetHeight){const n=this.isPotentialCartItem(t,i,e);if(!n||!i)continue;if(null==u){if(!d)continue;if(u=this.getCommonParent(d,i),null==u)continue}const o=Node.DOCUMENT_POSITION_CONTAINED_BY;if(!(u.compareDocumentPosition(i)&o))continue;s.products.push(n)}}if(await this.augmentWithWebAssist(s.products,e,o,r),s.products=[],s.products?.length>0){const e="Successfully automatically extracted Cart Information";this.LogCartExtractionEvent(s,p.R.CartExtraction,e,p.in.Information,n),this.StoreCartInfoInLocalStorage(s,t)}else{const i=this.scrapeCandidateUrls(e),a=await this.generateWebassistProducts(i,o,r);if(a?.length>0){s.products=a;const e="Successfully automatically extracted Cart Information via webassist scraping";this.LogCartExtractionEvent(s,p.R.CartExtraction,e,p.in.Information,n),this.StoreCartInfoInLocalStorage(s,t)}else{const e="Unable to automatically get enough info about products in cart";this.LogCartExtractionEvent(s,p.R.CartExtractionError,e,p.in.Error,n)}}}}async augmentWithWebAssist(e,t,i,n){if(!e||0===e.length)return;const o=e.map((e=>this.normalizeUrl(e.productUrl,t))),r=await this.webAssistQueryService.QueryWebAssistUrls(i,o,n);r&&e.forEach((e=>{if(e?.productUrl){const i=this.normalizeUrl(e.productUrl,t);if(this.HasValidWebAssistEntry(r,i)){const t=r[i];t.entity&&this.AugmentProductWithWebAssistProduct(e,t)}}}))}normalizeUrl(e,t){return e?e.startsWith("http")?e:`https://www.${t}${e}`:""}isVisible(e){return e.offsetHeight>0&&e.offsetWidth>0&&"hidden"!==e.style.visibility&&"none"!==e.style.display}isAtTopOfPage(e){return window.pageYOffset+(e.getBoundingClientRect()?.top??0)<200}isInViewPort(e){const t=e.getBoundingClientRect(),i=t.left,n=t.top;return!0===document.elementFromPoint(i,n)?.isSameNode(e)}isPotentialCartItem(e,t,i){if(null==t)return null;const n=t.tagName.toLocaleLowerCase();if("html"===n||"body"===n)return null;const o=[...t.querySelectorAll("a")].filter((e=>b.Z.IsValidPDPUrlHeuristic(e.href,i)));if(o.length<=0)return null;const r=o[0],a=r.href,s=new C.Z;s.productUrl=a;let l=r.innerText??r.getAttribute("title");if(""===l&&o.length>1)for(let e=1;e<o.length&&""===l;e++)l=o[e].innerText??o[e].getAttribute("title");""===l&&(l=e.getAttribute("title")??e.getAttribute("alt")??""),s.productTitle=l,s.productImg=e.getAttribute("src")??"";const c=this.GetPrices(t);return c?.length&&(s.productPrice=this.GetMinimumPrice(c)),s}GetMinimumPrice(e){const t=(0,f.cU)(e[0]);return Math.min(...e.map((e=>parseFloat(e.replace(t,"").replace(/,/g,"")))))}findProductContainer(e){let t=e.parentElement;for(;null!=t&&"BODY"!==t.nodeName;){const e=this.GetPrices(t);if(e?.length&&t.querySelector("a"))return t;t=t.parentElement}return null}GetPrices(e){const t=(0,f.cU)(e.innerText);if(t&&(0,f.$g)(t)){const i=new RegExp("("+(0,f.So)(t)+"[0-9,]+(?:.[0-9]{1,2}){0,1})","g");return e.innerText.match(i)}return[]}getCommonParent(e,t){let i=e.parentElement;if(e===t)return i;if(null==i)return null;const n=Node.DOCUMENT_POSITION_CONTAINED_BY;let o=i.compareDocumentPosition(t);for(;!(o&n);){if(i=i.parentElement,null==i)return null;o=i.compareDocumentPosition(t)}const r=i.tagName.toLocaleLowerCase();return"html"===r||"body"===r?null:i}HasValidWebAssistEntry(e,t){return e.hasOwnProperty(t)}AugmentProductWithWebAssistProduct(e,t){const i=t.entity;e.foundInWebAssist=!0,e.webAssistTitle=t.title??i.name,e.webAssistImg=i.image;const n=this.CleanWebAssistPrice(i.price_value);n&&(e.webAssistPrice=n)}scrapeCandidateUrls(e){const t=Array.from(document.querySelectorAll("a")).filter((e=>e.href&&""!==e.href&&"#"!==e.href)).filter((e=>!this.isAtTopOfPage(e))).map((e=>e.href)).filter((t=>b.Z.IsValidPDPUrlHeuristic(t,e)));return[...new Set(t)]}async generateWebassistProducts(e,t,i){const n=await this.webAssistQueryService.QueryWebAssistUrls(t,e,i),o=[];if(n)for(const e in n)if(n[e].entity){const t=new C.Z;t.productUrl=e,this.AugmentProductWithWebAssistProduct(t,n[e]),o.push(t)}return o}LogCartExtractionEvent(e,t,i,n,o){const r=Ne.GetLocalDataService(),a=r.GetSessionIds()?.retailerSessionId??"",s=r.GetSessionIds()?.pageVisitId??"";e=x(x({},e),{},{PageVisitId:s,RetailerSessionId:a}),b.Z.SendLogEventMessage(e,t,o,i,n)}StoreCartInfoInLocalStorage(e,t){const i=new v.Vr;i.OrderTotal=t.OrderTotal,i.CartDataCreationTime=Date.now(),i.CartId=e.cartId,(0,m.Xo)(v.OY,JSON.stringify(i))}CleanWebAssistPrice(e){if(e)try{const t=(e=e.replace(/\s/g,"")).split("-");return(0,f.K)(t[0])}catch(e){}}}(_e.GetWebAssistQueryService())),this.automaticCartExtractionService}static GetPurchaseDetectionService(){return this.purchaseDetectionService||(this.purchaseDetectionService=new Ae(_e.GetValidatorModule(),_e.GetCartExtractionService())),this.purchaseDetectionService}static GetICValidatorService(){return this.icValidatorService}static GetIcSearchProcessorService(){return this.icSearchProcessorService}static GetIcPDPProcessorService(){return this.icPDPProcessorService}static GetLocalDataService(){return this.localDataService}static GetValidationMessageService(){return this.validationMessageService}static GetAutosMarketplaceService(){return this.autosMarketplaceService}static GetWebAssistQueryService(){return this.webAssistQueryService||(this.webAssistQueryService=new Ie),this.webAssistQueryService}static GetSuggestedCouponService(e=!1){return this.suggestedCouponsService||(this.suggestedCouponsService=new o.Z(b.Z.SendStorageMessage.bind(b.Z),e)),this.suggestedCouponsService}static GetOtherSellersService(){return this.otherSellersService}static GetAAConsentService(){return this.aaConsentService}static GetProductBestCouponConsentService(){return this.productBestCouponConsentService}static GetClippingService(){return this.clippingService}static GetClientRequestsService(){return this.clientRequestsService}static GetPageDetectionService(){return this.pageDetectionService}static GetBackgroundAAService(){return this.backgroundAAService}}(0,n.Z)(_e,"localDataService",new class{constructor(){(0,n.Z)(this,"impressionId",void 0),(0,n.Z)(this,"icNotificationType",void 0),(0,n.Z)(this,"mapData",void 0),(0,n.Z)(this,"userInfo",void 0),(0,n.Z)(this,"clientInfo",void 0),(0,n.Z)(this,"isRebatesEnabled",void 0),(0,n.Z)(this,"isP13nEnabled",void 0),(0,n.Z)(this,"isEdgeProfileRebatesUser",void 0),(0,n.Z)(this,"consentCanPrompt",void 0),(0,n.Z)(this,"itemLevelCashBackDta",void 0),(0,n.Z)(this,"domainName",void 0),(0,n.Z)(this,"traceId",void 0),(0,n.Z)(this,"isClippingSent",void 0),(0,n.Z)(this,"submittedIds",void 0),(0,n.Z)(this,"personalizedCashbackData",void 0),(0,n.Z)(this,"isPendingTransactionPresent",!1),(0,n.Z)(this,"searchApiRequestSentTimestamp",0),(0,n.Z)(this,"merchantData",void 0),(0,n.Z)(this,"coupons",void 0),(0,n.Z)(this,"isFinalCheckoutPage",void 0),(0,n.Z)(this,"isAOCActive",void 0),(0,n.Z)(this,"market",void 0),(0,n.Z)(this,"isExpressCheckoutPage",void 0),(0,n.Z)(this,"muid",void 0),(0,n.Z)(this,"params",void 0),(0,n.Z)(this,"isAADSignedIn",void 0),(0,n.Z)(this,"hasValidLinkedAccount",void 0),(0,n.Z)(this,"sessionIds",void 0),(0,n.Z)(this,"ConfirmationPageData",void 0),(0,n.Z)(this,"autoApplyStatus",!1),(0,n.Z)(this,"isCheckoutPage",void 0),(0,n.Z)(this,"userSettingsData",void 0),this.mapData=new Map,this.userInfo=new ae.Z,this.clientInfo=new ne.Z,this.isExpressCheckoutPage=!1}SetParams(e){this.params=e}SetImpressionId(e){this.impressionId=e}SetDomainName(e){this.domainName=e}EarlyFetchConfirmationPageData(e){this.ConfirmationPageData=async function(e,t){if(!e||!t||!function(e,t){return!(!e||!t)&&new RegExp(e,"i").test(t)}(e.orderConfirmationPageUrl,t))return Promise.resolve(void 0);const i=await(0,de._p)(e.confirmationPageTelemetry,e.domainName);return i?.confirmationDetails?{confirmationDetails:i.confirmationDetails,canNotifyOnConfirmationPage:ue(i)}:void 0}(e,(0,P.Ek)())}EarlyFetchIsCheckoutPage(e){this.isCheckoutPage=ie.Z.isCheckoutPageBySelectors(e,Ne.GetValidatorModule())}async GetConfirmationPageData(e){return this.ConfirmationPageData||this.EarlyFetchConfirmationPageData(e),await this.ConfirmationPageData}async GetIsCheckoutPage(e){return this.isCheckoutPage||this.EarlyFetchIsCheckoutPage(e),await this.isCheckoutPage}SetMarket(e){this.market=e}SetICNotificationType(e){this.icNotificationType=e}SetTraceId(e){this.traceId=e}SetIsClippingSent(e){this.isClippingSent=e}SetCheckoutPageData(e){this.merchantData=e}SetCoupons(e){this.coupons=e}SetIsFinalCheckoutPage(e){this.isFinalCheckoutPage=e}SetIsAOCActive(e){this.isAOCActive=e}GetParams(){return this.params}GetIsAOCActive(){return this.isAOCActive}GetIsFinalCheckoutPage(){return this.isFinalCheckoutPage}GetCheckoutPageData(){return this.merchantData}GetCoupons(){return this.coupons}GetIsClippingSent(){return this.isClippingSent}GetTraceId(){return this.traceId}GetMarket(){return this.market}GetICNotificationType(){return this.icNotificationType}GetImpressionId(){return this.impressionId??""}GetDomainName(){return this.domainName??""}SetIsExpressCheckoutPage(e){this.isExpressCheckoutPage=e}IsExpressCheckoutPage(){return this.isExpressCheckoutPage}SetItemLevelCashbackData(e){this.itemLevelCashBackDta=e}SetClientInfo(e){this.clientInfo=e}GetClientInfo(){return this.clientInfo}SetSubmittedIds(e){this.submittedIds=e}GetSubmittedIds(){return this.submittedIds}SetIsRebatesEnabled(e){this.isRebatesEnabled=e}IsrebatesEnabled(){return this.isRebatesEnabled}SetIsP13nEnabled(e){this.isP13nEnabled=e}IsP13nEnabled(){return this.isP13nEnabled}SetIsEdgeProfileRebatesUser(e){this.isEdgeProfileRebatesUser=e}IsEdgeProfileRebatesUser(){return this.isEdgeProfileRebatesUser}SetConsentCanPrompt(e){this.consentCanPrompt=e}ConsentCanPrompt(){return this.consentCanPrompt}SetIsAADSignedIn(e){this.isAADSignedIn=e}IsAADSignedIn(){return this.isAADSignedIn}SetHasValidLinkedAccount(e){this.hasValidLinkedAccount=e}HasValidLinkedAccount(){return this.hasValidLinkedAccount}GetItemLevelCashbackData(){return this.itemLevelCashBackDta}SetUserInfo(e){this.userInfo=e}GetUserInfo(){return this.userInfo}GetData(e){return this.mapData.get(e)}SetData(e,t){return this.mapData.set(e,t)}SetAutoApplyStatus(e){this.autoApplyStatus=e||this.autoApplyStatus}GetAutoApplyStatus(){return this.autoApplyStatus}SetPersonalizedAdsResponse(e){this.personalizedCashbackData=e}GetPersonalizedAdsResponse(){return this.personalizedCashbackData}SetIsPendingTransactionPresent(e){this.isPendingTransactionPresent=e}GetIsPendingTransactionPresent(){return this.isPendingTransactionPresent}SetSearchApiRequestSentTimestamp(e){this.searchApiRequestSentTimestamp=e}GetSearchApiRequestSentTimestamp(){return this.searchApiRequestSentTimestamp}SetSessionIds(e){this.sessionIds=ce.Create(e)}SetUserSettingsData(e,t,i){if(i&&!(e.length<=t))try{this.userSettingsData=JSON.parse(e[t])}catch(e){}}GetUserSettingsData(){return this.userSettingsData}GetSessionIds(){return this.sessionIds}SetMuidFromUHId(e){if(e)try{const t=window.atob(e);t&&(this.muid=t)}catch(e){}}GetMuid(){return this.muid}}),(0,n.Z)(_e,"validationMessageService",new Ee.Z),(0,n.Z)(_e,"validator",new Pe.ZP(_e.GetLocalDataService())),(0,n.Z)(_e,"personalizedPromotionsCartExtractionService",new ve),(0,n.Z)(_e,"zipCardService",new De.Z),(0,n.Z)(_e,"groceryCBService",void 0),(0,n.Z)(_e,"catalogExtractionServie",new D.Z),(0,n.Z)(_e,"automaticCartExtractionService",void 0),(0,n.Z)(_e,"purchaseDetectionService",new Ae(_e.GetValidatorModule(),_e.GetCartExtractionService())),(0,n.Z)(_e,"platformDetectionService",new Se),(0,n.Z)(_e,"htmlFragmentCollectionService",new H),(0,n.Z)(_e,"cancellationPageDataExtractionService",new k),(0,n.Z)(_e,"couponSavingsService",new R.Z),(0,n.Z)(_e,"autosMarketplaceService",new T.Z),(0,n.Z)(_e,"icValidatorService",new class{constructor(){(0,n.Z)(this,"localDataService",void 0),(0,n.Z)(this,"validationMessageService",void 0),(0,n.Z)(this,"domainData",void 0),(0,n.Z)(this,"apiResponse",void 0)}async Init(){this.apiResponse=te.Z.getApiResponse(),this.localDataService=Ne.GetLocalDataService(),this.validationMessageService=Ne.GetValidationMessageService();const e=ne.Z.Create(this.apiResponse),t=ae.Z.Create(this.apiResponse);this.domainData=oe.Z.Create(this.apiResponse?.itemLevelCashBack?.domainData||""),this.localDataService.SetUserInfo(t),this.localDataService.SetClientInfo(e),this.localDataService.SetSubmittedIds(this.apiResponse?.itemLevelCashBack?.submittedOfferIds||[]),this.localDataService.SetPersonalizedAdsResponse(this.apiResponse?.personalizedAdsResponse?.personalizedCashback),this.localDataService.SetData("variations",JSON.stringify(this.apiResponse?.itemLevelCashBack?.variations));const i=M.Q?.ICIsPendingTransactionPresent??!1;this.localDataService.SetIsPendingTransactionPresent(i),this.apiResponse?.itemLevelCashBack?.isCashBackEnabled&&this.localDataService.SetItemLevelCashbackData(this.apiResponse.itemLevelCashBack)}CanAutoOpen(e){const t=this.localDataService.GetItemLevelCashbackData();if(!t?.isCashBackEnabled)return Promise.resolve(!1);let i=this.ValidateGroceryCashback(e);if(i)if(this.localDataService.GetICNotificationType()===G.c.Search||this.localDataService.GetICNotificationType()===G.c.Category||this.localDataService.GetICNotificationType()===G.c.ActivatedOffers){let e=!1;const t=this.apiResponse.retailerData.getCurrentCheckoutPage();if(t){const n=ie.Z.GetInitialFields(this.apiResponse);(t?.orderTotalDataElementSelector||n.length>0)&&(e=!0,i=!1)}if(!e)return Promise.resolve(!1)}else this.localDataService.GetICNotificationType()!==G.c.GroceryAutoShow&&this.localDataService.GetICNotificationType()!==G.c.AddedToCartPDP||Q.Z.IsVariationString(this.localDataService,`gcbAutoshow-${this.localDataService.GetICNotificationType()}`,"disabled")&&(b.Z.SendStringStorageMessage(V.Q.ICNotificationType,""),i=!1);return Promise.resolve(i)}PostValidation(){return Promise.resolve()}GetPopupOriginationList(){return[Z.sR.AUTO_SHOW_SPB_CASHBACK_LANDING,Z.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK_LANDING,Z.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK]}async CanAutoOpenForFeature(e){const t=this.localDataService.GetItemLevelCashbackData();if(!t?.isCashBackEnabled)return Promise.resolve(!1);const i=this.ValidateGroceryCashback(),n=this.localDataService.GetICNotificationType();switch(e){case Z.sR.AUTO_SHOW_SPB_CASHBACK_LANDING:return!1;case Z.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK_LANDING:return i&&(n===G.c.GroceryAutoShow||n===G.c.AddedToCartPDP);case Z.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK:return Boolean(i&&n===G.c.Activated&&M.Q?.GroceryCashbackItem)}return!1}IsSeachPage(e,t){const i={isSerp:!1,searchKey:""};if(t&&t.SearchData){const n=Q.Z.IsUrlMatchAll(e,t.SearchData);i.isSerp=n.isMatch,i.searchKey=n.matchKey}return i}IsCategoryPage(e,t){const i={isCategory:!1,categoryId:""};if(t&&t.CategoryData){const n=Q.Z.IsUrlMatchAll(e,t.CategoryData);i.isCategory=n.isMatch,i.categoryId=n.matchKey}return i}SendGetCashbackMessage(e,t,i,n){const o=[];i===q.x.Search?o.push({keyword:t}):i===q.x.Category?o.push({category:t}):i===q.x.Offers&&t.split(",").forEach((e=>{o.push({offerId:e})}));const r=this.localDataService.GetUserInfo(),a=this.localDataService.GetClientInfo(),s=this.localDataService.IsrebatesEnabled(),l=this.localDataService.IsP13nEnabled(),c=this.localDataService.IsEdgeProfileRebatesUser(),d=this.localDataService.ConsentCanPrompt(),u=this.localDataService.GetIsPendingTransactionPresent(),h={ageGroup:r.ageGroup,clientContext:n,consentCanPrompt:d,domainName:e,isAADSignedIn:r.isAADSignedIn,isAnonymousFlowEnabled:r.isAnonymousFlowEnabled,isPendingTransaction:u,isEdgeProfileRebatesUser:c,isOffTheRecord:a.isOffTheRecord,isPersonalizationDataConsentChanged:r.isPersonalizationDataConsentChanged,isPersonalizationDataConsentEnabled:r.isPersonalizationDataConsentEnabled,isPersonalizationDataConsentEnabledV2:l,isRebatesEnabled:s,isRebatesUser:r.isRebatesUser,jsVersion:w.W1,pageUrl:(0,P.Ek)(),queries:o,queryType:i};this.localDataService.SetSearchApiRequestSentTimestamp((new Date).getTime()),this.validationMessageService.SendMessage(J.H.GetCashBack,[JSON.stringify(h)])}ValidateGroceryCashback(e){try{const t=new URL((0,P.Ek)()),i=this.localDataService.GetItemLevelCashbackData(),n=this.localDataService.GetCheckoutPageData(),o=this.localDataService.GetClientInfo(),r=this.localDataService.GetUserInfo(),a=this.domainData;if(this.validationMessageService.SendStringStorageMessage(V.Q.ICCurrentPageInfo,""),!this.IsAddedToCartPage(t,a)&&M.Q.ICRelatedPDPOffer){const e=JSON.parse(M.Q.ICRelatedPDPOffer),i=new URL(e.RelatedOfferShownURL);t&&i&&t.hostname===i.hostname&&t.pathname===i.pathname||this.validationMessageService.SendStringStorageMessage(V.Q.ICRelatedPDPOffer,"")}if(this.HandleActivatedAutoNotification()){const e=M.Q?.GroceryInstantAddToCart;return!e}const s=n?.retailerData?.domainName??"",l={appName:O.Z.GetClientName(),buildVersion:o.buildVersion,enabledfeatures:K.R.GetExpRawData()},c=t.searchParams.get("activatedOffers");if(null!==c)return this.HandleActivatedOffers(c,s,l),!0;if(null!==t.searchParams.get("showCashbackOffers")){this.localDataService.SetICNotificationType(G.c.GroceryAutoShow);const e=M.Q?.GroceryAutoShowData?(0,P.BQ)(M.Q.GroceryAutoShowData):new se;return e.ActiveAutoShowType="ShowCashbackOffers",this.validationMessageService.SendStringStorageMessage(V.Q.GroceryAutoShowData,JSON.stringify(e)),this.validationMessageService.SendStringStorageMessage(V.Q.ICNotificationType,G.c.GroceryAutoShow),!0}if(i.isSearchEnabled){const n=this.IsApplicableForSearchAndCategoryScenario(e),o=this.IsSeachPage(t,a);if(o.isSerp&&n&&this.HandleSearchPage(o.searchKey,s,l))return!0;const c=this.IsCategoryPage(t,a);if(c.isCategory&&n&&this.HandleCategoryPage(c.categoryId,s,l,a.categoryAutoShowCooldownInSeconds))return!0;if(r.isRebatesUser){const e=this.IsCustomAutoShowPage(t,a);if(e.isMatch&&this.HandleCustomAutoShowPage(s,e.autoShowType,e.cooldownInSeconds,i))return!0}}if(this.IsAddedToCartPage(t,a)&&M.Q.ICRelatedPDPOffer)return this.localDataService.SetICNotificationType(G.c.AddedToCartPDP),this.validationMessageService.SendStringStorageMessage(V.Q.ICNotificationType,G.c.AddedToCartPDP),!0;if(n?.retailerData?.getCurrentCheckoutPage()?.pageType===p.GV.HomePage){const e=i.spbHomePageOffers,t=e?.find((e=>e.shouldAutoshow&&e.offersType===$.h.SPB&&e.offers?.length>0));if(e&&t){const e=M.Q.ICSpbHomePageShownTimestamp||"0",t=Number(e),i=isNaN(t)?0:t,n=(new Date).getTime(),o=n-i,r=216e5;if(K.R.isTestFlagActive(re.t.msShoppingTestExp11)||0===i||o>r)return this.localDataService.SetICNotificationType(G.c.SpbHomePage),this.validationMessageService.SendStringStorageMessage(V.Q.ICNotificationType,G.c.SpbHomePage),this.validationMessageService.SendStringStorageMessage(V.Q.ICSpbHomePageShownTimestamp,`${n}`),!0}}}catch(e){return!1}return!1}IsAddedToCartPage(e,t){return!!(t&&t.AddedToCartData&&Q.Z.IsUrlMatchAll(e,t.AddedToCartData).isMatch)}IsApplicableForSearchAndCategoryScenario(e){return!e||e==Z.sR.AUTO_SHOW_SPB_CASHBACK_LANDING}IsCustomAutoShowPage(e,t){const i={isMatch:!1,autoShowType:"",cooldownInSeconds:0};if(t&&t.CustomAutoShowData)for(const n of t.CustomAutoShowData){const t=Q.Z.IsUrlMatchAll(e,n.matchData);if(t?.isMatch)return i.isMatch=t.isMatch,i.autoShowType=n.autoShowType,i.cooldownInSeconds=n.coolDownInSeconds,i}return i}HandleActivatedAutoNotification(){return!(!M.Q?.GroceryCashbackItem||!M.Q?.ICActivatedPending||(this.localDataService.SetICNotificationType(G.c.Activated),this.validationMessageService.SendStringStorageMessage(V.Q.ICNotificationType,G.c.Activated),this.validationMessageService.SendBoolStorageMessage(V.Q.ICActivatedPending,!1),0))}HandleSearchPage(e,t,i){return!!e&&(this.SendGetCashbackMessage(t,e,q.x.Search,i),this.localDataService.SetICNotificationType(G.c.Search),this.localDataService.SetData("query",e),!0)}HandleCategoryPage(e,t,i,n){return!!e&&(this.SendGetCashbackMessage(t,e,q.x.Category,i),this.localDataService.SetICNotificationType(G.c.Category),n&&this.localDataService.SetData("categoryCooldown",n.toString()),!0)}HandleCustomAutoShowPage(e,t,i,o){try{const r=M.Q?.GroceryAutoShowData?(0,P.BQ)(M.Q.GroceryAutoShowData):new se,a=r?.AutoShowEventsMap[e]?r.AutoShowEventsMap[e]:[],s=a?.filter((e=>e.AutoShowType===t));s?.sort(((e,t)=>e.AutoShowTimestamp-t.AutoShowTimestamp));const l=Q.Z.GetTotalCashbackFromOffers(o?.itemizedCashback);if(l&&l>0&&(0===s?.length||this.GetSecondsSince(s[0].AutoShowTimestamp)>i)){const o=a?.filter((e=>e.AutoShowType!==t));return o?.push(new class{constructor(e,t,i){(0,n.Z)(this,"AutoShowType",void 0),(0,n.Z)(this,"AutoShowTimestamp",void 0),(0,n.Z)(this,"CooldownInSeconds",void 0),this.AutoShowTimestamp=t,this.AutoShowType=e,this.CooldownInSeconds=i}}(t,Date.now(),i)),r.AutoShowEventsMap[e]=o,r.ActiveAutoShowType=t,r.TotalCashbackAmount=l,this.validationMessageService.SendStringStorageMessage(V.Q.GroceryAutoShowData,JSON.stringify(r)),this.validationMessageService.SendStringStorageMessage(V.Q.ICNotificationType,G.c.GroceryAutoShow),this.localDataService.SetICNotificationType(G.c.GroceryAutoShow),!0}return!1}catch(e){return!1}}GetSecondsSince(e){return(Date.now()-e)/1e3}HandleActivatedOffers(e,t,i){this.localDataService.SetICNotificationType(G.c.ActivatedOffers),this.localDataService.SetData("domain",t),this.SendGetCashbackMessage(t,e,q.x.Category,i)}}),(0,n.Z)(_e,"autoApplyService",new a.Z),(0,n.Z)(_e,"icSearchProcessorService",new class{constructor(){(0,n.Z)(this,"localDataService",void 0),(0,n.Z)(this,"validationMessageService",void 0),(0,n.Z)(this,"autosMarketplaceService",void 0),(0,n.Z)(this,"cashBackResponseStr","")}async Init(){this.localDataService=Ne.GetLocalDataService(),this.validationMessageService=Ne.GetValidationMessageService(),this.autosMarketplaceService=Ne.GetAutosMarketplaceService()}async PostValidation(){}GetPopupOriginationList(){return[Z.sR.AUTO_SHOW_SPB_CASHBACK_LANDING,Z.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK_LANDING]}async CanAutoOpenForFeature(e){const{isSpbNotification:t,shouldSendMessage:i}=this.ProcessCashBackResponse(this.cashBackResponseStr);return e===Z.sR.AUTO_SHOW_SPB_CASHBACK_LANDING?i&&t:e===Z.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK_LANDING&&i&&!t}async CanAutoOpen(){const{shouldSendMessage:e}=this.ProcessCashBackResponse(this.cashBackResponseStr);return e}SetCashbackResponseStr(e){this.cashBackResponseStr=e}ProcessCashBackResponse(e){let t=!1,i=!1,n=!1;const o={sentTimeMs:this.localDataService.GetSearchApiRequestSentTimestamp(),receivedTimeMs:(new Date).getTime()};this.localDataService.SetSearchApiRequestSentTimestamp(0);try{if(e){const r=JSON.parse(e);let a=this.localDataService.GetICNotificationType();if(this.HasCashbackOffers(r)){const e=this.GetOffersType(r)===$.h.Quotient,s=this.localDataService.GetDomainName(),l={};l.query=this.localDataService.GetData("query");let c="";if(e){const e=this.GetQtShouldShow(r,s);e.categoryName&&(l.categoryName=e.categoryName),e.addressBarTemplate&&(c=e.addressBarTemplate),e.notificationType&&e.shouldSendMessage&&(a=e.notificationType,i=e.shouldSendMessage)}else{const e=this.GetSpbShouldShow(r,s);e.notificationType&&e.shouldSendMessage&&(a=e.notificationType,i=e.shouldSendMessage,n=!0)}if(l.cashbackData=r,l.currentUrl=(0,P.Ek)(),l.type=a,l.latencyData=o,K.R.isExperimentActive(W.H.spbCheckoutAutoActivation)&&"amazon.com"===s&&this.IsCheckoutPage()){const e=new CustomEvent(z.fU,{detail:{jsonResponse:l}});window.dispatchEvent(e),i=!1,n=!1}this.validationMessageService.SendStringStorageMessage(V.Q.ICCurrentPageInfo,JSON.stringify(l)),this.validationMessageService.SendMessage(J.H.UpdateAddressBar,[JSON.stringify({type:c})]),t=!0,this.validationMessageService.SendMessage(J.H.UpdateLoadTimeData,[this.localDataService.GetTraceId()])}else r?.autosResponse&&this.autosMarketplaceService.processCashBackResponseForAutosMarketplace(r?.autosResponse)}}catch(e){}return t||this.validationMessageService.SendStringStorageMessage(V.Q.ICCurrentPageInfo,""),{shouldSendMessage:i,isSpbNotification:n}}LogSPBTelemetry(e,t,i,n={}){const o=this.localDataService.GetImpressionId(),r=this.localDataService.GetUserInfo();Q.Z.LogSPBTelemetry(e,t,i,r,o,n)}GetSecondsSince(e){return(Date.now()-e)/1e3}IsCheckoutPage(){const e=te.Z.getApiResponse(),t=ie.Z.CreateCheckoutPageData(e).retailerData.getCurrentCheckoutPage(location.pathname);return t&&t.pageType===p.GV.CheckoutPage}GetQtShouldShow(e,t){let i,o=!1,r="",a="";const s=this.GetActivatedOfferIds(t),l=this.GetShownOffers(t),c=this.GetSubmittedOffersSet(),d=e.itemizedCashBackResponse.queryType;if(d===q.x.Search){const t=Y.Z.CreateFromUAPIList(e.itemizedCashBackResponse.offers);r="SearchGeneric",this.ShouldAutoshow(e)&&this.ContainsOffersNotShownNonActivatedNotSubmitted(t,l,s,c)&&(this.validationMessageService.SendStringStorageMessage(V.Q.ICNotificationType,G.c.Search),o=!0,i=G.c.Search)}else if(d===q.x.Category){const s=Y.Z.CreateFromUAPIList(e.itemizedCashBackResponse.offers);r="CategoryGeneric",s[0].cashbackProducts&&s[0].cashbackProducts.length>0&&(a=s[0].cashbackProducts[0].displayCategory);const l=Q.Z.GetTotalCashback(s),c=this.localDataService.GetData("categoryCooldown");if(c&&l&&l>0){const e=M.Q.GroceryCategoryAutoShowData?(0,P.BQ)(M.Q.GroceryCategoryAutoShowData):new class{constructor(){(0,n.Z)(this,"AutoShowTimestampsMap",void 0),this.AutoShowTimestampsMap={}}},r=e.AutoShowTimestampsMap;(!r[t]||this.GetSecondsSince(r[t])>Number(c))&&(e.AutoShowTimestampsMap[t]=Date.now(),this.validationMessageService.SendStringStorageMessage(V.Q.GroceryCategoryAutoShowData,JSON.stringify(e)),this.localDataService.SetICNotificationType(G.c.CategoryAutoshow),this.validationMessageService.SendStringStorageMessage(V.Q.ICNotificationType,G.c.CategoryAutoshow),o=!0,i=G.c.CategoryAutoshow)}}else if(d===q.x.Offers){const n=M.Q.GroceryCashbackActivated;let r={};n&&(r=(0,P.BQ)(M.Q.GroceryCashbackActivated)),(!r[t]||r[t]&&!r[t].fullItems)&&(r[t]={fullItems:{}});const a=Y.Z.CreateFromUAPIList(e.itemizedCashBackResponse.offers),s={};a.filter((e=>e.cashbackProducts.length>0)).reverse().forEach((e=>{const t=e.id;s[t]=e})),Object.keys(r[t].fullItems).forEach((e=>{const i=r[t].fullItems[e],n=i.id;s[n]=i})),r[t].fullItems=s;let l=0;const c=[];Object.keys(s).forEach((e=>{const t=s[e],i=parseFloat(t.offerValue);c.length<3&&t.cashbackProducts?.length>0&&t.cashbackProducts[0].title&&c.push({imageUrl:t.imageUrl,title:t.cashbackProducts[0].title}),l+=i})),this.validationMessageService.SendStringStorageMessage(V.Q.ICActivatedCashbackTotal,l.toFixed(2)),this.validationMessageService.SendStringStorageMessage(V.Q.ICActivatedCashbackImages,JSON.stringify({images:c})),this.validationMessageService.SendStringStorageMessage(V.Q.GroceryCashbackActivated,JSON.stringify(r)),this.validationMessageService.SendStringStorageMessage(V.Q.ICNotificationType,G.c.ActivatedOffers),this.validationMessageService.SendBoolStorageMessage(V.Q.ICActivationMigrationPending,!0),o=!0,i=G.c.ActivatedOffers}return{shouldSendMessage:o,notificationType:i,addressBarTemplate:r,categoryName:a}}GetSpbShouldShow(e,t){let i,n=!1;if(K.R.isExperimentActive(W.H.disableSPBNotification))return this.LogSPBTelemetry(p.xu.ICSPBOffersNoShow,"SPB notification disabled by experiment disableSPBNotification",e),{notificationType:i,shouldSendMessage:n};const o=(0,ee.Sq)(e);let r=o.find((e=>e.source===$.h.SPB));if(e?.itemizedCashBackResponse?.offersType!==$.h.SPB||r||(r=o.length>0?o[0]:void 0),r){const t=e?.itemizedCashBackResponse?.shouldAutoshow??!1,a=this.localDataService.GetPersonalizedAdsResponse(),s=(0,ee.rP)(o,a),l=(0,ee.wu)(e),c=this.containsOfferToAutoShow(o);r.visibilityFeedbackUrlBase=l,t&&c&&s?.length>0?(this.validationMessageService.SendStringStorageMessage(V.Q.ICNotificationType,G.c.SearchSPB),this.localDataService.SetICNotificationType(G.c.SearchSPB),n=!0,i=G.c.SearchSPB,this.LogSPBTelemetry(p.xu.ICSPBOffersCanShow,"","")):this.LogSPBTelemetry(p.xu.ICSPBOffersNoShow,t?"Non-activated items are not there":`Should autoshow is falsecontainOfferToAutoShow ${c}`,e)}else this.LogSPBTelemetry(p.xu.ICSPBOffersNoShow,"No SPB offers, check again",e);return{notificationType:i,shouldSendMessage:n}}containsOfferToAutoShow(e){for(const t of e){if(void 0===t.shouldAutoshow||null===t.shouldAutoshow)return!0;if((0,g.Nx)(t.shouldAutoshow))return!0}return!1}GetSubmittedOffersSet(){try{const e=this.localDataService.GetSubmittedIds();if(e&&e.length>0)return new Set(e)}catch(e){}return new Set}HasCashbackOffers(e){return!!(e&&e.itemizedCashBackResponse&&e.itemizedCashBackResponse.offers&&e.itemizedCashBackResponse.offers.length>0)}GetOffersType(e){return e?.itemizedCashBackResponse?.offersType??""}ShouldAutoshow(e){return e&&e.itemizedCashBackResponse&&e.itemizedCashBackResponse.shouldAutoshow}ContainsOffersNotShownNonActivatedNotSubmitted(e,t,i,n){let o=!1;const r=this.localDataService.GetDomainName(),a=this.localDataService.GetData("variations"),s=a?JSON.parse(a):{},l=!!s.searchIgnoreAlreadyShown&&"enabled"===s.searchIgnoreAlreadyShown;try{let a="";for(const r of e)if((l||!t.has(r.id))&&!i.has(r.id)&&!n.has(r.id)){o=!0,a=r.id;break}if(o){t.add(a);const e={},i=new X(void 0);i.ShownOffers=Array.from(t),i.ImpressionId=this.localDataService.GetImpressionId(),e[r]=i,this.validationMessageService.SendStringStorageMessage(V.Q.ICAutoShownOffers,JSON.stringify(e))}}catch(e){o=!1}return o}GetActivatedOfferIds(e){const t=M.Q?.GroceryCashbackActivated,i=((0,P.BQ)(t)??{})[e]??void 0;return i?.fullItems?new Set(Object.keys(i.fullItems)):new Set}GetShownOffers(e){const t=(0,P.BQ)(M.Q?.ICAutoShownOffers)??{},i=this.localDataService.GetImpressionId();t&&t[e]&&t[e].ImpressionId!==i&&delete t[e];const n=new X(t[e]).ShownOffers;return new Set(n)}}),(0,n.Z)(_e,"icPDPProcessorService",new class{constructor(){(0,n.Z)(this,"localDataService",void 0),(0,n.Z)(this,"validationMessageService",void 0),(0,n.Z)(this,"cashBackResponse",void 0)}async Init(){this.localDataService=Ne.GetLocalDataService(),this.validationMessageService=Ne.GetValidationMessageService()}GetPopupOriginationList(){return[Z.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK_LANDING,Z.sR.AUTO_SHOW_SPB_CASHBACK_LANDING]}CanAutoOpen(){const e=this.localDataService.GetCheckoutPageData(),t=e?.retailerData?.domainName||"";if(!this.cashBackResponse)return!1;const{shouldShow:i}=this.ProcessPDPResponse(this.cashBackResponse,t);return i}async CanAutoOpenForFeature(e){const t=this.localDataService.GetCheckoutPageData(),i=t?.retailerData?.domainName||"";if(!this.cashBackResponse)return!1;const{isSpb:n,shouldShow:o}=this.ProcessPDPResponse(this.cashBackResponse,i);switch(e){case Z.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK_LANDING:return o&&!n;case Z.sR.AUTO_SHOW_SPB_CASHBACK_LANDING:return o&&n}return!1}async PostValidation(){}SetCashbackResponse(e){this.cashBackResponse=e}ProcessPDPResponse(e,t){let i=!1;try{const o=Ne.GetLocalDataService().GetSubmittedIds()||[],r=this.localDataService.GetIsClippingSent(),a=this.localDataService.GetUserInfo(),s=this.localDataService.GetImpressionId(),l=M.Q?.ICIsPendingTransactionPresent??!1;if(e.offersType===$.h.Quotient&&l)return(0,j.LT)(e,a,s,"Pending transaction is present"),{shouldShow:!1,isSpb:i};let c=!1,d=G.c.PDP;if(e.offersType===$.h.Quotient){c=(0,j.mg)(e,t,o,[],r);const l=this.localDataService.GetData("variations"),u=l?JSON.parse(l):{},h=!!u.relatedOfferOnAddToCart&&"enabled"===u.relatedOfferOnAddToCart,p=(0,j.$d)(e,t,[]);if(p&&h){const e=new class{constructor(e,t){(0,n.Z)(this,"RelatedOffer",void 0),(0,n.Z)(this,"RelatedOfferShownURL",void 0),this.RelatedOffer=e,this.RelatedOfferShownURL=t}}(p,(0,P.Ek)());this.validationMessageService.SendStringStorageMessage(V.Q.ICRelatedPDPOffer,JSON.stringify(e))}if(!c)return{shouldShow:!1,isSpb:i};d=G.c.PDP,(0,j.iQ)(e,a,s)}else if(e.offersType===$.h.SPB){if(i=!0,c=(0,j.WL)(e),!c)return{shouldShow:!1,isSpb:i};d=G.c.PdpSPB,(0,j.jV)(e,a,s)}const u={};return u.cashbackData=e,u.currentUrl=(0,P.Ek)(),u.type=d,u.pageTitle=(0,P.AL)(),this.validationMessageService.SendStringStorageMessage(V.Q.ICCurrentPageInfo,JSON.stringify(u)),this.localDataService.SetICNotificationType(d),this.validationMessageService.SendStringStorageMessage(V.Q.ICNotificationType,d),{shouldShow:!0,isSpb:i}}catch(t){(0,j.LT)(e,void 0,this.localDataService.GetImpressionId(),"Unknown error",!0)}return{shouldShow:!1,isSpb:i}}}),(0,n.Z)(_e,"suggestedCouponsService",void 0),(0,n.Z)(_e,"webAssistQueryService",void 0),(0,n.Z)(_e,"otherSellersService",new d.Z),(0,n.Z)(_e,"clippingService",new l.Z),(0,n.Z)(_e,"aaConsentService",new r.Z),(0,n.Z)(_e,"productBestCouponConsentService",new u.Z),(0,n.Z)(_e,"pinterestService",void 0),(0,n.Z)(_e,"clientRequestsService",new class{constructor(){(0,n.Z)(this,"MaxWaitTime",7e3),(0,n.Z)(this,"responseMap",{})}async Init(){}async PostValidation(){}async SendRequest(e,t,i){const n=h.Z.uuidv4(),o=JSON.stringify({serviceName:e,methodName:t,requestBody:JSON.stringify(i)});this.responseMap[n]=void 0,_.f.postMessageToHost("FireGenericDealsRequest",[n,o]),N.p.postMessageToHost("FireGenericDealsRequest",[n,o]),await g.ZP.WaitForCondition((async()=>void 0!==this.responseMap[n]),this.MaxWaitTime);const r=this.responseMap[n];if(delete this.responseMap[n],void 0!==r&&r.length>=3&&"200"===r[2]){const e=JSON.parse(r[1]);if("OK"===e?.errorCode&&e?.responseBody)return e.responseBody}return null}ProcessClientRequestResponse(e){if(e.length>=3){const t=e[0];Object.keys(this.responseMap).includes(t)&&void 0===this.responseMap[t]&&(this.responseMap[t]=e)}}}),(0,n.Z)(_e,"pageDetectionService",new class{constructor(){(0,n.Z)(this,"regexList",void 0),this.regexList=[/^(?!.*setting).*(\bcheckout|\bpayment\b)/i,/^(?!.*add).*(\bcart\b|\bbasket\b)/i]}async Init(){}async PostValidation(){}CheckAndLogUrl(e){const t=window.location.href;if(this.UrlNotInRetailerData(e,t))for(const i of this.regexList)if(i.test(t))return void this.LogUrlAndMatchedRegex(t,i,e)}UrlNotInRetailerData(e,t){const i=e.retailerData?.getCurrentCheckoutPage(t);return!i||"/"===i.checkoutPageUrl}LogUrlAndMatchedRegex(e,t,i){const n={Domain:i.retailerData?.domainName,PageUrl:e,Regex:t.source};b.Z.SendLogEventMessage(n,p.R.PageDetectionRegexMatched,i.impressionId,"Url not in retailer data matched regex",p.in.Information)}}),(0,n.Z)(_e,"backgroundAAService",new s.Z);var Ne=_e},93970:function(e,t,i){"use strict";i.d(t,{EI:function(){return x},J6:function(){return S},OE:function(){return b}});var n=i(72370),o=i(59645),r=i(40843),a=i(5144),s=i(73557),l=i(29247),c=i(36493),d=i(91495),u=i(8553),h=i(9448),p=i(90066),g=i(43916),f=i(1094),m=i(44922),v=i(86743),y=i(68813),C=i(52056);let b=function(e){return e.CouponClipping="18",e.BellIconNotifClick="25",e}({}),S=function(e){return e.CouponClipping="31",e.BellIconNotifClick="40",e}({}),x=function(e){return e.AutoShowAvailable="AutoShowAvailable",e.AutoOpenError="AutoOpenError",e.LogScriptTelemetry="LogScriptTelemetry",e.SetStorageValue="SetStorageValue",e.FallbackValidation="FallbackValidation",e.RecordAutoShowPrevented="RecordAutoShowPrevented",e.UpdateAddressBar="UpdateAddressBar",e.EndOfScript="EndOfScript",e.StoreJourneyStage="StoreJourneyStage",e.SetPackageTrackingConsent="SetPackageTrackingConsent",e.StartPackageTracking="StartPackageTracking",e.LogScriptTelemetryV2="LogScriptTelemetryV2",e.BGAAComplete="BGAAComplete",e.DataExtracted="DataExtracted",e.TriggerExperiment="TriggerExperiment",e}({});class T{static sendFinalCheckoutValidationLog(e,t,i,n,o){const r=o?.OrderTotal;t?C.Z.SendPurchaseConfirmationLog(e,i,"Valid Final Checkout Page","true",n,o):r&&-1!==r&&C.Z.SendPurchaseConfirmationLog(e,i,"Invalid Final Checkout Page","false",n,o),r&&-1!==r&&f.Z.SendGMVMessage(r,o?.Currency??"$",T.traceId)}static async ValidateProductOutOfStock(e,t,i,n){if(!t?.productOutOfStockSelector)return!1;const s=window.location.href;if((n=new r.Z(n)).isUnsupportedDomain)return!1;const d=u.ZP.IsTrackedProductForAOC(s);let h=!1;try{if(!await l.ZP.WaitUntilCondition((async()=>p.Z.HasVisibleElement(t?.productOutOfStockSelector)),2e3))return!1;let n,r,u,g="$";if(t?.productImageSelector){const e=p.Z.GetFirstMatchingElement(t?.productImageSelector);r=e?.src}if(t?.productTitleSelector){const e=p.Z.GetFirstMatchingElement(t?.productTitleSelector);n=e?.innerText}if(t?.productPriceSelector){const i=p.Z.GetFirstMatchingElement(t?.productPriceSelector),n=i?.innerText;n&&n.length&&(g=(0,c.cU)(n)||(0,c.N6)(e.exclusiveMarket||"en-us")||"$",u=(0,c.K)(n))}const f=JSON.stringify({currency:g,productImage:r,productPrice:u,productTitle:n,productUrl:s,status:"OUT_OF_STOCK"});if(n&&s&&(h=!0),!n||!r){const t=new o.Z(a.xu.ProductTrackingDebug);t.Metadata=JSON.stringify({productTitle:n,productImage:r,productUrl:s}),t.Domain=e.domainName,C.Z.SendLogEvent(i,"Product Tracking: Invalid OOS product, missing title or image","error",void 0,g,a.R.EdgeFlyoutStatus,t,e.domainName)}return C.Z.SendStorageMessage("ProductTrackingData",JSON.stringify({value:f})),!await d&&h}catch(e){return C.Z.SendLogEvent(i,`Product Tracking: Validating OOS product check" ${e?.message}\n\n${e}`,"error"),!1}return!1}constructor(e){(0,n.Z)(this,"impressionId",""),(0,n.Z)(this,"merchantData",void 0),(0,n.Z)(this,"isAutoOpenControllerActive",void 0),(0,n.Z)(this,"isRuleBasedTriggerControllerActive",void 0),(0,n.Z)(this,"aocValidatorUtilities",void 0),(0,n.Z)(this,"ruleBasedTriggerController",void 0),(0,n.Z)(this,"scriptRunNum",0),(0,n.Z)(this,"validationMsgNum",0),(0,n.Z)(this,"validationStartTime",performance.now()),(0,n.Z)(this,"initializeStartTime",void 0),(0,n.Z)(this,"scriptStartTime",void 0),(0,n.Z)(this,"localDataService",void 0),this.localDataService=e}SetTraceId(e){T.traceId=e}SetMerchantData(e){this.merchantData=e}SetAutoOpenControllerExp(e){this.isAutoOpenControllerActive=e}SetRuleBasedTriggerControllerExp(e){this.isRuleBasedTriggerControllerActive=e}SetImpressionId(e){this.impressionId=e}ResetValidationMsgNum(){this.validationMsgNum=0}SetRuleBasedTriggerController(){return this.ruleBasedTriggerController=g.Z.getRuleBasedTriggerController(s.sR.AUTO_SHOW_COUPONS_CHECKOUT,this.sendErrorMessage.bind(this),this.SendStorageMessage.bind(this),this.impressionId,d.Q?.RuleBasedTriggerData),this.ruleBasedTriggerController}GetRuleBasedTriggerController(){return this.ruleBasedTriggerController}SetInitializeStartTime(e){e&&(this.initializeStartTime=e)}SetScriptStartTime(e){e&&(this.scriptStartTime=e)}SetValidationStartTime(e){this.validationStartTime=e}SetScriptRunNum(e){this.scriptRunNum=e}SendAutoOpenWithPageValidation(e,t,i){this.SendValidationMessage(!1,e,t,[i],!1,!0)}SendValidationMessage(e,t,i,n,o=!0,r=!1,a){a||(a={auto_apply_status:e,express_checkout_status:this.localDataService.IsExpressCheckoutPage(),open_micro_notifcation:!1,page_validations:n??[],page_validations_auto_open:[],auto_open_reasons:[]});const s=(e&&o||r)&&(0,y.ZQ)((e=>{C.Z.SendLogEvent(this.impressionId,e,"Blocked notification based on User Cohort")}),(0,y.tW)(),n,this.localDataService.GetUserSettingsData());this.sendValidationMessage(a,i,"AAController: "+t,s),!s&&this.aocValidatorUtilities&&this.aocValidatorUtilities.cleanLocalStorage()}SendStorageMessage(e,t){C.Z.SendStorageMessage(e,t)}SendPurchaseConfirmationMessage(){C.Z.SendMessage(h.H.PurchaseCompleted,[T.traceId])}IsPageValid(e){for(const t of e)if(p.Z.HasVisibleElement(t))return!0;return!1}sendErrorMessage(e,t){try{const i="error";C.Z.SendLogEvent(e,t,i,void 0,void 0,void 0),C.Z.SendMessage(h.H.CheckoutPageValidationError,[i,T.traceId])}catch(e){}}async RetrieveGuestDomain(e){if(C.Z.SendMessage(h.H.GuestDomain,[""]),e?.pinterestSelectors&&l.ZP.IsValidDataField(e?.pinterestSelectors.domainSelector)&&e?.pinterestSelectors&&l.ZP.IsValidDataField(e?.pinterestSelectors.productLinkSelector)){let t;if(await l.ZP.WaitForCondition((async()=>(t=p.Z.GetFirstVisibleElement(e.pinterestSelectors.domainSelector),void 0!==t)),5e3),t){let i;await l.ZP.WaitForCondition((async()=>(i=p.Z.GetFirstVisibleElement(e.pinterestSelectors.productLinkSelector),void 0!==i)),5e3);let n=t.innerText;const o=i?.getAttribute("href");if(n&&o)return n.includes("www.")||(n=`www.${n}`),n.includes("http")||(n=`http://${n}`),C.Z.SendStorageMessage("pinterestProductLink",JSON.stringify({value:o})),C.Z.SendMessage(h.H.GuestDomain,[n]),Promise.resolve(!0)}}return Promise.resolve(!1)}DeleteKeyFromPersistentStorage(e){this.SendStorageMessage(e,JSON.stringify({value:null}))}sendValidationMessage(e,t,i,n){const o=e.auto_apply_status?"true":"false",r=JSON.stringify(e);if((0,v.sy)())try{this.SendPerfLog(t,i,r)}catch(e){}C.Z.SendMessage(h.H.PageStatus,[T.traceId,r]),(0,v.sy)()?C.Z.SendMessage(h.H.CheckoutPageValidationStatus,[o,T.traceId,`${n}`]):this.localDataService.SetAutoApplyStatus(e.auto_apply_status),this.validationMsgNum++}SendPerfLog(e,t,i){const n=performance.now(),o=new m.Z;o.domain=e,o.initializeTime=this.scriptStartTime-this.initializeStartTime,o.preValidationTime=this.validationStartTime-this.scriptStartTime,o.time=n-this.validationStartTime,o.scriptRunNum=this.scriptRunNum,o.validationMsgNum=this.validationMsgNum,o.validationReason=t,o.path=f.Z.GetCurrentPathName(),o.pageStatus=i,C.Z.SendLogEventMessage(o,a.R.CheckoutValidationPerf,this.impressionId,"",a.in.Information)}}(0,n.Z)(T,"traceId",void 0),t.ZP=T},27775:function(e,t,i){"use strict";i.d(t,{q:function(){return o}});var n=i(23582);let o=function(e){return e.Primary="btnPrimary",e.PrimarySmallNotification="btnPrimarySmallNotification",e.Secondary="btnSecondary",e.SimpleOutline="btnSimpleOutline",e.PrimaryColor="btnPrimaryColor",e}({});t.Z=class{getStyles(){return"\n fluent-design-system-provider {\n --product-wrapper-border: 1px solid rgb(236, 236, 236);\n --text-price-color: rgba(0, 0, 0, 0.83);\n --text-red-savings-color: #DE3700;\n --text-green-savings-color: #008A21;\n --text-retailer-color: rgba(0, 0, 0, 0.83);\n --text-normal: #1A1A1A;\n --text-neutral-foreground: #7A7A7A;\n --text-neutral-foreground-hint: #717171;\n\n --price-history-increase-color: #D64400;\n --price-history-decrease-color: #008A21;\n --price-history-stable-color: #166FF5;\n\n --body-font: 'Segoe UI', 'Roboto', Helvetica, Verdana, sans-serif;\n\n --section-separator-opacity: 1;\n\n --show-more-btn-bg-color: inherit;\n\n --tooltip-background-color: #FFFFFF;\n\n --coupon-selected-color: #207A90;\n\n --coupon-success-color: #DE3700;\n --coupon-success-bg-start: #FFEEF5;\n --coupon-success-bg-mid: #FFFBF0;\n --coupon-success-bg-end: #FFFFFF;\n\n --coupon-success-border: rgba(245, 214, 216, 0.3);\n\n --coupon-success-hover-bg-start: #FFF1F7;\n --coupon-success-hover-bg-mid: #FFFEF0;\n --coupon-success-hover-bg-end: #FFFFFF;\n\n --coupon-control-bg-start: #EDFBFF;\n --coupon-control-bg-end: #FFFFFF;\n\n --coupon-control-border: rgba(201, 225, 231, 0.3);\n --coupon-control-hover-bg-start: #FFFFFF;\n --coupon-control-hover-bg-end: #EDFBFF;\n\n --coupon-success-rate-bg-start: #E4008A;\n --coupon-success-rate-bg-mid: #FF4B14;\n --coupon-success-rate-bg-end: #FF8D24;\n\n --coupon-title-hover-color: #666666;\n --coupon-non-stackable-msg-color: #666666;\n\n --coupon-single-row-bg: #FFFFFF;\n\n --notification-header-bottom-border: #EBEBEB;\n }\n html {\n overflow: hidden;\n --background-outline-rest: padding-box linear-gradient(#FFFFFF, #FFFFFF), border-box linear-gradient(#efefef 90%, #d6d6d6 100%);\n --background-outline-hover: padding-box linear-gradient(#F7F7F7, #F7F7F7), border-box linear-gradient(#e5e5e5 90%, #cecece 100%);\n --background-outline-secondary-rest: padding-box linear-gradient(var(--fill-color), var(--fill-color)), border-box linear-gradient(88.14deg, #018DC8 0.49%, #01CC83 53.44%, #0CBFC9 104.22%);\n }\n msft-edge-shopping::part(header) {\n margin-top: 16px!important;\n }\n fluent-anchor {\n font-weight: 600;\n }\n .imgProduct {\n width: auto;\n height: auto;\n box-sizing: border-box;\n place-self: center;\n object-fit: cover;\n }\n .divProductImageContainer {\n position: relative;\n background-color: #FFFFFF;\n background-position: center;\n background-size: cover;\n font-weight: 600;\n font-size: 12px;\n line-height: 12px;\n text-align: center;\n color: #000000;\n display: flex;\n justify-content: center;\n align-items: center;\n overflow: hidden;\n place-self: center;\n }\n .divProductImageAlpha {\n background: rgba(0, 0, 0, 0.03);\n position: absolute;\n top: 0px;\n left: 0px;\n object-fit: cover;\n }\n msft-shopping-coupon,\n msft-shopping-link {\n margin-top: 5px;\n }\n msft-edge-shopping-section {\n margin-top: 10px;\n width: 100%;\n }\n msft-shopping-link:first-of-type,\n msft-shopping-coupon:first-of-type {\n margin-top: 0;\n }\n fluent-menu-item::part(content) {\n width: 100%;\n overflow: hidden;\n overflow-wrap: break-word;\n -webkit-line-clamp: 1;\n -webkit-box-orient: vertical;\n }\n msft-edge-shopping::part(footer){\n padding: 0px;\n margin-top: 0px;\n display: flex;\n flex-direction: column;\n border-top: none;\n }\n .noInlinePadding::part(action) {\n margin-inline-start: 0px;\n }\n fluent-anchor,\n fluent-button,\n fluent-card {\n font-size: 12px;\n }\n #remindLater::part(control) {\n display: flex;\n align-self: center;\n }\n #remindLater {\n margin-top: 5px;\n margin-bottom: 5px;\n }\n #footerDiv {\n display: grid;\n column-gap: 12px;\n justify-content: center;\n width: 100%;\n margin-top: 10px;\n margin-bottom: 12px;\n grid-template-columns: calc(50% - 22px) calc(50% - 22px);\n }\n .lateralMargin {\n width: calc(100% - 32px)!important;\n margin: auto;\n }\n #notshow::part(content), #snoozeWithOptions::part(content) {\n display: flex;\n flex-direction: row;\n width: 100%;\n justify-content: space-between;\n }\n #doNotShowOverlay, #snoozeOverlay {\n position: absolute;\n right: 20px;\n width: 73%;\n bottom: 40px;\n z-index: 1;\n }\n #doNotShowOverlay fluent-menu-item, #snoozeOverlay fluent-menu-item {\n grid-template-columns: minmax(14px, auto) 1fr minmax(12px, auto);\n white-space: normal;\n padding: 4px 0;\n height: auto;\n }\n ::part(sections) {\n position: relative;\n margin-top: 10px;\n padding: 0px!important;\n }\n .noSections::part(sections) {\n margin-top: 0px!important;\n }\n ::part(start-content) {\n padding: 0px;\n }\n ::part(actions) {\n width: 100%;\n border-bottom: unset;\n padding-bottom: 0px;\n padding-top: 0px;\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n }\n [slot=\"actions\"] {\n margin-top: 10px;\n width: 100%;\n }\n msft-shopping-link:last-of-type {\n margin-bottom: 5px;\n }\n msft-shopping-coupon:last-of-type {\n margin-bottom: 5px;\n }\n ::part(start-content) {\n padding-top: 0px;\n padding-bottom: 0px;\n }\n #divContentWrapper {\n width: 360px;\n height: auto;\n }\n #divContentWrapperStorybook {\n width: 360px;\n height: auto;\n }\n #menuMessage {\n margin-left: 22px;\n }\n #menuSettingsBingPrivacy {\n display: flex;\n flex-direction: row;\n justify-content: flex-start;\n color: #767676;\n margin-bottom: 6px;\n padding-top: 5px;\n border-top: 1px solid #F1F1F1\n }\n body {\n margin: 0px;\n }\n .hide {\n display: none;\n }\n msft-edge-shopping {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n height: auto;\n max-height: 580px;\n }\n #divContentWrapper.ms-edge-shopping-650 msft-edge-shopping {\n max-height: 650px;\n }\n #divContentWrapper.ms-edge-shopping-489 msft-edge-shopping {\n height: 489px;\n }\n fluent-design-system-provider {\n width: 360px;\n margin: 0px;\n }\n .txtLarge {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 24px;\n line-height: 24px;\n margin: 0px;\n color: var(--neutral-foreground-rest);\n }\n .txtMedium {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 16px;\n line-height: 20px;\n margin: 0px;\n color: var(--neutral-foreground-rest);\n }\n .txtSmall {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 14px;\n line-height: 20px;\n margin: 0px;\n color: var(--neutral-foreground-rest);\n }\n .txtXSmall {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 12px;\n font-weight: 400;\n line-height: 16px;\n margin: 0px;\n color: var(--neutral-foreground-rest);\n }\n .txtEmptyCoupons {\n all: initial;\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 18px;\n line-height: 25px;\n margin: 0px;\n color: rgba(0, 0, 0, 0.83);\n }\n .txtEmptyCouponsCjk {\n all: initial;\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 18px;\n line-height: 25px;\n margin: 0px;\n color: rgba(0, 0, 0, 0.83);\n width: 80%;\n text-align: center;\n }\n .txtSavingsColor {\n color: var(--text-green-savings-color);\n font-weight: 500;\n }\n .defaultFontFamily {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n }\n msft-shopping-link::part(attribution) {\n margin-top: 6px;\n }\n .sectionSeparator {\n position: absolute;\n border: 1px solid #000000;\n opacity: 0.04;\n margin-bottom: 0px;\n margin-top: 0px;\n border-bottom: unset;\n width: 360px;\n left: 0px;\n right: 0px;\n }\n ::part(control) {\n margin-bottom: 0px;\n }\n .triviaTitle {\n margin: 0px;\n display: flex;\n column-gap: 3px;\n flex-wrap: wrap;\n justify-content: center;\n font-weight: 400;\n font-size: 12px;\n line-height: 20px;\n vertical-align: middle;\n text-align: center;\n padding: 8px 10px;\n }\n .savingsFoundTextContainer {\n display: flex;\n justify-content: center;\n column-gap: 3px;\n line-height: normal;\n margin-top: 6px;\n }\n .savingsFoundTextContainer:last-child {\n margin-bottom: 6px;\n }\n .infoicon {\n align-self: center;\n display: inline;\n position: relative;\n top: -10px;\n }\n ::part(tooltip) {\n white-space: unset;\n font-size: 10px;\n hyphens: auto;\n padding: 4px 6px;\n line-height: 12px;\n padding-bottom: 8px;\n }\n .btnTooltip {\n border: none;\n outline: none;\n border-radius: 4px;\n background: transparent;\n display: flex;\n }\n #remindLaterFooter {\n font-size: 14px;\n margin-left: 10px;\n --accent-foreground-hover: none;\n }\n .btnTooltip:focus-visible {\n box-shadow: 0 0 0 2px inset #fbfdfe, 0 0 0 1px #878787;\n border: 1px solid #878787;\n }\n .infoiconsvg {\n fill: #000000;\n }\n .newSeeMore {\n width: 100%;\n margin: 0px 20px 20px 20px;\n font-size: 14px;\n font-weight: 400;\n line-height: 20px;\n }\n .cjkNewSeeMore {\n font-family: \"Segoe UI\", \"Roboto\", Helvetica, Verdana, sans-serif;\n font-style: normal;\n font-weight: 400;\n font-size: 12px;\n color: #717171;\n width: fit-content;\n height: 100%;\n margin-left: 16px;\n margin-bottom: 16px;\n }\n .cjkDivNewSeeMore {\n background-color: #FFFFFF;\n }\n .btnSeeMoreSeparate {\n margin: 0px!important;\n }\n .sectionTabs[aria-selected=true] {\n color: #036AC4;\n border: 1px solid #036AC4;\n }\n .sectionTabs[aria-selected=false] {\n color: #595959;\n font-weight: 400;\n border: 1px solid #595959;\n }\n .sectionTabs::active {\n border-width: 2px;\n }\n .sectionTabs {\n margin: 0px 5px;\n padding: 0px 10px;\n border-radius: 100px;\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 12px;\n height: 24px;\n display: flex;\n flex-direction: column;\n background-color: var(--fill-color);\n flex-direction: row;\n column-gap: 4px;\n width: max-content;\n }\n .sectionTabList::part(activeIndicator) {\n display: none;\n }\n .sectionTabList::part(tablist) {\n margin-bottom: 20px;\n width: calc(100% - 32px);\n margin: auto;\n overflow: auto;\n }\n @keyframes updownAnimation {\n 0% {\n transform: translateY(-40%);\n }\n 50% {\n transform: translateY(40%);\n }\n 100% {\n transform: translateY(-40%);\n }\n }\n ::part(header-fixed) {\n height: 44px;\n }\n ::part(header-fixed-title) {\n font-weight: 400;\n }\n .btnPrimary {\n width: 100%;\n height: 44px;\n font-weight: 600;\n font-size: 16px;\n line-height: 20px;\n border-radius: 8px;\n }\n .btnPrimaryColor {\n width: 100%;\n height: 48px;\n font-weight: 600;\n font-size: 16px;\n line-height: 20px;\n color: #FFFFFF;\n background: linear-gradient(90.05deg, #8300D4 0.59%, #0048D4 67.54%, #00D4A1 104.11%);\n }\n .btnPrimaryColor:hover {\n background: linear-gradient(90.05deg, #9E00FF 0.59%, #0048D4 67.54%, #00FFC2 104.11%);\n }\n .btnSimpleOutline {\n height: 32px;\n font-weight: 400;\n font-size: 14px;\n border-radius: 4px;\n line-height: 20px;\n }\n .btnSimpleOutline::part(control) {\n background: var(--background-outline-rest);\n }\n .btnSimpleOutline::part(control):hover {\n background: var(--background-outline-hover)!important;\n }\n .btnSecondary {\n color: #008076;\n height: 32px;\n font-weight: 400;\n font-size: 14px;\n border-radius: 4px;\n }\n .btnSecondary::part(control) {\n background: var(--background-outline-secondary-rest);\n }\n .btnPrimarySmallNotification {\n box-sizing: border-box;\n width: 100%;\n height: 32px;\n font-weight: 400;\n font-size: 14px;\n line-height: 20px;\n }\n\n @media (-ms-high-contrast: active) {\n #disabled-notification-icon path, #notification-icon path, #left-arrow-icon path, #right-arrow-icon path {\n fill: buttonText !important;\n }\n }\n section#toastContainer {\n position: fixed;\n top: 100%;\n z-index: 12; /* 10 is the z-index of the price drop decoration \"12% OFF\" */\n }\n\n #toastWrapper {\n display: grid;\n justify-content: center;\n gap: 10px;\n width: 100vw;\n will-change: transform;\n }\n\n #toastWrapper .toast {\n background: #1A1A1A;\n max-width: 80vw;\n display: flex;\n padding-block: 11px;\n margin: auto;\n justify-content: space-between;\n align-items: center;\n border-radius: 4px;\n padding-inline: 16px;\n font-size: 1rem;\n will-change: transform;\n transition: 200ms;\n animation: slideUp 500ms ease forwards 1;\n gap: 10px;\n }\n\n @keyframes slideUp {\n from {\n transform: translateY(100%);\n opacity: 0;\n }\n }\n\n #toastWrapper .toast .toastTextContainer {\n flex-grow: 1;\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n }\n #toastWrapper .toast .toastTitle {\n display: -webkit-box;\n -webkit-line-clamp: 1;\n -webkit-box-orient: vertical;\n overflow: hidden;\n font-size: 14px;\n font-weight: 600;\n margin: 0;\n }\n #toastWrapper .toast .toastText {\n margin: 0;\n display: -webkit-box;\n -webkit-line-clamp: 2;\n overflow: hidden;\n -webkit-box-orient: vertical;\n font-size: 14px;\n color: #FFFFFF;\n }\n #toastWrapper .toast .toastText.withTitle {\n font-size: 12px;\n -webkit-line-clamp: 1;\n color: #BABABA;\n }\n #toastWrapper .toast .toastClose {\n border-radius: 50%;\n color: #A8A8A8;\n font-size: 22px;\n background: #333333;\n min-width: unset;\n height: 24px;\n aspect-ratio: 1;\n }\n #toastWrapper .toast .toastClose p {\n margin: 0;\n width: 22px;\n line-height: 21px;\n height: 24px;\n text-align: center;\n padding: 0;\n }\n #toastWrapper .toast .toastClose::part(control) {\n width: 100%;\n padding: 0 0 0 1px;\n border: 0;\n }\n #toastWrapper .toast .toastClose::part(content) {\n width: 100%;\n height: 100%;\n text-align: center;\n line-height: normal;\n }\n #main-background-overlay {\n background: #FFFFFF;\n opacity: 0.8;\n height: 100vh;\n width: 100vw;\n position: fixed;\n top: 40px;\n left: 0;\n z-index: 100;\n }\n #divMenuContent {\n position: absolute;\n z-index: 10000;\n right: 10px;\n outline: none;\n padding: 0px!important;\n max-width: 280px!important;\n }\n\n @media (forced-colors: active) {\n msft-edge-shopping {\n background-image: unset!important;\n }\n .btnTooltip:focus-visible {\n border: 1px solid buttontext;\n box-shadow: highlighttext 0px 0px 0px 2px inset;\n }\n #flyoutCloseWhite>path .viewMorePricesButton>svg>path {\n fill: buttonText!important;\n }\n .sectionTabs {\n color: highlight !important;\n }\n }\n @media (-ms-high-contrast: active) {\n .infoiconsvg {\n fill:Text;\n }\n .btnTooltip:focus {\n outline: auto;\n }\n .searchMenuItem:hover #search-icon path {\n fill: #000000;\n }\n #bestCouponBtn #copy-icon, #bestCouponBtn #blue-check-icon {\n fill: #FFFFFF;\n }\n }\n .txtInstantSavings {\n color: #107C10;\n }\n #btnFlyoutClose #progressCircle {\n display: none;\n }\n .notification-manage-item {\n text-transform: capitalize;\n }\n #left-arrow-icon path, #right-arrow-icon path, #search-icon, .shoprunner-logo {\n fill: #000000;\n }\n #copy-icon, #blue-check-icon {\n fill: #0F6CBD;\n }\n #MS-logo {\n fill: #636363;\n }\n #plus-icon {\n fill: #707070;\n }\n .copyCouponBtn {\n font-weight: 600;\n font-size: 12px;\n line-height: 16px;\n border: 1px dashed #0F6CBD;\n border-radius: 4px;\n color: #0F6CBD;\n height: 24px;\n }\n .copyCouponBtn::part(control) {\n padding: 0px 6px;\n }\n .copyCouponBtn::part(end) {\n margin-inline-start: 0px;\n }\n .tagRightPath {\n fill: #0078D4;\n }\n @media (-ms-high-contrast: active) {\n .tagRightPath {\n fill: Background;\n }\n }\n "}getDarkModeStyles(){return"\n fluent-design-system-provider {\n --text-retailer-color: #FFFFFF;\n --text-price-color: #FFFFFF;\n --text-red-savings-color: #FFB833;\n --text-green-savings-color:#35D95B;\n --product-wrapper-border: 1px solid rgb(236, 236, 236, 0.08);\n --text-normal: #FFFFFF;\n --text-neutral-foreground: #C2C2C2;\n --text-neutral-foreground-hint: #E0E0E0;\n\n --price-history-increase-color: #F2364F;\n --price-history-decrease-color: #35D95B;\n --price-history-stable-color: #5EC4FE;\n\n --section-separator-opacity: 0.08;\n --section-separator-color: #FFFFFF;\n\n --show-more-btn-bg-color: var(--neutral-fill-rest);\n\n --tooltip-background-color: #3b3b3b;\n\n --coupon-selected-color: #41CFF2;\n\n --coupon-success-color: #FFB833;\n --coupon-success-bg-start: rgba(255, 0, 107, 0.08);\n --coupon-success-bg-mid: rgba(255, 184, 0, 0.08);\n --coupon-success-bg-end: rgba(255, 255, 255, 0);\n\n --coupon-success-border: rgba(245, 214, 216, 0.3);\n\n --coupon-success-hover-bg-start: rgba(255, 0, 107, 0.08);\n --coupon-success-hover-bg-mid: rgba(255, 230, 0, 0.08);\n --coupon-success-hover-bg-end: rgba(255, 255, 255, 0);\n\n --coupon-control-bg-start: rgba(0, 198, 255, 0.08);\n --coupon-control-bg-end: rgba(255, 255, 255, 0);\n\n --coupon-control-border: rgba(201, 225, 231, 0.3);\n --coupon-control-hover-bg-start: rgba(255, 255, 255, 0);\n --coupon-control-hover-bg-end: rgba(0, 198, 255, 0.08);\n\n --coupon-success-rate-bg-start: #C11371;\n --coupon-success-rate-bg-mid: #E74818;\n --coupon-success-rate-bg-end: #F78216;\n --coupon-title-hover-color: #C4C4C4;\n --coupon-non-stackable-msg-color: #FFFFFF;\n\n --coupon-single-row-bg: rgba(0, 0, 0, 0);\n\n --notification-header-bottom-border: #FFFFFF3D;\n }\n html {\n --background-outline-rest: padding-box linear-gradient(#333333, #333333), border-box linear-gradient(#505050 0%, #383838 10%);\n --background-outline-hover: padding-box linear-gradient(#383838, #383838), border-box linear-gradient(#595959 0%, #414141 10%);\n --background-outline-secondary-rest: padding-box linear-gradient(#3b3b3b, #3b3b3b), border-box linear-gradient(88.14deg, #018DC8 0.49%, #01CC83 53.44%, #0CBFC9 104.22%);\n }\n .txtEmptyCoupons {\n color: #FFFFFF;\n }\n .tirivaSavings {\n color: #FFFFFF!important;\n }\n .sectionSeparator {\n opacity: 0.08;\n }\n .infoiconsvg {\n fill: #FFFFFF;\n }\n #notshow::part(control), #snoozeWithOptions::part(control) {\n background: none;\n }\n #snooze::part(control) {\n background: none;\n }\n .divSeeMore {\n border-top: 1px solid rgba(236, 236, 236, 0.08)!important;\n }\n .btnSecondary {\n color: #09E6C3;\n }\n .btnPrimarySmallNotification {\n background: linear-gradient(#4985E7, #4985E7) padding-box, linear-gradient(180deg, #1C7DCE 90%, #024C8B 100%) border-box;\n }\n .txtInstantSavings {\n color: #62C90C;\n }\n .svg-icon path{\n fill: #FFFFFF;\n }\n #disabled-notification-icon path, #notification-icon path, #left-arrow-icon path, #right-arrow-icon path, #search-icon, .shoprunner-logo, #MS-logo {\n fill: #FFFFFF;\n }\n .sectionTabs[aria-selected=false] {\n color: #DDDDDD;\n }\n fluent-switch {\n --accent-fill-hover: #53A5E5;\n --accent-fill-rest: #9FC9FF;\n }\n #main-background-overlay {\n background: #3B3B3B;\n }\n #copy-icon, #blue-check-icon {\n fill: #82DDFD;\n }\n #plus-icon {\n fill: #BDBDBD;\n }\n .copyCouponBtn {\n border-color: #82DDFD;\n color: #82DDFD;\n }\n #menuSettingsBingPrivacy {\n color: #C0C0C0;\n }\n .btnSimpleOutline {\n outline: 1px solid var(--neutral-stroke-rest);\n }\n .divProductImageAlpha {\n background: rgba(0, 0, 0, 0.2);\n position: absolute;\n top: 0px;\n left: 0px;\n object-fit: cover;\n }\n "}getSmallerNotificationCssStyles(){return"\n #divContentWrapper {\n width: 280px;\n }\n .btnSimpleOutline::part(control) {\n padding: 8px;\n }\n #btnFlyoutClose::part(control), #btnMainMenu::part(control) {\n padding: 0px;\n }\n #footerDiv {\n column-gap: 8px;\n margin-top: 8px;\n grid-template-columns: calc(50% - 20px) calc(50% - 20px);\n }\n ::part(header-fixed) {\n border-bottom: 1px solid var(--notification-header-bottom-border);\n }\n #h2RebatesTitle {\n font-weight: 600!important;\n line-height: 28px!important;\n font-size: 20px!important;\n }\n #h2PdpEstimateTitle {\n font-weight: 600!important;\n line-height: 20px!important;\n font-size: 16px!important;\n margin: 0px;\n }\n .divCommissionValue {\n display: inline-block;\n margin: 0px;\n vertical-align: text-bottom;\n }\n .divPdpEstimateCommissionValue {\n display: inline-block;\n margin: 5px;\n vertical-align: text-bottom;\n }\n .spanCommissionValue {\n background: #036AC4!important;\n height: 24px!important;\n font-size: 20px!important;\n line-height: 20px!important;\n padding-top: 1px;\n box-sizing: border-box;\n display: flex;\n color: #fff;\n font-weight: 600;\n float: left;\n }\n .spanCommissionValueLarge {\n background: #0078D4!important;\n height: 30px!important;\n font-size: 24px!important;\n line-height: 28px!important;\n box-sizing: border-box;\n float: left;\n }\n .splitPrice {\n font-size: 16px;\n position: relative;\n line-height: 25px;\n align-self: flex-start;\n }\n .splitPriceSmall {\n font-size: 14px;\n position: relative;\n line-height: 18px;\n align-self: flex-start;\n }\n msft-edge-shopping::part(header) {\n margin-top: 12px!important;\n }\n msft-shopping-coupon-new::part(start-content) {\n min-width: unset;\n width: 120px;\n }\n "}getFallbackNotificationRequiredCssStyles(){return"\n #divContentWrapper {\n width: 360px;\n height: auto;\n }\n #footerDiv {\n display: grid;\n column-gap: 12px;\n justify-content: center;\n width: 100%;\n margin-top: 10px;\n margin-bottom: 12px;\n grid-template-columns: calc(50% - 22px) calc(50% - 22px);\n }"}getColoredHeaderCssExp1(){return"\n #btnFlyoutClose, #btnMainMenu {\n background: none;\n }\n ::part(header-fixed) {\n background: linear-gradient(90.79deg, #E4FCFF 3.55%, #D2F7FF 23.38%, #81D1FF 49.35%, #558EFF 70.12%, #1F65F1 90.42%);\n }\n ::part(header-fixed-title) {\n color: #001C56;\n font-weight: 400;\n }\n #flyoutMenu, #flyoutClose {\n fill: #FFFFFF;\n }\n "}getColoredHeaderCssExp2(){return"\n #btnFlyoutClose, #btnMainMenu {\n background: none;\n }\n ::part(header-fixed) {\n background: linear-gradient(270deg, #1F65F1 0%, #1F65F1 35.42%, #1F65F1 68.23%, #6BC1FF 88.54%, #B6FBFF 100%);\n }\n ::part(header-fixed-title) {\n color: #FFFFFF;\n font-weight: 400;\n }\n #flyoutClose, #flyoutMenu {\n fill: #FFFFFF;\n }\n "}getColoredHeaderCssExp3(){return"\n #btnFlyoutClose, #btnMainMenu {\n background: none;\n }\n ::part(header-fixed) {\n background: linear-gradient(270deg, #1F65F1 0%, #1F65F1 35.42%, #1F65F1 68.23%, #6BC1FF 88.54%, #B6FBFF 100%);\n }\n ::part(header-fixed-title) {\n color: #FFFFFF;\n font-weight: 400;\n }\n #flyoutClose, #flyoutMenu {\n fill: #FFFFFF;\n }\n "}getGroceryNotificationFooterCss(){return"\n #footerDiv{\n margin-bottom: 14px !important;\n }\n msft-edge-shopping::part(footer){\n padding: 0.1rem;\n margin-top: 0px;\n display: flex;\n flex-direction: column;\n border:none !important;\n }\n "}getColoredHeaderCssExp4(){return"\n #btnFlyoutClose, #btnMainMenu {\n background: none;\n }\n ::part(header-fixed) {\n background: linear-gradient(268.01deg, #CFE1FF -2.15%, #D8F6FF 50.34%, #EEFEFA 88.77%);\n }\n ::part(header-fixed-title) {\n font-weight: 400;\n }\n "}getGreenCheck(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none"><path d="M10 0C15.5228 0 20 4.47715 20 10C20 15.5228 15.5228 20 10 20C4.47715 20 0 15.5228 0 10C0 4.47715 4.47715 0 10 0ZM13.2197 6.96967L8.75 11.4393L6.78033 9.46967C6.48744 9.17678 6.01256 9.17678 5.71967 9.46967C5.42678 9.76256 5.42678 10.2374 5.71967 10.5303L8.21967 13.0303C8.51256 13.3232 8.98744 13.3232 9.28033 13.0303L14.2803 8.03033C14.5732 7.73744 14.5732 7.26256 14.2803 6.96967C13.9874 6.67678 13.5126 6.67678 13.2197 6.96967Z" fill="#107C10"/></svg>`}getInfoIcon(){return n.Z.getTrustedHTML`
<svg width="10" height="10" viewBox="0 0 10 10" aria-hidden="true" fill="none" xmlns="http://www.w3.org/2000/svg">
<style>
@media (prefers-color-scheme: dark) {
#infoiconsvg { fill: #FFFFFF; }
}
@media (-ms-high-contrast: active) {
#infoiconsvg { fill: buttonText; }
}
</style>
<path class="infoiconsvg" id=infoiconsvg d="M4.5 5.5C4.5 5.22386 4.72386 5 5 5C5.27614 5 5.5 5.22386 5.5 5.5V7C5.5 7.27614 5.27614 7.5 5 7.5C4.72386 7.5 4.5 7.27614 4.5 7V5.5ZM5 2.75C4.58579 2.75 4.25 3.08579 4.25 3.5C4.25 3.91421 4.58579 4.25 5 4.25C5.41421 4.25 5.75 3.91421 5.75 3.5C5.75 3.08579 5.41421 2.75 5 2.75ZM0 5C0 2.23858 2.23858 0 5 0C7.76142 0 10 2.23858 10 5C10 7.76142 7.76142 10 5 10C2.23858 10 0 7.76142 0 5ZM5 1C2.79086 1 1 2.79086 1 5C1 7.20914 2.79086 9 5 9C7.20914 9 9 7.20914 9 5C9 2.79086 7.20914 1 5 1Z" fill="black" fill-opacity="0.55"/>
</svg>
`}getGreenCheckCircle(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" width="18" height="18" viewBox="0 0 18 18" fill="none">
<path d="M9 0C9.82617 0 10.623 0.108398 11.3906 0.325195C12.1582 0.536133 12.873 0.837891 13.5352 1.23047C14.2031 1.62305 14.8096 2.09473 15.3545 2.64551C15.9053 3.19043 16.377 3.79688 16.7695 4.46484C17.1621 5.12695 17.4639 5.8418 17.6748 6.60938C17.8916 7.37695 18 8.17383 18 9C18 9.82617 17.8916 10.623 17.6748 11.3906C17.4639 12.1582 17.1621 12.876 16.7695 13.5439C16.377 14.2061 15.9053 14.8125 15.3545 15.3633C14.8096 15.9082 14.2031 16.377 13.5352 16.7695C12.873 17.1621 12.1582 17.4668 11.3906 17.6836C10.623 17.8945 9.82617 18 9 18C8.17383 18 7.37695 17.8945 6.60938 17.6836C5.8418 17.4668 5.12402 17.1621 4.45605 16.7695C3.79395 16.377 3.1875 15.9082 2.63672 15.3633C2.0918 14.8125 1.62305 14.2061 1.23047 13.5439C0.837891 12.876 0.533203 12.1582 0.316406 11.3906C0.105469 10.623 0 9.82617 0 9C0 8.17383 0.105469 7.37695 0.316406 6.60938C0.533203 5.8418 0.837891 5.12695 1.23047 4.46484C1.62305 3.79688 2.0918 3.19043 2.63672 2.64551C3.1875 2.09473 3.79395 1.62305 4.45605 1.23047C5.12402 0.837891 5.8418 0.536133 6.60938 0.325195C7.37695 0.108398 8.17383 0 9 0ZM14.2998 6.02051L13.1045 4.8252L7.3125 10.6172L4.89551 8.2002L3.7002 9.39551L7.3125 13.0078L14.2998 6.02051Z" fill="#107C10"/>
<path d="M11.2547 0.806371L11.2547 0.806383L11.2581 0.807322C11.9842 1.00685 12.6577 1.29147 13.2801 1.66056L13.2818 1.66153C13.9125 2.03217 14.4846 2.47716 14.9991 2.99717L14.999 2.99719L15.0028 3.00095C15.5228 3.51542 15.9678 4.08755 16.3385 4.71819L16.3394 4.71985C16.7085 5.34233 16.9931 6.01579 17.1927 6.74187L17.1936 6.74528C17.3975 7.46707 17.5 8.21813 17.5 9C17.5 9.78187 17.3975 10.5329 17.1936 11.2547L17.1927 11.2581C16.9932 11.9842 16.7085 12.6609 16.339 13.2897C15.9681 13.9152 15.5223 14.4883 15.0009 15.0097C14.4862 15.5245 13.9134 15.9673 13.2818 16.3385L13.2802 16.3394C12.6572 16.7088 11.9831 16.9966 11.2564 17.202C10.5341 17.4003 9.78247 17.5 9 17.5C8.21755 17.5 7.46593 17.4003 6.74368 17.202C6.01692 16.9966 5.33955 16.7087 4.71019 16.3389C4.08456 15.9679 3.51145 15.5251 2.99028 15.0097C2.47492 14.4885 2.03207 13.9154 1.66101 13.2897C1.29126 12.6604 1.00347 11.9831 0.79807 11.2564C0.599745 10.5342 0.5 9.7825 0.5 9C0.5 8.21751 0.599742 7.46586 0.798061 6.74358C1.00346 6.01688 1.29118 5.34283 1.66055 4.71985L1.66056 4.71985L1.66153 4.71819C2.03274 4.08658 2.47549 3.51384 2.99027 2.99906C3.51164 2.47769 4.08476 2.032 4.71019 1.66107C5.33903 1.29158 6.01578 1.00686 6.74187 0.807322L6.74187 0.807334L6.74528 0.806371C7.46707 0.602506 8.21813 0.5 9 0.5C9.78187 0.5 10.5329 0.602506 11.2547 0.806371ZM14.6534 6.37406L15.0069 6.02051L14.6534 5.66695L13.458 4.47164L13.1045 4.11809L12.7509 4.47164L7.3125 9.91008L5.24906 7.84664L4.89551 7.49309L4.54195 7.84664L3.34664 9.04195L2.99309 9.39551L3.34664 9.74906L6.95895 13.3614L7.3125 13.7149L7.66605 13.3614L14.6534 6.37406Z" stroke="black" stroke-opacity="0.07"/>
</svg>`}getCloseButton(){return n.Z.getTrustedHTML`<svg id="flyoutClose" xmlns="http://www.w3.org/2000/svg" width="12" height="12" viewBox="0 0 12 12">
<path d="M0.0885911 0.215694L0.146447 0.146447C0.320013 -0.0271197 0.589437 -0.046405 0.784306 0.0885911L0.853553 0.146447L6 5.293L11.1464 0.146447C11.32 -0.0271197 11.5894 -0.046405 11.7843 0.0885911L11.8536 0.146447C12.0271 0.320013 12.0464 0.589437 11.9114 0.784306L11.8536 0.853553L6.707 6L11.8536 11.1464C12.0271 11.32 12.0464 11.5894 11.9114 11.7843L11.8536 11.8536C11.68 12.0271 11.4106 12.0464 11.2157 11.9114L11.1464 11.8536L6 6.707L0.853553 11.8536C0.679987 12.0271 0.410563 12.0464 0.215694 11.9114L0.146447 11.8536C-0.0271197 11.68 -0.046405 11.4106 0.0885911 11.2157L0.146447 11.1464L5.293 6L0.146447 0.853553C-0.0271197 0.679987 -0.046405 0.410563 0.0885911 0.215694L0.146447 0.146447L0.0885911 0.215694Z"/>
</svg>`}getArrowButtonIcon(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="8" height="5" viewBox="0 0 8 5">
<path d="M0.146447 0.646447C0.341709 0.451184 0.658291 0.451184 0.853553 0.646447L4 3.79289L7.14645 0.646447C7.34171 0.451184 7.65829 0.451184 7.85355 0.646447C8.04882 0.841709 8.04882 1.15829 7.85355 1.35355L4.35355 4.85355C4.15829 5.04882 3.84171 5.04882 3.64645 4.85355L0.146447 1.35355C-0.0488155 1.15829 -0.0488155 0.841709 0.146447 0.646447Z"/>
</svg>`}getSnoozeLineButton(){return n.Z.getTrustedHTML`<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M7.96379 3C5.89462 3 3.96372 4.62135 3.96372 7.16667V9.9352L3.08616 12H12.8659L11.9637 9.93793V8.5C11.9637 8.22387 12.1876 8 12.4637 8C12.7399 8 12.9637 8.22387 12.9637 8.5V9.72873L13.8842 11.8327C14.1251 12.3832 13.7217 13 13.1207 13H9.96499C9.96446 14.1047 9.06873 15 7.96393 15C6.85913 15 5.96346 14.1047 5.96289 13H2.83422C2.23704 13 1.8337 12.3903 2.06728 11.8407L2.96372 9.73147V7.16667C2.96372 4.04532 5.36638 2 7.96379 2C8.53679 2 9.10039 2.09938 9.63079 2.28798C9.89099 2.38049 10.0269 2.66641 9.93439 2.92659C9.84186 3.18678 9.55593 3.3227 9.29573 3.23019C8.87146 3.07932 8.42113 3 7.96379 3ZM7.96393 14C8.51646 14 8.96446 13.5524 8.96499 13H6.96286C6.96346 13.5524 7.41146 14 7.96393 14ZM10.1311 5.33333H8.4644L8.39659 5.3379C8.15253 5.37101 7.9644 5.5802 7.9644 5.83333C7.9644 6.10947 8.18826 6.33333 8.4644 6.33333H9.15953L8.05753 7.87607L8.02066 7.93567C7.84959 8.25947 8.08166 8.66667 8.4644 8.66667H10.1311L10.1989 8.66213C10.443 8.629 10.6311 8.4198 10.6311 8.16667C10.6311 7.89053 10.4073 7.66667 10.1311 7.66667H9.43599L10.5379 6.12395L10.5748 6.06433C10.7459 5.74053 10.5139 5.33333 10.1311 5.33333ZM14.1311 2H11.7977L11.7299 2.00457C11.4859 2.03767 11.2977 2.24687 11.2977 2.5C11.2977 2.77614 11.5216 3 11.7977 3H13.2203L11.3759 5.89823L11.3432 5.95793C11.1928 6.28083 11.4264 6.66667 11.7977 6.66667H14.1311L14.1989 6.6621C14.443 6.62899 14.6311 6.4198 14.6311 6.16667C14.6311 5.89053 14.4073 5.66667 14.1311 5.66667H12.7086L14.5529 2.76844L14.5857 2.70874C14.7361 2.38584 14.5025 2 14.1311 2Z" fill="#1A1A1A"/>
</svg>
`}getSnoozeFilledButton(){return n.Z.getTrustedHTML`<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M10.1656 4.33333H8.4989L8.4311 4.3379C8.18703 4.37101 7.9989 4.5802 7.9989 4.83333C7.9989 5.10947 8.22276 5.33333 8.4989 5.33333H9.19403L8.09203 6.87607L8.05516 6.93567C7.8841 7.25947 8.11616 7.66667 8.4989 7.66667H10.1656L10.2334 7.66213C10.4775 7.629 10.6656 7.4198 10.6656 7.16667C10.6656 6.89053 10.4418 6.66667 10.1656 6.66667H9.4705L10.5724 5.12395L10.6093 5.06433C10.7804 4.74053 10.5484 4.33333 10.1656 4.33333ZM14.1656 1H11.8322L11.7644 1.00457C11.5204 1.03767 11.3322 1.24687 11.3322 1.5C11.3322 1.77614 11.5561 2 11.8322 2H13.2548L11.4104 4.89823L11.3777 4.95793C11.2273 5.28083 11.4609 5.66667 11.8322 5.66667H14.1656L14.2334 5.6621C14.4775 5.62899 14.6656 5.4198 14.6656 5.16667C14.6656 4.89053 14.4418 4.66667 14.1656 4.66667H12.7431L14.5874 1.76844L14.6202 1.70874C14.7706 1.38584 14.537 1 14.1656 1ZM8.46483 3.33333H10.1651C10.5038 3.33333 10.8026 3.43895 11.0426 3.61283L11.4619 2.95404C10.8373 2.79563 10.369 2.24539 10.3339 1.58029C9.6369 1.21147 8.84216 1.00261 7.9987 1.00261C5.30262 1.00261 3.09443 3.14023 3.00172 5.82738L2.99877 5.99399L2.9987 8.66853L2.05544 10.7755C1.91252 11.0948 2.05546 11.4695 2.37471 11.6124C2.45612 11.6489 2.5443 11.6677 2.63349 11.6677H13.3664C13.7162 11.6677 13.9998 11.3841 13.9998 11.0343C13.9998 10.9449 13.9808 10.8565 13.9442 10.775L12.9987 8.66827V6.66667H11.8318C11.7424 6.66667 11.6556 6.65927 11.572 6.64513C11.6322 6.80753 11.6651 6.98327 11.6651 7.16667C11.6651 7.92687 11.1006 8.5536 10.3674 8.653L10.3339 8.6576L10.1987 8.66667H8.49843C7.34563 8.66667 6.65549 7.44327 7.17056 6.46847L7.18636 6.43853L7.25856 6.32184L7.51363 5.96476C7.19796 5.68977 6.99843 5.28485 6.99843 4.83333C6.99843 4.07313 7.56303 3.44643 8.29616 3.34697L8.3297 3.34243L8.46483 3.33333ZM9.9709 12.3353C9.81176 13.2807 8.98936 14.001 7.9987 14.001C7.00803 14.001 6.18561 13.2807 6.02652 12.3353H9.9709Z" fill="#1A1A1A"/>
</svg>
`}getDisableAutoOpen(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16">
<path d="M8 0C12.4183 0 16 3.58172 16 8C16 12.4183 12.4183 16 8 16C3.58172 16 0 12.4183 0 8C0 3.58172 3.58172 0 8 0ZM8 1.2C4.24446 1.2 1.2 4.24446 1.2 8C1.2 11.7555 4.24446 14.8 8 14.8C11.7555 14.8 14.8 11.7555 14.8 8C14.8 4.24446 11.7555 1.2 8 1.2ZM4.59944 7.39944H11.3994C11.7308 7.39944 11.9994 7.66807 11.9994 7.99944C11.9994 8.30319 11.7737 8.55423 11.4809 8.59396L11.3994 8.59944H4.59944C4.26807 8.59944 3.99944 8.33081 3.99944 7.99944C3.99944 7.69568 4.22516 7.44464 4.51802 7.40491L4.59944 7.39944H11.3994H4.59944Z"/>
</svg>`}getEnableAutoOpen(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16">
<path d="M8 0C12.4183 0 16 3.58172 16 8C16 12.4183 12.4183 16 8 16C3.58172 16 0 12.4183 0 8C0 3.58172 3.58172 0 8 0ZM8 1.2C4.24446 1.2 1.2 4.24446 1.2 8C1.2 11.7555 4.24446 14.8 8 14.8C11.7555 14.8 14.8 11.7555 14.8 8C14.8 4.24446 11.7555 1.2 8 1.2ZM7 9.15147L10.5757 5.57574C10.8101 5.34142 11.1899 5.34142 11.4243 5.57574C11.6373 5.78875 11.6566 6.12208 11.4824 6.35697L11.4243 6.42426L7.42426 10.4243C7.21125 10.6373 6.87792 10.6566 6.64303 10.4824L6.57574 10.4243L4.57574 8.42426C4.34142 8.18995 4.34142 7.81005 4.57574 7.57574C4.78875 7.36272 5.12208 7.34336 5.35697 7.51764L5.42426 7.57574L7 9.15147L10.5757 5.57574L7 9.15147Z"/>
</svg>`}getHeaderIcon(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none">
<path d="M16.4406 13.9084C16.2303 14.0187 16.0106 14.1173 15.7823 14.203C15.0959 14.4608 14.338 14.607 13.5385 14.607C10.5809 14.607 8.00458 12.5725 8.00458 9.96185C8.00458 9.22779 8.42932 8.59147 9.03119 8.25635C6.35647 8.36847 5.66888 11.1563 5.66888 12.7895C5.66888 17.4065 9.92444 17.8751 10.8414 17.8751C11.3356 17.8751 12.0814 17.7312 12.5308 17.5902C12.5583 17.5811 12.5855 17.5719 12.6128 17.5625C14.3477 16.9642 15.812 15.787 16.7746 14.2613C16.9126 14.0424 16.6698 13.7882 16.4406 13.9084Z" fill="url(#paint0_linear_13140_883)"/>
<path d="M8.60694 17.0883C8.05105 16.7438 7.56848 16.2894 7.18599 15.7524C6.59411 14.9214 6.24027 13.8992 6.24027 12.7894C6.24027 11.1563 7.00075 9.70969 8.17297 8.79319C8.43919 8.58507 8.78006 8.37513 9.03125 8.25625C9.22625 8.16391 9.55981 7.99765 10.0028 8.00393C10.7373 8.01435 11.2923 8.38882 11.6081 8.81407C11.8509 9.14082 12.0005 9.54338 12.0055 9.98038C12.0057 9.96725 13.5346 5.00513 7.00245 5.00513C4.25914 5.00513 2 7.60947 2 9.89357C2 11.3424 2.33621 12.4992 2.75716 13.3956C3.6947 15.3925 5.43328 16.938 7.56002 17.6189C8.33019 17.8656 9.15069 17.9999 10.0028 17.9999C10.8866 17.9999 11.736 17.8546 12.5309 17.5901C12.0815 17.7311 11.6051 17.8083 11.1109 17.8083C10.194 17.8083 9.33931 17.5423 8.60694 17.0883Z" fill="url(#paint1_linear_13140_883)"/>
<path d="M11.52 11.3036C11.4694 11.3692 11.3136 11.4597 11.3136 11.6576C11.3136 11.8204 11.4198 11.9774 11.6086 12.1092C12.5074 12.7364 14.2015 12.6519 14.2061 12.6519C14.9054 12.6495 15.5346 12.4572 16.0981 12.1277C16.3545 11.9778 16.5918 11.7998 16.8057 11.5964C17.5399 10.8988 17.9876 9.91556 18 8.82313C18.0159 7.42218 17.5025 6.49079 17.2914 6.07838C15.9669 3.48974 13.1077 2 9.99899 2C5.61683 2 2.05954 5.52163 2.00073 9.8875C2.03044 7.60359 4.30034 5.75929 6.9986 5.75929C7.21738 5.75929 8.46499 5.78063 9.62393 6.38888C10.6448 6.92468 11.1801 7.57211 11.5521 8.21436C11.9384 8.88125 12.0071 9.7235 12.0071 10.0593C12.0071 10.3951 11.8377 10.8923 11.52 11.3036Z" fill="url(#paint2_linear_13140_883)"/>
<defs>
<linearGradient id="paint0_linear_13140_883" x1="5.66888" y1="13.0657" x2="16.8148" y2="13.0657" gradientUnits="userSpaceOnUse">
<stop stop-color="#094987"/>
<stop offset="0.245021" stop-color="#0C59A4"/>
<stop offset="1" stop-color="#114A8B"/>
</linearGradient>
<linearGradient id="paint1_linear_13140_883" x1="6.79995" y1="5.19886" x2="4.583" y2="15.8137" gradientUnits="userSpaceOnUse">
<stop stop-color="#117FBA"/>
<stop offset="0.223416" stop-color="#1797E0"/>
<stop offset="0.947917" stop-color="#0078D4"/>
</linearGradient>
<linearGradient id="paint2_linear_13140_883" x1="17.9998" y1="8.39889" x2="6.79992" y2="4.79892" gradientUnits="userSpaceOnUse">
<stop stop-color="#48D566"/>
<stop offset="1" stop-color="#35C1F1"/>
</linearGradient>
</defs>
</svg>`}getMenuIcon(){return n.Z.getTrustedHTML`<svg id="flyoutMenu" xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20">
<path d="M6.25 10C6.25 10.6904 5.69036 11.25 5 11.25C4.30964 11.25 3.75 10.6904 3.75 10C3.75 9.30964 4.30964 8.75 5 8.75C5.69036 8.75 6.25 9.30964 6.25 10ZM11.25 10C11.25 10.6904 10.6904 11.25 10 11.25C9.30964 11.25 8.75 10.6904 8.75 10C8.75 9.30964 9.30964 8.75 10 8.75C10.6904 8.75 11.25 9.30964 11.25 10ZM15 11.25C15.6904 11.25 16.25 10.6904 16.25 10C16.25 9.30964 15.6904 8.75 15 8.75C14.3096 8.75 13.75 9.30964 13.75 10C13.75 10.6904 14.3096 11.25 15 11.25Z"/>
</svg>`}getCashbackIcon(){return n.Z.getTrustedHTML`<svg width="22" height="16" viewBox="0 0 22 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<style>
@media (prefers-color-scheme: dark) {
#outline { stroke: #FFFFFF; }
#dollarIcon { fill: #FFFFFF; }
}
</style>
<path id="outline" d="M1.5 2C1.5 1.44772 1.94772 1 2.5 1H14.5481C14.8492 1 15.1343 1.1357 15.3242 1.36941L20.1992 7.36941C20.4977 7.73681 20.4977 8.26319 20.1992 8.63059L15.3242 14.6306C15.1343 14.8643 14.8492 15 14.5481 15H2.5C1.94772 15 1.5 14.5523 1.5 14V2Z" stroke="black" stroke-opacity="0.8" stroke-width="2"/>
<path id="dollarIcon" d="M9.49219 11.9785V13.1172H8.71875V12.0054C8.32487 11.9875 7.94173 11.9284 7.56934 11.8281C7.19694 11.7243 6.82992 11.5828 6.46826 11.4038L7.04834 10.2061C7.37777 10.3743 7.67497 10.5015 7.93994 10.5874C8.20492 10.6698 8.46452 10.7217 8.71875 10.7432V8.75586C7.89518 8.55176 7.32227 8.2653 7 7.89648C6.68132 7.52409 6.52197 7.05859 6.52197 6.5C6.52197 5.91634 6.71712 5.42936 7.10742 5.03906C7.49772 4.64518 8.03483 4.40169 8.71875 4.30859V3.29346H9.49219V4.26562C9.83952 4.27637 10.1725 4.33187 10.4912 4.43213C10.8135 4.53239 11.1519 4.69531 11.5063 4.9209L10.8779 6.06494C10.6165 5.90381 10.3766 5.78206 10.1582 5.69971C9.94336 5.61377 9.72135 5.55827 9.49219 5.5332V7.48828C10.237 7.6709 10.7902 7.95199 11.1519 8.33154C11.5135 8.70752 11.6943 9.16406 11.6943 9.70117C11.6943 10.3171 11.5028 10.8291 11.1196 11.2373C10.7401 11.6455 10.1976 11.8926 9.49219 11.9785ZM8.71875 7.29492V5.53857C8.45736 5.58512 8.25863 5.67822 8.12256 5.81787C7.99007 5.95394 7.92383 6.13298 7.92383 6.35498C7.92383 6.57699 7.98112 6.76318 8.0957 6.91357C8.21387 7.06038 8.42155 7.1875 8.71875 7.29492ZM9.49219 8.94385V10.7324C9.76432 10.693 9.96484 10.5999 10.0938 10.4531C10.2262 10.3027 10.2925 10.104 10.2925 9.85693C10.2925 9.62061 10.2316 9.43441 10.1099 9.29834C9.98812 9.15869 9.78223 9.04053 9.49219 8.94385Z" fill="black" fill-opacity="0.8"/>
</svg>`}getSettingsIcon(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="16" height="17" viewBox="0 0 16 17">
<path d="M7.81044 0C8.42209 0.00704958 9.03134 0.0777185 9.62836 0.210865C9.88898 0.268988 10.0839 0.486259 10.1135 0.751636L10.2553 2.02401C10.3195 2.60822 10.8128 3.0507 11.4008 3.05132C11.5589 3.05156 11.7152 3.01865 11.8613 2.95403L13.0285 2.4413C13.2712 2.33466 13.5548 2.3928 13.7361 2.58635C14.5796 3.4872 15.2077 4.56762 15.5734 5.74632C15.6522 6.00048 15.5615 6.27669 15.3473 6.43459L14.3127 7.19716C14.0176 7.41399 13.8433 7.75834 13.8433 8.12455C13.8433 8.49076 14.0176 8.8351 14.3133 9.05241L15.3488 9.81525C15.5631 9.97311 15.6539 10.2494 15.575 10.5036C15.2096 11.6821 14.5817 12.7624 13.7387 13.6634C13.5577 13.8569 13.2743 13.9152 13.0315 13.8089L11.8596 13.2954C11.5243 13.1487 11.1393 13.1702 10.8224 13.3533C10.5056 13.5364 10.2947 13.8593 10.2544 14.2231L10.1135 15.4953C10.0845 15.7577 9.89375 15.9735 9.63698 16.0346C8.42994 16.3218 7.17236 16.3218 5.96532 16.0346C5.70855 15.9735 5.51783 15.7577 5.48878 15.4953L5.34809 14.225C5.30677 13.8619 5.09558 13.54 4.77898 13.3575C4.46238 13.175 4.07796 13.1536 3.74379 13.2995L2.57161 13.813C2.32881 13.9194 2.04532 13.8611 1.86428 13.6674C1.02081 12.7654 0.392955 11.6838 0.0279603 10.504C-0.0506552 10.2499 0.0401776 9.97385 0.254331 9.81608L1.29044 9.05277C1.58556 8.83594 1.75986 8.49159 1.75986 8.12538C1.75986 7.75917 1.58556 7.41483 1.29006 7.19771L0.254594 6.43571C0.0401229 6.27787 -0.0507935 6.00149 0.0280992 5.74715C0.393725 4.56846 1.02191 3.48804 1.8654 2.58718C2.04662 2.39363 2.33024 2.33549 2.573 2.44213L3.73998 2.95477C4.07576 3.10213 4.46179 3.07987 4.7801 2.89391C5.09704 2.71007 5.30803 2.38685 5.34877 2.02304L5.4905 0.751636C5.52009 0.486125 5.71518 0.268784 5.97596 0.210785C6.57369 0.0778498 7.18359 0.00721143 7.81044 0ZM7.81059 1.24992C7.43223 1.25437 7.05492 1.28702 6.68181 1.34751L6.59104 2.16182C6.50618 2.91973 6.06699 3.59252 5.40898 3.97419C4.74694 4.36098 3.93976 4.40752 3.23745 4.09931L2.48887 3.77047C2.01226 4.34894 1.63291 5.00113 1.36573 5.7014L2.03056 6.19066C2.64623 6.64301 3.00986 7.36139 3.00986 8.12538C3.00986 8.88937 2.64623 9.60775 2.03121 10.0596L1.36533 10.5502C1.63228 11.2517 2.01169 11.9051 2.48863 12.4847L3.2429 12.1542C3.94131 11.8493 4.743 11.8939 5.40323 12.2745C6.06347 12.6551 6.5039 13.3265 6.59029 14.0855L6.68109 14.9054C7.42246 15.0315 8.17984 15.0315 8.92121 14.9054L9.01201 14.0856C9.096 13.3267 9.53592 12.6531 10.1969 12.271C10.858 11.889 11.6613 11.8442 12.361 12.1504L13.1146 12.4806C13.5911 11.9019 13.9704 11.2495 14.2375 10.5491L13.5726 10.0593C12.9569 9.60692 12.5933 8.88854 12.5933 8.12455C12.5933 7.36056 12.9569 6.64218 13.5718 6.19039L14.2359 5.70091C13.9687 5.00051 13.5893 4.3482 13.1126 3.76963L12.3655 4.09781C12.0611 4.23251 11.7318 4.30184 11.3992 4.30132C10.1744 4.30003 9.14657 3.37796 9.0129 2.16152L8.92213 1.34725C8.55085 1.28683 8.17749 1.25427 7.81059 1.24992ZM7.80004 4.99996C9.52593 4.99996 10.925 6.39907 10.925 8.12496C10.925 9.85085 9.52593 11.25 7.80004 11.25C6.07415 11.25 4.67504 9.85085 4.67504 8.12496C4.67504 6.39907 6.07415 4.99996 7.80004 4.99996ZM7.80004 6.24996C6.76451 6.24996 5.92504 7.08943 5.92504 8.12496C5.92504 9.16049 6.76451 9.99996 7.80004 9.99996C8.83557 9.99996 9.67504 9.16049 9.67504 8.12496C9.67504 7.08943 8.83557 6.24996 7.80004 6.24996Z"/>
</svg>`}getCheckmarkIcon(){return n.Z.getTrustedHTML`<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M8 0C12.4183 0 16 3.58172 16 8C16 12.4183 12.4183 16 8 16C3.58172 16 0 12.4183 0 8C0 3.58172 3.58172 0 8 0ZM8 1C4.13401 1 1 4.13401 1 8C1 11.866 4.13401 15 8 15C11.866 15 15 11.866 15 8C15 4.13401 11.866 1 8 1ZM11.3584 5.64645C11.532 5.82001 11.5513 6.08944 11.4163 6.28431L11.3584 6.35355L7.35355 10.3584C7.17999 10.532 6.91056 10.5513 6.71569 10.4163L6.64645 10.3584L4.64645 8.35842C4.45118 8.16316 4.45118 7.84658 4.64645 7.65131C4.82001 7.47775 5.08944 7.45846 5.28431 7.59346L5.35355 7.65131L7 9.298L10.6513 5.64645C10.8466 5.45118 11.1632 5.45118 11.3584 5.64645Z" fill="#18AB6E"/>
</svg>`}getCrossIcon(){return n.Z.getTrustedHTML`<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M8 0C12.4183 0 16 3.58172 16 8C16 12.4183 12.4183 16 8 16C3.58172 16 0 12.4183 0 8C0 3.58172 3.58172 0 8 0ZM8 1C4.13401 1 1 4.13401 1 8C1 11.866 4.13401 15 8 15C11.866 15 15 11.866 15 8C15 4.13401 11.866 1 8 1ZM5.80943 5.11372L5.87868 5.17157L8 7.29289L10.1213 5.17157C10.2949 4.99801 10.5643 4.97872 10.7592 5.11372L10.8284 5.17157C11.002 5.34514 11.0213 5.61456 10.8863 5.80943L10.8284 5.87868L8.70711 8L10.8284 10.1213C11.002 10.2949 11.0213 10.5643 10.8863 10.7592L10.8284 10.8284C10.6549 11.002 10.3854 11.0213 10.1906 10.8863L10.1213 10.8284L8 8.70711L5.87868 10.8284C5.70511 11.002 5.43569 11.0213 5.24082 10.8863L5.17157 10.8284C4.99801 10.6549 4.97872 10.3854 5.11372 10.1906L5.17157 10.1213L7.29289 8L5.17157 5.87868C4.99801 5.70511 4.97872 5.43569 5.11372 5.24082L5.17157 5.17157C5.34514 4.99801 5.61456 4.97872 5.80943 5.11372Z" fill="#F76A3B"/>
</svg>`}getNotificationIcon(){return n.Z.getTrustedHTML`<svg id="notification-icon" width="15" height="16" viewBox="0 0 15 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M6.9979 0C10.1469 0 12.7418 2.33488 12.9824 5.3554L12.9958 5.57762L13.0003 5.80214L12.9993 9.398L13.9247 11.6202C13.9472 11.6743 13.9649 11.7302 13.9776 11.7871L13.9929 11.8733L14.0015 12.0046C14.0015 12.4526 13.705 12.8387 13.2524 12.9677L13.136 12.9945L13.0015 13.0046L9.49986 13.004L9.49488 13.1653C9.40977 14.469 8.32542 15.5 7.00026 15.5C5.67478 15.5 4.59022 14.4685 4.50558 13.1644L4.49986 13.004L0.999153 13.0046C0.911201 13.0046 0.823829 12.993 0.739266 12.9702L0.614807 12.9277C0.204025 12.7567 -0.0379439 12.3392 0.0124571 11.8757L0.0335445 11.7483L0.0759637 11.6202L0.99926 9.401L1.00035 5.79281L1.00465 5.56824C1.12726 2.45115 3.77129 0 6.9979 0ZM8.49986 13.004H5.49986L5.50722 13.1454C5.57576 13.8581 6.143 14.425 6.8558 14.4931L7.00026 14.5C7.77996 14.5 8.42071 13.9051 8.49339 13.1445L8.49986 13.004ZM6.9979 1C4.37535 1 2.22741 2.92372 2.0174 5.38498L2.00417 5.59723L2.00026 5.80214V9.5L1.96185 9.69217L0.999142 12.0046L12.9569 12.0066L13.0021 12.0045L12.0387 9.6922L12.0003 9.5L12.0004 5.81241L11.9963 5.60831C11.8911 3.0349 9.6949 1 6.9979 1Z" fill="#1A1A1A"/>
</svg>`}getDisabledNotificationIcon(){return n.Z.getTrustedHTML`<svg id="disabled-notification-icon" width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M2.0044 5.56824C2.03648 4.75282 2.2411 3.98297 2.58356 3.29065L0.146447 0.853553C-0.0488155 0.658291 -0.0488155 0.341709 0.146447 0.146447C0.341709 -0.0488155 0.658291 -0.0488155 0.853553 0.146447L15.8536 15.1464C16.0488 15.3417 16.0488 15.6583 15.8536 15.8536C15.6583 16.0488 15.3417 16.0488 15.1464 15.8536L12.2972 13.0043L10.4996 13.004L10.4946 13.1653C10.4095 14.469 9.32518 15.5 8.00002 15.5C6.67453 15.5 5.58998 14.4685 5.50533 13.1644L5.49962 13.004L1.99891 13.0046C1.91096 13.0046 1.82358 12.993 1.73902 12.9702L1.61456 12.9277C1.20378 12.7567 0.961812 12.3392 1.01221 11.8757L1.0333 11.7483L1.07572 11.6202L1.99902 9.401L2.0001 5.79281L2.0044 5.56824ZM11.299 12.0061L3.33843 4.04552C3.16766 4.46607 3.05719 4.91575 3.01715 5.38498L3.00393 5.59723L3.00002 5.80214V9.5L2.96161 9.69217L1.9989 12.0046L11.299 12.0061ZM9.49961 13.004H6.49962L6.50697 13.1454C6.57552 13.8581 7.14275 14.425 7.85556 14.4931L8.00002 14.5C8.77971 14.5 9.42046 13.9051 9.49315 13.1445L9.49961 13.004ZM13.0384 9.6922L13.9133 11.7919L14.7653 12.644C14.9153 12.4691 15.0013 12.2458 15.0013 12.0046L14.9926 11.8733L14.9774 11.7871C14.9647 11.7302 14.947 11.6743 14.9244 11.6202L13.999 9.398L14 5.80214L13.9955 5.57762L13.9821 5.3554C13.7416 2.33488 11.1466 0 7.99766 0C6.3584 0 4.86951 0.632662 3.78523 1.66389L4.49193 2.3706C5.39369 1.52222 6.63126 1 7.99766 1C10.6947 1 12.8909 3.0349 12.996 5.60831L13.0001 5.81241L13 9.5L13.0384 9.6922Z" fill="#1A1A1A"/>
</svg>`}getChevronIcon(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="8" height="5" viewBox="0 0 8 5" fill="none">
<path d="M0.146447 0.646447C0.341709 0.451184 0.658291 0.451184 0.853553 0.646447L4 3.79289L7.14645 0.646447C7.34171 0.451184 7.65829 0.451184 7.85355 0.646447C8.04882 0.841709 8.04882 1.15829 7.85355 1.35355L4.35355 4.85355C4.15829 5.04882 3.84171 5.04882 3.64645 4.85355L0.146447 1.35355C-0.0488155 1.15829 -0.0488155 0.841709 0.146447 0.646447Z" fill="var(--neutral-foreground-rest)"/>
</svg>`}getCaretDownIcon(){return n.Z.getTrustedHTML`<svg width="12" height="7" viewBox="0 0 12 7" fill="inherit" xmlns="http://www.w3.org/2000/svg">
<path d="M5.99935 4.94942L1.60796 0.558057C1.36388 0.313981 0.968148 0.313981 0.724072 0.558057C0.479997 0.802132 0.479997 1.19786 0.724072 1.44194L0.724073 1.44194L5.55743 6.27525C5.80151 6.51933 6.19719 6.51933 6.44127 6.27525L11.2746 1.44194C11.5187 1.19787 11.5187 0.802131 11.2746 0.558055C11.0305 0.313982 10.6348 0.313982 10.3908 0.558055L5.99935 4.94942Z" stroke="inherit" stroke-width="1"/>
</svg>`}getYellowLightIcon(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16" fill="none">
<path d="M10.3587 12.666L10.1649 13.505C10.0161 14.1472 9.46754 14.6123 8.81901 14.662L8.70361 14.6664H7.2958C6.63618 14.6664 6.05901 14.2365 5.86452 13.6155L5.83424 13.5039L5.64067 12.666H10.3587ZM8.00001 1.33398C10.6694 1.33398 12.8333 3.49794 12.8333 6.16732C12.8333 7.59166 12.2096 8.8962 10.9897 10.0611C10.9662 10.0836 10.9498 10.1125 10.9425 10.1441L10.5907 11.666H5.40934L5.05868 10.1443C5.05135 10.1125 5.0349 10.0837 5.01135 10.0611C3.79078 8.8962 3.16667 7.59166 3.16667 6.16732C3.16667 3.49794 5.33063 1.33398 8.00001 1.33398Z" fill="#E8AA00"/>
</svg>`}getMoneyIcon(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16" fill="none">
<path d="M9 7C9 8.10457 8.10457 9 7 9C5.89543 9 5 8.10457 5 7C5 5.89543 5.89543 5 7 5C8.10457 5 9 5.89543 9 7ZM8 7C8 6.44772 7.55228 6 7 6C6.44772 6 6 6.44772 6 7C6 7.55228 6.44772 8 7 8C7.55228 8 8 7.55228 8 7ZM1 4.25C1 3.55964 1.55964 3 2.25 3H11.75C12.4404 3 13 3.55964 13 4.25V9.75C13 10.4404 12.4404 11 11.75 11H2.25C1.55964 11 1 10.4404 1 9.75V4.25ZM2.25 4C2.11193 4 2 4.11193 2 4.25V5H2.5C2.77614 5 3 4.77614 3 4.5V4H2.25ZM2 9.75C2 9.88807 2.11193 10 2.25 10H3V9.5C3 9.22386 2.77614 9 2.5 9H2V9.75ZM4 9.5V10H10V9.5C10 8.67157 10.6716 8 11.5 8H12V6H11.5C10.6716 6 10 5.32843 10 4.5V4H4V4.5C4 5.32843 3.32843 6 2.5 6H2V8H2.5C3.32843 8 4 8.67157 4 9.5ZM11 10H11.75C11.8881 10 12 9.88807 12 9.75V9H11.5C11.2239 9 11 9.22386 11 9.5V10ZM12 5V4.25C12 4.11193 11.8881 4 11.75 4H11V4.5C11 4.77614 11.2239 5 11.5 5H12ZM4.5 13C3.8334 13 3.26836 12.5652 3.07304 11.9637C3.21179 11.9876 3.35444 12 3.5 12H11.75C12.9926 12 14 10.9926 14 9.75V5.08535C14.5826 5.29127 15 5.84689 15 6.5V9.75C15 11.5449 13.5449 13 11.75 13H4.5Z" fill="#707070"/>
</svg>`}getCheckmarkCircleIcon(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16" fill="none">
<path d="M8 2C11.3137 2 14 4.68629 14 8C14 11.3137 11.3137 14 8 14C4.68629 14 2 11.3137 2 8C2 4.68629 4.68629 2 8 2ZM8 3C5.23858 3 3 5.23858 3 8C3 10.7614 5.23858 13 8 13C10.7614 13 13 10.7614 13 8C13 5.23858 10.7614 3 8 3ZM7.24953 9.04242L10.1203 6.16398C10.3153 5.96846 10.6319 5.96803 10.8274 6.16304C11.0012 6.33637 11.0208 6.60577 10.8861 6.80082L10.8283 6.87014L7.60403 10.1031C7.43053 10.277 7.16082 10.2965 6.96576 10.1615L6.89645 10.1036L5.14645 8.35355C4.95118 8.15829 4.95118 7.84171 5.14645 7.64645C5.32001 7.47288 5.58944 7.4536 5.78431 7.58859L5.85355 7.64645L7.24953 9.04242L10.1203 6.16398L7.24953 9.04242Z" fill="#707070"/>
</svg>`}getHourglassHalfIcon(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16" fill="none">
<path d="M5.02515 13H10.9706C10.9169 12.4806 10.7919 12.1321 10.661 11.8855C10.4963 11.5752 10.2752 11.3361 9.97942 11.0803C9.86945 10.9852 9.77096 10.9056 9.65701 10.8134C9.59998 10.7673 9.53863 10.7177 9.47047 10.6619C9.28949 10.5135 9.06586 10.3245 8.85818 10.1024C8.40115 9.61371 7.99944 8.93739 7.99943 8C7.99951 8.93781 7.59727 9.6143 7.13992 10.1029C6.93206 10.325 6.70824 10.5139 6.52708 10.6623C6.45867 10.7184 6.39755 10.7677 6.34033 10.8139C6.22629 10.906 6.12765 10.9857 6.01756 11.0808C5.72137 11.3367 5.49995 11.5759 5.33507 11.8861C5.20409 12.1326 5.07896 12.481 5.02515 13ZM3.00256 2.64534C2.97854 1.68104 3.80078 1 4.68082 1H11.3185C12.1985 1 13.0208 1.681 12.9968 2.64526C12.9715 3.66216 12.757 4.43599 12.4304 5.05156C12.1047 5.66562 11.6828 6.09278 11.2898 6.43237C11.154 6.54974 11.0143 6.66258 10.8871 6.76535C10.8357 6.80694 10.7862 6.84689 10.7399 6.88481C10.5713 7.02289 10.4328 7.14303 10.3197 7.26381C10.1074 7.49055 9.9997 7.70124 9.9997 8C9.9997 8.29897 10.1073 8.50972 10.3192 8.73635C10.4321 8.85709 10.5704 8.97719 10.7388 9.11524C10.7852 9.15327 10.8347 9.19335 10.8863 9.23508C11.0132 9.33772 11.1525 9.45041 11.288 9.56756C11.6805 9.90708 12.1021 10.3341 12.4279 10.9478C12.7544 11.5631 12.9694 12.3366 12.9957 13.3531C13.0206 14.318 12.198 15 11.3174 15H4.67878C3.79815 15 2.97548 14.318 3.00056 13.353C3.02698 12.3364 3.24225 11.5629 3.56921 10.9476C3.89537 10.3339 4.31737 9.90688 4.71032 9.5674C4.84587 9.45029 4.98527 9.33764 5.11226 9.23502C5.16394 9.19325 5.21357 9.15315 5.26005 9.11508C5.42858 8.97704 5.56701 8.85693 5.68003 8.73618C5.89218 8.50954 5.99975 8.29887 5.9997 8.00008C5.99965 7.7013 5.89196 7.49057 5.67961 7.26382C5.5665 7.14304 5.42799 7.0229 5.25938 6.88482C5.21307 6.84689 5.16366 6.80696 5.1122 6.76538C4.985 6.6626 4.84535 6.54975 4.70953 6.43238C4.31655 6.09278 3.89467 5.66563 3.56894 5.05158C3.24241 4.43602 3.02789 3.66221 3.00256 2.64534ZM4.68082 2C4.27643 2 3.99428 2.3007 4.00225 2.62043C4.02427 3.5043 4.20805 4.12243 4.45234 4.58296C4.69744 5.045 5.0189 5.37807 5.36338 5.67575C5.48618 5.78188 5.60469 5.87762 5.72639 5.97594C5.78105 6.0201 5.83635 6.06478 5.89298 6.11115C6.06784 6.25436 6.24902 6.40889 6.40952 6.58027C6.74439 6.93786 6.9996 7.38146 6.9997 7.99992C6.9998 8.61828 6.74488 9.0619 6.41011 9.41955C6.24967 9.59095 6.06854 9.74549 5.8937 9.8887C5.83682 9.93529 5.78128 9.98016 5.7264 10.0245C5.60496 10.1226 5.48669 10.2182 5.36407 10.3241C5.0195 10.6218 4.69779 10.9549 4.45227 11.4169C4.20756 11.8774 4.02319 12.4954 4.00022 13.379C3.99191 13.6989 4.27408 14 4.67878 14H11.3174C11.7221 14 12.0043 13.6989 11.996 13.3789C11.9731 12.4953 11.789 11.8772 11.5446 11.4167C11.2993 10.9546 10.978 10.6216 10.6338 10.3239C10.5113 10.218 10.3931 10.1224 10.2718 10.0243C10.217 9.97994 10.1615 9.9351 10.1048 9.88855C9.93009 9.74533 9.74913 9.59079 9.58883 9.41938C9.25435 9.06172 8.9997 8.61818 8.9997 8C8.9997 7.38151 9.25488 6.93788 9.58976 6.58028C9.75026 6.40889 9.93145 6.25435 10.1063 6.11114C10.163 6.06475 10.2183 6.02006 10.273 5.97589C10.3947 5.87758 10.5131 5.78185 10.6359 5.67574C10.9804 5.37805 11.3019 5.04498 11.547 4.58294C11.7913 4.12241 11.9751 3.50427 11.9971 2.6204C12.005 2.30069 11.7229 2 11.3185 2H4.68082Z" fill="#707070"/>
</svg>`}getShoppingTripsCashbackIcon(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16" fill="none">
<path d="M3.99507 4.00001C2.89051 3.99729 1.99729 4.89052 2.00001 5.99507L2.01143 10.645C2.01414 11.7496 2.91176 12.6472 4.01632 12.6499L10.6041 12.6661C11.1296 12.6674 11.6334 12.4619 12.0067 12.0939L14.4019 9.73317C15.193 8.95348 15.1918 7.67471 14.3993 6.88872L12.0912 4.59978C11.7157 4.2274 11.2091 4.01773 10.6815 4.01643L3.99507 4.00001Z" fill="#3275F0"/>
</svg>`}getShoppingTripsOpenLinkIcon(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16" fill="none">
<path d="M4.49999 3C3.67157 3 3 3.67157 3 4.5V11.5C3 12.3284 3.67157 13 4.49999 13H11.5C12.3284 13 12.9999 12.3284 12.9999 11.5V9.26923C12.9999 8.99309 13.2238 8.76923 13.4999 8.76923C13.7761 8.76923 13.9999 8.99309 13.9999 9.26923V11.5C13.9999 12.8807 12.8807 14 11.5 14H4.49999C3.11928 14 2 12.8807 2 11.5V4.5C2 3.11929 3.11928 2 4.49999 2H6.73075C7.00689 2 7.23074 2.22386 7.23074 2.5C7.23074 2.77614 7.00689 3 6.73075 3H4.49999ZM8.76926 2.5C8.76926 2.22386 8.99311 2 9.26925 2H13.5C13.7761 2 14 2.22386 14 2.5V6.73077C14 7.00691 13.7761 7.23077 13.5 7.23077C13.2239 7.23077 13 7.00691 13 6.73077V3.70711L9.6228 7.08433C9.42754 7.27959 9.11096 7.27959 8.9157 7.08433C8.72044 6.88906 8.72044 6.57248 8.9157 6.37722L12.2929 3H9.26925C8.99311 3 8.76926 2.77614 8.76926 2.5Z" fill="#707070"/>
</svg>`}getErrorImage(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="314" height="72" viewBox="0 0 314 72" fill="none">
<path d="M22.2505 70.9081C20.4564 68.0473 43.6258 53.3722 71.7396 56.2548C148.839 64.1601 174.218 0 228.893 0C283.567 0 284.573 70.9081 282.057 70.9081C279.541 70.9081 22.2505 70.9081 22.2505 70.9081Z" fill="#EBECEF"/>
<path d="M247.052 70.0138C246.724 70.5816 247.336 71.193 247.905 70.931C250.421 69.7299 253.55 69.3805 255.497 68.7253C260.113 67.1748 260.704 65.2094 264.227 62.1739C261.382 61.89 258.844 61.5843 256.394 62.5233C252.412 64.052 248.912 66.8254 247.052 70.0138Z" fill="#BFBFBF"/>
<path d="M243.377 54.9664C243.617 58.4387 245.893 66.6279 247.052 70.5806C247.205 71.1266 248.015 71.0829 248.102 70.5151C248.803 66.4532 250.159 58.0019 249.984 54.5297C249.7 48.4369 246.155 45.4014 246.155 45.4014C246.155 45.4014 242.961 48.8955 243.377 54.9664Z" fill="#BFBFBF"/>
<path d="M246.746 70.0787C246.549 70.7339 247.403 71.1925 247.84 70.6684C251.472 66.4536 259.239 57.1943 261.274 53.0887C264.752 46.0132 262.63 40.3572 262.63 40.3572C262.63 40.3572 256.81 42.3444 253.507 49.4855C251.581 53.6129 248.256 64.8376 246.746 70.0787Z" fill="#BFBFBF"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M180.169 42.7802L169.252 52.8038C168.902 53.1096 168.377 53.0877 168.092 52.7165C167.786 52.3671 167.83 51.8211 168.158 51.4936L179.075 41.4699C179.425 41.1642 179.95 41.186 180.257 41.5573C180.541 41.9067 180.497 42.4526 180.169 42.7802Z" fill="#EBECEF"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M243.135 21.947H203.535C203.535 24.9607 201.063 27.3847 198.022 27.3847C194.981 27.3847 192.53 24.9607 192.53 21.947H153.477C150.983 21.947 148.97 23.9561 148.97 26.4457V66.4311C148.97 68.8988 150.983 70.9079 153.477 70.9079H192.53C192.53 67.8942 195.003 65.4702 198.022 65.4702C198.241 65.4702 198.459 65.4921 198.656 65.5139C201.391 65.8196 203.535 68.1345 203.535 70.9079H243.135C245.629 70.9079 247.642 68.8988 247.642 66.4311V26.4457C247.642 23.9561 245.629 21.947 243.135 21.947ZM182.466 56.2109L183.079 59.6176L179.928 57.9579C178.244 57.0844 176.165 57.7396 175.312 59.4648L173.759 62.6313L172.205 59.4648C171.374 57.7396 169.273 57.0844 167.589 57.9579L164.46 59.6176L165.073 56.2109C165.423 54.3328 164.11 52.5203 162.207 52.2801L158.728 51.7996L161.244 49.4193C162.644 48.0871 162.644 45.8597 161.244 44.5275L158.728 42.1472L162.207 41.6668C164.11 41.4047 165.423 39.614 165.073 37.7359L164.46 34.3292L167.589 35.9889C169.273 36.8624 171.374 36.2073 172.205 34.5039L173.759 31.3374L175.312 34.5039C176.143 36.2073 178.244 36.8842 179.928 35.9889L183.079 34.3292L182.466 37.7359C182.138 39.614 183.429 41.4047 185.332 41.6668L188.811 42.1472L186.317 44.5275C184.917 45.8597 184.917 48.0871 186.317 49.4193L188.811 51.7996L185.332 52.2801C183.429 52.5203 182.138 54.311 182.466 56.2109Z" fill="white"/>
<path d="M198.678 29.2622V65.6007" stroke="#BFBFBF" stroke-linecap="round" stroke-dasharray="2 2"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M187.476 48.174C186.776 47.497 186.776 46.4051 187.476 45.7281L189.992 43.3478C191.021 42.3651 190.452 40.6398 189.052 40.4651L185.573 39.9847C184.61 39.8537 183.976 38.9583 184.151 38.0193L184.763 34.6126C185.026 33.2368 183.56 32.1449 182.313 32.8L179.163 34.4597C178.331 34.8964 177.281 34.5689 176.843 33.6954L175.29 30.5725C174.677 29.3059 172.883 29.3059 172.249 30.5725L170.696 33.739C170.28 34.6125 169.23 34.9401 168.398 34.5034L165.248 32.8437C164.001 32.1885 162.535 33.2586 162.797 34.6562L163.41 38.063C163.585 39.0238 162.929 39.8974 161.966 40.0284L158.487 40.5088C157.087 40.7054 156.518 42.4306 157.547 43.3914L160.063 45.7718C160.763 46.4488 160.763 47.5407 160.063 48.2176L157.547 50.598C156.518 51.5807 157.087 53.3059 158.487 53.4806L161.966 53.9611C162.929 54.0921 163.585 54.9874 163.41 55.9265L162.797 59.3332C162.535 60.709 164.001 61.7791 165.248 61.1239L168.398 59.4642C169.23 59.0275 170.28 59.3769 170.696 60.2286L172.249 63.3951C172.883 64.6617 174.677 64.6617 175.29 63.3951L176.843 60.2286C177.259 59.3769 178.309 59.0275 179.163 59.4642L182.313 61.1239C183.56 61.7791 185.026 60.709 184.763 59.3332L184.151 55.9265C183.976 54.9874 184.632 54.0921 185.573 53.9611L189.052 53.4806C190.452 53.2841 191.021 51.5589 189.992 50.598L187.476 48.174ZM185.332 52.2577C183.429 52.5197 182.116 54.3105 182.466 56.1885L183.079 59.5953L179.928 57.9356C178.244 57.0621 176.165 57.7172 175.312 59.4424L173.759 62.6089L172.205 59.4424C171.374 57.7172 169.273 57.0621 167.589 57.9356L164.46 59.5953L165.073 56.1885C165.423 54.3105 164.11 52.4979 162.207 52.2577L158.728 51.7772L161.244 49.3969C162.644 48.0648 162.644 45.8373 161.244 44.5052L158.728 42.1248L162.207 41.6444C164.11 41.3823 165.423 39.5916 165.073 37.7136L164.46 34.3068L167.589 35.9665C169.273 36.84 171.374 36.1849 172.205 34.4815L173.759 31.315L175.312 34.4815C176.143 36.1849 178.244 36.8619 179.928 35.9665L183.079 34.3068L182.466 37.7136C182.138 39.5916 183.429 41.3823 185.332 41.6444L188.811 42.1248L186.317 44.5052C184.917 45.8373 184.917 48.0648 186.317 49.3969L188.811 51.7772L185.332 52.2577Z" fill="#BFBFBF"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M186.317 44.5273L188.811 42.147L185.332 41.6665C183.429 41.4045 182.116 39.6138 182.466 37.7357L183.079 34.329L179.928 35.9887C178.244 36.8622 176.165 36.207 175.312 34.5037L173.759 31.3372L172.205 34.5037C171.374 36.207 169.273 36.884 167.589 35.9887L164.46 34.329L165.073 37.7357C165.423 39.6138 164.11 41.4045 162.207 41.6665L158.728 42.147L161.244 44.5273C162.644 45.8594 162.644 48.0869 161.244 49.419L158.728 51.7994L162.207 52.2798C164.11 52.5419 165.423 54.3326 165.073 56.2107L164.46 59.6174L167.589 57.9577C169.273 57.0842 171.374 57.7393 172.205 59.4645L173.759 62.6311L175.312 59.4645C176.143 57.7393 178.244 57.0842 179.928 57.9577L183.079 59.6174L182.466 56.2107C182.138 54.3326 183.429 52.5201 185.332 52.2798L188.811 51.7994L186.317 49.419C184.917 48.0651 184.917 45.8594 186.317 44.5273ZM169.252 52.8039C168.902 53.1097 168.376 53.0878 168.092 52.7166C167.786 52.3672 167.829 51.8212 168.158 51.4937L179.075 41.47C179.425 41.1643 179.95 41.1861 180.256 41.5574C180.541 41.9068 180.519 42.4527 180.169 42.7803L169.252 52.8039Z" fill="white"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M170.433 40.6836C168.639 40.2032 166.78 41.2514 166.298 43.0421C165.817 44.8547 166.911 46.6673 168.683 47.1259C170.477 47.6063 172.337 46.5581 172.818 44.7674C173.299 42.9766 172.227 41.1641 170.433 40.6836ZM171.177 44.3306C170.937 45.2041 170.018 45.7501 169.121 45.5098C168.202 45.2696 167.677 44.3524 167.917 43.4789C168.158 42.6054 169.077 42.0594 169.996 42.2997C170.893 42.5617 171.418 43.4571 171.177 44.3306Z" fill="#BFBFBF"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M179.447 46.7981C177.653 46.3177 175.793 47.3659 175.312 49.1566C174.831 50.9474 175.903 52.7818 177.697 53.2404C179.491 53.7208 181.35 52.6726 181.832 50.8818C182.313 49.113 181.241 47.2786 179.447 46.7981ZM180.191 50.4669C179.95 51.3404 179.031 51.8864 178.112 51.6462C177.193 51.3841 176.69 50.4888 176.931 49.6152C177.172 48.7417 178.091 48.1958 178.988 48.436C179.906 48.6544 180.432 49.5716 180.191 50.4669Z" fill="#BFBFBF"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M180.169 42.7802L169.252 52.8038C168.902 53.1096 168.377 53.0877 168.092 52.7165C167.786 52.3671 167.83 51.8211 168.158 51.4936L179.075 41.4699C179.425 41.1642 179.95 41.186 180.257 41.5573C180.541 41.9067 180.497 42.4526 180.169 42.7802Z" fill="#BFBFBF"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M223.729 30.5725C223.116 29.3059 221.322 29.3059 220.688 30.5725L219.135 33.739C218.719 34.5907 217.669 34.9401 216.837 34.4815L213.687 32.8218C212.44 32.1667 210.996 33.2368 211.236 34.6126L211.849 38.0193C212.024 38.9583 211.368 39.8537 210.405 39.9847L206.926 40.4651C205.526 40.6617 204.957 42.3869 205.986 43.3478L208.48 45.7281C209.18 46.3833 209.18 47.497 208.48 48.174L205.986 50.5543C204.957 51.537 205.526 53.2622 206.926 53.4369L210.405 53.9174C211.368 54.0484 212.002 54.9438 211.849 55.8828L211.236 59.2895C210.996 60.6653 212.44 61.7354 213.687 61.0803L216.837 59.4206C217.691 58.9838 218.719 59.3114 219.135 60.1631L220.688 63.3296C221.301 64.5962 223.095 64.5962 223.729 63.3296L225.282 60.1631C225.698 59.3114 226.748 58.962 227.58 59.4206L230.73 61.0803C231.977 61.7354 233.421 60.6653 233.181 59.2895L232.568 55.8828C232.393 54.9438 233.049 54.0484 234.012 53.9174L237.491 53.4369C238.891 53.2404 239.46 51.5152 238.431 50.5543L235.937 48.174C235.237 47.5188 235.237 46.4051 235.937 45.7281L238.431 43.3478C239.46 42.3651 238.891 40.6398 237.491 40.4651L234.012 39.9847C233.049 39.8537 232.415 38.9583 232.568 38.0193L233.181 34.6126C233.421 33.2368 231.977 32.1667 230.73 32.8218L227.58 34.4815C226.726 34.9183 225.698 34.5907 225.282 33.739L223.729 30.5725ZM216.356 43.4788C216.597 42.6053 217.516 42.0593 218.413 42.2995C219.331 42.5398 219.857 43.457 219.616 44.3305C219.375 45.204 218.456 45.75 217.559 45.5097C216.662 45.2695 216.137 44.3523 216.356 43.4788ZM218.872 40.6835C217.078 40.2031 215.218 41.2513 214.737 43.042C214.256 44.8328 215.328 46.6671 217.122 47.1476C218.916 47.628 220.775 46.5798 221.257 44.7891C221.76 42.9765 220.666 41.164 218.872 40.6835ZM227.448 48.4142C226.529 48.174 225.611 48.6981 225.392 49.5934C225.151 50.467 225.676 51.3842 226.595 51.6244C227.514 51.8646 228.433 51.3405 228.652 50.4451C228.87 49.5716 228.345 48.6544 227.448 48.4142ZM223.751 49.1567C224.232 47.366 226.092 46.3177 227.886 46.7982C229.68 47.2786 230.752 49.0912 230.271 50.9037C229.789 52.6944 227.93 53.7427 226.136 53.2622C224.342 52.7818 223.27 50.9474 223.751 49.1567ZM228.608 42.78C228.958 42.4742 228.98 41.9283 228.695 41.557C228.389 41.2076 227.864 41.164 227.536 41.4915L216.619 51.5152C216.268 51.8209 216.247 52.3669 216.531 52.7381C216.837 53.0875 217.362 53.1312 217.691 52.8036L228.608 42.78Z" fill="#BFBFBF"/>
<path d="M86.0258 60.5349L137.725 61.1682C139.694 61.19 141.269 62.806 141.225 64.7715L141.203 67.6978C141.181 69.6632 139.562 71.2355 137.593 71.1919L85.8945 70.5586C83.9254 70.5367 82.3502 68.9207 82.394 66.9553L82.4377 64.029C82.4596 62.0854 84.0567 60.5131 86.0258 60.5349Z" fill="#BFBFBF"/>
<path d="M89.3953 10.0013L141.029 10.6346C147.986 10.7219 153.543 16.4216 153.455 23.3661L153.105 51.0349C153.018 57.9794 147.308 63.5263 140.35 63.4389L88.7171 62.8056C81.7597 62.7183 76.2026 57.0185 76.2901 50.0741L76.6401 22.4053C76.7277 15.4608 82.4379 9.91391 89.3953 10.0013Z" fill="#BFBFBF"/>
<path d="M83.2693 9.91386L131.599 10.5253C138.556 10.6127 144.113 16.3124 144.026 23.2569L143.676 50.9257C143.588 57.8702 137.878 63.417 130.921 63.3297L82.5911 62.7182C75.6337 62.6309 70.0766 56.9311 70.1641 49.9866L70.5142 22.3179C70.6017 15.3952 76.312 9.8265 83.2693 9.91386Z" fill="#EBECEF"/>
<path d="M102.216 55.0098C112.39 58.8096 123.723 53.6558 127.529 43.5011C131.336 33.3464 126.173 22.0343 115.999 18.2345C105.826 14.4347 94.4929 19.5885 90.6861 29.7432C86.8792 39.8979 92.0425 51.21 102.216 55.0098Z" fill="white" stroke="#BFBFBF" stroke-miterlimit="10"/>
<path d="M109.283 22.2092L109.108 36.6223L101.713 41.3612" fill="white"/>
<path d="M109.283 22.2092L109.108 36.6223L101.713 41.3612" fill="white"/>
<path d="M109.283 22.2092L109.108 36.6223L101.713 41.3612" stroke="#BFBFBF" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"/>
<path d="M1.09375 70.9077H312.906" stroke="#EBECEF" stroke-width="2" stroke-miterlimit="10" stroke-linecap="round" stroke-linejoin="round"/>
</svg>`}getDefaultProductImage(){return"data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSI2NiIgaG\n VpZ2h0PSI2NiIgdmlld0JveD0iMCAwIDY2IDY2IiBmaWxsPSJub25lIj4KICAgICAgICA8cmVjdCB3aWR0aD0iNjYiIGhlaW\n dodD0iNjYiIHJ4PSI0IiBmaWxsPSIjRjdGN0Y3Ii8+CiAgICAgICAgPHBhdGggZD0iTTMyLjI5OTUgMzUuMjkwNkwzMi40MT\n EgMzUuMTk1OUMzMi43NTY2IDM0Ljk0MzQgMzMuMjI3MyAzNC45NDAzIDMzLjU3NiAzNS4xODY2TDMzLjcwMDUgMzUuMjkwNk\n w0Mi45Mzc0IDQ0LjM1ODFDNDIuMjc3MSA0NC43NjUyIDQxLjQ5OTMgNDUgNDAuNjY2NyA0NUgyNS4zMzMzQzI0LjUwMDcgND\n UgMjMuNzIyOSA0NC43NjUyIDIzLjA2MjYgNDQuMzU4MUwzMi4yOTk1IDM1LjI5MDZMMzIuNDExIDM1LjE5NTlMMzIuMjk5NS\n AzNS4yOTA2Wk00MC42NjY3IDIxQzQzLjA1OTkgMjEgNDUgMjIuOTQwMSA0NSAyNS4zMzMzVjQwLjY2NjdDNDUgNDEuNTAyNy\n A0NC43NjMyIDQyLjI4MzUgNDQuMzUzMSA0Mi45NDU2TDM1LjEwMTYgMzMuODYzM0wzNC45MzAzIDMzLjcwNzVDMzMuODE5OS\n AzMi43NzI0IDMyLjE5MjIgMzIuNzY5OCAzMS4wNzkgMzMuNjk5N0wzMC44OTg0IDMzLjg2MzNMMjEuNjQ2OSA0Mi45NDU2Qz\n IxLjIzNjggNDIuMjgzNSAyMSA0MS41MDI3IDIxIDQwLjY2NjdWMjUuMzMzM0MyMSAyMi45NDAxIDIyLjk0MDEgMjEgMjUuMz\n MzMyAyMUg0MC42NjY3Wk0zOC4wMDI4IDI1QzM2LjM0NDQgMjUgMzUgMjYuMzQ0NCAzNSAyOC4wMDI4QzM1IDI5LjY2MTIgMz\n YuMzQ0NCAzMS4wMDU2IDM4LjAwMjggMzEuMDA1NkMzOS42NjEyIDMxLjAwNTYgNDEuMDA1NiAyOS42NjEyIDQxLjAwNTYgMj\n guMDAyOEM0MS4wMDU2IDI2LjM0NDQgMzkuNjYxMiAyNSAzOC4wMDI4IDI1Wk0zOC4wMDI4IDI3QzM4LjU1NjcgMjcgMzkuMD\n A1NiAyNy40NDkgMzkuMDA1NiAyOC4wMDI4QzM5LjAwNTYgMjguNTU2NyAzOC41NTY3IDI5LjAwNTYgMzguMDAyOCAyOS4wMD\n U2QzM3LjQ0OSAyOS4wMDU2IDM3IDI4LjU1NjcgMzcgMjguMDAyOEMzNyAyNy40NDkgMzcuNDQ5IDI3IDM4LjAwMjggMjdaIi\n BmaWxsPSIjRDZENkQ2Ii8+CiAgICAgICAgPC9zdmc+"}getCountdownTimerIcon(){return n.Z.getTrustedHTML`
<svg id="countdown-svg" aria-hidden="true">
<circle r="13" cx="15" cy="15" id="back-countdown-circle"></circle>
<circle r="13" cx="15" cy="15" id="countdown-circle"></circle>
</svg>
`}getShoppingIcon(){return n.Z.getTrustedHTML`
<svg width="14" height="14" viewBox="0 0 14 14" id="shopping-tag-icon" xmlns="http://www.w3.org/2000/svg">
<path d="M13.9934 1.81949C13.992 0.834647 13.1949 0.0352401 12.208 0.0287846L7.81331 3.85878e-05C7.33336 -0.00310088 6.87209 0.185442 6.53228 0.523656L0.528027 6.4997C-0.175375 7.19979 -0.176102 8.33655 0.526407 9.03754L4.9732 13.4747C5.67508 14.1751 6.81305 14.1751 7.51492 13.4747L13.4736 7.52893C13.8113 7.19196 14.0007 6.73472 14 6.25817L13.9934 1.81949ZM10.3931 4.47982C9.89678 4.47982 9.49445 4.07836 9.49445 3.58313C9.49445 3.0879 9.89678 2.68644 10.3931 2.68644C10.8894 2.68644 11.2917 3.0879 11.2917 3.58313C11.2917 4.07836 10.8894 4.47982 10.3931 4.47982Z"/>
</svg>`}getXSmallTagLeft(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="4" height="16" viewBox="0 0 4 16" fill="none">
<path d="M0 3C0 1.34315 1.34315 0 3 0H4V16H3C1.34315 16 0 14.6569 0 13V3Z" fill="#036AC4"/>
</svg>`}getXSmallTagRight(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="8" height="16" viewBox="0 0 8 16" fill="none">
<path d="M2.74682 14.8291C2.17893 15.5674 1.30036 16 0.368949 16H0V0H0.368949C1.30036 0 2.17893 0.432611 2.74682 1.17087L6.59297 6.17087C7.42248 7.24922 7.42248 8.75078 6.59298 9.82913L2.74682 14.8291Z" fill="#036AC4"/>
</svg>`}getSmallTagLeft(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="4.5" height="20" viewBox="0 0 4.5 30" fill="none"><path fill-rule="evenodd" clip-rule="evenodd" d="M7.0003 0H3.5C1.567 0 0 1.567 0 3.5V26.5C0 28.433 1.567 30 3.5 30H7.0003V0Z" fill="#0078D4"/>`}getSmallTagRight(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="10" height="20" viewBox="0 0 15 30" fill="none"><path fill-rule="evenodd" clip-rule:"evenodd" d="M0,30h0.6c1,0,1.9-0.4,2.5-1.1L14,17.4c1.3-1.4,1.3-3.5,0-4.8L3.1,1.1C2.5,0.4,1.5,0,0.6,0H0V30z" fill="#0078D4"/>`}getMediumTagLeft(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="5" height="24" viewBox="0 0 5 24" fill="none">
<path d="M0 5C0 2.23858 2.23858 0 5 0V0V24V24C2.23858 24 0 21.7614 0 19V5Z" fill="#036AC4"/>
</svg>`}getMediumTagRight(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="12" height="24" viewBox="0 0 12 24" fill="none">
<path d="M4.49923 22.2009C3.54926 23.3409 2.14202 24 0.658125 24H0V0H0.658125C2.14202 0 3.54926 0.659115 4.49923 1.79908L10.3326 8.79908C11.8778 10.6533 11.8778 13.3467 10.3326 15.2009L4.49923 22.2009Z" fill="#036AC4"/>
</svg>`}getLargeTagLeft(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="7" height="30" viewBox="0 0 7 30" fill="none"><path fill-rule="evenodd" clip-rule="evenodd" d="M7.0003 0H3.5C1.567 0 0 1.567 0 3.5V26.5C0 28.433 1.567 30 3.5 30H7.0003V0Z" fill="#0078D4"/>`}getLargeTagRight(){return n.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="15" height="30" viewBox="0 0 15 30" fill="none"><path fill-rule="evenodd" clip-rule:"evenodd" d="M0,30h0.6c1,0,1.9-0.4,2.5-1.1L14,17.4c1.3-1.4,1.3-3.5,0-4.8L3.1,1.1C2.5,0.4,1.5,0,0.6,0H0V30z" fill="#0078D4"/>`}getShoppingTagIcon(){return n.Z.getTrustedHTML`
<svg class="svg-icon" width="17" height="16" viewBox="0 0 17 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M12 5C12.5523 5 13 4.55228 13 4C13 3.44772 12.5523 3 12 3C11.4477 3 11 3.44772 11 4C11 4.55228 11.4477 5 12 5ZM9.12922 4.30281e-05C8.59514 -0.00345791 8.08184 0.206807 7.7037 0.583987L1.02216 7.24852C0.239412 8.02928 0.238604 9.297 1.02036 10.0788L5.96875 15.0271C6.7498 15.8082 8.01613 15.8082 8.79718 15.0271L15.428 8.39633C15.8038 8.02054 16.0146 7.51063 16.0138 6.97917L16.0065 2.02911C16.0049 0.930807 15.1179 0.0393006 14.0196 0.032101L9.12922 4.30281e-05ZM8.4099 1.29199C8.59897 1.1034 8.85562 0.998271 9.12266 1.00002L14.013 1.03208C14.5622 1.03568 15.0057 1.48143 15.0065 2.03058L15.0138 6.98065C15.0142 7.24637 14.9088 7.50133 14.7209 7.68923L8.09007 14.32C7.69955 14.7106 7.06638 14.7106 6.67586 14.32L1.72746 9.37164C1.33659 8.98077 1.33699 8.34691 1.72836 7.95653L8.4099 1.29199Z" fill="#1A1A1A"/>
</svg>`}getCashbackTagIcon(){return n.Z.getTrustedHTML`
<svg width="21" height="14" viewBox="0 0 21 14" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M3.57065 9.96066e-06C1.8706 -0.00437353 0.495833 1.43862 0.500009 3.22302L0.51759 10.735C0.521767 12.5194 1.90331 13.9695 3.60335 13.9738L13.7428 14C14.5514 14.0021 15.3269 13.67 15.9014 13.0757L19.588 9.26188C20.8056 8.0023 20.8038 5.93645 19.5839 4.6667L16.0316 0.968935C15.4537 0.367356 14.6738 0.0286393 13.8619 0.0265455L3.57065 9.96066e-06Z" fill="#3267FA"/>
</svg>`}getPersonalizedReminddersIcon(){return n.Z.getTrustedHTML`
<svg class="svg-icon" width="17" height="17" viewBox="0 0 17 17" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M7 0C4.79086 0 3 1.79086 3 4C3 6.20914 4.79086 8 7 8C9.20914 8 11 6.20914 11 4C11 1.79086 9.20914 0 7 0ZM4 4C4 2.34315 5.34315 1 7 1C8.65685 1 10 2.34315 10 4C10 5.65685 8.65685 7 7 7C5.34315 7 4 5.65685 4 4ZM2.00873 9C0.903151 9 0 9.88687 0 11C0 12.6912 0.83281 13.9663 2.13499 14.7966C3.41697 15.614 5.14526 16 7 16C7.41085 16 7.8155 15.9811 8.21047 15.9427C7.97298 15.6472 7.7654 15.3266 7.59233 14.9855C7.39798 14.9951 7.20041 15 7 15C5.26489 15 3.74318 14.636 2.67262 13.9534C1.62226 13.2837 1 12.3088 1 11C1 10.4467 1.44786 10 2.00873 10L7.59971 10C7.7826 9.64222 8.00353 9.30711 8.25716 9L2.00873 9ZM8.63507 11.9199C9.72301 11.642 10.369 10.5231 10.0657 9.44195L9.90953 8.88518C10.1636 8.68988 10.439 8.52258 10.7314 8.3877L11.0688 8.74565C11.8577 9.58277 13.1885 9.58347 13.9783 8.74718L14.303 8.4034C14.6008 8.54392 14.8806 8.71819 15.1378 8.92148L15.0116 9.34376C14.6823 10.4459 15.3483 11.598 16.4677 11.8627L16.8167 11.9452C16.8383 12.127 16.8494 12.3121 16.8494 12.4999C16.8494 12.6559 16.8417 12.81 16.8268 12.9619L16.3662 13.0795C15.2783 13.3575 14.6323 14.4764 14.9356 15.5575L15.0917 16.1142C14.8376 16.3095 14.5623 16.4769 14.2698 16.6118L13.9325 16.2538C13.1436 15.4167 11.8128 15.416 11.023 16.2523L10.698 16.5964C10.4002 16.4559 10.1205 16.2817 9.86333 16.0785L9.98967 15.6557C10.319 14.5536 9.65302 13.4014 8.53358 13.1368L8.18403 13.0541C8.16247 12.8725 8.15137 12.6875 8.15137 12.4999C8.15137 12.3438 8.15904 12.1896 8.17402 12.0377L8.63507 11.9199ZM13.5004 12.4999C13.5004 11.9476 13.0527 11.4999 12.5004 11.4999C11.9481 11.4999 11.5004 11.9476 11.5004 12.4999C11.5004 13.0521 11.9481 13.4999 12.5004 13.4999C13.0527 13.4999 13.5004 13.0521 13.5004 12.4999Z" fill="#1A1A1A"/>
</svg>`}getPackageTrackingIcon(){return n.Z.getTrustedHTML`
<svg class="svg-icon" width="16" height="15" viewBox="0 0 16 15" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M0.0424805 1.74988C0.0424805 0.78338 0.825982 -0.00012207 1.79248 -0.00012207H10.2505C11.217 -0.00012207 12.0005 0.783379 12.0005 1.74988V2.99994L12.8824 2.99982C13.4506 2.99974 13.9701 3.32075 14.2242 3.829L15.8422 7.06498C15.9464 7.27326 16.0006 7.50293 16.0006 7.7358V11.4997C16.0006 12.3282 15.329 12.9997 14.5006 12.9997H12.9505C12.7189 14.1409 11.71 14.9999 10.5005 14.9999C9.29101 14.9999 8.28213 14.141 8.0505 12.9999H6.95048C6.71884 14.141 5.70997 14.9999 4.50049 14.9999C3.29101 14.9999 2.28213 14.141 2.0505 12.9999H1.79248C0.825982 12.9999 0.0424805 12.2164 0.0424805 11.2499V1.74988ZM8.0505 11.9999C8.28213 10.8588 9.29101 9.99988 10.5005 9.99988C10.6717 9.99988 10.8389 10.0171 11.0005 10.0499V1.74988C11.0005 1.33566 10.6647 0.999878 10.2505 0.999878H1.79248C1.37827 0.999878 1.04248 1.33566 1.04248 1.74988V11.2499C1.04248 11.6641 1.37827 11.9999 1.79248 11.9999H2.0505C2.28213 10.8588 3.29101 9.99988 4.50049 9.99988C5.70997 9.99988 6.71884 10.8588 6.95048 11.9999H8.0505ZM12.0005 10.4997C12.4805 10.8603 12.8266 11.3897 12.9504 11.9997H14.5006C14.7767 11.9997 15.0006 11.7759 15.0006 11.4997V7.99982H12.0005V10.4997ZM12.0005 6.99982H14.6916L13.3298 4.27621C13.2451 4.10679 13.0719 3.99979 12.8825 3.99982L12.0005 3.99994V6.99982ZM4.50049 10.9999C3.67206 10.9999 3.00049 11.6715 3.00049 12.4999C3.00049 13.3283 3.67206 13.9999 4.50049 13.9999C5.32892 13.9999 6.00049 13.3283 6.00049 12.4999C6.00049 11.6715 5.32892 10.9999 4.50049 10.9999ZM9.00049 12.4999C9.00049 13.3283 9.67206 13.9999 10.5005 13.9999C11.3289 13.9999 12.0005 13.3283 12.0005 12.4999C12.0005 11.6715 11.3289 10.9999 10.5005 10.9999C9.67206 10.9999 9.00049 11.6715 9.00049 12.4999Z" fill="#1A1A1A"/>
</svg>`}getOpenLinkIcon(){return n.Z.getTrustedHTML`
<svg class="svg-icon" width="14" height="14" viewBox="0 0 14 14" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M6.51562 3C6.23948 3 6.01562 3.22386 6.01562 3.5C6.01562 3.77614 6.23948 4 6.51562 4H9.29289L5.14645 8.14645C4.95118 8.34171 4.95118 8.65829 5.14645 8.85355C5.34171 9.04882 5.65829 9.04882 5.85355 8.85355L10 4.70711V7.48438C10 7.76052 10.2239 7.98438 10.5 7.98438C10.7761 7.98438 11 7.76052 11 7.48438V3.5C11 3.22386 10.7761 3 10.5 3H6.51562ZM9.76562 14C11.0136 14 12.0481 13.0855 12.2354 11.8901C13.2572 11.5761 14 10.6248 14 9.5V2.5C14 1.11929 12.8807 0 11.5 0H4.5C3.36321 0 2.40363 0.758746 2.10007 1.79744C0.909465 1.98887 0 3.02104 0 4.26562V10.5C0 12.433 1.567 14 3.5 14H9.76562ZM1 4.26562C1 3.61252 1.4174 3.0569 2 2.85098V9.5C2 10.8807 3.11929 12 4.5 12H11.1803C10.9744 12.5826 10.4187 13 9.76562 13H3.5C2.11929 13 1 11.8807 1 10.5V4.26562ZM4.5 1H11.5C12.3284 1 13 1.67157 13 2.5V9.5C13 10.3284 12.3284 11 11.5 11H4.5C3.67157 11 3 10.3284 3 9.5V2.5C3 1.67157 3.67157 1 4.5 1Z" fill="#1A1A1A"/>
</svg>`}getDismissIcon(){return n.Z.getTrustedHTML`
<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M8 0C12.4183 0 16 3.58172 16 8C16 12.4183 12.4183 16 8 16C3.58172 16 0 12.4183 0 8C0 3.58172 3.58172 0 8 0ZM5.80943 5.11372C5.61456 4.97872 5.34514 4.99801 5.17157 5.17157L5.11372 5.24082C4.97872 5.43569 4.99801 5.70511 5.17157 5.87868L7.29289 8L5.17157 10.1213L5.11372 10.1906C4.97872 10.3854 4.99801 10.6549 5.17157 10.8284L5.24082 10.8863C5.43569 11.0213 5.70511 11.002 5.87868 10.8284L8 8.70711L10.1213 10.8284L10.1906 10.8863C10.3854 11.0213 10.6549 11.002 10.8284 10.8284L10.8863 10.7592C11.0213 10.5643 11.002 10.2949 10.8284 10.1213L8.70711 8L10.8284 5.87868L10.8863 5.80943C11.0213 5.61456 11.002 5.34514 10.8284 5.17157L10.7592 5.11372C10.5643 4.97872 10.2949 4.99801 10.1213 5.17157L8 7.29289L5.87868 5.17157L5.80943 5.11372Z" fill="#767676"/>
</svg>`}getSearchIcon(){return n.Z.getTrustedHTML`
<svg id="search-icon" width="14" height="14" viewBox="0 0 14 14" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M5.5 0C8.53757 0 11 2.46243 11 5.5C11 6.83879 10.5217 8.06586 9.72656 9.01962L13.8536 13.1464C14.0488 13.3417 14.0488 13.6583 13.8536 13.8536C13.68 14.0271 13.4106 14.0464 13.2157 13.9114L13.1464 13.8536L9.01962 9.72656C8.06586 10.5217 6.83879 11 5.5 11C2.46243 11 0 8.53757 0 5.5C0 2.46243 2.46243 0 5.5 0ZM5.5 1C3.01472 1 1 3.01472 1 5.5C1 7.98528 3.01472 10 5.5 10C7.98528 10 10 7.98528 10 5.5C10 3.01472 7.98528 1 5.5 1Z" fill-opacity="0.3"/>
</svg>`}getLeftArrowIcon(){return n.Z.getTrustedHTML`
<svg id="left-arrow-icon" width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M8.45508 11.9824L2.4668 6L8.45508 0.0175781L8.98242 0.544922L3.5332 6L8.98242 11.4551L8.45508 11.9824Z" fill="black" fill-opacity="1"/>
</svg>`}getRightArrowIcon(){return n.Z.getTrustedHTML`
<svg id="right-arrow-icon" width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M3.01758 11.4551L8.4668 6L3.01758 0.544922L3.54492 0.0175781L9.5332 6L3.54492 11.9824L3.01758 11.4551Z" fill="black" fill-opacity="1"/>
</svg>`}getSnoozeBellIcon(){return n.Z.getTrustedHTML`
<svg width="15" height="16" viewBox="0 0 15 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M2.00006 9.49999V6.05444C2.002 6.03656 2.00299 6.01839 2.00299 6C2.00299 3.23851 4.24162 0.999878 7.00311 0.999878C7.47527 0.999878 7.93135 1.06518 8.3632 1.18695C8.62898 1.26189 8.90519 1.10719 8.98013 0.841406C9.05507 0.575626 8.90037 0.299419 8.63459 0.224479C8.11528 0.0780539 7.56791 -0.00012207 7.00311 -0.00012207C3.7091 -0.00012207 1.03506 2.65428 1.00328 5.94078C1.00115 5.95949 1.00006 5.97852 1.00006 5.9978V9.39999L0.076986 11.6154C-0.197467 12.2741 0.286485 13 1.00006 13H4.5C4.5 14.3807 5.61929 15.5 7 15.5C8.38071 15.5 9.5 14.3807 9.5 13L13.0001 13C13.7136 13 14.1976 12.2741 13.9231 11.6154L13.0001 9.39999V7.9978C13.0001 7.72166 12.7762 7.4978 12.5001 7.4978C12.2239 7.4978 12.0001 7.72166 12.0001 7.9978V9.49999C12.0001 9.566 12.0131 9.63136 12.0385 9.6923L13.0001 12H1.00006L1.9616 9.6923C1.98699 9.63136 2.00006 9.566 2.00006 9.49999ZM5.5 13H8.5C8.5 13.8284 7.82843 14.5 7 14.5C6.17157 14.5 5.5 13.8284 5.5 13ZM10.9999 0H14.4999C14.8755 0 15.1068 0.392617 14.9521 0.714033L14.9095 0.786731L11.9602 5H14.4999C14.776 5 14.9999 5.22386 14.9999 5.5C14.9999 5.74546 14.823 5.94961 14.5898 5.99194L14.4999 6H10.9999C10.6243 6 10.393 5.60738 10.5476 5.28597L10.5903 5.21327L13.5396 1H10.9999C10.7238 1 10.4999 0.776142 10.4999 0.5C10.4999 0.25454 10.6768 0.0503916 10.91 0.00805569L10.9999 0ZM6.50096 4H9.00096C9.39661 4 9.62472 4.4307 9.43273 4.75291L9.38507 4.82009L7.56848 7H9.00096C9.2771 7 9.50096 7.22386 9.50096 7.5C9.50096 7.74546 9.32408 7.94961 9.09083 7.99194L9.00096 8H6.50096C6.1053 8 5.87719 7.5693 6.06918 7.24709L6.11684 7.17991L7.93343 5H6.50096C6.22481 5 6.00096 4.77614 6.00096 4.5C6.00096 4.25454 6.17783 4.05039 6.41108 4.00806L6.50096 4Z" fill="#767676"/>
</svg>
`}getRightChevronIcon(){return n.Z.getTrustedHTML`
<svg aria-hidden="true" width="9" height="16" viewBox="0 0 9 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M0.46967 0.21967C0.176777 0.512563 0.176777 0.987437 0.46967 1.28033L7.18934 8L0.469671 14.7197C0.176777 15.0126 0.176777 15.4874 0.469671 15.7803C0.762564 16.0732 1.23744 16.0732 1.53033 15.7803L8.78033 8.53033C9.07322 8.23744 9.07322 7.76256 8.78033 7.46967L1.53033 0.21967C1.23744 -0.0732233 0.762563 -0.0732233 0.46967 0.21967Z"/>
</svg>
`}getChatDismissIcon(){return n.Z.getTrustedHTML`
<svg aria-hidden="true" width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M2.58859 2.71569L2.64645 2.64645C2.82001 2.47288 3.08944 2.4536 3.28431 2.58859L3.35355 2.64645L8 7.293L12.6464 2.64645C12.8417 2.45118 13.1583 2.45118 13.3536 2.64645C13.5488 2.84171 13.5488 3.15829 13.3536 3.35355L8.707 8L13.3536 12.6464C13.5271 12.82 13.5464 13.0894 13.4114 13.2843L13.3536 13.3536C13.18 13.5271 12.9106 13.5464 12.7157 13.4114L12.6464 13.3536L8 8.707L3.35355 13.3536C3.15829 13.5488 2.84171 13.5488 2.64645 13.3536C2.45118 13.1583 2.45118 12.8417 2.64645 12.6464L7.293 8L2.64645 3.35355C2.47288 3.17999 2.4536 2.91056 2.58859 2.71569L2.64645 2.64645L2.58859 2.71569Z"/>
</svg>
`}getBuyingGuidesIcon(){return n.Z.getTrustedHTML`
<svg width="14" height="14" viewBox="0 0 14 14" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M8.87774 0.282251L9.22602 1.35305C9.33432 1.67859 9.51712 1.97441 9.75988 2.21699C10.0026 2.45957 10.2987 2.64223 10.6245 2.75044L11.6961 3.09845L11.7175 3.10381C11.8001 3.13292 11.8716 3.18692 11.9222 3.25836C11.9728 3.3298 12 3.41516 12 3.50268C12 3.5902 11.9728 3.67556 11.9222 3.747C11.8716 3.81844 11.8001 3.87244 11.7175 3.90155L10.6459 4.24956C10.3201 4.35778 10.0241 4.54044 9.78131 4.78302C9.53855 5.0256 9.35575 5.32141 9.24745 5.64696L8.89918 6.71775C8.87004 6.80029 8.816 6.87175 8.7445 6.92231C8.67301 6.97286 8.58758 7.00001 8.5 7.00001C8.41242 7.00001 8.32699 6.97286 8.2555 6.92231C8.24844 6.91732 8.24157 6.91213 8.23486 6.90675C8.17359 6.85755 8.12709 6.79215 8.10082 6.71775L7.75255 5.64696C7.73383 5.59014 7.71284 5.53422 7.68966 5.47932C7.57963 5.21872 7.42023 4.98116 7.21968 4.77999C7.18154 4.74173 7.14208 4.70496 7.10139 4.66973C6.88302 4.48064 6.62919 4.33588 6.35408 4.24421L5.28247 3.8962C5.19987 3.86708 5.12835 3.81308 5.07776 3.74164C5.02717 3.6702 5 3.58484 5 3.49733C5 3.40981 5.02717 3.32445 5.07776 3.25301C5.12835 3.18157 5.19987 3.12757 5.28247 3.09845L6.35408 2.75044C6.67591 2.63941 6.96768 2.45549 7.20656 2.21307C7.44544 1.97065 7.62497 1.67631 7.73111 1.35305L8.07939 0.282251C8.10853 0.19972 8.16257 0.128252 8.23406 0.0776997C8.30556 0.0271473 8.39098 0 8.47857 0C8.56615 0 8.65158 0.0271473 8.72307 0.0776997C8.79457 0.128252 8.84861 0.19972 8.87774 0.282251ZM13.7829 8.21319L13.0175 7.96461C12.7848 7.88731 12.5733 7.75684 12.3999 7.58357C12.2265 7.4103 12.0959 7.199 12.0186 6.96647L11.7698 6.20161C11.749 6.14266 11.7104 6.09161 11.6593 6.05551C11.6083 6.0194 11.5473 6.00001 11.4847 6.00001C11.4221 6.00001 11.3611 6.0194 11.31 6.05551C11.259 6.09161 11.2204 6.14266 11.1996 6.20161L10.9508 6.96647C10.875 7.19737 10.7467 7.40762 10.5761 7.58077C10.4055 7.75392 10.1971 7.8853 9.9672 7.96461L9.20176 8.21319C9.14277 8.23398 9.09168 8.27255 9.05554 8.32358C9.01941 8.37461 9 8.43558 9 8.4981C9 8.56061 9.01941 8.62158 9.05554 8.67261C9.09168 8.72364 9.14277 8.76221 9.20176 8.78301L9.9672 9.03158C10.2003 9.10926 10.412 9.24032 10.5855 9.41428C10.7589 9.58824 10.8893 9.80031 10.9661 10.0335L11.2149 10.7984C11.2357 10.8574 11.2743 10.9084 11.3254 10.9445C11.3764 10.9806 11.4374 11 11.5 11C11.5626 11 11.6236 10.9806 11.6746 10.9445C11.7257 10.9084 11.7643 10.8574 11.7851 10.7984L12.0339 10.0335C12.1113 9.80101 12.2418 9.58972 12.4152 9.41645C12.5886 9.24317 12.8001 9.11271 13.0328 9.03541L13.7982 8.78683C13.8572 8.76603 13.9083 8.72746 13.9445 8.67643C13.9806 8.62541 14 8.56443 14 8.50192C14 8.43941 13.9806 8.37844 13.9445 8.32741C13.9083 8.27638 13.8572 8.23781 13.7982 8.21701L13.7829 8.21319ZM11.5018 12C11.3096 11.9993 11.1225 11.958 10.9515 11.8799C10.7833 12.5244 10.1972 13 9.5 13H2.5C1.67157 13 1 12.3284 1 11.5V4.5C1 3.67157 1.67157 3 2.5 3H4.08798C4.13055 2.88542 4.18822 2.77651 4.26024 2.67477C4.43039 2.43437 4.67061 2.25408 4.95086 2.15392L5.42985 2H2.5C1.11929 2 0 3.11929 0 4.5V11.5C0 12.8807 1.11929 14 2.5 14H9.5C10.7327 14 11.757 13.1079 11.9624 11.9341C11.8165 11.9818 11.6609 11.9996 11.5018 12ZM7.67334 7.74305C7.57281 7.6648 7.48752 7.58379 7.4154 7.5H5C4.72386 7.5 4.5 7.72386 4.5 8C4.5 8.27614 4.72386 8.5 5 8.5H8.00365C8.00424 8.31112 8.04428 8.12239 8.12375 7.95339C7.9636 7.91332 7.81347 7.84321 7.67334 7.74305ZM2.75 5.75C3.16421 5.75 3.5 5.41421 3.5 5C3.5 4.58579 3.16421 4.25 2.75 4.25C2.33579 4.25 2 4.58579 2 5C2 5.41421 2.33579 5.75 2.75 5.75ZM2.75 8.75C3.16421 8.75 3.5 8.41421 3.5 8C3.5 7.58579 3.16421 7.25 2.75 7.25C2.33579 7.25 2 7.58579 2 8C2 8.41421 2.33579 8.75 2.75 8.75ZM2.75 11.75C3.16421 11.75 3.5 11.4142 3.5 11C3.5 10.5858 3.16421 10.25 2.75 10.25C2.33579 10.25 2 10.5858 2 11C2 11.4142 2.33579 11.75 2.75 11.75ZM5 10.5C4.72386 10.5 4.5 10.7239 4.5 11C4.5 11.2761 4.72386 11.5 5 11.5H9.5C9.77614 11.5 10 11.2761 10 11C10 10.7239 9.77614 10.5 9.5 10.5H5Z"/>
</svg>
`}getChatIcon(){return n.Z.getTrustedHTML`
<svg aria-hidden="true" width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
<g filter="url(#filter0_dd_3145_525)">
<path d="M12 1C17.5228 1 22 5.47648 22 10.9985C22 16.5205 17.5228 20.997 12 20.997C10.8884 20.997 9.80241 20.8151 8.77611 20.4659C7.83349 20.1451 6.82179 19.9945 5.85819 20.2453L3.06538 20.9723C2.6111 21.0907 2.1469 20.8184 2.02858 20.3641C1.99199 20.2237 1.99198 20.0763 2.02855 19.9358L2.75447 17.1476C3.00566 16.1828 2.85436 15.1698 2.53265 14.2262C2.18239 13.1988 2 12.1116 2 10.9985C2 5.47648 6.47715 1 12 1Z" fill="url(#paint0_linear_3145_525)"/>
<path d="M2.93942 20.4885L2.9393 20.4885C2.75227 20.5372 2.56115 20.4251 2.51243 20.2381L2.51241 20.238C2.49738 20.1803 2.49735 20.1196 2.51242 20.0617L3.23834 17.2736C3.52333 16.179 3.34503 15.0596 3.0059 14.0649C2.67337 13.0895 2.5 12.0567 2.5 10.9985C2.5 5.7527 6.75322 1.5 12 1.5C17.2467 1.5 21.5 5.7527 21.5 10.9985C21.5 16.2443 17.2467 20.497 12 20.497C10.9431 20.497 9.91158 20.3241 8.93719 19.9926C7.94349 19.6544 6.82548 19.4769 5.73224 19.7615L2.93942 20.4885Z" stroke="url(#paint1_linear_3145_525)"/>
<path d="M2.93942 20.4885L2.9393 20.4885C2.75227 20.5372 2.56115 20.4251 2.51243 20.2381L2.51241 20.238C2.49738 20.1803 2.49735 20.1196 2.51242 20.0617L3.23834 17.2736C3.52333 16.179 3.34503 15.0596 3.0059 14.0649C2.67337 13.0895 2.5 12.0567 2.5 10.9985C2.5 5.7527 6.75322 1.5 12 1.5C17.2467 1.5 21.5 5.7527 21.5 10.9985C21.5 16.2443 17.2467 20.497 12 20.497C10.9431 20.497 9.91158 20.3241 8.93719 19.9926C7.94349 19.6544 6.82548 19.4769 5.73224 19.7615L2.93942 20.4885Z" stroke="url(#paint2_radial_3145_525)" stroke-opacity="0.6"/>
<path d="M2.93942 20.4885L2.9393 20.4885C2.75227 20.5372 2.56115 20.4251 2.51243 20.2381L2.51241 20.238C2.49738 20.1803 2.49735 20.1196 2.51242 20.0617L3.23834 17.2736C3.52333 16.179 3.34503 15.0596 3.0059 14.0649C2.67337 13.0895 2.5 12.0567 2.5 10.9985C2.5 5.7527 6.75322 1.5 12 1.5C17.2467 1.5 21.5 5.7527 21.5 10.9985C21.5 16.2443 17.2467 20.497 12 20.497C10.9431 20.497 9.91158 20.3241 8.93719 19.9926C7.94349 19.6544 6.82548 19.4769 5.73224 19.7615L2.93942 20.4885Z" stroke="url(#paint3_radial_3145_525)" stroke-opacity="0.8"/>
</g>
<g filter="url(#filter1_i_3145_525)">
<g clip-path="url(#clip0_3145_525)">
<path d="M16.5001 12.7114C16.5001 12.8283 16.4938 12.9445 16.4811 13.0591C16.4058 13.7577 16.1044 14.3895 15.6508 14.8781C15.708 14.8144 15.7594 14.746 15.8046 14.6728C15.8394 14.6171 15.8704 14.5591 15.8966 14.4985C15.9061 14.4786 15.9148 14.4579 15.9219 14.4373C15.9306 14.4174 15.9378 14.3967 15.9441 14.3761C15.9513 14.3571 15.9576 14.3372 15.9631 14.3173C15.9686 14.2965 15.9743 14.276 15.9789 14.2552C15.9798 14.2529 15.9806 14.2504 15.9813 14.248C15.9861 14.2273 15.9899 14.2067 15.9939 14.186C15.9979 14.1646 16.0019 14.143 16.0051 14.1216C16.0051 14.1208 16.0051 14.1208 16.0051 14.1201C16.0083 14.1002 16.0106 14.0803 16.0123 14.0596C16.0171 14.0126 16.0194 13.9658 16.0194 13.9179C16.0194 13.649 15.9456 13.3967 15.8164 13.182C15.7871 13.1318 15.7546 13.0842 15.719 13.0389C15.677 12.9847 15.6318 12.9338 15.5826 12.8869C15.4605 12.7683 15.3178 12.6711 15.16 12.6027C15.0918 12.5725 15.0205 12.5479 14.9475 12.5295C14.9466 12.5295 14.9451 12.5287 14.9443 12.5287L14.919 12.52L14.5495 12.3927V12.3919L13.5828 12.0584C13.5796 12.0576 13.5756 12.0576 13.5733 12.0569L13.513 12.0347C13.3186 11.9583 13.1576 11.8151 13.057 11.6329L12.7041 10.7297L12.2996 9.69528L12.222 9.49561L12.2021 9.45498C12.18 9.4008 12.168 9.34194 12.168 9.28073C12.168 9.26485 12.168 9.24896 12.1696 9.23458C12.1926 9.00699 12.3853 8.82874 12.6185 8.82874C12.6803 8.82874 12.7398 8.84144 12.7938 8.86452L14.5951 9.79126L14.9505 9.97353C15.1385 10.0857 15.3136 10.2178 15.4738 10.3667C16.0543 10.9014 16.4349 11.6509 16.4921 12.4889C16.4969 12.5628 16.5001 12.6367 16.5001 12.7114Z" fill="url(#paint4_linear_3145_525)"/>
<path d="M16.0189 13.9178C16.0189 14.0101 16.0103 14.0993 15.9943 14.186C15.9894 14.2091 15.9848 14.2322 15.9793 14.2553C15.9689 14.2966 15.9579 14.3364 15.9444 14.3762C15.9373 14.3969 15.9301 14.4175 15.9223 14.4374C15.9143 14.4581 15.9056 14.478 15.8969 14.4986C15.8708 14.5591 15.8398 14.6171 15.8049 14.6728C15.7598 14.7461 15.7081 14.8145 15.6511 14.8782C15.3886 15.1695 14.4971 15.6889 14.1686 15.8999L13.4393 16.347C12.9049 16.6775 12.3996 16.9112 11.7628 16.9271C11.7326 16.928 11.7033 16.9288 11.6739 16.9288C11.6328 16.9288 11.5923 16.928 11.5518 16.9265C10.4733 16.8852 9.53262 16.3042 8.99029 15.4457C8.74213 15.0534 8.57796 14.6031 8.52246 14.1193C8.63896 14.7805 9.21329 15.2818 9.90562 15.2818C10.1483 15.2818 10.376 15.2206 10.5749 15.1123C10.5764 15.1114 10.5781 15.1106 10.5798 15.1099L10.6511 15.067L10.9414 14.8951L11.3109 14.6755V14.6651L11.3586 14.6365L14.6649 12.6712L14.9194 12.52L14.9448 12.5287C14.9456 12.5287 14.9471 12.5296 14.9479 12.5296C15.0209 12.5478 15.0923 12.5725 15.1604 12.6028C15.3183 12.6712 15.4609 12.7683 15.5831 12.8869C15.6323 12.9339 15.6774 12.9847 15.7194 13.0389C15.7551 13.0842 15.7876 13.132 15.8169 13.182C15.9451 13.3966 16.0189 13.6489 16.0189 13.9178Z" fill="url(#paint5_linear_3145_525)"/>
<path d="M11.3115 7.35889L11.3103 14.6751L10.9408 14.8949L10.6503 15.0666L10.5788 15.1101C10.5777 15.1101 10.5755 15.1113 10.5745 15.1123C10.3752 15.22 10.1475 15.282 9.90466 15.282C9.21216 15.282 8.63883 14.7807 8.52167 14.1195C8.51617 14.089 8.512 14.0574 8.50867 14.027C8.50433 13.9693 8.50117 13.9128 8.5 13.8551V5.62113C8.5 5.36127 8.71033 5.14923 8.97033 5.14923C9.06783 5.14923 9.15883 5.17967 9.23366 5.22966L10.6718 6.17246C10.6795 6.17898 10.688 6.1845 10.6968 6.18985C11.0687 6.44436 11.3115 6.87278 11.3115 7.35889Z" fill="url(#paint6_linear_3145_525)"/>
<path opacity="0.15" d="M16.0189 13.9178C16.0189 14.0101 16.0103 14.0993 15.9943 14.186C15.9894 14.2091 15.9848 14.2322 15.9793 14.2553C15.9689 14.2966 15.9579 14.3364 15.9444 14.3762C15.9373 14.3969 15.9301 14.4175 15.9223 14.4374C15.9143 14.4581 15.9056 14.478 15.8969 14.4986C15.8708 14.5591 15.8398 14.6171 15.8049 14.6728C15.7598 14.7461 15.7083 14.8145 15.6511 14.8782C15.3886 15.1695 14.4971 15.6889 14.1686 15.8999L13.4393 16.347C12.9049 16.6775 12.3996 16.9112 11.7628 16.9271C11.7326 16.928 11.7033 16.9288 11.6739 16.9288C11.6328 16.9288 11.5923 16.928 11.5518 16.9265C10.4733 16.8852 9.53262 16.3042 8.99029 15.4457C8.74213 15.0534 8.57796 14.6031 8.52246 14.1193C8.63896 14.7805 9.21329 15.2818 9.90562 15.2818C10.1483 15.2818 10.376 15.2206 10.5749 15.1123C10.5764 15.1114 10.5781 15.1106 10.5798 15.1099L10.6511 15.067L10.9414 14.8951L11.3109 14.6755V14.6651L11.3586 14.6365L14.6649 12.6712L14.9194 12.52L14.9448 12.5287C14.9456 12.5287 14.9471 12.5296 14.9479 12.5296C15.0209 12.5478 15.0923 12.5725 15.1604 12.6028C15.3183 12.6712 15.4609 12.7683 15.5831 12.8869C15.6323 12.9339 15.6774 12.9847 15.7194 13.0389C15.7551 13.0842 15.7876 13.132 15.8169 13.182C15.9451 13.3966 16.0189 13.6489 16.0189 13.9178Z" fill="url(#paint7_linear_3145_525)"/>
<path opacity="0.1" d="M11.3115 7.35889L11.3103 14.6751L10.9408 14.8949L10.6503 15.0666L10.5788 15.1101C10.5777 15.1101 10.5755 15.1113 10.5745 15.1123C10.3752 15.22 10.1475 15.282 9.90466 15.282C9.21216 15.282 8.63883 14.7807 8.52167 14.1195C8.51617 14.089 8.512 14.0574 8.50867 14.027C8.50433 13.9693 8.50117 13.9128 8.5 13.8551V5.62113C8.5 5.36127 8.71033 5.14923 8.97033 5.14923C9.06783 5.14923 9.15883 5.17967 9.23366 5.22966L10.6718 6.17246C10.6795 6.17898 10.688 6.1845 10.6968 6.18985C11.0687 6.44436 11.3115 6.87278 11.3115 7.35889Z" fill="url(#paint8_linear_3145_525)"/>
</g>
</g>
<defs>
<filter id="filter0_dd_3145_525" x="0" y="0" width="24" height="24" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
<feFlood flood-opacity="0" result="BackgroundImageFix"/>
<feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"/>
<feOffset/>
<feGaussianBlur stdDeviation="0.5"/>
<feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.12 0"/>
<feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow_3145_525"/>
<feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"/>
<feOffset dy="1"/>
<feGaussianBlur stdDeviation="1"/>
<feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.14 0"/>
<feBlend mode="normal" in2="effect1_dropShadow_3145_525" result="effect2_dropShadow_3145_525"/>
<feBlend mode="normal" in="SourceGraphic" in2="effect2_dropShadow_3145_525" result="shape"/>
</filter>
<filter id="filter1_i_3145_525" x="6" y="5" width="12" height="13.5" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
<feFlood flood-opacity="0" result="BackgroundImageFix"/>
<feBlend mode="normal" in="SourceGraphic" in2="BackgroundImageFix" result="shape"/>
<feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"/>
<feOffset dy="1.5"/>
<feGaussianBlur stdDeviation="2.4375"/>
<feComposite in2="hardAlpha" operator="arithmetic" k2="-1" k3="1"/>
<feColorMatrix type="matrix" values="0 0 0 0 0.81875 0 0 0 0 0.824081 0 0 0 0 1 0 0 0 0.37 0"/>
<feBlend mode="normal" in2="shape" result="effect1_innerShadow_3145_525"/>
</filter>
<linearGradient id="paint0_linear_3145_525" x1="12" y1="1" x2="12" y2="21" gradientUnits="userSpaceOnUse">
<stop stop-color="#F9F9F9"/>
<stop offset="1" stop-color="#EDF0F9"/>
</linearGradient>
<linearGradient id="paint1_linear_3145_525" x1="2.07634" y1="24.75" x2="24.5358" y2="21.4401" gradientUnits="userSpaceOnUse">
<stop offset="0.107946" stop-color="#1D6CF2"/>
<stop offset="0.870845" stop-color="#1B4AEF"/>
</linearGradient>
<radialGradient id="paint2_radial_3145_525" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(7.17857 18.8571) rotate(14.0362) scale(17.6705)">
<stop stop-color="#0B31A3"/>
<stop offset="1" stop-color="#39A0ED"/>
</radialGradient>
<radialGradient id="paint3_radial_3145_525" cx="0" cy="0" r="1" gradientUnits="userSpaceOnUse" gradientTransform="translate(8.78571 8.14286) rotate(-140.774) scale(11.2953)">
<stop stop-color="#00FFF3" stop-opacity="0.77"/>
<stop offset="0.423394" stop-color="#00FFF3" stop-opacity="0.72"/>
<stop offset="1" stop-color="#5BDCD6" stop-opacity="0"/>
</radialGradient>
<linearGradient id="paint4_linear_3145_525" x1="11.5407" y1="10.2478" x2="16.7004" y2="13.2169" gradientUnits="userSpaceOnUse">
<stop stop-color="#37BDFF"/>
<stop offset="0.1832" stop-color="#33BFFD"/>
<stop offset="0.3576" stop-color="#28C5F5"/>
<stop offset="0.528" stop-color="#15D0E9"/>
<stop offset="0.5468" stop-color="#12D1E7"/>
<stop offset="0.5903" stop-color="#1CD2E5"/>
<stop offset="0.7679" stop-color="#42D8DC"/>
<stop offset="0.9107" stop-color="#59DBD6"/>
<stop offset="1" stop-color="#62DCD4"/>
</linearGradient>
<linearGradient id="paint5_linear_3145_525" x1="8.52213" y1="14.7243" x2="16.0189" y2="14.7243" gradientUnits="userSpaceOnUse">
<stop stop-color="#39D2FF"/>
<stop offset="0.1501" stop-color="#38CEFE"/>
<stop offset="0.2931" stop-color="#35C3FA"/>
<stop offset="0.4327" stop-color="#2FB0F3"/>
<stop offset="0.5468" stop-color="#299AEB"/>
<stop offset="0.5827" stop-color="#2692EC"/>
<stop offset="0.7635" stop-color="#1A6CF1"/>
<stop offset="0.909" stop-color="#1355F4"/>
<stop offset="1" stop-color="#104CF5"/>
</linearGradient>
<linearGradient id="paint6_linear_3145_525" x1="9.90572" y1="15.3854" x2="9.90572" y2="5.32767" gradientUnits="userSpaceOnUse">
<stop stop-color="#1B48EF"/>
<stop offset="0.1221" stop-color="#1C51F0"/>
<stop offset="0.3212" stop-color="#1E69F5"/>
<stop offset="0.5676" stop-color="#2190FB"/>
<stop offset="1" stop-color="#26B8F4"/>
</linearGradient>
<linearGradient id="paint7_linear_3145_525" x1="10.0122" y1="16.5806" x2="14.654" y2="11.9543" gradientUnits="userSpaceOnUse">
<stop stop-color="white"/>
<stop offset="0.3726" stop-color="#FDFDFD"/>
<stop offset="0.5069" stop-color="#F6F6F6"/>
<stop offset="0.6026" stop-color="#EBEBEB"/>
<stop offset="0.68" stop-color="#DADADA"/>
<stop offset="0.7463" stop-color="#C4C4C4"/>
<stop offset="0.805" stop-color="#A8A8A8"/>
<stop offset="0.8581" stop-color="#888888"/>
<stop offset="0.9069" stop-color="#626262"/>
<stop offset="0.9523" stop-color="#373737"/>
<stop offset="0.9926" stop-color="#090909"/>
<stop offset="1"/>
</linearGradient>
<linearGradient id="paint8_linear_3145_525" x1="9.90572" y1="5.14923" x2="9.90572" y2="15.2819" gradientUnits="userSpaceOnUse">
<stop stop-color="white"/>
<stop offset="0.3726" stop-color="#FDFDFD"/>
<stop offset="0.5069" stop-color="#F6F6F6"/>
<stop offset="0.6026" stop-color="#EBEBEB"/>
<stop offset="0.68" stop-color="#DADADA"/>
<stop offset="0.7463" stop-color="#C4C4C4"/>
<stop offset="0.805" stop-color="#A8A8A8"/>
<stop offset="0.8581" stop-color="#888888"/>
<stop offset="0.9069" stop-color="#626262"/>
<stop offset="0.9523" stop-color="#373737"/>
<stop offset="0.9926" stop-color="#090909"/>
<stop offset="1"/>
</linearGradient>
<clipPath id="clip0_3145_525">
<rect width="8" height="12" fill="white" transform="translate(8.5 5)"/>
</clipPath>
</defs>
</svg>
`}getGrayArrow(){return n.Z.getTrustedHTML`
<svg aria-hidden="true" width="9" height="8" viewBox="0 0 9 8" fill="none" xmlns="http://www.w3.org/2000/svg">
<path id="grayArrow" d="M0.5 3.5C0.223858 3.5 0 3.72386 0 4C0 4.27614 0.223858 4.5 0.5 4.5V3.5ZM8.85355 4.35355C9.04882 4.15829 9.04882 3.84171 8.85355 3.64645L5.67157 0.464466C5.47631 0.269204 5.15973 0.269204 4.96447 0.464466C4.7692 0.659728 4.7692 0.976311 4.96447 1.17157L7.79289 4L4.96447 6.82843C4.7692 7.02369 4.7692 7.34027 4.96447 7.53553C5.15973 7.7308 5.47631 7.7308 5.67157 7.53553L8.85355 4.35355ZM0.5 4.5H8.5V3.5H0.5V4.5Z" fill="#6D6D6D" />
</svg>
`}getCopyIcon(){return n.Z.getTrustedHTML`
<svg id="copy-icon" width="11" height="12" viewBox="0 0 11 12" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M1.50029 2.08525L1.5 8.5C1.5 9.82548 2.53154 10.91 3.83562 10.9947L4 11L8.4144 11.0007C8.20828 11.5829 7.65285 12 7 12H3.5C1.84315 12 0.5 10.6569 0.5 9V3.5C0.5 2.84678 0.917543 2.29109 1.50029 2.08525ZM9 0C9.82843 0 10.5 0.671573 10.5 1.5V8.5C10.5 9.32843 9.82843 10 9 10H4C3.17157 10 2.5 9.32843 2.5 8.5V1.5C2.5 0.671573 3.17157 0 4 0H9ZM9 1H4C3.72386 1 3.5 1.22386 3.5 1.5V8.5C3.5 8.77614 3.72386 9 4 9H9C9.27614 9 9.5 8.77614 9.5 8.5V1.5C9.5 1.22386 9.27614 1 9 1Z"/>
</svg>
`}getBlueCheckCircle(){return n.Z.getTrustedHTML`
<svg id="blue-check-icon" width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M6 0C9.31371 0 12 2.68629 12 6C12 9.31371 9.31371 12 6 12C2.68629 12 0 9.31371 0 6C0 2.68629 2.68629 0 6 0ZM6 1C3.23858 1 1 3.23858 1 6C1 8.76142 3.23858 11 6 11C8.76142 11 11 8.76142 11 6C11 3.23858 8.76142 1 6 1ZM5.24953 7.04242L8.12028 4.16398C8.31528 3.96846 8.63186 3.96803 8.82738 4.16304C9.00118 4.33637 9.02083 4.60577 8.88609 4.80082L8.82833 4.87014L5.60403 8.10308C5.43053 8.27704 5.16082 8.29654 4.96576 8.16146L4.89645 8.10355L3.14645 6.35355C2.95118 6.15829 2.95118 5.84171 3.14645 5.64645C3.32001 5.47288 3.58944 5.4536 3.78431 5.58859L3.85355 5.64645L5.24953 7.04242L8.12028 4.16398L5.24953 7.04242Z"/>
</svg>
`}getBlueBellIcon(){return n.Z.getTrustedHTML`
<svg width="14" height="16" viewBox="0 0 14 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M9.44986 14.0016C9.21763 15.1419 8.20912 16 7.00019 16C5.79126 16 4.78275 15.1419 4.55052 14.0016H9.44986ZM6.99783 0C10.1468 0 12.7417 2.33488 12.9823 5.3554L12.9957 5.57762L13.0002 5.80214L12.9992 9.408L13.9529 11.9951L13.9786 12.0796L13.994 12.1664L13.9992 12.2546C13.9992 12.5697 13.8035 12.845 13.4773 12.9618L13.3638 12.9947L13.2492 13.0046H0.751544C0.663047 13.0046 0.575248 12.9889 0.49221 12.9583C0.205309 12.8526 0.0165467 12.5865 0.00976562 12.2422L0.0143604 12.1247L0.0478067 11.9952L0.99919 9.411L1.00028 5.79281L1.00458 5.56824C1.12719 2.45115 3.77122 0 6.99783 0Z" fill="#2169EB"/>
</svg>
`}getMicrosoftLogo(){return n.Z.getTrustedHTML`<svg version="1.1" id="MS-symbol" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 215.25 216" style="enable-background:new 0 0 215.25 216;" xml:space="preserve"><style type="text/css">
.st0{fill:#F25022;} .st1{fill:#7FBA00;} .st2{fill:#00A4EF;} .st3{fill:#FFB900;}</style><g><rect x="72" y="72" class="st0" width="34.22" height="34.22"/><rect x="109.77" y="72" class="st1" width="34.22" height="34.22"/><rect x="72" y="109.77" class="st2" width="34.22" height="34.22"/><rect x="109.77" y="109.77" class="st3" width="34.22" height="34.22"/></g></svg>`}getShoprunnerMSLogo(){return n.Z.getTrustedHTML`
<svg width="180" height="16" viewBox="0 0 180 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_3762_26326)">
<path class="shoprunner-logo" d="M21.68 3.65321C20.1083 3.65321 18.7866 4.43474 18.7866 5.94322C18.7866 7.4517 19.9445 7.99188 21.022 8.17864L22.0449 8.35966C22.8983 8.50907 23.6798 8.81364 23.6798 9.69574C23.6798 10.5778 22.9931 11.1266 21.8036 11.1266C20.614 11.1266 19.7089 10.5865 19.6313 9.27336H18.5366C18.5912 11.2186 20.1227 12.0863 21.7978 12.0863C23.4729 12.0863 24.7515 11.21 24.7515 9.68712C24.7515 8.16427 23.6022 7.61547 22.4127 7.41147L21.3898 7.23045C20.5767 7.08966 19.8583 6.78509 19.8583 5.93173C19.8583 5.07836 20.5709 4.61001 21.6714 4.61001C22.7719 4.61001 23.5247 5.07261 23.5879 6.12711H24.6826C24.6136 4.43762 23.2517 3.64746 21.68 3.64746V3.65321Z" fill="black"/>
<path class="shoprunner-logo" d="M26.8485 11.9252V8.25031H30.4458V11.9252H31.5233V3.82544H30.4458V7.28201H26.8485V3.82544H25.771V11.9252H26.8485Z" fill="black"/>
<path class="shoprunner-logo" d="M36.6674 3.65308C34.205 3.65308 32.4839 5.34257 32.4839 7.87394C32.4839 10.4053 34.205 12.0948 36.6674 12.0948C39.1298 12.0948 40.8509 10.4053 40.8509 7.87394C40.8509 5.34257 39.1298 3.65308 36.6674 3.65308ZM36.6674 4.61563C38.4115 4.61563 39.7619 5.81092 39.7619 7.87681C39.7619 9.94271 38.4086 11.138 36.6674 11.138C34.8141 11.138 33.5729 9.94271 33.5729 7.87681C33.5815 5.81379 34.817 4.61563 36.6674 4.61563Z" fill="black"/>
<path class="shoprunner-logo" d="M42.8988 11.9252V8.43701H44.979C46.4961 8.43701 47.5133 7.59227 47.5133 6.12976C47.5133 4.66726 46.5047 3.82251 44.979 3.82251H41.8213V11.9223H42.8988V11.9252ZM42.8988 4.79368H44.8698C45.8554 4.79368 46.4329 5.20169 46.4329 6.12976C46.4329 7.05783 45.8554 7.46584 44.8698 7.46584H42.8988V4.79081V4.79368Z" fill="black"/>
<path class="shoprunner-logo" d="M54.1018 6.18728C54.1018 4.61559 53.03 3.82544 51.513 3.82544H48.292V11.9252H49.3695V8.54625H51.1366L52.6134 11.9252H53.7081V11.6983L52.2313 8.48592C53.3662 8.26755 54.0989 7.50038 54.0989 6.18728H54.1018ZM51.4038 4.79661C52.4439 4.79661 53.0214 5.20462 53.0214 6.18728C53.0214 7.16995 52.4439 7.57796 51.4038 7.57796H49.3781V4.78799H51.4038V4.79661Z" fill="black"/>
<path class="shoprunner-logo" d="M55.0249 9.43985C55.0249 11.2155 56.0334 12.0747 57.8637 12.0747C59.694 12.0747 60.7025 11.2155 60.7025 9.43985V3.82544H59.6222V9.38238C59.6222 10.7357 58.8809 11.1035 57.8695 11.1035C56.8581 11.1035 56.1196 10.7357 56.1196 9.38238V3.82544H55.0421V9.43985H55.0278H55.0249Z" fill="black"/>
<path class="shoprunner-logo" d="M63.179 11.9252V4.98338C63.179 4.92878 63.202 4.88856 63.2566 4.88856C63.3112 4.88856 63.3514 4.89718 63.3658 4.95752L65.9546 11.9224H67.9257V3.82544H66.8453V10.7673C66.8453 10.8219 66.8223 10.8621 66.7677 10.8621C66.7131 10.8621 66.6729 10.8535 66.6585 10.7903L64.0697 3.82544H62.0986V11.9252H63.1761H63.179Z" fill="black"/>
<path class="shoprunner-logo" d="M70.4658 11.9252V4.98338C70.4658 4.92878 70.4888 4.88856 70.5434 4.88856C70.598 4.88856 70.6382 4.89718 70.6525 4.95752L73.2471 11.9224H75.2182V3.82544H74.1407V10.7673C74.1407 10.8219 74.1177 10.8621 74.0631 10.8621C74.0085 10.8621 73.9683 10.8535 73.954 10.7903L71.3651 3.82544H69.394V11.9252H70.4658Z" fill="black"/>
<path class="shoprunner-logo" d="M81.864 11.9252V10.9569H77.7581V8.18991H81.4158V7.22161H77.7581V4.79081H81.8066V3.82251H76.6777V11.9309H81.8612L81.864 11.9252Z" fill="black"/>
<path class="shoprunner-logo" d="M88.6741 6.18728C88.6741 4.61559 87.6023 3.82544 86.0852 3.82544H82.8643V11.9252H83.9417V8.54625H85.7088L87.1857 11.9252H88.2804V11.6983L86.8035 8.48592C87.9385 8.26755 88.6712 7.50038 88.6712 6.18728H88.6741ZM85.976 4.79661C87.0162 4.79661 87.5937 5.20462 87.5937 6.18728C87.5937 7.16995 87.0162 7.57796 85.976 7.57796H83.9504V4.78799H85.976V4.79661Z" fill="black"/>
<path class="shoprunner-logo" d="M2.95765 9.3134L7.27907 3.04963C7.39687 2.87723 7.67845 2.98642 7.63823 3.19042L6.99748 6.66997C6.9745 6.80215 7.11529 6.91133 7.24746 6.85099L12.0631 4.57535C12.1953 4.51213 12.2585 4.36272 12.2183 4.23055C11.4942 1.98652 9.14958 -0.053521 6.34237 0.00107135C3.0812 0.055664 0.828538 2.52669 0.682 5.1931C0.587182 6.77341 1.32274 8.17845 2.61285 9.35075C2.71342 9.44557 2.88007 9.41971 2.95765 9.31053V9.3134ZM10.0949 6.40563L5.77059 12.6751C5.65278 12.8475 5.3712 12.7384 5.41143 12.5344L6.04355 9.04619C6.06654 8.91401 5.92575 8.80483 5.79357 8.86804L0.97795 11.1437C0.845778 11.2069 0.782566 11.3534 0.822792 11.4885C1.54111 13.7325 3.89433 15.7726 6.70153 15.718C9.96272 15.6634 12.2211 13.1923 12.3705 10.5259C12.4654 8.94562 11.7212 7.54058 10.4397 6.36828C10.3391 6.27346 10.1725 6.29932 10.0949 6.40851V6.40563Z" fill="black"/>
<path id="plus-icon" d="M104.064 8.21094H101.057V11.2188H99.4785V8.21094H96.4551V6.625H99.4785V3.60156H101.057V6.625H104.064V8.21094Z" fill="#707070"/>
<path id="MS-logo" d="M139.589 3.1577V11.8571H138.079V5.03854H138.055L135.354 11.8571H134.353L131.586 5.03854H131.568V11.8571H130.173V3.1577H132.338L134.837 9.6057H134.873L137.511 3.1577H139.585H139.589ZM140.852 3.81821C140.852 3.57455 140.94 3.37317 141.116 3.20805C141.291 3.04493 141.5 2.96237 141.744 2.96237C142.004 2.96237 142.217 3.04695 142.386 3.21409C142.555 3.38123 142.64 3.5826 142.64 3.81821C142.64 4.05382 142.553 4.25721 142.38 4.41831C142.207 4.57941 141.994 4.66197 141.744 4.66197C141.494 4.66197 141.283 4.57941 141.109 4.41629C140.938 4.25318 140.852 4.05382 140.852 3.81821ZM142.471 11.8571H141.003V5.62051H142.471V11.8571ZM146.923 10.7898C147.141 10.7898 147.382 10.7394 147.644 10.6388C147.908 10.5381 148.15 10.4052 148.371 10.238V11.6033C148.137 11.7362 147.872 11.8369 147.574 11.9074C147.276 11.9759 146.949 12.0101 146.595 12.0101C145.677 12.0101 144.932 11.7201 144.356 11.1402C143.782 10.5602 143.494 9.81916 143.494 8.917C143.494 7.91416 143.788 7.08853 144.374 6.43809C144.96 5.78966 145.791 5.46344 146.867 5.46344C147.143 5.46344 147.421 5.49969 147.7 5.57017C147.982 5.64065 148.204 5.72321 148.371 5.81584V7.22345C148.145 7.05832 147.914 6.92944 147.676 6.83882C147.439 6.7482 147.197 6.70189 146.951 6.70189C146.373 6.70189 145.906 6.89118 145.55 7.26574C145.193 7.64231 145.016 8.14977 145.016 8.78813C145.016 9.42648 145.187 9.90978 145.53 10.2622C145.872 10.6146 146.335 10.7898 146.921 10.7898M152.552 5.51781C152.668 5.51781 152.775 5.52586 152.868 5.54197C152.96 5.55808 153.041 5.57822 153.105 5.60239V7.08853C153.029 7.03214 152.916 6.97777 152.769 6.92743C152.622 6.87708 152.443 6.85091 152.231 6.85091C151.871 6.85091 151.567 7.00194 151.319 7.30601C151.069 7.61009 150.947 8.07727 150.947 8.70758V11.8571H149.479V5.62051H150.947V6.60322H150.971C151.104 6.26289 151.307 5.99708 151.577 5.80577C151.847 5.61447 152.173 5.51781 152.554 5.51781M153.186 8.83041C153.186 7.79938 153.476 6.9818 154.06 6.37969C154.642 5.77758 155.451 5.47552 156.486 5.47552C157.461 5.47552 158.222 5.7655 158.77 6.34546C159.318 6.92541 159.592 7.70876 159.592 8.69751C159.592 9.68625 159.3 10.5139 158.718 11.112C158.136 11.7101 157.342 12.0101 156.339 12.0101C155.337 12.0101 154.606 11.7262 154.038 11.1583C153.47 10.5904 153.186 9.81513 153.186 8.83243M154.714 8.7841C154.714 9.43655 154.861 9.93394 155.157 10.2763C155.451 10.6206 155.874 10.7918 156.426 10.7918C156.978 10.7918 157.366 10.6206 157.644 10.2763C157.924 9.93193 158.063 9.42245 158.063 8.74785C158.063 8.07325 157.918 7.56981 157.63 7.22748C157.342 6.88514 156.935 6.71397 156.414 6.71397C155.892 6.71397 155.459 6.89319 155.161 7.25164C154.863 7.61009 154.716 8.11956 154.716 8.7841M161.777 7.26171C161.777 7.47315 161.843 7.63627 161.976 7.75709C162.109 7.8759 162.405 8.02693 162.862 8.20817C163.448 8.44378 163.861 8.70758 164.096 8.99957C164.334 9.29357 164.451 9.64799 164.451 10.0648C164.451 10.6508 164.225 11.1221 163.774 11.4785C163.323 11.8349 162.713 12.0121 161.946 12.0121C161.686 12.0121 161.4 11.9819 161.088 11.9175C160.774 11.8551 160.508 11.7745 160.29 11.6778V10.234C160.556 10.4193 160.844 10.5683 161.152 10.677C161.46 10.7858 161.738 10.8401 161.99 10.8401C162.322 10.8401 162.566 10.7938 162.723 10.7012C162.88 10.6085 162.959 10.4515 162.959 10.234C162.959 10.0326 162.876 9.86145 162.713 9.72049C162.55 9.58154 162.24 9.42044 161.783 9.23719C161.241 9.00964 160.856 8.75591 160.631 8.47197C160.405 8.18803 160.29 7.82958 160.29 7.3926C160.29 6.83077 160.514 6.36761 160.961 6.00715C161.408 5.64467 161.988 5.46344 162.699 5.46344C162.916 5.46344 163.162 5.4876 163.434 5.53593C163.704 5.58426 163.931 5.64669 164.112 5.72522V7.12075C163.919 6.99187 163.692 6.8791 163.434 6.78647C163.174 6.69383 162.918 6.64752 162.663 6.64752C162.383 6.64752 162.167 6.70189 162.01 6.81063C161.855 6.91937 161.777 7.0704 161.777 7.2597M165.083 8.83041C165.083 7.79938 165.375 6.9818 165.957 6.37969C166.539 5.77758 167.349 5.47552 168.384 5.47552C169.358 5.47552 170.119 5.7655 170.667 6.34546C171.215 6.92541 171.489 7.70876 171.489 8.69751C171.489 9.68625 171.197 10.5139 170.615 11.112C170.033 11.7101 169.239 12.0101 168.237 12.0101C167.234 12.0101 166.503 11.7262 165.935 11.1583C165.367 10.5904 165.083 9.81513 165.083 8.83243M166.612 8.7841C166.612 9.43655 166.759 9.93394 167.055 10.2763C167.351 10.6206 167.771 10.7918 168.323 10.7918C168.875 10.7918 169.264 10.6206 169.544 10.2763C169.823 9.93193 169.962 9.42245 169.962 8.74785C169.962 8.07325 169.817 7.56981 169.529 7.22748C169.239 6.88514 168.835 6.71397 168.313 6.71397C167.792 6.71397 167.359 6.89319 167.061 7.25164C166.763 7.61009 166.616 8.11956 166.616 8.7841M176.364 6.82473H174.177V11.8611H172.691V6.82473H171.648V5.62454H172.691V4.75661C172.691 4.10215 172.904 3.56448 173.331 3.14562C173.758 2.72676 174.304 2.51733 174.973 2.51733C175.15 2.51733 175.309 2.5274 175.446 2.54553C175.583 2.56365 175.706 2.59184 175.81 2.62809V3.89675C175.762 3.86855 175.677 3.83432 175.555 3.79405C175.434 3.75377 175.295 3.73363 175.136 3.73363C174.828 3.73363 174.592 3.83029 174.427 4.0216C174.262 4.2129 174.179 4.49886 174.179 4.87341V5.62655H176.366V4.22499L177.84 3.77592V5.62655H179.326V6.82674H177.84V9.74465C177.84 10.1293 177.911 10.3991 178.05 10.5582C178.189 10.7153 178.408 10.7958 178.708 10.7958C178.793 10.7958 178.895 10.7757 179.014 10.7354C179.133 10.6951 179.238 10.6468 179.326 10.5904V11.8047C179.234 11.8571 179.079 11.9054 178.861 11.9497C178.646 11.994 178.432 12.0162 178.221 12.0162C177.603 12.0162 177.137 11.851 176.829 11.5228C176.519 11.1925 176.366 10.6972 176.366 10.0326V6.82875L176.364 6.82473Z" fill="#636363"/>
<path d="M119.565 0H112.674V6.89102H119.565V0Z" fill="#F25022"/>
<path d="M127.173 0H120.282V6.89102H127.173V0Z" fill="#7FBA00"/>
<path d="M119.565 7.60791H112.674V14.4989H119.565V7.60791Z" fill="#00A4EF"/>
<path d="M127.173 7.60791H120.282V14.4989H127.173V7.60791Z" fill="#FFB900"/>
</g>
<defs>
<clipPath id="clip0_3762_26326">
<rect width="178.652" height="15.719" fill="white" transform="translate(0.673828)"/>
</clipPath>
</defs>
</svg>
`}}},63173:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(){(0,n.Z)(this,"negativeEngagementCount",void 0)}}},21650:function(e,t,i){"use strict";var n=i(72370);class o{constructor(){(0,n.Z)(this,"boolValue",void 0)}static Create(e){const t=new o;return t.boolValue=e.boolValue,t}static CreateFromBool(e){const t=new o;return t.boolValue=e,t}}t.Z=o},96834:function(e,t,i){"use strict";var n=i(72370);class o{constructor(){(0,n.Z)(this,"stringValue",void 0)}static Create(e){const t=new o;return t.stringValue=e.stringValue,t}static CreateFromString(e){const t=new o;return t.stringValue=e,t}}t.Z=o},28060:function(e,t,i){"use strict";i.d(t,{E:function(){return n}});let n=function(e){return e.ICNotification="icnotification",e}({})},4724:function(e,t,i){"use strict";var n=i(72370),o=i(47746);class r{constructor(){(0,n.Z)(this,"displayCategory",void 0),(0,n.Z)(this,"image",void 0),(0,n.Z)(this,"price",void 0),(0,n.Z)(this,"productId",void 0),(0,n.Z)(this,"retailerIdentifier",void 0),(0,n.Z)(this,"title",void 0),(0,n.Z)(this,"upc",void 0),(0,n.Z)(this,"url",void 0),(0,n.Z)(this,"discountedPrice",void 0),(0,n.Z)(this,"productReviewsCount",void 0),(0,n.Z)(this,"productRatings",void 0),(0,n.Z)(this,"productShortTitle",void 0),(0,n.Z)(this,"variation",void 0)}static Create(e){const t=new r;return t.displayCategory=e.displayCategory,t.image=e.image,t.price=e.price,t.productId=e.productId,t.retailerIdentifier=e.retailerIdentifier,t.title=e.title,t.productShortTitle=e.productShortTitle,t.upc=e.upc,t.url=e.url,t.productRatings=e.productRatings,t.productReviewsCount=e.productReviewsCount,t.variation=e.variation,t}static CreateFromGroceryApi(e){const t=new r;return t.displayCategory=e.productDisplayCategory,t.image=e.productImage,t.price=e.productPrice,t.productId=e.productGTIN,t.productShortTitle=e.productShortTitle,t.retailerIdentifier=e.retailerIdentifier,t.title=e.productTitle,t.upc=e.productUPC,t.url=e.productURL,t.productRatings=e.prodcutRatings,t.productReviewsCount=e.productReviewsCount,t.variation=e.variation,t}static CreateFromUAPI(e){const t=new r;return t.displayCategory=e.displayCategory,t.image=e.image,t.price=e.price,t.productId=e.productId,t.retailerIdentifier="",t.title=e.title,t.productShortTitle=e.productShortTitle,t.upc=e.upc,t.url=e.url,t.productRatings=e.productRatings,t.productReviewsCount=e.productReviewsCount,t.productReviewsCount=e.variation,t}static CreateOneItemOffer(e){const t=r.CreateFromUAPI(e),i=new o.Z;return i.cashbackProducts.push(t),i}static CreateFromAdsOffer(e,t){const i=new r;return i.displayCategory="",i.image=t,i.price=`$${e.price}`,i.productId="",i.retailerIdentifier="",i.title=e.name??"",i.upc="",i.url=e.url??"",i.discountedPrice=e.discountedPrice?`$${e.discountedPrice.toFixed(2)}`:"",i}}t.Z=r},47746:function(e,t,i){"use strict";var n=i(72370),o=i(4724);class r{static Create(e){const t=new r;if(t.cashbackProducts=[],e.cashbackProducts)for(const i of e.cashbackProducts)t.cashbackProducts.push(o.Z.Create(i));return t.imageUrl=e.imageUrl,t.offerValue=e.value,t.id=e.id,t.description=e.description,t.brand=e.brand,t.disclaimer=e.disclaimer,t.expiryDate=e.expiryDate,t.minQty=e.minQty,t.source=e.source,t}static CreateFromGroceryApi(e){const t=new r;return t.imageUrl=e.offerImage.offerImage1,t.offerValue=e.offerValue,t.id=e.offerId,t.description=e.offerDescription,t.brand=e.brandName,t.disclaimer=e.offerDisclaimer,t.expiryDate=e.offerExpiryDate,t.minQty=e.requirements.minQty,t.cashbackProducts=e.edgeRebateOfferProducts.map((e=>o.Z.CreateFromGroceryApi(e))),t}static CreateFromUAPI(e){const t=new r;return t.imageUrl=e.imageUrl,t.offerValue=e.value,t.id=e.id,t.description=e.description,t.brand=e.brand,t.disclaimer="",t.expiryDate=e.expiryDate,t.minQty=e.minQty,t.source=e.source,t.cashbackProducts=e.cashbackProducts.map((e=>o.Z.CreateFromUAPI(e))),t}static CreateFromUAPIList(e){const t=[];return e.forEach((e=>{const i=new r;i.imageUrl=e.imageUrl,i.offerValue=e.value,i.id=e.id,i.description=e.description,i.brand=e.brand,i.disclaimer="",i.expiryDate=e.expiryDate,i.minQty=e.minQty,i.source=e.source,i.cashbackProducts=e.cashbackProducts.map((e=>o.Z.CreateFromUAPI(e))),t.push(i)})),t}constructor(){(0,n.Z)(this,"imageUrl",void 0),(0,n.Z)(this,"offerValue",void 0),(0,n.Z)(this,"id",void 0),(0,n.Z)(this,"description",void 0),(0,n.Z)(this,"brand",void 0),(0,n.Z)(this,"disclaimer",void 0),(0,n.Z)(this,"expiryDate",void 0),(0,n.Z)(this,"minQty",void 0),(0,n.Z)(this,"source",void 0),(0,n.Z)(this,"cashbackProducts",void 0),(0,n.Z)(this,"addedTimestamp",void 0),(0,n.Z)(this,"expAfterActivatingDate",void 0),(0,n.Z)(this,"quotientTimestamp",void 0),this.cashbackProducts=[]}}t.Z=r},31725:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(e,t,i,o,r,a,s,l){(0,n.Z)(this,"shouldAutoshow",void 0),(0,n.Z)(this,"renderedPageType",void 0),(0,n.Z)(this,"cashBackOffersTypeTitle",void 0),(0,n.Z)(this,"cashbackItemsFromSearchAndCategory",void 0),(0,n.Z)(this,"useCategoryFiltering",void 0),(0,n.Z)(this,"requestTraceId",void 0),(0,n.Z)(this,"isRecentlyViewedSpbEnabled",!1),(0,n.Z)(this,"searchQuery",""),(0,n.Z)(this,"categoryName",""),this.shouldAutoshow=e,this.renderedPageType=t,this.cashBackOffersTypeTitle=i,this.cashbackItemsFromSearchAndCategory=o,this.useCategoryFiltering=r,this.requestTraceId=a,this.searchQuery=s?i:"",this.categoryName=l?i:""}}},55646:function(e,t,i){"use strict";i.r(t);const n=Object.freeze({prefix:"commerceui",shadowRootMode:"open",registry:customElements});var o=i(85866);let r;const a="fast-kernel";try{if(document.currentScript)r=document.currentScript.getAttribute(a);else{const e=document.getElementsByTagName("script");r=e[e.length-1].getAttribute(a)}}catch(e){r="isolate"}let s;switch(r){case"share":s=Object.freeze({updateQueue:1,observable:2,contextEvent:3,elementRegistry:4});break;case"share-v2":s=Object.freeze({updateQueue:1.2,observable:2.2,contextEvent:3.2,elementRegistry:4.2});break;default:const e=`-${Math.random().toString(36).substring(2,8)}`;s=Object.freeze({updateQueue:`1.2${e}`,observable:`2.2${e}`,contextEvent:`3.2${e}`,elementRegistry:`4.2${e}`})}const l=e=>"function"==typeof e,c=e=>"string"==typeof e,d=()=>{};class u{constructor(e,t){this.sub1=void 0,this.sub2=void 0,this.spillover=void 0,this.subject=e,this.sub1=t}has(e){return void 0===this.spillover?this.sub1===e||this.sub2===e:-1!==this.spillover.indexOf(e)}subscribe(e){const t=this.spillover;if(void 0===t){if(this.has(e))return;if(void 0===this.sub1)return void(this.sub1=e);if(void 0===this.sub2)return void(this.sub2=e);this.spillover=[this.sub1,this.sub2,e],this.sub1=void 0,this.sub2=void 0}else-1===t.indexOf(e)&&t.push(e)}unsubscribe(e){const t=this.spillover;if(void 0===t)this.sub1===e?this.sub1=void 0:this.sub2===e&&(this.sub2=void 0);else{const i=t.indexOf(e);-1!==i&&t.splice(i,1)}}notify(e){const t=this.spillover,i=this.subject;if(void 0===t){const t=this.sub1,n=this.sub2;void 0!==t&&t.handleChange(i,e),void 0!==n&&n.handleChange(i,e)}else for(let n=0,o=t.length;n<o;++n)t[n].handleChange(i,e)}}class h{constructor(e){this.subscribers={},this.subjectSubscribers=null,this.subject=e}notify(e){var t,i;null===(t=this.subscribers[e])||void 0===t||t.notify(e),null===(i=this.subjectSubscribers)||void 0===i||i.notify(e)}subscribe(e,t){var i,n;let o;o=t?null!==(i=this.subscribers[t])&&void 0!==i?i:this.subscribers[t]=new u(this.subject):null!==(n=this.subjectSubscribers)&&void 0!==n?n:this.subjectSubscribers=new u(this.subject),o.subscribe(e)}unsubscribe(e,t){var i,n;t?null===(i=this.subscribers[t])||void 0===i||i.unsubscribe(e):null===(n=this.subjectSubscribers)||void 0===n||n.unsubscribe(e)}}!function(){if("undefined"==typeof globalThis)if("undefined"!=typeof global)global.globalThis=global;else if("undefined"!=typeof self)self.globalThis=self;else if("undefined"!=typeof window)window.globalThis=window;else{const e=new Function("return this")();e.globalThis=e}}();const p={configurable:!1,enumerable:!1,writable:!1};void 0===globalThis.FAST&&Reflect.defineProperty(globalThis,"FAST",Object.assign({value:Object.create(null)},p));const g=globalThis.FAST;if(void 0===g.getById){const e=Object.create(null);Reflect.defineProperty(g,"getById",Object.assign({value(t,i){let n=e[t];return void 0===n&&(n=i?e[t]=i():null),n}},p))}void 0===g.error&&Object.assign(g,{warn(){},error(e){return new Error(`Error ${e}`)},addMessages(){}});const f=Object.freeze([]);function m(){const e=new Map;return Object.freeze({register(t){return!e.has(t.type)&&(e.set(t.type,t),!0)},getByType(t){return e.get(t)},getForInstance(t){if(null!=t)return e.get(t.constructor)}})}function v(){const e=new WeakMap;return function(t){let i=e.get(t);if(void 0===i){let n=Reflect.getPrototypeOf(t);for(;void 0===i&&null!==n;)i=e.get(n),n=Reflect.getPrototypeOf(n);i=void 0===i?[]:i.slice(0),e.set(t,i)}return i}}function y(e){e.prototype.toJSON=d}const C=g.getById(s.updateQueue,(()=>{const e=[],t=[],i=globalThis.requestAnimationFrame;let n=!0;function o(){if(t.length)throw t.shift()}function r(i){try{i.call()}catch(i){if(!n)throw e.length=0,i;t.push(i),setTimeout(o,0)}}function a(){let t=0;for(;t<e.length;)if(r(e[t]),t++,t>1024){for(let i=0,n=e.length-t;i<n;i++)e[i]=e[i+t];e.length-=t,t=0}e.length=0}function s(t){e.push(t),e.length<2&&(n?i(a):a())}return Object.freeze({enqueue:s,next:()=>new Promise(s),process:a,setMode:e=>n=e})})),b=Object.freeze({unknown:void 0,coupled:1}),S=g.getById(s.observable,(()=>{const e=C.enqueue,t=/(:|&&|\|\||if|\?\.)/,i=new WeakMap;let n,o=e=>{throw g.error(1101)};function r(e){var t;let n=null!==(t=e.$fastController)&&void 0!==t?t:i.get(e);return void 0===n&&(Array.isArray(e)?n=o(e):i.set(e,n=new h(e))),n}const a=v();class s{constructor(e){this.name=e,this.field=`_${e}`,this.callback=`${e}Changed`}getValue(e){return void 0!==n&&n.watch(e,this.name),e[this.field]}setValue(e,t){const i=this.field,n=e[i];if(n!==t){e[i]=t;const o=e[this.callback];l(o)&&o.call(e,n,t),r(e).notify(this.name)}}}class d extends u{constructor(e,t,i=!1){super(e,t),this.expression=e,this.isVolatileBinding=i,this.needsRefresh=!0,this.needsQueue=!0,this.isAsync=!0,this.first=this,this.last=null,this.propertySource=void 0,this.propertyName=void 0,this.notifier=void 0,this.next=void 0}setMode(e){this.isAsync=this.needsQueue=e}bind(e){this.controller=e;const t=this.observe(e.source,e.context);return!e.isBound&&this.requiresUnbind(e)&&e.onUnbind(this),t}requiresUnbind(e){return e.sourceLifetime!==b.coupled||this.first!==this.last||this.first.propertySource!==e.source}unbind(e){this.dispose()}observe(e,t){this.needsRefresh&&null!==this.last&&this.dispose();const i=n;let o;n=this.needsRefresh?this:void 0,this.needsRefresh=this.isVolatileBinding;try{o=this.expression(e,t)}finally{n=i}return o}disconnect(){this.dispose()}dispose(){if(null!==this.last){let e=this.first;for(;void 0!==e;)e.notifier.unsubscribe(this,e.propertyName),e=e.next;this.last=null,this.needsRefresh=this.needsQueue=this.isAsync}}watch(e,t){const i=this.last,o=r(e),a=null===i?this.first:{};if(a.propertySource=e,a.propertyName=t,a.notifier=o,o.subscribe(this,t),null!==i){if(!this.needsRefresh){let t;n=void 0,t=i.propertySource[i.propertyName],n=this,e===t&&(this.needsRefresh=!0)}i.next=a}this.last=a}handleChange(){this.needsQueue?(this.needsQueue=!1,e(this)):this.isAsync||this.call()}call(){null!==this.last&&(this.needsQueue=this.isAsync,this.notify(this))}*records(){let e=this.first;for(;void 0!==e;)yield e,e=e.next}}return y(d),Object.freeze({setArrayObserverFactory(e){o=e},getNotifier:r,track(e,t){n&&n.watch(e,t)},trackVolatile(){n&&(n.needsRefresh=!0)},notify(e,t){r(e).notify(t)},defineProperty(e,t){c(t)&&(t=new s(t)),a(e).push(t),Reflect.defineProperty(e,t.name,{enumerable:!0,get(){return t.getValue(this)},set(e){t.setValue(this,e)}})},getAccessors:a,binding(e,t,i=this.isVolatileBinding(e)){return new d(e,t,i)},isVolatileBinding(e){return t.test(e.toString())}})}));function x(e,t){S.defineProperty(e,t)}function T(e,t,i){return Object.assign({},i,{get(){return S.trackVolatile(),i.get.apply(this)}})}const w=g.getById(s.contextEvent,(()=>{let e=null;return{get(){return e},set(t){e=t}}})),O=Object.freeze({default:{index:0,length:0,get event(){return O.getEvent()},eventDetail(){return this.event.detail},eventTarget(){return this.event.target}},getEvent(){return w.get()},setEvent(e){w.set(e)}});let P;function A(e){return e.map((e=>e instanceof E?A(e.styles):[e])).reduce(((e,t)=>e.concat(t)),[])}class E{constructor(e){this.styles=e,this.targets=new WeakSet,this._strategy=null,this.behaviors=e.map((e=>e instanceof E?e.behaviors:null)).reduce(((e,t)=>null===t?e:null===e?t:e.concat(t)),null)}get strategy(){return null===this._strategy&&this.withStrategy(P),this._strategy}addStylesTo(e){this.strategy.addStylesTo(e),this.targets.add(e)}removeStylesFrom(e){this.strategy.removeStylesFrom(e),this.targets.delete(e)}isAttachedTo(e){return this.targets.has(e)}withBehaviors(...e){return this.behaviors=null===this.behaviors?e:this.behaviors.concat(e),this}withStrategy(e){return this._strategy=new e(A(this.styles)),this}static setDefaultStrategy(e){P=e}static normalize(e){return void 0===e?void 0:Array.isArray(e)?new E(e):e instanceof E?e:new E([e])}}E.supportsAdoptedStyleSheets=Array.isArray(document.adoptedStyleSheets)&&"replace"in CSSStyleSheet.prototype;const k=Object.freeze({none:0,attribute:1,booleanAttribute:2,property:3,content:4,tokenList:5,event:6}),I=e=>e,D=globalThis.trustedTypes?globalThis.trustedTypes.createPolicy("fast-html",{createHTML:I}):{createHTML:I};let _=Object.freeze({createHTML(e){return D.createHTML(e)},protect(e,t,i,n){return n}});const N=_,R=Object.freeze({get policy(){return _},setPolicy(e){if(_!==N)throw g.error(1201);_=e},setAttribute(e,t,i){null==i?e.removeAttribute(t):e.setAttribute(t,i)},setBooleanAttribute(e,t,i){i?e.setAttribute(t,""):e.removeAttribute(t)}}),M="boolean",L="reflect",B=Object.freeze({locate:v()}),F={toView(e){return e?"true":"false"},fromView(e){return null!=e&&"false"!==e&&!1!==e&&0!==e}};function U(e){if(null==e)return null;const t=1*e;return isNaN(t)?null:t}const H={toView(e){const t=U(e);return t?t.toString():t},fromView:U};class ${constructor(e,t,i=t.toLowerCase(),n=L,o){this.guards=new Set,this.Owner=e,this.name=t,this.attribute=i,this.mode=n,this.converter=o,this.fieldName=`_${t}`,this.callbackName=`${t}Changed`,this.hasCallback=this.callbackName in e.prototype,n===M&&void 0===o&&(this.converter=F)}setValue(e,t){const i=e[this.fieldName],n=this.converter;void 0!==n&&(t=n.fromView(t)),i!==t&&(e[this.fieldName]=t,this.tryReflectToAttribute(e),this.hasCallback&&e[this.callbackName](i,t),e.$fastController.notify(this.name))}getValue(e){return S.track(e,this.name),e[this.fieldName]}onAttributeChangedCallback(e,t){this.guards.has(e)||(this.guards.add(e),this.setValue(e,t),this.guards.delete(e))}tryReflectToAttribute(e){const t=this.mode,i=this.guards;i.has(e)||"fromView"===t||C.enqueue((()=>{i.add(e);const n=e[this.fieldName];switch(t){case L:const t=this.converter;R.setAttribute(e,this.attribute,void 0!==t?t.toView(n):n);break;case M:R.setBooleanAttribute(e,this.attribute,n)}i.delete(e)}))}static collect(e,...t){const i=[];t.push(B.locate(e));for(let n=0,o=t.length;n<o;++n){const o=t[n];if(void 0!==o)for(let t=0,n=o.length;t<n;++t){const n=o[t];c(n)?i.push(new $(e,n)):i.push(new $(e,n.property,n.attribute,n.mode,n.converter))}}return i}}function Z(e,t){let i;function n(e,t){arguments.length>1&&(i.property=t),B.locate(e.constructor).push(i)}return arguments.length>1?(i={},void n(e,t)):(i=void 0===e?{}:e,n)}const V={mode:"open"},G={},j=new Set,z=g.getById(s.elementRegistry,(()=>m()));class W{constructor(e,t=e.definition){var i;this.platformDefined=!1,c(t)&&(t={name:t}),this.type=e,this.name=t.name,this.template=t.template,this.registry=null!==(i=t.registry)&&void 0!==i?i:customElements;const n=e.prototype,o=$.collect(e,t.attributes),r=new Array(o.length),a={},s={};for(let e=0,t=o.length;e<t;++e){const t=o[e];r[e]=t.attribute,a[t.name]=t,s[t.attribute]=t,S.defineProperty(n,t)}Reflect.defineProperty(e,"observedAttributes",{value:r,enumerable:!0}),this.attributes=o,this.propertyLookup=a,this.attributeLookup=s,this.shadowOptions=void 0===t.shadowOptions?V:null===t.shadowOptions?void 0:Object.assign(Object.assign({},V),t.shadowOptions),this.elementOptions=void 0===t.elementOptions?G:Object.assign(Object.assign({},G),t.elementOptions),this.styles=E.normalize(t.styles),z.register(this)}get isDefined(){return this.platformDefined}define(e=this.registry){const t=this.type;return e.get(this.name)||(this.platformDefined=!0,e.define(this.name,t,this.elementOptions)),this}static compose(e,t){return j.has(e)||z.getByType(e)?new W(class extends e{},t):new W(e,t)}static registerBaseType(e){j.add(e)}}W.getByType=z.getByType,W.getForInstance=z.getForInstance;const K={bubbles:!0,composed:!0,cancelable:!0},q="isConnected",Y=new WeakMap;function X(e){var t,i;return null!==(i=null!==(t=e.shadowRoot)&&void 0!==t?t:Y.get(e))&&void 0!==i?i:null}let J;class Q extends h{constructor(e,t){super(e),this.boundObservables=null,this.needsInitialization=!0,this.hasExistingShadowRoot=!1,this._template=null,this.stage=3,this.guardBehaviorConnection=!1,this.behaviors=null,this._mainStyles=null,this.$fastController=this,this.view=null,this.source=e,this.definition=t;const i=t.shadowOptions;if(void 0!==i){let t=e.shadowRoot;t?this.hasExistingShadowRoot=!0:(t=e.attachShadow(i),"closed"===i.mode&&Y.set(e,t))}const n=S.getAccessors(e);if(n.length>0){const t=this.boundObservables=Object.create(null);for(let i=0,o=n.length;i<o;++i){const o=n[i].name,r=e[o];void 0!==r&&(delete e[o],t[o]=r)}}}get isConnected(){return S.track(this,q),1===this.stage}get context(){var e,t;return null!==(t=null===(e=this.view)||void 0===e?void 0:e.context)&&void 0!==t?t:O.default}get isBound(){var e,t;return null!==(t=null===(e=this.view)||void 0===e?void 0:e.isBound)&&void 0!==t&&t}get sourceLifetime(){var e;return null===(e=this.view)||void 0===e?void 0:e.sourceLifetime}get template(){var e;if(null===this._template){const t=this.definition;this.source.resolveTemplate?this._template=this.source.resolveTemplate():t.template&&(this._template=null!==(e=t.template)&&void 0!==e?e:null)}return this._template}set template(e){this._template!==e&&(this._template=e,this.needsInitialization||this.renderTemplate(e))}get mainStyles(){var e;if(null===this._mainStyles){const t=this.definition;this.source.resolveStyles?this._mainStyles=this.source.resolveStyles():t.styles&&(this._mainStyles=null!==(e=t.styles)&&void 0!==e?e:null)}return this._mainStyles}set mainStyles(e){this._mainStyles!==e&&(null!==this._mainStyles&&this.removeStyles(this._mainStyles),this._mainStyles=e,this.needsInitialization||this.addStyles(e))}onUnbind(e){var t;null===(t=this.view)||void 0===t||t.onUnbind(e)}addBehavior(e){var t,i;const n=null!==(t=this.behaviors)&&void 0!==t?t:this.behaviors=new Map,o=null!==(i=n.get(e))&&void 0!==i?i:0;0===o?(n.set(e,1),e.addedCallback&&e.addedCallback(this),!e.connectedCallback||this.guardBehaviorConnection||1!==this.stage&&0!==this.stage||e.connectedCallback(this)):n.set(e,o+1)}removeBehavior(e,t=!1){const i=this.behaviors;if(null===i)return;const n=i.get(e);void 0!==n&&(1===n||t?(i.delete(e),e.disconnectedCallback&&3!==this.stage&&e.disconnectedCallback(this),e.removedCallback&&e.removedCallback(this)):i.set(e,n-1))}addStyles(e){var t;if(!e)return;const i=this.source;if(e instanceof HTMLElement)(null!==(t=X(i))&&void 0!==t?t:this.source).append(e);else if(!e.isAttachedTo(i)){const t=e.behaviors;if(e.addStylesTo(i),null!==t)for(let e=0,i=t.length;e<i;++e)this.addBehavior(t[e])}}removeStyles(e){var t;if(!e)return;const i=this.source;if(e instanceof HTMLElement)(null!==(t=X(i))&&void 0!==t?t:i).removeChild(e);else if(e.isAttachedTo(i)){const t=e.behaviors;if(e.removeStylesFrom(i),null!==t)for(let e=0,i=t.length;e<i;++e)this.removeBehavior(t[e])}}connect(){if(3!==this.stage)return;if(this.stage=0,null!==this.boundObservables){const e=this.source,t=this.boundObservables,i=Object.keys(t);for(let n=0,o=i.length;n<o;++n){const o=i[n];e[o]=t[o]}this.boundObservables=null}const e=this.behaviors;if(null!==e){this.guardBehaviorConnection=!0;for(const t of e.keys())t.connectedCallback&&t.connectedCallback(this);this.guardBehaviorConnection=!1}this.needsInitialization?(this.renderTemplate(this.template),this.addStyles(this.mainStyles),this.needsInitialization=!1):null!==this.view&&this.view.bind(this.source),this.stage=1,S.notify(this,q)}disconnect(){if(1!==this.stage)return;this.stage=2,S.notify(this,q),null!==this.view&&this.view.unbind();const e=this.behaviors;if(null!==e)for(const t of e.keys())t.disconnectedCallback&&t.disconnectedCallback(this);this.stage=3}onAttributeChangedCallback(e,t,i){const n=this.definition.attributeLookup[e];void 0!==n&&n.onAttributeChangedCallback(this.source,i)}emit(e,t,i){return 1===this.stage&&this.source.dispatchEvent(new CustomEvent(e,Object.assign(Object.assign({detail:t},K),i)))}renderTemplate(e){var t;const i=this.source,n=null!==(t=X(i))&&void 0!==t?t:i;if(null!==this.view)this.view.dispose(),this.view=null;else if(!this.needsInitialization||this.hasExistingShadowRoot){this.hasExistingShadowRoot=!1;for(let e=n.firstChild;null!==e;e=n.firstChild)n.removeChild(e)}e&&(this.view=e.render(i,n,i),this.view.sourceLifetime=b.coupled)}static forCustomElement(e){const t=e.$fastController;if(void 0!==t)return t;const i=W.getForInstance(e);if(void 0===i)throw g.error(1401);return e.$fastController=new J(e,i)}static setStrategy(e){J=e}}function ee(e){var t;return"adoptedStyleSheets"in e?e:null!==(t=X(e))&&void 0!==t?t:e.getRootNode()}y(Q),Q.setStrategy(Q);class te{constructor(e){const t=te.styleSheetCache;this.sheets=e.map((e=>{if(e instanceof CSSStyleSheet)return e;let i=t.get(e);return void 0===i&&(i=new CSSStyleSheet,i.replaceSync(e),t.set(e,i)),i}))}addStylesTo(e){oe(ee(e),this.sheets)}removeStylesFrom(e){re(ee(e),this.sheets)}}te.styleSheetCache=new Map;let ie=0;function ne(e){return e===document?document.body:e}let oe=(e,t)=>{e.adoptedStyleSheets=[...e.adoptedStyleSheets,...t]},re=(e,t)=>{e.adoptedStyleSheets=e.adoptedStyleSheets.filter((e=>-1===t.indexOf(e)))};if(E.supportsAdoptedStyleSheets){try{document.adoptedStyleSheets.push(),document.adoptedStyleSheets.splice(),oe=(e,t)=>{e.adoptedStyleSheets.push(...t)},re=(e,t)=>{for(const i of t){const t=e.adoptedStyleSheets.indexOf(i);-1!==t&&e.adoptedStyleSheets.splice(t,1)}}}catch(e){}E.setDefaultStrategy(te)}else E.setDefaultStrategy(class{constructor(e){this.styles=e,this.styleClass="fast-"+ ++ie}addStylesTo(e){e=ne(ee(e));const t=this.styles,i=this.styleClass;for(let n=0;n<t.length;n++){const o=document.createElement("style");o.innerHTML=t[n],o.className=i,e.append(o)}}removeStylesFrom(e){const t=(e=ne(ee(e))).querySelectorAll(`.${this.styleClass}`);for(let i=0,n=t.length;i<n;++i)e.removeChild(t[i])}});function ae(e){const t=class extends e{constructor(){super(),Q.forCustomElement(this)}$emit(e,t,i){return this.$fastController.emit(e,t,i)}connectedCallback(){this.$fastController.connect()}disconnectedCallback(){this.$fastController.disconnect()}attributeChangedCallback(e,t,i){this.$fastController.onAttributeChangedCallback(e,t,i)}};return W.registerBaseType(t),t}const se=Object.assign(ae(HTMLElement),{from:function(e){return ae(e)},define:function(e,t){return l(e)?W.compose(e,t).define().type:W.compose(this,e).define().type},compose:function(e,t){return l(e)?W.compose(e,t):W.compose(this,e)}}),le="compact",ce="edge",de="row";class ue extends se{constructor(){super(...arguments),this.layout=le,this.appearance=ce,this.hideShowMoreRetailers=!1,this.showMoreRetailersLabel="Show more retailers",this.handleNavigation=!1,this.locale="en-US",this.currency="USD",this.filterGroupDirection=de,this.filterGroupSorted=!0,this.filterGroupInlineSwatches=!1,this.autoHideOverflowSwatches=!0,this.hideRetailersLogo=!1,this.retailersListNoDataLabel="No retailers available",this.retailersListLowestPriceLabel="Lowest Price",this.retailersListDiscountPriceLabel="Save",this.retailersListCTAButtonLabel="Visit Site"}dataChanged(e,t){this.updateData(t)}filterGroupSortedChanged(){this.updateData(this.getData)}filterGroupEventHandler(e){var t;const i=e.detail.state;null===(t=this.onfiltergroupselectionchange)||void 0===t||t.call(this,i,e)}clickRetailerEventHandler(e){var t;const i=e.detail.retailerIndex;null===(t=this.onretailerclick)||void 0===t||t.call(this,i,e)}clickShowMoreRetailersEventHandler(e){var t;null===(t=this.onshowmoreretailersclick)||void 0===t||t.call(this,e)}mouseRetailerEventHandler(e){var t;const i=e.detail.retailerIndex;null===(t=this.onretailerhover)||void 0===t||t.call(this,i,e)}clickCtaEventHandler(e){var t;const i=e.detail.retailerIndex;e.stopPropagation(),null===(t=this.onretailerctaclick)||void 0===t||t.call(this,i,e)}sortFilterGroup(e){return this.filterGroupSorted&&e.filters&&e.filters.length>0?{filters:e.filters.sort(((e,t)=>"dropdown"===e.type&&"swatches"===t.type?-1:"swatches"===e.type&&"dropdown"===t.type?1:0))}:e}updateData(e){e&&(this._data={filterGroup:this.sortFilterGroup(e.filterGroup),retailerList:e.retailerList})}get getData(){return this._data}get getFiltersData(){return this.getData.filterGroup.filters}get getRetailersListData(){return{retailers:this.getData.retailerList.retailers.slice(0,this.getShowRetailersCount)}}get getRetailersData(){return this.getData.retailerList.retailers}get getTotalRetailersCount(){return this._data.retailerList.retailers.length}get getShowRetailersCount(){return void 0!==this.showMaxRetailers?Math.min(this.showMaxRetailers,this.getTotalRetailersCount):this.getTotalRetailersCount}get getShowMoreRetailers(){return!this.hideShowMoreRetailers&&this.getShowRetailersCount<this.getTotalRetailersCount}}(0,o.gn)([Z({attribute:"data"})],ue.prototype,"data",void 0),(0,o.gn)([Z],ue.prototype,"layout",void 0),(0,o.gn)([Z],ue.prototype,"appearance",void 0),(0,o.gn)([Z({attribute:"show-max-retailers",converter:H})],ue.prototype,"showMaxRetailers",void 0),(0,o.gn)([Z({attribute:"hide-show-more-retailers",mode:"boolean"})],ue.prototype,"hideShowMoreRetailers",void 0),(0,o.gn)([Z({attribute:"show-more-retailers-label"})],ue.prototype,"showMoreRetailersLabel",void 0),(0,o.gn)([Z({attribute:"handle-navigation",mode:"boolean"})],ue.prototype,"handleNavigation",void 0),(0,o.gn)([Z({attribute:"locale"})],ue.prototype,"locale",void 0),(0,o.gn)([Z({attribute:"currency"})],ue.prototype,"currency",void 0),(0,o.gn)([Z({attribute:"filter-group-direction"})],ue.prototype,"filterGroupDirection",void 0),(0,o.gn)([Z({attribute:"filter-group-sorted",mode:"boolean"})],ue.prototype,"filterGroupSorted",void 0),(0,o.gn)([Z({attribute:"filter-group-inline-swatches",mode:"boolean"})],ue.prototype,"filterGroupInlineSwatches",void 0),(0,o.gn)([Z({attribute:"auto-hide-overflow-swatches",mode:"boolean"})],ue.prototype,"autoHideOverflowSwatches",void 0),(0,o.gn)([Z({attribute:"hide-retailers-logo",mode:"boolean"})],ue.prototype,"hideRetailersLogo",void 0),(0,o.gn)([Z({attribute:"retailers-list-no-data-label"})],ue.prototype,"retailersListNoDataLabel",void 0),(0,o.gn)([Z({attribute:"retailers-list-lowest-price-label"})],ue.prototype,"retailersListLowestPriceLabel",void 0),(0,o.gn)([Z({attribute:"retailers-list-discount-price-label"})],ue.prototype,"retailersListDiscountPriceLabel",void 0),(0,o.gn)([Z({attribute:"retailers-list-cta-button-label"})],ue.prototype,"retailersListCTAButtonLabel",void 0),(0,o.gn)([x],ue.prototype,"_data",void 0);class he{constructor(e,t,i=!1){this.evaluate=e,this.policy=t,this.isVolatile=i}}class pe extends he{createObserver(e){return S.binding(this.evaluate,e,this.isVolatile)}}function ge(e,t,i=S.isVolatileBinding(e)){return new pe(e,t,i)}const fe=m(),me=Object.freeze({getForInstance:fe.getForInstance,getByType:fe.getByType,define(e){return fe.register({type:e}),e}});function ve(e,t,i){t.source.style.setProperty(e.targetAspect,i.bind(t))}class ye{constructor(e,t){this.dataBinding=e,this.targetAspect=t}createCSS(e){return e(this),`var(${this.targetAspect})`}addedCallback(e){var t;const i=e.source;if(!i.$cssBindings){i.$cssBindings=new Map;const e=i.setAttribute;i.setAttribute=(t,n)=>{e.call(i,t,n),"style"===t&&i.$cssBindings.forEach(((e,t)=>ve(t,e.controller,e.observer)))}}const n=null!==(t=e[this.targetAspect])&&void 0!==t?t:e[this.targetAspect]=this.dataBinding.createObserver(this,this);n.controller=e,e.source.$cssBindings.set(this,{controller:e,observer:n})}connectedCallback(e){ve(this,e,e[this.targetAspect])}removedCallback(e){e.source.$cssBindings&&e.source.$cssBindings.delete(this)}handleChange(e,t){ve(this,t.controller,t)}}me.define(ye);const Ce=`${Math.random().toString(36).substring(2,8)}`;let be=0;const Se=()=>`--v${Ce}${++be}`;function xe(e,t){const i=[];let n="";const o=[],r=e=>{o.push(e)};for(let o=0,a=e.length-1;o<a;++o){n+=e[o];let a=t[o];l(a)?a=new ye(ge(a),Se()).createCSS(r):a instanceof he?a=new ye(a,Se()).createCSS(r):void 0!==me.getForInstance(a)&&(a=a.createCSS(r)),a instanceof E||a instanceof CSSStyleSheet?(""!==n.trim()&&(i.push(n),n=""),i.push(a)):n+=a}return n+=e[e.length-1],""!==n.trim()&&i.push(n),{styles:i,behaviors:o}}const Te=(e,...t)=>{const{styles:i,behaviors:n}=xe(e,t),o=new E(i);return n.length?o.withBehaviors(...n):o};class we{constructor(e,t){this.behaviors=t,this.css="";const i=e.reduce(((e,t)=>(c(t)?this.css+=t:e.push(t),e)),[]);i.length&&(this.styles=new E(i))}createCSS(e){return this.behaviors.forEach(e),this.styles&&e(this),this.css}addedCallback(e){e.addStyles(this.styles)}removedCallback(e){e.removeStyles(this.styles)}}me.define(we),Te.partial=(e,...t)=>{const{styles:i,behaviors:n}=xe(e,t);return new we(i,n)};const Oe="var(--colorNeutralForeground1)",Pe="var(--colorNeutralForeground3)",Ae="var(--colorNeutralForeground4)",Ee="var(--colorNeutralForegroundStaticInverted)",ke="var(--colorBrandForeground1)",Ie="var(--colorNeutralBackground1)",De="var(--colorNeutralBackground1Hover)",_e="var(--colorBrandBackground)",Ne="var(--colorNeutralStroke1)",Re="var(--colorNeutralStroke2)",Me="var(--colorNeutralStroke3)",Le="var(--colorPaletteGreenForeground1)",Be="var(--borderRadiusSmall)",Fe="var(--borderRadiusMedium)",Ue="var(--borderRadiusXLarge)",He="var(--fontFamilyBase)",$e="var(--fontSizeBase300)",Ze="var(--fontWeightRegular)",Ve="var(--fontWeightSemibold)",Ge="var(--lineHeightBase300)",je="var(--spacingHorizontalXXS)",ze="var(--spacingHorizontalXS)",We="var(--spacingHorizontalS)",Ke="var(--spacingHorizontalL)",qe="var(--spacingVerticalXXS)",Ye="var(--spacingVerticalXS)",Xe="var(--spacingVerticalS)",Je="var(--spacingVerticalM)",Qe=Te`
/*****************************************
* Common styles
*****************************************/
:host fluent-beta-button svg {
margin-right: ${We};
}
`;class et extends he{createObserver(){return this}bind(e){return this.evaluate(e.source,e.context)}}function tt(e,t){return new et(e,t)}y(et);const it=`fast-${Math.random().toString(36).substring(2,8)}`,nt=`${it}{`,ot=`}${it}`,rt=ot.length;let at=0;const st=()=>`${it}-${++at}`,lt=Object.freeze({interpolation:e=>`${nt}${e}${ot}`,attribute:e=>`${st()}="${nt}${e}${ot}"`,comment:e=>`\x3c!--${nt}${e}${ot}--\x3e`}),ct=Object.freeze({parse(e,t){const i=e.split(nt);if(1===i.length)return null;const n=[];for(let e=0,o=i.length;e<o;++e){const o=i[e],r=o.indexOf(ot);let a;if(-1===r)a=o;else{const e=o.substring(0,r);n.push(t[e]),a=o.substring(r+rt)}""!==a&&n.push(a)}return n}}),dt=m(),ut=Object.freeze({getForInstance:dt.getForInstance,getByType:dt.getByType,define(e,t){return(t=t||{}).type=e,dt.register(t),e},assignAspect(e,t){if(t)switch(e.sourceAspect=t,t[0]){case":":e.targetAspect=t.substring(1),e.aspectType="classList"===e.targetAspect?k.tokenList:k.property;break;case"?":e.targetAspect=t.substring(1),e.aspectType=k.booleanAttribute;break;case"@":e.targetAspect=t.substring(1),e.aspectType=k.event;break;default:e.targetAspect=t,e.aspectType=k.attribute}else e.aspectType=k.content}});class ht{constructor(e){this.options=e}createHTML(e){return lt.attribute(e(this))}createBehavior(){return this}}y(ht);const pt={[k.attribute]:R.setAttribute,[k.booleanAttribute]:R.setBooleanAttribute,[k.property]:(e,t,i)=>e[t]=i,[k.content]:function(e,t,i,n){if(null==i&&(i=""),i.create){e.textContent="";let t=e.$fastView;void 0===t?t=i.create():e.$fastTemplate!==i&&(t.isComposed&&(t.remove(),t.unbind()),t=i.create()),t.isComposed?t.needsBindOnly&&(t.needsBindOnly=!1,t.bind(n.source,n.context)):(t.isComposed=!0,t.bind(n.source,n.context),t.insertBefore(e),e.$fastView=t,e.$fastTemplate=i)}else{const t=e.$fastView;void 0!==t&&t.isComposed&&(t.isComposed=!1,t.remove(),t.needsBindOnly?t.needsBindOnly=!1:t.unbind()),e.textContent=i}},[k.tokenList]:function(e,t,i){var n;const o=`${this.id}-t`,r=null!==(n=e[o])&&void 0!==n?n:e[o]={v:0,cv:Object.create(null)},a=r.cv;let s=r.v;const l=e[t];if(null!=i&&i.length){const e=i.split(/\s+/);for(let t=0,i=e.length;t<i;++t){const i=e[t];""!==i&&(a[i]=s,l.add(i))}}if(r.v=s+1,0!==s){s-=1;for(const e in a)a[e]===s&&l.remove(e)}},[k.event]:()=>{}};class gt{constructor(e){this.dataBinding=e,this.updateTarget=null,this.aspectType=k.content}createHTML(e){return lt.interpolation(e(this))}createBehavior(){var e;if(null===this.updateTarget){const t=pt[this.aspectType],i=null!==(e=this.dataBinding.policy)&&void 0!==e?e:this.policy;if(!t)throw g.error(1205);this.data=`${this.id}-d`,this.updateTarget=i.protect(this.targetTagName,this.aspectType,this.targetAspect,t)}return this}bind(e){var t;const i=e.targets[this.targetNodeId];switch(this.aspectType){case k.event:i[this.data]=e,i.addEventListener(this.targetAspect,this,this.dataBinding.options);break;case k.content:e.onUnbind(this);default:const n=null!==(t=i[this.data])&&void 0!==t?t:i[this.data]=this.dataBinding.createObserver(this,this);n.target=i,n.controller=e,this.updateTarget(i,this.targetAspect,n.bind(e),e)}}unbind(e){const t=e.targets[this.targetNodeId].$fastView;void 0!==t&&t.isComposed&&(t.unbind(),t.needsBindOnly=!0)}handleEvent(e){const t=e.currentTarget[this.data];if(t.isBound){O.setEvent(e);const i=this.dataBinding.evaluate(t.source,t.context);O.setEvent(null),!0!==i&&e.preventDefault()}}handleChange(e,t){const i=t.target,n=t.controller;this.updateTarget(i,this.targetAspect,t.bind(n),n)}}function ft(e,t){const i=e.parentNode;let n,o=e;for(;o!==t;)n=o.nextSibling,i.removeChild(o),o=n;i.removeChild(t)}ut.define(gt,{aspected:!0});class mt{constructor(e,t,i){this.fragment=e,this.factories=t,this.targets=i,this.behaviors=null,this.unbindables=[],this.source=null,this.isBound=!1,this.sourceLifetime=b.unknown,this.context=this,this.index=0,this.length=0,this.firstChild=e.firstChild,this.lastChild=e.lastChild}get event(){return O.getEvent()}get isEven(){return this.index%2==0}get isOdd(){return this.index%2!=0}get isFirst(){return 0===this.index}get isInMiddle(){return!this.isFirst&&!this.isLast}get isLast(){return this.index===this.length-1}eventDetail(){return this.event.detail}eventTarget(){return this.event.target}appendTo(e){e.appendChild(this.fragment)}insertBefore(e){if(this.fragment.hasChildNodes())e.parentNode.insertBefore(this.fragment,e);else{const t=this.lastChild;if(e.previousSibling===t)return;const i=e.parentNode;let n,o=this.firstChild;for(;o!==t;)n=o.nextSibling,i.insertBefore(o,e),o=n;i.insertBefore(t,e)}}remove(){const e=this.fragment,t=this.lastChild;let i,n=this.firstChild;for(;n!==t;)i=n.nextSibling,e.appendChild(n),n=i;e.appendChild(t)}dispose(){ft(this.firstChild,this.lastChild),this.unbind()}onUnbind(e){this.unbindables.push(e)}bind(e,t=this){if(this.source===e)return;let i=this.behaviors;if(null===i){this.source=e,this.context=t,this.behaviors=i=new Array(this.factories.length);const n=this.factories;for(let e=0,t=n.length;e<t;++e){const t=n[e].createBehavior();t.bind(this),i[e]=t}}else{null!==this.source&&this.evaluateUnbindables(),this.isBound=!1,this.source=e,this.context=t;for(let e=0,t=i.length;e<t;++e)i[e].bind(this)}this.isBound=!0}unbind(){this.isBound&&null!==this.source&&(this.evaluateUnbindables(),this.source=null,this.context=this,this.isBound=!1)}evaluateUnbindables(){const e=this.unbindables;for(let t=0,i=e.length;t<i;++t)e[t].unbind(this);e.length=0}static disposeContiguousBatch(e){if(0!==e.length){ft(e[0].firstChild,e[e.length-1].lastChild);for(let t=0,i=e.length;t<i;++t)e[t].unbind()}}}y(mt),S.defineProperty(mt.prototype,"index"),S.defineProperty(mt.prototype,"length");const vt=(e,t)=>`${e}.${t}`,yt={},Ct={index:0,node:null};function bt(e){e.startsWith("fast-")||g.warn(1204,{name:e})}const St=new Proxy(document.createElement("div"),{get(e,t){bt(t);const i=Reflect.get(e,t);return l(i)?i.bind(e):i},set(e,t,i){return bt(t),Reflect.set(e,t,i)}});class xt{constructor(e,t,i){this.fragment=e,this.directives=t,this.policy=i,this.proto=null,this.nodeIds=new Set,this.descriptors={},this.factories=[]}addFactory(e,t,i,n,o){var r,a;this.nodeIds.has(i)||(this.nodeIds.add(i),this.addTargetDescriptor(t,i,n)),e.id=null!==(r=e.id)&&void 0!==r?r:st(),e.targetNodeId=i,e.targetTagName=o,e.policy=null!==(a=e.policy)&&void 0!==a?a:this.policy,this.factories.push(e)}freeze(){return this.proto=Object.create(null,this.descriptors),this}addTargetDescriptor(e,t,i){const n=this.descriptors;if("r"===t||"h"===t||n[t])return;if(!n[e]){const t=e.lastIndexOf("."),i=e.substring(0,t),n=parseInt(e.substring(t+1));this.addTargetDescriptor(i,e,n)}let o=yt[t];if(!o){const n=`_${t}`;yt[t]=o={get(){var t;return null!==(t=this[n])&&void 0!==t?t:this[n]=this[e].childNodes[i]}}}n[t]=o}createView(e){const t=this.fragment.cloneNode(!0),i=Object.create(this.proto);i.r=t,i.h=null!=e?e:St;for(const e of this.nodeIds)i[e];return new mt(t,this.factories,i)}}function Tt(e,t,i,n,o,r=!1){const a=i.attributes,s=e.directives;for(let l=0,c=a.length;l<c;++l){const d=a[l],u=d.value,h=ct.parse(u,s);let p=null;null===h?r&&(p=new gt(tt((()=>u),e.policy)),ut.assignAspect(p,d.name)):p=At.aggregate(h,e.policy),null!==p&&(i.removeAttributeNode(d),l--,c--,e.addFactory(p,t,n,o,i.tagName))}}function wt(e,t,i){let n=0,o=t.firstChild;for(;o;){const t=Ot(e,i,o,n);o=t.node,n=t.index}}function Ot(e,t,i,n){const o=vt(t,n);switch(i.nodeType){case 1:Tt(e,t,i,o,n),wt(e,i,o);break;case 3:return function(e,t,i,n,o){const r=ct.parse(t.textContent,e.directives);if(null===r)return Ct.node=t.nextSibling,Ct.index=o+1,Ct;let a,s=a=t;for(let t=0,l=r.length;t<l;++t){const l=r[t];0!==t&&(o++,n=vt(i,o),a=s.parentNode.insertBefore(document.createTextNode(""),s.nextSibling)),c(l)?a.textContent=l:(a.textContent=" ",ut.assignAspect(l),e.addFactory(l,i,n,o,null)),s=a}return Ct.index=o+1,Ct.node=s.nextSibling,Ct}(e,i,t,o,n);case 8:const r=ct.parse(i.data,e.directives);null!==r&&e.addFactory(At.aggregate(r),t,o,n,null)}return Ct.index=n+1,Ct.node=i.nextSibling,Ct}const Pt="TEMPLATE",At={compile(e,t,i=R.policy){let n;if(c(e)){n=document.createElement(Pt),n.innerHTML=i.createHTML(e);const t=n.content.firstElementChild;null!==t&&t.tagName===Pt&&(n=t)}else n=e;n.content.firstChild||n.content.lastChild||n.content.appendChild(document.createComment(""));const o=document.adoptNode(n.content),r=new xt(o,t,i);var a,s;return Tt(r,"",n,"h",0,!0),s=t,((a=o.firstChild)&&8==a.nodeType&&null!==ct.parse(a.data,s)||1===o.childNodes.length&&Object.keys(t).length>0)&&o.insertBefore(document.createComment(""),o.firstChild),wt(r,o,"r"),Ct.node=null,r.freeze()},setDefaultStrategy(e){this.compile=e},aggregate(e,t=R.policy){if(1===e.length)return e[0];let i,n,o,r=!1;const a=e.length,s=e.map((e=>c(e)?()=>e:(i=e.sourceAspect||i,n=e.dataBinding||n,r=r||e.dataBinding.isVolatile,o=o||e.dataBinding.policy,e.dataBinding.evaluate)));n.evaluate=(e,t)=>{let i="";for(let n=0;n<a;++n)i+=s[n](e,t);return i},n.isVolatile=r,n.policy=null!=o?o:t;const l=new gt(n);return ut.assignAspect(l,i),l}},Et=/([ \x09\x0a\x0c\x0d])([^\0-\x1F\x7F-\x9F "'>=/]+)([ \x09\x0a\x0c\x0d]*=[ \x09\x0a\x0c\x0d]*(?:[^ \x09\x0a\x0c\x0d"'`<>=]*|"[^"]*|'[^']*))$/,kt=Object.create(null);class It{constructor(e,t=kt){this.html=e,this.factories=t}createHTML(e){const t=this.factories;for(const i in t)e(t[i]);return this.html}}function Dt(e,t,i,n=ut.getForInstance(e)){if(n.aspected){const i=Et.exec(t);null!==i&&ut.assignAspect(e,i[2])}return e.createHTML(i)}It.empty=new It(""),ut.define(It);class _t{constructor(e,t={},i){this.policy=i,this.result=null,this.html=e,this.factories=t}create(e){return null===this.result&&(this.result=At.compile(this.html,this.factories,this.policy)),this.result.createView(e)}inline(){return new It(c(this.html)?this.html:this.html.innerHTML,this.factories)}withPolicy(e){if(this.result)throw g.error(1208);if(this.policy)throw g.error(1207);return this.policy=e,this}render(e,t,i){const n=this.create(i);return n.bind(e),n.appendTo(t),n}static create(e,t,i){let n="";const o=Object.create(null),r=e=>{var t;const i=null!==(t=e.id)&&void 0!==t?t:e.id=st();return o[i]=e,i};for(let i=0,o=e.length-1;i<o;++i){const o=e[i];let a,s=t[i];if(n+=o,l(s))s=new gt(ge(s));else if(s instanceof he)s=new gt(s);else if(!(a=ut.getForInstance(s))){const e=s;s=new gt(tt((()=>e)))}n+=Dt(s,o,r,a)}return new _t(n+e[e.length-1],o,i)}}y(_t);const Nt=(e,...t)=>{if(Array.isArray(e)&&Array.isArray(e.raw))return _t.create(e,t);throw g.error(1206)};Nt.partial=e=>new It(e);const Rt=()=>null;function Mt(e){return void 0===e?Rt:l(e)?e:()=>e}function Lt(e,t,i){const n=l(e)?e:()=>e,o=Mt(t),r=Mt(i);return(e,t)=>n(e,t)?o(e,t):r(e,t)}const Bt=Te`
/*****************************************
* Common styles
*****************************************/
:host {
display: flex;
flex-direction: column;
row-gap: ${Xe};
}
::slotted(:first-child:not([slot="retailer-list"])) {
margin-bottom: ${Je};
}
::slotted([slot="show-more-retailers"]) {
display: flex;
flex-direction: column;
align-items: center;
}
`,Ft=Nt`
<slot name="filter-group"></slot>
<slot name="retailer-list"></slot>
<slot name="show-more-retailers"></slot>
`,Ut=Nt`${Ft}`;Nt`<commerceui-buying-options-base></commerceui-buying-options-base>`,class extends se{}.compose({name:`${n.prefix}-buying-options-base`,template:Ut,styles:Bt}).define(n.registry);class Ht extends se{constructor(){super(...arguments),this.direction=de,this.inlineSwatches=!1,this.autoHideOverflowSwatches=!0,this._filterGroupState={}}dataChanged(e,t){this._data=t,this._filterGroupState=this.data.filters.reduce(((e,t,i)=>{let n="";return n=t.id&&void 0!==t.id?t.id:`${t.label}-${t.type}-${i}`.replace(/\s/g,"-").toLowerCase(),e[n]=t.items[t.selectedIndex],e}),{})}selectionChangeHandler(e,t){var i;const n=t.detail.item;this._filterGroupState[e]=n,null===(i=this.onfiltergroupselectionchange)||void 0===i||i.call(this,this._filterGroupState,t),this.$emit("onfiltergroupselectionchange",{state:this._filterGroupState,event:t})}get getData(){return this._data}}let $t;(0,o.gn)([Z],Ht.prototype,"data",void 0),(0,o.gn)([Z],Ht.prototype,"direction",void 0),(0,o.gn)([Z({attribute:"inline-swatches",mode:"boolean"})],Ht.prototype,"inlineSwatches",void 0),(0,o.gn)([Z({attribute:"auto-hide-overflow-swatches",mode:"boolean"})],Ht.prototype,"autoHideOverflowSwatches",void 0),(0,o.gn)([x],Ht.prototype,"_filterGroupState",void 0),(0,o.gn)([x],Ht.prototype,"_data",void 0);const Zt="fast-kernel";try{if(document.currentScript)$t=document.currentScript.getAttribute(Zt);else{const e=document.getElementsByTagName("script");$t=e[e.length-1].getAttribute(Zt)}}catch(e){$t="isolate"}let Vt;switch($t){case"share":Vt=Object.freeze({updateQueue:1,observable:2,contextEvent:3,elementRegistry:4});break;case"share-v2":Vt=Object.freeze({updateQueue:1.2,observable:2.2,contextEvent:3.2,elementRegistry:4.2});break;default:const e=`-${Math.random().toString(36).substring(2,8)}`;Vt=Object.freeze({updateQueue:`1.2${e}`,observable:`2.2${e}`,contextEvent:`3.2${e}`,elementRegistry:`4.2${e}`})}const Gt=e=>"function"==typeof e,jt=e=>"string"==typeof e,zt=()=>{};var Wt="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};!function(){if("undefined"==typeof globalThis)if(void 0!==Wt)Wt.globalThis=Wt;else if("undefined"!=typeof self)self.globalThis=self;else if("undefined"!=typeof window)window.globalThis=window;else{const e=new Function("return this")();e.globalThis=e}}();const Kt={configurable:!1,enumerable:!1,writable:!1};void 0===globalThis.FAST&&Reflect.defineProperty(globalThis,"FAST",Object.assign({value:Object.create(null)},Kt));const qt=globalThis.FAST;if(void 0===qt.getById){const e=Object.create(null);Reflect.defineProperty(qt,"getById",Object.assign({value(t,i){let n=e[t];return void 0===n&&(n=i?e[t]=i():null),n}},Kt))}void 0===qt.error&&Object.assign(qt,{warn(){},error(e){return new Error(`Error ${e}`)},addMessages(){}});const Yt=Object.freeze([]);function Xt(){const e=new Map;return Object.freeze({register(t){return!e.has(t.type)&&(e.set(t.type,t),!0)},getByType(t){return e.get(t)},getForInstance(t){if(null!=t)return e.get(t.constructor)}})}function Jt(){const e=new WeakMap;return function(t){let i=e.get(t);if(void 0===i){let n=Reflect.getPrototypeOf(t);for(;void 0===i&&null!==n;)i=e.get(n),n=Reflect.getPrototypeOf(n);i=void 0===i?[]:i.slice(0),e.set(t,i)}return i}}function Qt(e){e.prototype.toJSON=zt}const ei=Object.freeze({none:0,attribute:1,booleanAttribute:2,property:3,content:4,tokenList:5,event:6}),ti=e=>e,ii=globalThis.trustedTypes?globalThis.trustedTypes.createPolicy("fast-html",{createHTML:ti}):{createHTML:ti};let ni=Object.freeze({createHTML(e){return ii.createHTML(e)},protect(e,t,i,n){return n}});const oi=ni,ri=Object.freeze({get policy(){return ni},setPolicy(e){if(ni!==oi)throw qt.error(1201);ni=e},setAttribute(e,t,i){null==i?e.removeAttribute(t):e.setAttribute(t,i)},setBooleanAttribute(e,t,i){i?e.setAttribute(t,""):e.removeAttribute(t)}}),ai=qt.getById(Vt.updateQueue,(()=>{const e=[],t=[],i=globalThis.requestAnimationFrame;let n=!0;function o(){if(t.length)throw t.shift()}function r(i){try{i.call()}catch(i){if(!n)throw e.length=0,i;t.push(i),setTimeout(o,0)}}function a(){let t=0;for(;t<e.length;)if(r(e[t]),t++,t>1024){for(let i=0,n=e.length-t;i<n;i++)e[i]=e[i+t];e.length-=t,t=0}e.length=0}function s(t){e.push(t),e.length<2&&(n?i(a):a())}return Object.freeze({enqueue:s,next:()=>new Promise(s),process:a,setMode:e=>n=e})}));class si{constructor(e,t){this.sub1=void 0,this.sub2=void 0,this.spillover=void 0,this.subject=e,this.sub1=t}has(e){return void 0===this.spillover?this.sub1===e||this.sub2===e:-1!==this.spillover.indexOf(e)}subscribe(e){const t=this.spillover;if(void 0===t){if(this.has(e))return;if(void 0===this.sub1)return void(this.sub1=e);if(void 0===this.sub2)return void(this.sub2=e);this.spillover=[this.sub1,this.sub2,e],this.sub1=void 0,this.sub2=void 0}else-1===t.indexOf(e)&&t.push(e)}unsubscribe(e){const t=this.spillover;if(void 0===t)this.sub1===e?this.sub1=void 0:this.sub2===e&&(this.sub2=void 0);else{const i=t.indexOf(e);-1!==i&&t.splice(i,1)}}notify(e){const t=this.spillover,i=this.subject;if(void 0===t){const t=this.sub1,n=this.sub2;void 0!==t&&t.handleChange(i,e),void 0!==n&&n.handleChange(i,e)}else for(let n=0,o=t.length;n<o;++n)t[n].handleChange(i,e)}}class li{constructor(e){this.subscribers={},this.subjectSubscribers=null,this.subject=e}notify(e){var t,i;null===(t=this.subscribers[e])||void 0===t||t.notify(e),null===(i=this.subjectSubscribers)||void 0===i||i.notify(e)}subscribe(e,t){var i,n;let o;o=t?null!==(i=this.subscribers[t])&&void 0!==i?i:this.subscribers[t]=new si(this.subject):null!==(n=this.subjectSubscribers)&&void 0!==n?n:this.subjectSubscribers=new si(this.subject),o.subscribe(e)}unsubscribe(e,t){var i,n;t?null===(i=this.subscribers[t])||void 0===i||i.unsubscribe(e):null===(n=this.subjectSubscribers)||void 0===n||n.unsubscribe(e)}}const ci=Object.freeze({unknown:void 0,coupled:1}),di=qt.getById(Vt.observable,(()=>{const e=ai.enqueue,t=/(:|&&|\|\||if|\?\.)/,i=new WeakMap;let n,o=e=>{throw qt.error(1101)};function r(e){var t;let n=null!==(t=e.$fastController)&&void 0!==t?t:i.get(e);return void 0===n&&(Array.isArray(e)?n=o(e):i.set(e,n=new li(e))),n}const a=Jt();class s{constructor(e){this.name=e,this.field=`_${e}`,this.callback=`${e}Changed`}getValue(e){return void 0!==n&&n.watch(e,this.name),e[this.field]}setValue(e,t){const i=this.field,n=e[i];if(n!==t){e[i]=t;const o=e[this.callback];Gt(o)&&o.call(e,n,t),r(e).notify(this.name)}}}class l extends si{constructor(e,t,i=!1){super(e,t),this.expression=e,this.isVolatileBinding=i,this.needsRefresh=!0,this.needsQueue=!0,this.isAsync=!0,this.first=this,this.last=null,this.propertySource=void 0,this.propertyName=void 0,this.notifier=void 0,this.next=void 0}setMode(e){this.isAsync=this.needsQueue=e}bind(e){this.controller=e;const t=this.observe(e.source,e.context);return!e.isBound&&this.requiresUnbind(e)&&e.onUnbind(this),t}requiresUnbind(e){return e.sourceLifetime!==ci.coupled||this.first!==this.last||this.first.propertySource!==e.source}unbind(e){this.dispose()}observe(e,t){this.needsRefresh&&null!==this.last&&this.dispose();const i=n;let o;n=this.needsRefresh?this:void 0,this.needsRefresh=this.isVolatileBinding;try{o=this.expression(e,t)}finally{n=i}return o}disconnect(){this.dispose()}dispose(){if(null!==this.last){let e=this.first;for(;void 0!==e;)e.notifier.unsubscribe(this,e.propertyName),e=e.next;this.last=null,this.needsRefresh=this.needsQueue=this.isAsync}}watch(e,t){const i=this.last,o=r(e),a=null===i?this.first:{};if(a.propertySource=e,a.propertyName=t,a.notifier=o,o.subscribe(this,t),null!==i){if(!this.needsRefresh){let t;n=void 0,t=i.propertySource[i.propertyName],n=this,e===t&&(this.needsRefresh=!0)}i.next=a}this.last=a}handleChange(){this.needsQueue?(this.needsQueue=!1,e(this)):this.isAsync||this.call()}call(){null!==this.last&&(this.needsQueue=this.isAsync,this.notify(this))}*records(){let e=this.first;for(;void 0!==e;)yield e,e=e.next}}return Qt(l),Object.freeze({setArrayObserverFactory(e){o=e},getNotifier:r,track(e,t){n&&n.watch(e,t)},trackVolatile(){n&&(n.needsRefresh=!0)},notify(e,t){r(e).notify(t)},defineProperty(e,t){jt(t)&&(t=new s(t)),a(e).push(t),Reflect.defineProperty(e,t.name,{enumerable:!0,get(){return t.getValue(this)},set(e){t.setValue(this,e)}})},getAccessors:a,binding(e,t,i=this.isVolatileBinding(e)){return new l(e,t,i)},isVolatileBinding(e){return t.test(e.toString())}})}));function ui(e,t){di.defineProperty(e,t)}const hi=qt.getById(Vt.contextEvent,(()=>{let e=null;return{get(){return e},set(t){e=t}}})),pi=Object.freeze({default:{index:0,length:0,get event(){return pi.getEvent()},eventDetail(){return this.event.detail},eventTarget(){return this.event.target}},getEvent(){return hi.get()},setEvent(e){hi.set(e)}});class gi{constructor(e,t,i){this.index=e,this.removed=t,this.addedCount=i}adjustTo(e){let t=this.index;const i=e.length;return t>i?t=i-this.addedCount:t<0&&(t=i+this.removed.length+t-this.addedCount),this.index=t<0?0:t,this}}const fi=Object.freeze({reset:1,splice:2,optimized:3}),mi=new gi(0,Yt,0);mi.reset=!0;const vi=[mi];function yi(e,t,i,n,o,r){let a=0,s=0;const l=Math.min(i-t,r-o);if(0===t&&0===o&&(a=function(e,t,i){for(let n=0;n<i;++n)if(e[n]!==t[n])return n;return i}(e,n,l)),i===e.length&&r===n.length&&(s=function(e,t,i){let n=e.length,o=t.length,r=0;for(;r<i&&e[--n]===t[--o];)r++;return r}(e,n,l-a)),o+=a,r-=s,(i-=s)-(t+=a)==0&&r-o==0)return Yt;if(t===i){const e=new gi(t,[],0);for(;o<r;)e.removed.push(n[o++]);return[e]}if(o===r)return[new gi(t,[],i-t)];const c=function(e){let t=e.length-1,i=e[0].length-1,n=e[t][i];const o=[];for(;t>0||i>0;){if(0===t){o.push(2),i--;continue}if(0===i){o.push(3),t--;continue}const r=e[t-1][i-1],a=e[t-1][i],s=e[t][i-1];let l;l=a<s?a<r?a:r:s<r?s:r,l===r?(r===n?o.push(0):(o.push(1),n=r),t--,i--):l===a?(o.push(3),t--,n=a):(o.push(2),i--,n=s)}return o.reverse()}(function(e,t,i,n,o,r){const a=r-o+1,s=i-t+1,l=new Array(a);let c,d;for(let e=0;e<a;++e)l[e]=new Array(s),l[e][0]=e;for(let e=0;e<s;++e)l[0][e]=e;for(let i=1;i<a;++i)for(let r=1;r<s;++r)e[t+r-1]===n[o+i-1]?l[i][r]=l[i-1][r-1]:(c=l[i-1][r]+1,d=l[i][r-1]+1,l[i][r]=c<d?c:d);return l}(e,t,i,n,o,r)),d=[];let u,h=t,p=o;for(let e=0;e<c.length;++e)switch(c[e]){case 0:void 0!==u&&(d.push(u),u=void 0),h++,p++;break;case 1:void 0===u&&(u=new gi(h,[],0)),u.addedCount++,h++,u.removed.push(n[p]),p++;break;case 2:void 0===u&&(u=new gi(h,[],0)),u.addedCount++,h++;break;case 3:void 0===u&&(u=new gi(h,[],0)),u.removed.push(n[p]),p++}return void 0!==u&&d.push(u),d}function Ci(e,t){let i=!1,n=0;for(let l=0;l<t.length;l++){const c=t[l];if(c.index+=n,i)continue;const d=(o=e.index,r=e.index+e.removed.length,a=c.index,s=c.index+c.addedCount,r<a||s<o?-1:r===a||s===o?0:o<a?r<s?r-a:s-a:s<r?s-o:r-o);if(d>=0){t.splice(l,1),l--,n-=c.addedCount-c.removed.length,e.addedCount+=c.addedCount-d;const o=e.removed.length+c.removed.length-d;if(e.addedCount||o){let t=c.removed;if(e.index<c.index){const i=e.removed.slice(0,c.index-e.index);i.push(...t),t=i}if(e.index+e.removed.length>c.index+c.addedCount){const i=e.removed.slice(c.index+c.addedCount-e.index);t.push(...i)}e.removed=t,c.index<e.index&&(e.index=c.index)}else i=!0}else if(e.index<c.index){i=!0,t.splice(l,0,e),l++;const o=e.addedCount-e.removed.length;c.index+=o,n+=o}}var o,r,a,s;i||t.push(e)}let bi=Object.freeze({support:fi.optimized,normalize(e,t,i){return void 0===e?void 0===i?Yt:function(e,t){let i=[];const n=[];for(let e=0,i=t.length;e<i;e++)Ci(t[e],n);for(let t=0,o=n.length;t<o;++t){const o=n[t];1!==o.addedCount||1!==o.removed.length?i=i.concat(yi(e,o.index,o.index+o.addedCount,o.removed,0,o.removed.length)):o.removed[0]!==e[o.index]&&i.push(o)}return i}(t,i):vi},pop(e,t,i,n){const o=e.length>0,r=i.apply(e,n);return o&&t.addSplice(new gi(e.length,[r],0)),r},push(e,t,i,n){const o=i.apply(e,n);return t.addSplice(new gi(e.length-n.length,[],n.length).adjustTo(e)),o},reverse(e,t,i,n){const o=i.apply(e,n);return t.reset(e),o},shift(e,t,i,n){const o=e.length>0,r=i.apply(e,n);return o&&t.addSplice(new gi(0,[r],0)),r},sort(e,t,i,n){const o=i.apply(e,n);return t.reset(e),o},splice(e,t,i,n){const o=i.apply(e,n);return t.addSplice(new gi(+n[0],o,n.length>2?n.length-2:0).adjustTo(e)),o},unshift(e,t,i,n){const o=i.apply(e,n);return t.addSplice(new gi(0,[],n.length).adjustTo(e)),o}});function Si(e,t,i){Reflect.defineProperty(e,t,{value:i,enumerable:!1})}class xi extends si{constructor(e){super(e),this.oldCollection=void 0,this.splices=void 0,this.needsQueue=!0,this._strategy=null,this._lengthObserver=void 0,this.call=this.flush,Si(e,"$fastController",this)}get strategy(){return this._strategy}set strategy(e){this._strategy=e}get lengthObserver(){let e=this._lengthObserver;if(void 0===e){const t=this.subject;this._lengthObserver=e={length:t.length,handleChange(){this.length!==t.length&&(this.length=t.length,di.notify(e,"length"))}},this.subscribe(e)}return e}subscribe(e){this.flush(),super.subscribe(e)}addSplice(e){void 0===this.splices?this.splices=[e]:this.splices.push(e),this.enqueue()}reset(e){this.oldCollection=e,this.enqueue()}flush(){var e;const t=this.splices,i=this.oldCollection;void 0===t&&void 0===i||(this.needsQueue=!0,this.splices=void 0,this.oldCollection=void 0,this.notify((null!==(e=this._strategy)&&void 0!==e?e:bi).normalize(i,this.subject,t)))}enqueue(){this.needsQueue&&(this.needsQueue=!1,ai.enqueue(this))}}let Ti=!1;const wi=Object.freeze({enable(){if(Ti)return;Ti=!0,di.setArrayObserverFactory((e=>new xi(e)));const e=Array.prototype;e.$fastPatch||(Si(e,"$fastPatch",1),[e.pop,e.push,e.reverse,e.shift,e.sort,e.splice,e.unshift].forEach((t=>{e[t.name]=function(...e){var i;const n=this.$fastController;return void 0===n?t.apply(this,e):(null!==(i=n.strategy)&&void 0!==i?i:bi)[t.name](this,n,t,e)}})))}});class Oi{constructor(e,t,i=!1){this.evaluate=e,this.policy=t,this.isVolatile=i}}class Pi extends Oi{createObserver(e){return di.binding(this.evaluate,e,this.isVolatile)}}function Ai(e,t,i=di.isVolatileBinding(e)){return new Pi(e,t,i)}class Ei extends Oi{createObserver(){return this}bind(e){return this.evaluate(e.source,e.context)}}function ki(e,t){return new Ei(e,t)}function Ii(e){return Gt(e)?Ai(e):e instanceof Oi?e:ki((()=>e))}let Di;function _i(e){return e.map((e=>e instanceof Ni?_i(e.styles):[e])).reduce(((e,t)=>e.concat(t)),[])}Qt(Ei);class Ni{constructor(e){this.styles=e,this.targets=new WeakSet,this._strategy=null,this.behaviors=e.map((e=>e instanceof Ni?e.behaviors:null)).reduce(((e,t)=>null===t?e:null===e?t:e.concat(t)),null)}get strategy(){return null===this._strategy&&this.withStrategy(Di),this._strategy}addStylesTo(e){this.strategy.addStylesTo(e),this.targets.add(e)}removeStylesFrom(e){this.strategy.removeStylesFrom(e),this.targets.delete(e)}isAttachedTo(e){return this.targets.has(e)}withBehaviors(...e){return this.behaviors=null===this.behaviors?e:this.behaviors.concat(e),this}withStrategy(e){return this._strategy=new e(_i(this.styles)),this}static setDefaultStrategy(e){Di=e}static normalize(e){return void 0===e?void 0:Array.isArray(e)?new Ni(e):e instanceof Ni?e:new Ni([e])}}Ni.supportsAdoptedStyleSheets=Array.isArray(document.adoptedStyleSheets)&&"replace"in CSSStyleSheet.prototype;const Ri=Xt(),Mi=Object.freeze({getForInstance:Ri.getForInstance,getByType:Ri.getByType,define(e){return Ri.register({type:e}),e}});function Li(e,t,i){t.source.style.setProperty(e.targetAspect,i.bind(t))}class Bi{constructor(e,t){this.dataBinding=e,this.targetAspect=t}createCSS(e){return e(this),`var(${this.targetAspect})`}addedCallback(e){var t;const i=e.source;if(!i.$cssBindings){i.$cssBindings=new Map;const e=i.setAttribute;i.setAttribute=(t,n)=>{e.call(i,t,n),"style"===t&&i.$cssBindings.forEach(((e,t)=>Li(t,e.controller,e.observer)))}}const n=null!==(t=e[this.targetAspect])&&void 0!==t?t:e[this.targetAspect]=this.dataBinding.createObserver(this,this);n.controller=e,e.source.$cssBindings.set(this,{controller:e,observer:n})}connectedCallback(e){Li(this,e,e[this.targetAspect])}removedCallback(e){e.source.$cssBindings&&e.source.$cssBindings.delete(this)}handleChange(e,t){Li(this,t.controller,t)}}Mi.define(Bi);const Fi=`${Math.random().toString(36).substring(2,8)}`;let Ui=0;const Hi=()=>`--v${Fi}${++Ui}`;function $i(e,t){const i=[];let n="";const o=[],r=e=>{o.push(e)};for(let o=0,a=e.length-1;o<a;++o){n+=e[o];let a=t[o];Gt(a)?a=new Bi(Ai(a),Hi()).createCSS(r):a instanceof Oi?a=new Bi(a,Hi()).createCSS(r):void 0!==Mi.getForInstance(a)&&(a=a.createCSS(r)),a instanceof Ni||a instanceof CSSStyleSheet?(""!==n.trim()&&(i.push(n),n=""),i.push(a)):n+=a}return n+=e[e.length-1],""!==n.trim()&&i.push(n),{styles:i,behaviors:o}}const Zi=(e,...t)=>{const{styles:i,behaviors:n}=$i(e,t),o=new Ni(i);return n.length?o.withBehaviors(...n):o};class Vi{constructor(e,t){this.behaviors=t,this.css="";const i=e.reduce(((e,t)=>(jt(t)?this.css+=t:e.push(t),e)),[]);i.length&&(this.styles=new Ni(i))}createCSS(e){return this.behaviors.forEach(e),this.styles&&e(this),this.css}addedCallback(e){e.addStyles(this.styles)}removedCallback(e){e.removeStyles(this.styles)}}Mi.define(Vi),Zi.partial=(e,...t)=>{const{styles:i,behaviors:n}=$i(e,t);return new Vi(i,n)};const Gi=`fast-${Math.random().toString(36).substring(2,8)}`,ji=`${Gi}{`,zi=`}${Gi}`,Wi=zi.length;let Ki=0;const qi=()=>`${Gi}-${++Ki}`,Yi=Object.freeze({interpolation:e=>`${ji}${e}${zi}`,attribute:e=>`${qi()}="${ji}${e}${zi}"`,comment:e=>`\x3c!--${ji}${e}${zi}--\x3e`}),Xi=Object.freeze({parse(e,t){const i=e.split(ji);if(1===i.length)return null;const n=[];for(let e=0,o=i.length;e<o;++e){const o=i[e],r=o.indexOf(zi);let a;if(-1===r)a=o;else{const e=o.substring(0,r);n.push(t[e]),a=o.substring(r+Wi)}""!==a&&n.push(a)}return n}}),Ji=Xt(),Qi=Object.freeze({getForInstance:Ji.getForInstance,getByType:Ji.getByType,define(e,t){return(t=t||{}).type=e,Ji.register(t),e},assignAspect(e,t){if(t)switch(e.sourceAspect=t,t[0]){case":":e.targetAspect=t.substring(1),e.aspectType="classList"===e.targetAspect?ei.tokenList:ei.property;break;case"?":e.targetAspect=t.substring(1),e.aspectType=ei.booleanAttribute;break;case"@":e.targetAspect=t.substring(1),e.aspectType=ei.event;break;default:e.targetAspect=t,e.aspectType=ei.attribute}else e.aspectType=ei.content}});class en{constructor(e){this.options=e}createHTML(e){return Yi.attribute(e(this))}createBehavior(){return this}}Qt(en);const tn={[ei.attribute]:ri.setAttribute,[ei.booleanAttribute]:ri.setBooleanAttribute,[ei.property]:(e,t,i)=>e[t]=i,[ei.content]:function(e,t,i,n){if(null==i&&(i=""),i.create){e.textContent="";let t=e.$fastView;void 0===t?t=i.create():e.$fastTemplate!==i&&(t.isComposed&&(t.remove(),t.unbind()),t=i.create()),t.isComposed?t.needsBindOnly&&(t.needsBindOnly=!1,t.bind(n.source,n.context)):(t.isComposed=!0,t.bind(n.source,n.context),t.insertBefore(e),e.$fastView=t,e.$fastTemplate=i)}else{const t=e.$fastView;void 0!==t&&t.isComposed&&(t.isComposed=!1,t.remove(),t.needsBindOnly?t.needsBindOnly=!1:t.unbind()),e.textContent=i}},[ei.tokenList]:function(e,t,i){var n;const o=`${this.id}-t`,r=null!==(n=e[o])&&void 0!==n?n:e[o]={v:0,cv:Object.create(null)},a=r.cv;let s=r.v;const l=e[t];if(null!=i&&i.length){const e=i.split(/\s+/);for(let t=0,i=e.length;t<i;++t){const i=e[t];""!==i&&(a[i]=s,l.add(i))}}if(r.v=s+1,0!==s){s-=1;for(const e in a)a[e]===s&&l.remove(e)}},[ei.event]:()=>{}};class nn{constructor(e){this.dataBinding=e,this.updateTarget=null,this.aspectType=ei.content}createHTML(e){return Yi.interpolation(e(this))}createBehavior(){var e;if(null===this.updateTarget){const t=tn[this.aspectType],i=null!==(e=this.dataBinding.policy)&&void 0!==e?e:this.policy;if(!t)throw qt.error(1205);this.data=`${this.id}-d`,this.updateTarget=i.protect(this.targetTagName,this.aspectType,this.targetAspect,t)}return this}bind(e){var t;const i=e.targets[this.targetNodeId];switch(this.aspectType){case ei.event:i[this.data]=e,i.addEventListener(this.targetAspect,this,this.dataBinding.options);break;case ei.content:e.onUnbind(this);default:const n=null!==(t=i[this.data])&&void 0!==t?t:i[this.data]=this.dataBinding.createObserver(this,this);n.target=i,n.controller=e,this.updateTarget(i,this.targetAspect,n.bind(e),e)}}unbind(e){const t=e.targets[this.targetNodeId].$fastView;void 0!==t&&t.isComposed&&(t.unbind(),t.needsBindOnly=!0)}handleEvent(e){const t=e.currentTarget[this.data];if(t.isBound){pi.setEvent(e);const i=this.dataBinding.evaluate(t.source,t.context);pi.setEvent(null),!0!==i&&e.preventDefault()}}handleChange(e,t){const i=t.target,n=t.controller;this.updateTarget(i,this.targetAspect,t.bind(n),n)}}function on(e,t){const i=e.parentNode;let n,o=e;for(;o!==t;)n=o.nextSibling,i.removeChild(o),o=n;i.removeChild(t)}Qi.define(nn,{aspected:!0});class rn{constructor(e,t,i){this.fragment=e,this.factories=t,this.targets=i,this.behaviors=null,this.unbindables=[],this.source=null,this.isBound=!1,this.sourceLifetime=ci.unknown,this.context=this,this.index=0,this.length=0,this.firstChild=e.firstChild,this.lastChild=e.lastChild}get event(){return pi.getEvent()}get isEven(){return this.index%2==0}get isOdd(){return this.index%2!=0}get isFirst(){return 0===this.index}get isInMiddle(){return!this.isFirst&&!this.isLast}get isLast(){return this.index===this.length-1}eventDetail(){return this.event.detail}eventTarget(){return this.event.target}appendTo(e){e.appendChild(this.fragment)}insertBefore(e){if(this.fragment.hasChildNodes())e.parentNode.insertBefore(this.fragment,e);else{const t=this.lastChild;if(e.previousSibling===t)return;const i=e.parentNode;let n,o=this.firstChild;for(;o!==t;)n=o.nextSibling,i.insertBefore(o,e),o=n;i.insertBefore(t,e)}}remove(){const e=this.fragment,t=this.lastChild;let i,n=this.firstChild;for(;n!==t;)i=n.nextSibling,e.appendChild(n),n=i;e.appendChild(t)}dispose(){on(this.firstChild,this.lastChild),this.unbind()}onUnbind(e){this.unbindables.push(e)}bind(e,t=this){if(this.source===e)return;let i=this.behaviors;if(null===i){this.source=e,this.context=t,this.behaviors=i=new Array(this.factories.length);const n=this.factories;for(let e=0,t=n.length;e<t;++e){const t=n[e].createBehavior();t.bind(this),i[e]=t}}else{null!==this.source&&this.evaluateUnbindables(),this.isBound=!1,this.source=e,this.context=t;for(let e=0,t=i.length;e<t;++e)i[e].bind(this)}this.isBound=!0}unbind(){this.isBound&&null!==this.source&&(this.evaluateUnbindables(),this.source=null,this.context=this,this.isBound=!1)}evaluateUnbindables(){const e=this.unbindables;for(let t=0,i=e.length;t<i;++t)e[t].unbind(this);e.length=0}static disposeContiguousBatch(e){if(0!==e.length){on(e[0].firstChild,e[e.length-1].lastChild);for(let t=0,i=e.length;t<i;++t)e[t].unbind()}}}Qt(rn),di.defineProperty(rn.prototype,"index"),di.defineProperty(rn.prototype,"length");const an=(e,t)=>`${e}.${t}`,sn={},ln={index:0,node:null};function cn(e){e.startsWith("fast-")||qt.warn(1204,{name:e})}const dn=new Proxy(document.createElement("div"),{get(e,t){cn(t);const i=Reflect.get(e,t);return Gt(i)?i.bind(e):i},set(e,t,i){return cn(t),Reflect.set(e,t,i)}});class un{constructor(e,t,i){this.fragment=e,this.directives=t,this.policy=i,this.proto=null,this.nodeIds=new Set,this.descriptors={},this.factories=[]}addFactory(e,t,i,n,o){var r,a;this.nodeIds.has(i)||(this.nodeIds.add(i),this.addTargetDescriptor(t,i,n)),e.id=null!==(r=e.id)&&void 0!==r?r:qi(),e.targetNodeId=i,e.targetTagName=o,e.policy=null!==(a=e.policy)&&void 0!==a?a:this.policy,this.factories.push(e)}freeze(){return this.proto=Object.create(null,this.descriptors),this}addTargetDescriptor(e,t,i){const n=this.descriptors;if("r"===t||"h"===t||n[t])return;if(!n[e]){const t=e.lastIndexOf("."),i=e.substring(0,t),n=parseInt(e.substring(t+1));this.addTargetDescriptor(i,e,n)}let o=sn[t];if(!o){const n=`_${t}`;sn[t]=o={get(){var t;return null!==(t=this[n])&&void 0!==t?t:this[n]=this[e].childNodes[i]}}}n[t]=o}createView(e){const t=this.fragment.cloneNode(!0),i=Object.create(this.proto);i.r=t,i.h=null!=e?e:dn;for(const e of this.nodeIds)i[e];return new rn(t,this.factories,i)}}function hn(e,t,i,n,o,r=!1){const a=i.attributes,s=e.directives;for(let l=0,c=a.length;l<c;++l){const d=a[l],u=d.value,h=Xi.parse(u,s);let p=null;null===h?r&&(p=new nn(ki((()=>u),e.policy)),Qi.assignAspect(p,d.name)):p=mn.aggregate(h,e.policy),null!==p&&(i.removeAttributeNode(d),l--,c--,e.addFactory(p,t,n,o,i.tagName))}}function pn(e,t,i){let n=0,o=t.firstChild;for(;o;){const t=gn(e,i,o,n);o=t.node,n=t.index}}function gn(e,t,i,n){const o=an(t,n);switch(i.nodeType){case 1:hn(e,t,i,o,n),pn(e,i,o);break;case 3:return function(e,t,i,n,o){const r=Xi.parse(t.textContent,e.directives);if(null===r)return ln.node=t.nextSibling,ln.index=o+1,ln;let a,s=a=t;for(let t=0,l=r.length;t<l;++t){const l=r[t];0!==t&&(o++,n=an(i,o),a=s.parentNode.insertBefore(document.createTextNode(""),s.nextSibling)),jt(l)?a.textContent=l:(a.textContent=" ",Qi.assignAspect(l),e.addFactory(l,i,n,o,null)),s=a}return ln.index=o+1,ln.node=s.nextSibling,ln}(e,i,t,o,n);case 8:const r=Xi.parse(i.data,e.directives);null!==r&&e.addFactory(mn.aggregate(r),t,o,n,null)}return ln.index=n+1,ln.node=i.nextSibling,ln}const fn="TEMPLATE",mn={compile(e,t,i=ri.policy){let n;if(jt(e)){n=document.createElement(fn),n.innerHTML=i.createHTML(e);const t=n.content.firstElementChild;null!==t&&t.tagName===fn&&(n=t)}else n=e;n.content.firstChild||n.content.lastChild||n.content.appendChild(document.createComment(""));const o=document.adoptNode(n.content),r=new un(o,t,i);var a,s;return hn(r,"",n,"h",0,!0),s=t,((a=o.firstChild)&&8==a.nodeType&&null!==Xi.parse(a.data,s)||1===o.childNodes.length&&Object.keys(t).length>0)&&o.insertBefore(document.createComment(""),o.firstChild),pn(r,o,"r"),ln.node=null,r.freeze()},setDefaultStrategy(e){this.compile=e},aggregate(e,t=ri.policy){if(1===e.length)return e[0];let i,n,o,r=!1;const a=e.length,s=e.map((e=>jt(e)?()=>e:(i=e.sourceAspect||i,n=e.dataBinding||n,r=r||e.dataBinding.isVolatile,o=o||e.dataBinding.policy,e.dataBinding.evaluate)));n.evaluate=(e,t)=>{let i="";for(let n=0;n<a;++n)i+=s[n](e,t);return i},n.isVolatile=r,n.policy=null!=o?o:t;const l=new nn(n);return Qi.assignAspect(l,i),l}},vn=/([ \x09\x0a\x0c\x0d])([^\0-\x1F\x7F-\x9F "'>=/]+)([ \x09\x0a\x0c\x0d]*=[ \x09\x0a\x0c\x0d]*(?:[^ \x09\x0a\x0c\x0d"'`<>=]*|"[^"]*|'[^']*))$/,yn=Object.create(null);class Cn{constructor(e,t=yn){this.html=e,this.factories=t}createHTML(e){const t=this.factories;for(const i in t)e(t[i]);return this.html}}function bn(e,t,i,n=Qi.getForInstance(e)){if(n.aspected){const i=vn.exec(t);null!==i&&Qi.assignAspect(e,i[2])}return e.createHTML(i)}Cn.empty=new Cn(""),Qi.define(Cn);class Sn{constructor(e,t={},i){this.policy=i,this.result=null,this.html=e,this.factories=t}create(e){return null===this.result&&(this.result=mn.compile(this.html,this.factories,this.policy)),this.result.createView(e)}inline(){return new Cn(jt(this.html)?this.html:this.html.innerHTML,this.factories)}withPolicy(e){if(this.result)throw qt.error(1208);if(this.policy)throw qt.error(1207);return this.policy=e,this}render(e,t,i){const n=this.create(i);return n.bind(e),n.appendTo(t),n}static create(e,t,i){let n="";const o=Object.create(null),r=e=>{var t;const i=null!==(t=e.id)&&void 0!==t?t:e.id=qi();return o[i]=e,i};for(let i=0,o=e.length-1;i<o;++i){const o=e[i];let a,s=t[i];if(n+=o,Gt(s))s=new nn(Ai(s));else if(s instanceof Oi)s=new nn(s);else if(!(a=Qi.getForInstance(s))){const e=s;s=new nn(ki((()=>e)))}n+=bn(s,o,r,a)}return new Sn(n+e[e.length-1],o,i)}}Qt(Sn);const xn=(e,...t)=>{if(Array.isArray(e)&&Array.isArray(e.raw))return Sn.create(e,t);throw qt.error(1206)};xn.partial=e=>new Cn(e);class Tn extends en{bind(e){e.source[this.options]=e.targets[this.targetNodeId]}}Qi.define(Tn);const wn=e=>new Tn(e),On=()=>null;function Pn(e){return void 0===e?On:Gt(e)?e:()=>e}function An(e,t,i){const n=Gt(e)?e:()=>e,o=Pn(t),r=Pn(i);return(e,t)=>n(e,t)?o(e,t):r(e,t)}const En=Object.freeze({positioning:!1,recycle:!0});function kn(e,t,i,n){e.context.parent=n.source,e.context.parentContext=n.context,e.bind(t[i])}function In(e,t,i,n){e.context.parent=n.source,e.context.parentContext=n.context,e.context.length=t.length,e.context.index=i,e.bind(t[i])}class Dn{constructor(e){this.directive=e,this.items=null,this.itemsObserver=null,this.bindView=kn,this.views=[],this.itemsBindingObserver=e.dataBinding.createObserver(this,e),this.templateBindingObserver=e.templateBinding.createObserver(this,e),e.options.positioning&&(this.bindView=In)}bind(e){this.location=e.targets[this.directive.targetNodeId],this.controller=e,this.items=this.itemsBindingObserver.bind(e),this.template=this.templateBindingObserver.bind(e),this.observeItems(!0),this.refreshAllViews(),e.onUnbind(this)}unbind(){null!==this.itemsObserver&&this.itemsObserver.unsubscribe(this),this.unbindAllViews()}handleChange(e,t){if(t===this.itemsBindingObserver)this.items=this.itemsBindingObserver.bind(this.controller),this.observeItems(),this.refreshAllViews();else if(t===this.templateBindingObserver)this.template=this.templateBindingObserver.bind(this.controller),this.refreshAllViews(!0);else{if(!t[0])return;t[0].reset?this.refreshAllViews():this.updateViews(t)}}observeItems(e=!1){if(!this.items)return void(this.items=Yt);const t=this.itemsObserver,i=this.itemsObserver=di.getNotifier(this.items),n=t!==i;n&&null!==t&&t.unsubscribe(this),(n||e)&&i.subscribe(this)}updateViews(e){const t=this.views,i=this.bindView,n=this.items,o=this.template,r=this.controller,a=this.directive.options.recycle,s=[];let l=0,c=0;for(let d=0,u=e.length;d<u;++d){const u=e[d],h=u.removed;let p=0,g=u.index;const f=g+u.addedCount,m=t.splice(u.index,h.length),v=c=s.length+m.length;for(;g<f;++g){const e=t[g],d=e?e.firstChild:this.location;let u;a&&c>0?(p<=v&&m.length>0?(u=m[p],p++):(u=s[l],l++),c--):u=o.create(),t.splice(g,0,u),i(u,n,g,r),u.insertBefore(d)}m[p]&&s.push(...m.slice(p))}for(let e=l,t=s.length;e<t;++e)s[e].dispose();if(this.directive.options.positioning)for(let e=0,i=t.length;e<i;++e){const n=t[e].context;n.length=i,n.index=e}}refreshAllViews(e=!1){const t=this.items,i=this.template,n=this.location,o=this.bindView,r=this.controller;let a=t.length,s=this.views,l=s.length;if(0!==a&&!e&&this.directive.options.recycle||(rn.disposeContiguousBatch(s),l=0),0===l){this.views=s=new Array(a);for(let e=0;e<a;++e){const a=i.create();o(a,t,e,r),s[e]=a,a.insertBefore(n)}}else{let e=0;for(;e<a;++e)if(e<l)o(s[e],t,e,r);else{const a=i.create();o(a,t,e,r),s.push(a),a.insertBefore(n)}const c=s.splice(e,l-e);for(e=0,a=c.length;e<a;++e)c[e].dispose()}}unbindAllViews(){const e=this.views;for(let t=0,i=e.length;t<i;++t)e[t].unbind()}}class _n{constructor(e,t,i){this.dataBinding=e,this.templateBinding=t,this.options=i,wi.enable()}createHTML(e){return Yi.comment(e(this))}createBehavior(){return new Dn(this)}}function Nn(e,t,i=En){const n=Ii(e),o=Ii(t);return new _n(n,o,Object.assign(Object.assign({},En),i))}Qi.define(_n);const Rn=e=>1===e.nodeType,Mn=e=>e?t=>1===t.nodeType&&t.matches(e):Rn;class Ln extends en{get id(){return this._id}set id(e){this._id=e,this._controllerProperty=`${e}-c`}bind(e){const t=e.targets[this.targetNodeId];t[this._controllerProperty]=e,this.updateTarget(e.source,this.computeNodes(t)),this.observe(t),e.onUnbind(this)}unbind(e){const t=e.targets[this.targetNodeId];this.updateTarget(e.source,Yt),this.disconnect(t),t[this._controllerProperty]=null}getSource(e){return e[this._controllerProperty].source}updateTarget(e,t){e[this.options.property]=t}computeNodes(e){let t=this.getNodes(e);return"filter"in this.options&&(t=t.filter(this.options.filter)),t}}const Bn="slotchange";class Fn extends Ln{observe(e){e.addEventListener(Bn,this)}disconnect(e){e.removeEventListener(Bn,this)}getNodes(e){return e.assignedNodes(this.options)}handleEvent(e){const t=e.currentTarget;this.updateTarget(this.getSource(t),this.computeNodes(t))}}function Un(e){return jt(e)&&(e={property:e}),new Fn(e)}Qi.define(Fn);const Hn="boolean",$n="reflect",Zn=Object.freeze({locate:Jt()}),Vn={toView(e){return e?"true":"false"},fromView(e){return null!=e&&"false"!==e&&!1!==e&&0!==e}};function Gn(e){if(null==e)return null;const t=1*e;return isNaN(t)?null:t}const jn={toView(e){const t=Gn(e);return t?t.toString():t},fromView:Gn};class zn{constructor(e,t,i=t.toLowerCase(),n=$n,o){this.guards=new Set,this.Owner=e,this.name=t,this.attribute=i,this.mode=n,this.converter=o,this.fieldName=`_${t}`,this.callbackName=`${t}Changed`,this.hasCallback=this.callbackName in e.prototype,n===Hn&&void 0===o&&(this.converter=Vn)}setValue(e,t){const i=e[this.fieldName],n=this.converter;void 0!==n&&(t=n.fromView(t)),i!==t&&(e[this.fieldName]=t,this.tryReflectToAttribute(e),this.hasCallback&&e[this.callbackName](i,t),e.$fastController.notify(this.name))}getValue(e){return di.track(e,this.name),e[this.fieldName]}onAttributeChangedCallback(e,t){this.guards.has(e)||(this.guards.add(e),this.setValue(e,t),this.guards.delete(e))}tryReflectToAttribute(e){const t=this.mode,i=this.guards;i.has(e)||"fromView"===t||ai.enqueue((()=>{i.add(e);const n=e[this.fieldName];switch(t){case $n:const t=this.converter;ri.setAttribute(e,this.attribute,void 0!==t?t.toView(n):n);break;case Hn:ri.setBooleanAttribute(e,this.attribute,n)}i.delete(e)}))}static collect(e,...t){const i=[];t.push(Zn.locate(e));for(let n=0,o=t.length;n<o;++n){const o=t[n];if(void 0!==o)for(let t=0,n=o.length;t<n;++t){const n=o[t];jt(n)?i.push(new zn(e,n)):i.push(new zn(e,n.property,n.attribute,n.mode,n.converter))}}return i}}function Wn(e,t){let i;function n(e,t){arguments.length>1&&(i.property=t),Zn.locate(e.constructor).push(i)}return arguments.length>1?(i={},void n(e,t)):(i=void 0===e?{}:e,n)}const Kn={mode:"open"},qn={},Yn=new Set,Xn=qt.getById(Vt.elementRegistry,(()=>Xt()));class Jn{constructor(e,t=e.definition){var i;this.platformDefined=!1,jt(t)&&(t={name:t}),this.type=e,this.name=t.name,this.template=t.template,this.registry=null!==(i=t.registry)&&void 0!==i?i:customElements;const n=e.prototype,o=zn.collect(e,t.attributes),r=new Array(o.length),a={},s={};for(let e=0,t=o.length;e<t;++e){const t=o[e];r[e]=t.attribute,a[t.name]=t,s[t.attribute]=t,di.defineProperty(n,t)}Reflect.defineProperty(e,"observedAttributes",{value:r,enumerable:!0}),this.attributes=o,this.propertyLookup=a,this.attributeLookup=s,this.shadowOptions=void 0===t.shadowOptions?Kn:null===t.shadowOptions?void 0:Object.assign(Object.assign({},Kn),t.shadowOptions),this.elementOptions=void 0===t.elementOptions?qn:Object.assign(Object.assign({},qn),t.elementOptions),this.styles=Ni.normalize(t.styles),Xn.register(this)}get isDefined(){return this.platformDefined}define(e=this.registry){const t=this.type;return e.get(this.name)||(this.platformDefined=!0,e.define(this.name,t,this.elementOptions)),this}static compose(e,t){return Yn.has(e)||Xn.getByType(e)?new Jn(class extends e{},t):new Jn(e,t)}static registerBaseType(e){Yn.add(e)}}Jn.getByType=Xn.getByType,Jn.getForInstance=Xn.getForInstance;const Qn={bubbles:!0,composed:!0,cancelable:!0},eo="isConnected",to=new WeakMap;function io(e){var t,i;return null!==(i=null!==(t=e.shadowRoot)&&void 0!==t?t:to.get(e))&&void 0!==i?i:null}let no;class oo extends li{constructor(e,t){super(e),this.boundObservables=null,this.needsInitialization=!0,this.hasExistingShadowRoot=!1,this._template=null,this.stage=3,this.guardBehaviorConnection=!1,this.behaviors=null,this._mainStyles=null,this.$fastController=this,this.view=null,this.source=e,this.definition=t;const i=t.shadowOptions;if(void 0!==i){let t=e.shadowRoot;t?this.hasExistingShadowRoot=!0:(t=e.attachShadow(i),"closed"===i.mode&&to.set(e,t))}const n=di.getAccessors(e);if(n.length>0){const t=this.boundObservables=Object.create(null);for(let i=0,o=n.length;i<o;++i){const o=n[i].name,r=e[o];void 0!==r&&(delete e[o],t[o]=r)}}}get isConnected(){return di.track(this,eo),1===this.stage}get context(){var e,t;return null!==(t=null===(e=this.view)||void 0===e?void 0:e.context)&&void 0!==t?t:pi.default}get isBound(){var e,t;return null!==(t=null===(e=this.view)||void 0===e?void 0:e.isBound)&&void 0!==t&&t}get sourceLifetime(){var e;return null===(e=this.view)||void 0===e?void 0:e.sourceLifetime}get template(){var e;if(null===this._template){const t=this.definition;this.source.resolveTemplate?this._template=this.source.resolveTemplate():t.template&&(this._template=null!==(e=t.template)&&void 0!==e?e:null)}return this._template}set template(e){this._template!==e&&(this._template=e,this.needsInitialization||this.renderTemplate(e))}get mainStyles(){var e;if(null===this._mainStyles){const t=this.definition;this.source.resolveStyles?this._mainStyles=this.source.resolveStyles():t.styles&&(this._mainStyles=null!==(e=t.styles)&&void 0!==e?e:null)}return this._mainStyles}set mainStyles(e){this._mainStyles!==e&&(null!==this._mainStyles&&this.removeStyles(this._mainStyles),this._mainStyles=e,this.needsInitialization||this.addStyles(e))}onUnbind(e){var t;null===(t=this.view)||void 0===t||t.onUnbind(e)}addBehavior(e){var t,i;const n=null!==(t=this.behaviors)&&void 0!==t?t:this.behaviors=new Map,o=null!==(i=n.get(e))&&void 0!==i?i:0;0===o?(n.set(e,1),e.addedCallback&&e.addedCallback(this),!e.connectedCallback||this.guardBehaviorConnection||1!==this.stage&&0!==this.stage||e.connectedCallback(this)):n.set(e,o+1)}removeBehavior(e,t=!1){const i=this.behaviors;if(null===i)return;const n=i.get(e);void 0!==n&&(1===n||t?(i.delete(e),e.disconnectedCallback&&3!==this.stage&&e.disconnectedCallback(this),e.removedCallback&&e.removedCallback(this)):i.set(e,n-1))}addStyles(e){var t;if(!e)return;const i=this.source;if(e instanceof HTMLElement)(null!==(t=io(i))&&void 0!==t?t:this.source).append(e);else if(!e.isAttachedTo(i)){const t=e.behaviors;if(e.addStylesTo(i),null!==t)for(let e=0,i=t.length;e<i;++e)this.addBehavior(t[e])}}removeStyles(e){var t;if(!e)return;const i=this.source;if(e instanceof HTMLElement)(null!==(t=io(i))&&void 0!==t?t:i).removeChild(e);else if(e.isAttachedTo(i)){const t=e.behaviors;if(e.removeStylesFrom(i),null!==t)for(let e=0,i=t.length;e<i;++e)this.removeBehavior(t[e])}}connect(){if(3!==this.stage)return;if(this.stage=0,null!==this.boundObservables){const e=this.source,t=this.boundObservables,i=Object.keys(t);for(let n=0,o=i.length;n<o;++n){const o=i[n];e[o]=t[o]}this.boundObservables=null}const e=this.behaviors;if(null!==e){this.guardBehaviorConnection=!0;for(const t of e.keys())t.connectedCallback&&t.connectedCallback(this);this.guardBehaviorConnection=!1}this.needsInitialization?(this.renderTemplate(this.template),this.addStyles(this.mainStyles),this.needsInitialization=!1):null!==this.view&&this.view.bind(this.source),this.stage=1,di.notify(this,eo)}disconnect(){if(1!==this.stage)return;this.stage=2,di.notify(this,eo),null!==this.view&&this.view.unbind();const e=this.behaviors;if(null!==e)for(const t of e.keys())t.disconnectedCallback&&t.disconnectedCallback(this);this.stage=3}onAttributeChangedCallback(e,t,i){const n=this.definition.attributeLookup[e];void 0!==n&&n.onAttributeChangedCallback(this.source,i)}emit(e,t,i){return 1===this.stage&&this.source.dispatchEvent(new CustomEvent(e,Object.assign(Object.assign({detail:t},Qn),i)))}renderTemplate(e){var t;const i=this.source,n=null!==(t=io(i))&&void 0!==t?t:i;if(null!==this.view)this.view.dispose(),this.view=null;else if(!this.needsInitialization||this.hasExistingShadowRoot){this.hasExistingShadowRoot=!1;for(let e=n.firstChild;null!==e;e=n.firstChild)n.removeChild(e)}e&&(this.view=e.render(i,n,i),this.view.sourceLifetime=ci.coupled)}static forCustomElement(e){const t=e.$fastController;if(void 0!==t)return t;const i=Jn.getForInstance(e);if(void 0===i)throw qt.error(1401);return e.$fastController=new no(e,i)}static setStrategy(e){no=e}}function ro(e){var t;return"adoptedStyleSheets"in e?e:null!==(t=io(e))&&void 0!==t?t:e.getRootNode()}Qt(oo),oo.setStrategy(oo);class ao{constructor(e){const t=ao.styleSheetCache;this.sheets=e.map((e=>{if(e instanceof CSSStyleSheet)return e;let i=t.get(e);return void 0===i&&(i=new CSSStyleSheet,i.replaceSync(e),t.set(e,i)),i}))}addStylesTo(e){co(ro(e),this.sheets)}removeStylesFrom(e){uo(ro(e),this.sheets)}}ao.styleSheetCache=new Map;let so=0;function lo(e){return e===document?document.body:e}let co=(e,t)=>{e.adoptedStyleSheets=[...e.adoptedStyleSheets,...t]},uo=(e,t)=>{e.adoptedStyleSheets=e.adoptedStyleSheets.filter((e=>-1===t.indexOf(e)))};if(Ni.supportsAdoptedStyleSheets){try{document.adoptedStyleSheets.push(),document.adoptedStyleSheets.splice(),co=(e,t)=>{e.adoptedStyleSheets.push(...t)},uo=(e,t)=>{for(const i of t){const t=e.adoptedStyleSheets.indexOf(i);-1!==t&&e.adoptedStyleSheets.splice(t,1)}}}catch(e){}Ni.setDefaultStrategy(ao)}else Ni.setDefaultStrategy(class{constructor(e){this.styles=e,this.styleClass="fast-"+ ++so}addStylesTo(e){e=lo(ro(e));const t=this.styles,i=this.styleClass;for(let n=0;n<t.length;n++){const o=document.createElement("style");o.innerHTML=t[n],o.className=i,e.append(o)}}removeStylesFrom(e){const t=(e=lo(ro(e))).querySelectorAll(`.${this.styleClass}`);for(let i=0,n=t.length;i<n;++i)e.removeChild(t[i])}});function ho(e){const t=class extends e{constructor(){super(),oo.forCustomElement(this)}$emit(e,t,i){return this.$fastController.emit(e,t,i)}connectedCallback(){this.$fastController.connect()}disconnectedCallback(){this.$fastController.disconnect()}attributeChangedCallback(e,t,i){this.$fastController.onAttributeChangedCallback(e,t,i)}};return Jn.registerBaseType(t),t}const po=Object.assign(ho(HTMLElement),{from:function(e){return ho(e)},define:function(e,t){return Gt(e)?Jn.compose(e,t).define().type:Jn.compose(this,e).define().type},compose:function(e,t){return Gt(e)?Jn.compose(e,t):Jn.compose(this,e)}}),go="dropdown",fo="swatches";var mo=Object.defineProperty,vo=Object.getOwnPropertyDescriptor,yo=(e,t,i,n)=>{for(var o,r=n>1?void 0:n?vo(t,i):t,a=e.length-1;a>=0;a--)(o=e[a])&&(r=(n?o(t,i,r):o(r))||r);return n&&r&&mo(t,i,r),r};class Co extends po{constructor(){super(...arguments),this.type=go,this.size="medium",this.placeholderText="Select",this.selectedIndex=null,this.rowMaxItems=null,this.autoHideOverflowSwatches=!1,this.handleMenuOpenChange=e=>{this.open=e.detail.open}}itemsChanged(){this.items&&this.items.length>0&&this.selectedIndexHandler()}selectedIndexChanged(){this.selectedIndexHandler()}rowMaxItemsChanged(){this.updateRowMaxItems()}autoHideOverflowChanged(){this.updateRowMaxItems()}connectedCallback(){super.connectedCallback(),this.type===go?this.menuButtonRef.shadowRoot.querySelector("[slot='end']").style.flex="0 0 auto":this.type===fo&&this.updateRowMaxItems(),this.containerResizeObserver=new ResizeObserver((()=>{this.updateRowMaxItems()})),this.containerResizeObserver.observe(this.containerRef)}disconnectedCallback(){super.disconnectedCallback(),this.containerResizeObserver.unobserve(this.containerRef)}get getSelectedValue(){return void 0!==this._selected&&null!==this._selected&&void 0!==this.items&&this.items.length>=this._selected-1?this.items[this._selected].value:null}get getPlaceholderText(){return this.placeholderText}selectHandler(e){this._selected=this.items.map((e=>e.value)).indexOf(e.value),this.onselectionchange?.(e),this.$emit("filterchange",{selectedIndex:this._selected,item:e})}selectedIndexHandler(){this.items&&this.selectedIndex>=0&&this.selectedIndex<this.items.length&&(this._selected=this.selectedIndex)}updateRowMaxItems(){if(this.shadowRoot&&this.containerRef&&this.swatchesRef&&this.containerRef.clientWidth>0&&this.containerRef.clientWidth!==this.containerPreviousWidth){const e=this.swatchesRef.shadowRoot.querySelector("commerceui-swatch");this.itemsToFitPerRow=this.autoHideOverflowSwatches?Math.floor(this.containerRef.clientWidth/(e.clientWidth+8)):this.rowMaxItems,this.containerPreviousWidth=this.containerRef.clientWidth}}}yo([Wn({attribute:"type"})],Co.prototype,"type",2),yo([Wn],Co.prototype,"size",2),yo([Wn({attribute:"open"})],Co.prototype,"open",2),yo([Wn],Co.prototype,"label",2),yo([Wn({attribute:"show-label-value",mode:"boolean"})],Co.prototype,"showLabelValue",2),yo([Wn({attribute:"show-label-inline",mode:"boolean"})],Co.prototype,"showLabelInline",2),yo([Wn({attribute:"items"})],Co.prototype,"items",2),yo([Wn({attribute:"placeholder-text"})],Co.prototype,"placeholderText",2),yo([Wn({attribute:"hide-placeholder-text",mode:"boolean"})],Co.prototype,"hidePlaceholderText",2),yo([Wn({attribute:"selected-index",converter:jn})],Co.prototype,"selectedIndex",2),yo([Wn({attribute:"row-max-items",converter:jn})],Co.prototype,"rowMaxItems",2),yo([Wn({attribute:"auto-hide-overflow-swatches",mode:"boolean"})],Co.prototype,"autoHideOverflowSwatches",2),yo([ui],Co.prototype,"itemsToFitPerRow",2),yo([ui],Co.prototype,"_selected",2);const bo=Object.freeze({prefix:"commerceui",shadowRootMode:"open",registry:customElements});function So(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a}"function"==typeof SuppressedError&&SuppressedError;const xo="circle",To="square",wo="small",Oo="medium";class Po extends po{constructor(){super(...arguments),this.shape=To,this.size=Oo,this.rowMaxItems=null,this.selectedIndex=null,this.items=[],this.isExpanded=!1,this._rowMaxItems=null,this.handleExpandButtonClick=()=>{this.isExpanded=!this.isExpanded}}rowMaxItemsChanged(e,t){this._rowMaxItems=t&&t>1?this.rowMaxItems:null}selectedIndexChanged(){if(this.items){let e=this.items.slice();for(let t=0;t<e.length;t++)e.splice(t,1,{...e[t],selected:this.selectedIndex===t&&!e[t].disabled});this.items=e}}getVisibleSwatches(){if(!this.items)return;let e=this.items.slice();this._rowMaxItems&&this.items.length>this._rowMaxItems&&(e=this.items.slice(0,this._rowMaxItems-1));for(let t=0;t<e.length;t++)e[t].selected=this.selectedIndex===t&&!e[t].disabled;return e}getOverflowSwatches(){if(!this.items||this.items.length<=this._rowMaxItems||!this.isExpanded)return;let e=this.items.slice(this._rowMaxItems-1,this.items.length);for(let t=0;t<e.length;t++){const i=t+this._rowMaxItems-1;e[t].selected=this.selectedIndex===i&&!e[t].disabled}return e}handleSwatchClick(e){var t;if(e.disabled)return;const i=this.items.indexOf(e);i!==this.selectedIndex&&(this.selectedIndex=i,null===(t=this.onselectionchange)||void 0===t||t.call(this,e),this.$emit("change",e))}}So([Wn],Po.prototype,"shape",void 0),So([Wn],Po.prototype,"size",void 0),So([Wn({attribute:"row-max-items",converter:jn})],Po.prototype,"rowMaxItems",void 0),So([Wn({attribute:"selected-index",converter:jn})],Po.prototype,"selectedIndex",void 0),So([Wn],Po.prototype,"items",void 0),So([ui],Po.prototype,"isExpanded",void 0),So([ui],Po.prototype,"_rowMaxItems",void 0);const Ao="var(--colorNeutralForegroundStaticInverted)",Eo="var(--colorBrandForeground1)",ko="var(--colorNeutralStroke1)",Io="var(--borderRadiusMedium)",Do="var(--fontFamilyBase)",_o="var(--fontSizeBase300)",No="var(--lineHeightBase300)",Ro="var(--spacingHorizontalXXS)",Mo="var(--spacingVerticalXXS)",Lo=_o,Bo="var(--fontWeightRegular)",Fo="var(--fontWeightSemibold)",Uo=Zi`
:host {
display: block;
}
.container {
display: flex;
flex-wrap: wrap;
gap: ${"var(--spacingHorizontalS)"};
}
.expand-button {
background: transparent;
border: none;
padding: 0 0 ${Mo} ${Ro};
color: ${Eo};
font-family: ${Do};
font-size: ${Lo};
line-height: ${No};
font-weight: ${Bo};
text-align: start;
cursor: pointer;
}
:host([size=${wo}]) .expand-button {
min-width: 24px;
height: 24px;
}
:host([size=${Oo}]) .expand-button {
min-width: 32px;
height: 32px;
}
:host([aria-expanded="true"]) .expand-button {
padding: 0 0 ${Mo};
text-align: center;
}
`,Ho=(e,t)=>xn`<commerceui-swatch
shape=${t.shape}
size=${t.size}
selected=${e.selected}
@click=${()=>t.handleSwatchClick(e)}
:data=${e}
></commerceui-swatch>`,$o=xn`
<button class="expand-button" role="button" @click=${e=>e.handleExpandButtonClick()}>
${e=>e.isExpanded?"Less":"+"+(e.items.length-e.rowMaxItems+1)}
</button>
`,Zo=xn`
<template aria-expanded=${e=>e.isExpanded}>
<div id="swatches-container" class="container">
${Nn((e=>e.getVisibleSwatches()),xn`${(e,t)=>Ho(e,t.parent)}`)}
${Nn((e=>e.getOverflowSwatches()),xn`${(e,t)=>Ho(e,t.parent)}`)}
${An((e=>e.items&&e._rowMaxItems&&e.items.length>e.rowMaxItems),$o)}
</div>
</template>
`;xn`<commerceui-swatches
shape=${e=>e.shape}
size=${e=>e.size}
row-max-items=${e=>e.rowMaxItems}
selected-index=${e=>e.selectedIndex}
:items=${e=>e.items}
:onselectionchange=${e=>e.onselectionchange}
></commerceui-swatches>`,Po.compose({name:`${bo.prefix}-swatches`,template:Zo,styles:Uo}).define(bo.registry);class Vo extends po{constructor(){super(...arguments),this.shape=To,this.size=Oo}}So([Wn],Vo.prototype,"shape",void 0),So([Wn],Vo.prototype,"size",void 0),So([Wn],Vo.prototype,"data",void 0);const Go=Zi`
:host {
display: block;
}
:host([size=${wo}]) {
width: 24px;
height: 24px;
}
:host([size=${Oo}]) {
width: 32px;
height: 32px;
}
:host([size=${"large"}]) {
width: 40px;
height: 40px;
}
.swatch {
display: flex;
align-items: center;
justify-content: center;
width: 100%;
height: 100%;
margin: 0;
padding: 0;
background-color: ${Ao};
border: none;
box-sizing: border-box;
cursor: pointer;
}
.swatch[disabled] {
opacity: 0.4;
cursor: default;
pointer-events: none;
position: relative;
overflow: hidden;
}
.color {
width: 100%;
height: 100%;
border-radius: ${Io};
}
.swatch[disabled] .color {
opacity: 0.4;
}
.swatch[disabled]::before {
content: "";
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: linear-gradient(
to bottom right,
transparent 49%,
${ko} 49%,
${ko} 51%,
transparent 21%
);
z-index: 1;
}
.swatch,
.content,
:host([shape=${To}]) .swatch,
:host([shape=${To}]) .swatch .content {
border-radius: ${Io};
}
:host([shape=${xo}]) .swatch,
:host([shape=${xo}]) .content {
border-radius: 50%;
padding: unset;
}
.content {
width: 100%;
height: 100%;
border: 1px solid ${ko};
box-sizing: border-box;
overflow: hidden;
transition-property: width, height;
transition: 0.3s ${"var(--curveDecelerateMid)"};
padding: ${Ro};
}
.content img {
width: 100%;
height: 100%;
border-radius: ${Io};
background-color: ${Ao};
object-fit: contain;
}
.swatch:hover {
border: 1px solid ${"var(--colorNeutralStroke1Hover)"};
}
:host([selected]) .swatch {
outline: 2px solid ${Eo};
outline-offset: -2px;
}
:host([selected]) .swatch:focus-visible {
outline: 2px solid ${"var(--colorNeutralForeground1)"};
outline-offset: 2px;
}
.swatch:hover .content,
:host([selected]) .swatch .content {
width: calc(100% - 2px);
height: calc(100% - 2px);
border: none;
}
`,jo=xn`<button
class="swatch"
role="button"
type="button"
?disabled=${e=>e.data.disabled}
>
<div class="content">
${An((e=>e.data.imgSrc),xn`<img
src=${e=>e.data.imgSrc}
alt=${e=>e.data.imgAlt}
title=${e=>e.data.label}
/>`)}
${An((e=>!e.data.imgSrc),xn`<div
class="color"
style="background-color: ${e=>e.data.fill};"
></div>`)}
</div>
</button>`,zo=xn`
<template shape=${e=>e.shape} size=${e=>e.size} ?selected=${e=>e.data.selected}>
${jo}
</template>
`;function Wo(...e){return e.every((e=>e instanceof HTMLElement))}xn`<commerceui-swatch
shape=${e=>e.shape}
size=${e=>e.size}
:data=${e=>e.data}
:onclick=${e=>e.onclick}
></commerceui-swatch>`,Vo.compose({name:`${bo.prefix}-swatch`,template:zo,styles:Go}).define(bo.registry);const Ko="Enter",qo="Escape";var Yo=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};class Xo{}function Jo(e){return e?"string"==typeof e?new Cn(e):"inline"in e?e.inline():e:Cn.empty}function Qo(e){return`:host([hidden]){display:none}:host{display:${e}}`}Yo([Wn({attribute:"aria-atomic"})],Xo.prototype,"ariaAtomic",void 0),Yo([Wn({attribute:"aria-busy"})],Xo.prototype,"ariaBusy",void 0),Yo([Wn({attribute:"aria-controls"})],Xo.prototype,"ariaControls",void 0),Yo([Wn({attribute:"aria-current"})],Xo.prototype,"ariaCurrent",void 0),Yo([Wn({attribute:"aria-describedby"})],Xo.prototype,"ariaDescribedby",void 0),Yo([Wn({attribute:"aria-details"})],Xo.prototype,"ariaDetails",void 0),Yo([Wn({attribute:"aria-disabled"})],Xo.prototype,"ariaDisabled",void 0),Yo([Wn({attribute:"aria-errormessage"})],Xo.prototype,"ariaErrormessage",void 0),Yo([Wn({attribute:"aria-flowto"})],Xo.prototype,"ariaFlowto",void 0),Yo([Wn({attribute:"aria-haspopup"})],Xo.prototype,"ariaHaspopup",void 0),Yo([Wn({attribute:"aria-hidden"})],Xo.prototype,"ariaHidden",void 0),Yo([Wn({attribute:"aria-invalid"})],Xo.prototype,"ariaInvalid",void 0),Yo([Wn({attribute:"aria-keyshortcuts"})],Xo.prototype,"ariaKeyshortcuts",void 0),Yo([Wn({attribute:"aria-label"})],Xo.prototype,"ariaLabel",void 0),Yo([Wn({attribute:"aria-labelledby"})],Xo.prototype,"ariaLabelledby",void 0),Yo([Wn({attribute:"aria-live"})],Xo.prototype,"ariaLive",void 0),Yo([Wn({attribute:"aria-owns"})],Xo.prototype,"ariaOwns",void 0),Yo([Wn({attribute:"aria-relevant"})],Xo.prototype,"ariaRelevant",void 0),Yo([Wn({attribute:"aria-roledescription"})],Xo.prototype,"ariaRoledescription",void 0);class er{constructor(e){this.listenerCache=new WeakMap,this.query=e}connectedCallback(e){const{query:t}=this;let i=this.listenerCache.get(e);i||(i=this.constructListener(e),this.listenerCache.set(e,i)),i.bind(t)(),t.addEventListener("change",i)}disconnectedCallback(e){const t=this.listenerCache.get(e);t&&this.query.removeEventListener("change",t)}}class tr extends er{constructor(e,t){super(e),this.styles=t}static with(e){return t=>new tr(e,t)}constructListener(e){let t=!1;const i=this.styles;return function(){const{matches:n}=this;n&&!t?(e.addStyles(i),t=n):!n&&t&&(e.removeStyles(i),t=n)}}removedCallback(e){e.removeStyles(this.styles)}}const ir=tr.with(window.matchMedia("(forced-colors)"));tr.with(window.matchMedia("(prefers-color-scheme: dark)")),tr.with(window.matchMedia("(prefers-color-scheme: light)"));class nr{}function or(e){return xn` <slot name="end" ${wn("end")}>${Jo(e.end)}</slot> `.inline()}function rr(e){return xn` <slot name="start" ${wn("start")}>${Jo(e.start)}</slot> `.inline()}function ar(e,...t){const i=Zn.locate(e);t.forEach((t=>{Object.getOwnPropertyNames(t.prototype).forEach((i=>{"constructor"!==i&&Object.defineProperty(e.prototype,i,Object.getOwnPropertyDescriptor(t.prototype,i))})),Zn.locate(t).forEach((e=>i.push(e)))}))}const sr=Object.freeze({prefix:"fluent",shadowRootMode:"open",registry:customElements}),lr="var(--colorNeutralForeground1)",cr="var(--colorNeutralForeground2)",dr="var(--colorNeutralForeground2Hover)",ur="var(--colorNeutralForeground2Pressed)",hr="var(--colorNeutralForeground2BrandHover)",pr="var(--colorNeutralForeground2BrandPressed)",gr="var(--colorNeutralForegroundDisabled)",fr="var(--colorNeutralForegroundOnBrand)",mr="var(--colorNeutralBackground1)",vr="var(--colorNeutralBackground1Hover)",yr="var(--colorTransparentBackground)",Cr="var(--colorTransparentBackgroundHover)",br="var(--colorTransparentBackgroundPressed)",Sr="var(--colorNeutralBackgroundDisabled)",xr="var(--colorTransparentStroke)",Tr="var(--colorStrokeFocus2)",wr="var(--borderRadiusMedium)",Or="var(--fontFamilyBase)",Pr="var(--fontSizeBase200)",Ar="var(--fontSizeBase300)",Er="var(--fontSizeBase400)",kr="var(--fontWeightRegular)",Ir="var(--fontWeightSemibold)",Dr="var(--lineHeightBase200)",_r="var(--lineHeightBase300)",Nr="var(--lineHeightBase400)",Rr="var(--spacingHorizontalXS)",Mr="submit",Lr="reset",Br=Zi`
${Qo("inline-flex")}
:host {
--icon-spacing: ${"var(--spacingHorizontalSNudge)"};
contain: layout style;
vertical-align: middle;
}
:host .control {
display: inline-flex;
align-items: center;
box-sizing: border-box;
justify-content: center;
text-decoration-line: none;
margin: 0;
min-height: 32px;
outline-style: none;
background-color: ${mr};
color: ${lr};
border: ${"var(--strokeWidthThin)"} solid ${"var(--colorNeutralStroke1)"};
padding: 0 ${"var(--spacingHorizontalM)"};
min-width: 96px;
border-radius: ${wr};
font-size: ${Ar};
font-family: ${Or};
font-weight: ${Ir};
line-height: ${_r};
transition-duration: ${"var(--durationFaster)"};
transition-property: background, border, color;
transition-timing-function: ${"var(--curveEasyEase)"};
cursor: pointer;
}
.content {
display: inherit;
}
:host(:hover) .control {
background-color: ${vr};
color: ${"var(--colorNeutralForeground1Hover)"};
border-color: ${"var(--colorNeutralStroke1Hover)"};
}
:host(:hover:active) .control {
background-color: ${"var(--colorNeutralBackground1Pressed)"};
border-color: ${"var(--colorNeutralStroke1Pressed)"};
color: ${"var(--colorNeutralForeground1Pressed)"};
outline-style: none;
}
:host .control:focus-visible {
border-color: ${xr};
outline: ${"var(--strokeWidthThick)"}) solid ${xr};
box-shadow: ${"var(--shadow4)"}, 0 0 0 2px ${Tr};
}
@media screen and (prefers-reduced-motion: reduce) {
transition-duration: 0.01ms;
}
::slotted(svg) {
font-size: 20px;
height: 20px;
width: 20px;
fill: currentColor;
}
[slot='start'],
::slotted([slot='start']) {
margin-inline-end: var(--icon-spacing);
}
[slot='end'],
::slotted([slot='end']) {
margin-inline-start: var(--icon-spacing);
}
:host([icon-only]) .control {
min-width: 32px;
max-width: 32px;
}
:host([size='small']) {
--icon-spacing: ${Rr};
}
:host([size='small']) .control {
min-height: 24px;
min-width: 64px;
padding: 0 ${"var(--spacingHorizontalS)"};
border-radius: ${"var(--borderRadiusSmall)"};
font-size: ${Pr};
line-height: ${Dr};
font-weight: ${kr};
}
:host([size='small'][icon-only]) .control {
min-width: 24px;
max-width: 24px;
}
:host([size='large']) .control {
min-height: 40px;
border-radius: ${"var(--borderRadiusLarge)"};
padding: 0 ${"var(--spacingHorizontalL)"};
font-size: ${Er};
line-height: ${Nr};
}
:host([size='large'][icon-only]) .control {
min-width: 40px;
max-width: 40px;
}
:host([size='large']) ::slotted(svg) {
font-size: 24px;
height: 24px;
width: 24px;
}
:host([shape='circular']) .control,
:host([shape='circular']) .control:focus-visible {
border-radius: ${"var(--borderRadiusCircular)"};
}
:host([shape='square']) .control,
:host([shape='square']) .control:focus-visible {
border-radius: ${"var(--borderRadiusNone)"};
}
:host([appearance='primary']) .control {
background-color: ${"var(--colorBrandBackground)"};
color: ${fr};
border-color: transparent;
}
:host([appearance='primary']:hover) .control {
background-color: ${"var(--colorBrandBackgroundHover)"};
}
:host([appearance='primary']:hover) .control,
:host([appearance='primary']:hover:active) .control {
border-color: transparent;
color: ${fr};
}
:host([appearance='primary']:hover:active) .control {
background-color: ${"var(--colorBrandBackgroundPressed)"};
}
:host([appearance='primary']) .control:focus-visible {
border-color: ${fr};
box-shadow: ${"var(--shadow2)"}, 0 0 0 2px ${Tr};
}
:host(is:([disabled][appearance='primary'], [disabled-focusabale][appearance="primary"])) .control,
:host(is:([disabled][appearance='primary'], [disabled-focusabale][appearance="primary"]):hover) .control,
:host(is:([disabled][appearance='primary'], [disabled-focusabale][appearance="primary"]):hover:active) .control {
border-color: transparent;
}
:host([appearance='outline']) .control {
background-color: ${yr};
}
:host([appearance='outline']:hover) .control {
background-color: ${Cr};
}
:host([appearance='outline']:hover:active) .control {
background-color: ${br};
}
:host(is:([disabled][appearance='outline'], [disabled-focusabale][appearance="outline"])) .control,
:host(is:([disabled][appearance='outline'], [disabled-focusabale][appearance="outline"]):hover) .control,
:host(is:([disabled][appearance='outline'], [disabled-focusabale][appearance="outline"]):hover:active) .control {
background-color: ${yr};
}
:host([appearance='subtle']) .control {
background-color: ${"var(--colorSubtleBackground)"};
color: ${cr};
border-color: transparent;
}
:host([appearance='subtle']:hover) .control {
background-color: ${"var(--colorSubtleBackgroundHover)"};
color: ${dr};
border-color: transparent;
}
:host([appearance='subtle']:hover:active) .control {
background-color: ${"var(--colorSubtleBackgroundPressed)"};
color: ${ur};
border-color: transparent;
}
:host(is:([disabled][appearance='subtle'], [disabled-focusabale][appearance="subtle"])) .control,
:host(is:([disabled][appearance='subtle'], [disabled-focusabale][appearance="subtle"]):hover) .control,
:host(is:([disabled][appearance='subtle'], [disabled-focusabale][appearance="subtle"]):hover:active) .control {
background-color: ${yr};
border-color: transparent;
}
:host([appearance='subtle']:hover) ::slotted(svg) {
fill: ${hr};
}
:host([appearance='subtle']:hover:active) ::slotted(svg) {
fill: ${pr};
}
:host([appearance='transparent']) .control {
background-color: ${yr};
color: ${cr};
}
:host([appearance='transparent']:hover) .control {
background-color: ${Cr};
color: ${hr};
}
:host([appearance='transparent']:hover:active) .control {
background-color: ${br};
color: ${pr};
}
:host([appearance='transparent']) .control,
:host([appearance='transparent']:hover) .control,
:host([appearance='transparent']:hover:active) .control {
border-color: transparent;
}
:host(is:([disabled][appearance='transparent'], [disabled-focusabale][appearance="transparent"])) .control,
:host(is:([disabled][appearance='transparent'], [disabled-focusabale][appearance="transparent"]):hover) .control,
:host(is:([disabled][appearance='transparent'], [disabled-focusabale][appearance="transparent"]):hover:active) .control {
border-color: transparent;
background-color: ${yr};
}
:host(:is([disabled], [disabled-focusable], [appearance][disabled], [appearance][disabled-focusable])) .control,
:host(:is([disabled], [disabled-focusable], [appearance][disabled], [appearance][disabled-focusable]):hover) .control,
:host(:is([disabled], [disabled-focusable], [appearance][disabled], [appearance][disabled-focusable]):hover:active)
.control {
background-color: ${Sr};
border-color: ${"var(--colorNeutralStrokeDisabled)"};
color: ${gr};
cursor: not-allowed;
}
`.withBehaviors(ir(Zi`
:host([appearance='transparent']:hover) .control {
border-color: Highlight;
}
`)),Fr="form-associated-proxy",Ur="ElementInternals",Hr=Ur in window&&"setFormValue"in window[Ur].prototype,$r=new WeakMap;class Zr extends po{}class Vr extends(function(e){const t=class extends e{constructor(...e){super(...e),this.dirtyValue=!1,this.initialValue="",this.disabled=!1,this.proxyEventsToBlock=["change","click"],this.proxyInitialized=!1,this.required=!1,this.initialValue=this.initialValue||"",this.elementInternals||(this.formResetCallback=this.formResetCallback.bind(this))}static get formAssociated(){return Hr}get validity(){return this.elementInternals?this.elementInternals.validity:this.proxy.validity}get form(){return this.elementInternals?this.elementInternals.form:this.proxy.form}get validationMessage(){return this.elementInternals?this.elementInternals.validationMessage:this.proxy.validationMessage}get willValidate(){return this.elementInternals?this.elementInternals.willValidate:this.proxy.willValidate}get labels(){if(this.elementInternals)return Object.freeze(Array.from(this.elementInternals.labels));if(this.proxy instanceof HTMLElement&&this.proxy.ownerDocument&&this.id){const e=this.proxy.labels,t=Array.from(this.proxy.getRootNode().querySelectorAll(`[for='${this.id}']`)),i=e?t.concat(Array.from(e)):t;return Object.freeze(i)}return Yt}valueChanged(e,t){this.dirtyValue=!0,this.proxy instanceof HTMLElement&&(this.proxy.value=this.value),this.currentValue=this.value,this.setFormValue(this.value),this.validate()}currentValueChanged(){this.value=this.currentValue}initialValueChanged(e,t){this.dirtyValue||(this.value=this.initialValue,this.dirtyValue=!1)}disabledChanged(e,t){this.proxy instanceof HTMLElement&&(this.proxy.disabled=this.disabled),ai.enqueue((()=>this.classList.toggle("disabled",this.disabled)))}nameChanged(e,t){this.proxy instanceof HTMLElement&&(this.proxy.name=this.name)}requiredChanged(e,t){this.proxy instanceof HTMLElement&&(this.proxy.required=this.required),ai.enqueue((()=>this.classList.toggle("required",this.required))),this.validate()}get elementInternals(){if(!Hr)return null;let e=$r.get(this);return e||(e=this.attachInternals(),$r.set(this,e)),e}connectedCallback(){super.connectedCallback(),this.addEventListener("keypress",this._keypressHandler),this.value||(this.value=this.initialValue,this.dirtyValue=!1),this.elementInternals||(this.attachProxy(),this.form&&this.form.addEventListener("reset",this.formResetCallback))}disconnectedCallback(){this.proxyEventsToBlock.forEach((e=>this.proxy.removeEventListener(e,this.stopPropagation))),!this.elementInternals&&this.form&&this.form.removeEventListener("reset",this.formResetCallback)}checkValidity(){return this.elementInternals?this.elementInternals.checkValidity():this.proxy.checkValidity()}reportValidity(){return this.elementInternals?this.elementInternals.reportValidity():this.proxy.reportValidity()}setValidity(e,t,i){this.elementInternals?this.elementInternals.setValidity(e,t,i):"string"==typeof t&&this.proxy.setCustomValidity(t)}formDisabledCallback(e){this.disabled=e}formResetCallback(){this.value=this.initialValue,this.dirtyValue=!1}attachProxy(){var e;this.proxyInitialized||(this.proxyInitialized=!0,this.proxy.style.display="none",this.proxyEventsToBlock.forEach((e=>this.proxy.addEventListener(e,this.stopPropagation))),this.proxy.disabled=this.disabled,this.proxy.required=this.required,"string"==typeof this.name&&(this.proxy.name=this.name),"string"==typeof this.value&&(this.proxy.value=this.value),this.proxy.setAttribute("slot",Fr),this.proxySlot=document.createElement("slot"),this.proxySlot.setAttribute("name",Fr)),null===(e=this.shadowRoot)||void 0===e||e.appendChild(this.proxySlot),this.appendChild(this.proxy)}detachProxy(){var e;this.removeChild(this.proxy),null===(e=this.shadowRoot)||void 0===e||e.removeChild(this.proxySlot)}validate(e){this.proxy instanceof HTMLElement&&this.setValidity(this.proxy.validity,this.proxy.validationMessage,e)}setFormValue(e,t){this.elementInternals&&this.elementInternals.setFormValue(e,t||e)}_keypressHandler(e){if(e.key===Ko&&this.form instanceof HTMLFormElement){const e=this.form.querySelector("[type=submit]");null==e||e.click()}}stopPropagation(e){e.stopPropagation()}};return Wn({mode:"boolean"})(t.prototype,"disabled"),Wn({mode:"fromView",attribute:"value"})(t.prototype,"initialValue"),Wn({attribute:"current-value"})(t.prototype,"currentValue"),Wn(t.prototype,"name"),Wn({mode:"boolean"})(t.prototype,"required"),ui(t.prototype,"value"),t}(Zr)){constructor(){super(...arguments),this.proxy=document.createElement("input")}}var Gr=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};class jr extends Vr{constructor(){super(...arguments),this.iconOnly=!1,this.disabledFocusable=!1,this.handleDisabledFocusableClick=e=>{e&&this.disabledFocusable&&e.stopImmediatePropagation()},this.handleSubmission=()=>{if(!this.form)return;const e=this.proxy.isConnected;e||this.attachProxy(),"function"==typeof this.form.requestSubmit?this.form.requestSubmit(this.proxy):this.proxy.click(),e||this.detachProxy()},this.handleFormReset=()=>{var e;null===(e=this.form)||void 0===e||e.reset()}}formactionChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.formAction=this.formaction)}formenctypeChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.formEnctype=this.formenctype)}formmethodChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.formMethod=this.formmethod)}formnovalidateChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.formNoValidate=this.formnovalidate)}formtargetChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.formTarget=this.formtarget)}typeChanged(e,t){this.proxy instanceof HTMLInputElement&&(this.proxy.type=this.type),t===Mr&&this.addEventListener("click",this.handleSubmission),e===Mr&&this.removeEventListener("click",this.handleSubmission),t===Lr&&this.addEventListener("click",this.handleFormReset),e===Lr&&this.removeEventListener("click",this.handleFormReset)}disabledFocusableChanged(e,t){this.$fastController.isConnected&&(this.disabledFocusable?this.setAttribute("aria-disabled","true"):this.removeAttribute("aria-disabled"))}validate(){super.validate(this.control)}connectedCallback(){super.connectedCallback(),this.proxy.setAttribute("type",this.type),this.addEventListener("click",this.handleDisabledFocusableClick)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("click",this.handleDisabledFocusableClick)}}Gr([Wn({mode:"boolean"})],jr.prototype,"autofocus",void 0),Gr([Wn({attribute:"form"})],jr.prototype,"formId",void 0),Gr([Wn],jr.prototype,"formaction",void 0),Gr([Wn],jr.prototype,"formenctype",void 0),Gr([Wn],jr.prototype,"formmethod",void 0),Gr([Wn({mode:"boolean"})],jr.prototype,"formnovalidate",void 0),Gr([Wn],jr.prototype,"formtarget",void 0),Gr([Wn],jr.prototype,"type",void 0),Gr([Wn],jr.prototype,"appearance",void 0),Gr([Wn],jr.prototype,"shape",void 0),Gr([Wn],jr.prototype,"size",void 0),Gr([Wn({attribute:"icon-only",mode:"boolean"})],jr.prototype,"iconOnly",void 0),Gr([Wn({attribute:"disabled-focusable",mode:"boolean"})],jr.prototype,"disabledFocusable",void 0),Gr([ui],jr.prototype,"defaultSlottedContent",void 0);class zr{}function Wr(e={}){return xn`
<button
class="control"
part="control"
?autofocus="${e=>e.autofocus}"
?disabled="${e=>e.disabled}"
form="${e=>e.formId}"
formaction="${e=>e.formaction}"
formenctype="${e=>e.formenctype}"
formmethod="${e=>e.formmethod}"
?formnovalidate="${e=>e.formnovalidate}"
formtarget="${e=>e.formtarget}"
name="${e=>e.name}"
type="${e=>e.type}"
value="${e=>e.value}"
aria-atomic="${e=>e.ariaAtomic}"
aria-busy="${e=>e.ariaBusy}"
aria-controls="${e=>e.ariaControls}"
aria-current="${e=>e.ariaCurrent}"
aria-describedby="${e=>e.ariaDescribedby}"
aria-details="${e=>e.ariaDetails}"
aria-disabled="${e=>e.ariaDisabled}"
aria-errormessage="${e=>e.ariaErrormessage}"
aria-expanded="${e=>e.ariaExpanded}"
aria-flowto="${e=>e.ariaFlowto}"
aria-haspopup="${e=>e.ariaHaspopup}"
aria-hidden="${e=>e.ariaHidden}"
aria-invalid="${e=>e.ariaInvalid}"
aria-keyshortcuts="${e=>e.ariaKeyshortcuts}"
aria-label="${e=>e.ariaLabel}"
aria-labelledby="${e=>e.ariaLabelledby}"
aria-live="${e=>e.ariaLive}"
aria-owns="${e=>e.ariaOwns}"
aria-pressed="${e=>e.ariaPressed}"
aria-relevant="${e=>e.ariaRelevant}"
aria-roledescription="${e=>e.ariaRoledescription}"
${wn("control")}
>
${rr(e)}
<span class="content" part="content">
<slot ${Un("defaultSlottedContent")}></slot>
</span>
${or(e)}
</button>
`}Gr([Wn({attribute:"aria-expanded"})],zr.prototype,"ariaExpanded",void 0),Gr([Wn({attribute:"aria-pressed"})],zr.prototype,"ariaPressed",void 0),ar(zr,Xo),ar(jr,nr,zr),Wr();var Kr=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};class qr extends po{constructor(){super(...arguments),this.disabled=!1,this.required=!1}}Kr([Wn],qr.prototype,"size",void 0),Kr([Wn],qr.prototype,"weight",void 0),Kr([Wn({mode:"boolean"})],qr.prototype,"disabled",void 0),Kr([Wn({mode:"boolean"})],qr.prototype,"required",void 0);const Yr=Zi`
${Qo("flex")}
:host {
font-family: ${Or};
font-size: ${Ar};
line-height: ${_r};
font-weight: ${kr};
color: ${lr};
}
.asterisk {
color: ${"var(--colorPaletteRedForeground1)"};
margin-left: ${Rr};
}
:host([size='small']) {
font-size: ${Pr};
line-height: ${Dr};
}
:host([size='large']) {
font-size: ${Er};
line-height: ${Nr};
font-weight: ${Ir};
}
:host([weight='semibold']) {
font-weight: ${Ir};
}
:host([disabled]),
:host([disabled]) .asterisk {
color: ${gr};
}
`,Xr=xn`
<slot></slot>
<span part="asterisk" class="asterisk" ?hidden="${e=>!e.required}">*</span>
`,Jr=qr.compose({name:`${sr.prefix}-label`,template:Xr,styles:Yr}),Qr=["top","right","bottom","left"],ea=Math.min,ta=Math.max,ia=Math.round,na=Math.floor,oa=e=>({x:e,y:e}),ra={left:"right",right:"left",bottom:"top",top:"bottom"},aa={start:"end",end:"start"};function sa(e,t,i){return ta(e,ea(t,i))}function la(e,t){return"function"==typeof e?e(t):e}function ca(e){return e.split("-")[0]}function da(e){return e.split("-")[1]}function ua(e){return"x"===e?"y":"x"}function ha(e){return"y"===e?"height":"width"}function pa(e){return["top","bottom"].includes(ca(e))?"y":"x"}function ga(e){return ua(pa(e))}function fa(e){return e.replace(/start|end/g,(e=>aa[e]))}function ma(e){return e.replace(/left|right|bottom|top/g,(e=>ra[e]))}function va(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}function ya(e,t,i){let{reference:n,floating:o}=e;const r=pa(t),a=ga(t),s=ha(a),l=ca(t),c="y"===r,d=n.x+n.width/2-o.width/2,u=n.y+n.height/2-o.height/2,h=n[s]/2-o[s]/2;let p;switch(l){case"top":p={x:d,y:n.y-o.height};break;case"bottom":p={x:d,y:n.y+n.height};break;case"right":p={x:n.x+n.width,y:u};break;case"left":p={x:n.x-o.width,y:u};break;default:p={x:n.x,y:n.y}}switch(da(t)){case"start":p[a]-=h*(i&&c?-1:1);break;case"end":p[a]+=h*(i&&c?-1:1)}return p}async function Ca(e,t){var i;void 0===t&&(t={});const{x:n,y:o,platform:r,rects:a,elements:s,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:d="viewport",elementContext:u="floating",altBoundary:h=!1,padding:p=0}=la(t,e),g=function(e){return"number"!=typeof e?function(e){return{top:0,right:0,bottom:0,left:0,...e}}(e):{top:e,right:e,bottom:e,left:e}}(p),f=s[h?"floating"===u?"reference":"floating":u],m=va(await r.getClippingRect({element:null==(i=await(null==r.isElement?void 0:r.isElement(f)))||i?f:f.contextElement||await(null==r.getDocumentElement?void 0:r.getDocumentElement(s.floating)),boundary:c,rootBoundary:d,strategy:l})),v="floating"===u?{...a.floating,x:n,y:o}:a.reference,y=await(null==r.getOffsetParent?void 0:r.getOffsetParent(s.floating)),C=await(null==r.isElement?void 0:r.isElement(y))&&await(null==r.getScale?void 0:r.getScale(y))||{x:1,y:1},b=va(r.convertOffsetParentRelativeRectToViewportRelativeRect?await r.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:v,offsetParent:y,strategy:l}):v);return{top:(m.top-b.top+g.top)/C.y,bottom:(b.bottom-m.bottom+g.bottom)/C.y,left:(m.left-b.left+g.left)/C.x,right:(b.right-m.right+g.right)/C.x}}function ba(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Sa(e){return Qr.some((t=>e[t]>=0))}function xa(e){return Oa(e)?(e.nodeName||"").toLowerCase():"#document"}function Ta(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function wa(e){var t;return null==(t=(Oa(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function Oa(e){return e instanceof Node||e instanceof Ta(e).Node}function Pa(e){return e instanceof Element||e instanceof Ta(e).Element}function Aa(e){return e instanceof HTMLElement||e instanceof Ta(e).HTMLElement}function Ea(e){return"undefined"!=typeof ShadowRoot&&(e instanceof ShadowRoot||e instanceof Ta(e).ShadowRoot)}function ka(e){const{overflow:t,overflowX:i,overflowY:n,display:o}=Ra(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+i)&&!["inline","contents"].includes(o)}function Ia(e){return["table","td","th"].includes(xa(e))}function Da(e){const t=_a(),i=Ra(e);return"none"!==i.transform||"none"!==i.perspective||!!i.containerType&&"normal"!==i.containerType||!t&&!!i.backdropFilter&&"none"!==i.backdropFilter||!t&&!!i.filter&&"none"!==i.filter||["transform","perspective","filter"].some((e=>(i.willChange||"").includes(e)))||["paint","layout","strict","content"].some((e=>(i.contain||"").includes(e)))}function _a(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function Na(e){return["html","body","#document"].includes(xa(e))}function Ra(e){return Ta(e).getComputedStyle(e)}function Ma(e){return Pa(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function La(e){if("html"===xa(e))return e;const t=e.assignedSlot||e.parentNode||Ea(e)&&e.host||wa(e);return Ea(t)?t.host:t}function Ba(e){const t=La(e);return Na(t)?e.ownerDocument?e.ownerDocument.body:e.body:Aa(t)&&ka(t)?t:Ba(t)}function Fa(e,t,i){var n;void 0===t&&(t=[]),void 0===i&&(i=!0);const o=Ba(e),r=o===(null==(n=e.ownerDocument)?void 0:n.body),a=Ta(o);return r?t.concat(a,a.visualViewport||[],ka(o)?o:[],a.frameElement&&i?Fa(a.frameElement):[]):t.concat(o,Fa(o,[],i))}function Ua(e){const t=Ra(e);let i=parseFloat(t.width)||0,n=parseFloat(t.height)||0;const o=Aa(e),r=o?e.offsetWidth:i,a=o?e.offsetHeight:n,s=ia(i)!==r||ia(n)!==a;return s&&(i=r,n=a),{width:i,height:n,$:s}}function Ha(e){return Pa(e)?e:e.contextElement}function $a(e){const t=Ha(e);if(!Aa(t))return oa(1);const i=t.getBoundingClientRect(),{width:n,height:o,$:r}=Ua(t);let a=(r?ia(i.width):i.width)/n,s=(r?ia(i.height):i.height)/o;return a&&Number.isFinite(a)||(a=1),s&&Number.isFinite(s)||(s=1),{x:a,y:s}}const Za=oa(0);function Va(e){const t=Ta(e);return _a()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:Za}function Ga(e,t,i,n){void 0===t&&(t=!1),void 0===i&&(i=!1);const o=e.getBoundingClientRect(),r=Ha(e);let a=oa(1);t&&(n?Pa(n)&&(a=$a(n)):a=$a(e));const s=function(e,t,i){return void 0===t&&(t=!1),!(!i||t&&i!==Ta(e))&&t}(r,i,n)?Va(r):oa(0);let l=(o.left+s.x)/a.x,c=(o.top+s.y)/a.y,d=o.width/a.x,u=o.height/a.y;if(r){const e=Ta(r),t=n&&Pa(n)?Ta(n):n;let i=e,o=i.frameElement;for(;o&&n&&t!==i;){const e=$a(o),t=o.getBoundingClientRect(),n=Ra(o),r=t.left+(o.clientLeft+parseFloat(n.paddingLeft))*e.x,a=t.top+(o.clientTop+parseFloat(n.paddingTop))*e.y;l*=e.x,c*=e.y,d*=e.x,u*=e.y,l+=r,c+=a,i=Ta(o),o=i.frameElement}}return va({width:d,height:u,x:l,y:c})}const ja=[":popover-open",":modal"];function za(e){return ja.some((t=>{try{return e.matches(t)}catch(e){return!1}}))}function Wa(e){return Ga(wa(e)).left+Ma(e).scrollLeft}function Ka(e,t,i){let n;if("viewport"===t)n=function(e,t){const i=Ta(e),n=wa(e),o=i.visualViewport;let r=n.clientWidth,a=n.clientHeight,s=0,l=0;if(o){r=o.width,a=o.height;const e=_a();(!e||e&&"fixed"===t)&&(s=o.offsetLeft,l=o.offsetTop)}return{width:r,height:a,x:s,y:l}}(e,i);else if("document"===t)n=function(e){const t=wa(e),i=Ma(e),n=e.ownerDocument.body,o=ta(t.scrollWidth,t.clientWidth,n.scrollWidth,n.clientWidth),r=ta(t.scrollHeight,t.clientHeight,n.scrollHeight,n.clientHeight);let a=-i.scrollLeft+Wa(e);const s=-i.scrollTop;return"rtl"===Ra(n).direction&&(a+=ta(t.clientWidth,n.clientWidth)-o),{width:o,height:r,x:a,y:s}}(wa(e));else if(Pa(t))n=function(e,t){const i=Ga(e,!0,"fixed"===t),n=i.top+e.clientTop,o=i.left+e.clientLeft,r=Aa(e)?$a(e):oa(1);return{width:e.clientWidth*r.x,height:e.clientHeight*r.y,x:o*r.x,y:n*r.y}}(t,i);else{const i=Va(e);n={...t,x:t.x-i.x,y:t.y-i.y}}return va(n)}function qa(e,t){const i=La(e);return!(i===t||!Pa(i)||Na(i))&&("fixed"===Ra(i).position||qa(i,t))}function Ya(e,t,i){const n=Aa(t),o=wa(t),r="fixed"===i,a=Ga(e,!0,r,t);let s={scrollLeft:0,scrollTop:0};const l=oa(0);if(n||!n&&!r)if(("body"!==xa(t)||ka(o))&&(s=Ma(t)),n){const e=Ga(t,!0,r,t);l.x=e.x+t.clientLeft,l.y=e.y+t.clientTop}else o&&(l.x=Wa(o));return{x:a.left+s.scrollLeft-l.x,y:a.top+s.scrollTop-l.y,width:a.width,height:a.height}}function Xa(e,t){return Aa(e)&&"fixed"!==Ra(e).position?t?t(e):e.offsetParent:null}function Ja(e,t){const i=Ta(e);if(!Aa(e)||za(e))return i;let n=Xa(e,t);for(;n&&Ia(n)&&"static"===Ra(n).position;)n=Xa(n,t);return n&&("html"===xa(n)||"body"===xa(n)&&"static"===Ra(n).position&&!Da(n))?i:n||function(e){let t=La(e);for(;Aa(t)&&!Na(t);){if(Da(t))return t;t=La(t)}return null}(e)||i}const Qa={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:t,rect:i,offsetParent:n,strategy:o}=e;const r="fixed"===o,a=wa(n),s=!!t&&za(t.floating);if(n===a||s&&r)return i;let l={scrollLeft:0,scrollTop:0},c=oa(1);const d=oa(0),u=Aa(n);if((u||!u&&!r)&&(("body"!==xa(n)||ka(a))&&(l=Ma(n)),Aa(n))){const e=Ga(n);c=$a(n),d.x=e.x+n.clientLeft,d.y=e.y+n.clientTop}return{width:i.width*c.x,height:i.height*c.y,x:i.x*c.x-l.scrollLeft*c.x+d.x,y:i.y*c.y-l.scrollTop*c.y+d.y}},getDocumentElement:wa,getClippingRect:function(e){let{element:t,boundary:i,rootBoundary:n,strategy:o}=e;const r=[..."clippingAncestors"===i?function(e,t){const i=t.get(e);if(i)return i;let n=Fa(e,[],!1).filter((e=>Pa(e)&&"body"!==xa(e))),o=null;const r="fixed"===Ra(e).position;let a=r?La(e):e;for(;Pa(a)&&!Na(a);){const t=Ra(a),i=Da(a);i||"fixed"!==t.position||(o=null),(r?!i&&!o:!i&&"static"===t.position&&o&&["absolute","fixed"].includes(o.position)||ka(a)&&!i&&qa(e,a))?n=n.filter((e=>e!==a)):o=t,a=La(a)}return t.set(e,n),n}(t,this._c):[].concat(i),n],a=r[0],s=r.reduce(((e,i)=>{const n=Ka(t,i,o);return e.top=ta(n.top,e.top),e.right=ea(n.right,e.right),e.bottom=ea(n.bottom,e.bottom),e.left=ta(n.left,e.left),e}),Ka(t,a,o));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}},getOffsetParent:Ja,getElementRects:async function(e){const t=this.getOffsetParent||Ja,i=this.getDimensions;return{reference:Ya(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,...await i(e.floating)}}},getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){const{width:t,height:i}=Ua(e);return{width:t,height:i}},getScale:$a,isElement:Pa,isRTL:function(e){return"rtl"===Ra(e).direction}};function es(e,t,i,n){void 0===n&&(n={});const{ancestorScroll:o=!0,ancestorResize:r=!0,elementResize:a="function"==typeof ResizeObserver,layoutShift:s="function"==typeof IntersectionObserver,animationFrame:l=!1}=n,c=Ha(e),d=o||r?[...c?Fa(c):[],...Fa(t)]:[];d.forEach((e=>{o&&e.addEventListener("scroll",i,{passive:!0}),r&&e.addEventListener("resize",i)}));const u=c&&s?function(e,t){let i,n=null;const o=wa(e);function r(){var e;clearTimeout(i),null==(e=n)||e.disconnect(),n=null}return function a(s,l){void 0===s&&(s=!1),void 0===l&&(l=1),r();const{left:c,top:d,width:u,height:h}=e.getBoundingClientRect();if(s||t(),!u||!h)return;const p={rootMargin:-na(d)+"px "+-na(o.clientWidth-(c+u))+"px "+-na(o.clientHeight-(d+h))+"px "+-na(c)+"px",threshold:ta(0,ea(1,l))||1};let g=!0;function f(e){const t=e[0].intersectionRatio;if(t!==l){if(!g)return a();t?a(!1,t):i=setTimeout((()=>{a(!1,1e-7)}),100)}g=!1}try{n=new IntersectionObserver(f,{...p,root:o.ownerDocument})}catch(e){n=new IntersectionObserver(f,p)}n.observe(e)}(!0),r}(c,i):null;let h,p=-1,g=null;a&&(g=new ResizeObserver((e=>{let[n]=e;n&&n.target===c&&g&&(g.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame((()=>{var e;null==(e=g)||e.observe(t)}))),i()})),c&&!l&&g.observe(c),g.observe(t));let f=l?Ga(e):null;return l&&function t(){const n=Ga(e);!f||n.x===f.x&&n.y===f.y&&n.width===f.width&&n.height===f.height||i(),f=n,h=requestAnimationFrame(t)}(),i(),()=>{var e;d.forEach((e=>{o&&e.removeEventListener("scroll",i),r&&e.removeEventListener("resize",i)})),null==u||u(),null==(e=g)||e.disconnect(),g=null,l&&cancelAnimationFrame(h)}}const ts=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var i,n;const{placement:o,middlewareData:r,rects:a,initialPlacement:s,platform:l,elements:c}=t,{mainAxis:d=!0,crossAxis:u=!0,fallbackPlacements:h,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:g="none",flipAlignment:f=!0,...m}=la(e,t);if(null!=(i=r.arrow)&&i.alignmentOffset)return{};const v=ca(o),y=ca(s)===s,C=await(null==l.isRTL?void 0:l.isRTL(c.floating)),b=h||(y||!f?[ma(s)]:function(e){const t=ma(e);return[fa(e),t,fa(t)]}(s));h||"none"===g||b.push(...function(e,t,i,n){const o=da(e);let r=function(e,t,i){const n=["left","right"],o=["right","left"],r=["top","bottom"],a=["bottom","top"];switch(e){case"top":case"bottom":return i?t?o:n:t?n:o;case"left":case"right":return t?r:a;default:return[]}}(ca(e),"start"===i,n);return o&&(r=r.map((e=>e+"-"+o)),t&&(r=r.concat(r.map(fa)))),r}(s,f,g,C));const S=[s,...b],x=await Ca(t,m),T=[];let w=(null==(n=r.flip)?void 0:n.overflows)||[];if(d&&T.push(x[v]),u){const e=function(e,t,i){void 0===i&&(i=!1);const n=da(e),o=ga(e),r=ha(o);let a="x"===o?n===(i?"end":"start")?"right":"left":"start"===n?"bottom":"top";return t.reference[r]>t.floating[r]&&(a=ma(a)),[a,ma(a)]}(o,a,C);T.push(x[e[0]],x[e[1]])}if(w=[...w,{placement:o,overflows:T}],!T.every((e=>e<=0))){var O,P;const e=((null==(O=r.flip)?void 0:O.index)||0)+1,t=S[e];if(t)return{data:{index:e,overflows:w},reset:{placement:t}};let i=null==(P=w.filter((e=>e.overflows[0]<=0)).sort(((e,t)=>e.overflows[1]-t.overflows[1]))[0])?void 0:P.placement;if(!i)switch(p){case"bestFit":{var A;const e=null==(A=w.map((e=>[e.placement,e.overflows.filter((e=>e>0)).reduce(((e,t)=>e+t),0)])).sort(((e,t)=>e[1]-t[1]))[0])?void 0:A[0];e&&(i=e);break}case"initialPlacement":i=s}if(o!==i)return{reset:{placement:i}}}return{}}}},is=function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){const{placement:i,rects:n,platform:o,elements:r}=t,{apply:a=(()=>{}),...s}=la(e,t),l=await Ca(t,s),c=ca(i),d=da(i),u="y"===pa(i),{width:h,height:p}=n.floating;let g,f;"top"===c||"bottom"===c?(g=c,f=d===(await(null==o.isRTL?void 0:o.isRTL(r.floating))?"start":"end")?"left":"right"):(f=c,g="end"===d?"top":"bottom");const m=p-l[g],v=h-l[f],y=!t.middlewareData.shift;let C=m,b=v;if(u){const e=h-l.left-l.right;b=d||y?ea(v,e):e}else{const e=p-l.top-l.bottom;C=d||y?ea(m,e):e}if(y&&!d){const e=ta(l.left,0),t=ta(l.right,0),i=ta(l.top,0),n=ta(l.bottom,0);u?b=h-2*(0!==e||0!==t?e+t:ta(l.left,l.right)):C=p-2*(0!==i||0!==n?i+n:ta(l.top,l.bottom))}await a({...t,availableWidth:b,availableHeight:C});const S=await o.getDimensions(r.floating);return h!==S.width||p!==S.height?{reset:{rects:!0}}:{}}}},ns=(e,t,i)=>{const n=new Map,o={platform:Qa,...i},r={...o.platform,_c:n};return(async(e,t,i)=>{const{placement:n="bottom",strategy:o="absolute",middleware:r=[],platform:a}=i,s=r.filter(Boolean),l=await(null==a.isRTL?void 0:a.isRTL(t));let c=await a.getElementRects({reference:e,floating:t,strategy:o}),{x:d,y:u}=ya(c,n,l),h=n,p={},g=0;for(let i=0;i<s.length;i++){const{name:r,fn:f}=s[i],{x:m,y:v,data:y,reset:C}=await f({x:d,y:u,initialPlacement:n,placement:h,strategy:o,middlewareData:p,rects:c,platform:a,elements:{reference:e,floating:t}});d=null!=m?m:d,u=null!=v?v:u,p={...p,[r]:{...p[r],...y}},C&&g<=50&&(g++,"object"==typeof C&&(C.placement&&(h=C.placement),C.rects&&(c=!0===C.rects?await a.getElementRects({reference:e,floating:t,strategy:o}):C.rects),({x:d,y:u}=ya(c,h,l))),i=-1)}return{x:d,y:u,placement:h,strategy:o,middlewareData:p}})(e,t,{...o,platform:r})};var os=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};class rs extends po{constructor(){super(...arguments),this.openOnHover=!1,this.openOnContext=!1,this.closeOnScroll=!1,this.persistOnItemClick=!1,this.open=!1,this.slottedMenuList=[],this.slottedTriggers=[],this.toggleMenu=()=>{this.open?this.closeMenu():this.openMenu()},this.closeMenu=()=>{this.open=!1,this.closeOnScroll&&document.removeEventListener("scroll",this.closeMenu)},this.openMenu=e=>{this.open=!0,e&&this.openOnContext&&e.preventDefault(),this.closeOnScroll&&document.addEventListener("scroll",this.closeMenu)},this.setPositioningTask=()=>{this.setPositioning()},this.handleTriggerKeydown=e=>{if(!e.defaultPrevented)switch(e.key){case" ":case Ko:e.preventDefault(),this.toggleMenu(),this.open&&this.focusMenuList();break;default:return!0}},this.handleDocumentClick=e=>{!e||e.composedPath().includes(this._menuList)||e.composedPath().includes(this._trigger)||this.closeMenu()}}connectedCallback(){super.connectedCallback(),ai.enqueue((()=>this.setComponent()))}disconnectedCallback(){var e;super.disconnectedCallback(),null===(e=this.cleanup)||void 0===e||e.call(this),this.removeListeners()}setComponent(){this.$fastController.isConnected&&this.slottedMenuList.length&&this.slottedTriggers.length&&(this._trigger=this.slottedTriggers[0],this._menuList=this.slottedMenuList[0],this._trigger.setAttribute("aria-haspopup","true"),this._trigger.setAttribute("aria-expanded",`${this.open}`),this.addListeners())}focusMenuList(){this.open&&this._menuList&&ai.enqueue((()=>{this._menuList.focus()}))}focusTrigger(){!this.open&&this._trigger&&ai.enqueue((()=>{this._trigger.focus()}))}openChanged(e,t){var i;this.$fastController.isConnected&&this._trigger instanceof HTMLElement&&(this._trigger.setAttribute("aria-expanded",`${this.open}`),this._menuList&&this.open&&ai.enqueue(this.setPositioningTask)),null===(i=this.cleanup)||void 0===i||i.call(this),this.$emit("onOpenChange",{open:t})}openOnHoverChanged(e,t){var i,n;t?null===(i=this._trigger)||void 0===i||i.addEventListener("mouseover",this.openMenu):null===(n=this._trigger)||void 0===n||n.removeEventListener("mouseover",this.openMenu)}persistOnItemClickChanged(e,t){var i,n;t?null===(n=this._menuList)||void 0===n||n.removeEventListener("click",this.closeMenu):null===(i=this._menuList)||void 0===i||i.addEventListener("click",this.closeMenu)}openOnContextChanged(e,t){var i,n;t?null===(i=this._trigger)||void 0===i||i.addEventListener("contextmenu",this.openMenu):null===(n=this._trigger)||void 0===n||n.removeEventListener("contextmenu",this.openMenu)}closeOnScrollChanged(e,t){t?document.addEventListener("scroll",this.closeMenu):document.removeEventListener("scroll",this.closeMenu)}setPositioning(){this.$fastController.isConnected&&this._menuList&&this.open&&this._trigger&&(this.cleanup=es(this,this.positioningContainer,(async()=>{var e,t;const{middlewareData:i,x:n,y:o}=await ns(this._trigger,this.positioningContainer,{placement:"bottom",strategy:"fixed",middleware:[ts(),is({apply:({availableHeight:e,rects:t})=>{var i;(null===(i=this.positioningContainer)||void 0===i?void 0:i.style)&&Object.assign(this.positioningContainer.style,{maxHeight:`${e}px`,width:`${t.reference.width}px`})}}),(void 0===r&&(r={}),{name:"hide",options:r,async fn(e){const{rects:t}=e,{strategy:i="referenceHidden",...n}=la(r,e);switch(i){case"referenceHidden":{const i=ba(await Ca(e,{...n,elementContext:"reference"}),t.reference);return{data:{referenceHiddenOffsets:i,referenceHidden:Sa(i)}}}case"escaped":{const i=ba(await Ca(e,{...n,altBoundary:!0}),t.floating);return{data:{escapedOffsets:i,escaped:Sa(i)}}}default:return{}}}})]});var r;(null===(e=i.hide)||void 0===e?void 0:e.referenceHidden)?this.open=!1:(null===(t=this.positioningContainer)||void 0===t?void 0:t.style)&&Object.assign(this.positioningContainer.style,{position:"fixed",top:"0",left:"0",transform:`translate(${n}px, ${o}px)`})})))}addListeners(){var e,t,i,n,o;document.addEventListener("click",this.handleDocumentClick),null===(e=this._trigger)||void 0===e||e.addEventListener("keydown",this.handleTriggerKeydown),this.persistOnItemClick||null===(t=this._menuList)||void 0===t||t.addEventListener("click",this.closeMenu),this.openOnHover?null===(i=this._trigger)||void 0===i||i.addEventListener("mouseover",this.openMenu):this.openOnContext?null===(n=this._trigger)||void 0===n||n.addEventListener("contextmenu",this.openMenu):null===(o=this._trigger)||void 0===o||o.addEventListener("click",this.toggleMenu)}removeListeners(){var e,t,i,n,o;document.removeEventListener("click",this.handleDocumentClick),null===(e=this._trigger)||void 0===e||e.removeEventListener("keydown",this.handleTriggerKeydown),this.persistOnItemClick||null===(t=this._menuList)||void 0===t||t.removeEventListener("click",this.closeMenu),this.openOnHover&&(null===(i=this._trigger)||void 0===i||i.removeEventListener("mouseover",this.openMenu)),this.openOnContext?null===(n=this._trigger)||void 0===n||n.removeEventListener("contextmenu",this.openMenu):null===(o=this._trigger)||void 0===o||o.removeEventListener("click",this.toggleMenu)}handleMenuKeydown(e){if(!e.defaultPrevented)switch(e.key){case qo:e.preventDefault(),this.open&&(this.closeMenu(),this.focusTrigger());break;case"Tab":this.open&&this.closeMenu(),e.shiftKey&&this.focusTrigger();default:return!0}}}os([ui,Wn({attribute:"open-on-hover",mode:"boolean"})],rs.prototype,"openOnHover",void 0),os([ui,Wn({attribute:"open-on-context",mode:"boolean"})],rs.prototype,"openOnContext",void 0),os([ui,Wn({attribute:"close-on-scroll",mode:"boolean"})],rs.prototype,"closeOnScroll",void 0),os([ui,Wn({attribute:"persist-on-item-click",mode:"boolean"})],rs.prototype,"persistOnItemClick",void 0),os([ui,Wn({mode:"boolean"})],rs.prototype,"open",void 0),os([ui],rs.prototype,"slottedMenuList",void 0),os([ui],rs.prototype,"slottedTriggers",void 0);const as=xn`
<template
?open-on-hover="${e=>e.openOnHover}"
?open-on-context="${e=>e.openOnContext}"
?close-on-scroll="${e=>e.closeOnScroll}"
?persist-on-item-click="${e=>e.persistOnItemClick}"
@keydown="${(e,t)=>e.handleMenuKeydown(t.event)}"
>
<slot name="trigger" ${Un({property:"slottedTriggers",filter:Mn()})}></slot>
<span
${wn("positioningContainer")}
part="positioning-container"
class="positioning-container"
?hidden="${e=>!e.open}"
>
<slot ${Un({property:"slottedMenuList",filter:Mn()})}></slot>
</span>
</template>
`,ss=Zi`
:host {
position: relative;
z-index: var(--z-index-menu, 1);
}
.positioning-container {
position: fixed;
top: 0;
left: 0;
transform: translate(0, 0);
}
`,ls=rs.compose({name:`${sr.prefix}-menu`,template:as,styles:ss}),cs=Wr({end:xn.partial('<svg slot="end" fill="currentColor" aria-hidden="true" width="1em" height="1em" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path d="M15.85 7.65c.2.2.2.5 0 .7l-5.46 5.49a.55.55 0 0 1-.78 0L4.15 8.35a.5.5 0 1 1 .7-.7L10 12.8l5.15-5.16c.2-.2.5-.2.7 0Z" fill="currentColor"></path></svg>')}),ds=class extends jr{}.compose({name:`${sr.prefix}-menu-button`,template:cs,styles:Br,shadowOptions:{delegatesFocus:!0}}),us={menuitem:"menuitem",menuitemcheckbox:"menuitemcheckbox",menuitemradio:"menuitemradio"};var hs=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};class ps extends po{constructor(){super(...arguments),this.role=us.menuitem,this.checked=!1,this.focusSubmenuOnLoad=!1,this.handleMenuItemKeyDown=e=>{if(e.defaultPrevented)return!1;switch(e.key){case Ko:case" ":return this.invoke(),!1;case"ArrowRight":return this.expanded&&this.submenu?this.submenu.focus():this.expandAndFocus(),!1;case qo:case"ArrowLeft":if(this.expanded)return this.closeSubMenu(),!1}return!0},this.handleMenuItemClick=e=>(e.defaultPrevented||this.disabled||this.invoke(),!1),this.submenuLoaded=()=>{this.focusSubmenuOnLoad&&(this.focusSubmenuOnLoad=!1,this.submenu&&(this.submenu.focus(),this.setAttribute("tabindex","-1")))},this.handleMouseOver=e=>(this.disabled||!this.hasSubmenu||this.expanded||(this.expanded=!0),!1),this.handleMouseOut=e=>(!this.expanded||this.contains(document.activeElement)||(this.expanded=!1),!1),this.closeSubMenu=()=>{this.expanded=!1,this.focus()},this.expandAndFocus=()=>{this.hasSubmenu&&(this.focusSubmenuOnLoad=!0,this.expanded=!0)},this.invoke=()=>{if(!this.disabled)switch(this.role){case us.menuitemcheckbox:this.checked=!this.checked;break;case us.menuitem:if(this.hasSubmenu){this.expandAndFocus();break}this.$emit("change");break;case us.menuitemradio:this.checked||(this.checked=!0)}}}expandedChanged(e,t){this.$fastController.isConnected&&(t&&this.submenu&&this.updateSubmenu(),this.$emit("expanded-change",this,{bubbles:!1}))}checkedChanged(e,t){this.$fastController.isConnected&&this.$emit("change")}get hasSubmenu(){return!!this.submenu}slottedSubmenuChanged(e,t){t.length&&(this.submenu=t[0],this.updateSubmenu())}disconnectedCallback(){var e;null===(e=this.cleanup)||void 0===e||e.call(this),super.disconnectedCallback()}updateSubmenu(){var e;null===(e=this.cleanup)||void 0===e||e.call(this),this.submenu&&this.expanded&&ai.enqueue((()=>{this.cleanup=es(this,this.submenuContainer,(async()=>{const e=["left-start","right-start"],{x:t,y:i}=await ns(this,this.submenuContainer,{middleware:[(void 0===n&&(n={}),{name:"shift",options:n,async fn(e){const{x:t,y:i,placement:o}=e,{mainAxis:r=!0,crossAxis:a=!1,limiter:s={fn:e=>{let{x:t,y:i}=e;return{x:t,y:i}}},...l}=la(n,e),c={x:t,y:i},d=await Ca(e,l),u=pa(ca(o)),h=ua(u);let p=c[h],g=c[u];if(r){const e="y"===h?"bottom":"right";p=sa(p+d["y"===h?"top":"left"],p,p-d[e])}if(a){const e="y"===u?"bottom":"right";g=sa(g+d["y"===u?"top":"left"],g,g-d[e])}const f=s.fn({...e,[h]:p,[u]:g});return{...f,data:{x:f.x-t,y:f.y-i}}}}),is({apply:({availableWidth:t,rects:i})=>{t<i.floating.width&&e.push("bottom-end","top-end")}}),ts({fallbackPlacements:e})],placement:"right-start",strategy:"fixed"});var n;Object.assign(this.submenuContainer.style,{left:`${t}px`,position:"fixed",top:`${i}px`}),this.submenuLoaded()}))}))}}hs([Wn({mode:"boolean"})],ps.prototype,"disabled",void 0),hs([Wn({mode:"boolean"})],ps.prototype,"expanded",void 0),hs([Wn],ps.prototype,"role",void 0),hs([Wn({mode:"boolean"})],ps.prototype,"checked",void 0),hs([Wn({mode:"boolean"})],ps.prototype,"hidden",void 0),hs([ui],ps.prototype,"slottedSubmenu",void 0),hs([ui],ps.prototype,"submenu",void 0),ar(ps,nr);const gs=xn.partial('<svg fill="currentColor" class="___12fm75w f1w7gpdv fez10in fg4l7m0" aria-hidden="true" width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M14.05 3.49c.28.3.27.77-.04 1.06l-7.93 7.47A.85.85 0 014.9 12L2.22 9.28a.75.75 0 111.06-1.06l2.24 2.27 7.47-7.04a.75.75 0 011.06.04z" fill="currentColor"></path></svg>'),fs=function(e={}){return xn`
<template
aria-haspopup="${e=>e.hasSubmenu?"menu":void 0}"
aria-checked="${e=>e.role!==us.menuitem?e.checked:void 0}"
aria-disabled="${e=>e.disabled}"
aria-expanded="${e=>e.expanded}"
@keydown="${(e,t)=>e.handleMenuItemKeyDown(t.event)}"
@click="${(e,t)=>e.handleMenuItemClick(t.event)}"
@mouseover="${(e,t)=>e.handleMouseOver(t.event)}"
@mouseout="${(e,t)=>e.handleMouseOut(t.event)}"
>
${An((e=>e.role===us.menuitemcheckbox),xn`
<div part="input-container" class="input-container">
<span part="checkbox" class="checkbox">
<slot name="checkbox-indicator"> ${Jo(e.checkboxIndicator)} </slot>
</span>
</div>
`)}
${An((e=>e.role===us.menuitemradio),xn`
<div part="input-container" class="input-container">
<span part="radio" class="radio">
<slot name="radio-indicator"> ${Jo(e.radioIndicator)} </slot>
</span>
</div>
`)}
</div>
${rr(e)}
<span class="content" part="content">
<slot></slot>
</span>
${or(e)}
${An((e=>e.hasSubmenu),xn`
<div part="expand-collapse-glyph-container" class="expand-collapse-glyph-container">
<span part="expand-collapse" class="expand-collapse">
<slot name="expand-collapse-indicator"> ${Jo(e.expandCollapseGlyph)} </slot>
</span>
</div>
`)}
<span
?hidden="${e=>!e.expanded}"
class="submenu-container"
part="submenu-container"
${wn("submenuContainer")}
>
<slot name="submenu" ${Un({property:"slottedSubmenu",filter:Mn("[role='menu']")})}></slot>
</span>
</template>
`}({checkboxIndicator:gs,expandCollapseGlyph:xn.partial('<svg fill="currentColor" class="___12fm75w f1w7gpdv fez10in fg4l7m0" aria-hidden="true" width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M5.74 3.2a.75.75 0 00-.04 1.06L9.23 8 5.7 11.74a.75.75 0 101.1 1.02l4-4.25a.75.75 0 000-1.02l-4-4.25a.75.75 0 00-1.06-.04z" fill="currentColor"></path></svg>'),radioIndicator:gs}),ms=Zi`
${Qo("grid")}
:host {
grid-template-columns: 20px 20px auto 20px;
align-items: center;
grid-gap: 4px;
height: 32px;
background: ${mr};
font: ${kr} ${Ar} / ${_r} ${Or};
border-radius: ${wr};
color: ${cr};
padding: 0 10px;
cursor: pointer;
overflow: visible;
contain: layout;
}
:host(:hover) {
background: ${vr};
}
.content {
white-space: nowrap;
flex-grow: 1;
grid-column: auto / span 2;
padding: 0 2px;
}
.checkbox,
.radio {
display: none;
}
.input-container,
.expand-collapse-glyph-container,
::slotted([slot='start']),
::slotted([slot='end']),
:host([checked]) .checkbox,
:host([checked]) .radio {
display: inline-flex;
justify-content: center;
align-items: center;
color: ${cr};
}
.expand-collapse-glyph-container,
::slotted([slot='start']),
::slotted([slot='end']) {
height: 32px;
font-size: ${"var(--fontSizeBase500)"};
width: fit-content;
}
.input-container {
width: 20px;
}
::slotted([slot='end']) {
color: ${"var(--colorNeutralForeground3)"};
font: ${kr} ${Pr} / ${Dr} ${Or};
white-space: nowrap;
grid-column: 4 / span 1;
justify-self: flex-end;
}
.expand-collapse-glyph-container {
grid-column: 4 / span 1;
justify-self: flex-end;
}
:host(:hover) .input-container,
:host(:hover) .expand-collapse-glyph-container,
:host(:hover) .content {
color: ${dr};
}
:host([icon]:hover) ::slotted([slot='start']) {
color: ${"var(--colorCompoundBrandForeground1Hover)"};
}
:host(:active) {
background-color: ${"var(--colorNeutralBackground1Selected)"};
}
:host(:active) .input-container,
:host(:active) .expand-collapse-glyph-container,
:host(:active) .content {
color: ${ur};
}
:host(:active) ::slotted([slot='start']) {
color: ${"var(--colorCompoundBrandForeground1Pressed)"};
}
:host([disabled]) {
background-color: ${Sr};
}
:host([disabled]) .content,
:host([disabled]) .expand-collapse-glyph-container,
:host([disabled]) ::slotted([slot='end']),
:host([disabled]) ::slotted([slot='start']) {
color: ${gr};
}
:host([data-indent]) {
display: grid;
}
:host([data-indent='1']) .content {
grid-column: 2 / span 1;
}
:host([data-indent='1'][role='menuitemcheckbox']) {
display: grid;
}
:host([data-indent='2'][aria-haspopup='menu']) ::slotted([slot='end']) {
grid-column: 4 / span 1;
}
:host([data-indent='2'][aria-haspopup='menu']) .expand-collapse-glyph-container {
grid-column: 5 / span 1;
}
:host([data-indent='1']) .content {
grid-column: 2 / span 1;
}
:host([data-indent='1'][role='menuitemcheckbox']) .content,
:host([data-indent='1'][role='menuitemradio']) .content {
grid-column: auto / span 1;
}
:host([icon]) ::slotted([slot='end']),
:host([data-indent='1']) ::slotted([slot='end']) {
grid-column: 4 / span 1;
justify-self: flex-end;
}
:host([data-indent='2']) {
display: grid;
grid-template-columns: 20px 20px auto auto;
}
:host([data-indent='2']) .content {
grid-column: 3 / span 1;
}
:host([data-indent='2']) .input-container {
grid-column: 1 / span 1;
}
:host([data-indent='2']) ::slotted([slot='start']) {
grid-column: 2 / span 1;
}
:host([aria-haspopup='menu']) {
grid-template-columns: 20px auto auto 20px;
}
:host([data-indent='2'][aria-haspopup='menu']) {
grid-template-columns: 20px 20px auto auto 20px;
}
:host([aria-haspopup='menu']) ::slotted([slot='end']) {
grid-column: 3 / span 1;
justify-self: flex-end;
}
:host([data-indent='2'][aria-haspopup='menu']) ::slotted([slot='end']) {
grid-column: 4 / span 1;
justify-self: flex-end;
}
`,vs=ps.compose({name:`${sr.prefix}-menu-item`,template:fs,styles:ms});class ys extends po{constructor(){super(...arguments),this.expandedItem=null,this.focusIndex=-1,this.isNestedMenu=()=>null!==this.parentElement&&Wo(this.parentElement)&&"menuitem"===this.parentElement.getAttribute("role"),this.handleFocusOut=e=>{if(!this.contains(e.relatedTarget)&&void 0!==this.menuItems){this.collapseExpandedItem();const e=this.menuItems.findIndex(this.isFocusableElement);this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.menuItems[e].setAttribute("tabindex","0"),this.focusIndex=e}},this.handleItemFocus=e=>{const t=e.target;void 0!==this.menuItems&&t!==this.menuItems[this.focusIndex]&&(this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.focusIndex=this.menuItems.indexOf(t),t.setAttribute("tabindex","0"))},this.handleExpandedChanged=e=>{if(e.defaultPrevented||null===e.target||void 0===this.menuItems||this.menuItems.indexOf(e.target)<0)return;e.preventDefault();const t=e.target;null===this.expandedItem||t!==this.expandedItem||!1!==t.expanded?t.expanded&&(null!==this.expandedItem&&this.expandedItem!==t&&(this.expandedItem.expanded=!1),this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.expandedItem=t,this.focusIndex=this.menuItems.indexOf(t),t.setAttribute("tabindex","0")):this.expandedItem=null},this.changeHandler=e=>{if(void 0===this.menuItems)return;const t=e.target,i=this.menuItems.indexOf(t);if(-1!==i&&"menuitemradio"===t.role&&!0===t.checked){for(let e=i-1;e>=0;--e){const t=this.menuItems[e],i=t.getAttribute("role");if(i===us.menuitemradio&&(t.checked=!1),"separator"===i)break}const e=this.menuItems.length-1;for(let t=i+1;t<=e;++t){const e=this.menuItems[t],i=e.getAttribute("role");if(i===us.menuitemradio&&(e.checked=!1),"separator"===i)break}}},this.isMenuItemElement=e=>e instanceof ps||Wo(e)&&e.getAttribute("role")in ys.focusableElementRoles,this.isFocusableElement=e=>this.isMenuItemElement(e)}itemsChanged(e,t){this.$fastController.isConnected&&void 0!==this.menuItems&&this.setItems()}connectedCallback(){super.connectedCallback(),ai.enqueue((()=>{this.setItems()})),this.addEventListener("change",this.changeHandler)}disconnectedCallback(){super.disconnectedCallback(),this.removeItemListeners(),this.menuItems=void 0,this.removeEventListener("change",this.changeHandler)}focus(){this.setFocus(0,1)}collapseExpandedItem(){null!==this.expandedItem&&(this.expandedItem.expanded=!1,this.expandedItem=null)}handleMenuKeyDown(e){if(!e.defaultPrevented&&void 0!==this.menuItems)switch(e.key){case"ArrowDown":return void this.setFocus(this.focusIndex+1,1);case"ArrowUp":return void this.setFocus(this.focusIndex-1,-1);case"End":return void this.setFocus(this.menuItems.length-1,-1);case"Home":return void this.setFocus(0,1);default:return!0}}removeItemListeners(e=this.items){e.forEach((e=>{e.removeEventListener("focus",this.handleItemFocus),e.removeEventListener("expanded-changed",this.handleExpandedChanged),di.getNotifier(e).unsubscribe(this,"hidden")}))}static elementIndent(e){const t=e.getAttribute("role"),i=e.querySelector("[slot=start]");return t&&t!==us.menuitem?i?2:1:i?1:0}setItems(){var e;const t=Array.from(this.children);this.removeItemListeners(t),t.forEach((e=>di.getNotifier(e).subscribe(this,"hidden")));const i=t.filter((e=>!e.hasAttribute("hidden")));this.menuItems=i;const n=this.menuItems.filter(this.isMenuItemElement);n.length&&(this.focusIndex=0),n.forEach(((e,t)=>{e.setAttribute("tabindex",0===t?"0":"-1"),e.addEventListener("expanded-change",this.handleExpandedChanged),e.addEventListener("focus",this.handleItemFocus)}));const o=null===(e=this.menuItems)||void 0===e?void 0:e.filter(this.isMenuItemElement);null==o||o.forEach(((e,t)=>{const i=null==o?void 0:o.reduce(((e,t)=>{const i=ys.elementIndent(t);return Math.max(e,i)}),0);e instanceof ps&&e.setAttribute("data-indent",`${i}`)}))}handleChange(e,t){"hidden"===t&&this.setItems()}setFocus(e,t){if(void 0!==this.menuItems)for(;e>=0&&e<this.menuItems.length;){const i=this.menuItems[e];if(this.isFocusableElement(i)){this.focusIndex>-1&&this.menuItems.length>=this.focusIndex-1&&this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.focusIndex=e,i.setAttribute("tabindex","0"),i.focus();break}e+=t}}}ys.focusableElementRoles=us,function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);r>3&&a&&Object.defineProperty(t,i,a)}([ui],ys.prototype,"items",void 0);const Cs=xn`
<template
slot="${e=>e.slot?e.slot:e.isNestedMenu()?"submenu":void 0}"
role="menu"
@keydown="${(e,t)=>e.handleMenuKeyDown(t.event)}"
@focusout="${(e,t)=>e.handleFocusOut(t.event)}"
>
<slot ${Un("items")}></slot>
</template>
`,bs=Zi`
${Qo("flex")}
:host {
flex-direction: column;
height: fit-content;
max-width: 300px;
min-width: 160px;
width: auto;
background-color: ${mr};
border: 1px solid ${xr};
border-radius: ${wr};
box-shadow: ${"var(--shadow16)"};
padding: 4px;
row-gap: 2px;
}
`,Ss=ys.compose({name:`${sr.prefix}-menu-list`,template:Cs,styles:bs});Jr.name="fluent-beta-label",Jr.define(customElements),ls.name="fluent-beta-menu",ls.define(customElements),ds.name="fluent-beta-menu-button",ds.define(customElements),Ss.name="fluent-beta-menu-list",Ss.define(customElements),vs.name="fluent-beta-menu-item",vs.define(customElements);const xs=xn`
<div class="container" ${wn("containerRef")}>
${An((e=>!e.showLabelInline),xn`<fluent-beta-label
><span class="label">${e=>e.label}</span>
${An((e=>e.showLabelValue),xn`<span class="label-value">${e=>e.getSelectedValue}</span>`)}
</fluent-beta-label>`)}
${An((e=>e.type===go),xn`
<fluent-beta-menu
open=${e=>e.open}
@onOpenChange=${(e,t)=>e.handleMenuOpenChange(t.event)}
>
<fluent-beta-menu-button
class="menu-button"
appearance="outline"
slot="trigger"
size=${e=>e.size}
${wn("menuButtonRef")}
>${An((e=>!e.getSelectedValue&&!e.hidePlaceholderText),xn`<span class="placeholder">${e=>e.getPlaceholderText}</span>`)}
${An((e=>e.getSelectedValue),xn`
${An((e=>e.showLabelInline),xn`<span class="label">${e=>e.label}</span>`)}
<span class="label-value">${e=>e.getSelectedValue}</span>
`)}
</fluent-beta-menu-button>
<fluent-beta-menu-list class="menu-list">
${Nn((e=>e.items),xn`<fluent-beta-menu-item
class="menu-item"
?disabled=${e=>e.disabled}
@change=${(e,t)=>t.parent.selectHandler(e)}
><div class="menu-item-label">${e=>e.label}</div></fluent-beta-menu-item
>`)}
</fluent-beta-menu-list>
</fluent-beta-menu>
`)}
${An((e=>e.type===fo),xn`
<commerceui-swatches
${wn("swatchesRef")}
:items=${e=>e.items}
size=${e=>e.size}
selected-index=${e=>e.selectedIndex}
row-max-items=${e=>e.itemsToFitPerRow}
@change=${(e,t)=>{e.selectHandler(t.event.detail)}}
></commerceui-swatches>
`)}
</div>
`;xn`<commerceui-filter
:items=${e=>e.items}
type=${e=>e.type}
label=${e=>e.label}
show-label-value=${e=>e.showLabelValue}
selected-index=${e=>e.selectedIndex}
placeholder-text=${e=>e.placeholderText}
auto-hide-overflow-swatches=${e=>e.autoHideOverflowSwatches}
hide-placeholder-text=${e=>e.hidePlaceholderText}
show-label-value=${e=>e.showLabelValue}
show-label-inline=${e=>e.showLabelInline}
open=${e=>e.open}
row-max-items=${e=>e.rowMaxItems}
size=${e=>e.size}
:onselectionchange=${e=>e.onselectionchange}
></commerceui-filter>`;const Ts=Zi`
:host {
overflow: hidden;
}
.container {
display: flex;
flex-direction: column;
align-items: flex-start;
row-gap: ${"var(--spacingVerticalXS)"};
}
.placeholder {
color: ${"var(--colorNeutralForeground4)"};
font-family: ${Do};
font-size: ${Lo};
font-weight: ${Bo};
}
fluent-beta-label {
max-width: 100%;
}
.label {
font-weight: ${Fo};
}
.label-value {
margin-inline-start: ${"var(--spacingHorizontalXS)"};
font-weight: ${Bo};
}
fluent-beta-menu {
max-width: 100%;
}
fluent-beta-menu[open="true"] {
z-index: 2;
}
fluent-beta-menu-button {
max-width: 100%;
}
.menu-button::part(control) {
flex: 1;
min-width: 0;
width: max-content;
background-color: ${"var(--colorNeutralBackground1)"};
}
.label,
.menu-button::part(content),
.menu-button .label-value {
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
}
fluent-beta-menu-list {
width: fit-content;
min-width: fit-content;
max-width: fit-content;
}
fluent-beta-menu-item {
grid-template-columns: auto;
}
fluent-beta-menu-item[disabled] {
pointer-events: none;
background: none;
}
fluent-beta-menu-item .menu-item-label {
overflow: hidden;
text-overflow: ellipsis;
}
`,ws=Object.freeze({prefix:"commerceui",shadowRootMode:"open",registry:customElements}),Os=(Co.compose({name:`${ws.prefix}-filter`,template:xs,styles:Ts}),Te`
:host .slot-filter-group {
display: flex;
flex-wrap: wrap;
row-gap: ${Je};
column-gap: ${Ke};
}
:host([inline-swatches]:not([auto-hide-overflow-swatches])) .slot-filter-group {
flex-wrap: nowrap;
}
:host([direction=${"column"}]) .slot-filter-group {
flex-direction: column;
}
:host([direction=${de}]) .slot-filter-group {
flex-direction: row;
}
commerceui-filter[type=${fo}] {
flex-basis: 100%;
}
:host([inline-swatches]:not([auto-hide-overflow-swatches])) commerceui-filter[type=${fo}] {
flex-basis: content;
}
`);class Ps{constructor(e,t,i){this.index=e,this.removed=t,this.addedCount=i}adjustTo(e){let t=this.index;const i=e.length;return t>i?t=i-this.addedCount:t<0&&(t=i+this.removed.length+t-this.addedCount),this.index=t<0?0:t,this}}const As=Object.freeze({reset:1,splice:2,optimized:3}),Es=new Ps(0,f,0);Es.reset=!0;const ks=[Es];function Is(e,t,i,n,o,r){let a=0,s=0;const l=Math.min(i-t,r-o);if(0===t&&0===o&&(a=function(e,t,i){for(let n=0;n<i;++n)if(e[n]!==t[n])return n;return i}(e,n,l)),i===e.length&&r===n.length&&(s=function(e,t,i){let n=e.length,o=t.length,r=0;for(;r<i&&e[--n]===t[--o];)r++;return r}(e,n,l-a)),o+=a,r-=s,(i-=s)-(t+=a)==0&&r-o==0)return f;if(t===i){const e=new Ps(t,[],0);for(;o<r;)e.removed.push(n[o++]);return[e]}if(o===r)return[new Ps(t,[],i-t)];const c=function(e){let t=e.length-1,i=e[0].length-1,n=e[t][i];const o=[];for(;t>0||i>0;){if(0===t){o.push(2),i--;continue}if(0===i){o.push(3),t--;continue}const r=e[t-1][i-1],a=e[t-1][i],s=e[t][i-1];let l;l=a<s?a<r?a:r:s<r?s:r,l===r?(r===n?o.push(0):(o.push(1),n=r),t--,i--):l===a?(o.push(3),t--,n=a):(o.push(2),i--,n=s)}return o.reverse()}(function(e,t,i,n,o,r){const a=r-o+1,s=i-t+1,l=new Array(a);let c,d;for(let e=0;e<a;++e)l[e]=new Array(s),l[e][0]=e;for(let e=0;e<s;++e)l[0][e]=e;for(let i=1;i<a;++i)for(let r=1;r<s;++r)e[t+r-1]===n[o+i-1]?l[i][r]=l[i-1][r-1]:(c=l[i-1][r]+1,d=l[i][r-1]+1,l[i][r]=c<d?c:d);return l}(e,t,i,n,o,r)),d=[];let u,h=t,p=o;for(let e=0;e<c.length;++e)switch(c[e]){case 0:void 0!==u&&(d.push(u),u=void 0),h++,p++;break;case 1:void 0===u&&(u=new Ps(h,[],0)),u.addedCount++,h++,u.removed.push(n[p]),p++;break;case 2:void 0===u&&(u=new Ps(h,[],0)),u.addedCount++,h++;break;case 3:void 0===u&&(u=new Ps(h,[],0)),u.removed.push(n[p]),p++}return void 0!==u&&d.push(u),d}function Ds(e,t){let i=!1,n=0;for(let l=0;l<t.length;l++){const c=t[l];if(c.index+=n,i)continue;const d=(o=e.index,r=e.index+e.removed.length,a=c.index,s=c.index+c.addedCount,r<a||s<o?-1:r===a||s===o?0:o<a?r<s?r-a:s-a:s<r?s-o:r-o);if(d>=0){t.splice(l,1),l--,n-=c.addedCount-c.removed.length,e.addedCount+=c.addedCount-d;const o=e.removed.length+c.removed.length-d;if(e.addedCount||o){let t=c.removed;if(e.index<c.index){const i=e.removed.slice(0,c.index-e.index);i.push(...t),t=i}if(e.index+e.removed.length>c.index+c.addedCount){const i=e.removed.slice(c.index+c.addedCount-e.index);t.push(...i)}e.removed=t,c.index<e.index&&(e.index=c.index)}else i=!0}else if(e.index<c.index){i=!0,t.splice(l,0,e),l++;const o=e.addedCount-e.removed.length;c.index+=o,n+=o}}var o,r,a,s;i||t.push(e)}let _s=Object.freeze({support:As.optimized,normalize(e,t,i){return void 0===e?void 0===i?f:function(e,t){let i=[];const n=[];for(let e=0,i=t.length;e<i;e++)Ds(t[e],n);for(let t=0,o=n.length;t<o;++t){const o=n[t];1!==o.addedCount||1!==o.removed.length?i=i.concat(Is(e,o.index,o.index+o.addedCount,o.removed,0,o.removed.length)):o.removed[0]!==e[o.index]&&i.push(o)}return i}(t,i):ks},pop(e,t,i,n){const o=e.length>0,r=i.apply(e,n);return o&&t.addSplice(new Ps(e.length,[r],0)),r},push(e,t,i,n){const o=i.apply(e,n);return t.addSplice(new Ps(e.length-n.length,[],n.length).adjustTo(e)),o},reverse(e,t,i,n){const o=i.apply(e,n);return t.reset(e),o},shift(e,t,i,n){const o=e.length>0,r=i.apply(e,n);return o&&t.addSplice(new Ps(0,[r],0)),r},sort(e,t,i,n){const o=i.apply(e,n);return t.reset(e),o},splice(e,t,i,n){const o=i.apply(e,n);return t.addSplice(new Ps(+n[0],o,n.length>2?n.length-2:0).adjustTo(e)),o},unshift(e,t,i,n){const o=i.apply(e,n);return t.addSplice(new Ps(0,[],n.length).adjustTo(e)),o}});function Ns(e,t,i){Reflect.defineProperty(e,t,{value:i,enumerable:!1})}Object.freeze({reset:ks,setDefaultStrategy(e){_s=e}});class Rs extends u{constructor(e){super(e),this.oldCollection=void 0,this.splices=void 0,this.needsQueue=!0,this._strategy=null,this._lengthObserver=void 0,this.call=this.flush,Ns(e,"$fastController",this)}get strategy(){return this._strategy}set strategy(e){this._strategy=e}get lengthObserver(){let e=this._lengthObserver;if(void 0===e){const t=this.subject;this._lengthObserver=e={length:t.length,handleChange(){this.length!==t.length&&(this.length=t.length,S.notify(e,"length"))}},this.subscribe(e)}return e}subscribe(e){this.flush(),super.subscribe(e)}addSplice(e){void 0===this.splices?this.splices=[e]:this.splices.push(e),this.enqueue()}reset(e){this.oldCollection=e,this.enqueue()}flush(){var e;const t=this.splices,i=this.oldCollection;void 0===t&&void 0===i||(this.needsQueue=!0,this.splices=void 0,this.oldCollection=void 0,this.notify((null!==(e=this._strategy)&&void 0!==e?e:_s).normalize(i,this.subject,t)))}enqueue(){this.needsQueue&&(this.needsQueue=!1,C.enqueue(this))}}let Ms=!1;const Ls=Object.freeze({enable(){if(Ms)return;Ms=!0,S.setArrayObserverFactory((e=>new Rs(e)));const e=Array.prototype;e.$fastPatch||(Ns(e,"$fastPatch",1),[e.pop,e.push,e.reverse,e.shift,e.sort,e.splice,e.unshift].forEach((t=>{e[t.name]=function(...e){var i;const n=this.$fastController;return void 0===n?t.apply(this,e):(null!==(i=n.strategy)&&void 0!==i?i:_s)[t.name](this,n,t,e)}})))}});function Bs(e){return l(e)?ge(e):e instanceof he?e:tt((()=>e))}const Fs=Object.freeze({positioning:!1,recycle:!0});function Us(e,t,i,n){e.context.parent=n.source,e.context.parentContext=n.context,e.bind(t[i])}function Hs(e,t,i,n){e.context.parent=n.source,e.context.parentContext=n.context,e.context.length=t.length,e.context.index=i,e.bind(t[i])}class $s{constructor(e){this.directive=e,this.items=null,this.itemsObserver=null,this.bindView=Us,this.views=[],this.itemsBindingObserver=e.dataBinding.createObserver(this,e),this.templateBindingObserver=e.templateBinding.createObserver(this,e),e.options.positioning&&(this.bindView=Hs)}bind(e){this.location=e.targets[this.directive.targetNodeId],this.controller=e,this.items=this.itemsBindingObserver.bind(e),this.template=this.templateBindingObserver.bind(e),this.observeItems(!0),this.refreshAllViews(),e.onUnbind(this)}unbind(){null!==this.itemsObserver&&this.itemsObserver.unsubscribe(this),this.unbindAllViews()}handleChange(e,t){if(t===this.itemsBindingObserver)this.items=this.itemsBindingObserver.bind(this.controller),this.observeItems(),this.refreshAllViews();else if(t===this.templateBindingObserver)this.template=this.templateBindingObserver.bind(this.controller),this.refreshAllViews(!0);else{if(!t[0])return;t[0].reset?this.refreshAllViews():this.updateViews(t)}}observeItems(e=!1){if(!this.items)return void(this.items=f);const t=this.itemsObserver,i=this.itemsObserver=S.getNotifier(this.items),n=t!==i;n&&null!==t&&t.unsubscribe(this),(n||e)&&i.subscribe(this)}updateViews(e){const t=this.views,i=this.bindView,n=this.items,o=this.template,r=this.controller,a=this.directive.options.recycle,s=[];let l=0,c=0;for(let d=0,u=e.length;d<u;++d){const u=e[d],h=u.removed;let p=0,g=u.index;const f=g+u.addedCount,m=t.splice(u.index,h.length),v=c=s.length+m.length;for(;g<f;++g){const e=t[g],d=e?e.firstChild:this.location;let u;a&&c>0?(p<=v&&m.length>0?(u=m[p],p++):(u=s[l],l++),c--):u=o.create(),t.splice(g,0,u),i(u,n,g,r),u.insertBefore(d)}m[p]&&s.push(...m.slice(p))}for(let e=l,t=s.length;e<t;++e)s[e].dispose();if(this.directive.options.positioning)for(let e=0,i=t.length;e<i;++e){const n=t[e].context;n.length=i,n.index=e}}refreshAllViews(e=!1){const t=this.items,i=this.template,n=this.location,o=this.bindView,r=this.controller;let a=t.length,s=this.views,l=s.length;if(0!==a&&!e&&this.directive.options.recycle||(mt.disposeContiguousBatch(s),l=0),0===l){this.views=s=new Array(a);for(let e=0;e<a;++e){const a=i.create();o(a,t,e,r),s[e]=a,a.insertBefore(n)}}else{let e=0;for(;e<a;++e)if(e<l)o(s[e],t,e,r);else{const a=i.create();o(a,t,e,r),s.push(a),a.insertBefore(n)}const c=s.splice(e,l-e);for(e=0,a=c.length;e<a;++e)c[e].dispose()}}unbindAllViews(){const e=this.views;for(let t=0,i=e.length;t<i;++t)e[t].unbind()}}class Zs{constructor(e,t,i){this.dataBinding=e,this.templateBinding=t,this.options=i,Ls.enable()}createHTML(e){return lt.comment(e(this))}createBehavior(){return new $s(this)}}function Vs(e,t,i=Fs){const n=Bs(e),o=Bs(t);return new Zs(n,o,Object.assign(Object.assign({},Fs),i))}ut.define(Zs);const Gs=Object.freeze({prefix:"commerceui",shadowRootMode:"open",registry:customElements});let js;const zs="fast-kernel";try{if(document.currentScript)js=document.currentScript.getAttribute(zs);else{const e=document.getElementsByTagName("script");js=e[e.length-1].getAttribute(zs)}}catch(e){js="isolate"}let Ws;switch(js){case"share":Ws=Object.freeze({updateQueue:1,observable:2,contextEvent:3,elementRegistry:4});break;case"share-v2":Ws=Object.freeze({updateQueue:1.2,observable:2.2,contextEvent:3.2,elementRegistry:4.2});break;default:const e=`-${Math.random().toString(36).substring(2,8)}`;Ws=Object.freeze({updateQueue:`1.2${e}`,observable:`2.2${e}`,contextEvent:`3.2${e}`,elementRegistry:`4.2${e}`})}const Ks=e=>"function"==typeof e,qs=e=>"string"==typeof e,Ys=()=>{};class Xs{constructor(e,t){this.sub1=void 0,this.sub2=void 0,this.spillover=void 0,this.subject=e,this.sub1=t}has(e){return void 0===this.spillover?this.sub1===e||this.sub2===e:-1!==this.spillover.indexOf(e)}subscribe(e){const t=this.spillover;if(void 0===t){if(this.has(e))return;if(void 0===this.sub1)return void(this.sub1=e);if(void 0===this.sub2)return void(this.sub2=e);this.spillover=[this.sub1,this.sub2,e],this.sub1=void 0,this.sub2=void 0}else-1===t.indexOf(e)&&t.push(e)}unsubscribe(e){const t=this.spillover;if(void 0===t)this.sub1===e?this.sub1=void 0:this.sub2===e&&(this.sub2=void 0);else{const i=t.indexOf(e);-1!==i&&t.splice(i,1)}}notify(e){const t=this.spillover,i=this.subject;if(void 0===t){const t=this.sub1,n=this.sub2;void 0!==t&&t.handleChange(i,e),void 0!==n&&n.handleChange(i,e)}else for(let n=0,o=t.length;n<o;++n)t[n].handleChange(i,e)}}class Js{constructor(e){this.subscribers={},this.subjectSubscribers=null,this.subject=e}notify(e){var t,i;null===(t=this.subscribers[e])||void 0===t||t.notify(e),null===(i=this.subjectSubscribers)||void 0===i||i.notify(e)}subscribe(e,t){var i,n;let o;o=t?null!==(i=this.subscribers[t])&&void 0!==i?i:this.subscribers[t]=new Xs(this.subject):null!==(n=this.subjectSubscribers)&&void 0!==n?n:this.subjectSubscribers=new Xs(this.subject),o.subscribe(e)}unsubscribe(e,t){var i,n;t?null===(i=this.subscribers[t])||void 0===i||i.unsubscribe(e):null===(n=this.subjectSubscribers)||void 0===n||n.unsubscribe(e)}}!function(){if("undefined"==typeof globalThis)if("undefined"!=typeof global)global.globalThis=global;else if("undefined"!=typeof self)self.globalThis=self;else if("undefined"!=typeof window)window.globalThis=window;else{const e=new Function("return this")();e.globalThis=e}}();const Qs={configurable:!1,enumerable:!1,writable:!1};void 0===globalThis.FAST&&Reflect.defineProperty(globalThis,"FAST",Object.assign({value:Object.create(null)},Qs));const el=globalThis.FAST;if(void 0===el.getById){const e=Object.create(null);Reflect.defineProperty(el,"getById",Object.assign({value(t,i){let n=e[t];return void 0===n&&(n=i?e[t]=i():null),n}},Qs))}void 0===el.error&&Object.assign(el,{warn(){},error(e){return new Error(`Error ${e}`)},addMessages(){}});const tl=Object.freeze([]);function il(){const e=new Map;return Object.freeze({register(t){return!e.has(t.type)&&(e.set(t.type,t),!0)},getByType(t){return e.get(t)},getForInstance(t){if(null!=t)return e.get(t.constructor)}})}function nl(){const e=new WeakMap;return function(t){let i=e.get(t);if(void 0===i){let n=Reflect.getPrototypeOf(t);for(;void 0===i&&null!==n;)i=e.get(n),n=Reflect.getPrototypeOf(n);i=void 0===i?[]:i.slice(0),e.set(t,i)}return i}}function ol(e){e.prototype.toJSON=Ys}const rl=el.getById(Ws.updateQueue,(()=>{const e=[],t=[],i=globalThis.requestAnimationFrame;let n=!0;function o(){if(t.length)throw t.shift()}function r(i){try{i.call()}catch(i){if(!n)throw e.length=0,i;t.push(i),setTimeout(o,0)}}function a(){let t=0;for(;t<e.length;)if(r(e[t]),t++,t>1024){for(let i=0,n=e.length-t;i<n;i++)e[i]=e[i+t];e.length-=t,t=0}e.length=0}function s(t){e.push(t),e.length<2&&(n?i(a):a())}return Object.freeze({enqueue:s,next:()=>new Promise(s),process:a,setMode:e=>n=e})})),al=Object.freeze({unknown:void 0,coupled:1}),sl=el.getById(Ws.observable,(()=>{const e=rl.enqueue,t=/(:|&&|\|\||if|\?\.)/,i=new WeakMap;let n,o=e=>{throw el.error(1101)};function r(e){var t;let n=null!==(t=e.$fastController)&&void 0!==t?t:i.get(e);return void 0===n&&(Array.isArray(e)?n=o(e):i.set(e,n=new Js(e))),n}const a=nl();class s{constructor(e){this.name=e,this.field=`_${e}`,this.callback=`${e}Changed`}getValue(e){return void 0!==n&&n.watch(e,this.name),e[this.field]}setValue(e,t){const i=this.field,n=e[i];if(n!==t){e[i]=t;const o=e[this.callback];Ks(o)&&o.call(e,n,t),r(e).notify(this.name)}}}class l extends Xs{constructor(e,t,i=!1){super(e,t),this.expression=e,this.isVolatileBinding=i,this.needsRefresh=!0,this.needsQueue=!0,this.isAsync=!0,this.first=this,this.last=null,this.propertySource=void 0,this.propertyName=void 0,this.notifier=void 0,this.next=void 0}setMode(e){this.isAsync=this.needsQueue=e}bind(e){this.controller=e;const t=this.observe(e.source,e.context);return!e.isBound&&this.requiresUnbind(e)&&e.onUnbind(this),t}requiresUnbind(e){return e.sourceLifetime!==al.coupled||this.first!==this.last||this.first.propertySource!==e.source}unbind(e){this.dispose()}observe(e,t){this.needsRefresh&&null!==this.last&&this.dispose();const i=n;let o;n=this.needsRefresh?this:void 0,this.needsRefresh=this.isVolatileBinding;try{o=this.expression(e,t)}finally{n=i}return o}disconnect(){this.dispose()}dispose(){if(null!==this.last){let e=this.first;for(;void 0!==e;)e.notifier.unsubscribe(this,e.propertyName),e=e.next;this.last=null,this.needsRefresh=this.needsQueue=this.isAsync}}watch(e,t){const i=this.last,o=r(e),a=null===i?this.first:{};if(a.propertySource=e,a.propertyName=t,a.notifier=o,o.subscribe(this,t),null!==i){if(!this.needsRefresh){let t;n=void 0,t=i.propertySource[i.propertyName],n=this,e===t&&(this.needsRefresh=!0)}i.next=a}this.last=a}handleChange(){this.needsQueue?(this.needsQueue=!1,e(this)):this.isAsync||this.call()}call(){null!==this.last&&(this.needsQueue=this.isAsync,this.notify(this))}*records(){let e=this.first;for(;void 0!==e;)yield e,e=e.next}}return ol(l),Object.freeze({setArrayObserverFactory(e){o=e},getNotifier:r,track(e,t){n&&n.watch(e,t)},trackVolatile(){n&&(n.needsRefresh=!0)},notify(e,t){r(e).notify(t)},defineProperty(e,t){qs(t)&&(t=new s(t)),a(e).push(t),Reflect.defineProperty(e,t.name,{enumerable:!0,get(){return t.getValue(this)},set(e){t.setValue(this,e)}})},getAccessors:a,binding(e,t,i=this.isVolatileBinding(e)){return new l(e,t,i)},isVolatileBinding(e){return t.test(e.toString())}})}));function ll(e,t){sl.defineProperty(e,t)}const cl=el.getById(Ws.contextEvent,(()=>{let e=null;return{get(){return e},set(t){e=t}}})),dl=Object.freeze({default:{index:0,length:0,get event(){return dl.getEvent()},eventDetail(){return this.event.detail},eventTarget(){return this.event.target}},getEvent(){return cl.get()},setEvent(e){cl.set(e)}});let ul;function hl(e){return e.map((e=>e instanceof pl?hl(e.styles):[e])).reduce(((e,t)=>e.concat(t)),[])}class pl{constructor(e){this.styles=e,this.targets=new WeakSet,this._strategy=null,this.behaviors=e.map((e=>e instanceof pl?e.behaviors:null)).reduce(((e,t)=>null===t?e:null===e?t:e.concat(t)),null)}get strategy(){return null===this._strategy&&this.withStrategy(ul),this._strategy}addStylesTo(e){this.strategy.addStylesTo(e),this.targets.add(e)}removeStylesFrom(e){this.strategy.removeStylesFrom(e),this.targets.delete(e)}isAttachedTo(e){return this.targets.has(e)}withBehaviors(...e){return this.behaviors=null===this.behaviors?e:this.behaviors.concat(e),this}withStrategy(e){return this._strategy=new e(hl(this.styles)),this}static setDefaultStrategy(e){ul=e}static normalize(e){return void 0===e?void 0:Array.isArray(e)?new pl(e):e instanceof pl?e:new pl([e])}}pl.supportsAdoptedStyleSheets=Array.isArray(document.adoptedStyleSheets)&&"replace"in CSSStyleSheet.prototype;const gl=Object.freeze({none:0,attribute:1,booleanAttribute:2,property:3,content:4,tokenList:5,event:6}),fl=e=>e,ml=globalThis.trustedTypes?globalThis.trustedTypes.createPolicy("fast-html",{createHTML:fl}):{createHTML:fl};let vl=Object.freeze({createHTML(e){return ml.createHTML(e)},protect(e,t,i,n){return n}});const yl=vl,Cl=Object.freeze({get policy(){return vl},setPolicy(e){if(vl!==yl)throw el.error(1201);vl=e},setAttribute(e,t,i){null==i?e.removeAttribute(t):e.setAttribute(t,i)},setBooleanAttribute(e,t,i){i?e.setAttribute(t,""):e.removeAttribute(t)}}),bl="boolean",Sl="reflect",xl=Object.freeze({locate:nl()}),Tl={toView(e){return e?"true":"false"},fromView(e){return null!=e&&"false"!==e&&!1!==e&&0!==e}};function wl(e){if(null==e)return null;const t=1*e;return isNaN(t)?null:t}const Ol={toView(e){const t=wl(e);return t?t.toString():t},fromView:wl};class Pl{constructor(e,t,i=t.toLowerCase(),n=Sl,o){this.guards=new Set,this.Owner=e,this.name=t,this.attribute=i,this.mode=n,this.converter=o,this.fieldName=`_${t}`,this.callbackName=`${t}Changed`,this.hasCallback=this.callbackName in e.prototype,n===bl&&void 0===o&&(this.converter=Tl)}setValue(e,t){const i=e[this.fieldName],n=this.converter;void 0!==n&&(t=n.fromView(t)),i!==t&&(e[this.fieldName]=t,this.tryReflectToAttribute(e),this.hasCallback&&e[this.callbackName](i,t),e.$fastController.notify(this.name))}getValue(e){return sl.track(e,this.name),e[this.fieldName]}onAttributeChangedCallback(e,t){this.guards.has(e)||(this.guards.add(e),this.setValue(e,t),this.guards.delete(e))}tryReflectToAttribute(e){const t=this.mode,i=this.guards;i.has(e)||"fromView"===t||rl.enqueue((()=>{i.add(e);const n=e[this.fieldName];switch(t){case Sl:const t=this.converter;Cl.setAttribute(e,this.attribute,void 0!==t?t.toView(n):n);break;case bl:Cl.setBooleanAttribute(e,this.attribute,n)}i.delete(e)}))}static collect(e,...t){const i=[];t.push(xl.locate(e));for(let n=0,o=t.length;n<o;++n){const o=t[n];if(void 0!==o)for(let t=0,n=o.length;t<n;++t){const n=o[t];qs(n)?i.push(new Pl(e,n)):i.push(new Pl(e,n.property,n.attribute,n.mode,n.converter))}}return i}}function Al(e,t){let i;function n(e,t){arguments.length>1&&(i.property=t),xl.locate(e.constructor).push(i)}return arguments.length>1?(i={},void n(e,t)):(i=void 0===e?{}:e,n)}const El={mode:"open"},kl={},Il=new Set,Dl=el.getById(Ws.elementRegistry,(()=>il()));class _l{constructor(e,t=e.definition){var i;this.platformDefined=!1,qs(t)&&(t={name:t}),this.type=e,this.name=t.name,this.template=t.template,this.registry=null!==(i=t.registry)&&void 0!==i?i:customElements;const n=e.prototype,o=Pl.collect(e,t.attributes),r=new Array(o.length),a={},s={};for(let e=0,t=o.length;e<t;++e){const t=o[e];r[e]=t.attribute,a[t.name]=t,s[t.attribute]=t,sl.defineProperty(n,t)}Reflect.defineProperty(e,"observedAttributes",{value:r,enumerable:!0}),this.attributes=o,this.propertyLookup=a,this.attributeLookup=s,this.shadowOptions=void 0===t.shadowOptions?El:null===t.shadowOptions?void 0:Object.assign(Object.assign({},El),t.shadowOptions),this.elementOptions=void 0===t.elementOptions?kl:Object.assign(Object.assign({},kl),t.elementOptions),this.styles=pl.normalize(t.styles),Dl.register(this)}get isDefined(){return this.platformDefined}define(e=this.registry){const t=this.type;return e.get(this.name)||(this.platformDefined=!0,e.define(this.name,t,this.elementOptions)),this}static compose(e,t){return Il.has(e)||Dl.getByType(e)?new _l(class extends e{},t):new _l(e,t)}static registerBaseType(e){Il.add(e)}}_l.getByType=Dl.getByType,_l.getForInstance=Dl.getForInstance;const Nl={bubbles:!0,composed:!0,cancelable:!0},Rl="isConnected",Ml=new WeakMap;function Ll(e){var t,i;return null!==(i=null!==(t=e.shadowRoot)&&void 0!==t?t:Ml.get(e))&&void 0!==i?i:null}let Bl;class Fl extends Js{constructor(e,t){super(e),this.boundObservables=null,this.needsInitialization=!0,this.hasExistingShadowRoot=!1,this._template=null,this.stage=3,this.guardBehaviorConnection=!1,this.behaviors=null,this._mainStyles=null,this.$fastController=this,this.view=null,this.source=e,this.definition=t;const i=t.shadowOptions;if(void 0!==i){let t=e.shadowRoot;t?this.hasExistingShadowRoot=!0:(t=e.attachShadow(i),"closed"===i.mode&&Ml.set(e,t))}const n=sl.getAccessors(e);if(n.length>0){const t=this.boundObservables=Object.create(null);for(let i=0,o=n.length;i<o;++i){const o=n[i].name,r=e[o];void 0!==r&&(delete e[o],t[o]=r)}}}get isConnected(){return sl.track(this,Rl),1===this.stage}get context(){var e,t;return null!==(t=null===(e=this.view)||void 0===e?void 0:e.context)&&void 0!==t?t:dl.default}get isBound(){var e,t;return null!==(t=null===(e=this.view)||void 0===e?void 0:e.isBound)&&void 0!==t&&t}get sourceLifetime(){var e;return null===(e=this.view)||void 0===e?void 0:e.sourceLifetime}get template(){var e;if(null===this._template){const t=this.definition;this.source.resolveTemplate?this._template=this.source.resolveTemplate():t.template&&(this._template=null!==(e=t.template)&&void 0!==e?e:null)}return this._template}set template(e){this._template!==e&&(this._template=e,this.needsInitialization||this.renderTemplate(e))}get mainStyles(){var e;if(null===this._mainStyles){const t=this.definition;this.source.resolveStyles?this._mainStyles=this.source.resolveStyles():t.styles&&(this._mainStyles=null!==(e=t.styles)&&void 0!==e?e:null)}return this._mainStyles}set mainStyles(e){this._mainStyles!==e&&(null!==this._mainStyles&&this.removeStyles(this._mainStyles),this._mainStyles=e,this.needsInitialization||this.addStyles(e))}onUnbind(e){var t;null===(t=this.view)||void 0===t||t.onUnbind(e)}addBehavior(e){var t,i;const n=null!==(t=this.behaviors)&&void 0!==t?t:this.behaviors=new Map,o=null!==(i=n.get(e))&&void 0!==i?i:0;0===o?(n.set(e,1),e.addedCallback&&e.addedCallback(this),!e.connectedCallback||this.guardBehaviorConnection||1!==this.stage&&0!==this.stage||e.connectedCallback(this)):n.set(e,o+1)}removeBehavior(e,t=!1){const i=this.behaviors;if(null===i)return;const n=i.get(e);void 0!==n&&(1===n||t?(i.delete(e),e.disconnectedCallback&&3!==this.stage&&e.disconnectedCallback(this),e.removedCallback&&e.removedCallback(this)):i.set(e,n-1))}addStyles(e){var t;if(!e)return;const i=this.source;if(e instanceof HTMLElement)(null!==(t=Ll(i))&&void 0!==t?t:this.source).append(e);else if(!e.isAttachedTo(i)){const t=e.behaviors;if(e.addStylesTo(i),null!==t)for(let e=0,i=t.length;e<i;++e)this.addBehavior(t[e])}}removeStyles(e){var t;if(!e)return;const i=this.source;if(e instanceof HTMLElement)(null!==(t=Ll(i))&&void 0!==t?t:i).removeChild(e);else if(e.isAttachedTo(i)){const t=e.behaviors;if(e.removeStylesFrom(i),null!==t)for(let e=0,i=t.length;e<i;++e)this.removeBehavior(t[e])}}connect(){if(3!==this.stage)return;if(this.stage=0,null!==this.boundObservables){const e=this.source,t=this.boundObservables,i=Object.keys(t);for(let n=0,o=i.length;n<o;++n){const o=i[n];e[o]=t[o]}this.boundObservables=null}const e=this.behaviors;if(null!==e){this.guardBehaviorConnection=!0;for(const t of e.keys())t.connectedCallback&&t.connectedCallback(this);this.guardBehaviorConnection=!1}this.needsInitialization?(this.renderTemplate(this.template),this.addStyles(this.mainStyles),this.needsInitialization=!1):null!==this.view&&this.view.bind(this.source),this.stage=1,sl.notify(this,Rl)}disconnect(){if(1!==this.stage)return;this.stage=2,sl.notify(this,Rl),null!==this.view&&this.view.unbind();const e=this.behaviors;if(null!==e)for(const t of e.keys())t.disconnectedCallback&&t.disconnectedCallback(this);this.stage=3}onAttributeChangedCallback(e,t,i){const n=this.definition.attributeLookup[e];void 0!==n&&n.onAttributeChangedCallback(this.source,i)}emit(e,t,i){return 1===this.stage&&this.source.dispatchEvent(new CustomEvent(e,Object.assign(Object.assign({detail:t},Nl),i)))}renderTemplate(e){var t;const i=this.source,n=null!==(t=Ll(i))&&void 0!==t?t:i;if(null!==this.view)this.view.dispose(),this.view=null;else if(!this.needsInitialization||this.hasExistingShadowRoot){this.hasExistingShadowRoot=!1;for(let e=n.firstChild;null!==e;e=n.firstChild)n.removeChild(e)}e&&(this.view=e.render(i,n,i),this.view.sourceLifetime=al.coupled)}static forCustomElement(e){const t=e.$fastController;if(void 0!==t)return t;const i=_l.getForInstance(e);if(void 0===i)throw el.error(1401);return e.$fastController=new Bl(e,i)}static setStrategy(e){Bl=e}}function Ul(e){var t;return"adoptedStyleSheets"in e?e:null!==(t=Ll(e))&&void 0!==t?t:e.getRootNode()}ol(Fl),Fl.setStrategy(Fl);class Hl{constructor(e){const t=Hl.styleSheetCache;this.sheets=e.map((e=>{if(e instanceof CSSStyleSheet)return e;let i=t.get(e);return void 0===i&&(i=new CSSStyleSheet,i.replaceSync(e),t.set(e,i)),i}))}addStylesTo(e){Vl(Ul(e),this.sheets)}removeStylesFrom(e){Gl(Ul(e),this.sheets)}}Hl.styleSheetCache=new Map;let $l=0;function Zl(e){return e===document?document.body:e}let Vl=(e,t)=>{e.adoptedStyleSheets=[...e.adoptedStyleSheets,...t]},Gl=(e,t)=>{e.adoptedStyleSheets=e.adoptedStyleSheets.filter((e=>-1===t.indexOf(e)))};if(pl.supportsAdoptedStyleSheets){try{document.adoptedStyleSheets.push(),document.adoptedStyleSheets.splice(),Vl=(e,t)=>{e.adoptedStyleSheets.push(...t)},Gl=(e,t)=>{for(const i of t){const t=e.adoptedStyleSheets.indexOf(i);-1!==t&&e.adoptedStyleSheets.splice(t,1)}}}catch(e){}pl.setDefaultStrategy(Hl)}else pl.setDefaultStrategy(class{constructor(e){this.styles=e,this.styleClass="fast-"+ ++$l}addStylesTo(e){e=Zl(Ul(e));const t=this.styles,i=this.styleClass;for(let n=0;n<t.length;n++){const o=document.createElement("style");o.innerHTML=t[n],o.className=i,e.append(o)}}removeStylesFrom(e){const t=(e=Zl(Ul(e))).querySelectorAll(`.${this.styleClass}`);for(let i=0,n=t.length;i<n;++i)e.removeChild(t[i])}});function jl(e){const t=class extends e{constructor(){super(),Fl.forCustomElement(this)}$emit(e,t,i){return this.$fastController.emit(e,t,i)}connectedCallback(){this.$fastController.connect()}disconnectedCallback(){this.$fastController.disconnect()}attributeChangedCallback(e,t,i){this.$fastController.onAttributeChangedCallback(e,t,i)}};return _l.registerBaseType(t),t}const zl=Object.assign(jl(HTMLElement),{from:function(e){return jl(e)},define:function(e,t){return Ks(e)?_l.compose(e,t).define().type:_l.compose(this,e).define().type},compose:function(e,t){return Ks(e)?_l.compose(e,t):_l.compose(this,e)}}),Wl="dropdown",Kl="swatches";class ql extends zl{constructor(){super(...arguments),this.type=Wl,this.size="medium",this.placeholderText="Select",this.selectedIndex=null,this.rowMaxItems=null,this.autoHideOverflowSwatches=!1,this.handleMenuOpenChange=e=>{this.open=e.detail.open}}itemsChanged(){this.items&&this.items.length>0&&this.selectedIndexHandler()}selectedIndexChanged(){this.selectedIndexHandler()}rowMaxItemsChanged(){this.updateRowMaxItems()}autoHideOverflowChanged(){this.updateRowMaxItems()}connectedCallback(){super.connectedCallback(),this.type===Wl?this.menuButtonRef.shadowRoot.querySelector("[slot='end']").style.flex="0 0 auto":this.type===Kl&&this.updateRowMaxItems(),this.containerResizeObserver=new ResizeObserver((()=>{this.updateRowMaxItems()})),this.containerResizeObserver.observe(this.containerRef)}disconnectedCallback(){super.disconnectedCallback(),this.containerResizeObserver.unobserve(this.containerRef)}get getSelectedValue(){return void 0!==this._selected&&null!==this._selected&&void 0!==this.items&&this.items.length>=this._selected-1?this.items[this._selected].value:null}get getPlaceholderText(){return this.placeholderText}selectHandler(e){var t;this._selected=this.items.map((e=>e.value)).indexOf(e.value),null===(t=this.onselectionchange)||void 0===t||t.call(this,e),this.$emit("filterchange",{selectedIndex:this._selected,item:e})}selectedIndexHandler(){this.items&&this.selectedIndex>=0&&this.selectedIndex<this.items.length&&(this._selected=this.selectedIndex)}updateRowMaxItems(){if(this.shadowRoot&&this.containerRef&&this.swatchesRef&&this.containerRef.clientWidth>0&&this.containerRef.clientWidth!==this.containerPreviousWidth){const e=this.swatchesRef.shadowRoot.querySelector("commerceui-swatch");this.itemsToFitPerRow=this.autoHideOverflowSwatches?Math.floor(this.containerRef.clientWidth/(e.clientWidth+8)):this.rowMaxItems,this.containerPreviousWidth=this.containerRef.clientWidth}}}(0,o.gn)([Al({attribute:"type"})],ql.prototype,"type",void 0),(0,o.gn)([Al],ql.prototype,"size",void 0),(0,o.gn)([Al({attribute:"open"})],ql.prototype,"open",void 0),(0,o.gn)([Al],ql.prototype,"label",void 0),(0,o.gn)([Al({attribute:"show-label-value",mode:"boolean"})],ql.prototype,"showLabelValue",void 0),(0,o.gn)([Al({attribute:"show-label-inline",mode:"boolean"})],ql.prototype,"showLabelInline",void 0),(0,o.gn)([Al({attribute:"items"})],ql.prototype,"items",void 0),(0,o.gn)([Al({attribute:"placeholder-text"})],ql.prototype,"placeholderText",void 0),(0,o.gn)([Al({attribute:"hide-placeholder-text",mode:"boolean"})],ql.prototype,"hidePlaceholderText",void 0),(0,o.gn)([Al({attribute:"selected-index",converter:Ol})],ql.prototype,"selectedIndex",void 0),(0,o.gn)([Al({attribute:"row-max-items",converter:Ol})],ql.prototype,"rowMaxItems",void 0),(0,o.gn)([Al({attribute:"auto-hide-overflow-swatches",mode:"boolean"})],ql.prototype,"autoHideOverflowSwatches",void 0),(0,o.gn)([ll],ql.prototype,"itemsToFitPerRow",void 0),(0,o.gn)([ll],ql.prototype,"_selected",void 0);class Yl{constructor(e,t,i=!1){this.evaluate=e,this.policy=t,this.isVolatile=i}}class Xl extends Yl{createObserver(e){return sl.binding(this.evaluate,e,this.isVolatile)}}function Jl(e,t,i=sl.isVolatileBinding(e)){return new Xl(e,t,i)}const Ql=il(),ec=Object.freeze({getForInstance:Ql.getForInstance,getByType:Ql.getByType,define(e){return Ql.register({type:e}),e}});function tc(e,t,i){t.source.style.setProperty(e.targetAspect,i.bind(t))}class ic{constructor(e,t){this.dataBinding=e,this.targetAspect=t}createCSS(e){return e(this),`var(${this.targetAspect})`}addedCallback(e){var t;const i=e.source;if(!i.$cssBindings){i.$cssBindings=new Map;const e=i.setAttribute;i.setAttribute=(t,n)=>{e.call(i,t,n),"style"===t&&i.$cssBindings.forEach(((e,t)=>tc(t,e.controller,e.observer)))}}const n=null!==(t=e[this.targetAspect])&&void 0!==t?t:e[this.targetAspect]=this.dataBinding.createObserver(this,this);n.controller=e,e.source.$cssBindings.set(this,{controller:e,observer:n})}connectedCallback(e){tc(this,e,e[this.targetAspect])}removedCallback(e){e.source.$cssBindings&&e.source.$cssBindings.delete(this)}handleChange(e,t){tc(this,t.controller,t)}}ec.define(ic);const nc=`${Math.random().toString(36).substring(2,8)}`;let oc=0;const rc=()=>`--v${nc}${++oc}`;function ac(e,t){const i=[];let n="";const o=[],r=e=>{o.push(e)};for(let o=0,a=e.length-1;o<a;++o){n+=e[o];let a=t[o];Ks(a)?a=new ic(Jl(a),rc()).createCSS(r):a instanceof Yl?a=new ic(a,rc()).createCSS(r):void 0!==ec.getForInstance(a)&&(a=a.createCSS(r)),a instanceof pl||a instanceof CSSStyleSheet?(""!==n.trim()&&(i.push(n),n=""),i.push(a)):n+=a}return n+=e[e.length-1],""!==n.trim()&&i.push(n),{styles:i,behaviors:o}}const sc=(e,...t)=>{const{styles:i,behaviors:n}=ac(e,t),o=new pl(i);return n.length?o.withBehaviors(...n):o};class lc{constructor(e,t){this.behaviors=t,this.css="";const i=e.reduce(((e,t)=>(qs(t)?this.css+=t:e.push(t),e)),[]);i.length&&(this.styles=new pl(i))}createCSS(e){return this.behaviors.forEach(e),this.styles&&e(this),this.css}addedCallback(e){e.addStyles(this.styles)}removedCallback(e){e.removeStyles(this.styles)}}ec.define(lc),sc.partial=(e,...t)=>{const{styles:i,behaviors:n}=ac(e,t);return new lc(i,n)};const cc=He,dc=$e,uc=Ze,hc=Ge,pc=He,gc="var(--fontSizeBase200)",fc=Ze,mc="var(--lineHeightBase200)",vc="var(--fontSizeBase100)",yc=Ze,Cc="var(--lineHeightBase100)",bc="var(--fontSizeBase500)",Sc=Ve,xc="var(--lineHeightBase500)",Tc="var(--fontSizeBase400)",wc=Ve,Oc="var(--lineHeightBase400)",Pc="var(--fontSizeHero700)",Ac=Ve,Ec="var(--lineHeightHero700)",kc="var(--fontSizeBase600)",Ic=Ve,Dc="var(--lineHeightBase600)",_c=sc`
:host {
overflow: hidden;
}
.container {
display: flex;
flex-direction: column;
align-items: flex-start;
row-gap: ${Ye};
}
.placeholder {
color: ${Ae};
font-family: ${He};
font-size: ${dc};
font-weight: ${uc};
}
fluent-beta-label {
max-width: 100%;
}
.label {
font-weight: ${Ve};
}
.label-value {
margin-inline-start: ${ze};
font-weight: ${uc};
}
fluent-beta-menu {
max-width: 100%;
}
fluent-beta-menu[open="true"] {
z-index: 2;
}
fluent-beta-menu-button {
max-width: 100%;
}
.menu-button::part(control) {
flex: 1;
min-width: 0;
width: max-content;
background-color: ${Ie};
}
.label,
.menu-button::part(content),
.menu-button .label-value {
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
}
fluent-beta-menu-list {
width: fit-content;
min-width: fit-content;
max-width: fit-content;
}
fluent-beta-menu-item {
grid-template-columns: auto;
}
fluent-beta-menu-item[disabled] {
pointer-events: none;
background: none;
}
fluent-beta-menu-item .menu-item-label {
overflow: hidden;
text-overflow: ellipsis;
}
`;class Nc extends Yl{createObserver(){return this}bind(e){return this.evaluate(e.source,e.context)}}function Rc(e,t){return new Nc(e,t)}ol(Nc);const Mc=`fast-${Math.random().toString(36).substring(2,8)}`,Lc=`${Mc}{`,Bc=`}${Mc}`,Fc=Bc.length;let Uc=0;const Hc=()=>`${Mc}-${++Uc}`,$c=Object.freeze({interpolation:e=>`${Lc}${e}${Bc}`,attribute:e=>`${Hc()}="${Lc}${e}${Bc}"`,comment:e=>`\x3c!--${Lc}${e}${Bc}--\x3e`}),Zc=Object.freeze({parse(e,t){const i=e.split(Lc);if(1===i.length)return null;const n=[];for(let e=0,o=i.length;e<o;++e){const o=i[e],r=o.indexOf(Bc);let a;if(-1===r)a=o;else{const e=o.substring(0,r);n.push(t[e]),a=o.substring(r+Fc)}""!==a&&n.push(a)}return n}}),Vc=il(),Gc=Object.freeze({getForInstance:Vc.getForInstance,getByType:Vc.getByType,define(e,t){return(t=t||{}).type=e,Vc.register(t),e},assignAspect(e,t){if(t)switch(e.sourceAspect=t,t[0]){case":":e.targetAspect=t.substring(1),e.aspectType="classList"===e.targetAspect?gl.tokenList:gl.property;break;case"?":e.targetAspect=t.substring(1),e.aspectType=gl.booleanAttribute;break;case"@":e.targetAspect=t.substring(1),e.aspectType=gl.event;break;default:e.targetAspect=t,e.aspectType=gl.attribute}else e.aspectType=gl.content}});class jc{constructor(e){this.options=e}createHTML(e){return $c.attribute(e(this))}createBehavior(){return this}}ol(jc);const zc={[gl.attribute]:Cl.setAttribute,[gl.booleanAttribute]:Cl.setBooleanAttribute,[gl.property]:(e,t,i)=>e[t]=i,[gl.content]:function(e,t,i,n){if(null==i&&(i=""),i.create){e.textContent="";let t=e.$fastView;void 0===t?t=i.create():e.$fastTemplate!==i&&(t.isComposed&&(t.remove(),t.unbind()),t=i.create()),t.isComposed?t.needsBindOnly&&(t.needsBindOnly=!1,t.bind(n.source,n.context)):(t.isComposed=!0,t.bind(n.source,n.context),t.insertBefore(e),e.$fastView=t,e.$fastTemplate=i)}else{const t=e.$fastView;void 0!==t&&t.isComposed&&(t.isComposed=!1,t.remove(),t.needsBindOnly?t.needsBindOnly=!1:t.unbind()),e.textContent=i}},[gl.tokenList]:function(e,t,i){var n;const o=`${this.id}-t`,r=null!==(n=e[o])&&void 0!==n?n:e[o]={v:0,cv:Object.create(null)},a=r.cv;let s=r.v;const l=e[t];if(null!=i&&i.length){const e=i.split(/\s+/);for(let t=0,i=e.length;t<i;++t){const i=e[t];""!==i&&(a[i]=s,l.add(i))}}if(r.v=s+1,0!==s){s-=1;for(const e in a)a[e]===s&&l.remove(e)}},[gl.event]:()=>{}};class Wc{constructor(e){this.dataBinding=e,this.updateTarget=null,this.aspectType=gl.content}createHTML(e){return $c.interpolation(e(this))}createBehavior(){var e;if(null===this.updateTarget){const t=zc[this.aspectType],i=null!==(e=this.dataBinding.policy)&&void 0!==e?e:this.policy;if(!t)throw el.error(1205);this.data=`${this.id}-d`,this.updateTarget=i.protect(this.targetTagName,this.aspectType,this.targetAspect,t)}return this}bind(e){var t;const i=e.targets[this.targetNodeId];switch(this.aspectType){case gl.event:i[this.data]=e,i.addEventListener(this.targetAspect,this,this.dataBinding.options);break;case gl.content:e.onUnbind(this);default:const n=null!==(t=i[this.data])&&void 0!==t?t:i[this.data]=this.dataBinding.createObserver(this,this);n.target=i,n.controller=e,this.updateTarget(i,this.targetAspect,n.bind(e),e)}}unbind(e){const t=e.targets[this.targetNodeId].$fastView;void 0!==t&&t.isComposed&&(t.unbind(),t.needsBindOnly=!0)}handleEvent(e){const t=e.currentTarget[this.data];if(t.isBound){dl.setEvent(e);const i=this.dataBinding.evaluate(t.source,t.context);dl.setEvent(null),!0!==i&&e.preventDefault()}}handleChange(e,t){const i=t.target,n=t.controller;this.updateTarget(i,this.targetAspect,t.bind(n),n)}}function Kc(e,t){const i=e.parentNode;let n,o=e;for(;o!==t;)n=o.nextSibling,i.removeChild(o),o=n;i.removeChild(t)}Gc.define(Wc,{aspected:!0});class qc{constructor(e,t,i){this.fragment=e,this.factories=t,this.targets=i,this.behaviors=null,this.unbindables=[],this.source=null,this.isBound=!1,this.sourceLifetime=al.unknown,this.context=this,this.index=0,this.length=0,this.firstChild=e.firstChild,this.lastChild=e.lastChild}get event(){return dl.getEvent()}get isEven(){return this.index%2==0}get isOdd(){return this.index%2!=0}get isFirst(){return 0===this.index}get isInMiddle(){return!this.isFirst&&!this.isLast}get isLast(){return this.index===this.length-1}eventDetail(){return this.event.detail}eventTarget(){return this.event.target}appendTo(e){e.appendChild(this.fragment)}insertBefore(e){if(this.fragment.hasChildNodes())e.parentNode.insertBefore(this.fragment,e);else{const t=this.lastChild;if(e.previousSibling===t)return;const i=e.parentNode;let n,o=this.firstChild;for(;o!==t;)n=o.nextSibling,i.insertBefore(o,e),o=n;i.insertBefore(t,e)}}remove(){const e=this.fragment,t=this.lastChild;let i,n=this.firstChild;for(;n!==t;)i=n.nextSibling,e.appendChild(n),n=i;e.appendChild(t)}dispose(){Kc(this.firstChild,this.lastChild),this.unbind()}onUnbind(e){this.unbindables.push(e)}bind(e,t=this){if(this.source===e)return;let i=this.behaviors;if(null===i){this.source=e,this.context=t,this.behaviors=i=new Array(this.factories.length);const n=this.factories;for(let e=0,t=n.length;e<t;++e){const t=n[e].createBehavior();t.bind(this),i[e]=t}}else{null!==this.source&&this.evaluateUnbindables(),this.isBound=!1,this.source=e,this.context=t;for(let e=0,t=i.length;e<t;++e)i[e].bind(this)}this.isBound=!0}unbind(){this.isBound&&null!==this.source&&(this.evaluateUnbindables(),this.source=null,this.context=this,this.isBound=!1)}evaluateUnbindables(){const e=this.unbindables;for(let t=0,i=e.length;t<i;++t)e[t].unbind(this);e.length=0}static disposeContiguousBatch(e){if(0!==e.length){Kc(e[0].firstChild,e[e.length-1].lastChild);for(let t=0,i=e.length;t<i;++t)e[t].unbind()}}}ol(qc),sl.defineProperty(qc.prototype,"index"),sl.defineProperty(qc.prototype,"length");const Yc=(e,t)=>`${e}.${t}`,Xc={},Jc={index:0,node:null};function Qc(e){e.startsWith("fast-")||el.warn(1204,{name:e})}const ed=new Proxy(document.createElement("div"),{get(e,t){Qc(t);const i=Reflect.get(e,t);return Ks(i)?i.bind(e):i},set(e,t,i){return Qc(t),Reflect.set(e,t,i)}});class td{constructor(e,t,i){this.fragment=e,this.directives=t,this.policy=i,this.proto=null,this.nodeIds=new Set,this.descriptors={},this.factories=[]}addFactory(e,t,i,n,o){var r,a;this.nodeIds.has(i)||(this.nodeIds.add(i),this.addTargetDescriptor(t,i,n)),e.id=null!==(r=e.id)&&void 0!==r?r:Hc(),e.targetNodeId=i,e.targetTagName=o,e.policy=null!==(a=e.policy)&&void 0!==a?a:this.policy,this.factories.push(e)}freeze(){return this.proto=Object.create(null,this.descriptors),this}addTargetDescriptor(e,t,i){const n=this.descriptors;if("r"===t||"h"===t||n[t])return;if(!n[e]){const t=e.lastIndexOf("."),i=e.substring(0,t),n=parseInt(e.substring(t+1));this.addTargetDescriptor(i,e,n)}let o=Xc[t];if(!o){const n=`_${t}`;Xc[t]=o={get(){var t;return null!==(t=this[n])&&void 0!==t?t:this[n]=this[e].childNodes[i]}}}n[t]=o}createView(e){const t=this.fragment.cloneNode(!0),i=Object.create(this.proto);i.r=t,i.h=null!=e?e:ed;for(const e of this.nodeIds)i[e];return new qc(t,this.factories,i)}}function id(e,t,i,n,o,r=!1){const a=i.attributes,s=e.directives;for(let l=0,c=a.length;l<c;++l){const d=a[l],u=d.value,h=Zc.parse(u,s);let p=null;null===h?r&&(p=new Wc(Rc((()=>u),e.policy)),Gc.assignAspect(p,d.name)):p=ad.aggregate(h,e.policy),null!==p&&(i.removeAttributeNode(d),l--,c--,e.addFactory(p,t,n,o,i.tagName))}}function nd(e,t,i){let n=0,o=t.firstChild;for(;o;){const t=od(e,i,o,n);o=t.node,n=t.index}}function od(e,t,i,n){const o=Yc(t,n);switch(i.nodeType){case 1:id(e,t,i,o,n),nd(e,i,o);break;case 3:return function(e,t,i,n,o){const r=Zc.parse(t.textContent,e.directives);if(null===r)return Jc.node=t.nextSibling,Jc.index=o+1,Jc;let a,s=a=t;for(let t=0,l=r.length;t<l;++t){const l=r[t];0!==t&&(o++,n=Yc(i,o),a=s.parentNode.insertBefore(document.createTextNode(""),s.nextSibling)),qs(l)?a.textContent=l:(a.textContent=" ",Gc.assignAspect(l),e.addFactory(l,i,n,o,null)),s=a}return Jc.index=o+1,Jc.node=s.nextSibling,Jc}(e,i,t,o,n);case 8:const r=Zc.parse(i.data,e.directives);null!==r&&e.addFactory(ad.aggregate(r),t,o,n,null)}return Jc.index=n+1,Jc.node=i.nextSibling,Jc}const rd="TEMPLATE",ad={compile(e,t,i=Cl.policy){let n;if(qs(e)){n=document.createElement(rd),n.innerHTML=i.createHTML(e);const t=n.content.firstElementChild;null!==t&&t.tagName===rd&&(n=t)}else n=e;n.content.firstChild||n.content.lastChild||n.content.appendChild(document.createComment(""));const o=document.adoptNode(n.content),r=new td(o,t,i);var a,s;return id(r,"",n,"h",0,!0),s=t,((a=o.firstChild)&&8==a.nodeType&&null!==Zc.parse(a.data,s)||1===o.childNodes.length&&Object.keys(t).length>0)&&o.insertBefore(document.createComment(""),o.firstChild),nd(r,o,"r"),Jc.node=null,r.freeze()},setDefaultStrategy(e){this.compile=e},aggregate(e,t=Cl.policy){if(1===e.length)return e[0];let i,n,o,r=!1;const a=e.length,s=e.map((e=>qs(e)?()=>e:(i=e.sourceAspect||i,n=e.dataBinding||n,r=r||e.dataBinding.isVolatile,o=o||e.dataBinding.policy,e.dataBinding.evaluate)));n.evaluate=(e,t)=>{let i="";for(let n=0;n<a;++n)i+=s[n](e,t);return i},n.isVolatile=r,n.policy=null!=o?o:t;const l=new Wc(n);return Gc.assignAspect(l,i),l}},sd=/([ \x09\x0a\x0c\x0d])([^\0-\x1F\x7F-\x9F "'>=/]+)([ \x09\x0a\x0c\x0d]*=[ \x09\x0a\x0c\x0d]*(?:[^ \x09\x0a\x0c\x0d"'`<>=]*|"[^"]*|'[^']*))$/,ld=Object.create(null);class cd{constructor(e,t=ld){this.html=e,this.factories=t}createHTML(e){const t=this.factories;for(const i in t)e(t[i]);return this.html}}function dd(e,t,i,n=Gc.getForInstance(e)){if(n.aspected){const i=sd.exec(t);null!==i&&Gc.assignAspect(e,i[2])}return e.createHTML(i)}cd.empty=new cd(""),Gc.define(cd);class ud{constructor(e,t={},i){this.policy=i,this.result=null,this.html=e,this.factories=t}create(e){return null===this.result&&(this.result=ad.compile(this.html,this.factories,this.policy)),this.result.createView(e)}inline(){return new cd(qs(this.html)?this.html:this.html.innerHTML,this.factories)}withPolicy(e){if(this.result)throw el.error(1208);if(this.policy)throw el.error(1207);return this.policy=e,this}render(e,t,i){const n=this.create(i);return n.bind(e),n.appendTo(t),n}static create(e,t,i){let n="";const o=Object.create(null),r=e=>{var t;const i=null!==(t=e.id)&&void 0!==t?t:e.id=Hc();return o[i]=e,i};for(let i=0,o=e.length-1;i<o;++i){const o=e[i];let a,s=t[i];if(n+=o,Ks(s))s=new Wc(Jl(s));else if(s instanceof Yl)s=new Wc(s);else if(!(a=Gc.getForInstance(s))){const e=s;s=new Wc(Rc((()=>e)))}n+=dd(s,o,r,a)}return new ud(n+e[e.length-1],o,i)}}ol(ud);const hd=(e,...t)=>{if(Array.isArray(e)&&Array.isArray(e.raw))return ud.create(e,t);throw el.error(1206)};hd.partial=e=>new cd(e);class pd extends jc{bind(e){e.source[this.options]=e.targets[this.targetNodeId]}}Gc.define(pd);const gd=e=>new pd(e),fd=()=>null;function md(e){return void 0===e?fd:Ks(e)?e:()=>e}function vd(e,t,i){const n=Ks(e)?e:()=>e,o=md(t),r=md(i);return(e,t)=>n(e,t)?o(e,t):r(e,t)}class yd{constructor(e,t,i){this.index=e,this.removed=t,this.addedCount=i}adjustTo(e){let t=this.index;const i=e.length;return t>i?t=i-this.addedCount:t<0&&(t=i+this.removed.length+t-this.addedCount),this.index=t<0?0:t,this}}const Cd=Object.freeze({reset:1,splice:2,optimized:3}),bd=new yd(0,tl,0);bd.reset=!0;const Sd=[bd];function xd(e,t,i,n,o,r){let a=0,s=0;const l=Math.min(i-t,r-o);if(0===t&&0===o&&(a=function(e,t,i){for(let n=0;n<i;++n)if(e[n]!==t[n])return n;return i}(e,n,l)),i===e.length&&r===n.length&&(s=function(e,t,i){let n=e.length,o=t.length,r=0;for(;r<i&&e[--n]===t[--o];)r++;return r}(e,n,l-a)),o+=a,r-=s,(i-=s)-(t+=a)==0&&r-o==0)return tl;if(t===i){const e=new yd(t,[],0);for(;o<r;)e.removed.push(n[o++]);return[e]}if(o===r)return[new yd(t,[],i-t)];const c=function(e){let t=e.length-1,i=e[0].length-1,n=e[t][i];const o=[];for(;t>0||i>0;){if(0===t){o.push(2),i--;continue}if(0===i){o.push(3),t--;continue}const r=e[t-1][i-1],a=e[t-1][i],s=e[t][i-1];let l;l=a<s?a<r?a:r:s<r?s:r,l===r?(r===n?o.push(0):(o.push(1),n=r),t--,i--):l===a?(o.push(3),t--,n=a):(o.push(2),i--,n=s)}return o.reverse()}(function(e,t,i,n,o,r){const a=r-o+1,s=i-t+1,l=new Array(a);let c,d;for(let e=0;e<a;++e)l[e]=new Array(s),l[e][0]=e;for(let e=0;e<s;++e)l[0][e]=e;for(let i=1;i<a;++i)for(let r=1;r<s;++r)e[t+r-1]===n[o+i-1]?l[i][r]=l[i-1][r-1]:(c=l[i-1][r]+1,d=l[i][r-1]+1,l[i][r]=c<d?c:d);return l}(e,t,i,n,o,r)),d=[];let u,h=t,p=o;for(let e=0;e<c.length;++e)switch(c[e]){case 0:void 0!==u&&(d.push(u),u=void 0),h++,p++;break;case 1:void 0===u&&(u=new yd(h,[],0)),u.addedCount++,h++,u.removed.push(n[p]),p++;break;case 2:void 0===u&&(u=new yd(h,[],0)),u.addedCount++,h++;break;case 3:void 0===u&&(u=new yd(h,[],0)),u.removed.push(n[p]),p++}return void 0!==u&&d.push(u),d}function Td(e,t){let i=!1,n=0;for(let l=0;l<t.length;l++){const c=t[l];if(c.index+=n,i)continue;const d=(o=e.index,r=e.index+e.removed.length,a=c.index,s=c.index+c.addedCount,r<a||s<o?-1:r===a||s===o?0:o<a?r<s?r-a:s-a:s<r?s-o:r-o);if(d>=0){t.splice(l,1),l--,n-=c.addedCount-c.removed.length,e.addedCount+=c.addedCount-d;const o=e.removed.length+c.removed.length-d;if(e.addedCount||o){let t=c.removed;if(e.index<c.index){const i=e.removed.slice(0,c.index-e.index);i.push(...t),t=i}if(e.index+e.removed.length>c.index+c.addedCount){const i=e.removed.slice(c.index+c.addedCount-e.index);t.push(...i)}e.removed=t,c.index<e.index&&(e.index=c.index)}else i=!0}else if(e.index<c.index){i=!0,t.splice(l,0,e),l++;const o=e.addedCount-e.removed.length;c.index+=o,n+=o}}var o,r,a,s;i||t.push(e)}let wd=Object.freeze({support:Cd.optimized,normalize(e,t,i){return void 0===e?void 0===i?tl:function(e,t){let i=[];const n=[];for(let e=0,i=t.length;e<i;e++)Td(t[e],n);for(let t=0,o=n.length;t<o;++t){const o=n[t];1!==o.addedCount||1!==o.removed.length?i=i.concat(xd(e,o.index,o.index+o.addedCount,o.removed,0,o.removed.length)):o.removed[0]!==e[o.index]&&i.push(o)}return i}(t,i):Sd},pop(e,t,i,n){const o=e.length>0,r=i.apply(e,n);return o&&t.addSplice(new yd(e.length,[r],0)),r},push(e,t,i,n){const o=i.apply(e,n);return t.addSplice(new yd(e.length-n.length,[],n.length).adjustTo(e)),o},reverse(e,t,i,n){const o=i.apply(e,n);return t.reset(e),o},shift(e,t,i,n){const o=e.length>0,r=i.apply(e,n);return o&&t.addSplice(new yd(0,[r],0)),r},sort(e,t,i,n){const o=i.apply(e,n);return t.reset(e),o},splice(e,t,i,n){const o=i.apply(e,n);return t.addSplice(new yd(+n[0],o,n.length>2?n.length-2:0).adjustTo(e)),o},unshift(e,t,i,n){const o=i.apply(e,n);return t.addSplice(new yd(0,[],n.length).adjustTo(e)),o}});function Od(e,t,i){Reflect.defineProperty(e,t,{value:i,enumerable:!1})}Object.freeze({reset:Sd,setDefaultStrategy(e){wd=e}});class Pd extends Xs{constructor(e){super(e),this.oldCollection=void 0,this.splices=void 0,this.needsQueue=!0,this._strategy=null,this._lengthObserver=void 0,this.call=this.flush,Od(e,"$fastController",this)}get strategy(){return this._strategy}set strategy(e){this._strategy=e}get lengthObserver(){let e=this._lengthObserver;if(void 0===e){const t=this.subject;this._lengthObserver=e={length:t.length,handleChange(){this.length!==t.length&&(this.length=t.length,sl.notify(e,"length"))}},this.subscribe(e)}return e}subscribe(e){this.flush(),super.subscribe(e)}addSplice(e){void 0===this.splices?this.splices=[e]:this.splices.push(e),this.enqueue()}reset(e){this.oldCollection=e,this.enqueue()}flush(){var e;const t=this.splices,i=this.oldCollection;void 0===t&&void 0===i||(this.needsQueue=!0,this.splices=void 0,this.oldCollection=void 0,this.notify((null!==(e=this._strategy)&&void 0!==e?e:wd).normalize(i,this.subject,t)))}enqueue(){this.needsQueue&&(this.needsQueue=!1,rl.enqueue(this))}}let Ad=!1;const Ed=Object.freeze({enable(){if(Ad)return;Ad=!0,sl.setArrayObserverFactory((e=>new Pd(e)));const e=Array.prototype;e.$fastPatch||(Od(e,"$fastPatch",1),[e.pop,e.push,e.reverse,e.shift,e.sort,e.splice,e.unshift].forEach((t=>{e[t.name]=function(...e){var i;const n=this.$fastController;return void 0===n?t.apply(this,e):(null!==(i=n.strategy)&&void 0!==i?i:wd)[t.name](this,n,t,e)}})))}});function kd(e){return Ks(e)?Jl(e):e instanceof Yl?e:Rc((()=>e))}const Id=Object.freeze({positioning:!1,recycle:!0});function Dd(e,t,i,n){e.context.parent=n.source,e.context.parentContext=n.context,e.bind(t[i])}function _d(e,t,i,n){e.context.parent=n.source,e.context.parentContext=n.context,e.context.length=t.length,e.context.index=i,e.bind(t[i])}class Nd{constructor(e){this.directive=e,this.items=null,this.itemsObserver=null,this.bindView=Dd,this.views=[],this.itemsBindingObserver=e.dataBinding.createObserver(this,e),this.templateBindingObserver=e.templateBinding.createObserver(this,e),e.options.positioning&&(this.bindView=_d)}bind(e){this.location=e.targets[this.directive.targetNodeId],this.controller=e,this.items=this.itemsBindingObserver.bind(e),this.template=this.templateBindingObserver.bind(e),this.observeItems(!0),this.refreshAllViews(),e.onUnbind(this)}unbind(){null!==this.itemsObserver&&this.itemsObserver.unsubscribe(this),this.unbindAllViews()}handleChange(e,t){if(t===this.itemsBindingObserver)this.items=this.itemsBindingObserver.bind(this.controller),this.observeItems(),this.refreshAllViews();else if(t===this.templateBindingObserver)this.template=this.templateBindingObserver.bind(this.controller),this.refreshAllViews(!0);else{if(!t[0])return;t[0].reset?this.refreshAllViews():this.updateViews(t)}}observeItems(e=!1){if(!this.items)return void(this.items=tl);const t=this.itemsObserver,i=this.itemsObserver=sl.getNotifier(this.items),n=t!==i;n&&null!==t&&t.unsubscribe(this),(n||e)&&i.subscribe(this)}updateViews(e){const t=this.views,i=this.bindView,n=this.items,o=this.template,r=this.controller,a=this.directive.options.recycle,s=[];let l=0,c=0;for(let d=0,u=e.length;d<u;++d){const u=e[d],h=u.removed;let p=0,g=u.index;const f=g+u.addedCount,m=t.splice(u.index,h.length),v=c=s.length+m.length;for(;g<f;++g){const e=t[g],d=e?e.firstChild:this.location;let u;a&&c>0?(p<=v&&m.length>0?(u=m[p],p++):(u=s[l],l++),c--):u=o.create(),t.splice(g,0,u),i(u,n,g,r),u.insertBefore(d)}m[p]&&s.push(...m.slice(p))}for(let e=l,t=s.length;e<t;++e)s[e].dispose();if(this.directive.options.positioning)for(let e=0,i=t.length;e<i;++e){const n=t[e].context;n.length=i,n.index=e}}refreshAllViews(e=!1){const t=this.items,i=this.template,n=this.location,o=this.bindView,r=this.controller;let a=t.length,s=this.views,l=s.length;if(0!==a&&!e&&this.directive.options.recycle||(qc.disposeContiguousBatch(s),l=0),0===l){this.views=s=new Array(a);for(let e=0;e<a;++e){const a=i.create();o(a,t,e,r),s[e]=a,a.insertBefore(n)}}else{let e=0;for(;e<a;++e)if(e<l)o(s[e],t,e,r);else{const a=i.create();o(a,t,e,r),s.push(a),a.insertBefore(n)}const c=s.splice(e,l-e);for(e=0,a=c.length;e<a;++e)c[e].dispose()}}unbindAllViews(){const e=this.views;for(let t=0,i=e.length;t<i;++t)e[t].unbind()}}class Rd{constructor(e,t,i){this.dataBinding=e,this.templateBinding=t,this.options=i,Ed.enable()}createHTML(e){return $c.comment(e(this))}createBehavior(){return new Nd(this)}}Gc.define(Rd);const Md=Object.freeze({prefix:"commerceui",shadowRootMode:"open",registry:customElements});let Ld;const Bd="fast-kernel";try{if(document.currentScript)Ld=document.currentScript.getAttribute(Bd);else{const e=document.getElementsByTagName("script");Ld=e[e.length-1].getAttribute(Bd)}}catch(e){Ld="isolate"}let Fd;switch(Ld){case"share":Fd=Object.freeze({updateQueue:1,observable:2,contextEvent:3,elementRegistry:4});break;case"share-v2":Fd=Object.freeze({updateQueue:1.2,observable:2.2,contextEvent:3.2,elementRegistry:4.2});break;default:const e=`-${Math.random().toString(36).substring(2,8)}`;Fd=Object.freeze({updateQueue:`1.2${e}`,observable:`2.2${e}`,contextEvent:`3.2${e}`,elementRegistry:`4.2${e}`})}const Ud=e=>"function"==typeof e,Hd=e=>"string"==typeof e,$d=()=>{};class Zd{constructor(e,t){this.sub1=void 0,this.sub2=void 0,this.spillover=void 0,this.subject=e,this.sub1=t}has(e){return void 0===this.spillover?this.sub1===e||this.sub2===e:-1!==this.spillover.indexOf(e)}subscribe(e){const t=this.spillover;if(void 0===t){if(this.has(e))return;if(void 0===this.sub1)return void(this.sub1=e);if(void 0===this.sub2)return void(this.sub2=e);this.spillover=[this.sub1,this.sub2,e],this.sub1=void 0,this.sub2=void 0}else-1===t.indexOf(e)&&t.push(e)}unsubscribe(e){const t=this.spillover;if(void 0===t)this.sub1===e?this.sub1=void 0:this.sub2===e&&(this.sub2=void 0);else{const i=t.indexOf(e);-1!==i&&t.splice(i,1)}}notify(e){const t=this.spillover,i=this.subject;if(void 0===t){const t=this.sub1,n=this.sub2;void 0!==t&&t.handleChange(i,e),void 0!==n&&n.handleChange(i,e)}else for(let n=0,o=t.length;n<o;++n)t[n].handleChange(i,e)}}class Vd{constructor(e){this.subscribers={},this.subjectSubscribers=null,this.subject=e}notify(e){var t,i;null===(t=this.subscribers[e])||void 0===t||t.notify(e),null===(i=this.subjectSubscribers)||void 0===i||i.notify(e)}subscribe(e,t){var i,n;let o;o=t?null!==(i=this.subscribers[t])&&void 0!==i?i:this.subscribers[t]=new Zd(this.subject):null!==(n=this.subjectSubscribers)&&void 0!==n?n:this.subjectSubscribers=new Zd(this.subject),o.subscribe(e)}unsubscribe(e,t){var i,n;t?null===(i=this.subscribers[t])||void 0===i||i.unsubscribe(e):null===(n=this.subjectSubscribers)||void 0===n||n.unsubscribe(e)}}!function(){if("undefined"==typeof globalThis)if("undefined"!=typeof global)global.globalThis=global;else if("undefined"!=typeof self)self.globalThis=self;else if("undefined"!=typeof window)window.globalThis=window;else{const e=new Function("return this")();e.globalThis=e}}();const Gd={configurable:!1,enumerable:!1,writable:!1};void 0===globalThis.FAST&&Reflect.defineProperty(globalThis,"FAST",Object.assign({value:Object.create(null)},Gd));const jd=globalThis.FAST;if(void 0===jd.getById){const e=Object.create(null);Reflect.defineProperty(jd,"getById",Object.assign({value(t,i){let n=e[t];return void 0===n&&(n=i?e[t]=i():null),n}},Gd))}void 0===jd.error&&Object.assign(jd,{warn(){},error(e){return new Error(`Error ${e}`)},addMessages(){}});const zd=Object.freeze([]);function Wd(){const e=new Map;return Object.freeze({register(t){return!e.has(t.type)&&(e.set(t.type,t),!0)},getByType(t){return e.get(t)},getForInstance(t){if(null!=t)return e.get(t.constructor)}})}function Kd(){const e=new WeakMap;return function(t){let i=e.get(t);if(void 0===i){let n=Reflect.getPrototypeOf(t);for(;void 0===i&&null!==n;)i=e.get(n),n=Reflect.getPrototypeOf(n);i=void 0===i?[]:i.slice(0),e.set(t,i)}return i}}function qd(e){e.prototype.toJSON=$d}const Yd=jd.getById(Fd.updateQueue,(()=>{const e=[],t=[],i=globalThis.requestAnimationFrame;let n=!0;function o(){if(t.length)throw t.shift()}function r(i){try{i.call()}catch(i){if(!n)throw e.length=0,i;t.push(i),setTimeout(o,0)}}function a(){let t=0;for(;t<e.length;)if(r(e[t]),t++,t>1024){for(let i=0,n=e.length-t;i<n;i++)e[i]=e[i+t];e.length-=t,t=0}e.length=0}function s(t){e.push(t),e.length<2&&(n?i(a):a())}return Object.freeze({enqueue:s,next:()=>new Promise(s),process:a,setMode:e=>n=e})})),Xd=Object.freeze({unknown:void 0,coupled:1}),Jd=jd.getById(Fd.observable,(()=>{const e=Yd.enqueue,t=/(:|&&|\|\||if|\?\.)/,i=new WeakMap;let n,o=e=>{throw jd.error(1101)};function r(e){var t;let n=null!==(t=e.$fastController)&&void 0!==t?t:i.get(e);return void 0===n&&(Array.isArray(e)?n=o(e):i.set(e,n=new Vd(e))),n}const a=Kd();class s{constructor(e){this.name=e,this.field=`_${e}`,this.callback=`${e}Changed`}getValue(e){return void 0!==n&&n.watch(e,this.name),e[this.field]}setValue(e,t){const i=this.field,n=e[i];if(n!==t){e[i]=t;const o=e[this.callback];Ud(o)&&o.call(e,n,t),r(e).notify(this.name)}}}class l extends Zd{constructor(e,t,i=!1){super(e,t),this.expression=e,this.isVolatileBinding=i,this.needsRefresh=!0,this.needsQueue=!0,this.isAsync=!0,this.first=this,this.last=null,this.propertySource=void 0,this.propertyName=void 0,this.notifier=void 0,this.next=void 0}setMode(e){this.isAsync=this.needsQueue=e}bind(e){this.controller=e;const t=this.observe(e.source,e.context);return!e.isBound&&this.requiresUnbind(e)&&e.onUnbind(this),t}requiresUnbind(e){return e.sourceLifetime!==Xd.coupled||this.first!==this.last||this.first.propertySource!==e.source}unbind(e){this.dispose()}observe(e,t){this.needsRefresh&&null!==this.last&&this.dispose();const i=n;let o;n=this.needsRefresh?this:void 0,this.needsRefresh=this.isVolatileBinding;try{o=this.expression(e,t)}finally{n=i}return o}disconnect(){this.dispose()}dispose(){if(null!==this.last){let e=this.first;for(;void 0!==e;)e.notifier.unsubscribe(this,e.propertyName),e=e.next;this.last=null,this.needsRefresh=this.needsQueue=this.isAsync}}watch(e,t){const i=this.last,o=r(e),a=null===i?this.first:{};if(a.propertySource=e,a.propertyName=t,a.notifier=o,o.subscribe(this,t),null!==i){if(!this.needsRefresh){let t;n=void 0,t=i.propertySource[i.propertyName],n=this,e===t&&(this.needsRefresh=!0)}i.next=a}this.last=a}handleChange(){this.needsQueue?(this.needsQueue=!1,e(this)):this.isAsync||this.call()}call(){null!==this.last&&(this.needsQueue=this.isAsync,this.notify(this))}*records(){let e=this.first;for(;void 0!==e;)yield e,e=e.next}}return qd(l),Object.freeze({setArrayObserverFactory(e){o=e},getNotifier:r,track(e,t){n&&n.watch(e,t)},trackVolatile(){n&&(n.needsRefresh=!0)},notify(e,t){r(e).notify(t)},defineProperty(e,t){Hd(t)&&(t=new s(t)),a(e).push(t),Reflect.defineProperty(e,t.name,{enumerable:!0,get(){return t.getValue(this)},set(e){t.setValue(this,e)}})},getAccessors:a,binding(e,t,i=this.isVolatileBinding(e)){return new l(e,t,i)},isVolatileBinding(e){return t.test(e.toString())}})}));function Qd(e,t){Jd.defineProperty(e,t)}const eu=jd.getById(Fd.contextEvent,(()=>{let e=null;return{get(){return e},set(t){e=t}}})),tu=Object.freeze({default:{index:0,length:0,get event(){return tu.getEvent()},eventDetail(){return this.event.detail},eventTarget(){return this.event.target}},getEvent(){return eu.get()},setEvent(e){eu.set(e)}});let iu;function nu(e){return e.map((e=>e instanceof ou?nu(e.styles):[e])).reduce(((e,t)=>e.concat(t)),[])}class ou{constructor(e){this.styles=e,this.targets=new WeakSet,this._strategy=null,this.behaviors=e.map((e=>e instanceof ou?e.behaviors:null)).reduce(((e,t)=>null===t?e:null===e?t:e.concat(t)),null)}get strategy(){return null===this._strategy&&this.withStrategy(iu),this._strategy}addStylesTo(e){this.strategy.addStylesTo(e),this.targets.add(e)}removeStylesFrom(e){this.strategy.removeStylesFrom(e),this.targets.delete(e)}isAttachedTo(e){return this.targets.has(e)}withBehaviors(...e){return this.behaviors=null===this.behaviors?e:this.behaviors.concat(e),this}withStrategy(e){return this._strategy=new e(nu(this.styles)),this}static setDefaultStrategy(e){iu=e}static normalize(e){return void 0===e?void 0:Array.isArray(e)?new ou(e):e instanceof ou?e:new ou([e])}}ou.supportsAdoptedStyleSheets=Array.isArray(document.adoptedStyleSheets)&&"replace"in CSSStyleSheet.prototype;const ru=Object.freeze({none:0,attribute:1,booleanAttribute:2,property:3,content:4,tokenList:5,event:6}),au=e=>e,su=globalThis.trustedTypes?globalThis.trustedTypes.createPolicy("fast-html",{createHTML:au}):{createHTML:au};let lu=Object.freeze({createHTML(e){return su.createHTML(e)},protect(e,t,i,n){return n}});const cu=lu,du=Object.freeze({get policy(){return lu},setPolicy(e){if(lu!==cu)throw jd.error(1201);lu=e},setAttribute(e,t,i){null==i?e.removeAttribute(t):e.setAttribute(t,i)},setBooleanAttribute(e,t,i){i?e.setAttribute(t,""):e.removeAttribute(t)}}),uu="boolean",hu="reflect",pu=Object.freeze({locate:Kd()}),gu={toView(e){return e?"true":"false"},fromView(e){return null!=e&&"false"!==e&&!1!==e&&0!==e}};function fu(e){if(null==e)return null;const t=1*e;return isNaN(t)?null:t}const mu={toView(e){const t=fu(e);return t?t.toString():t},fromView:fu};class vu{constructor(e,t,i=t.toLowerCase(),n=hu,o){this.guards=new Set,this.Owner=e,this.name=t,this.attribute=i,this.mode=n,this.converter=o,this.fieldName=`_${t}`,this.callbackName=`${t}Changed`,this.hasCallback=this.callbackName in e.prototype,n===uu&&void 0===o&&(this.converter=gu)}setValue(e,t){const i=e[this.fieldName],n=this.converter;void 0!==n&&(t=n.fromView(t)),i!==t&&(e[this.fieldName]=t,this.tryReflectToAttribute(e),this.hasCallback&&e[this.callbackName](i,t),e.$fastController.notify(this.name))}getValue(e){return Jd.track(e,this.name),e[this.fieldName]}onAttributeChangedCallback(e,t){this.guards.has(e)||(this.guards.add(e),this.setValue(e,t),this.guards.delete(e))}tryReflectToAttribute(e){const t=this.mode,i=this.guards;i.has(e)||"fromView"===t||Yd.enqueue((()=>{i.add(e);const n=e[this.fieldName];switch(t){case hu:const t=this.converter;du.setAttribute(e,this.attribute,void 0!==t?t.toView(n):n);break;case uu:du.setBooleanAttribute(e,this.attribute,n)}i.delete(e)}))}static collect(e,...t){const i=[];t.push(pu.locate(e));for(let n=0,o=t.length;n<o;++n){const o=t[n];if(void 0!==o)for(let t=0,n=o.length;t<n;++t){const n=o[t];Hd(n)?i.push(new vu(e,n)):i.push(new vu(e,n.property,n.attribute,n.mode,n.converter))}}return i}}function yu(e,t){let i;function n(e,t){arguments.length>1&&(i.property=t),pu.locate(e.constructor).push(i)}return arguments.length>1?(i={},void n(e,t)):(i=void 0===e?{}:e,n)}const Cu={mode:"open"},bu={},Su=new Set,xu=jd.getById(Fd.elementRegistry,(()=>Wd()));class Tu{constructor(e,t=e.definition){var i;this.platformDefined=!1,Hd(t)&&(t={name:t}),this.type=e,this.name=t.name,this.template=t.template,this.registry=null!==(i=t.registry)&&void 0!==i?i:customElements;const n=e.prototype,o=vu.collect(e,t.attributes),r=new Array(o.length),a={},s={};for(let e=0,t=o.length;e<t;++e){const t=o[e];r[e]=t.attribute,a[t.name]=t,s[t.attribute]=t,Jd.defineProperty(n,t)}Reflect.defineProperty(e,"observedAttributes",{value:r,enumerable:!0}),this.attributes=o,this.propertyLookup=a,this.attributeLookup=s,this.shadowOptions=void 0===t.shadowOptions?Cu:null===t.shadowOptions?void 0:Object.assign(Object.assign({},Cu),t.shadowOptions),this.elementOptions=void 0===t.elementOptions?bu:Object.assign(Object.assign({},bu),t.elementOptions),this.styles=ou.normalize(t.styles),xu.register(this)}get isDefined(){return this.platformDefined}define(e=this.registry){const t=this.type;return e.get(this.name)||(this.platformDefined=!0,e.define(this.name,t,this.elementOptions)),this}static compose(e,t){return Su.has(e)||xu.getByType(e)?new Tu(class extends e{},t):new Tu(e,t)}static registerBaseType(e){Su.add(e)}}Tu.getByType=xu.getByType,Tu.getForInstance=xu.getForInstance;const wu={bubbles:!0,composed:!0,cancelable:!0},Ou="isConnected",Pu=new WeakMap;function Au(e){var t,i;return null!==(i=null!==(t=e.shadowRoot)&&void 0!==t?t:Pu.get(e))&&void 0!==i?i:null}let Eu;class ku extends Vd{constructor(e,t){super(e),this.boundObservables=null,this.needsInitialization=!0,this.hasExistingShadowRoot=!1,this._template=null,this.stage=3,this.guardBehaviorConnection=!1,this.behaviors=null,this._mainStyles=null,this.$fastController=this,this.view=null,this.source=e,this.definition=t;const i=t.shadowOptions;if(void 0!==i){let t=e.shadowRoot;t?this.hasExistingShadowRoot=!0:(t=e.attachShadow(i),"closed"===i.mode&&Pu.set(e,t))}const n=Jd.getAccessors(e);if(n.length>0){const t=this.boundObservables=Object.create(null);for(let i=0,o=n.length;i<o;++i){const o=n[i].name,r=e[o];void 0!==r&&(delete e[o],t[o]=r)}}}get isConnected(){return Jd.track(this,Ou),1===this.stage}get context(){var e,t;return null!==(t=null===(e=this.view)||void 0===e?void 0:e.context)&&void 0!==t?t:tu.default}get isBound(){var e,t;return null!==(t=null===(e=this.view)||void 0===e?void 0:e.isBound)&&void 0!==t&&t}get sourceLifetime(){var e;return null===(e=this.view)||void 0===e?void 0:e.sourceLifetime}get template(){var e;if(null===this._template){const t=this.definition;this.source.resolveTemplate?this._template=this.source.resolveTemplate():t.template&&(this._template=null!==(e=t.template)&&void 0!==e?e:null)}return this._template}set template(e){this._template!==e&&(this._template=e,this.needsInitialization||this.renderTemplate(e))}get mainStyles(){var e;if(null===this._mainStyles){const t=this.definition;this.source.resolveStyles?this._mainStyles=this.source.resolveStyles():t.styles&&(this._mainStyles=null!==(e=t.styles)&&void 0!==e?e:null)}return this._mainStyles}set mainStyles(e){this._mainStyles!==e&&(null!==this._mainStyles&&this.removeStyles(this._mainStyles),this._mainStyles=e,this.needsInitialization||this.addStyles(e))}onUnbind(e){var t;null===(t=this.view)||void 0===t||t.onUnbind(e)}addBehavior(e){var t,i;const n=null!==(t=this.behaviors)&&void 0!==t?t:this.behaviors=new Map,o=null!==(i=n.get(e))&&void 0!==i?i:0;0===o?(n.set(e,1),e.addedCallback&&e.addedCallback(this),!e.connectedCallback||this.guardBehaviorConnection||1!==this.stage&&0!==this.stage||e.connectedCallback(this)):n.set(e,o+1)}removeBehavior(e,t=!1){const i=this.behaviors;if(null===i)return;const n=i.get(e);void 0!==n&&(1===n||t?(i.delete(e),e.disconnectedCallback&&3!==this.stage&&e.disconnectedCallback(this),e.removedCallback&&e.removedCallback(this)):i.set(e,n-1))}addStyles(e){var t;if(!e)return;const i=this.source;if(e instanceof HTMLElement)(null!==(t=Au(i))&&void 0!==t?t:this.source).append(e);else if(!e.isAttachedTo(i)){const t=e.behaviors;if(e.addStylesTo(i),null!==t)for(let e=0,i=t.length;e<i;++e)this.addBehavior(t[e])}}removeStyles(e){var t;if(!e)return;const i=this.source;if(e instanceof HTMLElement)(null!==(t=Au(i))&&void 0!==t?t:i).removeChild(e);else if(e.isAttachedTo(i)){const t=e.behaviors;if(e.removeStylesFrom(i),null!==t)for(let e=0,i=t.length;e<i;++e)this.removeBehavior(t[e])}}connect(){if(3!==this.stage)return;if(this.stage=0,null!==this.boundObservables){const e=this.source,t=this.boundObservables,i=Object.keys(t);for(let n=0,o=i.length;n<o;++n){const o=i[n];e[o]=t[o]}this.boundObservables=null}const e=this.behaviors;if(null!==e){this.guardBehaviorConnection=!0;for(const t of e.keys())t.connectedCallback&&t.connectedCallback(this);this.guardBehaviorConnection=!1}this.needsInitialization?(this.renderTemplate(this.template),this.addStyles(this.mainStyles),this.needsInitialization=!1):null!==this.view&&this.view.bind(this.source),this.stage=1,Jd.notify(this,Ou)}disconnect(){if(1!==this.stage)return;this.stage=2,Jd.notify(this,Ou),null!==this.view&&this.view.unbind();const e=this.behaviors;if(null!==e)for(const t of e.keys())t.disconnectedCallback&&t.disconnectedCallback(this);this.stage=3}onAttributeChangedCallback(e,t,i){const n=this.definition.attributeLookup[e];void 0!==n&&n.onAttributeChangedCallback(this.source,i)}emit(e,t,i){return 1===this.stage&&this.source.dispatchEvent(new CustomEvent(e,Object.assign(Object.assign({detail:t},wu),i)))}renderTemplate(e){var t;const i=this.source,n=null!==(t=Au(i))&&void 0!==t?t:i;if(null!==this.view)this.view.dispose(),this.view=null;else if(!this.needsInitialization||this.hasExistingShadowRoot){this.hasExistingShadowRoot=!1;for(let e=n.firstChild;null!==e;e=n.firstChild)n.removeChild(e)}e&&(this.view=e.render(i,n,i),this.view.sourceLifetime=Xd.coupled)}static forCustomElement(e){const t=e.$fastController;if(void 0!==t)return t;const i=Tu.getForInstance(e);if(void 0===i)throw jd.error(1401);return e.$fastController=new Eu(e,i)}static setStrategy(e){Eu=e}}function Iu(e){var t;return"adoptedStyleSheets"in e?e:null!==(t=Au(e))&&void 0!==t?t:e.getRootNode()}qd(ku),ku.setStrategy(ku);class Du{constructor(e){const t=Du.styleSheetCache;this.sheets=e.map((e=>{if(e instanceof CSSStyleSheet)return e;let i=t.get(e);return void 0===i&&(i=new CSSStyleSheet,i.replaceSync(e),t.set(e,i)),i}))}addStylesTo(e){Ru(Iu(e),this.sheets)}removeStylesFrom(e){Mu(Iu(e),this.sheets)}}Du.styleSheetCache=new Map;let _u=0;function Nu(e){return e===document?document.body:e}let Ru=(e,t)=>{e.adoptedStyleSheets=[...e.adoptedStyleSheets,...t]},Mu=(e,t)=>{e.adoptedStyleSheets=e.adoptedStyleSheets.filter((e=>-1===t.indexOf(e)))};if(ou.supportsAdoptedStyleSheets){try{document.adoptedStyleSheets.push(),document.adoptedStyleSheets.splice(),Ru=(e,t)=>{e.adoptedStyleSheets.push(...t)},Mu=(e,t)=>{for(const i of t){const t=e.adoptedStyleSheets.indexOf(i);-1!==t&&e.adoptedStyleSheets.splice(t,1)}}}catch(e){}ou.setDefaultStrategy(Du)}else ou.setDefaultStrategy(class{constructor(e){this.styles=e,this.styleClass="fast-"+ ++_u}addStylesTo(e){e=Nu(Iu(e));const t=this.styles,i=this.styleClass;for(let n=0;n<t.length;n++){const o=document.createElement("style");o.innerHTML=t[n],o.className=i,e.append(o)}}removeStylesFrom(e){const t=(e=Nu(Iu(e))).querySelectorAll(`.${this.styleClass}`);for(let i=0,n=t.length;i<n;++i)e.removeChild(t[i])}});function Lu(e){const t=class extends e{constructor(){super(),ku.forCustomElement(this)}$emit(e,t,i){return this.$fastController.emit(e,t,i)}connectedCallback(){this.$fastController.connect()}disconnectedCallback(){this.$fastController.disconnect()}attributeChangedCallback(e,t,i){this.$fastController.onAttributeChangedCallback(e,t,i)}};return Tu.registerBaseType(t),t}const Bu=Object.assign(Lu(HTMLElement),{from:function(e){return Lu(e)},define:function(e,t){return Ud(e)?Tu.compose(e,t).define().type:Tu.compose(this,e).define().type},compose:function(e,t){return Ud(e)?Tu.compose(e,t):Tu.compose(this,e)}}),Fu="circle",Uu="square",Hu="small",$u="medium";class Zu extends Bu{constructor(){super(...arguments),this.shape=Uu,this.size=$u,this.rowMaxItems=null,this.selectedIndex=null,this.items=[],this.isExpanded=!1,this._rowMaxItems=null,this.handleExpandButtonClick=()=>{this.isExpanded=!this.isExpanded}}rowMaxItemsChanged(e,t){this._rowMaxItems=t&&t>1?this.rowMaxItems:null}selectedIndexChanged(){if(this.items){let e=this.items.slice();for(let t=0;t<e.length;t++)e.splice(t,1,{...e[t],selected:this.selectedIndex===t&&!e[t].disabled});this.items=e}}getVisibleSwatches(){if(!this.items)return;let e=this.items.slice();this._rowMaxItems&&this.items.length>this._rowMaxItems&&(e=this.items.slice(0,this._rowMaxItems-1));for(let t=0;t<e.length;t++)e[t].selected=this.selectedIndex===t&&!e[t].disabled;return e}getOverflowSwatches(){if(!this.items||this.items.length<=this._rowMaxItems||!this.isExpanded)return;let e=this.items.slice(this._rowMaxItems-1,this.items.length);for(let t=0;t<e.length;t++){const i=t+this._rowMaxItems-1;e[t].selected=this.selectedIndex===i&&!e[t].disabled}return e}handleSwatchClick(e){var t;if(e.disabled)return;const i=this.items.indexOf(e);i!==this.selectedIndex&&(this.selectedIndex=i,null===(t=this.onselectionchange)||void 0===t||t.call(this,e),this.$emit("change",e))}}(0,o.gn)([yu],Zu.prototype,"shape",void 0),(0,o.gn)([yu],Zu.prototype,"size",void 0),(0,o.gn)([yu({attribute:"row-max-items",converter:mu})],Zu.prototype,"rowMaxItems",void 0),(0,o.gn)([yu({attribute:"selected-index",converter:mu})],Zu.prototype,"selectedIndex",void 0),(0,o.gn)([yu],Zu.prototype,"items",void 0),(0,o.gn)([Qd],Zu.prototype,"isExpanded",void 0),(0,o.gn)([Qd],Zu.prototype,"_rowMaxItems",void 0);class Vu{constructor(e,t,i=!1){this.evaluate=e,this.policy=t,this.isVolatile=i}}class Gu extends Vu{createObserver(e){return Jd.binding(this.evaluate,e,this.isVolatile)}}function ju(e,t,i=Jd.isVolatileBinding(e)){return new Gu(e,t,i)}const zu=Wd(),Wu=Object.freeze({getForInstance:zu.getForInstance,getByType:zu.getByType,define(e){return zu.register({type:e}),e}});function Ku(e,t,i){t.source.style.setProperty(e.targetAspect,i.bind(t))}class qu{constructor(e,t){this.dataBinding=e,this.targetAspect=t}createCSS(e){return e(this),`var(${this.targetAspect})`}addedCallback(e){var t;const i=e.source;if(!i.$cssBindings){i.$cssBindings=new Map;const e=i.setAttribute;i.setAttribute=(t,n)=>{e.call(i,t,n),"style"===t&&i.$cssBindings.forEach(((e,t)=>Ku(t,e.controller,e.observer)))}}const n=null!==(t=e[this.targetAspect])&&void 0!==t?t:e[this.targetAspect]=this.dataBinding.createObserver(this,this);n.controller=e,e.source.$cssBindings.set(this,{controller:e,observer:n})}connectedCallback(e){Ku(this,e,e[this.targetAspect])}removedCallback(e){e.source.$cssBindings&&e.source.$cssBindings.delete(this)}handleChange(e,t){Ku(this,t.controller,t)}}Wu.define(qu);const Yu=`${Math.random().toString(36).substring(2,8)}`;let Xu=0;const Ju=()=>`--v${Yu}${++Xu}`;function Qu(e,t){const i=[];let n="";const o=[],r=e=>{o.push(e)};for(let o=0,a=e.length-1;o<a;++o){n+=e[o];let a=t[o];Ud(a)?a=new qu(ju(a),Ju()).createCSS(r):a instanceof Vu?a=new qu(a,Ju()).createCSS(r):void 0!==Wu.getForInstance(a)&&(a=a.createCSS(r)),a instanceof ou||a instanceof CSSStyleSheet?(""!==n.trim()&&(i.push(n),n=""),i.push(a)):n+=a}return n+=e[e.length-1],""!==n.trim()&&i.push(n),{styles:i,behaviors:o}}const eh=(e,...t)=>{const{styles:i,behaviors:n}=Qu(e,t),o=new ou(i);return n.length?o.withBehaviors(...n):o};class th{constructor(e,t){this.behaviors=t,this.css="";const i=e.reduce(((e,t)=>(Hd(t)?this.css+=t:e.push(t),e)),[]);i.length&&(this.styles=new ou(i))}createCSS(e){return this.behaviors.forEach(e),this.styles&&e(this),this.css}addedCallback(e){e.addStyles(this.styles)}removedCallback(e){e.removeStyles(this.styles)}}Wu.define(th),eh.partial=(e,...t)=>{const{styles:i,behaviors:n}=Qu(e,t);return new th(i,n)};const ih=eh`
:host {
display: block;
}
.container {
display: flex;
flex-wrap: wrap;
gap: ${We};
}
.expand-button {
background: transparent;
border: none;
padding: 0 0 ${qe} ${je};
color: ${ke};
font-family: ${He};
font-size: ${dc};
line-height: ${hc};
font-weight: ${uc};
text-align: start;
cursor: pointer;
}
:host([size=${Hu}]) .expand-button {
min-width: 24px;
height: 24px;
}
:host([size=${$u}]) .expand-button {
min-width: 32px;
height: 32px;
}
:host([aria-expanded="true"]) .expand-button {
padding: 0 0 ${qe};
text-align: center;
}
`;class nh extends Vu{createObserver(){return this}bind(e){return this.evaluate(e.source,e.context)}}function oh(e,t){return new nh(e,t)}qd(nh);const rh=`fast-${Math.random().toString(36).substring(2,8)}`,ah=`${rh}{`,sh=`}${rh}`,lh=sh.length;let ch=0;const dh=()=>`${rh}-${++ch}`,uh=Object.freeze({interpolation:e=>`${ah}${e}${sh}`,attribute:e=>`${dh()}="${ah}${e}${sh}"`,comment:e=>`\x3c!--${ah}${e}${sh}--\x3e`}),hh=Object.freeze({parse(e,t){const i=e.split(ah);if(1===i.length)return null;const n=[];for(let e=0,o=i.length;e<o;++e){const o=i[e],r=o.indexOf(sh);let a;if(-1===r)a=o;else{const e=o.substring(0,r);n.push(t[e]),a=o.substring(r+lh)}""!==a&&n.push(a)}return n}}),ph=Wd(),gh=Object.freeze({getForInstance:ph.getForInstance,getByType:ph.getByType,define(e,t){return(t=t||{}).type=e,ph.register(t),e},assignAspect(e,t){if(t)switch(e.sourceAspect=t,t[0]){case":":e.targetAspect=t.substring(1),e.aspectType="classList"===e.targetAspect?ru.tokenList:ru.property;break;case"?":e.targetAspect=t.substring(1),e.aspectType=ru.booleanAttribute;break;case"@":e.targetAspect=t.substring(1),e.aspectType=ru.event;break;default:e.targetAspect=t,e.aspectType=ru.attribute}else e.aspectType=ru.content}});qd(class{constructor(e){this.options=e}createHTML(e){return uh.attribute(e(this))}createBehavior(){return this}});const fh={[ru.attribute]:du.setAttribute,[ru.booleanAttribute]:du.setBooleanAttribute,[ru.property]:(e,t,i)=>e[t]=i,[ru.content]:function(e,t,i,n){if(null==i&&(i=""),i.create){e.textContent="";let t=e.$fastView;void 0===t?t=i.create():e.$fastTemplate!==i&&(t.isComposed&&(t.remove(),t.unbind()),t=i.create()),t.isComposed?t.needsBindOnly&&(t.needsBindOnly=!1,t.bind(n.source,n.context)):(t.isComposed=!0,t.bind(n.source,n.context),t.insertBefore(e),e.$fastView=t,e.$fastTemplate=i)}else{const t=e.$fastView;void 0!==t&&t.isComposed&&(t.isComposed=!1,t.remove(),t.needsBindOnly?t.needsBindOnly=!1:t.unbind()),e.textContent=i}},[ru.tokenList]:function(e,t,i){var n;const o=`${this.id}-t`,r=null!==(n=e[o])&&void 0!==n?n:e[o]={v:0,cv:Object.create(null)},a=r.cv;let s=r.v;const l=e[t];if(null!=i&&i.length){const e=i.split(/\s+/);for(let t=0,i=e.length;t<i;++t){const i=e[t];""!==i&&(a[i]=s,l.add(i))}}if(r.v=s+1,0!==s){s-=1;for(const e in a)a[e]===s&&l.remove(e)}},[ru.event]:()=>{}};class mh{constructor(e){this.dataBinding=e,this.updateTarget=null,this.aspectType=ru.content}createHTML(e){return uh.interpolation(e(this))}createBehavior(){var e;if(null===this.updateTarget){const t=fh[this.aspectType],i=null!==(e=this.dataBinding.policy)&&void 0!==e?e:this.policy;if(!t)throw jd.error(1205);this.data=`${this.id}-d`,this.updateTarget=i.protect(this.targetTagName,this.aspectType,this.targetAspect,t)}return this}bind(e){var t;const i=e.targets[this.targetNodeId];switch(this.aspectType){case ru.event:i[this.data]=e,i.addEventListener(this.targetAspect,this,this.dataBinding.options);break;case ru.content:e.onUnbind(this);default:const n=null!==(t=i[this.data])&&void 0!==t?t:i[this.data]=this.dataBinding.createObserver(this,this);n.target=i,n.controller=e,this.updateTarget(i,this.targetAspect,n.bind(e),e)}}unbind(e){const t=e.targets[this.targetNodeId].$fastView;void 0!==t&&t.isComposed&&(t.unbind(),t.needsBindOnly=!0)}handleEvent(e){const t=e.currentTarget[this.data];if(t.isBound){tu.setEvent(e);const i=this.dataBinding.evaluate(t.source,t.context);tu.setEvent(null),!0!==i&&e.preventDefault()}}handleChange(e,t){const i=t.target,n=t.controller;this.updateTarget(i,this.targetAspect,t.bind(n),n)}}function vh(e,t){const i=e.parentNode;let n,o=e;for(;o!==t;)n=o.nextSibling,i.removeChild(o),o=n;i.removeChild(t)}gh.define(mh,{aspected:!0});class yh{constructor(e,t,i){this.fragment=e,this.factories=t,this.targets=i,this.behaviors=null,this.unbindables=[],this.source=null,this.isBound=!1,this.sourceLifetime=Xd.unknown,this.context=this,this.index=0,this.length=0,this.firstChild=e.firstChild,this.lastChild=e.lastChild}get event(){return tu.getEvent()}get isEven(){return this.index%2==0}get isOdd(){return this.index%2!=0}get isFirst(){return 0===this.index}get isInMiddle(){return!this.isFirst&&!this.isLast}get isLast(){return this.index===this.length-1}eventDetail(){return this.event.detail}eventTarget(){return this.event.target}appendTo(e){e.appendChild(this.fragment)}insertBefore(e){if(this.fragment.hasChildNodes())e.parentNode.insertBefore(this.fragment,e);else{const t=this.lastChild;if(e.previousSibling===t)return;const i=e.parentNode;let n,o=this.firstChild;for(;o!==t;)n=o.nextSibling,i.insertBefore(o,e),o=n;i.insertBefore(t,e)}}remove(){const e=this.fragment,t=this.lastChild;let i,n=this.firstChild;for(;n!==t;)i=n.nextSibling,e.appendChild(n),n=i;e.appendChild(t)}dispose(){vh(this.firstChild,this.lastChild),this.unbind()}onUnbind(e){this.unbindables.push(e)}bind(e,t=this){if(this.source===e)return;let i=this.behaviors;if(null===i){this.source=e,this.context=t,this.behaviors=i=new Array(this.factories.length);const n=this.factories;for(let e=0,t=n.length;e<t;++e){const t=n[e].createBehavior();t.bind(this),i[e]=t}}else{null!==this.source&&this.evaluateUnbindables(),this.isBound=!1,this.source=e,this.context=t;for(let e=0,t=i.length;e<t;++e)i[e].bind(this)}this.isBound=!0}unbind(){this.isBound&&null!==this.source&&(this.evaluateUnbindables(),this.source=null,this.context=this,this.isBound=!1)}evaluateUnbindables(){const e=this.unbindables;for(let t=0,i=e.length;t<i;++t)e[t].unbind(this);e.length=0}static disposeContiguousBatch(e){if(0!==e.length){vh(e[0].firstChild,e[e.length-1].lastChild);for(let t=0,i=e.length;t<i;++t)e[t].unbind()}}}qd(yh),Jd.defineProperty(yh.prototype,"index"),Jd.defineProperty(yh.prototype,"length");const Ch=(e,t)=>`${e}.${t}`,bh={},Sh={index:0,node:null};function xh(e){e.startsWith("fast-")||jd.warn(1204,{name:e})}const Th=new Proxy(document.createElement("div"),{get(e,t){xh(t);const i=Reflect.get(e,t);return Ud(i)?i.bind(e):i},set(e,t,i){return xh(t),Reflect.set(e,t,i)}});class wh{constructor(e,t,i){this.fragment=e,this.directives=t,this.policy=i,this.proto=null,this.nodeIds=new Set,this.descriptors={},this.factories=[]}addFactory(e,t,i,n,o){var r,a;this.nodeIds.has(i)||(this.nodeIds.add(i),this.addTargetDescriptor(t,i,n)),e.id=null!==(r=e.id)&&void 0!==r?r:dh(),e.targetNodeId=i,e.targetTagName=o,e.policy=null!==(a=e.policy)&&void 0!==a?a:this.policy,this.factories.push(e)}freeze(){return this.proto=Object.create(null,this.descriptors),this}addTargetDescriptor(e,t,i){const n=this.descriptors;if("r"===t||"h"===t||n[t])return;if(!n[e]){const t=e.lastIndexOf("."),i=e.substring(0,t),n=parseInt(e.substring(t+1));this.addTargetDescriptor(i,e,n)}let o=bh[t];if(!o){const n=`_${t}`;bh[t]=o={get(){var t;return null!==(t=this[n])&&void 0!==t?t:this[n]=this[e].childNodes[i]}}}n[t]=o}createView(e){const t=this.fragment.cloneNode(!0),i=Object.create(this.proto);i.r=t,i.h=null!=e?e:Th;for(const e of this.nodeIds)i[e];return new yh(t,this.factories,i)}}function Oh(e,t,i,n,o,r=!1){const a=i.attributes,s=e.directives;for(let l=0,c=a.length;l<c;++l){const d=a[l],u=d.value,h=hh.parse(u,s);let p=null;null===h?r&&(p=new mh(oh((()=>u),e.policy)),gh.assignAspect(p,d.name)):p=kh.aggregate(h,e.policy),null!==p&&(i.removeAttributeNode(d),l--,c--,e.addFactory(p,t,n,o,i.tagName))}}function Ph(e,t,i){let n=0,o=t.firstChild;for(;o;){const t=Ah(e,i,o,n);o=t.node,n=t.index}}function Ah(e,t,i,n){const o=Ch(t,n);switch(i.nodeType){case 1:Oh(e,t,i,o,n),Ph(e,i,o);break;case 3:return function(e,t,i,n,o){const r=hh.parse(t.textContent,e.directives);if(null===r)return Sh.node=t.nextSibling,Sh.index=o+1,Sh;let a,s=a=t;for(let t=0,l=r.length;t<l;++t){const l=r[t];0!==t&&(o++,n=Ch(i,o),a=s.parentNode.insertBefore(document.createTextNode(""),s.nextSibling)),Hd(l)?a.textContent=l:(a.textContent=" ",gh.assignAspect(l),e.addFactory(l,i,n,o,null)),s=a}return Sh.index=o+1,Sh.node=s.nextSibling,Sh}(e,i,t,o,n);case 8:const r=hh.parse(i.data,e.directives);null!==r&&e.addFactory(kh.aggregate(r),t,o,n,null)}return Sh.index=n+1,Sh.node=i.nextSibling,Sh}const Eh="TEMPLATE",kh={compile(e,t,i=du.policy){let n;if(Hd(e)){n=document.createElement(Eh),n.innerHTML=i.createHTML(e);const t=n.content.firstElementChild;null!==t&&t.tagName===Eh&&(n=t)}else n=e;n.content.firstChild||n.content.lastChild||n.content.appendChild(document.createComment(""));const o=document.adoptNode(n.content),r=new wh(o,t,i);var a,s;return Oh(r,"",n,"h",0,!0),s=t,((a=o.firstChild)&&8==a.nodeType&&null!==hh.parse(a.data,s)||1===o.childNodes.length&&Object.keys(t).length>0)&&o.insertBefore(document.createComment(""),o.firstChild),Ph(r,o,"r"),Sh.node=null,r.freeze()},setDefaultStrategy(e){this.compile=e},aggregate(e,t=du.policy){if(1===e.length)return e[0];let i,n,o,r=!1;const a=e.length,s=e.map((e=>Hd(e)?()=>e:(i=e.sourceAspect||i,n=e.dataBinding||n,r=r||e.dataBinding.isVolatile,o=o||e.dataBinding.policy,e.dataBinding.evaluate)));n.evaluate=(e,t)=>{let i="";for(let n=0;n<a;++n)i+=s[n](e,t);return i},n.isVolatile=r,n.policy=null!=o?o:t;const l=new mh(n);return gh.assignAspect(l,i),l}},Ih=/([ \x09\x0a\x0c\x0d])([^\0-\x1F\x7F-\x9F "'>=/]+)([ \x09\x0a\x0c\x0d]*=[ \x09\x0a\x0c\x0d]*(?:[^ \x09\x0a\x0c\x0d"'`<>=]*|"[^"]*|'[^']*))$/,Dh=Object.create(null);class _h{constructor(e,t=Dh){this.html=e,this.factories=t}createHTML(e){const t=this.factories;for(const i in t)e(t[i]);return this.html}}function Nh(e,t,i,n=gh.getForInstance(e)){if(n.aspected){const i=Ih.exec(t);null!==i&&gh.assignAspect(e,i[2])}return e.createHTML(i)}_h.empty=new _h(""),gh.define(_h);class Rh{constructor(e,t={},i){this.policy=i,this.result=null,this.html=e,this.factories=t}create(e){return null===this.result&&(this.result=kh.compile(this.html,this.factories,this.policy)),this.result.createView(e)}inline(){return new _h(Hd(this.html)?this.html:this.html.innerHTML,this.factories)}withPolicy(e){if(this.result)throw jd.error(1208);if(this.policy)throw jd.error(1207);return this.policy=e,this}render(e,t,i){const n=this.create(i);return n.bind(e),n.appendTo(t),n}static create(e,t,i){let n="";const o=Object.create(null),r=e=>{var t;const i=null!==(t=e.id)&&void 0!==t?t:e.id=dh();return o[i]=e,i};for(let i=0,o=e.length-1;i<o;++i){const o=e[i];let a,s=t[i];if(n+=o,Ud(s))s=new mh(ju(s));else if(s instanceof Vu)s=new mh(s);else if(!(a=gh.getForInstance(s))){const e=s;s=new mh(oh((()=>e)))}n+=Nh(s,o,r,a)}return new Rh(n+e[e.length-1],o,i)}}qd(Rh);const Mh=(e,...t)=>{if(Array.isArray(e)&&Array.isArray(e.raw))return Rh.create(e,t);throw jd.error(1206)};Mh.partial=e=>new _h(e);class Lh{constructor(e,t,i){this.index=e,this.removed=t,this.addedCount=i}adjustTo(e){let t=this.index;const i=e.length;return t>i?t=i-this.addedCount:t<0&&(t=i+this.removed.length+t-this.addedCount),this.index=t<0?0:t,this}}const Bh=Object.freeze({reset:1,splice:2,optimized:3}),Fh=new Lh(0,zd,0);Fh.reset=!0;const Uh=[Fh];function Hh(e,t,i,n,o,r){let a=0,s=0;const l=Math.min(i-t,r-o);if(0===t&&0===o&&(a=function(e,t,i){for(let n=0;n<i;++n)if(e[n]!==t[n])return n;return i}(e,n,l)),i===e.length&&r===n.length&&(s=function(e,t,i){let n=e.length,o=t.length,r=0;for(;r<i&&e[--n]===t[--o];)r++;return r}(e,n,l-a)),o+=a,r-=s,(i-=s)-(t+=a)==0&&r-o==0)return zd;if(t===i){const e=new Lh(t,[],0);for(;o<r;)e.removed.push(n[o++]);return[e]}if(o===r)return[new Lh(t,[],i-t)];const c=function(e){let t=e.length-1,i=e[0].length-1,n=e[t][i];const o=[];for(;t>0||i>0;){if(0===t){o.push(2),i--;continue}if(0===i){o.push(3),t--;continue}const r=e[t-1][i-1],a=e[t-1][i],s=e[t][i-1];let l;l=a<s?a<r?a:r:s<r?s:r,l===r?(r===n?o.push(0):(o.push(1),n=r),t--,i--):l===a?(o.push(3),t--,n=a):(o.push(2),i--,n=s)}return o.reverse()}(function(e,t,i,n,o,r){const a=r-o+1,s=i-t+1,l=new Array(a);let c,d;for(let e=0;e<a;++e)l[e]=new Array(s),l[e][0]=e;for(let e=0;e<s;++e)l[0][e]=e;for(let i=1;i<a;++i)for(let r=1;r<s;++r)e[t+r-1]===n[o+i-1]?l[i][r]=l[i-1][r-1]:(c=l[i-1][r]+1,d=l[i][r-1]+1,l[i][r]=c<d?c:d);return l}(e,t,i,n,o,r)),d=[];let u,h=t,p=o;for(let e=0;e<c.length;++e)switch(c[e]){case 0:void 0!==u&&(d.push(u),u=void 0),h++,p++;break;case 1:void 0===u&&(u=new Lh(h,[],0)),u.addedCount++,h++,u.removed.push(n[p]),p++;break;case 2:void 0===u&&(u=new Lh(h,[],0)),u.addedCount++,h++;break;case 3:void 0===u&&(u=new Lh(h,[],0)),u.removed.push(n[p]),p++}return void 0!==u&&d.push(u),d}function $h(e,t){let i=!1,n=0;for(let l=0;l<t.length;l++){const c=t[l];if(c.index+=n,i)continue;const d=(o=e.index,r=e.index+e.removed.length,a=c.index,s=c.index+c.addedCount,r<a||s<o?-1:r===a||s===o?0:o<a?r<s?r-a:s-a:s<r?s-o:r-o);if(d>=0){t.splice(l,1),l--,n-=c.addedCount-c.removed.length,e.addedCount+=c.addedCount-d;const o=e.removed.length+c.removed.length-d;if(e.addedCount||o){let t=c.removed;if(e.index<c.index){const i=e.removed.slice(0,c.index-e.index);i.push(...t),t=i}if(e.index+e.removed.length>c.index+c.addedCount){const i=e.removed.slice(c.index+c.addedCount-e.index);t.push(...i)}e.removed=t,c.index<e.index&&(e.index=c.index)}else i=!0}else if(e.index<c.index){i=!0,t.splice(l,0,e),l++;const o=e.addedCount-e.removed.length;c.index+=o,n+=o}}var o,r,a,s;i||t.push(e)}let Zh=Object.freeze({support:Bh.optimized,normalize(e,t,i){return void 0===e?void 0===i?zd:function(e,t){let i=[];const n=[];for(let e=0,i=t.length;e<i;e++)$h(t[e],n);for(let t=0,o=n.length;t<o;++t){const o=n[t];1!==o.addedCount||1!==o.removed.length?i=i.concat(Hh(e,o.index,o.index+o.addedCount,o.removed,0,o.removed.length)):o.removed[0]!==e[o.index]&&i.push(o)}return i}(t,i):Uh},pop(e,t,i,n){const o=e.length>0,r=i.apply(e,n);return o&&t.addSplice(new Lh(e.length,[r],0)),r},push(e,t,i,n){const o=i.apply(e,n);return t.addSplice(new Lh(e.length-n.length,[],n.length).adjustTo(e)),o},reverse(e,t,i,n){const o=i.apply(e,n);return t.reset(e),o},shift(e,t,i,n){const o=e.length>0,r=i.apply(e,n);return o&&t.addSplice(new Lh(0,[r],0)),r},sort(e,t,i,n){const o=i.apply(e,n);return t.reset(e),o},splice(e,t,i,n){const o=i.apply(e,n);return t.addSplice(new Lh(+n[0],o,n.length>2?n.length-2:0).adjustTo(e)),o},unshift(e,t,i,n){const o=i.apply(e,n);return t.addSplice(new Lh(0,[],n.length).adjustTo(e)),o}});function Vh(e,t,i){Reflect.defineProperty(e,t,{value:i,enumerable:!1})}Object.freeze({reset:Uh,setDefaultStrategy(e){Zh=e}});class Gh extends Zd{constructor(e){super(e),this.oldCollection=void 0,this.splices=void 0,this.needsQueue=!0,this._strategy=null,this._lengthObserver=void 0,this.call=this.flush,Vh(e,"$fastController",this)}get strategy(){return this._strategy}set strategy(e){this._strategy=e}get lengthObserver(){let e=this._lengthObserver;if(void 0===e){const t=this.subject;this._lengthObserver=e={length:t.length,handleChange(){this.length!==t.length&&(this.length=t.length,Jd.notify(e,"length"))}},this.subscribe(e)}return e}subscribe(e){this.flush(),super.subscribe(e)}addSplice(e){void 0===this.splices?this.splices=[e]:this.splices.push(e),this.enqueue()}reset(e){this.oldCollection=e,this.enqueue()}flush(){var e;const t=this.splices,i=this.oldCollection;void 0===t&&void 0===i||(this.needsQueue=!0,this.splices=void 0,this.oldCollection=void 0,this.notify((null!==(e=this._strategy)&&void 0!==e?e:Zh).normalize(i,this.subject,t)))}enqueue(){this.needsQueue&&(this.needsQueue=!1,Yd.enqueue(this))}}let jh=!1;const zh=Object.freeze({enable(){if(jh)return;jh=!0,Jd.setArrayObserverFactory((e=>new Gh(e)));const e=Array.prototype;e.$fastPatch||(Vh(e,"$fastPatch",1),[e.pop,e.push,e.reverse,e.shift,e.sort,e.splice,e.unshift].forEach((t=>{e[t.name]=function(...e){var i;const n=this.$fastController;return void 0===n?t.apply(this,e):(null!==(i=n.strategy)&&void 0!==i?i:Zh)[t.name](this,n,t,e)}})))}});function Wh(e){return Ud(e)?ju(e):e instanceof Vu?e:oh((()=>e))}const Kh=Object.freeze({positioning:!1,recycle:!0});function qh(e,t,i,n){e.context.parent=n.source,e.context.parentContext=n.context,e.bind(t[i])}function Yh(e,t,i,n){e.context.parent=n.source,e.context.parentContext=n.context,e.context.length=t.length,e.context.index=i,e.bind(t[i])}class Xh{constructor(e){this.directive=e,this.items=null,this.itemsObserver=null,this.bindView=qh,this.views=[],this.itemsBindingObserver=e.dataBinding.createObserver(this,e),this.templateBindingObserver=e.templateBinding.createObserver(this,e),e.options.positioning&&(this.bindView=Yh)}bind(e){this.location=e.targets[this.directive.targetNodeId],this.controller=e,this.items=this.itemsBindingObserver.bind(e),this.template=this.templateBindingObserver.bind(e),this.observeItems(!0),this.refreshAllViews(),e.onUnbind(this)}unbind(){null!==this.itemsObserver&&this.itemsObserver.unsubscribe(this),this.unbindAllViews()}handleChange(e,t){if(t===this.itemsBindingObserver)this.items=this.itemsBindingObserver.bind(this.controller),this.observeItems(),this.refreshAllViews();else if(t===this.templateBindingObserver)this.template=this.templateBindingObserver.bind(this.controller),this.refreshAllViews(!0);else{if(!t[0])return;t[0].reset?this.refreshAllViews():this.updateViews(t)}}observeItems(e=!1){if(!this.items)return void(this.items=zd);const t=this.itemsObserver,i=this.itemsObserver=Jd.getNotifier(this.items),n=t!==i;n&&null!==t&&t.unsubscribe(this),(n||e)&&i.subscribe(this)}updateViews(e){const t=this.views,i=this.bindView,n=this.items,o=this.template,r=this.controller,a=this.directive.options.recycle,s=[];let l=0,c=0;for(let d=0,u=e.length;d<u;++d){const u=e[d],h=u.removed;let p=0,g=u.index;const f=g+u.addedCount,m=t.splice(u.index,h.length),v=c=s.length+m.length;for(;g<f;++g){const e=t[g],d=e?e.firstChild:this.location;let u;a&&c>0?(p<=v&&m.length>0?(u=m[p],p++):(u=s[l],l++),c--):u=o.create(),t.splice(g,0,u),i(u,n,g,r),u.insertBefore(d)}m[p]&&s.push(...m.slice(p))}for(let e=l,t=s.length;e<t;++e)s[e].dispose();if(this.directive.options.positioning)for(let e=0,i=t.length;e<i;++e){const n=t[e].context;n.length=i,n.index=e}}refreshAllViews(e=!1){const t=this.items,i=this.template,n=this.location,o=this.bindView,r=this.controller;let a=t.length,s=this.views,l=s.length;if(0!==a&&!e&&this.directive.options.recycle||(yh.disposeContiguousBatch(s),l=0),0===l){this.views=s=new Array(a);for(let e=0;e<a;++e){const a=i.create();o(a,t,e,r),s[e]=a,a.insertBefore(n)}}else{let e=0;for(;e<a;++e)if(e<l)o(s[e],t,e,r);else{const a=i.create();o(a,t,e,r),s.push(a),a.insertBefore(n)}const c=s.splice(e,l-e);for(e=0,a=c.length;e<a;++e)c[e].dispose()}}unbindAllViews(){const e=this.views;for(let t=0,i=e.length;t<i;++t)e[t].unbind()}}class Jh{constructor(e,t,i){this.dataBinding=e,this.templateBinding=t,this.options=i,zh.enable()}createHTML(e){return uh.comment(e(this))}createBehavior(){return new Xh(this)}}function Qh(e,t,i=Kh){const n=Wh(e),o=Wh(t);return new Jh(n,o,Object.assign(Object.assign({},Kh),i))}gh.define(Jh);const ep=()=>null;function tp(e){return void 0===e?ep:Ud(e)?e:()=>e}function ip(e,t,i){const n=Ud(e)?e:()=>e,o=tp(t),r=tp(i);return(e,t)=>n(e,t)?o(e,t):r(e,t)}const np=(e,t)=>Mh`<commerceui-swatch
shape=${t.shape}
size=${t.size}
selected=${e.selected}
@click=${()=>t.handleSwatchClick(e)}
:data=${e}
></commerceui-swatch>`,op=Mh`
<button class="expand-button" role="button" @click=${e=>e.handleExpandButtonClick()}>
${e=>e.isExpanded?"Less":"+"+(e.items.length-e.rowMaxItems+1)}
</button>
`,rp=Mh`
<template aria-expanded=${e=>e.isExpanded}>
<div id="swatches-container" class="container">
${Qh((e=>e.getVisibleSwatches()),Mh`${(e,t)=>np(e,t.parent)}`)}
${Qh((e=>e.getOverflowSwatches()),Mh`${(e,t)=>np(e,t.parent)}`)}
${ip((e=>e.items&&e._rowMaxItems&&e.items.length>e.rowMaxItems),op)}
</div>
</template>
`;Mh`<commerceui-swatches
shape=${e=>e.shape}
size=${e=>e.size}
row-max-items=${e=>e.rowMaxItems}
selected-index=${e=>e.selectedIndex}
:items=${e=>e.items}
:onselectionchange=${e=>e.onselectionchange}
></commerceui-swatches>`,Zu.compose({name:`${Md.prefix}-swatches`,template:rp,styles:ih}).define(Md.registry);class ap extends Bu{constructor(){super(...arguments),this.shape=Uu,this.size=$u}}(0,o.gn)([yu],ap.prototype,"shape",void 0),(0,o.gn)([yu],ap.prototype,"size",void 0),(0,o.gn)([yu],ap.prototype,"data",void 0);const sp=eh`
:host {
display: block;
}
:host([size=${Hu}]) {
width: 24px;
height: 24px;
}
:host([size=${$u}]) {
width: 32px;
height: 32px;
}
:host([size=${"large"}]) {
width: 40px;
height: 40px;
}
.swatch {
display: flex;
align-items: center;
justify-content: center;
width: 100%;
height: 100%;
margin: 0;
padding: 0;
background-color: ${Ee};
border: none;
box-sizing: border-box;
cursor: pointer;
}
.swatch[disabled] {
opacity: 0.4;
cursor: default;
pointer-events: none;
position: relative;
overflow: hidden;
}
.color {
width: 100%;
height: 100%;
border-radius: ${Fe};
}
.swatch[disabled] .color {
opacity: 0.4;
}
.swatch[disabled]::before {
content: "";
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: linear-gradient(
to bottom right,
transparent 49%,
${Ne} 49%,
${Ne} 51%,
transparent 21%
);
z-index: 1;
}
.swatch,
.content,
:host([shape=${Uu}]) .swatch,
:host([shape=${Uu}]) .swatch .content {
border-radius: ${Fe};
}
:host([shape=${Fu}]) .swatch,
:host([shape=${Fu}]) .content {
border-radius: 50%;
padding: unset;
}
.content {
width: 100%;
height: 100%;
border: 1px solid ${Ne};
box-sizing: border-box;
overflow: hidden;
transition-property: width, height;
transition: 0.3s ${"var(--curveDecelerateMid)"};
padding: ${je};
}
.content img {
width: 100%;
height: 100%;
border-radius: ${Fe};
background-color: ${Ee};
object-fit: contain;
}
.swatch:hover {
border: 1px solid ${"var(--colorNeutralStroke1Hover)"};
}
:host([selected]) .swatch {
outline: 2px solid ${ke};
outline-offset: -2px;
}
:host([selected]) .swatch:focus-visible {
outline: 2px solid ${Oe};
outline-offset: 2px;
}
.swatch:hover .content,
:host([selected]) .swatch .content {
width: calc(100% - 2px);
height: calc(100% - 2px);
border: none;
}
`,lp=Mh`<button
class="swatch"
role="button"
type="button"
?disabled=${e=>e.data.disabled}
>
<div class="content">
${ip((e=>e.data.imgSrc),Mh`<img
src=${e=>e.data.imgSrc}
alt=${e=>e.data.imgAlt}
title=${e=>e.data.label}
/>`)}
${ip((e=>!e.data.imgSrc),Mh`<div
class="color"
style="background-color: ${e=>e.data.fill};"
></div>`)}
</div>
</button>`,cp=Mh`
<template shape=${e=>e.shape} size=${e=>e.size} ?selected=${e=>e.data.selected}>
${lp}
</template>
`;Mh`<commerceui-swatch
shape=${e=>e.shape}
size=${e=>e.size}
:data=${e=>e.data}
:onclick=${e=>e.onclick}
></commerceui-swatch>`,ap.compose({name:`${Md.prefix}-swatch`,template:cp,styles:sp}).define(Md.registry);const dp=Object.freeze({prefix:"fluent",shadowRootMode:"open",registry:customElements});var up=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};class hp extends zl{constructor(){super(...arguments),this.disabled=!1,this.required=!1}}function pp(e){return`:host([hidden]){display:none}:host{display:${e}}`}up([Al],hp.prototype,"size",void 0),up([Al],hp.prototype,"weight",void 0),up([Al({mode:"boolean"})],hp.prototype,"disabled",void 0),up([Al({mode:"boolean"})],hp.prototype,"required",void 0);const gp="var(--colorNeutralForeground1)",fp="var(--colorNeutralForeground2)",mp="var(--colorNeutralForeground2Hover)",vp="var(--colorNeutralForeground2Pressed)",yp="var(--colorNeutralForeground2BrandHover)",Cp="var(--colorNeutralForeground2BrandPressed)",bp="var(--colorNeutralForegroundDisabled)",Sp="var(--colorNeutralForegroundOnBrand)",xp="var(--colorNeutralBackground1)",Tp="var(--colorNeutralBackground1Hover)",wp="var(--colorTransparentBackground)",Op="var(--colorTransparentBackgroundHover)",Pp="var(--colorTransparentBackgroundPressed)",Ap="var(--colorNeutralBackgroundDisabled)",Ep="var(--colorTransparentStroke)",kp="var(--colorStrokeFocus2)",Ip="var(--borderRadiusMedium)",Dp="var(--fontFamilyBase)",_p="var(--fontSizeBase200)",Np="var(--fontSizeBase300)",Rp="var(--fontSizeBase400)",Mp="var(--fontWeightRegular)",Lp="var(--fontWeightSemibold)",Bp="var(--lineHeightBase200)",Fp="var(--lineHeightBase300)",Up="var(--lineHeightBase400)",Hp="var(--spacingHorizontalXS)",$p=sc`
${pp("flex")}
:host {
font-family: ${Dp};
font-size: ${Np};
line-height: ${Fp};
font-weight: ${Mp};
color: ${gp};
}
.asterisk {
color: ${"var(--colorPaletteRedForeground1)"};
margin-left: ${Hp};
}
:host([size='small']) {
font-size: ${_p};
line-height: ${Bp};
}
:host([size='large']) {
font-size: ${Rp};
line-height: ${Up};
font-weight: ${Lp};
}
:host([weight='semibold']) {
font-weight: ${Lp};
}
:host([disabled]),
:host([disabled]) .asterisk {
color: ${bp};
}
`,Zp=hd`
<slot></slot>
<span part="asterisk" class="asterisk" ?hidden="${e=>!e.required}">*</span>
`,Vp=hp.compose({name:`${dp.prefix}-label`,template:Zp,styles:$p});var Gp=i(22256),jp=i(63853),zp=i(56493),Wp=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};class Kp extends zl{constructor(){super(...arguments),this.openOnHover=!1,this.openOnContext=!1,this.closeOnScroll=!1,this.persistOnItemClick=!1,this.open=!1,this.slottedMenuList=[],this.slottedTriggers=[],this.toggleMenu=()=>{this.open?this.closeMenu():this.openMenu()},this.closeMenu=()=>{this.open=!1,this.closeOnScroll&&document.removeEventListener("scroll",this.closeMenu)},this.openMenu=e=>{this.open=!0,e&&this.openOnContext&&e.preventDefault(),this.closeOnScroll&&document.addEventListener("scroll",this.closeMenu)},this.setPositioningTask=()=>{this.setPositioning()},this.handleTriggerKeydown=e=>{if(!e.defaultPrevented)switch(e.key){case zp.BI:case zp.kL:e.preventDefault(),this.toggleMenu(),this.open&&this.focusMenuList();break;default:return!0}},this.handleDocumentClick=e=>{!e||e.composedPath().includes(this._menuList)||e.composedPath().includes(this._trigger)||this.closeMenu()}}connectedCallback(){super.connectedCallback(),rl.enqueue((()=>this.setComponent()))}disconnectedCallback(){var e;super.disconnectedCallback(),null===(e=this.cleanup)||void 0===e||e.call(this),this.removeListeners()}setComponent(){this.$fastController.isConnected&&this.slottedMenuList.length&&this.slottedTriggers.length&&(this._trigger=this.slottedTriggers[0],this._menuList=this.slottedMenuList[0],this._trigger.setAttribute("aria-haspopup","true"),this._trigger.setAttribute("aria-expanded",`${this.open}`),this.addListeners())}focusMenuList(){this.open&&this._menuList&&rl.enqueue((()=>{this._menuList.focus()}))}focusTrigger(){!this.open&&this._trigger&&rl.enqueue((()=>{this._trigger.focus()}))}openChanged(e,t){var i;this.$fastController.isConnected&&this._trigger instanceof HTMLElement&&(this._trigger.setAttribute("aria-expanded",`${this.open}`),this._menuList&&this.open&&rl.enqueue(this.setPositioningTask)),null===(i=this.cleanup)||void 0===i||i.call(this),this.$emit("onOpenChange",{open:t})}openOnHoverChanged(e,t){var i,n;t?null===(i=this._trigger)||void 0===i||i.addEventListener("mouseover",this.openMenu):null===(n=this._trigger)||void 0===n||n.removeEventListener("mouseover",this.openMenu)}persistOnItemClickChanged(e,t){var i,n;t?null===(n=this._menuList)||void 0===n||n.removeEventListener("click",this.closeMenu):null===(i=this._menuList)||void 0===i||i.addEventListener("click",this.closeMenu)}openOnContextChanged(e,t){var i,n;t?null===(i=this._trigger)||void 0===i||i.addEventListener("contextmenu",this.openMenu):null===(n=this._trigger)||void 0===n||n.removeEventListener("contextmenu",this.openMenu)}closeOnScrollChanged(e,t){t?document.addEventListener("scroll",this.closeMenu):document.removeEventListener("scroll",this.closeMenu)}setPositioning(){this.$fastController.isConnected&&this._menuList&&this.open&&this._trigger&&(this.cleanup=(0,Gp.Me)(this,this.positioningContainer,(async()=>{var e,t;const{middlewareData:i,x:n,y:o}=await(0,Gp.oo)(this._trigger,this.positioningContainer,{placement:"bottom",strategy:"fixed",middleware:[(0,jp.RR)(),(0,jp.dp)({apply:({availableHeight:e,rects:t})=>{var i;(null===(i=this.positioningContainer)||void 0===i?void 0:i.style)&&Object.assign(this.positioningContainer.style,{maxHeight:`${e}px`,width:`${t.reference.width}px`})}}),(0,jp.Cp)()]});(null===(e=i.hide)||void 0===e?void 0:e.referenceHidden)?this.open=!1:(null===(t=this.positioningContainer)||void 0===t?void 0:t.style)&&Object.assign(this.positioningContainer.style,{position:"fixed",top:"0",left:"0",transform:`translate(${n}px, ${o}px)`})})))}addListeners(){var e,t,i,n,o;document.addEventListener("click",this.handleDocumentClick),null===(e=this._trigger)||void 0===e||e.addEventListener("keydown",this.handleTriggerKeydown),this.persistOnItemClick||null===(t=this._menuList)||void 0===t||t.addEventListener("click",this.closeMenu),this.openOnHover?null===(i=this._trigger)||void 0===i||i.addEventListener("mouseover",this.openMenu):this.openOnContext?null===(n=this._trigger)||void 0===n||n.addEventListener("contextmenu",this.openMenu):null===(o=this._trigger)||void 0===o||o.addEventListener("click",this.toggleMenu)}removeListeners(){var e,t,i,n,o;document.removeEventListener("click",this.handleDocumentClick),null===(e=this._trigger)||void 0===e||e.removeEventListener("keydown",this.handleTriggerKeydown),this.persistOnItemClick||null===(t=this._menuList)||void 0===t||t.removeEventListener("click",this.closeMenu),this.openOnHover&&(null===(i=this._trigger)||void 0===i||i.removeEventListener("mouseover",this.openMenu)),this.openOnContext?null===(n=this._trigger)||void 0===n||n.removeEventListener("contextmenu",this.openMenu):null===(o=this._trigger)||void 0===o||o.removeEventListener("click",this.toggleMenu)}handleMenuKeydown(e){if(!e.defaultPrevented)switch(e.key){case zp.CX:e.preventDefault(),this.open&&(this.closeMenu(),this.focusTrigger());break;case zp.oM:this.open&&this.closeMenu(),e.shiftKey&&this.focusTrigger();default:return!0}}}Wp([ll,Al({attribute:"open-on-hover",mode:"boolean"})],Kp.prototype,"openOnHover",void 0),Wp([ll,Al({attribute:"open-on-context",mode:"boolean"})],Kp.prototype,"openOnContext",void 0),Wp([ll,Al({attribute:"close-on-scroll",mode:"boolean"})],Kp.prototype,"closeOnScroll",void 0),Wp([ll,Al({attribute:"persist-on-item-click",mode:"boolean"})],Kp.prototype,"persistOnItemClick",void 0),Wp([ll,Al({mode:"boolean"})],Kp.prototype,"open",void 0),Wp([ll],Kp.prototype,"slottedMenuList",void 0),Wp([ll],Kp.prototype,"slottedTriggers",void 0);const qp=sc`
:host {
position: relative;
z-index: var(--z-index-menu, 1);
}
.positioning-container {
position: fixed;
top: 0;
left: 0;
transform: translate(0, 0);
}
`,Yp=e=>1===e.nodeType,Xp=e=>e?t=>1===t.nodeType&&t.matches(e):Yp;class Jp extends jc{get id(){return this._id}set id(e){this._id=e,this._controllerProperty=`${e}-c`}bind(e){const t=e.targets[this.targetNodeId];t[this._controllerProperty]=e,this.updateTarget(e.source,this.computeNodes(t)),this.observe(t),e.onUnbind(this)}unbind(e){const t=e.targets[this.targetNodeId];this.updateTarget(e.source,tl),this.disconnect(t),t[this._controllerProperty]=null}getSource(e){return e[this._controllerProperty].source}updateTarget(e,t){e[this.options.property]=t}computeNodes(e){let t=this.getNodes(e);return"filter"in this.options&&(t=t.filter(this.options.filter)),t}}const Qp="slotchange";class eg extends Jp{observe(e){e.addEventListener(Qp,this)}disconnect(e){e.removeEventListener(Qp,this)}getNodes(e){return e.assignedNodes(this.options)}handleEvent(e){const t=e.currentTarget;this.updateTarget(this.getSource(t),this.computeNodes(t))}}function tg(e){return qs(e)&&(e={property:e}),new eg(e)}Gc.define(eg);const ig=hd`
<template
?open-on-hover="${e=>e.openOnHover}"
?open-on-context="${e=>e.openOnContext}"
?close-on-scroll="${e=>e.closeOnScroll}"
?persist-on-item-click="${e=>e.persistOnItemClick}"
@keydown="${(e,t)=>e.handleMenuKeydown(t.event)}"
>
<slot name="trigger" ${tg({property:"slottedTriggers",filter:Xp()})}></slot>
<span
${gd("positioningContainer")}
part="positioning-container"
class="positioning-container"
?hidden="${e=>!e.open}"
>
<slot ${tg({property:"slottedMenuList",filter:Xp()})}></slot>
</span>
</template>
`,ng=Kp.compose({name:`${dp.prefix}-menu`,template:ig,styles:qp});class og{constructor(e){this.listenerCache=new WeakMap,this.query=e}connectedCallback(e){const{query:t}=this;let i=this.listenerCache.get(e);i||(i=this.constructListener(e),this.listenerCache.set(e,i)),i.bind(t)(),t.addEventListener("change",i)}disconnectedCallback(e){const t=this.listenerCache.get(e);t&&this.query.removeEventListener("change",t)}}class rg extends og{constructor(e,t){super(e),this.styles=t}static with(e){return t=>new rg(e,t)}constructListener(e){let t=!1;const i=this.styles;return function(){const{matches:n}=this;n&&!t?(e.addStyles(i),t=n):!n&&t&&(e.removeStyles(i),t=n)}}removedCallback(e){e.removeStyles(this.styles)}}const ag=rg.with(window.matchMedia("(forced-colors)")),sg=(rg.with(window.matchMedia("(prefers-color-scheme: dark)")),rg.with(window.matchMedia("(prefers-color-scheme: light)")),sc`
${pp("inline-flex")}
:host {
--icon-spacing: ${"var(--spacingHorizontalSNudge)"};
contain: layout style;
vertical-align: middle;
align-items: center;
box-sizing: border-box;
justify-content: center;
text-align: center;
text-decoration-line: none;
margin: 0;
min-height: 32px;
outline-style: none;
background-color: ${xp};
color: ${gp};
border: ${"var(--strokeWidthThin)"} solid ${"var(--colorNeutralStroke1)"};
padding: 0 ${"var(--spacingHorizontalM)"};
min-width: 96px;
border-radius: ${Ip};
font-size: ${Np};
font-family: ${Dp};
font-weight: ${Lp};
line-height: ${Fp};
transition-duration: ${"var(--durationFaster)"};
transition-property: background, border, color;
transition-timing-function: ${"var(--curveEasyEase)"};
cursor: pointer;
user-select: none;
}
.content {
display: inherit;
}
:host(:hover) {
background-color: ${Tp};
color: ${"var(--colorNeutralForeground1Hover)"};
border-color: ${"var(--colorNeutralStroke1Hover)"};
}
:host(:hover:active) {
background-color: ${"var(--colorNeutralBackground1Pressed)"};
border-color: ${"var(--colorNeutralStroke1Pressed)"};
color: ${"var(--colorNeutralForeground1Pressed)"};
outline-style: none;
}
:host(:focus-visible) {
border-color: ${Ep};
outline: ${"var(--strokeWidthThick)"}) solid ${Ep};
box-shadow: ${"var(--shadow4)"}, 0 0 0 2px ${kp};
}
@media screen and (prefers-reduced-motion: reduce) {
transition-duration: 0.01ms;
}
::slotted(svg) {
font-size: 20px;
height: 20px;
width: 20px;
fill: currentColor;
}
[slot='start'],
::slotted([slot='start']) {
margin-inline-end: var(--icon-spacing);
}
[slot='end'],
::slotted([slot='end']) {
margin-inline-start: var(--icon-spacing);
}
:host([icon-only]) {
min-width: 32px;
max-width: 32px;
}
:host([size='small']) {
--icon-spacing: ${Hp};
min-height: 24px;
min-width: 64px;
padding: 0 ${"var(--spacingHorizontalS)"};
border-radius: ${"var(--borderRadiusSmall)"};
font-size: ${_p};
line-height: ${Bp};
font-weight: ${Mp};
}
:host([size='small'][icon-only]) {
min-width: 24px;
max-width: 24px;
}
:host([size='large']) {
min-height: 40px;
border-radius: ${"var(--borderRadiusLarge)"};
padding: 0 ${"var(--spacingHorizontalL)"};
font-size: ${Rp};
line-height: ${Up};
}
:host([size='large'][icon-only]) {
min-width: 40px;
max-width: 40px;
}
:host([size='large']) ::slotted(svg) {
font-size: 24px;
height: 24px;
width: 24px;
}
:host([shape='circular']),
:host([shape='circular']:focus-visible) {
border-radius: ${"var(--borderRadiusCircular)"};
}
:host([shape='square']),
:host([shape='square']:focus-visible) {
border-radius: ${"var(--borderRadiusNone)"};
}
:host([appearance='primary']) {
background-color: ${"var(--colorBrandBackground)"};
color: ${Sp};
border-color: transparent;
}
:host([appearance='primary']:hover) {
background-color: ${"var(--colorBrandBackgroundHover)"};
}
:host([appearance='primary']:hover),
:host([appearance='primary']:hover:active) {
border-color: transparent;
color: ${Sp};
}
:host([appearance='primary']:hover:active) {
background-color: ${"var(--colorBrandBackgroundPressed)"};
}
:host([appearance='primary']:focus-visible) {
border-color: ${Sp};
box-shadow: ${"var(--shadow2)"}, 0 0 0 2px ${kp};
}
:host(is:([disabled][appearance='primary'], [disabled-focusabale][appearance="primary"])),
:host(is:([disabled][appearance='primary'], [disabled-focusabale][appearance="primary"]):hover),
:host(is:([disabled][appearance='primary'], [disabled-focusabale][appearance="primary"]):hover:active) {
border-color: transparent;
}
:host([appearance='outline']) {
background-color: ${wp};
}
:host([appearance='outline']:hover) {
background-color: ${Op};
}
:host([appearance='outline']:hover:active) {
background-color: ${Pp};
}
:host(is:([disabled][appearance='outline'], [disabled-focusabale][appearance="outline"])),
:host(is:([disabled][appearance='outline'], [disabled-focusabale][appearance="outline"]):hover),
:host(is:([disabled][appearance='outline'], [disabled-focusabale][appearance="outline"]):hover:active) {
background-color: ${wp};
}
:host([appearance='subtle']) {
background-color: ${"var(--colorSubtleBackground)"};
color: ${fp};
border-color: transparent;
}
:host([appearance='subtle']:hover) {
background-color: ${"var(--colorSubtleBackgroundHover)"};
color: ${mp};
border-color: transparent;
}
:host([appearance='subtle']:hover:active) {
background-color: ${"var(--colorSubtleBackgroundPressed)"};
color: ${vp};
border-color: transparent;
}
:host(is:([disabled][appearance='subtle'], [disabled-focusabale][appearance="subtle"])),
:host(is:([disabled][appearance='subtle'], [disabled-focusabale][appearance="subtle"]):hover),
:host(is:([disabled][appearance='subtle'], [disabled-focusabale][appearance="subtle"]):hover:active) {
background-color: ${wp};
border-color: transparent;
}
:host([appearance='subtle']:hover) ::slotted(svg) {
fill: ${yp};
}
:host([appearance='subtle']:hover:active) ::slotted(svg) {
fill: ${Cp};
}
:host([appearance='transparent']) {
background-color: ${wp};
color: ${fp};
}
:host([appearance='transparent']:hover) {
background-color: ${Op};
color: ${yp};
}
:host([appearance='transparent']:hover:active) {
background-color: ${Pp};
color: ${Cp};
}
:host([appearance='transparent']),
:host([appearance='transparent']:hover),
:host([appearance='transparent']:hover:active) {
border-color: transparent;
}
:host(is:([disabled][appearance='transparent'], [disabled-focusabale][appearance="transparent"])),
:host(is:([disabled][appearance='transparent'], [disabled-focusabale][appearance="transparent"]):hover),
:host(is:([disabled][appearance='transparent'], [disabled-focusabale][appearance="transparent"]):hover:active) {
border-color: transparent;
background-color: ${wp};
}
:host(:is([disabled], [disabled-focusable], [appearance][disabled], [appearance][disabled-focusable])),
:host(:is([disabled], [disabled-focusable], [appearance][disabled], [appearance][disabled-focusable]):hover),
:host(:is([disabled], [disabled-focusable], [appearance][disabled], [appearance][disabled-focusable]):hover:active) {
background-color: ${Ap};
border-color: ${"var(--colorNeutralStrokeDisabled)"};
color: ${bp};
cursor: not-allowed;
}
`.withBehaviors(ag(sc`
:host([appearance='transparent']:hover) {
border-color: Highlight;
}
`)));function lg(e){return e?"string"==typeof e?new cd(e):"inline"in e?e.inline():e:cd.empty}class cg{}function dg(e){return hd` <slot name="end" ${gd("end")}>${lg(e.end)}</slot> `.inline()}function ug(e){return hd` <slot name="start" ${gd("start")}>${lg(e.start)}</slot> `.inline()}function hg(e,...t){const i=xl.locate(e);t.forEach((t=>{Object.getOwnPropertyNames(t.prototype).forEach((i=>{"constructor"!==i&&Object.defineProperty(e.prototype,i,Object.getOwnPropertyDescriptor(t.prototype,i))})),xl.locate(t).forEach((e=>i.push(e)))}))}const pg="submit";var gg=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};class fg extends zl{constructor(){super(),this.disabledFocusable=!1,this.elementInternals=this.attachInternals(),this.iconOnly=!1,this.elementInternals.role="button"}disabledFocusableChanged(e,t){this.$fastController.isConnected&&(this.elementInternals.ariaDisabled=`${!!t}`)}get form(){return this.elementInternals.form}get labels(){return Object.freeze(Array.from(this.elementInternals.labels))}typeChanged(e,t){var i,n,o;t!==pg&&(null===(i=this.formSubmissionFallbackControl)||void 0===i||i.remove(),null===(o=null===(n=this.shadowRoot)||void 0===n?void 0:n.querySelector('slot[name="internal"]'))||void 0===o||o.remove())}clickHandler(e){if(!e||!this.disabledFocusable)return this.press(),!0;e.stopImmediatePropagation()}connectedCallback(){super.connectedCallback(),this.elementInternals.ariaDisabled=`${!!this.disabledFocusable}`}createAndInsertFormSubmissionFallbackControl(){var e,t,i,n,o,r,a,s;const l=null!==(e=this.formSubmissionFallbackControlSlot)&&void 0!==e?e:document.createElement("slot");l.setAttribute("name","internal"),null===(t=this.shadowRoot)||void 0===t||t.appendChild(l),this.formSubmissionFallbackControlSlot=l;const c=null!==(i=this.formSubmissionFallbackControl)&&void 0!==i?i:document.createElement("button");c.style.display="none",c.setAttribute("type","submit"),c.setAttribute("slot","internal"),this.formNoValidate&&c.toggleAttribute("formnovalidate",!0),(null===(n=this.elementInternals.form)||void 0===n?void 0:n.id)&&c.setAttribute("form",this.elementInternals.form.id),this.name&&c.setAttribute("name",this.name),this.value&&c.setAttribute("value",this.value),this.formAction&&c.setAttribute("formaction",null!==(o=this.formAction)&&void 0!==o?o:""),this.formEnctype&&c.setAttribute("formenctype",null!==(r=this.formEnctype)&&void 0!==r?r:""),this.formMethod&&c.setAttribute("formmethod",null!==(a=this.formMethod)&&void 0!==a?a:""),this.formTarget&&c.setAttribute("formtarget",null!==(s=this.formTarget)&&void 0!==s?s:""),this.append(c),this.formSubmissionFallbackControl=c}formDisabledCallback(e){this.disabled=e}keypressHandler(e){if(e&&this.disabledFocusable)e.stopImmediatePropagation();else{if(e.key!==zp.kL&&e.key!==zp.BI)return!0;this.press()}}press(){switch(this.type){case"reset":this.resetForm();break;case pg:this.submitForm()}}resetForm(){var e;null===(e=this.elementInternals.form)||void 0===e||e.reset()}submitForm(){var e;if(this.elementInternals.form&&!this.disabled&&this.type===pg)if(this.name||this.formAction||this.formEnctype||this.form||this.formMethod||this.formNoValidate||this.formTarget)try{this.elementInternals.setFormValue(null!==(e=this.value)&&void 0!==e?e:""),this.elementInternals.form.requestSubmit(this)}catch(e){this.createAndInsertFormSubmissionFallbackControl(),this.elementInternals.setFormValue(null),this.elementInternals.form.requestSubmit(this.formSubmissionFallbackControl)}else this.elementInternals.form.requestSubmit()}}function mg(e={}){return hd`
<template
tabindex="${e=>e.disabled?-1:0}"
@click="${(e,t)=>e.clickHandler(t.event)}"
@keypress="${(e,t)=>e.keypressHandler(t.event)}"
>
${ug(e)}
<span class="content" part="content">
<slot ${tg("defaultSlottedContent")}></slot>
</span>
${dg(e)}
</template>
`}fg.formAssociated=!0,gg([Al],fg.prototype,"appearance",void 0),gg([Al({mode:"boolean"})],fg.prototype,"autofocus",void 0),gg([ll],fg.prototype,"defaultSlottedContent",void 0),gg([Al({mode:"boolean"})],fg.prototype,"disabled",void 0),gg([Al({attribute:"disabled-focusable",mode:"boolean"})],fg.prototype,"disabledFocusable",void 0),gg([Al({attribute:"formaction"})],fg.prototype,"formAction",void 0),gg([Al({attribute:"form"})],fg.prototype,"formAttribute",void 0),gg([Al({attribute:"formenctype"})],fg.prototype,"formEnctype",void 0),gg([Al({attribute:"formmethod"})],fg.prototype,"formMethod",void 0),gg([Al({attribute:"formnovalidate",mode:"boolean"})],fg.prototype,"formNoValidate",void 0),gg([Al({attribute:"formtarget"})],fg.prototype,"formTarget",void 0),gg([Al({attribute:"icon-only",mode:"boolean"})],fg.prototype,"iconOnly",void 0),gg([Al],fg.prototype,"name",void 0),gg([Al],fg.prototype,"shape",void 0),gg([Al],fg.prototype,"size",void 0),gg([Al],fg.prototype,"type",void 0),gg([Al],fg.prototype,"value",void 0),hg(fg,cg),mg();const vg=mg({end:hd.partial('\n <svg slot="end" fill="currentColor" aria-hidden="true" width="1em" height="1em" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg">\n <path d="M15.85 7.65c.2.2.2.5 0 .7l-5.46 5.49a.55.55 0 0 1-.78 0L4.15 8.35a.5.5 0 1 1 .7-.7L10 12.8l5.15-5.16c.2-.2.5-.2.7 0Z" fill="currentColor"></path>\n </svg>\n ')}),yg=class extends fg{}.compose({name:`${dp.prefix}-menu-button`,template:vg,styles:sg});function Cg(...e){return e.every((e=>e instanceof HTMLElement))}const bg={menuitem:"menuitem",menuitemcheckbox:"menuitemcheckbox",menuitemradio:"menuitemradio"};var Sg=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};class xg extends zl{constructor(){super(...arguments),this.role=bg.menuitem,this.checked=!1,this.focusSubmenuOnLoad=!1,this.handleMenuItemKeyDown=e=>{if(e.defaultPrevented)return!1;switch(e.key){case zp.kL:case zp.BI:return this.invoke(),!1;case zp.mr:return this.expanded&&this.submenu?this.submenu.focus():this.expandAndFocus(),!1;case zp.CX:case zp.BE:if(this.expanded)return this.closeSubMenu(),!1}return!0},this.handleMenuItemClick=e=>(e.defaultPrevented||this.disabled||this.invoke(),!1),this.submenuLoaded=()=>{this.focusSubmenuOnLoad&&(this.focusSubmenuOnLoad=!1,this.submenu&&(this.submenu.focus(),this.setAttribute("tabindex","-1")))},this.handleMouseOver=e=>(this.disabled||!this.hasSubmenu||this.expanded||(this.expanded=!0),!1),this.handleMouseOut=e=>(!this.expanded||this.contains(document.activeElement)||(this.expanded=!1),!1),this.closeSubMenu=()=>{this.expanded=!1,this.focus()},this.expandAndFocus=()=>{this.hasSubmenu&&(this.focusSubmenuOnLoad=!0,this.expanded=!0)},this.invoke=()=>{if(!this.disabled)switch(this.role){case bg.menuitemcheckbox:this.checked=!this.checked;break;case bg.menuitem:if(this.hasSubmenu){this.expandAndFocus();break}this.$emit("change");break;case bg.menuitemradio:this.checked||(this.checked=!0)}}}expandedChanged(e,t){this.$fastController.isConnected&&(t&&this.submenu&&this.updateSubmenu(),this.$emit("expanded-change",this,{bubbles:!1}))}checkedChanged(e,t){this.$fastController.isConnected&&this.$emit("change")}get hasSubmenu(){return!!this.submenu}slottedSubmenuChanged(e,t){t.length&&(this.submenu=t[0],this.updateSubmenu())}disconnectedCallback(){var e;null===(e=this.cleanup)||void 0===e||e.call(this),super.disconnectedCallback()}updateSubmenu(){var e;null===(e=this.cleanup)||void 0===e||e.call(this),this.submenu&&this.expanded&&rl.enqueue((()=>{this.cleanup=(0,Gp.Me)(this,this.submenuContainer,(async()=>{const e=["left-start","right-start"],{x:t,y:i}=await(0,Gp.oo)(this,this.submenuContainer,{middleware:[(0,jp.uY)(),(0,jp.dp)({apply:({availableWidth:t,rects:i})=>{t<i.floating.width&&e.push("bottom-end","top-end")}}),(0,jp.RR)({fallbackPlacements:e})],placement:"right-start",strategy:"fixed"});Object.assign(this.submenuContainer.style,{left:`${t}px`,position:"fixed",top:`${i}px`}),this.submenuLoaded()}))}))}}Sg([Al({mode:"boolean"})],xg.prototype,"disabled",void 0),Sg([Al({mode:"boolean"})],xg.prototype,"expanded",void 0),Sg([Al],xg.prototype,"role",void 0),Sg([Al({mode:"boolean"})],xg.prototype,"checked",void 0),Sg([Al({mode:"boolean"})],xg.prototype,"hidden",void 0),Sg([ll],xg.prototype,"slottedSubmenu",void 0),Sg([ll],xg.prototype,"submenu",void 0),hg(xg,cg);class Tg extends zl{constructor(){super(...arguments),this.expandedItem=null,this.focusIndex=-1,this.isNestedMenu=()=>null!==this.parentElement&&Cg(this.parentElement)&&"menuitem"===this.parentElement.getAttribute("role"),this.handleFocusOut=e=>{if(!this.contains(e.relatedTarget)&&void 0!==this.menuItems){this.collapseExpandedItem();const e=this.menuItems.findIndex(this.isFocusableElement);this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.menuItems[e].setAttribute("tabindex","0"),this.focusIndex=e}},this.handleItemFocus=e=>{const t=e.target;void 0!==this.menuItems&&t!==this.menuItems[this.focusIndex]&&(this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.focusIndex=this.menuItems.indexOf(t),t.setAttribute("tabindex","0"))},this.handleExpandedChanged=e=>{if(e.defaultPrevented||null===e.target||void 0===this.menuItems||this.menuItems.indexOf(e.target)<0)return;e.preventDefault();const t=e.target;null===this.expandedItem||t!==this.expandedItem||!1!==t.expanded?t.expanded&&(null!==this.expandedItem&&this.expandedItem!==t&&(this.expandedItem.expanded=!1),this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.expandedItem=t,this.focusIndex=this.menuItems.indexOf(t),t.setAttribute("tabindex","0")):this.expandedItem=null},this.changeHandler=e=>{if(void 0===this.menuItems)return;const t=e.target,i=this.menuItems.indexOf(t);if(-1!==i&&"menuitemradio"===t.role&&!0===t.checked){for(let e=i-1;e>=0;--e){const t=this.menuItems[e],i=t.getAttribute("role");if(i===bg.menuitemradio&&(t.checked=!1),"separator"===i)break}const e=this.menuItems.length-1;for(let t=i+1;t<=e;++t){const e=this.menuItems[t],i=e.getAttribute("role");if(i===bg.menuitemradio&&(e.checked=!1),"separator"===i)break}}},this.isMenuItemElement=e=>e instanceof xg||Cg(e)&&e.getAttribute("role")in Tg.focusableElementRoles,this.isFocusableElement=e=>this.isMenuItemElement(e)}itemsChanged(e,t){this.$fastController.isConnected&&void 0!==this.menuItems&&this.setItems()}connectedCallback(){super.connectedCallback(),rl.enqueue((()=>{this.setItems()})),this.addEventListener("change",this.changeHandler)}disconnectedCallback(){super.disconnectedCallback(),this.removeItemListeners(),this.menuItems=void 0,this.removeEventListener("change",this.changeHandler)}focus(){this.setFocus(0,1)}collapseExpandedItem(){null!==this.expandedItem&&(this.expandedItem.expanded=!1,this.expandedItem=null)}handleMenuKeyDown(e){if(!e.defaultPrevented&&void 0!==this.menuItems)switch(e.key){case zp.iF:return void this.setFocus(this.focusIndex+1,1);case zp.SB:return void this.setFocus(this.focusIndex-1,-1);case zp.Kh:return void this.setFocus(this.menuItems.length-1,-1);case zp.tU:return void this.setFocus(0,1);default:return!0}}removeItemListeners(e=this.items){e.forEach((e=>{e.removeEventListener("focus",this.handleItemFocus),e.removeEventListener("expanded-changed",this.handleExpandedChanged),sl.getNotifier(e).unsubscribe(this,"hidden")}))}static elementIndent(e){const t=e.getAttribute("role"),i=e.querySelector("[slot=start]");return t&&t!==bg.menuitem?i?2:1:i?1:0}setItems(){var e;const t=Array.from(this.children);this.removeItemListeners(t),t.forEach((e=>sl.getNotifier(e).subscribe(this,"hidden")));const i=t.filter((e=>!e.hasAttribute("hidden")));this.menuItems=i;const n=this.menuItems.filter(this.isMenuItemElement);n.length&&(this.focusIndex=0),n.forEach(((e,t)=>{e.setAttribute("tabindex",0===t?"0":"-1"),e.addEventListener("expanded-change",this.handleExpandedChanged),e.addEventListener("focus",this.handleItemFocus)}));const o=null===(e=this.menuItems)||void 0===e?void 0:e.filter(this.isMenuItemElement);null==o||o.forEach(((e,t)=>{const i=null==o?void 0:o.reduce(((e,t)=>{const i=Tg.elementIndent(t);return Math.max(e,i)}),0);e instanceof xg&&e.setAttribute("data-indent",`${i}`)}))}handleChange(e,t){"hidden"===t&&this.setItems()}setFocus(e,t){if(void 0!==this.menuItems)for(;e>=0&&e<this.menuItems.length;){const i=this.menuItems[e];if(this.isFocusableElement(i)){this.focusIndex>-1&&this.menuItems.length>=this.focusIndex-1&&this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.focusIndex=e,i.setAttribute("tabindex","0"),i.focus();break}e+=t}}}Tg.focusableElementRoles=bg,function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);r>3&&a&&Object.defineProperty(t,i,a)}([ll],Tg.prototype,"items",void 0);const wg=sc`
${pp("flex")}
:host {
flex-direction: column;
height: fit-content;
max-width: 300px;
min-width: 160px;
width: auto;
background-color: ${xp};
border: 1px solid ${Ep};
border-radius: ${Ip};
box-shadow: ${"var(--shadow16)"};
padding: 4px;
row-gap: 2px;
}
`,Og=hd`
<template
slot="${e=>e.slot?e.slot:e.isNestedMenu()?"submenu":void 0}"
role="menu"
@keydown="${(e,t)=>e.handleMenuKeyDown(t.event)}"
@focusout="${(e,t)=>e.handleFocusOut(t.event)}"
>
<slot ${tg("items")}></slot>
</template>
`,Pg=Tg.compose({name:`${dp.prefix}-menu-list`,template:Og,styles:wg}),Ag=sc`
${pp("grid")}
:host {
grid-template-columns: 20px 20px auto 20px;
align-items: center;
grid-gap: 4px;
height: 32px;
background: ${xp};
font: ${Mp} ${Np} / ${Fp} ${Dp};
border-radius: ${Ip};
color: ${fp};
padding: 0 10px;
cursor: pointer;
overflow: visible;
contain: layout;
}
:host(:hover) {
background: ${Tp};
}
.content {
white-space: nowrap;
flex-grow: 1;
grid-column: auto / span 2;
padding: 0 2px;
}
.checkbox,
.radio {
display: none;
}
.input-container,
.expand-collapse-glyph-container,
::slotted([slot='start']),
::slotted([slot='end']),
:host([checked]) .checkbox,
:host([checked]) .radio {
display: inline-flex;
justify-content: center;
align-items: center;
color: ${fp};
}
.expand-collapse-glyph-container,
::slotted([slot='start']),
::slotted([slot='end']) {
height: 32px;
font-size: ${"var(--fontSizeBase500)"};
width: fit-content;
}
.input-container {
width: 20px;
}
::slotted([slot='end']) {
color: ${"var(--colorNeutralForeground3)"};
font: ${Mp} ${_p} / ${Bp} ${Dp};
white-space: nowrap;
grid-column: 4 / span 1;
justify-self: flex-end;
}
.expand-collapse-glyph-container {
grid-column: 4 / span 1;
justify-self: flex-end;
}
:host(:hover) .input-container,
:host(:hover) .expand-collapse-glyph-container,
:host(:hover) .content {
color: ${mp};
}
:host([icon]:hover) ::slotted([slot='start']) {
color: ${"var(--colorCompoundBrandForeground1Hover)"};
}
:host(:active) {
background-color: ${"var(--colorNeutralBackground1Selected)"};
}
:host(:active) .input-container,
:host(:active) .expand-collapse-glyph-container,
:host(:active) .content {
color: ${vp};
}
:host(:active) ::slotted([slot='start']) {
color: ${"var(--colorCompoundBrandForeground1Pressed)"};
}
:host([disabled]) {
background-color: ${Ap};
}
:host([disabled]) .content,
:host([disabled]) .expand-collapse-glyph-container,
:host([disabled]) ::slotted([slot='end']),
:host([disabled]) ::slotted([slot='start']) {
color: ${bp};
}
:host([data-indent]) {
display: grid;
}
:host([data-indent='1']) .content {
grid-column: 2 / span 1;
}
:host([data-indent='1'][role='menuitemcheckbox']) {
display: grid;
}
:host([data-indent='2'][aria-haspopup='menu']) ::slotted([slot='end']) {
grid-column: 4 / span 1;
}
:host([data-indent='2'][aria-haspopup='menu']) .expand-collapse-glyph-container {
grid-column: 5 / span 1;
}
:host([data-indent='1']) .content {
grid-column: 2 / span 1;
}
:host([data-indent='1'][role='menuitemcheckbox']) .content,
:host([data-indent='1'][role='menuitemradio']) .content {
grid-column: auto / span 1;
}
:host([icon]) ::slotted([slot='end']),
:host([data-indent='1']) ::slotted([slot='end']) {
grid-column: 4 / span 1;
justify-self: flex-end;
}
:host([data-indent='2']) {
display: grid;
grid-template-columns: 20px 20px auto auto;
}
:host([data-indent='2']) .content {
grid-column: 3 / span 1;
}
:host([data-indent='2']) .input-container {
grid-column: 1 / span 1;
}
:host([data-indent='2']) ::slotted([slot='start']) {
grid-column: 2 / span 1;
}
:host([aria-haspopup='menu']) {
grid-template-columns: 20px auto auto 20px;
}
:host([data-indent='2'][aria-haspopup='menu']) {
grid-template-columns: 20px 20px auto auto 20px;
}
:host([aria-haspopup='menu']) ::slotted([slot='end']) {
grid-column: 3 / span 1;
justify-self: flex-end;
}
:host([data-indent='2'][aria-haspopup='menu']) ::slotted([slot='end']) {
grid-column: 4 / span 1;
justify-self: flex-end;
}
`,Eg=hd.partial('<svg fill="currentColor" class="___12fm75w f1w7gpdv fez10in fg4l7m0" aria-hidden="true" width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M14.05 3.49c.28.3.27.77-.04 1.06l-7.93 7.47A.85.85 0 014.9 12L2.22 9.28a.75.75 0 111.06-1.06l2.24 2.27 7.47-7.04a.75.75 0 011.06.04z" fill="currentColor"></path></svg>'),kg=function(e={}){return hd`
<template
aria-haspopup="${e=>e.hasSubmenu?"menu":void 0}"
aria-checked="${e=>e.role!==bg.menuitem?e.checked:void 0}"
aria-disabled="${e=>e.disabled}"
aria-expanded="${e=>e.expanded}"
@keydown="${(e,t)=>e.handleMenuItemKeyDown(t.event)}"
@click="${(e,t)=>e.handleMenuItemClick(t.event)}"
@mouseover="${(e,t)=>e.handleMouseOver(t.event)}"
@mouseout="${(e,t)=>e.handleMouseOut(t.event)}"
>
${vd((e=>e.role===bg.menuitemcheckbox),hd`
<div part="input-container" class="input-container">
<span part="checkbox" class="checkbox">
<slot name="checkbox-indicator"> ${lg(e.checkboxIndicator)} </slot>
</span>
</div>
`)}
${vd((e=>e.role===bg.menuitemradio),hd`
<div part="input-container" class="input-container">
<span part="radio" class="radio">
<slot name="radio-indicator"> ${lg(e.radioIndicator)} </slot>
</span>
</div>
`)}
</div>
${ug(e)}
<span class="content" part="content">
<slot></slot>
</span>
${dg(e)}
${vd((e=>e.hasSubmenu),hd`
<div part="expand-collapse-glyph-container" class="expand-collapse-glyph-container">
<span part="expand-collapse" class="expand-collapse">
<slot name="expand-collapse-indicator"> ${lg(e.expandCollapseGlyph)} </slot>
</span>
</div>
`)}
<span
?hidden="${e=>!e.expanded}"
class="submenu-container"
part="submenu-container"
${gd("submenuContainer")}
>
<slot name="submenu" ${tg({property:"slottedSubmenu",filter:Xp("[role='menu']")})}></slot>
</span>
</template>
`}({checkboxIndicator:Eg,expandCollapseGlyph:hd.partial('<svg fill="currentColor" class="___12fm75w f1w7gpdv fez10in fg4l7m0" aria-hidden="true" width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M5.74 3.2a.75.75 0 00-.04 1.06L9.23 8 5.7 11.74a.75.75 0 101.1 1.02l4-4.25a.75.75 0 000-1.02l-4-4.25a.75.75 0 00-1.06-.04z" fill="currentColor"></path></svg>'),radioIndicator:Eg}),Ig=xg.compose({name:`${dp.prefix}-menu-item`,template:kg,styles:Ag});Vp.name="fluent-beta-label",Vp.define(customElements),ng.name="fluent-beta-menu",ng.define(customElements),yg.name="fluent-beta-menu-button",yg.define(customElements),Pg.name="fluent-beta-menu-list",Pg.define(customElements),Ig.name="fluent-beta-menu-item",Ig.define(customElements);const Dg=hd`
<div class="container" ${gd("containerRef")}>
${vd((e=>!e.showLabelInline),hd`<fluent-beta-label
><span class="label">${e=>e.label}</span>
${vd((e=>e.showLabelValue),hd`<span class="label-value">${e=>e.getSelectedValue}</span>`)}
</fluent-beta-label>`)}
${vd((e=>e.type===Wl),hd`
<fluent-beta-menu
open=${e=>e.open}
@onOpenChange=${(e,t)=>e.handleMenuOpenChange(t.event)}
>
<fluent-beta-menu-button
class="menu-button"
appearance="outline"
slot="trigger"
size=${e=>e.size}
${gd("menuButtonRef")}
>${vd((e=>!e.getSelectedValue&&!e.hidePlaceholderText),hd`<span class="placeholder">${e=>e.getPlaceholderText}</span>`)}
${vd((e=>e.getSelectedValue),hd`
${vd((e=>e.showLabelInline),hd`<span class="label">${e=>e.label}</span>`)}
<span class="label-value">${e=>e.getSelectedValue}</span>
`)}
</fluent-beta-menu-button>
<fluent-beta-menu-list class="menu-list">
${function(e,t,i=Id){const n=kd(e),o=kd(t);return new Rd(n,o,Object.assign(Object.assign({},Id),i))}((e=>e.items),hd`<fluent-beta-menu-item
class="menu-item"
?disabled=${e=>e.disabled}
@change=${(e,t)=>t.parent.selectHandler(e)}
><div class="menu-item-label">${e=>e.label}</div></fluent-beta-menu-item
>`)}
</fluent-beta-menu-list>
</fluent-beta-menu>
`)}
${vd((e=>e.type===Kl),hd`
<commerceui-swatches
${gd("swatchesRef")}
:items=${e=>e.items}
size=${e=>e.size}
selected-index=${e=>e.selectedIndex}
row-max-items=${e=>e.itemsToFitPerRow}
@change=${(e,t)=>{e.selectHandler(t.event.detail)}}
></commerceui-swatches>
`)}
</div>
`;hd`<commerceui-filter
:items=${e=>e.items}
type=${e=>e.type}
label=${e=>e.label}
show-label-value=${e=>e.showLabelValue}
selected-index=${e=>e.selectedIndex}
placeholder-text=${e=>e.placeholderText}
auto-hide-overflow-swatches=${e=>e.autoHideOverflowSwatches}
hide-placeholder-text=${e=>e.hidePlaceholderText}
show-label-value=${e=>e.showLabelValue}
show-label-inline=${e=>e.showLabelInline}
open=${e=>e.open}
row-max-items=${e=>e.rowMaxItems}
size=${e=>e.size}
:onselectionchange=${e=>e.onselectionchange}
></commerceui-filter>`,ql.compose({name:`${Gs.prefix}-filter`,template:Dg,styles:_c}).define(Gs.registry);const _g=Nt`<div class="slot-filter-group">
${Vs((e=>e.getData.filters),Nt`
<commerceui-filter
type=${(e,t)=>t.parent.getData.filters[t.index].type}
:items=${(e,t)=>t.parent.getData.filters[t.index].items}
label=${(e,t)=>t.parent.getData.filters[t.index].label}
show-label-value=${(e,t)=>t.parent.getData.filters[t.index].showLabelValue}
row-max-items=${(e,t)=>t.parent.getData.filters[t.index].rowMaxItems}
auto-hide-overflow-swatches=${(e,t)=>t.parent.autoHideOverflowSwatches}
selected-index=${(e,t)=>t.parent.getData.filters[t.index].selectedIndex}
size=${(e,t)=>t.parent.getData.filters[t.index].size}
hide-placeholder-text=${(e,t)=>t.parent.getData.filters[t.index].hidePlaceholderText}
placeholder-text=${(e,t)=>t.parent.getData.filters[t.index].placeholderText}
@filterchange=${(e,t)=>{t.parent.selectionChangeHandler(e.id,t.event)}}
></commerceui-filter>
`,{positioning:!0})}
</div>`;Nt`<commerceui-buying-options-filter-group
direction=${e=>e.direction}
auto-hide-overflow-swatches=${e=>e.autoHideOverflowSwatches}
title=${e=>e.title}
inline-swatches=${e=>e.inlineSwatches}
:data=${e=>e.data}
:onfiltergroupselectionchange=${e=>e.onfiltergroupselectionchange}
>${e=>e.content}</commerceui-buying-options-filter-group
>`,Ht.compose({name:`${n.prefix}-buying-options-filter-group`,template:_g,styles:Os}).define(n.registry);class Ng extends se{constructor(){super(...arguments),this.layout=le,this.appearance=ce,this.handleNavigation=!1,this.hideRetailersLogo=!1,this.noDataLabel="No data available",this.lowestPriceLabel="Lowest Price",this.discountPriceLabel="Save",this.ctaButtonLabel="Visit Site"}dataChanged(e,t){this._data=t}clickEventHandler(e,t){var i,n;this.handleNavigation&&this.getRetailerData(e).item.url&&void 0!==this.getRetailerData(e).item.url&&""!==this.getRetailerData(e).item.url&&window.open(this.getRetailerData(e).item.url,null===(i=this.getRetailerData(e).item)||void 0===i?void 0:i.target),null===(n=this.onretailerclick)||void 0===n||n.call(this,e,t),this.$emit("retailerclick",{retailerIndex:e,event:t})}clickCtaEventHandler(e,t){var i,n;t.stopPropagation(),this.handleNavigation&&this.getRetailerData(e).ctaButton.url&&void 0!==this.getRetailerData(e).ctaButton.url&&""!==this.getRetailerData(e).ctaButton.url&&window.open(this.getRetailerData(e).ctaButton.url,null===(i=this.getRetailerData(e).ctaButton)||void 0===i?void 0:i.target),null===(n=this.onretailerctaclick)||void 0===n||n.call(this,e,t),this.$emit("retailerctaclick",{retailerIndex:e,event:t})}mouseEventHandler(e,t){var i;null===(i=this.onretailerhover)||void 0===i||i.call(this,e,t),this.$emit("retailerhover",{retailerIndex:e,event:t})}get getData(){return this._data}getRetailerData(e){var t;return null===(t=this._data)||void 0===t?void 0:t.retailers[e]}}(0,o.gn)([Z],Ng.prototype,"data",void 0),(0,o.gn)([Z],Ng.prototype,"locale",void 0),(0,o.gn)([Z],Ng.prototype,"currency",void 0),(0,o.gn)([Z],Ng.prototype,"layout",void 0),(0,o.gn)([Z],Ng.prototype,"appearance",void 0),(0,o.gn)([Z({attribute:"handle-navigation",mode:"boolean"})],Ng.prototype,"handleNavigation",void 0),(0,o.gn)([Z({attribute:"hide-retailers-logo"})],Ng.prototype,"hideRetailersLogo",void 0),(0,o.gn)([Z({attribute:"no-data-label"})],Ng.prototype,"noDataLabel",void 0),(0,o.gn)([Z({attribute:"lowest-price-label"})],Ng.prototype,"lowestPriceLabel",void 0),(0,o.gn)([Z({attribute:"discount-price-label"})],Ng.prototype,"discountPriceLabel",void 0),(0,o.gn)([Z({attribute:"cta-button-label"})],Ng.prototype,"ctaButtonLabel",void 0),(0,o.gn)([x],Ng.prototype,"_data",void 0);const Rg=Te`
:host {
}
:host .container {
}
:host ul {
list-style-type: none;
margin: 0;
padding: 0;
}
:host li {
margin: 0;
padding: 0;
}
:host a {
text-decoration: none;
}
:host .retailer-list {
}
:host .retailer-list-item {
cursor: pointer;
}
:host .retailer-list-item:not(:last-child) {
border-bottom: 1px solid ${Me};
}
:host .no-data-label {
font-family: ${cc};
font-size: ${dc};
font-weight: ${uc};
color: ${"var(--colorPaletteRedForeground3)"};
}
:host .retailer-list-item a {
display: flex;
flex-direction: row;
align-items: top;
padding-block: ${Je};
padding-inline: ${Ke};
column-gap: ${"var(--spacingHorizontalM)"};
}
:host commerceui-retailer-item {
flex: 1;
}
:host .price {
display: flex;
flex-direction: column;
row-gap: ${Xe};
justify-content: flex-start;
align-items: flex-end;
align-content: flex-start;
min-width: 60px;
}
:host .save-label {
display: flex;
flex-direction: row;
column-gap: ${Ye};
align-items: self-end;
font-family: ${pc};
font-size: ${gc};
font-weight: ${fc};
color: ${Le};
}
:host .cta-button {
display: flex;
justify-content: flex-start;
flex-direction: column;
}
/*********************************************
* Edge Appearance styles
**********************************************/
:host .appearance-edge {
border: 1px solid ${Me};
border-radius: ${Ue};
background-color: ${Ie};
box-shadow: ${"var(--shadow2)"};
}
:host .appearance-edge .retailer-list-item:first-child :hover {
border-top-left-radius: ${Ue};
border-top-right-radius: ${Ue};
}
:host .appearance-edge .retailer-list-item:last-child :hover {
border-bottom-left-radius: ${Ue};
border-bottom-right-radius: ${Ue};
}
:host .appearance-edge .retailer-list-item :hover {
background-color: ${De};
transition: background-color 0.3s ease-in-out;
}
/*********************************************
* PDP Appearance styles
**********************************************/
:host .appearance-pdp {
border: 1px solid ${Re};
border-radius: ${"var(--borderRadiusLarge)"};
}
:host .appearance-pdp .retailer-list-item:first-child :hover {
border-top-left-radius: ${Ue};
border-top-right-radius: ${Ue};
}
:host .appearance-pdp .retailer-list-item:last-child :hover {
border-bottom-left-radius: ${Ue};
border-bottom-right-radius: ${Ue};
}
:host .appearance-pdp .retailer-list-item :hover {
background-color: ${De};
transition: background-color 0.3s ease-in-out;
}
/*********************************************
* SERP Appearance styles
**********************************************/
:host .appearance-serp {
border: 1px solid ${Re};
border-radius: ${Ue};
}
:host .appearance-serp .retailer-list-item:first-child :hover {
border-top-left-radius: ${Ue};
border-top-right-radius: ${Ue};
}
:host .appearance-serp .retailer-list-item:last-child :hover {
border-bottom-left-radius: ${Ue};
border-bottom-right-radius: ${Ue};
}
:host .appearance-serp .retailer-list-item :hover {
background-color: ${"var(--colorNeutralBackground3Hover)"};
transition: background-color 0.3s ease-in-out;
}
`,Mg="accent-primary",Lg=Object.freeze({prefix:"commerceui",shadowRootMode:"open",registry:customElements}),Bg="xx-small",Fg="x-small",Ug="small",Hg="medium",$g="large",Zg="x-large",Vg="neutral",Gg="accent-primary",jg="accent-secondary",zg="accent-brand",Wg="subtle",Kg="inverted",qg="inherit",Yg="bottom",Xg="start";class Jg extends se{constructor(){super(...arguments),this.value=0,this.locale="en-US",this.currency="USD",this.currencySymbol="$",this.nonBreakingSpace=!1,this.currencySymbolPosition=Xg,this.percentSymbol="%",this.perItemLabel="",this.perItemSeparator="/",this.size=Hg,this.color=Vg,this.hideCurrency=!1,this.discountLabel="off",this.discountLabelPosition=Yg,this.hideCents=!1,this.showZeroCents=!1,this.showRaisedCents=!1,this.showDiscountPercent=!1,this.strikethrough=!1,this.showDiscount=!1}}(0,o.gn)([Z({attribute:"value",converter:H})],Jg.prototype,"value",void 0),(0,o.gn)([Z],Jg.prototype,"locale",void 0),(0,o.gn)([Z],Jg.prototype,"currency",void 0),(0,o.gn)([Z({attribute:"currency-symbol"})],Jg.prototype,"currencySymbol",void 0),(0,o.gn)([Z({attribute:"non-breaking-space"})],Jg.prototype,"nonBreakingSpace",void 0),(0,o.gn)([Z({attribute:"currency-symbol-position"})],Jg.prototype,"currencySymbolPosition",void 0),(0,o.gn)([Z({attribute:"percent-symbol"})],Jg.prototype,"percentSymbol",void 0),(0,o.gn)([Z({attribute:"per-item-label"})],Jg.prototype,"perItemLabel",void 0),(0,o.gn)([Z({attribute:"per-item-separator"})],Jg.prototype,"perItemSeparator",void 0),(0,o.gn)([Z],Jg.prototype,"size",void 0),(0,o.gn)([Z],Jg.prototype,"color",void 0),(0,o.gn)([Z({attribute:"hide-currency",mode:"boolean"})],Jg.prototype,"hideCurrency",void 0),(0,o.gn)([Z({attribute:"discount-label"})],Jg.prototype,"discountLabel",void 0),(0,o.gn)([Z({attribute:"discount-label-position"})],Jg.prototype,"discountLabelPosition",void 0),(0,o.gn)([Z({attribute:"hide-cents",mode:"boolean"})],Jg.prototype,"hideCents",void 0),(0,o.gn)([Z({attribute:"show-zero-cents",mode:"boolean"})],Jg.prototype,"showZeroCents",void 0),(0,o.gn)([Z({attribute:"show-raised-cents",mode:"boolean"})],Jg.prototype,"showRaisedCents",void 0),(0,o.gn)([Z({attribute:"show-discount-percent",mode:"boolean"})],Jg.prototype,"showDiscountPercent",void 0),(0,o.gn)([Z({mode:"boolean"})],Jg.prototype,"strikethrough",void 0),(0,o.gn)([Z({mode:"boolean",attribute:"show-discount"})],Jg.prototype,"showDiscount",void 0);class Qg extends Jg{constructor(){super(...arguments),this._hideDecimal=!1,this._currencySymbol=this.currencySymbol,this._currencySymbolPosition=Xg,this._hasNonBreakingSpace=!1,this._discountLabel=this.discountLabel,this._percentSymbol="%"}valueChanged(){this.updateLocalizedValues()}localeChanged(){this.updateLocalizedValues()}currencyChanged(){this.updateLocalizedValues()}updateLocalizedValues(){const e=this.value,t=this.currency||"USD",i=((e,t,i)=>{var n,o,r,a;const s={},l={style:"currency",currency:i,currencyDisplay:"symbol"},c=Intl.NumberFormat(t,l).formatToParts(e);let d="";return c.forEach((e=>{"integer"!==e.type&&"group"!==e.type||(d=d.concat(e.value))})),s.currencySymbol=null===(n=c.find((e=>"currency"===e.type)))||void 0===n?void 0:n.value,s.valueInteger=d,s.decimalSymbol=(null===(o=c.find((e=>"decimal"===e.type)))||void 0===o?void 0:o.value)||".",s.valueCents=(null===(r=c.find((e=>"fraction"===e.type)))||void 0===r?void 0:r.value)||"00",s.currencySymbolPosition="currency"==(null===(a=c[0])||void 0===a?void 0:a.type)?Xg:"end",s.hasNonBreakingSpace=null!=c.find((e=>"literal"===e.type&&" "===e.value)),s})(e,this.locale||void 0,t);this._currencySymbol=i.currencySymbol,this._valueInteger=i.valueInteger,this._decimalSymbol=i.decimalSymbol,this._valueCents=i.valueCents,this._currencySymbolPosition=i.currencySymbolPosition,this._hasNonBreakingSpace=i.hasNonBreakingSpace}connectedCallback(){super.connectedCallback(),"00"!==this._valueCents||!1!==this.showZeroCents&&void 0!==this.showZeroCents||(this.hideCents=!0),!this.showRaisedCents||this.size!==Ug&&this.size!==Fg&&this.size!==Bg||(this.showRaisedCents=!1,this._hideDecimal=!1),this.showDiscount&&(this.showRaisedCents=!1),!0===this.showDiscount&&!0===this.showDiscountPercent&&(this.hideCurrency=!0,this.hideCents=!0),!0!==this.hideCents&&!0!==this.showRaisedCents||(this._hideDecimal=!0)}get getDiscountLabel(){return this._discountLabel}get getCurrencySymbol(){return this._currencySymbol}get getPercentSymbol(){return this._percentSymbol}get getDecimalSymbol(){return this._decimalSymbol}get getValueInteger(){return this._valueInteger}get getValueCents(){return this._valueCents}get getHideDecimal(){return this._hideDecimal}get getCurrencySymbolPosition(){return this.currencySymbolPosition?this.currencySymbolPosition:this._currencySymbolPosition}get hasNonBreakingSpace(){return this.nonBreakingSpace?this.nonBreakingSpace:this._hasNonBreakingSpace}}(0,o.gn)([x],Qg.prototype,"_hideDecimal",void 0),(0,o.gn)([T],Qg.prototype,"getCurrencySymbolPosition",null),(0,o.gn)([T],Qg.prototype,"hasNonBreakingSpace",null);const ef=Te.partial`
font-family: ${He};
font-size: ${gc};
line-height: calc(${mc} * 0.9);
font-weight: ${fc};
`,tf=Te.partial`
font-family: ${He};
font-size: ${dc};
line-height: calc(${hc} * 0.7);
font-weight: ${uc};
`,nf=Te.partial`
font-family: ${He};
font-size: ${Tc};
line-height: calc(${Oc} * 0.75);
font-weight: ${wc};
`,of=Te.partial`
font-family: ${He};
font-size: ${bc};
line-height: calc(${xc} * 0.7);
font-weight: ${Sc};
`,rf=Te.partial`
font-family: ${He};
font-size: ${kc};
line-height: calc(${Dc} * 0.8);
font-weight: ${Ic};
`,af=Te.partial`
font-family: ${He};
font-size: ${Pc};
line-height: calc(${Ec} * 0.65);
font-weight: ${Ac};
`,sf=Te.partial`
font-family: ${He};
`,lf=Te.partial`
color: ${Oe};
`,cf=Te.partial`
color: ${Le};
`,df=Te.partial`
color: ${"var(--colorPaletteRedForeground1)"};
`,uf=Te.partial`
color: ${Ae};
`,hf=Te.partial`
color: ${Ee};
`,pf=Te.partial`
color: ${ke};
`,gf=Te`
/**
* Container styles
**/
:host {
${of}
${lf}
}
:host .price-container {
display: flex;
flex-direction: row;
}
:host([strikethrough]) .currency {
text-decoration: line-through;
}
:host([strikethrough]) .integer {
text-decoration: line-through;
}
:host([strikethrough]) .cents {
text-decoration: line-through;
}
:host([strikethrough]) .decimal {
text-decoration: line-through;
}
:host .per-item-container {
display: flex;
flex-direction: row;
align-items: flex-end;
padding-left: ${je};
column-gap: ${je};
font-weight: ${Ze};
${uf}
}
:host .per-item-separator {
}
:host .per-item-label {
}
/**
* Container size styles
**/
:host([size="${Bg}"]) .price-container {
${ef}
}
:host([size="${Fg}"]) .price-container {
${tf}
}
:host([size="${Ug}"]) .price-container {
${nf}
}
:host([size="${Hg}"]) .price-container {
${of}
}
:host([size="${$g}"]) .price-container {
${rf}
}
:host([size="${Zg}"]) .price-container {
${af}
}
/**
* Container color styles
**/
:host([color="${Vg}"]) .price-container {
${lf}
}
:host([color="${Gg}"]) .price-container {
${cf}
}
:host([color="${jg}"]) .price-container {
${df}
}
:host([color="${zg}"]) .price-container {
${pf}
}
:host([color="${Wg}"]) .price-container {
${uf}
}
:host([color="${Kg}"]) .price-container {
${hf}
}
:host([color="${qg}"]) .price-container {
color: inherit;
}
/**
* Raised currency and cents styles for all size
*/
:host([show-raised-cents]) .currency {
vertical-align: top;
margin-right: 0.1em;
font-size: ${"60%"};
line-height: ${"1.0"};
transform: translateY(${"10%"});
}
:host([show-raised-cents]) .cents {
vertical-align: top;
margin-left: 0.05em;
font-size: ${"60%"};
line-height: ${"1.0"};
transform: translateY(${"8%"});
}
/**
* Raised currency and cents custon line-height for medium size
*/
:host([show-raised-cents][size="${Hg}"]) .cents {
}
:host([show-raised-cents][size="${Hg}"]) .currency {
}
/**
* Discount styles
**/
.discount-label {
${sf}
margin-left: 0.2em;
}
/*
we dont support top position for small, x-small, xx-small sizes
*/
:host([discount-label-position="${"top"}"]:not([size="${Ug}"]):not([size="${Fg}"]):not([size="${Bg}"]))
.discount-label {
vertical-align: top;
font-size: ${"60%"};
line-height: ${"1.0"};
transform: translateY(0.1em);
}
/*
Currently, the middle position is not supported by the component.
:host([discount-label-position="middle"]) .discount-label {
justify-content: center;
font-size: 60%;
} */
:host([discount-label-position="${Yg}"]))
.discount-label {
margin-left: 0.2em;
font-size: 100%;
}
:host([discount-label-color="${Vg}"]) .discount-label {
${lf}
}
:host([discount-label-color="${Gg}"]) .discount-label {
${cf}
}
:host([discount-label-color="${jg}"]) .discount-label {
${df}
}
:host([discount-label-color="${zg}"]) .discount-label {
${pf}
}
:host([discount-label-color="${Wg}"]) .discount-label {
${uf}
}
:host([discount-label-color="${Kg}"]) .discount-label {
${hf}
}
:host([discount-label-color="${qg}"]) .discount-label {
color: inherit;
}
`,ff=Nt`
<div class="price-container">
${Lt((e=>!e.hideCurrency&&e.getCurrencySymbolPosition==Xg),Nt`
<div class="currency">
${e=>e.getCurrencySymbol}${Lt((e=>e.hasNonBreakingSpace),Nt` `)}
</div>
`)}
<div class="integer">${e=>e.getValueInteger}</div>
${Lt((e=>!e.getHideDecimal),Nt` <div class="decimal">${e=>e.getDecimalSymbol}</div> `)}
${Lt((e=>!e.hideCents),Nt` <div class="cents">${e=>e.getValueCents}</div> `)}
${Lt((e=>!e.hideCurrency&&"end"==e.getCurrencySymbolPosition),Nt`
<div class="currency">
${Lt((e=>e.hasNonBreakingSpace),Nt` `)}${e=>e.getCurrencySymbol}
</div>
`)}
${Lt((e=>e.showDiscountPercent),Nt` <div>${e=>e.getPercentSymbol}</div> `)}
${Lt((e=>e.showDiscount),Nt` <div class="discount-label">${e=>e.discountLabel}</div> `)}
${Lt((e=>void 0!==e.perItemLabel&&""!==e.perItemLabel),Nt`
<div class="per-item-container">
${Lt((e=>void 0!==e.perItemSeparator),Nt` <div class="per-item-separator">${e=>e.perItemSeparator}</div> `)}
<div class="per-item-label">${e=>e.perItemLabel}</div>
</div>
`)}
</div>
`;Nt`<commerceui-price
value="${e=>e.value}"
show-discount="${e=>e.showDiscount}"
show-discount-percent="${e=>e.showDiscountPercent}"
discount-label-position="${e=>e.discountLabelPosition}"
percent-symbol="${e=>e.percentSymbol}"
per-item-separator="${e=>e.perItemSeparator}"
per-item-label="${e=>e.perItemLabel}"
show-raised-cents="${e=>e.showRaisedCents}"
show-zero-cents="${e=>e.showZeroCents}"
hide-cents="${e=>e.hideCents}"
hide-currency="${e=>e.hideCurrency}"
strikethrough="${e=>e.strikethrough}"
currency="${e=>e.currency}"
currency-symbol="${e=>e.currencySymbol}"
currency-symbol-position="${e=>e.currencySymbolPosition}"
non-breaking-space="${e=>e.nonBreakingSpace}"
locale="${e=>e.locale}"
color="${e=>e.color}"
size="${e=>e.size}"
discount-label="${e=>e.discountLabel}"
></commerceui-price>`,Qg.compose({name:`${Lg.prefix}-price`,template:ff,styles:gf}).define(Lg.registry);const mf=Object.freeze({prefix:"commerceui",shadowRootMode:"open",registry:customElements});let vf;const yf="fast-kernel";try{if(document.currentScript)vf=document.currentScript.getAttribute(yf);else{const e=document.getElementsByTagName("script");vf=e[e.length-1].getAttribute(yf)}}catch(e){vf="isolate"}let Cf;switch(vf){case"share":Cf=Object.freeze({updateQueue:1,observable:2,contextEvent:3,elementRegistry:4});break;case"share-v2":Cf=Object.freeze({updateQueue:1.2,observable:2.2,contextEvent:3.2,elementRegistry:4.2});break;default:const e=`-${Math.random().toString(36).substring(2,8)}`;Cf=Object.freeze({updateQueue:`1.2${e}`,observable:`2.2${e}`,contextEvent:`3.2${e}`,elementRegistry:`4.2${e}`})}const bf=e=>"function"==typeof e,Sf=e=>"string"==typeof e,xf=()=>{};class Tf{constructor(e,t){this.sub1=void 0,this.sub2=void 0,this.spillover=void 0,this.subject=e,this.sub1=t}has(e){return void 0===this.spillover?this.sub1===e||this.sub2===e:-1!==this.spillover.indexOf(e)}subscribe(e){const t=this.spillover;if(void 0===t){if(this.has(e))return;if(void 0===this.sub1)return void(this.sub1=e);if(void 0===this.sub2)return void(this.sub2=e);this.spillover=[this.sub1,this.sub2,e],this.sub1=void 0,this.sub2=void 0}else-1===t.indexOf(e)&&t.push(e)}unsubscribe(e){const t=this.spillover;if(void 0===t)this.sub1===e?this.sub1=void 0:this.sub2===e&&(this.sub2=void 0);else{const i=t.indexOf(e);-1!==i&&t.splice(i,1)}}notify(e){const t=this.spillover,i=this.subject;if(void 0===t){const t=this.sub1,n=this.sub2;void 0!==t&&t.handleChange(i,e),void 0!==n&&n.handleChange(i,e)}else for(let n=0,o=t.length;n<o;++n)t[n].handleChange(i,e)}}class wf{constructor(e){this.subscribers={},this.subjectSubscribers=null,this.subject=e}notify(e){var t,i;null===(t=this.subscribers[e])||void 0===t||t.notify(e),null===(i=this.subjectSubscribers)||void 0===i||i.notify(e)}subscribe(e,t){var i,n;let o;o=t?null!==(i=this.subscribers[t])&&void 0!==i?i:this.subscribers[t]=new Tf(this.subject):null!==(n=this.subjectSubscribers)&&void 0!==n?n:this.subjectSubscribers=new Tf(this.subject),o.subscribe(e)}unsubscribe(e,t){var i,n;t?null===(i=this.subscribers[t])||void 0===i||i.unsubscribe(e):null===(n=this.subjectSubscribers)||void 0===n||n.unsubscribe(e)}}!function(){if("undefined"==typeof globalThis)if("undefined"!=typeof global)global.globalThis=global;else if("undefined"!=typeof self)self.globalThis=self;else if("undefined"!=typeof window)window.globalThis=window;else{const e=new Function("return this")();e.globalThis=e}}();const Of={configurable:!1,enumerable:!1,writable:!1};void 0===globalThis.FAST&&Reflect.defineProperty(globalThis,"FAST",Object.assign({value:Object.create(null)},Of));const Pf=globalThis.FAST;if(void 0===Pf.getById){const e=Object.create(null);Reflect.defineProperty(Pf,"getById",Object.assign({value(t,i){let n=e[t];return void 0===n&&(n=i?e[t]=i():null),n}},Of))}function Af(){const e=new Map;return Object.freeze({register(t){return!e.has(t.type)&&(e.set(t.type,t),!0)},getByType(t){return e.get(t)},getForInstance(t){if(null!=t)return e.get(t.constructor)}})}function Ef(){const e=new WeakMap;return function(t){let i=e.get(t);if(void 0===i){let n=Reflect.getPrototypeOf(t);for(;void 0===i&&null!==n;)i=e.get(n),n=Reflect.getPrototypeOf(n);i=void 0===i?[]:i.slice(0),e.set(t,i)}return i}}function kf(e){e.prototype.toJSON=xf}void 0===Pf.error&&Object.assign(Pf,{warn(){},error(e){return new Error(`Error ${e}`)},addMessages(){}}),Object.freeze([]);const If=Pf.getById(Cf.updateQueue,(()=>{const e=[],t=[],i=globalThis.requestAnimationFrame;let n=!0;function o(){if(t.length)throw t.shift()}function r(i){try{i.call()}catch(i){if(!n)throw e.length=0,i;t.push(i),setTimeout(o,0)}}function a(){let t=0;for(;t<e.length;)if(r(e[t]),t++,t>1024){for(let i=0,n=e.length-t;i<n;i++)e[i]=e[i+t];e.length-=t,t=0}e.length=0}function s(t){e.push(t),e.length<2&&(n?i(a):a())}return Object.freeze({enqueue:s,next:()=>new Promise(s),process:a,setMode:e=>n=e})})),Df=Object.freeze({unknown:void 0,coupled:1}),_f=Pf.getById(Cf.observable,(()=>{const e=If.enqueue,t=/(:|&&|\|\||if|\?\.)/,i=new WeakMap;let n,o=e=>{throw Pf.error(1101)};function r(e){var t;let n=null!==(t=e.$fastController)&&void 0!==t?t:i.get(e);return void 0===n&&(Array.isArray(e)?n=o(e):i.set(e,n=new wf(e))),n}const a=Ef();class s{constructor(e){this.name=e,this.field=`_${e}`,this.callback=`${e}Changed`}getValue(e){return void 0!==n&&n.watch(e,this.name),e[this.field]}setValue(e,t){const i=this.field,n=e[i];if(n!==t){e[i]=t;const o=e[this.callback];bf(o)&&o.call(e,n,t),r(e).notify(this.name)}}}class l extends Tf{constructor(e,t,i=!1){super(e,t),this.expression=e,this.isVolatileBinding=i,this.needsRefresh=!0,this.needsQueue=!0,this.isAsync=!0,this.first=this,this.last=null,this.propertySource=void 0,this.propertyName=void 0,this.notifier=void 0,this.next=void 0}setMode(e){this.isAsync=this.needsQueue=e}bind(e){this.controller=e;const t=this.observe(e.source,e.context);return!e.isBound&&this.requiresUnbind(e)&&e.onUnbind(this),t}requiresUnbind(e){return e.sourceLifetime!==Df.coupled||this.first!==this.last||this.first.propertySource!==e.source}unbind(e){this.dispose()}observe(e,t){this.needsRefresh&&null!==this.last&&this.dispose();const i=n;let o;n=this.needsRefresh?this:void 0,this.needsRefresh=this.isVolatileBinding;try{o=this.expression(e,t)}finally{n=i}return o}disconnect(){this.dispose()}dispose(){if(null!==this.last){let e=this.first;for(;void 0!==e;)e.notifier.unsubscribe(this,e.propertyName),e=e.next;this.last=null,this.needsRefresh=this.needsQueue=this.isAsync}}watch(e,t){const i=this.last,o=r(e),a=null===i?this.first:{};if(a.propertySource=e,a.propertyName=t,a.notifier=o,o.subscribe(this,t),null!==i){if(!this.needsRefresh){let t;n=void 0,t=i.propertySource[i.propertyName],n=this,e===t&&(this.needsRefresh=!0)}i.next=a}this.last=a}handleChange(){this.needsQueue?(this.needsQueue=!1,e(this)):this.isAsync||this.call()}call(){null!==this.last&&(this.needsQueue=this.isAsync,this.notify(this))}*records(){let e=this.first;for(;void 0!==e;)yield e,e=e.next}}return kf(l),Object.freeze({setArrayObserverFactory(e){o=e},getNotifier:r,track(e,t){n&&n.watch(e,t)},trackVolatile(){n&&(n.needsRefresh=!0)},notify(e,t){r(e).notify(t)},defineProperty(e,t){Sf(t)&&(t=new s(t)),a(e).push(t),Reflect.defineProperty(e,t.name,{enumerable:!0,get(){return t.getValue(this)},set(e){t.setValue(this,e)}})},getAccessors:a,binding(e,t,i=this.isVolatileBinding(e)){return new l(e,t,i)},isVolatileBinding(e){return t.test(e.toString())}})})),Nf=Pf.getById(Cf.contextEvent,(()=>{let e=null;return{get(){return e},set(t){e=t}}})),Rf=Object.freeze({default:{index:0,length:0,get event(){return Rf.getEvent()},eventDetail(){return this.event.detail},eventTarget(){return this.event.target}},getEvent(){return Nf.get()},setEvent(e){Nf.set(e)}});let Mf;function Lf(e){return e.map((e=>e instanceof Bf?Lf(e.styles):[e])).reduce(((e,t)=>e.concat(t)),[])}class Bf{constructor(e){this.styles=e,this.targets=new WeakSet,this._strategy=null,this.behaviors=e.map((e=>e instanceof Bf?e.behaviors:null)).reduce(((e,t)=>null===t?e:null===e?t:e.concat(t)),null)}get strategy(){return null===this._strategy&&this.withStrategy(Mf),this._strategy}addStylesTo(e){this.strategy.addStylesTo(e),this.targets.add(e)}removeStylesFrom(e){this.strategy.removeStylesFrom(e),this.targets.delete(e)}isAttachedTo(e){return this.targets.has(e)}withBehaviors(...e){return this.behaviors=null===this.behaviors?e:this.behaviors.concat(e),this}withStrategy(e){return this._strategy=new e(Lf(this.styles)),this}static setDefaultStrategy(e){Mf=e}static normalize(e){return void 0===e?void 0:Array.isArray(e)?new Bf(e):e instanceof Bf?e:new Bf([e])}}Bf.supportsAdoptedStyleSheets=Array.isArray(document.adoptedStyleSheets)&&"replace"in CSSStyleSheet.prototype;const Ff=Object.freeze({none:0,attribute:1,booleanAttribute:2,property:3,content:4,tokenList:5,event:6}),Uf=e=>e,Hf=globalThis.trustedTypes?globalThis.trustedTypes.createPolicy("fast-html",{createHTML:Uf}):{createHTML:Uf};let $f=Object.freeze({createHTML(e){return Hf.createHTML(e)},protect(e,t,i,n){return n}});const Zf=$f,Vf=Object.freeze({get policy(){return $f},setPolicy(e){if($f!==Zf)throw Pf.error(1201);$f=e},setAttribute(e,t,i){null==i?e.removeAttribute(t):e.setAttribute(t,i)},setBooleanAttribute(e,t,i){i?e.setAttribute(t,""):e.removeAttribute(t)}}),Gf="boolean",jf="reflect",zf=Object.freeze({locate:Ef()}),Wf={toView(e){return e?"true":"false"},fromView(e){return null!=e&&"false"!==e&&!1!==e&&0!==e}};class Kf{constructor(e,t,i=t.toLowerCase(),n=jf,o){this.guards=new Set,this.Owner=e,this.name=t,this.attribute=i,this.mode=n,this.converter=o,this.fieldName=`_${t}`,this.callbackName=`${t}Changed`,this.hasCallback=this.callbackName in e.prototype,n===Gf&&void 0===o&&(this.converter=Wf)}setValue(e,t){const i=e[this.fieldName],n=this.converter;void 0!==n&&(t=n.fromView(t)),i!==t&&(e[this.fieldName]=t,this.tryReflectToAttribute(e),this.hasCallback&&e[this.callbackName](i,t),e.$fastController.notify(this.name))}getValue(e){return _f.track(e,this.name),e[this.fieldName]}onAttributeChangedCallback(e,t){this.guards.has(e)||(this.guards.add(e),this.setValue(e,t),this.guards.delete(e))}tryReflectToAttribute(e){const t=this.mode,i=this.guards;i.has(e)||"fromView"===t||If.enqueue((()=>{i.add(e);const n=e[this.fieldName];switch(t){case jf:const t=this.converter;Vf.setAttribute(e,this.attribute,void 0!==t?t.toView(n):n);break;case Gf:Vf.setBooleanAttribute(e,this.attribute,n)}i.delete(e)}))}static collect(e,...t){const i=[];t.push(zf.locate(e));for(let n=0,o=t.length;n<o;++n){const o=t[n];if(void 0!==o)for(let t=0,n=o.length;t<n;++t){const n=o[t];Sf(n)?i.push(new Kf(e,n)):i.push(new Kf(e,n.property,n.attribute,n.mode,n.converter))}}return i}}function qf(e,t){let i;function n(e,t){arguments.length>1&&(i.property=t),zf.locate(e.constructor).push(i)}return arguments.length>1?(i={},void n(e,t)):(i=void 0===e?{}:e,n)}const Yf={mode:"open"},Xf={},Jf=new Set,Qf=Pf.getById(Cf.elementRegistry,(()=>Af()));class em{constructor(e,t=e.definition){var i;this.platformDefined=!1,Sf(t)&&(t={name:t}),this.type=e,this.name=t.name,this.template=t.template,this.registry=null!==(i=t.registry)&&void 0!==i?i:customElements;const n=e.prototype,o=Kf.collect(e,t.attributes),r=new Array(o.length),a={},s={};for(let e=0,t=o.length;e<t;++e){const t=o[e];r[e]=t.attribute,a[t.name]=t,s[t.attribute]=t,_f.defineProperty(n,t)}Reflect.defineProperty(e,"observedAttributes",{value:r,enumerable:!0}),this.attributes=o,this.propertyLookup=a,this.attributeLookup=s,this.shadowOptions=void 0===t.shadowOptions?Yf:null===t.shadowOptions?void 0:Object.assign(Object.assign({},Yf),t.shadowOptions),this.elementOptions=void 0===t.elementOptions?Xf:Object.assign(Object.assign({},Xf),t.elementOptions),this.styles=Bf.normalize(t.styles),Qf.register(this)}get isDefined(){return this.platformDefined}define(e=this.registry){const t=this.type;return e.get(this.name)||(this.platformDefined=!0,e.define(this.name,t,this.elementOptions)),this}static compose(e,t){return Jf.has(e)||Qf.getByType(e)?new em(class extends e{},t):new em(e,t)}static registerBaseType(e){Jf.add(e)}}em.getByType=Qf.getByType,em.getForInstance=Qf.getForInstance;const tm={bubbles:!0,composed:!0,cancelable:!0},im="isConnected",nm=new WeakMap;function om(e){var t,i;return null!==(i=null!==(t=e.shadowRoot)&&void 0!==t?t:nm.get(e))&&void 0!==i?i:null}let rm;class am extends wf{constructor(e,t){super(e),this.boundObservables=null,this.needsInitialization=!0,this.hasExistingShadowRoot=!1,this._template=null,this.stage=3,this.guardBehaviorConnection=!1,this.behaviors=null,this._mainStyles=null,this.$fastController=this,this.view=null,this.source=e,this.definition=t;const i=t.shadowOptions;if(void 0!==i){let t=e.shadowRoot;t?this.hasExistingShadowRoot=!0:(t=e.attachShadow(i),"closed"===i.mode&&nm.set(e,t))}const n=_f.getAccessors(e);if(n.length>0){const t=this.boundObservables=Object.create(null);for(let i=0,o=n.length;i<o;++i){const o=n[i].name,r=e[o];void 0!==r&&(delete e[o],t[o]=r)}}}get isConnected(){return _f.track(this,im),1===this.stage}get context(){var e,t;return null!==(t=null===(e=this.view)||void 0===e?void 0:e.context)&&void 0!==t?t:Rf.default}get isBound(){var e,t;return null!==(t=null===(e=this.view)||void 0===e?void 0:e.isBound)&&void 0!==t&&t}get sourceLifetime(){var e;return null===(e=this.view)||void 0===e?void 0:e.sourceLifetime}get template(){var e;if(null===this._template){const t=this.definition;this.source.resolveTemplate?this._template=this.source.resolveTemplate():t.template&&(this._template=null!==(e=t.template)&&void 0!==e?e:null)}return this._template}set template(e){this._template!==e&&(this._template=e,this.needsInitialization||this.renderTemplate(e))}get mainStyles(){var e;if(null===this._mainStyles){const t=this.definition;this.source.resolveStyles?this._mainStyles=this.source.resolveStyles():t.styles&&(this._mainStyles=null!==(e=t.styles)&&void 0!==e?e:null)}return this._mainStyles}set mainStyles(e){this._mainStyles!==e&&(null!==this._mainStyles&&this.removeStyles(this._mainStyles),this._mainStyles=e,this.needsInitialization||this.addStyles(e))}onUnbind(e){var t;null===(t=this.view)||void 0===t||t.onUnbind(e)}addBehavior(e){var t,i;const n=null!==(t=this.behaviors)&&void 0!==t?t:this.behaviors=new Map,o=null!==(i=n.get(e))&&void 0!==i?i:0;0===o?(n.set(e,1),e.addedCallback&&e.addedCallback(this),!e.connectedCallback||this.guardBehaviorConnection||1!==this.stage&&0!==this.stage||e.connectedCallback(this)):n.set(e,o+1)}removeBehavior(e,t=!1){const i=this.behaviors;if(null===i)return;const n=i.get(e);void 0!==n&&(1===n||t?(i.delete(e),e.disconnectedCallback&&3!==this.stage&&e.disconnectedCallback(this),e.removedCallback&&e.removedCallback(this)):i.set(e,n-1))}addStyles(e){var t;if(!e)return;const i=this.source;if(e instanceof HTMLElement)(null!==(t=om(i))&&void 0!==t?t:this.source).append(e);else if(!e.isAttachedTo(i)){const t=e.behaviors;if(e.addStylesTo(i),null!==t)for(let e=0,i=t.length;e<i;++e)this.addBehavior(t[e])}}removeStyles(e){var t;if(!e)return;const i=this.source;if(e instanceof HTMLElement)(null!==(t=om(i))&&void 0!==t?t:i).removeChild(e);else if(e.isAttachedTo(i)){const t=e.behaviors;if(e.removeStylesFrom(i),null!==t)for(let e=0,i=t.length;e<i;++e)this.removeBehavior(t[e])}}connect(){if(3!==this.stage)return;if(this.stage=0,null!==this.boundObservables){const e=this.source,t=this.boundObservables,i=Object.keys(t);for(let n=0,o=i.length;n<o;++n){const o=i[n];e[o]=t[o]}this.boundObservables=null}const e=this.behaviors;if(null!==e){this.guardBehaviorConnection=!0;for(const t of e.keys())t.connectedCallback&&t.connectedCallback(this);this.guardBehaviorConnection=!1}this.needsInitialization?(this.renderTemplate(this.template),this.addStyles(this.mainStyles),this.needsInitialization=!1):null!==this.view&&this.view.bind(this.source),this.stage=1,_f.notify(this,im)}disconnect(){if(1!==this.stage)return;this.stage=2,_f.notify(this,im),null!==this.view&&this.view.unbind();const e=this.behaviors;if(null!==e)for(const t of e.keys())t.disconnectedCallback&&t.disconnectedCallback(this);this.stage=3}onAttributeChangedCallback(e,t,i){const n=this.definition.attributeLookup[e];void 0!==n&&n.onAttributeChangedCallback(this.source,i)}emit(e,t,i){return 1===this.stage&&this.source.dispatchEvent(new CustomEvent(e,Object.assign(Object.assign({detail:t},tm),i)))}renderTemplate(e){var t;const i=this.source,n=null!==(t=om(i))&&void 0!==t?t:i;if(null!==this.view)this.view.dispose(),this.view=null;else if(!this.needsInitialization||this.hasExistingShadowRoot){this.hasExistingShadowRoot=!1;for(let e=n.firstChild;null!==e;e=n.firstChild)n.removeChild(e)}e&&(this.view=e.render(i,n,i),this.view.sourceLifetime=Df.coupled)}static forCustomElement(e){const t=e.$fastController;if(void 0!==t)return t;const i=em.getForInstance(e);if(void 0===i)throw Pf.error(1401);return e.$fastController=new rm(e,i)}static setStrategy(e){rm=e}}function sm(e){var t;return"adoptedStyleSheets"in e?e:null!==(t=om(e))&&void 0!==t?t:e.getRootNode()}kf(am),am.setStrategy(am);class lm{constructor(e){const t=lm.styleSheetCache;this.sheets=e.map((e=>{if(e instanceof CSSStyleSheet)return e;let i=t.get(e);return void 0===i&&(i=new CSSStyleSheet,i.replaceSync(e),t.set(e,i)),i}))}addStylesTo(e){um(sm(e),this.sheets)}removeStylesFrom(e){hm(sm(e),this.sheets)}}lm.styleSheetCache=new Map;let cm=0;function dm(e){return e===document?document.body:e}let um=(e,t)=>{e.adoptedStyleSheets=[...e.adoptedStyleSheets,...t]},hm=(e,t)=>{e.adoptedStyleSheets=e.adoptedStyleSheets.filter((e=>-1===t.indexOf(e)))};if(Bf.supportsAdoptedStyleSheets){try{document.adoptedStyleSheets.push(),document.adoptedStyleSheets.splice(),um=(e,t)=>{e.adoptedStyleSheets.push(...t)},hm=(e,t)=>{for(const i of t){const t=e.adoptedStyleSheets.indexOf(i);-1!==t&&e.adoptedStyleSheets.splice(t,1)}}}catch(e){}Bf.setDefaultStrategy(lm)}else Bf.setDefaultStrategy(class{constructor(e){this.styles=e,this.styleClass="fast-"+ ++cm}addStylesTo(e){e=dm(sm(e));const t=this.styles,i=this.styleClass;for(let n=0;n<t.length;n++){const o=document.createElement("style");o.innerHTML=t[n],o.className=i,e.append(o)}}removeStylesFrom(e){const t=(e=dm(sm(e))).querySelectorAll(`.${this.styleClass}`);for(let i=0,n=t.length;i<n;++i)e.removeChild(t[i])}});function pm(e){const t=class extends e{constructor(){super(),am.forCustomElement(this)}$emit(e,t,i){return this.$fastController.emit(e,t,i)}connectedCallback(){this.$fastController.connect()}disconnectedCallback(){this.$fastController.disconnect()}attributeChangedCallback(e,t,i){this.$fastController.onAttributeChangedCallback(e,t,i)}};return em.registerBaseType(t),t}const gm=Object.assign(pm(HTMLElement),{from:function(e){return pm(e)},define:function(e,t){return bf(e)?em.compose(e,t).define().type:em.compose(this,e).define().type},compose:function(e,t){return bf(e)?em.compose(e,t):em.compose(this,e)}}),fm="regular",mm="cashback",vm="cashback",ym="cashback-outline",Cm="small",bm="medium",Sm="large",xm="x-large",Tm="deal";class wm{constructor(e,t,i=!1){this.evaluate=e,this.policy=t,this.isVolatile=i}}class Om extends wm{createObserver(e){return _f.binding(this.evaluate,e,this.isVolatile)}}function Pm(e,t,i=_f.isVolatileBinding(e)){return new Om(e,t,i)}class Am extends wm{createObserver(){return this}bind(e){return this.evaluate(e.source,e.context)}}function Em(e,t){return new Am(e,t)}kf(Am);const km=`fast-${Math.random().toString(36).substring(2,8)}`,Im=`${km}{`,Dm=`}${km}`,_m=Dm.length;let Nm=0;const Rm=()=>`${km}-${++Nm}`,Mm=Object.freeze({interpolation:e=>`${Im}${e}${Dm}`,attribute:e=>`${Rm()}="${Im}${e}${Dm}"`,comment:e=>`\x3c!--${Im}${e}${Dm}--\x3e`}),Lm=Object.freeze({parse(e,t){const i=e.split(Im);if(1===i.length)return null;const n=[];for(let e=0,o=i.length;e<o;++e){const o=i[e],r=o.indexOf(Dm);let a;if(-1===r)a=o;else{const e=o.substring(0,r);n.push(t[e]),a=o.substring(r+_m)}""!==a&&n.push(a)}return n}}),Bm=Af(),Fm=Object.freeze({getForInstance:Bm.getForInstance,getByType:Bm.getByType,define(e,t){return(t=t||{}).type=e,Bm.register(t),e},assignAspect(e,t){if(t)switch(e.sourceAspect=t,t[0]){case":":e.targetAspect=t.substring(1),e.aspectType="classList"===e.targetAspect?Ff.tokenList:Ff.property;break;case"?":e.targetAspect=t.substring(1),e.aspectType=Ff.booleanAttribute;break;case"@":e.targetAspect=t.substring(1),e.aspectType=Ff.event;break;default:e.targetAspect=t,e.aspectType=Ff.attribute}else e.aspectType=Ff.content}});class Um{constructor(e){this.options=e}createHTML(e){return Mm.attribute(e(this))}createBehavior(){return this}}kf(Um);const Hm={[Ff.attribute]:Vf.setAttribute,[Ff.booleanAttribute]:Vf.setBooleanAttribute,[Ff.property]:(e,t,i)=>e[t]=i,[Ff.content]:function(e,t,i,n){if(null==i&&(i=""),i.create){e.textContent="";let t=e.$fastView;void 0===t?t=i.create():e.$fastTemplate!==i&&(t.isComposed&&(t.remove(),t.unbind()),t=i.create()),t.isComposed?t.needsBindOnly&&(t.needsBindOnly=!1,t.bind(n.source,n.context)):(t.isComposed=!0,t.bind(n.source,n.context),t.insertBefore(e),e.$fastView=t,e.$fastTemplate=i)}else{const t=e.$fastView;void 0!==t&&t.isComposed&&(t.isComposed=!1,t.remove(),t.needsBindOnly?t.needsBindOnly=!1:t.unbind()),e.textContent=i}},[Ff.tokenList]:function(e,t,i){var n;const o=`${this.id}-t`,r=null!==(n=e[o])&&void 0!==n?n:e[o]={v:0,cv:Object.create(null)},a=r.cv;let s=r.v;const l=e[t];if(null!=i&&i.length){const e=i.split(/\s+/);for(let t=0,i=e.length;t<i;++t){const i=e[t];""!==i&&(a[i]=s,l.add(i))}}if(r.v=s+1,0!==s){s-=1;for(const e in a)a[e]===s&&l.remove(e)}},[Ff.event]:()=>{}};class $m{constructor(e){this.dataBinding=e,this.updateTarget=null,this.aspectType=Ff.content}createHTML(e){return Mm.interpolation(e(this))}createBehavior(){var e;if(null===this.updateTarget){const t=Hm[this.aspectType],i=null!==(e=this.dataBinding.policy)&&void 0!==e?e:this.policy;if(!t)throw Pf.error(1205);this.data=`${this.id}-d`,this.updateTarget=i.protect(this.targetTagName,this.aspectType,this.targetAspect,t)}return this}bind(e){var t;const i=e.targets[this.targetNodeId];switch(this.aspectType){case Ff.event:i[this.data]=e,i.addEventListener(this.targetAspect,this,this.dataBinding.options);break;case Ff.content:e.onUnbind(this);default:const n=null!==(t=i[this.data])&&void 0!==t?t:i[this.data]=this.dataBinding.createObserver(this,this);n.target=i,n.controller=e,this.updateTarget(i,this.targetAspect,n.bind(e),e)}}unbind(e){const t=e.targets[this.targetNodeId].$fastView;void 0!==t&&t.isComposed&&(t.unbind(),t.needsBindOnly=!0)}handleEvent(e){const t=e.currentTarget[this.data];if(t.isBound){Rf.setEvent(e);const i=this.dataBinding.evaluate(t.source,t.context);Rf.setEvent(null),!0!==i&&e.preventDefault()}}handleChange(e,t){const i=t.target,n=t.controller;this.updateTarget(i,this.targetAspect,t.bind(n),n)}}function Zm(e,t){const i=e.parentNode;let n,o=e;for(;o!==t;)n=o.nextSibling,i.removeChild(o),o=n;i.removeChild(t)}Fm.define($m,{aspected:!0});class Vm{constructor(e,t,i){this.fragment=e,this.factories=t,this.targets=i,this.behaviors=null,this.unbindables=[],this.source=null,this.isBound=!1,this.sourceLifetime=Df.unknown,this.context=this,this.index=0,this.length=0,this.firstChild=e.firstChild,this.lastChild=e.lastChild}get event(){return Rf.getEvent()}get isEven(){return this.index%2==0}get isOdd(){return this.index%2!=0}get isFirst(){return 0===this.index}get isInMiddle(){return!this.isFirst&&!this.isLast}get isLast(){return this.index===this.length-1}eventDetail(){return this.event.detail}eventTarget(){return this.event.target}appendTo(e){e.appendChild(this.fragment)}insertBefore(e){if(this.fragment.hasChildNodes())e.parentNode.insertBefore(this.fragment,e);else{const t=this.lastChild;if(e.previousSibling===t)return;const i=e.parentNode;let n,o=this.firstChild;for(;o!==t;)n=o.nextSibling,i.insertBefore(o,e),o=n;i.insertBefore(t,e)}}remove(){const e=this.fragment,t=this.lastChild;let i,n=this.firstChild;for(;n!==t;)i=n.nextSibling,e.appendChild(n),n=i;e.appendChild(t)}dispose(){Zm(this.firstChild,this.lastChild),this.unbind()}onUnbind(e){this.unbindables.push(e)}bind(e,t=this){if(this.source===e)return;let i=this.behaviors;if(null===i){this.source=e,this.context=t,this.behaviors=i=new Array(this.factories.length);const n=this.factories;for(let e=0,t=n.length;e<t;++e){const t=n[e].createBehavior();t.bind(this),i[e]=t}}else{null!==this.source&&this.evaluateUnbindables(),this.isBound=!1,this.source=e,this.context=t;for(let e=0,t=i.length;e<t;++e)i[e].bind(this)}this.isBound=!0}unbind(){this.isBound&&null!==this.source&&(this.evaluateUnbindables(),this.source=null,this.context=this,this.isBound=!1)}evaluateUnbindables(){const e=this.unbindables;for(let t=0,i=e.length;t<i;++t)e[t].unbind(this);e.length=0}static disposeContiguousBatch(e){if(0!==e.length){Zm(e[0].firstChild,e[e.length-1].lastChild);for(let t=0,i=e.length;t<i;++t)e[t].unbind()}}}kf(Vm),_f.defineProperty(Vm.prototype,"index"),_f.defineProperty(Vm.prototype,"length");const Gm=(e,t)=>`${e}.${t}`,jm={},zm={index:0,node:null};function Wm(e){e.startsWith("fast-")||Pf.warn(1204,{name:e})}const Km=new Proxy(document.createElement("div"),{get(e,t){Wm(t);const i=Reflect.get(e,t);return bf(i)?i.bind(e):i},set(e,t,i){return Wm(t),Reflect.set(e,t,i)}});class qm{constructor(e,t,i){this.fragment=e,this.directives=t,this.policy=i,this.proto=null,this.nodeIds=new Set,this.descriptors={},this.factories=[]}addFactory(e,t,i,n,o){var r,a;this.nodeIds.has(i)||(this.nodeIds.add(i),this.addTargetDescriptor(t,i,n)),e.id=null!==(r=e.id)&&void 0!==r?r:Rm(),e.targetNodeId=i,e.targetTagName=o,e.policy=null!==(a=e.policy)&&void 0!==a?a:this.policy,this.factories.push(e)}freeze(){return this.proto=Object.create(null,this.descriptors),this}addTargetDescriptor(e,t,i){const n=this.descriptors;if("r"===t||"h"===t||n[t])return;if(!n[e]){const t=e.lastIndexOf("."),i=e.substring(0,t),n=parseInt(e.substring(t+1));this.addTargetDescriptor(i,e,n)}let o=jm[t];if(!o){const n=`_${t}`;jm[t]=o={get(){var t;return null!==(t=this[n])&&void 0!==t?t:this[n]=this[e].childNodes[i]}}}n[t]=o}createView(e){const t=this.fragment.cloneNode(!0),i=Object.create(this.proto);i.r=t,i.h=null!=e?e:Km;for(const e of this.nodeIds)i[e];return new Vm(t,this.factories,i)}}function Ym(e,t,i,n,o,r=!1){const a=i.attributes,s=e.directives;for(let l=0,c=a.length;l<c;++l){const d=a[l],u=d.value,h=Lm.parse(u,s);let p=null;null===h?r&&(p=new $m(Em((()=>u),e.policy)),Fm.assignAspect(p,d.name)):p=ev.aggregate(h,e.policy),null!==p&&(i.removeAttributeNode(d),l--,c--,e.addFactory(p,t,n,o,i.tagName))}}function Xm(e,t,i){let n=0,o=t.firstChild;for(;o;){const t=Jm(e,i,o,n);o=t.node,n=t.index}}function Jm(e,t,i,n){const o=Gm(t,n);switch(i.nodeType){case 1:Ym(e,t,i,o,n),Xm(e,i,o);break;case 3:return function(e,t,i,n,o){const r=Lm.parse(t.textContent,e.directives);if(null===r)return zm.node=t.nextSibling,zm.index=o+1,zm;let a,s=a=t;for(let t=0,l=r.length;t<l;++t){const l=r[t];0!==t&&(o++,n=Gm(i,o),a=s.parentNode.insertBefore(document.createTextNode(""),s.nextSibling)),Sf(l)?a.textContent=l:(a.textContent=" ",Fm.assignAspect(l),e.addFactory(l,i,n,o,null)),s=a}return zm.index=o+1,zm.node=s.nextSibling,zm}(e,i,t,o,n);case 8:const r=Lm.parse(i.data,e.directives);null!==r&&e.addFactory(ev.aggregate(r),t,o,n,null)}return zm.index=n+1,zm.node=i.nextSibling,zm}const Qm="TEMPLATE",ev={compile(e,t,i=Vf.policy){let n;if(Sf(e)){n=document.createElement(Qm),n.innerHTML=i.createHTML(e);const t=n.content.firstElementChild;null!==t&&t.tagName===Qm&&(n=t)}else n=e;n.content.firstChild||n.content.lastChild||n.content.appendChild(document.createComment(""));const o=document.adoptNode(n.content),r=new qm(o,t,i);var a,s;return Ym(r,"",n,"h",0,!0),s=t,((a=o.firstChild)&&8==a.nodeType&&null!==Lm.parse(a.data,s)||1===o.childNodes.length&&Object.keys(t).length>0)&&o.insertBefore(document.createComment(""),o.firstChild),Xm(r,o,"r"),zm.node=null,r.freeze()},setDefaultStrategy(e){this.compile=e},aggregate(e,t=Vf.policy){if(1===e.length)return e[0];let i,n,o,r=!1;const a=e.length,s=e.map((e=>Sf(e)?()=>e:(i=e.sourceAspect||i,n=e.dataBinding||n,r=r||e.dataBinding.isVolatile,o=o||e.dataBinding.policy,e.dataBinding.evaluate)));n.evaluate=(e,t)=>{let i="";for(let n=0;n<a;++n)i+=s[n](e,t);return i},n.isVolatile=r,n.policy=null!=o?o:t;const l=new $m(n);return Fm.assignAspect(l,i),l}},tv=/([ \x09\x0a\x0c\x0d])([^\0-\x1F\x7F-\x9F "'>=/]+)([ \x09\x0a\x0c\x0d]*=[ \x09\x0a\x0c\x0d]*(?:[^ \x09\x0a\x0c\x0d"'`<>=]*|"[^"]*|'[^']*))$/,iv=Object.create(null);class nv{constructor(e,t=iv){this.html=e,this.factories=t}createHTML(e){const t=this.factories;for(const i in t)e(t[i]);return this.html}}function ov(e,t,i,n=Fm.getForInstance(e)){if(n.aspected){const i=tv.exec(t);null!==i&&Fm.assignAspect(e,i[2])}return e.createHTML(i)}nv.empty=new nv(""),Fm.define(nv);class rv{constructor(e,t={},i){this.policy=i,this.result=null,this.html=e,this.factories=t}create(e){return null===this.result&&(this.result=ev.compile(this.html,this.factories,this.policy)),this.result.createView(e)}inline(){return new nv(Sf(this.html)?this.html:this.html.innerHTML,this.factories)}withPolicy(e){if(this.result)throw Pf.error(1208);if(this.policy)throw Pf.error(1207);return this.policy=e,this}render(e,t,i){const n=this.create(i);return n.bind(e),n.appendTo(t),n}static create(e,t,i){let n="";const o=Object.create(null),r=e=>{var t;const i=null!==(t=e.id)&&void 0!==t?t:e.id=Rm();return o[i]=e,i};for(let i=0,o=e.length-1;i<o;++i){const o=e[i];let a,s=t[i];if(n+=o,bf(s))s=new $m(Pm(s));else if(s instanceof wm)s=new $m(s);else if(!(a=Fm.getForInstance(s))){const e=s;s=new $m(Em((()=>e)))}n+=ov(s,o,r,a)}return new rv(n+e[e.length-1],o,i)}}kf(rv);const av=(e,...t)=>{if(Array.isArray(e)&&Array.isArray(e.raw))return rv.create(e,t);throw Pf.error(1206)};av.partial=e=>new nv(e);const sv=av`<svg
width="15"
height="15"
viewBox="0 0 15 15"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M9.34371 1.34221C8.82929 0.871203 8.03471 0.888446 7.54126 1.38132L1.38175 7.53355C0.872744 8.04195 0.87275 8.86623 1.38177 9.37463L2.24403 10.2358C2.56723 10.5587 3.0322 10.4809 3.30606 10.2986C3.46824 10.1906 3.66273 10.1277 3.87307 10.1277C4.43868 10.1277 4.89719 10.5857 4.89719 11.1506C4.89719 11.3607 4.83418 11.5549 4.72608 11.7169C4.54355 11.9904 4.46572 12.4548 4.78892 12.7776L5.63098 13.6187C6.15094 14.138 6.99783 14.1252 7.5018 13.5904L13.6457 7.07039C14.1437 6.54195 14.1129 5.70887 13.5773 5.2185L12.7521 4.46291C12.5482 4.27627 12.2903 4.24102 12.0757 4.27926C11.8643 4.31693 11.6639 4.42864 11.5193 4.58689C11.3315 4.79239 11.0623 4.92049 10.7626 4.92049C10.197 4.92049 9.7385 4.46253 9.7385 3.8976C9.7385 3.62992 9.84095 3.38698 10.0095 3.20443C10.155 3.04688 10.2491 2.83781 10.2683 2.62427C10.2879 2.40739 10.2302 2.1539 10.0265 1.96734L9.34371 1.34221Z"
fill="${ke}"
/>
</svg> `,lv=av`<svg
width="15"
height="15"
viewBox="0 0 15 15"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M2.99507 3.00001C1.89051 2.99729 0.997293 3.89052 1.00001 4.99507L1.01143 9.64502C1.01414 10.7496 1.91177 11.6472 3.01632 11.6499L9.60413 11.6661C10.1296 11.6674 10.6334 11.4619 11.0067 11.0939L13.4019 8.73317C14.193 7.95348 14.1918 6.67471 13.3993 5.88872L11.0912 3.59978C10.7157 3.2274 10.2091 3.01773 9.68153 3.01643L2.99507 3.00001Z"
fill="${ke}"
/>
</svg> `,cv=av`<svg
width="16"
height="12"
viewBox="0 0 16 12"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M2.45652 0.857918C1.09648 0.854474 -0.00333321 1.98825 7.59088e-06 3.39028L0.0140721 9.29253C0.0174134 10.6946 1.12265 11.8339 2.48268 11.8374L10.5942 11.8579C11.2412 11.8595 11.8615 11.5987 12.3211 11.1317L15.2704 8.1351C16.2445 7.14543 16.243 5.52227 15.2671 4.5246L12.4253 1.61922C11.9629 1.14655 11.3391 0.880412 10.6895 0.878767L2.45652 0.857918Z"
fill="${ke}"
/>
</svg> `,dv=av`
<svg width="16" height="12" viewBox="0 0 16 12" fill="none" xmlns="http://www.w3.org/2000/svg">
<path
d="M0.500006 3.38909C0.497291 2.24961 1.38665 1.35521 2.45525 1.35792L10.6882 1.37877C11.201 1.38006 11.6974 1.59009 12.0678 1.96884L12.4253 1.61922L12.0678 1.96884L14.9097 4.87423C15.6967 5.67877 15.6954 6.9905 14.9141 7.78437L11.9648 10.7809C11.5981 11.1535 11.1061 11.3592 10.5955 11.3579L2.48395 11.3374C1.41322 11.3347 0.51679 10.4325 0.514071 9.29134L0.500006 3.38909Z"
stroke="${ke}"
/>
</svg>
`,uv=av`<svg
width="13"
height="10"
viewBox="0 0 13 10"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M1.99507 0.857916C0.890514 0.855203 -0.00270708 1.74843 6.16497e-06 2.85298L0.0114288 7.50293C0.0141423 8.60749 0.911765 9.50511 2.01632 9.50782L8.60413 9.52401C9.12955 9.5253 9.63337 9.31977 10.0067 8.95185L12.4019 6.59108C13.193 5.81139 13.1918 4.53262 12.3993 3.74663L10.0912 1.45769C9.71575 1.08531 9.20907 0.875638 8.68153 0.874342L1.99507 0.857916Z"
fill="${ke}"
/>
</svg> `,hv=av`
<svg width="13" height="10" viewBox="0 0 13 10" fill="none" xmlns="http://www.w3.org/2000/svg">
<path
d="M0.500005 2.85175C0.497972 2.0243 1.16639 1.35588 1.99384 1.35791L8.68031 1.37434C9.07601 1.37531 9.45675 1.53264 9.73915 1.81271L12.0472 4.10165C12.6438 4.69328 12.6421 5.65234 12.051 6.23497L9.65569 8.59574C9.3765 8.8709 8.99937 9.02497 8.60536 9.02401L2.01755 9.00782C1.18818 9.00579 0.513465 8.33108 0.511427 7.5017L0.500005 2.85175Z"
stroke="${ke}"
/>
</svg>
`,pv=av`<svg viewBox="0 0 14 40" xmlns="http://www.w3.org/2000/svg">
<path
d="M4.53165 37.3908C3.65607 38.9991 1.97143 40 0.140313 40H2.98023e-07V-1.19209e-06H0.140313C1.97143 -1.19209e-06 3.65607 1.00095 4.53165 2.60916L12.6983 17.6092C13.5099 19.0998 13.5099 20.9002 12.6983 22.3908L4.53165 37.3908Z"
/>
</svg>`,gv=av`<svg
width="15"
height="15"
viewBox="0 0 15 15"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M2.08402 2C1.48533 2 1 2.48123 1 3.07486V5.84011C1 7.96094 2.73392 9.68021 4.87281 9.68021C4.91764 9.68021 4.96229 9.67946 5.00675 9.67796C4.81737 9.14852 4.71429 8.57857 4.71429 7.98475C4.71429 7.48355 4.78772 6.99935 4.9245 6.54217L3.9217 5.54813C3.74036 5.36837 3.74032 5.07688 3.92161 4.89707C4.1029 4.71727 4.39687 4.71722 4.57821 4.89698L5.30535 5.61778C5.84885 4.60036 6.73181 3.78861 7.8046 3.33091C7.09443 2.51582 6.04437 2 4.87281 2H2.08402ZM6.55698 10.5714L4.90138 12.2142C4.72014 12.3941 4.72025 12.6856 4.90163 12.8653C5.08301 13.045 5.37698 13.0449 5.55823 12.865L7.21367 11.2223C7.92845 11.7891 8.83502 12.128 9.82143 12.128C12.1292 12.128 14 10.273 14 7.98475V4.97145C14 4.34737 13.4898 3.84146 12.8604 3.84146L9.82143 3.84146C7.51367 3.84146 5.64286 5.69647 5.64286 7.98475C5.64286 8.96324 5.98494 9.8625 6.55698 10.5714ZM10.1526 8.30607L7.87426 10.5651C7.62542 10.3802 7.4042 10.1607 7.21786 9.91388L9.49596 7.65502C9.67728 7.47523 9.97125 7.47523 10.1526 7.65502C10.3339 7.8348 10.3339 8.12629 10.1526 8.30607Z"
fill="${Le}"
/>
</svg> `,fv=av`<svg
width="15"
height="15"
viewBox="0 0 15 15"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M2.05479 8.20279L2.05373 8.20667C1.97678 8.50665 1.67997 8.68579 1.3907 8.60622C0.923291 8.4777 1.00558 7.91834 1.00558 7.91834L1.02474 7.84928C1.02474 7.84928 1.05304 7.75466 1.07584 7.68597C1.12141 7.54871 1.1911 7.35683 1.29017 7.1285C1.48777 6.67305 1.80537 6.06537 2.2872 5.45581C3.26044 4.22457 4.89653 3 7.49367 3C10.0908 3 11.7269 4.22457 12.7001 5.45581C13.182 6.06537 13.4996 6.67305 13.6972 7.1285C13.7962 7.35683 13.8659 7.54871 13.9115 7.68597C13.9343 7.75466 13.9511 7.80984 13.9626 7.84928C13.9683 7.869 13.9728 7.8848 13.9759 7.8964L13.9797 7.91062L13.981 7.9153L13.9814 7.91703L13.9818 7.91834C14.0585 8.21862 13.8861 8.5266 13.5966 8.60622C13.3076 8.68572 13.0113 8.5075 12.934 8.20805L12.9336 8.20667L12.9325 8.20279L12.9246 8.17466C12.9169 8.14818 12.9043 8.10668 12.8862 8.05232C12.8501 7.94349 12.7923 7.78381 12.7084 7.59026C12.5399 7.20196 12.2691 6.68464 11.8617 6.16919C11.0564 5.15043 9.71047 4.125 7.49367 4.125C5.27687 4.125 3.93095 5.15043 3.12567 6.16919C2.71824 6.68464 2.44745 7.20196 2.27898 7.59026C2.195 7.78381 2.13723 7.94349 2.1011 8.05232C2.08306 8.10668 2.07047 8.14818 2.06276 8.17466L2.05479 8.20279ZM4.78284 9.1875C4.78284 7.6342 5.99656 6.375 7.49376 6.375C8.99095 6.375 10.2047 7.6342 10.2047 9.1875C10.2047 10.7408 8.99095 12 7.49376 12C5.99656 12 4.78284 10.7408 4.78284 9.1875Z"
fill="${e=>e.getIconColor}"
/>
</svg> `,mv=av`<svg
width="15"
height="15"
viewBox="0 0 16 16"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M2 3.75C2 2.7835 2.7835 2 3.75 2H9.25016C10.2167 2 11.0002 2.7835 11.0002 3.75V4H11.382C11.9501 4 12.4695 4.321 12.7236 4.82918L13.8416 7.06525C13.9458 7.27353 14 7.5032 14 7.73607V11C14 11.8284 13.3284 12.5 12.5 12.5H11.937C11.715 13.3626 10.9319 14 10 14C9.06808 14 8.28503 13.3626 8.06301 12.5H6.93699C6.71497 13.3626 5.93192 14 5 14C4.01321 14 3.19333 13.2853 3.02971 12.3454C2.4225 12.0708 2 11.4597 2 10.75V3.75ZM8.06301 11.5C8.28503 10.6374 9.06808 10 10 10C9.99995 10 10.0001 10 10 10L10.0002 3.75C10.0002 3.33579 9.66438 3 9.25016 3H3.75C3.33579 3 3 3.33579 3 3.75V10.75C3 10.9251 3.05997 11.0861 3.16049 11.2137C3.46594 10.5 4.17458 10 5 10C5.93192 10 6.71497 10.6374 6.93699 11.5H8.06301ZM11.0002 10.2677C11.4585 10.5328 11.8018 10.9746 11.937 11.5H12.5C12.7761 11.5 13 11.2761 13 11V8H11.0002V10.2677ZM11.0002 7H12.691L11.8292 5.27639C11.7445 5.107 11.5714 5 11.382 5H11.0002V7ZM5 11C4.44772 11 4 11.4477 4 12C4 12.5523 4.44772 13 5 13C5.55228 13 6 12.5523 6 12C6 11.4477 5.55228 11 5 11ZM9 12C9 12.5523 9.44772 13 10 13C10.5523 13 11 12.5523 11 12C11 11.4477 10.5523 11 10 11C9.44772 11 9 11.4477 9 12Z"
fill="${Oe}"
/>
</svg>`,vv="x-small",yv="medium",Cv="large";class bv extends gm{constructor(){super(...arguments),this.type=fm,this.size=bm,this.color="informative",this.appearance="filled"}connectedCallback(){super.connectedCallback(),this.configSlottedPriceComponent()}typeChanged(){this.type===mm&&(this.color="brand",this.appearance="ghost")}get getIconColor(){let e;return e="important"===this.color?"var(--colorNeutralForegroundInverted2)":Oe,e}get getSize(){return this.size===Cm?this.type!==mm||this.icon!==vm&&this.icon!==ym?(this.size=bm,"medium"):"small":this.size===bm?"medium":this.size===Sm?"large":this.size===xm?"extra-large":void 0}get getIcon(){return this.type===mm?this.getCashbackIcon():this.getRegularIcon()}getRegularIcon(){switch(this.icon){case"coupon":return sv;case vm:return lv;case"ethical-choice":return gv;case"views":return fv;case"truck":return mv;default:return void(this.icon=void 0)}}getCashbackIcon(){switch(this.icon){case vm:return"small"===this.getSize?uv:(this.size=bm,cv);case ym:return"small"===this.getSize?hv:(this.size=bm,dv)}}configSlottedPriceComponent(){const e=this.querySelector("commerceui-price");if(e)switch(e.color="inverted",this.size){case bm:e.size=vv;break;case Sm:e.size=yv;break;case xm:e.size=Cv}}}(0,o.gn)([qf],bv.prototype,"type",void 0),(0,o.gn)([qf],bv.prototype,"icon",void 0),(0,o.gn)([qf],bv.prototype,"size",void 0),(0,o.gn)([qf],bv.prototype,"color",void 0),(0,o.gn)([qf],bv.prototype,"appearance",void 0);const Sv=Af(),xv=Object.freeze({getForInstance:Sv.getForInstance,getByType:Sv.getByType,define(e){return Sv.register({type:e}),e}});function Tv(e,t,i){t.source.style.setProperty(e.targetAspect,i.bind(t))}class wv{constructor(e,t){this.dataBinding=e,this.targetAspect=t}createCSS(e){return e(this),`var(${this.targetAspect})`}addedCallback(e){var t;const i=e.source;if(!i.$cssBindings){i.$cssBindings=new Map;const e=i.setAttribute;i.setAttribute=(t,n)=>{e.call(i,t,n),"style"===t&&i.$cssBindings.forEach(((e,t)=>Tv(t,e.controller,e.observer)))}}const n=null!==(t=e[this.targetAspect])&&void 0!==t?t:e[this.targetAspect]=this.dataBinding.createObserver(this,this);n.controller=e,e.source.$cssBindings.set(this,{controller:e,observer:n})}connectedCallback(e){Tv(this,e,e[this.targetAspect])}removedCallback(e){e.source.$cssBindings&&e.source.$cssBindings.delete(this)}handleChange(e,t){Tv(this,t.controller,t)}}xv.define(wv);const Ov=`${Math.random().toString(36).substring(2,8)}`;let Pv=0;const Av=()=>`--v${Ov}${++Pv}`;function Ev(e,t){const i=[];let n="";const o=[],r=e=>{o.push(e)};for(let o=0,a=e.length-1;o<a;++o){n+=e[o];let a=t[o];bf(a)?a=new wv(Pm(a),Av()).createCSS(r):a instanceof wm?a=new wv(a,Av()).createCSS(r):void 0!==xv.getForInstance(a)&&(a=a.createCSS(r)),a instanceof Bf||a instanceof CSSStyleSheet?(""!==n.trim()&&(i.push(n),n=""),i.push(a)):n+=a}return n+=e[e.length-1],""!==n.trim()&&i.push(n),{styles:i,behaviors:o}}const kv=(e,...t)=>{const{styles:i,behaviors:n}=Ev(e,t),o=new Bf(i);return n.length?o.withBehaviors(...n):o};class Iv{constructor(e,t){this.behaviors=t,this.css="";const i=e.reduce(((e,t)=>(Sf(t)?this.css+=t:e.push(t),e)),[]);i.length&&(this.styles=new Bf(i))}createCSS(e){return this.behaviors.forEach(e),this.styles&&e(this),this.css}addedCallback(e){e.addStyles(this.styles)}removedCallback(e){e.removeStyles(this.styles)}}xv.define(Iv),kv.partial=(e,...t)=>{const{styles:i,behaviors:n}=Ev(e,t);return new Iv(i,n)};const Dv=kv`
/**
* Container styles
**/
:host([icon]) fluent-beta-badge {
padding-inline-start: ${je};
}
.icon {
display: flex;
align-items: center;
justify-content: center;
width: 20px;
height: 20px;
margin-inline-end: ${je};
}
/**
/ Make sure the badge is always inline with the text and not wrapping
*/
:host fluent-beta-badge {
width: max-content;
}
/*
* We need to override the badge styles for the following colors
*/
:host([color="${"success"}"]) fluent-beta-badge {
border: transparent;
}
/*
* Deal is the custom style
* we need to hide default border and background
*/
:host([color="${Tm}"]) fluent-beta-badge:after {
border: transparent;
background: transparent;
}
/* Deal media query to show custom style for light and dark */
@media (prefers-color-scheme: dark) {
:host([color="${Tm}"]) fluent-beta-badge {
color: #fff;
outline: 1px solid rgba(214, 222, 255, 0.2);
outline-offset: -1px;
background: var(
--dark-deal-days-gradient,
linear-gradient(90deg, #050f8d -0.77%, #0077d4 100%)
);
}
}
@media (prefers-color-scheme: light) {
:host([color="${Tm}"]) fluent-beta-badge {
color: #264587;
border: 1px solid #d6deff;
background: var(
--light-deal-days-gradient,
linear-gradient(139deg, rgba(239, 250, 255, 0.5) 5.76%, rgba(214, 222, 255, 0.5) 100%),
#fff
);
}
}
/* Cashback badge type */
:host([type=${mm}]:not([icon])) {
position: relative;
display: inline-flex;
width: fit-content;
height: fit-content;
}
:host([type=${mm}]:not([icon])) fluent-beta-badge {
height: fit-content;
max-height: 40px;
contain: layout style;
padding-block: ${Ye};
padding-inline-end: ${ze};
color: ${"var(--colorNeutralForegroundInverted)"};
background-color: ${_e};
border-radius: ${Fe};
border-start-end-radius: 0;
border-end-end-radius: 0;
}
:host([type=${mm}]:not([icon])) fluent-beta-badge + div {
position: absolute;
height: 100%;
inset-block-start: 0;
inset-inline-end: 0;
text-align: initial;
}
:host([type=${mm}][size=${bm}]:not([icon])) fluent-beta-badge + div {
width: 7px;
}
:host([type=${mm}][size=${Sm}]:not([icon])) fluent-beta-badge + div {
width: 11px;
}
:host([type=${mm}][size=${xm}]:not([icon])) fluent-beta-badge + div {
width: 14px;
}
:host([type=${mm}]:not([icon])) fluent-beta-badge + div svg {
height: 100%;
fill: ${_e};
}
:host([type=${mm}][size=${bm}]:not([icon])) fluent-beta-badge {
min-height: 20px;
padding-block: ${qe};
margin-inline-end: 7px;
}
:host([type=${mm}][size=${Sm}]:not([icon])) fluent-beta-badge {
min-height: 32px;
margin-inline-end: 11px;
}
:host([type=${mm}][size=${xm}]:not([icon])) fluent-beta-badge {
min-height: 40px;
margin-inline-end: 14px;
}
:host([type=${mm}][icon]) fluent-beta-badge {
padding-inline: 0;
}
:host([type=${mm}]) .icon {
margin-inline-end: 0;
}
:host([type=${mm}][icon=${vm}][size=${Cm}]) fluent-beta-badge,
:host([type=${mm}][icon=${ym}][size=${Cm}]) fluent-beta-badge {
min-width: 16px;
height: 16px;
}
:host([type=${mm}][icon=${vm}][size=${Cm}]) .icon,
:host([type=${mm}][icon=${ym}][size=${Cm}]) .icon {
width: 16px;
height: 16px;
}
`,_v=()=>null;function Nv(e){return void 0===e?_v:bf(e)?e:()=>e}function Rv(e,t,i){const n=bf(e)?e:()=>e,o=Nv(t),r=Nv(i);return(e,t)=>n(e,t)?o(e,t):r(e,t)}const Mv=Object.freeze({prefix:"fluent",shadowRootMode:"open",registry:customElements});class Lv extends Um{bind(e){e.source[this.options]=e.targets[this.targetNodeId]}}Fm.define(Lv);const Bv=e=>new Lv(e);function Fv(e){return e?"string"==typeof e?new nv(e):"inline"in e?e.inline():e:nv.empty}var Uv=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};class Hv extends gm{constructor(){super(...arguments),this.appearance="filled",this.color="brand"}}Uv([qf],Hv.prototype,"appearance",void 0),Uv([qf],Hv.prototype,"color",void 0),Uv([qf],Hv.prototype,"shape",void 0),Uv([qf],Hv.prototype,"size",void 0),function(e,...t){const i=zf.locate(e);t.forEach((t=>{Object.getOwnPropertyNames(t.prototype).forEach((i=>{"constructor"!==i&&Object.defineProperty(e.prototype,i,Object.getOwnPropertyDescriptor(t.prototype,i))})),zf.locate(t).forEach((e=>i.push(e)))}))}(Hv,class{});const $v="var(--colorNeutralForeground1)",Zv="var(--colorNeutralForeground3)",Vv="var(--colorNeutralForegroundOnBrand)",Gv="var(--colorBrandForeground1)",jv="var(--colorNeutralBackground1)",zv="var(--colorNeutralStroke2)",Wv="var(--colorTransparentStroke)",Kv="var(--colorPaletteRedForeground3)",qv="var(--colorPaletteDarkOrangeForeground3)",Yv="var(--colorPaletteYellowForeground2)",Xv="var(--fontSizeBase200)",Jv="var(--lineHeightBase200)",Qv="var(--spacingHorizontalXXS)",ey="var(--spacingHorizontalXS)",ty=kv.partial`
${"inline-flex",":host([hidden]){display:none}:host{display:inline-flex}"} :host {
position: relative;
box-sizing: border-box;
align-items: center;
justify-content: center;
font-family: ${"var(--fontFamilyBase)"};
font-weight: ${"var(--fontWeightSemibold)"};
font-size: ${Xv};
line-height: ${Jv};
min-width: 20px;
height: 20px;
padding-inline: calc(${ey} + ${Qv});
border-radius: ${"var(--borderRadiusCircular)"};
border-color: ${Wv};
background-color: ${"var(--colorBrandBackground)"};
color: ${Vv};
contain: content;
}
::slotted(svg) {
font-size: 12px;
}
:host(:not([appearance='ghost']))::after {
position: absolute;
content: '';
top: 0;
left: 0;
bottom: 0;
right: 0;
border-style: solid;
border-width: ${"var(--strokeWidthThin)"};
border-color: inherit;
border-radius: inherit;
}
`;const iy=kv`
:host([shape='square']) {
border-radius: ${"var(--borderRadiusNone)"};
}
:host([shape='rounded']) {
border-radius: ${"var(--borderRadiusMedium)"};
}
:host([shape='rounded'][size='tiny']),
:host([shape='rounded'][size='extra-small']),
:host([shape='rounded'][size='small']) {
border-radius: ${"var(--borderRadiusSmall)"};
}
${kv.partial`
:host([size='tiny']) {
width: 6px;
height: 6px;
font-size: 4px;
line-height: 4px;
padding-inline: 0;
min-width: unset;
}
:host([size='tiny']) ::slotted(svg) {
font-size: 6px;
}
:host([size='extra-small']) {
width: 10px;
height: 10px;
font-size: 6px;
line-height: 6px;
padding-inline: 0;
min-width: unset;
}
:host([size='extra-small']) ::slotted(svg) {
font-size: 10px;
}
:host([size='small']) {
min-width: 16px;
height: 16px;
font-size: ${"var(--fontSizeBase100)"};
line-height: ${"var(--lineHeightBase100)"};
padding-inline: calc(${Qv} + ${Qv});
}
:host([size='small']) ::slotted(svg) {
font-size: 12px;
}
:host([size='large']) {
min-width: 24px;
height: 24px;
font-size: ${Xv};
line-height: ${Jv};
padding-inline: calc(${ey} + ${Qv});
}
:host([size='large']) ::slotted(svg) {
font-size: 16px;
}
:host([size='extra-large']) {
min-width: 32px;
height: 32px;
font-size: ${Xv};
line-height: ${Jv};
padding-inline: calc(${"var(--spacingHorizontalSNudge)"} + ${Qv});
}
:host([size='extra-large']) ::slotted(svg) {
font-size: 20px;
}
`}
${kv.partial`
:host([color='danger']) {
background-color: ${"var(--colorPaletteRedBackground3)"};
color: ${Vv};
}
:host([color='important']) {
background-color: ${$v};
color: ${jv};
}
:host([color='informative']) {
background-color: ${"var(--colorNeutralBackground5)"};
color: ${Zv};
}
:host([color='severe']) {
background-color: ${"var(--colorPaletteDarkOrangeBackground3)"};
color: ${Vv};
}
:host([color='subtle']) {
background-color: ${jv};
color: ${$v};
}
:host([color='success']) {
background-color: ${"var(--colorPaletteGreenBackground3)"};
color: ${Vv};
}
:host([color='warning']) {
background-color: ${"var(--colorPaletteYellowBackground3)"};
color: ${"var(--colorNeutralForeground1Static)"};
}
`}
${kv.partial`
:host([appearance='ghost']) {
color: ${Gv};
background-color: initial;
}
:host([appearance='ghost'][color='danger']) {
color: ${Kv};
}
:host([appearance='ghost'][color='important']) {
color: ${$v};
}
:host([appearance='ghost'][color='informative']) {
color: ${Zv};
}
:host([appearance='ghost'][color='severe']) {
color: ${qv};
}
:host([appearance='ghost'][color='subtle']) {
color: ${"var(--colorNeutralForegroundInverted)"};
}
:host([appearance='ghost'][color='success']) {
color: ${"var(--colorPaletteGreenForeground3)"};
}
:host([appearance='ghost'][color='warning']) {
color: ${Yv};
}
`}
${kv.partial`
:host([appearance='outline']) {
border-color: currentColor;
color: ${Gv};
background-color: initial;
}
:host([appearance='outline'][color='danger']) {
color: ${Kv};
}
:host([appearance='outline'][color='important']) {
color: ${Zv};
border-color: ${"var(--colorNeutralStrokeAccessible)"};
}
:host([appearance='outline'][color='informative']) {
color: ${Zv};
border-color: ${zv};
}
:host([appearance='outline'][color='severe']) {
color: ${qv};
}
:host([appearance='outline'][color='subtle']) {
color: ${"var(--colorNeutralForegroundStaticInverted)"};
}
:host([appearance='outline'][color='success']) {
color: ${"var(--colorPaletteGreenForeground2)"};
}
:host([appearance='outline'][color='warning']) {
color: ${Yv};
}
`}
${kv.partial`
:host([appearance='tint']) {
background-color: ${"var(--colorBrandBackground2)"};
color: ${"var(--colorBrandForeground2)"};
border-color: ${"var(--colorBrandStroke2)"};
}
:host([appearance='tint'][color='danger']) {
background-color: ${"var(--colorPaletteRedBackground1)"};
color: ${"var(--colorPaletteRedForeground1)"};
border-color: ${"var(--colorPaletteRedBorder1)"};
}
:host([appearance='tint'][color='important']) {
background-color: ${Zv};
color: ${jv};
border-color: ${Wv};
}
:host([appearance='tint'][color='informative']) {
background-color: ${"var(--colorNeutralBackground4)"};
color: ${Zv};
border-color: ${zv};
}
:host([appearance='tint'][color='severe']) {
background-color: ${"var(--colorPaletteDarkOrangeBackground1)"};
color: ${"var(--colorPaletteDarkOrangeForeground1)"};
border-color: ${"var(--colorPaletteDarkOrangeBorder1)"};
}
:host([appearance='tint'][color='subtle']) {
background-color: ${jv};
color: ${Zv};
border-color: ${zv};
}
:host([appearance='tint'][color='success']) {
background-color: ${"var(--colorPaletteGreenBackground1)"};
color: ${"var(--colorPaletteGreenForeground1)"};
border-color: ${"var(--colorPaletteGreenBorder2)"};
}
:host([appearance='tint'][color='warning']) {
background-color: ${"var(--colorPaletteYellowBackground1)"};
color: ${Yv};
border-color: ${"var(--colorPaletteYellowBorder1)"};
}
`}
${ty}
`,ny=function(e={}){return av`
${function(e){return av` <slot name="start" ${Bv("start")}>${Fv(e.start)}</slot> `.inline()}(e)}
<slot>${Fv(e.defaultContent)}</slot>
${function(e){return av` <slot name="end" ${Bv("end")}>${Fv(e.end)}</slot> `.inline()}(e)}
`}(),oy=Hv.compose({name:`${Mv.prefix}-badge`,template:ny,styles:iy});oy.name="fluent-beta-badge",oy.define(customElements);const ry=av`<template
><fluent-beta-badge
shape="rounded"
icon-position="start"
color=${e=>e.color}
size=${e=>e.getSize}
appearance=${e=>e.appearance}
>${Rv((e=>void 0!==e.icon),av`<div class="icon" slot="start">${e=>e.getIcon}</div>`)}
${Rv((e=>e.type===fm||e.type===mm&&void 0===e.icon),av`<slot></slot>`)}
</fluent-beta-badge>
${Rv((e=>e.type===mm&&void 0===e.icon),av`<div>${pv}</div>`)}
</template>`;av`<commerceui-badge
type=${e=>e.type}
color=${e=>e.color}
icon=${e=>e.icon}
size=${e=>e.size}
appearance=${e=>e.appearance}
>${e=>e.content}</commerceui-badge
>`,bv.compose({name:`${mf.prefix}-badge`,template:ry,styles:Dv}).define(mf.registry);class ay extends se{constructor(){super(...arguments),this.advertisement=!1,this.metadata=[],this.hideLogo=!1}}(0,o.gn)([Z],ay.prototype,"name",void 0),(0,o.gn)([Z({attribute:"img-url"})],ay.prototype,"imgUrl",void 0),(0,o.gn)([Z({attribute:"img-alt"})],ay.prototype,"imgAlt",void 0),(0,o.gn)([Z({mode:"boolean"})],ay.prototype,"advertisement",void 0),(0,o.gn)([Z],ay.prototype,"description",void 0),(0,o.gn)([Z({attribute:"metadata"})],ay.prototype,"metadata",void 0),(0,o.gn)([Z({attribute:"hide-logo",mode:"boolean"})],ay.prototype,"hideLogo",void 0);const sy="16px",ly=Te`
:host .container {
display: grid;
grid-auto-rows: max-content;
grid-template-columns: 20px auto;
grid-column-gap: ${We};
align-items: flex-start;
font-family: ${He};
}
:host([hide-logo]) .container {
display: flex;
flex-direction: column;
align-items: flex-start;
}
:host .logo {
grid-area: 1 / 1 / 2 / 2;
margin-block-start: ${Ye};
width: ${sy};
height: ${sy};
border-radius: ${Be};
border: 0.5px solid ${Me};
}
:host .logo-fallback {
grid-area: 1 / 1 / 2 / 2;
display: flex;
align-items: center;
justify-content: center;
margin-block-start: ${Ye};
width: ${sy};
height: ${sy};
border-radius: ${Be};
border: 1px solid ${Me};
background-color: ${Ie};
color: ${Oe};
font-size: ${vc};
line-height: ${Cc};
font-weight: ${yc};
}
:host .name-container {
grid-area: 1 / 2 / 2 / 3;
display: flex;
align-items: flex-start;
}
:host .name {
margin: 0;
margin-inline-end: ${We};
color: ${Oe};
font-size: ${Tc};
line-height: ${Oc};
font-weight: ${wc};
/* limit the name to 2 lines */
display: -webkit-box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
overflow: hidden;
}
:host fluent-beta-badge {
flex: 0 0 auto;
padding-inline: ${"var(--spacingHorizontalSNudge)"};
margin-block-start: ${Ye};
}
:host .description {
grid-area: 2 / 2 / 3 / 3;
margin: 0;
margin-block-start: ${qe};
color: ${Pe};
font-size: ${gc};
line-height: ${mc};
font-weight: ${fc};
/* limit the description to 3 lines */
display: -webkit-box;
-webkit-line-clamp: 3;
-webkit-box-orient: vertical;
overflow: hidden;
}
:host .metadata-items {
grid-area: 3 / 2 / 4 / 3;
margin-block-start: ${qe};
}
`,cy=Object.freeze({prefix:"fluent",shadowRootMode:"open",registry:customElements});function dy(e,...t){const i=B.locate(e);t.forEach((t=>{Object.getOwnPropertyNames(t.prototype).forEach((i=>{"constructor"!==i&&Object.defineProperty(e.prototype,i,Object.getOwnPropertyDescriptor(t.prototype,i))})),B.locate(t).forEach((e=>i.push(e)))}))}class uy extends ht{bind(e){e.source[this.options]=e.targets[this.targetNodeId]}}ut.define(uy);const hy=e=>new uy(e);function py(e){return e?"string"==typeof e?new It(e):"inline"in e?e.inline():e:It.empty}class gy{}function fy(e){return Nt` <slot name="end" ${hy("end")}>${py(e.end)}</slot> `.inline()}function my(e){return Nt` <slot name="start" ${hy("start")}>${py(e.start)}</slot> `.inline()}var vy=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};class yy extends se{constructor(){super(...arguments),this.appearance="filled",this.color="brand"}}function Cy(e){return`:host([hidden]){display:none}:host{display:${e}}`}vy([Z],yy.prototype,"appearance",void 0),vy([Z],yy.prototype,"color",void 0),vy([Z],yy.prototype,"shape",void 0),vy([Z],yy.prototype,"size",void 0),dy(yy,gy);const by="var(--colorNeutralForeground1)",Sy="var(--colorNeutralForeground2)",xy="var(--colorNeutralForeground2BrandHover)",Ty="var(--colorNeutralForeground2BrandPressed)",wy="var(--colorNeutralForeground3)",Oy="var(--colorNeutralForegroundOnBrand)",Py="var(--colorBrandForeground1)",Ay="var(--colorNeutralBackground1)",Ey="var(--colorTransparentBackground)",ky="var(--colorTransparentBackgroundHover)",Iy="var(--colorTransparentBackgroundPressed)",Dy="var(--colorBrandBackground)",_y="var(--colorNeutralStroke2)",Ny="var(--colorTransparentStroke)",Ry="var(--colorStrokeFocus2)",My="var(--colorPaletteRedForeground3)",Ly="var(--colorPaletteDarkOrangeForeground3)",By="var(--colorPaletteYellowForeground2)",Fy="var(--borderRadiusNone)",Uy="var(--borderRadiusSmall)",Hy="var(--borderRadiusMedium)",$y="var(--borderRadiusCircular)",Zy="var(--fontFamilyBase)",Vy="var(--fontSizeBase200)",Gy="var(--fontWeightSemibold)",jy="var(--lineHeightBase200)",zy="var(--strokeWidthThin)",Wy="var(--spacingHorizontalXXS)",Ky="var(--spacingHorizontalXS)",qy="var(--spacingHorizontalSNudge)",Yy=Wy,Xy=Te.partial`
${Cy("inline-flex")} :host {
position: relative;
box-sizing: border-box;
align-items: center;
justify-content: center;
font-family: ${Zy};
font-weight: ${Gy};
font-size: ${Vy};
line-height: ${jy};
min-width: 20px;
height: 20px;
padding-inline: calc(${Ky} + ${Yy});
border-radius: ${$y};
border-color: ${Ny};
background-color: ${Dy};
color: ${Oy};
contain: content;
}
::slotted(svg) {
font-size: 12px;
}
:host(:not([appearance='ghost']))::after {
position: absolute;
content: '';
top: 0;
left: 0;
bottom: 0;
right: 0;
border-style: solid;
border-width: ${zy};
border-color: inherit;
border-radius: inherit;
}
`,Jy=Te`
:host([shape='square']) {
border-radius: ${Fy};
}
:host([shape='rounded']) {
border-radius: ${Hy};
}
:host([shape='rounded'][size='tiny']),
:host([shape='rounded'][size='extra-small']),
:host([shape='rounded'][size='small']) {
border-radius: ${Uy};
}
${Te.partial`
:host([size='tiny']) {
width: 6px;
height: 6px;
font-size: 4px;
line-height: 4px;
padding-inline: 0;
min-width: unset;
}
:host([size='tiny']) ::slotted(svg) {
font-size: 6px;
}
:host([size='extra-small']) {
width: 10px;
height: 10px;
font-size: 6px;
line-height: 6px;
padding-inline: 0;
min-width: unset;
}
:host([size='extra-small']) ::slotted(svg) {
font-size: 10px;
}
:host([size='small']) {
min-width: 16px;
height: 16px;
font-size: ${"var(--fontSizeBase100)"};
line-height: ${"var(--lineHeightBase100)"};
padding-inline: calc(${Wy} + ${Yy});
}
:host([size='small']) ::slotted(svg) {
font-size: 12px;
}
:host([size='large']) {
min-width: 24px;
height: 24px;
font-size: ${Vy};
line-height: ${jy};
padding-inline: calc(${Ky} + ${Yy});
}
:host([size='large']) ::slotted(svg) {
font-size: 16px;
}
:host([size='extra-large']) {
min-width: 32px;
height: 32px;
font-size: ${Vy};
line-height: ${jy};
padding-inline: calc(${qy} + ${Yy});
}
:host([size='extra-large']) ::slotted(svg) {
font-size: 20px;
}
`}
${Te.partial`
:host([color='danger']) {
background-color: ${"var(--colorPaletteRedBackground3)"};
color: ${Oy};
}
:host([color='important']) {
background-color: ${by};
color: ${Ay};
}
:host([color='informative']) {
background-color: ${"var(--colorNeutralBackground5)"};
color: ${wy};
}
:host([color='severe']) {
background-color: ${"var(--colorPaletteDarkOrangeBackground3)"};
color: ${Oy};
}
:host([color='subtle']) {
background-color: ${Ay};
color: ${by};
}
:host([color='success']) {
background-color: ${"var(--colorPaletteGreenBackground3)"};
color: ${Oy};
}
:host([color='warning']) {
background-color: ${"var(--colorPaletteYellowBackground3)"};
color: ${"var(--colorNeutralForeground1Static)"};
}
`}
${Te.partial`
:host([appearance='ghost']) {
color: ${Py};
background-color: initial;
}
:host([appearance='ghost'][color='danger']) {
color: ${My};
}
:host([appearance='ghost'][color='important']) {
color: ${by};
}
:host([appearance='ghost'][color='informative']) {
color: ${wy};
}
:host([appearance='ghost'][color='severe']) {
color: ${Ly};
}
:host([appearance='ghost'][color='subtle']) {
color: ${"var(--colorNeutralForegroundInverted)"};
}
:host([appearance='ghost'][color='success']) {
color: ${"var(--colorPaletteGreenForeground3)"};
}
:host([appearance='ghost'][color='warning']) {
color: ${By};
}
`}
${Te.partial`
:host([appearance='outline']) {
border-color: currentColor;
color: ${Py};
background-color: initial;
}
:host([appearance='outline'][color='danger']) {
color: ${My};
}
:host([appearance='outline'][color='important']) {
color: ${wy};
border-color: ${"var(--colorNeutralStrokeAccessible)"};
}
:host([appearance='outline'][color='informative']) {
color: ${wy};
border-color: ${_y};
}
:host([appearance='outline'][color='severe']) {
color: ${Ly};
}
:host([appearance='outline'][color='subtle']) {
color: ${"var(--colorNeutralForegroundStaticInverted)"};
}
:host([appearance='outline'][color='success']) {
color: ${"var(--colorPaletteGreenForeground2)"};
}
:host([appearance='outline'][color='warning']) {
color: ${By};
}
`}
${Te.partial`
:host([appearance='tint']) {
background-color: ${"var(--colorBrandBackground2)"};
color: ${"var(--colorBrandForeground2)"};
border-color: ${"var(--colorBrandStroke2)"};
}
:host([appearance='tint'][color='danger']) {
background-color: ${"var(--colorPaletteRedBackground1)"};
color: ${"var(--colorPaletteRedForeground1)"};
border-color: ${"var(--colorPaletteRedBorder1)"};
}
:host([appearance='tint'][color='important']) {
background-color: ${wy};
color: ${Ay};
border-color: ${Ny};
}
:host([appearance='tint'][color='informative']) {
background-color: ${"var(--colorNeutralBackground4)"};
color: ${wy};
border-color: ${_y};
}
:host([appearance='tint'][color='severe']) {
background-color: ${"var(--colorPaletteDarkOrangeBackground1)"};
color: ${"var(--colorPaletteDarkOrangeForeground1)"};
border-color: ${"var(--colorPaletteDarkOrangeBorder1)"};
}
:host([appearance='tint'][color='subtle']) {
background-color: ${Ay};
color: ${wy};
border-color: ${_y};
}
:host([appearance='tint'][color='success']) {
background-color: ${"var(--colorPaletteGreenBackground1)"};
color: ${"var(--colorPaletteGreenForeground1)"};
border-color: ${"var(--colorPaletteGreenBorder2)"};
}
:host([appearance='tint'][color='warning']) {
background-color: ${"var(--colorPaletteYellowBackground1)"};
color: ${By};
border-color: ${"var(--colorPaletteYellowBorder1)"};
}
`}
${Xy}
`,Qy=function(e={}){return Nt`
${my(e)}
<slot>${py(e.defaultContent)}</slot>
${fy(e)}
`}(),eC=yy.compose({name:`${cy.prefix}-badge`,template:Qy,styles:Jy}),tC=Nt`<svg
width="17"
height="17"
viewBox="0 0 17 17"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M4.49507 4.35792C3.39051 4.3552 2.49729 5.24843 2.50001 6.35298L2.51143 11.0029C2.51414 12.1075 3.41176 13.0051 4.51632 13.0078L11.1041 13.024C11.6296 13.0253 12.1334 12.8198 12.5067 12.4518L14.9019 10.0911C15.693 9.31139 15.6918 8.03262 14.8993 7.24663L12.5912 4.95769C12.2157 4.58531 11.7091 4.37564 11.1815 4.37434L4.49507 4.35792Z"
fill="${ke}"
/>
</svg> `,iC=Nt`<svg
width="17"
height="17"
viewBox="0 0 17 17"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M3 6.35175C2.99797 5.5243 3.66639 4.85588 4.49384 4.85791L11.1803 4.87434C11.576 4.87531 11.9568 5.03264 12.2392 5.31271L14.5472 7.60165C15.1438 8.19328 15.1421 9.15234 14.551 9.73497L12.1557 12.0957C11.8765 12.3709 11.4994 12.525 11.1054 12.524L4.51755 12.5078C3.68818 12.5058 3.01346 11.8311 3.01143 11.0017L3 6.35175Z"
stroke="${Pe}"
/>
</svg> `,nC=Nt`<svg
width="16"
height="16"
viewBox="0 0 16 16"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M9.97753 1.35238C9.42499 0.845867 8.57155 0.86441 8.04153 1.39444L1.42566 8.01051C0.878941 8.55725 0.878947 9.44367 1.42568 9.9904L2.35182 10.9165C2.69897 11.2637 3.19839 11.1801 3.49254 10.984C3.66674 10.8679 3.87564 10.8002 4.10156 10.8002C4.70908 10.8002 5.20156 11.2927 5.20156 11.9002C5.20156 12.1262 5.13388 12.3351 5.01778 12.5093C4.82172 12.8034 4.73812 13.3028 5.08526 13.65L5.98972 14.5544C6.5482 15.1129 7.45784 15.0991 7.99915 14.524L14.5983 7.51243C15.1331 6.94415 15.1001 6.04827 14.5248 5.52093L13.6384 4.70837C13.4195 4.50765 13.1424 4.46974 12.9119 4.51087C12.6849 4.55138 12.4696 4.67151 12.3143 4.84169C12.1126 5.06269 11.8235 5.20044 11.5016 5.20044C10.894 5.20044 10.4016 4.70795 10.4016 4.10044C10.4016 3.81258 10.5116 3.55132 10.6927 3.355C10.8489 3.18557 10.95 2.96074 10.9706 2.7311C10.9916 2.49787 10.9297 2.22527 10.7109 2.02465L9.97753 1.35238Z"
fill="${ke}"
/>
</svg>`,oC=Nt`<svg
width="16"
height="16"
viewBox="0 0 16 16"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M9.43694 1.94209C9.20014 1.72502 8.83437 1.73296 8.60722 1.96012L1.99135 8.57619C1.75705 8.8105 1.75705 9.1904 1.99136 9.42471L2.91725 10.3506C2.91691 10.3505 2.91743 10.3507 2.91725 10.3506C2.91959 10.3515 2.92772 10.354 2.9412 10.354C2.97076 10.354 3.0118 10.343 3.04884 10.3183C3.35036 10.1174 3.71289 10.0002 4.10156 10.0002C5.1509 10.0002 6.00156 10.8509 6.00156 11.9002C6.00156 12.2889 5.88443 12.6514 5.68346 12.953C5.65877 12.99 5.64785 13.031 5.64782 13.0606C5.6478 13.0741 5.65001 13.0814 5.6509 13.0838C5.65081 13.0836 5.65102 13.0841 5.6509 13.0838L6.55541 13.9888C6.79476 14.2281 7.1846 14.2222 7.41659 13.9757L14.0157 6.96414C14.2449 6.72059 14.2308 6.33664 13.9842 6.11064L13.098 5.29821C13.0975 5.29804 13.0967 5.29776 13.0954 5.29745C13.0898 5.29613 13.0756 5.29429 13.0524 5.29844C13.0017 5.30748 12.9439 5.33864 12.9052 5.38101C12.5583 5.76108 12.0576 6.00044 11.5016 6.00044C10.4522 6.00044 9.60156 5.14978 9.60156 4.10044C9.60156 3.60381 9.79263 3.15091 10.1045 2.81266C10.1433 2.77062 10.1693 2.71048 10.1739 2.65942C10.176 2.63603 10.1729 2.62216 10.1711 2.61676C10.1707 2.61548 10.1704 2.61467 10.1701 2.61423L9.43694 1.94209ZM8.04153 1.39444C8.57155 0.86441 9.42499 0.845867 9.97753 1.35238L10.7109 2.02465C10.9297 2.22527 10.9916 2.49787 10.9706 2.7311C10.95 2.96074 10.8489 3.18557 10.6927 3.355C10.5116 3.55132 10.4016 3.81258 10.4016 4.10044C10.4016 4.70795 10.894 5.20044 11.5016 5.20044C11.8235 5.20044 12.1126 5.06269 12.3143 4.84169C12.4696 4.67151 12.6849 4.55138 12.9119 4.51087C13.1424 4.46974 13.4195 4.50765 13.6384 4.70837L14.5248 5.52093C15.1001 6.04827 15.1331 6.94415 14.5983 7.51243L7.99915 14.524C7.45784 15.0991 6.5482 15.1129 5.98972 14.5544L5.08526 13.65C4.73812 13.3028 4.82172 12.8034 5.01778 12.5093C5.13388 12.3351 5.20156 12.1262 5.20156 11.9002C5.20156 11.2927 4.70908 10.8002 4.10156 10.8002C3.87564 10.8002 3.66674 10.8679 3.49254 10.984C3.19839 11.1801 2.69897 11.2637 2.35182 10.9165L1.42568 9.9904C0.878947 9.44367 0.878941 8.55725 1.42566 8.01051L8.04153 1.39444Z"
fill="${Pe}"
/>
</svg>`,rC=Nt`<svg
width="16"
height="16"
viewBox="0 0 16 16"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M2 3.75C2 2.7835 2.7835 2 3.75 2H9.25016C10.2167 2 11.0002 2.7835 11.0002 3.75V4H11.382C11.9501 4 12.4695 4.321 12.7236 4.82918L13.8416 7.06525C13.9458 7.27353 14 7.5032 14 7.73607V11C14 11.8284 13.3284 12.5 12.5 12.5H11.937C11.715 13.3626 10.9319 14 10 14C9.06808 14 8.28503 13.3626 8.06301 12.5H6.93699C6.71497 13.3626 5.93192 14 5 14C4.01321 14 3.19333 13.2853 3.02971 12.3454C2.4225 12.0708 2 11.4597 2 10.75V3.75ZM11.0002 5V7H12.691L11.8292 5.27639C11.7445 5.107 11.5714 5 11.382 5H11.0002ZM5 11C4.44772 11 4 11.4477 4 12C4 12.5523 4.44772 13 5 13C5.55228 13 6 12.5523 6 12C6 11.4477 5.55228 11 5 11ZM9 12C9 12.5523 9.44772 13 10 13C10.5523 13 11 12.5523 11 12C11 11.4477 10.5523 11 10 11C9.44772 11 9 11.4477 9 12Z"
fill="${ke}"
/>
</svg>`,aC=Nt`<svg
width="16"
height="16"
viewBox="0 0 16 16"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M2 3.75C2 2.7835 2.7835 2 3.75 2H9.25016C10.2167 2 11.0002 2.7835 11.0002 3.75V4H11.382C11.9501 4 12.4695 4.321 12.7236 4.82918L13.8416 7.06525C13.9458 7.27353 14 7.5032 14 7.73607V11C14 11.8284 13.3284 12.5 12.5 12.5H11.937C11.715 13.3626 10.9319 14 10 14C9.06808 14 8.28503 13.3626 8.06301 12.5H6.93699C6.71497 13.3626 5.93192 14 5 14C4.01321 14 3.19333 13.2853 3.02971 12.3454C2.4225 12.0708 2 11.4597 2 10.75V3.75ZM8.06301 11.5C8.28503 10.6374 9.06808 10 10 10C9.99995 10 10.0001 10 10 10L10.0002 3.75C10.0002 3.33579 9.66438 3 9.25016 3H3.75C3.33579 3 3 3.33579 3 3.75V10.75C3 10.9251 3.05997 11.0861 3.16049 11.2137C3.46594 10.5 4.17458 10 5 10C5.93192 10 6.71497 10.6374 6.93699 11.5H8.06301ZM11.0002 10.2677C11.4585 10.5328 11.8018 10.9746 11.937 11.5H12.5C12.7761 11.5 13 11.2761 13 11V8H11.0002V10.2677ZM11.0002 7H12.691L11.8292 5.27639C11.7445 5.107 11.5714 5 11.382 5H11.0002V7ZM5 11C4.44772 11 4 11.4477 4 12C4 12.5523 4.44772 13 5 13C5.55228 13 6 12.5523 6 12C6 11.4477 5.55228 11 5 11ZM9 12C9 12.5523 9.44772 13 10 13C10.5523 13 11 12.5523 11 12C11 11.4477 10.5523 11 10 11C9.44772 11 9 11.4477 9 12Z"
fill="${Pe}"
/>
</svg> `;class sC extends se{constructor(){super(...arguments),this.iconAppearance="outline"}getIcon(){switch(this.icon){case"cashback":return"filled"===this.iconAppearance?tC:iC;case"coupon":return"filled"===this.iconAppearance?nC:oC;case"shipping":return"filled"===this.iconAppearance?rC:aC}}}(0,o.gn)([Z],sC.prototype,"label",void 0),(0,o.gn)([Z],sC.prototype,"icon",void 0),(0,o.gn)([Z({attribute:"icon-appearance"})],sC.prototype,"iconAppearance",void 0);const lC=Te`
:host {
display: grid;
grid-auto-columns: max-content;
grid-gap: ${ze};
grid-auto-flow: column;
align-items: center;
margin-block: ${qe};
font-family: ${He};
}
.icon {
display: flex;
align-items: center;
width: 16px;
height: 16px;
}
.label {
color: ${Pe};
font-size: ${gc};
line-height: ${mc};
font-weight: ${fc};
}
`,cC=Nt`
<template>
<div class="icon">${e=>e.getIcon()}</div>
<div class="label">${e=>e.label}</div>
</template>
`;Nt`<commerceui-metadata-item
label=${e=>e.label}
icon=${e=>e.icon}
icon-appearance=${e=>e.iconAppearance}
></commerceui-metadata-item>`,sC.compose({name:`${n.prefix}-metadata-item`,template:cC,styles:lC}).define(n.registry),eC.name="fluent-beta-badge",eC.define(customElements);const dC=Nt`
<div id="retailer-item-container" class="container">
${Lt((e=>!e.hideLogo),Nt`${Lt((e=>e.imgUrl&&""!==e.imgUrl),Nt` <img class="logo" src=${e=>e.imgUrl} alt=${e=>e.imgAlt} />`,Nt` <div class="logo-fallback">${e=>e.name.substring(0,1)}</div>`)}`)}
<div class="name-container">
<p class="name">${e=>e.name}</p>
${Lt((e=>e.advertisement),Nt`<fluent-beta-badge shape="rounded" color="informative" size="small"
>Ad</fluent-beta-badge
>`)}
</div>
${Lt((e=>e.description),Nt`<p class="description" title=${e=>e.description}>${e=>e.description}</p>`)}
<div class="metadata-items">
${Vs((e=>e.metadata),Nt`${(e,t)=>{return Nt`<commerceui-metadata-item
label=${(i=e).label}
icon=${i.icon}
icon-appearance=${i.iconAppearance}
></commerceui-metadata-item>`;var i}}`)}
</div>
</div>
`;Nt`<commerceui-retailer-item
name=${e=>e.name}
img-url=${e=>e.imgUrl}
img-alt=${e=>e.imgAlt}
hide-logo=${e=>e.hideLogo}
description=${e=>e.description}
:metadata=${e=>e.metadata}
?advertisement=${e=>e.advertisement}
></commerceui-retailer-item>`,ay.compose({name:`${n.prefix}-retailer-item`,template:dC,styles:ly}).define(n.registry);const uC="submit";var hC=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};class pC extends se{constructor(){super(),this.disabledFocusable=!1,this.elementInternals=this.attachInternals(),this.iconOnly=!1,this.elementInternals.role="button"}disabledFocusableChanged(e,t){this.$fastController.isConnected&&(this.elementInternals.ariaDisabled=`${!!t}`)}get form(){return this.elementInternals.form}get labels(){return Object.freeze(Array.from(this.elementInternals.labels))}typeChanged(e,t){var i,n,o;t!==uC&&(null===(i=this.formSubmissionFallbackControl)||void 0===i||i.remove(),null===(o=null===(n=this.shadowRoot)||void 0===n?void 0:n.querySelector('slot[name="internal"]'))||void 0===o||o.remove())}clickHandler(e){if(!e||!this.disabledFocusable)return this.press(),!0;e.stopImmediatePropagation()}connectedCallback(){super.connectedCallback(),this.elementInternals.ariaDisabled=`${!!this.disabledFocusable}`}createAndInsertFormSubmissionFallbackControl(){var e,t,i,n,o,r,a,s;const l=null!==(e=this.formSubmissionFallbackControlSlot)&&void 0!==e?e:document.createElement("slot");l.setAttribute("name","internal"),null===(t=this.shadowRoot)||void 0===t||t.appendChild(l),this.formSubmissionFallbackControlSlot=l;const c=null!==(i=this.formSubmissionFallbackControl)&&void 0!==i?i:document.createElement("button");c.style.display="none",c.setAttribute("type","submit"),c.setAttribute("slot","internal"),this.formNoValidate&&c.toggleAttribute("formnovalidate",!0),(null===(n=this.elementInternals.form)||void 0===n?void 0:n.id)&&c.setAttribute("form",this.elementInternals.form.id),this.name&&c.setAttribute("name",this.name),this.value&&c.setAttribute("value",this.value),this.formAction&&c.setAttribute("formaction",null!==(o=this.formAction)&&void 0!==o?o:""),this.formEnctype&&c.setAttribute("formenctype",null!==(r=this.formEnctype)&&void 0!==r?r:""),this.formMethod&&c.setAttribute("formmethod",null!==(a=this.formMethod)&&void 0!==a?a:""),this.formTarget&&c.setAttribute("formtarget",null!==(s=this.formTarget)&&void 0!==s?s:""),this.append(c),this.formSubmissionFallbackControl=c}formDisabledCallback(e){this.disabled=e}keypressHandler(e){if(e&&this.disabledFocusable)e.stopImmediatePropagation();else{if(e.key!==zp.kL&&e.key!==zp.BI)return!0;this.press()}}press(){switch(this.type){case"reset":this.resetForm();break;case uC:this.submitForm()}}resetForm(){var e;null===(e=this.elementInternals.form)||void 0===e||e.reset()}submitForm(){var e;if(this.elementInternals.form&&!this.disabled&&this.type===uC)if(this.name||this.formAction||this.formEnctype||this.form||this.formMethod||this.formNoValidate||this.formTarget)try{this.elementInternals.setFormValue(null!==(e=this.value)&&void 0!==e?e:""),this.elementInternals.form.requestSubmit(this)}catch(e){this.createAndInsertFormSubmissionFallbackControl(),this.elementInternals.setFormValue(null),this.elementInternals.form.requestSubmit(this.formSubmissionFallbackControl)}else this.elementInternals.form.requestSubmit()}}pC.formAssociated=!0,hC([Z],pC.prototype,"appearance",void 0),hC([Z({mode:"boolean"})],pC.prototype,"autofocus",void 0),hC([x],pC.prototype,"defaultSlottedContent",void 0),hC([Z({mode:"boolean"})],pC.prototype,"disabled",void 0),hC([Z({attribute:"disabled-focusable",mode:"boolean"})],pC.prototype,"disabledFocusable",void 0),hC([Z({attribute:"formaction"})],pC.prototype,"formAction",void 0),hC([Z({attribute:"form"})],pC.prototype,"formAttribute",void 0),hC([Z({attribute:"formenctype"})],pC.prototype,"formEnctype",void 0),hC([Z({attribute:"formmethod"})],pC.prototype,"formMethod",void 0),hC([Z({attribute:"formnovalidate",mode:"boolean"})],pC.prototype,"formNoValidate",void 0),hC([Z({attribute:"formtarget"})],pC.prototype,"formTarget",void 0),hC([Z({attribute:"icon-only",mode:"boolean"})],pC.prototype,"iconOnly",void 0),hC([Z],pC.prototype,"name",void 0),hC([Z],pC.prototype,"shape",void 0),hC([Z],pC.prototype,"size",void 0),hC([Z],pC.prototype,"type",void 0),hC([Z],pC.prototype,"value",void 0),dy(pC,gy);class gC{constructor(e){this.listenerCache=new WeakMap,this.query=e}connectedCallback(e){const{query:t}=this;let i=this.listenerCache.get(e);i||(i=this.constructListener(e),this.listenerCache.set(e,i)),i.bind(t)(),t.addEventListener("change",i)}disconnectedCallback(e){const t=this.listenerCache.get(e);t&&this.query.removeEventListener("change",t)}}class fC extends gC{constructor(e,t){super(e),this.styles=t}static with(e){return t=>new fC(e,t)}constructListener(e){let t=!1;const i=this.styles;return function(){const{matches:n}=this;n&&!t?(e.addStyles(i),t=n):!n&&t&&(e.removeStyles(i),t=n)}}removedCallback(e){e.removeStyles(this.styles)}}const mC=fC.with(window.matchMedia("(forced-colors)")),vC=(fC.with(window.matchMedia("(prefers-color-scheme: dark)")),fC.with(window.matchMedia("(prefers-color-scheme: light)")),Te`
${Cy("inline-flex")}
:host {
--icon-spacing: ${qy};
contain: layout style;
vertical-align: middle;
align-items: center;
box-sizing: border-box;
justify-content: center;
text-align: center;
text-decoration-line: none;
margin: 0;
min-height: 32px;
outline-style: none;
background-color: ${Ay};
color: ${by};
border: ${zy} solid ${"var(--colorNeutralStroke1)"};
padding: 0 ${"var(--spacingHorizontalM)"};
min-width: 96px;
border-radius: ${Hy};
font-size: ${"var(--fontSizeBase300)"};
font-family: ${Zy};
font-weight: ${Gy};
line-height: ${"var(--lineHeightBase300)"};
transition-duration: ${"var(--durationFaster)"};
transition-property: background, border, color;
transition-timing-function: ${"var(--curveEasyEase)"};
cursor: pointer;
user-select: none;
}
.content {
display: inherit;
}
:host(:hover) {
background-color: ${"var(--colorNeutralBackground1Hover)"};
color: ${"var(--colorNeutralForeground1Hover)"};
border-color: ${"var(--colorNeutralStroke1Hover)"};
}
:host(:hover:active) {
background-color: ${"var(--colorNeutralBackground1Pressed)"};
border-color: ${"var(--colorNeutralStroke1Pressed)"};
color: ${"var(--colorNeutralForeground1Pressed)"};
outline-style: none;
}
:host(:focus-visible) {
border-color: ${Ny};
outline: ${"var(--strokeWidthThick)"}) solid ${Ny};
box-shadow: ${"var(--shadow4)"}, 0 0 0 2px ${Ry};
}
@media screen and (prefers-reduced-motion: reduce) {
transition-duration: 0.01ms;
}
::slotted(svg) {
font-size: 20px;
height: 20px;
width: 20px;
fill: currentColor;
}
[slot='start'],
::slotted([slot='start']) {
margin-inline-end: var(--icon-spacing);
}
[slot='end'],
::slotted([slot='end']) {
margin-inline-start: var(--icon-spacing);
}
:host([icon-only]) {
min-width: 32px;
max-width: 32px;
}
:host([size='small']) {
--icon-spacing: ${Ky};
min-height: 24px;
min-width: 64px;
padding: 0 ${"var(--spacingHorizontalS)"};
border-radius: ${Uy};
font-size: ${Vy};
line-height: ${jy};
font-weight: ${"var(--fontWeightRegular)"};
}
:host([size='small'][icon-only]) {
min-width: 24px;
max-width: 24px;
}
:host([size='large']) {
min-height: 40px;
border-radius: ${"var(--borderRadiusLarge)"};
padding: 0 ${"var(--spacingHorizontalL)"};
font-size: ${"var(--fontSizeBase400)"};
line-height: ${"var(--lineHeightBase400)"};
}
:host([size='large'][icon-only]) {
min-width: 40px;
max-width: 40px;
}
:host([size='large']) ::slotted(svg) {
font-size: 24px;
height: 24px;
width: 24px;
}
:host([shape='circular']),
:host([shape='circular']:focus-visible) {
border-radius: ${$y};
}
:host([shape='square']),
:host([shape='square']:focus-visible) {
border-radius: ${Fy};
}
:host([appearance='primary']) {
background-color: ${Dy};
color: ${Oy};
border-color: transparent;
}
:host([appearance='primary']:hover) {
background-color: ${"var(--colorBrandBackgroundHover)"};
}
:host([appearance='primary']:hover),
:host([appearance='primary']:hover:active) {
border-color: transparent;
color: ${Oy};
}
:host([appearance='primary']:hover:active) {
background-color: ${"var(--colorBrandBackgroundPressed)"};
}
:host([appearance='primary']:focus-visible) {
border-color: ${Oy};
box-shadow: ${"var(--shadow2)"}, 0 0 0 2px ${Ry};
}
:host(is:([disabled][appearance='primary'], [disabled-focusabale][appearance="primary"])),
:host(is:([disabled][appearance='primary'], [disabled-focusabale][appearance="primary"]):hover),
:host(is:([disabled][appearance='primary'], [disabled-focusabale][appearance="primary"]):hover:active) {
border-color: transparent;
}
:host([appearance='outline']) {
background-color: ${Ey};
}
:host([appearance='outline']:hover) {
background-color: ${ky};
}
:host([appearance='outline']:hover:active) {
background-color: ${Iy};
}
:host(is:([disabled][appearance='outline'], [disabled-focusabale][appearance="outline"])),
:host(is:([disabled][appearance='outline'], [disabled-focusabale][appearance="outline"]):hover),
:host(is:([disabled][appearance='outline'], [disabled-focusabale][appearance="outline"]):hover:active) {
background-color: ${Ey};
}
:host([appearance='subtle']) {
background-color: ${"var(--colorSubtleBackground)"};
color: ${Sy};
border-color: transparent;
}
:host([appearance='subtle']:hover) {
background-color: ${"var(--colorSubtleBackgroundHover)"};
color: ${"var(--colorNeutralForeground2Hover)"};
border-color: transparent;
}
:host([appearance='subtle']:hover:active) {
background-color: ${"var(--colorSubtleBackgroundPressed)"};
color: ${"var(--colorNeutralForeground2Pressed)"};
border-color: transparent;
}
:host(is:([disabled][appearance='subtle'], [disabled-focusabale][appearance="subtle"])),
:host(is:([disabled][appearance='subtle'], [disabled-focusabale][appearance="subtle"]):hover),
:host(is:([disabled][appearance='subtle'], [disabled-focusabale][appearance="subtle"]):hover:active) {
background-color: ${Ey};
border-color: transparent;
}
:host([appearance='subtle']:hover) ::slotted(svg) {
fill: ${xy};
}
:host([appearance='subtle']:hover:active) ::slotted(svg) {
fill: ${Ty};
}
:host([appearance='transparent']) {
background-color: ${Ey};
color: ${Sy};
}
:host([appearance='transparent']:hover) {
background-color: ${ky};
color: ${xy};
}
:host([appearance='transparent']:hover:active) {
background-color: ${Iy};
color: ${Ty};
}
:host([appearance='transparent']),
:host([appearance='transparent']:hover),
:host([appearance='transparent']:hover:active) {
border-color: transparent;
}
:host(is:([disabled][appearance='transparent'], [disabled-focusabale][appearance="transparent"])),
:host(is:([disabled][appearance='transparent'], [disabled-focusabale][appearance="transparent"]):hover),
:host(is:([disabled][appearance='transparent'], [disabled-focusabale][appearance="transparent"]):hover:active) {
border-color: transparent;
background-color: ${Ey};
}
:host(:is([disabled], [disabled-focusable], [appearance][disabled], [appearance][disabled-focusable])),
:host(:is([disabled], [disabled-focusable], [appearance][disabled], [appearance][disabled-focusable]):hover),
:host(:is([disabled], [disabled-focusable], [appearance][disabled], [appearance][disabled-focusable]):hover:active) {
background-color: ${"var(--colorNeutralBackgroundDisabled)"};
border-color: ${"var(--colorNeutralStrokeDisabled)"};
color: ${"var(--colorNeutralForegroundDisabled)"};
cursor: not-allowed;
}
`.withBehaviors(mC(Te`
:host([appearance='transparent']:hover) {
border-color: Highlight;
}
`)));class yC extends ht{get id(){return this._id}set id(e){this._id=e,this._controllerProperty=`${e}-c`}bind(e){const t=e.targets[this.targetNodeId];t[this._controllerProperty]=e,this.updateTarget(e.source,this.computeNodes(t)),this.observe(t),e.onUnbind(this)}unbind(e){const t=e.targets[this.targetNodeId];this.updateTarget(e.source,f),this.disconnect(t),t[this._controllerProperty]=null}getSource(e){return e[this._controllerProperty].source}updateTarget(e,t){e[this.options.property]=t}computeNodes(e){let t=this.getNodes(e);return"filter"in this.options&&(t=t.filter(this.options.filter)),t}}const CC="slotchange";class bC extends yC{observe(e){e.addEventListener(CC,this)}disconnect(e){e.removeEventListener(CC,this)}getNodes(e){return e.assignedNodes(this.options)}handleEvent(e){const t=e.currentTarget;this.updateTarget(this.getSource(t),this.computeNodes(t))}}ut.define(bC);const SC=function(e={}){return Nt`
<template
tabindex="${e=>e.disabled?-1:0}"
@click="${(e,t)=>e.clickHandler(t.event)}"
@keypress="${(e,t)=>e.keypressHandler(t.event)}"
>
${my(e)}
<span class="content" part="content">
<slot ${t="defaultSlottedContent",c(t)&&(t={property:t}),new bC(t)}></slot>
</span>
${fy(e)}
</template>
`;var t}(),xC=pC.compose({name:`${cy.prefix}-button`,template:SC,styles:vC});xC.name="fluent-beta-button",xC.define(customElements);Nt`<commerceui-buying-options-retailer-list
locale=${e=>e.locale}
currency=${e=>e.currency}
layout=${e=>e.layout}
hide-retailers-logo=${e=>e.hideRetailersLogo}
no-data-label=${e=>e.noDataLabel}
lowest-price-label=${e=>e.lowestPriceLabel}
cta-button-label=${e=>e.ctaButtonLabel}
discount-price-label=${e=>e.discountPriceLabel}
appearance=${e=>e.appearance}
:data=${e=>e.data}
:onretailerhover=${e=>e.onretailerhover}
:onretailerclick=${e=>e.onretailerclick}
:onretailerctaclick=${e=>e.onretailerctaclick}
>${e=>e.content}</commerceui-buying-options-retailer-list
>`;const TC=Nt`<div class="container">
${Lt((e=>e.getData.retailers.length>0),Nt`<ul class="retailer-list appearance-${e=>e.appearance}">
${Vs((e=>e.getData.retailers),Nt`
<li
class="retailer-list-item"
@mouseenter="${(e,t)=>t.parent.mouseEventHandler(t.index,t.event)}"
>
<a
href=${(e,t)=>{var i;return null===(i=t.parent.getRetailerData(t.index).item)||void 0===i?void 0:i.url}}
target=${(e,t)=>{var i;return null===(i=t.parent.getRetailerData(t.index).item)||void 0===i?void 0:i.target}}
title=${(e,t)=>{var i;return null===(i=t.parent.getRetailerData(t.index).item)||void 0===i?void 0:i.title}}
aria-label=${(e,t)=>{var i,n;return null===(n=null===(i=t.parent.getRetailerData(t.index).item)||void 0===i?void 0:i.aria)||void 0===n?void 0:n.label}}
aria-description=${(e,t)=>{var i;return null===(i=t.parent.getRetailerData(t.index).item.aria)||void 0===i?void 0:i.description}}
@click="${(e,t)=>t.parent.clickEventHandler(t.index,t.event)}"
>
${Lt(((e,t)=>t.parent.getRetailerData(t.index).item),((e,t)=>{const i=t.parent.getData.retailers[t.index].item;return Nt`<commerceui-retailer-item
name=${i.name}
img-url=${i.imgUrl}
img-alt=${i.imgAlt}
hide-logo=${t.parent.hideRetailersLogo}
description=${i.description}
?advertisement=${i.advertisement}
:metadata=${i.metadata}
></commerceui-retailer-item>`}))}
${Lt(((e,t)=>t.parent.getRetailerData(t.index).price),((e,t)=>{const i=t.parent.getData.retailers[t.index].price,n=i.oldPrice>i.currentPrice;return Nt`
<div class="price">
<commerceui-price
locale=${t.parent.locale}
currency=${t.parent.currency}
size="medium"
color="${n?Mg:"neutral"}"
show-raised-cents
show-zero-cents
value="${i.currentPrice}"
></commerceui-price>
${Lt(i.isLowestPrice,Nt`<commerceui-badge color="success" appearance="tint"
>${t.parent.lowestPriceLabel}</commerceui-badge
>`)}
${Lt(i.oldPrice,Nt`<commerceui-price
locale=${t.parent.locale}
currency=${t.parent.currency}
size="xx-small"
color="${"subtle"}"
strikethrough
value="${i.oldPrice}"
></commerceui-price>`)}
${Lt(i.discountPrice,Nt`<div class="save-label">
${t.parent.discountPriceLabel}
<commerceui-price
locale=${t.parent.locale}
currency=${t.parent.currency}
size="xx-small"
color="${Mg}"
value="${i.discountPrice}"
></commerceui-price>
</div>`)}
${Lt(i.installmentsPrice,Nt`<commerceui-price
locale=${t.parent.locale}
currency=${t.parent.currency}
size="xx-small"
value=${i.installmentsPrice}
per-item-label=${i.installmentsPerItemLabel}
></commerceui-price>`)}
</div>
`}))}
${Lt(((e,t)=>"regular"===t.parent.layout&&t.parent.getRetailerData(t.index).ctaButton),((e,t)=>{var i,n;const o=t.parent.getData.retailers[t.index].ctaButton;return Nt`<div class="cta-button">
<fluent-beta-button
size="small"
appearance="${o.appearance}"
disabled="${null==o?void 0:o.disabled}"
aria-label="${null===(i=null==o?void 0:o.aria)||void 0===i?void 0:i.label}"
aria-description="${null===(n=null==o?void 0:o.aria)||void 0===n?void 0:n.description}"
title="${null==o?void 0:o.title}"
@click="${(e,t)=>t.parent.clickCtaEventHandler(t.index,t.event)}"
>${t.parent.ctaButtonLabel}</fluent-beta-button
>
</div>`}))}
</a>
</li>
`,{positioning:!0})}
</ul>`,Nt`<div class="no-data-label">${e=>e.noDataLabel}</div>`)}
</div>`;Ng.compose({name:`${n.prefix}-buying-options-retailer-list`,template:TC,styles:Rg}).define(n.registry),xC.name="fluent-beta-button",xC.define(customElements);const wC=Nt` <commerceui-buying-options-base>
${Lt((e=>e.getFiltersData.length>0),Nt`<div slot="filter-group">
<slot name="filter-group">
<commerceui-buying-options-filter-group
direction=${e=>e.filterGroupDirection}
inline-swatches=${e=>e.filterGroupInlineSwatches}
auto-hide-overflow-swatches=${e=>e.autoHideOverflowSwatches}
:data=${e=>e.getData.filterGroup}
@onfiltergroupselectionchange=${(e,t)=>e.filterGroupEventHandler(t.event)}
></commerceui-buying-options-filter-group
></slot>
</div>`)}
<div slot="retailer-list">
<slot name="retailer-list">
<commerceui-buying-options-retailer-list
locale=${e=>e.locale}
currency=${e=>e.currency}
:data=${e=>e.getRetailersListData}
hide-retailers-logo=${e=>e.hideRetailersLogo}
layout=${e=>e.layout}
no-data-label=${e=>e.retailersListNoDataLabel}
lowest-price-label=${e=>e.retailersListLowestPriceLabel}
cta-button-label=${e=>e.retailersListCTAButtonLabel}
discount-price-label=${e=>e.retailersListDiscountPriceLabel}
appearance=${e=>e.appearance}
handle-navigation=${e=>e.handleNavigation}
@retailerclick=${(e,t)=>e.clickRetailerEventHandler(t.event)}
@retailerctaclick=${(e,t)=>e.clickCtaEventHandler(t.event)}
@retailerhover=${(e,t)=>e.mouseRetailerEventHandler(t.event)}
></commerceui-buying-options-retailer-list>
</slot>
</div>
${Lt((e=>e.getShowMoreRetailers),Nt`<div slot="show-more-retailers">
<slot name="show-more-retailers">
<fluent-beta-button
shape="rounded"
appearance="transparent"
size="medium"
icon
@click="${(e,t)=>e.clickShowMoreRetailersEventHandler(t.event)}"
>
<svg
width="16"
height="16"
viewBox="0 0 16 16"
fill="currentColor"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M3.14645 5.64645C3.34171 5.45118 3.65829 5.45118 3.85355 5.64645L8 9.79289L12.1464 5.64645C12.3417 5.45118 12.6583 5.45118 12.8536 5.64645C13.0488 5.84171 13.0488 6.15829 12.8536 6.35355L8.35355 10.8536C8.15829 11.0488 7.84171 11.0488 7.64645 10.8536L3.14645 6.35355C2.95118 6.15829 2.95118 5.84171 3.14645 5.64645Z"
fill="currentColor"
/>
</svg>
${e=>e.showMoreRetailersLabel}
</fluent-beta-button>
</slot>
</div>`)}
</commerceui-buying-options-base>`;Nt` <commerceui-buying-options
locale=${e=>e.locale}
currency=${e=>e.currency}
title=${e=>e.title}
layout=${e=>e.layout}
appearance=${e=>e.appearance}
show-max-retailers=${e=>e.showMaxRetailers}
show-more-retailers-label=${e=>e.showMoreRetailersLabel}
hide-show-more-retailers=${e=>e.hideShowMoreRetailers}
hide-retailers-logo=${e=>e.hideRetailersLogo}
auto-hide-overflow-swatches=${e=>e.autoHideOverflowSwatches}
filter-group-direction=${e=>e.filterGroupDirection}
filter-group-inline-swatches=${e=>e.filterGroupInlineSwatches}
filter-group-sorted=${e=>e.filterGroupSorted}
retailers-list-no-data-label=${e=>e.retailersListNoDataLabel}
retailers-list-lowest-price-label=${e=>e.retailersListLowestPriceLabel}
retailers-list-cta-button-label=${e=>e.retailersListCTAButtonLabel}
retailers-list-discount-price-label=${e=>e.retailersListDiscountPriceLabel}
handle-navigation=${e=>e.handleNavigation}
:data=${e=>e.data}
:onfiltergroupselectionchange=${e=>e.onfiltergroupselectionchange}
:onretailerclick=${e=>e.onretailerclick}
:onretailerhover=${e=>e.onretailerhover}
:onretailerctaclick=${e=>e.onretailerctaclick}
:onshowmoreretailersclick=${e=>e.onshowmoreretailersclick}
>${e=>e.content}</commerceui-buying-options
>`,ue.compose({name:`${n.prefix}-buying-options`,template:wC,styles:Qe}).define(n.registry)},69698:function(e,t,i){"use strict";i.d(t,{BI:function(){return l},Op:function(){return d},rE:function(){return c}});var n=i(72370),o=i(11127);let r=o.DesignToken.create("cb-background-colour").withDefault("#FFFFFF"),a=o.DesignToken.create("cb-font").withDefault("#000000"),s=o.DesignToken.create("cb-background").withDefault("#FEFEFE"),l=o.DesignToken.create("cb-price-tag").withDefault("#0078D4"),c=o.DesignToken.create("linkColor").withDefault("#235CCF");class d{setCashbackUIService(e){this.cashbackUIService=e}constructor(e){(0,n.Z)(this,"cashbackUIService",void 0),this.cashbackUIService=e}initializeTokens(){this.cashbackUIService.isDarkMode()&&(c.setValueFor(document.documentElement,"#63ADE5"),l.setValueFor(document.documentElement,"#0078D4"),r.setValueFor(document.documentElement,"#FFFFFF"),a.setValueFor(document.documentElement,"#FFFFFF"),s.setValueFor(document.documentElement,"#3B3B3B"))}async init(){}}},49259:function(e,t,i){"use strict";i.d(t,{Z:function(){return M}});var n=i(72370),o=i(71544),r=i(81687),a=i(12265),s=i(87605),l=i(84901),c=i(29247),d=i(75434),u=i(55590),h=i(31656),p=i(4872),g=i(5144),f=i(56764),m=class{constructor(){(0,n.Z)(this,"cashbackState",void 0),(0,n.Z)(this,"cashbackType",void 0),(0,n.Z)(this,"domain",void 0),(0,n.Z)(this,"cashbackProductTitle",void 0),(0,n.Z)(this,"cashbackAmount",void 0),(0,n.Z)(this,"productPrice",void 0),(0,n.Z)(this,"imageUrl",void 0),(0,n.Z)(this,"productBingUrl",void 0),(0,n.Z)(this,"productRetailerUrl",void 0),(0,n.Z)(this,"description",void 0),(0,n.Z)(this,"isBlossom",!1),(0,n.Z)(this,"is3xIncentive",!1),(0,n.Z)(this,"shouldAutoshow",void 0),(0,n.Z)(this,"expireTimeEpoch",void 0),(0,n.Z)(this,"globalOfferId",void 0),(0,n.Z)(this,"minPurchaseValue",void 0),(0,n.Z)(this,"visibilityFeedbackUrl",void 0),(0,n.Z)(this,"cashbackCategories",[])}},v=class{constructor(e,t){(0,n.Z)(this,"price",void 0),(0,n.Z)(this,"currency",void 0),this.price=e,this.currency=t}},y=i(3634);let C=function(e){return e.EligibleUser="EligibleUser",e.OfferClaimed="OfferClaimed",e.PayoutCompleted="PayoutCompleted",e.FailedToFetch="FailedToFetch",e.NotEligibleUser="NotEligibleUser",e}({});var b=i(88767),S=i(59645),x=i(28060),T=i(42544),w=i(15255),O=i(4238),P=i(11501),A=class{constructor(e,t,i,o){(0,n.Z)(this,"apiResponse",void 0),(0,n.Z)(this,"sessionIds",void 0),(0,n.Z)(this,"anid",""),(0,n.Z)(this,"esf",""),(0,n.Z)(this,"settings",void 0),this.apiResponse=e,this.sessionIds=t,this.esf=o||"",this.anid=i||"",this.settings=new P.Z(e?.retailerData?.settings)}isPane(){throw new Error("Method not implemented.")}getCheckoutPageInfo(){}getPageType(){return g.GV.UnknownPage}getRetailerSettings(){return this.settings}getPersonalizedCashback(){return this.apiResponse?.personalizedAdsResponse?.personalizedCashback}isEdgeRebateUser(){return this.apiResponse?.cashback?.isRebatesUser??!1}isAadSignedIn(){return this.apiResponse?.userInfo?.isAADSignedIn??null}getSanConsentFlag(){return(0,c.Nx)(this.apiResponse?.userInfo?.isPersonalizationDataConsentEnabled)}getHtmlCollectionRate(){return this.apiResponse?.retailerData?.aOCFragmentCollectionRate?`${this.apiResponse?.retailerData?.aOCFragmentCollectionRate}`:"0"}getCurrentMarket(){const e=this.apiResponse?.market,t=this.apiResponse?.aFDMarket;return(0,c.UE)(e)?e:(0,c.UE)(t)?t:void 0}getExtractionRate(){try{if(this.apiResponse?.retailerData?.aOCFragmentCollectionRate)return parseFloat(this.apiResponse?.retailerData?.aOCFragmentCollectionRate)}catch(e){return-1}return-1}isFragmentCollectionEnabled(){return(0,c.Nx)(this.apiResponse?.retailerData?.isAOCFragmentCollectionEnabled)}getCheckoutPages(){}isCartCachingEnabled(){return this.getConfirmationPageTelemetryData()?.isCartCachingEnabled??!0}getPlatform(){return this.apiResponse?.retailerData?.platform??""}getConfirmationPageRegex(){return this.apiResponse?.retailerData?.orderConfirmationPageUrl}getMarket(){return this.apiResponse?.market??""}getAfdMarket(){return this.apiResponse?.aFDMarket??""}getConfirmationPageTelemetryData(){return this.apiResponse?.retailerData?.confirmationPageTelemetry}getCurrentDomain(){return this.apiResponse?.retailerData?.domainName??""}getImpressionId(){return this.apiResponse?.impressionId??""}getRetailerData(){return this.apiResponse?.retailerData}getAutomatedSelectorsData(){return this.apiResponse?.retailerData?.allAutomatedSelectors??[]}getAutomatedSelectorsDataForPage(e){}getFeatureFlagEnabledByDefault(e){return"feature_disabled"!==this.apiResponse?.retailerData?.edgeFeatureFlag?.[e]}getFeatureFlag(e){return"feature_enabled"===this.apiResponse?.retailerData?.edgeFeatureFlag?.[e]}getDataMaskRules(){const e=this.apiResponse?.retailerData?.dataMaskRules,t=[];if(e&&e.length>0)for(const i of e)if(i?.ruleName&&i?.ruleValue&&i?.maskType){const e=new O.Z(i?.ruleName,i?.maskType,i?.ruleValue);t.push(e)}return t}};class E{constructor(e,t){(0,n.Z)(this,"cashbackItems",void 0),(0,n.Z)(this,"requestedForSearchUrl",void 0),this.cashbackItems=e,this.requestedForSearchUrl=t}}class k extends A{constructor(e,t,i,o){const r=k.parseApiWithErrorCatch(e);super(r),(0,n.Z)(this,"dataLoader",void 0),(0,n.Z)(this,"storageHandler",void 0),(0,n.Z)(this,"loggerService",void 0),(0,n.Z)(this,"apiResponse",void 0),(0,n.Z)(this,"highestCashbackCategoryData",void 0),(0,n.Z)(this,"pageHandler",void 0),(0,n.Z)(this,"cachedIsBingAdRefered",!1),this.pageHandler=t,this.dataLoader=e,this.storageHandler=i,this.loggerService=o,this.apiResponse=r}isPane(){return this.dataLoader.GetLoadTimeDataValue("is_hub",!1)}async GetBlossomUserStatus(e){if(!(0,c.UE)(e))return Promise.resolve(C.FailedToFetch);const t=await this.storageHandler.getStorageString(u.Q.BlossomCampaignUserStatus),i=Number(await this.storageHandler.getStorageString(u.Q.BlossomCampaignUserStatusTimestamp));if(t&&!isNaN(i)&&(new Date).getTime()-i<3e5)return Promise.resolve(C[t]);{const t={headers:{"Content-Type":"application/json",Origin:"chrome-untrusted://shopping"},method:"GET"},i=`https://www.bing.com/api/shopping/v1/grocery/campaigns/projectBlossom022024/status?anid=${e}`;try{const e=await fetch(i,t),n=await e.json();if(200===e.status){const e=n?.userStatus??"";return this.storageHandler.setStorageString(u.Q.BlossomCampaignUserStatus,e),this.storageHandler.setStorageString(u.Q.BlossomCampaignUserStatusTimestamp,(new Date).getTime().toString()),e}return Promise.resolve(C.FailedToFetch)}catch(e){return Promise.resolve(C.FailedToFetch)}}}getSessionIds(){}getESF(){return""}isSignedIn(){return Boolean(this.isAadSignedIn())}async getAnid(){try{return await(0,d.H)(this.pageHandler)}catch(e){return}}SaveBlossomStatus(e){this.storageHandler.setStorageString(u.Q.BlossomCampaignUserStatus,e),this.storageHandler.setStorageString(u.Q.BlossomCampaignUserStatusTimestamp,(new Date).getTime().toString())}async GetShouldShowBlossomFlag(){const e=await this.storageHandler.getStorageString(u.Q.BlossomShouldShowNotification);return(0,c.Nx)(e)}ResetBlossomNotificationFlag(){this.storageHandler.clearStorage(u.Q.BlossomShouldShowNotification)}saveToLocalCache(e,t){throw new Error("Method not implemented.")}readFromLocalCache(e){throw new Error("Method not implemented.")}saveToLocalCachePersistent(e,t){throw new Error("Method not implemented.")}readFromLocalCachePersistent(e){throw new Error("Method not implemented.")}getLastCommittedURL(){return this.dataLoader.GetLoadTimeDataValue("lastCommittedURL","")}static parseApiWithErrorCatch(e){try{const t=e.GetLoadTimeDataValue(w.a.CouponsApiResponse,void 0);return JSON.parse(t)}catch(e){return}}getCurrency(){return"$"}getDataMaskRules(){return super.getDataMaskRules()}getSpbPdpOffer(){const e=this.dataLoader.GetLoadTimeDataValue("comparableOffers",void 0)||void 0,t=new m,i=(e?.value||[]).find((e=>e.position===b.zE.SPB_OFFERS)),n=i?.offer.itemOffered;if(n?.image?.contentUrl&&i?.promotionInformation?.rebateValue&&i?.offer?.price&&i?.offer?.priceCurrency&&e?.visibilityFeedbackUrl)return t.imageUrl=n.image?.contentUrl,t.cashbackProductTitle=n.name,t.productPrice=new v(i.offer.price,i?.offer?.priceCurrency),t.cashbackAmount=new v(i.offer.price,i?.offer?.priceCurrency),t.productBingUrl=i?.offer?.url,t.visibilityFeedbackUrl=e?.visibilityFeedbackUrl,t.cashbackAmount=new v(i.promotionInformation.rebateValue,i.offer.priceCurrencySymbol),t}async getSearchSpbOffers(){const e=await this.storageHandler.getStorageString(u.Q.ICCurrentPageInfo),t=[];if(!e||void 0===e)return new E([],void 0);try{const i=JSON.parse(e),n=i.cashbackData;if(n&&n.itemizedCashBackResponse&&n.itemizedCashBackResponse.offers&&n.itemizedCashBackResponse.offers.length>0){const e=n.itemizedCashBackResponse.offers,i=n.itemizedCashBackResponse.adsMetadata?.visibilityFeedbackUrl;if(!i)return this.loggerService.LogError("No visibility feedback url"),new E([],void 0);e.forEach((e=>{if(e.adsOffer.name&&e.adsOffer.price&&e.adsOffer.promotionInformation?.rebateValue){const n=new m,o=e.adsOffer.impressionToken;n.productBingUrl=e.adsOffer.url,n.shouldAutoshow=e.shouldAutoshow,n.imageUrl=e.imageUrl,n.cashbackProductTitle=e.adsOffer.name,n.description=e.description,n.productPrice=new v(e.adsOffer.price,"$"),n.cashbackAmount=new v(e.adsOffer.promotionInformation.rebateValue,"$"),n.visibilityFeedbackUrl=`${i}&tids=${o}`,t.push(n)}else this.loggerService.LogError("Failed to parse spb data",{spbCashback:e})}))}return new E(t,i.currentUrl)}catch(e){return new E([],void 0)}}async getCurrentSpbSearchQuery(){const e=await this.storageHandler.getStorageString(u.Q.ICCurrentPageInfo);try{const t=JSON.parse(e);if("search"===t.type||"searchSPB"===t.type)return(0,c.UE)(t?.query)?Promise.resolve(t?.query):Promise.resolve(void 0)}catch(e){return this.loggerService.LogError("failed to parse page info"),Promise.resolve(void 0)}}getCashbackTransactions(){const e=this.apiResponse?.cashback?.userTransactionsResponse;return e}highestCashbackCategory(){const e=this.apiResponse?.cashback?.highestCashbackCategory;if(!e){const e=this.storewideCategories();return e?e[0]:void 0}if(this.highestCashbackCategoryData)return this.highestCashbackCategoryData;try{const t=e;return t.commissionType&&t.commissionValue&&t.category?(this.highestCashbackCategoryData=t,this.highestCashbackCategoryData):void this.loggerService.LogError("Category data is corrupted",this.apiResponse)}catch(e){return void this.loggerService.LogError("Unable to parse highest category data",this.apiResponse)}}storewideCategories(){if(!this.apiResponse?.cashback?.categories)return;if(0===this.apiResponse.cashback.categories.length)return;const e=[];for(const t of this.apiResponse.cashback.categories)e.push(new T.Z(t));return e.length>0?(e.sort(((e,t)=>e.commissionValue>t.commissionValue?-1:1)),e):void 0}getRecentActivatedOffer(){if(this.apiResponse?.personalizedAdsResponse?.personalizedCashback?.ldData&&""!==this.apiResponse?.personalizedAdsResponse?.personalizedCashback?.ldData){const e=this.getActivatedOffers();if(e.length>0)return e[0]}}getActivatedOffers(){if(!this.apiResponse?.personalizedAdsResponse?.personalizedCashback?.adsCashback)return[];const e=this.apiResponse.personalizedAdsResponse,t={commissionType:e.personalizedCashback?.commissionType,commissionValue:e.personalizedCashback?.commissionValue,imageUrl:e.personalizedCashback?.imageUrl,isAdClick:e.personalizedCashback?.isAdClick,offerId:e.personalizedCashback?.offerId,productUrl:e.personalizedCashback?.productUrl,rGuid:e.personalizedCashback?.rGuid,scope:e.personalizedCashback?.scope,destinationUrl:e.personalizedCashback?.destinationUrl,adsCashback:e.personalizedCashback?.adsCashback};if(t&&t.adsCashback.length>0){const e=[];return t.adsCashback.forEach((t=>{const i=this.convertToItemCashbacData(t);e.push(i)})),e}return[]}isStorewideCashBackActivated(){return this.dataLoader.GetLoadTimeDataValue("rebatesActive",!1)}isEdgeRebateUser(){const e=this.dataLoader.GetLoadTimeDataValue("is_edge_profile_rebates_user",!1),t=this.apiResponse?.cashback?.userRebateResponse?.isRebatesUser;return e||(0,c.Nx)(t)}isAadSignedIn(){return(0,c.Nx)(this.apiResponse?.userInfo?.isAADSignedIn)}isConfirmationPage(){return this.dataLoader.GetLoadTimeDataValue("isConfirmationPage",!1)}isCashBackTurnedOff(){return this.dataLoader.GetLoadTimeDataValue("rebatesDeactivating",!1)}aadEmail(){return this.dataLoader.GetLoadTimeDataValue("aadEmail",void 0)}isAADLinkedAccountValid(){return this.dataLoader.GetLoadTimeDataValue("isAADLinkedAccountValid",!1)}isLinkingPolicyEnabled(){return this.dataLoader.GetLoadTimeDataValue("isLinkingPolicyEnabled",!1)}shouldSuppressRebatesScenarios(){return this.dataLoader.GetLoadTimeDataValue("suppress_rebates_scenarios",!1)}getActivateRebateStatus(){const e=this.dataLoader.GetLoadTimeDataValue("activateRebatesStatus",null);let t=b.FA.NOT_ACTIVATING;return null!=e&&(t=b.FA[b.FA[e]]),t}isSPBActivated(){return(0,c.Nx)(this.apiResponse?.itemLevelCashBack?.isSpbActivated)}setShouldExpandDetails(e){this.storageHandler.setStorageBool(u.Q.ShouldOpenOfferDetails,Boolean(e))}async getShouldExpandDetails(){return Boolean(this.storageHandler.getStorageBool(u.Q.ShouldOpenOfferDetails))}convertToItemCashbacData(e){const t=new m;return t.productBingUrl=e.productUrl,t.productRetailerUrl=e.destinationUrl,t.imageUrl=e.imageUrl,t.domain=e.domain,"Storewide"===e.scope?t.cashbackType=a.hB.PCBStorewide:(t.cashbackProductTitle=e.scope,t.cashbackType=a.hB.SPBorPPCashback),t.minPurchaseValue=e.minPurchaseValue,t.cashbackAmount=new v(Number.parseFloat(e.commissionValue),e.adsCurrencySymbol),t.expireTimeEpoch=e.expireTimeEpoch,t.productPrice=void 0,t.description=void 0,t.visibilityFeedbackUrl=void 0,t}}var I=k;class D{constructor(e,t){(0,n.Z)(this,"currentUrlMasked",void 0),(0,n.Z)(this,"cashbackDAO",void 0),(0,n.Z)(this,"personalDataRemover",void 0),(0,n.Z)(this,"currentPageType",g.GV.UnknownPage),this.cashbackDAO=e,this.personalDataRemover=t,this.currentUrlMasked=this.getCurrentUrlValue(!0),this.currentPageType=this.cashbackDAO.getPageType()}getDomainMarket(){return this.cashbackDAO.getCurrentMarket()}async getAnid(){return await this.cashbackDAO.getAnid()}sanConsentEnabled(){return this.cashbackDAO.getSanConsentFlag()}getCurrentDomain(){return this.cashbackDAO.getCurrentDomain()}getCurrentPageType(){return this.currentPageType}getMuid(){return"muid"}getCurrentUserType(){const e=this.cashbackDAO.isLinkingPolicyEnabled(),t=this.cashbackDAO.isAadSignedIn(),i=this.cashbackDAO.isAADLinkedAccountValid(),n=this.cashbackDAO.isEdgeRebateUser();return t&&e?i?a.qx.LinkedAAD:a.qx.LinkableAAD:n?a.qx.Rebate:a.qx.NonRebateUser}async getSearchQuery(){return await this.cashbackDAO.getCurrentSpbSearchQuery()}getCurrentUrl(){return this.currentUrlMasked}getCurrentUrlValue(e){const t=this.cashbackDAO.getLastCommittedURL();if(!e)return t;return this.personalDataRemover.deleteSecretsInURL(t)||""}}var _=i(12727),N=i(69698);class R{constructor(e,t,i){(0,n.Z)(this,"logModule",void 0),(0,n.Z)(this,"flyoutData",void 0),(0,n.Z)(this,"pageHandlerModule",void 0),(0,n.Z)(this,"stateManagement",void 0),(0,n.Z)(this,"storageHandler",void 0),(0,n.Z)(this,"utilities",void 0),(0,n.Z)(this,"cashbackContext",void 0),(0,n.Z)(this,"cashbackAvailableScenarioService",void 0),(0,n.Z)(this,"cashbackDAO",void 0),(0,n.Z)(this,"personalDataRemover",void 0),(0,n.Z)(this,"cashbackUIService",void 0),(0,n.Z)(this,"cashbackFastInitializer",void 0),this.logModule=i.logModule,this.pageHandlerModule=i.pageHandlerModule,this.stateManagement=e,this.flyoutData=t,this.utilities=i,this.storageHandler=i.storageHandler,this.stateManagement.addEventListener(r.e1.StyleProcessingState,(e=>{}))}getActivationService(){return new class{constructor(e,t,i,o,r){(0,n.Z)(this,"pageHandlerModule",void 0),(0,n.Z)(this,"storageHandler",void 0),(0,n.Z)(this,"localizedStringsData",void 0),(0,n.Z)(this,"loggerService",void 0),(0,n.Z)(this,"cashbackContext",void 0),(0,n.Z)(this,"stateManagement",void 0),this.pageHandlerModule=e,this.storageHandler=t,this.localizedStringsData=i,this.loggerService=o,this.cashbackContext=r,this.stateManagement=M.getFactory().getStateManagementModule()}listenForCashbackStateChange(e,t){new Map([[r.e1.rebatesNotActivating,a.VS.NonActivated],[r.e1.rebatesSignInPendingSuccess,a.VS.Activating],[r.e1.onRebatesTelemetrySuccess,a.VS.Activated],[r.e1.rebatesSignInFail,a.VS.Failed],[r.e1.rebatesFetchUserInfoFail,a.VS.FetchUserInfoFailed]]).forEach(((i,n)=>{this.stateManagement.addEventListener(n,(()=>{e.cashbackState=i,t()}))}))}getActivateCashbackLocalizedText(e){let t;const i=this.cashbackContext.getCurrentUserType();if(e.cashbackState===a.VS.Activated?t=i===a.qx.LinkableAAD?this.localizedStringsData.pcbLinkMsaActivateButton:e.cashbackType===a.hB.Storewide?this.localizedStringsData.cbActivatedButton:e.cashbackType===a.hB.PCBStorewide?i===a.qx.NonRebateUser?this.localizedStringsData.gcbSigninToClaim:this.localizedStringsData.cbActivatedButton:this.localizedStringsData.cbCashbackButtonActivated:e.cashbackState===a.VS.Activating&&o.Z.IsMobile()?t=this.localizedStringsData.cbProcessing:e.cashbackState===a.VS.Failed&&o.Z.IsMobile()||e.cashbackState===a.VS.FetchUserInfoFailed&&o.Z.IsMobile()?t=this.localizedStringsData.cbFailedRetry:e.cashbackState===a.VS.NonActivated&&(i===a.qx.LinkableAAD?t=this.localizedStringsData.pcbLinkMsaActivateButton:i===a.qx.NonRebateUser?t=e.cashbackType===a.hB.PCBStorewide?this.localizedStringsData.gcbSigninToClaim:this.localizedStringsData.cbBingActivateButton:i!==a.qx.Rebate&&i!==a.qx.LinkedAAD||(e.cashbackType===a.hB.SPBSearchCashback||e.cashbackType===a.hB.SPBPDPCashback?t=h.R.isExperimentActive(p.H.spbShortNotification)||h.R.isExperimentActive(p.H.spbPDPShortDesign)?this.localizedStringsData.cbActivateButton:this.localizedStringsData.gcOkButtonText:e.cashbackType===a.hB.Storewide&&(t=this.localizedStringsData.gcOkButtonText))),!t)throw this.loggerService.LogError("Message for activate button not found",e),new Error("Failed to localize a text for activate button");return t}activateCashback(e,t,i){const n=this.cashbackContext.getCurrentUserType(),r=this.getActivateCashbackLocalizedText(t).replace(" ","").toLowerCase();if(n===a.qx.NonRebateUser)this.pageHandlerModule.RecordAsUserAction(s.bS.ACTIVATE_CASHBACK_NEW),this.pageHandlerModule.RecordAsUserEngagement(l.FV.ACTIVATE_CASHBACK_NEW,i),this.pageHandlerModule.ActivateRebates(!0);else if(n===a.qx.LinkableAAD)this.linkUser();else if(t.cashbackState===a.VS.FetchUserInfoFailed&&o.Z.IsMobile())this.pageHandlerModule.RetryFetchUserInfo(!0);else if(t.cashbackType===a.hB.Storewide)this.activateStorewideCashback(t,i);else if(t.cashbackType===a.hB.PCBStorewide);else if(t.cashbackType===a.hB.SPBPDPCashback||t.cashbackType===a.hB.SPBSearchCashback){this.activateOffer(t,i,!0);const e=new Date;t.expireTimeEpoch=e.getTime()+864e5,t.cashbackState=a.VS.Activated}let c="";t?.isBlossom&&(c+="bloossom;"),t?.is3xIncentive&&(c+="3xIncentive;");const d=this.cashbackContext.getCurrentPageType(),u=this.cashbackContext.getCurrentUrl(),h=i?g.xu.UnifiedCashBackNotificationBtnClick:g.xu.UnifiedCashBackShorelineBtnClick,p={viewName:e,buttonName:r,cashBack:t,userType:n,additionalInfo:c,pageType:d,pageUrl:u,popupOrigination:i};this.loggerService.Log("Cashback button clicked",h,f.g.CouponImpressionId,p)}navigateToOffer(e){e.cashbackType!==a.hB.Storewide&&e.productBingUrl&&this.pageHandlerModule.NavigateToUrl(e.productBingUrl)}linkUser(){return this.pageHandlerModule.NavigateToUrl("https://www.msn.com/en-us/feed/personalize/settings?pc=edge"),Promise.resolve()}activateAndAddToCart(e,t){const i=!!t;this.storageHandler.setStorageBool(u.Q.GroceryInstantAddToCartSpb,i),this.pageHandlerModule.RecordAsUserEngagement(l.FV.ACTIVATE_CLICK_SPB_CASHBACK,t),this.activateOffer(e,t,!1)}activateOffer(e,t,i){e.productBingUrl&&(i?(this.pageHandlerModule.RecordAsUserEngagement(l.FV.ACTIVATE_CLICK_SPB_CASHBACK,t),this.pageHandlerModule.NavigateToUrl(e.productBingUrl)):this.makeBackgroundActivation(e,t))}async activateStorewideCashback(e,t){const i=this.cashbackContext.getCurrentUserType();i===a.qx.Rebate||i===a.qx.LinkedAAD?(this.pageHandlerModule.RecordAsUserAction(s.bS.ACTIVATE_CASHBACK),this.pageHandlerModule.RecordAsUserEngagement(l.FV.ACTIVATE_CASHBACK,t),o.Z.IsMobile()||(e.cashbackState=a.VS.Activated),await this.pageHandlerModule.ActivateRebates(!0)):e.cashbackType===a.hB.StorewideCashbackPinterest&&(this.pageHandlerModule.RecordAsUserAction(s.bS.PINTEREST_CASHBACK_ACTIVATED),this.pageHandlerModule.RecordAsUserEngagement(l.FV.PINTEREST_CASHBACK_ACTIVATED,t),o.Z.IsMobile()||(e.cashbackState=a.VS.Activated),await this.pageHandlerModule.ActivateRebates(!0))}sendVisibilityFeedbackUrl(e){e&&e.visibilityFeedbackUrl&&(0,c.UE)(e.visibilityFeedbackUrl)?this.pageHandlerModule.SendVisibilityFeedbBackUrl(e.visibilityFeedbackUrl):this.loggerService.LogError("Absent visibility feedback url",e)}makeBackgroundActivation(e,t){if(!e.productBingUrl)return;const i=this.pageHandlerModule.NavigateToUrlBackgroundWithResult(e.productBingUrl,e.productBingUrl,!0),n=this;i.then((async i=>{const o=i.result,r=(0,d.rm)(o);if(r){if(!e.productBingUrl)return;const i=this.getValueFromUrl(r.destinationUrl,"msclkid"),o=this.getValueFromUrl(e.productBingUrl,"ld");n.pageHandlerModule.RefreshDealsResponse(o,i,!1),n.pageHandlerModule.UpdateLoadTimeData(),n.pageHandlerModule.RecordAsUserEngagement(l.FV.ACTIVATE_CLICK_SPB_CASHBACK,t)}})).catch((e=>{}))}getValueFromUrl(e,t){const i=e.split("?");if(i.length<=1)return"";const n=[];i.forEach((e=>{const t=e.split("&");n.push(...t)}));for(const e of n){const i=e.split("=");if(2===i.length&&i[0]===t)return i[1]}return""}}(this.pageHandlerModule,this.storageHandler,this.flyoutData.strings,this.getCashbackLogger(),this.getCasbackContext())}getCashbackFastInitializer(){return this.cashbackFastInitializer||(this.cashbackFastInitializer=new N.Op(this.getCashbackUIService())),this.cashbackFastInitializer}getPersonalDataRemover(){return this.personalDataRemover||(this.personalDataRemover=new _.Z(this.getCashbackDAO())),this.personalDataRemover}getCashbackUIService(){return this.cashbackUIService||(this.cashbackUIService=new class{constructor(e,t,i){(0,n.Z)(this,"utilities",void 0),(0,n.Z)(this,"flyoutData",void 0),(0,n.Z)(this,"loggerService",void 0),this.utilities=e,this.flyoutData=t,this.loggerService=i}applyStylesToShoppingSection(e){this.utilities.applyStyles(this.flyoutData.common.shopping,e,x.E.ICNotification)}isDarkMode(){return this.utilities.isDarkMode()}async createNotificationFromModule(e){return e&&e.element?(e.element.style.marginTop="0px",e.element.slot="header-content",e.element.accordion=!1,e.element.hideTitle=!0,this.flyoutData.common.shopping.classList.add("noSections"),this.utilities.applyStyles(this.flyoutData.common.shopping,"::part(header) {\n margin-top: 0px;\n margin-bottom: 0px;\n }"),e):null}getRetailerImageUrl(){const e=this.utilities.getFavIconSrc(this.flyoutData.common.domain);if(!e||""===e){const e={domain:this.flyoutData.common.domain};this.loggerService.LogError("Icon not found",e)}return e}getCashbackImageUrl(e){return e?.imageUrl&&""!==e.imageUrl&&null!==e.imageUrl?e.imageUrl.startsWith("edge://image?")?e.imageUrl.replace("edge://image?","").replace("edge://image?",""):e.imageUrl.indexOf("localhost")>-1||e.imageUrl.indexOf("bing")>-1?e.imageUrl:"https://www.bing.com/"+e.imageUrl:(this.loggerService.LogError("No image found",e),"")}getExpireSoon(e){const t=e-(new Date).getTime();let i="0h 00m";if(t>0){const e=t/1e3/60,n=e/60,o=Math.floor(n/24),r=o>0?` ${o} days `:"",a=Math.floor(n-24*o),s=Math.floor(e-24*o*60-60*a);return i=`${r} ${a>0?a:0}h ${s>0?s:"00"}m`,i}return this.loggerService.LogError("Unable to calc expire time "),"Expires soon"}getMerchantFullName(){return this.flyoutData.dataStoreModule.CashBackData?.merchantFullName?this.flyoutData.dataStoreModule.CashBackData?.merchantFullName:this.flyoutData.common.domain}getPopupOrigination(){return this.flyoutData.common.popupOrigination}getFlyoutData(){return this.flyoutData}}(this.utilities.viewModulesUtilities,this.flyoutData,this.getCashbackLogger())),this.cashbackUIService}getLocalizedStringsData(){return this.flyoutData.strings}getStateManagementModule(){return this.stateManagement}getCashbackDAO(){return this.cashbackDAO||(this.cashbackDAO=new I(this.flyoutData.dataLoader,this.pageHandlerModule,this.storageHandler,this.getCashbackLogger())),this.cashbackDAO}getCasbackContext(){return this.cashbackContext||(this.cashbackContext=new D(this.getCashbackDAO(),this.getPersonalDataRemover())),this.cashbackContext}getCashbackAvailableScenarious(){return this.cashbackAvailableScenarioService||(this.cashbackAvailableScenarioService=new class{constructor(e,t,i,o){(0,n.Z)(this,"validBlossomStatus",new Set([C.OfferClaimed,C.EligibleUser,C.PayoutCompleted])),(0,n.Z)(this,"cashback",void 0),(0,n.Z)(this,"cashbackActivated",!1),(0,n.Z)(this,"loggerService",void 0),(0,n.Z)(this,"cashbackDAO",void 0),(0,n.Z)(this,"cashbackContext",void 0),(0,n.Z)(this,"pageHandler",void 0),(0,n.Z)(this,"popupOrigination",void 0),(0,n.Z)(this,"viewName",void 0),this.loggerService=e,this.cashbackDAO=t,this.cashbackContext=i,this.pageHandler=o,this.popupOrigination=this.pageHandler.PopupOrigination}closeIfNotification(e){if(!this.cashbackDAO.isPane()&&e>0){const t=this.pageHandler;setTimeout((()=>{t.DismissPopup()}),e)}}triggerExperiment(e){this.pageHandler.TriggerExperiment(e)}openPane(e,t,i){this.LogButtonClick(e,t,void 0,"button was clicked"),this.cashbackDAO.setShouldExpandDetails(i),this.pageHandler.OpenPane(this.popupOrigination)}async getShouldExpandDetails(){const e=await this.cashbackDAO.getShouldExpandDetails();return this.cashbackDAO.setShouldExpandDetails(!1),Boolean(e)}is3xIncentiveCashback(){if(!this.cashbackDAO.getFeatureFlag("3xIncentiveCashback"))return!1;if("en-us"===this.cashbackDAO.getCurrentMarket()){const e=this.cashbackDAO.storewideCategories();if(e)for(let t=0;t<e.length;t++){const i=e[t];if(i.category?.toLowerCase().includes(y.eS))return!0}}return!1}async isBlossomScenario(e){if(!h.R.isExperimentActive(p.H.blossomCampaign))return!1;if(!this.cashbackDAO.getFeatureFlag("blossomFeature"))return!1;if(this.cashbackContext.getCurrentPageType()!==g.GV.ConfirmationPage)return!1;if(e){const e=await this.cashbackContext.getAnid();if(!e)return!1;const t=await this.cashbackDAO.GetBlossomUserStatus(e);if(t&&this.validBlossomStatus.has(t))return!0}else{const e=await this.cashbackDAO.GetShouldShowBlossomFlag();if(this.loggerService.Log(`getBlossomNotificationString: Blossom string requested. Should show: ${e}.`,g.xu.RebatesConfirmationBlossomNotification,f.g.CouponImpressionId),e)return this.cashbackDAO.ResetBlossomNotificationFlag(),!0}return!1}getSPBPDPOffer(){const e=this.cashbackDAO.getSpbPdpOffer();return e&&(e.cashbackType=a.hB.SPBPDPCashback,e.cashbackState=a.VS.NonActivated),e}navigateToMicrosoftRewards(){this.pageHandler.NavigateToMicrosoftRewards()}navigateToTermsStatementFlyout(){this.pageHandler.NavigateToTermsStatementFlyout()}navigateToPrivacyCookiesStatement(){this.pageHandler.NavigateToPrivacyCookiesStatement()}navigateToRebateHistory(){this.pageHandler.NavigateToUrl("https://www.bing.com/rebates/history")}calcDiscount(e){if(e?.productPrice&&e?.cashbackAmount)return`${(100-100*(e.productPrice.price-e.cashbackAmount.price)/e.productPrice.price).toFixed(0)}%`}getCashbackPriceAfterDiscount(e){if(e.productPrice&&e.cashbackAmount)return`${(e.productPrice.price-e.cashbackAmount.price).toFixed(2)}`}LogUserShownModule(e,t){const i=this.cashbackContext.getCurrentUserType();"confirmationPage"===e?this.loggerService.Log("User saw confirmation notification, new UX",g.xu.RebatesConfirmationNotification,f.g.CouponImpressionId):"PCBconfirmationPage"===e&&this.loggerService.Log("User saw confirmation notification, new UX",g.xu.PersonalizedCashbackConfirmationNotification,f.g.CouponImpressionId);let n="";t?.isBlossom&&(n+="bloossom;"),t?.is3xIncentive&&(n+="3xIncentive;");const o=this.cashbackContext.getCurrentPageType(),r=this.cashbackContext.getCurrentUrl(),a=this.cashbackDAO.isPane()?g.xu.UnifiedCashBackShorelineModule:g.xu.UnifiedCashBackNotificationModule,s={viewName:e,buttonName:"none",cashback:t,userType:i,additionalInfo:n,pageType:o,pageUrl:r,popupOrigination:this.pageHandler.PopupOrigination};this.loggerService.Log("Cashback was shown",a,f.g.CouponImpressionId,s)}async getPersonalizedOfferHero(){const e=this.cashbackDAO.getRecentActivatedOffer();if(e){const t=this.cashbackContext.getCurrentUserType();t===a.qx.LinkableAAD||t===a.qx.NonRebateUser||t===a.qx.NotEnrollledUser?e.cashbackState=a.VS.NonActivated:e.cashbackState=a.VS.Activated}return e}showPrivacyText(){const e=this.cashbackContext.getCurrentUserType();return e===a.qx.NotEnrollledUser||e===a.qx.LinkableAAD||e===a.qx.NonRebateUser}experimentalFlight(){return!1}async anyCashbackScenarioAvailable(){if(this.cashbackDAO.shouldSuppressRebatesScenarios())return!1;const e=await this.spbSearchScenarioAvailable(),t=this.cashbackDAO.getActivatedOffers(),i=this.storewideOfferAvailable()||t&&t.length>0||e;return this.loggerService.LogDebugInfo(`Any scenario avaiable ${i}`),i}storewideOfferAvailable(){return void 0!==this.cashbackDAO.highestCashbackCategory()}getStoreWideOffer(){if(!this.cashbackDAO.getFeatureFlagEnabledByDefault("edge.affiliateoffer.module"))return;const e=new m,t=this.cashbackDAO.highestCashbackCategory(),i=this.cashbackDAO.storewideCategories(),n=this.cashbackDAO.isStorewideCashBackActivated(),o=this.cashbackDAO.getActivateRebateStatus();return i&&t?(e.cashbackType=a.hB.Storewide,n||o===b.FA.ACTIVATED||o===b.FA.PENDING_ACTIVATION_IN_PROFILE?e.cashbackState=a.VS.Activated:e.cashbackState=a.VS.NonActivated,t&&(e.cashbackCategories=i,e.cashbackAmount=new v(t.commissionValue,t.commissionType)),e):void 0}async getSpbSearchHeroForOffer(){if(await this.spbSearchScenarioAvailable()){const e=await this.getSearchSpbOffersForCurrentPage();for(let t of e){if(void 0===t.shouldAutoshow||null===t.shouldAutoshow)return t;if((0,c.Nx)(t.shouldAutoshow))return t}}}getAllActivatedOffers(){const e=this.cashbackDAO.getActivatedOffers();return e.forEach((e=>{e.cashbackState=a.VS.Activated})),e}async getSearchSpbOffersForCurrentPage(){const e=this.cashbackContext.getCurrentUrl(),t=await this.cashbackDAO.getSearchSpbOffers();return t.requestedForSearchUrl!==e?(this.loggerService.LogDebugInfo(`spb search not shown due to diffrent url ${t.requestedForSearchUrl} and ${e}`),Promise.resolve([])):(t.cashbackItems.forEach((e=>{e.cashbackState=a.VS.NonActivated,e.cashbackType=a.hB.SPBSearchCashback})),t.cashbackItems)}getCashbackTransactions(){return this.cashbackDAO.getCashbackTransactions()}async spbSearchScenarioAvailable(){const e=await this.getSearchSpbOffersForCurrentPage();return!!(e&&e.length>0)}LogButtonClick(e,t,i,n=""){const o=this.cashbackContext.getCurrentUserType(),r=this.cashbackDAO.isPane()?g.xu.UnifiedCashBackShorelineBtnClick:g.xu.UnifiedCashBackNotificationBtnClick,a={viewName:e,buttonName:t,cashback:i,userType:o,pageUrl:this.cashbackContext.getCurrentUrl()};this.loggerService.Log(n,r,f.g.CouponImpressionId,a)}}(this.getCashbackLogger(),this.getCashbackDAO(),this.getCasbackContext(),this.pageHandlerModule)),this.cashbackAvailableScenarioService}getCashbackLogger(){return new class{constructor(e){(0,n.Z)(this,"logModule",void 0),this.logModule=e}Log(e,t,i,n){const o=new S.Z(t);o.Metadata=JSON.stringify(n),this.logModule.LogInfoEvent(g.R.EdgeFlyoutStatus,e,o,i)}LogDebugInfo(e,t){const i=new S.Z(g.xu.UnifiedCashBackDebugLog);i.Metadata=JSON.stringify(t),this.logModule.LogInfoEvent(g.R.EdgeFlyoutStatus,e,i)}LogError(e,t){const i=new S.Z(g.xu.UnifiedCashBackDebugLog);i.Metadata=JSON.stringify({user:void 0,componentData:t}),this.logModule.LogErrorEvent(g.R.EdgeFlyoutStatus,e,i)}LogInfo(e,t){throw new Error("Method not implemented.")}LogInfoWithEvenType(e,t,i){throw new Error("Method not implemented.")}}(this.logModule)}static didBaseURLChange(e,t){return e!==t&&(!e||!t||new URL(e).origin!==new URL(t).origin)}static initFactory(e,t,i){const n=this.instance?.cashbackContext?.getCurrentUrl(),o=t.dataStoreModule.CashBackData?.lastCommittedURL,r=this.didBaseURLChange(n,o);return this.instance&&!r||(this.instance=new R(e,t,i)),this.instance}static getFactory(){return this.instance}static resetFactory(e){this.instance&&(this.instance.flyoutData=e,this.instance.cashbackDAO=void 0,this.instance.cashbackAvailableScenarioService=void 0,this.instance.cashbackUIService=void 0,this.instance.cashbackUIService=void 0)}}(0,n.Z)(R,"instance",void 0);var M=R},42544:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(e){(0,n.Z)(this,"category",void 0),(0,n.Z)(this,"commissionType",void 0),(0,n.Z)(this,"commissionValue",void 0),(0,n.Z)(this,"priority",void 0),this.category=e?.category,this.commissionType=e?.commissionType,this.commissionValue=e?.commissionValue,this.priority=e?.priority}}},8553:function(e,t,i){"use strict";i.d(t,{JZ:function(){return T},Jm:function(){return x}});var n=i(72370),o=i(4872),r=i(31656),a=i(93209),s=i(59645),l=i(11232),c=i(40843),d=i(65358),u=i(5144),h=i(88767),p=i(55590),g=i(36493),f=i(33491),m=i(91495),v=i(91897),y=i(27689),C=i(81687);function b(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function S(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?b(Object(i),!0).forEach((function(t){(0,n.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):b(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}const x="edge_shopping_product_tracking_back_in_stock_notification",T="edge_shopping_product_tracking_price_drop_notification",w=["ja-jp","de-de","en-gb","en-ca","en-in","fr-fr","it-it","es-es","es-mx"];class O{static showedOOSNotifcationRecently(){try{const e=9e5;return Date.now()-+new Date(m.Q.ProductTrackingOOSLastShown)<e}catch(e){return!1}}static getDomainFromUrl(e){if(!e)return"";e=e.startsWith("http")?e:`https://${e}`;try{const t=new URL(e).hostname.split("."),i=t.length<3?t[0]:t[1];return`${i[0].toUpperCase()}${i.substring(1)}`}catch(t){return e}}static GetStrippedTitle(e,t){const i=new RegExp(`[\\s\\W]*${t}[\\s\\W]*`,"gi");return e?.replace(i,"")}static GetStrippedUrl(e){const t=O.getDomainFromUrl(e)?.toLocaleLowerCase();return"amazon"===t?e.replace(/\/ref=[A-z0-9_]+/,""):e}static isSameUrl(e,t){return(e=O.GetStrippedUrl(e))===O.GetStrippedUrl(t)}static isSameUrlByPathName(e,t){if(O.isSameUrl(e,t))return!0;try{const i=new URL(O.GetStrippedUrl(e.toLowerCase())),n=new URL(O.GetStrippedUrl(t.toLowerCase()));return i.origin===n.origin&&i.pathname===n.pathname}catch(e){return!1}}static IsSameProduct(e,t){if(!e||!t)return!1;if(e&&(e?.ProductId??e?.productId)===(t?.ProductId??t?.productId))try{const i=new URL(e.ProductUrl??e.productUrl);return new URL(t.ProductUrl??t.productUrl).hostname===i.hostname}catch{}return!1}static async IsTrackedProductForAOC(e){const t=O.getUrlAndProductToMap(m.Q.UrlToProductMap)?.[e];let i=[];const n=(0,y.Ad)(m.Q.TrackedProductsData??"{}");if(i=n?.trackedProducts??[],t)return i?.find((e=>O.IsSameProduct(e,t)));if(i){let t=!0;for(const n of i){if(O.isSameUrl(n.ProductUrl,e))return n;O.isSameUrlByPathName(n.ProductUrl,e)&&(t=!1)}if(t)return}try{const e=await fetch("https://www.bing.com/api/shopping/v1/savings/product-tracking/is-tracked",{headers:{Source:"ProductTracking",Service:"Extension/UX"}}).then((e=>e.json()));return e?.product??void 0}catch{}}static ProductWithPriceDropAndNoNotification(e){if(e?.length)return e.find((e=>e&&!e.notificationEnabled&&e.basePrice&&e.CurrentPrice&&e.CurrentPrice<e.basePrice&&!this.productExpired(e)))}static productExpired(e){const t=new Date,i=new Date(e.expirationDate??"");return"Invalid Date"===i.toString()||(e.expirationDate?.endsWith("Z")||i.setMinutes(i.getMinutes()-t.getTimezoneOffset()),+i<+t)}static getUrlAndProductToMap(e){if(!e)return{};let t={};return t=(0,y.Ad)(e),t||(t={}),t}constructor(e,t,i){this.flyoutData=t,this.stateManagement=i,(0,n.Z)(this,"pageHandlerModule",void 0),(0,n.Z)(this,"logModule",void 0),(0,n.Z)(this,"telemetryUtilities",void 0),(0,n.Z)(this,"utilities",void 0),(0,n.Z)(this,"storageHandler",void 0),(0,n.Z)(this,"anid",void 0),(0,n.Z)(this,"dealsEndpoint","https://www.bing.com/api/shopping/v1/savings"),(0,n.Z)(this,"trackedProductsCachePeriod",12e5),(0,n.Z)(this,"anidTrackingDataCachePeriod",864e5),(0,n.Z)(this,"userConsented",void 0),this.pageHandlerModule=e.pageHandlerModule,this.logModule=e.logModule,this.utilities=e.viewModulesUtilities,this.storageHandler=e.storageHandler,this.telemetryUtilities=e.telemetryHandler}AnidTrackingAvailable(){const e=this.flyoutData.dataLoader.GetLoadTimeDataValue("aadEmail",void 0);return r.R.isExperimentActive(o.H.PTEmail)&&!e}async shouldRenderProductCollections(e){let t=!1;const i=r.R.isExperimentActive(o.H.productTracking),n=this.flyoutData.common.market?.toLowerCase()??"",a="en-us"===n||!n,s=await this.GetLocalProductTrackingData(),l=e?.toLocaleLowerCase().includes("amazon."),c=l&&w.includes(n);return s&&s?.trackedProducts?.length>0&&(t=!0),Promise.resolve((i||a||c||t)&&this.flyoutData.common.isPane)}async hasUserConsented(){if(!this.AnidTrackingAvailable())return!1;if(void 0!==this.userConsented)return this.userConsented;const e=await this.storageHandler.getStorageString(p.Q.ProductTrackingConsentStatus),t=(0,y.Ad)(e)??"";let i="";if(this.pageHandlerModule.IsMessageAllowed("getEdgeAnid")&&(i=(await this.pageHandlerModule.GetEdgeAnid(!0))?.anid,!i))return!1;if(t&&t.IsAnidTrackingConsented)return!0;const n=await this.GetAnidProductTrackingData(i),o=n?.trackingPreferences?.IsAnidTrackingConsented,r=await this.GetLocalProductTrackingData();n?.trackingPreferences&&this.storageHandler.setStorageString(p.Q.ProductTrackingConsentStatus,JSON.stringify({IsAnidTrackingConsented:!!o,timestamp:Date.now()}));const a=o||void 0===o&&0===r?.trackedProducts?.length;return this.userConsented=a}async anidLoggedInHasTrackedProductsButNotExplicitlyConsented(){if(!this.AnidTrackingAvailable())return!1;const e=(await this.pageHandlerModule.GetEdgeAnid(!0))?.anid,t=await this.GetAnidProductTrackingData(e),i=t?.trackingPreferences?.IsAnidTrackingConsented,n=await this.GetLocalProductTrackingData();return e&&!i&&n?.trackedProducts?.length}setConsentLastShown(e){e&&this.storageHandler.setStorageString(p.Q.ProductCollectionBannerLastShown,JSON.stringify({timestamp:Date.now(),banner:e}))}async shownBannerRecently(e){const t=await this.storageHandler.getStorageString(p.Q.ProductCollectionBannerLastShown),i=(0,y.Ad)(t);return i?.banner===e&&Date.now()-i.timestamp<2*v.nQ}static isSupportedDomainForPrice(e,t,i){const n=t?.isUnsupportedDomain;if(!0===n)return!1;i=i?.toLowerCase();const a=r.R.isExperimentActive(o.H.productTracking),s="en-us"===i||!i,l=e?.toLocaleLowerCase().includes("amazon."),c=l&&w.includes(i);return a||s||c}static isSupportedDomainAOC(e,t,i){return this.isSupportedDomainForPrice(e,t,i)}async GetAnidProductTrackingData(e){if(!e)return null;const t=await this.storageHandler.getStorageString(p.Q.ProductTrackingAnidData);if(t){const e=(0,y.Ad)(t);if(e?.timestamp&&!this.isStaleAnidTrackingData(e))return e}return this.GetAnidProductTrackingDataFromEndpoint(e)}async GetAnidProductTrackingDataFromEndpoint(e){e=e??await this.getAnid();const t=await this.createRequest(`tracked-products?anid=${e}`,void 0,"GET"),i=new c.Z(t?.productTrackingData);return i.timestamp=Date.now().toString(),this.storageHandler.setStorageString(p.Q.ProductTrackingAnidData,JSON.stringify(i)),i}async TrackProduct(e,t,i,n){const o=await this.createTrackProductBody(e,this.flyoutData.common,t,i,n);if(!o){const o=new s.Z(u.xu.ProductTrackingDebug);return o.Metadata=JSON.stringify({product:e,isOutOfStock:t,duration:i,priceDrop:n}),this.logModule.LogErrorEvent(u.R.EdgeFlyoutStatus,"Failed to track product. Invalid product data",o),null}try{const t=await this.createRequest("track",o);if(await this.GetLocalProductTrackingDataFromEndpoint(),!t?.success)throw new Error(t.errorCode||t.errorMessage);return t.product&&this.addProductToUrlProductsMap(e.ProductUrl,t.product),new d.ZP(t.product)}catch(t){const i=new s.Z(u.xu.ProductTrackingNetworkError);i.Metadata=JSON.stringify({product:e,err:t,productRequest:o}),this.logModule.LogErrorEvent(u.R.EdgeFlyoutStatus,`Track product request failed: ${t}`,i)}return null}async TrackProductLocal(e){if(!e)return[];let t=await this.GetLocalProductTrackingData();if(t&&Array.isArray(t.trackedProducts)){const i=t.trackedProducts.findIndex((t=>O.IsSameProduct(t,e)));-1===i?t.trackedProducts.push(e):t.trackedProducts[i]=e}else t={trackedProducts:[e]};return t.timestamp=(new Date).toString(),this.storageHandler.setStorageString(p.Q.ProductTrackingTrackedProducts,JSON.stringify(t)),t.trackedProducts}async UntrackProduct(e){const t=await this.createUntrackProductBody(e,this.flyoutData.common);try{const i=await this.createRequest("untrack",t);if(this.GetLocalProductTrackingDataFromEndpoint(),!i.success)throw new Error(i.errorCode||i.errorMessage);return await this.removeProductFromUrlProductsMap(e.ProductUrl),i.success}catch(i){const n=new s.Z(u.xu.ProductTrackingNetworkError);n.Metadata=JSON.stringify({product:e,productRequest:t,err:i}),this.logModule.LogErrorEvent(u.R.EdgeFlyoutStatus,`Untrack product request failed: ${i}`,n)}return!1}async UntrackProductLocal(e){if(!e)return[];const t=await this.GetLocalProductTrackingData();return t?(t.trackedProducts=(t?.trackedProducts||[]).filter((t=>!O.IsSameProduct(t,e))),t.timestamp=(new Date).toString(),this.removeProductFromUrlProductsMap(e.ProductUrl),this.storageHandler.setStorageString(p.Q.ProductTrackingTrackedProducts,JSON.stringify(t)),t.trackedProducts):[]}async SetAbandondedCartPreferences(e){const t={Muid:this.flyoutData.common.muid,Anid:await this.getAnid(),Preferences:{AbandonedCartTrackingEnabled:e}};try{const e=await this.createRequest("set-user-preferences",t);if(this.GetLocalProductTrackingDataFromEndpoint(),!e.success)throw new Error(e.errorCode||e.errorMessage);return e.success}catch(e){const t=new s.Z(u.xu.ProductTrackingNetworkError);t.Metadata=JSON.stringify({err:e}),this.logModule.LogErrorEvent(u.R.EdgeFlyoutStatus,`Set Muid preferences request failed: ${e}`,t)}return!1}async RoamProductsFromEndpoint(){const e=await this.getAnid(),t=this.flyoutData.common.muid,i=(await this.pageHandlerModule.GetEmailForMSA(!0))?.email,n={Muid:t,Anid:e,Email:i};try{const t=await this.createRequest("roam-products",n);if(this.GetLocalProductTrackingDataFromEndpoint(),this.GetAnidProductTrackingDataFromEndpoint(e),!t.success)throw new Error(t.errorCode||t.errorMessage);return this.storageHandler.setStorageString(p.Q.ProductTrackingConsentStatus,JSON.stringify({IsAnidTrackingConsented:!0,timestamp:Date.now()})),t.success}catch(e){const t=new s.Z(u.xu.ProductTrackingNetworkError);t.Metadata=JSON.stringify({err:e}),this.logModule.LogErrorEvent(u.R.EdgeFlyoutStatus,`Roam products request failed: ${e}`,t)}return!1}async LogProductNotification(e,t,i){if(!e||!t)return!1;try{const n=await this.createRequest("log-notification",{Muid:e,ProductUrl:t},"POST",i);if(!n.success)throw new Error(n.errorCode||n.errorMessage);return!0}catch(i){const n=new s.Z(u.xu.ProductTrackingNetworkError);n.Metadata=JSON.stringify({Url:t,Muid:e,err:i}),this.logModule.LogErrorEvent(u.R.EdgeFlyoutStatus,`Log notification request failed: ${i}`,n)}return!1}async GetTrackedProductFromApi(e){const t=await this.getAnid(),i=this.flyoutData.common.muid;try{let n={Muid:i,Url:e};await this.canUseAnidForRequest(t)&&(n={Anid:t,Url:e});const o=await this.createRequest("is-tracked",n);if(!o.success)throw new Error(o.errorCode||o.errorMessage);return o.product}catch(n){const o=new s.Z(u.xu.ProductTrackingNetworkError);return o.Metadata=JSON.stringify({Url:e,Muid:i,Anid:t,err:n}),this.logModule.LogErrorEvent(u.R.EdgeFlyoutStatus,"Is tracked product request failed",o),null}}async GetTrackedProductsBySource(e){const t=await this.getProductTrackingData(),i=t?.trackedProducts.filter((t=>t.trackingSource===e));return i}async getProductTrackingData(){const e=await this.GetLocalProductTrackingData();return!e||await this.isStaleTrackedProducts(e)?await this.GetLocalProductTrackingDataFromEndpoint():e}async SetProductTrackingData(e,t){const i=e.trackedProducts,n=e.trackingPreferences;if(!i)return[];let o;return o&&Array.isArray(o.trackedProducts)?o.trackedProducts=i:o={trackedProducts:i},n&&(o.trackingPreferences=n),t?o._anid=await this.getAnid():o._muid=this.flyoutData.common.muid,o.timestamp=(new Date).toString(),this.storageHandler.setStorageString(p.Q.ProductTrackingTrackedProducts,JSON.stringify(o)),o.trackedProducts}async GetLocalProductTrackingData(){const e=await this.storageHandler.getStorageString(p.Q.ProductTrackingTrackedProducts);try{const t=JSON.parse(e);if(Array.isArray(t?.trackedProducts))return t}catch(e){return{trackedProducts:[]}}}async isTrackedProduct(e){return!!await this.GetTrackedProduct(e)}async GetTrackedProduct(e){if(!e)return null;const t=await this.storageHandler.getStorageString(p.Q.ProductTrackingUrlProductCache);let i=O.getUrlAndProductToMap(t);if(this.AnidTrackingAvailable()){const e=await this.getAnid();!e&&i.anid&&(i={},this.storageHandler.setStorageString(p.Q.ProductTrackingUrlProductCache,JSON.stringify({muid:this.flyoutData.common.muid}))),await this.canUseAnidForRequest(e)&&i.muid&&(i={},this.storageHandler.setStorageString(p.Q.ProductTrackingUrlProductCache,JSON.stringify({anid:e})))}const n=i?.[e];if(n)return n;const o=await this.GetLocalProductTrackingData();let r=!0;if(o?.trackedProducts){for(const t of o.trackedProducts){if(O.isSameUrl(t.ProductUrl,e))return t;O.isSameUrlByPathName(t.ProductUrl,e)&&(r=!1)}if(r)return null}const a=await this.GetTrackedProductFromApi(e);return a&&await this.addProductToUrlProductsMap(e,a),a}async checkIsOutOfStock(){const e=await this.getOutOfStockData();return!!e&&(O.isSameUrlByPathName(e?.productUrl,this.flyoutData.common.lastCommittedURL)?e&&"OUT_OF_STOCK"===e?.status:(this.storageHandler.clearStorage(p.Q.ProductTrackingOOSData),!1))}async getOutOfStockData(){const e=await this.storageHandler.getStorageString(p.Q.ProductTrackingOOSData);if(e)return(0,y.Ad)(e)}async sendTrackingData(e,t,i,n,o){const{strings:r}=this.flyoutData;if(!e){const e=new s.Z(u.xu.ProductTrackingDebug);return e.Metadata=JSON.stringify({url:this.flyoutData.common.lastCommittedURL,isOutOfStock:i}),void this.logModule.LogErrorEvent(u.R.EdgeFlyoutStatus,"Product unavailable, unable to track or untrack",e)}const a=new CustomEvent(C.e1.ProductTrackingUpdate);if(t){const t=await this.TrackProduct(e,i,n,o);if(await this.TrackProductLocal(t),t){const e=i?r.productTrackingStockTrackAlert:r.productTrackingPriceTrackAlert;this.stateManagement.dispatchEvent((0,C.eT)({text:e}))}else this.stateManagement.dispatchEvent((0,C.eT)({text:r.productTrackingTrackFailed}))}else{const t=await this.GetTrackedProduct(e.ProductUrl);this.UntrackProductLocal(t),await this.UntrackProduct(e)||this.stateManagement.dispatchEvent((0,C.eT)({text:r.productTrackingUntrackFailed}))}this.stateManagement.dispatchEvent(a)}recordTrackingToggleChange(e,t,i,n,o,r,s){const l=Object.assign({},t,{base64ProductImage:void 0}),c=this.flyoutData.common.openedWith===h.Te.Auto,d=JSON.stringify(S(S({duration:r,priceDropValue:s},l),{},{source:o,isOutOfStock:n,isNotification:c})),p=new a.Z(e,this.telemetryUtilities.setContentViewed(o),this.flyoutData.common.domain,d),g=`Product ${i?"":"un"}tracked from ${o}`;this.logModule.LogInfoEvent(u.R.ButtonClick,g,p)}setAlertSettingsPrefs(e,t){(0,f.Xo)("ptAlertSettingsPrefs",`${e}-${t}`)}getAlertSettingsPrefs(){const e=(0,f.Mw)("ptAlertSettingsPrefs"),t={};if(e){const[i,n]=e.split("-",2);isNaN(Number(i))||(t.priceDropValue=Number(i)),isNaN(Number(n))||(t.durationValue=Number(n))}return t}resetAlertSettingsPrefs(){(0,f.TJ)("ptAlertSettingsPrefs")}extractExtractedEntityData(e,t,i){if(!e)return null;const n=e?.entity??e.product_og_entity,o=n?.image||e.image_url,r=O.GetStrippedTitle(n?.name||e?.title,this.flyoutData.common.domain);let a=n?.price_value||n?.["offers/price"]?.substring(1);if(a||(a=this.flyoutData.dataLoader.GetLoadTimeDataValue("price",void 0)?.toString()??i),r&&(a||t)){const e=new l.Z(r,o,n?.price_currency??"$");return e.price=a||"",e.ProductUrl=this.flyoutData.common.lastCommittedURL,e}return null}ResetOutOfFlowNotificationFrequency(){const e=this.flyoutData.dataStoreModule.ProductTrackingNotificationData?.TrackedProducts;e&&e.length>2?this.pageHandlerModule.setShoppingNotificationFrequencyHours(3):this.pageHandlerModule.setShoppingNotificationFrequencyHours(24)}getAndCacheAfdMarket(){const e=this.flyoutData.common.afdMarket;return e?((0,f.Xo)("afdMarket",e),e):(0,f.Mw)("afdMarket")||""}async canUseAnidForRequest(e){return this.AnidTrackingAvailable()&&!!e&&await this.hasUserConsented()}async getAnid(){if(!this.AnidTrackingAvailable())return"";if(!this.anid){const e=(await this.pageHandlerModule.GetEdgeAnid(!0)).anid;this.anid=e??""}return this.anid}async GetLocalProductTrackingDataFromEndpoint(){try{const e=await this.getAnid();let t=!1,i=`tracked-products?muid=${this.flyoutData.common.muid}&trackingSource=5`;await this.canUseAnidForRequest(e)&&(i=`tracked-products?anid=${e}&trackingSource=5`,t=!0);const n=await this.createRequest(i,void 0,"GET"),o=new c.Z(n?.productTrackingData);return o&&this.SetProductTrackingData(o,t),o}catch(e){const t=new s.Z(u.xu.ProductTrackingNetworkError);return this.logModule.LogErrorEvent(u.R.EdgeFlyoutStatus,`Unable to get tracked products ${e}`,t),new c.Z(void 0)}}async addProductToUrlProductsMap(e,t){const i=await this.storageHandler.getStorageString(p.Q.ProductTrackingUrlProductCache),n=S(S({},O.getUrlAndProductToMap(i)),{},{[e]:t});this.AnidTrackingAvailable()?n.anid=await this.hasUserConsented()?await this.getAnid():void 0:n.muid=this.flyoutData.common.muid,this.storageHandler.setStorageString(p.Q.ProductTrackingUrlProductCache,JSON.stringify(n))}async removeProductFromUrlProductsMap(e){const t=await this.storageHandler.getStorageString(p.Q.ProductTrackingUrlProductCache),i=O.getUrlAndProductToMap(t);this.storageHandler.setStorageString(p.Q.ProductTrackingUrlProductCache,JSON.stringify(S(S({},i),{},{[e]:void 0})))}async createRequest(e,t,i="POST",n){const o=this.flyoutData.dataLoader.GetLoadTimeDataValue("enabledservicefeatures",{}),r=this.flyoutData.dataLoader.GetLoadTimeDataValue("enabledservicefeaturesv2",{}),a=await fetch(`${this.dealsEndpoint}/product-tracking/${e}`,{body:JSON.stringify(t),headers:{"Content-Type":"application/json",Source:"ProductTracking",Service:n??"Extension/UX",EnabledServiceFeatures:JSON.stringify(o),EnabledServiceFeaturesv2:JSON.stringify(r)},method:i});return await a.json()}async createUntrackProductBody(e,t){const i={Currency:e.currency??e.CurrencySymbol,Domain:t.domain,Market:t.market??t.afdMarket,Muid:t.muid,Url:e.ProductUrl},n=await this.getAnid();return await this.canUseAnidForRequest(n)&&(i.Anid=await this.getAnid()),i}async createTrackProductBody(e,t,i,n,o){const r={Currency:e.currency||"$",Domain:t.domain,ImageUrl:e.imageUrl,Market:t.market??t.afdMarket,Muid:t.muid,ProductStockStatus:i?2:1,TrackingType:i?"OutOfStock":"PriceDrop",Title:O.GetStrippedTitle(e.title,t.domain),Url:O.GetStrippedUrl(e.ProductUrl??t.lastCommittedURL)},a=await this.getAnid();await this.canUseAnidForRequest(a)&&(r.Anid=a,r.Muid=t.muid);const s=(0,g.K)(e?.price?.toString()??"");return Number.isNaN(s)||(r.Price=s),n&&(r.DurationInWeeks=n),o&&!i&&(r.DropPercentage=o),r}async isStaleTrackedProducts(e){if(!e)return!0;const{timestamp:t}=e,i=await this.hasUserConsented();if(!i&&e._anid)return!0;if(i&&e._muid)return!0;if(!t)return!0;try{const e=new Date(t);return Date.now()-+e>this.trackedProductsCachePeriod}catch(e){return!0}}isStaleAnidTrackingData(e){if(!e)return!0;const{timestamp:t}=e;if(!t)return!0;try{const e=new Date(+t);return Date.now()-+e>this.anidTrackingDataCachePeriod}catch(e){return!0}}}t.ZP=O},56764:function(e,t,i){"use strict";i.d(t,{g:function(){return n}});let n=function(e){return e.EdgeImpressionId="EdgeImpressionId",e.CouponImpressionId="CouponImpressionId",e.DomainName="DomainName",e.Client="Client",e.FlyoutId="FlyoutId",e.EdgeChannel="EdgeChannel",e}({})},87605:function(e,t,i){"use strict";i.d(t,{R9:function(){return o},bS:function(){return n}});let n=function(e){return e.VIEW_PRODUCT_SUMMARY_CARD="VIEW_PRODUCT_SUMMARY_CARD",e.COUPONS_COPIED="COUPONS_COPIED",e.DISMISSED="DISMISSED",e.FLYOUT_SNOOZED="SNOOZED",e.FLYOUT_SNOOZE_UNDO="FLYOUT_SNOOZE_UNDO",e.FRE_DISMISSED="FRE_DISMISSED",e.FRE_GOT_IT="FRE_GOT_IT",e.FRE_MANAGE="FRE_MANAGE",e.FRE_NO_THANKS="FRE_NO_THANKS",e.FRE_SETTINGS="FRE_SETTINGS",e.MANAGE="MANAGE",e.NAVIGATE_TO_RETAILER="NAVIGATE_TO_RETAILER",e.TRY_ALL_COUPONS="TRY_ALL_COUPONS",e.TURN_OFF_AUTO_SHOW="TURN_OFF_AUTO_SHOW",e.TURN_ON_AUTO_SHOW="TURN_ON_AUTO_SHOW",e.VIEW_MORE_COUPONS="VIEW_MORE_COUPONS",e.VIEW_MORE_RETAILERS="VIEW_MORE_RETAILERS",e.VIEW_MORE_GROCERY_COUPONS="VIEW_MORE_GROCERY_COUPONS",e.LIGHT_DISMISSED="LIGHT_DISMISSED",e.SHOW_MORE_SELLERS="SHOW_MORE_SELLERS",e.REBATES_VIEW_IN_PANE="REBATES_VIEW_IN_PANE",e.REBATES_LEARN_MORE="REBATES_LEARN_MORE",e.REBATES_ACCOUNT="REBATES_ACCOUNT",e.REBATES_HISTORY="REBATES_HISTORY",e.ACTIVATE_CASHBACK="ACTIVATE_CASHBACK",e.EXPAND_PRICE_HISTORY_GRAPH="EXPAND_PRICE_HISTORY_GRAPH",e.HIDE_PRICE_HISTORY_GRAPH="HIDE_PRICE_HISTORY_GRAPH",e.FIRST_HOVER_PRICE_HISTORY_GRAPH="FIRST_HOVER_PRICE_HISTORY_GRAPH",e.VIEW_PRICE_HISTORY="VIEW_PRICE_HISTORY",e.HIDE_PRICE_HISTORY="HIDE_PRICE_HISTORY",e.NAVIGATE_TO_DEAL_OFFER="NAVIGATE_TO_DEAL_OFFER",e.NAVIGATE_TO_PROFESSIONAL_REVIEW="NAVIGATE_TO_PROFESSIONAL_REVIEW",e.NAVIGATE_TO_VIDEO_REVIEW="NAVIGATE_TO_VIDEO_REVIEW",e.TRY_ALL_COUPON_WITH_EXPRESS_CHECKOUT="TRY_ALL_COUPON_WITH_EXPRESS_CHECKOUT",e.TRY_ALL_COUPON_WITH_EXPRESS_CHECKOUT_FORZIP="TRY_ALL_COUPON_WITH_EXPRESS_CHECKOUT_FORZIP",e.EXPRESS_CHECKOUT="EXPRESS_CHECKOUT",e.EXPRESS_CHECKOUT_FORZIP="EXPRESS_CHECKOUT_FORZIP",e.EXPRESS_CHECKOUT_WITHOUT_PAYMENT="EXPRESS_CHECKOUT_WITHOUT_PAYMENT",e.NAVIGATE_TO_RECOMMENDATION_OFFER="NAVIGATE_TO_RECOMMENDATION_OFFER",e.CLIP_COUPON="CLIP_COUPON",e.ACTIVATE_CASHBACK_NEW="ACTIVATE_CASHBACK_NEW",e.NAVIGATE_TO_OTHER_SELLER="NAVIGATE_TO_OTHER_SELLER",e.ADD_TO_CART_FROM_OTHER_SELLER="ADD_TO_CART_FROM_OTHER_SELLER",e.ITEMIZED_CASHBACK_ADD_TO_CART="ITEMIZED_CASHBACK_ADD_TO_CART",e.PRODUCT_HISTORY_NAVIGATION="PRODUCT_HISTORY_NAVIGATION",e.PRODUCT_HISTORY_EXPAND_SECTION="PRODUCT_HISTORY_EXPAND_SECTION",e.PRODUCT_HISTORY_COLLAPSE_SECTION="PRODUCT_HISTORY_COLLAPSE_SECTION",e.TIPS_CLICK="TIPS_CLICK",e.OPEN_PANE_FROM_FLYOUT="OPEN_PANE_FROM_FLYOUT",e.WALLET_HUB_NAVIGATION="WALLET_HUB_NAVIGATION",e.PAYMENT_OPTIONS_EXPAND_SECTION="PAYMENT_OPTIONS_EXPAND_SECTION",e.PAYMENT_OPTIONS_COLLAPSE_SECTION="PAYMENT_OPTIONS_COLLAPSE_SECTION",e.EXPRESS_CHECKOUT_ZIP_OPTION_SELECTED="EXPRESS_CHECKOUT_ZIP_OPTION_SELECTED",e.EXPRESS_CHECKOUT_SHOWN_IN_ZIP_FEATURE="EXPRESS_CHECKOUT_SHOWN_IN_ZIP_FEATURE",e.EXPRESS_CHECKOUT_ZIP_OPTION_SHOWN="EXPRESS_CHECKOUT_ZIP_OPTION_SHOWN",e.CONTINUE_TO_ZIP_CLICKED="CONTINUE_TO_ZIP_CLICKED",e.DELETE_TRACKER="DELETE_TRACKER",e.CASHBACK_RETAILER_CLICK="CASHBACK_RETAILER_CLICK",e.ACTIVATE_CASHBACK_RETURNED="ACTIVATE_CASHBACK_RETURNED",e.PRINT_COUPONS_CLICK="PRINT_COUPONS_CLICK",e.SELECT_PRINTABLE_COUPON="SELECT_PRINTABLE_COUPON",e.CLICK_SEEALL_PRINTABLE_COUPON="CLICK_SEEALL_PRINTABLE_COUPON",e.DIGITAL_GROCERY_COUPONS_CLICK="DIGITAL_GROCERY_COUPONS_CLICK",e.DIGITAL_GROCERY_COUPONS_SEEALL="DIGITAL_GROCERY_COUPONS_SEEALL",e.PACKAGE_TRACKING_OPT_IN="PACKAGE_TRACKING_TRACK_ORDER_OPT_IN",e.PACKAGE_TRACKING_OPT_OUT="PACKAGE_TRACKING_TRACK_ORDER_DO_NOT_TRACK",e.PACKAGE_TRACKING_EXPAND_SECTION="PACKAGE_TRACKING_EXPAND_SECTION",e.PACKAGE_TRACKING_SEE_MORE="PACKAGE_TRACKING_SEE_MORE",e.PACKAGE_TRACKING_COLLAPSE_SECTION="PACKAGE_TRACKING_COLLAPSE_SECTION",e.PACKAGE_TRACKING_CARD_CLICKED="PACKAGE_TRACKING_CARD_CLICKED",e.ACTIVATE_REWARDS_NEW="ACTIVATE_REWARDS_NEW",e.REWARDS_SIGNIN_CLICK="REWARDS_SIGNIN_CLICK",e.REWARDS_REDEEM_CLICK="REWARDS_REDEEM_CLICK",e.SUSTAINABILITYSHOP_CLICK="SUSTAINABILITYSHOP_CLICK",e.PWILO_NOTIFICATION_PRICE_DROP="PWILO_NOTIFICATION_PRICE_DROP",e.PWILO_NOTIFICATION_PRICE_DROP_DELETE="PWILO_NOTIFICATION_PRICE_DROP_DELETE",e.PWILO_NOTIFICATION_PRICE_DROP_DISABLE_REMINDERS="PWILO_NOTIFICATION_PRICE_DROP_DISABLE_REMINDERS",e.EXPRESS_CHECKOUT_ZIP_LEARN_MORE_LINK_CLICKED="EXPRESS_CHECKOUT_ZIP_LEARN_MORE_LINK_CLICKED",e.EXPRESS_CHECKOUT_ZIP_PREFERENCE_LINK_CLICKED="EXPRESS_CHECKOUT_ZIP_PREFERENCE_LINK_CLICKED",e.SUSTAINABILITY_LANDING_FULL_LEARN_MORE="SUSTAINABILITY_LANDING_FULL_LEARN_MORE",e.SUSTAINABILITY_LANDING_FOOTER_LEARN_MORE="SUSTAINABILITY_LANDING_FOOTER_LEARN_MORE",e.SUSTAINABILITY_PURCHASE_CONFIRMATION_LEARN_MORE="SUSTAINABILITY_PURCHASE_CONFIRMATION_LEARN_MORE",e.CLICK_PCB_CROSS_SESSION="CLICK_PCB_CROSS_SESSION",e.REWARD_JOIN_NOW="REWARD_JOIN_NOW",e.REWARD_MAYBE_LATER="REWARD_MAYBE_LATER",e.REWARD_DISMISS="REWARD_DISMISS",e.REWARD_LINK_CLICK="REWARD_LINK_CLICK",e.ATTAINABLE_COUPON_CONTINUE="ATTAINABLE_COUPON_CONTINUE",e.ATTAINABLE_COUPON_CLICK="ATTAINABLE_COUPON_CLICK",e.ACTIVATE_CLICK_ITEMIZED_CASHBACK="ACTIVATE_CLICK_ITEMIZED_CASHBACK",e.ACTIVATED_CLICK_ITEMIZED_CASHBACK="ACTIVATED_CLICK_ITEMIZED_CASHBACK",e.CLICK_ITEMIZED_CASHBACK_SEE_ALL="CLICK_ITEMIZED_CASHBACK_SEE_ALL",e.HOVER_INFO_ICON_ITEMIZED_CASHBACK="HOVER_INFO_ICON_ITEMIZED_CASHBACK",e.CLICK_DISCLAIMER_ITEMIZED_CASHBACK="CLICK_DISCLAIMER_ITEMIZED_CASHBACK",e.PERSONALIZED_CASHBACK_SEEMORE="PERSONALIZED_CASHBACK_SEEMORE",e.FEED_MOMENT_IN_TIME="FEED_MOMENT_IN_TIME",e.FEED_TRENDING_OFFERS="FEED_TRENDING_OFFERS",e.FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB="FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB",e.FEED_TRENDING_OFFERS_SHOW_MORE="FEED_TRENDING_OFFERS_SHOW_MORE",e.FEED_SIMILAR_OFFERS="FEED_SIMILAR_OFFERS",e.FEED_SIMILAR_OFFERS_SHOW_MORE="FEED_SIMILAR_OFFERS_SHOW_MORE",e.FEED_SEARCH_RESULTS="FEED_SEARCH_RESULTS",e.FEED_SEARCH_RESULTS_SHOW_MORE="FEED_SEARCH_RESULTS_SHOW_MORE",e.FEED_NATIVE_ADS="FEED_NATIVE_ADS",e.FEED_NATIVE_ADS_SHOW_MORE="FEED_NATIVE_ADS_SHOW_MORE",e.FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB_SHOW_MORE="FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB_SHOW_MORE",e.FEED_DAILY_DEALS="FEED_DAILY_DEALS",e.FEED_DAILY_DEALS_SHOW_MORE="FEED_DAILY_DEALS_SHOW_MORE",e.FEED_BUY_DIRECT="FEED_BUY_DIRECT",e.FEED_BUY_DIRECT_SHOW_MORE="FEED_BUY_DIRECT_SHOW_MORE",e.FEED_INFINITE_CATEGORY="FEED_INFINITE_CATEGORY",e.FEED_INFINITE_CATEGORY_AD="FEED_INFINITE_CATEGORY_AD",e.FEED_INFINITE_CATEGORY_SHOW_MORE="FEED_INFINITE_CATEGORY_SHOW_MORE",e.FEED_INFINITE_CATEGORY_AD_SHOW_MORE="FEED_INFINITE_CATEGORY_AD_SHOW_MORE",e.FEED_VISUAL_SEARCH="FEED_VISUAL_SEARCH",e.FEED_VISUAL_SEARCH_SHOW_MORE="FEED_VISUAL_SEARCH_SHOW_MORE",e.FEED_RELATED_PRODUCTS="FEED_RELATED_PRODUCTS",e.FEED_RELATED_PRODUCTS_SHOW_MORE="FEED_RELATED_PRODUCTS_SHOW_MORE",e.SWITCH_TO_TAB1="SWITCH_TO_TAB1",e.SWITCH_TO_TAB2="SWITCH_TO_TAB2",e.SWITCH_TO_TAB3="SWITCH_TO_TAB3",e.SCROLL_TO_TAB1="SCROLL_TO_TAB1",e.SCROLL_TO_TAB2="SCROLL_TO_TAB2",e.SCROLL_TO_TAB3="SCROLL_TO_TAB3",e.AUTOS_MARKETPLACE_TITLE_CLICK="AUTOS_MARKETPLACE_TITLE_CLICK",e.AUTOS_MARKETPLACE_LISTING_HOVER="AUTOS_MARKETPLACE_LISTING_HOVER",e.AUTOS_MARKETPLACE_RECOMMENDATION_CLICK="AUTOS_MARKETPLACE_RECOMMENDATION_CLICK",e.AUTOS_MARKETPLACE_SEE_MORE_CLICK="AUTOS_MARKETPLACE_SEE_MORE_CLICK",e.AUTOS_MARKETPLACE_MYGARAGE_CHECK_NOW="AUTOS_MARKETPLACE_MYGARAGE_CHECK_NOW",e.AUTOS_PRICE_INSIGHT_HOVER="AUTOS_PRICE_INSIGHT_HOVER",e.AUTOS_PRICE_INSIGHT_SEE_MORE_CLICK="AUTOS_PRICE_INSIGHT_SEE_MORE_CLICK",e.AUTOS_PRICE_INSIGHT_RATINGURL_CLICK="AUTOS_PRICE_INSIGHT_RATINGURL_CLICK",e.AUTOS_REVIEWS_VIDEO_CLICK="AUTOS_REVIEWS_VIDEO_CLICK",e.AUTOS_REVIEWS_VIDEO_SEE_MORE_CLICK="AUTOS_REVIEWS_VIDEO_SEE_MORE_CLICK",e.AUTOS_MYGARAGE_TITLE_CLICK="AUTOS_MYGARAGE_TITLE_CLICK",e.AUTOS_MYGARAGE_HOVER="AUTOS_MYGARAGE_HOVER",e.AUTOS_MYGARAGE_MODULE_CLICK="AUTOS_MYGARAGE_MODULE_CLICK",e.GO_TO_ABANDONED_CART="GO_TO_ABANDONED_CART",e.GO_TO_WIN_CART="GO_TO_WIN_CART",e.SEE_ALL_TRENDING_DEALS="SEE_ALL_TRENDING_DEALS",e.NAVIGATE_TO_TRENDING_DEAL="NAVIGATE_TO_TRENDING_DEAL",e.GROCERY_CASHBACK_SINGIN_CLICKED="GROCERY_CASHBACK_SINGIN_CLICKED",e.MS_CASHBACK_ACCOUNT_CLICKED="MS_CASHBACK_ACCOUNT_CLICKED",e.CLICK_DISCLAIMER_PENDING_CASHBACK="CLICK_DISCLAIMER_PENDING_CASHBACK",e.CLICK_DISCLAIMER_CLAIMMED_PENDING_CASHBACK="CLICK_DISCLAIMER_CLAIMMED_PENDING_CASHBACK",e.HOVER_INFO_ICON_PENDING_CASHBACK="HOVER_INFO_ICON_PENDING_CASHBACK",e.HOVER_INFO_ICON_CLAIMMED_PENDING_CASHBACK="HOVER_INFO_ICON_CLAIMMED_PENDING_CASHBACK",e.SUBMIT_COUPON="SUBMIT_COUPON",e.AWARENESS_SEE_MORE="AWARENESS_SEE_MORE",e.CLICK_SPB_CASHBACK_SEE_MORE="CLICK_SPB_CASHBACK_SEE_MORE",e.ACTIVATE_CLICK_SPB_CASHBACK="ACTIVATE_CLICK_SPB_CASHBACK",e.ACTIVATED_CLICK_SPB_CASHBACK="ACTIVATED_CLICK_SPB_CASHBACK",e.HOVER_INFO_ICON_SPB_CASHBACK="HOVER_INFO_ICON_SPB_CASHBACK",e.CLICK_DISCLAIMER_SPB_CASHBACK="CLICK_DISCLAIMER_SPB_CASHBACK",e.INPUT_COUPON="INPUT_COUPON",e.CLICK_BEST_COUPON="CLICK_BEST_COUPON",e.SEE_MORE_TRENDING_COUPONS="SEE_MORE_TRENDING_COUPONS",e.PRODUCT_TRACKED_STOCK="PRODUCT_TRACKED_STOCK",e.PRODUCT_TRACKED_PRICE="PRODUCT_TRACKED_PRICE",e.PRODUCT_TRACKED_STOCK_SETTINGS="PRODUCT_TRACKED_STOCK_SETTINGS",e.PRODUCT_TRACKED_PRICE_SETTINGS="PRODUCT_TRACKED_PRICE_SETTINGS",e.PRODUCT_TRACKING_PRODUCT_NOTIFICATION_CLICK="PRODUCT_TRACKING_PRODUCT_NOTIFICATION_CLICK",e.PRODUCT_TRACKING_PRODUCT_COLLECTIONS_CLICK="PRODUCT_TRACKING_PRODUCT_COLLECTIONS_CLICK",e.PRODUCT_TRACKING_PRODUCT_NOTIFICATION_UNTRACK_CLICK="PRODUCT_TRACKING_PRODUCT_NOTIFICATION_UNTRACK_CLICK",e.PRODUCT_TRACKING_PRODUCT_COLLECTIONS_UNTRACK_CLICK="PRODUCT_TRACKING_PRODUCT_COLLECTIONS_UNTRACK_CLICK",e.PRODUCT_TRACKING_NOTIFICATION_TRACK="PRODUCT_TRACKING_NOTIFICATION_TRACK",e.PRODUCT_TRACKING_NOTIFICATION_UNTRACK="PRODUCT_TRACKING_NOTIFICATION_UNTRACK",e.PRODUCT_TRACKING_COLLECTIONS_RECENT_SEE_MORE_CLICK="PRODUCT_TRACKING_COLLECTIONS_RECENT_SEE_MORE_CLICK",e.PRODUCT_TRACKING_COLLECTIONS_TRACKED_PRODUCT_SEE_MORE_CLICK="PRODUCT_TRACKING_COLLECTIONS_TRACKED_PRODUCT_SEE_MORE_CLICK",e.PRODUCT_TRACKING_COLLECTIONS_TAB_SWITCH_1="PRODUCT_TRACKING_COLLECTIONS_TAB_SWITCH_1",e.PRODUCT_TRACKING_COLLECTIONS_TAB_SWITCH_2="PRODUCT_TRACKING_COLLECTIONS_TAB_SWITCH_2",e.PRODUCT_TRACKING_COLLECTIONS_TAB_SWITCH_3="PRODUCT_TRACKING_COLLECTIONS_TAB_SWITCH_3",e.PRODUCT_TRACKED_STOCK_UNTRACK="PRODUCT_TRACKED_STOCK_UNTRACK",e.PRODUCT_TRACKED_PRICE_UNTRACK="PRODUCT_TRACKED_PRICE_UNTRACK",e.PRODUCT_TRACKING_COLLECTIONS_TRACK_CLICK="PRODUCT_TRACKING_COLLECTIONS_TRACK_CLICK",e.PRODUCT_TRACKING_COLLECTIONS_VIEW_STEPS="PRODUCT_TRACKING_COLLECTIONS_VIEW_STEPS",e.PRODUCT_TRACKING_COLLECTIONS_START_TRACKING="PRODUCT_TRACKING_COLLECTIONS_START_TRACKING",e.PRODUCT_TRACKED_VIEW_TRACKED_PRODUCTS="PRODUCT_TRACKED_VIEW_TRACKED_PRODUCTS",e.PRODUCT_TRACKING_ABANDONED_CART_TRACK_CLICK="PRODUCT_TRACKING_ABANDONED_CART_TRACK_CLICK",e.PRODUCT_TRACKING_ABANDONED_CART_UNTRACK_CLICK="PRODUCT_TRACKING_ABANDONED_CART_UNTRACK_CLICK",e.INBOX_COUPONS_SIGN_IN_EDGE="INBOX_COUPONS_SIGN_IN_EDGE",e.INBOX_COUPONS_CONNECT_OUTLOOK_INBOX="INBOX_COUPONS_CONNECT_OUTLOOK_INBOX",e.INBOX_COUPONS_CONNECT_GMAIL_INBOX="INBOX_COUPONS_CONNECT_GMAIL_INBOX",e.INBOX_COUPONS_RECONNECT_INBOX="INBOX_COUPONS_RECONNECT_INBOX",e.INBOX_COUPONS_COPY_COUPON="INBOX_COUPONS_COPY_COUPON",e.INBOX_COUPONS_DISCONNECT_INBOX="INBOX_COUPONS_DISCONNECT_INBOX",e.PINTEREST_COUPON_COPIED="PINTEREST_COUPON_COPIED",e.PINTEREST_CASHBACK_ACTIVATED="PINTEREST_CASHBACK_ACTIVATED",e.PINTEREST_VIEW_PRICE_HISTORY="PINTEREST_VIEW_PRICE_HISTORY",e.ATTAINABLE_COUPON_VIEWED="ATTAINABLE_COUPON_VIEWED",e.MORE_MENU_OPENED="MORE_MENU_OPENED",e.FEEDBACK_THUMBS_UP="FEEDBACK_THUMBS_UP",e.FEEDBACK_THUMBS_DOWN="FEEDBACK_THUMBS_DOWN",e.AUTOS_MARKETPLACE_RATING_REVIEW_HOVER="AUTOS_MARKETPLACE_RATING_REVIEW_HOVER",e.FETCH_SEARCH_RESULTS="FETCH_SEARCH_RESULTS",e.SEARCH_BOX_FOCUSED="SEARCH_BOX_FOCUSED",e.PRICE_COMPARISON_COMPONENT_CLICK="PRICE_COMPARISON_COMPONENT_CLICK",e.CJK_OPEN_FLYOUT="CJK_OPEN_FLYOUT",e.CJK_OPEN_PANE_FROM_FLYOUT="CJK_OPEN_PANE_FROM_FLYOUT",e.CJK_OPEN_PANE_FROM_SIDEBAR="CJK_OPEN_PANE_FROM_SIDEBAR",e.CJK_SCROLL_PAGE="CJK_SCROLL_PAGE",e.CJK_SWITCH_TO_TAB1="CJK_SWITCH_TO_TAB1",e.CJK_SWITCH_TO_TAB2="CJK_SWITCH_TO_TAB2",e.CJK_COUPONS_CLICK="CJK_COUPONS_CLICK",e.CJK_COUPONS_SEE_MORE="CJK_COUPONS_SEE_MORE",e.CJK_COUPONS_CHECK_COUPON="CJK_COUPONS_CHECK_COUPON",e.CJK_VIEW_PRICE_HISTORY="CJK_VIEW_PRICE_HISTORY",e.CJK_PRICE_HISTORY_SET_TIMERANGE="CJK_PRICE_HISTORY_SET_TIMERANGE",e.CJK_PRICE_COMPARISON_CLICK="CJK_PRICE_COMPARISON_CLICK",e.CJK_CLICK_PRICE_COMPARISON_SEE_MORE="CJK_CLICK_PRICE_COMPARISON_SEE_MORE",e.CJK_SIMILAR_PRODUCTS_CLICK="CJK_SIMILAR_PRODUCTS_CLICK",e.CJK_ACTIVITY_CLICK="CJK_ACTIVITY_CLICK",e.CJK_ACTIVITY_SEE_MORE="CJK_ACTIVITY_SEE_MORE",e.CJK_TRENDING_PRODUCTS_CLICK="CJK_TRENDING_PRODUCTS_CLICK",e.CJK_TRENDING_PRODUCTS_SET_CATEGORY="CJK_TRENDING_PRODUCTS_SET_CATEGORY",e.CJK_TRENDING_PRODUCTS_SET_RETAILER="CJK_TRENDING_PRODUCTS_SET_RETAILER",e.FEED_CAMPAIGN_SHOW_MORE="FEED_CAMPAIGN_SHOW_MORE",e.TRY_PRODUCT_BEST_COUPON="TRY_PRODUCT_BEST_COUPON",e.AX_SHOPPING_NAV_TRY_NOW_CLICK="AX_SHOPPING_NAV_TRY_NOW_CLICK",e.PRICE_MATCH_OPT_IN="PRICE_MATCH_OPT_IN",e.PRICE_MATCH_OPT_OUT="PRICE_MATCH_OPT_OUT",e.PRICE_MATCH_CARD_CLICK="PRICE_MATCH_CARD_CLICK",e.PRICE_MATCH_CARD_CTA_CLICK="PRICE_MATCH_CARD_CTA_CLICK",e.PRICE_MATCH_NOTIFICATION_CTA_CLICK="PRICE_MATCH_NOTIFICATION_CTA_CLICK",e.DISCOVER_NOTIFICATION_CLICK="DISCOVER_NOTIFICATION_CLICK",e.PRODUCT_TRACKING_COLLECTIONS_SIGN_IN="PRODUCT_TRACKING_COLLECTIONS_SIGN_IN",e.PRODUCT_TRACKING_COLLECTIONS_SIGN_IN_CLOSE="PRODUCT_TRACKING_COLLECTIONS_SIGN_IN_CLOSE",e.PRODUCT_TRACKING_COLLECTIONS_ROAM="PRODUCT_TRACKING_COLLECTIONS_ROAM",e.PRODUCT_TRACKING_COLLECTIONS_ROAM_CLOSE="PRODUCT_TRACKING_COLLECTIONS_ROAM_CLOSE",e.PRODUCT_TRACKING_SUMMARY_CARD="PRODUCT_TRACKING_SUMMARY_CARD",e.TRY_BGAA_BEST_COUPON="TRY_BGAA_BEST_COUPON",e.TRAVEL_CHEAPER_FLIGHTS_CLICK="TRAVEL_CHEAPER_FLIGHTS_CLICK",e.TRAVEL_CHEAPER_HOTEL_CLICK="TRAVEL_CHEAPER_HOTEL_CLICK ",e.BUYING_OPTIONS_FILTERCHANGE="BUYING_OPTIONS_FILTERCHANGE",e.BUYING_OPTIONS_RETAILER_HOVER="BUYING_OPTIONS_RETAILER_HOVER",e}({}),o=function(e){return e[e.COUPONS_COPIED=0]="COUPONS_COPIED",e[e.DISMISSED=1]="DISMISSED",e[e.FRE_DISMISSED=2]="FRE_DISMISSED",e[e.FRE_GOT_IT=3]="FRE_GOT_IT",e[e.FRE_MANAGE=4]="FRE_MANAGE",e[e.FRE_NO_THANKS=5]="FRE_NO_THANKS",e[e.FRE_SETTINGS=6]="FRE_SETTINGS",e[e.MANAGE=7]="MANAGE",e[e.NAVIGATE_TO_RETAILER=8]="NAVIGATE_TO_RETAILER",e[e.TRY_ALL_COUPONS=9]="TRY_ALL_COUPONS",e[e.TURN_OFF_AUTO_SHOW=10]="TURN_OFF_AUTO_SHOW",e[e.TURN_ON_AUTO_SHOW=11]="TURN_ON_AUTO_SHOW",e[e.VIEW_MORE_COUPONS=12]="VIEW_MORE_COUPONS",e[e.VIEW_MORE_RETAILERS=13]="VIEW_MORE_RETAILERS",e[e.LIGHT_DISMISSED=14]="LIGHT_DISMISSED",e[e.SHOW_MORE_SELLERS=15]="SHOW_MORE_SELLERS",e[e.REBATES_LEARN_MORE=16]="REBATES_LEARN_MORE",e[e.REBATES_ACCOUNT=17]="REBATES_ACCOUNT",e[e.REBATES_HISTORY=18]="REBATES_HISTORY",e[e.ACTIVATE_CASHBACK=19]="ACTIVATE_CASHBACK",e[e.EXPAND_PRICE_HISTORY_GRAPH=20]="EXPAND_PRICE_HISTORY_GRAPH",e[e.HIDE_PRICE_HISTORY_GRAPH=21]="HIDE_PRICE_HISTORY_GRAPH",e[e.FIRST_HOVER_PRICE_HISTORY_GRAPH=22]="FIRST_HOVER_PRICE_HISTORY_GRAPH",e[e.VIEW_PRICE_HISTORY=23]="VIEW_PRICE_HISTORY",e[e.HIDE_PRICE_HISTORY=24]="HIDE_PRICE_HISTORY",e[e.NAVIGATE_TO_DEAL_OFFER=25]="NAVIGATE_TO_DEAL_OFFER",e[e.NAVIGATE_TO_PROFESSIONAL_REVIEW=26]="NAVIGATE_TO_PROFESSIONAL_REVIEW",e[e.NAVIGATE_TO_VIDEO_REVIEW=27]="NAVIGATE_TO_VIDEO_REVIEW",e[e.TRY_ALL_COUPON_WITH_EXPRESS_CHECKOUT=28]="TRY_ALL_COUPON_WITH_EXPRESS_CHECKOUT",e[e.EXPRESS_CHECKOUT=29]="EXPRESS_CHECKOUT",e[e.NAVIGATE_TO_RECOMMENDATION_OFFER=30]="NAVIGATE_TO_RECOMMENDATION_OFFER",e[e.CLIP_COUPON=31]="CLIP_COUPON",e[e.ACTIVATE_CASHBACK_NEW=32]="ACTIVATE_CASHBACK_NEW",e[e.ACTIVATE_REWARDS_NEW=33]="ACTIVATE_REWARDS_NEW",e[e.ADD_TO_CART_FROM_OTHER_SELLER=34]="ADD_TO_CART_FROM_OTHER_SELLER",e[e.PRODUCT_HISTORY_NAVIGATION=35]="PRODUCT_HISTORY_NAVIGATION",e[e.PRODUCT_HISTORY_EXPAND_SECTION=36]="PRODUCT_HISTORY_EXPAND_SECTION",e[e.PRODUCT_HISTORY_COLLAPSE_SECTION=37]="PRODUCT_HISTORY_COLLAPSE_SECTION",e[e.NAVIGATE_TO_OTHER_SELLER=38]="NAVIGATE_TO_OTHER_SELLER",e[e.TIPS_CLICK=39]="TIPS_CLICK",e[e.REWARDS_SIGNIN_CLICK=40]="REWARDS_SIGNIN_CLICK",e[e.REWARDS_REDEEM_CLICK=41]="REWARDS_REDEEM_CLICK",e[e.CASHBACK_OTHERSITES_CLICK=42]="CASHBACK_OTHERSITES_CLICK",e[e.TRY_ALL_COUPON_WITH_EXPRESS_CHECKOUT_FORZIP=44]="TRY_ALL_COUPON_WITH_EXPRESS_CHECKOUT_FORZIP",e[e.EXPRESS_CHECKOUT_FORZIP=45]="EXPRESS_CHECKOUT_FORZIP",e[e.EXPRESS_CHECKOUT_ZIP_OPTION_SELECTED=46]="EXPRESS_CHECKOUT_ZIP_OPTION_SELECTED",e[e.EXPRESS_CHECKOUT_SHOWN_IN_ZIP_FEATURE=47]="EXPRESS_CHECKOUT_SHOWN_IN_ZIP_FEATURE",e[e.EXPRESS_CHECKOUT_ZIP_OPTION_SHOWN=48]="EXPRESS_CHECKOUT_ZIP_OPTION_SHOWN",e[e.CONTINUE_TO_ZIP_CLICKED=49]="CONTINUE_TO_ZIP_CLICKED",e[e.PWILO_NOTIFICATION_PRICE_DROP=50]="PWILO_NOTIFICATION_PRICE_DROP",e[e.YOUTUBE_COUPON_COPIED_HOME=51]="YOUTUBE_COUPON_COPIED_HOME",e[e.YOUTUBE_COUPON_COPIED_VIDEO=52]="YOUTUBE_COUPON_COPIED_VIDEO",e[e.YOUTUBE_COUPON_COPIED_RETAILER=53]="YOUTUBE_COUPON_COPIED_RETAILER",e[e.YOUTUBE_COUPON_COPIED_RETAILER_CHECKOUT=54]="YOUTUBE_COUPON_COPIED_RETAILER_CHECKOUT",e[e.YOUTUBE_TRY_ALL_COUPONS=55]="YOUTUBE_TRY_ALL_COUPONS",e[e.YOUTUBE_COUPONS_EXPAND_SECTION=56]="YOUTUBE_COUPONS_EXPAND_SECTION",e[e.YOUTUBE_COUPONS_COLLAPSE_SECTION=57]="YOUTUBE_COUPONS_COLLAPSE_SECTION",e[e.YOUTUBE_COUPONS_SEE_MORE_COUPONS=58]="YOUTUBE_COUPONS_SEE_MORE_COUPONS",e[e.CASHBACK_RETAILER_CLICK=59]="CASHBACK_RETAILER_CLICK",e[e.ACTIVATE_CASHBACK_RETURNED=60]="ACTIVATE_CASHBACK_RETURNED",e[e.PRINT_COUPONS_CLICK=61]="PRINT_COUPONS_CLICK",e[e.SELECT_PRINTABLE_COUPON=62]="SELECT_PRINTABLE_COUPON",e[e.CLICK_SEEALL_PRINTABLE_COUPON=63]="CLICK_SEEALL_PRINTABLE_COUPON",e[e.DIGITAL_GROCERY_COUPONS_CLICK=64]="DIGITAL_GROCERY_COUPONS_CLICK",e[e.DIGITAL_GROCERY_COUPONS_SEEALL=65]="DIGITAL_GROCERY_COUPONS_SEEALL",e[e.PINTEREST_COUPON_COPIED=66]="PINTEREST_COUPON_COPIED",e[e.PINTEREST_CASHBACK_ACTIVATED=67]="PINTEREST_CASHBACK_ACTIVATED",e[e.PINTEREST_VIEW_PRICE_HISTORY=68]="PINTEREST_VIEW_PRICE_HISTORY",e[e.PACKAGE_TRACKING_EXPAND_SECTION=69]="PACKAGE_TRACKING_EXPAND_SECTION",e[e.PACKAGE_TRACKING_COLLAPSE_SECTION=70]="PACKAGE_TRACKING_COLLAPSE_SECTION",e[e.PACKAGE_TRACKING_TRACK_ORDER_OPT_IN=71]="PACKAGE_TRACKING_TRACK_ORDER_OPT_IN",e[e.PACKAGE_TRACKING_TRACK_ORDER_DO_NOT_TRACK=72]="PACKAGE_TRACKING_TRACK_ORDER_DO_NOT_TRACK",e[e.PACKAGE_TRACKING_CARD_CLICKED=73]="PACKAGE_TRACKING_CARD_CLICKED",e[e.PACKAGE_TRACKING_SEE_MORE=74]="PACKAGE_TRACKING_SEE_MORE",e[e.SUSTAINABILITY_LANDING_FULL_LEARN_MORE=75]="SUSTAINABILITY_LANDING_FULL_LEARN_MORE",e[e.SUSTAINABILITY_LANDING_FOOTER_LEARN_MORE=76]="SUSTAINABILITY_LANDING_FOOTER_LEARN_MORE",e[e.SUSTAINABILITY_PURCHASE_CONFIRMATION_LEARN_MORE=77]="SUSTAINABILITY_PURCHASE_CONFIRMATION_LEARN_MORE",e[e.SUSTAINABILITY_PURCHASE_CONFIRMATION_SHOW_PRODUCTS=78]="SUSTAINABILITY_PURCHASE_CONFIRMATION_SHOW_PRODUCTS",e[e.SUSTAINABILITY_PURCHASE_CONFIRMATION_SOCIAL_SHARE=79]="SUSTAINABILITY_PURCHASE_CONFIRMATION_SOCIAL_SHARE",e[e.NTP_RIGHT_ARROW=80]="NTP_RIGHT_ARROW",e[e.NTP_LEFT_ARROW=81]="NTP_LEFT_ARROW",e[e.NTP_SETTINGS_MENU=82]="NTP_SETTINGS_MENU",e[e.NTP_HIDE_SHOPPING_CARD=83]="NTP_HIDE_SHOPPING_CARD",e[e.NTP_DISABLE_REMINDERS=84]="NTP_DISABLE_REMINDERS",e[e.NTP_MANAGE=85]="NTP_MANAGE",e[e.NTP_MORE_SETTINGS=86]="NTP_MORE_SETTINGS",e[e.NTP_REBATES_REDEEM=87]="NTP_REBATES_REDEEM",e[e.NTP_REBATES_EXPLORE_RETAILERS=88]="NTP_REBATES_EXPLORE_RETAILERS",e[e.NTP_CART_NAVIGATE_TO_CART=89]="NTP_CART_NAVIGATE_TO_CART",e[e.NTP_CART_EXPLORE_MORE=90]="NTP_CART_EXPLORE_MORE",e[e.NTP_CART_VIEW_PRODUCT=91]="NTP_CART_VIEW_PRODUCT",e[e.NTP_CART_FORGET_PRODUCT=92]="NTP_CART_FORGET_PRODUCT",e[e.NTP_DROP_VIEW_PRODUCT=93]="NTP_DROP_VIEW_PRODUCT",e[e.NTP_DROP_FORGET_PRODUCT=94]="NTP_DROP_FORGET_PRODUCT",e[e.NTP_DROP_SEE_MORE=95]="NTP_DROP_SEE_MORE",e[e.NTP_RETAILERS_VIEW_RETAILER=96]="NTP_RETAILERS_VIEW_RETAILER",e[e.NTP_RETAILERS_EXPLORE_MORE=97]="NTP_RETAILERS_EXPLORE_MORE",e[e.NTP_OFFER_BUY_NOW=98]="NTP_OFFER_BUY_NOW",e[e.PWILO_NOTIFICATION_PRICE_DROP_DELETE=99]="PWILO_NOTIFICATION_PRICE_DROP_DELETE",e[e.PWILO_NOTIFICATION_PRICE_DROP_DISABLE_REMINDERS=100]="PWILO_NOTIFICATION_PRICE_DROP_DISABLE_REMINDERS",e[e.EXPRESS_CHECKOUT_ZIP_LEARN_MORE_LINK_CLICKED=101]="EXPRESS_CHECKOUT_ZIP_LEARN_MORE_LINK_CLICKED",e[e.EXPRESS_CHECKOUT_ZIP_PREFERENCE_LINK_CLICKED=102]="EXPRESS_CHECKOUT_ZIP_PREFERENCE_LINK_CLICKED",e[e.ATTAINABLE_COUPON_CONTINUE=103]="ATTAINABLE_COUPON_CONTINUE",e[e.ATTAINABLE_COUPON_CLICK=104]="ATTAINABLE_COUPON_CLICK",e[e.ATTAINABLE_COUPON_VIEWED=105]="ATTAINABLE_COUPON_VIEWED",e[e.REWARD_LINK_CLICK=106]="REWARD_LINK_CLICK",e[e.SNOOZE_FEATURE=107]="SNOOZE_FEATURE",e[e.MORE_MENU_OPENED=108]="MORE_MENU_OPENED",e[e.FEEDBACK_THUMBS_DOWN=109]="FEEDBACK_THUMBS_DOWN",e[e.FEEDBACK_THUMBS_UP=110]="FEEDBACK_THUMBS_UP",e[e.CLICK_ITEMIZED_CASHBACK_SEE_ALL=111]="CLICK_ITEMIZED_CASHBACK_SEE_ALL",e[e.ACTIVATE_CLICK_ITEMIZED_CASHBACK=112]="ACTIVATE_CLICK_ITEMIZED_CASHBACK",e[e.ACTIVATED_CLICK_ITEMIZED_CASHBACK=113]="ACTIVATED_CLICK_ITEMIZED_CASHBACK",e[e.HOVER_INFO_ICON_ITEMIZED_CASHBACK=114]="HOVER_INFO_ICON_ITEMIZED_CASHBACK",e[e.CLICK_DISCLAIMER_ITEMIZED_CASHBACK=115]="CLICK_DISCLAIMER_ITEMIZED_CASHBACK",e[e.REMIND_ME_LATER=116]="REMIND_ME_LATER",e[e.SHOPRUNNER_SIGNUP_CLICK=117]="SHOPRUNNER_SIGNUP_CLICK",e[e.SHOPRUNNER_SEEMORE=118]="SHOPRUNNER_SEEMORE",e[e.SHOPRUNNER_DETAILS=119]="SHOPRUNNER_DETAILS",e[e.NTP_TOP_SITES_HOVER=120]="NTP_TOP_SITES_HOVER",e[e.NTP_TOP_SITES_CART_PRODUCT=121]="NTP_TOP_SITES_CART_PRODUCT",e[e.NTP_TOP_SITES_CART_BUTTON=122]="NTP_TOP_SITES_CART_BUTTON",e[e.NTP_TOP_SITES_PRICE_DROP_PRODUCT=123]="NTP_TOP_SITES_PRICE_DROP_PRODUCT",e[e.NTP_TOP_SITES_STORE_CASHBACK=124]="NTP_TOP_SITES_STORE_CASHBACK",e[e.FEED_TRENDING_OFFERS=125]="FEED_TRENDING_OFFERS",e[e.FEED_TRENDING_OFFERS_SHOW_MORE=126]="FEED_TRENDING_OFFERS_SHOW_MORE",e[e.FEED_DAILY_DEALS=127]="FEED_DAILY_DEALS",e[e.FEED_DAILY_DEALS_SHOW_MORE=128]="FEED_DAILY_DEALS_SHOW_MORE",e[e.FEED_INFINITE_CATEGORY=129]="FEED_INFINITE_CATEGORY",e[e.FEED_INFINITE_CATEGORY_SHOW_MORE=130]="FEED_INFINITE_CATEGORY_SHOW_MORE",e[e.SWITCH_TO_TAB1=131]="SWITCH_TO_TAB1",e[e.SWITCH_TO_TAB2=132]="SWITCH_TO_TAB2",e[e.GO_TO_ABANDONED_CART=136]="GO_TO_ABANDONED_CART",e[e.PRODUCT_IN_CART_CLICK=137]="PRODUCT_IN_CART_CLICK",e[e.PRODUCT_TRACKED_STOCK=138]="PRODUCT_TRACKED_STOCK",e[e.PRODUCT_TRACKED_PRICE=139]="PRODUCT_TRACKED_PRICE",e[e.PRODUCT_TRACKED_STOCK_SETTINGS=140]="PRODUCT_TRACKED_STOCK_SETTINGS",e[e.PRODUCT_TRACKED_PRICE_SETTINGS=141]="PRODUCT_TRACKED_PRICE_SETTINGS",e[e.PRODUCT_TRACKING_PRODUCT_NOTIFICATION_CLICK=142]="PRODUCT_TRACKING_PRODUCT_NOTIFICATION_CLICK",e[e.PRODUCT_TRACKING_PRODUCT_COLLECTIONS_CLICK=143]="PRODUCT_TRACKING_PRODUCT_COLLECTIONS_CLICK",e[e.PRODUCT_TRACKING_PRODUCT_NOTIFICATION_UNTRACK_CLICK=144]="PRODUCT_TRACKING_PRODUCT_NOTIFICATION_UNTRACK_CLICK",e[e.PRODUCT_TRACKING_PRODUCT_COLLECTIONS_UNTRACK_CLICK=145]="PRODUCT_TRACKING_PRODUCT_COLLECTIONS_UNTRACK_CLICK",e[e.SEE_ALL_TRENDING_DEALS=146]="SEE_ALL_TRENDING_DEALS",e[e.NAVIGATE_TO_TRENDING_DEAL=147]="NAVIGATE_TO_TRENDING_DEAL",e[e.INPUT_COUPON=148]="INPUT_COUPON",e[e.SUBMIT_COUPON=149]="SUBMIT_COUPON",e[e.AWARENESS_SEE_MORE=150]="AWARENESS_SEE_MORE",e[e.CLICK_SPB_CASHBACK_SEE_MORE=151]="CLICK_SPB_CASHBACK_SEE_MORE",e[e.ACTIVATE_CLICK_SPB_CASHBACK=152]="ACTIVATE_CLICK_SPB_CASHBACK",e[e.ACTIVATED_CLICK_SPB_CASHBACK=153]="ACTIVATED_CLICK_SPB_CASHBACK",e[e.HOVER_INFO_ICON_SPB_CASHBACK=154]="HOVER_INFO_ICON_SPB_CASHBACK",e[e.CLICK_DISCLAIMER_SPB_CASHBACK=155]="CLICK_DISCLAIMER_SPB_CASHBACK",e[e.OMNIBOX_HOVER_SUGGESTION_MATCH=156]="OMNIBOX_HOVER_SUGGESTION_MATCH",e[e.OMNIBOX_HOVER_HISTORY_MATCH=157]="OMNIBOX_HOVER_HISTORY_MATCH",e[e.OMNIBOX_CLICK_SUGGESTION_MATCH=158]="OMNIBOX_CLICK_SUGGESTION_MATCH",e[e.OMNIBOX_CLICK_HISTORY_MATCH=159]="OMNIBOX_CLICK_HISTORY_MATCH",e[e.OMNIBOX_REMOVE_SUGGESTION_MATCH=160]="OMNIBOX_REMOVE_SUGGESTION_MATCH",e[e.OMNIBOX_REMOVE_HISTORY_MATCH=161]="OMNIBOX_REMOVE_HISTORY_MATCH",e[e.CLICK_BEST_COUPON=162]="CLICK_BEST_COUPON",e[e.SEE_MORE_TRENDING_COUPONS=163]="SEE_MORE_TRENDING_COUPONS",e[e.PRODUCT_TRACKING_NOTIFICATION_TRACK=164]="PRODUCT_TRACKING_NOTIFICATION_TRACK",e[e.PRODUCT_TRACKING_NOTIFICATION_UNTRACK=165]="PRODUCT_TRACKING_NOTIFICATION_UNTRACK",e[e.PRODUCT_TRACKING_COLLECTIONS_RECENT_SEE_MORE_CLICK=166]="PRODUCT_TRACKING_COLLECTIONS_RECENT_SEE_MORE_CLICK",e[e.PRODUCT_TRACKING_COLLECTIONS_TRACKED_PRODUCT_SEE_MORE_CLICK=167]="PRODUCT_TRACKING_COLLECTIONS_TRACKED_PRODUCT_SEE_MORE_CLICK",e[e.PRODUCT_TRACKING_COLLECTIONS_TAB_SWITCH_1=168]="PRODUCT_TRACKING_COLLECTIONS_TAB_SWITCH_1",e[e.PRODUCT_TRACKING_COLLECTIONS_TAB_SWITCH_2=169]="PRODUCT_TRACKING_COLLECTIONS_TAB_SWITCH_2",e[e.PRODUCT_TRACKING_COLLECTIONS_TAB_SWITCH_3=170]="PRODUCT_TRACKING_COLLECTIONS_TAB_SWITCH_3",e[e.PRODUCT_TRACKED_STOCK_UNTRACK=171]="PRODUCT_TRACKED_STOCK_UNTRACK",e[e.PRODUCT_TRACKED_PRICE_UNTRACK=172]="PRODUCT_TRACKED_PRICE_UNTRACK",e[e.NOTIFICATION_MOMENT_IN_TIME=173]="NOTIFICATION_MOMENT_IN_TIME",e[e.FEED_MOMENT_IN_TIME=174]="FEED_MOMENT_IN_TIME",e[e.OPEN_PANE_FROM_FLYOUT=175]="OPEN_PANE_FROM_FLYOUT",e[e.INBOX_COUPONS_SIGN_IN_EDGE=176]="INBOX_COUPONS_SIGN_IN_EDGE",e[e.INBOX_COUPONS_CONNECT_OUTLOOK_INBOX=177]="INBOX_COUPONS_CONNECT_OUTLOOK_INBOX",e[e.INBOX_COUPONS_CONNECT_GMAIL_INBOX=178]="INBOX_COUPONS_CONNECT_GMAIL_INBOX",e[e.INBOX_COUPONS_RECONNECT_INBOX=179]="INBOX_COUPONS_RECONNECT_INBOX",e[e.INBOX_COUPONS_COPY_COUPON=180]="INBOX_COUPONS_COPY_COUPON",e[e.INBOX_COUPONS_DISCONNECT_INBOX=181]="INBOX_COUPONS_DISCONNECT_INBOX",e[e.AUTOS_MARKETPLACE_TITLE_CLICK=182]="AUTOS_MARKETPLACE_TITLE_CLICK",e[e.AUTOS_MARKETPLACE_LISTING_HOVER=183]="AUTOS_MARKETPLACE_LISTING_HOVER",e[e.AUTOS_MARKETPLACE_RECOMMENDATION_CLICK=184]="AUTOS_MARKETPLACE_RECOMMENDATION_CLICK",e[e.AUTOS_MARKETPLACE_SEE_MORE_CLICK=185]="AUTOS_MARKETPLACE_SEE_MORE_CLICK",e[e.AUTOS_PRICE_INSIGHT_HOVER=186]="AUTOS_PRICE_INSIGHT_HOVER",e[e.AUTOS_PRICE_INSIGHT_SEE_MORE_CLICK=187]="AUTOS_PRICE_INSIGHT_SEE_MORE_CLICK",e[e.AUTOS_MARKETPLACE_RATING_REVIEW_HOVER=188]="AUTOS_MARKETPLACE_RATING_REVIEW_HOVER",e[e.WALLET_HUB_NAVIGATION=189]="WALLET_HUB_NAVIGATION",e[e.PAYMENT_OPTIONS_EXPAND_SECTION=190]="PAYMENT_OPTIONS_EXPAND_SECTION",e[e.PAYMENT_OPTIONS_COLLAPSE_SECTION=191]="PAYMENT_OPTIONS_COLLAPSE_SECTION",e[e.CLICK_PCB_CROSS_SESSION=192]="CLICK_PCB_CROSS_SESSION",e[e.REWARD_JOIN_NOW=193]="REWARD_JOIN_NOW",e[e.REWARD_MAYBE_LATER=194]="REWARD_MAYBE_LATER",e[e.REWARD_DISMISS=195]="REWARD_DISMISS",e[e.FEED_BUY_DIRECT=196]="FEED_BUY_DIRECT",e[e.FEED_BUY_DIRECT_SHOW_MORE=197]="FEED_BUY_DIRECT_SHOW_MORE",e[e.SNOOZED=198]="SNOOZED",e[e.EXPRESS_CHECKOUT_WITHOUT_PAYMENT=199]="EXPRESS_CHECKOUT_WITHOUT_PAYMENT",e[e.ITEMIZED_CASHBACK_ADD_TO_CART=200]="ITEMIZED_CASHBACK_ADD_TO_CART",e[e.DELETE_TRACKER=201]="DELETE_TRACKER",e[e.FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB=202]="FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB",e[e.FEED_NATIVE_ADS=203]="FEED_NATIVE_ADS",e[e.FEED_NATIVE_ADS_SHOW_MORE=204]="FEED_NATIVE_ADS_SHOW_MORE",e[e.FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB_SHOW_MORE=205]="FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB_SHOW_MORE",e[e.AUTOS_PRICE_INSIGHT_RATINGURL_CLICK=207]="AUTOS_PRICE_INSIGHT_RATINGURL_CLICK",e[e.AUTOS_REVIEWS_VIDEO_CLICK=208]="AUTOS_REVIEWS_VIDEO_CLICK",e[e.AUTOS_REVIEWS_VIDEO_SEE_MORE_CLICK=209]="AUTOS_REVIEWS_VIDEO_SEE_MORE_CLICK",e[e.GROCERY_CASHBACK_SINGIN_CLICKED=210]="GROCERY_CASHBACK_SINGIN_CLICKED",e[e.MS_CASHBACK_ACCOUNT_CLICKED=211]="MS_CASHBACK_ACCOUNT_CLICKED",e[e.FEED_INFINITE_CATEGORY_AD=212]="FEED_INFINITE_CATEGORY_AD",e[e.FEED_INFINITE_CATEGORY_AD_SHOW_MORE=213]="FEED_INFINITE_CATEGORY_AD_SHOW_MORE",e[e.GOODRX_SELECT_CLICK=214]="GOODRX_SELECT_CLICK",e[e.GOODRX_DEALS_CLICK=215]="GOODRX_DEALS_CLICK",e[e.GOODRX_TERMS_CLICK=216]="GOODRX_TERMS_CLICK",e[e.GOODRX_PRINT_CLICK=217]="GOODRX_PRINT_CLICK",e[e.GOODRX_TEXT_CLICK=218]="GOODRX_TEXT_CLICK",e[e.GOODRX_EMAIL_CLICK=219]="GOODRX_EMAIL_CLICK",e[e.FEED_VISUAL_SEARCH=220]="FEED_VISUAL_SEARCH",e[e.FEED_VISUAL_SEARCH_SHOW_MORE=221]="FEED_VISUAL_SEARCH_SHOW_MORE",e[e.FEED_SIMILAR_OFFERS=222]="FEED_SIMILAR_OFFERS",e[e.FEED_SIMILAR_OFFERS_SHOW_MORE=223]="FEED_SIMILAR_OFFERS_SHOW_MORE",e[e.FEED_SEARCH_RESULTS=224]="FEED_SEARCH_RESULTS",e[e.FEED_SEARCH_RESULTS_SHOW_MORE=225]="FEED_SEARCH_RESULTS_SHOW_MORE",e[e.GOODRX_CREATE_ACCOUNT_CLICK=226]="GOODRX_CREATE_ACCOUNT_CLICK",e[e.GOODRX_SEND_COUPON_CLICK=227]="GOODRX_SEND_COUPON_CLICK",e[e.GOODRX_ENTER_INPUT=228]="GOODRX_ENTER_INPUT",e[e.GOODRX_CANCEL_CLICK=229]="GOODRX_CANCEL_CLICK",e[e.FETCH_SEARCH_RESULTS=230]="FETCH_SEARCH_RESULTS",e[e.SEARCH_BOX_FOCUSED=231]="SEARCH_BOX_FOCUSED",e[e.CJK_OPEN_FLYOUT=232]="CJK_OPEN_FLYOUT",e[e.CJK_OPEN_PANE_FROM_FLYOUT=233]="CJK_OPEN_PANE_FROM_FLYOUT",e[e.CJK_OPEN_PANE_FROM_SIDEBAR=234]="CJK_OPEN_PANE_FROM_SIDEBAR",e[e.CJK_SCROLL_PAGE=235]="CJK_SCROLL_PAGE",e[e.CJK_SWITCH_TO_TAB1=236]="CJK_SWITCH_TO_TAB1",e[e.CJK_SWITCH_TO_TAB2=237]="CJK_SWITCH_TO_TAB2",e[e.CJK_COUPONS_CLICK=238]="CJK_COUPONS_CLICK",e[e.CJK_COUPONS_SEE_MORE=239]="CJK_COUPONS_SEE_MORE",e[e.CJK_VIEW_PRICE_HISTORY=240]="CJK_VIEW_PRICE_HISTORY",e[e.CJK_PRICE_HISTORY_SET_TIMERANGE=241]="CJK_PRICE_HISTORY_SET_TIMERANGE",e[e.CJK_PRICE_COMPARISON_CLICK=242]="CJK_PRICE_COMPARISON_CLICK",e[e.CJK_CLICK_PRICE_COMPARISON_SEE_MORE=243]="CJK_CLICK_PRICE_COMPARISON_SEE_MORE",e[e.CJK_SIMILAR_PRODUCTS_CLICK=244]="CJK_SIMILAR_PRODUCTS_CLICK",e[e.CJK_ACTIVITY_CLICK=245]="CJK_ACTIVITY_CLICK",e[e.CJK_ACTIVITY_SEE_MORE=246]="CJK_ACTIVITY_SEE_MORE",e[e.CJK_TRENDING_PRODUCTS_CLICK=247]="CJK_TRENDING_PRODUCTS_CLICK",e[e.CJK_TRENDING_PRODUCTS_SET_CATEGORY=248]="CJK_TRENDING_PRODUCTS_SET_CATEGORY",e[e.CJK_TRENDING_PRODUCTS_SET_RETAILER=249]="CJK_TRENDING_PRODUCTS_SET_RETAILER",e[e.GO_TO_WIN_CART=250]="GO_TO_WIN_CART",e[e.SWITCH_TO_TAB3=251]="SWITCH_TO_TAB3",e[e.SCROLL_TO_TAB1=252]="SCROLL_TO_TAB1",e[e.SCROLL_TO_TAB2=253]="SCROLL_TO_TAB2",e[e.SCROLL_TO_TAB3=254]="SCROLL_TO_TAB3",e[e.FEED_CAMPAIGN_SHOW_MORE=256]="FEED_CAMPAIGN_SHOW_MORE",e[e.AX_SHOPPING_NAV_TRY_NOW_CLICK=257]="AX_SHOPPING_NAV_TRY_NOW_CLICK",e[e.TRY_PRODUCT_BEST_COUPON=258]="TRY_PRODUCT_BEST_COUPON",e[e.PRODUCT_TRACKING_COLLECTIONS_TRACK_CLICK=262]="PRODUCT_TRACKING_COLLECTIONS_TRACK_CLICK",e[e.PRODUCT_TRACKING_COLLECTIONS_VIEW_STEPS=263]="PRODUCT_TRACKING_COLLECTIONS_VIEW_STEPS",e[e.PRODUCT_TRACKING_COLLECTIONS_START_TRACKING=264]="PRODUCT_TRACKING_COLLECTIONS_START_TRACKING",e[e.PRODUCT_TRACKED_VIEW_TRACKED_PRODUCTS=265]="PRODUCT_TRACKED_VIEW_TRACKED_PRODUCTS",e[e.PRODUCT_TRACKING_ABANDONED_CART_TRACK_CLICK=266]="PRODUCT_TRACKING_ABANDONED_CART_TRACK_CLICK",e[e.PRODUCT_TRACKING_ABANDONED_CART_UNTRACK_CLICK=267]="PRODUCT_TRACKING_ABANDONED_CART_UNTRACK_CLICK",e[e.REBATES_VIEW_IN_PANE=268]="REBATES_VIEW_IN_PANE",e[e.AUTOS_MYGARAGE_TITLE_CLICK=269]="AUTOS_MYGARAGE_TITLE_CLICK",e[e.AUTOS_MYGARAGE_HOVER=270]="AUTOS_MYGARAGE_HOVER",e[e.AUTOS_MYGARAGE_MODULE_CLICK=271]="AUTOS_MYGARAGE_MODULE_CLICK",e[e.AUTOS_MARKETPLACE_MYGARAGE_CHECK_NOW=272]="AUTOS_MARKETPLACE_MYGARAGE_CHECK_NOW",e[e.PRICE_MATCH_OPT_IN=273]="PRICE_MATCH_OPT_IN",e[e.PRICE_MATCH_OPT_OUT=274]="PRICE_MATCH_OPT_OUT",e[e.PRICE_MATCH_CARD_CLICK=275]="PRICE_MATCH_CARD_CLICK",e[e.PRICE_MATCH_CARD_CTA_CLICK=276]="PRICE_MATCH_CARD_CTA_CLICK",e[e.PRICE_MATCH_NOTIFICATION_CTA_CLICK=277]="PRICE_MATCH_NOTIFICATION_CTA_CLICK",e[e.PRICE_COMPARISON_COMPONENT_CLICK=278]="PRICE_COMPARISON_COMPONENT_CLICK",e[e.DISCOVER_NOTIFICATION_CLICK=279]="DISCOVER_NOTIFICATION_CLICK",e[e.PRODUCT_TRACKING_COLLECTIONS_SIGN_IN=280]="PRODUCT_TRACKING_COLLECTIONS_SIGN_IN",e[e.PRODUCT_TRACKING_COLLECTIONS_SIGN_IN_CLOSE=281]="PRODUCT_TRACKING_COLLECTIONS_SIGN_IN_CLOSE",e[e.PRODUCT_TRACKING_COLLECTIONS_ROAM=282]="PRODUCT_TRACKING_COLLECTIONS_ROAM",e[e.PRODUCT_TRACKING_COLLECTIONS_ROAM_CLOSE=283]="PRODUCT_TRACKING_COLLECTIONS_ROAM_CLOSE",e[e.FEED_RELATED_PRODUCTS=284]="FEED_RELATED_PRODUCTS",e[e.FEED_RELATED_PRODUCTS_SHOW_MORE=285]="FEED_RELATED_PRODUCTS_SHOW_MORE",e[e.VIEW_PRODUCT_SUMMARY_CARD=286]="VIEW_PRODUCT_SUMMARY_CARD",e[e.PRODUCT_TRACKING_SUMMARY_CARD=287]="PRODUCT_TRACKING_SUMMARY_CARD",e[e.TRY_BGAA_BEST_COUPON=288]="TRY_BGAA_BEST_COUPON",e[e.CJK_COUPONS_CHECK_COUPON=289]="CJK_COUPONS_CHECK_COUPON",e[e.TRAVEL_CHEAPER_FLIGHTS_CLICK=290]="TRAVEL_CHEAPER_FLIGHTS_CLICK",e[e.TRAVEL_CHEAPER_HOTEL_CLICK=291]="TRAVEL_CHEAPER_HOTEL_CLICK",e[e.BUYING_OPTIONS_FILTERCHANGE=292]="BUYING_OPTIONS_FILTERCHANGE",e[e.BUYING_OPTIONS_RETAILER_HOVER=293]="BUYING_OPTIONS_RETAILER_HOVER",e}({})},2388:function(e,t,i){"use strict";i.d(t,{L:function(){return o},r:function(){return n}});let n=function(e){return e.COUPONS_AVAILABLE="COUPONS_AVAILABLE",e.COUPONS_AUTO_APPLY="COUPONS_AUTO_APPLY",e.COUPONS_CLIPPING="COUPONS_CLIPPING",e.SIMILAR_OFFERS="SIMILAR_OFFERS",e.PRICE_COMPARE_LOWER_PRICES="PRICE_COMPARE_LOWER_PRICES",e.PRICE_COMPARE_BEST_PRICE="PRICE_COMPARE_BEST_PRICE",e.REBATES_ACTIVATE_CASHBACK="REBATES_ACTIVATE_CASHBACK",e.REBATES_BING_CONFIRMATION="REBATES_BING_CONFIRMATION",e.PRICE_HISTORY_DROP="PRICE_HISTORY_DROP",e.PRICE_DROP_PLUS_COUPONS="PRICE_DROP_PLUS_COUPONS",e.PRICE_DROP_PLUS_CASHBACK="PRICE_DROP_PLUS_CASHBACK",e.CASHBACK_PLUS_COUPONS="CASHBACK_PLUS_COUPONS",e.LOWER_PRICE_PLUS_CASHBACK_PLUS_COUPONS="LOWER_PRICE_PLUS_CASHBACK_PLUS_COUPONS",e.PRICE_HISTORY_STABLE="PRICE_HISTORY_STABLE",e.PRICE_HISTORY_INCREASE="PRICE_HISTORY_INCREASE",e.PRICE_HISTORY_NO_INSIGHT="PRICE_HISTORY_NO_INSIGHT",e.DEALS="DEALS",e.PROFESSIONAL_REVIEWS="PROFESSIONAL_REVIEWS",e.VIDEO_REVIEWS="VIDEO_REVIEWS",e.RECOMMENDATIONS="RECOMMENDATIONS",e.ACTIVATE_CASHBACK_NEW="ACTIVATE_CASHBACK_NEW",e.EXPRESS_CHECKOUT="EXPRESS_CHECKOUT",e.ACTIVATE_REWARDS_NEW="ACTIVATE_REWARDS_NEW",e.OTHER_SELLER="OTHER_SELLER",e.PRODUCT_HISTORY="PRODUCT_HISTORY",e.PAYMENT_OPTIONS="PAYMENT_OPTIONS",e.TIPS="TIPS",e.PACKAGE_TRACKING_OPT_IN="PACKAGE_TRACKING_OPT_IN",e.PACKAGE_TRACKING_STATUS_VIEW="PACKAGE_TRACKING_STATUS_VIEW",e.PINTEREST_COUPONS_AVAILABLE="PINTEREST_COUPONS_AVAILABLE",e.PINTEREST_PRICE_HISTORY_DROP="PINTEREST_PRICE_HISTORY_DROP",e.PINTEREST_PRICE_HISTORY_INCREASE="PINTEREST_PRICE_HISTORY_INCREASE",e.PINTEREST_PRICE_HISTORY_STABLE="PINTEREST_PRICE_HISTORY_STABLE",e.PINTEREST_REBATES_ACTIVATE_CASHBACK="PINTEREST_REBATES_ACTIVATE_CASHBACK",e.CASHBACK_RETAILER="CASHBACK_RETAILER",e.GROCERY_PRINT_COUPONS="GROCERY_PRINT_COUPONS",e.GROCERY_DIGITAL_COUPONS="GROCERY_DIGITAL_COUPONS",e.PWILO_NOTIFICATION_PRICE_DROP="PWILO_NOTIFICATION_PRICE_DROP",e.SUSTAINABILITY_LANDING_FULL="SUSTAINABILITY_LANDING_FULL",e.SUSTAINABILITY_LANDING_FOOTER="SUSTAINABILITY_LANDING_FOOTER",e.SUSTAINABILITY_PURCHASE_CONFIRMATION="SUSTAINABILITY_PURCHASE_CONFIRMATION",e.ATTAINABLE_COUPONS="ATTAINABLE_COUPONS",e.COUPON_ATTAINED="COUPON_ATTAINED",e.ATTAINABLE_COUPONS_OVERLAY="ATTAINABLE_COUPONS_OVERLAY",e.ITEMIZED_CASHBACK="ITEMIZED_CASHBACK",e.FEED_TRENDING_OFFERS="FEED_TRENDING_OFFERS",e.FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB="FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB",e.FEED_DAILY_DEALS="FEED_DAILY_DEALS",e.FEED_INFINITE_CATEGORY="FEED_INFINITE_CATEGORY",e.FEED_MOMENT_IN_TIME="FEED_MOMENT_IN_TIME",e.AUTOS_MARKETPLACE="AUTOS_MARKETPLACE",e.AUTOS_PRICE_INSIGHT="AUTOS_PRICE_INSIGHT",e.AUTOS_INCENTIVES="AUTOS_INCENTIVES",e.ABANDONED_CART="ABANDONED_CART",e.AWARENESS="AWARENESS",e.PRODUCT_TRACKING_STOCK="PRODUCT_TRACKING_STOCK",e.PRODUCT_TRACKING_PRICE="PRODUCT_TRACKING_PRICE",e.PRODUCT_TRACKING_NOTIFICATION="PRODUCT_TRACKING_NOTIFICATION",e.PRODUCT_TRACKING_COLLECTIONS="PRODUCT_TRACKING_COLLECTIONS",e.SHOPPING_TRIPS="SHOPPING_TRIPS",e.VIEW_BEST_COUPON_MODULE="VIEW_BEST_COUPON_MODULE",e.INBOX_COUPONS="INBOX_COUPONS",e.ACTIVE_RETAILER_INBOX_COUPONS="ACTIVE_RETAILER_INBOX_COUPONS",e.PRODUCT_TRACKING_OUT_OF_STOCK_NOTIFICATION="PRODUCT_TRACKING_OUT_OF_STOCK_NOTIFICATION",e.PRODUCT_TRACKING_OFFERS_COUPON_NOTIFICATION="PRODUCT_TRACKING_OFFERS_COUPON_NOTIFICATION",e.PRODUCT_TRACKING_BACK_IN_STOCK_NOTIFICATION="PRODUCT_TRACKING_BACK_IN_STOCK_NOTIFICATION",e.PRODUCT_BEST_COUPON="PRODUCT_BEST_COUPON",e.PRODUCT_TRACKING_ALERT="PRODUCT_TRACKING_ALERT",e.ABANDONED_CART_NOTIFICATION_COUPONS="ABANDONED_CART_NOTIFICATION_COUPONS",e.REWARD_GIFT_CARD="REWARD_GIFT_CARD",e.YOUTUBE_COUPONS_RETAILER="YOUTUBE_COUPONS_RETAILER",e.YOUTUBE_COUPONS_RETAILER_CHECKOUT="YOUTUBE_COUPONS_RETAILER_CHECKOUT",e.YOUTUBE_COUPONS_HOME="YOUTUBE_COUPONS_HOME",e.YOUTUBE_COUPONS_VIDEO="YOUTUBE_COUPONS_VIDEO",e.SAN_CONSENT_NOTIFICATION="SAN_CONSENT_NOTIFICATION",e.FEED_BUY_DIRECT="FEED_BUY_DIRECT",e.CODEX_CHAT="CODEX_CHAT",e.AX_SHOPPING_NAV="AX_SHOPPING_NAV",e.INSTANT_ADD_TO_CART_OVERLAY="INSTANT_ADD_TO_CART_OVERLAY",e.SEARCH_RESULTS="SEARCH_RESULTS",e.FEED_VISUAL_SEARCH="FEED_VISUAL_SEARCH",e.FEED_RELATED_PRODUCTS="FEED_RELATED_PRODUCTS",e.FEED_NATIVE_ADS="FEED_NATIVE_ADS",e.DISCOVER_SHOPPING="DISCOVER_SHOPPING",e.DISCOVER_CHAT_CHIPS="DISCOVER_CHAT_CHIPS",e.SHOPPING_CHIPS="SHOPPING_CHIPS",e.SMART_COMPARE="SMART_COMPARE",e.PRODUCT_SUMMARY="PRODUCT_SUMMARY",e.PRODUCT_SUMMARY_CARD="PRODUCT_SUMMARY_CARD",e.BUYING_GUIDES="BUYING_GUIDES",e.USER_INSIGHTS="USER_INSIGHTS",e.EXPERT_INSIGHTS="EXPERT_INSIGHTS",e.WIN_CART="WIN_CART",e.DISCOVER_CHAT="DISCOVER_CHAT",e.SAFARI_FIRST_RUN_EXPERIENCE="SAFARI_FIRST_RUN_EXPERIENCE",e.SIDEPANE_CASHBACK="SIDEPANE_CASHBACK",e.CAMPAIGN_PDP_CASHBACK="CAMPAIGN_PDP_CASHBACK",e.CAMPAIGN_BANNER="CAMPAIGN_BANNER",e.FEED_CAMPAIGN="FEED_CAMPAIGN ",e.CAMPAIGN_PDP_CASHBACK_NOTIFICATION="CAMPAIGN_PDP_CASHBACK_NOTIFICATION",e.CAMPAIGN_AWARENESS_NOTIFICATION="CAMPAIGN_AWARENESS_NOTIFICATION",e.CJK_SIMILAR_PRODUCTS="CJK_SIMILAR_PRODUCTS",e.WISHLIST="WISHLIST ",e.MENU="MENU",e.FOOTER="FOOTER",e.EDGE_OVERLAY="OVERLAY",e.EXTENSION_POPUP="EXTENSION_POPUP",e.EXTENSION_AUTOAPPLY="EXTENSION_AUTOAPPLY",e.BELL_ICON="BELL_ICON",e.BANNER="BANNER",e.SEARCH_IN_PANE="SEARCH_IN_PANE",e.ENROLL_TO_CASHBACK_CONFIRMATION_NOTIFICATION="ENROLL_TO_CASHBACK_CONFIRMATION_NOTIFICATION",e.POST_PURCHASE_CONSENT_NOTIFICATION="POST_PURCHASE_CONSENT_NOTIFICATION",e.SEARCHBOXDEMO_NOTIFICATION="SEARCHBOXDEMO_NOTIFICATION",e.PRICE_MATCH_PRICE_DROP_NOTIFICATION="PRICE_MATCH_PRICE_DROP_NOTIFICATION",e.INBOX_PRICE_MATCH_PRICE_DROP_NOTIFICATION="INBOX_PRICE_MATCH_PRICE_DROP_NOTIFICATION",e.TRAVEL_CHEAPER_FLIGHT_NOTIFICATION="TRAVEL_CHEAPER_FLIGHT_NOTIFICATION",e.DISCOVER_NOTIFICATION="DISCOVER_NOTIFICATION",e.AX_SHOPPING_NAV_NOTIFICATION="AX_SHOPPING_NAV_NOTIFICATION",e.ARTICLES_CASHBACK="ARTICLES_CASHBACK",e.BACKGROUND_AUTO_APPLY="BACKGROUND_AUTO_APPLY",e.TRAVEL_CHEAPER_HOTEL_NOTIFICATION="TRAVEL_CHEAPER_HOTEL_NOTIFICATION",e.POST_PURCHASE_REWARDS_NOTIFICATION="POST_PURCHASE_REWARDS_NOTIFICATION",e.CASHBACK_DASHBOARD="CASHBACK_DASHBOARD",e.BUYING_OPTIONS="BUYING_OPTIONS",e}({}),o=function(e){return e[e.COUPONS_AVAILABLE=0]="COUPONS_AVAILABLE",e[e.COUPONS_AUTO_APPLY=1]="COUPONS_AUTO_APPLY",e[e.COUPONS_CLIPPING=2]="COUPONS_CLIPPING",e[e.PRICE_COMPARE_LOWER_PRICES=3]="PRICE_COMPARE_LOWER_PRICES",e[e.PRICE_COMPARE_BEST_PRICE=4]="PRICE_COMPARE_BEST_PRICE",e[e.PRICE_COMPARE_SHOW_MORE_SELLERS=5]="PRICE_COMPARE_SHOW_MORE_SELLERS",e[e.REBATES_ACTIVATE_CASHBACK=6]="REBATES_ACTIVATE_CASHBACK",e[e.REBATES_BING_CONFIRMATION=7]="REBATES_BING_CONFIRMATION",e[e.PRICE_HISTORY_DROP=8]="PRICE_HISTORY_DROP",e[e.PRICE_HISTORY_STABLE=9]="PRICE_HISTORY_STABLE",e[e.PRICE_HISTORY_INCREASE=10]="PRICE_HISTORY_INCREASE",e[e.DEALS=11]="DEALS",e[e.PROFESSIONAL_REVIEWS=12]="PROFESSIONAL_REVIEWS",e[e.VIDEO_REVIEWS=13]="VIDEO_REVIEWS",e[e.RECOMMENDATIONS=14]="RECOMMENDATIONS",e[e.ACTIVATE_CASHBACK_NEW=15]="ACTIVATE_CASHBACK_NEW",e[e.EXPRESS_CHECKOUT=16]="EXPRESS_CHECKOUT",e[e.ACTIVATE_REWARDS_NEW=17]="ACTIVATE_REWARDS_NEW",e[e.OTHER_SELLER=18]="OTHER_SELLER",e[e.PRODUCT_HISTORY=19]="PRODUCT_HISTORY",e[e.TIPS=20]="TIPS",e[e.PAYMENT_OPTIONS=21]="PAYMENT_OPTIONS",e[e.PWILO_NOTIFICATION_PRICE_DROP=22]="PWILO_NOTIFICATION_PRICE_DROP",e[e.YOUTUBE_COUPONS_HOME=23]="YOUTUBE_COUPONS_HOME",e[e.YOUTUBE_COUPONS_VIDEO=24]="YOUTUBE_COUPONS_VIDEO",e[e.YOUTUBE_COUPONS_RETAILER=25]="YOUTUBE_COUPONS_RETAILER",e[e.YOUTUBE_COUPONS_AUTO_APPLY=27]="YOUTUBE_COUPONS_AUTO_APPLY",e[e.CASHBACK_RETAILER=28]="CASHBACK_RETAILER",e[e.GROCERY_PRINT_COUPONS=29]="GROCERY_PRINT_COUPONS",e[e.GROCERY_DIGITAL_COUPONS=30]="GROCERY_DIGITAL_COUPONS",e[e.PINTEREST_COUPONS_AVAILABLE=31]="PINTEREST_COUPONS_AVAILABLE",e[e.PINTEREST_REBATES_ACTIVATE_CASHBACK=32]="PINTEREST_REBATES_ACTIVATE_CASHBACK",e[e.PINTEREST_PRICE_HISTORY_DROP=33]="PINTEREST_PRICE_HISTORY_DROP",e[e.PINTEREST_PRICE_HISTORY_STABLE=34]="PINTEREST_PRICE_HISTORY_STABLE",e[e.PINTEREST_PRICE_HISTORY_INCREASE=35]="PINTEREST_PRICE_HISTORY_INCREASE",e[e.PACKAGE_TRACKING_OPT_IN=36]="PACKAGE_TRACKING_OPT_IN",e[e.PACKAGE_TRACKING_STATUS_VIEW=37]="PACKAGE_TRACKING_STATUS_VIEW",e[e.SUSTAINABILITY_LANDING_FOOTER=39]="SUSTAINABILITY_LANDING_FOOTER",e[e.SUSTAINABILITY_PURCHASE_CONFIRMATION=40]="SUSTAINABILITY_PURCHASE_CONFIRMATION",e[e.NTP_REBATES_SAVINGS=41]="NTP_REBATES_SAVINGS",e[e.NTP_ABANDONED_CART=42]="NTP_ABANDONED_CART",e[e.NTP_RECENTLY_VIEWED=43]="NTP_RECENTLY_VIEWED",e[e.NTP_FAVE_RETAILERS=44]="NTP_FAVE_RETAILERS",e[e.NTP_PERSONALIZED_CASHBACK=45]="NTP_PERSONALIZED_CASHBACK",e[e.PCB_VIEWED=46]="PCB_VIEWED",e[e.REWARD_GIFT_CARD=47]="REWARD_GIFT_CARD",e[e.COUPONS_AUTO_APPLY_AUTOFILL=49]="COUPONS_AUTO_APPLY_AUTOFILL",e[e.ITEMIZED_CASHBACK=50]="ITEMIZED_CASHBACK",e[e.GROCERY=51]="GROCERY",e[e.SHOPRUNNER_SIGNUP=52]="SHOPRUNNER_SIGNUP",e[e.NTP_TOP_SITES_SHOPPING_TILE=53]="NTP_TOP_SITES_SHOPPING_TILE",e[e.FEED_TRENDING_OFFERS=54]="FEED_TRENDING_OFFERS",e[e.FEED_DAILY_DEALS=55]="FEED_DAILY_DEALS",e[e.FEED_INFINITE_CATEGORY=56]="FEED_INFINITE_CATEGORY",e[e.ABANDONED_CART=57]="ABANDONED_CART",e[e.PRODUCT_TRACKING_STOCK=58]="PRODUCT_TRACKING_STOCK",e[e.PRODUCT_TRACKING_PRICE=59]="PRODUCT_TRACKING_PRICE",e[e.PRODUCT_TRACKING_NOTIFICATION=60]="PRODUCT_TRACKING_NOTIFICATION",e[e.PRODUCT_TRACKING_COLLECTIONS=61]="PRODUCT_TRACKING_COLLECTIONS",e[e.ATTAINABLE_COUPONS=62]="ATTAINABLE_COUPONS",e[e.COUPON_ATTAINED=63]="COUPON_ATTAINED",e[e.ATTAINABLE_COUPONS_OVERLAY=64]="ATTAINABLE_COUPONS_OVERLAY",e[e.COMMUNITY_COUPONS=65]="COMMUNITY_COUPONS",e[e.AWARENESS=66]="AWARENESS",e[e.OMNIBOX_COUPON_SUGGESTION_MATCH=67]="OMNIBOX_COUPON_SUGGESTION_MATCH",e[e.OMNIBOX_COUPON_HISTORY_MATCH=68]="OMNIBOX_COUPON_HISTORY_MATCH",e[e.OMNIBOX_CASHBACK_SUGGESTION_MATCH=69]="OMNIBOX_CASHBACK_SUGGESTION_MATCH",e[e.OMNIBOX_CASHBACK_HISTORY_MATCH=70]="OMNIBOX_CASHBACK_HISTORY_MATCH",e[e.VIEW_BEST_COUPON_MODULE=71]="VIEW_BEST_COUPON_MODULE",e[e.PRODUCT_TRACKING_OUT_OF_STOCK_NOTIFICATION=72]="PRODUCT_TRACKING_OUT_OF_STOCK_NOTIFICATION",e[e.PRODUCT_TRACKING_BACK_IN_STOCK_NOTIFICATION=73]="PRODUCT_TRACKING_BACK_IN_STOCK_NOTIFICATION",e[e.ABANDONED_CART_NOTIFICATION_COUPONS=74]="ABANDONED_CART_NOTIFICATION_COUPONS",e[e.INBOX_COUPONS=75]="INBOX_COUPONS",e[e.ACTIVE_RETAILER_INBOX_COUPONS=76]="ACTIVE_RETAILER_INBOX_COUPONS",e[e.AUTOS_MARKETPLACE=77]="AUTOS_MARKETPLACE",e[e.AUTOS_PRICE_INSIGHT=78]="AUTOS_PRICE_INSIGHT",e[e.SAN_CONSENT_NOTIFICATION=81]="SAN_CONSENT_NOTIFICATION",e[e.FEED_BUY_DIRECT=82]="FEED_BUY_DIRECT",e[e.FEED_MOMENT_IN_TIME=83]="FEED_MOMENT_IN_TIME",e[e.PRICE_HISTORY_NO_INSIGHT=84]="PRICE_HISTORY_NO_INSIGHT",e[e.FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB=85]="FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB",e[e.AUTOS_INCENTIVES=86]="AUTOS_INCENTIVES",e[e.GOODRX=87]="GOODRX",e[e.GOODRX_OVERLAY=88]="GOODRX_OVERLAY",e[e.SIMILAR_OFFERS=89]="SIMILAR_OFFERS",e[e.SEARCH_RESULTS=90]="SEARCH_RESULTS",e[e.FEED_VISUAL_SEARCH=91]="FEED_VISUAL_SEARCH",e[e.FEED_NATIVE_ADS=92]="FEED_NATIVE_ADS",e[e.AX_SHOPPING_NAV=93]="AX_SHOPPING_NAV",e[e.SHOPPING_CHIPS=95]="SHOPPING_CHIPS",e[e.SMART_COMPARE=96]="SMART_COMPARE",e[e.BUYING_GUIDES=97]="BUYING_GUIDES",e[e.CAMPAIGN_PDP_CASHBACK=98]="CAMPAIGN_PDP_CASHBACK",e[e.CAMPAIGN_BANNER=99]="CAMPAIGN_BANNER",e[e.FEED_CAMPAIGN=100]="FEED_CAMPAIGN",e[e.CAMPAIGN_PDP_CASHBACK_NOTIFICATION=101]="CAMPAIGN_PDP_CASHBACK_NOTIFICATION",e[e.CAMPAIGN_AWARENESS_NOTIFICATION=102]="CAMPAIGN_AWARENESS_NOTIFICATION",e[e.PRICE_DROP_PLUS_COUPONS=103]="PRICE_DROP_PLUS_COUPONS",e[e.PRODUCT_BEST_COUPON=104]="PRODUCT_BEST_COUPON",e[e.WIN_CART=105]="WIN_CART",e[e.SIDEPANE_CASHBACK=106]="SIDEPANE_CASHBACK",e[e.WISHLIST=107]="WISHLIST",e[e.MENU=108]="MENU",e[e.PRODUCT_TRACKING_ALERT=109]="PRODUCT_TRACKING_ALERT",e[e.OVERLAY_SHARE=110]="OVERLAY_SHARE",e[e.OVERLAY_CLOSE=111]="OVERLAY_CLOSE",e[e.EXTENSION_POPUP=112]="EXTENSION_POPUP",e[e.EXTENSION_AUTOAPPLY=113]="EXTENSION_AUTOAPPLY",e[e.BELL_ICON=114]="BELL_ICON",e[e.BANNER=115]="BANNER",e[e.SEARCH_IN_PANE=116]="SEARCH_IN_PANE",e[e.FOOTER=117]="FOOTER",e[e.CASHBACK_PLUS_COUPONS=118]="CASHBACK_PLUS_COUPONS",e[e.PRICE_DROP_PLUS_CASHBACK=119]="PRICE_DROP_PLUS_CASHBACK",e[e.POST_PURCHASE_CONSENT_NOTIFICATION=120]="POST_PURCHASE_CONSENT_NOTIFICATION",e[e.OMNIBOX_PCB_HISTORY_MATCH=121]="OMNIBOX_PCB_HISTORY_MATCH",e[e.LOWER_PRICE_PLUS_CASHBACK_PLUS_COUPONS=122]="LOWER_PRICE_PLUS_CASHBACK_PLUS_COUPONS",e[e.PRICE_MATCH_PRICE_DROP_NOTIFICATION=124]="PRICE_MATCH_PRICE_DROP_NOTIFICATION",e[e.PRODUCT_TRACKING_OFFERS_COUPON_NOTIFICATION=125]="PRODUCT_TRACKING_OFFERS_COUPON_NOTIFICATION",e[e.SHOPPING_TRIPS=126]="SHOPPING_TRIPS",e[e.DISCOVER_NOTIFICATION=127]="DISCOVER_NOTIFICATION",e[e.AX_SHOPPING_NAV_NOTIFICATION=128]="AX_SHOPPING_NAV_NOTIFICATION",e[e.BACKGROUND_AUTO_APPLY=129]="BACKGROUND_AUTO_APPLY",e[e.FEED_RELATED_PRODUCTS=130]="FEED_RELATED_PRODUCTS",e[e.PRODUCT_SUMMARY_CARD=131]="PRODUCT_SUMMARY_CARD",e[e.INSTANT_ADD_TO_CART_OVERLAY=132]="INSTANT_ADD_TO_CART_OVERLAY",e[e.ARTICLES_CASHBACK=133]="ARTICLES_CASHBACK",e[e.INBOX_PRICE_MATCH_PRICE_DROP_NOTIFICATION=134]="INBOX_PRICE_MATCH_PRICE_DROP_NOTIFICATION",e[e.TRAVEL_CHEAPER_FLIGHT_NOTIFICATION=135]="TRAVEL_CHEAPER_FLIGHT_NOTIFICATION",e[e.TRAVEL_CHEAPER_HOTEL_NOTIFICATION=136]="TRAVEL_CHEAPER_HOTEL_NOTIFICATION",e[e.POST_PURCHASE_REWARDS_NOTIFICATION=137]="POST_PURCHASE_REWARDS_NOTIFICATION",e[e.BUYING_OPTIONS=138]="BUYING_OPTIONS",e[e.MAX_VALUE=139]="MAX_VALUE",e}({})},84901:function(e,t,i){"use strict";i.d(t,{FV:function(){return n},ZF:function(){return o},w1:function(){return r}});let n=function(e){return e.VIEW_PRODUCT_SUMMARY_CARD="VIEW_PRODUCT_SUMMARY_CARD",e.PRODUCT_SUMMARY_CARD_SAVE_WL="PRODUCT_SUMMARY_CARD_SAVE_WL",e.PRODUCT_SUMMARY_CARD_UNSAVE_WL="PRODUCT_SUMMARY_CARD_UNSAVE_WL",e.COUPONS_COPIED="COUPONS_COPIED",e.NAVIGATE_TO_RETAILER="NAVIGATE_TO_RETAILER",e.TRY_ALL_COUPONS="TRY_ALL_COUPONS",e.SHOW_MORE_SELLERS="SHOW_MORE_SELLERS",e.REBATES_LEARN_MORE="REBATES_LEARN_MORE",e.REBATES_VIEW_IN_PANE="REBATES_VIEW_IN_PANE",e.REBATES_ACCOUNT="REBATES_ACCOUNT",e.REBATES_HISTORY="REBATES_HISTORY",e.ACTIVATE_CASHBACK="ACTIVATE_CASHBACK",e.EXPAND_GRAPH="EXPAND_GRAPH",e.VIEW_PRICE_HISTORY="VIEW_PRICE_HISTORY",e.COUPONS_COPIED_AUTOFILL="COUPONS_COPIED_AUTOFILL",e.TRY_ALL_COUPONS_AUTOFILL="TRY_ALL_COUPONS_AUTOFILL",e.NAVIGATE_TO_DEAL_OFFER="NAVIGATE_TO_DEAL_OFFER",e.NAVIGATE_TO_PROFESSIONAL_REVIEW="NAVIGATE_TO_PROFESSIONAL_REVIEW",e.NAVIGATE_TO_VIDEO_REVIEW="NAVIGATE_TO_VIDEO_REVIEW",e.EXPRESS_CHECKOUT="EXPRESS_CHECKOUT",e.OPEN_FLYOUT="OPEN_FLYOUT",e.OPEN_PANE_FROM_FLYOUT="OPEN_PANE_FROM_FLYOUT",e.NAVIGATE_TO_RECOMMENDATION_OFFER="NAVIGATE_TO_RECOMMENDATION_OFFER",e.CLIP_COUPON="CLIP_COUPON",e.ACTIVATE_CASHBACK_NEW="ACTIVATE_CASHBACK_NEW",e.PRODUCT_HISTORY_NAVIGATION="PRODUCT_HISTORY_NAVIGATION",e.NAVIGATE_TO_OTHER_SELLER="NAVIGATE_TO_OTHER_SELLER",e.TIPS_CLICK="TIPS_CLICK",e.REWARDS_SIGNIN_CLICK="REWARDS_SIGNIN_CLICK",e.REWARDS_REDEEM_CLICK="REWARDS_REDEEM_CLICK",e.CASHBACK_OTHERSITES_CLICK="CASHBACK_OTHERSITES_CLICK",e.ZIP_CHECKOUT="ZIP_CHECKOUT",e.PWILO_NOTIFICATION_PRICE_DROP="PWILO_NOTIFICATION_PRICE_DROP",e.YOUTUBE_COUPON_COPIED_HOME="YOUTUBE_COUPON_COPIED_HOME",e.YOUTUBE_COUPON_COPIED_VIDEO="YOUTUBE_COUPON_COPIED_VIDEO",e.YOUTUBE_COUPON_COPIED_RETAILER="YOUTUBE_COUPON_COPIED_RETAILER",e.YOUTUBE_COUPON_COPIED_RETAILER_CHECKOUT="YOUTUBE_COUPON_COPIED_RETAILER_CHECKOUT",e.YOUTUBE_TRY_ALL_COUPONS="YOUTUBE_TRY_ALL_COUPONS",e.CASHBACK_RETAILER_CLICK="CASHBACK_RETAILER_CLICK",e.ACTIVATE_CASHBACK_RETURNED="ACTIVATE_CASHBACK_RETURNED",e.PRINT_COUPONS_CLICK="PRINT_COUPONS_CLICK",e.SELECT_PRINTABLE_COUPON="SELECT_PRINTABLE_COUPON",e.DIGITAL_GROCERY_COUPONS_CLICK="DIGITAL_GROCERY_COUPONS_CLICK",e.PINTEREST_COUPON_COPIED="PINTEREST_COUPON_COPIED",e.PINTEREST_CASHBACK_ACTIVATED="PINTEREST_CASHBACK_ACTIVATED",e.PINTEREST_VIEW_PRICE_HISTORY="PINTEREST_VIEW_PRICE_HISTORY",e.PACKAGE_TRACKING_EXPAND_SECTION="PACKAGE_TRACKING_EXPAND_SECTION",e.PACKAGE_TRACKING_OPT_IN="PACKAGE_TRACKING_OPT_IN",e.PACKAGE_TRACKING_CARD_CLICKED="PACKAGE_TRACKING_CARD_CLICKED",e.AUTOS_MARKETPLACE_TITLE_CLICK="AUTOS_MARKETPLACE_TITLE_CLICK",e.AUTOS_MARKETPLACE_RECOMMENDATION_CLICK="AUTOS_MARKETPLACE_RECOMMENDATION_CLICK",e.AUTOS_MARKETPLACE_SEE_MORE_CLICK="AUTOS_MARKETPLACE_SEE_MORE_CLICK",e.AUTOS_MARKETPLACE_MYGARAGE_CHECK_NOW="AUTOS_MARKETPLACE_MYGARAGE_CHECK_NOW",e.AUTOS_PRICE_INSIGHT_SEE_MORE_CLICK="AUTOS_PRICE_INSIGHT_SEE_MORE_CLICK",e.AUTOS_PRICE_INSIGHT_RATINGURL_CLICK="AUTOS_PRICE_INSIGHT_RATINGURL_CLICK",e.AUTOS_REVIEWS_VIDEO_CLICK="AUTOS_REVIEWS_VIDEO_CLICK",e.AUTOS_REVIEWS_VIDEO_SEE_MORE_CLICK="AUTOS_REVIEWS_VIDEO_SEE_MORE_CLICK",e.AUTOS_MYGARAGE_TITLE_CLICK="AUTOS_MYGARAGE_TITLE_CLICK",e.AUTOS_MYGARAGE_MODULE_CLICK="AUTOS_MYGARAGE_MODULE_CLICK",e.GO_TO_ABANDONED_CART="GO_TO_ABANDONED_CART",e.GO_TO_WIN_CART="GO_TO_WIN_CART",e.INPUT_COUPON="INPUT_COUPON",e.SUBMIT_COUPON="SUBMIT_COUPON",e.AWARENESS_SEE_MORE="AWARENESS_SEE_MORE",e.PRODUCT_TRACKED_STOCK="PRODUCT_TRACKED_STOCK",e.PRODUCT_TRACKED_PRICE="PRODUCT_TRACKED_PRICE",e.PRODUCT_TRACKING_PRODUCT_NOTIFICATION_CLICK="PRODUCT_TRACKING_PRODUCT_NOTIFICATION_CLICK",e.PRODUCT_TRACKING_PRODUCT_COLLECTIONS_CLICK="PRODUCT_TRACKING_PRODUCT_COLLECTIONS_CLICK",e.PRODUCT_TRACKING_COLLECTIONS_TRACK_CLICK="PRODUCT_TRACKING_COLLECTIONS_TRACK_CLICK",e.PRODUCT_TRACKING_COLLECTIONS_VIEW_STEPS="PRODUCT_TRACKING_COLLECTIONS_VIEW_STEPS",e.PRODUCT_TRACKING_COLLECTIONS_START_TRACKING="PRODUCT_TRACKING_COLLECTIONS_START_TRACKING",e.PRODUCT_TRACKED_VIEW_TRACKED_PRODUCTS="PRODUCT_TRACKED_VIEW_TRACKED_PRODUCTS",e.PRODUCT_TRACKING_ABANDONED_CART_TRACK_CLICK="PRODUCT_TRACKING_ABANDONED_CART_TRACK_CLICK",e.CLICK_BEST_COUPON="CLICK_BEST_COUPON",e.SEE_MORE_TRENDING_COUPONS="SEE_MORE_TRENDING_COUPONS",e.INBOX_COUPONS_SIGN_IN_EDGE="INBOX_COUPONS_SIGN_IN_EDGE",e.INBOX_COUPONS_CONNECT_OUTLOOK_INBOX="INBOX_COUPONS_CONNECT_OUTLOOK_INBOX",e.INBOX_COUPONS_CONNECT_GMAIL_INBOX="INBOX_COUPONS_CONNECT_GMAIL_INBOX",e.INBOX_COUPONS_RECONNECT_INBOX="INBOX_COUPONS_RECONNECT_INBOX",e.INBOX_COUPONS_COPY_COUPON="INBOX_COUPONS_COPY_COUPON",e.INBOX_COUPONS_DISCONNECT_INBOX="INBOX_COUPONS_DISCONNECT_INBOX",e.NAVIGATE_TO_TRENDING_DEAL="NAVIGATE_TO_TRENDING_DEAL",e.PRODUCT_TRACKING_NOTIFICATION_TRACK="PRODUCT_TRACKING_NOTIFICATION_TRACK",e.PRODUCT_TRACKING_COLLECTIONS_RECENT_SEE_MORE_CLICK="PRODUCT_TRACKING_COLLECTIONS_RECENT_SEE_MORE_CLICK",e.PRODUCT_TRACKING_COLLECTIONS_TRACKED_PRODUCT_SEE_MORE_CLICK="PRODUCT_TRACKING_COLLECTIONS_TRACKED_PRODUCT_SEE_MORE_CLICK",e.NOTIFICATION_MOMENT_IN_TIME="NOTIFICATION_MOMENT_IN_TIME",e.FEED_MOMENT_IN_TIME="FEED_MOMENT_IN_TIME",e.FEED_TRENDING_OFFERS="FEED_TRENDING_OFFERS",e.FEED_TRENDING_OFFERS_SHOW_MORE="FEED_TRENDING_OFFERS_SHOW_MORE",e.FEED_DAILY_DEALS="FEED_DAILY_DEALS",e.FEED_DAILY_DEALS_SHOW_MORE="FEED_DAILY_DEALS_SHOW_MORE",e.FEED_INFINITE_CATEGORY="FEED_INFINITE_CATEGORY",e.FEED_INFINITE_CATEGORY_SHOW_MORE="FEED_INFINITE_CATEGORY_SHOW_MORE",e.SWITCH_TO_TAB1="SWITCH_TO_TAB1",e.SWITCH_TO_TAB2="SWITCH_TO_TAB2",e.SWITCH_TO_TAB3="SWITCH_TO_TAB3",e.SCROLL_TO_TAB1="SCROLL_TO_TAB1",e.SCROLL_TO_TAB2="SCROLL_TO_TAB2",e.SCROLL_TO_TAB3="SCROLL_TO_TAB3",e.FEED_BUY_DIRECT="FEED_BUY_DIRECT",e.FEED_BUY_DIRECT_SHOW_MORE="FEED_BUY_DIRECT_SHOW_MORE",e.FETCH_SEARCH_RESULTS="FETCH_SEARCH_RESULTS",e.SEARCH_BOX_FOCUSED="SEARCH_BOX_FOCUSED",e.FEED_INFINITE_CATEGORY_AD="FEED_INFINITE_CATEGORY_AD",e.FEED_RELATED_PRODUCTS="FEED_RELATED_PRODUCTS",e.FEED_NATIVE_ADS="FEED_NATIVE_ADS",e.FEED_SEARCH_RESULTS="FEED_SEARCH_RESULTS",e.FEED_SIMILAR_OFFERS="FEED_SIMILAR_OFFERS",e.FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB="FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB",e.FEED_VISUAL_SEARCH="FEED_VISUAL_SEARCH",e.CJK_OPEN_FLYOUT="CJK_OPEN_FLYOUT",e.CJK_OPEN_PANE_FROM_FLYOUT="CJK_OPEN_PANE_FROM_FLYOUT",e.CJK_OPEN_PANE_FROM_SIDEBAR="CJK_OPEN_PANE_FROM_SIDEBAR",e.CJK_SCROLL_PAGE="CJK_SCROLL_PAGE",e.CJK_SWITCH_TO_TAB1="CJK_SWITCH_TO_TAB1",e.CJK_SWITCH_TO_TAB2="CJK_SWITCH_TO_TAB2",e.CJK_COUPONS_CLICK="CJK_COUPONS_CLICK",e.CJK_COUPONS_SEE_MORE="CJK_COUPONS_SEE_MORE",e.CJK_VIEW_PRICE_HISTORY="CJK_VIEW_PRICE_HISTORY",e.CJK_PRICE_HISTORY_SET_TIMERANGE="CJK_PRICE_HISTORY_SET_TIMERANGE",e.CJK_PRICE_COMPARISON_CLICK="CJK_PRICE_COMPARISON_CLICK",e.CJK_CLICK_PRICE_COMPARISON_SEE_MORE="CJK_CLICK_PRICE_COMPARISON_SEE_MORE",e.CJK_SIMILAR_PRODUCTS_CLICK="CJK_SIMILAR_PRODUCTS_CLICK",e.CJK_ACTIVITY_CLICK="CJK_ACTIVITY_CLICK",e.CJK_ACTIVITY_SEE_MORE="CJK_ACTIVITY_SEE_MORE",e.CJK_TRENDING_PRODUCTS_CLICK="CJK_TRENDING_PRODUCTS_CLICK",e.CJK_TRENDING_PRODUCTS_SET_CATEGORY="CJK_TRENDING_PRODUCTS_SET_CATEGORY",e.CJK_TRENDING_PRODUCTS_SET_RETAILER="CJK_TRENDING_PRODUCTS_SET_RETAILER",e.CJK_COUPONS_CHECK_COUPON="CJK_COUPONS_CHECK_COUPON",e.CAMPAIGN_SHOP_NOW_BANNER_BUTTON_CLICK="CAMPAIGN_SHOP_NOW_BANNER_BUTTON_CLICK",e.FEED_CAMPAIGN="FEED_CAMPAIGN",e.CAMPAIGN_CASHBACK_BANNER="CAMPAIGN_CASHBACK_BANNER",e.AX_SHOP_INVOKED_PRODUCT_NAME="AX_SHOP_INVOKED_PRODUCT_NAME",e.AX_SHOP_INVOKED_PRODUCT_PRICE="AX_SHOP_INVOKED_PRODUCT_PRICE",e.AX_SHOP_INVOKED_PRODUCT_REVIEW_COUNT="AX_SHOP_INVOKED_PRODUCT_REVIEW_COUNT",e.AX_SHOP_INVOKED_PRODUCT_MANUFACTURER="AX_SHOP_INVOKED_PRODUCT_MANUFACTURER",e.AX_SHOP_INVOKED_PRODUCT_OUT_OF_STOCK_MESSAGE="AX_SHOP_INVOKED_PRODUCT_OUT_OF_STOCK_MESSAGE",e.AX_SHOP_INVOKED_PRODUCT_RATING="AX_SHOP_INVOKED_PRODUCT_RATING",e.AX_SHOP_INVOKED_PRODUCT_OTHER="AX_SHOP_INVOKED_PRODUCT_OTHER",e.TRY_PRODUCT_BEST_COUPON="TRY_PRODUCT_BEST_COUPON",e.VIEW_COUPONS_FROM_NOTIFICATION="VIEW_COUPONS_FROM_NOTIFICATION",e.VIEW_PRICE_COMPARISON_FROM_NOTIFICATION="VIEW_PRICE_COMPARISON_FROM_NOTIFICATION",e.CAMPAIGN_AWARENESS_BANNER_BUTTON_CLICK="CAMPAIGN_AWARENESS_BANNER_BUTTON_CLICK",e.SHOPPING_CHIPS="SHOPPING_CHIPS",e.SMART_COMPARE="SMART_COMPARE",e.BUYING_GUIDES="BUYING_GUIDES",e.WISHLIST_SAVE="WISHLIST_SAVE",e.WISHLIST_UNSAVE="WISHLIST_UNSAVE",e.WISHLIST_SEE_ALL="WISHLIST_SEE_ALL",e.PRICE_MATCH_OPT_IN="PRICE_MATCH_OPT_IN",e.PRICE_MATCH_CARD_CLICK="PRICE_MATCH_CARD_CLICK",e.PRICE_MATCH_CARD_CTA_CLICK="PRICE_MATCH_CARD_CTA_CLICK",e.PRICE_MATCH_NOTIFICATION_CTA_CLICK="PRICE_MATCH_NOTIFICATION_CTA_CLICK",e.CASHBACK_MODULE_VIEW_OFFER_DETAILS_CLICK="CASHBACK_MODULE_VIEW_OFFER_DETAILS_CLICK",e.CASHBACK_MODULE_VIEW_OFFER_DETAILS_SEELESS_CLICK="CASHBACK_MODULE_VIEW_OFFER_DETAILS_SEELESS_CLICK",e.CASHBACK_MODULE_FLYOUT_TAG_CLICK="CASHBACK_MODULE_FLYOUT_TAG_CLICK",e.PRODUCT_TRACKING_COLLECTIONS_SIGN_IN="PRODUCT_TRACKING_COLLECTIONS_SIGN_IN",e.PRODUCT_TRACKING_COLLECTIONS_ROAM="PRODUCT_TRACKING_COLLECTIONS_ROAM",e.ACTIVATE_CLICK_SPB_CASHBACK="ACTIVATE_CLICK_SPB_CASHBACK",e.TRY_BGAA_BEST_COUPON="TRY_BGAA_BEST_COUPON",e.TRAVEL_CHEAPER_FLIGHTS_CLICK="TRAVEL_CHEAPER_FLIGHTS_CLICK",e.TRAVEL_CHEAPER_HOTEL_CLICK="TRAVEL_CHEAPER_HOTEL_CLICK ",e.BUYING_OPTIONS_FILTERCHANGE="BUYING_OPTIONS_FILTERCHANGE",e.BUYING_OPTIONS_RETAILER_HOVER="BUYING_OPTIONS_RETAILER_HOVER",e}({}),o=function(e){return e[e.COUPONS_COPIED=0]="COUPONS_COPIED",e[e.NAVIGATE_TO_RETAILER=1]="NAVIGATE_TO_RETAILER",e[e.TRY_ALL_COUPONS=2]="TRY_ALL_COUPONS",e[e.SHOW_MORE_SELLERS=3]="SHOW_MORE_SELLERS",e[e.REBATES_LEARN_MORE=4]="REBATES_LEARN_MORE",e[e.REBATES_ACCOUNT=5]="REBATES_ACCOUNT",e[e.REBATES_HISTORY=6]="REBATES_HISTORY",e[e.ACTIVATE_CASHBACK=7]="ACTIVATE_CASHBACK",e[e.EXPAND_GRAPH=8]="EXPAND_GRAPH",e[e.VIEW_PRICE_HISTORY=9]="VIEW_PRICE_HISTORY",e[e.COUPONS_COPIED_AUTOFILL=10]="COUPONS_COPIED_AUTOFILL",e[e.TRY_ALL_COUPONS_AUTOFILL=11]="TRY_ALL_COUPONS_AUTOFILL",e[e.NAVIGATE_TO_DEAL_OFFER=12]="NAVIGATE_TO_DEAL_OFFER",e[e.NAVIGATE_TO_PROFESSIONAL_REVIEW=13]="NAVIGATE_TO_PROFESSIONAL_REVIEW",e[e.NAVIGATE_TO_VIDEO_REVIEW=14]="NAVIGATE_TO_VIDEO_REVIEW",e[e.EXPRESS_CHECKOUT=15]="EXPRESS_CHECKOUT",e[e.OPEN_FLYOUT=16]="OPEN_FLYOUT",e[e.NAVIGATE_TO_RECOMMENDATION_OFFER=17]="NAVIGATE_TO_RECOMMENDATION_OFFER",e[e.CLIP_COUPON=18]="CLIP_COUPON",e[e.ACTIVATE_CASHBACK_NEW=19]="ACTIVATE_CASHBACK_NEW",e[e.ACTIVATE_REWARDS_NEW=20]="ACTIVATE_REWARDS_NEW",e[e.ADD_TO_CART_FROM_OTHER_SELLER=21]="ADD_TO_CART_FROM_OTHER_SELLER",e[e.PRODUCT_HISTORY_NAVIGATION=22]="PRODUCT_HISTORY_NAVIGATION",e[e.NAVIGATE_TO_OTHER_SELLER=23]="NAVIGATE_TO_OTHER_SELLER",e[e.TIPS_CLICK=24]="TIPS_CLICK",e[e.REWARDS_SIGNIN_CLICK=25]="REWARDS_SIGNIN_CLICK",e[e.REWARDS_REDEEM_CLICK=26]="REWARDS_REDEEM_CLICK",e[e.CASHBACK_OTHERSITES_CLICK=27]="CASHBACK_OTHERSITES_CLICK",e[e.ZIP_CHECKOUT=29]="ZIP_CHECKOUT",e[e.PWILO_NOTIFICATION_PRICE_DROP=30]="PWILO_NOTIFICATION_PRICE_DROP",e[e.YOUTUBE_COUPON_COPIED_HOME=31]="YOUTUBE_COUPON_COPIED_HOME",e[e.YOUTUBE_COUPON_COPIED_VIDEO=32]="YOUTUBE_COUPON_COPIED_VIDEO",e[e.YOUTUBE_COUPON_COPIED_RETAILER=33]="YOUTUBE_COUPON_COPIED_RETAILER",e[e.YOUTUBE_COUPON_COPIED_RETAILER_CHECKOUT=34]="YOUTUBE_COUPON_COPIED_RETAILER_CHECKOUT",e[e.YOUTUBE_TRY_ALL_COUPONS=35]="YOUTUBE_TRY_ALL_COUPONS",e[e.CASHBACK_RETAILER_CLICK=36]="CASHBACK_RETAILER_CLICK",e[e.ACTIVATE_CASHBACK_RETURNED=37]="ACTIVATE_CASHBACK_RETURNED",e[e.PRINT_COUPONS_CLICK=38]="PRINT_COUPONS_CLICK",e[e.SELECT_PRINTABLE_COUPON=39]="SELECT_PRINTABLE_COUPON",e[e.DIGITAL_GROCERY_COUPONS_CLICK=40]="DIGITAL_GROCERY_COUPONS_CLICK",e[e.PINTEREST_COUPON_COPIED=41]="PINTEREST_COUPON_COPIED",e[e.PINTEREST_CASHBACK_ACTIVATED=42]="PINTEREST_CASHBACK_ACTIVATED",e[e.PINTEREST_VIEW_PRICE_HISTORY=43]="PINTEREST_VIEW_PRICE_HISTORY",e[e.PACKAGE_TRACKING_EXPAND_SECTION=44]="PACKAGE_TRACKING_EXPAND_SECTION",e[e.PACKAGE_TRACKING_OPT_IN=45]="PACKAGE_TRACKING_OPT_IN",e[e.PACKAGE_TRACKING_CARD_CLICKED=46]="PACKAGE_TRACKING_CARD_CLICKED",e[e.SUSTAINABILITY_LANDING_FULL_LEARN_MORE=47]="SUSTAINABILITY_LANDING_FULL_LEARN_MORE",e[e.SUSTAINABILITY_LANDING_FOOTER_LEARN_MORE=48]="SUSTAINABILITY_LANDING_FOOTER_LEARN_MORE",e[e.SUSTAINABILITY_PURCHASE_CONFIRMATION_LEARN_MORE=49]="SUSTAINABILITY_PURCHASE_CONFIRMATION_LEARN_MORE",e[e.SUSTAINABILITY_PURCHASE_CONFIRMATION_SHOW_PRODUCTS=50]="SUSTAINABILITY_PURCHASE_CONFIRMATION_SHOW_PRODUCTS",e[e.SUSTAINABILITY_PURCHASE_CONFIRMATION_SOCIAL_SHARE=51]="SUSTAINABILITY_PURCHASE_CONFIRMATION_SOCIAL_SHARE",e[e.NTP_REBATES_REDEEM=52]="NTP_REBATES_REDEEM",e[e.NTP_REBATES_EXPLORE_RETAILERS=53]="NTP_REBATES_EXPLORE_RETAILERS",e[e.NTP_CART_NAVIGATE_TO_CART=54]="NTP_CART_NAVIGATE_TO_CART",e[e.NTP_CART_EXPLORE_MORE=55]="NTP_CART_EXPLORE_MORE",e[e.NTP_CART_VIEW_PRODUCT=56]="NTP_CART_VIEW_PRODUCT",e[e.NTP_DROP_VIEW_PRODUCT=57]="NTP_DROP_VIEW_PRODUCT",e[e.NTP_DROP_SEE_MORE=58]="NTP_DROP_SEE_MORE",e[e.NTP_RETAILERS_VIEW_RETAILER=59]="NTP_RETAILERS_VIEW_RETAILER",e[e.NTP_RETAILERS_EXPLORE_MORE=60]="NTP_RETAILERS_EXPLORE_MORE",e[e.NTP_OFFER_BUY_NOW=61]="NTP_OFFER_BUY_NOW",e[e.CLICK_PCB_CROSS_SESSION=62]="CLICK_PCB_CROSS_SESSION",e[e.REWARD_JOIN_NOW=63]="REWARD_JOIN_NOW",e[e.REWARD_MAYBE_LATER=64]="REWARD_MAYBE_LATER",e[e.REWARD_DISMISS=65]="REWARD_DISMISS",e[e.ACTIVATE_CLICK_ITEMIZED_CASHBACK=66]="ACTIVATE_CLICK_ITEMIZED_CASHBACK",e[e.ACTIVATED_CLICK_ITEMIZED_CASHBACK=67]="ACTIVATED_CLICK_ITEMIZED_CASHBACK",e[e.HOVER_INFO_ICON_ITEMIZED_CASHBACK=68]="HOVER_INFO_ICON_ITEMIZED_CASHBACK",e[e.CLICK_DISCLAIMER_ITEMIZED_CASHBACK=69]="CLICK_DISCLAIMER_ITEMIZED_CASHBACK",e[e.REMIND_ME_LATER=70]="REMIND_ME_LATER",e[e.GROCERY=71]="GROCERY",e[e.NTP_TOP_SITES_HOVER=72]="NTP_TOP_SITES_HOVER",e[e.NTP_TOP_SITES_CART_PRODUCT=73]="NTP_TOP_SITES_CART_PRODUCT",e[e.NTP_TOP_SITES_CART_BUTTON=74]="NTP_TOP_SITES_CART_BUTTON",e[e.NTP_TOP_SITES_PRICE_DROP_PRODUCT=75]="NTP_TOP_SITES_PRICE_DROP_PRODUCT",e[e.NTP_TOP_SITES_STORE_CASHBACK=76]="NTP_TOP_SITES_STORE_CASHBACK",e[e.FEED_TRENDING_OFFERS=77]="FEED_TRENDING_OFFERS",e[e.FEED_TRENDING_OFFERS_SHOW_MORE=78]="FEED_TRENDING_OFFERS_SHOW_MORE",e[e.FEED_DAILY_DEALS=79]="FEED_DAILY_DEALS",e[e.FEED_DAILY_DEALS_SHOW_MORE=80]="FEED_DAILY_DEALS_SHOW_MORE",e[e.FEED_INFINITE_CATEGORY=81]="FEED_INFINITE_CATEGORY",e[e.FEED_INFINITE_CATEGORY_SHOW_MORE=82]="FEED_INFINITE_CATEGORY_SHOW_MORE",e[e.SWITCH_TO_TAB1=83]="SWITCH_TO_TAB1",e[e.SWITCH_TO_TAB2=84]="SWITCH_TO_TAB2",e[e.SHOPRUNNER_SEEMORE=85]="SHOPRUNNER_SEEMORE",e[e.SHOPRUNNER_SIGNUP_CLICK=86]="SHOPRUNNER_SIGNUP_CLICK",e[e.SHOPRUNNER_FLYOUT_EXPAND_SECTION=87]="SHOPRUNNER_FLYOUT_EXPAND_SECTION",e[e.GO_TO_ABANDONED_CART=88]="GO_TO_ABANDONED_CART",e[e.PRODUCT_IN_CART_CLICK=89]="PRODUCT_IN_CART_CLICK",e[e.PRODUCT_TRACKED_STOCK=90]="PRODUCT_TRACKED_STOCK",e[e.PRODUCT_TRACKED_PRICE=91]="PRODUCT_TRACKED_PRICE",e[e.PRODUCT_TRACKING_PRODUCT_NOTIFICATION_CLICK=92]="PRODUCT_TRACKING_PRODUCT_NOTIFICATION_CLICK",e[e.PRODUCT_TRACKING_PRODUCT_COLLECTIONS_CLICK=93]="PRODUCT_TRACKING_PRODUCT_COLLECTIONS_CLICK",e[e.SEE_ALL_TRENDING_DEALS=94]="SEE_ALL_TRENDING_DEALS",e[e.NAVIGATE_TO_TRENDING_DEAL=95]="NAVIGATE_TO_TRENDING_DEAL",e[e.INPUT_COUPON=96]="INPUT_COUPON",e[e.SUBMIT_COUPON=97]="SUBMIT_COUPON",e[e.AWARENESS_SEE_MORE=98]="AWARENESS_SEE_MORE",e[e.ACTIVATE_CLICK_SPB_CASHBACK=99]="ACTIVATE_CLICK_SPB_CASHBACK",e[e.ACTIVATED_CLICK_SPB_CASHBACK=100]="ACTIVATED_CLICK_SPB_CASHBACK",e[e.OMNIBOX_CLICK_SUGGESTION_MATCH=101]="OMNIBOX_CLICK_SUGGESTION_MATCH",e[e.OMNIBOX_CLICK_HISTORY_MATCH=102]="OMNIBOX_CLICK_HISTORY_MATCH",e[e.CLICK_BEST_COUPON=103]="CLICK_BEST_COUPON",e[e.SEE_MORE_TRENDING_COUPONS=104]="SEE_MORE_TRENDING_COUPONS",e[e.NTP_TOP_SITES_CLICK=105]="NTP_TOP_SITES_CLICK",e[e.PRODUCT_TRACKING_NOTIFICATION_TRACK=106]="PRODUCT_TRACKING_NOTIFICATION_TRACK",e[e.PRODUCT_TRACKING_COLLECTIONS_RECENT_SEE_MORE_CLICK=107]="PRODUCT_TRACKING_COLLECTIONS_RECENT_SEE_MORE_CLICK",e[e.PRODUCT_TRACKING_COLLECTIONS_TRACKED_PRODUCT_SEE_MORE_CLICK=108]="PRODUCT_TRACKING_COLLECTIONS_TRACKED_PRODUCT_SEE_MORE_CLICK",e[e.NOTIFICATION_MOMENT_IN_TIME=109]="NOTIFICATION_MOMENT_IN_TIME",e[e.FEED_MOMENT_IN_TIME=110]="FEED_MOMENT_IN_TIME",e[e.OPEN_PANE_FROM_FLYOUT=111]="OPEN_PANE_FROM_FLYOUT",e[e.INBOX_COUPONS_SIGN_IN_EDGE=112]="INBOX_COUPONS_SIGN_IN_EDGE",e[e.INBOX_COUPONS_CONNECT_OUTLOOK_INBOX=113]="INBOX_COUPONS_CONNECT_OUTLOOK_INBOX",e[e.INBOX_COUPONS_CONNECT_GMAIL_INBOX=114]="INBOX_COUPONS_CONNECT_GMAIL_INBOX",e[e.INBOX_COUPONS_RECONNECT_INBOX=115]="INBOX_COUPONS_RECONNECT_INBOX",e[e.INBOX_COUPONS_COPY_COUPON=116]="INBOX_COUPONS_COPY_COUPON",e[e.INBOX_COUPONS_DISCONNECT_INBOX=117]="INBOX_COUPONS_DISCONNECT_INBOX",e[e.AUTOS_MARKETPLACE_TITLE_CLICK=118]="AUTOS_MARKETPLACE_TITLE_CLICK",e[e.AUTOS_MARKETPLACE_RECOMMENDATION_CLICK=119]="AUTOS_MARKETPLACE_RECOMMENDATION_CLICK",e[e.AUTOS_MARKETPLACE_SEE_MORE_CLICK=120]="AUTOS_MARKETPLACE_SEE_MORE_CLICK",e[e.AUTOS_PRICE_INSIGHT_SEE_MORE_CLICK=121]="AUTOS_PRICE_INSIGHT_SEE_MORE_CLICK",e[e.FEED_BUY_DIRECT=122]="FEED_BUY_DIRECT",e[e.FEED_BUY_DIRECT_SHOW_MORE=123]="FEED_BUY_DIRECT_SHOW_MORE",e[e.AUTOS_PRICE_INSIGHT_RATINGURL_CLICK=124]="AUTOS_PRICE_INSIGHT_RATINGURL_CLICK",e[e.AUTOS_REVIEWS_VIDEO_CLICK=125]="AUTOS_REVIEWS_VIDEO_CLICK",e[e.AUTOS_REVIEWS_VIDEO_SEE_MORE_CLICK=126]="AUTOS_REVIEWS_VIDEO_SEE_MORE_CLICK",e[e.GOODRX_SELECT_CLICK=127]="GOODRX_SELECT_CLICK",e[e.GOODRX_DEALS_CLICK=128]="GOODRX_DEALS_CLICK",e[e.GOODRX_TERMS_CLICK=129]="GOODRX_TERMS_CLICK",e[e.GOODRX_PRINT_CLICK=130]="GOODRX_PRINT_CLICK",e[e.GOODRX_TEXT_CLICK=131]="GOODRX_TEXT_CLICK",e[e.GOODRX_EMAIL_CLICK=132]="GOODRX_EMAIL_CLICK",e[e.GOODRX_CREATE_ACCOUNT_CLICK=133]="GOODRX_CREATE_ACCOUNT_CLICK",e[e.GOODRX_SEND_COUPON_CLICK=134]="GOODRX_SEND_COUPON_CLICK",e[e.GOODRX_ENTER_INPUT=135]="GOODRX_ENTER_INPUT",e[e.FETCH_SEARCH_RESULTS=136]="FETCH_SEARCH_RESULTS",e[e.SEARCH_BOX_FOCUSED=137]="SEARCH_BOX_FOCUSED",e[e.GO_TO_WIN_CART=138]="GO_TO_WIN_CART",e[e.AX_SHOP_INVOKED_PRODUCT_NAME=139]="AX_SHOP_INVOKED_PRODUCT_NAME",e[e.AX_SHOP_INVOKED_PRODUCT_PRICE=140]="AX_SHOP_INVOKED_PRODUCT_PRICE",e[e.AX_SHOP_INVOKED_PRODUCT_REVIEW_COUNT=141]="AX_SHOP_INVOKED_PRODUCT_REVIEW_COUNT",e[e.AX_SHOP_INVOKED_PRODUCT_MANUFACTURER=142]="AX_SHOP_INVOKED_PRODUCT_MANUFACTURER",e[e.AX_SHOP_INVOKED_PRODUCT_OUT_OF_STOCK_MESSAGE=143]="AX_SHOP_INVOKED_PRODUCT_OUT_OF_STOCK_MESSAGE",e[e.AX_SHOP_INVOKED_PRODUCT_RATING=144]="AX_SHOP_INVOKED_PRODUCT_RATING",e[e.CJK_OPEN_FLYOUT=145]="CJK_OPEN_FLYOUT",e[e.CJK_OPEN_PANE_FROM_FLYOUT=146]="CJK_OPEN_PANE_FROM_FLYOUT",e[e.CJK_OPEN_PANE_FROM_SIDEBAR=147]="CJK_OPEN_PANE_FROM_SIDEBAR",e[e.CJK_SCROLL_PAGE=148]="CJK_SCROLL_PAGE",e[e.CJK_SWITCH_TO_TAB1=149]="CJK_SWITCH_TO_TAB1",e[e.CJK_SWITCH_TO_TAB2=150]="CJK_SWITCH_TO_TAB2",e[e.CJK_COUPONS_CLICK=151]="CJK_COUPONS_CLICK",e[e.CJK_COUPONS_SEE_MORE=152]="CJK_COUPONS_SEE_MORE",e[e.CJK_VIEW_PRICE_HISTORY=153]="CJK_VIEW_PRICE_HISTORY",e[e.CJK_PRICE_HISTORY_SET_TIMERANGE=154]="CJK_PRICE_HISTORY_SET_TIMERANGE",e[e.CJK_PRICE_COMPARISON_CLICK=155]="CJK_PRICE_COMPARISON_CLICK",e[e.CJK_CLICK_PRICE_COMPARISON_SEE_MORE=156]="CJK_CLICK_PRICE_COMPARISON_SEE_MORE",e[e.CJK_SIMILAR_PRODUCTS_CLICK=157]="CJK_SIMILAR_PRODUCTS_CLICK",e[e.CJK_ACTIVITY_CLICK=158]="CJK_ACTIVITY_CLICK",e[e.CJK_ACTIVITY_SEE_MORE=159]="CJK_ACTIVITY_SEE_MORE",e[e.CJK_TRENDING_PRODUCTS_CLICK=160]="CJK_TRENDING_PRODUCTS_CLICK",e[e.CJK_TRENDING_PRODUCTS_SET_CATEGORY=161]="CJK_TRENDING_PRODUCTS_SET_CATEGORY",e[e.CJK_TRENDING_PRODUCTS_SET_RETAILER=162]="CJK_TRENDING_PRODUCTS_SET_RETAILER",e[e.FEED_INFINITE_CATEGORY_AD=163]="FEED_INFINITE_CATEGORY_AD",e[e.FEED_NATIVE_ADS=164]="FEED_NATIVE_ADS",e[e.FEED_SEARCH_RESULTS=165]="FEED_SEARCH_RESULTS",e[e.FEED_SIMILAR_OFFERS=166]="FEED_SIMILAR_OFFERS",e[e.FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB=167]="FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB",e[e.FEED_VISUAL_SEARCH=168]="FEED_VISUAL_SEARCH",e[e.SWITCH_TO_TAB3=169]="SWITCH_TO_TAB3",e[e.SCROLL_TO_TAB1=170]="SCROLL_TO_TAB1",e[e.SCROLL_TO_TAB2=171]="SCROLL_TO_TAB2",e[e.SCROLL_TO_TAB3=172]="SCROLL_TO_TAB3",e[e.CAMPAIGN_SHOP_NOW_BANNER_BUTTON_CLICK=174]="CAMPAIGN_SHOP_NOW_BANNER_BUTTON_CLICK",e[e.FEED_CAMPAIGN=175]="FEED_CAMPAIGN",e[e.CAMPAIGN_CASHBACK_BANNER=176]="CAMPAIGN_CASHBACK_BANNER",e[e.AX_SHOP_INVOKED_PRODUCT_OTHER=177]="AX_SHOP_INVOKED_PRODUCT_OTHER",e[e.TRY_PRODUCT_BEST_COUPON=178]="TRY_PRODUCT_BEST_COUPON",e[e.CAMPAIGN_AWARENESS_BANNER_BUTTON_CLICK=179]="CAMPAIGN_AWARENESS_BANNER_BUTTON_CLICK",e[e.SHOPPING_CHIPS=180]="SHOPPING_CHIPS",e[e.SMART_COMPARE=184]="SMART_COMPARE",e[e.BUYING_GUIDES=185]="BUYING_GUIDES",e[e.PRODUCT_TRACKING_COLLECTIONS_TRACK_CLICK=186]="PRODUCT_TRACKING_COLLECTIONS_TRACK_CLICK",e[e.PRODUCT_TRACKING_COLLECTIONS_VIEW_STEPS=187]="PRODUCT_TRACKING_COLLECTIONS_VIEW_STEPS",e[e.PRODUCT_TRACKING_COLLECTIONS_START_TRACKING=188]="PRODUCT_TRACKING_COLLECTIONS_START_TRACKING",e[e.PRODUCT_TRACKED_VIEW_TRACKED_PRODUCTS=189]="PRODUCT_TRACKED_VIEW_TRACKED_PRODUCTS",e[e.PRODUCT_TRACKING_ABANDONED_CART_TRACK_CLICK=190]="PRODUCT_TRACKING_ABANDONED_CART_TRACK_CLICK",e[e.VIEW_COUPONS_FROM_NOTIFICATION=191]="VIEW_COUPONS_FROM_NOTIFICATION",e[e.REBATES_VIEW_IN_PANE=192]="REBATES_VIEW_IN_PANE",e[e.AUTOS_MYGARAGE_TITLE_CLICK=193]="AUTOS_MYGARAGE_TITLE_CLICK",e[e.AUTOS_MYGARAGE_MODULE_CLICK=194]="AUTOS_MYGARAGE_MODULE_CLICK",e[e.AUTOS_MARKETPLACE_MYGARAGE_CHECK_NOW=195]="AUTOS_MARKETPLACE_MYGARAGE_CHECK_NOW",e[e.PRICE_MATCH_OPT_IN=196]="PRICE_MATCH_OPT_IN",e[e.PRICE_MATCH_CARD_CLICK=197]="PRICE_MATCH_CARD_CLICK",e[e.PRICE_MATCH_CARD_CTA_CLICK=198]="PRICE_MATCH_CARD_CTA_CLICK",e[e.PRICE_MATCH_NOTIFICATION_CTA_CLICK=199]="PRICE_MATCH_NOTIFICATION_CTA_CLICK",e[e.VIEW_PRICE_COMPARISON_FROM_NOTIFICATION=200]="VIEW_PRICE_COMPARISON_FROM_NOTIFICATION",e[e.CASHBACK_MODULE_VIEW_OFFER_DETAILS_CLICK=201]="CASHBACK_MODULE_VIEW_OFFER_DETAILS_CLICK",e[e.CASHBACK_MODULE_VIEW_OFFER_DETAILS_SEELESS_CLICK=202]="CASHBACK_MODULE_VIEW_OFFER_DETAILS_SEELESS_CLICK",e[e.CASHBACK_MODULE_FLYOUT_TAG_CLICK=203]="CASHBACK_MODULE_FLYOUT_TAG_CLICK",e[e.PRODUCT_TRACKING_COLLECTIONS_SIGN_IN=204]="PRODUCT_TRACKING_COLLECTIONS_SIGN_IN",e[e.PRODUCT_TRACKING_COLLECTIONS_ROAM=205]="PRODUCT_TRACKING_COLLECTIONS_ROAM",e[e.FEED_RELATED_PRODUCTS=206]="FEED_RELATED_PRODUCTS",e[e.VIEW_PRODUCT_SUMMARY_CARD=207]="VIEW_PRODUCT_SUMMARY_CARD",e[e.TRY_BGAA_BEST_COUPON=208]="TRY_BGAA_BEST_COUPON",e[e.CJK_COUPONS_CHECK_COUPON=209]="CJK_COUPONS_CHECK_COUPON",e[e.WISHLIST_SAVE=210]="WISHLIST_SAVE",e[e.WISHLIST_UNSAVE=211]="WISHLIST_UNSAVE",e[e.WISHLIST_SEE_ALL=212]="WISHLIST_SEE_ALL",e[e.TRAVEL_CHEAPER_FLIGHTS_CLICK=213]="TRAVEL_CHEAPER_FLIGHTS_CLICK",e[e.PRODUCT_SUMMARY_CARD_SAVE_WL=214]="PRODUCT_SUMMARY_CARD_SAVE_WL",e[e.PRODUCT_SUMMARY_CARD_UNSAVE_WL=215]="PRODUCT_SUMMARY_CARD_UNSAVE_WL",e[e.TRAVEL_CHEAPER_HOTEL_CLICK=216]="TRAVEL_CHEAPER_HOTEL_CLICK",e[e.BUYING_OPTIONS_FILTERCHANGE=217]="BUYING_OPTIONS_FILTERCHANGE",e[e.BUYING_OPTIONS_RETAILER_HOVER=218]="BUYING_OPTIONS_RETAILER_HOVER",e[e.MIN_VALUE=0]="MIN_VALUE",e[e.MAX_VALUE=218]="MAX_VALUE",e}({}),r=function(e){return e[e.POSITIVE=0]="POSITIVE",e[e.NEGATIVE=1]="NEGATIVE",e}({})},86127:function(e,t,i){"use strict";i.d(t,{$:function(){return n}});let n=function(e){return e[e.CURRENT_TAB=0]="CURRENT_TAB",e[e.NEW_FOREGROUND_TAB=1]="NEW_FOREGROUND_TAB",e[e.NEW_BACKGROUND_TAB=2]="NEW_BACKGROUND_TAB",e[e.NEW_WINDOW=3]="NEW_WINDOW",e[e.NEW_IN_PRIVATE_TAB=4]="NEW_IN_PRIVATE_TAB",e}({})},33105:function(e,t,i){"use strict";i.d(t,{k:function(){return o},q:function(){return n}});let n=function(e){return e.Unknown="",e.PriceCompare="PriceCompare",e.PriceHistory="PriceHistory",e.Deals="Deals",e.PreviouslyViewedSimilar="PreviouslyViewedSimilar",e.CategoryInsights="CategoryInsights",e.ProductSummary="ProductSummary",e.OfferInsights="OfferInsights",e.DynamicSuggestionChips="DynamicSuggestionChips",e}({}),o=function(e){return e.PriceCompare="PriceCompare",e.PriceHistory="PriceHistory",e.PreviouslyViewedSimilar="PreviouslyViewedSimilar",e.BuyingGuides="BuyingGuides",e.ProductSummary="ProductSummary",e.ReviewsSummary="ReviewsSummary",e.CategoryInsights="CategoryInsights",e}({})},15255:function(e,t,i){"use strict";i.d(t,{a:function(){return n}});let n=function(e){return e.PageStatus="pageStatus",e.EnabledFeatures="enabled_features",e.CouponsApiResponse="couponsApiResponse",e.PackageTrackingFreShown="packageTrackingFreShown",e.PackageTrackingUserConsented="packageTrackingUserConsented",e.PackageTrackerResponse="packageTrackingData",e.ShouldShowPackageTrackingNotification="shouldShowPackageTrackingNotification",e.EdgeDriverDataForFlyout="edgeDriverDataForFlyout",e.GuestCouponsApiResponse="guestCouponsApiResponse",e.AutofillProfileEnabled="autofillProfileEnabled",e.AutofillCreditCardEnabled="autofillCreditCardEnabled",e.BgaaInfo="bgaa_info",e.ProductItemizedCashBack="productItemizedCashBack",e.NotificationData="notification_data",e.EnabledServiceFeatures="enabledservicefeatures",e.EnabledServiceFlights="enabledserviceflights",e.ExtractedEntity="extracted_entity",e.ShoppingDataContainer="shoppingDataContainer",e.IsDiscoverPane="isDiscoverPane",e.ShouldOpenSettingsPane="shouldOpenSettings",e.IsCJKEnabled="cjk_data",e.JourneyStage="journeyStage",e.UserInsights="userInsights",e.ExpertInsights="expertInsights",e.EnabledServiceFeaturesv2="enabledservicefeaturesv2",e}({})},17728:function(e,t,i){"use strict";var n=i(72370);t.Z=class{constructor(){(0,n.Z)(this,"element",void 0),(0,n.Z)(this,"name",void 0),(0,n.Z)(this,"moduleInterface",void 0)}}},64106:function(e,t,i){"use strict";var n=i(72370),o=i(59645),r=i(5144),a=i(88767);function s(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function l(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?s(Object(i),!0).forEach((function(t){(0,n.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):s(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}t.Z=class{constructor(e,t,i){(0,n.Z)(this,"flyoutData",void 0),(0,n.Z)(this,"logModule",void 0),(0,n.Z)(this,"pageHandlerModule",void 0),(0,n.Z)(this,"actionIdMap",{[a.ModuleNames.PRICEHISTORY]:1,[a.ModuleNames.SMART_COMPARE]:2,[a.ModuleNames.BUYING_GUIDES]:3,[a.ModuleNames.PRICECOMPARISON]:4,[a.ModuleNames.COUPON]:5,[a.ModuleNames.PRODUCT_SUMMARY]:6,[a.ModuleNames.PRODUCT_COLLECTIONS]:7}),this.flyoutData=e,this.logModule=t,this.pageHandlerModule=i}LogEventTelemetry(e,t,i,n,o={},a,s){const l=this.GetTelemetryData(e,t,i,n,!1,o);this.logModule.LogInfoEvent(r.R.EdgeFlyoutStatus,t,l),a&&this.pageHandlerModule.RecordAsContentViewed(a),s&&this.pageHandlerModule.RecordAsUserEngagement(s,this.flyoutData.common.popupOrigination)}LogClickTelemetry(e,t,i,n,o={},a){const s=this.GetTelemetryData(e,t,i,n,!1,o);this.logModule.LogInfoEvent(r.R.ButtonClick,t,s),this.logModule.LogInfoEvent(r.R.EdgeFlyoutStatus,t,s),a&&this.pageHandlerModule.RecordAsUserEngagement(a,this.flyoutData.common.popupOrigination)}LogErrorTelemetry(e,t,i,n,o={},a){const s=this.GetTelemetryData(a||r.xu.DiscoverModuleError,e,t,i,!0,o,n);this.logModule.LogInfoEvent(r.R.EdgeFlyoutStatus,e,s)}LogRenderErrorTelemetry(e,t,i,n={},o){const a=this.GetTelemetryData(o||r.xu.DiscoverPaneError,e,"",t,!0,n,i);this.logModule.LogInfoEvent(r.R.EdgeFlyoutStatus,e,a)}LogRendeInfoTelemetry(e,t,i={},n){const o=this.GetTelemetryData(n||r.xu.DiscoverPaneInfo,e,"",t,!1,i);this.logModule.LogInfoEvent(r.R.EdgeFlyoutStatus,e,o)}GetTelemetryData(e,t,i,n,r,a={},s){const c=this.flyoutData?{url:this.flyoutData.common.lastCommittedURL??"",domain:this.flyoutData.common.domain,channel:this.flyoutData.common.channel,isDiscoverPane:this.flyoutData.common.isDiscoverPane,moduleName:n,actionId:n?this.actionIdMap[n]??void 0:void 0,journeyStage:this.flyoutData.common.journeyStage}:{},d=new o.Z(e,void 0,void 0,this.flyoutData.common.domain);return d.Metadata=r?JSON.stringify(l(l(l({isError:!0,errorStr:s?JSON.stringify(s):""},c),a),{},{message:t})):JSON.stringify(l(l(l({},c),a),{},{message:t})),d}}},21908:function(e,t,i){"use strict";i.d(t,{y:function(){return a}});var n=i(72370),o=i(88767),r=i(73557);let a='button:enabled:not([slot="header-actions"]), textarea, input[type="text"], input[type="password"], div[role="slider"],\n input[type="radio"]:checked, input[type="checkbox"]:enabled, a[href]:not([slot="header-actions"]):not(#infoIcon),\n select:not([style*="display: none"]), details, a.autosMarketplaceListing, msft-shopping-link, msft-product-card,\n fluent-button:not([slot="header-actions"]), fluent-anchor:not([class="aHeaderContent"]), msft-shopping-recommendation,\n fluent-accordion, fluent-option, fluent-listbox, div.tipsDiv, msft-shopping-cashback-card, msft-shopping-coupon,\n div#divHomeNotification, msft-shopping-coupon-printable, div#divYoutubeCouponsNotification, msft-micro-feedback-item,\n msft-shopping-tooltip, #divPriceHistory svg, msft-shopping-cart:not([id="unselectable"]), rect.priceInsightBar,\n msft-shopping-section:not([slot="header-content"]), msft-shopping-coupon-new, msft-banner-card, msft-product-feed,\n div#packageTrackingAcknowledgementDescriptionDiv, msft-package-tracker-card-new, msft-travel-cheaper-flight-card, fluent-select\n ';class s{constructor(){(0,n.Z)(this,"container",void 0),(0,n.Z)(this,"currentFocusElement",void 0),(0,n.Z)(this,"isEdgeDriver",!1),(0,n.Z)(this,"flyoutData",void 0),(0,n.Z)(this,"initialize",((e,t,i)=>{this.container=e,this.isEdgeDriver=t,this.flyoutData=i,this.container.addEventListener("keydown",this.trapFocus)})),(0,n.Z)(this,"removeListeners",(()=>{this.container.removeEventListener("keydown",this.trapFocus)})),(0,n.Z)(this,"trapFocus",(e=>{if("Tab"!==e.key||e.ctrlKey||!this.container)return;let t=Array.prototype.slice.call(this.container.querySelectorAll('fluent-button[slot="header-actions"], a[slot="header-actions"], button[slot="header-actions"]'));const i=Array.prototype.slice.call(this.container.querySelectorAll('#divPinterestSubTitle[slot="header-content"], fluent-anchor[slot="header-content"], fluent-button[slot="header-content"], button[slot="header-content"], div#divYoutubeCouponsNotification, msft-shopping-tooltip#header-tooltip, msft-shopping-section[slot="header-content"] msft-shopping-coupon-new, div[slot="header-content"] msft-shopping-tooltip'));t.push.apply(t,i),this.flyoutData&&this.flyoutData.common.openedWith===o.Te.Auto&&this.flyoutData.common.popupOrigination===r.sR.AUTO_SHOW_PRICE_HISTORY&&(a+=", #divPriceHistorySection");let n=Array.prototype.slice.call(this.container.querySelectorAll(a));n=n.filter((e=>!i.includes(e))),t.push.apply(t,n),this.isEdgeDriver&&(t=t.filter((e=>"fluent-accordion"!==e.nodeName.toLowerCase()&&e.offsetHeight>0))),this.flyoutData&&this.flyoutData.common.openedWith===o.Te.Auto&&(t=t.filter((e=>"msft-micro-feedback-item"!==e.nodeName.toLowerCase())));const s=Array.prototype.slice.call(this.container.querySelectorAll('fluent-anchor[slot="footer"], fluent-button[slot="footer"],\n button[slot="footer"], #footerDiv fluent-button'));if(t=t.filter((e=>!s.includes(e))),t.push.apply(t,s),t&&t.length>0){const i=t[0];let n=t[t.length-1];for(const e of t)e.classList.contains("checkoutButton")&&(n=e);let o=document.activeElement;if(o){if("divOverlayWrapper"===o.id){const e=o.shadowRoot;e&&(o=e.activeElement)}if(o===i&&e.shiftKey){let t=n?.parentElement?.shadowRoot;if("previousCashBackSection"===n.parentElement?.id){const e=n.parentElement?.parentElement?.shadowRoot;if(e){const i=e.querySelector("fluent-accordion-item");if(i&&!i.classList.contains("expanded")){const e=i.shadowRoot?.querySelector("button");e&&(e.focus(),t=null)}}}if(t){const e=t.querySelector("fluent-accordion-item");if(e&&!e.classList.contains("expanded")){const t=e.shadowRoot?.querySelector("button");t&&t.focus()}else n.focus()}else"previousCashBackSection"!==n.parentElement?.id&&(n.focus(),e.preventDefault())}else o!==n||e.shiftKey||(i.focus(),e.preventDefault())}}}))}static getInstance(){return null===s.currentInstance&&(s.currentInstance=new s),s.currentInstance}static getFirstFocusableElementInParent(e){return e.querySelectorAll(a)[0]}makeFocusOnActiveElement(e){if(this.currentFocusElement===document.activeElement)return;const t=e.querySelectorAll(a);0!==t.length&&(t.forEach((e=>{document.activeElement!==e||(this.currentFocusElement=e)})),this.currentFocusElement&&this.currentFocusElement.focus())}}(0,n.Z)(s,"currentInstance",null),t.Z=s},57549:function(e,t,i){"use strict";i.d(t,{Z:function(){return P}});var n=i(72370),o=i(98557),r=i(4872),a=i(31656),s=i(31714),l=i(93209),c=i(12710),d=i(5144),u=i(88767),h=i(73557),p=i(27689),g=i(86743),f=i(27775),m=i(56764),v=i(87605),y=i(2388),C=i(84901);let b=function(e){return e.TOP_LEFT="TOP_LEFT",e.TOP_RIGHT="TOP_RIGHT",e.BOTTOM_LEFT="BOTTOM_LEFT",e.BOTTOM_RIGHT="BOTTOM_RIGHT",e}({});var S=i(86127),x=i(81687),T=i(65302),w=i(79710);class O{static CloseFooterOverlay(e,t){t.addEventListener("keydown",(t=>{"Tab"===t.key&&"hide"!==e.className&&(e.className="hide")}))}constructor(e,t,i,o,r){(0,n.Z)(this,"flyoutData",void 0),(0,n.Z)(this,"utilities",void 0),(0,n.Z)(this,"pageHandlerModule",void 0),(0,n.Z)(this,"logModule",void 0),(0,n.Z)(this,"userEngagementStoreManager",void 0),(0,n.Z)(this,"autoOpenControllerUtilities",void 0),(0,n.Z)(this,"snoozeMenu",void 0),(0,n.Z)(this,"dontShowMenu",void 0),this.flyoutData=e,this.utilities=t,this.pageHandlerModule=i,this.logModule=o,this.userEngagementStoreManager=r.userEngagementStoreManager,this.autoOpenControllerUtilities=r}async showFooter(){return(u.Te.Auto===this.flyoutData.common.openedWith&&!this.excludeFooter(this.flyoutData.common.popupOrigination))??!1}createSnoozeButton(e){const t=(0,w.s1)();t.id="snooze",t.textContent=this.flyoutData.strings.snoozeButton,t.title=this.getSnoozeHoverText();let{popupOrigination:i}=this.flyoutData.common;if(i===h.sR.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION){const t=this.utilities.getPwiloPopupOrigination(e);t&&(i=t)}const n={popupOriginationEnum:i};return t.addEventListener("click",(async()=>{this.pageHandlerModule.SendWPOInteractionEvent(i,u.N.Snooze);const e=new l.Z(d.$S.FlyoutSnooze,y.r.FOOTER,this.flyoutData.common.domain,JSON.stringify(n),this.flyoutData.common.flyoutId);this.pageHandlerModule.RecordAsUserAction(v.bS.FLYOUT_SNOOZED),this.logModule.LogInfoEvent(d.R.ButtonClick,"Flyout Snoozed",e,m.g.CouponImpressionId),this.flyoutData.common.popupOrigination&&a.R.isExperimentActive(r.H.CouponsPersonalization)&&await this.userEngagementStoreManager.addEngagement(C.w1.NEGATIVE,this.flyoutData.common.popupOrigination,void 0,c.e.userEngagementCouponWeights.snoozeBtnWeight,d.$S.FlyoutSnooze),await this.handleSnooze()})),t}createSnoozeWithOptionsButton(e,t){const i=(0,w.s1)();i.id="snoozeWithOptions",i.ariaHaspopup="menu";const n=(0,w.Ux)("SPAN");n.textContent=this.flyoutData.strings.snoozeButton,i.appendChild(n);const o=(0,w.Ux)("DIV",{style:"display: flex; align-items: center;"});o.innerHTML=(new f.Z).getArrowButtonIcon(),i.appendChild(o),this.snoozeMenu=document.createElement("fluent-menu"),this.snoozeMenu.id="snoozeOverlay",this.snoozeMenu.classList.toggle("hide"),this.utilities.shouldRenderSmallNotification()&&(this.snoozeMenu.style.width="89%",this.snoozeMenu.style.right="11px"),e.appendChild(this.snoozeMenu);const r=t.getFriendlyFeatureName(this.flyoutData.common.popupOrigination);return this.addSnoozeFeatureForSiteOption(r),this.addSnoozeNotificationsForSiteOption(),this.addSnoozeAllNotificationsOption(),t.handleClickOutsideMenu(this.flyoutData.common.shopping,this.snoozeMenu,i),t.manageMenuEvents(this.snoozeMenu,i,null),i}createDoNotShowButton(e,t,i,n){const o=(0,w.s1)();o.id="notshow",o.ariaHaspopup="menu",(0,w.Ux)("SPAN").textContent=this.flyoutData.strings.doNotShowString,o.innerText=this.flyoutData.strings.doNotShowString,o.title=this.flyoutData.strings.doNotShowString,o.role="menu",o.setAttribute("aria-expanded","false");const c=(0,w.Ux)("DIV",{style:"display: flex; align-items: center;"});c.innerHTML=(new f.Z).getArrowButtonIcon(),c.ariaHidden="true",o.appendChild(c),this.dontShowMenu=document.createElement("fluent-menu"),this.dontShowMenu.id="doNotShowOverlay",this.dontShowMenu.classList.toggle("hide"),this.dontShowMenu.style.width="89%",this.dontShowMenu.style.right="11px",e.appendChild(this.dontShowMenu);const u=document.createElement("fluent-menu-item"),g=t.getFriendlyFeatureName(this.flyoutData.common.popupOrigination),C=(0,p.fZ)("dontShowFeatureNameForSite",this.flyoutData.strings.dontShowFeatureNameForSite,g);u.textContent=C,u.title=C,u.className+=" defaultFontFamily",u.addEventListener("click",(()=>{let e=this.flyoutData.common.popupOrigination;if(e&&e===h.sR.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION){const t=this.utilities.getPwiloPopupOrigination(n);t&&(e=t)}const t=new l.Z(d.$S.DoNotShowFeatureForDomain,y.r.FOOTER);if(t.Metadata=JSON.stringify({popupOriginationEnum:e}),this.logModule.LogInfoEvent(d.R.ButtonClick,`${e}`,t),this.flyoutData.common.popupOrigination){let e=(0,T.vW)(this.flyoutData.common.popupOrigination);for(const t of e)a.R.isExperimentActive(r.H.autoOpenControllerScript)&&this.autoOpenControllerUtilities.pausePopupOriginationForDomain(t),t<63&&this.pageHandlerModule.DisablePopupForDomain(t)}this.pageHandlerModule.DismissPopup()})),O.CloseFooterOverlay(this.dontShowMenu,u),this.dontShowMenu.appendChild(u),this.flyoutData.common.popupOrigination===h.sR.AUTO_SHOW_COUPONS_CHECKOUT&&a.R.isExperimentActive(r.H.aaNoDontShowAgain)||t.addAutoShowItem(this.dontShowMenu,this.flyoutData.common.popupOrigination,!0);const P=document.createElement("fluent-menu-item");P.textContent=this.flyoutData.strings.commonCMManage,P.style.borderTop="1px solid #F1F1F1",P.className+="defaultFontFamily",P.addEventListener("change",(()=>{this.pageHandlerModule.RecordAsUserAction(v.bS.MANAGE);const e=new l.Z(d.$S.FlyoutManage,y.r.FOOTER);e.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.logModule.LogInfoEvent(d.R.ButtonClick,"Flyout Menu Manage",e),this.pageHandlerModule.TriggerExperiment(r.H.settingsPaneNavigateFromFlyout),a.R.isExperimentActive(r.H.settingsPaneNavigateFromFlyout)?this.pageHandlerModule.OpenPane(this.flyoutData.common.popupOrigination,!0):this.pageHandlerModule.NavigateToEdgeUrl("edge://settings/privacy#Shopping",S.$.NEW_FOREGROUND_TAB)})),O.CloseFooterOverlay(this.dontShowMenu,P),this.dontShowMenu.appendChild(P),a.R.isVariantActive(r.H.footerExperiments,s._K.MenuClientTeam)&&i.addEventListener(x.e1.MenuOptionClicked,(e=>{if(e&&e.detail&&void 0!==e.detail.idClicked){const t=e.detail.idClicked;0===t?(this.pageHandlerModule.DisablePopupForDomain(this.flyoutData.common.popupOrigination),this.pageHandlerModule.DismissPopup()):1===t?(this.pageHandlerModule.AllowAutoShow(!1,this.flyoutData.common.popupOrigination),this.pageHandlerModule.DismissPopup()):2===t&&this.pageHandlerModule.NavigateToEdgeUrl("edge://settings/privacy#Shopping",S.$.NEW_FOREGROUND_TAB)}}));const A={popupOriginationEnum:this.flyoutData.common.popupOrigination};return o.addEventListener("click",(()=>{const e=new l.Z(d.$S.DoNotShow,y.r.FOOTER,this.flyoutData.common.domain,JSON.stringify(A),this.flyoutData.common.flyoutId);if(a.R.isVariantActive(r.H.footerExperiments,s._K.MenuClientTeam)){const t=e=>{const t=new Array(e.length);for(let i=0;i<e.length;++i)t[i]=e.charCodeAt(i);return{data:t}};this.pageHandlerModule.OpenContextMenu([0,1,2],[t((0,p.fZ)("dontShowFeatureNameForSite",this.flyoutData.strings.dontShowFeatureNameForSite,g)),t((0,p.fZ)("dontShowFeatureName",this.flyoutData.strings.dontShowFeatureName,g)),t(this.flyoutData.strings.commonCMManage)],b.BOTTOM_RIGHT,-10,230),this.logModule.LogInfoEvent(d.R.ButtonClick,`${this.flyoutData.common.popupOrigination}`,e,m.g.CouponImpressionId)}})),t.handleClickOutsideMenu(this.flyoutData.common.shopping,this.dontShowMenu,o),a.R.isVariantActive(r.H.footerExperiments,s._K.MenuClientTeam)||t.manageMenuEvents(this.dontShowMenu,o,null),o}setFlyoutFooter(e,t,i){const n=(0,w.Ux)("DIV");let l,c;n.id="footerDiv",n.slot="footer",this.pageHandlerModule.TriggerExperiment(r.H.snoozeWithOptions),l=this.isSnoozeWithOptionsExpActive()?this.createSnoozeWithOptionsButton(n,t):this.createSnoozeButton(i),a.R.isVariantActive(r.H.footerExperiments,s._K.OnlySnooze)?n.style.gridTemplateColumns="100%":c=this.createDoNotShowButton(n,t,e,i),l&&n.appendChild(l),c&&n.appendChild(c),l&&c&&this.isSnoozeWithOptionsExpActive()&&this.snoozeMenu&&this.dontShowMenu&&(t.handleClickOutsideMenu(l,this.dontShowMenu,c),t.handleClickOutsideMenu(c,this.snoozeMenu,l)),this.flyoutData.common.shopping&&this.flyoutData.common.shopping.appendChild(n),o.SO.queueUpdate((()=>{const t=new CustomEvent(x.e1.FooterCreated);e.dispatchEvent(t)}))}setFlyoutFooterToWrapper(e,t,i){const n=(0,w.Ux)("DIV");n.id="footerDiv",n.slot="footer";const l=this.createSnoozeButton(i);let c;a.R.isVariantActive(r.H.footerExperiments,s._K.OnlySnooze)?(n.style.gridTemplateColumns="100%",n.classList.add("lateralMargin")):c=this.createDoNotShowButton(n,t,e,i),l&&n.appendChild(l),c&&n.appendChild(c),e&&e.appendChild(n),o.SO.queueUpdate((()=>{const t=new CustomEvent(x.e1.FooterCreated);e.dispatchEvent(t)}))}removeFooterButtons(){const e=document.querySelector("#snooze"),t=document.querySelector("#notshow");t?.remove(),e?.remove()}disableFooterButtons(){const e=document.querySelector("#snooze"),t=document.querySelector("#notshow");t&&(t.disabled=!0),e&&(e.disabled=!0)}excludeFooter(e){if(!a.R.isExperimentActive(r.H.snoozeAutoshow))return!0;const t=!!this.flyoutData.dataStoreModule?.VirtualCardData?.cardProvider,i=(0,T.fr)();return!!t&&((e===h.sR.AUTO_SHOW_COUPONS_CHECKOUT||void 0!==e&&i.includes(e)||e===h.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK||t)??!1)}async handleSnooze(){let e=this.getSnoozeList(),t=288e5;if(a.R.isExperimentActive(r.H.autoOpenControllerScript)){try{const e=a.R.getVariantName(r.H.snoozeAutoshow);e&&!isNaN(Number(e))&&Number(e)<1&&(t=60*Number(e)*1e3*60*8)}catch{}await this.autoOpenControllerUtilities.setUserPreferenceBatch(!1,e,this.flyoutData.common.disabledNotifications,t)}e=e.filter((e=>e<63)),this.pageHandlerModule.MuteFeatures(e,t/1e3),this.pageHandlerModule.DismissPopup()}addSnoozeAllNotificationsOption(){const e=document.createElement("fluent-menu-item");e.textContent=this.flyoutData.strings.snoozeAllNotifications,e.title=this.flyoutData.strings.snoozeAllNotificationsTooltip,e.className+="defaultFontFamily",e.addEventListener("click",(async()=>{const e=new l.Z(d.$S.SnoozeAllNotifications,y.r.FOOTER);this.logModule.LogInfoEvent(d.R.ButtonClick,`${this.flyoutData.common.popupOrigination}`,e),await this.handleSnooze(),this.pageHandlerModule.DismissPopup()})),O.CloseFooterOverlay(this.snoozeMenu,e),this.snoozeMenu.appendChild(e)}addSnoozeNotificationsForSiteOption(){const e=document.createElement("fluent-menu-item");e.textContent=this.flyoutData.strings.snoozeDomainNotifications,e.title=this.flyoutData.strings.snoozeDomainNotificationsTooltip,e.className+="defaultFontFamily",e.addEventListener("click",(async()=>{const e=new l.Z(d.$S.SnoozeNotificationsForDomain,y.r.FOOTER);if(this.logModule.LogInfoEvent(d.R.ButtonClick,`${this.flyoutData.common.popupOrigination}`,e),this.flyoutData.common.popupOrigination){const e=288e5,t=this.getSnoozeList();for(const i of t)await this.autoOpenControllerUtilities.pauseAutoOpenForPopupOrigination(i,e)}this.pageHandlerModule.DismissPopup()})),O.CloseFooterOverlay(this.snoozeMenu,e),this.snoozeMenu.appendChild(e)}addSnoozeFeatureForSiteOption(e){const t=document.createElement("fluent-menu-item"),i=(0,p.fZ)("snoozeOneDomainNotification",this.flyoutData.strings.snoozeOneDomainNotification,e),n=(0,p.fZ)("snoozeOneDomainNotificationTooltip",this.flyoutData.strings.snoozeOneDomainNotificationTooltip,e);t.textContent=i,t.title=n,t.className+="defaultFontFamily",t.addEventListener("click",(async()=>{const e=new l.Z(d.$S.SnoozeNotificationForDomain,y.r.FOOTER);if(this.logModule.LogInfoEvent(d.R.ButtonClick,`${this.flyoutData.common.popupOrigination}`,e),this.flyoutData.common.popupOrigination){const e=288e5;await this.autoOpenControllerUtilities.pauseAutoOpenForPopupOrigination(this.flyoutData.common.popupOrigination,e)}this.pageHandlerModule.DismissPopup()})),O.CloseFooterOverlay(this.snoozeMenu,t),this.snoozeMenu.appendChild(t)}getSnoozeList(){const e=Object.keys(h.sR).filter((e=>!isNaN(Number(e)))),t=[];for(const i of e){const e=parseInt(i,10);this.excludeFooter(e)||t.push(e)}return t}isSnoozeWithOptionsExpActive(){return!!this.flyoutData.common.popupOrigination&&a.R.isExperimentActive(r.H.snoozeWithOptions)&&a.R.isExperimentActive(r.H.autoOpenControllerScript)&&this.flyoutData.common.popupOrigination&&(0,g.Kv)(this.flyoutData.common.popupOrigination).status}getSnoozeHoverText(){return this.flyoutData.strings.snoozeHoverText}}var P=O},11542:function(e,t,i){"use strict";var n=i(88767),o=i(73557);class r{static GetProductIdsFromUrl(e){let t;const i=[];try{t=new URL(e)}catch(e){return i}const n=r.IsPDPURL(t);return n.IsPDP&&0!==n.ProductIds.length?(i.push(...n.ProductIds),i):i}static IsGroceryCashbackNotification(e,t){const i=e===o.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK||e===o.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK_LANDING;return t===n.Te.Auto&&i}static IsPDPURL(e){if(e.hostname.includes("amazon.com")){const t=e.pathname.match("/dp/([a-zA-Z0-9]+)($|/)|/gp/product/([a-zA-Z0-9]+)($|/)");if(t&&t.length>3)return{IsPDP:!0,ProductIds:[t[1]||t[3]]}}else if(e.hostname.includes("target.com")){const t=e.pathname.match("/p/.*/A-([a-zA-Z0-9]+)($|#|\\?)"),i=[];if(t&&t.length>1&&i.push(t[1]),e.searchParams.has("preselect")&&i.push(e.searchParams.get("preselect")||""),i.length>0)return{IsPDP:!0,ProductIds:i}}else if(e.hostname.includes("walmart.com")){const t=e.pathname.match("/ip/.*/([a-zA-Z0-9]+)($|#|\\?)");if(t&&t.length>1)return{IsPDP:!0,ProductIds:[t[1]]}}return{IsPDP:!1,ProductIds:[]}}}t.Z=r},75434:function(e,t,i){"use strict";i.d(t,{F0:function(){return Y},FV:function(){return L},H:function(){return H},IJ:function(){return M},Jp:function(){return Q},KG:function(){return ne},KI:function(){return G},L4:function(){return T},Li:function(){return W},QU:function(){return Z},Rv:function(){return J},S3:function(){return V},SI:function(){return q},Sz:function(){return te},WY:function(){return I},ZK:function(){return U},aI:function(){return S},bu:function(){return $},d5:function(){return x},dh:function(){return z},eD:function(){return K},eg:function(){return R},fU:function(){return k},kf:function(){return B},mS:function(){return E},oC:function(){return ie},r2:function(){return ee},rm:function(){return X},sS:function(){return b},t8:function(){return _},ut:function(){return N},w3:function(){return F},wB:function(){return A},xs:function(){return w},zJ:function(){return D}});var n=i(72370),o=i(64865),r=i(4872),a=i(31656),s=i(59645),l=i(5144),c=i(55590),d=i(64641),u=i(32389),h=i(33491),p=i(47746),g=i(31725),f=i(56764),m=(i(87605),i(11542)),v=i(49259);function y(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function C(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?y(Object(i),!0).forEach((function(t){(0,n.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):y(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}const b="redeemedCashback",S="filteredOffersMap",x="currentImpressionId",T="lastGroceryTransaction",w="activationSubmitted",O="groceryAnonymousUserIdentifier",P="isRebatesUserAfterSignIn",A={spb:{name:"Exclusive for you",id:"-2"},related:{name:"Related",id:"-1"},popular:{name:"Popular",id:"0"}};function E(e){(0,h.Xo)(P,void 0!==e?`${e}`:"")}function k(){const e=(0,h.Mw)(O)||"";return e||function(){const e="xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(e=>{const t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)}));return(0,h.Xo)(O,e),e}()}function I(e,t,i){try{const n=(0,h.hS)(b);(!n[e]||n[e]&&!n[e].submittedIds)&&(n[e]={submittedIds:[]}),n[e].submittedIds=t,n[e].impressionId=i;const o=JSON.stringify(n);(0,h.Xo)(b,o)}catch{}}function D(e,t,i,n,o){if(t)try{const r=t.id;(!o[e]||o[e]&&!o[e].fullItems)&&(o[e]={fullItems:{}});const a=new Date,s=24;t.addedTimestamp=a.getTime(),t.expAfterActivatingDate=a.setHours(a.getHours()+s),t.quotientTimestamp=u.Z.getQuotientDate(),o[e].impressionId=i,o[e].fullItems[r]=t,n.setStorageString(c.Q.GroceryCashbackActivated,JSON.stringify(o))}catch{}}async function _(e,t,i,n){if(t)try{const o=(await N(e,n)).activatedItemsMap;(!o[e]||o[e]&&!o[e].fullItems)&&(o[e]={fullItems:{}}),o[e].impressionId||(o[e].impressionId=i);const r=o[e].fullItems,a={};t.forEach((e=>{a[e.id]=e})),o[e].fullItems=C(C({},a),r),n.setStorageString(c.Q.GroceryCashbackActivated,JSON.stringify(o))}catch{}}async function N(e,t){let i=[],n={},o={};if(!e)return{activatedItems:i,activatedItemsList:n,activatedItemsMap:o};try{const r=await t.getStorageString(c.Q.GroceryCashbackActivated);o=r&&"undefined"!==r&&""!==r?JSON.parse(r):{},n=o[e]?o[e].fullItems??{}:{},i=Object.keys(n)??[]}catch(e){return{activatedItems:i,activatedItemsList:n,activatedItemsMap:o}}return{activatedItems:i,activatedItemsList:n,activatedItemsMap:o}}async function R(e){const t=e.muid??"",i=e.Anid??"";e.Anid="",e.muid="";const n={body:JSON.stringify(e),headers:{"Content-Type":"application/json","x-edge-anid":i,"x-muid":t},method:"POST"},o=await fetch("https://www.bing.com/grocery/universal/api/v1/edge/action",n),r=await o.json();return{isSuccess:r.success??!1,subId:r.subId??"",isDuplicateError:409===o.status}}async function M(e,t){try{const i={body:JSON.stringify(e),headers:{"Content-Type":"application/json","x-edge-anid":t},method:"POST"},n="https://www.bing.com/grocery/universal/api/v1/edge/receipt/submit",o=await fetch(n,i);return await o.json()}catch(e){return{success:!1}}}function L(e){const t=(0,d.kU)(e.common.lastCommittedURL,e.common.domain);return t?{isConfirmationPage:!0,purchaseIdFromUrl:t}:{isConfirmationPage:!0===e?.dataStoreModule?.CashBackData?.isConfirmationPage,purchaseIdFromUrl:t}}function B(e,t){const{UserInfo:i}=e.dataStoreModule;return i.isRebatesUser||F(e)&&(t?(n=t,!!(Array.isArray(n.activatedOffers)&&n.activatedOffers.length>0)||!!(Array.isArray(n.submittedOfferIds)&&n.submittedOfferIds.length>0)):function(e){const t=e?.dataStoreModule?.GroceryCashbackData?.Cashback;return!!t&&(t.ActivatedOffers?.length>0||t.SubmittedOfferIds.length>0)}(e))||"true"===(0,h.Mw)(P);var n}function F(e){const{UserInfo:t}=e.dataStoreModule;return t.isMSASignedIn}function U(e){return e.dataStoreModule.ApiData?.impressionId??""}async function H(e){const t=await e.GetAnid(!0);return t?.anid??""}async function $(e,t,i){await Z(e,t,[i.id])}async function Z(e,t,i){if(B(e)){const n=U(e),o=await H(t),r=e.common.domain;o&&await async function(e,t,i,n,o){const r={activateOffersBody:C({offers:e},{}),domainName:n,impressionId:i},a={body:JSON.stringify(r),headers:{"Content-Type":"application/json","x-edge-anid":t},method:"POST"};await fetch("https://www.bing.com/grocery/universal/api/v1/edge/activate",a)}(i,o,n,r)}}async function V(e,t,i,n,r){let a,d,u="",h=[],p=!1,f="",m=!1,v=!1,y=[];const C=await e.getStorageString(c.Q.ICCurrentPageInfo),b=t.common.lastCommittedURL;if((0,o.TF)(C)){const e=new s.Z(l.xu.GroceryCashbackNotification),o={lastcommitedURL:b,query:i?.searchParams?.get("k")??"",domain:t.common.domain};e.Metadata=JSON.stringify(o),n.LogInfoEvent(l.R.EdgeFlyoutStatus,"Grocery auto show empty currentPageInfo",e)}else try{const e=JSON.parse(C),o=e.cashbackData;if(p=o?.itemizedCashBackResponse?.shouldAutoshow??!1,f=o?.impressionId??"",e){if("search"===e.type){let t=e.query;t||b&&(t=i?.searchParams?.get("k")??""),u=t,h=j(o),a=l.e4.SearchPage,m=!0}else"category"!==e.type&&"categoryAutoshow"!==e.type||(h=j(o),e.categoryName&&(u=e.categoryName),a=l.e4.CategorySearchPage,d=!1,v=!0);if(e.currentUrl!==b&&"search"===e.type&&p){const i=new s.Z(l.xu.GroceryCashbackNotification),o={lastcommitedURL:b,pageInfoUrl:e.currentURL,currentPageInfo:e,domain:t.common.domain,isAutoshow:p};i.Metadata=JSON.stringify(o),n.LogInfoEvent(l.R.EdgeFlyoutStatus,"Grocery auto show url conflict",i)}}if(y=r?h.filter((e=>!r.has(e.id))):h,e.currentUrl!==b&&"search"===e.type&&p){const i=new s.Z(l.xu.GroceryCashbackNotification),o={lastcommitedURL:b,pageInfoUrl:e.currentURL,currentPageInfo:e,domain:t.common.domain,isAutoshow:p,offerItems:y};i.Metadata=JSON.stringify(o),n.LogInfoEvent(l.R.EdgeFlyoutStatus,"Grocery auto show url conflict",i)}}catch(e){}return new g.Z(p,a,u,y,d,f,m,v)}function G(e){const t=e?.searchCategoryData?.cashbackItemsFromSearchAndCategory&&e.searchCategoryData.cashbackItemsFromSearchAndCategory.length>0,i=e?.Cashback?.pdpCashBack&&(e.Cashback.pdpCashBack.pdpOffer||e.Cashback.pdpCashBack.relatedOffers.length>0);return t||i}function j(e){const t={};if(e&&e?.itemizedCashBackResponse?.offers&&e?.itemizedCashBackResponse?.offers.length>0)for(const i of e.itemizedCashBackResponse.offers){const e=p.Z.Create(i);z(e)&&!t[e.id]&&(t[e.id]=e)}return Object.values(t)}function z(e){return function(e){return Boolean(e.offerValue&&e.id&&e.cashbackProducts.length>0&&e.cashbackProducts[0].image&&e.cashbackProducts[0].title&&e.cashbackProducts[0].upc&&e.cashbackProducts[0].url)}(e)}async function W(e,t){try{const i=(await N(e,t)).activatedItemsMap;i&&i[e]&&(Object.values(i[e].fullItems).forEach((t=>{(function(e){return!!e.expAfterActivatingDate&&(new Date).getTime()>e.expAfterActivatingDate})(t)&&delete i[e][t.id]})),t.setStorageString(c.Q.GroceryCashbackActivated,JSON.stringify(i)))}catch(e){}}async function K(e,t){const i=await async function(e,t,i){let n=[];const o=e.dataStoreModule.GroceryCashbackData?.Cashback;if(t){const i=(X(await t.getStorageString(c.Q.GroceryCashbackActivated))??{})[e.common.domain]??void 0;n=i?.fullItems?Object.keys(i.fullItems):[]}if(o){const e=o.ActivatedOffers.map((e=>e.id));n.push(...e)}return n}(e,t),n=q(e),o=n?[...n]:[];return new Set([...i,...o])}function q(e){const t=e.dataStoreModule.GroceryCashbackData?.Cashback,i=t?.SubmittedOfferIds;if(i&&i.length>0)return new Set(i)}function Y(e,t,i,n,o,r={},a){const c=new s.Z(a||l.xu.GroceryCashbackError),d=ee(e,o??"");c.Metadata=JSON.stringify(C(C(C({isError:!0,errorStr:n?JSON.stringify(n):""},d),r),{},{message:i})),t&&t.LogInfoEvent(l.R.EdgeFlyoutStatus,i,c,f.g.CouponImpressionId)}function X(e){try{if(!e)return;return JSON.parse(e)}catch(e){return}}function J(e,t,i,n,o,r={}){const a=new s.Z(i),c=ee(e,o??"");a.Metadata=JSON.stringify(C(C(C({},c),r),{},{message:n})),t.LogInfoEvent(l.R.EdgeFlyoutStatus,n,a,f.g.CouponImpressionId)}function Q(e,t,i,n,o,r,a={},c){try{const d=new s.Z(c||e?l.xu.CashbackError:l.xu.CashbackInfo),u=ee(t,r??"");d.Metadata=JSON.stringify(C(C(C({isError:e,errorStr:o?JSON.stringify(o):""},u),a),{},{message:n})),i&&i.LogInfoEvent(l.R.EdgeFlyoutStatus,n,d,f.g.CouponImpressionId)}catch(e){}}function ee(e,t){const i=void 0!==e?.dataStoreModule?.ICVariations?Object.fromEntries(e.dataStoreModule.ICVariations):{},n=v.Z.getFactory().getCasbackContext();return e?{bingSignedInUser:e.dataStoreModule.UserInfo.isBingSignedInUser,isPane:e.common.isPane,isRebatesEnabled:e.common.isRebatesEnabled,isRebatesUser:e.dataStoreModule.UserInfo.isRebatesUser,msaSignedInUser:e.dataStoreModule.UserInfo.isMSASignedIn,openedWith:e.common.openedWith,pageType:t??"",popupOrigination:e.common.popupOrigination,url:n.getCurrentUrl(),domain:e.common.domain,variations:i,anonymousUserId:e.dataStoreModule.UserInfo.anonymousUserId,channel:e.common.channel,isAnonymousFlowEnabled:e.dataStoreModule.UserInfo.isAnonymousFlowEnabled,isAad:e.dataStoreModule.UserInfo.isAadEmailPresent,searchQuerySpb:e.dataStoreModule.SPBItemizedCashbackData?.searchQuery||"",categoryNameSpb:e.dataStoreModule.SPBItemizedCashbackData?.categoryName||"",searchQueryQt:e.dataStoreModule.GroceryCashbackData?.searchCategoryData?.searchQuery||"",categoryNameQt:e.dataStoreModule.GroceryCashbackData?.searchCategoryData?.categoryName||"",pdpDataSpb:e.dataStoreModule.SPBItemizedCashbackData?.SpbPDPData?.pdpData,pdpDataQt:e.dataStoreModule.GroceryCashbackData?.Cashback?.pdpCashBack?.pdpData,isAOCActive:a.R.isExperimentActive(r.H.autoOpenControllerScript),isDiscoverPane:e.common.isDiscoverPane,cashbackMetadata:e.dataStoreModule.CashBackData?.CreateLogMetadata()}:{pageType:t??""}}function te(e,t){if(t)for(const i of t){const t=ie(new URL(i.cashbackProducts[0].url));if(t.IsPDP){const i=t.ProductId;if(-1!==e.pathname.indexOf(i))return!0}}return!1}function ie(e){const t=m.Z.IsPDPURL(e);return t.IsPDP&&t.ProductIds.length>0?{IsPDP:!0,ProductId:t.ProductIds[0]}:{IsPDP:!1,ProductId:""}}function ne(e){const t=(0,h.hS)(S)[e.common.domain];return t?.data?new Map(JSON.parse(t.data)):void 0}},64550:function(e,t,i){"use strict";i.d(t,{U:function(){return r}});var n=i(5144),o=i(33491);function r(e,t=location.href,i){if("true"===(0,o.Mw)("isPDP")||i?.entity?.name)return n.GV.ProductPage;if(!e)return n.GV.NonShoppingPage;const r=e.GetCurrentCheckoutPage();return r&&r.pageType||(e.IsConfirmationPage(t)?n.GV.ConfirmationPage:n.GV.UnknownPage)}},93978:function(e,t,i){"use strict";i.d(t,{H8:function(){return p},HX:function(){return a},Jh:function(){return l},Kc:function(){return s},T$:function(){return n},Uo:function(){return d},YE:function(){return h},Zl:function(){return u},_X:function(){return c},dV:function(){return o},e6:function(){return g},eg:function(){return r},z2:function(){return f}});const n=new Set(["en-us"]),o=new Set(["ar-sa","da-dk","de-de","de-at","de-ch","de-li","el-gr","en-us","en-au","en-ca","en-gb","en-ie","en-in","en-my","en-nz","en-ph","en-za","es-es","es-ar","es-cl","es-co","es-mx","es-pe","es-ve","fi-fi","fr-fr","fr-be","hu-hu","it-it","ja-jp","nb-no","nl-nl","nl-be","pl-pl","pt-pt","pt-br","sv-se","tr-tr","zh-hk","zh-tw"]),r=new Set(["en-us"]),a=new Set(["en-us"]),s=new Set(["en-us"]),l=new Set(["da-dk","de-de","de-at","de-ch","de-li","el-gr","en-us","en-au","en-ca","en-gb","en-ie","en-in","en-za","es-es","es-ar","es-cl","es-mx","fi-fi","fr-fr","hu-hu","it-it","ja-jp","nb-no","nl-nl","nl-be","pl-pl","pt-pt","pt-br","sv-se","tr-tr"]),c=new Set(["de-de","en-us","en-au","en-ca","en-in","en-gb","fr-fr"]),d=new Set(["da-dk","de-de","de-at","de-ch","en-us","en-au","en-ca","en-es","en-gb","en-id","en-ie","en-in","en-my","en-nz","en-ph","en-sg","en-th","en-vn","es-mx","es-ar","es-cl","es-co","es-pe","es-us","es-ve","fi-fi","fr-fr","fr-be","fr-ca","fr-ch","it-it","nl-nl","nl-be","no-no","pt-br","sv-se","zh-hk","zh-tw"]),u=new Set(["en-us"]),h=(new Set(["en-us"]),new Set(["da-dk","de-de","en-us","en-au","en-ca","en-es","en-gb","en-in","en-nz","en-sg","es-mx","es-us","fr-fr","fr-be","fr-ca","ja-jp","it-it","pt-br"])),p=new Set(["en-us","en-in","en-au","en-ca","es-mx","en-my","en-za","es-ar","zh-hk","zh-tw","en-sg","en-ph","en-nz","es-pe","es-ve","es-cl","en-ae"]),g=new Set(["en-us","en-gb","en-in","en-au","en-ca","ja-jp","fr-fr","de-de","es-es","it-it","nl-nl","fr-be","de-at","de-ch","nb-no","sv-se","en-ie"]),f=new Set(["en-us","en-au","en-ca","en-in"])},81687:function(e,t,i){"use strict";i.d(t,{IY:function(){return c},e1:function(){return l},eT:function(){return d}});var n=i(72370),o=i(59645),r=i(5144),a=i(88767),s=i(56764);let l=function(e){return e.onCashbackActivationError="onCashbackActivationError",e.onCashBackActivated="onCashBackActivated",e.onDelayedCashBackActivated="onDelayedCashBackActivated",e.onCashBackActivatedForRewards="onCashBackActivatedForRewards",e.telemetryCashBackActivationError="telemetryCashBackActivationError",e.onSignedInAndEnrolledInRebates="onSignedInAndEnrolledInRebates",e.onSignedInAndEnrolledInRebatesFailed="onSignedInAndEnrolledInRebatesFailed",e.telemetryCashBackActivated="telemetryCashBackActivated",e.StyleActivatedState="StyleActivatedState",e.StyleProcessingState="StyleProcessingState",e.CreateCommissionArrow="CreateCommissionArrow",e.CreateModules="CreateModules",e.CreateFeedbackModule="CreateFeedbackModule",e.CreateShortFeedbackModule="CreateShortFeedbackModule",e.ModulesRendered="ModulesRendered",e.PWILOPriceHistory="PWILOPriceHistory",e.onRebatesTelemetrySuccess="onRebatesTelemetrySuccess",e.onRebatesTelemetryFail="onRebatesTelemetryFail",e.onRewardsTelemetrySuccess="onRewardsTelemetrySuccess",e.onRewardsTelemetryFail="onRewardsTelemetryFail",e.onFlyoutResize="onFlyoutResize",e.rebatesNotActivating="rebatesNotActivating",e.rebatesSignInPendingSuccess="rebatesSignInPendingSuccess",e.rebatesSignInFail="rebatesSignInFail",e.rebatesFetchUserInfoFail="rebatesFetchUserInfoFail",e.PDPUpdate="PDPUpdate",e.onDataUpdate="onDataUpdate",e.domainEligibility="domainEligibility",e.pdpEligibility="pdpEligibility",e.flyoutRefresh="flyoutRefresh",e.PWILODeleted="PWILODeleted",e.WinCartDeleted="WinCartDeleted",e.PWILOEmpty="PWILOEmpty",e.PDPRemoved="PDPRemoved",e.CreateCBLearnMore="CreateCBLearnMore",e.FooterCreated="FooterCreated",e.ReRankFlyout="ReRankFlyout",e.MenuOptionClicked="MenuOptionClicked",e.RequestRefresh="RequestRefresh",e.FocusProductCollections="FocusProductCollections",e.FocusProductTracking="FocusProductTracking",e.FocusshoppingTrips="FocusShoppingTrips",e.ProductTrackingUpdate="ProductTrackingUpdate",e.InboxCouponUserLoggedIn="InboxCouponUserLoggedIn",e.InboxCouponUserDisconnected="InboxCouponUserDisconnected",e.ActiveRetailerInboxCouponsEmpty="ActiveRetailerInboxCouponsEmpty",e.InboxCouponsOpenSettings="InboxCouponsOpenSettings",e.InboxCouponsUpsellTriggered="InboxCouponsUpsellTriggered",e.ClientEngagement="ClientEngagement",e.ClientAction="ClientAction",e.OnFlyoutDismissed="OnFlyoutDismissed",e.HomeTabActive="HomeTabActive",e.SeeMoreClick="SeeMoreClick",e.ToastNotification="ToastNotification",e.CompleteEntityExtracted="CompleteEntityExtracted",e.ChangeContextualTitle="ChangeContextualTitle",e.ShoppingSettingsOpened="ShoppingSettingsOpened",e.InboxCouponsEdgeUserSuccsefullySignedIn="InboxCouponsEdgeUserSuccsefullySignedIn",e.InboxCouponsEdgeUserWorkProfileSuccsefullySignedIn="InboxCouponsEdgeUserWorkProfileSuccsefullySignedIn",e}({}),c=function(e){return e.topModuleName="topModuleName",e.topContextualModuleName="topContextualModuleName",e.topModulePriority="topModulePriority",e.renderedViewModuleCount="renderedViewModuleCount",e.modulesRendered="modulesRendered",e.isProductDetailPage="isProductDetailPage",e.pcLowestPriceImpression="pcLowestPriceImpression",e.multiPcImpressions="multiPcImpressions",e.canRenderAutoApply="canRenderAutoApply",e.ICOffersRendered="ICOffersRendered",e.nonICPDP="nonICPDP",e.ICRelatedOffersExist="ICRelatedOffersExist",e.icPdpAvailable="icPdpAvailable",e.isTrackingToggleRendered="isTrackingToggleRendered",e.pdpForActivatedAd="pdpForActivatedAd",e.outOfFlow="outOfFlow",e.shouldChangeTitle="shouldChangeTitle",e.renderedModules="renderedModules",e}({});const d=e=>new CustomEvent(l.ToastNotification,{detail:e});class u{constructor(e,t){(0,n.Z)(this,"logModule",void 0),(0,n.Z)(this,"shopping",void 0),(0,n.Z)(this,"renderedModules",void 0),this.logModule=e,this.shopping=t,this.renderedModules=new Set,this.cleanStateMapping(),this.cleanShoppingEventListeners()}getState(e){return u.stateMapping.get(e)}setState(e,t){u.stateMapping.set(e,t)}addEventListener(e,t){try{this.addShoppingEventListener(e,t),this.shopping.addEventListener(e,t)}catch(t){const i=s.g.EdgeImpressionId,n=new o.Z(r.xu.OnErrorInvoked);this.logModule.LogErrorEvent(r.R.EdgeFlyoutStatus,`addEventListener exception: ${e} ${t}`,n,i)}}removeEventListener(e,t){try{this.shopping.removeEventListener(e,t),this.removeShoppingEventListener(e,t)}catch(t){const i=s.g.EdgeImpressionId,n=new o.Z(r.xu.OnErrorInvoked);this.logModule.LogErrorEvent(r.R.EdgeFlyoutStatus,`removeEventListener exception: ${e} ${t}`,n,i)}}dispatchEvent(e){try{this.shopping.dispatchEvent(e)}catch(t){const i=s.g.EdgeImpressionId,n=new o.Z(r.xu.OnErrorInvoked);this.logModule.LogErrorEvent(r.R.EdgeFlyoutStatus,`dispatchEvent exception: ${e?.type} ${t}`,n,i)}}AddDiscoverRenderModule(e){this.renderedModules.add(e)}CanDiscoverRender(e){return e in a.ModuleNames&&this.renderedModules.has(a.ModuleNames[e])}cleanStateMapping(){u.stateMapping=new Map}cleanShoppingEventListeners(){try{u.wrapperEventListener.forEach(((e,t)=>{e.forEach((e=>{this.shopping.removeEventListener(t,e)}))})),u.wrapperEventListener.clear()}catch(e){this.logModule.LogErrorEvent,new o.Z(r.xu.RefreshError),r.R.EdgeFlyoutStatus}}addShoppingEventListener(e,t){u.wrapperEventListener.has(e)||u.wrapperEventListener.set(e,new Set),u.wrapperEventListener.get(e)?.add(t)}removeShoppingEventListener(e,t){u.wrapperEventListener.get(e)?.delete(t)}}(0,n.Z)(u,"stateMapping",new Map),(0,n.Z)(u,"wrapperEventListener",new Map),t.ZP=u},23582:function(e,t,i){"use strict";var n=i(72370);let o=!1;const r=e=>!!(e instanceof Array&&Object.isFrozen(e)),a=(e,t)=>(e=>{if(r(e)&&e.raw&&r(e.raw)&&e.length===e.raw.length&&1===e.length)return e.join("");if(o)return e.join("");throw new TypeError("Static Types only allows static Template literals")})(t),s={createHTML:a,createScript:a,createScriptURL:a};class l{static getTrustedHTML(e){return this.staticPolicy.createHTML("",e)}static getTrustedScript(e){return this.staticPolicy.createScript("",e)}static getTrustedScriptURL(e){return this.staticPolicy.createScriptURL("",e)}static setStoryBook(){o=!0}}(0,n.Z)(l,"staticPolicy",window.trustedTypes?window.trustedTypes.createPolicy("shopping-static",s):s),t.Z=l},91221:function(e,t,i){"use strict";i.d(t,{Z:function(){return m}});var n=i(72370),o=i(64865),r=i(59645),a=i(5144),s=i(91495),l=i(27689),c=i(21650);class d{constructor(){(0,n.Z)(this,"intValue",void 0)}static Create(e){const t=new d;return t.intValue=e.intValue,t}static CreateFromInteger(e){const t=new d;return t.intValue=e,t}}var u=d;class h{constructor(){(0,n.Z)(this,"nullValue",void 0)}static Create(e){const t=new h;return t.nullValue=e.nullValue,t}}var p=h,g=i(96834);class f{static hasNotificationBeenShownRecently(e,t){try{if(void 0===f.storage)return!1;const i=f.storage[e];if(i&&""!==i){const e=(new Date).toUTCString();return new Date(e).getTime()-new Date(i).getTime()<t}return!1}catch(e){return!1}}constructor(e,t,i){let o;(0,n.Z)(this,"pageHandlerModule",void 0),(0,n.Z)(this,"logModule",void 0),(0,n.Z)(this,"storageEmpty",void 0),(0,n.Z)(this,"autoClearedKeySubstrings",void 0),(0,n.Z)(this,"customCleaningKeys",void 0),(0,n.Z)(this,"storageCleanerKey","StorageCleaner"),(0,n.Z)(this,"cleaningSchedule",6048e5),t&&(o=t.GetLoadTimeDataValue("storage",void 0)),this.logModule=i,this.storageEmpty=!1,o?(s.Q.setRawStorageObject(o),f.storage=s.Q.rawStorageObj):this.storageEmpty=!0,this.pageHandlerModule=e,this.autoClearedKeySubstrings=["SuggestedCoupons","OtherSellers","price","EstimatedCashback","BackgroundAutoApplyData","InboxCouponsResponseCache","InboxCouponsAuthToken","isCheckoutPage","CashbackProductUrl"],this.customCleaningKeys=["AutoOpenData","AutoOpenDomainPrefData","AutoOpenPrefData","AAConsentData","InboxCouponsGetAllCouponsResponseCache","InboxCouponsUserEmailsStatusCache","UserConsentedInboxCoupon",this.storageCleanerKey]}async getStorageBool(e){let t=f.storage[e];return this.storageEmpty&&(t=await this.pageHandlerModule.GetStorageValue(e),t=t?.value?.boolValue),t||null}async getStorageInteger(e){let t=f.storage[e];return this.storageEmpty&&(t=await this.pageHandlerModule.GetStorageValue(e),t=t?.value?.intValue),t||NaN}async getStorageString(e,t){let i=f.storage[e];return(this.storageEmpty||t&&(!i||""===i||null===i))&&(i=await this.pageHandlerModule.GetStorageValue(e),i=i?.value?.stringValue,f.storage[e]=i),i?.value?"string"!=typeof i.value?JSON.stringify(i.value):i.value:"string"!=typeof i?JSON.stringify(i):i||""}setStorageBool(e,t){this.storageEmpty=!1,f.storage[e]=t,this.pageHandlerModule.SetStorageValue(e,c.Z.CreateFromBool(t))}setStorageInteger(e,t){this.storageEmpty=!1,f.storage[e]=t,this.pageHandlerModule.SetStorageValue(e,u.CreateFromInteger(t))}setStorageString(e,t){this.storageEmpty=!1,f.storage[e]=t,this.pageHandlerModule.SetStorageValue(e,g.Z.CreateFromString(t))}setStorageValueByDottedPath(e,t){this.storageEmpty=!1,f.storage[e]=t,this.pageHandlerModule.SetStorageValueByDottedPath(e,g.Z.CreateFromString(t))}async getStorageValueByDottedPath(e){let t=f.storage[e];return this.storageEmpty&&(t=await this.pageHandlerModule.GetStorageValueByDottedPath(e),t=t?.value?.stringValue),t?.value?"string"!=typeof t.value?JSON.stringify(t.value):t.value:"string"!=typeof t?JSON.stringify(t):t||""}clearStorage(e){this.pageHandlerModule.SetStorageValue(e,new p)}clearStorageByDottedPath(e){this.pageHandlerModule.ClearStorageValue(e)}async scheduledStorageCleaner(){const e=await this.getStorageString(this.storageCleanerKey);if(e&&e&&"{}"!==e){const t=(0,l.BQ)(e,!0);if(Date.now()-t<this.cleaningSchedule)return}const t=Object.getOwnPropertyNames(s.Q);t&&(t.forEach((e=>{if(s.Q[e]&&-1===this.customCleaningKeys.findIndex((t=>e.includes(t))))if(-1!==this.autoClearedKeySubstrings.findIndex((t=>e.includes(t))))this.clearStorage(e);else{let t=s.Q[e];if("string"!=typeof s.Q[e]&&(t=JSON.stringify(s.Q[e])),t.length>1e5){this.clearStorage(e);const t=new r.Z(a.xu.StorageLimitReached);this.logModule.LogInfoEvent(a.R.EdgeFlyoutStatus,"storage bigger than 100K",t)}}})),this.setStorageString(this.storageCleanerKey,Date.now().toString()))}async clearDomainMappedStringStorage(e,t,i){if(!e||!t)return;let n;if(i)n=i;else{const t=await this.getStorageString(e);if(!(0,o.TF)(t))try{n=JSON.parse(t)??{}}catch(e){}}n&&(n[t]=null,this.setStorageString(e,JSON.stringify(n)))}}(0,n.Z)(f,"storage",[]);var m=f},65302:function(e,t,i){"use strict";i.d(t,{Uy:function(){return re},YU:function(){return ie},H6:function(){return oe},Pw:function(){return ne},fr:function(){return ae},ZP:function(){return ye},UO:function(){return le},y6:function(){return he},VR:function(){return se},ws:function(){return pe},Hg:function(){return de},Wy:function(){return ue},et:function(){return ce},vW:function(){return ge},gQ:function(){return me},g7:function(){return fe},tB:function(){return ve}});var n=i(72370),o=i(4872),r=i(31656),a=i(59645),s=i(5144),l=i(93190),c=i(73557),d=i(56764),u=i(64865),h=i(21597),p=i(87720),g=i(3141),f=i(50033),m=i(20400),v=i(56372),y=i(29247),C=i(63173),b=i(18519),S=i(17675),x=i(13018),T=i(12710),w=i(54775),O=i(68793),P=i(88767),A=i(84901),E=i(86743);let k=function(e){return e.Path="Path",e.Domain="Domain",e.All="All",e.StageAndCategory="StageAndCategory",e}({});class I extends v.Z{constructor(...e){super(...e),(0,n.Z)(this,"userEngagementStoreManager",void 0),(0,n.Z)(this,"logModule",void 0),(0,n.Z)(this,"storageHandler",void 0),(0,n.Z)(this,"pageHandlerModule",void 0),(0,n.Z)(this,"flyoutData",void 0)}init(e,t,i,o,r){this.initCommonInfo(r,e.common.domain,e.common.lastCommittedURL,s.G7.Flyout),this.flyoutData=e,this.logModule=t,this.storageHandler=i,this.pageHandlerModule=o,this.sendErrorMessage=this.sendFlyoutErrorMessage.bind(this),this.sendStorageMessage=this.sendFlyoutStorageMessage.bind(this);const l=this.flyoutData.dataLoader.GetLoadTimeDataValue("coupons",[]).length>0&&this.flyoutData?.common?.pageStatus?.AutoApplyStatus;this.userEngagementStoreManager=new class{constructor(e,t,i){(0,n.Z)(this,"hasPositiveEngagements",void 0),(0,n.Z)(this,"logModule",void 0),(0,n.Z)(this,"storageHandler",void 0),(0,n.Z)(this,"isAutoApplyCoupons",void 0),(0,n.Z)(this,"engagementType",void 0),this.logModule=t,this.storageHandler=e,this.isAutoApplyCoupons=i,this.hasPositiveEngagements=!1}async addEngagement(e,t,i,n=1,o){try{if(this.engagementType=e,!t&&i&&(t=this.getPopupOriginationFromRenderedModule(i)),!t)return;if(t===c.sR.AUTO_SHOW_REBATES_CHECKOUT&&this.isAutoApplyCoupons&&(t=c.sR.AUTO_SHOW_COUPONS_CHECKOUT),e===A.w1.NEGATIVE&&o===s.$S.NotificationDismiss&&this.hasPositiveEngagements)return;const r=await this.storageHandler.getStorageString(T.e.storageKeys.userEngagementDataKey),a=this.createUserEngagementMapIfNotExists(r,t),l=this.createUserEngagementDataIfNotExists(a,t);this.updateUserEngagementData(e,l,n,o),a.set(t.toString(),l),this.storeUserEngagementMap(a);const d=this.getEngagementResults(l),u=new x.Z(d);await this.updateRuleBasedTriggerData(t,u)}catch(e){const t=new a.Z(s.xu.OnErrorInvoked);this.logModule.LogErrorEvent(s.R.EdgeFlyoutStatus,`Error adding user engagement ${e}`,t)}}async increaseCouponExpectationWeight(e,t){if(!e&&t&&(e=this.getPopupOriginationFromRenderedModule(t)),void 0===e){const e=new a.Z(s.xu.OnErrorInvoked);return void this.logModule.LogErrorEvent(s.R.EdgeFlyoutStatus,`Undefined popup origination - can't increase coupon expectation weight. renderedModule: ${t}`,e)}const i=new x.Z(void 0,S.l.defaultCouponExpectationWeight+2);await this.updateRuleBasedTriggerData(e,i)}async increasecIndexExpectationWeight(e,t){if(!e&&t&&(e=this.getPopupOriginationFromRenderedModule(t)),void 0===e){const e=new a.Z(s.xu.OnErrorInvoked);return void this.logModule.LogErrorEvent(s.R.EdgeFlyoutStatus,`Undefined popup origination - can't increase ax shopping index expectation weight. renderedModule: ${t}`,e)}const i=new x.Z(void 0,S.l.defaultCouponExpectationWeight+2);await this.updateRuleBasedTriggerData(e,i)}async trackNotification(e){if(void 0===e)return;const t=new Date,i=t.toISOString(),n=await this.storageHandler.getStorageString(S.l.ruleBasedTriggerDataKey),o=this.createRuleBasedTriggerMapIfNotExists(n,e),r=this.createRuleBasedTriggerDataIfNotExists(o,e);let a=r?.notificationTracker;if(void 0===a)a=new b.Z,a.perMinFirstTriggered=i,a.perMinCount=1,a.perHourFirstTriggered=i,a.perHourCount=1,a.perDayFirstTriggered=i,a.perDayCount=1;else{const e=(t.getTime()-new Date(a.perMinFirstTriggered).getTime())/6e4,n=(t.getTime()-new Date(a.perHourFirstTriggered).getTime())/36e5,o=(t.getTime()-new Date(a.perDayFirstTriggered).getTime())/864e5;e<1?a.perMinCount+=1:(a.perMinFirstTriggered=i,a.perMinCount=1),n<1?a.perHourCount+=1:(a.perHourFirstTriggered=i,a.perHourCount=1),o<1?a.perDayCount+=1:(a.perDayFirstTriggered=i,a.perDayCount=1)}r.notificationTracker=a,await this.updateRuleBasedTriggerData(e,r)}createUserEngagementMapIfNotExists(e,t){if((0,u.TF)(e))return this.initializeUserEngagementMap(t);try{return JSON.parse(e,y.ZP.ParseMap)}catch(i){const n=new a.Z(s.xu.OnErrorInvoked);return this.logModule.LogErrorEvent(s.R.EdgeFlyoutStatus,`User engagement map parsing error ${i} - userEngagementMapStorage = ${JSON.stringify(e)}`,n),this.initializeUserEngagementMap(t)}}createRuleBasedTriggerMapIfNotExists(e,t){if((0,u.TF)(e))return this.initializeRuleBasedTriggerMap(t);try{return JSON.parse(JSON.parse(e),y.ZP.ParseMap)}catch(i){const n=new a.Z(s.xu.OnErrorInvoked);return this.logModule.LogErrorEvent(s.R.EdgeFlyoutStatus,`Rule Based Trigger map parsing error ${i} - ruleBasedTriggerMapStorage = ${JSON.stringify(e)}`,n),this.initializeRuleBasedTriggerMap(t)}}createUserEngagementDataIfNotExists(e,t){let i=e?.get(t.toString());return i||(i=new w.Z),i}createRuleBasedTriggerDataIfNotExists(e,t){let i=e?.get(t.toString());return i||(i=new x.Z),i}getEngagementResults(e){const t=new O.Z,i=e.positiveEngagementCount+e.negativeEngagementCount;return t.positiveEngagementScore=e.positiveEngagementCount/i,t.totalEngagementsCount=i,t}initializeUserEngagementMap(e){const t=new Map,i=new w.Z;return t.set(e.toString(),i),t}initializeRuleBasedTriggerMap(e){const t=new Map,i=new x.Z(new O.Z);return t.set(e.toString(),i),t}storeUserEngagementMap(e){if(0===e.size)this.storageHandler.clearStorage(T.e.storageKeys.userEngagementDataKey);else{const t=JSON.stringify(e,y.ZP.StringifyMap);this.storageHandler.setStorageString(T.e.storageKeys.userEngagementDataKey,t)}}async updateRuleBasedTriggerData(e,t){try{await this.updateLocalStorage(e,t)}catch(t){const i=new a.Z(s.xu.OnErrorInvoked);this.logModule.LogErrorEvent(s.R.EdgeFlyoutStatus,`Error updating RuleBasedTriggerData for ${e} ${t}`,i)}}async updateLocalStorage(e,t){const i=await this.storageHandler.getStorageString(S.l.ruleBasedTriggerDataKey),n=this.createRuleBasedTriggerMapIfNotExists(i,e),o=this.createRuleBasedTriggerDataIfNotExists(n,e);this.increaseFlyoutReintroduceDaysIfNeeded(o,t),Object.entries(t).forEach((([e,t])=>{void 0!==t&&(o[e]=t)})),n.set(e.toString(),o);const r=JSON.stringify(JSON.stringify(n,y.ZP.StringifyMap));this.storageHandler.setStorageString(S.l.ruleBasedTriggerDataKey,r)}getPopupOriginationFromRenderedModule(e){let t;return t=e===P.ModuleNames.COUPON?c.sR.AUTO_SHOW_COUPONS_CHECKOUT:e===P.ModuleNames.PRICEHISTORY?c.sR.AUTO_SHOW_PRICE_HISTORY:e===P.ModuleNames.CASHBACK?c.sR.AUTO_SHOW_REBATES_CHECKOUT:e===P.ModuleNames.PRICECOMPARISON?c.sR.AUTO_SHOW_LOWER_PRICE_FOUND:void 0,t}increaseFlyoutReintroduceDaysIfNeeded(e,t){this.engagementType===A.w1.NEGATIVE&&e.flyoutReintroduceIsForced&&(t.flyoutReintroduceDays++,t.flyoutReintroduceIsForced=!1)}updateUserEngagementData(e,t,i,n){e===A.w1.POSITIVE?(t.positiveEngagementCount+=i,this.hasPositiveEngagements=!0):n===s.$S.FlyoutSnooze?this.addEngagementForSnoozeClick(t,i):n===s.$S.NotificationDismiss?this.addEngagementForDismissClick(t,i):t.negativeEngagementCount+=i,void 0!==n&&(t.lastClick=n)}addEngagementForDismissClick(e,t){e.negativeEngagementCount+=t}addEngagementForSnoozeClick(e,t){void 0===e.snoozeClickTimes&&(e.snoozeClickTimes=[]),e.snoozeClickTimes?.push(new Date),e.snoozeClickTimes.length>=T.e.snoozeClickCountEngagement&&(((new Date).getTime()-new Date(e.snoozeClickTimes[0]).getTime())/864e5<T.e.snoozeClickCountDaysEngagement?(e.negativeEngagementCount+=t,e.snoozeClickTimes=[]):e.snoozeClickTimes.shift())}}(this.storageHandler,this.logModule,l)}async setDomainName(e){this.domainName=e,await this.initialize()}async initialize(){this.autoOpenDataStr=await this.storageHandler.getStorageString(p.Q5),this.lastCleanedDataStr=await this.storageHandler.getStorageString(p.Gr),this.autoOpenPrefDataStr=await this.storageHandler.getStorageString(p.cv),this.lastShownDataStr=await this.storageHandler.getStorageString(p.n1),this.stageAndCategoryLastShownStr=await this.storageHandler.getStorageString(p.z0),this.totalPrice=await this.storageHandler.getStorageString("price"+this.domainName),this.autoOpenDomainPrefDataStr=await this.storageHandler.getStorageString(p.Sk),this.initializeData(),r.R.isExperimentActive(o.H.autoOpenControllerScript)&&this.initializeDomainPref()}shouldRestrictAutoOpen(e){return e!==c.sR.AUTO_SHOW_COUPONS_CHECKOUT}resetBlockedForSitePref(){try{let e=!1;if(this.domainData){const t=this.domainData.blockedList;if(t&&t.length>0)for(const i of t)i.blockedForSite&&(i.blockedForSite=!1,e=!0);e&&(this.domainData.blockedList=t);let i=!1;const n=this.domainData.paths;if(n&&n.forEach(((e,t)=>{if(e&&e.blockedListPath&&e.blockedListPath.length>0)for(const t of e.blockedListPath)t.blockedForSite&&(t.blockedForSite=!1,i=!0)})),i&&(this.domainData.paths=n),e||i){this.autoOpenData.set(this.domainName,this.domainData);const e=JSON.stringify(this.autoOpenData,y.ZP.StringifyMap);this.sendStorageMessage(p.Q5,e)}}}catch(e){this.sendErrorMessage(`:::AOC - error when resetting pref ${e}`)}}getBlockType(e){return this.shouldBlockForAll(e)?k.All:this.shouldBlockForDomain(e)?k.Domain:this.shouldBlockForStageAndCategory(e)?k.StageAndCategory:k.Path}storeLastShown(e){this.lastShownData.set(e,Date.now());const t=JSON.stringify(this.lastShownData,y.ZP.StringifyMap);this.sendStorageMessage(p.n1,t)}storeStageAndCategoryLastShown(e,t,i){if(!r.R.isExperimentActive(o.H.shoppingOnDiscover)||!r.R.isExperimentActive(o.H.temporalShoppingOnDiscover))return;const n=r.R.getMultipleVariants(o.H.shoppingOnDiscover),a=r.R.getVariantValue(n,"categoryCooldownInMinutes",1440);let s=this.stageAndCategoryLastShown.get(e);s||(s=new m.Z,this.stageAndCategoryLastShown.set(e,s)),s.categoriesBlocked||(s.categoriesBlocked=new Map);let l=s.categoriesBlocked.get(t);if(l||(s.categoriesBlocked.set(t,[]),l=s.categoriesBlocked.get(t)),!l)return;const c=new f.Z;for(c.categoryName=i,c.timeLastAutoOpen=Date.now(),l.push(c);l.length>0&&Date.now()-l[0].timeLastAutoOpen>1e3*a*60*1;)l.shift();const d=JSON.stringify(this.stageAndCategoryLastShown,y.ZP.StringifyMap);this.sendStorageMessage(p.z0,d)}async pauseAutoOpenForPopupOrigination(e,t){try{const i=performance.now(),n=await this.storageHandler.getStorageString("price"+this.flyoutData.common.domain);""!==n&&this.setTotalPrice(n),this.updateLocalStorage(e,t);const o=performance.now()-i,r=JSON.stringify({popupOriginationEnum:e,snoozeTime:t});this.sendControllerPerfInfo(o.toString(),r)}catch(t){const i=new a.Z(s.xu.OnErrorInvoked);this.logModule.LogErrorEvent(s.R.EdgeFlyoutStatus,`error pausing auto open for ${e} ${t}`,i)}}async addNegativeEngagementForDomain(e,t,i){try{const n=await this.storageHandler.getStorageString(p.fX);if((0,u.TF)(n))return void this.startEngagementMap(e,null,t,i);let o;try{if(o=JSON.parse(n,y.ZP.ParseMap),!o)return void this.startEngagementMap(e,null,t)}catch(e){const t=new a.Z(s.xu.OnErrorInvoked);this.logModule.LogErrorEvent(s.R.EdgeFlyoutStatus,`engagement map parsing error ${e}`,t)}const r=o.get(this.flyoutData.common.domain);if(!r)return void this.startEngagementMap(e,o,t);let l=r?.get(e.toString());if(l||(l=new C.Z,l.negativeEngagementCount=0),l.negativeEngagementCount++,l.negativeEngagementCount>=t){await this.pauseAutoOpenForPopupOrigination(e,i),this.sendEngagementInfo(e,t,"auto open paused - engagement");const n=new a.Z(s.xu.AutoShowPaused,void 0,void 0,this.flyoutData.common.domain,JSON.stringify({engagementMap:o}));this.logModule.LogInfoEvent(s.R.EdgeFlyoutStatus,`${e} snoozed for domain ${this.flyoutData.common.domain} due to close button`,n),r.delete(e.toString()),o.set(this.flyoutData.common.domain,r)}else r.set(e.toString(),l),o.set(this.flyoutData.common.domain,r);this.storeNewEngagementMap(o)}catch(e){const t=new a.Z(s.xu.OnErrorInvoked);this.logModule.LogErrorEvent(s.R.EdgeFlyoutStatus,`error adding negative engagement ${e}`,t),this.storageHandler.clearStorage(p.fX)}}async addTotalNegativeEngagement(e,t,i){try{const n=await this.storageHandler.getStorageString(p.CR);if((0,u.TF)(n))return void this.startTotalNegativeEngagementMap(e,null,t,i);let o;try{if(o=JSON.parse(n,y.ZP.ParseMap),!o)return void this.startTotalNegativeEngagementMap(e,null,t,i)}catch(e){const t=new a.Z(s.xu.OnErrorInvoked);this.logModule.LogErrorEvent(s.R.EdgeFlyoutStatus,`total negative engagement map parsing error ${e}`,t)}let r=o.get(e.toString())??0;if(r++,r>=t){(0,E.XB)()||this.pageHandlerModule.MuteFeatures([e],i/1e3),await this.updateLocalStoragePref(!1,e,this.flyoutData.common.disabledNotifications,i),this.sendEngagementInfo(e,t,"auto open paused - total negative engagement");const n=new a.Z(s.xu.AutoShowPaused,void 0,void 0,this.flyoutData.common.domain,JSON.stringify({engagementMap:o}));this.logModule.LogInfoEvent(s.R.EdgeFlyoutStatus,`${e} snoozed for all domains due to close button`,n),o.delete(e.toString())}else o.set(e.toString(),r);this.storeTotalNegativeEngagementMap(o)}catch(e){const t=new a.Z(s.xu.OnErrorInvoked);this.logModule.LogErrorEvent(s.R.EdgeFlyoutStatus,`error adding negative engagement ${e}`,t),this.storageHandler.clearStorage(p.CR)}}async setUserPreference(e,t,i){try{await this.updateLocalStoragePref(e,t,i)}catch(e){const i=new a.Z(s.xu.OnErrorInvoked);this.logModule.LogErrorEvent(s.R.EdgeFlyoutStatus,`error setting preference for ${t} ${e}`,i)}}async setUserPreferenceBatch(e,t,i,n){try{await this.updateLocalStoragePrefBatch(e,t,i,n)}catch(e){const t=new a.Z(s.xu.OnErrorInvoked);this.logModule.LogErrorEvent(s.R.EdgeFlyoutStatus,`error setting batch preference ${e}`,t)}}isPopupOriginationBlockedByPref(e){return this.isPopupOriginationBlockedByPrefForDomain(e)?{blockedByAoc:!1}:this.isPopupOriginationBlockedByPrefForAllDomains(e)}isPopupOriginationBlockedByPrefForDomain(e){if(this.domainData&&this.domainData.blockedList){const t=this.domainData.blockedList.findIndex((t=>t.popupOrigination===e));if(-1!==t&&this.domainData.blockedList[t].blockedForSite)return!0}return!1}isPopupOriginationBlockedByPrefForAllDomains(e){if(this.autoOpenPrefData&&this.autoOpenPrefData.length>0){const t=this.autoOpenPrefData.findIndex((t=>t.popupOrigination===e));if(-1!==t){const i=this.autoOpenPrefData[t];if(this.isPopupOriginReenabledForLostUser(e,this.flyoutData.common.disabledNotifications,i))return{blockedByAoc:!1,reenabledForLostUser:!0};if(!i.snoozeTime)return{blockedByAoc:!0};if(Date.now()-i.timeLastAutoOpen<i.snoozeTime)return{blockedByAoc:!0}}}return{blockedByAoc:!1}}pausePopupOriginationForDomain(e){this.domainData||this.addDomainToLocalStorage(e,!0),this.domainData&&this.updatePopupOriginationList(this.domainData.blockedList,e,!0)}shouldBlockForAll(e){switch(e){case c.sR.AUTO_SHOW_CAMPAIGN_AWARENESS_NOTIFICATION:case c.sR.AUTO_SHOW_TRENDING_COUPONS:case c.sR.AUTO_SHOW_RECOMMENDATIONS:case c.sR.AUTO_SHOW_IBC_UPSELL:return!0}return!1}initializeDomainPref(){const e=this.autoOpenDomainPrefData?.get(this.domainName);if(this.autoOpenDomainPrefData&&e)for(const t of e)this.domainData||this.addDomainToLocalStorage(t,!0),this.domainData&&this.updatePopupOriginationList(this.domainData.blockedList,t,!0)}async updateLocalStoragePref(e,t,i,n){if(e){if(this.autoOpenPrefData=this.autoOpenPrefData.filter((e=>e.popupOrigination!==t)),this.domainData&&this.domainData.blockedList){const e=this.domainData.blockedList.filter((e=>e.popupOrigination!==t));this.writeToList(e,t,!1)}let e=this.autoOpenDomainPrefData.get(this.domainName);if(e){e=e.filter((e=>e!==t)),this.autoOpenDomainPrefData.set(this.domainName,e);const i=JSON.stringify(this.autoOpenDomainPrefData,y.ZP.StringifyMap);await this.sendStorageMessage(p.Sk,i)}}else{const e=new p.ZP;e.popupOrigination=t,e.timeLastAutoOpen=Date.now(),n&&(e.snoozeTime=n),i?.some((e=>e.popupOrigination===t))&&(e.lostUserReblockedTime=Date.now()),this.autoOpenPrefData.push(e)}const o=JSON.stringify(this.autoOpenPrefData);await this.sendStorageMessage(p.cv,o)}async updateLocalStoragePrefBatch(e,t,i,n){if(e)this.autoOpenPrefData=this.autoOpenPrefData.filter((e=>!t.includes(e.popupOrigination)));else{const e=[];for(const o of t){const t=this.autoOpenPrefData.findIndex((e=>e.popupOrigination===o));if(-1===t){const r=new p.ZP;r.popupOrigination=o,r.timeLastAutoOpen=Date.now(),n&&(r.snoozeTime=n),i?.some((e=>e.popupOrigination===o))&&(this.autoOpenPrefData[t].lostUserReblockedTime=Date.now()),e.push(r)}else void 0===n&&i?.some((e=>e.popupOrigination===o))?this.autoOpenPrefData[t].lostUserReblockedTime=Date.now():this.autoOpenPrefData[t].snoozeTime&&(this.autoOpenPrefData[t].timeLastAutoOpen=Date.now(),n&&(this.autoOpenPrefData[t].snoozeTime=n))}this.autoOpenPrefData=[...this.autoOpenPrefData,...e]}const o=JSON.stringify(this.autoOpenPrefData);await this.sendStorageMessage(p.cv,o)}updateLocalStorage(e,t){if(this.autoOpenDataStr||this.addDomainToLocalStorage(e,!1),this.domainData)if(this.shouldBlockForDomain(e))this.updatePopupOriginationList(this.domainData.blockedList,e,!1,t);else{this.domainData.paths.get(this.currentPath)||this.domainData.paths.set(this.currentPath,new g.Z);const i=this.domainData.paths.get(this.currentPath);i?this.updatePopupOriginationList(i.blockedListPath,e,!1,t):this.sendErrorMessage(":::AOC - pathData undefined")}else this.addDomainToLocalStorage(e,!1)}addDomainToLocalStorage(e,t){if(this.domainData){let i=[];if(this.shouldBlockForDomain(e)&&this.domainData&&this.domainData.blockedList)i=this.domainData.blockedList;else{let e=this.domainData?.paths.get(this.currentPath);e||(this.domainData||(this.domainData=new h.ZP),e=new g.Z,this.domainData.paths.set(this.currentPath,e)),i=e.blockedListPath}this.updatePopupOriginationList(i,e,t)}else{const i=new h.ZP,n=new Map;if(this.shouldBlockForDomain(e))this.updatePopupOriginationList(i.blockedList,e,t);else{const i=new g.Z;n.set(this.currentPath,i),this.updatePopupOriginationList(i.blockedListPath,e,t)}}}updatePopupOriginationList(e,t,i,n){let o=-1;if(e&&(o=e?.findIndex((e=>e.popupOrigination===t))),-1!==o&&e){const r=e[o];r.timeLastAutoOpen=Date.now(),n&&(r.snoozeTime=n),r.blockedForSite=i,e[o]=r,this.writeToList(e,t,i)}else{const o=new p.ZP;o.popupOrigination=t,o.timeLastAutoOpen=Date.now(),o.blockedForSite=i,n&&(o.snoozeTime=n),e||(e=[]),e.push(o),this.writeToList(e,t,i)}}sendControllerPerfInfo(e,t){const i=new a.Z(s.xu.PerfPauseAutoShow,void 0,void 0,this.flyoutData.common.domain,t);this.logModule.LogInfoEvent(s.R.EdgeFlyoutStatus,e,i,d.g.EdgeImpressionId)}async startTotalNegativeEngagementMap(e,t,i,n){if(!t){if(1>=i){(0,E.XB)()||this.pageHandlerModule.MuteFeatures([e],n/1e3),await this.updateLocalStoragePref(!1,e,this.flyoutData.common.disabledNotifications,n);const t=new a.Z(s.xu.AutoShowPaused,void 0,void 0,this.flyoutData.common.domain);return void this.logModule.LogInfoEvent(s.R.EdgeFlyoutStatus,`${e} snoozed for all domains due to close button`,t)}t=new Map}const o=e.toString();t.set(o,t.get(o)??1),this.storeTotalNegativeEngagementMap(t)}async startEngagementMap(e,t,i,n){if(!t){if(1>=i){await this.pauseAutoOpenForPopupOrigination(e,n);const t=new a.Z(s.xu.AutoShowPaused,void 0,void 0,this.flyoutData.common.domain);return void this.logModule.LogInfoEvent(s.R.EdgeFlyoutStatus,`${e} snoozed for domain ${this.flyoutData.common.domain} due to close button`,t)}t=new Map}const o=new Map,r=new C.Z;r.negativeEngagementCount=1,o.set(e.toString(),r),t.set(this.flyoutData.common.domain,o),this.storeNewEngagementMap(t)}storeTotalNegativeEngagementMap(e){if(0===e.size)this.storageHandler.clearStorage(p.CR);else{const t=JSON.stringify(e,y.ZP.StringifyMap);this.storageHandler.setStorageString(p.CR,t)}}storeNewEngagementMap(e){if(0===e.size)this.storageHandler.clearStorage(p.fX);else{const t=JSON.stringify(e,y.ZP.StringifyMap);this.storageHandler.setStorageString(p.fX,t)}}sendEngagementInfo(e,t,i){const n=new a.Z(s.xu.BlockedAutoOpenEngagement,void 0,void 0,this.flyoutData.common.domain,JSON.stringify({negativeEngagementCount:t,popupOrigination:e}));this.logModule.LogInfoEvent(s.R.EdgeFlyoutStatus,i,n,d.g.EdgeImpressionId)}sendFlyoutErrorMessage(e){const t=new a.Z(s.xu.OnErrorInvoked);this.logModule.LogErrorEvent(s.R.EdgeFlyoutStatus,e,t)}sendFlyoutStorageMessage(e,t){this.storageHandler.setStorageString(e,t)}}var D=I,_=i(36493),N=i(33491);function R(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function M(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?R(Object(i),!0).forEach((function(t){(0,n.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):R(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var L=function(e){return e.PRICE_MATCH="price match",e.EE_PRICE_UNAVAILABLE="entity extraction price unavailable",e.EE_PRICE_HIGHER="entity extraction price is higher than displayed price",e.EE_PRICE_LOWER="entity extraction price is lower than displayed price",e.UNABLE_TO_VALIDATE="Unable to validate entry",e.DISPLAY_PRICE_ERROR="unable to extract displayed price",e}(L||{}),B=i(64106),F=i(79710),U=i(57549),H=i(91221),$=i(93209),Z=i(97861),V=i(1583),G=i(55590),j=i(18549),z=i(91495),W=i(2388),K=i(75434),q=i(64550);function Y(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function X(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Y(Object(i),!0).forEach((function(t){(0,n.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Y(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var J=i(54380),Q=i(46357),ee=i(87605),te=i(3960);function ie(e){return`${e?.name??""} ${e?.message??""} ${e?.stack??""}`}function ne(e){switch(e){case l.p.ATTAINABLE_COUPONS:return c.sR.AUTO_SHOW_ATTAINABLE_COUPONS;case l.p.AUTOS_MARKETPLACE:return c.sR.AUTO_SHOW_AUTOS_MARKETPLACE;case l.p.COUPONS_CLIPPING:return c.sR.AUTO_SHOW_COUPONS_CLIPPING;case l.p.EXCLUSIVE_COUPONS:return c.sR.AUTO_SHOW_SOCIAL_COUPONS;case l.p.GROCERY_ITEMIZED_CASHBACK:return c.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK;case l.p.SPB_CASHBACK_LANDING:return c.sR.AUTO_SHOW_SPB_CASHBACK_LANDING;case l.p.GROCERY_ITEMIZED_CASHBACK_LANDING:return c.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK_LANDING;case l.p.OTHER_SELLERS_CONFIRMATION:return c.sR.AUTO_SHOW_ITEM_ADDED_TO_CART_FROM_OTHER_SELLER;case l.p.OTHER_SELLERS:case l.p.OTHER_SELLERS_TRIGGER:return c.sR.AUTO_SHOW_OTHER_SELLERS;case l.p.PRINT_GROCERY:return c.sR.AUTO_SHOW_RECOMMENDATIONS;case l.p.PRODUCT_TRACKING_OUT_OF_STOCK:return c.sR.AUTO_PRODUCT_TRACKING_OUT_OF_STOCK;case l.p.REWARDS_GIFT_CARD:return c.sR.AUTO_SHOW_GIFT_CARD;case l.p.AA_CONSENT:return c.sR.AA_CONSENT;default:return null}}function oe(e){switch(e){case c.sR.AUTO_SHOW_COUPONS_CHECKOUT:case c.sR.AA_CONSENT:case c.sR.AUTO_SHOW_BING_SEARCH:return c.Ke.COUPONS_CHECKOUT;case c.sR.AUTO_SHOW_URL_PARAM_REBATES:return c.Ke.REBATES_BING;case c.sR.AUTO_SHOW_AUTOS_MARKETPLACE:return c.Ke.AUTOS_MARKETPLACE;case c.sR.AUTO_SHOW_COUPONS_CLIPPING:return c.Ke.COUPONS_CLIPPING;case c.sR.AUTO_SHOW_LOWER_PRICE_FOUND:case c.sR.AUTO_SHOW_URL_PARAM_PRICE_COMPARISON:return c.Ke.PRICE_COMPARE;case c.sR.AUTO_SHOW_PRICE_HISTORY:case c.sR.AUTO_SHOW_URL_PARAM_PRICE_HISTORY:return c.Ke.PRICE_HISTORY;case c.sR.AUTO_SHOW_REBATES_CONFIRMATION:return c.Ke.REBATES_CONFIRMATION;case c.sR.AUTO_SHOW_REBATES:return c.Ke.REBATES_BING;case c.sR.AUTO_SHOW_REBATES_ORGANIC:case c.sR.AUTO_SHOW_REBATES_ORGANIC_NEW:return c.Ke.REBATES_ORGANIC;case c.sR.AUTO_SHOW_REBATES_CHECKOUT:return c.Ke.REBATES_CHECKOUT;case c.sR.AUTO_SHOW_PERSONALIZED_CASHBACK||c.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_ADDRESSBAR:return c.Ke.PERSONALIZED_CASHBACK;case c.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_CONFIRMATION:return c.Ke.PERSONALIZED_CASHBACK_CONFIRMATION;case c.sR.AUTO_SHOW_EXPRESS_CHECKOUT:return c.Ke.EXPRESS_CHECKOUT;case c.sR.AUTO_SHOW_SERVER_DRIVEN_REWARDS:return c.Ke.REWARDS;case c.sR.AUTO_SHOW_OTHER_SELLERS:case c.sR.AUTO_SHOW_ITEM_ADDED_TO_CART_FROM_OTHER_SELLER:return c.Ke.OTHER_SELLER;case c.sR.AUTO_SHOW_PROFESSIONAL_REVIEWS:return c.Ke.REVIEWS;case c.sR.AUTO_SHOW_SOCIAL_COUPONS:return c.Ke.EXCLUSIVE_COUPONS;case c.sR.AUTO_SHOW_GUEST_DOMAIN_COUPONS:return c.Ke.GUEST_COUPONS;case c.sR.AUTO_SHOW_SUSTAINABILITY_LANDING:return c.Ke.SUSTAINABILITY_LANDING;case c.sR.AUTO_SHOW_SUSTAINABILITY_PURCHASE:return c.Ke.SUSTAINABILITY_PURCHASE;case c.sR.AUTO_SHOW_PACKAGE_TRACKING:return c.Ke.PACKAGE_TRACKING;case c.sR.AUTO_SHOW_ATTAINABLE_COUPONS:return c.Ke.ATTAINABLE_COUPONS;case c.sR.AUTO_SHOW_GIFT_CARD:return c.Ke.REWARDS_GIFT_CARD;case c.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK:return c.Ke.GROCERY_ITEMIZED_CASHBACK;case c.sR.AUTO_PRODUCT_TRACKING_OUT_OF_STOCK:return c.Ke.OUT_OF_STOCK;case c.sR.AUTO_SHOW_VIRTUAL_CARD:return c.Ke.VIRTUAL_CARD;case c.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK_LANDING:return c.Ke.GROCERY_ITEMIZED_CASHBACK_LANDING;case c.sR.AUTO_SHOW_SPB_CASHBACK_LANDING:return c.Ke.SPB_CASHBACK_LANDING;case c.sR.OPEN_FLYOUT_FROM_EDGE_DRIVER_EC:return c.Ke.EXPRESS_CHECKOUT;case c.sR.AUTO_SHOW_RECOMMENDATIONS:return c.Ke.RECOMMENDATIONS;default:return c.Ke.NONE}}function re(){return[c.sR.AUTO_SHOW_BING_SEARCH,c.sR.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION,c.sR.AUTO_SHOW_BING_CAMPAIGN,c.sR.AUTO_SHOW_AOC]}function ae(){return[c.sR.AUTO_SHOW_REBATES_CONFIRMATION,c.sR.AUTO_SHOW_REBATES_DEACTIVATED,c.sR.AUTO_SHOW_REBATES,c.sR.AUTO_SHOW_REBATES_ACTIVATION_FAILED,c.sR.AUTO_SHOW_REBATES_SWITCHED_TO_MSA,c.sR.AUTO_SHOW_REWARDS_ACTIVATION_FAILED,c.sR.AUTO_SHOW_REWARDS_SWITCHED_TO_MSA,c.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_CONFIRMATION,c.sR.AUTO_SHOW_PERSONALIZED_CASHBACK,c.sR.AUTO_SHOW_SUSTAINABILITY_LANDING,c.sR.AUTO_SHOW_SUSTAINABILITY_PURCHASE,c.sR.AUTO_SHOW_SAN_CONSENT_CONFIRMATION]}function se(e,t,i,n){if(n===c.sR.AUTO_SHOW_ARTICLES_CASHBACK_NOTIFICATION)return e.strings.articlesCashbackFeatureName;if(n===c.sR.AUTO_SHOW_GIFT_CARD)return e.strings.giftFeatureName;if(pe().includes(n))return e.strings.groceriesFeatureName;if(de().includes(n))return e.strings.pcFeatureName;if(n===c.sR.AUTO_SHOW_PACKAGE_TRACKING)return e.strings.packageTrackingFeatureName;if(ce().includes(n))return e.strings.cbFeatureName;if(n===c.sR.AUTO_SHOW_PRICE_HISTORY||n===c.sR.AUTO_SHOW_URL_PARAM_PRICE_HISTORY)return e.strings.phFeatureName;if(n===c.sR.AUTO_SHOW_CASHBACK_PDP_PLUS_COUPONS)return e.strings.cashbackPlusCouponsFeatureName;if(n===c.sR.AUTO_SHOW_PRICE_DROP_PLUS_CASHBACK)return e.strings.cashbackPlusPriceDropFeatureName;if(n===c.sR.AUTO_SHOW_LOWER_PRICE_PLUS_CASHBACK_PLUS_COUPONS)return e.strings.pcPlusCashbackPlusCouponsFeatureName;if(he().includes(n))return e.strings.dealsFeatureName;if(n===c.sR.AUTO_SHOW_PROFESSIONAL_REVIEWS)return e.strings.rrFeatureName;if(n===c.sR.AUTO_SHOW_SUSTAINABILITY_LANDING||n===c.sR.AUTO_SHOW_SUSTAINABILITY_PURCHASE)return e.strings.sustainabilityFeatureName;if(n===c.sR.AUTO_SHOW_VIRTUAL_CARD)return e.strings.virtualCardFeatureName;if(le().includes(n))return e.strings.couponFeatureName;if(n===c.sR.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION){const n=t.getPwiloPopupOrigination(i);if(n){if(n===c.sR.AUTO_SHOW_ABANDONED_CART)return e.strings.abandonedCartFeatureName;if(n===c.sR.AUTO_PRODUCT_TRACKING_OUT_OF_STOCK||n===c.sR.AUTO_PRODUCT_TRACKING_EXP_PRICE_DROP||n===c.sR.AUTO_PRODUCT_TRACKING_IMP_PRICE_DROP||n===c.sR.AUTO_SHOW_PRODUCT_TRACKING_BACK_IN_STOCK)return e.strings.productTrackingFeatureName}return e.strings.productTrackingFeatureName}return n===c.sR.AUTO_SHOW_EXPRESS_CHECKOUT||n===c.sR.OPEN_FLYOUT_FROM_EDGE_DRIVER_EC?e.strings.checkoutFeatureName:n===c.sR.AUTO_SHOW_AUTOS_MARKETPLACE?e.strings.autosFeatureName:n===c.sR.AUTO_PRODUCT_TRACKING_EXP_PRICE_DROP||n===c.sR.AUTO_PRODUCT_TRACKING_IMP_PRICE_DROP||n===c.sR.AUTO_SHOW_PRODUCT_TRACKING_BACK_IN_STOCK||n===c.sR.AUTO_PRODUCT_TRACKING_OUT_OF_STOCK?e.strings.productTrackingFeatureName:n===c.sR.AUTO_SHOW_SAN_CONSENT_CONFIRMATION?e.strings.sanConsentFeatureName:n===c.sR.AUTO_SHOW_ABANDONED_CART?e.strings.abandonedCartFeatureName:n===c.sR.AUTO_SHOW_PRODUCT_BEST_COUPON_CONSENT?e.strings.productBestCouponFeatureName:n===c.sR.CJK_OPEN_HUB_ICON?e.strings.cjkOpenHubIconName:n===c.sR.HOVER_BUTTON_SHOW_FLYOUT?e.strings.cjkHoverButtonShowFlyoutName:n===c.sR.AUTO_SHOW_CJK_PRICE_DROP?e.strings.cjkPriceDrop:n===c.sR.AUTO_SHOW_CJK_COUPON_FOUND?e.strings.cjkCouponFound:n===c.sR.AUTO_SHOW_IBC_UPSELL?e.strings.inboxCouponsFeatureName:n===c.sR.AUTO_SHOW_POST_PURCHASE_TRACKING||n===c.sR.AUTO_SHOW_AMAZON_SEARCH_PC?e.strings.postPurchaseTrackingFeatureName:n===c.sR.AUTO_SHOW_SERVER_DRIVEN_REWARDS?e.strings.rewardsFeatureName:n===c.sR.AUTO_SHOW_DISCOVER_NOTIFICATION?e.strings.discoverFeatureName:n===c.sR.AUTO_SHOW_TRAVEL_NOTIFICATION_CHEAPER_FLIGHTS?e.strings.travelCheaperFlightsFeatureName:n===c.sR.AUTO_SHOW_TRAVEL_NOTIFICATION_CHEAPER_HOTEL_ROOM?e.strings.travelCheaperHotelsFeatureName:n===c.sR.AUTO_SHOW_COUPONS_BACKGROUND_AUTO_APPLY?e.strings.backgroundAutoApplyFeatureName:n===c.sR.AUTO_SHOW_INBOX_PRICE_MATCH_NOTIFICATION?e.strings.inboxSavingsFeatureName:n===c.sR.AUTO_SHOW_POST_PURCHASE_REWARDS_NOTIFICATION?e.strings.postPurchaseRewardsFeatureName:""}function le(){return[c.sR.AUTO_SHOW_COUPONS_CHECKOUT,c.sR.AUTO_SHOW_COUPONS_CLIPPING,c.sR.AUTO_SHOW_GUEST_DOMAIN_COUPONS,c.sR.AUTO_SHOW_SOCIAL_COUPONS,c.sR.AUTO_SHOW_BING_SEARCH,c.sR.AUTO_SHOW_ATTAINABLE_COUPONS,c.sR.AA_CONSENT,c.sR.AUTO_SHOW_TRENDING_COUPONS,c.sR.AUTO_SHOW_PRODUCT_BEST_COUPON_CONSENT]}function ce(){return[c.sR.AUTO_SHOW_REBATES,c.sR.AUTO_SHOW_REBATES_ORGANIC,c.sR.AUTO_SHOW_REBATES_ORGANIC_NEW,c.sR.AUTO_SHOW_REBATES_CONFIRMATION,c.sR.AUTO_SHOW_REBATES_CHECKOUT,c.sR.AUTO_SHOW_PERSONALIZED_CASHBACK,c.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_CONFIRMATION,c.sR.AUTO_SHOW_REBATES_DEACTIVATED,c.sR.AUTO_SHOW_REBATES_ACTIVATION_FAILED,c.sR.AUTO_SHOW_REBATES_SWITCHED_TO_MSA,c.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_ADDRESSBAR,c.sR.AUTO_SHOW_REBATES_PDP,c.sR.AUTO_SHOW_URL_PARAM_REBATES]}function de(){return[c.sR.AUTO_SHOW_LOWER_PRICE_FOUND,c.sR.AUTO_SHOW_OTHER_SELLERS,c.sR.AUTO_SHOW_URL_PARAM_PRICE_COMPARISON,c.sR.AUTO_SHOW_ITEM_ADDED_TO_CART_FROM_OTHER_SELLER]}function ue(){return[c.sR.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION,c.sR.AUTO_PRODUCT_TRACKING_OUT_OF_STOCK]}function he(){return[c.sR.AUTO_SHOW_MOMENT_IN_TIME,c.sR.AUTO_SHOW_CAMPAIGN_PDP_NOTIFICATION,c.sR.AUTO_SHOW_CAMPAIGN_AWARENESS_NOTIFICATION]}function pe(){return[c.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK,c.sR.AUTO_SHOW_RECOMMENDATIONS,c.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK_LANDING,c.sR.AUTO_SHOW_SPB_CASHBACK_LANDING,c.sR.AUTO_SHOW_SPB_CHECK_OUT_PAGE_NOTIFICATION]}function ge(e){for(const t of[le(),ce(),de(),ue(),he(),pe()])if(t.includes(e))return t;return[e]}function fe(e,t,i,n,l=!1){if(e){if(r.R.isExperimentActive(o.H.autoOpenControllerScript)){const{blockedByAoc:o,reenabledForLostUser:r}=l?i.isPopupOriginationBlockedByPref(e):i.isPopupOriginationBlockedByPrefForAllDomains(e),c=oe(e),d=c&&(t.common.autoshowFeaturePref&c)===c;if(o!==d&&e<63&&!r){const r={blockedByAoc:o,blockedByClientPref:d,popupOrigination:e,feature:c},l=new a.Z(s.xu.UserPrefMismatch,void 0,void 0,t.common.domain,JSON.stringify(r));if(n.LogInfoEvent(s.R.EdgeFlyoutStatus,"",l),d)return i.setUserPreference(!1,e,t.common.disabledNotifications),!d}return!o}{const i=oe(e);if(void 0!==t.common.autoshowFeaturePref)return(t.common.autoshowFeaturePref&i)!==i}}return t.common.isNotificationEnabled}function me(e,t,i){return e?!i.isPopupOriginationBlockedByPref(e):t.common.isNotificationEnabled}function ve(e){return e.common.isSafariClient}var ye=class{constructor(e,t,i,l){(0,n.Z)(this,"pageHandlerModule",void 0),(0,n.Z)(this,"logModule",void 0),(0,n.Z)(this,"viewModulesUtilities",void 0),(0,n.Z)(this,"commonAssets",void 0),(0,n.Z)(this,"storageHandler",void 0),(0,n.Z)(this,"fixedHeaderUtilities",void 0),(0,n.Z)(this,"footerUtilities",void 0),(0,n.Z)(this,"tooltipUtilities",void 0),(0,n.Z)(this,"telemetryHandler",void 0),(0,n.Z)(this,"autoOpenControllerUtilities",void 0),(0,n.Z)(this,"dataValidationUtilities",void 0),(0,n.Z)(this,"discoverTelemetryHandler",void 0),this.pageHandlerModule=e,this.logModule=t,this.storageHandler=new H.Z(e,i.dataLoader,t),this.fixedHeaderUtilities=new class{setFlyoutHeader(e,t,i){if(!e.common.isPane&&!e.common.shopping.fixedTitle){const n=e.strings;e.common.shopping.fixedTitle=n.commonFixedTitle,this.addHeaderIcon(i,e.common.shopping,t,!1),r.R.isPCBannerUXExperimentActive()?e.common.shopping.fixedTitle=n.pcPriceSectionTitle:e.common.shopping.fixedTitle=n.commonFixedTitleNew}}addHeaderIcon(e,t,i,n){const o=(0,F.Ux)("DIV");o.id="divFixedHeaderIcon",o.style.zIndex="10",o.style.display="flex",o.style.alignContent="center",o.innerHTML=e.getHeaderIcon(),o.slot="header-icon",n?(o.style.marginLeft="16px",o.style.display="flex",o.style.alignItems="center",t.prepend(o)):t.appendChild(o)}},this.viewModulesUtilities=new te.Z(i,t,l),this.autoOpenControllerUtilities=new D,this.autoOpenControllerUtilities.init(i,this.logModule,this.storageHandler,this.pageHandlerModule,d.g.EdgeImpressionId),this.footerUtilities=new U.Z(i,this.viewModulesUtilities,e,t,this.autoOpenControllerUtilities),this.telemetryHandler=new class{constructor(e,t,i,o){(0,n.Z)(this,"flyoutData",void 0),(0,n.Z)(this,"utilities",void 0),(0,n.Z)(this,"pageHandlerModule",void 0),(0,n.Z)(this,"logModule",void 0),this.flyoutData=e,this.utilities=t,this.pageHandlerModule=i,this.logModule=o}sendCTRLog(e,t,i,n,o){const r=e.paneTab;if("MSFT-EDGE-SHOPPING-SECTION"===e.element.nodeName)if(!e.element.hasAttribute("accordion")||e.element.hasAttribute("expanded")||0===t)this.recordContentViewed(e.name,i,n,t,r,o);else{e.element.addEventListener("click",p);const l=this.pageHandlerModule,c=this.logModule,d=this.flyoutData,u=this.setContentViewed.bind(this),h=this.getModuleViewedTelemetryMetadata.bind(this);function p(){if(e.element&&!e.element.hasAttribute("expanded")){const g=u(e.name,i,!0,!1);if(g){l.RecordAsContentViewed(g);const d=new a.Z(s.xu.ModuleViewed,void 0,void 0,void 0);d.Metadata=h(e.name,t,n,r,o),c.LogInfoEvent(s.R.EdgeFlyoutStatus,`${g} expanded`,d,i)}if(e.element&&e.element.removeEventListener("click",p),e.name===P.ModuleNames.PRICECOMPARISON){const e=d.dataStoreModule.PriceComparisonData;if(e&&e.CompetingPrices?.length>0){const t=[];e.CompetingPrices.forEach((e=>{""!==e.ImpressionToken&&this.visibilityRequest&&t.push(e.ImpressionToken)})),t.length>0&&l.SendBingVisibilityRequest(t)}}}}}else this.recordContentViewed(e.name,i,n,t,r,o)}recordContentViewed(e,t,i,n,o,r){const l=0===n,c=this.setContentViewed(e);let u=`${e}`;const h=new a.Z(s.xu.ModuleViewed,void 0,void 0,this.flyoutData.common.domain);if(c)this.pageHandlerModule.RecordAsContentViewed(c),u=`${c}`,i&&(0,N.Ev)("NotificationContent",u);else if(e!==P.ModuleNames.FEEDBACK&&e!==P.ModuleNames.EMPTYCOUPON){const t=new a.Z(s.xu.ErrorRecordingContentViewed);this.logModule.LogErrorEvent(s.R.EdgeFlyoutStatus,`couldn't record as content viewed ${e}`,t)}i?u+=" notification":l&&(u+=" pole position"),this.utilities.isPinterest()&&(u+=" Pinterest");let p=t;h.Metadata=this.getModuleViewedTelemetryMetadata(e,n,i,o,r),e!==P.sM.GROCERY_CASHBACK_NOTIFICATION&&e!==P.ModuleNames.GROCERY_CASHBACK||(p=d.g.CouponImpressionId),this.logModule.LogInfoEvent(s.R.EdgeFlyoutStatus,u,h,p)}LogIcError(e,t,i,n={},o){(0,K.F0)(this.flyoutData,this.logModule,e,t,i,n,o)}LogButtonClickICSpecificTelemetry(e,t,i,n,o={}){const r=(0,K.r2)(this.flyoutData,n),a=new $.Z(e,W.r.ITEMIZED_CASHBACK);a.Metadata=JSON.stringify(X(X(X({},r),o),{},{message:i})),this.logModule.LogInfoEvent(s.R.ButtonClick,i,a,d.g.CouponImpressionId),t&&this.pageHandlerModule.RecordAsUserAction(t)}LogICSpecificTelemetry(e,t,i,n={}){const o=(0,K.r2)(this.flyoutData,i),r=new a.Z(e),l=(new Date).getTime(),c=this.getCurrentPageInfo(),u=c?.latencyData?X(X({},c?.latencyData),{},{shownTimeMs:l}):void 0;if(r.Metadata=JSON.stringify(X(X(X({},o),n),{},{message:t,timestamps:u})),this.logModule.LogInfoEvent(s.R.EdgeFlyoutStatus,t,r,d.g.CouponImpressionId),e===s.xu.ICSearchNotificationSPB)try{if(c?.latencyData?.receivedTimeMs&&c?.latencyData?.sentTimeMs){const e=(c.latencyData.receivedTimeMs-c.latencyData.sentTimeMs)/1e3,i=(l-c.latencyData.receivedTimeMs)/1e3,n=(l-c.latencyData.sentTimeMs)/1e3,r=new Z.Z(s.My.ICSPBNotificationLatency,o.domain,e,i,n,"","",o.pageType,o.popupOrigination?.toString(),o.isPane?"true":"false",c?.lastCommittedURL);this.logModule.LogInfoEvent(s.R.ItemizedCashbackStatus,t,r,d.g.CouponImpressionId)}}catch(e){}}setContentViewed(e){if(!e)return null;switch(e){case P.ModuleNames.CASHBACK_DASHBOARD:case P.sM.CASHBACK_DASHBOARD:return W.r.CASHBACK_DASHBOARD;case P.sM.ARTICLES_CASHBACK_NOTIFICATION:return W.r.ARTICLES_CASHBACK;case P.ModuleNames.COUPON:case P.sM.COUPON:return this.flyoutData.dataStoreModule.CouponData?.isCheckoutPageWithAutoApply?W.r.COUPONS_AUTO_APPLY:this.utilities.isPinterest()?W.r.PINTEREST_COUPONS_AVAILABLE:W.r.COUPONS_AVAILABLE;case P.ModuleNames.CASHBACK:case P.ModuleNames.CASHBACK_ACTIVATE:case P.ModuleNames.CASHBACK_DELAYED_ENROLLMENT:case P.sM.CASHBACKCONFIRMATION:case P.sM.CASHBACK:case P.sM.CASHBACKTURNEDOFF:case P.sM.CASHBACK_CHECKOUT_NOTIFICATION:case P.sM.CASHBACK_PDP_NOTIFICATION:return!this.flyoutData.dataStoreModule.CashBackData?.IsRebatesUser()&&this.flyoutData.common.isRebatesEnabled&&r.R.isExperimentActive(o.H.signinRebates)?W.r.ACTIVATE_CASHBACK_NEW:this.flyoutData.dataStoreModule.CashBackData?.IsRebatesUser()&&!this.flyoutData.dataStoreModule.CashBackData?.isCashBackActivated?this.utilities.isPinterest()?W.r.PINTEREST_REBATES_ACTIVATE_CASHBACK:W.r.REBATES_ACTIVATE_CASHBACK:this.flyoutData.dataStoreModule.CashBackData?.isConfirmationPage?W.r.REBATES_BING_CONFIRMATION:W.r.CASHBACK_RETAILER;case P.ModuleNames.COUPONCLIPPING:return W.r.COUPONS_CLIPPING;case P.ModuleNames.DEALS:case P.ModuleNames.DAILY_DEALS:return W.r.DEALS;case P.ModuleNames.MOMENT_IN_TIME:return W.r.FEED_MOMENT_IN_TIME;case P.ModuleNames.RECOMMENDATIONS:case P.sM.RECOMMENDATION:return W.r.RECOMMENDATIONS;case P.ModuleNames.SIMILARSELLERS:case P.sM.SIMILARSELLERS_CONFIRMATION_NOTIFICATION:case P.sM.SIMILARSELLERS_NOTIFICATION:return W.r.OTHER_SELLER;case P.ModuleNames.PRODUCTHISTORY:return W.r.PRODUCT_HISTORY;case P.ModuleNames.TRACKING_CONFIRMATION:return W.r.PACKAGE_TRACKING_OPT_IN;case P.ModuleNames.SIMILAR_OFFERS:return W.r.SIMILAR_OFFERS;case P.ModuleNames.ORDERSTATUSTRACKING:return W.r.PACKAGE_TRACKING_STATUS_VIEW;case P.ModuleNames.PRICECOMPARISON:const e=new j.Z(this.flyoutData.common.openedWith,this.flyoutData.dataStoreModule.PriceComparisonData?.CompetingPrices,this.flyoutData.dataStoreModule.PriceComparisonData?.Price,this.flyoutData.common.popupOrigination,this.flyoutData.common.pageLocale);return e?.shouldBeInPolePosition||this.flyoutData.common.openedWith===P.Te.Auto&&this.flyoutData.common.popupOrigination===c.sR.AUTO_SHOW_LOWER_PRICE_FOUND?W.r.PRICE_COMPARE_LOWER_PRICES:W.r.PRICE_COMPARE_BEST_PRICE;case P.ModuleNames.PRICEHISTORY:const t=this.flyoutData.dataStoreModule.PriceHistoryData?.getPriceHistoryType();return t===V.sh.NOINSIGHT?W.r.PRICE_HISTORY_NO_INSIGHT:t===V.sh.PRICEDROP?W.r.PRICE_HISTORY_DROP:t===V.sh.FAIRPRICE?W.r.PRICE_HISTORY_STABLE:W.r.PRICE_HISTORY_INCREASE;case P.sM.PRICE_DROP_PLUS_CASHBACK:return W.r.PRICE_DROP_PLUS_CASHBACK;case P.sM.PRICE_DROP_PLUS_COUPONS_COMPOSITE:return W.r.PRICE_DROP_PLUS_COUPONS;case P.sM.CASHBACK_PLUS_COUPONS_COMPOSITE:return W.r.CASHBACK_PLUS_COUPONS;case P.sM.LOWER_PRICE_PLUS_CASHBACK_PLUS_COUPONS_COMPOSITE:return W.r.LOWER_PRICE_PLUS_CASHBACK_PLUS_COUPONS;case P.ModuleNames.AUTOSREVIEWS:return W.r.VIDEO_REVIEWS;case P.ModuleNames.SIMILARSELLERS:return W.r.OTHER_SELLER;case P.ModuleNames.REWARD:return W.r.ACTIVATE_REWARDS_NEW;case P.ModuleNames.GROCERY_CASHBACK:case P.sM.GROCERY_CASHBACK_NOTIFICATION:case P.ModuleNames.GROCERY_CASHBACK_PENDING:case P.ModuleNames.ITEMIZED_CASHBACK:case P.sM.GROCERY_CASHBACK_PENDING_NOTIFICATION:case P.sM.ITEMIZED_CASHBACK_NOTIFICATION:return W.r.ITEMIZED_CASHBACK;case P.ModuleNames.TRENDING_OFFERS:return W.r.FEED_TRENDING_OFFERS;case P.ModuleNames.TRENDING_OFFERS_ON_CONTEXTUAL_TAB:return W.r.FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB;case P.ModuleNames.DAILY_DEALS:return W.r.FEED_DAILY_DEALS;case P.ModuleNames.INFINITE_CATEGORY_FEED:return W.r.FEED_INFINITE_CATEGORY;case P.ModuleNames.RELATED_PRODUCTS:return W.r.FEED_RELATED_PRODUCTS;case P.ModuleNames.AUTOSMARKETPLACE:case P.ModuleNames.AUTOSMYGARAGE:case P.sM.AUTOSMARKETPLACE_NOTIFICATION:case P.sM.AUTOSREVIEW_NOTIFICATION:return W.r.AUTOS_MARKETPLACE;case P.ModuleNames.ABANDONED_CART:return this.flyoutData.common.openedWith===P.Te.Auto?W.r.ABANDONED_CART_NOTIFICATION_COUPONS:W.r.ABANDONED_CART;case P.ModuleNames.PRODUCT_TRACKING_OUT_OF_STOCK:return W.r.PRODUCT_TRACKING_STOCK;case P.ModuleNames.PRODUCT_TRACKING_PRICE_DROP:return W.r.PRODUCT_TRACKING_PRICE;case P.ModuleNames.PRODUCT_TRACKING_ALERT:return W.r.PRODUCT_TRACKING_ALERT;case P.ModuleNames.PRODUCT_COLLECTIONS:return W.r.PRODUCT_TRACKING_COLLECTIONS;case P.ModuleNames.SHOPPING_TRIPS:return W.r.SHOPPING_TRIPS;case P.ModuleNames.TRENDING_COUPONS:return W.r.VIEW_BEST_COUPON_MODULE;case P.ModuleNames.INBOX_COUPONS:return W.r.INBOX_COUPONS;case P.ModuleNames.ACTIVE_RETAILER_INBOX_COUPONS:return W.r.ACTIVE_RETAILER_INBOX_COUPONS;case P.sM.PRODUCT_TRACKING_OFFERS_COUPON_NOTIFICATION:return W.r.PRODUCT_TRACKING_OFFERS_COUPON_NOTIFICATION;case P.sM.PRODUCT_TRACKING_BACK_IN_STOCK_NOTIFICATION:return W.r.PRODUCT_TRACKING_BACK_IN_STOCK_NOTIFICATION;case P.sM.PRODUCT_TRACKING_OUT_OF_STOCK_NOTIFICATION:return W.r.PRODUCT_TRACKING_OUT_OF_STOCK_NOTIFICATION;case P.sM.PRODUCT_TRACKING_PRICE_DROP_NOTIFICATION:return W.r.PRODUCT_TRACKING_NOTIFICATION;case P.sM.PRODUCT_BEST_COUPON:return W.r.PRODUCT_BEST_COUPON;case P.ModuleNames.PAYMENT_OPTIONS:return W.r.PAYMENT_OPTIONS;case P.ModuleNames.SOCIALCOUPONS:case P.sM.SOCIALCOUPONS:return this.flyoutData.common.lastCommittedURL?.includes("watch")?W.r.YOUTUBE_COUPONS_VIDEO:W.r.YOUTUBE_COUPONS_HOME;case P.ModuleNames.SOCIALCOUPONS_PERSISTENT:return this.flyoutData.common.isCheckoutPage?W.r.YOUTUBE_COUPONS_RETAILER_CHECKOUT:W.r.YOUTUBE_COUPONS_RETAILER;case P.ModuleNames.VIRTUAL_CARD:case P.sM.VIRTUAL_CARD:return W.r.PAYMENT_OPTIONS;case P.ModuleNames.SUSTAINABILITY:return W.r.SUSTAINABILITY_LANDING_FOOTER;case P.sM.SUSTAINABILITY:return this.flyoutData.common.popupOrigination===c.sR.AUTO_SHOW_SUSTAINABILITY_LANDING?W.r.SUSTAINABILITY_LANDING_FULL:this.flyoutData.common.popupOrigination===c.sR.AUTO_SHOW_SUSTAINABILITY_PURCHASE?W.r.SUSTAINABILITY_PURCHASE_CONFIRMATION:W.r.SUSTAINABILITY_LANDING_FOOTER;case P.sM.UNIFIED_CASHBACK:case P.ModuleNames.UNIFIED_CASHBACK:return W.r.CASHBACK_RETAILER;case P.ModuleNames.PRINTABLE_COUPON:return W.r.GROCERY_PRINT_COUPONS;case P.ModuleNames.ViewedProductPriceDrop:case P.sM.ViewedProductPriceDrop:return W.r.PWILO_NOTIFICATION_PRICE_DROP;case P.ModuleNames.PINTEREST:return W.r.PINTEREST_COUPONS_AVAILABLE;case P.sM.SAN_CONSENT_NOTIFICATION:return W.r.SAN_CONSENT_NOTIFICATION;case P.sM.ENROLL_TO_CASHBACK_CONFIRMATION_NOTIFICATION:return W.r.ENROLL_TO_CASHBACK_CONFIRMATION_NOTIFICATION;case P.ModuleNames.BUY_DIRECT:return W.r.FEED_BUY_DIRECT;case P.ModuleNames.SEARCH_RESULTS:return W.r.SEARCH_RESULTS;case P.ModuleNames.SEARCH_IN_PANE:return W.r.SEARCH_IN_PANE;case P.ModuleNames.DISCOVER_CHAT_CHIPS:return W.r.DISCOVER_CHAT_CHIPS;case P.ModuleNames.SMART_COMPARE:return W.r.SMART_COMPARE;case P.ModuleNames.PRODUCT_SUMMARY:return W.r.PRODUCT_SUMMARY;case P.ModuleNames.PRODUCTSUMMARYCARD:return W.r.PRODUCT_SUMMARY_CARD;case P.ModuleNames.BUYING_GUIDES:return W.r.BUYING_GUIDES;case P.ModuleNames.AX_SHOPPING_NAV:return W.r.AX_SHOPPING_NAV;case P.sM.DISCOVER_CHAT:return W.r.DISCOVER_CHAT;case P.ModuleNames.SAFARI_FIRST_RUN_EXPERIENCE:return W.r.SAFARI_FIRST_RUN_EXPERIENCE;case P.ModuleNames.CAMPAIGN_BANNER:return W.r.CAMPAIGN_BANNER;case P.ModuleNames.CAMPAIGN_PDP_CASHBACK:return W.r.CAMPAIGN_PDP_CASHBACK;case P.ModuleNames.FEED_CAMPAIGN:return W.r.FEED_CAMPAIGN;case P.ModuleNames.WISHLIST:return W.r.WISHLIST;case P.sM.CAMPAIGN_AWARENESS_NOTIFICATION:return W.r.CAMPAIGN_AWARENESS_NOTIFICATION;case P.sM.CAMPAIGN_PDP_CASHBACK_NOTIFICATION:return W.r.CAMPAIGN_PDP_CASHBACK_NOTIFICATION;case P.ModuleNames.SIDEPANE_CASHBACK:return W.r.SIDEPANE_CASHBACK;case P.ModuleNames.CJK_SIMILAR_PRODUCTS:return W.r.CJK_SIMILAR_PRODUCTS;case P.ModuleNames.MENU:return W.r.MENU;case P.sM.POST_PURCHASE_CONSENT_NOTIFICATION:return W.r.POST_PURCHASE_CONSENT_NOTIFICATION;case P.sM.PRICE_MATCH_PRICE_DROP_NOTIFICATION:return W.r.PRICE_MATCH_PRICE_DROP_NOTIFICATION;case P.sM.INBOX_PRICE_MATCH_PRICE_DROP_NOTIFICATION:return W.r.INBOX_PRICE_MATCH_PRICE_DROP_NOTIFICATION;case P.sM.SEARCHBOXDEMO_NOTIFICATION:return W.r.SEARCHBOXDEMO_NOTIFICATION;case P.sM.TRAVEL_CHEAPER_FLIGHT_NOTIFICATION:return W.r.TRAVEL_CHEAPER_FLIGHT_NOTIFICATION;case P.sM.TRAVEL_CHEAPER_HOTEL_NOTIFICATION:return W.r.TRAVEL_CHEAPER_HOTEL_NOTIFICATION;case P.ModuleNames.TRAVEL_CHEAPER_FLIGHT:return W.r.TRAVEL_CHEAPER_FLIGHT_NOTIFICATION;case P.sM.DISCOVER_NOTIFICATION:return W.r.DISCOVER_NOTIFICATION;case P.ModuleNames.USER_INSIGHTS:return W.r.USER_INSIGHTS;case P.ModuleNames.EXPERT_INSIGHTS:return W.r.EXPERT_INSIGHTS;case P.sM.AX_SHOPPING_NAV_NOTIFICATION:return W.r.AX_SHOPPING_NAV_NOTIFICATION;case P.ModuleNames.BACKGROUND_AUTO_APPLY:case P.sM.BGAA_NOTIFICATION:return W.r.BACKGROUND_AUTO_APPLY;case P.sM.POST_PURCHASE_REWARDS_NOTIFICATION:case P.ModuleNames.POST_PURCHASE_REWARDS:return W.r.POST_PURCHASE_REWARDS_NOTIFICATION;default:return null}}getModuleViewedTelemetryMetadata(e,t,i,n,o){if(!e)return;let r;switch(e){case P.sM.GROCERY_CASHBACK_NOTIFICATION:case P.ModuleNames.GROCERY_CASHBACK:const e=z.Q[G.Q.ICNotificationType];r={bingSignedInUser:this.flyoutData.dataStoreModule.UserInfo.isBingSignedInUser,isRebatesuser:this.flyoutData.dataStoreModule.UserInfo.isRebatesUser,msaSignedInUser:this.flyoutData.dataStoreModule.UserInfo.isMSASignedIn,openedWith:this.flyoutData.common.openedWith,popupOrigination:this.flyoutData.common.popupOrigination,url:this.flyoutData.common.lastCommittedURL??"",notificationType:e};break;case P.ModuleNames.PRICECOMPARISON:case P.sM.PRICECOMPARISON:r={url:this.flyoutData.common.lastCommittedURL??""};break;case P.sM.PRODUCT_TRACKING_BACK_IN_STOCK_NOTIFICATION:case P.sM.PRODUCT_TRACKING_OUT_OF_STOCK_NOTIFICATION:case P.sM.PRODUCT_TRACKING_PRICE_DROP_NOTIFICATION:case P.ModuleNames.PRODUCT_TRACKING_OUT_OF_STOCK:case P.ModuleNames.PRODUCT_TRACKING_PRICE_DROP:r={currentProduct:this.flyoutData.dataStoreModule.ProductTrackingData?._currentProduct,abandonedCartToggle:this.flyoutData.dataStoreModule.ProductTrackingData?._abandonedCartNotificationToggle};break;case P.ModuleNames.COUPON:case P.sM.COUPON:r={result:this.flyoutData.dataStoreModule.CouponData?.BgaaResultState,savings:this.flyoutData.dataStoreModule.CouponData?.BgaaSavings,viewedContent:this.flyoutData.dataStoreModule.CouponData?.BgaaViewedContent};break;case P.ModuleNames.SIMILARSELLERS:case P.sM.SIMILARSELLERS_CONFIRMATION_NOTIFICATION:case P.sM.SIMILARSELLERS_NOTIFICATION:const t=this.flyoutData.dataStoreModule.SimilarSellerData;t&&(r={similarSellerData:t,url:this.flyoutData.common.lastCommittedURL??""});break;case P.sM.TRAVEL_CHEAPER_FLIGHT_NOTIFICATION:{let e="";if(z.Q&&z.Q.rawStorageObj&&z.Q.rawStorageObj[G.Q.TravelCheaperFlightData]&&(e=z.Q.rawStorageObj[G.Q.TravelCheaperFlightData]),!e)break;const t=e?JSON.parse(e):void 0;if(t){const e=t.flightSearchResponse?.FlightQuery?.MaximumPrice?.Value,i=t.flightSearchResponse?.FlightQuery?.MaximumPrice?.CurrencyCode,n=t.flightSearchResponse?.FlightResults?.length??0,o=t.clientActivityId;let a;Array.isArray(t.flightSearchResponse?.FlightResults)&&t.flightSearchResponse.FlightResults.length>0&&(a=t.flightSearchResponse.FlightResults[0]),r=X({priceOnPage:e,clientActivityId:o,priceOnPageCurrency:i,numberOfOptions:n,cheapestFlight:a??{},cardType:t.cardType,flightQuery:t.flightSearchResponse?.FlightQuery??{},bookingOption:t.flightSearchResponse?.BookingOptions??{}},t.flightSearchResponse?.Telemetry)}break}case P.sM.TRAVEL_CHEAPER_HOTEL_NOTIFICATION:{let e="";if(z.Q&&z.Q.rawStorageObj&&z.Q.rawStorageObj[G.Q.TravelCheaperHotelData]&&(e=z.Q.rawStorageObj[G.Q.TravelCheaperHotelData]),!e)break;const t=e?JSON.parse(e):void 0;if(t){const e=t.hotelSearchResponse?.HotelQuery?.MaximumPrice?.Value,i=t.hotelSearchResponse?.HotelQuery?.MaximumPrice?.CurrencyCode,n=t.hotelSearchResponse?.HotelResults?.length??0,o=t.clientActivityId;let a;Array.isArray(t.hotelSearchResponse?.HotelResults)&&Array.isArray(t.hotelSearchResponse?.HotelResults[0].BookingOptions)&&t.hotelSearchResponse.HotelResults[0].BookingOptions.length>0&&(a=t.hotelSearchResponse.HotelResults[0].BookingOptions[0]),r={priceOnPage:e,clientActivityId:o,priceOnPageCurrency:i,numberOfOptions:n,cheapestHotel:a??{},cardType:t.cardType,hotelQuery:t.hotelSearchResponse?.HotelQuery??{},bookingOption:t.hotelSearchResponse?.HotelResults?.[0]?.BookingOptions??{}}}break}}if(r?r.ranking=t:r={ranking:t},r.isNotification=i,r.visible=performance.now(),n&&(r.paneTab=n),o&&(r.initialTab=o),!r.popupOrigination&&this.flyoutData.common?.popupOrigination&&(r.popupOrigination=this.flyoutData.common?.popupOrigination),P.ModuleNames[e]){const{common:e,dataStoreModule:t}=this.flyoutData;r.pageType=(0,q.U)(t.ApiData?.retailerData,e.lastCommittedURL,e.extractedEntity),r.journeyStage=this.flyoutData.common.journeyStage,r.sessionId=this.flyoutData.common.sessionId,r.retailerSessionId=this.flyoutData.common.retailerSessionId,r.pageVisitId=this.flyoutData.common.pageVisitId}return JSON.stringify(r)}getCurrentPageInfo(){const e=z.Q.ICCurrentPageInfo;if(e)try{return JSON.parse(e)}catch(e){return}}}(i,this.viewModulesUtilities,e,t),this.dataValidationUtilities=new class{constructor(e,t){(0,n.Z)(this,"flyoutData",void 0),(0,n.Z)(this,"logModule",void 0),this.flyoutData=e,this.logModule=t}writeValidationDataToStorage(e,t,i,n){try{const o=this.processIfBingAdsUrl(n);if(e&&""!==e){const n={displayedPrice:e,displayedTitle:t,sourceModule:i,timestamp:Date.now(),fromDomain:this.flyoutData.common.domain},r=(0,N.hS)("dataValidations");r[o]=n,this.deleteExpiredEntriesAndSave(r)}}catch(e){const t=`DataValidations: ERROR. Unable to save data to local storage. ${e}`,i=new a.Z(s.xu.OnErrorInvoked);this.logModule.LogErrorEvent(s.R.EdgeFlyoutStatus,t,i)}}checkExtractedDataForValidations(e){try{const t=e?.url;if(t){const i=(0,N.hS)("dataValidations");let n=t;if(!i.hasOwnProperty(t)){const e=new URL(t).searchParams.get("msclkid");if(!i.hasOwnProperty(e))return;n=e}this.validateDisplayedPrice(e,i[n]),delete i[n],this.deleteExpiredEntriesAndSave(i)}}catch(e){const t=`DataValidations: ERROR. Unable to validate prices. ${e}`,i=new a.Z(s.xu.OnErrorInvoked);this.logModule.LogErrorEvent(s.R.EdgeFlyoutStatus,t,i)}}validatePriceWithEntityExtractionResults(e,t,i){if(!e||!t)return;const n=e.entity?.price_value?e.entity.price_value:"",o=this.formatPricesAndCompare(n,t);if(o.comparisonResult!==L.PRICE_MATCH){const t=M(M({},o),{},{entityExtractionTitle:e.title,productUrl:e.url,sourceModule:i,extractedEntity:e});this.sendDataValidationTelemetry(t)}}processIfBingAdsUrl(e){const t=new URL(e);if("www.bing.com"===t.hostname){const e=t.searchParams.get("rlid");if(e&&""!==e)return e}return e}deleteExpiredEntriesAndSave(e){Object.keys(e).forEach((t=>{const i=new Date(e[t].timestamp);if(((new Date).getTime()-i.getTime())/1e3>=60){const i=e[t],n={displayedTitle:i.displayedTitle,displayedPriceString:i.displayedPrice,fromDomain:i.fromDomain,productUrl:t,sourceModule:i.sourceModule,comparisonResult:L.UNABLE_TO_VALIDATE};this.sendDataValidationTelemetry(n),delete e[t]}})),(0,N.Ev)("dataValidations",e)}validateDisplayedPrice(e,t){if(!e||!t)return;const i=t.displayedPrice,n=e.entity?.price_value?e.entity.price_value:"",o=M(M({},this.formatPricesAndCompare(n,i)),{},{displayedTitle:t.displayedTitle,fromDomain:t.fromDomain,entityExtractionTitle:e.title,productUrl:e.url,sourceModule:t.sourceModule,extractedEntity:e});this.sendDataValidationTelemetry(o)}formatPricesAndCompare(e,t){let i="";const n=(0,_.K)(t),o=(0,_.K)(e);return i=Number.isNaN(o)||""===e?L.EE_PRICE_UNAVAILABLE:Number.isNaN(n)?L.DISPLAY_PRICE_ERROR:n===o?L.PRICE_MATCH:o>n?L.EE_PRICE_HIGHER:L.EE_PRICE_LOWER,{entityExtractionPriceString:e,displayedPriceString:t,displayedPrice:n,entityExtractionPrice:o,comparisonResult:i}}sendDataValidationTelemetry(e){const t=new a.Z(s.xu.DataValidation,void 0,void 0,void 0,JSON.stringify(e));this.logModule.LogInfoEvent(s.R.EdgeFlyoutStatus,e.comparisonResult,t)}}(i,t),this.commonAssets=l,this.tooltipUtilities=new class{constructor(e,t,i,o){(0,n.Z)(this,"flyoutData",void 0),(0,n.Z)(this,"footerUtilities",void 0),(0,n.Z)(this,"commonAssets",void 0),(0,n.Z)(this,"utilities",void 0),this.flyoutData=e,this.footerUtilities=o,this.commonAssets=i,this.utilities=t}createInfoIconTooltip(e,t,i,n,o,r){const a=(0,F.Ux)("div");a.slot="hover-anchor",a.className="btnTooltip",a.tabIndex=0,a.innerHTML=this.commonAssets.getInfoIcon(),a.setAttribute("aria-label",this.flyoutData.strings.infoIconLabel);const s=(0,F.Ux)("msft-shopping-tooltip");return s.content=e,s.header=t??"",s.isCjk=r??!1,s.ariaDescribedby="content",s.setAttribute("name",`${s.header} ${s.content}`),s.setAttribute("aria-label",`${s.header} ${s.content}`),s.append(a),i&&(s.addEventListener("click",(()=>i())),s.addEventListener("keydown",(e=>{"Enter"===e.key&&i()}))),s.addEventListener("hover",(()=>{this.setupTooltip(s),n&&n()})),s.addEventListener("focus",(()=>{ve(this.flyoutData)&&(s.isVisible=!0),this.setupTooltip(s),o&&o()})),s}createPriceCompareCashbackTooltip(e,t){const i=(0,F.Ux)("msft-shopping-tooltip");i.termsAndConditionsTip=!0,i.header="";const n=this.flyoutData.strings.commonLearnMore+"|"+this.flyoutData.strings.termsAndConditions;return i.contentLength=n.length,i.setAttribute("name",`${i.header} ${n}`),i.setAttribute("aria-label",`${i.header} ${n}`),i.learnMoreText=this.flyoutData.strings.commonLearnMore,i.termsAndConditionsText=this.flyoutData.strings.termsAndConditions,i.learnMoreLinkHandler=()=>{t?.NavigateToBingRebates()},i.termsAndConditionsLinkHandler=()=>{t?.NavigateToTermsStatementFlyout()},e&&(e.slot="hover-anchor",i.append(e)),i.addEventListener("hover",(()=>{i.isVisible=!0,this.setupTooltip(i),i.style.visibility="true"})),i.addEventListener("focus",(()=>{this.setupTooltip(i)})),i}createCashbackTooltip(e,t){const i=this.flyoutData.strings.cbLearnMoreNew+". "+this.flyoutData.strings.cbToolTips,n=this.flyoutData.common.popupOrigination,o=this.flyoutData;function r(i,r){const a=new $.Z(s.$S.RebatesLearnMore,W.r.CASHBACK_RETAILER);a.Metadata=JSON.stringify({popupOriginationEnum:n}),e.RecordAsUserAction(ee.bS.REBATES_LEARN_MORE),e.RecordAsUserEngagement(A.FV.REBATES_LEARN_MORE,o.common.popupOrigination),t.LogInfoEvent(s.R.ButtonClick,i,a,r)}const a=this.flyoutData.dataStoreModule.CashBackData?.isPersonalizedCashback,l=this.flyoutData.common.isPane,c=this.createInfoIconTooltip(i,void 0,(function(){r("User navigated to rebates learn more",d.g.CouponImpressionId),a?e.NavigateToBingRebates():l||((0,N.Xo)(J.Q.CashBackOfferDetailsVisible,"true"),e.OpenPane(n))}),(function(){r("Hovered over tooltip")}),(function(){r("Focused on tooltip")}));return c.id="cbTooltip",c}async setupTooltipDiscover(e){e.width="270px",e.caratSide=Q.W.Bottom,e.caratLeftOffset="250px",e.style.setProperty("--carat-left-offset",e.caratLeftOffset),e.style.setProperty("--tooltip-width",e.width)}async setupTooltip(e){if(this.flyoutData.common.isDiscoverPane)return void this.setupTooltipDiscover(e);const t=e.getBoundingClientRect();if(await this.shouldDisplayTooltipSide(e,15)){const i=t.left-t.width-10;e.width=`${i}px`;let n=e.contentLength;e.content&&(n=e.content.length);let o=this.getTooltipAreaSize(n)/i+10;o>await this.getFullHeight()&&(e.fontSize="10px",o=this.getTooltipAreaSize(n,!0)/i+10);const r=await this.getAvailableHeight(t.top,t.height);e.caratTopOffset=o>r?o-r+"px":"2px",e.style.setProperty("--carat-top-offset",e.caratTopOffset),e.caratSide=Q.W.Right}else{const i=this.getFullWidth();let n=this.getAvailableWidth(t.left,t.width);if(257>i)e.width=`${i}px`,e.caratLeftOffset=i-this.getSideMargins()+"px";else{const t=245;n>t&&(n=t),e.width="257px",e.caratLeftOffset=`${n}px`,e.style.setProperty("--carat-left-offset",e.caratLeftOffset)}await this.getAvailableHeight(t.top,t.height)>15?e.caratSide=Q.W.Top:(e.caratSide=Q.W.Bottom,e.style.left="0px"),e.caratLeftOffset=`${n}px`,e.style.setProperty("--carat-left-offset",e.caratLeftOffset)}e.style.setProperty("--tooltip-width",e.width)}async shouldDisplayTooltipSide(e,t){const i=await this.getFullHeight(),n=e.getBoundingClientRect(),o=this.getAvailableWidth(n.left,n.width);let r=this.getFullWidth();r>257&&(r=257);const a=await this.getAvailableHeight(n.top,n.height);if(a>=300||a<t)return Promise.resolve(!1);const s=i*o>r*a;return e.className=s?"vertical":"horizontal",Promise.resolve(s)}async getFullHeight(){const e=await this.footerUtilities.showFooter()?32+this.getFooterMargins():0;return Promise.resolve(window.innerHeight-44-e)}async getAvailableHeight(e,t){return await this.getFullHeight()-(e-44)-t}getFullWidth(){return window.innerWidth-this.getSideMargins()-20}getAvailableWidth(e,t){return Math.round(e-this.getSideMargins()/2-t)}getTooltipAreaSize(e,t=!1){return e*(t?44:70)/(this.flyoutData.strings.cbLearnMore+". "+this.flyoutData.strings.cbToolTips).length*257}getFooterMargins(){return this.utilities.shouldRenderSmallNotification()?14:20}getSideMargins(){return this.utilities.shouldRenderSmallNotification()||this.flyoutData.common.isPane?40:32}}(i,this.viewModulesUtilities,this.commonAssets,this.footerUtilities),this.discoverTelemetryHandler=new B.Z(i,t,e)}}},79710:function(e,t,i){"use strict";i.d(t,{Ci:function(){return p},Oo:function(){return c},Qn:function(){return g},Ux:function(){return l},lw:function(){return u},oZ:function(){return d},s1:function(){return h},zM:function(){return f}});var n=i(93209),o=i(5144),r=i(27689),a=i(27775),s=i(87605);function l(e,t,i){const n=document.createElement(e);if(t)for(const e in t)t.hasOwnProperty(e)&&(n[e]=t[e]);return i&&(n.innerText=i),n}function c(e){if(e){let t="";return e.length>0&&(t+=e[0].toUpperCase()+e.substring(1)),t}return e}function d(e){if(e){let t="";const i=e.split(" "),n=["or","of","and","a","an"];return i.forEach((e=>{e.length>0&&(n.includes(e)?t+=e+" ":t+=e[0].toUpperCase()+e.substring(1).toLowerCase()+" ")})),t.trimEnd()}return e}function u(e){const t=l("fluent-button");return t.setAttribute("appearance","accent"),e.shouldRenderSmallNotification()?t.classList.add(a.q.PrimarySmallNotification):t.classList.add(a.q.Primary),t}function h(){const e=l("fluent-button");return e.classList.add(a.q.SimpleOutline),e}function p(){const e=l("fluent-button");return e.setAttribute("appearance","accent"),e.classList.add(a.q.PrimaryColor),e}function g(e,t,i,n,o){const r=l("fluent-tab");r.id=t,r.classList.add("sectionTabs"),o&&r.appendChild(o);const a=l("P");a.textContent=i,r.appendChild(a),e.appendChild(r);const s=l("fluent-tab-panel");return s.id=`${t}_MODULE`,n&&s.appendChild(n),e.appendChild(s),s}function f(e,t,i,a,c,d,u,h){const p=l("fluent-button");p.id="bestCouponBtn",p.classList.add("copyCouponBtn"),p.appearance="stealth",p.textContent=e.coupon.couponCode;const g=(0,r.fZ)("best coupon button aria label",i,e.coupon.couponCode);p.setAttribute("aria-label",g);const f=l("DIV");return f.style.display="flex",f.style.marginLeft="6px",f.slot="end",f.innerHTML=t.getCopyIcon(),f.setAttribute("aria-hidden","true"),p.appendChild(f),p.addEventListener("click",(async i=>{f.innerHTML=t.getBlueCheckCircle(),u.CopyCoupon(e.coupon.couponCode);const l=(0,r.fZ)("best coupon copied aria label",a,e.coupon.couponCode);p.setAttribute("aria-label",l);const g=new n.Z(o.$S.CouponCopied,d.setContentViewed(c));u.RecordAsUserAction(s.bS.COUPONS_COPIED),h.LogInfoEvent(o.R.ButtonClick,"Product best coupon copied",g),i.stopPropagation(),setTimeout((()=>{p.disabled=!0}),1500)})),p}},3960:function(e,t,i){"use strict";i.d(t,{h:function(){return x}});var n=i(72370),o=i(23026),r=i(53752),a=i(5144),s=i(88767),l=i(73557),c=i(81687),d=i(79710),u=i(98557),h=i(64865),p=i(4872),g=i(31656),f=i(59645),m=i(36493),v=i(27689),y=i(17728),C=i(23582),b=i(21908),S=i(65302);let x=function(e){return e[e.XSmall=0]="XSmall",e[e.Small=1]="Small",e[e.Medium=2]="Medium",e[e.Large=3]="Large",e}({});t.Z=class{constructor(e,t,i){(0,n.Z)(this,"commonAssets",void 0),(0,n.Z)(this,"flyoutData",void 0),(0,n.Z)(this,"logModule",void 0),this.flyoutData=e,this.logModule=t,this.commonAssets=i}handleHTMLDecode(e,t=!1){if((0,h.TF)(e))return"";const i=document.createElement("span"),n=[e];return n.raw=n,i.innerHTML=C.Z.getTrustedHTML(Object.freeze(n)),t?i.innerHTML:i.innerText}cleanCouponDescription(e){const t=/[^%%\w\.@\-, !$ぁ-ゔァ-ヴー一-龠々〆〤ヶÀ-ÖØ-öø-ÿĄąĆćĘꣳŃńÓóŚśŹźŻżа-яА-ЯёЁ\u0621-\u064A\u0660-\u0669]/g;try{return e.replace(t,"")}catch{return" "}}timeAgo(e){const t=new Date,i=new Date(e),n=t.getTime()-i.getTime(),o=Math.ceil(n/6e4),r=Math.ceil(n/36e5);if(!(r<=0||r>2))return o<60?(0,v.fZ)("timeSinceSuccessfulCoupon",this.flyoutData.strings.minutesAgo,o.toString()):1===r?(0,v.fZ)("timeSinceSuccessfulCoupon",this.flyoutData.strings.hourAgo,r.toString()):r>1&&r<=2?(0,v.fZ)("timeSinceSuccessfulCoupon",this.flyoutData.strings.hoursAgo,r.toString()):void 0}getDomainNameAndCapitalize(e){const t=e.split(".");let i;return i=-1!==["us","ca","uk","au","nz","ie","fr","de","it","es","mx","br","eu","jp"].indexOf(t[0])?(0,d.Oo)(t[1]):(0,d.Oo)(t[0]),"Macys"===i?"Macy's":"Kohls"===i?"Kohl's":i}removeDomainPrefix(e){const t=e.split(".");let i=0;return-1!==["us","ca","uk","au","nz","ie","fr","de","it","es","mx","br","eu","jp"].indexOf(t[0])&&(i=1),t.slice(i).join(".")}getPwiloPopupOrigination(e){const t=e?.getState(c.IY.outOfFlow);if(t)return t===l.W5.ABANDONED_CART_COUPONS?l.sR.AUTO_SHOW_ABANDONED_CART:t===l.W5.PRODUCT_TRACKING_BACK_IN_STOCK?l.sR.AUTO_SHOW_PRODUCT_TRACKING_BACK_IN_STOCK:t===l.W5.PRODUCT_TRACKING_EXP_PRICE_DROP?l.sR.AUTO_PRODUCT_TRACKING_EXP_PRICE_DROP:t===l.W5.PRODUCT_TRACKING_IMP_PRICE_DROP?l.sR.AUTO_PRODUCT_TRACKING_IMP_PRICE_DROP:t===l.W5.PRODUCT_TRACKING_OUT_OF_STOCK?l.sR.AUTO_PRODUCT_TRACKING_OUT_OF_STOCK:void 0}toFixedSafe(e,t){return e&&e.toFixed?e.toFixed(t):""}formatToParts(e,t){try{let i,n,o,r;n=t||this.flyoutData.common.pageLocale;try{const t=e[e.length-3];","===t?(o=e.replace(".",""),o=o.replace(",",".")):"."===t&&(o=e.replace(",",""))}catch(e){}return r=o?+o:+e,i=new Intl.NumberFormat(n,{maximumFractionDigits:2,minimumFractionDigits:2}).formatToParts(r),i||i}catch(e){return[]}}getCurrencyMarket(e){return e||this.flyoutData.common.pageLocale}getFormattedPrice(e,t){return e%1!=0?new Intl.NumberFormat(t,{maximumFractionDigits:2,minimumFractionDigits:2}).format(e):new Intl.NumberFormat(t).format(e)}formatPrice(e,t){try{const i=this.getCurrencyMarket(t);return this.getFormattedPrice(e,i)||this.toFixedSafe(e,2)}catch(t){return this.toFixedSafe(e,2)}}isDarkMode(){const e=this.flyoutData.common.currentTheme===s.Q2.Dark,t=window,i=!!(t&&t.matchMedia&&t.matchMedia("(prefers-color-scheme: dark)")?.matches);return e||i}isPinterest(){return(void 0!==this.flyoutData.dataStoreModule.PinterestData?.productLink&&void 0!==this.flyoutData.common.lastCommittedURL&&null!==this.flyoutData.common.lastCommittedURL&&this.flyoutData.common.lastCommittedURL.includes("pinterest.com/pin"))??!1}createPDPLoadingStateUX(e,t,i,n,o){e.id=i,e.classList.add("loadingSection"),e.accordion=!0,e.expanded=!0;const r=(0,d.Ux)("DIV",{style:'\n display: grid;\n grid-template-areas:\n "img img title title title title"\n "img img subTitle subTitle subTitle subTitle"\n "content1 content1 content1 content1 content1 content1"\n "content2 content2 content2 content2 content2 content2"\n "content3 content3 content3 content3 content3 content3";\n grid-gap: 20px;\n padding: 0px 2px;\n '});r.id=t;let a=1;this.isDarkMode()&&(a=.08);const s=(0,d.Ux)("DIV",{style:`\n grid-area: img;\n border-radius: 4px;\n background-color: #F1F1F1;\n height: 100px;\n opacity: ${a};\n `}),l=(0,d.Ux)("DIV",{style:`\n grid-area: title;\n border-radius: 4px;\n background-color: #F1F1F1;\n height: 20px;\n margin-top: 20px;\n margin-right: 50px;\n opacity: ${a};\n `}),u=(0,d.Ux)("DIV",{style:`\n grid-area: subTitle;\n border-radius: 4px;\n background-color: #F1F1F1;\n height: 20px;\n margin-bottom: 20px;\n margin-right: 50px;\n opacity: ${a};\n `}),h=(0,d.Ux)("DIV",{style:`\n grid-area: content1;\n border-radius: 4px;\n background-color: #F1F1F1;\n height: 30px;\n opacity: ${a};\n `}),p=(0,d.Ux)("DIV",{style:`\n grid-area: content2;\n border-radius: 4px;\n background-color: #F1F1F1;\n height: 30px;\n opacity: ${a};\n `}),g=(0,d.Ux)("DIV",{style:`\n grid-area: content3;\n border-radius: 4px;\n background-color: #F1F1F1;\n height: 30px;\n opacity: ${a};\n `});r.appendChild(s),r.appendChild(l),r.appendChild(u),r.appendChild(h),r.appendChild(p),r.appendChild(g),e.appendChild(r),setTimeout((()=>{const e=document.querySelector(`#${t}`);if(e){e.parentElement?.remove();const t=new CustomEvent(c.e1.PDPRemoved,{detail:{moduleName:o}});n.dispatchEvent(t)}}),7e3)}async setImageSrc(e,t,i){return new Promise(((n,o)=>{e.src=t,e.addEventListener("error",(()=>{e.src=i??this.commonAssets.getDefaultProductImage(),n(!1)})),e.addEventListener("load",(()=>{n(!0)}))}))}setImageSrcAndConvertToBase64(e,t,i){i?i.GetSafeImage(t).then((t=>{t.succ?e.src=t.safeImgData:e.src=this.flyoutData.common.resourcesEndpoint+"common/defaultProduct.svg"})):e.src=this.flyoutData.common.resourcesEndpoint+"common/defaultProduct.svg"}addCommonStyles(e,t,i){try{this.applyFluentDesignStyles(t),this.applyWrapperStyles(e,i)}catch(e){const t=new f.Z(a.xu.OnErrorInvoked);this.logModule.LogErrorEvent(a.R.EdgeFlyoutStatus,`error adding common styles ${e}`,t)}}createCommonListStructure(e,t,i,n,o,r,a,l,c){const u=this.flyoutData.common.isPane;this.flyoutData.common.currentDevice===s.AS.Desktop?e.accordion=!0:e.accordion=!1,e.titleText=t,e.expanded=!1;const h=o(i),p=l?i?[...i.keys()]:null:i;if(p&&p.length>h){const o=document.createElement("fluent-button");if(o.slot="action",o.className+="action btnSeeMore",o.tabIndex=0,u){o.classList.add("newSeeMore"),o.appearance="neutral",e.classList.add("noInlinePadding");const t=(0,d.Ux)("div");t.style.display="inline-block",t.style.paddingLeft="10px",t.innerHTML=this.commonAssets.getCaretDownIcon(),o.textContent=this.flyoutData.strings.bgShowMore,o.appendChild(t)}else o.appearance="lightweight",o.style.backgroundColor="transparent",o.style.padding="0px",i.length-h>20?o.textContent=(0,v.fZ)("sectionSeeMore",this.flyoutData.strings.sectionSeeMore,"20+"):o.textContent=(0,v.fZ)("sectionSeeMore",this.flyoutData.strings.sectionSeeMore,(i.length-h).toString());let l;if(o.setAttribute("aria-label",`${o.textContent} of ${t}`),this.isDarkMode()?o.style.color="#FFFFFF":o.style.color=this.flyoutData.common.isPane?"#1A1A1A":"#666666",c){const t=(0,d.Ux)("DIV",{});t.classList.add("cjkNewSeeMore"),t.role="button",t.textContent=(0,v.fZ)("sectionSeeMore",this.flyoutData.strings.sectionSeeMore,""+(i.length-h)),t.addEventListener("click",(n=>{this.seeMoreClickHandler(n,e,r,t,i,a)})),t.addEventListener("keydown",(n=>{"Enter"!==n.key&&" "!==n.key||(this.seeMoreClickHandler(n,e,r,t,i,a),n.preventDefault())})),t.tabIndex=0,e.appendChild(t),e.classList.add("cjkDivNewSeeMore")}else{if(n===s.ModuleNames.COUPON||n===s.ModuleNames.RECOMMENDATIONS||n===s.ModuleNames.PRINTABLE_COUPON||n===s.ModuleNames.SOCIALCOUPONS||n===s.ModuleNames.CASHBACK||n===s.ModuleNames.GROCERY_CASHBACK||n===s.ModuleNames.ITEMIZED_CASHBACK||u)e.appendChild(o);else{const t=this.isDarkMode()?"linear-gradient(265.08deg, rgba(36, 255, 0, 0.06) -6.71%, rgba(0, 210, 255, 0.06) 38.87%, rgba(255, 188, 125, 0.06) 93.88%)":(0,S.tB)(this.flyoutData)?"none":"linear-gradient(90deg, #FFFBF2 0%, #EEFCFF 53.12%, #F5F9FF 100%)";l=(0,d.Ux)("DIV",{style:`\n background: ${t};\n height: 40px;\n padding-left: 12px;\n cursor: pointer;\n display: flex;\n align-items: center;\n border-top: 1px solid rgb(236, 236, 236);\n `}),l.className="divSeeMore",l.appendChild(o),e.appendChild(l),l&&l.addEventListener("click",(t=>{this.seeMoreClickHandler(t,e,r,l,i,a)}))}o&&o.addEventListener("click",(t=>{l||this.seeMoreClickHandler(t,e,r,o,i,a)}))}}else e.style.marginBottom="10px"}addFavIconSrc(e,t,i,n=!1,o=!1){const r=new f.Z(a.xu.FavIconRenderStatus),s=n?i:this.getFavIconSrc(i);let l=!0;e.style.maxWidth="16px",e.slot="icon",e.setAttribute("aria-hidden","true"),e.addEventListener("error",(()=>{l=!1,e.remove()})),this.flyoutData.common.isCJKEnabled&&(e.style.maxWidth="20px",e.style.maxHeight="20px"),s?e.src=s:l=!1,l&&t.appendChild(e),o&&this.logModule.LogInfoEvent(a.R.EdgeFlyoutStatus,"Fav Icon render status "+l+" for "+i,r)}addFavIconSVG(e,t,i){let n=!0;e.style.maxWidth="16px",e.slot="icon",e.setAttribute("aria-hidden","true"),e.addEventListener("error",(()=>{n=!1,e.remove()})),this.flyoutData.common.isCJKEnabled&&(e.style.maxWidth="20px",e.style.maxHeight="20px"),i?e.innerHTML=i:n=!1,n&&t.appendChild(e)}addFavIconBase64(e,t,i,n){e.style.maxWidth="16px",e.slot="icon",e.setAttribute("aria-hidden","true"),e.addEventListener("error",(()=>{e.remove()})),this.flyoutData.common.isCJKEnabled&&(e.style.maxWidth="20px",e.style.maxHeight="20px"),this.setImageSrcAndConvertToBase64(e,i,n),t.appendChild(e)}checkIfActionInLoadTimeData(e,t){return!(!e||!(t in e))}getFavIconSrc(e,t=20){return e?this.flyoutData.common.isCJKEnabled?`${e}`:(e=(e=e.replace("http://","")).replace("https://",""),this.flyoutData.dataLoader.IsServerData()?`https://edge.microsoft.com/favicon/v1/?client=chrome_desktop&nfrp=2&check_seen=true&size=${t}&fallback_opts=TYPE,SIZE,URL&url=http://${e}&origin=shoppingv2`:this.flyoutData.common.currentDevice===s.AS.Mobile?`https://${e}/favicon.ico`:`edge://favicon2/?size=16&scale_factor=1x&page_url=http://${e}&allow_google_server_fallback=1`):""}trapFlyoutFocusMac(){this.flyoutData.common.isPane||b.Z.getInstance().initialize(this.flyoutData.common.shopping,!1,this.flyoutData)}applyStyles(e,t,i,n){if(e){const o=(0,d.Ux)("STYLE");let r=t;this.isDarkMode()&&(r=`${r}\n${n}`),o.textContent=r,o.type="text/css",o.rel="stylesheet",i&&(o.id=i),e.appendChild(o)}}addSectionSeparator(e){const t=(0,d.Ux)("HR",{className:"sectionSeparator"});t.setAttribute("aria-hidden","true"),e.appendChild(t)}styleModules(e,t,i){this.styleModulesHeader(t,e,i),this.flyoutData.common.isPane&&(e.moduleLayout===s.SV.BLOCK?e.element.classList.add("actionBlock"):e.element.classList.add("actionPane"),e.name!==s.ModuleNames.PRODUCTHISTORY||i.classList.contains("isStoryBook")&&!i.classList.contains("isPolePositionStory")||(e.element.accordion=!1,e.element.classList.add("accordionPadding")))}appendNewModuleToFlyout(e){const t=this.flyoutData.common.shopping.querySelectorAll("msft-edge-shopping-section");let i=!1;if(t&&t.length>0&&!this.flyoutData.common.isPane)try{if(1===t.length){const n=(0,d.Ux)("HR",{className:"sectionSeparator"});n.setAttribute("aria-hidden","true"),t[0].nextSibling?(this.flyoutData.common.shopping.insertBefore(n,t[0].nextSibling),this.flyoutData.common.shopping.insertBefore(e.element,n.nextSibling),i=!0):(this.addSectionSeparator(this.flyoutData.common.shopping),this.flyoutData.common.shopping.appendChild(e.element),i=!0)}else for(let n=1;n<t.length;n++){const o=t[n];if(null!==o.getAttribute("accordion")){const t=(0,d.Ux)("HR",{className:"sectionSeparator"});t.setAttribute("aria-hidden","true"),"HR"===o.previousSibling?.nodeName?(this.flyoutData.common.shopping.insertBefore(t,o.previousSibling),this.flyoutData.common.shopping.insertBefore(e.element,o.previousSibling)):(this.flyoutData.common.shopping.insertBefore(t,o),this.flyoutData.common.shopping.insertBefore(e.element,o)),i=!0}}}catch(t){this.addSectionSeparator(this.flyoutData.common.shopping),this.flyoutData.common.shopping.appendChild(e.element),i=!0}else{const t=this.flyoutData.common.shopping.querySelector("#feedbackDiv");if(t){const i=(0,d.Ux)("HR",{className:"sectionSeparator"});i.setAttribute("aria-hidden","true"),this.flyoutData.common.shopping.insertBefore(i,t),this.flyoutData.common.shopping.insertBefore(e.element,t)}else this.addSectionSeparator(this.flyoutData.common.shopping),this.flyoutData.common.shopping.appendChild(e.element),i=!0}if(!i){const t=this.flyoutData.common.shopping.querySelector("#feedbackDiv");if(t){const i=(0,d.Ux)("HR",{className:"sectionSeparator"});i.setAttribute("aria-hidden","true"),this.flyoutData.common.shopping.insertBefore(i,t),this.flyoutData.common.shopping.insertBefore(e.element,t)}else this.addSectionSeparator(this.flyoutData.common.shopping),this.flyoutData.common.shopping.appendChild(e.element)}}shouldRenderSmallNotification(){if(this.flyoutData.common.openedWith===s.Te.Auto){const e=this.flyoutData.common.popupOrigination;if(e===l.sR.AUTO_SHOW_PRICE_HISTORY||e===l.sR.AUTO_SHOW_PACKAGE_TRACKING||e===l.sR.AUTO_SHOW_COUPONS_CHECKOUT||e===l.sR.AUTO_SHOW_LOWER_PRICE_FOUND||e===l.sR.AUTO_SHOW_PRICE_DROP_PLUS_CASHBACK||e===l.sR.AUTO_SHOW_OTHER_SELLERS||e===l.sR.AUTO_SHOW_REBATES_ORGANIC||e===l.sR.AUTO_SHOW_REBATES_ORGANIC_NEW||e===l.sR.AUTO_SHOW_REBATES_CHECKOUT||e===l.sR.AUTO_SHOW_REBATES||e===l.sR.AUTO_SHOW_REBATES_PDP||e===l.sR.AUTO_SHOW_REBATES_CONFIRMATION||e===l.sR.AUTO_SHOW_REBATES_DEACTIVATED||e===l.sR.AUTO_SHOW_COUPONS_CLIPPING||e===l.sR.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION||e===l.sR.AUTO_SHOW_GIFT_CARD||e===l.sR.AUTO_PRODUCT_TRACKING_OUT_OF_STOCK||e===l.sR.AUTO_SHOW_AUTOS_MARKETPLACE||e===l.sR.AUTO_SHOW_ITEM_ADDED_TO_CART_FROM_OTHER_SELLER||e===l.sR.AUTO_SHOW_SOCIAL_COUPONS||e===l.sR.AA_CONSENT||e===l.sR.AUTO_SHOW_PRODUCT_BEST_COUPON_CONSENT||e===l.sR.AUTO_SHOW_RECOMMENDATIONS||e===l.sR.AUTO_SHOW_PERSONALIZED_CASHBACK||e===l.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_CONFIRMATION||e===l.sR.AUTO_SHOW_REBATES_SWITCHED_TO_MSA||e===l.sR.AUTO_SHOW_CAMPAIGN_PDP_NOTIFICATION||e===l.sR.AUTO_SHOW_CASHBACK_PDP_PLUS_COUPONS||e===l.sR.AUTO_SHOW_CAMPAIGN_AWARENESS_NOTIFICATION||e===l.sR.AUTO_SHOW_POST_PURCHASE_TRACKING||e===l.sR.AUTO_SHOW_LOWER_PRICE_PLUS_CASHBACK_PLUS_COUPONS||e===l.sR.AUTO_SHOW_ARTICLES_CASHBACK_NOTIFICATION||e===l.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_ADDRESSBAR||e===l.sR.AUTO_SHOW_DISCOVER_NOTIFICATION||e===l.sR.AUTO_SHOW_CJK_COUPON_FOUND||e===l.sR.AUTO_SHOW_CJK_PRICE_DROP)return!0}return!1}isValidScenarioForProductSummary(){const e=this.flyoutData.dataStoreModule?.PriceHistoryData,t=this.flyoutData.dataStoreModule?.PriceComparisonData,i=this.flyoutData.dataStoreModule?.CashBackData,n=this.flyoutData.dataStoreModule?.CouponData?.Coupons?.length,o=null!=t&&t.CompetingPrices&&t.CompetingPrices.length>1?1:0,r=null!=e&&e.ShowPriceHistoryInsight?1:0;return o+r>1&&!this.flyoutData.dataStoreModule?.TrendingCouponsData||o+r>0&&(i&&i.canRenderCashback?1:0)+(n&&n>0?1:0)>0}isSearchPage(){const e=this.flyoutData.dataStoreModule.ApiData?.retailerData?.searchQueryUrlRegex,t=this.flyoutData.common.lastCommittedURL;if(e&&t){const i=new RegExp(e).exec(t);return i&&1===i.length}return!1}createProductImage(e,t,i,n,o){const r=(0,d.Ux)("DIV"),a=(0,d.Ux)("DIV");return this.setContainerStyles(r,e,t,o),this.setGrayOverlayStyles(a,e,t),this.setImageStyles(i,e,t,n),r.appendChild(i),o||r.appendChild(a),r}createNotificationModule(e,t,i){const n=new y.Z;return n.element=e,n.name=t,n.moduleInterface=i,n}sendFlyoutUpdateEvent(e,t){u.SO.queueUpdate((()=>{const i=new CustomEvent(c.e1.onDataUpdate,{detail:{moduleType:t}});e.dispatchEvent(i)}))}async logMuidNotificationShown(e,t){if(!e||!t)return Promise.resolve(!1);const i={Muid:e,NotificationType:t,Timestamp:(new Date).toISOString()};return fetch("https://www.bing.com/api/shopping/v1/savings/user/logNotification",{body:JSON.stringify(i),headers:{Accept:"application/json","Content-Type":"application/json"},method:"POST"}).then((async e=>200===e.status)).catch((e=>!1))}seeMoreClickHandler(e,t,i,n,o,r){const a=(0,v.pq)(e);i(t,!0,a,o,r),n.remove(),u.SO.queueUpdate((()=>{const e=t.shadowRoot;if(e){const t=e.querySelector(".action");t&&(t.style.display="none")}}))}switchShoppingTab(e){if(g.R.isExperimentActive(p.H.singleScrollingShoreline))return void this.switchSingleScrollingShoppingTab(e);const t=window.document.querySelector("#shoppingTab");t&&t.activeid!==e&&(t.activeid=e)}switchSingleScrollingShoppingTab(e){const t=e===s.d$.Home?s.d$.MyShopping:s.d$.CouponsSavings;globalThis.singleScrollingActiveTab=t}setFocusAfterDeletion(e,t,i,n,o){const r=e.querySelector(i),a=e.querySelector(o);let s=-1;return t+1<r?.childElementCount||t+1===r?.childElementCount&&null!==a?s=t:t+1===r?.childElementCount&&(s=t-1),-1===s&&u.SO.queueUpdate((()=>{const e=document.querySelector(n);e&&e.focus()})),s}createCommissionArrow(e,t=!1,i,n,o,r,a){const s=(0,d.Ux)("DIV");s.className="imgCBTag",s.setAttribute("aria-hidden","true"),s.style.float="left",s.style.marginRight="-1px";const l=(0,d.Ux)("DIV");l.className="imgCBTag",l.setAttribute("aria-hidden","true"),l.style.float="left";const c=(0,d.Ux)("span");if(c.className="spanCommissionValue",c.style.paddingLeft="1px",t&&e){const t=this.createSplitPrice(e,o,i);c.append(t)}else{const t=e??this.retrieveCashBackAmount().cashBackAmount;c.textContent=a?`${o}${t}`:t}switch(i){case x.XSmall:c.className="spanCommissionValueXSmall",s.innerHTML=this.commonAssets.getXSmallTagLeft(),s.style.height="16px",l.innerHTML=this.commonAssets.getXSmallTagRight(),l.style.height="16px";break;case x.Small:c.className="spanCommissionValueSmall",s.innerHTML=this.commonAssets.getSmallTagLeft(),s.style.height="20px",l.innerHTML=this.commonAssets.getSmallTagRight(),l.style.height="20px";break;case x.Medium:s.innerHTML=this.commonAssets.getMediumTagLeft(),s.style.height="24px",l.innerHTML=this.commonAssets.getMediumTagRight(),l.style.height="24px";break;case x.Large:c.className="spanCommissionValueLarge";default:s.innerHTML=this.commonAssets.getLargeTagLeft(),s.style.height="30px",l.innerHTML=this.commonAssets.getLargeTagRight(),l.style.height="30px"}const u=(0,d.Ux)("DIV");return u.className=r?"divPdpEstimateCommissionValue":"divCommissionValue",u.appendChild(s),u.appendChild(c),u.appendChild(l),n&&n(u),u}createYellowLight(){const e=(0,d.Ux)("DIV");return e.setAttribute("aria-hidden","true"),e.style.display="inline-block",e.style.verticalAlign="vertical-align: -webkit-baseline-middle",e.innerHTML=this.commonAssets.getYellowLightIcon(),e}retrieveCashBackAmount(e,t=!1,i){let n="";const o=i??this.flyoutData.dataStoreModule.CashBackData?.highestCashBackCategory;let r,a,s="$";if(o?.commissionType&&!t){r=o.commissionType,a=o.commissionValue;const e=(0,v.uf)(this.flyoutData.dataStoreModule.ApiData?.market,this.flyoutData.dataStoreModule.ApiData?.retailerData?.exclusiveMarket);s=(0,m.N6)(e)??s}else e&&e?.commissionType?(r=e.commissionType,a=e.commissionValue,s=e.adsCurrencySymbol):e&&e?.adsCashback?.length>0&&(r=e.adsCashback[0].commissionType,a=e.adsCashback[0].commissionValue,s=e.adsCashback[0].adsCurrencySymbol);return s=(0,m.Jl)(s),"%"===r?n=`${a}%`:"flat"===r&&(n=i?`${s}${Math.floor(a)}`:`${s}${this.formatPrice(a)||Math.floor(a)}`),{cashBackAmount:n,currencySymbol:s}}createCloseButton(){const e=(0,d.Ux)("fluent-button");e.ariaLabel=this.flyoutData.strings.commonClose,e.appearance="stealth";const t=(0,d.Ux)("DIV");return t.style.display="flex",t.style.alignContent="center",t.setAttribute("aria-hidden","true"),t.innerHTML=this.commonAssets.getCloseButton(),e.appendChild(t),e}getImageSrc(e){let t,i=e?.ProductDetails?.extractedImage??e?.ProductDetails?.base64ProductImage??e?.ProductDetails?.imageUrl;if(!i){const e=new f.Z(a.xu.PriceHistoryNoImage);this.logModule.LogInfoEvent(a.R.EdgeFlyoutStatus,"Price history - no image",e)}if(i)if(!e?.ProductDetails?.extractedImage&&e?.ProductDetails?.base64ProductImage)t=`data:image/png;base64,${i}`;else try{i.toString().startsWith("http")||(i="https://"+i),t=i}catch(e){}return t||(t=this.flyoutData.common.resourcesEndpoint+"common/defaultProduct.svg"),t}makeHtmlElementKeyboardClickable(e,t){e.addEventListener("keydown",(e=>{"Enter"!==e.key&&" "!==e.key||t(e)}))}handleCjkSectionAsTopModuleStyle(e){if(e){const t=e.shadowRoot?.querySelector("fluent-accordion-item");t&&t.classList.add("cjk-region-top")}}createSplitPrice(e,t="$",i){const n=(0,d.Ux)("div");n.style.display="inline-flex",n.style.justifyContent="center";const o=(0,d.Ux)("span"),r=(0,m.nR)(`${e}`);if("object"==typeof r){const e=(0,d.Ux)("span");e.className=i===x.Medium?"splitPriceSmall":"splitPrice",e.textContent=(0,m.Jl)(t),o.textContent=r.dollars;const a=(0,d.Ux)("span");a.className=i===x.Medium?"splitPriceSmall":"splitPrice",a.textContent=(0,h.TF)(r.cents)?"00":r.cents,n.appendChild(e),n.appendChild(o),n.appendChild(a)}else o.textContent=`${t}${r}`,n.appendChild(o);return n}setImageBackgroundStyles(e,t,i){try{const n=new Image;n.crossOrigin="anonymous",n.src=e.src,n.onload=()=>{const o=document.createElement("canvas");o.width=n.width,o.height=n.height,o.getContext("2d")?.drawImage(n,0,0,n.width,n.height);const r=o.getContext("2d")?.getImageData(0,0,1,1).data;r&&255===r[0]&&255===r[1]&&255===r[2]||(e.style.minWidth=`${t}px`,e.style.minHeight=`${i}px`,e.style.maxWidth="",e.style.maxHeight="")},e.style.maxWidth=t-10+"px",e.style.maxHeight=i-10+"px"}catch(n){e.style.maxWidth=t-10+"px",e.style.maxHeight=i-10+"px"}}applyFluentDesignStyles(e){const t=this.getFluentDesignElement(e);t&&(this.setFluentDesignFillColor(t),this.setFluentDesignDirection(t),this.flyoutData.common.isPane&&t.removeAttribute("role"))}getFluentDesignElement(e){return e||document.querySelector("fluent-design-system-provider")}setFluentDesignFillColor(e){this.isDarkMode()?(e.setAttribute("fill-color","#3b3b3b"),o.q2d.setValueFor(e,.23)):(e.setAttribute("fill-color","#FFFFFF"),o.q2d.setValueFor(e,r.h.LightMode))}setFluentDesignDirection(e){this.flyoutData.common.currentDirection===s.m5.RTL?e.style.direction="rtl":e.style.direction="ltr"}applyWrapperStyles(e,t){const i=this.getWrapperElement(t);i&&(this.applyStylesToWrapper(i,e),this.flyoutData.common.isCJKEnabled&&this.flyoutData.common.openedWith===s.Te.Hover?i.classList.add("ms-edge-shopping-489"):this.applyExperimentClassToWrapper(i))}applyStylesToWrapper(e,t){this.shouldRenderSmallNotification()?this.applyStyles(e,t.getStyles()+t.getSmallerNotificationCssStyles(),void 0,t.getDarkModeStyles()):this.applyStyles(e,t.getStyles(),void 0,t.getDarkModeStyles())}applyExperimentClassToWrapper(e){g.R.isExperimentActive(p.H.showPaymentOptions)&&e.classList.add("ms-edge-shopping-650")}getWrapperElement(e){return e||document.querySelector("#divContentWrapper")}styleModulesHeader(e,t,i){const n=t.element,o=t.name;if(0===e&&n.expanded){let e=!1;const r=this.flyoutData.dataStoreModule.CashBackData;o===s.ModuleNames.PRODUCTHISTORY||o===s.ModuleNames.GROCERY_CASHBACK||o===s.ModuleNames.ITEMIZED_CASHBACK||o===s.ModuleNames.ABANDONED_CART||o===s.ModuleNames.TRENDING_COUPONS||o===s.ModuleNames.ACTIVE_RETAILER_INBOX_COUPONS||o===s.ModuleNames.AX_SHOPPING_NAV||o===s.ModuleNames.DISCOVER_CHAT_CHIPS||o===s.ModuleNames.COUPON&&r?.canRenderCashback&&!r?.isCashBackActivated&&!this.flyoutData.common.suppressRebatesScenarios||i.classList.contains("isStoryBook")&&!i.classList.contains("isPolePositionStory")||((!this.flyoutData.common.isCJKEnabled||o!==s.ModuleNames.PRICEHISTORY&&o!==s.ModuleNames.PRICECOMPARISON&&o!==s.ModuleNames.CJK_SIMILAR_PRODUCTS&&o!==s.ModuleNames.COUPON)&&(t.element.hideTitle=!0),o===s.ModuleNames.PRICECOMPARISON&&g.R.isExperimentActive(p.H.priceCompareV2)&&(t.element.hideTitle=!1),e=!0),o===s.ModuleNames.PRICECOMPARISON&&g.R.isExperimentActive(p.H.priceCompareV2)||e&&(o!==s.ModuleNames.PRODUCTHISTORY&&o!==s.ModuleNames.ABANDONED_CART&&o!==s.ModuleNames.TRENDING_COUPONS&&o!==s.ModuleNames.AX_SHOPPING_NAV||!this.flyoutData.common.isPane)||i.classList.contains("isStoryBook")&&!i.classList.contains("isPolePositionStory")||(n.accordion=!1,n.classList.add("accordionPadding")),n.style.marginTop="0px"}}setContainerStyles(e,t,i,n){e.className="divProductImageContainer",e.style.width=`${t}px`,e.style.height=`${i}px`,e.style.borderRadius=n?"0px":t>75?"8px":"4px"}setGrayOverlayStyles(e,t,i){e.className="divProductImageAlpha",e.style.width=`${t}px`,e.style.height=`${i}px`}setImageStyles(e,t,i,n){e.classList.add("imgProduct"),n?e.setAttribute("aria-label",n):e.setAttribute("aria-hidden","true"),this.setImageBackgroundStyles(e,t,i)}}},46357:function(e,t,i){"use strict";var n;i.d(t,{W:function(){return n}}),function(e){e[e.Right=0]="Right",e[e.Left=1]="Left",e[e.Top=2]="Top",e[e.Bottom=3]="Bottom"}(n||(n={}))},44077:function(e,t,i){"use strict";i.r(t),i.d(t,{Box:function(){return C},Stack:function(){return v}});var n=i(84045),o=i(61492),r=i(74551),a=i(44323);function s(e){return s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s(e)}function l(e){var t=function(e,t){if("object"!==s(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==s(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===s(t)?t:String(t)}var c,d={exports:{}},u={};d.exports=function(){if(c)return u;c=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),r=Symbol.for("react.provider"),a=Symbol.for("react.context"),s=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),d=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),p=Symbol.iterator,g={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},f=Object.assign,m={};function v(e,t,i){this.props=e,this.context=t,this.refs=m,this.updater=i||g}function y(){}function C(e,t,i){this.props=e,this.context=t,this.refs=m,this.updater=i||g}v.prototype.isReactComponent={},v.prototype.setState=function(e,t){if("object"!=typeof e&&"function"!=typeof e&&null!=e)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")},v.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},y.prototype=v.prototype;var b=C.prototype=new y;b.constructor=C,f(b,v.prototype),b.isPureReactComponent=!0;var S=Array.isArray,x=Object.prototype.hasOwnProperty,T={current:null},w={key:!0,ref:!0,__self:!0,__source:!0};function O(t,i,n){var o,r={},a=null,s=null;if(null!=i)for(o in void 0!==i.ref&&(s=i.ref),void 0!==i.key&&(a=""+i.key),i)x.call(i,o)&&!w.hasOwnProperty(o)&&(r[o]=i[o]);var l=arguments.length-2;if(1===l)r.children=n;else if(1<l){for(var c=Array(l),d=0;d<l;d++)c[d]=arguments[d+2];r.children=c}if(t&&t.defaultProps)for(o in l=t.defaultProps)void 0===r[o]&&(r[o]=l[o]);return{$$typeof:e,type:t,key:a,ref:s,props:r,_owner:T.current}}function P(t){return"object"==typeof t&&null!==t&&t.$$typeof===e}var A=/\/+/g;function E(e,t){return"object"==typeof e&&null!==e&&null!=e.key?function(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,(function(e){return t[e]}))}(""+e.key):t.toString(36)}function k(i,n,o,r,a){var s=typeof i;"undefined"!==s&&"boolean"!==s||(i=null);var l=!1;if(null===i)l=!0;else switch(s){case"string":case"number":l=!0;break;case"object":switch(i.$$typeof){case e:case t:l=!0}}if(l)return a=a(l=i),i=""===r?"."+E(l,0):r,S(a)?(o="",null!=i&&(o=i.replace(A,"$&/")+"/"),k(a,n,o,"",(function(e){return e}))):null!=a&&(P(a)&&(a=function(t,i){return{$$typeof:e,type:t.type,key:i,ref:t.ref,props:t.props,_owner:t._owner}}(a,o+(!a.key||l&&l.key===a.key?"":(""+a.key).replace(A,"$&/")+"/")+i)),n.push(a)),1;if(l=0,r=""===r?".":r+":",S(i))for(var c=0;c<i.length;c++){var d=r+E(s=i[c],c);l+=k(s,n,o,d,a)}else if(d=function(e){return null===e||"object"!=typeof e?null:"function"==typeof(e=p&&e[p]||e["@@iterator"])?e:null}(i),"function"==typeof d)for(i=d.call(i),c=0;!(s=i.next()).done;)l+=k(s=s.value,n,o,d=r+E(s,c++),a);else if("object"===s)throw n=String(i),Error("Objects are not valid as a React child (found: "+("[object Object]"===n?"object with keys {"+Object.keys(i).join(", ")+"}":n)+"). If you meant to render a collection of children, use an array instead.");return l}function I(e,t,i){if(null==e)return e;var n=[],o=0;return k(e,n,"","",(function(e){return t.call(i,e,o++)})),n}function D(e){if(-1===e._status){var t=e._result;(t=t()).then((function(t){0!==e._status&&-1!==e._status||(e._status=1,e._result=t)}),(function(t){0!==e._status&&-1!==e._status||(e._status=2,e._result=t)})),-1===e._status&&(e._status=0,e._result=t)}if(1===e._status)return e._result.default;throw e._result}var _={current:null},N={transition:null},R={ReactCurrentDispatcher:_,ReactCurrentBatchConfig:N,ReactCurrentOwner:T};return u.Children={map:I,forEach:function(e,t,i){I(e,(function(){t.apply(this,arguments)}),i)},count:function(e){var t=0;return I(e,(function(){t++})),t},toArray:function(e){return I(e,(function(e){return e}))||[]},only:function(e){if(!P(e))throw Error("React.Children.only expected to receive a single React element child.");return e}},u.Component=v,u.Fragment=i,u.Profiler=o,u.PureComponent=C,u.StrictMode=n,u.Suspense=l,u.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=R,u.cloneElement=function(t,i,n){if(null==t)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+t+".");var o=f({},t.props),r=t.key,a=t.ref,s=t._owner;if(null!=i){if(void 0!==i.ref&&(a=i.ref,s=T.current),void 0!==i.key&&(r=""+i.key),t.type&&t.type.defaultProps)var l=t.type.defaultProps;for(c in i)x.call(i,c)&&!w.hasOwnProperty(c)&&(o[c]=void 0===i[c]&&void 0!==l?l[c]:i[c])}var c=arguments.length-2;if(1===c)o.children=n;else if(1<c){l=Array(c);for(var d=0;d<c;d++)l[d]=arguments[d+2];o.children=l}return{$$typeof:e,type:t.type,key:r,ref:a,props:o,_owner:s}},u.createContext=function(e){return(e={$$typeof:a,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null}).Provider={$$typeof:r,_context:e},e.Consumer=e},u.createElement=O,u.createFactory=function(e){var t=O.bind(null,e);return t.type=e,t},u.createRef=function(){return{current:null}},u.forwardRef=function(e){return{$$typeof:s,render:e}},u.isValidElement=P,u.lazy=function(e){return{$$typeof:h,_payload:{_status:-1,_result:e},_init:D}},u.memo=function(e,t){return{$$typeof:d,type:e,compare:void 0===t?null:t}},u.startTransition=function(e){var t=N.transition;N.transition={};try{e()}finally{N.transition=t}},u.unstable_act=function(){throw Error("act(...) is not supported in production builds of React.")},u.useCallback=function(e,t){return _.current.useCallback(e,t)},u.useContext=function(e){return _.current.useContext(e)},u.useDebugValue=function(){},u.useDeferredValue=function(e){return _.current.useDeferredValue(e)},u.useEffect=function(e,t){return _.current.useEffect(e,t)},u.useId=function(){return _.current.useId()},u.useImperativeHandle=function(e,t,i){return _.current.useImperativeHandle(e,t,i)},u.useInsertionEffect=function(e,t){return _.current.useInsertionEffect(e,t)},u.useLayoutEffect=function(e,t){return _.current.useLayoutEffect(e,t)},u.useMemo=function(e,t){return _.current.useMemo(e,t)},u.useReducer=function(e,t,i){return _.current.useReducer(e,t,i)},u.useRef=function(e){return _.current.useRef(e)},u.useState=function(e){return _.current.useState(e)},u.useSyncExternalStore=function(e,t,i){return _.current.useSyncExternalStore(e,t,i)},u.useTransition=function(){return _.current.useTransition()},u.version="18.2.0",u}();var h,p=(h=d.exports)&&h.__esModule&&Object.prototype.hasOwnProperty.call(h,"default")?h.default:h,g=(0,n.Z)({stackVertical:{display:"flex",flexDirection:"column"},stackHorizontal:{display:"flex",flexDirection:"row",alignItems:"center"},stackGrid:{display:"grid"},stackAlignmentVerticalStart:{alignItems:"flex-start"},stackAlignmentVerticalCenter:{alignItems:"center"},stackAlignmentVerticalEnd:{alignItems:"flex-end"},stackAlignmentHorizontalStart:{justifyContent:"flex-start"},stackAlignmentHorizontalCenter:{justifyContent:"center"},stackAlignmentHorizontalSpaceBetween:{justifyContent:"space-between"},stackAlignmentHorizontalEnd:{justifyContent:"flex-end"},stackHorizontalGapNone:{columnGap:"0px"},stackHorizontalGapXXSmall:{columnGap:o.T.spacingHorizontalXXS},stackHorizontalGapXSmall:{columnGap:o.T.spacingHorizontalXS},stackHorizontalGapSmall:{columnGap:o.T.spacingHorizontalS},stackHorizontalGapMedium:{columnGap:o.T.spacingHorizontalM},stackHorizontalGapLarge:{columnGap:o.T.spacingHorizontalL},stackHorizontalGapXLarge:{columnGap:o.T.spacingHorizontalXL},stackVerticalGapNone:{columnGap:"0px"},stackVerticalGapXXSmall:{rowGap:o.T.spacingVerticalXXS},stackVerticalGapXSmall:{rowGap:o.T.spacingVerticalXS},stackVerticalGapSmall:{rowGap:o.T.spacingVerticalS},stackVerticalGapMedium:{rowGap:o.T.spacingVerticalM},stackVerticalGapLarge:{rowGap:o.T.spacingVerticalL},stackVerticalGapXLarge:{rowGap:o.T.spacingVerticalXL},stackAlignmentGridStart:{justifyItems:"start"},stackAlignmentGridCenter:{justifyItems:"center"},stackAlignmentGridEnd:{justifyItems:"end"},stackAlignmentGridSpaceBetween:{justifyItems:"stretch"},stackGridGapNone:{columnGap:"0px",rowGap:"0px"},stackGridGapXXSmall:{rowGap:o.T.spacingHorizontalXXS,columnGap:o.T.spacingVerticalXXS},stackGridGapXSmall:{rowGap:o.T.spacingHorizontalXS,columnGap:o.T.spacingVerticalXS},stackGridGapSmall:{rowGap:o.T.spacingHorizontalS,columnGap:o.T.spacingVerticalS},stackGridGapMedium:{rowGap:o.T.spacingHorizontalM,columnGap:o.T.spacingVerticalM},stackGridGapLarge:{rowGap:o.T.spacingHorizontalL,columnGap:o.T.spacingVerticalL},stackGridGapXLarge:{rowGap:o.T.spacingHorizontalXL,columnGap:o.T.spacingVerticalXL}});function f(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function m(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?f(Object(i),!0).forEach((function(t){var n,o,r;n=e,o=t,r=i[t],(o=l(o))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):f(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var v=function(e){var t,i,n=e.children,o=e.direction,a=e.spacing,s=e.alignment,l=e.style,c=e.gridColumns,d=e.columnWidth,u=e.block,h=g(),f=m(m({},l),{},{width:u?"100%":"auto",gridTemplateColumns:0===c?"repeat(auto-fill, minmax(".concat(d,"px, 1fr))"):"repeat(".concat(c,", 1fr)")}),v=new Map([["horizontal",h.stackHorizontal],["vertical",h.stackVertical],["grid",h.stackGrid]]),y=new Map([["none",h.stackHorizontalGapNone],["xx-small",h.stackHorizontalGapXXSmall],["x-small",h.stackHorizontalGapXSmall],["small",h.stackHorizontalGapSmall],["medium",h.stackHorizontalGapMedium],["large",h.stackHorizontalGapLarge],["x-large",h.stackHorizontalGapXLarge]]),C=new Map([["none",h.stackVerticalGapNone],["xx-small",h.stackVerticalGapXXSmall],["x-small",h.stackVerticalGapXSmall],["small",h.stackVerticalGapSmall],["medium",h.stackVerticalGapMedium],["large",h.stackVerticalGapLarge],["x-large",h.stackVerticalGapXLarge]]),b=new Map([["none",h.stackGridGapNone],["xx-small",h.stackGridGapXXSmall],["x-small",h.stackGridGapXSmall],["small",h.stackGridGapSmall],["medium",h.stackGridGapMedium],["large",h.stackGridGapLarge],["x-large",h.stackGridGapXLarge]]),S=new Map([["start",h.stackAlignmentVerticalStart],["center",h.stackAlignmentVerticalCenter],["end",h.stackAlignmentVerticalEnd]]),x=new Map([["start",h.stackAlignmentHorizontalStart],["center",h.stackAlignmentHorizontalCenter],["space-between",h.stackAlignmentHorizontalSpaceBetween],["end",h.stackAlignmentHorizontalEnd]]),T=new Map([["start",h.stackAlignmentGridStart],["center",h.stackAlignmentGridCenter],["space-between",h.stackAlignmentGridSpaceBetween],["end",h.stackAlignmentGridEnd]]);switch(o){case"horizontal":t=y.get(a),i=x.get(s);break;case"vertical":t=C.get(a),i=S.get(s);break;case"grid":t=b.get(a),i=T.get(s)}var w=(0,r.z)(v.get(o),t,i);return p.createElement("div",{className:w,style:f},n)};v.defaultProps={direction:"horizontal",block:!1,spacing:"x-small",alignment:"start",gridColumns:1,columnWidth:1};var y=(0,n.Z)({default:{}}),C=function(e){var t=e.children,i=e.type,n=e.style,o=y(),s=(0,a.useSharedStyles)(),l=new Map([["default",o.default],["surface",s.surfacePanel]]),c=(0,r.z)(l.get(i));return p.createElement("div",{className:c,style:n&&n},t)};C.defaultProps={type:"default"}},37116:function(e,t,i){"use strict";i.r(t),i.d(t,{PriceActivity:function(){return Kt}});var n=i(8559),o=i(1598),r=i(94183),a=i(74551);const s=(0,r.s)({root:{mc9l5x:"f1w7gpdv",Bg96gwp:"fez10in",ycbfsm:"fg4l7m0"},rtl:{Bz10aip:"f13rod7r"}},{d:[".f1w7gpdv{display:inline;}",".fez10in{line-height:0;}",".f13rod7r{-webkit-transform:scaleX(-1);-moz-transform:scaleX(-1);-ms-transform:scaleX(-1);transform:scaleX(-1);}"],t:["@media (forced-colors: active){.fg4l7m0{forced-color-adjust:auto;}}"]}),l=(e,t)=>{const{title:i,primaryFill:n="currentColor",...r}=e,l={...r,title:void 0,fill:n},c=s(),d=(0,o.a)();return l.className=(0,a.z)(c.root,(null==t?void 0:t.flipInRtl)&&"rtl"===(null==d?void 0:d.textDirection)&&c.rtl,l.className),i&&(l["aria-label"]=i),l["aria-label"]||l["aria-labelledby"]?l.role="img":l["aria-hidden"]=!0,l},c=(e,t,i,o)=>{const r="1em"===t?"20":t,a=n.forwardRef(((e,a)=>{const s={...l(e,{flipInRtl:null==o?void 0:o.flipInRtl}),ref:a,width:t,height:t,viewBox:`0 0 ${r} ${r}`,xmlns:"http://www.w3.org/2000/svg"};return n.createElement("svg",s,...i.map((e=>n.createElement("path",{d:e,fill:s.fill}))))}));return a.displayName=e,a},d=c("ArrowCircleDown12Filled","12",["M11 6A5 5 0 1 1 1 6a5 5 0 0 1 10 0Zm-2.65.1a.5.5 0 0 0-.7 0L6.5 7.24V3.5a.5.5 0 0 0-1 0v3.74L4.35 6.1a.5.5 0 1 0-.7.7l2 2c.2.2.5.2.7 0l2-2a.5.5 0 0 0 0-.7Z"]),u=c("ArrowCircleDown16Filled","16",["M1 8a7 7 0 1 0 14 0A7 7 0 0 0 1 8Zm6.8 3.46a.5.5 0 0 1-.15-.1l-2.5-2.5a.5.5 0 1 1 .7-.71L7.5 9.79V5a.5.5 0 0 1 1 0v4.8l1.65-1.65a.5.5 0 0 1 .7.7l-2.5 2.5a.5.5 0 0 1-.54.11Z"]),h=c("ArrowCircleDown28Filled","28",["M14 2a12 12 0 1 0 0 24 12 12 0 0 0 0-24ZM8.97 14.22c.3-.3.77-.3 1.06 0l3.22 3.22V8.75a.75.75 0 0 1 1.5 0v8.69l3.22-3.22a.75.75 0 1 1 1.06 1.06l-4.5 4.5c-.3.3-.77.3-1.06 0l-4.5-4.5a.75.75 0 0 1 0-1.06Z"]),p=c("ArrowCircleRight12Filled","12",["M6 1a5 5 0 1 1 0 10A5 5 0 0 1 6 1Zm.1 2.65a.5.5 0 0 0 0 .7L7.24 5.5H3.5a.5.5 0 0 0 0 1h3.74L6.1 7.65a.5.5 0 1 0 .7.7l2-2a.5.5 0 0 0 0-.7l-2-2a.5.5 0 0 0-.7 0Z"]),g=c("ArrowCircleRight16Filled","16",["M8 15A7 7 0 1 0 8 1a7 7 0 0 0 0 14Zm3.46-6.8a.5.5 0 0 1-.1.15l-2.5 2.5a.5.5 0 0 1-.71-.7L9.79 8.5H5a.5.5 0 0 1 0-1h4.8L8.14 5.85a.5.5 0 1 1 .7-.7l2.5 2.5a.5.5 0 0 1 .11.54Z"]),f=c("ArrowCircleRight28Filled","28",["M2 14a12 12 0 1 1 24 0 12 12 0 0 1-24 0Zm12.22-5.03c-.3.3-.3.77 0 1.06l3.22 3.22H8.75a.75.75 0 0 0 0 1.5h8.69l-3.22 3.22a.75.75 0 1 0 1.06 1.06l4.5-4.5c.3-.3.3-.77 0-1.06l-4.5-4.5a.75.75 0 0 0-1.06 0Z"]),m=c("ArrowCircleUp12Filled","12",["M1 6a5 5 0 1 1 10 0A5 5 0 0 1 1 6Zm2.65-.1c.2.2.5.2.7 0L5.5 4.76V8.5a.5.5 0 0 0 1 0V4.76L7.65 5.9a.5.5 0 1 0 .7-.7l-2-2a.5.5 0 0 0-.7 0l-2 2a.5.5 0 0 0 0 .7Z"]),v=c("ArrowCircleUp16Filled","16",["M1 8a7 7 0 1 1 14 0A7 7 0 0 1 1 8Zm6.8-3.46a.5.5 0 0 0-.15.1l-2.5 2.5a.5.5 0 1 0 .7.71L7.5 6.21V11a.5.5 0 0 0 1 0V6.2l1.65 1.65a.5.5 0 0 0 .7-.7l-2.5-2.5a.5.5 0 0 0-.54-.11Z"]),y=c("ArrowCircleUp28Filled","28",["M14 26a12 12 0 1 1 0-24 12 12 0 0 1 0 24ZM8.97 13.78c.3.3.77.3 1.06 0l3.22-3.22v8.69a.75.75 0 0 0 1.5 0v-8.69l3.22 3.22a.75.75 0 1 0 1.06-1.06l-4.5-4.5a.75.75 0 0 0-1.06 0l-4.5 4.5c-.3.3-.3.77 0 1.06Z"]);var C,b=i(44323),S=i(84045),x=i(44956),T={exports:{}},w={};T.exports=function(){if(C)return w;C=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),r=Symbol.for("react.provider"),a=Symbol.for("react.context"),s=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),c=Symbol.for("react.memo"),d=Symbol.for("react.lazy"),u=Symbol.iterator,h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},p=Object.assign,g={};function f(e,t,i){this.props=e,this.context=t,this.refs=g,this.updater=i||h}function m(){}function v(e,t,i){this.props=e,this.context=t,this.refs=g,this.updater=i||h}f.prototype.isReactComponent={},f.prototype.setState=function(e,t){if("object"!=typeof e&&"function"!=typeof e&&null!=e)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")},f.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},m.prototype=f.prototype;var y=v.prototype=new m;y.constructor=v,p(y,f.prototype),y.isPureReactComponent=!0;var b=Array.isArray,S=Object.prototype.hasOwnProperty,x={current:null},T={key:!0,ref:!0,__self:!0,__source:!0};function O(t,i,n){var o,r={},a=null,s=null;if(null!=i)for(o in void 0!==i.ref&&(s=i.ref),void 0!==i.key&&(a=""+i.key),i)S.call(i,o)&&!T.hasOwnProperty(o)&&(r[o]=i[o]);var l=arguments.length-2;if(1===l)r.children=n;else if(1<l){for(var c=Array(l),d=0;d<l;d++)c[d]=arguments[d+2];r.children=c}if(t&&t.defaultProps)for(o in l=t.defaultProps)void 0===r[o]&&(r[o]=l[o]);return{$$typeof:e,type:t,key:a,ref:s,props:r,_owner:x.current}}function P(t){return"object"==typeof t&&null!==t&&t.$$typeof===e}var A=/\/+/g;function E(e,t){return"object"==typeof e&&null!==e&&null!=e.key?function(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,(function(e){return t[e]}))}(""+e.key):t.toString(36)}function k(i,n,o,r,a){var s=typeof i;"undefined"!==s&&"boolean"!==s||(i=null);var l=!1;if(null===i)l=!0;else switch(s){case"string":case"number":l=!0;break;case"object":switch(i.$$typeof){case e:case t:l=!0}}if(l)return a=a(l=i),i=""===r?"."+E(l,0):r,b(a)?(o="",null!=i&&(o=i.replace(A,"$&/")+"/"),k(a,n,o,"",(function(e){return e}))):null!=a&&(P(a)&&(a=function(t,i){return{$$typeof:e,type:t.type,key:i,ref:t.ref,props:t.props,_owner:t._owner}}(a,o+(!a.key||l&&l.key===a.key?"":(""+a.key).replace(A,"$&/")+"/")+i)),n.push(a)),1;if(l=0,r=""===r?".":r+":",b(i))for(var c=0;c<i.length;c++){var d=r+E(s=i[c],c);l+=k(s,n,o,d,a)}else if(d=function(e){return null===e||"object"!=typeof e?null:"function"==typeof(e=u&&e[u]||e["@@iterator"])?e:null}(i),"function"==typeof d)for(i=d.call(i),c=0;!(s=i.next()).done;)l+=k(s=s.value,n,o,d=r+E(s,c++),a);else if("object"===s)throw n=String(i),Error("Objects are not valid as a React child (found: "+("[object Object]"===n?"object with keys {"+Object.keys(i).join(", ")+"}":n)+"). If you meant to render a collection of children, use an array instead.");return l}function I(e,t,i){if(null==e)return e;var n=[],o=0;return k(e,n,"","",(function(e){return t.call(i,e,o++)})),n}function D(e){if(-1===e._status){var t=e._result;(t=t()).then((function(t){0!==e._status&&-1!==e._status||(e._status=1,e._result=t)}),(function(t){0!==e._status&&-1!==e._status||(e._status=2,e._result=t)})),-1===e._status&&(e._status=0,e._result=t)}if(1===e._status)return e._result.default;throw e._result}var _={current:null},N={transition:null},R={ReactCurrentDispatcher:_,ReactCurrentBatchConfig:N,ReactCurrentOwner:x};return w.Children={map:I,forEach:function(e,t,i){I(e,(function(){t.apply(this,arguments)}),i)},count:function(e){var t=0;return I(e,(function(){t++})),t},toArray:function(e){return I(e,(function(e){return e}))||[]},only:function(e){if(!P(e))throw Error("React.Children.only expected to receive a single React element child.");return e}},w.Component=f,w.Fragment=i,w.Profiler=o,w.PureComponent=v,w.StrictMode=n,w.Suspense=l,w.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=R,w.cloneElement=function(t,i,n){if(null==t)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+t+".");var o=p({},t.props),r=t.key,a=t.ref,s=t._owner;if(null!=i){if(void 0!==i.ref&&(a=i.ref,s=x.current),void 0!==i.key&&(r=""+i.key),t.type&&t.type.defaultProps)var l=t.type.defaultProps;for(c in i)S.call(i,c)&&!T.hasOwnProperty(c)&&(o[c]=void 0===i[c]&&void 0!==l?l[c]:i[c])}var c=arguments.length-2;if(1===c)o.children=n;else if(1<c){l=Array(c);for(var d=0;d<c;d++)l[d]=arguments[d+2];o.children=l}return{$$typeof:e,type:t.type,key:r,ref:a,props:o,_owner:s}},w.createContext=function(e){return(e={$$typeof:a,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null}).Provider={$$typeof:r,_context:e},e.Consumer=e},w.createElement=O,w.createFactory=function(e){var t=O.bind(null,e);return t.type=e,t},w.createRef=function(){return{current:null}},w.forwardRef=function(e){return{$$typeof:s,render:e}},w.isValidElement=P,w.lazy=function(e){return{$$typeof:d,_payload:{_status:-1,_result:e},_init:D}},w.memo=function(e,t){return{$$typeof:c,type:e,compare:void 0===t?null:t}},w.startTransition=function(e){var t=N.transition;N.transition={};try{e()}finally{N.transition=t}},w.unstable_act=function(){throw Error("act(...) is not supported in production builds of React.")},w.useCallback=function(e,t){return _.current.useCallback(e,t)},w.useContext=function(e){return _.current.useContext(e)},w.useDebugValue=function(){},w.useDeferredValue=function(e){return _.current.useDeferredValue(e)},w.useEffect=function(e,t){return _.current.useEffect(e,t)},w.useId=function(){return _.current.useId()},w.useImperativeHandle=function(e,t,i){return _.current.useImperativeHandle(e,t,i)},w.useInsertionEffect=function(e,t){return _.current.useInsertionEffect(e,t)},w.useLayoutEffect=function(e,t){return _.current.useLayoutEffect(e,t)},w.useMemo=function(e,t){return _.current.useMemo(e,t)},w.useReducer=function(e,t,i){return _.current.useReducer(e,t,i)},w.useRef=function(e){return _.current.useRef(e)},w.useState=function(e){return _.current.useState(e)},w.useSyncExternalStore=function(e,t,i){return _.current.useSyncExternalStore(e,t,i)},w.useTransition=function(){return _.current.useTransition()},w.version="18.2.0",w}();var O,P=(O=T.exports)&&O.__esModule&&Object.prototype.hasOwnProperty.call(O,"default")?O.default:O;function A(e){return A="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},A(e)}function E(e){var t=function(e,t){if("object"!==A(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==A(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===A(t)?t:String(t)}function k(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function I(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?k(Object(i),!0).forEach((function(t){var n,o,r;n=e,o=t,r=i[t],(o=E(o))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):k(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var D=(0,S.Z)({priceContainer:{display:"flex",width:"fit-content",flexDirection:"row",alignItems:"baseline",columnGap:"0px"},priceColorInherit:{color:"inherit"},priceXSmall:I(I({},x.w.caption2),{},{lineHeight:"unset"}),priceSmall:I(I({},x.w.caption1Strong),{},{lineHeight:"unset"}),priceMedium:I(I({},x.w.subtitle2),{},{lineHeight:"unset"}),priceLarge:I(I({},x.w.title2),{},{lineHeight:"unset"}),priceXLarge:I(I({},x.w.largeTitle),{},{lineHeight:"unset"}),currencySymbol:{},integer:{},decimal:{position:"absolute",opacity:"0"},fraction:{},raisedMedium:I({paddingTop:"1px",alignSelf:"flex-start"},x.w.caption2Strong),raisedLarge:I({marginTop:"-5px",alignSelf:"flex-start"},x.w.subtitle2),raisedXLarge:I({marginTop:"-11px",alignSelf:"flex-start"},x.w.title3),strikethrough:{textDecorationLine:"line-through"}}),_=function(e){var t,i,n,o=e.value,r=e.locale,s=e.currency,l=e.showCurrency,c=e.showRaisedCents,d=e.showCents,u=e.strikethrough,h=e.color,p=e.size,g=e.style,f=D(),m=(0,b.useSharedColors)(),v=new Map([["inherit",f.priceColorInherit],["normal",m.priceNormal],["accent-primary",m.priceAccentPrimary],["accent-secondary",m.priceAccentSecondary],["subtle",m.priceSubtle],["inverted",m.priceInverted]]),y=new Map([["x-small",f.priceXSmall],["small",f.priceSmall],["medium",f.priceMedium],["large",f.priceLarge],["x-large",f.priceXLarge]]),C=new Map([["medium",f.raisedMedium],["large",f.raisedLarge],["x-large",f.raisedXLarge]]),S=Intl.NumberFormat(r,{currency:s,style:"currency"}).formatToParts(o),x="";S.forEach((function(e){"integer"!==e.type&&"group"!==e.type||(x=x.concat(e.value))}));var T=(null===(t=S.find((function(e){return"currency"===e.type})))||void 0===t?void 0:t.value)||s,w=x,O=(null===(i=S.find((function(e){return"decimal"===e.type})))||void 0===i?void 0:i.value)||".",A=(null===(n=S.find((function(e){return"fraction"===e.type})))||void 0===n?void 0:n.value)||"00",E=(0,a.z)(f.priceContainer,p&&y.get(p),h&&v.get(h),f[u?"strikethrough":""]),k=c&&"small"!==p&&"x-small"!==p?(0,a.z)(f.currencySymbol,p&&C.get(p)):f.currencySymbol,I=c&&"small"!==p&&"x-small"!==p?(0,a.z)(f.decimal):f.currencySymbol,_="00"!==A;return P.createElement("div",{"data-testid":"price-container",className:E,style:g&&g},l&&P.createElement("div",{"data-testid":"price-currency",className:k},T),P.createElement("div",{"data-testid":"price-integer"},w),d&&_&&P.createElement(P.Fragment,null,P.createElement("div",{"data-testid":"price-decimal",className:I},O),P.createElement("div",{"data-testid":"price-fraction",className:k},A)))};_.defaultProps={color:"inherit",currency:"USD",locale:"en-US",showCents:!0,showCurrency:!0,showRaisedCents:!0,size:"medium",strikethrough:!1};var N=i(61492),R=i(64821),M=i(94270),L=i(58092),B=i(54194);const F=(0,r.s)({root:{Bahqtrf:"fk6fouc",sj55zd:"f19n0e5"},disabled:{sj55zd:"f1s2aq7o"},required:{sj55zd:"f1whyuy6",uwmqm3:["fycuoez","f8wuabp"]},requiredDisabled:{sj55zd:"f1s2aq7o"},small:{Be2twd7:"fy9rknc",Bg96gwp:"fwrc4pm"},medium:{Be2twd7:"fkhj508",Bg96gwp:"f1i3iumi"},large:{Be2twd7:"fod5ikn",Bg96gwp:"faaz57k",Bhrd7zp:"fl43uef"},semibold:{Bhrd7zp:"fl43uef"}},{d:[".fk6fouc{font-family:var(--fontFamilyBase);}",".f19n0e5{color:var(--colorNeutralForeground1);}",".f1s2aq7o{color:var(--colorNeutralForegroundDisabled);}",".f1whyuy6{color:var(--colorPaletteRedForeground3);}",".fycuoez{padding-left:4px;}",".f8wuabp{padding-right:4px;}",".fy9rknc{font-size:var(--fontSizeBase200);}",".fwrc4pm{line-height:var(--lineHeightBase200);}",".fkhj508{font-size:var(--fontSizeBase300);}",".f1i3iumi{line-height:var(--lineHeightBase300);}",".fod5ikn{font-size:var(--fontSizeBase400);}",".faaz57k{line-height:var(--lineHeightBase400);}",".fl43uef{font-weight:var(--fontWeightSemibold);}"]});var U=i(44906);const H=n.forwardRef(((e,t)=>{const i=((e,t)=>{const{disabled:i=!1,required:n=!1,weight:o="regular",size:r="medium"}=e;return{disabled:i,required:L.jt(!0===n?"*":n||void 0,{defaultProps:{"aria-hidden":"true"},elementType:"span"}),weight:o,size:r,components:{root:"label",required:"span"},root:L.Bx((0,B.h)("label",{ref:t,...e}),{elementType:"label"})}})(e,t);return(e=>{const t=F();e.root.className=(0,a.z)("fui-Label",t.root,e.disabled&&t.disabled,t[e.size],"semibold"===e.weight&&t.semibold,e.root.className),e.required&&(e.required.className=(0,a.z)("fui-Label__required",t.required,e.disabled&&t.requiredDisabled,e.required.className))})(i),(0,U.oj)("useLabelStyles_unstable")(i),(e=>((0,M.a)(e),(0,R.BX)(e.root,{children:[e.root.children,e.required&&(0,R.tZ)(e.required,{})]})))(i)}));H.displayName="Label";var $=i(29924),Z=i(32384),V=i(70617),G=i(48628),j=i(32535),z=i(82142),W=i(77793);const K="data-tabster",q="data-tabster-dummy",Y="tabster:modalizer:active",X="tabster:modalizer:inactive",J="tabster:focusin",Q="tabster:focusout",ee={Source:0,Target:1},te={Auto:0,Inside:1,Outside:2};var ie=Object.freeze({__proto__:null,TabsterAttributeName:K,TabsterDummyInputAttributeName:q,DeloserEventName:"tabster:deloser",ModalizerActiveEventName:Y,ModalizerInactiveEventName:X,ModalizerFocusInEventName:"tabster:modalizer:focusin",ModalizerFocusOutEventName:"tabster:modalizer:focusout",ModalizerBeforeFocusOutEventName:"tabster:modalizer:beforefocusout",MoverEventName:"tabster:mover",FocusInEventName:J,FocusOutEventName:Q,ObservedElementAccesibilities:{Any:0,Accessible:1,Focusable:2},RestoreFocusOrders:{History:0,DeloserDefault:1,RootDefault:2,DeloserFirst:3,RootFirst:4},Visibilities:{Invisible:0,PartiallyVisible:1,Visible:2},RestorerTypes:ee,MoverDirections:{Both:0,Vertical:1,Horizontal:2,Grid:3,GridLinear:4},GroupperTabbabilities:{Unlimited:0,Limited:1,LimitedTrapFocus:2},SysDummyInputsPositions:te});function ne(e,t){var i;return null===(i=e.storageEntry(t))||void 0===i?void 0:i.tabster}function oe(e,t,i){var n,o;const r=i||e._noop?void 0:t.getAttribute(K);let a,s=e.storageEntry(t);if(r){if(r===(null===(n=null==s?void 0:s.attr)||void 0===n?void 0:n.string))return;try{const e=JSON.parse(r);if("object"!=typeof e)throw new Error(`Value is not a JSON object, got '${r}'.`);a={string:r,object:e}}catch(e){}}else if(!s)return;s||(s=e.storageEntry(t,!0)),s.tabster||(s.tabster={});const l=s.tabster||{},c=(null===(o=s.attr)||void 0===o?void 0:o.object)||{},d=(null==a?void 0:a.object)||{};for(const i of Object.keys(c))if(!d[i]){if("root"===i){const t=l[i];t&&e.root.onRoot(t,!0)}switch(i){case"deloser":case"root":case"groupper":case"modalizer":case"restorer":case"mover":const n=l[i];n&&(n.dispose(),delete l[i]);break;case"observed":delete l[i],e.observedElement&&e.observedElement.onObservedElementUpdate(t);break;case"focusable":case"outline":case"uncontrolled":case"sys":delete l[i]}}for(const i of Object.keys(d)){const n=d.sys;switch(i){case"deloser":l.deloser?l.deloser.setProps(d.deloser):e.deloser&&(l.deloser=e.deloser.createDeloser(t,d.deloser));break;case"root":l.root?l.root.setProps(d.root):l.root=e.root.createRoot(t,d.root,n),e.root.onRoot(l.root);break;case"modalizer":l.modalizer?l.modalizer.setProps(d.modalizer):e.modalizer&&(l.modalizer=e.modalizer.createModalizer(t,d.modalizer,n));break;case"restorer":l.restorer?l.restorer.setProps(d.restorer):e.restorer&&d.restorer&&(l.restorer=e.restorer.createRestorer(t,d.restorer));break;case"focusable":l.focusable=d.focusable;break;case"groupper":l.groupper?l.groupper.setProps(d.groupper):e.groupper&&(l.groupper=e.groupper.createGroupper(t,d.groupper,n));break;case"mover":l.mover?l.mover.setProps(d.mover):e.mover&&(l.mover=e.mover.createMover(t,d.mover,n));break;case"observed":e.observedElement&&(l.observed=d.observed,e.observedElement.onObservedElementUpdate(t));break;case"uncontrolled":l.uncontrolled=d.uncontrolled;break;case"outline":e.outline&&(l.outline=d.outline);break;case"sys":l.sys=d.sys}}a?s.attr=a:(0===Object.keys(l).length&&(delete s.tabster,delete s.attr),e.storageEntry(t,!1))}let re;"undefined"!=typeof DOMRect&&DOMRect;let ae=0;try{document.createTreeWalker(document,NodeFilter.SHOW_ELEMENT),re=!1}catch(O){re=!0}function se(e){const t=e();let i=t.__tabsterInstanceContext;return i||(i={elementByUId:{},basics:{Promise:t.Promise||void 0,WeakRef:t.WeakRef||void 0},containerBoundingRectCache:{},lastContainerBoundingRectCacheId:0,fakeWeakRefs:[],fakeWeakRefsStarted:!1},t.__tabsterInstanceContext=i),i}class le{constructor(e){this._target=e}deref(){return this._target}static cleanup(e,t){return!e._target||!(!t&&me(e._target.ownerDocument,e._target))&&(delete e._target,!0)}}class ce{constructor(e,t,i){const n=se(e);let o;n.WeakRef?o=new n.WeakRef(t):(o=new le(t),n.fakeWeakRefs.push(o)),this._ref=o,this._data=i}get(){const e=this._ref;let t;return e&&(t=e.deref(),t||delete this._ref),t}getData(){return this._data}}function de(e,t){const i=se(e);i.fakeWeakRefs=i.fakeWeakRefs.filter((e=>!le.cleanup(e,t)))}function ue(e){const t=se(e);t.fakeWeakRefsStarted||(t.fakeWeakRefsStarted=!0,t.WeakRef=function(e){return e.basics.WeakRef}(t)),t.fakeWeakRefsTimer||(t.fakeWeakRefsTimer=e().setTimeout((()=>{t.fakeWeakRefsTimer=void 0,de(e),ue(e)}),12e4))}function he(e,t,i){if(t.nodeType!==Node.ELEMENT_NODE)return;const n=re?i:{acceptNode:i};return e.createTreeWalker(t,NodeFilter.SHOW_ELEMENT,n,!1)}function pe(e){return!!e.__shouldIgnoreFocus}function ge(e,t){const i=se(e);let n=t.__tabsterElementUID;return n||(n=t.__tabsterElementUID=function(e){const t=new Uint32Array(4);if(e.crypto&&e.crypto.getRandomValues)e.crypto.getRandomValues(t);else if(e.msCrypto&&e.msCrypto.getRandomValues)e.msCrypto.getRandomValues(t);else for(let e=0;e<t.length;e++)t[e]=4294967295*Math.random();const i=[];for(let e=0;e<t.length;e++)i.push(t[e].toString(36));return i.push("|"),i.push((++ae).toString(36)),i.push("|"),i.push(Date.now().toString(36)),i.join("")}(e())),!i.elementByUId[n]&&me(t.ownerDocument,t)&&(i.elementByUId[n]=new ce(e,t)),n}function fe(e,t){const i=se(e);for(const e of Object.keys(i.elementByUId)){const n=i.elementByUId[e],o=n&&n.get();o&&t&&!t.contains(o)||delete i.elementByUId[e]}}function me(e,t){var i;return!!(null===(i=null==e?void 0:e.body)||void 0===i?void 0:i.contains(t))}let ve=0;class ye{constructor(e,t,i){const n=e.getWindow;this._tabster=e,this._element=new ce(n,t),this._props={...i},this.id="i"+ ++ve}getElement(){return this._element.get()}getProps(){return this._props}setProps(e){this._props={...e}}}class Ce{constructor(e,t,i,n){var o;this._focusIn=e=>{const t=this.input;if(this.onFocusIn&&t){const i=be.getLastPhantomFrom()||e.relatedTarget;this.onFocusIn(this,this._isBackward(!0,t,i),i)}},this._focusOut=e=>{this.useDefaultAction=!1;const t=this.input;if(this.onFocusOut&&t){const i=e.relatedTarget;this.onFocusOut(this,this._isBackward(!1,t,i),i)}};const r=e(),a=r.document.createElement("i");a.tabIndex=0,a.setAttribute("role","none"),a.setAttribute(q,""),a.setAttribute("aria-hidden","true");const s=a.style;s.position="fixed",s.width=s.height="1px",s.opacity="0.001",s.zIndex="-1",s.setProperty("content-visibility","hidden"),function(e){e.__shouldIgnoreFocus=!0}(a),this.input=a,this.isFirst=i.isFirst,this.isOutside=t,this._isPhantom=null!==(o=i.isPhantom)&&void 0!==o&&o,a.addEventListener("focusin",this._focusIn),a.addEventListener("focusout",this._focusOut),a.__tabsterDummyContainer=n,this._isPhantom&&(this._disposeTimer=r.setTimeout((()=>{delete this._disposeTimer,this.dispose()}),0),this._clearDisposeTimeout=()=>{this._disposeTimer&&(r.clearTimeout(this._disposeTimer),delete this._disposeTimer),delete this._clearDisposeTimeout})}dispose(){var e;this._clearDisposeTimeout&&this._clearDisposeTimeout();const t=this.input;t&&(delete this.onFocusIn,delete this.onFocusOut,delete this.input,t.removeEventListener("focusin",this._focusIn),t.removeEventListener("focusout",this._focusOut),delete t.__tabsterDummyContainer,null===(e=t.parentElement)||void 0===e||e.removeChild(t))}setTopLeft(e,t){var i;const n=null===(i=this.input)||void 0===i?void 0:i.style;n&&(n.top=`${e}px`,n.left=`${t}px`)}_isBackward(e,t,i){return e&&!i?!this.isFirst:!!(i&&t.compareDocumentPosition(i)&Node.DOCUMENT_POSITION_FOLLOWING)}}class be{constructor(e,t,i,n,o,r){this._element=t,this._instance=new xe(e,t,this,i,n,o,r)}_setHandlers(e,t){this._onFocusIn=e,this._onFocusOut=t}moveOut(e){var t;null===(t=this._instance)||void 0===t||t.moveOut(e)}moveOutWithDefaultAction(e){var t;null===(t=this._instance)||void 0===t||t.moveOutWithDefaultAction(e)}getHandler(e){return e?this._onFocusIn:this._onFocusOut}setTabbable(e){var t;null===(t=this._instance)||void 0===t||t.setTabbable(this,e)}dispose(){this._instance&&(this._instance.dispose(this),delete this._instance),delete this._onFocusIn,delete this._onFocusOut}static getLastPhantomFrom(){const e=be._lastPhantomFrom;return delete be._lastPhantomFrom,e}static moveWithPhantomDummy(e,t,i,n){const o=new Ce(e.getWindow,!0,{isPhantom:!0,isFirst:!0}).input;if(o){const r=t.parentElement;if(r){let a=i&&!n||!i&&n?t.nextElementSibling:t;if(a)if(n){const e=a.previousElementSibling;e&&e.__tabsterDummyContainer&&(a=e)}else a.__tabsterDummyContainer&&(a=a.nextElementSibling);r.insertBefore(o,a),be._lastPhantomFrom=t,e.getWindow().setTimeout((()=>{delete be._lastPhantomFrom}),0),(0,W.ev)(o)}}}}class Se{constructor(e){this._updateQueue=new Set,this._lastUpdateQueueTime=0,this._changedParents=new WeakSet,this._dummyElements=[],this._dummyCallbacks=new WeakMap,this._domChanged=e=>{var t;this._changedParents.has(e)||(this._changedParents.add(e),this._updateDummyInputsTimer||(this._updateDummyInputsTimer=null===(t=this._win)||void 0===t?void 0:t.call(this).setTimeout((()=>{delete this._updateDummyInputsTimer;for(const e of this._dummyElements){const t=e.deref();if(t){const e=this._dummyCallbacks.get(t);if(e){const i=t.parentElement;i&&!this._changedParents.has(i)||e()}}}this._changedParents=new WeakSet}),100)))},this._win=e}add(e,t){this._dummyCallbacks.has(e)||(this._dummyElements.push(new WeakRef(e)),this._dummyCallbacks.set(e,t),this.domChanged=this._domChanged)}remove(e){this._dummyElements=this._dummyElements.filter((t=>{const i=t.deref();return i&&i!==e})),this._dummyCallbacks.delete(e),0===this._dummyElements.length&&delete this.domChanged}dispose(){var e;const t=null===(e=this._win)||void 0===e?void 0:e.call(this);this._updateTimer&&(null==t||t.clearTimeout(this._updateTimer),delete this._updateTimer),this._updateDummyInputsTimer&&(null==t||t.clearTimeout(this._updateDummyInputsTimer),delete this._updateDummyInputsTimer),this._changedParents=new WeakSet,this._dummyCallbacks=new WeakMap,this._dummyElements=[],this._updateQueue.clear(),delete this.domChanged,delete this._win}updatePositions(e){this._win&&(this._updateQueue.add(e),this._lastUpdateQueueTime=Date.now(),this._scheduledUpdatePositions())}_scheduledUpdatePositions(){var e;this._updateTimer||(this._updateTimer=null===(e=this._win)||void 0===e?void 0:e.call(this).setTimeout((()=>{if(delete this._updateTimer,this._lastUpdateQueueTime+100<=Date.now()){const e=new Map,t=[];for(const i of this._updateQueue)t.push(i(e));this._updateQueue.clear();for(const e of t)e();e.clear()}else this._scheduledUpdatePositions()}),100))}}class xe{constructor(e,t,i,n,o,r,a){this._wrappers=[],this._isOutside=!1,this._transformElements=new Set,this._onFocusIn=(e,t,i)=>{this._onFocus(!0,e,t,i)},this._onFocusOut=(e,t,i)=>{this._onFocus(!1,e,t,i)},this.moveOut=e=>{var t;const i=this._firstDummy,n=this._lastDummy;if(i&&n){this._ensurePosition();const o=i.input,r=n.input,a=null===(t=this._element)||void 0===t?void 0:t.get();if(o&&r&&a){let t;e?(o.tabIndex=0,t=o):(r.tabIndex=0,t=r),t&&(0,W.ev)(t)}}},this.moveOutWithDefaultAction=e=>{var t;const i=this._firstDummy,n=this._lastDummy;if(i&&n){this._ensurePosition();const o=i.input,r=n.input,a=null===(t=this._element)||void 0===t?void 0:t.get();if(o&&r&&a){let t;e?!i.isOutside&&this._tabster.focusable.isFocusable(a,!0,!0,!0)?t=a:(i.useDefaultAction=!0,o.tabIndex=0,t=o):(n.useDefaultAction=!0,r.tabIndex=0,t=r),t&&(0,W.ev)(t)}}},this.setTabbable=(e,t)=>{var i,n;for(const i of this._wrappers)if(i.manager===e){i.tabbable=t;break}const o=this._getCurrent();if(o){const e=o.tabbable?0:-1;let t=null===(i=this._firstDummy)||void 0===i?void 0:i.input;t&&(t.tabIndex=e),t=null===(n=this._lastDummy)||void 0===n?void 0:n.input,t&&(t.tabIndex=e)}},this._addDummyInputs=()=>{this._addTimer||(this._addTimer=this._getWindow().setTimeout((()=>{delete this._addTimer,this._ensurePosition(),this._addTransformOffsets()}),0))},this._addTransformOffsets=()=>{this._tabster._dummyObserver.updatePositions(this._computeTransformOffsets)},this._computeTransformOffsets=e=>{var t,i;const n=(null===(t=this._firstDummy)||void 0===t?void 0:t.input)||(null===(i=this._lastDummy)||void 0===i?void 0:i.input),o=this._transformElements,r=new Set;let a=0,s=0;const l=this._getWindow();for(let t=n;t&&t.nodeType===Node.ELEMENT_NODE;t=t.parentElement){let i=e.get(t);if(void 0===i){const n=l.getComputedStyle(t).transform;n&&"none"!==n&&(i={scrollTop:t.scrollTop,scrollLeft:t.scrollLeft}),e.set(t,i||null)}i&&(r.add(t),o.has(t)||t.addEventListener("scroll",this._addTransformOffsets),a+=i.scrollTop,s+=i.scrollLeft)}for(const e of o)r.has(e)||e.removeEventListener("scroll",this._addTransformOffsets);return this._transformElements=r,()=>{var e,t;null===(e=this._firstDummy)||void 0===e||e.setTopLeft(a,s),null===(t=this._lastDummy)||void 0===t||t.setTopLeft(a,s)}};const s=t.get();if(!s)throw new Error("No element");this._tabster=e,this._getWindow=e.getWindow,this._callForDefaultAction=a;const l=s.__tabsterDummy;if((l||this)._wrappers.push({manager:i,priority:n,tabbable:!0}),l)return l;s.__tabsterDummy=this;const c=null==o?void 0:o.dummyInputsPosition,d=s.tagName;this._isOutside=c?c===te.Outside:(r||"UL"===d||"OL"===d||"TABLE"===d)&&!("LI"===d||"TD"===d||"TH"===d),this._firstDummy=new Ce(this._getWindow,this._isOutside,{isFirst:!0},t),this._lastDummy=new Ce(this._getWindow,this._isOutside,{isFirst:!1},t);const u=this._firstDummy.input;u&&e._dummyObserver.add(u,this._addDummyInputs),this._firstDummy.onFocusIn=this._onFocusIn,this._firstDummy.onFocusOut=this._onFocusOut,this._lastDummy.onFocusIn=this._onFocusIn,this._lastDummy.onFocusOut=this._onFocusOut,this._element=t,this._addDummyInputs()}dispose(e,t){var i,n,o,r;if(0===(this._wrappers=this._wrappers.filter((i=>i.manager!==e&&!t))).length){delete(null===(i=this._element)||void 0===i?void 0:i.get()).__tabsterDummy;for(const e of this._transformElements)e.removeEventListener("scroll",this._addTransformOffsets);this._transformElements.clear();const e=this._getWindow();this._addTimer&&(e.clearTimeout(this._addTimer),delete this._addTimer);const t=null===(n=this._firstDummy)||void 0===n?void 0:n.input;t&&this._tabster._dummyObserver.remove(t),null===(o=this._firstDummy)||void 0===o||o.dispose(),null===(r=this._lastDummy)||void 0===r||r.dispose()}}_onFocus(e,t,i,n){var o;const r=this._getCurrent();!r||t.useDefaultAction&&!this._callForDefaultAction||null===(o=r.manager.getHandler(e))||void 0===o||o(t,i,n)}_getCurrent(){return this._wrappers.sort(((e,t)=>e.tabbable!==t.tabbable?e.tabbable?-1:1:e.priority-t.priority)),this._wrappers[0]}_ensurePosition(){var e,t,i;const n=null===(e=this._element)||void 0===e?void 0:e.get(),o=null===(t=this._firstDummy)||void 0===t?void 0:t.input,r=null===(i=this._lastDummy)||void 0===i?void 0:i.input;if(n&&o&&r)if(this._isOutside){const e=n.parentElement;if(e){const t=n.nextElementSibling;t!==r&&e.insertBefore(r,t),n.previousElementSibling!==o&&e.insertBefore(o,n)}}else{n.lastElementChild!==r&&n.appendChild(r);const e=n.firstElementChild;e&&e!==o&&n.insertBefore(o,e)}}}function Te(e){let t=null;for(let i=e.lastElementChild;i;i=i.lastElementChild)t=i;return t||void 0}function we(e,t,i){const n=document.createEvent("HTMLEvents");return n.initEvent(t,!0,!0),n.details=i,e.dispatchEvent(n),!n.defaultPrevented}function Oe(e,t,i,n){const o=e.storageEntry(t,!0);let r=!1;if(!o.aug){if(void 0===n)return r;o.aug={}}if(void 0===n){if(i in o.aug){const e=o.aug[i];delete o.aug[i],null===e?t.removeAttribute(i):t.setAttribute(i,e),r=!0}}else{let e;i in o.aug||(e=t.getAttribute(i)),void 0!==e&&e!==n&&(o.aug[i]=e,null===n?t.removeAttribute(i):t.setAttribute(i,n),r=!0)}return void 0===n&&0===Object.keys(o.aug).length&&(delete o.aug,e.storageEntry(t,!1)),r}function Pe(e,t){const i=JSON.stringify(e);return!0===t?i:{[K]:i}}class Ae extends be{constructor(e,t,i,n){super(e,t,1,n,void 0,!0),this._onDummyInputFocus=e=>{var t;if(e.useDefaultAction)this._setFocused(!1,!0);else{this._tabster.keyboardNavigation.setNavigatingWithKeyboard(!0);const i=this._element.get();if(i){this._setFocused(!0,!0);const t=this._tabster.focusedElement.getFirstOrLastTabbable(e.isFirst,{container:i,ignoreAccessibility:!0});if(t)return void(0,W.ev)(t)}null===(t=e.input)||void 0===t||t.blur()}},this._setHandlers(this._onDummyInputFocus),this._tabster=e,this._setFocused=i}}class Ee extends ye{constructor(e,t,i,n,o){super(e,t,n),this._isFocused=!1,this._setFocused=(e,t)=>{if(this._setFocusedTimer&&(this._tabster.getWindow().clearTimeout(this._setFocusedTimer),delete this._setFocusedTimer),this._isFocused===e)return;const i=this._element.get();i&&(e?(this._isFocused=!0,we(this._tabster.root.eventTarget,"focus",{element:i,fromAdjacent:t})):this._setFocusedTimer=this._tabster.getWindow().setTimeout((()=>{delete this._setFocusedTimer,this._isFocused=!1,we(this._tabster.root.eventTarget,"blur",{element:i,fromAdjacent:t})}),0))},this._onFocus=e=>{var t;const i=this._tabster.getWindow();if(this._setTabbableTimer&&(i.clearTimeout(this._setTabbableTimer),delete this._setTabbableTimer),e){const i=ke.getTabsterContext(this._tabster,e);if(i&&this._setFocused(i.root.getElement()===this._element.get()),!i||i.uncontrolled||this._tabster.rootDummyInputs)return void(null===(t=this._dummyManager)||void 0===t||t.setTabbable(!1))}else this._setFocused(!1);this._setTabbableTimer=i.setTimeout((()=>{var e;delete this._setTabbableTimer,null===(e=this._dummyManager)||void 0===e||e.setTabbable(!0)}),0)},this._onDispose=i;const r=e.getWindow;this.uid=ge(r,t),this._sys=o,(e.controlTab||e.rootDummyInputs)&&this.addDummyInputs(),e.focusedElement.subscribe(this._onFocus),this._add()}addDummyInputs(){this._dummyManager||(this._dummyManager=new Ae(this._tabster,this._element,this._setFocused,this._sys))}dispose(){var e;this._onDispose(this);const t=this._tabster.getWindow();this._setFocusedTimer&&(t.clearTimeout(this._setFocusedTimer),delete this._setFocusedTimer),this._setTabbableTimer&&(t.clearTimeout(this._setTabbableTimer),delete this._setTabbableTimer),null===(e=this._dummyManager)||void 0===e||e.dispose(),this._remove()}moveOutWithDefaultAction(e){const t=this._dummyManager;if(t)t.moveOutWithDefaultAction(e);else{const t=this.getElement();t&&Ae.moveWithPhantomDummy(this._tabster,t,!0,e)}}_add(){}_remove(){}}class ke{constructor(e,t){this._autoRootWaiting=!1,this._roots={},this._forceDummy=!1,this.rootById={},this._autoRootCreate=()=>{var e;const t=this._win().document,i=t.body;if(i){this._autoRootUnwait(t);const n=this._autoRoot;if(n)return function(e,t,i){let n;if(i){const t=e.getAttribute(K);if(t)try{n=JSON.parse(t)}catch(e){}}n||(n={}),function(e,t){for(const i of Object.keys(t)){const n=t[i];n?e[i]=n:delete e[i]}}(n,t),Object.keys(n).length>0?e.setAttribute(K,Pe(n,!0)):e.removeAttribute(K)}(i,{root:n},!0),oe(this._tabster,i),null===(e=ne(this._tabster,i))||void 0===e?void 0:e.root}else this._autoRootWaiting||(this._autoRootWaiting=!0,t.addEventListener("readystatechange",this._autoRootCreate))},this._onRootDispose=e=>{delete this._roots[e.id]},this._tabster=e,this._win=e.getWindow,this._autoRoot=t,this.eventTarget=function(e){const t=e();try{if(t.EventTarget)return new t.EventTarget}catch(e){if(!(e instanceof TypeError))throw e}return t.document.createElement("div")}(this._win),e.queueInit((()=>{this._autoRoot&&this._autoRootCreate()}))}_autoRootUnwait(e){e.removeEventListener("readystatechange",this._autoRootCreate),this._autoRootWaiting=!1}dispose(){const e=this._win();this._autoRootUnwait(e.document),delete this._autoRoot,Object.keys(this._roots).forEach((e=>{this._roots[e]&&(this._roots[e].dispose(),delete this._roots[e])})),this.rootById={}}createRoot(e,t,i){const n=new Ee(this._tabster,e,this._onRootDispose,t,i);return this._roots[n.id]=n,this._forceDummy&&n.addDummyInputs(),n}addDummyInputs(){this._forceDummy=!0;const e=this._roots;for(const t of Object.keys(e))e[t].addDummyInputs()}static getRootByUId(e,t){const i=e().__tabsterInstance;return i&&i.root.rootById[t]}static getTabsterContext(e,t,i){var n,o,r,a;if(void 0===i&&(i={}),!t.ownerDocument)return;const{checkRtl:s,referenceElement:l}=i,c=e.getParent;let d,u,h,p;e.drainInitQueue();let g,f,m,v,y=!1,C=l||t;const b={};for(;C&&(!d||s);){const i=ne(e,C);if(s&&void 0===m){const e=C.dir;e&&(m="rtl"===e.toLowerCase())}if(!i){C=c(C);continue}const a=C.tagName;(i.uncontrolled||"IFRAME"===a||"WEBVIEW"===a)&&(v=C),p||!(null===(n=i.focusable)||void 0===n?void 0:n.excludeFromMover)||h||(y=!0);const l=i.modalizer,S=i.groupper,x=i.mover;!u&&l&&(u=l),h||!S||u&&!l||(u?(!S.isActive()&&S.getProps().tabbability&&u.userId!==(null===(o=e.modalizer)||void 0===o?void 0:o.activeId)&&(u=void 0,h=S),f=S):h=S),p||!x||u&&!l||S&&C===t||(p=x,g=!!h&&h!==S),i.root&&(d=i.root),(null===(r=i.focusable)||void 0===r?void 0:r.ignoreKeydown)&&Object.assign(b,i.focusable.ignoreKeydown),C=c(C)}if(!d){const i=e.root;i._autoRoot&&(null===(a=t.ownerDocument)||void 0===a?void 0:a.body)&&(d=i._autoRootCreate())}return h&&!p&&(g=!0),d?{root:d,modalizer:u,groupper:h,mover:p,isGroupperFirst:g,modalizerInGroupper:f,isRtl:s?!!m:void 0,uncontrolled:v,isExcludedFromMover:y,ignoreKeydown:e=>!!b[e.key]}:void 0}static getRoot(e,t){var i;for(let n=t;n;n=n.parentElement){const t=null===(i=ne(e,n))||void 0===i?void 0:i.root;if(t)return t}}onRoot(e,t){t?delete this.rootById[e.uid]:this.rootById[e.uid]=e}}class Ie{constructor(){this._callbacks=[]}dispose(){this._callbacks=[],delete this._val}subscribe(e){const t=this._callbacks;t.indexOf(e)<0&&t.push(e)}subscribeFirst(e){const t=this._callbacks,i=t.indexOf(e);i>=0&&t.splice(i,1),t.unshift(e)}unsubscribe(e){const t=this._callbacks.indexOf(e);t>=0&&this._callbacks.splice(t,1)}setVal(e,t){this._val!==e&&(this._val=e,this._callCallbacks(e,t))}getVal(){return this._val}trigger(e,t){this._callCallbacks(e,t)}_callCallbacks(e,t){this._callbacks.forEach((i=>i(e,t)))}}const De=["a[href]","button:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])","*[tabindex]","*[contenteditable]"].join(", ");class _e{constructor(e){this._tabster=e}dispose(){}getProps(e){const t=ne(this._tabster,e);return t&&t.focusable||{}}isFocusable(e,t,i,n){return!(!function(e,t){const i=e.matches||e.matchesSelector||e.msMatchesSelector||e.webkitMatchesSelector;return i&&i.call(e,t)}(e,De)||!t&&-1===e.tabIndex)&&(i||this.isVisible(e))&&(n||this.isAccessible(e))}isVisible(e){if(!e.ownerDocument||e.nodeType!==Node.ELEMENT_NODE)return!1;if(null===e.offsetParent&&e.ownerDocument.body!==e)return!1;const t=e.ownerDocument.defaultView;if(!t)return!1;const i=e.ownerDocument.body.getBoundingClientRect();return(0!==i.width||0!==i.height)&&"hidden"!==t.getComputedStyle(e).visibility}isAccessible(e){var t;for(let i=e;i;i=i.parentElement){const e=ne(this._tabster,i);if(this._isHidden(i))return!1;if(!(null===(t=null==e?void 0:e.focusable)||void 0===t?void 0:t.ignoreAriaDisabled)&&this._isDisabled(i))return!1}return!0}_isDisabled(e){return e.hasAttribute("disabled")}_isHidden(e){var t;const i=e.getAttribute("aria-hidden");return!(!i||"true"!==i.toLowerCase()||(null===(t=this._tabster.modalizer)||void 0===t?void 0:t.isAugmented(e)))}findFirst(e){return this.findElement({...e})}findLast(e){return this.findElement({isBackward:!0,...e})}findNext(e,t){return this.findElement({...e},t)}findPrev(e,t){return this.findElement({...e,isBackward:!0},t)}findDefault(e){return this.findElement({...e,acceptCondition:t=>this._tabster.focusable.isFocusable(t,e.includeProgrammaticallyFocusable)&&!!this.getProps(t).isDefault})||null}findAll(e){return this._findElements(!0,e)||[]}findElement(e,t){const i=this._findElements(!1,e,t);return i?i[0]:i}_findElements(e,t,i){var n,o,r;const{container:a,currentElement:s=null,includeProgrammaticallyFocusable:l,useActiveModalizer:c,ignoreUncontrolled:d,ignoreAccessibility:u,modalizerId:h,isBackward:p,onUncontrolled:g,onElement:f}=t;i||(i={});const m=[];let{acceptCondition:v}=t;if(!a)return null;v||(v=e=>this._tabster.focusable.isFocusable(e,l,!1,u));const y={container:a,modalizerUserId:void 0===h&&c?null===(n=this._tabster.modalizer)||void 0===n?void 0:n.activeId:h||(null===(r=null===(o=ke.getTabsterContext(this._tabster,a))||void 0===o?void 0:o.modalizer)||void 0===r?void 0:r.userId),from:s||a,isBackward:p,acceptCondition:v,includeProgrammaticallyFocusable:l,ignoreUncontrolled:d,ignoreAccessibility:u,cachedGrouppers:{}},C=he(a.ownerDocument,a,(e=>this._acceptElement(e,y)));if(!C)return null;const b=t=>{const i=y.foundElement;return i&&m.push(i),e?!(i&&(y.found=!1,delete y.foundElement,delete y.fromCtx,y.from=i,f&&!f(i))||!i&&!t):!(!t||i)};if(s||(i.outOfDOMOrder=!0),s)C.currentNode=s;else if(p){const e=Te(a);if(!e)return null;if(this._acceptElement(e,y)===NodeFilter.FILTER_ACCEPT&&!b(!0))return y.skippedFocusable&&(i.outOfDOMOrder=!0),m;C.currentNode=e}let S;do{S=(p?C.previousNode():C.nextNode())||void 0}while(b());if(!e){const e=y.nextUncontrolled;if(e)return g&&g(e),S?void 0:null}return y.skippedFocusable&&(i.outOfDOMOrder=!0),m.length?m:null}_acceptElement(e,t){var i,n,o,r,a;if(t.found)return NodeFilter.FILTER_ACCEPT;const s=t.container;if(e===s)return NodeFilter.FILTER_SKIP;if(!s.contains(e))return NodeFilter.FILTER_REJECT;if(e.__tabsterDummyContainer)return NodeFilter.FILTER_REJECT;let l=t.lastToIgnore;if(l){if(l.contains(e))return NodeFilter.FILTER_REJECT;l=t.lastToIgnore=void 0}const c=t.currentCtx=ke.getTabsterContext(this._tabster,e);if(!c)return NodeFilter.FILTER_SKIP;if(t.ignoreUncontrolled){if(pe(e))return NodeFilter.FILTER_SKIP}else if(c.uncontrolled&&!t.nextUncontrolled&&this._tabster.focusable.isFocusable(e,void 0,!0,!0)&&!c.groupper&&!c.mover&&(null===(i=c.modalizer)||void 0===i?void 0:i.userId)===(null===(n=this._tabster.modalizer)||void 0===n?void 0:n.activeId))return this.isVisible(c.uncontrolled)&&(t.nextUncontrolled=c.uncontrolled),t.skippedFocusable=!0,NodeFilter.FILTER_REJECT;if("IFRAME"===e.tagName||"WEBVIEW"===e.tagName)return(null===(o=c.modalizer)||void 0===o?void 0:o.userId)===(null===(r=this._tabster.modalizer)||void 0===r?void 0:r.activeId)?(t.found=!0,t.lastToIgnore=t.foundElement=e,NodeFilter.FILTER_ACCEPT):NodeFilter.FILTER_REJECT;if(!t.ignoreAccessibility&&!this.isAccessible(e))return this.isFocusable(e,!1,!0,!0)&&(t.skippedFocusable=!0),NodeFilter.FILTER_REJECT;let d,u=t.fromCtx;u||(u=t.fromCtx=ke.getTabsterContext(this._tabster,t.from));const h=null==u?void 0:u.mover;let p=c.groupper,g=c.mover;if(d=null===(a=this._tabster.modalizer)||void 0===a?void 0:a.acceptElement(e,t),void 0!==d&&(t.skippedFocusable=!0),void 0===d&&(p||g||h)){const i=null==p?void 0:p.getElement(),n=null==h?void 0:h.getElement();let o=null==g?void 0:g.getElement();o&&(null==n?void 0:n.contains(o))&&s.contains(n)&&(!i||!g||n.contains(i))&&(g=h,o=n),!i||i!==s&&s.contains(i)||(p=void 0),o&&!s.contains(o)&&(g=void 0),p&&g&&(o&&i&&!i.contains(o)?g=void 0:p=void 0),p&&(d=p.acceptElement(e,t)),g&&(d=g.acceptElement(e,t))}return void 0===d&&(d=t.acceptCondition(e)?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP,d===NodeFilter.FILTER_SKIP&&this.isFocusable(e,!1,!0,!0)&&(t.skippedFocusable=!0)),d!==NodeFilter.FILTER_ACCEPT||t.found||(t.found=!0,t.foundElement=e),d}}class Ne extends Ie{constructor(e,t){super(),this._init=()=>{const e=this._win(),t=e.document;t.addEventListener(W.PW,this._onFocusIn,!0),t.addEventListener("focusout",this._onFocusOut,!0),e.addEventListener("keydown",this._onKeyDown,!0);const i=t.activeElement;i&&i!==t.body&&this._setFocusedElement(i),this.subscribe(this._onChanged)},this._onFocusIn=e=>{this._setFocusedElement(e.target,e.details.relatedTarget,e.details.isFocusedProgrammatically)},this._onFocusOut=e=>{this._setFocusedElement(void 0,e.relatedTarget)},this._validateFocusedElement=e=>{},this._onKeyDown=e=>{var t,i;if(9!==e.keyCode||e.ctrlKey)return;const n=this.getVal();if(!n||!n.ownerDocument||"true"===n.contentEditable)return;const o=this._tabster,r=o.controlTab,a=ke.getTabsterContext(o,n);if(!a||a.ignoreKeydown(e))return;const s=e.shiftKey,l=Ne.findNextTabbable(o,a,void 0,n,void 0,s,void 0,!0);let c;if(l){let e=l.uncontrolled;if(e){const n=a.isGroupperFirst;let o=!1;if(void 0!==n){const r=null===(t=a.groupper)||void 0===t?void 0:t.getElement(),s=null===(i=a.mover)||void 0===i?void 0:i.getElement();let l;n&&r&&e.contains(r)?l=r:!n&&s&&e.contains(s)&&(l=s),l&&(e=l,o=!0)}return void(e&&a.uncontrolled!==e&&be.moveWithPhantomDummy(this._tabster,e,o,s))}c=l.element}if(c){if("IFRAME"===c.tagName)return void be.moveWithPhantomDummy(this._tabster,c,!1,s);(r||(null==l?void 0:l.outOfDOMOrder))&&(e.preventDefault(),e.stopImmediatePropagation(),(0,W.ev)(c))}else a.root.moveOutWithDefaultAction(s)},this._onChanged=(e,t)=>{var i,n;if(e)we(e,J,t);else{const e=null===(i=this._lastVal)||void 0===i?void 0:i.get();if(e){const i={...t},o=ke.getTabsterContext(this._tabster,e),r=null===(n=null==o?void 0:o.modalizer)||void 0===n?void 0:n.userId;r&&(i.modalizerId=r),we(e,Q,i)}}},this._tabster=e,this._win=t,e.queueInit(this._init)}dispose(){super.dispose();const e=this._win();e.document.removeEventListener(W.PW,this._onFocusIn,!0),e.document.removeEventListener("focusout",this._onFocusOut,!0),e.removeEventListener("keydown",this._onKeyDown,!0),this.unsubscribe(this._onChanged),delete Ne._lastResetElement,delete this._nextVal,delete this._lastVal}static forgetMemorized(e,t){var i,n;let o=Ne._lastResetElement,r=o&&o.get();r&&t.contains(r)&&delete Ne._lastResetElement,r=null===(n=null===(i=e._nextVal)||void 0===i?void 0:i.element)||void 0===n?void 0:n.get(),r&&t.contains(r)&&delete e._nextVal,o=e._lastVal,r=o&&o.get(),r&&t.contains(r)&&delete e._lastVal}getFocusedElement(){return this.getVal()}getLastFocusedElement(){var e;let t=null===(e=this._lastVal)||void 0===e?void 0:e.get();return(!t||t&&!me(t.ownerDocument,t))&&(this._lastVal=t=void 0),t}focus(e,t,i){return!!this._tabster.focusable.isFocusable(e,t,!1,i)&&(e.focus(),!0)}focusDefault(e){const t=this._tabster.focusable.findDefault({container:e});return!!t&&(this._tabster.focusedElement.focus(t),!0)}getFirstOrLastTabbable(e,t){const i=this._tabster.focusable,{container:n,ignoreAccessibility:o}=t;let r,a;if(n){const t=ke.getTabsterContext(this._tabster,n);if(t){let s=Ne.findNextTabbable(this._tabster,t,n,void 0,void 0,!e,void 0,o);if(s)for(a=s.element,r=s.uncontrolled;!a&&r;)a=i.isFocusable(r,!1,!0,!0)?r:i[e?"findFirst":"findLast"]({container:r,ignoreUncontrolled:!0,ignoreAccessibility:o,useActiveModalizer:!0}),a||(s=Ne.findNextTabbable(this._tabster,t,r,void 0,void 0,!e,void 0,o),s&&(a=s.element,r=s.uncontrolled))}}return a&&!(null==n?void 0:n.contains(a))&&(a=void 0),a||void 0}_focusFirstOrLast(e,t){const i=this.getFirstOrLastTabbable(e,t);return!!i&&(this.focus(i,!1,!0),!0)}focusFirst(e){return this._focusFirstOrLast(!0,e)}focusLast(e){return this._focusFirstOrLast(!1,e)}resetFocus(e){if(!this._tabster.focusable.isVisible(e))return!1;if(this._tabster.focusable.isFocusable(e,!0,!0,!0))this.focus(e);else{const t=e.getAttribute("tabindex"),i=e.getAttribute("aria-hidden");e.tabIndex=-1,e.setAttribute("aria-hidden","true"),Ne._lastResetElement=new ce(this._win,e),this.focus(e,!0,!0),this._setOrRemoveAttribute(e,"tabindex",t),this._setOrRemoveAttribute(e,"aria-hidden",i)}return!0}_setOrRemoveAttribute(e,t,i){null===i?e.removeAttribute(t):e.setAttribute(t,i)}_setFocusedElement(e,t,i){var n,o;if(this._tabster._noop)return;const r={relatedTarget:t};if(e){const t=null===(n=Ne._lastResetElement)||void 0===n?void 0:n.get();if(Ne._lastResetElement=void 0,t===e||pe(e))return;r.isFocusedProgrammatically=i;const a=ke.getTabsterContext(this._tabster,e),s=null===(o=null==a?void 0:a.modalizer)||void 0===o?void 0:o.userId;s&&(r.modalizerId=s)}const a=this._nextVal={element:e?new ce(this._win,e):void 0,details:r};e&&e!==this._val&&this._validateFocusedElement(e),this._nextVal===a&&this.setVal(e,r),this._nextVal=void 0}setVal(e,t){super.setVal(e,t),e&&(this._lastVal=new ce(this._win,e))}static findNextTabbable(e,t,i,n,o,r,a,s){const l=i||t.root.getElement();if(!l)return null;let c=null;const d=Ne._isTabbingTimer,u=e.getWindow();d&&u.clearTimeout(d),Ne.isTabbing=!0,Ne._isTabbingTimer=u.setTimeout((()=>{delete Ne._isTabbingTimer,Ne.isTabbing=!1}),0);const h=t.modalizer,p=t.groupper,g=t.mover,f=t=>{var l;if(c=t.findNextTabbable(n,o,r,a,s),n&&!(null==c?void 0:c.element)&&!(null==c?void 0:c.uncontrolled)){const o=t!==h&&(null===(l=t.getElement())||void 0===l?void 0:l.parentElement);if(o){const l=ke.getTabsterContext(e,n,{referenceElement:o});if(l){const n=t.getElement(),d=r?n:n&&Te(n)||n;d&&(c=Ne.findNextTabbable(e,l,i,d,o,r,a,s),c&&(c.outOfDOMOrder=!0))}}}};if(p&&g)f(t.isGroupperFirst?p:g);else if(p)f(p);else if(g)f(g);else if(h)f(h);else{let t;const i={container:l,currentElement:n,referenceElement:o,onUncontrolled:e=>{t=e},ignoreUncontrolled:a,ignoreAccessibility:s,useActiveModalizer:!0},d={},u=e.focusable[r?"findPrev":"findNext"](i,d);c={element:t?void 0:u,uncontrolled:t,outOfDOMOrder:d.outOfDOMOrder}}return c}}Ne.isTabbing=!1;class Re extends Ie{constructor(e){super(),this._onChange=e=>{this.setVal(e,void 0)},this._keyborg=(0,W.Vm)(e()),this._keyborg.subscribe(this._onChange)}dispose(){super.dispose(),this._keyborg&&(this._keyborg.unsubscribe(this._onChange),(0,W.ub)(this._keyborg),delete this._keyborg)}setNavigatingWithKeyboard(e){var t;null===(t=this._keyborg)||void 0===t||t.setVal(e)}isNavigatingWithKeyboard(){var e;return!!(null===(e=this._keyborg)||void 0===e?void 0:e.isNavigatingWithKeyboard())}}let Me=0;const Le="aria-hidden";class Be extends be{constructor(e,t,i){super(t,e,2,i),this._setHandlers(((i,n)=>{var o,r,a;const s=e.get(),l=s&&(null===(o=ke.getRoot(t,s))||void 0===o?void 0:o.getElement()),c=i.input;let d;if(l&&c){const e=null===(r=c.__tabsterDummyContainer)||void 0===r?void 0:r.get(),i=ke.getTabsterContext(t,e||c);i&&(d=null===(a=Ne.findNextTabbable(t,i,l,c,void 0,n,!0,!0))||void 0===a?void 0:a.element),d&&(0,W.ev)(d)}}))}}class Fe extends ye{constructor(e,t,i,n,o,r){super(e,t,n),this._wasFocused=0,this.userId=n.id,this._onDispose=i,this._activeElements=r,e.controlTab||(this.dummyManager=new Be(this._element,e,o))}makeActive(e){if(this._isActive!==e){this._isActive=e;const t=this.getElement();if(t){const i=this._activeElements,n=i.map((e=>e.deref())).indexOf(t);e?n<0&&i.push(new WeakRef(t)):n>=0&&i.splice(n,1)}this.triggerFocusEvent(e?Y:X)}}focused(e){return e||(this._wasFocused=++Me),this._wasFocused}setProps(e){e.id&&(this.userId=e.id),this._props={...e}}dispose(){var e;this.makeActive(!1),this._onDispose(this),null===(e=this.dummyManager)||void 0===e||e.dispose(),delete this.dummyManager,this._activeElements=[],this._remove()}isActive(){return!!this._isActive}contains(e){var t;return!!(null===(t=this.getElement())||void 0===t?void 0:t.contains(e))}findNextTabbable(e,t,i,n,o){var r,a;if(!this.getElement())return null;const s=this._tabster;let l,c=null,d=!1;const u=e=>{l=e},h=e&&(null===(r=ke.getRoot(s,e))||void 0===r?void 0:r.getElement());if(h){const r={container:h,currentElement:e,referenceElement:t,onUncontrolled:u,ignoreUncontrolled:n,ignoreAccessibility:o,useActiveModalizer:!0},p={};c=s.focusable[i?"findPrev":"findNext"](r,p),!l&&!c&&this._props.isTrapped&&(null===(a=s.modalizer)||void 0===a?void 0:a.activeId)?(c=s.focusable[i?"findLast":"findFirst"]({container:h,ignoreUncontrolled:!0,ignoreAccessibility:o,useActiveModalizer:!0}),d=!0):d=!!p.outOfDOMOrder}return{element:c,uncontrolled:l,outOfDOMOrder:d}}triggerFocusEvent(e,t){const i=this.getElement();let n=!1;if(i){const o=t?this._activeElements.map((e=>e.deref())):[i];for(const t of o)t&&!we(t,e,{id:this.userId,element:i,eventName:e})&&(n=!0)}return n}_remove(){}}class Ue{constructor(e,t,i){this._onModalizerDispose=e=>{const t=e.id,i=e.userId,n=this._parts[i];delete this._modalizers[t],n&&(delete n[t],0===Object.keys(n).length&&(delete this._parts[i],this.activeId===i&&this.setActive(void 0)))},this._onKeyDown=e=>{var t;if(27!==e.keyCode)return;const i=this._tabster,n=i.focusedElement.getFocusedElement();if(n){const o=ke.getTabsterContext(i,n),r=null==o?void 0:o.modalizer;if(o&&!o.groupper&&(null==r?void 0:r.isActive())&&!o.ignoreKeydown(e)){const n=r.userId;if(n){const o=this._parts[n];if(o){const n=Object.keys(o).map((e=>{var t;const i=o[e],n=i.getElement();let r;return n&&(r=null===(t=ne(this._tabster,n))||void 0===t?void 0:t.groupper),i&&n&&r?{el:n,focusedSince:i.focused(!0)}:{focusedSince:0}})).filter((e=>e.focusedSince>0)).sort(((e,t)=>e.focusedSince>t.focusedSince?-1:e.focusedSince<t.focusedSince?1:0));if(n.length){const o=n[0].el;o&&(null===(t=i.groupper)||void 0===t||t.handleKeyPress(o,e,!0))}}}}}},this._onFocus=(e,t)=>{var i,n;const o=e&&ke.getTabsterContext(this._tabster,e);if(!o||!e)return;const r=this._augMap;for(let t=e;t;t=t.parentElement)r.has(t)&&(r.delete(t),Oe(this._tabster,t,Le));const a=o.modalizer;if(null===(n=a||(null===(i=ne(this._tabster,e))||void 0===i?void 0:i.modalizer))||void 0===n||n.focused(),(null==a?void 0:a.userId)!==this.activeId)if(t.isFocusedProgrammatically||this.currentIsOthersAccessible||(null==a?void 0:a.getProps().isAlwaysAccessible))this.setActive(a);else{const t=this._win();t.clearTimeout(this._restoreModalizerFocusTimer),this._restoreModalizerFocusTimer=t.setTimeout((()=>this._restoreModalizerFocus(e)),100)}else this.currentIsOthersAccessible=null==a?void 0:a.getProps().isOthersAccessible},this._tabster=e,this._win=e.getWindow,this._modalizers={},this._parts={},this._augMap=new WeakMap,this._aug=[],this._alwaysAccessibleSelector=t,this._accessibleCheck=i,this.activeElements=[],e.controlTab||e.root.addDummyInputs(),this._win().addEventListener("keydown",this._onKeyDown,!0),e.queueInit((()=>{this._tabster.focusedElement.subscribe(this._onFocus)}))}dispose(){const e=this._win();e.removeEventListener("keydown",this._onKeyDown,!0),Object.keys(this._modalizers).forEach((e=>{this._modalizers[e]&&(this._modalizers[e].dispose(),delete this._modalizers[e])})),e.clearTimeout(this._restoreModalizerFocusTimer),e.clearTimeout(this._hiddenUpdateTimer),this._parts={},delete this.activeId,this.activeElements=[],this._augMap=new WeakMap,this._aug=[],this._tabster.focusedElement.unsubscribe(this._onFocus)}createModalizer(e,t,i){var n;const o=new Fe(this._tabster,e,this._onModalizerDispose,t,i,this.activeElements),r=o.id,a=t.id;this._modalizers[r]=o;let s=this._parts[a];return s||(s=this._parts[a]={}),s[r]=o,e.contains(null!==(n=this._tabster.focusedElement.getFocusedElement())&&void 0!==n?n:null)&&(a!==this.activeId?this.setActive(o):o.makeActive(!0)),o}isAugmented(e){return this._augMap.has(e)}hiddenUpdate(){this._hiddenUpdateTimer||(this._hiddenUpdateTimer=this._win().setTimeout((()=>{delete this._hiddenUpdateTimer,this._hiddenUpdate()}),250))}setActive(e){const t=null==e?void 0:e.userId,i=this.activeId;if(i!==t){if(this.activeId=t,i){const e=this._parts[i];if(e)for(const t of Object.keys(e))e[t].makeActive(!1)}if(t){const e=this._parts[t];if(e)for(const t of Object.keys(e))e[t].makeActive(!0)}this.currentIsOthersAccessible=null==e?void 0:e.getProps().isOthersAccessible,this.hiddenUpdate()}}focus(e,t,i){const n=ke.getTabsterContext(this._tabster,e),o=null==n?void 0:n.modalizer;if(o){this.setActive(o);const e=o.getProps(),n=o.getElement();if(n){if(void 0===t&&(t=e.isNoFocusFirst),!t&&this._tabster.keyboardNavigation.isNavigatingWithKeyboard()&&this._tabster.focusedElement.focusFirst({container:n}))return!0;if(void 0===i&&(i=e.isNoFocusDefault),!i&&this._tabster.focusedElement.focusDefault(n))return!0;this._tabster.focusedElement.resetFocus(n)}}return!1}acceptElement(e,t){var i;const n=t.modalizerUserId,o=null===(i=t.currentCtx)||void 0===i?void 0:i.modalizer;if(n)for(const t of this.activeElements){const i=t.deref();if(i&&(e.contains(i)||i===e))return NodeFilter.FILTER_SKIP}const r=n===(null==o?void 0:o.userId)||!n&&(null==o?void 0:o.getProps().isAlwaysAccessible)?void 0:NodeFilter.FILTER_SKIP;return void 0!==r&&(t.skippedFocusable=!0),r}_hiddenUpdate(){var e;const t=this._tabster,i=t.getWindow().document.body,n=this.activeId,o=this._parts,r=[],a=[],s=this._alwaysAccessibleSelector,l=s?Array.from(i.querySelectorAll(s)):[],c=[];for(const e of Object.keys(o)){const t=o[e];for(const i of Object.keys(t)){const o=t[i],s=o.getElement(),d=o.getProps().isAlwaysAccessible;s&&(e===n?(c.push(s),this.currentIsOthersAccessible||r.push(s)):d?l.push(s):a.push(s))}}const d=this._augMap,u=r.length>0?[...r,...l]:void 0,h=[],p=new WeakMap,g=(e,i)=>{var n;const o=e.tagName;if("SCRIPT"===o||"STYLE"===o)return;let r=!1;d.has(e)?i?r=!0:(d.delete(e),Oe(t,e,Le)):i&&!(null===(n=this._accessibleCheck)||void 0===n?void 0:n.call(this,e,c))&&Oe(t,e,Le,"true")&&(d.set(e,!0),r=!0),r&&(h.push(new WeakRef(e)),p.set(e,!0))},f=e=>{for(let t=e.firstElementChild;t;t=t.nextElementSibling){let e=!1,i=!1;if(u){for(const n of u){if(t===n){e=!0;break}if(t.contains(n)){i=!0;break}}i?f(t):e||g(t,!0)}else g(t,!1)}};u||l.forEach((e=>g(e,!1))),a.forEach((e=>g(e,!0))),i&&f(i),null===(e=this._aug)||void 0===e||e.map((e=>e.deref())).forEach((e=>{e&&!p.get(e)&&g(e,!1)})),this._aug=h,this._augMap=p}_restoreModalizerFocus(e){const t=null==e?void 0:e.ownerDocument;if(!e||!t)return;const i=ke.getTabsterContext(this._tabster,e),n=null==i?void 0:i.modalizer,o=this.activeId;if(!n&&!o||n&&o===n.userId)return;const r=null==i?void 0:i.root.getElement();if(r){let t=this._tabster.focusable.findFirst({container:r,ignoreUncontrolled:!0,useActiveModalizer:!0});if(t){if(e.compareDocumentPosition(t)&document.DOCUMENT_POSITION_PRECEDING&&(t=this._tabster.focusable.findLast({container:r,ignoreUncontrolled:!0,useActiveModalizer:!0}),!t))throw new Error("Something went wrong.");return void this._tabster.focusedElement.focus(t)}}e.blur()}}class He{constructor(){}}const $e="restorer:restorefocus";class Ze extends ye{constructor(e,t,i){var n;if(super(e,t,i),this._hasFocus=!1,this._onFocusOut=e=>{var t;const i=null===(t=this._element)||void 0===t?void 0:t.get();i&&null===e.relatedTarget&&i.dispatchEvent(new Event($e,{bubbles:!0})),i&&!i.contains(e.relatedTarget)&&(this._hasFocus=!1)},this._onFocusIn=()=>{this._hasFocus=!0},this._props.type===ee.Source){const e=null===(n=this._element)||void 0===n?void 0:n.get();null==e||e.addEventListener("focusout",this._onFocusOut),null==e||e.addEventListener("focusin",this._onFocusIn)}}dispose(){var e,t;if(this._props.type===ee.Source){const i=null===(e=this._element)||void 0===e?void 0:e.get();null==i||i.removeEventListener("focusout",this._onFocusOut),null==i||i.removeEventListener("focusin",this._onFocusIn),this._hasFocus&&(null===(t=this._tabster.getWindow().document.body)||void 0===t||t.dispatchEvent(new Event($e,{bubbles:!0})))}}}class Ve{constructor(e){this._history=[],this._restoreFocusTimeout=0,this._onRestoreFocus=e=>{const t=this._getWindow();this._restoreFocusTimeout&&t.clearTimeout(this._restoreFocusTimeout),this._restoreFocusTimeout=t.setTimeout((()=>this._restoreFocus(e.target)))},this._onFocusIn=e=>{var t;if(!e)return;const i=ne(this._tabster,e);(null===(t=null==i?void 0:i.restorer)||void 0===t?void 0:t.getProps().type)===ee.Target&&this._addToHistory(e)},this._restoreFocus=e=>{var t,i,n;const o=this._getWindow().document;if(o.activeElement!==o.body)return;if(!this._keyboardNavState.isNavigatingWithKeyboard()&&o.body.contains(e))return;let r=this._history.pop();for(;r&&!o.body.contains(null!==(i=null===(t=r.deref())||void 0===t?void 0:t.parentElement)&&void 0!==i?i:null);)r=this._history.pop();null===(n=null==r?void 0:r.deref())||void 0===n||n.focus()},this._tabster=e,this._getWindow=e.getWindow,this._getWindow().addEventListener($e,this._onRestoreFocus),this._keyboardNavState=e.keyboardNavigation,this._focusedElementState=e.focusedElement,this._focusedElementState.subscribe(this._onFocusIn)}dispose(){const e=this._getWindow();this._focusedElementState.unsubscribe(this._onFocusIn),e.removeEventListener($e,this._onRestoreFocus),this._restoreFocusTimeout&&e.clearTimeout(this._restoreFocusTimeout)}_addToHistory(e){var t;(null===(t=this._history[this._history.length-1])||void 0===t?void 0:t.deref())!==e&&(this._history.length>10&&this._history.shift(),this._history.push(new WeakRef(e)))}createRestorer(e,t){const i=new Ze(this._tabster,e,t);return t.type===ee.Target&&e.ownerDocument.activeElement===e&&this._addToHistory(e),i}}class Ge{constructor(e){this.keyboardNavigation=e.keyboardNavigation,this.focusedElement=e.focusedElement,this.focusable=e.focusable,this.root=e.root,this.uncontrolled=e.uncontrolled,this.core=e}}class je{constructor(e,t){var i,n;this._forgetMemorizedElements=[],this._wrappers=new Set,this._initQueue=[],this._version="4.9.0",this._noop=!1,this.getWindow=()=>{if(!this._win)throw new Error("Using disposed Tabster.");return this._win},this._storage=function(e){const t=e.__tabsterInstanceContext;return new((null==t?void 0:t.basics.WeakMap)||WeakMap)}(e),this._win=e;const o=this.getWindow;this.keyboardNavigation=new Re(o),this.focusedElement=new Ne(this,o),this.focusable=new _e(this),this.root=new ke(this,null==t?void 0:t.autoRoot),this.uncontrolled=new He,this.controlTab=null===(i=null==t?void 0:t.controlTab)||void 0===i||i,this.rootDummyInputs=!!(null==t?void 0:t.rootDummyInputs),this._dummyObserver=new Se(o),this.getParent=null!==(n=null==t?void 0:t.getParent)&&void 0!==n?n:e=>e.parentElement,this.internal={stopObserver:()=>{this._unobserve&&(this._unobserve(),delete this._unobserve)},resumeObserver:e=>{if(!this._unobserve){const t=o().document;this._unobserve=function(e,t,i,n){if("undefined"==typeof MutationObserver)return()=>{};const o=t.getWindow;let r;function a(t,i){r||(r=se(o).elementByUId),s(t,i);const n=he(e,t,(e=>s(e,i)));if(n)for(;n.nextNode(););}function s(e,n){var a;if(!e.getAttribute)return NodeFilter.FILTER_SKIP;const s=e.__tabsterElementUID;return s&&r&&(n?delete r[s]:null!==(a=r[s])&&void 0!==a||(r[s]=new ce(o,e))),(ne(t,e)||e.hasAttribute(K))&&i(t,e,n),NodeFilter.FILTER_SKIP}const l=new MutationObserver((e=>{var n,o,r,s,l;for(const l of e){const e=l.target,c=l.removedNodes,d=l.addedNodes;if("attributes"===l.type)l.attributeName===K&&i(t,e);else{for(let i=0;i<c.length;i++)a(c[i],!0),null===(o=(n=t._dummyObserver).domChanged)||void 0===o||o.call(n,e);for(let i=0;i<d.length;i++)a(d[i]),null===(s=(r=t._dummyObserver).domChanged)||void 0===s||s.call(r,e)}}null===(l=t.modalizer)||void 0===l||l.hiddenUpdate()}));return n&&a(o().document.body),l.observe(e,{childList:!0,subtree:!0,attributes:!0,attributeFilter:[K]}),()=>{l.disconnect()}}(t,this,oe,e)}}},ue(o),this.queueInit((()=>{this.internal.resumeObserver(!0)}))}_mergeProps(e){var t;e&&(this.getParent=null!==(t=e.getParent)&&void 0!==t?t:this.getParent)}createTabster(e,t){const i=new Ge(this);return e||this._wrappers.add(i),this._mergeProps(t),i}disposeTabster(e,t){t?this._wrappers.clear():this._wrappers.delete(e),0===this._wrappers.size&&this.dispose()}dispose(){var e,t,i,n,o,r,a,s;this.internal.stopObserver();const l=this._win;null==l||l.clearTimeout(this._initTimer),delete this._initTimer,this._initQueue=[],this._forgetMemorizedElements=[],l&&this._forgetMemorizedTimer&&(l.clearTimeout(this._forgetMemorizedTimer),delete this._forgetMemorizedTimer),null===(e=this.outline)||void 0===e||e.dispose(),null===(t=this.crossOrigin)||void 0===t||t.dispose(),null===(i=this.deloser)||void 0===i||i.dispose(),null===(n=this.groupper)||void 0===n||n.dispose(),null===(o=this.mover)||void 0===o||o.dispose(),null===(r=this.modalizer)||void 0===r||r.dispose(),null===(a=this.observedElement)||void 0===a||a.dispose(),null===(s=this.restorer)||void 0===s||s.dispose(),this.keyboardNavigation.dispose(),this.focusable.dispose(),this.focusedElement.dispose(),this.root.dispose(),this._dummyObserver.dispose(),function(e){const t=se(e);t.fakeWeakRefsStarted=!1,t.fakeWeakRefsTimer&&(e().clearTimeout(t.fakeWeakRefsTimer),t.fakeWeakRefsTimer=void 0,t.fakeWeakRefs=[])}(this.getWindow),fe(this.getWindow),this._storage=new WeakMap,this._wrappers.clear(),l&&(function(e){const t=e.__tabsterInstanceContext;t&&(t.elementByUId={},delete t.WeakRef,t.containerBoundingRectCache={},t.containerBoundingRectCacheTimer&&e.clearTimeout(t.containerBoundingRectCacheTimer),t.fakeWeakRefsTimer&&e.clearTimeout(t.fakeWeakRefsTimer),t.fakeWeakRefs=[],delete e.__tabsterInstanceContext)}(l),delete l.__tabsterInstance,delete this._win)}storageEntry(e,t){const i=this._storage;let n=i.get(e);return n?!1===t&&0===Object.keys(n).length&&i.delete(e):!0===t&&(n={},i.set(e,n)),n}forceCleanup(){this._win&&(this._forgetMemorizedElements.push(this._win.document.body),this._forgetMemorizedTimer||(this._forgetMemorizedTimer=this._win.setTimeout((()=>{delete this._forgetMemorizedTimer;for(let e=this._forgetMemorizedElements.shift();e;e=this._forgetMemorizedElements.shift())fe(this.getWindow,e),Ne.forgetMemorized(this.focusedElement,e)}),0),de(this.getWindow,!0)))}queueInit(e){var t;this._win&&(this._initQueue.push(e),this._initTimer||(this._initTimer=null===(t=this._win)||void 0===t?void 0:t.setTimeout((()=>{delete this._initTimer,this.drainInitQueue()}),0)))}drainInitQueue(){if(!this._win)return;const e=this._initQueue;this._initQueue=[],e.forEach((e=>e()))}}var ze=i(10910);function We(e,t={}){if(!e)return null;if(!t.skipVirtual){const t=function(e){return(t=e)&&t._virtual&&e._virtual.parent||null;var t}(e);if(t)return t}return(null==e?void 0:e.parentNode)||null}var Ke=i(38283);const qe=()=>{const{targetDocument:e}=(0,ze.O)(),t=(null==e?void 0:e.defaultView)||void 0,i=n.useMemo((()=>t?function(e,t){let i=function(e){return e.__tabsterInstance}(e);return i?i.createTabster(!1,t):(i=new je(e,t),e.__tabsterInstance=i,i.createTabster())}(t,{autoRoot:{},controlTab:!1,getParent:We}):null),[t]);return(0,Ke.L)((()=>()=>{i&&function(e,t){e.core.disposeTabster(e,void 0)}(i)}),[i]),i},Ye=e=>(qe(),Pe(e)),Xe=(e={})=>{const{trapFocus:t,alwaysFocusable:i,legacyTrapFocus:n}=e,o=qe();o&&(function(e,t,i){const n=e.core;n.modalizer||(n.modalizer=new Ue(n,t,i)),n.modalizer}(o),function(e){const t=e.core;t.restorer||(t.restorer=new Ve(t)),t.restorer}(o));const r=(0,$.Me)("modal-",e.id);return{modalAttributes:Ye({restorer:{type:ie.RestorerTypes.Source},...t&&{modalizer:{id:r,isOthersAccessible:!t,isAlwaysAccessible:i,isTrapped:n&&t}}}),triggerAttributes:Ye({restorer:{type:ie.RestorerTypes.Target}})}};var Je=i(44853);const Qe="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},et=(e=>{const t=n.createContext({value:{current:void 0},version:{current:-1},listeners:[]});var i;return t.Provider=(i=t.Provider,e=>{const t=n.useRef(e.value),o=n.useRef(0),r=n.useRef();return r.current||(r.current={value:t,version:o,listeners:[]}),(0,Ke.L)((()=>{t.current=e.value,o.current+=1,(0,Je.unstable_runWithPriority)(Je.unstable_NormalPriority,(()=>{r.current.listeners.forEach((t=>{t([o.current,e.value])}))}))}),[e.value]),n.createElement(i,{value:r.current},e.children)}),delete t.Consumer,t})(),tt={open:!1,setOpen:()=>null,toggleOpen:()=>null,triggerRef:{current:null},contentRef:{current:null},arrowRef:{current:null},openOnContext:!1,openOnHover:!1,size:"medium",trapFocus:!1,inline:!1},it=(et.Provider,e=>((e,t)=>{const i=n.useContext(e),{value:{current:o},version:{current:r},listeners:a}=i,s=t(o),[l,c]=n.useReducer(((e,i)=>{if(!i)return[o,s];if(i[0]<=r)return Qe(e[1],s)?e:[o,s];try{if(Qe(e[0],i[1]))return e;const n=t(i[1]);return Qe(e[1],n)?e:[i[1],n]}catch(e){}return[e[0],e[1]]}),[o,s]);return Qe(l[1],s)||c(void 0),(0,Ke.L)((()=>(a.push(c),()=>{const e=a.indexOf(c);a.splice(e,1)})),[a]),l[1]})(et,((t=tt)=>e(t))));var nt=i(89832),ot=i(34325);const rt=e=>{const t=(e=>{const{children:t,disableButtonEnhancement:i=!1}=e,n=(0,G.W)(t),o=it((e=>e.open)),r=it((e=>e.setOpen)),a=it((e=>e.toggleOpen)),s=it((e=>e.triggerRef)),l=it((e=>e.openOnHover)),c=it((e=>e.openOnContext)),{triggerAttributes:d}=Xe(),u={...d,"aria-expanded":`${o}`,...null==n?void 0:n.props,onMouseEnter:(0,Z.$)((0,V.E)(null==n?void 0:n.props.onMouseEnter,(e=>{l&&r(e,!0)}))),onMouseLeave:(0,Z.$)((0,V.E)(null==n?void 0:n.props.onMouseLeave,(e=>{l&&r(e,!1)}))),onContextMenu:(0,Z.$)((0,V.E)(null==n?void 0:n.props.onContextMenu,(e=>{c&&(e.preventDefault(),r(e,!0))}))),ref:(0,j.r)(s,null==n?void 0:n.ref)},h={...u,onClick:(0,Z.$)((0,V.E)(null==n?void 0:n.props.onClick,(e=>{c||a(e)}))),onKeyDown:(0,Z.$)((0,V.E)(null==n?void 0:n.props.onKeyDown,(e=>{e.key===ot.L1R&&o&&!e.isDefaultPrevented()&&(r(e,!1),e.preventDefault())})))},p=(0,nt.Q)("button"===(null==n?void 0:n.type)||"a"===(null==n?void 0:n.type)?n.type:"div",h);return{children:(0,z.a)(e.children,(0,nt.Q)("button"===(null==n?void 0:n.type)||"a"===(null==n?void 0:n.type)?n.type:"div",c?u:i?h:p))}})(e);return(e=>e.children)(t)};rt.displayName="PopoverTrigger",rt.isFluentTriggerComponent=!0;const at=(0,r.s)({root:{mc9l5x:"fjseox"},visible:{mc9l5x:"f1w7gpdv"}},{d:[".fjseox{display:none;}",".f1w7gpdv{display:inline;}"]});var st=(e,t)=>{const i=i=>{const{className:o,primaryFill:r="currentColor",filled:s,...l}=i,c=at();return n.createElement(n.Fragment,null,n.createElement(e,Object.assign({},l,{className:(0,a.z)(c.root,s&&c.visible,"fui-Icon-filled",o),fill:r})),n.createElement(t,Object.assign({},l,{className:(0,a.z)(c.root,!s&&c.visible,"fui-Icon-regular",o),fill:r})))};return i.displayName="CompoundIcon",i};const lt=c("Info12Filled","12",["M11 6A5 5 0 1 1 1 6a5 5 0 0 1 10 0Zm-5.5.5V8a.5.5 0 0 0 1 0V6.5a.5.5 0 0 0-1 0ZM6 3.75a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Z"]),ct=c("Info12Regular","12",["M5.5 6.5a.5.5 0 0 1 1 0V8a.5.5 0 0 1-1 0V6.5ZM6 3.75a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5ZM1 6a5 5 0 1 1 10 0A5 5 0 0 1 1 6Zm5-4a4 4 0 1 0 0 8 4 4 0 0 0 0-8Z"]),dt=c("Info16Filled","16",["M8 2a6 6 0 1 0 0 12A6 6 0 0 0 8 2Zm.75 3.5a.75.75 0 1 1-1.5 0 .75.75 0 0 1 1.5 0ZM8 7c.28 0 .5.22.5.5v3a.5.5 0 0 1-1 0v-3c0-.28.22-.5.5-.5Z"]),ut=c("Info16Regular","16",["M8 7c.28 0 .5.22.5.5v3a.5.5 0 0 1-1 0v-3c0-.28.22-.5.5-.5Zm0-.75a.75.75 0 1 0 0-1.5.75.75 0 0 0 0 1.5ZM2 8a6 6 0 1 1 12 0A6 6 0 0 1 2 8Zm6-5a5 5 0 1 0 0 10A5 5 0 0 0 8 3Z"]),ht=c("Info20Filled","20",["M18 10a8 8 0 1 0-16 0 8 8 0 0 0 16 0ZM9.5 8.91a.5.5 0 0 1 1 0V13.6a.5.5 0 0 1-1 0V8.9Zm-.25-2.16a.75.75 0 1 1 1.5 0 .75.75 0 0 1-1.5 0Z"]),pt=c("Info20Regular","20",["M10.5 8.91a.5.5 0 0 0-1 .09v4.6a.5.5 0 0 0 1-.1V8.91Zm.3-2.16a.75.75 0 1 0-1.5 0 .75.75 0 0 0 1.5 0ZM18 10a8 8 0 1 0-16 0 8 8 0 0 0 16 0ZM3 10a7 7 0 1 1 14 0 7 7 0 0 1-14 0Z"]),gt=st(lt,ct),ft=st(dt,ut),mt=st(ht,pt);var vt=i(11122),yt=i(96568);function Ct(e,t){if(!e||!t)return!1;if(e===t)return!0;{const i=new WeakSet;for(;t;){const n=We(t,{skipVirtual:i.has(t)});if(i.add(t),n===e)return!0;t=n}}return!1}const bt=(e,t)=>!!(null==e?void 0:e.contains(t)),St="fuiframefocus";var xt=i(12211),Tt=i(85440),wt=i(3421);const Ot={small:6,medium:8,large:8},Pt=(0,r.s)({root:{sj55zd:"f19n0e5",De3pzq:"fxugw4r",E5pizo:"f1hg901r",Bbmb7ep:["f1aa9q02","f16jpd5f"],Beyfa6y:["f16jpd5f","f1aa9q02"],B7oj6ja:["f1jar5jt","fyu767a"],Btl43ni:["fyu767a","f1jar5jt"],B4j52fo:"f5ogflp",Bekrc4i:["f1hqa2wf","finvdd3"],Bn0qgzm:"f1f09k3d",ibv6hh:["finvdd3","f1hqa2wf"],icvyot:"fzkkow9",vrafjx:["fcdblym","fjik90z"],oivjwe:"fg706s2",wvpqe5:["fjik90z","fcdblym"],g2u3we:"fghlq4f",h3c5rm:["f1gn591s","fjscplz"],B9xav0g:"fb073pr",zhjwy3:["fjscplz","f1gn591s"],Bahqtrf:"fk6fouc",Be2twd7:"fkhj508",Bhrd7zp:"figsok6",Bg96gwp:"f1i3iumi",B93otf3:"f18k4bn6",vin17d:"fo1kyvf",Ezkn3b:"fetxo7e",ex8oj8:"fmm77a6",Bksk4gw:"f12t24nk",Bc5phfd:"f1babd7",cbiifc:"f1jgo889",fyiq5g:"f1ij1pew",Bqc19t1:"f1gu8pa9",Eet2gb:"fhfnl4n",Bhl7k63:"fk8tkmz",Bv12yb3:"f3n0535",z0t1cu:"fi19xcv",Bks05zx:"f1mzajhk",Bvtglag:"fjp4h9y"},inline:{Bj3rh1h:"f19g0ac"},inverted:{De3pzq:"fg3r6xk",sj55zd:"fonrgv7"},brand:{De3pzq:"ffp7eso",sj55zd:"f1phragk"},smallPadding:{z8tnut:"f1kcqot9",z189sj:["f11qrl6u","fjlbh76"],Byoj8tv:"fpe6lb7",uwmqm3:["fjlbh76","f11qrl6u"]},mediumPadding:{z8tnut:"fqag9an",z189sj:["f1gbmcue","f1rh9g5y"],Byoj8tv:"fp67ikv",uwmqm3:["f1rh9g5y","f1gbmcue"]},largePadding:{z8tnut:"fc7z3ec",z189sj:["fat0sn4","fekwl8i"],Byoj8tv:"fe2my4m",uwmqm3:["fekwl8i","fat0sn4"]},smallArrow:{a9b677:"f1ekdpwm",Bqenvij:"f83vc9z"},mediumLargeArrow:{a9b677:"f1kmc0fn",Bqenvij:"fb6lvc5"},arrow:{qhf8xq:"f1euv43f",De3pzq:"f1u2r49w",Bcdw1i0:"fd7fpy0",Bj3rh1h:"f1bsuimh",Ftih45:"f1wl9k8s",B1puzpu:"f1wkw4r9",Brfgrao:"f1j7ml58",Bcvre1j:"fyl8oag",Ccq8qp:"frdoeuz",Baz25je:"fb81m9q",cmx5o7:"f1ljr5q2",B4f6apu:"fyfemzf",m598lv:"focyt6c",Bk5zm6e:"fnhxbxj",y0oebl:"fdw6hkg",qa3bma:"f11yjt3y",Bqjgrrk:"f1172wan",Budzafs:["f9e5op9","f112wvtl"],Hv9wc6:["ftj5xct","fyavhwi"],hl6cv3:"f1773hnp",Bh2vraf:"f1n8855c",yayu3t:"f1v7783n",wedwtw:"fsw6im5",rhl9o9:"fh2hsk5",Bu8t5uz:"f159pzir",B6q6orb:"f11yvu4",Bwwlvwl:"fm1ycve"}},{d:[".f19n0e5{color:var(--colorNeutralForeground1);}",".fxugw4r{background-color:var(--colorNeutralBackground1);}",".f1hg901r{box-shadow:var(--shadow16);}",".f1aa9q02{border-bottom-right-radius:var(--borderRadiusMedium);}",".f16jpd5f{border-bottom-left-radius:var(--borderRadiusMedium);}",".f1jar5jt{border-top-right-radius:var(--borderRadiusMedium);}",".fyu767a{border-top-left-radius:var(--borderRadiusMedium);}",".f5ogflp{border-top-width:1px;}",".f1hqa2wf{border-right-width:1px;}",".finvdd3{border-left-width:1px;}",".f1f09k3d{border-bottom-width:1px;}",".fzkkow9{border-top-style:solid;}",".fcdblym{border-right-style:solid;}",".fjik90z{border-left-style:solid;}",".fg706s2{border-bottom-style:solid;}",".fghlq4f{border-top-color:var(--colorTransparentStroke);}",".f1gn591s{border-right-color:var(--colorTransparentStroke);}",".fjscplz{border-left-color:var(--colorTransparentStroke);}",".fb073pr{border-bottom-color:var(--colorTransparentStroke);}",".fk6fouc{font-family:var(--fontFamilyBase);}",".fkhj508{font-size:var(--fontSizeBase300);}",".figsok6{font-weight:var(--fontWeightRegular);}",".f1i3iumi{line-height:var(--lineHeightBase300);}",".f18k4bn6{animation-composition:accumulate;}",".fo1kyvf{animation-duration:var(--durationSlower);}",".fetxo7e{animation-timing-function:var(--curveDecelerateMid);}",".fmm77a6{--slide-distance-x:0px;}",".f12t24nk{--slide-distance-y:10px;}",".f1babd7[data-popper-placement^=right]{--slide-distance-x:-10px;}",".f1jgo889[data-popper-placement^=right]{--slide-distance-y:0px;}",".f1ij1pew[data-popper-placement^=bottom]{--slide-distance-x:0px;}",".f1gu8pa9[data-popper-placement^=bottom]{--slide-distance-y:-10px;}",".fhfnl4n[data-popper-placement^=left]{--slide-distance-x:10px;}",".fk8tkmz[data-popper-placement^=left]{--slide-distance-y:0px;}",".f3n0535{animation-name:f5j8bii,fld5wjx;}",".f19g0ac{z-index:1;}",".fg3r6xk{background-color:var(--colorNeutralBackgroundStatic);}",".fonrgv7{color:var(--colorNeutralForegroundStaticInverted);}",".ffp7eso{background-color:var(--colorBrandBackground);}",".f1phragk{color:var(--colorNeutralForegroundOnBrand);}",".f1kcqot9{padding-top:12px;}",".f11qrl6u{padding-right:12px;}",".fjlbh76{padding-left:12px;}",".fpe6lb7{padding-bottom:12px;}",".fqag9an{padding-top:16px;}",".f1gbmcue{padding-right:16px;}",".f1rh9g5y{padding-left:16px;}",".fp67ikv{padding-bottom:16px;}",".fc7z3ec{padding-top:20px;}",".fat0sn4{padding-right:20px;}",".fekwl8i{padding-left:20px;}",".fe2my4m{padding-bottom:20px;}",".f1ekdpwm{width:8.484px;}",".f83vc9z{height:8.484px;}",".f1kmc0fn{width:11.312px;}",".fb6lvc5{height:11.312px;}",".f1euv43f{position:absolute;}",".f1u2r49w{background-color:inherit;}",".fd7fpy0{visibility:hidden;}",".f1bsuimh{z-index:-1;}",'.f1wl9k8s::before{content:"";}',".f1wkw4r9::before{visibility:visible;}",".f1j7ml58::before{position:absolute;}",".fyl8oag::before{box-sizing:border-box;}",".frdoeuz::before{width:inherit;}",".fb81m9q::before{height:inherit;}",".f1ljr5q2::before{background-color:inherit;}",".fyfemzf::before{border-right-width:1px;}",".focyt6c::before{border-right-style:solid;}",".fnhxbxj::before{border-right-color:var(--colorTransparentStroke);}",".fdw6hkg::before{border-bottom-width:1px;}",".f11yjt3y::before{border-bottom-style:solid;}",".f1172wan::before{border-bottom-color:var(--colorTransparentStroke);}",".f9e5op9::before{border-bottom-right-radius:var(--borderRadiusSmall);}",".f112wvtl::before{border-bottom-left-radius:var(--borderRadiusSmall);}",".ftj5xct::before{transform:rotate(var(--angle)) translate(0, 50%) rotate(45deg);}",".fyavhwi::before{transform:rotate(var(--angle)) translate(0, 50%) rotate(-45deg);}",'[data-popper-placement^="top"] .f1773hnp{bottom:-1px;}','[data-popper-placement^="top"] .f1n8855c{--angle:0;}','[data-popper-placement^="right"] .f1v7783n{left:-1px;}','[data-popper-placement^="right"] .fsw6im5{--angle:90deg;}','[data-popper-placement^="bottom"] .fh2hsk5{top:-1px;}','[data-popper-placement^="bottom"] .f159pzir{--angle:180deg;}','[data-popper-placement^="left"] .f11yvu4{right:-1px;}','[data-popper-placement^="left"] .fm1ycve{--angle:270deg;}'],k:["@keyframes f5j8bii{from{opacity:0;}to{opacity:1;}}","@keyframes fld5wjx{from{transform:translate(var(--slide-distance-x), var(--slide-distance-y));}}"],m:[["@media (prefers-reduced-motion){.fi19xcv[data-popper-placement]{animation-duration:1ms;}}",{m:"(prefers-reduced-motion)"}],["@media (prefers-reduced-motion){.f1mzajhk[data-popper-placement]{animation-name:f5j8bii;}}",{m:"(prefers-reduced-motion)"}]],t:["@supports not (animation-composition: accumulate){.fjp4h9y[data-popper-placement]{animation-name:f5j8bii;}}"]}),At=e=>{const[t,i]=(e=>{const[t,i]=n.useState(void 0);return[t,e=>{if(null==e)return void i(void 0);let t;t=e instanceof MouseEvent?e:e.nativeEvent,MouseEvent;const n=function(e){const t=e.clientX,i=e.clientY,n=t+1,o=i+1;return{getBoundingClientRect:function(){return{left:t,top:i,right:n,bottom:o,x:t,y:i,height:1,width:1}}}}(t);i(n)}]})(),o={size:"medium",contextTarget:t,setContextTarget:i,...e},r=n.Children.toArray(e.children);let a,s;2===r.length?(a=r[0],s=r[1]):1===r.length&&(s=r[0]);const[l,c]=function(e){const t=(0,Z.$)(((t,i)=>{var n;return null===(n=e.onOpenChange)||void 0===n?void 0:n.call(e,t,i)})),[i,o]=(0,vt.T)({state:e.open,defaultState:e.defaultOpen,initialState:!1});e.open=void 0!==i?i:e.open;const r=e.setContextTarget,a=n.useCallback(((e,i)=>{i&&"contextmenu"===e.type&&r(e),i||r(void 0),o(i),null==t||t(e,{open:i})}),[o,t,r]);return[i,a]}(o),d=n.useRef(0),u=(0,Z.$)(((t,i)=>{var n;clearTimeout(d.current),t instanceof Event||!t.persist||t.persist(),"mouseleave"===t.type?d.current=setTimeout((()=>{c(t,i)}),null!==(n=e.mouseLeaveDelay)&&void 0!==n?n:500):c(t,i)}));n.useEffect((()=>()=>{clearTimeout(d.current)}),[]);const h=n.useCallback((e=>{u(e,!l)}),[u,l]),p=function(e){const t={position:"above",align:"center",arrowPadding:8,target:e.openOnContext?e.contextTarget:void 0,...(0,xt.j)(e.positioning)};t.coverTarget&&(e.withArrow=!1),e.withArrow&&(t.offset=(0,Tt.w)(t.offset,Ot[e.size]));const{targetRef:i,containerRef:n,arrowRef:o}=(0,wt.m)(t);return{triggerRef:i,contentRef:n,arrowRef:o}}(o),{targetDocument:g}=(0,ze.O)();var f;(e=>{const{refs:t,callback:i,element:o,disabled:r,disabledFocusOnIframe:a,contains:s=bt}=e,l=n.useRef(void 0);(e=>{const{disabled:t,element:i,callback:o,contains:r=bt,pollDuration:a=1e3,refs:s}=e,l=n.useRef(),c=(0,Z.$)((e=>{s.every((t=>!r(t.current||null,e.target)))&&!t&&o(e)}));n.useEffect((()=>{if(!t)return null==i||i.addEventListener(St,c,!0),()=>{null==i||i.removeEventListener(St,c,!0)}}),[i,t,c]),n.useEffect((()=>{var e;if(!t)return l.current=null==i||null===(e=i.defaultView)||void 0===e?void 0:e.setInterval((()=>{const e=null==i?void 0:i.activeElement;if("IFRAME"===(null==e?void 0:e.tagName)||"WEBVIEW"===(null==e?void 0:e.tagName)){const t=new CustomEvent(St,{bubbles:!0});e.dispatchEvent(t)}}),a),()=>{var e;null==i||null===(e=i.defaultView)||void 0===e||e.clearTimeout(l.current)}}),[i,t,a])})({element:o,disabled:a||r,callback:i,refs:t,contains:s});const c=n.useRef(!1),d=(0,Z.$)((e=>{if(c.current)return void(c.current=!1);const n=e.composedPath()[0];t.every((e=>!s(e.current||null,n)))&&!r&&i(e)})),u=(0,Z.$)((e=>{c.current=t.some((t=>s(t.current||null,e.target)))}));n.useEffect((()=>{if(r)return;let e=(e=>{var t,i,n;if(e)return"object"==typeof e.window&&e.window===e?e.event:null!==(n=null===(i=e.ownerDocument)||void 0===i||null===(t=i.defaultView)||void 0===t?void 0:t.event)&&void 0!==n?n:void 0})(window);const t=t=>{t!==e?d(t):e=void 0};return null==o||o.addEventListener("click",t,!0),null==o||o.addEventListener("touchstart",t,!0),null==o||o.addEventListener("contextmenu",t,!0),null==o||o.addEventListener("mousedown",u,!0),l.current=window.setTimeout((()=>{e=void 0}),1),()=>{null==o||o.removeEventListener("click",t,!0),null==o||o.removeEventListener("touchstart",t,!0),null==o||o.removeEventListener("contextmenu",t,!0),null==o||o.removeEventListener("mousedown",u,!0),clearTimeout(l.current),e=void 0}}),[d,o,r,u])})({contains:Ct,element:g,callback:e=>u(e,!1),refs:[p.triggerRef,p.contentRef],disabled:!l,disabledFocusOnIframe:!(null===(f=e.closeOnIframeFocus)||void 0===f||f)});const m=o.openOnContext||o.closeOnScroll;(e=>{const{refs:t,callback:i,element:o,disabled:r,contains:a}=e,s=(0,Z.$)((e=>{const n=a||((e,t)=>!!(null==e?void 0:e.contains(t))),o=e.composedPath()[0];t.every((e=>!n(e.current||null,o)))&&!r&&i(e)}));n.useEffect((()=>{if(!r)return null==o||o.addEventListener("wheel",s),null==o||o.addEventListener("touchmove",s),()=>{null==o||o.removeEventListener("wheel",s),null==o||o.removeEventListener("touchmove",s)}}),[s,o,r])})({contains:Ct,element:g,callback:e=>u(e,!1),refs:[p.triggerRef,p.contentRef],disabled:!l||!m});const{findFirstFocusable:v}=(()=>{const e=qe(),{targetDocument:t}=(0,ze.O)();return{findAllFocusable:n.useCallback(((t,i)=>(null==e?void 0:e.focusable.findAll({container:t,acceptCondition:i}))||[]),[e]),findFirstFocusable:n.useCallback((t=>null==e?void 0:e.focusable.findFirst({container:t})),[e]),findLastFocusable:n.useCallback((t=>null==e?void 0:e.focusable.findLast({container:t})),[e]),findNextFocusable:n.useCallback(((i,n={})=>{if(!e||!t)return null;const{container:o=t.body}=n;return e.focusable.findNext({currentElement:i,container:o})}),[e,t]),findPrevFocusable:n.useCallback(((i,n={})=>{if(!e||!t)return null;const{container:o=t.body}=n;return e.focusable.findPrev({currentElement:i,container:o})}),[e,t])}})();var y,C;return n.useEffect((()=>{if(!e.unstable_disableAutoFocus&&l&&p.contentRef.current){var t;const e=null!==(t=p.contentRef.current.getAttribute("tabIndex"))&&void 0!==t?t:void 0,i=isNaN(e)?v(p.contentRef.current):p.contentRef.current;null==i||i.focus()}}),[v,l,p.contentRef,e.unstable_disableAutoFocus]),{...o,...p,inertTrapFocus:null!==(y=e.inertTrapFocus)&&void 0!==y?y:void 0!==e.legacyTrapFocus&&!e.legacyTrapFocus,popoverTrigger:a,popoverSurface:s,open:l,setOpen:u,toggleOpen:h,setContextTarget:i,contextTarget:t,inline:null!==(C=e.inline)&&void 0!==C&&C}},Et=e=>(e=>{const{appearance:t,arrowRef:i,contentRef:o,inline:r,mountNode:a,open:s,openOnContext:l,openOnHover:c,setOpen:d,size:u,toggleOpen:h,trapFocus:p,triggerRef:g,withArrow:f,inertTrapFocus:m}=e;return n.createElement(et.Provider,{value:{appearance:t,arrowRef:i,contentRef:o,inline:r,mountNode:a,open:s,openOnContext:l,openOnHover:c,setOpen:d,toggleOpen:h,triggerRef:g,size:u,trapFocus:p,inertTrapFocus:m,withArrow:f}},e.popoverTrigger,e.open&&e.popoverSurface)})(At(e));Et.displayName="Popover";var kt=i(77688);const It=n.forwardRef(((e,t)=>{const i=((e,t)=>{const i=it((e=>e.contentRef)),n=it((e=>e.openOnHover)),o=it((e=>e.setOpen)),r=it((e=>e.mountNode)),a=it((e=>e.arrowRef)),s=it((e=>e.size)),l=it((e=>e.withArrow)),c=it((e=>e.appearance)),d=it((e=>e.trapFocus)),u=it((e=>e.inertTrapFocus)),h=it((e=>e.inline)),{modalAttributes:p}=Xe({trapFocus:d,legacyTrapFocus:!u,alwaysFocusable:!d}),g={inline:h,appearance:c,withArrow:l,size:s,arrowRef:a,mountNode:r,components:{root:"div"},root:L.Bx((0,B.h)("div",{ref:(0,j.r)(t,i),role:d?"dialog":"group","aria-modal":!!d||void 0,...p,...e}),{elementType:"div"})},{onMouseEnter:f,onMouseLeave:m,onKeyDown:v}=g.root;return g.root.onMouseEnter=e=>{n&&o(e,!0),null==f||f(e)},g.root.onMouseLeave=e=>{n&&o(e,!1),null==m||m(e)},g.root.onKeyDown=e=>{var t;"Escape"===e.key&&(null===(t=i.current)||void 0===t?void 0:t.contains(e.target))&&(e.preventDefault(),o(e,!1)),null==v||v(e)},g})(e,t);return(e=>{const t=Pt();e.root.className=(0,a.z)("fui-PopoverSurface",t.root,e.inline&&t.inline,"small"===e.size&&t.smallPadding,"medium"===e.size&&t.mediumPadding,"large"===e.size&&t.largePadding,"inverted"===e.appearance&&t.inverted,"brand"===e.appearance&&t.brand,e.root.className),e.arrowClassName=(0,a.z)(t.arrow,"small"===e.size?t.smallArrow:t.mediumLargeArrow)})(i),(0,U.oj)("usePopoverSurfaceStyles_unstable")(i),(e=>{(0,M.a)(e);const t=(0,R.BX)(e.root,{children:[e.withArrow&&(0,R.tZ)("div",{ref:e.arrowRef,className:e.arrowClassName}),e.root.children]});return e.inline?t:(0,R.tZ)(kt.h,{mountNode:e.mountNode,children:t})})(i)}));It.displayName="PopoverSurface";const Dt={small:n.createElement(gt,null),medium:n.createElement(ft,null),large:n.createElement(mt,null)},_t={small:"small",medium:"small",large:"medium"},Nt=(0,r.s)({base:{Bt984gj:"f122n59",B7ck84d:"f1ewtqcl",mc9l5x:"ftuwxu6",Brf1p80:"f4d9j23",w71qe1:"f1iuv45f",ha4doy:"fmrv4ls",qhf8xq:"f10pi13n",De3pzq:"f1c21dwh",sj55zd:"fkfq4zb",icvyot:"f1ern45e",vrafjx:["f1n71otn","f1deefiw"],oivjwe:"f1h8hb77",wvpqe5:["f1deefiw","f1n71otn"],Bbmb7ep:["f1aa9q02","f16jpd5f"],Beyfa6y:["f16jpd5f","f1aa9q02"],B7oj6ja:["f1jar5jt","fyu767a"],Btl43ni:["fyu767a","f1jar5jt"],B6of3ja:"f1hu3pq6",t21cq0:["f11qmguv","f1tyq0we"],jrapky:"f19f4twv",Frg6f3:["f1tyq0we","f11qmguv"],z8tnut:"f1ywm7hm",z189sj:["f7x41pl","fruq291"],Byoj8tv:"f14wxoun",uwmqm3:["fruq291","f7x41pl"],D0sxk3:"f16u1re",t6yez3:"f1rw4040",Jwef8y:"fjxutwb",Bi91k9c:"f139oj5f",eoavqd:"f8491dx",Bk3fhr4:"f1jpd6y0",Bmfj8id:"fuxngvv",iro3zm:"fwiml72",B2d53fq:"f1fg1p5m"},selected:{De3pzq:"f1q9pm1r",sj55zd:"f1qj7y59",D0sxk3:"fgzdkf0",t6yez3:"f15q0o9g",Bsw6fvg:"f1rirnrt",Bbusuzp:"f1cg6951"},highContrast:{Bbusuzp:"fn0tkbb",Bs6v0vm:"f1rp3av6",B46dtvo:"f1u7gwqv",gh1jta:"fl6kagl"},focusIndicator:{Brovlpu:"ftqa4ok",B486eqv:"f2hkw1w",B8q5s1w:"f8hki3x",Bci5o5g:["f1d2448m","ffh67wi"],n8qw10:"f1bjia2o",Bdrgwmp:["ffh67wi","f1d2448m"],Bm4h7ae:"f15bsgw9",B7ys5i9:"f14e48fq",Busjfv9:"f18yb2kv",Bhk32uz:"fd6o370",Bf4ptjt:"fh1cnn4",kclons:["fy7oxxb","f184ne2d"],Bhdgwq3:"fpukqih",Blkhhs4:["f184ne2d","fy7oxxb"],Bqtpl0w:"frrh606",clg4pj:["f1v5zibi","fo2hd23"],hgwjuy:"ful5kiu",Bonggc9:["fo2hd23","f1v5zibi"],B1tsrr9:["f1jqcqds","ftffrms"],Dah5zi:["ftffrms","f1jqcqds"],Bkh64rk:["f2e7qr6","fsr1zz6"],qqdqy8:["fsr1zz6","f2e7qr6"],B6dhp37:"f1dvezut",i03rao:["fd0oaoj","f1cwg4i8"],Boxcth7:"fjvm52t",Bsom6fd:["f1cwg4i8","fd0oaoj"],J0r882:"f57olzd",Bule8hv:["f4stah7","fs1por5"],Bjwuhne:"f480a47",Ghsupd:["fs1por5","f4stah7"]},large:{z8tnut:"fclwglc",z189sj:["f1w3695s","f1b0r8ql"],Byoj8tv:"fywfov9",uwmqm3:["f1b0r8ql","f1w3695s"]}},{d:[".f122n59{align-items:center;}",".f1ewtqcl{box-sizing:border-box;}",".ftuwxu6{display:inline-flex;}",".f4d9j23{justify-content:center;}",".f1iuv45f{text-decoration-line:none;}",".fmrv4ls{vertical-align:middle;}",".f10pi13n{position:relative;}",".f1c21dwh{background-color:var(--colorTransparentBackground);}",".fkfq4zb{color:var(--colorNeutralForeground2);}",".f1ern45e{border-top-style:none;}",".f1n71otn{border-right-style:none;}",".f1deefiw{border-left-style:none;}",".f1h8hb77{border-bottom-style:none;}",".f1aa9q02{border-bottom-right-radius:var(--borderRadiusMedium);}",".f16jpd5f{border-bottom-left-radius:var(--borderRadiusMedium);}",".f1jar5jt{border-top-right-radius:var(--borderRadiusMedium);}",".fyu767a{border-top-left-radius:var(--borderRadiusMedium);}",".f1hu3pq6{margin-top:0;}",".f11qmguv{margin-right:0;}",".f1tyq0we{margin-left:0;}",".f19f4twv{margin-bottom:0;}",".f1ywm7hm{padding-top:var(--spacingVerticalXS);}",".f7x41pl{padding-right:var(--spacingHorizontalXS);}",".fruq291{padding-left:var(--spacingHorizontalXS);}",".f14wxoun{padding-bottom:var(--spacingVerticalXS);}",".f16u1re .fui-Icon-filled{display:none;}",".f1rw4040 .fui-Icon-regular{display:inline-flex;}",".f1q9pm1r{background-color:var(--colorTransparentBackgroundSelected);}",".f1qj7y59{color:var(--colorNeutralForeground2BrandSelected);}",".fgzdkf0 .fui-Icon-filled{display:inline-flex;}",".f15q0o9g .fui-Icon-regular{display:none;}",".f8hki3x[data-fui-focus-visible]{border-top-color:transparent;}",".f1d2448m[data-fui-focus-visible]{border-right-color:transparent;}",".ffh67wi[data-fui-focus-visible]{border-left-color:transparent;}",".f1bjia2o[data-fui-focus-visible]{border-bottom-color:transparent;}",'.f15bsgw9[data-fui-focus-visible]::after{content:"";}',".f14e48fq[data-fui-focus-visible]::after{position:absolute;}",".f18yb2kv[data-fui-focus-visible]::after{pointer-events:none;}",".fd6o370[data-fui-focus-visible]::after{z-index:1;}",".fh1cnn4[data-fui-focus-visible]::after{border-top-style:solid;}",".fy7oxxb[data-fui-focus-visible]::after{border-right-style:solid;}",".f184ne2d[data-fui-focus-visible]::after{border-left-style:solid;}",".fpukqih[data-fui-focus-visible]::after{border-bottom-style:solid;}",".frrh606[data-fui-focus-visible]::after{border-top-width:2px;}",".f1v5zibi[data-fui-focus-visible]::after{border-right-width:2px;}",".fo2hd23[data-fui-focus-visible]::after{border-left-width:2px;}",".ful5kiu[data-fui-focus-visible]::after{border-bottom-width:2px;}",".f1jqcqds[data-fui-focus-visible]::after{border-bottom-right-radius:var(--borderRadiusMedium);}",".ftffrms[data-fui-focus-visible]::after{border-bottom-left-radius:var(--borderRadiusMedium);}",".f2e7qr6[data-fui-focus-visible]::after{border-top-right-radius:var(--borderRadiusMedium);}",".fsr1zz6[data-fui-focus-visible]::after{border-top-left-radius:var(--borderRadiusMedium);}",".f1dvezut[data-fui-focus-visible]::after{border-top-color:var(--colorStrokeFocus2);}",".fd0oaoj[data-fui-focus-visible]::after{border-right-color:var(--colorStrokeFocus2);}",".f1cwg4i8[data-fui-focus-visible]::after{border-left-color:var(--colorStrokeFocus2);}",".fjvm52t[data-fui-focus-visible]::after{border-bottom-color:var(--colorStrokeFocus2);}",".f57olzd[data-fui-focus-visible]::after{top:calc(2px * -1);}",".f4stah7[data-fui-focus-visible]::after{right:calc(2px * -1);}",".fs1por5[data-fui-focus-visible]::after{left:calc(2px * -1);}",".f480a47[data-fui-focus-visible]::after{bottom:calc(2px * -1);}",".fclwglc{padding-top:var(--spacingVerticalXXS);}",".f1w3695s{padding-right:var(--spacingVerticalXXS);}",".f1b0r8ql{padding-left:var(--spacingVerticalXXS);}",".fywfov9{padding-bottom:var(--spacingVerticalXXS);}"],h:[".fjxutwb:hover{background-color:var(--colorTransparentBackgroundHover);}",".f139oj5f:hover{color:var(--colorNeutralForeground2BrandHover);}",".f8491dx:hover{cursor:pointer;}",".f1jpd6y0:hover .fui-Icon-filled{display:inline-flex;}",".fuxngvv:hover .fui-Icon-regular{display:none;}",".fwiml72:hover:active{background-color:var(--colorTransparentBackgroundPressed);}",".f1fg1p5m:hover:active{color:var(--colorNeutralForeground2BrandPressed);}"],m:[["@media (forced-colors: active){.f1rirnrt{background-color:Highlight;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1cg6951{color:Canvas;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.fn0tkbb{color:CanvasText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1rp3av6:hover,.f1rp3av6:hover:active{forced-color-adjust:none;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1u7gwqv:hover,.f1u7gwqv:hover:active{background-color:Highlight;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.fl6kagl:hover,.fl6kagl:hover:active{color:Canvas;}}",{m:"(forced-colors: active)"}]],f:[".ftqa4ok:focus{outline-style:none;}"],i:[".f2hkw1w:focus-visible{outline-style:none;}"]}),Rt=(0,r.s)({smallMedium:{Bahqtrf:"fk6fouc",Be2twd7:"fy9rknc",Bhrd7zp:"figsok6",Bg96gwp:"fwrc4pm"},large:{Bahqtrf:"fk6fouc",Be2twd7:"fkhj508",Bhrd7zp:"figsok6",Bg96gwp:"f1i3iumi"}},{d:[".fk6fouc{font-family:var(--fontFamilyBase);}",".fy9rknc{font-size:var(--fontSizeBase200);}",".figsok6{font-weight:var(--fontWeightRegular);}",".fwrc4pm{line-height:var(--lineHeightBase200);}",".fkhj508{font-size:var(--fontSizeBase300);}",".f1i3iumi{line-height:var(--lineHeightBase300);}"]}),Mt=n.forwardRef(((e,t)=>{const i=((e,t)=>{const{size:i="medium",inline:o=!0}=e,r={inline:o,size:i,components:{root:"button",popover:Et,info:It},root:L.Bx((0,B.h)("button",{children:Dt[i],type:"button","aria-label":"information",...e,ref:t}),{elementType:"button"}),popover:L.Bx(e.popover,{defaultProps:{inline:o,positioning:"above-start",size:_t[i],withArrow:!0},elementType:Et}),info:L.Bx(e.info,{defaultProps:{role:"note",tabIndex:-1},elementType:It})},[a,s]=(0,vt.T)({state:r.popover.open,defaultState:r.popover.defaultOpen,initialState:!1});r.popover.open=a,r.popover.onOpenChange=(0,V.E)(r.popover.onOpenChange,((e,t)=>s(t.open)));const l=n.useCallback((e=>{e&&e.addEventListener("focusout",(t=>{const i=t.relatedTarget;(0,yt.R)(i)&&!Ct(e,i)&&s(!1)}))}),[s]);return r.info.ref=(0,j.r)(r.info.ref,l),r})(e,t);return(e=>{const{size:t}=e,{open:i}=e.popover,n=Nt(),o=Rt();e.info.className=(0,a.z)("fui-InfoButton__info","large"===t?o.large:o.smallMedium,e.info.className),e.root.className=(0,a.z)("fui-InfoButton",n.base,n.highContrast,n.focusIndicator,i&&n.selected,"large"===t&&n.large,e.root.className)})(i),(e=>((0,M.a)(e),(0,R.BX)(e.popover,{children:[(0,R.tZ)(rt,{children:(0,R.tZ)(e.root,{})}),(0,R.tZ)(e.info,{})]})))(i)}));Mt.displayName="InfoButton";const Lt=(0,r.s)({base:{ha4doy:"f12kltsn",Bceei9c:"fpo1scq",sj55zd:"f1ym3bx4"}},{d:[".f12kltsn{vertical-align:top;}",".fpo1scq{cursor:inherit;}",".f1ym3bx4{color:inherit;}"]}),Bt=(0,r.s)({base:{ha4doy:"f12kltsn",B6of3ja:"f1bmzb36",jrapky:"f1nyzk09"},large:{B6of3ja:"fkrn0sh",jrapky:"fmxx68s"}},{d:[".f12kltsn{vertical-align:top;}",".f1bmzb36{margin-top:calc(0px - var(--spacingVerticalXXS));}",".f1nyzk09{margin-bottom:calc(0px - var(--spacingVerticalXXS));}",".fkrn0sh{margin-top:-1px;}",".fmxx68s{margin-bottom:-1px;}"]}),Ft=n.forwardRef(((e,t)=>{const i=((e,t)=>{const{root:i,label:o,infoButton:r,info:a,size:s,className:l,style:c,...d}=e,u=(0,$.Me)("infolabel-"),[h,p]=n.useState(!1),g=L.Bx(i,{defaultProps:{className:l,style:c},elementType:"span"}),f=L.Bx(o,{defaultProps:{id:u+"__label",ref:t,size:s,...d},elementType:H}),m=L.jt(r,{renderByDefault:!!a,defaultProps:{id:u+"__infoButton",size:s,info:a},elementType:Mt}),v=L.Bx(null==m?void 0:m.popover,{elementType:"div"});var y,C,b,S,x;return v.onOpenChange=(0,Z.$)((0,V.E)(v.onOpenChange,((e,t)=>{p(t.open)}))),m&&(m.popover=v,m.info=L.jt(null==m?void 0:m.info,{defaultProps:{id:u+"__info"},elementType:"div"}),null!==(C=(y=m)["aria-labelledby"])&&void 0!==C||(y["aria-labelledby"]=`${f.id} ${m.id}`),h&&(null!==(x=(S=g)["aria-owns"])&&void 0!==x||(S["aria-owns"]=null===(b=m.info)||void 0===b?void 0:b.id))),{size:s,components:{root:"span",label:H,infoButton:Mt},root:g,label:f,infoButton:m}})(e,t);return(e=>{e.root.className=(0,a.z)("fui-InfoLabel",e.root.className);const t=Lt();e.label.className=(0,a.z)("fui-InfoLabel__label",t.base,e.label.className);const i=Bt();e.infoButton&&(e.infoButton.className=(0,a.z)("fui-InfoLabel__infoButton",i.base,"large"===e.size&&i.large,e.infoButton.className))})(i),(e=>((0,M.a)(e),(0,R.BX)(e.root,{children:[(0,R.tZ)(e.label,{}),e.infoButton&&(0,R.tZ)(e.infoButton,{})]})))(i)}));Ft.displayName="InfoLabel";var Ut,Ht={exports:{}},$t={};Ht.exports=function(){if(Ut)return $t;Ut=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),r=Symbol.for("react.provider"),a=Symbol.for("react.context"),s=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),c=Symbol.for("react.memo"),d=Symbol.for("react.lazy"),u=Symbol.iterator,h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},p=Object.assign,g={};function f(e,t,i){this.props=e,this.context=t,this.refs=g,this.updater=i||h}function m(){}function v(e,t,i){this.props=e,this.context=t,this.refs=g,this.updater=i||h}f.prototype.isReactComponent={},f.prototype.setState=function(e,t){if("object"!=typeof e&&"function"!=typeof e&&null!=e)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")},f.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},m.prototype=f.prototype;var y=v.prototype=new m;y.constructor=v,p(y,f.prototype),y.isPureReactComponent=!0;var C=Array.isArray,b=Object.prototype.hasOwnProperty,S={current:null},x={key:!0,ref:!0,__self:!0,__source:!0};function T(t,i,n){var o,r={},a=null,s=null;if(null!=i)for(o in void 0!==i.ref&&(s=i.ref),void 0!==i.key&&(a=""+i.key),i)b.call(i,o)&&!x.hasOwnProperty(o)&&(r[o]=i[o]);var l=arguments.length-2;if(1===l)r.children=n;else if(1<l){for(var c=Array(l),d=0;d<l;d++)c[d]=arguments[d+2];r.children=c}if(t&&t.defaultProps)for(o in l=t.defaultProps)void 0===r[o]&&(r[o]=l[o]);return{$$typeof:e,type:t,key:a,ref:s,props:r,_owner:S.current}}function w(t){return"object"==typeof t&&null!==t&&t.$$typeof===e}var O=/\/+/g;function P(e,t){return"object"==typeof e&&null!==e&&null!=e.key?function(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,(function(e){return t[e]}))}(""+e.key):t.toString(36)}function A(i,n,o,r,a){var s=typeof i;"undefined"!==s&&"boolean"!==s||(i=null);var l=!1;if(null===i)l=!0;else switch(s){case"string":case"number":l=!0;break;case"object":switch(i.$$typeof){case e:case t:l=!0}}if(l)return a=a(l=i),i=""===r?"."+P(l,0):r,C(a)?(o="",null!=i&&(o=i.replace(O,"$&/")+"/"),A(a,n,o,"",(function(e){return e}))):null!=a&&(w(a)&&(a=function(t,i){return{$$typeof:e,type:t.type,key:i,ref:t.ref,props:t.props,_owner:t._owner}}(a,o+(!a.key||l&&l.key===a.key?"":(""+a.key).replace(O,"$&/")+"/")+i)),n.push(a)),1;if(l=0,r=""===r?".":r+":",C(i))for(var c=0;c<i.length;c++){var d=r+P(s=i[c],c);l+=A(s,n,o,d,a)}else if(d=function(e){return null===e||"object"!=typeof e?null:"function"==typeof(e=u&&e[u]||e["@@iterator"])?e:null}(i),"function"==typeof d)for(i=d.call(i),c=0;!(s=i.next()).done;)l+=A(s=s.value,n,o,d=r+P(s,c++),a);else if("object"===s)throw n=String(i),Error("Objects are not valid as a React child (found: "+("[object Object]"===n?"object with keys {"+Object.keys(i).join(", ")+"}":n)+"). If you meant to render a collection of children, use an array instead.");return l}function E(e,t,i){if(null==e)return e;var n=[],o=0;return A(e,n,"","",(function(e){return t.call(i,e,o++)})),n}function k(e){if(-1===e._status){var t=e._result;(t=t()).then((function(t){0!==e._status&&-1!==e._status||(e._status=1,e._result=t)}),(function(t){0!==e._status&&-1!==e._status||(e._status=2,e._result=t)})),-1===e._status&&(e._status=0,e._result=t)}if(1===e._status)return e._result.default;throw e._result}var I={current:null},D={transition:null},_={ReactCurrentDispatcher:I,ReactCurrentBatchConfig:D,ReactCurrentOwner:S};return $t.Children={map:E,forEach:function(e,t,i){E(e,(function(){t.apply(this,arguments)}),i)},count:function(e){var t=0;return E(e,(function(){t++})),t},toArray:function(e){return E(e,(function(e){return e}))||[]},only:function(e){if(!w(e))throw Error("React.Children.only expected to receive a single React element child.");return e}},$t.Component=f,$t.Fragment=i,$t.Profiler=o,$t.PureComponent=v,$t.StrictMode=n,$t.Suspense=l,$t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=_,$t.cloneElement=function(t,i,n){if(null==t)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+t+".");var o=p({},t.props),r=t.key,a=t.ref,s=t._owner;if(null!=i){if(void 0!==i.ref&&(a=i.ref,s=S.current),void 0!==i.key&&(r=""+i.key),t.type&&t.type.defaultProps)var l=t.type.defaultProps;for(c in i)b.call(i,c)&&!x.hasOwnProperty(c)&&(o[c]=void 0===i[c]&&void 0!==l?l[c]:i[c])}var c=arguments.length-2;if(1===c)o.children=n;else if(1<c){l=Array(c);for(var d=0;d<c;d++)l[d]=arguments[d+2];o.children=l}return{$$typeof:e,type:t.type,key:r,ref:a,props:o,_owner:s}},$t.createContext=function(e){return(e={$$typeof:a,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null}).Provider={$$typeof:r,_context:e},e.Consumer=e},$t.createElement=T,$t.createFactory=function(e){var t=T.bind(null,e);return t.type=e,t},$t.createRef=function(){return{current:null}},$t.forwardRef=function(e){return{$$typeof:s,render:e}},$t.isValidElement=w,$t.lazy=function(e){return{$$typeof:d,_payload:{_status:-1,_result:e},_init:k}},$t.memo=function(e,t){return{$$typeof:c,type:e,compare:void 0===t?null:t}},$t.startTransition=function(e){var t=D.transition;D.transition={};try{e()}finally{D.transition=t}},$t.unstable_act=function(){throw Error("act(...) is not supported in production builds of React.")},$t.useCallback=function(e,t){return I.current.useCallback(e,t)},$t.useContext=function(e){return I.current.useContext(e)},$t.useDebugValue=function(){},$t.useDeferredValue=function(e){return I.current.useDeferredValue(e)},$t.useEffect=function(e,t){return I.current.useEffect(e,t)},$t.useId=function(){return I.current.useId()},$t.useImperativeHandle=function(e,t,i){return I.current.useImperativeHandle(e,t,i)},$t.useInsertionEffect=function(e,t){return I.current.useInsertionEffect(e,t)},$t.useLayoutEffect=function(e,t){return I.current.useLayoutEffect(e,t)},$t.useMemo=function(e,t){return I.current.useMemo(e,t)},$t.useReducer=function(e,t,i){return I.current.useReducer(e,t,i)},$t.useRef=function(e){return I.current.useRef(e)},$t.useState=function(e){return I.current.useState(e)},$t.useSyncExternalStore=function(e,t,i){return I.current.useSyncExternalStore(e,t,i)},$t.useTransition=function(){return I.current.useTransition()},$t.version="18.2.0",$t}();var Zt=function(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}(Ht.exports);function Vt(e){return Vt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Vt(e)}function Gt(e){var t=function(e,t){if("object"!==Vt(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==Vt(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Vt(t)?t:String(t)}function jt(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function zt(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?jt(Object(i),!0).forEach((function(t){var n,o,r;n=e,o=t,r=i[t],(o=Gt(o))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):jt(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var Wt=(0,S.Z)({container:{display:"flex",flexDirection:"row",alignItems:"center",columnGap:N.T.spacingHorizontalXXS},priceXSmall:zt(zt({},x.w.caption2),{},{lineHeight:"unset"}),priceSmall:zt(zt({},x.w.caption1Strong),{},{lineHeight:"unset"}),priceMedium:zt(zt({},x.w.subtitle2),{},{lineHeight:"unset"}),priceLarge:zt({},x.w.title2),priceXLarge:zt(zt({},x.w.largeTitle),{},{lineHeight:"unset"}),conteinerSmall:{height:"12px"},conteinerMedium:{height:"16px"},conteinerLarge:{height:"28px"},label:{display:"flex",flexDirection:"row",justifyContent:"left",alignItems:"baseline",columnGap:N.T.spacingHorizontalS},labelContainer:{display:"flex",flexDirection:"row",columnGap:N.T.spacingHorizontalXS},labelContainerNoChange:{display:"flex",flexDirection:"row",columnGap:N.T.spacingHorizontalXS},infoLabel:{},icon:{display:"flex"},title:{display:"flex",flexDirection:"row",columnGap:N.T.spacingHorizontalXS},priceLabelSmall:zt({},x.w.body1),priceLabelMedium:zt({},x.w.body1),priceLabelLarge:zt({},x.w.subtitle2),priceNoChangeLabel:{paddingLeft:N.T.spacingHorizontalXS,color:N.T.colorNeutralForeground1},priceChangeLabel:{color:N.T.colorNeutralForeground1}}),Kt=function(e){var t=e.size,i=e.hideIcon,n=e.hidePercent,o=e.percentDigits,r=e.price,s=e.priceChangePercentage,l=void 0===s?0:s,c=e.label,C=e.currency,S=e.locale,x=e.infoLabel,T=e.infoLabelIconSize,w=e.infoLabelWidth,O=e.infoLabelInline,P=e.infoLabelOpen,A=e.infoLabelBoundaryRef,E=e.infoLabelOnChange,k=e.showCents,I=e.showCurrency,D=e.showRaisedCents,R=(0,b.useSharedColors)(),M=Wt(),L=l>0,B=0!==l,F=Math.abs(l).toFixed(o),U=new Map([["small",M.priceSmall],["medium",M.priceMedium],["large",M.priceLarge]]),H=new Map([["small",M.priceLabelSmall],["medium",M.priceLabelMedium],["large",M.priceLabelLarge]]),$=new Map([["small",M.conteinerSmall],["medium",M.conteinerMedium],["large",M.conteinerLarge]]),Z=(0,a.z)(M.icon,B?L?R.priceAccentPrimary:R.priceAccentSecondary:N.T.colorBrandForeground1),V=(0,a.z)($.get(t),M.container),G=(0,a.z)(B?M.labelContainer:M.labelContainerNoChange),j=(0,a.z)(U.get(t),L?R.priceAccentPrimary:R.priceAccentSecondary),z=(0,a.z)(H.get(t),B?M.priceChangeLabel:M.priceNoChangeLabel),W=r&&"0"!==F;return Zt.createElement("div",{className:V},!i&&function(e,t){var i=Zt.createElement(Zt.Fragment,null);switch(e){case"small":"up"===t?i=Zt.createElement(m,{className:Z}):"down"===t?i=Zt.createElement(d,{className:Z}):"right"===t&&(i=Zt.createElement(p,{color:N.T.colorBrandForeground1}));break;case"medium":"up"===t?i=Zt.createElement(v,{className:Z}):"down"===t?i=Zt.createElement(u,{className:Z}):"right"===t&&(i=Zt.createElement(g,{color:N.T.colorBrandForeground1}));break;case"large":"up"===t?i=Zt.createElement(y,{className:Z}):"down"===t?i=Zt.createElement(h,{className:Z}):"right"===t&&(i=Zt.createElement(f,{color:N.T.colorBrandForeground1}))}return i}(t,B?L?"down":"up":"right"),Zt.createElement("div",{className:M.label},r&&B&&Zt.createElement(_,{value:r,showRaisedCents:D,color:L?"accent-primary":"accent-secondary",size:t,currency:C,locale:S,showCents:k,showCurrency:I}),!n&&B&&Zt.createElement("div",{className:j},W&&"(",F,"%",W&&")"),Zt.createElement("div",{className:G},Zt.createElement("div",{className:z},c),""!==x&&Zt.createElement("div",{className:M.infoLabel},Zt.createElement(Ft,{infoButton:{popover:{onOpenChange:function(e,t){return E&&void 0!==E&&E(e,t)},positioning:{position:"below",flipBoundary:A,overflowBoundary:A},closeOnScroll:!0,inline:O,unstable_disableAutoFocus:!0,trapFocus:!1,legacyTrapFocus:!1,mouseLeaveDelay:0,open:!!P||void 0}},info:{style:{zIndex:1},"aria-label":x,children:Zt.createElement("div",{"aria-label":x,style:{width:A?A.clientWidth-40:w&&w}},x)},size:T||t})))))};Kt.defaultProps={percentDigits:0,priceChangePercentage:0,hideIcon:!1,hidePercent:!1,showCents:!0,showCurrency:!0,showRaisedCents:!1,size:"medium",infoLabel:"",infoLabelOnHover:!0,infoLabelOpen:!1,infoLabelInline:!1,infoLabelBoundaryRef:null}},66202:function(e,t,i){"use strict";i.r(t),i.d(t,{PriceHistory:function(){return La}});var n=i(33680),o=i.n(n),r=i(8559),a=i(43763),s=i(85075),l=i.n(s),c=i(98374),d=i.n(c),u=function(e,t){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var i in t)t.hasOwnProperty(i)&&(e[i]=t[i])},u(e,t)};var h=function(e){return"function"==typeof e},p=function(){return"undefined"==typeof window},g=function(e){return e instanceof Element||e instanceof HTMLDocument},f=function(e){function t(t){var i=e.call(this,t)||this;i.cancelHandler=function(){i.resizeHandler&&i.resizeHandler.cancel&&(i.resizeHandler.cancel(),i.resizeHandler=null)},i.attachObserver=function(){var e=i.props,t=e.targetRef,n=e.observerOptions;if(!p()){t&&t.current&&(i.targetRef.current=t.current);var o=i.getElement();o&&(i.observableElement&&i.observableElement===o||(i.observableElement=o,i.resizeObserver.observe(o,n)))}},i.getElement=function(){var e=i.props,t=e.querySelector,n=e.targetDomEl;if(p())return null;if(t)return document.querySelector(t);if(n&&g(n))return n;if(i.targetRef&&g(i.targetRef.current))return i.targetRef.current;var o=(0,a.findDOMNode)(i);if(!o)return null;switch(i.getRenderType()){case"renderProp":case"childFunction":case"child":case"childArray":return o;default:return o.parentElement}},i.createResizeHandler=function(e){var t=i.props,n=t.handleWidth,o=void 0===n||n,r=t.handleHeight,a=void 0===r||r,s=t.onResize;if(o||a){var l=function(e,t,i){return function(n){var o=n.width,r=n.height;e((function(e){return e.width===o&&e.height===r||e.width===o&&!i||e.height===r&&!t?e:{width:o,height:r}}))}}((function(e){return i.setState(e,(function(){return null==s?void 0:s(i.state.width,i.state.height)}))}),o,a);e.forEach((function(e){var t=e&&e.contentRect||{},n=t.width,o=t.height;!i.skipOnMount&&!p()&&l({width:n,height:o}),i.skipOnMount=!1}))}},i.getRenderType=function(){var e=i.props,t=e.render,n=e.children;return h(t)?"renderProp":h(n)?"childFunction":(0,r.isValidElement)(n)?"child":Array.isArray(n)?"childArray":"parent"};var n=t.skipOnMount,o=t.refreshMode,s=t.refreshRate,c=void 0===s?1e3:s,u=t.refreshOptions;return i.state={width:void 0,height:void 0},i.skipOnMount=n,i.targetRef=(0,r.createRef)(),i.observableElement=null,p()||(i.resizeHandler=function(e,t,i,n){switch(t){case"debounce":return l()(e,i,n);case"throttle":return d()(e,i,n);default:return e}}(i.createResizeHandler,o,c,u),i.resizeObserver=new window.ResizeObserver(i.resizeHandler)),i}return function(e,t){function i(){this.constructor=e}u(e,t),e.prototype=null===t?Object.create(t):(i.prototype=t.prototype,new i)}(t,e),t.prototype.componentDidMount=function(){this.attachObserver()},t.prototype.componentDidUpdate=function(){this.attachObserver()},t.prototype.componentWillUnmount=function(){p()||(this.observableElement=null,this.resizeObserver.disconnect(),this.cancelHandler())},t.prototype.render=function(){var e=this.props,t=e.render,i=e.children,n=e.nodeType,o=void 0===n?"div":n,a=this.state,s={width:a.width,height:a.height,targetRef:this.targetRef};switch(this.getRenderType()){case"renderProp":return null==t?void 0:t(s);case"childFunction":return null==i?void 0:i(s);case"child":var l=i;if(l.type&&"string"==typeof l.type){var c=function(e,t){var i={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(i[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(i[n[o]]=e[n[o]])}return i}(s,["targetRef"]);return(0,r.cloneElement)(l,c)}return(0,r.cloneElement)(l,s);case"childArray":return i.map((function(e){return!!e&&(0,r.cloneElement)(e,s)}));default:return r.createElement(o,null)}},t}(r.PureComponent);p()?r.useEffect:r.useLayoutEffect;var m=i(71758),v=i.n(m),y=i(83008),C=i.n(y),b=i(68014),S=i.n(b),x=i(82265),T=i.n(x),w=i(12343),O=i.n(w),P=function(e){return O()(e)&&e.indexOf("%")===e.length-1},A=function(e){return T()(e)&&!S()(e)},E=function(e){return A(e)||O()(e)},k=0,I=function(e){var t=++k;return"".concat(e||"").concat(t)},D=function(e,t){var i,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,o=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(!A(e)&&!O()(e))return n;if(P(e)){var r=e.indexOf("%");i=t*parseFloat(e.slice(0,r))/100}else i=+e;return S()(i)&&(i=n),o&&i>t&&(i=t),i},_=function(e,t){return A(e)&&A(t)?function(i){return e+i*(t-e)}:function(){return t}},N=function(e,t){for(var i=arguments.length,n=new Array(i>2?i-2:0),o=2;o<i;o++)n[o-2]=arguments[o]};function R(e){return R="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},R(e)}function M(){return M=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},M.apply(this,arguments)}function L(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function B(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?L(Object(i),!0).forEach((function(t){var n,o,r;n=e,o=t,r=i[t],(o=function(e){var t=function(e,t){if("object"!==R(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==R(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===R(t)?t:String(t)}(o))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):L(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function F(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}var U=(0,r.forwardRef)((function(e,t){var i,n,a=e.aspect,s=e.initialDimension,l=void 0===s?{width:-1,height:-1}:s,c=e.width,d=void 0===c?"100%":c,u=e.height,h=void 0===u?"100%":u,p=e.minWidth,g=void 0===p?0:p,m=e.minHeight,v=e.maxHeight,y=e.children,C=e.debounce,b=void 0===C?0:C,S=e.id,x=e.className,T=e.onResize,w=e.style,O=void 0===w?{}:w,A=(i=(0,r.useState)({containerWidth:l.width,containerHeight:l.height}),n=2,function(e){if(Array.isArray(e))return e}(i)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var n,o,r,a,s=[],l=!0,c=!1;try{if(r=(i=i.call(e)).next,0===t){if(Object(i)!==i)return;l=!1}else for(;!(l=(n=r.call(i)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=i.return&&(a=i.return(),Object(a)!==a))return}finally{if(c)throw o}}return s}}(i,n)||function(e,t){if(e){if("string"==typeof e)return F(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?F(e,t):void 0}}(i,n)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),E=A[0],k=A[1],I=(0,r.useRef)(null);(0,r.useImperativeHandle)(t,(function(){return I}),[I]);var D=(0,r.useCallback)((function(){return I.current?{containerWidth:I.current.clientWidth,containerHeight:I.current.clientHeight}:null}),[]),_=(0,r.useCallback)((function(){var e=D();if(e){var t=e.containerWidth,i=e.containerHeight;T&&T(t,i),k((function(e){var n=e.containerWidth,o=e.containerHeight;return t!==n||i!==o?{containerWidth:t,containerHeight:i}:e}))}}),[D,T]),R=(0,r.useMemo)((function(){var e=E.containerWidth,t=E.containerHeight;if(e<0||t<0)return null;N(P(d)||P(h),"The width(%s) and height(%s) are both fixed numbers,\n maybe you don't need to use a ResponsiveContainer.",d,h),N(!a||a>0,"The aspect(%s) must be greater than zero.",a);var i=P(d)?e:d,n=P(h)?t:h;return a&&a>0&&(i?n=i/a:n&&(i=n*a),v&&n>v&&(n=v)),N(i>0||n>0,"The width(%s) and height(%s) of chart should be greater than 0,\n please check the style of container, or the props width(%s) and height(%s),\n or add a minWidth(%s) or minHeight(%s) or use aspect(%s) to control the\n height and width.",i,n,d,h,g,m,a),(0,r.cloneElement)(y,{width:i,height:n})}),[a,y,h,v,m,g,E,d]);(0,r.useEffect)((function(){var e=D();e&&k(e)}),[D]);var L=B(B({},O),{},{width:d,height:h,minWidth:g,minHeight:m,maxHeight:v});return r.createElement(f,{handleWidth:!0,handleHeight:!0,onResize:_,targetRef:I,refreshMode:b>0?"debounce":void 0,refreshRate:b},r.createElement("div",M({},null!=S?{id:"".concat(S)}:{},{className:o()("recharts-responsive-container",x),style:L,ref:I}),R))})),H=i(40825),$=i.n(H),Z=i(63991),V=i.n(Z),G=i(18562),j=i.n(G),z=i(37787),W=["aria-activedescendant","aria-atomic","aria-autocomplete","aria-busy","aria-checked","aria-colcount","aria-colindex","aria-colspan","aria-controls","aria-current","aria-describedby","aria-details","aria-disabled","aria-errormessage","aria-expanded","aria-flowto","aria-haspopup","aria-hidden","aria-invalid","aria-keyshortcuts","aria-label","aria-labelledby","aria-level","aria-live","aria-modal","aria-multiline","aria-multiselectable","aria-orientation","aria-owns","aria-placeholder","aria-posinset","aria-pressed","aria-readonly","aria-relevant","aria-required","aria-roledescription","aria-rowcount","aria-rowindex","aria-rowspan","aria-selected","aria-setsize","aria-sort","aria-valuemax","aria-valuemin","aria-valuenow","aria-valuetext","className","color","height","id","lang","max","media","method","min","name","style","target","width","role","tabIndex","accentHeight","accumulate","additive","alignmentBaseline","allowReorder","alphabetic","amplitude","arabicForm","ascent","attributeName","attributeType","autoReverse","azimuth","baseFrequency","baselineShift","baseProfile","bbox","begin","bias","by","calcMode","capHeight","clip","clipPath","clipPathUnits","clipRule","colorInterpolation","colorInterpolationFilters","colorProfile","colorRendering","contentScriptType","contentStyleType","cursor","cx","cy","d","decelerate","descent","diffuseConstant","direction","display","divisor","dominantBaseline","dur","dx","dy","edgeMode","elevation","enableBackground","end","exponent","externalResourcesRequired","fill","fillOpacity","fillRule","filter","filterRes","filterUnits","floodColor","floodOpacity","focusable","fontFamily","fontSize","fontSizeAdjust","fontStretch","fontStyle","fontVariant","fontWeight","format","from","fx","fy","g1","g2","glyphName","glyphOrientationHorizontal","glyphOrientationVertical","glyphRef","gradientTransform","gradientUnits","hanging","horizAdvX","horizOriginX","href","ideographic","imageRendering","in2","in","intercept","k1","k2","k3","k4","k","kernelMatrix","kernelUnitLength","kerning","keyPoints","keySplines","keyTimes","lengthAdjust","letterSpacing","lightingColor","limitingConeAngle","local","markerEnd","markerHeight","markerMid","markerStart","markerUnits","markerWidth","mask","maskContentUnits","maskUnits","mathematical","mode","numOctaves","offset","opacity","operator","order","orient","orientation","origin","overflow","overlinePosition","overlineThickness","paintOrder","panose1","pathLength","patternContentUnits","patternTransform","patternUnits","pointerEvents","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","r","radius","refX","refY","renderingIntent","repeatCount","repeatDur","requiredExtensions","requiredFeatures","restart","result","rotate","rx","ry","seed","shapeRendering","slope","spacing","specularConstant","specularExponent","speed","spreadMethod","startOffset","stdDeviation","stemh","stemv","stitchTiles","stopColor","stopOpacity","strikethroughPosition","strikethroughThickness","string","stroke","strokeDasharray","strokeDashoffset","strokeLinecap","strokeLinejoin","strokeMiterlimit","strokeOpacity","strokeWidth","surfaceScale","systemLanguage","tableValues","targetX","targetY","textAnchor","textDecoration","textLength","textRendering","to","transform","u1","u2","underlinePosition","underlineThickness","unicode","unicodeBidi","unicodeRange","unitsPerEm","vAlphabetic","values","vectorEffect","version","vertAdvY","vertOriginX","vertOriginY","vHanging","vIdeographic","viewTarget","visibility","vMathematical","widths","wordSpacing","writingMode","x1","x2","x","xChannelSelector","xHeight","xlinkActuate","xlinkArcrole","xlinkHref","xlinkRole","xlinkShow","xlinkTitle","xlinkType","xmlBase","xmlLang","xmlns","xmlnsXlink","xmlSpace","y1","y2","y","yChannelSelector","z","zoomAndPan","ref","key","angle"],K=["points","pathLength"],q={svg:["viewBox","children"],polygon:K,polyline:K},Y=["dangerouslySetInnerHTML","onCopy","onCopyCapture","onCut","onCutCapture","onPaste","onPasteCapture","onCompositionEnd","onCompositionEndCapture","onCompositionStart","onCompositionStartCapture","onCompositionUpdate","onCompositionUpdateCapture","onFocus","onFocusCapture","onBlur","onBlurCapture","onChange","onChangeCapture","onBeforeInput","onBeforeInputCapture","onInput","onInputCapture","onReset","onResetCapture","onSubmit","onSubmitCapture","onInvalid","onInvalidCapture","onLoad","onLoadCapture","onError","onErrorCapture","onKeyDown","onKeyDownCapture","onKeyPress","onKeyPressCapture","onKeyUp","onKeyUpCapture","onAbort","onAbortCapture","onCanPlay","onCanPlayCapture","onCanPlayThrough","onCanPlayThroughCapture","onDurationChange","onDurationChangeCapture","onEmptied","onEmptiedCapture","onEncrypted","onEncryptedCapture","onEnded","onEndedCapture","onLoadedData","onLoadedDataCapture","onLoadedMetadata","onLoadedMetadataCapture","onLoadStart","onLoadStartCapture","onPause","onPauseCapture","onPlay","onPlayCapture","onPlaying","onPlayingCapture","onProgress","onProgressCapture","onRateChange","onRateChangeCapture","onSeeked","onSeekedCapture","onSeeking","onSeekingCapture","onStalled","onStalledCapture","onSuspend","onSuspendCapture","onTimeUpdate","onTimeUpdateCapture","onVolumeChange","onVolumeChangeCapture","onWaiting","onWaitingCapture","onAuxClick","onAuxClickCapture","onClick","onClickCapture","onContextMenu","onContextMenuCapture","onDoubleClick","onDoubleClickCapture","onDrag","onDragCapture","onDragEnd","onDragEndCapture","onDragEnter","onDragEnterCapture","onDragExit","onDragExitCapture","onDragLeave","onDragLeaveCapture","onDragOver","onDragOverCapture","onDragStart","onDragStartCapture","onDrop","onDropCapture","onMouseDown","onMouseDownCapture","onMouseEnter","onMouseLeave","onMouseMove","onMouseMoveCapture","onMouseOut","onMouseOutCapture","onMouseOver","onMouseOverCapture","onMouseUp","onMouseUpCapture","onSelect","onSelectCapture","onTouchCancel","onTouchCancelCapture","onTouchEnd","onTouchEndCapture","onTouchMove","onTouchMoveCapture","onTouchStart","onTouchStartCapture","onPointerDown","onPointerDownCapture","onPointerMove","onPointerMoveCapture","onPointerUp","onPointerUpCapture","onPointerCancel","onPointerCancelCapture","onPointerEnter","onPointerEnterCapture","onPointerLeave","onPointerLeaveCapture","onPointerOver","onPointerOverCapture","onPointerOut","onPointerOutCapture","onGotPointerCapture","onGotPointerCaptureCapture","onLostPointerCapture","onLostPointerCaptureCapture","onScroll","onScrollCapture","onWheel","onWheelCapture","onAnimationStart","onAnimationStartCapture","onAnimationEnd","onAnimationEndCapture","onAnimationIteration","onAnimationIterationCapture","onTransitionEnd","onTransitionEndCapture"],X=function(e,t){if(!e||"function"==typeof e||"boolean"==typeof e)return null;var i=e;if((0,r.isValidElement)(e)&&(i=e.props),!V()(i))return null;var n={};return Object.keys(i).forEach((function(e){Y.includes(e)&&(n[e]=t||function(t){return i[e](i,t)})})),n};function J(e){return J="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},J(e)}var Q=function(e){return"string"==typeof e?e:e?e.displayName||e.name||"Component":""},ee=null,te=null,ie=function e(t){if(t===ee&&C()(te))return te;var i=[];return r.Children.forEach(t,(function(t){j()(t)||((0,z.isFragment)(t)?i=i.concat(e(t.props.children)):i.push(t))})),te=i,ee=t,i};function ne(e,t){var i=[],n=[];return n=C()(t)?t.map((function(e){return Q(e)})):[Q(t)],ie(e).forEach((function(e){var t=v()(e,"type.displayName")||v()(e,"type.name");-1!==n.indexOf(t)&&i.push(e)})),i}var oe=function(e,t,i){if(!e||"function"==typeof e||"boolean"==typeof e)return null;var n=e;if((0,r.isValidElement)(e)&&(n=e.props),!V()(n))return null;var o={};return Object.keys(n).forEach((function(e){var r;(function(e,t,i,n){var o,r=null!==(o=null==q?void 0:q[n])&&void 0!==o?o:[];return!$()(e)&&(n&&r.includes(t)||W.includes(t))||i&&Y.includes(t)})(null===(r=n)||void 0===r?void 0:r[e],e,t,i)&&(o[e]=n[e])})),o},re=["x1","y1","x2","y2","key"],ae=["offset"];function se(e){return se="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},se(e)}function le(){return le=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},le.apply(this,arguments)}function ce(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}function de(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function ue(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?de(Object(i),!0).forEach((function(t){fe(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):de(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function he(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,me(n.key),n)}}function pe(e,t){return pe=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},pe(e,t)}function ge(e){return ge=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},ge(e)}function fe(e,t,i){return(t=me(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function me(e){var t=function(e,t){if("object"!==se(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==se(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===se(t)?t:String(t)}var ve=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&pe(e,t)}(l,e);var t,i,n,o,a,s=(o=l,a=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=ge(o);if(a){var i=ge(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===se(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(this,e)});function l(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,l),s.apply(this,arguments)}return t=l,n=[{key:"renderLineItem",value:function(e,t){var i;if(r.isValidElement(e))i=r.cloneElement(e,t);else if($()(e))i=e(t);else{var n=t.x1,o=t.y1,a=t.x2,s=t.y2,l=t.key,c=ce(t,re),d=oe(c),u=(d.offset,ce(d,ae));i=r.createElement("line",le({},u,{x1:n,y1:o,x2:a,y2:s,fill:"none",key:l}))}return i}}],(i=[{key:"renderHorizontal",value:function(e){var t=this,i=this.props,n=i.x,o=i.width,a=i.horizontal;if(!e||!e.length)return null;var s=e.map((function(e,i){var r=ue(ue({},t.props),{},{x1:n,y1:e,x2:n+o,y2:e,key:"line-".concat(i),index:i});return l.renderLineItem(a,r)}));return r.createElement("g",{className:"recharts-cartesian-grid-horizontal"},s)}},{key:"renderVertical",value:function(e){var t=this,i=this.props,n=i.y,o=i.height,a=i.vertical;if(!e||!e.length)return null;var s=e.map((function(e,i){var r=ue(ue({},t.props),{},{x1:e,y1:n,x2:e,y2:n+o,key:"line-".concat(i),index:i});return l.renderLineItem(a,r)}));return r.createElement("g",{className:"recharts-cartesian-grid-vertical"},s)}},{key:"renderVerticalStripes",value:function(e){var t=this.props.verticalFill;if(!t||!t.length)return null;var i=this.props,n=i.fillOpacity,o=i.x,a=i.y,s=i.width,l=i.height,c=e.map((function(e){return Math.round(e+o-o)})).sort((function(e,t){return e-t}));o!==c[0]&&c.unshift(0);var d=c.map((function(e,i){var d=c[i+1]?c[i+1]-e:o+s-e;if(d<=0)return null;var u=i%t.length;return r.createElement("rect",{key:"react-".concat(i),x:e,y:a,width:d,height:l,stroke:"none",fill:t[u],fillOpacity:n,className:"recharts-cartesian-grid-bg"})}));return r.createElement("g",{className:"recharts-cartesian-gridstripes-vertical"},d)}},{key:"renderHorizontalStripes",value:function(e){var t=this.props.horizontalFill;if(!t||!t.length)return null;var i=this.props,n=i.fillOpacity,o=i.x,a=i.y,s=i.width,l=i.height,c=e.map((function(e){return Math.round(e+a-a)})).sort((function(e,t){return e-t}));a!==c[0]&&c.unshift(0);var d=c.map((function(e,i){var d=c[i+1]?c[i+1]-e:a+l-e;if(d<=0)return null;var u=i%t.length;return r.createElement("rect",{key:"react-".concat(i),y:e,x:o,height:d,width:s,stroke:"none",fill:t[u],fillOpacity:n,className:"recharts-cartesian-grid-bg"})}));return r.createElement("g",{className:"recharts-cartesian-gridstripes-horizontal"},d)}},{key:"renderBackground",value:function(){var e=this.props.fill;if(!e||"none"===e)return null;var t=this.props,i=t.fillOpacity,n=t.x,o=t.y,a=t.width,s=t.height;return r.createElement("rect",{x:n,y:o,width:a,height:s,stroke:"none",fill:e,fillOpacity:i,className:"recharts-cartesian-grid-bg"})}},{key:"render",value:function(){var e=this.props,t=e.x,i=e.y,n=e.width,o=e.height,a=e.horizontal,s=e.vertical,l=e.horizontalCoordinatesGenerator,c=e.verticalCoordinatesGenerator,d=e.xAxis,u=e.yAxis,h=e.offset,p=e.chartWidth,g=e.chartHeight,f=e.syncWithTicks,m=e.horizontalValues,v=e.verticalValues;if(!A(n)||n<=0||!A(o)||o<=0||!A(t)||t!==+t||!A(i)||i!==+i)return null;var y=this.props,C=y.horizontalPoints,b=y.verticalPoints;if((!C||!C.length)&&$()(l)){var S=m&&m.length;C=l({yAxis:u?ue(ue({},u),{},{ticks:S?m:u.ticks}):void 0,width:p,height:g,offset:h},!!S||f)}if((!b||!b.length)&&$()(c)){var x=v&&v.length;b=c({xAxis:d?ue(ue({},d),{},{ticks:x?v:d.ticks}):void 0,width:p,height:g,offset:h},!!x||f)}return r.createElement("g",{className:"recharts-cartesian-grid"},this.renderBackground(),a&&this.renderHorizontal(C),s&&this.renderVertical(b),a&&this.renderHorizontalStripes(C),s&&this.renderVerticalStripes(b))}}])&&he(t.prototype,i),n&&he(t,n),Object.defineProperty(t,"prototype",{writable:!1}),l}(r.PureComponent);fe(ve,"displayName","CartesianGrid"),fe(ve,"defaultProps",{horizontal:!0,vertical:!0,horizontalPoints:[],verticalPoints:[],stroke:"#ccc",fill:"none",verticalFill:[],horizontalFill:[]});var ye=function(){return null};ye.displayName="YAxis",ye.defaultProps={allowDuplicatedCategory:!0,allowDecimals:!0,hide:!1,orientation:"left",width:60,height:0,mirror:!1,yAxisId:0,tickCount:5,type:"number",padding:{top:0,bottom:0},allowDataOverflow:!1,scale:"auto",reversed:!1};var Ce=function(){return null};Ce.displayName="XAxis",Ce.defaultProps={allowDecimals:!0,hide:!1,orientation:"bottom",width:0,height:30,mirror:!1,xAxisId:0,tickCount:5,type:"category",padding:{left:0,right:0},allowDataOverflow:!1,scale:"auto",reversed:!1,allowDuplicatedCategory:!0};var be=i(37861),Se=i.n(be),xe=i(94563),Te=i.n(xe),we=i(90480),Oe=i(126),Pe=i.n(Oe);function Ae(){}function Ee(e,t,i){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+i)/6)}function ke(e){this._context=e}function Ie(e){this._context=e}function De(e){this._context=e}ke.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:Ee(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:Ee(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}},Ie.prototype={areaStart:Ae,areaEnd:Ae,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4)}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:Ee(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}},De.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var i=(this._x0+4*this._x1+e)/6,n=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(i,n):this._context.moveTo(i,n);break;case 3:this._point=4;default:Ee(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};class _e{constructor(e,t){this._context=e,this._x=t}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line}point(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._x?this._context.bezierCurveTo(this._x0=(this._x0+e)/2,this._y0,this._x0,t,e,t):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+t)/2,e,this._y0,e,t)}this._x0=e,this._y0=t}}function Ne(e){this._context=e}Ne.prototype={areaStart:Ae,areaEnd:Ae,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}};var Re=i(80561),Me=i(32439);function Le(e){this._context=e}function Be(e){var t,i,n=e.length-1,o=new Array(n),r=new Array(n),a=new Array(n);for(o[0]=0,r[0]=2,a[0]=e[0]+2*e[1],t=1;t<n-1;++t)o[t]=1,r[t]=4,a[t]=4*e[t]+2*e[t+1];for(o[n-1]=2,r[n-1]=7,a[n-1]=8*e[n-1]+e[n],t=1;t<n;++t)i=o[t]/r[t-1],r[t]-=i,a[t]-=i*a[t-1];for(o[n-1]=a[n-1]/r[n-1],t=n-2;t>=0;--t)o[t]=(a[t]-o[t+1])/r[t];for(r[n-1]=(e[n]+o[n-1])/2,t=0;t<n-1;++t)r[t]=2*e[t+1]-o[t+1];return[o,r]}function Fe(e,t){this._context=e,this._t=t}Le.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var e=this._x,t=this._y,i=e.length;if(i)if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),2===i)this._context.lineTo(e[1],t[1]);else for(var n=Be(e),o=Be(t),r=0,a=1;a<i;++r,++a)this._context.bezierCurveTo(n[0][r],o[0][r],n[1][r],o[1][r],e[a],t[a]);(this._line||0!==this._line&&1===i)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(e,t){this._x.push(+e),this._y.push(+t)}},Fe.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&2===this._point&&this._context.lineTo(this._x,this._y),(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var i=this._x*(1-this._t)+e*this._t;this._context.lineTo(i,this._y),this._context.lineTo(i,t)}}this._x=e,this._y=t}};var Ue=i(94070),He=i(97987),$e=i(69634),Ze=i(59945),Ve=i(87441);function Ge(e,t,i){var n=null,o=(0,He.Z)(!0),r=null,a=Re.Z,s=null,l=(0,Ze.d)(c);function c(c){var d,u,h,p,g,f=(c=(0,Ue.Z)(c)).length,m=!1,v=new Array(f),y=new Array(f);for(null==r&&(s=a(g=l())),d=0;d<=f;++d){if(!(d<f&&o(p=c[d],d,c))===m)if(m=!m)u=d,s.areaStart(),s.lineStart();else{for(s.lineEnd(),s.lineStart(),h=d-1;h>=u;--h)s.point(v[h],y[h]);s.lineEnd(),s.areaEnd()}m&&(v[d]=+e(p,d,c),y[d]=+t(p,d,c),s.point(n?+n(p,d,c):v[d],i?+i(p,d,c):y[d]))}if(g)return s=null,g+""||null}function d(){return(0,$e.Z)().defined(o).curve(a).context(r)}return e="function"==typeof e?e:void 0===e?Ve.x:(0,He.Z)(+e),t="function"==typeof t?t:void 0===t?(0,He.Z)(0):(0,He.Z)(+t),i="function"==typeof i?i:void 0===i?Ve.y:(0,He.Z)(+i),c.x=function(t){return arguments.length?(e="function"==typeof t?t:(0,He.Z)(+t),n=null,c):e},c.x0=function(t){return arguments.length?(e="function"==typeof t?t:(0,He.Z)(+t),c):e},c.x1=function(e){return arguments.length?(n=null==e?null:"function"==typeof e?e:(0,He.Z)(+e),c):n},c.y=function(e){return arguments.length?(t="function"==typeof e?e:(0,He.Z)(+e),i=null,c):t},c.y0=function(e){return arguments.length?(t="function"==typeof e?e:(0,He.Z)(+e),c):t},c.y1=function(e){return arguments.length?(i=null==e?null:"function"==typeof e?e:(0,He.Z)(+e),c):i},c.lineX0=c.lineY0=function(){return d().x(e).y(t)},c.lineY1=function(){return d().x(e).y(i)},c.lineX1=function(){return d().x(n).y(t)},c.defined=function(e){return arguments.length?(o="function"==typeof e?e:(0,He.Z)(!!e),c):o},c.curve=function(e){return arguments.length?(a=e,null!=r&&(s=a(r)),c):a},c.context=function(e){return arguments.length?(null==e?r=s=null:s=a(r=e),c):r},c}function je(e){return je="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},je(e)}function ze(){return ze=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},ze.apply(this,arguments)}function We(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Ke(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?We(Object(i),!0).forEach((function(t){var n,o,r;n=e,o=t,r=i[t],(o=function(e){var t=function(e,t){if("object"!==je(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==je(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===je(t)?t:String(t)}(o))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):We(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var qe={curveBasisClosed:function(e){return new Ie(e)},curveBasisOpen:function(e){return new De(e)},curveBasis:function(e){return new ke(e)},curveBumpX:function(e){return new _e(e,!0)},curveBumpY:function(e){return new _e(e,!1)},curveLinearClosed:function(e){return new Ne(e)},curveLinear:Re.Z,curveMonotoneX:Me.Z,curveMonotoneY:Me.s,curveNatural:function(e){return new Le(e)},curveStep:function(e){return new Fe(e,.5)},curveStepAfter:function(e){return new Fe(e,1)},curveStepBefore:function(e){return new Fe(e,0)}},Ye=function(e){return e.x===+e.x&&e.y===+e.y},Xe=function(e){return e.x},Je=function(e){return e.y},Qe=function(e){var t=e.className,i=e.points,n=e.path,a=e.pathRef;if(!(i&&i.length||n))return null;var s=i&&i.length?function(e){var t,i=e.type,n=void 0===i?"linear":i,o=e.points,r=void 0===o?[]:o,a=e.baseLine,s=e.layout,l=e.connectNulls,c=void 0!==l&&l,d=function(e,t){if($()(e))return e;var i="curve".concat(Pe()(e));return"curveMonotone"!==i&&"curveBump"!==i||!t?qe[i]||Re.Z:qe["".concat(i).concat("vertical"===t?"Y":"X")]}(n,s),u=c?r.filter((function(e){return Ye(e)})):r;if(C()(a)){var h=c?a.filter((function(e){return Ye(e)})):a,p=u.map((function(e,t){return Ke(Ke({},e),{},{base:h[t]})}));return(t="vertical"===s?Ge().y(Je).x1(Xe).x0((function(e){return e.base.x})):Ge().x(Xe).y1(Je).y0((function(e){return e.base.y}))).defined(Ye).curve(d),t(p)}return(t="vertical"===s&&A(a)?Ge().y(Je).x1(Xe).x0(a):A(a)?Ge().x(Xe).y1(Je).y0(a):(0,$e.Z)().x(Xe).y(Je)).defined(Ye).curve(d),t(u)}(e):n;return r.createElement("path",ze({},oe(e),X(e),{className:o()("recharts-curve",t),d:s,ref:a}))};function et(){return et=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},et.apply(this,arguments)}var tt=function(e){var t=e.cx,i=e.cy,n=e.r,a=e.className,s=o()("recharts-dot",a);return t===+t&&i===+i&&n===+n?r.createElement("circle",et({},oe(e),X(e),{className:s,cx:t,cy:i,r:n})):null},it=["children","className"];function nt(){return nt=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},nt.apply(this,arguments)}var ot=r.forwardRef((function(e,t){var i=e.children,n=e.className,a=function(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}(e,it),s=o()("recharts-layer",n);return r.createElement("g",nt({className:s},oe(a,!0),{ref:t}),i)})),rt=i(26295),at=i.n(rt),st={isSsr:!("undefined"!=typeof window&&window.document&&window.document.createElement&&window.setTimeout),get:function(e){return st[e]},set:function(e,t){if("string"==typeof e)st[e]=t;else{var i=Object.keys(e);i&&i.length&&i.forEach((function(t){st[t]=e[t]}))}}};function lt(e){return lt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},lt(e)}function ct(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function dt(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?ct(Object(i),!0).forEach((function(t){var n,o,r;n=e,o=t,r=i[t],(o=function(e){var t=function(e,t){if("object"!==lt(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==lt(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===lt(t)?t:String(t)}(o))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):ct(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function ut(e){return function(e){if(Array.isArray(e))return ht(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return ht(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?ht(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function ht(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}var pt={widthCache:{},cacheCount:0},gt={position:"absolute",top:"-20000px",left:0,padding:0,margin:0,border:"none",whiteSpace:"pre"},ft=["minWidth","maxWidth","width","minHeight","maxHeight","height","top","left","fontSize","lineHeight","padding","margin","paddingLeft","paddingRight","paddingTop","paddingBottom","marginLeft","marginRight","marginTop","marginBottom"],mt="recharts_measurement_span",vt=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(null==e||st.isSsr)return{width:0,height:0};var i="".concat(e),n=function(e){return Object.keys(e).reduce((function(t,i){return"".concat(t).concat((r=i,r.split("").reduce((function(e,t){return t===t.toUpperCase()?[].concat(ut(e),["-",t.toLowerCase()]):[].concat(ut(e),[t])}),[]).join("")),":").concat((n=i,o=e[i],ft.indexOf(n)>=0&&o===+o?"".concat(o,"px"):o),";");var n,o,r}),"")}(t),o="".concat(i,"-").concat(n);if(pt.widthCache[o])return pt.widthCache[o];try{var r=document.getElementById(mt);r||((r=document.createElement("span")).setAttribute("id",mt),r.setAttribute("aria-hidden","true"),document.body.appendChild(r));var a=dt(dt({},gt),t);Object.keys(a).map((function(e){return r.style[e]=a[e],e})),r.textContent=i;var s=r.getBoundingClientRect(),l={width:s.width,height:s.height};return pt.widthCache[o]=l,++pt.cacheCount>2e3&&(pt.cacheCount=0,pt.widthCache={}),l}catch(e){return{width:0,height:0}}};function yt(e){return yt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},yt(e)}function Ct(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var n,o,r,a,s=[],l=!0,c=!1;try{if(r=(i=i.call(e)).next,0===t){if(Object(i)!==i)return;l=!1}else for(;!(l=(n=r.call(i)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=i.return&&(a=i.return(),Object(a)!==a))return}finally{if(c)throw o}}return s}}(e,t)||function(e,t){if(e){if("string"==typeof e)return bt(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?bt(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function bt(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}function St(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,(void 0,o=function(e,t){if("object"!==yt(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==yt(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(n.key),"symbol"===yt(o)?o:String(o)),n)}var o}var xt=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([*/])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,Tt=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([+-])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,wt=/^px|cm|vh|vw|em|rem|%|mm|in|pt|pc|ex|ch|vmin|vmax|Q$/,Ot=/(-?\d+(?:\.\d+)?)([a-zA-Z%]+)?/,Pt={cm:96/2.54,mm:96/25.4,pt:96/72,pc:16,in:96,Q:96/101.6,px:1},At=Object.keys(Pt),Et="NaN",kt=function(){function e(t,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.num=t,this.unit=i,this.num=t,this.unit=i,Number.isNaN(t)&&(this.unit=""),""===i||wt.test(i)||(this.num=NaN,this.unit=""),At.includes(i)&&(this.num=function(e,t){return e*Pt[t]}(t,i),this.unit="px")}var t,i,n;return t=e,n=[{key:"parse",value:function(t){var i,n=Ct(null!==(i=Ot.exec(t))&&void 0!==i?i:[],3),o=n[1],r=n[2];return new e(parseFloat(o),null!=r?r:"")}}],(i=[{key:"add",value:function(t){return this.unit!==t.unit?new e(NaN,""):new e(this.num+t.num,this.unit)}},{key:"subtract",value:function(t){return this.unit!==t.unit?new e(NaN,""):new e(this.num-t.num,this.unit)}},{key:"multiply",value:function(t){return""!==this.unit&&""!==t.unit&&this.unit!==t.unit?new e(NaN,""):new e(this.num*t.num,this.unit||t.unit)}},{key:"divide",value:function(t){return""!==this.unit&&""!==t.unit&&this.unit!==t.unit?new e(NaN,""):new e(this.num/t.num,this.unit||t.unit)}},{key:"toString",value:function(){return"".concat(this.num).concat(this.unit)}},{key:"isNaN",value:function(){return Number.isNaN(this.num)}}])&&St(t.prototype,i),n&&St(t,n),Object.defineProperty(t,"prototype",{writable:!1}),e}();function It(e){if(e.includes(Et))return Et;for(var t=e;t.includes("*")||t.includes("/");){var i,n=Ct(null!==(i=xt.exec(t))&&void 0!==i?i:[],4),o=n[1],r=n[2],a=n[3],s=kt.parse(null!=o?o:""),l=kt.parse(null!=a?a:""),c="*"===r?s.multiply(l):s.divide(l);if(c.isNaN())return Et;t=t.replace(xt,c.toString())}for(;t.includes("+")||/.-\d+(?:\.\d+)?/.test(t);){var d,u=Ct(null!==(d=Tt.exec(t))&&void 0!==d?d:[],4),h=u[1],p=u[2],g=u[3],f=kt.parse(null!=h?h:""),m=kt.parse(null!=g?g:""),v="+"===p?f.add(m):f.subtract(m);if(v.isNaN())return Et;t=t.replace(Tt,v.toString())}return t}var Dt=/\(([^()]*)\)/;function _t(e){var t=function(e){try{return function(e){var t=e.replace(/\s+/g,"");return t=function(e){for(var t=e;t.includes("(");){var i=Ct(Dt.exec(t),2)[1];t=t.replace(Dt,It(i))}return t}(t),It(t)}(e)}catch(e){return Et}}(e.slice(5,-1));return t===Et?"":t}var Nt=["x","y","lineHeight","capHeight","scaleToFit","textAnchor","verticalAnchor","fill"],Rt=["dx","dy","angle","className","breakAll"];function Mt(){return Mt=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},Mt.apply(this,arguments)}function Lt(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}function Bt(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var n,o,r,a,s=[],l=!0,c=!1;try{if(r=(i=i.call(e)).next,0===t){if(Object(i)!==i)return;l=!1}else for(;!(l=(n=r.call(i)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=i.return&&(a=i.return(),Object(a)!==a))return}finally{if(c)throw o}}return s}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Ft(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?Ft(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Ft(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}var Ut=/[ \f\n\r\t\v\u2028\u2029]+/,Ht=function(e){var t=e.children,i=e.breakAll,n=e.style;try{var o=[];return j()(t)||(o=i?t.toString().split(""):t.toString().split(Ut)),{wordsWithComputedWidth:o.map((function(e){return{word:e,width:vt(e,n).width}})),spaceWidth:i?0:vt(" ",n).width}}catch(e){return null}},$t=function(e){return[{words:j()(e)?[]:e.toString().split(Ut)}]},Zt="#808080",Vt=function(e){var t=e.x,i=void 0===t?0:t,n=e.y,a=void 0===n?0:n,s=e.lineHeight,l=void 0===s?"1em":s,c=e.capHeight,d=void 0===c?"0.71em":c,u=e.scaleToFit,h=void 0!==u&&u,p=e.textAnchor,g=void 0===p?"start":p,f=e.verticalAnchor,m=void 0===f?"end":f,v=e.fill,y=void 0===v?Zt:v,C=Lt(e,Nt),b=(0,r.useMemo)((function(){return function(e){var t=e.width,i=e.scaleToFit,n=e.children,o=e.style,r=e.breakAll,a=e.maxLines;if((t||i)&&!st.isSsr){var s=Ht({breakAll:r,children:n,style:o});return s?function(e,t,i,n,o){var r=e.maxLines,a=e.children,s=e.style,l=e.breakAll,c=A(r),d=a,u=function(){return(arguments.length>0&&void 0!==arguments[0]?arguments[0]:[]).reduce((function(e,t){var r=t.word,a=t.width,s=e[e.length-1];if(s&&(null==n||o||s.width+a+i<Number(n)))s.words.push(r),s.width+=a+i;else{var l={words:[r],width:a};e.push(l)}return e}),[])},h=u(t);if(!c)return h;for(var p,g=function(e){var t=d.slice(0,e),i=Ht({breakAll:l,style:s,children:t+"…"}).wordsWithComputedWidth,o=u(i),a=o.length>r||function(e){return e.reduce((function(e,t){return e.width>t.width?e:t}))}(o).width>Number(n);return[a,o]},f=0,m=d.length-1,v=0;f<=m&&v<=d.length-1;){var y=Math.floor((f+m)/2),C=Bt(g(y-1),2),b=C[0],S=C[1],x=Bt(g(y),1)[0];if(b||x||(f=y+1),b&&x&&(m=y-1),!b&&x){p=S;break}v++}return p||h}({breakAll:r,children:n,maxLines:a,style:o},s.wordsWithComputedWidth,s.spaceWidth,t,i):$t(n)}return $t(n)}({breakAll:C.breakAll,children:C.children,maxLines:C.maxLines,scaleToFit:h,style:C.style,width:C.width})}),[C.breakAll,C.children,C.maxLines,h,C.style,C.width]),S=C.dx,x=C.dy,T=C.angle,w=C.className,O=C.breakAll,P=Lt(C,Rt);if(!E(i)||!E(a))return null;var k,I=i+(A(S)?S:0),D=a+(A(x)?x:0);switch(m){case"start":k=_t("calc(".concat(d,")"));break;case"middle":k=_t("calc(".concat((b.length-1)/2," * -").concat(l," + (").concat(d," / 2))"));break;default:k=_t("calc(".concat(b.length-1," * -").concat(l,")"))}var _=[];if(h){var N=b[0].width,R=C.width;_.push("scale(".concat((A(R)?R/N:1)/N,")"))}return T&&_.push("rotate(".concat(T,", ").concat(I,", ").concat(D,")")),_.length&&(P.transform=_.join(" ")),r.createElement("text",Mt({},oe(P,!0),{x:I,y:D,className:o()("recharts-text",w),textAnchor:g,fill:y.includes("url")?Zt:y}),b.map((function(e,t){return r.createElement("tspan",{x:I,dy:0===t?k:l,key:t},e.words.join(O?"":" "))})))},Gt=Math.PI/180,jt=function(e,t,i,n){return{x:e+Math.cos(-Gt*n)*i,y:t+Math.sin(-Gt*n)*i}};function zt(e){return zt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},zt(e)}var Wt=["offset"];function Kt(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}function qt(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Yt(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?qt(Object(i),!0).forEach((function(t){var n,o,r;n=e,o=t,r=i[t],(o=function(e){var t=function(e,t){if("object"!==zt(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==zt(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===zt(t)?t:String(t)}(o))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):qt(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function Xt(){return Xt=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},Xt.apply(this,arguments)}var Jt=function(e){var t=e.value,i=e.formatter,n=j()(e.children)?t:e.children;return $()(i)?i(n):n},Qt=function(e,t,i){var n,a,s=e.position,l=e.viewBox,c=e.offset,d=e.className,u=l,h=u.cx,p=u.cy,g=u.innerRadius,f=u.outerRadius,m=u.startAngle,v=u.endAngle,y=u.clockWise,C=(g+f)/2,b=function(e,t){var i;return(0==(i=t-e)?0:i>0?1:-1)*Math.min(Math.abs(t-e),360)}(m,v),S=b>=0?1:-1;"insideStart"===s?(n=m+S*c,a=y):"insideEnd"===s?(n=v-S*c,a=!y):"end"===s&&(n=v+S*c,a=y),a=b<=0?a:!a;var x=jt(h,p,C,n),T=jt(h,p,C,n+359*(a?1:-1)),w="M".concat(x.x,",").concat(x.y,"\n A").concat(C,",").concat(C,",0,1,").concat(a?0:1,",\n ").concat(T.x,",").concat(T.y),O=j()(e.id)?I("recharts-radial-line-"):e.id;return r.createElement("text",Xt({},i,{dominantBaseline:"central",className:o()("recharts-radial-bar-label",d)}),r.createElement("defs",null,r.createElement("path",{id:O,d:w})),r.createElement("textPath",{xlinkHref:"#".concat(O)},t))},ei=function(e){var t=e.viewBox,i=e.offset,n=e.position,o=t,r=o.cx,a=o.cy,s=o.innerRadius,l=o.outerRadius,c=(o.startAngle+o.endAngle)/2;if("outside"===n){var d=jt(r,a,l+i,c),u=d.x;return{x:u,y:d.y,textAnchor:u>=r?"start":"end",verticalAnchor:"middle"}}if("center"===n)return{x:r,y:a,textAnchor:"middle",verticalAnchor:"middle"};if("centerTop"===n)return{x:r,y:a,textAnchor:"middle",verticalAnchor:"start"};if("centerBottom"===n)return{x:r,y:a,textAnchor:"middle",verticalAnchor:"end"};var h=jt(r,a,(s+l)/2,c);return{x:h.x,y:h.y,textAnchor:"middle",verticalAnchor:"middle"}},ti=function(e){var t=e.viewBox,i=e.parentViewBox,n=e.offset,o=e.position,r=t,a=r.x,s=r.y,l=r.width,c=r.height,d=c>=0?1:-1,u=d*n,h=d>0?"end":"start",p=d>0?"start":"end",g=l>=0?1:-1,f=g*n,m=g>0?"end":"start",v=g>0?"start":"end";if("top"===o)return Yt(Yt({},{x:a+l/2,y:s-d*n,textAnchor:"middle",verticalAnchor:h}),i?{height:Math.max(s-i.y,0),width:l}:{});if("bottom"===o)return Yt(Yt({},{x:a+l/2,y:s+c+u,textAnchor:"middle",verticalAnchor:p}),i?{height:Math.max(i.y+i.height-(s+c),0),width:l}:{});if("left"===o){var y={x:a-f,y:s+c/2,textAnchor:m,verticalAnchor:"middle"};return Yt(Yt({},y),i?{width:Math.max(y.x-i.x,0),height:c}:{})}if("right"===o){var C={x:a+l+f,y:s+c/2,textAnchor:v,verticalAnchor:"middle"};return Yt(Yt({},C),i?{width:Math.max(i.x+i.width-C.x,0),height:c}:{})}var b=i?{width:l,height:c}:{};return"insideLeft"===o?Yt({x:a+f,y:s+c/2,textAnchor:v,verticalAnchor:"middle"},b):"insideRight"===o?Yt({x:a+l-f,y:s+c/2,textAnchor:m,verticalAnchor:"middle"},b):"insideTop"===o?Yt({x:a+l/2,y:s+u,textAnchor:"middle",verticalAnchor:p},b):"insideBottom"===o?Yt({x:a+l/2,y:s+c-u,textAnchor:"middle",verticalAnchor:h},b):"insideTopLeft"===o?Yt({x:a+f,y:s+u,textAnchor:v,verticalAnchor:p},b):"insideTopRight"===o?Yt({x:a+l-f,y:s+u,textAnchor:m,verticalAnchor:p},b):"insideBottomLeft"===o?Yt({x:a+f,y:s+c-u,textAnchor:v,verticalAnchor:h},b):"insideBottomRight"===o?Yt({x:a+l-f,y:s+c-u,textAnchor:m,verticalAnchor:h},b):V()(o)&&(A(o.x)||P(o.x))&&(A(o.y)||P(o.y))?Yt({x:a+D(o.x,l),y:s+D(o.y,c),textAnchor:"end",verticalAnchor:"end"},b):Yt({x:a+l/2,y:s+c/2,textAnchor:"middle",verticalAnchor:"middle"},b)},ii=function(e){return"cx"in e&&A(e.cx)};function ni(e){var t,i=e.offset,n=Yt({offset:void 0===i?5:i},function(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}(e,Wt)),a=n.viewBox,s=n.position,l=n.value,c=n.children,d=n.content,u=n.className,h=void 0===u?"":u,p=n.textBreakAll;if(!a||j()(l)&&j()(c)&&!(0,r.isValidElement)(d)&&!$()(d))return null;if((0,r.isValidElement)(d))return(0,r.cloneElement)(d,n);if($()(d)){if(t=(0,r.createElement)(d,n),(0,r.isValidElement)(t))return t}else t=Jt(n);var g=ii(a),f=oe(n,!0);if(g&&("insideStart"===s||"insideEnd"===s||"end"===s))return Qt(n,t,f);var m=g?ei(n):ti(n);return r.createElement(Vt,Xt({className:o()("recharts-label",h)},f,m,{breakAll:p}),t)}ni.displayName="Label";var oi=function(e){var t=e.cx,i=e.cy,n=e.angle,o=e.startAngle,r=e.endAngle,a=e.r,s=e.radius,l=e.innerRadius,c=e.outerRadius,d=e.x,u=e.y,h=e.top,p=e.left,g=e.width,f=e.height,m=e.clockWise,v=e.labelViewBox;if(v)return v;if(A(g)&&A(f)){if(A(d)&&A(u))return{x:d,y:u,width:g,height:f};if(A(h)&&A(p))return{x:h,y:p,width:g,height:f}}return A(d)&&A(u)?{x:d,y:u,width:0,height:0}:A(t)&&A(i)?{cx:t,cy:i,startAngle:o||n||0,endAngle:r||n||0,innerRadius:l||0,outerRadius:c||s||a||0,clockWise:m}:e.viewBox?e.viewBox:{}};function ri(e,t,i){return j()(e)||j()(t)?i:E(t)?v()(e,t,i):$()(t)?t(e):i}ni.parseViewBox=oi,ni.renderCallByParent=function(e,t){var i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];if(!e||!e.children&&i&&!e.label)return null;var n=e.children,o=oi(e),a=ne(n,ni).map((function(e,i){return(0,r.cloneElement)(e,{viewBox:t||o,key:"label-".concat(i)})}));if(!i)return a;var s,l=function(e,t){return e?!0===e?r.createElement(ni,{key:"label-implicit",viewBox:t}):E(e)?r.createElement(ni,{key:"label-implicit",viewBox:t,value:e}):(0,r.isValidElement)(e)?e.type===ni?(0,r.cloneElement)(e,{key:"label-implicit",viewBox:t}):r.createElement(ni,{key:"label-implicit",content:e,viewBox:t}):$()(e)?r.createElement(ni,{key:"label-implicit",content:e,viewBox:t}):V()(e)?r.createElement(ni,Xt({viewBox:t},e,{key:"label-implicit"})):null:null}(e.label,t||o);return[l].concat(function(e){if(Array.isArray(e))return Kt(e)}(s=a)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(s)||function(e,t){if(e){if("string"==typeof e)return Kt(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?Kt(e,t):void 0}}(s)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())},i(57657),i(9884),i(86974),i(72507);var ai=function(e){var t,i,n,o=e.axis,r=e.ticks,a=e.bandSize,s=e.entry,l=e.index,c=e.dataKey;if("category"===o.type){if(!o.allowDuplicatedCategory&&o.dataKey&&!j()(s[o.dataKey])){var d=(t=r,i="value",n=s[o.dataKey],t&&t.length?t.find((function(e){return e&&v()(e,i)===n})):null);if(d)return d.coordinate+a/2}return r[l]?r[l].coordinate+a/2:null}var u=ri(s,j()(c)?o.dataKey:c);return j()(u)?null:o.scale(u)};function si(e){return si="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},si(e)}var li=["valueAccessor"],ci=["data","dataKey","clockWise","id","textBreakAll"];function di(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}function ui(){return ui=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},ui.apply(this,arguments)}function hi(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function pi(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?hi(Object(i),!0).forEach((function(t){var n,o,r;n=e,o=t,r=i[t],(o=function(e){var t=function(e,t){if("object"!==si(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==si(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===si(t)?t:String(t)}(o))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):hi(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function gi(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}var fi=function(e){return C()(e.value)?at()(e.value):e.value};function mi(e){var t=e.valueAccessor,i=void 0===t?fi:t,n=gi(e,li),o=n.data,a=n.dataKey,s=n.clockWise,l=n.id,c=n.textBreakAll,d=gi(n,ci);return o&&o.length?r.createElement(ot,{className:"recharts-label-list"},o.map((function(e,t){var n=j()(a)?i(e,t):ri(e&&e.payload,a),o=j()(l)?{}:{id:"".concat(l,"-").concat(t)};return r.createElement(ni,ui({},oe(e,!0),d,o,{parentViewBox:e.parentViewBox,index:t,value:n,textBreakAll:c,viewBox:ni.parseViewBox(j()(s)?e:pi(pi({},e),{},{clockWise:s})),key:"label-".concat(t)}))}))):null}mi.displayName="LabelList",mi.renderCallByParent=function(e,t){var i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];if(!e||!e.children&&i&&!e.label)return null;var n,o=ne(e.children,mi).map((function(e,i){return(0,r.cloneElement)(e,{data:t,key:"labelList-".concat(i)})}));return i?[function(e,t){return e?!0===e?r.createElement(mi,{key:"labelList-implicit",data:t}):r.isValidElement(e)||$()(e)?r.createElement(mi,{key:"labelList-implicit",data:t,content:e}):V()(e)?r.createElement(mi,ui({data:t},e,{key:"labelList-implicit"})):null:null}(e.label,t)].concat(function(e){if(Array.isArray(e))return di(e)}(n=o)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(n)||function(e,t){if(e){if("string"==typeof e)return di(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?di(e,t):void 0}}(n)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()):o};var vi,yi=["layout","type","stroke","connectNulls","isRange","ref"];function Ci(e){return Ci="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ci(e)}function bi(){return bi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},bi.apply(this,arguments)}function Si(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function xi(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Si(Object(i),!0).forEach((function(t){Ai(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Si(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function Ti(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,Ei(n.key),n)}}function wi(e,t){return wi=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},wi(e,t)}function Oi(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Pi(e){return Pi=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Pi(e)}function Ai(e,t,i){return(t=Ei(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function Ei(e){var t=function(e,t){if("object"!==Ci(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==Ci(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Ci(t)?t:String(t)}var ki=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&wi(e,t)}(c,e);var t,i,n,a,s,l=(a=c,s=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=Pi(a);if(s){var i=Pi(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===Ci(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return Oi(e)}(this,e)});function c(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,c);for(var t=arguments.length,i=new Array(t),n=0;n<t;n++)i[n]=arguments[n];return Ai(Oi(e=l.call.apply(l,[this].concat(i))),"state",{isAnimationFinished:!0}),Ai(Oi(e),"id",I("recharts-area-")),Ai(Oi(e),"handleAnimationEnd",(function(){var t=e.props.onAnimationEnd;e.setState({isAnimationFinished:!0}),$()(t)&&t()})),Ai(Oi(e),"handleAnimationStart",(function(){var t=e.props.onAnimationStart;e.setState({isAnimationFinished:!1}),$()(t)&&t()})),e}return t=c,n=[{key:"getDerivedStateFromProps",value:function(e,t){return e.animationId!==t.prevAnimationId?{prevAnimationId:e.animationId,curPoints:e.points,curBaseLine:e.baseLine,prevPoints:t.curPoints,prevBaseLine:t.curBaseLine}:e.points!==t.curPoints||e.baseLine!==t.curBaseLine?{curPoints:e.points,curBaseLine:e.baseLine}:null}}],(i=[{key:"renderDots",value:function(e,t,i){var n=this.props.isAnimationActive,o=this.state.isAnimationFinished;if(n&&!o)return null;var a=this.props,s=a.dot,l=a.points,d=a.dataKey,u=oe(this.props),h=oe(s,!0),p=l.map((function(e,t){var i=xi(xi(xi({key:"dot-".concat(t),r:3},u),h),{},{dataKey:d,cx:e.x,cy:e.y,index:t,value:e.value,payload:e.payload});return c.renderDotItem(s,i)})),g={clipPath:e?"url(#clipPath-".concat(t?"":"dots-").concat(i,")"):null};return r.createElement(ot,bi({className:"recharts-area-dots"},g),p)}},{key:"renderHorizontalRect",value:function(e){var t=this.props,i=t.baseLine,n=t.points,o=t.strokeWidth,a=n[0].x,s=n[n.length-1].x,l=e*Math.abs(a-s),c=Te()(n.map((function(e){return e.y||0})));return A(i)&&"number"==typeof i?c=Math.max(i,c):i&&C()(i)&&i.length&&(c=Math.max(Te()(i.map((function(e){return e.y||0}))),c)),A(c)?r.createElement("rect",{x:a<s?a:a-l,y:0,width:l,height:Math.floor(c+(o?parseInt("".concat(o),10):1))}):null}},{key:"renderVerticalRect",value:function(e){var t=this.props,i=t.baseLine,n=t.points,o=t.strokeWidth,a=n[0].y,s=n[n.length-1].y,l=e*Math.abs(a-s),c=Te()(n.map((function(e){return e.x||0})));return A(i)&&"number"==typeof i?c=Math.max(i,c):i&&C()(i)&&i.length&&(c=Math.max(Te()(i.map((function(e){return e.x||0}))),c)),A(c)?r.createElement("rect",{x:0,y:a<s?a:a-l,width:c+(o?parseInt("".concat(o),10):1),height:Math.floor(l)}):null}},{key:"renderClipRect",value:function(e){return"vertical"===this.props.layout?this.renderVerticalRect(e):this.renderHorizontalRect(e)}},{key:"renderAreaStatically",value:function(e,t,i,n){var o=this.props,a=o.layout,s=o.type,l=o.stroke,c=o.connectNulls,d=o.isRange,u=(o.ref,function(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}(o,yi));return r.createElement(ot,{clipPath:i?"url(#clipPath-".concat(n,")"):null},r.createElement(Qe,bi({},oe(u,!0),{points:e,connectNulls:c,type:s,baseLine:t,layout:a,stroke:"none",className:"recharts-area-area"})),"none"!==l&&r.createElement(Qe,bi({},oe(this.props),{className:"recharts-area-curve",layout:a,type:s,connectNulls:c,fill:"none",points:e})),"none"!==l&&d&&r.createElement(Qe,bi({},oe(this.props),{className:"recharts-area-curve",layout:a,type:s,connectNulls:c,fill:"none",points:t})))}},{key:"renderAreaWithAnimation",value:function(e,t){var i=this,n=this.props,o=n.points,a=n.baseLine,s=n.isAnimationActive,l=n.animationBegin,c=n.animationDuration,d=n.animationEasing,u=n.animationId,h=this.state,p=h.prevPoints,g=h.prevBaseLine;return r.createElement(we.default,{begin:l,duration:c,isActive:s,easing:d,from:{t:0},to:{t:1},key:"area-".concat(u),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},(function(n){var s=n.t;if(p){var l,c=p.length/o.length,d=o.map((function(e,t){var i=Math.floor(t*c);if(p[i]){var n=p[i],o=_(n.x,e.x),r=_(n.y,e.y);return xi(xi({},e),{},{x:o(s),y:r(s)})}return e}));return l=A(a)&&"number"==typeof a?_(g,a)(s):j()(a)||S()(a)?_(g,0)(s):a.map((function(e,t){var i=Math.floor(t*c);if(g[i]){var n=g[i],o=_(n.x,e.x),r=_(n.y,e.y);return xi(xi({},e),{},{x:o(s),y:r(s)})}return e})),i.renderAreaStatically(d,l,e,t)}return r.createElement(ot,null,r.createElement("defs",null,r.createElement("clipPath",{id:"animationClipPath-".concat(t)},i.renderClipRect(s))),r.createElement(ot,{clipPath:"url(#animationClipPath-".concat(t,")")},i.renderAreaStatically(o,a,e,t)))}))}},{key:"renderArea",value:function(e,t){var i=this.props,n=i.points,o=i.baseLine,r=i.isAnimationActive,a=this.state,s=a.prevPoints,l=a.prevBaseLine,c=a.totalLength;return r&&n&&n.length&&(!s&&c>0||!Se()(s,n)||!Se()(l,o))?this.renderAreaWithAnimation(e,t):this.renderAreaStatically(n,o,e,t)}},{key:"render",value:function(){var e,t=this.props,i=t.hide,n=t.dot,a=t.points,s=t.className,l=t.top,c=t.left,d=t.xAxis,u=t.yAxis,h=t.width,p=t.height,g=t.isAnimationActive,f=t.id;if(i||!a||!a.length)return null;var m=this.state.isAnimationFinished,v=1===a.length,y=o()("recharts-area",s),C=d&&d.allowDataOverflow,b=u&&u.allowDataOverflow,S=C||b,x=j()(f)?this.id:f,T=null!==(e=oe(n))&&void 0!==e?e:{r:3,strokeWidth:2},w=T.r,O=void 0===w?3:w,P=T.strokeWidth,A=void 0===P?2:P,E=(function(e){return e&&"object"===J(e)&&"cx"in e&&"cy"in e&&"r"in e}(n)?n:{}).clipDot,k=void 0===E||E,I=2*O+A;return r.createElement(ot,{className:y},C||b?r.createElement("defs",null,r.createElement("clipPath",{id:"clipPath-".concat(x)},r.createElement("rect",{x:C?c:c-h/2,y:b?l:l-p/2,width:C?h:2*h,height:b?p:2*p})),!k&&r.createElement("clipPath",{id:"clipPath-dots-".concat(x)},r.createElement("rect",{x:c-I/2,y:l-I/2,width:h+I,height:p+I}))):null,v?null:this.renderArea(S,x),(n||v)&&this.renderDots(S,k,x),(!g||m)&&mi.renderCallByParent(this.props,a))}}])&&Ti(t.prototype,i),n&&Ti(t,n),Object.defineProperty(t,"prototype",{writable:!1}),c}(r.PureComponent);vi=ki,Ai(ki,"displayName","Area"),Ai(ki,"defaultProps",{stroke:"#3182bd",fill:"#3182bd",fillOpacity:.6,xAxisId:0,yAxisId:0,legendType:"line",connectNulls:!1,points:[],dot:!1,activeDot:!0,hide:!1,isAnimationActive:!st.isSsr,animationBegin:0,animationDuration:1500,animationEasing:"ease"}),Ai(ki,"getBaseValue",(function(e,t,i,n){var o=e.layout,r=e.baseValue,a=t.props.baseValue,s=null!=a?a:r;if(A(s)&&"number"==typeof s)return s;var l="horizontal"===o?n:i,c=l.scale.domain();if("number"===l.type){var d=Math.max(c[0],c[1]),u=Math.min(c[0],c[1]);return"dataMin"===s?u:"dataMax"===s||d<0?d:Math.max(Math.min(c[0],c[1]),0)}return"dataMin"===s?c[0]:"dataMax"===s?c[1]:c[0]})),Ai(ki,"getComposedData",(function(e){var t,i=e.props,n=e.item,o=e.xAxis,r=e.yAxis,a=e.xAxisTicks,s=e.yAxisTicks,l=e.bandSize,c=e.dataKey,d=e.stackedData,u=e.dataStartIndex,h=e.displayedData,p=e.offset,g=i.layout,f=d&&d.length,m=vi.getBaseValue(i,n,o,r),y=!1,b=h.map((function(e,t){var i,n=ri(e,c);f?i=d[u+t]:(i=n,C()(i)?y=!0:i=[m,i]);var h=j()(i[1])||f&&j()(n);return"horizontal"===g?{x:ai({axis:o,ticks:a,bandSize:l,entry:e,index:t}),y:h?null:r.scale(i[1]),value:i,payload:e}:{x:h?null:o.scale(i[1]),y:ai({axis:r,ticks:s,bandSize:l,entry:e,index:t}),value:i,payload:e}}));return t=f||y?b.map((function(e){return"horizontal"===g?{x:e.x,y:j()(v()(e,"value[0]"))||j()(v()(e,"y"))?null:r.scale(v()(e,"value[0]"))}:{x:j()(v()(e,"value[0]"))?null:o.scale(v()(e,"value[0]")),y:e.y}})):"horizontal"===g?r.scale(m):o.scale(m),xi({points:b,baseLine:t,layout:g,isRange:y},p)})),Ai(ki,"renderDotItem",(function(e,t){return r.isValidElement(e)?r.cloneElement(e,t):$()(e)?e(t):r.createElement(tt,bi({},t,{className:"recharts-area-dot"}))}));var Ii=i(93525),Di=i.n(Ii),_i=function(e,t){var i=e.alwaysShow,n=e.ifOverflow;return i&&(n="extendDomain"),n===t},Ni=i(6425),Ri=i.n(Ni),Mi=i(31113),Li=i.n(Mi);function Bi(e){return Bi="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Bi(e)}function Fi(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,Zi(n.key),n)}}function Ui(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Hi(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Ui(Object(i),!0).forEach((function(t){$i(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Ui(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function $i(e,t,i){return(t=Zi(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function Zi(e){var t=function(e,t){if("object"!==Bi(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==Bi(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Bi(t)?t:String(t)}var Vi=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.scale=t}var t,i,n;return t=e,i=[{key:"domain",get:function(){return this.scale.domain}},{key:"range",get:function(){return this.scale.range}},{key:"rangeMin",get:function(){return this.range()[0]}},{key:"rangeMax",get:function(){return this.range()[1]}},{key:"bandwidth",get:function(){return this.scale.bandwidth}},{key:"apply",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=t.bandAware,n=t.position;if(void 0!==e){if(n)switch(n){case"start":default:return this.scale(e);case"middle":var o=this.bandwidth?this.bandwidth()/2:0;return this.scale(e)+o;case"end":var r=this.bandwidth?this.bandwidth():0;return this.scale(e)+r}if(i){var a=this.bandwidth?this.bandwidth()/2:0;return this.scale(e)+a}return this.scale(e)}}},{key:"isInRange",value:function(e){var t=this.range(),i=t[0],n=t[t.length-1];return i<=n?e>=i&&e<=n:e>=n&&e<=i}}],n=[{key:"create",value:function(t){return new e(t)}}],i&&Fi(t.prototype,i),n&&Fi(t,n),Object.defineProperty(t,"prototype",{writable:!1}),e}();$i(Vi,"EPS",1e-4);var Gi=function(e){var t=Object.keys(e).reduce((function(t,i){return Hi(Hi({},t),{},$i({},i,Vi.create(e[i])))}),{});return Hi(Hi({},t),{},{apply:function(e){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=i.bandAware,o=i.position;return Li()(e,(function(e,i){return t[i].apply(e,{bandAware:n,position:o})}))},isInRange:function(e){return Ri()(e,(function(e,i){return t[i].isInRange(e)}))}})};function ji(e){return ji="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},ji(e)}function zi(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Wi(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?zi(Object(i),!0).forEach((function(t){var n,o,r;n=e,o=t,r=i[t],(o=function(e){var t=function(e,t){if("object"!==ji(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==ji(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===ji(t)?t:String(t)}(o))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):zi(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function Ki(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}function qi(){return qi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},qi.apply(this,arguments)}function Yi(e){var t=e.x,i=e.y,n=e.segment,a=e.xAxis,s=e.yAxis,l=e.shape,c=e.className,d=e.alwaysShow,u=e.clipPathId;N(void 0===d,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var h=function(e,t,i,n,o){var r=o.viewBox,a=r.x,s=r.y,l=r.width,c=r.height,d=o.position;if(i){var u=o.y,h=o.yAxis.orientation,p=e.y.apply(u,{position:d});if(_i(o,"discard")&&!e.y.isInRange(p))return null;var g=[{x:a+l,y:p},{x:a,y:p}];return"left"===h?g.reverse():g}if(t){var f=o.x,m=o.xAxis.orientation,v=e.x.apply(f,{position:d});if(_i(o,"discard")&&!e.x.isInRange(v))return null;var y=[{x:v,y:s+c},{x:v,y:s}];return"top"===m?y.reverse():y}if(n){var C=o.segment.map((function(t){return e.apply(t,{position:d})}));return _i(o,"discard")&&Di()(C,(function(t){return!e.isInRange(t)}))?null:C}return null}(Gi({x:a.scale,y:s.scale}),E(t),E(i),n&&2===n.length,e);if(!h)return null;var p,g,f=(g=2,function(e){if(Array.isArray(e))return e}(p=h)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var n,o,r,a,s=[],l=!0,c=!1;try{if(r=(i=i.call(e)).next,0===t){if(Object(i)!==i)return;l=!1}else for(;!(l=(n=r.call(i)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=i.return&&(a=i.return(),Object(a)!==a))return}finally{if(c)throw o}}return s}}(p,g)||function(e,t){if(e){if("string"==typeof e)return Ki(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?Ki(e,t):void 0}}(p,g)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),m=f[0],v=m.x,y=m.y,C=f[1],b=C.x,S=C.y,x=Wi(Wi({clipPath:_i(e,"hidden")?"url(#".concat(u,")"):void 0},oe(e,!0)),{},{x1:v,y1:y,x2:b,y2:S});return r.createElement(ot,{className:o()("recharts-reference-line",c)},function(e,t){return r.isValidElement(e)?r.cloneElement(e,t):$()(e)?e(t):r.createElement("line",qi({},t,{className:"recharts-reference-line-line"}))}(l,x),ni.renderCallByParent(e,function(e){return t={x:e.x1,y:e.y1},i={x:e.x2,y:e.y2},n=t.x,o=t.y,r=i.x,a=i.y,{x:Math.min(n,r),y:Math.min(o,a),width:Math.abs(r-n),height:Math.abs(a-o)};var t,i,n,o,r,a}({x1:v,y1:y,x2:b,y2:S})))}function Xi(e){return Xi="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Xi(e)}function Ji(){return Ji=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},Ji.apply(this,arguments)}function Qi(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function en(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Qi(Object(i),!0).forEach((function(t){var n,o,r;n=e,o=t,r=i[t],(o=function(e){var t=function(e,t){if("object"!==Xi(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==Xi(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Xi(t)?t:String(t)}(o))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Qi(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function tn(e){var t=e.x,i=e.y,n=e.r,a=e.alwaysShow,s=e.clipPathId,l=E(t),c=E(i);if(N(void 0===a,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.'),!l||!c)return null;var d=function(e){var t=e.x,i=e.y,n=e.xAxis,o=e.yAxis,r=Gi({x:n.scale,y:o.scale}),a=r.apply({x:t,y:i},{bandAware:!0});return _i(e,"discard")&&!r.isInRange(a)?null:a}(e);if(!d)return null;var u=d.x,h=d.y,p=e.shape,g=e.className,f=en(en({clipPath:_i(e,"hidden")?"url(#".concat(s,")"):void 0},oe(e,!0)),{},{cx:u,cy:h});return r.createElement(ot,{className:o()("recharts-reference-dot",g)},tn.renderDot(p,f),ni.renderCallByParent(e,{x:u-n,y:h-n,width:2*n,height:2*n}))}Yi.displayName="ReferenceLine",Yi.defaultProps={isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,fill:"none",stroke:"#ccc",fillOpacity:1,strokeWidth:1,position:"middle"},tn.displayName="ReferenceDot",tn.defaultProps={isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#fff",stroke:"#ccc",fillOpacity:1,strokeWidth:1},tn.renderDot=function(e,t){return r.isValidElement(e)?r.cloneElement(e,t):$()(e)?e(t):r.createElement(tt,Ji({},t,{cx:t.cx,cy:t.cy,className:"recharts-reference-dot-dot"}))};var nn=i(2068),on=i(68304),rn=i(47320),an=i(10428),sn=i(93273),ln=i(61441),cn=i(81202),dn=i(36725),un=i(96729),hn=i(1508),pn=i(52931),gn=i(49566),fn=i(53042),mn=i(48828),vn=i(19518),yn=i(93903),Cn=i(36893),bn=i(13630),Sn=i(8959),xn=i(89211),Tn=i(87416),wn=i(15703),On=i(10455),Pn=i(64692),An=i(60212),En=i(60637),kn=i(11976),In=i(45138),Dn=i(28071),_n=i(12618),Nn=i(61492),Rn=i(52961),Mn=i(44956),Ln=i(84045);function Bn(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}function Fn(e,t){if(e){if("string"==typeof e)return Bn(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?Bn(e,t):void 0}}function Un(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var n,o,r,a,s=[],l=!0,c=!1;try{if(r=(i=i.call(e)).next,0===t){if(Object(i)!==i)return;l=!1}else for(;!(l=(n=r.call(i)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=i.return&&(a=i.return(),Object(a)!==a))return}finally{if(c)throw o}}return s}}(e,t)||Fn(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Hn(e){return Hn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Hn(e)}function $n(e){var t=function(e,t){if("object"!==Hn(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==Hn(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Hn(t)?t:String(t)}function Zn(e,t,i){return(t=$n(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function Vn(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Gn,jn,zn,Wn,Kn={exports:{}};Kn.exports=function(){if(Wn)return zn;Wn=1;var e=jn?Gn:(jn=1,Gn="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED");function t(){}function i(){}return i.resetWarningCache=t,zn=function(){function n(t,i,n,o,r,a){if(a!==e){var s=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw s.name="Invariant Violation",s}}function o(){return n}n.isRequired=n;var r={array:n,bigint:n,bool:n,func:n,number:n,object:n,string:n,symbol:n,any:n,arrayOf:o,element:n,elementType:n,instanceOf:o,node:n,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:i,resetWarningCache:t};return r.PropTypes=r,r}}()();var qn=Vn(Kn.exports);function Yn(e){return Yn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Yn(e)}function Xn(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Jn(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Xn(Object(i),!0).forEach((function(t){Qn(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Xn(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function Qn(e,t,i){return(t=function(e){var t=function(e,t){if("object"!==Yn(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==Yn(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Yn(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}var eo=["Webkit","Moz","O","ms"],to=["-webkit-","-moz-","-o-","-ms-"],io=["transform","transformOrigin","transition"],no=function(e){return Object.keys(e).reduce((function(e,t){return Jn(Jn({},e),function(e,t){if(-1===io.indexOf(e))return Qn({},e,Number.isNaN(t)?0:t);var i="transition"===e,n=e.replace(/(\w)/,(function(e){return e.toUpperCase()})),o=t;return eo.reduce((function(e,r,a){return i&&(o=t.replace(/(transform|transform-origin)/gim,"".concat(to[a],"$1"))),Jn(Jn({},e),{},Qn({},r+n,o))}),{})}(t,e[t]))}),e)};qn.oneOfType([qn.object,qn.string]),qn.oneOfType([qn.object,qn.string]),qn.string,qn.number,qn.number,qn.oneOfType([qn.string,qn.func]),qn.arrayOf(qn.shape({duration:qn.number.isRequired,style:qn.object.isRequired,easing:qn.oneOfType([qn.oneOf(["ease","ease-in","ease-out","ease-in-out","linear"]),qn.func]),properties:qn.arrayOf("string"),onAnimationEnd:qn.func})),qn.oneOfType([qn.node,qn.func]),qn.bool,qn.bool,qn.func,qn.bool,qn.func,qn.func,void 0===Number.isFinite&&(Number.isFinite=function(e){return"number"==typeof e&&isFinite(e)}),qn.object,qn.object,qn.object,qn.element,qn.object,qn.object,qn.object,qn.oneOfType([qn.array,qn.element]),qn.any;var oo={exports:{}};!function(e,t){(function(){var n,o="Expected a function",r="__lodash_hash_undefined__",a="__lodash_placeholder__",s=32,l=128,c=1/0,d=9007199254740991,u=NaN,h=4294967295,p=[["ary",l],["bind",1],["bindKey",2],["curry",8],["curryRight",16],["flip",512],["partial",s],["partialRight",64],["rearg",256]],g="[object Arguments]",f="[object Array]",m="[object Boolean]",v="[object Date]",y="[object Error]",C="[object Function]",b="[object GeneratorFunction]",S="[object Map]",x="[object Number]",T="[object Object]",w="[object Promise]",O="[object RegExp]",P="[object Set]",A="[object String]",E="[object Symbol]",k="[object WeakMap]",I="[object ArrayBuffer]",D="[object DataView]",_="[object Float32Array]",N="[object Float64Array]",R="[object Int8Array]",M="[object Int16Array]",L="[object Int32Array]",B="[object Uint8Array]",F="[object Uint8ClampedArray]",U="[object Uint16Array]",H="[object Uint32Array]",$=/\b__p \+= '';/g,Z=/\b(__p \+=) '' \+/g,V=/(__e\(.*?\)|\b__t\)) \+\n'';/g,G=/&(?:amp|lt|gt|quot|#39);/g,j=/[&<>"']/g,z=RegExp(G.source),W=RegExp(j.source),K=/<%-([\s\S]+?)%>/g,q=/<%([\s\S]+?)%>/g,Y=/<%=([\s\S]+?)%>/g,X=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,J=/^\w*$/,Q=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,ee=/[\\^$.*+?()[\]{}|]/g,te=RegExp(ee.source),ie=/^\s+/,ne=/\s/,oe=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,re=/\{\n\/\* \[wrapped with (.+)\] \*/,ae=/,? & /,se=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,le=/[()=,{}\[\]\/\s]/,ce=/\\(\\)?/g,de=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,ue=/\w*$/,he=/^[-+]0x[0-9a-f]+$/i,pe=/^0b[01]+$/i,ge=/^\[object .+?Constructor\]$/,fe=/^0o[0-7]+$/i,me=/^(?:0|[1-9]\d*)$/,ve=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,ye=/($^)/,Ce=/['\n\r\u2028\u2029\\]/g,be="\\ud800-\\udfff",Se="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",xe="\\u2700-\\u27bf",Te="a-z\\xdf-\\xf6\\xf8-\\xff",we="A-Z\\xc0-\\xd6\\xd8-\\xde",Oe="\\ufe0e\\ufe0f",Pe="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Ae="["+be+"]",Ee="["+Pe+"]",ke="["+Se+"]",Ie="\\d+",De="["+xe+"]",_e="["+Te+"]",Ne="[^"+be+Pe+Ie+xe+Te+we+"]",Re="\\ud83c[\\udffb-\\udfff]",Me="[^"+be+"]",Le="(?:\\ud83c[\\udde6-\\uddff]){2}",Be="[\\ud800-\\udbff][\\udc00-\\udfff]",Fe="["+we+"]",Ue="\\u200d",He="(?:"+_e+"|"+Ne+")",$e="(?:"+Fe+"|"+Ne+")",Ze="(?:['’](?:d|ll|m|re|s|t|ve))?",Ve="(?:['’](?:D|LL|M|RE|S|T|VE))?",Ge="(?:"+ke+"|"+Re+")?",je="["+Oe+"]?",ze=je+Ge+"(?:"+Ue+"(?:"+[Me,Le,Be].join("|")+")"+je+Ge+")*",We="(?:"+[De,Le,Be].join("|")+")"+ze,Ke="(?:"+[Me+ke+"?",ke,Le,Be,Ae].join("|")+")",qe=RegExp("['’]","g"),Ye=RegExp(ke,"g"),Xe=RegExp(Re+"(?="+Re+")|"+Ke+ze,"g"),Je=RegExp([Fe+"?"+_e+"+"+Ze+"(?="+[Ee,Fe,"$"].join("|")+")",$e+"+"+Ve+"(?="+[Ee,Fe+He,"$"].join("|")+")",Fe+"?"+He+"+"+Ze,Fe+"+"+Ve,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Ie,We].join("|"),"g"),Qe=RegExp("["+Ue+be+Se+Oe+"]"),et=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,tt=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],it=-1,nt={};nt[_]=nt[N]=nt[R]=nt[M]=nt[L]=nt[B]=nt[F]=nt[U]=nt[H]=!0,nt[g]=nt[f]=nt[I]=nt[m]=nt[D]=nt[v]=nt[y]=nt[C]=nt[S]=nt[x]=nt[T]=nt[O]=nt[P]=nt[A]=nt[k]=!1;var ot={};ot[g]=ot[f]=ot[I]=ot[D]=ot[m]=ot[v]=ot[_]=ot[N]=ot[R]=ot[M]=ot[L]=ot[S]=ot[x]=ot[T]=ot[O]=ot[P]=ot[A]=ot[E]=ot[B]=ot[F]=ot[U]=ot[H]=!0,ot[y]=ot[C]=ot[k]=!1;var rt={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},at=parseFloat,st=parseInt,lt="object"==typeof i.g&&i.g&&i.g.Object===Object&&i.g,ct="object"==typeof self&&self&&self.Object===Object&&self,dt=lt||ct||Function("return this")(),ut=t&&!t.nodeType&&t,ht=ut&&e&&!e.nodeType&&e,pt=ht&&ht.exports===ut,gt=pt&<.process,ft=function(){try{return ht&&ht.require&&ht.require("util").types||gt&>.binding&>.binding("util")}catch(e){}}(),mt=ft&&ft.isArrayBuffer,vt=ft&&ft.isDate,yt=ft&&ft.isMap,Ct=ft&&ft.isRegExp,bt=ft&&ft.isSet,St=ft&&ft.isTypedArray;function xt(e,t,i){switch(i.length){case 0:return e.call(t);case 1:return e.call(t,i[0]);case 2:return e.call(t,i[0],i[1]);case 3:return e.call(t,i[0],i[1],i[2])}return e.apply(t,i)}function Tt(e,t,i,n){for(var o=-1,r=null==e?0:e.length;++o<r;){var a=e[o];t(n,a,i(a),e)}return n}function wt(e,t){for(var i=-1,n=null==e?0:e.length;++i<n&&!1!==t(e[i],i,e););return e}function Ot(e,t){for(var i=null==e?0:e.length;i--&&!1!==t(e[i],i,e););return e}function Pt(e,t){for(var i=-1,n=null==e?0:e.length;++i<n;)if(!t(e[i],i,e))return!1;return!0}function At(e,t){for(var i=-1,n=null==e?0:e.length,o=0,r=[];++i<n;){var a=e[i];t(a,i,e)&&(r[o++]=a)}return r}function Et(e,t){return!(null==e||!e.length)&&Ft(e,t,0)>-1}function kt(e,t,i){for(var n=-1,o=null==e?0:e.length;++n<o;)if(i(t,e[n]))return!0;return!1}function It(e,t){for(var i=-1,n=null==e?0:e.length,o=Array(n);++i<n;)o[i]=t(e[i],i,e);return o}function Dt(e,t){for(var i=-1,n=t.length,o=e.length;++i<n;)e[o+i]=t[i];return e}function _t(e,t,i,n){var o=-1,r=null==e?0:e.length;for(n&&r&&(i=e[++o]);++o<r;)i=t(i,e[o],o,e);return i}function Nt(e,t,i,n){var o=null==e?0:e.length;for(n&&o&&(i=e[--o]);o--;)i=t(i,e[o],o,e);return i}function Rt(e,t){for(var i=-1,n=null==e?0:e.length;++i<n;)if(t(e[i],i,e))return!0;return!1}var Mt=Zt("length");function Lt(e,t,i){var n;return i(e,(function(e,i,o){if(t(e,i,o))return n=i,!1})),n}function Bt(e,t,i,n){for(var o=e.length,r=i+(n?1:-1);n?r--:++r<o;)if(t(e[r],r,e))return r;return-1}function Ft(e,t,i){return t==t?function(e,t,i){for(var n=i-1,o=e.length;++n<o;)if(e[n]===t)return n;return-1}(e,t,i):Bt(e,Ht,i)}function Ut(e,t,i,n){for(var o=i-1,r=e.length;++o<r;)if(n(e[o],t))return o;return-1}function Ht(e){return e!=e}function $t(e,t){var i=null==e?0:e.length;return i?jt(e,t)/i:u}function Zt(e){return function(t){return null==t?n:t[e]}}function Vt(e){return function(t){return null==e?n:e[t]}}function Gt(e,t,i,n,o){return o(e,(function(e,o,r){i=n?(n=!1,e):t(i,e,o,r)})),i}function jt(e,t){for(var i,o=-1,r=e.length;++o<r;){var a=t(e[o]);a!==n&&(i=i===n?a:i+a)}return i}function zt(e,t){for(var i=-1,n=Array(e);++i<e;)n[i]=t(i);return n}function Wt(e){return e?e.slice(0,ci(e)+1).replace(ie,""):e}function Kt(e){return function(t){return e(t)}}function qt(e,t){return It(t,(function(t){return e[t]}))}function Yt(e,t){return e.has(t)}function Xt(e,t){for(var i=-1,n=e.length;++i<n&&Ft(t,e[i],0)>-1;);return i}function Jt(e,t){for(var i=e.length;i--&&Ft(t,e[i],0)>-1;);return i}var Qt=Vt({"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"}),ei=Vt({"&":"&","<":"<",">":">",'"':""","'":"'"});function ti(e){return"\\"+rt[e]}function ii(e){return Qe.test(e)}function ni(e){var t=-1,i=Array(e.size);return e.forEach((function(e,n){i[++t]=[n,e]})),i}function oi(e,t){return function(i){return e(t(i))}}function ri(e,t){for(var i=-1,n=e.length,o=0,r=[];++i<n;){var s=e[i];s!==t&&s!==a||(e[i]=a,r[o++]=i)}return r}function ai(e){var t=-1,i=Array(e.size);return e.forEach((function(e){i[++t]=e})),i}function si(e){return ii(e)?function(e){for(var t=Xe.lastIndex=0;Xe.test(e);)++t;return t}(e):Mt(e)}function li(e){return ii(e)?function(e){return e.match(Xe)||[]}(e):function(e){return e.split("")}(e)}function ci(e){for(var t=e.length;t--&&ne.test(e.charAt(t)););return t}var di=Vt({"&":"&","<":"<",">":">",""":'"',"'":"'"}),ui=function e(t){var i,ne=(t=null==t?dt:ui.defaults(dt.Object(),t,ui.pick(dt,tt))).Array,be=t.Date,Se=t.Error,xe=t.Function,Te=t.Math,we=t.Object,Oe=t.RegExp,Pe=t.String,Ae=t.TypeError,Ee=ne.prototype,ke=xe.prototype,Ie=we.prototype,De=t["__core-js_shared__"],_e=ke.toString,Ne=Ie.hasOwnProperty,Re=0,Me=(i=/[^.]+$/.exec(De&&De.keys&&De.keys.IE_PROTO||""))?"Symbol(src)_1."+i:"",Le=Ie.toString,Be=_e.call(we),Fe=dt._,Ue=Oe("^"+_e.call(Ne).replace(ee,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),He=pt?t.Buffer:n,$e=t.Symbol,Ze=t.Uint8Array,Ve=He?He.allocUnsafe:n,Ge=oi(we.getPrototypeOf,we),je=we.create,ze=Ie.propertyIsEnumerable,We=Ee.splice,Ke=$e?$e.isConcatSpreadable:n,Xe=$e?$e.iterator:n,Qe=$e?$e.toStringTag:n,rt=function(){try{var e=lr(we,"defineProperty");return e({},"",{}),e}catch(e){}}(),lt=t.clearTimeout!==dt.clearTimeout&&t.clearTimeout,ct=be&&be.now!==dt.Date.now&&be.now,ut=t.setTimeout!==dt.setTimeout&&t.setTimeout,ht=Te.ceil,gt=Te.floor,ft=we.getOwnPropertySymbols,Mt=He?He.isBuffer:n,Vt=t.isFinite,hi=Ee.join,pi=oi(we.keys,we),gi=Te.max,fi=Te.min,mi=be.now,vi=t.parseInt,yi=Te.random,Ci=Ee.reverse,bi=lr(t,"DataView"),Si=lr(t,"Map"),xi=lr(t,"Promise"),Ti=lr(t,"Set"),wi=lr(t,"WeakMap"),Oi=lr(we,"create"),Pi=wi&&new wi,Ai={},Ei=Rr(bi),ki=Rr(Si),Ii=Rr(xi),Di=Rr(Ti),_i=Rr(wi),Ni=$e?$e.prototype:n,Ri=Ni?Ni.valueOf:n,Mi=Ni?Ni.toString:n;function Li(e){if(Xa(e)&&!Ha(e)&&!(e instanceof Hi)){if(e instanceof Ui)return e;if(Ne.call(e,"__wrapped__"))return Mr(e)}return new Ui(e)}var Bi=function(){function e(){}return function(t){if(!Ya(t))return{};if(je)return je(t);e.prototype=t;var i=new e;return e.prototype=n,i}}();function Fi(){}function Ui(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=n}function Hi(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=h,this.__views__=[]}function $i(e){var t=-1,i=null==e?0:e.length;for(this.clear();++t<i;){var n=e[t];this.set(n[0],n[1])}}function Zi(e){var t=-1,i=null==e?0:e.length;for(this.clear();++t<i;){var n=e[t];this.set(n[0],n[1])}}function Vi(e){var t=-1,i=null==e?0:e.length;for(this.clear();++t<i;){var n=e[t];this.set(n[0],n[1])}}function Gi(e){var t=-1,i=null==e?0:e.length;for(this.__data__=new Vi;++t<i;)this.add(e[t])}function ji(e){var t=this.__data__=new Zi(e);this.size=t.size}function zi(e,t){var i=Ha(e),n=!i&&Ua(e),o=!i&&!n&&Ga(e),r=!i&&!n&&!o&&rs(e),a=i||n||o||r,s=a?zt(e.length,Pe):[],l=s.length;for(var c in e)!t&&!Ne.call(e,c)||a&&("length"==c||o&&("offset"==c||"parent"==c)||r&&("buffer"==c||"byteLength"==c||"byteOffset"==c)||fr(c,l))||s.push(c);return s}function Wi(e){var t=e.length;return t?e[Gn(0,t-1)]:n}function Ki(e,t){return Dr(Po(e),on(t,0,e.length))}function qi(e){return Dr(Po(e))}function Yi(e,t,i){(i!==n&&!La(e[t],i)||i===n&&!(t in e))&&tn(e,t,i)}function Xi(e,t,i){var o=e[t];Ne.call(e,t)&&La(o,i)&&(i!==n||t in e)||tn(e,t,i)}function Ji(e,t){for(var i=e.length;i--;)if(La(e[i][0],t))return i;return-1}function Qi(e,t,i,n){return cn(e,(function(e,o,r){t(n,e,i(e),r)})),n}function en(e,t){return e&&Ao(t,As(t),e)}function tn(e,t,i){"__proto__"==t&&rt?rt(e,t,{configurable:!0,enumerable:!0,value:i,writable:!0}):e[t]=i}function nn(e,t){for(var i=-1,o=t.length,r=ne(o),a=null==e;++i<o;)r[i]=a?n:xs(e,t[i]);return r}function on(e,t,i){return e==e&&(i!==n&&(e=e<=i?e:i),t!==n&&(e=e>=t?e:t)),e}function rn(e,t,i,o,r,a){var s,l=1&t,c=2&t,d=4&t;if(i&&(s=r?i(e,o,r,a):i(e)),s!==n)return s;if(!Ya(e))return e;var u=Ha(e);if(u){if(s=function(e){var t=e.length,i=new e.constructor(t);return t&&"string"==typeof e[0]&&Ne.call(e,"index")&&(i.index=e.index,i.input=e.input),i}(e),!l)return Po(e,s)}else{var h=ur(e),p=h==C||h==b;if(Ga(e))return bo(e,l);if(h==T||h==g||p&&!r){if(s=c||p?{}:pr(e),!l)return c?function(e,t){return Ao(e,dr(e),t)}(e,function(e,t){return e&&Ao(t,Es(t),e)}(s,e)):function(e,t){return Ao(e,cr(e),t)}(e,en(s,e))}else{if(!ot[h])return r?e:{};s=function(e,t,i){var n,o=e.constructor;switch(t){case I:return So(e);case m:case v:return new o(+e);case D:return function(e,t){var i=t?So(e.buffer):e.buffer;return new e.constructor(i,e.byteOffset,e.byteLength)}(e,i);case _:case N:case R:case M:case L:case B:case F:case U:case H:return xo(e,i);case S:return new o;case x:case A:return new o(e);case O:return function(e){var t=new e.constructor(e.source,ue.exec(e));return t.lastIndex=e.lastIndex,t}(e);case P:return new o;case E:return n=e,Ri?we(Ri.call(n)):{}}}(e,h,l)}}a||(a=new ji);var f=a.get(e);if(f)return f;a.set(e,s),is(e)?e.forEach((function(n){s.add(rn(n,t,i,n,e,a))})):Ja(e)&&e.forEach((function(n,o){s.set(o,rn(n,t,i,o,e,a))}));var y=u?n:(d?c?tr:er:c?Es:As)(e);return wt(y||e,(function(n,o){y&&(n=e[o=n]),Xi(s,o,rn(n,t,i,o,e,a))})),s}function an(e,t,i){var o=i.length;if(null==e)return!o;for(e=we(e);o--;){var r=i[o],a=t[r],s=e[r];if(s===n&&!(r in e)||!a(s))return!1}return!0}function sn(e,t,i){if("function"!=typeof e)throw new Ae(o);return Ar((function(){e.apply(n,i)}),t)}function ln(e,t,i,n){var o=-1,r=Et,a=!0,s=e.length,l=[],c=t.length;if(!s)return l;i&&(t=It(t,Kt(i))),n?(r=kt,a=!1):t.length>=200&&(r=Yt,a=!1,t=new Gi(t));e:for(;++o<s;){var d=e[o],u=null==i?d:i(d);if(d=n||0!==d?d:0,a&&u==u){for(var h=c;h--;)if(t[h]===u)continue e;l.push(d)}else r(t,u,n)||l.push(d)}return l}Li.templateSettings={escape:K,evaluate:q,interpolate:Y,variable:"",imports:{_:Li}},Li.prototype=Fi.prototype,Li.prototype.constructor=Li,Ui.prototype=Bi(Fi.prototype),Ui.prototype.constructor=Ui,Hi.prototype=Bi(Fi.prototype),Hi.prototype.constructor=Hi,$i.prototype.clear=function(){this.__data__=Oi?Oi(null):{},this.size=0},$i.prototype.delete=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},$i.prototype.get=function(e){var t=this.__data__;if(Oi){var i=t[e];return i===r?n:i}return Ne.call(t,e)?t[e]:n},$i.prototype.has=function(e){var t=this.__data__;return Oi?t[e]!==n:Ne.call(t,e)},$i.prototype.set=function(e,t){var i=this.__data__;return this.size+=this.has(e)?0:1,i[e]=Oi&&t===n?r:t,this},Zi.prototype.clear=function(){this.__data__=[],this.size=0},Zi.prototype.delete=function(e){var t=this.__data__,i=Ji(t,e);return!(i<0||(i==t.length-1?t.pop():We.call(t,i,1),--this.size,0))},Zi.prototype.get=function(e){var t=this.__data__,i=Ji(t,e);return i<0?n:t[i][1]},Zi.prototype.has=function(e){return Ji(this.__data__,e)>-1},Zi.prototype.set=function(e,t){var i=this.__data__,n=Ji(i,e);return n<0?(++this.size,i.push([e,t])):i[n][1]=t,this},Vi.prototype.clear=function(){this.size=0,this.__data__={hash:new $i,map:new(Si||Zi),string:new $i}},Vi.prototype.delete=function(e){var t=ar(this,e).delete(e);return this.size-=t?1:0,t},Vi.prototype.get=function(e){return ar(this,e).get(e)},Vi.prototype.has=function(e){return ar(this,e).has(e)},Vi.prototype.set=function(e,t){var i=ar(this,e),n=i.size;return i.set(e,t),this.size+=i.size==n?0:1,this},Gi.prototype.add=Gi.prototype.push=function(e){return this.__data__.set(e,r),this},Gi.prototype.has=function(e){return this.__data__.has(e)},ji.prototype.clear=function(){this.__data__=new Zi,this.size=0},ji.prototype.delete=function(e){var t=this.__data__,i=t.delete(e);return this.size=t.size,i},ji.prototype.get=function(e){return this.__data__.get(e)},ji.prototype.has=function(e){return this.__data__.has(e)},ji.prototype.set=function(e,t){var i=this.__data__;if(i instanceof Zi){var n=i.__data__;if(!Si||n.length<199)return n.push([e,t]),this.size=++i.size,this;i=this.__data__=new Vi(n)}return i.set(e,t),this.size=i.size,this};var cn=Io(vn),dn=Io(yn,!0);function un(e,t){var i=!0;return cn(e,(function(e,n,o){return i=!!t(e,n,o)})),i}function hn(e,t,i){for(var o=-1,r=e.length;++o<r;){var a=e[o],s=t(a);if(null!=s&&(l===n?s==s&&!os(s):i(s,l)))var l=s,c=a}return c}function pn(e,t){var i=[];return cn(e,(function(e,n,o){t(e,n,o)&&i.push(e)})),i}function gn(e,t,i,n,o){var r=-1,a=e.length;for(i||(i=gr),o||(o=[]);++r<a;){var s=e[r];t>0&&i(s)?t>1?gn(s,t-1,i,n,o):Dt(o,s):n||(o[o.length]=s)}return o}var fn=Do(),mn=Do(!0);function vn(e,t){return e&&fn(e,t,As)}function yn(e,t){return e&&mn(e,t,As)}function Cn(e,t){return At(t,(function(t){return Wa(e[t])}))}function bn(e,t){for(var i=0,o=(t=mo(t,e)).length;null!=e&&i<o;)e=e[Nr(t[i++])];return i&&i==o?e:n}function Sn(e,t,i){var n=t(e);return Ha(e)?n:Dt(n,i(e))}function xn(e){return null==e?e===n?"[object Undefined]":"[object Null]":Qe&&Qe in we(e)?function(e){var t=Ne.call(e,Qe),i=e[Qe];try{e[Qe]=n;var o=!0}catch(e){}var r=Le.call(e);return o&&(t?e[Qe]=i:delete e[Qe]),r}(e):function(e){return Le.call(e)}(e)}function Tn(e,t){return e>t}function wn(e,t){return null!=e&&Ne.call(e,t)}function On(e,t){return null!=e&&t in we(e)}function Pn(e,t,i){for(var o=i?kt:Et,r=e[0].length,a=e.length,s=a,l=ne(a),c=1/0,d=[];s--;){var u=e[s];s&&t&&(u=It(u,Kt(t))),c=fi(u.length,c),l[s]=!i&&(t||r>=120&&u.length>=120)?new Gi(s&&u):n}u=e[0];var h=-1,p=l[0];e:for(;++h<r&&d.length<c;){var g=u[h],f=t?t(g):g;if(g=i||0!==g?g:0,!(p?Yt(p,f):o(d,f,i))){for(s=a;--s;){var m=l[s];if(!(m?Yt(m,f):o(e[s],f,i)))continue e}p&&p.push(f),d.push(g)}}return d}function An(e,t,i){var o=null==(e=wr(e,t=mo(t,e)))?e:e[Nr(zr(t))];return null==o?n:xt(o,e,i)}function En(e){return Xa(e)&&xn(e)==g}function kn(e,t,i,o,r){return e===t||(null==e||null==t||!Xa(e)&&!Xa(t)?e!=e&&t!=t:function(e,t,i,o,r,a){var s=Ha(e),l=Ha(t),c=s?f:ur(e),d=l?f:ur(t),u=(c=c==g?T:c)==T,h=(d=d==g?T:d)==T,p=c==d;if(p&&Ga(e)){if(!Ga(t))return!1;s=!0,u=!1}if(p&&!u)return a||(a=new ji),s||rs(e)?Jo(e,t,i,o,r,a):function(e,t,i,n,o,r,a){switch(i){case D:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case I:return!(e.byteLength!=t.byteLength||!r(new Ze(e),new Ze(t)));case m:case v:case x:return La(+e,+t);case y:return e.name==t.name&&e.message==t.message;case O:case A:return e==t+"";case S:var s=ni;case P:var l=1&n;if(s||(s=ai),e.size!=t.size&&!l)return!1;var c=a.get(e);if(c)return c==t;n|=2,a.set(e,t);var d=Jo(s(e),s(t),n,o,r,a);return a.delete(e),d;case E:if(Ri)return Ri.call(e)==Ri.call(t)}return!1}(e,t,c,i,o,r,a);if(!(1&i)){var C=u&&Ne.call(e,"__wrapped__"),b=h&&Ne.call(t,"__wrapped__");if(C||b){var w=C?e.value():e,k=b?t.value():t;return a||(a=new ji),r(w,k,i,o,a)}}return!!p&&(a||(a=new ji),function(e,t,i,o,r,a){var s=1&i,l=er(e),c=l.length;if(c!=er(t).length&&!s)return!1;for(var d=c;d--;){var u=l[d];if(!(s?u in t:Ne.call(t,u)))return!1}var h=a.get(e),p=a.get(t);if(h&&p)return h==t&&p==e;var g=!0;a.set(e,t),a.set(t,e);for(var f=s;++d<c;){var m=e[u=l[d]],v=t[u];if(o)var y=s?o(v,m,u,t,e,a):o(m,v,u,e,t,a);if(!(y===n?m===v||r(m,v,i,o,a):y)){g=!1;break}f||(f="constructor"==u)}if(g&&!f){var C=e.constructor,b=t.constructor;C==b||!("constructor"in e)||!("constructor"in t)||"function"==typeof C&&C instanceof C&&"function"==typeof b&&b instanceof b||(g=!1)}return a.delete(e),a.delete(t),g}(e,t,i,o,r,a))}(e,t,i,o,kn,r))}function In(e,t,i,o){var r=i.length,a=r,s=!o;if(null==e)return!a;for(e=we(e);r--;){var l=i[r];if(s&&l[2]?l[1]!==e[l[0]]:!(l[0]in e))return!1}for(;++r<a;){var c=(l=i[r])[0],d=e[c],u=l[1];if(s&&l[2]){if(d===n&&!(c in e))return!1}else{var h=new ji;if(o)var p=o(d,u,c,e,t,h);if(!(p===n?kn(u,d,3,o,h):p))return!1}}return!0}function Dn(e){return!(!Ya(e)||(t=e,Me&&Me in t))&&(Wa(e)?Ue:ge).test(Rr(e));var t}function _n(e){return"function"==typeof e?e:null==e?Qs:"object"==typeof e?Ha(e)?Bn(e[0],e[1]):Ln(e):ll(e)}function Nn(e){if(!br(e))return pi(e);var t=[];for(var i in we(e))Ne.call(e,i)&&"constructor"!=i&&t.push(i);return t}function Rn(e,t){return e<t}function Mn(e,t){var i=-1,n=Za(e)?ne(e.length):[];return cn(e,(function(e,o,r){n[++i]=t(e,o,r)})),n}function Ln(e){var t=sr(e);return 1==t.length&&t[0][2]?xr(t[0][0],t[0][1]):function(i){return i===e||In(i,e,t)}}function Bn(e,t){return vr(e)&&Sr(t)?xr(Nr(e),t):function(i){var o=xs(i,e);return o===n&&o===t?Ts(i,e):kn(t,o,3)}}function Fn(e,t,i,o,r){e!==t&&fn(t,(function(a,s){if(r||(r=new ji),Ya(a))!function(e,t,i,o,r,a,s){var l=Or(e,i),c=Or(t,i),d=s.get(c);if(d)Yi(e,i,d);else{var u=a?a(l,c,i+"",e,t,s):n,h=u===n;if(h){var p=Ha(c),g=!p&&Ga(c),f=!p&&!g&&rs(c);u=c,p||g||f?Ha(l)?u=l:Va(l)?u=Po(l):g?(h=!1,u=bo(c,!0)):f?(h=!1,u=xo(c,!0)):u=[]:es(c)||Ua(c)?(u=l,Ua(l)?u=ps(l):Ya(l)&&!Wa(l)||(u=pr(c))):h=!1}h&&(s.set(c,u),r(u,c,o,a,s),s.delete(c)),Yi(e,i,u)}}(e,t,s,i,Fn,o,r);else{var l=o?o(Or(e,s),a,s+"",e,t,r):n;l===n&&(l=a),Yi(e,s,l)}}),Es)}function Un(e,t){var i=e.length;if(i)return fr(t+=t<0?i:0,i)?e[t]:n}function Hn(e,t,i){t=t.length?It(t,(function(e){return Ha(e)?function(t){return bn(t,1===e.length?e[0]:e)}:e})):[Qs];var n=-1;t=It(t,Kt(rr()));var o=Mn(e,(function(e,i,o){var r=It(t,(function(t){return t(e)}));return{criteria:r,index:++n,value:e}}));return function(e,t){var i=e.length;for(e.sort(t);i--;)e[i]=e[i].value;return e}(o,(function(e,t){return function(e,t,i){for(var n=-1,o=e.criteria,r=t.criteria,a=o.length,s=i.length;++n<a;){var l=To(o[n],r[n]);if(l)return n>=s?l:l*("desc"==i[n]?-1:1)}return e.index-t.index}(e,t,i)}))}function $n(e,t,i){for(var n=-1,o=t.length,r={};++n<o;){var a=t[n],s=bn(e,a);i(s,a)&&qn(r,mo(a,e),s)}return r}function Zn(e,t,i,n){var o=n?Ut:Ft,r=-1,a=t.length,s=e;for(e===t&&(t=Po(t)),i&&(s=It(e,Kt(i)));++r<a;)for(var l=0,c=t[r],d=i?i(c):c;(l=o(s,d,l,n))>-1;)s!==e&&We.call(s,l,1),We.call(e,l,1);return e}function Vn(e,t){for(var i=e?t.length:0,n=i-1;i--;){var o=t[i];if(i==n||o!==r){var r=o;fr(o)?We.call(e,o,1):so(e,o)}}return e}function Gn(e,t){return e+gt(yi()*(t-e+1))}function jn(e,t){var i="";if(!e||t<1||t>d)return i;do{t%2&&(i+=e),(t=gt(t/2))&&(e+=e)}while(t);return i}function zn(e,t){return Er(Tr(e,t,Qs),e+"")}function Wn(e){return Wi(Ls(e))}function Kn(e,t){var i=Ls(e);return Dr(i,on(t,0,i.length))}function qn(e,t,i,o){if(!Ya(e))return e;for(var r=-1,a=(t=mo(t,e)).length,s=a-1,l=e;null!=l&&++r<a;){var c=Nr(t[r]),d=i;if("__proto__"===c||"constructor"===c||"prototype"===c)return e;if(r!=s){var u=l[c];(d=o?o(u,c,l):n)===n&&(d=Ya(u)?u:fr(t[r+1])?[]:{})}Xi(l,c,d),l=l[c]}return e}var Yn=Pi?function(e,t){return Pi.set(e,t),e}:Qs,Xn=rt?function(e,t){return rt(e,"toString",{configurable:!0,enumerable:!1,value:Ys(t),writable:!0})}:Qs;function Jn(e){return Dr(Ls(e))}function Qn(e,t,i){var n=-1,o=e.length;t<0&&(t=-t>o?0:o+t),(i=i>o?o:i)<0&&(i+=o),o=t>i?0:i-t>>>0,t>>>=0;for(var r=ne(o);++n<o;)r[n]=e[n+t];return r}function eo(e,t){var i;return cn(e,(function(e,n,o){return!(i=t(e,n,o))})),!!i}function to(e,t,i){var n=0,o=null==e?n:e.length;if("number"==typeof t&&t==t&&o<=2147483647){for(;n<o;){var r=n+o>>>1,a=e[r];null!==a&&!os(a)&&(i?a<=t:a<t)?n=r+1:o=r}return o}return io(e,t,Qs,i)}function io(e,t,i,o){var r=0,a=null==e?0:e.length;if(0===a)return 0;for(var s=(t=i(t))!=t,l=null===t,c=os(t),d=t===n;r<a;){var u=gt((r+a)/2),h=i(e[u]),p=h!==n,g=null===h,f=h==h,m=os(h);if(s)var v=o||f;else v=d?f&&(o||p):l?f&&p&&(o||!g):c?f&&p&&!g&&(o||!m):!g&&!m&&(o?h<=t:h<t);v?r=u+1:a=u}return fi(a,4294967294)}function no(e,t){for(var i=-1,n=e.length,o=0,r=[];++i<n;){var a=e[i],s=t?t(a):a;if(!i||!La(s,l)){var l=s;r[o++]=0===a?0:a}}return r}function oo(e){return"number"==typeof e?e:os(e)?u:+e}function ro(e){if("string"==typeof e)return e;if(Ha(e))return It(e,ro)+"";if(os(e))return Mi?Mi.call(e):"";var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}function ao(e,t,i){var n=-1,o=Et,r=e.length,a=!0,s=[],l=s;if(i)a=!1,o=kt;else if(r>=200){var c=t?null:zo(e);if(c)return ai(c);a=!1,o=Yt,l=new Gi}else l=t?[]:s;e:for(;++n<r;){var d=e[n],u=t?t(d):d;if(d=i||0!==d?d:0,a&&u==u){for(var h=l.length;h--;)if(l[h]===u)continue e;t&&l.push(u),s.push(d)}else o(l,u,i)||(l!==s&&l.push(u),s.push(d))}return s}function so(e,t){return null==(e=wr(e,t=mo(t,e)))||delete e[Nr(zr(t))]}function lo(e,t,i,n){return qn(e,t,i(bn(e,t)),n)}function co(e,t,i,n){for(var o=e.length,r=n?o:-1;(n?r--:++r<o)&&t(e[r],r,e););return i?Qn(e,n?0:r,n?r+1:o):Qn(e,n?r+1:0,n?o:r)}function uo(e,t){var i=e;return i instanceof Hi&&(i=i.value()),_t(t,(function(e,t){return t.func.apply(t.thisArg,Dt([e],t.args))}),i)}function ho(e,t,i){var n=e.length;if(n<2)return n?ao(e[0]):[];for(var o=-1,r=ne(n);++o<n;)for(var a=e[o],s=-1;++s<n;)s!=o&&(r[o]=ln(r[o]||a,e[s],t,i));return ao(gn(r,1),t,i)}function po(e,t,i){for(var o=-1,r=e.length,a=t.length,s={};++o<r;){var l=o<a?t[o]:n;i(s,e[o],l)}return s}function go(e){return Va(e)?e:[]}function fo(e){return"function"==typeof e?e:Qs}function mo(e,t){return Ha(e)?e:vr(e,t)?[e]:_r(gs(e))}var vo=zn;function yo(e,t,i){var o=e.length;return i=i===n?o:i,!t&&i>=o?e:Qn(e,t,i)}var Co=lt||function(e){return dt.clearTimeout(e)};function bo(e,t){if(t)return e.slice();var i=e.length,n=Ve?Ve(i):new e.constructor(i);return e.copy(n),n}function So(e){var t=new e.constructor(e.byteLength);return new Ze(t).set(new Ze(e)),t}function xo(e,t){var i=t?So(e.buffer):e.buffer;return new e.constructor(i,e.byteOffset,e.length)}function To(e,t){if(e!==t){var i=e!==n,o=null===e,r=e==e,a=os(e),s=t!==n,l=null===t,c=t==t,d=os(t);if(!l&&!d&&!a&&e>t||a&&s&&c&&!l&&!d||o&&s&&c||!i&&c||!r)return 1;if(!o&&!a&&!d&&e<t||d&&i&&r&&!o&&!a||l&&i&&r||!s&&r||!c)return-1}return 0}function wo(e,t,i,n){for(var o=-1,r=e.length,a=i.length,s=-1,l=t.length,c=gi(r-a,0),d=ne(l+c),u=!n;++s<l;)d[s]=t[s];for(;++o<a;)(u||o<r)&&(d[i[o]]=e[o]);for(;c--;)d[s++]=e[o++];return d}function Oo(e,t,i,n){for(var o=-1,r=e.length,a=-1,s=i.length,l=-1,c=t.length,d=gi(r-s,0),u=ne(d+c),h=!n;++o<d;)u[o]=e[o];for(var p=o;++l<c;)u[p+l]=t[l];for(;++a<s;)(h||o<r)&&(u[p+i[a]]=e[o++]);return u}function Po(e,t){var i=-1,n=e.length;for(t||(t=ne(n));++i<n;)t[i]=e[i];return t}function Ao(e,t,i,o){var r=!i;i||(i={});for(var a=-1,s=t.length;++a<s;){var l=t[a],c=o?o(i[l],e[l],l,i,e):n;c===n&&(c=e[l]),r?tn(i,l,c):Xi(i,l,c)}return i}function Eo(e,t){return function(i,n){var o=Ha(i)?Tt:Qi,r=t?t():{};return o(i,e,rr(n,2),r)}}function ko(e){return zn((function(t,i){var o=-1,r=i.length,a=r>1?i[r-1]:n,s=r>2?i[2]:n;for(a=e.length>3&&"function"==typeof a?(r--,a):n,s&&mr(i[0],i[1],s)&&(a=r<3?n:a,r=1),t=we(t);++o<r;){var l=i[o];l&&e(t,l,o,a)}return t}))}function Io(e,t){return function(i,n){if(null==i)return i;if(!Za(i))return e(i,n);for(var o=i.length,r=t?o:-1,a=we(i);(t?r--:++r<o)&&!1!==n(a[r],r,a););return i}}function Do(e){return function(t,i,n){for(var o=-1,r=we(t),a=n(t),s=a.length;s--;){var l=a[e?s:++o];if(!1===i(r[l],l,r))break}return t}}function _o(e){return function(t){var i=ii(t=gs(t))?li(t):n,o=i?i[0]:t.charAt(0),r=i?yo(i,1).join(""):t.slice(1);return o[e]()+r}}function No(e){return function(t){return _t(Ws(Us(t).replace(qe,"")),e,"")}}function Ro(e){return function(){var t=arguments;switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3]);case 5:return new e(t[0],t[1],t[2],t[3],t[4]);case 6:return new e(t[0],t[1],t[2],t[3],t[4],t[5]);case 7:return new e(t[0],t[1],t[2],t[3],t[4],t[5],t[6])}var i=Bi(e.prototype),n=e.apply(i,t);return Ya(n)?n:i}}function Mo(e){return function(t,i,o){var r=we(t);if(!Za(t)){var a=rr(i,3);t=As(t),i=function(e){return a(r[e],e,r)}}var s=e(t,i,o);return s>-1?r[a?t[s]:s]:n}}function Lo(e){return Qo((function(t){var i=t.length,r=i,a=Ui.prototype.thru;for(e&&t.reverse();r--;){var s=t[r];if("function"!=typeof s)throw new Ae(o);if(a&&!l&&"wrapper"==nr(s))var l=new Ui([],!0)}for(r=l?r:i;++r<i;){var c=nr(s=t[r]),d="wrapper"==c?ir(s):n;l=d&&yr(d[0])&&424==d[1]&&!d[4].length&&1==d[9]?l[nr(d[0])].apply(l,d[3]):1==s.length&&yr(s)?l[c]():l.thru(s)}return function(){var e=arguments,n=e[0];if(l&&1==e.length&&Ha(n))return l.plant(n).value();for(var o=0,r=i?t[o].apply(this,e):n;++o<i;)r=t[o].call(this,r);return r}}))}function Bo(e,t,i,o,r,a,s,c,d,u){var h=t&l,p=1&t,g=2&t,f=24&t,m=512&t,v=g?n:Ro(e);return function l(){for(var y=arguments.length,C=ne(y),b=y;b--;)C[b]=arguments[b];if(f)var S=or(l),x=function(e,t){for(var i=e.length,n=0;i--;)e[i]===t&&++n;return n}(C,S);if(o&&(C=wo(C,o,r,f)),a&&(C=Oo(C,a,s,f)),y-=x,f&&y<u){var T=ri(C,S);return Go(e,t,Bo,l.placeholder,i,C,T,c,d,u-y)}var w=p?i:this,O=g?w[e]:e;return y=C.length,c?C=function(e,t){for(var i=e.length,o=fi(t.length,i),r=Po(e);o--;){var a=t[o];e[o]=fr(a,i)?r[a]:n}return e}(C,c):m&&y>1&&C.reverse(),h&&d<y&&(C.length=d),this&&this!==dt&&this instanceof l&&(O=v||Ro(O)),O.apply(w,C)}}function Fo(e,t){return function(i,n){return function(e,t,i,n){return vn(e,(function(e,o,r){t(n,i(e),o,r)})),n}(i,e,t(n),{})}}function Uo(e,t){return function(i,o){var r;if(i===n&&o===n)return t;if(i!==n&&(r=i),o!==n){if(r===n)return o;"string"==typeof i||"string"==typeof o?(i=ro(i),o=ro(o)):(i=oo(i),o=oo(o)),r=e(i,o)}return r}}function Ho(e){return Qo((function(t){return t=It(t,Kt(rr())),zn((function(i){var n=this;return e(t,(function(e){return xt(e,n,i)}))}))}))}function $o(e,t){var i=(t=t===n?" ":ro(t)).length;if(i<2)return i?jn(t,e):t;var o=jn(t,ht(e/si(t)));return ii(t)?yo(li(o),0,e).join(""):o.slice(0,e)}function Zo(e){return function(t,i,o){return o&&"number"!=typeof o&&mr(t,i,o)&&(i=o=n),t=cs(t),i===n?(i=t,t=0):i=cs(i),function(e,t,i,n){for(var o=-1,r=gi(ht((t-e)/(i||1)),0),a=ne(r);r--;)a[n?r:++o]=e,e+=i;return a}(t,i,o=o===n?t<i?1:-1:cs(o),e)}}function Vo(e){return function(t,i){return"string"==typeof t&&"string"==typeof i||(t=hs(t),i=hs(i)),e(t,i)}}function Go(e,t,i,o,r,a,l,c,d,u){var h=8&t;t|=h?s:64,4&(t&=~(h?64:s))||(t&=-4);var p=[e,t,r,h?a:n,h?l:n,h?n:a,h?n:l,c,d,u],g=i.apply(n,p);return yr(e)&&Pr(g,p),g.placeholder=o,kr(g,e,t)}function jo(e){var t=Te[e];return function(e,i){if(e=hs(e),(i=null==i?0:fi(ds(i),292))&&Vt(e)){var n=(gs(e)+"e").split("e");return+((n=(gs(t(n[0]+"e"+(+n[1]+i)))+"e").split("e"))[0]+"e"+(+n[1]-i))}return t(e)}}var zo=Ti&&1/ai(new Ti([,-0]))[1]==c?function(e){return new Ti(e)}:ol;function Wo(e){return function(t){var i=ur(t);return i==S?ni(t):i==P?function(e){var t=-1,i=Array(e.size);return e.forEach((function(e){i[++t]=[e,e]})),i}(t):function(e,t){return It(t,(function(t){return[t,e[t]]}))}(t,e(t))}}function Ko(e,t,i,r,c,d,u,h){var p=2&t;if(!p&&"function"!=typeof e)throw new Ae(o);var g=r?r.length:0;if(g||(t&=-97,r=c=n),u=u===n?u:gi(ds(u),0),h=h===n?h:ds(h),g-=c?c.length:0,64&t){var f=r,m=c;r=c=n}var v=p?n:ir(e),y=[e,t,i,r,c,f,m,d,u,h];if(v&&function(e,t){var i=e[1],n=t[1],o=i|n,r=o<131,s=n==l&&8==i||n==l&&256==i&&e[7].length<=t[8]||384==n&&t[7].length<=t[8]&&8==i;if(!r&&!s)return e;1&n&&(e[2]=t[2],o|=1&i?0:4);var c=t[3];if(c){var d=e[3];e[3]=d?wo(d,c,t[4]):c,e[4]=d?ri(e[3],a):t[4]}(c=t[5])&&(d=e[5],e[5]=d?Oo(d,c,t[6]):c,e[6]=d?ri(e[5],a):t[6]),(c=t[7])&&(e[7]=c),n&l&&(e[8]=null==e[8]?t[8]:fi(e[8],t[8])),null==e[9]&&(e[9]=t[9]),e[0]=t[0],e[1]=o}(y,v),e=y[0],t=y[1],i=y[2],r=y[3],c=y[4],!(h=y[9]=y[9]===n?p?0:e.length:gi(y[9]-g,0))&&24&t&&(t&=-25),t&&1!=t)C=8==t||16==t?function(e,t,i){var o=Ro(e);return function r(){for(var a=arguments.length,s=ne(a),l=a,c=or(r);l--;)s[l]=arguments[l];var d=a<3&&s[0]!==c&&s[a-1]!==c?[]:ri(s,c);return(a-=d.length)<i?Go(e,t,Bo,r.placeholder,n,s,d,n,n,i-a):xt(this&&this!==dt&&this instanceof r?o:e,this,s)}}(e,t,h):t!=s&&33!=t||c.length?Bo.apply(n,y):function(e,t,i,n){var o=1&t,r=Ro(e);return function t(){for(var a=-1,s=arguments.length,l=-1,c=n.length,d=ne(c+s),u=this&&this!==dt&&this instanceof t?r:e;++l<c;)d[l]=n[l];for(;s--;)d[l++]=arguments[++a];return xt(u,o?i:this,d)}}(e,t,i,r);else var C=function(e,t,i){var n=1&t,o=Ro(e);return function t(){return(this&&this!==dt&&this instanceof t?o:e).apply(n?i:this,arguments)}}(e,t,i);return kr((v?Yn:Pr)(C,y),e,t)}function qo(e,t,i,o){return e===n||La(e,Ie[i])&&!Ne.call(o,i)?t:e}function Yo(e,t,i,o,r,a){return Ya(e)&&Ya(t)&&(a.set(t,e),Fn(e,t,n,Yo,a),a.delete(t)),e}function Xo(e){return es(e)?n:e}function Jo(e,t,i,o,r,a){var s=1&i,l=e.length,c=t.length;if(l!=c&&!(s&&c>l))return!1;var d=a.get(e),u=a.get(t);if(d&&u)return d==t&&u==e;var h=-1,p=!0,g=2&i?new Gi:n;for(a.set(e,t),a.set(t,e);++h<l;){var f=e[h],m=t[h];if(o)var v=s?o(m,f,h,t,e,a):o(f,m,h,e,t,a);if(v!==n){if(v)continue;p=!1;break}if(g){if(!Rt(t,(function(e,t){if(!Yt(g,t)&&(f===e||r(f,e,i,o,a)))return g.push(t)}))){p=!1;break}}else if(f!==m&&!r(f,m,i,o,a)){p=!1;break}}return a.delete(e),a.delete(t),p}function Qo(e){return Er(Tr(e,n,$r),e+"")}function er(e){return Sn(e,As,cr)}function tr(e){return Sn(e,Es,dr)}var ir=Pi?function(e){return Pi.get(e)}:ol;function nr(e){for(var t=e.name+"",i=Ai[t],n=Ne.call(Ai,t)?i.length:0;n--;){var o=i[n],r=o.func;if(null==r||r==e)return o.name}return t}function or(e){return(Ne.call(Li,"placeholder")?Li:e).placeholder}function rr(){var e=Li.iteratee||el;return e=e===el?_n:e,arguments.length?e(arguments[0],arguments[1]):e}function ar(e,t){var i,n,o=e.__data__;return("string"==(n=typeof(i=t))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==i:null===i)?o["string"==typeof t?"string":"hash"]:o.map}function sr(e){for(var t=As(e),i=t.length;i--;){var n=t[i],o=e[n];t[i]=[n,o,Sr(o)]}return t}function lr(e,t){var i=function(e,t){return null==e?n:e[t]}(e,t);return Dn(i)?i:n}var cr=ft?function(e){return null==e?[]:(e=we(e),At(ft(e),(function(t){return ze.call(e,t)})))}:ul,dr=ft?function(e){for(var t=[];e;)Dt(t,cr(e)),e=Ge(e);return t}:ul,ur=xn;function hr(e,t,i){for(var n=-1,o=(t=mo(t,e)).length,r=!1;++n<o;){var a=Nr(t[n]);if(!(r=null!=e&&i(e,a)))break;e=e[a]}return r||++n!=o?r:!!(o=null==e?0:e.length)&&qa(o)&&fr(a,o)&&(Ha(e)||Ua(e))}function pr(e){return"function"!=typeof e.constructor||br(e)?{}:Bi(Ge(e))}function gr(e){return Ha(e)||Ua(e)||!!(Ke&&e&&e[Ke])}function fr(e,t){var i=typeof e;return!!(t=null==t?d:t)&&("number"==i||"symbol"!=i&&me.test(e))&&e>-1&&e%1==0&&e<t}function mr(e,t,i){if(!Ya(i))return!1;var n=typeof t;return!!("number"==n?Za(i)&&fr(t,i.length):"string"==n&&t in i)&&La(i[t],e)}function vr(e,t){if(Ha(e))return!1;var i=typeof e;return!("number"!=i&&"symbol"!=i&&"boolean"!=i&&null!=e&&!os(e))||J.test(e)||!X.test(e)||null!=t&&e in we(t)}function yr(e){var t=nr(e),i=Li[t];if("function"!=typeof i||!(t in Hi.prototype))return!1;if(e===i)return!0;var n=ir(i);return!!n&&e===n[0]}(bi&&ur(new bi(new ArrayBuffer(1)))!=D||Si&&ur(new Si)!=S||xi&&ur(xi.resolve())!=w||Ti&&ur(new Ti)!=P||wi&&ur(new wi)!=k)&&(ur=function(e){var t=xn(e),i=t==T?e.constructor:n,o=i?Rr(i):"";if(o)switch(o){case Ei:return D;case ki:return S;case Ii:return w;case Di:return P;case _i:return k}return t});var Cr=De?Wa:hl;function br(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||Ie)}function Sr(e){return e==e&&!Ya(e)}function xr(e,t){return function(i){return null!=i&&i[e]===t&&(t!==n||e in we(i))}}function Tr(e,t,i){return t=gi(t===n?e.length-1:t,0),function(){for(var n=arguments,o=-1,r=gi(n.length-t,0),a=ne(r);++o<r;)a[o]=n[t+o];o=-1;for(var s=ne(t+1);++o<t;)s[o]=n[o];return s[t]=i(a),xt(e,this,s)}}function wr(e,t){return t.length<2?e:bn(e,Qn(t,0,-1))}function Or(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]}var Pr=Ir(Yn),Ar=ut||function(e,t){return dt.setTimeout(e,t)},Er=Ir(Xn);function kr(e,t,i){var n=t+"";return Er(e,function(e,t){var i=t.length;if(!i)return e;var n=i-1;return t[n]=(i>1?"& ":"")+t[n],t=t.join(i>2?", ":" "),e.replace(oe,"{\n/* [wrapped with "+t+"] */\n")}(n,function(e,t){return wt(p,(function(i){var n="_."+i[0];t&i[1]&&!Et(e,n)&&e.push(n)})),e.sort()}(function(e){var t=e.match(re);return t?t[1].split(ae):[]}(n),i)))}function Ir(e){var t=0,i=0;return function(){var o=mi(),r=16-(o-i);if(i=o,r>0){if(++t>=800)return arguments[0]}else t=0;return e.apply(n,arguments)}}function Dr(e,t){var i=-1,o=e.length,r=o-1;for(t=t===n?o:t;++i<t;){var a=Gn(i,r),s=e[a];e[a]=e[i],e[i]=s}return e.length=t,e}var _r=function(e){var t=Ia((function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(Q,(function(e,i,n,o){t.push(n?o.replace(ce,"$1"):i||e)})),t}),(function(e){return 500===i.size&&i.clear(),e})),i=t.cache;return t}();function Nr(e){if("string"==typeof e||os(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}function Rr(e){if(null!=e){try{return _e.call(e)}catch(e){}try{return e+""}catch(e){}}return""}function Mr(e){if(e instanceof Hi)return e.clone();var t=new Ui(e.__wrapped__,e.__chain__);return t.__actions__=Po(e.__actions__),t.__index__=e.__index__,t.__values__=e.__values__,t}var Lr=zn((function(e,t){return Va(e)?ln(e,gn(t,1,Va,!0)):[]})),Br=zn((function(e,t){var i=zr(t);return Va(i)&&(i=n),Va(e)?ln(e,gn(t,1,Va,!0),rr(i,2)):[]})),Fr=zn((function(e,t){var i=zr(t);return Va(i)&&(i=n),Va(e)?ln(e,gn(t,1,Va,!0),n,i):[]}));function Ur(e,t,i){var n=null==e?0:e.length;if(!n)return-1;var o=null==i?0:ds(i);return o<0&&(o=gi(n+o,0)),Bt(e,rr(t,3),o)}function Hr(e,t,i){var o=null==e?0:e.length;if(!o)return-1;var r=o-1;return i!==n&&(r=ds(i),r=i<0?gi(o+r,0):fi(r,o-1)),Bt(e,rr(t,3),r,!0)}function $r(e){return null!=e&&e.length?gn(e,1):[]}function Zr(e){return e&&e.length?e[0]:n}var Vr=zn((function(e){var t=It(e,go);return t.length&&t[0]===e[0]?Pn(t):[]})),Gr=zn((function(e){var t=zr(e),i=It(e,go);return t===zr(i)?t=n:i.pop(),i.length&&i[0]===e[0]?Pn(i,rr(t,2)):[]})),jr=zn((function(e){var t=zr(e),i=It(e,go);return(t="function"==typeof t?t:n)&&i.pop(),i.length&&i[0]===e[0]?Pn(i,n,t):[]}));function zr(e){var t=null==e?0:e.length;return t?e[t-1]:n}var Wr=zn(Kr);function Kr(e,t){return e&&e.length&&t&&t.length?Zn(e,t):e}var qr=Qo((function(e,t){var i=null==e?0:e.length,n=nn(e,t);return Vn(e,It(t,(function(e){return fr(e,i)?+e:e})).sort(To)),n}));function Yr(e){return null==e?e:Ci.call(e)}var Xr=zn((function(e){return ao(gn(e,1,Va,!0))})),Jr=zn((function(e){var t=zr(e);return Va(t)&&(t=n),ao(gn(e,1,Va,!0),rr(t,2))})),Qr=zn((function(e){var t=zr(e);return t="function"==typeof t?t:n,ao(gn(e,1,Va,!0),n,t)}));function ea(e){if(!e||!e.length)return[];var t=0;return e=At(e,(function(e){if(Va(e))return t=gi(e.length,t),!0})),zt(t,(function(t){return It(e,Zt(t))}))}function ta(e,t){if(!e||!e.length)return[];var i=ea(e);return null==t?i:It(i,(function(e){return xt(t,n,e)}))}var ia=zn((function(e,t){return Va(e)?ln(e,t):[]})),na=zn((function(e){return ho(At(e,Va))})),oa=zn((function(e){var t=zr(e);return Va(t)&&(t=n),ho(At(e,Va),rr(t,2))})),ra=zn((function(e){var t=zr(e);return t="function"==typeof t?t:n,ho(At(e,Va),n,t)})),aa=zn(ea),sa=zn((function(e){var t=e.length,i=t>1?e[t-1]:n;return i="function"==typeof i?(e.pop(),i):n,ta(e,i)}));function la(e){var t=Li(e);return t.__chain__=!0,t}function ca(e,t){return t(e)}var da=Qo((function(e){var t=e.length,i=t?e[0]:0,o=this.__wrapped__,r=function(t){return nn(t,e)};return!(t>1||this.__actions__.length)&&o instanceof Hi&&fr(i)?((o=o.slice(i,+i+(t?1:0))).__actions__.push({func:ca,args:[r],thisArg:n}),new Ui(o,this.__chain__).thru((function(e){return t&&!e.length&&e.push(n),e}))):this.thru(r)})),ua=Eo((function(e,t,i){Ne.call(e,i)?++e[i]:tn(e,i,1)})),ha=Mo(Ur),pa=Mo(Hr);function ga(e,t){return(Ha(e)?wt:cn)(e,rr(t,3))}function fa(e,t){return(Ha(e)?Ot:dn)(e,rr(t,3))}var ma=Eo((function(e,t,i){Ne.call(e,i)?e[i].push(t):tn(e,i,[t])})),va=zn((function(e,t,i){var n=-1,o="function"==typeof t,r=Za(e)?ne(e.length):[];return cn(e,(function(e){r[++n]=o?xt(t,e,i):An(e,t,i)})),r})),ya=Eo((function(e,t,i){tn(e,i,t)}));function Ca(e,t){return(Ha(e)?It:Mn)(e,rr(t,3))}var ba=Eo((function(e,t,i){e[i?0:1].push(t)}),(function(){return[[],[]]})),Sa=zn((function(e,t){if(null==e)return[];var i=t.length;return i>1&&mr(e,t[0],t[1])?t=[]:i>2&&mr(t[0],t[1],t[2])&&(t=[t[0]]),Hn(e,gn(t,1),[])})),xa=ct||function(){return dt.Date.now()};function Ta(e,t,i){return t=i?n:t,t=e&&null==t?e.length:t,Ko(e,l,n,n,n,n,t)}function wa(e,t){var i;if("function"!=typeof t)throw new Ae(o);return e=ds(e),function(){return--e>0&&(i=t.apply(this,arguments)),e<=1&&(t=n),i}}var Oa=zn((function(e,t,i){var n=1;if(i.length){var o=ri(i,or(Oa));n|=s}return Ko(e,n,t,i,o)})),Pa=zn((function(e,t,i){var n=3;if(i.length){var o=ri(i,or(Pa));n|=s}return Ko(t,n,e,i,o)}));function Aa(e,t,i){var r,a,s,l,c,d,u=0,h=!1,p=!1,g=!0;if("function"!=typeof e)throw new Ae(o);function f(t){var i=r,o=a;return r=a=n,u=t,l=e.apply(o,i)}function m(e){var i=e-d;return d===n||i>=t||i<0||p&&e-u>=s}function v(){var e=xa();if(m(e))return y(e);c=Ar(v,function(e){var i=t-(e-d);return p?fi(i,s-(e-u)):i}(e))}function y(e){return c=n,g&&r?f(e):(r=a=n,l)}function C(){var e=xa(),i=m(e);if(r=arguments,a=this,d=e,i){if(c===n)return function(e){return u=e,c=Ar(v,t),h?f(e):l}(d);if(p)return Co(c),c=Ar(v,t),f(d)}return c===n&&(c=Ar(v,t)),l}return t=hs(t)||0,Ya(i)&&(h=!!i.leading,s=(p="maxWait"in i)?gi(hs(i.maxWait)||0,t):s,g="trailing"in i?!!i.trailing:g),C.cancel=function(){c!==n&&Co(c),u=0,r=d=a=c=n},C.flush=function(){return c===n?l:y(xa())},C}var Ea=zn((function(e,t){return sn(e,1,t)})),ka=zn((function(e,t,i){return sn(e,hs(t)||0,i)}));function Ia(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new Ae(o);var i=function(){var n=arguments,o=t?t.apply(this,n):n[0],r=i.cache;if(r.has(o))return r.get(o);var a=e.apply(this,n);return i.cache=r.set(o,a)||r,a};return i.cache=new(Ia.Cache||Vi),i}function Da(e){if("function"!=typeof e)throw new Ae(o);return function(){var t=arguments;switch(t.length){case 0:return!e.call(this);case 1:return!e.call(this,t[0]);case 2:return!e.call(this,t[0],t[1]);case 3:return!e.call(this,t[0],t[1],t[2])}return!e.apply(this,t)}}Ia.Cache=Vi;var _a=vo((function(e,t){var i=(t=1==t.length&&Ha(t[0])?It(t[0],Kt(rr())):It(gn(t,1),Kt(rr()))).length;return zn((function(n){for(var o=-1,r=fi(n.length,i);++o<r;)n[o]=t[o].call(this,n[o]);return xt(e,this,n)}))})),Na=zn((function(e,t){var i=ri(t,or(Na));return Ko(e,s,n,t,i)})),Ra=zn((function(e,t){var i=ri(t,or(Ra));return Ko(e,64,n,t,i)})),Ma=Qo((function(e,t){return Ko(e,256,n,n,n,t)}));function La(e,t){return e===t||e!=e&&t!=t}var Ba=Vo(Tn),Fa=Vo((function(e,t){return e>=t})),Ua=En(function(){return arguments}())?En:function(e){return Xa(e)&&Ne.call(e,"callee")&&!ze.call(e,"callee")},Ha=ne.isArray,$a=mt?Kt(mt):function(e){return Xa(e)&&xn(e)==I};function Za(e){return null!=e&&qa(e.length)&&!Wa(e)}function Va(e){return Xa(e)&&Za(e)}var Ga=Mt||hl,ja=vt?Kt(vt):function(e){return Xa(e)&&xn(e)==v};function za(e){if(!Xa(e))return!1;var t=xn(e);return t==y||"[object DOMException]"==t||"string"==typeof e.message&&"string"==typeof e.name&&!es(e)}function Wa(e){if(!Ya(e))return!1;var t=xn(e);return t==C||t==b||"[object AsyncFunction]"==t||"[object Proxy]"==t}function Ka(e){return"number"==typeof e&&e==ds(e)}function qa(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=d}function Ya(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function Xa(e){return null!=e&&"object"==typeof e}var Ja=yt?Kt(yt):function(e){return Xa(e)&&ur(e)==S};function Qa(e){return"number"==typeof e||Xa(e)&&xn(e)==x}function es(e){if(!Xa(e)||xn(e)!=T)return!1;var t=Ge(e);if(null===t)return!0;var i=Ne.call(t,"constructor")&&t.constructor;return"function"==typeof i&&i instanceof i&&_e.call(i)==Be}var ts=Ct?Kt(Ct):function(e){return Xa(e)&&xn(e)==O},is=bt?Kt(bt):function(e){return Xa(e)&&ur(e)==P};function ns(e){return"string"==typeof e||!Ha(e)&&Xa(e)&&xn(e)==A}function os(e){return"symbol"==typeof e||Xa(e)&&xn(e)==E}var rs=St?Kt(St):function(e){return Xa(e)&&qa(e.length)&&!!nt[xn(e)]},as=Vo(Rn),ss=Vo((function(e,t){return e<=t}));function ls(e){if(!e)return[];if(Za(e))return ns(e)?li(e):Po(e);if(Xe&&e[Xe])return function(e){for(var t,i=[];!(t=e.next()).done;)i.push(t.value);return i}(e[Xe]());var t=ur(e);return(t==S?ni:t==P?ai:Ls)(e)}function cs(e){return e?(e=hs(e))===c||e===-1/0?17976931348623157e292*(e<0?-1:1):e==e?e:0:0===e?e:0}function ds(e){var t=cs(e),i=t%1;return t==t?i?t-i:t:0}function us(e){return e?on(ds(e),0,h):0}function hs(e){if("number"==typeof e)return e;if(os(e))return u;if(Ya(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=Ya(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=Wt(e);var i=pe.test(e);return i||fe.test(e)?st(e.slice(2),i?2:8):he.test(e)?u:+e}function ps(e){return Ao(e,Es(e))}function gs(e){return null==e?"":ro(e)}var fs=ko((function(e,t){if(br(t)||Za(t))Ao(t,As(t),e);else for(var i in t)Ne.call(t,i)&&Xi(e,i,t[i])})),ms=ko((function(e,t){Ao(t,Es(t),e)})),vs=ko((function(e,t,i,n){Ao(t,Es(t),e,n)})),ys=ko((function(e,t,i,n){Ao(t,As(t),e,n)})),Cs=Qo(nn),bs=zn((function(e,t){e=we(e);var i=-1,o=t.length,r=o>2?t[2]:n;for(r&&mr(t[0],t[1],r)&&(o=1);++i<o;)for(var a=t[i],s=Es(a),l=-1,c=s.length;++l<c;){var d=s[l],u=e[d];(u===n||La(u,Ie[d])&&!Ne.call(e,d))&&(e[d]=a[d])}return e})),Ss=zn((function(e){return e.push(n,Yo),xt(Is,n,e)}));function xs(e,t,i){var o=null==e?n:bn(e,t);return o===n?i:o}function Ts(e,t){return null!=e&&hr(e,t,On)}var ws=Fo((function(e,t,i){null!=t&&"function"!=typeof t.toString&&(t=Le.call(t)),e[t]=i}),Ys(Qs)),Os=Fo((function(e,t,i){null!=t&&"function"!=typeof t.toString&&(t=Le.call(t)),Ne.call(e,t)?e[t].push(i):e[t]=[i]}),rr),Ps=zn(An);function As(e){return Za(e)?zi(e):Nn(e)}function Es(e){return Za(e)?zi(e,!0):function(e){if(!Ya(e))return function(e){var t=[];if(null!=e)for(var i in we(e))t.push(i);return t}(e);var t=br(e),i=[];for(var n in e)("constructor"!=n||!t&&Ne.call(e,n))&&i.push(n);return i}(e)}var ks=ko((function(e,t,i){Fn(e,t,i)})),Is=ko((function(e,t,i,n){Fn(e,t,i,n)})),Ds=Qo((function(e,t){var i={};if(null==e)return i;var n=!1;t=It(t,(function(t){return t=mo(t,e),n||(n=t.length>1),t})),Ao(e,tr(e),i),n&&(i=rn(i,7,Xo));for(var o=t.length;o--;)so(i,t[o]);return i})),_s=Qo((function(e,t){return null==e?{}:function(e,t){return $n(e,t,(function(t,i){return Ts(e,i)}))}(e,t)}));function Ns(e,t){if(null==e)return{};var i=It(tr(e),(function(e){return[e]}));return t=rr(t),$n(e,i,(function(e,i){return t(e,i[0])}))}var Rs=Wo(As),Ms=Wo(Es);function Ls(e){return null==e?[]:qt(e,As(e))}var Bs=No((function(e,t,i){return t=t.toLowerCase(),e+(i?Fs(t):t)}));function Fs(e){return zs(gs(e).toLowerCase())}function Us(e){return(e=gs(e))&&e.replace(ve,Qt).replace(Ye,"")}var Hs=No((function(e,t,i){return e+(i?"-":"")+t.toLowerCase()})),$s=No((function(e,t,i){return e+(i?" ":"")+t.toLowerCase()})),Zs=_o("toLowerCase"),Vs=No((function(e,t,i){return e+(i?"_":"")+t.toLowerCase()})),Gs=No((function(e,t,i){return e+(i?" ":"")+zs(t)})),js=No((function(e,t,i){return e+(i?" ":"")+t.toUpperCase()})),zs=_o("toUpperCase");function Ws(e,t,i){return e=gs(e),(t=i?n:t)===n?function(e){return et.test(e)}(e)?function(e){return e.match(Je)||[]}(e):function(e){return e.match(se)||[]}(e):e.match(t)||[]}var Ks=zn((function(e,t){try{return xt(e,n,t)}catch(e){return za(e)?e:new Se(e)}})),qs=Qo((function(e,t){return wt(t,(function(t){t=Nr(t),tn(e,t,Oa(e[t],e))})),e}));function Ys(e){return function(){return e}}var Xs=Lo(),Js=Lo(!0);function Qs(e){return e}function el(e){return _n("function"==typeof e?e:rn(e,1))}var tl=zn((function(e,t){return function(i){return An(i,e,t)}})),il=zn((function(e,t){return function(i){return An(e,i,t)}}));function nl(e,t,i){var n=As(t),o=Cn(t,n);null!=i||Ya(t)&&(o.length||!n.length)||(i=t,t=e,e=this,o=Cn(t,As(t)));var r=!(Ya(i)&&"chain"in i&&!i.chain),a=Wa(e);return wt(o,(function(i){var n=t[i];e[i]=n,a&&(e.prototype[i]=function(){var t=this.__chain__;if(r||t){var i=e(this.__wrapped__);return(i.__actions__=Po(this.__actions__)).push({func:n,args:arguments,thisArg:e}),i.__chain__=t,i}return n.apply(e,Dt([this.value()],arguments))})})),e}function ol(){}var rl=Ho(It),al=Ho(Pt),sl=Ho(Rt);function ll(e){return vr(e)?Zt(Nr(e)):function(e){return function(t){return bn(t,e)}}(e)}var cl=Zo(),dl=Zo(!0);function ul(){return[]}function hl(){return!1}var pl,gl=Uo((function(e,t){return e+t}),0),fl=jo("ceil"),ml=Uo((function(e,t){return e/t}),1),vl=jo("floor"),yl=Uo((function(e,t){return e*t}),1),Cl=jo("round"),bl=Uo((function(e,t){return e-t}),0);return Li.after=function(e,t){if("function"!=typeof t)throw new Ae(o);return e=ds(e),function(){if(--e<1)return t.apply(this,arguments)}},Li.ary=Ta,Li.assign=fs,Li.assignIn=ms,Li.assignInWith=vs,Li.assignWith=ys,Li.at=Cs,Li.before=wa,Li.bind=Oa,Li.bindAll=qs,Li.bindKey=Pa,Li.castArray=function(){if(!arguments.length)return[];var e=arguments[0];return Ha(e)?e:[e]},Li.chain=la,Li.chunk=function(e,t,i){t=(i?mr(e,t,i):t===n)?1:gi(ds(t),0);var o=null==e?0:e.length;if(!o||t<1)return[];for(var r=0,a=0,s=ne(ht(o/t));r<o;)s[a++]=Qn(e,r,r+=t);return s},Li.compact=function(e){for(var t=-1,i=null==e?0:e.length,n=0,o=[];++t<i;){var r=e[t];r&&(o[n++]=r)}return o},Li.concat=function(){var e=arguments.length;if(!e)return[];for(var t=ne(e-1),i=arguments[0],n=e;n--;)t[n-1]=arguments[n];return Dt(Ha(i)?Po(i):[i],gn(t,1))},Li.cond=function(e){var t=null==e?0:e.length,i=rr();return e=t?It(e,(function(e){if("function"!=typeof e[1])throw new Ae(o);return[i(e[0]),e[1]]})):[],zn((function(i){for(var n=-1;++n<t;){var o=e[n];if(xt(o[0],this,i))return xt(o[1],this,i)}}))},Li.conforms=function(e){return function(e){var t=As(e);return function(i){return an(i,e,t)}}(rn(e,1))},Li.constant=Ys,Li.countBy=ua,Li.create=function(e,t){var i=Bi(e);return null==t?i:en(i,t)},Li.curry=function e(t,i,o){var r=Ko(t,8,n,n,n,n,n,i=o?n:i);return r.placeholder=e.placeholder,r},Li.curryRight=function e(t,i,o){var r=Ko(t,16,n,n,n,n,n,i=o?n:i);return r.placeholder=e.placeholder,r},Li.debounce=Aa,Li.defaults=bs,Li.defaultsDeep=Ss,Li.defer=Ea,Li.delay=ka,Li.difference=Lr,Li.differenceBy=Br,Li.differenceWith=Fr,Li.drop=function(e,t,i){var o=null==e?0:e.length;return o?Qn(e,(t=i||t===n?1:ds(t))<0?0:t,o):[]},Li.dropRight=function(e,t,i){var o=null==e?0:e.length;return o?Qn(e,0,(t=o-(t=i||t===n?1:ds(t)))<0?0:t):[]},Li.dropRightWhile=function(e,t){return e&&e.length?co(e,rr(t,3),!0,!0):[]},Li.dropWhile=function(e,t){return e&&e.length?co(e,rr(t,3),!0):[]},Li.fill=function(e,t,i,o){var r=null==e?0:e.length;return r?(i&&"number"!=typeof i&&mr(e,t,i)&&(i=0,o=r),function(e,t,i,o){var r=e.length;for((i=ds(i))<0&&(i=-i>r?0:r+i),(o=o===n||o>r?r:ds(o))<0&&(o+=r),o=i>o?0:us(o);i<o;)e[i++]=t;return e}(e,t,i,o)):[]},Li.filter=function(e,t){return(Ha(e)?At:pn)(e,rr(t,3))},Li.flatMap=function(e,t){return gn(Ca(e,t),1)},Li.flatMapDeep=function(e,t){return gn(Ca(e,t),c)},Li.flatMapDepth=function(e,t,i){return i=i===n?1:ds(i),gn(Ca(e,t),i)},Li.flatten=$r,Li.flattenDeep=function(e){return null!=e&&e.length?gn(e,c):[]},Li.flattenDepth=function(e,t){return null!=e&&e.length?gn(e,t=t===n?1:ds(t)):[]},Li.flip=function(e){return Ko(e,512)},Li.flow=Xs,Li.flowRight=Js,Li.fromPairs=function(e){for(var t=-1,i=null==e?0:e.length,n={};++t<i;){var o=e[t];n[o[0]]=o[1]}return n},Li.functions=function(e){return null==e?[]:Cn(e,As(e))},Li.functionsIn=function(e){return null==e?[]:Cn(e,Es(e))},Li.groupBy=ma,Li.initial=function(e){return null!=e&&e.length?Qn(e,0,-1):[]},Li.intersection=Vr,Li.intersectionBy=Gr,Li.intersectionWith=jr,Li.invert=ws,Li.invertBy=Os,Li.invokeMap=va,Li.iteratee=el,Li.keyBy=ya,Li.keys=As,Li.keysIn=Es,Li.map=Ca,Li.mapKeys=function(e,t){var i={};return t=rr(t,3),vn(e,(function(e,n,o){tn(i,t(e,n,o),e)})),i},Li.mapValues=function(e,t){var i={};return t=rr(t,3),vn(e,(function(e,n,o){tn(i,n,t(e,n,o))})),i},Li.matches=function(e){return Ln(rn(e,1))},Li.matchesProperty=function(e,t){return Bn(e,rn(t,1))},Li.memoize=Ia,Li.merge=ks,Li.mergeWith=Is,Li.method=tl,Li.methodOf=il,Li.mixin=nl,Li.negate=Da,Li.nthArg=function(e){return e=ds(e),zn((function(t){return Un(t,e)}))},Li.omit=Ds,Li.omitBy=function(e,t){return Ns(e,Da(rr(t)))},Li.once=function(e){return wa(2,e)},Li.orderBy=function(e,t,i,o){return null==e?[]:(Ha(t)||(t=null==t?[]:[t]),Ha(i=o?n:i)||(i=null==i?[]:[i]),Hn(e,t,i))},Li.over=rl,Li.overArgs=_a,Li.overEvery=al,Li.overSome=sl,Li.partial=Na,Li.partialRight=Ra,Li.partition=ba,Li.pick=_s,Li.pickBy=Ns,Li.property=ll,Li.propertyOf=function(e){return function(t){return null==e?n:bn(e,t)}},Li.pull=Wr,Li.pullAll=Kr,Li.pullAllBy=function(e,t,i){return e&&e.length&&t&&t.length?Zn(e,t,rr(i,2)):e},Li.pullAllWith=function(e,t,i){return e&&e.length&&t&&t.length?Zn(e,t,n,i):e},Li.pullAt=qr,Li.range=cl,Li.rangeRight=dl,Li.rearg=Ma,Li.reject=function(e,t){return(Ha(e)?At:pn)(e,Da(rr(t,3)))},Li.remove=function(e,t){var i=[];if(!e||!e.length)return i;var n=-1,o=[],r=e.length;for(t=rr(t,3);++n<r;){var a=e[n];t(a,n,e)&&(i.push(a),o.push(n))}return Vn(e,o),i},Li.rest=function(e,t){if("function"!=typeof e)throw new Ae(o);return zn(e,t=t===n?t:ds(t))},Li.reverse=Yr,Li.sampleSize=function(e,t,i){return t=(i?mr(e,t,i):t===n)?1:ds(t),(Ha(e)?Ki:Kn)(e,t)},Li.set=function(e,t,i){return null==e?e:qn(e,t,i)},Li.setWith=function(e,t,i,o){return o="function"==typeof o?o:n,null==e?e:qn(e,t,i,o)},Li.shuffle=function(e){return(Ha(e)?qi:Jn)(e)},Li.slice=function(e,t,i){var o=null==e?0:e.length;return o?(i&&"number"!=typeof i&&mr(e,t,i)?(t=0,i=o):(t=null==t?0:ds(t),i=i===n?o:ds(i)),Qn(e,t,i)):[]},Li.sortBy=Sa,Li.sortedUniq=function(e){return e&&e.length?no(e):[]},Li.sortedUniqBy=function(e,t){return e&&e.length?no(e,rr(t,2)):[]},Li.split=function(e,t,i){return i&&"number"!=typeof i&&mr(e,t,i)&&(t=i=n),(i=i===n?h:i>>>0)?(e=gs(e))&&("string"==typeof t||null!=t&&!ts(t))&&!(t=ro(t))&&ii(e)?yo(li(e),0,i):e.split(t,i):[]},Li.spread=function(e,t){if("function"!=typeof e)throw new Ae(o);return t=null==t?0:gi(ds(t),0),zn((function(i){var n=i[t],o=yo(i,0,t);return n&&Dt(o,n),xt(e,this,o)}))},Li.tail=function(e){var t=null==e?0:e.length;return t?Qn(e,1,t):[]},Li.take=function(e,t,i){return e&&e.length?Qn(e,0,(t=i||t===n?1:ds(t))<0?0:t):[]},Li.takeRight=function(e,t,i){var o=null==e?0:e.length;return o?Qn(e,(t=o-(t=i||t===n?1:ds(t)))<0?0:t,o):[]},Li.takeRightWhile=function(e,t){return e&&e.length?co(e,rr(t,3),!1,!0):[]},Li.takeWhile=function(e,t){return e&&e.length?co(e,rr(t,3)):[]},Li.tap=function(e,t){return t(e),e},Li.throttle=function(e,t,i){var n=!0,r=!0;if("function"!=typeof e)throw new Ae(o);return Ya(i)&&(n="leading"in i?!!i.leading:n,r="trailing"in i?!!i.trailing:r),Aa(e,t,{leading:n,maxWait:t,trailing:r})},Li.thru=ca,Li.toArray=ls,Li.toPairs=Rs,Li.toPairsIn=Ms,Li.toPath=function(e){return Ha(e)?It(e,Nr):os(e)?[e]:Po(_r(gs(e)))},Li.toPlainObject=ps,Li.transform=function(e,t,i){var n=Ha(e),o=n||Ga(e)||rs(e);if(t=rr(t,4),null==i){var r=e&&e.constructor;i=o?n?new r:[]:Ya(e)&&Wa(r)?Bi(Ge(e)):{}}return(o?wt:vn)(e,(function(e,n,o){return t(i,e,n,o)})),i},Li.unary=function(e){return Ta(e,1)},Li.union=Xr,Li.unionBy=Jr,Li.unionWith=Qr,Li.uniq=function(e){return e&&e.length?ao(e):[]},Li.uniqBy=function(e,t){return e&&e.length?ao(e,rr(t,2)):[]},Li.uniqWith=function(e,t){return t="function"==typeof t?t:n,e&&e.length?ao(e,n,t):[]},Li.unset=function(e,t){return null==e||so(e,t)},Li.unzip=ea,Li.unzipWith=ta,Li.update=function(e,t,i){return null==e?e:lo(e,t,fo(i))},Li.updateWith=function(e,t,i,o){return o="function"==typeof o?o:n,null==e?e:lo(e,t,fo(i),o)},Li.values=Ls,Li.valuesIn=function(e){return null==e?[]:qt(e,Es(e))},Li.without=ia,Li.words=Ws,Li.wrap=function(e,t){return Na(fo(t),e)},Li.xor=na,Li.xorBy=oa,Li.xorWith=ra,Li.zip=aa,Li.zipObject=function(e,t){return po(e||[],t||[],Xi)},Li.zipObjectDeep=function(e,t){return po(e||[],t||[],qn)},Li.zipWith=sa,Li.entries=Rs,Li.entriesIn=Ms,Li.extend=ms,Li.extendWith=vs,nl(Li,Li),Li.add=gl,Li.attempt=Ks,Li.camelCase=Bs,Li.capitalize=Fs,Li.ceil=fl,Li.clamp=function(e,t,i){return i===n&&(i=t,t=n),i!==n&&(i=(i=hs(i))==i?i:0),t!==n&&(t=(t=hs(t))==t?t:0),on(hs(e),t,i)},Li.clone=function(e){return rn(e,4)},Li.cloneDeep=function(e){return rn(e,5)},Li.cloneDeepWith=function(e,t){return rn(e,5,t="function"==typeof t?t:n)},Li.cloneWith=function(e,t){return rn(e,4,t="function"==typeof t?t:n)},Li.conformsTo=function(e,t){return null==t||an(e,t,As(t))},Li.deburr=Us,Li.defaultTo=function(e,t){return null==e||e!=e?t:e},Li.divide=ml,Li.endsWith=function(e,t,i){e=gs(e),t=ro(t);var o=e.length,r=i=i===n?o:on(ds(i),0,o);return(i-=t.length)>=0&&e.slice(i,r)==t},Li.eq=La,Li.escape=function(e){return(e=gs(e))&&W.test(e)?e.replace(j,ei):e},Li.escapeRegExp=function(e){return(e=gs(e))&&te.test(e)?e.replace(ee,"\\$&"):e},Li.every=function(e,t,i){var o=Ha(e)?Pt:un;return i&&mr(e,t,i)&&(t=n),o(e,rr(t,3))},Li.find=ha,Li.findIndex=Ur,Li.findKey=function(e,t){return Lt(e,rr(t,3),vn)},Li.findLast=pa,Li.findLastIndex=Hr,Li.findLastKey=function(e,t){return Lt(e,rr(t,3),yn)},Li.floor=vl,Li.forEach=ga,Li.forEachRight=fa,Li.forIn=function(e,t){return null==e?e:fn(e,rr(t,3),Es)},Li.forInRight=function(e,t){return null==e?e:mn(e,rr(t,3),Es)},Li.forOwn=function(e,t){return e&&vn(e,rr(t,3))},Li.forOwnRight=function(e,t){return e&&yn(e,rr(t,3))},Li.get=xs,Li.gt=Ba,Li.gte=Fa,Li.has=function(e,t){return null!=e&&hr(e,t,wn)},Li.hasIn=Ts,Li.head=Zr,Li.identity=Qs,Li.includes=function(e,t,i,n){e=Za(e)?e:Ls(e),i=i&&!n?ds(i):0;var o=e.length;return i<0&&(i=gi(o+i,0)),ns(e)?i<=o&&e.indexOf(t,i)>-1:!!o&&Ft(e,t,i)>-1},Li.indexOf=function(e,t,i){var n=null==e?0:e.length;if(!n)return-1;var o=null==i?0:ds(i);return o<0&&(o=gi(n+o,0)),Ft(e,t,o)},Li.inRange=function(e,t,i){return t=cs(t),i===n?(i=t,t=0):i=cs(i),function(e,t,i){return e>=fi(t,i)&&e<gi(t,i)}(e=hs(e),t,i)},Li.invoke=Ps,Li.isArguments=Ua,Li.isArray=Ha,Li.isArrayBuffer=$a,Li.isArrayLike=Za,Li.isArrayLikeObject=Va,Li.isBoolean=function(e){return!0===e||!1===e||Xa(e)&&xn(e)==m},Li.isBuffer=Ga,Li.isDate=ja,Li.isElement=function(e){return Xa(e)&&1===e.nodeType&&!es(e)},Li.isEmpty=function(e){if(null==e)return!0;if(Za(e)&&(Ha(e)||"string"==typeof e||"function"==typeof e.splice||Ga(e)||rs(e)||Ua(e)))return!e.length;var t=ur(e);if(t==S||t==P)return!e.size;if(br(e))return!Nn(e).length;for(var i in e)if(Ne.call(e,i))return!1;return!0},Li.isEqual=function(e,t){return kn(e,t)},Li.isEqualWith=function(e,t,i){var o=(i="function"==typeof i?i:n)?i(e,t):n;return o===n?kn(e,t,n,i):!!o},Li.isError=za,Li.isFinite=function(e){return"number"==typeof e&&Vt(e)},Li.isFunction=Wa,Li.isInteger=Ka,Li.isLength=qa,Li.isMap=Ja,Li.isMatch=function(e,t){return e===t||In(e,t,sr(t))},Li.isMatchWith=function(e,t,i){return i="function"==typeof i?i:n,In(e,t,sr(t),i)},Li.isNaN=function(e){return Qa(e)&&e!=+e},Li.isNative=function(e){if(Cr(e))throw new Se("Unsupported core-js use. Try https://npms.io/search?q=ponyfill.");return Dn(e)},Li.isNil=function(e){return null==e},Li.isNull=function(e){return null===e},Li.isNumber=Qa,Li.isObject=Ya,Li.isObjectLike=Xa,Li.isPlainObject=es,Li.isRegExp=ts,Li.isSafeInteger=function(e){return Ka(e)&&e>=-9007199254740991&&e<=d},Li.isSet=is,Li.isString=ns,Li.isSymbol=os,Li.isTypedArray=rs,Li.isUndefined=function(e){return e===n},Li.isWeakMap=function(e){return Xa(e)&&ur(e)==k},Li.isWeakSet=function(e){return Xa(e)&&"[object WeakSet]"==xn(e)},Li.join=function(e,t){return null==e?"":hi.call(e,t)},Li.kebabCase=Hs,Li.last=zr,Li.lastIndexOf=function(e,t,i){var o=null==e?0:e.length;if(!o)return-1;var r=o;return i!==n&&(r=(r=ds(i))<0?gi(o+r,0):fi(r,o-1)),t==t?function(e,t,i){for(var n=i+1;n--;)if(e[n]===t)return n;return n}(e,t,r):Bt(e,Ht,r,!0)},Li.lowerCase=$s,Li.lowerFirst=Zs,Li.lt=as,Li.lte=ss,Li.max=function(e){return e&&e.length?hn(e,Qs,Tn):n},Li.maxBy=function(e,t){return e&&e.length?hn(e,rr(t,2),Tn):n},Li.mean=function(e){return $t(e,Qs)},Li.meanBy=function(e,t){return $t(e,rr(t,2))},Li.min=function(e){return e&&e.length?hn(e,Qs,Rn):n},Li.minBy=function(e,t){return e&&e.length?hn(e,rr(t,2),Rn):n},Li.stubArray=ul,Li.stubFalse=hl,Li.stubObject=function(){return{}},Li.stubString=function(){return""},Li.stubTrue=function(){return!0},Li.multiply=yl,Li.nth=function(e,t){return e&&e.length?Un(e,ds(t)):n},Li.noConflict=function(){return dt._===this&&(dt._=Fe),this},Li.noop=ol,Li.now=xa,Li.pad=function(e,t,i){e=gs(e);var n=(t=ds(t))?si(e):0;if(!t||n>=t)return e;var o=(t-n)/2;return $o(gt(o),i)+e+$o(ht(o),i)},Li.padEnd=function(e,t,i){e=gs(e);var n=(t=ds(t))?si(e):0;return t&&n<t?e+$o(t-n,i):e},Li.padStart=function(e,t,i){e=gs(e);var n=(t=ds(t))?si(e):0;return t&&n<t?$o(t-n,i)+e:e},Li.parseInt=function(e,t,i){return i||null==t?t=0:t&&(t=+t),vi(gs(e).replace(ie,""),t||0)},Li.random=function(e,t,i){if(i&&"boolean"!=typeof i&&mr(e,t,i)&&(t=i=n),i===n&&("boolean"==typeof t?(i=t,t=n):"boolean"==typeof e&&(i=e,e=n)),e===n&&t===n?(e=0,t=1):(e=cs(e),t===n?(t=e,e=0):t=cs(t)),e>t){var o=e;e=t,t=o}if(i||e%1||t%1){var r=yi();return fi(e+r*(t-e+at("1e-"+((r+"").length-1))),t)}return Gn(e,t)},Li.reduce=function(e,t,i){var n=Ha(e)?_t:Gt,o=arguments.length<3;return n(e,rr(t,4),i,o,cn)},Li.reduceRight=function(e,t,i){var n=Ha(e)?Nt:Gt,o=arguments.length<3;return n(e,rr(t,4),i,o,dn)},Li.repeat=function(e,t,i){return t=(i?mr(e,t,i):t===n)?1:ds(t),jn(gs(e),t)},Li.replace=function(){var e=arguments,t=gs(e[0]);return e.length<3?t:t.replace(e[1],e[2])},Li.result=function(e,t,i){var o=-1,r=(t=mo(t,e)).length;for(r||(r=1,e=n);++o<r;){var a=null==e?n:e[Nr(t[o])];a===n&&(o=r,a=i),e=Wa(a)?a.call(e):a}return e},Li.round=Cl,Li.runInContext=e,Li.sample=function(e){return(Ha(e)?Wi:Wn)(e)},Li.size=function(e){if(null==e)return 0;if(Za(e))return ns(e)?si(e):e.length;var t=ur(e);return t==S||t==P?e.size:Nn(e).length},Li.snakeCase=Vs,Li.some=function(e,t,i){var o=Ha(e)?Rt:eo;return i&&mr(e,t,i)&&(t=n),o(e,rr(t,3))},Li.sortedIndex=function(e,t){return to(e,t)},Li.sortedIndexBy=function(e,t,i){return io(e,t,rr(i,2))},Li.sortedIndexOf=function(e,t){var i=null==e?0:e.length;if(i){var n=to(e,t);if(n<i&&La(e[n],t))return n}return-1},Li.sortedLastIndex=function(e,t){return to(e,t,!0)},Li.sortedLastIndexBy=function(e,t,i){return io(e,t,rr(i,2),!0)},Li.sortedLastIndexOf=function(e,t){if(null!=e&&e.length){var i=to(e,t,!0)-1;if(La(e[i],t))return i}return-1},Li.startCase=Gs,Li.startsWith=function(e,t,i){return e=gs(e),i=null==i?0:on(ds(i),0,e.length),t=ro(t),e.slice(i,i+t.length)==t},Li.subtract=bl,Li.sum=function(e){return e&&e.length?jt(e,Qs):0},Li.sumBy=function(e,t){return e&&e.length?jt(e,rr(t,2)):0},Li.template=function(e,t,i){var o=Li.templateSettings;i&&mr(e,t,i)&&(t=n),e=gs(e),t=vs({},t,o,qo);var r,a,s=vs({},t.imports,o.imports,qo),l=As(s),c=qt(s,l),d=0,u=t.interpolate||ye,h="__p += '",p=Oe((t.escape||ye).source+"|"+u.source+"|"+(u===Y?de:ye).source+"|"+(t.evaluate||ye).source+"|$","g"),g="//# sourceURL="+(Ne.call(t,"sourceURL")?(t.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++it+"]")+"\n";e.replace(p,(function(t,i,n,o,s,l){return n||(n=o),h+=e.slice(d,l).replace(Ce,ti),i&&(r=!0,h+="' +\n__e("+i+") +\n'"),s&&(a=!0,h+="';\n"+s+";\n__p += '"),n&&(h+="' +\n((__t = ("+n+")) == null ? '' : __t) +\n'"),d=l+t.length,t})),h+="';\n";var f=Ne.call(t,"variable")&&t.variable;if(f){if(le.test(f))throw new Se("Invalid `variable` option passed into `_.template`")}else h="with (obj) {\n"+h+"\n}\n";h=(a?h.replace($,""):h).replace(Z,"$1").replace(V,"$1;"),h="function("+(f||"obj")+") {\n"+(f?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(r?", __e = _.escape":"")+(a?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+h+"return __p\n}";var m=Ks((function(){return xe(l,g+"return "+h).apply(n,c)}));if(m.source=h,za(m))throw m;return m},Li.times=function(e,t){if((e=ds(e))<1||e>d)return[];var i=h,n=fi(e,h);t=rr(t),e-=h;for(var o=zt(n,t);++i<e;)t(i);return o},Li.toFinite=cs,Li.toInteger=ds,Li.toLength=us,Li.toLower=function(e){return gs(e).toLowerCase()},Li.toNumber=hs,Li.toSafeInteger=function(e){return e?on(ds(e),-9007199254740991,d):0===e?e:0},Li.toString=gs,Li.toUpper=function(e){return gs(e).toUpperCase()},Li.trim=function(e,t,i){if((e=gs(e))&&(i||t===n))return Wt(e);if(!e||!(t=ro(t)))return e;var o=li(e),r=li(t);return yo(o,Xt(o,r),Jt(o,r)+1).join("")},Li.trimEnd=function(e,t,i){if((e=gs(e))&&(i||t===n))return e.slice(0,ci(e)+1);if(!e||!(t=ro(t)))return e;var o=li(e);return yo(o,0,Jt(o,li(t))+1).join("")},Li.trimStart=function(e,t,i){if((e=gs(e))&&(i||t===n))return e.replace(ie,"");if(!e||!(t=ro(t)))return e;var o=li(e);return yo(o,Xt(o,li(t))).join("")},Li.truncate=function(e,t){var i=30,o="...";if(Ya(t)){var r="separator"in t?t.separator:r;i="length"in t?ds(t.length):i,o="omission"in t?ro(t.omission):o}var a=(e=gs(e)).length;if(ii(e)){var s=li(e);a=s.length}if(i>=a)return e;var l=i-si(o);if(l<1)return o;var c=s?yo(s,0,l).join(""):e.slice(0,l);if(r===n)return c+o;if(s&&(l+=c.length-l),ts(r)){if(e.slice(l).search(r)){var d,u=c;for(r.global||(r=Oe(r.source,gs(ue.exec(r))+"g")),r.lastIndex=0;d=r.exec(u);)var h=d.index;c=c.slice(0,h===n?l:h)}}else if(e.indexOf(ro(r),l)!=l){var p=c.lastIndexOf(r);p>-1&&(c=c.slice(0,p))}return c+o},Li.unescape=function(e){return(e=gs(e))&&z.test(e)?e.replace(G,di):e},Li.uniqueId=function(e){var t=++Re;return gs(e)+t},Li.upperCase=js,Li.upperFirst=zs,Li.each=ga,Li.eachRight=fa,Li.first=Zr,nl(Li,(pl={},vn(Li,(function(e,t){Ne.call(Li.prototype,t)||(pl[t]=e)})),pl),{chain:!1}),Li.VERSION="4.17.21",wt(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(e){Li[e].placeholder=Li})),wt(["drop","take"],(function(e,t){Hi.prototype[e]=function(i){i=i===n?1:gi(ds(i),0);var o=this.__filtered__&&!t?new Hi(this):this.clone();return o.__filtered__?o.__takeCount__=fi(i,o.__takeCount__):o.__views__.push({size:fi(i,h),type:e+(o.__dir__<0?"Right":"")}),o},Hi.prototype[e+"Right"]=function(t){return this.reverse()[e](t).reverse()}})),wt(["filter","map","takeWhile"],(function(e,t){var i=t+1,n=1==i||3==i;Hi.prototype[e]=function(e){var t=this.clone();return t.__iteratees__.push({iteratee:rr(e,3),type:i}),t.__filtered__=t.__filtered__||n,t}})),wt(["head","last"],(function(e,t){var i="take"+(t?"Right":"");Hi.prototype[e]=function(){return this[i](1).value()[0]}})),wt(["initial","tail"],(function(e,t){var i="drop"+(t?"":"Right");Hi.prototype[e]=function(){return this.__filtered__?new Hi(this):this[i](1)}})),Hi.prototype.compact=function(){return this.filter(Qs)},Hi.prototype.find=function(e){return this.filter(e).head()},Hi.prototype.findLast=function(e){return this.reverse().find(e)},Hi.prototype.invokeMap=zn((function(e,t){return"function"==typeof e?new Hi(this):this.map((function(i){return An(i,e,t)}))})),Hi.prototype.reject=function(e){return this.filter(Da(rr(e)))},Hi.prototype.slice=function(e,t){e=ds(e);var i=this;return i.__filtered__&&(e>0||t<0)?new Hi(i):(e<0?i=i.takeRight(-e):e&&(i=i.drop(e)),t!==n&&(i=(t=ds(t))<0?i.dropRight(-t):i.take(t-e)),i)},Hi.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},Hi.prototype.toArray=function(){return this.take(h)},vn(Hi.prototype,(function(e,t){var i=/^(?:filter|find|map|reject)|While$/.test(t),o=/^(?:head|last)$/.test(t),r=Li[o?"take"+("last"==t?"Right":""):t],a=o||/^find/.test(t);r&&(Li.prototype[t]=function(){var t=this.__wrapped__,s=o?[1]:arguments,l=t instanceof Hi,c=s[0],d=l||Ha(t),u=function(e){var t=r.apply(Li,Dt([e],s));return o&&h?t[0]:t};d&&i&&"function"==typeof c&&1!=c.length&&(l=d=!1);var h=this.__chain__,p=!!this.__actions__.length,g=a&&!h,f=l&&!p;if(!a&&d){t=f?t:new Hi(this);var m=e.apply(t,s);return m.__actions__.push({func:ca,args:[u],thisArg:n}),new Ui(m,h)}return g&&f?e.apply(this,s):(m=this.thru(u),g?o?m.value()[0]:m.value():m)})})),wt(["pop","push","shift","sort","splice","unshift"],(function(e){var t=Ee[e],i=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",n=/^(?:pop|shift)$/.test(e);Li.prototype[e]=function(){var e=arguments;if(n&&!this.__chain__){var o=this.value();return t.apply(Ha(o)?o:[],e)}return this[i]((function(i){return t.apply(Ha(i)?i:[],e)}))}})),vn(Hi.prototype,(function(e,t){var i=Li[t];if(i){var n=i.name+"";Ne.call(Ai,n)||(Ai[n]=[]),Ai[n].push({name:t,func:i})}})),Ai[Bo(n,2).name]=[{name:"wrapper",func:n}],Hi.prototype.clone=function(){var e=new Hi(this.__wrapped__);return e.__actions__=Po(this.__actions__),e.__dir__=this.__dir__,e.__filtered__=this.__filtered__,e.__iteratees__=Po(this.__iteratees__),e.__takeCount__=this.__takeCount__,e.__views__=Po(this.__views__),e},Hi.prototype.reverse=function(){if(this.__filtered__){var e=new Hi(this);e.__dir__=-1,e.__filtered__=!0}else(e=this.clone()).__dir__*=-1;return e},Hi.prototype.value=function(){var e=this.__wrapped__.value(),t=this.__dir__,i=Ha(e),n=t<0,o=i?e.length:0,r=function(e,t,i){for(var n=-1,o=i.length;++n<o;){var r=i[n],a=r.size;switch(r.type){case"drop":e+=a;break;case"dropRight":t-=a;break;case"take":t=fi(t,e+a);break;case"takeRight":e=gi(e,t-a)}}return{start:e,end:t}}(0,o,this.__views__),a=r.start,s=r.end,l=s-a,c=n?s:a-1,d=this.__iteratees__,u=d.length,h=0,p=fi(l,this.__takeCount__);if(!i||!n&&o==l&&p==l)return uo(e,this.__actions__);var g=[];e:for(;l--&&h<p;){for(var f=-1,m=e[c+=t];++f<u;){var v=d[f],y=v.iteratee,C=v.type,b=y(m);if(2==C)m=b;else if(!b){if(1==C)continue e;break e}}g[h++]=m}return g},Li.prototype.at=da,Li.prototype.chain=function(){return la(this)},Li.prototype.commit=function(){return new Ui(this.value(),this.__chain__)},Li.prototype.next=function(){this.__values__===n&&(this.__values__=ls(this.value()));var e=this.__index__>=this.__values__.length;return{done:e,value:e?n:this.__values__[this.__index__++]}},Li.prototype.plant=function(e){for(var t,i=this;i instanceof Fi;){var o=Mr(i);o.__index__=0,o.__values__=n,t?r.__wrapped__=o:t=o;var r=o;i=i.__wrapped__}return r.__wrapped__=e,t},Li.prototype.reverse=function(){var e=this.__wrapped__;if(e instanceof Hi){var t=e;return this.__actions__.length&&(t=new Hi(this)),(t=t.reverse()).__actions__.push({func:ca,args:[Yr],thisArg:n}),new Ui(t,this.__chain__)}return this.thru(Yr)},Li.prototype.toJSON=Li.prototype.valueOf=Li.prototype.value=function(){return uo(this.__wrapped__,this.__actions__)},Li.prototype.first=Li.prototype.head,Xe&&(Li.prototype[Xe]=function(){return this}),Li}();ht?((ht.exports=ui)._=ui,ut._=ui):dt._=ui}).call(this)}(oo,oo.exports);var ro,ao=oo.exports,so=Vn(ao),lo={exports:{}};ro=lo,function(){var e={}.hasOwnProperty;function t(){for(var i=[],n=0;n<arguments.length;n++){var o=arguments[n];if(o){var r=typeof o;if("string"===r||"number"===r)i.push(o);else if(Array.isArray(o)){if(o.length){var a=t.apply(null,o);a&&i.push(a)}}else if("object"===r){if(o.toString!==Object.prototype.toString&&!o.toString.toString().includes("[native code]")){i.push(o.toString());continue}for(var s in o)e.call(o,s)&&o[s]&&i.push(s)}}}return i.join(" ")}ro.exports?(t.default=t,ro.exports=t):window.classNames=t}();var co=Vn(lo.exports);function uo(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function ho(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?uo(Object(i),!0).forEach((function(t){Zn(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):uo(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var po="recharts-tooltip-wrapper";function go(e){return e.dataKey}var fo={active:!1,allowEscapeViewBox:{x:!1,y:!1},reverseDirection:{x:!1,y:!1},offset:10,viewBox:{x:0,y:0,height:0,width:0},coordinate:{x:0,y:0},cursorStyle:{},separator:" : ",wrapperStyle:{},contentStyle:{},itemStyle:{},labelStyle:{},cursor:!0,trigger:"hover",isAnimationActive:!on.Global.isSsr,animationEasing:"ease",animationDuration:400,filterNull:!0,useTranslate3d:!1,role:"note",firstPosition:"end",ariaProps:{"aria-label":"Tooltip"}},mo=function(e){var t=Un((0,r.useState)(-1),2),i=t[0],n=t[1],o=Un((0,r.useState)(-1),2),a=o[0],s=o[1],l=Un((0,r.useState)(!1),2),c=l[0],d=l[1],u=Un((0,r.useState)({x:0,y:0}),2),h=u[0],p=u[1],g=(0,r.useRef)(null),f=e.allowEscapeViewBox,m=e.reverseDirection,v=e.coordinate,y=e.offset,C=e.position,b=e.viewBox,S=e.firstPosition,x=(0,r.useCallback)((function(e){"Escape"===e.key&&(d(!0),p((function(e){return ho(ho({},e),{},{x:null==v?void 0:v.x,y:null==v?void 0:v.y})})))}),[null==v?void 0:v.x,null==v?void 0:v.y]);(0,r.useEffect)((function(){v.x="start"===S?0:b.width+b.left-i}),[b.width,b.left]),(0,r.useEffect)((function(){return function(){if(c?(document.removeEventListener("keydown",x),(null==v?void 0:v.x)===h.x&&(null==v?void 0:v.y)===h.y||d(!1)):document.addEventListener("keydown",x),g.current&&g.current.getBoundingClientRect){var e=g.current.getBoundingClientRect();(Math.abs(e.width-i)>1||Math.abs(e.height-a)>1)&&(n(e.width),s(e.height))}else-1===i&&-1===a||(n(-1),s(-1))}(),function(){document.removeEventListener("keydown",x)}}),[a,i,v,c,h.x,h.y,x]);var T,w,O=function(e){var t=e.key,i=e.tooltipDimension,n=e.viewBoxDimension;if(C&&(0,rn.isNumber)(C[t]))return C[t];var o=v[t]-i-y,r=v[t]+y;return(null==f?void 0:f[t])?m[t]?o:r:(null==m?void 0:m[t])?o<b[t]?Math.max(r,b[t]):Math.max(o,b[t]):r+i>b[t]+n?Math.max(o,b[t]):Math.max(r,b[t])},P=e.payload,A=e.payloadUniqBy,E=e.filterNull,k=e.active,I=e.wrapperStyle,D=e.useTranslate3d,_=e.isAnimationActive,N=e.animationDuration,R=e.animationEasing,M=e.tabIndex,L=e.role,B=e.ariaProps,F=function(e,t){return!0===e?so.uniqBy(t,go):so.isFunction(e)?so.uniqBy(t,e):t}(A,E&&P&&P.length?P.filter((function(e){return!so.isNil(e.value)})):P),U=F&&F.length,H=e.content,$=ho({visibility:!c&&k&&U?"visible":"hidden",position:"absolute",top:0,left:0},I);C&&(0,rn.isNumber)(C.x)&&(0,rn.isNumber)(C.y)?(T=C.x,w=C.y):i>0&&a>0&&v?(T=O({key:"x",tooltipDimension:i,viewBoxDimension:b.width}),w=O({key:"y",tooltipDimension:a,viewBoxDimension:b.height})):$.visibility="hidden",$=ho(ho({},no({transform:D?"translate3d(".concat(T,"px, ").concat(w,"px, 0)"):"translate(".concat(T,"px, ").concat(w,"px)")})),$),_&&k&&($=ho(ho({},no({transition:"transform ".concat(N,"ms ").concat(R)})),$));var Z=co(po,Zn(Zn(Zn(Zn({},"".concat(po,"-right"),(0,rn.isNumber)(T)&&v&&(0,rn.isNumber)(v.x)&&T>=v.x),"".concat(po,"-left"),(0,rn.isNumber)(T)&&v&&(0,rn.isNumber)(v.x)&&T<v.x),"".concat(po,"-bottom"),(0,rn.isNumber)(w)&&v&&(0,rn.isNumber)(v.y)&&w>=v.y),"".concat(po,"-top"),(0,rn.isNumber)(w)&&v&&(0,rn.isNumber)(v.y)&&w<v.y));return r.createElement("div",ho(ho({tabIndex:M,role:L},B),{},{className:Z,style:$,ref:g}),function(e,t){return r.isValidElement(e)?r.cloneElement(e,t):so.isFunction(e)?r.createElement(e,t):r.createElement(nn.DefaultTooltipContent,ho({},t))}(H,ho(ho({},e),{},{payload:F})))};function vo(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}function yo(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Co(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,$n(n.key),n)}}function bo(e,t,i){return t&&Co(e.prototype,t),i&&Co(e,i),Object.defineProperty(e,"prototype",{writable:!1}),e}function So(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function xo(e,t){return xo=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},xo(e,t)}function To(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&xo(e,t)}function wo(e,t){if(t&&("object"===Hn(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return So(e)}function Oo(e){return Oo=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Oo(e)}function Po(e){return function(e){if(Array.isArray(e))return Bn(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||Fn(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}mo.displayName="Tooltip",mo.defaultProps=fo;var Ao,Eo="object"==typeof i.g&&i.g&&i.g.Object===Object&&i.g,ko="object"==typeof self&&self&&self.Object===Object&&self,Io=Eo||ko||Function("return this")(),Do=Io.Symbol,_o=Do,No=Object.prototype,Ro=No.hasOwnProperty,Mo=No.toString,Lo=_o?_o.toStringTag:void 0,Bo=Object.prototype.toString,Fo=Do?Do.toStringTag:void 0,Uo=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":Fo&&Fo in Object(e)?function(e){var t=Ro.call(e,Lo),i=e[Lo];try{e[Lo]=void 0;var n=!0}catch(e){}var o=Mo.call(e);return n&&(t?e[Lo]=i:delete e[Lo]),o}(e):function(e){return Bo.call(e)}(e)},Ho=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)},$o=Uo,Zo=Ho,Vo=function(e){if(!Zo(e))return!1;var t=$o(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t},Go=Vn(Vo),jo=Array.isArray,zo=Uo,Wo=function(e){return"symbol"==typeof e||function(e){return null!=e&&"object"==typeof e}(e)&&"[object Symbol]"==zo(e)},Ko=jo,qo=Wo,Yo=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Xo=/^\w*$/,Jo=Io["__core-js_shared__"],Qo=(Ao=/[^.]+$/.exec(Jo&&Jo.keys&&Jo.keys.IE_PROTO||""))?"Symbol(src)_1."+Ao:"",er=Function.prototype.toString,tr=Vo,ir=Ho,nr=/^\[object .+?Constructor\]$/,or=Function.prototype,rr=Object.prototype,ar=or.toString,sr=rr.hasOwnProperty,lr=RegExp("^"+ar.call(sr).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),cr=function(e){return!(!ir(e)||function(e){return!!Qo&&Qo in e}(e))&&(tr(e)?lr:nr).test(function(e){if(null!=e){try{return er.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(e))},dr=function(e,t){var i=function(e,t){return null==e?void 0:e[t]}(e,t);return cr(i)?i:void 0},ur=dr(Object,"create"),hr=ur,pr=ur,gr=Object.prototype.hasOwnProperty,fr=ur,mr=Object.prototype.hasOwnProperty,vr=ur;function yr(e){var t=-1,i=null==e?0:e.length;for(this.clear();++t<i;){var n=e[t];this.set(n[0],n[1])}}yr.prototype.clear=function(){this.__data__=hr?hr(null):{},this.size=0},yr.prototype.delete=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},yr.prototype.get=function(e){var t=this.__data__;if(pr){var i=t[e];return"__lodash_hash_undefined__"===i?void 0:i}return gr.call(t,e)?t[e]:void 0},yr.prototype.has=function(e){var t=this.__data__;return fr?void 0!==t[e]:mr.call(t,e)},yr.prototype.set=function(e,t){var i=this.__data__;return this.size+=this.has(e)?0:1,i[e]=vr&&void 0===t?"__lodash_hash_undefined__":t,this};var Cr=yr,br=function(e,t){return e===t||e!=e&&t!=t},Sr=function(e,t){for(var i=e.length;i--;)if(br(e[i][0],t))return i;return-1},xr=Sr,Tr=Array.prototype.splice,wr=Sr,Or=Sr,Pr=Sr;function Ar(e){var t=-1,i=null==e?0:e.length;for(this.clear();++t<i;){var n=e[t];this.set(n[0],n[1])}}Ar.prototype.clear=function(){this.__data__=[],this.size=0},Ar.prototype.delete=function(e){var t=this.__data__,i=xr(t,e);return!(i<0||(i==t.length-1?t.pop():Tr.call(t,i,1),--this.size,0))},Ar.prototype.get=function(e){var t=this.__data__,i=wr(t,e);return i<0?void 0:t[i][1]},Ar.prototype.has=function(e){return Or(this.__data__,e)>-1},Ar.prototype.set=function(e,t){var i=this.__data__,n=Pr(i,e);return n<0?(++this.size,i.push([e,t])):i[n][1]=t,this};var Er=Ar,kr=dr(Io,"Map"),Ir=Cr,Dr=Er,_r=kr,Nr=function(e,t){var i=e.__data__;return function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}(t)?i["string"==typeof t?"string":"hash"]:i.map},Rr=Nr,Mr=Nr,Lr=Nr,Br=Nr;function Fr(e){var t=-1,i=null==e?0:e.length;for(this.clear();++t<i;){var n=e[t];this.set(n[0],n[1])}}Fr.prototype.clear=function(){this.size=0,this.__data__={hash:new Ir,map:new(_r||Dr),string:new Ir}},Fr.prototype.delete=function(e){var t=Rr(this,e).delete(e);return this.size-=t?1:0,t},Fr.prototype.get=function(e){return Mr(this,e).get(e)},Fr.prototype.has=function(e){return Lr(this,e).has(e)},Fr.prototype.set=function(e,t){var i=Br(this,e),n=i.size;return i.set(e,t),this.size+=i.size==n?0:1,this};var Ur=Fr;function Hr(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new TypeError("Expected a function");var i=function(){var n=arguments,o=t?t.apply(this,n):n[0],r=i.cache;if(r.has(o))return r.get(o);var a=e.apply(this,n);return i.cache=r.set(o,a)||r,a};return i.cache=new(Hr.Cache||Ur),i}Hr.Cache=Ur;var $r,Zr,Vr=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Gr=/\\(\\)?/g,jr=($r=Hr((function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(Vr,(function(e,i,n,o){t.push(n?o.replace(Gr,"$1"):i||e)})),t}),(function(e){return 500===Zr.size&&Zr.clear(),e})),Zr=$r.cache,$r),zr=jo,Wr=Wo,Kr=Do?Do.prototype:void 0,qr=Kr?Kr.toString:void 0,Yr=function e(t){if("string"==typeof t)return t;if(zr(t))return function(e,t){for(var i=-1,n=null==e?0:e.length,o=Array(n);++i<n;)o[i]=t(e[i],i,e);return o}(t,e)+"";if(Wr(t))return qr?qr.call(t):"";var i=t+"";return"0"==i&&1/t==-1/0?"-0":i},Xr=jo,Jr=jr,Qr=Wo,ea=function(e,t){return Xr(e)?e:function(e,t){if(Ko(e))return!1;var i=typeof e;return!("number"!=i&&"symbol"!=i&&"boolean"!=i&&null!=e&&!qo(e))||Xo.test(e)||!Yo.test(e)||null!=t&&e in Object(t)}(e,t)?[e]:Jr(function(e){return null==e?"":Yr(e)}(e))},ta=function(e){if("string"==typeof e||Qr(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t},ia=Vn((function(e,t,i){var n=null==e?void 0:function(e,t){for(var i=0,n=(t=ea(t,e)).length;null!=e&&i<n;)e=e[ta(t[i++])];return i&&i==n?e:void 0}(e,t);return void 0===n?i:n}));function na(e){var t,i,n="";if("string"==typeof e||"number"==typeof e)n+=e;else if("object"==typeof e)if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(i=na(e[t]))&&(n&&(n+=" "),n+=i);else for(t in e)e[t]&&(n&&(n+=" "),n+=t);return n}function oa(){for(var e,t,i=0,n="";i<arguments.length;)(e=arguments[i++])&&(t=na(e))&&(n&&(n+=" "),n+=t);return n}function ra(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function aa(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?ra(Object(i),!0).forEach((function(t){Zn(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):ra(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var sa=["viewBox"],la=["viewBox"],ca=["ticks"];function da(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function ua(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?da(Object(i),!0).forEach((function(t){Zn(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):da(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var ha=function(e){To(i,r.Component);var t=function(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var i,n=Oo(e);if(t){var o=Oo(this).constructor;i=Reflect.construct(n,arguments,o)}else i=n.apply(this,arguments);return wo(this,i)}}(i);function i(e){var n;return yo(this,i),(n=t.call(this,e)).state={fontSize:"",letterSpacing:""},n}return bo(i,[{key:"shouldComponentUpdate",value:function(e,t){var i=e.viewBox,n=vo(e,sa),o=this.props,r=o.viewBox,a=vo(o,la);return!(0,vn.shallowEqual)(i,r)||!(0,vn.shallowEqual)(n,a)||!(0,vn.shallowEqual)(t,this.state)}},{key:"componentDidMount",value:function(){var e=this.layerReference;if(e){var t=e.getElementsByClassName("recharts-cartesian-axis-tick-value")[0];t&&this.setState({fontSize:window.getComputedStyle(t).fontSize,letterSpacing:window.getComputedStyle(t).letterSpacing})}}},{key:"getTickLineCoord",value:function(e){var t,i,n,o,r,a,s=this.props,l=s.x,c=s.y,d=s.width,u=s.height,h=s.orientation,p=s.tickSize,g=s.mirror,f=s.tickMargin,m=g?-1:1,v=e.tickSize||p,y=(0,rn.isNumber)(e.tickCoord)?e.tickCoord:e.coordinate;switch(h){case"top":t=i=e.coordinate,a=(n=(o=c+ +!g*u)-m*v)-m*f,r=y;break;case"left":n=o=e.coordinate,r=(t=(i=l+ +!g*d)-m*v)-m*f,a=y;break;case"right":n=o=e.coordinate,r=(t=(i=l+ +g*d)+m*v)+m*f,a=y;break;default:t=i=e.coordinate,a=(n=(o=c+ +g*u)+m*v)+m*f,r=y}return{line:{x1:t,y1:n,x2:i,y2:o},tick:{x:r,y:a}}}},{key:"getTickTextAnchor",value:function(){var e,t=this.props,i=t.orientation,n=t.mirror;switch(i){case"left":e=n?"start":"end";break;case"right":e=n?"end":"start";break;default:e="middle"}return e}},{key:"getTickVerticalAnchor",value:function(){var e=this.props,t=e.orientation,i=e.mirror,n="end";switch(t){case"left":case"right":n="middle";break;case"top":n=i?"start":"end";break;default:n=i?"end":"start"}return n}},{key:"renderAxisLine",value:function(){var e=this.props,t=e.x,i=e.y,n=e.width,o=e.height,a=e.orientation,s=e.mirror,l=e.axisLine,c=ua(ua(ua({},(0,mn.filterProps)(this.props)),(0,mn.filterProps)(l)),{},{fill:"none"});if("top"===a||"bottom"===a){var d=+("top"===a&&!s||"bottom"===a&&s);c=ua(ua({},c),{},{x1:t,y1:i+d*o,x2:t+n,y2:i+d*o})}else{var u=+("left"===a&&!s||"right"===a&&s);c=ua(ua({},c),{},{x1:t+u*n,y1:i,x2:t+u*n,y2:i+o})}return r.createElement("line",ua(ua({},c),{},{className:oa("recharts-cartesian-axis-line",ia(l,"className"))}))}},{key:"renderTicks",value:function(e,t,n){var o=this,a=this.props,s=a.tickLine,l=a.stroke,c=a.tick,d=a.tickFormatter,u=a.unit,h=function(e,t,i){var n=e.tick,o=e.ticks,r=e.viewBox,a=e.minTickGap,s=e.orientation,l=e.interval,c=e.unit,d=e.angle;if(!o||!o.length||!n)return[];if((0,rn.isNumber)(l)||on.Global.isSsr)return(0,xn.getNumberIntervalTicks)(o,"number"==typeof l&&(0,rn.isNumber)(l)?l:0);var u=[],h="top"===s||"bottom"===s?"width":"height",p=c&&"width"===h?(0,Sn.getStringSize)(c,{fontSize:t,letterSpacing:i}):{width:0,height:0},g=function(e,n){var o=e.value;return"width"===h?(0,xn.getAngledTickWidth)((0,Sn.getStringSize)(o,{fontSize:t,letterSpacing:i}),p,d):(0,Sn.getStringSize)(o,{fontSize:t,letterSpacing:i})[h]},f=o.length>=2?(0,rn.mathSign)(o[1].coordinate-o[0].coordinate):1,m=(0,xn.getTickBoundaries)(r,f,h);if("equidistantPreserveStart"===l)return function(e,t,i,n,o){for(var r=(n||[]).slice(),a=t.start,s=t.end,l=0,c=1,d=a;c<=r.length;){var u=null==n?void 0:n[l];if(void 0===u)return(0,Tn.getEveryNthWithCondition)(n,c);var h=i(u,l),p=u.coordinate,g=0===l||(0,xn.isVisible)(e,p,h,d,s);g||(l=0,d=a,c+=1),g&&(d=p+e*(h/2+o),l+=c)}return[]}(f,m,g,o,a);u="preserveStart"===l||"preserveStartEnd"===l?function(e,t,i,n,o,r){var a=(n||[]).slice(),s=a.length,l=t.start,c=t.end;if(r){var d=n[s-1],u=i(d,s-1),h=e*(d.coordinate+e*u/2-c);a[s-1]=d=aa(aa({},d),{},{tickCoord:h>0?d.coordinate-h*e:d.coordinate}),(0,xn.isVisible)(e,d.tickCoord,u,l,c)&&(c=d.tickCoord-e*(u/2+o),a[s-1]=aa(aa({},d),{},{isShow:!0}))}for(var p=r?s-1:s,g=0;g<p;g++){var f=a[g],m=i(f,g);if(0===g){var v=e*(f.coordinate-e*m/2-l);a[g]=f=aa(aa({},f),{},{tickCoord:v<0?f.coordinate-v*e:f.coordinate})}else a[g]=f=aa(aa({},f),{},{tickCoord:f.coordinate});(0,xn.isVisible)(e,f.tickCoord,m,l,c)&&(l=f.tickCoord+e*(m/2+o),a[g]=aa(aa({},f),{},{isShow:!0}))}return a}(f,m,g,o,a,"preserveStartEnd"===l):function(e,t,i,n,o){for(var r=(n||[]).slice(),a=r.length,s=t.start,l=t.end,c=a-1;c>=0;c--){var d=r[c],u=i(d,c);if(c===a-1){var h=e*(d.coordinate+e*u/2-l);r[c]=d=aa(aa({},d),{},{tickCoord:h>0?d.coordinate-h*e:d.coordinate})}else r[c]=d=aa(aa({},d),{},{tickCoord:d.coordinate});(0,xn.isVisible)(e,d.tickCoord,u,s,l)&&(l=d.tickCoord-e*(u/2+o),r[c]=aa(aa({},d),{},{isShow:!0}))}return r}(f,m,g,o,a);var v=new Set;return u.filter((function(e){return e.isShow})).filter((function(e){if(isNaN(Date.parse(e.value)))return!0;var t=new Date(e.value),i="".concat(t.getFullYear(),"-").concat(t.getMonth()+1);return!(void 0!==t&&v.has(i)||(v.add(i),0))}))}(ua(ua({},this.props),{},{ticks:e}),t,n),p=this.getTickTextAnchor(),g=this.getTickVerticalAnchor(),f=(0,mn.filterProps)(this.props),m=(0,mn.filterProps)(c),v=ua(ua({},f),{},{fill:"none"},(0,mn.filterProps)(s)),y=h.map((function(e,t){var n=o.getTickLineCoord(e),a=n.line,y=n.tick,C=ua(ua(ua(ua({textAnchor:p,verticalAnchor:g},f),{},{stroke:"none",fill:l},m),y),{},{index:t,payload:e,visibleTicksCount:h.length,tickFormatter:d}),b="date"===o.props.dataKey;return r.createElement(ln.Layer,ua({className:"recharts-cartesian-axis-tick",key:"tick-".concat(t)},(0,bn.adaptEventsOfChild)(o.props,e,t)),s&&r.createElement("line",ua(ua(ua({},v),a),{},{className:oa("recharts-cartesian-axis-tick-line",ia(s,"className"))})),c&&i.renderTickItem(c,C,b,"".concat(Go(d)?d(e.value,t):e.value).concat(u||"")))}));return r.createElement("g",{className:"recharts-cartesian-axis-ticks"},y)}},{key:"render",value:function(){var e=this,t=this.props,i=t.axisLine,n=t.width,o=t.height,a=t.ticksGenerator,s=t.className;if(t.hide)return null;var l=this.props,c=l.ticks,d=vo(l,ca),u=c;return Go(a)&&(u=c&&c.length>0?a(this.props):a(d)),n<=0||o<=0||!u||!u.length?null:r.createElement(ln.Layer,{className:oa("recharts-cartesian-axis",s),ref:function(t){e.layerReference=t}},i&&this.renderAxisLine(),this.renderTicks(u,this.state.fontSize,this.state.letterSpacing),Cn.Label.renderCallByParent(this.props))}}],[{key:"renderTickItem",value:function(e,t){var i=arguments.length>2&&void 0!==arguments[2]&&arguments[2],n=arguments.length>3?arguments[3]:void 0;return r.isValidElement(e)?r.cloneElement(e,t):Go(e)?e(t):r.createElement(yn.Text,ua(ua({},t),{},{textAnchor:i?0===t.index?"start":t.index===t.visibleTicksCounts-1?"end":"middle":t.textAnchor,className:"recharts-cartesian-axis-tick-value"}),n)}}]),i}();ha.displayName="CartesianAxis",ha.defaultProps={x:0,y:0,width:0,height:0,viewBox:{x:0,y:0,width:0,height:0},orientation:"bottom",ticks:[],stroke:"#666",tickLine:!0,axisLine:!0,tick:!0,mirror:!1,minTickGap:5,tickSize:6,tickMargin:2,interval:"preserveEnd"};var pa=function(){function e(){yo(this,e),this.activeIndex=0,this.isFirstRender=!0,this.defaultActiveIndex=0,this.coordinateList=[],this.layout="horizontal"}return bo(e,[{key:"setDetails",value:function(e){var t=e.defaultActiveIndex,i=e.coordinateList,n=void 0===i?[]:i,o=e.container,r=void 0===o?void 0:o,a=e.layout,s=void 0===a?null:a,l=e.offset,c=void 0===l?void 0:l,d=e.mouseHandlerCallback,u=void 0===d?void 0:d;this.coordinateList=null!=n?n:this.coordinateList,this.container=null!=r?r:this.container,this.layout=null!=s?s:this.layout,this.offset=null!=c?c:this.offset,this.defaultActiveIndex=null!=t?t:this.defaultActiveIndex,this.mouseHandlerCallback=null!=u?u:this.mouseHandlerCallback,this.activeIndex=this.isFirstRender?this.defaultActiveIndex:this.activeIndex,this.activeIndex=Math.min(Math.max(this.activeIndex,0),this.coordinateList.length-1),this.isFirstRender=!1}},{key:"focus",value:function(){this.spoofMouse()}},{key:"keyboardEvent",value:function(e){if(0!==this.coordinateList.length)switch(e.key){case"ArrowRight":if("horizontal"!==this.layout)return;this.activeIndex=Math.min(this.activeIndex+1,this.coordinateList.length-1),this.spoofMouse();break;case"ArrowLeft":if("horizontal"!==this.layout)return;this.activeIndex=Math.max(this.activeIndex-1,0),this.spoofMouse()}}},{key:"spoofMouse",value:function(){if("horizontal"===this.layout&&0!==this.coordinateList.length){var e=this.container.getBoundingClientRect(),t=e.x,i=e.y,n=t+this.coordinateList[this.activeIndex].coordinate,o=i+this.offset.top;void 0!==this.mouseHandlerCallback&&this.mouseHandlerCallback({pageX:n,pageY:o})}}}]),e}(),ga=["item"],fa=["children","className","width","height","style","compact","title","desc"];function ma(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function va(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?ma(Object(i),!0).forEach((function(t){Zn(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):ma(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var ya={xAxis:["bottom","top"],yAxis:["left","right"]},Ca={x:0,y:0},ba=Number.isFinite?Number.isFinite:isFinite,Sa="function"==typeof requestAnimationFrame?requestAnimationFrame:"function"==typeof setImmediate?setImmediate:setTimeout,xa="function"==typeof cancelAnimationFrame?cancelAnimationFrame:"function"==typeof clearImmediate?clearImmediate:clearTimeout,Ta=function(e,t,i){var n=t.graphicalItems,o=t.dataStartIndex,r=t.dataEndIndex,a=(n||[]).reduce((function(e,t){var i=t.props.data;return i&&i.length?[].concat(Po(e),Po(i)):e}),[]);return a&&a.length>0?a:i&&i.props&&i.props.data&&i.props.data.length>0?i.props.data:e&&e.length&&(0,rn.isNumber)(o)&&(0,rn.isNumber)(r)?e.slice(o,r+1):[]};function wa(e){return"number"===e?[0,"auto"]:void 0}var Oa=function(e,t,i,n){var o=e.graphicalItems,r=e.tooltipAxis,a=Ta(t,e);return i<0||!o||!o.length||i>=a.length?null:o.reduce((function(e,t){if(t.props.hide)return e;var o,s=t.props.data;return(o=r.dataKey&&!r.allowDuplicatedCategory?(0,rn.findEntryInArray)(void 0===s?a:s,r.dataKey,n):s&&s[i]||a[i])?[].concat(Po(e),[(0,On.getTooltipItem)(t,o)]):e}),[])},Pa=function(e,t,i,n){var o=n||{x:e.chartX,y:e.chartY},r=function(e,t){return"horizontal"===t?e.x:"vertical"===t?e.y:"centric"===t?e.angle:e.radius}(o,i),a=e.orderedTooltipTicks,s=e.tooltipAxis,l=e.tooltipTicks,c=(0,On.calculateActiveTickIndex)(r,a,l,s);if(c>=0&&l){var d=l[c]&&l[c].value,u=Oa(e,t,c,d),h=function(e,t,i,n){var o=t.find((function(e){return e&&e.index===i}));if(o){if("horizontal"===e)return{x:o.coordinate,y:n.y};if("vertical"===e)return{x:n.x,y:o.coordinate};if("centric"===e){var r=o.coordinate,a=n.radius;return va(va(va({},n),(0,An.polarToCartesian)(n.cx,n.cy,a,r)),{},{angle:r,radius:a})}var s=o.coordinate,l=n.angle;return va(va(va({},n),(0,An.polarToCartesian)(n.cx,n.cy,s,l)),{},{angle:l,radius:s})}return Ca}(i,a,c,o);return{activeTooltipIndex:c,activeLabel:d,activePayload:u,activeCoordinate:h}}return null},Aa=function(e){var t,i,n=e.children,o=e.defaultShowTooltip,r=(0,mn.findChildByType)(n,wn.B);return{chartX:0,chartY:0,dataStartIndex:r&&r.props&&r.props.startIndex||0,dataEndIndex:void 0!==(null===(t=null==r?void 0:r.props)||void 0===t?void 0:t.endIndex)?null===(i=null==r?void 0:r.props)||void 0===i?void 0:i.endIndex:e.data&&e.data.length-1||0,activeTooltipIndex:-1,isTooltipActive:!so.isNil(o)&&o}},Ea=function(e){return"horizontal"===e?{numericAxisName:"yAxis",cateAxisName:"xAxis"}:"vertical"===e?{numericAxisName:"xAxis",cateAxisName:"yAxis"}:"centric"===e?{numericAxisName:"radiusAxis",cateAxisName:"angleAxis"}:{numericAxisName:"angleAxis",cateAxisName:"radiusAxis"}},ka=function(e){var t,i=e.chartName,n=e.GraphicalChild,o=e.defaultTooltipEventType,a=void 0===o?"axis":o,s=e.validateTooltipEventTypes,l=void 0===s?["axis"]:s,c=e.axisComponents,d=e.legendContent,u=e.formatAxisMap,h=e.defaultProps,p=function(e,t){var o=e.props,r=e.dataStartIndex,a=e.dataEndIndex,s=e.updateId;if(!(0,mn.validateWidthHeight)({props:o}))return null;var l=o.children,d=o.layout,h=o.stackOffset,p=o.data,g=o.reverseStackOrder,f=Ea(d),m=f.numericAxisName,v=f.cateAxisName,y=(0,mn.findAllByType)(l,n),C=(0,On.getStackGroupsByAxisId)(p,y,"".concat(m,"Id"),"".concat(v,"Id"),h,g),b=c.reduce((function(e,t){var i="".concat(t.axisType,"Map");return va(va({},e),{},Zn({},i,function(e,t){var i=t.axisType,n=void 0===i?"xAxis":i,o=t.AxisComp,r=t.graphicalItems,a=t.stackGroups,s=t.dataStartIndex,l=t.dataEndIndex,c=e.children,d="".concat(n,"Id"),u=(0,mn.findAllByType)(c,o),h={};return u&&u.length?h=function(e,t){var i=t.axes,n=t.graphicalItems,o=t.axisType,r=t.axisIdKey,a=t.stackGroups,s=t.dataStartIndex,l=t.dataEndIndex,c=e.layout,d=e.children,u=e.stackOffset,h=(0,On.isCategoricalAxis)(c,o);return i.reduce((function(t,i){var p,g,f=i.props,m=f.type,v=f.dataKey,y=f.allowDataOverflow,C=f.allowDuplicatedCategory,b=f.scale,S=f.ticks,x=f.includeHidden,T=i.props[r];if(t[T])return t;var w,O,P,A=Ta(e.data,{graphicalItems:n.filter((function(e){return e.props[r]===T})),dataStartIndex:s,dataEndIndex:l}),E=A.length;(function(e,t,i){if("number"===i&&!0===t&&Array.isArray(e)){var n=null==e?void 0:e[0],o=null==e?void 0:e[1];if(n&&o&&(0,rn.isNumber)(n)&&(0,rn.isNumber)(o))return!0}return!1})(i.props.domain,y,m)&&(w=(0,On.parseSpecifiedDomain)(i.props.domain,null,y),!h||"number"!==m&&"auto"===b||(P=(0,On.getDomainOfDataByKey)(A,v,"category")));var k=wa(m);if(!w||0===w.length){var I=null!==(p=i.props.domain)&&void 0!==p?p:k;if(v){if(w=(0,On.getDomainOfDataByKey)(A,v,m),"category"===m&&h){var D=(0,rn.hasDuplicate)(w);C&&D?(O=w,w=so.range(0,E)):C||(w=(0,On.parseDomainOfCategoryAxis)(I,w,i).reduce((function(e,t){return e.indexOf(t)>=0?e:[].concat(Po(e),[t])}),[]))}else if("category"===m)w=C?w.filter((function(e){return""!==e&&!so.isNil(e)})):(0,On.parseDomainOfCategoryAxis)(I,w,i).reduce((function(e,t){return e.indexOf(t)>=0||""===t||so.isNil(t)?e:[].concat(Po(e),[t])}),[]);else if("number"===m){var _=(0,On.parseErrorBarsOfAxis)(A,n.filter((function(e){return e.props[r]===T&&(x||!e.props.hide)})),v,o,c);_&&(w=_)}!h||"number"!==m&&"auto"===b||(P=(0,On.getDomainOfDataByKey)(A,v,"category"))}else w=h?so.range(0,E):a&&a[T]&&a[T].hasStack&&"number"===m?"expand"===u?[0,1]:(0,On.getDomainOfStackGroups)(a[T].stackGroups,s,l):(0,On.getDomainOfItemsWithSameAxis)(A,n.filter((function(e){return e.props[r]===T&&(x||!e.props.hide)})),m,c,!0);if("number"===m)w=(0,Pn._)(d,w,T,o,S),I&&(w=(0,On.parseSpecifiedDomain)(I,w,y));else if("category"===m&&I){var N=I;w.every((function(e){return N.indexOf(e)>=0}))&&(w=N)}}return va(va({},t),{},Zn({},T,va(va({},i.props),{},{axisType:o,domain:w,categoricalDomain:P,duplicateDomain:O,originalDomain:null!==(g=i.props.domain)&&void 0!==g?g:k,isCategorical:h,layout:c})))}),{})}(e,{axes:u,graphicalItems:r,axisType:n,axisIdKey:d,stackGroups:a,dataStartIndex:s,dataEndIndex:l}):r&&r.length&&(h=function(e,t){var i=t.graphicalItems,n=t.Axis,o=t.axisType,r=t.axisIdKey,a=t.stackGroups,s=t.dataStartIndex,l=t.dataEndIndex,c=e.layout,d=e.children,u=Ta(e.data,{graphicalItems:i,dataStartIndex:s,dataEndIndex:l}),h=u.length,p=(0,On.isCategoricalAxis)(c,o),g=-1;return i.reduce((function(e,t){var f,m=t.props[r],v=wa("number");return e[m]?e:(g++,p?f=so.range(0,h):a&&a[m]&&a[m].hasStack?(f=(0,On.getDomainOfStackGroups)(a[m].stackGroups,s,l),f=(0,Pn._)(d,f,m,o)):(f=(0,On.parseSpecifiedDomain)(v,(0,On.getDomainOfItemsWithSameAxis)(u,i.filter((function(e){return e.props[r]===m&&!e.props.hide})),"number",c),n.defaultProps.allowDataOverflow),f=(0,Pn._)(d,f,m,o)),va(va({},e),{},Zn({},m,va(va({axisType:o},n.defaultProps),{},{hide:!0,orientation:so.get(ya,"".concat(o,".").concat(g%2),null),domain:f,originalDomain:v,isCategorical:p,layout:c}))))}),{})}(e,{Axis:o,graphicalItems:r,axisType:n,axisIdKey:d,stackGroups:a,dataStartIndex:s,dataEndIndex:l})),h}(o,va(va({},t),{},{graphicalItems:y,stackGroups:t.axisType===m&&C,dataStartIndex:r,dataEndIndex:a}))))}),{}),S=function(e,t){var i=e.props,n=e.graphicalItems,o=e.xAxisMap,r=void 0===o?{}:o,a=e.yAxisMap,s=void 0===a?{}:a,l=i.width,c=i.height,d=i.children,u=i.margin||{},h=(0,mn.findChildByType)(d,wn.B),p=(0,mn.findChildByType)(d,dn.Legend),g=Object.keys(s).reduce((function(e,t){var i=s[t],n=i.orientation;return i.mirror||i.hide?e:va(va({},e),{},Zn({},n,e[n]+i.width))}),{left:u.left||0,right:u.right||0}),f=Object.keys(r).reduce((function(e,t){var i=r[t],n=i.orientation;return i.mirror||i.hide?e:va(va({},e),{},Zn({},n,so.get(e,"".concat(n))+i.height))}),{top:u.top||0,bottom:u.bottom||0}),m=va(va({},f),g),v=m.bottom;return h&&(m.bottom+=h.props.height||wn.B.defaultProps.height),p&&t&&(m=(0,On.appendOffsetOfLegend)(m,n,i,t)),va(va({brushBottom:v},m),{},{width:l-m.left-m.right,height:c-m.top-m.bottom})}(va(va({},b),{},{props:o,graphicalItems:y}),null==t?void 0:t.legendBBox);Object.keys(b).forEach((function(e){b[e]=u(o,b[e],S,e.replace("Map",""),i)}));var x,T,w=b["".concat(v,"Map")],O=(x=(0,rn.getAnyElementOfObject)(w),{tooltipTicks:T=(0,On.getTicksOfAxis)(x,!1,!0),orderedTooltipTicks:so.sortBy(T,(function(e){return e.coordinate})),tooltipAxis:x,tooltipAxisBandSize:(0,On.getBandSizeOfAxis)(x,T)}),P=function(e,t){var i=t.graphicalItems,n=t.stackGroups,o=t.offset,r=t.updateId,a=t.dataStartIndex,s=t.dataEndIndex,l=e.barSize,d=e.layout,u=e.barGap,h=e.barCategoryGap,p=e.maxBarSize,g=Ea(d),f=g.numericAxisName,m=g.cateAxisName,v=function(e){return!(!e||!e.length)&&e.some((function(e){var t=(0,mn.getDisplayName)(e&&e.type);return t&&t.indexOf("Bar")>=0}))}(i),y=v&&(0,On.getBarSizeList)({barSize:l,stackGroups:n}),C=[];return i.forEach((function(i,l){var g,v,b=Ta(e.data,{dataStartIndex:a,dataEndIndex:s},i),S=i.props,x=S.dataKey,T=S.maxBarSize,w=i.props["".concat(f,"Id")],O=i.props["".concat(m,"Id")],P=c.reduce((function(e,n){var o=t["".concat(n.axisType,"Map")],r=i.props["".concat(n.axisType,"Id")],a=o&&o[r];return va(va({},e),{},Zn(Zn({},n.axisType,a),"".concat(n.axisType,"Ticks"),(0,On.getTicksOfAxis)(a)))}),{}),A=P[m],E=P["".concat(m,"Ticks")],k=n&&n[w]&&n[w].hasStack&&(0,On.getStackedDataOfItem)(i,n[w].stackGroups),I=(0,mn.getDisplayName)(i.type).indexOf("Bar")>=0,D=(0,On.getBandSizeOfAxis)(A,E),_=[];if(I){var N=so.isNil(T)?p:T,R=null!==(v=null!==(g=(0,On.getBandSizeOfAxis)(A,E,!0))&&void 0!==g?g:N)&&void 0!==v?v:0;_=(0,On.getBarPosition)({barGap:u,barCategoryGap:h,bandSize:R!==D?R:D,sizeList:y[O],maxBarSize:N}),R!==D&&(_=_.map((function(e){return va(va({},e),{},{position:va(va({},e.position),{},{offset:e.position.offset-R/2})})})))}var M=i&&i.type&&i.type.getComposedData;M&&C.push({props:va(va({},M(va(va({},P),{},{displayedData:b,props:e,dataKey:x,item:i,bandSize:D,barPosition:_,offset:o,stackedData:k,layout:d,dataStartIndex:a,dataEndIndex:s}))),{},Zn(Zn(Zn({key:i.key||"item-".concat(l)},f,P[f]),m,P[m]),"animationId",r)),childIndex:(0,mn.parseChildIndex)(i,e.children),item:i})})),C}(o,va(va({},b),{},{dataStartIndex:r,dataEndIndex:a,updateId:s,graphicalItems:y,stackGroups:C,offset:S}));return va(va({formattedGraphicalItems:P,graphicalItems:y,offset:S,stackGroups:C},O),b)};return(t=function(e){To(n,r.Component);var t=function(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var i,n=Oo(e);if(t){var o=Oo(this).constructor;i=Reflect.construct(n,arguments,o)}else i=n.apply(this,arguments);return wo(this,i)}}(n);function n(e){var o;return yo(this,n),(o=t.call(this,e)).accessibilityManager=new pa,o.clearDeferId=function(){!ao.isNil(o.deferId)&&xa&&xa(o.deferId),o.deferId=null},o.handleLegendBBoxUpdate=function(e){if(e){var t=o.state,i=t.dataStartIndex,n=t.dataEndIndex,r=t.updateId;o.setState(va({legendBBox:e},p({props:o.props,dataStartIndex:i,dataEndIndex:n,updateId:r},va(va({},o.state),{},{legendBBox:e}))))}},o.handleReceiveSyncEvent=function(e,t,i){o.props.syncId===e&&t!==o.uniqueChartId&&(o.clearDeferId(),o.deferId=Sa&&Sa(o.applySyncEvent.bind(So(o),i)))},o.handleBrushChange=function(e){var t=e.startIndex,i=e.endIndex;if(t!==o.state.dataStartIndex||i!==o.state.dataEndIndex){var n=o.state.updateId;o.setState((function(){return va({dataStartIndex:t,dataEndIndex:i},p({props:o.props,dataStartIndex:t,dataEndIndex:i,updateId:n},o.state))})),o.triggerSyncEvent({dataStartIndex:t,dataEndIndex:i})}},o.handleMouseEnter=function(e){var t=o.props.onMouseEnter,i=o.getMouseInfo(e);if(i){var n=va(va({},i),{},{isTooltipActive:!0});o.setState(n),o.triggerSyncEvent(n),so.isFunction(t)&&t(n,e)}},o.triggeredAfterMouseMove=function(e){var t=o.props.onMouseMove,i=o.getMouseInfo(e),n=i?va(va({},i),{},{isTooltipActive:!0}):{isTooltipActive:!1};o.setState(n),o.triggerSyncEvent(n),so.isFunction(t)&&t(n,e)},o.handleItemMouseEnter=function(e){o.setState((function(){return{isTooltipActive:!0,activeItem:e,activePayload:e.tooltipPayload,activeCoordinate:e.tooltipPosition||{x:e.cx,y:e.cy}}}))},o.handleItemMouseLeave=function(){o.setState((function(){return{isTooltipActive:!1}}))},o.handleMouseMove=function(e){e&&so.isFunction(e.persist)&&e.persist(),o.triggeredAfterMouseMove(e)},o.handleMouseLeave=function(e){var t=o.props.onMouseLeave,i={isTooltipActive:!1};o.setState(i),o.triggerSyncEvent(i),so.isFunction(t)&&t(i,e),o.cancelThrottledTriggerAfterMouseMove()},o.handleOuterEvent=function(e){var t=(0,mn.getReactEventByType)(e),i=so.get(o.props,"".concat(t));t&&so.isFunction(i)&&i(/.*touch.*/i.test(t)?o.getMouseInfo(e.changedTouches[0]):o.getMouseInfo(e),e)},o.handleClick=function(e){var t=o.props.onClick,i=o.getMouseInfo(e);if(i){var n=va(va({},i),{},{isTooltipActive:!0});o.setState(n),o.triggerSyncEvent(n),so.isFunction(t)&&t(n,e)}},o.handleMouseDown=function(e){var t=o.props.onMouseDown;so.isFunction(t)&&t(o.getMouseInfo(e),e)},o.handleMouseUp=function(e){var t=o.props.onMouseUp;so.isFunction(t)&&t(o.getMouseInfo(e),e)},o.handleTouchMove=function(e){null!=e.changedTouches&&e.changedTouches.length>0&&o.handleMouseMove(e.changedTouches[0])},o.handleTouchStart=function(e){null!=e.changedTouches&&e.changedTouches.length>0&&o.handleMouseDown(e.changedTouches[0])},o.handleTouchEnd=function(e){null!=e.changedTouches&&e.changedTouches.length>0&&o.handleMouseUp(e.changedTouches[0])},o.verticalCoordinatesGenerator=function(e){var t=e.xAxis,i=e.width,n=e.height,o=e.offset;return(0,On.getCoordinatesOfGrid)((0,an.f)(va(va(va({},ha.defaultProps),t),{},{ticks:(0,On.getTicksOfAxis)(t,!0),viewBox:{x:0,y:0,width:i,height:n}})),o.left,o.left+o.width)},o.horizontalCoordinatesGenerator=function(e){var t=e.yAxis,i=e.width,n=e.height,o=e.offset;return(0,On.getCoordinatesOfGrid)((0,an.f)(va(va(va({},ha.defaultProps),t),{},{ticks:(0,On.getTicksOfAxis)(t,!0),viewBox:{x:0,y:0,width:i,height:n}})),o.top,o.top+o.height)},o.axesTicksGenerator=function(e){return(0,On.getTicksOfAxis)(e,!0)},o.renderCursor=function(e){var t=o.state,n=t.isTooltipActive,a=t.activeCoordinate,s=t.activePayload,l=t.offset,c=t.activeTooltipIndex,d=o.getTooltipEventType();if(!e||!e.props.cursor||!n||!a||"ScatterChart"!==i&&"axis"!==d)return null;var u,h=o.props.layout,p=un.Curve;if("ScatterChart"===i)u=a,p=hn.X;else if("BarChart"===i)u=o.getCursorRectangle(),p=fn.Rectangle;else if("radial"===h){var g=o.getCursorPoints(),f=g.cx,m=g.cy,v=g.radius;u={cx:f,cy:m,startAngle:g.startAngle,endAngle:g.endAngle,innerRadius:v,outerRadius:v},p=pn.Sector}else u={points:o.getCursorPoints()},p=un.Curve;var y=e.key||"_recharts-cursor",C=va(va(va(va({stroke:"#ccc",pointerEvents:"none"},l),u),(0,mn.filterProps)(e.props.cursor)),{},{payload:s,payloadIndex:c,key:y,className:"recharts-tooltip-cursor"});return(0,r.isValidElement)(e.props.cursor)?(0,r.cloneElement)(e.props.cursor,C):(0,r.createElement)(p,C)},o.renderPolarAxis=function(e,t,i){var n=so.get(e,"type.axisType"),a=so.get(o.state,"".concat(n,"Map")),s=a&&a[e.props["".concat(n,"Id")]];return(0,r.cloneElement)(e,va(va({},s),{},{className:n,key:e.key||"".concat(t,"-").concat(i),ticks:(0,On.getTicksOfAxis)(s,!0)}))},o.renderXAxis=function(e,t,i){var n=o.state.xAxisMap[e.props.xAxisId];return o.renderAxis(n,e,t,i)},o.renderYAxis=function(e,t,i){var n=o.state.yAxisMap[e.props.yAxisId];return o.renderAxis(n,e,t,i)},o.renderGrid=function(e){var t=o.state,i=t.xAxisMap,n=t.yAxisMap,a=t.offset,s=o.props,l=s.width,c=s.height,d=(0,rn.getAnyElementOfObject)(i),u=so.find(n,(function(e){return so.every(e.domain,ba)}))||(0,rn.getAnyElementOfObject)(n),h=e.props||{};return(0,r.cloneElement)(e,{key:e.key||"grid",x:(0,rn.isNumber)(h.x)?h.x:a.left,y:(0,rn.isNumber)(h.y)?h.y:a.top,width:(0,rn.isNumber)(h.width)?h.width:a.width,height:(0,rn.isNumber)(h.height)?h.height:a.height,xAxis:d,yAxis:u,offset:a,chartWidth:l,chartHeight:c,verticalCoordinatesGenerator:h.verticalCoordinatesGenerator||o.verticalCoordinatesGenerator,horizontalCoordinatesGenerator:h.horizontalCoordinatesGenerator||o.horizontalCoordinatesGenerator})},o.renderPolarGrid=function(e){var t=e.props,i=t.radialLines,n=t.polarAngles,a=t.polarRadius,s=o.state,l=s.radiusAxisMap,c=s.angleAxisMap,d=(0,rn.getAnyElementOfObject)(l),u=(0,rn.getAnyElementOfObject)(c),h=u.cx,p=u.cy,g=u.innerRadius,f=u.outerRadius;return(0,r.cloneElement)(e,{polarAngles:ao.isArray(n)?n:(0,On.getTicksOfAxis)(u,!0).map((function(e){return e.coordinate})),polarRadius:ao.isArray(a)?a:(0,On.getTicksOfAxis)(d,!0).map((function(e){return e.coordinate})),cx:h,cy:p,innerRadius:g,outerRadius:f,key:e.key||"polar-grid",radialLines:i})},o.renderLegend=function(){var e=o.state.formattedGraphicalItems,t=o.props,i=t.children,n=t.width,a=t.height,s=o.props.margin||{},l=n-(s.left||0)-(s.right||0),c=(0,On.getLegendProps)({children:i,formattedGraphicalItems:e,legendWidth:l,legendContent:d});if(!c)return null;var u=c.item,h=vo(c,ga);return(0,r.cloneElement)(u,va(va({},h),{},{chartWidth:n,chartHeight:a,margin:s,ref:function(e){o.legendInstance=e},onBBoxUpdate:o.handleLegendBBoxUpdate}))},o.renderTooltip=function(){var e=o.props.children,t=(0,mn.findChildByType)(e,cn.u);if(!t)return null;var i=o.state,n=i.isTooltipActive,a=i.activeCoordinate,s=i.activePayload,l=i.activeLabel,c=i.offset;return(0,r.cloneElement)(t,{viewBox:va(va({},c),{},{x:c.left,y:c.top}),active:n,label:l,payload:n?s:[],coordinate:a})},o.renderBrush=function(e){var t=o.props,i=t.margin,n=t.data,a=o.state,s=a.offset,l=a.dataStartIndex,c=a.dataEndIndex,d=a.updateId;return(0,r.cloneElement)(e,{key:e.key||"_recharts-brush",onChange:(0,On.combineEventHandlers)(o.handleBrushChange,null,e.props.onChange),data:n,x:(0,rn.isNumber)(e.props.x)?e.props.x:s.left,y:(0,rn.isNumber)(e.props.y)?e.props.y:s.top+s.height+s.brushBottom-(i.bottom||0),width:(0,rn.isNumber)(e.props.width)?e.props.width:s.width,startIndex:l,endIndex:c,updateId:"brush-".concat(d)})},o.renderReferenceElement=function(e,t,i){if(!e)return null;var n=So(o).clipPathId,a=o.state,s=a.xAxisMap,l=a.yAxisMap,c=a.offset,d=e.props,u=d.xAxisId,h=d.yAxisId;return(0,r.cloneElement)(e,{key:e.key||"".concat(t,"-").concat(i),xAxis:s[u],yAxis:l[h],viewBox:{x:c.left,y:c.top,width:c.width,height:c.height},clipPathId:n})},o.renderActivePoints=function(e){var t=e.item,i=e.activePoint,o=e.basePoint,r=e.childIndex,a=e.isRange,s=[],l=t.props.key,c=t.item.props,d=c.activeDot,u=va(va({index:r,dataKey:c.dataKey,cx:i.x,cy:i.y,r:4,fill:(0,On.getMainColorOfGraphicItem)(t.item),strokeWidth:2,stroke:"#fff",payload:i.payload,value:i.value,key:"".concat(l,"-activePoint-").concat(r)},(0,mn.filterProps)(d)),(0,bn.adaptEventHandlers)(d));return s.push(n.renderActiveDot(d,u)),o?s.push(n.renderActiveDot(d,va(va({},u),{},{cx:o.x,cy:o.y,key:"".concat(l,"-basePoint-").concat(r)}))):a&&s.push(null),s},o.renderGraphicChild=function(e,t,i){var n=o.filterFormatItem(e,t,i);if(!n)return null;var a=o.getTooltipEventType(),s=o.state,l=s.isTooltipActive,c=s.tooltipAxis,d=s.activeTooltipIndex,u=s.activeLabel,h=o.props.children,p=(0,mn.findChildByType)(h,cn.u),g=n.props,f=g.points,m=g.isRange,v=g.baseLine,y=n.item.props,C=y.activeDot,b=!y.hide&&l&&p&&C&&d>=0,S={};"axis"!==a&&p&&"click"===p.props.trigger?S={onClick:(0,On.combineEventHandlers)(o.handleItemMouseEnter,null,e.props.onCLick)}:"axis"!==a&&(S={onMouseLeave:(0,On.combineEventHandlers)(o.handleItemMouseLeave,null,e.props.onMouseLeave),onMouseEnter:(0,On.combineEventHandlers)(o.handleItemMouseEnter,null,e.props.onMouseEnter)});var x=(0,r.cloneElement)(e,va(va({},n.props),S));if(b){var T,w;if(c.dataKey&&!c.allowDuplicatedCategory){var O="function"==typeof c.dataKey?function(e){return"function"==typeof c.dataKey?c.dataKey(e.payload):null}:"payload.".concat(c.dataKey.toString());T=(0,rn.findEntryInArray)(f,O,u),w=m&&v&&(0,rn.findEntryInArray)(v,O,u)}else T=f[d],w=m&&v&&v[d];if(!so.isNil(T))return[x].concat(Po(o.renderActivePoints({item:n,activePoint:T,basePoint:w,childIndex:d,isRange:m})))}return m?[x,null,null]:[x,null]},o.renderCustomized=function(e,t,i){return(0,r.cloneElement)(e,va(va({key:"recharts-customized-".concat(i)},o.props),o.state))},o.uniqueChartId=so.isNil(e.id)?(0,rn.uniqueId)("recharts"):e.id,o.clipPathId="".concat(o.uniqueChartId,"-clip"),e.throttleDelay&&(o.triggeredAfterMouseMove=so.throttle(o.triggeredAfterMouseMove,e.throttleDelay)),o.state={},o}return bo(n,[{key:"componentDidMount",value:function(){var e,t,i,n;null===(t=(e=this.props).onStateInitialized)||void 0===t||t.call(e,this.state,"init"),so.isNil(this.props.syncId)||this.addListener(),this.accessibilityManager.setDetails({defaultActiveIndex:void 0!==this.state.tooltipTicks?this.state.tooltipTicks.length-1:0,container:this.container,offset:{left:null!==(i=this.props.margin.left)&&void 0!==i?i:0,top:null!==(n=this.props.margin.top)&&void 0!==n?n:0},coordinateList:this.state.tooltipTicks,mouseHandlerCallback:this.handleMouseMove,layout:this.props.layout})}},{key:"getSnapshotBeforeUpdate",value:function(e,t){var i,n;return this.props.accessibilityLayer?(this.state.tooltipTicks!==t.tooltipTicks&&this.accessibilityManager.setDetails({coordinateList:this.state.tooltipTicks}),this.props.layout!==e.layout&&this.accessibilityManager.setDetails({layout:this.props.layout}),this.props.margin!==e.margin&&this.accessibilityManager.setDetails({offset:{left:null!==(i=this.props.margin.left)&&void 0!==i?i:0,top:null!==(n=this.props.margin.top)&&void 0!==n?n:0}}),null):null}},{key:"componentDidUpdate",value:function(e){var t,i;null===(i=(t=this.props).onStateChange)||void 0===i||i.call(t,this.state,"update"),so.isNil(e.syncId)&&!so.isNil(this.props.syncId)&&this.addListener(),!so.isNil(e.syncId)&&so.isNil(this.props.syncId)&&this.removeListener()}},{key:"componentWillUnmount",value:function(){this.clearDeferId(),so.isNil(this.props.syncId)||this.removeListener(),this.cancelThrottledTriggerAfterMouseMove()}},{key:"cancelThrottledTriggerAfterMouseMove",value:function(){"function"==typeof this.triggeredAfterMouseMove.cancel&&this.triggeredAfterMouseMove.cancel()}},{key:"getTooltipEventType",value:function(){var e=(0,mn.findChildByType)(this.props.children,cn.u);if(e&&ao.isBoolean(e.props.shared)){var t=e.props.shared?"axis":"item";return l.indexOf(t)>=0?t:a}return a}},{key:"getMouseInfo",value:function(e){if(!this.container)return null;var t=(0,Sn.getOffset)(this.container),i=(0,Sn.calculateChartCoordinate)(e,t),n=this.inRange(i.chartX,i.chartY);if(!n)return null;var o=this.state,r=o.xAxisMap,a=o.yAxisMap;if("axis"!==this.getTooltipEventType()&&r&&a){var s=(0,rn.getAnyElementOfObject)(r).scale,l=(0,rn.getAnyElementOfObject)(a).scale,c=s&&s.invert?s.invert(i.chartX):null,d=l&&l.invert?l.invert(i.chartY):null;return va(va({},i),{},{xValue:c,yValue:d})}var u=Pa(this.state,this.props.data,this.props.layout,n);return u?va(va({},i),u):null}},{key:"getCursorRectangle",value:function(){var e=this.props.layout,t=this.state,i=t.activeCoordinate,n=t.offset,o=t.tooltipAxisBandSize,r=o/2;return{stroke:"none",fill:"#ccc",x:"horizontal"===e?i.x-r:n.left+.5,y:"horizontal"===e?n.top+.5:i.y-r,width:"horizontal"===e?o:n.width-1,height:"horizontal"===e?n.height-1:o}}},{key:"getCursorPoints",value:function(){var e,t,i,n,o=this.props.layout,r=this.state,a=r.activeCoordinate,s=r.offset;if("horizontal"===o)i=e=a.x,t=s.top,n=s.top+s.height;else if("vertical"===o)n=t=a.y,e=s.left,i=s.left+s.width;else if(!so.isNil(a.cx)||!so.isNil(a.cy)){if("centric"!==o){var l=a.cx,c=a.cy,d=a.radius,u=a.startAngle,h=a.endAngle;return{points:[(0,An.polarToCartesian)(l,c,d,u),(0,An.polarToCartesian)(l,c,d,h)],cx:l,cy:c,radius:d,startAngle:u,endAngle:h}}var p=a.cx,g=a.cy,f=a.innerRadius,m=a.outerRadius,v=a.angle,y=(0,An.polarToCartesian)(p,g,f,v),C=(0,An.polarToCartesian)(p,g,m,v);e=y.x,t=y.y,i=C.x,n=C.y}return[{x:e,y:t},{x:i,y:n}]}},{key:"inRange",value:function(e,t){var i=this.props.layout;if("horizontal"===i||"vertical"===i){var n=this.state.offset;return e>=n.left&&e<=n.left+n.width&&t>=n.top&&t<=n.top+n.height?{x:e,y:t}:null}var o=this.state,r=o.angleAxisMap,a=o.radiusAxisMap;if(r&&a){var s=(0,rn.getAnyElementOfObject)(r);return(0,An.inRangeOfSector)({x:e,y:t},s)}return null}},{key:"parseEventsOfWrapper",value:function(){var e=this.props.children,t=this.getTooltipEventType(),i=(0,mn.findChildByType)(e,cn.u),n={};return i&&"axis"===t&&(n="click"===i.props.trigger?{onClick:this.handleClick}:{onMouseEnter:this.handleMouseEnter,onMouseMove:this.handleMouseMove,onMouseLeave:this.handleMouseLeave,onTouchMove:this.handleTouchMove,onTouchStart:this.handleTouchStart,onTouchEnd:this.handleTouchEnd}),va(va({},(0,bn.adaptEventHandlers)(this.props,this.handleOuterEvent)),n)}},{key:"addListener",value:function(){En.td.on(En.YZ,this.handleReceiveSyncEvent),En.td.setMaxListeners&&En.td._maxListeners&&En.td.setMaxListeners(En.td._maxListeners+1)}},{key:"removeListener",value:function(){En.td.removeListener(En.YZ,this.handleReceiveSyncEvent),En.td.setMaxListeners&&En.td._maxListeners&&En.td.setMaxListeners(En.td._maxListeners-1)}},{key:"triggerSyncEvent",value:function(e){var t=this.props.syncId;so.isNil(t)||En.td.emit(En.YZ,t,this.uniqueChartId,e)}},{key:"applySyncEvent",value:function(e){var t=this.props,i=t.layout,n=t.syncMethod,o=this.state.updateId,r=e.dataStartIndex,a=e.dataEndIndex;if(so.isNil(e.dataStartIndex)&&so.isNil(e.dataEndIndex))if(so.isNil(e.activeTooltipIndex))this.setState(e);else{var s=e.chartX,l=e.chartY,c=e.activeTooltipIndex,d=this.state,u=d.offset,h=d.tooltipTicks;if(!u)return;if("function"==typeof n)c=n(h,e);else if("value"===n){c=-1;for(var g=0;g<h.length;g++)if(h[g].value===e.activeLabel){c=g;break}}var f=va(va({},u),{},{x:u.left,y:u.top}),m=Math.min(s,f.x+f.width),v=Math.min(l,f.y+f.height),y=h[c]&&h[c].value,C=Oa(this.state,this.props.data,c),b=h[c]?{x:"horizontal"===i?h[c].coordinate:m,y:"horizontal"===i?v:h[c].coordinate}:Ca;this.setState(va(va({},e),{},{activeLabel:y,activeCoordinate:b,activePayload:C,activeTooltipIndex:c}))}else this.setState(va({dataStartIndex:r,dataEndIndex:a},p({props:this.props,dataStartIndex:r,dataEndIndex:a,updateId:o},this.state)))}},{key:"filterFormatItem",value:function(e,t,i){for(var n=this.state.formattedGraphicalItems,o=0,r=n.length;o<r;o++){var a=n[o];if(a.item===e||a.props.key===e.key||t===(0,mn.getDisplayName)(a.item.type)&&i===a.childIndex)return a}return null}},{key:"renderAxis",value:function(e,t,i,n){var o=this.props,a=o.width,s=o.height;return r.createElement(ha,va(va({},e),{},{className:co("recharts-".concat(e.axisType," ").concat(e.axisType),e.className),key:t.key||"".concat(i,"-").concat(n),viewBox:{x:0,y:0,width:a,height:s},ticksGenerator:this.axesTicksGenerator}))}},{key:"renderClipPath",value:function(){var e=this.clipPathId,t=this.state.offset,i=t.left,n=t.top,o=t.height,a=t.width;return r.createElement("defs",null,r.createElement("clipPath",{id:e},r.createElement("rect",{x:i,y:n,height:o,width:a})))}},{key:"getXScales",value:function(){var e=this.state.xAxisMap;return e?Object.entries(e).reduce((function(e,t){var i=Un(t,2),n=i[0],o=i[1];return va(va({},e),{},Zn({},n,o.scale))}),{}):null}},{key:"getYScales",value:function(){var e=this.state.yAxisMap;return e?Object.entries(e).reduce((function(e,t){var i=Un(t,2),n=i[0],o=i[1];return va(va({},e),{},Zn({},n,o.scale))}),{}):null}},{key:"getXScaleByAxisId",value:function(e){var t,i;return null===(i=null===(t=this.state.xAxisMap)||void 0===t?void 0:t[e])||void 0===i?void 0:i.scale}},{key:"getYScaleByAxisId",value:function(e){var t,i;return null===(i=null===(t=this.state.yAxisMap)||void 0===t?void 0:t[e])||void 0===i?void 0:i.scale}},{key:"getItemByXY",value:function(e){var t=this.state.formattedGraphicalItems;if(t&&t.length)for(var i=0,n=t.length;i<n;i++){var o=t[i],r=o.props,a=o.item,s=(0,mn.getDisplayName)(a.type);if("Bar"===s){var l=(r.data||[]).find((function(t){return(0,fn.isInRectangle)(e,t)}));if(l)return{graphicalItem:o,payload:l}}else if("RadialBar"===s){var c=(r.data||[]).find((function(t){return(0,An.inRangeOfSector)(e,t)}));if(c)return{graphicalItem:o,payload:c}}}return null}},{key:"render",value:function(){var e=this;if(!(0,mn.validateWidthHeight)(this))return null;var t=this.props,i=t.children,n=t.className,o=t.width,a=t.height,s=t.style,l=t.compact,c=t.title,d=t.desc,u=vo(t,fa),h=(0,mn.filterProps)(u),p={CartesianGrid:{handler:this.renderGrid,once:!0},ReferenceArea:{handler:this.renderReferenceElement},ReferenceLine:{handler:this.renderReferenceElement},ReferenceDot:{handler:this.renderReferenceElement},XAxis:{handler:this.renderXAxis},YAxis:{handler:this.renderYAxis},Brush:{handler:this.renderBrush,once:!0},Bar:{handler:this.renderGraphicChild},Line:{handler:this.renderGraphicChild},Area:{handler:this.renderGraphicChild},Radar:{handler:this.renderGraphicChild},RadialBar:{handler:this.renderGraphicChild},Scatter:{handler:this.renderGraphicChild},Pie:{handler:this.renderGraphicChild},Funnel:{handler:this.renderGraphicChild},Tooltip:{handler:this.renderCursor,once:!0},PolarGrid:{handler:this.renderPolarGrid,once:!0},PolarAngleAxis:{handler:this.renderPolarAxis},PolarRadiusAxis:{handler:this.renderPolarAxis},Customized:{handler:this.renderCustomized}};if(l)return r.createElement(sn.Surface,va(va({},h),{},{width:o,height:a,title:c,desc:d}),this.renderClipPath(),(0,mn.renderByOrder)(i,p));this.props.accessibilityLayer&&(h.tabIndex=0,h.role="img",h.onKeyDown=function(t){e.accessibilityManager.keyboardEvent(t)},h.onFocus=function(){e.accessibilityManager.focus()});var g=this.parseEventsOfWrapper();return r.createElement("div",va(va({className:co("recharts-wrapper",n),style:va({position:"relative",cursor:"default",width:o,height:a},s)},g),{},{ref:function(t){e.container=t},role:"region"}),r.createElement(sn.Surface,va(va({},h),{},{width:o,height:a,title:c,desc:d}),this.renderClipPath(),(0,mn.renderByOrder)(i,p)),this.renderLegend(),this.renderTooltip())}}]),n}()).displayName=i,t.defaultProps=va({layout:"horizontal",stackOffset:"none",barCategoryGap:"10%",barGap:4,margin:{top:5,right:5,bottom:5,left:5},reverseStackOrder:!1,syncMethod:"index"},h),t.getDerivedStateFromProps=function(e,t){var i=e.data,n=e.children,o=e.width,r=e.height,a=e.layout,s=e.stackOffset,l=e.margin;if(so.isNil(t.updateId)){var c=Aa(e);return va(va(va({},c),{},{updateId:0},p(va(va({props:e},c),{},{updateId:0}),t)),{},{prevData:i,prevWidth:o,prevHeight:r,prevLayout:a,prevStackOffset:s,prevMargin:l,prevChildren:n})}if(i!==t.prevData||o!==t.prevWidth||r!==t.prevHeight||a!==t.prevLayout||s!==t.prevStackOffset||!(0,vn.shallowEqual)(l,t.prevMargin)){var d=Aa(e),u={chartX:t.chartX,chartY:t.chartY,isTooltipActive:t.isTooltipActive},h=va(va({},Pa(t,i,a)),{},{updateId:t.updateId+1}),g=va(va(va({},d),u),h);return va(va(va({},g),p(va({props:e},g),t)),{},{prevData:i,prevWidth:o,prevHeight:r,prevLayout:a,prevStackOffset:s,prevMargin:l,prevChildren:n})}if(!(0,mn.isChildrenEqual)(n,t.prevChildren)){var f=so.isNil(i)?t.updateId+1:t.updateId;return va(va({updateId:f},p(va(va({props:e},t),{},{updateId:f}),t)),{},{prevChildren:n})}return null},t.renderActiveDot=function(e,t){var i;return i=(0,r.isValidElement)(e)?(0,r.cloneElement)(e,t):so.isFunction(e)?e(t):r.createElement(gn.Dot,va({},t)),r.createElement(ln.Layer,{className:"recharts-active-dot",key:t.key},i)},t}({chartName:"AreaChart",GraphicalChild:kn.u,axisComponents:[{axisType:"xAxis",AxisComp:In.K},{axisType:"yAxis",AxisComp:Dn.B}],formatAxisMap:_n.formatAxisMap});function Ia(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Da(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Ia(Object(i),!0).forEach((function(t){Zn(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Ia(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var _a=Da(Da(Da({color:Nn.T.colorNeutralForegroundInverted},Rn.q5.borderRadius(Nn.T.borderRadiusLarge)),Mn.w.caption1Strong),{},{paddingLeft:Nn.T.spacingHorizontalS,paddingRight:Nn.T.spacingHorizontalS,paddingTop:Nn.T.spacingVerticalXXS,paddingBottom:Nn.T.spacingVerticalXXS}),Na=(0,Ln.Z)({ReferenceDotLabel:Da(Da(Da({},Rn.q5.borderRadius(Nn.T.borderRadiusLarge)),Mn.w.caption1),{},{textAlign:"center",paddingTop:Nn.T.spacingVerticalXXS,paddingBottom:Nn.T.spacingVerticalXXS,color:Nn.T.colorNeutralForeground1,backgroundColor:Nn.T.colorNeutralBackground3}),tooltipColorBrand:Da(Da({},_a),{},{backgroundColor:Nn.T.colorBrandForeground1}),tooltipColorRed:Da(Da({},_a),{},{backgroundColor:Nn.T.colorPaletteRedForeground1}),tooltipColorGreen:Da(Da({},_a),{},{backgroundColor:Nn.T.colorPaletteGreenForeground1}),container:{width:"100%",marginRight:"-8px"}});function Ra(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Ma(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Ra(Object(i),!0).forEach((function(t){Zn(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Ra(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}(0,Ln.Z)({});var La=function(e){var t=Na(),i=e.data,n=e.priceBuffer,o=e.locale,a=e.localeCompact,s=e.timeZone,l=e.height,c=e.color,d=e.currency,u=e.numberFormatOptions,h=e.dateTimeFormatOptions,p=e.lowestPriceIndex,g=e.medianPriceIndex,f=e.highestPriceIndex,m=e.lowestPriceLabel,v=e.highestPriceLabel,y=e.medianPriceLabel,C=e.showHighestLowestPriceLabel,b=e.showTooltip,S=e.tooltipTodayLabel,x=e.tooltipDateFormatter,T=e.animationDuration,w=e.disableAnimation,O=e.ariaProps,P=new Intl.DateTimeFormat(o,Ma(Ma({},h),{},{timeZone:s})).format;if(1===i.length){var A=i[0],E=A.date,k=null==A?void 0:A.price,I=new Date(E);I.setDate(I.getDate()-1);var D={date:I.toISOString().split("T")[0],price:k};i.unshift(D)}var _,N=i[i.length-1].date,R=i[i.length-1].price,M=void 0!==g&&g>=0&&g<=i.length-1?i[g].price:i[0].price,L=M!==i[i.length-1].price,B=M>i[i.length-1].price;_=void 0!==c?c:L?B?"green":"red":"brand";var F=new Map([["brand",Nn.T.colorBrandForeground1],["red",Nn.T.colorPaletteRedForeground1],["green",Nn.T.colorPaletteGreenForeground1]]),H=new Map([["brand",t.tooltipColorBrand],["red",t.tooltipColorRed],["green",t.tooltipColorGreen]]),$=Un((0,r.useState)(!1),2),Z=$[0],V=$[1],G=Un((0,r.useState)(!1),2),j=G[0],z=G[1],W=Un((0,r.useState)({date:N,price:R}),2),K=W[0],q=W[1],Y=Intl.NumberFormat(a,Ma(Ma({},u),{},{currency:d,maximumFractionDigits:2})),X=Intl.NumberFormat(a,Ma(Ma({},u),{},{currency:d})),J=0;i.forEach((function(e){var t=8.5*X.format(null==e?void 0:e.price).length;J=t>0?t:0}));var Q=function(e){var i=r.useRef(null),n=e.viewBox,o=e.price,a=e.label,s="".concat(a," ").concat(Y.format(o)),l=7*s.toString().length,c=-l/2;n.x<l&&(c=0);var d=n.y+-25,u=n.x+c,h=Un((0,r.useState)(!1),2),p=h[0],g=h[1];return r.useEffect((function(){setTimeout((function(){return g(!0)}),500)}),[j]),r.createElement("g",null,p&&r.createElement("foreignObject",{x:u,y:d,width:l,height:30},r.createElement("div",{className:t.ReferenceDotLabel,ref:i},s)))};return r.createElement("div",{className:t.container,style:{marginBottom:10}},r.createElement(U,{width:"100%",height:l},r.createElement(ka,Ma(Ma({},null==O?void 0:O.chart),{},{data:i,style:{paddingTop:25},accessibilityLayer:!0,onMouseMove:b?function(e){e.isTooltipActive?(z(!0),q(e.activePayload[0].payload)):z(!1)}:void 0}),r.createElement("defs",null,r.createElement("linearGradient",{id:"fill-".concat(_),x1:"0",y1:"0",x2:"0",y2:"1"},r.createElement("stop",{offset:"0%",stopColor:F.get(_),stopOpacity:.2}),r.createElement("stop",{offset:"100%",stopColor:F.get(_),stopOpacity:0}))),r.createElement(ve,{stroke:Nn.T.colorNeutralStroke3,strokeWidth:1,vertical:!1,horizontal:!0}),r.createElement(ye,{dataKey:"price",tickCount:4,axisLine:!1,width:J,domain:function(e){var t=Un(e,2),i=t[0],o=t[1],r=i===o?0:void 0===n?.3:n;return[i-i*r>0?i-i*r:0,o+o*r]},tickLine:!1,tickMargin:3,tick:r.createElement((function(e){var t=e.x,i=e.y,n=e.index,o=e.visibleTicksCount,a=e.payload,s=0===n&&1!==o?"auto":n===o-1?"mathematical":"central";return r.createElement("g",{transform:"translate(".concat(t,",").concat(i,")")},r.createElement("text",{textAnchor:"end",dominantBaseline:s,fontSize:Mn.w.caption2.fontSize,fill:Nn.T.colorNeutralForeground4},X.format(a.value)))}),null)}),r.createElement(Ce,{dataKey:"date",type:"category",allowDuplicatedCategory:!0,axisLine:!1,tickFormatter:function(e,t){return P(new Date(e))},tickLine:!1,tick:{fontSize:Mn.w.caption2.fontSize,fill:Nn.T.colorNeutralForeground4}}),b&&r.createElement(mo,Ma(Ma({role:"note",tabIndex:(null==O?void 0:O.tooltipTabIndex)||0},null==O?void 0:O.tooltip),{},{labelClassName:"chart-tooltip-label",active:Z,isAnimationActive:!1,position:{y:0},offset:0,firstPosition:"end",cursor:!1,wrapperStyle:{outline:"none",visibility:Z?"visible":"hidden"},content:r.createElement((function(){var e,t=K.date,n=null==K?void 0:K.price,o=void 0===x?"".concat(P(new Date(t))," ").concat(new Date(t).getDate()):x(new Date(t));return r.createElement("div",{className:H.get(_)},t===i[i.length-1].date&&""!==S?S:o," - ","".concat(Y.format(n)),void 0!==p&&t===i[p].date&&!C&&m&&" (".concat(m,")"),void 0!==f&&t===i[f].date&&!C&&v&&" (".concat(v,")"),void 0!==g&&n===(null===(e=i[g])||void 0===e?void 0:e.price)&&y&&" (".concat(y,")"))}),null)})),r.createElement(ki,{type:"linear",dataKey:"price",stroke:F.get(_),strokeWidth:2,dot:!1,fill:"url(#fill-".concat(_,")"),animationEasing:"ease-out",animationDuration:w?0:T,onAnimationStart:function(){V(!1)},onAnimationEnd:function(){V(!0)}}),Z&&b&&r.createElement(Yi,{x:K.date,stroke:Nn.T.colorNeutralForeground4,strokeWidth:Nn.T.strokeWidthThin,strokeDasharray:"4 4"}),Z&&r.createElement(r.Fragment,null,void 0!==g&&g>=0&&g<=i.length-1&&r.createElement(Yi,{y:i[g].price,stroke:F.get(_),strokeWidth:Nn.T.strokeWidthThin,strokeDasharray:"4 4",isFront:!1}),void 0!==p&&p>=0&&p<=i.length-1&&r.createElement(tn,Ma(Ma({tabIndex:(null==O?void 0:O.lowestPricePointTabIndex)||0,role:"note"},null==O?void 0:O.lowestPricePoint),{},{x:i[p].date,y:i[p].price,r:4,fill:F.get(_),stroke:Nn.T.colorNeutralBackground1,strokeWidth:2}),C&&r.createElement(ni,{key:m,content:r.createElement(Q,{price:i[p].price,label:m})})),void 0!==f&&f>=0&&f<=i.length-1&&r.createElement(tn,Ma(Ma({tabIndex:(null==O?void 0:O.highestPricePointTabIndex)||0,role:"note"},null==O?void 0:O.highestPricePoint),{},{x:i[f].date,y:i[f].price,r:4,fill:F.get(_),stroke:Nn.T.colorNeutralBackground1,strokeWidth:2}),C&&r.createElement(ni,{content:r.createElement(Q,{price:i[f].price,label:v})})),r.createElement(tn,Ma(Ma({tabIndex:(null==O?void 0:O.activePricePointTabIndex)||0,role:"note"},null==O?void 0:O.activePricePoint),{},{x:K.date,y:K.price,r:7,isFront:!0,fill:F.get(_),stroke:Nn.T.colorNeutralBackground1,strokeWidth:4}))))))};La.defaultProps={locale:"en-US",localeCompact:"en-US",dateTimeFormatOptions:{month:"short"},numberFormatOptions:{notation:"compact",style:"currency",currency:"USD",minimumFractionDigits:0,maximumFractionDigits:0},height:140,showHighestLowestPriceLabel:!1,medianPriceLabel:"Median",tooltipTodayLabel:"",lowestPriceLabel:"Low",highestPriceLabel:"High",currency:"USD",timeZone:"UTC",animationDuration:1e3,disableAnimation:!1,priceBuffer:.3,showTooltip:!0}},44323:function(e,t,i){"use strict";i.r(t),i.d(t,{bingTheme:function(){return Le},shoppingTheme:function(){return Re},themes:function(){return Oe.themes},useSharedColors:function(){return Be},useSharedLayouts:function(){return Fe},useSharedStyles:function(){return $e},useSharedTokens:function(){return Ze},useSharedTypography:function(){return je}});const n="#0a0a0a",o="#141414",r="#1f1f1f",a="#242424",s="#292929",l="#2e2e2e",c="#333333",d="#383838",u="#3d3d3d",h="#424242",p="#575757",g="#616161",f="#707070",m="#adadad",v="#b3b3b3",y="#bdbdbd",C="#d6d6d6",b="#e0e0e0",S="#e6e6e6",x="#ebebeb",T="#f0f0f0",w="#f5f5f5",O="#fafafa",P="rgba(255, 255, 255, 0.1)",A="rgba(255, 255, 255, 0.2)",E="rgba(255, 255, 255, 0.4)",k="rgba(255, 255, 255, 0.5)",I="rgba(0, 0, 0, 0.05)",D="rgba(0, 0, 0, 0.1)",_="rgba(0, 0, 0, 0.2)",N="rgba(0, 0, 0, 0.3)",R="rgba(0, 0, 0, 0.5)",M="#ffffff",L="#000000",B={shade50:"#200205",shade40:"#3b0509",shade30:"#6e0811",shade20:"#960b18",shade10:"#b10e1c",primary:"#c50f1f",tint10:"#cc2635",tint20:"#d33f4c",tint30:"#dc626d",tint40:"#eeacb2",tint50:"#f6d1d5",tint60:"#fdf3f4"},F={shade50:"#031403",shade40:"#052505",shade30:"#094509",shade20:"#0c5e0c",shade10:"#0e700e",primary:"#107c10",tint10:"#218c21",tint20:"#359b35",tint30:"#54b054",tint40:"#9fd89f",tint50:"#c9eac9",tint60:"#f1faf1"},U={red:{shade50:"#210809",shade40:"#3f1011",shade30:"#751d1f",shade20:"#9f282b",shade10:"#bc2f32",primary:"#d13438",tint10:"#d7494c",tint20:"#dc5e62",tint30:"#e37d80",tint40:"#f1bbbc",tint50:"#f8dadb",tint60:"#fdf6f6"},green:F,darkOrange:{shade50:"#230900",shade40:"#411200",shade30:"#7a2101",shade20:"#a62d01",shade10:"#c43501",primary:"#da3b01",tint10:"#de501c",tint20:"#e36537",tint30:"#e9835e",tint40:"#f4bfab",tint50:"#f9dcd1",tint60:"#fdf6f3"},yellow:{primary:"#fde300",shade10:"#e4cc00",shade20:"#c0ad00",shade30:"#817400",shade40:"#4c4400",shade50:"#282400",tint10:"#fde61e",tint20:"#fdea3d",tint30:"#feee66",tint40:"#fef7b2",tint50:"#fffad6",tint60:"#fffef5"},berry:{shade50:"#1f091d",shade40:"#3a1136",shade30:"#6d2064",shade20:"#932b88",shade10:"#af33a1",primary:"#c239b3",tint10:"#c94cbc",tint20:"#d161c4",tint30:"#da7ed0",tint40:"#edbbe7",tint50:"#f5daf2",tint60:"#fdf5fc"},lightGreen:{shade50:"#031a02",shade40:"#063004",shade30:"#0b5a08",shade20:"#0e7a0b",shade10:"#11910d",primary:"#13a10e",tint10:"#27ac22",tint20:"#3db838",tint30:"#5ec75a",tint40:"#a7e3a5",tint50:"#cef0cd",tint60:"#f2fbf2"},marigold:{shade50:"#251a00",shade40:"#463100",shade30:"#835b00",shade20:"#b27c00",shade10:"#d39300",primary:"#eaa300",tint10:"#edad1c",tint20:"#efb839",tint30:"#f2c661",tint40:"#f9e2ae",tint50:"#fcefd3",tint60:"#fefbf4"}},H={darkRed:{shade50:"#130204",shade40:"#230308",shade30:"#420610",shade20:"#590815",shade10:"#690a19",primary:"#750b1c",tint10:"#861b2c",tint20:"#962f3f",tint30:"#ac4f5e",tint40:"#d69ca5",tint50:"#e9c7cd",tint60:"#f9f0f2"},cranberry:B,pumpkin:{shade50:"#200d03",shade40:"#3d1805",shade30:"#712d09",shade20:"#9a3d0c",shade10:"#b6480e",primary:"#ca5010",tint10:"#d06228",tint20:"#d77440",tint30:"#df8e64",tint40:"#efc4ad",tint50:"#f7dfd2",tint60:"#fdf7f4"},peach:{shade50:"#291600",shade40:"#4d2a00",shade30:"#8f4e00",shade20:"#c26a00",shade10:"#e67e00",primary:"#ff8c00",tint10:"#ff9a1f",tint20:"#ffa83d",tint30:"#ffba66",tint40:"#ffddb3",tint50:"#ffedd6",tint60:"#fffaf5"},gold:{shade50:"#1f1900",shade40:"#3a2f00",shade30:"#6c5700",shade20:"#937700",shade10:"#ae8c00",primary:"#c19c00",tint10:"#c8a718",tint20:"#d0b232",tint30:"#dac157",tint40:"#ecdfa5",tint50:"#f5eece",tint60:"#fdfbf2"},brass:{shade50:"#181202",shade40:"#2e2103",shade30:"#553e06",shade20:"#745408",shade10:"#89640a",primary:"#986f0b",tint10:"#a47d1e",tint20:"#b18c34",tint30:"#c1a256",tint40:"#e0cea2",tint50:"#efe4cb",tint60:"#fbf8f2"},brown:{shade50:"#170e07",shade40:"#2b1a0e",shade30:"#50301a",shade20:"#6c4123",shade10:"#804d29",primary:"#8e562e",tint10:"#9c663f",tint20:"#a97652",tint30:"#bb8f6f",tint40:"#ddc3b0",tint50:"#edded3",tint60:"#faf7f4"},forest:{shade50:"#0c1501",shade40:"#162702",shade30:"#294903",shade20:"#376304",shade10:"#427505",primary:"#498205",tint10:"#599116",tint20:"#6ba02b",tint30:"#85b44c",tint40:"#bdd99b",tint50:"#dbebc7",tint60:"#f6faf0"},seafoam:{shade50:"#002111",shade40:"#003d20",shade30:"#00723b",shade20:"#009b51",shade10:"#00b85f",primary:"#00cc6a",tint10:"#19d279",tint20:"#34d889",tint30:"#5ae0a0",tint40:"#a8f0cd",tint50:"#cff7e4",tint60:"#f3fdf8"},darkGreen:{shade50:"#021102",shade40:"#032003",shade30:"#063b06",shade20:"#085108",shade10:"#0a5f0a",primary:"#0b6a0b",tint10:"#1a7c1a",tint20:"#2d8e2d",tint30:"#4da64d",tint40:"#9ad29a",tint50:"#c6e7c6",tint60:"#f0f9f0"},lightTeal:{shade50:"#001d1f",shade40:"#00373a",shade30:"#00666d",shade20:"#008b94",shade10:"#00a5af",primary:"#00b7c3",tint10:"#18bfca",tint20:"#32c8d1",tint30:"#58d3db",tint40:"#a6e9ed",tint50:"#cef3f5",tint60:"#f2fcfd"},teal:{shade50:"#001516",shade40:"#012728",shade30:"#02494c",shade20:"#026467",shade10:"#037679",primary:"#038387",tint10:"#159195",tint20:"#2aa0a4",tint30:"#4cb4b7",tint40:"#9bd9db",tint50:"#c7ebec",tint60:"#f0fafa"},steel:{shade50:"#000f12",shade40:"#001b22",shade30:"#00333f",shade20:"#004555",shade10:"#005265",primary:"#005b70",tint10:"#0f6c81",tint20:"#237d92",tint30:"#4496a9",tint40:"#94c8d4",tint50:"#c3e1e8",tint60:"#eff7f9"},blue:{shade50:"#001322",shade40:"#002440",shade30:"#004377",shade20:"#005ba1",shade10:"#006cbf",primary:"#0078d4",tint10:"#1a86d9",tint20:"#3595de",tint30:"#5caae5",tint40:"#a9d3f2",tint50:"#d0e7f8",tint60:"#f3f9fd"},royalBlue:{shade50:"#000c16",shade40:"#00172a",shade30:"#002c4e",shade20:"#003b6a",shade10:"#00467e",primary:"#004e8c",tint10:"#125e9a",tint20:"#286fa8",tint30:"#4a89ba",tint40:"#9abfdc",tint50:"#c7dced",tint60:"#f0f6fa"},cornflower:{shade50:"#0d1126",shade40:"#182047",shade30:"#2c3c85",shade20:"#3c51b4",shade10:"#4760d5",primary:"#4f6bed",tint10:"#637cef",tint20:"#778df1",tint30:"#93a4f4",tint40:"#c8d1fa",tint50:"#e1e6fc",tint60:"#f7f9fe"},navy:{shade50:"#00061d",shade40:"#000c36",shade30:"#001665",shade20:"#001e89",shade10:"#0023a2",primary:"#0027b4",tint10:"#173bbd",tint20:"#3050c6",tint30:"#546fd2",tint40:"#a3b2e8",tint50:"#ccd5f3",tint60:"#f2f4fc"},lavender:{shade50:"#120f25",shade40:"#221d46",shade30:"#3f3682",shade20:"#5649b0",shade10:"#6656d1",primary:"#7160e8",tint10:"#8172eb",tint20:"#9184ee",tint30:"#a79cf1",tint40:"#d2ccf8",tint50:"#e7e4fb",tint60:"#f9f8fe"},purple:{shade50:"#0f0717",shade40:"#1c0e2b",shade30:"#341a51",shade20:"#46236e",shade10:"#532982",primary:"#5c2e91",tint10:"#6b3f9e",tint20:"#7c52ab",tint30:"#9470bd",tint40:"#c6b1de",tint50:"#e0d3ed",tint60:"#f7f4fb"},grape:{shade50:"#160418",shade40:"#29072e",shade30:"#4c0d55",shade20:"#671174",shade10:"#7a1589",primary:"#881798",tint10:"#952aa4",tint20:"#a33fb1",tint30:"#b55fc1",tint40:"#d9a7e0",tint50:"#eaceef",tint60:"#faf2fb"},lilac:{shade50:"#1c0b1f",shade40:"#35153a",shade30:"#63276d",shade20:"#863593",shade10:"#9f3faf",primary:"#b146c2",tint10:"#ba58c9",tint20:"#c36bd1",tint30:"#cf87da",tint40:"#e6bfed",tint50:"#f2dcf5",tint60:"#fcf6fd"},pink:{shade50:"#24091b",shade40:"#441232",shade30:"#80215d",shade20:"#ad2d7e",shade10:"#cd3595",primary:"#e43ba6",tint10:"#e750b0",tint20:"#ea66ba",tint30:"#ef85c8",tint40:"#f7c0e3",tint50:"#fbddf0",tint60:"#fef6fb"},magenta:{shade50:"#1f0013",shade40:"#390024",shade30:"#6b0043",shade20:"#91005a",shade10:"#ac006b",primary:"#bf0077",tint10:"#c71885",tint20:"#ce3293",tint30:"#d957a8",tint40:"#eca5d1",tint50:"#f5cee6",tint60:"#fcf2f9"},plum:{shade50:"#13000c",shade40:"#240017",shade30:"#43002b",shade20:"#5a003b",shade10:"#6b0045",primary:"#77004d",tint10:"#87105d",tint20:"#98246f",tint30:"#ad4589",tint40:"#d696c0",tint50:"#e9c4dc",tint60:"#faf0f6"},beige:{shade50:"#141313",shade40:"#252323",shade30:"#444241",shade20:"#5d5958",shade10:"#6e6968",primary:"#7a7574",tint10:"#8a8584",tint20:"#9a9594",tint30:"#afabaa",tint40:"#d7d4d4",tint50:"#eae8e8",tint60:"#faf9f9"},mink:{shade50:"#0f0e0e",shade40:"#1c1b1a",shade30:"#343231",shade20:"#474443",shade10:"#54514f",primary:"#5d5a58",tint10:"#706d6b",tint20:"#84817e",tint30:"#9e9b99",tint40:"#cecccb",tint50:"#e5e4e3",tint60:"#f8f8f8"},platinum:{shade50:"#111314",shade40:"#1f2426",shade30:"#3b4447",shade20:"#505c60",shade10:"#5f6d71",primary:"#69797e",tint10:"#79898d",tint20:"#89989d",tint30:"#a0adb2",tint40:"#cdd6d8",tint50:"#e4e9ea",tint60:"#f8f9fa"},anchor:{shade50:"#090a0b",shade40:"#111315",shade30:"#202427",shade20:"#2b3135",shade10:"#333a3f",primary:"#394146",tint10:"#4d565c",tint20:"#626c72",tint30:"#808a90",tint40:"#bcc3c7",tint50:"#dbdfe1",tint60:"#f6f7f8"}},$={cranberry:B,green:F,orange:{shade50:"#271002",shade40:"#4a1e04",shade30:"#8a3707",shade20:"#bc4b09",shade10:"#de590b",primary:"#f7630c",tint10:"#f87528",tint20:"#f98845",tint30:"#faa06b",tint40:"#fdcfb4",tint50:"#fee5d7",tint60:"#fff9f5"}},Z=["red","green","darkOrange","yellow","berry","lightGreen","marigold"],V=["darkRed","cranberry","pumpkin","peach","gold","brass","brown","forest","seafoam","darkGreen","lightTeal","teal","steel","blue","royalBlue","cornflower","navy","lavender","purple","grape","lilac","pink","magenta","plum","beige","mink","platinum","anchor"],G={success:"green",warning:"orange",danger:"cranberry"},j=Z.reduce(((e,t)=>{const i=t.slice(0,1).toUpperCase()+t.slice(1),n={[`colorPalette${i}Background1`]:U[t].tint60,[`colorPalette${i}Background2`]:U[t].tint40,[`colorPalette${i}Background3`]:U[t].primary,[`colorPalette${i}Foreground1`]:U[t].shade10,[`colorPalette${i}Foreground2`]:U[t].shade30,[`colorPalette${i}Foreground3`]:U[t].primary,[`colorPalette${i}BorderActive`]:U[t].primary,[`colorPalette${i}Border1`]:U[t].tint40,[`colorPalette${i}Border2`]:U[t].primary};return Object.assign(e,n)}),{});j.colorPaletteYellowForeground1=U.yellow.shade30,j.colorPaletteRedForegroundInverted=U.red.tint20,j.colorPaletteGreenForegroundInverted=U.green.tint20,j.colorPaletteYellowForegroundInverted=U.yellow.tint40;const z=V.reduce(((e,t)=>{const i=t.slice(0,1).toUpperCase()+t.slice(1),n={[`colorPalette${i}Background2`]:H[t].tint40,[`colorPalette${i}Foreground2`]:H[t].shade30,[`colorPalette${i}BorderActive`]:H[t].primary};return Object.assign(e,n)}),{}),W={...j,...z},K=Object.entries(G).reduce(((e,[t,i])=>{const n=t.slice(0,1).toUpperCase()+t.slice(1),o={[`colorStatus${n}Background1`]:$[i].tint60,[`colorStatus${n}Background2`]:$[i].tint40,[`colorStatus${n}Background3`]:$[i].primary,[`colorStatus${n}Foreground1`]:$[i].shade10,[`colorStatus${n}Foreground2`]:$[i].shade30,[`colorStatus${n}Foreground3`]:$[i].primary,[`colorStatus${n}ForegroundInverted`]:$[i].tint30,[`colorStatus${n}BorderActive`]:$[i].primary,[`colorStatus${n}Border1`]:$[i].tint40,[`colorStatus${n}Border2`]:$[i].primary};return Object.assign(e,o)}),{});K.colorStatusWarningForeground1=$[G.warning].shade20,K.colorStatusWarningForeground3=$[G.warning].shade20,K.colorStatusWarningBorder2=$[G.warning].shade20;const q={borderRadiusNone:"0",borderRadiusSmall:"2px",borderRadiusMedium:"4px",borderRadiusLarge:"6px",borderRadiusXLarge:"8px",borderRadiusCircular:"10000px"},Y={fontSizeBase100:"10px",fontSizeBase200:"12px",fontSizeBase300:"14px",fontSizeBase400:"16px",fontSizeBase500:"20px",fontSizeBase600:"24px",fontSizeHero700:"28px",fontSizeHero800:"32px",fontSizeHero900:"40px",fontSizeHero1000:"68px"},X={lineHeightBase100:"14px",lineHeightBase200:"16px",lineHeightBase300:"20px",lineHeightBase400:"22px",lineHeightBase500:"28px",lineHeightBase600:"32px",lineHeightHero700:"36px",lineHeightHero800:"40px",lineHeightHero900:"52px",lineHeightHero1000:"92px"},J={fontWeightRegular:400,fontWeightMedium:500,fontWeightSemibold:600,fontWeightBold:700},Q={fontFamilyBase:"'Segoe UI', 'Segoe UI Web (West European)', -apple-system, BlinkMacSystemFont, Roboto, 'Helvetica Neue', sans-serif",fontFamilyMonospace:"Consolas, 'Courier New', Courier, monospace",fontFamilyNumeric:"Bahnschrift, 'Segoe UI', 'Segoe UI Web (West European)', -apple-system, BlinkMacSystemFont, Roboto, 'Helvetica Neue', sans-serif"},ee={strokeWidthThin:"1px",strokeWidthThick:"2px",strokeWidthThicker:"3px",strokeWidthThickest:"4px"};function te(e,t,i=""){return{[`shadow2${i}`]:`0 0 2px ${e}, 0 1px 2px ${t}`,[`shadow4${i}`]:`0 0 2px ${e}, 0 2px 4px ${t}`,[`shadow8${i}`]:`0 0 2px ${e}, 0 4px 8px ${t}`,[`shadow16${i}`]:`0 0 2px ${e}, 0 8px 16px ${t}`,[`shadow28${i}`]:`0 0 8px ${e}, 0 14px 28px ${t}`,[`shadow64${i}`]:`0 0 8px ${e}, 0 32px 64px ${t}`}}const ie={durationUltraFast:"50ms",durationFaster:"100ms",durationFast:"150ms",durationNormal:"200ms",durationGentle:"250ms",durationSlow:"300ms",durationSlower:"400ms",durationUltraSlow:"500ms"},ne={curveAccelerateMax:"cubic-bezier(1,0,1,1)",curveAccelerateMid:"cubic-bezier(0.7,0,1,0.5)",curveAccelerateMin:"cubic-bezier(0.8,0,1,1)",curveDecelerateMax:"cubic-bezier(0,0,0,1)",curveDecelerateMid:"cubic-bezier(0.1,0.9,0.2,1)",curveDecelerateMin:"cubic-bezier(0.33,0,0.1,1)",curveEasyEaseMax:"cubic-bezier(0.8,0,0.1,1)",curveEasyEase:"cubic-bezier(0.33,0,0.67,1)",curveLinear:"cubic-bezier(0,0,1,1)"},oe="10px",re="12px",ae="16px",se="20px",le="24px",ce="32px",de={spacingHorizontalNone:"0",spacingHorizontalXXS:"2px",spacingHorizontalXS:"4px",spacingHorizontalSNudge:"6px",spacingHorizontalS:"8px",spacingHorizontalMNudge:oe,spacingHorizontalM:re,spacingHorizontalL:ae,spacingHorizontalXL:se,spacingHorizontalXXL:le,spacingHorizontalXXXL:ce},ue={spacingVerticalNone:"0",spacingVerticalXXS:"2px",spacingVerticalXS:"4px",spacingVerticalSNudge:"6px",spacingVerticalS:"8px",spacingVerticalMNudge:oe,spacingVerticalM:re,spacingVerticalL:ae,spacingVerticalXL:se,spacingVerticalXXL:le,spacingVerticalXXXL:ce},he=e=>{const t=(e=>({colorNeutralForeground1:a,colorNeutralForeground1Hover:a,colorNeutralForeground1Pressed:a,colorNeutralForeground1Selected:a,colorNeutralForeground2:h,colorNeutralForeground2Hover:a,colorNeutralForeground2Pressed:a,colorNeutralForeground2Selected:a,colorNeutralForeground2BrandHover:e[80],colorNeutralForeground2BrandPressed:e[70],colorNeutralForeground2BrandSelected:e[80],colorNeutralForeground3:g,colorNeutralForeground3Hover:h,colorNeutralForeground3Pressed:h,colorNeutralForeground3Selected:h,colorNeutralForeground3BrandHover:e[80],colorNeutralForeground3BrandPressed:e[70],colorNeutralForeground3BrandSelected:e[80],colorNeutralForeground4:f,colorNeutralForegroundDisabled:y,colorNeutralForegroundInvertedDisabled:E,colorBrandForegroundLink:e[70],colorBrandForegroundLinkHover:e[60],colorBrandForegroundLinkPressed:e[40],colorBrandForegroundLinkSelected:e[70],colorNeutralForeground2Link:h,colorNeutralForeground2LinkHover:a,colorNeutralForeground2LinkPressed:a,colorNeutralForeground2LinkSelected:a,colorCompoundBrandForeground1:e[80],colorCompoundBrandForeground1Hover:e[70],colorCompoundBrandForeground1Pressed:e[60],colorBrandForeground1:e[80],colorBrandForeground2:e[70],colorBrandForeground2Hover:e[60],colorBrandForeground2Pressed:e[30],colorNeutralForeground1Static:a,colorNeutralForegroundStaticInverted:M,colorNeutralForegroundInverted:M,colorNeutralForegroundInvertedHover:M,colorNeutralForegroundInvertedPressed:M,colorNeutralForegroundInvertedSelected:M,colorNeutralForegroundInverted2:M,colorNeutralForegroundOnBrand:M,colorNeutralForegroundInvertedLink:M,colorNeutralForegroundInvertedLinkHover:M,colorNeutralForegroundInvertedLinkPressed:M,colorNeutralForegroundInvertedLinkSelected:M,colorBrandForegroundInverted:e[100],colorBrandForegroundInvertedHover:e[110],colorBrandForegroundInvertedPressed:e[100],colorBrandForegroundOnLight:e[80],colorBrandForegroundOnLightHover:e[70],colorBrandForegroundOnLightPressed:e[50],colorBrandForegroundOnLightSelected:e[60],colorNeutralBackground1:M,colorNeutralBackground1Hover:w,colorNeutralBackground1Pressed:b,colorNeutralBackground1Selected:x,colorNeutralBackground2:O,colorNeutralBackground2Hover:T,colorNeutralBackground2Pressed:"#dbdbdb",colorNeutralBackground2Selected:S,colorNeutralBackground3:w,colorNeutralBackground3Hover:x,colorNeutralBackground3Pressed:C,colorNeutralBackground3Selected:b,colorNeutralBackground4:T,colorNeutralBackground4Hover:O,colorNeutralBackground4Pressed:w,colorNeutralBackground4Selected:M,colorNeutralBackground5:x,colorNeutralBackground5Hover:w,colorNeutralBackground5Pressed:T,colorNeutralBackground5Selected:O,colorNeutralBackground6:S,colorNeutralBackgroundInverted:s,colorNeutralBackgroundStatic:c,colorNeutralBackgroundAlpha:k,colorNeutralBackgroundAlpha2:"rgba(255, 255, 255, 0.8)",colorSubtleBackground:"transparent",colorSubtleBackgroundHover:w,colorSubtleBackgroundPressed:b,colorSubtleBackgroundSelected:x,colorSubtleBackgroundLightAlphaHover:"rgba(255, 255, 255, 0.7)",colorSubtleBackgroundLightAlphaPressed:k,colorSubtleBackgroundLightAlphaSelected:"transparent",colorSubtleBackgroundInverted:"transparent",colorSubtleBackgroundInvertedHover:D,colorSubtleBackgroundInvertedPressed:N,colorSubtleBackgroundInvertedSelected:_,colorTransparentBackground:"transparent",colorTransparentBackgroundHover:"transparent",colorTransparentBackgroundPressed:"transparent",colorTransparentBackgroundSelected:"transparent",colorNeutralBackgroundDisabled:T,colorNeutralBackgroundInvertedDisabled:P,colorNeutralStencil1:S,colorNeutralStencil2:O,colorNeutralStencil1Alpha:D,colorNeutralStencil2Alpha:I,colorBackgroundOverlay:"rgba(0, 0, 0, 0.4)",colorScrollbarOverlay:R,colorBrandBackground:e[80],colorBrandBackgroundHover:e[70],colorBrandBackgroundPressed:e[40],colorBrandBackgroundSelected:e[60],colorCompoundBrandBackground:e[80],colorCompoundBrandBackgroundHover:e[70],colorCompoundBrandBackgroundPressed:e[60],colorBrandBackgroundStatic:e[80],colorBrandBackground2:e[160],colorBrandBackground2Hover:e[150],colorBrandBackground2Pressed:e[130],colorBrandBackgroundInverted:M,colorBrandBackgroundInvertedHover:e[160],colorBrandBackgroundInvertedPressed:e[140],colorBrandBackgroundInvertedSelected:e[150],colorNeutralStrokeAccessible:g,colorNeutralStrokeAccessibleHover:p,colorNeutralStrokeAccessiblePressed:"#4d4d4d",colorNeutralStrokeAccessibleSelected:e[80],colorNeutralStroke1:"#d1d1d1",colorNeutralStroke1Hover:"#c7c7c7",colorNeutralStroke1Pressed:v,colorNeutralStroke1Selected:y,colorNeutralStroke2:b,colorNeutralStroke3:T,colorNeutralStrokeSubtle:b,colorNeutralStrokeOnBrand:M,colorNeutralStrokeOnBrand2:M,colorNeutralStrokeOnBrand2Hover:M,colorNeutralStrokeOnBrand2Pressed:M,colorNeutralStrokeOnBrand2Selected:M,colorBrandStroke1:e[80],colorBrandStroke2:e[140],colorBrandStroke2Hover:e[120],colorBrandStroke2Pressed:e[80],colorBrandStroke2Contrast:e[140],colorCompoundBrandStroke:e[80],colorCompoundBrandStrokeHover:e[70],colorCompoundBrandStrokePressed:e[60],colorNeutralStrokeDisabled:b,colorNeutralStrokeInvertedDisabled:E,colorTransparentStroke:"transparent",colorTransparentStrokeInteractive:"transparent",colorTransparentStrokeDisabled:"transparent",colorNeutralStrokeAlpha:I,colorNeutralStrokeAlpha2:A,colorStrokeFocus1:M,colorStrokeFocus2:L,colorNeutralShadowAmbient:"rgba(0,0,0,0.12)",colorNeutralShadowKey:"rgba(0,0,0,0.14)",colorNeutralShadowAmbientLighter:"rgba(0,0,0,0.06)",colorNeutralShadowKeyLighter:"rgba(0,0,0,0.07)",colorNeutralShadowAmbientDarker:"rgba(0,0,0,0.20)",colorNeutralShadowKeyDarker:"rgba(0,0,0,0.24)",colorBrandShadowAmbient:"rgba(0,0,0,0.30)",colorBrandShadowKey:"rgba(0,0,0,0.25)"}))(e);return{...q,...Y,...X,...Q,...J,...ee,...de,...ue,...ie,...ne,...t,...W,...K,...te(t.colorNeutralShadowAmbient,t.colorNeutralShadowKey),...te(t.colorBrandShadowAmbient,t.colorBrandShadowKey,"Brand")}},pe={10:"#061724",20:"#082338",30:"#0a2e4a",40:"#0c3b5e",50:"#0e4775",60:"#0f548c",70:"#115ea3",80:"#0f6cbd",90:"#2886de",100:"#479ef5",110:"#62abf5",120:"#77b7f7",130:"#96c6fa",140:"#b4d6fa",150:"#cfe4fa",160:"#ebf3fc"},ge=he(pe),fe=Z.reduce(((e,t)=>{const i=t.slice(0,1).toUpperCase()+t.slice(1),n={[`colorPalette${i}Background1`]:U[t].shade40,[`colorPalette${i}Background2`]:U[t].shade30,[`colorPalette${i}Background3`]:U[t].primary,[`colorPalette${i}Foreground1`]:U[t].tint30,[`colorPalette${i}Foreground2`]:U[t].tint40,[`colorPalette${i}Foreground3`]:U[t].tint20,[`colorPalette${i}BorderActive`]:U[t].tint30,[`colorPalette${i}Border1`]:U[t].primary,[`colorPalette${i}Border2`]:U[t].tint20};return Object.assign(e,n)}),{});fe.colorPaletteRedForeground3=U.red.tint30,fe.colorPaletteRedBorder2=U.red.tint30,fe.colorPaletteGreenForeground3=U.green.tint40,fe.colorPaletteGreenBorder2=U.green.tint40,fe.colorPaletteDarkOrangeForeground3=U.darkOrange.tint30,fe.colorPaletteDarkOrangeBorder2=U.darkOrange.tint30,fe.colorPaletteRedForegroundInverted=U.red.primary,fe.colorPaletteGreenForegroundInverted=U.green.primary,fe.colorPaletteYellowForegroundInverted=U.yellow.shade30;const me=V.reduce(((e,t)=>{const i=t.slice(0,1).toUpperCase()+t.slice(1),n={[`colorPalette${i}Background2`]:H[t].shade30,[`colorPalette${i}Foreground2`]:H[t].tint40,[`colorPalette${i}BorderActive`]:H[t].tint30};return Object.assign(e,n)}),{});me.colorPaletteDarkRedBackground2=H.darkRed.shade20,me.colorPalettePlumBackground2=H.plum.shade20;const ve={...fe,...me},ye=Object.entries(G).reduce(((e,[t,i])=>{const n=t.slice(0,1).toUpperCase()+t.slice(1),o={[`colorStatus${n}Background1`]:$[i].shade40,[`colorStatus${n}Background2`]:$[i].shade30,[`colorStatus${n}Background3`]:$[i].primary,[`colorStatus${n}Foreground1`]:$[i].tint30,[`colorStatus${n}Foreground2`]:$[i].tint40,[`colorStatus${n}Foreground3`]:$[i].tint20,[`colorStatus${n}BorderActive`]:$[i].tint30,[`colorStatus${n}ForegroundInverted`]:$[i].shade10,[`colorStatus${n}Border1`]:$[i].primary,[`colorStatus${n}Border2`]:$[i].tint20};return Object.assign(e,o)}),{});ye.colorStatusDangerForeground3=$[G.danger].tint30,ye.colorStatusDangerBorder2=$[G.danger].tint30,ye.colorStatusSuccessForeground3=$[G.success].tint40,ye.colorStatusSuccessBorder2=$[G.success].tint40,ye.colorStatusWarningForegroundInverted=$[G.warning].shade20;const Ce=e=>{const t=(e=>({colorNeutralForeground1:M,colorNeutralForeground1Hover:M,colorNeutralForeground1Pressed:M,colorNeutralForeground1Selected:M,colorNeutralForeground2:C,colorNeutralForeground2Hover:M,colorNeutralForeground2Pressed:M,colorNeutralForeground2Selected:M,colorNeutralForeground2BrandHover:e[100],colorNeutralForeground2BrandPressed:e[90],colorNeutralForeground2BrandSelected:e[100],colorNeutralForeground3:m,colorNeutralForeground3Hover:C,colorNeutralForeground3Pressed:C,colorNeutralForeground3Selected:C,colorNeutralForeground3BrandHover:e[100],colorNeutralForeground3BrandPressed:e[90],colorNeutralForeground3BrandSelected:e[100],colorNeutralForeground4:"#999999",colorNeutralForegroundDisabled:"#5c5c5c",colorNeutralForegroundInvertedDisabled:E,colorBrandForegroundLink:e[100],colorBrandForegroundLinkHover:e[110],colorBrandForegroundLinkPressed:e[90],colorBrandForegroundLinkSelected:e[100],colorNeutralForeground2Link:C,colorNeutralForeground2LinkHover:M,colorNeutralForeground2LinkPressed:M,colorNeutralForeground2LinkSelected:M,colorCompoundBrandForeground1:e[100],colorCompoundBrandForeground1Hover:e[110],colorCompoundBrandForeground1Pressed:e[90],colorBrandForeground1:e[100],colorBrandForeground2:e[110],colorBrandForeground2Hover:e[130],colorBrandForeground2Pressed:e[160],colorNeutralForeground1Static:a,colorNeutralForegroundStaticInverted:M,colorNeutralForegroundInverted:a,colorNeutralForegroundInvertedHover:a,colorNeutralForegroundInvertedPressed:a,colorNeutralForegroundInvertedSelected:a,colorNeutralForegroundInverted2:a,colorNeutralForegroundOnBrand:M,colorNeutralForegroundInvertedLink:M,colorNeutralForegroundInvertedLinkHover:M,colorNeutralForegroundInvertedLinkPressed:M,colorNeutralForegroundInvertedLinkSelected:M,colorBrandForegroundInverted:e[80],colorBrandForegroundInvertedHover:e[70],colorBrandForegroundInvertedPressed:e[60],colorBrandForegroundOnLight:e[80],colorBrandForegroundOnLightHover:e[70],colorBrandForegroundOnLightPressed:e[50],colorBrandForegroundOnLightSelected:e[60],colorNeutralBackground1:s,colorNeutralBackground1Hover:u,colorNeutralBackground1Pressed:r,colorNeutralBackground1Selected:d,colorNeutralBackground2:r,colorNeutralBackground2Hover:c,colorNeutralBackground2Pressed:o,colorNeutralBackground2Selected:l,colorNeutralBackground3:o,colorNeutralBackground3Hover:s,colorNeutralBackground3Pressed:n,colorNeutralBackground3Selected:a,colorNeutralBackground4:n,colorNeutralBackground4Hover:r,colorNeutralBackground4Pressed:L,colorNeutralBackground4Selected:"#1a1a1a",colorNeutralBackground5:L,colorNeutralBackground5Hover:o,colorNeutralBackground5Pressed:"#050505",colorNeutralBackground5Selected:"#0f0f0f",colorNeutralBackground6:c,colorNeutralBackgroundInverted:M,colorNeutralBackgroundStatic:u,colorNeutralBackgroundAlpha:"rgba(26, 26, 26, 0.5)",colorNeutralBackgroundAlpha2:"rgba(31, 31, 31, 0.7)",colorSubtleBackground:"transparent",colorSubtleBackgroundHover:d,colorSubtleBackgroundPressed:l,colorSubtleBackgroundSelected:c,colorSubtleBackgroundLightAlphaHover:"rgba(36, 36, 36, 0.8)",colorSubtleBackgroundLightAlphaPressed:"rgba(36, 36, 36, 0.5)",colorSubtleBackgroundLightAlphaSelected:"transparent",colorSubtleBackgroundInverted:"transparent",colorSubtleBackgroundInvertedHover:D,colorSubtleBackgroundInvertedPressed:N,colorSubtleBackgroundInvertedSelected:_,colorTransparentBackground:"transparent",colorTransparentBackgroundHover:"transparent",colorTransparentBackgroundPressed:"transparent",colorTransparentBackgroundSelected:"transparent",colorNeutralBackgroundDisabled:o,colorNeutralBackgroundInvertedDisabled:P,colorNeutralStencil1:p,colorNeutralStencil2:c,colorNeutralStencil1Alpha:P,colorNeutralStencil2Alpha:"rgba(255, 255, 255, 0.05)",colorBackgroundOverlay:R,colorScrollbarOverlay:"rgba(255, 255, 255, 0.6)",colorBrandBackground:e[70],colorBrandBackgroundHover:e[80],colorBrandBackgroundPressed:e[40],colorBrandBackgroundSelected:e[60],colorCompoundBrandBackground:e[100],colorCompoundBrandBackgroundHover:e[110],colorCompoundBrandBackgroundPressed:e[90],colorBrandBackgroundStatic:e[80],colorBrandBackground2:e[20],colorBrandBackground2Hover:e[40],colorBrandBackground2Pressed:e[10],colorBrandBackgroundInverted:M,colorBrandBackgroundInvertedHover:e[160],colorBrandBackgroundInvertedPressed:e[140],colorBrandBackgroundInvertedSelected:e[150],colorNeutralStrokeAccessible:m,colorNeutralStrokeAccessibleHover:y,colorNeutralStrokeAccessiblePressed:v,colorNeutralStrokeAccessibleSelected:e[100],colorNeutralStroke1:"#666666",colorNeutralStroke1Hover:"#757575",colorNeutralStroke1Pressed:"#6b6b6b",colorNeutralStroke1Selected:f,colorNeutralStroke2:"#525252",colorNeutralStroke3:u,colorNeutralStrokeSubtle:n,colorNeutralStrokeOnBrand:s,colorNeutralStrokeOnBrand2:M,colorNeutralStrokeOnBrand2Hover:M,colorNeutralStrokeOnBrand2Pressed:M,colorNeutralStrokeOnBrand2Selected:M,colorBrandStroke1:e[100],colorBrandStroke2:e[50],colorBrandStroke2Hover:e[50],colorBrandStroke2Pressed:e[30],colorBrandStroke2Contrast:e[50],colorCompoundBrandStroke:e[100],colorCompoundBrandStrokeHover:e[110],colorCompoundBrandStrokePressed:e[90],colorNeutralStrokeDisabled:h,colorNeutralStrokeInvertedDisabled:E,colorTransparentStroke:"transparent",colorTransparentStrokeInteractive:"transparent",colorTransparentStrokeDisabled:"transparent",colorNeutralStrokeAlpha:P,colorNeutralStrokeAlpha2:A,colorStrokeFocus1:L,colorStrokeFocus2:M,colorNeutralShadowAmbient:"rgba(0,0,0,0.24)",colorNeutralShadowKey:"rgba(0,0,0,0.28)",colorNeutralShadowAmbientLighter:"rgba(0,0,0,0.12)",colorNeutralShadowKeyLighter:"rgba(0,0,0,0.14)",colorNeutralShadowAmbientDarker:"rgba(0,0,0,0.40)",colorNeutralShadowKeyDarker:"rgba(0,0,0,0.48)",colorBrandShadowAmbient:"rgba(0,0,0,0.30)",colorBrandShadowKey:"rgba(0,0,0,0.25)"}))(e);return{...q,...Y,...X,...Q,...J,...ee,...de,...ue,...ie,...ne,...t,...ve,...ye,...te(t.colorNeutralShadowAmbient,t.colorNeutralShadowKey),...te(t.colorBrandShadowAmbient,t.colorBrandShadowKey,"Brand")}},be=Ce(pe);var Se=i(84045),xe=i(61492),Te=i(52961),we=i(44956),Oe=i(45101);function Pe(e){return Pe="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Pe(e)}function Ae(e,t,i){return(t=function(e){var t=function(e,t){if("object"!==Pe(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==Pe(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Pe(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function Ee(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function ke(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Ee(Object(i),!0).forEach((function(t){Ae(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Ee(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var Ie={10:"#151B29",20:"#1A2338",30:"#202E4F",40:"#243966",50:"#264587",60:"#2551A8",70:"#235CCF",80:"#2169EB",90:"#3275F0",100:"#4082F5",110:"#4D8DFA",120:"#69A1FA",130:"#86B3FC",140:"#A7C9FC",150:"#C4DCFF",160:"#E0EDFF"},De={},_e={colorPaletteRedForeground1:"#D63600",colorPaletteGreenForeground1:"#138757",colorBrandForegroundInverted:Ie[110],colorBrandForegroundInvertedHover:Ie[120],colorBrandForegroundInvertedPressed:Ie[130],colorPaletteYellowForeground1:"#F5C32F",colorNeutralStencil1:"#E6E6E6"},Ne={colorPaletteRedForeground1:"#F76A3B",colorPaletteGreenForeground1:"#44D498",colorCompoundBrandBackground:Ie[110],colorCompoundBrandBackgroundHover:Ie[120],colorCompoundBrandBackgroundPressed:Ie[130],colorBrandForeground1:Ie[110],colorBrandForeground2:Ie[120],colorBrandForegroundLink:Ie[110],colorBrandForegroundLinkHover:Ie[120],colorBrandForegroundLinkPressed:Ie[130],colorBrandForegroundLinkSelected:Ie[110],colorCompoundBrandForeground1:Ie[110],colorCompoundBrandForeground1Hover:Ie[120],colorCompoundBrandForeground1Pressed:Ie[130],colorBrandStroke1:Ie[110],colorCompoundBrandStroke:Ie[110],colorCompoundBrandStrokeHover:Ie[120],colorCompoundBrandStrokePressed:Ie[130],colorPaletteYellowForeground1:"#F5C32F",colorNeutralStencil1:"#999999"},Re={light:ke(ke(ke(ke({},ge),he(Ie)),De),_e),dark:ke(ke(ke(ke({},be),Ce(Ie)),De),Ne),colorRamp:Ie},Me={fontFamilyBase:"Roboto, Helvetica Neue, Helvetica, Arial, sans-serif",fontFamilyMonospace:"Roboto Mono, Consolas, Menlo, Monaco, Lucida Console, monospace",fontFamilyNumeric:"Roboto, Helvetica Neue, Helvetica, Arial, sans-serif"},Le={light:ke(ke({},Re.light),Me),dark:ke(ke({},Re.dark),Me),colorRamp:Re.colorRamp},Be=(0,Se.Z)({priceAccentSecondary:{color:xe.T.colorPaletteRedForeground1},priceAccentPrimary:{color:xe.T.colorPaletteGreenForeground1},priceNormal:{color:xe.T.colorNeutralForeground1},priceSubtle:{color:xe.T.colorNeutralForeground4},priceInverted:{color:xe.T.colorNeutralForegroundStaticInverted}}),Fe=(0,Se.Z)({shoppingPanelVertical:{display:"flex",flexDirection:"column",rowGap:xe.T.spacingHorizontalXL,paddingTop:xe.T.spacingHorizontalL,paddingBottom:xe.T.spacingHorizontalL},surfacePanelVertical:{display:"flex",flexDirection:"column",paddingTop:xe.T.spacingVerticalL,paddingBottom:xe.T.spacingVerticalL,paddingLeft:xe.T.spacingHorizontalL,paddingRight:xe.T.spacingHorizontalL,rowGap:xe.T.spacingHorizontalXL}});function Ue(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function He(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Ue(Object(i),!0).forEach((function(t){Ae(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Ue(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var $e=(0,Se.Z)({surfacePanel:He(He(He(He({backgroundColor:xe.T.colorNeutralBackground1},Te.q5.borderRadius(xe.T.borderRadiusXLarge)),Te.q5.border(xe.T.strokeWidthThin,xe.T.colorStrokeFocus1)),Te.q5.padding(xe.T.spacingHorizontalL)),{},{boxShadow:xe.T.shadow4})}),Ze=(0,Se.Z)({});function Ve(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Ge(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Ve(Object(i),!0).forEach((function(t){Ae(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Ve(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var je=(0,Se.Z)({priceChangeSmall:Ge({},we.w.caption1),priceChangeMedium:Ge({},we.w.body1),priceChangeLarge:Ge({},we.w.subtitle2)})},8052:function(e,t,i){"use strict";function n(e){for(var t,i=0,n=0,o=e.length;o>=4;++n,o-=4)t=1540483477*(65535&(t=255&e.charCodeAt(n)|(255&e.charCodeAt(++n))<<8|(255&e.charCodeAt(++n))<<16|(255&e.charCodeAt(++n))<<24))+(59797*(t>>>16)<<16),i=1540483477*(65535&(t^=t>>>24))+(59797*(t>>>16)<<16)^1540483477*(65535&i)+(59797*(i>>>16)<<16);switch(o){case 3:i^=(255&e.charCodeAt(n+2))<<16;case 2:i^=(255&e.charCodeAt(n+1))<<8;case 1:i=1540483477*(65535&(i^=255&e.charCodeAt(n)))+(59797*(i>>>16)<<16)}return(((i=1540483477*(65535&(i^=i>>>13))+(59797*(i>>>16)<<16))^i>>>15)>>>0).toString(36)}i.d(t,{Z:function(){return n}})},34325:function(e,t,i){"use strict";i.d(t,{Ce2:function(){return n},L1R:function(){return r},TaI:function(){return o}});const n="Enter",o=" ",r="Escape"},89832:function(e,t,i){"use strict";i.d(t,{Q:function(){return r}});var n=i(34325),o=i(32384);function r(e,t){const{disabled:i,disabledFocusable:r=!1,"aria-disabled":a,onClick:s,onKeyDown:l,onKeyUp:c,...d}=null!=t?t:{},u="string"==typeof a?"true"===a:a,h=i||r||u,p=(0,o.$)((e=>{h?(e.preventDefault(),e.stopPropagation()):null==s||s(e)})),g=(0,o.$)((e=>{if(null==l||l(e),e.isDefaultPrevented())return;const t=e.key;if(h&&(t===n.Ce2||t===n.TaI))return e.preventDefault(),void e.stopPropagation();t!==n.TaI?t===n.Ce2&&(e.preventDefault(),e.currentTarget.click()):e.preventDefault()})),f=(0,o.$)((e=>{if(null==c||c(e),e.isDefaultPrevented())return;const t=e.key;if(h&&(t===n.Ce2||t===n.TaI))return e.preventDefault(),void e.stopPropagation();t===n.TaI&&(e.preventDefault(),e.currentTarget.click())}));if("button"===e||void 0===e)return{...d,disabled:i&&!r,"aria-disabled":!!r||u,onClick:r?void 0:p,onKeyUp:r?void 0:c,onKeyDown:r?void 0:l};{const t={role:"button",tabIndex:i&&!r?void 0:0,...d,onClick:p,onKeyUp:f,onKeyDown:g,"aria-disabled":i||r||u};return"a"===e&&h&&(t.href=void 0),t}}i(8559)},1598:function(e,t,i){"use strict";i.d(t,{_:function(){return a},a:function(){return s}});var n=i(8559);const o=n.createContext(void 0),r={},a=o.Provider,s=()=>n.useContext(o)?n.useContext(o):r},64821:function(e,t,i){"use strict";i.d(t,{tZ:function(){return u},BX:function(){return h}});var n=i(35190);function o(e){return Boolean(null==e?void 0:e.hasOwnProperty(n.v))}var r=i(8559),a=i(81764);function s(e,t){return function(i,r,s,l,c){return o(r)?t(function(e,t){return{...t,[n.v]:e}}(i,r),null,s,l,c):o(i)?t(i,r,s,l,c):(function(e){"object"==typeof e&&(0,a.isValidElementType)(e)}(i),e(i,r,s,l,c))}}function l(e){const{as:t,[n.v]:i,[n.A]:o,...r}=e,a=r,s="string"==typeof i&&null!=t?t:i;return"string"!=typeof s&&t&&(a.as=t),{elementType:s,props:a,renderFunction:o}}var c=i(82369);const d=i.t(c,2),u=s(d.jsx,((e,t,i)=>{const{elementType:n,renderFunction:o,props:a}=l(e),s={...a,...t};return o?d.jsx(r.Fragment,{children:o(n,s)},i):d.jsx(n,s,i)})),h=s(d.jsxs,((e,t,i)=>{const{elementType:n,renderFunction:o,props:a}=l(e),s={...a,...t};return o?d.jsx(r.Fragment,{children:o(n,{...s,children:d.jsxs(r.Fragment,{children:s.children},void 0)})},i):d.jsxs(n,s,i)}))},5889:function(e,t){"use strict";var i=60107,n=60108,o=60114,r=60109,a=60110,s=60112,l=60113,c=60120,d=60115,u=60116,h=60121,p=60122,g=60117,f=60129,m=60131;if("function"==typeof Symbol&&Symbol.for){var v=Symbol.for;v("react.element"),v("react.portal"),i=v("react.fragment"),n=v("react.strict_mode"),o=v("react.profiler"),r=v("react.provider"),a=v("react.context"),s=v("react.forward_ref"),l=v("react.suspense"),c=v("react.suspense_list"),d=v("react.memo"),u=v("react.lazy"),h=v("react.block"),p=v("react.server.block"),g=v("react.fundamental"),f=v("react.debug_trace_mode"),m=v("react.legacy_hidden")}t.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===i||e===o||e===f||e===n||e===l||e===c||e===m||"object"==typeof e&&null!==e&&(e.$$typeof===u||e.$$typeof===d||e.$$typeof===r||e.$$typeof===a||e.$$typeof===s||e.$$typeof===g||e.$$typeof===h||e[0]===p)}},81764:function(e,t,i){"use strict";e.exports=i(5889)},77688:function(e,t,i){"use strict";i.d(t,{h:function(){return m}});var n=i(8559),o=i.t(n,2),r=i(96568);function a(e,t){if(!e)return;const i=e;i._virtual||(i._virtual={}),i._virtual.parent=t}var s=i(10910);const l=n.createContext(void 0);l.Provider;var c=i(64143),d=i(74551),u=i(16049);const h=(0,i(94183).s)({root:{qhf8xq:"f1euv43f",Bhzewxz:"f15twtuk",oyh7mz:["f1vgc2s3","f1e31b4d"],j35jbq:["f1e31b4d","f1vgc2s3"],Bj3rh1h:"f494woh"}},{d:[".f1euv43f{position:absolute;}",".f15twtuk{top:0;}",".f1vgc2s3{left:0;}",".f1e31b4d{right:0;}",".f494woh{z-index:1000000;}"]}),p=o.useInsertionEffect,g=e=>{const{targetDocument:t,dir:i}=(0,s.O)(),o=n.useContext(l),r=(0,u._)(),a=h(),g=(0,c.H)(),f=(0,d.z)(g,a.root,e.className),m=null!=o?o:null==t?void 0:t.body,v=function(t,i){var o;const r=n.useMemo,a=n.useEffect,[s,l]=null!=(o=r((()=>(()=>{if(void 0===m||e.disabled)return[null,()=>null];const t=m.ownerDocument.createElement("div");return m.appendChild(t),[t,()=>t.remove()]})()),i))?o:[null,()=>null];return a((()=>l),i),s}(0,[m]);return p?p((()=>{if(!v)return;const e=f.split(" ").filter(Boolean);return v.classList.add(...e),v.setAttribute("dir",i),r.current=v,()=>{v.classList.remove(...e),v.removeAttribute("dir")}}),[f,i,v,r]):n.useMemo((()=>{v&&(v.className=f,v.setAttribute("dir",i),r.current=v)}),[f,i,v,r]),v};var f=i(43763);const m=e=>{return t=(e=>{const{element:t,className:i}=(o=e.mountNode,(0,r.R)(o)?{element:o}:"object"==typeof o?null===o?{element:null}:o:{});var o;const s=n.useRef(null),l=g({disabled:!!t,className:i}),c={children:e.children,mountNode:null!=t?t:l,virtualParentRootRef:s};return n.useEffect((()=>(c.virtualParentRootRef.current&&c.mountNode&&a(c.mountNode,c.virtualParentRootRef.current),()=>{c.mountNode&&a(c.mountNode,void 0)})),[c.virtualParentRootRef,c.mountNode]),c})(e),n.createElement("span",{hidden:!0,ref:t.virtualParentRootRef},t.mountNode&&f.createPortal(t.children,t.mountNode));var t};m.displayName="Portal"},3421:function(e,t,i){"use strict";i.d(t,{m:function(){return _}});var n=i(63853),o=i(10910),r=i(90100),a=i(32384),s=i(38283),l=i(8559);function c(e,t,i){const n=l.useRef(!0),[o]=l.useState((()=>({value:e,callback:t,facade:{get current(){return o.value},set current(e){const t=o.value;if(t!==e){if(o.value=e,i&&n.current)return;o.callback(e,t)}}}})));return(0,s.L)((()=>{n.current=!1}),[]),o.callback=t,o.facade}const d=e=>{switch(e){case"always":case!0:return{applyMaxWidth:!0,applyMaxHeight:!0};case"width-always":case"width":return{applyMaxWidth:!0,applyMaxHeight:!1};case"height-always":case"height":return{applyMaxWidth:!1,applyMaxHeight:!0};default:return!1}},u=e=>{const t=e&&(e=>"HTML"===e.nodeName?e:e.parentNode||e.host)(e);if(!t)return document.body;switch(t.nodeName){case"HTML":case"BODY":return t.ownerDocument.body;case"#document":return t.body}const{overflow:i,overflowX:n,overflowY:o}=(e=>{var t;return 1!==e.nodeType?{}:(null===(t=e.ownerDocument)||void 0===t?void 0:t.defaultView).getComputedStyle(e,null)})(t);return/(auto|scroll|overlay)/.test(i+o+n)?t:u(t)},h=e=>{var t;const i=u(e);return!!i&&i!==(null===(t=i.ownerDocument)||void 0===t?void 0:t.body)},p=(e,t,i)=>{const n=((e,t)=>{const i="above"===e||"below"===e,n="top"===t||"bottom"===t;return i&&n||!i&&!n})(t,e)?"center":e,o=t&&(e=>({above:"top",below:"bottom",before:e?"right":"left",after:e?"left":"right"}))(i)[t],r=n&&{start:"start",end:"end",top:"start",bottom:"end",center:void 0}[n];return o&&r?`${o}-${r}`:o};function g(e,t){if("window"===t)return null==e?void 0:e.ownerDocument.documentElement;if("clippingParents"===t)return"clippingAncestors";if("scrollParent"===t){let t=u(e);return"BODY"===t.nodeName&&(t=null==e?void 0:e.ownerDocument.documentElement),t}return t}const f=e=>({name:"resetMaxSize",fn({middlewareData:t,elements:i}){var n;if(null===(n=t.resetMaxSize)||void 0===n?void 0:n.maxSizeAlreadyReset)return{};const{applyMaxWidth:o,applyMaxHeight:r}=e;return o&&(i.floating.style.removeProperty("box-sizing"),i.floating.style.removeProperty("max-width"),i.floating.style.removeProperty("width")),r&&(i.floating.style.removeProperty("box-sizing"),i.floating.style.removeProperty("max-height"),i.floating.style.removeProperty("height")),{data:{maxSizeAlreadyReset:!0},reset:{rects:!0}}}});function m(e,t){const{container:i,overflowBoundary:o}=t;return(0,n.dp)({...o&&{altBoundary:!0,boundary:g(i,o)},apply({availableHeight:t,availableWidth:i,elements:n,rects:o}){const r=(e,t,i)=>{if(e&&(n.floating.style.setProperty("box-sizing","border-box"),n.floating.style.setProperty(`max-${t}`,`${i}px`),o.floating[t]>i)){n.floating.style.setProperty(t,`${i}px`);const e="width"===t?"x":"y";n.floating.style.getPropertyValue(`overflow-${e}`)||n.floating.style.setProperty(`overflow-${e}`,"auto")}},{applyMaxWidth:a,applyMaxHeight:s}=e;r(a,"width",i),r(s,"height",t)}})}function v(e){const t=e.split("-");return{side:t[0],alignment:t[1]}}const y=e=>{const{side:t,alignment:i}=v(e),n={top:"above",bottom:"below",right:"after",left:"before"}[t],o=i&&(e=>"above"===e||"below"===e?{start:"start",end:"end"}:{start:"top",end:"bottom"})(n)[i];return{position:n,alignment:o}};function C(e){const t=(i=e)?"number"==typeof i||"object"==typeof i?i:({rects:{floating:e,reference:t},placement:n})=>{const{position:o,alignment:r}=y(n);return i({positionedRect:e,targetRect:t,position:o,alignment:r})}:i;var i;return(0,n.cv)(t)}var b=i(12211);function S(e){const{hasScrollableElement:t,flipBoundary:i,container:o,fallbackPositions:r=[],isRtl:a}=e,s=r.reduce(((e,t)=>{const{position:i,align:n}=(0,b.j)(t),o=p(n,i,a);return o&&e.push(o),e}),[]);return(0,n.RR)({...t&&{boundary:"clippingAncestors"},...i&&{altBoundary:!0,boundary:g(o,i)},fallbackStrategy:"bestFit",...s.length&&{fallbackPlacements:s}})}function x(e,t){if("number"==typeof e)return e;const{start:i,end:n,...o}=e,r=o,a=t?"end":"start",s=t?"start":"end";return e[a]&&(r.left=e[a]),e[s]&&(r.right=e[s]),r}function T(e){const{hasScrollableElement:t,disableTether:i,overflowBoundary:o,container:r,overflowBoundaryPadding:a,isRtl:s}=e;return(0,n.uY)({...t&&{boundary:"clippingAncestors"},...i&&{crossAxis:"all"===i,limiter:(0,n.dr)({crossAxis:"all"!==i,mainAxis:!1})},...a&&{padding:x(a,s)},...o&&{altBoundary:!0,boundary:g(r,o)}})}var w=i(22256);const O="data-popper-is-intersecting",P="data-popper-escaped",A="data-popper-reference-hidden",E="data-popper-placement";var k=i(96568);function I(e){const t=[];let i=e;for(;i;){const n=u(i);if(e.ownerDocument.body===n){t.push(n);break}t.push(n),i=n}return t}function D(e){const{container:t,target:i,arrow:n,strategy:o,middleware:r,placement:a,useTransform:s=!0}=e;let l=!1;if(!i||!t)return{updatePosition:()=>{},dispose:()=>{}};let c=!0;const d=new Set,u=t.ownerDocument.defaultView;Object.assign(t.style,{position:"fixed",left:0,top:0,margin:0});const h=function(e){let p;return()=>(p||(p=new Promise((e=>{Promise.resolve().then((()=>{p=void 0,e(void(l||(c&&(I(t).forEach((e=>d.add(e))),(0,k.R)(i)&&I(i).forEach((e=>d.add(e))),d.forEach((e=>{e.addEventListener("scroll",h,{passive:!0})})),c=!1),Object.assign(t.style,{position:o}),(0,w.oo)(i,t,{placement:a,middleware:r,strategy:o}).then((({x:e,y:i,middlewareData:r,placement:a})=>{l||(function(e){const{arrow:t,middlewareData:i}=e;if(!i.arrow||!t)return;const{x:n,y:o}=i.arrow;Object.assign(t.style,{left:`${n}px`,top:`${o}px`})}({arrow:n,middlewareData:r}),function(e){var t,i,n;const{container:o,placement:r,middlewareData:a,strategy:s,lowPPI:l,coordinates:c,useTransform:d=!0}=e;if(!o)return;o.setAttribute(E,r),o.removeAttribute(O),a.intersectionObserver.intersecting&&o.setAttribute(O,""),o.removeAttribute(P),(null===(t=a.hide)||void 0===t?void 0:t.escaped)&&o.setAttribute(P,""),o.removeAttribute(A),(null===(i=a.hide)||void 0===i?void 0:i.referenceHidden)&&o.setAttribute(A,"");const u=(null===(n=o.ownerDocument.defaultView)||void 0===n?void 0:n.devicePixelRatio)||1,h=Math.round(c.x*u)/u,p=Math.round(c.y*u)/u;Object.assign(o.style,{position:s}),d?Object.assign(o.style,{transform:l?`translate(${h}px, ${p}px)`:`translate3d(${h}px, ${p}px, 0)`}):Object.assign(o.style,{left:`${h}px`,top:`${p}px`})}({container:t,middlewareData:r,placement:a,coordinates:{x:e,y:i},lowPPI:((null==u?void 0:u.devicePixelRatio)||1)<=1,strategy:o,useTransform:s}))})).catch((e=>{})))))}))}))),p)}();return u&&(u.addEventListener("scroll",h,{passive:!0}),u.addEventListener("resize",h)),h(),{updatePosition:h,dispose:()=>{l=!0,u&&(u.removeEventListener("scroll",h),u.removeEventListener("resize",h)),d.forEach((e=>{e.removeEventListener("scroll",h)})),d.clear()}}}function _(e){const t=l.useRef(null),i=l.useRef(null),u=l.useRef(null),g=l.useRef(null),y=l.useRef(null),{enabled:b=!0}=e,x=function(e){const{align:t,arrowPadding:i,autoSize:r,coverTarget:a,flipBoundary:s,offset:c,overflowBoundary:u,pinned:g,position:y,unstable_disableTether:b,positionFixed:x,strategy:w,overflowBoundaryPadding:O,fallbackPositions:P,useTransform:A}=e,{dir:E}=(0,o.O)(),k="rtl"===E,I=(null!=w?w:x)?"fixed":"absolute",D=d(r);return l.useCallback(((e,o)=>{const r=h(e),l=[D&&f(D),c&&C(c),a&&{name:"coverTarget",fn:e=>{const{placement:t,rects:i,x:n,y:o}=e,r={x:n,y:o};switch(v(t).side){case"bottom":r.y-=i.reference.height;break;case"top":r.y+=i.reference.height;break;case"left":r.x+=i.reference.width;break;case"right":r.x-=i.reference.width}return r}},!g&&S({container:e,flipBoundary:s,hasScrollableElement:r,isRtl:k,fallbackPositions:P}),T({container:e,hasScrollableElement:r,overflowBoundary:u,disableTether:b,overflowBoundaryPadding:O,isRtl:k}),D&&m(D,{container:e,overflowBoundary:u}),{name:"intersectionObserver",fn:async e=>{const t=e.rects.floating,i=await(0,n.US)(e,{altBoundary:!0}),o=i.top<t.height&&i.top>0,r=i.bottom<t.height&&i.bottom>0;return{data:{intersecting:o||r}}}},o&&(0,n.x7)({element:o,padding:i}),(0,n.Cp)({strategy:"referenceHidden"}),(0,n.Cp)({strategy:"escaped"})].filter(Boolean);return{placement:p(t,y,k),middleware:l,strategy:I,useTransform:A}}),[t,i,D,a,b,s,k,c,u,g,y,I,O,P,A])}(e),w=l.useCallback((()=>{var e;t.current&&t.current.dispose(),t.current=null;const n=null!==(e=u.current)&&void 0!==e?e:i.current;b&&(0,r.N)()&&n&&g.current&&(t.current=D({container:g.current,target:n,arrow:y.current,...x(g.current,y.current)}))}),[b,x]),O=(0,a.$)((e=>{u.current=e,w()}));return l.useImperativeHandle(e.positioningRef,(()=>({updatePosition:()=>{var e;return null===(e=t.current)||void 0===e?void 0:e.updatePosition()},setTarget:t=>{e.target,O(t)}})),[e.target,O]),(0,s.L)((()=>{var t;O(null!==(t=e.target)&&void 0!==t?t:null)}),[e.target,O]),(0,s.L)((()=>{w()}),[w]),{targetRef:c(null,(e=>{i.current!==e&&(i.current=e,w())})),containerRef:c(null,(e=>{g.current!==e&&(g.current=e,w())})),arrowRef:c(null,(e=>{y.current!==e&&(y.current=e,w())}))}}},85440:function(e,t,i){"use strict";function n(e,t){return"number"==typeof e||"object"==typeof e&&null!==e?o(e,t):"function"==typeof e?i=>{const n=e(i);return o(n,t)}:{mainAxis:t}}i.d(t,{w:function(){return n}});const o=(e,t)=>{return"number"==typeof e?{mainAxis:e+t}:{...e,mainAxis:(null!==(i=e.mainAxis)&&void 0!==i?i:0)+t};var i}},12211:function(e,t,i){"use strict";i.d(t,{j:function(){return o}});const n={above:{position:"above",align:"center"},"above-start":{position:"above",align:"start"},"above-end":{position:"above",align:"end"},below:{position:"below",align:"center"},"below-start":{position:"below",align:"start"},"below-end":{position:"below",align:"end"},before:{position:"before",align:"center"},"before-top":{position:"before",align:"top"},"before-bottom":{position:"before",align:"bottom"},after:{position:"after",align:"center"},"after-top":{position:"after",align:"top"},"after-bottom":{position:"after",align:"bottom"}};function o(e){return null==e?{}:"string"==typeof e?n[e]:e}},44906:function(e,t,i){"use strict";i.d(t,{Qb:function(){return o},UF:function(){return a},oj:function(){return s}});var n=i(8559);const o=n.createContext(void 0),r=()=>{},a=o.Provider,s=e=>{var t,i;return null!==(i=null===(t=n.useContext(o))||void 0===t?void 0:t[e])&&void 0!==i?i:r}},10910:function(e,t,i){"use strict";i.d(t,{O:function(){return s},z:function(){return a}});var n=i(8559);const o=n.createContext(void 0),r={targetDocument:"object"==typeof document?document:void 0,dir:"ltr"},a=o.Provider;function s(){var e;return null!==(e=n.useContext(o))&&void 0!==e?e:r}},64143:function(e,t,i){"use strict";i.d(t,{H:function(){return s},U:function(){return a}});var n=i(8559);const o=n.createContext(void 0),r="",a=o.Provider;function s(){var e;return null!==(e=n.useContext(o))&&void 0!==e?e:r}},16049:function(e,t,i){"use strict";i.d(t,{_:function(){return d}});var n=i(8559),o=i(10910),r=i(96568),a=i(77793);const s="data-fui-focus-visible";function l(e,t){if(c(e))return()=>{};const i={current:void 0},n=(0,a.Vm)(t);function o(e){n.isNavigatingWithKeyboard()&&(0,r.R)(e)&&(i.current=e,e.setAttribute(s,""))}function l(){i.current&&(i.current.removeAttribute(s),i.current=void 0)}n.subscribe((e=>{e||l()}));const d=e=>{l(),o(e.target)},u=t=>{(!t.relatedTarget||(0,r.R)(t.relatedTarget)&&!e.contains(t.relatedTarget))&&l()};return e.addEventListener(a.PW,d),e.addEventListener("focusout",u),e.focusVisible=!0,o(t.document.activeElement),()=>{l(),e.removeEventListener(a.PW,d),e.removeEventListener("focusout",u),delete e.focusVisible,(0,a.ub)(n)}}function c(e){return!!e&&(!!e.focusVisible||c(null==e?void 0:e.parentElement))}function d(e={}){const t=(0,o.O)(),i=n.useRef(null);var r;const a=null!==(r=e.targetDocument)&&void 0!==r?r:t.targetDocument;return n.useEffect((()=>{if((null==a?void 0:a.defaultView)&&i.current)return l(i.current,a.defaultView)}),[i,a]),i}},44956:function(e,t,i){"use strict";i.d(t,{w:function(){return o}});var n=i(61492);const o={body1:{fontFamily:n.T.fontFamilyBase,fontSize:n.T.fontSizeBase300,fontWeight:n.T.fontWeightRegular,lineHeight:n.T.lineHeightBase300},body1Strong:{fontFamily:n.T.fontFamilyBase,fontSize:n.T.fontSizeBase300,fontWeight:n.T.fontWeightSemibold,lineHeight:n.T.lineHeightBase300},body1Stronger:{fontFamily:n.T.fontFamilyBase,fontSize:n.T.fontSizeBase300,fontWeight:n.T.fontWeightBold,lineHeight:n.T.lineHeightBase300},body2:{fontFamily:n.T.fontFamilyBase,fontSize:n.T.fontSizeBase400,fontWeight:n.T.fontWeightRegular,lineHeight:n.T.lineHeightBase400},caption1:{fontFamily:n.T.fontFamilyBase,fontSize:n.T.fontSizeBase200,fontWeight:n.T.fontWeightRegular,lineHeight:n.T.lineHeightBase200},caption1Strong:{fontFamily:n.T.fontFamilyBase,fontSize:n.T.fontSizeBase200,fontWeight:n.T.fontWeightSemibold,lineHeight:n.T.lineHeightBase200},caption1Stronger:{fontFamily:n.T.fontFamilyBase,fontSize:n.T.fontSizeBase200,fontWeight:n.T.fontWeightBold,lineHeight:n.T.lineHeightBase200},caption2:{fontFamily:n.T.fontFamilyBase,fontSize:n.T.fontSizeBase100,fontWeight:n.T.fontWeightRegular,lineHeight:n.T.lineHeightBase100},caption2Strong:{fontFamily:n.T.fontFamilyBase,fontSize:n.T.fontSizeBase100,fontWeight:n.T.fontWeightSemibold,lineHeight:n.T.lineHeightBase100},subtitle1:{fontFamily:n.T.fontFamilyBase,fontSize:n.T.fontSizeBase500,fontWeight:n.T.fontWeightSemibold,lineHeight:n.T.lineHeightBase500},subtitle2:{fontFamily:n.T.fontFamilyBase,fontSize:n.T.fontSizeBase400,fontWeight:n.T.fontWeightSemibold,lineHeight:n.T.lineHeightBase400},subtitle2Stronger:{fontFamily:n.T.fontFamilyBase,fontSize:n.T.fontSizeBase400,fontWeight:n.T.fontWeightBold,lineHeight:n.T.lineHeightBase400},title1:{fontFamily:n.T.fontFamilyBase,fontSize:n.T.fontSizeHero800,fontWeight:n.T.fontWeightSemibold,lineHeight:n.T.lineHeightHero800},title2:{fontFamily:n.T.fontFamilyBase,fontSize:n.T.fontSizeHero700,fontWeight:n.T.fontWeightSemibold,lineHeight:n.T.lineHeightHero700},title3:{fontFamily:n.T.fontFamilyBase,fontSize:n.T.fontSizeBase600,fontWeight:n.T.fontWeightSemibold,lineHeight:n.T.lineHeightBase600},largeTitle:{fontFamily:n.T.fontFamilyBase,fontSize:n.T.fontSizeHero900,fontWeight:n.T.fontWeightSemibold,lineHeight:n.T.lineHeightHero900},display:{fontFamily:n.T.fontFamilyBase,fontSize:n.T.fontSizeHero1000,fontWeight:n.T.fontWeightSemibold,lineHeight:n.T.lineHeightHero1000}}},61492:function(e,t,i){"use strict";i.d(t,{T:function(){return n}});const n={colorNeutralForeground1:"var(--colorNeutralForeground1)",colorNeutralForeground1Hover:"var(--colorNeutralForeground1Hover)",colorNeutralForeground1Pressed:"var(--colorNeutralForeground1Pressed)",colorNeutralForeground1Selected:"var(--colorNeutralForeground1Selected)",colorNeutralForeground2:"var(--colorNeutralForeground2)",colorNeutralForeground2Hover:"var(--colorNeutralForeground2Hover)",colorNeutralForeground2Pressed:"var(--colorNeutralForeground2Pressed)",colorNeutralForeground2Selected:"var(--colorNeutralForeground2Selected)",colorNeutralForeground2BrandHover:"var(--colorNeutralForeground2BrandHover)",colorNeutralForeground2BrandPressed:"var(--colorNeutralForeground2BrandPressed)",colorNeutralForeground2BrandSelected:"var(--colorNeutralForeground2BrandSelected)",colorNeutralForeground3:"var(--colorNeutralForeground3)",colorNeutralForeground3Hover:"var(--colorNeutralForeground3Hover)",colorNeutralForeground3Pressed:"var(--colorNeutralForeground3Pressed)",colorNeutralForeground3Selected:"var(--colorNeutralForeground3Selected)",colorNeutralForeground3BrandHover:"var(--colorNeutralForeground3BrandHover)",colorNeutralForeground3BrandPressed:"var(--colorNeutralForeground3BrandPressed)",colorNeutralForeground3BrandSelected:"var(--colorNeutralForeground3BrandSelected)",colorNeutralForeground4:"var(--colorNeutralForeground4)",colorNeutralForegroundDisabled:"var(--colorNeutralForegroundDisabled)",colorBrandForegroundLink:"var(--colorBrandForegroundLink)",colorBrandForegroundLinkHover:"var(--colorBrandForegroundLinkHover)",colorBrandForegroundLinkPressed:"var(--colorBrandForegroundLinkPressed)",colorBrandForegroundLinkSelected:"var(--colorBrandForegroundLinkSelected)",colorNeutralForeground2Link:"var(--colorNeutralForeground2Link)",colorNeutralForeground2LinkHover:"var(--colorNeutralForeground2LinkHover)",colorNeutralForeground2LinkPressed:"var(--colorNeutralForeground2LinkPressed)",colorNeutralForeground2LinkSelected:"var(--colorNeutralForeground2LinkSelected)",colorCompoundBrandForeground1:"var(--colorCompoundBrandForeground1)",colorCompoundBrandForeground1Hover:"var(--colorCompoundBrandForeground1Hover)",colorCompoundBrandForeground1Pressed:"var(--colorCompoundBrandForeground1Pressed)",colorNeutralForegroundOnBrand:"var(--colorNeutralForegroundOnBrand)",colorNeutralForegroundInverted:"var(--colorNeutralForegroundInverted)",colorNeutralForegroundInvertedHover:"var(--colorNeutralForegroundInvertedHover)",colorNeutralForegroundInvertedPressed:"var(--colorNeutralForegroundInvertedPressed)",colorNeutralForegroundInvertedSelected:"var(--colorNeutralForegroundInvertedSelected)",colorNeutralForegroundInverted2:"var(--colorNeutralForegroundInverted2)",colorNeutralForegroundStaticInverted:"var(--colorNeutralForegroundStaticInverted)",colorNeutralForegroundInvertedLink:"var(--colorNeutralForegroundInvertedLink)",colorNeutralForegroundInvertedLinkHover:"var(--colorNeutralForegroundInvertedLinkHover)",colorNeutralForegroundInvertedLinkPressed:"var(--colorNeutralForegroundInvertedLinkPressed)",colorNeutralForegroundInvertedLinkSelected:"var(--colorNeutralForegroundInvertedLinkSelected)",colorNeutralForegroundInvertedDisabled:"var(--colorNeutralForegroundInvertedDisabled)",colorBrandForeground1:"var(--colorBrandForeground1)",colorBrandForeground2:"var(--colorBrandForeground2)",colorBrandForeground2Hover:"var(--colorBrandForeground2Hover)",colorBrandForeground2Pressed:"var(--colorBrandForeground2Pressed)",colorNeutralForeground1Static:"var(--colorNeutralForeground1Static)",colorBrandForegroundInverted:"var(--colorBrandForegroundInverted)",colorBrandForegroundInvertedHover:"var(--colorBrandForegroundInvertedHover)",colorBrandForegroundInvertedPressed:"var(--colorBrandForegroundInvertedPressed)",colorBrandForegroundOnLight:"var(--colorBrandForegroundOnLight)",colorBrandForegroundOnLightHover:"var(--colorBrandForegroundOnLightHover)",colorBrandForegroundOnLightPressed:"var(--colorBrandForegroundOnLightPressed)",colorBrandForegroundOnLightSelected:"var(--colorBrandForegroundOnLightSelected)",colorNeutralBackground1:"var(--colorNeutralBackground1)",colorNeutralBackground1Hover:"var(--colorNeutralBackground1Hover)",colorNeutralBackground1Pressed:"var(--colorNeutralBackground1Pressed)",colorNeutralBackground1Selected:"var(--colorNeutralBackground1Selected)",colorNeutralBackground2:"var(--colorNeutralBackground2)",colorNeutralBackground2Hover:"var(--colorNeutralBackground2Hover)",colorNeutralBackground2Pressed:"var(--colorNeutralBackground2Pressed)",colorNeutralBackground2Selected:"var(--colorNeutralBackground2Selected)",colorNeutralBackground3:"var(--colorNeutralBackground3)",colorNeutralBackground3Hover:"var(--colorNeutralBackground3Hover)",colorNeutralBackground3Pressed:"var(--colorNeutralBackground3Pressed)",colorNeutralBackground3Selected:"var(--colorNeutralBackground3Selected)",colorNeutralBackground4:"var(--colorNeutralBackground4)",colorNeutralBackground4Hover:"var(--colorNeutralBackground4Hover)",colorNeutralBackground4Pressed:"var(--colorNeutralBackground4Pressed)",colorNeutralBackground4Selected:"var(--colorNeutralBackground4Selected)",colorNeutralBackground5:"var(--colorNeutralBackground5)",colorNeutralBackground5Hover:"var(--colorNeutralBackground5Hover)",colorNeutralBackground5Pressed:"var(--colorNeutralBackground5Pressed)",colorNeutralBackground5Selected:"var(--colorNeutralBackground5Selected)",colorNeutralBackground6:"var(--colorNeutralBackground6)",colorNeutralBackgroundInverted:"var(--colorNeutralBackgroundInverted)",colorNeutralBackgroundStatic:"var(--colorNeutralBackgroundStatic)",colorNeutralBackgroundAlpha:"var(--colorNeutralBackgroundAlpha)",colorNeutralBackgroundAlpha2:"var(--colorNeutralBackgroundAlpha2)",colorSubtleBackground:"var(--colorSubtleBackground)",colorSubtleBackgroundHover:"var(--colorSubtleBackgroundHover)",colorSubtleBackgroundPressed:"var(--colorSubtleBackgroundPressed)",colorSubtleBackgroundSelected:"var(--colorSubtleBackgroundSelected)",colorSubtleBackgroundLightAlphaHover:"var(--colorSubtleBackgroundLightAlphaHover)",colorSubtleBackgroundLightAlphaPressed:"var(--colorSubtleBackgroundLightAlphaPressed)",colorSubtleBackgroundLightAlphaSelected:"var(--colorSubtleBackgroundLightAlphaSelected)",colorSubtleBackgroundInverted:"var(--colorSubtleBackgroundInverted)",colorSubtleBackgroundInvertedHover:"var(--colorSubtleBackgroundInvertedHover)",colorSubtleBackgroundInvertedPressed:"var(--colorSubtleBackgroundInvertedPressed)",colorSubtleBackgroundInvertedSelected:"var(--colorSubtleBackgroundInvertedSelected)",colorTransparentBackground:"var(--colorTransparentBackground)",colorTransparentBackgroundHover:"var(--colorTransparentBackgroundHover)",colorTransparentBackgroundPressed:"var(--colorTransparentBackgroundPressed)",colorTransparentBackgroundSelected:"var(--colorTransparentBackgroundSelected)",colorNeutralBackgroundDisabled:"var(--colorNeutralBackgroundDisabled)",colorNeutralBackgroundInvertedDisabled:"var(--colorNeutralBackgroundInvertedDisabled)",colorNeutralStencil1:"var(--colorNeutralStencil1)",colorNeutralStencil2:"var(--colorNeutralStencil2)",colorNeutralStencil1Alpha:"var(--colorNeutralStencil1Alpha)",colorNeutralStencil2Alpha:"var(--colorNeutralStencil2Alpha)",colorBackgroundOverlay:"var(--colorBackgroundOverlay)",colorScrollbarOverlay:"var(--colorScrollbarOverlay)",colorBrandBackground:"var(--colorBrandBackground)",colorBrandBackgroundHover:"var(--colorBrandBackgroundHover)",colorBrandBackgroundPressed:"var(--colorBrandBackgroundPressed)",colorBrandBackgroundSelected:"var(--colorBrandBackgroundSelected)",colorCompoundBrandBackground:"var(--colorCompoundBrandBackground)",colorCompoundBrandBackgroundHover:"var(--colorCompoundBrandBackgroundHover)",colorCompoundBrandBackgroundPressed:"var(--colorCompoundBrandBackgroundPressed)",colorBrandBackgroundStatic:"var(--colorBrandBackgroundStatic)",colorBrandBackground2:"var(--colorBrandBackground2)",colorBrandBackground2Hover:"var(--colorBrandBackground2Hover)",colorBrandBackground2Pressed:"var(--colorBrandBackground2Pressed)",colorBrandBackgroundInverted:"var(--colorBrandBackgroundInverted)",colorBrandBackgroundInvertedHover:"var(--colorBrandBackgroundInvertedHover)",colorBrandBackgroundInvertedPressed:"var(--colorBrandBackgroundInvertedPressed)",colorBrandBackgroundInvertedSelected:"var(--colorBrandBackgroundInvertedSelected)",colorNeutralStrokeAccessible:"var(--colorNeutralStrokeAccessible)",colorNeutralStrokeAccessibleHover:"var(--colorNeutralStrokeAccessibleHover)",colorNeutralStrokeAccessiblePressed:"var(--colorNeutralStrokeAccessiblePressed)",colorNeutralStrokeAccessibleSelected:"var(--colorNeutralStrokeAccessibleSelected)",colorNeutralStroke1:"var(--colorNeutralStroke1)",colorNeutralStroke1Hover:"var(--colorNeutralStroke1Hover)",colorNeutralStroke1Pressed:"var(--colorNeutralStroke1Pressed)",colorNeutralStroke1Selected:"var(--colorNeutralStroke1Selected)",colorNeutralStroke2:"var(--colorNeutralStroke2)",colorNeutralStroke3:"var(--colorNeutralStroke3)",colorNeutralStrokeSubtle:"var(--colorNeutralStrokeSubtle)",colorNeutralStrokeOnBrand:"var(--colorNeutralStrokeOnBrand)",colorNeutralStrokeOnBrand2:"var(--colorNeutralStrokeOnBrand2)",colorNeutralStrokeOnBrand2Hover:"var(--colorNeutralStrokeOnBrand2Hover)",colorNeutralStrokeOnBrand2Pressed:"var(--colorNeutralStrokeOnBrand2Pressed)",colorNeutralStrokeOnBrand2Selected:"var(--colorNeutralStrokeOnBrand2Selected)",colorBrandStroke1:"var(--colorBrandStroke1)",colorBrandStroke2:"var(--colorBrandStroke2)",colorBrandStroke2Hover:"var(--colorBrandStroke2Hover)",colorBrandStroke2Pressed:"var(--colorBrandStroke2Pressed)",colorBrandStroke2Contrast:"var(--colorBrandStroke2Contrast)",colorCompoundBrandStroke:"var(--colorCompoundBrandStroke)",colorCompoundBrandStrokeHover:"var(--colorCompoundBrandStrokeHover)",colorCompoundBrandStrokePressed:"var(--colorCompoundBrandStrokePressed)",colorNeutralStrokeDisabled:"var(--colorNeutralStrokeDisabled)",colorNeutralStrokeInvertedDisabled:"var(--colorNeutralStrokeInvertedDisabled)",colorTransparentStroke:"var(--colorTransparentStroke)",colorTransparentStrokeInteractive:"var(--colorTransparentStrokeInteractive)",colorTransparentStrokeDisabled:"var(--colorTransparentStrokeDisabled)",colorNeutralStrokeAlpha:"var(--colorNeutralStrokeAlpha)",colorNeutralStrokeAlpha2:"var(--colorNeutralStrokeAlpha2)",colorStrokeFocus1:"var(--colorStrokeFocus1)",colorStrokeFocus2:"var(--colorStrokeFocus2)",colorNeutralShadowAmbient:"var(--colorNeutralShadowAmbient)",colorNeutralShadowKey:"var(--colorNeutralShadowKey)",colorNeutralShadowAmbientLighter:"var(--colorNeutralShadowAmbientLighter)",colorNeutralShadowKeyLighter:"var(--colorNeutralShadowKeyLighter)",colorNeutralShadowAmbientDarker:"var(--colorNeutralShadowAmbientDarker)",colorNeutralShadowKeyDarker:"var(--colorNeutralShadowKeyDarker)",colorBrandShadowAmbient:"var(--colorBrandShadowAmbient)",colorBrandShadowKey:"var(--colorBrandShadowKey)",colorPaletteRedBackground1:"var(--colorPaletteRedBackground1)",colorPaletteRedBackground2:"var(--colorPaletteRedBackground2)",colorPaletteRedBackground3:"var(--colorPaletteRedBackground3)",colorPaletteRedBorderActive:"var(--colorPaletteRedBorderActive)",colorPaletteRedBorder1:"var(--colorPaletteRedBorder1)",colorPaletteRedBorder2:"var(--colorPaletteRedBorder2)",colorPaletteRedForeground1:"var(--colorPaletteRedForeground1)",colorPaletteRedForeground2:"var(--colorPaletteRedForeground2)",colorPaletteRedForeground3:"var(--colorPaletteRedForeground3)",colorPaletteRedForegroundInverted:"var(--colorPaletteRedForegroundInverted)",colorPaletteGreenBackground1:"var(--colorPaletteGreenBackground1)",colorPaletteGreenBackground2:"var(--colorPaletteGreenBackground2)",colorPaletteGreenBackground3:"var(--colorPaletteGreenBackground3)",colorPaletteGreenBorderActive:"var(--colorPaletteGreenBorderActive)",colorPaletteGreenBorder1:"var(--colorPaletteGreenBorder1)",colorPaletteGreenBorder2:"var(--colorPaletteGreenBorder2)",colorPaletteGreenForeground1:"var(--colorPaletteGreenForeground1)",colorPaletteGreenForeground2:"var(--colorPaletteGreenForeground2)",colorPaletteGreenForeground3:"var(--colorPaletteGreenForeground3)",colorPaletteGreenForegroundInverted:"var(--colorPaletteGreenForegroundInverted)",colorPaletteDarkOrangeBackground1:"var(--colorPaletteDarkOrangeBackground1)",colorPaletteDarkOrangeBackground2:"var(--colorPaletteDarkOrangeBackground2)",colorPaletteDarkOrangeBackground3:"var(--colorPaletteDarkOrangeBackground3)",colorPaletteDarkOrangeBorderActive:"var(--colorPaletteDarkOrangeBorderActive)",colorPaletteDarkOrangeBorder1:"var(--colorPaletteDarkOrangeBorder1)",colorPaletteDarkOrangeBorder2:"var(--colorPaletteDarkOrangeBorder2)",colorPaletteDarkOrangeForeground1:"var(--colorPaletteDarkOrangeForeground1)",colorPaletteDarkOrangeForeground2:"var(--colorPaletteDarkOrangeForeground2)",colorPaletteDarkOrangeForeground3:"var(--colorPaletteDarkOrangeForeground3)",colorPaletteYellowBackground1:"var(--colorPaletteYellowBackground1)",colorPaletteYellowBackground2:"var(--colorPaletteYellowBackground2)",colorPaletteYellowBackground3:"var(--colorPaletteYellowBackground3)",colorPaletteYellowBorderActive:"var(--colorPaletteYellowBorderActive)",colorPaletteYellowBorder1:"var(--colorPaletteYellowBorder1)",colorPaletteYellowBorder2:"var(--colorPaletteYellowBorder2)",colorPaletteYellowForeground1:"var(--colorPaletteYellowForeground1)",colorPaletteYellowForeground2:"var(--colorPaletteYellowForeground2)",colorPaletteYellowForeground3:"var(--colorPaletteYellowForeground3)",colorPaletteYellowForegroundInverted:"var(--colorPaletteYellowForegroundInverted)",colorPaletteBerryBackground1:"var(--colorPaletteBerryBackground1)",colorPaletteBerryBackground2:"var(--colorPaletteBerryBackground2)",colorPaletteBerryBackground3:"var(--colorPaletteBerryBackground3)",colorPaletteBerryBorderActive:"var(--colorPaletteBerryBorderActive)",colorPaletteBerryBorder1:"var(--colorPaletteBerryBorder1)",colorPaletteBerryBorder2:"var(--colorPaletteBerryBorder2)",colorPaletteBerryForeground1:"var(--colorPaletteBerryForeground1)",colorPaletteBerryForeground2:"var(--colorPaletteBerryForeground2)",colorPaletteBerryForeground3:"var(--colorPaletteBerryForeground3)",colorPaletteMarigoldBackground1:"var(--colorPaletteMarigoldBackground1)",colorPaletteMarigoldBackground2:"var(--colorPaletteMarigoldBackground2)",colorPaletteMarigoldBackground3:"var(--colorPaletteMarigoldBackground3)",colorPaletteMarigoldBorderActive:"var(--colorPaletteMarigoldBorderActive)",colorPaletteMarigoldBorder1:"var(--colorPaletteMarigoldBorder1)",colorPaletteMarigoldBorder2:"var(--colorPaletteMarigoldBorder2)",colorPaletteMarigoldForeground1:"var(--colorPaletteMarigoldForeground1)",colorPaletteMarigoldForeground2:"var(--colorPaletteMarigoldForeground2)",colorPaletteMarigoldForeground3:"var(--colorPaletteMarigoldForeground3)",colorPaletteLightGreenBackground1:"var(--colorPaletteLightGreenBackground1)",colorPaletteLightGreenBackground2:"var(--colorPaletteLightGreenBackground2)",colorPaletteLightGreenBackground3:"var(--colorPaletteLightGreenBackground3)",colorPaletteLightGreenBorderActive:"var(--colorPaletteLightGreenBorderActive)",colorPaletteLightGreenBorder1:"var(--colorPaletteLightGreenBorder1)",colorPaletteLightGreenBorder2:"var(--colorPaletteLightGreenBorder2)",colorPaletteLightGreenForeground1:"var(--colorPaletteLightGreenForeground1)",colorPaletteLightGreenForeground2:"var(--colorPaletteLightGreenForeground2)",colorPaletteLightGreenForeground3:"var(--colorPaletteLightGreenForeground3)",colorPaletteAnchorBackground2:"var(--colorPaletteAnchorBackground2)",colorPaletteAnchorBorderActive:"var(--colorPaletteAnchorBorderActive)",colorPaletteAnchorForeground2:"var(--colorPaletteAnchorForeground2)",colorPaletteBeigeBackground2:"var(--colorPaletteBeigeBackground2)",colorPaletteBeigeBorderActive:"var(--colorPaletteBeigeBorderActive)",colorPaletteBeigeForeground2:"var(--colorPaletteBeigeForeground2)",colorPaletteBlueBackground2:"var(--colorPaletteBlueBackground2)",colorPaletteBlueBorderActive:"var(--colorPaletteBlueBorderActive)",colorPaletteBlueForeground2:"var(--colorPaletteBlueForeground2)",colorPaletteBrassBackground2:"var(--colorPaletteBrassBackground2)",colorPaletteBrassBorderActive:"var(--colorPaletteBrassBorderActive)",colorPaletteBrassForeground2:"var(--colorPaletteBrassForeground2)",colorPaletteBrownBackground2:"var(--colorPaletteBrownBackground2)",colorPaletteBrownBorderActive:"var(--colorPaletteBrownBorderActive)",colorPaletteBrownForeground2:"var(--colorPaletteBrownForeground2)",colorPaletteCornflowerBackground2:"var(--colorPaletteCornflowerBackground2)",colorPaletteCornflowerBorderActive:"var(--colorPaletteCornflowerBorderActive)",colorPaletteCornflowerForeground2:"var(--colorPaletteCornflowerForeground2)",colorPaletteCranberryBackground2:"var(--colorPaletteCranberryBackground2)",colorPaletteCranberryBorderActive:"var(--colorPaletteCranberryBorderActive)",colorPaletteCranberryForeground2:"var(--colorPaletteCranberryForeground2)",colorPaletteDarkGreenBackground2:"var(--colorPaletteDarkGreenBackground2)",colorPaletteDarkGreenBorderActive:"var(--colorPaletteDarkGreenBorderActive)",colorPaletteDarkGreenForeground2:"var(--colorPaletteDarkGreenForeground2)",colorPaletteDarkRedBackground2:"var(--colorPaletteDarkRedBackground2)",colorPaletteDarkRedBorderActive:"var(--colorPaletteDarkRedBorderActive)",colorPaletteDarkRedForeground2:"var(--colorPaletteDarkRedForeground2)",colorPaletteForestBackground2:"var(--colorPaletteForestBackground2)",colorPaletteForestBorderActive:"var(--colorPaletteForestBorderActive)",colorPaletteForestForeground2:"var(--colorPaletteForestForeground2)",colorPaletteGoldBackground2:"var(--colorPaletteGoldBackground2)",colorPaletteGoldBorderActive:"var(--colorPaletteGoldBorderActive)",colorPaletteGoldForeground2:"var(--colorPaletteGoldForeground2)",colorPaletteGrapeBackground2:"var(--colorPaletteGrapeBackground2)",colorPaletteGrapeBorderActive:"var(--colorPaletteGrapeBorderActive)",colorPaletteGrapeForeground2:"var(--colorPaletteGrapeForeground2)",colorPaletteLavenderBackground2:"var(--colorPaletteLavenderBackground2)",colorPaletteLavenderBorderActive:"var(--colorPaletteLavenderBorderActive)",colorPaletteLavenderForeground2:"var(--colorPaletteLavenderForeground2)",colorPaletteLightTealBackground2:"var(--colorPaletteLightTealBackground2)",colorPaletteLightTealBorderActive:"var(--colorPaletteLightTealBorderActive)",colorPaletteLightTealForeground2:"var(--colorPaletteLightTealForeground2)",colorPaletteLilacBackground2:"var(--colorPaletteLilacBackground2)",colorPaletteLilacBorderActive:"var(--colorPaletteLilacBorderActive)",colorPaletteLilacForeground2:"var(--colorPaletteLilacForeground2)",colorPaletteMagentaBackground2:"var(--colorPaletteMagentaBackground2)",colorPaletteMagentaBorderActive:"var(--colorPaletteMagentaBorderActive)",colorPaletteMagentaForeground2:"var(--colorPaletteMagentaForeground2)",colorPaletteMinkBackground2:"var(--colorPaletteMinkBackground2)",colorPaletteMinkBorderActive:"var(--colorPaletteMinkBorderActive)",colorPaletteMinkForeground2:"var(--colorPaletteMinkForeground2)",colorPaletteNavyBackground2:"var(--colorPaletteNavyBackground2)",colorPaletteNavyBorderActive:"var(--colorPaletteNavyBorderActive)",colorPaletteNavyForeground2:"var(--colorPaletteNavyForeground2)",colorPalettePeachBackground2:"var(--colorPalettePeachBackground2)",colorPalettePeachBorderActive:"var(--colorPalettePeachBorderActive)",colorPalettePeachForeground2:"var(--colorPalettePeachForeground2)",colorPalettePinkBackground2:"var(--colorPalettePinkBackground2)",colorPalettePinkBorderActive:"var(--colorPalettePinkBorderActive)",colorPalettePinkForeground2:"var(--colorPalettePinkForeground2)",colorPalettePlatinumBackground2:"var(--colorPalettePlatinumBackground2)",colorPalettePlatinumBorderActive:"var(--colorPalettePlatinumBorderActive)",colorPalettePlatinumForeground2:"var(--colorPalettePlatinumForeground2)",colorPalettePlumBackground2:"var(--colorPalettePlumBackground2)",colorPalettePlumBorderActive:"var(--colorPalettePlumBorderActive)",colorPalettePlumForeground2:"var(--colorPalettePlumForeground2)",colorPalettePumpkinBackground2:"var(--colorPalettePumpkinBackground2)",colorPalettePumpkinBorderActive:"var(--colorPalettePumpkinBorderActive)",colorPalettePumpkinForeground2:"var(--colorPalettePumpkinForeground2)",colorPalettePurpleBackground2:"var(--colorPalettePurpleBackground2)",colorPalettePurpleBorderActive:"var(--colorPalettePurpleBorderActive)",colorPalettePurpleForeground2:"var(--colorPalettePurpleForeground2)",colorPaletteRoyalBlueBackground2:"var(--colorPaletteRoyalBlueBackground2)",colorPaletteRoyalBlueBorderActive:"var(--colorPaletteRoyalBlueBorderActive)",colorPaletteRoyalBlueForeground2:"var(--colorPaletteRoyalBlueForeground2)",colorPaletteSeafoamBackground2:"var(--colorPaletteSeafoamBackground2)",colorPaletteSeafoamBorderActive:"var(--colorPaletteSeafoamBorderActive)",colorPaletteSeafoamForeground2:"var(--colorPaletteSeafoamForeground2)",colorPaletteSteelBackground2:"var(--colorPaletteSteelBackground2)",colorPaletteSteelBorderActive:"var(--colorPaletteSteelBorderActive)",colorPaletteSteelForeground2:"var(--colorPaletteSteelForeground2)",colorPaletteTealBackground2:"var(--colorPaletteTealBackground2)",colorPaletteTealBorderActive:"var(--colorPaletteTealBorderActive)",colorPaletteTealForeground2:"var(--colorPaletteTealForeground2)",colorStatusSuccessBackground1:"var(--colorStatusSuccessBackground1)",colorStatusSuccessBackground2:"var(--colorStatusSuccessBackground2)",colorStatusSuccessBackground3:"var(--colorStatusSuccessBackground3)",colorStatusSuccessForeground1:"var(--colorStatusSuccessForeground1)",colorStatusSuccessForeground2:"var(--colorStatusSuccessForeground2)",colorStatusSuccessForeground3:"var(--colorStatusSuccessForeground3)",colorStatusSuccessForegroundInverted:"var(--colorStatusSuccessForegroundInverted)",colorStatusSuccessBorderActive:"var(--colorStatusSuccessBorderActive)",colorStatusSuccessBorder1:"var(--colorStatusSuccessBorder1)",colorStatusSuccessBorder2:"var(--colorStatusSuccessBorder2)",colorStatusWarningBackground1:"var(--colorStatusWarningBackground1)",colorStatusWarningBackground2:"var(--colorStatusWarningBackground2)",colorStatusWarningBackground3:"var(--colorStatusWarningBackground3)",colorStatusWarningForeground1:"var(--colorStatusWarningForeground1)",colorStatusWarningForeground2:"var(--colorStatusWarningForeground2)",colorStatusWarningForeground3:"var(--colorStatusWarningForeground3)",colorStatusWarningForegroundInverted:"var(--colorStatusWarningForegroundInverted)",colorStatusWarningBorderActive:"var(--colorStatusWarningBorderActive)",colorStatusWarningBorder1:"var(--colorStatusWarningBorder1)",colorStatusWarningBorder2:"var(--colorStatusWarningBorder2)",colorStatusDangerBackground1:"var(--colorStatusDangerBackground1)",colorStatusDangerBackground2:"var(--colorStatusDangerBackground2)",colorStatusDangerBackground3:"var(--colorStatusDangerBackground3)",colorStatusDangerForeground1:"var(--colorStatusDangerForeground1)",colorStatusDangerForeground2:"var(--colorStatusDangerForeground2)",colorStatusDangerForeground3:"var(--colorStatusDangerForeground3)",colorStatusDangerForegroundInverted:"var(--colorStatusDangerForegroundInverted)",colorStatusDangerBorderActive:"var(--colorStatusDangerBorderActive)",colorStatusDangerBorder1:"var(--colorStatusDangerBorder1)",colorStatusDangerBorder2:"var(--colorStatusDangerBorder2)",borderRadiusNone:"var(--borderRadiusNone)",borderRadiusSmall:"var(--borderRadiusSmall)",borderRadiusMedium:"var(--borderRadiusMedium)",borderRadiusLarge:"var(--borderRadiusLarge)",borderRadiusXLarge:"var(--borderRadiusXLarge)",borderRadiusCircular:"var(--borderRadiusCircular)",fontFamilyBase:"var(--fontFamilyBase)",fontFamilyMonospace:"var(--fontFamilyMonospace)",fontFamilyNumeric:"var(--fontFamilyNumeric)",fontSizeBase100:"var(--fontSizeBase100)",fontSizeBase200:"var(--fontSizeBase200)",fontSizeBase300:"var(--fontSizeBase300)",fontSizeBase400:"var(--fontSizeBase400)",fontSizeBase500:"var(--fontSizeBase500)",fontSizeBase600:"var(--fontSizeBase600)",fontSizeHero700:"var(--fontSizeHero700)",fontSizeHero800:"var(--fontSizeHero800)",fontSizeHero900:"var(--fontSizeHero900)",fontSizeHero1000:"var(--fontSizeHero1000)",fontWeightRegular:"var(--fontWeightRegular)",fontWeightMedium:"var(--fontWeightMedium)",fontWeightSemibold:"var(--fontWeightSemibold)",fontWeightBold:"var(--fontWeightBold)",lineHeightBase100:"var(--lineHeightBase100)",lineHeightBase200:"var(--lineHeightBase200)",lineHeightBase300:"var(--lineHeightBase300)",lineHeightBase400:"var(--lineHeightBase400)",lineHeightBase500:"var(--lineHeightBase500)",lineHeightBase600:"var(--lineHeightBase600)",lineHeightHero700:"var(--lineHeightHero700)",lineHeightHero800:"var(--lineHeightHero800)",lineHeightHero900:"var(--lineHeightHero900)",lineHeightHero1000:"var(--lineHeightHero1000)",shadow2:"var(--shadow2)",shadow4:"var(--shadow4)",shadow8:"var(--shadow8)",shadow16:"var(--shadow16)",shadow28:"var(--shadow28)",shadow64:"var(--shadow64)",shadow2Brand:"var(--shadow2Brand)",shadow4Brand:"var(--shadow4Brand)",shadow8Brand:"var(--shadow8Brand)",shadow16Brand:"var(--shadow16Brand)",shadow28Brand:"var(--shadow28Brand)",shadow64Brand:"var(--shadow64Brand)",strokeWidthThin:"var(--strokeWidthThin)",strokeWidthThick:"var(--strokeWidthThick)",strokeWidthThicker:"var(--strokeWidthThicker)",strokeWidthThickest:"var(--strokeWidthThickest)",spacingHorizontalNone:"var(--spacingHorizontalNone)",spacingHorizontalXXS:"var(--spacingHorizontalXXS)",spacingHorizontalXS:"var(--spacingHorizontalXS)",spacingHorizontalSNudge:"var(--spacingHorizontalSNudge)",spacingHorizontalS:"var(--spacingHorizontalS)",spacingHorizontalMNudge:"var(--spacingHorizontalMNudge)",spacingHorizontalM:"var(--spacingHorizontalM)",spacingHorizontalL:"var(--spacingHorizontalL)",spacingHorizontalXL:"var(--spacingHorizontalXL)",spacingHorizontalXXL:"var(--spacingHorizontalXXL)",spacingHorizontalXXXL:"var(--spacingHorizontalXXXL)",spacingVerticalNone:"var(--spacingVerticalNone)",spacingVerticalXXS:"var(--spacingVerticalXXS)",spacingVerticalXS:"var(--spacingVerticalXS)",spacingVerticalSNudge:"var(--spacingVerticalSNudge)",spacingVerticalS:"var(--spacingVerticalS)",spacingVerticalMNudge:"var(--spacingVerticalMNudge)",spacingVerticalM:"var(--spacingVerticalM)",spacingVerticalL:"var(--spacingVerticalL)",spacingVerticalXL:"var(--spacingVerticalXL)",spacingVerticalXXL:"var(--spacingVerticalXXL)",spacingVerticalXXXL:"var(--spacingVerticalXXXL)",durationUltraFast:"var(--durationUltraFast)",durationFaster:"var(--durationFaster)",durationFast:"var(--durationFast)",durationNormal:"var(--durationNormal)",durationGentle:"var(--durationGentle)",durationSlow:"var(--durationSlow)",durationSlower:"var(--durationSlower)",durationUltraSlow:"var(--durationUltraSlow)",curveAccelerateMax:"var(--curveAccelerateMax)",curveAccelerateMid:"var(--curveAccelerateMid)",curveAccelerateMin:"var(--curveAccelerateMin)",curveDecelerateMax:"var(--curveDecelerateMax)",curveDecelerateMid:"var(--curveDecelerateMid)",curveDecelerateMin:"var(--curveDecelerateMin)",curveEasyEaseMax:"var(--curveEasyEaseMax)",curveEasyEase:"var(--curveEasyEase)",curveLinear:"var(--curveLinear)"}},94270:function(e,t,i){"use strict";function n(e){}i.d(t,{a:function(){return n}}),i(8559)},35190:function(e,t,i){"use strict";i.d(t,{A:function(){return n},v:function(){return o}});const n=Symbol("fui.slotRenderFunction"),o=Symbol("fui.slotElementType")},54194:function(e,t,i){"use strict";i.d(t,{h:function(){return v}}),i(8559);const n=(...e)=>{const t={};for(const i of e){const e=Array.isArray(i)?i:Object.keys(i);for(const i of e)t[i]=1}return t},o=n(["onAuxClick","onAnimationEnd","onAnimationStart","onCopy","onCut","onPaste","onCompositionEnd","onCompositionStart","onCompositionUpdate","onFocus","onFocusCapture","onBlur","onBlurCapture","onChange","onInput","onSubmit","onLoad","onError","onKeyDown","onKeyDownCapture","onKeyPress","onKeyUp","onAbort","onCanPlay","onCanPlayThrough","onDurationChange","onEmptied","onEncrypted","onEnded","onLoadedData","onLoadedMetadata","onLoadStart","onPause","onPlay","onPlaying","onProgress","onRateChange","onSeeked","onSeeking","onStalled","onSuspend","onTimeUpdate","onVolumeChange","onWaiting","onClick","onClickCapture","onContextMenu","onDoubleClick","onDrag","onDragEnd","onDragEnter","onDragExit","onDragLeave","onDragOver","onDragStart","onDrop","onMouseDown","onMouseDownCapture","onMouseEnter","onMouseLeave","onMouseMove","onMouseOut","onMouseOver","onMouseUp","onMouseUpCapture","onSelect","onTouchCancel","onTouchEnd","onTouchMove","onTouchStart","onScroll","onWheel","onPointerCancel","onPointerDown","onPointerEnter","onPointerLeave","onPointerMove","onPointerOut","onPointerOver","onPointerUp","onGotPointerCapture","onLostPointerCapture"]),r=n(["accessKey","children","className","contentEditable","dir","draggable","hidden","htmlFor","id","lang","ref","role","style","tabIndex","title","translate","spellCheck","name"]),a=n(["itemID","itemProp","itemRef","itemScope","itemType"]),s=n(r,o,a),l=n(s,["form"]),c=n(s,["height","loop","muted","preload","src","width"]),d=n(c,["poster"]),u=n(s,["start"]),h=n(s,["value"]),p=n(s,["download","href","hrefLang","media","rel","target","type"]),g=n(s,["dateTime"]),f=n(s,["autoFocus","disabled","form","formAction","formEncType","formMethod","formNoValidate","formTarget","type","value"]),m={label:l,audio:c,video:d,ol:u,li:h,a:p,button:f,input:n(f,["accept","alt","autoCapitalize","autoComplete","checked","dirname","form","height","inputMode","list","max","maxLength","min","multiple","pattern","placeholder","readOnly","required","src","step","size","type","value","width"]),textarea:n(f,["autoCapitalize","cols","dirname","form","maxLength","placeholder","readOnly","required","rows","wrap"]),select:n(f,["form","multiple","required"]),option:n(s,["selected","value"]),table:n(s,["cellPadding","cellSpacing"]),tr:s,th:n(s,["colSpan","rowSpan","scope"]),td:n(s,["colSpan","headers","rowSpan","scope"]),colGroup:n(s,["span"]),col:n(s,["span"]),fieldset:n(s,["disabled","form"]),form:n(s,["acceptCharset","action","encType","encType","method","noValidate","target"]),iframe:n(s,["allow","allowFullScreen","allowPaymentRequest","allowTransparency","csp","height","importance","referrerPolicy","sandbox","src","srcDoc","width"]),img:n(s,["alt","crossOrigin","height","src","srcSet","useMap","width"]),time:g,dialog:n(s,["open","onCancel","onClose"])};const v=(e,t,i)=>{var n;return function(e,t,i){const n=e&&m[e]||s;return n.as=1,function(e,t,i){const n=Array.isArray(t),o={},r=Object.keys(e);for(const a of r)!(!n&&t[a]||n&&t.indexOf(a)>=0||0===a.indexOf("data-")||0===a.indexOf("aria-"))||i&&-1!==(null==i?void 0:i.indexOf(a))||(o[a]=e[a]);return o}(t,n,i)}(null!==(n=t.as)&&void 0!==n?n:e,t,i)}},58092:function(e,t,i){"use strict";i.d(t,{Bx:function(){return r},jt:function(){return a}});var n=i(8559),o=i(35190);function r(e,t){const{defaultProps:i,elementType:r}=t,a=function(e){return"string"==typeof e||"number"==typeof e||Array.isArray(e)||n.isValidElement(e)?{children:e}:e}(e),s={...i,...a,[o.v]:r};return a&&"function"==typeof a.children&&(s[o.A]=a.children,s.children=null==i?void 0:i.children),s}function a(e,t){if(null!==e&&(void 0!==e||t.renderByDefault))return r(e,t)}},11122:function(e,t,i){"use strict";i.d(t,{T:function(){return o}});var n=i(8559);const o=e=>{const[t,i]=n.useState((()=>void 0===e.defaultState?e.initialState:"function"==typeof e.defaultState?e.defaultState():e.defaultState)),o=n.useRef(e.state);n.useEffect((()=>{o.current=e.state}),[e.state]);const a=n.useCallback((e=>{(function(e){return"function"==typeof e})(e)&&e(o.current)}),[]);return r(e.state)?[e.state,a]:[t,i]},r=e=>{const[t]=n.useState((()=>void 0!==e));return t}},32384:function(e,t,i){"use strict";i.d(t,{$:function(){return r}});var n=i(8559),o=i(38283);const r=e=>{const t=n.useRef((()=>{throw new Error("Cannot call an event handler while rendering")}));return(0,o.L)((()=>{t.current=e}),[e]),n.useCallback(((...e)=>(0,t.current)(...e)),[t])}},29924:function(e,t,i){"use strict";var n;i.d(t,{Me:function(){return s}});var o=i(8559),r=i(61068);const a=o.createContext(void 0);function s(e="fui-",t){const s=(0,r.Zq)(),l=o.useContext(a)||"",c=(n||(n=i.t(o,2))).useId;if(c){const i=c(),n=o.useMemo((()=>i.replace(/:/g,"")),[i]);return t||`${l}${e}${n}`}return o.useMemo((()=>t||`${l}${e}${++s.current}`),[l,e,t,s])}a.Provider},38283:function(e,t,i){"use strict";i.d(t,{L:function(){return o}});var n=i(8559);const o=(0,i(90100).N)()?n.useLayoutEffect:n.useEffect},32535:function(e,t,i){"use strict";i.d(t,{r:function(){return o}});var n=i(8559);function o(...e){const t=n.useCallback((i=>{t.current=i;for(const t of e)"function"==typeof t?t(i):t&&(t.current=i)}),[...e]);return t}},61068:function(e,t,i){"use strict";i.d(t,{Av:function(){return l},Zq:function(){return s}});var n=i(8559),o=i(90100);const r={current:0},a=n.createContext(void 0);function s(){var e;return null!==(e=n.useContext(a))&&void 0!==e?e:r}function l(){const e=s()!==r,[t,i]=n.useState(e);return(0,o.N)()&&e&&n.useLayoutEffect((()=>{i(!1)}),[]),t}},90100:function(e,t,i){"use strict";function n(){return"undefined"!=typeof window&&!(!window.document||!window.document.createElement)}i.d(t,{N:function(){return n}})},82142:function(e,t,i){"use strict";i.d(t,{a:function(){return r}});var n=i(8559),o=i(21547);function r(e,t){return"function"==typeof e?e(t):e?a(e,t):e||null}function a(e,t){if(!n.isValidElement(e)||e.type===n.Fragment)throw new Error("A trigger element must be a single element for this component. Please ensure that you're not using React Fragments.");if((0,o.G)(e)){const i=a(e.props.children,t);return n.cloneElement(e,void 0,i)}return n.cloneElement(e,t)}},48628:function(e,t,i){"use strict";i.d(t,{W:function(){return r}});var n=i(8559),o=i(21547);function r(e){return n.isValidElement(e)?(0,o.G)(e)?r(e.props.children):e:null}},21547:function(e,t,i){"use strict";function n(e){return Boolean(e.type.isFluentTriggerComponent)}i.d(t,{G:function(){return n}}),i(8559)},96568:function(e,t,i){"use strict";function n(e,t){var i;const n=e;var o;return Boolean((null==n||null===(i=n.ownerDocument)||void 0===i?void 0:i.defaultView)&&n instanceof n.ownerDocument.defaultView[null!==(o=null==t?void 0:t.constructorName)&&void 0!==o?o:"HTMLElement"])}i.d(t,{R:function(){return n}})},70617:function(e,t,i){"use strict";function n(e,t){return(...i)=>{null==e||e(...i),null==t||t(...i)}}i.d(t,{E:function(){return n}})},6205:function(e,t,i){"use strict";i.d(t,{v:function(){return f}});var n,o=i(63375),r=i(37328),a=i(3179),s=i(5302),l=i(58168);function c(e,t,i){return isNaN(e)||e<=0?t:e>=1?i:new s.h((0,o.t7)(e,t.r,i.r),(0,o.t7)(e,t.g,i.g),(0,o.t7)(e,t.b,i.b),(0,o.t7)(e,t.a,i.a))}!function(e){e[e.RGB=0]="RGB",e[e.HSL=1]="HSL",e[e.HSV=2]="HSV",e[e.XYZ=3]="XYZ",e[e.LAB=4]="LAB",e[e.LCH=5]="LCH"}(n||(n={}));var d=i(79385);function u(e,t,i=0,n=e.length-1){if(n===i)return e[i];const o=Math.floor((n-i)/2)+i;return t(e[o])?u(e,t,i,o):u(e,t,o+1,n)}var h=i(79077),p=i(91069);const g={stepContrast:1.03,stepContrastRamp:.03,preserveSource:!1},f=Object.freeze({create:function(e,t,i){return"number"==typeof e?f.from(d.w.create(e,t,i)):f.from(e)},from:function(e,t){return(0,d.m)(e)?m.from(e,t):m.from(d.w.create(e.r,e.g,e.b),t)}});class m{constructor(e,t){this.closestIndexCache=new Map,this.source=e,this.swatches=t,this.reversedSwatches=Object.freeze([...this.swatches].reverse()),this.lastIndex=this.swatches.length-1}colorContrast(e,t,i,n){void 0===i&&(i=this.closestIndexOf(e));let o=this.swatches;const r=this.lastIndex;let a=i;return void 0===n&&(n=(0,h.a)(e)),-1===n&&(o=this.reversedSwatches,a=r-a),u(o,(i=>(0,p.$)(e,i)>=t),a,r)}get(e){return this.swatches[e]||this.swatches[(0,o.uZ)(e,0,this.lastIndex)]}closestIndexOf(e){if(this.closestIndexCache.has(e.relativeLuminance))return this.closestIndexCache.get(e.relativeLuminance);let t=this.swatches.indexOf(e);if(-1!==t)return this.closestIndexCache.set(e.relativeLuminance,t),t;const i=this.swatches.reduce(((t,i)=>Math.abs(i.relativeLuminance-e.relativeLuminance)<Math.abs(t.relativeLuminance-e.relativeLuminance)?i:t));return t=this.swatches.indexOf(i),this.closestIndexCache.set(e.relativeLuminance,t),t}static saturationBump(e,t){const i=(0,r.lw)(e).s,n=(0,r.lw)(t);if(n.s<i){const e=new a.H(n.h,i,n.l);return(0,r.hP)(e)}return t}static ramp(e){const t=e/100;return t>.5?(t-.5)/.5:2*t}static createHighResolutionPalette(e){const t=[],i=(0,r.v1)(s.h.fromObject(e).roundToPrecision(4)),n=(0,r.DR)(new l.R(0,i.a,i.b)).clamp().roundToPrecision(4),o=(0,r.DR)(new l.R(50,i.a,i.b)).clamp().roundToPrecision(4),a=(0,r.DR)(new l.R(100,i.a,i.b)).clamp().roundToPrecision(4),u=new s.h(0,0,0),h=new s.h(1,1,1),p=a.equalValue(h)?0:14,g=n.equalValue(u)?0:14;for(let e=100+p;e>=0-g;e-=.5){let i;i=e<0?c(e/g+1,u,n):e<=50?c(m.ramp(e),n,o):e<=100?c(m.ramp(e),o,a):c((e-100)/p,a,h),i=m.saturationBump(o,i).roundToPrecision(4),t.push(d.w.from(i))}return new m(e,t)}static adjustEnd(e,t,i,n){const r=-1===n?t.swatches:t.reversedSwatches,a=e=>{const i=t.closestIndexOf(e);return 1===n?t.lastIndex-i:i};1===n&&i.reverse();const s=e(i[i.length-2]);if((0,o.fZ)((0,p.$)(i[i.length-1],i[i.length-2]),2)<s){i.pop();const e=a(t.colorContrast(r[t.lastIndex],s,void 0,n))-a(i[i.length-2]);let o=1;for(let n=i.length-e-1;n<i.length;n++){const e=a(i[n]),s=n===i.length-1?t.lastIndex:e+o;i[n]=r[s],o++}}1===n&&i.reverse()}static createColorPaletteByContrast(e,t){const i=m.createHighResolutionPalette(e),n=e=>{const i=t.stepContrast+t.stepContrast*(1-e.relativeLuminance)*t.stepContrastRamp;return(0,o.fZ)(i,2)},r=[];let a=t.preserveSource?e:i.swatches[0];r.push(a);do{const e=n(a);a=i.colorContrast(a,e,void 0,1),r.push(a)}while(a.relativeLuminance>0);if(t.preserveSource){a=e;do{const e=n(a);a=i.colorContrast(a,e,void 0,-1),r.unshift(a)}while(a.relativeLuminance<1)}return this.adjustEnd(n,i,r,-1),t.preserveSource&&this.adjustEnd(n,i,r,1),r}static from(e,t){const i=void 0===t?g:Object.assign(Object.assign({},g),t);return new m(e,Object.freeze(m.createColorPaletteByContrast(e,i)))}}},79385:function(e,t,i){"use strict";i.d(t,{m:function(){return s},w:function(){return a}});var n=i(5302),o=i(37328),r=i(91069);const a=Object.freeze({create(e,t,i){return new l(e,t,i)},from(e){return new l(e.r,e.g,e.b)}});function s(e){const t={r:0,g:0,b:0,toColorString:()=>"",contrast:()=>0,relativeLuminance:0};for(const i in t)if(typeof t[i]!=typeof e[i])return!1;return!0}class l extends n.h{constructor(e,t,i){super(e,t,i,1),this.toColorString=this.toStringHexRGB,this.contrast=r.$.bind(null,this),this.createCSS=this.toColorString,this.relativeLuminance=(0,o.hM)(this)}static fromObject(e){return new l(e.r,e.g,e.b)}}},53752:function(e,t,i){"use strict";i.d(t,{C:function(){return r},h:function(){return n}});var n,o=i(79385);function r(e){return o.w.create(e,e,e)}!function(e){e[e.LightMode=.98]="LightMode",e[e.DarkMode=.15]="DarkMode"}(n||(n={}))},79077:function(e,t,i){"use strict";i.d(t,{a:function(){return o}});var n=i(47212);function o(e){return(0,n._)(e)?-1:1}},47212:function(e,t,i){"use strict";i.d(t,{_:function(){return o}});const n=(-.1+Math.sqrt(.21))/2;function o(e){return e.relativeLuminance<=n}},91069:function(e,t,i){"use strict";function n(e,t){const i=e.relativeLuminance>t.relativeLuminance?e:t,n=e.relativeLuminance>t.relativeLuminance?t:e;return(i.relativeLuminance+.05)/(n.relativeLuminance+.05)}i.d(t,{$:function(){return n}})},23026:function(e,t,i){"use strict";i.d(t,{R6v:function(){return yt},UEO:function(){return Nt},Woc:function(){return Se},v$0:function(){return xe},OCG:function(){return _t},B23:function(){return be},Avx:function(){return Dt},N7s:function(){return Ce},VNr:function(){return Zt},kb6:function(){return Oe},ndN:function(){return Pe},D9J:function(){return $t},L8d:function(){return we},goi:function(){return Ht},kpA:function(){return Te},oi3:function(){return zt},fbQ:function(){return jt},z0S:function(){return Gt},nfe:function(){return R},LQ3:function(){return M},q2d:function(){return ye},SVJ:function(){return Z},UWU:function(){return F},hVk:function(){return L},_5n:function(){return B},o7V:function(){return _},VFZ:function(){return N},IfY:function(){return Et},a2F:function(){return Ki},yGg:function(){return zi},vxp:function(){return $},PpH:function(){return Ft},lJV:function(){return Bt},w41:function(){return Lt},rSr:function(){return U},aIT:function(){return mt},Gy2:function(){return Yt},hDF:function(){return ke},VQw:function(){return Ie},XiB:function(){return qt},jWw:function(){return Ee},q_p:function(){return Ne},bWE:function(){return oi},W3V:function(){return ri},vFq:function(){return ni},pB6:function(){return ii},rFm:function(){return ei},Zbo:function(){return Re},Tm7:function(){return Qt},EL3:function(){return _e},smF:function(){return Xt},_Bj:function(){return Jt},efx:function(){return De},Y5u:function(){return ci},abR:function(){return ai},RJY:function(){return si},YL4:function(){return Ue},wFS:function(){return Kt},MYN:function(){return Ae},_ii:function(){return pi},KTo:function(){return gi},d$x:function(){return hi},TuC:function(){return di},_jX:function(){return ui},sG3:function(){return yi},gs2:function(){return qe},s0z:function(){return Ci},IU$:function(){return Ye},QpD:function(){return vi},fqe:function(){return Ke},DFW:function(){return fi},jql:function(){return mi},qDs:function(){return We},Vt5:function(){return Qe},UCF:function(){return et},sc1:function(){return Je},Ttg:function(){return Ti},Q5n:function(){return Oi},axZ:function(){return wi},CHi:function(){return xi},s55:function(){return xt},yvm:function(){return vt},c1L:function(){return ki},IMz:function(){return nt},_ro:function(){return Ni},xBI:function(){return _i},U_Q:function(){return Di},dtw:function(){return Mi},hD7:function(){return ct},Bxy:function(){return ot},QPc:function(){return Ei},rnN:function(){return it},zt3:function(){return Fi},iAs:function(){return Bi},Ja_:function(){return Hi},akT:function(){return Ai},fd1:function(){return tt},ekh:function(){return Gi},gKw:function(){return Vi},rU8:function(){return Zi},Han:function(){return H},cSu:function(){return j},Ww_:function(){return W},RUt:function(){return z},sNp:function(){return K},FMB:function(){return Y},vgC:function(){return q},G8g:function(){return X},Tp7:function(){return Q},MwG:function(){return J},PwC:function(){return ee},GQL:function(){return ie},b3W:function(){return te},mWK:function(){return ne},YQw:function(){return re},I7_:function(){return oe},ipv:function(){return ae},pqD:function(){return le},yGZ:function(){return se},IWd:function(){return ce},SZp:function(){return ue},iL4:function(){return de},CXZ:function(){return he},NIE:function(){return ge},n5T:function(){return pe},Zaf:function(){return fe},dm2:function(){return ve},yDy:function(){return me}});var n,o=i(11127);!function(e){e.ltr="ltr",e.rtl="rtl"}(n||(n={}));var r=i(6205),a=i(77158),s=i(79385);const l=s.w.create(1,1,1),c=s.w.create(0,0,0),d=s.w.create(.5,.5,.5),u=(0,a.in)("#0078D4"),h=s.w.create(u.r,u.g,u.b);function p(e,t,i,n,o){const r=e=>e.contrast(l)>=o?l:c,a=r(e),s=r(t);return{rest:a,hover:s,active:a.relativeLuminance===s.relativeLuminance?a:r(i),focus:r(n)}}var g,f=i(5302),m=i(37328);!function(e){e[e.Burn=0]="Burn",e[e.Color=1]="Color",e[e.Darken=2]="Darken",e[e.Dodge=3]="Dodge",e[e.Lighten=4]="Lighten",e[e.Multiply=5]="Multiply",e[e.Overlay=6]="Overlay",e[e.Screen=7]="Screen"}(g||(g={}));var v=i(79077),y=i(91069);class C{constructor(e,t,i,n){this.toColorString=()=>this.cssGradient,this.contrast=y.$.bind(null,this),this.createCSS=this.toColorString,this.color=new f.h(e,t,i),this.cssGradient=n,this.relativeLuminance=(0,m.hM)(this.color),this.r=e,this.g=t,this.b=i}static fromObject(e,t){return new C(e.r,e.g,e.b,t)}}const b=new f.h(0,0,0),S=new f.h(1,1,1);function x(e,t,i,n,o,r,l,c,d=10,u=!1){const h=e.closestIndexOf(t);function p(i){if(u){const n=e.closestIndexOf(t),o=e.get(n),r=i.relativeLuminance<t.relativeLuminance?b:S,l=(0,m.PJ)((0,a.in)(i.toColorString()),(0,a.in)(o.toColorString()),r).roundToPrecision(2),c=function(e,t){if(t.a>=1)return t;if(t.a<=0)return new f.h(e.r,e.g,e.b,1);const i=t.a*t.r+(1-t.a)*e.r,n=t.a*t.g+(1-t.a)*e.g,o=t.a*t.b+(1-t.a)*e.b;return new f.h(i,n,o,1)}((0,a.in)(t.toColorString()),l);return s.w.from(c)}return i}void 0===c&&(c=(0,v.a)(t));const g=h+c*i,y=g+c*(n-i),x=g+c*(o-i),T=g+c*(r-i),w=-1===c?0:100-d,O=-1===c?d:100;function P(t,i){const n=e.get(t);if(i){const i=e.get(t+c*l),o=-1===c?i:n,r=-1===c?n:i,a=`linear-gradient(${p(o).toColorString()} ${w}%, ${p(r).toColorString()} ${O}%)`;return C.fromObject(o,a)}return p(n)}return{rest:P(g,!0),hover:P(y,!0),active:P(x,!1),focus:P(T,!0)}}var T=i(47212);function w(e,t,i,n,o,r,a,s){null==s&&(s=(0,v.a)(t));const l=e.closestIndexOf(e.colorContrast(t,i));return{rest:e.get(l+s*n),hover:e.get(l+s*o),active:e.get(l+s*r),focus:e.get(l+s*a)}}function O(e,t,i,n,o,r,a){const s=e.closestIndexOf(t);return null==a&&(a=(0,v.a)(t)),{rest:e.get(s+a*i),hover:e.get(s+a*n),active:e.get(s+a*o),focus:e.get(s+a*r)}}function P(e,t,i,n,o,r,a=void 0,s,l,c,d,u=void 0){return(0,T._)(t)?O(e,t,s,l,c,d,u):O(e,t,i,n,o,r,a)}var A=i(53752);function E(e,t){return e.closestIndexOf((0,A.C)(t))}function k(e,t,i){return e.get(E(e,t)+-1*i)}const{create:I}=o.DesignToken;function D(e){return o.DesignToken.create({name:e,cssCustomPropertyName:null})}const _=I("direction").withDefault(n.ltr),N=I("disabled-opacity").withDefault(.3),R=I("base-height-multiplier").withDefault(8),M=I("base-horizontal-spacing-multiplier").withDefault(3),L=I("density").withDefault(0),B=I("design-unit").withDefault(4),F=I("control-corner-radius").withDefault(4),U=I("layer-corner-radius").withDefault(8),H=I("stroke-width").withDefault(1),$=I("focus-stroke-width").withDefault(2),Z=I("body-font").withDefault('"Segoe UI Variable", "Segoe UI", sans-serif'),V=I("font-weight").withDefault(400);function G(e){return t=>{const i=e.getValueFor(t),n=V.getValueFor(t);if(i.endsWith("px")){const e=Number.parseFloat(i.replace("px",""));if(e<=12)return`"wght" ${n}, "opsz" 8`;if(e>24)return`"wght" ${n}, "opsz" 36`}return`"wght" ${n}, "opsz" 10.5`}}const j=I("type-ramp-base-font-size").withDefault("14px"),z=I("type-ramp-base-line-height").withDefault("20px"),W=I("type-ramp-base-font-variations").withDefault(G(j)),K=I("type-ramp-minus-1-font-size").withDefault("12px"),q=I("type-ramp-minus-1-line-height").withDefault("16px"),Y=I("type-ramp-minus-1-font-variations").withDefault(G(K)),X=I("type-ramp-minus-2-font-size").withDefault("10px"),J=I("type-ramp-minus-2-line-height").withDefault("14px"),Q=I("type-ramp-minus-2-font-variations").withDefault(G(X)),ee=I("type-ramp-plus-1-font-size").withDefault("16px"),te=I("type-ramp-plus-1-line-height").withDefault("22px"),ie=I("type-ramp-plus-1-font-variations").withDefault(G(ee)),ne=I("type-ramp-plus-2-font-size").withDefault("20px"),oe=I("type-ramp-plus-2-line-height").withDefault("26px"),re=I("type-ramp-plus-2-font-variations").withDefault(G(ne)),ae=I("type-ramp-plus-3-font-size").withDefault("24px"),se=I("type-ramp-plus-3-line-height").withDefault("32px"),le=I("type-ramp-plus-3-font-variations").withDefault(G(ae)),ce=I("type-ramp-plus-4-font-size").withDefault("28px"),de=I("type-ramp-plus-4-line-height").withDefault("36px"),ue=I("type-ramp-plus-4-font-variations").withDefault(G(ce)),he=I("type-ramp-plus-5-font-size").withDefault("32px"),pe=I("type-ramp-plus-5-line-height").withDefault("40px"),ge=I("type-ramp-plus-5-font-variations").withDefault(G(he)),fe=I("type-ramp-plus-6-font-size").withDefault("40px"),me=I("type-ramp-plus-6-line-height").withDefault("52px"),ve=I("type-ramp-plus-6-font-variations").withDefault(G(fe)),ye=I("base-layer-luminance").withDefault(A.h.LightMode),Ce=D("accent-fill-rest-delta").withDefault(0),be=D("accent-fill-hover-delta").withDefault(-2),Se=D("accent-fill-active-delta").withDefault(-5),xe=D("accent-fill-focus-delta").withDefault(0),Te=D("accent-foreground-rest-delta").withDefault(0),we=D("accent-foreground-hover-delta").withDefault(3),Oe=D("accent-foreground-active-delta").withDefault(-8),Pe=D("accent-foreground-focus-delta").withDefault(0),Ae=D("neutral-fill-rest-delta").withDefault(-1),Ee=D("neutral-fill-hover-delta").withDefault(1),ke=D("neutral-fill-active-delta").withDefault(0),Ie=D("neutral-fill-focus-delta").withDefault(0),De=D("neutral-fill-input-rest-delta").withDefault(-1),_e=D("neutral-fill-input-hover-delta").withDefault(1),Ne=D("neutral-fill-input-active-delta").withDefault(0),Re=D("neutral-fill-input-focus-delta").withDefault(-2),Me=D("neutral-fill-input-alt-rest-delta").withDefault(2),Le=D("neutral-fill-input-alt-hover-delta").withDefault(4),Be=D("neutral-fill-input-alt-active-delta").withDefault(6),Fe=D("neutral-fill-input-alt-focus-delta").withDefault(2),Ue=D("neutral-fill-layer-rest-delta").withDefault(-2),He=D("neutral-fill-layer-hover-delta").withDefault(-3),$e=D("neutral-fill-layer-active-delta").withDefault(-3),Ze=D("neutral-fill-layer-alt-rest-delta").withDefault(-1),Ve=D("neutral-fill-secondary-rest-delta").withDefault(3),Ge=D("neutral-fill-secondary-hover-delta").withDefault(2),je=D("neutral-fill-secondary-active-delta").withDefault(1),ze=D("neutral-fill-secondary-focus-delta").withDefault(3),We=D("neutral-fill-stealth-rest-delta").withDefault(0),Ke=D("neutral-fill-stealth-hover-delta").withDefault(3),qe=D("neutral-fill-stealth-active-delta").withDefault(2),Ye=D("neutral-fill-stealth-focus-delta").withDefault(0),Xe=D("neutral-fill-strong-rest-delta").withDefault(0),Je=D("neutral-fill-strong-hover-delta").withDefault(8),Qe=D("neutral-fill-strong-active-delta").withDefault(-5),et=D("neutral-fill-strong-focus-delta").withDefault(0),tt=D("neutral-stroke-rest-delta").withDefault(8),it=D("neutral-stroke-hover-delta").withDefault(12),nt=D("neutral-stroke-active-delta").withDefault(6),ot=D("neutral-stroke-focus-delta").withDefault(8),rt=D("neutral-stroke-control-rest-delta").withDefault(3),at=D("neutral-stroke-control-hover-delta").withDefault(5),st=D("neutral-stroke-control-active-delta").withDefault(5),lt=D("neutral-stroke-control-focus-delta").withDefault(5),ct=D("neutral-stroke-divider-rest-delta").withDefault(4),dt=D("neutral-stroke-layer-rest-delta").withDefault(3),ut=D("neutral-stroke-layer-hover-delta").withDefault(3),ht=D("neutral-stroke-layer-active-delta").withDefault(3),pt=D("neutral-stroke-strong-hover-delta").withDefault(0),gt=D("neutral-stroke-strong-active-delta").withDefault(0),ft=D("neutral-stroke-strong-focus-delta").withDefault(0),mt=I("neutral-base-color").withDefault(d),vt=D("neutral-palette").withDefault((e=>r.v.from(mt.getValueFor(e)))),yt=I("accent-base-color").withDefault(h),Ct=D("accent-palette").withDefault((e=>r.v.from(yt.getValueFor(e)))),bt=D("neutral-layer-card-container-recipe").withDefault({evaluate:e=>k(vt.getValueFor(e),ye.getValueFor(e),Ue.getValueFor(e))}),St=(I("neutral-layer-card-container").withDefault((e=>bt.getValueFor(e).evaluate(e))),D("neutral-layer-floating-recipe").withDefault({evaluate:e=>function(e,t,i){return e.get(E(e,t)+i)}(vt.getValueFor(e),ye.getValueFor(e),Ue.getValueFor(e))})),xt=I("neutral-layer-floating").withDefault((e=>St.getValueFor(e).evaluate(e))),Tt=D("neutral-layer-1-recipe").withDefault({evaluate:e=>function(e,t){return e.get(E(e,t))}(vt.getValueFor(e),ye.getValueFor(e))}),wt=I("neutral-layer-1").withDefault((e=>Tt.getValueFor(e).evaluate(e))),Ot=D("neutral-layer-2-recipe").withDefault({evaluate:e=>k(vt.getValueFor(e),ye.getValueFor(e),Ue.getValueFor(e))}),Pt=(I("neutral-layer-2").withDefault((e=>Ot.getValueFor(e).evaluate(e))),D("neutral-layer-3-recipe").withDefault({evaluate:e=>function(e,t,i){return e.get(E(e,t)+-1*i*2)}(vt.getValueFor(e),ye.getValueFor(e),Ue.getValueFor(e))})),At=(I("neutral-layer-3").withDefault((e=>Pt.getValueFor(e).evaluate(e))),D("neutral-layer-4-recipe").withDefault({evaluate:e=>function(e,t,i){return e.get(E(e,t)+-1*i*3)}(vt.getValueFor(e),ye.getValueFor(e),Ue.getValueFor(e))})),Et=(I("neutral-layer-4").withDefault((e=>At.getValueFor(e).evaluate(e))),I("fill-color").withDefault((e=>wt.getValueFor(e))));var kt;!function(e){e[e.normal=4.5]="normal",e[e.large=3]="large"}(kt||(kt={}));const It=D("accent-fill-recipe").withDefault({evaluate:(e,t)=>function(e,t,i,n,o,r,a,s,l,c,d,u,h,p){return(0,T._)(t)?w(e,t,8,c,d,u,h,void 0):w(e,t,5,n,o,r,a,void 0)}(Ct.getValueFor(e),t||Et.getValueFor(e),0,Ce.getValueFor(e),be.getValueFor(e),Se.getValueFor(e),xe.getValueFor(e),0,0,Ce.getValueFor(e),be.getValueFor(e),Se.getValueFor(e),xe.getValueFor(e))}),Dt=I("accent-fill-rest").withDefault((e=>It.getValueFor(e).evaluate(e).rest)),_t=I("accent-fill-hover").withDefault((e=>It.getValueFor(e).evaluate(e).hover)),Nt=I("accent-fill-active").withDefault((e=>It.getValueFor(e).evaluate(e).active)),Rt=I("accent-fill-focus").withDefault((e=>It.getValueFor(e).evaluate(e).focus)),Mt=D("foreground-on-accent-recipe").withDefault({evaluate:e=>p(Dt.getValueFor(e),_t.getValueFor(e),Nt.getValueFor(e),Rt.getValueFor(e),kt.normal)}),Lt=I("foreground-on-accent-rest").withDefault((e=>Mt.getValueFor(e).evaluate(e).rest)),Bt=I("foreground-on-accent-hover").withDefault((e=>Mt.getValueFor(e).evaluate(e).hover)),Ft=I("foreground-on-accent-active").withDefault((e=>Mt.getValueFor(e).evaluate(e).active)),Ut=(I("foreground-on-accent-focus").withDefault((e=>Mt.getValueFor(e).evaluate(e).focus)),D("accent-foreground-recipe").withDefault({evaluate:(e,t)=>w(Ct.getValueFor(e),t||Et.getValueFor(e),9.5,Te.getValueFor(e),we.getValueFor(e),Oe.getValueFor(e),Pe.getValueFor(e))})),Ht=I("accent-foreground-rest").withDefault((e=>Ut.getValueFor(e).evaluate(e).rest)),$t=I("accent-foreground-hover").withDefault((e=>Ut.getValueFor(e).evaluate(e).hover)),Zt=I("accent-foreground-active").withDefault((e=>Ut.getValueFor(e).evaluate(e).active)),Vt=(I("accent-foreground-focus").withDefault((e=>Ut.getValueFor(e).evaluate(e).focus)),D("accent-stroke-control-recipe").withDefault({evaluate:(e,t)=>x(vt.getValueFor(e),t||Et.getValueFor(e),-3,-3,-3,-3,10,1,void 0,!0)})),Gt=I("accent-stroke-control-rest").withDefault((e=>Vt.getValueFor(e).evaluate(e,Dt.getValueFor(e)).rest)),jt=I("accent-stroke-control-hover").withDefault((e=>Vt.getValueFor(e).evaluate(e,_t.getValueFor(e)).hover)),zt=I("accent-stroke-control-active").withDefault((e=>Vt.getValueFor(e).evaluate(e,Nt.getValueFor(e)).active)),Wt=(I("accent-stroke-control-focus").withDefault((e=>Vt.getValueFor(e).evaluate(e,Rt.getValueFor(e)).focus)),D("neutral-fill-recipe").withDefault({evaluate:(e,t)=>P(vt.getValueFor(e),t||Et.getValueFor(e),Ae.getValueFor(e),Ee.getValueFor(e),ke.getValueFor(e),Ie.getValueFor(e),void 0,2,3,1,2,void 0)})),Kt=I("neutral-fill-rest").withDefault((e=>Wt.getValueFor(e).evaluate(e).rest)),qt=I("neutral-fill-hover").withDefault((e=>Wt.getValueFor(e).evaluate(e).hover)),Yt=I("neutral-fill-active").withDefault((e=>Wt.getValueFor(e).evaluate(e).active)),Xt=(I("neutral-fill-focus").withDefault((e=>Wt.getValueFor(e).evaluate(e).focus)),D("neutral-fill-input-recipe").withDefault({evaluate:(e,t)=>P(vt.getValueFor(e),t||Et.getValueFor(e),De.getValueFor(e),_e.getValueFor(e),Ne.getValueFor(e),Re.getValueFor(e),void 0,2,3,1,0,void 0)})),Jt=I("neutral-fill-input-rest").withDefault((e=>Xt.getValueFor(e).evaluate(e).rest)),Qt=I("neutral-fill-input-hover").withDefault((e=>Xt.getValueFor(e).evaluate(e).hover)),ei=(I("neutral-fill-input-active").withDefault((e=>Xt.getValueFor(e).evaluate(e).active)),I("neutral-fill-input-focus").withDefault((e=>Xt.getValueFor(e).evaluate(e).focus))),ti=D("neutral-fill-input-alt-recipe").withDefault({evaluate:(e,t)=>P(vt.getValueFor(e),t||Et.getValueFor(e),Me.getValueFor(e),Le.getValueFor(e),Be.getValueFor(e),Fe.getValueFor(e),1,Me.getValueFor(e),Me.getValueFor(e)-Le.getValueFor(e),Me.getValueFor(e)-Be.getValueFor(e),Fe.getValueFor(e),1)}),ii=I("neutral-fill-input-alt-rest").withDefault((e=>ti.getValueFor(e).evaluate(e).rest)),ni=I("neutral-fill-input-alt-hover").withDefault((e=>ti.getValueFor(e).evaluate(e).hover)),oi=I("neutral-fill-input-alt-active").withDefault((e=>ti.getValueFor(e).evaluate(e).active)),ri=I("neutral-fill-input-alt-focus").withDefault((e=>ti.getValueFor(e).evaluate(e).focus)),ai=D("neutral-fill-layer-recipe").withDefault({evaluate:(e,t)=>O(vt.getValueFor(e),t||Et.getValueFor(e),Ue.getValueFor(e),He.getValueFor(e),$e.getValueFor(e),Ue.getValueFor(e),1)}),si=I("neutral-fill-layer-rest").withDefault((e=>ai.getValueFor(e).evaluate(e).rest)),li=(I("neutral-fill-layer-hover").withDefault((e=>ai.getValueFor(e).evaluate(e).hover)),I("neutral-fill-layer-active").withDefault((e=>ai.getValueFor(e).evaluate(e).active)),D("neutral-fill-layer-alt-recipe").withDefault({evaluate:(e,t)=>O(vt.getValueFor(e),t||Et.getValueFor(e),Ze.getValueFor(e),Ze.getValueFor(e),Ze.getValueFor(e),Ze.getValueFor(e))})),ci=I("neutral-fill-layer-alt-rest").withDefault((e=>li.getValueFor(e).evaluate(e).rest)),di=D("neutral-fill-secondary-recipe").withDefault({evaluate:(e,t)=>O(vt.getValueFor(e),t||Et.getValueFor(e),Ve.getValueFor(e),Ge.getValueFor(e),je.getValueFor(e),ze.getValueFor(e))}),ui=I("neutral-fill-secondary-rest").withDefault((e=>di.getValueFor(e).evaluate(e).rest)),hi=I("neutral-fill-secondary-hover").withDefault((e=>di.getValueFor(e).evaluate(e).hover)),pi=I("neutral-fill-secondary-active").withDefault((e=>di.getValueFor(e).evaluate(e).active)),gi=I("neutral-fill-secondary-focus").withDefault((e=>di.getValueFor(e).evaluate(e).focus)),fi=D("neutral-fill-stealth-recipe").withDefault({evaluate:(e,t)=>O(vt.getValueFor(e),t||Et.getValueFor(e),We.getValueFor(e),Ke.getValueFor(e),qe.getValueFor(e),Ye.getValueFor(e))}),mi=I("neutral-fill-stealth-rest").withDefault((e=>fi.getValueFor(e).evaluate(e).rest)),vi=I("neutral-fill-stealth-hover").withDefault((e=>fi.getValueFor(e).evaluate(e).hover)),yi=I("neutral-fill-stealth-active").withDefault((e=>fi.getValueFor(e).evaluate(e).active)),Ci=I("neutral-fill-stealth-focus").withDefault((e=>fi.getValueFor(e).evaluate(e).focus)),bi=D("neutral-fill-strong-recipe").withDefault({evaluate:(e,t)=>w(vt.getValueFor(e),t||Et.getValueFor(e),4.5,Xe.getValueFor(e),Je.getValueFor(e),Qe.getValueFor(e),et.getValueFor(e))}),Si=(I("neutral-fill-strong-rest").withDefault((e=>bi.getValueFor(e).evaluate(e).rest)),I("neutral-fill-strong-hover").withDefault((e=>bi.getValueFor(e).evaluate(e).hover)),I("neutral-fill-strong-active").withDefault((e=>bi.getValueFor(e).evaluate(e).active)),I("neutral-fill-strong-focus").withDefault((e=>bi.getValueFor(e).evaluate(e).focus)),D("neutral-foreground-recipe").withDefault({evaluate:(e,t)=>w(vt.getValueFor(e),t||Et.getValueFor(e),16,0,-19,-30,0)})),xi=I("neutral-foreground-rest").withDefault((e=>Si.getValueFor(e).evaluate(e).rest)),Ti=(I("neutral-foreground-hover").withDefault((e=>Si.getValueFor(e).evaluate(e).hover)),I("neutral-foreground-active").withDefault((e=>Si.getValueFor(e).evaluate(e).active))),wi=(I("neutral-foreground-focus").withDefault((e=>Si.getValueFor(e).evaluate(e).focus)),D("neutral-foreground-hint-recipe").withDefault({evaluate:(e,t)=>function(e,t,i){return e.colorContrast(t,4.5)}(vt.getValueFor(e),t||Et.getValueFor(e))})),Oi=I("neutral-foreground-hint").withDefault((e=>wi.getValueFor(e).evaluate(e))),Pi=D("neutral-stroke-recipe").withDefault({evaluate:(e,t)=>O(vt.getValueFor(e),t||Et.getValueFor(e),tt.getValueFor(e),it.getValueFor(e),nt.getValueFor(e),ot.getValueFor(e))}),Ai=I("neutral-stroke-rest").withDefault((e=>Pi.getValueFor(e).evaluate(e).rest)),Ei=I("neutral-stroke-hover").withDefault((e=>Pi.getValueFor(e).evaluate(e).hover)),ki=I("neutral-stroke-active").withDefault((e=>Pi.getValueFor(e).evaluate(e).active)),Ii=(I("neutral-stroke-focus").withDefault((e=>Pi.getValueFor(e).evaluate(e).focus)),D("neutral-stroke-control-recipe").withDefault({evaluate:(e,t)=>x(vt.getValueFor(e),t||Et.getValueFor(e),rt.getValueFor(e),at.getValueFor(e),st.getValueFor(e),lt.getValueFor(e),5)})),Di=I("neutral-stroke-control-rest").withDefault((e=>Ii.getValueFor(e).evaluate(e).rest)),_i=I("neutral-stroke-control-hover").withDefault((e=>Ii.getValueFor(e).evaluate(e).hover)),Ni=I("neutral-stroke-control-active").withDefault((e=>Ii.getValueFor(e).evaluate(e).active)),Ri=(I("neutral-stroke-control-focus").withDefault((e=>Ii.getValueFor(e).evaluate(e).focus)),D("neutral-stroke-divider-recipe").withDefault({evaluate:(e,t)=>function(e,t,i){return e.get(e.closestIndexOf(t)+(0,v.a)(t)*i)}(vt.getValueFor(e),t||Et.getValueFor(e),ct.getValueFor(e))})),Mi=I("neutral-stroke-divider-rest").withDefault((e=>Ri.getValueFor(e).evaluate(e))),Li=D("neutral-stroke-input-recipe").withDefault({evaluate:(e,t)=>function(e,t,i,n,o,r,a,s){const l=e.closestIndexOf(t),c=(0,v.a)(t),d=l+c*i,u=d+c*(n-i),h=d+c*(o-i),p=d+c*(r-i),g=`calc(100% - ${s})`;function f(t,i){const n=e.get(t);if(i){const i=e.get(t+20*c),o=`linear-gradient(${n.toColorString()} ${g}, ${i.toColorString()} ${g}, ${i.toColorString()})`;return C.fromObject(n,o)}return n}return{rest:f(d,!0),hover:f(u,!0),active:f(h,!1),focus:f(p,!0)}}(vt.getValueFor(e),t||Et.getValueFor(e),rt.getValueFor(e),at.getValueFor(e),st.getValueFor(e),lt.getValueFor(e),0,H.getValueFor(e)+"px")}),Bi=I("neutral-stroke-input-rest").withDefault((e=>Li.getValueFor(e).evaluate(e).rest)),Fi=I("neutral-stroke-input-hover").withDefault((e=>Li.getValueFor(e).evaluate(e).hover)),Ui=(I("neutral-stroke-input-active").withDefault((e=>Li.getValueFor(e).evaluate(e).active)),I("neutral-stroke-input-focus").withDefault((e=>Li.getValueFor(e).evaluate(e).focus)),D("neutral-stroke-layer-recipe").withDefault({evaluate:(e,t)=>O(vt.getValueFor(e),t||Et.getValueFor(e),dt.getValueFor(e),ut.getValueFor(e),ht.getValueFor(e),dt.getValueFor(e))})),Hi=I("neutral-stroke-layer-rest").withDefault((e=>Ui.getValueFor(e).evaluate(e).rest)),$i=(I("neutral-stroke-layer-hover").withDefault((e=>Ui.getValueFor(e).evaluate(e).hover)),I("neutral-stroke-layer-active").withDefault((e=>Ui.getValueFor(e).evaluate(e).active)),D("neutral-stroke-strong-recipe").withDefault({evaluate:(e,t)=>w(vt.getValueFor(e),t||Et.getValueFor(e),5.5,0,pt.getValueFor(e),gt.getValueFor(e),ft.getValueFor(e))})),Zi=I("neutral-stroke-strong-rest").withDefault((e=>$i.getValueFor(e).evaluate(e).rest)),Vi=I("neutral-stroke-strong-hover").withDefault((e=>$i.getValueFor(e).evaluate(e).hover)),Gi=I("neutral-stroke-strong-active").withDefault((e=>$i.getValueFor(e).evaluate(e).active)),ji=(I("neutral-stroke-strong-focus").withDefault((e=>$i.getValueFor(e).evaluate(e).focus)),D("focus-stroke-outer-recipe").withDefault({evaluate:e=>{return vt.getValueFor(e),t=Et.getValueFor(e),(0,T._)(t)?l:c;var t}})),zi=I("focus-stroke-outer").withDefault((e=>ji.getValueFor(e).evaluate(e))),Wi=D("focus-stroke-inner-recipe").withDefault({evaluate:e=>{return Ct.getValueFor(e),t=Et.getValueFor(e),zi.getValueFor(e),(0,T._)(t)?c:l;var t}}),Ki=I("focus-stroke-inner").withDefault((e=>Wi.getValueFor(e).evaluate(e))),qi=D("foreground-on-accent-large-recipe").withDefault({evaluate:e=>p(Dt.getValueFor(e),_t.getValueFor(e),Nt.getValueFor(e),Rt.getValueFor(e),kt.large)}),Yi=(I("foreground-on-accent-rest-large").withDefault((e=>qi.getValueFor(e).evaluate(e).rest)),I("foreground-on-accent-hover-large").withDefault((e=>qi.getValueFor(e).evaluate(e,_t.getValueFor(e)).hover)),I("foreground-on-accent-active-large").withDefault((e=>qi.getValueFor(e).evaluate(e,Nt.getValueFor(e)).active)),I("foreground-on-accent-focus-large").withDefault((e=>qi.getValueFor(e).evaluate(e,Rt.getValueFor(e)).focus)),I("neutral-fill-inverse-rest-delta").withDefault(0)),Xi=I("neutral-fill-inverse-hover-delta").withDefault(-3),Ji=I("neutral-fill-inverse-active-delta").withDefault(7),Qi=I("neutral-fill-inverse-focus-delta").withDefault(0),en=D("neutral-fill-inverse-recipe").withDefault({evaluate:(e,t)=>function(e,t,i,n,o,r){const a=(0,v.a)(t),s=e.closestIndexOf(e.colorContrast(t,14)),l=s+a*Math.abs(i-n);let c,d;return(1===a?i<n:a*i>a*n)?(c=s,d=l):(c=l,d=s),{rest:e.get(c),hover:e.get(d),active:e.get(c+a*o),focus:e.get(c+a*r)}}(vt.getValueFor(e),t||Et.getValueFor(e),Yi.getValueFor(e),Xi.getValueFor(e),Ji.getValueFor(e),Qi.getValueFor(e))});I("neutral-fill-inverse-rest").withDefault((e=>en.getValueFor(e).evaluate(e).rest)),I("neutral-fill-inverse-hover").withDefault((e=>en.getValueFor(e).evaluate(e).hover)),I("neutral-fill-inverse-active").withDefault((e=>en.getValueFor(e).evaluate(e).active)),I("neutral-fill-inverse-focus").withDefault((e=>en.getValueFor(e).evaluate(e).focus))},65538:function(e,t,i){"use strict";i.d(t,{s:function(){return r}});var n=i(12878),o=i(24456);function r(e,t,i=n.F){const r=i();let a=null,s=null;return function(i){const{dir:n,renderer:l}=i,c="ltr"===n;return c?null===a&&(a=(0,o.V)(e,n)):null===s&&(s=(0,o.V)(e,n)),r(l,t),c?a:s}}},73802:function(e,t,i){"use strict";i.d(t,{$Q:function(){return s},C_:function(){return f},Hf:function(){return l},JM:function(){return p},M_:function(){return u},Qz:function(){return d},de:function(){return g},gk:function(){return c},jD:function(){return h},xR:function(){return a}});const n="undefined"==typeof window?i.g:window,o="@griffel/";function r(e,t){return n[Symbol.for(o+e)]||(n[Symbol.for(o+e)]=t),n[Symbol.for(o+e)]}const a=r("DEFINITION_LOOKUP_TABLE",{}),s="data-make-styles-bucket",l="f",c=7,d="___",u="_",h=d.length+c,p=0,g=1,f={all:1,animation:1,background:1,backgroundPosition:1,border:1,borderBlock:1,borderBlockEnd:1,borderBlockStart:1,borderBottom:1,borderColor:1,borderImage:1,borderInline:1,borderInlineEnd:1,borderInlineStart:1,borderLeft:1,borderRadius:1,borderRight:1,borderStyle:1,borderTop:1,borderWidth:1,caret:1,columns:1,columnRule:1,containIntrinsicSize:1,container:1,flex:1,flexFlow:1,font:1,gap:1,grid:1,gridArea:1,gridColumn:1,gridRow:1,gridTemplate:1,inset:1,insetBlock:1,insetInline:1,lineClamp:1,listStyle:1,margin:1,marginBlock:1,marginInline:1,mask:1,maskBorder:1,motion:1,offset:1,outline:1,overflow:1,overscrollBehavior:1,padding:1,paddingBlock:1,paddingInline:1,placeItems:1,placeContent:1,placeSelf:1,scrollMargin:1,scrollMarginBlock:1,scrollMarginInline:1,scrollPadding:1,scrollPaddingBlock:1,scrollPaddingInline:1,scrollSnapMargin:1,scrollTimeline:1,textDecoration:1,textEmphasis:1,transition:1}},52961:function(e,t,i){"use strict";i.d(t,{q5:function(){return b}});const n=["Top","Right","Bottom","Left"];function o(e,t,...i){const[o,r=o,a=o,s=r]=i,l=[o,r,a,s],c={};for(let i=0;i<l.length;i+=1)(l[i]||0===l[i])&&(c[e+n[i]+t]=l[i]);return c}function r(...e){return o("border","Width",...e)}function a(...e){return o("border","Style",...e)}function s(...e){return o("border","Color",...e)}const l=["none","hidden","dotted","dashed","solid","double","groove","ridge","inset","outset"];function c(e){return l.includes(e)}const d=e=>"number"==typeof e&&!Number.isNaN(e),u=e=>"auto"===e,h=["content","fit-content","max-content","min-content"],p=e=>h.some((t=>e===t))||(e=>"string"==typeof e&&/(\d+(\w+|%))/.test(e))(e),g=/var\(.*\)/gi,f=/^[a-zA-Z0-9\-_\\#;]+$/,m=/^-moz-initial$|^auto$|^initial$|^inherit$|^revert$|^unset$|^span \d+$|\d.*/;function v(e){return void 0!==e&&"string"==typeof e&&f.test(e)&&!m.test(e)}const y=["-moz-initial","inherit","initial","revert","unset"],C=["dashed","dotted","double","solid","wavy"],b={border:function(...e){return c(e[0])?{...a(e[0]),...e[1]&&r(e[1]),...e[2]&&s(e[2])}:{...r(e[0]),...e[1]&&a(e[1]),...e[2]&&s(e[2])}},borderLeft:function(...e){return c(e[0])?{borderLeftStyle:e[0],...e[1]&&{borderLeftWidth:e[1]},...e[2]&&{borderLeftColor:e[2]}}:{borderLeftWidth:e[0],...e[1]&&{borderLeftStyle:e[1]},...e[2]&&{borderLeftColor:e[2]}}},borderBottom:function(...e){return c(e[0])?{borderBottomStyle:e[0],...e[1]&&{borderBottomWidth:e[1]},...e[2]&&{borderBottomColor:e[2]}}:{borderBottomWidth:e[0],...e[1]&&{borderBottomStyle:e[1]},...e[2]&&{borderBottomColor:e[2]}}},borderRight:function(...e){return c(e[0])?{borderRightStyle:e[0],...e[1]&&{borderRightWidth:e[1]},...e[2]&&{borderRightColor:e[2]}}:{borderRightWidth:e[0],...e[1]&&{borderRightStyle:e[1]},...e[2]&&{borderRightColor:e[2]}}},borderTop:function(...e){return c(e[0])?{borderTopStyle:e[0],...e[1]&&{borderTopWidth:e[1]},...e[2]&&{borderTopColor:e[2]}}:{borderTopWidth:e[0],...e[1]&&{borderTopStyle:e[1]},...e[2]&&{borderTopColor:e[2]}}},borderColor:s,borderStyle:a,borderRadius:function(e,t=e,i=e,n=t){return{borderBottomRightRadius:i,borderBottomLeftRadius:n,borderTopRightRadius:t,borderTopLeftRadius:e}},borderWidth:r,flex:function(...e){const t=1===e.length,i=2===e.length,n=3===e.length;if(t){const[t]=e;if("initial"===t)return{flexGrow:0,flexShrink:1,flexBasis:"auto"};if(u(t))return{flexGrow:1,flexShrink:1,flexBasis:"auto"};if("none"===t)return{flexGrow:0,flexShrink:0,flexBasis:"auto"};if(d(t))return{flexGrow:t,flexShrink:1,flexBasis:0};if(p(t))return{flexGrow:1,flexShrink:1,flexBasis:t}}if(i){const[t,i]=e;if(d(i))return{flexGrow:t,flexShrink:i,flexBasis:0};if(p(i))return{flexGrow:t,flexShrink:1,flexBasis:i}}if(n){const[t,i,n]=e;if(d(t)&&d(i)&&(u(n)||p(n)))return{flexGrow:t,flexShrink:i,flexBasis:n}}return{}},gap:function(e,t=e){return{columnGap:e,rowGap:t}},gridArea:function(...e){if(e.some((e=>!function(e){return void 0===e||"number"==typeof e||"string"==typeof e&&!g.test(e)}(e))))return{};const t=void 0!==e[0]?e[0]:"auto",i=void 0!==e[1]?e[1]:v(t)?t:"auto";return{gridRowStart:t,gridColumnStart:i,gridRowEnd:void 0!==e[2]?e[2]:v(t)?t:"auto",gridColumnEnd:void 0!==e[3]?e[3]:v(i)?i:"auto"}},margin:function(...e){return o("margin","",...e)},marginBlock:function(e,t=e){return{marginBlockStart:e,marginBlockEnd:t}},marginInline:function(e,t=e){return{marginInlineStart:e,marginInlineEnd:t}},padding:function(...e){return o("padding","",...e)},paddingBlock:function(e,t=e){return{paddingBlockStart:e,paddingBlockEnd:t}},paddingInline:function(e,t=e){return{paddingInlineStart:e,paddingInlineEnd:t}},overflow:function(e,t=e){return{overflowX:e,overflowY:t}},inset:function(...e){const[t,i=t,n=t,o=i]=e;return{top:t,right:i,bottom:n,left:o}},outline:function(e,t,i){return{outlineWidth:e,...t&&{outlineStyle:t},...i&&{outlineColor:i}}},transition:function(...e){return function(e){return 1===e.length&&y.includes(e[0])}(e)?{transitionDelay:e[0],transitionDuration:e[0],transitionProperty:e[0],transitionTimingFunction:e[0]}:(t=e,1===t.length&&Array.isArray(t[0])?t[0]:[t]).reduce(((e,[t,i="0s",n="0s",o="ease"],r)=>(0===r?(e.transitionProperty=t,e.transitionDuration=i,e.transitionDelay=n,e.transitionTimingFunction=o):(e.transitionProperty+=`, ${t}`,e.transitionDuration+=`, ${i}`,e.transitionDelay+=`, ${n}`,e.transitionTimingFunction+=`, ${o}`),e)),{});var t},textDecoration:function(e,...t){if(0===t.length)return function(e){return C.includes(e)}(e)?{textDecorationStyle:e}:{textDecorationLine:e};const[i,n,o]=t;return{textDecorationLine:e,...i&&{textDecorationStyle:i},...n&&{textDecorationColor:n},...o&&{textDecorationThickness:o}}}}},12878:function(e,t,i){"use strict";i.d(t,{F:function(){return n}});const n=()=>{const e={};return function(t,i){void 0===e[t.id]&&(t.insertCSSRules(i),e[t.id]=!0)}}},74551:function(e,t,i){"use strict";i.d(t,{z:function(){return s}});var n=i(73802),o=i(62800),r=i(24456);const a={};function s(){let e=null,t="",i="";const s=new Array(arguments.length);for(let e=0;e<arguments.length;e++){const o=arguments[e];if("string"==typeof o&&""!==o){const r=o.indexOf(n.Qz);if(-1===r)t+=o+" ";else{const a=o.substr(r,n.jD);r>0&&(t+=o.slice(0,r)),i+=a,s[e]=a}}}if(""===i)return t.slice(0,-1);const l=a[i];if(void 0!==l)return t+l;const c=[];for(let t=0;t<arguments.length;t++){const i=s[t];if(i){const t=n.xR[i];t&&(c.push(t[n.JM]),e=t[n.de])}}const d=Object.assign.apply(Object,[{}].concat(c));let u=(0,r.w)(d,e);const h=(0,o.m)(u,e,s);return u=h+" "+u,a[i]=u,n.xR[h]=[d,e],t+u}},24456:function(e,t,i){"use strict";i.d(t,{V:function(){return a},w:function(){return r}});var n=i(73802),o=i(62800);function r(e,t){let i="";for(const n in e){const o=e[n];if(o){const e=Array.isArray(o);i+="rtl"===t?(e?o[1]:o)+" ":(e?o[0]:o)+" "}}return i.slice(0,-1)}function a(e,t){const i={};for(const a in e){const s=r(e[a],t);if(""===s){i[a]="";continue}const l=(0,o.m)(s,t),c=l+" "+s;n.xR[l]=[e[a],t],i[a]=c}return i}},62800:function(e,t,i){"use strict";i.d(t,{m:function(){return r}});var n=i(8052),o=i(73802);function r(e,t,i=[]){return o.Qz+function(e){const t=e.length;if(t===o.gk)return e;for(let i=t;i<o.gk;i++)e+="0";return e}((0,n.Z)(e+t))}},67659:function(e,t,i){"use strict";i.d(t,{a:function(){return h}});var n=i(73802);const o=["r","d","l","v","w","f","i","h","a","s","k","t","m","c"].reduce(((e,t,i)=>(e[t]=i,e)),{});function r(e,t,i,r,a={}){const s="m"===e,l=s?e+a.m:e;if(!r.stylesheets[l]){const c=t&&t.createElement("style"),d=function(e,t,i){const o=[];if(i[n.$Q]=t,e)for(const t in i)e.setAttribute(t,i[t]);return{elementAttributes:i,insertRule:function(t){return(null==e?void 0:e.sheet)?e.sheet.insertRule(t,e.sheet.cssRules.length):o.push(t)},element:e,bucketName:t,cssRules(){return(null==e?void 0:e.sheet)?Array.from(e.sheet.cssRules).map((e=>e.cssText)):o}}}(c,e,{...r.styleElementAttributes,...s&&{media:a.m}});r.stylesheets[l]=d,t&&c&&t.head.insertBefore(c,function(e,t,i,r,a){const s=o[i];let l=e=>s-o[e.getAttribute(n.$Q)],c=e.head.querySelectorAll(`[${n.$Q}]`);if("m"===i&&a){const t=e.head.querySelectorAll(`[${n.$Q}="${i}"]`);t.length&&(c=t,l=e=>r.compareMediaQueries(a.m,e.media))}const d=c.length;let u=d-1;for(;u>=0;){const e=c.item(u);if(l(e)>0)return e.nextSibling;u--}return d>0?c.item(0):t?t.nextSibling:null}(t,i,e,r,a))}return r.stylesheets[l]}function a(e,t){try{e.insertRule(t)}catch(e){}}let s=0;const l=(e,t)=>e<t?-1:e>t?1:0;function c(e=("undefined"==typeof document?void 0:document),t={}){const{unstable_filterCSSRule:i,insertionPoint:n,styleElementAttributes:o,compareMediaQueries:c=l}=t,d={insertionCache:{},stylesheets:{},styleElementAttributes:Object.freeze(o),compareMediaQueries:c,id:"d"+s++,insertCSSRules(t){for(const s in t){const l=t[s];for(let t=0,c=l.length;t<c;t++){const[c,u]=(o=l[t],Array.isArray(o)?o:[o]),h=r(s,e,n||null,d,u);d.insertionCache[c]||(d.insertionCache[c]=s,i?i(c)&&a(h,c):a(h,c))}}var o}};return d}var d=i(8559);const u=d.createContext(c());function h(){return d.useContext(u)}},16503:function(e,t,i){"use strict";i.d(t,{n:function(){return r},s:function(){return a}});var n=i(8559);const o=n.createContext("ltr"),r=({children:e,dir:t})=>n.createElement(o.Provider,{value:t},e);function a(){return n.useContext(o)}},94183:function(e,t,i){"use strict";i.d(t,{s:function(){return s}});var n=i(65538),o=i(90893),r=i(67659),a=i(16503);function s(e,t){const i=(0,n.s)(e,t,o.F);return function(){const e=(0,a.s)(),t=(0,r.a)();return i({dir:e,renderer:t})}}},90893:function(e,t,i){"use strict";i.d(t,{F:function(){return a}});var n=i(8559),o=i.t(n,2);const r=o.useInsertionEffect?o.useInsertionEffect:void 0,a=()=>{const e={};return function(t,i){r&&"undefined"!=typeof window&&window.document&&window.document.createElement?r((()=>{t.insertCSSRules(i)}),[t,i]):void 0===e[t.id]&&(t.insertCSSRules(i),e[t.id]=!0)}}},84045:function(e,t,i){"use strict";i.d(t,{Z:function(){return it}});var n=i(12878),o=i(8052);function r(e){return e.reduce((function(e,t){var i=t[0],n=t[1];return e[i]=n,e[n]=i,e}),{})}function a(e){return"number"==typeof e}function s(e,t){return-1!==e.indexOf(t)}function l(e,t,i,n){return t+(o=i,0===parseFloat(o)?o:"-"===o[0]?o.slice(1):"-"+o)+n;var o}function c(e){return e.replace(/ +/g," ").split(" ").map((function(e){return e.trim()})).filter(Boolean).reduce((function(e,t){var i=e.list,n=e.state,o=(t.match(/\(/g)||[]).length,r=(t.match(/\)/g)||[]).length;return n.parensDepth>0?i[i.length-1]=i[i.length-1]+" "+t:i.push(t),n.parensDepth+=o-r,{list:i,state:n}}),{list:[],state:{parensDepth:0}}).list}function d(e){var t=c(e);if(t.length<=3||t.length>4)return e;var i=t[0],n=t[1],o=t[2];return[i,t[3],o,n].join(" ")}var u={padding:function(e){var t=e.value;return a(t)?t:d(t)},textShadow:function(e){return function(e){for(var t=[],i=0,n=0,o=!1;n<e.length;)o||","!==e[n]?"("===e[n]?(o=!0,n++):")"===e[n]?(o=!1,n++):n++:(t.push(e.substring(i,n).trim()),i=++n);return i!=n&&t.push(e.substring(i,n+1)),t}(e.value).map((function(e){return e.replace(/(^|\s)(-*)([.|\d]+)/,(function(e,t,i,n){return"0"===n?e:t+(""===i?"-":"")+n}))})).join(",")},borderColor:function(e){return d(e.value)},borderRadius:function(e){var t=e.value;if(a(t))return t;if(s(t,"/")){var i=t.split("/"),n=i[0],o=i[1];return u.borderRadius({value:n.trim()})+" / "+u.borderRadius({value:o.trim()})}var r=c(t);switch(r.length){case 2:return r.reverse().join(" ");case 4:var l=r[0],d=r[1],h=r[2];return[d,l,r[3],h].join(" ");default:return t}},background:function(e){var t=e.value,i=e.valuesToConvert,n=e.isRtl,o=e.bgImgDirectionRegex,r=e.bgPosDirectionRegex;if(a(t))return t;var s=t.replace(/(url\(.*?\))|(rgba?\(.*?\))|(hsl\(.*?\))|(#[a-fA-F0-9]+)|((^| )(\D)+( |$))/g,"").trim();return t=t.replace(s,u.backgroundPosition({value:s,valuesToConvert:i,isRtl:n,bgPosDirectionRegex:r})),u.backgroundImage({value:t,valuesToConvert:i,bgImgDirectionRegex:o})},backgroundImage:function(e){var t=e.value,i=e.valuesToConvert,n=e.bgImgDirectionRegex;return s(t,"url(")||s(t,"linear-gradient(")?t.replace(n,(function(e,t,n){return e.replace(n,i[n])})):t},backgroundPosition:function(e){var t=e.value,i=e.valuesToConvert,n=e.isRtl,o=e.bgPosDirectionRegex;return t.replace(n?/^((-|\d|\.)+%)/:null,(function(e,t){return function(e){var t=e.indexOf(".");if(-1===t)e=100-parseFloat(e)+"%";else{var i=e.length-t-2;e=(e=100-parseFloat(e)).toFixed(i)+"%"}return e}(t)})).replace(o,(function(e){return i[e]}))},backgroundPositionX:function(e){var t=e.value,i=e.valuesToConvert,n=e.isRtl,o=e.bgPosDirectionRegex;return a(t)?t:u.backgroundPosition({value:t,valuesToConvert:i,isRtl:n,bgPosDirectionRegex:o})},transition:function(e){var t=e.value,i=e.propertiesToConvert;return t.split(/,\s*/g).map((function(e){var t=e.split(" ");return t[0]=i[t[0]]||t[0],t.join(" ")})).join(", ")},transitionProperty:function(e){var t=e.value,i=e.propertiesToConvert;return t.split(/,\s*/g).map((function(e){return i[e]||e})).join(", ")},transform:function(e){var t=e.value,i="[^\\u0020-\\u007e]",n="(?:(?:(?:\\[0-9a-f]{1,6})(?:\\r\\n|\\s)?)|\\\\[^\\r\\n\\f0-9a-f])",o="((?:-?(?:[0-9]*\\.[0-9]+|[0-9]+)(?:\\s*(?:em|ex|px|cm|mm|in|pt|pc|deg|rad|grad|ms|s|hz|khz|%)|-?(?:[_a-z]|"+i+"|"+n+")(?:[_a-z0-9-]|"+i+"|"+n+")*)?)|(?:inherit|auto))",r=new RegExp("(translateX\\s*\\(\\s*)"+o+"(\\s*\\))","gi"),a=new RegExp("(translate\\s*\\(\\s*)"+o+"((?:\\s*,\\s*"+o+"){0,1}\\s*\\))","gi"),s=new RegExp("(translate3d\\s*\\(\\s*)"+o+"((?:\\s*,\\s*"+o+"){0,2}\\s*\\))","gi"),c=new RegExp("(rotate[ZY]?\\s*\\(\\s*)"+o+"(\\s*\\))","gi");return t.replace(r,l).replace(a,l).replace(s,l).replace(c,l)}};u.objectPosition=u.backgroundPosition,u.margin=u.padding,u.borderWidth=u.padding,u.boxShadow=u.textShadow,u.webkitBoxShadow=u.boxShadow,u.mozBoxShadow=u.boxShadow,u.WebkitBoxShadow=u.boxShadow,u.MozBoxShadow=u.boxShadow,u.borderStyle=u.borderColor,u.webkitTransform=u.transform,u.mozTransform=u.transform,u.WebkitTransform=u.transform,u.MozTransform=u.transform,u.transformOrigin=u.backgroundPosition,u.webkitTransformOrigin=u.transformOrigin,u.mozTransformOrigin=u.transformOrigin,u.WebkitTransformOrigin=u.transformOrigin,u.MozTransformOrigin=u.transformOrigin,u.webkitTransition=u.transition,u.mozTransition=u.transition,u.WebkitTransition=u.transition,u.MozTransition=u.transition,u.webkitTransitionProperty=u.transitionProperty,u.mozTransitionProperty=u.transitionProperty,u.WebkitTransitionProperty=u.transitionProperty,u.MozTransitionProperty=u.transitionProperty,u["text-shadow"]=u.textShadow,u["border-color"]=u.borderColor,u["border-radius"]=u.borderRadius,u["background-image"]=u.backgroundImage,u["background-position"]=u.backgroundPosition,u["background-position-x"]=u.backgroundPositionX,u["object-position"]=u.objectPosition,u["border-width"]=u.padding,u["box-shadow"]=u.textShadow,u["-webkit-box-shadow"]=u.textShadow,u["-moz-box-shadow"]=u.textShadow,u["border-style"]=u.borderColor,u["-webkit-transform"]=u.transform,u["-moz-transform"]=u.transform,u["transform-origin"]=u.transformOrigin,u["-webkit-transform-origin"]=u.transformOrigin,u["-moz-transform-origin"]=u.transformOrigin,u["-webkit-transition"]=u.transition,u["-moz-transition"]=u.transition,u["transition-property"]=u.transitionProperty,u["-webkit-transition-property"]=u.transitionProperty,u["-moz-transition-property"]=u.transitionProperty;var h=r([["paddingLeft","paddingRight"],["marginLeft","marginRight"],["left","right"],["borderLeft","borderRight"],["borderLeftColor","borderRightColor"],["borderLeftStyle","borderRightStyle"],["borderLeftWidth","borderRightWidth"],["borderTopLeftRadius","borderTopRightRadius"],["borderBottomLeftRadius","borderBottomRightRadius"],["padding-left","padding-right"],["margin-left","margin-right"],["border-left","border-right"],["border-left-color","border-right-color"],["border-left-style","border-right-style"],["border-left-width","border-right-width"],["border-top-left-radius","border-top-right-radius"],["border-bottom-left-radius","border-bottom-right-radius"]]),p=["content"],g=r([["ltr","rtl"],["left","right"],["w-resize","e-resize"],["sw-resize","se-resize"],["nw-resize","ne-resize"]]),f=new RegExp("(^|\\W|_)((ltr)|(rtl)|(left)|(right))(\\W|_|$)","g"),m=new RegExp("(left)|(right)");function v(e){return Object.keys(e).reduce((function(t,i){var n=e[i];if("string"==typeof n&&(n=n.trim()),s(p,i))return t[i]=n,t;var o=y(i,n),r=o.key,a=o.value;return t[r]=a,t}),Array.isArray(e)?[]:{})}function y(e,t){var i,n=/\/\*\s?@noflip\s?\*\//.test(t),o=n?e:h[i=e]||i,r=n?t:function(e,t){if(!function(e){return!("boolean"==typeof e||function(e){return null==e}(e))}(t))return t;if((i=t)&&"object"==typeof i)return v(t);var i,n,o=a(t),r=function(e){return"function"==typeof e}(t),s=o||r?t:t.replace(/ !important.*?$/,""),l=!o&&s.length!==t.length,c=u[e];return n=c?c({value:s,valuesToConvert:g,propertiesToConvert:h,isRtl:!0,bgImgDirectionRegex:f,bgPosDirectionRegex:m}):g[s]||s,l?n+" !important":n}(o,t);return{key:o,value:r}}var C=i(73802);const b=/[A-Z]/g,S=/^ms-/,x={};function T(e){return"-"+e.toLowerCase()}function w(e){if(Object.prototype.hasOwnProperty.call(x,e))return x[e];if("--"===e.substr(0,2))return e;const t=e.replace(b,T);return x[e]=S.test(t)?"-"+t:t}function O(e){return"&"===e.charAt(0)?e.slice(1):e}var P="-ms-",A="-moz-",E="-webkit-",k="comm",I="rule",D="decl",_="@import",N="@keyframes",R="@layer",M=Math.abs,L=String.fromCharCode,B=Object.assign;function F(e){return e.trim()}function U(e,t){return(e=t.exec(e))?e[0]:e}function H(e,t,i){return e.replace(t,i)}function $(e,t){return e.indexOf(t)}function Z(e,t){return 0|e.charCodeAt(t)}function V(e,t,i){return e.slice(t,i)}function G(e){return e.length}function j(e){return e.length}function z(e,t){return t.push(e),e}function W(e,t){for(var i="",n=0;n<e.length;n++)i+=t(e[n],n,e,t)||"";return i}function K(e,t,i,n){switch(e.type){case R:if(e.children.length)break;case _:case D:return e.return=e.return||e.value;case k:return"";case N:return e.return=e.value+"{"+W(e.children,n)+"}";case I:if(!G(e.value=e.props.join(",")))return""}return G(i=W(e.children,n))?e.return=e.value+"{"+i+"}":""}var q=1,Y=1,X=0,J=0,Q=0,ee="";function te(e,t,i,n,o,r,a,s){return{value:e,root:t,parent:i,type:n,props:o,children:r,line:q,column:Y,length:a,return:"",siblings:s}}function ie(e,t){return B(te("",null,null,"",null,null,0,e.siblings),e,{length:-e.length},t)}function ne(){return Q=J>0?Z(ee,--J):0,Y--,10===Q&&(Y=1,q--),Q}function oe(){return Q=J<X?Z(ee,J++):0,Y++,10===Q&&(Y=1,q++),Q}function re(){return Z(ee,J)}function ae(){return J}function se(e,t){return V(ee,e,t)}function le(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function ce(e){return q=Y=1,X=G(ee=e),J=0,[]}function de(e){return ee="",e}function ue(e){return F(se(J-1,ge(91===e?e+2:40===e?e+1:e)))}function he(e){for(;(Q=re())&&Q<33;)oe();return le(e)>2||le(Q)>3?"":" "}function pe(e,t){for(;--t&&oe()&&!(Q<48||Q>102||Q>57&&Q<65||Q>70&&Q<97););return se(e,ae()+(t<6&&32==re()&&32==oe()))}function ge(e){for(;oe();)switch(Q){case e:return J;case 34:case 39:34!==e&&39!==e&&ge(Q);break;case 40:41===e&&ge(e);break;case 92:oe()}return J}function fe(e,t){for(;oe()&&e+Q!==57&&(e+Q!==84||47!==re()););return"/*"+se(t,J-1)+"*"+L(47===e?e:oe())}function me(e){for(;!le(re());)oe();return se(e,J)}function ve(e){return de(ye("",null,null,null,[""],e=ce(e),0,[0],e))}function ye(e,t,i,n,o,r,a,s,l){for(var c=0,d=0,u=a,h=0,p=0,g=0,f=1,m=1,v=1,y=0,C="",b=o,S=r,x=n,T=C;m;)switch(g=y,y=oe()){case 40:if(108!=g&&58==Z(T,u-1)){-1!=$(T+=H(ue(y),"&","&\f"),"&\f")&&(v=-1);break}case 34:case 39:case 91:T+=ue(y);break;case 9:case 10:case 13:case 32:T+=he(g);break;case 92:T+=pe(ae()-1,7);continue;case 47:switch(re()){case 42:case 47:z(be(fe(oe(),ae()),t,i,l),l);break;default:T+="/"}break;case 123*f:s[c++]=G(T)*v;case 125*f:case 59:case 0:switch(y){case 0:case 125:m=0;case 59+d:-1==v&&(T=H(T,/\f/g,"")),p>0&&G(T)-u&&z(p>32?Se(T+";",n,i,u-1,l):Se(H(T," ","")+";",n,i,u-2,l),l);break;case 59:T+=";";default:if(z(x=Ce(T,t,i,c,d,o,s,C,b=[],S=[],u,r),r),123===y)if(0===d)ye(T,t,x,x,b,r,u,s,S);else switch(99===h&&110===Z(T,3)?100:h){case 100:case 108:case 109:case 115:ye(e,x,x,n&&z(Ce(e,x,x,0,0,o,s,C,o,b=[],u,S),S),o,S,u,s,n?b:S);break;default:ye(T,x,x,x,[""],S,0,s,S)}}c=d=p=0,f=v=1,C=T="",u=a;break;case 58:u=1+G(T),p=g;default:if(f<1)if(123==y)--f;else if(125==y&&0==f++&&125==ne())continue;switch(T+=L(y),y*f){case 38:v=d>0?1:(T+="\f",-1);break;case 44:s[c++]=(G(T)-1)*v,v=1;break;case 64:45===re()&&(T+=ue(oe())),h=re(),d=u=G(C=T+=me(ae())),y++;break;case 45:45===g&&2==G(T)&&(f=0)}}return r}function Ce(e,t,i,n,o,r,a,s,l,c,d,u){for(var h=o-1,p=0===o?r:[""],g=j(p),f=0,m=0,v=0;f<n;++f)for(var y=0,C=V(e,h+1,h=M(m=a[f])),b=e;y<g;++y)(b=F(m>0?p[y]+" "+C:H(C,/&\f/g,p[y])))&&(l[v++]=b);return te(e,t,i,0===o?I:s,l,c,d,u)}function be(e,t,i,n){return te(e,t,i,k,L(Q),V(e,2,-2),0,n)}function Se(e,t,i,n,o){return te(e,t,i,D,V(e,0,n),V(e,n+1,-1),n,o)}function xe(e){var t=j(e);return function(i,n,o,r){for(var a="",s=0;s<t;s++)a+=e[s](i,n,o,r)||"";return a}}function Te(e){return function(t){t.root||(t=t.return)&&e(t)}}const we=e=>{if(e.type===I){if("string"==typeof e.props)return;e.props=e.props.map((e=>-1===e.indexOf(":global(")?e:function(e){return de(function(e){for(;oe();)switch(le(Q)){case 0:z(me(J-1),e);break;case 2:z(ue(Q),e);break;default:z(L(Q),e)}return e}(ce(e)))}(e).reduce(((e,t,i,n)=>{if(""===t)return e;if(":"===t&&"global"===n[i+1]){const t=n[i+2].slice(1,-1)+" ";return e.unshift(t),n[i+1]="",n[i+2]="",e}return e.push(t),e}),[]).join("")))}};function Oe(e,t,i){switch(function(e,t){return 45^Z(e,0)?(((t<<2^Z(e,0))<<2^Z(e,1))<<2^Z(e,2))<<2^Z(e,3):0}(e,t)){case 5103:return E+"print-"+e+e;case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:return E+e+e;case 4215:if(116===Z(e,t+1))return E+e+e;break;case 4789:return A+e+e;case 5349:case 4246:case 6968:return E+e+A+e+P+e+e;case 6187:if(!U(e,/grab/))return H(H(H(e,/(zoom-|grab)/,E+"$1"),/(image-set)/,E+"$1"),e,"")+e;case 5495:case 3959:return H(e,/(image-set\([^]*)/,E+"$1$`$1");case 4095:case 3583:case 4068:case 2532:return H(e,/(.+)-inline(.+)/,E+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(G(e)-1-t>6)switch(Z(e,t+1)){case 102:if(108===Z(e,t+3))return H(e,/(.+:)(.+)-([^]+)/,"$1"+E+"$2-$3$1"+A+(108==Z(e,t+3)?"$3":"$2-$3"))+e;case 115:return~$(e,"stretch")?Oe(H(e,"stretch","fill-available"),t)+e:e}}return e}function Pe(e,t,i,n){if(e.length>-1&&!e.return)switch(e.type){case D:return void(e.return=Oe(e.value,e.length));case I:if(e.length)return function(e,t){return e.map(t).join("")}(e.props,(function(t){switch(U(t,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return W([ie(e,{props:[H(t,/:(read-\w+)/,":"+A+"$1")]})],n);case"::placeholder":return W([ie(e,{props:[H(t,/:(plac\w+)/,":"+E+"input-$1")]}),ie(e,{props:[H(t,/:(plac\w+)/,":"+A+"$1")]}),ie(e,{props:[H(t,/:(plac\w+)/,P+"input-$1")]})],n)}return""}))}}const Ae=e=>{(function(e){switch(e.type){case"@container":case"@media":case"@supports":case R:return!0}return!1})(e)&&Array.isArray(e.children)&&e.children.sort(((e,t)=>e.props[0]>t.props[0]?1:-1))};const Ee=/,( *[^ &])/g;function ke(e,t,i){let n=t;return i.length>0&&(n=i.reduceRight(((e,t)=>{return`${i=t,"&"+O(i.replace(Ee,",&$1"))} { ${e} }`;var i}),t)),`${e}{${n}}`}function Ie(e){const{className:t,media:i,layer:n,selectors:o,support:r,property:a,rtlClassName:s,rtlProperty:l,rtlValue:c,value:d,container:u}=e;let h=ke(`.${t}`,Array.isArray(d)?`${d.map((e=>`${w(a)}: ${e}`)).join(";")};`:`${w(a)}: ${d};`,o);return l&&s&&(h+=ke(`.${s}`,Array.isArray(c)?`${c.map((e=>`${w(l)}: ${e}`)).join(";")};`:`${w(l)}: ${c};`,o)),i&&(h=`@media ${i} { ${h} }`),n&&(h=`@layer ${n} { ${h} }`),r&&(h=`@supports ${r} { ${h} }`),u&&(h=`@container ${u} { ${h} }`),function(e,t){const i=[];return W(ve(e),xe([we,Ae,Pe,K,Te((e=>i.push(e)))])),i}(h)}function De(e){let t="";for(const i in e){const n=e[i];"string"!=typeof n&&"number"!=typeof n||(t+=w(i)+":"+n+";")}return t}function _e(e){let t="";for(const i in e)t+=`${i}{${De(e[i])}}`;return t}function Ne(e,t){const i=[];return W(ve(`@keyframes ${e} {${t}}`),xe([K,Pe,Te((e=>i.push(e)))])),i}function Re(e,t){return 0===e.length?t:`${e} and ${t}`}function Me(e){return"@media"===e.substr(0,6)}function Le(e){return"@layer"===e.substr(0,6)}const Be=/^(:|\[|>|&)/;function Fe(e){return Be.test(e)}function Ue(e){return"@supports"===e.substr(0,9)}function He(e){return"@container"===e.substring(0,10)}const $e={"us-w":"w","us-v":"i",nk:"l",si:"v",cu:"f",ve:"h",ti:"a"};function Ze(e,t,i,n,o){if(i)return"m";if(t||n)return"t";if(o)return"c";if(e.length>0){const t=e[0].trim();if(58===t.charCodeAt(0))return $e[t.slice(4,8)]||$e[t.slice(3,5)]||"d"}return"d"}function Ve({container:e,media:t,layer:i,property:n,selector:r,support:a,value:s}){const l=(0,o.Z)(r+e+t+i+a+n+s.trim());return C.Hf+l}function Ge(e,t,i,n,r){const a=e+t+i+n+r,s=(0,o.Z)(a),l=s.charCodeAt(0);return l>=48&&l<=57?String.fromCharCode(l+17)+s.slice(1):s}function je(e){return e.replace(/>\s+/g,">")}function ze(e,t){const i=JSON.stringify(t,null,2),n=["@griffel/react: A rule was not resolved to CSS properly. Please check your `makeStyles` or `makeResetStyles` calls for following:"," ".repeat(2)+"makeStyles({"," ".repeat(4)+"[slot]: {"," ".repeat(6)+`"${e}": ${i.split("\n").map(((e,t)=>" ".repeat(0===t?0:6)+e)).join("\n")}`," ".repeat(4)+"}"," ".repeat(2)+"})",""];-1===e.indexOf("&")?(n.push("It looks that you're are using a nested selector, but it is missing an ampersand placeholder where the generated class name should be injected."),n.push(`Try to update a property to include it i.e "${e}" => "&${e}".`)):(n.push(""),n.push("If it's not obvious what triggers a problem, please report an issue at https://github.com/microsoft/griffel/issues")),n.join("\n")}function We(e,t){[`@griffel/react: You are using unsupported shorthand CSS property "${e}". Please check your "makeStyles" calls, there *should not* be following:`," ".repeat(2)+"makeStyles({"," ".repeat(4)+`[slot]: { ${e}: "${t}" }`," ".repeat(2)+"})","","Learn why CSS shorthands are not supported: https://aka.ms/griffel-css-shorthands"].join("\n")}function Ke(e,t,i,n){e[t]=n?[i,n]:i}function qe(e,t){return t?[e,t]:e}function Ye(e,t,i,n,o){var r;let a;"m"===t&&o&&(a={m:o}),null!==(r=e[t])&&void 0!==r||(e[t]=[]),i&&e[t].push(qe(i,a)),n&&e[t].push(qe(n,a))}function Xe(e,t=[],i="",n="",r="",a="",s={},l={},c){for(const u in e){if(C.C_.hasOwnProperty(u)){We(u,e[u]);continue}const h=e[u];if(null!=h)if("string"==typeof h||"number"==typeof h){const e=je(t.join("")),o=Ge(e,a,i,r,u),d=Ve({container:a,media:i,layer:n,value:h.toString(),support:r,selector:e,property:u}),p=c&&{key:u,value:c}||y(u,h),g=p.key!==u||p.value!==h,f=g?Ve({container:a,value:p.value.toString(),property:p.key,selector:e,media:i,layer:n,support:r}):void 0,m=g?{rtlClassName:f,rtlProperty:p.key,rtlValue:p.value}:void 0,v=Ze(t,n,i,r,a),[C,b]=Ie({className:d,media:i,layer:n,selectors:t,property:u,support:r,container:a,value:h,...m});Ke(s,o,d,f),Ye(l,v,C,b,i)}else if("animationName"===u){const e=Array.isArray(h)?h:[h],c=[],d=[];for(const t of e){const e=_e(t),n=_e(v(t)),r=C.Hf+(0,o.Z)(e);let a;const s=Ne(r,e);let u=[];e===n?a=r:(a=C.Hf+(0,o.Z)(n),u=Ne(a,n));for(let e=0;e<s.length;e++)Ye(l,"k",s[e],u[e],i);c.push(r),d.push(a)}Xe({animationName:c.join(", ")},t,i,n,r,a,s,l,d.join(", "))}else if(Array.isArray(h)){if(0===h.length)continue;const e=je(t.join("")),o=Ge(e,a,i,r,u),c=Ve({container:a,media:i,layer:n,value:h.map((e=>(null!=e?e:"").toString())).join(";"),support:r,selector:e,property:u}),d=h.map((e=>y(u,e)));if(d.some((e=>e.key!==d[0].key)))continue;const p=d[0].key!==u||d.some(((e,t)=>e.value!==h[t])),g=p?Ve({container:a,value:d.map((e=>{var t;return(null!==(t=null==e?void 0:e.value)&&void 0!==t?t:"").toString()})).join(";"),property:d[0].key,selector:e,layer:n,media:i,support:r}):void 0,f=p?{rtlClassName:g,rtlProperty:d[0].key,rtlValue:d.map((e=>e.value))}:void 0,m=Ze(t,n,i,r,a),[v,C]=Ie({className:c,media:i,layer:n,selectors:t,property:u,support:r,container:a,value:h,...f});Ke(s,o,c,g),Ye(l,m,v,C,i)}else if(null!=(d=h)&&"object"==typeof d&&!1===Array.isArray(d))if(Fe(u))Xe(h,t.concat(O(u)),i,n,r,a,s,l);else if(Me(u)){const e=Re(i,u.slice(6).trim());Xe(h,t,e,n,r,a,s,l)}else if(Le(u)){const e=(n?`${n}.`:"")+u.slice(6).trim();Xe(h,t,i,e,r,a,s,l)}else if(Ue(u)){const e=Re(r,u.slice(9).trim());Xe(h,t,i,n,e,a,s,l)}else if(He(u)){const e=u.slice(10).trim();Xe(h,t,i,n,r,e,s,l)}else ze(u,h)}var d;return[s,l]}var Je=i(24456);var Qe=i(90893),et=i(67659),tt=i(16503);function it(e){const t=function(e,t=n.F){const i=t();let o=null,r=null,a=null,s=null;return function(t){const{dir:n,renderer:l}=t;null===o&&([o,r]=function(e){const t={},i={};for(const n in e){const o=e[n],[r,a]=Xe(o);t[n]=r,Object.keys(a).forEach((e=>{i[e]=(i[e]||[]).concat(a[e])}))}return[t,i]}(e));const c="ltr"===n;return c?null===a&&(a=(0,Je.V)(o,n)):null===s&&(s=(0,Je.V)(o,n)),i(l,r),c?a:s}}(e,Qe.F);return function(){const e=(0,tt.s)(),i=(0,et.a)();return t({dir:e,renderer:i})}}},45908:function(e,t,i){"use strict";function n(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a}i.d(t,{gn:function(){return n}})},88524:function(e,t){"use strict";t.D=void 0;var i=function(){function e(){this.b64c="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",this.b64u="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_",this.b64pad="="}return e.prototype.encode=function(e){var t=unescape(encodeURIComponent(e));return this.encodeData(t,t.length,this.b64c)},e.prototype.urlEncode=function(e){var t=unescape(encodeURIComponent(e));return this.encodeData(t,t.length,this.b64u)},e.prototype.decode=function(e){var t,i,n,o,r,a="";for(t=0;t<e.length-3;t+=4)i=this.charIndex(e.charAt(t+0)),n=this.charIndex(e.charAt(t+1)),o=this.charIndex(e.charAt(t+2)),r=this.charIndex(e.charAt(t+3)),a+=String.fromCharCode(i<<2|n>>>4),e.charAt(t+2)!==this.b64pad&&(a+=String.fromCharCode(n<<4&240|o>>>2&15)),e.charAt(t+3)!==this.b64pad&&(a+=String.fromCharCode(o<<6&192|r));return decodeURIComponent(escape(a))},e.prototype.urlSniff=function(e){return e.indexOf("-")>=0||e.indexOf("_")>=0},e.prototype.encodeData=function(e,t,i){var n="",o=0;for(o=0;o<=t-3;o+=3)n+=i.charAt(e.charCodeAt(o)>>>2),n+=i.charAt((3&e.charCodeAt(o))<<4|e.charCodeAt(o+1)>>>4),n+=i.charAt((15&e.charCodeAt(o+1))<<2|e.charCodeAt(o+2)>>>6),n+=i.charAt(63&e.charCodeAt(o+2));return t%3==2?(n+=i.charAt(e.charCodeAt(o)>>>2),n+=i.charAt((3&e.charCodeAt(o))<<4|e.charCodeAt(o+1)>>>4),n+=i.charAt((15&e.charCodeAt(o+1))<<2),n+=this.b64pad):t%3==1&&(n+=i.charAt(e.charCodeAt(o)>>>2),n+=i.charAt((3&e.charCodeAt(o))<<4),n+=this.b64pad,n+=this.b64pad),n},e.prototype.charIndex=function(e){return"+"===e?62:"/"===e?63:this.b64u.indexOf(e)},e}();t.D=i},33680:function(e,t){var i;!function(){"use strict";var n={}.hasOwnProperty;function o(){for(var e=[],t=0;t<arguments.length;t++){var i=arguments[t];if(i){var r=typeof i;if("string"===r||"number"===r)e.push(i);else if(Array.isArray(i)){if(i.length){var a=o.apply(null,i);a&&e.push(a)}}else if("object"===r){if(i.toString!==Object.prototype.toString&&!i.toString.toString().includes("[native code]")){e.push(i.toString());continue}for(var s in i)n.call(i,s)&&i[s]&&e.push(s)}}}return e.join(" ")}e.exports?(o.default=o,e.exports=o):void 0===(i=function(){return o}.apply(t,[]))||(e.exports=i)}()},90698:function(e,t,i){var n;!function(o){"use strict";var r,a=1e9,s={precision:20,rounding:4,toExpNeg:-7,toExpPos:21,LN10:"2.302585092994045684017991454684364207601101488628772976033327900967572609677352480235997205089598298341967784042286"},l=!0,c="[DecimalError] ",d=c+"Invalid argument: ",u=c+"Exponent out of range: ",h=Math.floor,p=Math.pow,g=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,f=1e7,m=7,v=9007199254740991,y=h(v/m),C={};function b(e,t){var i,n,o,r,a,s,c,d,u=e.constructor,h=u.precision;if(!e.s||!t.s)return t.s||(t=new u(e)),l?I(t,h):t;if(c=e.d,d=t.d,a=e.e,o=t.e,c=c.slice(),r=a-o){for(r<0?(n=c,r=-r,s=d.length):(n=d,o=a,s=c.length),r>(s=(a=Math.ceil(h/m))>s?a+1:s+1)&&(r=s,n.length=1),n.reverse();r--;)n.push(0);n.reverse()}for((s=c.length)-(r=d.length)<0&&(r=s,n=d,d=c,c=n),i=0;r;)i=(c[--r]=c[r]+d[r]+i)/f|0,c[r]%=f;for(i&&(c.unshift(i),++o),s=c.length;0==c[--s];)c.pop();return t.d=c,t.e=o,l?I(t,h):t}function S(e,t,i){if(e!==~~e||e<t||e>i)throw Error(d+e)}function x(e){var t,i,n,o=e.length-1,r="",a=e[0];if(o>0){for(r+=a,t=1;t<o;t++)n=e[t]+"",(i=m-n.length)&&(r+=A(i)),r+=n;a=e[t],(i=m-(n=a+"").length)&&(r+=A(i))}else if(0===a)return"0";for(;a%10==0;)a/=10;return r+a}C.absoluteValue=C.abs=function(){var e=new this.constructor(this);return e.s&&(e.s=1),e},C.comparedTo=C.cmp=function(e){var t,i,n,o,r=this;if(e=new r.constructor(e),r.s!==e.s)return r.s||-e.s;if(r.e!==e.e)return r.e>e.e^r.s<0?1:-1;for(t=0,i=(n=r.d.length)<(o=e.d.length)?n:o;t<i;++t)if(r.d[t]!==e.d[t])return r.d[t]>e.d[t]^r.s<0?1:-1;return n===o?0:n>o^r.s<0?1:-1},C.decimalPlaces=C.dp=function(){var e=this,t=e.d.length-1,i=(t-e.e)*m;if(t=e.d[t])for(;t%10==0;t/=10)i--;return i<0?0:i},C.dividedBy=C.div=function(e){return T(this,new this.constructor(e))},C.dividedToIntegerBy=C.idiv=function(e){var t=this.constructor;return I(T(this,new t(e),0,1),t.precision)},C.equals=C.eq=function(e){return!this.cmp(e)},C.exponent=function(){return O(this)},C.greaterThan=C.gt=function(e){return this.cmp(e)>0},C.greaterThanOrEqualTo=C.gte=function(e){return this.cmp(e)>=0},C.isInteger=C.isint=function(){return this.e>this.d.length-2},C.isNegative=C.isneg=function(){return this.s<0},C.isPositive=C.ispos=function(){return this.s>0},C.isZero=function(){return 0===this.s},C.lessThan=C.lt=function(e){return this.cmp(e)<0},C.lessThanOrEqualTo=C.lte=function(e){return this.cmp(e)<1},C.logarithm=C.log=function(e){var t,i=this,n=i.constructor,o=n.precision,a=o+5;if(void 0===e)e=new n(10);else if((e=new n(e)).s<1||e.eq(r))throw Error(c+"NaN");if(i.s<1)throw Error(c+(i.s?"NaN":"-Infinity"));return i.eq(r)?new n(0):(l=!1,t=T(E(i,a),E(e,a),a),l=!0,I(t,o))},C.minus=C.sub=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?D(t,e):b(t,(e.s=-e.s,e))},C.modulo=C.mod=function(e){var t,i=this,n=i.constructor,o=n.precision;if(!(e=new n(e)).s)throw Error(c+"NaN");return i.s?(l=!1,t=T(i,e,0,1).times(e),l=!0,i.minus(t)):I(new n(i),o)},C.naturalExponential=C.exp=function(){return w(this)},C.naturalLogarithm=C.ln=function(){return E(this)},C.negated=C.neg=function(){var e=new this.constructor(this);return e.s=-e.s||0,e},C.plus=C.add=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?b(t,e):D(t,(e.s=-e.s,e))},C.precision=C.sd=function(e){var t,i,n,o=this;if(void 0!==e&&e!==!!e&&1!==e&&0!==e)throw Error(d+e);if(t=O(o)+1,i=(n=o.d.length-1)*m+1,n=o.d[n]){for(;n%10==0;n/=10)i--;for(n=o.d[0];n>=10;n/=10)i++}return e&&t>i?t:i},C.squareRoot=C.sqrt=function(){var e,t,i,n,o,r,a,s=this,d=s.constructor;if(s.s<1){if(!s.s)return new d(0);throw Error(c+"NaN")}for(e=O(s),l=!1,0==(o=Math.sqrt(+s))||o==1/0?(((t=x(s.d)).length+e)%2==0&&(t+="0"),o=Math.sqrt(t),e=h((e+1)/2)-(e<0||e%2),n=new d(t=o==1/0?"5e"+e:(t=o.toExponential()).slice(0,t.indexOf("e")+1)+e)):n=new d(o.toString()),o=a=(i=d.precision)+3;;)if(n=(r=n).plus(T(s,r,a+2)).times(.5),x(r.d).slice(0,a)===(t=x(n.d)).slice(0,a)){if(t=t.slice(a-3,a+1),o==a&&"4999"==t){if(I(r,i+1,0),r.times(r).eq(s)){n=r;break}}else if("9999"!=t)break;a+=4}return l=!0,I(n,i)},C.times=C.mul=function(e){var t,i,n,o,r,a,s,c,d,u=this,h=u.constructor,p=u.d,g=(e=new h(e)).d;if(!u.s||!e.s)return new h(0);for(e.s*=u.s,i=u.e+e.e,(c=p.length)<(d=g.length)&&(r=p,p=g,g=r,a=c,c=d,d=a),r=[],n=a=c+d;n--;)r.push(0);for(n=d;--n>=0;){for(t=0,o=c+n;o>n;)s=r[o]+g[n]*p[o-n-1]+t,r[o--]=s%f|0,t=s/f|0;r[o]=(r[o]+t)%f|0}for(;!r[--a];)r.pop();return t?++i:r.shift(),e.d=r,e.e=i,l?I(e,h.precision):e},C.toDecimalPlaces=C.todp=function(e,t){var i=this,n=i.constructor;return i=new n(i),void 0===e?i:(S(e,0,a),void 0===t?t=n.rounding:S(t,0,8),I(i,e+O(i)+1,t))},C.toExponential=function(e,t){var i,n=this,o=n.constructor;return void 0===e?i=_(n,!0):(S(e,0,a),void 0===t?t=o.rounding:S(t,0,8),i=_(n=I(new o(n),e+1,t),!0,e+1)),i},C.toFixed=function(e,t){var i,n,o=this,r=o.constructor;return void 0===e?_(o):(S(e,0,a),void 0===t?t=r.rounding:S(t,0,8),i=_((n=I(new r(o),e+O(o)+1,t)).abs(),!1,e+O(n)+1),o.isneg()&&!o.isZero()?"-"+i:i)},C.toInteger=C.toint=function(){var e=this,t=e.constructor;return I(new t(e),O(e)+1,t.rounding)},C.toNumber=function(){return+this},C.toPower=C.pow=function(e){var t,i,n,o,a,s,d=this,u=d.constructor,p=+(e=new u(e));if(!e.s)return new u(r);if(!(d=new u(d)).s){if(e.s<1)throw Error(c+"Infinity");return d}if(d.eq(r))return d;if(n=u.precision,e.eq(r))return I(d,n);if(s=(t=e.e)>=(i=e.d.length-1),a=d.s,s){if((i=p<0?-p:p)<=v){for(o=new u(r),t=Math.ceil(n/m+4),l=!1;i%2&&N((o=o.times(d)).d,t),0!==(i=h(i/2));)N((d=d.times(d)).d,t);return l=!0,e.s<0?new u(r).div(o):I(o,n)}}else if(a<0)throw Error(c+"NaN");return a=a<0&&1&e.d[Math.max(t,i)]?-1:1,d.s=1,l=!1,o=e.times(E(d,n+12)),l=!0,(o=w(o)).s=a,o},C.toPrecision=function(e,t){var i,n,o=this,r=o.constructor;return void 0===e?n=_(o,(i=O(o))<=r.toExpNeg||i>=r.toExpPos):(S(e,1,a),void 0===t?t=r.rounding:S(t,0,8),n=_(o=I(new r(o),e,t),e<=(i=O(o))||i<=r.toExpNeg,e)),n},C.toSignificantDigits=C.tosd=function(e,t){var i=this.constructor;return void 0===e?(e=i.precision,t=i.rounding):(S(e,1,a),void 0===t?t=i.rounding:S(t,0,8)),I(new i(this),e,t)},C.toString=C.valueOf=C.val=C.toJSON=function(){var e=this,t=O(e),i=e.constructor;return _(e,t<=i.toExpNeg||t>=i.toExpPos)};var T=function(){function e(e,t){var i,n=0,o=e.length;for(e=e.slice();o--;)i=e[o]*t+n,e[o]=i%f|0,n=i/f|0;return n&&e.unshift(n),e}function t(e,t,i,n){var o,r;if(i!=n)r=i>n?1:-1;else for(o=r=0;o<i;o++)if(e[o]!=t[o]){r=e[o]>t[o]?1:-1;break}return r}function i(e,t,i){for(var n=0;i--;)e[i]-=n,n=e[i]<t[i]?1:0,e[i]=n*f+e[i]-t[i];for(;!e[0]&&e.length>1;)e.shift()}return function(n,o,r,a){var s,l,d,u,h,p,g,v,y,C,b,S,x,T,w,P,A,E,k=n.constructor,D=n.s==o.s?1:-1,_=n.d,N=o.d;if(!n.s)return new k(n);if(!o.s)throw Error(c+"Division by zero");for(l=n.e-o.e,A=N.length,w=_.length,v=(g=new k(D)).d=[],d=0;N[d]==(_[d]||0);)++d;if(N[d]>(_[d]||0)&&--l,(S=null==r?r=k.precision:a?r+(O(n)-O(o))+1:r)<0)return new k(0);if(S=S/m+2|0,d=0,1==A)for(u=0,N=N[0],S++;(d<w||u)&&S--;d++)x=u*f+(_[d]||0),v[d]=x/N|0,u=x%N|0;else{for((u=f/(N[0]+1)|0)>1&&(N=e(N,u),_=e(_,u),A=N.length,w=_.length),T=A,C=(y=_.slice(0,A)).length;C<A;)y[C++]=0;(E=N.slice()).unshift(0),P=N[0],N[1]>=f/2&&++P;do{u=0,(s=t(N,y,A,C))<0?(b=y[0],A!=C&&(b=b*f+(y[1]||0)),(u=b/P|0)>1?(u>=f&&(u=f-1),1==(s=t(h=e(N,u),y,p=h.length,C=y.length))&&(u--,i(h,A<p?E:N,p))):(0==u&&(s=u=1),h=N.slice()),(p=h.length)<C&&h.unshift(0),i(y,h,C),-1==s&&(s=t(N,y,A,C=y.length))<1&&(u++,i(y,A<C?E:N,C)),C=y.length):0===s&&(u++,y=[0]),v[d++]=u,s&&y[0]?y[C++]=_[T]||0:(y=[_[T]],C=1)}while((T++<w||void 0!==y[0])&&S--)}return v[0]||v.shift(),g.e=l,I(g,a?r+O(g)+1:r)}}();function w(e,t){var i,n,o,a,s,c=0,d=0,h=e.constructor,g=h.precision;if(O(e)>16)throw Error(u+O(e));if(!e.s)return new h(r);for(null==t?(l=!1,s=g):s=t,a=new h(.03125);e.abs().gte(.1);)e=e.times(a),d+=5;for(s+=Math.log(p(2,d))/Math.LN10*2+5|0,i=n=o=new h(r),h.precision=s;;){if(n=I(n.times(e),s),i=i.times(++c),x((a=o.plus(T(n,i,s))).d).slice(0,s)===x(o.d).slice(0,s)){for(;d--;)o=I(o.times(o),s);return h.precision=g,null==t?(l=!0,I(o,g)):o}o=a}}function O(e){for(var t=e.e*m,i=e.d[0];i>=10;i/=10)t++;return t}function P(e,t,i){if(t>e.LN10.sd())throw l=!0,i&&(e.precision=i),Error(c+"LN10 precision limit exceeded");return I(new e(e.LN10),t)}function A(e){for(var t="";e--;)t+="0";return t}function E(e,t){var i,n,o,a,s,d,u,h,p,g=1,f=e,m=f.d,v=f.constructor,y=v.precision;if(f.s<1)throw Error(c+(f.s?"NaN":"-Infinity"));if(f.eq(r))return new v(0);if(null==t?(l=!1,h=y):h=t,f.eq(10))return null==t&&(l=!0),P(v,h);if(h+=10,v.precision=h,n=(i=x(m)).charAt(0),a=O(f),!(Math.abs(a)<15e14))return u=P(v,h+2,y).times(a+""),f=E(new v(n+"."+i.slice(1)),h-10).plus(u),v.precision=y,null==t?(l=!0,I(f,y)):f;for(;n<7&&1!=n||1==n&&i.charAt(1)>3;)n=(i=x((f=f.times(e)).d)).charAt(0),g++;for(a=O(f),n>1?(f=new v("0."+i),a++):f=new v(n+"."+i.slice(1)),d=s=f=T(f.minus(r),f.plus(r),h),p=I(f.times(f),h),o=3;;){if(s=I(s.times(p),h),x((u=d.plus(T(s,new v(o),h))).d).slice(0,h)===x(d.d).slice(0,h))return d=d.times(2),0!==a&&(d=d.plus(P(v,h+2,y).times(a+""))),d=T(d,new v(g),h),v.precision=y,null==t?(l=!0,I(d,y)):d;d=u,o+=2}}function k(e,t){var i,n,o;for((i=t.indexOf("."))>-1&&(t=t.replace(".","")),(n=t.search(/e/i))>0?(i<0&&(i=n),i+=+t.slice(n+1),t=t.substring(0,n)):i<0&&(i=t.length),n=0;48===t.charCodeAt(n);)++n;for(o=t.length;48===t.charCodeAt(o-1);)--o;if(t=t.slice(n,o)){if(o-=n,i=i-n-1,e.e=h(i/m),e.d=[],n=(i+1)%m,i<0&&(n+=m),n<o){for(n&&e.d.push(+t.slice(0,n)),o-=m;n<o;)e.d.push(+t.slice(n,n+=m));t=t.slice(n),n=m-t.length}else n-=o;for(;n--;)t+="0";if(e.d.push(+t),l&&(e.e>y||e.e<-y))throw Error(u+i)}else e.s=0,e.e=0,e.d=[0];return e}function I(e,t,i){var n,o,r,a,s,c,d,g,v=e.d;for(a=1,r=v[0];r>=10;r/=10)a++;if((n=t-a)<0)n+=m,o=t,d=v[g=0];else{if((g=Math.ceil((n+1)/m))>=(r=v.length))return e;for(d=r=v[g],a=1;r>=10;r/=10)a++;o=(n%=m)-m+a}if(void 0!==i&&(s=d/(r=p(10,a-o-1))%10|0,c=t<0||void 0!==v[g+1]||d%r,c=i<4?(s||c)&&(0==i||i==(e.s<0?3:2)):s>5||5==s&&(4==i||c||6==i&&(n>0?o>0?d/p(10,a-o):0:v[g-1])%10&1||i==(e.s<0?8:7))),t<1||!v[0])return c?(r=O(e),v.length=1,t=t-r-1,v[0]=p(10,(m-t%m)%m),e.e=h(-t/m)||0):(v.length=1,v[0]=e.e=e.s=0),e;if(0==n?(v.length=g,r=1,g--):(v.length=g+1,r=p(10,m-n),v[g]=o>0?(d/p(10,a-o)%p(10,o)|0)*r:0),c)for(;;){if(0==g){(v[0]+=r)==f&&(v[0]=1,++e.e);break}if(v[g]+=r,v[g]!=f)break;v[g--]=0,r=1}for(n=v.length;0===v[--n];)v.pop();if(l&&(e.e>y||e.e<-y))throw Error(u+O(e));return e}function D(e,t){var i,n,o,r,a,s,c,d,u,h,p=e.constructor,g=p.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new p(e),l?I(t,g):t;if(c=e.d,h=t.d,n=t.e,d=e.e,c=c.slice(),a=d-n){for((u=a<0)?(i=c,a=-a,s=h.length):(i=h,n=d,s=c.length),a>(o=Math.max(Math.ceil(g/m),s)+2)&&(a=o,i.length=1),i.reverse(),o=a;o--;)i.push(0);i.reverse()}else{for((u=(o=c.length)<(s=h.length))&&(s=o),o=0;o<s;o++)if(c[o]!=h[o]){u=c[o]<h[o];break}a=0}for(u&&(i=c,c=h,h=i,t.s=-t.s),s=c.length,o=h.length-s;o>0;--o)c[s++]=0;for(o=h.length;o>a;){if(c[--o]<h[o]){for(r=o;r&&0===c[--r];)c[r]=f-1;--c[r],c[o]+=f}c[o]-=h[o]}for(;0===c[--s];)c.pop();for(;0===c[0];c.shift())--n;return c[0]?(t.d=c,t.e=n,l?I(t,g):t):new p(0)}function _(e,t,i){var n,o=O(e),r=x(e.d),a=r.length;return t?(i&&(n=i-a)>0?r=r.charAt(0)+"."+r.slice(1)+A(n):a>1&&(r=r.charAt(0)+"."+r.slice(1)),r=r+(o<0?"e":"e+")+o):o<0?(r="0."+A(-o-1)+r,i&&(n=i-a)>0&&(r+=A(n))):o>=a?(r+=A(o+1-a),i&&(n=i-o-1)>0&&(r=r+"."+A(n))):((n=o+1)<a&&(r=r.slice(0,n)+"."+r.slice(n)),i&&(n=i-a)>0&&(o+1===a&&(r+="."),r+=A(n))),e.s<0?"-"+r:r}function N(e,t){if(e.length>t)return e.length=t,!0}function R(e){if(!e||"object"!=typeof e)throw Error(c+"Object expected");var t,i,n,o=["precision",1,a,"rounding",0,8,"toExpNeg",-1/0,0,"toExpPos",0,1/0];for(t=0;t<o.length;t+=3)if(void 0!==(n=e[i=o[t]])){if(!(h(n)===n&&n>=o[t+1]&&n<=o[t+2]))throw Error(d+i+": "+n);this[i]=n}if(void 0!==(n=e[i="LN10"])){if(n!=Math.LN10)throw Error(d+i+": "+n);this[i]=new this(n)}return this}(s=function e(t){var i,n,o;function r(e){var t=this;if(!(t instanceof r))return new r(e);if(t.constructor=r,e instanceof r)return t.s=e.s,t.e=e.e,void(t.d=(e=e.d)?e.slice():e);if("number"==typeof e){if(0*e!=0)throw Error(d+e);if(e>0)t.s=1;else{if(!(e<0))return t.s=0,t.e=0,void(t.d=[0]);e=-e,t.s=-1}return e===~~e&&e<1e7?(t.e=0,void(t.d=[e])):k(t,e.toString())}if("string"!=typeof e)throw Error(d+e);if(45===e.charCodeAt(0)?(e=e.slice(1),t.s=-1):t.s=1,!g.test(e))throw Error(d+e);k(t,e)}if(r.prototype=C,r.ROUND_UP=0,r.ROUND_DOWN=1,r.ROUND_CEIL=2,r.ROUND_FLOOR=3,r.ROUND_HALF_UP=4,r.ROUND_HALF_DOWN=5,r.ROUND_HALF_EVEN=6,r.ROUND_HALF_CEIL=7,r.ROUND_HALF_FLOOR=8,r.clone=e,r.config=r.set=R,void 0===t&&(t={}),t)for(o=["precision","rounding","toExpNeg","toExpPos","LN10"],i=0;i<o.length;)t.hasOwnProperty(n=o[i++])||(t[n]=this[n]);return r.config(t),r}(s)).default=s.Decimal=s,r=new s(1),void 0===(n=function(){return s}.call(t,i,t,e))||(e.exports=n)}()},40764:function(e){"use strict";var t=Object.prototype.hasOwnProperty,i="~";function n(){}function o(e,t,i){this.fn=e,this.context=t,this.once=i||!1}function r(e,t,n,r,a){if("function"!=typeof n)throw new TypeError("The listener must be a function");var s=new o(n,r||e,a),l=i?i+t:t;return e._events[l]?e._events[l].fn?e._events[l]=[e._events[l],s]:e._events[l].push(s):(e._events[l]=s,e._eventsCount++),e}function a(e,t){0==--e._eventsCount?e._events=new n:delete e._events[t]}function s(){this._events=new n,this._eventsCount=0}Object.create&&(n.prototype=Object.create(null),(new n).__proto__||(i=!1)),s.prototype.eventNames=function(){var e,n,o=[];if(0===this._eventsCount)return o;for(n in e=this._events)t.call(e,n)&&o.push(i?n.slice(1):n);return Object.getOwnPropertySymbols?o.concat(Object.getOwnPropertySymbols(e)):o},s.prototype.listeners=function(e){var t=i?i+e:e,n=this._events[t];if(!n)return[];if(n.fn)return[n.fn];for(var o=0,r=n.length,a=new Array(r);o<r;o++)a[o]=n[o].fn;return a},s.prototype.listenerCount=function(e){var t=i?i+e:e,n=this._events[t];return n?n.fn?1:n.length:0},s.prototype.emit=function(e,t,n,o,r,a){var s=i?i+e:e;if(!this._events[s])return!1;var l,c,d=this._events[s],u=arguments.length;if(d.fn){switch(d.once&&this.removeListener(e,d.fn,void 0,!0),u){case 1:return d.fn.call(d.context),!0;case 2:return d.fn.call(d.context,t),!0;case 3:return d.fn.call(d.context,t,n),!0;case 4:return d.fn.call(d.context,t,n,o),!0;case 5:return d.fn.call(d.context,t,n,o,r),!0;case 6:return d.fn.call(d.context,t,n,o,r,a),!0}for(c=1,l=new Array(u-1);c<u;c++)l[c-1]=arguments[c];d.fn.apply(d.context,l)}else{var h,p=d.length;for(c=0;c<p;c++)switch(d[c].once&&this.removeListener(e,d[c].fn,void 0,!0),u){case 1:d[c].fn.call(d[c].context);break;case 2:d[c].fn.call(d[c].context,t);break;case 3:d[c].fn.call(d[c].context,t,n);break;case 4:d[c].fn.call(d[c].context,t,n,o);break;default:if(!l)for(h=1,l=new Array(u-1);h<u;h++)l[h-1]=arguments[h];d[c].fn.apply(d[c].context,l)}}return!0},s.prototype.on=function(e,t,i){return r(this,e,t,i,!1)},s.prototype.once=function(e,t,i){return r(this,e,t,i,!0)},s.prototype.removeListener=function(e,t,n,o){var r=i?i+e:e;if(!this._events[r])return this;if(!t)return a(this,r),this;var s=this._events[r];if(s.fn)s.fn!==t||o&&!s.once||n&&s.context!==n||a(this,r);else{for(var l=0,c=[],d=s.length;l<d;l++)(s[l].fn!==t||o&&!s[l].once||n&&s[l].context!==n)&&c.push(s[l]);c.length?this._events[r]=1===c.length?c[0]:c:a(this,r)}return this},s.prototype.removeAllListeners=function(e){var t;return e?(t=i?i+e:e,this._events[t]&&a(this,t)):(this._events=new n,this._eventsCount=0),this},s.prototype.off=s.prototype.removeListener,s.prototype.addListener=s.prototype.on,s.prefixed=i,s.EventEmitter=s,e.exports=s},20495:function(e,t,i){"use strict";var n=i(37787),o={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},r={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},a={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},s={};function l(e){return n.isMemo(e)?a:s[e.$$typeof]||o}s[n.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},s[n.Memo]=a;var c=Object.defineProperty,d=Object.getOwnPropertyNames,u=Object.getOwnPropertySymbols,h=Object.getOwnPropertyDescriptor,p=Object.getPrototypeOf,g=Object.prototype;e.exports=function e(t,i,n){if("string"!=typeof i){if(g){var o=p(i);o&&o!==g&&e(t,o,n)}var a=d(i);u&&(a=a.concat(u(i)));for(var s=l(t),f=l(i),m=0;m<a.length;++m){var v=a[m];if(!(r[v]||n&&n[v]||f&&f[v]||s&&s[v])){var y=h(i,v);try{c(t,v,y)}catch(e){}}}}return t}},77793:function(e,t,i){"use strict";i.d(t,{PW:function(){return r},Vm:function(){return p},ev:function(){return s},ub:function(){return g}});const n="undefined"!=typeof WeakRef;class o{constructor(e){n&&"object"==typeof e?this._weakRef=new WeakRef(e):this._instance=e}deref(){var e,t,i;let n;return this._weakRef?(n=null===(e=this._weakRef)||void 0===e?void 0:e.deref(),n||delete this._weakRef):(n=this._instance,(null===(i=null===(t=n)||void 0===t?void 0:t.isDisposed)||void 0===i?void 0:i.call(t))&&delete this._instance),n}}const r="keyborg:focusin";let a=!1;function s(e){const t=e.focus;t.__keyborgNativeFocus?t.__keyborgNativeFocus.call(e):e.focus()}let l=0;class c{constructor(){this.__keyborgCoreRefs={},this._isNavigatingWithKeyboard=!1}add(e){const t=e.id;t in this.__keyborgCoreRefs||(this.__keyborgCoreRefs[t]=new o(e))}remove(e){delete this.__keyborgCoreRefs[e],0===Object.keys(this.__keyborgCoreRefs).length&&(this._isNavigatingWithKeyboard=!1)}setVal(e){if(this._isNavigatingWithKeyboard!==e){this._isNavigatingWithKeyboard=e;for(const t of Object.keys(this.__keyborgCoreRefs)){const i=this.__keyborgCoreRefs[t].deref();i?i.update(e):this.remove(t)}}}getVal(){return this._isNavigatingWithKeyboard}}const d=new c;class u{constructor(e,t){this._onFocusIn=e=>{if(this._isMouseUsedTimer)return;if(d.getVal())return;const t=e.details;t.relatedTarget&&(t.isFocusedProgrammatically||void 0===t.isFocusedProgrammatically||d.setVal(!0))},this._onMouseDown=e=>{if(0===e.buttons||0===e.clientX&&0===e.clientY&&0===e.screenX&&0===e.screenY)return;const t=this._win;t&&(this._isMouseUsedTimer&&t.clearTimeout(this._isMouseUsedTimer),this._isMouseUsedTimer=t.setTimeout((()=>{delete this._isMouseUsedTimer}),1e3)),d.setVal(!1)},this._onKeyDown=e=>{var t;const i=d.getVal(),n=e.keyCode,o=this._triggerKeys;i||o&&!o.has(n)?i&&(null===(t=this._dismissKeys)||void 0===t?void 0:t.has(n))&&this._scheduleDismiss():d.setVal(!0)},this.id="c"+ ++l,this._win=e;const i=e.document;if(t){const e=t.triggerKeys,i=t.dismissKeys;(null==e?void 0:e.length)&&(this._triggerKeys=new Set(e)),(null==i?void 0:i.length)&&(this._dismissKeys=new Set(i))}i.addEventListener(r,this._onFocusIn,!0),i.addEventListener("mousedown",this._onMouseDown,!0),e.addEventListener("keydown",this._onKeyDown,!0),function(e){const t=e;a||(a=function(e){const t=e.HTMLElement,i=t.prototype.focus;let n=!1;return t.prototype.focus=function(){n=!0},e.document.createElement("button").focus(),t.prototype.focus=i,n}(t));const i=t.HTMLElement.prototype.focus;if(i.__keyborgNativeFocus)return;t.HTMLElement.prototype.focus=s;const n=t.__keyborgData={focusInHandler:e=>{var t;const i=e.target;if(!i)return;const o=document.createEvent("HTMLEvents");o.initEvent(r,!0,!0);const s={relatedTarget:e.relatedTarget||void 0};(a||n.lastFocusedProgrammatically)&&(s.isFocusedProgrammatically=i===(null===(t=n.lastFocusedProgrammatically)||void 0===t?void 0:t.deref()),n.lastFocusedProgrammatically=void 0),o.details=s,i.dispatchEvent(o)}};function s(){const e=t.__keyborgData;return e&&(e.lastFocusedProgrammatically=new o(this)),i.apply(this,arguments)}t.document.addEventListener("focusin",t.__keyborgData.focusInHandler,!0),s.__keyborgNativeFocus=i}(e),d.add(this)}dispose(){const e=this._win;if(e){this._isMouseUsedTimer&&(e.clearTimeout(this._isMouseUsedTimer),this._isMouseUsedTimer=void 0),this._dismissTimer&&(e.clearTimeout(this._dismissTimer),this._dismissTimer=void 0),function(e){const t=e,i=t.HTMLElement.prototype,n=i.focus.__keyborgNativeFocus,o=t.__keyborgData;o&&(t.document.removeEventListener("focusin",o.focusInHandler,!0),delete t.__keyborgData),n&&(i.focus=n)}(e);const t=e.document;t.removeEventListener(r,this._onFocusIn,!0),t.removeEventListener("mousedown",this._onMouseDown,!0),e.removeEventListener("keydown",this._onKeyDown,!0),delete this._win,d.remove(this.id)}}isDisposed(){return!!this._win}update(e){var t,i;const n=null===(i=null===(t=this._win)||void 0===t?void 0:t.__keyborg)||void 0===i?void 0:i.refs;if(n)for(const t of Object.keys(n))h.update(n[t],e)}_scheduleDismiss(){const e=this._win;if(e){this._dismissTimer&&(e.clearTimeout(this._dismissTimer),this._dismissTimer=void 0);const t=e.document.activeElement;this._dismissTimer=e.setTimeout((()=>{this._dismissTimer=void 0;const i=e.document.activeElement;t&&i&&t===i&&d.setVal(!1)}),500)}}}class h{constructor(e,t){this._cb=[],this._id="k"+ ++l,this._win=e;const i=e.__keyborg;i?(this._core=i.core,i.refs[this._id]=this):(this._core=new u(e,t),e.__keyborg={core:this._core,refs:{[this._id]:this}})}static create(e,t){return new h(e,t)}static dispose(e){e.dispose()}static update(e,t){e._cb.forEach((e=>e(t)))}dispose(){var e;const t=null===(e=this._win)||void 0===e?void 0:e.__keyborg;(null==t?void 0:t.refs[this._id])&&(delete t.refs[this._id],0===Object.keys(t.refs).length&&(t.core.dispose(),delete this._win.__keyborg)),this._cb=[],delete this._core,delete this._win}isNavigatingWithKeyboard(){return d.getVal()}subscribe(e){this._cb.push(e)}unsubscribe(e){const t=this._cb.indexOf(e);t>=0&&this._cb.splice(t,1)}setVal(e){d.setVal(e)}}function p(e,t){return h.create(e,t)}function g(e){h.dispose(e)}},49446:function(e,t,i){var n=i(8603)(i(77332),"DataView");e.exports=n},8236:function(e,t,i){var n=i(12216),o=i(48934),r=i(48928),a=i(47118),s=i(75246);function l(e){var t=-1,i=null==e?0:e.length;for(this.clear();++t<i;){var n=e[t];this.set(n[0],n[1])}}l.prototype.clear=n,l.prototype.delete=o,l.prototype.get=r,l.prototype.has=a,l.prototype.set=s,e.exports=l},96999:function(e,t,i){var n=i(22619),o=i(10710),r=i(62810),a=i(42277),s=i(28182);function l(e){var t=-1,i=null==e?0:e.length;for(this.clear();++t<i;){var n=e[t];this.set(n[0],n[1])}}l.prototype.clear=n,l.prototype.delete=o,l.prototype.get=r,l.prototype.has=a,l.prototype.set=s,e.exports=l},29869:function(e,t,i){var n=i(8603)(i(77332),"Map");e.exports=n},40618:function(e,t,i){var n=i(55466),o=i(23155),r=i(59459),a=i(83706),s=i(49753);function l(e){var t=-1,i=null==e?0:e.length;for(this.clear();++t<i;){var n=e[t];this.set(n[0],n[1])}}l.prototype.clear=n,l.prototype.delete=o,l.prototype.get=r,l.prototype.has=a,l.prototype.set=s,e.exports=l},60098:function(e,t,i){var n=i(8603)(i(77332),"Promise");e.exports=n},94897:function(e,t,i){var n=i(8603)(i(77332),"Set");e.exports=n},55581:function(e,t,i){var n=i(40618),o=i(46407),r=i(54514);function a(e){var t=-1,i=null==e?0:e.length;for(this.__data__=new n;++t<i;)this.add(e[t])}a.prototype.add=a.prototype.push=o,a.prototype.has=r,e.exports=a},88497:function(e,t,i){var n=i(96999),o=i(45006),r=i(17622),a=i(62307),s=i(9554),l=i(30790);function c(e){var t=this.__data__=new n(e);this.size=t.size}c.prototype.clear=o,c.prototype.delete=r,c.prototype.get=a,c.prototype.has=s,c.prototype.set=l,e.exports=c},50431:function(e,t,i){var n=i(77332).Symbol;e.exports=n},82421:function(e,t,i){var n=i(77332).Uint8Array;e.exports=n},70159:function(e,t,i){var n=i(8603)(i(77332),"WeakMap");e.exports=n},38956:function(e){e.exports=function(e,t,i){switch(i.length){case 0:return e.call(t);case 1:return e.call(t,i[0]);case 2:return e.call(t,i[0],i[1]);case 3:return e.call(t,i[0],i[1],i[2])}return e.apply(t,i)}},67452:function(e){e.exports=function(e,t){for(var i=-1,n=null==e?0:e.length;++i<n;)if(!t(e[i],i,e))return!1;return!0}},62012:function(e){e.exports=function(e,t){for(var i=-1,n=null==e?0:e.length,o=0,r=[];++i<n;){var a=e[i];t(a,i,e)&&(r[o++]=a)}return r}},83326:function(e,t,i){var n=i(34708);e.exports=function(e,t){return!(null==e||!e.length)&&n(e,t,0)>-1}},33549:function(e){e.exports=function(e,t,i){for(var n=-1,o=null==e?0:e.length;++n<o;)if(i(t,e[n]))return!0;return!1}},27943:function(e,t,i){var n=i(92142),o=i(79774),r=i(83008),a=i(30550),s=i(75934),l=i(8635),c=Object.prototype.hasOwnProperty;e.exports=function(e,t){var i=r(e),d=!i&&o(e),u=!i&&!d&&a(e),h=!i&&!d&&!u&&l(e),p=i||d||u||h,g=p?n(e.length,String):[],f=g.length;for(var m in e)!t&&!c.call(e,m)||p&&("length"==m||u&&("offset"==m||"parent"==m)||h&&("buffer"==m||"byteLength"==m||"byteOffset"==m)||s(m,f))||g.push(m);return g}},96457:function(e){e.exports=function(e,t){for(var i=-1,n=null==e?0:e.length,o=Array(n);++i<n;)o[i]=t(e[i],i,e);return o}},10323:function(e){e.exports=function(e,t){for(var i=-1,n=t.length,o=e.length;++i<n;)e[o+i]=t[i];return e}},76605:function(e){e.exports=function(e,t){for(var i=-1,n=null==e?0:e.length;++i<n;)if(t(e[i],i,e))return!0;return!1}},33899:function(e){e.exports=function(e){return e.split("")}},66779:function(e,t,i){var n=i(31502);e.exports=function(e,t){for(var i=e.length;i--;)if(n(e[i][0],t))return i;return-1}},95045:function(e,t,i){var n=i(25798);e.exports=function(e,t,i){"__proto__"==t&&n?n(e,t,{configurable:!0,enumerable:!0,value:i,writable:!0}):e[t]=i}},49351:function(e,t,i){var n=i(75058),o=i(76889)(n);e.exports=o},83568:function(e,t,i){var n=i(49351);e.exports=function(e,t){var i=!0;return n(e,(function(e,n,o){return i=!!t(e,n,o)})),i}},33989:function(e,t,i){var n=i(44308);e.exports=function(e,t,i){for(var o=-1,r=e.length;++o<r;){var a=e[o],s=t(a);if(null!=s&&(void 0===l?s==s&&!n(s):i(s,l)))var l=s,c=a}return c}},46975:function(e){e.exports=function(e,t,i,n){for(var o=e.length,r=i+(n?1:-1);n?r--:++r<o;)if(t(e[r],r,e))return r;return-1}},89442:function(e,t,i){var n=i(10323),o=i(87036);e.exports=function e(t,i,r,a,s){var l=-1,c=t.length;for(r||(r=o),s||(s=[]);++l<c;){var d=t[l];i>0&&r(d)?i>1?e(d,i-1,r,a,s):n(s,d):a||(s[s.length]=d)}return s}},57172:function(e,t,i){var n=i(91231)();e.exports=n},75058:function(e,t,i){var n=i(57172),o=i(33045);e.exports=function(e,t){return e&&n(e,t,o)}},1653:function(e,t,i){var n=i(58739),o=i(15222);e.exports=function(e,t){for(var i=0,r=(t=n(t,e)).length;null!=e&&i<r;)e=e[o(t[i++])];return i&&i==r?e:void 0}},47609:function(e,t,i){var n=i(10323),o=i(83008);e.exports=function(e,t,i){var r=t(e);return o(e)?r:n(r,i(e))}},37663:function(e,t,i){var n=i(50431),o=i(64854),r=i(50078),a=n?n.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":a&&a in Object(e)?o(e):r(e)}},3006:function(e){e.exports=function(e,t){return e>t}},76454:function(e){e.exports=function(e,t){return null!=e&&t in Object(e)}},34708:function(e,t,i){var n=i(46975),o=i(41994),r=i(12205);e.exports=function(e,t,i){return t==t?r(e,t,i):n(e,o,i)}},50969:function(e,t,i){var n=i(37663),o=i(94488);e.exports=function(e){return o(e)&&"[object Arguments]"==n(e)}},20625:function(e,t,i){var n=i(29503),o=i(94488);e.exports=function e(t,i,r,a,s){return t===i||(null==t||null==i||!o(t)&&!o(i)?t!=t&&i!=i:n(t,i,r,a,e,s))}},29503:function(e,t,i){var n=i(88497),o=i(13777),r=i(10512),a=i(71095),s=i(42267),l=i(83008),c=i(30550),d=i(8635),u="[object Arguments]",h="[object Array]",p="[object Object]",g=Object.prototype.hasOwnProperty;e.exports=function(e,t,i,f,m,v){var y=l(e),C=l(t),b=y?h:s(e),S=C?h:s(t),x=(b=b==u?p:b)==p,T=(S=S==u?p:S)==p,w=b==S;if(w&&c(e)){if(!c(t))return!1;y=!0,x=!1}if(w&&!x)return v||(v=new n),y||d(e)?o(e,t,i,f,m,v):r(e,t,b,i,f,m,v);if(!(1&i)){var O=x&&g.call(e,"__wrapped__"),P=T&&g.call(t,"__wrapped__");if(O||P){var A=O?e.value():e,E=P?t.value():t;return v||(v=new n),m(A,E,i,f,v)}}return!!w&&(v||(v=new n),a(e,t,i,f,m,v))}},69026:function(e,t,i){var n=i(88497),o=i(20625);e.exports=function(e,t,i,r){var a=i.length,s=a,l=!r;if(null==e)return!s;for(e=Object(e);a--;){var c=i[a];if(l&&c[2]?c[1]!==e[c[0]]:!(c[0]in e))return!1}for(;++a<s;){var d=(c=i[a])[0],u=e[d],h=c[1];if(l&&c[2]){if(void 0===u&&!(d in e))return!1}else{var p=new n;if(r)var g=r(u,h,d,e,t,p);if(!(void 0===g?o(h,u,3,r,p):g))return!1}}return!0}},41994:function(e){e.exports=function(e){return e!=e}},77342:function(e,t,i){var n=i(40825),o=i(70660),r=i(63991),a=i(66082),s=/^\[object .+?Constructor\]$/,l=Function.prototype,c=Object.prototype,d=l.toString,u=c.hasOwnProperty,h=RegExp("^"+d.call(u).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");e.exports=function(e){return!(!r(e)||o(e))&&(n(e)?h:s).test(a(e))}},98084:function(e,t,i){var n=i(37663),o=i(62904),r=i(94488),a={};a["[object Float32Array]"]=a["[object Float64Array]"]=a["[object Int8Array]"]=a["[object Int16Array]"]=a["[object Int32Array]"]=a["[object Uint8Array]"]=a["[object Uint8ClampedArray]"]=a["[object Uint16Array]"]=a["[object Uint32Array]"]=!0,a["[object Arguments]"]=a["[object Array]"]=a["[object ArrayBuffer]"]=a["[object Boolean]"]=a["[object DataView]"]=a["[object Date]"]=a["[object Error]"]=a["[object Function]"]=a["[object Map]"]=a["[object Number]"]=a["[object Object]"]=a["[object RegExp]"]=a["[object Set]"]=a["[object String]"]=a["[object WeakMap]"]=!1,e.exports=function(e){return r(e)&&o(e.length)&&!!a[n(e)]}},51761:function(e,t,i){var n=i(69085),o=i(50067),r=i(34981),a=i(83008),s=i(48387);e.exports=function(e){return"function"==typeof e?e:null==e?r:"object"==typeof e?a(e)?o(e[0],e[1]):n(e):s(e)}},42580:function(e,t,i){var n=i(50012),o=i(5703),r=Object.prototype.hasOwnProperty;e.exports=function(e){if(!n(e))return o(e);var t=[];for(var i in Object(e))r.call(e,i)&&"constructor"!=i&&t.push(i);return t}},5201:function(e){e.exports=function(e,t){return e<t}},68821:function(e,t,i){var n=i(49351),o=i(32335);e.exports=function(e,t){var i=-1,r=o(e)?Array(e.length):[];return n(e,(function(e,n,o){r[++i]=t(e,n,o)})),r}},69085:function(e,t,i){var n=i(69026),o=i(24896),r=i(8026);e.exports=function(e){var t=o(e);return 1==t.length&&t[0][2]?r(t[0][0],t[0][1]):function(i){return i===e||n(i,e,t)}}},50067:function(e,t,i){var n=i(20625),o=i(71758),r=i(49044),a=i(98984),s=i(7573),l=i(8026),c=i(15222);e.exports=function(e,t){return a(e)&&s(t)?l(c(e),t):function(i){var a=o(i,e);return void 0===a&&a===t?r(i,e):n(t,a,3)}}},48463:function(e,t,i){var n=i(96457),o=i(1653),r=i(51761),a=i(68821),s=i(91411),l=i(51648),c=i(43990),d=i(34981),u=i(83008);e.exports=function(e,t,i){t=t.length?n(t,(function(e){return u(e)?function(t){return o(t,1===e.length?e[0]:e)}:e})):[d];var h=-1;t=n(t,l(r));var p=a(e,(function(e,i,o){return{criteria:n(t,(function(t){return t(e)})),index:++h,value:e}}));return s(p,(function(e,t){return c(e,t,i)}))}},76543:function(e){e.exports=function(e){return function(t){return null==t?void 0:t[e]}}},72626:function(e,t,i){var n=i(1653);e.exports=function(e){return function(t){return n(t,e)}}},20645:function(e){var t=Math.ceil,i=Math.max;e.exports=function(e,n,o,r){for(var a=-1,s=i(t((n-e)/(o||1)),0),l=Array(s);s--;)l[r?s:++a]=e,e+=o;return l}},28947:function(e,t,i){var n=i(34981),o=i(51206),r=i(71464);e.exports=function(e,t){return r(o(e,t,n),e+"")}},25153:function(e,t,i){var n=i(74467),o=i(25798),r=i(34981),a=o?function(e,t){return o(e,"toString",{configurable:!0,enumerable:!1,value:n(t),writable:!0})}:r;e.exports=a},54179:function(e){e.exports=function(e,t,i){var n=-1,o=e.length;t<0&&(t=-t>o?0:o+t),(i=i>o?o:i)<0&&(i+=o),o=t>i?0:i-t>>>0,t>>>=0;for(var r=Array(o);++n<o;)r[n]=e[n+t];return r}},31349:function(e,t,i){var n=i(49351);e.exports=function(e,t){var i;return n(e,(function(e,n,o){return!(i=t(e,n,o))})),!!i}},91411:function(e){e.exports=function(e,t){var i=e.length;for(e.sort(t);i--;)e[i]=e[i].value;return e}},92142:function(e){e.exports=function(e,t){for(var i=-1,n=Array(e);++i<e;)n[i]=t(i);return n}},13986:function(e,t,i){var n=i(50431),o=i(96457),r=i(83008),a=i(44308),s=n?n.prototype:void 0,l=s?s.toString:void 0;e.exports=function e(t){if("string"==typeof t)return t;if(r(t))return o(t,e)+"";if(a(t))return l?l.call(t):"";var i=t+"";return"0"==i&&1/t==-1/0?"-0":i}},79856:function(e,t,i){var n=i(80011),o=/^\s+/;e.exports=function(e){return e?e.slice(0,n(e)+1).replace(o,""):e}},51648:function(e){e.exports=function(e){return function(t){return e(t)}}},96567:function(e,t,i){var n=i(55581),o=i(83326),r=i(33549),a=i(92437),s=i(368),l=i(9674);e.exports=function(e,t,i){var c=-1,d=o,u=e.length,h=!0,p=[],g=p;if(i)h=!1,d=r;else if(u>=200){var f=t?null:s(e);if(f)return l(f);h=!1,d=a,g=new n}else g=t?[]:p;e:for(;++c<u;){var m=e[c],v=t?t(m):m;if(m=i||0!==m?m:0,h&&v==v){for(var y=g.length;y--;)if(g[y]===v)continue e;t&&g.push(v),p.push(m)}else d(g,v,i)||(g!==p&&g.push(v),p.push(m))}return p}},92437:function(e){e.exports=function(e,t){return e.has(t)}},58739:function(e,t,i){var n=i(83008),o=i(98984),r=i(36912),a=i(44139);e.exports=function(e,t){return n(e)?e:o(e,t)?[e]:r(a(e))}},49788:function(e,t,i){var n=i(54179);e.exports=function(e,t,i){var o=e.length;return i=void 0===i?o:i,!t&&i>=o?e:n(e,t,i)}},59697:function(e,t,i){var n=i(44308);e.exports=function(e,t){if(e!==t){var i=void 0!==e,o=null===e,r=e==e,a=n(e),s=void 0!==t,l=null===t,c=t==t,d=n(t);if(!l&&!d&&!a&&e>t||a&&s&&c&&!l&&!d||o&&s&&c||!i&&c||!r)return 1;if(!o&&!a&&!d&&e<t||d&&i&&r&&!o&&!a||l&&i&&r||!s&&r||!c)return-1}return 0}},43990:function(e,t,i){var n=i(59697);e.exports=function(e,t,i){for(var o=-1,r=e.criteria,a=t.criteria,s=r.length,l=i.length;++o<s;){var c=n(r[o],a[o]);if(c)return o>=l?c:c*("desc"==i[o]?-1:1)}return e.index-t.index}},58005:function(e,t,i){var n=i(77332)["__core-js_shared__"];e.exports=n},76889:function(e,t,i){var n=i(32335);e.exports=function(e,t){return function(i,o){if(null==i)return i;if(!n(i))return e(i,o);for(var r=i.length,a=t?r:-1,s=Object(i);(t?a--:++a<r)&&!1!==o(s[a],a,s););return i}}},91231:function(e){e.exports=function(e){return function(t,i,n){for(var o=-1,r=Object(t),a=n(t),s=a.length;s--;){var l=a[e?s:++o];if(!1===i(r[l],l,r))break}return t}}},83320:function(e,t,i){var n=i(49788),o=i(36619),r=i(82802),a=i(44139);e.exports=function(e){return function(t){t=a(t);var i=o(t)?r(t):void 0,s=i?i[0]:t.charAt(0),l=i?n(i,1).join(""):t.slice(1);return s[e]()+l}}},81481:function(e,t,i){var n=i(20645),o=i(3485),r=i(59477);e.exports=function(e){return function(t,i,a){return a&&"number"!=typeof a&&o(t,i,a)&&(i=a=void 0),t=r(t),void 0===i?(i=t,t=0):i=r(i),a=void 0===a?t<i?1:-1:r(a),n(t,i,a,e)}}},368:function(e,t,i){var n=i(94897),o=i(77730),r=i(9674),a=n&&1/r(new n([,-0]))[1]==1/0?function(e){return new n(e)}:o;e.exports=a},25798:function(e,t,i){var n=i(8603),o=function(){try{var e=n(Object,"defineProperty");return e({},"",{}),e}catch(e){}}();e.exports=o},13777:function(e,t,i){var n=i(55581),o=i(76605),r=i(92437);e.exports=function(e,t,i,a,s,l){var c=1&i,d=e.length,u=t.length;if(d!=u&&!(c&&u>d))return!1;var h=l.get(e),p=l.get(t);if(h&&p)return h==t&&p==e;var g=-1,f=!0,m=2&i?new n:void 0;for(l.set(e,t),l.set(t,e);++g<d;){var v=e[g],y=t[g];if(a)var C=c?a(y,v,g,t,e,l):a(v,y,g,e,t,l);if(void 0!==C){if(C)continue;f=!1;break}if(m){if(!o(t,(function(e,t){if(!r(m,t)&&(v===e||s(v,e,i,a,l)))return m.push(t)}))){f=!1;break}}else if(v!==y&&!s(v,y,i,a,l)){f=!1;break}}return l.delete(e),l.delete(t),f}},10512:function(e,t,i){var n=i(50431),o=i(82421),r=i(31502),a=i(13777),s=i(75373),l=i(9674),c=n?n.prototype:void 0,d=c?c.valueOf:void 0;e.exports=function(e,t,i,n,c,u,h){switch(i){case"[object DataView]":if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case"[object ArrayBuffer]":return!(e.byteLength!=t.byteLength||!u(new o(e),new o(t)));case"[object Boolean]":case"[object Date]":case"[object Number]":return r(+e,+t);case"[object Error]":return e.name==t.name&&e.message==t.message;case"[object RegExp]":case"[object String]":return e==t+"";case"[object Map]":var p=s;case"[object Set]":var g=1&n;if(p||(p=l),e.size!=t.size&&!g)return!1;var f=h.get(e);if(f)return f==t;n|=2,h.set(e,t);var m=a(p(e),p(t),n,c,u,h);return h.delete(e),m;case"[object Symbol]":if(d)return d.call(e)==d.call(t)}return!1}},71095:function(e,t,i){var n=i(72692),o=Object.prototype.hasOwnProperty;e.exports=function(e,t,i,r,a,s){var l=1&i,c=n(e),d=c.length;if(d!=n(t).length&&!l)return!1;for(var u=d;u--;){var h=c[u];if(!(l?h in t:o.call(t,h)))return!1}var p=s.get(e),g=s.get(t);if(p&&g)return p==t&&g==e;var f=!0;s.set(e,t),s.set(t,e);for(var m=l;++u<d;){var v=e[h=c[u]],y=t[h];if(r)var C=l?r(y,v,h,t,e,s):r(v,y,h,e,t,s);if(!(void 0===C?v===y||a(v,y,i,r,s):C)){f=!1;break}m||(m="constructor"==h)}if(f&&!m){var b=e.constructor,S=t.constructor;b==S||!("constructor"in e)||!("constructor"in t)||"function"==typeof b&&b instanceof b&&"function"==typeof S&&S instanceof S||(f=!1)}return s.delete(e),s.delete(t),f}},22421:function(e,t,i){var n="object"==typeof i.g&&i.g&&i.g.Object===Object&&i.g;e.exports=n},72692:function(e,t,i){var n=i(47609),o=i(65863),r=i(33045);e.exports=function(e){return n(e,r,o)}},79056:function(e,t,i){var n=i(64765);e.exports=function(e,t){var i=e.__data__;return n(t)?i["string"==typeof t?"string":"hash"]:i.map}},24896:function(e,t,i){var n=i(7573),o=i(33045);e.exports=function(e){for(var t=o(e),i=t.length;i--;){var r=t[i],a=e[r];t[i]=[r,a,n(a)]}return t}},8603:function(e,t,i){var n=i(77342),o=i(36430);e.exports=function(e,t){var i=o(e,t);return n(i)?i:void 0}},71584:function(e,t,i){var n=i(43907)(Object.getPrototypeOf,Object);e.exports=n},64854:function(e,t,i){var n=i(50431),o=Object.prototype,r=o.hasOwnProperty,a=o.toString,s=n?n.toStringTag:void 0;e.exports=function(e){var t=r.call(e,s),i=e[s];try{e[s]=void 0;var n=!0}catch(e){}var o=a.call(e);return n&&(t?e[s]=i:delete e[s]),o}},65863:function(e,t,i){var n=i(62012),o=i(12825),r=Object.prototype.propertyIsEnumerable,a=Object.getOwnPropertySymbols,s=a?function(e){return null==e?[]:(e=Object(e),n(a(e),(function(t){return r.call(e,t)})))}:o;e.exports=s},42267:function(e,t,i){var n=i(49446),o=i(29869),r=i(60098),a=i(94897),s=i(70159),l=i(37663),c=i(66082),d="[object Map]",u="[object Promise]",h="[object Set]",p="[object WeakMap]",g="[object DataView]",f=c(n),m=c(o),v=c(r),y=c(a),C=c(s),b=l;(n&&b(new n(new ArrayBuffer(1)))!=g||o&&b(new o)!=d||r&&b(r.resolve())!=u||a&&b(new a)!=h||s&&b(new s)!=p)&&(b=function(e){var t=l(e),i="[object Object]"==t?e.constructor:void 0,n=i?c(i):"";if(n)switch(n){case f:return g;case m:return d;case v:return u;case y:return h;case C:return p}return t}),e.exports=b},36430:function(e){e.exports=function(e,t){return null==e?void 0:e[t]}},75825:function(e,t,i){var n=i(58739),o=i(79774),r=i(83008),a=i(75934),s=i(62904),l=i(15222);e.exports=function(e,t,i){for(var c=-1,d=(t=n(t,e)).length,u=!1;++c<d;){var h=l(t[c]);if(!(u=null!=e&&i(e,h)))break;e=e[h]}return u||++c!=d?u:!!(d=null==e?0:e.length)&&s(d)&&a(h,d)&&(r(e)||o(e))}},36619:function(e){var t=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]");e.exports=function(e){return t.test(e)}},12216:function(e,t,i){var n=i(15880);e.exports=function(){this.__data__=n?n(null):{},this.size=0}},48934:function(e){e.exports=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}},48928:function(e,t,i){var n=i(15880),o=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;if(n){var i=t[e];return"__lodash_hash_undefined__"===i?void 0:i}return o.call(t,e)?t[e]:void 0}},47118:function(e,t,i){var n=i(15880),o=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;return n?void 0!==t[e]:o.call(t,e)}},75246:function(e,t,i){var n=i(15880);e.exports=function(e,t){var i=this.__data__;return this.size+=this.has(e)?0:1,i[e]=n&&void 0===t?"__lodash_hash_undefined__":t,this}},87036:function(e,t,i){var n=i(50431),o=i(79774),r=i(83008),a=n?n.isConcatSpreadable:void 0;e.exports=function(e){return r(e)||o(e)||!!(a&&e&&e[a])}},75934:function(e){var t=/^(?:0|[1-9]\d*)$/;e.exports=function(e,i){var n=typeof e;return!!(i=null==i?9007199254740991:i)&&("number"==n||"symbol"!=n&&t.test(e))&&e>-1&&e%1==0&&e<i}},3485:function(e,t,i){var n=i(31502),o=i(32335),r=i(75934),a=i(63991);e.exports=function(e,t,i){if(!a(i))return!1;var s=typeof t;return!!("number"==s?o(i)&&r(t,i.length):"string"==s&&t in i)&&n(i[t],e)}},98984:function(e,t,i){var n=i(83008),o=i(44308),r=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,a=/^\w*$/;e.exports=function(e,t){if(n(e))return!1;var i=typeof e;return!("number"!=i&&"symbol"!=i&&"boolean"!=i&&null!=e&&!o(e))||a.test(e)||!r.test(e)||null!=t&&e in Object(t)}},64765:function(e){e.exports=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}},70660:function(e,t,i){var n,o=i(58005),r=(n=/[^.]+$/.exec(o&&o.keys&&o.keys.IE_PROTO||""))?"Symbol(src)_1."+n:"";e.exports=function(e){return!!r&&r in e}},50012:function(e){var t=Object.prototype;e.exports=function(e){var i=e&&e.constructor;return e===("function"==typeof i&&i.prototype||t)}},7573:function(e,t,i){var n=i(63991);e.exports=function(e){return e==e&&!n(e)}},22619:function(e){e.exports=function(){this.__data__=[],this.size=0}},10710:function(e,t,i){var n=i(66779),o=Array.prototype.splice;e.exports=function(e){var t=this.__data__,i=n(t,e);return!(i<0||(i==t.length-1?t.pop():o.call(t,i,1),--this.size,0))}},62810:function(e,t,i){var n=i(66779);e.exports=function(e){var t=this.__data__,i=n(t,e);return i<0?void 0:t[i][1]}},42277:function(e,t,i){var n=i(66779);e.exports=function(e){return n(this.__data__,e)>-1}},28182:function(e,t,i){var n=i(66779);e.exports=function(e,t){var i=this.__data__,o=n(i,e);return o<0?(++this.size,i.push([e,t])):i[o][1]=t,this}},55466:function(e,t,i){var n=i(8236),o=i(96999),r=i(29869);e.exports=function(){this.size=0,this.__data__={hash:new n,map:new(r||o),string:new n}}},23155:function(e,t,i){var n=i(79056);e.exports=function(e){var t=n(this,e).delete(e);return this.size-=t?1:0,t}},59459:function(e,t,i){var n=i(79056);e.exports=function(e){return n(this,e).get(e)}},83706:function(e,t,i){var n=i(79056);e.exports=function(e){return n(this,e).has(e)}},49753:function(e,t,i){var n=i(79056);e.exports=function(e,t){var i=n(this,e),o=i.size;return i.set(e,t),this.size+=i.size==o?0:1,this}},75373:function(e){e.exports=function(e){var t=-1,i=Array(e.size);return e.forEach((function(e,n){i[++t]=[n,e]})),i}},8026:function(e){e.exports=function(e,t){return function(i){return null!=i&&i[e]===t&&(void 0!==t||e in Object(i))}}},63965:function(e,t,i){var n=i(40560);e.exports=function(e){var t=n(e,(function(e){return 500===i.size&&i.clear(),e})),i=t.cache;return t}},15880:function(e,t,i){var n=i(8603)(Object,"create");e.exports=n},5703:function(e,t,i){var n=i(43907)(Object.keys,Object);e.exports=n},61701:function(e,t,i){e=i.nmd(e);var n=i(22421),o=t&&!t.nodeType&&t,r=o&&e&&!e.nodeType&&e,a=r&&r.exports===o&&n.process,s=function(){try{return r&&r.require&&r.require("util").types||a&&a.binding&&a.binding("util")}catch(e){}}();e.exports=s},50078:function(e){var t=Object.prototype.toString;e.exports=function(e){return t.call(e)}},43907:function(e){e.exports=function(e,t){return function(i){return e(t(i))}}},51206:function(e,t,i){var n=i(38956),o=Math.max;e.exports=function(e,t,i){return t=o(void 0===t?e.length-1:t,0),function(){for(var r=arguments,a=-1,s=o(r.length-t,0),l=Array(s);++a<s;)l[a]=r[t+a];a=-1;for(var c=Array(t+1);++a<t;)c[a]=r[a];return c[t]=i(l),n(e,this,c)}}},77332:function(e,t,i){var n=i(22421),o="object"==typeof self&&self&&self.Object===Object&&self,r=n||o||Function("return this")();e.exports=r},46407:function(e){e.exports=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this}},54514:function(e){e.exports=function(e){return this.__data__.has(e)}},9674:function(e){e.exports=function(e){var t=-1,i=Array(e.size);return e.forEach((function(e){i[++t]=e})),i}},71464:function(e,t,i){var n=i(25153),o=i(75394)(n);e.exports=o},75394:function(e){var t=Date.now;e.exports=function(e){var i=0,n=0;return function(){var o=t(),r=16-(o-n);if(n=o,r>0){if(++i>=800)return arguments[0]}else i=0;return e.apply(void 0,arguments)}}},45006:function(e,t,i){var n=i(96999);e.exports=function(){this.__data__=new n,this.size=0}},17622:function(e){e.exports=function(e){var t=this.__data__,i=t.delete(e);return this.size=t.size,i}},62307:function(e){e.exports=function(e){return this.__data__.get(e)}},9554:function(e){e.exports=function(e){return this.__data__.has(e)}},30790:function(e,t,i){var n=i(96999),o=i(29869),r=i(40618);e.exports=function(e,t){var i=this.__data__;if(i instanceof n){var a=i.__data__;if(!o||a.length<199)return a.push([e,t]),this.size=++i.size,this;i=this.__data__=new r(a)}return i.set(e,t),this.size=i.size,this}},12205:function(e){e.exports=function(e,t,i){for(var n=i-1,o=e.length;++n<o;)if(e[n]===t)return n;return-1}},82802:function(e,t,i){var n=i(33899),o=i(36619),r=i(35155);e.exports=function(e){return o(e)?r(e):n(e)}},36912:function(e,t,i){var n=i(63965),o=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,r=/\\(\\)?/g,a=n((function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(o,(function(e,i,n,o){t.push(n?o.replace(r,"$1"):i||e)})),t}));e.exports=a},15222:function(e,t,i){var n=i(44308);e.exports=function(e){if("string"==typeof e||n(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}},66082:function(e){var t=Function.prototype.toString;e.exports=function(e){if(null!=e){try{return t.call(e)}catch(e){}try{return e+""}catch(e){}}return""}},80011:function(e){var t=/\s/;e.exports=function(e){for(var i=e.length;i--&&t.test(e.charAt(i)););return i}},35155:function(e){var t="\\ud800-\\udfff",i="["+t+"]",n="[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]",o="\\ud83c[\\udffb-\\udfff]",r="[^"+t+"]",a="(?:\\ud83c[\\udde6-\\uddff]){2}",s="[\\ud800-\\udbff][\\udc00-\\udfff]",l="(?:"+n+"|"+o+")?",c="[\\ufe0e\\ufe0f]?",d=c+l+"(?:\\u200d(?:"+[r,a,s].join("|")+")"+c+l+")*",u="(?:"+[r+n+"?",n,a,s,i].join("|")+")",h=RegExp(o+"(?="+o+")|"+u+d,"g");e.exports=function(e){return e.match(h)||[]}},74467:function(e){e.exports=function(e){return function(){return e}}},85075:function(e,t,i){var n=i(63991),o=i(57326),r=i(20824),a=Math.max,s=Math.min;e.exports=function(e,t,i){var l,c,d,u,h,p,g=0,f=!1,m=!1,v=!0;if("function"!=typeof e)throw new TypeError("Expected a function");function y(t){var i=l,n=c;return l=c=void 0,g=t,u=e.apply(n,i)}function C(e){var i=e-p;return void 0===p||i>=t||i<0||m&&e-g>=d}function b(){var e=o();if(C(e))return S(e);h=setTimeout(b,function(e){var i=t-(e-p);return m?s(i,d-(e-g)):i}(e))}function S(e){return h=void 0,v&&l?y(e):(l=c=void 0,u)}function x(){var e=o(),i=C(e);if(l=arguments,c=this,p=e,i){if(void 0===h)return function(e){return g=e,h=setTimeout(b,t),f?y(e):u}(p);if(m)return clearTimeout(h),h=setTimeout(b,t),y(p)}return void 0===h&&(h=setTimeout(b,t)),u}return t=r(t)||0,n(i)&&(f=!!i.leading,d=(m="maxWait"in i)?a(r(i.maxWait)||0,t):d,v="trailing"in i?!!i.trailing:v),x.cancel=function(){void 0!==h&&clearTimeout(h),g=0,l=p=c=h=void 0},x.flush=function(){return void 0===h?u:S(o())},x}},31502:function(e){e.exports=function(e,t){return e===t||e!=e&&t!=t}},6425:function(e,t,i){var n=i(67452),o=i(83568),r=i(51761),a=i(83008),s=i(3485);e.exports=function(e,t,i){var l=a(e)?n:o;return i&&s(e,t,i)&&(t=void 0),l(e,r(t,3))}},86974:function(e,t,i){var n=i(89442),o=i(58963);e.exports=function(e,t){return n(o(e,t),1)}},71758:function(e,t,i){var n=i(1653);e.exports=function(e,t,i){var o=null==e?void 0:n(e,t);return void 0===o?i:o}},49044:function(e,t,i){var n=i(76454),o=i(75825);e.exports=function(e,t){return null!=e&&o(e,t,n)}},34981:function(e){e.exports=function(e){return e}},79774:function(e,t,i){var n=i(50969),o=i(94488),r=Object.prototype,a=r.hasOwnProperty,s=r.propertyIsEnumerable,l=n(function(){return arguments}())?n:function(e){return o(e)&&a.call(e,"callee")&&!s.call(e,"callee")};e.exports=l},83008:function(e){var t=Array.isArray;e.exports=t},32335:function(e,t,i){var n=i(40825),o=i(62904);e.exports=function(e){return null!=e&&o(e.length)&&!n(e)}},35189:function(e,t,i){var n=i(37663),o=i(94488);e.exports=function(e){return!0===e||!1===e||o(e)&&"[object Boolean]"==n(e)}},30550:function(e,t,i){e=i.nmd(e);var n=i(77332),o=i(51305),r=t&&!t.nodeType&&t,a=r&&e&&!e.nodeType&&e,s=a&&a.exports===r?n.Buffer:void 0,l=(s?s.isBuffer:void 0)||o;e.exports=l},37861:function(e,t,i){var n=i(20625);e.exports=function(e,t){return n(e,t)}},40825:function(e,t,i){var n=i(37663),o=i(63991);e.exports=function(e){if(!o(e))return!1;var t=n(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}},62904:function(e){e.exports=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991}},68014:function(e,t,i){var n=i(82265);e.exports=function(e){return n(e)&&e!=+e}},18562:function(e){e.exports=function(e){return null==e}},82265:function(e,t,i){var n=i(37663),o=i(94488);e.exports=function(e){return"number"==typeof e||o(e)&&"[object Number]"==n(e)}},63991:function(e){e.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},94488:function(e){e.exports=function(e){return null!=e&&"object"==typeof e}},57466:function(e,t,i){var n=i(37663),o=i(71584),r=i(94488),a=Function.prototype,s=Object.prototype,l=a.toString,c=s.hasOwnProperty,d=l.call(Object);e.exports=function(e){if(!r(e)||"[object Object]"!=n(e))return!1;var t=o(e);if(null===t)return!0;var i=c.call(t,"constructor")&&t.constructor;return"function"==typeof i&&i instanceof i&&l.call(i)==d}},12343:function(e,t,i){var n=i(37663),o=i(83008),r=i(94488);e.exports=function(e){return"string"==typeof e||!o(e)&&r(e)&&"[object String]"==n(e)}},44308:function(e,t,i){var n=i(37663),o=i(94488);e.exports=function(e){return"symbol"==typeof e||o(e)&&"[object Symbol]"==n(e)}},8635:function(e,t,i){var n=i(98084),o=i(51648),r=i(61701),a=r&&r.isTypedArray,s=a?o(a):n;e.exports=s},33045:function(e,t,i){var n=i(27943),o=i(42580),r=i(32335);e.exports=function(e){return r(e)?n(e):o(e)}},26295:function(e){e.exports=function(e){var t=null==e?0:e.length;return t?e[t-1]:void 0}},58963:function(e,t,i){var n=i(96457),o=i(51761),r=i(68821),a=i(83008);e.exports=function(e,t){return(a(e)?n:r)(e,o(t,3))}},31113:function(e,t,i){var n=i(95045),o=i(75058),r=i(51761);e.exports=function(e,t){var i={};return t=r(t,3),o(e,(function(e,o,r){n(i,o,t(e,o,r))})),i}},94563:function(e,t,i){var n=i(33989),o=i(3006),r=i(34981);e.exports=function(e){return e&&e.length?n(e,r,o):void 0}},40560:function(e,t,i){var n=i(40618);function o(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new TypeError("Expected a function");var i=function(){var n=arguments,o=t?t.apply(this,n):n[0],r=i.cache;if(r.has(o))return r.get(o);var a=e.apply(this,n);return i.cache=r.set(o,a)||r,a};return i.cache=new(o.Cache||n),i}o.Cache=n,e.exports=o},9884:function(e,t,i){var n=i(33989),o=i(5201),r=i(34981);e.exports=function(e){return e&&e.length?n(e,r,o):void 0}},77730:function(e){e.exports=function(){}},57326:function(e,t,i){var n=i(77332);e.exports=function(){return n.Date.now()}},48387:function(e,t,i){var n=i(76543),o=i(72626),r=i(98984),a=i(15222);e.exports=function(e){return r(e)?n(a(e)):o(e)}},12474:function(e,t,i){var n=i(81481)();e.exports=n},93525:function(e,t,i){var n=i(76605),o=i(51761),r=i(31349),a=i(83008),s=i(3485);e.exports=function(e,t,i){var l=a(e)?n:r;return i&&s(e,t,i)&&(t=void 0),l(e,o(t,3))}},57657:function(e,t,i){var n=i(89442),o=i(48463),r=i(28947),a=i(3485),s=r((function(e,t){if(null==e)return[];var i=t.length;return i>1&&a(e,t[0],t[1])?t=[]:i>2&&a(t[0],t[1],t[2])&&(t=[t[0]]),o(e,n(t,1),[])}));e.exports=s},12825:function(e){e.exports=function(){return[]}},51305:function(e){e.exports=function(){return!1}},98374:function(e,t,i){var n=i(85075),o=i(63991);e.exports=function(e,t,i){var r=!0,a=!0;if("function"!=typeof e)throw new TypeError("Expected a function");return o(i)&&(r="leading"in i?!!i.leading:r,a="trailing"in i?!!i.trailing:a),n(e,t,{leading:r,maxWait:t,trailing:a})}},59477:function(e,t,i){var n=i(20824);e.exports=function(e){return e?Infinity===(e=n(e))||e===-1/0?17976931348623157e292*(e<0?-1:1):e==e?e:0:0===e?e:0}},20824:function(e,t,i){var n=i(79856),o=i(63991),r=i(44308),a=/^[-+]0x[0-9a-f]+$/i,s=/^0b[01]+$/i,l=/^0o[0-7]+$/i,c=parseInt;e.exports=function(e){if("number"==typeof e)return e;if(r(e))return NaN;if(o(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=o(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=n(e);var i=s.test(e);return i||l.test(e)?c(e.slice(2),i?2:8):a.test(e)?NaN:+e}},44139:function(e,t,i){var n=i(13986);e.exports=function(e){return null==e?"":n(e)}},33504:function(e,t,i){var n=i(51761),o=i(96567);e.exports=function(e,t){return e&&e.length?o(e,n(t,2)):[]}},126:function(e,t,i){var n=i(83320)("toUpperCase");e.exports=n},79382:function(e,t,i){"use strict";var n=i(76245);function o(){}function r(){}r.resetWarningCache=o,e.exports=function(){function e(e,t,i,o,r,a){if(a!==n){var s=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw s.name="Invariant Violation",s}}function t(){return e}e.isRequired=e;var i={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:r,resetWarningCache:o};return i.PropTypes=i,i}},25286:function(e,t,i){e.exports=i(79382)()},76245:function(e){"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},69788:function(e,t,i){"use strict";var n=i(8559);function o(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,i=1;i<arguments.length;i++)t+="&args[]="+encodeURIComponent(arguments[i]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var r=Object.prototype.hasOwnProperty,a=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,s={},l={};function c(e){return!!r.call(l,e)||!r.call(s,e)&&(a.test(e)?l[e]=!0:(s[e]=!0,!1))}function d(e,t,i,n,o,r,a){this.acceptsBooleans=2===t||3===t||4===t,this.attributeName=n,this.attributeNamespace=o,this.mustUseProperty=i,this.propertyName=e,this.type=t,this.sanitizeURL=r,this.removeEmptyString=a}var u={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach((function(e){u[e]=new d(e,0,!1,e,null,!1,!1)})),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach((function(e){var t=e[0];u[t]=new d(t,1,!1,e[1],null,!1,!1)})),["contentEditable","draggable","spellCheck","value"].forEach((function(e){u[e]=new d(e,2,!1,e.toLowerCase(),null,!1,!1)})),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach((function(e){u[e]=new d(e,2,!1,e,null,!1,!1)})),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach((function(e){u[e]=new d(e,3,!1,e.toLowerCase(),null,!1,!1)})),["checked","multiple","muted","selected"].forEach((function(e){u[e]=new d(e,3,!0,e,null,!1,!1)})),["capture","download"].forEach((function(e){u[e]=new d(e,4,!1,e,null,!1,!1)})),["cols","rows","size","span"].forEach((function(e){u[e]=new d(e,6,!1,e,null,!1,!1)})),["rowSpan","start"].forEach((function(e){u[e]=new d(e,5,!1,e.toLowerCase(),null,!1,!1)}));var h=/[\-:]([a-z])/g;function p(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach((function(e){var t=e.replace(h,p);u[t]=new d(t,1,!1,e,null,!1,!1)})),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach((function(e){var t=e.replace(h,p);u[t]=new d(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)})),["xml:base","xml:lang","xml:space"].forEach((function(e){var t=e.replace(h,p);u[t]=new d(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)})),["tabIndex","crossOrigin"].forEach((function(e){u[e]=new d(e,1,!1,e.toLowerCase(),null,!1,!1)})),u.xlinkHref=new d("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach((function(e){u[e]=new d(e,1,!1,e.toLowerCase(),null,!0,!0)}));var g={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},f=["Webkit","ms","Moz","O"];Object.keys(g).forEach((function(e){f.forEach((function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),g[t]=g[e]}))}));var m=/["'&<>]/;function v(e){if("boolean"==typeof e||"number"==typeof e)return""+e;e=""+e;var t=m.exec(e);if(t){var i,n="",o=0;for(i=t.index;i<e.length;i++){switch(e.charCodeAt(i)){case 34:t=""";break;case 38:t="&";break;case 39:t="'";break;case 60:t="<";break;case 62:t=">";break;default:continue}o!==i&&(n+=e.substring(o,i)),o=i+1,n+=t}e=o!==i?n+e.substring(o,i):n}return e}var y=/([A-Z])/g,C=/^ms-/,b=Array.isArray;function S(e,t){return{insertionMode:e,selectedValue:t}}var x=new Map;function T(e,t,i){if("object"!=typeof i)throw Error(o(62));for(var n in t=!0,i)if(r.call(i,n)){var a=i[n];if(null!=a&&"boolean"!=typeof a&&""!==a){if(0===n.indexOf("--")){var s=v(n);a=v((""+a).trim())}else{s=n;var l=x.get(s);void 0!==l||(l=v(s.replace(y,"-$1").toLowerCase().replace(C,"-ms-")),x.set(s,l)),s=l,a="number"==typeof a?0===a||r.call(g,n)?""+a:a+"px":v((""+a).trim())}t?(t=!1,e.push(' style="',s,":",a)):e.push(";",s,":",a)}}t||e.push('"')}function w(e,t,i,n){switch(i){case"style":return void T(e,t,n);case"defaultValue":case"defaultChecked":case"innerHTML":case"suppressContentEditableWarning":case"suppressHydrationWarning":return}if(!(2<i.length)||"o"!==i[0]&&"O"!==i[0]||"n"!==i[1]&&"N"!==i[1])if(null!==(t=u.hasOwnProperty(i)?u[i]:null)){switch(typeof n){case"function":case"symbol":return;case"boolean":if(!t.acceptsBooleans)return}switch(i=t.attributeName,t.type){case 3:n&&e.push(" ",i,'=""');break;case 4:!0===n?e.push(" ",i,'=""'):!1!==n&&e.push(" ",i,'="',v(n),'"');break;case 5:isNaN(n)||e.push(" ",i,'="',v(n),'"');break;case 6:!isNaN(n)&&1<=n&&e.push(" ",i,'="',v(n),'"');break;default:t.sanitizeURL&&(n=""+n),e.push(" ",i,'="',v(n),'"')}}else if(c(i)){switch(typeof n){case"function":case"symbol":return;case"boolean":if("data-"!==(t=i.toLowerCase().slice(0,5))&&"aria-"!==t)return}e.push(" ",i,'="',v(n),'"')}}function O(e,t,i){if(null!=t){if(null!=i)throw Error(o(60));if("object"!=typeof t||!("__html"in t))throw Error(o(61));null!=(t=t.__html)&&e.push(""+t)}}function P(e,t,i,n){e.push(k(i));var o,a=i=null;for(o in t)if(r.call(t,o)){var s=t[o];if(null!=s)switch(o){case"children":i=s;break;case"dangerouslySetInnerHTML":a=s;break;default:w(e,n,o,s)}}return e.push(">"),O(e,a,i),"string"==typeof i?(e.push(v(i)),null):i}var A=/^[a-zA-Z][a-zA-Z:_\.\-\d]*$/,E=new Map;function k(e){var t=E.get(e);if(void 0===t){if(!A.test(e))throw Error(o(65,e));t="<"+e,E.set(e,t)}return t}function I(e,t,i){if(e.push('\x3c!--$?--\x3e<template id="'),null===i)throw Error(o(395));return e.push(i),e.push('"></template>')}var D=/[<\u2028\u2029]/g;function _(e){return JSON.stringify(e).replace(D,(function(e){switch(e){case"<":return"\\u003c";case"\u2028":return"\\u2028";case"\u2029":return"\\u2029";default:throw Error("escapeJSStringsForInstructionScripts encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}}))}function N(e,t,i,n){return i.generateStaticMarkup?(e.push(v(t)),!1):(""===t?e=n:(n&&e.push("\x3c!-- --\x3e"),e.push(v(t)),e=!0),e)}var R=Object.assign,M=Symbol.for("react.element"),L=Symbol.for("react.portal"),B=Symbol.for("react.fragment"),F=Symbol.for("react.strict_mode"),U=Symbol.for("react.profiler"),H=Symbol.for("react.provider"),$=Symbol.for("react.context"),Z=Symbol.for("react.forward_ref"),V=Symbol.for("react.suspense"),G=Symbol.for("react.suspense_list"),j=Symbol.for("react.memo"),z=Symbol.for("react.lazy"),W=Symbol.for("react.scope"),K=Symbol.for("react.debug_trace_mode"),q=Symbol.for("react.legacy_hidden"),Y=Symbol.for("react.default_value"),X=Symbol.iterator;function J(e){if(null==e)return null;if("function"==typeof e)return e.displayName||e.name||null;if("string"==typeof e)return e;switch(e){case B:return"Fragment";case L:return"Portal";case U:return"Profiler";case F:return"StrictMode";case V:return"Suspense";case G:return"SuspenseList"}if("object"==typeof e)switch(e.$$typeof){case $:return(e.displayName||"Context")+".Consumer";case H:return(e._context.displayName||"Context")+".Provider";case Z:var t=e.render;return(e=e.displayName)||(e=""!==(e=t.displayName||t.name||"")?"ForwardRef("+e+")":"ForwardRef"),e;case j:return null!==(t=e.displayName||null)?t:J(e.type)||"Memo";case z:t=e._payload,e=e._init;try{return J(e(t))}catch(e){}}return null}var Q={};function ee(e,t){if(!(e=e.contextTypes))return Q;var i,n={};for(i in e)n[i]=t[i];return n}var te=null;function ie(e,t){if(e!==t){e.context._currentValue2=e.parentValue,e=e.parent;var i=t.parent;if(null===e){if(null!==i)throw Error(o(401))}else{if(null===i)throw Error(o(401));ie(e,i)}t.context._currentValue2=t.value}}function ne(e){e.context._currentValue2=e.parentValue,null!==(e=e.parent)&&ne(e)}function oe(e){var t=e.parent;null!==t&&oe(t),e.context._currentValue2=e.value}function re(e,t){if(e.context._currentValue2=e.parentValue,null===(e=e.parent))throw Error(o(402));e.depth===t.depth?ie(e,t):re(e,t)}function ae(e,t){var i=t.parent;if(null===i)throw Error(o(402));e.depth===i.depth?ie(e,i):ae(e,i),t.context._currentValue2=t.value}function se(e){var t=te;t!==e&&(null===t?oe(e):null===e?ne(t):t.depth===e.depth?ie(t,e):t.depth>e.depth?re(t,e):ae(t,e),te=e)}var le={isMounted:function(){return!1},enqueueSetState:function(e,t){null!==(e=e._reactInternals).queue&&e.queue.push(t)},enqueueReplaceState:function(e,t){(e=e._reactInternals).replace=!0,e.queue=[t]},enqueueForceUpdate:function(){}};function ce(e,t,i,n){var o=void 0!==e.state?e.state:null;e.updater=le,e.props=i,e.state=o;var r={queue:[],replace:!1};e._reactInternals=r;var a=t.contextType;if(e.context="object"==typeof a&&null!==a?a._currentValue2:n,"function"==typeof(a=t.getDerivedStateFromProps)&&(o=null==(a=a(i,o))?o:R({},o,a),e.state=o),"function"!=typeof t.getDerivedStateFromProps&&"function"!=typeof e.getSnapshotBeforeUpdate&&("function"==typeof e.UNSAFE_componentWillMount||"function"==typeof e.componentWillMount))if(t=e.state,"function"==typeof e.componentWillMount&&e.componentWillMount(),"function"==typeof e.UNSAFE_componentWillMount&&e.UNSAFE_componentWillMount(),t!==e.state&&le.enqueueReplaceState(e,e.state,null),null!==r.queue&&0<r.queue.length)if(t=r.queue,a=r.replace,r.queue=null,r.replace=!1,a&&1===t.length)e.state=t[0];else{for(r=a?t[0]:e.state,o=!0,a=a?1:0;a<t.length;a++){var s=t[a];null!=(s="function"==typeof s?s.call(e,r,i,n):s)&&(o?(o=!1,r=R({},r,s)):R(r,s))}e.state=r}else r.queue=null}var de={id:1,overflow:""};function ue(e,t,i){var n=e.id;e=e.overflow;var o=32-he(n)-1;n&=~(1<<o),i+=1;var r=32-he(t)+o;if(30<r){var a=o-o%5;return r=(n&(1<<a)-1).toString(32),n>>=a,o-=a,{id:1<<32-he(t)+o|i<<o|n,overflow:r+e}}return{id:1<<r|i<<o|n,overflow:e}}var he=Math.clz32?Math.clz32:function(e){return 0==(e>>>=0)?32:31-(pe(e)/ge|0)|0},pe=Math.log,ge=Math.LN2,fe="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},me=null,ve=null,ye=null,Ce=null,be=!1,Se=!1,xe=0,Te=null,we=0;function Oe(){if(null===me)throw Error(o(321));return me}function Pe(){if(0<we)throw Error(o(312));return{memoizedState:null,queue:null,next:null}}function Ae(){return null===Ce?null===ye?(be=!1,ye=Ce=Pe()):(be=!0,Ce=ye):null===Ce.next?(be=!1,Ce=Ce.next=Pe()):(be=!0,Ce=Ce.next),Ce}function Ee(){ve=me=null,Se=!1,ye=null,we=0,Ce=Te=null}function ke(e,t){return"function"==typeof t?t(e):t}function Ie(e,t,i){if(me=Oe(),Ce=Ae(),be){var n=Ce.queue;if(t=n.dispatch,null!==Te&&void 0!==(i=Te.get(n))){Te.delete(n),n=Ce.memoizedState;do{n=e(n,i.action),i=i.next}while(null!==i);return Ce.memoizedState=n,[n,t]}return[Ce.memoizedState,t]}return e=e===ke?"function"==typeof t?t():t:void 0!==i?i(t):t,Ce.memoizedState=e,e=(e=Ce.queue={last:null,dispatch:null}).dispatch=_e.bind(null,me,e),[Ce.memoizedState,e]}function De(e,t){if(me=Oe(),t=void 0===t?null:t,null!==(Ce=Ae())){var i=Ce.memoizedState;if(null!==i&&null!==t){var n=i[1];e:if(null===n)n=!1;else{for(var o=0;o<n.length&&o<t.length;o++)if(!fe(t[o],n[o])){n=!1;break e}n=!0}if(n)return i[0]}}return e=e(),Ce.memoizedState=[e,t],e}function _e(e,t,i){if(25<=we)throw Error(o(301));if(e===me)if(Se=!0,e={action:i,next:null},null===Te&&(Te=new Map),void 0===(i=Te.get(t)))Te.set(t,e);else{for(t=i;null!==t.next;)t=t.next;t.next=e}}function Ne(){throw Error(o(394))}function Re(){}var Me={readContext:function(e){return e._currentValue2},useContext:function(e){return Oe(),e._currentValue2},useMemo:De,useReducer:Ie,useRef:function(e){me=Oe();var t=(Ce=Ae()).memoizedState;return null===t?(e={current:e},Ce.memoizedState=e):t},useState:function(e){return Ie(ke,e)},useInsertionEffect:Re,useLayoutEffect:function(){},useCallback:function(e,t){return De((function(){return e}),t)},useImperativeHandle:Re,useEffect:Re,useDebugValue:Re,useDeferredValue:function(e){return Oe(),e},useTransition:function(){return Oe(),[!1,Ne]},useId:function(){var e=ve.treeContext,t=e.overflow;e=((e=e.id)&~(1<<32-he(e)-1)).toString(32)+t;var i=Le;if(null===i)throw Error(o(404));return t=xe++,e=":"+i.idPrefix+"R"+e,0<t&&(e+="H"+t.toString(32)),e+":"},useMutableSource:function(e,t){return Oe(),t(e._source)},useSyncExternalStore:function(e,t,i){if(void 0===i)throw Error(o(407));return i()}},Le=null,Be=n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentDispatcher;function Fe(e){return null}function Ue(){}function He(e,t,i,n,o,r,a,s){e.allPendingTasks++,null===i?e.pendingRootTasks++:i.pendingTasks++;var l={node:t,ping:function(){var t=e.pingedTasks;t.push(l),1===t.length&&tt(e)},blockedBoundary:i,blockedSegment:n,abortSet:o,legacyContext:r,context:a,treeContext:s};return o.add(l),l}function $e(e,t,i,n,o,r){return{status:0,id:-1,index:t,parentFlushed:!1,chunks:[],children:[],formatContext:n,boundary:i,lastPushedText:o,textEmbedded:r}}function Ze(e,t){if(null!=(e=e.onError(t))&&"string"!=typeof e)throw Error('onError returned something with a type other than "string". onError should return a string and may return null or undefined but must not return anything else. It received something of type "'+typeof e+'" instead');return e}function Ve(e,t){var i=e.onShellError;i(t),(i=e.onFatalError)(t),null!==e.destination?(e.status=2,e.destination.destroy(t)):(e.status=1,e.fatalError=t)}function Ge(e,t,i,n,o){for(me={},ve=t,xe=0,e=i(n,o);Se;)Se=!1,xe=0,we+=1,Ce=null,e=i(n,o);return Ee(),e}function je(e,t,i,n){var r=i.render(),a=n.childContextTypes;if(null!=a){var s=t.legacyContext;if("function"!=typeof i.getChildContext)n=s;else{for(var l in i=i.getChildContext())if(!(l in a))throw Error(o(108,J(n)||"Unknown",l));n=R({},s,i)}t.legacyContext=n,Ke(e,t,r),t.legacyContext=s}else Ke(e,t,r)}function ze(e,t){if(e&&e.defaultProps){for(var i in t=R({},t),e=e.defaultProps)void 0===t[i]&&(t[i]=e[i]);return t}return t}function We(e,t,i,a,s){if("function"==typeof i)if(i.prototype&&i.prototype.isReactComponent){s=ee(i,t.legacyContext);var l=i.contextType;ce(l=new i(a,"object"==typeof l&&null!==l?l._currentValue2:s),i,a,s),je(e,t,l,i)}else{s=Ge(e,t,i,a,l=ee(i,t.legacyContext));var d=0!==xe;if("object"==typeof s&&null!==s&&"function"==typeof s.render&&void 0===s.$$typeof)ce(s,i,a,l),je(e,t,s,i);else if(d){a=t.treeContext,t.treeContext=ue(a,1,0);try{Ke(e,t,s)}finally{t.treeContext=a}}else Ke(e,t,s)}else{if("string"!=typeof i){switch(i){case q:case K:case F:case U:case B:case G:return void Ke(e,t,a.children);case W:throw Error(o(343));case V:e:{i=t.blockedBoundary,s=t.blockedSegment,l=a.fallback,a=a.children;var u={id:null,rootSegmentID:-1,parentFlushed:!1,pendingTasks:0,forceClientRender:!1,completedSegments:[],byteSize:0,fallbackAbortableTasks:d=new Set,errorDigest:null},h=$e(0,s.chunks.length,u,s.formatContext,!1,!1);s.children.push(h),s.lastPushedText=!1;var p=$e(0,0,null,s.formatContext,!1,!1);p.parentFlushed=!0,t.blockedBoundary=u,t.blockedSegment=p;try{if(Ye(e,t,a),e.responseState.generateStaticMarkup||p.lastPushedText&&p.textEmbedded&&p.chunks.push("\x3c!-- --\x3e"),p.status=1,Qe(u,p),0===u.pendingTasks)break e}catch(t){p.status=4,u.forceClientRender=!0,u.errorDigest=Ze(e,t)}finally{t.blockedBoundary=i,t.blockedSegment=s}t=He(e,l,i,h,d,t.legacyContext,t.context,t.treeContext),e.pingedTasks.push(t)}return}if("object"==typeof i&&null!==i)switch(i.$$typeof){case Z:if(a=Ge(e,t,i.render,a,s),0!==xe){i=t.treeContext,t.treeContext=ue(i,1,0);try{Ke(e,t,a)}finally{t.treeContext=i}}else Ke(e,t,a);return;case j:return void We(e,t,i=i.type,a=ze(i,a),s);case H:if(s=a.children,i=i._context,a=a.value,l=i._currentValue2,i._currentValue2=a,te=a={parent:d=te,depth:null===d?0:d.depth+1,context:i,parentValue:l,value:a},t.context=a,Ke(e,t,s),null===(e=te))throw Error(o(403));return a=e.parentValue,e.context._currentValue2=a===Y?e.context._defaultValue:a,e=te=e.parent,void(t.context=e);case $:return void Ke(e,t,a=(a=a.children)(i._currentValue2));case z:return void We(e,t,i=(s=i._init)(i._payload),a=ze(i,a),void 0)}throw Error(o(130,null==i?i:typeof i,""))}switch(l=function(e,t,i,a,s){switch(t){case"select":e.push(k("select"));var l=null,d=null;for(g in i)if(r.call(i,g)){var u=i[g];if(null!=u)switch(g){case"children":l=u;break;case"dangerouslySetInnerHTML":d=u;break;case"defaultValue":case"value":break;default:w(e,a,g,u)}}return e.push(">"),O(e,d,l),l;case"option":d=s.selectedValue,e.push(k("option"));var h=u=null,p=null,g=null;for(l in i)if(r.call(i,l)){var f=i[l];if(null!=f)switch(l){case"children":u=f;break;case"selected":p=f;break;case"dangerouslySetInnerHTML":g=f;break;case"value":h=f;default:w(e,a,l,f)}}if(null!=d)if(i=null!==h?""+h:function(e){var t="";return n.Children.forEach(e,(function(e){null!=e&&(t+=e)})),t}(u),b(d)){for(a=0;a<d.length;a++)if(""+d[a]===i){e.push(' selected=""');break}}else""+d===i&&e.push(' selected=""');else p&&e.push(' selected=""');return e.push(">"),O(e,g,u),u;case"textarea":for(u in e.push(k("textarea")),g=d=l=null,i)if(r.call(i,u)&&null!=(h=i[u]))switch(u){case"children":g=h;break;case"value":l=h;break;case"defaultValue":d=h;break;case"dangerouslySetInnerHTML":throw Error(o(91));default:w(e,a,u,h)}if(null===l&&null!==d&&(l=d),e.push(">"),null!=g){if(null!=l)throw Error(o(92));if(b(g)&&1<g.length)throw Error(o(93));l=""+g}return"string"==typeof l&&"\n"===l[0]&&e.push("\n"),null!==l&&e.push(v(""+l)),null;case"input":for(d in e.push(k("input")),h=g=u=l=null,i)if(r.call(i,d)&&null!=(p=i[d]))switch(d){case"children":case"dangerouslySetInnerHTML":throw Error(o(399,"input"));case"defaultChecked":h=p;break;case"defaultValue":u=p;break;case"checked":g=p;break;case"value":l=p;break;default:w(e,a,d,p)}return null!==g?w(e,a,"checked",g):null!==h&&w(e,a,"checked",h),null!==l?w(e,a,"value",l):null!==u&&w(e,a,"value",u),e.push("/>"),null;case"menuitem":for(var m in e.push(k("menuitem")),i)if(r.call(i,m)&&null!=(l=i[m]))switch(m){case"children":case"dangerouslySetInnerHTML":throw Error(o(400));default:w(e,a,m,l)}return e.push(">"),null;case"title":for(f in e.push(k("title")),l=null,i)if(r.call(i,f)&&null!=(d=i[f]))switch(f){case"children":l=d;break;case"dangerouslySetInnerHTML":throw Error(o(434));default:w(e,a,f,d)}return e.push(">"),l;case"listing":case"pre":for(h in e.push(k(t)),d=l=null,i)if(r.call(i,h)&&null!=(u=i[h]))switch(h){case"children":l=u;break;case"dangerouslySetInnerHTML":d=u;break;default:w(e,a,h,u)}if(e.push(">"),null!=d){if(null!=l)throw Error(o(60));if("object"!=typeof d||!("__html"in d))throw Error(o(61));null!=(i=d.__html)&&("string"==typeof i&&0<i.length&&"\n"===i[0]?e.push("\n",i):e.push(""+i))}return"string"==typeof l&&"\n"===l[0]&&e.push("\n"),l;case"area":case"base":case"br":case"col":case"embed":case"hr":case"img":case"keygen":case"link":case"meta":case"param":case"source":case"track":case"wbr":for(var y in e.push(k(t)),i)if(r.call(i,y)&&null!=(l=i[y]))switch(y){case"children":case"dangerouslySetInnerHTML":throw Error(o(399,t));default:w(e,a,y,l)}return e.push("/>"),null;case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return P(e,i,t,a);case"html":return 0===s.insertionMode&&e.push("<!DOCTYPE html>"),P(e,i,t,a);default:if(-1===t.indexOf("-")&&"string"!=typeof i.is)return P(e,i,t,a);for(p in e.push(k(t)),d=l=null,i)if(r.call(i,p)&&null!=(u=i[p]))switch(p){case"children":l=u;break;case"dangerouslySetInnerHTML":d=u;break;case"style":T(e,a,u);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":break;default:c(p)&&"function"!=typeof u&&"symbol"!=typeof u&&e.push(" ",p,'="',v(u),'"')}return e.push(">"),O(e,d,l),l}}((s=t.blockedSegment).chunks,i,a,e.responseState,s.formatContext),s.lastPushedText=!1,d=s.formatContext,s.formatContext=function(e,t,i){switch(t){case"select":return S(1,null!=i.value?i.value:i.defaultValue);case"svg":return S(2,null);case"math":return S(3,null);case"foreignObject":return S(1,null);case"table":return S(4,null);case"thead":case"tbody":case"tfoot":return S(5,null);case"colgroup":return S(7,null);case"tr":return S(6,null)}return 4<=e.insertionMode||0===e.insertionMode?S(1,null):e}(d,i,a),Ye(e,t,l),s.formatContext=d,i){case"area":case"base":case"br":case"col":case"embed":case"hr":case"img":case"input":case"keygen":case"link":case"meta":case"param":case"source":case"track":case"wbr":break;default:s.chunks.push("</",i,">")}s.lastPushedText=!1}}function Ke(e,t,i){if(t.node=i,"object"==typeof i&&null!==i){switch(i.$$typeof){case M:return void We(e,t,i.type,i.props,i.ref);case L:throw Error(o(257));case z:var n=i._init;return void Ke(e,t,i=n(i._payload))}if(b(i))return void qe(e,t,i);if((n=null===i||"object"!=typeof i?null:"function"==typeof(n=X&&i[X]||i["@@iterator"])?n:null)&&(n=n.call(i))){if(!(i=n.next()).done){var r=[];do{r.push(i.value),i=n.next()}while(!i.done);qe(e,t,r)}return}throw e=Object.prototype.toString.call(i),Error(o(31,"[object Object]"===e?"object with keys {"+Object.keys(i).join(", ")+"}":e))}"string"==typeof i?(n=t.blockedSegment).lastPushedText=N(t.blockedSegment.chunks,i,e.responseState,n.lastPushedText):"number"==typeof i&&((n=t.blockedSegment).lastPushedText=N(t.blockedSegment.chunks,""+i,e.responseState,n.lastPushedText))}function qe(e,t,i){for(var n=i.length,o=0;o<n;o++){var r=t.treeContext;t.treeContext=ue(r,n,o);try{Ye(e,t,i[o])}finally{t.treeContext=r}}}function Ye(e,t,i){var n=t.blockedSegment.formatContext,o=t.legacyContext,r=t.context;try{return Ke(e,t,i)}catch(l){if(Ee(),"object"!=typeof l||null===l||"function"!=typeof l.then)throw t.blockedSegment.formatContext=n,t.legacyContext=o,t.context=r,se(r),l;i=l;var a=t.blockedSegment,s=$e(0,a.chunks.length,null,a.formatContext,a.lastPushedText,!0);a.children.push(s),a.lastPushedText=!1,e=He(e,t.node,t.blockedBoundary,s,t.abortSet,t.legacyContext,t.context,t.treeContext).ping,i.then(e,e),t.blockedSegment.formatContext=n,t.legacyContext=o,t.context=r,se(r)}}function Xe(e){var t=e.blockedBoundary;(e=e.blockedSegment).status=3,et(this,t,e)}function Je(e,t,i){var n=e.blockedBoundary;e.blockedSegment.status=3,null===n?(t.allPendingTasks--,2!==t.status&&(t.status=2,null!==t.destination&&t.destination.push(null))):(n.pendingTasks--,n.forceClientRender||(n.forceClientRender=!0,e=void 0===i?Error(o(432)):i,n.errorDigest=t.onError(e),n.parentFlushed&&t.clientRenderedBoundaries.push(n)),n.fallbackAbortableTasks.forEach((function(e){return Je(e,t,i)})),n.fallbackAbortableTasks.clear(),t.allPendingTasks--,0===t.allPendingTasks&&(n=t.onAllReady)())}function Qe(e,t){if(0===t.chunks.length&&1===t.children.length&&null===t.children[0].boundary){var i=t.children[0];i.id=t.id,i.parentFlushed=!0,1===i.status&&Qe(e,i)}else e.completedSegments.push(t)}function et(e,t,i){if(null===t){if(i.parentFlushed){if(null!==e.completedRootSegment)throw Error(o(389));e.completedRootSegment=i}e.pendingRootTasks--,0===e.pendingRootTasks&&(e.onShellError=Ue,(t=e.onShellReady)())}else t.pendingTasks--,t.forceClientRender||(0===t.pendingTasks?(i.parentFlushed&&1===i.status&&Qe(t,i),t.parentFlushed&&e.completedBoundaries.push(t),t.fallbackAbortableTasks.forEach(Xe,e),t.fallbackAbortableTasks.clear()):i.parentFlushed&&1===i.status&&(Qe(t,i),1===t.completedSegments.length&&t.parentFlushed&&e.partialBoundaries.push(t)));e.allPendingTasks--,0===e.allPendingTasks&&(e=e.onAllReady)()}function tt(e){if(2!==e.status){var t=te,i=Be.current;Be.current=Me;var n=Le;Le=e.responseState;try{var o,r=e.pingedTasks;for(o=0;o<r.length;o++){var a=r[o],s=e,l=a.blockedSegment;if(0===l.status){se(a.context);try{Ke(s,a,a.node),s.responseState.generateStaticMarkup||l.lastPushedText&&l.textEmbedded&&l.chunks.push("\x3c!-- --\x3e"),a.abortSet.delete(a),l.status=1,et(s,a.blockedBoundary,l)}catch(e){if(Ee(),"object"==typeof e&&null!==e&&"function"==typeof e.then){var c=a.ping;e.then(c,c)}else{a.abortSet.delete(a),l.status=4;var d=a.blockedBoundary,u=e,h=Ze(s,u);null===d?Ve(s,u):(d.pendingTasks--,d.forceClientRender||(d.forceClientRender=!0,d.errorDigest=h,d.parentFlushed&&s.clientRenderedBoundaries.push(d))),s.allPendingTasks--,0===s.allPendingTasks&&(0,s.onAllReady)()}}}}r.splice(0,o),null!==e.destination&&st(e,e.destination)}catch(t){Ze(e,t),Ve(e,t)}finally{Le=n,Be.current=i,i===Me&&se(t)}}}function it(e,t,i){switch(i.parentFlushed=!0,i.status){case 0:var n=i.id=e.nextSegmentId++;return i.lastPushedText=!1,i.textEmbedded=!1,e=e.responseState,t.push('<template id="'),t.push(e.placeholderPrefix),e=n.toString(16),t.push(e),t.push('"></template>');case 1:i.status=2;var r=!0;n=i.chunks;var a=0;i=i.children;for(var s=0;s<i.length;s++){for(r=i[s];a<r.index;a++)t.push(n[a]);r=nt(e,t,r)}for(;a<n.length-1;a++)t.push(n[a]);return a<n.length&&(r=t.push(n[a])),r;default:throw Error(o(390))}}function nt(e,t,i){var n=i.boundary;if(null===n)return it(e,t,i);if(n.parentFlushed=!0,n.forceClientRender)return e.responseState.generateStaticMarkup||(n=n.errorDigest,t.push("\x3c!--$!--\x3e"),t.push("<template"),n&&(t.push(' data-dgst="'),n=v(n),t.push(n),t.push('"')),t.push("></template>")),it(e,t,i),!!e.responseState.generateStaticMarkup||t.push("\x3c!--/$--\x3e");if(0<n.pendingTasks){n.rootSegmentID=e.nextSegmentId++,0<n.completedSegments.length&&e.partialBoundaries.push(n);var r=e.responseState,a=r.nextSuspenseID++;return r=r.boundaryPrefix+a.toString(16),n=n.id=r,I(t,e.responseState,n),it(e,t,i),t.push("\x3c!--/$--\x3e")}if(n.byteSize>e.progressiveChunkSize)return n.rootSegmentID=e.nextSegmentId++,e.completedBoundaries.push(n),I(t,e.responseState,n.id),it(e,t,i),t.push("\x3c!--/$--\x3e");if(e.responseState.generateStaticMarkup||t.push("\x3c!--$--\x3e"),1!==(i=n.completedSegments).length)throw Error(o(391));return nt(e,t,i[0]),!!e.responseState.generateStaticMarkup||t.push("\x3c!--/$--\x3e")}function ot(e,t,i){return function(e,t,i,n){switch(i.insertionMode){case 0:case 1:return e.push('<div hidden id="'),e.push(t.segmentPrefix),t=n.toString(16),e.push(t),e.push('">');case 2:return e.push('<svg aria-hidden="true" style="display:none" id="'),e.push(t.segmentPrefix),t=n.toString(16),e.push(t),e.push('">');case 3:return e.push('<math aria-hidden="true" style="display:none" id="'),e.push(t.segmentPrefix),t=n.toString(16),e.push(t),e.push('">');case 4:return e.push('<table hidden id="'),e.push(t.segmentPrefix),t=n.toString(16),e.push(t),e.push('">');case 5:return e.push('<table hidden><tbody id="'),e.push(t.segmentPrefix),t=n.toString(16),e.push(t),e.push('">');case 6:return e.push('<table hidden><tr id="'),e.push(t.segmentPrefix),t=n.toString(16),e.push(t),e.push('">');case 7:return e.push('<table hidden><colgroup id="'),e.push(t.segmentPrefix),t=n.toString(16),e.push(t),e.push('">');default:throw Error(o(397))}}(t,e.responseState,i.formatContext,i.id),nt(e,t,i),function(e,t){switch(t.insertionMode){case 0:case 1:return e.push("</div>");case 2:return e.push("</svg>");case 3:return e.push("</math>");case 4:return e.push("</table>");case 5:return e.push("</tbody></table>");case 6:return e.push("</tr></table>");case 7:return e.push("</colgroup></table>");default:throw Error(o(397))}}(t,i.formatContext)}function rt(e,t,i){for(var n=i.completedSegments,r=0;r<n.length;r++)at(e,t,i,n[r]);if(n.length=0,e=e.responseState,n=i.id,i=i.rootSegmentID,t.push(e.startInlineScript),e.sentCompleteBoundaryFunction?t.push('$RC("'):(e.sentCompleteBoundaryFunction=!0,t.push('function $RC(a,b){a=document.getElementById(a);b=document.getElementById(b);b.parentNode.removeChild(b);if(a){a=a.previousSibling;var f=a.parentNode,c=a.nextSibling,e=0;do{if(c&&8===c.nodeType){var d=c.data;if("/$"===d)if(0===e)break;else e--;else"$"!==d&&"$?"!==d&&"$!"!==d||e++}d=c.nextSibling;f.removeChild(c);c=d}while(c);for(;b.firstChild;)f.insertBefore(b.firstChild,c);a.data="$";a._reactRetry&&a._reactRetry()}};$RC("')),null===n)throw Error(o(395));return i=i.toString(16),t.push(n),t.push('","'),t.push(e.segmentPrefix),t.push(i),t.push('")<\/script>')}function at(e,t,i,n){if(2===n.status)return!0;var r=n.id;if(-1===r){if(-1===(n.id=i.rootSegmentID))throw Error(o(392));return ot(e,t,n)}return ot(e,t,n),e=e.responseState,t.push(e.startInlineScript),e.sentCompleteSegmentFunction?t.push('$RS("'):(e.sentCompleteSegmentFunction=!0,t.push('function $RS(a,b){a=document.getElementById(a);b=document.getElementById(b);for(a.parentNode.removeChild(a);a.firstChild;)b.parentNode.insertBefore(a.firstChild,b);b.parentNode.removeChild(b)};$RS("')),t.push(e.segmentPrefix),r=r.toString(16),t.push(r),t.push('","'),t.push(e.placeholderPrefix),t.push(r),t.push('")<\/script>')}function st(e,t){try{var i=e.completedRootSegment;if(null!==i&&0===e.pendingRootTasks){nt(e,t,i),e.completedRootSegment=null;var n=e.responseState.bootstrapChunks;for(i=0;i<n.length-1;i++)t.push(n[i]);i<n.length&&t.push(n[i])}var r,a=e.clientRenderedBoundaries;for(r=0;r<a.length;r++){var s=a[r];n=t;var l=e.responseState,c=s.id,d=s.errorDigest,u=s.errorMessage,h=s.errorComponentStack;if(n.push(l.startInlineScript),l.sentClientRenderFunction?n.push('$RX("'):(l.sentClientRenderFunction=!0,n.push('function $RX(b,c,d,e){var a=document.getElementById(b);a&&(b=a.previousSibling,b.data="$!",a=a.dataset,c&&(a.dgst=c),d&&(a.msg=d),e&&(a.stck=e),b._reactRetry&&b._reactRetry())};$RX("')),null===c)throw Error(o(395));if(n.push(c),n.push('"'),d||u||h){n.push(",");var p=_(d||"");n.push(p)}if(u||h){n.push(",");var g=_(u||"");n.push(g)}if(h){n.push(",");var f=_(h);n.push(f)}if(!n.push(")<\/script>"))return e.destination=null,r++,void a.splice(0,r)}a.splice(0,r);var m=e.completedBoundaries;for(r=0;r<m.length;r++)if(!rt(e,t,m[r]))return e.destination=null,r++,void m.splice(0,r);m.splice(0,r);var v=e.partialBoundaries;for(r=0;r<v.length;r++){var y=v[r];e:{a=e,s=t;var C=y.completedSegments;for(l=0;l<C.length;l++)if(!at(a,s,y,C[l])){l++,C.splice(0,l);var b=!1;break e}C.splice(0,l),b=!0}if(!b)return e.destination=null,r++,void v.splice(0,r)}v.splice(0,r);var S=e.completedBoundaries;for(r=0;r<S.length;r++)if(!rt(e,t,S[r]))return e.destination=null,r++,void S.splice(0,r);S.splice(0,r)}finally{0===e.allPendingTasks&&0===e.pingedTasks.length&&0===e.clientRenderedBoundaries.length&&0===e.completedBoundaries.length&&t.push(null)}}function lt(e,t){try{var i=e.abortableTasks;i.forEach((function(i){return Je(i,e,t)})),i.clear(),null!==e.destination&&st(e,e.destination)}catch(t){Ze(e,t),Ve(e,t)}}function ct(){}function dt(e,t,i,n){var r=!1,a=null,s="",l={push:function(e){return null!==e&&(s+=e),!0},destroy:function(e){r=!0,a=e}},c=!1;if(e=function(e,t,i,n,o,r,a,s,l){var c=[],d=new Set;return(i=$e(t={destination:null,responseState:t,progressiveChunkSize:n,status:0,fatalError:null,nextSegmentId:0,allPendingTasks:0,pendingRootTasks:0,completedRootSegment:null,abortableTasks:d,pingedTasks:c,clientRenderedBoundaries:[],completedBoundaries:[],partialBoundaries:[],onError:void 0===o?Fe:o,onAllReady:Ue,onShellReady:void 0===a?Ue:a,onShellError:Ue,onFatalError:Ue},0,null,i,!1,!1)).parentFlushed=!0,e=He(t,e,null,i,d,Q,null,de),c.push(e),t}(e,function(e,t){return{bootstrapChunks:[],startInlineScript:"<script>",placeholderPrefix:(t=void 0===t?"":t)+"P:",segmentPrefix:t+"S:",boundaryPrefix:t+"B:",idPrefix:t,nextSuspenseID:0,sentCompleteSegmentFunction:!1,sentCompleteBoundaryFunction:!1,sentClientRenderFunction:!1,generateStaticMarkup:e}}(i,t?t.identifierPrefix:void 0),{insertionMode:1,selectedValue:null},1/0,ct,0,(function(){c=!0})),tt(e),lt(e,n),1===e.status)e.status=2,l.destroy(e.fatalError);else if(2!==e.status&&null===e.destination){e.destination=l;try{st(e,l)}catch(t){Ze(e,t),Ve(e,t)}}if(r)throw a;if(!c)throw Error(o(426));return s}t.renderToNodeStream=function(){throw Error(o(207))},t.renderToStaticMarkup=function(e,t){return dt(e,t,!0,'The server used "renderToStaticMarkup" which does not support Suspense. If you intended to have the server wait for the suspended component please switch to "renderToReadableStream" which supports Suspense on the server')},t.renderToStaticNodeStream=function(){throw Error(o(208))},t.renderToString=function(e,t){return dt(e,t,!1,'The server used "renderToString" which does not support Suspense. If you intended for this Suspense boundary to render the fallback content on the server consider throwing an Error somewhere within the Suspense boundary. If you intended to have the server wait for the suspended component please switch to "renderToReadableStream" which supports Suspense on the server')},t.version="18.2.0"},24221:function(e,t,i){"use strict";var n=i(8559);function o(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,i=1;i<arguments.length;i++)t+="&args[]="+encodeURIComponent(arguments[i]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var r=null,a=0;function s(e,t){if(0!==t.length)if(512<t.length)0<a&&(e.enqueue(new Uint8Array(r.buffer,0,a)),r=new Uint8Array(512),a=0),e.enqueue(t);else{var i=r.length-a;i<t.length&&(0===i?e.enqueue(r):(r.set(t.subarray(0,i),a),e.enqueue(r),t=t.subarray(i)),r=new Uint8Array(512),a=0),r.set(t,a),a+=t.length}}function l(e,t){return s(e,t),!0}function c(e){r&&0<a&&(e.enqueue(new Uint8Array(r.buffer,0,a)),r=null,a=0)}var d=new TextEncoder;function u(e){return d.encode(e)}function h(e){return d.encode(e)}function p(e,t){"function"==typeof e.error?e.error(t):e.close()}var g=Object.prototype.hasOwnProperty,f=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,m={},v={};function y(e){return!!g.call(v,e)||!g.call(m,e)&&(f.test(e)?v[e]=!0:(m[e]=!0,!1))}function C(e,t,i,n,o,r,a){this.acceptsBooleans=2===t||3===t||4===t,this.attributeName=n,this.attributeNamespace=o,this.mustUseProperty=i,this.propertyName=e,this.type=t,this.sanitizeURL=r,this.removeEmptyString=a}var b={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach((function(e){b[e]=new C(e,0,!1,e,null,!1,!1)})),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach((function(e){var t=e[0];b[t]=new C(t,1,!1,e[1],null,!1,!1)})),["contentEditable","draggable","spellCheck","value"].forEach((function(e){b[e]=new C(e,2,!1,e.toLowerCase(),null,!1,!1)})),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach((function(e){b[e]=new C(e,2,!1,e,null,!1,!1)})),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach((function(e){b[e]=new C(e,3,!1,e.toLowerCase(),null,!1,!1)})),["checked","multiple","muted","selected"].forEach((function(e){b[e]=new C(e,3,!0,e,null,!1,!1)})),["capture","download"].forEach((function(e){b[e]=new C(e,4,!1,e,null,!1,!1)})),["cols","rows","size","span"].forEach((function(e){b[e]=new C(e,6,!1,e,null,!1,!1)})),["rowSpan","start"].forEach((function(e){b[e]=new C(e,5,!1,e.toLowerCase(),null,!1,!1)}));var S=/[\-:]([a-z])/g;function x(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach((function(e){var t=e.replace(S,x);b[t]=new C(t,1,!1,e,null,!1,!1)})),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach((function(e){var t=e.replace(S,x);b[t]=new C(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)})),["xml:base","xml:lang","xml:space"].forEach((function(e){var t=e.replace(S,x);b[t]=new C(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)})),["tabIndex","crossOrigin"].forEach((function(e){b[e]=new C(e,1,!1,e.toLowerCase(),null,!1,!1)})),b.xlinkHref=new C("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach((function(e){b[e]=new C(e,1,!1,e.toLowerCase(),null,!0,!0)}));var T={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},w=["Webkit","ms","Moz","O"];Object.keys(T).forEach((function(e){w.forEach((function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),T[t]=T[e]}))}));var O=/["'&<>]/;function P(e){if("boolean"==typeof e||"number"==typeof e)return""+e;e=""+e;var t=O.exec(e);if(t){var i,n="",o=0;for(i=t.index;i<e.length;i++){switch(e.charCodeAt(i)){case 34:t=""";break;case 38:t="&";break;case 39:t="'";break;case 60:t="<";break;case 62:t=">";break;default:continue}o!==i&&(n+=e.substring(o,i)),o=i+1,n+=t}e=o!==i?n+e.substring(o,i):n}return e}var A=/([A-Z])/g,E=/^ms-/,k=Array.isArray,I=h("<script>"),D=h("<\/script>"),_=h('<script src="'),N=h('<script type="module" src="'),R=h('" async=""><\/script>'),M=/(<\/|<)(s)(cript)/gi;function L(e,t,i,n){return t+("s"===i?"\\u0073":"\\u0053")+n}function B(e,t){return{insertionMode:e,selectedValue:t}}var F=h("\x3c!-- --\x3e");function U(e,t,i,n){return""===t?n:(n&&e.push(F),e.push(u(P(t))),!0)}var H=new Map,$=h(' style="'),Z=h(":"),V=h(";");function G(e,t,i){if("object"!=typeof i)throw Error(o(62));for(var n in t=!0,i)if(g.call(i,n)){var r=i[n];if(null!=r&&"boolean"!=typeof r&&""!==r){if(0===n.indexOf("--")){var a=u(P(n));r=u(P((""+r).trim()))}else{a=n;var s=H.get(a);void 0!==s||(s=h(P(a.replace(A,"-$1").toLowerCase().replace(E,"-ms-"))),H.set(a,s)),a=s,r="number"==typeof r?0===r||g.call(T,n)?u(""+r):u(r+"px"):u(P((""+r).trim()))}t?(t=!1,e.push($,a,Z,r)):e.push(V,a,Z,r)}}t||e.push(W)}var j=h(" "),z=h('="'),W=h('"'),K=h('=""');function q(e,t,i,n){switch(i){case"style":return void G(e,t,n);case"defaultValue":case"defaultChecked":case"innerHTML":case"suppressContentEditableWarning":case"suppressHydrationWarning":return}if(!(2<i.length)||"o"!==i[0]&&"O"!==i[0]||"n"!==i[1]&&"N"!==i[1])if(null!==(t=b.hasOwnProperty(i)?b[i]:null)){switch(typeof n){case"function":case"symbol":return;case"boolean":if(!t.acceptsBooleans)return}switch(i=u(t.attributeName),t.type){case 3:n&&e.push(j,i,K);break;case 4:!0===n?e.push(j,i,K):!1!==n&&e.push(j,i,z,u(P(n)),W);break;case 5:isNaN(n)||e.push(j,i,z,u(P(n)),W);break;case 6:!isNaN(n)&&1<=n&&e.push(j,i,z,u(P(n)),W);break;default:t.sanitizeURL&&(n=""+n),e.push(j,i,z,u(P(n)),W)}}else if(y(i)){switch(typeof n){case"function":case"symbol":return;case"boolean":if("data-"!==(t=i.toLowerCase().slice(0,5))&&"aria-"!==t)return}e.push(j,u(i),z,u(P(n)),W)}}var Y=h(">"),X=h("/>");function J(e,t,i){if(null!=t){if(null!=i)throw Error(o(60));if("object"!=typeof t||!("__html"in t))throw Error(o(61));null!=(t=t.__html)&&e.push(u(""+t))}}var Q=h(' selected=""');function ee(e,t,i,n){e.push(oe(i));var o,r=i=null;for(o in t)if(g.call(t,o)){var a=t[o];if(null!=a)switch(o){case"children":i=a;break;case"dangerouslySetInnerHTML":r=a;break;default:q(e,n,o,a)}}return e.push(Y),J(e,r,i),"string"==typeof i?(e.push(u(P(i))),null):i}var te=h("\n"),ie=/^[a-zA-Z][a-zA-Z:_\.\-\d]*$/,ne=new Map;function oe(e){var t=ne.get(e);if(void 0===t){if(!ie.test(e))throw Error(o(65,e));t=h("<"+e),ne.set(e,t)}return t}var re=h("<!DOCTYPE html>");var ae=h("</"),se=h(">"),le=h('<template id="'),ce=h('"></template>'),de=h("\x3c!--$--\x3e"),ue=h('\x3c!--$?--\x3e<template id="'),he=h('"></template>'),pe=h("\x3c!--$!--\x3e"),ge=h("\x3c!--/$--\x3e"),fe=h("<template"),me=h('"'),ve=h(' data-dgst="');h(' data-msg="'),h(' data-stck="');var ye=h("></template>");function Ce(e,t,i){if(s(e,ue),null===i)throw Error(o(395));return s(e,i),l(e,he)}var be=h('<div hidden id="'),Se=h('">'),xe=h("</div>"),Te=h('<svg aria-hidden="true" style="display:none" id="'),we=h('">'),Oe=h("</svg>"),Pe=h('<math aria-hidden="true" style="display:none" id="'),Ae=h('">'),Ee=h("</math>"),ke=h('<table hidden id="'),Ie=h('">'),De=h("</table>"),_e=h('<table hidden><tbody id="'),Ne=h('">'),Re=h("</tbody></table>"),Me=h('<table hidden><tr id="'),Le=h('">'),Be=h("</tr></table>"),Fe=h('<table hidden><colgroup id="'),Ue=h('">'),He=h("</colgroup></table>"),$e=h('function $RS(a,b){a=document.getElementById(a);b=document.getElementById(b);for(a.parentNode.removeChild(a);a.firstChild;)b.parentNode.insertBefore(a.firstChild,b);b.parentNode.removeChild(b)};$RS("'),Ze=h('$RS("'),Ve=h('","'),Ge=h('")<\/script>'),je=h('function $RC(a,b){a=document.getElementById(a);b=document.getElementById(b);b.parentNode.removeChild(b);if(a){a=a.previousSibling;var f=a.parentNode,c=a.nextSibling,e=0;do{if(c&&8===c.nodeType){var d=c.data;if("/$"===d)if(0===e)break;else e--;else"$"!==d&&"$?"!==d&&"$!"!==d||e++}d=c.nextSibling;f.removeChild(c);c=d}while(c);for(;b.firstChild;)f.insertBefore(b.firstChild,c);a.data="$";a._reactRetry&&a._reactRetry()}};$RC("'),ze=h('$RC("'),We=h('","'),Ke=h('")<\/script>'),qe=h('function $RX(b,c,d,e){var a=document.getElementById(b);a&&(b=a.previousSibling,b.data="$!",a=a.dataset,c&&(a.dgst=c),d&&(a.msg=d),e&&(a.stck=e),b._reactRetry&&b._reactRetry())};$RX("'),Ye=h('$RX("'),Xe=h('"'),Je=h(")<\/script>"),Qe=h(","),et=/[<\u2028\u2029]/g;function tt(e){return JSON.stringify(e).replace(et,(function(e){switch(e){case"<":return"\\u003c";case"\u2028":return"\\u2028";case"\u2029":return"\\u2029";default:throw Error("escapeJSStringsForInstructionScripts encountered a match it does not know how to replace. this means the match regex and the replacement characters are no longer in sync. This is a bug in React")}}))}var it=Object.assign,nt=Symbol.for("react.element"),ot=Symbol.for("react.portal"),rt=Symbol.for("react.fragment"),at=Symbol.for("react.strict_mode"),st=Symbol.for("react.profiler"),lt=Symbol.for("react.provider"),ct=Symbol.for("react.context"),dt=Symbol.for("react.forward_ref"),ut=Symbol.for("react.suspense"),ht=Symbol.for("react.suspense_list"),pt=Symbol.for("react.memo"),gt=Symbol.for("react.lazy"),ft=Symbol.for("react.scope"),mt=Symbol.for("react.debug_trace_mode"),vt=Symbol.for("react.legacy_hidden"),yt=Symbol.for("react.default_value"),Ct=Symbol.iterator;function bt(e){if(null==e)return null;if("function"==typeof e)return e.displayName||e.name||null;if("string"==typeof e)return e;switch(e){case rt:return"Fragment";case ot:return"Portal";case st:return"Profiler";case at:return"StrictMode";case ut:return"Suspense";case ht:return"SuspenseList"}if("object"==typeof e)switch(e.$$typeof){case ct:return(e.displayName||"Context")+".Consumer";case lt:return(e._context.displayName||"Context")+".Provider";case dt:var t=e.render;return(e=e.displayName)||(e=""!==(e=t.displayName||t.name||"")?"ForwardRef("+e+")":"ForwardRef"),e;case pt:return null!==(t=e.displayName||null)?t:bt(e.type)||"Memo";case gt:t=e._payload,e=e._init;try{return bt(e(t))}catch(e){}}return null}var St={};function xt(e,t){if(!(e=e.contextTypes))return St;var i,n={};for(i in e)n[i]=t[i];return n}var Tt=null;function wt(e,t){if(e!==t){e.context._currentValue=e.parentValue,e=e.parent;var i=t.parent;if(null===e){if(null!==i)throw Error(o(401))}else{if(null===i)throw Error(o(401));wt(e,i)}t.context._currentValue=t.value}}function Ot(e){e.context._currentValue=e.parentValue,null!==(e=e.parent)&&Ot(e)}function Pt(e){var t=e.parent;null!==t&&Pt(t),e.context._currentValue=e.value}function At(e,t){if(e.context._currentValue=e.parentValue,null===(e=e.parent))throw Error(o(402));e.depth===t.depth?wt(e,t):At(e,t)}function Et(e,t){var i=t.parent;if(null===i)throw Error(o(402));e.depth===i.depth?wt(e,i):Et(e,i),t.context._currentValue=t.value}function kt(e){var t=Tt;t!==e&&(null===t?Pt(e):null===e?Ot(t):t.depth===e.depth?wt(t,e):t.depth>e.depth?At(t,e):Et(t,e),Tt=e)}var It={isMounted:function(){return!1},enqueueSetState:function(e,t){null!==(e=e._reactInternals).queue&&e.queue.push(t)},enqueueReplaceState:function(e,t){(e=e._reactInternals).replace=!0,e.queue=[t]},enqueueForceUpdate:function(){}};function Dt(e,t,i,n){var o=void 0!==e.state?e.state:null;e.updater=It,e.props=i,e.state=o;var r={queue:[],replace:!1};e._reactInternals=r;var a=t.contextType;if(e.context="object"==typeof a&&null!==a?a._currentValue:n,"function"==typeof(a=t.getDerivedStateFromProps)&&(o=null==(a=a(i,o))?o:it({},o,a),e.state=o),"function"!=typeof t.getDerivedStateFromProps&&"function"!=typeof e.getSnapshotBeforeUpdate&&("function"==typeof e.UNSAFE_componentWillMount||"function"==typeof e.componentWillMount))if(t=e.state,"function"==typeof e.componentWillMount&&e.componentWillMount(),"function"==typeof e.UNSAFE_componentWillMount&&e.UNSAFE_componentWillMount(),t!==e.state&&It.enqueueReplaceState(e,e.state,null),null!==r.queue&&0<r.queue.length)if(t=r.queue,a=r.replace,r.queue=null,r.replace=!1,a&&1===t.length)e.state=t[0];else{for(r=a?t[0]:e.state,o=!0,a=a?1:0;a<t.length;a++){var s=t[a];null!=(s="function"==typeof s?s.call(e,r,i,n):s)&&(o?(o=!1,r=it({},r,s)):it(r,s))}e.state=r}else r.queue=null}var _t={id:1,overflow:""};function Nt(e,t,i){var n=e.id;e=e.overflow;var o=32-Rt(n)-1;n&=~(1<<o),i+=1;var r=32-Rt(t)+o;if(30<r){var a=o-o%5;return r=(n&(1<<a)-1).toString(32),n>>=a,o-=a,{id:1<<32-Rt(t)+o|i<<o|n,overflow:r+e}}return{id:1<<r|i<<o|n,overflow:e}}var Rt=Math.clz32?Math.clz32:function(e){return 0==(e>>>=0)?32:31-(Mt(e)/Lt|0)|0},Mt=Math.log,Lt=Math.LN2,Bt="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},Ft=null,Ut=null,Ht=null,$t=null,Zt=!1,Vt=!1,Gt=0,jt=null,zt=0;function Wt(){if(null===Ft)throw Error(o(321));return Ft}function Kt(){if(0<zt)throw Error(o(312));return{memoizedState:null,queue:null,next:null}}function qt(){return null===$t?null===Ht?(Zt=!1,Ht=$t=Kt()):(Zt=!0,$t=Ht):null===$t.next?(Zt=!1,$t=$t.next=Kt()):(Zt=!0,$t=$t.next),$t}function Yt(){Ut=Ft=null,Vt=!1,Ht=null,zt=0,$t=jt=null}function Xt(e,t){return"function"==typeof t?t(e):t}function Jt(e,t,i){if(Ft=Wt(),$t=qt(),Zt){var n=$t.queue;if(t=n.dispatch,null!==jt&&void 0!==(i=jt.get(n))){jt.delete(n),n=$t.memoizedState;do{n=e(n,i.action),i=i.next}while(null!==i);return $t.memoizedState=n,[n,t]}return[$t.memoizedState,t]}return e=e===Xt?"function"==typeof t?t():t:void 0!==i?i(t):t,$t.memoizedState=e,e=(e=$t.queue={last:null,dispatch:null}).dispatch=ei.bind(null,Ft,e),[$t.memoizedState,e]}function Qt(e,t){if(Ft=Wt(),t=void 0===t?null:t,null!==($t=qt())){var i=$t.memoizedState;if(null!==i&&null!==t){var n=i[1];e:if(null===n)n=!1;else{for(var o=0;o<n.length&&o<t.length;o++)if(!Bt(t[o],n[o])){n=!1;break e}n=!0}if(n)return i[0]}}return e=e(),$t.memoizedState=[e,t],e}function ei(e,t,i){if(25<=zt)throw Error(o(301));if(e===Ft)if(Vt=!0,e={action:i,next:null},null===jt&&(jt=new Map),void 0===(i=jt.get(t)))jt.set(t,e);else{for(t=i;null!==t.next;)t=t.next;t.next=e}}function ti(){throw Error(o(394))}function ii(){}var ni={readContext:function(e){return e._currentValue},useContext:function(e){return Wt(),e._currentValue},useMemo:Qt,useReducer:Jt,useRef:function(e){Ft=Wt();var t=($t=qt()).memoizedState;return null===t?(e={current:e},$t.memoizedState=e):t},useState:function(e){return Jt(Xt,e)},useInsertionEffect:ii,useLayoutEffect:function(){},useCallback:function(e,t){return Qt((function(){return e}),t)},useImperativeHandle:ii,useEffect:ii,useDebugValue:ii,useDeferredValue:function(e){return Wt(),e},useTransition:function(){return Wt(),[!1,ti]},useId:function(){var e=Ut.treeContext,t=e.overflow;e=((e=e.id)&~(1<<32-Rt(e)-1)).toString(32)+t;var i=oi;if(null===i)throw Error(o(404));return t=Gt++,e=":"+i.idPrefix+"R"+e,0<t&&(e+="H"+t.toString(32)),e+":"},useMutableSource:function(e,t){return Wt(),t(e._source)},useSyncExternalStore:function(e,t,i){if(void 0===i)throw Error(o(407));return i()}},oi=null,ri=n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentDispatcher;function ai(e){return null}function si(){}function li(e,t,i,n,o,r,a,s){e.allPendingTasks++,null===i?e.pendingRootTasks++:i.pendingTasks++;var l={node:t,ping:function(){var t=e.pingedTasks;t.push(l),1===t.length&&Ti(e)},blockedBoundary:i,blockedSegment:n,abortSet:o,legacyContext:r,context:a,treeContext:s};return o.add(l),l}function ci(e,t,i,n,o,r){return{status:0,id:-1,index:t,parentFlushed:!1,chunks:[],children:[],formatContext:n,boundary:i,lastPushedText:o,textEmbedded:r}}function di(e,t){if(null!=(e=e.onError(t))&&"string"!=typeof e)throw Error('onError returned something with a type other than "string". onError should return a string and may return null or undefined but must not return anything else. It received something of type "'+typeof e+'" instead');return e}function ui(e,t){var i=e.onShellError;i(t),(i=e.onFatalError)(t),null!==e.destination?(e.status=2,p(e.destination,t)):(e.status=1,e.fatalError=t)}function hi(e,t,i,n,o){for(Ft={},Ut=t,Gt=0,e=i(n,o);Vt;)Vt=!1,Gt=0,zt+=1,$t=null,e=i(n,o);return Yt(),e}function pi(e,t,i,n){var r=i.render(),a=n.childContextTypes;if(null!=a){var s=t.legacyContext;if("function"!=typeof i.getChildContext)n=s;else{for(var l in i=i.getChildContext())if(!(l in a))throw Error(o(108,bt(n)||"Unknown",l));n=it({},s,i)}t.legacyContext=n,mi(e,t,r),t.legacyContext=s}else mi(e,t,r)}function gi(e,t){if(e&&e.defaultProps){for(var i in t=it({},t),e=e.defaultProps)void 0===t[i]&&(t[i]=e[i]);return t}return t}function fi(e,t,i,r,a){if("function"==typeof i)if(i.prototype&&i.prototype.isReactComponent){a=xt(i,t.legacyContext);var s=i.contextType;Dt(s=new i(r,"object"==typeof s&&null!==s?s._currentValue:a),i,r,a),pi(e,t,s,i)}else{a=hi(e,t,i,r,s=xt(i,t.legacyContext));var l=0!==Gt;if("object"==typeof a&&null!==a&&"function"==typeof a.render&&void 0===a.$$typeof)Dt(a,i,r,s),pi(e,t,a,i);else if(l){r=t.treeContext,t.treeContext=Nt(r,1,0);try{mi(e,t,a)}finally{t.treeContext=r}}else mi(e,t,a)}else{if("string"!=typeof i){switch(i){case vt:case mt:case at:case st:case rt:case ht:return void mi(e,t,r.children);case ft:throw Error(o(343));case ut:e:{i=t.blockedBoundary,a=t.blockedSegment,s=r.fallback,r=r.children;var c={id:null,rootSegmentID:-1,parentFlushed:!1,pendingTasks:0,forceClientRender:!1,completedSegments:[],byteSize:0,fallbackAbortableTasks:l=new Set,errorDigest:null},d=ci(0,a.chunks.length,c,a.formatContext,!1,!1);a.children.push(d),a.lastPushedText=!1;var h=ci(0,0,null,a.formatContext,!1,!1);h.parentFlushed=!0,t.blockedBoundary=c,t.blockedSegment=h;try{if(yi(e,t,r),h.lastPushedText&&h.textEmbedded&&h.chunks.push(F),h.status=1,Si(c,h),0===c.pendingTasks)break e}catch(t){h.status=4,c.forceClientRender=!0,c.errorDigest=di(e,t)}finally{t.blockedBoundary=i,t.blockedSegment=a}t=li(e,s,i,d,l,t.legacyContext,t.context,t.treeContext),e.pingedTasks.push(t)}return}if("object"==typeof i&&null!==i)switch(i.$$typeof){case dt:if(r=hi(e,t,i.render,r,a),0!==Gt){i=t.treeContext,t.treeContext=Nt(i,1,0);try{mi(e,t,r)}finally{t.treeContext=i}}else mi(e,t,r);return;case pt:return void fi(e,t,i=i.type,r=gi(i,r),a);case lt:if(a=r.children,i=i._context,r=r.value,s=i._currentValue,i._currentValue=r,Tt=r={parent:l=Tt,depth:null===l?0:l.depth+1,context:i,parentValue:s,value:r},t.context=r,mi(e,t,a),null===(e=Tt))throw Error(o(403));return r=e.parentValue,e.context._currentValue=r===yt?e.context._defaultValue:r,e=Tt=e.parent,void(t.context=e);case ct:return void mi(e,t,r=(r=r.children)(i._currentValue));case gt:return void fi(e,t,i=(a=i._init)(i._payload),r=gi(i,r),void 0)}throw Error(o(130,null==i?i:typeof i,""))}switch(s=function(e,t,i,r,a){switch(t){case"select":e.push(oe("select"));var s=null,l=null;for(p in i)if(g.call(i,p)){var c=i[p];if(null!=c)switch(p){case"children":s=c;break;case"dangerouslySetInnerHTML":l=c;break;case"defaultValue":case"value":break;default:q(e,r,p,c)}}return e.push(Y),J(e,l,s),s;case"option":l=a.selectedValue,e.push(oe("option"));var d=c=null,h=null,p=null;for(s in i)if(g.call(i,s)){var f=i[s];if(null!=f)switch(s){case"children":c=f;break;case"selected":h=f;break;case"dangerouslySetInnerHTML":p=f;break;case"value":d=f;default:q(e,r,s,f)}}if(null!=l)if(i=null!==d?""+d:function(e){var t="";return n.Children.forEach(e,(function(e){null!=e&&(t+=e)})),t}(c),k(l)){for(r=0;r<l.length;r++)if(""+l[r]===i){e.push(Q);break}}else""+l===i&&e.push(Q);else h&&e.push(Q);return e.push(Y),J(e,p,c),c;case"textarea":for(c in e.push(oe("textarea")),p=l=s=null,i)if(g.call(i,c)&&null!=(d=i[c]))switch(c){case"children":p=d;break;case"value":s=d;break;case"defaultValue":l=d;break;case"dangerouslySetInnerHTML":throw Error(o(91));default:q(e,r,c,d)}if(null===s&&null!==l&&(s=l),e.push(Y),null!=p){if(null!=s)throw Error(o(92));if(k(p)&&1<p.length)throw Error(o(93));s=""+p}return"string"==typeof s&&"\n"===s[0]&&e.push(te),null!==s&&e.push(u(P(""+s))),null;case"input":for(l in e.push(oe("input")),d=p=c=s=null,i)if(g.call(i,l)&&null!=(h=i[l]))switch(l){case"children":case"dangerouslySetInnerHTML":throw Error(o(399,"input"));case"defaultChecked":d=h;break;case"defaultValue":c=h;break;case"checked":p=h;break;case"value":s=h;break;default:q(e,r,l,h)}return null!==p?q(e,r,"checked",p):null!==d&&q(e,r,"checked",d),null!==s?q(e,r,"value",s):null!==c&&q(e,r,"value",c),e.push(X),null;case"menuitem":for(var m in e.push(oe("menuitem")),i)if(g.call(i,m)&&null!=(s=i[m]))switch(m){case"children":case"dangerouslySetInnerHTML":throw Error(o(400));default:q(e,r,m,s)}return e.push(Y),null;case"title":for(f in e.push(oe("title")),s=null,i)if(g.call(i,f)&&null!=(l=i[f]))switch(f){case"children":s=l;break;case"dangerouslySetInnerHTML":throw Error(o(434));default:q(e,r,f,l)}return e.push(Y),s;case"listing":case"pre":for(d in e.push(oe(t)),l=s=null,i)if(g.call(i,d)&&null!=(c=i[d]))switch(d){case"children":s=c;break;case"dangerouslySetInnerHTML":l=c;break;default:q(e,r,d,c)}if(e.push(Y),null!=l){if(null!=s)throw Error(o(60));if("object"!=typeof l||!("__html"in l))throw Error(o(61));null!=(i=l.__html)&&("string"==typeof i&&0<i.length&&"\n"===i[0]?e.push(te,u(i)):e.push(u(""+i)))}return"string"==typeof s&&"\n"===s[0]&&e.push(te),s;case"area":case"base":case"br":case"col":case"embed":case"hr":case"img":case"keygen":case"link":case"meta":case"param":case"source":case"track":case"wbr":for(var v in e.push(oe(t)),i)if(g.call(i,v)&&null!=(s=i[v]))switch(v){case"children":case"dangerouslySetInnerHTML":throw Error(o(399,t));default:q(e,r,v,s)}return e.push(X),null;case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return ee(e,i,t,r);case"html":return 0===a.insertionMode&&e.push(re),ee(e,i,t,r);default:if(-1===t.indexOf("-")&&"string"!=typeof i.is)return ee(e,i,t,r);for(h in e.push(oe(t)),l=s=null,i)if(g.call(i,h)&&null!=(c=i[h]))switch(h){case"children":s=c;break;case"dangerouslySetInnerHTML":l=c;break;case"style":G(e,r,c);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":break;default:y(h)&&"function"!=typeof c&&"symbol"!=typeof c&&e.push(j,u(h),z,u(P(c)),W)}return e.push(Y),J(e,l,s),s}}((a=t.blockedSegment).chunks,i,r,e.responseState,a.formatContext),a.lastPushedText=!1,l=a.formatContext,a.formatContext=function(e,t,i){switch(t){case"select":return B(1,null!=i.value?i.value:i.defaultValue);case"svg":return B(2,null);case"math":return B(3,null);case"foreignObject":return B(1,null);case"table":return B(4,null);case"thead":case"tbody":case"tfoot":return B(5,null);case"colgroup":return B(7,null);case"tr":return B(6,null)}return 4<=e.insertionMode||0===e.insertionMode?B(1,null):e}(l,i,r),yi(e,t,s),a.formatContext=l,i){case"area":case"base":case"br":case"col":case"embed":case"hr":case"img":case"input":case"keygen":case"link":case"meta":case"param":case"source":case"track":case"wbr":break;default:a.chunks.push(ae,u(i),se)}a.lastPushedText=!1}}function mi(e,t,i){if(t.node=i,"object"==typeof i&&null!==i){switch(i.$$typeof){case nt:return void fi(e,t,i.type,i.props,i.ref);case ot:throw Error(o(257));case gt:var n=i._init;return void mi(e,t,i=n(i._payload))}if(k(i))return void vi(e,t,i);if((n=null===i||"object"!=typeof i?null:"function"==typeof(n=Ct&&i[Ct]||i["@@iterator"])?n:null)&&(n=n.call(i))){if(!(i=n.next()).done){var r=[];do{r.push(i.value),i=n.next()}while(!i.done);vi(e,t,r)}return}throw e=Object.prototype.toString.call(i),Error(o(31,"[object Object]"===e?"object with keys {"+Object.keys(i).join(", ")+"}":e))}"string"==typeof i?(n=t.blockedSegment).lastPushedText=U(t.blockedSegment.chunks,i,e.responseState,n.lastPushedText):"number"==typeof i&&((n=t.blockedSegment).lastPushedText=U(t.blockedSegment.chunks,""+i,e.responseState,n.lastPushedText))}function vi(e,t,i){for(var n=i.length,o=0;o<n;o++){var r=t.treeContext;t.treeContext=Nt(r,n,o);try{yi(e,t,i[o])}finally{t.treeContext=r}}}function yi(e,t,i){var n=t.blockedSegment.formatContext,o=t.legacyContext,r=t.context;try{return mi(e,t,i)}catch(l){if(Yt(),"object"!=typeof l||null===l||"function"!=typeof l.then)throw t.blockedSegment.formatContext=n,t.legacyContext=o,t.context=r,kt(r),l;i=l;var a=t.blockedSegment,s=ci(0,a.chunks.length,null,a.formatContext,a.lastPushedText,!0);a.children.push(s),a.lastPushedText=!1,e=li(e,t.node,t.blockedBoundary,s,t.abortSet,t.legacyContext,t.context,t.treeContext).ping,i.then(e,e),t.blockedSegment.formatContext=n,t.legacyContext=o,t.context=r,kt(r)}}function Ci(e){var t=e.blockedBoundary;(e=e.blockedSegment).status=3,xi(this,t,e)}function bi(e,t,i){var n=e.blockedBoundary;e.blockedSegment.status=3,null===n?(t.allPendingTasks--,2!==t.status&&(t.status=2,null!==t.destination&&t.destination.close())):(n.pendingTasks--,n.forceClientRender||(n.forceClientRender=!0,e=void 0===i?Error(o(432)):i,n.errorDigest=t.onError(e),n.parentFlushed&&t.clientRenderedBoundaries.push(n)),n.fallbackAbortableTasks.forEach((function(e){return bi(e,t,i)})),n.fallbackAbortableTasks.clear(),t.allPendingTasks--,0===t.allPendingTasks&&(n=t.onAllReady)())}function Si(e,t){if(0===t.chunks.length&&1===t.children.length&&null===t.children[0].boundary){var i=t.children[0];i.id=t.id,i.parentFlushed=!0,1===i.status&&Si(e,i)}else e.completedSegments.push(t)}function xi(e,t,i){if(null===t){if(i.parentFlushed){if(null!==e.completedRootSegment)throw Error(o(389));e.completedRootSegment=i}e.pendingRootTasks--,0===e.pendingRootTasks&&(e.onShellError=si,(t=e.onShellReady)())}else t.pendingTasks--,t.forceClientRender||(0===t.pendingTasks?(i.parentFlushed&&1===i.status&&Si(t,i),t.parentFlushed&&e.completedBoundaries.push(t),t.fallbackAbortableTasks.forEach(Ci,e),t.fallbackAbortableTasks.clear()):i.parentFlushed&&1===i.status&&(Si(t,i),1===t.completedSegments.length&&t.parentFlushed&&e.partialBoundaries.push(t)));e.allPendingTasks--,0===e.allPendingTasks&&(e=e.onAllReady)()}function Ti(e){if(2!==e.status){var t=Tt,i=ri.current;ri.current=ni;var n=oi;oi=e.responseState;try{var o,r=e.pingedTasks;for(o=0;o<r.length;o++){var a=r[o],s=e,l=a.blockedSegment;if(0===l.status){kt(a.context);try{mi(s,a,a.node),l.lastPushedText&&l.textEmbedded&&l.chunks.push(F),a.abortSet.delete(a),l.status=1,xi(s,a.blockedBoundary,l)}catch(e){if(Yt(),"object"==typeof e&&null!==e&&"function"==typeof e.then){var c=a.ping;e.then(c,c)}else{a.abortSet.delete(a),l.status=4;var d=a.blockedBoundary,u=e,h=di(s,u);null===d?ui(s,u):(d.pendingTasks--,d.forceClientRender||(d.forceClientRender=!0,d.errorDigest=h,d.parentFlushed&&s.clientRenderedBoundaries.push(d))),s.allPendingTasks--,0===s.allPendingTasks&&(0,s.onAllReady)()}}}}r.splice(0,o),null!==e.destination&&ki(e,e.destination)}catch(t){di(e,t),ui(e,t)}finally{oi=n,ri.current=i,i===ni&&kt(t)}}}function wi(e,t,i){switch(i.parentFlushed=!0,i.status){case 0:var n=i.id=e.nextSegmentId++;return i.lastPushedText=!1,i.textEmbedded=!1,e=e.responseState,s(t,le),s(t,e.placeholderPrefix),s(t,e=u(n.toString(16))),l(t,ce);case 1:i.status=2;var r=!0;n=i.chunks;var a=0;i=i.children;for(var c=0;c<i.length;c++){for(r=i[c];a<r.index;a++)s(t,n[a]);r=Oi(e,t,r)}for(;a<n.length-1;a++)s(t,n[a]);return a<n.length&&(r=l(t,n[a])),r;default:throw Error(o(390))}}function Oi(e,t,i){var n=i.boundary;if(null===n)return wi(e,t,i);if(n.parentFlushed=!0,n.forceClientRender)n=n.errorDigest,l(t,pe),s(t,fe),n&&(s(t,ve),s(t,u(P(n))),s(t,me)),l(t,ye),wi(e,t,i);else if(0<n.pendingTasks){n.rootSegmentID=e.nextSegmentId++,0<n.completedSegments.length&&e.partialBoundaries.push(n);var r=e.responseState,a=r.nextSuspenseID++;r=h(r.boundaryPrefix+a.toString(16)),n=n.id=r,Ce(t,e.responseState,n),wi(e,t,i)}else if(n.byteSize>e.progressiveChunkSize)n.rootSegmentID=e.nextSegmentId++,e.completedBoundaries.push(n),Ce(t,e.responseState,n.id),wi(e,t,i);else{if(l(t,de),1!==(i=n.completedSegments).length)throw Error(o(391));Oi(e,t,i[0])}return l(t,ge)}function Pi(e,t,i){return function(e,t,i,n){switch(i.insertionMode){case 0:case 1:return s(e,be),s(e,t.segmentPrefix),s(e,u(n.toString(16))),l(e,Se);case 2:return s(e,Te),s(e,t.segmentPrefix),s(e,u(n.toString(16))),l(e,we);case 3:return s(e,Pe),s(e,t.segmentPrefix),s(e,u(n.toString(16))),l(e,Ae);case 4:return s(e,ke),s(e,t.segmentPrefix),s(e,u(n.toString(16))),l(e,Ie);case 5:return s(e,_e),s(e,t.segmentPrefix),s(e,u(n.toString(16))),l(e,Ne);case 6:return s(e,Me),s(e,t.segmentPrefix),s(e,u(n.toString(16))),l(e,Le);case 7:return s(e,Fe),s(e,t.segmentPrefix),s(e,u(n.toString(16))),l(e,Ue);default:throw Error(o(397))}}(t,e.responseState,i.formatContext,i.id),Oi(e,t,i),function(e,t){switch(t.insertionMode){case 0:case 1:return l(e,xe);case 2:return l(e,Oe);case 3:return l(e,Ee);case 4:return l(e,De);case 5:return l(e,Re);case 6:return l(e,Be);case 7:return l(e,He);default:throw Error(o(397))}}(t,i.formatContext)}function Ai(e,t,i){for(var n=i.completedSegments,r=0;r<n.length;r++)Ei(e,t,i,n[r]);if(n.length=0,e=e.responseState,n=i.id,i=i.rootSegmentID,s(t,e.startInlineScript),e.sentCompleteBoundaryFunction?s(t,ze):(e.sentCompleteBoundaryFunction=!0,s(t,je)),null===n)throw Error(o(395));return i=u(i.toString(16)),s(t,n),s(t,We),s(t,e.segmentPrefix),s(t,i),l(t,Ke)}function Ei(e,t,i,n){if(2===n.status)return!0;var r=n.id;if(-1===r){if(-1===(n.id=i.rootSegmentID))throw Error(o(392));return Pi(e,t,n)}return Pi(e,t,n),s(t,(e=e.responseState).startInlineScript),e.sentCompleteSegmentFunction?s(t,Ze):(e.sentCompleteSegmentFunction=!0,s(t,$e)),s(t,e.segmentPrefix),s(t,r=u(r.toString(16))),s(t,Ve),s(t,e.placeholderPrefix),s(t,r),l(t,Ge)}function ki(e,t){r=new Uint8Array(512),a=0;try{var i=e.completedRootSegment;if(null!==i&&0===e.pendingRootTasks){Oi(e,t,i),e.completedRootSegment=null;var n=e.responseState.bootstrapChunks;for(i=0;i<n.length-1;i++)s(t,n[i]);i<n.length&&l(t,n[i])}var d,h=e.clientRenderedBoundaries;for(d=0;d<h.length;d++){var p=h[d];n=t;var g=e.responseState,f=p.id,m=p.errorDigest,v=p.errorMessage,y=p.errorComponentStack;if(s(n,g.startInlineScript),g.sentClientRenderFunction?s(n,Ye):(g.sentClientRenderFunction=!0,s(n,qe)),null===f)throw Error(o(395));if(s(n,f),s(n,Xe),(m||v||y)&&(s(n,Qe),s(n,u(tt(m||"")))),(v||y)&&(s(n,Qe),s(n,u(tt(v||"")))),y&&(s(n,Qe),s(n,u(tt(y)))),!l(n,Je))return e.destination=null,d++,void h.splice(0,d)}h.splice(0,d);var C=e.completedBoundaries;for(d=0;d<C.length;d++)if(!Ai(e,t,C[d]))return e.destination=null,d++,void C.splice(0,d);C.splice(0,d),c(t),r=new Uint8Array(512),a=0;var b=e.partialBoundaries;for(d=0;d<b.length;d++){var S=b[d];e:{h=e,p=t;var x=S.completedSegments;for(g=0;g<x.length;g++)if(!Ei(h,p,S,x[g])){g++,x.splice(0,g);var T=!1;break e}x.splice(0,g),T=!0}if(!T)return e.destination=null,d++,void b.splice(0,d)}b.splice(0,d);var w=e.completedBoundaries;for(d=0;d<w.length;d++)if(!Ai(e,t,w[d]))return e.destination=null,d++,void w.splice(0,d);w.splice(0,d)}finally{c(t),0===e.allPendingTasks&&0===e.pingedTasks.length&&0===e.clientRenderedBoundaries.length&&0===e.completedBoundaries.length&&t.close()}}function Ii(e,t){try{var i=e.abortableTasks;i.forEach((function(i){return bi(i,e,t)})),i.clear(),null!==e.destination&&ki(e,e.destination)}catch(t){di(e,t),ui(e,t)}}t.renderToReadableStream=function(e,t){return new Promise((function(i,n){var o,r,a=new Promise((function(e,t){r=e,o=t})),s=function(e,t,i,n,o,r,a,s,l){var c=[],d=new Set;return(i=ci(t={destination:null,responseState:t,progressiveChunkSize:void 0===n?12800:n,status:0,fatalError:null,nextSegmentId:0,allPendingTasks:0,pendingRootTasks:0,completedRootSegment:null,abortableTasks:d,pingedTasks:c,clientRenderedBoundaries:[],completedBoundaries:[],partialBoundaries:[],onError:void 0===o?ai:o,onAllReady:void 0===r?si:r,onShellReady:void 0===a?si:a,onShellError:void 0===s?si:s,onFatalError:void 0===l?si:l},0,null,i,!1,!1)).parentFlushed=!0,e=li(t,e,null,i,d,St,null,_t),c.push(e),t}(e,function(e,t,i,n,o){e=void 0===e?"":e,t=void 0===t?I:h('<script nonce="'+P(t)+'">');var r=[];if(void 0!==i&&r.push(t,u((""+i).replace(M,L)),D),void 0!==n)for(i=0;i<n.length;i++)r.push(_,u(P(n[i])),R);if(void 0!==o)for(n=0;n<o.length;n++)r.push(N,u(P(o[n])),R);return{bootstrapChunks:r,startInlineScript:t,placeholderPrefix:h(e+"P:"),segmentPrefix:h(e+"S:"),boundaryPrefix:e+"B:",idPrefix:e,nextSuspenseID:0,sentCompleteSegmentFunction:!1,sentCompleteBoundaryFunction:!1,sentClientRenderFunction:!1}}(t?t.identifierPrefix:void 0,t?t.nonce:void 0,t?t.bootstrapScriptContent:void 0,t?t.bootstrapScripts:void 0,t?t.bootstrapModules:void 0),function(e){return B("http://www.w3.org/2000/svg"===e?2:"http://www.w3.org/1998/Math/MathML"===e?3:0,null)}(t?t.namespaceURI:void 0),t?t.progressiveChunkSize:void 0,t?t.onError:void 0,r,(function(){var e=new ReadableStream({type:"bytes",pull:function(e){if(1===s.status)s.status=2,p(e,s.fatalError);else if(2!==s.status&&null===s.destination){s.destination=e;try{ki(s,e)}catch(e){di(s,e),ui(s,e)}}},cancel:function(){Ii(s)}},{highWaterMark:0});e.allReady=a,i(e)}),(function(e){a.catch((function(){})),n(e)}),o);if(t&&t.signal){var l=t.signal,c=function(){Ii(s,l.reason),l.removeEventListener("abort",c)};l.addEventListener("abort",c)}Ti(s)}))},t.version="18.2.0"},76539:function(e,t,i){"use strict";var n=i(8559),o=i(44853);function r(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,i=1;i<arguments.length;i++)t+="&args[]="+encodeURIComponent(arguments[i]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var a=new Set,s={};function l(e,t){c(e,t),c(e+"Capture",t)}function c(e,t){for(s[e]=t,e=0;e<t.length;e++)a.add(t[e])}var d=!("undefined"==typeof window||void 0===window.document||void 0===window.document.createElement),u=Object.prototype.hasOwnProperty,h=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,p={},g={};function f(e,t,i,n,o,r,a){this.acceptsBooleans=2===t||3===t||4===t,this.attributeName=n,this.attributeNamespace=o,this.mustUseProperty=i,this.propertyName=e,this.type=t,this.sanitizeURL=r,this.removeEmptyString=a}var m={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach((function(e){m[e]=new f(e,0,!1,e,null,!1,!1)})),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach((function(e){var t=e[0];m[t]=new f(t,1,!1,e[1],null,!1,!1)})),["contentEditable","draggable","spellCheck","value"].forEach((function(e){m[e]=new f(e,2,!1,e.toLowerCase(),null,!1,!1)})),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach((function(e){m[e]=new f(e,2,!1,e,null,!1,!1)})),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach((function(e){m[e]=new f(e,3,!1,e.toLowerCase(),null,!1,!1)})),["checked","multiple","muted","selected"].forEach((function(e){m[e]=new f(e,3,!0,e,null,!1,!1)})),["capture","download"].forEach((function(e){m[e]=new f(e,4,!1,e,null,!1,!1)})),["cols","rows","size","span"].forEach((function(e){m[e]=new f(e,6,!1,e,null,!1,!1)})),["rowSpan","start"].forEach((function(e){m[e]=new f(e,5,!1,e.toLowerCase(),null,!1,!1)}));var v=/[\-:]([a-z])/g;function y(e){return e[1].toUpperCase()}function C(e,t,i,n){var o=m.hasOwnProperty(t)?m[t]:null;(null!==o?0!==o.type:n||!(2<t.length)||"o"!==t[0]&&"O"!==t[0]||"n"!==t[1]&&"N"!==t[1])&&(function(e,t,i,n){if(null==t||function(e,t,i,n){if(null!==i&&0===i.type)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return!n&&(null!==i?!i.acceptsBooleans:"data-"!==(e=e.toLowerCase().slice(0,5))&&"aria-"!==e);default:return!1}}(e,t,i,n))return!0;if(n)return!1;if(null!==i)switch(i.type){case 3:return!t;case 4:return!1===t;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}(t,i,o,n)&&(i=null),n||null===o?function(e){return!!u.call(g,e)||!u.call(p,e)&&(h.test(e)?g[e]=!0:(p[e]=!0,!1))}(t)&&(null===i?e.removeAttribute(t):e.setAttribute(t,""+i)):o.mustUseProperty?e[o.propertyName]=null===i?3!==o.type&&"":i:(t=o.attributeName,n=o.attributeNamespace,null===i?e.removeAttribute(t):(i=3===(o=o.type)||4===o&&!0===i?"":""+i,n?e.setAttributeNS(n,t,i):e.setAttribute(t,i))))}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach((function(e){var t=e.replace(v,y);m[t]=new f(t,1,!1,e,null,!1,!1)})),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach((function(e){var t=e.replace(v,y);m[t]=new f(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)})),["xml:base","xml:lang","xml:space"].forEach((function(e){var t=e.replace(v,y);m[t]=new f(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)})),["tabIndex","crossOrigin"].forEach((function(e){m[e]=new f(e,1,!1,e.toLowerCase(),null,!1,!1)})),m.xlinkHref=new f("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach((function(e){m[e]=new f(e,1,!1,e.toLowerCase(),null,!0,!0)}));var b=n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,S=Symbol.for("react.element"),x=Symbol.for("react.portal"),T=Symbol.for("react.fragment"),w=Symbol.for("react.strict_mode"),O=Symbol.for("react.profiler"),P=Symbol.for("react.provider"),A=Symbol.for("react.context"),E=Symbol.for("react.forward_ref"),k=Symbol.for("react.suspense"),I=Symbol.for("react.suspense_list"),D=Symbol.for("react.memo"),_=Symbol.for("react.lazy");Symbol.for("react.scope"),Symbol.for("react.debug_trace_mode");var N=Symbol.for("react.offscreen");Symbol.for("react.legacy_hidden"),Symbol.for("react.cache"),Symbol.for("react.tracing_marker");var R=Symbol.iterator;function M(e){return null===e||"object"!=typeof e?null:"function"==typeof(e=R&&e[R]||e["@@iterator"])?e:null}var L,B=Object.assign;function F(e){if(void 0===L)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);L=t&&t[1]||""}return"\n"+L+e}var U=!1;function H(e,t){if(!e||U)return"";U=!0;var i=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),"object"==typeof Reflect&&Reflect.construct){try{Reflect.construct(t,[])}catch(e){var n=e}Reflect.construct(e,[],t)}else{try{t.call()}catch(e){n=e}e.call(t.prototype)}else{try{throw Error()}catch(e){n=e}e()}}catch(t){if(t&&n&&"string"==typeof t.stack){for(var o=t.stack.split("\n"),r=n.stack.split("\n"),a=o.length-1,s=r.length-1;1<=a&&0<=s&&o[a]!==r[s];)s--;for(;1<=a&&0<=s;a--,s--)if(o[a]!==r[s]){if(1!==a||1!==s)do{if(a--,0>--s||o[a]!==r[s]){var l="\n"+o[a].replace(" at new "," at ");return e.displayName&&l.includes("<anonymous>")&&(l=l.replace("<anonymous>",e.displayName)),l}}while(1<=a&&0<=s);break}}}finally{U=!1,Error.prepareStackTrace=i}return(e=e?e.displayName||e.name:"")?F(e):""}function $(e){switch(e.tag){case 5:return F(e.type);case 16:return F("Lazy");case 13:return F("Suspense");case 19:return F("SuspenseList");case 0:case 2:case 15:return H(e.type,!1);case 11:return H(e.type.render,!1);case 1:return H(e.type,!0);default:return""}}function Z(e){if(null==e)return null;if("function"==typeof e)return e.displayName||e.name||null;if("string"==typeof e)return e;switch(e){case T:return"Fragment";case x:return"Portal";case O:return"Profiler";case w:return"StrictMode";case k:return"Suspense";case I:return"SuspenseList"}if("object"==typeof e)switch(e.$$typeof){case A:return(e.displayName||"Context")+".Consumer";case P:return(e._context.displayName||"Context")+".Provider";case E:var t=e.render;return(e=e.displayName)||(e=""!==(e=t.displayName||t.name||"")?"ForwardRef("+e+")":"ForwardRef"),e;case D:return null!==(t=e.displayName||null)?t:Z(e.type)||"Memo";case _:t=e._payload,e=e._init;try{return Z(e(t))}catch(e){}}return null}function V(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=(e=t.render).displayName||e.name||"",t.displayName||(""!==e?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Z(t);case 8:return t===w?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if("function"==typeof t)return t.displayName||t.name||null;if("string"==typeof t)return t}return null}function G(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":case"object":return e;default:return""}}function j(e){var t=e.type;return(e=e.nodeName)&&"input"===e.toLowerCase()&&("checkbox"===t||"radio"===t)}function z(e){e._valueTracker||(e._valueTracker=function(e){var t=j(e)?"checked":"value",i=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),n=""+e[t];if(!e.hasOwnProperty(t)&&void 0!==i&&"function"==typeof i.get&&"function"==typeof i.set){var o=i.get,r=i.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return o.call(this)},set:function(e){n=""+e,r.call(this,e)}}),Object.defineProperty(e,t,{enumerable:i.enumerable}),{getValue:function(){return n},setValue:function(e){n=""+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}(e))}function W(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var i=t.getValue(),n="";return e&&(n=j(e)?e.checked?"true":"false":e.value),(e=n)!==i&&(t.setValue(e),!0)}function K(e){if(void 0===(e=e||("undefined"!=typeof document?document:void 0)))return null;try{return e.activeElement||e.body}catch(t){return e.body}}function q(e,t){var i=t.checked;return B({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:null!=i?i:e._wrapperState.initialChecked})}function Y(e,t){var i=null==t.defaultValue?"":t.defaultValue,n=null!=t.checked?t.checked:t.defaultChecked;i=G(null!=t.value?t.value:i),e._wrapperState={initialChecked:n,initialValue:i,controlled:"checkbox"===t.type||"radio"===t.type?null!=t.checked:null!=t.value}}function X(e,t){null!=(t=t.checked)&&C(e,"checked",t,!1)}function J(e,t){X(e,t);var i=G(t.value),n=t.type;if(null!=i)"number"===n?(0===i&&""===e.value||e.value!=i)&&(e.value=""+i):e.value!==""+i&&(e.value=""+i);else if("submit"===n||"reset"===n)return void e.removeAttribute("value");t.hasOwnProperty("value")?ee(e,t.type,i):t.hasOwnProperty("defaultValue")&&ee(e,t.type,G(t.defaultValue)),null==t.checked&&null!=t.defaultChecked&&(e.defaultChecked=!!t.defaultChecked)}function Q(e,t,i){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var n=t.type;if(!("submit"!==n&&"reset"!==n||void 0!==t.value&&null!==t.value))return;t=""+e._wrapperState.initialValue,i||t===e.value||(e.value=t),e.defaultValue=t}""!==(i=e.name)&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,""!==i&&(e.name=i)}function ee(e,t,i){"number"===t&&K(e.ownerDocument)===e||(null==i?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+i&&(e.defaultValue=""+i))}var te=Array.isArray;function ie(e,t,i,n){if(e=e.options,t){t={};for(var o=0;o<i.length;o++)t["$"+i[o]]=!0;for(i=0;i<e.length;i++)o=t.hasOwnProperty("$"+e[i].value),e[i].selected!==o&&(e[i].selected=o),o&&n&&(e[i].defaultSelected=!0)}else{for(i=""+G(i),t=null,o=0;o<e.length;o++){if(e[o].value===i)return e[o].selected=!0,void(n&&(e[o].defaultSelected=!0));null!==t||e[o].disabled||(t=e[o])}null!==t&&(t.selected=!0)}}function ne(e,t){if(null!=t.dangerouslySetInnerHTML)throw Error(r(91));return B({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function oe(e,t){var i=t.value;if(null==i){if(i=t.children,t=t.defaultValue,null!=i){if(null!=t)throw Error(r(92));if(te(i)){if(1<i.length)throw Error(r(93));i=i[0]}t=i}null==t&&(t=""),i=t}e._wrapperState={initialValue:G(i)}}function re(e,t){var i=G(t.value),n=G(t.defaultValue);null!=i&&((i=""+i)!==e.value&&(e.value=i),null==t.defaultValue&&e.defaultValue!==i&&(e.defaultValue=i)),null!=n&&(e.defaultValue=""+n)}function ae(e){var t=e.textContent;t===e._wrapperState.initialValue&&""!==t&&null!==t&&(e.value=t)}function se(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function le(e,t){return null==e||"http://www.w3.org/1999/xhtml"===e?se(t):"http://www.w3.org/2000/svg"===e&&"foreignObject"===t?"http://www.w3.org/1999/xhtml":e}var ce,de,ue=(de=function(e,t){if("http://www.w3.org/2000/svg"!==e.namespaceURI||"innerHTML"in e)e.innerHTML=t;else{for((ce=ce||document.createElement("div")).innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=ce.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}},"undefined"!=typeof MSApp&&MSApp.execUnsafeLocalFunction?function(e,t,i,n){MSApp.execUnsafeLocalFunction((function(){return de(e,t)}))}:de);function he(e,t){if(t){var i=e.firstChild;if(i&&i===e.lastChild&&3===i.nodeType)return void(i.nodeValue=t)}e.textContent=t}var pe={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},ge=["Webkit","ms","Moz","O"];function fe(e,t,i){return null==t||"boolean"==typeof t||""===t?"":i||"number"!=typeof t||0===t||pe.hasOwnProperty(e)&&pe[e]?(""+t).trim():t+"px"}function me(e,t){for(var i in e=e.style,t)if(t.hasOwnProperty(i)){var n=0===i.indexOf("--"),o=fe(i,t[i],n);"float"===i&&(i="cssFloat"),n?e.setProperty(i,o):e[i]=o}}Object.keys(pe).forEach((function(e){ge.forEach((function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),pe[t]=pe[e]}))}));var ve=B({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function ye(e,t){if(t){if(ve[e]&&(null!=t.children||null!=t.dangerouslySetInnerHTML))throw Error(r(137,e));if(null!=t.dangerouslySetInnerHTML){if(null!=t.children)throw Error(r(60));if("object"!=typeof t.dangerouslySetInnerHTML||!("__html"in t.dangerouslySetInnerHTML))throw Error(r(61))}if(null!=t.style&&"object"!=typeof t.style)throw Error(r(62))}}function Ce(e,t){if(-1===e.indexOf("-"))return"string"==typeof t.is;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var be=null;function Se(e){return(e=e.target||e.srcElement||window).correspondingUseElement&&(e=e.correspondingUseElement),3===e.nodeType?e.parentNode:e}var xe=null,Te=null,we=null;function Oe(e){if(e=bo(e)){if("function"!=typeof xe)throw Error(r(280));var t=e.stateNode;t&&(t=xo(t),xe(e.stateNode,e.type,t))}}function Pe(e){Te?we?we.push(e):we=[e]:Te=e}function Ae(){if(Te){var e=Te,t=we;if(we=Te=null,Oe(e),t)for(e=0;e<t.length;e++)Oe(t[e])}}function Ee(e,t){return e(t)}function ke(){}var Ie=!1;function De(e,t,i){if(Ie)return e(t,i);Ie=!0;try{return Ee(e,t,i)}finally{Ie=!1,(null!==Te||null!==we)&&(ke(),Ae())}}function _e(e,t){var i=e.stateNode;if(null===i)return null;var n=xo(i);if(null===n)return null;i=n[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(n=!n.disabled)||(n=!("button"===(e=e.type)||"input"===e||"select"===e||"textarea"===e)),e=!n;break e;default:e=!1}if(e)return null;if(i&&"function"!=typeof i)throw Error(r(231,t,typeof i));return i}var Ne=!1;if(d)try{var Re={};Object.defineProperty(Re,"passive",{get:function(){Ne=!0}}),window.addEventListener("test",Re,Re),window.removeEventListener("test",Re,Re)}catch(de){Ne=!1}function Me(e,t,i,n,o,r,a,s,l){var c=Array.prototype.slice.call(arguments,3);try{t.apply(i,c)}catch(e){this.onError(e)}}var Le=!1,Be=null,Fe=!1,Ue=null,He={onError:function(e){Le=!0,Be=e}};function $e(e,t,i,n,o,r,a,s,l){Le=!1,Be=null,Me.apply(He,arguments)}function Ze(e){var t=e,i=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do{0!=(4098&(t=e).flags)&&(i=t.return),e=t.return}while(e)}return 3===t.tag?i:null}function Ve(e){if(13===e.tag){var t=e.memoizedState;if(null===t&&null!==(e=e.alternate)&&(t=e.memoizedState),null!==t)return t.dehydrated}return null}function Ge(e){if(Ze(e)!==e)throw Error(r(188))}function je(e){return null!==(e=function(e){var t=e.alternate;if(!t){if(null===(t=Ze(e)))throw Error(r(188));return t!==e?null:e}for(var i=e,n=t;;){var o=i.return;if(null===o)break;var a=o.alternate;if(null===a){if(null!==(n=o.return)){i=n;continue}break}if(o.child===a.child){for(a=o.child;a;){if(a===i)return Ge(o),e;if(a===n)return Ge(o),t;a=a.sibling}throw Error(r(188))}if(i.return!==n.return)i=o,n=a;else{for(var s=!1,l=o.child;l;){if(l===i){s=!0,i=o,n=a;break}if(l===n){s=!0,n=o,i=a;break}l=l.sibling}if(!s){for(l=a.child;l;){if(l===i){s=!0,i=a,n=o;break}if(l===n){s=!0,n=a,i=o;break}l=l.sibling}if(!s)throw Error(r(189))}}if(i.alternate!==n)throw Error(r(190))}if(3!==i.tag)throw Error(r(188));return i.stateNode.current===i?e:t}(e))?ze(e):null}function ze(e){if(5===e.tag||6===e.tag)return e;for(e=e.child;null!==e;){var t=ze(e);if(null!==t)return t;e=e.sibling}return null}var We=o.unstable_scheduleCallback,Ke=o.unstable_cancelCallback,qe=o.unstable_shouldYield,Ye=o.unstable_requestPaint,Xe=o.unstable_now,Je=o.unstable_getCurrentPriorityLevel,Qe=o.unstable_ImmediatePriority,et=o.unstable_UserBlockingPriority,tt=o.unstable_NormalPriority,it=o.unstable_LowPriority,nt=o.unstable_IdlePriority,ot=null,rt=null,at=Math.clz32?Math.clz32:function(e){return 0===(e>>>=0)?32:31-(st(e)/lt|0)|0},st=Math.log,lt=Math.LN2,ct=64,dt=4194304;function ut(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return 4194240&e;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return 130023424&e;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function ht(e,t){var i=e.pendingLanes;if(0===i)return 0;var n=0,o=e.suspendedLanes,r=e.pingedLanes,a=268435455&i;if(0!==a){var s=a&~o;0!==s?n=ut(s):0!=(r&=a)&&(n=ut(r))}else 0!=(a=i&~o)?n=ut(a):0!==r&&(n=ut(r));if(0===n)return 0;if(0!==t&&t!==n&&0==(t&o)&&((o=n&-n)>=(r=t&-t)||16===o&&0!=(4194240&r)))return t;if(0!=(4&n)&&(n|=16&i),0!==(t=e.entangledLanes))for(e=e.entanglements,t&=n;0<t;)o=1<<(i=31-at(t)),n|=e[i],t&=~o;return n}function pt(e,t){switch(e){case 1:case 2:case 4:return t+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;default:return-1}}function gt(e){return 0!=(e=-1073741825&e.pendingLanes)?e:1073741824&e?1073741824:0}function ft(){var e=ct;return 0==(4194240&(ct<<=1))&&(ct=64),e}function mt(e){for(var t=[],i=0;31>i;i++)t.push(e);return t}function vt(e,t,i){e.pendingLanes|=t,536870912!==t&&(e.suspendedLanes=0,e.pingedLanes=0),(e=e.eventTimes)[t=31-at(t)]=i}function yt(e,t){var i=e.entangledLanes|=t;for(e=e.entanglements;i;){var n=31-at(i),o=1<<n;o&t|e[n]&t&&(e[n]|=t),i&=~o}}var Ct=0;function bt(e){return 1<(e&=-e)?4<e?0!=(268435455&e)?16:536870912:4:1}var St,xt,Tt,wt,Ot,Pt=!1,At=[],Et=null,kt=null,It=null,Dt=new Map,_t=new Map,Nt=[],Rt="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function Mt(e,t){switch(e){case"focusin":case"focusout":Et=null;break;case"dragenter":case"dragleave":kt=null;break;case"mouseover":case"mouseout":It=null;break;case"pointerover":case"pointerout":Dt.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":_t.delete(t.pointerId)}}function Lt(e,t,i,n,o,r){return null===e||e.nativeEvent!==r?(e={blockedOn:t,domEventName:i,eventSystemFlags:n,nativeEvent:r,targetContainers:[o]},null!==t&&null!==(t=bo(t))&&xt(t),e):(e.eventSystemFlags|=n,t=e.targetContainers,null!==o&&-1===t.indexOf(o)&&t.push(o),e)}function Bt(e){var t=Co(e.target);if(null!==t){var i=Ze(t);if(null!==i)if(13===(t=i.tag)){if(null!==(t=Ve(i)))return e.blockedOn=t,void Ot(e.priority,(function(){Tt(i)}))}else if(3===t&&i.stateNode.current.memoizedState.isDehydrated)return void(e.blockedOn=3===i.tag?i.stateNode.containerInfo:null)}e.blockedOn=null}function Ft(e){if(null!==e.blockedOn)return!1;for(var t=e.targetContainers;0<t.length;){var i=qt(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(null!==i)return null!==(t=bo(i))&&xt(t),e.blockedOn=i,!1;var n=new(i=e.nativeEvent).constructor(i.type,i);be=n,i.target.dispatchEvent(n),be=null,t.shift()}return!0}function Ut(e,t,i){Ft(e)&&i.delete(t)}function Ht(){Pt=!1,null!==Et&&Ft(Et)&&(Et=null),null!==kt&&Ft(kt)&&(kt=null),null!==It&&Ft(It)&&(It=null),Dt.forEach(Ut),_t.forEach(Ut)}function $t(e,t){e.blockedOn===t&&(e.blockedOn=null,Pt||(Pt=!0,o.unstable_scheduleCallback(o.unstable_NormalPriority,Ht)))}function Zt(e){function t(t){return $t(t,e)}if(0<At.length){$t(At[0],e);for(var i=1;i<At.length;i++){var n=At[i];n.blockedOn===e&&(n.blockedOn=null)}}for(null!==Et&&$t(Et,e),null!==kt&&$t(kt,e),null!==It&&$t(It,e),Dt.forEach(t),_t.forEach(t),i=0;i<Nt.length;i++)(n=Nt[i]).blockedOn===e&&(n.blockedOn=null);for(;0<Nt.length&&null===(i=Nt[0]).blockedOn;)Bt(i),null===i.blockedOn&&Nt.shift()}var Vt=b.ReactCurrentBatchConfig,Gt=!0;function jt(e,t,i,n){var o=Ct,r=Vt.transition;Vt.transition=null;try{Ct=1,Wt(e,t,i,n)}finally{Ct=o,Vt.transition=r}}function zt(e,t,i,n){var o=Ct,r=Vt.transition;Vt.transition=null;try{Ct=4,Wt(e,t,i,n)}finally{Ct=o,Vt.transition=r}}function Wt(e,t,i,n){if(Gt){var o=qt(e,t,i,n);if(null===o)Gn(e,t,n,Kt,i),Mt(e,n);else if(function(e,t,i,n,o){switch(t){case"focusin":return Et=Lt(Et,e,t,i,n,o),!0;case"dragenter":return kt=Lt(kt,e,t,i,n,o),!0;case"mouseover":return It=Lt(It,e,t,i,n,o),!0;case"pointerover":var r=o.pointerId;return Dt.set(r,Lt(Dt.get(r)||null,e,t,i,n,o)),!0;case"gotpointercapture":return r=o.pointerId,_t.set(r,Lt(_t.get(r)||null,e,t,i,n,o)),!0}return!1}(o,e,t,i,n))n.stopPropagation();else if(Mt(e,n),4&t&&-1<Rt.indexOf(e)){for(;null!==o;){var r=bo(o);if(null!==r&&St(r),null===(r=qt(e,t,i,n))&&Gn(e,t,n,Kt,i),r===o)break;o=r}null!==o&&n.stopPropagation()}else Gn(e,t,n,null,i)}}var Kt=null;function qt(e,t,i,n){if(Kt=null,null!==(e=Co(e=Se(n))))if(null===(t=Ze(e)))e=null;else if(13===(i=t.tag)){if(null!==(e=Ve(t)))return e;e=null}else if(3===i){if(t.stateNode.current.memoizedState.isDehydrated)return 3===t.tag?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null);return Kt=e,null}function Yt(e){switch(e){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(Je()){case Qe:return 1;case et:return 4;case tt:case it:return 16;case nt:return 536870912;default:return 16}default:return 16}}var Xt=null,Jt=null,Qt=null;function ei(){if(Qt)return Qt;var e,t,i=Jt,n=i.length,o="value"in Xt?Xt.value:Xt.textContent,r=o.length;for(e=0;e<n&&i[e]===o[e];e++);var a=n-e;for(t=1;t<=a&&i[n-t]===o[r-t];t++);return Qt=o.slice(e,1<t?1-t:void 0)}function ti(e){var t=e.keyCode;return"charCode"in e?0===(e=e.charCode)&&13===t&&(e=13):e=t,10===e&&(e=13),32<=e||13===e?e:0}function ii(){return!0}function ni(){return!1}function oi(e){function t(t,i,n,o,r){for(var a in this._reactName=t,this._targetInst=n,this.type=i,this.nativeEvent=o,this.target=r,this.currentTarget=null,e)e.hasOwnProperty(a)&&(t=e[a],this[a]=t?t(o):o[a]);return this.isDefaultPrevented=(null!=o.defaultPrevented?o.defaultPrevented:!1===o.returnValue)?ii:ni,this.isPropagationStopped=ni,this}return B(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():"unknown"!=typeof e.returnValue&&(e.returnValue=!1),this.isDefaultPrevented=ii)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():"unknown"!=typeof e.cancelBubble&&(e.cancelBubble=!0),this.isPropagationStopped=ii)},persist:function(){},isPersistent:ii}),t}var ri,ai,si,li={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},ci=oi(li),di=B({},li,{view:0,detail:0}),ui=oi(di),hi=B({},di,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:wi,button:0,buttons:0,relatedTarget:function(e){return void 0===e.relatedTarget?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==si&&(si&&"mousemove"===e.type?(ri=e.screenX-si.screenX,ai=e.screenY-si.screenY):ai=ri=0,si=e),ri)},movementY:function(e){return"movementY"in e?e.movementY:ai}}),pi=oi(hi),gi=oi(B({},hi,{dataTransfer:0})),fi=oi(B({},di,{relatedTarget:0})),mi=oi(B({},li,{animationName:0,elapsedTime:0,pseudoElement:0})),vi=B({},li,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),yi=oi(vi),Ci=oi(B({},li,{data:0})),bi={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Si={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},xi={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Ti(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):!!(e=xi[e])&&!!t[e]}function wi(){return Ti}var Oi=B({},di,{key:function(e){if(e.key){var t=bi[e.key]||e.key;if("Unidentified"!==t)return t}return"keypress"===e.type?13===(e=ti(e))?"Enter":String.fromCharCode(e):"keydown"===e.type||"keyup"===e.type?Si[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:wi,charCode:function(e){return"keypress"===e.type?ti(e):0},keyCode:function(e){return"keydown"===e.type||"keyup"===e.type?e.keyCode:0},which:function(e){return"keypress"===e.type?ti(e):"keydown"===e.type||"keyup"===e.type?e.keyCode:0}}),Pi=oi(Oi),Ai=oi(B({},hi,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),Ei=oi(B({},di,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:wi})),ki=oi(B({},li,{propertyName:0,elapsedTime:0,pseudoElement:0})),Ii=B({},hi,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),Di=oi(Ii),_i=[9,13,27,32],Ni=d&&"CompositionEvent"in window,Ri=null;d&&"documentMode"in document&&(Ri=document.documentMode);var Mi=d&&"TextEvent"in window&&!Ri,Li=d&&(!Ni||Ri&&8<Ri&&11>=Ri),Bi=String.fromCharCode(32),Fi=!1;function Ui(e,t){switch(e){case"keyup":return-1!==_i.indexOf(t.keyCode);case"keydown":return 229!==t.keyCode;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Hi(e){return"object"==typeof(e=e.detail)&&"data"in e?e.data:null}var $i=!1,Zi={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Vi(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return"input"===t?!!Zi[e.type]:"textarea"===t}function Gi(e,t,i,n){Pe(n),0<(t=zn(t,"onChange")).length&&(i=new ci("onChange","change",null,i,n),e.push({event:i,listeners:t}))}var ji=null,zi=null;function Wi(e){Fn(e,0)}function Ki(e){if(W(So(e)))return e}function qi(e,t){if("change"===e)return t}var Yi=!1;if(d){var Xi;if(d){var Ji="oninput"in document;if(!Ji){var Qi=document.createElement("div");Qi.setAttribute("oninput","return;"),Ji="function"==typeof Qi.oninput}Xi=Ji}else Xi=!1;Yi=Xi&&(!document.documentMode||9<document.documentMode)}function en(){ji&&(ji.detachEvent("onpropertychange",tn),zi=ji=null)}function tn(e){if("value"===e.propertyName&&Ki(zi)){var t=[];Gi(t,zi,e,Se(e)),De(Wi,t)}}function nn(e,t,i){"focusin"===e?(en(),zi=i,(ji=t).attachEvent("onpropertychange",tn)):"focusout"===e&&en()}function on(e){if("selectionchange"===e||"keyup"===e||"keydown"===e)return Ki(zi)}function rn(e,t){if("click"===e)return Ki(t)}function an(e,t){if("input"===e||"change"===e)return Ki(t)}var sn="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t};function ln(e,t){if(sn(e,t))return!0;if("object"!=typeof e||null===e||"object"!=typeof t||null===t)return!1;var i=Object.keys(e),n=Object.keys(t);if(i.length!==n.length)return!1;for(n=0;n<i.length;n++){var o=i[n];if(!u.call(t,o)||!sn(e[o],t[o]))return!1}return!0}function cn(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function dn(e,t){var i,n=cn(e);for(e=0;n;){if(3===n.nodeType){if(i=e+n.textContent.length,e<=t&&i>=t)return{node:n,offset:t-e};e=i}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=cn(n)}}function un(e,t){return!(!e||!t)&&(e===t||(!e||3!==e.nodeType)&&(t&&3===t.nodeType?un(e,t.parentNode):"contains"in e?e.contains(t):!!e.compareDocumentPosition&&!!(16&e.compareDocumentPosition(t))))}function hn(){for(var e=window,t=K();t instanceof e.HTMLIFrameElement;){try{var i="string"==typeof t.contentWindow.location.href}catch(e){i=!1}if(!i)break;t=K((e=t.contentWindow).document)}return t}function pn(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&("input"===t&&("text"===e.type||"search"===e.type||"tel"===e.type||"url"===e.type||"password"===e.type)||"textarea"===t||"true"===e.contentEditable)}function gn(e){var t=hn(),i=e.focusedElem,n=e.selectionRange;if(t!==i&&i&&i.ownerDocument&&un(i.ownerDocument.documentElement,i)){if(null!==n&&pn(i))if(t=n.start,void 0===(e=n.end)&&(e=t),"selectionStart"in i)i.selectionStart=t,i.selectionEnd=Math.min(e,i.value.length);else if((e=(t=i.ownerDocument||document)&&t.defaultView||window).getSelection){e=e.getSelection();var o=i.textContent.length,r=Math.min(n.start,o);n=void 0===n.end?r:Math.min(n.end,o),!e.extend&&r>n&&(o=n,n=r,r=o),o=dn(i,r);var a=dn(i,n);o&&a&&(1!==e.rangeCount||e.anchorNode!==o.node||e.anchorOffset!==o.offset||e.focusNode!==a.node||e.focusOffset!==a.offset)&&((t=t.createRange()).setStart(o.node,o.offset),e.removeAllRanges(),r>n?(e.addRange(t),e.extend(a.node,a.offset)):(t.setEnd(a.node,a.offset),e.addRange(t)))}for(t=[],e=i;e=e.parentNode;)1===e.nodeType&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for("function"==typeof i.focus&&i.focus(),i=0;i<t.length;i++)(e=t[i]).element.scrollLeft=e.left,e.element.scrollTop=e.top}}var fn=d&&"documentMode"in document&&11>=document.documentMode,mn=null,vn=null,yn=null,Cn=!1;function bn(e,t,i){var n=i.window===i?i.document:9===i.nodeType?i:i.ownerDocument;Cn||null==mn||mn!==K(n)||(n="selectionStart"in(n=mn)&&pn(n)?{start:n.selectionStart,end:n.selectionEnd}:{anchorNode:(n=(n.ownerDocument&&n.ownerDocument.defaultView||window).getSelection()).anchorNode,anchorOffset:n.anchorOffset,focusNode:n.focusNode,focusOffset:n.focusOffset},yn&&ln(yn,n)||(yn=n,0<(n=zn(vn,"onSelect")).length&&(t=new ci("onSelect","select",null,t,i),e.push({event:t,listeners:n}),t.target=mn)))}function Sn(e,t){var i={};return i[e.toLowerCase()]=t.toLowerCase(),i["Webkit"+e]="webkit"+t,i["Moz"+e]="moz"+t,i}var xn={animationend:Sn("Animation","AnimationEnd"),animationiteration:Sn("Animation","AnimationIteration"),animationstart:Sn("Animation","AnimationStart"),transitionend:Sn("Transition","TransitionEnd")},Tn={},wn={};function On(e){if(Tn[e])return Tn[e];if(!xn[e])return e;var t,i=xn[e];for(t in i)if(i.hasOwnProperty(t)&&t in wn)return Tn[e]=i[t];return e}d&&(wn=document.createElement("div").style,"AnimationEvent"in window||(delete xn.animationend.animation,delete xn.animationiteration.animation,delete xn.animationstart.animation),"TransitionEvent"in window||delete xn.transitionend.transition);var Pn=On("animationend"),An=On("animationiteration"),En=On("animationstart"),kn=On("transitionend"),In=new Map,Dn="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function _n(e,t){In.set(e,t),l(t,[e])}for(var Nn=0;Nn<Dn.length;Nn++){var Rn=Dn[Nn];_n(Rn.toLowerCase(),"on"+(Rn[0].toUpperCase()+Rn.slice(1)))}_n(Pn,"onAnimationEnd"),_n(An,"onAnimationIteration"),_n(En,"onAnimationStart"),_n("dblclick","onDoubleClick"),_n("focusin","onFocus"),_n("focusout","onBlur"),_n(kn,"onTransitionEnd"),c("onMouseEnter",["mouseout","mouseover"]),c("onMouseLeave",["mouseout","mouseover"]),c("onPointerEnter",["pointerout","pointerover"]),c("onPointerLeave",["pointerout","pointerover"]),l("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),l("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),l("onBeforeInput",["compositionend","keypress","textInput","paste"]),l("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),l("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),l("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Mn="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),Ln=new Set("cancel close invalid load scroll toggle".split(" ").concat(Mn));function Bn(e,t,i){var n=e.type||"unknown-event";e.currentTarget=i,function(e,t,i,n,o,a,s,l,c){if($e.apply(this,arguments),Le){if(!Le)throw Error(r(198));var d=Be;Le=!1,Be=null,Fe||(Fe=!0,Ue=d)}}(n,t,void 0,e),e.currentTarget=null}function Fn(e,t){t=0!=(4&t);for(var i=0;i<e.length;i++){var n=e[i],o=n.event;n=n.listeners;e:{var r=void 0;if(t)for(var a=n.length-1;0<=a;a--){var s=n[a],l=s.instance,c=s.currentTarget;if(s=s.listener,l!==r&&o.isPropagationStopped())break e;Bn(o,s,c),r=l}else for(a=0;a<n.length;a++){if(l=(s=n[a]).instance,c=s.currentTarget,s=s.listener,l!==r&&o.isPropagationStopped())break e;Bn(o,s,c),r=l}}}if(Fe)throw e=Ue,Fe=!1,Ue=null,e}function Un(e,t){var i=t[mo];void 0===i&&(i=t[mo]=new Set);var n=e+"__bubble";i.has(n)||(Vn(t,e,2,!1),i.add(n))}function Hn(e,t,i){var n=0;t&&(n|=4),Vn(i,e,n,t)}var $n="_reactListening"+Math.random().toString(36).slice(2);function Zn(e){if(!e[$n]){e[$n]=!0,a.forEach((function(t){"selectionchange"!==t&&(Ln.has(t)||Hn(t,!1,e),Hn(t,!0,e))}));var t=9===e.nodeType?e:e.ownerDocument;null===t||t[$n]||(t[$n]=!0,Hn("selectionchange",!1,t))}}function Vn(e,t,i,n){switch(Yt(t)){case 1:var o=jt;break;case 4:o=zt;break;default:o=Wt}i=o.bind(null,t,i,e),o=void 0,!Ne||"touchstart"!==t&&"touchmove"!==t&&"wheel"!==t||(o=!0),n?void 0!==o?e.addEventListener(t,i,{capture:!0,passive:o}):e.addEventListener(t,i,!0):void 0!==o?e.addEventListener(t,i,{passive:o}):e.addEventListener(t,i,!1)}function Gn(e,t,i,n,o){var r=n;if(0==(1&t)&&0==(2&t)&&null!==n)e:for(;;){if(null===n)return;var a=n.tag;if(3===a||4===a){var s=n.stateNode.containerInfo;if(s===o||8===s.nodeType&&s.parentNode===o)break;if(4===a)for(a=n.return;null!==a;){var l=a.tag;if((3===l||4===l)&&((l=a.stateNode.containerInfo)===o||8===l.nodeType&&l.parentNode===o))return;a=a.return}for(;null!==s;){if(null===(a=Co(s)))return;if(5===(l=a.tag)||6===l){n=r=a;continue e}s=s.parentNode}}n=n.return}De((function(){var n=r,o=Se(i),a=[];e:{var s=In.get(e);if(void 0!==s){var l=ci,c=e;switch(e){case"keypress":if(0===ti(i))break e;case"keydown":case"keyup":l=Pi;break;case"focusin":c="focus",l=fi;break;case"focusout":c="blur",l=fi;break;case"beforeblur":case"afterblur":l=fi;break;case"click":if(2===i.button)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":l=pi;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":l=gi;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":l=Ei;break;case Pn:case An:case En:l=mi;break;case kn:l=ki;break;case"scroll":l=ui;break;case"wheel":l=Di;break;case"copy":case"cut":case"paste":l=yi;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":l=Ai}var d=0!=(4&t),u=!d&&"scroll"===e,h=d?null!==s?s+"Capture":null:s;d=[];for(var p,g=n;null!==g;){var f=(p=g).stateNode;if(5===p.tag&&null!==f&&(p=f,null!==h&&null!=(f=_e(g,h))&&d.push(jn(g,f,p))),u)break;g=g.return}0<d.length&&(s=new l(s,c,null,i,o),a.push({event:s,listeners:d}))}}if(0==(7&t)){if(l="mouseout"===e||"pointerout"===e,(!(s="mouseover"===e||"pointerover"===e)||i===be||!(c=i.relatedTarget||i.fromElement)||!Co(c)&&!c[fo])&&(l||s)&&(s=o.window===o?o:(s=o.ownerDocument)?s.defaultView||s.parentWindow:window,l?(l=n,null!==(c=(c=i.relatedTarget||i.toElement)?Co(c):null)&&(c!==(u=Ze(c))||5!==c.tag&&6!==c.tag)&&(c=null)):(l=null,c=n),l!==c)){if(d=pi,f="onMouseLeave",h="onMouseEnter",g="mouse","pointerout"!==e&&"pointerover"!==e||(d=Ai,f="onPointerLeave",h="onPointerEnter",g="pointer"),u=null==l?s:So(l),p=null==c?s:So(c),(s=new d(f,g+"leave",l,i,o)).target=u,s.relatedTarget=p,f=null,Co(o)===n&&((d=new d(h,g+"enter",c,i,o)).target=p,d.relatedTarget=u,f=d),u=f,l&&c)e:{for(h=c,g=0,p=d=l;p;p=Wn(p))g++;for(p=0,f=h;f;f=Wn(f))p++;for(;0<g-p;)d=Wn(d),g--;for(;0<p-g;)h=Wn(h),p--;for(;g--;){if(d===h||null!==h&&d===h.alternate)break e;d=Wn(d),h=Wn(h)}d=null}else d=null;null!==l&&Kn(a,s,l,d,!1),null!==c&&null!==u&&Kn(a,u,c,d,!0)}if("select"===(l=(s=n?So(n):window).nodeName&&s.nodeName.toLowerCase())||"input"===l&&"file"===s.type)var m=qi;else if(Vi(s))if(Yi)m=an;else{m=on;var v=nn}else(l=s.nodeName)&&"input"===l.toLowerCase()&&("checkbox"===s.type||"radio"===s.type)&&(m=rn);switch(m&&(m=m(e,n))?Gi(a,m,i,o):(v&&v(e,s,n),"focusout"===e&&(v=s._wrapperState)&&v.controlled&&"number"===s.type&&ee(s,"number",s.value)),v=n?So(n):window,e){case"focusin":(Vi(v)||"true"===v.contentEditable)&&(mn=v,vn=n,yn=null);break;case"focusout":yn=vn=mn=null;break;case"mousedown":Cn=!0;break;case"contextmenu":case"mouseup":case"dragend":Cn=!1,bn(a,i,o);break;case"selectionchange":if(fn)break;case"keydown":case"keyup":bn(a,i,o)}var y;if(Ni)e:{switch(e){case"compositionstart":var C="onCompositionStart";break e;case"compositionend":C="onCompositionEnd";break e;case"compositionupdate":C="onCompositionUpdate";break e}C=void 0}else $i?Ui(e,i)&&(C="onCompositionEnd"):"keydown"===e&&229===i.keyCode&&(C="onCompositionStart");C&&(Li&&"ko"!==i.locale&&($i||"onCompositionStart"!==C?"onCompositionEnd"===C&&$i&&(y=ei()):(Jt="value"in(Xt=o)?Xt.value:Xt.textContent,$i=!0)),0<(v=zn(n,C)).length&&(C=new Ci(C,e,null,i,o),a.push({event:C,listeners:v}),(y||null!==(y=Hi(i)))&&(C.data=y))),(y=Mi?function(e,t){switch(e){case"compositionend":return Hi(t);case"keypress":return 32!==t.which?null:(Fi=!0,Bi);case"textInput":return(e=t.data)===Bi&&Fi?null:e;default:return null}}(e,i):function(e,t){if($i)return"compositionend"===e||!Ni&&Ui(e,t)?(e=ei(),Qt=Jt=Xt=null,$i=!1,e):null;switch(e){case"paste":default:return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return Li&&"ko"!==t.locale?null:t.data}}(e,i))&&0<(n=zn(n,"onBeforeInput")).length&&(o=new Ci("onBeforeInput","beforeinput",null,i,o),a.push({event:o,listeners:n}),o.data=y)}Fn(a,t)}))}function jn(e,t,i){return{instance:e,listener:t,currentTarget:i}}function zn(e,t){for(var i=t+"Capture",n=[];null!==e;){var o=e,r=o.stateNode;5===o.tag&&null!==r&&(o=r,null!=(r=_e(e,i))&&n.unshift(jn(e,r,o)),null!=(r=_e(e,t))&&n.push(jn(e,r,o))),e=e.return}return n}function Wn(e){if(null===e)return null;do{e=e.return}while(e&&5!==e.tag);return e||null}function Kn(e,t,i,n,o){for(var r=t._reactName,a=[];null!==i&&i!==n;){var s=i,l=s.alternate,c=s.stateNode;if(null!==l&&l===n)break;5===s.tag&&null!==c&&(s=c,o?null!=(l=_e(i,r))&&a.unshift(jn(i,l,s)):o||null!=(l=_e(i,r))&&a.push(jn(i,l,s))),i=i.return}0!==a.length&&e.push({event:t,listeners:a})}var qn=/\r\n?/g,Yn=/\u0000|\uFFFD/g;function Xn(e){return("string"==typeof e?e:""+e).replace(qn,"\n").replace(Yn,"")}function Jn(e,t,i){if(t=Xn(t),Xn(e)!==t&&i)throw Error(r(425))}function Qn(){}var eo=null,to=null;function io(e,t){return"textarea"===e||"noscript"===e||"string"==typeof t.children||"number"==typeof t.children||"object"==typeof t.dangerouslySetInnerHTML&&null!==t.dangerouslySetInnerHTML&&null!=t.dangerouslySetInnerHTML.__html}var no="function"==typeof setTimeout?setTimeout:void 0,oo="function"==typeof clearTimeout?clearTimeout:void 0,ro="function"==typeof Promise?Promise:void 0,ao="function"==typeof queueMicrotask?queueMicrotask:void 0!==ro?function(e){return ro.resolve(null).then(e).catch(so)}:no;function so(e){setTimeout((function(){throw e}))}function lo(e,t){var i=t,n=0;do{var o=i.nextSibling;if(e.removeChild(i),o&&8===o.nodeType)if("/$"===(i=o.data)){if(0===n)return e.removeChild(o),void Zt(t);n--}else"$"!==i&&"$?"!==i&&"$!"!==i||n++;i=o}while(i);Zt(t)}function co(e){for(;null!=e;e=e.nextSibling){var t=e.nodeType;if(1===t||3===t)break;if(8===t){if("$"===(t=e.data)||"$!"===t||"$?"===t)break;if("/$"===t)return null}}return e}function uo(e){e=e.previousSibling;for(var t=0;e;){if(8===e.nodeType){var i=e.data;if("$"===i||"$!"===i||"$?"===i){if(0===t)return e;t--}else"/$"===i&&t++}e=e.previousSibling}return null}var ho=Math.random().toString(36).slice(2),po="__reactFiber$"+ho,go="__reactProps$"+ho,fo="__reactContainer$"+ho,mo="__reactEvents$"+ho,vo="__reactListeners$"+ho,yo="__reactHandles$"+ho;function Co(e){var t=e[po];if(t)return t;for(var i=e.parentNode;i;){if(t=i[fo]||i[po]){if(i=t.alternate,null!==t.child||null!==i&&null!==i.child)for(e=uo(e);null!==e;){if(i=e[po])return i;e=uo(e)}return t}i=(e=i).parentNode}return null}function bo(e){return!(e=e[po]||e[fo])||5!==e.tag&&6!==e.tag&&13!==e.tag&&3!==e.tag?null:e}function So(e){if(5===e.tag||6===e.tag)return e.stateNode;throw Error(r(33))}function xo(e){return e[go]||null}var To=[],wo=-1;function Oo(e){return{current:e}}function Po(e){0>wo||(e.current=To[wo],To[wo]=null,wo--)}function Ao(e,t){wo++,To[wo]=e.current,e.current=t}var Eo={},ko=Oo(Eo),Io=Oo(!1),Do=Eo;function _o(e,t){var i=e.type.contextTypes;if(!i)return Eo;var n=e.stateNode;if(n&&n.__reactInternalMemoizedUnmaskedChildContext===t)return n.__reactInternalMemoizedMaskedChildContext;var o,r={};for(o in i)r[o]=t[o];return n&&((e=e.stateNode).__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=r),r}function No(e){return null!=e.childContextTypes}function Ro(){Po(Io),Po(ko)}function Mo(e,t,i){if(ko.current!==Eo)throw Error(r(168));Ao(ko,t),Ao(Io,i)}function Lo(e,t,i){var n=e.stateNode;if(t=t.childContextTypes,"function"!=typeof n.getChildContext)return i;for(var o in n=n.getChildContext())if(!(o in t))throw Error(r(108,V(e)||"Unknown",o));return B({},i,n)}function Bo(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Eo,Do=ko.current,Ao(ko,e),Ao(Io,Io.current),!0}function Fo(e,t,i){var n=e.stateNode;if(!n)throw Error(r(169));i?(e=Lo(e,t,Do),n.__reactInternalMemoizedMergedChildContext=e,Po(Io),Po(ko),Ao(ko,e)):Po(Io),Ao(Io,i)}var Uo=null,Ho=!1,$o=!1;function Zo(e){null===Uo?Uo=[e]:Uo.push(e)}function Vo(){if(!$o&&null!==Uo){$o=!0;var e=0,t=Ct;try{var i=Uo;for(Ct=1;e<i.length;e++){var n=i[e];do{n=n(!0)}while(null!==n)}Uo=null,Ho=!1}catch(t){throw null!==Uo&&(Uo=Uo.slice(e+1)),We(Qe,Vo),t}finally{Ct=t,$o=!1}}return null}var Go=[],jo=0,zo=null,Wo=0,Ko=[],qo=0,Yo=null,Xo=1,Jo="";function Qo(e,t){Go[jo++]=Wo,Go[jo++]=zo,zo=e,Wo=t}function er(e,t,i){Ko[qo++]=Xo,Ko[qo++]=Jo,Ko[qo++]=Yo,Yo=e;var n=Xo;e=Jo;var o=32-at(n)-1;n&=~(1<<o),i+=1;var r=32-at(t)+o;if(30<r){var a=o-o%5;r=(n&(1<<a)-1).toString(32),n>>=a,o-=a,Xo=1<<32-at(t)+o|i<<o|n,Jo=r+e}else Xo=1<<r|i<<o|n,Jo=e}function tr(e){null!==e.return&&(Qo(e,1),er(e,1,0))}function ir(e){for(;e===zo;)zo=Go[--jo],Go[jo]=null,Wo=Go[--jo],Go[jo]=null;for(;e===Yo;)Yo=Ko[--qo],Ko[qo]=null,Jo=Ko[--qo],Ko[qo]=null,Xo=Ko[--qo],Ko[qo]=null}var nr=null,or=null,rr=!1,ar=null;function sr(e,t){var i=Dc(5,null,null,0);i.elementType="DELETED",i.stateNode=t,i.return=e,null===(t=e.deletions)?(e.deletions=[i],e.flags|=16):t.push(i)}function lr(e,t){switch(e.tag){case 5:var i=e.type;return null!==(t=1!==t.nodeType||i.toLowerCase()!==t.nodeName.toLowerCase()?null:t)&&(e.stateNode=t,nr=e,or=co(t.firstChild),!0);case 6:return null!==(t=""===e.pendingProps||3!==t.nodeType?null:t)&&(e.stateNode=t,nr=e,or=null,!0);case 13:return null!==(t=8!==t.nodeType?null:t)&&(i=null!==Yo?{id:Xo,overflow:Jo}:null,e.memoizedState={dehydrated:t,treeContext:i,retryLane:1073741824},(i=Dc(18,null,null,0)).stateNode=t,i.return=e,e.child=i,nr=e,or=null,!0);default:return!1}}function cr(e){return 0!=(1&e.mode)&&0==(128&e.flags)}function dr(e){if(rr){var t=or;if(t){var i=t;if(!lr(e,t)){if(cr(e))throw Error(r(418));t=co(i.nextSibling);var n=nr;t&&lr(e,t)?sr(n,i):(e.flags=-4097&e.flags|2,rr=!1,nr=e)}}else{if(cr(e))throw Error(r(418));e.flags=-4097&e.flags|2,rr=!1,nr=e}}}function ur(e){for(e=e.return;null!==e&&5!==e.tag&&3!==e.tag&&13!==e.tag;)e=e.return;nr=e}function hr(e){if(e!==nr)return!1;if(!rr)return ur(e),rr=!0,!1;var t;if((t=3!==e.tag)&&!(t=5!==e.tag)&&(t="head"!==(t=e.type)&&"body"!==t&&!io(e.type,e.memoizedProps)),t&&(t=or)){if(cr(e))throw pr(),Error(r(418));for(;t;)sr(e,t),t=co(t.nextSibling)}if(ur(e),13===e.tag){if(!(e=null!==(e=e.memoizedState)?e.dehydrated:null))throw Error(r(317));e:{for(e=e.nextSibling,t=0;e;){if(8===e.nodeType){var i=e.data;if("/$"===i){if(0===t){or=co(e.nextSibling);break e}t--}else"$"!==i&&"$!"!==i&&"$?"!==i||t++}e=e.nextSibling}or=null}}else or=nr?co(e.stateNode.nextSibling):null;return!0}function pr(){for(var e=or;e;)e=co(e.nextSibling)}function gr(){or=nr=null,rr=!1}function fr(e){null===ar?ar=[e]:ar.push(e)}var mr=b.ReactCurrentBatchConfig;function vr(e,t){if(e&&e.defaultProps){for(var i in t=B({},t),e=e.defaultProps)void 0===t[i]&&(t[i]=e[i]);return t}return t}var yr=Oo(null),Cr=null,br=null,Sr=null;function xr(){Sr=br=Cr=null}function Tr(e){var t=yr.current;Po(yr),e._currentValue=t}function wr(e,t,i){for(;null!==e;){var n=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,null!==n&&(n.childLanes|=t)):null!==n&&(n.childLanes&t)!==t&&(n.childLanes|=t),e===i)break;e=e.return}}function Or(e,t){Cr=e,Sr=br=null,null!==(e=e.dependencies)&&null!==e.firstContext&&(0!=(e.lanes&t)&&(Cs=!0),e.firstContext=null)}function Pr(e){var t=e._currentValue;if(Sr!==e)if(e={context:e,memoizedValue:t,next:null},null===br){if(null===Cr)throw Error(r(308));br=e,Cr.dependencies={lanes:0,firstContext:e}}else br=br.next=e;return t}var Ar=null;function Er(e){null===Ar?Ar=[e]:Ar.push(e)}function kr(e,t,i,n){var o=t.interleaved;return null===o?(i.next=i,Er(t)):(i.next=o.next,o.next=i),t.interleaved=i,Ir(e,n)}function Ir(e,t){e.lanes|=t;var i=e.alternate;for(null!==i&&(i.lanes|=t),i=e,e=e.return;null!==e;)e.childLanes|=t,null!==(i=e.alternate)&&(i.childLanes|=t),i=e,e=e.return;return 3===i.tag?i.stateNode:null}var Dr=!1;function _r(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Nr(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function Rr(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function Mr(e,t,i){var n=e.updateQueue;if(null===n)return null;if(n=n.shared,0!=(2&El)){var o=n.pending;return null===o?t.next=t:(t.next=o.next,o.next=t),n.pending=t,Ir(e,i)}return null===(o=n.interleaved)?(t.next=t,Er(n)):(t.next=o.next,o.next=t),n.interleaved=t,Ir(e,i)}function Lr(e,t,i){if(null!==(t=t.updateQueue)&&(t=t.shared,0!=(4194240&i))){var n=t.lanes;i|=n&=e.pendingLanes,t.lanes=i,yt(e,i)}}function Br(e,t){var i=e.updateQueue,n=e.alternate;if(null!==n&&i===(n=n.updateQueue)){var o=null,r=null;if(null!==(i=i.firstBaseUpdate)){do{var a={eventTime:i.eventTime,lane:i.lane,tag:i.tag,payload:i.payload,callback:i.callback,next:null};null===r?o=r=a:r=r.next=a,i=i.next}while(null!==i);null===r?o=r=t:r=r.next=t}else o=r=t;return i={baseState:n.baseState,firstBaseUpdate:o,lastBaseUpdate:r,shared:n.shared,effects:n.effects},void(e.updateQueue=i)}null===(e=i.lastBaseUpdate)?i.firstBaseUpdate=t:e.next=t,i.lastBaseUpdate=t}function Fr(e,t,i,n){var o=e.updateQueue;Dr=!1;var r=o.firstBaseUpdate,a=o.lastBaseUpdate,s=o.shared.pending;if(null!==s){o.shared.pending=null;var l=s,c=l.next;l.next=null,null===a?r=c:a.next=c,a=l;var d=e.alternate;null!==d&&(s=(d=d.updateQueue).lastBaseUpdate)!==a&&(null===s?d.firstBaseUpdate=c:s.next=c,d.lastBaseUpdate=l)}if(null!==r){var u=o.baseState;for(a=0,d=c=l=null,s=r;;){var h=s.lane,p=s.eventTime;if((n&h)===h){null!==d&&(d=d.next={eventTime:p,lane:0,tag:s.tag,payload:s.payload,callback:s.callback,next:null});e:{var g=e,f=s;switch(h=t,p=i,f.tag){case 1:if("function"==typeof(g=f.payload)){u=g.call(p,u,h);break e}u=g;break e;case 3:g.flags=-65537&g.flags|128;case 0:if(null==(h="function"==typeof(g=f.payload)?g.call(p,u,h):g))break e;u=B({},u,h);break e;case 2:Dr=!0}}null!==s.callback&&0!==s.lane&&(e.flags|=64,null===(h=o.effects)?o.effects=[s]:h.push(s))}else p={eventTime:p,lane:h,tag:s.tag,payload:s.payload,callback:s.callback,next:null},null===d?(c=d=p,l=u):d=d.next=p,a|=h;if(null===(s=s.next)){if(null===(s=o.shared.pending))break;s=(h=s).next,h.next=null,o.lastBaseUpdate=h,o.shared.pending=null}}if(null===d&&(l=u),o.baseState=l,o.firstBaseUpdate=c,o.lastBaseUpdate=d,null!==(t=o.shared.interleaved)){o=t;do{a|=o.lane,o=o.next}while(o!==t)}else null===r&&(o.shared.lanes=0);Ll|=a,e.lanes=a,e.memoizedState=u}}function Ur(e,t,i){if(e=t.effects,t.effects=null,null!==e)for(t=0;t<e.length;t++){var n=e[t],o=n.callback;if(null!==o){if(n.callback=null,n=i,"function"!=typeof o)throw Error(r(191,o));o.call(n)}}}var Hr=(new n.Component).refs;function $r(e,t,i,n){i=null==(i=i(n,t=e.memoizedState))?t:B({},t,i),e.memoizedState=i,0===e.lanes&&(e.updateQueue.baseState=i)}var Zr={isMounted:function(e){return!!(e=e._reactInternals)&&Ze(e)===e},enqueueSetState:function(e,t,i){e=e._reactInternals;var n=ec(),o=tc(e),r=Rr(n,o);r.payload=t,null!=i&&(r.callback=i),null!==(t=Mr(e,r,o))&&(ic(t,e,o,n),Lr(t,e,o))},enqueueReplaceState:function(e,t,i){e=e._reactInternals;var n=ec(),o=tc(e),r=Rr(n,o);r.tag=1,r.payload=t,null!=i&&(r.callback=i),null!==(t=Mr(e,r,o))&&(ic(t,e,o,n),Lr(t,e,o))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var i=ec(),n=tc(e),o=Rr(i,n);o.tag=2,null!=t&&(o.callback=t),null!==(t=Mr(e,o,n))&&(ic(t,e,n,i),Lr(t,e,n))}};function Vr(e,t,i,n,o,r,a){return"function"==typeof(e=e.stateNode).shouldComponentUpdate?e.shouldComponentUpdate(n,r,a):!(t.prototype&&t.prototype.isPureReactComponent&&ln(i,n)&&ln(o,r))}function Gr(e,t,i){var n=!1,o=Eo,r=t.contextType;return"object"==typeof r&&null!==r?r=Pr(r):(o=No(t)?Do:ko.current,r=(n=null!=(n=t.contextTypes))?_o(e,o):Eo),t=new t(i,r),e.memoizedState=null!==t.state&&void 0!==t.state?t.state:null,t.updater=Zr,e.stateNode=t,t._reactInternals=e,n&&((e=e.stateNode).__reactInternalMemoizedUnmaskedChildContext=o,e.__reactInternalMemoizedMaskedChildContext=r),t}function jr(e,t,i,n){e=t.state,"function"==typeof t.componentWillReceiveProps&&t.componentWillReceiveProps(i,n),"function"==typeof t.UNSAFE_componentWillReceiveProps&&t.UNSAFE_componentWillReceiveProps(i,n),t.state!==e&&Zr.enqueueReplaceState(t,t.state,null)}function zr(e,t,i,n){var o=e.stateNode;o.props=i,o.state=e.memoizedState,o.refs=Hr,_r(e);var r=t.contextType;"object"==typeof r&&null!==r?o.context=Pr(r):(r=No(t)?Do:ko.current,o.context=_o(e,r)),o.state=e.memoizedState,"function"==typeof(r=t.getDerivedStateFromProps)&&($r(e,t,r,i),o.state=e.memoizedState),"function"==typeof t.getDerivedStateFromProps||"function"==typeof o.getSnapshotBeforeUpdate||"function"!=typeof o.UNSAFE_componentWillMount&&"function"!=typeof o.componentWillMount||(t=o.state,"function"==typeof o.componentWillMount&&o.componentWillMount(),"function"==typeof o.UNSAFE_componentWillMount&&o.UNSAFE_componentWillMount(),t!==o.state&&Zr.enqueueReplaceState(o,o.state,null),Fr(e,i,o,n),o.state=e.memoizedState),"function"==typeof o.componentDidMount&&(e.flags|=4194308)}function Wr(e,t,i){if(null!==(e=i.ref)&&"function"!=typeof e&&"object"!=typeof e){if(i._owner){if(i=i._owner){if(1!==i.tag)throw Error(r(309));var n=i.stateNode}if(!n)throw Error(r(147,e));var o=n,a=""+e;return null!==t&&null!==t.ref&&"function"==typeof t.ref&&t.ref._stringRef===a?t.ref:(t=function(e){var t=o.refs;t===Hr&&(t=o.refs={}),null===e?delete t[a]:t[a]=e},t._stringRef=a,t)}if("string"!=typeof e)throw Error(r(284));if(!i._owner)throw Error(r(290,e))}return e}function Kr(e,t){throw e=Object.prototype.toString.call(t),Error(r(31,"[object Object]"===e?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function qr(e){return(0,e._init)(e._payload)}function Yr(e){function t(t,i){if(e){var n=t.deletions;null===n?(t.deletions=[i],t.flags|=16):n.push(i)}}function i(i,n){if(!e)return null;for(;null!==n;)t(i,n),n=n.sibling;return null}function n(e,t){for(e=new Map;null!==t;)null!==t.key?e.set(t.key,t):e.set(t.index,t),t=t.sibling;return e}function o(e,t){return(e=Nc(e,t)).index=0,e.sibling=null,e}function a(t,i,n){return t.index=n,e?null!==(n=t.alternate)?(n=n.index)<i?(t.flags|=2,i):n:(t.flags|=2,i):(t.flags|=1048576,i)}function s(t){return e&&null===t.alternate&&(t.flags|=2),t}function l(e,t,i,n){return null===t||6!==t.tag?((t=Bc(i,e.mode,n)).return=e,t):((t=o(t,i)).return=e,t)}function c(e,t,i,n){var r=i.type;return r===T?u(e,t,i.props.children,n,i.key):null!==t&&(t.elementType===r||"object"==typeof r&&null!==r&&r.$$typeof===_&&qr(r)===t.type)?((n=o(t,i.props)).ref=Wr(e,t,i),n.return=e,n):((n=Rc(i.type,i.key,i.props,null,e.mode,n)).ref=Wr(e,t,i),n.return=e,n)}function d(e,t,i,n){return null===t||4!==t.tag||t.stateNode.containerInfo!==i.containerInfo||t.stateNode.implementation!==i.implementation?((t=Fc(i,e.mode,n)).return=e,t):((t=o(t,i.children||[])).return=e,t)}function u(e,t,i,n,r){return null===t||7!==t.tag?((t=Mc(i,e.mode,n,r)).return=e,t):((t=o(t,i)).return=e,t)}function h(e,t,i){if("string"==typeof t&&""!==t||"number"==typeof t)return(t=Bc(""+t,e.mode,i)).return=e,t;if("object"==typeof t&&null!==t){switch(t.$$typeof){case S:return(i=Rc(t.type,t.key,t.props,null,e.mode,i)).ref=Wr(e,null,t),i.return=e,i;case x:return(t=Fc(t,e.mode,i)).return=e,t;case _:return h(e,(0,t._init)(t._payload),i)}if(te(t)||M(t))return(t=Mc(t,e.mode,i,null)).return=e,t;Kr(e,t)}return null}function p(e,t,i,n){var o=null!==t?t.key:null;if("string"==typeof i&&""!==i||"number"==typeof i)return null!==o?null:l(e,t,""+i,n);if("object"==typeof i&&null!==i){switch(i.$$typeof){case S:return i.key===o?c(e,t,i,n):null;case x:return i.key===o?d(e,t,i,n):null;case _:return p(e,t,(o=i._init)(i._payload),n)}if(te(i)||M(i))return null!==o?null:u(e,t,i,n,null);Kr(e,i)}return null}function g(e,t,i,n,o){if("string"==typeof n&&""!==n||"number"==typeof n)return l(t,e=e.get(i)||null,""+n,o);if("object"==typeof n&&null!==n){switch(n.$$typeof){case S:return c(t,e=e.get(null===n.key?i:n.key)||null,n,o);case x:return d(t,e=e.get(null===n.key?i:n.key)||null,n,o);case _:return g(e,t,i,(0,n._init)(n._payload),o)}if(te(n)||M(n))return u(t,e=e.get(i)||null,n,o,null);Kr(t,n)}return null}function f(o,r,s,l){for(var c=null,d=null,u=r,f=r=0,m=null;null!==u&&f<s.length;f++){u.index>f?(m=u,u=null):m=u.sibling;var v=p(o,u,s[f],l);if(null===v){null===u&&(u=m);break}e&&u&&null===v.alternate&&t(o,u),r=a(v,r,f),null===d?c=v:d.sibling=v,d=v,u=m}if(f===s.length)return i(o,u),rr&&Qo(o,f),c;if(null===u){for(;f<s.length;f++)null!==(u=h(o,s[f],l))&&(r=a(u,r,f),null===d?c=u:d.sibling=u,d=u);return rr&&Qo(o,f),c}for(u=n(o,u);f<s.length;f++)null!==(m=g(u,o,f,s[f],l))&&(e&&null!==m.alternate&&u.delete(null===m.key?f:m.key),r=a(m,r,f),null===d?c=m:d.sibling=m,d=m);return e&&u.forEach((function(e){return t(o,e)})),rr&&Qo(o,f),c}function m(o,s,l,c){var d=M(l);if("function"!=typeof d)throw Error(r(150));if(null==(l=d.call(l)))throw Error(r(151));for(var u=d=null,f=s,m=s=0,v=null,y=l.next();null!==f&&!y.done;m++,y=l.next()){f.index>m?(v=f,f=null):v=f.sibling;var C=p(o,f,y.value,c);if(null===C){null===f&&(f=v);break}e&&f&&null===C.alternate&&t(o,f),s=a(C,s,m),null===u?d=C:u.sibling=C,u=C,f=v}if(y.done)return i(o,f),rr&&Qo(o,m),d;if(null===f){for(;!y.done;m++,y=l.next())null!==(y=h(o,y.value,c))&&(s=a(y,s,m),null===u?d=y:u.sibling=y,u=y);return rr&&Qo(o,m),d}for(f=n(o,f);!y.done;m++,y=l.next())null!==(y=g(f,o,m,y.value,c))&&(e&&null!==y.alternate&&f.delete(null===y.key?m:y.key),s=a(y,s,m),null===u?d=y:u.sibling=y,u=y);return e&&f.forEach((function(e){return t(o,e)})),rr&&Qo(o,m),d}return function e(n,r,a,l){if("object"==typeof a&&null!==a&&a.type===T&&null===a.key&&(a=a.props.children),"object"==typeof a&&null!==a){switch(a.$$typeof){case S:e:{for(var c=a.key,d=r;null!==d;){if(d.key===c){if((c=a.type)===T){if(7===d.tag){i(n,d.sibling),(r=o(d,a.props.children)).return=n,n=r;break e}}else if(d.elementType===c||"object"==typeof c&&null!==c&&c.$$typeof===_&&qr(c)===d.type){i(n,d.sibling),(r=o(d,a.props)).ref=Wr(n,d,a),r.return=n,n=r;break e}i(n,d);break}t(n,d),d=d.sibling}a.type===T?((r=Mc(a.props.children,n.mode,l,a.key)).return=n,n=r):((l=Rc(a.type,a.key,a.props,null,n.mode,l)).ref=Wr(n,r,a),l.return=n,n=l)}return s(n);case x:e:{for(d=a.key;null!==r;){if(r.key===d){if(4===r.tag&&r.stateNode.containerInfo===a.containerInfo&&r.stateNode.implementation===a.implementation){i(n,r.sibling),(r=o(r,a.children||[])).return=n,n=r;break e}i(n,r);break}t(n,r),r=r.sibling}(r=Fc(a,n.mode,l)).return=n,n=r}return s(n);case _:return e(n,r,(d=a._init)(a._payload),l)}if(te(a))return f(n,r,a,l);if(M(a))return m(n,r,a,l);Kr(n,a)}return"string"==typeof a&&""!==a||"number"==typeof a?(a=""+a,null!==r&&6===r.tag?(i(n,r.sibling),(r=o(r,a)).return=n,n=r):(i(n,r),(r=Bc(a,n.mode,l)).return=n,n=r),s(n)):i(n,r)}}var Xr=Yr(!0),Jr=Yr(!1),Qr={},ea=Oo(Qr),ta=Oo(Qr),ia=Oo(Qr);function na(e){if(e===Qr)throw Error(r(174));return e}function oa(e,t){switch(Ao(ia,t),Ao(ta,e),Ao(ea,Qr),e=t.nodeType){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:le(null,"");break;default:t=le(t=(e=8===e?t.parentNode:t).namespaceURI||null,e=e.tagName)}Po(ea),Ao(ea,t)}function ra(){Po(ea),Po(ta),Po(ia)}function aa(e){na(ia.current);var t=na(ea.current),i=le(t,e.type);t!==i&&(Ao(ta,e),Ao(ea,i))}function sa(e){ta.current===e&&(Po(ea),Po(ta))}var la=Oo(0);function ca(e){for(var t=e;null!==t;){if(13===t.tag){var i=t.memoizedState;if(null!==i&&(null===(i=i.dehydrated)||"$?"===i.data||"$!"===i.data))return t}else if(19===t.tag&&void 0!==t.memoizedProps.revealOrder){if(0!=(128&t.flags))return t}else if(null!==t.child){t.child.return=t,t=t.child;continue}if(t===e)break;for(;null===t.sibling;){if(null===t.return||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var da=[];function ua(){for(var e=0;e<da.length;e++)da[e]._workInProgressVersionPrimary=null;da.length=0}var ha=b.ReactCurrentDispatcher,pa=b.ReactCurrentBatchConfig,ga=0,fa=null,ma=null,va=null,ya=!1,Ca=!1,ba=0,Sa=0;function xa(){throw Error(r(321))}function Ta(e,t){if(null===t)return!1;for(var i=0;i<t.length&&i<e.length;i++)if(!sn(e[i],t[i]))return!1;return!0}function wa(e,t,i,n,o,a){if(ga=a,fa=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,ha.current=null===e||null===e.memoizedState?ss:ls,e=i(n,o),Ca){a=0;do{if(Ca=!1,ba=0,25<=a)throw Error(r(301));a+=1,va=ma=null,t.updateQueue=null,ha.current=cs,e=i(n,o)}while(Ca)}if(ha.current=as,t=null!==ma&&null!==ma.next,ga=0,va=ma=fa=null,ya=!1,t)throw Error(r(300));return e}function Oa(){var e=0!==ba;return ba=0,e}function Pa(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return null===va?fa.memoizedState=va=e:va=va.next=e,va}function Aa(){if(null===ma){var e=fa.alternate;e=null!==e?e.memoizedState:null}else e=ma.next;var t=null===va?fa.memoizedState:va.next;if(null!==t)va=t,ma=e;else{if(null===e)throw Error(r(310));e={memoizedState:(ma=e).memoizedState,baseState:ma.baseState,baseQueue:ma.baseQueue,queue:ma.queue,next:null},null===va?fa.memoizedState=va=e:va=va.next=e}return va}function Ea(e,t){return"function"==typeof t?t(e):t}function ka(e){var t=Aa(),i=t.queue;if(null===i)throw Error(r(311));i.lastRenderedReducer=e;var n=ma,o=n.baseQueue,a=i.pending;if(null!==a){if(null!==o){var s=o.next;o.next=a.next,a.next=s}n.baseQueue=o=a,i.pending=null}if(null!==o){a=o.next,n=n.baseState;var l=s=null,c=null,d=a;do{var u=d.lane;if((ga&u)===u)null!==c&&(c=c.next={lane:0,action:d.action,hasEagerState:d.hasEagerState,eagerState:d.eagerState,next:null}),n=d.hasEagerState?d.eagerState:e(n,d.action);else{var h={lane:u,action:d.action,hasEagerState:d.hasEagerState,eagerState:d.eagerState,next:null};null===c?(l=c=h,s=n):c=c.next=h,fa.lanes|=u,Ll|=u}d=d.next}while(null!==d&&d!==a);null===c?s=n:c.next=l,sn(n,t.memoizedState)||(Cs=!0),t.memoizedState=n,t.baseState=s,t.baseQueue=c,i.lastRenderedState=n}if(null!==(e=i.interleaved)){o=e;do{a=o.lane,fa.lanes|=a,Ll|=a,o=o.next}while(o!==e)}else null===o&&(i.lanes=0);return[t.memoizedState,i.dispatch]}function Ia(e){var t=Aa(),i=t.queue;if(null===i)throw Error(r(311));i.lastRenderedReducer=e;var n=i.dispatch,o=i.pending,a=t.memoizedState;if(null!==o){i.pending=null;var s=o=o.next;do{a=e(a,s.action),s=s.next}while(s!==o);sn(a,t.memoizedState)||(Cs=!0),t.memoizedState=a,null===t.baseQueue&&(t.baseState=a),i.lastRenderedState=a}return[a,n]}function Da(){}function _a(e,t){var i=fa,n=Aa(),o=t(),a=!sn(n.memoizedState,o);if(a&&(n.memoizedState=o,Cs=!0),n=n.queue,Ga(Ma.bind(null,i,n,e),[e]),n.getSnapshot!==t||a||null!==va&&1&va.memoizedState.tag){if(i.flags|=2048,Ua(9,Ra.bind(null,i,n,o,t),void 0,null),null===kl)throw Error(r(349));0!=(30&ga)||Na(i,t,o)}return o}function Na(e,t,i){e.flags|=16384,e={getSnapshot:t,value:i},null===(t=fa.updateQueue)?(t={lastEffect:null,stores:null},fa.updateQueue=t,t.stores=[e]):null===(i=t.stores)?t.stores=[e]:i.push(e)}function Ra(e,t,i,n){t.value=i,t.getSnapshot=n,La(t)&&Ba(e)}function Ma(e,t,i){return i((function(){La(t)&&Ba(e)}))}function La(e){var t=e.getSnapshot;e=e.value;try{var i=t();return!sn(e,i)}catch(e){return!0}}function Ba(e){var t=Ir(e,1);null!==t&&ic(t,e,1,-1)}function Fa(e){var t=Pa();return"function"==typeof e&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:Ea,lastRenderedState:e},t.queue=e,e=e.dispatch=is.bind(null,fa,e),[t.memoizedState,e]}function Ua(e,t,i,n){return e={tag:e,create:t,destroy:i,deps:n,next:null},null===(t=fa.updateQueue)?(t={lastEffect:null,stores:null},fa.updateQueue=t,t.lastEffect=e.next=e):null===(i=t.lastEffect)?t.lastEffect=e.next=e:(n=i.next,i.next=e,e.next=n,t.lastEffect=e),e}function Ha(){return Aa().memoizedState}function $a(e,t,i,n){var o=Pa();fa.flags|=e,o.memoizedState=Ua(1|t,i,void 0,void 0===n?null:n)}function Za(e,t,i,n){var o=Aa();n=void 0===n?null:n;var r=void 0;if(null!==ma){var a=ma.memoizedState;if(r=a.destroy,null!==n&&Ta(n,a.deps))return void(o.memoizedState=Ua(t,i,r,n))}fa.flags|=e,o.memoizedState=Ua(1|t,i,r,n)}function Va(e,t){return $a(8390656,8,e,t)}function Ga(e,t){return Za(2048,8,e,t)}function ja(e,t){return Za(4,2,e,t)}function za(e,t){return Za(4,4,e,t)}function Wa(e,t){return"function"==typeof t?(e=e(),t(e),function(){t(null)}):null!=t?(e=e(),t.current=e,function(){t.current=null}):void 0}function Ka(e,t,i){return i=null!=i?i.concat([e]):null,Za(4,4,Wa.bind(null,t,e),i)}function qa(){}function Ya(e,t){var i=Aa();t=void 0===t?null:t;var n=i.memoizedState;return null!==n&&null!==t&&Ta(t,n[1])?n[0]:(i.memoizedState=[e,t],e)}function Xa(e,t){var i=Aa();t=void 0===t?null:t;var n=i.memoizedState;return null!==n&&null!==t&&Ta(t,n[1])?n[0]:(e=e(),i.memoizedState=[e,t],e)}function Ja(e,t,i){return 0==(21&ga)?(e.baseState&&(e.baseState=!1,Cs=!0),e.memoizedState=i):(sn(i,t)||(i=ft(),fa.lanes|=i,Ll|=i,e.baseState=!0),t)}function Qa(e,t){var i=Ct;Ct=0!==i&&4>i?i:4,e(!0);var n=pa.transition;pa.transition={};try{e(!1),t()}finally{Ct=i,pa.transition=n}}function es(){return Aa().memoizedState}function ts(e,t,i){var n=tc(e);i={lane:n,action:i,hasEagerState:!1,eagerState:null,next:null},ns(e)?os(t,i):null!==(i=kr(e,t,i,n))&&(ic(i,e,n,ec()),rs(i,t,n))}function is(e,t,i){var n=tc(e),o={lane:n,action:i,hasEagerState:!1,eagerState:null,next:null};if(ns(e))os(t,o);else{var r=e.alternate;if(0===e.lanes&&(null===r||0===r.lanes)&&null!==(r=t.lastRenderedReducer))try{var a=t.lastRenderedState,s=r(a,i);if(o.hasEagerState=!0,o.eagerState=s,sn(s,a)){var l=t.interleaved;return null===l?(o.next=o,Er(t)):(o.next=l.next,l.next=o),void(t.interleaved=o)}}catch(e){}null!==(i=kr(e,t,o,n))&&(ic(i,e,n,o=ec()),rs(i,t,n))}}function ns(e){var t=e.alternate;return e===fa||null!==t&&t===fa}function os(e,t){Ca=ya=!0;var i=e.pending;null===i?t.next=t:(t.next=i.next,i.next=t),e.pending=t}function rs(e,t,i){if(0!=(4194240&i)){var n=t.lanes;i|=n&=e.pendingLanes,t.lanes=i,yt(e,i)}}var as={readContext:Pr,useCallback:xa,useContext:xa,useEffect:xa,useImperativeHandle:xa,useInsertionEffect:xa,useLayoutEffect:xa,useMemo:xa,useReducer:xa,useRef:xa,useState:xa,useDebugValue:xa,useDeferredValue:xa,useTransition:xa,useMutableSource:xa,useSyncExternalStore:xa,useId:xa,unstable_isNewReconciler:!1},ss={readContext:Pr,useCallback:function(e,t){return Pa().memoizedState=[e,void 0===t?null:t],e},useContext:Pr,useEffect:Va,useImperativeHandle:function(e,t,i){return i=null!=i?i.concat([e]):null,$a(4194308,4,Wa.bind(null,t,e),i)},useLayoutEffect:function(e,t){return $a(4194308,4,e,t)},useInsertionEffect:function(e,t){return $a(4,2,e,t)},useMemo:function(e,t){var i=Pa();return t=void 0===t?null:t,e=e(),i.memoizedState=[e,t],e},useReducer:function(e,t,i){var n=Pa();return t=void 0!==i?i(t):t,n.memoizedState=n.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},n.queue=e,e=e.dispatch=ts.bind(null,fa,e),[n.memoizedState,e]},useRef:function(e){return e={current:e},Pa().memoizedState=e},useState:Fa,useDebugValue:qa,useDeferredValue:function(e){return Pa().memoizedState=e},useTransition:function(){var e=Fa(!1),t=e[0];return e=Qa.bind(null,e[1]),Pa().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,i){var n=fa,o=Pa();if(rr){if(void 0===i)throw Error(r(407));i=i()}else{if(i=t(),null===kl)throw Error(r(349));0!=(30&ga)||Na(n,t,i)}o.memoizedState=i;var a={value:i,getSnapshot:t};return o.queue=a,Va(Ma.bind(null,n,a,e),[e]),n.flags|=2048,Ua(9,Ra.bind(null,n,a,i,t),void 0,null),i},useId:function(){var e=Pa(),t=kl.identifierPrefix;if(rr){var i=Jo;t=":"+t+"R"+(i=(Xo&~(1<<32-at(Xo)-1)).toString(32)+i),0<(i=ba++)&&(t+="H"+i.toString(32)),t+=":"}else t=":"+t+"r"+(i=Sa++).toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},ls={readContext:Pr,useCallback:Ya,useContext:Pr,useEffect:Ga,useImperativeHandle:Ka,useInsertionEffect:ja,useLayoutEffect:za,useMemo:Xa,useReducer:ka,useRef:Ha,useState:function(){return ka(Ea)},useDebugValue:qa,useDeferredValue:function(e){return Ja(Aa(),ma.memoizedState,e)},useTransition:function(){return[ka(Ea)[0],Aa().memoizedState]},useMutableSource:Da,useSyncExternalStore:_a,useId:es,unstable_isNewReconciler:!1},cs={readContext:Pr,useCallback:Ya,useContext:Pr,useEffect:Ga,useImperativeHandle:Ka,useInsertionEffect:ja,useLayoutEffect:za,useMemo:Xa,useReducer:Ia,useRef:Ha,useState:function(){return Ia(Ea)},useDebugValue:qa,useDeferredValue:function(e){var t=Aa();return null===ma?t.memoizedState=e:Ja(t,ma.memoizedState,e)},useTransition:function(){return[Ia(Ea)[0],Aa().memoizedState]},useMutableSource:Da,useSyncExternalStore:_a,useId:es,unstable_isNewReconciler:!1};function ds(e,t){try{var i="",n=t;do{i+=$(n),n=n.return}while(n);var o=i}catch(e){o="\nError generating stack: "+e.message+"\n"+e.stack}return{value:e,source:t,stack:o,digest:null}}function us(e,t,i){return{value:e,source:null,stack:null!=i?i:null,digest:null!=t?t:null}}var hs="function"==typeof WeakMap?WeakMap:Map;function ps(e,t,i){(i=Rr(-1,i)).tag=3,i.payload={element:null};var n=t.value;return i.callback=function(){Gl||(Gl=!0,jl=n)},i}function gs(e,t,i){(i=Rr(-1,i)).tag=3;var n=e.type.getDerivedStateFromError;if("function"==typeof n){var o=t.value;i.payload=function(){return n(o)},i.callback=function(){}}var r=e.stateNode;return null!==r&&"function"==typeof r.componentDidCatch&&(i.callback=function(){"function"!=typeof n&&(null===zl?zl=new Set([this]):zl.add(this));var e=t.stack;this.componentDidCatch(t.value,{componentStack:null!==e?e:""})}),i}function fs(e,t,i){var n=e.pingCache;if(null===n){n=e.pingCache=new hs;var o=new Set;n.set(t,o)}else void 0===(o=n.get(t))&&(o=new Set,n.set(t,o));o.has(i)||(o.add(i),e=Oc.bind(null,e,t,i),t.then(e,e))}function ms(e){do{var t;if((t=13===e.tag)&&(t=null===(t=e.memoizedState)||null!==t.dehydrated),t)return e;e=e.return}while(null!==e);return null}function vs(e,t,i,n,o){return 0==(1&e.mode)?(e===t?e.flags|=65536:(e.flags|=128,i.flags|=131072,i.flags&=-52805,1===i.tag&&(null===i.alternate?i.tag=17:((t=Rr(-1,1)).tag=2,Mr(i,t,1))),i.lanes|=1),e):(e.flags|=65536,e.lanes=o,e)}var ys=b.ReactCurrentOwner,Cs=!1;function bs(e,t,i,n){t.child=null===e?Jr(t,null,i,n):Xr(t,e.child,i,n)}function Ss(e,t,i,n,o){i=i.render;var r=t.ref;return Or(t,o),n=wa(e,t,i,n,r,o),i=Oa(),null===e||Cs?(rr&&i&&tr(t),t.flags|=1,bs(e,t,n,o),t.child):(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~o,Gs(e,t,o))}function xs(e,t,i,n,o){if(null===e){var r=i.type;return"function"!=typeof r||_c(r)||void 0!==r.defaultProps||null!==i.compare||void 0!==i.defaultProps?((e=Rc(i.type,null,n,t,t.mode,o)).ref=t.ref,e.return=t,t.child=e):(t.tag=15,t.type=r,Ts(e,t,r,n,o))}if(r=e.child,0==(e.lanes&o)){var a=r.memoizedProps;if((i=null!==(i=i.compare)?i:ln)(a,n)&&e.ref===t.ref)return Gs(e,t,o)}return t.flags|=1,(e=Nc(r,n)).ref=t.ref,e.return=t,t.child=e}function Ts(e,t,i,n,o){if(null!==e){var r=e.memoizedProps;if(ln(r,n)&&e.ref===t.ref){if(Cs=!1,t.pendingProps=n=r,0==(e.lanes&o))return t.lanes=e.lanes,Gs(e,t,o);0!=(131072&e.flags)&&(Cs=!0)}}return Ps(e,t,i,n,o)}function ws(e,t,i){var n=t.pendingProps,o=n.children,r=null!==e?e.memoizedState:null;if("hidden"===n.mode)if(0==(1&t.mode))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},Ao(Nl,_l),_l|=i;else{if(0==(1073741824&i))return e=null!==r?r.baseLanes|i:i,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,Ao(Nl,_l),_l|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},n=null!==r?r.baseLanes:i,Ao(Nl,_l),_l|=n}else null!==r?(n=r.baseLanes|i,t.memoizedState=null):n=i,Ao(Nl,_l),_l|=n;return bs(e,t,o,i),t.child}function Os(e,t){var i=t.ref;(null===e&&null!==i||null!==e&&e.ref!==i)&&(t.flags|=512,t.flags|=2097152)}function Ps(e,t,i,n,o){var r=No(i)?Do:ko.current;return r=_o(t,r),Or(t,o),i=wa(e,t,i,n,r,o),n=Oa(),null===e||Cs?(rr&&n&&tr(t),t.flags|=1,bs(e,t,i,o),t.child):(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~o,Gs(e,t,o))}function As(e,t,i,n,o){if(No(i)){var r=!0;Bo(t)}else r=!1;if(Or(t,o),null===t.stateNode)Vs(e,t),Gr(t,i,n),zr(t,i,n,o),n=!0;else if(null===e){var a=t.stateNode,s=t.memoizedProps;a.props=s;var l=a.context,c=i.contextType;c="object"==typeof c&&null!==c?Pr(c):_o(t,c=No(i)?Do:ko.current);var d=i.getDerivedStateFromProps,u="function"==typeof d||"function"==typeof a.getSnapshotBeforeUpdate;u||"function"!=typeof a.UNSAFE_componentWillReceiveProps&&"function"!=typeof a.componentWillReceiveProps||(s!==n||l!==c)&&jr(t,a,n,c),Dr=!1;var h=t.memoizedState;a.state=h,Fr(t,n,a,o),l=t.memoizedState,s!==n||h!==l||Io.current||Dr?("function"==typeof d&&($r(t,i,d,n),l=t.memoizedState),(s=Dr||Vr(t,i,s,n,h,l,c))?(u||"function"!=typeof a.UNSAFE_componentWillMount&&"function"!=typeof a.componentWillMount||("function"==typeof a.componentWillMount&&a.componentWillMount(),"function"==typeof a.UNSAFE_componentWillMount&&a.UNSAFE_componentWillMount()),"function"==typeof a.componentDidMount&&(t.flags|=4194308)):("function"==typeof a.componentDidMount&&(t.flags|=4194308),t.memoizedProps=n,t.memoizedState=l),a.props=n,a.state=l,a.context=c,n=s):("function"==typeof a.componentDidMount&&(t.flags|=4194308),n=!1)}else{a=t.stateNode,Nr(e,t),s=t.memoizedProps,c=t.type===t.elementType?s:vr(t.type,s),a.props=c,u=t.pendingProps,h=a.context,l="object"==typeof(l=i.contextType)&&null!==l?Pr(l):_o(t,l=No(i)?Do:ko.current);var p=i.getDerivedStateFromProps;(d="function"==typeof p||"function"==typeof a.getSnapshotBeforeUpdate)||"function"!=typeof a.UNSAFE_componentWillReceiveProps&&"function"!=typeof a.componentWillReceiveProps||(s!==u||h!==l)&&jr(t,a,n,l),Dr=!1,h=t.memoizedState,a.state=h,Fr(t,n,a,o);var g=t.memoizedState;s!==u||h!==g||Io.current||Dr?("function"==typeof p&&($r(t,i,p,n),g=t.memoizedState),(c=Dr||Vr(t,i,c,n,h,g,l)||!1)?(d||"function"!=typeof a.UNSAFE_componentWillUpdate&&"function"!=typeof a.componentWillUpdate||("function"==typeof a.componentWillUpdate&&a.componentWillUpdate(n,g,l),"function"==typeof a.UNSAFE_componentWillUpdate&&a.UNSAFE_componentWillUpdate(n,g,l)),"function"==typeof a.componentDidUpdate&&(t.flags|=4),"function"==typeof a.getSnapshotBeforeUpdate&&(t.flags|=1024)):("function"!=typeof a.componentDidUpdate||s===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),"function"!=typeof a.getSnapshotBeforeUpdate||s===e.memoizedProps&&h===e.memoizedState||(t.flags|=1024),t.memoizedProps=n,t.memoizedState=g),a.props=n,a.state=g,a.context=l,n=c):("function"!=typeof a.componentDidUpdate||s===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),"function"!=typeof a.getSnapshotBeforeUpdate||s===e.memoizedProps&&h===e.memoizedState||(t.flags|=1024),n=!1)}return Es(e,t,i,n,r,o)}function Es(e,t,i,n,o,r){Os(e,t);var a=0!=(128&t.flags);if(!n&&!a)return o&&Fo(t,i,!1),Gs(e,t,r);n=t.stateNode,ys.current=t;var s=a&&"function"!=typeof i.getDerivedStateFromError?null:n.render();return t.flags|=1,null!==e&&a?(t.child=Xr(t,e.child,null,r),t.child=Xr(t,null,s,r)):bs(e,t,s,r),t.memoizedState=n.state,o&&Fo(t,i,!0),t.child}function ks(e){var t=e.stateNode;t.pendingContext?Mo(0,t.pendingContext,t.pendingContext!==t.context):t.context&&Mo(0,t.context,!1),oa(e,t.containerInfo)}function Is(e,t,i,n,o){return gr(),fr(o),t.flags|=256,bs(e,t,i,n),t.child}var Ds,_s,Ns,Rs,Ms={dehydrated:null,treeContext:null,retryLane:0};function Ls(e){return{baseLanes:e,cachePool:null,transitions:null}}function Bs(e,t,i){var n,o=t.pendingProps,a=la.current,s=!1,l=0!=(128&t.flags);if((n=l)||(n=(null===e||null!==e.memoizedState)&&0!=(2&a)),n?(s=!0,t.flags&=-129):null!==e&&null===e.memoizedState||(a|=1),Ao(la,1&a),null===e)return dr(t),null!==(e=t.memoizedState)&&null!==(e=e.dehydrated)?(0==(1&t.mode)?t.lanes=1:"$!"===e.data?t.lanes=8:t.lanes=1073741824,null):(l=o.children,e=o.fallback,s?(o=t.mode,s=t.child,l={mode:"hidden",children:l},0==(1&o)&&null!==s?(s.childLanes=0,s.pendingProps=l):s=Lc(l,o,0,null),e=Mc(e,o,i,null),s.return=t,e.return=t,s.sibling=e,t.child=s,t.child.memoizedState=Ls(i),t.memoizedState=Ms,e):Fs(t,l));if(null!==(a=e.memoizedState)&&null!==(n=a.dehydrated))return function(e,t,i,n,o,a,s){if(i)return 256&t.flags?(t.flags&=-257,Us(e,t,s,n=us(Error(r(422))))):null!==t.memoizedState?(t.child=e.child,t.flags|=128,null):(a=n.fallback,o=t.mode,n=Lc({mode:"visible",children:n.children},o,0,null),(a=Mc(a,o,s,null)).flags|=2,n.return=t,a.return=t,n.sibling=a,t.child=n,0!=(1&t.mode)&&Xr(t,e.child,null,s),t.child.memoizedState=Ls(s),t.memoizedState=Ms,a);if(0==(1&t.mode))return Us(e,t,s,null);if("$!"===o.data){if(n=o.nextSibling&&o.nextSibling.dataset)var l=n.dgst;return n=l,Us(e,t,s,n=us(a=Error(r(419)),n,void 0))}if(l=0!=(s&e.childLanes),Cs||l){if(null!==(n=kl)){switch(s&-s){case 4:o=2;break;case 16:o=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:o=32;break;case 536870912:o=268435456;break;default:o=0}0!==(o=0!=(o&(n.suspendedLanes|s))?0:o)&&o!==a.retryLane&&(a.retryLane=o,Ir(e,o),ic(n,e,o,-1))}return fc(),Us(e,t,s,n=us(Error(r(421))))}return"$?"===o.data?(t.flags|=128,t.child=e.child,t=Ac.bind(null,e),o._reactRetry=t,null):(e=a.treeContext,or=co(o.nextSibling),nr=t,rr=!0,ar=null,null!==e&&(Ko[qo++]=Xo,Ko[qo++]=Jo,Ko[qo++]=Yo,Xo=e.id,Jo=e.overflow,Yo=t),(t=Fs(t,n.children)).flags|=4096,t)}(e,t,l,o,n,a,i);if(s){s=o.fallback,l=t.mode,n=(a=e.child).sibling;var c={mode:"hidden",children:o.children};return 0==(1&l)&&t.child!==a?((o=t.child).childLanes=0,o.pendingProps=c,t.deletions=null):(o=Nc(a,c)).subtreeFlags=14680064&a.subtreeFlags,null!==n?s=Nc(n,s):(s=Mc(s,l,i,null)).flags|=2,s.return=t,o.return=t,o.sibling=s,t.child=o,o=s,s=t.child,l=null===(l=e.child.memoizedState)?Ls(i):{baseLanes:l.baseLanes|i,cachePool:null,transitions:l.transitions},s.memoizedState=l,s.childLanes=e.childLanes&~i,t.memoizedState=Ms,o}return e=(s=e.child).sibling,o=Nc(s,{mode:"visible",children:o.children}),0==(1&t.mode)&&(o.lanes=i),o.return=t,o.sibling=null,null!==e&&(null===(i=t.deletions)?(t.deletions=[e],t.flags|=16):i.push(e)),t.child=o,t.memoizedState=null,o}function Fs(e,t){return(t=Lc({mode:"visible",children:t},e.mode,0,null)).return=e,e.child=t}function Us(e,t,i,n){return null!==n&&fr(n),Xr(t,e.child,null,i),(e=Fs(t,t.pendingProps.children)).flags|=2,t.memoizedState=null,e}function Hs(e,t,i){e.lanes|=t;var n=e.alternate;null!==n&&(n.lanes|=t),wr(e.return,t,i)}function $s(e,t,i,n,o){var r=e.memoizedState;null===r?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:n,tail:i,tailMode:o}:(r.isBackwards=t,r.rendering=null,r.renderingStartTime=0,r.last=n,r.tail=i,r.tailMode=o)}function Zs(e,t,i){var n=t.pendingProps,o=n.revealOrder,r=n.tail;if(bs(e,t,n.children,i),0!=(2&(n=la.current)))n=1&n|2,t.flags|=128;else{if(null!==e&&0!=(128&e.flags))e:for(e=t.child;null!==e;){if(13===e.tag)null!==e.memoizedState&&Hs(e,i,t);else if(19===e.tag)Hs(e,i,t);else if(null!==e.child){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;null===e.sibling;){if(null===e.return||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}n&=1}if(Ao(la,n),0==(1&t.mode))t.memoizedState=null;else switch(o){case"forwards":for(i=t.child,o=null;null!==i;)null!==(e=i.alternate)&&null===ca(e)&&(o=i),i=i.sibling;null===(i=o)?(o=t.child,t.child=null):(o=i.sibling,i.sibling=null),$s(t,!1,o,i,r);break;case"backwards":for(i=null,o=t.child,t.child=null;null!==o;){if(null!==(e=o.alternate)&&null===ca(e)){t.child=o;break}e=o.sibling,o.sibling=i,i=o,o=e}$s(t,!0,i,null,r);break;case"together":$s(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function Vs(e,t){0==(1&t.mode)&&null!==e&&(e.alternate=null,t.alternate=null,t.flags|=2)}function Gs(e,t,i){if(null!==e&&(t.dependencies=e.dependencies),Ll|=t.lanes,0==(i&t.childLanes))return null;if(null!==e&&t.child!==e.child)throw Error(r(153));if(null!==t.child){for(i=Nc(e=t.child,e.pendingProps),t.child=i,i.return=t;null!==e.sibling;)e=e.sibling,(i=i.sibling=Nc(e,e.pendingProps)).return=t;i.sibling=null}return t.child}function js(e,t){if(!rr)switch(e.tailMode){case"hidden":t=e.tail;for(var i=null;null!==t;)null!==t.alternate&&(i=t),t=t.sibling;null===i?e.tail=null:i.sibling=null;break;case"collapsed":i=e.tail;for(var n=null;null!==i;)null!==i.alternate&&(n=i),i=i.sibling;null===n?t||null===e.tail?e.tail=null:e.tail.sibling=null:n.sibling=null}}function zs(e){var t=null!==e.alternate&&e.alternate.child===e.child,i=0,n=0;if(t)for(var o=e.child;null!==o;)i|=o.lanes|o.childLanes,n|=14680064&o.subtreeFlags,n|=14680064&o.flags,o.return=e,o=o.sibling;else for(o=e.child;null!==o;)i|=o.lanes|o.childLanes,n|=o.subtreeFlags,n|=o.flags,o.return=e,o=o.sibling;return e.subtreeFlags|=n,e.childLanes=i,t}function Ws(e,t,i){var n=t.pendingProps;switch(ir(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return zs(t),null;case 1:case 17:return No(t.type)&&Ro(),zs(t),null;case 3:return n=t.stateNode,ra(),Po(Io),Po(ko),ua(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),null!==e&&null!==e.child||(hr(t)?t.flags|=4:null===e||e.memoizedState.isDehydrated&&0==(256&t.flags)||(t.flags|=1024,null!==ar&&(ac(ar),ar=null))),_s(e,t),zs(t),null;case 5:sa(t);var o=na(ia.current);if(i=t.type,null!==e&&null!=t.stateNode)Ns(e,t,i,n,o),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!n){if(null===t.stateNode)throw Error(r(166));return zs(t),null}if(e=na(ea.current),hr(t)){n=t.stateNode,i=t.type;var a=t.memoizedProps;switch(n[po]=t,n[go]=a,e=0!=(1&t.mode),i){case"dialog":Un("cancel",n),Un("close",n);break;case"iframe":case"object":case"embed":Un("load",n);break;case"video":case"audio":for(o=0;o<Mn.length;o++)Un(Mn[o],n);break;case"source":Un("error",n);break;case"img":case"image":case"link":Un("error",n),Un("load",n);break;case"details":Un("toggle",n);break;case"input":Y(n,a),Un("invalid",n);break;case"select":n._wrapperState={wasMultiple:!!a.multiple},Un("invalid",n);break;case"textarea":oe(n,a),Un("invalid",n)}for(var l in ye(i,a),o=null,a)if(a.hasOwnProperty(l)){var c=a[l];"children"===l?"string"==typeof c?n.textContent!==c&&(!0!==a.suppressHydrationWarning&&Jn(n.textContent,c,e),o=["children",c]):"number"==typeof c&&n.textContent!==""+c&&(!0!==a.suppressHydrationWarning&&Jn(n.textContent,c,e),o=["children",""+c]):s.hasOwnProperty(l)&&null!=c&&"onScroll"===l&&Un("scroll",n)}switch(i){case"input":z(n),Q(n,a,!0);break;case"textarea":z(n),ae(n);break;case"select":case"option":break;default:"function"==typeof a.onClick&&(n.onclick=Qn)}n=o,t.updateQueue=n,null!==n&&(t.flags|=4)}else{l=9===o.nodeType?o:o.ownerDocument,"http://www.w3.org/1999/xhtml"===e&&(e=se(i)),"http://www.w3.org/1999/xhtml"===e?"script"===i?((e=l.createElement("div")).innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):"string"==typeof n.is?e=l.createElement(i,{is:n.is}):(e=l.createElement(i),"select"===i&&(l=e,n.multiple?l.multiple=!0:n.size&&(l.size=n.size))):e=l.createElementNS(e,i),e[po]=t,e[go]=n,Ds(e,t,!1,!1),t.stateNode=e;e:{switch(l=Ce(i,n),i){case"dialog":Un("cancel",e),Un("close",e),o=n;break;case"iframe":case"object":case"embed":Un("load",e),o=n;break;case"video":case"audio":for(o=0;o<Mn.length;o++)Un(Mn[o],e);o=n;break;case"source":Un("error",e),o=n;break;case"img":case"image":case"link":Un("error",e),Un("load",e),o=n;break;case"details":Un("toggle",e),o=n;break;case"input":Y(e,n),o=q(e,n),Un("invalid",e);break;case"option":default:o=n;break;case"select":e._wrapperState={wasMultiple:!!n.multiple},o=B({},n,{value:void 0}),Un("invalid",e);break;case"textarea":oe(e,n),o=ne(e,n),Un("invalid",e)}for(a in ye(i,o),c=o)if(c.hasOwnProperty(a)){var d=c[a];"style"===a?me(e,d):"dangerouslySetInnerHTML"===a?null!=(d=d?d.__html:void 0)&&ue(e,d):"children"===a?"string"==typeof d?("textarea"!==i||""!==d)&&he(e,d):"number"==typeof d&&he(e,""+d):"suppressContentEditableWarning"!==a&&"suppressHydrationWarning"!==a&&"autoFocus"!==a&&(s.hasOwnProperty(a)?null!=d&&"onScroll"===a&&Un("scroll",e):null!=d&&C(e,a,d,l))}switch(i){case"input":z(e),Q(e,n,!1);break;case"textarea":z(e),ae(e);break;case"option":null!=n.value&&e.setAttribute("value",""+G(n.value));break;case"select":e.multiple=!!n.multiple,null!=(a=n.value)?ie(e,!!n.multiple,a,!1):null!=n.defaultValue&&ie(e,!!n.multiple,n.defaultValue,!0);break;default:"function"==typeof o.onClick&&(e.onclick=Qn)}switch(i){case"button":case"input":case"select":case"textarea":n=!!n.autoFocus;break e;case"img":n=!0;break e;default:n=!1}}n&&(t.flags|=4)}null!==t.ref&&(t.flags|=512,t.flags|=2097152)}return zs(t),null;case 6:if(e&&null!=t.stateNode)Rs(e,t,e.memoizedProps,n);else{if("string"!=typeof n&&null===t.stateNode)throw Error(r(166));if(i=na(ia.current),na(ea.current),hr(t)){if(n=t.stateNode,i=t.memoizedProps,n[po]=t,(a=n.nodeValue!==i)&&null!==(e=nr))switch(e.tag){case 3:Jn(n.nodeValue,i,0!=(1&e.mode));break;case 5:!0!==e.memoizedProps.suppressHydrationWarning&&Jn(n.nodeValue,i,0!=(1&e.mode))}a&&(t.flags|=4)}else(n=(9===i.nodeType?i:i.ownerDocument).createTextNode(n))[po]=t,t.stateNode=n}return zs(t),null;case 13:if(Po(la),n=t.memoizedState,null===e||null!==e.memoizedState&&null!==e.memoizedState.dehydrated){if(rr&&null!==or&&0!=(1&t.mode)&&0==(128&t.flags))pr(),gr(),t.flags|=98560,a=!1;else if(a=hr(t),null!==n&&null!==n.dehydrated){if(null===e){if(!a)throw Error(r(318));if(!(a=null!==(a=t.memoizedState)?a.dehydrated:null))throw Error(r(317));a[po]=t}else gr(),0==(128&t.flags)&&(t.memoizedState=null),t.flags|=4;zs(t),a=!1}else null!==ar&&(ac(ar),ar=null),a=!0;if(!a)return 65536&t.flags?t:null}return 0!=(128&t.flags)?(t.lanes=i,t):((n=null!==n)!=(null!==e&&null!==e.memoizedState)&&n&&(t.child.flags|=8192,0!=(1&t.mode)&&(null===e||0!=(1&la.current)?0===Rl&&(Rl=3):fc())),null!==t.updateQueue&&(t.flags|=4),zs(t),null);case 4:return ra(),_s(e,t),null===e&&Zn(t.stateNode.containerInfo),zs(t),null;case 10:return Tr(t.type._context),zs(t),null;case 19:if(Po(la),null===(a=t.memoizedState))return zs(t),null;if(n=0!=(128&t.flags),null===(l=a.rendering))if(n)js(a,!1);else{if(0!==Rl||null!==e&&0!=(128&e.flags))for(e=t.child;null!==e;){if(null!==(l=ca(e))){for(t.flags|=128,js(a,!1),null!==(n=l.updateQueue)&&(t.updateQueue=n,t.flags|=4),t.subtreeFlags=0,n=i,i=t.child;null!==i;)e=n,(a=i).flags&=14680066,null===(l=a.alternate)?(a.childLanes=0,a.lanes=e,a.child=null,a.subtreeFlags=0,a.memoizedProps=null,a.memoizedState=null,a.updateQueue=null,a.dependencies=null,a.stateNode=null):(a.childLanes=l.childLanes,a.lanes=l.lanes,a.child=l.child,a.subtreeFlags=0,a.deletions=null,a.memoizedProps=l.memoizedProps,a.memoizedState=l.memoizedState,a.updateQueue=l.updateQueue,a.type=l.type,e=l.dependencies,a.dependencies=null===e?null:{lanes:e.lanes,firstContext:e.firstContext}),i=i.sibling;return Ao(la,1&la.current|2),t.child}e=e.sibling}null!==a.tail&&Xe()>Zl&&(t.flags|=128,n=!0,js(a,!1),t.lanes=4194304)}else{if(!n)if(null!==(e=ca(l))){if(t.flags|=128,n=!0,null!==(i=e.updateQueue)&&(t.updateQueue=i,t.flags|=4),js(a,!0),null===a.tail&&"hidden"===a.tailMode&&!l.alternate&&!rr)return zs(t),null}else 2*Xe()-a.renderingStartTime>Zl&&1073741824!==i&&(t.flags|=128,n=!0,js(a,!1),t.lanes=4194304);a.isBackwards?(l.sibling=t.child,t.child=l):(null!==(i=a.last)?i.sibling=l:t.child=l,a.last=l)}return null!==a.tail?(t=a.tail,a.rendering=t,a.tail=t.sibling,a.renderingStartTime=Xe(),t.sibling=null,i=la.current,Ao(la,n?1&i|2:1&i),t):(zs(t),null);case 22:case 23:return uc(),n=null!==t.memoizedState,null!==e&&null!==e.memoizedState!==n&&(t.flags|=8192),n&&0!=(1&t.mode)?0!=(1073741824&_l)&&(zs(t),6&t.subtreeFlags&&(t.flags|=8192)):zs(t),null;case 24:case 25:return null}throw Error(r(156,t.tag))}function Ks(e,t){switch(ir(t),t.tag){case 1:return No(t.type)&&Ro(),65536&(e=t.flags)?(t.flags=-65537&e|128,t):null;case 3:return ra(),Po(Io),Po(ko),ua(),0!=(65536&(e=t.flags))&&0==(128&e)?(t.flags=-65537&e|128,t):null;case 5:return sa(t),null;case 13:if(Po(la),null!==(e=t.memoizedState)&&null!==e.dehydrated){if(null===t.alternate)throw Error(r(340));gr()}return 65536&(e=t.flags)?(t.flags=-65537&e|128,t):null;case 19:return Po(la),null;case 4:return ra(),null;case 10:return Tr(t.type._context),null;case 22:case 23:return uc(),null;default:return null}}Ds=function(e,t){for(var i=t.child;null!==i;){if(5===i.tag||6===i.tag)e.appendChild(i.stateNode);else if(4!==i.tag&&null!==i.child){i.child.return=i,i=i.child;continue}if(i===t)break;for(;null===i.sibling;){if(null===i.return||i.return===t)return;i=i.return}i.sibling.return=i.return,i=i.sibling}},_s=function(){},Ns=function(e,t,i,n){var o=e.memoizedProps;if(o!==n){e=t.stateNode,na(ea.current);var r,a=null;switch(i){case"input":o=q(e,o),n=q(e,n),a=[];break;case"select":o=B({},o,{value:void 0}),n=B({},n,{value:void 0}),a=[];break;case"textarea":o=ne(e,o),n=ne(e,n),a=[];break;default:"function"!=typeof o.onClick&&"function"==typeof n.onClick&&(e.onclick=Qn)}for(d in ye(i,n),i=null,o)if(!n.hasOwnProperty(d)&&o.hasOwnProperty(d)&&null!=o[d])if("style"===d){var l=o[d];for(r in l)l.hasOwnProperty(r)&&(i||(i={}),i[r]="")}else"dangerouslySetInnerHTML"!==d&&"children"!==d&&"suppressContentEditableWarning"!==d&&"suppressHydrationWarning"!==d&&"autoFocus"!==d&&(s.hasOwnProperty(d)?a||(a=[]):(a=a||[]).push(d,null));for(d in n){var c=n[d];if(l=null!=o?o[d]:void 0,n.hasOwnProperty(d)&&c!==l&&(null!=c||null!=l))if("style"===d)if(l){for(r in l)!l.hasOwnProperty(r)||c&&c.hasOwnProperty(r)||(i||(i={}),i[r]="");for(r in c)c.hasOwnProperty(r)&&l[r]!==c[r]&&(i||(i={}),i[r]=c[r])}else i||(a||(a=[]),a.push(d,i)),i=c;else"dangerouslySetInnerHTML"===d?(c=c?c.__html:void 0,l=l?l.__html:void 0,null!=c&&l!==c&&(a=a||[]).push(d,c)):"children"===d?"string"!=typeof c&&"number"!=typeof c||(a=a||[]).push(d,""+c):"suppressContentEditableWarning"!==d&&"suppressHydrationWarning"!==d&&(s.hasOwnProperty(d)?(null!=c&&"onScroll"===d&&Un("scroll",e),a||l===c||(a=[])):(a=a||[]).push(d,c))}i&&(a=a||[]).push("style",i);var d=a;(t.updateQueue=d)&&(t.flags|=4)}},Rs=function(e,t,i,n){i!==n&&(t.flags|=4)};var qs=!1,Ys=!1,Xs="function"==typeof WeakSet?WeakSet:Set,Js=null;function Qs(e,t){var i=e.ref;if(null!==i)if("function"==typeof i)try{i(null)}catch(i){wc(e,t,i)}else i.current=null}function el(e,t,i){try{i()}catch(i){wc(e,t,i)}}var tl=!1;function il(e,t,i){var n=t.updateQueue;if(null!==(n=null!==n?n.lastEffect:null)){var o=n=n.next;do{if((o.tag&e)===e){var r=o.destroy;o.destroy=void 0,void 0!==r&&el(t,i,r)}o=o.next}while(o!==n)}}function nl(e,t){if(null!==(t=null!==(t=t.updateQueue)?t.lastEffect:null)){var i=t=t.next;do{if((i.tag&e)===e){var n=i.create;i.destroy=n()}i=i.next}while(i!==t)}}function ol(e){var t=e.ref;if(null!==t){var i=e.stateNode;e.tag,e=i,"function"==typeof t?t(e):t.current=e}}function rl(e){var t=e.alternate;null!==t&&(e.alternate=null,rl(t)),e.child=null,e.deletions=null,e.sibling=null,5===e.tag&&null!==(t=e.stateNode)&&(delete t[po],delete t[go],delete t[mo],delete t[vo],delete t[yo]),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function al(e){return 5===e.tag||3===e.tag||4===e.tag}function sl(e){e:for(;;){for(;null===e.sibling;){if(null===e.return||al(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;5!==e.tag&&6!==e.tag&&18!==e.tag;){if(2&e.flags)continue e;if(null===e.child||4===e.tag)continue e;e.child.return=e,e=e.child}if(!(2&e.flags))return e.stateNode}}function ll(e,t,i){var n=e.tag;if(5===n||6===n)e=e.stateNode,t?8===i.nodeType?i.parentNode.insertBefore(e,t):i.insertBefore(e,t):(8===i.nodeType?(t=i.parentNode).insertBefore(e,i):(t=i).appendChild(e),null!=(i=i._reactRootContainer)||null!==t.onclick||(t.onclick=Qn));else if(4!==n&&null!==(e=e.child))for(ll(e,t,i),e=e.sibling;null!==e;)ll(e,t,i),e=e.sibling}function cl(e,t,i){var n=e.tag;if(5===n||6===n)e=e.stateNode,t?i.insertBefore(e,t):i.appendChild(e);else if(4!==n&&null!==(e=e.child))for(cl(e,t,i),e=e.sibling;null!==e;)cl(e,t,i),e=e.sibling}var dl=null,ul=!1;function hl(e,t,i){for(i=i.child;null!==i;)pl(e,t,i),i=i.sibling}function pl(e,t,i){if(rt&&"function"==typeof rt.onCommitFiberUnmount)try{rt.onCommitFiberUnmount(ot,i)}catch(e){}switch(i.tag){case 5:Ys||Qs(i,t);case 6:var n=dl,o=ul;dl=null,hl(e,t,i),ul=o,null!==(dl=n)&&(ul?(e=dl,i=i.stateNode,8===e.nodeType?e.parentNode.removeChild(i):e.removeChild(i)):dl.removeChild(i.stateNode));break;case 18:null!==dl&&(ul?(e=dl,i=i.stateNode,8===e.nodeType?lo(e.parentNode,i):1===e.nodeType&&lo(e,i),Zt(e)):lo(dl,i.stateNode));break;case 4:n=dl,o=ul,dl=i.stateNode.containerInfo,ul=!0,hl(e,t,i),dl=n,ul=o;break;case 0:case 11:case 14:case 15:if(!Ys&&null!==(n=i.updateQueue)&&null!==(n=n.lastEffect)){o=n=n.next;do{var r=o,a=r.destroy;r=r.tag,void 0!==a&&(0!=(2&r)||0!=(4&r))&&el(i,t,a),o=o.next}while(o!==n)}hl(e,t,i);break;case 1:if(!Ys&&(Qs(i,t),"function"==typeof(n=i.stateNode).componentWillUnmount))try{n.props=i.memoizedProps,n.state=i.memoizedState,n.componentWillUnmount()}catch(e){wc(i,t,e)}hl(e,t,i);break;case 21:hl(e,t,i);break;case 22:1&i.mode?(Ys=(n=Ys)||null!==i.memoizedState,hl(e,t,i),Ys=n):hl(e,t,i);break;default:hl(e,t,i)}}function gl(e){var t=e.updateQueue;if(null!==t){e.updateQueue=null;var i=e.stateNode;null===i&&(i=e.stateNode=new Xs),t.forEach((function(t){var n=Ec.bind(null,e,t);i.has(t)||(i.add(t),t.then(n,n))}))}}function fl(e,t){var i=t.deletions;if(null!==i)for(var n=0;n<i.length;n++){var o=i[n];try{var a=e,s=t,l=s;e:for(;null!==l;){switch(l.tag){case 5:dl=l.stateNode,ul=!1;break e;case 3:case 4:dl=l.stateNode.containerInfo,ul=!0;break e}l=l.return}if(null===dl)throw Error(r(160));pl(a,s,o),dl=null,ul=!1;var c=o.alternate;null!==c&&(c.return=null),o.return=null}catch(e){wc(o,t,e)}}if(12854&t.subtreeFlags)for(t=t.child;null!==t;)ml(t,e),t=t.sibling}function ml(e,t){var i=e.alternate,n=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(fl(t,e),vl(e),4&n){try{il(3,e,e.return),nl(3,e)}catch(t){wc(e,e.return,t)}try{il(5,e,e.return)}catch(t){wc(e,e.return,t)}}break;case 1:fl(t,e),vl(e),512&n&&null!==i&&Qs(i,i.return);break;case 5:if(fl(t,e),vl(e),512&n&&null!==i&&Qs(i,i.return),32&e.flags){var o=e.stateNode;try{he(o,"")}catch(t){wc(e,e.return,t)}}if(4&n&&null!=(o=e.stateNode)){var a=e.memoizedProps,s=null!==i?i.memoizedProps:a,l=e.type,c=e.updateQueue;if(e.updateQueue=null,null!==c)try{"input"===l&&"radio"===a.type&&null!=a.name&&X(o,a),Ce(l,s);var d=Ce(l,a);for(s=0;s<c.length;s+=2){var u=c[s],h=c[s+1];"style"===u?me(o,h):"dangerouslySetInnerHTML"===u?ue(o,h):"children"===u?he(o,h):C(o,u,h,d)}switch(l){case"input":J(o,a);break;case"textarea":re(o,a);break;case"select":var p=o._wrapperState.wasMultiple;o._wrapperState.wasMultiple=!!a.multiple;var g=a.value;null!=g?ie(o,!!a.multiple,g,!1):p!==!!a.multiple&&(null!=a.defaultValue?ie(o,!!a.multiple,a.defaultValue,!0):ie(o,!!a.multiple,a.multiple?[]:"",!1))}o[go]=a}catch(t){wc(e,e.return,t)}}break;case 6:if(fl(t,e),vl(e),4&n){if(null===e.stateNode)throw Error(r(162));o=e.stateNode,a=e.memoizedProps;try{o.nodeValue=a}catch(t){wc(e,e.return,t)}}break;case 3:if(fl(t,e),vl(e),4&n&&null!==i&&i.memoizedState.isDehydrated)try{Zt(t.containerInfo)}catch(t){wc(e,e.return,t)}break;case 4:default:fl(t,e),vl(e);break;case 13:fl(t,e),vl(e),8192&(o=e.child).flags&&(a=null!==o.memoizedState,o.stateNode.isHidden=a,!a||null!==o.alternate&&null!==o.alternate.memoizedState||($l=Xe())),4&n&&gl(e);break;case 22:if(u=null!==i&&null!==i.memoizedState,1&e.mode?(Ys=(d=Ys)||u,fl(t,e),Ys=d):fl(t,e),vl(e),8192&n){if(d=null!==e.memoizedState,(e.stateNode.isHidden=d)&&!u&&0!=(1&e.mode))for(Js=e,u=e.child;null!==u;){for(h=Js=u;null!==Js;){switch(g=(p=Js).child,p.tag){case 0:case 11:case 14:case 15:il(4,p,p.return);break;case 1:Qs(p,p.return);var f=p.stateNode;if("function"==typeof f.componentWillUnmount){n=p,i=p.return;try{t=n,f.props=t.memoizedProps,f.state=t.memoizedState,f.componentWillUnmount()}catch(e){wc(n,i,e)}}break;case 5:Qs(p,p.return);break;case 22:if(null!==p.memoizedState){Sl(h);continue}}null!==g?(g.return=p,Js=g):Sl(h)}u=u.sibling}e:for(u=null,h=e;;){if(5===h.tag){if(null===u){u=h;try{o=h.stateNode,d?"function"==typeof(a=o.style).setProperty?a.setProperty("display","none","important"):a.display="none":(l=h.stateNode,s=null!=(c=h.memoizedProps.style)&&c.hasOwnProperty("display")?c.display:null,l.style.display=fe("display",s))}catch(t){wc(e,e.return,t)}}}else if(6===h.tag){if(null===u)try{h.stateNode.nodeValue=d?"":h.memoizedProps}catch(t){wc(e,e.return,t)}}else if((22!==h.tag&&23!==h.tag||null===h.memoizedState||h===e)&&null!==h.child){h.child.return=h,h=h.child;continue}if(h===e)break e;for(;null===h.sibling;){if(null===h.return||h.return===e)break e;u===h&&(u=null),h=h.return}u===h&&(u=null),h.sibling.return=h.return,h=h.sibling}}break;case 19:fl(t,e),vl(e),4&n&&gl(e);case 21:}}function vl(e){var t=e.flags;if(2&t){try{e:{for(var i=e.return;null!==i;){if(al(i)){var n=i;break e}i=i.return}throw Error(r(160))}switch(n.tag){case 5:var o=n.stateNode;32&n.flags&&(he(o,""),n.flags&=-33),cl(e,sl(e),o);break;case 3:case 4:var a=n.stateNode.containerInfo;ll(e,sl(e),a);break;default:throw Error(r(161))}}catch(t){wc(e,e.return,t)}e.flags&=-3}4096&t&&(e.flags&=-4097)}function yl(e,t,i){Js=e,Cl(e,t,i)}function Cl(e,t,i){for(var n=0!=(1&e.mode);null!==Js;){var o=Js,r=o.child;if(22===o.tag&&n){var a=null!==o.memoizedState||qs;if(!a){var s=o.alternate,l=null!==s&&null!==s.memoizedState||Ys;s=qs;var c=Ys;if(qs=a,(Ys=l)&&!c)for(Js=o;null!==Js;)l=(a=Js).child,22===a.tag&&null!==a.memoizedState?xl(o):null!==l?(l.return=a,Js=l):xl(o);for(;null!==r;)Js=r,Cl(r,t,i),r=r.sibling;Js=o,qs=s,Ys=c}bl(e)}else 0!=(8772&o.subtreeFlags)&&null!==r?(r.return=o,Js=r):bl(e)}}function bl(e){for(;null!==Js;){var t=Js;if(0!=(8772&t.flags)){var i=t.alternate;try{if(0!=(8772&t.flags))switch(t.tag){case 0:case 11:case 15:Ys||nl(5,t);break;case 1:var n=t.stateNode;if(4&t.flags&&!Ys)if(null===i)n.componentDidMount();else{var o=t.elementType===t.type?i.memoizedProps:vr(t.type,i.memoizedProps);n.componentDidUpdate(o,i.memoizedState,n.__reactInternalSnapshotBeforeUpdate)}var a=t.updateQueue;null!==a&&Ur(t,a,n);break;case 3:var s=t.updateQueue;if(null!==s){if(i=null,null!==t.child)switch(t.child.tag){case 5:case 1:i=t.child.stateNode}Ur(t,s,i)}break;case 5:var l=t.stateNode;if(null===i&&4&t.flags){i=l;var c=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":c.autoFocus&&i.focus();break;case"img":c.src&&(i.src=c.src)}}break;case 6:case 4:case 12:case 19:case 17:case 21:case 22:case 23:case 25:break;case 13:if(null===t.memoizedState){var d=t.alternate;if(null!==d){var u=d.memoizedState;if(null!==u){var h=u.dehydrated;null!==h&&Zt(h)}}}break;default:throw Error(r(163))}Ys||512&t.flags&&ol(t)}catch(e){wc(t,t.return,e)}}if(t===e){Js=null;break}if(null!==(i=t.sibling)){i.return=t.return,Js=i;break}Js=t.return}}function Sl(e){for(;null!==Js;){var t=Js;if(t===e){Js=null;break}var i=t.sibling;if(null!==i){i.return=t.return,Js=i;break}Js=t.return}}function xl(e){for(;null!==Js;){var t=Js;try{switch(t.tag){case 0:case 11:case 15:var i=t.return;try{nl(4,t)}catch(e){wc(t,i,e)}break;case 1:var n=t.stateNode;if("function"==typeof n.componentDidMount){var o=t.return;try{n.componentDidMount()}catch(e){wc(t,o,e)}}var r=t.return;try{ol(t)}catch(e){wc(t,r,e)}break;case 5:var a=t.return;try{ol(t)}catch(e){wc(t,a,e)}}}catch(e){wc(t,t.return,e)}if(t===e){Js=null;break}var s=t.sibling;if(null!==s){s.return=t.return,Js=s;break}Js=t.return}}var Tl,wl=Math.ceil,Ol=b.ReactCurrentDispatcher,Pl=b.ReactCurrentOwner,Al=b.ReactCurrentBatchConfig,El=0,kl=null,Il=null,Dl=0,_l=0,Nl=Oo(0),Rl=0,Ml=null,Ll=0,Bl=0,Fl=0,Ul=null,Hl=null,$l=0,Zl=1/0,Vl=null,Gl=!1,jl=null,zl=null,Wl=!1,Kl=null,ql=0,Yl=0,Xl=null,Jl=-1,Ql=0;function ec(){return 0!=(6&El)?Xe():-1!==Jl?Jl:Jl=Xe()}function tc(e){return 0==(1&e.mode)?1:0!=(2&El)&&0!==Dl?Dl&-Dl:null!==mr.transition?(0===Ql&&(Ql=ft()),Ql):0!==(e=Ct)?e:e=void 0===(e=window.event)?16:Yt(e.type)}function ic(e,t,i,n){if(50<Yl)throw Yl=0,Xl=null,Error(r(185));vt(e,i,n),0!=(2&El)&&e===kl||(e===kl&&(0==(2&El)&&(Bl|=i),4===Rl&&sc(e,Dl)),nc(e,n),1===i&&0===El&&0==(1&t.mode)&&(Zl=Xe()+500,Ho&&Vo()))}function nc(e,t){var i=e.callbackNode;!function(e,t){for(var i=e.suspendedLanes,n=e.pingedLanes,o=e.expirationTimes,r=e.pendingLanes;0<r;){var a=31-at(r),s=1<<a,l=o[a];-1===l?0!=(s&i)&&0==(s&n)||(o[a]=pt(s,t)):l<=t&&(e.expiredLanes|=s),r&=~s}}(e,t);var n=ht(e,e===kl?Dl:0);if(0===n)null!==i&&Ke(i),e.callbackNode=null,e.callbackPriority=0;else if(t=n&-n,e.callbackPriority!==t){if(null!=i&&Ke(i),1===t)0===e.tag?function(e){Ho=!0,Zo(e)}(lc.bind(null,e)):Zo(lc.bind(null,e)),ao((function(){0==(6&El)&&Vo()})),i=null;else{switch(bt(n)){case 1:i=Qe;break;case 4:i=et;break;case 16:default:i=tt;break;case 536870912:i=nt}i=kc(i,oc.bind(null,e))}e.callbackPriority=t,e.callbackNode=i}}function oc(e,t){if(Jl=-1,Ql=0,0!=(6&El))throw Error(r(327));var i=e.callbackNode;if(xc()&&e.callbackNode!==i)return null;var n=ht(e,e===kl?Dl:0);if(0===n)return null;if(0!=(30&n)||0!=(n&e.expiredLanes)||t)t=mc(e,n);else{t=n;var o=El;El|=2;var a=gc();for(kl===e&&Dl===t||(Vl=null,Zl=Xe()+500,hc(e,t));;)try{yc();break}catch(t){pc(e,t)}xr(),Ol.current=a,El=o,null!==Il?t=0:(kl=null,Dl=0,t=Rl)}if(0!==t){if(2===t&&0!==(o=gt(e))&&(n=o,t=rc(e,o)),1===t)throw i=Ml,hc(e,0),sc(e,n),nc(e,Xe()),i;if(6===t)sc(e,n);else{if(o=e.current.alternate,0==(30&n)&&!function(e){for(var t=e;;){if(16384&t.flags){var i=t.updateQueue;if(null!==i&&null!==(i=i.stores))for(var n=0;n<i.length;n++){var o=i[n],r=o.getSnapshot;o=o.value;try{if(!sn(r(),o))return!1}catch(e){return!1}}}if(i=t.child,16384&t.subtreeFlags&&null!==i)i.return=t,t=i;else{if(t===e)break;for(;null===t.sibling;){if(null===t.return||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}(o)&&(2===(t=mc(e,n))&&0!==(a=gt(e))&&(n=a,t=rc(e,a)),1===t))throw i=Ml,hc(e,0),sc(e,n),nc(e,Xe()),i;switch(e.finishedWork=o,e.finishedLanes=n,t){case 0:case 1:throw Error(r(345));case 2:case 5:Sc(e,Hl,Vl);break;case 3:if(sc(e,n),(130023424&n)===n&&10<(t=$l+500-Xe())){if(0!==ht(e,0))break;if(((o=e.suspendedLanes)&n)!==n){ec(),e.pingedLanes|=e.suspendedLanes&o;break}e.timeoutHandle=no(Sc.bind(null,e,Hl,Vl),t);break}Sc(e,Hl,Vl);break;case 4:if(sc(e,n),(4194240&n)===n)break;for(t=e.eventTimes,o=-1;0<n;){var s=31-at(n);a=1<<s,(s=t[s])>o&&(o=s),n&=~a}if(n=o,10<(n=(120>(n=Xe()-n)?120:480>n?480:1080>n?1080:1920>n?1920:3e3>n?3e3:4320>n?4320:1960*wl(n/1960))-n)){e.timeoutHandle=no(Sc.bind(null,e,Hl,Vl),n);break}Sc(e,Hl,Vl);break;default:throw Error(r(329))}}}return nc(e,Xe()),e.callbackNode===i?oc.bind(null,e):null}function rc(e,t){var i=Ul;return e.current.memoizedState.isDehydrated&&(hc(e,t).flags|=256),2!==(e=mc(e,t))&&(t=Hl,Hl=i,null!==t&&ac(t)),e}function ac(e){null===Hl?Hl=e:Hl.push.apply(Hl,e)}function sc(e,t){for(t&=~Fl,t&=~Bl,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var i=31-at(t),n=1<<i;e[i]=-1,t&=~n}}function lc(e){if(0!=(6&El))throw Error(r(327));xc();var t=ht(e,0);if(0==(1&t))return nc(e,Xe()),null;var i=mc(e,t);if(0!==e.tag&&2===i){var n=gt(e);0!==n&&(t=n,i=rc(e,n))}if(1===i)throw i=Ml,hc(e,0),sc(e,t),nc(e,Xe()),i;if(6===i)throw Error(r(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,Sc(e,Hl,Vl),nc(e,Xe()),null}function cc(e,t){var i=El;El|=1;try{return e(t)}finally{0===(El=i)&&(Zl=Xe()+500,Ho&&Vo())}}function dc(e){null!==Kl&&0===Kl.tag&&0==(6&El)&&xc();var t=El;El|=1;var i=Al.transition,n=Ct;try{if(Al.transition=null,Ct=1,e)return e()}finally{Ct=n,Al.transition=i,0==(6&(El=t))&&Vo()}}function uc(){_l=Nl.current,Po(Nl)}function hc(e,t){e.finishedWork=null,e.finishedLanes=0;var i=e.timeoutHandle;if(-1!==i&&(e.timeoutHandle=-1,oo(i)),null!==Il)for(i=Il.return;null!==i;){var n=i;switch(ir(n),n.tag){case 1:null!=(n=n.type.childContextTypes)&&Ro();break;case 3:ra(),Po(Io),Po(ko),ua();break;case 5:sa(n);break;case 4:ra();break;case 13:case 19:Po(la);break;case 10:Tr(n.type._context);break;case 22:case 23:uc()}i=i.return}if(kl=e,Il=e=Nc(e.current,null),Dl=_l=t,Rl=0,Ml=null,Fl=Bl=Ll=0,Hl=Ul=null,null!==Ar){for(t=0;t<Ar.length;t++)if(null!==(n=(i=Ar[t]).interleaved)){i.interleaved=null;var o=n.next,r=i.pending;if(null!==r){var a=r.next;r.next=o,n.next=a}i.pending=n}Ar=null}return e}function pc(e,t){for(;;){var i=Il;try{if(xr(),ha.current=as,ya){for(var n=fa.memoizedState;null!==n;){var o=n.queue;null!==o&&(o.pending=null),n=n.next}ya=!1}if(ga=0,va=ma=fa=null,Ca=!1,ba=0,Pl.current=null,null===i||null===i.return){Rl=1,Ml=t,Il=null;break}e:{var a=e,s=i.return,l=i,c=t;if(t=Dl,l.flags|=32768,null!==c&&"object"==typeof c&&"function"==typeof c.then){var d=c,u=l,h=u.tag;if(0==(1&u.mode)&&(0===h||11===h||15===h)){var p=u.alternate;p?(u.updateQueue=p.updateQueue,u.memoizedState=p.memoizedState,u.lanes=p.lanes):(u.updateQueue=null,u.memoizedState=null)}var g=ms(s);if(null!==g){g.flags&=-257,vs(g,s,l,0,t),1&g.mode&&fs(a,d,t),c=d;var f=(t=g).updateQueue;if(null===f){var m=new Set;m.add(c),t.updateQueue=m}else f.add(c);break e}if(0==(1&t)){fs(a,d,t),fc();break e}c=Error(r(426))}else if(rr&&1&l.mode){var v=ms(s);if(null!==v){0==(65536&v.flags)&&(v.flags|=256),vs(v,s,l,0,t),fr(ds(c,l));break e}}a=c=ds(c,l),4!==Rl&&(Rl=2),null===Ul?Ul=[a]:Ul.push(a),a=s;do{switch(a.tag){case 3:a.flags|=65536,t&=-t,a.lanes|=t,Br(a,ps(0,c,t));break e;case 1:l=c;var y=a.type,C=a.stateNode;if(0==(128&a.flags)&&("function"==typeof y.getDerivedStateFromError||null!==C&&"function"==typeof C.componentDidCatch&&(null===zl||!zl.has(C)))){a.flags|=65536,t&=-t,a.lanes|=t,Br(a,gs(a,l,t));break e}}a=a.return}while(null!==a)}bc(i)}catch(e){t=e,Il===i&&null!==i&&(Il=i=i.return);continue}break}}function gc(){var e=Ol.current;return Ol.current=as,null===e?as:e}function fc(){0!==Rl&&3!==Rl&&2!==Rl||(Rl=4),null===kl||0==(268435455&Ll)&&0==(268435455&Bl)||sc(kl,Dl)}function mc(e,t){var i=El;El|=2;var n=gc();for(kl===e&&Dl===t||(Vl=null,hc(e,t));;)try{vc();break}catch(t){pc(e,t)}if(xr(),El=i,Ol.current=n,null!==Il)throw Error(r(261));return kl=null,Dl=0,Rl}function vc(){for(;null!==Il;)Cc(Il)}function yc(){for(;null!==Il&&!qe();)Cc(Il)}function Cc(e){var t=Tl(e.alternate,e,_l);e.memoizedProps=e.pendingProps,null===t?bc(e):Il=t,Pl.current=null}function bc(e){var t=e;do{var i=t.alternate;if(e=t.return,0==(32768&t.flags)){if(null!==(i=Ws(i,t,_l)))return void(Il=i)}else{if(null!==(i=Ks(i,t)))return i.flags&=32767,void(Il=i);if(null===e)return Rl=6,void(Il=null);e.flags|=32768,e.subtreeFlags=0,e.deletions=null}if(null!==(t=t.sibling))return void(Il=t);Il=t=e}while(null!==t);0===Rl&&(Rl=5)}function Sc(e,t,i){var n=Ct,o=Al.transition;try{Al.transition=null,Ct=1,function(e,t,i,n){do{xc()}while(null!==Kl);if(0!=(6&El))throw Error(r(327));i=e.finishedWork;var o=e.finishedLanes;if(null===i)return null;if(e.finishedWork=null,e.finishedLanes=0,i===e.current)throw Error(r(177));e.callbackNode=null,e.callbackPriority=0;var a=i.lanes|i.childLanes;if(function(e,t){var i=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var n=e.eventTimes;for(e=e.expirationTimes;0<i;){var o=31-at(i),r=1<<o;t[o]=0,n[o]=-1,e[o]=-1,i&=~r}}(e,a),e===kl&&(Il=kl=null,Dl=0),0==(2064&i.subtreeFlags)&&0==(2064&i.flags)||Wl||(Wl=!0,kc(tt,(function(){return xc(),null}))),a=0!=(15990&i.flags),0!=(15990&i.subtreeFlags)||a){a=Al.transition,Al.transition=null;var s=Ct;Ct=1;var l=El;El|=4,Pl.current=null,function(e,t){if(eo=Gt,pn(e=hn())){if("selectionStart"in e)var i={start:e.selectionStart,end:e.selectionEnd};else e:{var n=(i=(i=e.ownerDocument)&&i.defaultView||window).getSelection&&i.getSelection();if(n&&0!==n.rangeCount){i=n.anchorNode;var o=n.anchorOffset,a=n.focusNode;n=n.focusOffset;try{i.nodeType,a.nodeType}catch(e){i=null;break e}var s=0,l=-1,c=-1,d=0,u=0,h=e,p=null;t:for(;;){for(var g;h!==i||0!==o&&3!==h.nodeType||(l=s+o),h!==a||0!==n&&3!==h.nodeType||(c=s+n),3===h.nodeType&&(s+=h.nodeValue.length),null!==(g=h.firstChild);)p=h,h=g;for(;;){if(h===e)break t;if(p===i&&++d===o&&(l=s),p===a&&++u===n&&(c=s),null!==(g=h.nextSibling))break;p=(h=p).parentNode}h=g}i=-1===l||-1===c?null:{start:l,end:c}}else i=null}i=i||{start:0,end:0}}else i=null;for(to={focusedElem:e,selectionRange:i},Gt=!1,Js=t;null!==Js;)if(e=(t=Js).child,0!=(1028&t.subtreeFlags)&&null!==e)e.return=t,Js=e;else for(;null!==Js;){t=Js;try{var f=t.alternate;if(0!=(1024&t.flags))switch(t.tag){case 0:case 11:case 15:case 5:case 6:case 4:case 17:break;case 1:if(null!==f){var m=f.memoizedProps,v=f.memoizedState,y=t.stateNode,C=y.getSnapshotBeforeUpdate(t.elementType===t.type?m:vr(t.type,m),v);y.__reactInternalSnapshotBeforeUpdate=C}break;case 3:var b=t.stateNode.containerInfo;1===b.nodeType?b.textContent="":9===b.nodeType&&b.documentElement&&b.removeChild(b.documentElement);break;default:throw Error(r(163))}}catch(e){wc(t,t.return,e)}if(null!==(e=t.sibling)){e.return=t.return,Js=e;break}Js=t.return}f=tl,tl=!1}(e,i),ml(i,e),gn(to),Gt=!!eo,to=eo=null,e.current=i,yl(i,e,o),Ye(),El=l,Ct=s,Al.transition=a}else e.current=i;if(Wl&&(Wl=!1,Kl=e,ql=o),0===(a=e.pendingLanes)&&(zl=null),function(e){if(rt&&"function"==typeof rt.onCommitFiberRoot)try{rt.onCommitFiberRoot(ot,e,void 0,128==(128&e.current.flags))}catch(e){}}(i.stateNode),nc(e,Xe()),null!==t)for(n=e.onRecoverableError,i=0;i<t.length;i++)n((o=t[i]).value,{componentStack:o.stack,digest:o.digest});if(Gl)throw Gl=!1,e=jl,jl=null,e;0!=(1&ql)&&0!==e.tag&&xc(),0!=(1&(a=e.pendingLanes))?e===Xl?Yl++:(Yl=0,Xl=e):Yl=0,Vo()}(e,t,i,n)}finally{Al.transition=o,Ct=n}return null}function xc(){if(null!==Kl){var e=bt(ql),t=Al.transition,i=Ct;try{if(Al.transition=null,Ct=16>e?16:e,null===Kl)var n=!1;else{if(e=Kl,Kl=null,ql=0,0!=(6&El))throw Error(r(331));var o=El;for(El|=4,Js=e.current;null!==Js;){var a=Js,s=a.child;if(0!=(16&Js.flags)){var l=a.deletions;if(null!==l){for(var c=0;c<l.length;c++){var d=l[c];for(Js=d;null!==Js;){var u=Js;switch(u.tag){case 0:case 11:case 15:il(8,u,a)}var h=u.child;if(null!==h)h.return=u,Js=h;else for(;null!==Js;){var p=(u=Js).sibling,g=u.return;if(rl(u),u===d){Js=null;break}if(null!==p){p.return=g,Js=p;break}Js=g}}}var f=a.alternate;if(null!==f){var m=f.child;if(null!==m){f.child=null;do{var v=m.sibling;m.sibling=null,m=v}while(null!==m)}}Js=a}}if(0!=(2064&a.subtreeFlags)&&null!==s)s.return=a,Js=s;else e:for(;null!==Js;){if(0!=(2048&(a=Js).flags))switch(a.tag){case 0:case 11:case 15:il(9,a,a.return)}var y=a.sibling;if(null!==y){y.return=a.return,Js=y;break e}Js=a.return}}var C=e.current;for(Js=C;null!==Js;){var b=(s=Js).child;if(0!=(2064&s.subtreeFlags)&&null!==b)b.return=s,Js=b;else e:for(s=C;null!==Js;){if(0!=(2048&(l=Js).flags))try{switch(l.tag){case 0:case 11:case 15:nl(9,l)}}catch(e){wc(l,l.return,e)}if(l===s){Js=null;break e}var S=l.sibling;if(null!==S){S.return=l.return,Js=S;break e}Js=l.return}}if(El=o,Vo(),rt&&"function"==typeof rt.onPostCommitFiberRoot)try{rt.onPostCommitFiberRoot(ot,e)}catch(e){}n=!0}return n}finally{Ct=i,Al.transition=t}}return!1}function Tc(e,t,i){e=Mr(e,t=ps(0,t=ds(i,t),1),1),t=ec(),null!==e&&(vt(e,1,t),nc(e,t))}function wc(e,t,i){if(3===e.tag)Tc(e,e,i);else for(;null!==t;){if(3===t.tag){Tc(t,e,i);break}if(1===t.tag){var n=t.stateNode;if("function"==typeof t.type.getDerivedStateFromError||"function"==typeof n.componentDidCatch&&(null===zl||!zl.has(n))){t=Mr(t,e=gs(t,e=ds(i,e),1),1),e=ec(),null!==t&&(vt(t,1,e),nc(t,e));break}}t=t.return}}function Oc(e,t,i){var n=e.pingCache;null!==n&&n.delete(t),t=ec(),e.pingedLanes|=e.suspendedLanes&i,kl===e&&(Dl&i)===i&&(4===Rl||3===Rl&&(130023424&Dl)===Dl&&500>Xe()-$l?hc(e,0):Fl|=i),nc(e,t)}function Pc(e,t){0===t&&(0==(1&e.mode)?t=1:(t=dt,0==(130023424&(dt<<=1))&&(dt=4194304)));var i=ec();null!==(e=Ir(e,t))&&(vt(e,t,i),nc(e,i))}function Ac(e){var t=e.memoizedState,i=0;null!==t&&(i=t.retryLane),Pc(e,i)}function Ec(e,t){var i=0;switch(e.tag){case 13:var n=e.stateNode,o=e.memoizedState;null!==o&&(i=o.retryLane);break;case 19:n=e.stateNode;break;default:throw Error(r(314))}null!==n&&n.delete(t),Pc(e,i)}function kc(e,t){return We(e,t)}function Ic(e,t,i,n){this.tag=e,this.key=i,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=n,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Dc(e,t,i,n){return new Ic(e,t,i,n)}function _c(e){return!(!(e=e.prototype)||!e.isReactComponent)}function Nc(e,t){var i=e.alternate;return null===i?((i=Dc(e.tag,t,e.key,e.mode)).elementType=e.elementType,i.type=e.type,i.stateNode=e.stateNode,i.alternate=e,e.alternate=i):(i.pendingProps=t,i.type=e.type,i.flags=0,i.subtreeFlags=0,i.deletions=null),i.flags=14680064&e.flags,i.childLanes=e.childLanes,i.lanes=e.lanes,i.child=e.child,i.memoizedProps=e.memoizedProps,i.memoizedState=e.memoizedState,i.updateQueue=e.updateQueue,t=e.dependencies,i.dependencies=null===t?null:{lanes:t.lanes,firstContext:t.firstContext},i.sibling=e.sibling,i.index=e.index,i.ref=e.ref,i}function Rc(e,t,i,n,o,a){var s=2;if(n=e,"function"==typeof e)_c(e)&&(s=1);else if("string"==typeof e)s=5;else e:switch(e){case T:return Mc(i.children,o,a,t);case w:s=8,o|=8;break;case O:return(e=Dc(12,i,t,2|o)).elementType=O,e.lanes=a,e;case k:return(e=Dc(13,i,t,o)).elementType=k,e.lanes=a,e;case I:return(e=Dc(19,i,t,o)).elementType=I,e.lanes=a,e;case N:return Lc(i,o,a,t);default:if("object"==typeof e&&null!==e)switch(e.$$typeof){case P:s=10;break e;case A:s=9;break e;case E:s=11;break e;case D:s=14;break e;case _:s=16,n=null;break e}throw Error(r(130,null==e?e:typeof e,""))}return(t=Dc(s,i,t,o)).elementType=e,t.type=n,t.lanes=a,t}function Mc(e,t,i,n){return(e=Dc(7,e,n,t)).lanes=i,e}function Lc(e,t,i,n){return(e=Dc(22,e,n,t)).elementType=N,e.lanes=i,e.stateNode={isHidden:!1},e}function Bc(e,t,i){return(e=Dc(6,e,null,t)).lanes=i,e}function Fc(e,t,i){return(t=Dc(4,null!==e.children?e.children:[],e.key,t)).lanes=i,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Uc(e,t,i,n,o){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=mt(0),this.expirationTimes=mt(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=mt(0),this.identifierPrefix=n,this.onRecoverableError=o,this.mutableSourceEagerHydrationData=null}function Hc(e,t,i,n,o,r,a,s,l){return e=new Uc(e,t,i,s,l),1===t?(t=1,!0===r&&(t|=8)):t=0,r=Dc(3,null,null,t),e.current=r,r.stateNode=e,r.memoizedState={element:n,isDehydrated:i,cache:null,transitions:null,pendingSuspenseBoundaries:null},_r(r),e}function $c(e){if(!e)return Eo;e:{if(Ze(e=e._reactInternals)!==e||1!==e.tag)throw Error(r(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(No(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(null!==t);throw Error(r(171))}if(1===e.tag){var i=e.type;if(No(i))return Lo(e,i,t)}return t}function Zc(e,t,i,n,o,r,a,s,l){return(e=Hc(i,n,!0,e,0,r,0,s,l)).context=$c(null),i=e.current,(r=Rr(n=ec(),o=tc(i))).callback=null!=t?t:null,Mr(i,r,o),e.current.lanes=o,vt(e,o,n),nc(e,n),e}function Vc(e,t,i,n){var o=t.current,r=ec(),a=tc(o);return i=$c(i),null===t.context?t.context=i:t.pendingContext=i,(t=Rr(r,a)).payload={element:e},null!==(n=void 0===n?null:n)&&(t.callback=n),null!==(e=Mr(o,t,a))&&(ic(e,o,a,r),Lr(e,o,a)),a}function Gc(e){return(e=e.current).child?(e.child.tag,e.child.stateNode):null}function jc(e,t){if(null!==(e=e.memoizedState)&&null!==e.dehydrated){var i=e.retryLane;e.retryLane=0!==i&&i<t?i:t}}function zc(e,t){jc(e,t),(e=e.alternate)&&jc(e,t)}Tl=function(e,t,i){if(null!==e)if(e.memoizedProps!==t.pendingProps||Io.current)Cs=!0;else{if(0==(e.lanes&i)&&0==(128&t.flags))return Cs=!1,function(e,t,i){switch(t.tag){case 3:ks(t),gr();break;case 5:aa(t);break;case 1:No(t.type)&&Bo(t);break;case 4:oa(t,t.stateNode.containerInfo);break;case 10:var n=t.type._context,o=t.memoizedProps.value;Ao(yr,n._currentValue),n._currentValue=o;break;case 13:if(null!==(n=t.memoizedState))return null!==n.dehydrated?(Ao(la,1&la.current),t.flags|=128,null):0!=(i&t.child.childLanes)?Bs(e,t,i):(Ao(la,1&la.current),null!==(e=Gs(e,t,i))?e.sibling:null);Ao(la,1&la.current);break;case 19:if(n=0!=(i&t.childLanes),0!=(128&e.flags)){if(n)return Zs(e,t,i);t.flags|=128}if(null!==(o=t.memoizedState)&&(o.rendering=null,o.tail=null,o.lastEffect=null),Ao(la,la.current),n)break;return null;case 22:case 23:return t.lanes=0,ws(e,t,i)}return Gs(e,t,i)}(e,t,i);Cs=0!=(131072&e.flags)}else Cs=!1,rr&&0!=(1048576&t.flags)&&er(t,Wo,t.index);switch(t.lanes=0,t.tag){case 2:var n=t.type;Vs(e,t),e=t.pendingProps;var o=_o(t,ko.current);Or(t,i),o=wa(null,t,n,e,o,i);var a=Oa();return t.flags|=1,"object"==typeof o&&null!==o&&"function"==typeof o.render&&void 0===o.$$typeof?(t.tag=1,t.memoizedState=null,t.updateQueue=null,No(n)?(a=!0,Bo(t)):a=!1,t.memoizedState=null!==o.state&&void 0!==o.state?o.state:null,_r(t),o.updater=Zr,t.stateNode=o,o._reactInternals=t,zr(t,n,e,i),t=Es(null,t,n,!0,a,i)):(t.tag=0,rr&&a&&tr(t),bs(null,t,o,i),t=t.child),t;case 16:n=t.elementType;e:{switch(Vs(e,t),e=t.pendingProps,n=(o=n._init)(n._payload),t.type=n,o=t.tag=function(e){if("function"==typeof e)return _c(e)?1:0;if(null!=e){if((e=e.$$typeof)===E)return 11;if(e===D)return 14}return 2}(n),e=vr(n,e),o){case 0:t=Ps(null,t,n,e,i);break e;case 1:t=As(null,t,n,e,i);break e;case 11:t=Ss(null,t,n,e,i);break e;case 14:t=xs(null,t,n,vr(n.type,e),i);break e}throw Error(r(306,n,""))}return t;case 0:return n=t.type,o=t.pendingProps,Ps(e,t,n,o=t.elementType===n?o:vr(n,o),i);case 1:return n=t.type,o=t.pendingProps,As(e,t,n,o=t.elementType===n?o:vr(n,o),i);case 3:e:{if(ks(t),null===e)throw Error(r(387));n=t.pendingProps,o=(a=t.memoizedState).element,Nr(e,t),Fr(t,n,null,i);var s=t.memoizedState;if(n=s.element,a.isDehydrated){if(a={element:n,isDehydrated:!1,cache:s.cache,pendingSuspenseBoundaries:s.pendingSuspenseBoundaries,transitions:s.transitions},t.updateQueue.baseState=a,t.memoizedState=a,256&t.flags){t=Is(e,t,n,i,o=ds(Error(r(423)),t));break e}if(n!==o){t=Is(e,t,n,i,o=ds(Error(r(424)),t));break e}for(or=co(t.stateNode.containerInfo.firstChild),nr=t,rr=!0,ar=null,i=Jr(t,null,n,i),t.child=i;i;)i.flags=-3&i.flags|4096,i=i.sibling}else{if(gr(),n===o){t=Gs(e,t,i);break e}bs(e,t,n,i)}t=t.child}return t;case 5:return aa(t),null===e&&dr(t),n=t.type,o=t.pendingProps,a=null!==e?e.memoizedProps:null,s=o.children,io(n,o)?s=null:null!==a&&io(n,a)&&(t.flags|=32),Os(e,t),bs(e,t,s,i),t.child;case 6:return null===e&&dr(t),null;case 13:return Bs(e,t,i);case 4:return oa(t,t.stateNode.containerInfo),n=t.pendingProps,null===e?t.child=Xr(t,null,n,i):bs(e,t,n,i),t.child;case 11:return n=t.type,o=t.pendingProps,Ss(e,t,n,o=t.elementType===n?o:vr(n,o),i);case 7:return bs(e,t,t.pendingProps,i),t.child;case 8:case 12:return bs(e,t,t.pendingProps.children,i),t.child;case 10:e:{if(n=t.type._context,o=t.pendingProps,a=t.memoizedProps,s=o.value,Ao(yr,n._currentValue),n._currentValue=s,null!==a)if(sn(a.value,s)){if(a.children===o.children&&!Io.current){t=Gs(e,t,i);break e}}else for(null!==(a=t.child)&&(a.return=t);null!==a;){var l=a.dependencies;if(null!==l){s=a.child;for(var c=l.firstContext;null!==c;){if(c.context===n){if(1===a.tag){(c=Rr(-1,i&-i)).tag=2;var d=a.updateQueue;if(null!==d){var u=(d=d.shared).pending;null===u?c.next=c:(c.next=u.next,u.next=c),d.pending=c}}a.lanes|=i,null!==(c=a.alternate)&&(c.lanes|=i),wr(a.return,i,t),l.lanes|=i;break}c=c.next}}else if(10===a.tag)s=a.type===t.type?null:a.child;else if(18===a.tag){if(null===(s=a.return))throw Error(r(341));s.lanes|=i,null!==(l=s.alternate)&&(l.lanes|=i),wr(s,i,t),s=a.sibling}else s=a.child;if(null!==s)s.return=a;else for(s=a;null!==s;){if(s===t){s=null;break}if(null!==(a=s.sibling)){a.return=s.return,s=a;break}s=s.return}a=s}bs(e,t,o.children,i),t=t.child}return t;case 9:return o=t.type,n=t.pendingProps.children,Or(t,i),n=n(o=Pr(o)),t.flags|=1,bs(e,t,n,i),t.child;case 14:return o=vr(n=t.type,t.pendingProps),xs(e,t,n,o=vr(n.type,o),i);case 15:return Ts(e,t,t.type,t.pendingProps,i);case 17:return n=t.type,o=t.pendingProps,o=t.elementType===n?o:vr(n,o),Vs(e,t),t.tag=1,No(n)?(e=!0,Bo(t)):e=!1,Or(t,i),Gr(t,n,o),zr(t,n,o,i),Es(null,t,n,!0,e,i);case 19:return Zs(e,t,i);case 22:return ws(e,t,i)}throw Error(r(156,t.tag))};var Wc="function"==typeof reportError?reportError:function(e){};function Kc(e){this._internalRoot=e}function qc(e){this._internalRoot=e}function Yc(e){return!(!e||1!==e.nodeType&&9!==e.nodeType&&11!==e.nodeType)}function Xc(e){return!(!e||1!==e.nodeType&&9!==e.nodeType&&11!==e.nodeType&&(8!==e.nodeType||" react-mount-point-unstable "!==e.nodeValue))}function Jc(){}function Qc(e,t,i,n,o){var r=i._reactRootContainer;if(r){var a=r;if("function"==typeof o){var s=o;o=function(){var e=Gc(a);s.call(e)}}Vc(t,a,e,o)}else a=function(e,t,i,n,o){if(o){if("function"==typeof n){var r=n;n=function(){var e=Gc(a);r.call(e)}}var a=Zc(t,n,e,0,null,!1,0,"",Jc);return e._reactRootContainer=a,e[fo]=a.current,Zn(8===e.nodeType?e.parentNode:e),dc(),a}for(;o=e.lastChild;)e.removeChild(o);if("function"==typeof n){var s=n;n=function(){var e=Gc(l);s.call(e)}}var l=Hc(e,0,!1,null,0,!1,0,"",Jc);return e._reactRootContainer=l,e[fo]=l.current,Zn(8===e.nodeType?e.parentNode:e),dc((function(){Vc(t,l,i,n)})),l}(i,t,e,o,n);return Gc(a)}qc.prototype.render=Kc.prototype.render=function(e){var t=this._internalRoot;if(null===t)throw Error(r(409));Vc(e,t,null,null)},qc.prototype.unmount=Kc.prototype.unmount=function(){var e=this._internalRoot;if(null!==e){this._internalRoot=null;var t=e.containerInfo;dc((function(){Vc(null,e,null,null)})),t[fo]=null}},qc.prototype.unstable_scheduleHydration=function(e){if(e){var t=wt();e={blockedOn:null,target:e,priority:t};for(var i=0;i<Nt.length&&0!==t&&t<Nt[i].priority;i++);Nt.splice(i,0,e),0===i&&Bt(e)}},St=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var i=ut(t.pendingLanes);0!==i&&(yt(t,1|i),nc(t,Xe()),0==(6&El)&&(Zl=Xe()+500,Vo()))}break;case 13:dc((function(){var t=Ir(e,1);if(null!==t){var i=ec();ic(t,e,1,i)}})),zc(e,1)}},xt=function(e){if(13===e.tag){var t=Ir(e,134217728);null!==t&&ic(t,e,134217728,ec()),zc(e,134217728)}},Tt=function(e){if(13===e.tag){var t=tc(e),i=Ir(e,t);null!==i&&ic(i,e,t,ec()),zc(e,t)}},wt=function(){return Ct},Ot=function(e,t){var i=Ct;try{return Ct=e,t()}finally{Ct=i}},xe=function(e,t,i){switch(t){case"input":if(J(e,i),t=i.name,"radio"===i.type&&null!=t){for(i=e;i.parentNode;)i=i.parentNode;for(i=i.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<i.length;t++){var n=i[t];if(n!==e&&n.form===e.form){var o=xo(n);if(!o)throw Error(r(90));W(n),J(n,o)}}}break;case"textarea":re(e,i);break;case"select":null!=(t=i.value)&&ie(e,!!i.multiple,t,!1)}},Ee=cc,ke=dc;var ed={usingClientEntryPoint:!1,Events:[bo,So,xo,Pe,Ae,cc]},td={findFiberByHostInstance:Co,bundleType:0,version:"18.2.0",rendererPackageName:"react-dom"},id={bundleType:td.bundleType,version:td.version,rendererPackageName:td.rendererPackageName,rendererConfig:td.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:b.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return null===(e=je(e))?null:e.stateNode},findFiberByHostInstance:td.findFiberByHostInstance||function(){return null},findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.2.0-next-9e3b772b8-20220608"};if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__){var nd=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!nd.isDisabled&&nd.supportsFiber)try{ot=nd.inject(id),rt=nd}catch(de){}}t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=ed,t.createPortal=function(e,t){var i=2<arguments.length&&void 0!==arguments[2]?arguments[2]:null;if(!Yc(t))throw Error(r(200));return function(e,t,i){var n=3<arguments.length&&void 0!==arguments[3]?arguments[3]:null;return{$$typeof:x,key:null==n?null:""+n,children:e,containerInfo:t,implementation:i}}(e,t,null,i)},t.createRoot=function(e,t){if(!Yc(e))throw Error(r(299));var i=!1,n="",o=Wc;return null!=t&&(!0===t.unstable_strictMode&&(i=!0),void 0!==t.identifierPrefix&&(n=t.identifierPrefix),void 0!==t.onRecoverableError&&(o=t.onRecoverableError)),t=Hc(e,1,!1,null,0,i,0,n,o),e[fo]=t.current,Zn(8===e.nodeType?e.parentNode:e),new Kc(t)},t.findDOMNode=function(e){if(null==e)return null;if(1===e.nodeType)return e;var t=e._reactInternals;if(void 0===t){if("function"==typeof e.render)throw Error(r(188));throw e=Object.keys(e).join(","),Error(r(268,e))}return null===(e=je(t))?null:e.stateNode},t.flushSync=function(e){return dc(e)},t.hydrate=function(e,t,i){if(!Xc(t))throw Error(r(200));return Qc(null,e,t,!0,i)},t.hydrateRoot=function(e,t,i){if(!Yc(e))throw Error(r(405));var n=null!=i&&i.hydratedSources||null,o=!1,a="",s=Wc;if(null!=i&&(!0===i.unstable_strictMode&&(o=!0),void 0!==i.identifierPrefix&&(a=i.identifierPrefix),void 0!==i.onRecoverableError&&(s=i.onRecoverableError)),t=Zc(t,null,e,1,null!=i?i:null,o,0,a,s),e[fo]=t.current,Zn(e),n)for(e=0;e<n.length;e++)o=(o=(i=n[e])._getVersion)(i._source),null==t.mutableSourceEagerHydrationData?t.mutableSourceEagerHydrationData=[i,o]:t.mutableSourceEagerHydrationData.push(i,o);return new qc(t)},t.render=function(e,t,i){if(!Xc(t))throw Error(r(200));return Qc(null,e,t,!1,i)},t.unmountComponentAtNode=function(e){if(!Xc(e))throw Error(r(40));return!!e._reactRootContainer&&(dc((function(){Qc(null,null,e,!1,(function(){e._reactRootContainer=null,e[fo]=null}))})),!0)},t.unstable_batchedUpdates=cc,t.unstable_renderSubtreeIntoContainer=function(e,t,i,n){if(!Xc(i))throw Error(r(200));if(null==e||void 0===e._reactInternals)throw Error(r(38));return Qc(e,t,i,!1,n)},t.version="18.2.0-next-9e3b772b8-20220608"},43763:function(e,t,i){"use strict";!function e(){if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE)try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(e){}}(),e.exports=i(76539)},39711:function(e,t,i){"use strict";var n,o;n=i(69788),o=i(24221),t.version=n.version,t.renderToString=n.renderToString,t.renderToStaticMarkup=n.renderToStaticMarkup,t.renderToNodeStream=n.renderToNodeStream,t.renderToStaticNodeStream=n.renderToStaticNodeStream,t.renderToReadableStream=o.renderToReadableStream},94055:function(e,t){"use strict";var i="function"==typeof Symbol&&Symbol.for,n=i?Symbol.for("react.element"):60103,o=i?Symbol.for("react.portal"):60106,r=i?Symbol.for("react.fragment"):60107,a=i?Symbol.for("react.strict_mode"):60108,s=i?Symbol.for("react.profiler"):60114,l=i?Symbol.for("react.provider"):60109,c=i?Symbol.for("react.context"):60110,d=i?Symbol.for("react.async_mode"):60111,u=i?Symbol.for("react.concurrent_mode"):60111,h=i?Symbol.for("react.forward_ref"):60112,p=i?Symbol.for("react.suspense"):60113,g=i?Symbol.for("react.suspense_list"):60120,f=i?Symbol.for("react.memo"):60115,m=i?Symbol.for("react.lazy"):60116,v=i?Symbol.for("react.block"):60121,y=i?Symbol.for("react.fundamental"):60117,C=i?Symbol.for("react.responder"):60118,b=i?Symbol.for("react.scope"):60119;function S(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case n:switch(e=e.type){case d:case u:case r:case s:case a:case p:return e;default:switch(e=e&&e.$$typeof){case c:case h:case m:case f:case l:return e;default:return t}}case o:return t}}}function x(e){return S(e)===u}t.AsyncMode=d,t.ConcurrentMode=u,t.ContextConsumer=c,t.ContextProvider=l,t.Element=n,t.ForwardRef=h,t.Fragment=r,t.Lazy=m,t.Memo=f,t.Portal=o,t.Profiler=s,t.StrictMode=a,t.Suspense=p,t.isAsyncMode=function(e){return x(e)||S(e)===d},t.isConcurrentMode=x,t.isContextConsumer=function(e){return S(e)===c},t.isContextProvider=function(e){return S(e)===l},t.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===n},t.isForwardRef=function(e){return S(e)===h},t.isFragment=function(e){return S(e)===r},t.isLazy=function(e){return S(e)===m},t.isMemo=function(e){return S(e)===f},t.isPortal=function(e){return S(e)===o},t.isProfiler=function(e){return S(e)===s},t.isStrictMode=function(e){return S(e)===a},t.isSuspense=function(e){return S(e)===p},t.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===r||e===u||e===s||e===a||e===p||e===g||"object"==typeof e&&null!==e&&(e.$$typeof===m||e.$$typeof===f||e.$$typeof===l||e.$$typeof===c||e.$$typeof===h||e.$$typeof===y||e.$$typeof===C||e.$$typeof===b||e.$$typeof===v)},t.typeOf=S},37787:function(e,t,i){"use strict";e.exports=i(94055)},81304:function(e,t,i){"use strict";function n(){var e=this.constructor.getDerivedStateFromProps(this.props,this.state);null!=e&&this.setState(e)}function o(e){this.setState(function(t){var i=this.constructor.getDerivedStateFromProps(e,t);return null!=i?i:null}.bind(this))}function r(e,t){try{var i=this.props,n=this.state;this.props=e,this.state=t,this.__reactInternalSnapshotFlag=!0,this.__reactInternalSnapshot=this.getSnapshotBeforeUpdate(i,n)}finally{this.props=i,this.state=n}}function a(e){var t=e.prototype;if(!t||!t.isReactComponent)throw new Error("Can only polyfill class components");if("function"!=typeof e.getDerivedStateFromProps&&"function"!=typeof t.getSnapshotBeforeUpdate)return e;var i=null,a=null,s=null;if("function"==typeof t.componentWillMount?i="componentWillMount":"function"==typeof t.UNSAFE_componentWillMount&&(i="UNSAFE_componentWillMount"),"function"==typeof t.componentWillReceiveProps?a="componentWillReceiveProps":"function"==typeof t.UNSAFE_componentWillReceiveProps&&(a="UNSAFE_componentWillReceiveProps"),"function"==typeof t.componentWillUpdate?s="componentWillUpdate":"function"==typeof t.UNSAFE_componentWillUpdate&&(s="UNSAFE_componentWillUpdate"),null!==i||null!==a||null!==s){var l=e.displayName||e.name,c="function"==typeof e.getDerivedStateFromProps?"getDerivedStateFromProps()":"getSnapshotBeforeUpdate()";throw Error("Unsafe legacy lifecycles will not be called for components using new component APIs.\n\n"+l+" uses "+c+" but also contains the following legacy lifecycles:"+(null!==i?"\n "+i:"")+(null!==a?"\n "+a:"")+(null!==s?"\n "+s:"")+"\n\nThe above lifecycles should be removed. Learn more about this warning here:\nhttps://fb.me/react-async-component-lifecycle-hooks")}if("function"==typeof e.getDerivedStateFromProps&&(t.componentWillMount=n,t.componentWillReceiveProps=o),"function"==typeof t.getSnapshotBeforeUpdate){if("function"!=typeof t.componentDidUpdate)throw new Error("Cannot polyfill getSnapshotBeforeUpdate() for components that do not define componentDidUpdate() on the prototype");t.componentWillUpdate=r;var d=t.componentDidUpdate;t.componentDidUpdate=function(e,t,i){var n=this.__reactInternalSnapshotFlag?this.__reactInternalSnapshot:i;d.call(this,e,t,n)}}return e}i.r(t),i.d(t,{polyfill:function(){return a}}),n.__suppressDeprecationWarning=!0,o.__suppressDeprecationWarning=!0,r.__suppressDeprecationWarning=!0},90480:function(e,t,i){"use strict";i.r(t),i.d(t,{AnimateGroup:function(){return Ze},configBezier:function(){return Q},configSpring:function(){return ee},default:function(){return Ve},translateStyle:function(){return j}});var n=i(8559),o=i(25286),r=i.n(o),a=Object.getOwnPropertyNames,s=Object.getOwnPropertySymbols,l=Object.prototype.hasOwnProperty;function c(e,t){return function(i,n,o){return e(i,n,o)&&t(i,n,o)}}function d(e){return function(t,i,n){if(!t||!i||"object"!=typeof t||"object"!=typeof i)return e(t,i,n);var o=n.cache,r=o.get(t),a=o.get(i);if(r&&a)return r===i&&a===t;o.set(t,i),o.set(i,t);var s=e(t,i,n);return o.delete(t),o.delete(i),s}}function u(e){return a(e).concat(s(e))}var h=Object.hasOwn||function(e,t){return l.call(e,t)};function p(e,t){return e||t?e===t:e===t||e!=e&&t!=t}var g="_owner",f=Object.getOwnPropertyDescriptor,m=Object.keys;function v(e,t,i){var n=e.length;if(t.length!==n)return!1;for(;n-- >0;)if(!i.equals(e[n],t[n],n,n,e,t,i))return!1;return!0}function y(e,t){return p(e.getTime(),t.getTime())}function C(e,t,i){if(e.size!==t.size)return!1;for(var n,o,r={},a=e.entries(),s=0;(n=a.next())&&!n.done;){for(var l=t.entries(),c=!1,d=0;(o=l.next())&&!o.done;){var u=n.value,h=u[0],p=u[1],g=o.value,f=g[0],m=g[1];c||r[d]||!(c=i.equals(h,f,s,d,e,t,i)&&i.equals(p,m,h,f,e,t,i))||(r[d]=!0),d++}if(!c)return!1;s++}return!0}function b(e,t,i){var n,o=m(e),r=o.length;if(m(t).length!==r)return!1;for(;r-- >0;){if((n=o[r])===g&&(e.$$typeof||t.$$typeof)&&e.$$typeof!==t.$$typeof)return!1;if(!h(t,n)||!i.equals(e[n],t[n],n,n,e,t,i))return!1}return!0}function S(e,t,i){var n,o,r,a=u(e),s=a.length;if(u(t).length!==s)return!1;for(;s-- >0;){if((n=a[s])===g&&(e.$$typeof||t.$$typeof)&&e.$$typeof!==t.$$typeof)return!1;if(!h(t,n))return!1;if(!i.equals(e[n],t[n],n,n,e,t,i))return!1;if(o=f(e,n),r=f(t,n),(o||r)&&(!o||!r||o.configurable!==r.configurable||o.enumerable!==r.enumerable||o.writable!==r.writable))return!1}return!0}function x(e,t){return p(e.valueOf(),t.valueOf())}function T(e,t){return e.source===t.source&&e.flags===t.flags}function w(e,t,i){if(e.size!==t.size)return!1;for(var n,o,r={},a=e.values();(n=a.next())&&!n.done;){for(var s=t.values(),l=!1,c=0;(o=s.next())&&!o.done;)l||r[c]||!(l=i.equals(n.value,o.value,n.value,o.value,e,t,i))||(r[c]=!0),c++;if(!l)return!1}return!0}function O(e,t){var i=e.length;if(t.length!==i)return!1;for(;i-- >0;)if(e[i]!==t[i])return!1;return!0}var P=Array.isArray,A="function"==typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView:null,E=Object.assign,k=Object.prototype.toString.call.bind(Object.prototype.toString),I=D();function D(e){void 0===e&&(e={});var t,i=e.circular,n=void 0!==i&&i,o=e.createInternalComparator,r=e.createState,a=e.strict,s=void 0!==a&&a,l=function(e){var t=e.circular,i=e.createCustomConfig,n=e.strict,o={areArraysEqual:n?S:v,areDatesEqual:y,areMapsEqual:n?c(C,S):C,areObjectsEqual:n?S:b,arePrimitiveWrappersEqual:x,areRegExpsEqual:T,areSetsEqual:n?c(w,S):w,areTypedArraysEqual:n?S:O};if(i&&(o=E({},o,i(o))),t){var r=d(o.areArraysEqual),a=d(o.areMapsEqual),s=d(o.areObjectsEqual),l=d(o.areSetsEqual);o=E({},o,{areArraysEqual:r,areMapsEqual:a,areObjectsEqual:s,areSetsEqual:l})}return o}(e),u=function(e){var t=e.areArraysEqual,i=e.areDatesEqual,n=e.areMapsEqual,o=e.areObjectsEqual,r=e.arePrimitiveWrappersEqual,a=e.areRegExpsEqual,s=e.areSetsEqual,l=e.areTypedArraysEqual;return function(e,c,d){if(e===c)return!0;if(null==e||null==c||"object"!=typeof e||"object"!=typeof c)return e!=e&&c!=c;var u=e.constructor;if(u!==c.constructor)return!1;if(u===Object)return o(e,c,d);if(P(e))return t(e,c,d);if(null!=A&&A(e))return l(e,c,d);if(u===Date)return i(e,c,d);if(u===RegExp)return a(e,c,d);if(u===Map)return n(e,c,d);if(u===Set)return s(e,c,d);var h=k(e);return"[object Date]"===h?i(e,c,d):"[object RegExp]"===h?a(e,c,d):"[object Map]"===h?n(e,c,d):"[object Set]"===h?s(e,c,d):"[object Object]"===h?"function"!=typeof e.then&&"function"!=typeof c.then&&o(e,c,d):"[object Arguments]"===h?o(e,c,d):("[object Boolean]"===h||"[object Number]"===h||"[object String]"===h)&&r(e,c,d)}}(l);return function(e){var t=e.circular,i=e.comparator,n=e.createState,o=e.equals,r=e.strict;if(n)return function(e,a){var s=n(),l=s.cache,c=void 0===l?t?new WeakMap:void 0:l,d=s.meta;return i(e,a,{cache:c,equals:o,meta:d,strict:r})};if(t)return function(e,t){return i(e,t,{cache:new WeakMap,equals:o,meta:void 0,strict:r})};var a={cache:void 0,equals:o,meta:void 0,strict:r};return function(e,t){return i(e,t,a)}}({circular:n,comparator:u,createState:r,equals:o?o(u):(t=u,function(e,i,n,o,r,a,s){return t(e,i,s)}),strict:s})}function _(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=-1;requestAnimationFrame((function n(o){i<0&&(i=o),o-i>t?(e(o),i=-1):function(e){"undefined"!=typeof requestAnimationFrame&&requestAnimationFrame(e)}(n)}))}function N(e){return N="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},N(e)}function R(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}function M(){var e=function(){return null},t=!1,i=function i(n){if(!t){if(Array.isArray(n)){if(!n.length)return;var o=function(e){if(Array.isArray(e))return e}(s=n)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(s)||function(e,t){if(e){if("string"==typeof e)return R(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?R(e,t):void 0}}(s)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}(),r=o[0],a=o.slice(1);return"number"==typeof r?void _(i.bind(null,a),r):(i(r),void _(i.bind(null,a)))}"object"===N(n)&&e(n),"function"==typeof n&&n()}var s};return{stop:function(){t=!0},start:function(e){t=!1,i(e)},subscribe:function(t){return e=t,function(){e=function(){return null}}}}}function L(e){return L="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},L(e)}function B(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function F(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?B(Object(i),!0).forEach((function(t){U(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):B(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function U(e,t,i){return(t=function(e){var t=function(e,t){if("object"!==L(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==L(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===L(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}D({strict:!0}),D({circular:!0}),D({circular:!0,strict:!0}),D({createInternalComparator:function(){return p}}),D({strict:!0,createInternalComparator:function(){return p}}),D({circular:!0,createInternalComparator:function(){return p}}),D({circular:!0,createInternalComparator:function(){return p},strict:!0});var H=["Webkit","Moz","O","ms"],$=["-webkit-","-moz-","-o-","-ms-"],Z=["transform","transformOrigin","transition"],V=function(e){return e},G=function(e,t){return Object.keys(t).reduce((function(i,n){return F(F({},i),{},U({},n,e(n,t[n])))}),{})},j=function(e){return Object.keys(e).reduce((function(e,t){return F(F({},e),function(e,t){if(-1===Z.indexOf(e))return U({},e,Number.isNaN(t)?0:t);var i="transition"===e,n=e.replace(/(\w)/,(function(e){return e.toUpperCase()})),o=t;return H.reduce((function(e,r,a){return i&&(o=t.replace(/(transform|transform-origin)/gim,"".concat($[a],"$1"))),F(F({},e),{},U({},r+n,o))}),{})}(t,e[t]))}),e)},z=function(e,t,i){return e.map((function(e){return"".concat((n=e,n.replace(/([A-Z])/g,(function(e){return"-".concat(e.toLowerCase())})))," ").concat(t,"ms ").concat(i);var n})).join(",")};function W(e,t){if(e){if("string"==typeof e)return K(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?K(e,t):void 0}}function K(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}var q=1e-4,Y=function(e,t){return[0,3*e,3*t-6*e,3*e-3*t+1]},X=function(e,t){return e.map((function(e,i){return e*Math.pow(t,i)})).reduce((function(e,t){return e+t}))},J=function(e,t){return function(i){var n=Y(e,t);return X(n,i)}},Q=function(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];var n,o,r=t[0],a=t[1],s=t[2],l=t[3];if(1===t.length)switch(t[0]){case"linear":r=0,a=0,s=1,l=1;break;case"ease":r=.25,a=.1,s=.25,l=1;break;case"ease-in":r=.42,a=0,s=1,l=1;break;case"ease-out":r=.42,a=0,s=.58,l=1;break;case"ease-in-out":r=0,a=0,s=.58,l=1;break;default:var c=t[0].split("(");if("cubic-bezier"===c[0]&&4===c[1].split(")")[0].split(",").length){var d=(n=c[1].split(")")[0].split(",").map((function(e){return parseFloat(e)})),o=4,function(e){if(Array.isArray(e))return e}(n)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var n,o,r,a,s=[],l=!0,c=!1;try{if(r=(i=i.call(e)).next,0===t){if(Object(i)!==i)return;l=!1}else for(;!(l=(n=r.call(i)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=i.return&&(a=i.return(),Object(a)!==a))return}finally{if(c)throw o}}return s}}(n,o)||W(n,o)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}());r=d[0],a=d[1],s=d[2],l=d[3]}}[r,s,a,l].every((function(e){return"number"==typeof e&&e>=0&&e<=1}));var u,h,p=J(r,s),g=J(a,l),f=(u=r,h=s,function(e){var t=Y(u,h),i=[].concat(function(e){return function(e){if(Array.isArray(e))return K(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||W(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(t.map((function(e,t){return e*t})).slice(1)),[0]);return X(i,e)}),m=function(e){for(var t,i=e>1?1:e,n=i,o=0;o<8;++o){var r=p(n)-i,a=f(n);if(Math.abs(r-i)<q||a<q)return g(n);n=(t=n-r/a)>1?1:t<0?0:t}return g(n)};return m.isStepper=!1,m},ee=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.stiff,i=void 0===t?100:t,n=e.damping,o=void 0===n?8:n,r=e.dt,a=void 0===r?17:r,s=function(e,t,n){var r=n+(-(e-t)*i-n*o)*a/1e3,s=n*a/1e3+e;return Math.abs(s-t)<q&&Math.abs(r)<q?[t,0]:[s,r]};return s.isStepper=!0,s.dt=a,s};function te(e){return te="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},te(e)}function ie(e){return function(e){if(Array.isArray(e))return se(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||ae(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function ne(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function oe(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?ne(Object(i),!0).forEach((function(t){re(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):ne(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function re(e,t,i){return(t=function(e){var t=function(e,t){if("object"!==te(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==te(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===te(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function ae(e,t){if(e){if("string"==typeof e)return se(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?se(e,t):void 0}}function se(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}var le=function(e,t,i){return e+(t-e)*i},ce=function(e){return e.from!==e.to},de=function e(t,i,n){var o=G((function(e,i){if(ce(i)){var n=(a=t(i.from,i.to,i.velocity),s=2,function(e){if(Array.isArray(e))return e}(a)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var n,o,r,a,s=[],l=!0,c=!1;try{if(r=(i=i.call(e)).next,0===t){if(Object(i)!==i)return;l=!1}else for(;!(l=(n=r.call(i)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=i.return&&(a=i.return(),Object(a)!==a))return}finally{if(c)throw o}}return s}}(a,s)||ae(a,s)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),o=n[0],r=n[1];return oe(oe({},i),{},{from:o,velocity:r})}var a,s;return i}),i);return n<1?G((function(e,t){return ce(t)?oe(oe({},t),{},{velocity:le(t.velocity,o[e].velocity,n),from:le(t.from,o[e].from,n)}):t}),i):e(t,o,n-1)};function ue(e){return ue="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},ue(e)}var he=["children","begin","duration","attributeName","easing","isActive","steps","from","to","canBegin","onAnimationEnd","shouldReAnimate","onAnimationReStart"];function pe(e){return function(e){if(Array.isArray(e))return ge(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return ge(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?ge(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function ge(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}function fe(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function me(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?fe(Object(i),!0).forEach((function(t){ve(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):fe(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function ve(e,t,i){return(t=Ce(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function ye(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,Ce(n.key),n)}}function Ce(e){var t=function(e,t){if("object"!==ue(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==ue(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===ue(t)?t:String(t)}function be(e,t){return be=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},be(e,t)}function Se(e,t){if(t&&("object"===ue(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return xe(e)}function xe(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Te(e){return Te=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Te(e)}var we=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&be(e,t)}(s,e);var t,i,o,r,a=(o=s,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=Te(o);if(r){var i=Te(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return Se(this,e)});function s(e,t){var i;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s);var n=(i=a.call(this,e,t)).props,o=n.isActive,r=n.attributeName,l=n.from,c=n.to,d=n.steps,u=n.children,h=n.duration;if(i.handleStyleChange=i.handleStyleChange.bind(xe(i)),i.changeStyle=i.changeStyle.bind(xe(i)),!o||h<=0)return i.state={style:{}},"function"==typeof u&&(i.state={style:c}),Se(i);if(d&&d.length)i.state={style:d[0].style};else if(l){if("function"==typeof u)return i.state={style:l},Se(i);i.state={style:r?ve({},r,l):l}}else i.state={style:{}};return i}return t=s,i=[{key:"componentDidMount",value:function(){var e=this.props,t=e.isActive,i=e.canBegin;this.mounted=!0,t&&i&&this.runAnimation(this.props)}},{key:"componentDidUpdate",value:function(e){var t=this.props,i=t.isActive,n=t.canBegin,o=t.attributeName,r=t.shouldReAnimate,a=t.to,s=t.from,l=this.state.style;if(n)if(i){if(!(I(e.to,a)&&e.canBegin&&e.isActive)){var c=!e.canBegin||!e.isActive;this.manager&&this.manager.stop(),this.stopJSAnimation&&this.stopJSAnimation();var d=c||r?s:e.to;if(this.state&&l){var u={style:o?ve({},o,d):d};(o&&[o]!==d||!o&&l!==d)&&this.setState(u)}this.runAnimation(me(me({},this.props),{},{from:d,begin:0}))}}else{var h={style:o?ve({},o,a):a};this.state&&l&&(o&&l[o]!==a||!o&&l!==a)&&this.setState(h)}}},{key:"componentWillUnmount",value:function(){this.mounted=!1;var e=this.props.onAnimationEnd;this.unSubscribe&&this.unSubscribe(),this.manager&&(this.manager.stop(),this.manager=null),this.stopJSAnimation&&this.stopJSAnimation(),e&&e()}},{key:"handleStyleChange",value:function(e){this.changeStyle(e)}},{key:"changeStyle",value:function(e){this.mounted&&this.setState({style:e})}},{key:"runJSAnimation",value:function(e){var t=this,i=e.from,n=e.to,o=e.duration,r=e.easing,a=e.begin,s=e.onAnimationEnd,l=e.onAnimationStart,c=function(e,t,i,n,o){var r,a,s,l,c=(r=e,a=t,[Object.keys(r),Object.keys(a)].reduce((function(e,t){return e.filter((function(e){return t.includes(e)}))}))),d=c.reduce((function(i,n){return oe(oe({},i),{},re({},n,[e[n],t[n]]))}),{}),u=c.reduce((function(i,n){return oe(oe({},i),{},re({},n,{from:e[n],velocity:0,to:t[n]}))}),{}),h=-1,p=function(){return null};return p=i.isStepper?function(n){s||(s=n);var r=(n-s)/i.dt;u=de(i,u,r),o(oe(oe(oe({},e),t),G((function(e,t){return t.from}),u))),s=n,Object.values(u).filter(ce).length&&(h=requestAnimationFrame(p))}:function(r){l||(l=r);var a=(r-l)/n,s=G((function(e,t){return le.apply(void 0,ie(t).concat([i(a)]))}),d);if(o(oe(oe(oe({},e),t),s)),a<1)h=requestAnimationFrame(p);else{var c=G((function(e,t){return le.apply(void 0,ie(t).concat([i(1)]))}),d);o(oe(oe(oe({},e),t),c))}},function(){return requestAnimationFrame(p),function(){cancelAnimationFrame(h)}}}(i,n,function(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];var n=t[0];if("string"==typeof n)switch(n){case"ease":case"ease-in-out":case"ease-out":case"ease-in":case"linear":return Q(n);case"spring":return ee();default:if("cubic-bezier"===n.split("(")[0])return Q(n)}return"function"==typeof n?n:null}(r),o,this.changeStyle);this.manager.start([l,a,function(){t.stopJSAnimation=c()},o,s])}},{key:"runStepAnimation",value:function(e){var t=this,i=e.steps,n=e.begin,o=e.onAnimationStart,r=i[0],a=r.style,s=r.duration,l=void 0===s?0:s;return this.manager.start([o].concat(pe(i.reduce((function(e,n,o){if(0===o)return e;var r=n.duration,a=n.easing,s=void 0===a?"ease":a,l=n.style,c=n.properties,d=n.onAnimationEnd,u=o>0?i[o-1]:n,h=c||Object.keys(l);if("function"==typeof s||"spring"===s)return[].concat(pe(e),[t.runJSAnimation.bind(t,{from:u.style,to:l,duration:r,easing:s}),r]);var p=z(h,r,s),g=me(me(me({},u.style),l),{},{transition:p});return[].concat(pe(e),[g,r,d]).filter(V)}),[a,Math.max(l,n)])),[e.onAnimationEnd]))}},{key:"runAnimation",value:function(e){this.manager||(this.manager=M());var t=e.begin,i=e.duration,n=e.attributeName,o=e.to,r=e.easing,a=e.onAnimationStart,s=e.onAnimationEnd,l=e.steps,c=e.children,d=this.manager;if(this.unSubscribe=d.subscribe(this.handleStyleChange),"function"!=typeof r&&"function"!=typeof c&&"spring"!==r)if(l.length>1)this.runStepAnimation(e);else{var u=n?ve({},n,o):o,h=z(Object.keys(u),i,r);d.start([a,t,me(me({},u),{},{transition:h}),i,s])}else this.runJSAnimation(e)}},{key:"render",value:function(){var e=this.props,t=e.children,i=(e.begin,e.duration),o=(e.attributeName,e.easing,e.isActive),r=(e.steps,e.from,e.to,e.canBegin,e.onAnimationEnd,e.shouldReAnimate,e.onAnimationReStart,function(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}(e,he)),a=n.Children.count(t),s=j(this.state.style);if("function"==typeof t)return t(s);if(!o||0===a||i<=0)return t;var l=function(e){var t=e.props,i=t.style,o=void 0===i?{}:i,a=t.className;return(0,n.cloneElement)(e,me(me({},r),{},{style:me(me({},o),s),className:a}))};return 1===a?l(n.Children.only(t)):n.createElement("div",null,n.Children.map(t,(function(e){return l(e)})))}}],i&&ye(t.prototype,i),Object.defineProperty(t,"prototype",{writable:!1}),s}(n.PureComponent);we.displayName="Animate",we.defaultProps={begin:0,duration:1e3,from:"",to:"",attributeName:"",easing:"ease",isActive:!0,canBegin:!0,steps:[],onAnimationEnd:function(){},onAnimationStart:function(){}},we.propTypes={from:r().oneOfType([r().object,r().string]),to:r().oneOfType([r().object,r().string]),attributeName:r().string,duration:r().number,begin:r().number,easing:r().oneOfType([r().string,r().func]),steps:r().arrayOf(r().shape({duration:r().number.isRequired,style:r().object.isRequired,easing:r().oneOfType([r().oneOf(["ease","ease-in","ease-out","ease-in-out","linear"]),r().func]),properties:r().arrayOf("string"),onAnimationEnd:r().func})),children:r().oneOfType([r().node,r().func]),isActive:r().bool,canBegin:r().bool,onAnimationEnd:r().func,shouldReAnimate:r().bool,onAnimationStart:r().func,onAnimationReStart:r().func};var Oe=we,Pe=i(59146),Ae=["children","appearOptions","enterOptions","leaveOptions"];function Ee(e){return Ee="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ee(e)}function ke(){return ke=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},ke.apply(this,arguments)}function Ie(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function De(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Ie(Object(i),!0).forEach((function(t){Le(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Ie(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function _e(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,Be(n.key),n)}}function Ne(e,t){return Ne=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},Ne(e,t)}function Re(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Me(e){return Me=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},Me(e)}function Le(e,t,i){return(t=Be(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function Be(e){var t=function(e,t){if("object"!==Ee(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==Ee(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===Ee(t)?t:String(t)}void 0===Number.isFinite&&(Number.isFinite=function(e){return"number"==typeof e&&isFinite(e)});var Fe=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.steps,i=e.duration;return t&&t.length?t.reduce((function(e,t){return e+(Number.isFinite(t.duration)&&t.duration>0?t.duration:0)}),0):Number.isFinite(i)?i:0},Ue=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Ne(e,t)}(s,e);var t,i,o,r,a=(o=s,r=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=Me(o);if(r){var i=Me(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===Ee(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return Re(e)}(this,e)});function s(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,s),Le(Re(e=a.call(this)),"handleEnter",(function(t,i){var n=e.props,o=n.appearOptions,r=n.enterOptions;e.handleStyleActive(i?o:r)})),Le(Re(e),"handleExit",(function(){var t=e.props.leaveOptions;e.handleStyleActive(t)})),e.state={isActive:!1},e}return t=s,(i=[{key:"handleStyleActive",value:function(e){if(e){var t=e.onAnimationEnd?function(){e.onAnimationEnd()}:null;this.setState(De(De({},e),{},{onAnimationEnd:t,isActive:!0}))}}},{key:"parseTimeout",value:function(){var e=this.props,t=e.appearOptions,i=e.enterOptions,n=e.leaveOptions;return Fe(t)+Fe(i)+Fe(n)}},{key:"render",value:function(){var e=this,t=this.props,i=t.children,o=(t.appearOptions,t.enterOptions,t.leaveOptions,function(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}(t,Ae));return n.createElement(Pe.Transition,ke({},o,{onEnter:this.handleEnter,onExit:this.handleExit,timeout:this.parseTimeout()}),(function(){return n.createElement(Oe,e.state,n.Children.only(i))}))}}])&&_e(t.prototype,i),Object.defineProperty(t,"prototype",{writable:!1}),s}(n.Component);Ue.propTypes={appearOptions:r().object,enterOptions:r().object,leaveOptions:r().object,children:r().element};var He=Ue;function $e(e){var t=e.component,i=e.children,o=e.appear,r=e.enter,a=e.leave;return n.createElement(Pe.TransitionGroup,{component:t},n.Children.map(i,(function(e,t){return n.createElement(He,{appearOptions:o,enterOptions:r,leaveOptions:a,key:"child-".concat(t)},e)})))}$e.propTypes={appear:r().object,enter:r().object,leave:r().object,children:r().oneOfType([r().array,r().element]),component:r().any},$e.defaultProps={component:"span"};var Ze=$e,Ve=Oe},32142:function(e,t,i){"use strict";var n=i(19097);t.__esModule=!0,t.default=function(e,t){e.classList?e.classList.add(t):(0,o.default)(e,t)||("string"==typeof e.className?e.className=e.className+" "+t:e.setAttribute("class",(e.className&&e.className.baseVal||"")+" "+t))};var o=n(i(14375));e.exports=t.default},14375:function(e,t){"use strict";t.__esModule=!0,t.default=function(e,t){return e.classList?!!t&&e.classList.contains(t):-1!==(" "+(e.className.baseVal||e.className)+" ").indexOf(" "+t+" ")},e.exports=t.default},27961:function(e){"use strict";function t(e,t){return e.replace(new RegExp("(^|\\s)"+t+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}e.exports=function(e,i){e.classList?e.classList.remove(i):"string"==typeof e.className?e.className=t(e.className,i):e.setAttribute("class",t(e.className&&e.className.baseVal||"",i))}},30673:function(e,t,i){"use strict";t.__esModule=!0,t.default=void 0,function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var n=Object.defineProperty&&Object.getOwnPropertyDescriptor?Object.getOwnPropertyDescriptor(e,i):{};n.get||n.set?Object.defineProperty(t,i,n):t[i]=e[i]}t.default=e}(i(25286));var n=s(i(32142)),o=s(i(27961)),r=s(i(8559)),a=s(i(37450));function s(e){return e&&e.__esModule?e:{default:e}}function l(){return l=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},l.apply(this,arguments)}i(94975);var c=function(e,t){return e&&t&&t.split(" ").forEach((function(t){return(0,n.default)(e,t)}))},d=function(e,t){return e&&t&&t.split(" ").forEach((function(t){return(0,o.default)(e,t)}))},u=function(e){var t,i;function n(){for(var t,i=arguments.length,n=new Array(i),o=0;o<i;o++)n[o]=arguments[o];return(t=e.call.apply(e,[this].concat(n))||this).onEnter=function(e,i){var n=t.getClassNames(i?"appear":"enter").className;t.removeClasses(e,"exit"),c(e,n),t.props.onEnter&&t.props.onEnter(e,i)},t.onEntering=function(e,i){var n=t.getClassNames(i?"appear":"enter").activeClassName;t.reflowAndAddClass(e,n),t.props.onEntering&&t.props.onEntering(e,i)},t.onEntered=function(e,i){var n=t.getClassNames("appear").doneClassName,o=t.getClassNames("enter").doneClassName,r=i?n+" "+o:o;t.removeClasses(e,i?"appear":"enter"),c(e,r),t.props.onEntered&&t.props.onEntered(e,i)},t.onExit=function(e){var i=t.getClassNames("exit").className;t.removeClasses(e,"appear"),t.removeClasses(e,"enter"),c(e,i),t.props.onExit&&t.props.onExit(e)},t.onExiting=function(e){var i=t.getClassNames("exit").activeClassName;t.reflowAndAddClass(e,i),t.props.onExiting&&t.props.onExiting(e)},t.onExited=function(e){var i=t.getClassNames("exit").doneClassName;t.removeClasses(e,"exit"),c(e,i),t.props.onExited&&t.props.onExited(e)},t.getClassNames=function(e){var i=t.props.classNames,n="string"==typeof i,o=n?(n&&i?i+"-":"")+e:i[e];return{className:o,activeClassName:n?o+"-active":i[e+"Active"],doneClassName:n?o+"-done":i[e+"Done"]}},t}i=e,(t=n).prototype=Object.create(i.prototype),t.prototype.constructor=t,t.__proto__=i;var o=n.prototype;return o.removeClasses=function(e,t){var i=this.getClassNames(t),n=i.className,o=i.activeClassName,r=i.doneClassName;n&&d(e,n),o&&d(e,o),r&&d(e,r)},o.reflowAndAddClass=function(e,t){t&&(e&&e.scrollTop,c(e,t))},o.render=function(){var e=l({},this.props);return delete e.classNames,r.default.createElement(a.default,l({},e,{onEnter:this.onEnter,onEntered:this.onEntered,onEntering:this.onEntering,onExit:this.onExit,onExiting:this.onExiting,onExited:this.onExited}))},n}(r.default.Component);u.defaultProps={classNames:""},u.propTypes={};var h=u;t.default=h,e.exports=t.default},93890:function(e,t,i){"use strict";t.__esModule=!0,t.default=void 0,a(i(25286));var n=a(i(8559)),o=i(43763),r=a(i(93868));function a(e){return e&&e.__esModule?e:{default:e}}var s=function(e){var t,i;function a(){for(var t,i=arguments.length,n=new Array(i),o=0;o<i;o++)n[o]=arguments[o];return(t=e.call.apply(e,[this].concat(n))||this).handleEnter=function(){for(var e=arguments.length,i=new Array(e),n=0;n<e;n++)i[n]=arguments[n];return t.handleLifecycle("onEnter",0,i)},t.handleEntering=function(){for(var e=arguments.length,i=new Array(e),n=0;n<e;n++)i[n]=arguments[n];return t.handleLifecycle("onEntering",0,i)},t.handleEntered=function(){for(var e=arguments.length,i=new Array(e),n=0;n<e;n++)i[n]=arguments[n];return t.handleLifecycle("onEntered",0,i)},t.handleExit=function(){for(var e=arguments.length,i=new Array(e),n=0;n<e;n++)i[n]=arguments[n];return t.handleLifecycle("onExit",1,i)},t.handleExiting=function(){for(var e=arguments.length,i=new Array(e),n=0;n<e;n++)i[n]=arguments[n];return t.handleLifecycle("onExiting",1,i)},t.handleExited=function(){for(var e=arguments.length,i=new Array(e),n=0;n<e;n++)i[n]=arguments[n];return t.handleLifecycle("onExited",1,i)},t}i=e,(t=a).prototype=Object.create(i.prototype),t.prototype.constructor=t,t.__proto__=i;var s=a.prototype;return s.handleLifecycle=function(e,t,i){var r,a=this.props.children,s=n.default.Children.toArray(a)[t];s.props[e]&&(r=s.props)[e].apply(r,i),this.props[e]&&this.props[e]((0,o.findDOMNode)(this))},s.render=function(){var e=this.props,t=e.children,i=e.in,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,["children","in"]),a=n.default.Children.toArray(t),s=a[0],l=a[1];return delete o.onEnter,delete o.onEntering,delete o.onEntered,delete o.onExit,delete o.onExiting,delete o.onExited,n.default.createElement(r.default,o,i?n.default.cloneElement(s,{key:"first",onEnter:this.handleEnter,onEntering:this.handleEntering,onEntered:this.handleEntered}):n.default.cloneElement(l,{key:"second",onEnter:this.handleExit,onEntering:this.handleExiting,onEntered:this.handleExited}))},a}(n.default.Component);s.propTypes={};var l=s;t.default=l,e.exports=t.default},37450:function(e,t,i){"use strict";t.__esModule=!0,t.default=t.EXITING=t.ENTERED=t.ENTERING=t.EXITED=t.UNMOUNTED=void 0;var n=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i)){var n=Object.defineProperty&&Object.getOwnPropertyDescriptor?Object.getOwnPropertyDescriptor(e,i):{};n.get||n.set?Object.defineProperty(t,i,n):t[i]=e[i]}return t.default=e,t}(i(25286)),o=s(i(8559)),r=s(i(43763)),a=i(81304);function s(e){return e&&e.__esModule?e:{default:e}}i(94975);var l="unmounted";t.UNMOUNTED=l;var c="exited";t.EXITED=c;var d="entering";t.ENTERING=d;var u="entered";t.ENTERED=u;var h="exiting";t.EXITING=h;var p=function(e){var t,i;function n(t,i){var n;n=e.call(this,t,i)||this;var o,r=i.transitionGroup,a=r&&!r.isMounting?t.enter:t.appear;return n.appearStatus=null,t.in?a?(o=c,n.appearStatus=d):o=u:o=t.unmountOnExit||t.mountOnEnter?l:c,n.state={status:o},n.nextCallback=null,n}i=e,(t=n).prototype=Object.create(i.prototype),t.prototype.constructor=t,t.__proto__=i;var a=n.prototype;return a.getChildContext=function(){return{transitionGroup:null}},n.getDerivedStateFromProps=function(e,t){return e.in&&t.status===l?{status:c}:null},a.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},a.componentDidUpdate=function(e){var t=null;if(e!==this.props){var i=this.state.status;this.props.in?i!==d&&i!==u&&(t=d):i!==d&&i!==u||(t=h)}this.updateStatus(!1,t)},a.componentWillUnmount=function(){this.cancelNextCallback()},a.getTimeouts=function(){var e,t,i,n=this.props.timeout;return e=t=i=n,null!=n&&"number"!=typeof n&&(e=n.exit,t=n.enter,i=void 0!==n.appear?n.appear:t),{exit:e,enter:t,appear:i}},a.updateStatus=function(e,t){if(void 0===e&&(e=!1),null!==t){this.cancelNextCallback();var i=r.default.findDOMNode(this);t===d?this.performEnter(i,e):this.performExit(i)}else this.props.unmountOnExit&&this.state.status===c&&this.setState({status:l})},a.performEnter=function(e,t){var i=this,n=this.props.enter,o=this.context.transitionGroup?this.context.transitionGroup.isMounting:t,r=this.getTimeouts(),a=o?r.appear:r.enter;t||n?(this.props.onEnter(e,o),this.safeSetState({status:d},(function(){i.props.onEntering(e,o),i.onTransitionEnd(e,a,(function(){i.safeSetState({status:u},(function(){i.props.onEntered(e,o)}))}))}))):this.safeSetState({status:u},(function(){i.props.onEntered(e)}))},a.performExit=function(e){var t=this,i=this.props.exit,n=this.getTimeouts();i?(this.props.onExit(e),this.safeSetState({status:h},(function(){t.props.onExiting(e),t.onTransitionEnd(e,n.exit,(function(){t.safeSetState({status:c},(function(){t.props.onExited(e)}))}))}))):this.safeSetState({status:c},(function(){t.props.onExited(e)}))},a.cancelNextCallback=function(){null!==this.nextCallback&&(this.nextCallback.cancel(),this.nextCallback=null)},a.safeSetState=function(e,t){t=this.setNextCallback(t),this.setState(e,t)},a.setNextCallback=function(e){var t=this,i=!0;return this.nextCallback=function(n){i&&(i=!1,t.nextCallback=null,e(n))},this.nextCallback.cancel=function(){i=!1},this.nextCallback},a.onTransitionEnd=function(e,t,i){this.setNextCallback(i);var n=null==t&&!this.props.addEndListener;e&&!n?(this.props.addEndListener&&this.props.addEndListener(e,this.nextCallback),null!=t&&setTimeout(this.nextCallback,t)):setTimeout(this.nextCallback,0)},a.render=function(){var e=this.state.status;if(e===l)return null;var t=this.props,i=t.children,n=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(t,["children"]);if(delete n.in,delete n.mountOnEnter,delete n.unmountOnExit,delete n.appear,delete n.enter,delete n.exit,delete n.timeout,delete n.addEndListener,delete n.onEnter,delete n.onEntering,delete n.onEntered,delete n.onExit,delete n.onExiting,delete n.onExited,"function"==typeof i)return i(e,n);var r=o.default.Children.only(i);return o.default.cloneElement(r,n)},n}(o.default.Component);function g(){}p.contextTypes={transitionGroup:n.object},p.childContextTypes={transitionGroup:function(){}},p.propTypes={},p.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:g,onEntering:g,onEntered:g,onExit:g,onExiting:g,onExited:g},p.UNMOUNTED=0,p.EXITED=1,p.ENTERING=2,p.ENTERED=3,p.EXITING=4;var f=(0,a.polyfill)(p);t.default=f},93868:function(e,t,i){"use strict";t.__esModule=!0,t.default=void 0;var n=s(i(25286)),o=s(i(8559)),r=i(81304),a=i(65393);function s(e){return e&&e.__esModule?e:{default:e}}function l(){return l=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},l.apply(this,arguments)}function c(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}var d=Object.values||function(e){return Object.keys(e).map((function(t){return e[t]}))},u=function(e){var t,i;function n(t,i){var n,o=(n=e.call(this,t,i)||this).handleExited.bind(c(c(n)));return n.state={handleExited:o,firstRender:!0},n}i=e,(t=n).prototype=Object.create(i.prototype),t.prototype.constructor=t,t.__proto__=i;var r=n.prototype;return r.getChildContext=function(){return{transitionGroup:{isMounting:!this.appeared}}},r.componentDidMount=function(){this.appeared=!0,this.mounted=!0},r.componentWillUnmount=function(){this.mounted=!1},n.getDerivedStateFromProps=function(e,t){var i=t.children,n=t.handleExited;return{children:t.firstRender?(0,a.getInitialChildMapping)(e,n):(0,a.getNextChildMapping)(e,i,n),firstRender:!1}},r.handleExited=function(e,t){var i=(0,a.getChildMapping)(this.props.children);e.key in i||(e.props.onExited&&e.props.onExited(t),this.mounted&&this.setState((function(t){var i=l({},t.children);return delete i[e.key],{children:i}})))},r.render=function(){var e=this.props,t=e.component,i=e.childFactory,n=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,["component","childFactory"]),r=d(this.state.children).map(i);return delete n.appear,delete n.enter,delete n.exit,null===t?r:o.default.createElement(t,n,r)},n}(o.default.Component);u.childContextTypes={transitionGroup:n.default.object.isRequired},u.propTypes={},u.defaultProps={component:"div",childFactory:function(e){return e}};var h=(0,r.polyfill)(u);t.default=h,e.exports=t.default},59146:function(e,t,i){"use strict";var n=s(i(30673)),o=s(i(93890)),r=s(i(93868)),a=s(i(37450));function s(e){return e&&e.__esModule?e:{default:e}}e.exports={Transition:a.default,TransitionGroup:r.default,ReplaceTransition:o.default,CSSTransition:n.default}},65393:function(e,t,i){"use strict";t.__esModule=!0,t.getChildMapping=o,t.mergeChildMappings=r,t.getInitialChildMapping=function(e,t){return o(e.children,(function(i){return(0,n.cloneElement)(i,{onExited:t.bind(null,i),in:!0,appear:a(i,"appear",e),enter:a(i,"enter",e),exit:a(i,"exit",e)})}))},t.getNextChildMapping=function(e,t,i){var s=o(e.children),l=r(t,s);return Object.keys(l).forEach((function(o){var r=l[o];if((0,n.isValidElement)(r)){var c=o in t,d=o in s,u=t[o],h=(0,n.isValidElement)(u)&&!u.props.in;!d||c&&!h?d||!c||h?d&&c&&(0,n.isValidElement)(u)&&(l[o]=(0,n.cloneElement)(r,{onExited:i.bind(null,r),in:u.props.in,exit:a(r,"exit",e),enter:a(r,"enter",e)})):l[o]=(0,n.cloneElement)(r,{in:!1}):l[o]=(0,n.cloneElement)(r,{onExited:i.bind(null,r),in:!0,exit:a(r,"exit",e),enter:a(r,"enter",e)})}})),l};var n=i(8559);function o(e,t){var i=Object.create(null);return e&&n.Children.map(e,(function(e){return e})).forEach((function(e){i[e.key]=function(e){return t&&(0,n.isValidElement)(e)?t(e):e}(e)})),i}function r(e,t){function i(i){return i in t?t[i]:e[i]}e=e||{},t=t||{};var n,o=Object.create(null),r=[];for(var a in e)a in t?r.length&&(o[a]=r,r=[]):r.push(a);var s={};for(var l in t){if(o[l])for(n=0;n<o[l].length;n++){var c=o[l][n];s[o[l][n]]=i(c)}s[l]=i(l)}for(n=0;n<r.length;n++)s[r[n]]=i(r[n]);return s}function a(e,t,i){return null!=i[t]?i[t]:e.props[t]}},94975:function(e,t,i){"use strict";var n;t.__esModule=!0,t.classNamesShape=t.timeoutsShape=void 0,(n=i(25286))&&n.__esModule,t.timeoutsShape=null,t.classNamesShape=null},88044:function(e,t,i){"use strict";var n=i(8559),o=Symbol.for("react.element"),r=Symbol.for("react.fragment"),a=Object.prototype.hasOwnProperty,s=n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,l={key:!0,ref:!0,__self:!0,__source:!0};function c(e,t,i){var n,r={},c=null,d=null;for(n in void 0!==i&&(c=""+i),void 0!==t.key&&(c=""+t.key),void 0!==t.ref&&(d=t.ref),t)a.call(t,n)&&!l.hasOwnProperty(n)&&(r[n]=t[n]);if(e&&e.defaultProps)for(n in t=e.defaultProps)void 0===r[n]&&(r[n]=t[n]);return{$$typeof:o,type:e,key:c,ref:d,props:r,_owner:s.current}}t.Fragment=r,t.jsx=c,t.jsxs=c},67301:function(e,t){"use strict";var i=Symbol.for("react.element"),n=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),l=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),u=Symbol.for("react.memo"),h=Symbol.for("react.lazy"),p=Symbol.iterator,g={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},f=Object.assign,m={};function v(e,t,i){this.props=e,this.context=t,this.refs=m,this.updater=i||g}function y(){}function C(e,t,i){this.props=e,this.context=t,this.refs=m,this.updater=i||g}v.prototype.isReactComponent={},v.prototype.setState=function(e,t){if("object"!=typeof e&&"function"!=typeof e&&null!=e)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")},v.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},y.prototype=v.prototype;var b=C.prototype=new y;b.constructor=C,f(b,v.prototype),b.isPureReactComponent=!0;var S=Array.isArray,x=Object.prototype.hasOwnProperty,T={current:null},w={key:!0,ref:!0,__self:!0,__source:!0};function O(e,t,n){var o,r={},a=null,s=null;if(null!=t)for(o in void 0!==t.ref&&(s=t.ref),void 0!==t.key&&(a=""+t.key),t)x.call(t,o)&&!w.hasOwnProperty(o)&&(r[o]=t[o]);var l=arguments.length-2;if(1===l)r.children=n;else if(1<l){for(var c=Array(l),d=0;d<l;d++)c[d]=arguments[d+2];r.children=c}if(e&&e.defaultProps)for(o in l=e.defaultProps)void 0===r[o]&&(r[o]=l[o]);return{$$typeof:i,type:e,key:a,ref:s,props:r,_owner:T.current}}function P(e){return"object"==typeof e&&null!==e&&e.$$typeof===i}var A=/\/+/g;function E(e,t){return"object"==typeof e&&null!==e&&null!=e.key?function(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,(function(e){return t[e]}))}(""+e.key):t.toString(36)}function k(e,t,o,r,a){var s=typeof e;"undefined"!==s&&"boolean"!==s||(e=null);var l=!1;if(null===e)l=!0;else switch(s){case"string":case"number":l=!0;break;case"object":switch(e.$$typeof){case i:case n:l=!0}}if(l)return a=a(l=e),e=""===r?"."+E(l,0):r,S(a)?(o="",null!=e&&(o=e.replace(A,"$&/")+"/"),k(a,t,o,"",(function(e){return e}))):null!=a&&(P(a)&&(a=function(e,t){return{$$typeof:i,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}(a,o+(!a.key||l&&l.key===a.key?"":(""+a.key).replace(A,"$&/")+"/")+e)),t.push(a)),1;if(l=0,r=""===r?".":r+":",S(e))for(var c=0;c<e.length;c++){var d=r+E(s=e[c],c);l+=k(s,t,o,d,a)}else if(d=function(e){return null===e||"object"!=typeof e?null:"function"==typeof(e=p&&e[p]||e["@@iterator"])?e:null}(e),"function"==typeof d)for(e=d.call(e),c=0;!(s=e.next()).done;)l+=k(s=s.value,t,o,d=r+E(s,c++),a);else if("object"===s)throw t=String(e),Error("Objects are not valid as a React child (found: "+("[object Object]"===t?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.");return l}function I(e,t,i){if(null==e)return e;var n=[],o=0;return k(e,n,"","",(function(e){return t.call(i,e,o++)})),n}function D(e){if(-1===e._status){var t=e._result;(t=t()).then((function(t){0!==e._status&&-1!==e._status||(e._status=1,e._result=t)}),(function(t){0!==e._status&&-1!==e._status||(e._status=2,e._result=t)})),-1===e._status&&(e._status=0,e._result=t)}if(1===e._status)return e._result.default;throw e._result}var _={current:null},N={transition:null},R={ReactCurrentDispatcher:_,ReactCurrentBatchConfig:N,ReactCurrentOwner:T};t.Children={map:I,forEach:function(e,t,i){I(e,(function(){t.apply(this,arguments)}),i)},count:function(e){var t=0;return I(e,(function(){t++})),t},toArray:function(e){return I(e,(function(e){return e}))||[]},only:function(e){if(!P(e))throw Error("React.Children.only expected to receive a single React element child.");return e}},t.Component=v,t.Fragment=o,t.Profiler=a,t.PureComponent=C,t.StrictMode=r,t.Suspense=d,t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=R,t.cloneElement=function(e,t,n){if(null==e)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+e+".");var o=f({},e.props),r=e.key,a=e.ref,s=e._owner;if(null!=t){if(void 0!==t.ref&&(a=t.ref,s=T.current),void 0!==t.key&&(r=""+t.key),e.type&&e.type.defaultProps)var l=e.type.defaultProps;for(c in t)x.call(t,c)&&!w.hasOwnProperty(c)&&(o[c]=void 0===t[c]&&void 0!==l?l[c]:t[c])}var c=arguments.length-2;if(1===c)o.children=n;else if(1<c){l=Array(c);for(var d=0;d<c;d++)l[d]=arguments[d+2];o.children=l}return{$$typeof:i,type:e.type,key:r,ref:a,props:o,_owner:s}},t.createContext=function(e){return(e={$$typeof:l,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null}).Provider={$$typeof:s,_context:e},e.Consumer=e},t.createElement=O,t.createFactory=function(e){var t=O.bind(null,e);return t.type=e,t},t.createRef=function(){return{current:null}},t.forwardRef=function(e){return{$$typeof:c,render:e}},t.isValidElement=P,t.lazy=function(e){return{$$typeof:h,_payload:{_status:-1,_result:e},_init:D}},t.memo=function(e,t){return{$$typeof:u,type:e,compare:void 0===t?null:t}},t.startTransition=function(e){var t=N.transition;N.transition={};try{e()}finally{N.transition=t}},t.unstable_act=function(){throw Error("act(...) is not supported in production builds of React.")},t.useCallback=function(e,t){return _.current.useCallback(e,t)},t.useContext=function(e){return _.current.useContext(e)},t.useDebugValue=function(){},t.useDeferredValue=function(e){return _.current.useDeferredValue(e)},t.useEffect=function(e,t){return _.current.useEffect(e,t)},t.useId=function(){return _.current.useId()},t.useImperativeHandle=function(e,t,i){return _.current.useImperativeHandle(e,t,i)},t.useInsertionEffect=function(e,t){return _.current.useInsertionEffect(e,t)},t.useLayoutEffect=function(e,t){return _.current.useLayoutEffect(e,t)},t.useMemo=function(e,t){return _.current.useMemo(e,t)},t.useReducer=function(e,t,i){return _.current.useReducer(e,t,i)},t.useRef=function(e){return _.current.useRef(e)},t.useState=function(e){return _.current.useState(e)},t.useSyncExternalStore=function(e,t,i){return _.current.useSyncExternalStore(e,t,i)},t.useTransition=function(){return _.current.useTransition()},t.version="18.2.0"},8559:function(e,t,i){"use strict";e.exports=i(67301)},82369:function(e,t,i){"use strict";e.exports=i(88044)},72507:function(e,t,i){"use strict";i.r(t),i.d(t,{getNiceTickValues:function(){return P},getTickValues:function(){return A},getTickValuesFixedDomain:function(){return E}});var n=i(90698),o=i.n(n);function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}var a=function(e){return e},s={"@@functional/placeholder":!0},l=function(e){return e===s},c=function(e){return function t(){return 0===arguments.length||1===arguments.length&&l(arguments.length<=0?void 0:arguments[0])?t:e.apply(void 0,arguments)}},d=function e(t,i){return 1===t?i:c((function(){for(var n=arguments.length,o=new Array(n),a=0;a<n;a++)o[a]=arguments[a];var d=o.filter((function(e){return e!==s})).length;return d>=t?i.apply(void 0,o):e(t-d,c((function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var a,s=o.map((function(e){return l(e)?t.shift():e}));return i.apply(void 0,(a=s,function(e){if(Array.isArray(e))return r(e)}(a)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(a)||function(e,t){if(e){if("string"==typeof e)return r(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?r(e,t):void 0}}(a)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()).concat(t))})))}))},u=function(e){return d(e.length,e)},h=function(e,t){for(var i=[],n=e;n<t;++n)i[n-e]=n;return i},p=u((function(e,t){return Array.isArray(t)?t.map(e):Object.keys(t).map((function(e){return t[e]})).map(e)})),g=function(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];if(!t.length)return a;var n=t.reverse(),o=n[0],r=n.slice(1);return function(){return r.reduce((function(e,t){return t(e)}),o.apply(void 0,arguments))}},f=function(e){return Array.isArray(e)?e.reverse():e.split("").reverse.join("")},m=function(e){var t=null,i=null;return function(){for(var n=arguments.length,o=new Array(n),r=0;r<n;r++)o[r]=arguments[r];return t&&o.every((function(e,i){return e===t[i]}))?i:(t=o,i=e.apply(void 0,o))}},v={rangeStep:function(e,t,i){for(var n=new(o())(e),r=0,a=[];n.lt(t)&&r<1e5;)a.push(n.toNumber()),n=n.add(i),r++;return a},getDigitCount:function(e){return 0===e?1:Math.floor(new(o())(e).abs().log(10).toNumber())+1},interpolateNumber:u((function(e,t,i){var n=+e;return n+i*(+t-n)})),uninterpolateNumber:u((function(e,t,i){var n=t-+e;return(i-e)/(n||1/0)})),uninterpolateTruncation:u((function(e,t,i){var n=t-+e;return n=n||1/0,Math.max(0,Math.min(1,(i-e)/n))}))};function y(e){return function(e){if(Array.isArray(e))return S(e)}(e)||function(e){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e))return Array.from(e)}(e)||b(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function C(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){if("undefined"!=typeof Symbol&&Symbol.iterator in Object(e)){var i=[],n=!0,o=!1,r=void 0;try{for(var a,s=e[Symbol.iterator]();!(n=(a=s.next()).done)&&(i.push(a.value),!t||i.length!==t);n=!0);}catch(e){o=!0,r=e}finally{try{n||null==s.return||s.return()}finally{if(o)throw r}}return i}}(e,t)||b(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function b(e,t){if(e){if("string"==typeof e)return S(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?S(e,t):void 0}}function S(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}function x(e){var t=C(e,2),i=t[0],n=t[1],o=i,r=n;return i>n&&(o=n,r=i),[o,r]}function T(e,t,i){if(e.lte(0))return new(o())(0);var n=v.getDigitCount(e.toNumber()),r=new(o())(10).pow(n),a=e.div(r),s=1!==n?.05:.1,l=new(o())(Math.ceil(a.div(s).toNumber())).add(i).mul(s).mul(r);return t?l:new(o())(Math.ceil(l))}function w(e,t,i){var n=1,r=new(o())(e);if(!r.isint()&&i){var a=Math.abs(e);a<1?(n=new(o())(10).pow(v.getDigitCount(e)-1),r=new(o())(Math.floor(r.div(n).toNumber())).mul(n)):a>1&&(r=new(o())(Math.floor(e)))}else 0===e?r=new(o())(Math.floor((t-1)/2)):i||(r=new(o())(Math.floor(e)));var s=Math.floor((t-1)/2);return g(p((function(e){return r.add(new(o())(e-s).mul(n)).toNumber()})),h)(0,t)}function O(e,t,i,n){var r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0;if(!Number.isFinite((t-e)/(i-1)))return{step:new(o())(0),tickMin:new(o())(0),tickMax:new(o())(0)};var a,s=T(new(o())(t).sub(e).div(i-1),n,r);a=e<=0&&t>=0?new(o())(0):(a=new(o())(e).add(t).div(2)).sub(new(o())(a).mod(s));var l=Math.ceil(a.sub(e).div(s).toNumber()),c=Math.ceil(new(o())(t).sub(a).div(s).toNumber()),d=l+c+1;return d>i?O(e,t,i,n,r+1):(d<i&&(c=t>0?c+(i-d):c,l=t>0?l:l+(i-d)),{step:s,tickMin:a.sub(new(o())(l).mul(s)),tickMax:a.add(new(o())(c).mul(s))})}var P=m((function(e){var t=C(e,2),i=t[0],n=t[1],r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:6,a=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],s=Math.max(r,2),l=C(x([i,n]),2),c=l[0],d=l[1];if(c===-1/0||d===1/0){var u=d===1/0?[c].concat(y(h(0,r-1).map((function(){return 1/0})))):[].concat(y(h(0,r-1).map((function(){return-1/0}))),[d]);return i>n?f(u):u}if(c===d)return w(c,r,a);var p=O(c,d,s,a),g=p.step,m=p.tickMin,b=p.tickMax,S=v.rangeStep(m,b.add(new(o())(.1).mul(g)),g);return i>n?f(S):S})),A=m((function(e){var t=C(e,2),i=t[0],n=t[1],r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:6,a=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],s=Math.max(r,2),l=C(x([i,n]),2),c=l[0],d=l[1];if(c===-1/0||d===1/0)return[i,n];if(c===d)return w(c,r,a);var u=T(new(o())(d).sub(c).div(s-1),a,0),m=g(p((function(e){return new(o())(c).add(new(o())(e).mul(u)).toNumber()})),h)(0,s).filter((function(e){return e>=c&&e<=d}));return i>n?f(m):m})),E=m((function(e,t){var i=C(e,2),n=i[0],r=i[1],a=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],s=C(x([n,r]),2),l=s[0],c=s[1];if(l===-1/0||c===1/0)return[n,r];if(l===c)return[l];var d=Math.max(t,2),u=T(new(o())(c).sub(l).div(d-1),a,0),h=[].concat(y(v.rangeStep(new(o())(l),new(o())(c).sub(new(o())(.99).mul(u)),u)),[c]);return n>r?f(h):h}))},11976:function(e,t,i){"use strict";t.u=void 0;var n,o=w(i(37861)),r=w(i(68014)),a=w(i(94563)),s=w(i(40825)),l=w(i(71758)),c=w(i(18562)),d=w(i(83008)),u=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!==O(e)&&"function"!=typeof e)return{default:e};var i=T(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}(i(8559)),h=w(i(33680)),p=w(i(90480)),g=i(96729),f=i(49566),m=i(61441),v=i(74730),y=i(68304),C=i(47320),b=i(10455),S=i(48828),x=["layout","type","stroke","connectNulls","isRange","ref"];function T(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(T=function(e){return e?i:t})(e)}function w(e){return e&&e.__esModule?e:{default:e}}function O(e){return O="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},O(e)}function P(){return P=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},P.apply(this,arguments)}function A(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function E(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?A(Object(i),!0).forEach((function(t){N(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):A(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function k(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,R(n.key),n)}}function I(e,t){return I=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},I(e,t)}function D(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function _(e){return _=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},_(e)}function N(e,t,i){return(t=R(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function R(e){var t=function(e,t){if("object"!==O(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==O(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===O(t)?t:String(t)}var M=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&I(e,t)}(b,e);var t,i,n,l,f,y=(l=b,f=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=_(l);if(f){var i=_(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===O(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return D(e)}(this,e)});function b(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,b);for(var t=arguments.length,i=new Array(t),n=0;n<t;n++)i[n]=arguments[n];return N(D(e=y.call.apply(y,[this].concat(i))),"state",{isAnimationFinished:!0}),N(D(e),"id",(0,C.uniqueId)("recharts-area-")),N(D(e),"handleAnimationEnd",(function(){var t=e.props.onAnimationEnd;e.setState({isAnimationFinished:!0}),(0,s.default)(t)&&t()})),N(D(e),"handleAnimationStart",(function(){var t=e.props.onAnimationStart;e.setState({isAnimationFinished:!1}),(0,s.default)(t)&&t()})),e}return t=b,n=[{key:"getDerivedStateFromProps",value:function(e,t){return e.animationId!==t.prevAnimationId?{prevAnimationId:e.animationId,curPoints:e.points,curBaseLine:e.baseLine,prevPoints:t.curPoints,prevBaseLine:t.curBaseLine}:e.points!==t.curPoints||e.baseLine!==t.curBaseLine?{curPoints:e.points,curBaseLine:e.baseLine}:null}}],(i=[{key:"renderDots",value:function(e,t,i){var n=this.props.isAnimationActive,o=this.state.isAnimationFinished;if(n&&!o)return null;var r=this.props,a=r.dot,s=r.points,l=r.dataKey,c=(0,S.filterProps)(this.props),d=(0,S.filterProps)(a,!0),h=s.map((function(e,t){var i=E(E(E({key:"dot-".concat(t),r:3},c),d),{},{dataKey:l,cx:e.x,cy:e.y,index:t,value:e.value,payload:e.payload});return b.renderDotItem(a,i)})),p={clipPath:e?"url(#clipPath-".concat(t?"":"dots-").concat(i,")"):null};return u.default.createElement(m.Layer,P({className:"recharts-area-dots"},p),h)}},{key:"renderHorizontalRect",value:function(e){var t=this.props,i=t.baseLine,n=t.points,o=t.strokeWidth,r=n[0].x,s=n[n.length-1].x,l=e*Math.abs(r-s),c=(0,a.default)(n.map((function(e){return e.y||0})));return(0,C.isNumber)(i)&&"number"==typeof i?c=Math.max(i,c):i&&(0,d.default)(i)&&i.length&&(c=Math.max((0,a.default)(i.map((function(e){return e.y||0}))),c)),(0,C.isNumber)(c)?u.default.createElement("rect",{x:r<s?r:r-l,y:0,width:l,height:Math.floor(c+(o?parseInt("".concat(o),10):1))}):null}},{key:"renderVerticalRect",value:function(e){var t=this.props,i=t.baseLine,n=t.points,o=t.strokeWidth,r=n[0].y,s=n[n.length-1].y,l=e*Math.abs(r-s),c=(0,a.default)(n.map((function(e){return e.x||0})));return(0,C.isNumber)(i)&&"number"==typeof i?c=Math.max(i,c):i&&(0,d.default)(i)&&i.length&&(c=Math.max((0,a.default)(i.map((function(e){return e.x||0}))),c)),(0,C.isNumber)(c)?u.default.createElement("rect",{x:0,y:r<s?r:r-l,width:c+(o?parseInt("".concat(o),10):1),height:Math.floor(l)}):null}},{key:"renderClipRect",value:function(e){return"vertical"===this.props.layout?this.renderVerticalRect(e):this.renderHorizontalRect(e)}},{key:"renderAreaStatically",value:function(e,t,i,n){var o=this.props,r=o.layout,a=o.type,s=o.stroke,l=o.connectNulls,c=o.isRange,d=(o.ref,function(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}(o,x));return u.default.createElement(m.Layer,{clipPath:i?"url(#clipPath-".concat(n,")"):null},u.default.createElement(g.Curve,P({},(0,S.filterProps)(d,!0),{points:e,connectNulls:l,type:a,baseLine:t,layout:r,stroke:"none",className:"recharts-area-area"})),"none"!==s&&u.default.createElement(g.Curve,P({},(0,S.filterProps)(this.props),{className:"recharts-area-curve",layout:r,type:a,connectNulls:l,fill:"none",points:e})),"none"!==s&&c&&u.default.createElement(g.Curve,P({},(0,S.filterProps)(this.props),{className:"recharts-area-curve",layout:r,type:a,connectNulls:l,fill:"none",points:t})))}},{key:"renderAreaWithAnimation",value:function(e,t){var i=this,n=this.props,o=n.points,a=n.baseLine,s=n.isAnimationActive,l=n.animationBegin,d=n.animationDuration,h=n.animationEasing,g=n.animationId,f=this.state,v=f.prevPoints,y=f.prevBaseLine;return u.default.createElement(p.default,{begin:l,duration:d,isActive:s,easing:h,from:{t:0},to:{t:1},key:"area-".concat(g),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},(function(n){var s=n.t;if(v){var l,d=v.length/o.length,h=o.map((function(e,t){var i=Math.floor(t*d);if(v[i]){var n=v[i],o=(0,C.interpolateNumber)(n.x,e.x),r=(0,C.interpolateNumber)(n.y,e.y);return E(E({},e),{},{x:o(s),y:r(s)})}return e}));return l=(0,C.isNumber)(a)&&"number"==typeof a?(0,C.interpolateNumber)(y,a)(s):(0,c.default)(a)||(0,r.default)(a)?(0,C.interpolateNumber)(y,0)(s):a.map((function(e,t){var i=Math.floor(t*d);if(y[i]){var n=y[i],o=(0,C.interpolateNumber)(n.x,e.x),r=(0,C.interpolateNumber)(n.y,e.y);return E(E({},e),{},{x:o(s),y:r(s)})}return e})),i.renderAreaStatically(h,l,e,t)}return u.default.createElement(m.Layer,null,u.default.createElement("defs",null,u.default.createElement("clipPath",{id:"animationClipPath-".concat(t)},i.renderClipRect(s))),u.default.createElement(m.Layer,{clipPath:"url(#animationClipPath-".concat(t,")")},i.renderAreaStatically(o,a,e,t)))}))}},{key:"renderArea",value:function(e,t){var i=this.props,n=i.points,r=i.baseLine,a=i.isAnimationActive,s=this.state,l=s.prevPoints,c=s.prevBaseLine,d=s.totalLength;return a&&n&&n.length&&(!l&&d>0||!(0,o.default)(l,n)||!(0,o.default)(c,r))?this.renderAreaWithAnimation(e,t):this.renderAreaStatically(n,r,e,t)}},{key:"render",value:function(){var e,t=this.props,i=t.hide,n=t.dot,o=t.points,r=t.className,a=t.top,s=t.left,l=t.xAxis,d=t.yAxis,p=t.width,g=t.height,f=t.isAnimationActive,y=t.id;if(i||!o||!o.length)return null;var C=this.state.isAnimationFinished,b=1===o.length,x=(0,h.default)("recharts-area",r),T=l&&l.allowDataOverflow,w=d&&d.allowDataOverflow,O=T||w,P=(0,c.default)(y)?this.id:y,A=null!==(e=(0,S.filterProps)(n))&&void 0!==e?e:{r:3,strokeWidth:2},E=A.r,k=void 0===E?3:E,I=A.strokeWidth,D=void 0===I?2:I,_=((0,S.isDotProps)(n)?n:{}).clipDot,N=void 0===_||_,R=2*k+D;return u.default.createElement(m.Layer,{className:x},T||w?u.default.createElement("defs",null,u.default.createElement("clipPath",{id:"clipPath-".concat(P)},u.default.createElement("rect",{x:T?s:s-p/2,y:w?a:a-g/2,width:T?p:2*p,height:w?g:2*g})),!N&&u.default.createElement("clipPath",{id:"clipPath-dots-".concat(P)},u.default.createElement("rect",{x:s-R/2,y:a-R/2,width:p+R,height:g+R}))):null,b?null:this.renderArea(O,P),(n||b)&&this.renderDots(O,N,P),(!f||C)&&v.LabelList.renderCallByParent(this.props,o))}}])&&k(t.prototype,i),n&&k(t,n),Object.defineProperty(t,"prototype",{writable:!1}),b}(u.PureComponent);t.u=M,n=M,N(M,"displayName","Area"),N(M,"defaultProps",{stroke:"#3182bd",fill:"#3182bd",fillOpacity:.6,xAxisId:0,yAxisId:0,legendType:"line",connectNulls:!1,points:[],dot:!1,activeDot:!0,hide:!1,isAnimationActive:!y.Global.isSsr,animationBegin:0,animationDuration:1500,animationEasing:"ease"}),N(M,"getBaseValue",(function(e,t,i,n){var o=e.layout,r=e.baseValue,a=t.props.baseValue,s=null!=a?a:r;if((0,C.isNumber)(s)&&"number"==typeof s)return s;var l="horizontal"===o?n:i,c=l.scale.domain();if("number"===l.type){var d=Math.max(c[0],c[1]),u=Math.min(c[0],c[1]);return"dataMin"===s?u:"dataMax"===s||d<0?d:Math.max(Math.min(c[0],c[1]),0)}return"dataMin"===s?c[0]:"dataMax"===s?c[1]:c[0]})),N(M,"getComposedData",(function(e){var t,i=e.props,o=e.item,r=e.xAxis,a=e.yAxis,s=e.xAxisTicks,u=e.yAxisTicks,h=e.bandSize,p=e.dataKey,g=e.stackedData,f=e.dataStartIndex,m=e.displayedData,v=e.offset,y=i.layout,C=g&&g.length,S=n.getBaseValue(i,o,r,a),x=!1,T=m.map((function(e,t){var i,n=(0,b.getValueByDataKey)(e,p);C?i=g[f+t]:(i=n,(0,d.default)(i)?x=!0:i=[S,i]);var o=(0,c.default)(i[1])||C&&(0,c.default)(n);return"horizontal"===y?{x:(0,b.getCateCoordinateOfLine)({axis:r,ticks:s,bandSize:h,entry:e,index:t}),y:o?null:a.scale(i[1]),value:i,payload:e}:{x:o?null:r.scale(i[1]),y:(0,b.getCateCoordinateOfLine)({axis:a,ticks:u,bandSize:h,entry:e,index:t}),value:i,payload:e}}));return t=C||x?T.map((function(e){return"horizontal"===y?{x:e.x,y:(0,c.default)((0,l.default)(e,"value[0]"))||(0,c.default)((0,l.default)(e,"y"))?null:a.scale((0,l.default)(e,"value[0]"))}:{x:(0,c.default)((0,l.default)(e,"value[0]"))?null:r.scale((0,l.default)(e,"value[0]")),y:e.y}})):"horizontal"===y?a.scale(S):r.scale(S),E({points:T,baseLine:t,layout:y,isRange:x},v)})),N(M,"renderDotItem",(function(e,t){return u.default.isValidElement(e)?u.default.cloneElement(e,t):(0,s.default)(e)?e(t):u.default.createElement(f.Dot,P({},t,{className:"recharts-area-dot"}))}))},5445:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Bar=void 0;var n=S(i(18562)),o=S(i(37861)),r=S(i(83008)),a=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!==x(e)&&"function"!=typeof e)return{default:e};var i=b(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}(i(8559)),s=S(i(33680)),l=S(i(90480)),c=i(61441),d=i(63394),u=i(54704),h=i(74730),p=i(47320),g=i(48828),f=i(68304),m=i(10455),v=i(13630),y=i(46129),C=["value","background"];function b(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(b=function(e){return e?i:t})(e)}function S(e){return e&&e.__esModule?e:{default:e}}function x(e){return x="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},x(e)}function T(){return T=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},T.apply(this,arguments)}function w(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function O(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?w(Object(i),!0).forEach((function(t){I(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):w(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function P(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,D(n.key),n)}}function A(e,t){return A=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},A(e,t)}function E(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function k(e){return k=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},k(e)}function I(e,t,i){return(t=D(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function D(e){var t=function(e,t){if("object"!==x(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==x(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===x(t)?t:String(t)}var _=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&A(e,t)}(S,e);var t,i,r,u,f,b=(u=S,f=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=k(u);if(f){var i=k(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===x(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return E(e)}(this,e)});function S(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,S);for(var t=arguments.length,i=new Array(t),n=0;n<t;n++)i[n]=arguments[n];return I(E(e=b.call.apply(b,[this].concat(i))),"state",{isAnimationFinished:!1}),I(E(e),"id",(0,p.uniqueId)("recharts-bar-")),I(E(e),"handleAnimationEnd",(function(){var t=e.props.onAnimationEnd;e.setState({isAnimationFinished:!0}),t&&t()})),I(E(e),"handleAnimationStart",(function(){var t=e.props.onAnimationStart;e.setState({isAnimationFinished:!1}),t&&t()})),e}return t=S,r=[{key:"getDerivedStateFromProps",value:function(e,t){return e.animationId!==t.prevAnimationId?{prevAnimationId:e.animationId,curData:e.data,prevData:t.curData}:e.data!==t.curData?{curData:e.data}:null}}],(i=[{key:"renderRectanglesStatically",value:function(e){var t=this,i=this.props,n=i.shape,o=i.dataKey,r=i.activeIndex,s=i.activeBar,l=(0,g.filterProps)(this.props);return e&&e.map((function(e,i){var d=i===r,u=d?s:n,h=O(O(O({},l),e),{},{isActive:d,option:u,index:i,dataKey:o,onAnimationStart:t.handleAnimationStart,onAnimationEnd:t.handleAnimationEnd});return a.default.createElement(c.Layer,T({className:"recharts-bar-rectangle"},(0,v.adaptEventsOfChild)(t.props,e,i),{key:"rectangle-".concat(i)}),a.default.createElement(y.BarRectangle,h))}))}},{key:"renderRectanglesWithAnimation",value:function(){var e=this,t=this.props,i=t.data,n=t.layout,o=t.isAnimationActive,r=t.animationBegin,s=t.animationDuration,d=t.animationEasing,u=t.animationId,h=this.state.prevData;return a.default.createElement(l.default,{begin:r,duration:s,isActive:o,easing:d,from:{t:0},to:{t:1},key:"bar-".concat(u),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},(function(t){var o=t.t,r=i.map((function(e,t){var i=h&&h[t];if(i){var r=(0,p.interpolateNumber)(i.x,e.x),a=(0,p.interpolateNumber)(i.y,e.y),s=(0,p.interpolateNumber)(i.width,e.width),l=(0,p.interpolateNumber)(i.height,e.height);return O(O({},e),{},{x:r(o),y:a(o),width:s(o),height:l(o)})}if("horizontal"===n){var c=(0,p.interpolateNumber)(0,e.height)(o);return O(O({},e),{},{y:e.y+e.height-c,height:c})}var d=(0,p.interpolateNumber)(0,e.width)(o);return O(O({},e),{},{width:d})}));return a.default.createElement(c.Layer,null,e.renderRectanglesStatically(r))}))}},{key:"renderRectangles",value:function(){var e=this.props,t=e.data,i=e.isAnimationActive,n=this.state.prevData;return!(i&&t&&t.length)||n&&(0,o.default)(n,t)?this.renderRectanglesStatically(t):this.renderRectanglesWithAnimation()}},{key:"renderBackground",value:function(){var e=this,t=this.props,i=t.data,n=t.dataKey,o=t.activeIndex,r=(0,g.filterProps)(this.props.background);return i.map((function(t,i){t.value;var s=t.background,l=function(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}(t,C);if(!s)return null;var c=O(O(O(O(O({},l),{},{fill:"#eee"},s),r),(0,v.adaptEventsOfChild)(e.props,t,i)),{},{onAnimationStart:e.handleAnimationStart,onAnimationEnd:e.handleAnimationEnd,dataKey:n,index:i,key:"background-bar-".concat(i),className:"recharts-bar-background-rectangle"});return a.default.createElement(y.BarRectangle,T({option:e.props.background,isActive:i===o},c))}))}},{key:"renderErrorBar",value:function(e,t){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var i=this.props,n=i.data,o=i.xAxis,r=i.yAxis,s=i.layout,l=i.children,u=(0,g.findAllByType)(l,d.ErrorBar);if(!u)return null;var h="vertical"===s?n[0].height/2:n[0].width/2,p=function(e,t){var i=Array.isArray(e.value)?e.value[1]:e.value;return{x:e.x,y:e.y,value:i,errorVal:(0,m.getValueByDataKey)(e,t)}},f={clipPath:e?"url(#clipPath-".concat(t,")"):null};return a.default.createElement(c.Layer,f,u.map((function(e,t){return a.default.cloneElement(e,{key:"error-bar-".concat(t),data:n,xAxis:o,yAxis:r,layout:s,offset:h,dataPointFormatter:p})})))}},{key:"render",value:function(){var e=this.props,t=e.hide,i=e.data,o=e.className,r=e.xAxis,l=e.yAxis,d=e.left,u=e.top,p=e.width,g=e.height,f=e.isAnimationActive,m=e.background,v=e.id;if(t||!i||!i.length)return null;var y=this.state.isAnimationFinished,C=(0,s.default)("recharts-bar",o),b=r&&r.allowDataOverflow,S=l&&l.allowDataOverflow,x=b||S,T=(0,n.default)(v)?this.id:v;return a.default.createElement(c.Layer,{className:C},b||S?a.default.createElement("defs",null,a.default.createElement("clipPath",{id:"clipPath-".concat(T)},a.default.createElement("rect",{x:b?d:d-p/2,y:S?u:u-g/2,width:b?p:2*p,height:S?g:2*g}))):null,a.default.createElement(c.Layer,{className:"recharts-bar-rectangles",clipPath:x?"url(#clipPath-".concat(T,")"):null},m?this.renderBackground():null,this.renderRectangles()),this.renderErrorBar(x,T),(!f||y)&&h.LabelList.renderCallByParent(this.props,i))}}])&&P(t.prototype,i),r&&P(t,r),Object.defineProperty(t,"prototype",{writable:!1}),S}(a.PureComponent);t.Bar=_,I(_,"displayName","Bar"),I(_,"defaultProps",{xAxisId:0,yAxisId:0,legendType:"rect",minPointSize:0,hide:!1,data:[],layout:"vertical",activeBar:!0,isAnimationActive:!f.Global.isSsr,animationBegin:0,animationDuration:400,animationEasing:"ease"}),I(_,"getComposedData",(function(e){var t=e.props,i=e.item,n=e.barPosition,o=e.bandSize,a=e.xAxis,s=e.yAxis,l=e.xAxisTicks,c=e.yAxisTicks,d=e.stackedData,h=e.dataStartIndex,f=e.displayedData,v=e.offset,y=(0,m.findPositionOfBar)(n,i);if(!y)return null;var C=t.layout,b=i.props,S=b.dataKey,x=b.children,T=b.minPointSize,w="horizontal"===C?s:a,P=d?w.scale.domain():null,A=(0,m.getBaseValueOfBar)({numericAxis:w}),E=(0,g.findAllByType)(x,u.Cell),k=f.map((function(e,t){var n,u,g,f,v,b;if(d?n=(0,m.truncateByDomain)(d[h+t],P):(n=(0,m.getValueByDataKey)(e,S),(0,r.default)(n)||(n=[A,n])),"horizontal"===C){var x,w=[s.scale(n[0]),s.scale(n[1])],k=w[0],I=w[1];u=(0,m.getCateCoordinateOfBar)({axis:a,ticks:l,bandSize:o,offset:y.offset,entry:e,index:t}),g=null!==(x=null!=I?I:k)&&void 0!==x?x:void 0,f=y.size;var D=k-I;if(v=Number.isNaN(D)?0:D,b={x:u,y:s.y,width:f,height:s.height},Math.abs(T)>0&&Math.abs(v)<Math.abs(T)){var _=(0,p.mathSign)(v||T)*(Math.abs(T)-Math.abs(v));g-=_,v+=_}}else{var N=[a.scale(n[0]),a.scale(n[1])],R=N[0],M=N[1];u=R,g=(0,m.getCateCoordinateOfBar)({axis:s,ticks:c,bandSize:o,offset:y.offset,entry:e,index:t}),f=M-R,v=y.size,b={x:a.x,y:g,width:a.width,height:v},Math.abs(T)>0&&Math.abs(f)<Math.abs(T)&&(f+=(0,p.mathSign)(f||T)*(Math.abs(T)-Math.abs(f)))}return O(O(O({},e),{},{x:u,y:g,width:f,height:v,value:d?n:n[1],payload:e,background:b},E&&E[t]&&E[t].props),{},{tooltipPayload:[(0,m.getTooltipItem)(i,e)],tooltipPosition:{x:u+f/2,y:g+v/2}})}));return O({data:k,layout:C},v)}))},15703:function(e,t,i){"use strict";t.B=void 0;var n=f(i(40825)),o=f(i(12474)),r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!==m(e)&&"function"!=typeof e)return{default:e};var i=g(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}(i(8559)),a=f(i(33680)),s=i(53527),l=i(61441),c=i(93903),d=i(10455),u=i(47320),h=i(73350),p=i(48828);function g(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(g=function(e){return e?i:t})(e)}function f(e){return e&&e.__esModule?e:{default:e}}function m(e){return m="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},m(e)}function v(){return v=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},v.apply(this,arguments)}function y(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function C(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?y(Object(i),!0).forEach((function(t){w(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):y(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function b(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,O(n.key),n)}}function S(e,t){return S=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},S(e,t)}function x(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function T(e){return T=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},T(e)}function w(e,t,i){return(t=O(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function O(e){var t=function(e,t){if("object"!==m(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==m(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===m(t)?t:String(t)}var P=function(e){return e.changedTouches&&!!e.changedTouches.length},A=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&S(e,t)}(A,e);var t,i,g,f,y,O=(f=A,y=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=T(f);if(y){var i=T(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===m(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return x(e)}(this,e)});function A(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,A),w(x(t=O.call(this,e)),"handleDrag",(function(e){t.leaveTimer&&(clearTimeout(t.leaveTimer),t.leaveTimer=null),t.state.isTravellerMoving?t.handleTravellerMove(e):t.state.isSlideMoving&&t.handleSlideDrag(e)})),w(x(t),"handleTouchMove",(function(e){null!=e.changedTouches&&e.changedTouches.length>0&&t.handleDrag(e.changedTouches[0])})),w(x(t),"handleDragEnd",(function(){t.setState({isTravellerMoving:!1,isSlideMoving:!1},(function(){var e=t.props,i=e.endIndex,n=e.onDragEnd,o=e.startIndex;null==n||n({endIndex:i,startIndex:o})})),t.detachDragEndListener()})),w(x(t),"handleLeaveWrapper",(function(){(t.state.isTravellerMoving||t.state.isSlideMoving)&&(t.leaveTimer=window.setTimeout(t.handleDragEnd,t.props.leaveTimeOut))})),w(x(t),"handleEnterSlideOrTraveller",(function(){t.setState({isTextActive:!0})})),w(x(t),"handleLeaveSlideOrTraveller",(function(){t.setState({isTextActive:!1})})),w(x(t),"handleSlideDragStart",(function(e){var i=P(e)?e.changedTouches[0]:e;t.setState({isTravellerMoving:!1,isSlideMoving:!0,slideMoveStartX:i.pageX}),t.attachDragEndListener()})),t.travellerDragStartHandlers={startX:t.handleTravellerDragStart.bind(x(t),"startX"),endX:t.handleTravellerDragStart.bind(x(t),"endX")},t.state={},t}return t=A,g=[{key:"renderDefaultTraveller",value:function(e){var t=e.x,i=e.y,n=e.width,o=e.height,a=e.stroke,s=Math.floor(i+o/2)-1;return r.default.createElement(r.default.Fragment,null,r.default.createElement("rect",{x:t,y:i,width:n,height:o,fill:a,stroke:"none"}),r.default.createElement("line",{x1:t+1,y1:s,x2:t+n-1,y2:s,fill:"none",stroke:"#fff"}),r.default.createElement("line",{x1:t+1,y1:s+2,x2:t+n-1,y2:s+2,fill:"none",stroke:"#fff"}))}},{key:"renderTraveller",value:function(e,t){return r.default.isValidElement(e)?r.default.cloneElement(e,t):(0,n.default)(e)?e(t):A.renderDefaultTraveller(t)}},{key:"getDerivedStateFromProps",value:function(e,t){var i=e.data,n=e.width,r=e.x,a=e.travellerWidth,l=e.updateId,c=e.startIndex,d=e.endIndex;if(i!==t.prevData||l!==t.prevUpdateId)return C({prevData:i,prevTravellerWidth:a,prevUpdateId:l,prevX:r,prevWidth:n},i&&i.length?function(e){var t=e.data,i=e.startIndex,n=e.endIndex,r=e.x,a=e.width,l=e.travellerWidth;if(!t||!t.length)return{};var c=t.length,d=(0,s.scalePoint)().domain((0,o.default)(0,c)).range([r,r+a-l]),u=d.domain().map((function(e){return d(e)}));return{isTextActive:!1,isSlideMoving:!1,isTravellerMoving:!1,isTravellerFocused:!1,startX:d(i),endX:d(n),scale:d,scaleValues:u}}({data:i,width:n,x:r,travellerWidth:a,startIndex:c,endIndex:d}):{scale:null,scaleValues:null});if(t.scale&&(n!==t.prevWidth||r!==t.prevX||a!==t.prevTravellerWidth)){t.scale.range([r,r+n-a]);var u=t.scale.domain().map((function(e){return t.scale(e)}));return{prevData:i,prevTravellerWidth:a,prevUpdateId:l,prevX:r,prevWidth:n,startX:t.scale(e.startIndex),endX:t.scale(e.endIndex),scaleValues:u}}return null}},{key:"getIndexInRange",value:function(e,t){for(var i=0,n=e.length-1;n-i>1;){var o=Math.floor((i+n)/2);e[o]>t?n=o:i=o}return t>=e[n]?n:i}}],(i=[{key:"componentWillUnmount",value:function(){this.leaveTimer&&(clearTimeout(this.leaveTimer),this.leaveTimer=null),this.detachDragEndListener()}},{key:"getIndex",value:function(e){var t=e.startX,i=e.endX,n=this.state.scaleValues,o=this.props,r=o.gap,a=o.data.length-1,s=Math.min(t,i),l=Math.max(t,i),c=A.getIndexInRange(n,s),d=A.getIndexInRange(n,l);return{startIndex:c-c%r,endIndex:d===a?a:d-d%r}}},{key:"getTextOfTick",value:function(e){var t=this.props,i=t.data,o=t.tickFormatter,r=t.dataKey,a=(0,d.getValueByDataKey)(i[e],r,e);return(0,n.default)(o)?o(a,e):a}},{key:"attachDragEndListener",value:function(){window.addEventListener("mouseup",this.handleDragEnd,!0),window.addEventListener("touchend",this.handleDragEnd,!0),window.addEventListener("mousemove",this.handleDrag,!0)}},{key:"detachDragEndListener",value:function(){window.removeEventListener("mouseup",this.handleDragEnd,!0),window.removeEventListener("touchend",this.handleDragEnd,!0),window.removeEventListener("mousemove",this.handleDrag,!0)}},{key:"handleSlideDrag",value:function(e){var t=this.state,i=t.slideMoveStartX,n=t.startX,o=t.endX,r=this.props,a=r.x,s=r.width,l=r.travellerWidth,c=r.startIndex,d=r.endIndex,u=r.onChange,h=e.pageX-i;h>0?h=Math.min(h,a+s-l-o,a+s-l-n):h<0&&(h=Math.max(h,a-n,a-o));var p=this.getIndex({startX:n+h,endX:o+h});p.startIndex===c&&p.endIndex===d||!u||u(p),this.setState({startX:n+h,endX:o+h,slideMoveStartX:e.pageX})}},{key:"handleTravellerDragStart",value:function(e,t){var i=P(t)?t.changedTouches[0]:t;this.setState({isSlideMoving:!1,isTravellerMoving:!0,movingTravellerId:e,brushMoveStartX:i.pageX}),this.attachDragEndListener()}},{key:"handleTravellerMove",value:function(e){var t,i=this.state,n=i.brushMoveStartX,o=i.movingTravellerId,r=i.endX,a=i.startX,s=this.state[o],l=this.props,c=l.x,d=l.width,u=l.travellerWidth,h=l.onChange,p=l.gap,g=l.data,f={startX:this.state.startX,endX:this.state.endX},m=e.pageX-n;m>0?m=Math.min(m,c+d-u-s):m<0&&(m=Math.max(m,c-s)),f[o]=s+m;var v=this.getIndex(f),y=v.startIndex,C=v.endIndex;this.setState((w(t={},o,s+m),w(t,"brushMoveStartX",e.pageX),t),(function(){var e;h&&(e=g.length-1,("startX"===o&&(r>a?y%p==0:C%p==0)||r<a&&C===e||"endX"===o&&(r>a?C%p==0:y%p==0)||r>a&&C===e)&&h(v))}))}},{key:"handleTravellerMoveKeyboard",value:function(e,t){var i=this,n=this.state,o=n.scaleValues,r=n.startX,a=n.endX,s=this.state[t],l=o.indexOf(s);if(-1!==l){var c=l+e;if(!(-1===c||c>=o.length)){var d=o[c];"startX"===t&&d>=a||"endX"===t&&d<=r||this.setState(w({},t,d),(function(){i.props.onChange(i.getIndex({startX:i.state.startX,endX:i.state.endX}))}))}}}},{key:"renderBackground",value:function(){var e=this.props,t=e.x,i=e.y,n=e.width,o=e.height,a=e.fill,s=e.stroke;return r.default.createElement("rect",{stroke:s,fill:a,x:t,y:i,width:n,height:o})}},{key:"renderPanorama",value:function(){var e=this.props,t=e.x,i=e.y,n=e.width,o=e.height,a=e.data,s=e.children,l=e.padding,c=r.Children.only(s);return c?r.default.cloneElement(c,{x:t,y:i,width:n,height:o,margin:l,compact:!0,data:a}):null}},{key:"renderTravellerLayer",value:function(e,t){var i=this,n=this.props,o=n.y,a=n.travellerWidth,s=n.height,c=n.traveller,d=Math.max(e,this.props.x),u=C(C({},(0,p.filterProps)(this.props)),{},{x:d,y:o,width:a,height:s});return r.default.createElement(l.Layer,{tabIndex:0,role:"slider",className:"recharts-brush-traveller",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[t],onTouchStart:this.travellerDragStartHandlers[t],onKeyDown:function(e){["ArrowLeft","ArrowRight"].includes(e.key)&&(e.preventDefault(),e.stopPropagation(),i.handleTravellerMoveKeyboard("ArrowRight"===e.key?1:-1,t))},onFocus:function(){i.setState({isTravellerFocused:!0})},onBlur:function(){i.setState({isTravellerFocused:!1})},style:{cursor:"col-resize"}},A.renderTraveller(c,u))}},{key:"renderSlide",value:function(e,t){var i=this.props,n=i.y,o=i.height,a=i.stroke,s=i.travellerWidth,l=Math.min(e,t)+s,c=Math.max(Math.abs(t-e)-s,0);return r.default.createElement("rect",{className:"recharts-brush-slide",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.handleSlideDragStart,onTouchStart:this.handleSlideDragStart,style:{cursor:"move"},stroke:"none",fill:a,fillOpacity:.2,x:l,y:n,width:c,height:o})}},{key:"renderText",value:function(){var e=this.props,t=e.startIndex,i=e.endIndex,n=e.y,o=e.height,a=e.travellerWidth,s=e.stroke,d=this.state,u=d.startX,h=d.endX,p={pointerEvents:"none",fill:s};return r.default.createElement(l.Layer,{className:"recharts-brush-texts"},r.default.createElement(c.Text,v({textAnchor:"end",verticalAnchor:"middle",x:Math.min(u,h)-5,y:n+o/2},p),this.getTextOfTick(t)),r.default.createElement(c.Text,v({textAnchor:"start",verticalAnchor:"middle",x:Math.max(u,h)+a+5,y:n+o/2},p),this.getTextOfTick(i)))}},{key:"render",value:function(){var e=this.props,t=e.data,i=e.className,n=e.children,o=e.x,s=e.y,c=e.width,d=e.height,p=e.alwaysShowText,g=this.state,f=g.startX,m=g.endX,v=g.isTextActive,y=g.isSlideMoving,C=g.isTravellerMoving,b=g.isTravellerFocused;if(!t||!t.length||!(0,u.isNumber)(o)||!(0,u.isNumber)(s)||!(0,u.isNumber)(c)||!(0,u.isNumber)(d)||c<=0||d<=0)return null;var S=(0,a.default)("recharts-brush",i),x=1===r.default.Children.count(n),T=(0,h.generatePrefixStyle)("userSelect","none");return r.default.createElement(l.Layer,{className:S,onMouseLeave:this.handleLeaveWrapper,onTouchMove:this.handleTouchMove,style:T},this.renderBackground(),x&&this.renderPanorama(),this.renderSlide(f,m),this.renderTravellerLayer(f,"startX"),this.renderTravellerLayer(m,"endX"),(v||y||C||b||p)&&this.renderText())}}])&&b(t.prototype,i),g&&b(t,g),Object.defineProperty(t,"prototype",{writable:!1}),A}(r.PureComponent);t.B=A,w(A,"displayName","Brush"),w(A,"defaultProps",{height:40,travellerWidth:5,gap:1,fill:"#fff",stroke:"#666",padding:{top:1,right:1,bottom:1,left:1},leaveTimeOut:1e3,alwaysShowText:!1})},63394:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ErrorBar=d;var n,o=(n=i(8559))&&n.__esModule?n:{default:n},r=i(61441),a=i(48828),s=["offset","layout","width","dataKey","data","dataPointFormatter","xAxis","yAxis"];function l(){return l=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},l.apply(this,arguments)}function c(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}function d(e){var t=e.offset,i=e.layout,n=e.width,d=e.dataKey,u=e.data,h=e.dataPointFormatter,p=e.xAxis,g=e.yAxis,f=function(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}(e,s),m=(0,a.filterProps)(f),v=u.map((function(e,a){var s=h(e,d),u=s.x,f=s.y,v=s.value,y=s.errorVal;if(!y)return null;var C,b,S=[];if(Array.isArray(y)){var x=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var n,o,r,a,s=[],l=!0,c=!1;try{if(r=(i=i.call(e)).next,0===t){if(Object(i)!==i)return;l=!1}else for(;!(l=(n=r.call(i)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=i.return&&(a=i.return(),Object(a)!==a))return}finally{if(c)throw o}}return s}}(e,t)||function(e,t){if(e){if("string"==typeof e)return c(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?c(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(y,2);C=x[0],b=x[1]}else C=b=y;if("vertical"===i){var T=p.scale,w=f+t,O=w+n,P=w-n,A=T(v-C),E=T(v+b);S.push({x1:E,y1:O,x2:E,y2:P}),S.push({x1:A,y1:w,x2:E,y2:w}),S.push({x1:A,y1:O,x2:A,y2:P})}else if("horizontal"===i){var k=g.scale,I=u+t,D=I-n,_=I+n,N=k(v-C),R=k(v+b);S.push({x1:D,y1:R,x2:_,y2:R}),S.push({x1:I,y1:N,x2:I,y2:R}),S.push({x1:D,y1:N,x2:_,y2:N})}return o.default.createElement(r.Layer,l({className:"recharts-errorBar",key:"bar-".concat(a)},m),S.map((function(e,t){return o.default.createElement("line",l({},e,{key:"line-".concat(t)}))})))}));return o.default.createElement(r.Layer,{className:"recharts-errorBars"},v)}d.defaultProps={stroke:"black",strokeWidth:1.5,width:5,offset:0,layout:"horizontal"},d.displayName="ErrorBar"},67303:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ReferenceArea=b;var n=g(i(40825)),o=g(i(8559)),r=g(i(33680)),a=i(61441),s=i(36893),l=i(12618),c=i(15402),d=i(47320),u=i(91248),h=i(53042),p=i(48828);function g(e){return e&&e.__esModule?e:{default:e}}function f(e){return f="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},f(e)}function m(){return m=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},m.apply(this,arguments)}function v(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function y(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?v(Object(i),!0).forEach((function(t){var n,o,r;n=e,o=t,r=i[t],(o=function(e){var t=function(e,t){if("object"!==f(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==f(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===f(t)?t:String(t)}(o))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):v(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var C=function(e,t,i,n,o){var r=o.x1,a=o.x2,s=o.y1,d=o.y2,u=o.xAxis,h=o.yAxis;if(!u||!h)return null;var p=(0,l.createLabeledScales)({x:u.scale,y:h.scale}),g={x:e?p.x.apply(r,{position:"start"}):p.x.rangeMin,y:i?p.y.apply(s,{position:"start"}):p.y.rangeMin},f={x:t?p.x.apply(a,{position:"end"}):p.x.rangeMax,y:n?p.y.apply(d,{position:"end"}):p.y.rangeMax};return!(0,c.ifOverflowMatches)(o,"discard")||p.isInRange(g)&&p.isInRange(f)?(0,l.rectWithPoints)(g,f):null};function b(e){var t=e.x1,i=e.x2,n=e.y1,l=e.y2,h=e.className,g=e.alwaysShow,f=e.clipPathId;(0,u.warn)(void 0===g,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var m=(0,d.isNumOrStr)(t),v=(0,d.isNumOrStr)(i),S=(0,d.isNumOrStr)(n),x=(0,d.isNumOrStr)(l),T=e.shape;if(!(m||v||S||x||T))return null;var w=C(m,v,S,x,e);if(!w&&!T)return null;var O=(0,c.ifOverflowMatches)(e,"hidden")?"url(#".concat(f,")"):void 0;return o.default.createElement(a.Layer,{className:(0,r.default)("recharts-reference-area",h)},b.renderRect(T,y(y({clipPath:O},(0,p.filterProps)(e,!0)),w)),s.Label.renderCallByParent(e,w))}b.displayName="ReferenceArea",b.defaultProps={isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#ccc",fillOpacity:.5,stroke:"none",strokeWidth:1},b.renderRect=function(e,t){return o.default.isValidElement(e)?o.default.cloneElement(e,t):(0,n.default)(e)?e(t):o.default.createElement(h.Rectangle,m({},t,{className:"recharts-reference-area-rect"}))}},18426:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ReferenceDot=b;var n=g(i(40825)),o=g(i(8559)),r=g(i(33680)),a=i(61441),s=i(49566),l=i(36893),c=i(47320),d=i(15402),u=i(12618),h=i(91248),p=i(48828);function g(e){return e&&e.__esModule?e:{default:e}}function f(e){return f="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},f(e)}function m(){return m=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},m.apply(this,arguments)}function v(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function y(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?v(Object(i),!0).forEach((function(t){var n,o,r;n=e,o=t,r=i[t],(o=function(e){var t=function(e,t){if("object"!==f(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==f(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===f(t)?t:String(t)}(o))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):v(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var C=function(e){var t=e.x,i=e.y,n=e.xAxis,o=e.yAxis,r=(0,u.createLabeledScales)({x:n.scale,y:o.scale}),a=r.apply({x:t,y:i},{bandAware:!0});return(0,d.ifOverflowMatches)(e,"discard")&&!r.isInRange(a)?null:a};function b(e){var t=e.x,i=e.y,n=e.r,s=e.alwaysShow,u=e.clipPathId,g=(0,c.isNumOrStr)(t),f=(0,c.isNumOrStr)(i);if((0,h.warn)(void 0===s,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.'),!g||!f)return null;var m=C(e);if(!m)return null;var v=m.x,S=m.y,x=e.shape,T=e.className,w=y(y({clipPath:(0,d.ifOverflowMatches)(e,"hidden")?"url(#".concat(u,")"):void 0},(0,p.filterProps)(e,!0)),{},{cx:v,cy:S});return o.default.createElement(a.Layer,{className:(0,r.default)("recharts-reference-dot",T)},b.renderDot(x,w),l.Label.renderCallByParent(e,{x:v-n,y:S-n,width:2*n,height:2*n}))}b.displayName="ReferenceDot",b.defaultProps={isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#fff",stroke:"#ccc",fillOpacity:1,strokeWidth:1},b.renderDot=function(e,t){return o.default.isValidElement(e)?o.default.cloneElement(e,t):(0,n.default)(e)?e(t):o.default.createElement(s.Dot,m({},t,{cx:t.cx,cy:t.cy,className:"recharts-reference-dot-dot"}))}},58459:function(e,t,i){"use strict";function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.ReferenceLine=x;var o=f(i(93525)),r=f(i(40825)),a=f(i(8559)),s=f(i(33680)),l=i(61441),c=i(36893),d=i(15402),u=i(47320),h=i(12618),p=i(91248),g=i(48828);function f(e){return e&&e.__esModule?e:{default:e}}function m(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function v(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?m(Object(i),!0).forEach((function(t){var o,r,a;o=e,r=t,a=i[t],(r=function(e){var t=function(e,t){if("object"!==n(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var o=i.call(e,"string");if("object"!==n(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===n(t)?t:String(t)}(r))in o?Object.defineProperty(o,r,{value:a,enumerable:!0,configurable:!0,writable:!0}):o[r]=a})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):m(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function y(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}function C(){return C=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},C.apply(this,arguments)}var b=function(e,t){return a.default.isValidElement(e)?a.default.cloneElement(e,t):(0,r.default)(e)?e(t):a.default.createElement("line",C({},t,{className:"recharts-reference-line-line"}))},S=function(e,t,i,n,r){var a=r.viewBox,s=a.x,l=a.y,c=a.width,u=a.height,h=r.position;if(i){var p=r.y,g=r.yAxis.orientation,f=e.y.apply(p,{position:h});if((0,d.ifOverflowMatches)(r,"discard")&&!e.y.isInRange(f))return null;var m=[{x:s+c,y:f},{x:s,y:f}];return"left"===g?m.reverse():m}if(t){var v=r.x,y=r.xAxis.orientation,C=e.x.apply(v,{position:h});if((0,d.ifOverflowMatches)(r,"discard")&&!e.x.isInRange(C))return null;var b=[{x:C,y:l+u},{x:C,y:l}];return"top"===y?b.reverse():b}if(n){var S=r.segment.map((function(t){return e.apply(t,{position:h})}));return(0,d.ifOverflowMatches)(r,"discard")&&(0,o.default)(S,(function(t){return!e.isInRange(t)}))?null:S}return null};function x(e){var t=e.x,i=e.y,n=e.segment,o=e.xAxis,r=e.yAxis,f=e.shape,m=e.className,C=e.alwaysShow,x=e.clipPathId;(0,p.warn)(void 0===C,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var T=(0,h.createLabeledScales)({x:o.scale,y:r.scale}),w=(0,u.isNumOrStr)(t),O=(0,u.isNumOrStr)(i),P=n&&2===n.length,A=S(T,w,O,P,e);if(!A)return null;var E,k,I=(k=2,function(e){if(Array.isArray(e))return e}(E=A)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var n,o,r,a,s=[],l=!0,c=!1;try{if(r=(i=i.call(e)).next,0===t){if(Object(i)!==i)return;l=!1}else for(;!(l=(n=r.call(i)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=i.return&&(a=i.return(),Object(a)!==a))return}finally{if(c)throw o}}return s}}(E,k)||function(e,t){if(e){if("string"==typeof e)return y(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?y(e,t):void 0}}(E,k)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),D=I[0],_=D.x,N=D.y,R=I[1],M=R.x,L=R.y,B=v(v({clipPath:(0,d.ifOverflowMatches)(e,"hidden")?"url(#".concat(x,")"):void 0},(0,g.filterProps)(e,!0)),{},{x1:_,y1:N,x2:M,y2:L});return a.default.createElement(l.Layer,{className:(0,s.default)("recharts-reference-line",m)},b(f,B),c.Label.renderCallByParent(e,(0,h.rectWithCoords)({x1:_,y1:N,x2:M,y2:L})))}x.displayName="ReferenceLine",x.defaultProps={isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,fill:"none",stroke:"#ccc",fillOpacity:1,strokeWidth:1,position:"middle"}},45138:function(e,t){"use strict";t.K=void 0;var i=function(){return null};t.K=i,i.displayName="XAxis",i.defaultProps={allowDecimals:!0,hide:!1,orientation:"bottom",width:0,height:30,mirror:!1,xAxisId:0,tickCount:5,type:"category",padding:{left:0,right:0},allowDataOverflow:!1,scale:"auto",reversed:!1,allowDuplicatedCategory:!0}},28071:function(e,t){"use strict";t.B=void 0;var i=function(){return null};t.B=i,i.displayName="YAxis",i.defaultProps={allowDuplicatedCategory:!0,allowDecimals:!0,hide:!1,orientation:"left",width:60,height:0,mirror:!1,yAxisId:0,tickCount:5,type:"number",padding:{top:0,bottom:0},allowDataOverflow:!1,scale:"auto",reversed:!1}},54349:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getEquidistantTicks=function(e,t,i,r,a){for(var s=(r||[]).slice(),l=t.start,c=t.end,d=0,u=1,h=l;u<=s.length;){var p=null==r?void 0:r[d];if(void 0===p)return(0,o.getEveryNthWithCondition)(r,u);var g=i(p,d),f=p.coordinate,m=0===d||(0,n.isVisible)(e,f,g,h,c);m||(d=0,h=l,u+=1),m&&(h=f+e*(g/2+a),d+=u)}return[]};var n=i(89211),o=i(87416)},10428:function(e,t,i){"use strict";t.f=function(e,t,i){var n=e.tick,d=e.ticks,u=e.viewBox,p=e.minTickGap,g=e.orientation,f=e.interval,m=e.tickFormatter,v=e.unit,y=e.angle;if(!d||!d.length||!n)return[];if((0,r.isNumber)(f)||s.Global.isSsr)return(0,l.getNumberIntervalTicks)(d,"number"==typeof f&&(0,r.isNumber)(f)?f:0);var C=[],b="top"===g||"bottom"===g?"width":"height",S=v&&"width"===b?(0,a.getStringSize)(v,{fontSize:t,letterSpacing:i}):{width:0,height:0},x=function(e,n){var r=(0,o.default)(m)?m(e.value,n):e.value;return"width"===b?(0,l.getAngledTickWidth)((0,a.getStringSize)(r,{fontSize:t,letterSpacing:i}),S,y):(0,a.getStringSize)(r,{fontSize:t,letterSpacing:i})[b]},T=d.length>=2?(0,r.mathSign)(d[1].coordinate-d[0].coordinate):1,w=(0,l.getTickBoundaries)(u,T,b);return"equidistantPreserveStart"===f?(0,c.getEquidistantTicks)(T,w,x,d,p):(C="preserveStart"===f||"preserveStartEnd"===f?function(e,t,i,n,o,r){var a=(n||[]).slice(),s=a.length,c=t.start,d=t.end;if(r){var u=n[s-1],p=i(u,s-1),g=e*(u.coordinate+e*p/2-d);a[s-1]=u=h(h({},u),{},{tickCoord:g>0?u.coordinate-g*e:u.coordinate}),(0,l.isVisible)(e,u.tickCoord,p,c,d)&&(d=u.tickCoord-e*(p/2+o),a[s-1]=h(h({},u),{},{isShow:!0}))}for(var f=r?s-1:s,m=0;m<f;m++){var v=a[m],y=i(v,m);if(0===m){var C=e*(v.coordinate-e*y/2-c);a[m]=v=h(h({},v),{},{tickCoord:C<0?v.coordinate-C*e:v.coordinate})}else a[m]=v=h(h({},v),{},{tickCoord:v.coordinate});(0,l.isVisible)(e,v.tickCoord,y,c,d)&&(c=v.tickCoord+e*(y/2+o),a[m]=h(h({},v),{},{isShow:!0}))}return a}(T,w,x,d,p,"preserveStartEnd"===f):function(e,t,i,n,o){for(var r=(n||[]).slice(),a=r.length,s=t.start,c=t.end,d=a-1;d>=0;d--){var u=r[d],p=i(u,d);if(d===a-1){var g=e*(u.coordinate+e*p/2-c);r[d]=u=h(h({},u),{},{tickCoord:g>0?u.coordinate-g*e:u.coordinate})}else r[d]=u=h(h({},u),{},{tickCoord:u.coordinate});(0,l.isVisible)(e,u.tickCoord,p,s,c)&&(c=u.tickCoord-e*(p/2+o),r[d]=h(h({},u),{},{isShow:!0}))}return r}(T,w,x,d,p),C.filter((function(e){return e.isShow})))};var n,o=(n=i(40825))&&n.__esModule?n:{default:n},r=i(47320),a=i(8959),s=i(68304),l=i(89211),c=i(54349);function d(e){return d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},d(e)}function u(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function h(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?u(Object(i),!0).forEach((function(t){p(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):u(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function p(e,t,i){return(t=function(e){var t=function(e,t){if("object"!==d(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==d(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===d(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}},54704:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Cell=void 0;var i=function(e){return null};t.Cell=i,i.displayName="Cell"},75233:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DefaultLegendContent=void 0;var n=u(i(40825)),o=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!==h(e)&&"function"!=typeof e)return{default:e};var i=d(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}(i(8559)),r=u(i(33680)),a=i(91248),s=i(93273),l=i(50918),c=i(13630);function d(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(d=function(e){return e?i:t})(e)}function u(e){return e&&e.__esModule?e:{default:e}}function h(e){return h="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},h(e)}function p(){return p=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},p.apply(this,arguments)}function g(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function f(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,C(n.key),n)}}function m(e,t){return m=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},m(e,t)}function v(e){return v=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},v(e)}function y(e,t,i){return(t=C(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function C(e){var t=function(e,t){if("object"!==h(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==h(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===h(t)?t:String(t)}var b=32,S=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&m(e,t)}(S,e);var t,i,d,u,C=(d=S,u=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=v(d);if(u){var i=v(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===h(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(this,e)});function S(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,S),C.apply(this,arguments)}return t=S,i=[{key:"renderIcon",value:function(e){var t=this.props.inactiveColor,i=16,n=b/6,r=b/3,a=e.inactive?t:e.color;if("plainline"===e.type)return o.default.createElement("line",{strokeWidth:4,fill:"none",stroke:a,strokeDasharray:e.payload.strokeDasharray,x1:0,y1:i,x2:b,y2:i,className:"recharts-legend-icon"});if("line"===e.type)return o.default.createElement("path",{strokeWidth:4,fill:"none",stroke:a,d:"M0,".concat(i,"h").concat(r,"\n A").concat(n,",").concat(n,",0,1,1,").concat(2*r,",").concat(i,"\n H").concat(b,"M").concat(2*r,",").concat(i,"\n A").concat(n,",").concat(n,",0,1,1,").concat(r,",").concat(i),className:"recharts-legend-icon"});if("rect"===e.type)return o.default.createElement("path",{stroke:"none",fill:a,d:"M0,".concat(4,"h").concat(b,"v").concat(24,"h").concat(-32,"z"),className:"recharts-legend-icon"});if(o.default.isValidElement(e.legendIcon)){var s=function(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?g(Object(i),!0).forEach((function(t){y(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):g(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}({},e);return delete s.legendIcon,o.default.cloneElement(e.legendIcon,s)}return o.default.createElement(l.Symbols,{fill:a,cx:i,cy:i,size:b,sizeType:"diameter",type:e.type})}},{key:"renderItems",value:function(){var e=this,t=this.props,i=t.payload,l=t.iconSize,d=t.layout,u=t.formatter,h=t.inactiveColor,g={x:0,y:0,width:b,height:b},f={display:"horizontal"===d?"inline-block":"block",marginRight:10},m={display:"inline-block",verticalAlign:"middle",marginRight:4};return i.map((function(t,i){var d,v=t.formatter||u,C=(0,r.default)((y(d={"recharts-legend-item":!0},"legend-item-".concat(i),!0),y(d,"inactive",t.inactive),d));if("none"===t.type)return null;var b=(0,n.default)(t.value)?null:t.value;(0,a.warn)(!(0,n.default)(t.value),'The name property is also required when using a function for the dataKey of a chart\'s cartesian components. Ex: <Bar name="Name of my Data"/>');var S=t.inactive?h:t.color;return o.default.createElement("li",p({className:C,style:f,key:"legend-item-".concat(i)},(0,c.adaptEventsOfChild)(e.props,t,i)),o.default.createElement(s.Surface,{width:l,height:l,viewBox:g,style:m},e.renderIcon(t)),o.default.createElement("span",{className:"recharts-legend-item-text",style:{color:S}},v?v(b,t,i):b))}))}},{key:"render",value:function(){var e=this.props,t=e.payload,i=e.layout,n=e.align;if(!t||!t.length)return null;var r={padding:0,margin:0,textAlign:"horizontal"===i?n:"left"};return o.default.createElement("ul",{className:"recharts-default-legend",style:r},this.renderItems())}}],i&&f(t.prototype,i),Object.defineProperty(t,"prototype",{writable:!1}),S}(o.PureComponent);t.DefaultLegendContent=S,y(S,"displayName","Legend"),y(S,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"middle",inactiveColor:"#ccc"})},2068:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DefaultTooltipContent=void 0;var n=c(i(18562)),o=c(i(57657)),r=c(i(83008)),a=c(i(8559)),s=c(i(33680)),l=i(47320);function c(e){return e&&e.__esModule?e:{default:e}}function d(e){return d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},d(e)}function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}function h(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function p(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?h(Object(i),!0).forEach((function(t){var n,o,r;n=e,o=t,r=i[t],(o=function(e){var t=function(e,t){if("object"!==d(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==d(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===d(t)?t:String(t)}(o))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):h(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function g(e){return(0,r.default)(e)&&(0,l.isNumOrStr)(e[0])&&(0,l.isNumOrStr)(e[1])?e.join(" ~ "):e}t.DefaultTooltipContent=function(e){var t=e.separator,i=void 0===t?" : ":t,r=e.contentStyle,c=void 0===r?{}:r,d=e.itemStyle,h=void 0===d?{}:d,f=e.labelStyle,m=void 0===f?{}:f,v=e.payload,y=e.formatter,C=e.itemSorter,b=e.wrapperClassName,S=e.labelClassName,x=e.label,T=e.labelFormatter,w=p({margin:0,padding:10,backgroundColor:"#fff",border:"1px solid #ccc",whiteSpace:"nowrap"},c),O=p({margin:0},m),P=!(0,n.default)(x),A=P?x:"",E=(0,s.default)("recharts-default-tooltip",b),k=(0,s.default)("recharts-tooltip-label",S);return P&&T&&null!=v&&(A=T(x,v)),a.default.createElement("div",{className:E,style:w},a.default.createElement("p",{className:k,style:O},a.default.isValidElement(A)?A:"".concat(A)),function(){if(v&&v.length){var e=(C?(0,o.default)(v,C):v).map((function(e,t){if("none"===e.type)return null;var n=p({display:"block",paddingTop:4,paddingBottom:4,color:e.color||"#000"},h),o=e.formatter||y||g,r=e.value,s=e.name,c=r,d=s;if(o&&null!=c&&null!=d){var f=o(r,s,e,t,v);if(Array.isArray(f)){var m=function(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var n,o,r,a,s=[],l=!0,c=!1;try{if(r=(i=i.call(e)).next,0===t){if(Object(i)!==i)return;l=!1}else for(;!(l=(n=r.call(i)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=i.return&&(a=i.return(),Object(a)!==a))return}finally{if(c)throw o}}return s}}(e,t)||function(e,t){if(e){if("string"==typeof e)return u(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?u(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}(f,2);c=m[0],d=m[1]}else c=f}return a.default.createElement("li",{className:"recharts-tooltip-item",key:"tooltip-item-".concat(t),style:n},(0,l.isNumOrStr)(d)?a.default.createElement("span",{className:"recharts-tooltip-item-name"},d):null,(0,l.isNumOrStr)(d)?a.default.createElement("span",{className:"recharts-tooltip-item-separator"},i):null,a.default.createElement("span",{className:"recharts-tooltip-item-value"},c),a.default.createElement("span",{className:"recharts-tooltip-item-unit"},e.unit||""))}));return a.default.createElement("ul",{className:"recharts-tooltip-item-list",style:{padding:0,margin:0}},e)}return null}())}},36893:function(e,t,i){"use strict";function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.Label=O;var o=f(i(63991)),r=f(i(40825)),a=f(i(18562)),s=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!==n(e)&&"function"!=typeof e)return{default:e};var i=g(t);if(i&&i.has(e))return i.get(e);var o={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if("default"!==a&&Object.prototype.hasOwnProperty.call(e,a)){var s=r?Object.getOwnPropertyDescriptor(e,a):null;s&&(s.get||s.set)?Object.defineProperty(o,a,s):o[a]=e[a]}return o.default=e,i&&i.set(e,o),o}(i(8559)),l=f(i(33680)),c=i(93903),d=i(48828),u=i(47320),h=i(60212),p=["offset"];function g(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(g=function(e){return e?i:t})(e)}function f(e){return e&&e.__esModule?e:{default:e}}function m(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}function v(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function y(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?v(Object(i),!0).forEach((function(t){var o,r,a;o=e,r=t,a=i[t],(r=function(e){var t=function(e,t){if("object"!==n(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var o=i.call(e,"string");if("object"!==n(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===n(t)?t:String(t)}(r))in o?Object.defineProperty(o,r,{value:a,enumerable:!0,configurable:!0,writable:!0}):o[r]=a})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):v(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function C(){return C=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},C.apply(this,arguments)}var b=function(e){var t=e.value,i=e.formatter,n=(0,a.default)(e.children)?t:e.children;return(0,r.default)(i)?i(n):n},S=function(e,t,i){var n,o,r=e.position,c=e.viewBox,d=e.offset,p=e.className,g=c,f=g.cx,m=g.cy,v=g.innerRadius,y=g.outerRadius,b=g.startAngle,S=g.endAngle,x=g.clockWise,T=(v+y)/2,w=function(e,t){return(0,u.mathSign)(t-e)*Math.min(Math.abs(t-e),360)}(b,S),O=w>=0?1:-1;"insideStart"===r?(n=b+O*d,o=x):"insideEnd"===r?(n=S-O*d,o=!x):"end"===r&&(n=S+O*d,o=x),o=w<=0?o:!o;var P=(0,h.polarToCartesian)(f,m,T,n),A=(0,h.polarToCartesian)(f,m,T,n+359*(o?1:-1)),E="M".concat(P.x,",").concat(P.y,"\n A").concat(T,",").concat(T,",0,1,").concat(o?0:1,",\n ").concat(A.x,",").concat(A.y),k=(0,a.default)(e.id)?(0,u.uniqueId)("recharts-radial-line-"):e.id;return s.default.createElement("text",C({},i,{dominantBaseline:"central",className:(0,l.default)("recharts-radial-bar-label",p)}),s.default.createElement("defs",null,s.default.createElement("path",{id:k,d:E})),s.default.createElement("textPath",{xlinkHref:"#".concat(k)},t))},x=function(e){var t=e.viewBox,i=e.offset,n=e.position,o=t,r=o.cx,a=o.cy,s=o.innerRadius,l=o.outerRadius,c=(o.startAngle+o.endAngle)/2;if("outside"===n){var d=(0,h.polarToCartesian)(r,a,l+i,c),u=d.x;return{x:u,y:d.y,textAnchor:u>=r?"start":"end",verticalAnchor:"middle"}}if("center"===n)return{x:r,y:a,textAnchor:"middle",verticalAnchor:"middle"};if("centerTop"===n)return{x:r,y:a,textAnchor:"middle",verticalAnchor:"start"};if("centerBottom"===n)return{x:r,y:a,textAnchor:"middle",verticalAnchor:"end"};var p=(s+l)/2,g=(0,h.polarToCartesian)(r,a,p,c);return{x:g.x,y:g.y,textAnchor:"middle",verticalAnchor:"middle"}},T=function(e){var t=e.viewBox,i=e.parentViewBox,n=e.offset,r=e.position,a=t,s=a.x,l=a.y,c=a.width,d=a.height,h=d>=0?1:-1,p=h*n,g=h>0?"end":"start",f=h>0?"start":"end",m=c>=0?1:-1,v=m*n,C=m>0?"end":"start",b=m>0?"start":"end";if("top"===r)return y(y({},{x:s+c/2,y:l-h*n,textAnchor:"middle",verticalAnchor:g}),i?{height:Math.max(l-i.y,0),width:c}:{});if("bottom"===r)return y(y({},{x:s+c/2,y:l+d+p,textAnchor:"middle",verticalAnchor:f}),i?{height:Math.max(i.y+i.height-(l+d),0),width:c}:{});if("left"===r){var S={x:s-v,y:l+d/2,textAnchor:C,verticalAnchor:"middle"};return y(y({},S),i?{width:Math.max(S.x-i.x,0),height:d}:{})}if("right"===r){var x={x:s+c+v,y:l+d/2,textAnchor:b,verticalAnchor:"middle"};return y(y({},x),i?{width:Math.max(i.x+i.width-x.x,0),height:d}:{})}var T=i?{width:c,height:d}:{};return"insideLeft"===r?y({x:s+v,y:l+d/2,textAnchor:b,verticalAnchor:"middle"},T):"insideRight"===r?y({x:s+c-v,y:l+d/2,textAnchor:C,verticalAnchor:"middle"},T):"insideTop"===r?y({x:s+c/2,y:l+p,textAnchor:"middle",verticalAnchor:f},T):"insideBottom"===r?y({x:s+c/2,y:l+d-p,textAnchor:"middle",verticalAnchor:g},T):"insideTopLeft"===r?y({x:s+v,y:l+p,textAnchor:b,verticalAnchor:f},T):"insideTopRight"===r?y({x:s+c-v,y:l+p,textAnchor:C,verticalAnchor:f},T):"insideBottomLeft"===r?y({x:s+v,y:l+d-p,textAnchor:b,verticalAnchor:g},T):"insideBottomRight"===r?y({x:s+c-v,y:l+d-p,textAnchor:C,verticalAnchor:g},T):(0,o.default)(r)&&((0,u.isNumber)(r.x)||(0,u.isPercent)(r.x))&&((0,u.isNumber)(r.y)||(0,u.isPercent)(r.y))?y({x:s+(0,u.getPercentValue)(r.x,c),y:l+(0,u.getPercentValue)(r.y,d),textAnchor:"end",verticalAnchor:"end"},T):y({x:s+c/2,y:l+d/2,textAnchor:"middle",verticalAnchor:"middle"},T)},w=function(e){return"cx"in e&&(0,u.isNumber)(e.cx)};function O(e){var t,i=e.offset,n=y({offset:void 0===i?5:i},function(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}(e,p)),o=n.viewBox,u=n.position,h=n.value,g=n.children,f=n.content,m=n.className,v=void 0===m?"":m,O=n.textBreakAll;if(!o||(0,a.default)(h)&&(0,a.default)(g)&&!(0,s.isValidElement)(f)&&!(0,r.default)(f))return null;if((0,s.isValidElement)(f))return(0,s.cloneElement)(f,n);if((0,r.default)(f)){if(t=(0,s.createElement)(f,n),(0,s.isValidElement)(t))return t}else t=b(n);var P=w(o),A=(0,d.filterProps)(n,!0);if(P&&("insideStart"===u||"insideEnd"===u||"end"===u))return S(n,t,A);var E=P?x(n):T(n);return s.default.createElement(c.Text,C({className:(0,l.default)("recharts-label",v)},A,E,{breakAll:O}),t)}O.displayName="Label";var P=function(e){var t=e.cx,i=e.cy,n=e.angle,o=e.startAngle,r=e.endAngle,a=e.r,s=e.radius,l=e.innerRadius,c=e.outerRadius,d=e.x,h=e.y,p=e.top,g=e.left,f=e.width,m=e.height,v=e.clockWise,y=e.labelViewBox;if(y)return y;if((0,u.isNumber)(f)&&(0,u.isNumber)(m)){if((0,u.isNumber)(d)&&(0,u.isNumber)(h))return{x:d,y:h,width:f,height:m};if((0,u.isNumber)(p)&&(0,u.isNumber)(g))return{x:p,y:g,width:f,height:m}}return(0,u.isNumber)(d)&&(0,u.isNumber)(h)?{x:d,y:h,width:0,height:0}:(0,u.isNumber)(t)&&(0,u.isNumber)(i)?{cx:t,cy:i,startAngle:o||n||0,endAngle:r||n||0,innerRadius:l||0,outerRadius:c||s||a||0,clockWise:v}:e.viewBox?e.viewBox:{}};O.parseViewBox=P,O.renderCallByParent=function(e,t){var i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];if(!e||!e.children&&i&&!e.label)return null;var n=e.children,a=P(e),l=(0,d.findAllByType)(n,O).map((function(e,i){return(0,s.cloneElement)(e,{viewBox:t||a,key:"label-".concat(i)})}));if(!i)return l;var c,h=function(e,t){return e?!0===e?s.default.createElement(O,{key:"label-implicit",viewBox:t}):(0,u.isNumOrStr)(e)?s.default.createElement(O,{key:"label-implicit",viewBox:t,value:e}):(0,s.isValidElement)(e)?e.type===O?(0,s.cloneElement)(e,{key:"label-implicit",viewBox:t}):s.default.createElement(O,{key:"label-implicit",content:e,viewBox:t}):(0,r.default)(e)?s.default.createElement(O,{key:"label-implicit",content:e,viewBox:t}):(0,o.default)(e)?s.default.createElement(O,C({viewBox:t},e,{key:"label-implicit"})):null:null}(e.label,t||a);return[h].concat(function(e){if(Array.isArray(e))return m(e)}(c=l)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(c)||function(e,t){if(e){if("string"==typeof e)return m(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?m(e,t):void 0}}(c)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}())}},74730:function(e,t,i){"use strict";function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.LabelList=w;var o=v(i(63991)),r=v(i(40825)),a=v(i(18562)),s=v(i(26295)),l=v(i(83008)),c=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!==n(e)&&"function"!=typeof e)return{default:e};var i=m(t);if(i&&i.has(e))return i.get(e);var o={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if("default"!==a&&Object.prototype.hasOwnProperty.call(e,a)){var s=r?Object.getOwnPropertyDescriptor(e,a):null;s&&(s.get||s.set)?Object.defineProperty(o,a,s):o[a]=e[a]}return o.default=e,i&&i.set(e,o),o}(i(8559)),d=i(36893),u=i(61441),h=i(48828),p=i(10455),g=["valueAccessor"],f=["data","dataKey","clockWise","id","textBreakAll"];function m(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(m=function(e){return e?i:t})(e)}function v(e){return e&&e.__esModule?e:{default:e}}function y(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}function C(){return C=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},C.apply(this,arguments)}function b(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function S(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?b(Object(i),!0).forEach((function(t){var o,r,a;o=e,r=t,a=i[t],(r=function(e){var t=function(e,t){if("object"!==n(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var o=i.call(e,"string");if("object"!==n(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===n(t)?t:String(t)}(r))in o?Object.defineProperty(o,r,{value:a,enumerable:!0,configurable:!0,writable:!0}):o[r]=a})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):b(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function x(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}var T=function(e){return(0,l.default)(e.value)?(0,s.default)(e.value):e.value};function w(e){var t=e.valueAccessor,i=void 0===t?T:t,n=x(e,g),o=n.data,r=n.dataKey,s=n.clockWise,l=n.id,m=n.textBreakAll,v=x(n,f);return o&&o.length?c.default.createElement(u.Layer,{className:"recharts-label-list"},o.map((function(e,t){var n=(0,a.default)(r)?i(e,t):(0,p.getValueByDataKey)(e&&e.payload,r),o=(0,a.default)(l)?{}:{id:"".concat(l,"-").concat(t)};return c.default.createElement(d.Label,C({},(0,h.filterProps)(e,!0),v,o,{parentViewBox:e.parentViewBox,index:t,value:n,textBreakAll:m,viewBox:d.Label.parseViewBox((0,a.default)(s)?e:S(S({},e),{},{clockWise:s})),key:"label-".concat(t)}))}))):null}w.displayName="LabelList",w.renderCallByParent=function(e,t){var i=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];if(!e||!e.children&&i&&!e.label)return null;var n,a=e.children,s=(0,h.findAllByType)(a,w).map((function(e,i){return(0,c.cloneElement)(e,{data:t,key:"labelList-".concat(i)})}));return i?[function(e,t){return e?!0===e?c.default.createElement(w,{key:"labelList-implicit",data:t}):c.default.isValidElement(e)||(0,r.default)(e)?c.default.createElement(w,{key:"labelList-implicit",data:t,content:e}):(0,o.default)(e)?c.default.createElement(w,C({data:t},e,{key:"labelList-implicit"})):null:null}(e.label,t)].concat(function(e){if(Array.isArray(e))return y(e)}(n=s)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(n)||function(e,t){if(e){if("string"==typeof e)return y(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?y(e,t):void 0}}(n)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()):s}},36725:function(e,t,i){"use strict";function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.Legend=void 0;var o=u(i(40825)),r=u(i(33504)),a=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!==n(e)&&"function"!=typeof e)return{default:e};var i=d(t);if(i&&i.has(e))return i.get(e);var o={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if("default"!==a&&Object.prototype.hasOwnProperty.call(e,a)){var s=r?Object.getOwnPropertyDescriptor(e,a):null;s&&(s.get||s.set)?Object.defineProperty(o,a,s):o[a]=e[a]}return o.default=e,i&&i.set(e,o),o}(i(8559)),s=i(75233),l=i(47320),c=["ref"];function d(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(d=function(e){return e?i:t})(e)}function u(e){return e&&e.__esModule?e:{default:e}}function h(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function p(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?h(Object(i),!0).forEach((function(t){y(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):h(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function g(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,C(n.key),n)}}function f(e,t){return f=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},f(e,t)}function m(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function v(e){return v=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},v(e)}function y(e,t,i){return(t=C(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function C(e){var t=function(e,t){if("object"!==n(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var o=i.call(e,"string");if("object"!==n(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===n(t)?t:String(t)}function b(e){return e.value}function S(e,t){return!0===e?(0,r.default)(t,b):(0,o.default)(e)?(0,r.default)(t,e):t}var x=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&f(e,t)}(C,e);var t,i,r,d,u,h=(d=C,u=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=v(d);if(u){var i=v(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===n(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return m(e)}(this,e)});function C(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,C);for(var t=arguments.length,i=new Array(t),n=0;n<t;n++)i[n]=arguments[n];return y(m(e=h.call.apply(h,[this].concat(i))),"state",{boxWidth:-1,boxHeight:-1}),e}return t=C,r=[{key:"getWithHeight",value:function(e,t){var i=e.props.layout;return"vertical"===i&&(0,l.isNumber)(e.props.height)?{height:e.props.height}:"horizontal"===i?{width:e.props.width||t}:null}}],(i=[{key:"componentDidMount",value:function(){this.updateBBox()}},{key:"componentDidUpdate",value:function(){this.updateBBox()}},{key:"getBBox",value:function(){return this.wrapperNode&&this.wrapperNode.getBoundingClientRect?this.wrapperNode.getBoundingClientRect():null}},{key:"getBBoxSnapshot",value:function(){var e=this.state,t=e.boxWidth,i=e.boxHeight;return t>=0&&i>=0?{width:t,height:i}:null}},{key:"getDefaultPosition",value:function(e){var t,i,n=this.props,o=n.layout,r=n.align,a=n.verticalAlign,s=n.margin,l=n.chartWidth,c=n.chartHeight;return e&&(void 0!==e.left&&null!==e.left||void 0!==e.right&&null!==e.right)||(t="center"===r&&"vertical"===o?{left:((l||0)-(this.getBBoxSnapshot()||{width:0}).width)/2}:"right"===r?{right:s&&s.right||0}:{left:s&&s.left||0}),e&&(void 0!==e.top&&null!==e.top||void 0!==e.bottom&&null!==e.bottom)||(i="middle"===a?{top:((c||0)-(this.getBBoxSnapshot()||{height:0}).height)/2}:"bottom"===a?{bottom:s&&s.bottom||0}:{top:s&&s.top||0}),p(p({},t),i)}},{key:"updateBBox",value:function(){var e=this.state,t=e.boxWidth,i=e.boxHeight,n=this.props.onBBoxUpdate;if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var o=this.wrapperNode.getBoundingClientRect();(Math.abs(o.width-t)>1||Math.abs(o.height-i)>1)&&this.setState({boxWidth:o.width,boxHeight:o.height},(function(){n&&n(o)}))}else-1===t&&-1===i||this.setState({boxWidth:-1,boxHeight:-1},(function(){n&&n(null)}))}},{key:"render",value:function(){var e=this,t=this.props,i=t.content,n=t.width,r=t.height,l=t.wrapperStyle,d=t.payloadUniqBy,u=t.payload,h=p(p({position:"absolute",width:n||"auto",height:r||"auto"},this.getDefaultPosition(l)),l);return a.default.createElement("div",{className:"recharts-legend-wrapper",style:h,ref:function(t){e.wrapperNode=t}},function(e,t){if(a.default.isValidElement(e))return a.default.cloneElement(e,t);if((0,o.default)(e))return a.default.createElement(e,t);t.ref;var i=function(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}(t,c);return a.default.createElement(s.DefaultLegendContent,i)}(i,p(p({},this.props),{},{payload:S(d,u)})))}}])&&g(t.prototype,i),r&&g(t,r),Object.defineProperty(t,"prototype",{writable:!1}),C}(a.PureComponent);t.Legend=x,y(x,"displayName","Legend"),y(x,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"bottom"})},93903:function(e,t,i){"use strict";function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.Text=void 0;var o=f(i(18562)),r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!==n(e)&&"function"!=typeof e)return{default:e};var i=g(t);if(i&&i.has(e))return i.get(e);var o={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if("default"!==a&&Object.prototype.hasOwnProperty.call(e,a)){var s=r?Object.getOwnPropertyDescriptor(e,a):null;s&&(s.get||s.set)?Object.defineProperty(o,a,s):o[a]=e[a]}return o.default=e,i&&i.set(e,o),o}(i(8559)),a=f(i(33680)),s=i(47320),l=i(68304),c=i(48828),d=i(8959),u=i(68953),h=["x","y","lineHeight","capHeight","scaleToFit","textAnchor","verticalAnchor","fill"],p=["dx","dy","angle","className","breakAll"];function g(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(g=function(e){return e?i:t})(e)}function f(e){return e&&e.__esModule?e:{default:e}}function m(){return m=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},m.apply(this,arguments)}function v(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}function y(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var n,o,r,a,s=[],l=!0,c=!1;try{if(r=(i=i.call(e)).next,0===t){if(Object(i)!==i)return;l=!1}else for(;!(l=(n=r.call(i)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=i.return&&(a=i.return(),Object(a)!==a))return}finally{if(c)throw o}}return s}}(e,t)||function(e,t){if(e){if("string"==typeof e)return C(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?C(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function C(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}var b=/[ \f\n\r\t\v\u2028\u2029]+/,S=function(e){var t=e.children,i=e.breakAll,n=e.style;try{var r=[];return(0,o.default)(t)||(r=i?t.toString().split(""):t.toString().split(b)),{wordsWithComputedWidth:r.map((function(e){return{word:e,width:(0,d.getStringSize)(e,n).width}})),spaceWidth:i?0:(0,d.getStringSize)(" ",n).width}}catch(e){return null}},x=function(e){return[{words:(0,o.default)(e)?[]:e.toString().split(b)}]},T="#808080";t.Text=function(e){var t=e.x,i=void 0===t?0:t,n=e.y,o=void 0===n?0:n,d=e.lineHeight,g=void 0===d?"1em":d,f=e.capHeight,C=void 0===f?"0.71em":f,b=e.scaleToFit,w=void 0!==b&&b,O=e.textAnchor,P=void 0===O?"start":O,A=e.verticalAnchor,E=void 0===A?"end":A,k=e.fill,I=void 0===k?T:k,D=v(e,h),_=(0,r.useMemo)((function(){return function(e){var t=e.width,i=e.scaleToFit,n=e.children,o=e.style,r=e.breakAll,a=e.maxLines;if((t||i)&&!l.Global.isSsr){var c=S({breakAll:r,children:n,style:o});return c?function(e,t,i,n,o){var r=e.maxLines,a=e.children,l=e.style,c=e.breakAll,d=(0,s.isNumber)(r),u=a,h=function(){return(arguments.length>0&&void 0!==arguments[0]?arguments[0]:[]).reduce((function(e,t){var r=t.word,a=t.width,s=e[e.length-1];if(s&&(null==n||o||s.width+a+i<Number(n)))s.words.push(r),s.width+=a+i;else{var l={words:[r],width:a};e.push(l)}return e}),[])},p=h(t);if(!d)return p;for(var g,f=function(e){var t=u.slice(0,e),i=S({breakAll:c,style:l,children:t+"…"}).wordsWithComputedWidth,o=h(i),a=o.length>r||function(e){return e.reduce((function(e,t){return e.width>t.width?e:t}))}(o).width>Number(n);return[a,o]},m=0,v=u.length-1,C=0;m<=v&&C<=u.length-1;){var b=Math.floor((m+v)/2),x=y(f(b-1),2),T=x[0],w=x[1],O=y(f(b),1)[0];if(T||O||(m=b+1),T&&O&&(v=b-1),!T&&O){g=w;break}C++}return g||p}({breakAll:r,children:n,maxLines:a,style:o},c.wordsWithComputedWidth,c.spaceWidth,t,i):x(n)}return x(n)}({breakAll:D.breakAll,children:D.children,maxLines:D.maxLines,scaleToFit:w,style:D.style,width:D.width})}),[D.breakAll,D.children,D.maxLines,w,D.style,D.width]),N=D.dx,R=D.dy,M=D.angle,L=D.className,B=D.breakAll,F=v(D,p);if(!(0,s.isNumOrStr)(i)||!(0,s.isNumOrStr)(o))return null;var U,H=i+((0,s.isNumber)(N)?N:0),$=o+((0,s.isNumber)(R)?R:0);switch(E){case"start":U=(0,u.reduceCSSCalc)("calc(".concat(C,")"));break;case"middle":U=(0,u.reduceCSSCalc)("calc(".concat((_.length-1)/2," * -").concat(g," + (").concat(C," / 2))"));break;default:U=(0,u.reduceCSSCalc)("calc(".concat(_.length-1," * -").concat(g,")"))}var Z=[];if(w){var V=_[0].width,G=D.width;Z.push("scale(".concat(((0,s.isNumber)(G)?G/V:1)/V,")"))}return M&&Z.push("rotate(".concat(M,", ").concat(H,", ").concat($,")")),Z.length&&(F.transform=Z.join(" ")),r.default.createElement("text",m({},(0,c.filterProps)(F,!0),{x:H,y:$,className:(0,a.default)("recharts-text",L),textAnchor:P,fill:I.includes("url")?T:I}),_.map((function(e,t){return r.default.createElement("tspan",{x:H,dy:0===t?U:g,key:t},e.words.join(B?"":" "))})))}},81202:function(e,t,i){"use strict";t.u=void 0;var n=p(i(18562)),o=p(i(40825)),r=p(i(33504)),a=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!==g(e)&&"function"!=typeof e)return{default:e};var i=h(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}(i(8559)),s=i(90480),l=p(i(33680)),c=i(2068),d=i(68304),u=i(47320);function h(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(h=function(e){return e?i:t})(e)}function p(e){return e&&e.__esModule?e:{default:e}}function g(e){return g="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},g(e)}function f(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function m(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?f(Object(i),!0).forEach((function(t){S(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):f(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function v(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,x(n.key),n)}}function y(e,t){return y=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},y(e,t)}function C(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function b(e){return b=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},b(e)}function S(e,t,i){return(t=x(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function x(e){var t=function(e,t){if("object"!==g(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==g(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===g(t)?t:String(t)}var T="recharts-tooltip-wrapper";function w(e){return e.dataKey}var O=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&y(e,t)}(f,e);var t,i,d,h,p=(d=f,h=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=b(d);if(h){var i=b(this).constructor;e=Reflect.construct(t,arguments,i)}else e=t.apply(this,arguments);return function(e,t){if(t&&("object"===g(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return C(e)}(this,e)});function f(){var e;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,f);for(var t=arguments.length,i=new Array(t),n=0;n<t;n++)i[n]=arguments[n];return S(C(e=p.call.apply(p,[this].concat(i))),"state",{boxWidth:-1,boxHeight:-1,dismissed:!1,dismissedAtCoordinate:{x:0,y:0}}),S(C(e),"handleKeyDown",(function(t){"Escape"===t.key&&e.setState({dismissed:!0,dismissedAtCoordinate:m(m({},e.state.dismissedAtCoordinate),{},{x:e.props.coordinate.x,y:e.props.coordinate.y})})})),S(C(e),"getTranslate",(function(t){var i=t.key,n=t.tooltipDimension,o=t.viewBoxDimension,r=e.props,a=r.allowEscapeViewBox,s=r.reverseDirection,l=r.coordinate,c=r.offset,d=r.position,h=r.viewBox;if(d&&(0,u.isNumber)(d[i]))return d[i];var p=l[i]-n-c,g=l[i]+c;return a[i]?s[i]?p:g:s[i]?p<h[i]?Math.max(g,h[i]):Math.max(p,h[i]):g+n>h[i]+o?Math.max(p,h[i]):Math.max(g,h[i])})),e}return t=f,(i=[{key:"componentDidMount",value:function(){this.updateBBox()}},{key:"componentWillUnmount",value:function(){document.removeEventListener("keydown",this.handleKeyDown)}},{key:"componentDidUpdate",value:function(){this.updateBBox()}},{key:"updateBBox",value:function(){var e=this.state,t=e.boxWidth,i=e.boxHeight;if(e.dismissed?(document.removeEventListener("keydown",this.handleKeyDown),this.props.coordinate.x===this.state.dismissedAtCoordinate.x&&this.props.coordinate.y===this.state.dismissedAtCoordinate.y||this.setState({dismissed:!1})):document.addEventListener("keydown",this.handleKeyDown),this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var n=this.wrapperNode.getBoundingClientRect();(Math.abs(n.width-t)>1||Math.abs(n.height-i)>1)&&this.setState({boxWidth:n.width,boxHeight:n.height})}else-1===t&&-1===i||this.setState({boxWidth:-1,boxHeight:-1})}},{key:"render",value:function(){var e,t,i,d=this,h=this.props,p=h.payload,g=h.isAnimationActive,f=h.animationDuration,v=h.animationEasing,y=h.filterNull,C=function(e,t){return!0===e?(0,r.default)(t,w):(0,o.default)(e)?(0,r.default)(t,e):t}(h.payloadUniqBy,y&&p&&p.length?p.filter((function(e){return!(0,n.default)(e.value)})):p),b=C&&C.length,x=this.props,O=x.content,P=x.viewBox,A=x.coordinate,E=x.position,k=x.active,I=x.wrapperStyle,D=m({pointerEvents:"none",visibility:!this.state.dismissed&&k&&b?"visible":"hidden",position:"absolute",top:0,left:0},I);if(E&&(0,u.isNumber)(E.x)&&(0,u.isNumber)(E.y))t=E.x,i=E.y;else{var _=this.state,N=_.boxWidth,R=_.boxHeight;N>0&&R>0&&A?(t=this.getTranslate({key:"x",tooltipDimension:N,viewBoxDimension:P.width}),i=this.getTranslate({key:"y",tooltipDimension:R,viewBoxDimension:P.height})):D.visibility="hidden"}D=m(m({},(0,s.translateStyle)({transform:this.props.useTranslate3d?"translate3d(".concat(t,"px, ").concat(i,"px, 0)"):"translate(".concat(t,"px, ").concat(i,"px)")})),D),g&&k&&(D=m(m({},(0,s.translateStyle)({transition:"transform ".concat(f,"ms ").concat(v)})),D));var M=(0,l.default)(T,(S(e={},"".concat(T,"-right"),(0,u.isNumber)(t)&&A&&(0,u.isNumber)(A.x)&&t>=A.x),S(e,"".concat(T,"-left"),(0,u.isNumber)(t)&&A&&(0,u.isNumber)(A.x)&&t<A.x),S(e,"".concat(T,"-bottom"),(0,u.isNumber)(i)&&A&&(0,u.isNumber)(A.y)&&i>=A.y),S(e,"".concat(T,"-top"),(0,u.isNumber)(i)&&A&&(0,u.isNumber)(A.y)&&i<A.y),e));return a.default.createElement("div",{tabIndex:-1,role:"dialog",className:M,style:D,ref:function(e){d.wrapperNode=e}},function(e,t){return a.default.isValidElement(e)?a.default.cloneElement(e,t):(0,o.default)(e)?a.default.createElement(e,t):a.default.createElement(c.DefaultTooltipContent,t)}(O,m(m({},this.props),{},{payload:C})))}}])&&v(t.prototype,i),Object.defineProperty(t,"prototype",{writable:!1}),f}(a.PureComponent);t.u=O,S(O,"displayName","Tooltip"),S(O,"defaultProps",{active:!1,allowEscapeViewBox:{x:!1,y:!1},reverseDirection:{x:!1,y:!1},offset:10,viewBox:{x:0,y:0,height:0,width:0},coordinate:{x:0,y:0},cursorStyle:{},separator:" : ",wrapperStyle:{},contentStyle:{},itemStyle:{},labelStyle:{},cursor:!0,trigger:"hover",isAnimationActive:!d.Global.isSsr,animationEasing:"ease",animationDuration:400,filterNull:!0,useTranslate3d:!1})},61441:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Layer=void 0;var n=s(i(8559)),o=s(i(33680)),r=i(48828),a=["children","className"];function s(e){return e&&e.__esModule?e:{default:e}}function l(){return l=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},l.apply(this,arguments)}var c=n.default.forwardRef((function(e,t){var i=e.children,s=e.className,c=function(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}(e,a),d=(0,o.default)("recharts-layer",s);return n.default.createElement("g",l({className:d},(0,r.filterProps)(c,!0),{ref:t}),i)}));t.Layer=c},93273:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Surface=function(e){var t=e.children,i=e.width,s=e.height,c=e.viewBox,d=e.className,u=e.style,h=function(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}(e,a),p=c||{width:i,height:s,x:0,y:0},g=(0,o.default)("recharts-surface",d);return n.default.createElement("svg",l({},(0,r.filterProps)(h,!0,"svg"),{className:g,width:i,height:s,style:u,viewBox:"".concat(p.x," ").concat(p.y," ").concat(p.width," ").concat(p.height)}),n.default.createElement("title",null,e.title),n.default.createElement("desc",null,e.desc),t)};var n=s(i(8559)),o=s(i(33680)),r=i(48828),a=["children","width","height","viewBox","className","style"];function s(e){return e&&e.__esModule?e:{default:e}}function l(){return l=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},l.apply(this,arguments)}},1508:function(e,t,i){"use strict";function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}t.X=void 0;var o=c(i(8559)),r=c(i(33680)),a=i(47320),s=i(48828),l=["x","y","top","left","width","height","className"];function c(e){return e&&e.__esModule?e:{default:e}}function d(){return d=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},d.apply(this,arguments)}function u(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}var h=function(e,t,i,n,o,r){return"M".concat(e,",").concat(o,"v").concat(n,"M").concat(r,",").concat(t,"h").concat(i)};t.X=function(e){var t=e.x,i=void 0===t?0:t,c=e.y,p=void 0===c?0:c,g=e.top,f=void 0===g?0:g,m=e.left,v=void 0===m?0:m,y=e.width,C=void 0===y?0:y,b=e.height,S=void 0===b?0:b,x=e.className,T=function(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?u(Object(i),!0).forEach((function(t){var o,r,a;o=e,r=t,a=i[t],(r=function(e){var t=function(e,t){if("object"!==n(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var o=i.call(e,"string");if("object"!==n(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===n(t)?t:String(t)}(r))in o?Object.defineProperty(o,r,{value:a,enumerable:!0,configurable:!0,writable:!0}):o[r]=a})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):u(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}({x:i,y:p,top:f,left:v,width:C,height:S},function(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}(e,l));return(0,a.isNumber)(i)&&(0,a.isNumber)(p)&&(0,a.isNumber)(C)&&(0,a.isNumber)(S)&&(0,a.isNumber)(f)&&(0,a.isNumber)(v)?o.default.createElement("path",d({},(0,s.filterProps)(T,!0),{className:(0,r.default)("recharts-cross",x),d:h(i,p,C,S,f,v)})):null}},96729:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Curve=void 0;var n=h(i(83008)),o=h(i(126)),r=h(i(40825)),a=h(i(8559)),s=i(74895),l=h(i(33680)),c=i(13630),d=i(48828),u=i(47320);function h(e){return e&&e.__esModule?e:{default:e}}function p(e){return p="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},p(e)}function g(){return g=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},g.apply(this,arguments)}function f(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function m(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?f(Object(i),!0).forEach((function(t){var n,o,r;n=e,o=t,r=i[t],(o=function(e){var t=function(e,t){if("object"!==p(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==p(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===p(t)?t:String(t)}(o))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):f(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var v={curveBasisClosed:s.curveBasisClosed,curveBasisOpen:s.curveBasisOpen,curveBasis:s.curveBasis,curveBumpX:s.curveBumpX,curveBumpY:s.curveBumpY,curveLinearClosed:s.curveLinearClosed,curveLinear:s.curveLinear,curveMonotoneX:s.curveMonotoneX,curveMonotoneY:s.curveMonotoneY,curveNatural:s.curveNatural,curveStep:s.curveStep,curveStepAfter:s.curveStepAfter,curveStepBefore:s.curveStepBefore},y=function(e){return e.x===+e.x&&e.y===+e.y},C=function(e){return e.x},b=function(e){return e.y};t.Curve=function(e){var t=e.className,i=e.points,h=e.path,p=e.pathRef;if(!(i&&i.length||h))return null;var f=i&&i.length?function(e){var t,i=e.type,a=void 0===i?"linear":i,l=e.points,c=void 0===l?[]:l,d=e.baseLine,h=e.layout,p=e.connectNulls,g=void 0!==p&&p,f=function(e,t){if((0,r.default)(e))return e;var i="curve".concat((0,o.default)(e));return"curveMonotone"!==i&&"curveBump"!==i||!t?v[i]||s.curveLinear:v["".concat(i).concat("vertical"===t?"Y":"X")]}(a,h),S=g?c.filter((function(e){return y(e)})):c;if((0,n.default)(d)){var x=g?d.filter((function(e){return y(e)})):d,T=S.map((function(e,t){return m(m({},e),{},{base:x[t]})}));return(t="vertical"===h?(0,s.area)().y(b).x1(C).x0((function(e){return e.base.x})):(0,s.area)().x(C).y1(b).y0((function(e){return e.base.y}))).defined(y).curve(f),t(T)}return(t="vertical"===h&&(0,u.isNumber)(d)?(0,s.area)().y(b).x1(C).x0(d):(0,u.isNumber)(d)?(0,s.area)().x(C).y1(b).y0(d):(0,s.line)().x(C).y(b)).defined(y).curve(f),t(S)}(e):h;return a.default.createElement("path",g({},(0,d.filterProps)(e),(0,c.adaptEventHandlers)(e),{className:(0,l.default)("recharts-curve",t),d:f,ref:p}))}},49566:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Dot=void 0;var n=s(i(8559)),o=s(i(33680)),r=i(13630),a=i(48828);function s(e){return e&&e.__esModule?e:{default:e}}function l(){return l=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},l.apply(this,arguments)}t.Dot=function(e){var t=e.cx,i=e.cy,s=e.r,c=e.className,d=(0,o.default)("recharts-dot",c);return t===+t&&i===+i&&s===+s?n.default.createElement("circle",l({},(0,a.filterProps)(e),(0,r.adaptEventHandlers)(e),{className:d,cx:t,cy:i,r:s})):null}},53042:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isInRectangle=t.Rectangle=void 0;var n=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!==c(e)&&"function"!=typeof e)return{default:e};var i=l(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}(i(8559)),o=s(i(33680)),r=s(i(90480)),a=i(48828);function s(e){return e&&e.__esModule?e:{default:e}}function l(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(l=function(e){return e?i:t})(e)}function c(e){return c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},c(e)}function d(){return d=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},d.apply(this,arguments)}function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}function h(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function p(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?h(Object(i),!0).forEach((function(t){var n,o,r;n=e,o=t,r=i[t],(o=function(e){var t=function(e,t){if("object"!==c(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==c(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===c(t)?t:String(t)}(o))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):h(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var g=function(e,t,i,n,o){var r,a=Math.min(Math.abs(i)/2,Math.abs(n)/2),s=n>=0?1:-1,l=i>=0?1:-1,c=n>=0&&i>=0||n<0&&i<0?1:0;if(a>0&&o instanceof Array){for(var d=[0,0,0,0],u=0;u<4;u++)d[u]=o[u]>a?a:o[u];r="M".concat(e,",").concat(t+s*d[0]),d[0]>0&&(r+="A ".concat(d[0],",").concat(d[0],",0,0,").concat(c,",").concat(e+l*d[0],",").concat(t)),r+="L ".concat(e+i-l*d[1],",").concat(t),d[1]>0&&(r+="A ".concat(d[1],",").concat(d[1],",0,0,").concat(c,",\n ").concat(e+i,",").concat(t+s*d[1])),r+="L ".concat(e+i,",").concat(t+n-s*d[2]),d[2]>0&&(r+="A ".concat(d[2],",").concat(d[2],",0,0,").concat(c,",\n ").concat(e+i-l*d[2],",").concat(t+n)),r+="L ".concat(e+l*d[3],",").concat(t+n),d[3]>0&&(r+="A ".concat(d[3],",").concat(d[3],",0,0,").concat(c,",\n ").concat(e,",").concat(t+n-s*d[3])),r+="Z"}else if(a>0&&o===+o&&o>0){var h=Math.min(a,o);r="M ".concat(e,",").concat(t+s*h,"\n A ").concat(h,",").concat(h,",0,0,").concat(c,",").concat(e+l*h,",").concat(t,"\n L ").concat(e+i-l*h,",").concat(t,"\n A ").concat(h,",").concat(h,",0,0,").concat(c,",").concat(e+i,",").concat(t+s*h,"\n L ").concat(e+i,",").concat(t+n-s*h,"\n A ").concat(h,",").concat(h,",0,0,").concat(c,",").concat(e+i-l*h,",").concat(t+n,"\n L ").concat(e+l*h,",").concat(t+n,"\n A ").concat(h,",").concat(h,",0,0,").concat(c,",").concat(e,",").concat(t+n-s*h," Z")}else r="M ".concat(e,",").concat(t," h ").concat(i," v ").concat(n," h ").concat(-i," Z");return r};t.isInRectangle=function(e,t){if(!e||!t)return!1;var i=e.x,n=e.y,o=t.x,r=t.y,a=t.width,s=t.height;if(Math.abs(a)>0&&Math.abs(s)>0){var l=Math.min(o,o+a),c=Math.max(o,o+a),d=Math.min(r,r+s),u=Math.max(r,r+s);return i>=l&&i<=c&&n>=d&&n<=u}return!1};var f={x:0,y:0,width:0,height:0,radius:0,isAnimationActive:!1,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"};t.Rectangle=function(e){var t,i,s=p(p({},f),e),l=(0,n.useRef)(),c=(t=(0,n.useState)(-1),i=2,function(e){if(Array.isArray(e))return e}(t)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var n,o,r,a,s=[],l=!0,c=!1;try{if(r=(i=i.call(e)).next,0===t){if(Object(i)!==i)return;l=!1}else for(;!(l=(n=r.call(i)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=i.return&&(a=i.return(),Object(a)!==a))return}finally{if(c)throw o}}return s}}(t,i)||function(e,t){if(e){if("string"==typeof e)return u(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?u(e,t):void 0}}(t,i)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),h=c[0],m=c[1];(0,n.useEffect)((function(){if(l.current&&l.current.getTotalLength)try{var e=l.current.getTotalLength();e&&m(e)}catch(e){}}),[]);var v=s.x,y=s.y,C=s.width,b=s.height,S=s.radius,x=s.className,T=s.animationEasing,w=s.animationDuration,O=s.animationBegin,P=s.isAnimationActive,A=s.isUpdateAnimationActive;if(v!==+v||y!==+y||C!==+C||b!==+b||0===C||0===b)return null;var E=(0,o.default)("recharts-rectangle",x);return A?n.default.createElement(r.default,{canBegin:h>0,from:{width:C,height:b,x:v,y:y},to:{width:C,height:b,x:v,y:y},duration:w,animationEasing:T,isActive:A},(function(e){var t=e.width,i=e.height,o=e.x,c=e.y;return n.default.createElement(r.default,{canBegin:h>0,from:"0px ".concat(-1===h?1:h,"px"),to:"".concat(h,"px 0px"),attributeName:"strokeDasharray",begin:O,duration:w,isActive:P,easing:T},n.default.createElement("path",d({},(0,a.filterProps)(s,!0),{className:E,d:g(o,c,t,i,S),ref:l})))})):n.default.createElement("path",d({},(0,a.filterProps)(s,!0),{className:E,d:g(v,y,C,b,S)}))}},52931:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Sector=void 0;var n=l(i(8559)),o=l(i(33680)),r=i(48828),a=i(60212),s=i(47320);function l(e){return e&&e.__esModule?e:{default:e}}function c(e){return c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},c(e)}function d(){return d=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},d.apply(this,arguments)}function u(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function h(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?u(Object(i),!0).forEach((function(t){var n,o,r;n=e,o=t,r=i[t],(o=function(e){var t=function(e,t){if("object"!==c(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==c(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===c(t)?t:String(t)}(o))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):u(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var p=function(e){var t=e.cx,i=e.cy,n=e.radius,o=e.angle,r=e.sign,s=e.isExternal,l=e.cornerRadius,c=e.cornerIsExternal,d=l*(s?1:-1)+n,u=Math.asin(l/d)/a.RADIAN,h=c?o:o+r*u,p=c?o-r*u:o;return{center:(0,a.polarToCartesian)(t,i,d,h),circleTangency:(0,a.polarToCartesian)(t,i,n,h),lineTangency:(0,a.polarToCartesian)(t,i,d*Math.cos(u*a.RADIAN),p),theta:u}},g=function(e){var t=e.cx,i=e.cy,n=e.innerRadius,o=e.outerRadius,r=e.startAngle,l=function(e,t){return(0,s.mathSign)(t-e)*Math.min(Math.abs(t-e),359.999)}(r,e.endAngle),c=r+l,d=(0,a.polarToCartesian)(t,i,o,r),u=(0,a.polarToCartesian)(t,i,o,c),h="M ".concat(d.x,",").concat(d.y,"\n A ").concat(o,",").concat(o,",0,\n ").concat(+(Math.abs(l)>180),",").concat(+(r>c),",\n ").concat(u.x,",").concat(u.y,"\n ");if(n>0){var p=(0,a.polarToCartesian)(t,i,n,r),g=(0,a.polarToCartesian)(t,i,n,c);h+="L ".concat(g.x,",").concat(g.y,"\n A ").concat(n,",").concat(n,",0,\n ").concat(+(Math.abs(l)>180),",").concat(+(r<=c),",\n ").concat(p.x,",").concat(p.y," Z")}else h+="L ".concat(t,",").concat(i," Z");return h},f={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1};t.Sector=function(e){var t=h(h({},f),e),i=t.cx,a=t.cy,l=t.innerRadius,c=t.outerRadius,u=t.cornerRadius,m=t.forceCornerRadius,v=t.cornerIsExternal,y=t.startAngle,C=t.endAngle,b=t.className;if(c<l||y===C)return null;var S,x=(0,o.default)("recharts-sector",b),T=c-l,w=(0,s.getPercentValue)(u,T,0,!0);return S=w>0&&Math.abs(y-C)<360?function(e){var t=e.cx,i=e.cy,n=e.innerRadius,o=e.outerRadius,r=e.cornerRadius,a=e.forceCornerRadius,l=e.cornerIsExternal,c=e.startAngle,d=e.endAngle,u=(0,s.mathSign)(d-c),h=p({cx:t,cy:i,radius:o,angle:c,sign:u,cornerRadius:r,cornerIsExternal:l}),f=h.circleTangency,m=h.lineTangency,v=h.theta,y=p({cx:t,cy:i,radius:o,angle:d,sign:-u,cornerRadius:r,cornerIsExternal:l}),C=y.circleTangency,b=y.lineTangency,S=y.theta,x=l?Math.abs(c-d):Math.abs(c-d)-v-S;if(x<0)return a?"M ".concat(m.x,",").concat(m.y,"\n a").concat(r,",").concat(r,",0,0,1,").concat(2*r,",0\n a").concat(r,",").concat(r,",0,0,1,").concat(2*-r,",0\n "):g({cx:t,cy:i,innerRadius:n,outerRadius:o,startAngle:c,endAngle:d});var T="M ".concat(m.x,",").concat(m.y,"\n A").concat(r,",").concat(r,",0,0,").concat(+(u<0),",").concat(f.x,",").concat(f.y,"\n A").concat(o,",").concat(o,",0,").concat(+(x>180),",").concat(+(u<0),",").concat(C.x,",").concat(C.y,"\n A").concat(r,",").concat(r,",0,0,").concat(+(u<0),",").concat(b.x,",").concat(b.y,"\n ");if(n>0){var w=p({cx:t,cy:i,radius:n,angle:c,sign:u,isExternal:!0,cornerRadius:r,cornerIsExternal:l}),O=w.circleTangency,P=w.lineTangency,A=w.theta,E=p({cx:t,cy:i,radius:n,angle:d,sign:-u,isExternal:!0,cornerRadius:r,cornerIsExternal:l}),k=E.circleTangency,I=E.lineTangency,D=E.theta,_=l?Math.abs(c-d):Math.abs(c-d)-A-D;if(_<0&&0===r)return"".concat(T,"L").concat(t,",").concat(i,"Z");T+="L".concat(I.x,",").concat(I.y,"\n A").concat(r,",").concat(r,",0,0,").concat(+(u<0),",").concat(k.x,",").concat(k.y,"\n A").concat(n,",").concat(n,",0,").concat(+(_>180),",").concat(+(u>0),",").concat(O.x,",").concat(O.y,"\n A").concat(r,",").concat(r,",0,0,").concat(+(u<0),",").concat(P.x,",").concat(P.y,"Z")}else T+="L".concat(t,",").concat(i,"Z");return T}({cx:i,cy:a,innerRadius:l,outerRadius:c,cornerRadius:Math.min(w,T/2),forceCornerRadius:m,cornerIsExternal:v,startAngle:y,endAngle:C}):g({cx:i,cy:a,innerRadius:l,outerRadius:c,startAngle:y,endAngle:C}),n.default.createElement("path",d({},(0,r.filterProps)(t,!0),{className:x,d:S,role:"img"}))}},50918:function(e,t,i){"use strict";function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.Symbols=void 0;var o=d(i(126)),r=d(i(8559)),a=i(74895),s=d(i(33680)),l=i(48828),c=["type","size","sizeType"];function d(e){return e&&e.__esModule?e:{default:e}}function u(){return u=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},u.apply(this,arguments)}function h(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function p(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?h(Object(i),!0).forEach((function(t){var o,r,a;o=e,r=t,a=i[t],(r=function(e){var t=function(e,t){if("object"!==n(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var o=i.call(e,"string");if("object"!==n(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===n(t)?t:String(t)}(r))in o?Object.defineProperty(o,r,{value:a,enumerable:!0,configurable:!0,writable:!0}):o[r]=a})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):h(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var g={symbolCircle:a.symbolCircle,symbolCross:a.symbolCross,symbolDiamond:a.symbolDiamond,symbolSquare:a.symbolSquare,symbolStar:a.symbolStar,symbolTriangle:a.symbolTriangle,symbolWye:a.symbolWye},f=Math.PI/180,m=function(e){var t,i,n=e.type,d=void 0===n?"circle":n,h=e.size,m=void 0===h?64:h,v=e.sizeType,y=void 0===v?"area":v,C=p(p({},function(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}(e,c)),{},{type:d,size:m,sizeType:y}),b=C.className,S=C.cx,x=C.cy,T=(0,l.filterProps)(C,!0);return S===+S&&x===+x&&m===+m?r.default.createElement("path",u({},T,{className:(0,s.default)("recharts-symbols",b),transform:"translate(".concat(S,", ").concat(x,")"),d:(t=function(e){var t="symbol".concat((0,o.default)(e));return g[t]||a.symbolCircle}(d),i=(0,a.symbol)().type(t).size(function(e,t,i){if("area"===t)return e;switch(i){case"cross":return 5*e*e/9;case"diamond":return.5*e*e/Math.sqrt(3);case"square":return e*e;case"star":var n=18*f;return 1.25*e*e*(Math.tan(n)-Math.tan(2*n)*Math.pow(Math.tan(n),2));case"triangle":return Math.sqrt(3)*e*e/4;case"wye":return(21-10*Math.sqrt(3))*e*e/8;default:return Math.PI*e*e/4}}(m,y,d)),i())})):null};t.Symbols=m,m.registerSymbol=function(e,t){g["symbol".concat((0,o.default)(e))]=t}},67440:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Trapezoid=void 0;var n=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!==c(e)&&"function"!=typeof e)return{default:e};var i=l(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}(i(8559)),o=s(i(33680)),r=s(i(90480)),a=i(48828);function s(e){return e&&e.__esModule?e:{default:e}}function l(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(l=function(e){return e?i:t})(e)}function c(e){return c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},c(e)}function d(){return d=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},d.apply(this,arguments)}function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}function h(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function p(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?h(Object(i),!0).forEach((function(t){var n,o,r;n=e,o=t,r=i[t],(o=function(e){var t=function(e,t){if("object"!==c(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==c(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===c(t)?t:String(t)}(o))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):h(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var g=function(e,t,i,n,o){var r,a=i-n;return r="M ".concat(e,",").concat(t),r+="L ".concat(e+i,",").concat(t),r+="L ".concat(e+i-a/2,",").concat(t+o),(r+="L ".concat(e+i-a/2-n,",").concat(t+o))+"L ".concat(e,",").concat(t," Z")},f={x:0,y:0,upperWidth:0,lowerWidth:0,height:0,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"};t.Trapezoid=function(e){var t,i,s=p(p({},f),e),l=(0,n.useRef)(),c=(t=(0,n.useState)(-1),i=2,function(e){if(Array.isArray(e))return e}(t)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var n,o,r,a,s=[],l=!0,c=!1;try{if(r=(i=i.call(e)).next,0===t){if(Object(i)!==i)return;l=!1}else for(;!(l=(n=r.call(i)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=i.return&&(a=i.return(),Object(a)!==a))return}finally{if(c)throw o}}return s}}(t,i)||function(e,t){if(e){if("string"==typeof e)return u(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?u(e,t):void 0}}(t,i)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()),h=c[0],m=c[1];(0,n.useEffect)((function(){if(l.current&&l.current.getTotalLength)try{var e=l.current.getTotalLength();e&&m(e)}catch(e){}}),[]);var v=s.x,y=s.y,C=s.upperWidth,b=s.lowerWidth,S=s.height,x=s.className,T=s.animationEasing,w=s.animationDuration,O=s.animationBegin,P=s.isUpdateAnimationActive;if(v!==+v||y!==+y||C!==+C||b!==+b||S!==+S||0===C&&0===b||0===S)return null;var A=(0,o.default)("recharts-trapezoid",x);return P?n.default.createElement(r.default,{canBegin:h>0,from:{upperWidth:0,lowerWidth:0,height:S,x:v,y:y},to:{upperWidth:C,lowerWidth:b,height:S,x:v,y:y},duration:w,animationEasing:T,isActive:P},(function(e){var t=e.upperWidth,i=e.lowerWidth,o=e.height,c=e.x,u=e.y;return n.default.createElement(r.default,{canBegin:h>0,from:"0px ".concat(-1===h?1:h,"px"),to:"".concat(h,"px 0px"),attributeName:"strokeDasharray",begin:O,duration:w,easing:T},n.default.createElement("path",d({},(0,a.filterProps)(s,!0),{className:A,d:g(c,u,t,i,o),ref:l})))})):n.default.createElement("g",null,n.default.createElement("path",d({},(0,a.filterProps)(s,!0),{className:A,d:g(v,y,C,b,S)})))}},92541:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Shape=function(e){var t,i=e.option,n=e.shapeType,l=e.propTransformer,c=void 0===l?C:l,d=e.activeClassName,h=void 0===d?"recharts-active-shape":d,g=e.isActive,f=function(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}(e,p);if((0,s.isValidElement)(i))t=(0,s.cloneElement)(i,f);else if((0,a.default)(i))t=i(f);else if((0,r.default)(i)&&!(0,o.default)(i)){var m=c(i,f);t=s.default.createElement(b,{shapeType:n,elementProps:m})}else{var v=f;t=s.default.createElement(b,{shapeType:n,elementProps:v})}return g?s.default.createElement(u.Layer,{className:h},t):t},t.compareFunnel=w,t.comparePie=O,t.compareScatter=P,t.getActiveShapeIndexForTooltip=function(e){var t=e.activeTooltipItem,i=e.graphicalItem,o=e.itemData,r=function(e,t){var i;return S(e)?i="trapezoids":x(e)?i="sectors":T(e)&&(i="points"),i}(i),a=function(e,t){var i,n;return S(e)?null===(i=t.tooltipPayload)||void 0===i||null===(i=i[0])||void 0===i||null===(i=i.payload)||void 0===i?void 0:i.payload:x(e)?null===(n=t.tooltipPayload)||void 0===n||null===(n=n[0])||void 0===n||null===(n=n.payload)||void 0===n?void 0:n.payload:T(e)?t.payload:{}}(i,t),s=o.filter((function(e,o){var s=(0,n.default)(a,e),l=i.props[r].filter((function(e){var n=function(e,t){var i;return S(e)?i=w:x(e)?i=O:T(e)&&(i=P),i}(i);return n(e,t)})),c=i.props[r].indexOf(l[l.length-1]);return s&&o===c}));return o.indexOf(s[s.length-1])},t.isFunnel=S,t.isPie=x,t.isScatter=T;var n=f(i(37861)),o=f(i(35189)),r=f(i(57466)),a=f(i(40825)),s=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!==m(e)&&"function"!=typeof e)return{default:e};var i=g(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}(i(8559)),l=i(53042),c=i(67440),d=i(52931),u=i(61441),h=i(50918),p=["option","shapeType","propTransformer","activeClassName","isActive"];function g(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(g=function(e){return e?i:t})(e)}function f(e){return e&&e.__esModule?e:{default:e}}function m(e){return m="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},m(e)}function v(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function y(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?v(Object(i),!0).forEach((function(t){var n,o,r;n=e,o=t,r=i[t],(o=function(e){var t=function(e,t){if("object"!==m(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==m(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===m(t)?t:String(t)}(o))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):v(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function C(e,t){return y(y({},t),e)}function b(e){var t=e.shapeType,i=e.elementProps;switch(t){case"rectangle":return s.default.createElement(l.Rectangle,i);case"trapezoid":return s.default.createElement(c.Trapezoid,i);case"sector":return s.default.createElement(d.Sector,i);case"symbols":if(function(e,t){return"symbols"===e}(t))return s.default.createElement(h.Symbols,i);break;default:return null}}function S(e,t){return"trapezoids"in e.props}function x(e,t){return"sectors"in e.props}function T(e,t){return"points"in e.props}function w(e,t){var i,n,o=e.x===(null==t||null===(i=t.labelViewBox)||void 0===i?void 0:i.x)||e.x===t.x,r=e.y===(null==t||null===(n=t.labelViewBox)||void 0===n?void 0:n.y)||e.y===t.y;return o&&r}function O(e,t){var i=e.endAngle===t.endAngle,n=e.startAngle===t.startAngle;return i&&n}function P(e,t){var i=e.x===t.x,n=e.y===t.y,o=e.z===t.z;return i&&n&&o}},46129:function(e,t,i){"use strict";function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.BarRectangle=function(e){return r.default.createElement(a.Shape,l({shapeType:"rectangle",propTransformer:h,activeClassName:"recharts-active-bar"},e))};var o,r=(o=i(8559))&&o.__esModule?o:{default:o},a=i(92541),s=["x","y"];function l(){return l=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},l.apply(this,arguments)}function c(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function d(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?c(Object(i),!0).forEach((function(t){u(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):c(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function u(e,t,i){return(t=function(e){var t=function(e,t){if("object"!==n(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var o=i.call(e,"string");if("object"!==n(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===n(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function h(e,t){var i=e.x,n=e.y,o=function(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}(e,s),r="".concat(i),a=parseInt(r,10),l="".concat(n),c=parseInt(l,10),u="".concat(t.height||o.height),h=parseInt(u,10),p="".concat(t.width||o.width),g=parseInt(p,10);return d(d(d(d(d({},t),o),a?{x:a}:{}),c?{y:c}:{}),{},{height:h,width:g,name:t.name,radius:t.radius})}},12618:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getAngledRectangleWidth=t.formatAxisMap=t.createLabeledScales=t.ScaleHelper=void 0,t.normalizeAngle=y,t.rectWithPoints=t.rectWithCoords=void 0;var n=c(i(6425)),o=c(i(31113)),r=i(10455),a=i(48828),s=i(47320),l=i(5445);function c(e){return e&&e.__esModule?e:{default:e}}function d(e){return d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},d(e)}function u(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,f(n.key),n)}}function h(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function p(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?h(Object(i),!0).forEach((function(t){g(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):h(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function g(e,t,i){return(t=f(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function f(e){var t=function(e,t){if("object"!==d(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==d(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===d(t)?t:String(t)}t.formatAxisMap=function(e,t,i,n,o){var c=e.width,d=e.height,u=e.layout,h=e.children,f=Object.keys(t),m={left:i.left,leftMirror:i.left,right:c-i.right,rightMirror:c-i.right,top:i.top,topMirror:i.top,bottom:d-i.bottom,bottomMirror:d-i.bottom},v=!!(0,a.findChildByType)(h,l.Bar);return f.reduce((function(a,l){var c,d,h,f,y,C=t[l],b=C.orientation,S=C.domain,x=C.padding,T=void 0===x?{}:x,w=C.mirror,O=C.reversed,P="".concat(b).concat(w?"Mirror":"");if("number"===C.type&&("gap"===C.padding||"no-gap"===C.padding)){var A=S[1]-S[0],E=1/0,k=C.categoricalDomain.sort();k.forEach((function(e,t){t>0&&(E=Math.min((e||0)-(k[t-1]||0),E))}));var I=E/A,D="vertical"===C.layout?i.height:i.width;if("gap"===C.padding&&(c=I*D/2),"no-gap"===C.padding){var _=(0,s.getPercentValue)(e.barCategoryGap,I*D),N=I*D/2;c=N-_-(N-_)/D*_}}d="xAxis"===n?[i.left+(T.left||0)+(c||0),i.left+i.width-(T.right||0)-(c||0)]:"yAxis"===n?"horizontal"===u?[i.top+i.height-(T.bottom||0),i.top+(T.top||0)]:[i.top+(T.top||0)+(c||0),i.top+i.height-(T.bottom||0)-(c||0)]:C.range,O&&(d=[d[1],d[0]]);var R=(0,r.parseScale)(C,o,v),M=R.scale,L=R.realScaleType;M.domain(S).range(d),(0,r.checkDomainOfScale)(M);var B=(0,r.getTicksOfScale)(M,p(p({},C),{},{realScaleType:L}));"xAxis"===n?(y="top"===b&&!w||"bottom"===b&&w,h=i.left,f=m[P]-y*C.height):"yAxis"===n&&(y="left"===b&&!w||"right"===b&&w,h=m[P]-y*C.width,f=i.top);var F=p(p(p({},C),B),{},{realScaleType:L,x:h,y:f,scale:M,width:"xAxis"===n?i.width:C.width,height:"yAxis"===n?i.height:C.height});return F.bandSize=(0,r.getBandSizeOfAxis)(F,B),C.hide||"xAxis"!==n?C.hide||(m[P]+=(y?-1:1)*F.width):m[P]+=(y?-1:1)*F.height,p(p({},a),{},g({},l,F))}),{})};var m=function(e,t){var i=e.x,n=e.y,o=t.x,r=t.y;return{x:Math.min(i,o),y:Math.min(n,r),width:Math.abs(o-i),height:Math.abs(r-n)}};t.rectWithPoints=m,t.rectWithCoords=function(e){var t=e.x1,i=e.y1,n=e.x2,o=e.y2;return m({x:t,y:i},{x:n,y:o})};var v=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.scale=t}var t,i,n;return t=e,i=[{key:"domain",get:function(){return this.scale.domain}},{key:"range",get:function(){return this.scale.range}},{key:"rangeMin",get:function(){return this.range()[0]}},{key:"rangeMax",get:function(){return this.range()[1]}},{key:"bandwidth",get:function(){return this.scale.bandwidth}},{key:"apply",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=t.bandAware,n=t.position;if(void 0!==e){if(n)switch(n){case"start":default:return this.scale(e);case"middle":var o=this.bandwidth?this.bandwidth()/2:0;return this.scale(e)+o;case"end":var r=this.bandwidth?this.bandwidth():0;return this.scale(e)+r}if(i){var a=this.bandwidth?this.bandwidth()/2:0;return this.scale(e)+a}return this.scale(e)}}},{key:"isInRange",value:function(e){var t=this.range(),i=t[0],n=t[t.length-1];return i<=n?e>=i&&e<=n:e>=n&&e<=i}}],n=[{key:"create",value:function(t){return new e(t)}}],i&&u(t.prototype,i),n&&u(t,n),Object.defineProperty(t,"prototype",{writable:!1}),e}();function y(e){return(e%180+180)%180}t.ScaleHelper=v,g(v,"EPS",1e-4),t.createLabeledScales=function(e){var t=Object.keys(e).reduce((function(t,i){return p(p({},t),{},g({},i,v.create(e[i])))}),{});return p(p({},t),{},{apply:function(e){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=i.bandAware,r=i.position;return(0,o.default)(e,(function(e,i){return t[i].apply(e,{bandAware:n,position:r})}))},isInRange:function(e){return(0,n.default)(e,(function(e,i){return t[i].isInRange(e)}))}})},t.getAngledRectangleWidth=function(e){var t=e.width,i=e.height,n=y(arguments.length>1&&void 0!==arguments[1]?arguments[1]:0)*Math.PI/180,o=Math.atan(i/t),r=n>o&&n<Math.PI-o?i/Math.sin(n):t/Math.cos(n);return Math.abs(r)}},10455:function(e,t,i){"use strict";function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.getCoordinatesOfGrid=t.getCateCoordinateOfLine=t.getCateCoordinateOfBar=t.getBaseValueOfBar=t.getBarSizeList=t.getBarPosition=t.getBandSizeOfAxis=t.findPositionOfBar=t.combineEventHandlers=t.checkDomainOfScale=t.calculateActiveTickIndex=t.appendOffsetOfLegend=t.MIN_VALUE_REG=t.MAX_VALUE_REG=void 0,t.getDomainOfDataByKey=D,t.getDomainOfStackGroups=t.getDomainOfItemsWithSameAxis=t.getDomainOfErrorBars=void 0,Object.defineProperty(t,"getLegendProps",{enumerable:!0,get:function(){return x.getLegendProps}}),t.getTooltipItem=t.getTicksOfScale=t.getTicksOfAxis=t.getStackedDataOfItem=t.getStackedData=t.getStackGroupsByAxisId=t.getMainColorOfGraphicItem=void 0,t.getValueByDataKey=I,t.truncateByDomain=t.parseSpecifiedDomain=t.parseScale=t.parseErrorBarsOfAxis=t.parseDomainOfCategoryAxis=t.offsetSign=t.offsetPositive=t.isCategoricalAxis=void 0;var o=w(i(37861)),r=w(i(57657)),a=w(i(126)),s=w(i(12343)),l=w(i(68014)),c=w(i(83008)),d=w(i(94563)),u=w(i(9884)),h=w(i(86974)),p=w(i(40825)),g=w(i(71758)),f=w(i(18562)),m=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!==n(e)&&"function"!=typeof e)return{default:e};var i=T(t);if(i&&i.has(e))return i.get(e);var o={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if("default"!==a&&Object.prototype.hasOwnProperty.call(e,a)){var s=r?Object.getOwnPropertyDescriptor(e,a):null;s&&(s.get||s.set)?Object.defineProperty(o,a,s):o[a]=e[a]}return o.default=e,i&&i.set(e,o),o}(i(53527)),v=i(74895),y=i(72507),C=i(63394),b=i(47320),S=i(48828),x=i(32489);function T(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(T=function(e){return e?i:t})(e)}function w(e){return e&&e.__esModule?e:{default:e}}function O(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function P(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?O(Object(i),!0).forEach((function(t){A(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):O(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function A(e,t,i){return(t=function(e){var t=function(e,t){if("object"!==n(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var o=i.call(e,"string");if("object"!==n(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===n(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function E(e){return function(e){if(Array.isArray(e))return k(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return k(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?k(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function k(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}function I(e,t,i){return(0,f.default)(e)||(0,f.default)(t)?i:(0,b.isNumOrStr)(t)?(0,g.default)(e,t,i):(0,p.default)(t)?t(e):i}function D(e,t,i,n){var o=(0,h.default)(e,(function(e){return I(e,t)}));if("number"===i){var r=o.filter((function(e){return(0,b.isNumber)(e)||parseFloat(e)}));return r.length?[(0,u.default)(r),(0,d.default)(r)]:[1/0,-1/0]}return(n?o.filter((function(e){return!(0,f.default)(e)})):o).map((function(e){return(0,b.isNumOrStr)(e)||e instanceof Date?e:""}))}t.calculateActiveTickIndex=function(e){var t,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=arguments.length>2?arguments[2]:void 0,o=arguments.length>3?arguments[3]:void 0,r=-1,a=null!==(t=null==i?void 0:i.length)&&void 0!==t?t:0;if(a<=1)return 0;if(o&&"angleAxis"===o.axisType&&Math.abs(Math.abs(o.range[1]-o.range[0])-360)<=1e-6)for(var s=o.range,l=0;l<a;l++){var c=l>0?n[l-1].coordinate:n[a-1].coordinate,d=n[l].coordinate,u=l>=a-1?n[0].coordinate:n[l+1].coordinate,h=void 0;if((0,b.mathSign)(d-c)!==(0,b.mathSign)(u-d)){var p=[];if((0,b.mathSign)(u-d)===(0,b.mathSign)(s[1]-s[0])){h=u;var g=d+s[1]-s[0];p[0]=Math.min(g,(g+c)/2),p[1]=Math.max(g,(g+c)/2)}else{h=c;var f=u+s[1]-s[0];p[0]=Math.min(d,(f+d)/2),p[1]=Math.max(d,(f+d)/2)}var m=[Math.min(d,(h+d)/2),Math.max(d,(h+d)/2)];if(e>m[0]&&e<=m[1]||e>=p[0]&&e<=p[1]){r=n[l].index;break}}else{var v=Math.min(c,u),y=Math.max(c,u);if(e>(v+d)/2&&e<=(y+d)/2){r=n[l].index;break}}}else for(var C=0;C<a;C++)if(0===C&&e<=(i[C].coordinate+i[C+1].coordinate)/2||C>0&&C<a-1&&e>(i[C].coordinate+i[C-1].coordinate)/2&&e<=(i[C].coordinate+i[C+1].coordinate)/2||C===a-1&&e>(i[C].coordinate+i[C-1].coordinate)/2){r=i[C].index;break}return r};var _=function(e){var t,i=e.type.displayName,n=e.props,o=n.stroke,r=n.fill;switch(i){case"Line":t=o;break;case"Area":case"Radar":t=o&&"none"!==o?o:r;break;default:t=r}return t};t.getMainColorOfGraphicItem=_,t.getBarSizeList=function(e){var t=e.barSize,i=e.stackGroups,n=void 0===i?{}:i;if(!n)return{};for(var o={},r=Object.keys(n),a=0,s=r.length;a<s;a++)for(var l=n[r[a]].stackGroups,c=Object.keys(l),d=0,u=c.length;d<u;d++){var h=l[c[d]],p=h.items,g=h.cateAxisId,m=p.filter((function(e){return(0,S.getDisplayName)(e.type).indexOf("Bar")>=0}));if(m&&m.length){var v=m[0].props.barSize,y=m[0].props[g];o[y]||(o[y]=[]),o[y].push({item:m[0],stackList:m.slice(1),barSize:(0,f.default)(v)?t:v})}}return o},t.getBarPosition=function(e){var t=e.barGap,i=e.barCategoryGap,n=e.bandSize,o=e.sizeList,r=void 0===o?[]:o,a=e.maxBarSize,s=r.length;if(s<1)return null;var l,c=(0,b.getPercentValue)(t,n,0,!0),d=[];if(r[0].barSize===+r[0].barSize){var u=!1,h=n/s,p=r.reduce((function(e,t){return e+t.barSize||0}),0);(p+=(s-1)*c)>=n&&(p-=(s-1)*c,c=0),p>=n&&h>0&&(u=!0,p=s*(h*=.9));var g={offset:((n-p)/2>>0)-c,size:0};l=r.reduce((function(e,t){var i={item:t.item,position:{offset:g.offset+g.size+c,size:u?h:t.barSize}},n=[].concat(E(e),[i]);return g=n[n.length-1].position,t.stackList&&t.stackList.length&&t.stackList.forEach((function(e){n.push({item:e,position:g})})),n}),d)}else{var f=(0,b.getPercentValue)(i,n,0,!0);n-2*f-(s-1)*c<=0&&(c=0);var m=(n-2*f-(s-1)*c)/s;m>1&&(m>>=0);var v=a===+a?Math.min(m,a):m;l=r.reduce((function(e,t,i){var n=[].concat(E(e),[{item:t.item,position:{offset:f+(m+c)*i+(m-v)/2,size:v}}]);return t.stackList&&t.stackList.length&&t.stackList.forEach((function(e){n.push({item:e,position:n[n.length-1].position})})),n}),d)}return l},t.appendOffsetOfLegend=function(e,t,i,n){var o=i.children,r=i.width,a=i.margin,s=r-(a.left||0)-(a.right||0),l=(0,x.getLegendProps)({children:o,legendWidth:s});if(l){var c=n||{},d=c.width,u=c.height,h=l.align,p=l.verticalAlign,g=l.layout;if(("vertical"===g||"horizontal"===g&&"middle"===p)&&"center"!==h&&(0,b.isNumber)(e[h]))return P(P({},e),{},A({},h,e[h]+(d||0)));if(("horizontal"===g||"vertical"===g&&"center"===h)&&"middle"!==p&&(0,b.isNumber)(e[p]))return P(P({},e),{},A({},p,e[p]+(u||0)))}return e};var N=function(e,t,i,n,o){var r=t.props.children,a=(0,S.findAllByType)(r,C.ErrorBar).filter((function(e){return function(e,t,i){return!!(0,f.default)(t)||("horizontal"===e?"yAxis"===t:"vertical"===e||"x"===i?"xAxis"===t:"y"!==i||"yAxis"===t)}(n,o,e.props.direction)}));if(a&&a.length){var s=a.map((function(e){return e.props.dataKey}));return e.reduce((function(e,t){var n=I(t,i,0),o=(0,c.default)(n)?[(0,u.default)(n),(0,d.default)(n)]:[n,n],r=s.reduce((function(e,i){var n=I(t,i,0),r=o[0]-Math.abs((0,c.default)(n)?n[0]:n),a=o[1]+Math.abs((0,c.default)(n)?n[1]:n);return[Math.min(r,e[0]),Math.max(a,e[1])]}),[1/0,-1/0]);return[Math.min(r[0],e[0]),Math.max(r[1],e[1])]}),[1/0,-1/0])}return null};t.getDomainOfErrorBars=N,t.parseErrorBarsOfAxis=function(e,t,i,n,o){var r=t.map((function(t){return N(e,t,i,o,n)})).filter((function(e){return!(0,f.default)(e)}));return r&&r.length?r.reduce((function(e,t){return[Math.min(e[0],t[0]),Math.max(e[1],t[1])]}),[1/0,-1/0]):null},t.getDomainOfItemsWithSameAxis=function(e,t,i,n,o){var r=t.map((function(t){var r=t.props.dataKey;return"number"===i&&r&&N(e,t,r,n)||D(e,r,i,o)}));if("number"===i)return r.reduce((function(e,t){return[Math.min(e[0],t[0]),Math.max(e[1],t[1])]}),[1/0,-1/0]);var a={};return r.reduce((function(e,t){for(var i=0,n=t.length;i<n;i++)a[t[i]]||(a[t[i]]=!0,e.push(t[i]));return e}),[])},t.isCategoricalAxis=function(e,t){return"horizontal"===e&&"xAxis"===t||"vertical"===e&&"yAxis"===t||"centric"===e&&"angleAxis"===t||"radial"===e&&"radiusAxis"===t},t.getCoordinatesOfGrid=function(e,t,i,n){if(n)return e.map((function(e){return e.coordinate}));var o,r,a=e.map((function(e){return e.coordinate===t&&(o=!0),e.coordinate===i&&(r=!0),e.coordinate}));return o||a.push(t),r||a.push(i),a},t.getTicksOfAxis=function(e,t,i){if(!e)return null;var n=e.scale,o=e.duplicateDomain,r=e.type,a=e.range,s="scaleBand"===e.realScaleType?n.bandwidth()/2:2,c=(t||i)&&"category"===r&&n.bandwidth?n.bandwidth()/s:0;return c="angleAxis"===e.axisType&&(null==a?void 0:a.length)>=2?2*(0,b.mathSign)(a[0]-a[1])*c:c,t&&(e.ticks||e.niceTicks)?(e.ticks||e.niceTicks).map((function(e){var t=o?o.indexOf(e):e;return{coordinate:n(t)+c,value:e,offset:c}})).filter((function(e){return!(0,l.default)(e.coordinate)})):e.isCategorical&&e.categoricalDomain?e.categoricalDomain.map((function(e,t){return{coordinate:n(e)+c,value:e,index:t,offset:c}})):n.ticks&&!i?n.ticks(e.tickCount).map((function(e){return{coordinate:n(e)+c,value:e,offset:c}})):n.domain().map((function(e,t){return{coordinate:n(e)+c,value:o?o[e]:e,index:t,offset:c}}))},t.combineEventHandlers=function(e,t,i){var n;return(0,p.default)(i)?n=i:(0,p.default)(t)&&(n=t),(0,p.default)(e)||n?function(t,i,o,r){(0,p.default)(e)&&e(t,i,o,r),(0,p.default)(n)&&n(t,i,o,r)}:null},t.parseScale=function(e,t,i){var n=e.scale,o=e.type,r=e.layout,l=e.axisType;if("auto"===n)return"radial"===r&&"radiusAxis"===l?{scale:m.scaleBand(),realScaleType:"band"}:"radial"===r&&"angleAxis"===l?{scale:m.scaleLinear(),realScaleType:"linear"}:"category"===o&&t&&(t.indexOf("LineChart")>=0||t.indexOf("AreaChart")>=0||t.indexOf("ComposedChart")>=0&&!i)?{scale:m.scalePoint(),realScaleType:"point"}:"category"===o?{scale:m.scaleBand(),realScaleType:"band"}:{scale:m.scaleLinear(),realScaleType:"linear"};if((0,s.default)(n)){var c="scale".concat((0,a.default)(n));return{scale:(m[c]||m.scalePoint)(),realScaleType:m[c]?c:"point"}}return(0,p.default)(n)?{scale:n}:{scale:m.scalePoint(),realScaleType:"point"}};var R=1e-4;t.checkDomainOfScale=function(e){var t=e.domain();if(t&&!(t.length<=2)){var i=t.length,n=e.range(),o=Math.min(n[0],n[1])-R,r=Math.max(n[0],n[1])+R,a=e(t[0]),s=e(t[i-1]);(a<o||a>r||s<o||s>r)&&e.domain([t[0],t[i-1]])}},t.findPositionOfBar=function(e,t){if(!e)return null;for(var i=0,n=e.length;i<n;i++)if(e[i].item===t)return e[i].position;return null},t.truncateByDomain=function(e,t){if(!t||2!==t.length||!(0,b.isNumber)(t[0])||!(0,b.isNumber)(t[1]))return e;var i=Math.min(t[0],t[1]),n=Math.max(t[0],t[1]),o=[e[0],e[1]];return(!(0,b.isNumber)(e[0])||e[0]<i)&&(o[0]=i),(!(0,b.isNumber)(e[1])||e[1]>n)&&(o[1]=n),o[0]>n&&(o[0]=n),o[1]<i&&(o[1]=i),o};var M=function(e){var t=e.length;if(!(t<=0))for(var i=0,n=e[0].length;i<n;++i)for(var o=0,r=0,a=0;a<t;++a){var s=(0,l.default)(e[a][i][1])?e[a][i][0]:e[a][i][1];s>=0?(e[a][i][0]=o,e[a][i][1]=o+s,o=e[a][i][1]):(e[a][i][0]=r,e[a][i][1]=r+s,r=e[a][i][1])}};t.offsetSign=M;var L=function(e){var t=e.length;if(!(t<=0))for(var i=0,n=e[0].length;i<n;++i)for(var o=0,r=0;r<t;++r){var a=(0,l.default)(e[r][i][1])?e[r][i][0]:e[r][i][1];a>=0?(e[r][i][0]=o,e[r][i][1]=o+a,o=e[r][i][1]):(e[r][i][0]=0,e[r][i][1]=0)}};t.offsetPositive=L;var B={sign:M,expand:v.stackOffsetExpand,none:v.stackOffsetNone,silhouette:v.stackOffsetSilhouette,wiggle:v.stackOffsetWiggle,positive:L},F=function(e,t,i){var n=t.map((function(e){return e.props.dataKey})),o=B[i];return(0,v.stack)().keys(n).value((function(e,t){return+I(e,t,0)})).order(v.stackOrderNone).offset(o)(e)};t.getStackedData=F,t.getStackGroupsByAxisId=function(e,t,i,n,o,r){if(!e)return null;var a=(r?t.reverse():t).reduce((function(e,t){var o=t.props,r=o.stackId;if(o.hide)return e;var a=t.props[i],s=e[a]||{hasStack:!1,stackGroups:{}};if((0,b.isNumOrStr)(r)){var l=s.stackGroups[r]||{numericAxisId:i,cateAxisId:n,items:[]};l.items.push(t),s.hasStack=!0,s.stackGroups[r]=l}else s.stackGroups[(0,b.uniqueId)("_stackId_")]={numericAxisId:i,cateAxisId:n,items:[t]};return P(P({},e),{},A({},a,s))}),{});return Object.keys(a).reduce((function(t,r){var s=a[r];return s.hasStack&&(s.stackGroups=Object.keys(s.stackGroups).reduce((function(t,r){var a=s.stackGroups[r];return P(P({},t),{},A({},r,{numericAxisId:i,cateAxisId:n,items:a.items,stackedData:F(e,a.items,o)}))}),{})),P(P({},t),{},A({},r,s))}),{})},t.getTicksOfScale=function(e,t){var i=t.realScaleType,n=t.type,o=t.tickCount,r=t.originalDomain,a=t.allowDecimals,s=i||t.scale;if("auto"!==s&&"linear"!==s)return null;if(o&&"number"===n&&r&&("auto"===r[0]||"auto"===r[1])){var l=e.domain();if(!l.length)return null;var c=(0,y.getNiceTickValues)(l,o,a);return e.domain([(0,u.default)(c),(0,d.default)(c)]),{niceTicks:c}}if(o&&"number"===n){var h=e.domain();return{niceTicks:(0,y.getTickValuesFixedDomain)(h,o,a)}}return null},t.getCateCoordinateOfLine=function(e){var t=e.axis,i=e.ticks,n=e.bandSize,o=e.entry,r=e.index,a=e.dataKey;if("category"===t.type){if(!t.allowDuplicatedCategory&&t.dataKey&&!(0,f.default)(o[t.dataKey])){var s=(0,b.findEntryInArray)(i,"value",o[t.dataKey]);if(s)return s.coordinate+n/2}return i[r]?i[r].coordinate+n/2:null}var l=I(o,(0,f.default)(a)?t.dataKey:a);return(0,f.default)(l)?null:t.scale(l)},t.getCateCoordinateOfBar=function(e){var t=e.axis,i=e.ticks,n=e.offset,o=e.bandSize,r=e.entry,a=e.index;if("category"===t.type)return i[a]?i[a].coordinate+n:null;var s=I(r,t.dataKey,t.domain[a]);return(0,f.default)(s)?null:t.scale(s)-o/2+n},t.getBaseValueOfBar=function(e){var t=e.numericAxis,i=t.scale.domain();if("number"===t.type){var n=Math.min(i[0],i[1]),o=Math.max(i[0],i[1]);return n<=0&&o>=0?0:o<0?o:n}return i[0]},t.getStackedDataOfItem=function(e,t){var i=e.props.stackId;if((0,b.isNumOrStr)(i)){var n=t[i];if(n){var o=n.items.indexOf(e);return o>=0?n.stackedData[o]:null}}return null},t.getDomainOfStackGroups=function(e,t,i){return Object.keys(e).reduce((function(n,o){var r=e[o].stackedData.reduce((function(e,n){var o=n.slice(t,i+1).reduce((function(e,t){return[(0,u.default)(t.concat([e[0]]).filter(b.isNumber)),(0,d.default)(t.concat([e[1]]).filter(b.isNumber))]}),[1/0,-1/0]);return[Math.min(e[0],o[0]),Math.max(e[1],o[1])]}),[1/0,-1/0]);return[Math.min(r[0],n[0]),Math.max(r[1],n[1])]}),[1/0,-1/0]).map((function(e){return e===1/0||e===-1/0?0:e}))};var U=/^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/;t.MIN_VALUE_REG=U;var H=/^dataMax[\s]*\+[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/;t.MAX_VALUE_REG=H,t.parseSpecifiedDomain=function(e,t,i){if((0,p.default)(e))return e(t,i);if(!(0,c.default)(e))return t;var n=[];if((0,b.isNumber)(e[0]))n[0]=i?e[0]:Math.min(e[0],t[0]);else if(U.test(e[0])){var o=+U.exec(e[0])[1];n[0]=t[0]-o}else(0,p.default)(e[0])?n[0]=e[0](t[0]):n[0]=t[0];if((0,b.isNumber)(e[1]))n[1]=i?e[1]:Math.max(e[1],t[1]);else if(H.test(e[1])){var r=+H.exec(e[1])[1];n[1]=t[1]+r}else(0,p.default)(e[1])?n[1]=e[1](t[1]):n[1]=t[1];return n},t.getBandSizeOfAxis=function(e,t,i){if(e&&e.scale&&e.scale.bandwidth){var n=e.scale.bandwidth();if(!i||n>0)return n}if(e&&t&&t.length>=2){for(var o=(0,r.default)(t,(function(e){return e.coordinate})),a=1/0,s=1,l=o.length;s<l;s++){var c=o[s],d=o[s-1];a=Math.min((c.coordinate||0)-(d.coordinate||0),a)}return a===1/0?0:a}return i?void 0:0},t.parseDomainOfCategoryAxis=function(e,t,i){return e&&e.length?(0,o.default)(e,(0,g.default)(i,"type.defaultProps.domain"))?t:e:t},t.getTooltipItem=function(e,t){var i=e.props,n=i.dataKey,o=i.name,r=i.unit,a=i.formatter,s=i.tooltipType,l=i.chartType;return P(P({},(0,S.filterProps)(e)),{},{dataKey:n,unit:r,formatter:a,name:o||n,color:_(e),value:I(t,n),type:s,payload:t,chartType:l})}},73350:function(e,t){"use strict";function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}function n(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function o(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?n(Object(i),!0).forEach((function(t){r(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):n(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function r(e,t,n){return(t=function(e){var t=function(e,t){if("object"!==i(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var o=n.call(e,"string");if("object"!==i(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===i(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}Object.defineProperty(t,"__esModule",{value:!0}),t.generatePrefixStyle=void 0;var a=["Webkit","Moz","O","ms"];t.generatePrefixStyle=function(e,t){if(!e)return null;var i=e.replace(/(\w)/,(function(e){return e.toUpperCase()})),n=a.reduce((function(e,n){return o(o({},e),{},r({},n+i,t))}),{});return n[e]=t,n}},8959:function(e,t,i){"use strict";function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.getStyleString=t.getStringSize=t.getOffset=t.calculateChartCoordinate=void 0;var o=i(68304);function r(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function a(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?r(Object(i),!0).forEach((function(t){var o,r,a;o=e,r=t,a=i[t],(r=function(e){var t=function(e,t){if("object"!==n(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var o=i.call(e,"string");if("object"!==n(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===n(t)?t:String(t)}(r))in o?Object.defineProperty(o,r,{value:a,enumerable:!0,configurable:!0,writable:!0}):o[r]=a})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):r(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function s(e){return function(e){if(Array.isArray(e))return l(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return l(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?l(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function l(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}var c={widthCache:{},cacheCount:0},d={position:"absolute",top:"-20000px",left:0,padding:0,margin:0,border:"none",whiteSpace:"pre"},u=["minWidth","maxWidth","width","minHeight","maxHeight","height","top","left","fontSize","lineHeight","padding","margin","paddingLeft","paddingRight","paddingTop","paddingBottom","marginLeft","marginRight","marginTop","marginBottom"],h="recharts_measurement_span",p=function(e){return Object.keys(e).reduce((function(t,i){return"".concat(t).concat((r=i,r.split("").reduce((function(e,t){return t===t.toUpperCase()?[].concat(s(e),["-",t.toLowerCase()]):[].concat(s(e),[t])}),[]).join("")),":").concat((n=i,o=e[i],u.indexOf(n)>=0&&o===+o?"".concat(o,"px"):o),";");var n,o,r}),"")};t.getStyleString=p,t.getStringSize=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(null==e||o.Global.isSsr)return{width:0,height:0};var i="".concat(e),n=p(t),r="".concat(i,"-").concat(n);if(c.widthCache[r])return c.widthCache[r];try{var s=document.getElementById(h);s||((s=document.createElement("span")).setAttribute("id",h),s.setAttribute("aria-hidden","true"),document.body.appendChild(s));var l=a(a({},d),t);Object.keys(l).map((function(e){return s.style[e]=l[e],e})),s.textContent=i;var u=s.getBoundingClientRect(),g={width:u.width,height:u.height};return c.widthCache[r]=g,++c.cacheCount>2e3&&(c.cacheCount=0,c.widthCache={}),g}catch(e){return{width:0,height:0}}},t.getOffset=function(e){var t=e.ownerDocument.documentElement,i={top:0,left:0};return void 0!==e.getBoundingClientRect&&(i=e.getBoundingClientRect()),{top:i.top+window.pageYOffset-t.clientTop,left:i.left+window.pageXOffset-t.clientLeft}},t.calculateChartCoordinate=function(e,t){return{chartX:Math.round(e.pageX-t.left),chartY:Math.round(e.pageY-t.top)}}},47320:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.findEntryInArray=function(e,t,i){return e&&e.length?e.find((function(e){return e&&("function"==typeof t?t(e):(0,n.default)(e,t))===i})):null},t.uniqueId=t.mathSign=t.isPercent=t.isNumber=t.isNumOrStr=t.interpolateNumber=t.hasDuplicate=t.getPercentValue=t.getLinearRegression=t.getAnyElementOfObject=void 0;var n=l(i(71758)),o=l(i(83008)),r=l(i(68014)),a=l(i(82265)),s=l(i(12343));function l(e){return e&&e.__esModule?e:{default:e}}t.mathSign=function(e){return 0===e?0:e>0?1:-1};var c=function(e){return(0,s.default)(e)&&e.indexOf("%")===e.length-1};t.isPercent=c;var d=function(e){return(0,a.default)(e)&&!(0,r.default)(e)};t.isNumber=d,t.isNumOrStr=function(e){return d(e)||(0,s.default)(e)};var u=0;t.uniqueId=function(e){var t=++u;return"".concat(e||"").concat(t)},t.getPercentValue=function(e,t){var i,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,o=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(!d(e)&&!(0,s.default)(e))return n;if(c(e)){var a=e.indexOf("%");i=t*parseFloat(e.slice(0,a))/100}else i=+e;return(0,r.default)(i)&&(i=n),o&&i>t&&(i=t),i},t.getAnyElementOfObject=function(e){if(!e)return null;var t=Object.keys(e);return t&&t.length?e[t[0]]:null},t.hasDuplicate=function(e){if(!(0,o.default)(e))return!1;for(var t=e.length,i={},n=0;n<t;n++){if(i[e[n]])return!0;i[e[n]]=!0}return!1},t.interpolateNumber=function(e,t){return d(e)&&d(t)?function(i){return e+i*(t-e)}:function(){return t}},t.getLinearRegression=function(e){if(!e||!e.length)return null;for(var t=e.length,i=0,n=0,o=0,r=0,a=1/0,s=-1/0,l=0,c=0,d=0;d<t;d++)i+=l=e[d].cx||0,n+=c=e[d].cy||0,o+=l*c,r+=l*l,a=Math.min(a,l),s=Math.max(s,l);var u=t*r!=i*i?(t*o-i*n)/(t*r-i*i):0;return{xmin:a,xmax:s,a:u,b:(n-u*i)/t}}},64692:function(e,t,i){"use strict";t._=void 0;var n=i(18426),o=i(58459),r=i(67303),a=i(15402),s=i(48828),l=i(47320);function c(e){return function(e){if(Array.isArray(e))return d(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return d(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?d(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function d(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}t._=function(e,t,i,d,u){var h=(0,s.findAllByType)(e,o.ReferenceLine),p=(0,s.findAllByType)(e,n.ReferenceDot),g=[].concat(c(h),c(p)),f=(0,s.findAllByType)(e,r.ReferenceArea),m="".concat(d,"Id"),v=d[0],y=t;if(g.length&&(y=g.reduce((function(e,t){if(t.props[m]===i&&(0,a.ifOverflowMatches)(t.props,"extendDomain")&&(0,l.isNumber)(t.props[v])){var n=t.props[v];return[Math.min(e[0],n),Math.max(e[1],n)]}return e}),y)),f.length){var C="".concat(v,"1"),b="".concat(v,"2");y=f.reduce((function(e,t){if(t.props[m]===i&&(0,a.ifOverflowMatches)(t.props,"extendDomain")&&(0,l.isNumber)(t.props[C])&&(0,l.isNumber)(t.props[b])){var n=t.props[C],o=t.props[b];return[Math.min(e[0],n,o),Math.max(e[1],n,o)]}return e}),y)}return u&&u.length&&(y=u.reduce((function(e,t){return(0,l.isNumber)(t)?[Math.min(e[0],t),Math.max(e[1],t)]:e}),y)),y}},60637:function(e,t,i){"use strict";var n;t.td=t.YZ=void 0;var o=new(((n=i(40764))&&n.__esModule?n:{default:n}).default);t.td=o,o.setMaxListeners&&o.setMaxListeners(10),t.YZ="recharts.syncMouseEvents"},68304:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Global=void 0;var i={isSsr:!("undefined"!=typeof window&&window.document&&window.document.createElement&&window.setTimeout),get:function(e){return i[e]},set:function(e,t){if("string"==typeof e)i[e]=t;else{var n=Object.keys(e);n&&n.length&&n.forEach((function(t){i[t]=e[t]}))}}};t.Global=i},15402:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ifOverflowMatches=void 0,t.ifOverflowMatches=function(e,t){var i=e.alwaysShow,n=e.ifOverflow;return i&&(n="extendDomain"),n===t}},91248:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.warn=void 0,t.warn=function(e,t){for(var i=arguments.length,n=new Array(i>2?i-2:0),o=2;o<i;o++)n[o-2]=arguments[o]}},60212:function(e,t,i){"use strict";function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.radianToDegree=t.polarToCartesian=t.inRangeOfSector=t.getMaxRadius=t.getAngleOfPoint=t.formatAxisMap=t.formatAngleOfSector=t.distanceBetweenPoints=t.degreeToRadian=t.RADIAN=void 0;var o,r=(o=i(18562))&&o.__esModule?o:{default:o},a=i(47320),s=i(10455);function l(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function c(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?l(Object(i),!0).forEach((function(t){d(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):l(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function d(e,t,i){return(t=function(e){var t=function(e,t){if("object"!==n(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var o=i.call(e,"string");if("object"!==n(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===n(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}var h=Math.PI/180;t.RADIAN=h,t.degreeToRadian=function(e){return e*Math.PI/180};var p=function(e){return 180*e/Math.PI};t.radianToDegree=p,t.polarToCartesian=function(e,t,i,n){return{x:e+Math.cos(-h*n)*i,y:t+Math.sin(-h*n)*i}};var g=function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{top:0,right:0,bottom:0,left:0};return Math.min(Math.abs(e-(i.left||0)-(i.right||0)),Math.abs(t-(i.top||0)-(i.bottom||0)))/2};t.getMaxRadius=g,t.formatAxisMap=function(e,t,i,n,o){var l=e.width,h=e.height,p=e.startAngle,f=e.endAngle,m=(0,a.getPercentValue)(e.cx,l,l/2),v=(0,a.getPercentValue)(e.cy,h,h/2),y=g(l,h,i),C=(0,a.getPercentValue)(e.innerRadius,y,0),b=(0,a.getPercentValue)(e.outerRadius,y,.8*y);return Object.keys(t).reduce((function(e,i){var a,l,h,g=t[i],y=g.domain,S=g.reversed;if((0,r.default)(g.range))"angleAxis"===n?a=[p,f]:"radiusAxis"===n&&(a=[C,b]),S&&(a=[a[1],a[0]]);else{var x=(l=a=g.range,h=2,function(e){if(Array.isArray(e))return e}(l)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var n,o,r,a,s=[],l=!0,c=!1;try{if(r=(i=i.call(e)).next,0===t){if(Object(i)!==i)return;l=!1}else for(;!(l=(n=r.call(i)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=i.return&&(a=i.return(),Object(a)!==a))return}finally{if(c)throw o}}return s}}(l,h)||function(e,t){if(e){if("string"==typeof e)return u(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?u(e,t):void 0}}(l,h)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}());p=x[0],f=x[1]}var T=(0,s.parseScale)(g,o),w=T.realScaleType,O=T.scale;O.domain(y).range(a),(0,s.checkDomainOfScale)(O);var P=(0,s.getTicksOfScale)(O,c(c({},g),{},{realScaleType:w})),A=c(c(c({},g),P),{},{range:a,radius:b,realScaleType:w,scale:O,cx:m,cy:v,innerRadius:C,outerRadius:b,startAngle:p,endAngle:f});return c(c({},e),{},d({},i,A))}),{})};var f=function(e,t){var i=e.x,n=e.y,o=t.x,r=t.y;return Math.sqrt(Math.pow(i-o,2)+Math.pow(n-r,2))};t.distanceBetweenPoints=f;var m=function(e,t){var i=e.x,n=e.y,o=t.cx,r=t.cy,a=f({x:i,y:n},{x:o,y:r});if(a<=0)return{radius:a};var s=(i-o)/a,l=Math.acos(s);return n>r&&(l=2*Math.PI-l),{radius:a,angle:p(l),angleInRadian:l}};t.getAngleOfPoint=m;var v=function(e){var t=e.startAngle,i=e.endAngle,n=Math.floor(t/360),o=Math.floor(i/360),r=Math.min(n,o);return{startAngle:t-360*r,endAngle:i-360*r}};t.formatAngleOfSector=v;var y=function(e,t){var i=t.startAngle,n=t.endAngle,o=Math.floor(i/360),r=Math.floor(n/360);return e+360*Math.min(o,r)};t.inRangeOfSector=function(e,t){var i=e.x,n=e.y,o=m({x:i,y:n},t),r=o.radius,a=o.angle,s=t.innerRadius,l=t.outerRadius;if(r<s||r>l)return!1;if(0===r)return!0;var d,u=v(t),h=u.startAngle,p=u.endAngle,g=a;if(h<=p){for(;g>p;)g-=360;for(;g<h;)g+=360;d=g>=h&&g<=p}else{for(;g>h;)g-=360;for(;g<p;)g+=360;d=g>=p&&g<=h}return d?c(c({},t),{},{radius:r,angle:y(g,t)}):null}},48828:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.filterSvgElements=t.filterProps=t.TOOLTIP_TYPES=t.SCALE_TYPES=t.LEGEND_TYPES=void 0,t.findAllByType=w,t.findChildByType=function(e,t){var i=w(e,t);return i&&i[0]},t.withoutType=t.validateWidthHeight=t.toArray=t.renderByOrder=t.parseChildIndex=t.isValidSpreadableProp=t.isSingleChildEqual=t.isDotProps=t.isChildrenEqual=t.getReactEventByType=t.getDisplayName=void 0;var n=m(i(63991)),o=m(i(40825)),r=m(i(12343)),a=m(i(71758)),s=m(i(18562)),l=m(i(83008)),c=i(8559),d=i(37787),u=i(47320),h=i(19518),p=i(13630),g=["children"],f=["children"];function m(e){return e&&e.__esModule?e:{default:e}}function v(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}function y(e){return y="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},y(e)}var C={click:"onClick",mousedown:"onMouseDown",mouseup:"onMouseUp",mouseover:"onMouseOver",mousemove:"onMouseMove",mouseout:"onMouseOut",mouseenter:"onMouseEnter",mouseleave:"onMouseLeave",touchcancel:"onTouchCancel",touchend:"onTouchEnd",touchmove:"onTouchMove",touchstart:"onTouchStart"};t.SCALE_TYPES=["auto","linear","pow","sqrt","log","identity","time","band","point","ordinal","quantile","quantize","utc","sequential","threshold"],t.LEGEND_TYPES=["plainline","line","square","rect","circle","cross","diamond","star","triangle","wye","none"],t.TOOLTIP_TYPES=["none"];var b=function(e){return"string"==typeof e?e:e?e.displayName||e.name||"Component":""};t.getDisplayName=b;var S=null,x=null,T=function e(t){if(t===S&&(0,l.default)(x))return x;var i=[];return c.Children.forEach(t,(function(t){(0,s.default)(t)||((0,d.isFragment)(t)?i=i.concat(e(t.props.children)):i.push(t))})),x=i,S=t,i};function w(e,t){var i=[],n=[];return n=(0,l.default)(t)?t.map((function(e){return b(e)})):[b(t)],T(e).forEach((function(e){var t=(0,a.default)(e,"type.displayName")||(0,a.default)(e,"type.name");-1!==n.indexOf(t)&&i.push(e)})),i}t.toArray=T,t.withoutType=function(e,t){var i,n=[];return i=(0,l.default)(t)?t.map((function(e){return b(e)})):[b(t)],T(e).forEach((function(e){var t=(0,a.default)(e,"type.displayName");t&&-1!==i.indexOf(t)||n.push(e)})),n},t.validateWidthHeight=function(e){if(!e||!e.props)return!1;var t=e.props,i=t.width,n=t.height;return!(!(0,u.isNumber)(i)||i<=0||!(0,u.isNumber)(n)||n<=0)};var O=["a","altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","circle","clipPath","color-profile","cursor","defs","desc","ellipse","feBlend","feColormatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-url","foreignObject","g","glyph","glyphRef","hkern","image","line","lineGradient","marker","mask","metadata","missing-glyph","mpath","path","pattern","polygon","polyline","radialGradient","rect","script","set","stop","style","svg","switch","symbol","text","textPath","title","tref","tspan","use","view","vkern"],P=function(e){return e&&e.type&&(0,r.default)(e.type)&&O.indexOf(e.type)>=0};t.isDotProps=function(e){return e&&"object"===y(e)&&"cx"in e&&"cy"in e&&"r"in e};var A=function(e,t,i,n){var r,a=null!==(r=null===p.FilteredElementKeyMap||void 0===p.FilteredElementKeyMap?void 0:p.FilteredElementKeyMap[n])&&void 0!==r?r:[];return!(0,o.default)(e)&&(n&&a.includes(t)||p.SVGElementPropKeys.includes(t))||i&&p.EventKeys.includes(t)};t.isValidSpreadableProp=A,t.filterSvgElements=function(e){var t=[];return T(e).forEach((function(e){P(e)&&t.push(e)})),t},t.filterProps=function(e,t,i){if(!e||"function"==typeof e||"boolean"==typeof e)return null;var o=e;if((0,c.isValidElement)(e)&&(o=e.props),!(0,n.default)(o))return null;var r={};return Object.keys(o).forEach((function(e){var n;A(null===(n=o)||void 0===n?void 0:n[e],e,t,i)&&(r[e]=o[e])})),r};var E=function e(t,i){if(t===i)return!0;var n=c.Children.count(t);if(n!==c.Children.count(i))return!1;if(0===n)return!0;if(1===n)return k((0,l.default)(t)?t[0]:t,(0,l.default)(i)?i[0]:i);for(var o=0;o<n;o++){var r=t[o],a=i[o];if((0,l.default)(r)||(0,l.default)(a)){if(!e(r,a))return!1}else if(!k(r,a))return!1}return!0};t.isChildrenEqual=E;var k=function(e,t){if((0,s.default)(e)&&(0,s.default)(t))return!0;if(!(0,s.default)(e)&&!(0,s.default)(t)){var i=e.props||{},n=i.children,o=v(i,g),r=t.props||{},a=r.children,l=v(r,f);return n&&a?(0,h.shallowEqual)(o,l)&&E(n,a):!n&&!a&&(0,h.shallowEqual)(o,l)}return!1};t.isSingleChildEqual=k,t.renderByOrder=function(e,t){var i=[],n={};return T(e).forEach((function(e,o){if(P(e))i.push(e);else if(e){var r=b(e.type),a=t[r]||{},s=a.handler,l=a.once;if(s&&(!l||!n[r])){var c=s(e,r,o);i.push(c),n[r]=!0}}})),i},t.getReactEventByType=function(e){var t=e&&e.type;return t&&C[t]?C[t]:null},t.parseChildIndex=function(e,t){return T(t).indexOf(e)}},68953:function(e,t){"use strict";function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}function n(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var n,o,r,a,s=[],l=!0,c=!1;try{if(r=(i=i.call(e)).next,0===t){if(Object(i)!==i)return;l=!1}else for(;!(l=(n=r.call(i)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(e){c=!0,o=e}finally{try{if(!l&&null!=i.return&&(a=i.return(),Object(a)!==a))return}finally{if(c)throw o}}return s}}(e,t)||function(e,t){if(e){if("string"==typeof e)return o(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?o(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function o(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,n=new Array(t);i<t;i++)n[i]=e[i];return n}function r(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,(void 0,r=function(e,t){if("object"!==i(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var o=n.call(e,"string");if("object"!==i(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(o.key),"symbol"===i(r)?r:String(r)),o)}var r}Object.defineProperty(t,"__esModule",{value:!0}),t.reduceCSSCalc=function(e){var t=m(e.slice(5,-1));return t===h?"":t},t.safeEvaluateExpression=m;var a=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([*/])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,s=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([+-])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,l=/^px|cm|vh|vw|em|rem|%|mm|in|pt|pc|ex|ch|vmin|vmax|Q$/,c=/(-?\d+(?:\.\d+)?)([a-zA-Z%]+)?/,d={cm:96/2.54,mm:96/25.4,pt:96/72,pc:16,in:96,Q:96/101.6,px:1},u=Object.keys(d),h="NaN",p=function(){function e(t,i){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.num=t,this.unit=i,this.num=t,this.unit=i,Number.isNaN(t)&&(this.unit=""),""===i||l.test(i)||(this.num=NaN,this.unit=""),u.includes(i)&&(this.num=function(e,t){return e*d[t]}(t,i),this.unit="px")}var t,i,o;return t=e,o=[{key:"parse",value:function(t){var i,o=n(null!==(i=c.exec(t))&&void 0!==i?i:[],3),r=o[1],a=o[2];return new e(parseFloat(r),null!=a?a:"")}}],(i=[{key:"add",value:function(t){return this.unit!==t.unit?new e(NaN,""):new e(this.num+t.num,this.unit)}},{key:"subtract",value:function(t){return this.unit!==t.unit?new e(NaN,""):new e(this.num-t.num,this.unit)}},{key:"multiply",value:function(t){return""!==this.unit&&""!==t.unit&&this.unit!==t.unit?new e(NaN,""):new e(this.num*t.num,this.unit||t.unit)}},{key:"divide",value:function(t){return""!==this.unit&&""!==t.unit&&this.unit!==t.unit?new e(NaN,""):new e(this.num/t.num,this.unit||t.unit)}},{key:"toString",value:function(){return"".concat(this.num).concat(this.unit)}},{key:"isNaN",value:function(){return Number.isNaN(this.num)}}])&&r(t.prototype,i),o&&r(t,o),Object.defineProperty(t,"prototype",{writable:!1}),e}();function g(e){if(e.includes(h))return h;for(var t=e;t.includes("*")||t.includes("/");){var i,o=n(null!==(i=a.exec(t))&&void 0!==i?i:[],4),r=o[1],l=o[2],c=o[3],d=p.parse(null!=r?r:""),u=p.parse(null!=c?c:""),g="*"===l?d.multiply(u):d.divide(u);if(g.isNaN())return h;t=t.replace(a,g.toString())}for(;t.includes("+")||/.-\d+(?:\.\d+)?/.test(t);){var f,m=n(null!==(f=s.exec(t))&&void 0!==f?f:[],4),v=m[1],y=m[2],C=m[3],b=p.parse(null!=v?v:""),S=p.parse(null!=C?C:""),x="+"===y?b.add(S):b.subtract(S);if(x.isNaN())return h;t=t.replace(s,x.toString())}return t}var f=/\(([^()]*)\)/;function m(e){try{return function(e){var t=e.replace(/\s+/g,"");return t=function(e){for(var t=e;t.includes("(");){var i=n(f.exec(t),2)[1];t=t.replace(f,g(i))}return t}(t),g(t)}(e)}catch(e){return h}}},19518:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.shallowEqual=function(e,t){for(var i in e)if({}.hasOwnProperty.call(e,i)&&(!{}.hasOwnProperty.call(t,i)||e[i]!==t[i]))return!1;for(var n in t)if({}.hasOwnProperty.call(t,n)&&!{}.hasOwnProperty.call(e,n))return!1;return!0}},89211:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getAngledTickWidth=function(e,t,i){var o={width:e.width+t.width,height:e.height+t.height};return(0,n.getAngledRectangleWidth)(o,i)},t.getNumberIntervalTicks=function(e,t){return(0,o.getEveryNthWithCondition)(e,t+1)},t.getTickBoundaries=function(e,t,i){var n="width"===i,o=e.x,r=e.y,a=e.width,s=e.height;return 1===t?{start:n?o:r,end:n?o+a:r+s}:{start:n?o+a:r+s,end:n?o:r}},t.isVisible=function(e,t,i,n,o){return e*(t-e*i/2-n)>=0&&e*(t+e*i/2-o)<=0};var n=i(12618),o=i(87416)},87416:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getEveryNthWithCondition=function(e,t,i){if(t<1)return[];if(1===t&&void 0===i)return e;for(var n=[],o=0;o<e.length;o+=t){if(void 0!==i&&!0!==i(e[o]))return;n.push(e[o])}return n}},32489:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getLegendProps=void 0;var n=i(36725),o=i(10455),r=i(48828);function a(e){return a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},a(e)}function s(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function l(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?s(Object(i),!0).forEach((function(t){var n,o,r;n=e,o=t,r=i[t],(o=function(e){var t=function(e,t){if("object"!==a(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==a(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===a(t)?t:String(t)}(o))in n?Object.defineProperty(n,o,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[o]=r})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):s(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}t.getLegendProps=function(e){var t,i=e.children,a=e.formattedGraphicalItems,s=e.legendWidth,c=e.legendContent,d=(0,r.findChildByType)(i,n.Legend);return d?(t=d.props&&d.props.payload?d.props&&d.props.payload:"children"===c?(a||[]).reduce((function(e,t){var i=t.item,n=t.props,o=n.sectors||n.data||[];return e.concat(o.map((function(e){return{type:d.props.iconType||i.props.legendType,value:e.name,color:e.fill,payload:e}})))}),[]):(a||[]).map((function(e){var t=e.item,i=t.props,n=i.dataKey,r=i.name,a=i.legendType;return{inactive:i.hide,dataKey:n,type:d.props.iconType||a||"square",color:(0,o.getMainColorOfGraphicItem)(t),value:r||n,payload:t.props}})),l(l(l({},d.props),n.Legend.getWithHeight(d,s)),{},{payload:t,item:d})):null}},13630:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.adaptEventsOfChild=t.adaptEventHandlers=t.SVGElementPropKeys=t.FilteredElementKeyMap=t.EventKeys=void 0;var n,o=(n=i(63991))&&n.__esModule?n:{default:n},r=i(8559);function a(e){return a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},a(e)}t.SVGElementPropKeys=["aria-activedescendant","aria-atomic","aria-autocomplete","aria-busy","aria-checked","aria-colcount","aria-colindex","aria-colspan","aria-controls","aria-current","aria-describedby","aria-details","aria-disabled","aria-errormessage","aria-expanded","aria-flowto","aria-haspopup","aria-hidden","aria-invalid","aria-keyshortcuts","aria-label","aria-labelledby","aria-level","aria-live","aria-modal","aria-multiline","aria-multiselectable","aria-orientation","aria-owns","aria-placeholder","aria-posinset","aria-pressed","aria-readonly","aria-relevant","aria-required","aria-roledescription","aria-rowcount","aria-rowindex","aria-rowspan","aria-selected","aria-setsize","aria-sort","aria-valuemax","aria-valuemin","aria-valuenow","aria-valuetext","className","color","height","id","lang","max","media","method","min","name","style","target","width","role","tabIndex","accentHeight","accumulate","additive","alignmentBaseline","allowReorder","alphabetic","amplitude","arabicForm","ascent","attributeName","attributeType","autoReverse","azimuth","baseFrequency","baselineShift","baseProfile","bbox","begin","bias","by","calcMode","capHeight","clip","clipPath","clipPathUnits","clipRule","colorInterpolation","colorInterpolationFilters","colorProfile","colorRendering","contentScriptType","contentStyleType","cursor","cx","cy","d","decelerate","descent","diffuseConstant","direction","display","divisor","dominantBaseline","dur","dx","dy","edgeMode","elevation","enableBackground","end","exponent","externalResourcesRequired","fill","fillOpacity","fillRule","filter","filterRes","filterUnits","floodColor","floodOpacity","focusable","fontFamily","fontSize","fontSizeAdjust","fontStretch","fontStyle","fontVariant","fontWeight","format","from","fx","fy","g1","g2","glyphName","glyphOrientationHorizontal","glyphOrientationVertical","glyphRef","gradientTransform","gradientUnits","hanging","horizAdvX","horizOriginX","href","ideographic","imageRendering","in2","in","intercept","k1","k2","k3","k4","k","kernelMatrix","kernelUnitLength","kerning","keyPoints","keySplines","keyTimes","lengthAdjust","letterSpacing","lightingColor","limitingConeAngle","local","markerEnd","markerHeight","markerMid","markerStart","markerUnits","markerWidth","mask","maskContentUnits","maskUnits","mathematical","mode","numOctaves","offset","opacity","operator","order","orient","orientation","origin","overflow","overlinePosition","overlineThickness","paintOrder","panose1","pathLength","patternContentUnits","patternTransform","patternUnits","pointerEvents","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","r","radius","refX","refY","renderingIntent","repeatCount","repeatDur","requiredExtensions","requiredFeatures","restart","result","rotate","rx","ry","seed","shapeRendering","slope","spacing","specularConstant","specularExponent","speed","spreadMethod","startOffset","stdDeviation","stemh","stemv","stitchTiles","stopColor","stopOpacity","strikethroughPosition","strikethroughThickness","string","stroke","strokeDasharray","strokeDashoffset","strokeLinecap","strokeLinejoin","strokeMiterlimit","strokeOpacity","strokeWidth","surfaceScale","systemLanguage","tableValues","targetX","targetY","textAnchor","textDecoration","textLength","textRendering","to","transform","u1","u2","underlinePosition","underlineThickness","unicode","unicodeBidi","unicodeRange","unitsPerEm","vAlphabetic","values","vectorEffect","version","vertAdvY","vertOriginX","vertOriginY","vHanging","vIdeographic","viewTarget","visibility","vMathematical","widths","wordSpacing","writingMode","x1","x2","x","xChannelSelector","xHeight","xlinkActuate","xlinkArcrole","xlinkHref","xlinkRole","xlinkShow","xlinkTitle","xlinkType","xmlBase","xmlLang","xmlns","xmlnsXlink","xmlSpace","y1","y2","y","yChannelSelector","z","zoomAndPan","ref","key","angle"];var s=["points","pathLength"],l={svg:["viewBox","children"],polygon:s,polyline:s};t.FilteredElementKeyMap=l;var c=["dangerouslySetInnerHTML","onCopy","onCopyCapture","onCut","onCutCapture","onPaste","onPasteCapture","onCompositionEnd","onCompositionEndCapture","onCompositionStart","onCompositionStartCapture","onCompositionUpdate","onCompositionUpdateCapture","onFocus","onFocusCapture","onBlur","onBlurCapture","onChange","onChangeCapture","onBeforeInput","onBeforeInputCapture","onInput","onInputCapture","onReset","onResetCapture","onSubmit","onSubmitCapture","onInvalid","onInvalidCapture","onLoad","onLoadCapture","onError","onErrorCapture","onKeyDown","onKeyDownCapture","onKeyPress","onKeyPressCapture","onKeyUp","onKeyUpCapture","onAbort","onAbortCapture","onCanPlay","onCanPlayCapture","onCanPlayThrough","onCanPlayThroughCapture","onDurationChange","onDurationChangeCapture","onEmptied","onEmptiedCapture","onEncrypted","onEncryptedCapture","onEnded","onEndedCapture","onLoadedData","onLoadedDataCapture","onLoadedMetadata","onLoadedMetadataCapture","onLoadStart","onLoadStartCapture","onPause","onPauseCapture","onPlay","onPlayCapture","onPlaying","onPlayingCapture","onProgress","onProgressCapture","onRateChange","onRateChangeCapture","onSeeked","onSeekedCapture","onSeeking","onSeekingCapture","onStalled","onStalledCapture","onSuspend","onSuspendCapture","onTimeUpdate","onTimeUpdateCapture","onVolumeChange","onVolumeChangeCapture","onWaiting","onWaitingCapture","onAuxClick","onAuxClickCapture","onClick","onClickCapture","onContextMenu","onContextMenuCapture","onDoubleClick","onDoubleClickCapture","onDrag","onDragCapture","onDragEnd","onDragEndCapture","onDragEnter","onDragEnterCapture","onDragExit","onDragExitCapture","onDragLeave","onDragLeaveCapture","onDragOver","onDragOverCapture","onDragStart","onDragStartCapture","onDrop","onDropCapture","onMouseDown","onMouseDownCapture","onMouseEnter","onMouseLeave","onMouseMove","onMouseMoveCapture","onMouseOut","onMouseOutCapture","onMouseOver","onMouseOverCapture","onMouseUp","onMouseUpCapture","onSelect","onSelectCapture","onTouchCancel","onTouchCancelCapture","onTouchEnd","onTouchEndCapture","onTouchMove","onTouchMoveCapture","onTouchStart","onTouchStartCapture","onPointerDown","onPointerDownCapture","onPointerMove","onPointerMoveCapture","onPointerUp","onPointerUpCapture","onPointerCancel","onPointerCancelCapture","onPointerEnter","onPointerEnterCapture","onPointerLeave","onPointerLeaveCapture","onPointerOver","onPointerOverCapture","onPointerOut","onPointerOutCapture","onGotPointerCapture","onGotPointerCaptureCapture","onLostPointerCapture","onLostPointerCaptureCapture","onScroll","onScrollCapture","onWheel","onWheelCapture","onAnimationStart","onAnimationStartCapture","onAnimationEnd","onAnimationEndCapture","onAnimationIteration","onAnimationIterationCapture","onTransitionEnd","onTransitionEndCapture"];t.EventKeys=c,t.adaptEventHandlers=function(e,t){if(!e||"function"==typeof e||"boolean"==typeof e)return null;var i=e;if((0,r.isValidElement)(e)&&(i=e.props),!(0,o.default)(i))return null;var n={};return Object.keys(i).forEach((function(e){c.includes(e)&&(n[e]=t||function(t){return i[e](i,t)})})),n},t.adaptEventsOfChild=function(e,t,i){if(!(0,o.default)(e)||"object"!==a(e))return null;var n=null;return Object.keys(e).forEach((function(o){var r=e[o];c.includes(o)&&"function"==typeof r&&(n||(n={}),n[o]=function(e,t,i){return function(n){return e(t,i,n),null}}(r,t,i))})),n}},20834:function(e,t){"use strict";function i(e,t){var i=e.length;e.push(t);e:for(;0<i;){var n=i-1>>>1,o=e[n];if(!(0<r(o,t)))break e;e[n]=t,e[i]=o,i=n}}function n(e){return 0===e.length?null:e[0]}function o(e){if(0===e.length)return null;var t=e[0],i=e.pop();if(i!==t){e[0]=i;e:for(var n=0,o=e.length,a=o>>>1;n<a;){var s=2*(n+1)-1,l=e[s],c=s+1,d=e[c];if(0>r(l,i))c<o&&0>r(d,l)?(e[n]=d,e[c]=i,n=c):(e[n]=l,e[s]=i,n=s);else{if(!(c<o&&0>r(d,i)))break e;e[n]=d,e[c]=i,n=c}}}return t}function r(e,t){var i=e.sortIndex-t.sortIndex;return 0!==i?i:e.id-t.id}if("object"==typeof performance&&"function"==typeof performance.now){var a=performance;t.unstable_now=function(){return a.now()}}else{var s=Date,l=s.now();t.unstable_now=function(){return s.now()-l}}var c=[],d=[],u=1,h=null,p=3,g=!1,f=!1,m=!1,v="function"==typeof setTimeout?setTimeout:null,y="function"==typeof clearTimeout?clearTimeout:null,C="undefined"!=typeof setImmediate?setImmediate:null;function b(e){for(var t=n(d);null!==t;){if(null===t.callback)o(d);else{if(!(t.startTime<=e))break;o(d),t.sortIndex=t.expirationTime,i(c,t)}t=n(d)}}function S(e){if(m=!1,b(e),!f)if(null!==n(c))f=!0,N(x);else{var t=n(d);null!==t&&R(S,t.startTime-e)}}function x(e,i){f=!1,m&&(m=!1,y(P),P=-1),g=!0;var r=p;try{for(b(i),h=n(c);null!==h&&(!(h.expirationTime>i)||e&&!k());){var a=h.callback;if("function"==typeof a){h.callback=null,p=h.priorityLevel;var s=a(h.expirationTime<=i);i=t.unstable_now(),"function"==typeof s?h.callback=s:h===n(c)&&o(c),b(i)}else o(c);h=n(c)}if(null!==h)var l=!0;else{var u=n(d);null!==u&&R(S,u.startTime-i),l=!1}return l}finally{h=null,p=r,g=!1}}"undefined"!=typeof navigator&&void 0!==navigator.scheduling&&void 0!==navigator.scheduling.isInputPending&&navigator.scheduling.isInputPending.bind(navigator.scheduling);var T,w=!1,O=null,P=-1,A=5,E=-1;function k(){return!(t.unstable_now()-E<A)}function I(){if(null!==O){var e=t.unstable_now();E=e;var i=!0;try{i=O(!0,e)}finally{i?T():(w=!1,O=null)}}else w=!1}if("function"==typeof C)T=function(){C(I)};else if("undefined"!=typeof MessageChannel){var D=new MessageChannel,_=D.port2;D.port1.onmessage=I,T=function(){_.postMessage(null)}}else T=function(){v(I,0)};function N(e){O=e,w||(w=!0,T())}function R(e,i){P=v((function(){e(t.unstable_now())}),i)}t.unstable_IdlePriority=5,t.unstable_ImmediatePriority=1,t.unstable_LowPriority=4,t.unstable_NormalPriority=3,t.unstable_Profiling=null,t.unstable_UserBlockingPriority=2,t.unstable_cancelCallback=function(e){e.callback=null},t.unstable_continueExecution=function(){f||g||(f=!0,N(x))},t.unstable_forceFrameRate=function(e){0>e||125<e||(A=0<e?Math.floor(1e3/e):5)},t.unstable_getCurrentPriorityLevel=function(){return p},t.unstable_getFirstCallbackNode=function(){return n(c)},t.unstable_next=function(e){switch(p){case 1:case 2:case 3:var t=3;break;default:t=p}var i=p;p=t;try{return e()}finally{p=i}},t.unstable_pauseExecution=function(){},t.unstable_requestPaint=function(){},t.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var i=p;p=e;try{return t()}finally{p=i}},t.unstable_scheduleCallback=function(e,o,r){var a=t.unstable_now();switch(r="object"==typeof r&&null!==r&&"number"==typeof(r=r.delay)&&0<r?a+r:a,e){case 1:var s=-1;break;case 2:s=250;break;case 5:s=1073741823;break;case 4:s=1e4;break;default:s=5e3}return e={id:u++,callback:o,priorityLevel:e,startTime:r,expirationTime:s=r+s,sortIndex:-1},r>a?(e.sortIndex=r,i(d,e),null===n(c)&&e===n(d)&&(m?(y(P),P=-1):m=!0,R(S,r-a))):(e.sortIndex=s,i(c,e),f||g||(f=!0,N(x))),e},t.unstable_shouldYield=k,t.unstable_wrapCallback=function(e){var t=p;return function(){var i=p;p=t;try{return e.apply(this,arguments)}finally{p=i}}}},44853:function(e,t,i){"use strict";e.exports=i(20834)},33048:function(e){e.exports=function(e,t,i,n){var o=i?i.call(n,e,t):void 0;if(void 0!==o)return!!o;if(e===t)return!0;if("object"!=typeof e||!e||"object"!=typeof t||!t)return!1;var r=Object.keys(e),a=Object.keys(t);if(r.length!==a.length)return!1;for(var s=Object.prototype.hasOwnProperty.bind(t),l=0;l<r.length;l++){var c=r[l];if(!s(c))return!1;var d=e[c],u=t[c];if(!1===(o=i?i.call(n,d,u,c):void 0)||void 0===o&&d!==u)return!1}return!0}},35695:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.slice=t.map=void 0;var i=Array.prototype,n=i.slice;t.slice=n;var o=i.map;t.map=o},57114:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){return null==e||null==t?NaN:e<t?-1:e>t?1:e>=t?0:NaN}},84801:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){var e=s.default,t=a.default,i=d.default;function u(n){Array.isArray(n)||(n=Array.from(n));var r,s,d,u=n.length,h=new Array(u);for(r=0;r<u;++r)h[r]=e(n[r],r,n);var p=t(h),g=p[0],f=p[1],m=i(h,g,f);if(!Array.isArray(m)){const e=f,i=+m;if(t===a.default&&([g,f]=(0,l.default)(g,f,i)),(m=(0,c.default)(g,f,i))[0]<=g&&(d=(0,c.tickIncrement)(g,f,i)),m[m.length-1]>=f)if(e>=f&&t===a.default){const e=(0,c.tickIncrement)(g,f,i);isFinite(e)&&(e>0?f=(Math.floor(f/e)+1)*e:e<0&&(f=(Math.ceil(f*-e)+1)/-e))}else m.pop()}for(var v=m.length;m[0]<=g;)m.shift(),--v;for(;m[v-1]>f;)m.pop(),--v;var y,C=new Array(v+1);for(r=0;r<=v;++r)(y=C[r]=[]).x0=r>0?m[r-1]:g,y.x1=r<v?m[r]:f;if(isFinite(d)){if(d>0)for(r=0;r<u;++r)null!=(s=h[r])&&g<=s&&s<=f&&C[Math.min(v,Math.floor((s-g)/d))].push(n[r]);else if(d<0)for(r=0;r<u;++r)if(null!=(s=h[r])&&g<=s&&s<=f){const e=Math.floor((g-s)*d);C[Math.min(v,e+(m[e]<=s))].push(n[r])}}else for(r=0;r<u;++r)null!=(s=h[r])&&g<=s&&s<=f&&C[(0,o.default)(m,s,0,v)].push(n[r]);return C}return u.value=function(t){return arguments.length?(e="function"==typeof t?t:(0,r.default)(t),u):e},u.domain=function(e){return arguments.length?(t="function"==typeof e?e:(0,r.default)([e[0],e[1]]),u):t},u.thresholds=function(e){return arguments.length?(i="function"==typeof e?e:Array.isArray(e)?(0,r.default)(n.slice.call(e)):(0,r.default)(e),u):i},u};var n=i(35695),o=h(i(63208)),r=h(i(92014)),a=h(i(17820)),s=h(i(23674)),l=h(i(60532)),c=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=u(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}(i(98794)),d=h(i(93390));function u(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(u=function(e){return e?i:t})(e)}function h(e){return e&&e.__esModule?e:{default:e}}},63208:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.bisectRight=t.bisectLeft=t.bisectCenter=void 0;var n=a(i(57114)),o=a(i(97091)),r=a(i(77785));function a(e){return e&&e.__esModule?e:{default:e}}const s=(0,o.default)(n.default),l=s.right;t.bisectRight=l;const c=s.left;t.bisectLeft=c;const d=(0,o.default)(r.default).center;t.bisectCenter=d;var u=l;t.default=u},97091:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){let t,i,r;function s(e,n,o=0,r=e.length){if(o<r){if(0!==t(n,n))return r;do{const t=o+r>>>1;i(e[t],n)<0?o=t+1:r=t}while(o<r)}return o}return 2!==e.length?(t=n.default,i=(t,i)=>(0,n.default)(e(t),i),r=(t,i)=>e(t)-i):(t=e===n.default||e===o.default?e:a,i=e,r=e),{left:s,center:function(e,t,i=0,n=e.length){const o=s(e,t,i,n-1);return o>i&&r(e[o-1],t)>-r(e[o],t)?o-1:o},right:function(e,n,o=0,r=e.length){if(o<r){if(0!==t(n,n))return r;do{const t=o+r>>>1;i(e[t],n)<=0?o=t+1:r=t}while(o<r)}return o}}};var n=r(i(57114)),o=r(i(31946));function r(e){return e&&e.__esModule?e:{default:e}}function a(){return 0}},92014:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return()=>e}},2503:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){let i=0;if(void 0===t)for(let t of e)null!=t&&(t=+t)>=t&&++i;else{let n=-1;for(let o of e)null!=(o=t(o,++n,e))&&(o=+o)>=o&&++i}return i}},66015:function(e,t){"use strict";function i(e){return 0|e.length}function n(e){return!(e>0)}function o(e){return"object"!=typeof e||"length"in e?e:Array.from(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(...e){const t="function"==typeof e[e.length-1]&&function(e){return t=>e(...t)}(e.pop()),r=(e=e.map(o)).map(i),a=e.length-1,s=new Array(a+1).fill(0),l=[];if(a<0||r.some(n))return l;for(;;){l.push(s.map(((t,i)=>e[i][t])));let i=a;for(;++s[i]===r[i];){if(0===i)return t?l.map(t):l;s[i--]=0}}}},32892:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var i=0,n=0;return Float64Array.from(e,void 0===t?e=>i+=+e||0:o=>i+=+t(o,n++,e)||0)}},31946:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){return null==e||null==t?NaN:t<e?-1:t>e?1:t>=e?0:NaN}},11041:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){const i=(0,o.default)(e,t);return i?Math.sqrt(i):i};var n,o=(n=i(14492))&&n.__esModule?n:{default:n}},64099:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,...t){e=new n.InternSet(e);for(const i of t)for(const t of i)e.delete(t);return e};var n=i(58913)},14179:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){const i=t[Symbol.iterator](),o=new n.InternSet;for(const t of e){if(o.has(t))return!1;let e,n;for(;({value:e,done:n}=i.next())&&!n;){if(Object.is(t,e))return!1;o.add(e)}}return!0};var n=i(58913)},19222:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if("function"!=typeof t)throw new TypeError("test is not a function");let i=-1;for(const n of e)if(!t(n,++i,e))return!1;return!0}},17820:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){let i,n;if(void 0===t)for(const t of e)null!=t&&(void 0===i?t>=t&&(i=n=t):(i>t&&(i=t),n<t&&(n=t)));else{let o=-1;for(let r of e)null!=(r=t(r,++o,e))&&(void 0===i?r>=r&&(i=n=r):(i>r&&(i=r),n<r&&(n=r)))}return[i,n]}},25024:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if("function"!=typeof t)throw new TypeError("test is not a function");const i=[];let n=-1;for(const o of e)t(o,++n,e)&&i.push(o);return i}},99415:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Adder=void 0,t.fcumsum=function(e,t){const n=new i;let o=-1;return Float64Array.from(e,void 0===t?e=>n.add(+e||0):i=>n.add(+t(i,++o,e)||0))},t.fsum=function(e,t){const n=new i;if(void 0===t)for(let t of e)(t=+t)&&n.add(t);else{let i=-1;for(let o of e)(o=+t(o,++i,e))&&n.add(o)}return+n};class i{constructor(){this._partials=new Float64Array(32),this._n=0}add(e){const t=this._partials;let i=0;for(let n=0;n<this._n&&n<32;n++){const o=t[n],r=e+o,a=Math.abs(e)<Math.abs(o)?e-(r-o):o-(r-e);a&&(t[i++]=a),e=r}return t[i]=e,this._n=i+1,this}valueOf(){const e=this._partials;let t,i,n,o=this._n,r=0;if(o>0){for(r=e[--o];o>0&&(t=r,i=e[--o],r=t+i,n=i-(r-t),!n););o>0&&(n<0&&e[o-1]<0||n>0&&e[o-1]>0)&&(i=2*n,t=r+i,i==t-r&&(r=t))}return r}}t.Adder=i},22662:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t=o.default){let i,n=!1;if(1===t.length){let r;for(const a of e){const e=t(a);(n?(0,o.default)(e,r)>0:0===(0,o.default)(e,e))&&(i=a,r=e,n=!0)}}else for(const o of e)(n?t(o,i)>0:0===t(o,o))&&(i=o,n=!0);return i};var n,o=(n=i(57114))&&n.__esModule?n:{default:n}},66264:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t=n.default){if(1===t.length)return(0,o.default)(e,t);let i,r=-1,a=-1;for(const n of e)++a,(r<0?0===t(n,n):t(n,i)>0)&&(i=n,r=a);return r};var n=r(i(57114)),o=r(i(26523));function r(e){return e&&e.__esModule?e:{default:e}}},90212:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,...t){return d(e,r.default,r.default,t)},t.flatGroup=function(e,...t){return s(a(e,...t),t)},t.flatRollup=function(e,t,...i){return s(l(e,t,...i),i)},t.groups=a,t.index=function(e,...t){return d(e,r.default,c,t)},t.indexes=function(e,...t){return d(e,Array.from,c,t)},t.rollup=function(e,t,...i){return d(e,r.default,t,i)},t.rollups=l;var n,o=i(58913),r=(n=i(23674))&&n.__esModule?n:{default:n};function a(e,...t){return d(e,Array.from,r.default,t)}function s(e,t){for(let i=1,n=t.length;i<n;++i)e=e.flatMap((e=>e.pop().map((([t,i])=>[...e,t,i]))));return e}function l(e,t,...i){return d(e,Array.from,t,i)}function c(e){if(1!==e.length)throw new Error("duplicate key");return e[0]}function d(e,t,i,n){return function e(r,a){if(a>=n.length)return i(r);const s=new o.InternMap,l=n[a++];let c=-1;for(const e of r){const t=l(e,++c,r),i=s.get(t);i?i.push(e):s.set(t,[e])}for(const[t,i]of s)s.set(t,e(i,a));return t(s)}(e,0)}},24908:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,i){return(2!==t.length?(0,r.default)((0,o.rollup)(e,t,i),(([e,t],[i,o])=>(0,n.default)(t,o)||(0,n.default)(e,i))):(0,r.default)((0,o.default)(e,i),(([e,i],[o,r])=>t(i,r)||(0,n.default)(e,o)))).map((([e])=>e))};var n=s(i(57114)),o=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=a(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var s=o?Object.getOwnPropertyDescriptor(e,r):null;s&&(s.get||s.set)?Object.defineProperty(n,r,s):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}(i(90212)),r=s(i(66842));function a(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(a=function(e){return e?i:t})(e)}function s(e){return e&&e.__esModule?e:{default:e}}},23674:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return e}},55754:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"Adder",{enumerable:!0,get:function(){return h.Adder}}),Object.defineProperty(t,"InternMap",{enumerable:!0,get:function(){return oe.InternMap}}),Object.defineProperty(t,"InternSet",{enumerable:!0,get:function(){return oe.InternSet}}),Object.defineProperty(t,"ascending",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(t,"bin",{enumerable:!0,get:function(){return f.default}}),Object.defineProperty(t,"bisect",{enumerable:!0,get:function(){return n.default}}),Object.defineProperty(t,"bisectCenter",{enumerable:!0,get:function(){return n.bisectCenter}}),Object.defineProperty(t,"bisectLeft",{enumerable:!0,get:function(){return n.bisectLeft}}),Object.defineProperty(t,"bisectRight",{enumerable:!0,get:function(){return n.bisectRight}}),Object.defineProperty(t,"bisector",{enumerable:!0,get:function(){return r.default}}),Object.defineProperty(t,"count",{enumerable:!0,get:function(){return a.default}}),Object.defineProperty(t,"cross",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(t,"cumsum",{enumerable:!0,get:function(){return l.default}}),Object.defineProperty(t,"descending",{enumerable:!0,get:function(){return c.default}}),Object.defineProperty(t,"deviation",{enumerable:!0,get:function(){return d.default}}),Object.defineProperty(t,"difference",{enumerable:!0,get:function(){return J.default}}),Object.defineProperty(t,"disjoint",{enumerable:!0,get:function(){return Q.default}}),Object.defineProperty(t,"every",{enumerable:!0,get:function(){return j.default}}),Object.defineProperty(t,"extent",{enumerable:!0,get:function(){return u.default}}),Object.defineProperty(t,"fcumsum",{enumerable:!0,get:function(){return h.fcumsum}}),Object.defineProperty(t,"filter",{enumerable:!0,get:function(){return W.default}}),Object.defineProperty(t,"flatGroup",{enumerable:!0,get:function(){return p.flatGroup}}),Object.defineProperty(t,"flatRollup",{enumerable:!0,get:function(){return p.flatRollup}}),Object.defineProperty(t,"fsum",{enumerable:!0,get:function(){return h.fsum}}),Object.defineProperty(t,"greatest",{enumerable:!0,get:function(){return L.default}}),Object.defineProperty(t,"greatestIndex",{enumerable:!0,get:function(){return B.default}}),Object.defineProperty(t,"group",{enumerable:!0,get:function(){return p.default}}),Object.defineProperty(t,"groupSort",{enumerable:!0,get:function(){return g.default}}),Object.defineProperty(t,"groups",{enumerable:!0,get:function(){return p.groups}}),Object.defineProperty(t,"histogram",{enumerable:!0,get:function(){return f.default}}),Object.defineProperty(t,"index",{enumerable:!0,get:function(){return p.index}}),Object.defineProperty(t,"indexes",{enumerable:!0,get:function(){return p.indexes}}),Object.defineProperty(t,"intersection",{enumerable:!0,get:function(){return ee.default}}),Object.defineProperty(t,"least",{enumerable:!0,get:function(){return R.default}}),Object.defineProperty(t,"leastIndex",{enumerable:!0,get:function(){return M.default}}),Object.defineProperty(t,"map",{enumerable:!0,get:function(){return K.default}}),Object.defineProperty(t,"max",{enumerable:!0,get:function(){return C.default}}),Object.defineProperty(t,"maxIndex",{enumerable:!0,get:function(){return b.default}}),Object.defineProperty(t,"mean",{enumerable:!0,get:function(){return S.default}}),Object.defineProperty(t,"median",{enumerable:!0,get:function(){return x.default}}),Object.defineProperty(t,"merge",{enumerable:!0,get:function(){return T.default}}),Object.defineProperty(t,"min",{enumerable:!0,get:function(){return w.default}}),Object.defineProperty(t,"minIndex",{enumerable:!0,get:function(){return O.default}}),Object.defineProperty(t,"mode",{enumerable:!0,get:function(){return P.default}}),Object.defineProperty(t,"nice",{enumerable:!0,get:function(){return A.default}}),Object.defineProperty(t,"pairs",{enumerable:!0,get:function(){return E.default}}),Object.defineProperty(t,"permute",{enumerable:!0,get:function(){return k.default}}),Object.defineProperty(t,"quantile",{enumerable:!0,get:function(){return I.default}}),Object.defineProperty(t,"quantileSorted",{enumerable:!0,get:function(){return I.quantileSorted}}),Object.defineProperty(t,"quickselect",{enumerable:!0,get:function(){return D.default}}),Object.defineProperty(t,"range",{enumerable:!0,get:function(){return _.default}}),Object.defineProperty(t,"rank",{enumerable:!0,get:function(){return N.default}}),Object.defineProperty(t,"reduce",{enumerable:!0,get:function(){return q.default}}),Object.defineProperty(t,"reverse",{enumerable:!0,get:function(){return Y.default}}),Object.defineProperty(t,"rollup",{enumerable:!0,get:function(){return p.rollup}}),Object.defineProperty(t,"rollups",{enumerable:!0,get:function(){return p.rollups}}),Object.defineProperty(t,"scan",{enumerable:!0,get:function(){return F.default}}),Object.defineProperty(t,"shuffle",{enumerable:!0,get:function(){return U.default}}),Object.defineProperty(t,"shuffler",{enumerable:!0,get:function(){return U.shuffler}}),Object.defineProperty(t,"some",{enumerable:!0,get:function(){return z.default}}),Object.defineProperty(t,"sort",{enumerable:!0,get:function(){return X.default}}),Object.defineProperty(t,"subset",{enumerable:!0,get:function(){return te.default}}),Object.defineProperty(t,"sum",{enumerable:!0,get:function(){return H.default}}),Object.defineProperty(t,"superset",{enumerable:!0,get:function(){return ie.default}}),Object.defineProperty(t,"thresholdFreedmanDiaconis",{enumerable:!0,get:function(){return m.default}}),Object.defineProperty(t,"thresholdScott",{enumerable:!0,get:function(){return v.default}}),Object.defineProperty(t,"thresholdSturges",{enumerable:!0,get:function(){return y.default}}),Object.defineProperty(t,"tickIncrement",{enumerable:!0,get:function(){return $.tickIncrement}}),Object.defineProperty(t,"tickStep",{enumerable:!0,get:function(){return $.tickStep}}),Object.defineProperty(t,"ticks",{enumerable:!0,get:function(){return $.default}}),Object.defineProperty(t,"transpose",{enumerable:!0,get:function(){return Z.default}}),Object.defineProperty(t,"union",{enumerable:!0,get:function(){return ne.default}}),Object.defineProperty(t,"variance",{enumerable:!0,get:function(){return V.default}}),Object.defineProperty(t,"zip",{enumerable:!0,get:function(){return G.default}});var n=se(i(63208)),o=re(i(57114)),r=re(i(97091)),a=re(i(2503)),s=re(i(66015)),l=re(i(32892)),c=re(i(31946)),d=re(i(11041)),u=re(i(17820)),h=i(99415),p=se(i(90212)),g=re(i(24908)),f=re(i(84801)),m=re(i(23675)),v=re(i(57567)),y=re(i(93390)),C=re(i(37315)),b=re(i(26523)),S=re(i(22629)),x=re(i(49658)),T=re(i(57079)),w=re(i(26586)),O=re(i(7196)),P=re(i(82966)),A=re(i(60532)),E=re(i(17832)),k=re(i(28009)),I=se(i(90291)),D=re(i(52293)),_=re(i(1323)),N=re(i(73373)),R=re(i(97239)),M=re(i(82698)),L=re(i(22662)),B=re(i(66264)),F=re(i(38087)),U=se(i(20595)),H=re(i(6298)),$=se(i(98794)),Z=re(i(97343)),V=re(i(14492)),G=re(i(23576)),j=re(i(19222)),z=re(i(37927)),W=re(i(25024)),K=re(i(63396)),q=re(i(56924)),Y=re(i(9391)),X=re(i(66842)),J=re(i(64099)),Q=re(i(14179)),ee=re(i(14112)),te=re(i(14242)),ie=re(i(99773)),ne=re(i(9444)),oe=i(58913);function re(e){return e&&e.__esModule?e:{default:e}}function ae(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(ae=function(e){return e?i:t})(e)}function se(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=ae(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}},14112:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,...t){e=new n.InternSet(e),t=t.map(o);e:for(const i of e)for(const n of t)if(!n.has(i)){e.delete(i);continue e}return e};var n=i(58913);function o(e){return e instanceof n.InternSet?e:new n.InternSet(e)}},97239:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t=o.default){let i,n=!1;if(1===t.length){let r;for(const a of e){const e=t(a);(n?(0,o.default)(e,r)<0:0===(0,o.default)(e,e))&&(i=a,r=e,n=!0)}}else for(const o of e)(n?t(o,i)<0:0===t(o,o))&&(i=o,n=!0);return i};var n,o=(n=i(57114))&&n.__esModule?n:{default:n}},82698:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t=n.default){if(1===t.length)return(0,o.default)(e,t);let i,r=-1,a=-1;for(const n of e)++a,(r<0?0===t(n,n):t(n,i)<0)&&(i=n,r=a);return r};var n=r(i(57114)),o=r(i(7196));function r(e){return e&&e.__esModule?e:{default:e}}},63396:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if("function"!=typeof e[Symbol.iterator])throw new TypeError("values is not iterable");if("function"!=typeof t)throw new TypeError("mapper is not a function");return Array.from(e,((i,n)=>t(i,n,e)))}},37315:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){let i;if(void 0===t)for(const t of e)null!=t&&(i<t||void 0===i&&t>=t)&&(i=t);else{let n=-1;for(let o of e)null!=(o=t(o,++n,e))&&(i<o||void 0===i&&o>=o)&&(i=o)}return i}},26523:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){let i,n=-1,o=-1;if(void 0===t)for(const t of e)++o,null!=t&&(i<t||void 0===i&&t>=t)&&(i=t,n=o);else for(let r of e)null!=(r=t(r,++o,e))&&(i<r||void 0===i&&r>=r)&&(i=r,n=o);return n}},22629:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){let i=0,n=0;if(void 0===t)for(let t of e)null!=t&&(t=+t)>=t&&(++i,n+=t);else{let o=-1;for(let r of e)null!=(r=t(r,++o,e))&&(r=+r)>=r&&(++i,n+=r)}if(i)return n/i}},49658:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){return(0,o.default)(e,.5,t)};var n,o=(n=i(90291))&&n.__esModule?n:{default:n}},57079:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return Array.from(function*(e){for(const t of e)yield*t}(e))}},26586:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){let i;if(void 0===t)for(const t of e)null!=t&&(i>t||void 0===i&&t>=t)&&(i=t);else{let n=-1;for(let o of e)null!=(o=t(o,++n,e))&&(i>o||void 0===i&&o>=o)&&(i=o)}return i}},7196:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){let i,n=-1,o=-1;if(void 0===t)for(const t of e)++o,null!=t&&(i>t||void 0===i&&t>=t)&&(i=t,n=o);else for(let r of e)null!=(r=t(r,++o,e))&&(i>r||void 0===i&&r>=r)&&(i=r,n=o);return n}},82966:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){const i=new n.InternMap;if(void 0===t)for(let t of e)null!=t&&t>=t&&i.set(t,(i.get(t)||0)+1);else{let n=-1;for(let o of e)null!=(o=t(o,++n,e))&&o>=o&&i.set(o,(i.get(o)||0)+1)}let o,r=0;for(const[e,t]of i)t>r&&(r=t,o=e);return o};var n=i(58913)},60532:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,i){let o;for(;;){const r=(0,n.tickIncrement)(e,t,i);if(r===o||0===r||!isFinite(r))return[e,t];r>0?(e=Math.floor(e/r)*r,t=Math.ceil(t/r)*r):r<0&&(e=Math.ceil(e*r)/r,t=Math.floor(t*r)/r),o=r}};var n=i(98794)},77785:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return null===e?NaN:+e},t.numbers=function*(e,t){if(void 0===t)for(let t of e)null!=t&&(t=+t)>=t&&(yield t);else{let i=-1;for(let n of e)null!=(n=t(n,++i,e))&&(n=+n)>=n&&(yield n)}}},17832:function(e,t){"use strict";function i(e,t){return[e,t]}Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t=i){const n=[];let o,r=!1;for(const i of e)r&&n.push(t(o,i)),o=i,r=!0;return n},t.pair=i},28009:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){return Array.from(t,(t=>e[t]))}},90291:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,i){if(s=(e=Float64Array.from((0,a.numbers)(e,i))).length){if((t=+t)<=0||s<2)return(0,o.default)(e);if(t>=1)return(0,n.default)(e);var s,l=(s-1)*t,c=Math.floor(l),d=(0,n.default)((0,r.default)(e,c).subarray(0,c+1));return d+((0,o.default)(e.subarray(c+1))-d)*(l-c)}},t.quantileSorted=function(e,t,i=a.default){if(n=e.length){if((t=+t)<=0||n<2)return+i(e[0],0,e);if(t>=1)return+i(e[n-1],n-1,e);var n,o=(n-1)*t,r=Math.floor(o),s=+i(e[r],r,e);return s+(+i(e[r+1],r+1,e)-s)*(o-r)}};var n=l(i(37315)),o=l(i(26586)),r=l(i(52293)),a=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=s(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}(i(77785));function s(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(s=function(e){return e?i:t})(e)}function l(e){return e&&e.__esModule?e:{default:e}}},52293:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(t,i,r=0,a=t.length-1,s){for(s=void 0===s?n.ascendingDefined:(0,n.compareDefined)(s);a>r;){if(a-r>600){const n=a-r+1,o=i-r+1,l=Math.log(n),c=.5*Math.exp(2*l/3),d=.5*Math.sqrt(l*c*(n-c)/n)*(o-n/2<0?-1:1);e(t,i,Math.max(r,Math.floor(i-o*c/n+d)),Math.min(a,Math.floor(i+(n-o)*c/n+d)),s)}const n=t[i];let l=r,c=a;for(o(t,r,i),s(t[a],n)>0&&o(t,r,a);l<c;){for(o(t,l,c),++l,--c;s(t[l],n)<0;)++l;for(;s(t[c],n)>0;)--c}0===s(t[r],n)?o(t,r,c):(++c,o(t,c,a)),c<=i&&(r=c+1),i<=c&&(a=c-1)}return t};var n=i(66842);function o(e,t,i){const n=e[t];e[t]=e[i],e[i]=n}},1323:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,i){e=+e,t=+t,i=(o=arguments.length)<2?(t=e,e=0,1):o<3?1:+i;for(var n=-1,o=0|Math.max(0,Math.ceil((t-e)/i)),r=new Array(o);++n<o;)r[n]=e+n*i;return r}},73373:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t=o.default){if("function"!=typeof e[Symbol.iterator])throw new TypeError("values is not iterable");let i=Array.from(e);const n=new Float64Array(i.length);2!==t.length&&(i=i.map(t),t=o.default);const a=(e,n)=>t(i[e],i[n]);let s,l;return Uint32Array.from(i,((e,t)=>t)).sort(t===o.default?(e,t)=>(0,r.ascendingDefined)(i[e],i[t]):(0,r.compareDefined)(a)).forEach(((e,t)=>{const i=a(e,void 0===s?e:s);i>=0?((void 0===s||i>0)&&(s=e,l=t),n[e]=l):n[e]=NaN})),n};var n,o=(n=i(57114))&&n.__esModule?n:{default:n},r=i(66842)},56924:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,i){if("function"!=typeof t)throw new TypeError("reducer is not a function");const n=e[Symbol.iterator]();let o,r,a=-1;if(arguments.length<3){if(({done:o,value:i}=n.next()),o)return;++a}for(;({done:o,value:r}=n.next()),!o;)i=t(i,r,++a,e);return i}},9391:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){if("function"!=typeof e[Symbol.iterator])throw new TypeError("values is not iterable");return Array.from(e).reverse()}},38087:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){const i=(0,o.default)(e,t);return i<0?void 0:i};var n,o=(n=i(82698))&&n.__esModule?n:{default:n}},20595:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0,t.shuffler=n;var i=n(Math.random);function n(e){return function(t,i=0,n=t.length){let o=n-(i=+i);for(;o;){const n=e()*o--|0,r=t[o+i];t[o+i]=t[n+i],t[n+i]=r}return t}}t.default=i},37927:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if("function"!=typeof t)throw new TypeError("test is not a function");let i=-1;for(const n of e)if(t(n,++i,e))return!0;return!1}},66842:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ascendingDefined=s,t.compareDefined=a,t.default=function(e,...t){if("function"!=typeof e[Symbol.iterator])throw new TypeError("values is not iterable");e=Array.from(e);let[i]=t;if(i&&2!==i.length||t.length>1){const n=Uint32Array.from(e,((e,t)=>t));return t.length>1?(t=t.map((t=>e.map(t))),n.sort(((e,i)=>{for(const n of t){const t=s(n[e],n[i]);if(t)return t}}))):(i=e.map(i),n.sort(((e,t)=>s(i[e],i[t])))),(0,o.default)(e,n)}return e.sort(a(i))};var n=r(i(57114)),o=r(i(28009));function r(e){return e&&e.__esModule?e:{default:e}}function a(e=n.default){if(e===n.default)return s;if("function"!=typeof e)throw new TypeError("compare is not a function");return(t,i)=>{const n=e(t,i);return n||0===n?n:(0===e(i,i))-(0===e(t,t))}}function s(e,t){return(null==e||!(e>=e))-(null==t||!(t>=t))||(e<t?-1:e>t?1:0)}},14242:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){return(0,o.default)(t,e)};var n,o=(n=i(99773))&&n.__esModule?n:{default:n}},6298:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){let i=0;if(void 0===t)for(let t of e)(t=+t)&&(i+=t);else{let n=-1;for(let o of e)(o=+t(o,++n,e))&&(i+=o)}return i}},99773:function(e,t){"use strict";function i(e){return null!==e&&"object"==typeof e?e.valueOf():e}Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){const n=e[Symbol.iterator](),o=new Set;for(const e of t){const t=i(e);if(o.has(t))continue;let r,a;for(;({value:r,done:a}=n.next());){if(a)return!1;const e=i(r);if(o.add(e),Object.is(t,e))break}}return!0}},23675:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,i){return Math.ceil((i-t)/(2*((0,o.default)(e,.75)-(0,o.default)(e,.25))*Math.pow((0,n.default)(e),-1/3)))};var n=r(i(2503)),o=r(i(90291));function r(e){return e&&e.__esModule?e:{default:e}}},57567:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,i){return Math.ceil((i-t)*Math.cbrt((0,n.default)(e))/(3.49*(0,o.default)(e)))};var n=r(i(2503)),o=r(i(11041));function r(e){return e&&e.__esModule?e:{default:e}}},93390:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return Math.ceil(Math.log((0,o.default)(e))/Math.LN2)+1};var n,o=(n=i(2503))&&n.__esModule?n:{default:n}},98794:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,i){var n,o,a,s,l=-1;if(i=+i,(e=+e)==(t=+t)&&i>0)return[e];if((n=t<e)&&(o=e,e=t,t=o),0===(s=r(e,t,i))||!isFinite(s))return[];if(s>0){let i=Math.round(e/s),n=Math.round(t/s);for(i*s<e&&++i,n*s>t&&--n,a=new Array(o=n-i+1);++l<o;)a[l]=(i+l)*s}else{s=-s;let i=Math.round(e*s),n=Math.round(t*s);for(i/s<e&&++i,n/s>t&&--n,a=new Array(o=n-i+1);++l<o;)a[l]=(i+l)/s}return n&&a.reverse(),a},t.tickIncrement=r,t.tickStep=function(e,t,r){var a=Math.abs(t-e)/Math.max(0,r),s=Math.pow(10,Math.floor(Math.log(a)/Math.LN10)),l=a/s;return l>=i?s*=10:l>=n?s*=5:l>=o&&(s*=2),t<e?-s:s};var i=Math.sqrt(50),n=Math.sqrt(10),o=Math.sqrt(2);function r(e,t,r){var a=(t-e)/Math.max(0,r),s=Math.floor(Math.log(a)/Math.LN10),l=a/Math.pow(10,s);return s>=0?(l>=i?10:l>=n?5:l>=o?2:1)*Math.pow(10,s):-Math.pow(10,-s)/(l>=i?10:l>=n?5:l>=o?2:1)}},97343:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){if(!(a=e.length))return[];for(var t=-1,i=(0,o.default)(e,r),n=new Array(i);++t<i;)for(var a,s=-1,l=n[t]=new Array(a);++s<a;)l[s]=e[s][t];return n};var n,o=(n=i(26586))&&n.__esModule?n:{default:n};function r(e){return e.length}},9444:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(...e){const t=new n.InternSet;for(const i of e)for(const e of i)t.add(e);return t};var n=i(58913)},14492:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){let i,n=0,o=0,r=0;if(void 0===t)for(let t of e)null!=t&&(t=+t)>=t&&(i=t-o,o+=i/++n,r+=i*(t-o));else{let a=-1;for(let s of e)null!=(s=t(s,++a,e))&&(s=+s)>=s&&(i=s-o,o+=i/++n,r+=i*(s-o))}if(n>1)return r/(n-1)}},23576:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){return(0,o.default)(arguments)};var n,o=(n=i(97343))&&n.__esModule?n:{default:n}},14358:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Color=r,t.Rgb=P,t.darker=t.brighter=void 0,t.default=S,t.hsl=R,t.hslConvert=N,t.rgb=O,t.rgbConvert=w;var n=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=o(t);if(i&&i.has(e))return i.get(e);var n={},r=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if("default"!==a&&Object.prototype.hasOwnProperty.call(e,a)){var s=r?Object.getOwnPropertyDescriptor(e,a):null;s&&(s.get||s.set)?Object.defineProperty(n,a,s):n[a]=e[a]}return n.default=e,i&&i.set(e,n),n}(i(93715));function o(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(o=function(e){return e?i:t})(e)}function r(){}var a=.7;t.darker=a;var s=1/a;t.brighter=s;var l="\\s*([+-]?\\d+)\\s*",c="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",d="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",u=/^#([0-9a-f]{3,8})$/,h=new RegExp(`^rgb\\(${l},${l},${l}\\)$`),p=new RegExp(`^rgb\\(${d},${d},${d}\\)$`),g=new RegExp(`^rgba\\(${l},${l},${l},${c}\\)$`),f=new RegExp(`^rgba\\(${d},${d},${d},${c}\\)$`),m=new RegExp(`^hsl\\(${c},${d},${d}\\)$`),v=new RegExp(`^hsla\\(${c},${d},${d},${c}\\)$`),y={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function C(){return this.rgb().formatHex()}function b(){return this.rgb().formatRgb()}function S(e){var t,i;return e=(e+"").trim().toLowerCase(),(t=u.exec(e))?(i=t[1].length,t=parseInt(t[1],16),6===i?x(t):3===i?new P(t>>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===i?T(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===i?T(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|240&t,((15&t)<<4|15&t)/255):null):(t=h.exec(e))?new P(t[1],t[2],t[3],1):(t=p.exec(e))?new P(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=g.exec(e))?T(t[1],t[2],t[3],t[4]):(t=f.exec(e))?T(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=m.exec(e))?_(t[1],t[2]/100,t[3]/100,1):(t=v.exec(e))?_(t[1],t[2]/100,t[3]/100,t[4]):y.hasOwnProperty(e)?x(y[e]):"transparent"===e?new P(NaN,NaN,NaN,0):null}function x(e){return new P(e>>16&255,e>>8&255,255&e,1)}function T(e,t,i,n){return n<=0&&(e=t=i=NaN),new P(e,t,i,n)}function w(e){return e instanceof r||(e=S(e)),e?new P((e=e.rgb()).r,e.g,e.b,e.opacity):new P}function O(e,t,i,n){return 1===arguments.length?w(e):new P(e,t,i,null==n?1:n)}function P(e,t,i,n){this.r=+e,this.g=+t,this.b=+i,this.opacity=+n}function A(){return`#${D(this.r)}${D(this.g)}${D(this.b)}`}function E(){const e=k(this.opacity);return`${1===e?"rgb(":"rgba("}${I(this.r)}, ${I(this.g)}, ${I(this.b)}${1===e?")":`, ${e})`}`}function k(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function I(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function D(e){return((e=I(e))<16?"0":"")+e.toString(16)}function _(e,t,i,n){return n<=0?e=t=i=NaN:i<=0||i>=1?e=t=NaN:t<=0&&(e=NaN),new M(e,t,i,n)}function N(e){if(e instanceof M)return new M(e.h,e.s,e.l,e.opacity);if(e instanceof r||(e=S(e)),!e)return new M;if(e instanceof M)return e;var t=(e=e.rgb()).r/255,i=e.g/255,n=e.b/255,o=Math.min(t,i,n),a=Math.max(t,i,n),s=NaN,l=a-o,c=(a+o)/2;return l?(s=t===a?(i-n)/l+6*(i<n):i===a?(n-t)/l+2:(t-i)/l+4,l/=c<.5?a+o:2-a-o,s*=60):l=c>0&&c<1?0:s,new M(s,l,c,e.opacity)}function R(e,t,i,n){return 1===arguments.length?N(e):new M(e,t,i,null==n?1:n)}function M(e,t,i,n){this.h=+e,this.s=+t,this.l=+i,this.opacity=+n}function L(e){return(e=(e||0)%360)<0?e+360:e}function B(e){return Math.max(0,Math.min(1,e||0))}function F(e,t,i){return 255*(e<60?t+(i-t)*e/60:e<180?i:e<240?t+(i-t)*(240-e)/60:t)}(0,n.default)(r,S,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:C,formatHex:C,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return N(this).formatHsl()},formatRgb:b,toString:b}),(0,n.default)(P,O,(0,n.extend)(r,{brighter(e){return e=null==e?s:Math.pow(s,e),new P(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=null==e?a:Math.pow(a,e),new P(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new P(I(this.r),I(this.g),I(this.b),k(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:A,formatHex:A,formatHex8:function(){return`#${D(this.r)}${D(this.g)}${D(this.b)}${D(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:E,toString:E})),(0,n.default)(M,R,(0,n.extend)(r,{brighter(e){return e=null==e?s:Math.pow(s,e),new M(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=null==e?a:Math.pow(a,e),new M(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+360*(this.h<0),t=isNaN(e)||isNaN(this.s)?0:this.s,i=this.l,n=i+(i<.5?i:1-i)*t,o=2*i-n;return new P(F(e>=240?e-240:e+120,o,n),F(e,o,n),F(e<120?e+240:e-120,o,n),this.opacity)},clamp(){return new M(L(this.h),B(this.s),B(this.l),k(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=k(this.opacity);return`${1===e?"hsl(":"hsla("}${L(this.h)}, ${100*B(this.s)}%, ${100*B(this.l)}%${1===e?")":`, ${e})`}`}}))},88458:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Cubehelix=m,t.default=f;var n=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=a(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var s=o?Object.getOwnPropertyDescriptor(e,r):null;s&&(s.get||s.set)?Object.defineProperty(n,r,s):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}(i(93715)),o=i(14358),r=i(57737);function a(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(a=function(e){return e?i:t})(e)}var s=-.14861,l=1.78277,c=-.29227,d=-.90649,u=1.97294,h=u*d,p=u*l,g=l*c-d*s;function f(e,t,i,n){return 1===arguments.length?function(e){if(e instanceof m)return new m(e.h,e.s,e.l,e.opacity);e instanceof o.Rgb||(e=(0,o.rgbConvert)(e));var t=e.r/255,i=e.g/255,n=e.b/255,a=(g*n+h*t-p*i)/(g+h-p),s=n-a,l=(u*(i-a)-c*s)/d,f=Math.sqrt(l*l+s*s)/(u*a*(1-a)),v=f?Math.atan2(l,s)*r.degrees-120:NaN;return new m(v<0?v+360:v,f,a,e.opacity)}(e):new m(e,t,i,null==n?1:n)}function m(e,t,i,n){this.h=+e,this.s=+t,this.l=+i,this.opacity=+n}(0,n.default)(m,f,(0,n.extend)(o.Color,{brighter(e){return e=null==e?o.brighter:Math.pow(o.brighter,e),new m(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=null==e?o.darker:Math.pow(o.darker,e),new m(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=isNaN(this.h)?0:(this.h+120)*r.radians,t=+this.l,i=isNaN(this.s)?0:this.s*t*(1-t),n=Math.cos(e),a=Math.sin(e);return new o.Rgb(255*(t+i*(s*n+l*a)),255*(t+i*(c*n+d*a)),255*(t+i*(u*n)),this.opacity)}}))},93715:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,i){e.prototype=t.prototype=i,i.constructor=e},t.extend=function(e,t){var i=Object.create(e.prototype);for(var n in t)i[n]=t[n];return i}},62748:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"color",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(t,"cubehelix",{enumerable:!0,get:function(){return a.default}}),Object.defineProperty(t,"gray",{enumerable:!0,get:function(){return r.gray}}),Object.defineProperty(t,"hcl",{enumerable:!0,get:function(){return r.hcl}}),Object.defineProperty(t,"hsl",{enumerable:!0,get:function(){return o.hsl}}),Object.defineProperty(t,"lab",{enumerable:!0,get:function(){return r.default}}),Object.defineProperty(t,"lch",{enumerable:!0,get:function(){return r.lch}}),Object.defineProperty(t,"rgb",{enumerable:!0,get:function(){return o.rgb}});var n,o=l(i(14358)),r=l(i(53856)),a=(n=i(88458))&&n.__esModule?n:{default:n};function s(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(s=function(e){return e?i:t})(e)}function l(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=s(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}},53856:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Hcl=T,t.Lab=m,t.default=f,t.gray=function(e,t){return new m(e,0,0,null==t?1:t)},t.hcl=x,t.lch=function(e,t,i,n){return 1===arguments.length?S(e):new T(i,t,e,null==n?1:n)};var n=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=a(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var s=o?Object.getOwnPropertyDescriptor(e,r):null;s&&(s.get||s.set)?Object.defineProperty(n,r,s):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}(i(93715)),o=i(14358),r=i(57737);function a(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(a=function(e){return e?i:t})(e)}const s=.96422,l=1,c=.82521,d=4/29,u=6/29,h=3*u*u,p=u*u*u;function g(e){if(e instanceof m)return new m(e.l,e.a,e.b,e.opacity);if(e instanceof T)return w(e);e instanceof o.Rgb||(e=(0,o.rgbConvert)(e));var t,i,n=b(e.r),r=b(e.g),a=b(e.b),d=v((.2225045*n+.7168786*r+.0606169*a)/l);return n===r&&r===a?t=i=d:(t=v((.4360747*n+.3850649*r+.1430804*a)/s),i=v((.0139322*n+.0971045*r+.7141733*a)/c)),new m(116*d-16,500*(t-d),200*(d-i),e.opacity)}function f(e,t,i,n){return 1===arguments.length?g(e):new m(e,t,i,null==n?1:n)}function m(e,t,i,n){this.l=+e,this.a=+t,this.b=+i,this.opacity=+n}function v(e){return e>p?Math.pow(e,1/3):e/h+d}function y(e){return e>u?e*e*e:h*(e-d)}function C(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function b(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function S(e){if(e instanceof T)return new T(e.h,e.c,e.l,e.opacity);if(e instanceof m||(e=g(e)),0===e.a&&0===e.b)return new T(NaN,0<e.l&&e.l<100?0:NaN,e.l,e.opacity);var t=Math.atan2(e.b,e.a)*r.degrees;return new T(t<0?t+360:t,Math.sqrt(e.a*e.a+e.b*e.b),e.l,e.opacity)}function x(e,t,i,n){return 1===arguments.length?S(e):new T(e,t,i,null==n?1:n)}function T(e,t,i,n){this.h=+e,this.c=+t,this.l=+i,this.opacity=+n}function w(e){if(isNaN(e.h))return new m(e.l,0,0,e.opacity);var t=e.h*r.radians;return new m(e.l,Math.cos(t)*e.c,Math.sin(t)*e.c,e.opacity)}(0,n.default)(m,f,(0,n.extend)(o.Color,{brighter(e){return new m(this.l+18*(null==e?1:e),this.a,this.b,this.opacity)},darker(e){return new m(this.l-18*(null==e?1:e),this.a,this.b,this.opacity)},rgb(){var e=(this.l+16)/116,t=isNaN(this.a)?e:e+this.a/500,i=isNaN(this.b)?e:e-this.b/200;return t=s*y(t),e=l*y(e),i=c*y(i),new o.Rgb(C(3.1338561*t-1.6168667*e-.4906146*i),C(-.9787684*t+1.9161415*e+.033454*i),C(.0719453*t-.2289914*e+1.4052427*i),this.opacity)}})),(0,n.default)(T,x,(0,n.extend)(o.Color,{brighter(e){return new T(this.h,this.c,this.l+18*(null==e?1:e),this.opacity)},darker(e){return new T(this.h,this.c,this.l-18*(null==e?1:e),this.opacity)},rgb(){return w(this).rgb()}}))},57737:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.radians=t.degrees=void 0;const i=Math.PI/180;t.radians=i;const n=180/Math.PI;t.degrees=n},60848:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=l,t.formatPrefix=t.format=void 0;var n,o,r,a,s=(n=i(85841))&&n.__esModule?n:{default:n};function l(e){return o=(0,s.default)(e),t.format=r=o.format,t.formatPrefix=a=o.formatPrefix,o}t.format=r,t.formatPrefix=a,l({thousands:",",grouping:[3],currency:["$",""]})},17404:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return(e=(0,n.formatDecimalParts)(Math.abs(e)))?e[1]:NaN};var n=i(18957)},18957:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)},t.formatDecimalParts=function(e,t){if((i=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var i,n=e.slice(0,i);return[n.length>1?n[0]+n.slice(2):n,+e.slice(i+1)]}},32187:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){return function(i,n){for(var o=i.length,r=[],a=0,s=e[0],l=0;o>0&&s>0&&(l+s+1>n&&(s=Math.max(1,n-l)),r.push(i.substring(o-=s,o+s)),!((l+=s+1)>n));)s=e[a=(a+1)%e.length];return r.reverse().join(t)}}},72550:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return function(t){return t.replace(/[0-9]/g,(function(t){return e[+t]}))}}},5219:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,i){var r=(0,o.formatDecimalParts)(e,i);if(!r)return e+"";var a=r[0],s=r[1],l=s-(t.prefixExponent=n=3*Math.max(-8,Math.min(8,Math.floor(s/3))))+1,c=a.length;return l===c?a:l>c?a+new Array(l-c+1).join("0"):l>0?a.slice(0,l)+"."+a.slice(l):"0."+new Array(1-l).join("0")+(0,o.formatDecimalParts)(e,Math.max(0,i+l-1))[0]},t.prefixExponent=void 0;var n,o=i(18957);t.prefixExponent=n},84557:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var i=(0,n.formatDecimalParts)(e,t);if(!i)return e+"";var o=i[0],r=i[1];return r<0?"0."+new Array(-r).join("0")+o:o.length>r+1?o.slice(0,r+1)+"."+o.slice(r+1):o+new Array(r-o.length+2).join("0")};var n=i(18957)},46787:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FormatSpecifier=o,t.default=n;var i=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function n(e){if(!(t=i.exec(e)))throw new Error("invalid format: "+e);var t;return new o({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}function o(e){this.fill=void 0===e.fill?" ":e.fill+"",this.align=void 0===e.align?">":e.align+"",this.sign=void 0===e.sign?"-":e.sign+"",this.symbol=void 0===e.symbol?"":e.symbol+"",this.zero=!!e.zero,this.width=void 0===e.width?void 0:+e.width,this.comma=!!e.comma,this.precision=void 0===e.precision?void 0:+e.precision,this.trim=!!e.trim,this.type=void 0===e.type?"":e.type+""}n.prototype=o.prototype,o.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type}},72258:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){e:for(var t,i=e.length,n=1,o=-1;n<i;++n)switch(e[n]){case".":o=t=n;break;case"0":0===o&&(o=n),t=n;break;default:if(!+e[n])break e;o>0&&(o=0)}return o>0?e.slice(0,o)+e.slice(t+1):e}},16606:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=a(i(18957)),o=a(i(5219)),r=a(i(84557));function a(e){return e&&e.__esModule?e:{default:e}}var s={"%":(e,t)=>(100*e).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:n.default,e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>(0,r.default)(100*e,t),r:r.default,s:o.default,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};t.default=s},67089:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return e}},79737:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"FormatSpecifier",{enumerable:!0,get:function(){return r.FormatSpecifier}}),Object.defineProperty(t,"format",{enumerable:!0,get:function(){return n.format}}),Object.defineProperty(t,"formatDefaultLocale",{enumerable:!0,get:function(){return n.default}}),Object.defineProperty(t,"formatLocale",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(t,"formatPrefix",{enumerable:!0,get:function(){return n.formatPrefix}}),Object.defineProperty(t,"formatSpecifier",{enumerable:!0,get:function(){return r.default}}),Object.defineProperty(t,"precisionFixed",{enumerable:!0,get:function(){return a.default}}),Object.defineProperty(t,"precisionPrefix",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(t,"precisionRound",{enumerable:!0,get:function(){return l.default}});var n=u(i(60848)),o=c(i(85841)),r=u(i(46787)),a=c(i(39227)),s=c(i(90171)),l=c(i(99129));function c(e){return e&&e.__esModule?e:{default:e}}function d(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(d=function(e){return e?i:t})(e)}function u(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=d(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}},85841:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=void 0===e.grouping||void 0===e.thousands?d.default:(0,o.default)(h.call(e.grouping,Number),e.thousands+""),i=void 0===e.currency?"":e.currency[0]+"",u=void 0===e.currency?"":e.currency[1]+"",g=void 0===e.decimal?".":e.decimal+"",f=void 0===e.numerals?d.default:(0,r.default)(h.call(e.numerals,String)),m=void 0===e.percent?"%":e.percent+"",v=void 0===e.minus?"−":e.minus+"",y=void 0===e.nan?"NaN":e.nan+"";function C(e){var n=(e=(0,a.default)(e)).fill,o=e.align,r=e.sign,d=e.symbol,h=e.zero,C=e.width,b=e.comma,S=e.precision,x=e.trim,T=e.type;"n"===T?(b=!0,T="g"):l.default[T]||(void 0===S&&(S=12),x=!0,T="g"),(h||"0"===n&&"="===o)&&(h=!0,n="0",o="=");var w="$"===d?i:"#"===d&&/[boxX]/.test(T)?"0"+T.toLowerCase():"",O="$"===d?u:/[%p]/.test(T)?m:"",P=l.default[T],A=/[defgprs%]/.test(T);function E(e){var i,a,l,d=w,u=O;if("c"===T)u=P(e)+u,e="";else{var m=(e=+e)<0||1/e<0;if(e=isNaN(e)?y:P(Math.abs(e),S),x&&(e=(0,s.default)(e)),m&&0==+e&&"+"!==r&&(m=!1),d=(m?"("===r?r:v:"-"===r||"("===r?"":r)+d,u=("s"===T?p[8+c.prefixExponent/3]:"")+u+(m&&"("===r?")":""),A)for(i=-1,a=e.length;++i<a;)if(48>(l=e.charCodeAt(i))||l>57){u=(46===l?g+e.slice(i+1):e.slice(i))+u,e=e.slice(0,i);break}}b&&!h&&(e=t(e,1/0));var E=d.length+e.length+u.length,k=E<C?new Array(C-E+1).join(n):"";switch(b&&h&&(e=t(k+e,k.length?C-u.length:1/0),k=""),o){case"<":e=d+e+u+k;break;case"=":e=d+k+e+u;break;case"^":e=k.slice(0,E=k.length>>1)+d+e+u+k.slice(E);break;default:e=k+d+e+u}return f(e)}return S=void 0===S?6:/[gprs]/.test(T)?Math.max(1,Math.min(21,S)):Math.max(0,Math.min(20,S)),E.toString=function(){return e+""},E}return{format:C,formatPrefix:function(e,t){var i=C(((e=(0,a.default)(e)).type="f",e)),o=3*Math.max(-8,Math.min(8,Math.floor((0,n.default)(t)/3))),r=Math.pow(10,-o),s=p[8+o/3];return function(e){return i(r*e)+s}}}};var n=u(i(17404)),o=u(i(32187)),r=u(i(72550)),a=u(i(46787)),s=u(i(72258)),l=u(i(16606)),c=i(5219),d=u(i(67089));function u(e){return e&&e.__esModule?e:{default:e}}var h=Array.prototype.map,p=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"]},39227:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return Math.max(0,-(0,o.default)(Math.abs(e)))};var n,o=(n=i(17404))&&n.__esModule?n:{default:n}},90171:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor((0,o.default)(t)/3)))-(0,o.default)(Math.abs(e)))};var n,o=(n=i(17404))&&n.__esModule?n:{default:n}},99129:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,(0,o.default)(t)-(0,o.default)(e))+1};var n,o=(n=i(17404))&&n.__esModule?n:{default:n}},45533:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){return((0,r.isNumberArray)(t)?r.default:s)(e,t)},t.genericArray=s;var n,o=(n=i(95828))&&n.__esModule?n:{default:n},r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=a(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var s=o?Object.getOwnPropertyDescriptor(e,r):null;s&&(s.get||s.set)?Object.defineProperty(n,r,s):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}(i(90250));function a(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(a=function(e){return e?i:t})(e)}function s(e,t){var i,n=t?t.length:0,r=e?Math.min(n,e.length):0,a=new Array(r),s=new Array(n);for(i=0;i<r;++i)a[i]=(0,o.default)(e[i],t[i]);for(;i<n;++i)s[i]=t[i];return function(e){for(i=0;i<r;++i)s[i]=a[i](e);return s}}},82916:function(e,t){"use strict";function i(e,t,i,n,o){var r=e*e,a=r*e;return((1-3*e+3*r-a)*t+(4-6*r+3*a)*i+(1+3*e+3*r-3*a)*n+a*o)/6}Object.defineProperty(t,"__esModule",{value:!0}),t.basis=i,t.default=function(e){var t=e.length-1;return function(n){var o=n<=0?n=0:n>=1?(n=1,t-1):Math.floor(n*t),r=e[o],a=e[o+1],s=o>0?e[o-1]:2*r-a,l=o<t-1?e[o+2]:2*a-r;return i((n-o/t)*t,s,r,a,l)}}},51663:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=e.length;return function(i){var o=Math.floor(((i%=1)<0?++i:i)*t),r=e[(o+t-1)%t],a=e[o%t],s=e[(o+1)%t],l=e[(o+2)%t];return(0,n.basis)((i-o/t)*t,r,a,s,l)}};var n=i(82916)},26694:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=a,t.gamma=function(e){return 1==(e=+e)?a:function(t,i){return i-t?function(e,t,i){return e=Math.pow(e,i),t=Math.pow(t,i)-e,i=1/i,function(n){return Math.pow(e+n*t,i)}}(t,i,e):(0,o.default)(isNaN(t)?i:t)}},t.hue=function(e,t){var i=t-e;return i?r(e,i>180||i<-180?i-360*Math.round(i/360):i):(0,o.default)(isNaN(e)?t:e)};var n,o=(n=i(32958))&&n.__esModule?n:{default:n};function r(e,t){return function(i){return e+i*t}}function a(e,t){var i=t-e;return i?r(e,i):(0,o.default)(isNaN(e)?t:e)}},32958:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0,t.default=e=>()=>e},60828:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.cubehelixLong=void 0;var n=i(62748),o=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=r(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if("default"!==a&&Object.prototype.hasOwnProperty.call(e,a)){var s=o?Object.getOwnPropertyDescriptor(e,a):null;s&&(s.get||s.set)?Object.defineProperty(n,a,s):n[a]=e[a]}return n.default=e,i&&i.set(e,n),n}(i(26694));function r(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(r=function(e){return e?i:t})(e)}function a(e){return function t(i){function r(t,r){var a=e((t=(0,n.cubehelix)(t)).h,(r=(0,n.cubehelix)(r)).h),s=(0,o.default)(t.s,r.s),l=(0,o.default)(t.l,r.l),c=(0,o.default)(t.opacity,r.opacity);return function(e){return t.h=a(e),t.s=s(e),t.l=l(Math.pow(e,i)),t.opacity=c(e),t+""}}return i=+i,r.gamma=t,r}(1)}var s=a(o.hue);t.default=s;var l=a(o.default);t.cubehelixLong=l},44204:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var i=new Date;return e=+e,t=+t,function(n){return i.setTime(e*(1-n)+t*n),i}}},34743:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=e.length;return function(i){return e[Math.max(0,Math.min(t-1,Math.floor(i*t)))]}}},64910:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hclLong=t.default=void 0;var n=i(62748),o=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=r(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if("default"!==a&&Object.prototype.hasOwnProperty.call(e,a)){var s=o?Object.getOwnPropertyDescriptor(e,a):null;s&&(s.get||s.set)?Object.defineProperty(n,a,s):n[a]=e[a]}return n.default=e,i&&i.set(e,n),n}(i(26694));function r(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(r=function(e){return e?i:t})(e)}function a(e){return function(t,i){var r=e((t=(0,n.hcl)(t)).h,(i=(0,n.hcl)(i)).h),a=(0,o.default)(t.c,i.c),s=(0,o.default)(t.l,i.l),l=(0,o.default)(t.opacity,i.opacity);return function(e){return t.h=r(e),t.c=a(e),t.l=s(e),t.opacity=l(e),t+""}}}var s=a(o.hue);t.default=s;var l=a(o.default);t.hclLong=l},78894:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hslLong=t.default=void 0;var n=i(62748),o=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=r(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if("default"!==a&&Object.prototype.hasOwnProperty.call(e,a)){var s=o?Object.getOwnPropertyDescriptor(e,a):null;s&&(s.get||s.set)?Object.defineProperty(n,a,s):n[a]=e[a]}return n.default=e,i&&i.set(e,n),n}(i(26694));function r(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(r=function(e){return e?i:t})(e)}function a(e){return function(t,i){var r=e((t=(0,n.hsl)(t)).h,(i=(0,n.hsl)(i)).h),a=(0,o.default)(t.s,i.s),s=(0,o.default)(t.l,i.l),l=(0,o.default)(t.opacity,i.opacity);return function(e){return t.h=r(e),t.s=a(e),t.l=s(e),t.opacity=l(e),t+""}}}var s=a(o.hue);t.default=s;var l=a(o.default);t.hslLong=l},45303:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var i=(0,n.hue)(+e,+t);return function(e){var t=i(e);return t-360*Math.floor(t/360)}};var n=i(26694)},65164:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"interpolate",{enumerable:!0,get:function(){return n.default}}),Object.defineProperty(t,"interpolateArray",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(t,"interpolateBasis",{enumerable:!0,get:function(){return r.default}}),Object.defineProperty(t,"interpolateBasisClosed",{enumerable:!0,get:function(){return a.default}}),Object.defineProperty(t,"interpolateCubehelix",{enumerable:!0,get:function(){return S.default}}),Object.defineProperty(t,"interpolateCubehelixLong",{enumerable:!0,get:function(){return S.cubehelixLong}}),Object.defineProperty(t,"interpolateDate",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(t,"interpolateDiscrete",{enumerable:!0,get:function(){return l.default}}),Object.defineProperty(t,"interpolateHcl",{enumerable:!0,get:function(){return b.default}}),Object.defineProperty(t,"interpolateHclLong",{enumerable:!0,get:function(){return b.hclLong}}),Object.defineProperty(t,"interpolateHsl",{enumerable:!0,get:function(){return y.default}}),Object.defineProperty(t,"interpolateHslLong",{enumerable:!0,get:function(){return y.hslLong}}),Object.defineProperty(t,"interpolateHue",{enumerable:!0,get:function(){return c.default}}),Object.defineProperty(t,"interpolateLab",{enumerable:!0,get:function(){return C.default}}),Object.defineProperty(t,"interpolateNumber",{enumerable:!0,get:function(){return d.default}}),Object.defineProperty(t,"interpolateNumberArray",{enumerable:!0,get:function(){return u.default}}),Object.defineProperty(t,"interpolateObject",{enumerable:!0,get:function(){return h.default}}),Object.defineProperty(t,"interpolateRgb",{enumerable:!0,get:function(){return v.default}}),Object.defineProperty(t,"interpolateRgbBasis",{enumerable:!0,get:function(){return v.rgbBasis}}),Object.defineProperty(t,"interpolateRgbBasisClosed",{enumerable:!0,get:function(){return v.rgbBasisClosed}}),Object.defineProperty(t,"interpolateRound",{enumerable:!0,get:function(){return p.default}}),Object.defineProperty(t,"interpolateString",{enumerable:!0,get:function(){return g.default}}),Object.defineProperty(t,"interpolateTransformCss",{enumerable:!0,get:function(){return f.interpolateTransformCss}}),Object.defineProperty(t,"interpolateTransformSvg",{enumerable:!0,get:function(){return f.interpolateTransformSvg}}),Object.defineProperty(t,"interpolateZoom",{enumerable:!0,get:function(){return m.default}}),Object.defineProperty(t,"piecewise",{enumerable:!0,get:function(){return x.default}}),Object.defineProperty(t,"quantize",{enumerable:!0,get:function(){return T.default}});var n=P(i(95828)),o=P(i(45533)),r=P(i(82916)),a=P(i(51663)),s=P(i(44204)),l=P(i(34743)),c=P(i(45303)),d=P(i(73849)),u=P(i(90250)),h=P(i(96384)),p=P(i(36965)),g=P(i(32636)),f=i(75402),m=P(i(27043)),v=O(i(56775)),y=O(i(78894)),C=P(i(16238)),b=O(i(64910)),S=O(i(60828)),x=P(i(586)),T=P(i(4962));function w(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(w=function(e){return e?i:t})(e)}function O(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=w(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}function P(e){return e&&e.__esModule?e:{default:e}}},16238:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var i=(0,r.default)((e=(0,o.lab)(e)).l,(t=(0,o.lab)(t)).l),n=(0,r.default)(e.a,t.a),a=(0,r.default)(e.b,t.b),s=(0,r.default)(e.opacity,t.opacity);return function(t){return e.l=i(t),e.a=n(t),e.b=a(t),e.opacity=s(t),e+""}};var n,o=i(62748),r=(n=i(26694))&&n.__esModule?n:{default:n}},73849:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){return e=+e,t=+t,function(i){return e*(1-i)+t*i}}},90250:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){t||(t=[]);var i,n=e?Math.min(t.length,e.length):0,o=t.slice();return function(r){for(i=0;i<n;++i)o[i]=e[i]*(1-r)+t[i]*r;return o}},t.isNumberArray=function(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}},96384:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var i,n={},r={};for(i in null!==e&&"object"==typeof e||(e={}),null!==t&&"object"==typeof t||(t={}),t)i in e?n[i]=(0,o.default)(e[i],t[i]):r[i]=t[i];return function(e){for(i in n)r[i]=n[i](e);return r}};var n,o=(n=i(95828))&&n.__esModule?n:{default:n}},586:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){void 0===t&&(t=e,e=o.default);for(var i=0,n=t.length-1,r=t[0],a=new Array(n<0?0:n);i<n;)a[i]=e(r,r=t[++i]);return function(e){var t=Math.max(0,Math.min(n-1,Math.floor(e*=n)));return a[t](e-t)}};var n,o=(n=i(95828))&&n.__esModule?n:{default:n}},4962:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){for(var i=new Array(t),n=0;n<t;++n)i[n]=e(n/(t-1));return i}},56775:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.rgbBasisClosed=t.rgbBasis=t.default=void 0;var n=i(62748),o=l(i(82916)),r=l(i(51663)),a=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=s(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}(i(26694));function s(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(s=function(e){return e?i:t})(e)}function l(e){return e&&e.__esModule?e:{default:e}}var c=function e(t){var i=(0,a.gamma)(t);function o(e,t){var o=i((e=(0,n.rgb)(e)).r,(t=(0,n.rgb)(t)).r),r=i(e.g,t.g),s=i(e.b,t.b),l=(0,a.default)(e.opacity,t.opacity);return function(t){return e.r=o(t),e.g=r(t),e.b=s(t),e.opacity=l(t),e+""}}return o.gamma=e,o}(1);function d(e){return function(t){var i,o,r=t.length,a=new Array(r),s=new Array(r),l=new Array(r);for(i=0;i<r;++i)o=(0,n.rgb)(t[i]),a[i]=o.r||0,s[i]=o.g||0,l[i]=o.b||0;return a=e(a),s=e(s),l=e(l),o.opacity=1,function(e){return o.r=a(e),o.g=s(e),o.b=l(e),o+""}}}t.default=c;var u=d(o.default);t.rgbBasis=u;var h=d(r.default);t.rgbBasisClosed=h},36965:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){return e=+e,t=+t,function(i){return Math.round(e*(1-i)+t*i)}}},32636:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var i,n,s,l=r.lastIndex=a.lastIndex=0,c=-1,d=[],u=[];for(e+="",t+="";(i=r.exec(e))&&(n=a.exec(t));)(s=n.index)>l&&(s=t.slice(l,s),d[c]?d[c]+=s:d[++c]=s),(i=i[0])===(n=n[0])?d[c]?d[c]+=n:d[++c]=n:(d[++c]=null,u.push({i:c,x:(0,o.default)(i,n)})),l=a.lastIndex;return l<t.length&&(s=t.slice(l),d[c]?d[c]+=s:d[++c]=s),d.length<2?u[0]?function(e){return function(t){return e(t)+""}}(u[0].x):function(e){return function(){return e}}(t):(t=u.length,function(e){for(var i,n=0;n<t;++n)d[(i=u[n]).i]=i.x(e);return d.join("")})};var n,o=(n=i(73849))&&n.__esModule?n:{default:n},r=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,a=new RegExp(r.source,"g")},11909:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,n,o,r,a){var s,l,c;return(s=Math.sqrt(e*e+t*t))&&(e/=s,t/=s),(c=e*n+t*o)&&(n-=e*c,o-=t*c),(l=Math.sqrt(n*n+o*o))&&(n/=l,o/=l,c/=l),e*o<t*n&&(e=-e,t=-t,c=-c,s=-s),{translateX:r,translateY:a,rotate:Math.atan2(t,e)*i,skewX:Math.atan(c)*i,scaleX:s,scaleY:l}},t.identity=void 0;var i=180/Math.PI;t.identity={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1}},75402:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.interpolateTransformSvg=t.interpolateTransformCss=void 0;var n,o=(n=i(73849))&&n.__esModule?n:{default:n},r=i(25045);function a(e,t,i,n){function r(e){return e.length?e.pop()+" ":""}return function(a,s){var l=[],c=[];return a=e(a),s=e(s),function(e,n,r,a,s,l){if(e!==r||n!==a){var c=s.push("translate(",null,t,null,i);l.push({i:c-4,x:(0,o.default)(e,r)},{i:c-2,x:(0,o.default)(n,a)})}else(r||a)&&s.push("translate("+r+t+a+i)}(a.translateX,a.translateY,s.translateX,s.translateY,l,c),function(e,t,i,a){e!==t?(e-t>180?t+=360:t-e>180&&(e+=360),a.push({i:i.push(r(i)+"rotate(",null,n)-2,x:(0,o.default)(e,t)})):t&&i.push(r(i)+"rotate("+t+n)}(a.rotate,s.rotate,l,c),function(e,t,i,a){e!==t?a.push({i:i.push(r(i)+"skewX(",null,n)-2,x:(0,o.default)(e,t)}):t&&i.push(r(i)+"skewX("+t+n)}(a.skewX,s.skewX,l,c),function(e,t,i,n,a,s){if(e!==i||t!==n){var l=a.push(r(a)+"scale(",null,",",null,")");s.push({i:l-4,x:(0,o.default)(e,i)},{i:l-2,x:(0,o.default)(t,n)})}else 1===i&&1===n||a.push(r(a)+"scale("+i+","+n+")")}(a.scaleX,a.scaleY,s.scaleX,s.scaleY,l,c),a=s=null,function(e){for(var t,i=-1,n=c.length;++i<n;)l[(t=c[i]).i]=t.x(e);return l.join("")}}}var s=a(r.parseCss,"px, ","px)","deg)");t.interpolateTransformCss=s;var l=a(r.parseSvg,", ",")",")");t.interpolateTransformSvg=l},25045:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parseCss=function(e){const t=new("function"==typeof DOMMatrix?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?o.identity:(0,o.default)(t.a,t.b,t.c,t.d,t.e,t.f)},t.parseSvg=function(e){return null==e?o.identity:(n||(n=document.createElementNS("http://www.w3.org/2000/svg","g")),n.setAttribute("transform",e),(e=n.transform.baseVal.consolidate())?(e=e.matrix,(0,o.default)(e.a,e.b,e.c,e.d,e.e,e.f)):o.identity)};var n,o=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=r(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if("default"!==a&&Object.prototype.hasOwnProperty.call(e,a)){var s=o?Object.getOwnPropertyDescriptor(e,a):null;s&&(s.get||s.set)?Object.defineProperty(n,a,s):n[a]=e[a]}return n.default=e,i&&i.set(e,n),n}(i(11909));function r(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(r=function(e){return e?i:t})(e)}},95828:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var i,h=typeof t;return null==t||"boolean"===h?(0,d.default)(t):("number"===h?s.default:"string"===h?(i=(0,n.color)(t))?(t=i,o.default):c.default:t instanceof n.color?o.default:t instanceof Date?a.default:(0,u.isNumberArray)(t)?u.default:Array.isArray(t)?r.genericArray:"function"!=typeof t.valueOf&&"function"!=typeof t.toString||isNaN(t)?l.default:s.default)(e,t)};var n=i(62748),o=p(i(56775)),r=i(45533),a=p(i(44204)),s=p(i(73849)),l=p(i(96384)),c=p(i(32636)),d=p(i(32958)),u=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=h(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}(i(90250));function h(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(h=function(e){return e?i:t})(e)}function p(e){return e&&e.__esModule?e:{default:e}}},27043:function(e,t){"use strict";function i(e){return((e=Math.exp(e))+1/e)/2}Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=function e(t,n,o){function r(e,r){var a,s,l=e[0],c=e[1],d=e[2],u=r[0],h=r[1],p=r[2],g=u-l,f=h-c,m=g*g+f*f;if(m<1e-12)s=Math.log(p/d)/t,a=function(e){return[l+e*g,c+e*f,d*Math.exp(t*e*s)]};else{var v=Math.sqrt(m),y=(p*p-d*d+o*m)/(2*d*n*v),C=(p*p-d*d-o*m)/(2*p*n*v),b=Math.log(Math.sqrt(y*y+1)-y),S=Math.log(Math.sqrt(C*C+1)-C);s=(S-b)/t,a=function(e){var o,r=e*s,a=i(b),u=d/(n*v)*(a*(o=t*r+b,((o=Math.exp(2*o))-1)/(o+1))-function(e){return((e=Math.exp(e))-1/e)/2}(b));return[l+u*g,c+u*f,d*a/i(t*r+b)]}}return a.duration=1e3*s*t/Math.SQRT2,a}return r.rho=function(t){var i=Math.max(.001,+t),n=i*i;return e(i,n,n*n)},r}(Math.SQRT2,2,4);t.default=n},25985:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"path",{enumerable:!0,get:function(){return o.default}});var n,o=(n=i(68036))&&n.__esModule?n:{default:n}},68036:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;const i=Math.PI,n=2*i,o=1e-6,r=n-o;function a(){this._x0=this._y0=this._x1=this._y1=null,this._=""}function s(){return new a}a.prototype=s.prototype={constructor:a,moveTo:function(e,t){this._+="M"+(this._x0=this._x1=+e)+","+(this._y0=this._y1=+t)},closePath:function(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._+="Z")},lineTo:function(e,t){this._+="L"+(this._x1=+e)+","+(this._y1=+t)},quadraticCurveTo:function(e,t,i,n){this._+="Q"+ +e+","+ +t+","+(this._x1=+i)+","+(this._y1=+n)},bezierCurveTo:function(e,t,i,n,o,r){this._+="C"+ +e+","+ +t+","+ +i+","+ +n+","+(this._x1=+o)+","+(this._y1=+r)},arcTo:function(e,t,n,r,a){e=+e,t=+t,n=+n,r=+r,a=+a;var s=this._x1,l=this._y1,c=n-e,d=r-t,u=s-e,h=l-t,p=u*u+h*h;if(a<0)throw new Error("negative radius: "+a);if(null===this._x1)this._+="M"+(this._x1=e)+","+(this._y1=t);else if(p>o)if(Math.abs(h*c-d*u)>o&&a){var g=n-s,f=r-l,m=c*c+d*d,v=g*g+f*f,y=Math.sqrt(m),C=Math.sqrt(p),b=a*Math.tan((i-Math.acos((m+p-v)/(2*y*C)))/2),S=b/C,x=b/y;Math.abs(S-1)>o&&(this._+="L"+(e+S*u)+","+(t+S*h)),this._+="A"+a+","+a+",0,0,"+ +(h*g>u*f)+","+(this._x1=e+x*c)+","+(this._y1=t+x*d)}else this._+="L"+(this._x1=e)+","+(this._y1=t)},arc:function(e,t,a,s,l,c){e=+e,t=+t,c=!!c;var d=(a=+a)*Math.cos(s),u=a*Math.sin(s),h=e+d,p=t+u,g=1^c,f=c?s-l:l-s;if(a<0)throw new Error("negative radius: "+a);null===this._x1?this._+="M"+h+","+p:(Math.abs(this._x1-h)>o||Math.abs(this._y1-p)>o)&&(this._+="L"+h+","+p),a&&(f<0&&(f=f%n+n),f>r?this._+="A"+a+","+a+",0,1,"+g+","+(e-d)+","+(t-u)+"A"+a+","+a+",0,1,"+g+","+(this._x1=h)+","+(this._y1=p):f>o&&(this._+="A"+a+","+a+",0,"+ +(f>=i)+","+g+","+(this._x1=e+a*Math.cos(l))+","+(this._y1=t+a*Math.sin(l))))},rect:function(e,t,i,n){this._+="M"+(this._x0=this._x1=+e)+","+(this._y0=this._y1=+t)+"h"+ +i+"v"+ +n+"h"+-i+"Z"},toString:function(){return this._}};var l=s;t.default=l},67742:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=s,t.point=function(){return l(s.apply(null,arguments).paddingInner(1))};var n,o=i(55754),r=i(43906),a=(n=i(31110))&&n.__esModule?n:{default:n};function s(){var e,t,i=(0,a.default)().unknown(void 0),n=i.domain,l=i.range,c=0,d=1,u=!1,h=0,p=0,g=.5;function f(){var i=n().length,r=d<c,a=r?d:c,s=r?c:d;e=(s-a)/Math.max(1,i-h+2*p),u&&(e=Math.floor(e)),a+=(s-a-e*(i-h))*g,t=e*(1-h),u&&(a=Math.round(a),t=Math.round(t));var f=(0,o.range)(i).map((function(t){return a+e*t}));return l(r?f.reverse():f)}return delete i.unknown,i.domain=function(e){return arguments.length?(n(e),f()):n()},i.range=function(e){return arguments.length?([c,d]=e,c=+c,d=+d,f()):[c,d]},i.rangeRound=function(e){return[c,d]=e,c=+c,d=+d,u=!0,f()},i.bandwidth=function(){return t},i.step=function(){return e},i.round=function(e){return arguments.length?(u=!!e,f()):u},i.padding=function(e){return arguments.length?(h=Math.min(1,p=+e),f()):h},i.paddingInner=function(e){return arguments.length?(h=Math.min(1,e),f()):h},i.paddingOuter=function(e){return arguments.length?(p=+e,f()):p},i.align=function(e){return arguments.length?(g=Math.max(0,Math.min(1,e)),f()):g},i.copy=function(){return s(n(),[c,d]).round(u).paddingInner(h).paddingOuter(p).align(g)},r.initRange.apply(f(),arguments)}function l(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return l(t())},e}},14422:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return function(){return e}}},92239:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.copy=function(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())},t.default=function(){return p()(c,c)},t.identity=c,t.transformer=p;var n=i(55754),o=i(65164),r=s(i(14422)),a=s(i(6394));function s(e){return e&&e.__esModule?e:{default:e}}var l=[0,1];function c(e){return e}function d(e,t){return(t-=e=+e)?function(i){return(i-e)/t}:(0,r.default)(isNaN(t)?NaN:.5)}function u(e,t,i){var n=e[0],o=e[1],r=t[0],a=t[1];return o<n?(n=d(o,n),r=i(a,r)):(n=d(n,o),r=i(r,a)),function(e){return r(n(e))}}function h(e,t,i){var o=Math.min(e.length,t.length)-1,r=new Array(o),a=new Array(o),s=-1;for(e[o]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++s<o;)r[s]=d(e[s],e[s+1]),a[s]=i(t[s],t[s+1]);return function(t){var i=(0,n.bisect)(e,t,1,o)-1;return a[i](r[i](t))}}function p(){var e,t,i,n,r,s,d=l,p=l,g=o.interpolate,f=c;function m(){var e,t,i,o=Math.min(d.length,p.length);return f!==c&&(e=d[0],t=d[o-1],e>t&&(i=e,e=t,t=i),f=function(i){return Math.max(e,Math.min(t,i))}),n=o>2?h:u,r=s=null,v}function v(t){return null==t||isNaN(t=+t)?i:(r||(r=n(d.map(e),p,g)))(e(f(t)))}return v.invert=function(i){return f(t((s||(s=n(p,d.map(e),o.interpolateNumber)))(i)))},v.domain=function(e){return arguments.length?(d=Array.from(e,a.default),m()):d.slice()},v.range=function(e){return arguments.length?(p=Array.from(e),m()):p.slice()},v.rangeRound=function(e){return p=Array.from(e),g=o.interpolateRound,m()},v.clamp=function(e){return arguments.length?(f=!!e||c,m()):f!==c},v.interpolate=function(e){return arguments.length?(g=e,m()):g},v.unknown=function(e){return arguments.length?(i=e,v):i},function(i,n){return e=i,t=n,m()}}},15769:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(){var t=(0,a.linearish)(u()(o.identity));return t.copy=function(){return(0,l.copy)(t,e())},r.initInterpolator.apply(t,arguments)},t.divergingLog=function e(){var t=(0,s.loggish)(u()).domain([.1,1,10]);return t.copy=function(){return(0,l.copy)(t,e()).base(t.base())},r.initInterpolator.apply(t,arguments)},t.divergingPow=h,t.divergingSqrt=function(){return h.apply(null,arguments).exponent(.5)},t.divergingSymlog=function e(){var t=(0,c.symlogish)(u());return t.copy=function(){return(0,l.copy)(t,e()).constant(t.constant())},r.initInterpolator.apply(t,arguments)};var n=i(65164),o=i(92239),r=i(43906),a=i(16896),s=i(99309),l=i(21008),c=i(61045),d=i(59934);function u(){var e,t,i,r,a,s,l,c=0,d=.5,u=1,h=1,p=o.identity,g=!1;function f(e){return isNaN(e=+e)?l:(e=.5+((e=+s(e))-t)*(h*e<h*t?r:a),p(g?Math.max(0,Math.min(1,e)):e))}function m(e){return function(t){var i,o,r;return arguments.length?([i,o,r]=t,p=(0,n.piecewise)(e,[i,o,r]),f):[p(0),p(.5),p(1)]}}return f.domain=function(n){return arguments.length?([c,d,u]=n,e=s(c=+c),t=s(d=+d),i=s(u=+u),r=e===t?0:.5/(t-e),a=t===i?0:.5/(i-t),h=t<e?-1:1,f):[c,d,u]},f.clamp=function(e){return arguments.length?(g=!!e,f):g},f.interpolator=function(e){return arguments.length?(p=e,f):p},f.range=m(n.interpolate),f.rangeRound=m(n.interpolateRound),f.unknown=function(e){return arguments.length?(l=e,f):l},function(n){return s=n,e=n(c),t=n(d),i=n(u),r=e===t?0:.5/(t-e),a=t===i?0:.5/(i-t),h=t<e?-1:1,f}}function h(){var e=(0,d.powish)(u());return e.copy=function(){return(0,l.copy)(e,h()).exponent(e.exponent())},r.initInterpolator.apply(e,arguments)}},81837:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(t){var i;function n(e){return null==e||isNaN(e=+e)?i:e}return n.invert=n,n.domain=n.range=function(e){return arguments.length?(t=Array.from(e,r.default),n):t.slice()},n.unknown=function(e){return arguments.length?(i=e,n):i},n.copy=function(){return e(t).unknown(i)},t=arguments.length?Array.from(t,r.default):[0,1],(0,o.linearish)(n)};var n,o=i(16896),r=(n=i(6394))&&n.__esModule?n:{default:n}},63528:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"scaleBand",{enumerable:!0,get:function(){return n.default}}),Object.defineProperty(t,"scaleDiverging",{enumerable:!0,get:function(){return y.default}}),Object.defineProperty(t,"scaleDivergingLog",{enumerable:!0,get:function(){return y.divergingLog}}),Object.defineProperty(t,"scaleDivergingPow",{enumerable:!0,get:function(){return y.divergingPow}}),Object.defineProperty(t,"scaleDivergingSqrt",{enumerable:!0,get:function(){return y.divergingSqrt}}),Object.defineProperty(t,"scaleDivergingSymlog",{enumerable:!0,get:function(){return y.divergingSymlog}}),Object.defineProperty(t,"scaleIdentity",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(t,"scaleImplicit",{enumerable:!0,get:function(){return l.implicit}}),Object.defineProperty(t,"scaleLinear",{enumerable:!0,get:function(){return r.default}}),Object.defineProperty(t,"scaleLog",{enumerable:!0,get:function(){return a.default}}),Object.defineProperty(t,"scaleOrdinal",{enumerable:!0,get:function(){return l.default}}),Object.defineProperty(t,"scalePoint",{enumerable:!0,get:function(){return n.point}}),Object.defineProperty(t,"scalePow",{enumerable:!0,get:function(){return c.default}}),Object.defineProperty(t,"scaleQuantile",{enumerable:!0,get:function(){return u.default}}),Object.defineProperty(t,"scaleQuantize",{enumerable:!0,get:function(){return h.default}}),Object.defineProperty(t,"scaleRadial",{enumerable:!0,get:function(){return d.default}}),Object.defineProperty(t,"scaleSequential",{enumerable:!0,get:function(){return m.default}}),Object.defineProperty(t,"scaleSequentialLog",{enumerable:!0,get:function(){return m.sequentialLog}}),Object.defineProperty(t,"scaleSequentialPow",{enumerable:!0,get:function(){return m.sequentialPow}}),Object.defineProperty(t,"scaleSequentialQuantile",{enumerable:!0,get:function(){return v.default}}),Object.defineProperty(t,"scaleSequentialSqrt",{enumerable:!0,get:function(){return m.sequentialSqrt}}),Object.defineProperty(t,"scaleSequentialSymlog",{enumerable:!0,get:function(){return m.sequentialSymlog}}),Object.defineProperty(t,"scaleSqrt",{enumerable:!0,get:function(){return c.sqrt}}),Object.defineProperty(t,"scaleSymlog",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(t,"scaleThreshold",{enumerable:!0,get:function(){return p.default}}),Object.defineProperty(t,"scaleTime",{enumerable:!0,get:function(){return g.default}}),Object.defineProperty(t,"scaleUtc",{enumerable:!0,get:function(){return f.default}}),Object.defineProperty(t,"tickFormat",{enumerable:!0,get:function(){return C.default}});var n=x(i(67742)),o=b(i(81837)),r=b(i(16896)),a=b(i(99309)),s=b(i(61045)),l=x(i(31110)),c=x(i(59934)),d=b(i(30905)),u=b(i(96269)),h=b(i(62943)),p=b(i(58752)),g=b(i(17389)),f=b(i(15411)),m=x(i(21008)),v=b(i(8314)),y=x(i(15769)),C=b(i(65343));function b(e){return e&&e.__esModule?e:{default:e}}function S(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(S=function(e){return e?i:t})(e)}function x(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=S(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}},43906:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.initInterpolator=function(e,t){switch(arguments.length){case 0:break;case 1:"function"==typeof e?this.interpolator(e):this.range(e);break;default:this.domain(e),"function"==typeof t?this.interpolator(t):this.range(t)}return this},t.initRange=function(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e)}return this}},16896:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(){var t=(0,r.default)();return t.copy=function(){return(0,r.copy)(t,e())},a.initRange.apply(t,arguments),c(t)},t.linearish=c;var n,o=i(55754),r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=l(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}(i(92239)),a=i(43906),s=(n=i(65343))&&n.__esModule?n:{default:n};function l(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(l=function(e){return e?i:t})(e)}function c(e){var t=e.domain;return e.ticks=function(e){var i=t();return(0,o.ticks)(i[0],i[i.length-1],null==e?10:e)},e.tickFormat=function(e,i){var n=t();return(0,s.default)(n[0],n[n.length-1],null==e?10:e,i)},e.nice=function(i){null==i&&(i=10);var n,r,a=t(),s=0,l=a.length-1,c=a[s],d=a[l],u=10;for(d<c&&(r=c,c=d,d=r,r=s,s=l,l=r);u-- >0;){if((r=(0,o.tickIncrement)(c,d,i))===n)return a[s]=c,a[l]=d,t(a);if(r>0)c=Math.floor(c/r)*r,d=Math.ceil(d/r)*r;else{if(!(r<0))break;c=Math.ceil(c*r)/r,d=Math.floor(d*r)/r}n=r}return e},e}},99309:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(){const t=f((0,s.transformer)()).domain([1,10]);return t.copy=()=>(0,s.copy)(t,e()).base(t.base()),l.initRange.apply(t,arguments),t},t.loggish=f;var n,o=i(55754),r=i(79737),a=(n=i(73392))&&n.__esModule?n:{default:n},s=i(92239),l=i(43906);function c(e){return Math.log(e)}function d(e){return Math.exp(e)}function u(e){return-Math.log(-e)}function h(e){return-Math.exp(-e)}function p(e){return isFinite(e)?+("1e"+e):e<0?0:e}function g(e){return(t,i)=>-e(-t,i)}function f(e){const t=e(c,d),i=t.domain;let n,s,l=10;function f(){return n=function(e){return e===Math.E?Math.log:10===e&&Math.log10||2===e&&Math.log2||(e=Math.log(e),t=>Math.log(t)/e)}(l),s=function(e){return 10===e?p:e===Math.E?Math.exp:t=>Math.pow(e,t)}(l),i()[0]<0?(n=g(n),s=g(s),e(u,h)):e(c,d),t}return t.base=function(e){return arguments.length?(l=+e,f()):l},t.domain=function(e){return arguments.length?(i(e),f()):i()},t.ticks=e=>{const t=i();let r=t[0],a=t[t.length-1];const c=a<r;c&&([r,a]=[a,r]);let d,u,h=n(r),p=n(a);const g=null==e?10:+e;let f=[];if(!(l%1)&&p-h<g){if(h=Math.floor(h),p=Math.ceil(p),r>0){for(;h<=p;++h)for(d=1;d<l;++d)if(u=h<0?d/s(-h):d*s(h),!(u<r)){if(u>a)break;f.push(u)}}else for(;h<=p;++h)for(d=l-1;d>=1;--d)if(u=h>0?d/s(-h):d*s(h),!(u<r)){if(u>a)break;f.push(u)}2*f.length<g&&(f=(0,o.ticks)(r,a,g))}else f=(0,o.ticks)(h,p,Math.min(p-h,g)).map(s);return c?f.reverse():f},t.tickFormat=(e,i)=>{if(null==e&&(e=10),null==i&&(i=10===l?"s":","),"function"!=typeof i&&(l%1||null!=(i=(0,r.formatSpecifier)(i)).precision||(i.trim=!0),i=(0,r.format)(i)),e===1/0)return i;const o=Math.max(1,l*e/t.ticks().length);return e=>{let t=e/s(Math.round(n(e)));return t*l<l-.5&&(t*=l),t<=o?i(e):""}},t.nice=()=>i((0,a.default)(i(),{floor:e=>s(Math.floor(n(e))),ceil:e=>s(Math.ceil(n(e)))})),t}},73392:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var i,n=0,o=(e=e.slice()).length-1,r=e[n],a=e[o];return a<r&&(i=n,n=o,o=i,i=r,r=a,a=i),e[n]=t.floor(r),e[o]=t.ceil(a),e}},6394:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return+e}},31110:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(){var t=new n.InternMap,i=[],a=[],s=r;function l(e){let n=t.get(e);if(void 0===n){if(s!==r)return s;t.set(e,n=i.push(e)-1)}return a[n%a.length]}return l.domain=function(e){if(!arguments.length)return i.slice();i=[],t=new n.InternMap;for(const n of e)t.has(n)||t.set(n,i.push(n)-1);return l},l.range=function(e){return arguments.length?(a=Array.from(e),l):a.slice()},l.unknown=function(e){return arguments.length?(s=e,l):s},l.copy=function(){return e(i,a).unknown(s)},o.initRange.apply(l,arguments),l},t.implicit=void 0;var n=i(55754),o=i(43906);const r=Symbol("implicit");t.implicit=r},59934:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=d,t.powish=c,t.sqrt=function(){return d.apply(null,arguments).exponent(.5)};var n=i(16896),o=i(92239),r=i(43906);function a(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function s(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function l(e){return e<0?-e*e:e*e}function c(e){var t=e(o.identity,o.identity),i=1;return t.exponent=function(t){return arguments.length?1==(i=+t)?e(o.identity,o.identity):.5===i?e(s,l):e(a(i),a(1/i)):i},(0,n.linearish)(t)}function d(){var e=c((0,o.transformer)());return e.copy=function(){return(0,o.copy)(e,d()).exponent(e.exponent())},r.initRange.apply(e,arguments),e}},96269:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(){var t,i=[],r=[],a=[];function s(){var e=0,t=Math.max(1,r.length);for(a=new Array(t-1);++e<t;)a[e-1]=(0,n.quantileSorted)(i,e/t);return l}function l(e){return null==e||isNaN(e=+e)?t:r[(0,n.bisect)(a,e)]}return l.invertExtent=function(e){var t=r.indexOf(e);return t<0?[NaN,NaN]:[t>0?a[t-1]:i[0],t<a.length?a[t]:i[i.length-1]]},l.domain=function(e){if(!arguments.length)return i.slice();i=[];for(let t of e)null==t||isNaN(t=+t)||i.push(t);return i.sort(n.ascending),s()},l.range=function(e){return arguments.length?(r=Array.from(e),s()):r.slice()},l.unknown=function(e){return arguments.length?(t=e,l):t},l.quantiles=function(){return a.slice()},l.copy=function(){return e().domain(i).range(r).unknown(t)},o.initRange.apply(l,arguments)};var n=i(55754),o=i(43906)},62943:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(){var t,i=0,a=1,s=1,l=[.5],c=[0,1];function d(e){return null!=e&&e<=e?c[(0,n.bisect)(l,e,0,s)]:t}function u(){var e=-1;for(l=new Array(s);++e<s;)l[e]=((e+1)*a-(e-s)*i)/(s+1);return d}return d.domain=function(e){return arguments.length?([i,a]=e,i=+i,a=+a,u()):[i,a]},d.range=function(e){return arguments.length?(s=(c=Array.from(e)).length-1,u()):c.slice()},d.invertExtent=function(e){var t=c.indexOf(e);return t<0?[NaN,NaN]:t<1?[i,l[0]]:t>=s?[l[s-1],a]:[l[t-1],l[t]]},d.unknown=function(e){return arguments.length?(t=e,d):d},d.thresholds=function(){return l.slice()},d.copy=function(){return e().domain([i,a]).range(c).unknown(t)},r.initRange.apply((0,o.linearish)(d),arguments)};var n=i(55754),o=i(16896),r=i(43906)},30905:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(){var t,i=(0,n.default)(),s=[0,1],c=!1;function d(e){var n=function(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}(i(e));return isNaN(n)?t:c?Math.round(n):n}return d.invert=function(e){return i.invert(l(e))},d.domain=function(e){return arguments.length?(i.domain(e),d):i.domain()},d.range=function(e){return arguments.length?(i.range((s=Array.from(e,a.default)).map(l)),d):s.slice()},d.rangeRound=function(e){return d.range(e).round(!0)},d.round=function(e){return arguments.length?(c=!!e,d):c},d.clamp=function(e){return arguments.length?(i.clamp(e),d):i.clamp()},d.unknown=function(e){return arguments.length?(t=e,d):t},d.copy=function(){return e(i.domain(),s).round(c).clamp(i.clamp()).unknown(t)},o.initRange.apply(d,arguments),(0,r.linearish)(d)};var n=s(i(92239)),o=i(43906),r=i(16896),a=s(i(6394));function s(e){return e&&e.__esModule?e:{default:e}}function l(e){return Math.sign(e)*e*e}},21008:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.copy=u,t.default=function e(){var t=(0,a.linearish)(d()(o.identity));return t.copy=function(){return u(t,e())},r.initInterpolator.apply(t,arguments)},t.sequentialLog=function e(){var t=(0,s.loggish)(d()).domain([1,10]);return t.copy=function(){return u(t,e()).base(t.base())},r.initInterpolator.apply(t,arguments)},t.sequentialPow=h,t.sequentialSqrt=function(){return h.apply(null,arguments).exponent(.5)},t.sequentialSymlog=function e(){var t=(0,l.symlogish)(d());return t.copy=function(){return u(t,e()).constant(t.constant())},r.initInterpolator.apply(t,arguments)};var n=i(65164),o=i(92239),r=i(43906),a=i(16896),s=i(99309),l=i(61045),c=i(59934);function d(){var e,t,i,r,a,s=0,l=1,c=o.identity,d=!1;function u(t){return null==t||isNaN(t=+t)?a:c(0===i?.5:(t=(r(t)-e)*i,d?Math.max(0,Math.min(1,t)):t))}function h(e){return function(t){var i,n;return arguments.length?([i,n]=t,c=e(i,n),u):[c(0),c(1)]}}return u.domain=function(n){return arguments.length?([s,l]=n,e=r(s=+s),t=r(l=+l),i=e===t?0:1/(t-e),u):[s,l]},u.clamp=function(e){return arguments.length?(d=!!e,u):d},u.interpolator=function(e){return arguments.length?(c=e,u):c},u.range=h(n.interpolate),u.rangeRound=h(n.interpolateRound),u.unknown=function(e){return arguments.length?(a=e,u):a},function(n){return r=n,e=n(s),t=n(l),i=e===t?0:1/(t-e),u}}function u(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function h(){var e=(0,c.powish)(d());return e.copy=function(){return u(e,h()).exponent(e.exponent())},r.initInterpolator.apply(e,arguments)}},8314:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(){var t=[],i=o.identity;function a(e){if(null!=e&&!isNaN(e=+e))return i(((0,n.bisect)(t,e,1)-1)/(t.length-1))}return a.domain=function(e){if(!arguments.length)return t.slice();t=[];for(let i of e)null==i||isNaN(i=+i)||t.push(i);return t.sort(n.ascending),a},a.interpolator=function(e){return arguments.length?(i=e,a):i},a.range=function(){return t.map(((e,n)=>i(n/(t.length-1))))},a.quantiles=function(e){return Array.from({length:e+1},((i,o)=>(0,n.quantile)(t,o/e)))},a.copy=function(){return e(i).domain(t)},r.initInterpolator.apply(a,arguments)};var n=i(55754),o=i(92239),r=i(43906)},61045:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(){var t=l((0,o.transformer)());return t.copy=function(){return(0,o.copy)(t,e()).constant(t.constant())},r.initRange.apply(t,arguments)},t.symlogish=l;var n=i(16896),o=i(92239),r=i(43906);function a(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function s(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function l(e){var t=1,i=e(a(t),s(t));return i.constant=function(i){return arguments.length?e(a(t=+i),s(t)):t},(0,n.linearish)(i)}},58752:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(){var t,i=[.5],r=[0,1],a=1;function s(e){return null!=e&&e<=e?r[(0,n.bisect)(i,e,0,a)]:t}return s.domain=function(e){return arguments.length?(i=Array.from(e),a=Math.min(i.length,r.length-1),s):i.slice()},s.range=function(e){return arguments.length?(r=Array.from(e),a=Math.min(i.length,r.length-1),s):r.slice()},s.invertExtent=function(e){var t=r.indexOf(e);return[i[t-1],i[t]]},s.unknown=function(e){return arguments.length?(t=e,s):t},s.copy=function(){return e().domain(i).range(r).unknown(t)},o.initRange.apply(s,arguments)};var n=i(55754),o=i(43906)},65343:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,i,r){var a,s=(0,n.tickStep)(e,t,i);switch((r=(0,o.formatSpecifier)(null==r?",f":r)).type){case"s":var l=Math.max(Math.abs(e),Math.abs(t));return null!=r.precision||isNaN(a=(0,o.precisionPrefix)(s,l))||(r.precision=a),(0,o.formatPrefix)(r,l);case"":case"e":case"g":case"p":case"r":null!=r.precision||isNaN(a=(0,o.precisionRound)(s,Math.max(Math.abs(e),Math.abs(t))))||(r.precision=a-("e"===r.type));break;case"f":case"%":null!=r.precision||isNaN(a=(0,o.precisionFixed)(s))||(r.precision=a-2*("%"===r.type))}return(0,o.format)(r)};var n=i(55754),o=i(79737)},17389:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.calendar=h,t.default=function(){return s.initRange.apply(h(o.timeTicks,o.timeTickInterval,o.timeYear,o.timeMonth,o.timeWeek,o.timeDay,o.timeHour,o.timeMinute,o.timeSecond,r.timeFormat).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)};var n,o=i(2768),r=i(47920),a=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=c(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}(i(92239)),s=i(43906),l=(n=i(73392))&&n.__esModule?n:{default:n};function c(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(c=function(e){return e?i:t})(e)}function d(e){return new Date(e)}function u(e){return e instanceof Date?+e:+new Date(+e)}function h(e,t,i,n,o,r,s,c,p,g){var f=(0,a.default)(),m=f.invert,v=f.domain,y=g(".%L"),C=g(":%S"),b=g("%I:%M"),S=g("%I %p"),x=g("%a %d"),T=g("%b %d"),w=g("%B"),O=g("%Y");function P(e){return(p(e)<e?y:c(e)<e?C:s(e)<e?b:r(e)<e?S:n(e)<e?o(e)<e?x:T:i(e)<e?w:O)(e)}return f.invert=function(e){return new Date(m(e))},f.domain=function(e){return arguments.length?v(Array.from(e,u)):v().map(d)},f.ticks=function(t){var i=v();return e(i[0],i[i.length-1],null==t?10:t)},f.tickFormat=function(e,t){return null==t?P:g(t)},f.nice=function(e){var i=v();return e&&"function"==typeof e.range||(e=t(i[0],i[i.length-1],null==e?10:e)),e?v((0,l.default)(i,e)):f},f.copy=function(){return(0,a.copy)(f,h(e,t,i,n,o,r,s,c,p,g))},f}},15411:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){return a.initRange.apply((0,r.calendar)(n.utcTicks,n.utcTickInterval,n.utcYear,n.utcMonth,n.utcWeek,n.utcDay,n.utcHour,n.utcMinute,n.utcSecond,o.utcFormat).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)};var n=i(2768),o=i(47920),r=i(17389),a=i(43906)},7456:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){var e=s,t=l,i=(0,r.default)(0),n=null,p=c,g=d,f=u,m=null;function v(){var r,s,l=+e.apply(this,arguments),c=+t.apply(this,arguments),d=p.apply(this,arguments)-a.halfPi,u=g.apply(this,arguments)-a.halfPi,v=(0,a.abs)(u-d),y=u>d;if(m||(m=r=(0,o.path)()),c<l&&(s=c,c=l,l=s),c>a.epsilon)if(v>a.tau-a.epsilon)m.moveTo(c*(0,a.cos)(d),c*(0,a.sin)(d)),m.arc(0,0,c,d,u,!y),l>a.epsilon&&(m.moveTo(l*(0,a.cos)(u),l*(0,a.sin)(u)),m.arc(0,0,l,u,d,y));else{var C,b,S=d,x=u,T=d,w=u,O=v,P=v,A=f.apply(this,arguments)/2,E=A>a.epsilon&&(n?+n.apply(this,arguments):(0,a.sqrt)(l*l+c*c)),k=(0,a.min)((0,a.abs)(c-l)/2,+i.apply(this,arguments)),I=k,D=k;if(E>a.epsilon){var _=(0,a.asin)(E/l*(0,a.sin)(A)),N=(0,a.asin)(E/c*(0,a.sin)(A));(O-=2*_)>a.epsilon?(T+=_*=y?1:-1,w-=_):(O=0,T=w=(d+u)/2),(P-=2*N)>a.epsilon?(S+=N*=y?1:-1,x-=N):(P=0,S=x=(d+u)/2)}var R=c*(0,a.cos)(S),M=c*(0,a.sin)(S),L=l*(0,a.cos)(w),B=l*(0,a.sin)(w);if(k>a.epsilon){var F,U=c*(0,a.cos)(x),H=c*(0,a.sin)(x),$=l*(0,a.cos)(T),Z=l*(0,a.sin)(T);if(v<a.pi&&(F=function(e,t,i,n,o,r,s,l){var c=i-e,d=n-t,u=s-o,h=l-r,p=h*c-u*d;if(!(p*p<a.epsilon))return[e+(p=(u*(t-r)-h*(e-o))/p)*c,t+p*d]}(R,M,$,Z,U,H,L,B))){var V=R-F[0],G=M-F[1],j=U-F[0],z=H-F[1],W=1/(0,a.sin)((0,a.acos)((V*j+G*z)/((0,a.sqrt)(V*V+G*G)*(0,a.sqrt)(j*j+z*z)))/2),K=(0,a.sqrt)(F[0]*F[0]+F[1]*F[1]);I=(0,a.min)(k,(l-K)/(W-1)),D=(0,a.min)(k,(c-K)/(W+1))}}P>a.epsilon?D>a.epsilon?(C=h($,Z,R,M,c,D,y),b=h(U,H,L,B,c,D,y),m.moveTo(C.cx+C.x01,C.cy+C.y01),D<k?m.arc(C.cx,C.cy,D,(0,a.atan2)(C.y01,C.x01),(0,a.atan2)(b.y01,b.x01),!y):(m.arc(C.cx,C.cy,D,(0,a.atan2)(C.y01,C.x01),(0,a.atan2)(C.y11,C.x11),!y),m.arc(0,0,c,(0,a.atan2)(C.cy+C.y11,C.cx+C.x11),(0,a.atan2)(b.cy+b.y11,b.cx+b.x11),!y),m.arc(b.cx,b.cy,D,(0,a.atan2)(b.y11,b.x11),(0,a.atan2)(b.y01,b.x01),!y))):(m.moveTo(R,M),m.arc(0,0,c,S,x,!y)):m.moveTo(R,M),l>a.epsilon&&O>a.epsilon?I>a.epsilon?(C=h(L,B,U,H,l,-I,y),b=h(R,M,$,Z,l,-I,y),m.lineTo(C.cx+C.x01,C.cy+C.y01),I<k?m.arc(C.cx,C.cy,I,(0,a.atan2)(C.y01,C.x01),(0,a.atan2)(b.y01,b.x01),!y):(m.arc(C.cx,C.cy,I,(0,a.atan2)(C.y01,C.x01),(0,a.atan2)(C.y11,C.x11),!y),m.arc(0,0,l,(0,a.atan2)(C.cy+C.y11,C.cx+C.x11),(0,a.atan2)(b.cy+b.y11,b.cx+b.x11),y),m.arc(b.cx,b.cy,I,(0,a.atan2)(b.y11,b.x11),(0,a.atan2)(b.y01,b.x01),!y))):m.arc(0,0,l,w,T,y):m.lineTo(L,B)}else m.moveTo(0,0);if(m.closePath(),r)return m=null,r+""||null}return v.centroid=function(){var i=(+e.apply(this,arguments)+ +t.apply(this,arguments))/2,n=(+p.apply(this,arguments)+ +g.apply(this,arguments))/2-a.pi/2;return[(0,a.cos)(n)*i,(0,a.sin)(n)*i]},v.innerRadius=function(t){return arguments.length?(e="function"==typeof t?t:(0,r.default)(+t),v):e},v.outerRadius=function(e){return arguments.length?(t="function"==typeof e?e:(0,r.default)(+e),v):t},v.cornerRadius=function(e){return arguments.length?(i="function"==typeof e?e:(0,r.default)(+e),v):i},v.padRadius=function(e){return arguments.length?(n=null==e?null:"function"==typeof e?e:(0,r.default)(+e),v):n},v.startAngle=function(e){return arguments.length?(p="function"==typeof e?e:(0,r.default)(+e),v):p},v.endAngle=function(e){return arguments.length?(g="function"==typeof e?e:(0,r.default)(+e),v):g},v.padAngle=function(e){return arguments.length?(f="function"==typeof e?e:(0,r.default)(+e),v):f},v.context=function(e){return arguments.length?(m=null==e?null:e,v):m},v};var n,o=i(25985),r=(n=i(75820))&&n.__esModule?n:{default:n},a=i(25307);function s(e){return e.innerRadius}function l(e){return e.outerRadius}function c(e){return e.startAngle}function d(e){return e.endAngle}function u(e){return e&&e.padAngle}function h(e,t,i,n,o,r,s){var l=e-i,c=t-n,d=(s?r:-r)/(0,a.sqrt)(l*l+c*c),u=d*c,h=-d*l,p=e+u,g=t+h,f=i+u,m=n+h,v=(p+f)/2,y=(g+m)/2,C=f-p,b=m-g,S=C*C+b*b,x=o-r,T=p*m-f*g,w=(b<0?-1:1)*(0,a.sqrt)((0,a.max)(0,x*x*S-T*T)),O=(T*b-C*w)/S,P=(-T*C-b*w)/S,A=(T*b+C*w)/S,E=(-T*C+b*w)/S,k=O-v,I=P-y,D=A-v,_=E-y;return k*k+I*I>D*D+_*_&&(O=A,P=E),{cx:O,cy:P,x01:-u,y01:-h,x11:O*(o/x-1),y11:P*(o/x-1)}}},85767:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,i){var c=null,d=(0,r.default)(!0),u=null,h=a.default,p=null;function g(r){var a,s,l,g,f,m=(r=(0,o.default)(r)).length,v=!1,y=new Array(m),C=new Array(m);for(null==u&&(p=h(f=(0,n.path)())),a=0;a<=m;++a){if(!(a<m&&d(g=r[a],a,r))===v)if(v=!v)s=a,p.areaStart(),p.lineStart();else{for(p.lineEnd(),p.lineStart(),l=a-1;l>=s;--l)p.point(y[l],C[l]);p.lineEnd(),p.areaEnd()}v&&(y[a]=+e(g,a,r),C[a]=+t(g,a,r),p.point(c?+c(g,a,r):y[a],i?+i(g,a,r):C[a]))}if(f)return p=null,f+""||null}function f(){return(0,s.default)().defined(d).curve(h).context(u)}return e="function"==typeof e?e:void 0===e?l.x:(0,r.default)(+e),t="function"==typeof t?t:void 0===t?(0,r.default)(0):(0,r.default)(+t),i="function"==typeof i?i:void 0===i?l.y:(0,r.default)(+i),g.x=function(t){return arguments.length?(e="function"==typeof t?t:(0,r.default)(+t),c=null,g):e},g.x0=function(t){return arguments.length?(e="function"==typeof t?t:(0,r.default)(+t),g):e},g.x1=function(e){return arguments.length?(c=null==e?null:"function"==typeof e?e:(0,r.default)(+e),g):c},g.y=function(e){return arguments.length?(t="function"==typeof e?e:(0,r.default)(+e),i=null,g):t},g.y0=function(e){return arguments.length?(t="function"==typeof e?e:(0,r.default)(+e),g):t},g.y1=function(e){return arguments.length?(i=null==e?null:"function"==typeof e?e:(0,r.default)(+e),g):i},g.lineX0=g.lineY0=function(){return f().x(e).y(t)},g.lineY1=function(){return f().x(e).y(i)},g.lineX1=function(){return f().x(c).y(t)},g.defined=function(e){return arguments.length?(d="function"==typeof e?e:(0,r.default)(!!e),g):d},g.curve=function(e){return arguments.length?(h=e,null!=u&&(p=h(u)),g):h},g.context=function(e){return arguments.length?(null==e?u=p=null:p=h(u=e),g):u},g};var n=i(25985),o=c(i(84619)),r=c(i(75820)),a=c(i(85430)),s=c(i(97874)),l=i(96094);function c(e){return e&&e.__esModule?e:{default:e}}},80116:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){var e=(0,r.default)().curve(o.curveRadialLinear),t=e.curve,i=e.lineX0,n=e.lineX1,s=e.lineY0,l=e.lineY1;return e.angle=e.x,delete e.x,e.startAngle=e.x0,delete e.x0,e.endAngle=e.x1,delete e.x1,e.radius=e.y,delete e.y,e.innerRadius=e.y0,delete e.y0,e.outerRadius=e.y1,delete e.y1,e.lineStartAngle=function(){return(0,a.lineRadial)(i())},delete e.lineX0,e.lineEndAngle=function(){return(0,a.lineRadial)(n())},delete e.lineX1,e.lineInnerRadius=function(){return(0,a.lineRadial)(s())},delete e.lineY0,e.lineOuterRadius=function(){return(0,a.lineRadial)(l())},delete e.lineY1,e.curve=function(e){return arguments.length?t((0,o.default)(e)):t()._curve},e};var n,o=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=s(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}(i(5232)),r=(n=i(85767))&&n.__esModule?n:{default:n},a=i(49572);function s(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(s=function(e){return e?i:t})(e)}},84619:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return"object"==typeof e&&"length"in e?e:Array.from(e)},t.slice=void 0;var i=Array.prototype.slice;t.slice=i},75820:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return function(){return e}}},89778:function(e,t){"use strict";function i(e,t,i){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+i)/6)}function n(e){this._context=e}Object.defineProperty(t,"__esModule",{value:!0}),t.Basis=n,t.default=function(e){return new n(e)},t.point=i,n.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:i(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:i(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}}},5682:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return new a(e)};var n,o=(n=i(27600))&&n.__esModule?n:{default:n},r=i(89778);function a(e){this._context=e}a.prototype={areaStart:o.default,areaEnd:o.default,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4)}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:(0,r.point)(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}}},40362:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return new o(e)};var n=i(89778);function o(e){this._context=e}o.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var i=(this._x0+4*this._x1+e)/6,o=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(i,o):this._context.moveTo(i,o);break;case 3:this._point=4;default:(0,n.point)(this,e,t)}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}}},53804:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.bumpRadial=function(e){return new a(e)},t.bumpX=function(e){return new r(e,!0)},t.bumpY=function(e){return new r(e,!1)};var n,o=(n=i(5235))&&n.__esModule?n:{default:n};class r{constructor(e,t){this._context=e,this._x=t}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line}point(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._x?this._context.bezierCurveTo(this._x0=(this._x0+e)/2,this._y0,this._x0,t,e,t):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+t)/2,e,this._y0,e,t)}this._x0=e,this._y0=t}}class a{constructor(e){this._context=e}lineStart(){this._point=0}lineEnd(){}point(e,t){if(e=+e,t=+t,0==this._point++)this._x0=e,this._y0=t;else{const i=(0,o.default)(this._x0,this._y0),n=(0,o.default)(this._x0,this._y0=(this._y0+t)/2),r=(0,o.default)(e,this._y0),a=(0,o.default)(e,t);this._context.moveTo(...i),this._context.bezierCurveTo(...n,...r,...a)}}}},16552:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(89778);function o(e,t){this._basis=new n.Basis(e),this._beta=t}o.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var e=this._x,t=this._y,i=e.length-1;if(i>0)for(var n,o=e[0],r=t[0],a=e[i]-o,s=t[i]-r,l=-1;++l<=i;)n=l/i,this._basis.point(this._beta*e[l]+(1-this._beta)*(o+n*a),this._beta*t[l]+(1-this._beta)*(r+n*s));this._x=this._y=null,this._basis.lineEnd()},point:function(e,t){this._x.push(+e),this._y.push(+t)}};var r=function e(t){function i(e){return 1===t?new n.Basis(e):new o(e,t)}return i.beta=function(t){return e(+t)},i}(.85);t.default=r},36091:function(e,t){"use strict";function i(e,t,i){e._context.bezierCurveTo(e._x1+e._k*(e._x2-e._x0),e._y1+e._k*(e._y2-e._y0),e._x2+e._k*(e._x1-t),e._y2+e._k*(e._y1-i),e._x2,e._y2)}function n(e,t){this._context=e,this._k=(1-t)/6}Object.defineProperty(t,"__esModule",{value:!0}),t.Cardinal=n,t.default=void 0,t.point=i,n.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:i(this,this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2,this._x1=e,this._y1=t;break;case 2:this._point=3;default:i(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var o=function e(t){function i(e){return new n(e,t)}return i.tension=function(t){return e(+t)},i}(0);t.default=o},22191:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CardinalClosed=a,t.default=void 0;var n,o=(n=i(27600))&&n.__esModule?n:{default:n},r=i(36091);function a(e,t){this._context=e,this._k=(1-t)/6}a.prototype={areaStart:o.default,areaEnd:o.default,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:(0,r.point)(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var s=function e(t){function i(e){return new a(e,t)}return i.tension=function(t){return e(+t)},i}(0);t.default=s},76657:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CardinalOpen=o,t.default=void 0;var n=i(36091);function o(e,t){this._context=e,this._k=(1-t)/6}o.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:(0,n.point)(this,e,t)}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var r=function e(t){function i(e){return new o(e,t)}return i.tension=function(t){return e(+t)},i}(0);t.default=r},93163:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0,t.point=r;var n=i(25307),o=i(36091);function r(e,t,i){var o=e._x1,r=e._y1,a=e._x2,s=e._y2;if(e._l01_a>n.epsilon){var l=2*e._l01_2a+3*e._l01_a*e._l12_a+e._l12_2a,c=3*e._l01_a*(e._l01_a+e._l12_a);o=(o*l-e._x0*e._l12_2a+e._x2*e._l01_2a)/c,r=(r*l-e._y0*e._l12_2a+e._y2*e._l01_2a)/c}if(e._l23_a>n.epsilon){var d=2*e._l23_2a+3*e._l23_a*e._l12_a+e._l12_2a,u=3*e._l23_a*(e._l23_a+e._l12_a);a=(a*d+e._x1*e._l23_2a-t*e._l12_2a)/u,s=(s*d+e._y1*e._l23_2a-i*e._l12_2a)/u}e._context.bezierCurveTo(o,r,a,s,e._x2,e._y2)}function a(e,t){this._context=e,this._alpha=t}a.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var i=this._x2-e,n=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(i*i+n*n,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3;default:r(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var s=function e(t){function i(e){return t?new a(e,t):new o.Cardinal(e,0)}return i.alpha=function(t){return e(+t)},i}(.5);t.default=s},70181:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n,o=i(22191),r=(n=i(27600))&&n.__esModule?n:{default:n},a=i(93163);function s(e,t){this._context=e,this._alpha=t}s.prototype={areaStart:r.default,areaEnd:r.default,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(e,t){if(e=+e,t=+t,this._point){var i=this._x2-e,n=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(i*i+n*n,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:(0,a.point)(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var l=function e(t){function i(e){return t?new s(e,t):new o.CardinalClosed(e,0)}return i.alpha=function(t){return e(+t)},i}(.5);t.default=l},29041:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(76657),o=i(93163);function r(e,t){this._context=e,this._alpha=t}r.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var i=this._x2-e,n=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(i*i+n*n,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:(0,o.point)(this,e,t)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};var a=function e(t){function i(e){return t?new r(e,t):new n.CardinalOpen(e,0)}return i.alpha=function(t){return e(+t)},i}(.5);t.default=a},85430:function(e,t){"use strict";function i(e){this._context=e}Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return new i(e)},i.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t)}}}},36942:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return new r(e)};var n,o=(n=i(27600))&&n.__esModule?n:{default:n};function r(e){this._context=e}r.prototype={areaStart:o.default,areaEnd:o.default,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}}},38359:function(e,t){"use strict";function i(e){return e<0?-1:1}function n(e,t,n){var o=e._x1-e._x0,r=t-e._x1,a=(e._y1-e._y0)/(o||r<0&&-0),s=(n-e._y1)/(r||o<0&&-0),l=(a*r+s*o)/(o+r);return(i(a)+i(s))*Math.min(Math.abs(a),Math.abs(s),.5*Math.abs(l))||0}function o(e,t){var i=e._x1-e._x0;return i?(3*(e._y1-e._y0)/i-t)/2:t}function r(e,t,i){var n=e._x0,o=e._y0,r=e._x1,a=e._y1,s=(r-n)/3;e._context.bezierCurveTo(n+s,o+s*t,r-s,a-s*i,r,a)}function a(e){this._context=e}function s(e){this._context=new l(e)}function l(e){this._context=e}Object.defineProperty(t,"__esModule",{value:!0}),t.monotoneX=function(e){return new a(e)},t.monotoneY=function(e){return new s(e)},a.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:r(this,this._t0,o(this,this._t0))}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){var i=NaN;if(t=+t,(e=+e)!==this._x1||t!==this._y1){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,r(this,o(this,i=n(this,e,t)),i);break;default:r(this,this._t0,i=n(this,e,t))}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=i}}},(s.prototype=Object.create(a.prototype)).point=function(e,t){a.prototype.point.call(this,t,e)},l.prototype={moveTo:function(e,t){this._context.moveTo(t,e)},closePath:function(){this._context.closePath()},lineTo:function(e,t){this._context.lineTo(t,e)},bezierCurveTo:function(e,t,i,n,o,r){this._context.bezierCurveTo(t,e,n,i,r,o)}}},27450:function(e,t){"use strict";function i(e){this._context=e}function n(e){var t,i,n=e.length-1,o=new Array(n),r=new Array(n),a=new Array(n);for(o[0]=0,r[0]=2,a[0]=e[0]+2*e[1],t=1;t<n-1;++t)o[t]=1,r[t]=4,a[t]=4*e[t]+2*e[t+1];for(o[n-1]=2,r[n-1]=7,a[n-1]=8*e[n-1]+e[n],t=1;t<n;++t)i=o[t]/r[t-1],r[t]-=i,a[t]-=i*a[t-1];for(o[n-1]=a[n-1]/r[n-1],t=n-2;t>=0;--t)o[t]=(a[t]-o[t+1])/r[t];for(r[n-1]=(e[n]+o[n-1])/2,t=0;t<n-1;++t)r[t]=2*e[t+1]-o[t+1];return[o,r]}Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return new i(e)},i.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var e=this._x,t=this._y,i=e.length;if(i)if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),2===i)this._context.lineTo(e[1],t[1]);else for(var o=n(e),r=n(t),a=0,s=1;s<i;++a,++s)this._context.bezierCurveTo(o[0][a],r[0][a],o[1][a],r[1][a],e[s],t[s]);(this._line||0!==this._line&&1===i)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(e,t){this._x.push(+e),this._y.push(+t)}}},5232:function(e,t,i){"use strict";var n;Object.defineProperty(t,"__esModule",{value:!0}),t.curveRadialLinear=void 0,t.default=a;var o=a(((n=i(85430))&&n.__esModule?n:{default:n}).default);function r(e){this._curve=e}function a(e){function t(t){return new r(e(t))}return t._curve=e,t}t.curveRadialLinear=o,r.prototype={areaStart:function(){this._curve.areaStart()},areaEnd:function(){this._curve.areaEnd()},lineStart:function(){this._curve.lineStart()},lineEnd:function(){this._curve.lineEnd()},point:function(e,t){this._curve.point(t*Math.sin(e),t*-Math.cos(e))}}},63830:function(e,t){"use strict";function i(e,t){this._context=e,this._t=t}Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return new i(e,.5)},t.stepAfter=function(e){return new i(e,1)},t.stepBefore=function(e){return new i(e,0)},i.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&2===this._point&&this._context.lineTo(this._x,this._y),(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var i=this._x*(1-this._t)+e*this._t;this._context.lineTo(i,this._y),this._context.lineTo(i,t)}}this._x=e,this._y=t}}},82660:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){return t<e?-1:t>e?1:t>=e?0:NaN}},98947:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return e}},18461:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"arc",{enumerable:!0,get:function(){return n.default}}),Object.defineProperty(t,"area",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(t,"areaRadial",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(t,"curveBasis",{enumerable:!0,get:function(){return A.default}}),Object.defineProperty(t,"curveBasisClosed",{enumerable:!0,get:function(){return O.default}}),Object.defineProperty(t,"curveBasisOpen",{enumerable:!0,get:function(){return P.default}}),Object.defineProperty(t,"curveBumpX",{enumerable:!0,get:function(){return E.bumpX}}),Object.defineProperty(t,"curveBumpY",{enumerable:!0,get:function(){return E.bumpY}}),Object.defineProperty(t,"curveBundle",{enumerable:!0,get:function(){return k.default}}),Object.defineProperty(t,"curveCardinal",{enumerable:!0,get:function(){return _.default}}),Object.defineProperty(t,"curveCardinalClosed",{enumerable:!0,get:function(){return I.default}}),Object.defineProperty(t,"curveCardinalOpen",{enumerable:!0,get:function(){return D.default}}),Object.defineProperty(t,"curveCatmullRom",{enumerable:!0,get:function(){return M.default}}),Object.defineProperty(t,"curveCatmullRomClosed",{enumerable:!0,get:function(){return N.default}}),Object.defineProperty(t,"curveCatmullRomOpen",{enumerable:!0,get:function(){return R.default}}),Object.defineProperty(t,"curveLinear",{enumerable:!0,get:function(){return B.default}}),Object.defineProperty(t,"curveLinearClosed",{enumerable:!0,get:function(){return L.default}}),Object.defineProperty(t,"curveMonotoneX",{enumerable:!0,get:function(){return F.monotoneX}}),Object.defineProperty(t,"curveMonotoneY",{enumerable:!0,get:function(){return F.monotoneY}}),Object.defineProperty(t,"curveNatural",{enumerable:!0,get:function(){return U.default}}),Object.defineProperty(t,"curveStep",{enumerable:!0,get:function(){return H.default}}),Object.defineProperty(t,"curveStepAfter",{enumerable:!0,get:function(){return H.stepAfter}}),Object.defineProperty(t,"curveStepBefore",{enumerable:!0,get:function(){return H.stepBefore}}),Object.defineProperty(t,"line",{enumerable:!0,get:function(){return r.default}}),Object.defineProperty(t,"lineRadial",{enumerable:!0,get:function(){return l.default}}),Object.defineProperty(t,"link",{enumerable:!0,get:function(){return d.link}}),Object.defineProperty(t,"linkHorizontal",{enumerable:!0,get:function(){return d.linkHorizontal}}),Object.defineProperty(t,"linkRadial",{enumerable:!0,get:function(){return d.linkRadial}}),Object.defineProperty(t,"linkVertical",{enumerable:!0,get:function(){return d.linkVertical}}),Object.defineProperty(t,"pie",{enumerable:!0,get:function(){return a.default}}),Object.defineProperty(t,"pointRadial",{enumerable:!0,get:function(){return c.default}}),Object.defineProperty(t,"radialArea",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(t,"radialLine",{enumerable:!0,get:function(){return l.default}}),Object.defineProperty(t,"stack",{enumerable:!0,get:function(){return $.default}}),Object.defineProperty(t,"stackOffsetDiverging",{enumerable:!0,get:function(){return V.default}}),Object.defineProperty(t,"stackOffsetExpand",{enumerable:!0,get:function(){return Z.default}}),Object.defineProperty(t,"stackOffsetNone",{enumerable:!0,get:function(){return G.default}}),Object.defineProperty(t,"stackOffsetSilhouette",{enumerable:!0,get:function(){return j.default}}),Object.defineProperty(t,"stackOffsetWiggle",{enumerable:!0,get:function(){return z.default}}),Object.defineProperty(t,"stackOrderAppearance",{enumerable:!0,get:function(){return W.default}}),Object.defineProperty(t,"stackOrderAscending",{enumerable:!0,get:function(){return K.default}}),Object.defineProperty(t,"stackOrderDescending",{enumerable:!0,get:function(){return q.default}}),Object.defineProperty(t,"stackOrderInsideOut",{enumerable:!0,get:function(){return Y.default}}),Object.defineProperty(t,"stackOrderNone",{enumerable:!0,get:function(){return X.default}}),Object.defineProperty(t,"stackOrderReverse",{enumerable:!0,get:function(){return J.default}}),Object.defineProperty(t,"symbol",{enumerable:!0,get:function(){return u.default}}),Object.defineProperty(t,"symbolAsterisk",{enumerable:!0,get:function(){return h.default}}),Object.defineProperty(t,"symbolCircle",{enumerable:!0,get:function(){return p.default}}),Object.defineProperty(t,"symbolCross",{enumerable:!0,get:function(){return g.default}}),Object.defineProperty(t,"symbolDiamond",{enumerable:!0,get:function(){return f.default}}),Object.defineProperty(t,"symbolDiamond2",{enumerable:!0,get:function(){return m.default}}),Object.defineProperty(t,"symbolPlus",{enumerable:!0,get:function(){return v.default}}),Object.defineProperty(t,"symbolSquare",{enumerable:!0,get:function(){return y.default}}),Object.defineProperty(t,"symbolSquare2",{enumerable:!0,get:function(){return C.default}}),Object.defineProperty(t,"symbolStar",{enumerable:!0,get:function(){return b.default}}),Object.defineProperty(t,"symbolTriangle",{enumerable:!0,get:function(){return S.default}}),Object.defineProperty(t,"symbolTriangle2",{enumerable:!0,get:function(){return x.default}}),Object.defineProperty(t,"symbolWye",{enumerable:!0,get:function(){return T.default}}),Object.defineProperty(t,"symbolX",{enumerable:!0,get:function(){return w.default}}),Object.defineProperty(t,"symbols",{enumerable:!0,get:function(){return u.symbolsFill}}),Object.defineProperty(t,"symbolsFill",{enumerable:!0,get:function(){return u.symbolsFill}}),Object.defineProperty(t,"symbolsStroke",{enumerable:!0,get:function(){return u.symbolsStroke}});var n=te(i(7456)),o=te(i(85767)),r=te(i(97874)),a=te(i(39104)),s=te(i(80116)),l=te(i(49572)),c=te(i(5235)),d=i(4016),u=ee(i(80798)),h=te(i(47577)),p=te(i(25870)),g=te(i(99495)),f=te(i(13676)),m=te(i(42134)),v=te(i(37044)),y=te(i(12535)),C=te(i(86039)),b=te(i(61475)),S=te(i(3361)),x=te(i(99330)),T=te(i(43001)),w=te(i(15513)),O=te(i(5682)),P=te(i(40362)),A=te(i(89778)),E=i(53804),k=te(i(16552)),I=te(i(22191)),D=te(i(76657)),_=te(i(36091)),N=te(i(70181)),R=te(i(29041)),M=te(i(93163)),L=te(i(36942)),B=te(i(85430)),F=i(38359),U=te(i(27450)),H=ee(i(63830)),$=te(i(84288)),Z=te(i(40850)),V=te(i(24382)),G=te(i(98548)),j=te(i(7505)),z=te(i(68490)),W=te(i(98850)),K=te(i(12107)),q=te(i(49859)),Y=te(i(58735)),X=te(i(36519)),J=te(i(55360));function Q(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(Q=function(e){return e?i:t})(e)}function ee(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=Q(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}function te(e){return e&&e.__esModule?e:{default:e}}},97874:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var i=(0,r.default)(!0),l=null,c=a.default,d=null;function u(r){var a,s,u,h=(r=(0,o.default)(r)).length,p=!1;for(null==l&&(d=c(u=(0,n.path)())),a=0;a<=h;++a)!(a<h&&i(s=r[a],a,r))===p&&((p=!p)?d.lineStart():d.lineEnd()),p&&d.point(+e(s,a,r),+t(s,a,r));if(u)return d=null,u+""||null}return e="function"==typeof e?e:void 0===e?s.x:(0,r.default)(e),t="function"==typeof t?t:void 0===t?s.y:(0,r.default)(t),u.x=function(t){return arguments.length?(e="function"==typeof t?t:(0,r.default)(+t),u):e},u.y=function(e){return arguments.length?(t="function"==typeof e?e:(0,r.default)(+e),u):t},u.defined=function(e){return arguments.length?(i="function"==typeof e?e:(0,r.default)(!!e),u):i},u.curve=function(e){return arguments.length?(c=e,null!=l&&(d=c(l)),u):c},u.context=function(e){return arguments.length?(null==e?l=d=null:d=c(l=e),u):l},u};var n=i(25985),o=l(i(84619)),r=l(i(75820)),a=l(i(85430)),s=i(96094);function l(e){return e&&e.__esModule?e:{default:e}}},49572:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){return s((0,r.default)().curve(o.curveRadialLinear))},t.lineRadial=s;var n,o=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=a(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var s=o?Object.getOwnPropertyDescriptor(e,r):null;s&&(s.get||s.set)?Object.defineProperty(n,r,s):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}(i(5232)),r=(n=i(97874))&&n.__esModule?n:{default:n};function a(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(a=function(e){return e?i:t})(e)}function s(e){var t=e.curve;return e.angle=e.x,delete e.x,e.radius=e.y,delete e.y,e.curve=function(e){return arguments.length?t((0,o.default)(e)):t()._curve},e}},4016:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.link=u,t.linkHorizontal=function(){return u(s.bumpX)},t.linkRadial=function(){const e=u(s.bumpRadial);return e.angle=e.x,delete e.x,e.radius=e.y,delete e.y,e},t.linkVertical=function(){return u(s.bumpY)};var n,o=i(25985),r=i(84619),a=(n=i(75820))&&n.__esModule?n:{default:n},s=i(53804),l=i(96094);function c(e){return e.source}function d(e){return e.target}function u(e){let t=c,i=d,n=l.x,s=l.y,u=null,h=null;function p(){let a;const l=r.slice.call(arguments),c=t.apply(this,l),d=i.apply(this,l);if(null==u&&(h=e(a=(0,o.path)())),h.lineStart(),l[0]=c,h.point(+n.apply(this,l),+s.apply(this,l)),l[0]=d,h.point(+n.apply(this,l),+s.apply(this,l)),h.lineEnd(),a)return h=null,a+""||null}return p.source=function(e){return arguments.length?(t=e,p):t},p.target=function(e){return arguments.length?(i=e,p):i},p.x=function(e){return arguments.length?(n="function"==typeof e?e:(0,a.default)(+e),p):n},p.y=function(e){return arguments.length?(s="function"==typeof e?e:(0,a.default)(+e),p):s},p.context=function(t){return arguments.length?(null==t?u=h=null:h=e(u=t),p):u},p}},25307:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.abs=void 0,t.acos=function(e){return e>1?0:e<-1?c:Math.acos(e)},t.asin=function(e){return e>=1?d:e<=-1?-d:Math.asin(e)},t.tau=t.sqrt=t.sin=t.pi=t.min=t.max=t.halfPi=t.epsilon=t.cos=t.atan2=void 0;const i=Math.abs;t.abs=i;const n=Math.atan2;t.atan2=n;const o=Math.cos;t.cos=o;const r=Math.max;t.max=r;const a=Math.min;t.min=a;const s=Math.sin;t.sin=s;const l=Math.sqrt;t.sqrt=l,t.epsilon=1e-12;const c=Math.PI;t.pi=c;const d=c/2;t.halfPi=d;const u=2*c;t.tau=u},27600:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){}},24382:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if((s=e.length)>0)for(var i,n,o,r,a,s,l=0,c=e[t[0]].length;l<c;++l)for(r=a=0,i=0;i<s;++i)(o=(n=e[t[i]][l])[1]-n[0])>0?(n[0]=r,n[1]=r+=o):o<0?(n[1]=a,n[0]=a+=o):(n[0]=0,n[1]=o)}},40850:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if((n=e.length)>0){for(var i,n,r,a=0,s=e[0].length;a<s;++a){for(r=i=0;i<n;++i)r+=e[i][a][1]||0;if(r)for(i=0;i<n;++i)e[i][a][1]/=r}(0,o.default)(e,t)}};var n,o=(n=i(98548))&&n.__esModule?n:{default:n}},98548:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if((o=e.length)>1)for(var i,n,o,r=1,a=e[t[0]],s=a.length;r<o;++r)for(n=a,a=e[t[r]],i=0;i<s;++i)a[i][1]+=a[i][0]=isNaN(n[i][1])?n[i][0]:n[i][1]}},7505:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if((i=e.length)>0){for(var i,n=0,r=e[t[0]],a=r.length;n<a;++n){for(var s=0,l=0;s<i;++s)l+=e[s][n][1]||0;r[n][1]+=r[n][0]=-l/2}(0,o.default)(e,t)}};var n,o=(n=i(98548))&&n.__esModule?n:{default:n}},68490:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if((r=e.length)>0&&(n=(i=e[t[0]]).length)>0){for(var i,n,r,a=0,s=1;s<n;++s){for(var l=0,c=0,d=0;l<r;++l){for(var u=e[t[l]],h=u[s][1]||0,p=(h-(u[s-1][1]||0))/2,g=0;g<l;++g){var f=e[t[g]];p+=(f[s][1]||0)-(f[s-1][1]||0)}c+=h,d+=p*h}i[s-1][1]+=i[s-1][0]=a,c&&(a-=d/c)}i[s-1][1]+=i[s-1][0]=a,(0,o.default)(e,t)}};var n,o=(n=i(98548))&&n.__esModule?n:{default:n}},98850:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=e.map(r);return(0,o.default)(e).sort((function(e,i){return t[e]-t[i]}))};var n,o=(n=i(36519))&&n.__esModule?n:{default:n};function r(e){for(var t,i=-1,n=0,o=e.length,r=-1/0;++i<o;)(t=+e[i][1])>r&&(r=t,n=i);return n}},12107:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=e.map(r);return(0,o.default)(e).sort((function(e,i){return t[e]-t[i]}))},t.sum=r;var n,o=(n=i(36519))&&n.__esModule?n:{default:n};function r(e){for(var t,i=0,n=-1,o=e.length;++n<o;)(t=+e[n][1])&&(i+=t);return i}},49859:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return(0,o.default)(e).reverse()};var n,o=(n=i(12107))&&n.__esModule?n:{default:n}},58735:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t,i,n=e.length,a=e.map(r.sum),s=(0,o.default)(e),l=0,c=0,d=[],u=[];for(t=0;t<n;++t)i=s[t],l<c?(l+=a[i],d.push(i)):(c+=a[i],u.push(i));return u.reverse().concat(d)};var n,o=(n=i(98850))&&n.__esModule?n:{default:n},r=i(12107)},36519:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){for(var t=e.length,i=new Array(t);--t>=0;)i[t]=t;return i}},55360:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return(0,o.default)(e).reverse()};var n,o=(n=i(36519))&&n.__esModule?n:{default:n}},39104:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){var e=a.default,t=r.default,i=null,l=(0,o.default)(0),c=(0,o.default)(s.tau),d=(0,o.default)(0);function u(o){var r,a,u,h,p,g=(o=(0,n.default)(o)).length,f=0,m=new Array(g),v=new Array(g),y=+l.apply(this,arguments),C=Math.min(s.tau,Math.max(-s.tau,c.apply(this,arguments)-y)),b=Math.min(Math.abs(C)/g,d.apply(this,arguments)),S=b*(C<0?-1:1);for(r=0;r<g;++r)(p=v[m[r]=r]=+e(o[r],r,o))>0&&(f+=p);for(null!=t?m.sort((function(e,i){return t(v[e],v[i])})):null!=i&&m.sort((function(e,t){return i(o[e],o[t])})),r=0,u=f?(C-g*S)/f:0;r<g;++r,y=h)a=m[r],h=y+((p=v[a])>0?p*u:0)+S,v[a]={data:o[a],index:r,value:p,startAngle:y,endAngle:h,padAngle:b};return v}return u.value=function(t){return arguments.length?(e="function"==typeof t?t:(0,o.default)(+t),u):e},u.sortValues=function(e){return arguments.length?(t=e,i=null,u):t},u.sort=function(e){return arguments.length?(i=e,t=null,u):i},u.startAngle=function(e){return arguments.length?(l="function"==typeof e?e:(0,o.default)(+e),u):l},u.endAngle=function(e){return arguments.length?(c="function"==typeof e?e:(0,o.default)(+e),u):c},u.padAngle=function(e){return arguments.length?(d="function"==typeof e?e:(0,o.default)(+e),u):d},u};var n=l(i(84619)),o=l(i(75820)),r=l(i(82660)),a=l(i(98947)),s=i(25307);function l(e){return e&&e.__esModule?e:{default:e}}},96094:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.x=function(e){return e[0]},t.y=function(e){return e[1]}},5235:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){return[(t=+t)*Math.cos(e-=Math.PI/2),t*Math.sin(e)]}},84288:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){var e=(0,o.default)([]),t=a.default,i=r.default,s=l;function d(o){var r,a,l=Array.from(e.apply(this,arguments),c),d=l.length,u=-1;for(const e of o)for(r=0,++u;r<d;++r)(l[r][u]=[0,+s(e,l[r].key,u,o)]).data=e;for(r=0,a=(0,n.default)(t(l));r<d;++r)l[a[r]].index=r;return i(l,a),l}return d.keys=function(t){return arguments.length?(e="function"==typeof t?t:(0,o.default)(Array.from(t)),d):e},d.value=function(e){return arguments.length?(s="function"==typeof e?e:(0,o.default)(+e),d):s},d.order=function(e){return arguments.length?(t=null==e?a.default:"function"==typeof e?e:(0,o.default)(Array.from(e)),d):t},d.offset=function(e){return arguments.length?(i=null==e?r.default:e,d):i},d};var n=s(i(84619)),o=s(i(75820)),r=s(i(98548)),a=s(i(36519));function s(e){return e&&e.__esModule?e:{default:e}}function l(e,t){return e[t]}function c(e){const t=[];return t.key=e,t}},80798:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){let i=null;function r(){let o;if(i||(i=o=(0,n.path)()),e.apply(this,arguments).draw(i,+t.apply(this,arguments)),o)return i=null,o+""||null}return e="function"==typeof e?e:(0,o.default)(e||a.default),t="function"==typeof t?t:(0,o.default)(void 0===t?64:+t),r.type=function(t){return arguments.length?(e="function"==typeof t?t:(0,o.default)(t),r):e},r.size=function(e){return arguments.length?(t="function"==typeof e?e:(0,o.default)(+e),r):t},r.context=function(e){return arguments.length?(i=null==e?null:e,r):i},r},t.symbolsStroke=t.symbolsFill=void 0;var n=i(25985),o=y(i(75820)),r=y(i(47577)),a=y(i(25870)),s=y(i(99495)),l=y(i(13676)),c=y(i(42134)),d=y(i(37044)),u=y(i(12535)),h=y(i(86039)),p=y(i(61475)),g=y(i(3361)),f=y(i(99330)),m=y(i(43001)),v=y(i(15513));function y(e){return e&&e.__esModule?e:{default:e}}const C=[a.default,s.default,l.default,u.default,p.default,g.default,m.default];t.symbolsFill=C;const b=[a.default,d.default,v.default,f.default,r.default,h.default,c.default];t.symbolsStroke=b},47577:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(25307);const o=(0,n.sqrt)(3);var r={draw(e,t){const i=.59436*(0,n.sqrt)(t+(0,n.min)(t/28,.75)),r=i/2,a=r*o;e.moveTo(0,i),e.lineTo(0,-i),e.moveTo(-a,-r),e.lineTo(a,r),e.moveTo(-a,r),e.lineTo(a,-r)}};t.default=r},25870:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(25307),o={draw(e,t){const i=(0,n.sqrt)(t/n.pi);e.moveTo(i,0),e.arc(0,0,i,0,n.tau)}};t.default=o},99495:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(25307),o={draw(e,t){const i=(0,n.sqrt)(t/5)/2;e.moveTo(-3*i,-i),e.lineTo(-i,-i),e.lineTo(-i,-3*i),e.lineTo(i,-3*i),e.lineTo(i,-i),e.lineTo(3*i,-i),e.lineTo(3*i,i),e.lineTo(i,i),e.lineTo(i,3*i),e.lineTo(-i,3*i),e.lineTo(-i,i),e.lineTo(-3*i,i),e.closePath()}};t.default=o},13676:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(25307);const o=(0,n.sqrt)(1/3),r=2*o;var a={draw(e,t){const i=(0,n.sqrt)(t/r),a=i*o;e.moveTo(0,-i),e.lineTo(a,0),e.lineTo(0,i),e.lineTo(-a,0),e.closePath()}};t.default=a},42134:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(25307),o={draw(e,t){const i=.62625*(0,n.sqrt)(t);e.moveTo(0,-i),e.lineTo(i,0),e.lineTo(0,i),e.lineTo(-i,0),e.closePath()}};t.default=o},37044:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(25307),o={draw(e,t){const i=.87559*(0,n.sqrt)(t-(0,n.min)(t/7,2));e.moveTo(-i,0),e.lineTo(i,0),e.moveTo(0,i),e.lineTo(0,-i)}};t.default=o},12535:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(25307),o={draw(e,t){const i=(0,n.sqrt)(t),o=-i/2;e.rect(o,o,i,i)}};t.default=o},86039:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(25307),o={draw(e,t){const i=.4431*(0,n.sqrt)(t);e.moveTo(i,i),e.lineTo(i,-i),e.lineTo(-i,-i),e.lineTo(-i,i),e.closePath()}};t.default=o},61475:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(25307);const o=(0,n.sin)(n.pi/10)/(0,n.sin)(7*n.pi/10),r=(0,n.sin)(n.tau/10)*o,a=-(0,n.cos)(n.tau/10)*o;var s={draw(e,t){const i=(0,n.sqrt)(.8908130915292852*t),o=r*i,s=a*i;e.moveTo(0,-i),e.lineTo(o,s);for(let t=1;t<5;++t){const r=n.tau*t/5,a=(0,n.cos)(r),l=(0,n.sin)(r);e.lineTo(l*i,-a*i),e.lineTo(a*o-l*s,l*o+a*s)}e.closePath()}};t.default=s},3361:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(25307);const o=(0,n.sqrt)(3);var r={draw(e,t){const i=-(0,n.sqrt)(t/(3*o));e.moveTo(0,2*i),e.lineTo(-o*i,-i),e.lineTo(o*i,-i),e.closePath()}};t.default=r},99330:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(25307);const o=(0,n.sqrt)(3);var r={draw(e,t){const i=.6824*(0,n.sqrt)(t),r=i/2,a=i*o/2;e.moveTo(0,-i),e.lineTo(a,r),e.lineTo(-a,r),e.closePath()}};t.default=r},43001:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(25307);const o=-.5,r=(0,n.sqrt)(3)/2,a=1/(0,n.sqrt)(12),s=3*(a/2+1);var l={draw(e,t){const i=(0,n.sqrt)(t/s),l=i/2,c=i*a,d=l,u=i*a+i,h=-d,p=u;e.moveTo(l,c),e.lineTo(d,u),e.lineTo(h,p),e.lineTo(o*l-r*c,r*l+o*c),e.lineTo(o*d-r*u,r*d+o*u),e.lineTo(o*h-r*p,r*h+o*p),e.lineTo(o*l+r*c,o*c-r*l),e.lineTo(o*d+r*u,o*u-r*d),e.lineTo(o*h+r*p,o*p-r*h),e.closePath()}};t.default=l},15513:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(25307),o={draw(e,t){const i=.6189*(0,n.sqrt)(t-(0,n.min)(t/6,1.7));e.moveTo(-i,-i),e.lineTo(i,i),e.moveTo(-i,i),e.lineTo(i,-i)}};t.default=o},40218:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=d,t.utcParse=t.utcFormat=t.timeParse=t.timeFormat=void 0;var n,o,r,a,s,l,c=(n=i(24461))&&n.__esModule?n:{default:n};function d(e){return o=(0,c.default)(e),t.timeFormat=r=o.format,t.timeParse=a=o.parse,t.utcFormat=s=o.utcFormat,t.utcParse=l=o.utcParse,o}t.timeFormat=r,t.timeParse=a,t.utcFormat=s,t.utcParse=l,d({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]})},47920:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"isoFormat",{enumerable:!0,get:function(){return r.default}}),Object.defineProperty(t,"isoParse",{enumerable:!0,get:function(){return a.default}}),Object.defineProperty(t,"timeFormat",{enumerable:!0,get:function(){return n.timeFormat}}),Object.defineProperty(t,"timeFormatDefaultLocale",{enumerable:!0,get:function(){return n.default}}),Object.defineProperty(t,"timeFormatLocale",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(t,"timeParse",{enumerable:!0,get:function(){return n.timeParse}}),Object.defineProperty(t,"utcFormat",{enumerable:!0,get:function(){return n.utcFormat}}),Object.defineProperty(t,"utcParse",{enumerable:!0,get:function(){return n.utcParse}});var n=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=l(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}(i(40218)),o=s(i(24461)),r=s(i(97863)),a=s(i(50567));function s(e){return e&&e.__esModule?e:{default:e}}function l(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(l=function(e){return e?i:t})(e)}},97863:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isoSpecifier=t.default=void 0;var n=i(40218),o="%Y-%m-%dT%H:%M:%S.%LZ";t.isoSpecifier=o;var r=Date.prototype.toISOString?function(e){return e.toISOString()}:(0,n.utcFormat)(o);t.default=r},50567:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=i(97863),o=i(40218),r=+new Date("2000-01-01T00:00:00.000Z")?function(e){var t=new Date(e);return isNaN(t)?null:t}:(0,o.utcParse)(n.isoSpecifier);t.default=r},24461:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=e.dateTime,i=e.date,l=e.time,c=e.periods,d=e.days,u=e.shortDays,h=e.months,z=e.shortMonths,he=p(c),we=g(c),Oe=p(d),Pe=g(d),Ae=p(u),Ee=g(u),ke=p(h),Ie=g(h),De=p(z),_e=g(z),Ne={a:function(e){return u[e.getDay()]},A:function(e){return d[e.getDay()]},b:function(e){return z[e.getMonth()]},B:function(e){return h[e.getMonth()]},c:null,d:M,e:M,f:H,g:X,G:Q,H:L,I:B,j:F,L:U,m:$,M:Z,p:function(e){return c[+(e.getHours()>=12)]},q:function(e){return 1+~~(e.getMonth()/3)},Q:xe,s:Te,S:V,u:G,U:j,V:W,w:K,W:q,x:null,X:null,y:Y,Y:J,Z:ee,"%":Se},Re={a:function(e){return u[e.getUTCDay()]},A:function(e){return d[e.getUTCDay()]},b:function(e){return z[e.getUTCMonth()]},B:function(e){return h[e.getUTCMonth()]},c:null,d:te,e:te,f:ae,g:ve,G:Ce,H:ie,I:ne,j:oe,L:re,m:se,M:le,p:function(e){return c[+(e.getUTCHours()>=12)]},q:function(e){return 1+~~(e.getUTCMonth()/3)},Q:xe,s:Te,S:ce,u:de,U:ue,V:pe,w:ge,W:fe,x:null,X:null,y:me,Y:ye,Z:be,"%":Se},Me={a:function(e,t,i){var n=Ae.exec(t.slice(i));return n?(e.w=Ee.get(n[0].toLowerCase()),i+n[0].length):-1},A:function(e,t,i){var n=Oe.exec(t.slice(i));return n?(e.w=Pe.get(n[0].toLowerCase()),i+n[0].length):-1},b:function(e,t,i){var n=De.exec(t.slice(i));return n?(e.m=_e.get(n[0].toLowerCase()),i+n[0].length):-1},B:function(e,t,i){var n=ke.exec(t.slice(i));return n?(e.m=Ie.get(n[0].toLowerCase()),i+n[0].length):-1},c:function(e,i,n){return Fe(e,t,i,n)},d:O,e:O,f:D,g:S,G:b,H:A,I:A,j:P,L:I,m:w,M:E,p:function(e,t,i){var n=he.exec(t.slice(i));return n?(e.p=we.get(n[0].toLowerCase()),i+n[0].length):-1},q:T,Q:N,s:R,S:k,u:m,U:v,V:y,w:f,W:C,x:function(e,t,n){return Fe(e,i,t,n)},X:function(e,t,i){return Fe(e,l,t,i)},y:S,Y:b,Z:x,"%":_};function Le(e,t){return function(i){var n,o,r,a=[],l=-1,c=0,d=e.length;for(i instanceof Date||(i=new Date(+i));++l<d;)37===e.charCodeAt(l)&&(a.push(e.slice(c,l)),null!=(o=s[n=e.charAt(++l)])?n=e.charAt(++l):o="e"===n?" ":"0",(r=t[n])&&(n=r(i,o)),a.push(n),c=l+1);return a.push(e.slice(c,l)),a.join("")}}function Be(e,t){return function(i){var s,l,c=a(1900,void 0,1);if(Fe(c,e,i+="",0)!=i.length)return null;if("Q"in c)return new Date(c.Q);if("s"in c)return new Date(1e3*c.s+("L"in c?c.L:0));if(t&&!("Z"in c)&&(c.Z=0),"p"in c&&(c.H=c.H%12+12*c.p),void 0===c.m&&(c.m="q"in c?c.q:0),"V"in c){if(c.V<1||c.V>53)return null;"w"in c||(c.w=1),"Z"in c?(l=(s=r(a(c.y,0,1))).getUTCDay(),s=l>4||0===l?n.utcMonday.ceil(s):(0,n.utcMonday)(s),s=n.utcDay.offset(s,7*(c.V-1)),c.y=s.getUTCFullYear(),c.m=s.getUTCMonth(),c.d=s.getUTCDate()+(c.w+6)%7):(l=(s=o(a(c.y,0,1))).getDay(),s=l>4||0===l?n.timeMonday.ceil(s):(0,n.timeMonday)(s),s=n.timeDay.offset(s,7*(c.V-1)),c.y=s.getFullYear(),c.m=s.getMonth(),c.d=s.getDate()+(c.w+6)%7)}else("W"in c||"U"in c)&&("w"in c||(c.w="u"in c?c.u%7:"W"in c?1:0),l="Z"in c?r(a(c.y,0,1)).getUTCDay():o(a(c.y,0,1)).getDay(),c.m=0,c.d="W"in c?(c.w+6)%7+7*c.W-(l+5)%7:c.w+7*c.U-(l+6)%7);return"Z"in c?(c.H+=c.Z/100|0,c.M+=c.Z%100,r(c)):o(c)}}function Fe(e,t,i,n){for(var o,r,a=0,l=t.length,c=i.length;a<l;){if(n>=c)return-1;if(37===(o=t.charCodeAt(a++))){if(o=t.charAt(a++),!(r=Me[o in s?t.charAt(a++):o])||(n=r(e,i,n))<0)return-1}else if(o!=i.charCodeAt(n++))return-1}return n}return Ne.x=Le(i,Ne),Ne.X=Le(l,Ne),Ne.c=Le(t,Ne),Re.x=Le(i,Re),Re.X=Le(l,Re),Re.c=Le(t,Re),{format:function(e){var t=Le(e+="",Ne);return t.toString=function(){return e},t},parse:function(e){var t=Be(e+="",!1);return t.toString=function(){return e},t},utcFormat:function(e){var t=Le(e+="",Re);return t.toString=function(){return e},t},utcParse:function(e){var t=Be(e+="",!0);return t.toString=function(){return e},t}}};var n=i(2768);function o(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function r(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function a(e,t,i){return{y:e,m:t,d:i,H:0,M:0,S:0,L:0}}var s={"-":"",_:" ",0:"0"},l=/^\s*\d+/,c=/^%/,d=/[\\^$*+?|[\]().{}]/g;function u(e,t,i){var n=e<0?"-":"",o=(n?-e:e)+"",r=o.length;return n+(r<i?new Array(i-r+1).join(t)+o:o)}function h(e){return e.replace(d,"\\$&")}function p(e){return new RegExp("^(?:"+e.map(h).join("|")+")","i")}function g(e){return new Map(e.map(((e,t)=>[e.toLowerCase(),t])))}function f(e,t,i){var n=l.exec(t.slice(i,i+1));return n?(e.w=+n[0],i+n[0].length):-1}function m(e,t,i){var n=l.exec(t.slice(i,i+1));return n?(e.u=+n[0],i+n[0].length):-1}function v(e,t,i){var n=l.exec(t.slice(i,i+2));return n?(e.U=+n[0],i+n[0].length):-1}function y(e,t,i){var n=l.exec(t.slice(i,i+2));return n?(e.V=+n[0],i+n[0].length):-1}function C(e,t,i){var n=l.exec(t.slice(i,i+2));return n?(e.W=+n[0],i+n[0].length):-1}function b(e,t,i){var n=l.exec(t.slice(i,i+4));return n?(e.y=+n[0],i+n[0].length):-1}function S(e,t,i){var n=l.exec(t.slice(i,i+2));return n?(e.y=+n[0]+(+n[0]>68?1900:2e3),i+n[0].length):-1}function x(e,t,i){var n=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(i,i+6));return n?(e.Z=n[1]?0:-(n[2]+(n[3]||"00")),i+n[0].length):-1}function T(e,t,i){var n=l.exec(t.slice(i,i+1));return n?(e.q=3*n[0]-3,i+n[0].length):-1}function w(e,t,i){var n=l.exec(t.slice(i,i+2));return n?(e.m=n[0]-1,i+n[0].length):-1}function O(e,t,i){var n=l.exec(t.slice(i,i+2));return n?(e.d=+n[0],i+n[0].length):-1}function P(e,t,i){var n=l.exec(t.slice(i,i+3));return n?(e.m=0,e.d=+n[0],i+n[0].length):-1}function A(e,t,i){var n=l.exec(t.slice(i,i+2));return n?(e.H=+n[0],i+n[0].length):-1}function E(e,t,i){var n=l.exec(t.slice(i,i+2));return n?(e.M=+n[0],i+n[0].length):-1}function k(e,t,i){var n=l.exec(t.slice(i,i+2));return n?(e.S=+n[0],i+n[0].length):-1}function I(e,t,i){var n=l.exec(t.slice(i,i+3));return n?(e.L=+n[0],i+n[0].length):-1}function D(e,t,i){var n=l.exec(t.slice(i,i+6));return n?(e.L=Math.floor(n[0]/1e3),i+n[0].length):-1}function _(e,t,i){var n=c.exec(t.slice(i,i+1));return n?i+n[0].length:-1}function N(e,t,i){var n=l.exec(t.slice(i));return n?(e.Q=+n[0],i+n[0].length):-1}function R(e,t,i){var n=l.exec(t.slice(i));return n?(e.s=+n[0],i+n[0].length):-1}function M(e,t){return u(e.getDate(),t,2)}function L(e,t){return u(e.getHours(),t,2)}function B(e,t){return u(e.getHours()%12||12,t,2)}function F(e,t){return u(1+n.timeDay.count((0,n.timeYear)(e),e),t,3)}function U(e,t){return u(e.getMilliseconds(),t,3)}function H(e,t){return U(e,t)+"000"}function $(e,t){return u(e.getMonth()+1,t,2)}function Z(e,t){return u(e.getMinutes(),t,2)}function V(e,t){return u(e.getSeconds(),t,2)}function G(e){var t=e.getDay();return 0===t?7:t}function j(e,t){return u(n.timeSunday.count((0,n.timeYear)(e)-1,e),t,2)}function z(e){var t=e.getDay();return t>=4||0===t?(0,n.timeThursday)(e):n.timeThursday.ceil(e)}function W(e,t){return e=z(e),u(n.timeThursday.count((0,n.timeYear)(e),e)+(4===(0,n.timeYear)(e).getDay()),t,2)}function K(e){return e.getDay()}function q(e,t){return u(n.timeMonday.count((0,n.timeYear)(e)-1,e),t,2)}function Y(e,t){return u(e.getFullYear()%100,t,2)}function X(e,t){return u((e=z(e)).getFullYear()%100,t,2)}function J(e,t){return u(e.getFullYear()%1e4,t,4)}function Q(e,t){var i=e.getDay();return u((e=i>=4||0===i?(0,n.timeThursday)(e):n.timeThursday.ceil(e)).getFullYear()%1e4,t,4)}function ee(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+u(t/60|0,"0",2)+u(t%60,"0",2)}function te(e,t){return u(e.getUTCDate(),t,2)}function ie(e,t){return u(e.getUTCHours(),t,2)}function ne(e,t){return u(e.getUTCHours()%12||12,t,2)}function oe(e,t){return u(1+n.utcDay.count((0,n.utcYear)(e),e),t,3)}function re(e,t){return u(e.getUTCMilliseconds(),t,3)}function ae(e,t){return re(e,t)+"000"}function se(e,t){return u(e.getUTCMonth()+1,t,2)}function le(e,t){return u(e.getUTCMinutes(),t,2)}function ce(e,t){return u(e.getUTCSeconds(),t,2)}function de(e){var t=e.getUTCDay();return 0===t?7:t}function ue(e,t){return u(n.utcSunday.count((0,n.utcYear)(e)-1,e),t,2)}function he(e){var t=e.getUTCDay();return t>=4||0===t?(0,n.utcThursday)(e):n.utcThursday.ceil(e)}function pe(e,t){return e=he(e),u(n.utcThursday.count((0,n.utcYear)(e),e)+(4===(0,n.utcYear)(e).getUTCDay()),t,2)}function ge(e){return e.getUTCDay()}function fe(e,t){return u(n.utcMonday.count((0,n.utcYear)(e)-1,e),t,2)}function me(e,t){return u(e.getUTCFullYear()%100,t,2)}function ve(e,t){return u((e=he(e)).getUTCFullYear()%100,t,2)}function ye(e,t){return u(e.getUTCFullYear()%1e4,t,4)}function Ce(e,t){var i=e.getUTCDay();return u((e=i>=4||0===i?(0,n.utcThursday)(e):n.utcThursday.ceil(e)).getUTCFullYear()%1e4,t,4)}function be(){return"+0000"}function Se(){return"%"}function xe(e){return+e}function Te(e){return Math.floor(+e/1e3)}},85534:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.days=void 0;var n,o=(n=i(87242))&&n.__esModule?n:{default:n},r=i(69861),a=(0,o.default)((e=>e.setHours(0,0,0,0)),((e,t)=>e.setDate(e.getDate()+t)),((e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*r.durationMinute)/r.durationDay),(e=>e.getDate()-1)),s=a;t.default=s;var l=a.range;t.days=l},69861:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.durationYear=t.durationWeek=t.durationSecond=t.durationMonth=t.durationMinute=t.durationHour=t.durationDay=void 0,t.durationSecond=1e3,t.durationMinute=6e4;t.durationHour=36e5;t.durationDay=864e5,t.durationWeek=6048e5,t.durationMonth=2592e6,t.durationYear=31536e6},83728:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hours=t.default=void 0;var n,o=(n=i(87242))&&n.__esModule?n:{default:n},r=i(69861),a=(0,o.default)((function(e){e.setTime(e-e.getMilliseconds()-e.getSeconds()*r.durationSecond-e.getMinutes()*r.durationMinute)}),(function(e,t){e.setTime(+e+t*r.durationHour)}),(function(e,t){return(t-e)/r.durationHour}),(function(e){return e.getHours()})),s=a;t.default=s;var l=a.range;t.hours=l},2768:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"timeDay",{enumerable:!0,get:function(){return c.default}}),Object.defineProperty(t,"timeDays",{enumerable:!0,get:function(){return c.days}}),Object.defineProperty(t,"timeFriday",{enumerable:!0,get:function(){return d.friday}}),Object.defineProperty(t,"timeFridays",{enumerable:!0,get:function(){return d.fridays}}),Object.defineProperty(t,"timeHour",{enumerable:!0,get:function(){return l.default}}),Object.defineProperty(t,"timeHours",{enumerable:!0,get:function(){return l.hours}}),Object.defineProperty(t,"timeInterval",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(t,"timeMillisecond",{enumerable:!0,get:function(){return r.default}}),Object.defineProperty(t,"timeMilliseconds",{enumerable:!0,get:function(){return r.milliseconds}}),Object.defineProperty(t,"timeMinute",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(t,"timeMinutes",{enumerable:!0,get:function(){return s.minutes}}),Object.defineProperty(t,"timeMonday",{enumerable:!0,get:function(){return d.monday}}),Object.defineProperty(t,"timeMondays",{enumerable:!0,get:function(){return d.mondays}}),Object.defineProperty(t,"timeMonth",{enumerable:!0,get:function(){return u.default}}),Object.defineProperty(t,"timeMonths",{enumerable:!0,get:function(){return u.months}}),Object.defineProperty(t,"timeSaturday",{enumerable:!0,get:function(){return d.saturday}}),Object.defineProperty(t,"timeSaturdays",{enumerable:!0,get:function(){return d.saturdays}}),Object.defineProperty(t,"timeSecond",{enumerable:!0,get:function(){return a.default}}),Object.defineProperty(t,"timeSeconds",{enumerable:!0,get:function(){return a.seconds}}),Object.defineProperty(t,"timeSunday",{enumerable:!0,get:function(){return d.sunday}}),Object.defineProperty(t,"timeSundays",{enumerable:!0,get:function(){return d.sundays}}),Object.defineProperty(t,"timeThursday",{enumerable:!0,get:function(){return d.thursday}}),Object.defineProperty(t,"timeThursdays",{enumerable:!0,get:function(){return d.thursdays}}),Object.defineProperty(t,"timeTickInterval",{enumerable:!0,get:function(){return C.timeTickInterval}}),Object.defineProperty(t,"timeTicks",{enumerable:!0,get:function(){return C.timeTicks}}),Object.defineProperty(t,"timeTuesday",{enumerable:!0,get:function(){return d.tuesday}}),Object.defineProperty(t,"timeTuesdays",{enumerable:!0,get:function(){return d.tuesdays}}),Object.defineProperty(t,"timeWednesday",{enumerable:!0,get:function(){return d.wednesday}}),Object.defineProperty(t,"timeWednesdays",{enumerable:!0,get:function(){return d.wednesdays}}),Object.defineProperty(t,"timeWeek",{enumerable:!0,get:function(){return d.sunday}}),Object.defineProperty(t,"timeWeeks",{enumerable:!0,get:function(){return d.sundays}}),Object.defineProperty(t,"timeYear",{enumerable:!0,get:function(){return h.default}}),Object.defineProperty(t,"timeYears",{enumerable:!0,get:function(){return h.years}}),Object.defineProperty(t,"utcDay",{enumerable:!0,get:function(){return f.default}}),Object.defineProperty(t,"utcDays",{enumerable:!0,get:function(){return f.utcDays}}),Object.defineProperty(t,"utcFriday",{enumerable:!0,get:function(){return m.utcFriday}}),Object.defineProperty(t,"utcFridays",{enumerable:!0,get:function(){return m.utcFridays}}),Object.defineProperty(t,"utcHour",{enumerable:!0,get:function(){return g.default}}),Object.defineProperty(t,"utcHours",{enumerable:!0,get:function(){return g.utcHours}}),Object.defineProperty(t,"utcMillisecond",{enumerable:!0,get:function(){return r.default}}),Object.defineProperty(t,"utcMilliseconds",{enumerable:!0,get:function(){return r.milliseconds}}),Object.defineProperty(t,"utcMinute",{enumerable:!0,get:function(){return p.default}}),Object.defineProperty(t,"utcMinutes",{enumerable:!0,get:function(){return p.utcMinutes}}),Object.defineProperty(t,"utcMonday",{enumerable:!0,get:function(){return m.utcMonday}}),Object.defineProperty(t,"utcMondays",{enumerable:!0,get:function(){return m.utcMondays}}),Object.defineProperty(t,"utcMonth",{enumerable:!0,get:function(){return v.default}}),Object.defineProperty(t,"utcMonths",{enumerable:!0,get:function(){return v.utcMonths}}),Object.defineProperty(t,"utcSaturday",{enumerable:!0,get:function(){return m.utcSaturday}}),Object.defineProperty(t,"utcSaturdays",{enumerable:!0,get:function(){return m.utcSaturdays}}),Object.defineProperty(t,"utcSecond",{enumerable:!0,get:function(){return a.default}}),Object.defineProperty(t,"utcSeconds",{enumerable:!0,get:function(){return a.seconds}}),Object.defineProperty(t,"utcSunday",{enumerable:!0,get:function(){return m.utcSunday}}),Object.defineProperty(t,"utcSundays",{enumerable:!0,get:function(){return m.utcSundays}}),Object.defineProperty(t,"utcThursday",{enumerable:!0,get:function(){return m.utcThursday}}),Object.defineProperty(t,"utcThursdays",{enumerable:!0,get:function(){return m.utcThursdays}}),Object.defineProperty(t,"utcTickInterval",{enumerable:!0,get:function(){return C.utcTickInterval}}),Object.defineProperty(t,"utcTicks",{enumerable:!0,get:function(){return C.utcTicks}}),Object.defineProperty(t,"utcTuesday",{enumerable:!0,get:function(){return m.utcTuesday}}),Object.defineProperty(t,"utcTuesdays",{enumerable:!0,get:function(){return m.utcTuesdays}}),Object.defineProperty(t,"utcWednesday",{enumerable:!0,get:function(){return m.utcWednesday}}),Object.defineProperty(t,"utcWednesdays",{enumerable:!0,get:function(){return m.utcWednesdays}}),Object.defineProperty(t,"utcWeek",{enumerable:!0,get:function(){return m.utcSunday}}),Object.defineProperty(t,"utcWeeks",{enumerable:!0,get:function(){return m.utcSundays}}),Object.defineProperty(t,"utcYear",{enumerable:!0,get:function(){return y.default}}),Object.defineProperty(t,"utcYears",{enumerable:!0,get:function(){return y.utcYears}});var n,o=(n=i(87242))&&n.__esModule?n:{default:n},r=S(i(47029)),a=S(i(45008)),s=S(i(21949)),l=S(i(83728)),c=S(i(85534)),d=i(88122),u=S(i(98106)),h=S(i(93421)),p=S(i(8955)),g=S(i(42990)),f=S(i(7995)),m=i(54138),v=S(i(88926)),y=S(i(62363)),C=i(8448);function b(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(b=function(e){return e?i:t})(e)}function S(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=b(t);if(i&&i.has(e))return i.get(e);var n={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var r in e)if("default"!==r&&Object.prototype.hasOwnProperty.call(e,r)){var a=o?Object.getOwnPropertyDescriptor(e,r):null;a&&(a.get||a.set)?Object.defineProperty(n,r,a):n[r]=e[r]}return n.default=e,i&&i.set(e,n),n}},87242:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(t,o,r,a){function s(e){return t(e=0===arguments.length?new Date:new Date(+e)),e}return s.floor=function(e){return t(e=new Date(+e)),e},s.ceil=function(e){return t(e=new Date(e-1)),o(e,1),t(e),e},s.round=function(e){var t=s(e),i=s.ceil(e);return e-t<i-e?t:i},s.offset=function(e,t){return o(e=new Date(+e),null==t?1:Math.floor(t)),e},s.range=function(e,i,n){var r,a=[];if(e=s.ceil(e),n=null==n?1:Math.floor(n),!(e<i&&n>0))return a;do{a.push(r=new Date(+e)),o(e,n),t(e)}while(r<e&&e<i);return a},s.filter=function(i){return e((function(e){if(e>=e)for(;t(e),!i(e);)e.setTime(e-1)}),(function(e,t){if(e>=e)if(t<0)for(;++t<=0;)for(;o(e,-1),!i(e););else for(;--t>=0;)for(;o(e,1),!i(e););}))},r&&(s.count=function(e,o){return i.setTime(+e),n.setTime(+o),t(i),t(n),Math.floor(r(i,n))},s.every=function(e){return e=Math.floor(e),isFinite(e)&&e>0?e>1?s.filter(a?function(t){return a(t)%e==0}:function(t){return s.count(0,t)%e==0}):s:null}),s};var i=new Date,n=new Date},47029:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.milliseconds=t.default=void 0;var n,o=(n=i(87242))&&n.__esModule?n:{default:n},r=(0,o.default)((function(){}),(function(e,t){e.setTime(+e+t)}),(function(e,t){return t-e}));r.every=function(e){return e=Math.floor(e),isFinite(e)&&e>0?e>1?(0,o.default)((function(t){t.setTime(Math.floor(t/e)*e)}),(function(t,i){t.setTime(+t+i*e)}),(function(t,i){return(i-t)/e})):r:null};var a=r;t.default=a;var s=r.range;t.milliseconds=s},21949:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.minutes=t.default=void 0;var n,o=(n=i(87242))&&n.__esModule?n:{default:n},r=i(69861),a=(0,o.default)((function(e){e.setTime(e-e.getMilliseconds()-e.getSeconds()*r.durationSecond)}),(function(e,t){e.setTime(+e+t*r.durationMinute)}),(function(e,t){return(t-e)/r.durationMinute}),(function(e){return e.getMinutes()})),s=a;t.default=s;var l=a.range;t.minutes=l},98106:function(e,t,i){"use strict";var n;Object.defineProperty(t,"__esModule",{value:!0}),t.months=t.default=void 0;var o=(0,((n=i(87242))&&n.__esModule?n:{default:n}).default)((function(e){e.setDate(1),e.setHours(0,0,0,0)}),(function(e,t){e.setMonth(e.getMonth()+t)}),(function(e,t){return t.getMonth()-e.getMonth()+12*(t.getFullYear()-e.getFullYear())}),(function(e){return e.getMonth()})),r=o;t.default=r;var a=o.range;t.months=a},45008:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.seconds=t.default=void 0;var n,o=(n=i(87242))&&n.__esModule?n:{default:n},r=i(69861),a=(0,o.default)((function(e){e.setTime(e-e.getMilliseconds())}),(function(e,t){e.setTime(+e+t*r.durationSecond)}),(function(e,t){return(t-e)/r.durationSecond}),(function(e){return e.getUTCSeconds()})),s=a;t.default=s;var l=a.range;t.seconds=l},8448:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.utcTicks=t.utcTickInterval=t.timeTicks=t.timeTickInterval=void 0;var n=i(55754),o=i(69861),r=C(i(47029)),a=C(i(45008)),s=C(i(21949)),l=C(i(83728)),c=C(i(85534)),d=i(88122),u=C(i(98106)),h=C(i(93421)),p=C(i(8955)),g=C(i(42990)),f=C(i(7995)),m=i(54138),v=C(i(88926)),y=C(i(62363));function C(e){return e&&e.__esModule?e:{default:e}}function b(e,t,i,s,l,c){const d=[[a.default,1,o.durationSecond],[a.default,5,5*o.durationSecond],[a.default,15,15*o.durationSecond],[a.default,30,30*o.durationSecond],[c,1,o.durationMinute],[c,5,5*o.durationMinute],[c,15,15*o.durationMinute],[c,30,30*o.durationMinute],[l,1,o.durationHour],[l,3,3*o.durationHour],[l,6,6*o.durationHour],[l,12,12*o.durationHour],[s,1,o.durationDay],[s,2,2*o.durationDay],[i,1,o.durationWeek],[t,1,o.durationMonth],[t,3,3*o.durationMonth],[e,1,o.durationYear]];function u(t,i,a){const s=Math.abs(i-t)/a,l=(0,n.bisector)((([,,e])=>e)).right(d,s);if(l===d.length)return e.every((0,n.tickStep)(t/o.durationYear,i/o.durationYear,a));if(0===l)return r.default.every(Math.max((0,n.tickStep)(t,i,a),1));const[c,u]=d[s/d[l-1][2]<d[l][2]/s?l-1:l];return c.every(u)}return[function(e,t,i){const n=t<e;n&&([e,t]=[t,e]);const o=i&&"function"==typeof i.range?i:u(e,t,i),r=o?o.range(e,+t+1):[];return n?r.reverse():r},u]}const[S,x]=b(y.default,v.default,m.utcSunday,f.default,g.default,p.default);t.utcTickInterval=x,t.utcTicks=S;const[T,w]=b(h.default,u.default,d.sunday,c.default,l.default,s.default);t.timeTickInterval=w,t.timeTicks=T},7995:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.utcDays=t.default=void 0;var n,o=(n=i(87242))&&n.__esModule?n:{default:n},r=i(69861),a=(0,o.default)((function(e){e.setUTCHours(0,0,0,0)}),(function(e,t){e.setUTCDate(e.getUTCDate()+t)}),(function(e,t){return(t-e)/r.durationDay}),(function(e){return e.getUTCDate()-1})),s=a;t.default=s;var l=a.range;t.utcDays=l},42990:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.utcHours=t.default=void 0;var n,o=(n=i(87242))&&n.__esModule?n:{default:n},r=i(69861),a=(0,o.default)((function(e){e.setUTCMinutes(0,0,0)}),(function(e,t){e.setTime(+e+t*r.durationHour)}),(function(e,t){return(t-e)/r.durationHour}),(function(e){return e.getUTCHours()})),s=a;t.default=s;var l=a.range;t.utcHours=l},8955:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.utcMinutes=t.default=void 0;var n,o=(n=i(87242))&&n.__esModule?n:{default:n},r=i(69861),a=(0,o.default)((function(e){e.setUTCSeconds(0,0)}),(function(e,t){e.setTime(+e+t*r.durationMinute)}),(function(e,t){return(t-e)/r.durationMinute}),(function(e){return e.getUTCMinutes()})),s=a;t.default=s;var l=a.range;t.utcMinutes=l},88926:function(e,t,i){"use strict";var n;Object.defineProperty(t,"__esModule",{value:!0}),t.utcMonths=t.default=void 0;var o=(0,((n=i(87242))&&n.__esModule?n:{default:n}).default)((function(e){e.setUTCDate(1),e.setUTCHours(0,0,0,0)}),(function(e,t){e.setUTCMonth(e.getUTCMonth()+t)}),(function(e,t){return t.getUTCMonth()-e.getUTCMonth()+12*(t.getUTCFullYear()-e.getUTCFullYear())}),(function(e){return e.getUTCMonth()})),r=o;t.default=r;var a=o.range;t.utcMonths=a},54138:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.utcWednesdays=t.utcWednesday=t.utcTuesdays=t.utcTuesday=t.utcThursdays=t.utcThursday=t.utcSundays=t.utcSunday=t.utcSaturdays=t.utcSaturday=t.utcMondays=t.utcMonday=t.utcFridays=t.utcFriday=void 0;var n,o=(n=i(87242))&&n.__esModule?n:{default:n},r=i(69861);function a(e){return(0,o.default)((function(t){t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)}),(function(e,t){e.setUTCDate(e.getUTCDate()+7*t)}),(function(e,t){return(t-e)/r.durationWeek}))}var s=a(0);t.utcSunday=s;var l=a(1);t.utcMonday=l;var c=a(2);t.utcTuesday=c;var d=a(3);t.utcWednesday=d;var u=a(4);t.utcThursday=u;var h=a(5);t.utcFriday=h;var p=a(6);t.utcSaturday=p;var g=s.range;t.utcSundays=g;var f=l.range;t.utcMondays=f;var m=c.range;t.utcTuesdays=m;var v=d.range;t.utcWednesdays=v;var y=u.range;t.utcThursdays=y;var C=h.range;t.utcFridays=C;var b=p.range;t.utcSaturdays=b},62363:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.utcYears=t.default=void 0;var n,o=(n=i(87242))&&n.__esModule?n:{default:n},r=(0,o.default)((function(e){e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)}),(function(e,t){e.setUTCFullYear(e.getUTCFullYear()+t)}),(function(e,t){return t.getUTCFullYear()-e.getUTCFullYear()}),(function(e){return e.getUTCFullYear()}));r.every=function(e){return isFinite(e=Math.floor(e))&&e>0?(0,o.default)((function(t){t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)}),(function(t,i){t.setUTCFullYear(t.getUTCFullYear()+i*e)})):null};var a=r;t.default=a;var s=r.range;t.utcYears=s},88122:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.wednesdays=t.wednesday=t.tuesdays=t.tuesday=t.thursdays=t.thursday=t.sundays=t.sunday=t.saturdays=t.saturday=t.mondays=t.monday=t.fridays=t.friday=void 0;var n,o=(n=i(87242))&&n.__esModule?n:{default:n},r=i(69861);function a(e){return(0,o.default)((function(t){t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)}),(function(e,t){e.setDate(e.getDate()+7*t)}),(function(e,t){return(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*r.durationMinute)/r.durationWeek}))}var s=a(0);t.sunday=s;var l=a(1);t.monday=l;var c=a(2);t.tuesday=c;var d=a(3);t.wednesday=d;var u=a(4);t.thursday=u;var h=a(5);t.friday=h;var p=a(6);t.saturday=p;var g=s.range;t.sundays=g;var f=l.range;t.mondays=f;var m=c.range;t.tuesdays=m;var v=d.range;t.wednesdays=v;var y=u.range;t.thursdays=y;var C=h.range;t.fridays=C;var b=p.range;t.saturdays=b},93421:function(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.years=t.default=void 0;var n,o=(n=i(87242))&&n.__esModule?n:{default:n},r=(0,o.default)((function(e){e.setMonth(0,1),e.setHours(0,0,0,0)}),(function(e,t){e.setFullYear(e.getFullYear()+t)}),(function(e,t){return t.getFullYear()-e.getFullYear()}),(function(e){return e.getFullYear()}));r.every=function(e){return isFinite(e=Math.floor(e))&&e>0?(0,o.default)((function(t){t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)}),(function(t,i){t.setFullYear(t.getFullYear()+i*e)})):null};var a=r;t.default=a;var s=r.range;t.years=s},58913:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.InternSet=t.InternMap=void 0;class i extends Map{constructor(e,t=s){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:t}}),null!=e)for(const[t,i]of e)this.set(t,i)}get(e){return super.get(o(this,e))}has(e){return super.has(o(this,e))}set(e,t){return super.set(r(this,e),t)}delete(e){return super.delete(a(this,e))}}t.InternMap=i;class n extends Set{constructor(e,t=s){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:t}}),null!=e)for(const t of e)this.add(t)}has(e){return super.has(o(this,e))}add(e){return super.add(r(this,e))}delete(e){return super.delete(a(this,e))}}function o({_intern:e,_key:t},i){const n=t(i);return e.has(n)?e.get(n):i}function r({_intern:e,_key:t},i){const n=t(i);return e.has(n)?e.get(n):(e.set(n,i),i)}function a({_intern:e,_key:t},i){const n=t(i);return e.has(n)&&(i=e.get(n),e.delete(n)),i}function s(e){return null!==e&&"object"==typeof e?e.valueOf():e}t.InternSet=n},53527:function(e,t,i){e.exports=i(63528)},74895:function(e,t,i){e.exports=i(18461)},19097:function(e){e.exports=function(e){return e&&e.__esModule?e:{default:e}},e.exports.__esModule=!0,e.exports.default=e.exports},72370:function(e,t,i){"use strict";i.d(t,{Z:function(){return o}});var n=i(39316);function o(e,t,i){return(t=(0,n.Z)(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}},82387:function(e,t,i){"use strict";i.d(t,{Z:function(){return o}});var n=i(25039);function o(e,t){if("object"!==(0,n.Z)(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var o=i.call(e,t||"default");if("object"!==(0,n.Z)(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}},39316:function(e,t,i){"use strict";i.d(t,{Z:function(){return r}});var n=i(25039),o=i(82387);function r(e){var t=(0,o.Z)(e,"string");return"symbol"===(0,n.Z)(t)?t:String(t)}},25039:function(e,t,i){"use strict";function n(e){return n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},n(e)}i.d(t,{Z:function(){return n}})},56263:function(e,t,i){"use strict";let n;i.r(t),i.d(t,{BaseDefinition:function(){return eg},BaseStyles:function(){return Qp},BaseTemplate:function(){return Jp},BuyingOptions:function(){return og},BuyingOptionsAppearance:function(){return Fu},BuyingOptionsBase:function(){return Yp},BuyingOptionsDefinition:function(){return sg},BuyingOptionsLayout:function(){return Bu},BuyingOptionsStyles:function(){return ag},BuyingOptionsTemplate:function(){return rg},FilterGroup:function(){return Dt},FilterGroupDefinition:function(){return Lu},FilterGroupDirection:function(){return At},FilterGroupStyles:function(){return Ru},FilterGroupTemplate:function(){return Xr},MetadataItemDefinition:function(){return jp},MetadataItemIcon:function(){return Dp},MetadataItemIconAppearance:function(){return _p},MetadataItemStyles:function(){return Vp},MetadataItemTemplate:function(){return Gp},RetailerItemDefinition:function(){return Wp},RetailerItemStyles:function(){return Ip},RetailerItemTemplate:function(){return zp},RetailerListDefinition:function(){return qp},RetailerListStyles:function(){return Vu},RetailerListTemplate:function(){return Kp}});const o="fast-kernel";try{if(document.currentScript)n=document.currentScript.getAttribute(o);else{const e=document.getElementsByTagName("script");n=e[e.length-1].getAttribute(o)}}catch(e){n="isolate"}let r;switch(n){case"share":r=Object.freeze({updateQueue:1,observable:2,contextEvent:3,elementRegistry:4});break;case"share-v2":r=Object.freeze({updateQueue:1.2,observable:2.2,contextEvent:3.2,elementRegistry:4.2});break;default:const e=`-${Math.random().toString(36).substring(2,8)}`;r=Object.freeze({updateQueue:`1.2${e}`,observable:`2.2${e}`,contextEvent:`3.2${e}`,elementRegistry:`4.2${e}`})}const a=e=>"function"==typeof e,s=e=>"string"==typeof e,l=()=>{};var c="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};!function(){if("undefined"==typeof globalThis)if(void 0!==c)c.globalThis=c;else if("undefined"!=typeof self)self.globalThis=self;else if("undefined"!=typeof window)window.globalThis=window;else{const e=new Function("return this")();e.globalThis=e}}();const d={configurable:!1,enumerable:!1,writable:!1};void 0===globalThis.FAST&&Reflect.defineProperty(globalThis,"FAST",Object.assign({value:Object.create(null)},d));const u=globalThis.FAST;if(void 0===u.getById){const e=Object.create(null);Reflect.defineProperty(u,"getById",Object.assign({value(t,i){let n=e[t];return void 0===n&&(n=i?e[t]=i():null),n}},d))}void 0===u.error&&Object.assign(u,{warn(){},error(e){return new Error(`Error ${e}`)},addMessages(){}});const h=Object.freeze([]);function p(){const e=new Map;return Object.freeze({register(t){return!e.has(t.type)&&(e.set(t.type,t),!0)},getByType(t){return e.get(t)},getForInstance(t){if(null!=t)return e.get(t.constructor)}})}function g(){const e=new WeakMap;return function(t){let i=e.get(t);if(void 0===i){let n=Reflect.getPrototypeOf(t);for(;void 0===i&&null!==n;)i=e.get(n),n=Reflect.getPrototypeOf(n);i=void 0===i?[]:i.slice(0),e.set(t,i)}return i}}function f(e){e.prototype.toJSON=l}const m=Object.freeze({none:0,attribute:1,booleanAttribute:2,property:3,content:4,tokenList:5,event:6}),v=e=>e,y=globalThis.trustedTypes?globalThis.trustedTypes.createPolicy("fast-html",{createHTML:v}):{createHTML:v};let C=Object.freeze({createHTML(e){return y.createHTML(e)},protect(e,t,i,n){return n}});const b=C,S=Object.freeze({get policy(){return C},setPolicy(e){if(C!==b)throw u.error(1201);C=e},setAttribute(e,t,i){null==i?e.removeAttribute(t):e.setAttribute(t,i)},setBooleanAttribute(e,t,i){i?e.setAttribute(t,""):e.removeAttribute(t)}}),x=u.getById(r.updateQueue,(()=>{const e=[],t=[],i=globalThis.requestAnimationFrame;let n=!0;function o(){if(t.length)throw t.shift()}function r(i){try{i.call()}catch(i){if(!n)throw e.length=0,i;t.push(i),setTimeout(o,0)}}function a(){let t=0;for(;t<e.length;)if(r(e[t]),t++,t>1024){for(let i=0,n=e.length-t;i<n;i++)e[i]=e[i+t];e.length-=t,t=0}e.length=0}function s(t){e.push(t),e.length<2&&(n?i(a):a())}return Object.freeze({enqueue:s,next:()=>new Promise(s),process:a,setMode:e=>n=e})}));let T=class{constructor(e,t){this.sub1=void 0,this.sub2=void 0,this.spillover=void 0,this.subject=e,this.sub1=t}has(e){return void 0===this.spillover?this.sub1===e||this.sub2===e:-1!==this.spillover.indexOf(e)}subscribe(e){const t=this.spillover;if(void 0===t){if(this.has(e))return;if(void 0===this.sub1)return void(this.sub1=e);if(void 0===this.sub2)return void(this.sub2=e);this.spillover=[this.sub1,this.sub2,e],this.sub1=void 0,this.sub2=void 0}else-1===t.indexOf(e)&&t.push(e)}unsubscribe(e){const t=this.spillover;if(void 0===t)this.sub1===e?this.sub1=void 0:this.sub2===e&&(this.sub2=void 0);else{const i=t.indexOf(e);-1!==i&&t.splice(i,1)}}notify(e){const t=this.spillover,i=this.subject;if(void 0===t){const t=this.sub1,n=this.sub2;void 0!==t&&t.handleChange(i,e),void 0!==n&&n.handleChange(i,e)}else for(let n=0,o=t.length;n<o;++n)t[n].handleChange(i,e)}},w=class{constructor(e){this.subscribers={},this.subjectSubscribers=null,this.subject=e}notify(e){var t,i;null===(t=this.subscribers[e])||void 0===t||t.notify(e),null===(i=this.subjectSubscribers)||void 0===i||i.notify(e)}subscribe(e,t){var i,n;let o;o=t?null!==(i=this.subscribers[t])&&void 0!==i?i:this.subscribers[t]=new T(this.subject):null!==(n=this.subjectSubscribers)&&void 0!==n?n:this.subjectSubscribers=new T(this.subject),o.subscribe(e)}unsubscribe(e,t){var i,n;t?null===(i=this.subscribers[t])||void 0===i||i.unsubscribe(e):null===(n=this.subjectSubscribers)||void 0===n||n.unsubscribe(e)}};const O=Object.freeze({unknown:void 0,coupled:1}),P=u.getById(r.observable,(()=>{const e=x.enqueue,t=/(:|&&|\|\||if|\?\.)/,i=new WeakMap;let n,o=e=>{throw u.error(1101)};function r(e){var t;let n=null!==(t=e.$fastController)&&void 0!==t?t:i.get(e);return void 0===n&&(Array.isArray(e)?n=o(e):i.set(e,n=new w(e))),n}const l=g();class c{constructor(e){this.name=e,this.field=`_${e}`,this.callback=`${e}Changed`}getValue(e){return void 0!==n&&n.watch(e,this.name),e[this.field]}setValue(e,t){const i=this.field,n=e[i];if(n!==t){e[i]=t;const o=e[this.callback];a(o)&&o.call(e,n,t),r(e).notify(this.name)}}}class d extends T{constructor(e,t,i=!1){super(e,t),this.expression=e,this.isVolatileBinding=i,this.needsRefresh=!0,this.needsQueue=!0,this.isAsync=!0,this.first=this,this.last=null,this.propertySource=void 0,this.propertyName=void 0,this.notifier=void 0,this.next=void 0}setMode(e){this.isAsync=this.needsQueue=e}bind(e){this.controller=e;const t=this.observe(e.source,e.context);return!e.isBound&&this.requiresUnbind(e)&&e.onUnbind(this),t}requiresUnbind(e){return e.sourceLifetime!==O.coupled||this.first!==this.last||this.first.propertySource!==e.source}unbind(e){this.dispose()}observe(e,t){this.needsRefresh&&null!==this.last&&this.dispose();const i=n;let o;n=this.needsRefresh?this:void 0,this.needsRefresh=this.isVolatileBinding;try{o=this.expression(e,t)}finally{n=i}return o}disconnect(){this.dispose()}dispose(){if(null!==this.last){let e=this.first;for(;void 0!==e;)e.notifier.unsubscribe(this,e.propertyName),e=e.next;this.last=null,this.needsRefresh=this.needsQueue=this.isAsync}}watch(e,t){const i=this.last,o=r(e),a=null===i?this.first:{};if(a.propertySource=e,a.propertyName=t,a.notifier=o,o.subscribe(this,t),null!==i){if(!this.needsRefresh){let t;n=void 0,t=i.propertySource[i.propertyName],n=this,e===t&&(this.needsRefresh=!0)}i.next=a}this.last=a}handleChange(){this.needsQueue?(this.needsQueue=!1,e(this)):this.isAsync||this.call()}call(){null!==this.last&&(this.needsQueue=this.isAsync,this.notify(this))}*records(){let e=this.first;for(;void 0!==e;)yield e,e=e.next}}return f(d),Object.freeze({setArrayObserverFactory(e){o=e},getNotifier:r,track(e,t){n&&n.watch(e,t)},trackVolatile(){n&&(n.needsRefresh=!0)},notify(e,t){r(e).notify(t)},defineProperty(e,t){s(t)&&(t=new c(t)),l(e).push(t),Reflect.defineProperty(e,t.name,{enumerable:!0,get(){return t.getValue(this)},set(e){t.setValue(this,e)}})},getAccessors:l,binding(e,t,i=this.isVolatileBinding(e)){return new d(e,t,i)},isVolatileBinding(e){return t.test(e.toString())}})}));function A(e,t){P.defineProperty(e,t)}function E(e,t,i){return Object.assign({},i,{get(){return P.trackVolatile(),i.get.apply(this)}})}const k=u.getById(r.contextEvent,(()=>{let e=null;return{get(){return e},set(t){e=t}}})),I=Object.freeze({default:{index:0,length:0,get event(){return I.getEvent()},eventDetail(){return this.event.detail},eventTarget(){return this.event.target}},getEvent(){return k.get()},setEvent(e){k.set(e)}});let D=class{constructor(e,t,i){this.index=e,this.removed=t,this.addedCount=i}adjustTo(e){let t=this.index;const i=e.length;return t>i?t=i-this.addedCount:t<0&&(t=i+this.removed.length+t-this.addedCount),this.index=t<0?0:t,this}};const _=Object.freeze({reset:1,splice:2,optimized:3}),N=new D(0,h,0);N.reset=!0;const R=[N];function M(e,t,i,n,o,r){let a=0,s=0;const l=Math.min(i-t,r-o);if(0===t&&0===o&&(a=function(e,t,i){for(let n=0;n<i;++n)if(e[n]!==t[n])return n;return i}(e,n,l)),i===e.length&&r===n.length&&(s=function(e,t,i){let n=e.length,o=t.length,r=0;for(;r<i&&e[--n]===t[--o];)r++;return r}(e,n,l-a)),o+=a,r-=s,(i-=s)-(t+=a)==0&&r-o==0)return h;if(t===i){const e=new D(t,[],0);for(;o<r;)e.removed.push(n[o++]);return[e]}if(o===r)return[new D(t,[],i-t)];const c=function(e){let t=e.length-1,i=e[0].length-1,n=e[t][i];const o=[];for(;t>0||i>0;){if(0===t){o.push(2),i--;continue}if(0===i){o.push(3),t--;continue}const r=e[t-1][i-1],a=e[t-1][i],s=e[t][i-1];let l;l=a<s?a<r?a:r:s<r?s:r,l===r?(r===n?o.push(0):(o.push(1),n=r),t--,i--):l===a?(o.push(3),t--,n=a):(o.push(2),i--,n=s)}return o.reverse()}(function(e,t,i,n,o,r){const a=r-o+1,s=i-t+1,l=new Array(a);let c,d;for(let e=0;e<a;++e)l[e]=new Array(s),l[e][0]=e;for(let e=0;e<s;++e)l[0][e]=e;for(let i=1;i<a;++i)for(let r=1;r<s;++r)e[t+r-1]===n[o+i-1]?l[i][r]=l[i-1][r-1]:(c=l[i-1][r]+1,d=l[i][r-1]+1,l[i][r]=c<d?c:d);return l}(e,t,i,n,o,r)),d=[];let u,p=t,g=o;for(let e=0;e<c.length;++e)switch(c[e]){case 0:void 0!==u&&(d.push(u),u=void 0),p++,g++;break;case 1:void 0===u&&(u=new D(p,[],0)),u.addedCount++,p++,u.removed.push(n[g]),g++;break;case 2:void 0===u&&(u=new D(p,[],0)),u.addedCount++,p++;break;case 3:void 0===u&&(u=new D(p,[],0)),u.removed.push(n[g]),g++}return void 0!==u&&d.push(u),d}function L(e,t){let i=!1,n=0;for(let l=0;l<t.length;l++){const c=t[l];if(c.index+=n,i)continue;const d=(o=e.index,r=e.index+e.removed.length,a=c.index,s=c.index+c.addedCount,r<a||s<o?-1:r===a||s===o?0:o<a?r<s?r-a:s-a:s<r?s-o:r-o);if(d>=0){t.splice(l,1),l--,n-=c.addedCount-c.removed.length,e.addedCount+=c.addedCount-d;const o=e.removed.length+c.removed.length-d;if(e.addedCount||o){let t=c.removed;if(e.index<c.index){const i=e.removed.slice(0,c.index-e.index);i.push(...t),t=i}if(e.index+e.removed.length>c.index+c.addedCount){const i=e.removed.slice(c.index+c.addedCount-e.index);t.push(...i)}e.removed=t,c.index<e.index&&(e.index=c.index)}else i=!0}else if(e.index<c.index){i=!0,t.splice(l,0,e),l++;const o=e.addedCount-e.removed.length;c.index+=o,n+=o}}var o,r,a,s;i||t.push(e)}let B=Object.freeze({support:_.optimized,normalize(e,t,i){return void 0===e?void 0===i?h:function(e,t){let i=[];const n=[];for(let e=0,i=t.length;e<i;e++)L(t[e],n);for(let t=0,o=n.length;t<o;++t){const o=n[t];1!==o.addedCount||1!==o.removed.length?i=i.concat(M(e,o.index,o.index+o.addedCount,o.removed,0,o.removed.length)):o.removed[0]!==e[o.index]&&i.push(o)}return i}(t,i):R},pop(e,t,i,n){const o=e.length>0,r=i.apply(e,n);return o&&t.addSplice(new D(e.length,[r],0)),r},push(e,t,i,n){const o=i.apply(e,n);return t.addSplice(new D(e.length-n.length,[],n.length).adjustTo(e)),o},reverse(e,t,i,n){const o=i.apply(e,n);return t.reset(e),o},shift(e,t,i,n){const o=e.length>0,r=i.apply(e,n);return o&&t.addSplice(new D(0,[r],0)),r},sort(e,t,i,n){const o=i.apply(e,n);return t.reset(e),o},splice(e,t,i,n){const o=i.apply(e,n);return t.addSplice(new D(+n[0],o,n.length>2?n.length-2:0).adjustTo(e)),o},unshift(e,t,i,n){const o=i.apply(e,n);return t.addSplice(new D(0,[],n.length).adjustTo(e)),o}});function F(e,t,i){Reflect.defineProperty(e,t,{value:i,enumerable:!1})}let U=class extends T{constructor(e){super(e),this.oldCollection=void 0,this.splices=void 0,this.needsQueue=!0,this._strategy=null,this._lengthObserver=void 0,this.call=this.flush,F(e,"$fastController",this)}get strategy(){return this._strategy}set strategy(e){this._strategy=e}get lengthObserver(){let e=this._lengthObserver;if(void 0===e){const t=this.subject;this._lengthObserver=e={length:t.length,handleChange(){this.length!==t.length&&(this.length=t.length,P.notify(e,"length"))}},this.subscribe(e)}return e}subscribe(e){this.flush(),super.subscribe(e)}addSplice(e){void 0===this.splices?this.splices=[e]:this.splices.push(e),this.enqueue()}reset(e){this.oldCollection=e,this.enqueue()}flush(){var e;const t=this.splices,i=this.oldCollection;void 0===t&&void 0===i||(this.needsQueue=!0,this.splices=void 0,this.oldCollection=void 0,this.notify((null!==(e=this._strategy)&&void 0!==e?e:B).normalize(i,this.subject,t)))}enqueue(){this.needsQueue&&(this.needsQueue=!1,x.enqueue(this))}},H=!1;const $=Object.freeze({enable(){if(H)return;H=!0,P.setArrayObserverFactory((e=>new U(e)));const e=Array.prototype;e.$fastPatch||(F(e,"$fastPatch",1),[e.pop,e.push,e.reverse,e.shift,e.sort,e.splice,e.unshift].forEach((t=>{e[t.name]=function(...e){var i;const n=this.$fastController;return void 0===n?t.apply(this,e):(null!==(i=n.strategy)&&void 0!==i?i:B)[t.name](this,n,t,e)}})))}});let Z=class{constructor(e,t,i=!1){this.evaluate=e,this.policy=t,this.isVolatile=i}},V=class extends Z{createObserver(e){return P.binding(this.evaluate,e,this.isVolatile)}};function G(e,t,i=P.isVolatileBinding(e)){return new V(e,t,i)}let j,z=class extends Z{createObserver(){return this}bind(e){return this.evaluate(e.source,e.context)}};function W(e,t){return new z(e,t)}function K(e){return a(e)?G(e):e instanceof Z?e:W((()=>e))}function q(e){return e.map((e=>e instanceof Y?q(e.styles):[e])).reduce(((e,t)=>e.concat(t)),[])}f(z);let Y=class e{constructor(t){this.styles=t,this.targets=new WeakSet,this._strategy=null,this.behaviors=t.map((t=>t instanceof e?t.behaviors:null)).reduce(((e,t)=>null===t?e:null===e?t:e.concat(t)),null)}get strategy(){return null===this._strategy&&this.withStrategy(j),this._strategy}addStylesTo(e){this.strategy.addStylesTo(e),this.targets.add(e)}removeStylesFrom(e){this.strategy.removeStylesFrom(e),this.targets.delete(e)}isAttachedTo(e){return this.targets.has(e)}withBehaviors(...e){return this.behaviors=null===this.behaviors?e:this.behaviors.concat(e),this}withStrategy(e){return this._strategy=new e(q(this.styles)),this}static setDefaultStrategy(e){j=e}static normalize(t){return void 0===t?void 0:Array.isArray(t)?new e(t):t instanceof e?t:new e([t])}};Y.supportsAdoptedStyleSheets=Array.isArray(document.adoptedStyleSheets)&&"replace"in CSSStyleSheet.prototype;const X=p(),J=Object.freeze({getForInstance:X.getForInstance,getByType:X.getByType,define(e){return X.register({type:e}),e}});function Q(e,t,i){t.source.style.setProperty(e.targetAspect,i.bind(t))}let ee=class{constructor(e,t){this.dataBinding=e,this.targetAspect=t}createCSS(e){return e(this),`var(${this.targetAspect})`}addedCallback(e){var t;const i=e.source;if(!i.$cssBindings){i.$cssBindings=new Map;const e=i.setAttribute;i.setAttribute=(t,n)=>{e.call(i,t,n),"style"===t&&i.$cssBindings.forEach(((e,t)=>Q(t,e.controller,e.observer)))}}const n=null!==(t=e[this.targetAspect])&&void 0!==t?t:e[this.targetAspect]=this.dataBinding.createObserver(this,this);n.controller=e,e.source.$cssBindings.set(this,{controller:e,observer:n})}connectedCallback(e){Q(this,e,e[this.targetAspect])}removedCallback(e){e.source.$cssBindings&&e.source.$cssBindings.delete(this)}handleChange(e,t){Q(this,t.controller,t)}};J.define(ee);const te=`${Math.random().toString(36).substring(2,8)}`;let ie=0;const ne=()=>`--v${te}${++ie}`;function oe(e,t){const i=[];let n="";const o=[],r=e=>{o.push(e)};for(let o=0,s=e.length-1;o<s;++o){n+=e[o];let s=t[o];a(s)?s=new ee(G(s),ne()).createCSS(r):s instanceof Z?s=new ee(s,ne()).createCSS(r):void 0!==J.getForInstance(s)&&(s=s.createCSS(r)),s instanceof Y||s instanceof CSSStyleSheet?(""!==n.trim()&&(i.push(n),n=""),i.push(s)):n+=s}return n+=e[e.length-1],""!==n.trim()&&i.push(n),{styles:i,behaviors:o}}const re=(e,...t)=>{const{styles:i,behaviors:n}=oe(e,t),o=new Y(i);return n.length?o.withBehaviors(...n):o};let ae=class{constructor(e,t){this.behaviors=t,this.css="";const i=e.reduce(((e,t)=>(s(t)?this.css+=t:e.push(t),e)),[]);i.length&&(this.styles=new Y(i))}createCSS(e){return this.behaviors.forEach(e),this.styles&&e(this),this.css}addedCallback(e){e.addStyles(this.styles)}removedCallback(e){e.removeStyles(this.styles)}};J.define(ae),re.partial=(e,...t)=>{const{styles:i,behaviors:n}=oe(e,t);return new ae(i,n)};const se=`fast-${Math.random().toString(36).substring(2,8)}`,le=`${se}{`,ce=`}${se}`,de=ce.length;let ue=0;const he=()=>`${se}-${++ue}`,pe=Object.freeze({interpolation:e=>`${le}${e}${ce}`,attribute:e=>`${he()}="${le}${e}${ce}"`,comment:e=>`\x3c!--${le}${e}${ce}--\x3e`}),ge=Object.freeze({parse(e,t){const i=e.split(le);if(1===i.length)return null;const n=[];for(let e=0,o=i.length;e<o;++e){const o=i[e],r=o.indexOf(ce);let a;if(-1===r)a=o;else{const e=o.substring(0,r);n.push(t[e]),a=o.substring(r+de)}""!==a&&n.push(a)}return n}}),fe=p(),me=Object.freeze({getForInstance:fe.getForInstance,getByType:fe.getByType,define(e,t){return(t=t||{}).type=e,fe.register(t),e},assignAspect(e,t){if(t)switch(e.sourceAspect=t,t[0]){case":":e.targetAspect=t.substring(1),e.aspectType="classList"===e.targetAspect?m.tokenList:m.property;break;case"?":e.targetAspect=t.substring(1),e.aspectType=m.booleanAttribute;break;case"@":e.targetAspect=t.substring(1),e.aspectType=m.event;break;default:e.targetAspect=t,e.aspectType=m.attribute}else e.aspectType=m.content}});let ve=class{constructor(e){this.options=e}createHTML(e){return pe.attribute(e(this))}createBehavior(){return this}};f(ve);const ye={[m.attribute]:S.setAttribute,[m.booleanAttribute]:S.setBooleanAttribute,[m.property]:(e,t,i)=>e[t]=i,[m.content]:function(e,t,i,n){if(null==i&&(i=""),i.create){e.textContent="";let t=e.$fastView;void 0===t?t=i.create():e.$fastTemplate!==i&&(t.isComposed&&(t.remove(),t.unbind()),t=i.create()),t.isComposed?t.needsBindOnly&&(t.needsBindOnly=!1,t.bind(n.source,n.context)):(t.isComposed=!0,t.bind(n.source,n.context),t.insertBefore(e),e.$fastView=t,e.$fastTemplate=i)}else{const t=e.$fastView;void 0!==t&&t.isComposed&&(t.isComposed=!1,t.remove(),t.needsBindOnly?t.needsBindOnly=!1:t.unbind()),e.textContent=i}},[m.tokenList]:function(e,t,i){var n;const o=`${this.id}-t`,r=null!==(n=e[o])&&void 0!==n?n:e[o]={v:0,cv:Object.create(null)},a=r.cv;let s=r.v;const l=e[t];if(null!=i&&i.length){const e=i.split(/\s+/);for(let t=0,i=e.length;t<i;++t){const i=e[t];""!==i&&(a[i]=s,l.add(i))}}if(r.v=s+1,0!==s){s-=1;for(const e in a)a[e]===s&&l.remove(e)}},[m.event]:()=>{}};let Ce=class{constructor(e){this.dataBinding=e,this.updateTarget=null,this.aspectType=m.content}createHTML(e){return pe.interpolation(e(this))}createBehavior(){var e;if(null===this.updateTarget){const t=ye[this.aspectType],i=null!==(e=this.dataBinding.policy)&&void 0!==e?e:this.policy;if(!t)throw u.error(1205);this.data=`${this.id}-d`,this.updateTarget=i.protect(this.targetTagName,this.aspectType,this.targetAspect,t)}return this}bind(e){var t;const i=e.targets[this.targetNodeId];switch(this.aspectType){case m.event:i[this.data]=e,i.addEventListener(this.targetAspect,this,this.dataBinding.options);break;case m.content:e.onUnbind(this);default:const n=null!==(t=i[this.data])&&void 0!==t?t:i[this.data]=this.dataBinding.createObserver(this,this);n.target=i,n.controller=e,this.updateTarget(i,this.targetAspect,n.bind(e),e)}}unbind(e){const t=e.targets[this.targetNodeId].$fastView;void 0!==t&&t.isComposed&&(t.unbind(),t.needsBindOnly=!0)}handleEvent(e){const t=e.currentTarget[this.data];if(t.isBound){I.setEvent(e);const i=this.dataBinding.evaluate(t.source,t.context);I.setEvent(null),!0!==i&&e.preventDefault()}}handleChange(e,t){const i=t.target,n=t.controller;this.updateTarget(i,this.targetAspect,t.bind(n),n)}};function be(e,t){const i=e.parentNode;let n,o=e;for(;o!==t;)n=o.nextSibling,i.removeChild(o),o=n;i.removeChild(t)}me.define(Ce,{aspected:!0});let Se=class{constructor(e,t,i){this.fragment=e,this.factories=t,this.targets=i,this.behaviors=null,this.unbindables=[],this.source=null,this.isBound=!1,this.sourceLifetime=O.unknown,this.context=this,this.index=0,this.length=0,this.firstChild=e.firstChild,this.lastChild=e.lastChild}get event(){return I.getEvent()}get isEven(){return this.index%2==0}get isOdd(){return this.index%2!=0}get isFirst(){return 0===this.index}get isInMiddle(){return!this.isFirst&&!this.isLast}get isLast(){return this.index===this.length-1}eventDetail(){return this.event.detail}eventTarget(){return this.event.target}appendTo(e){e.appendChild(this.fragment)}insertBefore(e){if(this.fragment.hasChildNodes())e.parentNode.insertBefore(this.fragment,e);else{const t=this.lastChild;if(e.previousSibling===t)return;const i=e.parentNode;let n,o=this.firstChild;for(;o!==t;)n=o.nextSibling,i.insertBefore(o,e),o=n;i.insertBefore(t,e)}}remove(){const e=this.fragment,t=this.lastChild;let i,n=this.firstChild;for(;n!==t;)i=n.nextSibling,e.appendChild(n),n=i;e.appendChild(t)}dispose(){be(this.firstChild,this.lastChild),this.unbind()}onUnbind(e){this.unbindables.push(e)}bind(e,t=this){if(this.source===e)return;let i=this.behaviors;if(null===i){this.source=e,this.context=t,this.behaviors=i=new Array(this.factories.length);const n=this.factories;for(let e=0,t=n.length;e<t;++e){const t=n[e].createBehavior();t.bind(this),i[e]=t}}else{null!==this.source&&this.evaluateUnbindables(),this.isBound=!1,this.source=e,this.context=t;for(let e=0,t=i.length;e<t;++e)i[e].bind(this)}this.isBound=!0}unbind(){this.isBound&&null!==this.source&&(this.evaluateUnbindables(),this.source=null,this.context=this,this.isBound=!1)}evaluateUnbindables(){const e=this.unbindables;for(let t=0,i=e.length;t<i;++t)e[t].unbind(this);e.length=0}static disposeContiguousBatch(e){if(0!==e.length){be(e[0].firstChild,e[e.length-1].lastChild);for(let t=0,i=e.length;t<i;++t)e[t].unbind()}}};f(Se),P.defineProperty(Se.prototype,"index"),P.defineProperty(Se.prototype,"length");const xe=(e,t)=>`${e}.${t}`,Te={},we={index:0,node:null};function Oe(e){e.startsWith("fast-")||u.warn(1204,{name:e})}const Pe=new Proxy(document.createElement("div"),{get(e,t){Oe(t);const i=Reflect.get(e,t);return a(i)?i.bind(e):i},set(e,t,i){return Oe(t),Reflect.set(e,t,i)}});function Ae(e,t,i,n,o,r=!1){const a=i.attributes,s=e.directives;for(let l=0,c=a.length;l<c;++l){const d=a[l],u=d.value,h=ge.parse(u,s);let p=null;null===h?r&&(p=new Ce(W((()=>u),e.policy)),me.assignAspect(p,d.name)):p=De.aggregate(h,e.policy),null!==p&&(i.removeAttributeNode(d),l--,c--,e.addFactory(p,t,n,o,i.tagName))}}function Ee(e,t,i){let n=0,o=t.firstChild;for(;o;){const t=ke(e,i,o,n);o=t.node,n=t.index}}function ke(e,t,i,n){const o=xe(t,n);switch(i.nodeType){case 1:Ae(e,t,i,o,n),Ee(e,i,o);break;case 3:return function(e,t,i,n,o){const r=ge.parse(t.textContent,e.directives);if(null===r)return we.node=t.nextSibling,we.index=o+1,we;let a,l=a=t;for(let t=0,c=r.length;t<c;++t){const c=r[t];0!==t&&(o++,n=xe(i,o),a=l.parentNode.insertBefore(document.createTextNode(""),l.nextSibling)),s(c)?a.textContent=c:(a.textContent=" ",me.assignAspect(c),e.addFactory(c,i,n,o,null)),l=a}return we.index=o+1,we.node=l.nextSibling,we}(e,i,t,o,n);case 8:const r=ge.parse(i.data,e.directives);null!==r&&e.addFactory(De.aggregate(r),t,o,n,null)}return we.index=n+1,we.node=i.nextSibling,we}const Ie="TEMPLATE",De={compile(e,t,i=S.policy){let n;if(s(e)){n=document.createElement(Ie),n.innerHTML=i.createHTML(e);const t=n.content.firstElementChild;null!==t&&t.tagName===Ie&&(n=t)}else n=e;n.content.firstChild||n.content.lastChild||n.content.appendChild(document.createComment(""));const o=document.adoptNode(n.content),r=new class{constructor(e,t,i){this.fragment=e,this.directives=t,this.policy=i,this.proto=null,this.nodeIds=new Set,this.descriptors={},this.factories=[]}addFactory(e,t,i,n,o){var r,a;this.nodeIds.has(i)||(this.nodeIds.add(i),this.addTargetDescriptor(t,i,n)),e.id=null!==(r=e.id)&&void 0!==r?r:he(),e.targetNodeId=i,e.targetTagName=o,e.policy=null!==(a=e.policy)&&void 0!==a?a:this.policy,this.factories.push(e)}freeze(){return this.proto=Object.create(null,this.descriptors),this}addTargetDescriptor(e,t,i){const n=this.descriptors;if("r"===t||"h"===t||n[t])return;if(!n[e]){const t=e.lastIndexOf("."),i=e.substring(0,t),n=parseInt(e.substring(t+1));this.addTargetDescriptor(i,e,n)}let o=Te[t];if(!o){const n=`_${t}`;Te[t]=o={get(){var t;return null!==(t=this[n])&&void 0!==t?t:this[n]=this[e].childNodes[i]}}}n[t]=o}createView(e){const t=this.fragment.cloneNode(!0),i=Object.create(this.proto);i.r=t,i.h=null!=e?e:Pe;for(const e of this.nodeIds)i[e];return new Se(t,this.factories,i)}}(o,t,i);var a,l;return Ae(r,"",n,"h",0,!0),l=t,((a=o.firstChild)&&8==a.nodeType&&null!==ge.parse(a.data,l)||1===o.childNodes.length&&Object.keys(t).length>0)&&o.insertBefore(document.createComment(""),o.firstChild),Ee(r,o,"r"),we.node=null,r.freeze()},setDefaultStrategy(e){this.compile=e},aggregate(e,t=S.policy){if(1===e.length)return e[0];let i,n,o,r=!1;const a=e.length,l=e.map((e=>s(e)?()=>e:(i=e.sourceAspect||i,n=e.dataBinding||n,r=r||e.dataBinding.isVolatile,o=o||e.dataBinding.policy,e.dataBinding.evaluate)));n.evaluate=(e,t)=>{let i="";for(let n=0;n<a;++n)i+=l[n](e,t);return i},n.isVolatile=r,n.policy=null!=o?o:t;const c=new Ce(n);return me.assignAspect(c,i),c}},_e=/([ \x09\x0a\x0c\x0d])([^\0-\x1F\x7F-\x9F "'>=/]+)([ \x09\x0a\x0c\x0d]*=[ \x09\x0a\x0c\x0d]*(?:[^ \x09\x0a\x0c\x0d"'`<>=]*|"[^"]*|'[^']*))$/,Ne=Object.create(null);let Re=class{constructor(e,t=Ne){this.html=e,this.factories=t}createHTML(e){const t=this.factories;for(const i in t)e(t[i]);return this.html}};function Me(e,t,i,n=me.getForInstance(e)){if(n.aspected){const i=_e.exec(t);null!==i&&me.assignAspect(e,i[2])}return e.createHTML(i)}Re.empty=new Re(""),me.define(Re);let Le=class e{constructor(e,t={},i){this.policy=i,this.result=null,this.html=e,this.factories=t}create(e){return null===this.result&&(this.result=De.compile(this.html,this.factories,this.policy)),this.result.createView(e)}inline(){return new Re(s(this.html)?this.html:this.html.innerHTML,this.factories)}withPolicy(e){if(this.result)throw u.error(1208);if(this.policy)throw u.error(1207);return this.policy=e,this}render(e,t,i){const n=this.create(i);return n.bind(e),n.appendTo(t),n}static create(t,i,n){let o="";const r=Object.create(null),s=e=>{var t;const i=null!==(t=e.id)&&void 0!==t?t:e.id=he();return r[i]=e,i};for(let e=0,n=t.length-1;e<n;++e){const n=t[e];let r,l=i[e];if(o+=n,a(l))l=new Ce(G(l));else if(l instanceof Z)l=new Ce(l);else if(!(r=me.getForInstance(l))){const e=l;l=new Ce(W((()=>e)))}o+=Me(l,n,s,r)}return new e(o+t[t.length-1],r,n)}};f(Le);const Be=(e,...t)=>{if(Array.isArray(e)&&Array.isArray(e.raw))return Le.create(e,t);throw u.error(1206)};Be.partial=e=>new Re(e);let Fe=class extends ve{bind(e){e.source[this.options]=e.targets[this.targetNodeId]}};me.define(Fe);const Ue=e=>new Fe(e),He=()=>null;function $e(e){return void 0===e?He:a(e)?e:()=>e}function Ze(e,t,i){const n=a(e)?e:()=>e,o=$e(t),r=$e(i);return(e,t)=>n(e,t)?o(e,t):r(e,t)}const Ve=Object.freeze({positioning:!1,recycle:!0});function Ge(e,t,i,n){e.context.parent=n.source,e.context.parentContext=n.context,e.bind(t[i])}function je(e,t,i,n){e.context.parent=n.source,e.context.parentContext=n.context,e.context.length=t.length,e.context.index=i,e.bind(t[i])}let ze=class{constructor(e,t,i){this.dataBinding=e,this.templateBinding=t,this.options=i,$.enable()}createHTML(e){return pe.comment(e(this))}createBehavior(){return new class{constructor(e){this.directive=e,this.items=null,this.itemsObserver=null,this.bindView=Ge,this.views=[],this.itemsBindingObserver=e.dataBinding.createObserver(this,e),this.templateBindingObserver=e.templateBinding.createObserver(this,e),e.options.positioning&&(this.bindView=je)}bind(e){this.location=e.targets[this.directive.targetNodeId],this.controller=e,this.items=this.itemsBindingObserver.bind(e),this.template=this.templateBindingObserver.bind(e),this.observeItems(!0),this.refreshAllViews(),e.onUnbind(this)}unbind(){null!==this.itemsObserver&&this.itemsObserver.unsubscribe(this),this.unbindAllViews()}handleChange(e,t){if(t===this.itemsBindingObserver)this.items=this.itemsBindingObserver.bind(this.controller),this.observeItems(),this.refreshAllViews();else if(t===this.templateBindingObserver)this.template=this.templateBindingObserver.bind(this.controller),this.refreshAllViews(!0);else{if(!t[0])return;t[0].reset?this.refreshAllViews():this.updateViews(t)}}observeItems(e=!1){if(!this.items)return void(this.items=h);const t=this.itemsObserver,i=this.itemsObserver=P.getNotifier(this.items),n=t!==i;n&&null!==t&&t.unsubscribe(this),(n||e)&&i.subscribe(this)}updateViews(e){const t=this.views,i=this.bindView,n=this.items,o=this.template,r=this.controller,a=this.directive.options.recycle,s=[];let l=0,c=0;for(let d=0,u=e.length;d<u;++d){const u=e[d],h=u.removed;let p=0,g=u.index;const f=g+u.addedCount,m=t.splice(u.index,h.length),v=c=s.length+m.length;for(;g<f;++g){const e=t[g],d=e?e.firstChild:this.location;let u;a&&c>0?(p<=v&&m.length>0?(u=m[p],p++):(u=s[l],l++),c--):u=o.create(),t.splice(g,0,u),i(u,n,g,r),u.insertBefore(d)}m[p]&&s.push(...m.slice(p))}for(let e=l,t=s.length;e<t;++e)s[e].dispose();if(this.directive.options.positioning)for(let e=0,i=t.length;e<i;++e){const n=t[e].context;n.length=i,n.index=e}}refreshAllViews(e=!1){const t=this.items,i=this.template,n=this.location,o=this.bindView,r=this.controller;let a=t.length,s=this.views,l=s.length;if(0!==a&&!e&&this.directive.options.recycle||(Se.disposeContiguousBatch(s),l=0),0===l){this.views=s=new Array(a);for(let e=0;e<a;++e){const a=i.create();o(a,t,e,r),s[e]=a,a.insertBefore(n)}}else{let e=0;for(;e<a;++e)if(e<l)o(s[e],t,e,r);else{const a=i.create();o(a,t,e,r),s.push(a),a.insertBefore(n)}const c=s.splice(e,l-e);for(e=0,a=c.length;e<a;++e)c[e].dispose()}}unbindAllViews(){const e=this.views;for(let t=0,i=e.length;t<i;++t)e[t].unbind()}}(this)}};function We(e,t,i=Ve){const n=K(e),o=K(t);return new ze(n,o,Object.assign(Object.assign({},Ve),i))}me.define(ze);const Ke=e=>1===e.nodeType,qe=e=>e?t=>1===t.nodeType&&t.matches(e):Ke;let Ye=class extends ve{get id(){return this._id}set id(e){this._id=e,this._controllerProperty=`${e}-c`}bind(e){const t=e.targets[this.targetNodeId];t[this._controllerProperty]=e,this.updateTarget(e.source,this.computeNodes(t)),this.observe(t),e.onUnbind(this)}unbind(e){const t=e.targets[this.targetNodeId];this.updateTarget(e.source,h),this.disconnect(t),t[this._controllerProperty]=null}getSource(e){return e[this._controllerProperty].source}updateTarget(e,t){e[this.options.property]=t}computeNodes(e){let t=this.getNodes(e);return"filter"in this.options&&(t=t.filter(this.options.filter)),t}};const Xe="slotchange";let Je=class extends Ye{observe(e){e.addEventListener(Xe,this)}disconnect(e){e.removeEventListener(Xe,this)}getNodes(e){return e.assignedNodes(this.options)}handleEvent(e){const t=e.currentTarget;this.updateTarget(this.getSource(t),this.computeNodes(t))}};function Qe(e){return s(e)&&(e={property:e}),new Je(e)}me.define(Je);const et="boolean",tt="reflect",it=Object.freeze({locate:g()}),nt={toView(e){return e?"true":"false"},fromView(e){return null!=e&&"false"!==e&&!1!==e&&0!==e}};function ot(e){if(null==e)return null;const t=1*e;return isNaN(t)?null:t}const rt={toView(e){const t=ot(e);return t?t.toString():t},fromView:ot};let at=class e{constructor(e,t,i=t.toLowerCase(),n=tt,o){this.guards=new Set,this.Owner=e,this.name=t,this.attribute=i,this.mode=n,this.converter=o,this.fieldName=`_${t}`,this.callbackName=`${t}Changed`,this.hasCallback=this.callbackName in e.prototype,n===et&&void 0===o&&(this.converter=nt)}setValue(e,t){const i=e[this.fieldName],n=this.converter;void 0!==n&&(t=n.fromView(t)),i!==t&&(e[this.fieldName]=t,this.tryReflectToAttribute(e),this.hasCallback&&e[this.callbackName](i,t),e.$fastController.notify(this.name))}getValue(e){return P.track(e,this.name),e[this.fieldName]}onAttributeChangedCallback(e,t){this.guards.has(e)||(this.guards.add(e),this.setValue(e,t),this.guards.delete(e))}tryReflectToAttribute(e){const t=this.mode,i=this.guards;i.has(e)||"fromView"===t||x.enqueue((()=>{i.add(e);const n=e[this.fieldName];switch(t){case tt:const t=this.converter;S.setAttribute(e,this.attribute,void 0!==t?t.toView(n):n);break;case et:S.setBooleanAttribute(e,this.attribute,n)}i.delete(e)}))}static collect(t,...i){const n=[];i.push(it.locate(t));for(let o=0,r=i.length;o<r;++o){const r=i[o];if(void 0!==r)for(let i=0,o=r.length;i<o;++i){const o=r[i];s(o)?n.push(new e(t,o)):n.push(new e(t,o.property,o.attribute,o.mode,o.converter))}}return n}};function st(e,t){let i;function n(e,t){arguments.length>1&&(i.property=t),it.locate(e.constructor).push(i)}return arguments.length>1?(i={},void n(e,t)):(i=void 0===e?{}:e,n)}const lt={mode:"open"},ct={},dt=new Set,ut=u.getById(r.elementRegistry,(()=>p()));let ht=class e{constructor(e,t=e.definition){var i;this.platformDefined=!1,s(t)&&(t={name:t}),this.type=e,this.name=t.name,this.template=t.template,this.registry=null!==(i=t.registry)&&void 0!==i?i:customElements;const n=e.prototype,o=at.collect(e,t.attributes),r=new Array(o.length),a={},l={};for(let e=0,t=o.length;e<t;++e){const t=o[e];r[e]=t.attribute,a[t.name]=t,l[t.attribute]=t,P.defineProperty(n,t)}Reflect.defineProperty(e,"observedAttributes",{value:r,enumerable:!0}),this.attributes=o,this.propertyLookup=a,this.attributeLookup=l,this.shadowOptions=void 0===t.shadowOptions?lt:null===t.shadowOptions?void 0:Object.assign(Object.assign({},lt),t.shadowOptions),this.elementOptions=void 0===t.elementOptions?ct:Object.assign(Object.assign({},ct),t.elementOptions),this.styles=Y.normalize(t.styles),ut.register(this)}get isDefined(){return this.platformDefined}define(e=this.registry){const t=this.type;return e.get(this.name)||(this.platformDefined=!0,e.define(this.name,t,this.elementOptions)),this}static compose(t,i){return dt.has(t)||ut.getByType(t)?new e(class extends t{},i):new e(t,i)}static registerBaseType(e){dt.add(e)}};ht.getByType=ut.getByType,ht.getForInstance=ut.getForInstance;const pt={bubbles:!0,composed:!0,cancelable:!0},gt="isConnected",ft=new WeakMap;function mt(e){var t,i;return null!==(i=null!==(t=e.shadowRoot)&&void 0!==t?t:ft.get(e))&&void 0!==i?i:null}let vt,yt=class extends w{constructor(e,t){super(e),this.boundObservables=null,this.needsInitialization=!0,this.hasExistingShadowRoot=!1,this._template=null,this.stage=3,this.guardBehaviorConnection=!1,this.behaviors=null,this._mainStyles=null,this.$fastController=this,this.view=null,this.source=e,this.definition=t;const i=t.shadowOptions;if(void 0!==i){let t=e.shadowRoot;t?this.hasExistingShadowRoot=!0:(t=e.attachShadow(i),"closed"===i.mode&&ft.set(e,t))}const n=P.getAccessors(e);if(n.length>0){const t=this.boundObservables=Object.create(null);for(let i=0,o=n.length;i<o;++i){const o=n[i].name,r=e[o];void 0!==r&&(delete e[o],t[o]=r)}}}get isConnected(){return P.track(this,gt),1===this.stage}get context(){var e,t;return null!==(t=null===(e=this.view)||void 0===e?void 0:e.context)&&void 0!==t?t:I.default}get isBound(){var e,t;return null!==(t=null===(e=this.view)||void 0===e?void 0:e.isBound)&&void 0!==t&&t}get sourceLifetime(){var e;return null===(e=this.view)||void 0===e?void 0:e.sourceLifetime}get template(){var e;if(null===this._template){const t=this.definition;this.source.resolveTemplate?this._template=this.source.resolveTemplate():t.template&&(this._template=null!==(e=t.template)&&void 0!==e?e:null)}return this._template}set template(e){this._template!==e&&(this._template=e,this.needsInitialization||this.renderTemplate(e))}get mainStyles(){var e;if(null===this._mainStyles){const t=this.definition;this.source.resolveStyles?this._mainStyles=this.source.resolveStyles():t.styles&&(this._mainStyles=null!==(e=t.styles)&&void 0!==e?e:null)}return this._mainStyles}set mainStyles(e){this._mainStyles!==e&&(null!==this._mainStyles&&this.removeStyles(this._mainStyles),this._mainStyles=e,this.needsInitialization||this.addStyles(e))}onUnbind(e){var t;null===(t=this.view)||void 0===t||t.onUnbind(e)}addBehavior(e){var t,i;const n=null!==(t=this.behaviors)&&void 0!==t?t:this.behaviors=new Map,o=null!==(i=n.get(e))&&void 0!==i?i:0;0===o?(n.set(e,1),e.addedCallback&&e.addedCallback(this),!e.connectedCallback||this.guardBehaviorConnection||1!==this.stage&&0!==this.stage||e.connectedCallback(this)):n.set(e,o+1)}removeBehavior(e,t=!1){const i=this.behaviors;if(null===i)return;const n=i.get(e);void 0!==n&&(1===n||t?(i.delete(e),e.disconnectedCallback&&3!==this.stage&&e.disconnectedCallback(this),e.removedCallback&&e.removedCallback(this)):i.set(e,n-1))}addStyles(e){var t;if(!e)return;const i=this.source;if(e instanceof HTMLElement)(null!==(t=mt(i))&&void 0!==t?t:this.source).append(e);else if(!e.isAttachedTo(i)){const t=e.behaviors;if(e.addStylesTo(i),null!==t)for(let e=0,i=t.length;e<i;++e)this.addBehavior(t[e])}}removeStyles(e){var t;if(!e)return;const i=this.source;if(e instanceof HTMLElement)(null!==(t=mt(i))&&void 0!==t?t:i).removeChild(e);else if(e.isAttachedTo(i)){const t=e.behaviors;if(e.removeStylesFrom(i),null!==t)for(let e=0,i=t.length;e<i;++e)this.removeBehavior(t[e])}}connect(){if(3!==this.stage)return;if(this.stage=0,null!==this.boundObservables){const e=this.source,t=this.boundObservables,i=Object.keys(t);for(let n=0,o=i.length;n<o;++n){const o=i[n];e[o]=t[o]}this.boundObservables=null}const e=this.behaviors;if(null!==e){this.guardBehaviorConnection=!0;for(const t of e.keys())t.connectedCallback&&t.connectedCallback(this);this.guardBehaviorConnection=!1}this.needsInitialization?(this.renderTemplate(this.template),this.addStyles(this.mainStyles),this.needsInitialization=!1):null!==this.view&&this.view.bind(this.source),this.stage=1,P.notify(this,gt)}disconnect(){if(1!==this.stage)return;this.stage=2,P.notify(this,gt),null!==this.view&&this.view.unbind();const e=this.behaviors;if(null!==e)for(const t of e.keys())t.disconnectedCallback&&t.disconnectedCallback(this);this.stage=3}onAttributeChangedCallback(e,t,i){const n=this.definition.attributeLookup[e];void 0!==n&&n.onAttributeChangedCallback(this.source,i)}emit(e,t,i){return 1===this.stage&&this.source.dispatchEvent(new CustomEvent(e,Object.assign(Object.assign({detail:t},pt),i)))}renderTemplate(e){var t;const i=this.source,n=null!==(t=mt(i))&&void 0!==t?t:i;if(null!==this.view)this.view.dispose(),this.view=null;else if(!this.needsInitialization||this.hasExistingShadowRoot){this.hasExistingShadowRoot=!1;for(let e=n.firstChild;null!==e;e=n.firstChild)n.removeChild(e)}e&&(this.view=e.render(i,n,i),this.view.sourceLifetime=O.coupled)}static forCustomElement(e){const t=e.$fastController;if(void 0!==t)return t;const i=ht.getForInstance(e);if(void 0===i)throw u.error(1401);return e.$fastController=new vt(e,i)}static setStrategy(e){vt=e}};function Ct(e){var t;return"adoptedStyleSheets"in e?e:null!==(t=mt(e))&&void 0!==t?t:e.getRootNode()}f(yt),yt.setStrategy(yt);let bt=class e{constructor(t){const i=e.styleSheetCache;this.sheets=t.map((e=>{if(e instanceof CSSStyleSheet)return e;let t=i.get(e);return void 0===t&&(t=new CSSStyleSheet,t.replaceSync(e),i.set(e,t)),t}))}addStylesTo(e){Tt(Ct(e),this.sheets)}removeStylesFrom(e){wt(Ct(e),this.sheets)}};bt.styleSheetCache=new Map;let St=0;function xt(e){return e===document?document.body:e}let Tt=(e,t)=>{e.adoptedStyleSheets=[...e.adoptedStyleSheets,...t]},wt=(e,t)=>{e.adoptedStyleSheets=e.adoptedStyleSheets.filter((e=>-1===t.indexOf(e)))};if(Y.supportsAdoptedStyleSheets){try{document.adoptedStyleSheets.push(),document.adoptedStyleSheets.splice(),Tt=(e,t)=>{e.adoptedStyleSheets.push(...t)},wt=(e,t)=>{for(const i of t){const t=e.adoptedStyleSheets.indexOf(i);-1!==t&&e.adoptedStyleSheets.splice(t,1)}}}catch(e){}Y.setDefaultStrategy(bt)}else Y.setDefaultStrategy(class{constructor(e){this.styles=e,this.styleClass="fast-"+ ++St}addStylesTo(e){e=xt(Ct(e));const t=this.styles,i=this.styleClass;for(let n=0;n<t.length;n++){const o=document.createElement("style");o.innerHTML=t[n],o.className=i,e.append(o)}}removeStylesFrom(e){const t=(e=xt(Ct(e))).querySelectorAll(`.${this.styleClass}`);for(let i=0,n=t.length;i<n;++i)e.removeChild(t[i])}});function Ot(e){const t=class extends e{constructor(){super(),yt.forCustomElement(this)}$emit(e,t,i){return this.$fastController.emit(e,t,i)}connectedCallback(){this.$fastController.connect()}disconnectedCallback(){this.$fastController.disconnect()}attributeChangedCallback(e,t,i){this.$fastController.onAttributeChangedCallback(e,t,i)}};return ht.registerBaseType(t),t}const Pt=Object.assign(Ot(HTMLElement),{from:function(e){return Ot(e)},define:function(e,t){return a(e)?ht.compose(e,t).define().type:ht.compose(this,e).define().type},compose:function(e,t){return a(e)?ht.compose(e,t):ht.compose(this,e)}}),At={row:"row",column:"column"};var Et=Object.defineProperty,kt=Object.getOwnPropertyDescriptor,It=(e,t,i,n)=>{for(var o,r=n>1?void 0:n?kt(t,i):t,a=e.length-1;a>=0;a--)(o=e[a])&&(r=(n?o(t,i,r):o(r))||r);return n&&r&&Et(t,i,r),r};class Dt extends Pt{constructor(){super(...arguments),this.direction=At.row,this.inlineSwatches=!1,this.autoHideOverflowSwatches=!0,this._filterGroupState={}}dataChanged(e,t){this._data=t,this._filterGroupState=this.data.filters.reduce(((e,t,i)=>{let n="";return n=t.id&&void 0!==t.id?t.id:`${t.label}-${t.type}-${i}`.replace(/\s/g,"-").toLowerCase(),e[n]=t.items[t.selectedIndex],e}),{})}selectionChangeHandler(e,t){const i=t.detail.item;this._filterGroupState[e]=i,this.onfiltergroupselectionchange?.(this._filterGroupState,t),this.$emit("onfiltergroupselectionchange",{state:this._filterGroupState,event:t})}get getData(){return this._data}}It([st],Dt.prototype,"data",2),It([st],Dt.prototype,"direction",2),It([st({attribute:"inline-swatches",mode:"boolean"})],Dt.prototype,"inlineSwatches",2),It([st({attribute:"auto-hide-overflow-swatches",mode:"boolean"})],Dt.prototype,"autoHideOverflowSwatches",2),It([A],Dt.prototype,"_filterGroupState",2),It([A],Dt.prototype,"_data",2);const _t=Object.freeze({prefix:"commerceui",shadowRootMode:"open",registry:customElements});function Nt(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a}"function"==typeof SuppressedError&&SuppressedError;const Rt="dropdown",Mt="swatches";let Lt=class extends Pt{constructor(){super(...arguments),this.type=Rt,this.size="medium",this.placeholderText="Select",this.selectedIndex=null,this.rowMaxItems=null,this.autoHideOverflowSwatches=!1,this.handleMenuOpenChange=e=>{this.open=e.detail.open}}itemsChanged(){this.items&&this.items.length>0&&this.selectedIndexHandler()}selectedIndexChanged(){this.selectedIndexHandler()}rowMaxItemsChanged(){this.updateRowMaxItems()}autoHideOverflowChanged(){this.updateRowMaxItems()}connectedCallback(){super.connectedCallback(),this.type===Rt?this.menuButtonRef.shadowRoot.querySelector("[slot='end']").style.flex="0 0 auto":this.type===Mt&&this.updateRowMaxItems(),this.containerResizeObserver=new ResizeObserver((()=>{this.updateRowMaxItems()})),this.containerResizeObserver.observe(this.containerRef)}disconnectedCallback(){super.disconnectedCallback(),this.containerResizeObserver.unobserve(this.containerRef)}get getSelectedValue(){return void 0!==this._selected&&null!==this._selected&&void 0!==this.items&&this.items.length>=this._selected-1?this.items[this._selected].value:null}get getPlaceholderText(){return this.placeholderText}selectHandler(e){var t;this._selected=this.items.map((e=>e.value)).indexOf(e.value),null===(t=this.onselectionchange)||void 0===t||t.call(this,e),this.$emit("filterchange",{selectedIndex:this._selected,item:e})}selectedIndexHandler(){this.items&&this.selectedIndex>=0&&this.selectedIndex<this.items.length&&(this._selected=this.selectedIndex)}updateRowMaxItems(){if(this.shadowRoot&&this.containerRef&&this.swatchesRef&&this.containerRef.clientWidth>0&&this.containerRef.clientWidth!==this.containerPreviousWidth){const e=this.swatchesRef.shadowRoot.querySelector("commerceui-swatch");this.itemsToFitPerRow=this.autoHideOverflowSwatches?Math.floor(this.containerRef.clientWidth/(e.clientWidth+8)):this.rowMaxItems,this.containerPreviousWidth=this.containerRef.clientWidth}}};Nt([st({attribute:"type"})],Lt.prototype,"type",void 0),Nt([st],Lt.prototype,"size",void 0),Nt([st({attribute:"open"})],Lt.prototype,"open",void 0),Nt([st],Lt.prototype,"label",void 0),Nt([st({attribute:"show-label-value",mode:"boolean"})],Lt.prototype,"showLabelValue",void 0),Nt([st({attribute:"show-label-inline",mode:"boolean"})],Lt.prototype,"showLabelInline",void 0),Nt([st({attribute:"items"})],Lt.prototype,"items",void 0),Nt([st({attribute:"placeholder-text"})],Lt.prototype,"placeholderText",void 0),Nt([st({attribute:"hide-placeholder-text",mode:"boolean"})],Lt.prototype,"hidePlaceholderText",void 0),Nt([st({attribute:"selected-index",converter:rt})],Lt.prototype,"selectedIndex",void 0),Nt([st({attribute:"row-max-items",converter:rt})],Lt.prototype,"rowMaxItems",void 0),Nt([st({attribute:"auto-hide-overflow-swatches",mode:"boolean"})],Lt.prototype,"autoHideOverflowSwatches",void 0),Nt([A],Lt.prototype,"itemsToFitPerRow",void 0),Nt([A],Lt.prototype,"_selected",void 0);const Bt="var(--colorNeutralForeground1)",Ft="var(--colorNeutralForeground3)",Ut="var(--colorNeutralForeground4)",Ht="var(--colorNeutralForegroundStaticInverted)",$t="var(--colorBrandForeground1)",Zt="var(--colorNeutralBackground1)",Vt="var(--colorNeutralBackground1Hover)",Gt="var(--colorBrandBackground)",jt="var(--colorNeutralStroke1)",zt="var(--colorNeutralStroke2)",Wt="var(--colorNeutralStroke3)",Kt="var(--colorPaletteRedForeground1)",qt="var(--colorPaletteGreenForeground1)",Yt="var(--borderRadiusSmall)",Xt="var(--borderRadiusMedium)",Jt="var(--borderRadiusXLarge)",Qt="var(--fontFamilyBase)",ei="var(--fontSizeBase300)",ti="var(--fontWeightRegular)",ii="var(--fontWeightSemibold)",ni="var(--lineHeightBase300)",oi="var(--spacingHorizontalXXS)",ri="var(--spacingHorizontalXS)",ai="var(--spacingHorizontalS)",si="var(--spacingHorizontalL)",li="var(--spacingVerticalXXS)",ci="var(--spacingVerticalXS)",di="var(--spacingVerticalS)",ui="var(--spacingVerticalM)",hi=Qt,pi=ei,gi=ti,fi=ni,mi=Qt,vi="var(--fontSizeBase200)",yi=ti,Ci="var(--lineHeightBase200)",bi="var(--fontSizeBase100)",Si=ti,xi="var(--lineHeightBase100)",Ti="var(--fontSizeBase500)",wi=ii,Oi="var(--lineHeightBase500)",Pi="var(--fontSizeBase400)",Ai=ii,Ei="var(--lineHeightBase400)",ki="var(--fontSizeHero700)",Ii=ii,Di="var(--lineHeightHero700)",_i="var(--fontSizeBase600)",Ni=ii,Ri="var(--lineHeightBase600)",Mi=re`
:host {
overflow: hidden;
}
.container {
display: flex;
flex-direction: column;
align-items: flex-start;
row-gap: ${ci};
}
.placeholder {
color: ${Ut};
font-family: ${Qt};
font-size: ${pi};
font-weight: ${gi};
}
fluent-beta-label {
max-width: 100%;
}
.label {
font-weight: ${ii};
}
.label-value {
margin-inline-start: ${ri};
font-weight: ${gi};
}
fluent-beta-menu {
max-width: 100%;
}
fluent-beta-menu[open="true"] {
z-index: 2;
}
fluent-beta-menu-button {
max-width: 100%;
}
.menu-button::part(control) {
flex: 1;
min-width: 0;
width: max-content;
background-color: ${Zt};
}
.label,
.menu-button::part(content),
.menu-button .label-value {
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
}
fluent-beta-menu-list {
width: fit-content;
min-width: fit-content;
max-width: fit-content;
}
fluent-beta-menu-item {
grid-template-columns: auto;
}
fluent-beta-menu-item[disabled] {
pointer-events: none;
background: none;
}
fluent-beta-menu-item .menu-item-label {
overflow: hidden;
text-overflow: ellipsis;
}
`,Li=Object.freeze({prefix:"commerceui",shadowRootMode:"open",registry:customElements}),Bi="circle",Fi="square",Ui="small",Hi="medium";let $i=class extends Pt{constructor(){super(...arguments),this.shape=Fi,this.size=Hi,this.rowMaxItems=null,this.selectedIndex=null,this.items=[],this.isExpanded=!1,this._rowMaxItems=null,this.handleExpandButtonClick=()=>{this.isExpanded=!this.isExpanded}}rowMaxItemsChanged(e,t){this._rowMaxItems=t&&t>1?this.rowMaxItems:null}selectedIndexChanged(){if(this.items){let e=this.items.slice();for(let t=0;t<e.length;t++)e.splice(t,1,{...e[t],selected:this.selectedIndex===t&&!e[t].disabled});this.items=e}}getVisibleSwatches(){if(!this.items)return;let e=this.items.slice();this._rowMaxItems&&this.items.length>this._rowMaxItems&&(e=this.items.slice(0,this._rowMaxItems-1));for(let t=0;t<e.length;t++)e[t].selected=this.selectedIndex===t&&!e[t].disabled;return e}getOverflowSwatches(){if(!this.items||this.items.length<=this._rowMaxItems||!this.isExpanded)return;let e=this.items.slice(this._rowMaxItems-1,this.items.length);for(let t=0;t<e.length;t++){const i=t+this._rowMaxItems-1;e[t].selected=this.selectedIndex===i&&!e[t].disabled}return e}handleSwatchClick(e){var t;if(e.disabled)return;const i=this.items.indexOf(e);i!==this.selectedIndex&&(this.selectedIndex=i,null===(t=this.onselectionchange)||void 0===t||t.call(this,e),this.$emit("change",e))}};Nt([st],$i.prototype,"shape",void 0),Nt([st],$i.prototype,"size",void 0),Nt([st({attribute:"row-max-items",converter:rt})],$i.prototype,"rowMaxItems",void 0),Nt([st({attribute:"selected-index",converter:rt})],$i.prototype,"selectedIndex",void 0),Nt([st],$i.prototype,"items",void 0),Nt([A],$i.prototype,"isExpanded",void 0),Nt([A],$i.prototype,"_rowMaxItems",void 0);const Zi=re`
:host {
display: block;
}
.container {
display: flex;
flex-wrap: wrap;
gap: ${ai};
}
.expand-button {
background: transparent;
border: none;
padding: 0 0 ${li} ${oi};
color: ${$t};
font-family: ${Qt};
font-size: ${pi};
line-height: ${fi};
font-weight: ${gi};
text-align: start;
cursor: pointer;
}
:host([size=${Ui}]) .expand-button {
min-width: 24px;
height: 24px;
}
:host([size=${Hi}]) .expand-button {
min-width: 32px;
height: 32px;
}
:host([aria-expanded="true"]) .expand-button {
padding: 0 0 ${li};
text-align: center;
}
`,Vi=(e,t)=>Be`<commerceui-swatch
shape=${t.shape}
size=${t.size}
selected=${e.selected}
@click=${()=>t.handleSwatchClick(e)}
:data=${e}
></commerceui-swatch>`,Gi=Be`
<button class="expand-button" role="button" @click=${e=>e.handleExpandButtonClick()}>
${e=>e.isExpanded?"Less":"+"+(e.items.length-e.rowMaxItems+1)}
</button>
`,ji=Be`
<template aria-expanded=${e=>e.isExpanded}>
<div id="swatches-container" class="container">
${We((e=>e.getVisibleSwatches()),Be`${(e,t)=>Vi(e,t.parent)}`)}
${We((e=>e.getOverflowSwatches()),Be`${(e,t)=>Vi(e,t.parent)}`)}
${Ze((e=>e.items&&e._rowMaxItems&&e.items.length>e.rowMaxItems),Gi)}
</div>
</template>
`;Be`<commerceui-swatches
shape=${e=>e.shape}
size=${e=>e.size}
row-max-items=${e=>e.rowMaxItems}
selected-index=${e=>e.selectedIndex}
:items=${e=>e.items}
:onselectionchange=${e=>e.onselectionchange}
></commerceui-swatches>`,$i.compose({name:`${Li.prefix}-swatches`,template:ji,styles:Zi}).define(Li.registry);let zi=class extends Pt{constructor(){super(...arguments),this.shape=Fi,this.size=Hi}};Nt([st],zi.prototype,"shape",void 0),Nt([st],zi.prototype,"size",void 0),Nt([st],zi.prototype,"data",void 0);const Wi=re`
:host {
display: block;
}
:host([size=${Ui}]) {
width: 24px;
height: 24px;
}
:host([size=${Hi}]) {
width: 32px;
height: 32px;
}
:host([size=${"large"}]) {
width: 40px;
height: 40px;
}
.swatch {
display: flex;
align-items: center;
justify-content: center;
width: 100%;
height: 100%;
margin: 0;
padding: 0;
background-color: ${Ht};
border: none;
box-sizing: border-box;
cursor: pointer;
}
.swatch[disabled] {
opacity: 0.4;
cursor: default;
pointer-events: none;
position: relative;
overflow: hidden;
}
.color {
width: 100%;
height: 100%;
border-radius: ${Xt};
}
.swatch[disabled] .color {
opacity: 0.4;
}
.swatch[disabled]::before {
content: "";
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: linear-gradient(
to bottom right,
transparent 49%,
${jt} 49%,
${jt} 51%,
transparent 21%
);
z-index: 1;
}
.swatch,
.content,
:host([shape=${Fi}]) .swatch,
:host([shape=${Fi}]) .swatch .content {
border-radius: ${Xt};
}
:host([shape=${Bi}]) .swatch,
:host([shape=${Bi}]) .content {
border-radius: 50%;
padding: unset;
}
.content {
width: 100%;
height: 100%;
border: 1px solid ${jt};
box-sizing: border-box;
overflow: hidden;
transition-property: width, height;
transition: 0.3s ${"var(--curveDecelerateMid)"};
padding: ${oi};
}
.content img {
width: 100%;
height: 100%;
border-radius: ${Xt};
background-color: ${Ht};
object-fit: contain;
}
.swatch:hover {
border: 1px solid ${"var(--colorNeutralStroke1Hover)"};
}
:host([selected]) .swatch {
outline: 2px solid ${$t};
outline-offset: -2px;
}
:host([selected]) .swatch:focus-visible {
outline: 2px solid ${Bt};
outline-offset: 2px;
}
.swatch:hover .content,
:host([selected]) .swatch .content {
width: calc(100% - 2px);
height: calc(100% - 2px);
border: none;
}
`,Ki=Be`<button
class="swatch"
role="button"
type="button"
?disabled=${e=>e.data.disabled}
>
<div class="content">
${Ze((e=>e.data.imgSrc),Be`<img
src=${e=>e.data.imgSrc}
alt=${e=>e.data.imgAlt}
title=${e=>e.data.label}
/>`)}
${Ze((e=>!e.data.imgSrc),Be`<div
class="color"
style="background-color: ${e=>e.data.fill};"
></div>`)}
</div>
</button>`,qi=Be`
<template shape=${e=>e.shape} size=${e=>e.size} ?selected=${e=>e.data.selected}>
${Ki}
</template>
`;function Yi(...e){return e.every((e=>e instanceof HTMLElement))}Be`<commerceui-swatch
shape=${e=>e.shape}
size=${e=>e.size}
:data=${e=>e.data}
:onclick=${e=>e.onclick}
></commerceui-swatch>`,zi.compose({name:`${Li.prefix}-swatch`,template:qi,styles:Wi}).define(Li.registry);const Xi="Enter",Ji="Escape";var Qi=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};let en=class{};function tn(e){return e?"string"==typeof e?new Re(e):"inline"in e?e.inline():e:Re.empty}function nn(e){return`:host([hidden]){display:none}:host{display:${e}}`}Qi([st({attribute:"aria-atomic"})],en.prototype,"ariaAtomic",void 0),Qi([st({attribute:"aria-busy"})],en.prototype,"ariaBusy",void 0),Qi([st({attribute:"aria-controls"})],en.prototype,"ariaControls",void 0),Qi([st({attribute:"aria-current"})],en.prototype,"ariaCurrent",void 0),Qi([st({attribute:"aria-describedby"})],en.prototype,"ariaDescribedby",void 0),Qi([st({attribute:"aria-details"})],en.prototype,"ariaDetails",void 0),Qi([st({attribute:"aria-disabled"})],en.prototype,"ariaDisabled",void 0),Qi([st({attribute:"aria-errormessage"})],en.prototype,"ariaErrormessage",void 0),Qi([st({attribute:"aria-flowto"})],en.prototype,"ariaFlowto",void 0),Qi([st({attribute:"aria-haspopup"})],en.prototype,"ariaHaspopup",void 0),Qi([st({attribute:"aria-hidden"})],en.prototype,"ariaHidden",void 0),Qi([st({attribute:"aria-invalid"})],en.prototype,"ariaInvalid",void 0),Qi([st({attribute:"aria-keyshortcuts"})],en.prototype,"ariaKeyshortcuts",void 0),Qi([st({attribute:"aria-label"})],en.prototype,"ariaLabel",void 0),Qi([st({attribute:"aria-labelledby"})],en.prototype,"ariaLabelledby",void 0),Qi([st({attribute:"aria-live"})],en.prototype,"ariaLive",void 0),Qi([st({attribute:"aria-owns"})],en.prototype,"ariaOwns",void 0),Qi([st({attribute:"aria-relevant"})],en.prototype,"ariaRelevant",void 0),Qi([st({attribute:"aria-roledescription"})],en.prototype,"ariaRoledescription",void 0);let on=class{constructor(e){this.listenerCache=new WeakMap,this.query=e}connectedCallback(e){const{query:t}=this;let i=this.listenerCache.get(e);i||(i=this.constructListener(e),this.listenerCache.set(e,i)),i.bind(t)(),t.addEventListener("change",i)}disconnectedCallback(e){const t=this.listenerCache.get(e);t&&this.query.removeEventListener("change",t)}},rn=class e extends on{constructor(e,t){super(e),this.styles=t}static with(t){return i=>new e(t,i)}constructListener(e){let t=!1;const i=this.styles;return function(){const{matches:n}=this;n&&!t?(e.addStyles(i),t=n):!n&&t&&(e.removeStyles(i),t=n)}}removedCallback(e){e.removeStyles(this.styles)}};const an=rn.with(window.matchMedia("(forced-colors)"));rn.with(window.matchMedia("(prefers-color-scheme: dark)")),rn.with(window.matchMedia("(prefers-color-scheme: light)"));let sn=class{};function ln(e){return Be` <slot name="end" ${Ue("end")}>${tn(e.end)}</slot> `.inline()}function cn(e){return Be` <slot name="start" ${Ue("start")}>${tn(e.start)}</slot> `.inline()}function dn(e,...t){const i=it.locate(e);t.forEach((t=>{Object.getOwnPropertyNames(t.prototype).forEach((i=>{"constructor"!==i&&Object.defineProperty(e.prototype,i,Object.getOwnPropertyDescriptor(t.prototype,i))})),it.locate(t).forEach((e=>i.push(e)))}))}const un=Object.freeze({prefix:"fluent",shadowRootMode:"open",registry:customElements}),hn="var(--colorNeutralForeground1)",pn="var(--colorNeutralForeground2)",gn="var(--colorNeutralForeground2Hover)",fn="var(--colorNeutralForeground2Pressed)",mn="var(--colorNeutralForeground2BrandHover)",vn="var(--colorNeutralForeground2BrandPressed)",yn="var(--colorNeutralForeground3)",Cn="var(--colorNeutralForegroundDisabled)",bn="var(--colorNeutralForegroundOnBrand)",Sn="var(--colorBrandForeground1)",xn="var(--colorNeutralBackground1)",Tn="var(--colorNeutralBackground1Hover)",wn="var(--colorTransparentBackground)",On="var(--colorTransparentBackgroundHover)",Pn="var(--colorTransparentBackgroundPressed)",An="var(--colorNeutralBackgroundDisabled)",En="var(--colorBrandBackground)",kn="var(--colorNeutralStroke2)",In="var(--colorTransparentStroke)",Dn="var(--colorStrokeFocus2)",_n="var(--colorPaletteRedForeground1)",Nn="var(--colorPaletteRedForeground3)",Rn="var(--colorPaletteDarkOrangeForeground3)",Mn="var(--colorPaletteYellowForeground2)",Ln="var(--borderRadiusNone)",Bn="var(--borderRadiusSmall)",Fn="var(--borderRadiusMedium)",Un="var(--borderRadiusCircular)",Hn="var(--fontFamilyBase)",$n="var(--fontSizeBase200)",Zn="var(--fontSizeBase300)",Vn="var(--fontSizeBase400)",Gn="var(--fontWeightRegular)",jn="var(--fontWeightSemibold)",zn="var(--lineHeightBase200)",Wn="var(--lineHeightBase300)",Kn="var(--lineHeightBase400)",qn="var(--strokeWidthThin)",Yn="var(--spacingHorizontalXXS)",Xn="var(--spacingHorizontalXS)",Jn="var(--spacingHorizontalSNudge)",Qn="submit",eo="reset",to=re`
${nn("inline-flex")}
:host {
--icon-spacing: ${Jn};
contain: layout style;
vertical-align: middle;
}
:host .control {
display: inline-flex;
align-items: center;
box-sizing: border-box;
justify-content: center;
text-decoration-line: none;
margin: 0;
min-height: 32px;
outline-style: none;
background-color: ${xn};
color: ${hn};
border: ${qn} solid ${"var(--colorNeutralStroke1)"};
padding: 0 ${"var(--spacingHorizontalM)"};
min-width: 96px;
border-radius: ${Fn};
font-size: ${Zn};
font-family: ${Hn};
font-weight: ${jn};
line-height: ${Wn};
transition-duration: ${"var(--durationFaster)"};
transition-property: background, border, color;
transition-timing-function: ${"var(--curveEasyEase)"};
cursor: pointer;
}
.content {
display: inherit;
}
:host(:hover) .control {
background-color: ${Tn};
color: ${"var(--colorNeutralForeground1Hover)"};
border-color: ${"var(--colorNeutralStroke1Hover)"};
}
:host(:hover:active) .control {
background-color: ${"var(--colorNeutralBackground1Pressed)"};
border-color: ${"var(--colorNeutralStroke1Pressed)"};
color: ${"var(--colorNeutralForeground1Pressed)"};
outline-style: none;
}
:host .control:focus-visible {
border-color: ${In};
outline: ${"var(--strokeWidthThick)"}) solid ${In};
box-shadow: ${"var(--shadow4)"}, 0 0 0 2px ${Dn};
}
@media screen and (prefers-reduced-motion: reduce) {
transition-duration: 0.01ms;
}
::slotted(svg) {
font-size: 20px;
height: 20px;
width: 20px;
fill: currentColor;
}
[slot='start'],
::slotted([slot='start']) {
margin-inline-end: var(--icon-spacing);
}
[slot='end'],
::slotted([slot='end']) {
margin-inline-start: var(--icon-spacing);
}
:host([icon-only]) .control {
min-width: 32px;
max-width: 32px;
}
:host([size='small']) {
--icon-spacing: ${Xn};
}
:host([size='small']) .control {
min-height: 24px;
min-width: 64px;
padding: 0 ${"var(--spacingHorizontalS)"};
border-radius: ${Bn};
font-size: ${$n};
line-height: ${zn};
font-weight: ${Gn};
}
:host([size='small'][icon-only]) .control {
min-width: 24px;
max-width: 24px;
}
:host([size='large']) .control {
min-height: 40px;
border-radius: ${"var(--borderRadiusLarge)"};
padding: 0 ${"var(--spacingHorizontalL)"};
font-size: ${Vn};
line-height: ${Kn};
}
:host([size='large'][icon-only]) .control {
min-width: 40px;
max-width: 40px;
}
:host([size='large']) ::slotted(svg) {
font-size: 24px;
height: 24px;
width: 24px;
}
:host([shape='circular']) .control,
:host([shape='circular']) .control:focus-visible {
border-radius: ${Un};
}
:host([shape='square']) .control,
:host([shape='square']) .control:focus-visible {
border-radius: ${Ln};
}
:host([appearance='primary']) .control {
background-color: ${En};
color: ${bn};
border-color: transparent;
}
:host([appearance='primary']:hover) .control {
background-color: ${"var(--colorBrandBackgroundHover)"};
}
:host([appearance='primary']:hover) .control,
:host([appearance='primary']:hover:active) .control {
border-color: transparent;
color: ${bn};
}
:host([appearance='primary']:hover:active) .control {
background-color: ${"var(--colorBrandBackgroundPressed)"};
}
:host([appearance='primary']) .control:focus-visible {
border-color: ${bn};
box-shadow: ${"var(--shadow2)"}, 0 0 0 2px ${Dn};
}
:host(is:([disabled][appearance='primary'], [disabled-focusabale][appearance="primary"])) .control,
:host(is:([disabled][appearance='primary'], [disabled-focusabale][appearance="primary"]):hover) .control,
:host(is:([disabled][appearance='primary'], [disabled-focusabale][appearance="primary"]):hover:active) .control {
border-color: transparent;
}
:host([appearance='outline']) .control {
background-color: ${wn};
}
:host([appearance='outline']:hover) .control {
background-color: ${On};
}
:host([appearance='outline']:hover:active) .control {
background-color: ${Pn};
}
:host(is:([disabled][appearance='outline'], [disabled-focusabale][appearance="outline"])) .control,
:host(is:([disabled][appearance='outline'], [disabled-focusabale][appearance="outline"]):hover) .control,
:host(is:([disabled][appearance='outline'], [disabled-focusabale][appearance="outline"]):hover:active) .control {
background-color: ${wn};
}
:host([appearance='subtle']) .control {
background-color: ${"var(--colorSubtleBackground)"};
color: ${pn};
border-color: transparent;
}
:host([appearance='subtle']:hover) .control {
background-color: ${"var(--colorSubtleBackgroundHover)"};
color: ${gn};
border-color: transparent;
}
:host([appearance='subtle']:hover:active) .control {
background-color: ${"var(--colorSubtleBackgroundPressed)"};
color: ${fn};
border-color: transparent;
}
:host(is:([disabled][appearance='subtle'], [disabled-focusabale][appearance="subtle"])) .control,
:host(is:([disabled][appearance='subtle'], [disabled-focusabale][appearance="subtle"]):hover) .control,
:host(is:([disabled][appearance='subtle'], [disabled-focusabale][appearance="subtle"]):hover:active) .control {
background-color: ${wn};
border-color: transparent;
}
:host([appearance='subtle']:hover) ::slotted(svg) {
fill: ${mn};
}
:host([appearance='subtle']:hover:active) ::slotted(svg) {
fill: ${vn};
}
:host([appearance='transparent']) .control {
background-color: ${wn};
color: ${pn};
}
:host([appearance='transparent']:hover) .control {
background-color: ${On};
color: ${mn};
}
:host([appearance='transparent']:hover:active) .control {
background-color: ${Pn};
color: ${vn};
}
:host([appearance='transparent']) .control,
:host([appearance='transparent']:hover) .control,
:host([appearance='transparent']:hover:active) .control {
border-color: transparent;
}
:host(is:([disabled][appearance='transparent'], [disabled-focusabale][appearance="transparent"])) .control,
:host(is:([disabled][appearance='transparent'], [disabled-focusabale][appearance="transparent"]):hover) .control,
:host(is:([disabled][appearance='transparent'], [disabled-focusabale][appearance="transparent"]):hover:active) .control {
border-color: transparent;
background-color: ${wn};
}
:host(:is([disabled], [disabled-focusable], [appearance][disabled], [appearance][disabled-focusable])) .control,
:host(:is([disabled], [disabled-focusable], [appearance][disabled], [appearance][disabled-focusable]):hover) .control,
:host(:is([disabled], [disabled-focusable], [appearance][disabled], [appearance][disabled-focusable]):hover:active)
.control {
background-color: ${An};
border-color: ${"var(--colorNeutralStrokeDisabled)"};
color: ${Cn};
cursor: not-allowed;
}
`.withBehaviors(an(re`
:host([appearance='transparent']:hover) .control {
border-color: Highlight;
}
`));var io=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};let no=class extends Pt{constructor(){super(...arguments),this.appearance="filled",this.color="brand"}};io([st],no.prototype,"appearance",void 0),io([st],no.prototype,"color",void 0),io([st],no.prototype,"shape",void 0),io([st],no.prototype,"size",void 0),dn(no,sn);const oo=function(e={}){return Be`
${cn(e)}
<slot>${tn(e.defaultContent)}</slot>
${ln(e)}
`}(),ro=Yn,ao=re.partial`
${nn("inline-flex")} :host {
position: relative;
box-sizing: border-box;
align-items: center;
justify-content: center;
font-family: ${Hn};
font-weight: ${jn};
font-size: ${$n};
line-height: ${zn};
min-width: 20px;
height: 20px;
padding-inline: calc(${Xn} + ${ro});
border-radius: ${Un};
border-color: ${In};
background-color: ${En};
color: ${bn};
contain: content;
}
::slotted(svg) {
font-size: 12px;
}
:host(:not([appearance='ghost']))::after {
position: absolute;
content: '';
top: 0;
left: 0;
bottom: 0;
right: 0;
border-style: solid;
border-width: ${qn};
border-color: inherit;
border-radius: inherit;
}
`,so=re`
:host([shape='square']) {
border-radius: ${Ln};
}
:host([shape='rounded']) {
border-radius: ${Fn};
}
:host([shape='rounded'][size='tiny']),
:host([shape='rounded'][size='extra-small']),
:host([shape='rounded'][size='small']) {
border-radius: ${Bn};
}
${re.partial`
:host([size='tiny']) {
width: 6px;
height: 6px;
font-size: 4px;
line-height: 4px;
padding-inline: 0;
min-width: unset;
}
:host([size='tiny']) ::slotted(svg) {
font-size: 6px;
}
:host([size='extra-small']) {
width: 10px;
height: 10px;
font-size: 6px;
line-height: 6px;
padding-inline: 0;
min-width: unset;
}
:host([size='extra-small']) ::slotted(svg) {
font-size: 10px;
}
:host([size='small']) {
min-width: 16px;
height: 16px;
font-size: ${"var(--fontSizeBase100)"};
line-height: ${"var(--lineHeightBase100)"};
padding-inline: calc(${Yn} + ${ro});
}
:host([size='small']) ::slotted(svg) {
font-size: 12px;
}
:host([size='large']) {
min-width: 24px;
height: 24px;
font-size: ${$n};
line-height: ${zn};
padding-inline: calc(${Xn} + ${ro});
}
:host([size='large']) ::slotted(svg) {
font-size: 16px;
}
:host([size='extra-large']) {
min-width: 32px;
height: 32px;
font-size: ${$n};
line-height: ${zn};
padding-inline: calc(${Jn} + ${ro});
}
:host([size='extra-large']) ::slotted(svg) {
font-size: 20px;
}
`}
${re.partial`
:host([color='danger']) {
background-color: ${"var(--colorPaletteRedBackground3)"};
color: ${bn};
}
:host([color='important']) {
background-color: ${hn};
color: ${xn};
}
:host([color='informative']) {
background-color: ${"var(--colorNeutralBackground5)"};
color: ${yn};
}
:host([color='severe']) {
background-color: ${"var(--colorPaletteDarkOrangeBackground3)"};
color: ${bn};
}
:host([color='subtle']) {
background-color: ${xn};
color: ${hn};
}
:host([color='success']) {
background-color: ${"var(--colorPaletteGreenBackground3)"};
color: ${bn};
}
:host([color='warning']) {
background-color: ${"var(--colorPaletteYellowBackground3)"};
color: ${"var(--colorNeutralForeground1Static)"};
}
`}
${re.partial`
:host([appearance='ghost']) {
color: ${Sn};
background-color: initial;
}
:host([appearance='ghost'][color='danger']) {
color: ${Nn};
}
:host([appearance='ghost'][color='important']) {
color: ${hn};
}
:host([appearance='ghost'][color='informative']) {
color: ${yn};
}
:host([appearance='ghost'][color='severe']) {
color: ${Rn};
}
:host([appearance='ghost'][color='subtle']) {
color: ${"var(--colorNeutralForegroundInverted)"};
}
:host([appearance='ghost'][color='success']) {
color: ${"var(--colorPaletteGreenForeground3)"};
}
:host([appearance='ghost'][color='warning']) {
color: ${Mn};
}
`}
${re.partial`
:host([appearance='outline']) {
border-color: currentColor;
color: ${Sn};
background-color: initial;
}
:host([appearance='outline'][color='danger']) {
color: ${Nn};
}
:host([appearance='outline'][color='important']) {
color: ${yn};
border-color: ${"var(--colorNeutralStrokeAccessible)"};
}
:host([appearance='outline'][color='informative']) {
color: ${yn};
border-color: ${kn};
}
:host([appearance='outline'][color='severe']) {
color: ${Rn};
}
:host([appearance='outline'][color='subtle']) {
color: ${"var(--colorNeutralForegroundStaticInverted)"};
}
:host([appearance='outline'][color='success']) {
color: ${"var(--colorPaletteGreenForeground2)"};
}
:host([appearance='outline'][color='warning']) {
color: ${Mn};
}
`}
${re.partial`
:host([appearance='tint']) {
background-color: ${"var(--colorBrandBackground2)"};
color: ${"var(--colorBrandForeground2)"};
border-color: ${"var(--colorBrandStroke2)"};
}
:host([appearance='tint'][color='danger']) {
background-color: ${"var(--colorPaletteRedBackground1)"};
color: ${_n};
border-color: ${"var(--colorPaletteRedBorder1)"};
}
:host([appearance='tint'][color='important']) {
background-color: ${yn};
color: ${xn};
border-color: ${In};
}
:host([appearance='tint'][color='informative']) {
background-color: ${"var(--colorNeutralBackground4)"};
color: ${yn};
border-color: ${kn};
}
:host([appearance='tint'][color='severe']) {
background-color: ${"var(--colorPaletteDarkOrangeBackground1)"};
color: ${"var(--colorPaletteDarkOrangeForeground1)"};
border-color: ${"var(--colorPaletteDarkOrangeBorder1)"};
}
:host([appearance='tint'][color='subtle']) {
background-color: ${xn};
color: ${yn};
border-color: ${kn};
}
:host([appearance='tint'][color='success']) {
background-color: ${"var(--colorPaletteGreenBackground1)"};
color: ${"var(--colorPaletteGreenForeground1)"};
border-color: ${"var(--colorPaletteGreenBorder2)"};
}
:host([appearance='tint'][color='warning']) {
background-color: ${"var(--colorPaletteYellowBackground1)"};
color: ${Mn};
border-color: ${"var(--colorPaletteYellowBorder1)"};
}
`}
${ao}
`,lo=no.compose({name:`${un.prefix}-badge`,template:oo,styles:so}),co="form-associated-proxy",uo="ElementInternals",ho=uo in window&&"setFormValue"in window[uo].prototype,po=new WeakMap;let go=class extends Pt{},fo=class extends(function(e){const t=class extends e{constructor(...e){super(...e),this.dirtyValue=!1,this.initialValue="",this.disabled=!1,this.proxyEventsToBlock=["change","click"],this.proxyInitialized=!1,this.required=!1,this.initialValue=this.initialValue||"",this.elementInternals||(this.formResetCallback=this.formResetCallback.bind(this))}static get formAssociated(){return ho}get validity(){return this.elementInternals?this.elementInternals.validity:this.proxy.validity}get form(){return this.elementInternals?this.elementInternals.form:this.proxy.form}get validationMessage(){return this.elementInternals?this.elementInternals.validationMessage:this.proxy.validationMessage}get willValidate(){return this.elementInternals?this.elementInternals.willValidate:this.proxy.willValidate}get labels(){if(this.elementInternals)return Object.freeze(Array.from(this.elementInternals.labels));if(this.proxy instanceof HTMLElement&&this.proxy.ownerDocument&&this.id){const e=this.proxy.labels,t=Array.from(this.proxy.getRootNode().querySelectorAll(`[for='${this.id}']`)),i=e?t.concat(Array.from(e)):t;return Object.freeze(i)}return h}valueChanged(e,t){this.dirtyValue=!0,this.proxy instanceof HTMLElement&&(this.proxy.value=this.value),this.currentValue=this.value,this.setFormValue(this.value),this.validate()}currentValueChanged(){this.value=this.currentValue}initialValueChanged(e,t){this.dirtyValue||(this.value=this.initialValue,this.dirtyValue=!1)}disabledChanged(e,t){this.proxy instanceof HTMLElement&&(this.proxy.disabled=this.disabled),x.enqueue((()=>this.classList.toggle("disabled",this.disabled)))}nameChanged(e,t){this.proxy instanceof HTMLElement&&(this.proxy.name=this.name)}requiredChanged(e,t){this.proxy instanceof HTMLElement&&(this.proxy.required=this.required),x.enqueue((()=>this.classList.toggle("required",this.required))),this.validate()}get elementInternals(){if(!ho)return null;let e=po.get(this);return e||(e=this.attachInternals(),po.set(this,e)),e}connectedCallback(){super.connectedCallback(),this.addEventListener("keypress",this._keypressHandler),this.value||(this.value=this.initialValue,this.dirtyValue=!1),this.elementInternals||(this.attachProxy(),this.form&&this.form.addEventListener("reset",this.formResetCallback))}disconnectedCallback(){this.proxyEventsToBlock.forEach((e=>this.proxy.removeEventListener(e,this.stopPropagation))),!this.elementInternals&&this.form&&this.form.removeEventListener("reset",this.formResetCallback)}checkValidity(){return this.elementInternals?this.elementInternals.checkValidity():this.proxy.checkValidity()}reportValidity(){return this.elementInternals?this.elementInternals.reportValidity():this.proxy.reportValidity()}setValidity(e,t,i){this.elementInternals?this.elementInternals.setValidity(e,t,i):"string"==typeof t&&this.proxy.setCustomValidity(t)}formDisabledCallback(e){this.disabled=e}formResetCallback(){this.value=this.initialValue,this.dirtyValue=!1}attachProxy(){var e;this.proxyInitialized||(this.proxyInitialized=!0,this.proxy.style.display="none",this.proxyEventsToBlock.forEach((e=>this.proxy.addEventListener(e,this.stopPropagation))),this.proxy.disabled=this.disabled,this.proxy.required=this.required,"string"==typeof this.name&&(this.proxy.name=this.name),"string"==typeof this.value&&(this.proxy.value=this.value),this.proxy.setAttribute("slot",co),this.proxySlot=document.createElement("slot"),this.proxySlot.setAttribute("name",co)),null===(e=this.shadowRoot)||void 0===e||e.appendChild(this.proxySlot),this.appendChild(this.proxy)}detachProxy(){var e;this.removeChild(this.proxy),null===(e=this.shadowRoot)||void 0===e||e.removeChild(this.proxySlot)}validate(e){this.proxy instanceof HTMLElement&&this.setValidity(this.proxy.validity,this.proxy.validationMessage,e)}setFormValue(e,t){this.elementInternals&&this.elementInternals.setFormValue(e,t||e)}_keypressHandler(e){if(e.key===Xi&&this.form instanceof HTMLFormElement){const e=this.form.querySelector("[type=submit]");null==e||e.click()}}stopPropagation(e){e.stopPropagation()}};return st({mode:"boolean"})(t.prototype,"disabled"),st({mode:"fromView",attribute:"value"})(t.prototype,"initialValue"),st({attribute:"current-value"})(t.prototype,"currentValue"),st(t.prototype,"name"),st({mode:"boolean"})(t.prototype,"required"),A(t.prototype,"value"),t}(go)){constructor(){super(...arguments),this.proxy=document.createElement("input")}};var mo=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};let vo=class extends fo{constructor(){super(...arguments),this.iconOnly=!1,this.disabledFocusable=!1,this.handleDisabledFocusableClick=e=>{e&&this.disabledFocusable&&e.stopImmediatePropagation()},this.handleSubmission=()=>{if(!this.form)return;const e=this.proxy.isConnected;e||this.attachProxy(),"function"==typeof this.form.requestSubmit?this.form.requestSubmit(this.proxy):this.proxy.click(),e||this.detachProxy()},this.handleFormReset=()=>{var e;null===(e=this.form)||void 0===e||e.reset()}}formactionChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.formAction=this.formaction)}formenctypeChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.formEnctype=this.formenctype)}formmethodChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.formMethod=this.formmethod)}formnovalidateChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.formNoValidate=this.formnovalidate)}formtargetChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.formTarget=this.formtarget)}typeChanged(e,t){this.proxy instanceof HTMLInputElement&&(this.proxy.type=this.type),t===Qn&&this.addEventListener("click",this.handleSubmission),e===Qn&&this.removeEventListener("click",this.handleSubmission),t===eo&&this.addEventListener("click",this.handleFormReset),e===eo&&this.removeEventListener("click",this.handleFormReset)}disabledFocusableChanged(e,t){this.$fastController.isConnected&&(this.disabledFocusable?this.setAttribute("aria-disabled","true"):this.removeAttribute("aria-disabled"))}validate(){super.validate(this.control)}connectedCallback(){super.connectedCallback(),this.proxy.setAttribute("type",this.type),this.addEventListener("click",this.handleDisabledFocusableClick)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("click",this.handleDisabledFocusableClick)}};mo([st({mode:"boolean"})],vo.prototype,"autofocus",void 0),mo([st({attribute:"form"})],vo.prototype,"formId",void 0),mo([st],vo.prototype,"formaction",void 0),mo([st],vo.prototype,"formenctype",void 0),mo([st],vo.prototype,"formmethod",void 0),mo([st({mode:"boolean"})],vo.prototype,"formnovalidate",void 0),mo([st],vo.prototype,"formtarget",void 0),mo([st],vo.prototype,"type",void 0),mo([st],vo.prototype,"appearance",void 0),mo([st],vo.prototype,"shape",void 0),mo([st],vo.prototype,"size",void 0),mo([st({attribute:"icon-only",mode:"boolean"})],vo.prototype,"iconOnly",void 0),mo([st({attribute:"disabled-focusable",mode:"boolean"})],vo.prototype,"disabledFocusable",void 0),mo([A],vo.prototype,"defaultSlottedContent",void 0);let yo=class{};function Co(e={}){return Be`
<button
class="control"
part="control"
?autofocus="${e=>e.autofocus}"
?disabled="${e=>e.disabled}"
form="${e=>e.formId}"
formaction="${e=>e.formaction}"
formenctype="${e=>e.formenctype}"
formmethod="${e=>e.formmethod}"
?formnovalidate="${e=>e.formnovalidate}"
formtarget="${e=>e.formtarget}"
name="${e=>e.name}"
type="${e=>e.type}"
value="${e=>e.value}"
aria-atomic="${e=>e.ariaAtomic}"
aria-busy="${e=>e.ariaBusy}"
aria-controls="${e=>e.ariaControls}"
aria-current="${e=>e.ariaCurrent}"
aria-describedby="${e=>e.ariaDescribedby}"
aria-details="${e=>e.ariaDetails}"
aria-disabled="${e=>e.ariaDisabled}"
aria-errormessage="${e=>e.ariaErrormessage}"
aria-expanded="${e=>e.ariaExpanded}"
aria-flowto="${e=>e.ariaFlowto}"
aria-haspopup="${e=>e.ariaHaspopup}"
aria-hidden="${e=>e.ariaHidden}"
aria-invalid="${e=>e.ariaInvalid}"
aria-keyshortcuts="${e=>e.ariaKeyshortcuts}"
aria-label="${e=>e.ariaLabel}"
aria-labelledby="${e=>e.ariaLabelledby}"
aria-live="${e=>e.ariaLive}"
aria-owns="${e=>e.ariaOwns}"
aria-pressed="${e=>e.ariaPressed}"
aria-relevant="${e=>e.ariaRelevant}"
aria-roledescription="${e=>e.ariaRoledescription}"
${Ue("control")}
>
${cn(e)}
<span class="content" part="content">
<slot ${Qe("defaultSlottedContent")}></slot>
</span>
${ln(e)}
</button>
`}mo([st({attribute:"aria-expanded"})],yo.prototype,"ariaExpanded",void 0),mo([st({attribute:"aria-pressed"})],yo.prototype,"ariaPressed",void 0),dn(yo,en),dn(vo,sn,yo);const bo=Co(),So=vo.compose({name:`${un.prefix}-button`,template:bo,styles:to,shadowOptions:{delegatesFocus:!0}});var xo=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};let To=class extends Pt{constructor(){super(...arguments),this.disabled=!1,this.required=!1}};xo([st],To.prototype,"size",void 0),xo([st],To.prototype,"weight",void 0),xo([st({mode:"boolean"})],To.prototype,"disabled",void 0),xo([st({mode:"boolean"})],To.prototype,"required",void 0);const wo=re`
${nn("flex")}
:host {
font-family: ${Hn};
font-size: ${Zn};
line-height: ${Wn};
font-weight: ${Gn};
color: ${hn};
}
.asterisk {
color: ${_n};
margin-left: ${Xn};
}
:host([size='small']) {
font-size: ${$n};
line-height: ${zn};
}
:host([size='large']) {
font-size: ${Vn};
line-height: ${Kn};
font-weight: ${jn};
}
:host([weight='semibold']) {
font-weight: ${jn};
}
:host([disabled]),
:host([disabled]) .asterisk {
color: ${Cn};
}
`,Oo=Be`
<slot></slot>
<span part="asterisk" class="asterisk" ?hidden="${e=>!e.required}">*</span>
`,Po=To.compose({name:`${un.prefix}-label`,template:Oo,styles:wo}),Ao=["top","right","bottom","left"],Eo=Math.min,ko=Math.max,Io=Math.round,Do=Math.floor,_o=e=>({x:e,y:e}),No={left:"right",right:"left",bottom:"top",top:"bottom"},Ro={start:"end",end:"start"};function Mo(e,t,i){return ko(e,Eo(t,i))}function Lo(e,t){return"function"==typeof e?e(t):e}function Bo(e){return e.split("-")[0]}function Fo(e){return e.split("-")[1]}function Uo(e){return"x"===e?"y":"x"}function Ho(e){return"y"===e?"height":"width"}function $o(e){return["top","bottom"].includes(Bo(e))?"y":"x"}function Zo(e){return Uo($o(e))}function Vo(e){return e.replace(/start|end/g,(e=>Ro[e]))}function Go(e){return e.replace(/left|right|bottom|top/g,(e=>No[e]))}function jo(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}function zo(e,t,i){let{reference:n,floating:o}=e;const r=$o(t),a=Zo(t),s=Ho(a),l=Bo(t),c="y"===r,d=n.x+n.width/2-o.width/2,u=n.y+n.height/2-o.height/2,h=n[s]/2-o[s]/2;let p;switch(l){case"top":p={x:d,y:n.y-o.height};break;case"bottom":p={x:d,y:n.y+n.height};break;case"right":p={x:n.x+n.width,y:u};break;case"left":p={x:n.x-o.width,y:u};break;default:p={x:n.x,y:n.y}}switch(Fo(t)){case"start":p[a]-=h*(i&&c?-1:1);break;case"end":p[a]+=h*(i&&c?-1:1)}return p}async function Wo(e,t){var i;void 0===t&&(t={});const{x:n,y:o,platform:r,rects:a,elements:s,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:d="viewport",elementContext:u="floating",altBoundary:h=!1,padding:p=0}=Lo(t,e),g=function(e){return"number"!=typeof e?function(e){return{top:0,right:0,bottom:0,left:0,...e}}(e):{top:e,right:e,bottom:e,left:e}}(p),f=s[h?"floating"===u?"reference":"floating":u],m=jo(await r.getClippingRect({element:null==(i=await(null==r.isElement?void 0:r.isElement(f)))||i?f:f.contextElement||await(null==r.getDocumentElement?void 0:r.getDocumentElement(s.floating)),boundary:c,rootBoundary:d,strategy:l})),v="floating"===u?{...a.floating,x:n,y:o}:a.reference,y=await(null==r.getOffsetParent?void 0:r.getOffsetParent(s.floating)),C=await(null==r.isElement?void 0:r.isElement(y))&&await(null==r.getScale?void 0:r.getScale(y))||{x:1,y:1},b=jo(r.convertOffsetParentRelativeRectToViewportRelativeRect?await r.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:v,offsetParent:y,strategy:l}):v);return{top:(m.top-b.top+g.top)/C.y,bottom:(b.bottom-m.bottom+g.bottom)/C.y,left:(m.left-b.left+g.left)/C.x,right:(b.right-m.right+g.right)/C.x}}function Ko(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function qo(e){return Ao.some((t=>e[t]>=0))}function Yo(e){return Qo(e)?(e.nodeName||"").toLowerCase():"#document"}function Xo(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function Jo(e){var t;return null==(t=(Qo(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function Qo(e){return e instanceof Node||e instanceof Xo(e).Node}function er(e){return e instanceof Element||e instanceof Xo(e).Element}function tr(e){return e instanceof HTMLElement||e instanceof Xo(e).HTMLElement}function ir(e){return"undefined"!=typeof ShadowRoot&&(e instanceof ShadowRoot||e instanceof Xo(e).ShadowRoot)}function nr(e){const{overflow:t,overflowX:i,overflowY:n,display:o}=lr(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+i)&&!["inline","contents"].includes(o)}function or(e){return["table","td","th"].includes(Yo(e))}function rr(e){const t=ar(),i=lr(e);return"none"!==i.transform||"none"!==i.perspective||!!i.containerType&&"normal"!==i.containerType||!t&&!!i.backdropFilter&&"none"!==i.backdropFilter||!t&&!!i.filter&&"none"!==i.filter||["transform","perspective","filter"].some((e=>(i.willChange||"").includes(e)))||["paint","layout","strict","content"].some((e=>(i.contain||"").includes(e)))}function ar(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function sr(e){return["html","body","#document"].includes(Yo(e))}function lr(e){return Xo(e).getComputedStyle(e)}function cr(e){return er(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function dr(e){if("html"===Yo(e))return e;const t=e.assignedSlot||e.parentNode||ir(e)&&e.host||Jo(e);return ir(t)?t.host:t}function ur(e){const t=dr(e);return sr(t)?e.ownerDocument?e.ownerDocument.body:e.body:tr(t)&&nr(t)?t:ur(t)}function hr(e,t,i){var n;void 0===t&&(t=[]),void 0===i&&(i=!0);const o=ur(e),r=o===(null==(n=e.ownerDocument)?void 0:n.body),a=Xo(o);return r?t.concat(a,a.visualViewport||[],nr(o)?o:[],a.frameElement&&i?hr(a.frameElement):[]):t.concat(o,hr(o,[],i))}function pr(e){const t=lr(e);let i=parseFloat(t.width)||0,n=parseFloat(t.height)||0;const o=tr(e),r=o?e.offsetWidth:i,a=o?e.offsetHeight:n,s=Io(i)!==r||Io(n)!==a;return s&&(i=r,n=a),{width:i,height:n,$:s}}function gr(e){return er(e)?e:e.contextElement}function fr(e){const t=gr(e);if(!tr(t))return _o(1);const i=t.getBoundingClientRect(),{width:n,height:o,$:r}=pr(t);let a=(r?Io(i.width):i.width)/n,s=(r?Io(i.height):i.height)/o;return a&&Number.isFinite(a)||(a=1),s&&Number.isFinite(s)||(s=1),{x:a,y:s}}const mr=_o(0);function vr(e){const t=Xo(e);return ar()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:mr}function yr(e,t,i,n){void 0===t&&(t=!1),void 0===i&&(i=!1);const o=e.getBoundingClientRect(),r=gr(e);let a=_o(1);t&&(n?er(n)&&(a=fr(n)):a=fr(e));const s=function(e,t,i){return void 0===t&&(t=!1),!(!i||t&&i!==Xo(e))&&t}(r,i,n)?vr(r):_o(0);let l=(o.left+s.x)/a.x,c=(o.top+s.y)/a.y,d=o.width/a.x,u=o.height/a.y;if(r){const e=Xo(r),t=n&&er(n)?Xo(n):n;let i=e,o=i.frameElement;for(;o&&n&&t!==i;){const e=fr(o),t=o.getBoundingClientRect(),n=lr(o),r=t.left+(o.clientLeft+parseFloat(n.paddingLeft))*e.x,a=t.top+(o.clientTop+parseFloat(n.paddingTop))*e.y;l*=e.x,c*=e.y,d*=e.x,u*=e.y,l+=r,c+=a,i=Xo(o),o=i.frameElement}}return jo({width:d,height:u,x:l,y:c})}const Cr=[":popover-open",":modal"];function br(e){return Cr.some((t=>{try{return e.matches(t)}catch(e){return!1}}))}function Sr(e){return yr(Jo(e)).left+cr(e).scrollLeft}function xr(e,t,i){let n;if("viewport"===t)n=function(e,t){const i=Xo(e),n=Jo(e),o=i.visualViewport;let r=n.clientWidth,a=n.clientHeight,s=0,l=0;if(o){r=o.width,a=o.height;const e=ar();(!e||e&&"fixed"===t)&&(s=o.offsetLeft,l=o.offsetTop)}return{width:r,height:a,x:s,y:l}}(e,i);else if("document"===t)n=function(e){const t=Jo(e),i=cr(e),n=e.ownerDocument.body,o=ko(t.scrollWidth,t.clientWidth,n.scrollWidth,n.clientWidth),r=ko(t.scrollHeight,t.clientHeight,n.scrollHeight,n.clientHeight);let a=-i.scrollLeft+Sr(e);const s=-i.scrollTop;return"rtl"===lr(n).direction&&(a+=ko(t.clientWidth,n.clientWidth)-o),{width:o,height:r,x:a,y:s}}(Jo(e));else if(er(t))n=function(e,t){const i=yr(e,!0,"fixed"===t),n=i.top+e.clientTop,o=i.left+e.clientLeft,r=tr(e)?fr(e):_o(1);return{width:e.clientWidth*r.x,height:e.clientHeight*r.y,x:o*r.x,y:n*r.y}}(t,i);else{const i=vr(e);n={...t,x:t.x-i.x,y:t.y-i.y}}return jo(n)}function Tr(e,t){const i=dr(e);return!(i===t||!er(i)||sr(i))&&("fixed"===lr(i).position||Tr(i,t))}function wr(e,t,i){const n=tr(t),o=Jo(t),r="fixed"===i,a=yr(e,!0,r,t);let s={scrollLeft:0,scrollTop:0};const l=_o(0);if(n||!n&&!r)if(("body"!==Yo(t)||nr(o))&&(s=cr(t)),n){const e=yr(t,!0,r,t);l.x=e.x+t.clientLeft,l.y=e.y+t.clientTop}else o&&(l.x=Sr(o));return{x:a.left+s.scrollLeft-l.x,y:a.top+s.scrollTop-l.y,width:a.width,height:a.height}}function Or(e,t){return tr(e)&&"fixed"!==lr(e).position?t?t(e):e.offsetParent:null}function Pr(e,t){const i=Xo(e);if(!tr(e)||br(e))return i;let n=Or(e,t);for(;n&&or(n)&&"static"===lr(n).position;)n=Or(n,t);return n&&("html"===Yo(n)||"body"===Yo(n)&&"static"===lr(n).position&&!rr(n))?i:n||function(e){let t=dr(e);for(;tr(t)&&!sr(t);){if(rr(t))return t;t=dr(t)}return null}(e)||i}const Ar={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:t,rect:i,offsetParent:n,strategy:o}=e;const r="fixed"===o,a=Jo(n),s=!!t&&br(t.floating);if(n===a||s&&r)return i;let l={scrollLeft:0,scrollTop:0},c=_o(1);const d=_o(0),u=tr(n);if((u||!u&&!r)&&(("body"!==Yo(n)||nr(a))&&(l=cr(n)),tr(n))){const e=yr(n);c=fr(n),d.x=e.x+n.clientLeft,d.y=e.y+n.clientTop}return{width:i.width*c.x,height:i.height*c.y,x:i.x*c.x-l.scrollLeft*c.x+d.x,y:i.y*c.y-l.scrollTop*c.y+d.y}},getDocumentElement:Jo,getClippingRect:function(e){let{element:t,boundary:i,rootBoundary:n,strategy:o}=e;const r=[..."clippingAncestors"===i?function(e,t){const i=t.get(e);if(i)return i;let n=hr(e,[],!1).filter((e=>er(e)&&"body"!==Yo(e))),o=null;const r="fixed"===lr(e).position;let a=r?dr(e):e;for(;er(a)&&!sr(a);){const t=lr(a),i=rr(a);i||"fixed"!==t.position||(o=null),(r?!i&&!o:!i&&"static"===t.position&&o&&["absolute","fixed"].includes(o.position)||nr(a)&&!i&&Tr(e,a))?n=n.filter((e=>e!==a)):o=t,a=dr(a)}return t.set(e,n),n}(t,this._c):[].concat(i),n],a=r[0],s=r.reduce(((e,i)=>{const n=xr(t,i,o);return e.top=ko(n.top,e.top),e.right=Eo(n.right,e.right),e.bottom=Eo(n.bottom,e.bottom),e.left=ko(n.left,e.left),e}),xr(t,a,o));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}},getOffsetParent:Pr,getElementRects:async function(e){const t=this.getOffsetParent||Pr,i=this.getDimensions;return{reference:wr(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,...await i(e.floating)}}},getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){const{width:t,height:i}=pr(e);return{width:t,height:i}},getScale:fr,isElement:er,isRTL:function(e){return"rtl"===lr(e).direction}};function Er(e,t,i,n){void 0===n&&(n={});const{ancestorScroll:o=!0,ancestorResize:r=!0,elementResize:a="function"==typeof ResizeObserver,layoutShift:s="function"==typeof IntersectionObserver,animationFrame:l=!1}=n,c=gr(e),d=o||r?[...c?hr(c):[],...hr(t)]:[];d.forEach((e=>{o&&e.addEventListener("scroll",i,{passive:!0}),r&&e.addEventListener("resize",i)}));const u=c&&s?function(e,t){let i,n=null;const o=Jo(e);function r(){var e;clearTimeout(i),null==(e=n)||e.disconnect(),n=null}return function a(s,l){void 0===s&&(s=!1),void 0===l&&(l=1),r();const{left:c,top:d,width:u,height:h}=e.getBoundingClientRect();if(s||t(),!u||!h)return;const p={rootMargin:-Do(d)+"px "+-Do(o.clientWidth-(c+u))+"px "+-Do(o.clientHeight-(d+h))+"px "+-Do(c)+"px",threshold:ko(0,Eo(1,l))||1};let g=!0;function f(e){const t=e[0].intersectionRatio;if(t!==l){if(!g)return a();t?a(!1,t):i=setTimeout((()=>{a(!1,1e-7)}),100)}g=!1}try{n=new IntersectionObserver(f,{...p,root:o.ownerDocument})}catch(e){n=new IntersectionObserver(f,p)}n.observe(e)}(!0),r}(c,i):null;let h,p=-1,g=null;a&&(g=new ResizeObserver((e=>{let[n]=e;n&&n.target===c&&g&&(g.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame((()=>{var e;null==(e=g)||e.observe(t)}))),i()})),c&&!l&&g.observe(c),g.observe(t));let f=l?yr(e):null;return l&&function t(){const n=yr(e);!f||n.x===f.x&&n.y===f.y&&n.width===f.width&&n.height===f.height||i(),f=n,h=requestAnimationFrame(t)}(),i(),()=>{var e;d.forEach((e=>{o&&e.removeEventListener("scroll",i),r&&e.removeEventListener("resize",i)})),null==u||u(),null==(e=g)||e.disconnect(),g=null,l&&cancelAnimationFrame(h)}}const kr=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var i,n;const{placement:o,middlewareData:r,rects:a,initialPlacement:s,platform:l,elements:c}=t,{mainAxis:d=!0,crossAxis:u=!0,fallbackPlacements:h,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:g="none",flipAlignment:f=!0,...m}=Lo(e,t);if(null!=(i=r.arrow)&&i.alignmentOffset)return{};const v=Bo(o),y=Bo(s)===s,C=await(null==l.isRTL?void 0:l.isRTL(c.floating)),b=h||(y||!f?[Go(s)]:function(e){const t=Go(e);return[Vo(e),t,Vo(t)]}(s));h||"none"===g||b.push(...function(e,t,i,n){const o=Fo(e);let r=function(e,t,i){const n=["left","right"],o=["right","left"],r=["top","bottom"],a=["bottom","top"];switch(e){case"top":case"bottom":return i?t?o:n:t?n:o;case"left":case"right":return t?r:a;default:return[]}}(Bo(e),"start"===i,n);return o&&(r=r.map((e=>e+"-"+o)),t&&(r=r.concat(r.map(Vo)))),r}(s,f,g,C));const S=[s,...b],x=await Wo(t,m),T=[];let w=(null==(n=r.flip)?void 0:n.overflows)||[];if(d&&T.push(x[v]),u){const e=function(e,t,i){void 0===i&&(i=!1);const n=Fo(e),o=Zo(e),r=Ho(o);let a="x"===o?n===(i?"end":"start")?"right":"left":"start"===n?"bottom":"top";return t.reference[r]>t.floating[r]&&(a=Go(a)),[a,Go(a)]}(o,a,C);T.push(x[e[0]],x[e[1]])}if(w=[...w,{placement:o,overflows:T}],!T.every((e=>e<=0))){var O,P;const e=((null==(O=r.flip)?void 0:O.index)||0)+1,t=S[e];if(t)return{data:{index:e,overflows:w},reset:{placement:t}};let i=null==(P=w.filter((e=>e.overflows[0]<=0)).sort(((e,t)=>e.overflows[1]-t.overflows[1]))[0])?void 0:P.placement;if(!i)switch(p){case"bestFit":{var A;const e=null==(A=w.map((e=>[e.placement,e.overflows.filter((e=>e>0)).reduce(((e,t)=>e+t),0)])).sort(((e,t)=>e[1]-t[1]))[0])?void 0:A[0];e&&(i=e);break}case"initialPlacement":i=s}if(o!==i)return{reset:{placement:i}}}return{}}}},Ir=function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){const{placement:i,rects:n,platform:o,elements:r}=t,{apply:a=(()=>{}),...s}=Lo(e,t),l=await Wo(t,s),c=Bo(i),d=Fo(i),u="y"===$o(i),{width:h,height:p}=n.floating;let g,f;"top"===c||"bottom"===c?(g=c,f=d===(await(null==o.isRTL?void 0:o.isRTL(r.floating))?"start":"end")?"left":"right"):(f=c,g="end"===d?"top":"bottom");const m=p-l[g],v=h-l[f],y=!t.middlewareData.shift;let C=m,b=v;if(u){const e=h-l.left-l.right;b=d||y?Eo(v,e):e}else{const e=p-l.top-l.bottom;C=d||y?Eo(m,e):e}if(y&&!d){const e=ko(l.left,0),t=ko(l.right,0),i=ko(l.top,0),n=ko(l.bottom,0);u?b=h-2*(0!==e||0!==t?e+t:ko(l.left,l.right)):C=p-2*(0!==i||0!==n?i+n:ko(l.top,l.bottom))}await a({...t,availableWidth:b,availableHeight:C});const S=await o.getDimensions(r.floating);return h!==S.width||p!==S.height?{reset:{rects:!0}}:{}}}},Dr=(e,t,i)=>{const n=new Map,o={platform:Ar,...i},r={...o.platform,_c:n};return(async(e,t,i)=>{const{placement:n="bottom",strategy:o="absolute",middleware:r=[],platform:a}=i,s=r.filter(Boolean),l=await(null==a.isRTL?void 0:a.isRTL(t));let c=await a.getElementRects({reference:e,floating:t,strategy:o}),{x:d,y:u}=zo(c,n,l),h=n,p={},g=0;for(let i=0;i<s.length;i++){const{name:r,fn:f}=s[i],{x:m,y:v,data:y,reset:C}=await f({x:d,y:u,initialPlacement:n,placement:h,strategy:o,middlewareData:p,rects:c,platform:a,elements:{reference:e,floating:t}});d=null!=m?m:d,u=null!=v?v:u,p={...p,[r]:{...p[r],...y}},C&&g<=50&&(g++,"object"==typeof C&&(C.placement&&(h=C.placement),C.rects&&(c=!0===C.rects?await a.getElementRects({reference:e,floating:t,strategy:o}):C.rects),({x:d,y:u}=zo(c,h,l))),i=-1)}return{x:d,y:u,placement:h,strategy:o,middlewareData:p}})(e,t,{...o,platform:r})};var _r=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};let Nr=class extends Pt{constructor(){super(...arguments),this.openOnHover=!1,this.openOnContext=!1,this.closeOnScroll=!1,this.persistOnItemClick=!1,this.open=!1,this.slottedMenuList=[],this.slottedTriggers=[],this.toggleMenu=()=>{this.open?this.closeMenu():this.openMenu()},this.closeMenu=()=>{this.open=!1,this.closeOnScroll&&document.removeEventListener("scroll",this.closeMenu)},this.openMenu=e=>{this.open=!0,e&&this.openOnContext&&e.preventDefault(),this.closeOnScroll&&document.addEventListener("scroll",this.closeMenu)},this.setPositioningTask=()=>{this.setPositioning()},this.handleTriggerKeydown=e=>{if(!e.defaultPrevented)switch(e.key){case" ":case Xi:e.preventDefault(),this.toggleMenu(),this.open&&this.focusMenuList();break;default:return!0}},this.handleDocumentClick=e=>{!e||e.composedPath().includes(this._menuList)||e.composedPath().includes(this._trigger)||this.closeMenu()}}connectedCallback(){super.connectedCallback(),x.enqueue((()=>this.setComponent()))}disconnectedCallback(){var e;super.disconnectedCallback(),null===(e=this.cleanup)||void 0===e||e.call(this),this.removeListeners()}setComponent(){this.$fastController.isConnected&&this.slottedMenuList.length&&this.slottedTriggers.length&&(this._trigger=this.slottedTriggers[0],this._menuList=this.slottedMenuList[0],this._trigger.setAttribute("aria-haspopup","true"),this._trigger.setAttribute("aria-expanded",`${this.open}`),this.addListeners())}focusMenuList(){this.open&&this._menuList&&x.enqueue((()=>{this._menuList.focus()}))}focusTrigger(){!this.open&&this._trigger&&x.enqueue((()=>{this._trigger.focus()}))}openChanged(e,t){var i;this.$fastController.isConnected&&this._trigger instanceof HTMLElement&&(this._trigger.setAttribute("aria-expanded",`${this.open}`),this._menuList&&this.open&&x.enqueue(this.setPositioningTask)),null===(i=this.cleanup)||void 0===i||i.call(this),this.$emit("onOpenChange",{open:t})}openOnHoverChanged(e,t){var i,n;t?null===(i=this._trigger)||void 0===i||i.addEventListener("mouseover",this.openMenu):null===(n=this._trigger)||void 0===n||n.removeEventListener("mouseover",this.openMenu)}persistOnItemClickChanged(e,t){var i,n;t?null===(n=this._menuList)||void 0===n||n.removeEventListener("click",this.closeMenu):null===(i=this._menuList)||void 0===i||i.addEventListener("click",this.closeMenu)}openOnContextChanged(e,t){var i,n;t?null===(i=this._trigger)||void 0===i||i.addEventListener("contextmenu",this.openMenu):null===(n=this._trigger)||void 0===n||n.removeEventListener("contextmenu",this.openMenu)}closeOnScrollChanged(e,t){t?document.addEventListener("scroll",this.closeMenu):document.removeEventListener("scroll",this.closeMenu)}setPositioning(){this.$fastController.isConnected&&this._menuList&&this.open&&this._trigger&&(this.cleanup=Er(this,this.positioningContainer,(async()=>{var e,t;const{middlewareData:i,x:n,y:o}=await Dr(this._trigger,this.positioningContainer,{placement:"bottom",strategy:"fixed",middleware:[kr(),Ir({apply:({availableHeight:e,rects:t})=>{var i;(null===(i=this.positioningContainer)||void 0===i?void 0:i.style)&&Object.assign(this.positioningContainer.style,{maxHeight:`${e}px`,width:`${t.reference.width}px`})}}),(void 0===r&&(r={}),{name:"hide",options:r,async fn(e){const{rects:t}=e,{strategy:i="referenceHidden",...n}=Lo(r,e);switch(i){case"referenceHidden":{const i=Ko(await Wo(e,{...n,elementContext:"reference"}),t.reference);return{data:{referenceHiddenOffsets:i,referenceHidden:qo(i)}}}case"escaped":{const i=Ko(await Wo(e,{...n,altBoundary:!0}),t.floating);return{data:{escapedOffsets:i,escaped:qo(i)}}}default:return{}}}})]});var r;(null===(e=i.hide)||void 0===e?void 0:e.referenceHidden)?this.open=!1:(null===(t=this.positioningContainer)||void 0===t?void 0:t.style)&&Object.assign(this.positioningContainer.style,{position:"fixed",top:"0",left:"0",transform:`translate(${n}px, ${o}px)`})})))}addListeners(){var e,t,i,n,o;document.addEventListener("click",this.handleDocumentClick),null===(e=this._trigger)||void 0===e||e.addEventListener("keydown",this.handleTriggerKeydown),this.persistOnItemClick||null===(t=this._menuList)||void 0===t||t.addEventListener("click",this.closeMenu),this.openOnHover?null===(i=this._trigger)||void 0===i||i.addEventListener("mouseover",this.openMenu):this.openOnContext?null===(n=this._trigger)||void 0===n||n.addEventListener("contextmenu",this.openMenu):null===(o=this._trigger)||void 0===o||o.addEventListener("click",this.toggleMenu)}removeListeners(){var e,t,i,n,o;document.removeEventListener("click",this.handleDocumentClick),null===(e=this._trigger)||void 0===e||e.removeEventListener("keydown",this.handleTriggerKeydown),this.persistOnItemClick||null===(t=this._menuList)||void 0===t||t.removeEventListener("click",this.closeMenu),this.openOnHover&&(null===(i=this._trigger)||void 0===i||i.removeEventListener("mouseover",this.openMenu)),this.openOnContext?null===(n=this._trigger)||void 0===n||n.removeEventListener("contextmenu",this.openMenu):null===(o=this._trigger)||void 0===o||o.removeEventListener("click",this.toggleMenu)}handleMenuKeydown(e){if(!e.defaultPrevented)switch(e.key){case Ji:e.preventDefault(),this.open&&(this.closeMenu(),this.focusTrigger());break;case"Tab":this.open&&this.closeMenu(),e.shiftKey&&this.focusTrigger();default:return!0}}};_r([A,st({attribute:"open-on-hover",mode:"boolean"})],Nr.prototype,"openOnHover",void 0),_r([A,st({attribute:"open-on-context",mode:"boolean"})],Nr.prototype,"openOnContext",void 0),_r([A,st({attribute:"close-on-scroll",mode:"boolean"})],Nr.prototype,"closeOnScroll",void 0),_r([A,st({attribute:"persist-on-item-click",mode:"boolean"})],Nr.prototype,"persistOnItemClick",void 0),_r([A,st({mode:"boolean"})],Nr.prototype,"open",void 0),_r([A],Nr.prototype,"slottedMenuList",void 0),_r([A],Nr.prototype,"slottedTriggers",void 0);const Rr=Be`
<template
?open-on-hover="${e=>e.openOnHover}"
?open-on-context="${e=>e.openOnContext}"
?close-on-scroll="${e=>e.closeOnScroll}"
?persist-on-item-click="${e=>e.persistOnItemClick}"
@keydown="${(e,t)=>e.handleMenuKeydown(t.event)}"
>
<slot name="trigger" ${Qe({property:"slottedTriggers",filter:qe()})}></slot>
<span
${Ue("positioningContainer")}
part="positioning-container"
class="positioning-container"
?hidden="${e=>!e.open}"
>
<slot ${Qe({property:"slottedMenuList",filter:qe()})}></slot>
</span>
</template>
`,Mr=re`
:host {
position: relative;
z-index: var(--z-index-menu, 1);
}
.positioning-container {
position: fixed;
top: 0;
left: 0;
transform: translate(0, 0);
}
`,Lr=Nr.compose({name:`${un.prefix}-menu`,template:Rr,styles:Mr}),Br=Co({end:Be.partial('<svg slot="end" fill="currentColor" aria-hidden="true" width="1em" height="1em" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path d="M15.85 7.65c.2.2.2.5 0 .7l-5.46 5.49a.55.55 0 0 1-.78 0L4.15 8.35a.5.5 0 1 1 .7-.7L10 12.8l5.15-5.16c.2-.2.5-.2.7 0Z" fill="currentColor"></path></svg>')}),Fr=class extends vo{}.compose({name:`${un.prefix}-menu-button`,template:Br,styles:to,shadowOptions:{delegatesFocus:!0}}),Ur={menuitem:"menuitem",menuitemcheckbox:"menuitemcheckbox",menuitemradio:"menuitemradio"};var Hr=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};let $r=class extends Pt{constructor(){super(...arguments),this.role=Ur.menuitem,this.checked=!1,this.focusSubmenuOnLoad=!1,this.handleMenuItemKeyDown=e=>{if(e.defaultPrevented)return!1;switch(e.key){case Xi:case" ":return this.invoke(),!1;case"ArrowRight":return this.expanded&&this.submenu?this.submenu.focus():this.expandAndFocus(),!1;case Ji:case"ArrowLeft":if(this.expanded)return this.closeSubMenu(),!1}return!0},this.handleMenuItemClick=e=>(e.defaultPrevented||this.disabled||this.invoke(),!1),this.submenuLoaded=()=>{this.focusSubmenuOnLoad&&(this.focusSubmenuOnLoad=!1,this.submenu&&(this.submenu.focus(),this.setAttribute("tabindex","-1")))},this.handleMouseOver=e=>(this.disabled||!this.hasSubmenu||this.expanded||(this.expanded=!0),!1),this.handleMouseOut=e=>(!this.expanded||this.contains(document.activeElement)||(this.expanded=!1),!1),this.closeSubMenu=()=>{this.expanded=!1,this.focus()},this.expandAndFocus=()=>{this.hasSubmenu&&(this.focusSubmenuOnLoad=!0,this.expanded=!0)},this.invoke=()=>{if(!this.disabled)switch(this.role){case Ur.menuitemcheckbox:this.checked=!this.checked;break;case Ur.menuitem:if(this.hasSubmenu){this.expandAndFocus();break}this.$emit("change");break;case Ur.menuitemradio:this.checked||(this.checked=!0)}}}expandedChanged(e,t){this.$fastController.isConnected&&(t&&this.submenu&&this.updateSubmenu(),this.$emit("expanded-change",this,{bubbles:!1}))}checkedChanged(e,t){this.$fastController.isConnected&&this.$emit("change")}get hasSubmenu(){return!!this.submenu}slottedSubmenuChanged(e,t){t.length&&(this.submenu=t[0],this.updateSubmenu())}disconnectedCallback(){var e;null===(e=this.cleanup)||void 0===e||e.call(this),super.disconnectedCallback()}updateSubmenu(){var e;null===(e=this.cleanup)||void 0===e||e.call(this),this.submenu&&this.expanded&&x.enqueue((()=>{this.cleanup=Er(this,this.submenuContainer,(async()=>{const e=["left-start","right-start"],{x:t,y:i}=await Dr(this,this.submenuContainer,{middleware:[(void 0===n&&(n={}),{name:"shift",options:n,async fn(e){const{x:t,y:i,placement:o}=e,{mainAxis:r=!0,crossAxis:a=!1,limiter:s={fn:e=>{let{x:t,y:i}=e;return{x:t,y:i}}},...l}=Lo(n,e),c={x:t,y:i},d=await Wo(e,l),u=$o(Bo(o)),h=Uo(u);let p=c[h],g=c[u];if(r){const e="y"===h?"bottom":"right";p=Mo(p+d["y"===h?"top":"left"],p,p-d[e])}if(a){const e="y"===u?"bottom":"right";g=Mo(g+d["y"===u?"top":"left"],g,g-d[e])}const f=s.fn({...e,[h]:p,[u]:g});return{...f,data:{x:f.x-t,y:f.y-i}}}}),Ir({apply:({availableWidth:t,rects:i})=>{t<i.floating.width&&e.push("bottom-end","top-end")}}),kr({fallbackPlacements:e})],placement:"right-start",strategy:"fixed"});var n;Object.assign(this.submenuContainer.style,{left:`${t}px`,position:"fixed",top:`${i}px`}),this.submenuLoaded()}))}))}};Hr([st({mode:"boolean"})],$r.prototype,"disabled",void 0),Hr([st({mode:"boolean"})],$r.prototype,"expanded",void 0),Hr([st],$r.prototype,"role",void 0),Hr([st({mode:"boolean"})],$r.prototype,"checked",void 0),Hr([st({mode:"boolean"})],$r.prototype,"hidden",void 0),Hr([A],$r.prototype,"slottedSubmenu",void 0),Hr([A],$r.prototype,"submenu",void 0),dn($r,sn);const Zr=Be.partial('<svg fill="currentColor" class="___12fm75w f1w7gpdv fez10in fg4l7m0" aria-hidden="true" width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M14.05 3.49c.28.3.27.77-.04 1.06l-7.93 7.47A.85.85 0 014.9 12L2.22 9.28a.75.75 0 111.06-1.06l2.24 2.27 7.47-7.04a.75.75 0 011.06.04z" fill="currentColor"></path></svg>'),Vr=function(e={}){return Be`
<template
aria-haspopup="${e=>e.hasSubmenu?"menu":void 0}"
aria-checked="${e=>e.role!==Ur.menuitem?e.checked:void 0}"
aria-disabled="${e=>e.disabled}"
aria-expanded="${e=>e.expanded}"
@keydown="${(e,t)=>e.handleMenuItemKeyDown(t.event)}"
@click="${(e,t)=>e.handleMenuItemClick(t.event)}"
@mouseover="${(e,t)=>e.handleMouseOver(t.event)}"
@mouseout="${(e,t)=>e.handleMouseOut(t.event)}"
>
${Ze((e=>e.role===Ur.menuitemcheckbox),Be`
<div part="input-container" class="input-container">
<span part="checkbox" class="checkbox">
<slot name="checkbox-indicator"> ${tn(e.checkboxIndicator)} </slot>
</span>
</div>
`)}
${Ze((e=>e.role===Ur.menuitemradio),Be`
<div part="input-container" class="input-container">
<span part="radio" class="radio">
<slot name="radio-indicator"> ${tn(e.radioIndicator)} </slot>
</span>
</div>
`)}
</div>
${cn(e)}
<span class="content" part="content">
<slot></slot>
</span>
${ln(e)}
${Ze((e=>e.hasSubmenu),Be`
<div part="expand-collapse-glyph-container" class="expand-collapse-glyph-container">
<span part="expand-collapse" class="expand-collapse">
<slot name="expand-collapse-indicator"> ${tn(e.expandCollapseGlyph)} </slot>
</span>
</div>
`)}
<span
?hidden="${e=>!e.expanded}"
class="submenu-container"
part="submenu-container"
${Ue("submenuContainer")}
>
<slot name="submenu" ${Qe({property:"slottedSubmenu",filter:qe("[role='menu']")})}></slot>
</span>
</template>
`}({checkboxIndicator:Zr,expandCollapseGlyph:Be.partial('<svg fill="currentColor" class="___12fm75w f1w7gpdv fez10in fg4l7m0" aria-hidden="true" width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M5.74 3.2a.75.75 0 00-.04 1.06L9.23 8 5.7 11.74a.75.75 0 101.1 1.02l4-4.25a.75.75 0 000-1.02l-4-4.25a.75.75 0 00-1.06-.04z" fill="currentColor"></path></svg>'),radioIndicator:Zr}),Gr=re`
${nn("grid")}
:host {
grid-template-columns: 20px 20px auto 20px;
align-items: center;
grid-gap: 4px;
height: 32px;
background: ${xn};
font: ${Gn} ${Zn} / ${Wn} ${Hn};
border-radius: ${Fn};
color: ${pn};
padding: 0 10px;
cursor: pointer;
overflow: visible;
contain: layout;
}
:host(:hover) {
background: ${Tn};
}
.content {
white-space: nowrap;
flex-grow: 1;
grid-column: auto / span 2;
padding: 0 2px;
}
.checkbox,
.radio {
display: none;
}
.input-container,
.expand-collapse-glyph-container,
::slotted([slot='start']),
::slotted([slot='end']),
:host([checked]) .checkbox,
:host([checked]) .radio {
display: inline-flex;
justify-content: center;
align-items: center;
color: ${pn};
}
.expand-collapse-glyph-container,
::slotted([slot='start']),
::slotted([slot='end']) {
height: 32px;
font-size: ${"var(--fontSizeBase500)"};
width: fit-content;
}
.input-container {
width: 20px;
}
::slotted([slot='end']) {
color: ${yn};
font: ${Gn} ${$n} / ${zn} ${Hn};
white-space: nowrap;
grid-column: 4 / span 1;
justify-self: flex-end;
}
.expand-collapse-glyph-container {
grid-column: 4 / span 1;
justify-self: flex-end;
}
:host(:hover) .input-container,
:host(:hover) .expand-collapse-glyph-container,
:host(:hover) .content {
color: ${gn};
}
:host([icon]:hover) ::slotted([slot='start']) {
color: ${"var(--colorCompoundBrandForeground1Hover)"};
}
:host(:active) {
background-color: ${"var(--colorNeutralBackground1Selected)"};
}
:host(:active) .input-container,
:host(:active) .expand-collapse-glyph-container,
:host(:active) .content {
color: ${fn};
}
:host(:active) ::slotted([slot='start']) {
color: ${"var(--colorCompoundBrandForeground1Pressed)"};
}
:host([disabled]) {
background-color: ${An};
}
:host([disabled]) .content,
:host([disabled]) .expand-collapse-glyph-container,
:host([disabled]) ::slotted([slot='end']),
:host([disabled]) ::slotted([slot='start']) {
color: ${Cn};
}
:host([data-indent]) {
display: grid;
}
:host([data-indent='1']) .content {
grid-column: 2 / span 1;
}
:host([data-indent='1'][role='menuitemcheckbox']) {
display: grid;
}
:host([data-indent='2'][aria-haspopup='menu']) ::slotted([slot='end']) {
grid-column: 4 / span 1;
}
:host([data-indent='2'][aria-haspopup='menu']) .expand-collapse-glyph-container {
grid-column: 5 / span 1;
}
:host([data-indent='1']) .content {
grid-column: 2 / span 1;
}
:host([data-indent='1'][role='menuitemcheckbox']) .content,
:host([data-indent='1'][role='menuitemradio']) .content {
grid-column: auto / span 1;
}
:host([icon]) ::slotted([slot='end']),
:host([data-indent='1']) ::slotted([slot='end']) {
grid-column: 4 / span 1;
justify-self: flex-end;
}
:host([data-indent='2']) {
display: grid;
grid-template-columns: 20px 20px auto auto;
}
:host([data-indent='2']) .content {
grid-column: 3 / span 1;
}
:host([data-indent='2']) .input-container {
grid-column: 1 / span 1;
}
:host([data-indent='2']) ::slotted([slot='start']) {
grid-column: 2 / span 1;
}
:host([aria-haspopup='menu']) {
grid-template-columns: 20px auto auto 20px;
}
:host([data-indent='2'][aria-haspopup='menu']) {
grid-template-columns: 20px 20px auto auto 20px;
}
:host([aria-haspopup='menu']) ::slotted([slot='end']) {
grid-column: 3 / span 1;
justify-self: flex-end;
}
:host([data-indent='2'][aria-haspopup='menu']) ::slotted([slot='end']) {
grid-column: 4 / span 1;
justify-self: flex-end;
}
`,jr=$r.compose({name:`${un.prefix}-menu-item`,template:Vr,styles:Gr});let zr=class e extends Pt{constructor(){super(...arguments),this.expandedItem=null,this.focusIndex=-1,this.isNestedMenu=()=>null!==this.parentElement&&Yi(this.parentElement)&&"menuitem"===this.parentElement.getAttribute("role"),this.handleFocusOut=e=>{if(!this.contains(e.relatedTarget)&&void 0!==this.menuItems){this.collapseExpandedItem();const e=this.menuItems.findIndex(this.isFocusableElement);this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.menuItems[e].setAttribute("tabindex","0"),this.focusIndex=e}},this.handleItemFocus=e=>{const t=e.target;void 0!==this.menuItems&&t!==this.menuItems[this.focusIndex]&&(this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.focusIndex=this.menuItems.indexOf(t),t.setAttribute("tabindex","0"))},this.handleExpandedChanged=e=>{if(e.defaultPrevented||null===e.target||void 0===this.menuItems||this.menuItems.indexOf(e.target)<0)return;e.preventDefault();const t=e.target;null===this.expandedItem||t!==this.expandedItem||!1!==t.expanded?t.expanded&&(null!==this.expandedItem&&this.expandedItem!==t&&(this.expandedItem.expanded=!1),this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.expandedItem=t,this.focusIndex=this.menuItems.indexOf(t),t.setAttribute("tabindex","0")):this.expandedItem=null},this.changeHandler=e=>{if(void 0===this.menuItems)return;const t=e.target,i=this.menuItems.indexOf(t);if(-1!==i&&"menuitemradio"===t.role&&!0===t.checked){for(let e=i-1;e>=0;--e){const t=this.menuItems[e],i=t.getAttribute("role");if(i===Ur.menuitemradio&&(t.checked=!1),"separator"===i)break}const e=this.menuItems.length-1;for(let t=i+1;t<=e;++t){const e=this.menuItems[t],i=e.getAttribute("role");if(i===Ur.menuitemradio&&(e.checked=!1),"separator"===i)break}}},this.isMenuItemElement=t=>t instanceof $r||Yi(t)&&t.getAttribute("role")in e.focusableElementRoles,this.isFocusableElement=e=>this.isMenuItemElement(e)}itemsChanged(e,t){this.$fastController.isConnected&&void 0!==this.menuItems&&this.setItems()}connectedCallback(){super.connectedCallback(),x.enqueue((()=>{this.setItems()})),this.addEventListener("change",this.changeHandler)}disconnectedCallback(){super.disconnectedCallback(),this.removeItemListeners(),this.menuItems=void 0,this.removeEventListener("change",this.changeHandler)}focus(){this.setFocus(0,1)}collapseExpandedItem(){null!==this.expandedItem&&(this.expandedItem.expanded=!1,this.expandedItem=null)}handleMenuKeyDown(e){if(!e.defaultPrevented&&void 0!==this.menuItems)switch(e.key){case"ArrowDown":return void this.setFocus(this.focusIndex+1,1);case"ArrowUp":return void this.setFocus(this.focusIndex-1,-1);case"End":return void this.setFocus(this.menuItems.length-1,-1);case"Home":return void this.setFocus(0,1);default:return!0}}removeItemListeners(e=this.items){e.forEach((e=>{e.removeEventListener("focus",this.handleItemFocus),e.removeEventListener("expanded-changed",this.handleExpandedChanged),P.getNotifier(e).unsubscribe(this,"hidden")}))}static elementIndent(e){const t=e.getAttribute("role"),i=e.querySelector("[slot=start]");return t&&t!==Ur.menuitem?i?2:1:i?1:0}setItems(){var t;const i=Array.from(this.children);this.removeItemListeners(i),i.forEach((e=>P.getNotifier(e).subscribe(this,"hidden")));const n=i.filter((e=>!e.hasAttribute("hidden")));this.menuItems=n;const o=this.menuItems.filter(this.isMenuItemElement);o.length&&(this.focusIndex=0),o.forEach(((e,t)=>{e.setAttribute("tabindex",0===t?"0":"-1"),e.addEventListener("expanded-change",this.handleExpandedChanged),e.addEventListener("focus",this.handleItemFocus)}));const r=null===(t=this.menuItems)||void 0===t?void 0:t.filter(this.isMenuItemElement);null==r||r.forEach(((t,i)=>{const n=null==r?void 0:r.reduce(((t,i)=>{const n=e.elementIndent(i);return Math.max(t,n)}),0);t instanceof $r&&t.setAttribute("data-indent",`${n}`)}))}handleChange(e,t){"hidden"===t&&this.setItems()}setFocus(e,t){if(void 0!==this.menuItems)for(;e>=0&&e<this.menuItems.length;){const i=this.menuItems[e];if(this.isFocusableElement(i)){this.focusIndex>-1&&this.menuItems.length>=this.focusIndex-1&&this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.focusIndex=e,i.setAttribute("tabindex","0"),i.focus();break}e+=t}}};zr.focusableElementRoles=Ur,function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);r>3&&a&&Object.defineProperty(t,i,a)}([A],zr.prototype,"items",void 0);const Wr=Be`
<template
slot="${e=>e.slot?e.slot:e.isNestedMenu()?"submenu":void 0}"
role="menu"
@keydown="${(e,t)=>e.handleMenuKeyDown(t.event)}"
@focusout="${(e,t)=>e.handleFocusOut(t.event)}"
>
<slot ${Qe("items")}></slot>
</template>
`,Kr=re`
${nn("flex")}
:host {
flex-direction: column;
height: fit-content;
max-width: 300px;
min-width: 160px;
width: auto;
background-color: ${xn};
border: 1px solid ${In};
border-radius: ${Fn};
box-shadow: ${"var(--shadow16)"};
padding: 4px;
row-gap: 2px;
}
`,qr=zr.compose({name:`${un.prefix}-menu-list`,template:Wr,styles:Kr});Po.name="fluent-beta-label",Po.define(customElements),Lr.name="fluent-beta-menu",Lr.define(customElements),Fr.name="fluent-beta-menu-button",Fr.define(customElements),qr.name="fluent-beta-menu-list",qr.define(customElements),jr.name="fluent-beta-menu-item",jr.define(customElements);const Yr=Be`
<div class="container" ${Ue("containerRef")}>
${Ze((e=>!e.showLabelInline),Be`<fluent-beta-label
><span class="label">${e=>e.label}</span>
${Ze((e=>e.showLabelValue),Be`<span class="label-value">${e=>e.getSelectedValue}</span>`)}
</fluent-beta-label>`)}
${Ze((e=>e.type===Rt),Be`
<fluent-beta-menu
open=${e=>e.open}
@onOpenChange=${(e,t)=>e.handleMenuOpenChange(t.event)}
>
<fluent-beta-menu-button
class="menu-button"
appearance="outline"
slot="trigger"
size=${e=>e.size}
${Ue("menuButtonRef")}
>${Ze((e=>!e.getSelectedValue&&!e.hidePlaceholderText),Be`<span class="placeholder">${e=>e.getPlaceholderText}</span>`)}
${Ze((e=>e.getSelectedValue),Be`
${Ze((e=>e.showLabelInline),Be`<span class="label">${e=>e.label}</span>`)}
<span class="label-value">${e=>e.getSelectedValue}</span>
`)}
</fluent-beta-menu-button>
<fluent-beta-menu-list class="menu-list">
${We((e=>e.items),Be`<fluent-beta-menu-item
class="menu-item"
?disabled=${e=>e.disabled}
@change=${(e,t)=>t.parent.selectHandler(e)}
><div class="menu-item-label">${e=>e.label}</div></fluent-beta-menu-item
>`)}
</fluent-beta-menu-list>
</fluent-beta-menu>
`)}
${Ze((e=>e.type===Mt),Be`
<commerceui-swatches
${Ue("swatchesRef")}
:items=${e=>e.items}
size=${e=>e.size}
selected-index=${e=>e.selectedIndex}
row-max-items=${e=>e.itemsToFitPerRow}
@change=${(e,t)=>{e.selectHandler(t.event.detail)}}
></commerceui-swatches>
`)}
</div>
`;Be`<commerceui-filter
:items=${e=>e.items}
type=${e=>e.type}
label=${e=>e.label}
show-label-value=${e=>e.showLabelValue}
selected-index=${e=>e.selectedIndex}
placeholder-text=${e=>e.placeholderText}
auto-hide-overflow-swatches=${e=>e.autoHideOverflowSwatches}
hide-placeholder-text=${e=>e.hidePlaceholderText}
show-label-value=${e=>e.showLabelValue}
show-label-inline=${e=>e.showLabelInline}
open=${e=>e.open}
row-max-items=${e=>e.rowMaxItems}
size=${e=>e.size}
:onselectionchange=${e=>e.onselectionchange}
></commerceui-filter>`,Lt.compose({name:`${_t.prefix}-filter`,template:Yr,styles:Mi}).define(_t.registry);const Xr=Be`<div class="slot-filter-group">
${We((e=>e.getData.filters),Be`
<commerceui-filter
type=${(e,t)=>t.parent.getData.filters[t.index].type}
:items=${(e,t)=>t.parent.getData.filters[t.index].items}
label=${(e,t)=>t.parent.getData.filters[t.index].label}
show-label-value=${(e,t)=>t.parent.getData.filters[t.index].showLabelValue}
row-max-items=${(e,t)=>t.parent.getData.filters[t.index].rowMaxItems}
auto-hide-overflow-swatches=${(e,t)=>t.parent.autoHideOverflowSwatches}
selected-index=${(e,t)=>t.parent.getData.filters[t.index].selectedIndex}
size=${(e,t)=>t.parent.getData.filters[t.index].size}
hide-placeholder-text=${(e,t)=>t.parent.getData.filters[t.index].hidePlaceholderText}
placeholder-text=${(e,t)=>t.parent.getData.filters[t.index].placeholderText}
@filterchange=${(e,t)=>{t.parent.selectionChangeHandler(e.id,t.event)}}
></commerceui-filter>
`,{positioning:!0})}
</div>`;let Jr;Be`<commerceui-buying-options-filter-group
direction=${e=>e.direction}
auto-hide-overflow-swatches=${e=>e.autoHideOverflowSwatches}
title=${e=>e.title}
inline-swatches=${e=>e.inlineSwatches}
:data=${e=>e.data}
:onfiltergroupselectionchange=${e=>e.onfiltergroupselectionchange}
>${e=>e.content}</commerceui-buying-options-filter-group
>`;const Qr="fast-kernel";try{if(document.currentScript)Jr=document.currentScript.getAttribute(Qr);else{const e=document.getElementsByTagName("script");Jr=e[e.length-1].getAttribute(Qr)}}catch(e){Jr="isolate"}let ea;switch(Jr){case"share":ea=Object.freeze({updateQueue:1,observable:2,contextEvent:3,elementRegistry:4});break;case"share-v2":ea=Object.freeze({updateQueue:1.2,observable:2.2,contextEvent:3.2,elementRegistry:4.2});break;default:const e=`-${Math.random().toString(36).substring(2,8)}`;ea=Object.freeze({updateQueue:`1.2${e}`,observable:`2.2${e}`,contextEvent:`3.2${e}`,elementRegistry:`4.2${e}`})}const ta=e=>"function"==typeof e,ia=e=>"string"==typeof e,na=()=>{};var oa="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};!function(){if("undefined"==typeof globalThis)if(void 0!==oa)oa.globalThis=oa;else if("undefined"!=typeof self)self.globalThis=self;else if("undefined"!=typeof window)window.globalThis=window;else{const e=new Function("return this")();e.globalThis=e}}();const ra={configurable:!1,enumerable:!1,writable:!1};void 0===globalThis.FAST&&Reflect.defineProperty(globalThis,"FAST",Object.assign({value:Object.create(null)},ra));const aa=globalThis.FAST;if(void 0===aa.getById){const e=Object.create(null);Reflect.defineProperty(aa,"getById",Object.assign({value(t,i){let n=e[t];return void 0===n&&(n=i?e[t]=i():null),n}},ra))}void 0===aa.error&&Object.assign(aa,{warn(){},error(e){return new Error(`Error ${e}`)},addMessages(){}});const sa=Object.freeze([]);function la(){const e=new Map;return Object.freeze({register(t){return!e.has(t.type)&&(e.set(t.type,t),!0)},getByType(t){return e.get(t)},getForInstance(t){if(null!=t)return e.get(t.constructor)}})}function ca(){const e=new WeakMap;return function(t){let i=e.get(t);if(void 0===i){let n=Reflect.getPrototypeOf(t);for(;void 0===i&&null!==n;)i=e.get(n),n=Reflect.getPrototypeOf(n);i=void 0===i?[]:i.slice(0),e.set(t,i)}return i}}function da(e){e.prototype.toJSON=na}const ua=Object.freeze({none:0,attribute:1,booleanAttribute:2,property:3,content:4,tokenList:5,event:6}),ha=e=>e,pa=globalThis.trustedTypes?globalThis.trustedTypes.createPolicy("fast-html",{createHTML:ha}):{createHTML:ha};let ga=Object.freeze({createHTML(e){return pa.createHTML(e)},protect(e,t,i,n){return n}});const fa=ga,ma=Object.freeze({get policy(){return ga},setPolicy(e){if(ga!==fa)throw aa.error(1201);ga=e},setAttribute(e,t,i){null==i?e.removeAttribute(t):e.setAttribute(t,i)},setBooleanAttribute(e,t,i){i?e.setAttribute(t,""):e.removeAttribute(t)}}),va=aa.getById(ea.updateQueue,(()=>{const e=[],t=[],i=globalThis.requestAnimationFrame;let n=!0;function o(){if(t.length)throw t.shift()}function r(i){try{i.call()}catch(i){if(!n)throw e.length=0,i;t.push(i),setTimeout(o,0)}}function a(){let t=0;for(;t<e.length;)if(r(e[t]),t++,t>1024){for(let i=0,n=e.length-t;i<n;i++)e[i]=e[i+t];e.length-=t,t=0}e.length=0}function s(t){e.push(t),e.length<2&&(n?i(a):a())}return Object.freeze({enqueue:s,next:()=>new Promise(s),process:a,setMode:e=>n=e})}));class ya{constructor(e,t){this.sub1=void 0,this.sub2=void 0,this.spillover=void 0,this.subject=e,this.sub1=t}has(e){return void 0===this.spillover?this.sub1===e||this.sub2===e:-1!==this.spillover.indexOf(e)}subscribe(e){const t=this.spillover;if(void 0===t){if(this.has(e))return;if(void 0===this.sub1)return void(this.sub1=e);if(void 0===this.sub2)return void(this.sub2=e);this.spillover=[this.sub1,this.sub2,e],this.sub1=void 0,this.sub2=void 0}else-1===t.indexOf(e)&&t.push(e)}unsubscribe(e){const t=this.spillover;if(void 0===t)this.sub1===e?this.sub1=void 0:this.sub2===e&&(this.sub2=void 0);else{const i=t.indexOf(e);-1!==i&&t.splice(i,1)}}notify(e){const t=this.spillover,i=this.subject;if(void 0===t){const t=this.sub1,n=this.sub2;void 0!==t&&t.handleChange(i,e),void 0!==n&&n.handleChange(i,e)}else for(let n=0,o=t.length;n<o;++n)t[n].handleChange(i,e)}}class Ca{constructor(e){this.subscribers={},this.subjectSubscribers=null,this.subject=e}notify(e){var t,i;null===(t=this.subscribers[e])||void 0===t||t.notify(e),null===(i=this.subjectSubscribers)||void 0===i||i.notify(e)}subscribe(e,t){var i,n;let o;o=t?null!==(i=this.subscribers[t])&&void 0!==i?i:this.subscribers[t]=new ya(this.subject):null!==(n=this.subjectSubscribers)&&void 0!==n?n:this.subjectSubscribers=new ya(this.subject),o.subscribe(e)}unsubscribe(e,t){var i,n;t?null===(i=this.subscribers[t])||void 0===i||i.unsubscribe(e):null===(n=this.subjectSubscribers)||void 0===n||n.unsubscribe(e)}}const ba=Object.freeze({unknown:void 0,coupled:1}),Sa=aa.getById(ea.observable,(()=>{const e=va.enqueue,t=/(:|&&|\|\||if|\?\.)/,i=new WeakMap;let n,o=e=>{throw aa.error(1101)};function r(e){var t;let n=null!==(t=e.$fastController)&&void 0!==t?t:i.get(e);return void 0===n&&(Array.isArray(e)?n=o(e):i.set(e,n=new Ca(e))),n}const a=ca();class s{constructor(e){this.name=e,this.field=`_${e}`,this.callback=`${e}Changed`}getValue(e){return void 0!==n&&n.watch(e,this.name),e[this.field]}setValue(e,t){const i=this.field,n=e[i];if(n!==t){e[i]=t;const o=e[this.callback];ta(o)&&o.call(e,n,t),r(e).notify(this.name)}}}class l extends ya{constructor(e,t,i=!1){super(e,t),this.expression=e,this.isVolatileBinding=i,this.needsRefresh=!0,this.needsQueue=!0,this.isAsync=!0,this.first=this,this.last=null,this.propertySource=void 0,this.propertyName=void 0,this.notifier=void 0,this.next=void 0}setMode(e){this.isAsync=this.needsQueue=e}bind(e){this.controller=e;const t=this.observe(e.source,e.context);return!e.isBound&&this.requiresUnbind(e)&&e.onUnbind(this),t}requiresUnbind(e){return e.sourceLifetime!==ba.coupled||this.first!==this.last||this.first.propertySource!==e.source}unbind(e){this.dispose()}observe(e,t){this.needsRefresh&&null!==this.last&&this.dispose();const i=n;let o;n=this.needsRefresh?this:void 0,this.needsRefresh=this.isVolatileBinding;try{o=this.expression(e,t)}finally{n=i}return o}disconnect(){this.dispose()}dispose(){if(null!==this.last){let e=this.first;for(;void 0!==e;)e.notifier.unsubscribe(this,e.propertyName),e=e.next;this.last=null,this.needsRefresh=this.needsQueue=this.isAsync}}watch(e,t){const i=this.last,o=r(e),a=null===i?this.first:{};if(a.propertySource=e,a.propertyName=t,a.notifier=o,o.subscribe(this,t),null!==i){if(!this.needsRefresh){let t;n=void 0,t=i.propertySource[i.propertyName],n=this,e===t&&(this.needsRefresh=!0)}i.next=a}this.last=a}handleChange(){this.needsQueue?(this.needsQueue=!1,e(this)):this.isAsync||this.call()}call(){null!==this.last&&(this.needsQueue=this.isAsync,this.notify(this))}*records(){let e=this.first;for(;void 0!==e;)yield e,e=e.next}}return da(l),Object.freeze({setArrayObserverFactory(e){o=e},getNotifier:r,track(e,t){n&&n.watch(e,t)},trackVolatile(){n&&(n.needsRefresh=!0)},notify(e,t){r(e).notify(t)},defineProperty(e,t){ia(t)&&(t=new s(t)),a(e).push(t),Reflect.defineProperty(e,t.name,{enumerable:!0,get(){return t.getValue(this)},set(e){t.setValue(this,e)}})},getAccessors:a,binding(e,t,i=this.isVolatileBinding(e)){return new l(e,t,i)},isVolatileBinding(e){return t.test(e.toString())}})}));function xa(e,t){Sa.defineProperty(e,t)}const Ta=aa.getById(ea.contextEvent,(()=>{let e=null;return{get(){return e},set(t){e=t}}})),wa=Object.freeze({default:{index:0,length:0,get event(){return wa.getEvent()},eventDetail(){return this.event.detail},eventTarget(){return this.event.target}},getEvent(){return Ta.get()},setEvent(e){Ta.set(e)}});class Oa{constructor(e,t,i){this.index=e,this.removed=t,this.addedCount=i}adjustTo(e){let t=this.index;const i=e.length;return t>i?t=i-this.addedCount:t<0&&(t=i+this.removed.length+t-this.addedCount),this.index=t<0?0:t,this}}const Pa=Object.freeze({reset:1,splice:2,optimized:3}),Aa=new Oa(0,sa,0);Aa.reset=!0;const Ea=[Aa];function ka(e,t,i,n,o,r){let a=0,s=0;const l=Math.min(i-t,r-o);if(0===t&&0===o&&(a=function(e,t,i){for(let n=0;n<i;++n)if(e[n]!==t[n])return n;return i}(e,n,l)),i===e.length&&r===n.length&&(s=function(e,t,i){let n=e.length,o=t.length,r=0;for(;r<i&&e[--n]===t[--o];)r++;return r}(e,n,l-a)),o+=a,r-=s,(i-=s)-(t+=a)==0&&r-o==0)return sa;if(t===i){const e=new Oa(t,[],0);for(;o<r;)e.removed.push(n[o++]);return[e]}if(o===r)return[new Oa(t,[],i-t)];const c=function(e){let t=e.length-1,i=e[0].length-1,n=e[t][i];const o=[];for(;t>0||i>0;){if(0===t){o.push(2),i--;continue}if(0===i){o.push(3),t--;continue}const r=e[t-1][i-1],a=e[t-1][i],s=e[t][i-1];let l;l=a<s?a<r?a:r:s<r?s:r,l===r?(r===n?o.push(0):(o.push(1),n=r),t--,i--):l===a?(o.push(3),t--,n=a):(o.push(2),i--,n=s)}return o.reverse()}(function(e,t,i,n,o,r){const a=r-o+1,s=i-t+1,l=new Array(a);let c,d;for(let e=0;e<a;++e)l[e]=new Array(s),l[e][0]=e;for(let e=0;e<s;++e)l[0][e]=e;for(let i=1;i<a;++i)for(let r=1;r<s;++r)e[t+r-1]===n[o+i-1]?l[i][r]=l[i-1][r-1]:(c=l[i-1][r]+1,d=l[i][r-1]+1,l[i][r]=c<d?c:d);return l}(e,t,i,n,o,r)),d=[];let u,h=t,p=o;for(let e=0;e<c.length;++e)switch(c[e]){case 0:void 0!==u&&(d.push(u),u=void 0),h++,p++;break;case 1:void 0===u&&(u=new Oa(h,[],0)),u.addedCount++,h++,u.removed.push(n[p]),p++;break;case 2:void 0===u&&(u=new Oa(h,[],0)),u.addedCount++,h++;break;case 3:void 0===u&&(u=new Oa(h,[],0)),u.removed.push(n[p]),p++}return void 0!==u&&d.push(u),d}function Ia(e,t){let i=!1,n=0;for(let l=0;l<t.length;l++){const c=t[l];if(c.index+=n,i)continue;const d=(o=e.index,r=e.index+e.removed.length,a=c.index,s=c.index+c.addedCount,r<a||s<o?-1:r===a||s===o?0:o<a?r<s?r-a:s-a:s<r?s-o:r-o);if(d>=0){t.splice(l,1),l--,n-=c.addedCount-c.removed.length,e.addedCount+=c.addedCount-d;const o=e.removed.length+c.removed.length-d;if(e.addedCount||o){let t=c.removed;if(e.index<c.index){const i=e.removed.slice(0,c.index-e.index);i.push(...t),t=i}if(e.index+e.removed.length>c.index+c.addedCount){const i=e.removed.slice(c.index+c.addedCount-e.index);t.push(...i)}e.removed=t,c.index<e.index&&(e.index=c.index)}else i=!0}else if(e.index<c.index){i=!0,t.splice(l,0,e),l++;const o=e.addedCount-e.removed.length;c.index+=o,n+=o}}var o,r,a,s;i||t.push(e)}let Da=Object.freeze({support:Pa.optimized,normalize(e,t,i){return void 0===e?void 0===i?sa:function(e,t){let i=[];const n=[];for(let e=0,i=t.length;e<i;e++)Ia(t[e],n);for(let t=0,o=n.length;t<o;++t){const o=n[t];1!==o.addedCount||1!==o.removed.length?i=i.concat(ka(e,o.index,o.index+o.addedCount,o.removed,0,o.removed.length)):o.removed[0]!==e[o.index]&&i.push(o)}return i}(t,i):Ea},pop(e,t,i,n){const o=e.length>0,r=i.apply(e,n);return o&&t.addSplice(new Oa(e.length,[r],0)),r},push(e,t,i,n){const o=i.apply(e,n);return t.addSplice(new Oa(e.length-n.length,[],n.length).adjustTo(e)),o},reverse(e,t,i,n){const o=i.apply(e,n);return t.reset(e),o},shift(e,t,i,n){const o=e.length>0,r=i.apply(e,n);return o&&t.addSplice(new Oa(0,[r],0)),r},sort(e,t,i,n){const o=i.apply(e,n);return t.reset(e),o},splice(e,t,i,n){const o=i.apply(e,n);return t.addSplice(new Oa(+n[0],o,n.length>2?n.length-2:0).adjustTo(e)),o},unshift(e,t,i,n){const o=i.apply(e,n);return t.addSplice(new Oa(0,[],n.length).adjustTo(e)),o}});function _a(e,t,i){Reflect.defineProperty(e,t,{value:i,enumerable:!1})}class Na extends ya{constructor(e){super(e),this.oldCollection=void 0,this.splices=void 0,this.needsQueue=!0,this._strategy=null,this._lengthObserver=void 0,this.call=this.flush,_a(e,"$fastController",this)}get strategy(){return this._strategy}set strategy(e){this._strategy=e}get lengthObserver(){let e=this._lengthObserver;if(void 0===e){const t=this.subject;this._lengthObserver=e={length:t.length,handleChange(){this.length!==t.length&&(this.length=t.length,Sa.notify(e,"length"))}},this.subscribe(e)}return e}subscribe(e){this.flush(),super.subscribe(e)}addSplice(e){void 0===this.splices?this.splices=[e]:this.splices.push(e),this.enqueue()}reset(e){this.oldCollection=e,this.enqueue()}flush(){var e;const t=this.splices,i=this.oldCollection;void 0===t&&void 0===i||(this.needsQueue=!0,this.splices=void 0,this.oldCollection=void 0,this.notify((null!==(e=this._strategy)&&void 0!==e?e:Da).normalize(i,this.subject,t)))}enqueue(){this.needsQueue&&(this.needsQueue=!1,va.enqueue(this))}}let Ra=!1;const Ma=Object.freeze({enable(){if(Ra)return;Ra=!0,Sa.setArrayObserverFactory((e=>new Na(e)));const e=Array.prototype;e.$fastPatch||(_a(e,"$fastPatch",1),[e.pop,e.push,e.reverse,e.shift,e.sort,e.splice,e.unshift].forEach((t=>{e[t.name]=function(...e){var i;const n=this.$fastController;return void 0===n?t.apply(this,e):(null!==(i=n.strategy)&&void 0!==i?i:Da)[t.name](this,n,t,e)}})))}});class La{constructor(e,t,i=!1){this.evaluate=e,this.policy=t,this.isVolatile=i}}class Ba extends La{createObserver(e){return Sa.binding(this.evaluate,e,this.isVolatile)}}function Fa(e,t,i=Sa.isVolatileBinding(e)){return new Ba(e,t,i)}class Ua extends La{createObserver(){return this}bind(e){return this.evaluate(e.source,e.context)}}function Ha(e,t){return new Ua(e,t)}function $a(e){return ta(e)?Fa(e):e instanceof La?e:Ha((()=>e))}let Za;function Va(e){return e.map((e=>e instanceof Ga?Va(e.styles):[e])).reduce(((e,t)=>e.concat(t)),[])}da(Ua);class Ga{constructor(e){this.styles=e,this.targets=new WeakSet,this._strategy=null,this.behaviors=e.map((e=>e instanceof Ga?e.behaviors:null)).reduce(((e,t)=>null===t?e:null===e?t:e.concat(t)),null)}get strategy(){return null===this._strategy&&this.withStrategy(Za),this._strategy}addStylesTo(e){this.strategy.addStylesTo(e),this.targets.add(e)}removeStylesFrom(e){this.strategy.removeStylesFrom(e),this.targets.delete(e)}isAttachedTo(e){return this.targets.has(e)}withBehaviors(...e){return this.behaviors=null===this.behaviors?e:this.behaviors.concat(e),this}withStrategy(e){return this._strategy=new e(Va(this.styles)),this}static setDefaultStrategy(e){Za=e}static normalize(e){return void 0===e?void 0:Array.isArray(e)?new Ga(e):e instanceof Ga?e:new Ga([e])}}Ga.supportsAdoptedStyleSheets=Array.isArray(document.adoptedStyleSheets)&&"replace"in CSSStyleSheet.prototype;const ja=la(),za=Object.freeze({getForInstance:ja.getForInstance,getByType:ja.getByType,define(e){return ja.register({type:e}),e}});function Wa(e,t,i){t.source.style.setProperty(e.targetAspect,i.bind(t))}class Ka{constructor(e,t){this.dataBinding=e,this.targetAspect=t}createCSS(e){return e(this),`var(${this.targetAspect})`}addedCallback(e){var t;const i=e.source;if(!i.$cssBindings){i.$cssBindings=new Map;const e=i.setAttribute;i.setAttribute=(t,n)=>{e.call(i,t,n),"style"===t&&i.$cssBindings.forEach(((e,t)=>Wa(t,e.controller,e.observer)))}}const n=null!==(t=e[this.targetAspect])&&void 0!==t?t:e[this.targetAspect]=this.dataBinding.createObserver(this,this);n.controller=e,e.source.$cssBindings.set(this,{controller:e,observer:n})}connectedCallback(e){Wa(this,e,e[this.targetAspect])}removedCallback(e){e.source.$cssBindings&&e.source.$cssBindings.delete(this)}handleChange(e,t){Wa(this,t.controller,t)}}za.define(Ka);const qa=`${Math.random().toString(36).substring(2,8)}`;let Ya=0;const Xa=()=>`--v${qa}${++Ya}`;function Ja(e,t){const i=[];let n="";const o=[],r=e=>{o.push(e)};for(let o=0,a=e.length-1;o<a;++o){n+=e[o];let a=t[o];ta(a)?a=new Ka(Fa(a),Xa()).createCSS(r):a instanceof La?a=new Ka(a,Xa()).createCSS(r):void 0!==za.getForInstance(a)&&(a=a.createCSS(r)),a instanceof Ga||a instanceof CSSStyleSheet?(""!==n.trim()&&(i.push(n),n=""),i.push(a)):n+=a}return n+=e[e.length-1],""!==n.trim()&&i.push(n),{styles:i,behaviors:o}}const Qa=(e,...t)=>{const{styles:i,behaviors:n}=Ja(e,t),o=new Ga(i);return n.length?o.withBehaviors(...n):o};class es{constructor(e,t){this.behaviors=t,this.css="";const i=e.reduce(((e,t)=>(ia(t)?this.css+=t:e.push(t),e)),[]);i.length&&(this.styles=new Ga(i))}createCSS(e){return this.behaviors.forEach(e),this.styles&&e(this),this.css}addedCallback(e){e.addStyles(this.styles)}removedCallback(e){e.removeStyles(this.styles)}}za.define(es),Qa.partial=(e,...t)=>{const{styles:i,behaviors:n}=Ja(e,t);return new es(i,n)};const ts=`fast-${Math.random().toString(36).substring(2,8)}`,is=`${ts}{`,ns=`}${ts}`,os=ns.length;let rs=0;const as=()=>`${ts}-${++rs}`,ss=Object.freeze({interpolation:e=>`${is}${e}${ns}`,attribute:e=>`${as()}="${is}${e}${ns}"`,comment:e=>`\x3c!--${is}${e}${ns}--\x3e`}),ls=Object.freeze({parse(e,t){const i=e.split(is);if(1===i.length)return null;const n=[];for(let e=0,o=i.length;e<o;++e){const o=i[e],r=o.indexOf(ns);let a;if(-1===r)a=o;else{const e=o.substring(0,r);n.push(t[e]),a=o.substring(r+os)}""!==a&&n.push(a)}return n}}),cs=la(),ds=Object.freeze({getForInstance:cs.getForInstance,getByType:cs.getByType,define(e,t){return(t=t||{}).type=e,cs.register(t),e},assignAspect(e,t){if(t)switch(e.sourceAspect=t,t[0]){case":":e.targetAspect=t.substring(1),e.aspectType="classList"===e.targetAspect?ua.tokenList:ua.property;break;case"?":e.targetAspect=t.substring(1),e.aspectType=ua.booleanAttribute;break;case"@":e.targetAspect=t.substring(1),e.aspectType=ua.event;break;default:e.targetAspect=t,e.aspectType=ua.attribute}else e.aspectType=ua.content}});class us{constructor(e){this.options=e}createHTML(e){return ss.attribute(e(this))}createBehavior(){return this}}da(us);const hs={[ua.attribute]:ma.setAttribute,[ua.booleanAttribute]:ma.setBooleanAttribute,[ua.property]:(e,t,i)=>e[t]=i,[ua.content]:function(e,t,i,n){if(null==i&&(i=""),i.create){e.textContent="";let t=e.$fastView;void 0===t?t=i.create():e.$fastTemplate!==i&&(t.isComposed&&(t.remove(),t.unbind()),t=i.create()),t.isComposed?t.needsBindOnly&&(t.needsBindOnly=!1,t.bind(n.source,n.context)):(t.isComposed=!0,t.bind(n.source,n.context),t.insertBefore(e),e.$fastView=t,e.$fastTemplate=i)}else{const t=e.$fastView;void 0!==t&&t.isComposed&&(t.isComposed=!1,t.remove(),t.needsBindOnly?t.needsBindOnly=!1:t.unbind()),e.textContent=i}},[ua.tokenList]:function(e,t,i){var n;const o=`${this.id}-t`,r=null!==(n=e[o])&&void 0!==n?n:e[o]={v:0,cv:Object.create(null)},a=r.cv;let s=r.v;const l=e[t];if(null!=i&&i.length){const e=i.split(/\s+/);for(let t=0,i=e.length;t<i;++t){const i=e[t];""!==i&&(a[i]=s,l.add(i))}}if(r.v=s+1,0!==s){s-=1;for(const e in a)a[e]===s&&l.remove(e)}},[ua.event]:()=>{}};class ps{constructor(e){this.dataBinding=e,this.updateTarget=null,this.aspectType=ua.content}createHTML(e){return ss.interpolation(e(this))}createBehavior(){var e;if(null===this.updateTarget){const t=hs[this.aspectType],i=null!==(e=this.dataBinding.policy)&&void 0!==e?e:this.policy;if(!t)throw aa.error(1205);this.data=`${this.id}-d`,this.updateTarget=i.protect(this.targetTagName,this.aspectType,this.targetAspect,t)}return this}bind(e){var t;const i=e.targets[this.targetNodeId];switch(this.aspectType){case ua.event:i[this.data]=e,i.addEventListener(this.targetAspect,this,this.dataBinding.options);break;case ua.content:e.onUnbind(this);default:const n=null!==(t=i[this.data])&&void 0!==t?t:i[this.data]=this.dataBinding.createObserver(this,this);n.target=i,n.controller=e,this.updateTarget(i,this.targetAspect,n.bind(e),e)}}unbind(e){const t=e.targets[this.targetNodeId].$fastView;void 0!==t&&t.isComposed&&(t.unbind(),t.needsBindOnly=!0)}handleEvent(e){const t=e.currentTarget[this.data];if(t.isBound){wa.setEvent(e);const i=this.dataBinding.evaluate(t.source,t.context);wa.setEvent(null),!0!==i&&e.preventDefault()}}handleChange(e,t){const i=t.target,n=t.controller;this.updateTarget(i,this.targetAspect,t.bind(n),n)}}function gs(e,t){const i=e.parentNode;let n,o=e;for(;o!==t;)n=o.nextSibling,i.removeChild(o),o=n;i.removeChild(t)}ds.define(ps,{aspected:!0});class fs{constructor(e,t,i){this.fragment=e,this.factories=t,this.targets=i,this.behaviors=null,this.unbindables=[],this.source=null,this.isBound=!1,this.sourceLifetime=ba.unknown,this.context=this,this.index=0,this.length=0,this.firstChild=e.firstChild,this.lastChild=e.lastChild}get event(){return wa.getEvent()}get isEven(){return this.index%2==0}get isOdd(){return this.index%2!=0}get isFirst(){return 0===this.index}get isInMiddle(){return!this.isFirst&&!this.isLast}get isLast(){return this.index===this.length-1}eventDetail(){return this.event.detail}eventTarget(){return this.event.target}appendTo(e){e.appendChild(this.fragment)}insertBefore(e){if(this.fragment.hasChildNodes())e.parentNode.insertBefore(this.fragment,e);else{const t=this.lastChild;if(e.previousSibling===t)return;const i=e.parentNode;let n,o=this.firstChild;for(;o!==t;)n=o.nextSibling,i.insertBefore(o,e),o=n;i.insertBefore(t,e)}}remove(){const e=this.fragment,t=this.lastChild;let i,n=this.firstChild;for(;n!==t;)i=n.nextSibling,e.appendChild(n),n=i;e.appendChild(t)}dispose(){gs(this.firstChild,this.lastChild),this.unbind()}onUnbind(e){this.unbindables.push(e)}bind(e,t=this){if(this.source===e)return;let i=this.behaviors;if(null===i){this.source=e,this.context=t,this.behaviors=i=new Array(this.factories.length);const n=this.factories;for(let e=0,t=n.length;e<t;++e){const t=n[e].createBehavior();t.bind(this),i[e]=t}}else{null!==this.source&&this.evaluateUnbindables(),this.isBound=!1,this.source=e,this.context=t;for(let e=0,t=i.length;e<t;++e)i[e].bind(this)}this.isBound=!0}unbind(){this.isBound&&null!==this.source&&(this.evaluateUnbindables(),this.source=null,this.context=this,this.isBound=!1)}evaluateUnbindables(){const e=this.unbindables;for(let t=0,i=e.length;t<i;++t)e[t].unbind(this);e.length=0}static disposeContiguousBatch(e){if(0!==e.length){gs(e[0].firstChild,e[e.length-1].lastChild);for(let t=0,i=e.length;t<i;++t)e[t].unbind()}}}da(fs),Sa.defineProperty(fs.prototype,"index"),Sa.defineProperty(fs.prototype,"length");const ms=(e,t)=>`${e}.${t}`,vs={},ys={index:0,node:null};function Cs(e){e.startsWith("fast-")||aa.warn(1204,{name:e})}const bs=new Proxy(document.createElement("div"),{get(e,t){Cs(t);const i=Reflect.get(e,t);return ta(i)?i.bind(e):i},set(e,t,i){return Cs(t),Reflect.set(e,t,i)}});class Ss{constructor(e,t,i){this.fragment=e,this.directives=t,this.policy=i,this.proto=null,this.nodeIds=new Set,this.descriptors={},this.factories=[]}addFactory(e,t,i,n,o){var r,a;this.nodeIds.has(i)||(this.nodeIds.add(i),this.addTargetDescriptor(t,i,n)),e.id=null!==(r=e.id)&&void 0!==r?r:as(),e.targetNodeId=i,e.targetTagName=o,e.policy=null!==(a=e.policy)&&void 0!==a?a:this.policy,this.factories.push(e)}freeze(){return this.proto=Object.create(null,this.descriptors),this}addTargetDescriptor(e,t,i){const n=this.descriptors;if("r"===t||"h"===t||n[t])return;if(!n[e]){const t=e.lastIndexOf("."),i=e.substring(0,t),n=parseInt(e.substring(t+1));this.addTargetDescriptor(i,e,n)}let o=vs[t];if(!o){const n=`_${t}`;vs[t]=o={get(){var t;return null!==(t=this[n])&&void 0!==t?t:this[n]=this[e].childNodes[i]}}}n[t]=o}createView(e){const t=this.fragment.cloneNode(!0),i=Object.create(this.proto);i.r=t,i.h=null!=e?e:bs;for(const e of this.nodeIds)i[e];return new fs(t,this.factories,i)}}function xs(e,t,i,n,o,r=!1){const a=i.attributes,s=e.directives;for(let l=0,c=a.length;l<c;++l){const d=a[l],u=d.value,h=ls.parse(u,s);let p=null;null===h?r&&(p=new ps(Ha((()=>u),e.policy)),ds.assignAspect(p,d.name)):p=Ps.aggregate(h,e.policy),null!==p&&(i.removeAttributeNode(d),l--,c--,e.addFactory(p,t,n,o,i.tagName))}}function Ts(e,t,i){let n=0,o=t.firstChild;for(;o;){const t=ws(e,i,o,n);o=t.node,n=t.index}}function ws(e,t,i,n){const o=ms(t,n);switch(i.nodeType){case 1:xs(e,t,i,o,n),Ts(e,i,o);break;case 3:return function(e,t,i,n,o){const r=ls.parse(t.textContent,e.directives);if(null===r)return ys.node=t.nextSibling,ys.index=o+1,ys;let a,s=a=t;for(let t=0,l=r.length;t<l;++t){const l=r[t];0!==t&&(o++,n=ms(i,o),a=s.parentNode.insertBefore(document.createTextNode(""),s.nextSibling)),ia(l)?a.textContent=l:(a.textContent=" ",ds.assignAspect(l),e.addFactory(l,i,n,o,null)),s=a}return ys.index=o+1,ys.node=s.nextSibling,ys}(e,i,t,o,n);case 8:const r=ls.parse(i.data,e.directives);null!==r&&e.addFactory(Ps.aggregate(r),t,o,n,null)}return ys.index=n+1,ys.node=i.nextSibling,ys}const Os="TEMPLATE",Ps={compile(e,t,i=ma.policy){let n;if(ia(e)){n=document.createElement(Os),n.innerHTML=i.createHTML(e);const t=n.content.firstElementChild;null!==t&&t.tagName===Os&&(n=t)}else n=e;n.content.firstChild||n.content.lastChild||n.content.appendChild(document.createComment(""));const o=document.adoptNode(n.content),r=new Ss(o,t,i);var a,s;return xs(r,"",n,"h",0,!0),s=t,((a=o.firstChild)&&8==a.nodeType&&null!==ls.parse(a.data,s)||1===o.childNodes.length&&Object.keys(t).length>0)&&o.insertBefore(document.createComment(""),o.firstChild),Ts(r,o,"r"),ys.node=null,r.freeze()},setDefaultStrategy(e){this.compile=e},aggregate(e,t=ma.policy){if(1===e.length)return e[0];let i,n,o,r=!1;const a=e.length,s=e.map((e=>ia(e)?()=>e:(i=e.sourceAspect||i,n=e.dataBinding||n,r=r||e.dataBinding.isVolatile,o=o||e.dataBinding.policy,e.dataBinding.evaluate)));n.evaluate=(e,t)=>{let i="";for(let n=0;n<a;++n)i+=s[n](e,t);return i},n.isVolatile=r,n.policy=null!=o?o:t;const l=new ps(n);return ds.assignAspect(l,i),l}},As=/([ \x09\x0a\x0c\x0d])([^\0-\x1F\x7F-\x9F "'>=/]+)([ \x09\x0a\x0c\x0d]*=[ \x09\x0a\x0c\x0d]*(?:[^ \x09\x0a\x0c\x0d"'`<>=]*|"[^"]*|'[^']*))$/,Es=Object.create(null);class ks{constructor(e,t=Es){this.html=e,this.factories=t}createHTML(e){const t=this.factories;for(const i in t)e(t[i]);return this.html}}function Is(e,t,i,n=ds.getForInstance(e)){if(n.aspected){const i=As.exec(t);null!==i&&ds.assignAspect(e,i[2])}return e.createHTML(i)}ks.empty=new ks(""),ds.define(ks);class Ds{constructor(e,t={},i){this.policy=i,this.result=null,this.html=e,this.factories=t}create(e){return null===this.result&&(this.result=Ps.compile(this.html,this.factories,this.policy)),this.result.createView(e)}inline(){return new ks(ia(this.html)?this.html:this.html.innerHTML,this.factories)}withPolicy(e){if(this.result)throw aa.error(1208);if(this.policy)throw aa.error(1207);return this.policy=e,this}render(e,t,i){const n=this.create(i);return n.bind(e),n.appendTo(t),n}static create(e,t,i){let n="";const o=Object.create(null),r=e=>{var t;const i=null!==(t=e.id)&&void 0!==t?t:e.id=as();return o[i]=e,i};for(let i=0,o=e.length-1;i<o;++i){const o=e[i];let a,s=t[i];if(n+=o,ta(s))s=new ps(Fa(s));else if(s instanceof La)s=new ps(s);else if(!(a=ds.getForInstance(s))){const e=s;s=new ps(Ha((()=>e)))}n+=Is(s,o,r,a)}return new Ds(n+e[e.length-1],o,i)}}da(Ds);const _s=(e,...t)=>{if(Array.isArray(e)&&Array.isArray(e.raw))return Ds.create(e,t);throw aa.error(1206)};_s.partial=e=>new ks(e);class Ns extends us{bind(e){e.source[this.options]=e.targets[this.targetNodeId]}}ds.define(Ns);const Rs=e=>new Ns(e),Ms=()=>null;function Ls(e){return void 0===e?Ms:ta(e)?e:()=>e}function Bs(e,t,i){const n=ta(e)?e:()=>e,o=Ls(t),r=Ls(i);return(e,t)=>n(e,t)?o(e,t):r(e,t)}const Fs=Object.freeze({positioning:!1,recycle:!0});function Us(e,t,i,n){e.context.parent=n.source,e.context.parentContext=n.context,e.bind(t[i])}function Hs(e,t,i,n){e.context.parent=n.source,e.context.parentContext=n.context,e.context.length=t.length,e.context.index=i,e.bind(t[i])}class $s{constructor(e){this.directive=e,this.items=null,this.itemsObserver=null,this.bindView=Us,this.views=[],this.itemsBindingObserver=e.dataBinding.createObserver(this,e),this.templateBindingObserver=e.templateBinding.createObserver(this,e),e.options.positioning&&(this.bindView=Hs)}bind(e){this.location=e.targets[this.directive.targetNodeId],this.controller=e,this.items=this.itemsBindingObserver.bind(e),this.template=this.templateBindingObserver.bind(e),this.observeItems(!0),this.refreshAllViews(),e.onUnbind(this)}unbind(){null!==this.itemsObserver&&this.itemsObserver.unsubscribe(this),this.unbindAllViews()}handleChange(e,t){if(t===this.itemsBindingObserver)this.items=this.itemsBindingObserver.bind(this.controller),this.observeItems(),this.refreshAllViews();else if(t===this.templateBindingObserver)this.template=this.templateBindingObserver.bind(this.controller),this.refreshAllViews(!0);else{if(!t[0])return;t[0].reset?this.refreshAllViews():this.updateViews(t)}}observeItems(e=!1){if(!this.items)return void(this.items=sa);const t=this.itemsObserver,i=this.itemsObserver=Sa.getNotifier(this.items),n=t!==i;n&&null!==t&&t.unsubscribe(this),(n||e)&&i.subscribe(this)}updateViews(e){const t=this.views,i=this.bindView,n=this.items,o=this.template,r=this.controller,a=this.directive.options.recycle,s=[];let l=0,c=0;for(let d=0,u=e.length;d<u;++d){const u=e[d],h=u.removed;let p=0,g=u.index;const f=g+u.addedCount,m=t.splice(u.index,h.length),v=c=s.length+m.length;for(;g<f;++g){const e=t[g],d=e?e.firstChild:this.location;let u;a&&c>0?(p<=v&&m.length>0?(u=m[p],p++):(u=s[l],l++),c--):u=o.create(),t.splice(g,0,u),i(u,n,g,r),u.insertBefore(d)}m[p]&&s.push(...m.slice(p))}for(let e=l,t=s.length;e<t;++e)s[e].dispose();if(this.directive.options.positioning)for(let e=0,i=t.length;e<i;++e){const n=t[e].context;n.length=i,n.index=e}}refreshAllViews(e=!1){const t=this.items,i=this.template,n=this.location,o=this.bindView,r=this.controller;let a=t.length,s=this.views,l=s.length;if(0!==a&&!e&&this.directive.options.recycle||(fs.disposeContiguousBatch(s),l=0),0===l){this.views=s=new Array(a);for(let e=0;e<a;++e){const a=i.create();o(a,t,e,r),s[e]=a,a.insertBefore(n)}}else{let e=0;for(;e<a;++e)if(e<l)o(s[e],t,e,r);else{const a=i.create();o(a,t,e,r),s.push(a),a.insertBefore(n)}const c=s.splice(e,l-e);for(e=0,a=c.length;e<a;++e)c[e].dispose()}}unbindAllViews(){const e=this.views;for(let t=0,i=e.length;t<i;++t)e[t].unbind()}}class Zs{constructor(e,t,i){this.dataBinding=e,this.templateBinding=t,this.options=i,Ma.enable()}createHTML(e){return ss.comment(e(this))}createBehavior(){return new $s(this)}}function Vs(e,t,i=Fs){const n=$a(e),o=$a(t);return new Zs(n,o,Object.assign(Object.assign({},Fs),i))}ds.define(Zs);const Gs=e=>1===e.nodeType,js=e=>e?t=>1===t.nodeType&&t.matches(e):Gs;class zs extends us{get id(){return this._id}set id(e){this._id=e,this._controllerProperty=`${e}-c`}bind(e){const t=e.targets[this.targetNodeId];t[this._controllerProperty]=e,this.updateTarget(e.source,this.computeNodes(t)),this.observe(t),e.onUnbind(this)}unbind(e){const t=e.targets[this.targetNodeId];this.updateTarget(e.source,sa),this.disconnect(t),t[this._controllerProperty]=null}getSource(e){return e[this._controllerProperty].source}updateTarget(e,t){e[this.options.property]=t}computeNodes(e){let t=this.getNodes(e);return"filter"in this.options&&(t=t.filter(this.options.filter)),t}}const Ws="slotchange";class Ks extends zs{observe(e){e.addEventListener(Ws,this)}disconnect(e){e.removeEventListener(Ws,this)}getNodes(e){return e.assignedNodes(this.options)}handleEvent(e){const t=e.currentTarget;this.updateTarget(this.getSource(t),this.computeNodes(t))}}function qs(e){return ia(e)&&(e={property:e}),new Ks(e)}ds.define(Ks);const Ys="boolean",Xs="reflect",Js=Object.freeze({locate:ca()}),Qs={toView(e){return e?"true":"false"},fromView(e){return null!=e&&"false"!==e&&!1!==e&&0!==e}};function el(e){if(null==e)return null;const t=1*e;return isNaN(t)?null:t}const tl={toView(e){const t=el(e);return t?t.toString():t},fromView:el};class il{constructor(e,t,i=t.toLowerCase(),n=Xs,o){this.guards=new Set,this.Owner=e,this.name=t,this.attribute=i,this.mode=n,this.converter=o,this.fieldName=`_${t}`,this.callbackName=`${t}Changed`,this.hasCallback=this.callbackName in e.prototype,n===Ys&&void 0===o&&(this.converter=Qs)}setValue(e,t){const i=e[this.fieldName],n=this.converter;void 0!==n&&(t=n.fromView(t)),i!==t&&(e[this.fieldName]=t,this.tryReflectToAttribute(e),this.hasCallback&&e[this.callbackName](i,t),e.$fastController.notify(this.name))}getValue(e){return Sa.track(e,this.name),e[this.fieldName]}onAttributeChangedCallback(e,t){this.guards.has(e)||(this.guards.add(e),this.setValue(e,t),this.guards.delete(e))}tryReflectToAttribute(e){const t=this.mode,i=this.guards;i.has(e)||"fromView"===t||va.enqueue((()=>{i.add(e);const n=e[this.fieldName];switch(t){case Xs:const t=this.converter;ma.setAttribute(e,this.attribute,void 0!==t?t.toView(n):n);break;case Ys:ma.setBooleanAttribute(e,this.attribute,n)}i.delete(e)}))}static collect(e,...t){const i=[];t.push(Js.locate(e));for(let n=0,o=t.length;n<o;++n){const o=t[n];if(void 0!==o)for(let t=0,n=o.length;t<n;++t){const n=o[t];ia(n)?i.push(new il(e,n)):i.push(new il(e,n.property,n.attribute,n.mode,n.converter))}}return i}}function nl(e,t){let i;function n(e,t){arguments.length>1&&(i.property=t),Js.locate(e.constructor).push(i)}return arguments.length>1?(i={},void n(e,t)):(i=void 0===e?{}:e,n)}const ol={mode:"open"},rl={},al=new Set,sl=aa.getById(ea.elementRegistry,(()=>la()));class ll{constructor(e,t=e.definition){var i;this.platformDefined=!1,ia(t)&&(t={name:t}),this.type=e,this.name=t.name,this.template=t.template,this.registry=null!==(i=t.registry)&&void 0!==i?i:customElements;const n=e.prototype,o=il.collect(e,t.attributes),r=new Array(o.length),a={},s={};for(let e=0,t=o.length;e<t;++e){const t=o[e];r[e]=t.attribute,a[t.name]=t,s[t.attribute]=t,Sa.defineProperty(n,t)}Reflect.defineProperty(e,"observedAttributes",{value:r,enumerable:!0}),this.attributes=o,this.propertyLookup=a,this.attributeLookup=s,this.shadowOptions=void 0===t.shadowOptions?ol:null===t.shadowOptions?void 0:Object.assign(Object.assign({},ol),t.shadowOptions),this.elementOptions=void 0===t.elementOptions?rl:Object.assign(Object.assign({},rl),t.elementOptions),this.styles=Ga.normalize(t.styles),sl.register(this)}get isDefined(){return this.platformDefined}define(e=this.registry){const t=this.type;return e.get(this.name)||(this.platformDefined=!0,e.define(this.name,t,this.elementOptions)),this}static compose(e,t){return al.has(e)||sl.getByType(e)?new ll(class extends e{},t):new ll(e,t)}static registerBaseType(e){al.add(e)}}ll.getByType=sl.getByType,ll.getForInstance=sl.getForInstance;const cl={bubbles:!0,composed:!0,cancelable:!0},dl="isConnected",ul=new WeakMap;function hl(e){var t,i;return null!==(i=null!==(t=e.shadowRoot)&&void 0!==t?t:ul.get(e))&&void 0!==i?i:null}let pl;class gl extends Ca{constructor(e,t){super(e),this.boundObservables=null,this.needsInitialization=!0,this.hasExistingShadowRoot=!1,this._template=null,this.stage=3,this.guardBehaviorConnection=!1,this.behaviors=null,this._mainStyles=null,this.$fastController=this,this.view=null,this.source=e,this.definition=t;const i=t.shadowOptions;if(void 0!==i){let t=e.shadowRoot;t?this.hasExistingShadowRoot=!0:(t=e.attachShadow(i),"closed"===i.mode&&ul.set(e,t))}const n=Sa.getAccessors(e);if(n.length>0){const t=this.boundObservables=Object.create(null);for(let i=0,o=n.length;i<o;++i){const o=n[i].name,r=e[o];void 0!==r&&(delete e[o],t[o]=r)}}}get isConnected(){return Sa.track(this,dl),1===this.stage}get context(){var e,t;return null!==(t=null===(e=this.view)||void 0===e?void 0:e.context)&&void 0!==t?t:wa.default}get isBound(){var e,t;return null!==(t=null===(e=this.view)||void 0===e?void 0:e.isBound)&&void 0!==t&&t}get sourceLifetime(){var e;return null===(e=this.view)||void 0===e?void 0:e.sourceLifetime}get template(){var e;if(null===this._template){const t=this.definition;this.source.resolveTemplate?this._template=this.source.resolveTemplate():t.template&&(this._template=null!==(e=t.template)&&void 0!==e?e:null)}return this._template}set template(e){this._template!==e&&(this._template=e,this.needsInitialization||this.renderTemplate(e))}get mainStyles(){var e;if(null===this._mainStyles){const t=this.definition;this.source.resolveStyles?this._mainStyles=this.source.resolveStyles():t.styles&&(this._mainStyles=null!==(e=t.styles)&&void 0!==e?e:null)}return this._mainStyles}set mainStyles(e){this._mainStyles!==e&&(null!==this._mainStyles&&this.removeStyles(this._mainStyles),this._mainStyles=e,this.needsInitialization||this.addStyles(e))}onUnbind(e){var t;null===(t=this.view)||void 0===t||t.onUnbind(e)}addBehavior(e){var t,i;const n=null!==(t=this.behaviors)&&void 0!==t?t:this.behaviors=new Map,o=null!==(i=n.get(e))&&void 0!==i?i:0;0===o?(n.set(e,1),e.addedCallback&&e.addedCallback(this),!e.connectedCallback||this.guardBehaviorConnection||1!==this.stage&&0!==this.stage||e.connectedCallback(this)):n.set(e,o+1)}removeBehavior(e,t=!1){const i=this.behaviors;if(null===i)return;const n=i.get(e);void 0!==n&&(1===n||t?(i.delete(e),e.disconnectedCallback&&3!==this.stage&&e.disconnectedCallback(this),e.removedCallback&&e.removedCallback(this)):i.set(e,n-1))}addStyles(e){var t;if(!e)return;const i=this.source;if(e instanceof HTMLElement)(null!==(t=hl(i))&&void 0!==t?t:this.source).append(e);else if(!e.isAttachedTo(i)){const t=e.behaviors;if(e.addStylesTo(i),null!==t)for(let e=0,i=t.length;e<i;++e)this.addBehavior(t[e])}}removeStyles(e){var t;if(!e)return;const i=this.source;if(e instanceof HTMLElement)(null!==(t=hl(i))&&void 0!==t?t:i).removeChild(e);else if(e.isAttachedTo(i)){const t=e.behaviors;if(e.removeStylesFrom(i),null!==t)for(let e=0,i=t.length;e<i;++e)this.removeBehavior(t[e])}}connect(){if(3!==this.stage)return;if(this.stage=0,null!==this.boundObservables){const e=this.source,t=this.boundObservables,i=Object.keys(t);for(let n=0,o=i.length;n<o;++n){const o=i[n];e[o]=t[o]}this.boundObservables=null}const e=this.behaviors;if(null!==e){this.guardBehaviorConnection=!0;for(const t of e.keys())t.connectedCallback&&t.connectedCallback(this);this.guardBehaviorConnection=!1}this.needsInitialization?(this.renderTemplate(this.template),this.addStyles(this.mainStyles),this.needsInitialization=!1):null!==this.view&&this.view.bind(this.source),this.stage=1,Sa.notify(this,dl)}disconnect(){if(1!==this.stage)return;this.stage=2,Sa.notify(this,dl),null!==this.view&&this.view.unbind();const e=this.behaviors;if(null!==e)for(const t of e.keys())t.disconnectedCallback&&t.disconnectedCallback(this);this.stage=3}onAttributeChangedCallback(e,t,i){const n=this.definition.attributeLookup[e];void 0!==n&&n.onAttributeChangedCallback(this.source,i)}emit(e,t,i){return 1===this.stage&&this.source.dispatchEvent(new CustomEvent(e,Object.assign(Object.assign({detail:t},cl),i)))}renderTemplate(e){var t;const i=this.source,n=null!==(t=hl(i))&&void 0!==t?t:i;if(null!==this.view)this.view.dispose(),this.view=null;else if(!this.needsInitialization||this.hasExistingShadowRoot){this.hasExistingShadowRoot=!1;for(let e=n.firstChild;null!==e;e=n.firstChild)n.removeChild(e)}e&&(this.view=e.render(i,n,i),this.view.sourceLifetime=ba.coupled)}static forCustomElement(e){const t=e.$fastController;if(void 0!==t)return t;const i=ll.getForInstance(e);if(void 0===i)throw aa.error(1401);return e.$fastController=new pl(e,i)}static setStrategy(e){pl=e}}function fl(e){var t;return"adoptedStyleSheets"in e?e:null!==(t=hl(e))&&void 0!==t?t:e.getRootNode()}da(gl),gl.setStrategy(gl);class ml{constructor(e){const t=ml.styleSheetCache;this.sheets=e.map((e=>{if(e instanceof CSSStyleSheet)return e;let i=t.get(e);return void 0===i&&(i=new CSSStyleSheet,i.replaceSync(e),t.set(e,i)),i}))}addStylesTo(e){Cl(fl(e),this.sheets)}removeStylesFrom(e){bl(fl(e),this.sheets)}}ml.styleSheetCache=new Map;let vl=0;function yl(e){return e===document?document.body:e}let Cl=(e,t)=>{e.adoptedStyleSheets=[...e.adoptedStyleSheets,...t]},bl=(e,t)=>{e.adoptedStyleSheets=e.adoptedStyleSheets.filter((e=>-1===t.indexOf(e)))};if(Ga.supportsAdoptedStyleSheets){try{document.adoptedStyleSheets.push(),document.adoptedStyleSheets.splice(),Cl=(e,t)=>{e.adoptedStyleSheets.push(...t)},bl=(e,t)=>{for(const i of t){const t=e.adoptedStyleSheets.indexOf(i);-1!==t&&e.adoptedStyleSheets.splice(t,1)}}}catch(e){}Ga.setDefaultStrategy(ml)}else Ga.setDefaultStrategy(class{constructor(e){this.styles=e,this.styleClass="fast-"+ ++vl}addStylesTo(e){e=yl(fl(e));const t=this.styles,i=this.styleClass;for(let n=0;n<t.length;n++){const o=document.createElement("style");o.innerHTML=t[n],o.className=i,e.append(o)}}removeStylesFrom(e){const t=(e=yl(fl(e))).querySelectorAll(`.${this.styleClass}`);for(let i=0,n=t.length;i<n;++i)e.removeChild(t[i])}});function Sl(e){const t=class extends e{constructor(){super(),gl.forCustomElement(this)}$emit(e,t,i){return this.$fastController.emit(e,t,i)}connectedCallback(){this.$fastController.connect()}disconnectedCallback(){this.$fastController.disconnect()}attributeChangedCallback(e,t,i){this.$fastController.onAttributeChangedCallback(e,t,i)}};return ll.registerBaseType(t),t}const xl=Object.assign(Sl(HTMLElement),{from:function(e){return Sl(e)},define:function(e,t){return ta(e)?ll.compose(e,t).define().type:ll.compose(this,e).define().type},compose:function(e,t){return ta(e)?ll.compose(e,t):ll.compose(this,e)}}),Tl="dropdown",wl="swatches";var Ol=Object.defineProperty,Pl=Object.getOwnPropertyDescriptor,Al=(e,t,i,n)=>{for(var o,r=n>1?void 0:n?Pl(t,i):t,a=e.length-1;a>=0;a--)(o=e[a])&&(r=(n?o(t,i,r):o(r))||r);return n&&r&&Ol(t,i,r),r};class El extends xl{constructor(){super(...arguments),this.type=Tl,this.size="medium",this.placeholderText="Select",this.selectedIndex=null,this.rowMaxItems=null,this.autoHideOverflowSwatches=!1,this.handleMenuOpenChange=e=>{this.open=e.detail.open}}itemsChanged(){this.items&&this.items.length>0&&this.selectedIndexHandler()}selectedIndexChanged(){this.selectedIndexHandler()}rowMaxItemsChanged(){this.updateRowMaxItems()}autoHideOverflowChanged(){this.updateRowMaxItems()}connectedCallback(){super.connectedCallback(),this.type===Tl?this.menuButtonRef.shadowRoot.querySelector("[slot='end']").style.flex="0 0 auto":this.type===wl&&this.updateRowMaxItems(),this.containerResizeObserver=new ResizeObserver((()=>{this.updateRowMaxItems()})),this.containerResizeObserver.observe(this.containerRef)}disconnectedCallback(){super.disconnectedCallback(),this.containerResizeObserver.unobserve(this.containerRef)}get getSelectedValue(){return void 0!==this._selected&&null!==this._selected&&void 0!==this.items&&this.items.length>=this._selected-1?this.items[this._selected].value:null}get getPlaceholderText(){return this.placeholderText}selectHandler(e){this._selected=this.items.map((e=>e.value)).indexOf(e.value),this.onselectionchange?.(e),this.$emit("filterchange",{selectedIndex:this._selected,item:e})}selectedIndexHandler(){this.items&&this.selectedIndex>=0&&this.selectedIndex<this.items.length&&(this._selected=this.selectedIndex)}updateRowMaxItems(){if(this.shadowRoot&&this.containerRef&&this.swatchesRef&&this.containerRef.clientWidth>0&&this.containerRef.clientWidth!==this.containerPreviousWidth){const e=this.swatchesRef.shadowRoot.querySelector("commerceui-swatch");this.itemsToFitPerRow=this.autoHideOverflowSwatches?Math.floor(this.containerRef.clientWidth/(e.clientWidth+8)):this.rowMaxItems,this.containerPreviousWidth=this.containerRef.clientWidth}}}Al([nl({attribute:"type"})],El.prototype,"type",2),Al([nl],El.prototype,"size",2),Al([nl({attribute:"open"})],El.prototype,"open",2),Al([nl],El.prototype,"label",2),Al([nl({attribute:"show-label-value",mode:"boolean"})],El.prototype,"showLabelValue",2),Al([nl({attribute:"show-label-inline",mode:"boolean"})],El.prototype,"showLabelInline",2),Al([nl({attribute:"items"})],El.prototype,"items",2),Al([nl({attribute:"placeholder-text"})],El.prototype,"placeholderText",2),Al([nl({attribute:"hide-placeholder-text",mode:"boolean"})],El.prototype,"hidePlaceholderText",2),Al([nl({attribute:"selected-index",converter:tl})],El.prototype,"selectedIndex",2),Al([nl({attribute:"row-max-items",converter:tl})],El.prototype,"rowMaxItems",2),Al([nl({attribute:"auto-hide-overflow-swatches",mode:"boolean"})],El.prototype,"autoHideOverflowSwatches",2),Al([xa],El.prototype,"itemsToFitPerRow",2),Al([xa],El.prototype,"_selected",2);const kl=Object.freeze({prefix:"commerceui",shadowRootMode:"open",registry:customElements});function Il(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a}"function"==typeof SuppressedError&&SuppressedError;const Dl="circle",_l="square",Nl="small",Rl="medium";class Ml extends xl{constructor(){super(...arguments),this.shape=_l,this.size=Rl,this.rowMaxItems=null,this.selectedIndex=null,this.items=[],this.isExpanded=!1,this._rowMaxItems=null,this.handleExpandButtonClick=()=>{this.isExpanded=!this.isExpanded}}rowMaxItemsChanged(e,t){this._rowMaxItems=t&&t>1?this.rowMaxItems:null}selectedIndexChanged(){if(this.items){let e=this.items.slice();for(let t=0;t<e.length;t++)e.splice(t,1,{...e[t],selected:this.selectedIndex===t&&!e[t].disabled});this.items=e}}getVisibleSwatches(){if(!this.items)return;let e=this.items.slice();this._rowMaxItems&&this.items.length>this._rowMaxItems&&(e=this.items.slice(0,this._rowMaxItems-1));for(let t=0;t<e.length;t++)e[t].selected=this.selectedIndex===t&&!e[t].disabled;return e}getOverflowSwatches(){if(!this.items||this.items.length<=this._rowMaxItems||!this.isExpanded)return;let e=this.items.slice(this._rowMaxItems-1,this.items.length);for(let t=0;t<e.length;t++){const i=t+this._rowMaxItems-1;e[t].selected=this.selectedIndex===i&&!e[t].disabled}return e}handleSwatchClick(e){var t;if(e.disabled)return;const i=this.items.indexOf(e);i!==this.selectedIndex&&(this.selectedIndex=i,null===(t=this.onselectionchange)||void 0===t||t.call(this,e),this.$emit("change",e))}}Il([nl],Ml.prototype,"shape",void 0),Il([nl],Ml.prototype,"size",void 0),Il([nl({attribute:"row-max-items",converter:tl})],Ml.prototype,"rowMaxItems",void 0),Il([nl({attribute:"selected-index",converter:tl})],Ml.prototype,"selectedIndex",void 0),Il([nl],Ml.prototype,"items",void 0),Il([xa],Ml.prototype,"isExpanded",void 0),Il([xa],Ml.prototype,"_rowMaxItems",void 0);const Ll="var(--colorNeutralForegroundStaticInverted)",Bl="var(--colorBrandForeground1)",Fl="var(--colorNeutralStroke1)",Ul="var(--borderRadiusMedium)",Hl="var(--fontFamilyBase)",$l="var(--fontSizeBase300)",Zl="var(--lineHeightBase300)",Vl="var(--spacingHorizontalXXS)",Gl="var(--spacingVerticalXXS)",jl=$l,zl="var(--fontWeightRegular)",Wl="var(--fontWeightSemibold)",Kl=Qa`
:host {
display: block;
}
.container {
display: flex;
flex-wrap: wrap;
gap: ${"var(--spacingHorizontalS)"};
}
.expand-button {
background: transparent;
border: none;
padding: 0 0 ${Gl} ${Vl};
color: ${Bl};
font-family: ${Hl};
font-size: ${jl};
line-height: ${Zl};
font-weight: ${zl};
text-align: start;
cursor: pointer;
}
:host([size=${Nl}]) .expand-button {
min-width: 24px;
height: 24px;
}
:host([size=${Rl}]) .expand-button {
min-width: 32px;
height: 32px;
}
:host([aria-expanded="true"]) .expand-button {
padding: 0 0 ${Gl};
text-align: center;
}
`,ql=(e,t)=>_s`<commerceui-swatch
shape=${t.shape}
size=${t.size}
selected=${e.selected}
@click=${()=>t.handleSwatchClick(e)}
:data=${e}
></commerceui-swatch>`,Yl=_s`
<button class="expand-button" role="button" @click=${e=>e.handleExpandButtonClick()}>
${e=>e.isExpanded?"Less":"+"+(e.items.length-e.rowMaxItems+1)}
</button>
`,Xl=_s`
<template aria-expanded=${e=>e.isExpanded}>
<div id="swatches-container" class="container">
${Vs((e=>e.getVisibleSwatches()),_s`${(e,t)=>ql(e,t.parent)}`)}
${Vs((e=>e.getOverflowSwatches()),_s`${(e,t)=>ql(e,t.parent)}`)}
${Bs((e=>e.items&&e._rowMaxItems&&e.items.length>e.rowMaxItems),Yl)}
</div>
</template>
`;_s`<commerceui-swatches
shape=${e=>e.shape}
size=${e=>e.size}
row-max-items=${e=>e.rowMaxItems}
selected-index=${e=>e.selectedIndex}
:items=${e=>e.items}
:onselectionchange=${e=>e.onselectionchange}
></commerceui-swatches>`,Ml.compose({name:`${kl.prefix}-swatches`,template:Xl,styles:Kl}).define(kl.registry);class Jl extends xl{constructor(){super(...arguments),this.shape=_l,this.size=Rl}}Il([nl],Jl.prototype,"shape",void 0),Il([nl],Jl.prototype,"size",void 0),Il([nl],Jl.prototype,"data",void 0);const Ql=Qa`
:host {
display: block;
}
:host([size=${Nl}]) {
width: 24px;
height: 24px;
}
:host([size=${Rl}]) {
width: 32px;
height: 32px;
}
:host([size=${"large"}]) {
width: 40px;
height: 40px;
}
.swatch {
display: flex;
align-items: center;
justify-content: center;
width: 100%;
height: 100%;
margin: 0;
padding: 0;
background-color: ${Ll};
border: none;
box-sizing: border-box;
cursor: pointer;
}
.swatch[disabled] {
opacity: 0.4;
cursor: default;
pointer-events: none;
position: relative;
overflow: hidden;
}
.color {
width: 100%;
height: 100%;
border-radius: ${Ul};
}
.swatch[disabled] .color {
opacity: 0.4;
}
.swatch[disabled]::before {
content: "";
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: linear-gradient(
to bottom right,
transparent 49%,
${Fl} 49%,
${Fl} 51%,
transparent 21%
);
z-index: 1;
}
.swatch,
.content,
:host([shape=${_l}]) .swatch,
:host([shape=${_l}]) .swatch .content {
border-radius: ${Ul};
}
:host([shape=${Dl}]) .swatch,
:host([shape=${Dl}]) .content {
border-radius: 50%;
padding: unset;
}
.content {
width: 100%;
height: 100%;
border: 1px solid ${Fl};
box-sizing: border-box;
overflow: hidden;
transition-property: width, height;
transition: 0.3s ${"var(--curveDecelerateMid)"};
padding: ${Vl};
}
.content img {
width: 100%;
height: 100%;
border-radius: ${Ul};
background-color: ${Ll};
object-fit: contain;
}
.swatch:hover {
border: 1px solid ${"var(--colorNeutralStroke1Hover)"};
}
:host([selected]) .swatch {
outline: 2px solid ${Bl};
outline-offset: -2px;
}
:host([selected]) .swatch:focus-visible {
outline: 2px solid ${"var(--colorNeutralForeground1)"};
outline-offset: 2px;
}
.swatch:hover .content,
:host([selected]) .swatch .content {
width: calc(100% - 2px);
height: calc(100% - 2px);
border: none;
}
`,ec=_s`<button
class="swatch"
role="button"
type="button"
?disabled=${e=>e.data.disabled}
>
<div class="content">
${Bs((e=>e.data.imgSrc),_s`<img
src=${e=>e.data.imgSrc}
alt=${e=>e.data.imgAlt}
title=${e=>e.data.label}
/>`)}
${Bs((e=>!e.data.imgSrc),_s`<div
class="color"
style="background-color: ${e=>e.data.fill};"
></div>`)}
</div>
</button>`,tc=_s`
<template shape=${e=>e.shape} size=${e=>e.size} ?selected=${e=>e.data.selected}>
${ec}
</template>
`;function ic(...e){return e.every((e=>e instanceof HTMLElement))}_s`<commerceui-swatch
shape=${e=>e.shape}
size=${e=>e.size}
:data=${e=>e.data}
:onclick=${e=>e.onclick}
></commerceui-swatch>`,Jl.compose({name:`${kl.prefix}-swatch`,template:tc,styles:Ql}).define(kl.registry);const nc="Enter",oc="Escape";var rc=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};class ac{}function sc(e){return e?"string"==typeof e?new ks(e):"inline"in e?e.inline():e:ks.empty}function lc(e){return`:host([hidden]){display:none}:host{display:${e}}`}rc([nl({attribute:"aria-atomic"})],ac.prototype,"ariaAtomic",void 0),rc([nl({attribute:"aria-busy"})],ac.prototype,"ariaBusy",void 0),rc([nl({attribute:"aria-controls"})],ac.prototype,"ariaControls",void 0),rc([nl({attribute:"aria-current"})],ac.prototype,"ariaCurrent",void 0),rc([nl({attribute:"aria-describedby"})],ac.prototype,"ariaDescribedby",void 0),rc([nl({attribute:"aria-details"})],ac.prototype,"ariaDetails",void 0),rc([nl({attribute:"aria-disabled"})],ac.prototype,"ariaDisabled",void 0),rc([nl({attribute:"aria-errormessage"})],ac.prototype,"ariaErrormessage",void 0),rc([nl({attribute:"aria-flowto"})],ac.prototype,"ariaFlowto",void 0),rc([nl({attribute:"aria-haspopup"})],ac.prototype,"ariaHaspopup",void 0),rc([nl({attribute:"aria-hidden"})],ac.prototype,"ariaHidden",void 0),rc([nl({attribute:"aria-invalid"})],ac.prototype,"ariaInvalid",void 0),rc([nl({attribute:"aria-keyshortcuts"})],ac.prototype,"ariaKeyshortcuts",void 0),rc([nl({attribute:"aria-label"})],ac.prototype,"ariaLabel",void 0),rc([nl({attribute:"aria-labelledby"})],ac.prototype,"ariaLabelledby",void 0),rc([nl({attribute:"aria-live"})],ac.prototype,"ariaLive",void 0),rc([nl({attribute:"aria-owns"})],ac.prototype,"ariaOwns",void 0),rc([nl({attribute:"aria-relevant"})],ac.prototype,"ariaRelevant",void 0),rc([nl({attribute:"aria-roledescription"})],ac.prototype,"ariaRoledescription",void 0);class cc{constructor(e){this.listenerCache=new WeakMap,this.query=e}connectedCallback(e){const{query:t}=this;let i=this.listenerCache.get(e);i||(i=this.constructListener(e),this.listenerCache.set(e,i)),i.bind(t)(),t.addEventListener("change",i)}disconnectedCallback(e){const t=this.listenerCache.get(e);t&&this.query.removeEventListener("change",t)}}class dc extends cc{constructor(e,t){super(e),this.styles=t}static with(e){return t=>new dc(e,t)}constructListener(e){let t=!1;const i=this.styles;return function(){const{matches:n}=this;n&&!t?(e.addStyles(i),t=n):!n&&t&&(e.removeStyles(i),t=n)}}removedCallback(e){e.removeStyles(this.styles)}}const uc=dc.with(window.matchMedia("(forced-colors)"));dc.with(window.matchMedia("(prefers-color-scheme: dark)")),dc.with(window.matchMedia("(prefers-color-scheme: light)"));class hc{}function pc(e){return _s` <slot name="end" ${Rs("end")}>${sc(e.end)}</slot> `.inline()}function gc(e){return _s` <slot name="start" ${Rs("start")}>${sc(e.start)}</slot> `.inline()}function fc(e,...t){const i=Js.locate(e);t.forEach((t=>{Object.getOwnPropertyNames(t.prototype).forEach((i=>{"constructor"!==i&&Object.defineProperty(e.prototype,i,Object.getOwnPropertyDescriptor(t.prototype,i))})),Js.locate(t).forEach((e=>i.push(e)))}))}const mc=Object.freeze({prefix:"fluent",shadowRootMode:"open",registry:customElements}),vc="var(--colorNeutralForeground1)",yc="var(--colorNeutralForeground2)",Cc="var(--colorNeutralForeground2Hover)",bc="var(--colorNeutralForeground2Pressed)",Sc="var(--colorNeutralForeground2BrandHover)",xc="var(--colorNeutralForeground2BrandPressed)",Tc="var(--colorNeutralForegroundDisabled)",wc="var(--colorNeutralForegroundOnBrand)",Oc="var(--colorNeutralBackground1)",Pc="var(--colorNeutralBackground1Hover)",Ac="var(--colorTransparentBackground)",Ec="var(--colorTransparentBackgroundHover)",kc="var(--colorTransparentBackgroundPressed)",Ic="var(--colorNeutralBackgroundDisabled)",Dc="var(--colorTransparentStroke)",_c="var(--colorStrokeFocus2)",Nc="var(--borderRadiusMedium)",Rc="var(--fontFamilyBase)",Mc="var(--fontSizeBase200)",Lc="var(--fontSizeBase300)",Bc="var(--fontSizeBase400)",Fc="var(--fontWeightRegular)",Uc="var(--fontWeightSemibold)",Hc="var(--lineHeightBase200)",$c="var(--lineHeightBase300)",Zc="var(--lineHeightBase400)",Vc="var(--spacingHorizontalXS)",Gc="submit",jc="reset",zc=Qa`
${lc("inline-flex")}
:host {
--icon-spacing: ${"var(--spacingHorizontalSNudge)"};
contain: layout style;
vertical-align: middle;
}
:host .control {
display: inline-flex;
align-items: center;
box-sizing: border-box;
justify-content: center;
text-decoration-line: none;
margin: 0;
min-height: 32px;
outline-style: none;
background-color: ${Oc};
color: ${vc};
border: ${"var(--strokeWidthThin)"} solid ${"var(--colorNeutralStroke1)"};
padding: 0 ${"var(--spacingHorizontalM)"};
min-width: 96px;
border-radius: ${Nc};
font-size: ${Lc};
font-family: ${Rc};
font-weight: ${Uc};
line-height: ${$c};
transition-duration: ${"var(--durationFaster)"};
transition-property: background, border, color;
transition-timing-function: ${"var(--curveEasyEase)"};
cursor: pointer;
}
.content {
display: inherit;
}
:host(:hover) .control {
background-color: ${Pc};
color: ${"var(--colorNeutralForeground1Hover)"};
border-color: ${"var(--colorNeutralStroke1Hover)"};
}
:host(:hover:active) .control {
background-color: ${"var(--colorNeutralBackground1Pressed)"};
border-color: ${"var(--colorNeutralStroke1Pressed)"};
color: ${"var(--colorNeutralForeground1Pressed)"};
outline-style: none;
}
:host .control:focus-visible {
border-color: ${Dc};
outline: ${"var(--strokeWidthThick)"}) solid ${Dc};
box-shadow: ${"var(--shadow4)"}, 0 0 0 2px ${_c};
}
@media screen and (prefers-reduced-motion: reduce) {
transition-duration: 0.01ms;
}
::slotted(svg) {
font-size: 20px;
height: 20px;
width: 20px;
fill: currentColor;
}
[slot='start'],
::slotted([slot='start']) {
margin-inline-end: var(--icon-spacing);
}
[slot='end'],
::slotted([slot='end']) {
margin-inline-start: var(--icon-spacing);
}
:host([icon-only]) .control {
min-width: 32px;
max-width: 32px;
}
:host([size='small']) {
--icon-spacing: ${Vc};
}
:host([size='small']) .control {
min-height: 24px;
min-width: 64px;
padding: 0 ${"var(--spacingHorizontalS)"};
border-radius: ${"var(--borderRadiusSmall)"};
font-size: ${Mc};
line-height: ${Hc};
font-weight: ${Fc};
}
:host([size='small'][icon-only]) .control {
min-width: 24px;
max-width: 24px;
}
:host([size='large']) .control {
min-height: 40px;
border-radius: ${"var(--borderRadiusLarge)"};
padding: 0 ${"var(--spacingHorizontalL)"};
font-size: ${Bc};
line-height: ${Zc};
}
:host([size='large'][icon-only]) .control {
min-width: 40px;
max-width: 40px;
}
:host([size='large']) ::slotted(svg) {
font-size: 24px;
height: 24px;
width: 24px;
}
:host([shape='circular']) .control,
:host([shape='circular']) .control:focus-visible {
border-radius: ${"var(--borderRadiusCircular)"};
}
:host([shape='square']) .control,
:host([shape='square']) .control:focus-visible {
border-radius: ${"var(--borderRadiusNone)"};
}
:host([appearance='primary']) .control {
background-color: ${"var(--colorBrandBackground)"};
color: ${wc};
border-color: transparent;
}
:host([appearance='primary']:hover) .control {
background-color: ${"var(--colorBrandBackgroundHover)"};
}
:host([appearance='primary']:hover) .control,
:host([appearance='primary']:hover:active) .control {
border-color: transparent;
color: ${wc};
}
:host([appearance='primary']:hover:active) .control {
background-color: ${"var(--colorBrandBackgroundPressed)"};
}
:host([appearance='primary']) .control:focus-visible {
border-color: ${wc};
box-shadow: ${"var(--shadow2)"}, 0 0 0 2px ${_c};
}
:host(is:([disabled][appearance='primary'], [disabled-focusabale][appearance="primary"])) .control,
:host(is:([disabled][appearance='primary'], [disabled-focusabale][appearance="primary"]):hover) .control,
:host(is:([disabled][appearance='primary'], [disabled-focusabale][appearance="primary"]):hover:active) .control {
border-color: transparent;
}
:host([appearance='outline']) .control {
background-color: ${Ac};
}
:host([appearance='outline']:hover) .control {
background-color: ${Ec};
}
:host([appearance='outline']:hover:active) .control {
background-color: ${kc};
}
:host(is:([disabled][appearance='outline'], [disabled-focusabale][appearance="outline"])) .control,
:host(is:([disabled][appearance='outline'], [disabled-focusabale][appearance="outline"]):hover) .control,
:host(is:([disabled][appearance='outline'], [disabled-focusabale][appearance="outline"]):hover:active) .control {
background-color: ${Ac};
}
:host([appearance='subtle']) .control {
background-color: ${"var(--colorSubtleBackground)"};
color: ${yc};
border-color: transparent;
}
:host([appearance='subtle']:hover) .control {
background-color: ${"var(--colorSubtleBackgroundHover)"};
color: ${Cc};
border-color: transparent;
}
:host([appearance='subtle']:hover:active) .control {
background-color: ${"var(--colorSubtleBackgroundPressed)"};
color: ${bc};
border-color: transparent;
}
:host(is:([disabled][appearance='subtle'], [disabled-focusabale][appearance="subtle"])) .control,
:host(is:([disabled][appearance='subtle'], [disabled-focusabale][appearance="subtle"]):hover) .control,
:host(is:([disabled][appearance='subtle'], [disabled-focusabale][appearance="subtle"]):hover:active) .control {
background-color: ${Ac};
border-color: transparent;
}
:host([appearance='subtle']:hover) ::slotted(svg) {
fill: ${Sc};
}
:host([appearance='subtle']:hover:active) ::slotted(svg) {
fill: ${xc};
}
:host([appearance='transparent']) .control {
background-color: ${Ac};
color: ${yc};
}
:host([appearance='transparent']:hover) .control {
background-color: ${Ec};
color: ${Sc};
}
:host([appearance='transparent']:hover:active) .control {
background-color: ${kc};
color: ${xc};
}
:host([appearance='transparent']) .control,
:host([appearance='transparent']:hover) .control,
:host([appearance='transparent']:hover:active) .control {
border-color: transparent;
}
:host(is:([disabled][appearance='transparent'], [disabled-focusabale][appearance="transparent"])) .control,
:host(is:([disabled][appearance='transparent'], [disabled-focusabale][appearance="transparent"]):hover) .control,
:host(is:([disabled][appearance='transparent'], [disabled-focusabale][appearance="transparent"]):hover:active) .control {
border-color: transparent;
background-color: ${Ac};
}
:host(:is([disabled], [disabled-focusable], [appearance][disabled], [appearance][disabled-focusable])) .control,
:host(:is([disabled], [disabled-focusable], [appearance][disabled], [appearance][disabled-focusable]):hover) .control,
:host(:is([disabled], [disabled-focusable], [appearance][disabled], [appearance][disabled-focusable]):hover:active)
.control {
background-color: ${Ic};
border-color: ${"var(--colorNeutralStrokeDisabled)"};
color: ${Tc};
cursor: not-allowed;
}
`.withBehaviors(uc(Qa`
:host([appearance='transparent']:hover) .control {
border-color: Highlight;
}
`)),Wc="form-associated-proxy",Kc="ElementInternals",qc=Kc in window&&"setFormValue"in window[Kc].prototype,Yc=new WeakMap;class Xc extends xl{}class Jc extends(function(e){const t=class extends e{constructor(...e){super(...e),this.dirtyValue=!1,this.initialValue="",this.disabled=!1,this.proxyEventsToBlock=["change","click"],this.proxyInitialized=!1,this.required=!1,this.initialValue=this.initialValue||"",this.elementInternals||(this.formResetCallback=this.formResetCallback.bind(this))}static get formAssociated(){return qc}get validity(){return this.elementInternals?this.elementInternals.validity:this.proxy.validity}get form(){return this.elementInternals?this.elementInternals.form:this.proxy.form}get validationMessage(){return this.elementInternals?this.elementInternals.validationMessage:this.proxy.validationMessage}get willValidate(){return this.elementInternals?this.elementInternals.willValidate:this.proxy.willValidate}get labels(){if(this.elementInternals)return Object.freeze(Array.from(this.elementInternals.labels));if(this.proxy instanceof HTMLElement&&this.proxy.ownerDocument&&this.id){const e=this.proxy.labels,t=Array.from(this.proxy.getRootNode().querySelectorAll(`[for='${this.id}']`)),i=e?t.concat(Array.from(e)):t;return Object.freeze(i)}return sa}valueChanged(e,t){this.dirtyValue=!0,this.proxy instanceof HTMLElement&&(this.proxy.value=this.value),this.currentValue=this.value,this.setFormValue(this.value),this.validate()}currentValueChanged(){this.value=this.currentValue}initialValueChanged(e,t){this.dirtyValue||(this.value=this.initialValue,this.dirtyValue=!1)}disabledChanged(e,t){this.proxy instanceof HTMLElement&&(this.proxy.disabled=this.disabled),va.enqueue((()=>this.classList.toggle("disabled",this.disabled)))}nameChanged(e,t){this.proxy instanceof HTMLElement&&(this.proxy.name=this.name)}requiredChanged(e,t){this.proxy instanceof HTMLElement&&(this.proxy.required=this.required),va.enqueue((()=>this.classList.toggle("required",this.required))),this.validate()}get elementInternals(){if(!qc)return null;let e=Yc.get(this);return e||(e=this.attachInternals(),Yc.set(this,e)),e}connectedCallback(){super.connectedCallback(),this.addEventListener("keypress",this._keypressHandler),this.value||(this.value=this.initialValue,this.dirtyValue=!1),this.elementInternals||(this.attachProxy(),this.form&&this.form.addEventListener("reset",this.formResetCallback))}disconnectedCallback(){this.proxyEventsToBlock.forEach((e=>this.proxy.removeEventListener(e,this.stopPropagation))),!this.elementInternals&&this.form&&this.form.removeEventListener("reset",this.formResetCallback)}checkValidity(){return this.elementInternals?this.elementInternals.checkValidity():this.proxy.checkValidity()}reportValidity(){return this.elementInternals?this.elementInternals.reportValidity():this.proxy.reportValidity()}setValidity(e,t,i){this.elementInternals?this.elementInternals.setValidity(e,t,i):"string"==typeof t&&this.proxy.setCustomValidity(t)}formDisabledCallback(e){this.disabled=e}formResetCallback(){this.value=this.initialValue,this.dirtyValue=!1}attachProxy(){var e;this.proxyInitialized||(this.proxyInitialized=!0,this.proxy.style.display="none",this.proxyEventsToBlock.forEach((e=>this.proxy.addEventListener(e,this.stopPropagation))),this.proxy.disabled=this.disabled,this.proxy.required=this.required,"string"==typeof this.name&&(this.proxy.name=this.name),"string"==typeof this.value&&(this.proxy.value=this.value),this.proxy.setAttribute("slot",Wc),this.proxySlot=document.createElement("slot"),this.proxySlot.setAttribute("name",Wc)),null===(e=this.shadowRoot)||void 0===e||e.appendChild(this.proxySlot),this.appendChild(this.proxy)}detachProxy(){var e;this.removeChild(this.proxy),null===(e=this.shadowRoot)||void 0===e||e.removeChild(this.proxySlot)}validate(e){this.proxy instanceof HTMLElement&&this.setValidity(this.proxy.validity,this.proxy.validationMessage,e)}setFormValue(e,t){this.elementInternals&&this.elementInternals.setFormValue(e,t||e)}_keypressHandler(e){if(e.key===nc&&this.form instanceof HTMLFormElement){const e=this.form.querySelector("[type=submit]");null==e||e.click()}}stopPropagation(e){e.stopPropagation()}};return nl({mode:"boolean"})(t.prototype,"disabled"),nl({mode:"fromView",attribute:"value"})(t.prototype,"initialValue"),nl({attribute:"current-value"})(t.prototype,"currentValue"),nl(t.prototype,"name"),nl({mode:"boolean"})(t.prototype,"required"),xa(t.prototype,"value"),t}(Xc)){constructor(){super(...arguments),this.proxy=document.createElement("input")}}var Qc=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};class ed extends Jc{constructor(){super(...arguments),this.iconOnly=!1,this.disabledFocusable=!1,this.handleDisabledFocusableClick=e=>{e&&this.disabledFocusable&&e.stopImmediatePropagation()},this.handleSubmission=()=>{if(!this.form)return;const e=this.proxy.isConnected;e||this.attachProxy(),"function"==typeof this.form.requestSubmit?this.form.requestSubmit(this.proxy):this.proxy.click(),e||this.detachProxy()},this.handleFormReset=()=>{var e;null===(e=this.form)||void 0===e||e.reset()}}formactionChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.formAction=this.formaction)}formenctypeChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.formEnctype=this.formenctype)}formmethodChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.formMethod=this.formmethod)}formnovalidateChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.formNoValidate=this.formnovalidate)}formtargetChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.formTarget=this.formtarget)}typeChanged(e,t){this.proxy instanceof HTMLInputElement&&(this.proxy.type=this.type),t===Gc&&this.addEventListener("click",this.handleSubmission),e===Gc&&this.removeEventListener("click",this.handleSubmission),t===jc&&this.addEventListener("click",this.handleFormReset),e===jc&&this.removeEventListener("click",this.handleFormReset)}disabledFocusableChanged(e,t){this.$fastController.isConnected&&(this.disabledFocusable?this.setAttribute("aria-disabled","true"):this.removeAttribute("aria-disabled"))}validate(){super.validate(this.control)}connectedCallback(){super.connectedCallback(),this.proxy.setAttribute("type",this.type),this.addEventListener("click",this.handleDisabledFocusableClick)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("click",this.handleDisabledFocusableClick)}}Qc([nl({mode:"boolean"})],ed.prototype,"autofocus",void 0),Qc([nl({attribute:"form"})],ed.prototype,"formId",void 0),Qc([nl],ed.prototype,"formaction",void 0),Qc([nl],ed.prototype,"formenctype",void 0),Qc([nl],ed.prototype,"formmethod",void 0),Qc([nl({mode:"boolean"})],ed.prototype,"formnovalidate",void 0),Qc([nl],ed.prototype,"formtarget",void 0),Qc([nl],ed.prototype,"type",void 0),Qc([nl],ed.prototype,"appearance",void 0),Qc([nl],ed.prototype,"shape",void 0),Qc([nl],ed.prototype,"size",void 0),Qc([nl({attribute:"icon-only",mode:"boolean"})],ed.prototype,"iconOnly",void 0),Qc([nl({attribute:"disabled-focusable",mode:"boolean"})],ed.prototype,"disabledFocusable",void 0),Qc([xa],ed.prototype,"defaultSlottedContent",void 0);class td{}function id(e={}){return _s`
<button
class="control"
part="control"
?autofocus="${e=>e.autofocus}"
?disabled="${e=>e.disabled}"
form="${e=>e.formId}"
formaction="${e=>e.formaction}"
formenctype="${e=>e.formenctype}"
formmethod="${e=>e.formmethod}"
?formnovalidate="${e=>e.formnovalidate}"
formtarget="${e=>e.formtarget}"
name="${e=>e.name}"
type="${e=>e.type}"
value="${e=>e.value}"
aria-atomic="${e=>e.ariaAtomic}"
aria-busy="${e=>e.ariaBusy}"
aria-controls="${e=>e.ariaControls}"
aria-current="${e=>e.ariaCurrent}"
aria-describedby="${e=>e.ariaDescribedby}"
aria-details="${e=>e.ariaDetails}"
aria-disabled="${e=>e.ariaDisabled}"
aria-errormessage="${e=>e.ariaErrormessage}"
aria-expanded="${e=>e.ariaExpanded}"
aria-flowto="${e=>e.ariaFlowto}"
aria-haspopup="${e=>e.ariaHaspopup}"
aria-hidden="${e=>e.ariaHidden}"
aria-invalid="${e=>e.ariaInvalid}"
aria-keyshortcuts="${e=>e.ariaKeyshortcuts}"
aria-label="${e=>e.ariaLabel}"
aria-labelledby="${e=>e.ariaLabelledby}"
aria-live="${e=>e.ariaLive}"
aria-owns="${e=>e.ariaOwns}"
aria-pressed="${e=>e.ariaPressed}"
aria-relevant="${e=>e.ariaRelevant}"
aria-roledescription="${e=>e.ariaRoledescription}"
${Rs("control")}
>
${gc(e)}
<span class="content" part="content">
<slot ${qs("defaultSlottedContent")}></slot>
</span>
${pc(e)}
</button>
`}Qc([nl({attribute:"aria-expanded"})],td.prototype,"ariaExpanded",void 0),Qc([nl({attribute:"aria-pressed"})],td.prototype,"ariaPressed",void 0),fc(td,ac),fc(ed,hc,td),id();var nd=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};class od extends xl{constructor(){super(...arguments),this.disabled=!1,this.required=!1}}nd([nl],od.prototype,"size",void 0),nd([nl],od.prototype,"weight",void 0),nd([nl({mode:"boolean"})],od.prototype,"disabled",void 0),nd([nl({mode:"boolean"})],od.prototype,"required",void 0);const rd=Qa`
${lc("flex")}
:host {
font-family: ${Rc};
font-size: ${Lc};
line-height: ${$c};
font-weight: ${Fc};
color: ${vc};
}
.asterisk {
color: ${"var(--colorPaletteRedForeground1)"};
margin-left: ${Vc};
}
:host([size='small']) {
font-size: ${Mc};
line-height: ${Hc};
}
:host([size='large']) {
font-size: ${Bc};
line-height: ${Zc};
font-weight: ${Uc};
}
:host([weight='semibold']) {
font-weight: ${Uc};
}
:host([disabled]),
:host([disabled]) .asterisk {
color: ${Tc};
}
`,ad=_s`
<slot></slot>
<span part="asterisk" class="asterisk" ?hidden="${e=>!e.required}">*</span>
`,sd=od.compose({name:`${mc.prefix}-label`,template:ad,styles:rd}),ld=["top","right","bottom","left"],cd=Math.min,dd=Math.max,ud=Math.round,hd=Math.floor,pd=e=>({x:e,y:e}),gd={left:"right",right:"left",bottom:"top",top:"bottom"},fd={start:"end",end:"start"};function md(e,t,i){return dd(e,cd(t,i))}function vd(e,t){return"function"==typeof e?e(t):e}function yd(e){return e.split("-")[0]}function Cd(e){return e.split("-")[1]}function bd(e){return"x"===e?"y":"x"}function Sd(e){return"y"===e?"height":"width"}function xd(e){return["top","bottom"].includes(yd(e))?"y":"x"}function Td(e){return bd(xd(e))}function wd(e){return e.replace(/start|end/g,(e=>fd[e]))}function Od(e){return e.replace(/left|right|bottom|top/g,(e=>gd[e]))}function Pd(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}function Ad(e,t,i){let{reference:n,floating:o}=e;const r=xd(t),a=Td(t),s=Sd(a),l=yd(t),c="y"===r,d=n.x+n.width/2-o.width/2,u=n.y+n.height/2-o.height/2,h=n[s]/2-o[s]/2;let p;switch(l){case"top":p={x:d,y:n.y-o.height};break;case"bottom":p={x:d,y:n.y+n.height};break;case"right":p={x:n.x+n.width,y:u};break;case"left":p={x:n.x-o.width,y:u};break;default:p={x:n.x,y:n.y}}switch(Cd(t)){case"start":p[a]-=h*(i&&c?-1:1);break;case"end":p[a]+=h*(i&&c?-1:1)}return p}async function Ed(e,t){var i;void 0===t&&(t={});const{x:n,y:o,platform:r,rects:a,elements:s,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:d="viewport",elementContext:u="floating",altBoundary:h=!1,padding:p=0}=vd(t,e),g=function(e){return"number"!=typeof e?function(e){return{top:0,right:0,bottom:0,left:0,...e}}(e):{top:e,right:e,bottom:e,left:e}}(p),f=s[h?"floating"===u?"reference":"floating":u],m=Pd(await r.getClippingRect({element:null==(i=await(null==r.isElement?void 0:r.isElement(f)))||i?f:f.contextElement||await(null==r.getDocumentElement?void 0:r.getDocumentElement(s.floating)),boundary:c,rootBoundary:d,strategy:l})),v="floating"===u?{...a.floating,x:n,y:o}:a.reference,y=await(null==r.getOffsetParent?void 0:r.getOffsetParent(s.floating)),C=await(null==r.isElement?void 0:r.isElement(y))&&await(null==r.getScale?void 0:r.getScale(y))||{x:1,y:1},b=Pd(r.convertOffsetParentRelativeRectToViewportRelativeRect?await r.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:v,offsetParent:y,strategy:l}):v);return{top:(m.top-b.top+g.top)/C.y,bottom:(b.bottom-m.bottom+g.bottom)/C.y,left:(m.left-b.left+g.left)/C.x,right:(b.right-m.right+g.right)/C.x}}function kd(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Id(e){return ld.some((t=>e[t]>=0))}function Dd(e){return Rd(e)?(e.nodeName||"").toLowerCase():"#document"}function _d(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function Nd(e){var t;return null==(t=(Rd(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function Rd(e){return e instanceof Node||e instanceof _d(e).Node}function Md(e){return e instanceof Element||e instanceof _d(e).Element}function Ld(e){return e instanceof HTMLElement||e instanceof _d(e).HTMLElement}function Bd(e){return"undefined"!=typeof ShadowRoot&&(e instanceof ShadowRoot||e instanceof _d(e).ShadowRoot)}function Fd(e){const{overflow:t,overflowX:i,overflowY:n,display:o}=Vd(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+i)&&!["inline","contents"].includes(o)}function Ud(e){return["table","td","th"].includes(Dd(e))}function Hd(e){const t=$d(),i=Vd(e);return"none"!==i.transform||"none"!==i.perspective||!!i.containerType&&"normal"!==i.containerType||!t&&!!i.backdropFilter&&"none"!==i.backdropFilter||!t&&!!i.filter&&"none"!==i.filter||["transform","perspective","filter"].some((e=>(i.willChange||"").includes(e)))||["paint","layout","strict","content"].some((e=>(i.contain||"").includes(e)))}function $d(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function Zd(e){return["html","body","#document"].includes(Dd(e))}function Vd(e){return _d(e).getComputedStyle(e)}function Gd(e){return Md(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function jd(e){if("html"===Dd(e))return e;const t=e.assignedSlot||e.parentNode||Bd(e)&&e.host||Nd(e);return Bd(t)?t.host:t}function zd(e){const t=jd(e);return Zd(t)?e.ownerDocument?e.ownerDocument.body:e.body:Ld(t)&&Fd(t)?t:zd(t)}function Wd(e,t,i){var n;void 0===t&&(t=[]),void 0===i&&(i=!0);const o=zd(e),r=o===(null==(n=e.ownerDocument)?void 0:n.body),a=_d(o);return r?t.concat(a,a.visualViewport||[],Fd(o)?o:[],a.frameElement&&i?Wd(a.frameElement):[]):t.concat(o,Wd(o,[],i))}function Kd(e){const t=Vd(e);let i=parseFloat(t.width)||0,n=parseFloat(t.height)||0;const o=Ld(e),r=o?e.offsetWidth:i,a=o?e.offsetHeight:n,s=ud(i)!==r||ud(n)!==a;return s&&(i=r,n=a),{width:i,height:n,$:s}}function qd(e){return Md(e)?e:e.contextElement}function Yd(e){const t=qd(e);if(!Ld(t))return pd(1);const i=t.getBoundingClientRect(),{width:n,height:o,$:r}=Kd(t);let a=(r?ud(i.width):i.width)/n,s=(r?ud(i.height):i.height)/o;return a&&Number.isFinite(a)||(a=1),s&&Number.isFinite(s)||(s=1),{x:a,y:s}}const Xd=pd(0);function Jd(e){const t=_d(e);return $d()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:Xd}function Qd(e,t,i,n){void 0===t&&(t=!1),void 0===i&&(i=!1);const o=e.getBoundingClientRect(),r=qd(e);let a=pd(1);t&&(n?Md(n)&&(a=Yd(n)):a=Yd(e));const s=function(e,t,i){return void 0===t&&(t=!1),!(!i||t&&i!==_d(e))&&t}(r,i,n)?Jd(r):pd(0);let l=(o.left+s.x)/a.x,c=(o.top+s.y)/a.y,d=o.width/a.x,u=o.height/a.y;if(r){const e=_d(r),t=n&&Md(n)?_d(n):n;let i=e,o=i.frameElement;for(;o&&n&&t!==i;){const e=Yd(o),t=o.getBoundingClientRect(),n=Vd(o),r=t.left+(o.clientLeft+parseFloat(n.paddingLeft))*e.x,a=t.top+(o.clientTop+parseFloat(n.paddingTop))*e.y;l*=e.x,c*=e.y,d*=e.x,u*=e.y,l+=r,c+=a,i=_d(o),o=i.frameElement}}return Pd({width:d,height:u,x:l,y:c})}const eu=[":popover-open",":modal"];function tu(e){return eu.some((t=>{try{return e.matches(t)}catch(e){return!1}}))}function iu(e){return Qd(Nd(e)).left+Gd(e).scrollLeft}function nu(e,t,i){let n;if("viewport"===t)n=function(e,t){const i=_d(e),n=Nd(e),o=i.visualViewport;let r=n.clientWidth,a=n.clientHeight,s=0,l=0;if(o){r=o.width,a=o.height;const e=$d();(!e||e&&"fixed"===t)&&(s=o.offsetLeft,l=o.offsetTop)}return{width:r,height:a,x:s,y:l}}(e,i);else if("document"===t)n=function(e){const t=Nd(e),i=Gd(e),n=e.ownerDocument.body,o=dd(t.scrollWidth,t.clientWidth,n.scrollWidth,n.clientWidth),r=dd(t.scrollHeight,t.clientHeight,n.scrollHeight,n.clientHeight);let a=-i.scrollLeft+iu(e);const s=-i.scrollTop;return"rtl"===Vd(n).direction&&(a+=dd(t.clientWidth,n.clientWidth)-o),{width:o,height:r,x:a,y:s}}(Nd(e));else if(Md(t))n=function(e,t){const i=Qd(e,!0,"fixed"===t),n=i.top+e.clientTop,o=i.left+e.clientLeft,r=Ld(e)?Yd(e):pd(1);return{width:e.clientWidth*r.x,height:e.clientHeight*r.y,x:o*r.x,y:n*r.y}}(t,i);else{const i=Jd(e);n={...t,x:t.x-i.x,y:t.y-i.y}}return Pd(n)}function ou(e,t){const i=jd(e);return!(i===t||!Md(i)||Zd(i))&&("fixed"===Vd(i).position||ou(i,t))}function ru(e,t,i){const n=Ld(t),o=Nd(t),r="fixed"===i,a=Qd(e,!0,r,t);let s={scrollLeft:0,scrollTop:0};const l=pd(0);if(n||!n&&!r)if(("body"!==Dd(t)||Fd(o))&&(s=Gd(t)),n){const e=Qd(t,!0,r,t);l.x=e.x+t.clientLeft,l.y=e.y+t.clientTop}else o&&(l.x=iu(o));return{x:a.left+s.scrollLeft-l.x,y:a.top+s.scrollTop-l.y,width:a.width,height:a.height}}function au(e,t){return Ld(e)&&"fixed"!==Vd(e).position?t?t(e):e.offsetParent:null}function su(e,t){const i=_d(e);if(!Ld(e)||tu(e))return i;let n=au(e,t);for(;n&&Ud(n)&&"static"===Vd(n).position;)n=au(n,t);return n&&("html"===Dd(n)||"body"===Dd(n)&&"static"===Vd(n).position&&!Hd(n))?i:n||function(e){let t=jd(e);for(;Ld(t)&&!Zd(t);){if(Hd(t))return t;t=jd(t)}return null}(e)||i}const lu={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:t,rect:i,offsetParent:n,strategy:o}=e;const r="fixed"===o,a=Nd(n),s=!!t&&tu(t.floating);if(n===a||s&&r)return i;let l={scrollLeft:0,scrollTop:0},c=pd(1);const d=pd(0),u=Ld(n);if((u||!u&&!r)&&(("body"!==Dd(n)||Fd(a))&&(l=Gd(n)),Ld(n))){const e=Qd(n);c=Yd(n),d.x=e.x+n.clientLeft,d.y=e.y+n.clientTop}return{width:i.width*c.x,height:i.height*c.y,x:i.x*c.x-l.scrollLeft*c.x+d.x,y:i.y*c.y-l.scrollTop*c.y+d.y}},getDocumentElement:Nd,getClippingRect:function(e){let{element:t,boundary:i,rootBoundary:n,strategy:o}=e;const r=[..."clippingAncestors"===i?function(e,t){const i=t.get(e);if(i)return i;let n=Wd(e,[],!1).filter((e=>Md(e)&&"body"!==Dd(e))),o=null;const r="fixed"===Vd(e).position;let a=r?jd(e):e;for(;Md(a)&&!Zd(a);){const t=Vd(a),i=Hd(a);i||"fixed"!==t.position||(o=null),(r?!i&&!o:!i&&"static"===t.position&&o&&["absolute","fixed"].includes(o.position)||Fd(a)&&!i&&ou(e,a))?n=n.filter((e=>e!==a)):o=t,a=jd(a)}return t.set(e,n),n}(t,this._c):[].concat(i),n],a=r[0],s=r.reduce(((e,i)=>{const n=nu(t,i,o);return e.top=dd(n.top,e.top),e.right=cd(n.right,e.right),e.bottom=cd(n.bottom,e.bottom),e.left=dd(n.left,e.left),e}),nu(t,a,o));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}},getOffsetParent:su,getElementRects:async function(e){const t=this.getOffsetParent||su,i=this.getDimensions;return{reference:ru(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,...await i(e.floating)}}},getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){const{width:t,height:i}=Kd(e);return{width:t,height:i}},getScale:Yd,isElement:Md,isRTL:function(e){return"rtl"===Vd(e).direction}};function cu(e,t,i,n){void 0===n&&(n={});const{ancestorScroll:o=!0,ancestorResize:r=!0,elementResize:a="function"==typeof ResizeObserver,layoutShift:s="function"==typeof IntersectionObserver,animationFrame:l=!1}=n,c=qd(e),d=o||r?[...c?Wd(c):[],...Wd(t)]:[];d.forEach((e=>{o&&e.addEventListener("scroll",i,{passive:!0}),r&&e.addEventListener("resize",i)}));const u=c&&s?function(e,t){let i,n=null;const o=Nd(e);function r(){var e;clearTimeout(i),null==(e=n)||e.disconnect(),n=null}return function a(s,l){void 0===s&&(s=!1),void 0===l&&(l=1),r();const{left:c,top:d,width:u,height:h}=e.getBoundingClientRect();if(s||t(),!u||!h)return;const p={rootMargin:-hd(d)+"px "+-hd(o.clientWidth-(c+u))+"px "+-hd(o.clientHeight-(d+h))+"px "+-hd(c)+"px",threshold:dd(0,cd(1,l))||1};let g=!0;function f(e){const t=e[0].intersectionRatio;if(t!==l){if(!g)return a();t?a(!1,t):i=setTimeout((()=>{a(!1,1e-7)}),100)}g=!1}try{n=new IntersectionObserver(f,{...p,root:o.ownerDocument})}catch(e){n=new IntersectionObserver(f,p)}n.observe(e)}(!0),r}(c,i):null;let h,p=-1,g=null;a&&(g=new ResizeObserver((e=>{let[n]=e;n&&n.target===c&&g&&(g.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame((()=>{var e;null==(e=g)||e.observe(t)}))),i()})),c&&!l&&g.observe(c),g.observe(t));let f=l?Qd(e):null;return l&&function t(){const n=Qd(e);!f||n.x===f.x&&n.y===f.y&&n.width===f.width&&n.height===f.height||i(),f=n,h=requestAnimationFrame(t)}(),i(),()=>{var e;d.forEach((e=>{o&&e.removeEventListener("scroll",i),r&&e.removeEventListener("resize",i)})),null==u||u(),null==(e=g)||e.disconnect(),g=null,l&&cancelAnimationFrame(h)}}const du=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var i,n;const{placement:o,middlewareData:r,rects:a,initialPlacement:s,platform:l,elements:c}=t,{mainAxis:d=!0,crossAxis:u=!0,fallbackPlacements:h,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:g="none",flipAlignment:f=!0,...m}=vd(e,t);if(null!=(i=r.arrow)&&i.alignmentOffset)return{};const v=yd(o),y=yd(s)===s,C=await(null==l.isRTL?void 0:l.isRTL(c.floating)),b=h||(y||!f?[Od(s)]:function(e){const t=Od(e);return[wd(e),t,wd(t)]}(s));h||"none"===g||b.push(...function(e,t,i,n){const o=Cd(e);let r=function(e,t,i){const n=["left","right"],o=["right","left"],r=["top","bottom"],a=["bottom","top"];switch(e){case"top":case"bottom":return i?t?o:n:t?n:o;case"left":case"right":return t?r:a;default:return[]}}(yd(e),"start"===i,n);return o&&(r=r.map((e=>e+"-"+o)),t&&(r=r.concat(r.map(wd)))),r}(s,f,g,C));const S=[s,...b],x=await Ed(t,m),T=[];let w=(null==(n=r.flip)?void 0:n.overflows)||[];if(d&&T.push(x[v]),u){const e=function(e,t,i){void 0===i&&(i=!1);const n=Cd(e),o=Td(e),r=Sd(o);let a="x"===o?n===(i?"end":"start")?"right":"left":"start"===n?"bottom":"top";return t.reference[r]>t.floating[r]&&(a=Od(a)),[a,Od(a)]}(o,a,C);T.push(x[e[0]],x[e[1]])}if(w=[...w,{placement:o,overflows:T}],!T.every((e=>e<=0))){var O,P;const e=((null==(O=r.flip)?void 0:O.index)||0)+1,t=S[e];if(t)return{data:{index:e,overflows:w},reset:{placement:t}};let i=null==(P=w.filter((e=>e.overflows[0]<=0)).sort(((e,t)=>e.overflows[1]-t.overflows[1]))[0])?void 0:P.placement;if(!i)switch(p){case"bestFit":{var A;const e=null==(A=w.map((e=>[e.placement,e.overflows.filter((e=>e>0)).reduce(((e,t)=>e+t),0)])).sort(((e,t)=>e[1]-t[1]))[0])?void 0:A[0];e&&(i=e);break}case"initialPlacement":i=s}if(o!==i)return{reset:{placement:i}}}return{}}}},uu=function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){const{placement:i,rects:n,platform:o,elements:r}=t,{apply:a=(()=>{}),...s}=vd(e,t),l=await Ed(t,s),c=yd(i),d=Cd(i),u="y"===xd(i),{width:h,height:p}=n.floating;let g,f;"top"===c||"bottom"===c?(g=c,f=d===(await(null==o.isRTL?void 0:o.isRTL(r.floating))?"start":"end")?"left":"right"):(f=c,g="end"===d?"top":"bottom");const m=p-l[g],v=h-l[f],y=!t.middlewareData.shift;let C=m,b=v;if(u){const e=h-l.left-l.right;b=d||y?cd(v,e):e}else{const e=p-l.top-l.bottom;C=d||y?cd(m,e):e}if(y&&!d){const e=dd(l.left,0),t=dd(l.right,0),i=dd(l.top,0),n=dd(l.bottom,0);u?b=h-2*(0!==e||0!==t?e+t:dd(l.left,l.right)):C=p-2*(0!==i||0!==n?i+n:dd(l.top,l.bottom))}await a({...t,availableWidth:b,availableHeight:C});const S=await o.getDimensions(r.floating);return h!==S.width||p!==S.height?{reset:{rects:!0}}:{}}}},hu=(e,t,i)=>{const n=new Map,o={platform:lu,...i},r={...o.platform,_c:n};return(async(e,t,i)=>{const{placement:n="bottom",strategy:o="absolute",middleware:r=[],platform:a}=i,s=r.filter(Boolean),l=await(null==a.isRTL?void 0:a.isRTL(t));let c=await a.getElementRects({reference:e,floating:t,strategy:o}),{x:d,y:u}=Ad(c,n,l),h=n,p={},g=0;for(let i=0;i<s.length;i++){const{name:r,fn:f}=s[i],{x:m,y:v,data:y,reset:C}=await f({x:d,y:u,initialPlacement:n,placement:h,strategy:o,middlewareData:p,rects:c,platform:a,elements:{reference:e,floating:t}});d=null!=m?m:d,u=null!=v?v:u,p={...p,[r]:{...p[r],...y}},C&&g<=50&&(g++,"object"==typeof C&&(C.placement&&(h=C.placement),C.rects&&(c=!0===C.rects?await a.getElementRects({reference:e,floating:t,strategy:o}):C.rects),({x:d,y:u}=Ad(c,h,l))),i=-1)}return{x:d,y:u,placement:h,strategy:o,middlewareData:p}})(e,t,{...o,platform:r})};var pu=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};class gu extends xl{constructor(){super(...arguments),this.openOnHover=!1,this.openOnContext=!1,this.closeOnScroll=!1,this.persistOnItemClick=!1,this.open=!1,this.slottedMenuList=[],this.slottedTriggers=[],this.toggleMenu=()=>{this.open?this.closeMenu():this.openMenu()},this.closeMenu=()=>{this.open=!1,this.closeOnScroll&&document.removeEventListener("scroll",this.closeMenu)},this.openMenu=e=>{this.open=!0,e&&this.openOnContext&&e.preventDefault(),this.closeOnScroll&&document.addEventListener("scroll",this.closeMenu)},this.setPositioningTask=()=>{this.setPositioning()},this.handleTriggerKeydown=e=>{if(!e.defaultPrevented)switch(e.key){case" ":case nc:e.preventDefault(),this.toggleMenu(),this.open&&this.focusMenuList();break;default:return!0}},this.handleDocumentClick=e=>{!e||e.composedPath().includes(this._menuList)||e.composedPath().includes(this._trigger)||this.closeMenu()}}connectedCallback(){super.connectedCallback(),va.enqueue((()=>this.setComponent()))}disconnectedCallback(){var e;super.disconnectedCallback(),null===(e=this.cleanup)||void 0===e||e.call(this),this.removeListeners()}setComponent(){this.$fastController.isConnected&&this.slottedMenuList.length&&this.slottedTriggers.length&&(this._trigger=this.slottedTriggers[0],this._menuList=this.slottedMenuList[0],this._trigger.setAttribute("aria-haspopup","true"),this._trigger.setAttribute("aria-expanded",`${this.open}`),this.addListeners())}focusMenuList(){this.open&&this._menuList&&va.enqueue((()=>{this._menuList.focus()}))}focusTrigger(){!this.open&&this._trigger&&va.enqueue((()=>{this._trigger.focus()}))}openChanged(e,t){var i;this.$fastController.isConnected&&this._trigger instanceof HTMLElement&&(this._trigger.setAttribute("aria-expanded",`${this.open}`),this._menuList&&this.open&&va.enqueue(this.setPositioningTask)),null===(i=this.cleanup)||void 0===i||i.call(this),this.$emit("onOpenChange",{open:t})}openOnHoverChanged(e,t){var i,n;t?null===(i=this._trigger)||void 0===i||i.addEventListener("mouseover",this.openMenu):null===(n=this._trigger)||void 0===n||n.removeEventListener("mouseover",this.openMenu)}persistOnItemClickChanged(e,t){var i,n;t?null===(n=this._menuList)||void 0===n||n.removeEventListener("click",this.closeMenu):null===(i=this._menuList)||void 0===i||i.addEventListener("click",this.closeMenu)}openOnContextChanged(e,t){var i,n;t?null===(i=this._trigger)||void 0===i||i.addEventListener("contextmenu",this.openMenu):null===(n=this._trigger)||void 0===n||n.removeEventListener("contextmenu",this.openMenu)}closeOnScrollChanged(e,t){t?document.addEventListener("scroll",this.closeMenu):document.removeEventListener("scroll",this.closeMenu)}setPositioning(){this.$fastController.isConnected&&this._menuList&&this.open&&this._trigger&&(this.cleanup=cu(this,this.positioningContainer,(async()=>{var e,t;const{middlewareData:i,x:n,y:o}=await hu(this._trigger,this.positioningContainer,{placement:"bottom",strategy:"fixed",middleware:[du(),uu({apply:({availableHeight:e,rects:t})=>{var i;(null===(i=this.positioningContainer)||void 0===i?void 0:i.style)&&Object.assign(this.positioningContainer.style,{maxHeight:`${e}px`,width:`${t.reference.width}px`})}}),(void 0===r&&(r={}),{name:"hide",options:r,async fn(e){const{rects:t}=e,{strategy:i="referenceHidden",...n}=vd(r,e);switch(i){case"referenceHidden":{const i=kd(await Ed(e,{...n,elementContext:"reference"}),t.reference);return{data:{referenceHiddenOffsets:i,referenceHidden:Id(i)}}}case"escaped":{const i=kd(await Ed(e,{...n,altBoundary:!0}),t.floating);return{data:{escapedOffsets:i,escaped:Id(i)}}}default:return{}}}})]});var r;(null===(e=i.hide)||void 0===e?void 0:e.referenceHidden)?this.open=!1:(null===(t=this.positioningContainer)||void 0===t?void 0:t.style)&&Object.assign(this.positioningContainer.style,{position:"fixed",top:"0",left:"0",transform:`translate(${n}px, ${o}px)`})})))}addListeners(){var e,t,i,n,o;document.addEventListener("click",this.handleDocumentClick),null===(e=this._trigger)||void 0===e||e.addEventListener("keydown",this.handleTriggerKeydown),this.persistOnItemClick||null===(t=this._menuList)||void 0===t||t.addEventListener("click",this.closeMenu),this.openOnHover?null===(i=this._trigger)||void 0===i||i.addEventListener("mouseover",this.openMenu):this.openOnContext?null===(n=this._trigger)||void 0===n||n.addEventListener("contextmenu",this.openMenu):null===(o=this._trigger)||void 0===o||o.addEventListener("click",this.toggleMenu)}removeListeners(){var e,t,i,n,o;document.removeEventListener("click",this.handleDocumentClick),null===(e=this._trigger)||void 0===e||e.removeEventListener("keydown",this.handleTriggerKeydown),this.persistOnItemClick||null===(t=this._menuList)||void 0===t||t.removeEventListener("click",this.closeMenu),this.openOnHover&&(null===(i=this._trigger)||void 0===i||i.removeEventListener("mouseover",this.openMenu)),this.openOnContext?null===(n=this._trigger)||void 0===n||n.removeEventListener("contextmenu",this.openMenu):null===(o=this._trigger)||void 0===o||o.removeEventListener("click",this.toggleMenu)}handleMenuKeydown(e){if(!e.defaultPrevented)switch(e.key){case oc:e.preventDefault(),this.open&&(this.closeMenu(),this.focusTrigger());break;case"Tab":this.open&&this.closeMenu(),e.shiftKey&&this.focusTrigger();default:return!0}}}pu([xa,nl({attribute:"open-on-hover",mode:"boolean"})],gu.prototype,"openOnHover",void 0),pu([xa,nl({attribute:"open-on-context",mode:"boolean"})],gu.prototype,"openOnContext",void 0),pu([xa,nl({attribute:"close-on-scroll",mode:"boolean"})],gu.prototype,"closeOnScroll",void 0),pu([xa,nl({attribute:"persist-on-item-click",mode:"boolean"})],gu.prototype,"persistOnItemClick",void 0),pu([xa,nl({mode:"boolean"})],gu.prototype,"open",void 0),pu([xa],gu.prototype,"slottedMenuList",void 0),pu([xa],gu.prototype,"slottedTriggers",void 0);const fu=_s`
<template
?open-on-hover="${e=>e.openOnHover}"
?open-on-context="${e=>e.openOnContext}"
?close-on-scroll="${e=>e.closeOnScroll}"
?persist-on-item-click="${e=>e.persistOnItemClick}"
@keydown="${(e,t)=>e.handleMenuKeydown(t.event)}"
>
<slot name="trigger" ${qs({property:"slottedTriggers",filter:js()})}></slot>
<span
${Rs("positioningContainer")}
part="positioning-container"
class="positioning-container"
?hidden="${e=>!e.open}"
>
<slot ${qs({property:"slottedMenuList",filter:js()})}></slot>
</span>
</template>
`,mu=Qa`
:host {
position: relative;
z-index: var(--z-index-menu, 1);
}
.positioning-container {
position: fixed;
top: 0;
left: 0;
transform: translate(0, 0);
}
`,vu=gu.compose({name:`${mc.prefix}-menu`,template:fu,styles:mu}),yu=id({end:_s.partial('<svg slot="end" fill="currentColor" aria-hidden="true" width="1em" height="1em" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path d="M15.85 7.65c.2.2.2.5 0 .7l-5.46 5.49a.55.55 0 0 1-.78 0L4.15 8.35a.5.5 0 1 1 .7-.7L10 12.8l5.15-5.16c.2-.2.5-.2.7 0Z" fill="currentColor"></path></svg>')}),Cu=class extends ed{}.compose({name:`${mc.prefix}-menu-button`,template:yu,styles:zc,shadowOptions:{delegatesFocus:!0}}),bu={menuitem:"menuitem",menuitemcheckbox:"menuitemcheckbox",menuitemradio:"menuitemradio"};var Su=function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a};class xu extends xl{constructor(){super(...arguments),this.role=bu.menuitem,this.checked=!1,this.focusSubmenuOnLoad=!1,this.handleMenuItemKeyDown=e=>{if(e.defaultPrevented)return!1;switch(e.key){case nc:case" ":return this.invoke(),!1;case"ArrowRight":return this.expanded&&this.submenu?this.submenu.focus():this.expandAndFocus(),!1;case oc:case"ArrowLeft":if(this.expanded)return this.closeSubMenu(),!1}return!0},this.handleMenuItemClick=e=>(e.defaultPrevented||this.disabled||this.invoke(),!1),this.submenuLoaded=()=>{this.focusSubmenuOnLoad&&(this.focusSubmenuOnLoad=!1,this.submenu&&(this.submenu.focus(),this.setAttribute("tabindex","-1")))},this.handleMouseOver=e=>(this.disabled||!this.hasSubmenu||this.expanded||(this.expanded=!0),!1),this.handleMouseOut=e=>(!this.expanded||this.contains(document.activeElement)||(this.expanded=!1),!1),this.closeSubMenu=()=>{this.expanded=!1,this.focus()},this.expandAndFocus=()=>{this.hasSubmenu&&(this.focusSubmenuOnLoad=!0,this.expanded=!0)},this.invoke=()=>{if(!this.disabled)switch(this.role){case bu.menuitemcheckbox:this.checked=!this.checked;break;case bu.menuitem:if(this.hasSubmenu){this.expandAndFocus();break}this.$emit("change");break;case bu.menuitemradio:this.checked||(this.checked=!0)}}}expandedChanged(e,t){this.$fastController.isConnected&&(t&&this.submenu&&this.updateSubmenu(),this.$emit("expanded-change",this,{bubbles:!1}))}checkedChanged(e,t){this.$fastController.isConnected&&this.$emit("change")}get hasSubmenu(){return!!this.submenu}slottedSubmenuChanged(e,t){t.length&&(this.submenu=t[0],this.updateSubmenu())}disconnectedCallback(){var e;null===(e=this.cleanup)||void 0===e||e.call(this),super.disconnectedCallback()}updateSubmenu(){var e;null===(e=this.cleanup)||void 0===e||e.call(this),this.submenu&&this.expanded&&va.enqueue((()=>{this.cleanup=cu(this,this.submenuContainer,(async()=>{const e=["left-start","right-start"],{x:t,y:i}=await hu(this,this.submenuContainer,{middleware:[(void 0===n&&(n={}),{name:"shift",options:n,async fn(e){const{x:t,y:i,placement:o}=e,{mainAxis:r=!0,crossAxis:a=!1,limiter:s={fn:e=>{let{x:t,y:i}=e;return{x:t,y:i}}},...l}=vd(n,e),c={x:t,y:i},d=await Ed(e,l),u=xd(yd(o)),h=bd(u);let p=c[h],g=c[u];if(r){const e="y"===h?"bottom":"right";p=md(p+d["y"===h?"top":"left"],p,p-d[e])}if(a){const e="y"===u?"bottom":"right";g=md(g+d["y"===u?"top":"left"],g,g-d[e])}const f=s.fn({...e,[h]:p,[u]:g});return{...f,data:{x:f.x-t,y:f.y-i}}}}),uu({apply:({availableWidth:t,rects:i})=>{t<i.floating.width&&e.push("bottom-end","top-end")}}),du({fallbackPlacements:e})],placement:"right-start",strategy:"fixed"});var n;Object.assign(this.submenuContainer.style,{left:`${t}px`,position:"fixed",top:`${i}px`}),this.submenuLoaded()}))}))}}Su([nl({mode:"boolean"})],xu.prototype,"disabled",void 0),Su([nl({mode:"boolean"})],xu.prototype,"expanded",void 0),Su([nl],xu.prototype,"role",void 0),Su([nl({mode:"boolean"})],xu.prototype,"checked",void 0),Su([nl({mode:"boolean"})],xu.prototype,"hidden",void 0),Su([xa],xu.prototype,"slottedSubmenu",void 0),Su([xa],xu.prototype,"submenu",void 0),fc(xu,hc);const Tu=_s.partial('<svg fill="currentColor" class="___12fm75w f1w7gpdv fez10in fg4l7m0" aria-hidden="true" width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M14.05 3.49c.28.3.27.77-.04 1.06l-7.93 7.47A.85.85 0 014.9 12L2.22 9.28a.75.75 0 111.06-1.06l2.24 2.27 7.47-7.04a.75.75 0 011.06.04z" fill="currentColor"></path></svg>'),wu=function(e={}){return _s`
<template
aria-haspopup="${e=>e.hasSubmenu?"menu":void 0}"
aria-checked="${e=>e.role!==bu.menuitem?e.checked:void 0}"
aria-disabled="${e=>e.disabled}"
aria-expanded="${e=>e.expanded}"
@keydown="${(e,t)=>e.handleMenuItemKeyDown(t.event)}"
@click="${(e,t)=>e.handleMenuItemClick(t.event)}"
@mouseover="${(e,t)=>e.handleMouseOver(t.event)}"
@mouseout="${(e,t)=>e.handleMouseOut(t.event)}"
>
${Bs((e=>e.role===bu.menuitemcheckbox),_s`
<div part="input-container" class="input-container">
<span part="checkbox" class="checkbox">
<slot name="checkbox-indicator"> ${sc(e.checkboxIndicator)} </slot>
</span>
</div>
`)}
${Bs((e=>e.role===bu.menuitemradio),_s`
<div part="input-container" class="input-container">
<span part="radio" class="radio">
<slot name="radio-indicator"> ${sc(e.radioIndicator)} </slot>
</span>
</div>
`)}
</div>
${gc(e)}
<span class="content" part="content">
<slot></slot>
</span>
${pc(e)}
${Bs((e=>e.hasSubmenu),_s`
<div part="expand-collapse-glyph-container" class="expand-collapse-glyph-container">
<span part="expand-collapse" class="expand-collapse">
<slot name="expand-collapse-indicator"> ${sc(e.expandCollapseGlyph)} </slot>
</span>
</div>
`)}
<span
?hidden="${e=>!e.expanded}"
class="submenu-container"
part="submenu-container"
${Rs("submenuContainer")}
>
<slot name="submenu" ${qs({property:"slottedSubmenu",filter:js("[role='menu']")})}></slot>
</span>
</template>
`}({checkboxIndicator:Tu,expandCollapseGlyph:_s.partial('<svg fill="currentColor" class="___12fm75w f1w7gpdv fez10in fg4l7m0" aria-hidden="true" width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M5.74 3.2a.75.75 0 00-.04 1.06L9.23 8 5.7 11.74a.75.75 0 101.1 1.02l4-4.25a.75.75 0 000-1.02l-4-4.25a.75.75 0 00-1.06-.04z" fill="currentColor"></path></svg>'),radioIndicator:Tu}),Ou=Qa`
${lc("grid")}
:host {
grid-template-columns: 20px 20px auto 20px;
align-items: center;
grid-gap: 4px;
height: 32px;
background: ${Oc};
font: ${Fc} ${Lc} / ${$c} ${Rc};
border-radius: ${Nc};
color: ${yc};
padding: 0 10px;
cursor: pointer;
overflow: visible;
contain: layout;
}
:host(:hover) {
background: ${Pc};
}
.content {
white-space: nowrap;
flex-grow: 1;
grid-column: auto / span 2;
padding: 0 2px;
}
.checkbox,
.radio {
display: none;
}
.input-container,
.expand-collapse-glyph-container,
::slotted([slot='start']),
::slotted([slot='end']),
:host([checked]) .checkbox,
:host([checked]) .radio {
display: inline-flex;
justify-content: center;
align-items: center;
color: ${yc};
}
.expand-collapse-glyph-container,
::slotted([slot='start']),
::slotted([slot='end']) {
height: 32px;
font-size: ${"var(--fontSizeBase500)"};
width: fit-content;
}
.input-container {
width: 20px;
}
::slotted([slot='end']) {
color: ${"var(--colorNeutralForeground3)"};
font: ${Fc} ${Mc} / ${Hc} ${Rc};
white-space: nowrap;
grid-column: 4 / span 1;
justify-self: flex-end;
}
.expand-collapse-glyph-container {
grid-column: 4 / span 1;
justify-self: flex-end;
}
:host(:hover) .input-container,
:host(:hover) .expand-collapse-glyph-container,
:host(:hover) .content {
color: ${Cc};
}
:host([icon]:hover) ::slotted([slot='start']) {
color: ${"var(--colorCompoundBrandForeground1Hover)"};
}
:host(:active) {
background-color: ${"var(--colorNeutralBackground1Selected)"};
}
:host(:active) .input-container,
:host(:active) .expand-collapse-glyph-container,
:host(:active) .content {
color: ${bc};
}
:host(:active) ::slotted([slot='start']) {
color: ${"var(--colorCompoundBrandForeground1Pressed)"};
}
:host([disabled]) {
background-color: ${Ic};
}
:host([disabled]) .content,
:host([disabled]) .expand-collapse-glyph-container,
:host([disabled]) ::slotted([slot='end']),
:host([disabled]) ::slotted([slot='start']) {
color: ${Tc};
}
:host([data-indent]) {
display: grid;
}
:host([data-indent='1']) .content {
grid-column: 2 / span 1;
}
:host([data-indent='1'][role='menuitemcheckbox']) {
display: grid;
}
:host([data-indent='2'][aria-haspopup='menu']) ::slotted([slot='end']) {
grid-column: 4 / span 1;
}
:host([data-indent='2'][aria-haspopup='menu']) .expand-collapse-glyph-container {
grid-column: 5 / span 1;
}
:host([data-indent='1']) .content {
grid-column: 2 / span 1;
}
:host([data-indent='1'][role='menuitemcheckbox']) .content,
:host([data-indent='1'][role='menuitemradio']) .content {
grid-column: auto / span 1;
}
:host([icon]) ::slotted([slot='end']),
:host([data-indent='1']) ::slotted([slot='end']) {
grid-column: 4 / span 1;
justify-self: flex-end;
}
:host([data-indent='2']) {
display: grid;
grid-template-columns: 20px 20px auto auto;
}
:host([data-indent='2']) .content {
grid-column: 3 / span 1;
}
:host([data-indent='2']) .input-container {
grid-column: 1 / span 1;
}
:host([data-indent='2']) ::slotted([slot='start']) {
grid-column: 2 / span 1;
}
:host([aria-haspopup='menu']) {
grid-template-columns: 20px auto auto 20px;
}
:host([data-indent='2'][aria-haspopup='menu']) {
grid-template-columns: 20px 20px auto auto 20px;
}
:host([aria-haspopup='menu']) ::slotted([slot='end']) {
grid-column: 3 / span 1;
justify-self: flex-end;
}
:host([data-indent='2'][aria-haspopup='menu']) ::slotted([slot='end']) {
grid-column: 4 / span 1;
justify-self: flex-end;
}
`,Pu=xu.compose({name:`${mc.prefix}-menu-item`,template:wu,styles:Ou});class Au extends xl{constructor(){super(...arguments),this.expandedItem=null,this.focusIndex=-1,this.isNestedMenu=()=>null!==this.parentElement&&ic(this.parentElement)&&"menuitem"===this.parentElement.getAttribute("role"),this.handleFocusOut=e=>{if(!this.contains(e.relatedTarget)&&void 0!==this.menuItems){this.collapseExpandedItem();const e=this.menuItems.findIndex(this.isFocusableElement);this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.menuItems[e].setAttribute("tabindex","0"),this.focusIndex=e}},this.handleItemFocus=e=>{const t=e.target;void 0!==this.menuItems&&t!==this.menuItems[this.focusIndex]&&(this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.focusIndex=this.menuItems.indexOf(t),t.setAttribute("tabindex","0"))},this.handleExpandedChanged=e=>{if(e.defaultPrevented||null===e.target||void 0===this.menuItems||this.menuItems.indexOf(e.target)<0)return;e.preventDefault();const t=e.target;null===this.expandedItem||t!==this.expandedItem||!1!==t.expanded?t.expanded&&(null!==this.expandedItem&&this.expandedItem!==t&&(this.expandedItem.expanded=!1),this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.expandedItem=t,this.focusIndex=this.menuItems.indexOf(t),t.setAttribute("tabindex","0")):this.expandedItem=null},this.changeHandler=e=>{if(void 0===this.menuItems)return;const t=e.target,i=this.menuItems.indexOf(t);if(-1!==i&&"menuitemradio"===t.role&&!0===t.checked){for(let e=i-1;e>=0;--e){const t=this.menuItems[e],i=t.getAttribute("role");if(i===bu.menuitemradio&&(t.checked=!1),"separator"===i)break}const e=this.menuItems.length-1;for(let t=i+1;t<=e;++t){const e=this.menuItems[t],i=e.getAttribute("role");if(i===bu.menuitemradio&&(e.checked=!1),"separator"===i)break}}},this.isMenuItemElement=e=>e instanceof xu||ic(e)&&e.getAttribute("role")in Au.focusableElementRoles,this.isFocusableElement=e=>this.isMenuItemElement(e)}itemsChanged(e,t){this.$fastController.isConnected&&void 0!==this.menuItems&&this.setItems()}connectedCallback(){super.connectedCallback(),va.enqueue((()=>{this.setItems()})),this.addEventListener("change",this.changeHandler)}disconnectedCallback(){super.disconnectedCallback(),this.removeItemListeners(),this.menuItems=void 0,this.removeEventListener("change",this.changeHandler)}focus(){this.setFocus(0,1)}collapseExpandedItem(){null!==this.expandedItem&&(this.expandedItem.expanded=!1,this.expandedItem=null)}handleMenuKeyDown(e){if(!e.defaultPrevented&&void 0!==this.menuItems)switch(e.key){case"ArrowDown":return void this.setFocus(this.focusIndex+1,1);case"ArrowUp":return void this.setFocus(this.focusIndex-1,-1);case"End":return void this.setFocus(this.menuItems.length-1,-1);case"Home":return void this.setFocus(0,1);default:return!0}}removeItemListeners(e=this.items){e.forEach((e=>{e.removeEventListener("focus",this.handleItemFocus),e.removeEventListener("expanded-changed",this.handleExpandedChanged),Sa.getNotifier(e).unsubscribe(this,"hidden")}))}static elementIndent(e){const t=e.getAttribute("role"),i=e.querySelector("[slot=start]");return t&&t!==bu.menuitem?i?2:1:i?1:0}setItems(){var e;const t=Array.from(this.children);this.removeItemListeners(t),t.forEach((e=>Sa.getNotifier(e).subscribe(this,"hidden")));const i=t.filter((e=>!e.hasAttribute("hidden")));this.menuItems=i;const n=this.menuItems.filter(this.isMenuItemElement);n.length&&(this.focusIndex=0),n.forEach(((e,t)=>{e.setAttribute("tabindex",0===t?"0":"-1"),e.addEventListener("expanded-change",this.handleExpandedChanged),e.addEventListener("focus",this.handleItemFocus)}));const o=null===(e=this.menuItems)||void 0===e?void 0:e.filter(this.isMenuItemElement);null==o||o.forEach(((e,t)=>{const i=null==o?void 0:o.reduce(((e,t)=>{const i=Au.elementIndent(t);return Math.max(e,i)}),0);e instanceof xu&&e.setAttribute("data-indent",`${i}`)}))}handleChange(e,t){"hidden"===t&&this.setItems()}setFocus(e,t){if(void 0!==this.menuItems)for(;e>=0&&e<this.menuItems.length;){const i=this.menuItems[e];if(this.isFocusableElement(i)){this.focusIndex>-1&&this.menuItems.length>=this.focusIndex-1&&this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.focusIndex=e,i.setAttribute("tabindex","0"),i.focus();break}e+=t}}}Au.focusableElementRoles=bu,function(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);r>3&&a&&Object.defineProperty(t,i,a)}([xa],Au.prototype,"items",void 0);const Eu=_s`
<template
slot="${e=>e.slot?e.slot:e.isNestedMenu()?"submenu":void 0}"
role="menu"
@keydown="${(e,t)=>e.handleMenuKeyDown(t.event)}"
@focusout="${(e,t)=>e.handleFocusOut(t.event)}"
>
<slot ${qs("items")}></slot>
</template>
`,ku=Qa`
${lc("flex")}
:host {
flex-direction: column;
height: fit-content;
max-width: 300px;
min-width: 160px;
width: auto;
background-color: ${Oc};
border: 1px solid ${Dc};
border-radius: ${Nc};
box-shadow: ${"var(--shadow16)"};
padding: 4px;
row-gap: 2px;
}
`,Iu=Au.compose({name:`${mc.prefix}-menu-list`,template:Eu,styles:ku});sd.name="fluent-beta-label",sd.define(customElements),vu.name="fluent-beta-menu",vu.define(customElements),Cu.name="fluent-beta-menu-button",Cu.define(customElements),Iu.name="fluent-beta-menu-list",Iu.define(customElements),Pu.name="fluent-beta-menu-item",Pu.define(customElements);const Du=_s`
<div class="container" ${Rs("containerRef")}>
${Bs((e=>!e.showLabelInline),_s`<fluent-beta-label
><span class="label">${e=>e.label}</span>
${Bs((e=>e.showLabelValue),_s`<span class="label-value">${e=>e.getSelectedValue}</span>`)}
</fluent-beta-label>`)}
${Bs((e=>e.type===Tl),_s`
<fluent-beta-menu
open=${e=>e.open}
@onOpenChange=${(e,t)=>e.handleMenuOpenChange(t.event)}
>
<fluent-beta-menu-button
class="menu-button"
appearance="outline"
slot="trigger"
size=${e=>e.size}
${Rs("menuButtonRef")}
>${Bs((e=>!e.getSelectedValue&&!e.hidePlaceholderText),_s`<span class="placeholder">${e=>e.getPlaceholderText}</span>`)}
${Bs((e=>e.getSelectedValue),_s`
${Bs((e=>e.showLabelInline),_s`<span class="label">${e=>e.label}</span>`)}
<span class="label-value">${e=>e.getSelectedValue}</span>
`)}
</fluent-beta-menu-button>
<fluent-beta-menu-list class="menu-list">
${Vs((e=>e.items),_s`<fluent-beta-menu-item
class="menu-item"
?disabled=${e=>e.disabled}
@change=${(e,t)=>t.parent.selectHandler(e)}
><div class="menu-item-label">${e=>e.label}</div></fluent-beta-menu-item
>`)}
</fluent-beta-menu-list>
</fluent-beta-menu>
`)}
${Bs((e=>e.type===wl),_s`
<commerceui-swatches
${Rs("swatchesRef")}
:items=${e=>e.items}
size=${e=>e.size}
selected-index=${e=>e.selectedIndex}
row-max-items=${e=>e.itemsToFitPerRow}
@change=${(e,t)=>{e.selectHandler(t.event.detail)}}
></commerceui-swatches>
`)}
</div>
`;_s`<commerceui-filter
:items=${e=>e.items}
type=${e=>e.type}
label=${e=>e.label}
show-label-value=${e=>e.showLabelValue}
selected-index=${e=>e.selectedIndex}
placeholder-text=${e=>e.placeholderText}
auto-hide-overflow-swatches=${e=>e.autoHideOverflowSwatches}
hide-placeholder-text=${e=>e.hidePlaceholderText}
show-label-value=${e=>e.showLabelValue}
show-label-inline=${e=>e.showLabelInline}
open=${e=>e.open}
row-max-items=${e=>e.rowMaxItems}
size=${e=>e.size}
:onselectionchange=${e=>e.onselectionchange}
></commerceui-filter>`;const _u=Qa`
:host {
overflow: hidden;
}
.container {
display: flex;
flex-direction: column;
align-items: flex-start;
row-gap: ${"var(--spacingVerticalXS)"};
}
.placeholder {
color: ${"var(--colorNeutralForeground4)"};
font-family: ${Hl};
font-size: ${jl};
font-weight: ${zl};
}
fluent-beta-label {
max-width: 100%;
}
.label {
font-weight: ${Wl};
}
.label-value {
margin-inline-start: ${"var(--spacingHorizontalXS)"};
font-weight: ${zl};
}
fluent-beta-menu {
max-width: 100%;
}
fluent-beta-menu[open="true"] {
z-index: 2;
}
fluent-beta-menu-button {
max-width: 100%;
}
.menu-button::part(control) {
flex: 1;
min-width: 0;
width: max-content;
background-color: ${"var(--colorNeutralBackground1)"};
}
.label,
.menu-button::part(content),
.menu-button .label-value {
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
}
fluent-beta-menu-list {
width: fit-content;
min-width: fit-content;
max-width: fit-content;
}
fluent-beta-menu-item {
grid-template-columns: auto;
}
fluent-beta-menu-item[disabled] {
pointer-events: none;
background: none;
}
fluent-beta-menu-item .menu-item-label {
overflow: hidden;
text-overflow: ellipsis;
}
`,Nu=Object.freeze({prefix:"commerceui",shadowRootMode:"open",registry:customElements});El.compose({name:`${Nu.prefix}-filter`,template:Du,styles:_u});const Ru=re`
:host .slot-filter-group {
display: flex;
flex-wrap: wrap;
row-gap: ${ui};
column-gap: ${si};
}
:host([inline-swatches]:not([auto-hide-overflow-swatches])) .slot-filter-group {
flex-wrap: nowrap;
}
:host([direction=${At.column}]) .slot-filter-group {
flex-direction: column;
}
:host([direction=${At.row}]) .slot-filter-group {
flex-direction: row;
}
commerceui-filter[type=${wl}] {
flex-basis: 100%;
}
:host([inline-swatches]:not([auto-hide-overflow-swatches])) commerceui-filter[type=${wl}] {
flex-basis: content;
}
`,Mu=Object.freeze({prefix:"commerceui",shadowRootMode:"open",registry:customElements}),Lu=Dt.compose({name:`${Mu.prefix}-buying-options-filter-group`,template:Xr,styles:Ru}),Bu={compact:"compact",regular:"regular"},Fu={edge:"edge",pdp:"pdp",serp:"serp"};var Uu=Object.defineProperty,Hu=Object.getOwnPropertyDescriptor,$u=(e,t,i,n)=>{for(var o,r=n>1?void 0:n?Hu(t,i):t,a=e.length-1;a>=0;a--)(o=e[a])&&(r=(n?o(t,i,r):o(r))||r);return n&&r&&Uu(t,i,r),r};class Zu extends Pt{constructor(){super(...arguments),this.layout=Bu.compact,this.appearance=Fu.edge,this.handleNavigation=!1,this.hideRetailersLogo=!1,this.noDataLabel="No data available",this.lowestPriceLabel="Lowest Price",this.discountPriceLabel="Save",this.ctaButtonLabel="Visit Site"}dataChanged(e,t){this._data=t}clickEventHandler(e,t){this.handleNavigation&&this.getRetailerData(e).item.url&&void 0!==this.getRetailerData(e).item.url&&""!==this.getRetailerData(e).item.url&&window.open(this.getRetailerData(e).item.url,this.getRetailerData(e).item?.target),this.onretailerclick?.(e,t),this.$emit("retailerclick",{retailerIndex:e,event:t})}clickCtaEventHandler(e,t){t.stopPropagation(),this.handleNavigation&&this.getRetailerData(e).ctaButton.url&&void 0!==this.getRetailerData(e).ctaButton.url&&""!==this.getRetailerData(e).ctaButton.url&&window.open(this.getRetailerData(e).ctaButton.url,this.getRetailerData(e).ctaButton?.target),this.onretailerctaclick?.(e,t),this.$emit("retailerctaclick",{retailerIndex:e,event:t})}mouseEventHandler(e,t){this.onretailerhover?.(e,t),this.$emit("retailerhover",{retailerIndex:e,event:t})}get getData(){return this._data}getRetailerData(e){return this._data?.retailers[e]}}$u([st],Zu.prototype,"data",2),$u([st],Zu.prototype,"locale",2),$u([st],Zu.prototype,"currency",2),$u([st],Zu.prototype,"layout",2),$u([st],Zu.prototype,"appearance",2),$u([st({attribute:"handle-navigation",mode:"boolean"})],Zu.prototype,"handleNavigation",2),$u([st({attribute:"hide-retailers-logo"})],Zu.prototype,"hideRetailersLogo",2),$u([st({attribute:"no-data-label"})],Zu.prototype,"noDataLabel",2),$u([st({attribute:"lowest-price-label"})],Zu.prototype,"lowestPriceLabel",2),$u([st({attribute:"discount-price-label"})],Zu.prototype,"discountPriceLabel",2),$u([st({attribute:"cta-button-label"})],Zu.prototype,"ctaButtonLabel",2),$u([A],Zu.prototype,"_data",2);const Vu=re`
:host {
}
:host .container {
}
:host ul {
list-style-type: none;
margin: 0;
padding: 0;
}
:host li {
margin: 0;
padding: 0;
}
:host a {
text-decoration: none;
}
:host .retailer-list {
}
:host .retailer-list-item {
cursor: pointer;
}
:host .retailer-list-item:not(:last-child) {
border-bottom: 1px solid ${Wt};
}
:host .no-data-label {
font-family: ${hi};
font-size: ${pi};
font-weight: ${gi};
color: ${"var(--colorPaletteRedForeground3)"};
}
:host .retailer-list-item a {
display: flex;
flex-direction: row;
align-items: top;
padding-block: ${ui};
padding-inline: ${si};
column-gap: ${"var(--spacingHorizontalM)"};
}
:host commerceui-retailer-item {
flex: 1;
}
:host .price {
display: flex;
flex-direction: column;
row-gap: ${di};
justify-content: flex-start;
align-items: flex-end;
align-content: flex-start;
min-width: 60px;
}
:host .save-label {
display: flex;
flex-direction: row;
column-gap: ${ci};
align-items: self-end;
font-family: ${mi};
font-size: ${vi};
font-weight: ${yi};
color: ${qt};
}
:host .cta-button {
display: flex;
justify-content: flex-start;
flex-direction: column;
}
/*********************************************
* Edge Appearance styles
**********************************************/
:host .appearance-edge {
border: 1px solid ${Wt};
border-radius: ${Jt};
background-color: ${Zt};
box-shadow: ${"var(--shadow2)"};
}
:host .appearance-edge .retailer-list-item:first-child :hover {
border-top-left-radius: ${Jt};
border-top-right-radius: ${Jt};
}
:host .appearance-edge .retailer-list-item:last-child :hover {
border-bottom-left-radius: ${Jt};
border-bottom-right-radius: ${Jt};
}
:host .appearance-edge .retailer-list-item :hover {
background-color: ${Vt};
transition: background-color 0.3s ease-in-out;
}
/*********************************************
* PDP Appearance styles
**********************************************/
:host .appearance-pdp {
border: 1px solid ${zt};
border-radius: ${"var(--borderRadiusLarge)"};
}
:host .appearance-pdp .retailer-list-item:first-child :hover {
border-top-left-radius: ${Jt};
border-top-right-radius: ${Jt};
}
:host .appearance-pdp .retailer-list-item:last-child :hover {
border-bottom-left-radius: ${Jt};
border-bottom-right-radius: ${Jt};
}
:host .appearance-pdp .retailer-list-item :hover {
background-color: ${Vt};
transition: background-color 0.3s ease-in-out;
}
/*********************************************
* SERP Appearance styles
**********************************************/
:host .appearance-serp {
border: 1px solid ${zt};
border-radius: ${Jt};
}
:host .appearance-serp .retailer-list-item:first-child :hover {
border-top-left-radius: ${Jt};
border-top-right-radius: ${Jt};
}
:host .appearance-serp .retailer-list-item:last-child :hover {
border-bottom-left-radius: ${Jt};
border-bottom-right-radius: ${Jt};
}
:host .appearance-serp .retailer-list-item :hover {
background-color: ${"var(--colorNeutralBackground3Hover)"};
transition: background-color 0.3s ease-in-out;
}
`,Gu="accent-primary",ju=Object.freeze({prefix:"commerceui",shadowRootMode:"open",registry:customElements}),zu="xx-small",Wu="x-small",Ku="small",qu="medium",Yu="large",Xu="x-large",Ju="neutral",Qu="accent-primary",eh="accent-secondary",th="accent-brand",ih="subtle",nh="inverted",oh="inherit",rh="bottom",ah="start";let sh=class extends Pt{constructor(){super(...arguments),this.value=0,this.locale="en-US",this.currency="USD",this.currencySymbol="$",this.nonBreakingSpace=!1,this.currencySymbolPosition=ah,this.percentSymbol="%",this.perItemLabel="",this.perItemSeparator="/",this.size=qu,this.color=Ju,this.hideCurrency=!1,this.discountLabel="off",this.discountLabelPosition=rh,this.hideCents=!1,this.showZeroCents=!1,this.showRaisedCents=!1,this.showDiscountPercent=!1,this.strikethrough=!1,this.showDiscount=!1}};Nt([st({attribute:"value",converter:rt})],sh.prototype,"value",void 0),Nt([st],sh.prototype,"locale",void 0),Nt([st],sh.prototype,"currency",void 0),Nt([st({attribute:"currency-symbol"})],sh.prototype,"currencySymbol",void 0),Nt([st({attribute:"non-breaking-space"})],sh.prototype,"nonBreakingSpace",void 0),Nt([st({attribute:"currency-symbol-position"})],sh.prototype,"currencySymbolPosition",void 0),Nt([st({attribute:"percent-symbol"})],sh.prototype,"percentSymbol",void 0),Nt([st({attribute:"per-item-label"})],sh.prototype,"perItemLabel",void 0),Nt([st({attribute:"per-item-separator"})],sh.prototype,"perItemSeparator",void 0),Nt([st],sh.prototype,"size",void 0),Nt([st],sh.prototype,"color",void 0),Nt([st({attribute:"hide-currency",mode:"boolean"})],sh.prototype,"hideCurrency",void 0),Nt([st({attribute:"discount-label"})],sh.prototype,"discountLabel",void 0),Nt([st({attribute:"discount-label-position"})],sh.prototype,"discountLabelPosition",void 0),Nt([st({attribute:"hide-cents",mode:"boolean"})],sh.prototype,"hideCents",void 0),Nt([st({attribute:"show-zero-cents",mode:"boolean"})],sh.prototype,"showZeroCents",void 0),Nt([st({attribute:"show-raised-cents",mode:"boolean"})],sh.prototype,"showRaisedCents",void 0),Nt([st({attribute:"show-discount-percent",mode:"boolean"})],sh.prototype,"showDiscountPercent",void 0),Nt([st({mode:"boolean"})],sh.prototype,"strikethrough",void 0),Nt([st({mode:"boolean",attribute:"show-discount"})],sh.prototype,"showDiscount",void 0);let lh=class extends sh{constructor(){super(...arguments),this._hideDecimal=!1,this._currencySymbol=this.currencySymbol,this._currencySymbolPosition=ah,this._hasNonBreakingSpace=!1,this._discountLabel=this.discountLabel,this._percentSymbol="%"}valueChanged(){this.updateLocalizedValues()}localeChanged(){this.updateLocalizedValues()}currencyChanged(){this.updateLocalizedValues()}updateLocalizedValues(){const e=this.value,t=this.currency||"USD",i=((e,t,i)=>{var n,o,r,a;const s={},l={style:"currency",currency:i,currencyDisplay:"symbol"},c=Intl.NumberFormat(t,l).formatToParts(e);let d="";return c.forEach((e=>{"integer"!==e.type&&"group"!==e.type||(d=d.concat(e.value))})),s.currencySymbol=null===(n=c.find((e=>"currency"===e.type)))||void 0===n?void 0:n.value,s.valueInteger=d,s.decimalSymbol=(null===(o=c.find((e=>"decimal"===e.type)))||void 0===o?void 0:o.value)||".",s.valueCents=(null===(r=c.find((e=>"fraction"===e.type)))||void 0===r?void 0:r.value)||"00",s.currencySymbolPosition="currency"==(null===(a=c[0])||void 0===a?void 0:a.type)?ah:"end",s.hasNonBreakingSpace=null!=c.find((e=>"literal"===e.type&&" "===e.value)),s})(e,this.locale||void 0,t);this._currencySymbol=i.currencySymbol,this._valueInteger=i.valueInteger,this._decimalSymbol=i.decimalSymbol,this._valueCents=i.valueCents,this._currencySymbolPosition=i.currencySymbolPosition,this._hasNonBreakingSpace=i.hasNonBreakingSpace}connectedCallback(){super.connectedCallback(),"00"!==this._valueCents||!1!==this.showZeroCents&&void 0!==this.showZeroCents||(this.hideCents=!0),!this.showRaisedCents||this.size!==Ku&&this.size!==Wu&&this.size!==zu||(this.showRaisedCents=!1,this._hideDecimal=!1),this.showDiscount&&(this.showRaisedCents=!1),!0===this.showDiscount&&!0===this.showDiscountPercent&&(this.hideCurrency=!0,this.hideCents=!0),!0!==this.hideCents&&!0!==this.showRaisedCents||(this._hideDecimal=!0)}get getDiscountLabel(){return this._discountLabel}get getCurrencySymbol(){return this._currencySymbol}get getPercentSymbol(){return this._percentSymbol}get getDecimalSymbol(){return this._decimalSymbol}get getValueInteger(){return this._valueInteger}get getValueCents(){return this._valueCents}get getHideDecimal(){return this._hideDecimal}get getCurrencySymbolPosition(){return this.currencySymbolPosition?this.currencySymbolPosition:this._currencySymbolPosition}get hasNonBreakingSpace(){return this.nonBreakingSpace?this.nonBreakingSpace:this._hasNonBreakingSpace}};Nt([A],lh.prototype,"_hideDecimal",void 0),Nt([E],lh.prototype,"getCurrencySymbolPosition",null),Nt([E],lh.prototype,"hasNonBreakingSpace",null);const ch=re.partial`
font-family: ${Qt};
font-size: ${vi};
line-height: calc(${Ci} * 0.9);
font-weight: ${yi};
`,dh=re.partial`
font-family: ${Qt};
font-size: ${pi};
line-height: calc(${fi} * 0.7);
font-weight: ${gi};
`,uh=re.partial`
font-family: ${Qt};
font-size: ${Pi};
line-height: calc(${Ei} * 0.75);
font-weight: ${Ai};
`,hh=re.partial`
font-family: ${Qt};
font-size: ${Ti};
line-height: calc(${Oi} * 0.7);
font-weight: ${wi};
`,ph=re.partial`
font-family: ${Qt};
font-size: ${_i};
line-height: calc(${Ri} * 0.8);
font-weight: ${Ni};
`,gh=re.partial`
font-family: ${Qt};
font-size: ${ki};
line-height: calc(${Di} * 0.65);
font-weight: ${Ii};
`,fh=re.partial`
font-family: ${Qt};
`,mh=re.partial`
color: ${Bt};
`,vh=re.partial`
color: ${qt};
`,yh=re.partial`
color: ${Kt};
`,Ch=re.partial`
color: ${Ut};
`,bh=re.partial`
color: ${Ht};
`,Sh=re.partial`
color: ${$t};
`,xh=re`
/**
* Container styles
**/
:host {
${hh}
${mh}
}
:host .price-container {
display: flex;
flex-direction: row;
}
:host([strikethrough]) .currency {
text-decoration: line-through;
}
:host([strikethrough]) .integer {
text-decoration: line-through;
}
:host([strikethrough]) .cents {
text-decoration: line-through;
}
:host([strikethrough]) .decimal {
text-decoration: line-through;
}
:host .per-item-container {
display: flex;
flex-direction: row;
align-items: flex-end;
padding-left: ${oi};
column-gap: ${oi};
font-weight: ${ti};
${Ch}
}
:host .per-item-separator {
}
:host .per-item-label {
}
/**
* Container size styles
**/
:host([size="${zu}"]) .price-container {
${ch}
}
:host([size="${Wu}"]) .price-container {
${dh}
}
:host([size="${Ku}"]) .price-container {
${uh}
}
:host([size="${qu}"]) .price-container {
${hh}
}
:host([size="${Yu}"]) .price-container {
${ph}
}
:host([size="${Xu}"]) .price-container {
${gh}
}
/**
* Container color styles
**/
:host([color="${Ju}"]) .price-container {
${mh}
}
:host([color="${Qu}"]) .price-container {
${vh}
}
:host([color="${eh}"]) .price-container {
${yh}
}
:host([color="${th}"]) .price-container {
${Sh}
}
:host([color="${ih}"]) .price-container {
${Ch}
}
:host([color="${nh}"]) .price-container {
${bh}
}
:host([color="${oh}"]) .price-container {
color: inherit;
}
/**
* Raised currency and cents styles for all size
*/
:host([show-raised-cents]) .currency {
vertical-align: top;
margin-right: 0.1em;
font-size: ${"60%"};
line-height: ${"1.0"};
transform: translateY(${"10%"});
}
:host([show-raised-cents]) .cents {
vertical-align: top;
margin-left: 0.05em;
font-size: ${"60%"};
line-height: ${"1.0"};
transform: translateY(${"8%"});
}
/**
* Raised currency and cents custon line-height for medium size
*/
:host([show-raised-cents][size="${qu}"]) .cents {
}
:host([show-raised-cents][size="${qu}"]) .currency {
}
/**
* Discount styles
**/
.discount-label {
${fh}
margin-left: 0.2em;
}
/*
we dont support top position for small, x-small, xx-small sizes
*/
:host([discount-label-position="${"top"}"]:not([size="${Ku}"]):not([size="${Wu}"]):not([size="${zu}"]))
.discount-label {
vertical-align: top;
font-size: ${"60%"};
line-height: ${"1.0"};
transform: translateY(0.1em);
}
/*
Currently, the middle position is not supported by the component.
:host([discount-label-position="middle"]) .discount-label {
justify-content: center;
font-size: 60%;
} */
:host([discount-label-position="${rh}"]))
.discount-label {
margin-left: 0.2em;
font-size: 100%;
}
:host([discount-label-color="${Ju}"]) .discount-label {
${mh}
}
:host([discount-label-color="${Qu}"]) .discount-label {
${vh}
}
:host([discount-label-color="${eh}"]) .discount-label {
${yh}
}
:host([discount-label-color="${th}"]) .discount-label {
${Sh}
}
:host([discount-label-color="${ih}"]) .discount-label {
${Ch}
}
:host([discount-label-color="${nh}"]) .discount-label {
${bh}
}
:host([discount-label-color="${oh}"]) .discount-label {
color: inherit;
}
`,Th=Be`
<div class="price-container">
${Ze((e=>!e.hideCurrency&&e.getCurrencySymbolPosition==ah),Be`
<div class="currency">
${e=>e.getCurrencySymbol}${Ze((e=>e.hasNonBreakingSpace),Be` `)}
</div>
`)}
<div class="integer">${e=>e.getValueInteger}</div>
${Ze((e=>!e.getHideDecimal),Be` <div class="decimal">${e=>e.getDecimalSymbol}</div> `)}
${Ze((e=>!e.hideCents),Be` <div class="cents">${e=>e.getValueCents}</div> `)}
${Ze((e=>!e.hideCurrency&&"end"==e.getCurrencySymbolPosition),Be`
<div class="currency">
${Ze((e=>e.hasNonBreakingSpace),Be` `)}${e=>e.getCurrencySymbol}
</div>
`)}
${Ze((e=>e.showDiscountPercent),Be` <div>${e=>e.getPercentSymbol}</div> `)}
${Ze((e=>e.showDiscount),Be` <div class="discount-label">${e=>e.discountLabel}</div> `)}
${Ze((e=>void 0!==e.perItemLabel&&""!==e.perItemLabel),Be`
<div class="per-item-container">
${Ze((e=>void 0!==e.perItemSeparator),Be` <div class="per-item-separator">${e=>e.perItemSeparator}</div> `)}
<div class="per-item-label">${e=>e.perItemLabel}</div>
</div>
`)}
</div>
`;Be`<commerceui-price
value="${e=>e.value}"
show-discount="${e=>e.showDiscount}"
show-discount-percent="${e=>e.showDiscountPercent}"
discount-label-position="${e=>e.discountLabelPosition}"
percent-symbol="${e=>e.percentSymbol}"
per-item-separator="${e=>e.perItemSeparator}"
per-item-label="${e=>e.perItemLabel}"
show-raised-cents="${e=>e.showRaisedCents}"
show-zero-cents="${e=>e.showZeroCents}"
hide-cents="${e=>e.hideCents}"
hide-currency="${e=>e.hideCurrency}"
strikethrough="${e=>e.strikethrough}"
currency="${e=>e.currency}"
currency-symbol="${e=>e.currencySymbol}"
currency-symbol-position="${e=>e.currencySymbolPosition}"
non-breaking-space="${e=>e.nonBreakingSpace}"
locale="${e=>e.locale}"
color="${e=>e.color}"
size="${e=>e.size}"
discount-label="${e=>e.discountLabel}"
></commerceui-price>`,lh.compose({name:`${ju.prefix}-price`,template:Th,styles:xh}).define(ju.registry);const wh=Object.freeze({prefix:"commerceui",shadowRootMode:"open",registry:customElements}),Oh="regular",Ph="cashback",Ah="cashback",Eh="cashback-outline",kh="small",Ih="medium",Dh="large",_h="x-large",Nh="deal",Rh=Be`<svg
width="15"
height="15"
viewBox="0 0 15 15"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M9.34371 1.34221C8.82929 0.871203 8.03471 0.888446 7.54126 1.38132L1.38175 7.53355C0.872744 8.04195 0.87275 8.86623 1.38177 9.37463L2.24403 10.2358C2.56723 10.5587 3.0322 10.4809 3.30606 10.2986C3.46824 10.1906 3.66273 10.1277 3.87307 10.1277C4.43868 10.1277 4.89719 10.5857 4.89719 11.1506C4.89719 11.3607 4.83418 11.5549 4.72608 11.7169C4.54355 11.9904 4.46572 12.4548 4.78892 12.7776L5.63098 13.6187C6.15094 14.138 6.99783 14.1252 7.5018 13.5904L13.6457 7.07039C14.1437 6.54195 14.1129 5.70887 13.5773 5.2185L12.7521 4.46291C12.5482 4.27627 12.2903 4.24102 12.0757 4.27926C11.8643 4.31693 11.6639 4.42864 11.5193 4.58689C11.3315 4.79239 11.0623 4.92049 10.7626 4.92049C10.197 4.92049 9.7385 4.46253 9.7385 3.8976C9.7385 3.62992 9.84095 3.38698 10.0095 3.20443C10.155 3.04688 10.2491 2.83781 10.2683 2.62427C10.2879 2.40739 10.2302 2.1539 10.0265 1.96734L9.34371 1.34221Z"
fill="${$t}"
/>
</svg> `,Mh=Be`<svg
width="15"
height="15"
viewBox="0 0 15 15"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M2.99507 3.00001C1.89051 2.99729 0.997293 3.89052 1.00001 4.99507L1.01143 9.64502C1.01414 10.7496 1.91177 11.6472 3.01632 11.6499L9.60413 11.6661C10.1296 11.6674 10.6334 11.4619 11.0067 11.0939L13.4019 8.73317C14.193 7.95348 14.1918 6.67471 13.3993 5.88872L11.0912 3.59978C10.7157 3.2274 10.2091 3.01773 9.68153 3.01643L2.99507 3.00001Z"
fill="${$t}"
/>
</svg> `,Lh=Be`<svg
width="16"
height="12"
viewBox="0 0 16 12"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M2.45652 0.857918C1.09648 0.854474 -0.00333321 1.98825 7.59088e-06 3.39028L0.0140721 9.29253C0.0174134 10.6946 1.12265 11.8339 2.48268 11.8374L10.5942 11.8579C11.2412 11.8595 11.8615 11.5987 12.3211 11.1317L15.2704 8.1351C16.2445 7.14543 16.243 5.52227 15.2671 4.5246L12.4253 1.61922C11.9629 1.14655 11.3391 0.880412 10.6895 0.878767L2.45652 0.857918Z"
fill="${$t}"
/>
</svg> `,Bh=Be`
<svg width="16" height="12" viewBox="0 0 16 12" fill="none" xmlns="http://www.w3.org/2000/svg">
<path
d="M0.500006 3.38909C0.497291 2.24961 1.38665 1.35521 2.45525 1.35792L10.6882 1.37877C11.201 1.38006 11.6974 1.59009 12.0678 1.96884L12.4253 1.61922L12.0678 1.96884L14.9097 4.87423C15.6967 5.67877 15.6954 6.9905 14.9141 7.78437L11.9648 10.7809C11.5981 11.1535 11.1061 11.3592 10.5955 11.3579L2.48395 11.3374C1.41322 11.3347 0.51679 10.4325 0.514071 9.29134L0.500006 3.38909Z"
stroke="${$t}"
/>
</svg>
`,Fh=Be`<svg
width="13"
height="10"
viewBox="0 0 13 10"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M1.99507 0.857916C0.890514 0.855203 -0.00270708 1.74843 6.16497e-06 2.85298L0.0114288 7.50293C0.0141423 8.60749 0.911765 9.50511 2.01632 9.50782L8.60413 9.52401C9.12955 9.5253 9.63337 9.31977 10.0067 8.95185L12.4019 6.59108C13.193 5.81139 13.1918 4.53262 12.3993 3.74663L10.0912 1.45769C9.71575 1.08531 9.20907 0.875638 8.68153 0.874342L1.99507 0.857916Z"
fill="${$t}"
/>
</svg> `,Uh=Be`
<svg width="13" height="10" viewBox="0 0 13 10" fill="none" xmlns="http://www.w3.org/2000/svg">
<path
d="M0.500005 2.85175C0.497972 2.0243 1.16639 1.35588 1.99384 1.35791L8.68031 1.37434C9.07601 1.37531 9.45675 1.53264 9.73915 1.81271L12.0472 4.10165C12.6438 4.69328 12.6421 5.65234 12.051 6.23497L9.65569 8.59574C9.3765 8.8709 8.99937 9.02497 8.60536 9.02401L2.01755 9.00782C1.18818 9.00579 0.513465 8.33108 0.511427 7.5017L0.500005 2.85175Z"
stroke="${$t}"
/>
</svg>
`,Hh=Be`<svg viewBox="0 0 14 40" xmlns="http://www.w3.org/2000/svg">
<path
d="M4.53165 37.3908C3.65607 38.9991 1.97143 40 0.140313 40H2.98023e-07V-1.19209e-06H0.140313C1.97143 -1.19209e-06 3.65607 1.00095 4.53165 2.60916L12.6983 17.6092C13.5099 19.0998 13.5099 20.9002 12.6983 22.3908L4.53165 37.3908Z"
/>
</svg>`,$h=Be`<svg
width="15"
height="15"
viewBox="0 0 15 15"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M2.08402 2C1.48533 2 1 2.48123 1 3.07486V5.84011C1 7.96094 2.73392 9.68021 4.87281 9.68021C4.91764 9.68021 4.96229 9.67946 5.00675 9.67796C4.81737 9.14852 4.71429 8.57857 4.71429 7.98475C4.71429 7.48355 4.78772 6.99935 4.9245 6.54217L3.9217 5.54813C3.74036 5.36837 3.74032 5.07688 3.92161 4.89707C4.1029 4.71727 4.39687 4.71722 4.57821 4.89698L5.30535 5.61778C5.84885 4.60036 6.73181 3.78861 7.8046 3.33091C7.09443 2.51582 6.04437 2 4.87281 2H2.08402ZM6.55698 10.5714L4.90138 12.2142C4.72014 12.3941 4.72025 12.6856 4.90163 12.8653C5.08301 13.045 5.37698 13.0449 5.55823 12.865L7.21367 11.2223C7.92845 11.7891 8.83502 12.128 9.82143 12.128C12.1292 12.128 14 10.273 14 7.98475V4.97145C14 4.34737 13.4898 3.84146 12.8604 3.84146L9.82143 3.84146C7.51367 3.84146 5.64286 5.69647 5.64286 7.98475C5.64286 8.96324 5.98494 9.8625 6.55698 10.5714ZM10.1526 8.30607L7.87426 10.5651C7.62542 10.3802 7.4042 10.1607 7.21786 9.91388L9.49596 7.65502C9.67728 7.47523 9.97125 7.47523 10.1526 7.65502C10.3339 7.8348 10.3339 8.12629 10.1526 8.30607Z"
fill="${qt}"
/>
</svg> `,Zh=Be`<svg
width="15"
height="15"
viewBox="0 0 15 15"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M2.05479 8.20279L2.05373 8.20667C1.97678 8.50665 1.67997 8.68579 1.3907 8.60622C0.923291 8.4777 1.00558 7.91834 1.00558 7.91834L1.02474 7.84928C1.02474 7.84928 1.05304 7.75466 1.07584 7.68597C1.12141 7.54871 1.1911 7.35683 1.29017 7.1285C1.48777 6.67305 1.80537 6.06537 2.2872 5.45581C3.26044 4.22457 4.89653 3 7.49367 3C10.0908 3 11.7269 4.22457 12.7001 5.45581C13.182 6.06537 13.4996 6.67305 13.6972 7.1285C13.7962 7.35683 13.8659 7.54871 13.9115 7.68597C13.9343 7.75466 13.9511 7.80984 13.9626 7.84928C13.9683 7.869 13.9728 7.8848 13.9759 7.8964L13.9797 7.91062L13.981 7.9153L13.9814 7.91703L13.9818 7.91834C14.0585 8.21862 13.8861 8.5266 13.5966 8.60622C13.3076 8.68572 13.0113 8.5075 12.934 8.20805L12.9336 8.20667L12.9325 8.20279L12.9246 8.17466C12.9169 8.14818 12.9043 8.10668 12.8862 8.05232C12.8501 7.94349 12.7923 7.78381 12.7084 7.59026C12.5399 7.20196 12.2691 6.68464 11.8617 6.16919C11.0564 5.15043 9.71047 4.125 7.49367 4.125C5.27687 4.125 3.93095 5.15043 3.12567 6.16919C2.71824 6.68464 2.44745 7.20196 2.27898 7.59026C2.195 7.78381 2.13723 7.94349 2.1011 8.05232C2.08306 8.10668 2.07047 8.14818 2.06276 8.17466L2.05479 8.20279ZM4.78284 9.1875C4.78284 7.6342 5.99656 6.375 7.49376 6.375C8.99095 6.375 10.2047 7.6342 10.2047 9.1875C10.2047 10.7408 8.99095 12 7.49376 12C5.99656 12 4.78284 10.7408 4.78284 9.1875Z"
fill="${e=>e.getIconColor}"
/>
</svg> `,Vh=Be`<svg
width="15"
height="15"
viewBox="0 0 16 16"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M2 3.75C2 2.7835 2.7835 2 3.75 2H9.25016C10.2167 2 11.0002 2.7835 11.0002 3.75V4H11.382C11.9501 4 12.4695 4.321 12.7236 4.82918L13.8416 7.06525C13.9458 7.27353 14 7.5032 14 7.73607V11C14 11.8284 13.3284 12.5 12.5 12.5H11.937C11.715 13.3626 10.9319 14 10 14C9.06808 14 8.28503 13.3626 8.06301 12.5H6.93699C6.71497 13.3626 5.93192 14 5 14C4.01321 14 3.19333 13.2853 3.02971 12.3454C2.4225 12.0708 2 11.4597 2 10.75V3.75ZM8.06301 11.5C8.28503 10.6374 9.06808 10 10 10C9.99995 10 10.0001 10 10 10L10.0002 3.75C10.0002 3.33579 9.66438 3 9.25016 3H3.75C3.33579 3 3 3.33579 3 3.75V10.75C3 10.9251 3.05997 11.0861 3.16049 11.2137C3.46594 10.5 4.17458 10 5 10C5.93192 10 6.71497 10.6374 6.93699 11.5H8.06301ZM11.0002 10.2677C11.4585 10.5328 11.8018 10.9746 11.937 11.5H12.5C12.7761 11.5 13 11.2761 13 11V8H11.0002V10.2677ZM11.0002 7H12.691L11.8292 5.27639C11.7445 5.107 11.5714 5 11.382 5H11.0002V7ZM5 11C4.44772 11 4 11.4477 4 12C4 12.5523 4.44772 13 5 13C5.55228 13 6 12.5523 6 12C6 11.4477 5.55228 11 5 11ZM9 12C9 12.5523 9.44772 13 10 13C10.5523 13 11 12.5523 11 12C11 11.4477 10.5523 11 10 11C9.44772 11 9 11.4477 9 12Z"
fill="${Bt}"
/>
</svg>`,Gh="xx-small",jh="x-small",zh="small",Wh="medium",Kh="large",qh="x-large",Yh="neutral",Xh="accent-primary",Jh="accent-secondary",Qh="accent-brand",ep="subtle",tp="inverted",ip="inherit",np="bottom",op="start";class rp extends Pt{constructor(){super(...arguments),this.value=0,this.locale="en-US",this.currency="USD",this.currencySymbol="$",this.nonBreakingSpace=!1,this.currencySymbolPosition=op,this.percentSymbol="%",this.perItemLabel="",this.perItemSeparator="/",this.size=Wh,this.color=Yh,this.hideCurrency=!1,this.discountLabel="off",this.discountLabelPosition=np,this.hideCents=!1,this.showZeroCents=!1,this.showRaisedCents=!1,this.showDiscountPercent=!1,this.strikethrough=!1,this.showDiscount=!1}}Nt([st({attribute:"value",converter:rt})],rp.prototype,"value",void 0),Nt([st],rp.prototype,"locale",void 0),Nt([st],rp.prototype,"currency",void 0),Nt([st({attribute:"currency-symbol"})],rp.prototype,"currencySymbol",void 0),Nt([st({attribute:"non-breaking-space"})],rp.prototype,"nonBreakingSpace",void 0),Nt([st({attribute:"currency-symbol-position"})],rp.prototype,"currencySymbolPosition",void 0),Nt([st({attribute:"percent-symbol"})],rp.prototype,"percentSymbol",void 0),Nt([st({attribute:"per-item-label"})],rp.prototype,"perItemLabel",void 0),Nt([st({attribute:"per-item-separator"})],rp.prototype,"perItemSeparator",void 0),Nt([st],rp.prototype,"size",void 0),Nt([st],rp.prototype,"color",void 0),Nt([st({attribute:"hide-currency",mode:"boolean"})],rp.prototype,"hideCurrency",void 0),Nt([st({attribute:"discount-label"})],rp.prototype,"discountLabel",void 0),Nt([st({attribute:"discount-label-position"})],rp.prototype,"discountLabelPosition",void 0),Nt([st({attribute:"hide-cents",mode:"boolean"})],rp.prototype,"hideCents",void 0),Nt([st({attribute:"show-zero-cents",mode:"boolean"})],rp.prototype,"showZeroCents",void 0),Nt([st({attribute:"show-raised-cents",mode:"boolean"})],rp.prototype,"showRaisedCents",void 0),Nt([st({attribute:"show-discount-percent",mode:"boolean"})],rp.prototype,"showDiscountPercent",void 0),Nt([st({mode:"boolean"})],rp.prototype,"strikethrough",void 0),Nt([st({mode:"boolean",attribute:"show-discount"})],rp.prototype,"showDiscount",void 0);class ap extends rp{constructor(){super(...arguments),this._hideDecimal=!1,this._currencySymbol=this.currencySymbol,this._currencySymbolPosition=op,this._hasNonBreakingSpace=!1,this._discountLabel=this.discountLabel,this._percentSymbol="%"}valueChanged(){this.updateLocalizedValues()}localeChanged(){this.updateLocalizedValues()}currencyChanged(){this.updateLocalizedValues()}updateLocalizedValues(){const e=this.value,t=this.currency||"USD",i=((e,t,i)=>{var n,o,r,a;const s={},l={style:"currency",currency:i,currencyDisplay:"symbol"},c=Intl.NumberFormat(t,l).formatToParts(e);let d="";return c.forEach((e=>{"integer"!==e.type&&"group"!==e.type||(d=d.concat(e.value))})),s.currencySymbol=null===(n=c.find((e=>"currency"===e.type)))||void 0===n?void 0:n.value,s.valueInteger=d,s.decimalSymbol=(null===(o=c.find((e=>"decimal"===e.type)))||void 0===o?void 0:o.value)||".",s.valueCents=(null===(r=c.find((e=>"fraction"===e.type)))||void 0===r?void 0:r.value)||"00",s.currencySymbolPosition="currency"==(null===(a=c[0])||void 0===a?void 0:a.type)?op:"end",s.hasNonBreakingSpace=null!=c.find((e=>"literal"===e.type&&" "===e.value)),s})(e,this.locale||void 0,t);this._currencySymbol=i.currencySymbol,this._valueInteger=i.valueInteger,this._decimalSymbol=i.decimalSymbol,this._valueCents=i.valueCents,this._currencySymbolPosition=i.currencySymbolPosition,this._hasNonBreakingSpace=i.hasNonBreakingSpace}connectedCallback(){super.connectedCallback(),"00"!==this._valueCents||!1!==this.showZeroCents&&void 0!==this.showZeroCents||(this.hideCents=!0),!this.showRaisedCents||this.size!==zh&&this.size!==jh&&this.size!==Gh||(this.showRaisedCents=!1,this._hideDecimal=!1),this.showDiscount&&(this.showRaisedCents=!1),!0===this.showDiscount&&!0===this.showDiscountPercent&&(this.hideCurrency=!0,this.hideCents=!0),!0!==this.hideCents&&!0!==this.showRaisedCents||(this._hideDecimal=!0)}get getDiscountLabel(){return this._discountLabel}get getCurrencySymbol(){return this._currencySymbol}get getPercentSymbol(){return this._percentSymbol}get getDecimalSymbol(){return this._decimalSymbol}get getValueInteger(){return this._valueInteger}get getValueCents(){return this._valueCents}get getHideDecimal(){return this._hideDecimal}get getCurrencySymbolPosition(){return this.currencySymbolPosition?this.currencySymbolPosition:this._currencySymbolPosition}get hasNonBreakingSpace(){return this.nonBreakingSpace?this.nonBreakingSpace:this._hasNonBreakingSpace}}Nt([A],ap.prototype,"_hideDecimal",void 0),Nt([E],ap.prototype,"getCurrencySymbolPosition",null),Nt([E],ap.prototype,"hasNonBreakingSpace",null);const sp=Be`
<div class="price-container">
${Ze((e=>!e.hideCurrency&&e.getCurrencySymbolPosition==op),Be`
<div class="currency">
${e=>e.getCurrencySymbol}${Ze((e=>e.hasNonBreakingSpace),Be` `)}
</div>
`)}
<div class="integer">${e=>e.getValueInteger}</div>
${Ze((e=>!e.getHideDecimal),Be` <div class="decimal">${e=>e.getDecimalSymbol}</div> `)}
${Ze((e=>!e.hideCents),Be` <div class="cents">${e=>e.getValueCents}</div> `)}
${Ze((e=>!e.hideCurrency&&"end"==e.getCurrencySymbolPosition),Be`
<div class="currency">
${Ze((e=>e.hasNonBreakingSpace),Be` `)}${e=>e.getCurrencySymbol}
</div>
`)}
${Ze((e=>e.showDiscountPercent),Be` <div>${e=>e.getPercentSymbol}</div> `)}
${Ze((e=>e.showDiscount),Be` <div class="discount-label">${e=>e.discountLabel}</div> `)}
${Ze((e=>void 0!==e.perItemLabel&&""!==e.perItemLabel),Be`
<div class="per-item-container">
${Ze((e=>void 0!==e.perItemSeparator),Be` <div class="per-item-separator">${e=>e.perItemSeparator}</div> `)}
<div class="per-item-label">${e=>e.perItemLabel}</div>
</div>
`)}
</div>
`;Be`<commerceui-price
value="${e=>e.value}"
show-discount="${e=>e.showDiscount}"
show-discount-percent="${e=>e.showDiscountPercent}"
discount-label-position="${e=>e.discountLabelPosition}"
percent-symbol="${e=>e.percentSymbol}"
per-item-separator="${e=>e.perItemSeparator}"
per-item-label="${e=>e.perItemLabel}"
show-raised-cents="${e=>e.showRaisedCents}"
show-zero-cents="${e=>e.showZeroCents}"
hide-cents="${e=>e.hideCents}"
hide-currency="${e=>e.hideCurrency}"
strikethrough="${e=>e.strikethrough}"
currency="${e=>e.currency}"
currency-symbol="${e=>e.currencySymbol}"
currency-symbol-position="${e=>e.currencySymbolPosition}"
non-breaking-space="${e=>e.nonBreakingSpace}"
locale="${e=>e.locale}"
color="${e=>e.color}"
size="${e=>e.size}"
discount-label="${e=>e.discountLabel}"
></commerceui-price>`;const lp=re.partial`
font-family: ${Qt};
font-size: ${vi};
line-height: calc(${Ci} * 0.9);
font-weight: ${yi};
`,cp=re.partial`
font-family: ${Qt};
font-size: ${pi};
line-height: calc(${fi} * 0.7);
font-weight: ${gi};
`,dp=re.partial`
font-family: ${Qt};
font-size: ${Pi};
line-height: calc(${Ei} * 0.75);
font-weight: ${Ai};
`,up=re.partial`
font-family: ${Qt};
font-size: ${Ti};
line-height: calc(${Oi} * 0.7);
font-weight: ${wi};
`,hp=re.partial`
font-family: ${Qt};
font-size: ${_i};
line-height: calc(${Ri} * 0.8);
font-weight: ${Ni};
`,pp=re.partial`
font-family: ${Qt};
font-size: ${ki};
line-height: calc(${Di} * 0.65);
font-weight: ${Ii};
`,gp=re.partial`
font-family: ${Qt};
`,fp=re.partial`
color: ${Bt};
`,mp=re.partial`
color: ${qt};
`,vp=re.partial`
color: ${Kt};
`,yp=re.partial`
color: ${Ut};
`,Cp=re.partial`
color: ${Ht};
`,bp=re.partial`
color: ${$t};
`,Sp=re`
/**
* Container styles
**/
:host {
${up}
${fp}
}
:host .price-container {
display: flex;
flex-direction: row;
}
:host([strikethrough]) .currency {
text-decoration: line-through;
}
:host([strikethrough]) .integer {
text-decoration: line-through;
}
:host([strikethrough]) .cents {
text-decoration: line-through;
}
:host([strikethrough]) .decimal {
text-decoration: line-through;
}
:host .per-item-container {
display: flex;
flex-direction: row;
align-items: flex-end;
padding-left: ${oi};
column-gap: ${oi};
font-weight: ${ti};
${yp}
}
:host .per-item-separator {
}
:host .per-item-label {
}
/**
* Container size styles
**/
:host([size="${Gh}"]) .price-container {
${lp}
}
:host([size="${jh}"]) .price-container {
${cp}
}
:host([size="${zh}"]) .price-container {
${dp}
}
:host([size="${Wh}"]) .price-container {
${up}
}
:host([size="${Kh}"]) .price-container {
${hp}
}
:host([size="${qh}"]) .price-container {
${pp}
}
/**
* Container color styles
**/
:host([color="${Yh}"]) .price-container {
${fp}
}
:host([color="${Xh}"]) .price-container {
${mp}
}
:host([color="${Jh}"]) .price-container {
${vp}
}
:host([color="${Qh}"]) .price-container {
${bp}
}
:host([color="${ep}"]) .price-container {
${yp}
}
:host([color="${tp}"]) .price-container {
${Cp}
}
:host([color="${ip}"]) .price-container {
color: inherit;
}
/**
* Raised currency and cents styles for all size
*/
:host([show-raised-cents]) .currency {
vertical-align: top;
margin-right: 0.1em;
font-size: ${"60%"};
line-height: ${"1.0"};
transform: translateY(${"10%"});
}
:host([show-raised-cents]) .cents {
vertical-align: top;
margin-left: 0.05em;
font-size: ${"60%"};
line-height: ${"1.0"};
transform: translateY(${"8%"});
}
/**
* Raised currency and cents custon line-height for medium size
*/
:host([show-raised-cents][size="${Wh}"]) .cents {
}
:host([show-raised-cents][size="${Wh}"]) .currency {
}
/**
* Discount styles
**/
.discount-label {
${gp}
margin-left: 0.2em;
}
/*
we dont support top position for small, x-small, xx-small sizes
*/
:host([discount-label-position="${"top"}"]:not([size="${zh}"]):not([size="${jh}"]):not([size="${Gh}"]))
.discount-label {
vertical-align: top;
font-size: ${"60%"};
line-height: ${"1.0"};
transform: translateY(0.1em);
}
/*
Currently, the middle position is not supported by the component.
:host([discount-label-position="middle"]) .discount-label {
justify-content: center;
font-size: 60%;
} */
:host([discount-label-position="${np}"]))
.discount-label {
margin-left: 0.2em;
font-size: 100%;
}
:host([discount-label-color="${Yh}"]) .discount-label {
${fp}
}
:host([discount-label-color="${Xh}"]) .discount-label {
${mp}
}
:host([discount-label-color="${Jh}"]) .discount-label {
${vp}
}
:host([discount-label-color="${Qh}"]) .discount-label {
${bp}
}
:host([discount-label-color="${ep}"]) .discount-label {
${yp}
}
:host([discount-label-color="${tp}"]) .discount-label {
${Cp}
}
:host([discount-label-color="${ip}"]) .discount-label {
color: inherit;
}
`;ap.compose({name:`${wh.prefix}-price`,template:sp,styles:Sp});class xp extends Pt{constructor(){super(...arguments),this.type=Oh,this.size=Ih,this.color="informative",this.appearance="filled"}connectedCallback(){super.connectedCallback(),this.configSlottedPriceComponent()}typeChanged(){this.type===Ph&&(this.color="brand",this.appearance="ghost")}get getIconColor(){let e;return e="important"===this.color?"var(--colorNeutralForegroundInverted2)":Bt,e}get getSize(){return this.size===kh?this.type!==Ph||this.icon!==Ah&&this.icon!==Eh?(this.size=Ih,"medium"):"small":this.size===Ih?"medium":this.size===Dh?"large":this.size===_h?"extra-large":void 0}get getIcon(){return this.type===Ph?this.getCashbackIcon():this.getRegularIcon()}getRegularIcon(){switch(this.icon){case"coupon":return Rh;case Ah:return Mh;case"ethical-choice":return $h;case"views":return Zh;case"truck":return Vh;default:return void(this.icon=void 0)}}getCashbackIcon(){switch(this.icon){case Ah:return"small"===this.getSize?Fh:(this.size=Ih,Lh);case Eh:return"small"===this.getSize?Uh:(this.size=Ih,Bh)}}configSlottedPriceComponent(){const e=this.querySelector("commerceui-price");if(e)switch(e.color=tp,this.size){case Ih:e.size=jh;break;case Dh:e.size=Wh;break;case _h:e.size=Kh}}}Nt([st],xp.prototype,"type",void 0),Nt([st],xp.prototype,"icon",void 0),Nt([st],xp.prototype,"size",void 0),Nt([st],xp.prototype,"color",void 0),Nt([st],xp.prototype,"appearance",void 0);const Tp=re`
/**
* Container styles
**/
:host([icon]) fluent-beta-badge {
padding-inline-start: ${oi};
}
.icon {
display: flex;
align-items: center;
justify-content: center;
width: 20px;
height: 20px;
margin-inline-end: ${oi};
}
/**
/ Make sure the badge is always inline with the text and not wrapping
*/
:host fluent-beta-badge {
width: max-content;
}
/*
* We need to override the badge styles for the following colors
*/
:host([color="${"success"}"]) fluent-beta-badge {
border: transparent;
}
/*
* Deal is the custom style
* we need to hide default border and background
*/
:host([color="${Nh}"]) fluent-beta-badge:after {
border: transparent;
background: transparent;
}
/* Deal media query to show custom style for light and dark */
@media (prefers-color-scheme: dark) {
:host([color="${Nh}"]) fluent-beta-badge {
color: #fff;
outline: 1px solid rgba(214, 222, 255, 0.2);
outline-offset: -1px;
background: var(
--dark-deal-days-gradient,
linear-gradient(90deg, #050f8d -0.77%, #0077d4 100%)
);
}
}
@media (prefers-color-scheme: light) {
:host([color="${Nh}"]) fluent-beta-badge {
color: #264587;
border: 1px solid #d6deff;
background: var(
--light-deal-days-gradient,
linear-gradient(139deg, rgba(239, 250, 255, 0.5) 5.76%, rgba(214, 222, 255, 0.5) 100%),
#fff
);
}
}
/* Cashback badge type */
:host([type=${Ph}]:not([icon])) {
position: relative;
display: inline-flex;
width: fit-content;
height: fit-content;
}
:host([type=${Ph}]:not([icon])) fluent-beta-badge {
height: fit-content;
max-height: 40px;
contain: layout style;
padding-block: ${ci};
padding-inline-end: ${ri};
color: ${"var(--colorNeutralForegroundInverted)"};
background-color: ${Gt};
border-radius: ${Xt};
border-start-end-radius: 0;
border-end-end-radius: 0;
}
:host([type=${Ph}]:not([icon])) fluent-beta-badge + div {
position: absolute;
height: 100%;
inset-block-start: 0;
inset-inline-end: 0;
text-align: initial;
}
:host([type=${Ph}][size=${Ih}]:not([icon])) fluent-beta-badge + div {
width: 7px;
}
:host([type=${Ph}][size=${Dh}]:not([icon])) fluent-beta-badge + div {
width: 11px;
}
:host([type=${Ph}][size=${_h}]:not([icon])) fluent-beta-badge + div {
width: 14px;
}
:host([type=${Ph}]:not([icon])) fluent-beta-badge + div svg {
height: 100%;
fill: ${Gt};
}
:host([type=${Ph}][size=${Ih}]:not([icon])) fluent-beta-badge {
min-height: 20px;
padding-block: ${li};
margin-inline-end: 7px;
}
:host([type=${Ph}][size=${Dh}]:not([icon])) fluent-beta-badge {
min-height: 32px;
margin-inline-end: 11px;
}
:host([type=${Ph}][size=${_h}]:not([icon])) fluent-beta-badge {
min-height: 40px;
margin-inline-end: 14px;
}
:host([type=${Ph}][icon]) fluent-beta-badge {
padding-inline: 0;
}
:host([type=${Ph}]) .icon {
margin-inline-end: 0;
}
:host([type=${Ph}][icon=${Ah}][size=${kh}]) fluent-beta-badge,
:host([type=${Ph}][icon=${Eh}][size=${kh}]) fluent-beta-badge {
min-width: 16px;
height: 16px;
}
:host([type=${Ph}][icon=${Ah}][size=${kh}]) .icon,
:host([type=${Ph}][icon=${Eh}][size=${kh}]) .icon {
width: 16px;
height: 16px;
}
`;lo.name="fluent-beta-badge",lo.define(customElements);const wp=Be`<template
><fluent-beta-badge
shape="rounded"
icon-position="start"
color=${e=>e.color}
size=${e=>e.getSize}
appearance=${e=>e.appearance}
>${Ze((e=>void 0!==e.icon),Be`<div class="icon" slot="start">${e=>e.getIcon}</div>`)}
${Ze((e=>e.type===Oh||e.type===Ph&&void 0===e.icon),Be`<slot></slot>`)}
</fluent-beta-badge>
${Ze((e=>e.type===Ph&&void 0===e.icon),Be`<div>${Hh}</div>`)}
</template>`;Be`<commerceui-badge
type=${e=>e.type}
color=${e=>e.color}
icon=${e=>e.icon}
size=${e=>e.size}
appearance=${e=>e.appearance}
>${e=>e.content}</commerceui-badge
>`,xp.compose({name:`${wh.prefix}-badge`,template:wp,styles:Tp}).define(wh.registry);var Op=Object.defineProperty,Pp=Object.getOwnPropertyDescriptor,Ap=(e,t,i,n)=>{for(var o,r=n>1?void 0:n?Pp(t,i):t,a=e.length-1;a>=0;a--)(o=e[a])&&(r=(n?o(t,i,r):o(r))||r);return n&&r&&Op(t,i,r),r};class Ep extends Pt{constructor(){super(...arguments),this.advertisement=!1,this.metadata=[],this.hideLogo=!1}}Ap([st],Ep.prototype,"name",2),Ap([st({attribute:"img-url"})],Ep.prototype,"imgUrl",2),Ap([st({attribute:"img-alt"})],Ep.prototype,"imgAlt",2),Ap([st({mode:"boolean"})],Ep.prototype,"advertisement",2),Ap([st],Ep.prototype,"description",2),Ap([st({attribute:"metadata"})],Ep.prototype,"metadata",2),Ap([st({attribute:"hide-logo",mode:"boolean"})],Ep.prototype,"hideLogo",2);const kp="16px",Ip=re`
:host .container {
display: grid;
grid-auto-rows: max-content;
grid-template-columns: 20px auto;
grid-column-gap: ${ai};
align-items: flex-start;
font-family: ${Qt};
}
:host([hide-logo]) .container {
display: flex;
flex-direction: column;
align-items: flex-start;
}
:host .logo {
grid-area: 1 / 1 / 2 / 2;
margin-block-start: ${ci};
width: ${kp};
height: ${kp};
border-radius: ${Yt};
border: 0.5px solid ${Wt};
}
:host .logo-fallback {
grid-area: 1 / 1 / 2 / 2;
display: flex;
align-items: center;
justify-content: center;
margin-block-start: ${ci};
width: ${kp};
height: ${kp};
border-radius: ${Yt};
border: 1px solid ${Wt};
background-color: ${Zt};
color: ${Bt};
font-size: ${bi};
line-height: ${xi};
font-weight: ${Si};
}
:host .name-container {
grid-area: 1 / 2 / 2 / 3;
display: flex;
align-items: flex-start;
}
:host .name {
margin: 0;
margin-inline-end: ${ai};
color: ${Bt};
font-size: ${Pi};
line-height: ${Ei};
font-weight: ${Ai};
/* limit the name to 2 lines */
display: -webkit-box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
overflow: hidden;
}
:host fluent-beta-badge {
flex: 0 0 auto;
padding-inline: ${"var(--spacingHorizontalSNudge)"};
margin-block-start: ${ci};
}
:host .description {
grid-area: 2 / 2 / 3 / 3;
margin: 0;
margin-block-start: ${li};
color: ${Ft};
font-size: ${vi};
line-height: ${Ci};
font-weight: ${yi};
/* limit the description to 3 lines */
display: -webkit-box;
-webkit-line-clamp: 3;
-webkit-box-orient: vertical;
overflow: hidden;
}
:host .metadata-items {
grid-area: 3 / 2 / 4 / 3;
margin-block-start: ${li};
}
`,Dp={cashback:"cashback",coupon:"coupon",shipping:"shipping"},_p={filled:"filled",outline:"outline"},Np=Be`<svg
width="17"
height="17"
viewBox="0 0 17 17"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M4.49507 4.35792C3.39051 4.3552 2.49729 5.24843 2.50001 6.35298L2.51143 11.0029C2.51414 12.1075 3.41176 13.0051 4.51632 13.0078L11.1041 13.024C11.6296 13.0253 12.1334 12.8198 12.5067 12.4518L14.9019 10.0911C15.693 9.31139 15.6918 8.03262 14.8993 7.24663L12.5912 4.95769C12.2157 4.58531 11.7091 4.37564 11.1815 4.37434L4.49507 4.35792Z"
fill="${$t}"
/>
</svg> `,Rp=Be`<svg
width="17"
height="17"
viewBox="0 0 17 17"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M3 6.35175C2.99797 5.5243 3.66639 4.85588 4.49384 4.85791L11.1803 4.87434C11.576 4.87531 11.9568 5.03264 12.2392 5.31271L14.5472 7.60165C15.1438 8.19328 15.1421 9.15234 14.551 9.73497L12.1557 12.0957C11.8765 12.3709 11.4994 12.525 11.1054 12.524L4.51755 12.5078C3.68818 12.5058 3.01346 11.8311 3.01143 11.0017L3 6.35175Z"
stroke="${Ft}"
/>
</svg> `,Mp=Be`<svg
width="16"
height="16"
viewBox="0 0 16 16"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M9.97753 1.35238C9.42499 0.845867 8.57155 0.86441 8.04153 1.39444L1.42566 8.01051C0.878941 8.55725 0.878947 9.44367 1.42568 9.9904L2.35182 10.9165C2.69897 11.2637 3.19839 11.1801 3.49254 10.984C3.66674 10.8679 3.87564 10.8002 4.10156 10.8002C4.70908 10.8002 5.20156 11.2927 5.20156 11.9002C5.20156 12.1262 5.13388 12.3351 5.01778 12.5093C4.82172 12.8034 4.73812 13.3028 5.08526 13.65L5.98972 14.5544C6.5482 15.1129 7.45784 15.0991 7.99915 14.524L14.5983 7.51243C15.1331 6.94415 15.1001 6.04827 14.5248 5.52093L13.6384 4.70837C13.4195 4.50765 13.1424 4.46974 12.9119 4.51087C12.6849 4.55138 12.4696 4.67151 12.3143 4.84169C12.1126 5.06269 11.8235 5.20044 11.5016 5.20044C10.894 5.20044 10.4016 4.70795 10.4016 4.10044C10.4016 3.81258 10.5116 3.55132 10.6927 3.355C10.8489 3.18557 10.95 2.96074 10.9706 2.7311C10.9916 2.49787 10.9297 2.22527 10.7109 2.02465L9.97753 1.35238Z"
fill="${$t}"
/>
</svg>`,Lp=Be`<svg
width="16"
height="16"
viewBox="0 0 16 16"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M9.43694 1.94209C9.20014 1.72502 8.83437 1.73296 8.60722 1.96012L1.99135 8.57619C1.75705 8.8105 1.75705 9.1904 1.99136 9.42471L2.91725 10.3506C2.91691 10.3505 2.91743 10.3507 2.91725 10.3506C2.91959 10.3515 2.92772 10.354 2.9412 10.354C2.97076 10.354 3.0118 10.343 3.04884 10.3183C3.35036 10.1174 3.71289 10.0002 4.10156 10.0002C5.1509 10.0002 6.00156 10.8509 6.00156 11.9002C6.00156 12.2889 5.88443 12.6514 5.68346 12.953C5.65877 12.99 5.64785 13.031 5.64782 13.0606C5.6478 13.0741 5.65001 13.0814 5.6509 13.0838C5.65081 13.0836 5.65102 13.0841 5.6509 13.0838L6.55541 13.9888C6.79476 14.2281 7.1846 14.2222 7.41659 13.9757L14.0157 6.96414C14.2449 6.72059 14.2308 6.33664 13.9842 6.11064L13.098 5.29821C13.0975 5.29804 13.0967 5.29776 13.0954 5.29745C13.0898 5.29613 13.0756 5.29429 13.0524 5.29844C13.0017 5.30748 12.9439 5.33864 12.9052 5.38101C12.5583 5.76108 12.0576 6.00044 11.5016 6.00044C10.4522 6.00044 9.60156 5.14978 9.60156 4.10044C9.60156 3.60381 9.79263 3.15091 10.1045 2.81266C10.1433 2.77062 10.1693 2.71048 10.1739 2.65942C10.176 2.63603 10.1729 2.62216 10.1711 2.61676C10.1707 2.61548 10.1704 2.61467 10.1701 2.61423L9.43694 1.94209ZM8.04153 1.39444C8.57155 0.86441 9.42499 0.845867 9.97753 1.35238L10.7109 2.02465C10.9297 2.22527 10.9916 2.49787 10.9706 2.7311C10.95 2.96074 10.8489 3.18557 10.6927 3.355C10.5116 3.55132 10.4016 3.81258 10.4016 4.10044C10.4016 4.70795 10.894 5.20044 11.5016 5.20044C11.8235 5.20044 12.1126 5.06269 12.3143 4.84169C12.4696 4.67151 12.6849 4.55138 12.9119 4.51087C13.1424 4.46974 13.4195 4.50765 13.6384 4.70837L14.5248 5.52093C15.1001 6.04827 15.1331 6.94415 14.5983 7.51243L7.99915 14.524C7.45784 15.0991 6.5482 15.1129 5.98972 14.5544L5.08526 13.65C4.73812 13.3028 4.82172 12.8034 5.01778 12.5093C5.13388 12.3351 5.20156 12.1262 5.20156 11.9002C5.20156 11.2927 4.70908 10.8002 4.10156 10.8002C3.87564 10.8002 3.66674 10.8679 3.49254 10.984C3.19839 11.1801 2.69897 11.2637 2.35182 10.9165L1.42568 9.9904C0.878947 9.44367 0.878941 8.55725 1.42566 8.01051L8.04153 1.39444Z"
fill="${Ft}"
/>
</svg>`,Bp=Be`<svg
width="16"
height="16"
viewBox="0 0 16 16"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M2 3.75C2 2.7835 2.7835 2 3.75 2H9.25016C10.2167 2 11.0002 2.7835 11.0002 3.75V4H11.382C11.9501 4 12.4695 4.321 12.7236 4.82918L13.8416 7.06525C13.9458 7.27353 14 7.5032 14 7.73607V11C14 11.8284 13.3284 12.5 12.5 12.5H11.937C11.715 13.3626 10.9319 14 10 14C9.06808 14 8.28503 13.3626 8.06301 12.5H6.93699C6.71497 13.3626 5.93192 14 5 14C4.01321 14 3.19333 13.2853 3.02971 12.3454C2.4225 12.0708 2 11.4597 2 10.75V3.75ZM11.0002 5V7H12.691L11.8292 5.27639C11.7445 5.107 11.5714 5 11.382 5H11.0002ZM5 11C4.44772 11 4 11.4477 4 12C4 12.5523 4.44772 13 5 13C5.55228 13 6 12.5523 6 12C6 11.4477 5.55228 11 5 11ZM9 12C9 12.5523 9.44772 13 10 13C10.5523 13 11 12.5523 11 12C11 11.4477 10.5523 11 10 11C9.44772 11 9 11.4477 9 12Z"
fill="${$t}"
/>
</svg>`,Fp=Be`<svg
width="16"
height="16"
viewBox="0 0 16 16"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M2 3.75C2 2.7835 2.7835 2 3.75 2H9.25016C10.2167 2 11.0002 2.7835 11.0002 3.75V4H11.382C11.9501 4 12.4695 4.321 12.7236 4.82918L13.8416 7.06525C13.9458 7.27353 14 7.5032 14 7.73607V11C14 11.8284 13.3284 12.5 12.5 12.5H11.937C11.715 13.3626 10.9319 14 10 14C9.06808 14 8.28503 13.3626 8.06301 12.5H6.93699C6.71497 13.3626 5.93192 14 5 14C4.01321 14 3.19333 13.2853 3.02971 12.3454C2.4225 12.0708 2 11.4597 2 10.75V3.75ZM8.06301 11.5C8.28503 10.6374 9.06808 10 10 10C9.99995 10 10.0001 10 10 10L10.0002 3.75C10.0002 3.33579 9.66438 3 9.25016 3H3.75C3.33579 3 3 3.33579 3 3.75V10.75C3 10.9251 3.05997 11.0861 3.16049 11.2137C3.46594 10.5 4.17458 10 5 10C5.93192 10 6.71497 10.6374 6.93699 11.5H8.06301ZM11.0002 10.2677C11.4585 10.5328 11.8018 10.9746 11.937 11.5H12.5C12.7761 11.5 13 11.2761 13 11V8H11.0002V10.2677ZM11.0002 7H12.691L11.8292 5.27639C11.7445 5.107 11.5714 5 11.382 5H11.0002V7ZM5 11C4.44772 11 4 11.4477 4 12C4 12.5523 4.44772 13 5 13C5.55228 13 6 12.5523 6 12C6 11.4477 5.55228 11 5 11ZM9 12C9 12.5523 9.44772 13 10 13C10.5523 13 11 12.5523 11 12C11 11.4477 10.5523 11 10 11C9.44772 11 9 11.4477 9 12Z"
fill="${Ft}"
/>
</svg> `;var Up=Object.defineProperty,Hp=Object.getOwnPropertyDescriptor,$p=(e,t,i,n)=>{for(var o,r=n>1?void 0:n?Hp(t,i):t,a=e.length-1;a>=0;a--)(o=e[a])&&(r=(n?o(t,i,r):o(r))||r);return n&&r&&Up(t,i,r),r};class Zp extends Pt{constructor(){super(...arguments),this.iconAppearance=_p.outline}getIcon(){switch(this.icon){case Dp.cashback:return"filled"===this.iconAppearance?Np:Rp;case Dp.coupon:return"filled"===this.iconAppearance?Mp:Lp;case Dp.shipping:return"filled"===this.iconAppearance?Bp:Fp}}}$p([st],Zp.prototype,"label",2),$p([st],Zp.prototype,"icon",2),$p([st({attribute:"icon-appearance"})],Zp.prototype,"iconAppearance",2);const Vp=re`
:host {
display: grid;
grid-auto-columns: max-content;
grid-gap: ${ri};
grid-auto-flow: column;
align-items: center;
margin-block: ${li};
font-family: ${Qt};
}
.icon {
display: flex;
align-items: center;
width: 16px;
height: 16px;
}
.label {
color: ${Ft};
font-size: ${vi};
line-height: ${Ci};
font-weight: ${yi};
}
`,Gp=Be`
<template>
<div class="icon">${e=>e.getIcon()}</div>
<div class="label">${e=>e.label}</div>
</template>
`;Be`<commerceui-metadata-item
label=${e=>e.label}
icon=${e=>e.icon}
icon-appearance=${e=>e.iconAppearance}
></commerceui-metadata-item>`;const jp=Zp.compose({name:`${Mu.prefix}-metadata-item`,template:Gp,styles:Vp});jp.define(Mu.registry),lo.name="fluent-beta-badge",lo.define(customElements);const zp=Be`
<div id="retailer-item-container" class="container">
${Ze((e=>!e.hideLogo),Be`${Ze((e=>e.imgUrl&&""!==e.imgUrl),Be` <img class="logo" src=${e=>e.imgUrl} alt=${e=>e.imgAlt} />`,Be` <div class="logo-fallback">${e=>e.name.substring(0,1)}</div>`)}`)}
<div class="name-container">
<p class="name">${e=>e.name}</p>
${Ze((e=>e.advertisement),Be`<fluent-beta-badge shape="rounded" color="informative" size="small"
>Ad</fluent-beta-badge
>`)}
</div>
${Ze((e=>e.description),Be`<p class="description" title=${e=>e.description}>${e=>e.description}</p>`)}
<div class="metadata-items">
${We((e=>e.metadata),Be`${(e,t)=>{return Be`<commerceui-metadata-item
label=${(i=e).label}
icon=${i.icon}
icon-appearance=${i.iconAppearance}
></commerceui-metadata-item>`;var i}}`)}
</div>
</div>
`;Be`<commerceui-retailer-item
name=${e=>e.name}
img-url=${e=>e.imgUrl}
img-alt=${e=>e.imgAlt}
hide-logo=${e=>e.hideLogo}
description=${e=>e.description}
:metadata=${e=>e.metadata}
?advertisement=${e=>e.advertisement}
></commerceui-retailer-item>`;const Wp=Ep.compose({name:`${Mu.prefix}-retailer-item`,template:zp,styles:Ip});Wp.define(Mu.registry),So.name="fluent-beta-button",So.define(customElements);Be`<commerceui-buying-options-retailer-list
locale=${e=>e.locale}
currency=${e=>e.currency}
layout=${e=>e.layout}
hide-retailers-logo=${e=>e.hideRetailersLogo}
no-data-label=${e=>e.noDataLabel}
lowest-price-label=${e=>e.lowestPriceLabel}
cta-button-label=${e=>e.ctaButtonLabel}
discount-price-label=${e=>e.discountPriceLabel}
appearance=${e=>e.appearance}
:data=${e=>e.data}
:onretailerhover=${e=>e.onretailerhover}
:onretailerclick=${e=>e.onretailerclick}
:onretailerctaclick=${e=>e.onretailerctaclick}
>${e=>e.content}</commerceui-buying-options-retailer-list
>`;const Kp=Be`<div class="container">
${Ze((e=>e.getData.retailers.length>0),Be`<ul class="retailer-list appearance-${e=>e.appearance}">
${We((e=>e.getData.retailers),Be`
<li
class="retailer-list-item"
@mouseenter="${(e,t)=>t.parent.mouseEventHandler(t.index,t.event)}"
>
<a
href=${(e,t)=>t.parent.getRetailerData(t.index).item?.url}
target=${(e,t)=>t.parent.getRetailerData(t.index).item?.target}
title=${(e,t)=>t.parent.getRetailerData(t.index).item?.title}
aria-label=${(e,t)=>t.parent.getRetailerData(t.index).item?.aria?.label}
aria-description=${(e,t)=>t.parent.getRetailerData(t.index).item.aria?.description}
@click="${(e,t)=>t.parent.clickEventHandler(t.index,t.event)}"
>
${Ze(((e,t)=>t.parent.getRetailerData(t.index).item),((e,t)=>{const i=t.parent.getData.retailers[t.index].item;return Be`<commerceui-retailer-item
name=${i.name}
img-url=${i.imgUrl}
img-alt=${i.imgAlt}
hide-logo=${t.parent.hideRetailersLogo}
description=${i.description}
?advertisement=${i.advertisement}
:metadata=${i.metadata}
></commerceui-retailer-item>`}))}
${Ze(((e,t)=>t.parent.getRetailerData(t.index).price),((e,t)=>{const i=t.parent.getData.retailers[t.index].price,n=i.oldPrice>i.currentPrice;return Be`
<div class="price">
<commerceui-price
locale=${t.parent.locale}
currency=${t.parent.currency}
size="medium"
color="${n?Gu:"neutral"}"
show-raised-cents
show-zero-cents
value="${i.currentPrice}"
></commerceui-price>
${Ze(i.isLowestPrice,Be`<commerceui-badge color="success" appearance="tint"
>${t.parent.lowestPriceLabel}</commerceui-badge
>`)}
${Ze(i.oldPrice,Be`<commerceui-price
locale=${t.parent.locale}
currency=${t.parent.currency}
size="xx-small"
color="${"subtle"}"
strikethrough
value="${i.oldPrice}"
></commerceui-price>`)}
${Ze(i.discountPrice,Be`<div class="save-label">
${t.parent.discountPriceLabel}
<commerceui-price
locale=${t.parent.locale}
currency=${t.parent.currency}
size="xx-small"
color="${Gu}"
value="${i.discountPrice}"
></commerceui-price>
</div>`)}
${Ze(i.installmentsPrice,Be`<commerceui-price
locale=${t.parent.locale}
currency=${t.parent.currency}
size="xx-small"
value=${i.installmentsPrice}
per-item-label=${i.installmentsPerItemLabel}
></commerceui-price>`)}
</div>
`}))}
${Ze(((e,t)=>t.parent.layout===Bu.regular&&t.parent.getRetailerData(t.index).ctaButton),((e,t)=>{const i=t.parent.getData.retailers[t.index].ctaButton;return Be`<div class="cta-button">
<fluent-beta-button
size="small"
appearance="${i.appearance}"
disabled="${i?.disabled}"
aria-label="${i?.aria?.label}"
aria-description="${i?.aria?.description}"
title="${i?.title}"
@click="${(e,t)=>t.parent.clickCtaEventHandler(t.index,t.event)}"
>${t.parent.ctaButtonLabel}</fluent-beta-button
>
</div>`}))}
</a>
</li>
`,{positioning:!0})}
</ul>`,Be`<div class="no-data-label">${e=>e.noDataLabel}</div>`)}
</div>`,qp=Zu.compose({name:`${Mu.prefix}-buying-options-retailer-list`,template:Kp,styles:Vu});qp.define(Mu.registry);class Yp extends Pt{}const Xp=Be`
<slot name="filter-group"></slot>
<slot name="retailer-list"></slot>
<slot name="show-more-retailers"></slot>
`,Jp=Be`${Xp}`;Be`<commerceui-buying-options-base></commerceui-buying-options-base>`;const Qp=re`
/*****************************************
* Common styles
*****************************************/
:host {
display: flex;
flex-direction: column;
row-gap: ${di};
}
::slotted(:first-child:not([slot="retailer-list"])) {
margin-bottom: ${ui};
}
::slotted([slot="show-more-retailers"]) {
display: flex;
flex-direction: column;
align-items: center;
}
`,eg=Yp.compose({name:`${Mu.prefix}-buying-options-base`,template:Jp,styles:Qp});var tg=Object.defineProperty,ig=Object.getOwnPropertyDescriptor,ng=(e,t,i,n)=>{for(var o,r=n>1?void 0:n?ig(t,i):t,a=e.length-1;a>=0;a--)(o=e[a])&&(r=(n?o(t,i,r):o(r))||r);return n&&r&&tg(t,i,r),r};class og extends Pt{constructor(){super(...arguments),this.layout=Bu.compact,this.appearance=Fu.edge,this.hideShowMoreRetailers=!1,this.showMoreRetailersLabel="Show more retailers",this.handleNavigation=!1,this.locale="en-US",this.currency="USD",this.filterGroupDirection=At.row,this.filterGroupSorted=!0,this.filterGroupInlineSwatches=!1,this.autoHideOverflowSwatches=!0,this.hideRetailersLogo=!1,this.retailersListNoDataLabel="No retailers available",this.retailersListLowestPriceLabel="Lowest Price",this.retailersListDiscountPriceLabel="Save",this.retailersListCTAButtonLabel="Visit Site"}dataChanged(e,t){this.updateData(t)}filterGroupSortedChanged(){this.updateData(this.getData)}filterGroupEventHandler(e){const t=e.detail.state;this.onfiltergroupselectionchange?.(t,e)}clickRetailerEventHandler(e){const t=e.detail.retailerIndex;this.onretailerclick?.(t,e)}clickShowMoreRetailersEventHandler(e){this.onshowmoreretailersclick?.(e)}mouseRetailerEventHandler(e){const t=e.detail.retailerIndex;this.onretailerhover?.(t,e)}clickCtaEventHandler(e){const t=e.detail.retailerIndex;e.stopPropagation(),this.onretailerctaclick?.(t,e)}sortFilterGroup(e){return this.filterGroupSorted&&e.filters&&e.filters.length>0?{filters:e.filters.sort(((e,t)=>"dropdown"===e.type&&"swatches"===t.type?-1:"swatches"===e.type&&"dropdown"===t.type?1:0))}:e}updateData(e){e&&(this._data={filterGroup:this.sortFilterGroup(e.filterGroup),retailerList:e.retailerList})}get getData(){return this._data}get getFiltersData(){return this.getData.filterGroup.filters}get getRetailersListData(){return{retailers:this.getData.retailerList.retailers.slice(0,this.getShowRetailersCount)}}get getRetailersData(){return this.getData.retailerList.retailers}get getTotalRetailersCount(){return this._data.retailerList.retailers.length}get getShowRetailersCount(){return void 0!==this.showMaxRetailers?Math.min(this.showMaxRetailers,this.getTotalRetailersCount):this.getTotalRetailersCount}get getShowMoreRetailers(){return!this.hideShowMoreRetailers&&this.getShowRetailersCount<this.getTotalRetailersCount}}ng([st({attribute:"data"})],og.prototype,"data",2),ng([st],og.prototype,"layout",2),ng([st],og.prototype,"appearance",2),ng([st({attribute:"show-max-retailers",converter:rt})],og.prototype,"showMaxRetailers",2),ng([st({attribute:"hide-show-more-retailers",mode:"boolean"})],og.prototype,"hideShowMoreRetailers",2),ng([st({attribute:"show-more-retailers-label"})],og.prototype,"showMoreRetailersLabel",2),ng([st({attribute:"handle-navigation",mode:"boolean"})],og.prototype,"handleNavigation",2),ng([st({attribute:"locale"})],og.prototype,"locale",2),ng([st({attribute:"currency"})],og.prototype,"currency",2),ng([st({attribute:"filter-group-direction"})],og.prototype,"filterGroupDirection",2),ng([st({attribute:"filter-group-sorted",mode:"boolean"})],og.prototype,"filterGroupSorted",2),ng([st({attribute:"filter-group-inline-swatches",mode:"boolean"})],og.prototype,"filterGroupInlineSwatches",2),ng([st({attribute:"auto-hide-overflow-swatches",mode:"boolean"})],og.prototype,"autoHideOverflowSwatches",2),ng([st({attribute:"hide-retailers-logo",mode:"boolean"})],og.prototype,"hideRetailersLogo",2),ng([st({attribute:"retailers-list-no-data-label"})],og.prototype,"retailersListNoDataLabel",2),ng([st({attribute:"retailers-list-lowest-price-label"})],og.prototype,"retailersListLowestPriceLabel",2),ng([st({attribute:"retailers-list-discount-price-label"})],og.prototype,"retailersListDiscountPriceLabel",2),ng([st({attribute:"retailers-list-cta-button-label"})],og.prototype,"retailersListCTAButtonLabel",2),ng([A],og.prototype,"_data",2),eg.define(Mu.registry),Lu.define(Mu.registry),So.name="fluent-beta-button",So.define(customElements);const rg=Be` <commerceui-buying-options-base>
${Ze((e=>e.getFiltersData.length>0),Be`<div slot="filter-group">
<slot name="filter-group">
<commerceui-buying-options-filter-group
direction=${e=>e.filterGroupDirection}
inline-swatches=${e=>e.filterGroupInlineSwatches}
auto-hide-overflow-swatches=${e=>e.autoHideOverflowSwatches}
:data=${e=>e.getData.filterGroup}
@onfiltergroupselectionchange=${(e,t)=>e.filterGroupEventHandler(t.event)}
></commerceui-buying-options-filter-group
></slot>
</div>`)}
<div slot="retailer-list">
<slot name="retailer-list">
<commerceui-buying-options-retailer-list
locale=${e=>e.locale}
currency=${e=>e.currency}
:data=${e=>e.getRetailersListData}
hide-retailers-logo=${e=>e.hideRetailersLogo}
layout=${e=>e.layout}
no-data-label=${e=>e.retailersListNoDataLabel}
lowest-price-label=${e=>e.retailersListLowestPriceLabel}
cta-button-label=${e=>e.retailersListCTAButtonLabel}
discount-price-label=${e=>e.retailersListDiscountPriceLabel}
appearance=${e=>e.appearance}
handle-navigation=${e=>e.handleNavigation}
@retailerclick=${(e,t)=>e.clickRetailerEventHandler(t.event)}
@retailerctaclick=${(e,t)=>e.clickCtaEventHandler(t.event)}
@retailerhover=${(e,t)=>e.mouseRetailerEventHandler(t.event)}
></commerceui-buying-options-retailer-list>
</slot>
</div>
${Ze((e=>e.getShowMoreRetailers),Be`<div slot="show-more-retailers">
<slot name="show-more-retailers">
<fluent-beta-button
shape="rounded"
appearance="transparent"
size="medium"
icon
@click="${(e,t)=>e.clickShowMoreRetailersEventHandler(t.event)}"
>
<svg
width="16"
height="16"
viewBox="0 0 16 16"
fill="currentColor"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M3.14645 5.64645C3.34171 5.45118 3.65829 5.45118 3.85355 5.64645L8 9.79289L12.1464 5.64645C12.3417 5.45118 12.6583 5.45118 12.8536 5.64645C13.0488 5.84171 13.0488 6.15829 12.8536 6.35355L8.35355 10.8536C8.15829 11.0488 7.84171 11.0488 7.64645 10.8536L3.14645 6.35355C2.95118 6.15829 2.95118 5.84171 3.14645 5.64645Z"
fill="currentColor"
/>
</svg>
${e=>e.showMoreRetailersLabel}
</fluent-beta-button>
</slot>
</div>`)}
</commerceui-buying-options-base>`;Be` <commerceui-buying-options
locale=${e=>e.locale}
currency=${e=>e.currency}
title=${e=>e.title}
layout=${e=>e.layout}
appearance=${e=>e.appearance}
show-max-retailers=${e=>e.showMaxRetailers}
show-more-retailers-label=${e=>e.showMoreRetailersLabel}
hide-show-more-retailers=${e=>e.hideShowMoreRetailers}
hide-retailers-logo=${e=>e.hideRetailersLogo}
auto-hide-overflow-swatches=${e=>e.autoHideOverflowSwatches}
filter-group-direction=${e=>e.filterGroupDirection}
filter-group-inline-swatches=${e=>e.filterGroupInlineSwatches}
filter-group-sorted=${e=>e.filterGroupSorted}
retailers-list-no-data-label=${e=>e.retailersListNoDataLabel}
retailers-list-lowest-price-label=${e=>e.retailersListLowestPriceLabel}
retailers-list-cta-button-label=${e=>e.retailersListCTAButtonLabel}
retailers-list-discount-price-label=${e=>e.retailersListDiscountPriceLabel}
handle-navigation=${e=>e.handleNavigation}
:data=${e=>e.data}
:onfiltergroupselectionchange=${e=>e.onfiltergroupselectionchange}
:onretailerclick=${e=>e.onretailerclick}
:onretailerhover=${e=>e.onretailerhover}
:onretailerctaclick=${e=>e.onretailerctaclick}
:onshowmoreretailersclick=${e=>e.onshowmoreretailersclick}
>${e=>e.content}</commerceui-buying-options
>`;const ag=re`
/*****************************************
* Common styles
*****************************************/
:host fluent-beta-button svg {
margin-right: ${ai};
}
`,sg=og.compose({name:`${Mu.prefix}-buying-options`,template:rg,styles:ag})},32463:function(e,t,i){"use strict";function n(e,t=document){const i=new CSSStyleSheet,n=Object.keys(e).map((t=>`--${t}: ${e[t]};`)).join("");i.replaceSync(`:${t instanceof ShadowRoot?"host":"root"} {${n}}`),t.adoptedStyleSheets=[...t.adoptedStyleSheets,i]}function o(){if(!(null===window||void 0===window?void 0:window.matchMedia))return;const e=window.matchMedia("(prefers-color-scheme: dark)");return e?!!e.matches:void 0}function r(){if(!(null===window||void 0===window?void 0:window.matchMedia))return;const e=window.matchMedia("(forced-colors: active)");return e?!!e.matches:void 0}i.r(t),i.d(t,{isDarkMode:function(){return o},isHighContrast:function(){return r},setTheme:function(){return n}})},45101:function(e,t,i){"use strict";i.r(t),i.d(t,{themes:function(){return Ze}});const n="#0a0a0a",o="#141414",r="#1f1f1f",a="#242424",s="#292929",l="#2e2e2e",c="#333333",d="#383838",u="#3d3d3d",h="#424242",p="#575757",g="#616161",f="#707070",m="#adadad",v="#b3b3b3",y="#bdbdbd",C="#d6d6d6",b="#e0e0e0",S="#e6e6e6",x="#ebebeb",T="#f0f0f0",w="#f5f5f5",O="#fafafa",P="rgba(255, 255, 255, 0.1)",A="rgba(255, 255, 255, 0.2)",E="rgba(255, 255, 255, 0.4)",k="rgba(255, 255, 255, 0.5)",I="rgba(0, 0, 0, 0.05)",D="rgba(0, 0, 0, 0.1)",_="rgba(0, 0, 0, 0.2)",N="rgba(0, 0, 0, 0.3)",R="rgba(0, 0, 0, 0.5)",M="#ffffff",L="#000000",B={shade50:"#200205",shade40:"#3b0509",shade30:"#6e0811",shade20:"#960b18",shade10:"#b10e1c",primary:"#c50f1f",tint10:"#cc2635",tint20:"#d33f4c",tint30:"#dc626d",tint40:"#eeacb2",tint50:"#f6d1d5",tint60:"#fdf3f4"},F={shade50:"#031403",shade40:"#052505",shade30:"#094509",shade20:"#0c5e0c",shade10:"#0e700e",primary:"#107c10",tint10:"#218c21",tint20:"#359b35",tint30:"#54b054",tint40:"#9fd89f",tint50:"#c9eac9",tint60:"#f1faf1"},U={red:{shade50:"#210809",shade40:"#3f1011",shade30:"#751d1f",shade20:"#9f282b",shade10:"#bc2f32",primary:"#d13438",tint10:"#d7494c",tint20:"#dc5e62",tint30:"#e37d80",tint40:"#f1bbbc",tint50:"#f8dadb",tint60:"#fdf6f6"},green:F,darkOrange:{shade50:"#230900",shade40:"#411200",shade30:"#7a2101",shade20:"#a62d01",shade10:"#c43501",primary:"#da3b01",tint10:"#de501c",tint20:"#e36537",tint30:"#e9835e",tint40:"#f4bfab",tint50:"#f9dcd1",tint60:"#fdf6f3"},yellow:{shade50:"#282400",shade40:"#4c4400",shade30:"#817400",shade20:"#c0ad00",shade10:"#e4cc00",primary:"#fde300",tint10:"#fde61e",tint20:"#fdea3d",tint30:"#feee66",tint40:"#fef7b2",tint50:"#fffad6",tint60:"#fffef5"},berry:{shade50:"#1f091d",shade40:"#3a1136",shade30:"#6d2064",shade20:"#932b88",shade10:"#af33a1",primary:"#c239b3",tint10:"#c94cbc",tint20:"#d161c4",tint30:"#da7ed0",tint40:"#edbbe7",tint50:"#f5daf2",tint60:"#fdf5fc"},lightGreen:{shade50:"#031a02",shade40:"#063004",shade30:"#0b5a08",shade20:"#0e7a0b",shade10:"#11910d",primary:"#13a10e",tint10:"#27ac22",tint20:"#3db838",tint30:"#5ec75a",tint40:"#a7e3a5",tint50:"#cef0cd",tint60:"#f2fbf2"},marigold:{shade50:"#251a00",shade40:"#463100",shade30:"#835b00",shade20:"#b27c00",shade10:"#d39300",primary:"#eaa300",tint10:"#edad1c",tint20:"#efb839",tint30:"#f2c661",tint40:"#f9e2ae",tint50:"#fcefd3",tint60:"#fefbf4"}},H={darkRed:{shade50:"#130204",shade40:"#230308",shade30:"#420610",shade20:"#590815",shade10:"#690a19",primary:"#750b1c",tint10:"#861b2c",tint20:"#962f3f",tint30:"#ac4f5e",tint40:"#d69ca5",tint50:"#e9c7cd",tint60:"#f9f0f2"},cranberry:B,pumpkin:{shade50:"#200d03",shade40:"#3d1805",shade30:"#712d09",shade20:"#9a3d0c",shade10:"#b6480e",primary:"#ca5010",tint10:"#d06228",tint20:"#d77440",tint30:"#df8e64",tint40:"#efc4ad",tint50:"#f7dfd2",tint60:"#fdf7f4"},peach:{shade50:"#291600",shade40:"#4d2a00",shade30:"#8f4e00",shade20:"#c26a00",shade10:"#e67e00",primary:"#ff8c00",tint10:"#ff9a1f",tint20:"#ffa83d",tint30:"#ffba66",tint40:"#ffddb3",tint50:"#ffedd6",tint60:"#fffaf5"},gold:{shade50:"#1f1900",shade40:"#3a2f00",shade30:"#6c5700",shade20:"#937700",shade10:"#ae8c00",primary:"#c19c00",tint10:"#c8a718",tint20:"#d0b232",tint30:"#dac157",tint40:"#ecdfa5",tint50:"#f5eece",tint60:"#fdfbf2"},brass:{shade50:"#181202",shade40:"#2e2103",shade30:"#553e06",shade20:"#745408",shade10:"#89640a",primary:"#986f0b",tint10:"#a47d1e",tint20:"#b18c34",tint30:"#c1a256",tint40:"#e0cea2",tint50:"#efe4cb",tint60:"#fbf8f2"},brown:{shade50:"#170e07",shade40:"#2b1a0e",shade30:"#50301a",shade20:"#6c4123",shade10:"#804d29",primary:"#8e562e",tint10:"#9c663f",tint20:"#a97652",tint30:"#bb8f6f",tint40:"#ddc3b0",tint50:"#edded3",tint60:"#faf7f4"},forest:{shade50:"#0c1501",shade40:"#162702",shade30:"#294903",shade20:"#376304",shade10:"#427505",primary:"#498205",tint10:"#599116",tint20:"#6ba02b",tint30:"#85b44c",tint40:"#bdd99b",tint50:"#dbebc7",tint60:"#f6faf0"},seafoam:{shade50:"#002111",shade40:"#003d20",shade30:"#00723b",shade20:"#009b51",shade10:"#00b85f",primary:"#00cc6a",tint10:"#19d279",tint20:"#34d889",tint30:"#5ae0a0",tint40:"#a8f0cd",tint50:"#cff7e4",tint60:"#f3fdf8"},darkGreen:{shade50:"#021102",shade40:"#032003",shade30:"#063b06",shade20:"#085108",shade10:"#0a5f0a",primary:"#0b6a0b",tint10:"#1a7c1a",tint20:"#2d8e2d",tint30:"#4da64d",tint40:"#9ad29a",tint50:"#c6e7c6",tint60:"#f0f9f0"},lightTeal:{shade50:"#001d1f",shade40:"#00373a",shade30:"#00666d",shade20:"#008b94",shade10:"#00a5af",primary:"#00b7c3",tint10:"#18bfca",tint20:"#32c8d1",tint30:"#58d3db",tint40:"#a6e9ed",tint50:"#cef3f5",tint60:"#f2fcfd"},teal:{shade50:"#001516",shade40:"#012728",shade30:"#02494c",shade20:"#026467",shade10:"#037679",primary:"#038387",tint10:"#159195",tint20:"#2aa0a4",tint30:"#4cb4b7",tint40:"#9bd9db",tint50:"#c7ebec",tint60:"#f0fafa"},steel:{shade50:"#000f12",shade40:"#001b22",shade30:"#00333f",shade20:"#004555",shade10:"#005265",primary:"#005b70",tint10:"#0f6c81",tint20:"#237d92",tint30:"#4496a9",tint40:"#94c8d4",tint50:"#c3e1e8",tint60:"#eff7f9"},blue:{shade50:"#001322",shade40:"#002440",shade30:"#004377",shade20:"#005ba1",shade10:"#006cbf",primary:"#0078d4",tint10:"#1a86d9",tint20:"#3595de",tint30:"#5caae5",tint40:"#a9d3f2",tint50:"#d0e7f8",tint60:"#f3f9fd"},royalBlue:{shade50:"#000c16",shade40:"#00172a",shade30:"#002c4e",shade20:"#003b6a",shade10:"#00467e",primary:"#004e8c",tint10:"#125e9a",tint20:"#286fa8",tint30:"#4a89ba",tint40:"#9abfdc",tint50:"#c7dced",tint60:"#f0f6fa"},cornflower:{shade50:"#0d1126",shade40:"#182047",shade30:"#2c3c85",shade20:"#3c51b4",shade10:"#4760d5",primary:"#4f6bed",tint10:"#637cef",tint20:"#778df1",tint30:"#93a4f4",tint40:"#c8d1fa",tint50:"#e1e6fc",tint60:"#f7f9fe"},navy:{shade50:"#00061d",shade40:"#000c36",shade30:"#001665",shade20:"#001e89",shade10:"#0023a2",primary:"#0027b4",tint10:"#173bbd",tint20:"#3050c6",tint30:"#546fd2",tint40:"#a3b2e8",tint50:"#ccd5f3",tint60:"#f2f4fc"},lavender:{shade50:"#120f25",shade40:"#221d46",shade30:"#3f3682",shade20:"#5649b0",shade10:"#6656d1",primary:"#7160e8",tint10:"#8172eb",tint20:"#9184ee",tint30:"#a79cf1",tint40:"#d2ccf8",tint50:"#e7e4fb",tint60:"#f9f8fe"},purple:{shade50:"#0f0717",shade40:"#1c0e2b",shade30:"#341a51",shade20:"#46236e",shade10:"#532982",primary:"#5c2e91",tint10:"#6b3f9e",tint20:"#7c52ab",tint30:"#9470bd",tint40:"#c6b1de",tint50:"#e0d3ed",tint60:"#f7f4fb"},grape:{shade50:"#160418",shade40:"#29072e",shade30:"#4c0d55",shade20:"#671174",shade10:"#7a1589",primary:"#881798",tint10:"#952aa4",tint20:"#a33fb1",tint30:"#b55fc1",tint40:"#d9a7e0",tint50:"#eaceef",tint60:"#faf2fb"},lilac:{shade50:"#1c0b1f",shade40:"#35153a",shade30:"#63276d",shade20:"#863593",shade10:"#9f3faf",primary:"#b146c2",tint10:"#ba58c9",tint20:"#c36bd1",tint30:"#cf87da",tint40:"#e6bfed",tint50:"#f2dcf5",tint60:"#fcf6fd"},pink:{shade50:"#24091b",shade40:"#441232",shade30:"#80215d",shade20:"#ad2d7e",shade10:"#cd3595",primary:"#e43ba6",tint10:"#e750b0",tint20:"#ea66ba",tint30:"#ef85c8",tint40:"#f7c0e3",tint50:"#fbddf0",tint60:"#fef6fb"},magenta:{shade50:"#1f0013",shade40:"#390024",shade30:"#6b0043",shade20:"#91005a",shade10:"#ac006b",primary:"#bf0077",tint10:"#c71885",tint20:"#ce3293",tint30:"#d957a8",tint40:"#eca5d1",tint50:"#f5cee6",tint60:"#fcf2f9"},plum:{shade50:"#13000c",shade40:"#240017",shade30:"#43002b",shade20:"#5a003b",shade10:"#6b0045",primary:"#77004d",tint10:"#87105d",tint20:"#98246f",tint30:"#ad4589",tint40:"#d696c0",tint50:"#e9c4dc",tint60:"#faf0f6"},beige:{shade50:"#141313",shade40:"#252323",shade30:"#444241",shade20:"#5d5958",shade10:"#6e6968",primary:"#7a7574",tint10:"#8a8584",tint20:"#9a9594",tint30:"#afabaa",tint40:"#d7d4d4",tint50:"#eae8e8",tint60:"#faf9f9"},mink:{shade50:"#0f0e0e",shade40:"#1c1b1a",shade30:"#343231",shade20:"#474443",shade10:"#54514f",primary:"#5d5a58",tint10:"#706d6b",tint20:"#84817e",tint30:"#9e9b99",tint40:"#cecccb",tint50:"#e5e4e3",tint60:"#f8f8f8"},platinum:{shade50:"#111314",shade40:"#1f2426",shade30:"#3b4447",shade20:"#505c60",shade10:"#5f6d71",primary:"#69797e",tint10:"#79898d",tint20:"#89989d",tint30:"#a0adb2",tint40:"#cdd6d8",tint50:"#e4e9ea",tint60:"#f8f9fa"},anchor:{shade50:"#090a0b",shade40:"#111315",shade30:"#202427",shade20:"#2b3135",shade10:"#333a3f",primary:"#394146",tint10:"#4d565c",tint20:"#626c72",tint30:"#808a90",tint40:"#bcc3c7",tint50:"#dbdfe1",tint60:"#f6f7f8"}},$={cranberry:B,green:F,orange:{shade50:"#271002",shade40:"#4a1e04",shade30:"#8a3707",shade20:"#bc4b09",shade10:"#de590b",primary:"#f7630c",tint10:"#f87528",tint20:"#f98845",tint30:"#faa06b",tint40:"#fdcfb4",tint50:"#fee5d7",tint60:"#fff9f5"}},Z=["red","green","darkOrange","yellow","berry","lightGreen","marigold"],V=["darkRed","cranberry","pumpkin","peach","gold","brass","brown","forest","seafoam","darkGreen","lightTeal","teal","steel","blue","royalBlue","cornflower","navy","lavender","purple","grape","lilac","pink","magenta","plum","beige","mink","platinum","anchor"],G={success:"green",warning:"orange",danger:"cranberry"},j=Z.reduce(((e,t)=>{const i=t.slice(0,1).toUpperCase()+t.slice(1),n={[`colorPalette${i}Background1`]:U[t].tint60,[`colorPalette${i}Background2`]:U[t].tint40,[`colorPalette${i}Background3`]:U[t].primary,[`colorPalette${i}Foreground1`]:U[t].shade10,[`colorPalette${i}Foreground2`]:U[t].shade30,[`colorPalette${i}Foreground3`]:U[t].primary,[`colorPalette${i}BorderActive`]:U[t].primary,[`colorPalette${i}Border1`]:U[t].tint40,[`colorPalette${i}Border2`]:U[t].primary};return Object.assign(e,n)}),{});j.colorPaletteYellowForeground1=U.yellow.shade30,j.colorPaletteRedForegroundInverted=U.red.tint20,j.colorPaletteGreenForegroundInverted=U.green.tint20,j.colorPaletteYellowForegroundInverted=U.yellow.tint40;const z=V.reduce(((e,t)=>{const i=t.slice(0,1).toUpperCase()+t.slice(1),n={[`colorPalette${i}Background2`]:H[t].tint40,[`colorPalette${i}Foreground2`]:H[t].shade30,[`colorPalette${i}BorderActive`]:H[t].primary};return Object.assign(e,n)}),{}),W={...j,...z},K=Object.entries(G).reduce(((e,[t,i])=>{const n=t.slice(0,1).toUpperCase()+t.slice(1),o={[`colorStatus${n}Background1`]:$[i].tint60,[`colorStatus${n}Background2`]:$[i].tint40,[`colorStatus${n}Background3`]:$[i].primary,[`colorStatus${n}Foreground1`]:$[i].shade10,[`colorStatus${n}Foreground2`]:$[i].shade30,[`colorStatus${n}Foreground3`]:$[i].primary,[`colorStatus${n}ForegroundInverted`]:$[i].tint30,[`colorStatus${n}BorderActive`]:$[i].primary,[`colorStatus${n}Border1`]:$[i].tint40,[`colorStatus${n}Border2`]:$[i].primary};return Object.assign(e,o)}),{});K.colorStatusDangerBackground3Hover=$[G.danger].shade10,K.colorStatusDangerBackground3Pressed=$[G.danger].shade20,K.colorStatusWarningForeground1=$[G.warning].shade20,K.colorStatusWarningForeground3=$[G.warning].shade20,K.colorStatusWarningBorder2=$[G.warning].shade20;const q={borderRadiusNone:"0",borderRadiusSmall:"2px",borderRadiusMedium:"4px",borderRadiusLarge:"6px",borderRadiusXLarge:"8px",borderRadiusCircular:"10000px"},Y={curveAccelerateMax:"cubic-bezier(0.9,0.1,1,0.2)",curveAccelerateMid:"cubic-bezier(1,0,1,1)",curveAccelerateMin:"cubic-bezier(0.8,0,0.78,1)",curveDecelerateMax:"cubic-bezier(0.1,0.9,0.2,1)",curveDecelerateMid:"cubic-bezier(0,0,0,1)",curveDecelerateMin:"cubic-bezier(0.33,0,0.1,1)",curveEasyEaseMax:"cubic-bezier(0.8,0,0.2,1)",curveEasyEase:"cubic-bezier(0.33,0,0.67,1)",curveLinear:"cubic-bezier(0,0,1,1)"},X={durationUltraFast:"50ms",durationFaster:"100ms",durationFast:"150ms",durationNormal:"200ms",durationGentle:"250ms",durationSlow:"300ms",durationSlower:"400ms",durationUltraSlow:"500ms"},J={fontSizeBase100:"10px",fontSizeBase200:"12px",fontSizeBase300:"14px",fontSizeBase400:"16px",fontSizeBase500:"20px",fontSizeBase600:"24px",fontSizeHero700:"28px",fontSizeHero800:"32px",fontSizeHero900:"40px",fontSizeHero1000:"68px"},Q={lineHeightBase100:"14px",lineHeightBase200:"16px",lineHeightBase300:"20px",lineHeightBase400:"22px",lineHeightBase500:"28px",lineHeightBase600:"32px",lineHeightHero700:"36px",lineHeightHero800:"40px",lineHeightHero900:"52px",lineHeightHero1000:"92px"},ee={fontWeightRegular:400,fontWeightMedium:500,fontWeightSemibold:600,fontWeightBold:700},te={fontFamilyBase:"'Segoe UI', 'Segoe UI Web (West European)', -apple-system, BlinkMacSystemFont, Roboto, 'Helvetica Neue', sans-serif",fontFamilyMonospace:"Consolas, 'Courier New', Courier, monospace",fontFamilyNumeric:"Bahnschrift, 'Segoe UI', 'Segoe UI Web (West European)', -apple-system, BlinkMacSystemFont, Roboto, 'Helvetica Neue', sans-serif"},ie="10px",ne="12px",oe="16px",re="20px",ae="24px",se="32px",le={spacingHorizontalNone:"0",spacingHorizontalXXS:"2px",spacingHorizontalXS:"4px",spacingHorizontalSNudge:"6px",spacingHorizontalS:"8px",spacingHorizontalMNudge:ie,spacingHorizontalM:ne,spacingHorizontalL:oe,spacingHorizontalXL:re,spacingHorizontalXXL:ae,spacingHorizontalXXXL:se},ce={spacingVerticalNone:"0",spacingVerticalXXS:"2px",spacingVerticalXS:"4px",spacingVerticalSNudge:"6px",spacingVerticalS:"8px",spacingVerticalMNudge:ie,spacingVerticalM:ne,spacingVerticalL:oe,spacingVerticalXL:re,spacingVerticalXXL:ae,spacingVerticalXXXL:se},de={strokeWidthThin:"1px",strokeWidthThick:"2px",strokeWidthThicker:"3px",strokeWidthThickest:"4px"};function ue(e,t,i=""){return{[`shadow2${i}`]:`0 0 2px ${e}, 0 1px 2px ${t}`,[`shadow4${i}`]:`0 0 2px ${e}, 0 2px 4px ${t}`,[`shadow8${i}`]:`0 0 2px ${e}, 0 4px 8px ${t}`,[`shadow16${i}`]:`0 0 2px ${e}, 0 8px 16px ${t}`,[`shadow28${i}`]:`0 0 8px ${e}, 0 14px 28px ${t}`,[`shadow64${i}`]:`0 0 8px ${e}, 0 32px 64px ${t}`}}const he=e=>{const t=(e=>({colorNeutralForeground1:a,colorNeutralForeground1Hover:a,colorNeutralForeground1Pressed:a,colorNeutralForeground1Selected:a,colorNeutralForeground2:h,colorNeutralForeground2Hover:a,colorNeutralForeground2Pressed:a,colorNeutralForeground2Selected:a,colorNeutralForeground2BrandHover:e[80],colorNeutralForeground2BrandPressed:e[70],colorNeutralForeground2BrandSelected:e[80],colorNeutralForeground3:g,colorNeutralForeground3Hover:h,colorNeutralForeground3Pressed:h,colorNeutralForeground3Selected:h,colorNeutralForeground3BrandHover:e[80],colorNeutralForeground3BrandPressed:e[70],colorNeutralForeground3BrandSelected:e[80],colorNeutralForeground4:f,colorNeutralForegroundDisabled:y,colorNeutralForegroundInvertedDisabled:E,colorBrandForegroundLink:e[70],colorBrandForegroundLinkHover:e[60],colorBrandForegroundLinkPressed:e[40],colorBrandForegroundLinkSelected:e[70],colorNeutralForeground2Link:h,colorNeutralForeground2LinkHover:a,colorNeutralForeground2LinkPressed:a,colorNeutralForeground2LinkSelected:a,colorCompoundBrandForeground1:e[80],colorCompoundBrandForeground1Hover:e[70],colorCompoundBrandForeground1Pressed:e[60],colorBrandForeground1:e[80],colorBrandForeground2:e[70],colorBrandForeground2Hover:e[60],colorBrandForeground2Pressed:e[30],colorNeutralForeground1Static:a,colorNeutralForegroundStaticInverted:M,colorNeutralForegroundInverted:M,colorNeutralForegroundInvertedHover:M,colorNeutralForegroundInvertedPressed:M,colorNeutralForegroundInvertedSelected:M,colorNeutralForegroundInverted2:M,colorNeutralForegroundOnBrand:M,colorNeutralForegroundInvertedLink:M,colorNeutralForegroundInvertedLinkHover:M,colorNeutralForegroundInvertedLinkPressed:M,colorNeutralForegroundInvertedLinkSelected:M,colorBrandForegroundInverted:e[100],colorBrandForegroundInvertedHover:e[110],colorBrandForegroundInvertedPressed:e[100],colorBrandForegroundOnLight:e[80],colorBrandForegroundOnLightHover:e[70],colorBrandForegroundOnLightPressed:e[50],colorBrandForegroundOnLightSelected:e[60],colorNeutralBackground1:M,colorNeutralBackground1Hover:w,colorNeutralBackground1Pressed:b,colorNeutralBackground1Selected:x,colorNeutralBackground2:O,colorNeutralBackground2Hover:T,colorNeutralBackground2Pressed:"#dbdbdb",colorNeutralBackground2Selected:S,colorNeutralBackground3:w,colorNeutralBackground3Hover:x,colorNeutralBackground3Pressed:C,colorNeutralBackground3Selected:b,colorNeutralBackground4:T,colorNeutralBackground4Hover:O,colorNeutralBackground4Pressed:w,colorNeutralBackground4Selected:M,colorNeutralBackground5:x,colorNeutralBackground5Hover:w,colorNeutralBackground5Pressed:T,colorNeutralBackground5Selected:O,colorNeutralBackground6:S,colorNeutralBackgroundInverted:s,colorNeutralBackgroundStatic:c,colorNeutralBackgroundAlpha:k,colorNeutralBackgroundAlpha2:"rgba(255, 255, 255, 0.8)",colorSubtleBackground:"transparent",colorSubtleBackgroundHover:w,colorSubtleBackgroundPressed:b,colorSubtleBackgroundSelected:x,colorSubtleBackgroundLightAlphaHover:"rgba(255, 255, 255, 0.7)",colorSubtleBackgroundLightAlphaPressed:k,colorSubtleBackgroundLightAlphaSelected:"transparent",colorSubtleBackgroundInverted:"transparent",colorSubtleBackgroundInvertedHover:D,colorSubtleBackgroundInvertedPressed:N,colorSubtleBackgroundInvertedSelected:_,colorTransparentBackground:"transparent",colorTransparentBackgroundHover:"transparent",colorTransparentBackgroundPressed:"transparent",colorTransparentBackgroundSelected:"transparent",colorNeutralBackgroundDisabled:T,colorNeutralBackgroundInvertedDisabled:P,colorNeutralStencil1:S,colorNeutralStencil2:O,colorNeutralStencil1Alpha:D,colorNeutralStencil2Alpha:I,colorBackgroundOverlay:"rgba(0, 0, 0, 0.4)",colorScrollbarOverlay:R,colorBrandBackground:e[80],colorBrandBackgroundHover:e[70],colorBrandBackgroundPressed:e[40],colorBrandBackgroundSelected:e[60],colorCompoundBrandBackground:e[80],colorCompoundBrandBackgroundHover:e[70],colorCompoundBrandBackgroundPressed:e[60],colorBrandBackgroundStatic:e[80],colorBrandBackground2:e[160],colorBrandBackground2Hover:e[150],colorBrandBackground2Pressed:e[130],colorBrandBackground3Static:e[60],colorBrandBackground4Static:e[40],colorBrandBackgroundInverted:M,colorBrandBackgroundInvertedHover:e[160],colorBrandBackgroundInvertedPressed:e[140],colorBrandBackgroundInvertedSelected:e[150],colorNeutralCardBackground:O,colorNeutralCardBackgroundHover:M,colorNeutralCardBackgroundPressed:w,colorNeutralCardBackgroundSelected:x,colorNeutralCardBackgroundDisabled:T,colorNeutralStrokeAccessible:g,colorNeutralStrokeAccessibleHover:p,colorNeutralStrokeAccessiblePressed:"#4d4d4d",colorNeutralStrokeAccessibleSelected:e[80],colorNeutralStroke1:"#d1d1d1",colorNeutralStroke1Hover:"#c7c7c7",colorNeutralStroke1Pressed:v,colorNeutralStroke1Selected:y,colorNeutralStroke2:b,colorNeutralStroke3:T,colorNeutralStrokeSubtle:b,colorNeutralStrokeOnBrand:M,colorNeutralStrokeOnBrand2:M,colorNeutralStrokeOnBrand2Hover:M,colorNeutralStrokeOnBrand2Pressed:M,colorNeutralStrokeOnBrand2Selected:M,colorBrandStroke1:e[80],colorBrandStroke2:e[140],colorBrandStroke2Hover:e[120],colorBrandStroke2Pressed:e[80],colorBrandStroke2Contrast:e[140],colorCompoundBrandStroke:e[80],colorCompoundBrandStrokeHover:e[70],colorCompoundBrandStrokePressed:e[60],colorNeutralStrokeDisabled:b,colorNeutralStrokeInvertedDisabled:E,colorTransparentStroke:"transparent",colorTransparentStrokeInteractive:"transparent",colorTransparentStrokeDisabled:"transparent",colorNeutralStrokeAlpha:I,colorNeutralStrokeAlpha2:A,colorStrokeFocus1:M,colorStrokeFocus2:L,colorNeutralShadowAmbient:"rgba(0,0,0,0.12)",colorNeutralShadowKey:"rgba(0,0,0,0.14)",colorNeutralShadowAmbientLighter:"rgba(0,0,0,0.06)",colorNeutralShadowKeyLighter:"rgba(0,0,0,0.07)",colorNeutralShadowAmbientDarker:"rgba(0,0,0,0.20)",colorNeutralShadowKeyDarker:"rgba(0,0,0,0.24)",colorBrandShadowAmbient:"rgba(0,0,0,0.30)",colorBrandShadowKey:"rgba(0,0,0,0.25)"}))(e);return{...q,...J,...Q,...te,...ee,...de,...le,...ce,...X,...Y,...t,...W,...K,...ue(t.colorNeutralShadowAmbient,t.colorNeutralShadowKey),...ue(t.colorBrandShadowAmbient,t.colorBrandShadowKey,"Brand")}},pe=Z.reduce(((e,t)=>{const i=t.slice(0,1).toUpperCase()+t.slice(1),n={[`colorPalette${i}Background1`]:U[t].shade40,[`colorPalette${i}Background2`]:U[t].shade30,[`colorPalette${i}Background3`]:U[t].primary,[`colorPalette${i}Foreground1`]:U[t].tint30,[`colorPalette${i}Foreground2`]:U[t].tint40,[`colorPalette${i}Foreground3`]:U[t].tint20,[`colorPalette${i}BorderActive`]:U[t].tint30,[`colorPalette${i}Border1`]:U[t].primary,[`colorPalette${i}Border2`]:U[t].tint20};return Object.assign(e,n)}),{});pe.colorPaletteRedForeground3=U.red.tint30,pe.colorPaletteRedBorder2=U.red.tint30,pe.colorPaletteGreenForeground3=U.green.tint40,pe.colorPaletteGreenBorder2=U.green.tint40,pe.colorPaletteDarkOrangeForeground3=U.darkOrange.tint30,pe.colorPaletteDarkOrangeBorder2=U.darkOrange.tint30,pe.colorPaletteRedForegroundInverted=U.red.primary,pe.colorPaletteGreenForegroundInverted=U.green.primary,pe.colorPaletteYellowForegroundInverted=U.yellow.shade30;const ge=V.reduce(((e,t)=>{const i=t.slice(0,1).toUpperCase()+t.slice(1),n={[`colorPalette${i}Background2`]:H[t].shade30,[`colorPalette${i}Foreground2`]:H[t].tint40,[`colorPalette${i}BorderActive`]:H[t].tint30};return Object.assign(e,n)}),{});ge.colorPaletteDarkRedBackground2=H.darkRed.shade20,ge.colorPalettePlumBackground2=H.plum.shade20;const fe={...pe,...ge},me=Object.entries(G).reduce(((e,[t,i])=>{const n=t.slice(0,1).toUpperCase()+t.slice(1),o={[`colorStatus${n}Background1`]:$[i].shade40,[`colorStatus${n}Background2`]:$[i].shade30,[`colorStatus${n}Background3`]:$[i].primary,[`colorStatus${n}Foreground1`]:$[i].tint30,[`colorStatus${n}Foreground2`]:$[i].tint40,[`colorStatus${n}Foreground3`]:$[i].tint20,[`colorStatus${n}BorderActive`]:$[i].tint30,[`colorStatus${n}ForegroundInverted`]:$[i].shade10,[`colorStatus${n}Border1`]:$[i].primary,[`colorStatus${n}Border2`]:$[i].tint20};return Object.assign(e,o)}),{});me.colorStatusDangerBackground3Hover=$[G.danger].shade10,me.colorStatusDangerBackground3Pressed=$[G.danger].shade20,me.colorStatusDangerForeground3=$[G.danger].tint40,me.colorStatusDangerBorder2=$[G.danger].tint30,me.colorStatusSuccessForeground3=$[G.success].tint40,me.colorStatusSuccessBorder2=$[G.success].tint40,me.colorStatusWarningForegroundInverted=$[G.warning].shade20;const ve=e=>{const t=(e=>({colorNeutralForeground1:M,colorNeutralForeground1Hover:M,colorNeutralForeground1Pressed:M,colorNeutralForeground1Selected:M,colorNeutralForeground2:C,colorNeutralForeground2Hover:M,colorNeutralForeground2Pressed:M,colorNeutralForeground2Selected:M,colorNeutralForeground2BrandHover:e[100],colorNeutralForeground2BrandPressed:e[90],colorNeutralForeground2BrandSelected:e[100],colorNeutralForeground3:m,colorNeutralForeground3Hover:C,colorNeutralForeground3Pressed:C,colorNeutralForeground3Selected:C,colorNeutralForeground3BrandHover:e[100],colorNeutralForeground3BrandPressed:e[90],colorNeutralForeground3BrandSelected:e[100],colorNeutralForeground4:"#999999",colorNeutralForegroundDisabled:"#5c5c5c",colorNeutralForegroundInvertedDisabled:E,colorBrandForegroundLink:e[100],colorBrandForegroundLinkHover:e[110],colorBrandForegroundLinkPressed:e[90],colorBrandForegroundLinkSelected:e[100],colorNeutralForeground2Link:C,colorNeutralForeground2LinkHover:M,colorNeutralForeground2LinkPressed:M,colorNeutralForeground2LinkSelected:M,colorCompoundBrandForeground1:e[100],colorCompoundBrandForeground1Hover:e[110],colorCompoundBrandForeground1Pressed:e[90],colorBrandForeground1:e[100],colorBrandForeground2:e[110],colorBrandForeground2Hover:e[130],colorBrandForeground2Pressed:e[160],colorNeutralForeground1Static:a,colorNeutralForegroundStaticInverted:M,colorNeutralForegroundInverted:a,colorNeutralForegroundInvertedHover:a,colorNeutralForegroundInvertedPressed:a,colorNeutralForegroundInvertedSelected:a,colorNeutralForegroundInverted2:a,colorNeutralForegroundOnBrand:M,colorNeutralForegroundInvertedLink:M,colorNeutralForegroundInvertedLinkHover:M,colorNeutralForegroundInvertedLinkPressed:M,colorNeutralForegroundInvertedLinkSelected:M,colorBrandForegroundInverted:e[80],colorBrandForegroundInvertedHover:e[70],colorBrandForegroundInvertedPressed:e[60],colorBrandForegroundOnLight:e[80],colorBrandForegroundOnLightHover:e[70],colorBrandForegroundOnLightPressed:e[50],colorBrandForegroundOnLightSelected:e[60],colorNeutralBackground1:s,colorNeutralBackground1Hover:u,colorNeutralBackground1Pressed:r,colorNeutralBackground1Selected:d,colorNeutralBackground2:r,colorNeutralBackground2Hover:c,colorNeutralBackground2Pressed:o,colorNeutralBackground2Selected:l,colorNeutralBackground3:o,colorNeutralBackground3Hover:s,colorNeutralBackground3Pressed:n,colorNeutralBackground3Selected:a,colorNeutralBackground4:n,colorNeutralBackground4Hover:r,colorNeutralBackground4Pressed:L,colorNeutralBackground4Selected:"#1a1a1a",colorNeutralBackground5:L,colorNeutralBackground5Hover:o,colorNeutralBackground5Pressed:"#050505",colorNeutralBackground5Selected:"#0f0f0f",colorNeutralBackground6:c,colorNeutralBackgroundInverted:M,colorNeutralBackgroundStatic:u,colorNeutralBackgroundAlpha:"rgba(26, 26, 26, 0.5)",colorNeutralBackgroundAlpha2:"rgba(31, 31, 31, 0.7)",colorSubtleBackground:"transparent",colorSubtleBackgroundHover:d,colorSubtleBackgroundPressed:l,colorSubtleBackgroundSelected:c,colorSubtleBackgroundLightAlphaHover:"rgba(36, 36, 36, 0.8)",colorSubtleBackgroundLightAlphaPressed:"rgba(36, 36, 36, 0.5)",colorSubtleBackgroundLightAlphaSelected:"transparent",colorSubtleBackgroundInverted:"transparent",colorSubtleBackgroundInvertedHover:D,colorSubtleBackgroundInvertedPressed:N,colorSubtleBackgroundInvertedSelected:_,colorTransparentBackground:"transparent",colorTransparentBackgroundHover:"transparent",colorTransparentBackgroundPressed:"transparent",colorTransparentBackgroundSelected:"transparent",colorNeutralBackgroundDisabled:o,colorNeutralBackgroundInvertedDisabled:P,colorNeutralStencil1:p,colorNeutralStencil2:c,colorNeutralStencil1Alpha:P,colorNeutralStencil2Alpha:"rgba(255, 255, 255, 0.05)",colorBackgroundOverlay:R,colorScrollbarOverlay:"rgba(255, 255, 255, 0.6)",colorBrandBackground:e[70],colorBrandBackgroundHover:e[80],colorBrandBackgroundPressed:e[40],colorBrandBackgroundSelected:e[60],colorCompoundBrandBackground:e[100],colorCompoundBrandBackgroundHover:e[110],colorCompoundBrandBackgroundPressed:e[90],colorBrandBackgroundStatic:e[80],colorBrandBackground2:e[20],colorBrandBackground2Hover:e[40],colorBrandBackground2Pressed:e[10],colorBrandBackground3Static:e[60],colorBrandBackground4Static:e[40],colorBrandBackgroundInverted:M,colorBrandBackgroundInvertedHover:e[160],colorBrandBackgroundInvertedPressed:e[140],colorBrandBackgroundInvertedSelected:e[150],colorNeutralCardBackground:c,colorNeutralCardBackgroundHover:u,colorNeutralCardBackgroundPressed:l,colorNeutralCardBackgroundSelected:d,colorNeutralCardBackgroundDisabled:o,colorNeutralStrokeAccessible:m,colorNeutralStrokeAccessibleHover:y,colorNeutralStrokeAccessiblePressed:v,colorNeutralStrokeAccessibleSelected:e[100],colorNeutralStroke1:"#666666",colorNeutralStroke1Hover:"#757575",colorNeutralStroke1Pressed:"#6b6b6b",colorNeutralStroke1Selected:f,colorNeutralStroke2:"#525252",colorNeutralStroke3:u,colorNeutralStrokeSubtle:n,colorNeutralStrokeOnBrand:s,colorNeutralStrokeOnBrand2:M,colorNeutralStrokeOnBrand2Hover:M,colorNeutralStrokeOnBrand2Pressed:M,colorNeutralStrokeOnBrand2Selected:M,colorBrandStroke1:e[100],colorBrandStroke2:e[50],colorBrandStroke2Hover:e[50],colorBrandStroke2Pressed:e[30],colorBrandStroke2Contrast:e[50],colorCompoundBrandStroke:e[100],colorCompoundBrandStrokeHover:e[110],colorCompoundBrandStrokePressed:e[90],colorNeutralStrokeDisabled:h,colorNeutralStrokeInvertedDisabled:E,colorTransparentStroke:"transparent",colorTransparentStrokeInteractive:"transparent",colorTransparentStrokeDisabled:"transparent",colorNeutralStrokeAlpha:P,colorNeutralStrokeAlpha2:A,colorStrokeFocus1:L,colorStrokeFocus2:M,colorNeutralShadowAmbient:"rgba(0,0,0,0.24)",colorNeutralShadowKey:"rgba(0,0,0,0.28)",colorNeutralShadowAmbientLighter:"rgba(0,0,0,0.12)",colorNeutralShadowKeyLighter:"rgba(0,0,0,0.14)",colorNeutralShadowAmbientDarker:"rgba(0,0,0,0.40)",colorNeutralShadowKeyDarker:"rgba(0,0,0,0.48)",colorBrandShadowAmbient:"rgba(0,0,0,0.30)",colorBrandShadowKey:"rgba(0,0,0,0.25)"}))(e);return{...q,...J,...Q,...te,...ee,...de,...le,...ce,...X,...Y,...t,...fe,...me,...ue(t.colorNeutralShadowAmbient,t.colorNeutralShadowKey),...ue(t.colorBrandShadowAmbient,t.colorBrandShadowKey,"Brand")}},ye={colorNeutralStencil1:"#E6E6E6",dealBackground:"linear-gradient(139deg, rgba(239, 250, 255, 0.5) 5.76%, rgba(214, 222, 255, 0.5) 100%), #fff)"},Ce={colorNeutralStencil1:"#999999",dealBackground:"linear-gradient(90deg, #050f8d -0.77%, #0077d4 100%)"},be={colorPaletteYellowForeground1:"#F5C32F",colorPaletteRedForeground1:"#D63600",colorPaletteGreenForeground1:"#138757"},Se={colorPaletteRedForeground1:"#F76A3B",colorPaletteGreenForeground1:"#44D498",colorPaletteYellowForeground1:"#F5C32F"},xe={10:"#151B29",20:"#1A2338",30:"#202E4F",40:"#243966",50:"#264587",60:"#2551A8",70:"#235CCF",80:"#2169EB",90:"#3275F0",100:"#4082F5",110:"#4D8DFA",120:"#69A1FA",130:"#86B3FC",140:"#A7C9FC",150:"#C4DCFF",160:"#E0EDFF"},Te=he(xe),we=ve(xe),Oe={...Te,...ye,colorBrandForegroundInverted:xe[110],colorBrandForegroundInvertedHover:xe[120],colorBrandForegroundInvertedPressed:xe[130]},Pe={...Te,...be},Ae={...we,...Ce,colorCompoundBrandBackground:xe[110],colorCompoundBrandBackgroundHover:xe[120],colorCompoundBrandBackgroundPressed:xe[130],colorBrandForeground1:xe[110],colorBrandForeground2:xe[120],colorBrandForegroundLink:xe[110],colorBrandForegroundLinkHover:xe[120],colorBrandForegroundLinkPressed:xe[130],colorBrandForegroundLinkSelected:xe[110],colorCompoundBrandForeground1:xe[110],colorCompoundBrandForeground1Hover:xe[120],colorCompoundBrandForeground1Pressed:xe[130],colorBrandStroke1:xe[110],colorCompoundBrandStroke:xe[110],colorCompoundBrandStrokeHover:xe[120],colorCompoundBrandStrokePressed:xe[130]},Ee={...we,...Se},ke={lineHeightBase100:"14px",lineHeightBase200:"16px",lineHeightBase300:"20px",lineHeightBase400:"22px",lineHeightBase500:"28px",lineHeightBase600:"32px",lineHeightHero700:"42px",lineHeightHero800:"40px",lineHeightHero900:"52px",lineHeightHero1000:"92px"},Ie={...Oe,...Pe,...ke},De={...Ae,...Ee,...ke},_e={10:"#151B29",20:"#1A2338",30:"#202E4F",40:"#243966",50:"#264587",60:"#2551A8",70:"#235CCF",80:"#2169EB",90:"#3275F0",100:"#4082F5",110:"#4D8DFA",120:"#69A1FA",130:"#86B3FC",140:"#A7C9FC",150:"#C4DCFF",160:"#E0EDFF"},Ne=he(_e),Re=ve(_e),Me={...Ne,...ye,colorBrandForegroundInverted:_e[110],colorBrandForegroundInvertedHover:_e[120],colorBrandForegroundInvertedPressed:_e[130]},Le={...Re,...Ce,colorCompoundBrandBackground:_e[110],colorCompoundBrandBackgroundHover:_e[120],colorCompoundBrandBackgroundPressed:_e[130],colorBrandForeground1:_e[110],colorBrandForeground2:_e[120],colorBrandForegroundLink:_e[110],colorBrandForegroundLinkHover:_e[120],colorBrandForegroundLinkPressed:_e[130],colorBrandForegroundLinkSelected:_e[110],colorCompoundBrandForeground1:_e[110],colorCompoundBrandForeground1Hover:_e[120],colorCompoundBrandForeground1Pressed:_e[130],colorBrandStroke1:_e[110],colorCompoundBrandStroke:_e[110],colorCompoundBrandStrokeHover:_e[120],colorCompoundBrandStrokePressed:_e[130]},Be={...Ne,...be},Fe={...Re,...Se},Ue={fontFamilyBase:"'Roboto', 'Helvetica Neue', -apple-system, BlinkMacSystemFont, 'Arial', sans-serif",fontFamilyMonospace:"'Roboto Mono', 'Consolas', 'Menlo', 'Monaco', 'Lucida Console', monospace",fontFamilyNumeric:"'Roboto', 'Helvetica Neue', -apple-system, BlinkMacSystemFont, 'Helvetica', 'Arial', sans-serif"},He={lineHeightBase100:"14px",lineHeightBase200:"18px",lineHeightBase300:"20px",lineHeightBase400:"24px",lineHeightBase500:"32px",lineHeightBase600:"34px",lineHeightHero700:"42px",lineHeightHero800:"46px",lineHeightHero900:"52px",lineHeightHero1000:"92px"},$e={fontWeightRegular:200,fontWeightMedium:400,fontWeightSemibold:600,fontWeightBold:800},Ze={edge:{label:"Edge Shopping",light:Ie,dark:De,brandVariants:xe},bing:{label:"Bing Products",light:{...Me,...Be,...Ue,...He,...$e},dark:{...Le,...Fe,...Ue,...He,...$e},brandVariants:_e}}},63853:function(e,t,i){"use strict";i.d(t,{Cp:function(){return u},RR:function(){return l},US:function(){return a},cv:function(){return h},dp:function(){return f},dr:function(){return g},oo:function(){return r},uY:function(){return p},x7:function(){return s}});var n=i(160);function o(e,t,i){let{reference:o,floating:r}=e;const a=(0,n.Qq)(t),s=(0,n.Wh)(t),l=(0,n.I4)(s),c=(0,n.k3)(t),d="y"===a,u=o.x+o.width/2-r.width/2,h=o.y+o.height/2-r.height/2,p=o[l]/2-r[l]/2;let g;switch(c){case"top":g={x:u,y:o.y-r.height};break;case"bottom":g={x:u,y:o.y+o.height};break;case"right":g={x:o.x+o.width,y:h};break;case"left":g={x:o.x-r.width,y:h};break;default:g={x:o.x,y:o.y}}switch((0,n.hp)(t)){case"start":g[s]-=p*(i&&d?-1:1);break;case"end":g[s]+=p*(i&&d?-1:1)}return g}const r=async(e,t,i)=>{const{placement:n="bottom",strategy:r="absolute",middleware:a=[],platform:s}=i,l=a.filter(Boolean),c=await(null==s.isRTL?void 0:s.isRTL(t));let d=await s.getElementRects({reference:e,floating:t,strategy:r}),{x:u,y:h}=o(d,n,c),p=n,g={},f=0;for(let i=0;i<l.length;i++){const{name:a,fn:m}=l[i],{x:v,y:y,data:C,reset:b}=await m({x:u,y:h,initialPlacement:n,placement:p,strategy:r,middlewareData:g,rects:d,platform:s,elements:{reference:e,floating:t}});u=null!=v?v:u,h=null!=y?y:h,g={...g,[a]:{...g[a],...C}},b&&f<=50&&(f++,"object"==typeof b&&(b.placement&&(p=b.placement),b.rects&&(d=!0===b.rects?await s.getElementRects({reference:e,floating:t,strategy:r}):b.rects),({x:u,y:h}=o(d,p,c))),i=-1)}return{x:u,y:h,placement:p,strategy:r,middlewareData:g}};async function a(e,t){var i;void 0===t&&(t={});const{x:o,y:r,platform:a,rects:s,elements:l,strategy:c}=e,{boundary:d="clippingAncestors",rootBoundary:u="viewport",elementContext:h="floating",altBoundary:p=!1,padding:g=0}=(0,n.ku)(t,e),f=(0,n.yd)(g),m=l[p?"floating"===h?"reference":"floating":h],v=(0,n.JB)(await a.getClippingRect({element:null==(i=await(null==a.isElement?void 0:a.isElement(m)))||i?m:m.contextElement||await(null==a.getDocumentElement?void 0:a.getDocumentElement(l.floating)),boundary:d,rootBoundary:u,strategy:c})),y="floating"===h?{...s.floating,x:o,y:r}:s.reference,C=await(null==a.getOffsetParent?void 0:a.getOffsetParent(l.floating)),b=await(null==a.isElement?void 0:a.isElement(C))&&await(null==a.getScale?void 0:a.getScale(C))||{x:1,y:1},S=(0,n.JB)(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({rect:y,offsetParent:C,strategy:c}):y);return{top:(v.top-S.top+f.top)/b.y,bottom:(S.bottom-v.bottom+f.bottom)/b.y,left:(v.left-S.left+f.left)/b.x,right:(S.right-v.right+f.right)/b.x}}const s=e=>({name:"arrow",options:e,async fn(t){const{x:i,y:o,placement:r,rects:a,platform:s,elements:l,middlewareData:c}=t,{element:d,padding:u=0}=(0,n.ku)(e,t)||{};if(null==d)return{};const h=(0,n.yd)(u),p={x:i,y:o},g=(0,n.Wh)(r),f=(0,n.I4)(g),m=await s.getDimensions(d),v="y"===g,y=v?"top":"left",C=v?"bottom":"right",b=v?"clientHeight":"clientWidth",S=a.reference[f]+a.reference[g]-p[g]-a.floating[f],x=p[g]-a.reference[g],T=await(null==s.getOffsetParent?void 0:s.getOffsetParent(d));let w=T?T[b]:0;w&&await(null==s.isElement?void 0:s.isElement(T))||(w=l.floating[b]||a.floating[f]);const O=S/2-x/2,P=w/2-m[f]/2-1,A=(0,n.VV)(h[y],P),E=(0,n.VV)(h[C],P),k=A,I=w-m[f]-E,D=w/2-m[f]/2+O,_=(0,n.uZ)(k,D,I),N=!c.arrow&&null!=(0,n.hp)(r)&&D!=_&&a.reference[f]/2-(D<k?A:E)-m[f]/2<0,R=N?D<k?D-k:D-I:0;return{[g]:p[g]+R,data:{[g]:_,centerOffset:D-_-R,...N&&{alignmentOffset:R}},reset:N}}}),l=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var i,o;const{placement:r,middlewareData:s,rects:l,initialPlacement:c,platform:d,elements:u}=t,{mainAxis:h=!0,crossAxis:p=!0,fallbackPlacements:g,fallbackStrategy:f="bestFit",fallbackAxisSideDirection:m="none",flipAlignment:v=!0,...y}=(0,n.ku)(e,t);if(null!=(i=s.arrow)&&i.alignmentOffset)return{};const C=(0,n.k3)(r),b=(0,n.k3)(c)===c,S=await(null==d.isRTL?void 0:d.isRTL(u.floating)),x=g||(b||!v?[(0,n.pw)(c)]:(0,n.gy)(c));g||"none"===m||x.push(...(0,n.KX)(c,v,m,S));const T=[c,...x],w=await a(t,y),O=[];let P=(null==(o=s.flip)?void 0:o.overflows)||[];if(h&&O.push(w[C]),p){const e=(0,n.i8)(r,l,S);O.push(w[e[0]],w[e[1]])}if(P=[...P,{placement:r,overflows:O}],!O.every((e=>e<=0))){var A,E;const e=((null==(A=s.flip)?void 0:A.index)||0)+1,t=T[e];if(t)return{data:{index:e,overflows:P},reset:{placement:t}};let i=null==(E=P.filter((e=>e.overflows[0]<=0)).sort(((e,t)=>e.overflows[1]-t.overflows[1]))[0])?void 0:E.placement;if(!i)switch(f){case"bestFit":{var k;const e=null==(k=P.map((e=>[e.placement,e.overflows.filter((e=>e>0)).reduce(((e,t)=>e+t),0)])).sort(((e,t)=>e[1]-t[1]))[0])?void 0:k[0];e&&(i=e);break}case"initialPlacement":i=c}if(r!==i)return{reset:{placement:i}}}return{}}}};function c(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function d(e){return n.mA.some((t=>e[t]>=0))}const u=function(e){return void 0===e&&(e={}),{name:"hide",options:e,async fn(t){const{rects:i}=t,{strategy:o="referenceHidden",...r}=(0,n.ku)(e,t);switch(o){case"referenceHidden":{const e=c(await a(t,{...r,elementContext:"reference"}),i.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:d(e)}}}case"escaped":{const e=c(await a(t,{...r,altBoundary:!0}),i.floating);return{data:{escapedOffsets:e,escaped:d(e)}}}default:return{}}}}},h=function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){const{x:i,y:o}=t,r=await async function(e,t){const{placement:i,platform:o,elements:r}=e,a=await(null==o.isRTL?void 0:o.isRTL(r.floating)),s=(0,n.k3)(i),l=(0,n.hp)(i),c="y"===(0,n.Qq)(i),d=["left","top"].includes(s)?-1:1,u=a&&c?-1:1,h=(0,n.ku)(t,e);let{mainAxis:p,crossAxis:g,alignmentAxis:f}="number"==typeof h?{mainAxis:h,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...h};return l&&"number"==typeof f&&(g="end"===l?-1*f:f),c?{x:g*u,y:p*d}:{x:p*d,y:g*u}}(t,e);return{x:i+r.x,y:o+r.y,data:r}}}},p=function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(t){const{x:i,y:o,placement:r}=t,{mainAxis:s=!0,crossAxis:l=!1,limiter:c={fn:e=>{let{x:t,y:i}=e;return{x:t,y:i}}},...d}=(0,n.ku)(e,t),u={x:i,y:o},h=await a(t,d),p=(0,n.Qq)((0,n.k3)(r)),g=(0,n.Rn)(p);let f=u[g],m=u[p];if(s){const e="y"===g?"bottom":"right",t=f+h["y"===g?"top":"left"],i=f-h[e];f=(0,n.uZ)(t,f,i)}if(l){const e="y"===p?"bottom":"right",t=m+h["y"===p?"top":"left"],i=m-h[e];m=(0,n.uZ)(t,m,i)}const v=c.fn({...t,[g]:f,[p]:m});return{...v,data:{x:v.x-i,y:v.y-o}}}}},g=function(e){return void 0===e&&(e={}),{options:e,fn(t){const{x:i,y:o,placement:r,rects:a,middlewareData:s}=t,{offset:l=0,mainAxis:c=!0,crossAxis:d=!0}=(0,n.ku)(e,t),u={x:i,y:o},h=(0,n.Qq)(r),p=(0,n.Rn)(h);let g=u[p],f=u[h];const m=(0,n.ku)(l,t),v="number"==typeof m?{mainAxis:m,crossAxis:0}:{mainAxis:0,crossAxis:0,...m};if(c){const e="y"===p?"height":"width",t=a.reference[p]-a.floating[e]+v.mainAxis,i=a.reference[p]+a.reference[e]-v.mainAxis;g<t?g=t:g>i&&(g=i)}if(d){var y,C;const e="y"===p?"width":"height",t=["top","left"].includes((0,n.k3)(r)),i=a.reference[h]-a.floating[e]+(t&&(null==(y=s.offset)?void 0:y[h])||0)+(t?0:v.crossAxis),o=a.reference[h]+a.reference[e]+(t?0:(null==(C=s.offset)?void 0:C[h])||0)-(t?v.crossAxis:0);f<i?f=i:f>o&&(f=o)}return{[p]:g,[h]:f}}}},f=function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){const{placement:i,rects:o,platform:r,elements:s}=t,{apply:l=(()=>{}),...c}=(0,n.ku)(e,t),d=await a(t,c),u=(0,n.k3)(i),h=(0,n.hp)(i),p="y"===(0,n.Qq)(i),{width:g,height:f}=o.floating;let m,v;"top"===u||"bottom"===u?(m=u,v=h===(await(null==r.isRTL?void 0:r.isRTL(s.floating))?"start":"end")?"left":"right"):(v=u,m="end"===h?"top":"bottom");const y=f-d[m],C=g-d[v],b=!t.middlewareData.shift;let S=y,x=C;if(p){const e=g-d.left-d.right;x=h||b?(0,n.VV)(C,e):e}else{const e=f-d.top-d.bottom;S=h||b?(0,n.VV)(y,e):e}if(b&&!h){const e=(0,n.Fp)(d.left,0),t=(0,n.Fp)(d.right,0),i=(0,n.Fp)(d.top,0),o=(0,n.Fp)(d.bottom,0);p?x=g-2*(0!==e||0!==t?e+t:(0,n.Fp)(d.left,d.right)):S=f-2*(0!==i||0!==o?i+o:(0,n.Fp)(d.top,d.bottom))}await l({...t,availableWidth:x,availableHeight:S});const T=await r.getDimensions(s.floating);return g!==T.width||f!==T.height?{reset:{rects:!0}}:{}}}}},22256:function(e,t,i){"use strict";i.d(t,{Me:function(){return M},oo:function(){return L}});var n=i(160),o=i(63853);function r(e){return l(e)?(e.nodeName||"").toLowerCase():"#document"}function a(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function s(e){var t;return null==(t=(l(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function l(e){return e instanceof Node||e instanceof a(e).Node}function c(e){return e instanceof Element||e instanceof a(e).Element}function d(e){return e instanceof HTMLElement||e instanceof a(e).HTMLElement}function u(e){return"undefined"!=typeof ShadowRoot&&(e instanceof ShadowRoot||e instanceof a(e).ShadowRoot)}function h(e){const{overflow:t,overflowX:i,overflowY:n,display:o}=v(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+i)&&!["inline","contents"].includes(o)}function p(e){return["table","td","th"].includes(r(e))}function g(e){const t=f(),i=v(e);return"none"!==i.transform||"none"!==i.perspective||!!i.containerType&&"normal"!==i.containerType||!t&&!!i.backdropFilter&&"none"!==i.backdropFilter||!t&&!!i.filter&&"none"!==i.filter||["transform","perspective","filter"].some((e=>(i.willChange||"").includes(e)))||["paint","layout","strict","content"].some((e=>(i.contain||"").includes(e)))}function f(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function m(e){return["html","body","#document"].includes(r(e))}function v(e){return a(e).getComputedStyle(e)}function y(e){return c(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function C(e){if("html"===r(e))return e;const t=e.assignedSlot||e.parentNode||u(e)&&e.host||s(e);return u(t)?t.host:t}function b(e){const t=C(e);return m(t)?e.ownerDocument?e.ownerDocument.body:e.body:d(t)&&h(t)?t:b(t)}function S(e,t,i){var n;void 0===t&&(t=[]),void 0===i&&(i=!0);const o=b(e),r=o===(null==(n=e.ownerDocument)?void 0:n.body),s=a(o);return r?t.concat(s,s.visualViewport||[],h(o)?o:[],s.frameElement&&i?S(s.frameElement):[]):t.concat(o,S(o,[],i))}function x(e){const t=v(e);let i=parseFloat(t.width)||0,o=parseFloat(t.height)||0;const r=d(e),a=r?e.offsetWidth:i,s=r?e.offsetHeight:o,l=(0,n.NM)(i)!==a||(0,n.NM)(o)!==s;return l&&(i=a,o=s),{width:i,height:o,$:l}}function T(e){return c(e)?e:e.contextElement}function w(e){const t=T(e);if(!d(t))return(0,n.ze)(1);const i=t.getBoundingClientRect(),{width:o,height:r,$:a}=x(t);let s=(a?(0,n.NM)(i.width):i.width)/o,l=(a?(0,n.NM)(i.height):i.height)/r;return s&&Number.isFinite(s)||(s=1),l&&Number.isFinite(l)||(l=1),{x:s,y:l}}const O=(0,n.ze)(0);function P(e){const t=a(e);return f()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:O}function A(e,t,i,o){void 0===t&&(t=!1),void 0===i&&(i=!1);const r=e.getBoundingClientRect(),s=T(e);let l=(0,n.ze)(1);t&&(o?c(o)&&(l=w(o)):l=w(e));const d=function(e,t,i){return void 0===t&&(t=!1),!(!i||t&&i!==a(e))&&t}(s,i,o)?P(s):(0,n.ze)(0);let u=(r.left+d.x)/l.x,h=(r.top+d.y)/l.y,p=r.width/l.x,g=r.height/l.y;if(s){const e=a(s),t=o&&c(o)?a(o):o;let i=e.frameElement;for(;i&&o&&t!==e;){const e=w(i),t=i.getBoundingClientRect(),n=v(i),o=t.left+(i.clientLeft+parseFloat(n.paddingLeft))*e.x,r=t.top+(i.clientTop+parseFloat(n.paddingTop))*e.y;u*=e.x,h*=e.y,p*=e.x,g*=e.y,u+=o,h+=r,i=a(i).frameElement}}return(0,n.JB)({width:p,height:g,x:u,y:h})}function E(e){return A(s(e)).left+y(e).scrollLeft}function k(e,t,i){let o;if("viewport"===t)o=function(e,t){const i=a(e),n=s(e),o=i.visualViewport;let r=n.clientWidth,l=n.clientHeight,c=0,d=0;if(o){r=o.width,l=o.height;const e=f();(!e||e&&"fixed"===t)&&(c=o.offsetLeft,d=o.offsetTop)}return{width:r,height:l,x:c,y:d}}(e,i);else if("document"===t)o=function(e){const t=s(e),i=y(e),o=e.ownerDocument.body,r=(0,n.Fp)(t.scrollWidth,t.clientWidth,o.scrollWidth,o.clientWidth),a=(0,n.Fp)(t.scrollHeight,t.clientHeight,o.scrollHeight,o.clientHeight);let l=-i.scrollLeft+E(e);const c=-i.scrollTop;return"rtl"===v(o).direction&&(l+=(0,n.Fp)(t.clientWidth,o.clientWidth)-r),{width:r,height:a,x:l,y:c}}(s(e));else if(c(t))o=function(e,t){const i=A(e,!0,"fixed"===t),o=i.top+e.clientTop,r=i.left+e.clientLeft,a=d(e)?w(e):(0,n.ze)(1);return{width:e.clientWidth*a.x,height:e.clientHeight*a.y,x:r*a.x,y:o*a.y}}(t,i);else{const i=P(e);o={...t,x:t.x-i.x,y:t.y-i.y}}return(0,n.JB)(o)}function I(e,t){const i=C(e);return!(i===t||!c(i)||m(i))&&("fixed"===v(i).position||I(i,t))}function D(e,t,i){const o=d(t),a=s(t),l="fixed"===i,c=A(e,!0,l,t);let u={scrollLeft:0,scrollTop:0};const p=(0,n.ze)(0);if(o||!o&&!l)if(("body"!==r(t)||h(a))&&(u=y(t)),o){const e=A(t,!0,l,t);p.x=e.x+t.clientLeft,p.y=e.y+t.clientTop}else a&&(p.x=E(a));return{x:c.left+u.scrollLeft-p.x,y:c.top+u.scrollTop-p.y,width:c.width,height:c.height}}function _(e,t){return d(e)&&"fixed"!==v(e).position?t?t(e):e.offsetParent:null}function N(e,t){const i=a(e);if(!d(e))return i;let n=_(e,t);for(;n&&p(n)&&"static"===v(n).position;)n=_(n,t);return n&&("html"===r(n)||"body"===r(n)&&"static"===v(n).position&&!g(n))?i:n||function(e){let t=C(e);for(;d(t)&&!m(t);){if(g(t))return t;t=C(t)}return null}(e)||i}const R={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{rect:t,offsetParent:i,strategy:o}=e;const a=d(i),l=s(i);if(i===l)return t;let c={scrollLeft:0,scrollTop:0},u=(0,n.ze)(1);const p=(0,n.ze)(0);if((a||!a&&"fixed"!==o)&&(("body"!==r(i)||h(l))&&(c=y(i)),d(i))){const e=A(i);u=w(i),p.x=e.x+i.clientLeft,p.y=e.y+i.clientTop}return{width:t.width*u.x,height:t.height*u.y,x:t.x*u.x-c.scrollLeft*u.x+p.x,y:t.y*u.y-c.scrollTop*u.y+p.y}},getDocumentElement:s,getClippingRect:function(e){let{element:t,boundary:i,rootBoundary:o,strategy:a}=e;const s=[..."clippingAncestors"===i?function(e,t){const i=t.get(e);if(i)return i;let n=S(e,[],!1).filter((e=>c(e)&&"body"!==r(e))),o=null;const a="fixed"===v(e).position;let s=a?C(e):e;for(;c(s)&&!m(s);){const t=v(s),i=g(s);i||"fixed"!==t.position||(o=null),(a?!i&&!o:!i&&"static"===t.position&&o&&["absolute","fixed"].includes(o.position)||h(s)&&!i&&I(e,s))?n=n.filter((e=>e!==s)):o=t,s=C(s)}return t.set(e,n),n}(t,this._c):[].concat(i),o],l=s[0],d=s.reduce(((e,i)=>{const o=k(t,i,a);return e.top=(0,n.Fp)(o.top,e.top),e.right=(0,n.VV)(o.right,e.right),e.bottom=(0,n.VV)(o.bottom,e.bottom),e.left=(0,n.Fp)(o.left,e.left),e}),k(t,l,a));return{width:d.right-d.left,height:d.bottom-d.top,x:d.left,y:d.top}},getOffsetParent:N,getElementRects:async function(e){let{reference:t,floating:i,strategy:n}=e;const o=this.getOffsetParent||N,r=this.getDimensions;return{reference:D(t,await o(i),n),floating:{x:0,y:0,...await r(i)}}},getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){return x(e)},getScale:w,isElement:c,isRTL:function(e){return"rtl"===v(e).direction}};function M(e,t,i,o){void 0===o&&(o={});const{ancestorScroll:r=!0,ancestorResize:a=!0,elementResize:l="function"==typeof ResizeObserver,layoutShift:c="function"==typeof IntersectionObserver,animationFrame:d=!1}=o,u=T(e),h=r||a?[...u?S(u):[],...S(t)]:[];h.forEach((e=>{r&&e.addEventListener("scroll",i,{passive:!0}),a&&e.addEventListener("resize",i)}));const p=u&&c?function(e,t){let i,o=null;const r=s(e);function a(){clearTimeout(i),o&&o.disconnect(),o=null}return function s(l,c){void 0===l&&(l=!1),void 0===c&&(c=1),a();const{left:d,top:u,width:h,height:p}=e.getBoundingClientRect();if(l||t(),!h||!p)return;const g={rootMargin:-(0,n.GW)(u)+"px "+-(0,n.GW)(r.clientWidth-(d+h))+"px "+-(0,n.GW)(r.clientHeight-(u+p))+"px "+-(0,n.GW)(d)+"px",threshold:(0,n.Fp)(0,(0,n.VV)(1,c))||1};let f=!0;function m(e){const t=e[0].intersectionRatio;if(t!==c){if(!f)return s();t?s(!1,t):i=setTimeout((()=>{s(!1,1e-7)}),100)}f=!1}try{o=new IntersectionObserver(m,{...g,root:r.ownerDocument})}catch(e){o=new IntersectionObserver(m,g)}o.observe(e)}(!0),a}(u,i):null;let g,f=-1,m=null;l&&(m=new ResizeObserver((e=>{let[n]=e;n&&n.target===u&&m&&(m.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame((()=>{m&&m.observe(t)}))),i()})),u&&!d&&m.observe(u),m.observe(t));let v=d?A(e):null;return d&&function t(){const n=A(e);!v||n.x===v.x&&n.y===v.y&&n.width===v.width&&n.height===v.height||i(),v=n,g=requestAnimationFrame(t)}(),i(),()=>{h.forEach((e=>{r&&e.removeEventListener("scroll",i),a&&e.removeEventListener("resize",i)})),p&&p(),m&&m.disconnect(),m=null,d&&cancelAnimationFrame(g)}}const L=(e,t,i)=>{const n=new Map,r={platform:R,...i},a={...r.platform,_c:n};return(0,o.oo)(e,t,{...r,platform:a})}},160:function(e,t,i){"use strict";i.d(t,{Fp:function(){return r},GW:function(){return s},I4:function(){return m},JB:function(){return O},KX:function(){return x},NM:function(){return a},Qq:function(){return v},Rn:function(){return f},VV:function(){return o},Wh:function(){return y},gy:function(){return b},hp:function(){return g},i8:function(){return C},k3:function(){return p},ku:function(){return h},mA:function(){return n},pw:function(){return T},uZ:function(){return u},yd:function(){return w},ze:function(){return l}});const n=["top","right","bottom","left"],o=Math.min,r=Math.max,a=Math.round,s=Math.floor,l=e=>({x:e,y:e}),c={left:"right",right:"left",bottom:"top",top:"bottom"},d={start:"end",end:"start"};function u(e,t,i){return r(e,o(t,i))}function h(e,t){return"function"==typeof e?e(t):e}function p(e){return e.split("-")[0]}function g(e){return e.split("-")[1]}function f(e){return"x"===e?"y":"x"}function m(e){return"y"===e?"height":"width"}function v(e){return["top","bottom"].includes(p(e))?"y":"x"}function y(e){return f(v(e))}function C(e,t,i){void 0===i&&(i=!1);const n=g(e),o=y(e),r=m(o);let a="x"===o?n===(i?"end":"start")?"right":"left":"start"===n?"bottom":"top";return t.reference[r]>t.floating[r]&&(a=T(a)),[a,T(a)]}function b(e){const t=T(e);return[S(e),t,S(t)]}function S(e){return e.replace(/start|end/g,(e=>d[e]))}function x(e,t,i,n){const o=g(e);let r=function(e,t,i){const n=["left","right"],o=["right","left"],r=["top","bottom"],a=["bottom","top"];switch(e){case"top":case"bottom":return i?t?o:n:t?n:o;case"left":case"right":return t?r:a;default:return[]}}(p(e),"start"===i,n);return o&&(r=r.map((e=>e+"-"+o)),t&&(r=r.concat(r.map(S)))),r}function T(e){return e.replace(/left|right|bottom|top/g,(e=>c[e]))}function w(e){return"number"!=typeof e?function(e){return{top:0,right:0,bottom:0,left:0,...e}}(e):{top:e,right:e,bottom:e,left:e}}function O(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}},37328:function(e,t,i){"use strict";i.d(t,{PJ:function(){return u},hP:function(){return p},DR:function(){return f},lw:function(){return h},v1:function(){return g},hM:function(){return l}});var n=i(3179),o=i(58168),r=i(5302),a=i(63375);class s{constructor(e,t,i){this.x=e,this.y=t,this.z=i}static fromObject(e){return!e||isNaN(e.x)||isNaN(e.y)||isNaN(e.z)?null:new s(e.x,e.y,e.z)}equalValue(e){return this.x===e.x&&this.y===e.y&&this.z===e.z}roundToPrecision(e){return new s((0,a.fZ)(this.x,e),(0,a.fZ)(this.y,e),(0,a.fZ)(this.z,e))}toObject(){return{x:this.x,y:this.y,z:this.z}}}function l(e){function t(e){return e<=.03928?e/12.92:Math.pow((e+.055)/1.055,2.4)}return function(e){return.2126*e.r+.7152*e.g+.0722*e.b}(new r.h(t(e.r),t(e.g),t(e.b),1))}function c(e,t,i){return i-t==0?0:(e-t)/(i-t)}function d(e,t,i){return(c(e.r,t.r,i.r)+c(e.g,t.g,i.g)+c(e.b,t.b,i.b))/3}function u(e,t,i=null){let n=0,o=i;return null!==o?n=d(e,t,o):(o=new r.h(0,0,0,1),n=d(e,t,o),n<=0&&(o=new r.h(1,1,1,1),n=d(e,t,o))),n=Math.round(1e3*n)/1e3,new r.h(o.r,o.g,o.b,n)}function h(e){const t=Math.max(e.r,e.g,e.b),i=Math.min(e.r,e.g,e.b),o=t-i;let r=0;0!==o&&(r=t===e.r?(e.g-e.b)/o%6*60:t===e.g?60*((e.b-e.r)/o+2):60*((e.r-e.g)/o+4)),r<0&&(r+=360);const a=(t+i)/2;let s=0;return 0!==o&&(s=o/(1-Math.abs(2*a-1))),new n.H(r,s,a)}function p(e,t=1){const i=(1-Math.abs(2*e.l-1))*e.s,n=i*(1-Math.abs(e.h/60%2-1)),o=e.l-i/2;let a=0,s=0,l=0;return e.h<60?(a=i,s=n,l=0):e.h<120?(a=n,s=i,l=0):e.h<180?(a=0,s=i,l=n):e.h<240?(a=0,s=n,l=i):e.h<300?(a=n,s=0,l=i):e.h<360&&(a=i,s=0,l=n),new r.h(a+o,s+o,l+o,t)}function g(e){return function(e){function t(e){return e>o.R.epsilon?Math.pow(e,1/3):(o.R.kappa*e+16)/116}const i=t(e.x/s.whitePoint.x),n=t(e.y/s.whitePoint.y),r=116*n-16,a=500*(i-n),l=200*(n-t(e.z/s.whitePoint.z));return new o.R(r,a,l)}(function(e){function t(e){return e<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}const i=t(e.r),n=t(e.g),o=t(e.b);return new s(.4124564*i+.3575761*n+.1804375*o,.2126729*i+.7151522*n+.072175*o,.0193339*i+.119192*n+.9503041*o)}(e))}function f(e,t=1){return function(e,t=1){function i(e){return e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055}const n=i(3.2404542*e.x-1.5371385*e.y-.4985314*e.z),o=i(-.969266*e.x+1.8760108*e.y+.041556*e.z),a=i(.0556434*e.x-.2040259*e.y+1.0572252*e.z);return new r.h(n,o,a,t)}(function(e){const t=(e.l+16)/116,i=t+e.a/500,n=t-e.b/200,r=Math.pow(i,3),a=Math.pow(t,3),l=Math.pow(n,3);let c=0;c=r>o.R.epsilon?r:(116*i-16)/o.R.kappa;let d=0;d=e.l>o.R.epsilon*o.R.kappa?a:e.l/o.R.kappa;let u=0;return u=l>o.R.epsilon?l:(116*n-16)/o.R.kappa,c=s.whitePoint.x*c,d=s.whitePoint.y*d,u=s.whitePoint.z*u,new s(c,d,u)}(e),t)}s.whitePoint=new s(.95047,1,1.08883)},3179:function(e,t,i){"use strict";i.d(t,{H:function(){return o}});var n=i(63375);class o{constructor(e,t,i){this.h=e,this.s=t,this.l=i}static fromObject(e){return!e||isNaN(e.h)||isNaN(e.s)||isNaN(e.l)?null:new o(e.h,e.s,e.l)}equalValue(e){return this.h===e.h&&this.s===e.s&&this.l===e.l}roundToPrecision(e){return new o((0,n.fZ)(this.h,e),(0,n.fZ)(this.s,e),(0,n.fZ)(this.l,e))}toObject(){return{h:this.h,s:this.s,l:this.l}}}},58168:function(e,t,i){"use strict";i.d(t,{R:function(){return o}});var n=i(63375);class o{constructor(e,t,i){this.l=e,this.a=t,this.b=i}static fromObject(e){return!e||isNaN(e.l)||isNaN(e.a)||isNaN(e.b)?null:new o(e.l,e.a,e.b)}equalValue(e){return this.l===e.l&&this.a===e.a&&this.b===e.b}roundToPrecision(e){return new o((0,n.fZ)(this.l,e),(0,n.fZ)(this.a,e),(0,n.fZ)(this.b,e))}toObject(){return{l:this.l,a:this.a,b:this.b}}}o.epsilon=216/24389,o.kappa=24389/27},5302:function(e,t,i){"use strict";i.d(t,{h:function(){return o}});var n=i(63375);class o{constructor(e,t,i,n){this.r=e,this.g=t,this.b=i,this.a="number"!=typeof n||isNaN(n)?1:n}static fromObject(e){return!e||isNaN(e.r)||isNaN(e.g)||isNaN(e.b)?null:new o(e.r,e.g,e.b,e.a)}equalValue(e){return this.r===e.r&&this.g===e.g&&this.b===e.b&&this.a===e.a}toStringHexRGB(){return"#"+[this.r,this.g,this.b].map(this.formatHexValue).join("")}toStringHexRGBA(){return this.toStringHexRGB()+this.formatHexValue(this.a)}toStringHexARGB(){return"#"+[this.a,this.r,this.g,this.b].map(this.formatHexValue).join("")}toStringWebRGB(){return`rgb(${Math.round((0,n.cY)(this.r,0,255))},${Math.round((0,n.cY)(this.g,0,255))},${Math.round((0,n.cY)(this.b,0,255))})`}toStringWebRGBA(){return`rgba(${Math.round((0,n.cY)(this.r,0,255))},${Math.round((0,n.cY)(this.g,0,255))},${Math.round((0,n.cY)(this.b,0,255))},${(0,n.uZ)(this.a,0,1)})`}roundToPrecision(e){return new o((0,n.fZ)(this.r,e),(0,n.fZ)(this.g,e),(0,n.fZ)(this.b,e),(0,n.fZ)(this.a,e))}clamp(){return new o((0,n.uZ)(this.r,0,1),(0,n.uZ)(this.g,0,1),(0,n.uZ)(this.b,0,1),(0,n.uZ)(this.a,0,1))}toObject(){return{r:this.r,g:this.g,b:this.b,a:this.a}}formatHexValue(e){return(0,n.yi)((0,n.cY)(e,0,255))}}},63375:function(e,t,i){"use strict";function n(e,t,i){return isNaN(e)||e<=t?t:e>=i?i:e}function o(e,t,i){return isNaN(e)||e<=t?0:e>=i?1:e/(i-t)}function r(e,t,i){return isNaN(e)?t:t+e*(i-t)}function a(e){const t=Math.round(n(e,0,255)).toString(16);return 1===t.length?"0"+t:t}function s(e,t,i){return isNaN(e)||e<=0?t:e>=1?i:t+e*(i-t)}function l(e,t){const i=Math.pow(10,t);return Math.round(e*i)/i}i.d(t,{Fv:function(){return o},cY:function(){return r},fZ:function(){return l},t7:function(){return s},uZ:function(){return n},yi:function(){return a}}),Math.PI},77158:function(e,t,i){"use strict";i.d(t,{in:function(){return a}});var n=i(5302),o=i(63375);const r=/^#((?:[0-9a-f]{6}|[0-9a-f]{3}))$/i;function a(e){const t=r.exec(e);if(null===t)return null;let i=t[1];if(3===i.length){const e=i.charAt(0),t=i.charAt(1),n=i.charAt(2);i=e.concat(e,t,t,n,n)}const a=parseInt(i,16);return isNaN(a)?null:new n.h((0,o.Fv)((16711680&a)>>>16,0,255),(0,o.Fv)((65280&a)>>>8,0,255),(0,o.Fv)(255&a,0,255),1)}},5597:function(e,t,i){"use strict";i.d(t,{Ax:function(){return a},Id:function(){return l},Lj:function(){return d},bw:function(){return s},so:function(){return c}});var n=i(2907),o=i(98557),r=i(18438);const a=Object.freeze({locate:(0,r.j8)()}),s={toView(e){return e?"true":"false"},fromView(e){return null!=e&&"false"!==e&&!1!==e&&0!==e}},l={toView(e){if(null==e)return null;const t=1*e;return isNaN(t)?null:t.toString()},fromView(e){if(null==e)return null;const t=1*e;return isNaN(t)?null:t}};class c{constructor(e,t,i=t.toLowerCase(),n="reflect",o){this.guards=new Set,this.Owner=e,this.name=t,this.attribute=i,this.mode=n,this.converter=o,this.fieldName=`_${t}`,this.callbackName=`${t}Changed`,this.hasCallback=this.callbackName in e.prototype,"boolean"===n&&void 0===o&&(this.converter=s)}setValue(e,t){const i=e[this.fieldName],n=this.converter;void 0!==n&&(t=n.fromView(t)),i!==t&&(e[this.fieldName]=t,this.tryReflectToAttribute(e),this.hasCallback&&e[this.callbackName](i,t),e.$fastController.notify(this.name))}getValue(e){return n.y$.track(e,this.name),e[this.fieldName]}onAttributeChangedCallback(e,t){this.guards.has(e)||(this.guards.add(e),this.setValue(e,t),this.guards.delete(e))}tryReflectToAttribute(e){const t=this.mode,i=this.guards;i.has(e)||"fromView"===t||o.SO.queueUpdate((()=>{i.add(e);const n=e[this.fieldName];switch(t){case"reflect":const t=this.converter;o.SO.setAttribute(e,this.attribute,void 0!==t?t.toView(n):n);break;case"boolean":o.SO.setBooleanAttribute(e,this.attribute,n)}i.delete(e)}))}static collect(e,...t){const i=[];t.push(a.locate(e));for(let n=0,o=t.length;n<o;++n){const o=t[n];if(void 0!==o)for(let t=0,n=o.length;t<n;++t){const n=o[t];"string"==typeof n?i.push(new c(e,n)):i.push(new c(e,n.property,n.attribute,n.mode,n.converter))}}return i}}function d(e,t){let i;function n(e,t){arguments.length>1&&(i.property=t),a.locate(e.constructor).push(i)}return arguments.length>1?(i={},void n(e,t)):(i=void 0===e?{}:e,n)}},72171:function(e,t,i){"use strict";i.d(t,{W:function(){return d}});var n=i(18438),o=i(2907),r=i(2681),a=i(5597);const s={mode:"open"},l={},c=n.Bo.getById(4,(()=>{const e=new Map;return Object.freeze({register(t){return!e.has(t.type)&&(e.set(t.type,t),!0)},getByType(t){return e.get(t)}})}));class d{constructor(e,t=e.definition){"string"==typeof t&&(t={name:t}),this.type=e,this.name=t.name,this.template=t.template;const i=a.so.collect(e,t.attributes),n=new Array(i.length),o={},c={};for(let e=0,t=i.length;e<t;++e){const t=i[e];n[e]=t.attribute,o[t.name]=t,c[t.attribute]=t}this.attributes=i,this.observedAttributes=n,this.propertyLookup=o,this.attributeLookup=c,this.shadowOptions=void 0===t.shadowOptions?s:null===t.shadowOptions?void 0:Object.assign(Object.assign({},s),t.shadowOptions),this.elementOptions=void 0===t.elementOptions?l:Object.assign(Object.assign({},l),t.elementOptions),this.styles=void 0===t.styles?void 0:Array.isArray(t.styles)?r.XL.create(t.styles):t.styles instanceof r.XL?t.styles:r.XL.create([t.styles])}get isDefined(){return!!c.getByType(this.type)}define(e=customElements){const t=this.type;if(c.register(this)){const e=this.attributes,i=t.prototype;for(let t=0,n=e.length;t<n;++t)o.y$.defineProperty(i,e[t]);Reflect.defineProperty(t,"observedAttributes",{value:this.observedAttributes,enumerable:!0})}return e.get(this.name)||e.define(this.name,t,this.elementOptions),this}}d.forType=c.getByType},2816:function(e,t,i){"use strict";i.d(t,{H:function(){return h}});var n=i(98557),o=i(55208),r=i(2907),a=i(72171);const s=new WeakMap,l={bubbles:!0,composed:!0,cancelable:!0};function c(e){return e.shadowRoot||s.get(e)||null}class d extends o.A{constructor(e,t){super(e),this.boundObservables=null,this.behaviors=null,this.needsInitialization=!0,this._template=null,this._styles=null,this._isConnected=!1,this.$fastController=this,this.view=null,this.element=e,this.definition=t;const i=t.shadowOptions;if(void 0!==i){const t=e.attachShadow(i);"closed"===i.mode&&s.set(e,t)}const n=r.y$.getAccessors(e);if(n.length>0){const t=this.boundObservables=Object.create(null);for(let i=0,o=n.length;i<o;++i){const o=n[i].name,r=e[o];void 0!==r&&(delete e[o],t[o]=r)}}}get isConnected(){return r.y$.track(this,"isConnected"),this._isConnected}setIsConnected(e){this._isConnected=e,r.y$.notify(this,"isConnected")}get template(){return this._template}set template(e){this._template!==e&&(this._template=e,this.needsInitialization||this.renderTemplate(e))}get styles(){return this._styles}set styles(e){this._styles!==e&&(null!==this._styles&&this.removeStyles(this._styles),this._styles=e,this.needsInitialization||null===e||this.addStyles(e))}addStyles(e){const t=c(this.element)||this.element.getRootNode();if(e instanceof HTMLStyleElement)t.append(e);else if(!e.isAttachedTo(t)){const i=e.behaviors;e.addStylesTo(t),null!==i&&this.addBehaviors(i)}}removeStyles(e){const t=c(this.element)||this.element.getRootNode();if(e instanceof HTMLStyleElement)t.removeChild(e);else if(e.isAttachedTo(t)){const i=e.behaviors;e.removeStylesFrom(t),null!==i&&this.removeBehaviors(i)}}addBehaviors(e){const t=this.behaviors||(this.behaviors=new Map),i=e.length,n=[];for(let o=0;o<i;++o){const i=e[o];t.has(i)?t.set(i,t.get(i)+1):(t.set(i,1),n.push(i))}if(this._isConnected){const e=this.element;for(let t=0;t<n.length;++t)n[t].bind(e,r.Wp)}}removeBehaviors(e,t=!1){const i=this.behaviors;if(null===i)return;const n=e.length,o=[];for(let r=0;r<n;++r){const n=e[r];if(i.has(n)){const e=i.get(n)-1;0===e||t?i.delete(n)&&o.push(n):i.set(n,e)}}if(this._isConnected){const e=this.element;for(let t=0;t<o.length;++t)o[t].unbind(e)}}onConnectedCallback(){if(this._isConnected)return;const e=this.element;this.needsInitialization?this.finishInitialization():null!==this.view&&this.view.bind(e,r.Wp);const t=this.behaviors;if(null!==t)for(const[i]of t)i.bind(e,r.Wp);this.setIsConnected(!0)}onDisconnectedCallback(){if(!this._isConnected)return;this.setIsConnected(!1);const e=this.view;null!==e&&e.unbind();const t=this.behaviors;if(null!==t){const e=this.element;for(const[i]of t)i.unbind(e)}}onAttributeChangedCallback(e,t,i){const n=this.definition.attributeLookup[e];void 0!==n&&n.onAttributeChangedCallback(this.element,i)}emit(e,t,i){return!!this._isConnected&&this.element.dispatchEvent(new CustomEvent(e,Object.assign(Object.assign({detail:t},l),i)))}finishInitialization(){const e=this.element,t=this.boundObservables;if(null!==t){const i=Object.keys(t);for(let n=0,o=i.length;n<o;++n){const o=i[n];e[o]=t[o]}this.boundObservables=null}const i=this.definition;null===this._template&&(this.element.resolveTemplate?this._template=this.element.resolveTemplate():i.template&&(this._template=i.template||null)),null!==this._template&&this.renderTemplate(this._template),null===this._styles&&(this.element.resolveStyles?this._styles=this.element.resolveStyles():i.styles&&(this._styles=i.styles||null)),null!==this._styles&&this.addStyles(this._styles),this.needsInitialization=!1}renderTemplate(e){const t=this.element,i=c(t)||t;null!==this.view?(this.view.dispose(),this.view=null):this.needsInitialization||n.SO.removeChildNodes(i),e&&(this.view=e.render(t,i,t))}static forCustomElement(e){const t=e.$fastController;if(void 0!==t)return t;const i=a.W.forType(e.constructor);if(void 0===i)throw new Error("Missing FASTElement definition.");return e.$fastController=new d(e,i)}}function u(e){return class extends e{constructor(){super(),d.forCustomElement(this)}$emit(e,t,i){return this.$fastController.emit(e,t,i)}connectedCallback(){this.$fastController.onConnectedCallback()}disconnectedCallback(){this.$fastController.onDisconnectedCallback()}attributeChangedCallback(e,t,i){this.$fastController.onAttributeChangedCallback(e,t,i)}}}const h=Object.assign(u(HTMLElement),{from(e){return u(e)},define(e,t){return new a.W(e,t).define().type}})},98557:function(e,t,i){"use strict";i.d(t,{SO:function(){return d},Yl:function(){return c},pc:function(){return l}});var n=i(18438);const o=n.P3.FAST.getById(1,(()=>{const e=[],t=[];function i(){if(t.length)throw t.shift()}function o(e){try{e.call()}catch(e){t.push(e),setTimeout(i,0)}}function r(){let t=0;for(;t<e.length;)if(o(e[t]),t++,t>1024){for(let i=0,n=e.length-t;i<n;i++)e[i]=e[i+t];e.length-=t,t=0}e.length=0}return Object.freeze({enqueue:function(t){e.length<1&&n.P3.requestAnimationFrame(r),e.push(t)},process:r})})),r=n.P3.trustedTypes.createPolicy("fast-html",{createHTML:e=>e});let a=r;const s=`fast-${Math.random().toString(36).substring(2,8)}`,l=`${s}{`,c=`}${s}`,d=Object.freeze({supportsAdoptedStyleSheets:Array.isArray(document.adoptedStyleSheets)&&"replace"in CSSStyleSheet.prototype,setHTMLPolicy(e){if(a!==r)throw new Error("The HTML policy can only be set once.");a=e},createHTML(e){return a.createHTML(e)},isMarker(e){return e&&8===e.nodeType&&e.data.startsWith(s)},extractDirectiveIndexFromMarker(e){return parseInt(e.data.replace(`${s}:`,""))},createInterpolationPlaceholder(e){return`${l}${e}${c}`},createCustomAttributePlaceholder(e,t){return`${e}="${this.createInterpolationPlaceholder(t)}"`},createBlockPlaceholder(e){return`\x3c!--${s}:${e}--\x3e`},queueUpdate:o.enqueue,processUpdates:o.process,nextUpdate(){return new Promise(o.enqueue)},setAttribute(e,t,i){null==i?e.removeAttribute(t):e.setAttribute(t,i)},setBooleanAttribute(e,t,i){i?e.setAttribute(t,""):e.removeAttribute(t)},removeChildNodes(e){for(let t=e.firstChild;null!==t;t=e.firstChild)e.removeChild(t)},createTemplateWalker(e){return document.createTreeWalker(e,133,null,!1)}})},55208:function(e,t,i){"use strict";i.d(t,{A:function(){return o},q:function(){return n}});class n{constructor(e,t){this.sub1=void 0,this.sub2=void 0,this.spillover=void 0,this.source=e,this.sub1=t}has(e){return void 0===this.spillover?this.sub1===e||this.sub2===e:-1!==this.spillover.indexOf(e)}subscribe(e){const t=this.spillover;if(void 0===t){if(this.has(e))return;if(void 0===this.sub1)return void(this.sub1=e);if(void 0===this.sub2)return void(this.sub2=e);this.spillover=[this.sub1,this.sub2,e],this.sub1=void 0,this.sub2=void 0}else-1===t.indexOf(e)&&t.push(e)}unsubscribe(e){const t=this.spillover;if(void 0===t)this.sub1===e?this.sub1=void 0:this.sub2===e&&(this.sub2=void 0);else{const i=t.indexOf(e);-1!==i&&t.splice(i,1)}}notify(e){const t=this.spillover,i=this.source;if(void 0===t){const t=this.sub1,n=this.sub2;void 0!==t&&t.handleChange(i,e),void 0!==n&&n.handleChange(i,e)}else for(let n=0,o=t.length;n<o;++n)t[n].handleChange(i,e)}}class o{constructor(e){this.subscribers={},this.sourceSubscribers=null,this.source=e}notify(e){var t;const i=this.subscribers[e];void 0!==i&&i.notify(e),null===(t=this.sourceSubscribers)||void 0===t||t.notify(e)}subscribe(e,t){var i;if(t){let i=this.subscribers[t];void 0===i&&(this.subscribers[t]=i=new n(this.source)),i.subscribe(e)}else this.sourceSubscribers=null!==(i=this.sourceSubscribers)&&void 0!==i?i:new n(this.source),this.sourceSubscribers.subscribe(e)}unsubscribe(e,t){var i;if(t){const i=this.subscribers[t];void 0!==i&&i.unsubscribe(e)}else null===(i=this.sourceSubscribers)||void 0===i||i.unsubscribe(e)}}},2907:function(e,t,i){"use strict";i.d(t,{LO:function(){return s},Wp:function(){return u},lk:function(){return l},rd:function(){return d},y$:function(){return a}});var n=i(98557),o=i(18438),r=i(55208);const a=o.Bo.getById(2,(()=>{const e=/(:|&&|\|\||if)/,t=new WeakMap,i=n.SO.queueUpdate;let a,s=e=>{throw new Error("Must call enableArrayObservation before observing arrays.")};function l(e){let i=e.$fastController||t.get(e);return void 0===i&&(Array.isArray(e)?i=s(e):t.set(e,i=new r.A(e))),i}const c=(0,o.j8)();class d{constructor(e){this.name=e,this.field=`_${e}`,this.callback=`${e}Changed`}getValue(e){return void 0!==a&&a.watch(e,this.name),e[this.field]}setValue(e,t){const i=this.field,n=e[i];if(n!==t){e[i]=t;const o=e[this.callback];"function"==typeof o&&o.call(e,n,t),l(e).notify(this.name)}}}class u extends r.q{constructor(e,t,i=!1){super(e,t),this.binding=e,this.isVolatileBinding=i,this.needsRefresh=!0,this.needsQueue=!0,this.first=this,this.last=null,this.propertySource=void 0,this.propertyName=void 0,this.notifier=void 0,this.next=void 0}observe(e,t){this.needsRefresh&&null!==this.last&&this.disconnect();const i=a;a=this.needsRefresh?this:void 0,this.needsRefresh=this.isVolatileBinding;const n=this.binding(e,t);return a=i,n}disconnect(){if(null!==this.last){let e=this.first;for(;void 0!==e;)e.notifier.unsubscribe(this,e.propertyName),e=e.next;this.last=null,this.needsRefresh=this.needsQueue=!0}}watch(e,t){const i=this.last,n=l(e),o=null===i?this.first:{};if(o.propertySource=e,o.propertyName=t,o.notifier=n,n.subscribe(this,t),null!==i){if(!this.needsRefresh){let t;a=void 0,t=i.propertySource[i.propertyName],a=this,e===t&&(this.needsRefresh=!0)}i.next=o}this.last=o}handleChange(){this.needsQueue&&(this.needsQueue=!1,i(this))}call(){null!==this.last&&(this.needsQueue=!0,this.notify(this))}records(){let e=this.first;return{next:()=>{const t=e;return void 0===t?{value:void 0,done:!0}:(e=e.next,{value:t,done:!1})},[Symbol.iterator]:function(){return this}}}}return Object.freeze({setArrayObserverFactory(e){s=e},getNotifier:l,track(e,t){void 0!==a&&a.watch(e,t)},trackVolatile(){void 0!==a&&(a.needsRefresh=!0)},notify(e,t){l(e).notify(t)},defineProperty(e,t){"string"==typeof t&&(t=new d(t)),c(e).push(t),Reflect.defineProperty(e,t.name,{enumerable:!0,get:function(){return t.getValue(this)},set:function(e){t.setValue(this,e)}})},getAccessors:c,binding(e,t,i=this.isVolatileBinding(e)){return new u(e,t,i)},isVolatileBinding(t){return e.test(t.toString())}})}));function s(e,t){a.defineProperty(e,t)}function l(e,t,i){return Object.assign({},i,{get:function(){return a.trackVolatile(),i.get.apply(this)}})}const c=o.Bo.getById(3,(()=>{let e=null;return{get(){return e},set(t){e=t}}}));class d{constructor(){this.index=0,this.length=0,this.parent=null,this.parentContext=null}get event(){return c.get()}get isEven(){return this.index%2==0}get isOdd(){return this.index%2!=0}get isFirst(){return 0===this.index}get isInMiddle(){return!this.isFirst&&!this.isLast}get isLast(){return this.index===this.length-1}static setEvent(e){c.set(e)}}a.defineProperty(d.prototype,"index"),a.defineProperty(d.prototype,"length");const u=Object.seal(new d)},18438:function(e,t,i){"use strict";i.d(t,{Bo:function(){return r},P3:function(){return n},j8:function(){return s},ow:function(){return a}});const n=function(){if("undefined"!=typeof globalThis)return globalThis;if("undefined"!=typeof global)return global;if("undefined"!=typeof self)return self;if("undefined"!=typeof window)return window;try{return new Function("return this")()}catch(e){return{}}}();void 0===n.trustedTypes&&(n.trustedTypes={createPolicy:(e,t)=>t});const o={configurable:!1,enumerable:!1,writable:!1};void 0===n.FAST&&Reflect.defineProperty(n,"FAST",Object.assign({value:Object.create(null)},o));const r=n.FAST;if(void 0===r.getById){const e=Object.create(null);Reflect.defineProperty(r,"getById",Object.assign({value(t,i){let n=e[t];return void 0===n&&(n=i?e[t]=i():null),n}},o))}const a=Object.freeze([]);function s(){const e=new WeakMap;return function(t){let i=e.get(t);if(void 0===i){let n=Reflect.getPrototypeOf(t);for(;void 0===i&&null!==n;)i=e.get(n),n=Reflect.getPrototypeOf(n);i=void 0===i?[]:i.slice(0),e.set(t,i)}return i}}},85888:function(e,t,i){"use strict";i.d(t,{v:function(){return n}});class n{createCSS(){return""}createBehavior(){}}},2681:function(e,t,i){"use strict";i.d(t,{XL:function(){return o}});var n=i(98557);class o{constructor(){this.targets=new WeakSet}addStylesTo(e){this.targets.add(e)}removeStylesFrom(e){this.targets.delete(e)}isAttachedTo(e){return this.targets.has(e)}withBehaviors(...e){return this.behaviors=null===this.behaviors?e:this.behaviors.concat(e),this}}function r(e){return e.map((e=>e instanceof o?r(e.styles):[e])).reduce(((e,t)=>e.concat(t)),[])}function a(e){return e.map((e=>e instanceof o?e.behaviors:null)).reduce(((e,t)=>null===t?e:(null===e&&(e=[]),e.concat(t))),null)}o.create=(()=>{if(n.SO.supportsAdoptedStyleSheets){const e=new Map;return t=>new c(t,e)}return e=>new u(e)})();let s=(e,t)=>{e.adoptedStyleSheets=[...e.adoptedStyleSheets,...t]},l=(e,t)=>{e.adoptedStyleSheets=e.adoptedStyleSheets.filter((e=>-1===t.indexOf(e)))};if(n.SO.supportsAdoptedStyleSheets)try{document.adoptedStyleSheets.push(),document.adoptedStyleSheets.splice(),s=(e,t)=>{e.adoptedStyleSheets.push(...t)},l=(e,t)=>{for(const i of t){const t=e.adoptedStyleSheets.indexOf(i);-1!==t&&e.adoptedStyleSheets.splice(t,1)}}}catch(e){}class c extends o{constructor(e,t){super(),this.styles=e,this.styleSheetCache=t,this._styleSheets=void 0,this.behaviors=a(e)}get styleSheets(){if(void 0===this._styleSheets){const e=this.styles,t=this.styleSheetCache;this._styleSheets=r(e).map((e=>{if(e instanceof CSSStyleSheet)return e;let i=t.get(e);return void 0===i&&(i=new CSSStyleSheet,i.replaceSync(e),t.set(e,i)),i}))}return this._styleSheets}addStylesTo(e){s(e,this.styleSheets),super.addStylesTo(e)}removeStylesFrom(e){l(e,this.styleSheets),super.removeStylesFrom(e)}}let d=0;class u extends o{constructor(e){super(),this.styles=e,this.behaviors=null,this.behaviors=a(e),this.styleSheets=r(e),this.styleClass="fast-style-class-"+ ++d}addStylesTo(e){const t=this.styleSheets,i=this.styleClass;e=this.normalizeTarget(e);for(let n=0;n<t.length;n++){const o=document.createElement("style");o.innerHTML=t[n],o.className=i,e.append(o)}super.addStylesTo(e)}removeStylesFrom(e){const t=(e=this.normalizeTarget(e)).querySelectorAll(`.${this.styleClass}`);for(let i=0,n=t.length;i<n;++i)e.removeChild(t[i]);super.removeStylesFrom(e)}isAttachedTo(e){return super.isAttachedTo(this.normalizeTarget(e))}normalizeTarget(e){return e===document?document.body:e}}},11127:function(e,t,i){"use strict";i.d(t,{DesignToken:function(){return P}});var n=i(45908),o=i(85888),r=i(2907),a=i(2816),s=i(98584),l=i(98557),c=i(2681);const d=document.createElement("div");class u{setProperty(e,t){l.SO.queueUpdate((()=>this.target.setProperty(e,t)))}removeProperty(e){l.SO.queueUpdate((()=>this.target.removeProperty(e)))}}class h extends u{constructor(){super();const e=new CSSStyleSheet;this.target=e.cssRules[e.insertRule(":root{}")].style,document.adoptedStyleSheets=[...document.adoptedStyleSheets,e]}}class p extends u{constructor(){super(),this.style=document.createElement("style"),document.head.appendChild(this.style);const{sheet:e}=this.style;if(e){const t=e.insertRule(":root{}",e.cssRules.length);this.target=e.cssRules[t].style}}}class g{constructor(e){this.store=new Map,this.target=null;const t=e.$fastController;this.style=document.createElement("style"),t.addStyles(this.style),r.y$.getNotifier(t).subscribe(this,"isConnected"),this.handleChange(t,"isConnected")}targetChanged(){if(null!==this.target)for(const[e,t]of this.store.entries())this.target.setProperty(e,t)}setProperty(e,t){this.store.set(e,t),l.SO.queueUpdate((()=>{null!==this.target&&this.target.setProperty(e,t)}))}removeProperty(e){this.store.delete(e),l.SO.queueUpdate((()=>{null!==this.target&&this.target.removeProperty(e)}))}handleChange(e,t){const{sheet:i}=this.style;if(i){const e=i.insertRule(":host{}",i.cssRules.length);this.target=i.cssRules[e].style}else this.target=null}}(0,n.gn)([r.LO],g.prototype,"target",void 0);class f{constructor(e){this.target=e.style}setProperty(e,t){l.SO.queueUpdate((()=>this.target.setProperty(e,t)))}removeProperty(e){l.SO.queueUpdate((()=>this.target.removeProperty(e)))}}class m{setProperty(e,t){m.properties[e]=t;for(const i of m.roots.values())C.getOrCreate(m.normalizeRoot(i)).setProperty(e,t)}removeProperty(e){delete m.properties[e];for(const t of m.roots.values())C.getOrCreate(m.normalizeRoot(t)).removeProperty(e)}static registerRoot(e){const{roots:t}=m;if(!t.has(e)){t.add(e);const i=C.getOrCreate(this.normalizeRoot(e));for(const e in m.properties)i.setProperty(e,m.properties[e])}}static unregisterRoot(e){const{roots:t}=m;if(t.has(e)){t.delete(e);const i=C.getOrCreate(m.normalizeRoot(e));for(const e in m.properties)i.removeProperty(e)}}static normalizeRoot(e){return e===d?document:e}}m.roots=new Set,m.properties={};const v=new WeakMap,y=l.SO.supportsAdoptedStyleSheets?class extends u{constructor(e){super();const t=new CSSStyleSheet;this.target=t.cssRules[t.insertRule(":host{}")].style,e.$fastController.addStyles(c.XL.create([t]))}}:g,C=Object.freeze({getOrCreate(e){if(v.has(e))return v.get(e);let t;return t=e===d?new m:e instanceof Document?l.SO.supportsAdoptedStyleSheets?new h:new p:e instanceof a.H?new y(e):new f(e),v.set(e,t),t}});class b extends o.v{constructor(e){super(),this.subscribers=new WeakMap,this._appliedTo=new Set,this.name=e.name,null!==e.cssCustomPropertyName&&(this.cssCustomProperty=`--${e.cssCustomPropertyName}`,this.cssVar=`var(${this.cssCustomProperty})`),this.id=b.uniqueId(),b.tokensById.set(this.id,this)}get appliedTo(){return[...this._appliedTo]}static from(e){return new b({name:"string"==typeof e?e:e.name,cssCustomPropertyName:"string"==typeof e?e:void 0===e.cssCustomPropertyName?e.name:e.cssCustomPropertyName})}static isCSSDesignToken(e){return"string"==typeof e.cssCustomProperty}static isDerivedDesignTokenValue(e){return"function"==typeof e}static getTokenById(e){return b.tokensById.get(e)}getOrCreateSubscriberSet(e=this){return this.subscribers.get(e)||this.subscribers.set(e,new Set)&&this.subscribers.get(e)}createCSS(){return this.cssVar||""}getValueFor(e){const t=O.getOrCreate(e).get(this);if(void 0!==t)return t;throw new Error(`Value could not be retrieved for token named "${this.name}". Ensure the value is set for ${e} or an ancestor of ${e}.`)}setValueFor(e,t){return this._appliedTo.add(e),t instanceof b&&(t=this.alias(t)),O.getOrCreate(e).set(this,t),this}deleteValueFor(e){return this._appliedTo.delete(e),O.existsFor(e)&&O.getOrCreate(e).delete(this),this}withDefault(e){return this.setValueFor(d,e),this}subscribe(e,t){const i=this.getOrCreateSubscriberSet(t);t&&!O.existsFor(t)&&O.getOrCreate(t),i.has(e)||i.add(e)}unsubscribe(e,t){const i=this.subscribers.get(t||this);i&&i.has(e)&&i.delete(e)}notify(e){const t=Object.freeze({token:this,target:e});this.subscribers.has(this)&&this.subscribers.get(this).forEach((e=>e.handleChange(t))),this.subscribers.has(e)&&this.subscribers.get(e).forEach((e=>e.handleChange(t)))}alias(e){return t=>e.getValueFor(t)}}b.uniqueId=(()=>{let e=0;return()=>(e++,e.toString(16))})(),b.tokensById=new Map;class S{constructor(e,t,i){this.source=e,this.token=t,this.node=i,this.dependencies=new Set,this.observer=r.y$.binding(e,this,!1),this.observer.handleChange=this.observer.call,this.handleChange()}disconnect(){this.observer.disconnect()}handleChange(){this.node.store.set(this.token,this.observer.observe(this.node.target,r.Wp))}}class x{constructor(){this.values=new Map}set(e,t){this.values.get(e)!==t&&(this.values.set(e,t),r.y$.getNotifier(this).notify(e.id))}get(e){return r.y$.track(this,e.id),this.values.get(e)}delete(e){this.values.delete(e)}all(){return this.values.entries()}}const T=new WeakMap,w=new WeakMap;class O{constructor(e){this.target=e,this.store=new x,this.children=[],this.assignedValues=new Map,this.reflecting=new Set,this.bindingObservers=new Map,this.tokenValueChangeHandler={handleChange:(e,t)=>{const i=b.getTokenById(t);if(i&&(i.notify(this.target),b.isCSSDesignToken(i))){const t=this.parent,n=this.isReflecting(i);if(t){const o=t.get(i),r=e.get(i);o===r||n?o===r&&n&&this.stopReflectToCSS(i):this.reflectToCSS(i)}else n||this.reflectToCSS(i)}}},T.set(e,this),r.y$.getNotifier(this.store).subscribe(this.tokenValueChangeHandler),e instanceof a.H?e.$fastController.addBehaviors([this]):e.isConnected&&this.bind()}static getOrCreate(e){return T.get(e)||new O(e)}static existsFor(e){return T.has(e)}static findParent(e){if(d!==e.target){let t=(0,s.T)(e.target);for(;null!==t;){if(T.has(t))return T.get(t);t=(0,s.T)(t)}return O.getOrCreate(d)}return null}static findClosestAssignedNode(e,t){let i=t;do{if(i.has(e))return i;i=i.parent?i.parent:i.target!==d?O.getOrCreate(d):null}while(null!==i);return null}get parent(){return w.get(this)||null}has(e){return this.assignedValues.has(e)}get(e){const t=this.store.get(e);if(void 0!==t)return t;const i=this.getRaw(e);return void 0!==i?(this.hydrate(e,i),this.get(e)):void 0}getRaw(e){var t;return this.assignedValues.has(e)?this.assignedValues.get(e):null===(t=O.findClosestAssignedNode(e,this))||void 0===t?void 0:t.getRaw(e)}set(e,t){b.isDerivedDesignTokenValue(this.assignedValues.get(e))&&this.tearDownBindingObserver(e),this.assignedValues.set(e,t),b.isDerivedDesignTokenValue(t)?this.setupBindingObserver(e,t):this.store.set(e,t)}delete(e){this.assignedValues.delete(e),this.tearDownBindingObserver(e);const t=this.getRaw(e);t?this.hydrate(e,t):this.store.delete(e)}bind(){const e=O.findParent(this);e&&e.appendChild(this);for(const e of this.assignedValues.keys())e.notify(this.target)}unbind(){this.parent&&w.get(this).removeChild(this)}appendChild(e){e.parent&&w.get(e).removeChild(e);const t=this.children.filter((t=>e.contains(t)));w.set(e,this),this.children.push(e),t.forEach((t=>e.appendChild(t))),r.y$.getNotifier(this.store).subscribe(e);for(const[t,i]of this.store.all())e.hydrate(t,this.bindingObservers.has(t)?this.getRaw(t):i)}removeChild(e){const t=this.children.indexOf(e);return-1!==t&&this.children.splice(t,1),r.y$.getNotifier(this.store).unsubscribe(e),e.parent===this&&w.delete(e)}contains(e){return function(e,t){let i=t;for(;null!==i;){if(i===e)return!0;i=(0,s.T)(i)}return!1}(this.target,e.target)}reflectToCSS(e){this.isReflecting(e)||(this.reflecting.add(e),O.cssCustomPropertyReflector.startReflection(e,this.target))}stopReflectToCSS(e){this.isReflecting(e)&&(this.reflecting.delete(e),O.cssCustomPropertyReflector.stopReflection(e,this.target))}isReflecting(e){return this.reflecting.has(e)}handleChange(e,t){const i=b.getTokenById(t);i&&this.hydrate(i,this.getRaw(i))}hydrate(e,t){if(!this.has(e)){const i=this.bindingObservers.get(e);b.isDerivedDesignTokenValue(t)?i?i.source!==t&&(this.tearDownBindingObserver(e),this.setupBindingObserver(e,t)):this.setupBindingObserver(e,t):(i&&this.tearDownBindingObserver(e),this.store.set(e,t))}}setupBindingObserver(e,t){const i=new S(t,e,this);return this.bindingObservers.set(e,i),i}tearDownBindingObserver(e){return!!this.bindingObservers.has(e)&&(this.bindingObservers.get(e).disconnect(),this.bindingObservers.delete(e),!0)}}O.cssCustomPropertyReflector=new class{startReflection(e,t){e.subscribe(this,t),this.handleChange({token:e,target:t})}stopReflection(e,t){e.unsubscribe(this,t),this.remove(e,t)}handleChange(e){const{token:t,target:i}=e;this.add(t,i)}add(e,t){C.getOrCreate(t).setProperty(e.cssCustomProperty,this.resolveCSSValue(O.getOrCreate(t).get(e)))}remove(e,t){C.getOrCreate(t).removeProperty(e.cssCustomProperty)}resolveCSSValue(e){return e&&"function"==typeof e.createCSS?e.createCSS():e}},(0,n.gn)([r.LO],O.prototype,"children",void 0);const P=Object.freeze({create:function(e){return b.from(e)},notifyConnection(e){return!(!e.isConnected||!O.existsFor(e)||(O.getOrCreate(e).bind(),0))},notifyDisconnection(e){return!(e.isConnected||!O.existsFor(e)||(O.getOrCreate(e).unbind(),0))},registerRoot(e=d){m.registerRoot(e)},unregisterRoot(e=d){m.unregisterRoot(e)}})},98584:function(e,t,i){"use strict";function n(e){const t=e.parentElement;if(t)return t;{const t=e.getRootNode();if(t.host instanceof HTMLElement)return t.host}return null}i.d(t,{T:function(){return n}})},56493:function(e,t,i){"use strict";i.d(t,{BE:function(){return o},BI:function(){return u},CX:function(){return c},Kh:function(){return s},SB:function(){return a},iF:function(){return n},kL:function(){return l},mr:function(){return r},oM:function(){return h},tU:function(){return d}});const n="ArrowDown",o="ArrowLeft",r="ArrowRight",a="ArrowUp",s="End",l="Enter",c="Escape",d="Home",u=" ",h="Tab"},64865:function(e,t,i){"use strict";function n(e){return!e||!e.trim()}i.d(t,{TF:function(){return n}})},94070:function(e,t,i){"use strict";function n(e){return"object"==typeof e&&"length"in e?e:Array.from(e)}i.d(t,{Z:function(){return n}}),Array.prototype.slice},97987:function(e,t,i){"use strict";function n(e){return function(){return e}}i.d(t,{Z:function(){return n}})},80561:function(e,t,i){"use strict";function n(e){this._context=e}function o(e){return new n(e)}i.d(t,{Z:function(){return o}}),n.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t)}}}},32439:function(e,t,i){"use strict";function n(e){return e<0?-1:1}function o(e,t,i){var o=e._x1-e._x0,r=t-e._x1,a=(e._y1-e._y0)/(o||r<0&&-0),s=(i-e._y1)/(r||o<0&&-0),l=(a*r+s*o)/(o+r);return(n(a)+n(s))*Math.min(Math.abs(a),Math.abs(s),.5*Math.abs(l))||0}function r(e,t){var i=e._x1-e._x0;return i?(3*(e._y1-e._y0)/i-t)/2:t}function a(e,t,i){var n=e._x0,o=e._y0,r=e._x1,a=e._y1,s=(r-n)/3;e._context.bezierCurveTo(n+s,o+s*t,r-s,a-s*i,r,a)}function s(e){this._context=e}function l(e){this._context=new c(e)}function c(e){this._context=e}function d(e){return new s(e)}function u(e){return new l(e)}i.d(t,{Z:function(){return d},s:function(){return u}}),s.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:a(this,this._t0,r(this,this._t0))}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){var i=NaN;if(t=+t,(e=+e)!==this._x1||t!==this._y1){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,a(this,r(this,i=o(this,e,t)),i);break;default:a(this,this._t0,i=o(this,e,t))}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=i}}},(l.prototype=Object.create(s.prototype)).point=function(e,t){s.prototype.point.call(this,t,e)},c.prototype={moveTo:function(e,t){this._context.moveTo(t,e)},closePath:function(){this._context.closePath()},lineTo:function(e,t){this._context.lineTo(t,e)},bezierCurveTo:function(e,t,i,n,o,r){this._context.bezierCurveTo(t,e,n,i,r,o)}}},69634:function(e,t,i){"use strict";i.d(t,{Z:function(){return l}});var n=i(94070),o=i(97987),r=i(80561),a=i(59945),s=i(87441);function l(e,t){var i=(0,o.Z)(!0),l=null,c=r.Z,d=null,u=(0,a.d)(h);function h(o){var r,a,s,h=(o=(0,n.Z)(o)).length,p=!1;for(null==l&&(d=c(s=u())),r=0;r<=h;++r)!(r<h&&i(a=o[r],r,o))===p&&((p=!p)?d.lineStart():d.lineEnd()),p&&d.point(+e(a,r,o),+t(a,r,o));if(s)return d=null,s+""||null}return e="function"==typeof e?e:void 0===e?s.x:(0,o.Z)(e),t="function"==typeof t?t:void 0===t?s.y:(0,o.Z)(t),h.x=function(t){return arguments.length?(e="function"==typeof t?t:(0,o.Z)(+t),h):e},h.y=function(e){return arguments.length?(t="function"==typeof e?e:(0,o.Z)(+e),h):t},h.defined=function(e){return arguments.length?(i="function"==typeof e?e:(0,o.Z)(!!e),h):i},h.curve=function(e){return arguments.length?(c=e,null!=l&&(d=c(l)),h):c},h.context=function(e){return arguments.length?(null==e?l=d=null:d=c(l=e),h):l},h}},59945:function(e,t,i){"use strict";i.d(t,{d:function(){return c}});const n=Math.PI,o=2*n,r=1e-6,a=o-r;function s(e){this._+=e[0];for(let t=1,i=e.length;t<i;++t)this._+=arguments[t]+e[t]}class l{constructor(e){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=null==e?s:function(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return s;const i=10**t;return function(e){this._+=e[0];for(let t=1,n=e.length;t<n;++t)this._+=Math.round(arguments[t]*i)/i+e[t]}}(e)}moveTo(e,t){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+t}`}closePath(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(e,t){this._append`L${this._x1=+e},${this._y1=+t}`}quadraticCurveTo(e,t,i,n){this._append`Q${+e},${+t},${this._x1=+i},${this._y1=+n}`}bezierCurveTo(e,t,i,n,o,r){this._append`C${+e},${+t},${+i},${+n},${this._x1=+o},${this._y1=+r}`}arcTo(e,t,i,o,a){if(e=+e,t=+t,i=+i,o=+o,(a=+a)<0)throw new Error(`negative radius: ${a}`);let s=this._x1,l=this._y1,c=i-e,d=o-t,u=s-e,h=l-t,p=u*u+h*h;if(null===this._x1)this._append`M${this._x1=e},${this._y1=t}`;else if(p>r)if(Math.abs(h*c-d*u)>r&&a){let g=i-s,f=o-l,m=c*c+d*d,v=g*g+f*f,y=Math.sqrt(m),C=Math.sqrt(p),b=a*Math.tan((n-Math.acos((m+p-v)/(2*y*C)))/2),S=b/C,x=b/y;Math.abs(S-1)>r&&this._append`L${e+S*u},${t+S*h}`,this._append`A${a},${a},0,0,${+(h*g>u*f)},${this._x1=e+x*c},${this._y1=t+x*d}`}else this._append`L${this._x1=e},${this._y1=t}`}arc(e,t,i,s,l,c){if(e=+e,t=+t,c=!!c,(i=+i)<0)throw new Error(`negative radius: ${i}`);let d=i*Math.cos(s),u=i*Math.sin(s),h=e+d,p=t+u,g=1^c,f=c?s-l:l-s;null===this._x1?this._append`M${h},${p}`:(Math.abs(this._x1-h)>r||Math.abs(this._y1-p)>r)&&this._append`L${h},${p}`,i&&(f<0&&(f=f%o+o),f>a?this._append`A${i},${i},0,1,${g},${e-d},${t-u}A${i},${i},0,1,${g},${this._x1=h},${this._y1=p}`:f>r&&this._append`A${i},${i},0,${+(f>=n)},${g},${this._x1=e+i*Math.cos(l)},${this._y1=t+i*Math.sin(l)}`)}rect(e,t,i,n){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+t}h${i=+i}v${+n}h${-i}Z`}toString(){return this._}}function c(e){let t=3;return e.digits=function(i){if(!arguments.length)return t;if(null==i)t=null;else{const e=Math.floor(i);if(!(e>=0))throw new RangeError(`invalid digits: ${i}`);t=e}return e},()=>new l(t)}l.prototype},87441:function(e,t,i){"use strict";function n(e){return e[0]}function o(e){return e[1]}i.d(t,{x:function(){return n},y:function(){return o}})},85866:function(e,t,i){"use strict";function n(e,t,i,n){var o,r=arguments.length,a=r<3?t:null===n?n=Object.getOwnPropertyDescriptor(t,i):n;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,i,n);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(r<3?o(a):r>3?o(t,i,a):o(t,i))||a);return r>3&&a&&Object.defineProperty(t,i,a),a}function o(e,t,i,n){return new(i||(i=Promise))((function(o,r){function a(e){try{l(n.next(e))}catch(e){r(e)}}function s(e){try{l(n.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(a,s)}l((n=n.apply(e,t||[])).next())}))}i.d(t,{gn:function(){return n},mG:function(){return o}}),Object.create,Object.create,"function"==typeof SuppressedError&&SuppressedError}},n={};function o(e){var t=n[e];if(void 0!==t)return t.exports;var r=n[e]={id:e,loaded:!1,exports:{}};return i[e].call(r.exports,r,r.exports,o),r.loaded=!0,r.exports}o.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(t,{a:t}),t},t=Object.getPrototypeOf?function(e){return Object.getPrototypeOf(e)}:function(e){return e.__proto__},o.t=function(i,n){if(1&n&&(i=this(i)),8&n)return i;if("object"==typeof i&&i){if(4&n&&i.__esModule)return i;if(16&n&&"function"==typeof i.then)return i}var r=Object.create(null);o.r(r);var a={};e=e||[null,t({}),t([]),t(t)];for(var s=2&n&&i;"object"==typeof s&&!~e.indexOf(s);s=t(s))Object.getOwnPropertyNames(s).forEach((function(e){a[e]=function(){return i[e]}}));return a.default=function(){return i},o.d(r,a),r},o.d=function(e,t){for(var i in t)o.o(t,i)&&!o.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},o.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},o.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},o.nmd=function(e){return e.paths=[],e.children||(e.children=[]),e},o.nc=void 0,function(){"use strict";var e=o(31656),t=o(59645),i=o(5144),n=o(39088),r=o(88767);document.body=document.createElement("body");var a=o(27775),s=o(72370),l=o(15255),c=o(82960),d=o(87720),u=o(73557),h=o(33491),p=o(64865),g=class{constructor(e,t=[],i=!1){(0,s.Z)(this,"isAutosSupportedDomain",void 0),(0,s.Z)(this,"includePaths",void 0),(0,s.Z)(this,"isDetectedAutosDomain",void 0),this.isAutosSupportedDomain=e,this.isDetectedAutosDomain=i,this.includePaths=t}},f=o(4872);class m{constructor(e,t,i){(0,s.Z)(this,"code",void 0),(0,s.Z)(this,"discountType",void 0),(0,s.Z)(this,"discountValue",void 0),e&&(this.code=e),t&&(this.discountType=t),i&&(this.discountValue=i)}}class v{constructor(e){(0,s.Z)(this,"globalOfferId",void 0),(0,s.Z)(this,"cashback",void 0),(0,s.Z)(this,"coupon",void 0),(0,s.Z)(this,"title",void 0),(0,s.Z)(this,"seller",void 0),(0,s.Z)(this,"originalPrice",void 0),(0,s.Z)(this,"imageUrl",void 0),(0,s.Z)(this,"discountPrice",void 0),e&&(e.globalOfferId&&(this.globalOfferId=e.globalOfferId),e.cashback&&(this.cashback=e.cashback),e.coupon?.discountValue&&(this.coupon=new m(e.coupon.code,e.coupon.discountType,e.coupon.discountValue)),e.title&&(this.title=e.title),e.seller&&(this.seller=e.seller),e.originalPrice&&(this.originalPrice=e.originalPrice),e.imageUrl&&(this.imageUrl=`https://th.bing.com${e.imageUrl}&h=176&w=214`),e.discountPrice&&(this.discountPrice=e.discountPrice))}}var y=o(66933);class C{constructor(){(0,s.Z)(this,"title",void 0),(0,s.Z)(this,"offerUrl",void 0)}static Create(e){const t=new C;return t.title=e.title,t.offerUrl=e.offerUrl,t}}var b=C,S=o(57021),x=o(29247),T=o(27689),w=o(69886);class O{constructor(){(0,s.Z)(this,"otherSellersOverlayLinkSelector",void 0),(0,s.Z)(this,"otherSellerOfferElementSelector",void 0),(0,s.Z)(this,"otherSellerHeadingSelector",void 0),(0,s.Z)(this,"otherSellerPriceSelector",void 0),(0,s.Z)(this,"otherSellerNameSelector",void 0),(0,s.Z)(this,"productImageSelector",void 0),(0,s.Z)(this,"otherSellerRatingSelector",void 0),(0,s.Z)(this,"otherSellerDeliverySelector",void 0),(0,s.Z)(this,"otherSellerAddButtonSelector",void 0),(0,s.Z)(this,"otherSellerAddedConfirmationSelector",void 0)}static Create(e){const t=new O;return t.otherSellersOverlayLinkSelector=e.otherSellersOverlayLinkSelector,t.otherSellerOfferElementSelector=e.otherSellerOfferElementSelector,t.otherSellerHeadingSelector=e.otherSellerHeadingSelector,t.otherSellerPriceSelector=e.otherSellerPriceSelector,t.otherSellerNameSelector=e.otherSellerNameSelector,t.productImageSelector=e.productImageSelector,t.otherSellerRatingSelector=e.otherSellerRatingSelector,t.otherSellerDeliverySelector=e.otherSellerDeliverySelector,t.otherSellerAddButtonSelector=e.otherSellerAddButtonSelector,t.otherSellerAddedConfirmationSelector=e.otherSellerAddedConfirmationSelector,t}}var P=O,A=o(99182),E=o(6747);class k{constructor(){(0,s.Z)(this,"inputBoxSelector",void 0),(0,s.Z)(this,"applyButtonSelector",void 0),(0,s.Z)(this,"removeCouponButtonSelector",void 0),(0,s.Z)(this,"orderTotalDataElementSelector",void 0),(0,s.Z)(this,"orderSubTotalElementSelector",void 0),(0,s.Z)(this,"enabledTips",void 0),(0,s.Z)(this,"couponAcceptedMessageElementSelector",void 0),(0,s.Z)(this,"errorMessageCloseButtonSelector",void 0),(0,s.Z)(this,"waitBeforeReApplyingNextCoupon",void 0),(0,s.Z)(this,"waitAfterApplyingCurrentCoupon",void 0),(0,s.Z)(this,"checkoutPageUrl",void 0),(0,s.Z)(this,"refreshAfterApplying",void 0),(0,s.Z)(this,"refreshAfterRemoving",void 0),(0,s.Z)(this,"closeModal",void 0),(0,s.Z)(this,"layoutClickSelector",void 0),(0,s.Z)(this,"clickBeforeStartSelector",void 0),(0,s.Z)(this,"errorMessageSelector",void 0),(0,s.Z)(this,"couponSuccessMessageSelectors",void 0),(0,s.Z)(this,"couponFailureMessageSelectors",void 0),(0,s.Z)(this,"domMutationEnabled",void 0),(0,s.Z)(this,"couponRemovalNotNeeded",void 0),(0,s.Z)(this,"appliedCouponSelector",void 0),(0,s.Z)(this,"finalCheckoutButtonSelector",void 0),(0,s.Z)(this,"otherSellerSelectors",void 0),(0,s.Z)(this,"clippingSelectors",void 0),(0,s.Z)(this,"backgroundAAEnabled",void 0),(0,s.Z)(this,"socialSelectors",void 0),(0,s.Z)(this,"pinterestSelectors",void 0),(0,s.Z)(this,"backgroundAutoApplyStartTimeout",void 0),(0,s.Z)(this,"backgroundAutoApplyInProgressTimeout",void 0),(0,s.Z)(this,"backgroundAutoApplyCancelTimeout",void 0),(0,s.Z)(this,"edgeEnabled",void 0),(0,s.Z)(this,"couponApplyMinWaitTime",void 0),(0,s.Z)(this,"couponRemoveMinWaitTime",void 0),(0,s.Z)(this,"autosDataSelector",void 0),(0,s.Z)(this,"suggestedCouponElementSelector",void 0),(0,s.Z)(this,"suggestedCouponRegex",void 0),(0,s.Z)(this,"successfulAlertSelector",void 0),(0,s.Z)(this,"supportedNoOrderTotal",void 0),(0,s.Z)(this,"waitBeforeTypingNextCoupon",void 0),(0,s.Z)(this,"waitAfterTypingCoupon",void 0),(0,s.Z)(this,"productAddToCartSelector",void 0),(0,s.Z)(this,"pageUrlRegex",void 0),(0,s.Z)(this,"pageTypeSelector",void 0),(0,s.Z)(this,"pageType",void 0),(0,s.Z)(this,"addToCartOverlaySelector",void 0),(0,s.Z)(this,"shipmentSelector",void 0),(0,s.Z)(this,"getProductNamesFromImg",void 0),(0,s.Z)(this,"isHomePageSameAsCheckout",void 0)}static Create(e){const t=new k;return t.inputBoxSelector=e.inputBoxSelector,t.applyButtonSelector=e.applyButtonSelector,t.removeCouponButtonSelector=e.removeCouponButtonSelector,t.orderTotalDataElementSelector=e.orderTotalDataElementSelector,t.orderSubTotalElementSelector=e.orderSubTotalElementSelector,t.enabledTips=e.enabledTips,t.couponAcceptedMessageElementSelector=e.couponAcceptedMessageElementSelector,t.errorMessageCloseButtonSelector=e.errorMessageCloseButtonSelector,t.waitBeforeReApplyingNextCoupon=e.waitBeforeReApplyingNextCoupon,t.waitAfterApplyingCurrentCoupon=e.waitAfterApplyingCurrentCoupon,t.checkoutPageUrl=e.checkoutPageUrl,t.refreshAfterApplying=e.refreshAfterApplying,t.refreshAfterRemoving=e.refreshAfterRemoving,t.closeModal=e.closeModal,t.clickBeforeStartSelector=e.clickBeforeStartSelector,t.errorMessageSelector=e.errorMessageSelector,t.couponSuccessMessageSelectors=e.couponSuccessMessageSelectors,t.couponFailureMessageSelectors=e.couponFailureMessageSelectors,t.domMutationEnabled=e.domMutationEnabled,t.couponRemovalNotNeeded=e.couponRemovalNotNeeded,t.appliedCouponSelector=e.appliedCouponSelector,t.finalCheckoutButtonSelector=e.finalCheckoutButtonSelector,t.layoutClickSelector=e.layoutClickSelector,t.backgroundAAEnabled=e.backgroundAAEnabled,t.backgroundAutoApplyCancelTimeout=e.backgroundAutoApplyCancelTimeout,t.backgroundAutoApplyStartTimeout=e.backgroundAutoApplyStartTimeout,t.backgroundAutoApplyInProgressTimeout=e.backgroundAutoApplyInProgressTimeout,t.edgeEnabled=e.edgeEnabled,t.couponApplyMinWaitTime=e.couponApplyMinWaitTime,t.couponRemoveMinWaitTime=e.couponRemoveMinWaitTime,t.suggestedCouponElementSelector=e.suggestedCouponElementSelector,t.suggestedCouponRegex=e.suggestedCouponRegex,t.successfulAlertSelector=e.successfulAlertSelector,t.supportedNoOrderTotal=e.supportedNoOrderTotal,t.waitBeforeTypingNextCoupon=e.waitBeforeTypingNextCoupon,t.waitAfterTypingCoupon=e.waitAfterTypingCoupon,t.productAddToCartSelector=e.productAddToCartSelector,t.pageUrlRegex=e.pageUrlRegex,t.pageTypeSelector=e.pageTypeSelector,t.pageType=e.pageType,t.addToCartOverlaySelector=e.addToCartOverlaySelector,t.shipmentSelector=e.shipmentSelector,t.isHomePageSameAsCheckout=e.isHomePageSameAsCheckout,e.otherSellerSelectors&&(t.otherSellerSelectors=P.Create(e.otherSellerSelectors)),e.clippingSelectors&&(t.clippingSelectors=w.Z.Create(e.clippingSelectors)),e.socialSelectors&&(t.socialSelectors=E.Z.Create(e.socialSelectors)),e.autosDataSelector&&(t.autosDataSelector=e.autosDataSelector),e.pinterestSelectors&&(t.pinterestSelectors=A.Z.Create(e.pinterestSelectors)),t}static Process(e,t){return!t||t!==i.BN.Opal&&t!==i.BN.EdgeMobile&&t!==i.BN.Sapphire||(e.inputBoxSelector=(0,T.oO)(e.inputBoxSelector),e.applyButtonSelector=(0,T.oO)(e.applyButtonSelector),e.removeCouponButtonSelector=(0,T.oO)(e.removeCouponButtonSelector),e.orderTotalDataElementSelector=(0,T.oO)(e.orderTotalDataElementSelector),e.orderSubTotalElementSelector=(0,T.oO)(e.orderSubTotalElementSelector),e.enabledTips=(0,T.oO)(e.enabledTips),e.couponAcceptedMessageElementSelector=(0,T.oO)(e.couponAcceptedMessageElementSelector),e.errorMessageCloseButtonSelector=(0,T.oO)(e.errorMessageCloseButtonSelector),e.closeModal=(0,T.oO)(e.closeModal),e.clickBeforeStartSelector=(0,T.oO)(e.clickBeforeStartSelector),e.layoutClickSelector=(0,T.oO)(e.layoutClickSelector),e.errorMessageSelector=(0,T.oO)(e.errorMessageSelector)),e}}var I=k;class D{constructor(){(0,s.Z)(this,"transactionIdSelector",void 0),(0,s.Z)(this,"purchaseTotalSelector",void 0),(0,s.Z)(this,"isHtmlFragmentCollectionEnabled",void 0)}static Create(e){const t=new D;return t.transactionIdSelector=e.transactionIdSelector,t.purchaseTotalSelector=e.purchaseTotalSelector,t.isHtmlFragmentCollectionEnabled=e.isHtmlFragmentCollectionEnabled,t}}var _=D,N=class{constructor(e,t){(0,s.Z)(this,"AverageSavings",void 0),(0,s.Z)(this,"AverageUsers",void 0),(0,s.Z)(this,"SellerName",void 0),(0,s.Z)(this,"Domain",void 0),(0,s.Z)(this,"SuccessRate",void 0),this.AverageSavings=e.averageSavings,this.AverageUsers=e.averageUsers,this.Domain=t,this.SellerName=e.websiteName,this.SuccessRate=e.successRate}};class R{constructor(){(0,s.Z)(this,"checkoutPageUrl",void 0),(0,s.Z)(this,"priceSelector",void 0),(0,s.Z)(this,"startDateSelector",void 0),(0,s.Z)(this,"endDateSelector",void 0),(0,s.Z)(this,"domainType",void 0),(0,s.Z)(this,"nameSelector",void 0)}static Create(e){const t=new R;return t.checkoutPageUrl=e.checkoutPageUrl,t.priceSelector=e.priceSelector,t.startDateSelector=e.startDateSelector,t.endDateSelector=e.endDateSelector,t.nameSelector=e.nameSelector,t}}var M=R;class L{constructor(){(0,s.Z)(this,"domainName",void 0),(0,s.Z)(this,"productPageUrl",void 0),(0,s.Z)(this,"productImageSelector",void 0),(0,s.Z)(this,"productNameSelector",void 0),(0,s.Z)(this,"productOutOfStockSelector",void 0),(0,s.Z)(this,"productPriceSelector",void 0),(0,s.Z)(this,"allCheckoutPages",void 0),(0,s.Z)(this,"couponsFilteringEnabled",void 0),(0,s.Z)(this,"bestCouponLogicEnabled",void 0),(0,s.Z)(this,"shortCircuitAAEnabled",void 0),(0,s.Z)(this,"hasWhitePageError",void 0),(0,s.Z)(this,"checkoutPageKey",void 0),(0,s.Z)(this,"orderConfirmationPageUrl",void 0),(0,s.Z)(this,"orderConfirmationRegex",void 0),(0,s.Z)(this,"isHighTrafficDomain",void 0),(0,s.Z)(this,"exclusiveMarket",void 0),(0,s.Z)(this,"confirmationPageTelemetry",void 0),(0,s.Z)(this,"travelCheckoutPageData",void 0),(0,s.Z)(this,"isStorewideCashbackEstimationEnabled",void 0),(0,s.Z)(this,"IsForceRefreshDisabled",void 0),(0,s.Z)(this,"selectorExtractionEnabled",void 0),(0,s.Z)(this,"searchQueryUrlRegex",void 0),(0,s.Z)(this,"retailerTrivia",void 0),(0,s.Z)(this,"isCompositeNotificationPhCExcludedRetailer",void 0),(0,s.Z)(this,"isCompositeNotificationPhCTopRetailer",void 0)}static Create(e){const t=new L;return t.domainName=e.domainName,t.productPageUrl=e.productPageUrl,t.productImageSelector=e.productImageSelector,t.productOutOfStockSelector=e.productOutOfStockSelector,t.productNameSelector=e.productNameSelector,t.productPriceSelector=e.productPriceSelector,t.couponsFilteringEnabled=e.couponsFilteringEnabled,t.bestCouponLogicEnabled=e.bestCouponLogicEnabled,t.shortCircuitAAEnabled=e.shortCircuitAAEnabled,t.hasWhitePageError=e.hasWhitePageError,t.exclusiveMarket=e.exclusiveMarket,t.orderConfirmationPageUrl=e.orderConfirmationPageUrl,t.orderConfirmationRegex=e.orderConfirmationRegex,t.isHighTrafficDomain=e.isHighTrafficDomain,t.selectorExtractionEnabled=e.selectorExtractionEnabled,t.isStorewideCashbackEstimationEnabled=e.isStorewideCashbackEstimationEnabled,t.IsForceRefreshDisabled=e.IsForceRefreshDisabled,t.searchQueryUrlRegex=e.searchQueryUrlRegex,t.isCompositeNotificationPhCExcludedRetailer=e.isCompositeNotificationPhCExcludedRetailer,t.isCompositeNotificationPhCTopRetailer=e.isCompositeNotificationPhCTopRetailer,e.confirmationPageTelemetry&&(t.confirmationPageTelemetry=_.Create(e.confirmationPageTelemetry)),e.retailerTrivia&&(t.retailerTrivia=new N(e.retailerTrivia,e.domainName)),t.CreateCheckoutPageList(e),t.CreateTravelCheckoutPageList(e),t}static Process(e,t){if(t&&(t===i.BN.Opal||t===i.BN.EdgeMobile||t===i.BN.Sapphire)){e.productImageSelector=(0,T.oO)(e.productImageSelector),e.productNameSelector=(0,T.oO)(e.productNameSelector),e.productPriceSelector=(0,T.oO)(e.productPriceSelector);for(let i=0;i<e.allCheckoutPages.length;i++)e.allCheckoutPages[i]=I.Process(e.allCheckoutPages[i],t)}return e}UpdateCurrentCheckoutPage(e){for(let t=0;t<this.allCheckoutPages.length;t++)if((0,x.VJ)(this.allCheckoutPages[t].checkoutPageUrl,this.allCheckoutPages[t].pageUrlRegex,e))return this.checkoutPageKey=t,!0;return this.checkoutPageKey=-1,!1}UpdateCurrentCheckoutPageWithPageTypeCheck(e){for(let t=0;t<this.allCheckoutPages.length;t++)if((!this.allCheckoutPages[t].pageType||this.allCheckoutPages[t].pageType===i.GV.CheckoutPage)&&(0,x.VJ)(this.allCheckoutPages[t].checkoutPageUrl,this.allCheckoutPages[t].pageUrlRegex,e))return this.checkoutPageKey=t,!0;return this.checkoutPageKey=-1,!1}GetCurrentCheckoutPage(e){return null!==this.checkoutPageKey&&-1!==this.checkoutPageKey&&void 0!==this.checkoutPageKey||-1!==this.checkoutPageKey&&e&&(this.UpdateCurrentCheckoutPage(e),null!==this.checkoutPageKey&&-1!==this.checkoutPageKey&&void 0!==this.checkoutPageKey)?this.allCheckoutPages[this.checkoutPageKey]:void 0}IsConfirmationPage(e){return!!this.orderConfirmationPageUrl&&new RegExp(this.orderConfirmationPageUrl).test(e)}CreateCheckoutPageList(e){if(this.allCheckoutPages=[],e.allCheckoutPages&&e.allCheckoutPages.length>0)for(const t of e.allCheckoutPages)this.allCheckoutPages.push(I.Create(t))}CreateTravelCheckoutPageList(e){if(this.travelCheckoutPageData=[],e.travelCheckoutPageData&&e.travelCheckoutPageData.length>0)for(const t of e.travelCheckoutPageData)this.travelCheckoutPageData.push(M.Create(t))}}var B=L;class F extends S.Z{static Create(e){if(e){const t=new F(e.Timestamp);if(e.errorCode&&(t.errorCode=e.errorCode),e.retailerData&&(t.retailerData=B.Create(e.retailerData)),t.coupons=[],e.coupons)for(const i of e.coupons)t.coupons.push(i);if(t.suppressedCoupons=[],e.suppressedCoupons)for(const i of e.suppressedCoupons)t.suppressedCoupons.push(i);if(t.deals=[],e.deals)for(const i of e.deals)t.deals.push(b.Create(i));return e.cashback&&(t.cashback=y.Z.Create(e.cashback)),e.impressionId&&(t.impressionId=e.impressionId),e.aFDMarket&&(t.aFDMarket=e.aFDMarket),e.market&&(t.market=e.market),e.userPersonalizationInfo&&(t.userPersonalizationInfo=e.userPersonalizationInfo),t}return new F}static Process(e,t){return e.retailerData&&(e.retailerData=B.Process(e.retailerData,t)),e}constructor(e){super(F.thirtyMinutesExpiryInSeconds,e),(0,s.Z)(this,"coupons",[]),(0,s.Z)(this,"suppressedCoupons",[]),(0,s.Z)(this,"deals",[]),(0,s.Z)(this,"retailerData",void 0),(0,s.Z)(this,"cashback",void 0),(0,s.Z)(this,"errorCode",void 0),(0,s.Z)(this,"impressionId",void 0),(0,s.Z)(this,"market",void 0),(0,s.Z)(this,"aFDMarket",void 0),(0,s.Z)(this,"userPersonalizationInfo",void 0),(0,s.Z)(this,"domainData",void 0)}HasCoupons(){return this.coupons&&this.coupons.length>0}HasDeals(){return this.deals&&this.deals.length>0}GetOfferCount(){return this.HasCoupons()?this.coupons.length:this.HasDeals()?this.deals.length:0}}(0,s.Z)(F,"thirtyMinutesExpiryInSeconds",1800);var U=F,H=class{constructor(e){(0,s.Z)(this,"ProductTitle",void 0),(0,s.Z)(this,"ImageUrl",void 0),(0,s.Z)(this,"SellerName",void 0),(0,s.Z)(this,"Domain",void 0),(0,s.Z)(this,"Url",void 0),(0,s.Z)(this,"Price",void 0),(0,s.Z)(this,"OriginalPrice",void 0),(0,s.Z)(this,"FavIcon",void 0),(0,s.Z)(this,"CurrencySymbol",void 0),e&&(this.ProductTitle=e.title??"",this.ImageUrl=e.img??"",this.SellerName=e.shop??"",this.Domain=e.domain??"",this.Url=e.url??"",this.Price=e.price??0,this.OriginalPrice=e.price_org??0,this.FavIcon=e.site_icon??"",this.CurrencySymbol="¥")}},$=o(41865),Z=o(95457),V=o(58474);let G=function(e){return e.DataExtraction="DataExtraction",e.RenderTime="RenderTime",e}({});class j extends V.Z{constructor(e,t,i,n,o){super(),(0,s.Z)(this,"Domain",void 0),(0,s.Z)(this,"TotalTime",void 0),(0,s.Z)(this,"Platform",void 0),(0,s.Z)(this,"Metadata",void 0),(0,s.Z)(this,"RenderStep",void 0),this.Domain=e,this.TotalTime=t,this.Platform=i,this.Metadata=n,this.RenderStep=o}}var z=j,W=o(93209),K=o(87605),q=o(84901),Y=o(79710);function X(e,t,i,n,o,a,s,l){const c=(0,Y.Ux)("msft-notification-competing-price-header");c.navigateToDestination=s,c.openPaneSeeMoreOffers=l,c.VisitItemButtonText=t.productTrackingViewItem,c.TitleText=t.productTrackingInStockAtText,c.Price=`${e.CurrencySymbol}${a(e.IntendedPrice,e.PriceCurrency)}`,c.RetailerName=e.SellerName;const d=e.ProductImageUrl.replace("edge://image?","");return c.ProductImageUrl=d.replace("w=66&h=66",""),c.ProductTitle=e.Description,c.ProductUrl=e.Url,c.FavIconImageUrl=i,c.enableAdSlug=e.BillingType===r.YO.Paid,c.isOutOfStock=!0,c.adSlugSrc=n,c.adSlugAriaLabel=t.gcAd,c.slot="header-content",c.enableSeeMoreOffers=o,c.seeMoreOffersText=t.pcNotificationSeeMoreInfo,c}function J(e){const t=new W.Z(i.$S.ProductTrackingOutOfStockPCVisitItem,this.telemetryUtilities.setContentViewed(this.GetModuleName()),this.flyoutData.common.domain,JSON.stringify(e));this.logModule.LogInfoEvent(i.R.ButtonClick,e.Url,t),this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKING_PRODUCT_NOTIFICATION_CLICK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_TRACKING_PRODUCT_NOTIFICATION_CLICK),e?.Url&&this.pageHandlerModule.NavigateToUrl(e.Url)}function Q(e){if(e?.length>0){let t=e[0];for(let i=1;i<e.length;i++)e[i].IntendedPrice<t.IntendedPrice&&(t=e[i]);return t}}function ee(e,t){let i=e.displayedText;const n=e.typeId;return i=e.Rating?te(e.displayedText,t):e.PromotionalText?te(e.promotionalText,t):16253===n?t.free_shipping:te(e.displayedText,t),i&&n?{ExtensionText:i,ExtensionType:n}:void 0}function te(e,t){if(e){const i=e.toLowerCase().split(";;");let n,o;if(2===i.length?(n=i[0].toLowerCase(),o=i[1]):1===i.length&&(n=e.toLowerCase()),n){const e=t[n];if(o)return(0,T.fZ)(n,e,o);if(e)return e}return e}}function ie(e){if(e.InstallmentAmount){let t=parseFloat(e.InstallmentAmount.replace(/[^0-9.]/g,""));if(e.InstallmentDescription){const i=parseInt(e.InstallmentDescription.replace(/[^0-9]/g,""),10);i&&(t*=i)}return e.Price&&(t+=e.Price),t}return e.LowPrice?e.LowPrice:e.Price}var ne=o(36493);class oe{constructor(e){(0,s.Z)(this,"thumbnailId",void 0),(0,s.Z)(this,"height",void 0),(0,s.Z)(this,"width",void 0),this.thumbnailId=e.thumbnailId,this.height=e.height,this.width=e.width}}class re{constructor(e){(0,s.Z)(this,"value",void 0),(0,s.Z)(this,"isActive",void 0),(0,s.Z)(this,"isSelected",void 0),(0,s.Z)(this,"rank",void 0),(0,s.Z)(this,"thumbnailId",void 0),(0,s.Z)(this,"encodedValue",void 0),this.value=e.value,this.isActive=void 0!==e.isActive?e.isActive:null,this.isSelected=void 0!==e.isSelected?e.isSelected:null,this.rank=e.rank,this.thumbnailId=e.imageThumbnailId||null,this.encodedValue=e.encodedValue}}class ae{constructor(e){(0,s.Z)(this,"id",void 0),(0,s.Z)(this,"name",void 0),(0,s.Z)(this,"isUserFacing",void 0),(0,s.Z)(this,"values",void 0),(0,s.Z)(this,"filterValues",void 0),(0,s.Z)(this,"filterAttributeType",void 0),(0,s.Z)(this,"encodedId",void 0),this.id=e.id,this.name=e.name,this.isUserFacing=void 0!==e.isUserFacing?e.isUserFacing:null,this.values=e.values||null,this.filterValues=(e.filterValues||[]).map((e=>new re(e))),this.filterAttributeType=e.filterAttributeType||null,this.encodedId=e.encodedId}}class se{constructor(e){(0,s.Z)(this,"attributes",void 0),this.attributes=(e?.attributes||[]).map((e=>new ae(e)))||null}}var le=o(95016),ce=class{constructor(t,i,n,o){if((0,s.Z)(this,"Price",void 0),(0,s.Z)(this,"CompetingPrices",void 0),(0,s.Z)(this,"similarOffers",void 0),(0,s.Z)(this,"currentImageUrl",void 0),(0,s.Z)(this,"currentProductTitle",void 0),(0,s.Z)(this,"entityName",void 0),(0,s.Z)(this,"segment",void 0),(0,s.Z)(this,"adsTraceId",void 0),(0,s.Z)(this,"visibilityFeedbackUrl",void 0),(0,s.Z)(this,"isCashbackOfferPresent",void 0),(0,s.Z)(this,"market",void 0),(0,s.Z)(this,"autoshowOffers",void 0),(0,s.Z)(this,"buyingOptions",void 0),t){let a="",l="";if(t&&t.value&&i&&(n&&n.image_url&&(a=n.image_url,l=n.title),n&&n.entity&&n.entity.name&&(this.entityName=n.entity.name)),this.Price=this.GetCurrentPrice(i,n),this.currentImageUrl=a,this.currentProductTitle=l,this.CompetingPrices=[],t.value&&t.value.length>0)for(const e of t.value){const t=new le.Z(e);t.position!==r.zE.SPB_OFFERS&&this.CompetingPrices.push(t)}this.CompetingPrices&&this.CompetingPrices.length>0&&this.CompetingPrices.forEach((e=>{e.IntendedPrice=ie(e)})),t&&t.segment&&(this.segment=t.segment),t&&t.visibilityFeedbackUrl&&(this.visibilityFeedbackUrl=t.visibilityFeedbackUrl),t&&t.debug?.adsTraceId&&(this.adsTraceId=t.debug.adsTraceId),this.similarOffers=this.CompetingPrices.filter((e=>e.isSimilarOffer)),this.similarOffers=[...this.similarOffers.filter((e=>e.position===r.zE.SIMILAR_OFFERS)),...this.similarOffers.filter((e=>e.position!==r.zE.SIMILAR_OFFERS))],this.CompetingPrices=this.CompetingPrices.filter((e=>!e.isSimilarOffer)),this.CompetingPrices=[...this.CompetingPrices.filter((e=>e.position===r.zE.PRICE_COMPARISON)),...this.CompetingPrices.filter((e=>e.position!==r.zE.PRICE_COMPARISON))],this.isCashbackOfferPresent=!!this.CompetingPrices&&this.CompetingPrices.some((e=>e?.promotionInformation?.rebateValue&&e?.BillingType!==r.YO.NoCharge)),this.autoshowOffers=function(e,t){if(t&&e){let i=[],n=[];return e.forEach((e=>{if(e.BillingType===r.YO.Backfill)return void n.push(e);const o=e.IntendedPrice;if(e.ShouldOnTop&&o)if(e.promotionInformation?.rebateValue&&e.BillingType!==r.YO.NoCharge){let n=0;try{n=Number(e.promotionInformation.rebateValue)}catch(e){}const r=o-n;r>0&&r<t&&(e.finalPrice=r,i.push(e))}else o>0&&o<t&&(e.finalPrice=o,i.push(e))})),n.length===e.length?(n=n.filter((e=>e.IntendedPrice>0&&e.IntendedPrice<t)),n=n.sort(((e,t)=>e.IntendedPrice-t.IntendedPrice)),n):(i=i.sort(((e,t)=>e.finalPrice-t.finalPrice)),i)}return[]}(this.CompetingPrices,this.Price),this.market=o,e.R.getServiceExperimentValue(f.H.buyingOptions)&&t?.productId&&(this.buyingOptions=new class{constructor(e){(0,s.Z)(this,"productId",void 0),(0,s.Z)(this,"productTitle",void 0),(0,s.Z)(this,"productDescription",void 0),(0,s.Z)(this,"images",void 0),(0,s.Z)(this,"userFacingAttributes",void 0),this.productId=e.productId,this.productTitle=e.productTitle,this.productDescription=e.productDescription,this.images=(e.productImages||[]).map((e=>new oe(e))),this.userFacingAttributes=new se(e.userFacingAttributes)}}(t))}}GetCurrentPrice(e,t){return t?.entity?.price_value?(0,ne.K)(t?.entity?.price_value):e}},de=o(1583),ue=o(40843),he=class{constructor(){(0,s.Z)(this,"influencerName",void 0),(0,s.Z)(this,"imgSrc",void 0),(0,s.Z)(this,"followers",void 0),(0,s.Z)(this,"channelId",void 0),(0,s.Z)(this,"userName",void 0),(0,s.Z)(this,"coupons",void 0),(0,s.Z)(this,"videoPath",void 0)}},pe=o(59352),ge=o(71951),fe=o(17928),me=o(21488),ve=o(11050),ye=class{constructor(){(0,s.Z)(this,"impressionFeedbackUrl",void 0),(0,s.Z)(this,"visibilityFeedbackUrl",void 0),(0,s.Z)(this,"visibilityFeedbackUrls",void 0),(0,s.Z)(this,"adsInstrumentation",void 0)}},Ce=o(55590),be=o(64641);class Se{static addPendingTransaction(e,t){const i=(0,h.hS)(this.PendingTransactionsKey);return i[e]=t,(0,h.Xo)(this.PendingTransactionsKey,JSON.stringify(i)),i[e]}static DeletePendingTransaction(e){const t=(0,h.hS)(this.PendingTransactionsKey);t[e]&&(delete t[e],(0,h.Xo)(this.PendingTransactionsKey,JSON.stringify(t)))}static addSubIdToPendingTransaction(e,t){const i=(0,h.hS)(this.PendingTransactionsKey);if(i[e])return t&&(i[e].subId=t,i[e].errorSubmittingCount=void 0,(0,h.Xo)(this.PendingTransactionsKey,JSON.stringify(i))),i[e]}static getPendingTransaction(e){const t=(0,h.hS)(this.PendingTransactionsKey);return t[e]?t[e]:void 0}static getActivatedTransactions(e){const t=(0,h.hS)(this.ActivatedTransactionsKey);return t[e]||(t[e]={}),t[e]}static deleteActivatedTransactions(e){const t=(0,h.hS)(this.ActivatedTransactionsKey);e?t[e]&&(delete t[e],(0,h.Xo)(this.ActivatedTransactionsKey,JSON.stringify(t))):(0,h.Xo)(this.ActivatedTransactionsKey,JSON.stringify({}))}static PendingTransactionErrorIncrement(e){const t=(0,h.hS)(this.PendingTransactionsKey);if(!t[e])return;const i=t[e].errorSubmittingCount??0;return t[e].errorSubmittingCount=i+1,(0,h.Xo)(this.PendingTransactionsKey,JSON.stringify(t)),t[e]}static pendingTransactionToActivatedTransactions(e,t){const i=(0,h.hS)(this.PendingTransactionsKey),n=i[e];if(!n)return;const o=(0,h.hS)(this.ActivatedTransactionsKey);o[e]||(o[e]={});const r={activationRequestSentTimeStamp:(0,be.u3)(),cashbackAmount:n.pendingCashback,purchaseIdFromUrl:n.purchaseIdFromUrl,subId:t};return o[e][r.purchaseIdFromUrl]=r,delete i[e],(0,h.Xo)(this.ActivatedTransactionsKey,JSON.stringify(o)),(0,h.Xo)(this.PendingTransactionsKey,JSON.stringify(i)),r}static isPendingTransactionPresent(e){return!!(0,h.hS)(this.PendingTransactionsKey)[e]}static removeOldOrFailingPendingTransaction(e){const t=(0,h.hS)(this.PendingTransactionsKey);if(t[e]){if(this.isTransactionOlderThanAllowed(t[e].addedTimestamp,30))delete t[e];else{const i=3;(t[e].errorSubmittingCount??0)>i&&delete t[e]}(0,h.Xo)(this.PendingTransactionsKey,JSON.stringify(t))}}static isTransactionOlderThanAllowed(e,t){return!e||(0,be.u3)()-e>24*t*60*60}}(0,s.Z)(Se,"PendingTransactionsKey","PendingTransactions"),(0,s.Z)(Se,"ActivatedTransactionsKey","ActivatedTransactions");var xe=Se,Te=o(11542),we=o(75434),Oe=o(91221),Pe=o(32389);function Ae(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Ee(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Ae(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Ae(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var ke=o(8018),Ie=o(57550),De=o(98011),_e=o(81731),Ne=class{constructor(e){if((0,s.Z)(this,"Timestamp",void 0),(0,s.Z)(this,"CurrencySymbol",void 0),(0,s.Z)(this,"CouponCode",void 0),(0,s.Z)(this,"DiscountRate",void 0),(0,s.Z)(this,"RetailerName",void 0),(0,s.Z)(this,"CashbackCommissionType",void 0),(0,s.Z)(this,"CashbackCommissionValue",void 0),(0,s.Z)(this,"NotificationType",void 0),(0,s.Z)(this,"RetailerCartPage",void 0),(0,s.Z)(this,"Products",void 0),(0,s.Z)(this,"Domain",void 0),(0,s.Z)(this,"ImageUrl",void 0),(0,s.Z)(this,"ProductUrl",void 0),(0,s.Z)(this,"Scope",void 0),(0,s.Z)(this,"VisibilityFeedbackUrl",void 0),(0,s.Z)(this,"ImpressionToken",void 0),(0,s.Z)(this,"ExclusiveCouponCode",void 0),this.Timestamp=e?.timestamp,this.CurrencySymbol=e?.currencySymbol,this.CouponCode=e?.couponCode,this.DiscountRate=e?.discountRate,this.RetailerName=e?.retailerName,this.CashbackCommissionType=e?.cashbackType,this.CashbackCommissionValue=e?.cashbackValue,this.RetailerCartPage=e?.retailerCartPage,this.NotificationType=e?.notificationType,this.Domain=e?.domain,this.ImageUrl=e?.imageUrl,this.ProductUrl=e?.productUrl,this.Scope=e?.scope,this.VisibilityFeedbackUrl=e?.visibilityFeedbackUrl,this.ImpressionToken=e?.ImpressionToken,this.ExclusiveCouponCode=e?.exclusiveCouponCode,this.Products=[],e?.products)for(const t of e.products)this.Products.push(new _e.Z(t))}};class Re{constructor(e,t,i,n){(0,s.Z)(this,"domainName",void 0),(0,s.Z)(this,"cashbackValue",void 0),(0,s.Z)(this,"currency",void 0),(0,s.Z)(this,"isPdp",void 0),this.domainName=e,this.currency=i,this.cashbackValue=t,this.isPdp=n??!1}}var Me=o(42544),Le=class{constructor(e){(0,s.Z)(this,"startDate",void 0),(0,s.Z)(this,"domain",void 0),(0,s.Z)(this,"orderNumber",void 0),(0,s.Z)(this,"cashbackAmount",void 0),(0,s.Z)(this,"status",void 0),(0,s.Z)(this,"merchantName",void 0),(0,s.Z)(this,"merchantHomepage",void 0),this.startDate=e?.startDate,this.domain=e?.domain,this.orderNumber=e?.orderNumber,this.cashbackAmount=parseFloat(e?.cashbackAmount.toFixed(2)),this.status=e?.status,this.merchantName=e?.merchantName,this.merchantHomepage=e?.merchantHomepage}};const Be=[u.sR.AUTO_SHOW_CASHBACK_PDP_PLUS_COUPONS,u.sR.AUTO_SHOW_PRICE_DROP_PLUS_CASHBACK,u.sR.AUTO_SHOW_LOWER_PRICE_PLUS_CASHBACK_PLUS_COUPONS],Fe=[u.sR.AUTO_SHOW_REBATES_ORGANIC,u.sR.AUTO_SHOW_REBATES,u.sR.AUTO_SHOW_REBATES_ORGANIC_NEW,u.sR.AUTO_SHOW_REBATES_CHECKOUT,u.sR.AUTO_SHOW_REBATES_PDP,...Be];var Ue=function(e){return e.Cash="Cash",e.Percent="Percent",e}(Ue||{}),He=class{constructor(){(0,s.Z)(this,"url",void 0),(0,s.Z)(this,"name",void 0),(0,s.Z)(this,"promotionInformation",void 0),(0,s.Z)(this,"price",void 0),(0,s.Z)(this,"discountedPrice",void 0),(0,s.Z)(this,"impressionToken",void 0),(0,s.Z)(this,"destinationUrl",void 0)}},$e=class{constructor(){(0,s.Z)(this,"isFreeGiftCoupon",void 0),(0,s.Z)(this,"promotionType",void 0),(0,s.Z)(this,"rebateValue",void 0),(0,s.Z)(this,"minPurchaseValue",void 0),(0,s.Z)(this,"scope",void 0),(0,s.Z)(this,"valueType",void 0)}};class Ze{constructor(){(0,s.Z)(this,"imageUrl",void 0),(0,s.Z)(this,"value",void 0),(0,s.Z)(this,"id",void 0),(0,s.Z)(this,"description",void 0),(0,s.Z)(this,"brand",void 0),(0,s.Z)(this,"disclaimer",void 0),(0,s.Z)(this,"expiryDate",void 0),(0,s.Z)(this,"expireTimeEpoch",void 0),(0,s.Z)(this,"minQty",void 0),(0,s.Z)(this,"source",void 0),(0,s.Z)(this,"adsOffer",void 0),(0,s.Z)(this,"isActivated",void 0),(0,s.Z)(this,"visibilityFeedbackUrlBase",void 0),(0,s.Z)(this,"lastSeenTimestamp",void 0),(0,s.Z)(this,"pathname",""),(0,s.Z)(this,"shouldAutoshow",void 0)}static Create(e,t=""){const i=new Ze;return i.imageUrl=e.imageUrl,i.value=e.value,i.id=e.id,i.description=e.description,i.brand=e.brand,i.disclaimer=e.disclaimer,i.expiryDate=e.expiryDate,i.minQty=e.minQty,i.source=e.source,i.adsOffer=e.adsOffer,i.adsOffer.destinationUrl=(0,Ie.ru)(i.adsOffer.destinationUrl),i.visibilityFeedbackUrlBase=t,i.pathname=(0,Ie.en)(i.adsOffer.destinationUrl)?.pathname||"",i}static CreateFromComparableOffer(e,t){if(!e||!e?.offer||!e?.promotionInformation)return;const i=new Ze;i.imageUrl=(0,Ie.MK)(e.offer.itemOffered?.image?.contentUrl||"");const n=e.promotionInformation;i.value=String(n.rebateValue||0),i.id=e.globalOfferId?String(e.globalOfferId):"",i.description=e.offer.itemOffered.description,i.brand="",i.disclaimer="",i.expireTimeEpoch=void 0,i.minQty=1,i.source=ve.h.SPB;const o=new He;return o.destinationUrl=(0,Ie.ru)(e.offer.url),o.url=e.offer.url,o.name=e.offer.itemOffered.name,o.promotionInformation=new $e,o.promotionInformation.minPurchaseValue=n.minPurchaseValue||0,o.promotionInformation.rebateValue=n.rebateValue||0,o.promotionInformation.scope=n.scope||0,o.promotionInformation.valueType=n.valueType||0,o.promotionInformation.promotionType=n.promotionType||0,o.price=e.offer.price,o.impressionToken=e.impressionToken??"",i.adsOffer=o,i.visibilityFeedbackUrlBase=t,i.pathname=(0,Ie.en)(e.offer.url)?.pathname||"",i}static CreateFromPersonalizedOffer(e){const t=new Ze;t.imageUrl=(0,Ie.MK)(e.imageUrl),t.value=e.commissionValue,t.id=e.globalOfferId,t.description="",t.brand="",t.disclaimer="",t.expireTimeEpoch=e.expireTimeEpoch,t.minQty=1,t.source=ve.h.SPB;const i=new He;return i.destinationUrl=(0,Ie.ru)(e.destinationUrl||e.productUrl),i.url=e.productUrl,i.name=e.scope,i.promotionInformation=new $e,i.promotionInformation.minPurchaseValue=Number(e.minPurchaseValue),i.promotionInformation.rebateValue=Number(e.commissionValue),t.adsOffer=i,t.visibilityFeedbackUrlBase="",t.pathname=(0,Ie.en)(t.adsOffer.destinationUrl)?.pathname||"",t}}var Ve=Ze;class Ge{constructor(){(0,s.Z)(this,"ItemizedCashbackExactMatch",void 0),(0,s.Z)(this,"RelatedOffers",[]),(0,s.Z)(this,"AdsMetadata",void 0),(0,s.Z)(this,"pdpData",void 0),(0,s.Z)(this,"pdpActivatedData",void 0)}static Create(e){if(e?.offersType===ve.h.SPB){const t=new Ge;return t.ItemizedCashbackExactMatch=e.offer?Ve.Create(e.offer):void 0,e.relatedOffers&&(t.RelatedOffers=e.relatedOffers.map((e=>Ve.Create(e)))),t.AdsMetadata=e.adsMetadata,t}}static CreateFromPCResponse(e){const t=new Ge,i=(e?.value||[]).find((e=>e.position===r.zE.SPB_OFFERS)),n=Ve.CreateFromComparableOffer(i,e?.visibilityFeedbackUrl||"");return t.ItemizedCashbackExactMatch=n,t}}var je=Ge,ze=o(71544);class We{constructor(){(0,s.Z)(this,"title",void 0),(0,s.Z)(this,"offerUrl",void 0),(0,s.Z)(this,"imageUrl",void 0),(0,s.Z)(this,"originalPrice",void 0),(0,s.Z)(this,"newPrice",void 0),(0,s.Z)(this,"discountPercentage",void 0),(0,s.Z)(this,"shippingText",void 0),(0,s.Z)(this,"sellerName",void 0),(0,s.Z)(this,"id",void 0),(0,s.Z)(this,"priceDropPercentage",void 0),(0,s.Z)(this,"isTrendingOffer",void 0)}static Create(e){const t=new We;return t.title=e.title,t.offerUrl=e.offerUrl,t.imageUrl=e.imageUrl,t.originalPrice=e.originalPrice,t.newPrice=e.newPrice,t.discountPercentage=e.discountPercentage,t.shippingText=e.shippingText,t.id=e.id,t.priceDropPercentage=e.priceDropPercentage,t.isTrendingOffer=e.isTrendingOffer,t}}var Ke=We;class qe{constructor(){(0,s.Z)(this,"offerUrl",void 0),(0,s.Z)(this,"headerText",void 0),(0,s.Z)(this,"id",void 0)}static Create(e){const t=new qe;return t.offerUrl=e.offerUrl,t.headerText=e.headerText,t.id=e.id,t}}var Ye=qe,Xe=o(54774),Je=class{constructor(e,t){(0,s.Z)(this,"couponCode",void 0),(0,s.Z)(this,"title",void 0),(0,s.Z)(this,"attribution",void 0),(0,s.Z)(this,"isLowSuccessRateCoupon",void 0),(0,s.Z)(this,"isStackable",void 0),(0,s.Z)(this,"successRate",void 0),(0,s.Z)(this,"minimumPurchase",void 0),(0,s.Z)(this,"shortHeader",void 0),(0,s.Z)(this,"calculatedCutoffPrice",void 0),(0,s.Z)(this,"discountPercent",void 0),(0,s.Z)(this,"isPrivateCoupon",void 0),(0,s.Z)(this,"lastSuccessfulCouponTime",void 0),(0,s.Z)(this,"shouldDisplaySuccessRate",void 0),(0,s.Z)(this,"offerUrl",void 0),(0,s.Z)(this,"clickUrl",void 0),(0,s.Z)(this,"quota",void 0),(0,s.Z)(this,"startTime",void 0),(0,s.Z)(this,"expireTime",void 0),this.couponCode=e?.couponCode,this.title=e?.title,this.attribution=e?.attribution,this.isLowSuccessRateCoupon=e?.isLowSuccessRateCoupon,t===r.AS.Mobile?this.isStackable=!0:this.isStackable=e?.isStackable,this.successRate=e?.successRate,this.minimumPurchase=e?.minimumPurchase,this.shortHeader=e?.shortHeader,this.calculatedCutoffPrice=e?.calculatedCutoffPrice,this.discountPercent=e?.discountPercent,this.isPrivateCoupon=e?.isPrivateCoupon,this.lastSuccessfulCouponTime=e?.lastSuccessfulCouponTime,this.clickUrl=e?.clickUrl,this.quota=e?.quota,this.minimumPurchase=e?.minimumPurchase,this.startTime=e?.startTime,this.expireTime=e?.expireTime,this.offerUrl=e?.offerUrl}};class Qe{constructor(e,t,i){(0,s.Z)(this,"IsAutoApplyAvailable",void 0),(0,s.Z)(this,"Coupons",void 0),(0,s.Z)(this,"Trivia",void 0),(0,s.Z)(this,"FriendlyDomainName",void 0),(0,s.Z)(this,"DomainName",void 0),(0,s.Z)(this,"isCheckoutPageWithAutoApply",void 0),(0,s.Z)(this,"IsPackageTrackingEnabled",void 0),(0,s.Z)(this,"IsAmazonGiftCardEnabled",void 0),(0,s.Z)(this,"Deals",void 0),(0,s.Z)(this,"Recommendations",void 0),(0,s.Z)(this,"SavingsFound",void 0),(0,s.Z)(this,"BgaaResultState",void 0),(0,s.Z)(this,"BgaaSavings",void 0),(0,s.Z)(this,"BgaaViewedContent",void 0);const n=i.common.isCheckoutPage,o=i.common.currentDevice,r=i.dataLoader.GetLoadTimeDataValue("coupon",[]);if(i.common.isCJKEnabled){if(r){this.Coupons=[];for(const e of r)this.Coupons.push(new Je(e,o))}}else if(this.IsAutoApplyAvailable=t&&(!ze.Z.IsMobile()||Qe.shouldLoadOnMobile(i)),e){if(this.Coupons=[],e.coupons)for(const t of e.coupons)this.Coupons.push(new Je(t,o));if(this.Deals=[],e.deals)for(const t of e.deals)this.Deals.push(Ye.Create(t));if(this.Recommendations=[],e.recommendations)for(const t of e.recommendations)this.Recommendations.push(Ke.Create(t));e.retailerData&&(this.DomainName=e.retailerData.domainName,e.retailerData.retailerTrivia&&(this.Trivia=new N(e.retailerData.retailerTrivia,e.retailerData.domainName))),this.FriendlyDomainName=e.friendlyDomainName,this.IsPackageTrackingEnabled=e.isPackageTrackingEnabled,this.IsAmazonGiftCardEnabled=e.isAmazonGiftCardEnabled,this.isCheckoutPageWithAutoApply=(this.Coupons&&this.Coupons.length>0&&this.IsAutoApplyAvailable&&n)??!1,e?.savingsFound&&(this.SavingsFound=new class{constructor(e){(0,s.Z)(this,"TotalAutoApplySavingsAmount",void 0),(0,s.Z)(this,"LastUpdatedAutoApplySavingsTimestamp",void 0),(0,s.Z)(this,"ListOfAutoApplyTransactions",new Array),(0,s.Z)(this,"TotalCouponClippingSavingsAmount",void 0),(0,s.Z)(this,"LastUpdatedCouponClippingSavingsTimestamp",void 0),(0,s.Z)(this,"ListOfCouponClippingTransactions",new Array),(0,s.Z)(this,"TotalCashbackSavingsAmount",void 0),(0,s.Z)(this,"LastUpdatedCashbackSavingsTimestamp",void 0),(0,s.Z)(this,"ListOfCashbackTransactions",new Array),this.TotalAutoApplySavingsAmount=e?.totalAutoApplySavingsAmount,this.LastUpdatedAutoApplySavingsTimestamp=e?.lastUpdatedAutoApplySavingsTimestamp;const t=e?.listOfAutoApplyTransactions;if(t?.length>0)for(const e of t)this.ListOfAutoApplyTransactions.push(new Xe.Z(e));this.TotalCouponClippingSavingsAmount=e?.totalCouponClippingSavingsAmount,this.LastUpdatedCouponClippingSavingsTimestamp=e?.lastUpdatedCouponClippingSavingsTimestamp;const i=e?.listOfCouponClippingTransactions;if(i?.length>0)for(const e of i)this.ListOfCouponClippingTransactions.push(new Xe.Z(e));this.TotalCashbackSavingsAmount=e?.totalCashbackSavingsAmount,this.LastUpdatedCashbackSavingsTimestamp=e?.lastUpdatedCashbackSavingsTimestamp;const n=e?.listOfCashbackTransactions;if(n?.length>0)for(const e of n)this.ListOfCashbackTransactions.push(new Xe.Z(e))}}(e?.savingsFound));try{const e=i.dataLoader.GetLoadTimeDataValue(l.a.BgaaInfo,void 0);if(e){const t=JSON.parse(e);t&&(this.BgaaResultState=t.Result,this.BgaaSavings=t.Savings)}}catch(e){throw Error(e.message)}}}static shouldLoadOnMobile(e){const t=e.dataStoreModule.ApiData?.retailerData,i=t?.GetCurrentCheckoutPage(e.common.lastCommittedURL);return i?.edgeEnabled??!1}}var et=Qe,tt=o(3634),it=class{constructor(e,t){(0,s.Z)(this,"trackerKey",void 0),(0,s.Z)(this,"actionURL",void 0),(0,s.Z)(this,"orderSummary",void 0),(0,s.Z)(this,"domain",void 0),(0,s.Z)(this,"orderStatus",void 0),(0,s.Z)(this,"productsInOrder",void 0),e&&t&&(this.trackerKey=e.trackerKey,this.actionURL=e.actionURL,this.orderStatus=e.orderStatus,this.domain=e.domain,this.orderSummary=e.orderSummary,this.productsInOrder=t)}},nt=class{constructor(e,t){(0,s.Z)(this,"productImageUrl",void 0),(0,s.Z)(this,"productName",void 0),this.productImageUrl=e,this.productName=t}},ot=class{static async getPackageTrackingOrders(e,t,i){const n=[];if(i&&i.length>0)for(const e of i){const t=e?.listOfProducts,i=[];if(t){for(const e of t)this.isValidPackageTrackingProduct(e)&&i.push(new nt(e.productImageUrl,e.productName));this.isValidPackageTrackingOrder(e,i)&&n.push(new it(e,i))}}const o=await this.getMostUpToDateOrderData(e,t,n);return this.getUniqueOrdersBasedOnProductNames(o)}static async getMostUpToDateOrderData(e,t,i){const n=await t.getStorageString(Ce.Q.PackageTrackingUXOrderMetadata);let o=new Map;(0,p.TF)(n)||(o=new Map(JSON.parse(n)));const r=i.filter((t=>{if(void 0===t.trackerKey)return!1;const i=new class{constructor(e,t){(0,s.Z)(this,"shownTimeStamp",void 0),(0,s.Z)(this,"trackerKey",void 0),(0,s.Z)(this,"orderSummary",void 0),(0,s.Z)(this,"domain",void 0),(0,s.Z)(this,"orderStatus",void 0),e&&(this.trackerKey=e.trackerKey,this.orderStatus=e.orderStatus,this.domain=e.domain,this.orderSummary=e.orderSummary,this.shownTimeStamp=t)}}(t,(new Date).toUTCString()),n=o.get(t.trackerKey);if(void 0===n)return o.set(t.trackerKey,i),!0;const r=(new Date).toUTCString();return!(new Date(r).getTime()-new Date(n.shownTimeStamp).getTime()>tt.wB&&(this.isStaleOrderData(n,i)?(o.delete(t.trackerKey),e.DeletePackageTrackerByGuid(t.trackerKey),1):(o.set(t.trackerKey,i),0)))})),a=JSON.stringify(Array.from(o.entries()));return t.setStorageString(Ce.Q.PackageTrackingUXOrderMetadata,a),r}static isStaleOrderData(e,t){return e.trackerKey===t.trackerKey&&e.domain===t.domain&&e.orderStatus===t.orderStatus&&e.orderSummary===t.orderSummary}static isValidPackageTrackingProduct(e){return e&&!(0,p.TF)(e?.productImageUrl)&&!(0,p.TF)(e?.productName)}static isValidPackageTrackingOrder(e,t){const i=!(0,p.TF)(e?.orderSummary)&&!e?.orderSummary.toLowerCase().includes("cannot display")&&!e?.orderSummary.toLowerCase().includes("error");return e&&t&&t?.length>=1&&!(0,p.TF)(e?.trackerKey)&&!(0,p.TF)(e?.actionURL)&&!(0,p.TF)(e?.orderStatus)&&!(0,p.TF)(e?.domain)&&!(0,p.TF)(e?.orderSummary)&&i}static getArrayOfProductNames(e){const t=[];if(null==e||0===e.length)return t;for(const i of e)(0,p.TF)(i?.productName)||t.push(i?.productName);return t}static getUniqueOrdersBasedOnProductNames(e){return e.filter(((t,i)=>{const n=this.getArrayOfProductNames(t?.productsInOrder).sort().join("-");return i===e.findIndex((e=>{const t=this.getArrayOfProductNames(e?.productsInOrder).sort().join("-");return n===t}))}))}},rt=class{constructor(e,t,i,n,o){(0,s.Z)(this,"priceComparisonData",void 0),(0,s.Z)(this,"priceHistoryData",void 0),(0,s.Z)(this,"coupon",void 0),(0,s.Z)(this,"productTrackingData",void 0),(0,s.Z)(this,"cashbackData",void 0),this.coupon=e??void 0,this.priceComparisonData=t??void 0,this.priceHistoryData=i??void 0,this.productTrackingData=n??void 0,this.cashbackData=o??void 0}},at=o(96834),st=class{constructor(e){(0,s.Z)(this,"CouponCode",void 0),(0,s.Z)(this,"Domain",void 0),(0,s.Z)(this,"DiscountRate",void 0),(0,s.Z)(this,"SuccessRate",void 0),(0,s.Z)(this,"Timestamp",void 0),(0,s.Z)(this,"RetailerName",void 0),(0,s.Z)(this,"Title",void 0),(0,s.Z)(this,"ShouldDisplaySuccessRate",void 0),this.CouponCode=e.couponCode,this.Domain=e.domain,this.DiscountRate=e.discountRate,this.SuccessRate=e.successRate,this.Timestamp=e.timestamp,this.RetailerName=e.retailerName}};class lt{static async FetchAndCacheTrendingCoupons(e){const t=await fetch(this.TRENDING_COUPONS_URL,{signal:AbortSignal.timeout(5e3)}),i=await t.json();return i?.trendingCoupons?.length>0?this.ParseAndCacheTrendingCoupons(i.trendingCoupons,e):[]}static ParseAndCacheTrendingCoupons(e,t){const i=[];e.forEach((e=>{i.push(new st(e))}));const n=new at.Z;return n.stringValue=JSON.stringify(i),t.SetStorageValue(Ce.Q.TrendingCouponsData,n),i}static async LoadTrendingCouponsData(e){const t=(await e.GetStorageValue(Ce.Q.TrendingCouponsData))?.value?.stringValue;if(t){const e=JSON.parse(t);if(e&&!this.isCachedDataExpired(e))return e}return[]}static isCachedDataExpired(e){let t=new Date(0);return e.forEach((e=>{const i=new Date(e?.Timestamp);i&&i>t&&(t=i)})),(new Date).getTime()-t.getTime()>45e5}}(0,s.Z)(lt,"TRENDING_COUPONS_URL","https://www.bing.com/api/shopping/v1/savings/trending/getTrendingCoupons");var ct=lt,dt=o(65302),ut=o(65358),ht=class{constructor(e){(0,s.Z)(this,"RetailerName",void 0),(0,s.Z)(this,"Domain",void 0),(0,s.Z)(this,"Category",void 0),(0,s.Z)(this,"Timestamp",void 0),e&&(this.RetailerName=e.retailerName,this.Domain=e.domain,this.Category=e.category,this.Timestamp=e.timestamp)}};let pt=function(e){return e.Coupons="Coupons",e.ProductTracking="ProductTracking",e.CategoryDeals="CategoryDeals",e.Cashback="Cashback",e.PersonalizedCashback="PersonalizedCashback",e.ExclusiveCoupons="ExclusiveCoupons",e}({});class gt{static IsRelatedPdpScenario(e){const t=e?.Cashback?.pdpCashBack;return Boolean(t&&!t.pdpOffer&&e.relatedOffers&&e.relatedOffers.length>0)}SelectOffer(e,t,i,n,o){if(gt.IsRelatedPdpScenario(e))return e.relatedOffers[0]}}var ft=gt;class mt{static SelectOffer(e,t,i,n,o){for(const r of mt.strategies){const a=r.SelectOffer(e,t,i,n,o);if(a)return a}}}(0,s.Z)(mt,"strategies",[new class{SelectOffer(e,t,i,n,o){if(e&&e.Cashback?.pdpCashBack?.pdpOffer)return e.Cashback?.pdpCashBack?.pdpOffer}},new ft,new class{SelectOffer(e,t,i,n,o){const r=this.GetPdpOffer(i,n,o);if(r)return r}GetPdpOffer(e,t,i){const n=new URL(e.common.lastCommittedURL);let o;const r=(0,we.oC)(n);if(r.IsPDP&&t&&t.length>0)for(const e of t){const t=i[e];if(t.cashbackProducts[0].url){const e=new URL(t.cashbackProducts[0].url),i=(0,we.oC)(e);i.IsPDP&&i.ProductId===r.ProductId&&(o=t)}}return o}},new class{SelectOffer(e,t,i,n,o){const r=this.GetPdpOffer(i,e);if(r)return r}GetPdpOffer(e,t){const i=new URL(e.common.lastCommittedURL),n=(0,we.Sz)(i,t?.Cashback?.ItemizedCashback),o=(0,we.oC)(i);let r;if(t?.Cashback&&n){const e=o.ProductId;if(e){const i=t?.Cashback?.ItemizedCashback?.filter((i=>i.imageUrl&&i.cashbackProducts[0].title&&i.offerValue&&i.id&&i.cashbackProducts[0].upc&&i.cashbackProducts[0].url&&-1!==i.cashbackProducts[0].url.indexOf(e)&&!t?.Cashback?.ActivatedOffers.find((e=>e.id===i.id))&&!t?.Cashback?.SubmittedOfferIds.includes(i.id)));i&&i.length>0&&(r=i[0])}}return r}}]);var vt=mt,yt=o(47746);class Ct{static Create(e,t=""){const i=new Ct;return e?.offersType===ve.h.Quotient&&(i.pdpOffer=e.offer?yt.Z.Create(e.offer):void 0,e.relatedOffers&&(i.relatedOffers=e.relatedOffers.map((e=>yt.Z.Create(e))))),i.requestTraceId=t,i}constructor(){(0,s.Z)(this,"pdpOffer",void 0),(0,s.Z)(this,"relatedOffers",void 0),(0,s.Z)(this,"requestTraceId",""),(0,s.Z)(this,"pdpData",void 0),this.relatedOffers=[]}}var bt=Ct;const St=[{name:"Household",id:"15342811"},{name:"Personal care",id:"3760911"},{name:"Food",id:"16310101"},{name:"Baby",id:"10787321"},{name:"Beverages",id:"16310231"},{name:"Pet",id:"2619533011"}];class xt{static Create(e,t){const i=new xt;if(e&&e.itemizedCashback){for(const t of e.itemizedCashback)t.source===ve.h.Quotient&&i.ItemizedCashback.push(yt.Z.Create(t));if(Array.isArray(e.activatedOffers))for(const t of e.activatedOffers)i.ActivatedOffers?.push(yt.Z.Create(t));const n="amazon.com"===t?[...St]:[],o=e.categories?e.categories:n,r=new class{constructor(e,t,i){(0,s.Z)(this,"name",void 0),(0,s.Z)(this,"id",void 0),(0,s.Z)(this,"count",void 0),this.id=e,this.name=t,this.count=i}}(we.wB.popular.id,we.wB.popular.name);o.unshift(r);const a=0;if((a>0?o.slice(0,a):o).forEach((e=>{i.Categories.set(e.id,e.name)})),Array.isArray(e.submittedOfferIds))for(const t of e.submittedOfferIds)i.SubmittedOfferIds.push(t);i.Variations=e.variations?new Map(Object.entries(e.variations)):new Map,i.isCashBackEnabled=e.isCashBackEnabled??!1,i.isSearchEnabled=e.isSearchEnabled??!1,i.isAnonymousFlowEnabled=e.isAnonymousFlowEnabled??!1,i.isQAddToCartEnabled=Boolean("enabled"===i.Variations.get("isQAddToCartEnabled"))}return i}constructor(){(0,s.Z)(this,"ItemizedCashback",void 0),(0,s.Z)(this,"ActivatedOffers",void 0),(0,s.Z)(this,"SubmittedOfferIds",void 0),(0,s.Z)(this,"pdpCashBack",void 0),(0,s.Z)(this,"Categories",void 0),(0,s.Z)(this,"IsCategoryInSearchSupported",void 0),(0,s.Z)(this,"Variations",void 0),(0,s.Z)(this,"isCashBackEnabled",void 0),(0,s.Z)(this,"isSearchEnabled",void 0),(0,s.Z)(this,"isAnonymousFlowEnabled",void 0),(0,s.Z)(this,"isQAddToCartEnabled",void 0),this.ItemizedCashback=[],this.ActivatedOffers=[],this.SubmittedOfferIds=[],this.Categories=new Map,this.IsCategoryInSearchSupported=!1,this.Variations=new Map,this.isCashBackEnabled=!1,this.isSearchEnabled=!1,this.isAnonymousFlowEnabled=!1,this.isQAddToCartEnabled=!1}}var Tt=xt,wt=class{constructor(e){if((0,s.Z)(this,"category",void 0),(0,s.Z)(this,"entity",void 0),(0,s.Z)(this,"title",void 0),(0,s.Z)(this,"url",void 0),(0,s.Z)(this,"domain",void 0),(0,s.Z)(this,"newTimestamp",void 0),e&&(this.category=e.category,this.entity=new class{constructor(e){(0,s.Z)(this,"canonicalUrl",void 0),(0,s.Z)(this,"image",void 0),(0,s.Z)(this,"name",void 0),(0,s.Z)(this,"price",void 0),(0,s.Z)(this,"pageLocale",void 0),(0,s.Z)(this,"priceCurrency",void 0),(0,s.Z)(this,"priceValue",void 0),(0,s.Z)(this,"type",void 0),(0,s.Z)(this,"latestPrice",void 0),e&&(this.canonicalUrl=e.canonical_url,this.image=e.image,this.name=e.name,this.price=e["offers/price"],this.pageLocale=e.page_locale,this.priceCurrency=e.price_currency,this.priceValue=e.price_value,this.type=e.type,this.latestPrice=e.latestPrice)}}(e.entity),this.title=this.entity?.name??e.title,this.url=e.url,this.newTimestamp=e.newTimestamp,this.url)){const e=this.url.match(/:\/\/(www[0-9]?\.)?(.[^/:]+)/i);e&&e.length>2&&"string"==typeof e[2]&&(this.domain=e[2])}}},Ot=class{constructor(){(0,s.Z)(this,"cardOrder",void 0)}static Compare(e,t){return e.cardOrder-t.cardOrder}};class Pt{constructor(){(0,s.Z)(this,"rawValue",void 0),(0,s.Z)(this,"maxValue",void 0)}static createRating(e,t){if(t<1||e<0||e>t)return null;const i=new Pt;return i.rawValue=e,i.maxValue=t,i}get normalizedValue(){return Pt.NormalizedMaxRating*(this.rawValue/this.maxValue)}}(0,s.Z)(Pt,"NormalizedMaxRating",5);var At=Pt;class Et extends Ot{constructor(...e){super(...e),(0,s.Z)(this,"id",void 0),(0,s.Z)(this,"url",void 0),(0,s.Z)(this,"favIconDomain",void 0),(0,s.Z)(this,"provider",void 0),(0,s.Z)(this,"title",void 0),(0,s.Z)(this,"rating",void 0),(0,s.Z)(this,"caption",void 0),(0,s.Z)(this,"attribution",void 0)}static create(e,t,i,n,o,r,a,s,l,c){if(e&&i&&l&&!c?!o:!r)return null;const d=new Et;return d.id=e,d.cardOrder=t,d.url=i,d.favIconDomain=n,d.provider=o,d.title=r,d.caption=l,d.attribution=c,a&&s&&(d.rating=At.createRating(a,s)??void 0),d}}var kt=Et;let It=function(e){return e[e.H=0]="H",e[e.V=1]="V",e}({});class Dt extends Ot{constructor(...e){super(...e),(0,s.Z)(this,"id",void 0),(0,s.Z)(this,"cardOrientation",void 0),(0,s.Z)(this,"title",void 0),(0,s.Z)(this,"thumbnailId",void 0),(0,s.Z)(this,"thumbnailUrl",void 0),(0,s.Z)(this,"clickthroughUrl",void 0),(0,s.Z)(this,"publisher",void 0),(0,s.Z)(this,"creator",void 0),(0,s.Z)(this,"durationText",void 0),(0,s.Z)(this,"durationLabel",void 0),(0,s.Z)(this,"datePublished",void 0),(0,s.Z)(this,"viewCount",void 0)}static create(e,t,i,n,o,r,a,s,l,c,d,u){if(!e||!n||!a||!o&&!r)return null;const h=new Dt;if(h.id=e,h.cardOrder=t,h.cardOrientation=i?.toUpperCase()===It[It.H]?It.H:It.V,h.title=n,h.thumbnailId=o,h.thumbnailUrl=r,h.clickthroughUrl=a,h.publisher=s,h.creator=l,h.datePublished=d,h.viewCount=u,c>0){const e=Math.floor(c/60),t=Math.round(c)%60,i=t<10?"0"+t:t;h.durationText=e+":"+i,h.durationLabel=e>0?`${e} minutes ${i} seconds`:`${i} seconds`}return h}static Narrow(e){return"clickthroughUrl"in e?e:void 0}}var _t=Dt;class Nt{constructor(){(0,s.Z)(this,"sectionTitle",void 0),(0,s.Z)(this,"entityName",void 0),(0,s.Z)(this,"expertReviews",void 0),(0,s.Z)(this,"videos",void 0),(0,s.Z)(this,"metaData",void 0)}Create(e,t){if(e){const i=new Nt;if(i.sectionTitle=e.sectionTitle,i.entityName=t?.entity?.name??t?.title,Array.isArray(e.professionalReviews?.reviews)){const t=[];for(const i of e.professionalReviews.reviews){const e=this.createExpertReview(i);e&&t.push(e)}t.length>0&&(i.expertReviews=t)}if(Array.isArray(e.videoReviews?.reviews)){const t=[];for(const i of e.videoReviews.reviews){const e=this.createVideo(i);e&&t.push(e)}t.length>0&&(i.videos=t)}return e.metaData&&(i.metaData=e.metaData),i.expertReviews||i.videos?i:void 0}}createExpertReview(e){if(e&&e.publisher){let t;try{t=new URL(e.iconUri??e.url).hostname}catch{}return kt.create(e.id,e.cardOrder,e.url,t,e.publisher,e.title,e.rating?.value,e.rating?.maxValue,e.caption,e.attribution)}return null}createVideo(e){if(e?.publisher||e?.creator){const t=e.clickthroughUrl??e.contentUrl;return _t.create(e.id,e.cardOrder,e.cardOrientation,e.title,e.thumbnailId,e.thumbnailUrl,t,e.publisher,e.creator,e.lengthSeconds,e.datePublished,e.viewCount)}return null}get totalCards(){return this.expertReviews?.length??0}get hasExpertReviews(){return!!this.expertReviews&&this.expertReviews.length>0}get hasVideos(){return!!this.videos&&this.videos.length>0}}var Rt=Nt,Mt=o(33105),Lt=o(64106);class Bt{constructor(){(0,s.Z)(this,"guides",[]),(0,s.Z)(this,"name",void 0)}static Create(e,t,n){if(e)try{const t=new Bt,i=n&&n.split("-")[0]||"";let o;return e?.rRCategoryInsights?.buyingGuides&&(o=e.rRCategoryInsights.buyingGuides.find((e=>e?.lang&&e.lang===i)),void 0===o&&(o=e.rRCategoryInsights.buyingGuides[0])),t.guides=o?.buyingGuides.map((e=>{const[t,i]=e.split(":").reverse();return{title:i.trim(),description:t.trim()}}))||[],t.name=e.rRCategoryInsights?.name||"",t.IsValid()?t:void 0}catch(e){t?.LogErrorTelemetry("Error creating BuyingGuides","",void 0,e,{dataSource:"BuyingGuides"},i.xu.DiscoverModuleDataPrepError)}}IsValid(){return this?.guides?.length>0}}var Ft=Bt,Ut=o(35386);class Ht{constructor(){(0,s.Z)(this,"ChatChips",void 0)}static Create(e,t,n,o){const r=new Ht;try{r.ChatChips=this.MakeChatChips(e,t,n,o)}catch(e){o?.LogErrorTelemetry("Error creating ChatChipsData","",void 0,e,{dataSource:"ChatChipsData"},i.xu.DiscoverModuleDataPrepError)}return r}static MakeChatChips(e,t,i,n){const o=new Set([Mt.k.BuyingGuides,Mt.k.ProductSummary,Mt.k.ReviewsSummary,Mt.k.PreviouslyViewedSimilar]),a=i?.suggestionChips||[],s=new Map;a.forEach((e=>{o.has(e.action)&&s.set(e.action,e)}));const l={},c=this.MakeChatChipsTextForModulesMap(e),d=this.MakeChatChipsTextFromLoadTimeData(e),u=e.common.journeyStage||Ut.v.UNDEFINED,h=e.common.afdMarket.startsWith("en-"),p=e.common.lastCommittedURL;if(t?.BuyingGuideData){let e="";e=s.has(Mt.k.BuyingGuides)?s.get(Mt.k.BuyingGuides)?.displayText||"":this.GetString(r.ModuleNames.BUYING_GUIDES,c,d,u,h,n,p),e&&(l[r.ModuleNames.BUYING_GUIDES]=e)}if(t?.SmartCompareData){let e="";e=s.has(Mt.k.PreviouslyViewedSimilar)?s[Mt.k.PreviouslyViewedSimilar]?.displayText||"":this.GetString(r.ModuleNames.SMART_COMPARE,c,d,u,h,n,p),e&&(l[r.ModuleNames.SMART_COMPARE]=e)}if(t?.ProductSummaryData){let e="";e=s.has(Mt.k.ProductSummary)?s.get(Mt.k.ProductSummary)?.displayText||"":s.has(Mt.k.ReviewsSummary)?s.get(Mt.k.ReviewsSummary)?.displayText||"":this.GetString(r.ModuleNames.PRODUCT_SUMMARY,c,d,u,h,n,p),e&&(l[r.ModuleNames.PRODUCT_SUMMARY]=e)}return l}static GetString(e,t,i,n,o,r,a){this.LogNoDynamicChipString(e,a,r);const s=i[e];if(s&&n in s){const e=s[n],t=this.GetTextForMarket(o,e?.en||"",e?.notEn||"");if(t)return t}const l=t[e];return l?l[n]:""}static GetTextForMarket(e,t,i){return e&&t?t:i}static MakeChatChipsTextFromLoadTimeData(e){return{[r.ModuleNames.SMART_COMPARE]:{[Ut.v.UNDEFINED]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipFindSimilarProduct","")},[Ut.v.DISCOVER]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipCompareSimilarProduct","")},[Ut.v.RESEARCH]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipComparePrevious","")},[Ut.v.DECISION]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipComparePrevious","")}},[r.ModuleNames.BUYING_GUIDES]:{[Ut.v.UNDEFINED]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipViewBuyingGuide","")},[Ut.v.DISCOVER]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipViewBuyingGuide","")},[Ut.v.RESEARCH]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipViewBuyingGuide","")},[Ut.v.DECISION]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipViewBuyingGuide","")}},[r.ModuleNames.PRODUCT_SUMMARY]:{[Ut.v.UNDEFINED]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipGetInsights","")},[Ut.v.DISCOVER]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipGetInsights","")},[Ut.v.RESEARCH]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipGetInsights","")},[Ut.v.DECISION]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipGetInsights","")}},[r.ModuleNames.PRICECOMPARISON]:{[Ut.v.UNDEFINED]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipComparePrices","")},[Ut.v.DISCOVER]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipComparePrices","")},[Ut.v.RESEARCH]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipComparePrices","")},[Ut.v.DECISION]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipComparePrices","")}},[r.ModuleNames.PRICEHISTORY]:{[Ut.v.UNDEFINED]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipViewPriceHistory","")},[Ut.v.DISCOVER]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipViewPriceHistory","")},[Ut.v.RESEARCH]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipViewPriceHistory","")},[Ut.v.DECISION]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipViewPriceHistory","")}},[r.ModuleNames.PRODUCT_COLLECTIONS]:{[Ut.v.UNDEFINED]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipProductCollection","")},[Ut.v.DISCOVER]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipProductCollection","")},[Ut.v.RESEARCH]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipProductCollection","")},[Ut.v.DECISION]:{notEn:e.dataLoader.GetLoadTimeDataValue("chatChipProductCollection","")}}}}static MakeChatChipsTextForModulesMap(e){return{[r.ModuleNames.SMART_COMPARE]:{[Ut.v.UNDEFINED]:e.strings.chatChipFindSimilarProduct,[Ut.v.DISCOVER]:e.strings.chatChipCompareSimilarProduct,[Ut.v.RESEARCH]:e.strings.chatChipComparePrevious,[Ut.v.DECISION]:e.strings.chatChipComparePrevious},[r.ModuleNames.BUYING_GUIDES]:{[Ut.v.UNDEFINED]:e.strings.chatChipViewBuyingGuide,[Ut.v.DISCOVER]:e.strings.chatChipViewBuyingGuide,[Ut.v.RESEARCH]:e.strings.chatChipViewBuyingGuide,[Ut.v.DECISION]:e.strings.chatChipViewBuyingGuide},[r.ModuleNames.PRODUCT_SUMMARY]:{[Ut.v.UNDEFINED]:e.strings.chatChipGetInsights,[Ut.v.DISCOVER]:e.strings.chatChipGetInsights,[Ut.v.RESEARCH]:e.strings.chatChipGetInsights,[Ut.v.DECISION]:e.strings.chatChipGetInsights},[r.ModuleNames.PRICECOMPARISON]:{[Ut.v.UNDEFINED]:e.strings.chatChipComparePrices,[Ut.v.DISCOVER]:e.strings.chatChipComparePrices,[Ut.v.RESEARCH]:e.strings.chatChipComparePrices,[Ut.v.DECISION]:e.strings.chatChipComparePrices},[r.ModuleNames.PRICEHISTORY]:{[Ut.v.UNDEFINED]:e.strings.chatChipViewPriceHistory,[Ut.v.DISCOVER]:e.strings.chatChipViewPriceHistory,[Ut.v.RESEARCH]:e.strings.chatChipViewPriceHistory,[Ut.v.DECISION]:e.strings.chatChipViewPriceHistory},[r.ModuleNames.PRODUCT_COLLECTIONS]:{[Ut.v.UNDEFINED]:e.strings.chatChipProductCollection,[Ut.v.DISCOVER]:e.strings.chatChipProductCollection,[Ut.v.RESEARCH]:e.strings.chatChipProductCollection,[Ut.v.DECISION]:e.strings.chatChipProductCollection}}}static LogNoDynamicChipString(e,t,n){n?.LogEventTelemetry(i.xu.DiscoverChatChipMissingText,"No dynamic chip data for module from UAPI","",e,{url:t})}}var $t=Ht,Zt=o(47594);class Vt{constructor(){(0,s.Z)(this,"popularOpinions",[]),(0,s.Z)(this,"prosOpinions",[]),(0,s.Z)(this,"consOpinions",[]),(0,s.Z)(this,"summary",""),(0,s.Z)(this,"topInsights",[]),(0,s.Z)(this,"hasLinks",!1)}static Create(t,n,o){if(t)try{const i=new Vt,o=t?.attributes?.productInsightData;let r,a="";if(o&&o?.length>0&&(a=o[0].productSummary,r=o[0].offerId64),!r||!a)return;i.summary=a;const s=e.R.isTestFlagActive(Zt.t.msShoppingTestExp10);if(i.hasLinks=s,n?.rROfferInsights&&r){const e=n.rROfferInsights[r],t=[],o=[],a=[];e?.aspects?.forEach((e=>{if(e?.aggregateRating&&e?.name&&e?.aggregateRatingCount){const i={aggregateRating:e?.aggregateRating,aggregateRatingCount:e?.aggregateRatingCount,name:e?.name};t.push(i)}})),e?.prosAndCons?.forEach((e=>{e?.pros?.forEach((e=>{o.push(e.text)})),e?.cons?.forEach((e=>{a.push(e.text)}))})),i.popularOpinions=t,i.prosOpinions=o,i.consOpinions=a,i.topInsights=e?.insights?.map((e=>({title:e?.displayString||""})))??[],i.topInsights=i.topInsights.filter((e=>!!e.title))}return i.IsValid()?i:void 0}catch(e){o?.LogErrorTelemetry("Error creating ProductSummaryData","",void 0,e,{dataSource:"ProductSummaryData"},i.xu.DiscoverModuleDataPrepError)}}IsValid(){return!!this?.summary?.length||this?.popularOpinions?.length>0||this?.topInsights?.length>0}}var Gt=Vt;class jt{constructor(){(0,s.Z)(this,"smartCompareOptions",[]),(0,s.Z)(this,"comparedAttributes",[])}static Create(t,n,o){if(t)try{const i=new jt,o=t.offersAttributes?.offers||[];if(0===o.length)return;const r=t.offersAttributes?.attributes?.productInsightData||[],a=[],s=t.offersAttributes?.attributes?.attributes||[],l={};s.forEach((e=>{const t={};r.forEach((i=>{const n=i?.attributes||{},o=Object.keys(n).find((t=>t&&t.toLowerCase()===e?.toLowerCase()));o&&i?.offerId64&&(t[i.offerId64]=n[o])})),l[e]=t})),Object.keys(l).forEach((e=>{Object.keys(l[e]).length<2&&delete l[e]}));for(let t=0;t<o.length;t++){const i=o[t],s=Object.keys(l).map((e=>({name:e,value:i?.offerId64?l[e][i.offerId64]??"N/A":"N/A",best:!1})))||[],c=r[t]?.productSummary||"";let d,u="";const h=i?.extensions;if(h&&h?.find((e=>16253===e?.typeId))&&(u="Free shipping"),!e.R.isTestFlagActive(Zt.t.msShoppingTestExp6)&&n?.rROfferInsights&&i.offerId){const e=n.rROfferInsights[i.offerId];e&&(e.aggregateRating&&e.aggregateRatingCount&&!d&&(d={rating:e.aggregateRating,numberOfReviews:e.aggregateRatingCount}),e.insights.length>0&&!u&&(u=e.insights[0].displayString))}const p={image:i.images&&i.images.length>0?i.images[0].imageUrl:"",title:i.title||"",originalPrice:i.originalPrice||"",currentPrice:i.dealPrice||"",iconText:u,retailerName:i.seller||"",retailerLogoImg:"",url:i.destinationUrl||"",description:i.description||"",specs:s,summary:c,buyingOptions:[],ratingReviews:d};a.push(p)}if(0===a.length)return;return i.smartCompareOptions=a,i.comparedAttributes=t.offersAttributes?.attributes?.attributes||[],i}catch(e){return void o?.LogErrorTelemetry("Error creating SmartCompareData","",void 0,e,{dataSource:"SmartCompareData"},i.xu.DiscoverModuleDataPrepError)}}}var zt=jt;class Wt{constructor(){(0,s.Z)(this,"SmartCompareData",void 0),(0,s.Z)(this,"ProductSummaryData",void 0),(0,s.Z)(this,"BuyingGuideData",void 0),(0,s.Z)(this,"ChatChipsData",void 0)}static Create(e,t,i,n){const o=new Wt;if(!e||!e.baseShoppingDataList||0===e.baseShoppingDataList.length)return o;const r=t&&i?new Lt.Z(t,i,n):void 0,a=e.baseShoppingDataList.find((e=>e?.contentDataType===Mt.q.OfferInsights||e?._type===Mt.q.OfferInsights)),s=e.baseShoppingDataList.find((e=>e?.contentDataType===Mt.q.PreviouslyViewedSimilar));o.SmartCompareData=s?zt.Create(s,a,r):void 0;const l=e.baseShoppingDataList.find((e=>e?.contentDataType===Mt.q.ProductSummary));o.ProductSummaryData=Gt.Create(l,a,r);const c=e.baseShoppingDataList.find((e=>e?.contentDataType===Mt.q.CategoryInsights)),d=t.common.afdMarket||"";o.BuyingGuideData=Ft.Create(c,r,d);const u=e.baseShoppingDataList.find((e=>e?.contentDataType===Mt.q.DynamicSuggestionChips));return o.ChatChipsData=$t.Create(t,o,u,r),o}}var Kt=Wt;class qt{}(0,s.Z)(qt,"insightsTemplate",["x_users_addedtocart_inlast_y_month","x_users_purchased_inlast_y_month","x_users_viewed_inlast_y_month","x_users_addedtocart_inlast_y_days","x_users_purchased_inlast_y_days","x_users_viewed_inlast_y_days","x_users_addedtocart_inlast_y_day","x_users_purchased_inlast_y_day","x_users_viewed_inlast_y_day","addedtocart_x_days_ago","purchased_x_days_ago","viewed_x_days_ago","addedtocart_x_day_ago","purchased_x_day_ago","viewed_x_day_ago","addedtocart_x_hours_ago","purchased_x_hours_ago","viewed_x_hours_ago","addedtocart_x_hour_ago","purchased_x_hour_ago","viewed_x_hour_ago","addedtocart_x_minutes_ago","purchased_x_minutes_ago","viewed_x_minutes_ago","addedtocart_x_minute_ago","purchased_x_minute_ago","viewed_x_minute_ago","addedtocart_x_seconds_ago","purchased_x_seconds_ago","viewed_x_seconds_ago"]);var Yt=qt;class Xt{constructor(e){(0,s.Z)(this,"couponEmptyCouponSubTitle","We couldn't find any coupons at this time."),(0,s.Z)(this,"couponEmptyCouponTitle","Check back for coupons!"),(0,s.Z)(this,"couponAutoApplyButton","Try all coupons"),(0,s.Z)(this,"couponAutoApplyButtonRetry","Retry all coupons"),(0,s.Z)(this,"couponAutoApplyButtonAlt","Apply Coupons"),(0,s.Z)(this,"couponAutoApplyButtonInstantSavings","Apply Coupon"),(0,s.Z)(this,"couponFeatureName","coupons"),(0,s.Z)(this,"couponCarouselLabel","coupon carousel"),(0,s.Z)(this,"cashbackAvailable","cashback offer"),(0,s.Z)(this,"cashbackHistoryHeader","Recent history"),(0,s.Z)(this,"cashbackHistorySeeFull","See full History"),(0,s.Z)(this,"cashbackHistorySeeMore","See more"),(0,s.Z)(this,"cashbackHistorySeeLess","See less"),(0,s.Z)(this,"cashbackActivatedOffersHeader","Activated offers"),(0,s.Z)(this,"cashbackActivatedOffersSeeFull","See all offers"),(0,s.Z)(this,"cashbackActivatedOffersSeeMore","See more"),(0,s.Z)(this,"cashbackActivatedOffersSeeLess","See less"),(0,s.Z)(this,"cashbackEnrollSuccessMessage","Welcome to Microsoft Cashback"),(0,s.Z)(this,"cashbackEnrollSuccessLink","Browse cash back offers"),(0,s.Z)(this,"cashbackWelcomeBannerHeader","Welcome to Microsoft Cashback!"),(0,s.Z)(this,"cashbackWelcomeBannerBody","Check back here as you shop for updates on your cashback earnings."),(0,s.Z)(this,"cashbackCarouselStepOne","1. Shop in Microsoft Edge and you'll be notified when cashback is available at a store"),(0,s.Z)(this,"cashbackCarouselStepTwo","2. Activate cashback to earn money back for any eligible purchase you make at the store"),(0,s.Z)(this,"cashbackCarouselStepThree","3. Complete your purchase, wait a few days, and get your cash back through PayPal"),(0,s.Z)(this,"cashbackCarouselLegalese","You will be signed in to Microsoft Edge which will back up your browsing data and let you see your favorites, passwords, history and more on all your devices. You will also join and receive emails about $1, which include offers about partners."),(0,s.Z)(this,"cashbackRedeemBannerTitle","You have $1 ready to cash out."),(0,s.Z)(this,"cashbackRedeemBannerLinkText","Redeem your cash back"),(0,s.Z)(this,"cashbackActivatedOfferTimePrefix","Ends in"),(0,s.Z)(this,"cashbakcActivatedOfferHourSymbol","h"),(0,s.Z)(this,"cashbackActivatedOfferMinuteSymbol","m"),(0,s.Z)(this,"cashbackProductOfferLinkText","View item"),(0,s.Z)(this,"cashbackProductOfferPostfix","back"),(0,s.Z)(this,"cashbackRetailerOfferLinkText","Continue shopping"),(0,s.Z)(this,"cashbackRetailerOfferPostfix","back with $1 purchase"),(0,s.Z)(this,"cashbackTopOfferPostTag","back"),(0,s.Z)(this,"cashbackTopOfferPostUsageCount","uses today"),(0,s.Z)(this,"cashbackTopOfferTitle","Top cash back offers"),(0,s.Z)(this,"articlesCashbackFeatureName","Articles Cashback"),(0,s.Z)(this,"autoApplyFeatureName","Auto Apply Coupons"),(0,s.Z)(this,"mergedNewAutoApplyButton","Apply coupons & cash back"),(0,s.Z)(this,"backgroundAutoApplyFeatureName","Background Auto Apply Coupons"),(0,s.Z)(this,"pcBestPriceHeader","You have the best price!"),(0,s.Z)(this,"pcBestPriceRefreshHeader","You have the $1"),(0,s.Z)(this,"pcBestPriceTitle","Best price"),(0,s.Z)(this,"priceCompareCashback","$1 cash back"),(0,s.Z)(this,"priceCompareWithCashback","with $1 cash back"),(0,s.Z)(this,"priceCompareCashBackShort","$1 back"),(0,s.Z)(this,"pcNow","$1 now"),(0,s.Z)(this,"pcLowest","Lowest"),(0,s.Z)(this,"pcLowestUpdated","Lowest Price"),(0,s.Z)(this,"pcSmallSavingsHeader","Compare Price at other Stores"),(0,s.Z)(this,"pcNotificationSeeMoreInfo","See more offers"),(0,s.Z)(this,"pcNotificationVisitItem","Visit item"),(0,s.Z)(this,"pcNotificationShopAt","Shop at $1"),(0,s.Z)(this,"commonCMAutoShowDisable","Don't show this automatically"),(0,s.Z)(this,"commonCMAutoShowDisableFeature","Don't show $1 again"),(0,s.Z)(this,"commonCMAutoShowEnable","Show this flyout automatically"),(0,s.Z)(this,"commonCMAutoShowEnableFeature","Show $1 automatically"),(0,s.Z)(this,"commonSnoozeShopping","Snooze shopping notifications"),(0,s.Z)(this,"turnOffSnooze","Turn off snooze"),(0,s.Z)(this,"snoozeTooltip","Snooze"),(0,s.Z)(this,"snoozeAllNotifications","Snooze all notifications"),(0,s.Z)(this,"snoozeAllNotificationsTooltip","Snooze all notifications for 8 hours"),(0,s.Z)(this,"snoozeDomainNotifications","Snooze notifications for this site"),(0,s.Z)(this,"snoozeDomainNotificationsTooltip","Snooze notifications for this site for 8 hours"),(0,s.Z)(this,"snoozeOneDomainNotification","Snooze $1 for this site"),(0,s.Z)(this,"snoozeOneDomainNotificationTooltip","Snooze $1 for this site for 8 hours"),(0,s.Z)(this,"remindLater","Remind me later"),(0,s.Z)(this,"commonCMManage","Manage Settings"),(0,s.Z)(this,"commonManageNotifications","Manage notifications"),(0,s.Z)(this,"commonShoppingSettings","Shopping settings"),(0,s.Z)(this,"commonAltSettings","Settings and more"),(0,s.Z)(this,"commonMoreOptionsLabel","More options"),(0,s.Z)(this,"commonContextualTab","Shopping assistant"),(0,s.Z)(this,"commonHomeTab","Discover"),(0,s.Z)(this,"commonMyShoppingTab","Your Shopping Stuff"),(0,s.Z)(this,"commonExploreTab","Explore"),(0,s.Z)(this,"commonErrorTitle","It's not you, it's us"),(0,s.Z)(this,"commonErrorSubTitle","We will be back soon"),(0,s.Z)(this,"commonLearnMore","Learn more"),(0,s.Z)(this,"termsAndConditions","Terms & conditions"),(0,s.Z)(this,"commonMonth","month"),(0,s.Z)(this,"commonNow","now"),(0,s.Z)(this,"commonSave","Save $1"),(0,s.Z)(this,"commonSaveSimple","Save"),(0,s.Z)(this,"commonSaveOtherSellers","Save from other sellers"),(0,s.Z)(this,"itemizedCashBackAddToCart","Add to Cart ($1 cash back)"),(0,s.Z)(this,"itemizedCashBackSpbAddToCart","Add to cart"),(0,s.Z)(this,"itemizedCashBackSpbAutoATC","Add to cart with cash back activated"),(0,s.Z)(this,"itemizedCashBackSpbAutoActivate","Cashback activated for you"),(0,s.Z)(this,"commonMicrosoftRewards","Microsoft Rewards"),(0,s.Z)(this,"commonMicrosoftCashback","Cashback account"),(0,s.Z)(this,"commonAriaLogo","$1 logo"),(0,s.Z)(this,"commonGotIt","Got it"),(0,s.Z)(this,"commonPrivacy","Privacy"),(0,s.Z)(this,"commonInternationalDisclaimer","Shopping data shown here is gathered periodically and it may not be completely accurate at all times."),(0,s.Z)(this,"commonPersonalizationSettings","Personalization settings"),(0,s.Z)(this,"couponCopied","Copied"),(0,s.Z)(this,"couponCopyLabel","Copy code"),(0,s.Z)(this,"couponCopyLabelRefresh","Copy"),(0,s.Z)(this,"couponCopyAndApply","Copy & apply"),(0,s.Z)(this,"couponTitle","Coupons found!"),(0,s.Z)(this,"couponTitleApply","Apply coupons found"),(0,s.Z)(this,"couponWithSiteTitle","This site has coupons!"),(0,s.Z)(this,"couponTitleWithNumStr","{NUMBER, plural, =1 {1 Coupon found} other {# Coupons found}}"),(0,s.Z)(this,"couponTitleInstantSavings","Save with coupons"),(0,s.Z)(this,"couponExpandableTitleViewCoupons","View coupons"),(0,s.Z)(this,"couponExpandableTitleWithNumStr","{NUMBER, plural, =1 {1 coupon found} other {# coupons found}}"),(0,s.Z)(this,"socialCouponShop","Shop!"),(0,s.Z)(this,"pdpApplyCoupons","Apply coupons at checkout"),(0,s.Z)(this,"pdpApplyBestCoupon","Apply at checkout"),(0,s.Z)(this,"productBestCouponFeatureName","Product best coupon"),(0,s.Z)(this,"bestCouponAriaLabel","Copy current product best coupon: $1"),(0,s.Z)(this,"bestCouponCopiedAriaLabel","Copied coupon code: $1"),(0,s.Z)(this,"savePDPTitle","Save at checkout on $1"),(0,s.Z)(this,"savePDPTitleNoTrivia","Save at checkout"),(0,s.Z)(this,"dealsFeatureName","deals"),(0,s.Z)(this,"bgaaFeatureName","Background Auto Apply"),(0,s.Z)(this,"bgaaSuccessLeftTitle","You could save"),(0,s.Z)(this,"bgaaSuccessRightTitle","Coupon Success"),(0,s.Z)(this,"bgaaSuccessRightText","Very high"),(0,s.Z)(this,"bgaaFailedTitle","You have the best price"),(0,s.Z)(this,"bgaaFailedLeftTitle","coupons"),(0,s.Z)(this,"bgaaFailedLeftText","✓ All checked"),(0,s.Z)(this,"bgaaFailedRightTitle","Results"),(0,s.Z)(this,"bgaaFailedRightText","No valid coupons"),(0,s.Z)(this,"bgaaModuleMessage","Save $1 on your cart with coupon $2"),(0,s.Z)(this,"bgaaModuleCouponCountMessage","{NUMBER, plural, =1 {We checked 1 coupon} other {We checked # coupons}}"),(0,s.Z)(this,"bgaaModuleApplyCoupon","Apply coupon"),(0,s.Z)(this,"couponAutoApplyWithoutCB","Try all coupons without cash back"),(0,s.Z)(this,"commonFixedTitle","Shopping"),(0,s.Z)(this,"commonFixedTitleNew","Microsoft Shopping"),(0,s.Z)(this,"commonMicrosoftPolicy","Microsoft Privacy Statement"),(0,s.Z)(this,"commonMicrosoftTermsOfUse","Microsoft Terms of Use"),(0,s.Z)(this,"commonSeeMore","Show more"),(0,s.Z)(this,"thirdPartCookiesText","third-party cookies"),(0,s.Z)(this,"commonClear","Clear"),(0,s.Z)(this,"commonSearch","Search"),(0,s.Z)(this,"commonClose","Close"),(0,s.Z)(this,"doNotShowString","Do not show"),(0,s.Z)(this,"snoozeButton","Snooze"),(0,s.Z)(this,"ariaSnoozeOn","Snooze on"),(0,s.Z)(this,"ariaSnoozeoff","Snooze off"),(0,s.Z)(this,"pcPriceSectionTitle","Compare with other retailers"),(0,s.Z)(this,"newpcPriceSectionTitle","Buying options"),(0,s.Z)(this,"pcTooltipText","Microsoft may receive compensation for clicks on these products, but such compensation has no effect on the ranking or relevance of results."),(0,s.Z)(this,"pcAffiliateTooltipLabel","Affiliate disclaimer"),(0,s.Z)(this,"cbActivateButtonRefresh","OK"),(0,s.Z)(this,"cbActivateButton","Activate"),(0,s.Z)(this,"cbCashbackButtonActivated","Activated"),(0,s.Z)(this,"cbBingJoinAndActivate","Join now and activate"),(0,s.Z)(this,"cbBingActivateButton","Join now and activate cash back"),(0,s.Z)(this,"cbBingActivateButtonDelayedEnrollment","Sign in to get cash back"),(0,s.Z)(this,"pcbLinkMsaActivateButton","Link personal account to earn"),(0,s.Z)(this,"cbActivatedButton","Cash back is activated!"),(0,s.Z)(this,"pcbActivatedButton","Cash back activated"),(0,s.Z)(this,"cbLearnMore","See offer details on Microsoft Cashback"),(0,s.Z)(this,"cbLearnMoreFlyout","See offer details and exclusions"),(0,s.Z)(this,"cbLearnMoreNew","See offer details"),(0,s.Z)(this,"cbReceiveCashBackTitle","Receive cash back after purchase"),(0,s.Z)(this,"cbDelayedCashBackSigninAnytimeMessage","Sign in any time before purchase"),(0,s.Z)(this,"cbOfferDetailsButtonTitle","Offer details"),(0,s.Z)(this,"cbOfferSeeLessButtonTitle","See less"),(0,s.Z)(this,"cbConfirmationTitle","Thanks for shopping with Microsoft Cashback!"),(0,s.Z)(this,"pcbConfirmationTitle","You can earn up to $1 cash back with $2"),(0,s.Z)(this,"pcbBingRebates","Microsoft Cashback!"),(0,s.Z)(this,"instantcbBingRebates","Microsoft Cashback"),(0,s.Z)(this,"EnrollSuccessTitle","Welcome to Microsoft Cashback!"),(0,s.Z)(this,"cbAutoShowTitle","Get cash back"),(0,s.Z)(this,"cbAutoShowButtonMessage","Activate up to $1 cashback"),(0,s.Z)(this,"instantcbConfirmationMessage","And you'll receive email updates for this cash back offer."),(0,s.Z)(this,"cbConfirmationMessage","You'll get cash back for any eligible purchases. We'll let you know in the next few days."),(0,s.Z)(this,"cbConfirmationEnrollBonusMessage","Your order qualifies for this special offer. Join Microsoft Cashback and get $20 welcome bonus. Offer available to new users. Limit one per user."),(0,s.Z)(this,"cbConfirmationEnrollBonusSuccessMessage","Congratulations! You received $20 as welcome bonus in your $1. You will also receive confirmation about your bonus cash back in your email. Keep shopping on Microsoft Edge to earn more cash back."),(0,s.Z)(this,"pcbConfirmationMessage","The funds can be redeemed within 90 days, when the sale is confirmed. We'll email you to let you know if it's available"),(0,s.Z)(this,"cbTurnedOffTitle","Microsoft Cashback*br*was turned off for this purchase"),(0,s.Z)(this,"cbTurnedOffTitleMsftCashback","Microsoft Cashback"),(0,s.Z)(this,"cbTurnedOffDescription","was turned off for this purchase"),(0,s.Z)(this,"cbTurnedOffMessage","Sometimes this happens when you use another coupon or cash back service. But you can easily turn it back on to earn cash back."),(0,s.Z)(this,"cbDontFindAutomatically","Don't show cash back"),(0,s.Z)(this,"cbFindAutomatically","Show cash back when available"),(0,s.Z)(this,"cbExclusiveBadgeText","Exclusive Offer from Microsoft"),(0,s.Z)(this,"cbIncentiveExclusiveBadgeText","Exclusive on Microsoft Edge"),(0,s.Z)(this,"notificationPrivacyTitle","Microsoft Edge may remind you of products you've visited to help you save time and money."),(0,s.Z)(this,"notificationPrivacyDesc","If you are shopping in InPrivate mode, you will never be reminded about products you visit. If you wish to turn off reminders for a product, you can click 'Don't remind me again for this product' (below). Additional controls can be found under the '…' menu at the top right of this popup. If you wish to disable Shopping in Microsoft Edge entirely, you can visit 'Manage Edge Shopping'."),(0,s.Z)(this,"reminderDisabled","Disable shopping reminders"),(0,s.Z)(this,"reminderEnabled","Enable shopping reminders"),(0,s.Z)(this,"personalizedReminders","Personalized reminders"),(0,s.Z)(this,"crossSiteTrackingIsEnabled","Cross-site tracking is enabled"),(0,s.Z)(this,"reminderInfoButtonName","Learn more about product reminders"),(0,s.Z)(this,"cbPreviousTransactions","Previous transactions"),(0,s.Z)(this,"cbRebatesOff","off"),(0,s.Z)(this,"cbRebatesOn","on"),(0,s.Z)(this,"myCashback","My cash back"),(0,s.Z)(this,"lifetimeearned","lifetime earned"),(0,s.Z)(this,"cbNonStackableCoupon","This coupon can't be used with Microsoft Cashback"),(0,s.Z)(this,"cbRetailerTitle","Up to $1 cash back"),(0,s.Z)(this,"cbSnapshotTitle","Your Microsoft Cashback snapshot"),(0,s.Z)(this,"cbViewAccount","View account activity"),(0,s.Z)(this,"cbCurrBalance","current balance"),(0,s.Z)(this,"cbErrorMessage","Cash back activation failed"),(0,s.Z)(this,"cbFetchUserProfileErrorMessage","Fetch user profile failed"),(0,s.Z)(this,"cbFailedRetry","Retry"),(0,s.Z)(this,"cbProcessing","Activating your cash back"),(0,s.Z)(this,"cbPrivacyMessage","You will be signed in to Microsoft Edge which will back up your browsing data and let you see your favorites, passwords, history and more on all your devices. You will also join and receive emails about $1, which include offers about partner products. $2 | $3"),(0,s.Z)(this,"cbPrivacyMessageBeforeRewardsLink","You will be signed in to Microsoft Edge which will back up your browsing data and let you see your favorites, passwords, history and more on all your devices. You will also join and receive emails about"),(0,s.Z)(this,"cbPrivacyMessageAfterRewardsLink",", which include offers about partner products."),(0,s.Z)(this,"cbEnrollPrivacyMessage","You will join and receive emails about $1, which include offers about partner products. $2 | $3"),(0,s.Z)(this,"cbPrivacyMessageTerm","Terms"),(0,s.Z)(this,"cbPrivacyMessageAfterTerm","|"),(0,s.Z)(this,"cbPrivacyMessagePrivacyCookies","Privacy & Cookies"),(0,s.Z)(this,"privacyDataCollectionMessage","Microsoft will collect your browsing history and page content to improve the shopping experience provided by Microsoft products. $1"),(0,s.Z)(this,"cbMergedTitleEstimateStr","{NUMBER, plural, =1 {We found 1 coupon and estimated $2 cash back!} other {We found # coupons and estimated $2 cash back!}}"),(0,s.Z)(this,"forYou","FOR YOU"),(0,s.Z)(this,"previousOffers","Active offers"),(0,s.Z)(this,"cbPromotionsOnSubHeader","on first eligible purchase!"),(0,s.Z)(this,"trSectionTitle","Popular cashback partners"),(0,s.Z)(this,"bannerFoundBestPrice","We've found |a better| price!"),(0,s.Z)(this,"bannerFoundBestPriceAlt","We found you a better price!"),(0,s.Z)(this,"bannerYouHaveBestPrice","You have |the best price!|"),(0,s.Z)(this,"bannerSubTitleFlyout","Click below to copy a coupon code, or we can help auto apply at check out!"),(0,s.Z)(this,"bannerSeeDetails","See details"),(0,s.Z)(this,"bannerViewAll","View all"),(0,s.Z)(this,"bannerVisitItem","Visit item in new tab"),(0,s.Z)(this,"bannerViewAllCouponsStr","{NUMBER, plural, =1 {View coupon} other {View all # coupons}}"),(0,s.Z)(this,"getDeal","Get Deal"),(0,s.Z)(this,"dealsTitle","Trending deals on $1"),(0,s.Z)(this,"dealsSubTitle","Best deals for you on $1"),(0,s.Z)(this,"dontShowFeatureNameForSite","Don't show $1 for this site"),(0,s.Z)(this,"dontShowFeatureName","Don't show $1 again"),(0,s.Z)(this,"phTitlePriceDropped","The price on this product has dropped!"),(0,s.Z)(this,"phTitlePriceIncrease","The price on this product has increased"),(0,s.Z)(this,"phTitleStable","The price on this product is stable"),(0,s.Z)(this,"phToday","today"),(0,s.Z)(this,"phLow","low"),(0,s.Z)(this,"phHigh","high"),(0,s.Z)(this,"phMedian","median"),(0,s.Z)(this,"newPhLow","Low"),(0,s.Z)(this,"newPhHigh","High"),(0,s.Z)(this,"newPhMedian","Median"),(0,s.Z)(this,"phStableLabel","stable"),(0,s.Z)(this,"phStableSummary","stable price"),(0,s.Z)(this,"phPriceDrop","Price drop"),(0,s.Z)(this,"phPriceDropZero","low price"),(0,s.Z)(this,"phPriceDropped","Price dropped"),(0,s.Z)(this,"phSee","See Price History"),(0,s.Z)(this,"phSeeTrend","See the Price Trend?"),(0,s.Z)(this,"phPriceIncrease","Price increase"),(0,s.Z)(this,"phPriceUp","Price up"),(0,s.Z)(this,"phPriceUpZero","high price"),(0,s.Z)(this,"phPriceStable","Price stable"),(0,s.Z)(this,"phOldPrice","Old price"),(0,s.Z)(this,"phNewPrice","New price"),(0,s.Z)(this,"phGraphLabel","The price has not fluctuated much. Today price is $1"),(0,s.Z)(this,"phTooltipText","Price drop/increase is determined by >= 2% change from the historical median price ($1) seen by users for this product."),(0,s.Z)(this,"phTooltipTextAvg","Price drop/increase is determined by >= 2% change from the historical average price ($1) seen by users for this product."),(0,s.Z)(this,"phFeatureName","price drop"),(0,s.Z)(this,"cashbackPlusCouponsFeatureName","Cash back + coupons Notification"),(0,s.Z)(this,"cashbackPlusPriceDropFeatureName","Cash back + price drop Notification"),(0,s.Z)(this,"pcPlusCashbackPlusCouponsFeatureName","Lower price + cash back + coupons Notification"),(0,s.Z)(this,"phSectionTitle","Price history"),(0,s.Z)(this,"pcSectionTitle","Price comparison"),(0,s.Z)(this,"pcBetterPriceFound","Better price found"),(0,s.Z)(this,"pcSeeAllOffers","See all offers"),(0,s.Z)(this,"userInsightsSectionTitle","User insights"),(0,s.Z)(this,"userInsightsPositiveSection","Why they like it?"),(0,s.Z)(this,"userInsightsNegativeSection","Typical Complaints"),(0,s.Z)(this,"expertInsightsSectionTitle","Expert insights"),(0,s.Z)(this,"expertInsightsRecommend","Yes, experts recommend it."),(0,s.Z)(this,"expertInsightsDontRecommend","Experts don't recommend it."),(0,s.Z)(this,"expertInsightsRecommendationScore","recommendation score"),(0,s.Z)(this,"productSummaryCardSectionTitle","Product summary"),(0,s.Z)(this,"phNewPriceStable","Price is stable"),(0,s.Z)(this,"phNewPriceLower","lower than usual"),(0,s.Z)(this,"phNewPriceHigher","higher than usual"),(0,s.Z)(this,"phNewChartLabel","The lowest price in history is $1 on $2. The highest price in history is $3 on $4. The median price in history is $5 on $6."),(0,s.Z)(this,"phNewChartNoMedianLabel","The lowest price in history is $1 on $2. The highest price in history is $3 on $4."),(0,s.Z)(this,"phNewHighestPriceLabel","Highest price point $1 on $2"),(0,s.Z)(this,"phNewLowestPriceLabel","Lowest price point $1 on $2"),(0,s.Z)(this,"phNewMedianPriceLabel","Median price point $1 on $2"),(0,s.Z)(this,"phNewTodayPrice","Today's price is $1"),(0,s.Z)(this,"phNewSelectedPrice","Selected price is $1"),(0,s.Z)(this,"phRecentPriceDrop","Recent price drop"),(0,s.Z)(this,"phRecentPriceIncrease","Recent price increase"),(0,s.Z)(this,"phLowerPriceThanUsual","Lower price than usual"),(0,s.Z)(this,"phHigherPriceThanusual","Higher price than usual"),(0,s.Z)(this,"phLowerThanUsual","Lower than usual"),(0,s.Z)(this,"phHigherThanUsual","Higher than usual"),(0,s.Z)(this,"price_is_stable","Price is stable"),(0,s.Z)(this,"lowestprice_in_x_month","Lowest price in 1 month"),(0,s.Z)(this,"lowestprice_in_x_months","Lowest price in $1 months"),(0,s.Z)(this,"highestprice_in_x_month","Highest price in 1 month"),(0,s.Z)(this,"highestprice_in_x_months","Highest price in $1 months"),(0,s.Z)(this,"secondlowestprice_in_x_month","Second lowest price in 1 month"),(0,s.Z)(this,"secondlowestprice_in_x_months","Second lowest price in $1 months"),(0,s.Z)(this,"x_percent_price_increase_from_usual","$1 price increase from usual"),(0,s.Z)(this,"x_percent_price_drop_from_usual","$1 price drop from usual"),(0,s.Z)(this,"recent_x_percent_price_increase","Recent $1 price increase"),(0,s.Z)(this,"recent_x_percent_price_drop","Recent $1 price drop"),(0,s.Z)(this,"x_users_addedtocart_inlast_y_month","$1 users added to cart in $2 month"),(0,s.Z)(this,"x_users_purchased_inlast_y_month","$1 users purchased in $2 month"),(0,s.Z)(this,"x_users_viewed_inlast_y_month","$1 users viewed in $2 month"),(0,s.Z)(this,"x_users_addedtocart_inlast_y_days","$1 users added to cart in $2 days"),(0,s.Z)(this,"x_users_purchased_inlast_y_days","$1 users purchased in $2 days"),(0,s.Z)(this,"x_users_viewed_inlast_y_days","$1 users viewed in $2 days"),(0,s.Z)(this,"x_users_addedtocart_inlast_y_day","$1 users added to cart in $2 day"),(0,s.Z)(this,"x_users_purchased_inlast_y_day","$1 users purchased in $2 day"),(0,s.Z)(this,"x_users_viewed_inlast_y_day","$1 users viewed in $2 day"),(0,s.Z)(this,"addedtocart_x_days_ago","Added to cart $1 days ago"),(0,s.Z)(this,"purchased_x_days_ago","Purchased $1 days ago"),(0,s.Z)(this,"viewed_x_days_ago","Viewed $1 days ago"),(0,s.Z)(this,"addedtocart_x_day_ago","Added to cart $1 day ago"),(0,s.Z)(this,"purchased_x_day_ago","Purchased $1 day ago"),(0,s.Z)(this,"viewed_x_day_ago","Viewed $1 day ago"),(0,s.Z)(this,"addedtocart_x_hours_ago","Added to cart $1 hours ago"),(0,s.Z)(this,"purchased_x_hours_ago","Purchased $1 hours ago"),(0,s.Z)(this,"viewed_x_hours_ago","Viewed $1 hours ago"),(0,s.Z)(this,"addedtocart_x_hour_ago","Added to cart $1 hour ago"),(0,s.Z)(this,"purchased_x_hour_ago","Purchased $1 hour ago"),(0,s.Z)(this,"viewed_x_hour_ago","Viewed $1 hour ago"),(0,s.Z)(this,"addedtocart_x_minutes_ago","Added to cart $1 minutes ago"),(0,s.Z)(this,"purchased_x_minutes_ago","Purchased $1 minutes ago"),(0,s.Z)(this,"viewed_x_minutes_ago","Viewed $1 minutes ago"),(0,s.Z)(this,"addedtocart_x_minute_ago","Added to cart $1 minute ago"),(0,s.Z)(this,"purchased_x_minute_ago","Purchased $1 minute ago"),(0,s.Z)(this,"viewed_x_minute_ago","Viewed $1 minute ago"),(0,s.Z)(this,"addedtocart_x_seconds_ago","Added to cart $1 seconds ago"),(0,s.Z)(this,"purchased_x_seconds_ago","Purchased $1 seconds ago"),(0,s.Z)(this,"viewed_x_seconds_ago","Viewed $1 seconds ago"),(0,s.Z)(this,"rrExpertAndVideoReviews","Expert reviews and related videos"),(0,s.Z)(this,"rrExpertReviews","Expert reviews"),(0,s.Z)(this,"rrVideoReviews","Related videos"),(0,s.Z)(this,"rrFeatureName","reviews"),(0,s.Z)(this,"checkoutCreditOrDebitCardDropDown","Choose a different Credit or Debit card:"),(0,s.Z)(this,"checkoutShippingAddress","Shipping address:"),(0,s.Z)(this,"checkoutPaymentInfo","Payment info:"),(0,s.Z)(this,"checkoutSameBilling","Billing address is same as shipping address"),(0,s.Z)(this,"checkoutFillOnly","Quick and easy checkout"),(0,s.Z)(this,"checkoutButtonWithoutAA","Fill details"),(0,s.Z)(this,"checkoutButtonWithoutAAForOtherPayment","Fill details and checkout with $1"),(0,s.Z)(this,"checkoutSectionTitle","Autofill checkout details"),(0,s.Z)(this,"checkoutAddressSectionTitle","Autofill address details"),(0,s.Z)(this,"checkoutPaymentSectionTitle","Autofill payment details"),(0,s.Z)(this,"checkoutValidTill","valid till"),(0,s.Z)(this,"checkoutZip","ZIP"),(0,s.Z)(this,"checkoutFeatureName","express checkout"),(0,s.Z)(this,"ytSectionTitleOnRetailer","Coupons from YouTube"),(0,s.Z)(this,"ytSectionTitleOthersOnRetailer","Saved coupons from YouTube"),(0,s.Z)(this,"ytHeaderStr","{NUMBER, plural, =1 {1 exclusive coupon from $1} other {# exclusive coupons from $1}}"),(0,s.Z)(this,"ytPhotoLabel","Profile picture for $1"),(0,s.Z)(this,"ytMoreCoupons","More coupons from Youtube"),(0,s.Z)(this,"ytSectionTitleOnYoutube","Your coupons from Youtube"),(0,s.Z)(this,"ytShopOn","Shop on $1"),(0,s.Z)(this,"ytShopNow","Shop Now!"),(0,s.Z)(this,"ytSaveCouponsPermission","Save coupons"),(0,s.Z)(this,"ytDontSaveCouponsPermission","Never save coupons from Youtube"),(0,s.Z)(this,"ytCouponDescription","Coupon from $1"),(0,s.Z)(this,"ytSaved","Saved!"),(0,s.Z)(this,"ytFeatureName","youtube"),(0,s.Z)(this,"pintFeatureName","pinterest"),(0,s.Z)(this,"prodCollSectionTitle","Product collections"),(0,s.Z)(this,"prodCollWishlistTitle","Saved"),(0,s.Z)(this,"prodCollTrackingTitle","Tracked products"),(0,s.Z)(this,"prodCollProdHistoryTitle","Recently viewed"),(0,s.Z)(this,"prodCollEmptyWishlistMessage","Start saving products to view them here!"),(0,s.Z)(this,"prodCollEmptyTrackingMessage","Track products and see price drops here!"),(0,s.Z)(this,"prodCollEmptyRecentlyViewedMessage","Browse products and easily access them here!"),(0,s.Z)(this,"prodCollDeleteTitle","Untrack product"),(0,s.Z)(this,"prodCollStartTracking","Start tracking"),(0,s.Z)(this,"prodCollViewSteps","View steps"),(0,s.Z)(this,"prodCollStepOne","Go to any product page"),(0,s.Z)(this,"prodCollStepTwo",'Under Coupons & Savings tab, look for "Track Price"'),(0,s.Z)(this,"prodCollStepThree","Switch toggle ON to start tracking"),(0,s.Z)(this,"prodCollPrice","for $1"),(0,s.Z)(this,"prodCollPriceIncrease",", increased from $2 to $3"),(0,s.Z)(this,"prodCollPriceDecrease",", decreased from $2 to $3"),(0,s.Z)(this,"prodCollConsentTitle","Add saved products to your account"),(0,s.Z)(this,"prodCollConsentText","We noticed you tracked some items before logging in. Would you like us to add them to your account?"),(0,s.Z)(this,"prodCollConsentYes","Yes"),(0,s.Z)(this,"prodCollConsentNoThanks","No, thanks"),(0,s.Z)(this,"prodCollConsentSignInText","Get alerts and save your tracked products across devices"),(0,s.Z)(this,"prodCollConsentSignIn","Sign in"),(0,s.Z)(this,"prodCollConsentSignInPrivacyText","By signing in you agree to $1 and $2."),(0,s.Z)(this,"prodCollConsentSignInPrivacyTextSeeMore","Signing in will also sync your setting and back up your browsing data for you to see favorites, passwords and more on all your devices"),(0,s.Z)(this,"prodCollConsentNotNow","Not now"),(0,s.Z)(this,"shoppingTripsTitle","Cashback history"),(0,s.Z)(this,"shopTripAllPurchase","All"),(0,s.Z)(this,"shopTripActivePurchases","Active"),(0,s.Z)(this,"shopTripEmptyMessage","Track your cashback history here!"),(0,s.Z)(this,"shopTripCashBackAmountPending","Amount pending"),(0,s.Z)(this,"shopTripCashBackCompletePurchaseLink","Complete purchase"),(0,s.Z)(this,"shopTripStatusOfferActivated","Offer activated"),(0,s.Z)(this,"shopTripStatusMerchantProcessing","Merchant processing"),(0,s.Z)(this,"shopTripStatusCashbackReceived","Cash back received"),(0,s.Z)(this,"priceDropPlusCouponsCompositeNotificationTitle","Great deal at $1!"),(0,s.Z)(this,"cashbackPlusCouponsCompositeNotificationBtnText","Activate cash back"),(0,s.Z)(this,"couponsComponentCompositeNotificationTitle","Coupons found"),(0,s.Z)(this,"priceHistoryComponentCompositeNotificationTitle","Price drop"),(0,s.Z)(this,"estimatedCashbackComponentCompositeNotificationTitlePart1","Estimated"),(0,s.Z)(this,"cashbackUpToComponentCompositeNotificationTitle","Cash back up to"),(0,s.Z)(this,"cashbackPlusCouponsCompositeNotificationTitle","Cash back and Coupons"),(0,s.Z)(this,"couponsUpToXPercentOff","up to $1% off"),(0,s.Z)(this,"lowerPricePlusCashbackPlusCouponsCompositeNotificationTitle","Potential savings"),(0,s.Z)(this,"lpPlusCbPlusCouponsCompositeNotificationPriceComparisonTitle","Better price at $1 $2"),(0,s.Z)(this,"lpPlusCbPlusCouponsCompositeNotificationCashbackTitle","Up to $1 cash back at $2"),(0,s.Z)(this,"lpPlusCbPlusCouponsCompositeNotificationCouponsTitle","Up to $1% off with coupons"),(0,s.Z)(this,"lpPlusCbPlusCouponsCompositeNotificationCouponsTitleV2","Up to $1 off with coupons"),(0,s.Z)(this,"v2CompositeNotificationCashbackTitle","Up to $1 off with cash back"),(0,s.Z)(this,"v2CompositeNotificationPriceHistoryTitle","Price has dropped $1"),(0,s.Z)(this,"v2CompositeNotificationPhPlusTitle","Best deal at $1"),(0,s.Z)(this,"v2CompositeNotificationCashbackCouponsTitle","Up to $2 savings at $1"),(0,s.Z)(this,"v2CompositeNotificationCommonViewSavingsCTA","View savings"),(0,s.Z)(this,"v2CompositeNotificationHighCouponSuccessRate","Coupon success rate is high"),(0,s.Z)(this,"v2CompositeNotificationPHOldPriceAriaLAbel","Old price $1."),(0,s.Z)(this,"v2CompositeNotificationPHCurrentPriceAriaLAbel","New price $1."),(0,s.Z)(this,"mitButton","See deals"),(0,s.Z)(this,"mitHeaderBlackFriday","T-G-I-Black Friday"),(0,s.Z)(this,"mitSubtitleBlackFriday","Hurry! Check out deals that will light up your Friday."),(0,s.Z)(this,"mitHeaderCyberMonday","It's Cyber Monday"),(0,s.Z)(this,"mitSubtitleCyberMonday","Ready. Set. Click. Shop the best online deals and exclusives."),(0,s.Z)(this,"mitHeaderThanksgiving","Savings, thanks!"),(0,s.Z)(this,"mitSubtitleThanksgiving","Thanksgiving deals for home cooks to coffee lovers."),(0,s.Z)(this,"mitHeaderHolidays","Holiday savings"),(0,s.Z)(this,"mitSubtitleHolidays","Get great deals on gifts for you and your loved ones."),(0,s.Z)(this,"mitHeaderNewYear","Party of savings"),(0,s.Z)(this,"mitSubtitleNewYear","Celebrate the new year with the best deals and offers."),(0,s.Z)(this,"mitHeaderValentines","Valentine's Day"),(0,s.Z)(this,"prodHSectionTitle","Your recently viewed items"),(0,s.Z)(this,"prodHPriceDropRefresh","$1 price drop"),(0,s.Z)(this,"prodHPriceIncreaseRefresh","$1 price increase"),(0,s.Z)(this,"prodHPriceDropTitle","Price drop on recently viewed item"),(0,s.Z)(this,"prodHPriceDropDonotRemindMe","Don't remind me again for this product"),(0,s.Z)(this,"prodHPriceDropViewAt","View at $1"),(0,s.Z)(this,"prodHAnnotation","was $1"),(0,s.Z)(this,"prodHDeleteItem","delete item"),(0,s.Z)(this,"similarSellerNotificationError","Failed to add product!"),(0,s.Z)(this,"similarSellerStringCollapsedAmazon","Other Amazon sellers found!"),(0,s.Z)(this,"similarSellerStringCollapsed","Other sellers found!"),(0,s.Z)(this,"similarSellerAddToCartTitle","Add to cart"),(0,s.Z)(this,"similarSellerNewAddToCartTitle","Add to cart ($1)"),(0,s.Z)(this,"similarSellerAddedToCartTitle","Added to cart"),(0,s.Z)(this,"similarSellerInCartTitle","In cart"),(0,s.Z)(this,"similarSellerShipFromString","Ship from:"),(0,s.Z)(this,"similarSellerRatingLabel","Rating:"),(0,s.Z)(this,"similarSellerFreeDelivery","FREE Delivery"),(0,s.Z)(this,"similarSellerFeatureName","other sellers"),(0,s.Z)(this,"chatChipsInCardTitle","Get the insights you need to help you on your shopping journey."),(0,s.Z)(this,"carouselChatChipsCartTitle","Find the right product for you"),(0,s.Z)(this,"chatChipsSectionTitle","Ask Bing"),(0,s.Z)(this,"chatChipsInCardHeader","Bing"),(0,s.Z)(this,"carouselChipsInCardHeader","Ask Bing"),(0,s.Z)(this,"tipsTiltleSingle","1 tip found!"),(0,s.Z)(this,"tipsSubTitleSingle","1 tip found"),(0,s.Z)(this,"paymentOptionLabel","More payment options at checkout"),(0,s.Z)(this,"microsoftWalletLinkText","Wallet"),(0,s.Z)(this,"virtualCardCardHolderNameHeader","Your name"),(0,s.Z)(this,"virtualCardBillingAddressHeader","Your billing address"),(0,s.Z)(this,"virtualCardBillingInfoHeader","Your name & billing address"),(0,s.Z)(this,"virtualCardNumberHeader","Virtual card number"),(0,s.Z)(this,"virtualCardExpirationHeader","Expiration"),(0,s.Z)(this,"virtualCardCVCHeader","CVC"),(0,s.Z)(this,"visualizedCardHolderHeader","Card holder"),(0,s.Z)(this,"visualizedCardExpiresHeader","Expires"),(0,s.Z)(this,"showContentToggleTooltipCardNumber","Show content for virtual card number"),(0,s.Z)(this,"showContentToggleTooltipCVC","Show content for CVC"),(0,s.Z)(this,"hideContentToggleTooltipCardNumber","Hide content for virtual card number"),(0,s.Z)(this,"hideContentToggleTooltipCVC","Hide content for CVC"),(0,s.Z)(this,"copyButtonTooltip","Copy"),(0,s.Z)(this,"virtualCardSystemFailureHeader","Uh oh"),(0,s.Z)(this,"buyNowPayLater","Buy now, pay later"),(0,s.Z)(this,"masterCardPayment","Master"),(0,s.Z)(this,"visaPayment","Visa"),(0,s.Z)(this,"amexPayment","American Express"),(0,s.Z)(this,"discoverPayment","Discover"),(0,s.Z)(this,"disablePackageTrackingFromMenuText","Disable order tracking"),(0,s.Z)(this,"enablePackageTrackingFromMenuText","Enable order tracking"),(0,s.Z)(this,"packageTrackingOptInButtonText","Track my orders"),(0,s.Z)(this,"packageTrackingNewOptInButtonText","Enable order tracking"),(0,s.Z)(this,"packageTrackingOptOutButtonText","Do not track my orders"),(0,s.Z)(this,"packageTrackingDeactivatedTitle","Order tracking is off"),(0,s.Z)(this,"packageTrackingActivatedTitle","Order tracking is on"),(0,s.Z)(this,"packageTrackingOptInAcknowledgement","Order tracking is activated!"),(0,s.Z)(this,"packageTrackingOptInAcknowledgementFailure","Order tracking failed to activate"),(0,s.Z)(this,"packageTrackingOptOutAcknowledgement","Successfully opted out of order tracking"),(0,s.Z)(this,"packageTrackingOptOutAcknowledgementFailure","Failed to opt out of order tracking"),(0,s.Z)(this,"packageTrackingNotificationTitle","Track your orders now!"),(0,s.Z)(this,"packageTrackingNewNotificationTitle","Microsoft Edge can track your orders now!"),(0,s.Z)(this,"packageTrackingNotificationDescription","We will keep you updated on your order statuses."),(0,s.Z)(this,"packageTrackingFeatureName","package tracking"),(0,s.Z)(this,"packageTrackingOrderPlaced","Order Placed"),(0,s.Z)(this,"packageTrackingDisabledHeading","Microsoft Edge can track your orders"),(0,s.Z)(this,"postPurchaseTrackingFeatureName","price matching"),(0,s.Z)(this,"searchBoxPCBFeatureName","SearchBox PCB"),(0,s.Z)(this,"postPurchaseTrackingNotificationSubtitle","Edge tracks price drops on recent orders so you can request a refund."),(0,s.Z)(this,"postPurchaseTrackingNotificationCTA","Sounds good!"),(0,s.Z)(this,"postPurchaseTrackingDisabledHeading","Track your packages and get price match alerts"),(0,s.Z)(this,"postPurchaseTrackingOptInButtonText","Start tracking orders"),(0,s.Z)(this,"postPurchaseTrackingEnabledHeading","Order tracking enabled"),(0,s.Z)(this,"postPurchaseTrackingEnabledSubtitle","You'll see order statuses here when available"),(0,s.Z)(this,"priceMatchSettingsText","Get alerts when you're eligible for price matching."),(0,s.Z)(this,"priceMatchViewText","View price match"),(0,s.Z)(this,"priceMatchNotificationTitle","Get $1 back on your recent purchase"),(0,s.Z)(this,"postPurchaseTrackingNotificationTitle","Get alerts when you're eligible for price matching"),(0,s.Z)(this,"postPurchaseTrackingPriceMatchCTA","Request price match"),(0,s.Z)(this,"priceMatchPriceDropText","$1 dropped the price of an item you ordered by $2"),(0,s.Z)(this,"priceMatchRemainingDaysText","$1 remaining to claim"),(0,s.Z)(this,"couponsDoNotWork","Coupons do not work"),(0,s.Z)(this,"indexDoesNotWork","Index does not work"),(0,s.Z)(this,"popsUpTooFrequently","Pops up too frequently"),(0,s.Z)(this,"incorrectProductInformation","Incorrect information"),(0,s.Z)(this,"untrustworthyWebsite","Untrustworthy website"),(0,s.Z)(this,"other","Other"),(0,s.Z)(this,"checkBackForOrders","Check back for orders!"),(0,s.Z)(this,"deteTrackerText","Delete order tracker"),(0,s.Z)(this,"rewardsTermsText","Terms"),(0,s.Z)(this,"TrackMe","Track Price"),(0,s.Z)(this,"TrackingNow","Untrack Price"),(0,s.Z)(this,"giftFeatureName","gift card offer"),(0,s.Z)(this,"privacySettingsManage","Manage"),(0,s.Z)(this,"safariPrivacySettingsManage","Manage extension"),(0,s.Z)(this,"safariPrivacy","Privacy"),(0,s.Z)(this,"cashbackSettingsText","Activate cash back without leaving your favorite retailers."),(0,s.Z)(this,"personalizedRemindersSettingsText","Get notified when a product you've visited drops in price."),(0,s.Z)(this,"packageTrackingSettingsText","Keep track of your packages and their delivery status."),(0,s.Z)(this,"edgeShoppingSettings","Turn off Edge Shopping"),(0,s.Z)(this,"submitCouponData","Submit a coupon code"),(0,s.Z)(this,"submitCouponButtonLabel","Submit"),(0,s.Z)(this,"productDetailsOrderTracking","$1 Order containing Products $2!"),(0,s.Z)(this,"couponCode","Coupon code"),(0,s.Z)(this,"couponDescription","Coupon description"),(0,s.Z)(this,"feedbackPrompt","Do you find this content useful?"),(0,s.Z)(this,"feedbackThanks","Thanks for your feedback!"),(0,s.Z)(this,"feedbackAriaLike","Thumbs up"),(0,s.Z)(this,"feedbackAriaDislike","Thumbs down"),(0,s.Z)(this,"feedbackAriaDislikeMenu","Reason for thumbs down"),(0,s.Z)(this,"feedbackAriaClose","Close feedback"),(0,s.Z)(this,"bingPrivacyMessage","Publisher: bing.com"),(0,s.Z)(this,"infoIconLabel","More info"),(0,s.Z)(this,"bnplFeedbackPrompt","Did this feature help with your shopping experience?"),(0,s.Z)(this,"attCouponHeaderLocked","Unlock a better deal!"),(0,s.Z)(this,"attCouponHeaderUnlocked","Unlocked better deal!"),(0,s.Z)(this,"autosMarketplaceName","Microsoft Start Autos"),(0,s.Z)(this,"autosMarketplaceSectionTitle","Recommended listings for you"),(0,s.Z)(this,"autosMarketplaceNotifivationLowPriceHeader","Similar car with lower price"),(0,s.Z)(this,"autosMarketplaceNotificationSave","Save"),(0,s.Z)(this,"autosMarketplaceNotificationHeaderPt2","on a similar car"),(0,s.Z)(this,"autosMarketplaceNotificationHeader","A car you might like!"),(0,s.Z)(this,"autosMarketplaceNotificationNoAccident","No accidents"),(0,s.Z)(this,"autosMarketplaceOnlineDealer","Online dealer"),(0,s.Z)(this,"autosMarketplaceSeeMoreButton","See all listings"),(0,s.Z)(this,"autosMarketplaceSeeMoreButtonV2","OK"),(0,s.Z)(this,"autosMarketplaceSeeNowButton","See now"),(0,s.Z)(this,"autosMarketplaceTrendingVideos","Trending Videos"),(0,s.Z)(this,"autosMarketplaceTrendingVideosV2","Trending videos of latest cars"),(0,s.Z)(this,"autosMarketplaceTrendingVideosV3","Trending review of $1"),(0,s.Z)(this,"autosMarketplaceReviewsCTAButton","View trending videos"),(0,s.Z)(this,"autosMarketplaceTrendingReviews","Trending Reviews"),(0,s.Z)(this,"autosMarketplaceSeeDetails","See Details"),(0,s.Z)(this,"autosMarketplaceSimilarCarFound","Similar car found"),(0,s.Z)(this,"autosMarketplaceSimilarCarsFound","Similar cars found"),(0,s.Z)(this,"autosMarketplaceNoAccident","No accidents cars only"),(0,s.Z)(this,"autosMarketplacePopular","Popular"),(0,s.Z)(this,"autosMarketplaceGreatDeal","Great deal"),(0,s.Z)(this,"autosDealsIncentivesTitleText","Deals and incentives"),(0,s.Z)(this,"autosFeatureName","autos"),(0,s.Z)(this,"autosLatestNews","Latest news"),(0,s.Z)(this,"autosMyGarageHeaderTitle","My garage"),(0,s.Z)(this,"autosMyGarageTitleText","Check the market value of $1 $2"),(0,s.Z)(this,"autosMyGarageTitleTextV2","Market value for $1 $2"),(0,s.Z)(this,"autosMyGaragePriceDropText","price drop since $1 $2"),(0,s.Z)(this,"autosMyGaragePriceIncreaseText","price increase since $1 $2"),(0,s.Z)(this,"autosMyGarageDisclaimer","Estimated retail price based on average $1K miles; actual prices may vary due to condition, miles and location."),(0,s.Z)(this,"autosMyGarageActionButtonText","Check now"),(0,s.Z)(this,"autosMyGarageActionButtonTextV2","View more details"),(0,s.Z)(this,"scSectionTitle","Similar products"),(0,s.Z)(this,"scContainerTitle","Similar products list"),(0,s.Z)(this,"scFilter","Filter offers"),(0,s.Z)(this,"scAddOffer","Add offer"),(0,s.Z)(this,"scRemoveOffer","Remove offer"),(0,s.Z)(this,"scShowFullSpec","Show full specifications"),(0,s.Z)(this,"scChevronLeftTitle","Show previous offer"),(0,s.Z)(this,"scChevronRightTitle","Show next offer"),(0,s.Z)(this,"scSmartCompareNotificationText","Find the right product for you"),(0,s.Z)(this,"scProductSummaryNotificationText","Learn more about this product"),(0,s.Z)(this,"scFindMoreLikeThis","Find more like this"),(0,s.Z)(this,"scCompareSimilarEn","Compare similar $1"),(0,s.Z)(this,"scFindBestProductEn","Find the best $1 for you"),(0,s.Z)(this,"scGetMoreDetailsAboutProductEn","Get more details about $1"),(0,s.Z)(this,"scCompareSimilarNonEn","Compare similar products"),(0,s.Z)(this,"scFindBestProductNonEn","Find the best product for you"),(0,s.Z)(this,"scGetMoreDetailsAboutProductNonEn","Get more details about this product"),(0,s.Z)(this,"scFreeShipping","Free shipping"),(0,s.Z)(this,"psPopularOpinions","Popular opinions"),(0,s.Z)(this,"psTopInsights","Top insights"),(0,s.Z)(this,"psSectionTitle","Product summary"),(0,s.Z)(this,"psReviewSummary","Review insights"),(0,s.Z)(this,"psPros","Pros"),(0,s.Z)(this,"psCons","Cons"),(0,s.Z)(this,"psAiSummaryIndicator","Summarized by AI"),(0,s.Z)(this,"bgSectionTitle","Buying guides"),(0,s.Z)(this,"bgCardTitle","Buying guide"),(0,s.Z)(this,"bgShowMore","Show more"),(0,s.Z)(this,"bgShowLess","Show less"),(0,s.Z)(this,"bgChevronTitle","Expand"),(0,s.Z)(this,"discoverFeatureName","discover"),(0,s.Z)(this,"chatChipComparePrices","Compare prices"),(0,s.Z)(this,"chatChipViewPriceHistory","View price history"),(0,s.Z)(this,"chatChipFindSimilarProduct","Find similar products"),(0,s.Z)(this,"chatChipCompareSimilarProduct","Compare similar products"),(0,s.Z)(this,"chatChipComparePrevious","Compare previously viewed product"),(0,s.Z)(this,"chatChipViewBuyingGuide","View buying guides"),(0,s.Z)(this,"chatChipGetInsights","Get insights on this product"),(0,s.Z)(this,"chatChipGetReviewsSummary","Get reviews summary"),(0,s.Z)(this,"chatChipProductCollection","View previously visited products"),(0,s.Z)(this,"chatNotificationButton","Open Bing Chat"),(0,s.Z)(this,"chatFeatureName","Bing Chat"),(0,s.Z)(this,"gcSectionTitle","Grocery coupons"),(0,s.Z)(this,"gcbSectionTitle","Microsoft Cashback deals"),(0,s.Z)(this,"gcbSeeMore","See more"),(0,s.Z)(this,"gcbSearchSectionTitle",'Deals related to "$1"'),(0,s.Z)(this,"gcbSearchSectionOffTitle","Deals related to"),(0,s.Z)(this,"gcbActivatedSectionTitle","Cash back activated"),(0,s.Z)(this,"gcbSignInText","Sign in to see your cashback deals"),(0,s.Z)(this,"gcbPdpHeaderText","Earn cash back"),(0,s.Z)(this,"gcbNotifPdpActivation","Click below to apply cash back savings"),(0,s.Z)(this,"gcbNotifSubtitle","You'll get cash back for any eligible purchases within 24 hours of your purchase."),(0,s.Z)(this,"groceriesFeatureName","cash back"),(0,s.Z)(this,"gcSpbSearchBarOffersNotFound","No offers found"),(0,s.Z)(this,"gcSearchBarPlaceholder","Search offers on $1"),(0,s.Z)(this,"gcQuotientPrivacyPolicyLinkKey","privacy policy"),(0,s.Z)(this,"gcPrivacyTooltipButtonName","Privacy disclaimer"),(0,s.Z)(this,"gcPrivacyDisclaimerText","Privacy disclaimer text"),(0,s.Z)(this,"gcPrivacyTooltip","Your purchase data will be shared with our partner and used in compliance with their $1. To earn cash back you will need to sign in to Microsoft Edge, join and receive emails about $2."),(0,s.Z)(this,"gcAfterCashback","after <value> cash back"),(0,s.Z)(this,"gcEarnAfterCashback","Earn <value> cash back after purchase"),(0,s.Z)(this,"gcWithAfterCashback","With <value> cash back after purchase"),(0,s.Z)(this,"gcTopDeal","Top deal"),(0,s.Z)(this,"gcSimilarDeal","Similar deal"),(0,s.Z)(this,"gcRelatedDeal","Deal on related product"),(0,s.Z)(this,"gcOff","off"),(0,s.Z)(this,"gcGetDeal","Get"),(0,s.Z)(this,"gcListPrice","List Price"),(0,s.Z)(this,"gcSalePrice","Sale Price"),(0,s.Z)(this,"gcGet","Get $1"),(0,s.Z)(this,"gcGetCashBack","Get $1 cash back"),(0,s.Z)(this,"gcOkButtonText","OK"),(0,s.Z)(this,"gcGetDealOnRetailer","Get this deal on $1"),(0,s.Z)(this,"gcAfterCashBack","after cash back"),(0,s.Z)(this,"gcFinalPrice","Final Price"),(0,s.Z)(this,"gcEarning","You're earning"),(0,s.Z)(this,"gcRebatesEmailUpdate","You'll receive email updates from Microsoft Cashback"),(0,s.Z)(this,"gcRebatesClaimTime","You have 30 days to claim cash back for your purchase"),(0,s.Z)(this,"gcTrackCashback","Track cash back"),(0,s.Z)(this,"gcCashbackConfirmViaEmail","Cash back for eligible purchases will be confirmed in a few days via email."),(0,s.Z)(this,"gcBlossomCongratsFirstPart","Congrats, you're getting "),(0,s.Z)(this,"gcBlossomCongratsSecondPart","$5 bonus cash back!"),(0,s.Z)(this,"gcBlossomBonusFirstPart","Complete a purchase and get"),(0,s.Z)(this,"gcBlossomBonusSecondPart","an extra "),(0,s.Z)(this,"gcBlossomBonusThirdPart","$5 cash back!"),(0,s.Z)(this,"gcSponsored","Sponsored"),(0,s.Z)(this,"gcAdsSponsored","Ads"),(0,s.Z)(this,"gcAdsSponsoredDisclaimer","Ads disclaimer"),(0,s.Z)(this,"gcAd","Ad"),(0,s.Z)(this,"gcAdsHeader","Save on similar items at "),(0,s.Z)(this,"gcSpbHomePageText1","Get up to $1 cash back on select items"),(0,s.Z)(this,"gcSpbHomePageText2","Get exclusive cash back on $1 products"),(0,s.Z)(this,"gcSpbHomePageTextDefault","Get cash back on popular products"),(0,s.Z)(this,"gcFoundCashbackDeals","Found $1 cashback deals!"),(0,s.Z)(this,"gcSeeCashbackDeals","See cash back deals"),(0,s.Z)(this,"gcFoundCashbackDealsRelatedToSearch","Found $1 cashback deals related to your search"),(0,s.Z)(this,"gcSeeOtherDeals","See other deals"),(0,s.Z)(this,"gcJoinAndActivate","Join and Activate"),(0,s.Z)(this,"gcFindOutLinkText","Find out"),(0,s.Z)(this,"gcSponsoredTooltip2","These results match your search query. Sellers participating in our shopping program provide pricing and product information to Bing. Compensation from these sellers is one of several factors that influences ranking of these results. $1 more about our approach to personalized ads and how to opt-out."),(0,s.Z)(this,"gcSponsoredTooltip","These results match your search query. Sellers participating in our shopping program provide pricing and product information to Bing. Compensation from these sellers is one of several factors that influences ranking of these results. <link_find_out>Find out<link_find_out> more about our approach to personalized ads and how to opt-out."),(0,s.Z)(this,"gcSponsoredTooltipNoLink","These results match your search query. Sellers participating in our shopping program provide pricing and product information to Bing. Compensation from these sellers is one of several factors that influences ranking of these results. Find out more about our approach to personalized ads and how to opt-out."),(0,s.Z)(this,"gcViewActivatedDeal","View Deal"),(0,s.Z)(this,"gcCashbackApplied","Cash back applied"),(0,s.Z)(this,"gcPurchaseToEarn","Purchase to earn cash back"),(0,s.Z)(this,"gcInstantAddedToCartActivated","Added to cart with cashback"),(0,s.Z)(this,"gcActivateInstantAddToCart","Click to activate cashback and add to cart"),(0,s.Z)(this,"gcPrintCoupons","Print coupons"),(0,s.Z)(this,"gcPrintOneCoupon","Print 1 coupon"),(0,s.Z)(this,"gcPrintNumberCoupon","Print $1 coupons"),(0,s.Z)(this,"gcDeactivatedButton","Select items to activate"),(0,s.Z)(this,"gcBack","back"),(0,s.Z)(this,"gcAfter","After"),(0,s.Z)(this,"gcSave","Save"),(0,s.Z)(this,"gcMicrosoftCashbackOffers","Microsoft Cashback Offers"),(0,s.Z)(this,"gcViewOffer","View offer"),(0,s.Z)(this,"gcPurchaseBeforeTimer","Purchase before the timer runs out to earn your cash back."),(0,s.Z)(this,"gcEndsIn","Ends in"),(0,s.Z)(this,"gcTotalCashback","Earn up to $1 on *br* everyday items"),(0,s.Z)(this,"gcCategoryTotalCashback","Earn up to $1 on *br* $2"),(0,s.Z)(this,"gcCashbackOnTheseItem","Get {0} cash back on this item"),(0,s.Z)(this,"upToStorewideCashback","Up to {0} cash back storewide"),(0,s.Z)(this,"gcbSeeActivatedButton","See Activated Deals"),(0,s.Z)(this,"gcbSignInButton","Sign in"),(0,s.Z)(this,"gcError","Sorry, something went wrong."),(0,s.Z)(this,"gcDuplicateSubmissionError","Sorry, you've redeemed this offer already."),(0,s.Z)(this,"couponSectionPanePluralTitle","Coupons found"),(0,s.Z)(this,"cashbackExclusionsTitle","Exclusions"),(0,s.Z)(this,"cashbackExclusionsText","Exclusions: Gift cards; Purchases made with coupon codes; Apple products; Beats products; Tires; Video game hardware; VG hardware and accessories; Precious metals; Gifts; Prepaid cards; Photo sevices; Personal care; Over the counter pharmacy; Household paper and chemicals; Food; Walmart Plus Trial; Walmart Plus Confirmed; Categories not listed in the rebate section."),(0,s.Z)(this,"safariFREPrivacyStatement",'By clicking "Agree," you agree to turn on cross-site tracking for Microsoft Shopping. Click "Disagree," or adjust your Shopping settings, to turn off cross-site tracking.'),(0,s.Z)(this,"safariFRESide1Title","Save with Microsoft Shopping"),(0,s.Z)(this,"safariFRESide1Description","Browser features help save money when you shop."),(0,s.Z)(this,"safariFRESide2Title","Get the best deals"),(0,s.Z)(this,"safariFRESide2Description","Get coupons and discounts on anything, from chocolate to flowers and more."),(0,s.Z)(this,"safariFRESide3Title","Shop thousands of stores"),(0,s.Z)(this,"safariFRESide3Description","Browse thousands of stores with coupons. Apply all available coupons to get the best deal."),(0,s.Z)(this,"safariFREResultsTitle","Visit a shopping site to find savings with Microsoft Shopping"),(0,s.Z)(this,"safariFREAllset","You're all set!"),(0,s.Z)(this,"recommendationsFriendlyDomainTitle","Trending on $1"),(0,s.Z)(this,"recommendationsFriendlyDomainTitlePriceDrops","Price drops on $1"),(0,s.Z)(this,"recommendationsTitle","Trending products!"),(0,s.Z)(this,"recommendationsDiscountPercent","$1 OFF"),(0,s.Z)(this,"recommendationsPriceDrop","$1 Price Drop"),(0,s.Z)(this,"recommendationsFeatureName","recommendations"),(0,s.Z)(this,"recommendationsSSATitle","Popular products"),(0,s.Z)(this,"abandonedCartTitle","Products in your carts"),(0,s.Z)(this,"abandonedCartPrompt","Save up to $1 with coupons or $2 with cashback"),(0,s.Z)(this,"abandonedCartCouponPrompt","Save up to $1 with coupons"),(0,s.Z)(this,"abandonedCartCashbackPrompt","Save up to $1 with cash back"),(0,s.Z)(this,"abandonedCartNotif","$1 on your cart at $2 with $3 $4"),(0,s.Z)(this,"abandonedCartNotifOnDomain","$1 on your cart with $2 $3"),(0,s.Z)(this,"pcbAbandonedCart","Up to $1 cash back on product at $2 $3 $4"),(0,s.Z)(this,"abandonedCartButton","Go to cart"),(0,s.Z)(this,"viewProductButton","View Product"),(0,s.Z)(this,"abandonedCartCategoryDealsText","$1 is currently on sale at $2"),(0,s.Z)(this,"abandonedCartFeatureName","abandoned cart"),(0,s.Z)(this,"abandonedCartMoreItemsLabel","more items"),(0,s.Z)(this,"abandonedCartTrackAll","Track all products for price drops"),(0,s.Z)(this,"copyCouponAndViewProduct","Copy Coupon & View Product"),(0,s.Z)(this,"abandonedCartOOFNotificationTitleForExclusiveCoupon","$1 on your cart at $2 $3 $4"),(0,s.Z)(this,"abandonedCartOOFNotificationCouponCodeForExclusiveCoupon","With your exclusive coupon $1"),(0,s.Z)(this,"abandonedCartButtonForExclusiveCoupon","Apply coupon at cart"),(0,s.Z)(this,"abandonedCartCopyButtonForExclusiveCoupon","Copy coupon code"),(0,s.Z)(this,"abandonedCartCopiedButtonForExclusiveCoupon","Copied coupon code!"),(0,s.Z)(this,"winCartTitle","Your carts"),(0,s.Z)(this,"winCartZeroState","Keep track of your shopping carts"),(0,s.Z)(this,"cbMainTitleOff","Get up to $1 cash back"),(0,s.Z)(this,"StorewideCashbackTitleBefore","Get up to"),(0,s.Z)(this,"StorewideCashbackTitleAfter","cash back"),(0,s.Z)(this,"StorewideCashbackTitleOff","on"),(0,s.Z)(this,"cbMainTitleOffBegin","Up to"),(0,s.Z)(this,"cbMainTitleOffEnd","cash back after the purchase"),(0,s.Z)(this,"spbSearchTitleBefore","Up to"),(0,s.Z)(this,"spbSearchTitleAfter","cash back"),(0,s.Z)(this,"cbMainTitleDelayedEnrollment","Don’t miss out on up to $1 cash back"),(0,s.Z)(this,"cbActivateTitleWithOldCashback","Get up to $1 $2 cash back"),(0,s.Z)(this,"cbActivateTitle3xIncentive","Up to $1 $2 cash back"),(0,s.Z)(this,"cbActivateLimitedTimeOffer","Offer expires today!"),(0,s.Z)(this,"cbEnrollBonusTitle","Get $1 welcome bonus"),(0,s.Z)(this,"cbMainTitleOffWithCashbackEstimate","Estimated cash back$1*br*$2"),(0,s.Z)(this,"cbMainTitleOffWithPdpCashbackEstimate","Estimated cash back$1*br*on this item*br*$2"),(0,s.Z)(this,"pcbMainTitleOff","Get $1 cash back with Microsoft Cashback!"),(0,s.Z)(this,"cbSectionTitle","Microsoft Cashback deals"),(0,s.Z)(this,"cbMainTitleOn","You're earning up to $1 cash back!"),(0,s.Z)(this,"cbMainTitleOnStoreWide","You're earning up to $1 cash back storewide!"),(0,s.Z)(this,"pcbMainTitleOnStoreWide","You're earning up to $1 cash back off $2 storewide!"),(0,s.Z)(this,"cbSubtitle","You recently earned $1 cashback from $2"),(0,s.Z)(this,"pdpSubtitle","On average, shoppers earn $1 from coupons on $2"),(0,s.Z)(this,"cbMainTitleOffStoreWide","Get up to $1 cash back storewide!"),(0,s.Z)(this,"pcbMainTitleOffStoreWide","Get up to $1 cash back off $2 storewide!"),(0,s.Z)(this,"pcbAriaLabel","Cashback for this $1, $2, ends in $3"),(0,s.Z)(this,"pcbExpirationText","This $1 Offer ends in $2"),(0,s.Z)(this,"cbPersonalized","You're earning $1 cash back with Microsoft Cashback!"),(0,s.Z)(this,"instantcbRefresh","You may have earned cash back for this purchase"),(0,s.Z)(this,"trackCashback","Track cash back"),(0,s.Z)(this,"instantcbSecond","Track it on your $1 dashboard"),(0,s.Z)(this,"walmartMessage","Please use Add to Cart and follow the full check out process"),(0,s.Z)(this,"cbTitleSignInOn","You're earning up to $1 cash back with Microsoft Cashback!"),(0,s.Z)(this,"cbPromotionsSubTitle","And up to $1 cash back"),(0,s.Z)(this,"cbPromotionsSubTitleStoreWide","And up to $1 cash back storewide"),(0,s.Z)(this,"cbCashBackOnOff","Cashback is $1"),(0,s.Z)(this,"cbLifetimeEarned","Lifetime earned $1"),(0,s.Z)(this,"cbToolTips","Edge Shopping is powered by Microsoft Cashback, part of Microsoft Rewards."),(0,s.Z)(this,"cbFeatureName","cash back"),(0,s.Z)(this,"cbEnrollBonusButtonText","Join now and claim welcome bonus"),(0,s.Z)(this,"bannerPriceDropTitle","There was a |$1 price drop| for this product"),(0,s.Z)(this,"bannerPriceIncreaseTitle","There was a |$1 price increase| for this product"),(0,s.Z)(this,"bannerPriceStableTitle","There have been |no drastic price changes| for this product"),(0,s.Z)(this,"bannerCouponTitle","{0, plural, =1 {Shoppers save money |$1%| of the time with this coupon} other {Shoppers save money |$1%| of the time with these coupons}}"),(0,s.Z)(this,"bannerCashBackOffTitle","You could be earning |$1 cash back!|"),(0,s.Z)(this,"bannerCashBackOnTitle","|Cashback is on!| You're earning up to $1 cash back!"),(0,s.Z)(this,"bannerRecentPurchase","You earned $1 from a recent purchase!"),(0,s.Z)(this,"bannerCouponHeadingLabel","{NUMBER, plural, =1 {We've found |1 coupon| for this site!} other {We've found |#| for this site!}}"),(0,s.Z)(this,"bannerLifetime","Lifetime earned: $1"),(0,s.Z)(this,"microsoftWalletManage","Manage payment info in $1"),(0,s.Z)(this,"phPriceStableRefresh","Price is*br*$1"),(0,s.Z)(this,"ptCouponsTitleStr"," {NUMBER, plural, =1 {1 coupon found*br*on $1} other {# coupons found*br*on $1}}"),(0,s.Z)(this,"snoozeHoverText","Snooze all for 8 hours"),(0,s.Z)(this,"snoozeCurrentNotificationFor8HoverText","Snooze for 8 hours"),(0,s.Z)(this,"snoozeCurrentNotificationFor24HoverText","Snooze for 24 hours"),(0,s.Z)(this,"rebatesHistoryLinkText","Check your cash back earnings"),(0,s.Z)(this,"privacyConsent","I consent to the placement of cookies on my browser to facilitate billing with the coupon provider as per $1"),(0,s.Z)(this,"privacyConsentNew","I allow placing of $1 on my device to help billing with the coupon provider as per $2"),(0,s.Z)(this,"privacyConsentProvider","I allow placing of $1 on my device to facilitate billing with the affiliate offer provider as per $2"),(0,s.Z)(this,"rewardGiftCardConsent","You will receive emails about Microsoft Rewards, which include offers about Microsoft and partner products. $1 | $2"),(0,s.Z)(this,"rewardsjoinAckText","Keep shopping on Microsoft Edge for more savings and deals $1");(0,s.Z)(this,"rewardsFeatureName","rewards"),(0,s.Z)(this,"sectionSeeMore","See more ($1)"),(0,s.Z)(this,"sectionSeeMoreCoupons","See more coupons ($1)"),(0,s.Z)(this,"sectionSeeOlderCoupons","See older coupons ($1)"),(0,s.Z)(this,"sectionSeeMoreViewLess","View less"),(0,s.Z)(this,"travelCheaperFlightsFeatureName","cheaper flights"),(0,s.Z)(this,"travelCheaperFlightsTitle","Cheaper flights available"),(0,s.Z)(this,"travelCheaperHotelsFeatureName","cheaper hotels"),(0,s.Z)(this,"travel","Travel"),(0,s.Z)(this,"travel1Stop","1-stop"),(0,s.Z)(this,"travelBookNow","Book Now"),(0,s.Z)(this,"travelBookOn","Book on $1"),(0,s.Z)(this,"travelBookThisFlight","Book this flight"),(0,s.Z)(this,"travelCheaperDealsForYou","Cheaper deals for you"),(0,s.Z)(this,"travelFor1Adult","for 1 adult"),(0,s.Z)(this,"travelForNAdults","for $1 adults"),(0,s.Z)(this,"travelNonStop","Non-stop"),(0,s.Z)(this,"travelNStops","$1-stops"),(0,s.Z)(this,"travelOneWay","One way"),(0,s.Z)(this,"travelRoundTrip","Round trip"),(0,s.Z)(this,"travelSave","Save"),(0,s.Z)(this,"travelSaveUpto","Save upto"),(0,s.Z)(this,"travelMoreOptions","More options"),(0,s.Z)(this,"travelAd","Ad"),(0,s.Z)(this,"travel1Adult","1 adult"),(0,s.Z)(this,"travelNAdults","$1 adults"),(0,s.Z)(this,"travelBookWith","Book with $1"),(0,s.Z)(this,"travelFor1Night","for 1 night"),(0,s.Z)(this,"travelForNNights","for $1 nights"),(0,s.Z)(this,"travelGetBetterDealOn","Get a better deal on"),(0,s.Z)(this,"travelGetDealNow","Get deal now"),(0,s.Z)(this,"travelPerRoomPerNight","per room per night"),(0,s.Z)(this,"travel1Room","1 room"),(0,s.Z)(this,"travelNRooms","$1 rooms"),(0,s.Z)(this,"travelWeFoundTheBestFlightForYou","We found the best flight for you!"),(0,s.Z)(this,"travelGetSameFlightAtCheaperPrice","Get same flight at cheaper price!"),(0,s.Z)(this,"travelGetDeal","Get Deal"),(0,s.Z)(this,"couponSectionTitleStr","{NUMBER, plural, =1 {1 coupon} other {# coupons}}"),(0,s.Z)(this,"couponSuccessful","$1% successful"),(0,s.Z)(this,"totalSavings","Total savings"),(0,s.Z)(this,"triviaAverageSavingsHeader","On average users save"),(0,s.Z)(this,"couponExpectationHeader","Coupon success rate"),(0,s.Z)(this,"highCouponExpectationTooltip","High means 75%+ coupon success rate on this site"),(0,s.Z)(this,"mediumCouponExpectationTooltip","Medium means 50-75% coupon success rate on this site"),(0,s.Z)(this,"lowCouponExpectationTooltip","Low means <50% coupon success rate on this site"),(0,s.Z)(this,"couponExpectationHigh","High"),(0,s.Z)(this,"couponExpectationMedium","Medium"),(0,s.Z)(this,"couponExpectationLow","Low"),(0,s.Z)(this,"orderTrackingTitle","My orders"),(0,s.Z)(this,"clippingMainTitle","Save $1 with this coupon"),(0,s.Z)(this,"clippingMainTitleForSafari","Save $1 with coupons"),(0,s.Z)(this,"clippingMainTitleUpTo","Save up to $1 with this coupon"),(0,s.Z)(this,"clippingMainTitleSmallNotification","Save $1 with coupon"),(0,s.Z)(this,"clippingMainTitleSmallNotificationUpTo","Save up to $1 with coupon"),(0,s.Z)(this,"defaultClippingTitle","Save money with this coupon"),(0,s.Z)(this,"autoClipSubTitle","Click below to turn on automatic savings"),(0,s.Z)(this,"autoClipSafariSubTitle","Turn on automatic savings"),(0,s.Z)(this,"autoClipButtonTitle","Ok"),(0,s.Z)(this,"clippedTitle","You will save $1 on this item at checkout"),(0,s.Z)(this,"clippedTitleUpTo","You will save up to $1 on this item at checkout"),(0,s.Z)(this,"conditionsMayApplySubTitle","*Conditions may apply"),(0,s.Z)(this,"clippedSubTitle","Coupon successfully clipped"),(0,s.Z)(this,"clippingFeatureName","clip coupon"),(0,s.Z)(this,"clippingMainTitleEnGb","Save $1 with this voucher"),(0,s.Z)(this,"clippingMainTitleEnGbUpTo","Save up to $1 with this voucher"),(0,s.Z)(this,"defaultClippingTitleEnGb","Save money with this voucher"),(0,s.Z)(this,"clippedSubTitleEnGb","Voucher successfully collected"),(0,s.Z)(this,"clippingMainTitleV2","Apply all $1 coupons automatically"),(0,s.Z)(this,"autoClipButtonTitleV2","Auto-clip coupons from now on"),(0,s.Z)(this,"clippedSubTitleV2","You'll save $1 on this item"),(0,s.Z)(this,"defaultClippedSubTitleV2","You'll save money on this item"),(0,s.Z)(this,"clippingSubTitleSmallNotification","You'll Save $1 on this item"),(0,s.Z)(this,"clippingSubTitleUpTo","You'll save up to $1 on this item"),(0,s.Z)(this,"clippedCompletedTitle","You'll save $1 on this item at checkout"),(0,s.Z)(this,"clippedCompletedTitleUpTo","You'll save up to $1 on this item at checkout"),(0,s.Z)(this,"clippedCompletedSubTitle","Coupon automatically clipped"),(0,s.Z)(this,"clippedCompletedSubTitleEnGb","Voucher automatically collected"),(0,s.Z)(this,"bannerSave","Save $1 at $2"),(0,s.Z)(this,"phFinalDrop","$1% drop"),(0,s.Z)(this,"phFinalIncrease","$1% increase"),(0,s.Z)(this,"pcNotificationTitle","You can save $1"),(0,s.Z)(this,"commonYouCanSave","You can save"),(0,s.Z)(this,"commonSeeAll","See all"),(0,s.Z)(this,"pcNotificationTitleRefresh","You could save *br*$1!"),(0,s.Z)(this,"pcNotificationTitleSmall","Save *br*$1"),(0,s.Z)(this,"pcNotificationNarratorIntro","New toolbar on screen. "),(0,s.Z)(this,"priceCompareCbAriaLabel","$1 ad, Price after $2 cash back is $3"),(0,s.Z)(this,"viewMorePricesButtonText","View more prices"),(0,s.Z)(this,"savingsHeader","You can save*br*$1"),(0,s.Z)(this,"pcLowestPriceAria","$1, current price on $2"),(0,s.Z)(this,"pcCurrentPriceAria","$1, higher price on this page"),(0,s.Z)(this,"pcFeatureName","lower prices"),(0,s.Z)(this,"trAriaLabel","$1 cash back at $2, shop now!"),(0,s.Z)(this,"cbPromotionsTitle","Earn $1 bonus from Microsoft"),(0,s.Z)(this,"cbExpiryDateTime","ends in $1"),(0,s.Z)(this,"cbSpbExpiryDateTime","Offer ends in $1"),(0,s.Z)(this,"cbCommissionStr","$1 cash back"),(0,s.Z)(this,"pcbCommissionStoreWide","$1"),(0,s.Z)(this,"pcbCommissionStoreWideOff","off $1"),(0,s.Z)(this,"pcbCommissionStoreWideOffTextOnly","off"),(0,s.Z)(this,"pcbStorewideCashback","Storewide Cash back"),(0,s.Z)(this,"pcbStorewideCashbackAutoshow","Minimum $1 purchase"),(0,s.Z)(this,"cbPreviousCashbackDomain","$1 earned on $2 from $3"),(0,s.Z)(this,"cbMergedTitleStr","{NUMBER, plural, =1 {We found 1 coupon and up to $2 cash back!} other {We found # coupons and up to $2 cash back!}}"),(0,s.Z)(this,"rewardFailedSignin","Sign in Unsuccessful"),(0,s.Z)(this,"rewardTitleDefault","Get Microsoft Rewards"),(0,s.Z)(this,"rewardTitleEarnedMaximum","You've earned 5000 points!"),(0,s.Z)(this,"rewardTitleRewardsAdded","You've Earned $1 points!"),(0,s.Z)(this,"rewardTitleRewardTwo","Save $$ and earn rewards!"),(0,s.Z)(this,"rewardPointMax","5000"),(0,s.Z)(this,"rewardPerMaxPoint","/5000"),(0,s.Z)(this,"rewardDetail","Activate cash back and get |$1 points!|"),(0,s.Z)(this,"rewardDetailFirstLine","Activate cash back and get "),(0,s.Z)(this,"rewardDetailFirstLineBold","$1 points!"),(0,s.Z)(this,"rewardKeepExploringText","Keep shopping with Edge to earn more points!"),(0,s.Z)(this,"rewardDetailTwo","Click Microsoft Edge's little blue tag to find"),(0,s.Z)(this,"rewardSignIn","Sign in to earn points"),(0,s.Z)(this,"rewardRedeem","Redeem"),(0,s.Z)(this,"rewardCoupons","Coupons"),(0,s.Z)(this,"rewardCashback","Cashback"),(0,s.Z)(this,"rewardRewards","Rewards"),(0,s.Z)(this,"rewardAssociateSignIn","Sign in"),(0,s.Z)(this,"icRewardProgressText","Reward Progress"),(0,s.Z)(this,"icRewardProgressAriaLabel","you completed $1 out of 3 actions to get $2"),(0,s.Z)(this,"icRewardClaimText","Claim $1 reward!"),(0,s.Z)(this,"icRewardClaimPtsAriaLabel","claim 5000 points reward"),(0,s.Z)(this,"icRewardPointsAriaLabel","5000 points"),(0,s.Z)(this,"icRewardDollarsAriaLabel","5 dollars"),(0,s.Z)(this,"cucRewardClaimText","Get $1 bonus"),(0,s.Z)(this,"similarSellerStringAmazon","Save $1 if you buy from a different Amazon seller!"),(0,s.Z)(this,"similarSellerString","Save $1 if you buy from a different seller!"),(0,s.Z)(this,"similarSellerTitleAmazon","Buy from a different Amazon seller and save $1"),(0,s.Z)(this,"similarSellerTitle","Buy from a different seller and save $1"),(0,s.Z)(this,"similarSellerStringSubtitleAmazon","Other Amazon sellers found"),(0,s.Z)(this,"similarSellerStringSubtitleAmazonNew","Other Amazon sellers"),(0,s.Z)(this,"similarSellerStringSubtitle","Other sellers found"),(0,s.Z)(this,"similarSellerNotificationTitle","You saved $1"),(0,s.Z)(this,"sustainabilityDescriptionLight","When you make purchases on Microsoft Edge, Microsoft donates money to reforestation |at no cost to you.|"),(0,s.Z)(this,"sustainabilityDescription","Microsoft makes donation to plant trees for purchases made on Edge. You're making a difference by shopping with us!"),(0,s.Z)(this,"sustainabilityString","Microsoft plants trees when you shop!"),(0,s.Z)(this,"sustainabilityConfirmationTitle","You're making a difference by shopping in Edge!"),(0,s.Z)(this,"sustainabilityFeatureName","tree plantation"),(0,s.Z)(this,"similarSellerAddToCartAriaLable","Add to cart from other seller, Product price: $1, Product condition: $2"),(0,s.Z)(this,"tipsMinimumPurchase","Make a minimum purchase of $1"),(0,s.Z)(this,"virtualCardSystemFailureDescription","We are unable to retrieve your virtual card details. Please visit $1 for your virtual card details."),(0,s.Z)(this,"virtualCardSystemFailureLink","Visit $1"),(0,s.Z)(this,"virtualCardLinkSuccess","We successfully linked your Microsoft account to $1."),(0,s.Z)(this,"virtualCardLinkFail","We are unable to link your Microsoft account to $1. Please try again later."),(0,s.Z)(this,"virtualCardFeatureName","virtual card"),(0,s.Z)(this,"cardPaymentOptionBanner","Credit or Debit card"),(0,s.Z)(this,"otherPaymentMethodBanner","Other ways to pay"),(0,s.Z)(this,"howItWorkLinkAriaLabel","$1 for $2"),(0,s.Z)(this,"dismissMessageAriaLabel","Dismiss this message"),(0,s.Z)(this,"virtualCardDetailsActions","Actions"),(0,s.Z)(this,"msZipDescription","Microsoft does not charge you or get paid by this provider for the transaction."),(0,s.Z)(this,"joinNowButtonText","Join now"),(0,s.Z)(this,"maybeLaterButtontext","Maybe later"),(0,s.Z)(this,"rewardJoinSuccess","You joined"),(0,s.Z)(this,"rewardOfferSuccess","See progress on"),(0,s.Z)(this,"attFlyoutLocked","Boost your cart to $1 to unlock $2"),(0,s.Z)(this,"attFlyoutUnlocked","Congrats! You unlocked the $1 coupon"),(0,s.Z)(this,"attTooltipHeader","We found a coupon for $1 that requires $2 of items in your cart"),(0,s.Z)(this,"attTooltipText","Once your cart exceeds $1 we'll show you that coupon and apply it at checkout to save you even more money. *Restrictions may apply.*"),(0,s.Z)(this,"gcbCashBack","$1 cash back"),(0,s.Z)(this,"gcbWhenYouSpend","cash back when you spend"),(0,s.Z)(this,"gcbWhenShoppingAt","When shopping at"),(0,s.Z)(this,"gcbAt","at"),(0,s.Z)(this,"gcbViewAllActivatedOffers","View all active offers"),(0,s.Z)(this,"gcbViewMoreOffers","View more offers"),(0,s.Z)(this,"gcbSigninToClaim","Sign in to claim"),(0,s.Z)(this,"gcbThisOfferEndsIn","This offer ends in"),(0,s.Z)(this,"gcbNotifTitle","Microsoft will add $1 to your $2"),(0,s.Z)(this,"gcbOnMerchantName","on $1"),(0,s.Z)(this,"gcbOnLogoMerchantName","on $1 $2"),(0,s.Z)(this,"pcNotificationdisclaimerText","Compensation was not a factor in the selection of this offer. To view all offers, 'See more info'."),(0,s.Z)(this,"pcdisclaimerText","Compensation and relevance influence offer ranking."),(0,s.Z)(this,"paneForYou","Coupons & Savings"),(0,s.Z)(this,"paneHome","Your Shopping"),(0,s.Z)(this,"settingsPaneHdNotificationsTitle","Notification settings"),(0,s.Z)(this,"settingsPaneHdNotificationsText","Edge Shopping can help you save time and money while you shop online. The more features you have on, the harder we look for deals for you."),(0,s.Z)(this,"settingsPaneHdAllNotifications","All Shopping Notifications"),(0,s.Z)(this,"settingsPaneHdSavings","Savings"),(0,s.Z)(this,"settingsPaneHdProductInsights","Product Insights"),(0,s.Z)(this,"settingsPaneHdReminders","Reminders"),(0,s.Z)(this,"settingsPaneHdRecommendations","Recommendations"),(0,s.Z)(this,"settingsPaneAllNotificationsText","Turn on shopping notifications"),(0,s.Z)(this,"settingsPaneCouponsText","Use coupons and promo codes to save money. Apply the best one automatically at checkout."),(0,s.Z)(this,"settingsPaneCashbackText","Get money back for shopping online at select merchants. View cashback earned and activated it easily."),(0,s.Z)(this,"settingsPanePcText","Compare prices, shipping, and ratings for the same product from different sellers to find the best deals."),(0,s.Z)(this,"settingsPanePhText","Shows how a product's price changed over time and helps you predict when's the best time to buy."),(0,s.Z)(this,"settingsPaneProductTrackingText","Track products and get alerts when they're cheaper or in stock. We'll track the prices and availability for you."),(0,s.Z)(this,"settingsPanePackageTrackingText","Track your online orders and get delivery notifications. See the tracking number and the package status."),(0,s.Z)(this,"settingsPaneBingChatText","Chat with Bing AI and get quick answers to your shopping questions. We'll help you find the best products, prices, reviews, and tips."),(0,s.Z)(this,"settingsPaneDealsText","Discover new products based on your browsing and shopping history. See deals and promotions that suit your preferences and needs."),(0,s.Z)(this,"settingsPaneAutosText","Find the best deals on new and used cars near you. Compare prices, features, and ratings of different models and sellers."),(0,s.Z)(this,"settingsPaneGroceriesText","Find the best prices, coupons, and delivery options for groceries and other essentials."),(0,s.Z)(this,"settingsPaneOtherText","Stay updated on any other features or updates from Edge Shopping. We'll keep you informed as new features are added to help you save time and money."),(0,s.Z)(this,"paneMyShopping","My Shopping"),(0,s.Z)(this,"paneCouponsSavings","Coupons & Savings"),(0,s.Z)(this,"paneExplore","Explore"),(0,s.Z)(this,"paneNullStateMessage","Visit a shopping site to find savings with Microsoft Edge"),(0,s.Z)(this,"phTodayPriceAriaLabel","Today's price is $1"),(0,s.Z)(this,"phHighPriceAriaLabel","The highest price in history is $1 in $2"),(0,s.Z)(this,"phLowPriceArialLabel","The lowest price in history is $1 in $2"),(0,s.Z)(this,"zipPayPayment","Zip"),(0,s.Z)(this,"zipPayVirtualCardHeaderTitle","Pay with your Zip Visa card"),(0,s.Z)(this,"zipPayVirtualCardHeaderDescription","We've automatically filled your card information from Zip. Please confirm your card information and copy and paste any information that we didn't automatically fill correctly."),(0,s.Z)(this,"zipPayVirtualCardHeaderAutofillFailedDescription","We are unable to autofill your card information from Zip. Please manually enter your Zip card information during checkout."),(0,s.Z)(this,"zipPayVisualizedCardDetails","Illustration of Zip Visa card ending with $1, card holder $2, expires $3"),(0,s.Z)(this,"affirmPayment","Affirm"),(0,s.Z)(this,"affirmVirtualCardHeaderTitle","Pay with the Affirm virtual card"),(0,s.Z)(this,"affirmVirtualCardHeaderDescription","We securely auto filled your Affirm virtual card info and billing address to help save you time making this purchase."),(0,s.Z)(this,"affirmVirtualCardHeaderNoBillingInfoDescription","We securely auto filled your Affirm virtual card info to help save you time. To compete this purchase, please fill in your billing address."),(0,s.Z)(this,"affirmVirtualCardHeaderAutofillFailedDescription","We are unable to autofill your card information from Affirm. Please manually enter your Affirm card information during checkout."),(0,s.Z)(this,"affirmVisualizedCardDetails","Illustration of Affirm virtual card ending with $1, expires $2"),(0,s.Z)(this,"klarnaPayment","Klarna"),(0,s.Z)(this,"klarnaVirtualCardHeaderTitle","Pay with your Klarna virtual card"),(0,s.Z)(this,"klarnaVirtualCardHeaderDescription","We securely auto filled your Klarna virtual card info and billing address to help save you time making this purchase."),(0,s.Z)(this,"klarnaVirtualCardHeaderNoBillingInfoDescription","We securely auto filled your Klarna virtual card info to help save you time. To compete this purchase, please fill in your billing address."),(0,s.Z)(this,"klarnaVirtualCardHeaderAutofillFailedDescription","We are unable to autofill your card information from Klarna. Please manually enter your Klarna card information during checkout."),(0,s.Z)(this,"klarnaVisualizedCardDetails","Illustration of Klarna virtual card ending with $1, expires $2"),(0,s.Z)(this,"klarnaDisclaimerText","The Klarna Visa® Commercial Card is issued by Sutton Bank, Member FDIC, pursuant to a license from Visa U.S.A Inc. The Klarna Card is powered by Marqeta. Customer Service $1"),(0,s.Z)(this,"klarnaCustomerServiceNumber","+1 (844) 552-7621"),(0,s.Z)(this,"affirmDisclaimerText","The Affirm Card is a limited use virtual card and funded by either Cross River Bank, Member FDIC or Affirm Loan Services, LLC, depending on the terms of your loan agreement, and issued by Sutton Bank, Member FDIC, pursuant to license from Visa U.S.A. Inc. The Affirm Card is issued by Marqeta. $1 if you have any questions."),(0,s.Z)(this,"affirmDisclaimerLinkText","Contact Affirm"),(0,s.Z)(this,"trendingOffersTitle","Trending products"),(0,s.Z)(this,"similarOffersTitle","Shop for similar"),(0,s.Z)(this,"dailyDealsTitle","Hot deals"),(0,s.Z)(this,"relatedProductsModuleTitle","Related products you may like"),(0,s.Z)(this,"nativeAdsModuleTitle","Selected products"),(0,s.Z)(this,"visualSearchModuleTitle","Shop for similar"),(0,s.Z)(this,"percentageOff","$1 OFF"),(0,s.Z)(this,"offerAltText","$1 from $2 for $3"),(0,s.Z)(this,"dealOfferAltText","$1 from $2 for $3 reduced from $4 ($5 Off)"),(0,s.Z)(this,"sponsoredOfferAltText","Ad for $1 from $2 for $3"),(0,s.Z)(this,"sponsoredDealOfferAltText","Ad for $1 from $2 for $3 reduced from $4 ($5 Off)"),(0,s.Z)(this,"shopAllCTA","Shop all"),(0,s.Z)(this,"showMore","Show more"),(0,s.Z)(this,"adSlug","Ads"),(0,s.Z)(this,"productCardAdSlugText","Ad"),(0,s.Z)(this,"adSlugPolicy","Ads Policy"),(0,s.Z)(this,"buyDirectTitle","Buy with Microsoft & get free shipping"),(0,s.Z)(this,"buyDirectCashback","$1 cash back"),(0,s.Z)(this,"buyDirectShipping","free shipping"),(0,s.Z)(this,"buyDirectSeller","Buy with Microsoft"),(0,s.Z)(this,"buyDirectAltText","$1 for $2"),(0,s.Z)(this,"buyDirectOfferAltText","$1 for $2 reduced from $3 ($4 Off)"),(0,s.Z)(this,"productTrackingTitlePrice","Track price"),(0,s.Z)(this,"productTrackingTitlePriceUnTrack","Untrack price"),(0,s.Z)(this,"productTrackingTitleAvailability","Track availability"),(0,s.Z)(this,"productTrackingTitleAvailabilityUnTrack","Untrack availability"),(0,s.Z)(this,"productTrackingTitlePriceFor","Track price for $1"),(0,s.Z)(this,"productTrackingTitleAvailabilityFor","Track availability for $1"),(0,s.Z)(this,"productTrackingAlertBtnText","Alert Settings"),(0,s.Z)(this,"productTrackingViewTrackedText","View all tracked products"),(0,s.Z)(this,"productTrackingDescription","Get notified when product is in stock"),(0,s.Z)(this,"productTrackingBackInStockAlertsOn","Alerts on for product availability"),(0,s.Z)(this,"productTrackingInStockAtText","In stock at"),(0,s.Z)(this,"productTrackingBackInStockText","Back in stock at"),(0,s.Z)(this,"productTrackingViewItem","View item"),(0,s.Z)(this,"productTrackingTrackedProduct","Tracked product"),(0,s.Z)(this,"productTrackingAlertsOn","Alerts on"),(0,s.Z)(this,"productTrackingPriceDropText","Get notified when price drops"),(0,s.Z)(this,"productTrackingAbandonedCartPriceDropText","Get alerts for products in your cart"),(0,s.Z)(this,"productTrackingAbandonedCartTrackedPriceDropText","Alerts are on for products in your cart"),(0,s.Z)(this,"productTrackingOnRetailerText"," on $1"),(0,s.Z)(this,"productTrackingPriceDropAlertText","Alerts on for price drops"),(0,s.Z)(this,"productTrackingAlertSetting","Alert Setting"),(0,s.Z)(this,"productTrackingNotifyByEmail","Notify by email"),(0,s.Z)(this,"productTrackingDuration","Duration"),(0,s.Z)(this,"productTrackingXWeeks","$1 weeks"),(0,s.Z)(this,"productTrackingPriceDropXPercent","more than $1%"),(0,s.Z)(this,"productTrackingFeatureName","product tracking"),(0,s.Z)(this,"productTrackingPriceTrackAlert","You'll get alerts when product price drops"),(0,s.Z)(this,"productTrackingStockTrackAlert","You'll get alerts when product is back in stock"),(0,s.Z)(this,"productTrackingTrackFailed","Failed to track product"),(0,s.Z)(this,"productTrackingUntrackFailed","Failed to untrack product"),(0,s.Z)(this,"productTrackingInStockOther","In stock at other retailers"),(0,s.Z)(this,"productTrackingAlertBtnTextConcise","Alert settings"),(0,s.Z)(this,"productTrackingViewTrackedTextConcise","View tracked products"),(0,s.Z)(this,"productTrackingDescriptionConcise","Get alerts when in stock"),(0,s.Z)(this,"productTrackingAvailabilitySubtitleConcise","Get alerts when product is in stock"),(0,s.Z)(this,"productTrackingAlertsOnConcise","Alerts are on"),(0,s.Z)(this,"productTrackingPriceDropTextConcise","Get alerts on price drops"),(0,s.Z)(this,"productTrackingOnRetailerPreTextConcise","Get price drops alerts"),(0,s.Z)(this,"productTrackingForRetailerTextConcise"," for $1"),(0,s.Z)(this,"productTrackingNotificationOk","Ok"),(0,s.Z)(this,"productTrackingNotificationTrackProduct","Track Product"),(0,s.Z)(this,"productTrackingCouponOfferPercentage","with $1% coupon"),(0,s.Z)(this,"productTrackingNotificationCouponOffers","$1 on your tracked product at $2"),(0,s.Z)(this,"productTrackingCashbackOfferValue","with $1 cashback"),(0,s.Z)(this,"productTrackingNotificationCashbackOffers","Up to $1 cashback on your tracked product at $2"),(0,s.Z)(this,"productTrackingNotificationEmailText","Send updates via email"),(0,s.Z)(this,"productTrackingNotificationTooltipText","Tracked products will be associated with the Microsoft account you have used to sign in on Microsoft Edge. Previously tracked products will be automatically saved to your account. You will receive emails from Microsoft, which include offers about Microsoft and partner products. $1"),(0,s.Z)(this,"productTrackingNotificationSeeTerms","See terms"),(0,s.Z)(this,"spcbCashbackBalance","Cashback balance of $1"),(0,s.Z)(this,"spcbJoinNow","Join now"),(0,s.Z)(this,"spcbViewTopDeals","View top deals"),(0,s.Z)(this,"spcbTrackCashback","Track your cash back"),(0,s.Z)(this,"spcbRedeemNow","Redeem now!"),(0,s.Z)(this,"spcbCheckOffers","Check offers"),(0,s.Z)(this,"spcbViewAcct","View Cashback account"),(0,s.Z)(this,"spcbJoinNewUser","Join Microsoft Cashback and earn cash back when you shop."),(0,s.Z)(this,"spcbPassiveUser","Start earning cash back with Microsoft Cashback!"),(0,s.Z)(this,"spcbUnknownValue","You recently completed a purchase$1! Check back soon to see your exact cash back amount."),(0,s.Z)(this,"spcbKnownValue","You just earned $1 for your purchase $2."),(0,s.Z)(this,"spcbCashoutReady","Your $1 is ready for cash out."),(0,s.Z)(this,"spcbCashedOut","Explore more deals with Microsoft Cashback."),(0,s.Z)(this,"spcbEnrolledUserTitle","Ka-ching! Your $1 cash back is ready!"),(0,s.Z)(this,"spcbEnrolledUserNoBalanceTitle","Check your cash back details here!"),(0,s.Z)(this,"spcbEnrolledNoAmountUserTitle","You have cash back available!"),(0,s.Z)(this,"spcbNotEnrolledUserTitle","Earn cash back when you shop!"),(0,s.Z)(this,"gcAnonFlowPendingModuleTitle","Pending cashback"),(0,s.Z)(this,"gcAnonFlowPendingTitle","Cash back for you"),(0,s.Z)(this,"gcAnonFlowPendingButton","Join and claim now"),(0,s.Z)(this,"microsoftRewards","Microsoft Rewards"),(0,s.Z)(this,"terms","Terms"),(0,s.Z)(this,"privacyAndCookies","Privacy & Cookies"),(0,s.Z)(this,"gcDisclaimer","You will be signed in to Microsoft Edge which will back up your browsing data and let you see your favorites, passwords, history and more on all your devices. You will also join and receive emails about $1, which include offers about partner products. $2 | $3"),(0,s.Z)(this,"gcDisclaimerSignedIn","You will join and receive emails about $1, which include offers about partner products. $2 | $3"),(0,s.Z)(this,"gcConfirmationTextSpb","And You'll receive email updates for this cash back offer."),(0,s.Z)(this,"inboxSavingsFeatureName","inbox savings"),(0,s.Z)(this,"inboxCouponsFeatureName","inbox coupons"),(0,s.Z)(this,"inboxCouponsTitle","Inbox coupons"),(0,s.Z)(this,"inboxCouponsFromRetailerTitle","Inbox coupons from $1"),(0,s.Z)(this,"inboxCouponsLearnMore","Learn more about how inbox coupons works"),(0,s.Z)(this,"inboxCouponDescription","Coupon found in your inbox"),(0,s.Z)(this,"inboxCouponsFound","Inbox coupons found!"),(0,s.Z)(this,"inboxCouponsSettingsTitle","Inbox coupons settings"),(0,s.Z)(this,"newCoupon","New"),(0,s.Z)(this,"retailerSentYouThisCoupon","$1 sent you this coupon"),(0,s.Z)(this,"retailerSentYouZeroCoupon","No inbox coupons from $1 were found"),(0,s.Z)(this,"retailerSentYouOneCoupon","$1 sent you 1 inbox coupon"),(0,s.Z)(this,"retailerSentYouNCoupons","$1 sent you $2 inbox coupons"),(0,s.Z)(this,"retailerSentYouOneRecentCoupon","$1 sent you 1 recent inbox coupon"),(0,s.Z)(this,"retailerSentYouNRecentCoupons","$1 sent you $2 recent inbox coupons"),(0,s.Z)(this,"couponsCount","{NUMBER, plural, =1 {1 coupon} other {# coupons}}"),(0,s.Z)(this,"recentCoupons","{NUMBER, plural, =1 {1 recent coupon} other {# recent coupons}}"),(0,s.Z)(this,"noCouponsFound","No coupons found"),(0,s.Z)(this,"inboxRetailerHasCoupons","{NUMBER, plural, =1 {$1 has 1 coupon} other {$1 has # coupons}}"),(0,s.Z)(this,"emailConnectedToDifferentUserError","The email address you're trying to connect to is already linked to another Microsoft Edge profile. Try another email."),(0,s.Z)(this,"userHasDifferentEmailError","Your Microsoft Edge profile is linked to a different email address. Try using the correct email address, or $1 and try again."),(0,s.Z)(this,"emailBlockedError","Try reconnecting in a few minutes. Based on a previous request we are still in the process of disconnecting the email you are trying to sign in with."),(0,s.Z)(this,"switchToAnotherPersonalProfile","switch to another personal profile"),(0,s.Z)(this,"reconnectedDifferentEmailTitle","You tried connecting using an incorrect email address"),(0,s.Z)(this,"disconnectYourCurrentInbox","Disconnect your current email"),(0,s.Z)(this,"orReconnectEmailAction","$1 using $2"),(0,s.Z)(this,"reconnectWithYourEmailProvider","Reconnect your $1"),(0,s.Z)(this,"previouslyConnectedEmail","You were previously connected to $1"),(0,s.Z)(this,"inboxCouponsLoginCardDescription","Connect your email and get coupon codes instantly applied to your cart at checkout"),(0,s.Z)(this,"inboxCouponsConnect","Connect your email"),(0,s.Z)(this,"inboxCouponsMicrosoftLoginButtonText","Continue with Outlook"),(0,s.Z)(this,"inboxCouponsGoogleLoginButtonText","Continue with Gmail"),(0,s.Z)(this,"emailProviderMicrosoft","Outlook"),(0,s.Z)(this,"emailProviderGmail","Gmail"),(0,s.Z)(this,"outlookLogo","Outlook Logo"),(0,s.Z)(this,"gmailLogo","Gmail Logo"),(0,s.Z)(this,"noInboxCouponsTitle","Coupons found from verified retailers will appear here"),(0,s.Z)(this,"inboxCouponsVerifiedRetailersLearn","Learn about verified retailers"),(0,s.Z)(this,"noInboxCouponsSendersDescription","Only emails from verified retailers are scanned. Once coupons are found in your inbox, you will be able to manage which emails are scanned."),(0,s.Z)(this,"accessRevokedInboxCouponsTitle","We're having trouble*br*connecting to your email"),(0,s.Z)(this,"loadingInboxCoupons","Loading inbox coupons!"),(0,s.Z)(this,"loadedInboxCoupons","Inbox coupons loaded!"),(0,s.Z)(this,"inboxCouponsForEdgeUsersOnly","Inbox coupons is available only to Microsoft Edge users signed in to their personal accounts"),(0,s.Z)(this,"edgeWorkProfileError","You're signed into Microsoft Edge using your work or school account. $1"),(0,s.Z)(this,"switchingToEdgePersonalProfile","Switch to a personal profile"),(0,s.Z)(this,"addEdgeProfile","Sign in to Microsoft Edge"),(0,s.Z)(this,"inboxCouponsEmailSenderSingular","1 verified email sender"),(0,s.Z)(this,"inboxCouponsEmailSenderPlural","$1 verified email senders"),(0,s.Z)(this,"inboxCouponsRetailerHasEmailSenders","{NUMBER, plural, =1 {$1 has 1 verified email sender} other {$1 has # verified email senders}}"),(0,s.Z)(this,"comingSoon","Coming soon"),(0,s.Z)(this,"readingFromRetailerDomainEnabled","Reading messages from $1 enabled"),(0,s.Z)(this,"readingFromRetailerDomainDisabled","Reading messages from $1 disabled"),(0,s.Z)(this,"showRetailerCoupons","Show $1 coupons"),(0,s.Z)(this,"showRetailerEmailSenders","Show $1 verified email senders"),(0,s.Z)(this,"settings","Settings"),(0,s.Z)(this,"goToInboxCouponsSettingsTitle","Go to inbox coupons settings"),(0,s.Z)(this,"actionRequiredInSettingsTitle","Action required in settings"),(0,s.Z)(this,"goBackToCouponsTitle","Go back to coupons"),(0,s.Z)(this,"disconnect","Disconnect"),(0,s.Z)(this,"cancel","Cancel"),(0,s.Z)(this,"connect","Connect"),(0,s.Z)(this,"reconnect","Reconnect"),(0,s.Z)(this,"performActionOnInbox","$1 email"),(0,s.Z)(this,"performOneOfTwoActionsOnInbox","$1 or $2"),(0,s.Z)(this,"previouslyLinkedToEmailAddress","Previously linked to $1"),(0,s.Z)(this,"performActionOnDifferentEmailAddress","$1 to a different email address"),(0,s.Z)(this,"disconnectInboxDialogTitle","Disconnect email?"),(0,s.Z)(this,"disconnectInboxDialogDescription","All inbox coupons will be removed, and your inbox will no longer be scanned. You can reconnect at any time."),(0,s.Z)(this,"disconnectInboxErrorMsg","We're having trouble disconnecting your email. Please try again later."),(0,s.Z)(this,"inboxCouponsCountFound","{NUMBER, plural, =1 {1 inbox coupon found} other {# inbox coupons found}}"),(0,s.Z)(this,"inboxCouponsAccessRevoked","Unable to connect to your email"),(0,s.Z)(this,"retailSendersInInboxTitle","Retailers in your inbox ($1)"),(0,s.Z)(this,"noRetailerSendersInInboxTitle","There are no retailers in your inbox"),(0,s.Z)(this,"retailSendersInInboxDescription","Manage which retailer emails get scanned for coupons"),(0,s.Z)(this,"retailersTitleWithNum","$1 retailers"),(0,s.Z)(this,"inboxCouponsSignInConsentMessage","By signing in you agree to $1 and $2."),(0,s.Z)(this,"inboxCouponsGmailSignInConsentMessage","Inbox coupons, if connecting to a Gmail account, does so in compliance with the $1, including the Limited Use requirements."),(0,s.Z)(this,"inboxCouponsEdgeLoginFooterMessage","Signing in will also sync your settings and backup your browsing data for you to see favorites, passwords, and more on all your devices. $1."),(0,s.Z)(this,"googleAPIServicesUserDataPolicy","Google API Services User Data Policy"),(0,s.Z)(this,"newInboxCouponFound","New coupon found in your inbox"),(0,s.Z)(this,"connectedEmailSettings","$1's settings and has $2 inbox coupons"),(0,s.Z)(this,"inboxCouponsTabSwitched","Switched to $1"),(0,s.Z)(this,"needHelpTitle","Need help?"),(0,s.Z)(this,"feedbackForm","feedback form"),(0,s.Z)(this,"inboxCouponNeedHelpDescription","Reach out to us using the $1 to share any problems you would like to report or suggestions and feedback that you have about your experience with inbox coupons."),(0,s.Z)(this,"inboxCouponsUpsellCard","Don't miss on savings hidden in your inbox. $1"),(0,s.Z)(this,"inboxCouponsReloadCoupons","Reload inbox coupons"),(0,s.Z)(this,"inboxCouponsReloadingCoupons","Reloading inbox coupons"),(0,s.Z)(this,"inboxCouponsReloadedCoupons","Reloaded inbox coupons"),(0,s.Z)(this,"next","Next"),(0,s.Z)(this,"previous","Previous"),(0,s.Z)(this,"doNotMissSavingsTitle","Don't miss out on savings*br*hidden in your inbox"),(0,s.Z)(this,"doNotMissSavingsDescription","It's easy. Just sign in with your email and we'll scan your inbox to find active coupons."),(0,s.Z)(this,"personalEmailsAreNeverScannedTitle","Your personal emails*br*are never scanned"),(0,s.Z)(this,"personalEmailsAreNeverScannedDescription","We only scan promotional emails, nothing else. You have control over which retailer emails get scanned, too."),(0,s.Z)(this,"autoApplyCouponsAtCheckoutTitle","Coupons are automatically*br*applied at checkout"),(0,s.Z)(this,"autoApplyCouponsAtCheckoutDescription","Once your email is connected, we'll do the work so you can start saving."),(0,s.Z)(this,"searchForCoupons","Your email is connected.*br*Scanning for coupons now."),(0,s.Z)(this,"connectingEmail","Connecting to your email..."),(0,s.Z)(this,"seeOtherRetailers","See other retailers ($1)"),(0,s.Z)(this,"disconnectionFailed","Disconnection failed"),(0,s.Z)(this,"signInFailed","Sign in failed"),(0,s.Z)(this,"copyInboxCoupon","Copy $1 coupon"),(0,s.Z)(this,"copiedInboxCoupon","Copied $1 coupon"),(0,s.Z)(this,"trendingCouponsTitle","Best coupons on the web"),(0,s.Z)(this,"trendingCouponsTopLine","$1% off with coupon code"),(0,s.Z)(this,"trendingCouponsSeeMore","See more coupons"),(0,s.Z)(this,"trendingCouponsNavigateToRetailerSite","Click again to redeem at"),(0,s.Z)(this,"copyCouponDisclosureText","I allow placing of third party cookies on my device to facilitate billing with affiliate offer as per $1. Microsoft may receive compensation for using these coupons."),(0,s.Z)(this,"dealDays","Deal Days"),(0,s.Z)(this,"dealDaysDetailsText","Microsoft Edge Deal Days are here. Shop online with Edge for all the deals."),(0,s.Z)(this,"dealDaysTimeRangeText","May 8 - 15"),(0,s.Z)(this,"dealDaysAriaAwarenesses","See details about Microsoft Edge Deal Days"),(0,s.Z)(this,"dealDaysAllDeals","All deals"),(0,s.Z)(this,"dealDaysSeeAllDeals","See all deals"),(0,s.Z)(this,"dealDaysExclusive","Exclusive"),(0,s.Z)(this,"dealDaysCashbackDiscount","after cash back"),(0,s.Z)(this,"dealDaysCouponDiscount","after coupon"),(0,s.Z)(this,"dealDaysMultiDiscount","after coupon and cash back"),(0,s.Z)(this,"dealDayTimePrefixCompact","Ends $1"),(0,s.Z)(this,"dealDayTimePrefix","Ends in $1"),(0,s.Z)(this,"dealDaysAwarenessTitle","Let the savings begin!"),(0,s.Z)(this,"dealDaysAwarenessSubtitle","Shop online with Edge for all the deals, now through May 14."),(0,s.Z)(this,"wishlistTitle","Save to wishlist"),(0,s.Z)(this,"wishlistCollectionTitle","Shopping wishlist"),(0,s.Z)(this,"wishlistViewAll","View saved products"),(0,s.Z)(this,"wishlistUnsave","Unsave"),(0,s.Z)(this,"wishlistSaveAltText","Save $1 to your Shopping Wishlist"),(0,s.Z)(this,"wishlistUnsaveAltText","Unsave $1 from your Shopping Wishlist"),(0,s.Z)(this,"trendingRecHeader","Top price drops on $1!"),(0,s.Z)(this,"trendingRecSubtitle","Compare today's price to its trend, so you know the real discount you're getting."),(0,s.Z)(this,"trendingRecSectionTitle","Price drops on $1"),(0,s.Z)(this,"trendingRecButton","View price drops"),(0,s.Z)(this,"sanConsentFeatureName","Personalization Consent"),(0,s.Z)(this,"sanConsentHeaderTopText","Make your shopping feed better"),(0,s.Z)(this,"sanConsentHeaderBottomText","Personalize your*br*web experience"),(0,s.Z)(this,"sanConsentHeaderBottomTextV2","Personalize your web experience"),(0,s.Z)(this,"sanConsentHeaderBottomTextEU","Personalize your web and ads experience"),(0,s.Z)(this,"sanConsentBodyTopText","Allow Microsoft to save your browsing activity to personalize Microsoft Edge and other Microsoft services like shopping, search, news, and ads.*br*Your browsing activity includes history, usage, favorites, web content, and other browsing content. $1 | $2"),(0,s.Z)(this,"sanConsentButton","Turn on web personalization"),(0,s.Z)(this,"sanConsentButtonV2","Get started"),(0,s.Z)(this,"sanConsentSuccessString","Your shopping feed and other Microsoft services will get better as we learn more about you."),(0,s.Z)(this,"sanConsentAcceptButton","Yes, turn on"),(0,s.Z)(this,"sanConsentRejectButton","No, thanks"),(0,s.Z)(this,"sanConsentSeeMoreOffers","See more relevant offers"),(0,s.Z)(this,"sanConsentActivatedText","You'll see more relevant offers in shopping feed and other Microsoft services."),(0,s.Z)(this,"sanConsentHeaderTopTextNotification","Get great deals!"),(0,s.Z)(this,"sanConsentHeaderTopTextNotifPostPurchase","Save more next time!"),(0,s.Z)(this,"cjkExpiryDate","Expiry on: $1"),(0,s.Z)(this,"cjkClaim","Use"),(0,s.Z)(this,"cjkSimilarProductsSectionTitle","Similar products"),(0,s.Z)(this,"cjkPHDaysLowest","Lowest price in the past $1 days"),(0,s.Z)(this,"cjkPHTimeDurSixMonth","6 Months"),(0,s.Z)(this,"cjkPHTimeDurThreeMonth","3 Months"),(0,s.Z)(this,"cjkPHTimeDurOneMonth","1 Month"),(0,s.Z)(this,"cjkPaneNullStateMessage","Sorry, currently there is no available data for the product your are looking for."),(0,s.Z)(this,"cjkOpenHubIconName","Open Side Pane"),(0,s.Z)(this,"cjkPriceDrop","Price Drop"),(0,s.Z)(this,"cjkCouponFound","Coupon Found"),(0,s.Z)(this,"cjkHoverButtonShowFlyoutName","Hover Button Show Flyout Name"),(0,s.Z)(this,"cjkFlyoutCouponsSectionTitle","Coupons"),(0,s.Z)(this,"cjkNullSatateDescription","No available data for the product currently"),(0,s.Z)(this,"cjkHighestPrice","Highest Price"),(0,s.Z)(this,"cjkPriceLowerThanUsual","Lower Than Usual"),(0,s.Z)(this,"cjkSeePriceHistory","See price hisotry"),(0,s.Z)(this,"cjkGetCoupon","Get Coupon"),(0,s.Z)(this,"cjkSaveWithCoupon","Save $1 with coupon"),(0,s.Z)(this,"postPurchaseRewardsFeatureName","post purchase rewards"),(0,s.Z)(this,"postPurchaseRewardsTitlePrefix","You earned $1 for this purchase"),(0,s.Z)(this,"postPurchaseRewardsTitleMiddle","points"),(0,s.Z)(this,"postPurchaseRewardsSubtitleSuffix","total Rewards points"),(0,s.Z)(this,"postPurchaseRewardsButtonText","View rewards"),(0,s.Z)(this,"minutesAgo","Used $1min ago"),(0,s.Z)(this,"hourAgo","Used $1hr ago"),(0,s.Z)(this,"hoursAgo","Used $1hrs ago"),(0,s.Z)(this,"daysAgo","Used $1 days ago"),(0,s.Z)(this,"cbOK","Click OK"),(0,s.Z)(this,"cbPurchase","Purchase"),(0,s.Z)(this,"cbGetCashback","Get cash back"),(0,s.Z)(this,"cbNext","Next"),(0,s.Z)(this,"cbEasyTitle","Earning cash back is easy!"),(0,s.Z)(this,"cbShop","Shop!"),(0,s.Z)(this,"cbEarn","Earn cash back after purchase"),(0,s.Z)(this,"cbStep","Step $1"),(0,s.Z)(this,"triviaCashbackSavers","$1 of users earned cash back!"),(0,s.Z)(this,"triviaCashbackSavings","Edge users earned $1 cash back last month!"),(0,s.Z)(this,"triviaCashbackAvrDailySavings","On average, users earn $1 daily with cashback!"),(0,s.Z)(this,"triviaCouponsSavers","$1 of users saved money with coupons!"),(0,s.Z)(this,"triviaCouponsSavings","Users saved $1 last month with coupons!"),(0,s.Z)(this,"triviaCouponsAvrDailySavings","On average, users save $1 daily with coupons!"),(0,s.Z)(this,"loadingSpinnerText","Finding the best deals..."),(0,s.Z)(this,"percentage_pricedrop_key","$1% price drop"),(0,s.Z)(this,"percentage_pricedrop_long_key","Price dropped $1% below its 90-day average"),(0,s.Z)(this,"percentage_off_key","$1% off"),(0,s.Z)(this,"curbsidepickup","Curbside pickup"),(0,s.Z)(this,"gooddealsdecoration","Good Deal"),(0,s.Z)(this,"highly_rated_key","Highly Rated"),(0,s.Z)(this,"refurbished","Refurbished"),(0,s.Z)(this,"remanufactured","Remanufactured"),(0,s.Z)(this,"used","Used"),(0,s.Z)(this,"popular","POPULAR"),(0,s.Z)(this,"popular_decoration_key","Popular"),(0,s.Z)(this,"pricedecorationsaletag","SALE"),(0,s.Z)(this,"sustainablebrands","Ethical brands"),(0,s.Z)(this,"sustainable_key","Ethical Shopping"),(0,s.Z)(this,"trending","TRENDING"),(0,s.Z)(this,"trending_decoration_key","Trending"),(0,s.Z)(this,"free_shipping","Free shipping"),(0,s.Z)(this,"filterNoDataErrorMessage","Oops! No offers match your selection. Please adjust your filters"),(0,s.Z)(this,"dataLoader",void 0),this.dataLoader=e}Create(e){const t=this.dataLoader;this.shoppingTripsTitle=t.GetString("shoppingTripsTitle",this.shoppingTripsTitle),this.shopTripAllPurchase=t.GetString("shopTripAllPurchase",this.shopTripAllPurchase),this.shopTripActivePurchases=t.GetString("shopTripActivePurchases",this.shopTripActivePurchases),this.shopTripEmptyMessage=t.GetString("shopTripEmptyMessage",this.shopTripEmptyMessage),this.shopTripCashBackAmountPending=t.GetString("shopTripCashBackAmountPending",this.shopTripCashBackAmountPending),this.shopTripCashBackCompletePurchaseLink=t.GetString("shopTripCashBackCompletePurchaseLink",this.shopTripCashBackCompletePurchaseLink),this.shopTripStatusOfferActivated=t.GetString("shopTripStatusOfferActivated",this.shopTripStatusOfferActivated),this.shopTripStatusMerchantProcessing=t.GetString("shopTripStatusMerchantProcessing",this.shopTripStatusMerchantProcessing),this.shopTripStatusCashbackReceived=t.GetString("shopTripStatusCashbackReceived",this.shopTripStatusCashbackReceived),this.cashbackCarouselStepOne=t.GetString("cashbackCarouselStepOne",this.cashbackCarouselStepOne),this.cashbackCarouselStepTwo=t.GetString("cashbackCarouselStepTwo",this.cashbackCarouselStepTwo),this.cashbackCarouselStepThree=t.GetString("cashbackCarouselStepThree",this.cashbackCarouselStepThree),this.cashbackCarouselLegalese=t.GetString("cashbackCarouselLegalese",this.cashbackCarouselLegalese),this.commonCMAutoShowDisable=t.GetString("contextMenuAutoShowDisable",this.commonCMAutoShowDisable),this.commonCMAutoShowDisableFeature=t.GetString("commonCMAutoShowDisableFeature",this.commonCMAutoShowDisableFeature),this.commonCMAutoShowEnable=t.GetString("contextMenuAutoShowEnable",this.commonCMAutoShowEnable),this.commonCMAutoShowEnableFeature=t.GetString("commonCMAutoShowEnableFeature",this.commonCMAutoShowEnableFeature),this.commonSnoozeShopping=t.GetString("commonSnoozeShopping",this.commonSnoozeShopping),this.commonCMManage=t.GetString("contextMenuManage",this.commonCMManage),this.commonManageNotifications=t.GetString("commonManageNotifications",this.commonManageNotifications),this.commonShoppingSettings=t.GetString("commonShoppingSettings",this.commonShoppingSettings),this.commonMoreOptionsLabel=t.GetString("moreOptionsLabel",this.commonMoreOptionsLabel),this.commonFixedTitle=t.GetString("fixedTitle",this.commonFixedTitle),this.commonFixedTitleNew=t.GetString("fixedTitleNew",this.commonFixedTitleNew),this.commonMicrosoftPolicy=t.GetString("microsoftPolicy",this.commonMicrosoftPolicy),this.commonMicrosoftTermsOfUse=t.GetString("microsoftTermsOfUse",this.commonMicrosoftTermsOfUse),this.commonSeeMore=t.GetString("commonSeeMore",this.commonSeeMore),this.commonLearnMore=t.GetString("learnMore",this.commonLearnMore),this.termsAndConditions=t.GetString("termsAndConditions",this.termsAndConditions),this.commonYouCanSave=t.GetString("youCanSave",this.commonYouCanSave),this.commonSeeAll=t.GetString("commonSeeAll",this.commonSeeAll),this.commonMonth=t.GetString("commonMonth",this.commonMonth),this.commonNow=t.GetString("commonNow",this.commonNow),this.commonSave=t.GetString("saveX",this.commonSave),this.commonSaveSimple=t.GetString("save",this.commonSaveSimple),this.commonSaveOtherSellers=t.GetString("commonSaveOtherSellers",this.commonSaveOtherSellers),this.itemizedCashBackAddToCart=t.GetString("itemizedCashBackAddToCart",this.itemizedCashBackAddToCart),this.itemizedCashBackSpbAddToCart=t.GetString("itemizedCashBackSpbAddToCart",this.itemizedCashBackSpbAddToCart),this.itemizedCashBackSpbAutoActivate=t.GetString("itemizedCashBackSpbAutoActivate",this.itemizedCashBackSpbAutoActivate),this.itemizedCashBackSpbAutoATC=t.GetString("itemizedCashBackSpbAutoATC",this.itemizedCashBackSpbAutoATC),this.commonAltSettings=t.GetString("commonAltSettings",this.commonAltSettings),this.commonInternationalDisclaimer=t.GetString("internationalDisclaimer",this.commonInternationalDisclaimer),this.thirdPartCookiesText=t.GetString("thirdPartCookiesText",this.thirdPartCookiesText),this.commonClose=t.GetString("closeLabel",this.commonClose),this.commonClear=t.GetString("commonClear",this.commonClear),this.commonSearch=t.GetString("commonSearch",this.commonSearch),this.doNotShowString=t.GetString("doNotShowBtn",this.doNotShowString),this.snoozeButton=t.GetString("snoozeEnable",this.snoozeButton),this.turnOffSnooze=t.GetString("snoozeDisable",this.turnOffSnooze),this.remindLater=t.GetString("remindLater",this.remindLater),this.snoozeTooltip=t.GetString("snoozeTooltip",this.snoozeTooltip),this.ariaSnoozeOn=t.GetString("ariaSnoozeOn",this.ariaSnoozeOn),this.ariaSnoozeoff=t.GetString("ariaSnoozeoff",this.ariaSnoozeoff),this.commonContextualTab=t.GetString("tabContextualTitle",this.commonContextualTab),this.commonHomeTab=t.GetString("tabHomeTitle",this.commonHomeTab),this.commonMyShoppingTab=t.GetString("commonMyShoppingTab",this.commonMyShoppingTab),this.commonExploreTab=t.GetString("commonExploreTab",this.commonExploreTab),this.commonErrorTitle=t.GetString("errorTitle",this.commonErrorTitle),this.commonErrorSubTitle=t.GetString("errorSubTitle",this.commonErrorSubTitle),this.commonPrivacy=t.GetString("privacy",this.commonPrivacy),this.commonPersonalizationSettings=t.GetString("commonPersonalizationSettings",this.commonPersonalizationSettings),this.privacyConsentNew=t.GetString("privacyConsentNew",this.privacyConsentNew),this.privacyConsentProvider=t.GetString("privacyConsentProvider",this.privacyConsentProvider),this.rewardGiftCardConsent=t.GetString("rewardGiftCardConsent",this.rewardGiftCardConsent),this.rewardsjoinAckText=t.GetString("rewardsjoinAckText",this.rewardsjoinAckText),this.rewardsFeatureName=t.GetString("rewardsFeatureName",this.rewardsFeatureName),this.couponEmptyCouponSubTitle=t.GetString("EmptyCouponSubTitle",this.couponEmptyCouponSubTitle),this.couponEmptyCouponTitle=t.GetString("EmptyCouponTitle",this.couponEmptyCouponTitle),this.couponAutoApplyButton=t.GetString("autoApplyButton",this.couponAutoApplyButton),this.couponAutoApplyButtonRetry=t.GetString("couponAutoApplyButtonRetry",this.couponAutoApplyButtonRetry),this.couponAutoApplyButtonAlt=t.GetString("autoApplyButtonAlt",this.couponAutoApplyButtonAlt),this.couponAutoApplyButtonInstantSavings=t.GetString("couponAutoApplyButtonInstantSavings",this.couponAutoApplyButtonInstantSavings),this.couponFeatureName=t.GetString("couponFeatureName",this.couponFeatureName),this.couponCarouselLabel=t.GetString("couponCarouselLabel",this.couponCarouselLabel),this.cashbackAvailable=t.GetString("cashbackAvailable",this.cashbackAvailable),this.cashbackHistoryHeader=t.GetString("cashbackHistoryHeader",this.cashbackHistoryHeader),this.cashbackHistorySeeFull=t.GetString("cashbackHistorySeeFull",this.cashbackHistorySeeFull),this.cashbackHistorySeeMore=t.GetString("cashbackHistorySeeMore",this.cashbackHistorySeeMore),this.cashbackHistorySeeLess=t.GetString("cashbackHistorySeeLess",this.cashbackHistorySeeLess),this.cashbackActivatedOffersHeader=t.GetString("cashbackActivatedOffersHeader",this.cashbackActivatedOffersHeader),this.cashbackActivatedOffersSeeFull=t.GetString("cashbackActivatedOffersSeeFull",this.cashbackActivatedOffersSeeFull),this.cashbackActivatedOffersSeeMore=t.GetString("cashbackActivatedOffersSeeMore",this.cashbackActivatedOffersSeeMore),this.cashbackActivatedOffersSeeLess=t.GetString("cashbackActivatedOffersSeeLess",this.cashbackActivatedOffersSeeLess),this.cashbackEnrollSuccessMessage=t.GetString("cashbackEnrollSuccessMessage",this.cashbackEnrollSuccessMessage),this.cashbackEnrollSuccessLink=t.GetString("cashbackEnrollSuccessLink",this.cashbackEnrollSuccessLink),this.cashbackWelcomeBannerHeader=t.GetString("cashbackWelcomeBannerHeader",this.cashbackWelcomeBannerHeader),this.cashbackWelcomeBannerBody=t.GetString("cashbackWelcomeBannerBody",this.cashbackWelcomeBannerBody),this.cashbackRedeemBannerTitle=t.GetString("cashbackRedeemBannerTitle",this.cashbackRedeemBannerTitle),this.cashbackRedeemBannerLinkText=t.GetString("cashbackRedeemBannerLinkText",this.cashbackRedeemBannerLinkText),this.cashbackActivatedOfferTimePrefix=t.GetString("cashbackActivatedOfferTimePrefix",this.cashbackActivatedOfferTimePrefix),this.cashbakcActivatedOfferHourSymbol=t.GetString("cashbakcActivatedOfferHourSymbol",this.cashbakcActivatedOfferHourSymbol),this.cashbackActivatedOfferMinuteSymbol=t.GetString("cashbackActivatedOfferMinuteSymbol",this.cashbackActivatedOfferMinuteSymbol),this.cashbackProductOfferLinkText=t.GetString("cashbackProductOfferLinkText",this.cashbackProductOfferLinkText),this.cashbackProductOfferPostfix=t.GetString("cashbackProductOfferPostfix",this.cashbackProductOfferPostfix),this.cashbackRetailerOfferLinkText=t.GetString("cashbackRetailerOfferLinkText",this.cashbackRetailerOfferLinkText),this.cashbackRetailerOfferPostfix=t.GetString("cashbackRetailerOfferPostfix",this.cashbackRetailerOfferPostfix),this.cashbackTopOfferPostTag=t.GetString("cashbackTopOfferPostTag",this.cashbackTopOfferPostTag),this.cashbackTopOfferPostUsageCount=t.GetString("cashbackTopOfferPostUsageCount",this.cashbackTopOfferPostUsageCount),this.cashbackTopOfferTitle=t.GetString("cashbackTopOfferTitle",this.cashbackTopOfferTitle),this.articlesCashbackFeatureName=t.GetString("articlesCashbackFeatureName",this.articlesCashbackFeatureName),this.autoApplyFeatureName=t.GetString("autoApplyFeatureName",this.autoApplyFeatureName),this.mergedNewAutoApplyButton=t.GetString("mergedNewAutoApplyButton",this.mergedNewAutoApplyButton),this.backgroundAutoApplyFeatureName=t.GetString("backgroundAutoApplyFeatureName",this.backgroundAutoApplyFeatureName),this.couponCopied=t.GetString("copyCoupon",this.couponCopied),this.couponCopyLabel=t.GetString("copyCodeLabel",this.couponCopyLabel),this.couponCopyLabelRefresh=t.GetString("copyButtonTooltip",this.couponCopyLabelRefresh),this.couponCopyAndApply=t.GetString("couponCopyAndApply",this.couponCopyAndApply),this.couponTitle=t.GetString("couponTitleNew",this.couponTitle),this.couponTitleApply=t.GetString("couponTitleApply",this.couponTitleApply),this.couponWithSiteTitle=t.GetString("couponWithSiteTitle",this.couponWithSiteTitle),this.couponTitleWithNumStr=t.GetString("couponTitleWithNumStr",this.couponTitleWithNumStr),this.couponTitleInstantSavings=t.GetString("couponTitleInstantSavings",this.couponTitleInstantSavings),this.pcBestPriceHeader=t.GetString("bestPriceHeader",this.pcBestPriceHeader),this.priceCompareCashback=t.GetString("priceCompareCashback",this.priceCompareCashback),this.priceCompareWithCashback=t.GetString("priceCompareWithCashback",this.priceCompareWithCashback),this.priceCompareCashBackShort=t.GetString("priceCompareCashBackShort",this.priceCompareCashBackShort),this.pcBestPriceRefreshHeader=t.GetString("bestPriceRefreshHeader",this.pcBestPriceRefreshHeader),this.pcNotificationSeeMoreInfo=t.GetString("pcNotificationSeeMoreInfo",this.pcNotificationSeeMoreInfo),this.pcNow=t.GetString("pcNow",this.pcNow),this.pcLowest=t.GetString("pcLowest",this.pcLowest),this.pcLowestUpdated=t.GetString("pcLowestUpdated",this.pcLowestUpdated),this.pcSmallSavingsHeader=t.GetString("pcSmallSavingsHeader",this.pcSmallSavingsHeader),this.pcNotificationVisitItem=t.GetString("pcNotificationVisitItem",this.pcNotificationVisitItem),this.pcNotificationShopAt=t.GetString("pcNotificationShopAt",this.pcNotificationShopAt),this.pcPriceSectionTitle=t.GetString("priceSectionTitle",this.pcPriceSectionTitle),this.newpcPriceSectionTitle=t.GetString("newpriceSectionTitle",this.newpcPriceSectionTitle),this.productSummaryCardSectionTitle=t.GetString("productSummaryCardSectionTitle",this.productSummaryCardSectionTitle),this.pcTooltipText=t.GetString("pcTooltipText",this.pcTooltipText),this.pcAffiliateTooltipLabel=t.GetString("pcAffiliateTooltipLabel",this.pcAffiliateTooltipLabel),this.pcBestPriceTitle=t.GetString("pcBestPriceTitle",this.pcBestPriceTitle),this.cbActivateButtonRefresh=t.GetString("activateCashBackButtonRefresh",this.cbActivateButtonRefresh),this.cbActivateButton=t.GetString("cbActivateButton",this.cbActivateButton),this.cbActivatedButton=t.GetString("cashBackActivatedButton",this.cbActivatedButton),this.pcbActivatedButton=t.GetString("pcbActivatedButton",this.pcbActivatedButton),this.pcbLinkMsaActivateButton=t.GetString("pcbLinkMsaActivateButton",this.pcbLinkMsaActivateButton),this.cbLearnMore=t.GetString("learnMoreLabel",this.cbLearnMore),this.cbLearnMoreFlyout=t.GetString("learnMoreLabel",this.cbLearnMoreFlyout),this.cbConfirmationTitle=t.GetString("rebatesThanksMessage",this.cbConfirmationTitle),this.pcbConfirmationMessage=t.GetString("pcbConfirmationMessage",this.pcbConfirmationMessage),this.instantcbConfirmationMessage=t.GetString("instantcbConfirmationMessage",this.instantcbConfirmationMessage),this.pcbConfirmationTitle=t.GetString("pcbConfirmationTitle",this.pcbConfirmationTitle),this.pcbBingRebates=t.GetString("pcbBingRebates",this.pcbBingRebates),this.instantcbBingRebates=t.GetString("instantcbBingRebates",this.instantcbBingRebates),this.cbAutoShowTitle=t.GetString("cbAutoShowTitle",this.cbAutoShowTitle),this.cbConfirmationMessage=t.GetString("rebatesProcessingMessage",this.cbConfirmationMessage),this.cbConfirmationEnrollBonusMessage=t.GetString("cbConfirmationEnrollBonusMessage",this.cbConfirmationEnrollBonusMessage),this.cbTurnedOffTitle=t.GetString("rebatesTurnedOffMessage",this.cbTurnedOffTitle),this.cbTurnedOffTitleMsftCashback=t.GetString("cbTurnedOffTitleMsftCashback",this.cbTurnedOffTitleMsftCashback),this.cbTurnedOffDescription=t.GetString("cbTurnedOffDescription",this.cbTurnedOffDescription),this.cbTurnedOffMessage=t.GetString("rebatesTurnedOffNextSteps",this.cbTurnedOffMessage),this.cbDontFindAutomatically=t.GetString("rebatesDontFindAutomatically",this.cbDontFindAutomatically),this.cbFindAutomatically=t.GetString("rebatesFindAutomatically",this.cbFindAutomatically),this.cbPreviousTransactions=t.GetString("rebatesSeeMore",this.cbPreviousTransactions),this.cbExclusiveBadgeText=t.GetString("cbExclusiveBadgeText",this.cbExclusiveBadgeText),this.cbIncentiveExclusiveBadgeText=t.GetString("cbIncentiveExclusiveBadgeText",this.cbIncentiveExclusiveBadgeText),this.reminderInfoButtonName=t.GetString("reminderInfoButtonName",this.reminderInfoButtonName),this.notificationPrivacyTitle=t.GetString("notificationPrivacyTitle",this.notificationPrivacyTitle),this.notificationPrivacyDesc=t.GetString("notificationPrivacyDesc",this.notificationPrivacyDesc),this.reminderDisabled=t.GetString("reminderDisabled",this.reminderDisabled),this.reminderEnabled=t.GetString("reminderEnabled",this.reminderEnabled),this.personalizedReminders=t.GetString("personalizedReminders",this.personalizedReminders),this.crossSiteTrackingIsEnabled=t.GetString("crossSiteTrackingIsEnabled",this.crossSiteTrackingIsEnabled),this.safariPrivacySettingsManage=t.GetString("safariPrivacySettingsManage",this.safariPrivacySettingsManage),this.safariPrivacy=t.GetString("safariPrivacy",this.safariPrivacy),this.cbRebatesOn=t.GetString("rebatesOnAndPercent",this.cbRebatesOn),this.cbRebatesOff=t.GetString("rebatesOffAndPercent",this.cbRebatesOff),this.myCashback=t.GetString("myCashback",this.myCashback),this.lifetimeearned=t.GetString("lifetimeearned",this.lifetimeearned),this.cbNonStackableCoupon=t.GetString("rebatesNonStackable",this.cbNonStackableCoupon),this.cbProcessing=t.GetString("rebatesProcessing",this.cbProcessing),this.commonMicrosoftRewards=t.GetString("cbPrivacyMessageLearn",this.commonMicrosoftRewards),this.cbPrivacyMessage=t.GetString("rebatesPrivacyMessage",this.cbPrivacyMessage),this.cbEnrollPrivacyMessage=t.GetString("cbEnrollPrivacyMessage",this.cbEnrollPrivacyMessage),this.cbPrivacyMessageTerm=t.GetString("cbPrivacyMessageTerm",this.cbPrivacyMessageTerm),this.cbPrivacyMessagePrivacyCookies=t.GetString("cbPrivacyMessagePrivacyCookies",this.cbPrivacyMessagePrivacyCookies),this.cbPrivacyMessageBeforeRewardsLink=t.GetString("cbPrivacyMessageBeforeRewardsLink",this.cbPrivacyMessageBeforeRewardsLink),this.cbPrivacyMessageAfterRewardsLink=t.GetString("cbPrivacyMessageAfterRewardsLink",this.cbPrivacyMessageAfterRewardsLink),this.cbPrivacyMessageAfterTerm=t.GetString("cbPrivacyMessageAfterTerm",this.cbPrivacyMessageAfterTerm),this.commonGotIt=t.GetString("rebatesGotIt",this.commonGotIt),this.cbErrorMessage=t.GetString("rebatesErrorMessage",this.cbErrorMessage),this.cbFetchUserProfileErrorMessage=t.GetString("cbFetchUserProfileErrorMessage",this.cbFetchUserProfileErrorMessage),this.cbFailedRetry=t.GetString("cbFailedRetry",this.cbFailedRetry),this.cbPromotionsOnSubHeader=t.GetString("cbPromotionsOnSubHeader",this.cbPromotionsOnSubHeader),this.cbBingActivateButton=t.GetString("cbBingActivateButton",this.cbBingActivateButton),this.cbBingJoinAndActivate=t.GetString("cbBingJoinAndActivate",this.cbBingJoinAndActivate),this.cbCashbackButtonActivated=t.GetString("cbCashbackActivatedButton",this.cbCashbackButtonActivated),this.cbBingActivateButtonDelayedEnrollment=t.GetString("cbBingActivateButtonDelayedEnrollment",this.cbBingActivateButtonDelayedEnrollment),this.cbRetailerTitle=t.GetString("cbRetailerTitle",this.cbRetailerTitle),this.cbSnapshotTitle=t.GetString("snapshotTitle",this.cbSnapshotTitle),this.cbViewAccount=t.GetString("viewAccount",this.cbViewAccount),this.cbCurrBalance=t.GetString("currBalance",this.cbCurrBalance),this.cbFeatureName=t.GetString("cbFeatureName",this.cbFeatureName),this.cbLearnMoreNew=t.GetString("cbLearnMoreNew",this.cbLearnMoreNew),this.cbReceiveCashBackTitle=t.GetString(Xt.CbReceiveCashBackTitle,this.cbReceiveCashBackTitle),this.cbDelayedCashBackSigninAnytimeMessage=t.GetString("cbDelayedCashBackSigninAnytimeMessage",this.cbDelayedCashBackSigninAnytimeMessage),this.cbOfferDetailsButtonTitle=t.GetString("cbOfferDetailsButtonTitle",this.cbOfferDetailsButtonTitle),this.cbOfferSeeLessButtonTitle=t.GetString("cbOfferSeeLessButtonTitle",this.cbOfferSeeLessButtonTitle),this.pcbExpirationText=t.GetString("pcbExpirationText",this.pcbExpirationText),this.cashbackExclusionsTitle=t.GetString("Exclusions",this.cashbackExclusionsTitle),this.cashbackExclusionsText=t.GetString("StorewideCashbackExlusionText",this.cashbackExclusionsText),this.commonMicrosoftCashback=t.GetString("commonMicrosoftCashback",this.commonMicrosoftCashback),this.EnrollSuccessTitle=t.GetString("EnrollSuccessTitle",this.EnrollSuccessTitle),this.cbConfirmationEnrollBonusSuccessMessage=t.GetString("cbConfirmationEnrollBonusSuccessMessage",this.cbConfirmationEnrollBonusSuccessMessage),this.cbEnrollBonusButtonText=t.GetString("cbEnrollBonusButtonText",this.cbEnrollBonusButtonText),this.couponAutoApplyWithoutCB=t.GetString("rebatesApplyCoupons",this.couponAutoApplyWithoutCB),this.bannerFoundBestPrice=t.GetString("bannerPriceComparisonHeading",this.bannerFoundBestPrice),this.bannerFoundBestPriceAlt=t.GetString("bannerFoundBestPriceAlt",this.bannerFoundBestPriceAlt),this.bannerYouHaveBestPrice=t.GetString("bannerYouHaveBestPrice",this.bannerYouHaveBestPrice),this.bannerSubTitleFlyout=t.GetString("rebatesCouponsDescriptions",this.bannerSubTitleFlyout),this.bannerSeeDetails=t.GetString("bannerSeeDetails",this.bannerSeeDetails),this.bannerViewAll=t.GetString("bannerOpenFlyoutLabel",this.bannerViewAll),this.bannerVisitItem=t.GetString("bannerPriceComparisonHover",this.bannerVisitItem),this.bannerPriceStableTitle=t.GetString("bannerPriceStableTitle",this.bannerPriceStableTitle),this.bannerViewAllCouponsStr=t.GetString("bannerViewAllCouponsStr",this.bannerViewAllCouponsStr),this.defaultClippingTitle=t.GetString("defaultClippingTitle",this.defaultClippingTitle),this.clippingMainTitle=t.GetString("clippingMainTitle",this.clippingMainTitle),this.clippingMainTitleForSafari=t.GetString("clippingMainTitleForSafari",this.clippingMainTitleForSafari),this.clippingMainTitleUpTo=t.GetString("clippingMainTitleUpTo",this.clippingMainTitleUpTo),this.clippingMainTitleSmallNotification=t.GetString("clippingMainTitleSmallNotification",this.clippingMainTitleSmallNotification),this.clippingMainTitleSmallNotificationUpTo=t.GetString("clippingMainTitleSmallNotificationUpTo",this.clippingMainTitleSmallNotificationUpTo),this.autoClipSubTitle=t.GetString("autoClipSubTitle",this.autoClipSubTitle),this.autoClipSafariSubTitle=t.GetString("autoClipSafariSubTitle",this.autoClipSafariSubTitle),this.autoClipButtonTitle=t.GetString("autoClipButtonTitle",this.autoClipButtonTitle),this.clippedTitle=t.GetString("clippedTitle",this.clippedTitle),this.clippedTitleUpTo=t.GetString("clippedTitleUpTo",this.clippedTitleUpTo),this.conditionsMayApplySubTitle=t.GetString("conditionsMayApplySubTitle",this.conditionsMayApplySubTitle),this.clippedSubTitle=t.GetString("clippedSubTitle",this.clippedSubTitle),this.clippingMainTitleEnGb=t.GetString("clippingMainTitleEnGb",this.clippingMainTitleEnGb),this.clippingMainTitleEnGbUpTo=t.GetString("clippingMainTitleEnGbUpTo",this.clippingMainTitleEnGbUpTo),this.defaultClippingTitleEnGb=t.GetString("defaultClippingTitleEnGb",this.defaultClippingTitleEnGb),this.clippedSubTitleEnGb=t.GetString("clippedSubTitleEnGb",this.clippedSubTitleEnGb),this.clippingFeatureName=t.GetString("clippingFeatureName",this.clippingFeatureName),this.clippingMainTitleV2=t.GetString("clippingMainTitleV2",this.clippingMainTitleV2),this.autoClipButtonTitleV2=t.GetString("autoClipButtonTitleV2",this.autoClipButtonTitleV2),this.clippedSubTitleV2=t.GetString("clippedSubTitleV2",this.clippedSubTitleV2),this.defaultClippedSubTitleV2=t.GetString("defaultClippedSubTitleV2",this.defaultClippedSubTitleV2),this.clippingSubTitleSmallNotification=t.GetString("clippingSubTitleSmallNotification",this.clippingSubTitleSmallNotification),this.clippingSubTitleUpTo=t.GetString("clippingSubTitleUpTo",this.clippingSubTitleUpTo),this.clippedCompletedTitle=t.GetString("clippedCompletedTitle",this.clippedCompletedTitle),this.clippedCompletedTitleUpTo=t.GetString("clippedCompletedTitleUpTo",this.clippedCompletedTitleUpTo),this.clippedCompletedSubTitle=t.GetString("clippedCompletedSubTitle",this.clippedCompletedSubTitle),this.clippedCompletedSubTitleEnGb=t.GetString("clippedCompletedSubTitleEnGb",this.clippedCompletedSubTitleEnGb),this.getDeal=t.GetString("getDeal",this.getDeal),this.dealsTitle=t.GetString("dealsTitle",this.dealsTitle),this.dealsSubTitle=t.GetString("dealsSubTitle",this.dealsSubTitle),this.dealsFeatureName=t.GetString("dealsFeatureName",this.dealsFeatureName),this.dontShowFeatureName=t.GetString("dontShowFeatureName",this.dontShowFeatureName),this.dontShowFeatureNameForSite=t.GetString("dontShowFeatureNameForSite",this.dontShowFeatureNameForSite),this.phTitlePriceDropped=t.GetString("phTitlePriceDropped",this.phTitlePriceDropped),this.phTitlePriceIncrease=t.GetString("phTitlePriceIncrease",this.phTitlePriceIncrease),this.phTitleStable=t.GetString("phTitleStable",this.phTitleStable),this.phToday=t.GetString("phToday",this.phToday),this.phLow=t.GetString("phLow",this.phLow),this.phHigh=t.GetString("phHigh",this.phHigh),this.phMedian=t.GetString("phMedian",this.phMedian),this.newPhLow=t.GetString("newPhLow",this.newPhLow),this.newPhHigh=t.GetString("newPhHigh",this.newPhHigh),this.newPhMedian=t.GetString("newPhMedian",this.newPhMedian),this.phPriceStable=t.GetString("phPriceStable",this.phPriceStable),this.phPriceDrop=t.GetString("phPriceDrop",this.phPriceDrop),this.phPriceDropZero=t.GetString("phPriceDropZero",this.phPriceDropZero),this.phPriceUpZero=t.GetString("phPriceUpZero",this.phPriceUpZero),this.phPriceDropped=t.GetString("phPriceDropped",this.phPriceDropped),this.phSee=t.GetString("phSee",this.phSee),this.phSeeTrend=t.GetString("phSeeTrend",this.phSeeTrend),this.prodHPriceDropTitle=t.GetString("prodHPriceDropTitle",this.prodHPriceDropTitle),this.prodHPriceDropDonotRemindMe=t.GetString("prodHPriceDropDonotRemindMe",this.prodHPriceDropDonotRemindMe),this.prodHPriceDropViewAt=t.GetString("prodHPriceDropViewAt",this.prodHPriceDropViewAt),this.prodHAnnotation=t.GetString("prodHAnnotation",this.prodHAnnotation),this.prodHDeleteItem=t.GetString("prodHDeleteItem",this.prodHDeleteItem),this.phPriceIncrease=t.GetString("phPriceIncrease",this.phPriceIncrease),this.phPriceUp=t.GetString("phPriceUp",this.phPriceUp),this.phFinalDrop=t.GetString("phFinalDrop",this.phFinalDrop),this.phFinalIncrease=t.GetString("phFinalIncrease",this.phFinalIncrease),this.phPriceStableRefresh=t.GetString("phPriceStableRefresh",this.phPriceStableRefresh),this.phGraphLabel=t.GetString("phGraphLabel",this.phGraphLabel),this.phStableLabel=t.GetString("phStableLabel",this.phStableLabel),this.phStableSummary=t.GetString("phStableSummary",this.phStableSummary),this.phOldPrice=t.GetString("phOldPrice",this.phOldPrice),this.phNewPrice=t.GetString("phNewPrice",this.phNewPrice),this.phTooltipText=t.GetString("phTooltipText",this.phTooltipText),this.phTooltipTextAvg=t.GetString("phTooltipTextAvg",this.phTooltipTextAvg),this.phFeatureName=t.GetString("phFeatureName",this.phFeatureName),this.phSectionTitle=t.GetString("phSectionTitle",this.phSectionTitle),this.pcSectionTitle=t.GetString("pcSectionTitle",this.pcSectionTitle),this.pcBetterPriceFound=t.GetString("pcBetterPriceFound",this.pcBetterPriceFound),this.pcSeeAllOffers=t.GetString("pcSeeAllOffers",this.pcSeeAllOffers),this.phNewPriceStable=t.GetString("phNewPriceStable",this.phNewPriceStable),this.phNewPriceLower=t.GetString("phNewPriceLower",this.phNewPriceLower),this.phNewPriceHigher=t.GetString("phNewPriceHigher",this.phNewPriceHigher),this.phNewChartLabel=t.GetString("phNewChartLabel",this.phNewChartLabel),this.phNewChartNoMedianLabel=t.GetString("phNewChartNoMedianLabel",this.phNewChartNoMedianLabel),this.phNewHighestPriceLabel=t.GetString("phNewHighestPriceLabel",this.phNewHighestPriceLabel),this.phNewLowestPriceLabel=t.GetString("phNewLowestPriceLabel",this.phNewLowestPriceLabel),this.phNewMedianPriceLabel=t.GetString("phNewMedianPriceLabel",this.phNewMedianPriceLabel),this.phNewTodayPrice=t.GetString("phNewTodayPrice",this.phNewTodayPrice),this.phNewSelectedPrice=t.GetString("phNewSelectedPrice",this.phNewSelectedPrice),this.phRecentPriceDrop=t.GetString("phRecentPriceDrop",this.phRecentPriceDrop),this.phRecentPriceIncrease=t.GetString("phRecentPriceIncrease",this.phRecentPriceIncrease),this.phLowerPriceThanUsual=t.GetString("phLowerPriceThanUsual",this.phLowerPriceThanUsual),this.phHigherPriceThanusual=t.GetString("phHigherPriceThanusual",this.phHigherPriceThanusual),this.phLowerThanUsual=t.GetString("phLowerThanUsual",this.phLowerThanUsual),this.phHigherThanUsual=t.GetString("phHigherThanUsual",this.phHigherThanUsual),this.price_is_stable=t.GetString("price_is_stable",this.price_is_stable),this.lowestprice_in_x_month=t.GetString("lowestprice_in_x_month",this.lowestprice_in_x_month),this.lowestprice_in_x_months=t.GetString("lowestprice_in_x_months",this.lowestprice_in_x_months),this.highestprice_in_x_month=t.GetString("highestprice_in_x_month",this.highestprice_in_x_month),this.highestprice_in_x_months=t.GetString("highestprice_in_x_months",this.highestprice_in_x_months),this.secondlowestprice_in_x_month=t.GetString("secondlowestprice_in_x_month",this.secondlowestprice_in_x_month),this.secondlowestprice_in_x_months=t.GetString("secondlowestprice_in_x_months",this.secondlowestprice_in_x_months),this.x_percent_price_increase_from_usual=t.GetString("x_percent_price_increase_from_usual",this.x_percent_price_increase_from_usual),this.x_percent_price_drop_from_usual=t.GetString("x_percent_price_drop_from_usual",this.x_percent_price_drop_from_usual),this.recent_x_percent_price_increase=t.GetString("recent_x_percent_price_increase",this.recent_x_percent_price_increase),this.recent_x_percent_price_drop=t.GetString("recent_x_percent_price_drop",this.recent_x_percent_price_drop),this.x_users_addedtocart_inlast_y_month=t.GetString("x_users_addedtocart_inlast_y_month",this.x_users_addedtocart_inlast_y_month),this.x_users_purchased_inlast_y_month=t.GetString("x_users_purchased_inlast_y_month",this.x_users_purchased_inlast_y_month),this.x_users_viewed_inlast_y_month=t.GetString("x_users_viewed_inlast_y_month",this.x_users_viewed_inlast_y_month),this.x_users_addedtocart_inlast_y_days=t.GetString("x_users_addedtocart_inlast_y_days",this.x_users_addedtocart_inlast_y_days),this.x_users_purchased_inlast_y_days=t.GetString("x_users_purchased_inlast_y_days",this.x_users_purchased_inlast_y_days),this.x_users_viewed_inlast_y_days=t.GetString("x_users_viewed_inlast_y_days",this.x_users_viewed_inlast_y_days),this.x_users_addedtocart_inlast_y_day=t.GetString("x_users_addedtocart_inlast_y_day",this.x_users_addedtocart_inlast_y_day),this.x_users_purchased_inlast_y_day=t.GetString("x_users_purchased_inlast_y_day",this.x_users_purchased_inlast_y_day),this.x_users_viewed_inlast_y_day=t.GetString("x_users_viewed_inlast_y_day",this.x_users_viewed_inlast_y_day),this.addedtocart_x_days_ago=t.GetString("addedtocart_x_days_ago",this.addedtocart_x_days_ago),this.purchased_x_days_ago=t.GetString("purchased_x_days_ago",this.purchased_x_days_ago),this.viewed_x_days_ago=t.GetString("viewed_x_days_ago",this.viewed_x_days_ago),this.addedtocart_x_day_ago=t.GetString("addedtocart_x_day_ago",this.addedtocart_x_day_ago),this.purchased_x_day_ago=t.GetString("purchased_x_day_ago",this.purchased_x_day_ago),this.viewed_x_day_ago=t.GetString("viewed_x_day_ago",this.viewed_x_day_ago),this.addedtocart_x_hours_ago=t.GetString("addedtocart_x_hours_ago",this.addedtocart_x_hours_ago),this.purchased_x_hours_ago=t.GetString("purchased_x_hours_ago",this.purchased_x_hours_ago),this.viewed_x_hours_ago=t.GetString("viewed_x_hours_ago",this.viewed_x_hours_ago),this.addedtocart_x_hour_ago=t.GetString("addedtocart_x_hour_ago",this.addedtocart_x_hour_ago),this.purchased_x_hour_ago=t.GetString("purchased_x_hour_ago",this.purchased_x_hour_ago),this.viewed_x_hour_ago=t.GetString("viewed_x_hour_ago",this.viewed_x_hour_ago),this.addedtocart_x_minutes_ago=t.GetString("addedtocart_x_minutes_ago",this.addedtocart_x_minutes_ago),this.purchased_x_minutes_ago=t.GetString("purchased_x_minutes_ago",this.purchased_x_minutes_ago),this.viewed_x_minutes_ago=t.GetString("viewed_x_minutes_ago",this.viewed_x_minutes_ago),this.addedtocart_x_minute_ago=t.GetString("addedtocart_x_minute_ago",this.addedtocart_x_minute_ago),this.purchased_x_minute_ago=t.GetString("purchased_x_minute_ago",this.purchased_x_minute_ago),this.viewed_x_minute_ago=t.GetString("viewed_x_minute_ago",this.viewed_x_minute_ago),this.addedtocart_x_seconds_ago=t.GetString("addedtocart_x_seconds_ago",this.addedtocart_x_seconds_ago),this.purchased_x_seconds_ago=t.GetString("purchased_x_seconds_ago",this.purchased_x_seconds_ago),this.viewed_x_seconds_ago=t.GetString("viewed_x_seconds_ago",this.viewed_x_seconds_ago),this.prodHPriceDropRefresh=t.GetString("prodHPriceDropRefresh",this.prodHPriceDropRefresh),this.prodHPriceIncreaseRefresh=t.GetString("prodHPriceIncreaseRefresh",this.prodHPriceIncreaseRefresh),this.prodHSectionTitle=t.GetString("prodHSectionTitle",this.prodHSectionTitle),this.rrExpertAndVideoReviews=t.GetString("rrExpertAndVideoReviews",this.rrExpertAndVideoReviews),this.rrExpertReviews=t.GetString("rrExpertReviews",this.rrExpertReviews),this.rrVideoReviews=t.GetString("rrVideoReviews",this.rrVideoReviews),this.rrFeatureName=t.GetString("rrFeatureName",this.rrFeatureName),this.userInsightsSectionTitle=t.GetString("userInsightsSectionTitle",this.userInsightsSectionTitle),this.userInsightsPositiveSection=t.GetString("userInsightsPositiveSection",this.userInsightsPositiveSection),this.userInsightsNegativeSection=t.GetString("userInsightsNegativeSection",this.userInsightsNegativeSection),this.expertInsightsSectionTitle=t.GetString("expertInsightsSectionTitle",this.expertInsightsSectionTitle),this.expertInsightsRecommend=t.GetString("expertInsightsRecommend",this.expertInsightsRecommend),this.expertInsightsDontRecommend=t.GetString("expertInsightsDontRecommend",this.expertInsightsDontRecommend),this.expertInsightsRecommendationScore=t.GetString("expertInsightsRecommendationScore",this.expertInsightsRecommendationScore),this.checkoutCreditOrDebitCardDropDown=t.GetString("checkoutCreditOrDebitCardDropDown",this.checkoutCreditOrDebitCardDropDown),this.checkoutShippingAddress=t.GetString("checkoutShippingAddress",this.checkoutShippingAddress),this.checkoutPaymentInfo=t.GetString("checkoutPaymentInfo",this.checkoutPaymentInfo),this.checkoutSameBilling=t.GetString("checkoutSameBilling",this.checkoutSameBilling),this.checkoutFillOnly=t.GetString("checkoutFillOnly",this.checkoutFillOnly),this.checkoutButtonWithoutAA=t.GetString("checkoutButtonWithoutAA",this.checkoutButtonWithoutAA),this.checkoutButtonWithoutAAForOtherPayment=t.GetString("checkoutButtonWithoutAAForOtherPayment",this.checkoutButtonWithoutAAForOtherPayment),this.checkoutSectionTitle=t.GetString("checkoutSectionTitle",this.checkoutSectionTitle),this.checkoutAddressSectionTitle=t.GetString("checkoutAddressSectionTitle",this.checkoutAddressSectionTitle),this.checkoutPaymentSectionTitle=t.GetString("checkoutPaymentSectionTitle",this.checkoutPaymentSectionTitle),this.checkoutValidTill=t.GetString("checkoutValidTill",this.checkoutValidTill),this.checkoutZip=t.GetString("checkoutZip",this.checkoutZip),this.checkoutFeatureName=t.GetString("checkoutFeatureName",this.checkoutFeatureName),this.paymentOptionLabel=t.GetString("paymentOptionLabel",this.paymentOptionLabel),this.microsoftWalletLinkText=t.GetString("microsoftWalletLinkText",this.microsoftWalletLinkText),this.virtualCardCardHolderNameHeader=t.GetString("virtualCardCardHolderNameHeader",this.virtualCardCardHolderNameHeader),this.virtualCardBillingAddressHeader=t.GetString("virtualCardBillingAddressHeader",this.virtualCardBillingAddressHeader),this.virtualCardBillingInfoHeader=t.GetString("virtualCardBillingInfoHeader",this.virtualCardBillingInfoHeader),this.virtualCardNumberHeader=t.GetString("virtualCardNumberHeader",this.virtualCardNumberHeader),this.virtualCardExpirationHeader=t.GetString("virtualCardExpirationHeader",this.virtualCardExpirationHeader),this.virtualCardCVCHeader=t.GetString("virtualCardCVCHeader",this.virtualCardCVCHeader),this.visualizedCardHolderHeader=t.GetString("visualizedCardHolderHeader",this.visualizedCardHolderHeader),this.visualizedCardExpiresHeader=t.GetString("visualizedCardExpiresHeader",this.visualizedCardExpiresHeader),this.showContentToggleTooltipCardNumber=t.GetString("showContentToggleTooltipCardNumber",this.showContentToggleTooltipCardNumber),this.showContentToggleTooltipCVC=t.GetString("showContentToggleTooltipCVC",this.showContentToggleTooltipCVC),this.hideContentToggleTooltipCardNumber=t.GetString("hideContentToggleTooltipCardNumber",this.hideContentToggleTooltipCardNumber),this.hideContentToggleTooltipCVC=t.GetString("hideContentToggleTooltipCVC",this.hideContentToggleTooltipCVC),this.copyButtonTooltip=t.GetString("copyButtonTooltip",this.copyButtonTooltip),this.virtualCardSystemFailureHeader=t.GetString("virtualCardSystemFailureHeader",this.virtualCardSystemFailureHeader),this.virtualCardLinkSuccess=t.GetString("virtualCardLinkSuccess",this.virtualCardLinkSuccess),this.buyNowPayLater=t.GetString("billNowPayLater",this.buyNowPayLater),this.masterCardPayment=t.GetString("masterCardPayment",this.masterCardPayment),this.visaPayment=t.GetString("visaPayment",this.visaPayment),this.amexPayment=t.GetString("amexPayment",this.amexPayment),this.discoverPayment=t.GetString("discoverPayment",this.discoverPayment),this.couponExpandableTitleViewCoupons=t.GetString("couponExpandableTitleViewCoupons",this.couponExpandableTitleViewCoupons),this.couponExpandableTitleWithNumStr=t.GetString("couponExpandableTitleWithNumStr",this.couponExpandableTitleWithNumStr),this.socialCouponShop=t.GetString("socialCouponShop",this.socialCouponShop),this.pdpApplyCoupons=t.GetString("pdpApplyCoupons",this.pdpApplyCoupons),this.pdpApplyBestCoupon=t.GetString("pdpApplyBestCoupon",this.pdpApplyBestCoupon),this.productBestCouponFeatureName=t.GetString("productBestCouponFeatureName",this.productBestCouponFeatureName),this.bestCouponAriaLabel=t.GetString("bestCouponAriaLabel",this.bestCouponAriaLabel),this.bestCouponCopiedAriaLabel=t.GetString("bestCouponCopiedAriaLabel",this.bestCouponCopiedAriaLabel),this.savePDPTitle=t.GetString("savePDPTitle",this.savePDPTitle),this.savePDPTitleNoTrivia=t.GetString("savePDPTitleNoTrivia",this.savePDPTitleNoTrivia),this.bgaaFeatureName=t.GetString("bgaaFeatureName",this.bgaaFeatureName),this.bgaaSuccessLeftTitle=t.GetString("bgaaSuccessLeftTitle",this.bgaaSuccessLeftTitle),this.bgaaSuccessRightTitle=t.GetString("bgaaSuccessRightTitle",this.bgaaSuccessRightTitle),this.bgaaSuccessRightText=t.GetString("bgaaSuccessRightText",this.bgaaSuccessRightText),this.bgaaFailedTitle=t.GetString("bgaaFailedTitle",this.bgaaFailedTitle),this.bgaaFailedLeftTitle=t.GetString("bgaaFailedLeftTitle",this.bgaaFailedLeftTitle),this.bgaaFailedLeftText=t.GetString("bgaaFailedLeftText",this.bgaaFailedLeftText),this.bgaaFailedRightTitle=t.GetString("bgaaFailedRightTitle",this.bgaaFailedRightTitle),this.bgaaFailedRightText=t.GetString("bgaaFailedRightText",this.bgaaFailedRightText),this.bgaaModuleMessage=t.GetString("bgaaModuleMessage",this.bgaaModuleMessage),this.bgaaModuleCouponCountMessage=t.GetString("bgaaModuleCouponCountMessage",this.bgaaModuleCouponCountMessage),this.bgaaModuleApplyCoupon=t.GetString("bgaaModuleApplyCoupon",this.bgaaModuleApplyCoupon),this.disablePackageTrackingFromMenuText=t.GetString("disablePackageTrackingFromMenuText",this.disablePackageTrackingFromMenuText),this.enablePackageTrackingFromMenuText=t.GetString("enablePackageTrackingFromMenuText",this.enablePackageTrackingFromMenuText),this.packageTrackingOptInButtonText=t.GetString("packageTrackingOptInButtonText",this.packageTrackingOptInButtonText),this.packageTrackingNewOptInButtonText=t.GetString("packageTrackingNewOptInButtonText",this.packageTrackingNewOptInButtonText),this.packageTrackingNotificationTitle=t.GetString("packageTrackingNotificationTitle",this.packageTrackingNotificationTitle),this.packageTrackingNewNotificationTitle=t.GetString("packageTrackingNewNotificationTitle",this.packageTrackingNewNotificationTitle),this.packageTrackingNotificationDescription=t.GetString("packageTrackingNotificationDescription",this.packageTrackingNotificationDescription),this.packageTrackingFeatureName=t.GetString("packageTrackingFeatureName",this.packageTrackingFeatureName),this.packageTrackingOrderPlaced=t.GetString("packageTrackingOrderPlaced",this.packageTrackingOrderPlaced),this.packageTrackingDisabledHeading=t.GetString("packageTrackingDisabledHeading",this.packageTrackingDisabledHeading),this.postPurchaseTrackingFeatureName=t.GetString("postPurchaseTrackingFeatureName",this.postPurchaseTrackingFeatureName),this.searchBoxPCBFeatureName=t.GetString("searchBoxPCBFeatureName",this.searchBoxPCBFeatureName),this.postPurchaseTrackingNotificationTitle=t.GetString("postPurchaseTrackingNotificationTitle",this.postPurchaseTrackingNotificationTitle),this.postPurchaseTrackingNotificationSubtitle=t.GetString("postPurchaseTrackingNotificationSubtitle",this.postPurchaseTrackingNotificationSubtitle),this.postPurchaseTrackingNotificationCTA=t.GetString("postPurchaseTrackingNotificationCTA",this.postPurchaseTrackingNotificationCTA),this.postPurchaseTrackingDisabledHeading=t.GetString("postPurchaseTrackingDisabledHeading",this.postPurchaseTrackingDisabledHeading),this.postPurchaseTrackingOptInButtonText=t.GetString("postPurchaseTrackingOptInButtonText",this.postPurchaseTrackingOptInButtonText),this.postPurchaseTrackingEnabledHeading=t.GetString("postPurchaseTrackingEnabledHeading",this.postPurchaseTrackingEnabledHeading),this.postPurchaseTrackingEnabledSubtitle=t.GetString("postPurchaseTrackingEnabledSubtitle",this.postPurchaseTrackingEnabledSubtitle),this.postPurchaseTrackingPriceMatchCTA=t.GetString("postPurchaseTrackingPriceMatchCTA",this.postPurchaseTrackingPriceMatchCTA),this.priceMatchPriceDropText=t.GetString("priceMatchPriceDropText",this.priceMatchPriceDropText),this.priceMatchRemainingDaysText=t.GetString("priceMatchRemainingDaysText",this.priceMatchRemainingDaysText),this.priceMatchSettingsText=t.GetString("priceMatchSettingsText",this.priceMatchSettingsText),this.priceMatchViewText=t.GetString("priceMatchViewText",this.priceMatchViewText),this.priceMatchNotificationTitle=t.GetString("priceMatchNotificationTitle",this.priceMatchNotificationTitle),this.popsUpTooFrequently=t.GetString("popsUpTooFrequently",this.popsUpTooFrequently),this.couponsDoNotWork=t.GetString("couponsDoNotWork",this.couponsDoNotWork),this.indexDoesNotWork=t.GetString("indexDoesNotWork",this.indexDoesNotWork),this.incorrectProductInformation=t.GetString("incorrectProductInformation",this.incorrectProductInformation),this.untrustworthyWebsite=t.GetString("untrustworthyWebsite",this.untrustworthyWebsite),this.other=t.GetString("other",this.other),this.checkBackForOrders=t.GetString("checkBackForOrders",this.checkBackForOrders),this.deteTrackerText=t.GetString("deteTrackerText",this.deteTrackerText),this.packageTrackingOptOutButtonText=t.GetString("packageTrackingOptOutButtonText",this.packageTrackingOptOutButtonText),this.productDetailsOrderTracking=t.GetString("productDetailsOrderTracking",this.productDetailsOrderTracking),this.packageTrackingDeactivatedTitle=t.GetString("packageTrackingDeactivatedTitle",this.packageTrackingDeactivatedTitle),this.packageTrackingActivatedTitle=t.GetString("packageTrackingActivatedTitle",this.packageTrackingActivatedTitle),this.packageTrackingOptInAcknowledgement=t.GetString("packageTrackingOptInAcknowledgement",this.packageTrackingOptInAcknowledgement),this.packageTrackingOptInAcknowledgementFailure=t.GetString("packageTrackingOptInAcknowledgementFailure",this.packageTrackingOptInAcknowledgementFailure),this.packageTrackingOptOutAcknowledgement=t.GetString("packageTrackingOptOutAcknowledgement",this.packageTrackingOptOutAcknowledgement),this.packageTrackingOptOutAcknowledgementFailure=t.GetString("packageTrackingOptOutAcknowledgementFailure",this.packageTrackingOptOutAcknowledgementFailure),this.rewardsTermsText=t.GetString("rewardsTermsText",this.rewardsTermsText),this.giftFeatureName=t.GetString("giftFeatureName",this.giftFeatureName),this.privacySettingsManage=t.GetString("privacySettingsManage",this.privacySettingsManage),this.cashbackSettingsText=t.GetString("cashbackSettingsText",this.cashbackSettingsText),this.personalizedRemindersSettingsText=t.GetString("personalizedRemindersSettingsText",this.personalizedRemindersSettingsText),this.packageTrackingSettingsText=t.GetString("packageTrackingSettingsText",this.packageTrackingSettingsText),this.edgeShoppingSettings=t.GetString("edgeShoppingSettings",this.edgeShoppingSettings),this.feedbackPrompt=t.GetString("feedbackPrompt",this.feedbackPrompt),this.bnplFeedbackPrompt=t.GetString("bnplFeedbackPrompt",this.bnplFeedbackPrompt),this.feedbackThanks=t.GetString("feedbackThanks",this.feedbackThanks),this.feedbackAriaLike=t.GetString("feedbackAriaLike",this.feedbackAriaLike),this.feedbackAriaDislike=t.GetString("feedbackAriaDislike",this.feedbackAriaDislike),this.feedbackAriaDislikeMenu=t.GetString("feedbackAriaDislikeMenu",this.feedbackAriaDislikeMenu),this.feedbackAriaClose=t.GetString("feedbackAriaClose",this.feedbackAriaClose),this.bingPrivacyMessage=t.GetString("bingPrivacyMessage",this.bingPrivacyMessage),this.infoIconLabel=t.GetString("infoIconLabel",this.infoIconLabel),this.sustainabilityDescriptionLight=t.GetString("sustainabilityDescriptionLight",this.sustainabilityDescriptionLight),this.sustainabilityDescription=t.GetString("sustainabilityDescription",this.sustainabilityDescription),this.sustainabilityString=t.GetString("sustainabilityString",this.sustainabilityString),this.sustainabilityConfirmationTitle=t.GetString("sustainabilityConfirmationTitle",this.sustainabilityConfirmationTitle),this.sustainabilityFeatureName=t.GetString("sustainabilityFeatureName",this.sustainabilityFeatureName),this.attCouponHeaderLocked=t.GetString("attCouponHeaderLocked",this.attCouponHeaderLocked),this.attCouponHeaderUnlocked=t.GetString("attCouponHeaderUnlocked",this.attCouponHeaderUnlocked),this.spcbCashbackBalance=t.GetString("spcbCashbackBalance",this.spcbCashbackBalance),this.spcbJoinNow=t.GetString("spcbJoinNow",this.spcbJoinNow),this.spcbViewTopDeals=t.GetString("spcbViewTopDeals",this.spcbViewTopDeals),this.spcbTrackCashback=t.GetString("spcbTrackCashback",this.spcbTrackCashback),this.spcbRedeemNow=t.GetString("spcbRedeemNow",this.spcbRedeemNow),this.spcbCheckOffers=t.GetString("spcbCheckOffers",this.spcbCheckOffers),this.spcbViewAcct=t.GetString("spcbViewAcct",this.spcbViewAcct),this.spcbJoinNewUser=t.GetString("spcbJoinNewUser",this.spcbJoinNewUser),this.spcbPassiveUser=t.GetString("spcbPassiveUser",this.spcbPassiveUser),this.spcbUnknownValue=t.GetString("spcbUnknownValue",this.spcbUnknownValue),this.spcbKnownValue=t.GetString("spcbKnownValue",this.spcbKnownValue),this.spcbCashoutReady=t.GetString("spcbCashoutReady",this.spcbCashoutReady),this.spcbCashedOut=t.GetString("spcbCashedOut",this.spcbCashedOut),this.spcbEnrolledUserTitle=t.GetString("spcbEnrolledUserTitle",this.spcbEnrolledUserTitle),this.spcbEnrolledUserNoBalanceTitle=t.GetString("spcbEnrolledUserNoBalanceTitle",this.spcbEnrolledUserNoBalanceTitle),this.spcbEnrolledNoAmountUserTitle=t.GetString("spcbEnrolledNoAmountUserTitle",this.spcbEnrolledNoAmountUserTitle),this.spcbNotEnrolledUserTitle=t.GetString("spcbNotEnrolledUserTitle",this.spcbNotEnrolledUserTitle),this.scSectionTitle=t.GetString("scSectionTitle",this.scSectionTitle),this.scContainerTitle=t.GetString("scContainerTitle",this.scContainerTitle),this.scFilter=t.GetString("scFilter",this.scFilter),this.scAddOffer=t.GetString("scAddOffer",this.scAddOffer),this.scRemoveOffer=t.GetString("scRemoveOffer",this.scRemoveOffer),this.scShowFullSpec=t.GetString("scShowFullSpec",this.scShowFullSpec),this.scChevronLeftTitle=t.GetString("scChevronLeftTitle",this.scChevronLeftTitle),this.scChevronRightTitle=t.GetString("scChevronRightTitle",this.scChevronRightTitle),this.scSmartCompareNotificationText=t.GetString("scSmartCompareNotificationText",this.scSmartCompareNotificationText),this.scProductSummaryNotificationText=t.GetString("scProductSummaryNotificationText",this.scProductSummaryNotificationText),this.scFindMoreLikeThis=t.GetString("scFindMoreLikeThis",this.scFindMoreLikeThis),this.scCompareSimilarNonEn=t.GetString("scCompareSimilarNonEn",this.scCompareSimilarNonEn),this.scCompareSimilarEn=t.GetString("scCompareSimilarEn",this.scCompareSimilarEn),this.scFindBestProductNonEn=t.GetString("scFindBestProductNonEn",this.scFindBestProductNonEn),this.scFindBestProductEn=t.GetString("scFindBestProductEn",this.scFindBestProductEn),this.scGetMoreDetailsAboutProductNonEn=t.GetString("scGetMoreDetailsAboutProductNonEn",this.scGetMoreDetailsAboutProductNonEn),this.scGetMoreDetailsAboutProductEn=t.GetString("scGetMoreDetailsAboutProductEn",this.scGetMoreDetailsAboutProductEn),this.scFreeShipping=t.GetString("scFreeShipping",this.scFreeShipping),this.psPopularOpinions=t.GetString("psPopularOpinions",this.psPopularOpinions),this.psTopInsights=t.GetString("psTopInsights",this.psTopInsights),this.psSectionTitle=t.GetString("psSectionTitle",this.psSectionTitle),this.psReviewSummary=t.GetString("psReviewSummary",this.psReviewSummary),this.psPros=t.GetString("psTopInsights",this.psPros),this.psCons=t.GetString("psSectionTitle",this.psCons),this.psAiSummaryIndicator=t.GetString("psReviewSummary",this.psAiSummaryIndicator),this.bgSectionTitle=t.GetString("bgSectionTitle",this.bgSectionTitle),this.bgCardTitle=t.GetString("bgCardTitle",this.bgCardTitle),this.bgShowMore=t.GetString("bgCardTitle",this.bgShowMore),this.bgShowLess=t.GetString("bgCardTitle",this.bgShowLess),this.bgChevronTitle=t.GetString("bgChevronTitle",this.bgChevronTitle),this.discoverFeatureName=t.GetString("discoverFeatureName",this.discoverFeatureName),this.chatChipComparePrices=t.GetString("chatChipComparePrices",this.chatChipComparePrices),this.chatChipViewPriceHistory=t.GetString("chatChipViewPriceHistory",this.chatChipViewPriceHistory),this.chatChipFindSimilarProduct=t.GetString("chatChipFindSimilarProduct",this.chatChipFindSimilarProduct),this.chatChipCompareSimilarProduct=t.GetString("chatChipCompareSimilarProduct",this.chatChipCompareSimilarProduct),this.chatChipComparePrevious=t.GetString("chatChipComparePrevious",this.chatChipComparePrevious),this.chatChipViewBuyingGuide=t.GetString("chatChipViewBuyingGuide",this.chatChipViewBuyingGuide),this.chatChipGetInsights=t.GetString("chatChipGetInsights",this.chatChipGetInsights),this.chatChipGetReviewsSummary=t.GetString("chatChipGetReviewsSummary",this.chatChipGetReviewsSummary),this.chatChipProductCollection=t.GetString("chatChipProductCollection",this.chatChipProductCollection),this.chatNotificationButton=t.GetString("chatNotificationButton",this.chatNotificationButton),this.chatFeatureName=t.GetString("chatFeatureName",this.chatFeatureName),this.gcAnonFlowPendingModuleTitle=t.GetString("gcAnonFlowPendingModuleTitle",this.gcAnonFlowPendingModuleTitle),this.gcAnonFlowPendingTitle=t.GetString("gcAnonFlowPendingTitle",this.gcAnonFlowPendingTitle),this.gcAnonFlowPendingButton=t.GetString("gcAnonFlowPendingButton",this.gcAnonFlowPendingButton),this.microsoftRewards=t.GetString("microsoftRewards",this.microsoftRewards),this.terms=t.GetString("terms",this.terms),this.privacyAndCookies=t.GetString("privacyAndCookies",this.privacyAndCookies),this.gcDisclaimer=t.GetString("gcDisclaimer",this.gcDisclaimer),this.gcDisclaimerSignedIn=t.GetString("gcDisclaimerSignedIn",this.gcDisclaimerSignedIn),this.gcConfirmationTextSpb=t.GetString("gcConfirmationTextSpb",this.gcConfirmationTextSpb),this.gcSectionTitle=t.GetString("gcSectionTitle",this.gcSectionTitle),this.gcbSectionTitle=t.GetString("gcbSectionTitle",this.gcbSectionTitle),this.gcbSeeMore=t.GetString("gcbSeeMore",this.gcbSeeMore),this.gcbSearchSectionTitle=t.GetString("gcbSearchSectionTitle",this.gcbSearchSectionTitle),this.gcbSearchSectionOffTitle=t.GetString("gcbSearchSectionOffTitle",this.gcbSearchSectionOffTitle),this.gcbActivatedSectionTitle=t.GetString("gcbActivatedSectionTitle",this.gcbActivatedSectionTitle),this.gcbSignInText=t.GetString("gcbSignInText",this.gcbSignInText),this.gcbPdpHeaderText=t.GetString("gcbPdpHeaderText",this.gcbPdpHeaderText),this.gcbNotifPdpActivation=t.GetString("gcbNotifPdpActivation",this.gcbNotifPdpActivation),this.gcbNotifSubtitle=t.GetString("gcbNotifSubtitle",this.gcbNotifSubtitle),this.couponSectionPanePluralTitle=t.GetString("couponSectionPanePluralTitle",this.couponSectionPanePluralTitle),this.safariFREPrivacyStatement=t.GetString("safariFREPrivacyStatement",this.safariFREPrivacyStatement),this.safariFRESide1Title=t.GetString("safariFRESide1Title",this.safariFRESide1Title),this.safariFRESide1Description=t.GetString("safariFRESide1Description",this.safariFRESide1Description),this.safariFRESide2Title=t.GetString("safariFRESide2Title",this.safariFRESide2Title),this.safariFRESide2Description=t.GetString("safariFRESide2Description",this.safariFRESide2Description),this.safariFRESide3Title=t.GetString("safariFRESide3Title",this.safariFRESide3Title),this.safariFRESide3Description=t.GetString("safariFRESide3Description",this.safariFRESide3Description),this.safariFREResultsTitle=t.GetString("safariFREResultsTitle",this.safariFREResultsTitle),this.safariFREAllset=t.GetString("safariFREAllset",this.safariFREAllset),this.groceriesFeatureName=t.GetString("groceriesFeatureName",this.groceriesFeatureName),this.gcSpbSearchBarOffersNotFound=t.GetString("gcSpbSearchBarOffersNotFound",this.gcSpbSearchBarOffersNotFound),this.gcSearchBarPlaceholder=t.GetString("gcSearchBarPlaceholder",this.gcSearchBarPlaceholder),this.gcQuotientPrivacyPolicyLinkKey=t.GetString("gcQuotientPrivacyPolicyLinkKey",this.gcQuotientPrivacyPolicyLinkKey),this.gcPrivacyDisclaimerText=t.GetString("gcPrivacyDisclaimerText",this.gcPrivacyDisclaimerText),this.gcPrivacyTooltipButtonName=t.GetString("gcPrivacyTooltipButtonName",this.gcPrivacyTooltipButtonName),this.gcPrivacyTooltip=t.GetString("gcPrivacyTooltip",this.gcPrivacyTooltip),this.gcSponsoredTooltip=t.GetString("gcFreeAfterCashback",this.gcSponsoredTooltip),this.gcSponsoredTooltip2=t.GetString("gcFreeAfterCashback2",this.gcSponsoredTooltip2),this.gcSponsoredTooltipNoLink=t.GetString("gcFreeAfterCashbackNoLink",this.gcSponsoredTooltipNoLink),this.gcFindOutLinkText=t.GetString("gcFindOutLinkText",this.gcFindOutLinkText),this.gcViewActivatedDeal=t.GetString("gcViewActivatedDeal",this.gcViewActivatedDeal),this.gcCashbackApplied=t.GetString("gcCashbackApplied",this.gcCashbackApplied),this.gcPurchaseToEarn=t.GetString("gcPurchaseToEarn",this.gcPurchaseToEarn),this.gcAfterCashback=t.GetString("gcAfterCashback",this.gcAfterCashback),this.gcInstantAddedToCartActivated=t.GetString("gcInstantAddedToCartActivated",this.gcInstantAddedToCartActivated),this.gcActivateInstantAddToCart=t.GetString("gcActivateInstantAddToCart",this.gcActivateInstantAddToCart),this.gcEarnAfterCashback=t.GetString("gcEarnAfterCashback",this.gcEarnAfterCashback),this.gcWithAfterCashback=t.GetString("gcWithAfterCashback",this.gcWithAfterCashback),this.gcTopDeal=t.GetString("gcTopDeal",this.gcTopDeal),this.gcSimilarDeal=t.GetString("gcSimilarDeal",this.gcSimilarDeal),this.gcRelatedDeal=t.GetString("gcRelatedDeal",this.gcRelatedDeal),this.gcOff=t.GetString("gcOff",this.gcOff),this.gcGetDeal=t.GetString("gcGetDeal",this.gcGetDeal),this.gcListPrice=t.GetString("gcListPrice",this.gcListPrice),this.gcSalePrice=t.GetString("gcSalePrice",this.gcSalePrice),this.gcGet=t.GetString("gcGet",this.gcGet),this.gcGetCashBack=t.GetString("gcGetCashBack",this.gcGetCashBack),this.gcOkButtonText=t.GetString("gcOkButtonText",this.gcOkButtonText),this.gcGetDealOnRetailer=t.GetString("gcGetDealOnRetailer",this.gcGetDealOnRetailer),this.gcAfterCashBack=t.GetString("gcAfterCashBack",this.gcAfterCashBack),this.gcFinalPrice=t.GetString("gcFinalPrice",this.gcFinalPrice),this.gcEarning=t.GetString("gcEarning",this.gcEarning),this.gcRebatesEmailUpdate=t.GetString("gcRebatesEmailUpdate",this.gcRebatesEmailUpdate),this.gcRebatesClaimTime=t.GetString("gcRebatesClaimTime",this.gcRebatesClaimTime),this.gcTrackCashback=t.GetString("gcTrackCashback",this.gcTrackCashback),this.gcCashbackConfirmViaEmail=t.GetString("gcCashbackConfirmViaEmail",this.gcCashbackConfirmViaEmail),this.gcBlossomCongratsFirstPart=t.GetString("gcFirstPurchaseCongratsFirstPart",this.gcBlossomCongratsFirstPart),this.gcBlossomCongratsSecondPart=t.GetString("gcFirstPurchaseCongratsSecondPart",this.gcBlossomCongratsSecondPart),this.gcBlossomBonusFirstPart=t.GetString("gcBlossomBonusFirstPart",this.gcBlossomBonusFirstPart),this.gcBlossomBonusSecondPart=t.GetString("gcBlossomBonusSecondPart",this.gcBlossomBonusSecondPart),this.gcBlossomBonusThirdPart=t.GetString("gcBlossomBonusThirdPart",this.gcBlossomBonusThirdPart),this.gcSponsored=t.GetString("gcSponsored",this.gcSponsored),this.gcAdsSponsored=t.GetString("gcAdsSponsored",this.gcAdsSponsored),this.gcAdsSponsoredDisclaimer=t.GetString("gcAdsSponsoredDisclaimer",this.gcAdsSponsoredDisclaimer),this.gcAd=t.GetString("gcAd",this.gcAd),this.gcAdsHeader=t.GetString("gcAdsHeader",this.gcAdsHeader),this.gcSeeCashbackDeals=t.GetString("gcSeeCashbackDeals",this.gcSeeCashbackDeals),this.gcSpbHomePageText1=t.GetString("gcSpbHomePageText1",this.gcSpbHomePageText1),this.gcSpbHomePageText2=t.GetString("gcSpbHomePageText2",this.gcSpbHomePageText2),this.gcSpbHomePageTextDefault=t.GetString("gcSpbHomePageTextDefault",this.gcSpbHomePageTextDefault),this.gcFoundCashbackDeals=t.GetString("gcFoundCashbackDeals",this.gcFoundCashbackDeals),this.gcFoundCashbackDealsRelatedToSearch=t.GetString("gcFoundCashbackDealsRelatedToSearch",this.gcFoundCashbackDealsRelatedToSearch),this.gcSeeOtherDeals=t.GetString("gcSeeOtherDeals",this.gcSeeOtherDeals),this.gcJoinAndActivate=t.GetString("gcJoinAndActivate",this.gcJoinAndActivate),this.gcPrintCoupons=t.GetString("gcPrintCoupons",this.gcPrintCoupons),this.gcPrintNumberCoupon=t.GetString("gcPrintNumberCoupon",this.gcPrintNumberCoupon),this.gcPrintOneCoupon=t.GetString("gcPrintOneCoupon",this.gcPrintOneCoupon),this.gcDeactivatedButton=t.GetString("gcDeactivatedButton",this.gcDeactivatedButton),this.gcAfter=t.GetString("gcAfter",this.gcAfter),this.gcSave=t.GetString("gcSave",this.gcSave),this.gcBack=t.GetString("gcBack",this.gcBack),this.gcMicrosoftCashbackOffers=t.GetString("gcMicrosoftCashbackOffers",this.gcMicrosoftCashbackOffers),this.gcViewOffer=t.GetString("gcViewOffer",this.gcViewOffer),this.gcPurchaseBeforeTimer=t.GetString("gcPurchaseBeforeTimer",this.gcPurchaseBeforeTimer),this.gcEndsIn=t.GetString("gcEndsIn",this.gcEndsIn),this.gcTotalCashback=t.GetString("gcTotalCashback",this.gcTotalCashback),this.gcCategoryTotalCashback=t.GetString("gcCategoryTotalCashback",this.gcCategoryTotalCashback),this.gcbSeeActivatedButton=t.GetString("gcbSeeActivatedButton",this.gcbSeeActivatedButton),this.gcbSignInButton=t.GetString("gcbSignInButton",this.gcbSignInButton),this.gcDuplicateSubmissionError=t.GetString("gcDuplicateSubmissionError",this.gcDuplicateSubmissionError),this.gcError=t.GetString("gcError",this.gcError),this.priceDropPlusCouponsCompositeNotificationTitle=t.GetString("priceDropPlusCouponsCompositeNotificationTitle",this.priceDropPlusCouponsCompositeNotificationTitle),this.couponsComponentCompositeNotificationTitle=t.GetString("couponsComponentCompositeNotificationTitle",this.couponsComponentCompositeNotificationTitle),this.priceHistoryComponentCompositeNotificationTitle=t.GetString("priceHistoryComponentCompositeNotificationTitle",this.priceHistoryComponentCompositeNotificationTitle),this.cashbackPlusCouponsCompositeNotificationBtnText=t.GetString("cashbackPlusCouponsCompositeNotificationBtnText",this.cashbackPlusCouponsCompositeNotificationBtnText),this.estimatedCashbackComponentCompositeNotificationTitlePart1=t.GetString("estimatedCashbackComponentCompositeNotificationTitlePart1",this.estimatedCashbackComponentCompositeNotificationTitlePart1),this.cashbackPlusCouponsCompositeNotificationTitle=t.GetString("cashbackPlusCouponsCompositeNotificationTitle",this.cashbackPlusCouponsCompositeNotificationTitle),this.cashbackUpToComponentCompositeNotificationTitle=t.GetString("cashbackUpToComponentCompositeNotificationTitle",this.cashbackUpToComponentCompositeNotificationTitle),this.cashbackPlusCouponsFeatureName=t.GetString("cashbackPlusCouponsFeatureName",this.cashbackPlusCouponsFeatureName),this.cashbackPlusPriceDropFeatureName=t.GetString("cashbackPlusPriceDropFeatureName",this.cashbackPlusPriceDropFeatureName),this.pcPlusCashbackPlusCouponsFeatureName=t.GetString("pcPlusCashbackPlusCouponsFeatureName",this.pcPlusCashbackPlusCouponsFeatureName),this.couponsUpToXPercentOff=t.GetString("couponsUpToXPercentOff",this.couponsUpToXPercentOff),this.lowerPricePlusCashbackPlusCouponsCompositeNotificationTitle=t.GetString("lowerPricePlusCashbackPlusCouponsCompositeNotificationTitle",this.lowerPricePlusCashbackPlusCouponsCompositeNotificationTitle),this.lpPlusCbPlusCouponsCompositeNotificationPriceComparisonTitle=t.GetString("lpPlusCbPlusCouponsCompositeNotificationPriceComparisonTitle",this.lpPlusCbPlusCouponsCompositeNotificationPriceComparisonTitle),this.lpPlusCbPlusCouponsCompositeNotificationCashbackTitle=t.GetString("lpPlusCbPlusCouponsCompositeNotificationCashbackTitle",this.lpPlusCbPlusCouponsCompositeNotificationCashbackTitle),this.lpPlusCbPlusCouponsCompositeNotificationCouponsTitle=t.GetString("lpPlusCbPlusCouponsCompositeNotificationCouponsTitle",this.lpPlusCbPlusCouponsCompositeNotificationCouponsTitle),this.lpPlusCbPlusCouponsCompositeNotificationCouponsTitleV2=t.GetString("lpPlusCbPlusCouponsCompositeNotificationCouponsTitleV2",this.lpPlusCbPlusCouponsCompositeNotificationCouponsTitleV2),this.v2CompositeNotificationCashbackTitle=t.GetString("v2CompositeNotificationCashbackTitle",this.v2CompositeNotificationCashbackTitle),this.v2CompositeNotificationPriceHistoryTitle=t.GetString("v2CompositeNotificationPriceHistoryTitle",this.v2CompositeNotificationPriceHistoryTitle),this.v2CompositeNotificationPhPlusTitle=t.GetString("v2CompositeNotificationPhPlusTitle",this.v2CompositeNotificationPhPlusTitle),this.v2CompositeNotificationCashbackCouponsTitle=t.GetString("v2CompositeNotificationCashbackCouponsTitle",this.v2CompositeNotificationCashbackCouponsTitle),this.v2CompositeNotificationCommonViewSavingsCTA=t.GetString("v2CompositeNotificationCommonViewSavingsCTA",this.v2CompositeNotificationCommonViewSavingsCTA),this.v2CompositeNotificationHighCouponSuccessRate=t.GetString("v2CompositeNotificationHighCouponSuccessRate",this.v2CompositeNotificationHighCouponSuccessRate),this.v2CompositeNotificationPHOldPriceAriaLAbel=t.GetString("v2CompositeNotificationPHOldPriceAriaLAbel",this.v2CompositeNotificationPHOldPriceAriaLAbel),this.v2CompositeNotificationPHCurrentPriceAriaLAbel=t.GetString("v2CompositeNotificationPHCurrentPriceAriaLAbel",this.v2CompositeNotificationPHCurrentPriceAriaLAbel),this.pcdisclaimerText=t.GetString("pcdisclaimerText",this.pcdisclaimerText),this.pcNotificationdisclaimerText=t.GetString("pcNotificationdisclaimerText",this.pcNotificationdisclaimerText),this.cbMainTitleOffBegin=t.GetString("cbMainTitleOffBegin",this.cbMainTitleOffBegin),this.StorewideCashbackTitleBefore=t.GetString("StorewideCashbackTitleBefore",this.StorewideCashbackTitleBefore),this.StorewideCashbackTitleAfter=t.GetString("StorewideCashbackTitleAfter",this.StorewideCashbackTitleAfter),this.StorewideCashbackTitleOff=t.GetString("StorewideCashbackTitleOff",this.StorewideCashbackTitleOff),this.cbMainTitleOffEnd=t.GetString("cbMainTitleOffEnd",this.cbMainTitleOffEnd),this.gcCashbackOnTheseItem=t.GetString("gcCashbackOnTheseItem",this.gcCashbackOnTheseItem),this.upToStorewideCashback=t.GetString("upToStorewideCashback",this.upToStorewideCashback),this.spbSearchTitleBefore=t.GetString("spbSearchTitleBefore",this.spbSearchTitleBefore),this.spbSearchTitleAfter=t.GetString("spbSearchTitleAfter",this.spbSearchTitleAfter),this.cbMainTitleOff=t.GetString("rebatesPercentage",this.cbMainTitleOff),this.cbMainTitleDelayedEnrollment=t.GetString("cbMainTitleDelayedEnrollment",this.cbMainTitleDelayedEnrollment),this.cbActivateTitleWithOldCashback=t.GetString("cbActivateTitle",this.cbActivateTitleWithOldCashback),this.cbActivateTitle3xIncentive=t.GetString("cbActivateTitle3xIncentive",this.cbActivateTitle3xIncentive),this.cbActivateLimitedTimeOffer=t.GetString("cbActivateLimitedTimeOffer",this.cbActivateLimitedTimeOffer),this.cbEnrollBonusTitle=t.GetString("cbEnrollBonusTitle",this.cbEnrollBonusTitle),this.cbMainTitleOffWithCashbackEstimate=t.GetString("cbMainTitleOffWithCashbackEstimate",this.cbMainTitleOffWithCashbackEstimate),this.cbMainTitleOffWithPdpCashbackEstimate=t.GetString("cbMainTitleOffWithPdpCashbackEstimate",this.cbMainTitleOffWithPdpCashbackEstimate),this.pcbMainTitleOff=t.GetString("pcbMainTitleOff",this.pcbMainTitleOff),this.pcbAriaLabel=t.GetString("pcbAriaLabel",this.pcbAriaLabel),this.cbSectionTitle=t.GetString("cbSectionTitle",this.cbSectionTitle),this.cbMainTitleOn=t.GetString("rebatesPercentageEarn",this.cbMainTitleOn),this.cbAutoShowButtonMessage=t.GetString("cbAutoShowButtonMessage",this.cbAutoShowButtonMessage),this.cbMainTitleOnStoreWide=t.GetString("rebatesStorewidePercentageEarn",this.cbMainTitleOnStoreWide),this.pcbMainTitleOnStoreWide=t.GetString("rebatesStorewidePercentageEarn",this.pcbMainTitleOnStoreWide),this.pcbAbandonedCart=t.GetString("pcbAbandonedCart",this.pcbAbandonedCart),this.cbMainTitleOffStoreWide=t.GetString("rebatesStorewidePercentageEarn",this.cbMainTitleOffStoreWide),this.pcbMainTitleOffStoreWide=t.GetString("rebatesStorewidePercentageEarn",this.pcbMainTitleOffStoreWide),this.cbSubtitle=t.GetString("cbSubtitle",this.cbSubtitle),this.pdpSubtitle=t.GetString("pdpSubtitle",this.pdpSubtitle),this.walmartMessage=t.GetString("walmartMessage",this.walmartMessage),this.cbPromotionsSubTitle=t.GetString("subRebatesPercentageEarn",this.cbPromotionsSubTitle),this.cbPromotionsSubTitleStoreWide=t.GetString("subRebatesPercentageEarnStorewide",this.cbPromotionsSubTitleStoreWide),this.cbTitleSignInOn=t.GetString("cbMergedTitleSignInOn",this.cbTitleSignInOn),this.cbCashBackOnOff=t.GetString("rebatesOnAndOffPrefix",this.cbCashBackOnOff),this.cbLifetimeEarned=t.GetString("cbLifetimeEarned",this.cbLifetimeEarned),this.cbToolTips=t.GetString("cbToolTips",this.cbToolTips),this.bannerPriceDropTitle=t.GetString("bannerPriceDropTitle",this.bannerPriceDropTitle),this.bannerPriceIncreaseTitle=t.GetString("bannerPriceIncreaseTitle",this.bannerPriceIncreaseTitle),this.bannerCouponTitle=t.GetString("bannerCouponTitle",this.bannerCouponTitle),this.bannerCashBackOffTitle=t.GetString("bannerCashBackOffTitle",this.bannerCashBackOffTitle),this.bannerCashBackOnTitle=t.GetString("bannerCashBackOnTitle",this.bannerCashBackOnTitle),this.bannerRecentPurchase=t.GetString("bannerRecentPurchase",this.bannerRecentPurchase),this.bannerCouponHeadingLabel=t.GetString("bannerCouponHeadingLabel",this.bannerCouponHeadingLabel),this.bannerLifetime=t.GetString("bannerLifetime",this.bannerLifetime),this.privacyDataCollectionMessage=t.GetString("privacyDataCollectionMessage",this.privacyDataCollectionMessage),this.recommendationsFriendlyDomainTitle=t.GetString("recommendationsFriendlyDomainTitle",this.recommendationsFriendlyDomainTitle),this.recommendationsFriendlyDomainTitlePriceDrops=t.GetString("recommendationsFriendlyDomainTitlePriceDrops",this.recommendationsFriendlyDomainTitlePriceDrops),this.recommendationsTitle=t.GetString("recommendationsTitle",this.recommendationsTitle),this.recommendationsDiscountPercent=t.GetString("recommendationsDiscountPercent",this.recommendationsDiscountPercent),this.recommendationsPriceDrop=t.GetString("recommendationsPriceDrop",this.recommendationsPriceDrop),this.recommendationsFeatureName=t.GetString("recommendationsFeatureName",this.recommendationsFeatureName),this.recommendationsSSATitle=t.GetString("recommendationsSSATitle",this.recommendationsSSATitle),this.abandonedCartTitle=t.GetString("abandonedCartTitle",this.abandonedCartTitle),this.abandonedCartPrompt=t.GetString("abandonedCartPrompt",this.abandonedCartPrompt),this.abandonedCartCouponPrompt=t.GetString("abandonedCartCouponPrompt",this.abandonedCartCouponPrompt),this.abandonedCartCashbackPrompt=t.GetString("abandonedCartCashbackPrompt",this.abandonedCartCashbackPrompt),this.abandonedCartNotif=t.GetString("abandonedCartNotif",this.abandonedCartNotif),this.abandonedCartNotifOnDomain=t.GetString("abandonedCartNotifOnDomain",this.abandonedCartNotifOnDomain),this.abandonedCartButton=t.GetString("abandonedCartButton",this.abandonedCartButton),this.viewProductButton=t.GetString("viewProductButton",this.viewProductButton),this.abandonedCartCategoryDealsText=t.GetString("abandonedCartCategoryDealsText",this.abandonedCartCategoryDealsText),this.abandonedCartFeatureName=t.GetString("abandonedCartFeatureName",this.abandonedCartFeatureName),this.abandonedCartMoreItemsLabel=t.GetString("abandonedCartMoreItemsLabel",this.abandonedCartMoreItemsLabel),this.abandonedCartTrackAll=t.GetString("abandonedCartTrackAll",this.abandonedCartTrackAll),this.copyCouponAndViewProduct=t.GetString("copyCouponAndViewProduct",this.copyCouponAndViewProduct),this.abandonedCartOOFNotificationTitleForExclusiveCoupon=t.GetString("abandonedCartOOFNotificationTitleForExclusiveCoupon",this.abandonedCartOOFNotificationTitleForExclusiveCoupon),this.abandonedCartOOFNotificationCouponCodeForExclusiveCoupon=t.GetString("abandonedCartOOFNotificationCouponCodeForExclusiveCoupon",this.abandonedCartOOFNotificationCouponCodeForExclusiveCoupon),this.abandonedCartButtonForExclusiveCoupon=t.GetString("abandonedCartButtonForExclusiveCoupon",this.abandonedCartButtonForExclusiveCoupon),this.abandonedCartCopyButtonForExclusiveCoupon=t.GetString("abandonedCartCopyButtonForExclusiveCoupon",this.abandonedCartCopyButtonForExclusiveCoupon),this.abandonedCartCopiedButtonForExclusiveCoupon=t.GetString("abandonedCartCopiedButtonForExclusiveCoupon",this.abandonedCartCopiedButtonForExclusiveCoupon),this.winCartTitle=t.GetString("winCartTitle",this.winCartTitle),this.winCartZeroState=t.GetString("winCartZeroState",this.winCartZeroState),this.microsoftWalletManage=t.GetString("microsoftWalletManage",this.microsoftWalletManage),this.submitCouponData=t.GetString("submitCouponData",this.submitCouponData),this.submitCouponButtonLabel=t.GetString("submitCouponButtonLabel",this.submitCouponButtonLabel),this.couponCode=t.GetString("couponCode",this.couponCode),this.couponDescription=t.GetString("couponDescription",this.couponDescription),this.trAriaLabel=t.GetString("trAriaLabel",this.trAriaLabel),this.priceCompareCbAriaLabel=t.GetString("priceCompareCbAriaLabel",this.priceCompareCbAriaLabel),this.couponSectionTitleStr=t.GetString("couponSectionTitleStr",this.couponSectionTitleStr),this.privacyConsent=t.GetString("privacyConsent",this.privacyConsent),this.savingsHeader=t.GetString("savingsHeader",this.savingsHeader),this.sectionSeeMore=t.GetString("sectionSeeMore",this.sectionSeeMore),this.sectionSeeMoreCoupons=t.GetString("sectionSeeMoreCoupons",this.sectionSeeMoreCoupons),this.sectionSeeOlderCoupons=t.GetString("sectionSeeOlderCoupons",this.sectionSeeOlderCoupons),this.sectionSeeMoreViewLess=t.GetString("sectionSeeMoreViewLess",this.sectionSeeMoreViewLess),this.bannerSave=t.GetString("bannerSave",this.bannerSave),this.pcNotificationTitle=t.GetString("pcNotificationTitle",this.pcNotificationTitle),this.pcNotificationTitleRefresh=t.GetString("pcNotificationTitleRefresh",this.pcNotificationTitleRefresh),this.pcNotificationTitleSmall=t.GetString("pcNotificationTitleSmall",this.pcNotificationTitleSmall),this.pcNotificationNarratorIntro=t.GetString("pcNotificationNarratorIntro",this.pcNotificationNarratorIntro),this.viewMorePricesButtonText=t.GetString("viewMorePricesButtonText",this.viewMorePricesButtonText),this.pcLowestPriceAria=t.GetString("pcLowestPriceAria",this.pcLowestPriceAria),this.pcCurrentPriceAria=t.GetString("pcCurrentPriceAria",this.pcCurrentPriceAria),this.pcFeatureName=t.GetString("pcFeatureName",this.pcFeatureName),this.cbPromotionsTitle=t.GetString("cbPromotionsTitle",this.cbPromotionsTitle),this.cbExpiryDateTime=t.GetString("cbExpiryDateTime",this.cbExpiryDateTime),this.cbSpbExpiryDateTime=t.GetString("cbSpbExpiryDateTime",this.cbSpbExpiryDateTime),this.cbCommissionStr=t.GetString("cbCommissionStr",this.cbCommissionStr),this.pcbCommissionStoreWide=t.GetString("pcbCommissionStoreWide",this.pcbCommissionStoreWide),this.pcbCommissionStoreWideOff=t.GetString("pcbCommissionStoreWideOff",this.pcbCommissionStoreWideOff),this.pcbCommissionStoreWideOffTextOnly=t.GetString("pcbCommissionStoreWideOffTextOnly",this.pcbCommissionStoreWideOffTextOnly),this.pcbStorewideCashback=t.GetString("pcbStorewideCashback",this.pcbStorewideCashback),this.pcbStorewideCashbackAutoshow=t.GetString("pcbStorewideCashbackAutoshow",this.pcbStorewideCashbackAutoshow),this.cbPersonalized=t.GetString("cbPersonalized",this.cbPersonalized),this.instantcbRefresh=t.GetString("instantcbRefresh",this.instantcbRefresh),this.trackCashback=t.GetString("trackCashback",this.trackCashback),this.instantcbSecond=t.GetString("instantcbSecond",this.instantcbSecond),this.couponSuccessful=t.GetString("couponSuccessful",this.couponSuccessful),this.cbPreviousCashbackDomain=t.GetString("cbPreviousCashbackDomain",this.cbPreviousCashbackDomain),this.cbMergedTitleStr=t.GetString("rebatesFoundCouponsAndCashbackStr",this.cbMergedTitleStr),this.cbMergedTitleEstimateStr=t.GetString("cbMergedTitleEstimateStr",this.cbMergedTitleEstimateStr),this.forYou=t.GetString("forYou",this.forYou),this.previousOffers=t.GetString("previousOffers",this.previousOffers),this.commonAriaLogo=t.GetString("rebatesNotificationLogo",this.commonAriaLogo),this.tipsMinimumPurchase=t.GetString("tipsMinimumPurchase",this.tipsMinimumPurchase),this.totalSavings=t.GetString("totalSavings",this.totalSavings),this.triviaAverageSavingsHeader=t.GetString("triviaAverageSavingsHeader",this.triviaAverageSavingsHeader),this.couponExpectationHeader=t.GetString("couponExpectationHeader",this.couponExpectationHeader),this.highCouponExpectationTooltip=t.GetString("highCouponExpectationTooltip",this.highCouponExpectationTooltip),this.mediumCouponExpectationTooltip=t.GetString("mediumCouponExpectationTooltip",this.mediumCouponExpectationTooltip),this.lowCouponExpectationTooltip=t.GetString("lowCouponExpectationTooltip",this.lowCouponExpectationTooltip),this.couponExpectationHigh=t.GetString("couponExpectationHigh",this.couponExpectationHigh),this.couponExpectationMedium=t.GetString("couponExpectationMedium",this.couponExpectationMedium),this.couponExpectationLow=t.GetString("couponExpectationLow",this.couponExpectationLow),this.virtualCardSystemFailureDescription=t.GetString("virtualCardSystemFailureDescription",this.virtualCardSystemFailureDescription),this.virtualCardSystemFailureLink=t.GetString("virtualCardSystemFailureLink",this.virtualCardSystemFailureLink),this.virtualCardLinkFail=t.GetString("virtualCardLinkFail",this.virtualCardLinkFail),this.virtualCardFeatureName=t.GetString("virtualCardFeatureName",this.virtualCardFeatureName),this.cardPaymentOptionBanner=t.GetString("cardPaymentOptionBanner",this.cardPaymentOptionBanner),this.otherPaymentMethodBanner=t.GetString("otherPaymentMethodBanner",this.otherPaymentMethodBanner),this.howItWorkLinkAriaLabel=t.GetString("howItWorkLinkAriaLabel",this.howItWorkLinkAriaLabel),this.msZipDescription=t.GetString("msZipDescription",this.msZipDescription),this.similarSellerNotificationError=t.GetString("similarSellerNotificationError",this.similarSellerNotificationError),this.similarSellerStringCollapsedAmazon=t.GetString("similarSellerStringCollapsedAmazon",this.similarSellerStringCollapsedAmazon);this.similarSellerStringCollapsed=t.GetString("similarSellerStringCollapsed",this.similarSellerStringCollapsed),this.similarSellerAddToCartTitle=t.GetString("similarSellerAddToCartTitle",this.similarSellerAddToCartTitle),this.similarSellerNewAddToCartTitle=t.GetString("similarSellerNewAddToCartTitle",this.similarSellerNewAddToCartTitle),this.similarSellerAddedToCartTitle=t.GetString("similarSellerAddedToCartTitle",this.similarSellerAddedToCartTitle),this.similarSellerInCartTitle=t.GetString("similarSellerInCartTitle",this.similarSellerInCartTitle),this.similarSellerShipFromString=t.GetString("similarSellerShipFromString",this.similarSellerShipFromString),this.similarSellerRatingLabel=t.GetString("similarSellerRatingLabel",this.similarSellerRatingLabel),this.similarSellerFreeDelivery=t.GetString("similarSellerFreeDelivery",this.similarSellerFreeDelivery),this.similarSellerFeatureName=t.GetString("similarSellerFeatureName",this.similarSellerFeatureName),this.similarSellerStringAmazon=t.GetString("similarSellerStringAmazon",this.similarSellerStringAmazon),this.similarSellerString=t.GetString("similarSellerString",this.similarSellerString),this.similarSellerTitleAmazon=t.GetString("similarSellerTitleAmazon",this.similarSellerTitleAmazon),this.similarSellerTitle=t.GetString("similarSellerTitle",this.similarSellerTitle),this.similarSellerStringSubtitleAmazon=t.GetString("similarSellerStringSubtitleAmazon",this.similarSellerStringSubtitleAmazon),this.similarSellerStringSubtitleAmazonNew=t.GetString("similarSellerStringSubtitleAmazonNew",this.similarSellerStringSubtitleAmazonNew),this.similarSellerStringSubtitle=t.GetString("similarSellerStringSubtitle",this.similarSellerStringSubtitle),this.similarSellerNotificationTitle=t.GetString("similarSellerNotificationTitle",this.similarSellerNotificationTitle),this.similarSellerAddToCartAriaLable=t.GetString("similarSellerAddToCartAriaLable",this.similarSellerAddToCartAriaLable),this.chatChipsInCardTitle=t.GetString("chatChipsInCardTitle",this.chatChipsInCardTitle),this.carouselChatChipsCartTitle=t.GetString("carouselChatChipsCartTitle",this.carouselChatChipsCartTitle),this.chatChipsSectionTitle=t.GetString("chatChipsSectionTitle",this.chatChipsSectionTitle),this.chatChipsInCardHeader=t.GetString("chatChipsInCardHeader",this.chatChipsInCardHeader),this.carouselChipsInCardHeader=t.GetString("carouselChipsInCardHeader",this.carouselChipsInCardHeader),this.tipsTiltleSingle=t.GetString("tipsTiltleSingle",this.tipsTiltleSingle),this.tipsSubTitleSingle=t.GetString("tipsSubTitleSingle",this.tipsSubTitleSingle),this.orderTrackingTitle=t.GetString("orderTrackingTitle",this.orderTrackingTitle),this.rewardFailedSignin=t.GetString("rewardFailedSignin",this.rewardFailedSignin),this.rewardTitleDefault=t.GetString("rewardTitleDefault",this.rewardTitleDefault),this.rewardTitleEarnedMaximum=t.GetString("rewardTitleEarnedMaximum",this.rewardTitleEarnedMaximum),this.rewardTitleRewardTwo=t.GetString("rewardTitleRewardTwo",this.rewardTitleRewardTwo),this.rewardPointMax=t.GetString("rewardPointMax",this.rewardPointMax),this.rewardPerMaxPoint=t.GetString("rewardPerMaxPoint",this.rewardPerMaxPoint),this.rewardDetailFirstLine=t.GetString("rewardDetailFirstLine",this.rewardDetailFirstLine),this.rewardTitleRewardsAdded=t.GetString("rewardTitleRewardsAdded",this.rewardTitleRewardsAdded),this.rewardDetailFirstLineBold=t.GetString("rewardDetailFirstLineBold",this.rewardDetailFirstLineBold),this.rewardKeepExploringText=t.GetString("rewardKeepExploringText",this.rewardKeepExploringText),this.rewardDetailTwo=t.GetString("rewardDetailTwo",this.rewardDetailTwo),this.rewardDetail=t.GetString("rewardDetail",this.rewardDetail),this.rewardSignIn=t.GetString("rewardSignIn",this.rewardSignIn),this.rewardRedeem=t.GetString("rewardRedeem",this.rewardRedeem),this.rewardCoupons=t.GetString("rewardCoupons",this.rewardCoupons),this.rewardCashback=t.GetString("rewardCashback",this.rewardCashback),this.rewardRewards=t.GetString("rewardRewards",this.rewardRewards),this.rewardAssociateSignIn=t.GetString("rewardAssociateSignIn",this.rewardAssociateSignIn),this.icRewardProgressText=t.GetString("icRewardProgressText",this.icRewardProgressText),this.icRewardProgressAriaLabel=t.GetString("icRewardProgressAriaLabel",this.icRewardProgressAriaLabel),this.icRewardClaimText=t.GetString("icRewardClaimText",this.icRewardClaimText),this.icRewardClaimPtsAriaLabel=t.GetString("icRewardClaimPtsAriaLabel",this.icRewardClaimPtsAriaLabel),this.icRewardPointsAriaLabel=t.GetString("icRewardPointsAriaLabel",this.icRewardPointsAriaLabel),this.icRewardDollarsAriaLabel=t.GetString("icRewardDollarsAriaLabel",this.icRewardDollarsAriaLabel),this.cucRewardClaimText=t.GetString("cucRewardClaimText",this.cucRewardClaimText),this.dismissMessageAriaLabel=t.GetString("dismissMessageAriaLabel",this.dismissMessageAriaLabel),this.virtualCardDetailsActions=t.GetString("virtualCardDetailsActions",this.virtualCardDetailsActions),this.maybeLaterButtontext=t.GetString("maybeLaterButtontext",this.maybeLaterButtontext),this.rewardJoinSuccess=t.GetString("rewardJoinSuccess",this.rewardJoinSuccess),this.rewardOfferSuccess=t.GetString("rewardOfferSuccess",this.rewardOfferSuccess),this.joinNowButtonText=t.GetString("joinNowButtonText",this.joinNowButtonText),this.ytSectionTitleOnRetailer=t.GetString("ytSectionTitleOnRetailer",this.ytSectionTitleOnRetailer),this.ytSectionTitleOthersOnRetailer=t.GetString("ytSectionTitleOthersOnRetailer",this.ytSectionTitleOthersOnRetailer),this.ytCouponDescription=t.GetString("ytCouponDescription",this.ytCouponDescription),this.ytPhotoLabel=t.GetString("ytPhotoLabel",this.ytPhotoLabel),this.ytMoreCoupons=t.GetString("ytMoreCoupons",this.ytMoreCoupons),this.ytSectionTitleOnYoutube=t.GetString("ytSectionTitleOnYoutube",this.ytSectionTitleOnYoutube),this.ytShopOn=t.GetString("ytShopOn",this.ytShopOn),this.ytShopNow=t.GetString("ytShopNow",this.ytShopNow),this.ytSaveCouponsPermission=t.GetString("ytSaveCouponsPermission",this.ytSaveCouponsPermission),this.ytDontSaveCouponsPermission=t.GetString("ytDontSaveCouponsPermission",this.ytDontSaveCouponsPermission),this.ytFeatureName=t.GetString("ytFeatureName",this.ytFeatureName),this.ytHeaderStr=t.GetString("ytHeaderStr",this.ytHeaderStr),this.ytSaved=t.GetString("ytSaved",this.ytSaved),this.pintFeatureName=t.GetString("pintFeatureName",this.pintFeatureName),this.ptCouponsTitleStr=t.GetString("ptCouponsTitleStr",this.ptCouponsTitleStr),this.snoozeHoverText=t.GetString("snoozeHoverText",this.snoozeHoverText),this.snoozeCurrentNotificationFor8HoverText=t.GetString("snoozeCurrentNotificationFor8HoverText",this.snoozeCurrentNotificationFor8HoverText),this.snoozeCurrentNotificationFor24HoverText=t.GetString("snoozeCurrentNotificationFor24HoverText",this.snoozeCurrentNotificationFor24HoverText),this.rebatesHistoryLinkText=t.GetString("rebatesHistoryLinkText",this.rebatesHistoryLinkText),this.attFlyoutLocked=t.GetString("attFlyoutLocked",this.attFlyoutLocked),this.attFlyoutUnlocked=t.GetString("attFlyoutUnlocked",this.attFlyoutUnlocked),this.attTooltipHeader=t.GetString("attTooltipHeader",this.attTooltipHeader),this.attTooltipText=t.GetString("attTooltipText",this.attTooltipText),this.gcbCashBack=t.GetString("gcbCashBack",this.gcbCashBack),this.gcbWhenYouSpend=t.GetString("gcbWhenYouSpend",this.gcbWhenYouSpend),this.gcbWhenShoppingAt=t.GetString("gcbWhenShoppingAt",this.gcbWhenShoppingAt),this.gcbAt=t.GetString("gcbAt",this.gcbAt),this.gcbViewAllActivatedOffers=t.GetString("gcbViewAllActivatedOffers",this.gcbViewAllActivatedOffers),this.gcbSigninToClaim=t.GetString("gcbSigninToClaim",this.gcbSigninToClaim),this.gcbViewMoreOffers=t.GetString("gcbViewMoreOffers",this.gcbViewMoreOffers),this.gcbThisOfferEndsIn=t.GetString("gcbThisOfferEndsIn",this.gcbThisOfferEndsIn),this.gcbNotifTitle=t.GetString("gcbNotifTitle",this.gcbNotifTitle),this.gcbOnMerchantName=t.GetString("gcbOnMerchantName",this.gcbOnMerchantName),this.gcbOnLogoMerchantName=t.GetString("gcbOnLogoMerchantName",this.gcbOnLogoMerchantName),this.paneForYou=t.GetString("paneForYou",this.paneForYou),this.paneHome=t.GetString("paneHome",this.paneHome),this.settingsPaneHdNotificationsTitle=t.GetString("settingsPaneHdNotificationsTitle",this.settingsPaneHdNotificationsTitle),this.settingsPaneHdNotificationsText=t.GetString("settingsPaneHdNotificationsText",this.settingsPaneHdNotificationsText),this.settingsPaneHdAllNotifications=t.GetString("settingsPaneHdAllNotifications",this.settingsPaneHdAllNotifications),this.settingsPaneHdSavings=t.GetString("settingsPaneHdSavings",this.settingsPaneHdSavings),this.settingsPaneHdProductInsights=t.GetString("settingsPaneHdProductInsights",this.settingsPaneHdProductInsights),this.settingsPaneHdReminders=t.GetString("settingsPaneHdReminders",this.settingsPaneHdReminders),this.settingsPaneHdRecommendations=t.GetString("settingsPaneHdRecommendations",this.settingsPaneHdRecommendations),this.settingsPaneAllNotificationsText=t.GetString("settingsPaneAllNotificationsText",this.settingsPaneAllNotificationsText),this.settingsPaneCouponsText=t.GetString("settingsPaneCouponsText",this.settingsPaneCouponsText),this.settingsPaneCashbackText=t.GetString("settingsPaneCashbackText",this.settingsPaneCashbackText),this.settingsPanePcText=t.GetString("settingsPanePcText",this.settingsPanePcText),this.settingsPanePhText=t.GetString("settingsPanePhText",this.settingsPanePhText),this.settingsPaneProductTrackingText=t.GetString("settingsPaneProductTrackingText",this.settingsPaneProductTrackingText),this.settingsPanePackageTrackingText=t.GetString("settingsPanePackageTrackingText",this.settingsPanePackageTrackingText),this.settingsPaneBingChatText=t.GetString("settingsPaneBingChatText",this.settingsPaneBingChatText),this.settingsPaneDealsText=t.GetString("settingsPaneDealsText",this.settingsPaneDealsText),this.settingsPaneAutosText=t.GetString("settingsPaneAutosText",this.settingsPaneAutosText),this.settingsPaneGroceriesText=t.GetString("settingsPaneGroceriesText",this.settingsPaneGroceriesText),this.settingsPaneOtherText=t.GetString("settingsPaneOtherText",this.settingsPaneOtherText),this.paneMyShopping=t.GetString("paneMyShopping",this.paneMyShopping),this.paneCouponsSavings=t.GetString("paneCouponsSavings",this.paneCouponsSavings),this.paneExplore=t.GetString("paneExplore",this.paneExplore),this.paneNullStateMessage=t.GetString("paneNullStateMessage",this.paneNullStateMessage),this.phTodayPriceAriaLabel=t.GetString("phTodayPriceAriaLabel",this.phTodayPriceAriaLabel),this.phHighPriceAriaLabel=t.GetString("phHighPriceAriaLabel",this.phHighPriceAriaLabel),this.phLowPriceArialLabel=t.GetString("phLowPriceArialLabel",this.phLowPriceArialLabel),this.trSectionTitle=t.GetString("trSectionTitle",this.trSectionTitle),this.autosMarketplaceName=t.GetString("autosMarketplaceName",this.autosMarketplaceName),this.autosMarketplaceNotificationSave=t.GetString("autosMarketplaceNotificationSave",this.autosMarketplaceNotificationSave),this.autosMarketplaceNotificationHeaderPt2=t.GetString("autosMarketplaceNotificationHeaderPt2",this.autosMarketplaceNotificationHeaderPt2),this.autosMarketplaceSeeMoreButtonV2=t.GetString("autosMarketplaceSeeMoreButtonV2",this.autosMarketplaceSeeMoreButtonV2),this.autosMarketplaceSectionTitle=t.GetString("autosMarketplaceSectionTitle",this.autosMarketplaceSectionTitle),this.autosMarketplaceNotifivationLowPriceHeader=t.GetString("autosMarketplaceNotifivationLowPriceHeader",this.autosMarketplaceNotifivationLowPriceHeader),this.autosMarketplaceNotificationHeader=t.GetString("autosMarketplaceNotificationHeader",this.autosMarketplaceNotificationHeader),this.autosMarketplaceNotificationNoAccident=t.GetString("autosMarketplaceNotificationNoAccident",this.autosMarketplaceNotificationNoAccident),this.autosMarketplaceOnlineDealer=t.GetString("autosMarketplaceOnlineDealer",this.autosMarketplaceOnlineDealer),this.autosMarketplaceSeeMoreButton=t.GetString("autosMarketplaceSeeMoreButton",this.autosMarketplaceSeeMoreButton),this.autosMarketplaceSeeNowButton=t.GetString("autosMarketplaceSeeNowButton",this.autosMarketplaceSeeNowButton),this.autosMarketplaceTrendingVideos=t.GetString("autosMarketplaceTrendingVideos",this.autosMarketplaceTrendingVideos),this.autosMarketplaceTrendingVideosV2=t.GetString("autosMarketplaceTrendingVideosV2",this.autosMarketplaceTrendingVideosV2),this.autosMarketplaceTrendingVideosV3=t.GetString("autosMarketplaceTrendingVideosV3",this.autosMarketplaceTrendingVideosV3),this.autosMarketplaceReviewsCTAButton=t.GetString("autosMarketplaceReviewsCTAButton",this.autosMarketplaceReviewsCTAButton),this.autosMarketplaceTrendingReviews=t.GetString("autosMarketplaceTrendingReviews",this.autosMarketplaceTrendingReviews),this.autosMarketplaceSeeDetails=t.GetString("autosMarketplaceSeeDetails",this.autosMarketplaceSeeDetails),this.autosMarketplaceSimilarCarFound=t.GetString("autosMarketplaceSimilarCarFound",this.autosMarketplaceSimilarCarFound),this.autosMarketplaceSimilarCarsFound=t.GetString("autosMarketplaceSimilarCarsFound",this.autosMarketplaceSimilarCarsFound),this.autosMarketplaceNoAccident=t.GetString("autosMarketplaceNoAccident",this.autosMarketplaceNoAccident),this.autosMarketplacePopular=t.GetString("autosMarketplacePopular",this.autosMarketplacePopular),this.autosMarketplaceGreatDeal=t.GetString("autosMarketplaceGreatDeal",this.autosMarketplaceGreatDeal),this.autosDealsIncentivesTitleText=t.GetString("autosDealsIncentivesTitleText",this.autosDealsIncentivesTitleText),this.autosFeatureName=t.GetString("autosFeatureName",this.autosFeatureName),this.autosLatestNews=t.GetString("autosLatestNews",this.autosLatestNews),this.autosMyGarageHeaderTitle=t.GetString("autosMyGarageHeaderTitle",this.autosMyGarageHeaderTitle),this.autosMyGarageTitleText=t.GetString("autosMyGarageTitleText",this.autosMyGarageTitleText),this.autosMyGarageTitleTextV2=t.GetString("autosMyGarageTitleTextV2",this.autosMyGarageTitleTextV2),this.autosMyGaragePriceDropText=t.GetString("autosMyGaragePriceDropText",this.autosMyGaragePriceDropText),this.autosMyGaragePriceIncreaseText=t.GetString("autosMyGaragePriceIncreaseText",this.autosMyGaragePriceIncreaseText),this.autosMyGarageDisclaimer=t.GetString("autosMyGarageDisclaimer",this.autosMyGarageDisclaimer),this.autosMyGarageActionButtonText=t.GetString("autosMyGarageActionButtonText",this.autosMyGarageActionButtonText),this.autosMyGarageActionButtonTextV2=t.GetString("autosMyGarageActionButtonTextV2",this.autosMyGarageActionButtonTextV2),this.zipPayPayment=t.GetString("zipPayment",this.zipPayPayment),this.zipPayVirtualCardHeaderTitle=t.GetString("zipVirtualCardHeaderTitle",this.zipPayVirtualCardHeaderTitle),this.zipPayVirtualCardHeaderDescription=t.GetString("zipVirtualCardHeaderDescription",this.zipPayVirtualCardHeaderDescription),this.zipPayVirtualCardHeaderAutofillFailedDescription=t.GetString("zipVirtualCardHeaderAutofillFailedDescription",this.zipPayVirtualCardHeaderAutofillFailedDescription),this.zipPayVisualizedCardDetails=t.GetString("zipVisualizedCardDetails",this.zipPayVisualizedCardDetails),this.affirmVirtualCardHeaderTitle=t.GetString("affirmVirtualCardHeaderTitle",this.affirmVirtualCardHeaderTitle),this.affirmVirtualCardHeaderDescription=t.GetString("affirmVirtualCardHeaderDescription",this.affirmVirtualCardHeaderDescription),this.affirmVirtualCardHeaderNoBillingInfoDescription=t.GetString("affirmVirtualCardHeaderNoBillingInfoDescription",this.affirmVirtualCardHeaderNoBillingInfoDescription),this.affirmVirtualCardHeaderAutofillFailedDescription=t.GetString("affirmVirtualCardHeaderAutofillFailedDescription",this.affirmVirtualCardHeaderAutofillFailedDescription),this.affirmPayment=t.GetString("affirmPayment",this.affirmPayment),this.affirmVisualizedCardDetails=t.GetString("affirmVisualizedCardDetails",this.affirmVisualizedCardDetails),this.affirmDisclaimerText=t.GetString("affirmDisclaimerText",this.affirmDisclaimerText),this.affirmDisclaimerLinkText=t.GetString("affirmDisclaimerLinkText",this.affirmDisclaimerLinkText),this.klarnaVirtualCardHeaderTitle=t.GetString("klarnaVirtualCardHeaderTitle",this.klarnaVirtualCardHeaderTitle),this.klarnaVirtualCardHeaderDescription=t.GetString("klarnaVirtualCardHeaderDescription",this.klarnaVirtualCardHeaderDescription),this.klarnaVirtualCardHeaderNoBillingInfoDescription=t.GetString("klarnaVirtualCardHeaderNoBillingInfoDescription",this.klarnaVirtualCardHeaderNoBillingInfoDescription),this.klarnaVirtualCardHeaderAutofillFailedDescription=t.GetString("klarnaVirtualCardHeaderAutofillFailedDescription",this.klarnaVirtualCardHeaderAutofillFailedDescription),this.klarnaPayment=t.GetString("klarnaPayment",this.klarnaPayment),this.klarnaVisualizedCardDetails=t.GetString("klarnaVisualizedCardDetails",this.klarnaVisualizedCardDetails),this.klarnaDisclaimerText=t.GetString("klarnaDisclaimerText",this.klarnaDisclaimerText),this.klarnaCustomerServiceNumber=t.GetString("klarnaCustomerServiceNumber",this.klarnaCustomerServiceNumber),this.trendingOffersTitle=t.GetString("trendingOffersTitle",this.trendingOffersTitle),this.similarOffersTitle=t.GetString("similarOffersTitle",this.similarOffersTitle),this.dailyDealsTitle=t.GetString("dailyDeailsTitle",this.dailyDealsTitle),this.relatedProductsModuleTitle=t.GetString("relatedProductsModuleTitle",this.relatedProductsModuleTitle),this.nativeAdsModuleTitle=t.GetString("nativeAdsModuleTitle",this.nativeAdsModuleTitle),this.visualSearchModuleTitle=t.GetString("visualSearchModuleTitle",this.visualSearchModuleTitle),this.percentageOff=t.GetString("percentageOff",this.percentageOff),this.offerAltText=t.GetString("offerAltText",this.offerAltText),this.dealOfferAltText=t.GetString("dealOfferAltText",this.dealOfferAltText),this.sponsoredOfferAltText=t.GetString("sponsoredOfferAltText",this.sponsoredOfferAltText),this.sponsoredDealOfferAltText=t.GetString("sponsoredDealOfferAltText",this.sponsoredDealOfferAltText),this.shopAllCTA=t.GetString("shopAllCTA",this.shopAllCTA),this.showMore=t.GetString("showMore",this.showMore),this.adSlug=t.GetString("adSlug",this.adSlug),this.productCardAdSlugText=t.GetString("productCardAdSlugText",this.productCardAdSlugText),this.adSlugPolicy=t.GetString("adSlugPolicy",this.adSlugPolicy),this.buyDirectTitle=t.GetString("buyDirectTitle",this.buyDirectTitle),this.buyDirectCashback=t.GetString("buyDirectCashback",this.buyDirectCashback),this.buyDirectShipping=t.GetString("buyDirectShipping",this.buyDirectShipping),this.buyDirectSeller=t.GetString("buyDirectSeller",this.buyDirectSeller),this.buyDirectAltText=t.GetString("buyDirectDealOfferAltText",this.buyDirectAltText),this.buyDirectOfferAltText=t.GetString("buyDirectOfferAltText",this.buyDirectOfferAltText),this.TrackMe=t.GetString("TrackMe",this.TrackMe),this.TrackingNow=t.GetString("TrackingNow",this.TrackingNow),this.productTrackingTitlePrice=t.GetString("productTrackingTitlePrice",this.productTrackingTitlePrice),this.productTrackingTitlePriceUnTrack=t.GetString("productTrackingTitlePriceUnTrack",this.productTrackingTitlePriceUnTrack),this.productTrackingTitlePriceFor=t.GetString("productTrackingTitlePriceFor",this.productTrackingTitlePriceFor),this.productTrackingTitleAvailability=t.GetString("productTrackingTitleAvailability",this.productTrackingTitleAvailability),this.productTrackingTitleAvailabilityUnTrack=t.GetString("productTrackingTitleAvailabilityUnTrack",this.productTrackingTitleAvailabilityUnTrack),this.productTrackingTitleAvailabilityFor=t.GetString("productTrackingTitleAvailabilityFor",this.productTrackingTitleAvailabilityFor),this.productTrackingDescription=t.GetString("productTrackingDescription",this.productTrackingDescription),this.productTrackingBackInStockAlertsOn=t.GetString("productTrackingBackInStockAlertsOn",this.productTrackingBackInStockAlertsOn),this.productTrackingAlertBtnText=t.GetString("productTrackingAlertBtnText",this.productTrackingAlertBtnText),this.productTrackingInStockAtText=t.GetString("productTrackingInStockAtText",this.productTrackingInStockAtText),this.productTrackingBackInStockText=t.GetString("productTrackingBackInStockText",this.productTrackingBackInStockText),this.productTrackingPriceDropText=t.GetString("productTrackingPriceDropText",this.productTrackingPriceDropText),this.productTrackingAbandonedCartPriceDropText=t.GetString("productTrackingAbandonedCartPriceDropText",this.productTrackingAbandonedCartPriceDropText),this.productTrackingAbandonedCartTrackedPriceDropText=t.GetString("productTrackingAbandonedCartTrackedPriceDropText",this.productTrackingAbandonedCartTrackedPriceDropText),this.productTrackingOnRetailerText=t.GetString("productTrackingOnRetailerText",this.productTrackingOnRetailerText),this.productTrackingViewTrackedText=t.GetString("productTrackingViewTrackedText",this.productTrackingViewTrackedText),this.productTrackingViewItem=t.GetString("productTrackingViewItem",this.productTrackingViewItem),this.productTrackingTrackedProduct=t.GetString("productTrackingTrackedProduct",this.productTrackingTrackedProduct),this.productTrackingAlertsOn=t.GetString("productTrackingAlertsOn",this.productTrackingAlertsOn),this.productTrackingAlertSetting=t.GetString("productTrackingAlertSetting",this.productTrackingAlertSetting),this.productTrackingDuration=t.GetString("productTrackingDuration",this.productTrackingDuration),this.productTrackingXWeeks=t.GetString("productTrackingXWeeks",this.productTrackingXWeeks),this.productTrackingPriceDropXPercent=t.GetString("productTrackingPriceDropXPercent",this.productTrackingPriceDropXPercent),this.productTrackingFeatureName=t.GetString("productTrackingFeatureName",this.productTrackingFeatureName),this.productTrackingPriceDropAlertText=t.GetString("productTrackingPriceDropAlertText",this.productTrackingPriceDropAlertText),this.productTrackingNotifyByEmail=t.GetString("productTrackingNotifyByEmail",this.productTrackingNotifyByEmail),this.productTrackingPriceTrackAlert=t.GetString("productTrackingPriceTrackAlert",this.productTrackingPriceTrackAlert),this.productTrackingStockTrackAlert=t.GetString("productTrackingStockTrackAlert",this.productTrackingStockTrackAlert),this.productTrackingTrackFailed=t.GetString("productTrackingTrackFailed",this.productTrackingTrackFailed),this.productTrackingUntrackFailed=t.GetString("productTrackingUntrackFailed",this.productTrackingUntrackFailed),this.productTrackingInStockOther=t.GetString("productTrackingInStockOther",this.productTrackingInStockOther),this.productTrackingAlertBtnTextConcise=t.GetString("productTrackingAlertBtnTextConcise",this.productTrackingAlertBtnTextConcise),this.productTrackingViewTrackedTextConcise=t.GetString("productTrackingViewTrackedTextConcise",this.productTrackingViewTrackedTextConcise),this.productTrackingDescriptionConcise=t.GetString("productTrackingDescriptionConcise",this.productTrackingDescriptionConcise),this.productTrackingAvailabilitySubtitleConcise=t.GetString("productTrackingAvailabilitySubtitleConcise",this.productTrackingAvailabilitySubtitleConcise),this.productTrackingAlertsOnConcise=t.GetString("productTrackingAlertsOnConcise",this.productTrackingAlertsOnConcise),this.productTrackingPriceDropTextConcise=t.GetString("productTrackingPriceDropTextConcise",this.productTrackingPriceDropTextConcise),this.productTrackingOnRetailerPreTextConcise=t.GetString("productTrackingOnRetailerPreTextConcise",this.productTrackingOnRetailerPreTextConcise),this.productTrackingForRetailerTextConcise=t.GetString("productTrackingForRetailerTextConcise",this.productTrackingForRetailerTextConcise),this.productTrackingNotificationOk=t.GetString("productTrackingNotificationOk",this.productTrackingNotificationOk),this.productTrackingNotificationTrackProduct=t.GetString("productTrackingNotificationTrackProduct",this.productTrackingNotificationTrackProduct),this.productTrackingNotificationCouponOffers=t.GetString("productTrackingNotificationCouponOffers",this.productTrackingNotificationCouponOffers),this.productTrackingCouponOfferPercentage=t.GetString("productTrackingCouponOfferPercentage",this.productTrackingCouponOfferPercentage),this.productTrackingCashbackOfferValue=t.GetString("productTrackingCashbackOfferValue",this.productTrackingCashbackOfferValue),this.productTrackingNotificationCashbackOffers=t.GetString("productTrackingNotificationCashbackOffers",this.productTrackingNotificationCashbackOffers),this.productTrackingNotificationEmailText=t.GetString("productTrackingNotificationEmailText",this.productTrackingNotificationEmailText),this.productTrackingNotificationTooltipText=t.GetString("productTrackingNotificationTooltipText",this.productTrackingNotificationTooltipText),this.productTrackingNotificationSeeTerms=t.GetString("productTrackingNotificationSeeTerms",this.productTrackingNotificationSeeTerms),this.prodCollSectionTitle=t.GetString("prodCollSectionTitle",this.prodCollSectionTitle),this.prodCollWishlistTitle=t.GetString("prodCollWishlistTitle",this.prodCollWishlistTitle),this.prodCollTrackingTitle=t.GetString("prodCollTrackingTitle",this.prodCollTrackingTitle),this.prodCollProdHistoryTitle=t.GetString("prodCollProdHistoryTitle",this.prodCollProdHistoryTitle),this.prodCollEmptyWishlistMessage=t.GetString("prodCollEmptyWishlistMessage",this.prodCollEmptyWishlistMessage),this.prodCollEmptyTrackingMessage=t.GetString("prodCollEmptyTrackingMessage",this.prodCollEmptyTrackingMessage),this.prodCollEmptyRecentlyViewedMessage=t.GetString("prodCollEmptyRecentlyViewedMessage",this.prodCollEmptyRecentlyViewedMessage),this.prodCollDeleteTitle=t.GetString("prodCollDeleteTitle",this.prodCollDeleteTitle),this.prodCollStartTracking=t.GetString("prodCollStartTracking",this.prodCollStartTracking),this.prodCollViewSteps=t.GetString("prodCollViewSteps",this.prodCollViewSteps),this.prodCollStepOne=t.GetString("prodCollStepOne",this.prodCollStepOne),this.prodCollStepTwo=t.GetString("prodCollStepTwo",this.prodCollStepTwo),this.prodCollStepThree=t.GetString("prodCollStepThree",this.prodCollStepThree),this.prodCollPrice=t.GetString("prodCollPrice",this.prodCollPrice),this.prodCollPriceIncrease=t.GetString("prodCollPriceIncrease",this.prodCollPriceIncrease),this.prodCollPriceDecrease=t.GetString("prodCollPriceDecrease",this.prodCollPriceDecrease),this.prodCollConsentTitle=t.GetString("prodCollConsentTitle",this.prodCollConsentTitle),this.prodCollConsentText=t.GetString("prodCollConsentText",this.prodCollConsentText),this.prodCollConsentYes=t.GetString("prodCollConsentYes",this.prodCollConsentYes),this.prodCollConsentNoThanks=t.GetString("prodCollConsentNoThanks",this.prodCollConsentNoThanks),this.prodCollConsentSignInText=t.GetString("prodCollConsentSignInText",this.prodCollConsentSignInText),this.prodCollConsentSignIn=t.GetString("prodCollConsentSignIn",this.prodCollConsentSignIn),this.prodCollConsentSignInPrivacyText=t.GetString("prodCollConsentSignInPrivacyText",this.prodCollConsentSignInPrivacyText),this.prodCollConsentSignInPrivacyTextSeeMore=t.GetString("prodCollConsentSignInPrivacyTextSeeMore",this.prodCollConsentSignInPrivacyTextSeeMore),this.prodCollConsentNotNow=t.GetString("prodCollConsentNotNow",this.prodCollConsentNotNow),this.mitButton=t.GetString("mitButton",this.mitButton),this.mitHeaderBlackFriday=t.GetString("mitHeaderBlackFriday",this.mitHeaderBlackFriday),this.mitSubtitleBlackFriday=t.GetString("mitSubtitleBlackFriday",this.mitSubtitleBlackFriday),this.mitHeaderCyberMonday=t.GetString("mitHeaderCyberMonday",this.mitHeaderCyberMonday),this.mitSubtitleCyberMonday=t.GetString("mitSubtitleCyberMonday",this.mitSubtitleCyberMonday),this.mitHeaderThanksgiving=t.GetString("mitHeaderThanksgiving",this.mitHeaderThanksgiving),this.mitSubtitleThanksgiving=t.GetString("mitSubtitleThanksgiving",this.mitSubtitleThanksgiving),this.mitHeaderHolidays=t.GetString("mitHeaderHolidays",this.mitHeaderHolidays),this.mitSubtitleHolidays=t.GetString("mitSubtitleHolidays",this.mitSubtitleHolidays),this.mitHeaderNewYear=t.GetString("mitHeaderNewYear",this.mitHeaderNewYear),this.mitSubtitleNewYear=t.GetString("mitSubtitleNewYear",this.mitSubtitleNewYear),this.mitHeaderValentines=t.GetString("mitHeaderValentines",this.mitHeaderValentines),this.inboxCouponsFeatureName=t.GetString("inboxCouponsFeatureName",this.inboxCouponsFeatureName),this.inboxSavingsFeatureName=t.GetString("inboxSavingsFeatureName",this.inboxSavingsFeatureName),this.inboxCouponsTitle=t.GetString("inboxCouponsTitle",this.inboxCouponsTitle),this.inboxCouponsFromRetailerTitle=t.GetString("inboxCouponsFromRetailerTitle",this.inboxCouponsFromRetailerTitle),this.inboxCouponsLearnMore=t.GetString("inboxCouponsLearnMore",this.inboxCouponsLearnMore),this.inboxCouponDescription=t.GetString("inboxCouponDescription",this.inboxCouponDescription),this.inboxCouponsFound=t.GetString("inboxCouponsFound",this.inboxCouponsFound),this.inboxCouponsSettingsTitle=t.GetString("inboxCouponsSettingsTitle",this.inboxCouponsSettingsTitle),this.newCoupon=t.GetString("newCoupon",this.newCoupon),this.retailerSentYouThisCoupon=t.GetString("retailerSentYouThisCoupon",this.retailerSentYouThisCoupon),this.retailerSentYouZeroCoupon=t.GetString("retailerSentYouZeroCoupon",this.retailerSentYouZeroCoupon),this.retailerSentYouOneCoupon=t.GetString("retailerSentYouOneCoupon",this.retailerSentYouOneCoupon),this.retailerSentYouNCoupons=t.GetString("retailerSentYouNCoupons",this.retailerSentYouNCoupons),this.retailerSentYouOneRecentCoupon=t.GetString("retailerSentYouOneRecentCoupon",this.retailerSentYouOneRecentCoupon),this.retailerSentYouNRecentCoupons=t.GetString("retailerSentYouNRecentCoupons",this.retailerSentYouNRecentCoupons),this.couponsCount=t.GetString("couponsCount",this.couponsCount),this.recentCoupons=t.GetString("recentCoupons",this.recentCoupons),this.noCouponsFound=t.GetString("noCouponsFound",this.noCouponsFound),this.inboxRetailerHasCoupons=t.GetString("inboxRetailerHasCoupons",this.inboxRetailerHasCoupons),this.emailConnectedToDifferentUserError=t.GetString("emailConnectedToDifferentUserError",this.emailConnectedToDifferentUserError),this.userHasDifferentEmailError=t.GetString("userHasDifferentEmailError",this.userHasDifferentEmailError),this.emailBlockedError=t.GetString("emailBlockedError",this.emailBlockedError),this.switchToAnotherPersonalProfile=t.GetString("switchToAnotherPersonalProfile",this.switchToAnotherPersonalProfile),this.reconnectedDifferentEmailTitle=t.GetString("reconnectedDifferentEmailTitle",this.reconnectedDifferentEmailTitle),this.orReconnectEmailAction=t.GetString("orReconnectEmailAction",this.orReconnectEmailAction),this.disconnectYourCurrentInbox=t.GetString("disconnectYourCurrentInbox",this.disconnectYourCurrentInbox),this.reconnectWithYourEmailProvider=t.GetString("reconnectWithYourEmailProvider",this.reconnectWithYourEmailProvider),this.previouslyConnectedEmail=t.GetString("previouslyConnectedEmail",this.previouslyConnectedEmail),this.inboxCouponsLoginCardDescription=t.GetString("inboxCouponsLoginCardDescription",this.inboxCouponsLoginCardDescription),this.inboxCouponsConnect=t.GetString("inboxCouponsConnect",this.inboxCouponsConnect),this.inboxCouponsMicrosoftLoginButtonText=t.GetString("inboxCouponsMicrosoftLoginButtonText",this.inboxCouponsMicrosoftLoginButtonText),this.inboxCouponsGoogleLoginButtonText=t.GetString("inboxCouponsGoogleLoginButtonText",this.inboxCouponsGoogleLoginButtonText),this.outlookLogo=t.GetString("outlookLogo",this.outlookLogo),this.gmailLogo=t.GetString("gmailLogo",this.gmailLogo),this.noInboxCouponsTitle=t.GetString("noInboxCouponsTitle",this.noInboxCouponsTitle),this.inboxCouponsVerifiedRetailersLearn=t.GetString("inboxCouponsVerifiedRetailersLearn",this.inboxCouponsVerifiedRetailersLearn),this.noInboxCouponsSendersDescription=t.GetString("noInboxCouponsSendersDescription",this.noInboxCouponsSendersDescription),this.accessRevokedInboxCouponsTitle=t.GetString("accessRevokedInboxCouponsTitle",this.accessRevokedInboxCouponsTitle),this.loadingInboxCoupons=t.GetString("loadingInboxCoupons",this.loadingInboxCoupons),this.loadedInboxCoupons=t.GetString("loadedInboxCoupons",this.loadedInboxCoupons),this.inboxCouponsForEdgeUsersOnly=t.GetString("inboxCouponsForEdgeUsersOnly",this.inboxCouponsForEdgeUsersOnly),this.edgeWorkProfileError=t.GetString("edgeWorkProfileError",this.edgeWorkProfileError),this.switchingToEdgePersonalProfile=t.GetString("switchingToEdgePersonalProfile",this.switchingToEdgePersonalProfile),this.addEdgeProfile=t.GetString("addEdgeProfile",this.addEdgeProfile),this.inboxCouponsEmailSenderSingular=t.GetString("inboxCouponsEmailSenderSingular",this.inboxCouponsEmailSenderSingular),this.inboxCouponsEmailSenderPlural=t.GetString("inboxCouponsEmailSenderPlural",this.inboxCouponsEmailSenderPlural),this.inboxCouponsRetailerHasEmailSenders=t.GetString("inboxCouponsRetailerHasEmailSenders",this.inboxCouponsRetailerHasEmailSenders),this.comingSoon=t.GetString("comingSoon",this.comingSoon),this.readingFromRetailerDomainEnabled=t.GetString("readingFromRetailerDomainEnabled",this.readingFromRetailerDomainEnabled),this.readingFromRetailerDomainDisabled=t.GetString("readingFromRetailerDomainDisabled",this.readingFromRetailerDomainDisabled),this.showRetailerCoupons=t.GetString("showRetailerCoupons",this.showRetailerCoupons),this.showRetailerEmailSenders=t.GetString("showRetailerEmailSenders",this.showRetailerEmailSenders),this.settings=t.GetString("settings",this.settings),this.goToInboxCouponsSettingsTitle=t.GetString("goToInboxCouponsSettingsTitle",this.goToInboxCouponsSettingsTitle),this.actionRequiredInSettingsTitle=t.GetString("actionRequiredInSettingsTitle",this.actionRequiredInSettingsTitle),this.goBackToCouponsTitle=t.GetString("goBackToCouponsTitle",this.goBackToCouponsTitle),this.disconnect=t.GetString("disconnect",this.disconnect),this.cancel=t.GetString("cancel",this.cancel),this.connect=t.GetString("connect",this.connect),this.reconnect=t.GetString("reconnect",this.reconnect),this.performActionOnInbox=t.GetString("performActionOnInbox",this.performActionOnInbox),this.previouslyLinkedToEmailAddress=t.GetString("previouslyLinkedToEmailAddress",this.previouslyLinkedToEmailAddress),this.performActionOnDifferentEmailAddress=t.GetString("performActionOnDifferentEmailAddress",this.performActionOnDifferentEmailAddress),this.performOneOfTwoActionsOnInbox=t.GetString("performOneOfTwoActionsOnInbox",this.performOneOfTwoActionsOnInbox),this.disconnectInboxDialogTitle=t.GetString("disconnectInboxDialogTitle",this.disconnectInboxDialogTitle),this.disconnectInboxDialogDescription=t.GetString("disconnectInboxDialogDescription",this.disconnectInboxDialogDescription),this.disconnectInboxErrorMsg=t.GetString("disconnectInboxErrorMsg",this.disconnectInboxErrorMsg),this.inboxCouponsCountFound=t.GetString("inboxCouponsCountFound",this.inboxCouponsCountFound),this.inboxCouponsAccessRevoked=t.GetString("inboxCouponsAccessRevoked",this.inboxCouponsAccessRevoked),this.retailSendersInInboxTitle=t.GetString("retailSendersInInboxTitle",this.retailSendersInInboxTitle),this.noRetailerSendersInInboxTitle=t.GetString("noRetailerSendersInInboxTitle",this.noRetailerSendersInInboxTitle),this.retailSendersInInboxDescription=t.GetString("retailSendersInInboxDescription",this.retailSendersInInboxDescription),this.retailersTitleWithNum=t.GetString("retailersTitleWithNum",this.retailersTitleWithNum),this.googleAPIServicesUserDataPolicy=t.GetString("googleAPIServicesUserDataPolicy",this.googleAPIServicesUserDataPolicy),this.inboxCouponsSignInConsentMessage=t.GetString("inboxCouponsSignInConsentMessage",this.inboxCouponsSignInConsentMessage),this.inboxCouponsGmailSignInConsentMessage=t.GetString("inboxCouponsGmailSignInConsentMessage",this.inboxCouponsGmailSignInConsentMessage),this.inboxCouponsEdgeLoginFooterMessage=t.GetString("inboxCouponsEdgeLoginFooterMessage",this.inboxCouponsEdgeLoginFooterMessage),this.newInboxCouponFound=t.GetString("newInboxCouponFound",this.newInboxCouponFound),this.connectedEmailSettings=t.GetString("connectedEmailSettings",this.connectedEmailSettings),this.inboxCouponsTabSwitched=t.GetString("inboxCouponsTabSwitched",this.inboxCouponsTabSwitched),this.needHelpTitle=t.GetString("needHelpTitle",this.needHelpTitle),this.feedbackForm=t.GetString("feedbackForm",this.feedbackForm),this.inboxCouponNeedHelpDescription=t.GetString("inboxCouponNeedHelpDescription",this.inboxCouponNeedHelpDescription),this.inboxCouponsUpsellCard=t.GetString("inboxCouponsUpsellCard",this.inboxCouponsUpsellCard),this.inboxCouponsReloadCoupons=t.GetString("inboxCouponsReloadCoupons",this.inboxCouponsReloadCoupons),this.inboxCouponsReloadingCoupons=t.GetString("inboxCouponsReloadingCoupons",this.inboxCouponsReloadingCoupons),this.inboxCouponsReloadedCoupons=t.GetString("inboxCouponsReloadedCoupons",this.inboxCouponsReloadedCoupons),this.emailProviderMicrosoft=t.GetString("emailProviderMicrosoft",this.emailProviderMicrosoft),this.emailProviderGmail=t.GetString("emailProviderGmail",this.emailProviderGmail),this.next=t.GetString("next",this.next),this.previous=t.GetString("previous",this.previous),this.doNotMissSavingsTitle=t.GetString("doNotMissSavingsTitle",this.doNotMissSavingsTitle),this.doNotMissSavingsDescription=t.GetString("doNotMissSavingsDescription",this.doNotMissSavingsDescription),this.personalEmailsAreNeverScannedTitle=t.GetString("personalEmailsAreNeverScannedTitle",this.personalEmailsAreNeverScannedTitle),this.personalEmailsAreNeverScannedDescription=t.GetString("personalEmailsAreNeverScannedDescription",this.personalEmailsAreNeverScannedDescription),this.autoApplyCouponsAtCheckoutTitle=t.GetString("autoApplyCouponsAtCheckoutTitle",this.autoApplyCouponsAtCheckoutTitle),this.autoApplyCouponsAtCheckoutDescription=t.GetString("autoApplyCouponsAtCheckoutDescription",this.autoApplyCouponsAtCheckoutDescription),this.searchForCoupons=t.GetString("searchForCoupons",this.searchForCoupons),this.connectingEmail=t.GetString("connectingEmail",this.connectingEmail),this.seeOtherRetailers=t.GetString("seeOtherRetailers",this.seeOtherRetailers),this.disconnectionFailed=t.GetString("disconnectionFailed",this.disconnectionFailed),this.signInFailed=t.GetString("signInFailed",this.signInFailed),this.copyInboxCoupon=t.GetString("copyInboxCoupon",this.copyInboxCoupon),this.copiedInboxCoupon=t.GetString("copiedInboxCoupon",this.copiedInboxCoupon),this.trendingCouponsTitle=t.GetString("trendingCouponsTitle",this.trendingCouponsTitle),this.trendingCouponsTopLine=t.GetString("trendingCouponsTopLine",this.trendingCouponsTopLine),this.trendingCouponsSeeMore=t.GetString("trendingCouponsSeeMore",this.trendingCouponsSeeMore),this.trendingCouponsNavigateToRetailerSite=t.GetString("trendingCouponsNavigateToRetailerSite",this.trendingCouponsNavigateToRetailerSite),this.dealDays=t.GetString("dealDays",this.dealDays),this.dealDaysDetailsText=t.GetString("dealDaysDetailsText",this.dealDaysDetailsText),this.dealDaysTimeRangeText=t.GetString("dealDaysTimeRangeText",this.dealDaysTimeRangeText),this.dealDaysAriaAwarenesses=t.GetString("dealDaysAriaAwarenesses",this.dealDaysAriaAwarenesses),this.dealDaysAllDeals=t.GetString("dealDaysAllDeals",this.dealDaysAllDeals),this.dealDaysSeeAllDeals=t.GetString("dealDaysSeeAllDeals",this.dealDaysSeeAllDeals),this.dealDaysExclusive=t.GetString("dealDaysExclusive",this.dealDaysExclusive),this.dealDaysCashbackDiscount=t.GetString("dealDaysCashbackDiscount",this.dealDaysCashbackDiscount),this.dealDaysCouponDiscount=t.GetString("dealDaysCouponDiscount",this.dealDaysCouponDiscount),this.dealDaysMultiDiscount=t.GetString("dealDaysMultiDiscount",this.dealDaysMultiDiscount),this.dealDayTimePrefixCompact=t.GetString("dealDayTimePrefixCompact",this.dealDayTimePrefixCompact),this.dealDayTimePrefix=t.GetString("dealDayTimePrefix",this.dealDayTimePrefix),this.dealDaysAwarenessTitle=t.GetString("dealDaysAwarenessTitle",this.dealDaysAwarenessTitle),this.dealDaysAwarenessSubtitle=t.GetString("dealDaysAwarenessSubtitle",this.dealDaysAwarenessSubtitle),this.wishlistTitle=t.GetString("wishlistTitle",this.wishlistTitle),this.wishlistCollectionTitle=t.GetString("wishlistCollectionTitle",this.wishlistCollectionTitle),this.wishlistUnsave=t.GetString("wishlistUnsave",this.wishlistUnsave),this.wishlistViewAll=t.GetString("wishlistViewAll",this.wishlistViewAll),this.wishlistUnsaveAltText=t.GetString("wishlistUnsaveAltText",this.wishlistUnsaveAltText),this.wishlistSaveAltText=t.GetString("wishlistSaveAltText",this.wishlistSaveAltText),this.trendingRecHeader=t.GetString("trendingRecHeader",this.trendingRecHeader),this.trendingRecSubtitle=t.GetString("trendingRecSubtitle",this.trendingRecSubtitle),this.trendingRecSectionTitle=t.GetString("trendingRecSectionTitle",this.trendingRecSectionTitle),this.trendingRecButton=t.GetString("trendingRecButton",this.trendingRecButton),this.sanConsentFeatureName=t.GetString("sanConsentFeatureName",this.sanConsentFeatureName),this.sanConsentHeaderTopText=t.GetString("sanConsentHeaderTopText",this.sanConsentHeaderTopText),this.sanConsentHeaderBottomText=t.GetString("sanConsentHeaderBottomText",this.sanConsentHeaderBottomText),this.sanConsentHeaderBottomTextV2=t.GetString("sanConsentHeaderBottomTextV2",this.sanConsentHeaderBottomTextV2),this.sanConsentHeaderBottomTextEU=t.GetString("sanConsentHeaderBottomTextEU",this.sanConsentHeaderBottomTextEU),this.sanConsentBodyTopText=t.GetString("sanConsentBodyTopText",this.sanConsentBodyTopText),this.sanConsentButton=t.GetString("sanConsentButton",this.sanConsentButton),this.sanConsentButtonV2=t.GetString("sanConsentButtonV2",this.sanConsentButtonV2),this.sanConsentSuccessString=t.GetString("sanConsentSuccessString",this.sanConsentSuccessString),this.sanConsentAcceptButton=t.GetString("sanConsentAcceptButton",this.sanConsentAcceptButton),this.sanConsentRejectButton=t.GetString("sanConsentRejectButton",this.sanConsentRejectButton),this.sanConsentActivatedText=t.GetString("sanConsentActivatedText",this.sanConsentActivatedText),this.sanConsentSeeMoreOffers=t.GetString("sanConsentSeeMoreOffers",this.sanConsentSeeMoreOffers),this.sanConsentHeaderTopTextNotification=t.GetString("sanConsentHeaderTopTextNotification",this.sanConsentHeaderTopTextNotification),this.sanConsentHeaderTopTextNotifPostPurchase=t.GetString("sanConsentHeaderTopTextNotifPostPurchase",this.sanConsentHeaderTopTextNotifPostPurchase),this.minutesAgo=t.GetString("minutesAgo",this.minutesAgo),this.hourAgo=t.GetString("hourAgo",this.hourAgo),this.hoursAgo=t.GetString("hoursAgo",this.hoursAgo),this.daysAgo=t.GetString("daysAgo",this.daysAgo),this.cbOK=t.GetString("cbOK",this.cbOK),this.cbPurchase=t.GetString("cbPurchase",this.cbPurchase),this.cbGetCashback=t.GetString("cbGetCashback",this.cbGetCashback),this.cbNext=t.GetString("cbNext",this.cbNext),this.cbEasyTitle=t.GetString("cbEasyTitle",this.cbEasyTitle),this.cbShop=t.GetString("cbShop",this.cbShop),this.cbEarn=t.GetString("cbEarn",this.cbEarn),this.cbStep=t.GetString("cbStep",this.cbStep),this.snoozeAllNotifications=t.GetString("snoozeAllNotifications",this.snoozeAllNotifications),this.snoozeAllNotificationsTooltip=t.GetString("snoozeAllNotificationsTooltip",this.snoozeAllNotificationsTooltip),this.snoozeDomainNotifications=t.GetString("snoozeDomainNotifications",this.snoozeDomainNotifications),this.snoozeDomainNotificationsTooltip=t.GetString("snoozeDomainNotificationsTooltip",this.snoozeDomainNotificationsTooltip),this.snoozeOneDomainNotification=t.GetString("snoozeOneDomainNotification",this.snoozeOneDomainNotification),this.snoozeOneDomainNotificationTooltip=t.GetString("snoozeOneDomainNotificationTooltip",this.snoozeOneDomainNotificationTooltip),this.cjkExpiryDate=t.GetString("cjkCouponsExpiryDate",this.cjkExpiryDate),this.cjkClaim=t.GetString("cjkClaim",this.cjkClaim),this.cjkSimilarProductsSectionTitle=t.GetString("cjkSimilarProducts",this.cjkSimilarProductsSectionTitle),this.cjkPHDaysLowest=t.GetString("cjkPHDaysLowest",this.cjkPHDaysLowest),this.cjkPHTimeDurSixMonth=t.GetString("cjkPHTimeDurSixMonth",this.cjkPHTimeDurSixMonth),this.cjkPHTimeDurThreeMonth=t.GetString("cjkPHTimeDurThreeMonth",this.cjkPHTimeDurThreeMonth),this.cjkPHTimeDurOneMonth=t.GetString("cjkPHTimeDurOneMonth",this.cjkPHTimeDurOneMonth),this.cjkPaneNullStateMessage=t.GetString("cjkPaneNullStateMessage",this.cjkPaneNullStateMessage),this.cjkOpenHubIconName=t.GetString("cjkOpenHubIconName",this.cjkOpenHubIconName),this.cjkHoverButtonShowFlyoutName=t.GetString("cjkHoverButtonShowFlyoutName",this.cjkHoverButtonShowFlyoutName),this.cjkFlyoutCouponsSectionTitle=t.GetString("cjkFlyoutCouponsSectionTitle",this.cjkFlyoutCouponsSectionTitle),this.cjkNullSatateDescription=t.GetString("cjkNullSatateDescription",this.cjkNullSatateDescription),this.cjkHighestPrice=t.GetString("cjkHighestPrice",this.cjkHighestPrice),this.cjkPriceLowerThanUsual=t.GetString("cjkPriceLowerThanUsual",this.cjkPriceLowerThanUsual),this.cjkSeePriceHistory=t.GetString("cjkSeePriceHistory",this.cjkSeePriceHistory),this.cjkGetCoupon=t.GetString("cjkGetCoupon",this.cjkGetCoupon),this.cjkSaveWithCoupon=t.GetString("cjkSaveWithCoupon",this.cjkSaveWithCoupon),this.cjkPriceDrop=t.GetString("cjkPriceDrop",this.cjkPriceDrop),this.cjkCouponFound=t.GetString("cjkCouponFound",this.cjkCouponFound),this.triviaCashbackSavers=t.GetString("triviaCashbackSavers",this.triviaCashbackSavers),this.triviaCashbackSavings=t.GetString("triviaCashbackSavings",this.triviaCashbackSavings),this.triviaCashbackAvrDailySavings=t.GetString("triviaCashbackAvrDailySavings",this.triviaCashbackAvrDailySavings),this.triviaCouponsSavers=t.GetString("triviaCouponsSavers",this.triviaCouponsSavers),this.triviaCouponsSavings=t.GetString("triviaCouponsSavings",this.triviaCouponsSavings),this.triviaCouponsAvrDailySavings=t.GetString("triviaCouponsAvrDailySavings",this.triviaCouponsAvrDailySavings),this.loadingSpinnerText=t.GetString("loadingSpinnerText",this.loadingSpinnerText),this.travelCheaperFlightsFeatureName=t.GetString("travelCheaperFlightsFeatureName",this.travelCheaperFlightsFeatureName),this.travelCheaperFlightsTitle=t.GetString("travelCheaperFlightsTitle",this.travelCheaperFlightsTitle),this.travelCheaperHotelsFeatureName=t.GetString("travelCheaperHotelsFeatureName",this.travelCheaperHotelsFeatureName),this.travel=t.GetString("travel",this.travel),this.travel1Stop=t.GetString("travel1Stop",this.travel1Stop),this.travelBookNow=t.GetString("travelBookNow",this.travelBookNow),this.travelBookOn=t.GetString("travelBookOn",this.travelBookOn),this.travelBookThisFlight=t.GetString("travelBookThisFlight",this.travelBookThisFlight),this.travelCheaperDealsForYou=t.GetString("travelCheaperDealsForYou",this.travelCheaperDealsForYou),this.travelFor1Adult=t.GetString("travelFor1Adult",this.travelFor1Adult),this.travelForNAdults=t.GetString("travelForNAdults",this.travelForNAdults),this.travelNonStop=t.GetString("travelNonStop",this.travelNonStop),this.travelNStops=t.GetString("travelNStops",this.travelNStops),this.travelOneWay=t.GetString("travelOneWay",this.travelOneWay),this.travelRoundTrip=t.GetString("travelRoundTrip",this.travelRoundTrip),this.travelSave=t.GetString("travelSave",this.travelSave),this.travelSaveUpto=t.GetString("travelSaveUpto",this.travelSaveUpto),this.travelMoreOptions=t.GetString("travelMoreOptions",this.travelMoreOptions),this.travelWeFoundTheBestFlightForYou=t.GetString("travelWeFoundTheBestFlightForYou",this.travelWeFoundTheBestFlightForYou),this.travelGetSameFlightAtCheaperPrice=t.GetString("travelGetSameFlightAtCheaperPrice",this.travelGetSameFlightAtCheaperPrice),this.travelGetDeal=t.GetString("travelGetDeal",this.travelGetDeal),this.travelAd=t.GetString("travelAd",this.travelAd),this.travel1Adult=t.GetString("travel1Adult",this.travel1Adult),this.travelNAdults=t.GetString("travelNAdults",this.travelNAdults),this.travelBookWith=t.GetString("travelBookWith",this.travelBookWith),this.travelFor1Night=t.GetString("travelFor1Night",this.travelFor1Night),this.travelForNNights=t.GetString("travelForNNights",this.travelForNNights),this.travelGetBetterDealOn=t.GetString("travelGetBetterDealOn",this.travelGetBetterDealOn),this.travelGetDealNow=t.GetString("travelGetDealNow",this.travelGetDealNow),this.travelPerRoomPerNight=t.GetString("travelPerRoomPerNight",this.travelPerRoomPerNight),this.travel1Room=t.GetString("travel1Room",this.travel1Room),this.travelNRooms=t.GetString("travelNRooms",this.travelNRooms),this.percentage_pricedrop_key=t.GetString("percentage_pricedrop_key",this.percentage_pricedrop_key),this.percentage_pricedrop_long_key=t.GetString("percentage_pricedrop_long_key",this.percentage_pricedrop_long_key),this.percentage_off_key=t.GetString("percentage_off_key",this.percentage_off_key),this.curbsidepickup=t.GetString("curbsidepickup",this.curbsidepickup),this.gooddealsdecoration=t.GetString("gooddealsdecoration",this.gooddealsdecoration),this.highly_rated_key=t.GetString("highly_rated_key",this.highly_rated_key),this.refurbished=t.GetString("refurbished",this.refurbished),this.remanufactured=t.GetString("remanufactured",this.remanufactured),this.used=t.GetString("used",this.used),this.popular=t.GetString("popular",this.popular),this.popular_decoration_key=t.GetString("popular_decoration_key",this.popular_decoration_key),this.pricedecorationsaletag=t.GetString("pricedecorationsaletag",this.pricedecorationsaletag),this.sustainablebrands=t.GetString("sustainablebrands",this.sustainablebrands),this.sustainable_key=t.GetString("sustainable_key",this.sustainable_key),this.trending=t.GetString("trending",this.trending),this.trending_decoration_key=t.GetString("trending_decoration_key",this.trending_decoration_key),this.free_shipping=t.GetString("free_shipping",this.free_shipping),this.postPurchaseRewardsFeatureName=t.GetString("postPurchaseRewardsFeatureName",this.postPurchaseRewardsFeatureName),this.postPurchaseRewardsTitlePrefix=t.GetString("postPurchaseRewardsTitlePrefix",this.postPurchaseRewardsTitlePrefix),this.postPurchaseRewardsTitleMiddle=t.GetString("postPurchaseRewardsTitleMiddle",this.postPurchaseRewardsTitleMiddle),this.postPurchaseRewardsSubtitleSuffix=t.GetString("postPurchaseRewardsSubtitleSuffix",this.postPurchaseRewardsSubtitleSuffix),this.postPurchaseRewardsButtonText=t.GetString("postPurchaseRewardsButtonText",this.postPurchaseRewardsButtonText),this.filterNoDataErrorMessage=t.GetString("filterNoDataErrorMessage",this.filterNoDataErrorMessage),this.copyCouponDisclosureText=t.GetString("copyCouponDisclosureText",this.copyCouponDisclosureText)}}(0,s.Z)(Xt,"CbReceiveCashBackTitle","cbReceiveCashBackTitle");var Jt=Xt,Qt=class{constructor(){(0,s.Z)(this,"IsV2Data",void 0)}IsServerData(){return this.IsV2Data}},ei=class extends Qt{constructor(){super(),this.IsV2Data=!1}GetLoadTimeDataValue(e,t){try{return loadTimeData.valueExists(e)?loadTimeData.getValue(e):t}catch(e){}return t}GetString(e,t){try{return loadTimeData.valueExists(e)?loadTimeData.getValue(e)!==t&&this.isEnglish()?t:loadTimeData.getValue(e):t}catch(e){}return t}SetLoadTimeDataValue(e,t){}isEnglish(){const e="EmptyCouponSubTitle";return!(!loadTimeData.valueExists(e)||"We couldn't find any coupons at this time."!==loadTimeData.getValue(e))}},ti=o(72171),ii=o(45908),ni=o(2816),oi=o(2907),ri=o(2681),ai=o(18438);const si=new Map;"metadata"in Reflect||(Reflect.metadata=function(e,t){return function(i){Reflect.defineMetadata(e,t,i)}},Reflect.defineMetadata=function(e,t,i){let n=si.get(i);void 0===n&&si.set(i,n=new Map),n.set(e,t)},Reflect.getOwnMetadata=function(e,t){const i=si.get(t);if(void 0!==i)return i.get(e)});class li{constructor(e,t){this.container=e,this.key=t}instance(e){return this.registerResolver(0,e)}singleton(e){return this.registerResolver(1,e)}transient(e){return this.registerResolver(2,e)}callback(e){return this.registerResolver(3,e)}cachedCallback(e){return this.registerResolver(3,Ni(e))}aliasTo(e){return this.registerResolver(5,e)}registerResolver(e,t){const{container:i,key:n}=this;return this.container=this.key=void 0,i.registerResolver(n,new Si(n,e,t))}}function ci(e){const t=e.slice(),i=Object.keys(e),n=i.length;let o;for(let r=0;r<n;++r)o=i[r],$i(o)||(t[o]=e[o]);return t}const di=Object.freeze({none(e){throw Error(`${e.toString()} not registered, did you forget to add @singleton()?`)},singleton(e){return new Si(e,1,e)},transient(e){return new Si(e,2,e)}}),ui=Object.freeze({default:Object.freeze({parentLocator:()=>null,responsibleForOwnerRequests:!1,defaultResolver:di.singleton})}),hi=new Map;function pi(e){return t=>Reflect.getOwnMetadata(e,t)}let gi=null;const fi=Object.freeze({createContainer(e){return new Di(null,Object.assign({},ui.default,e))},findResponsibleContainer(e){const t=e.$$container$$;return t&&t.responsibleForOwnerRequests?t:fi.findParentContainer(e)},findParentContainer(e){const t=new CustomEvent(ki,{bubbles:!0,composed:!0,cancelable:!0,detail:{container:void 0}});return e.dispatchEvent(t),t.detail.container||fi.getOrCreateDOMContainer()},getOrCreateDOMContainer(e,t){return e?e.$$container$$||new Di(e,Object.assign({},ui.default,t,{parentLocator:fi.findParentContainer})):gi||(gi=new Di(null,Object.assign({},ui.default,t,{parentLocator:()=>null})))},getDesignParamtypes:pi("design:paramtypes"),getAnnotationParamtypes:pi("di:paramtypes"),getOrCreateAnnotationParamTypes(e){let t=this.getAnnotationParamtypes(e);return void 0===t&&Reflect.defineMetadata("di:paramtypes",t=[],e),t},getDependencies(e){let t=hi.get(e);if(void 0===t){const i=e.inject;if(void 0===i){const i=fi.getDesignParamtypes(e),n=fi.getAnnotationParamtypes(e);if(void 0===i)if(void 0===n){const i=Object.getPrototypeOf(e);t="function"==typeof i&&i!==Function.prototype?ci(fi.getDependencies(i)):[]}else t=ci(n);else if(void 0===n)t=ci(i);else{t=ci(i);let e,o=n.length;for(let i=0;i<o;++i)e=n[i],void 0!==e&&(t[i]=e);const r=Object.keys(n);let a;o=r.length;for(let e=0;e<o;++e)a=r[e],$i(a)||(t[a]=n[a])}}else t=ci(i);hi.set(e,t)}return t},defineProperty(e,t,i,n=!1){const o=`$di_${t}`;Reflect.defineProperty(e,t,{get:function(){let e=this[o];if(void 0===e){const r=this instanceof HTMLElement?fi.findResponsibleContainer(this):fi.getOrCreateDOMContainer();if(e=r.get(i),this[o]=e,n&&this instanceof ni.H){const n=this.$fastController,r=()=>{fi.findResponsibleContainer(this).get(i)!==this[o]&&(this[o]=e,n.notify(t))};n.subscribe({handleChange:r},"isConnected")}}return e}})},createInterface(e,t){const i="function"==typeof e?e:t,n="string"==typeof e?e:e&&"friendlyName"in e&&e.friendlyName||Bi,o="string"!=typeof e&&(e&&"respectConnection"in e&&e.respectConnection||!1),r=function(e,t,i){if(null==e||void 0!==new.target)throw new Error(`No registration for interface: '${r.friendlyName}'`);t?fi.defineProperty(e,t,r,o):fi.getOrCreateAnnotationParamTypes(e)[i]=r};return r.$isInterface=!0,r.friendlyName=null==n?"(anonymous)":n,null!=i&&(r.register=function(e,t){return i(new li(e,null!=t?t:r))}),r.toString=function(){return`InterfaceSymbol<${r.friendlyName}>`},r},inject(...e){return function(t,i,n){if("number"==typeof n){const i=fi.getOrCreateAnnotationParamTypes(t),o=e[0];void 0!==o&&(i[n]=o)}else if(i)fi.defineProperty(t,i,e[0]);else{const i=n?fi.getOrCreateAnnotationParamTypes(n.value):fi.getOrCreateAnnotationParamTypes(t);let o;for(let t=0;t<e.length;++t)o=e[t],void 0!==o&&(i[t]=o)}}},transient(e){return e.register=function(t){return Ri.transient(e,e).register(t)},e.registerInRequestor=!1,e},singleton(e,t=yi){return e.register=function(t){return Ri.singleton(e,e).register(t)},e.registerInRequestor=t.scoped,e}}),mi=fi.createInterface("Container");function vi(e){return function(t){const i=function(e,t,n){fi.inject(i)(e,t,n)};return i.$isResolver=!0,i.resolve=function(i,n){return e(t,i,n)},i}}fi.inject;const yi={scoped:!1};function Ci(e,t,i){fi.inject(Ci)(e,t,i)}function bi(e,t){return t.getFactory(e).construct(t)}vi(((e,t,i)=>()=>i.get(e))),vi(((e,t,i)=>i.has(e,!0)?i.get(e):void 0)),Ci.$isResolver=!0,Ci.resolve=()=>{},vi(((e,t,i)=>{const n=bi(e,t),o=new Si(e,0,n);return i.registerResolver(e,o),n})),vi(((e,t,i)=>bi(e,t)));class Si{constructor(e,t,i){this.key=e,this.strategy=t,this.state=i,this.resolving=!1}get $isResolver(){return!0}register(e){return e.registerResolver(this.key,this)}resolve(e,t){switch(this.strategy){case 0:return this.state;case 1:if(this.resolving)throw new Error(`Cyclic dependency found: ${this.state.name}`);return this.resolving=!0,this.state=e.getFactory(this.state).construct(t),this.strategy=0,this.resolving=!1,this.state;case 2:{const i=e.getFactory(this.state);if(null===i)throw new Error(`Resolver for ${String(this.key)} returned a null factory`);return i.construct(t)}case 3:return this.state(e,t,this);case 4:return this.state[0].resolve(e,t);case 5:return t.get(this.state);default:throw new Error(`Invalid resolver strategy specified: ${this.strategy}.`)}}getFactory(e){var t,i,n;switch(this.strategy){case 1:case 2:return e.getFactory(this.state);case 5:return null!==(n=null===(i=null===(t=e.getResolver(this.state))||void 0===t?void 0:t.getFactory)||void 0===i?void 0:i.call(t,e))&&void 0!==n?n:null;default:return null}}}function xi(e){return this.get(e)}function Ti(e,t){return t(e)}class wi{constructor(e,t){this.Type=e,this.dependencies=t,this.transformers=null}construct(e,t){let i;return i=void 0===t?new this.Type(...this.dependencies.map(xi,e)):new this.Type(...this.dependencies.map(xi,e),...t),null==this.transformers?i:this.transformers.reduce(Ti,i)}registerTransformer(e){(this.transformers||(this.transformers=[])).push(e)}}const Oi={$isResolver:!0,resolve(e,t){return t}};function Pi(e){return"function"==typeof e.register}function Ai(e){return function(e){return Pi(e)&&"boolean"==typeof e.registerInRequestor}(e)&&e.registerInRequestor}const Ei=new Set(["Array","ArrayBuffer","Boolean","DataView","Date","Error","EvalError","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Number","Object","Promise","RangeError","ReferenceError","RegExp","Set","SharedArrayBuffer","String","SyntaxError","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","URIError","WeakMap","WeakSet"]),ki="__DI_LOCATE_PARENT__",Ii=new Map;class Di{constructor(e,t){this.owner=e,this.config=t,this._parent=void 0,this.registerDepth=0,this.context=null,null!==e&&(e.$$container$$=this),this.resolvers=new Map,this.resolvers.set(mi,Oi),e instanceof Node&&e.addEventListener(ki,(e=>{e.composedPath()[0]!==this.owner&&(e.detail.container=this,e.stopImmediatePropagation())}))}get parent(){return void 0===this._parent&&(this._parent=this.config.parentLocator(this.owner)),this._parent}get depth(){return null===this.parent?0:this.parent.depth+1}get responsibleForOwnerRequests(){return this.config.responsibleForOwnerRequests}registerWithContext(e,...t){return this.context=e,this.register(...t),this.context=null,this}register(...e){if(100==++this.registerDepth)throw new Error("Unable to autoregister dependency");let t,i,n,o,r;const a=this.context;for(let s=0,l=e.length;s<l;++s)if(t=e[s],Fi(t))if(Pi(t))t.register(this,a);else if(void 0!==t.prototype)Ri.singleton(t,t).register(this);else for(i=Object.keys(t),o=0,r=i.length;o<r;++o)n=t[i[o]],Fi(n)&&(Pi(n)?n.register(this,a):this.register(n));return--this.registerDepth,this}registerResolver(e,t){Mi(e);const i=this.resolvers,n=i.get(e);return null==n?i.set(e,t):n instanceof Si&&4===n.strategy?n.state.push(t):i.set(e,new Si(e,4,[n,t])),t}registerTransformer(e,t){const i=this.getResolver(e);if(null==i)return!1;if(i.getFactory){const e=i.getFactory(this);return null!=e&&(e.registerTransformer(t),!0)}return!1}getResolver(e,t=!0){if(Mi(e),void 0!==e.resolve)return e;let i,n=this;for(;null!=n;){if(i=n.resolvers.get(e),null!=i)return i;if(null==n.parent){const i=Ai(e)?this:n;return t?this.jitRegister(e,i):null}n=n.parent}return null}has(e,t=!1){return!!this.resolvers.has(e)||!(!t||null==this.parent)&&this.parent.has(e,!0)}get(e){if(Mi(e),e.$isResolver)return e.resolve(this,this);let t,i=this;for(;null!=i;){if(t=i.resolvers.get(e),null!=t)return t.resolve(i,this);if(null==i.parent){const n=Ai(e)?this:i;return t=this.jitRegister(e,n),t.resolve(i,this)}i=i.parent}throw new Error(`Unable to resolve key: ${e}`)}getAll(e,t=!1){Mi(e);const i=this;let n,o=i;if(t){let t=ai.ow;for(;null!=o;)n=o.resolvers.get(e),null!=n&&(t=t.concat(Li(n,o,i))),o=o.parent;return t}for(;null!=o;){if(n=o.resolvers.get(e),null!=n)return Li(n,o,i);if(o=o.parent,null==o)return ai.ow}return ai.ow}getFactory(e){let t=Ii.get(e);if(void 0===t){if(Ui(e))throw new Error(`${e.name} is a native function and therefore cannot be safely constructed by DI. If this is intentional, please use a callback or cachedCallback resolver.`);Ii.set(e,t=new wi(e,fi.getDependencies(e)))}return t}registerFactory(e,t){Ii.set(e,t)}createChild(e){return new Di(null,Object.assign({},this.config,e,{parentLocator:()=>this}))}jitRegister(e,t){if("function"!=typeof e)throw new Error(`Attempted to jitRegister something that is not a constructor: '${e}'. Did you forget to register this dependency?`);if(Ei.has(e.name))throw new Error(`Attempted to jitRegister an intrinsic type: ${e.name}. Did you forget to add @inject(Key)`);if(Pi(e)){const i=e.register(t);if(!(i instanceof Object)||null==i.resolve){const i=t.resolvers.get(e);if(null!=i)return i;throw new Error("A valid resolver was not returned from the static register method")}return i}if(e.$isInterface)throw new Error(`Attempted to jitRegister an interface: ${e.friendlyName}`);{const i=this.config.defaultResolver(e,t);return t.resolvers.set(e,i),i}}}const _i=new WeakMap;function Ni(e){return function(t,i,n){if(_i.has(n))return _i.get(n);const o=e(t,i,n);return _i.set(n,o),o}}const Ri=Object.freeze({instance(e,t){return new Si(e,0,t)},singleton(e,t){return new Si(e,1,t)},transient(e,t){return new Si(e,2,t)},callback(e,t){return new Si(e,3,t)},cachedCallback(e,t){return new Si(e,3,Ni(t))},aliasTo(e,t){return new Si(t,5,e)}});function Mi(e){if(null==e)throw new Error("key/value cannot be null or undefined. Are you trying to inject/register something that doesn't exist with DI?")}function Li(e,t,i){if(e instanceof Si&&4===e.strategy){const n=e.state;let o=n.length;const r=new Array(o);for(;o--;)r[o]=n[o].resolve(t,i);return r}return[e.resolve(t,i)]}const Bi="(anonymous)";function Fi(e){return"object"==typeof e&&null!==e||"function"==typeof e}const Ui=function(){const e=new WeakMap;let t=!1,i="",n=0;return function(o){return t=e.get(o),void 0===t&&(i=o.toString(),n=i.length,t=n>=29&&n<=100&&125===i.charCodeAt(n-1)&&i.charCodeAt(n-2)<=32&&93===i.charCodeAt(n-3)&&101===i.charCodeAt(n-4)&&100===i.charCodeAt(n-5)&&111===i.charCodeAt(n-6)&&99===i.charCodeAt(n-7)&&32===i.charCodeAt(n-8)&&101===i.charCodeAt(n-9)&&118===i.charCodeAt(n-10)&&105===i.charCodeAt(n-11)&&116===i.charCodeAt(n-12)&&97===i.charCodeAt(n-13)&&110===i.charCodeAt(n-14)&&88===i.charCodeAt(n-15),e.set(o,t)),t}}(),Hi={};function $i(e){switch(typeof e){case"number":return e>=0&&(0|e)===e;case"string":{const t=Hi[e];if(void 0!==t)return t;const i=e.length;if(0===i)return Hi[e]=!1;let n=0;for(let t=0;t<i;++t)if(n=e.charCodeAt(t),0===t&&48===n&&i>1||n<48||n>57)return Hi[e]=!1;return Hi[e]=!0}default:return!1}}function Zi(e){return`${e.toLowerCase()}:presentation`}const Vi=new Map,Gi=Object.freeze({define(e,t,i){const n=Zi(e);void 0===Vi.get(n)?Vi.set(n,t):Vi.set(n,!1),i.register(Ri.instance(n,t))},forTag(e,t){const i=Zi(e),n=Vi.get(i);return!1===n?fi.findResponsibleContainer(t).get(i):n||null}});class ji{constructor(e,t){this.template=e||null,this.styles=void 0===t?null:Array.isArray(t)?ri.XL.create(t):t instanceof ri.XL?t:ri.XL.create([t])}applyTo(e){const t=e.$fastController;null===t.template&&(t.template=this.template),null===t.styles&&(t.styles=this.styles)}}class zi extends ni.H{constructor(){super(...arguments),this._presentation=void 0}get $presentation(){return void 0===this._presentation&&(this._presentation=Gi.forTag(this.tagName,this)),this._presentation}templateChanged(){void 0!==this.template&&(this.$fastController.template=this.template)}stylesChanged(){void 0!==this.styles&&(this.$fastController.styles=this.styles)}connectedCallback(){null!==this.$presentation&&this.$presentation.applyTo(this),super.connectedCallback()}static compose(e){return(t={})=>new Ki(this===zi?class extends zi{}:this,e,t)}}function Wi(e,t,i){return"function"==typeof e?e(t,i):e}(0,ii.gn)([oi.LO],zi.prototype,"template",void 0),(0,ii.gn)([oi.LO],zi.prototype,"styles",void 0);class Ki{constructor(e,t,i){this.type=e,this.elementDefinition=t,this.overrideDefinition=i,this.definition=Object.assign(Object.assign({},this.elementDefinition),this.overrideDefinition)}register(e,t){const i=this.definition,n=this.overrideDefinition,o=`${i.prefix||t.elementPrefix}-${i.baseName}`;t.tryDefineElement({name:o,type:this.type,baseClass:this.elementDefinition.baseClass,callback:e=>{const t=new ji(Wi(i.template,e,i),Wi(i.styles,e,i));e.definePresentation(t);let o=Wi(i.shadowOptions,e,i);e.shadowRootMode&&(o?n.shadowOptions||(o.mode=e.shadowRootMode):null!==o&&(o={mode:e.shadowRootMode})),e.defineElement({elementOptions:Wi(i.elementOptions,e,i),shadowOptions:o,attributes:Wi(i.attributes,e,i)})}})}}var qi=o(11127);const Yi=Object.freeze({definitionCallbackOnly:null,ignoreDuplicate:Symbol()}),Xi=new Map,Ji=new Map;let Qi=null;const en=fi.createInterface((e=>e.cachedCallback((e=>(null===Qi&&(Qi=new nn(null,e)),Qi))))),tn=Object.freeze({tagFor(e){return Ji.get(e)},responsibleFor(e){const t=e.$$designSystem$$;return t||fi.findResponsibleContainer(e).get(en)},getOrCreate(e){if(!e)return null===Qi&&(Qi=fi.getOrCreateDOMContainer().get(en)),Qi;const t=e.$$designSystem$$;if(t)return t;const i=fi.getOrCreateDOMContainer(e);if(i.has(en,!1))return i.get(en);{const t=new nn(e,i);return i.register(Ri.instance(en,t)),t}}});class nn{constructor(e,t){this.owner=e,this.container=t,this.designTokensInitialized=!1,this.prefix="fast",this.shadowRootMode=void 0,this.disambiguate=()=>Yi.definitionCallbackOnly,null!==e&&(e.$$designSystem$$=this)}withPrefix(e){return this.prefix=e,this}withShadowRootMode(e){return this.shadowRootMode=e,this}withElementDisambiguation(e){return this.disambiguate=e,this}withDesignTokenRoot(e){return this.designTokenRoot=e,this}register(...e){const t=this.container,i=[],n=this.disambiguate,o=this.shadowRootMode,r={elementPrefix:this.prefix,tryDefineElement(e,r,a){const s=function(e,t,i){return"string"==typeof e?{name:e,type:t,callback:i}:e}(e,r,a),{name:l,callback:c,baseClass:d}=s;let{type:u}=s,h=l,p=Xi.get(h),g=!0;for(;p;){const e=n(h,u,p);switch(e){case Yi.ignoreDuplicate:return;case Yi.definitionCallbackOnly:g=!1,p=void 0;break;default:h=e,p=Xi.get(h)}}g&&((Ji.has(u)||u===zi)&&(u=class extends u{}),Xi.set(h,u),Ji.set(u,h),d&&Ji.set(d,h)),i.push(new on(t,h,u,o,c,g))}};this.designTokensInitialized||(this.designTokensInitialized=!0,null!==this.designTokenRoot&&qi.DesignToken.registerRoot(this.designTokenRoot)),t.registerWithContext(r,...e);for(const e of i)e.callback(e),e.willDefine&&null!==e.definition&&e.definition.define();return this}}class on{constructor(e,t,i,n,o,r){this.container=e,this.name=t,this.type=i,this.shadowRootMode=n,this.callback=o,this.willDefine=r,this.definition=null}definePresentation(e){Gi.define(this.name,e,this.container)}defineElement(e){this.definition=new ti.W(this.type,Object.assign(Object.assign({},e),{name:this.name}))}tagFor(e){return tn.tagFor(e)}}function rn(e){return tn.getOrCreate(e).withPrefix("fluent")}var an=o(85866),sn=o(77158),ln=o(85888);function cn(e,t){const i=[];let n="";const o=[];for(let r=0,a=e.length-1;r<a;++r){n+=e[r];let a=t[r];if(a instanceof ln.v){const e=a.createBehavior();a=a.createCSS(),e&&o.push(e)}a instanceof ri.XL||a instanceof CSSStyleSheet?(""!==n.trim()&&(i.push(n),n=""),i.push(a)):n+=a}return n+=e[e.length-1],""!==n.trim()&&i.push(n),{styles:i,behaviors:o}}function dn(e,...t){const{styles:i,behaviors:n}=cn(e,t),o=ri.XL.create(i);return n.length&&o.withBehaviors(...n),o}class un extends ln.v{constructor(e,t){super(),this.behaviors=t,this.css="";const i=e.reduce(((e,t)=>("string"==typeof t?this.css+=t:e.push(t),e)),[]);i.length&&(this.styles=ri.XL.create(i))}createBehavior(){return this}createCSS(){return this.css}bind(e){this.styles&&e.$fastController.addStyles(this.styles),this.behaviors.length&&e.$fastController.addBehaviors(this.behaviors)}unbind(e){this.styles&&e.$fastController.removeStyles(this.styles),this.behaviors.length&&e.$fastController.removeBehaviors(this.behaviors)}}function hn(e,...t){const{styles:i,behaviors:n}=cn(e,t);return new un(i,n)}var pn=o(5597),gn=o(98557);class fn{constructor(){this.targetIndex=0}}class mn extends fn{constructor(){super(...arguments),this.createPlaceholder=gn.SO.createInterpolationPlaceholder}}class vn extends fn{constructor(e,t,i){super(),this.name=e,this.behavior=t,this.options=i}createPlaceholder(e){return gn.SO.createCustomAttributePlaceholder(this.name,e)}createBehavior(e){return new this.behavior(e,this.options)}}function yn(e,t){this.source=e,this.context=t,null===this.bindingObserver&&(this.bindingObserver=oi.y$.binding(this.binding,this,this.isBindingVolatile)),this.updateTarget(this.bindingObserver.observe(e,t))}function Cn(e,t){this.source=e,this.context=t,this.target.addEventListener(this.targetName,this)}function bn(){this.bindingObserver.disconnect(),this.source=null,this.context=null}function Sn(){this.bindingObserver.disconnect(),this.source=null,this.context=null;const e=this.target.$fastView;void 0!==e&&e.isComposed&&(e.unbind(),e.needsBindOnly=!0)}function xn(){this.target.removeEventListener(this.targetName,this),this.source=null,this.context=null}function Tn(e){gn.SO.setAttribute(this.target,this.targetName,e)}function wn(e){gn.SO.setBooleanAttribute(this.target,this.targetName,e)}function On(e){if(null==e&&(e=""),e.create){this.target.textContent="";let t=this.target.$fastView;void 0===t?t=e.create():this.target.$fastTemplate!==e&&(t.isComposed&&(t.remove(),t.unbind()),t=e.create()),t.isComposed?t.needsBindOnly&&(t.needsBindOnly=!1,t.bind(this.source,this.context)):(t.isComposed=!0,t.bind(this.source,this.context),t.insertBefore(this.target),this.target.$fastView=t,this.target.$fastTemplate=e)}else{const t=this.target.$fastView;void 0!==t&&t.isComposed&&(t.isComposed=!1,t.remove(),t.needsBindOnly?t.needsBindOnly=!1:t.unbind()),this.target.textContent=e}}function Pn(e){this.target[this.targetName]=e}function An(e){const t=this.classVersions||Object.create(null),i=this.target;let n=this.version||0;if(null!=e&&e.length){const o=e.split(/\s+/);for(let e=0,r=o.length;e<r;++e){const r=o[e];""!==r&&(t[r]=n,i.classList.add(r))}}if(this.classVersions=t,this.version=n+1,0!==n){n-=1;for(const e in t)t[e]===n&&i.classList.remove(e)}}class En extends mn{constructor(e){super(),this.binding=e,this.bind=yn,this.unbind=bn,this.updateTarget=Tn,this.isBindingVolatile=oi.y$.isVolatileBinding(this.binding)}get targetName(){return this.originalTargetName}set targetName(e){if(this.originalTargetName=e,void 0!==e)switch(e[0]){case":":if(this.cleanedTargetName=e.substr(1),this.updateTarget=Pn,"innerHTML"===this.cleanedTargetName){const e=this.binding;this.binding=(t,i)=>gn.SO.createHTML(e(t,i))}break;case"?":this.cleanedTargetName=e.substr(1),this.updateTarget=wn;break;case"@":this.cleanedTargetName=e.substr(1),this.bind=Cn,this.unbind=xn;break;default:this.cleanedTargetName=e,"class"===e&&(this.updateTarget=An)}}targetAtContent(){this.updateTarget=On,this.unbind=Sn}createBehavior(e){return new kn(e,this.binding,this.isBindingVolatile,this.bind,this.unbind,this.updateTarget,this.cleanedTargetName)}}class kn{constructor(e,t,i,n,o,r,a){this.source=null,this.context=null,this.bindingObserver=null,this.target=e,this.binding=t,this.isBindingVolatile=i,this.bind=n,this.unbind=o,this.updateTarget=r,this.targetName=a}handleChange(){this.updateTarget(this.bindingObserver.observe(this.source,this.context))}handleEvent(e){oi.rd.setEvent(e);const t=this.binding(this.source,this.context);oi.rd.setEvent(null),!0!==t&&e.preventDefault()}}let In=null;class Dn{addFactory(e){e.targetIndex=this.targetIndex,this.behaviorFactories.push(e)}captureContentBinding(e){e.targetAtContent(),this.addFactory(e)}reset(){this.behaviorFactories=[],this.targetIndex=-1}release(){In=this}static borrow(e){const t=In||new Dn;return t.directives=e,t.reset(),In=null,t}}function _n(e){if(1===e.length)return e[0];let t;const i=e.length,n=e.map((e=>"string"==typeof e?()=>e:(t=e.targetName||t,e.binding))),o=new En(((e,t)=>{let o="";for(let r=0;r<i;++r)o+=n[r](e,t);return o}));return o.targetName=t,o}const Nn=gn.Yl.length;function Rn(e,t){const i=t.split(gn.pc);if(1===i.length)return null;const n=[];for(let t=0,o=i.length;t<o;++t){const o=i[t],r=o.indexOf(gn.Yl);let a;if(-1===r)a=o;else{const t=parseInt(o.substring(0,r));n.push(e.directives[t]),a=o.substring(r+Nn)}""!==a&&n.push(a)}return n}function Mn(e,t,i=!1){const n=t.attributes;for(let o=0,r=n.length;o<r;++o){const a=n[o],s=a.value,l=Rn(e,s);let c=null;null===l?i&&(c=new En((()=>s)),c.targetName=a.name):c=_n(l),null!==c&&(t.removeAttributeNode(a),o--,r--,e.addFactory(c))}}function Ln(e,t,i){const n=Rn(e,t.textContent);if(null!==n){let o=t;for(let r=0,a=n.length;r<a;++r){const a=n[r],s=0===r?t:o.parentNode.insertBefore(document.createTextNode(""),o.nextSibling);"string"==typeof a?s.textContent=a:(s.textContent=" ",e.captureContentBinding(a)),o=s,e.targetIndex++,s!==t&&i.nextNode()}e.targetIndex--}}const Bn=document.createRange();class Fn{constructor(e,t){this.fragment=e,this.behaviors=t,this.source=null,this.context=null,this.firstChild=e.firstChild,this.lastChild=e.lastChild}appendTo(e){e.appendChild(this.fragment)}insertBefore(e){if(this.fragment.hasChildNodes())e.parentNode.insertBefore(this.fragment,e);else{const t=this.lastChild;if(e.previousSibling===t)return;const i=e.parentNode;let n,o=this.firstChild;for(;o!==t;)n=o.nextSibling,i.insertBefore(o,e),o=n;i.insertBefore(t,e)}}remove(){const e=this.fragment,t=this.lastChild;let i,n=this.firstChild;for(;n!==t;)i=n.nextSibling,e.appendChild(n),n=i;e.appendChild(t)}dispose(){const e=this.firstChild.parentNode,t=this.lastChild;let i,n=this.firstChild;for(;n!==t;)i=n.nextSibling,e.removeChild(n),n=i;e.removeChild(t);const o=this.behaviors,r=this.source;for(let e=0,t=o.length;e<t;++e)o[e].unbind(r)}bind(e,t){const i=this.behaviors;if(this.source!==e)if(null!==this.source){const n=this.source;this.source=e,this.context=t;for(let o=0,r=i.length;o<r;++o){const r=i[o];r.unbind(n),r.bind(e,t)}}else{this.source=e,this.context=t;for(let n=0,o=i.length;n<o;++n)i[n].bind(e,t)}}unbind(){if(null===this.source)return;const e=this.behaviors,t=this.source;for(let i=0,n=e.length;i<n;++i)e[i].unbind(t);this.source=null}static disposeContiguousBatch(e){if(0!==e.length){Bn.setStartBefore(e[0].firstChild),Bn.setEndAfter(e[e.length-1].lastChild),Bn.deleteContents();for(let t=0,i=e.length;t<i;++t){const i=e[t],n=i.behaviors,o=i.source;for(let e=0,t=n.length;e<t;++e)n[e].unbind(o)}}}}class Un{constructor(e,t){this.behaviorCount=0,this.hasHostBehaviors=!1,this.fragment=null,this.targetOffset=0,this.viewBehaviorFactories=null,this.hostBehaviorFactories=null,this.html=e,this.directives=t}create(e){if(null===this.fragment){let e;const t=this.html;if("string"==typeof t){e=document.createElement("template"),e.innerHTML=gn.SO.createHTML(t);const i=e.content.firstElementChild;null!==i&&"TEMPLATE"===i.tagName&&(e=i)}else e=t;const i=function(e,t){const i=e.content;document.adoptNode(i);const n=Dn.borrow(t);Mn(n,e,!0);const o=n.behaviorFactories;n.reset();const r=gn.SO.createTemplateWalker(i);let a;for(;a=r.nextNode();)switch(n.targetIndex++,a.nodeType){case 1:Mn(n,a);break;case 3:Ln(n,a,r);break;case 8:gn.SO.isMarker(a)&&n.addFactory(t[gn.SO.extractDirectiveIndexFromMarker(a)])}let s=0;(gn.SO.isMarker(i.firstChild)||1===i.childNodes.length&&t.length)&&(i.insertBefore(document.createComment(""),i.firstChild),s=-1);const l=n.behaviorFactories;return n.release(),{fragment:i,viewBehaviorFactories:l,hostBehaviorFactories:o,targetOffset:s}}(e,this.directives);this.fragment=i.fragment,this.viewBehaviorFactories=i.viewBehaviorFactories,this.hostBehaviorFactories=i.hostBehaviorFactories,this.targetOffset=i.targetOffset,this.behaviorCount=this.viewBehaviorFactories.length+this.hostBehaviorFactories.length,this.hasHostBehaviors=this.hostBehaviorFactories.length>0}const t=this.fragment.cloneNode(!0),i=this.viewBehaviorFactories,n=new Array(this.behaviorCount),o=gn.SO.createTemplateWalker(t);let r=0,a=this.targetOffset,s=o.nextNode();for(let e=i.length;r<e;++r){const e=i[r],t=e.targetIndex;for(;null!==s;){if(a===t){n[r]=e.createBehavior(s);break}s=o.nextNode(),a++}}if(this.hasHostBehaviors){const t=this.hostBehaviorFactories;for(let i=0,o=t.length;i<o;++i,++r)n[r]=t[i].createBehavior(e)}return new Fn(t,n)}render(e,t,i){"string"==typeof t&&(t=document.getElementById(t)),void 0===i&&(i=t);const n=this.create(i);return n.bind(e,oi.Wp),n.appendTo(t),n}}const Hn=/([ \x09\x0a\x0c\x0d])([^\0-\x1F\x7F-\x9F "'>=/]+)([ \x09\x0a\x0c\x0d]*=[ \x09\x0a\x0c\x0d]*(?:[^ \x09\x0a\x0c\x0d"'`<>=]*|"[^"]*|'[^']*))$/;function $n(e,...t){const i=[];let n="";for(let o=0,r=e.length-1;o<r;++o){const r=e[o];let a=t[o];if(n+=r,a instanceof Un){const e=a;a=()=>e}if("function"==typeof a&&(a=new En(a)),a instanceof mn){const e=Hn.exec(r);null!==e&&(a.targetName=e[2])}a instanceof fn?(n+=a.createPlaceholder(i.length),i.push(a)):n+=a}return n+=e[e.length-1],new Un(n,i)}class Zn{constructor(e){this.listenerCache=new WeakMap,this.query=e}bind(e){const{query:t}=this,i=this.constructListener(e);i.bind(t)(),t.addListener(i),this.listenerCache.set(e,i)}unbind(e){const t=this.listenerCache.get(e);t&&(this.query.removeListener(t),this.listenerCache.delete(e))}}class Vn extends Zn{constructor(e,t){super(e),this.styles=t}static with(e){return t=>new Vn(e,t)}constructListener(e){let t=!1;const i=this.styles;return function(){const{matches:n}=this;n&&!t?(e.$fastController.addStyles(i),t=n):!n&&t&&(e.$fastController.removeStyles(i),t=n)}}unbind(e){super.unbind(e),e.$fastController.removeStyles(this.styles)}}const Gn=Vn.with(window.matchMedia("(forced-colors)")),jn=Vn.with(window.matchMedia("(prefers-color-scheme: dark)"));function zn(e){return`:host([hidden]){display:none}:host{display:${e}}`}var Wn;Vn.with(window.matchMedia("(prefers-color-scheme: light)")),function(e){e.Canvas="Canvas",e.CanvasText="CanvasText",e.LinkText="LinkText",e.VisitedText="VisitedText",e.ActiveText="ActiveText",e.ButtonFace="ButtonFace",e.ButtonText="ButtonText",e.Field="Field",e.FieldText="FieldText",e.Highlight="Highlight",e.HighlightText="HighlightText",e.GrayText="GrayText"}(Wn||(Wn={}));var Kn=o(79385),qn=o(23026);const Yn={toView(e){return null==e?null:null==e?void 0:e.toColorString()},fromView(e){if(null==e)return null;const t=(0,sn.in)(e);return t?Kn.w.create(t.r,t.g,t.b):null}},Xn=dn`
:host {
background-color: ${qn.IfY};
color: ${qn.CHi};
}
`.withBehaviors(Gn(dn`
:host {
background-color: ${Wn.Canvas};
box-shadow: 0 0 0 1px ${Wn.CanvasText};
color: ${Wn.CanvasText};
}
`));function Jn(e){return(t,i)=>{t[i+"Changed"]=function(t,i){null!=i?e.setValueFor(this,i):e.deleteValueFor(this)}}}class Qn extends zi{constructor(){super(),this.noPaint=!1;const e={handleChange:this.noPaintChanged.bind(this)};oi.y$.getNotifier(this).subscribe(e,"fillColor"),oi.y$.getNotifier(this).subscribe(e,"baseLayerLuminance")}connectedCallback(){super.connectedCallback(),this.noPaintChanged()}noPaintChanged(){this.noPaint||void 0===this.fillColor&&!this.baseLayerLuminance?this.$fastController.removeStyles(Xn):this.$fastController.addStyles(Xn)}}(0,an.gn)([(0,pn.Lj)({attribute:"no-paint",mode:"boolean"})],Qn.prototype,"noPaint",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"fill-color",converter:Yn,mode:"fromView"}),Jn(qn.IfY)],Qn.prototype,"fillColor",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"accent-base-color",converter:Yn,mode:"fromView"}),Jn(qn.R6v)],Qn.prototype,"accentBaseColor",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-base-color",converter:Yn,mode:"fromView"}),Jn(qn.aIT)],Qn.prototype,"neutralBaseColor",void 0),(0,an.gn)([(0,pn.Lj)({converter:pn.Id}),Jn(qn.hVk)],Qn.prototype,"density",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"design-unit",converter:pn.Id}),Jn(qn._5n)],Qn.prototype,"designUnit",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"direction"}),Jn(qn.o7V)],Qn.prototype,"direction",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"base-height-multiplier",converter:pn.Id}),Jn(qn.nfe)],Qn.prototype,"baseHeightMultiplier",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"base-horizontal-spacing-multiplier",converter:pn.Id}),Jn(qn.LQ3)],Qn.prototype,"baseHorizontalSpacingMultiplier",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"control-corner-radius",converter:pn.Id}),Jn(qn.UWU)],Qn.prototype,"controlCornerRadius",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"layer-corner-radius",converter:pn.Id}),Jn(qn.rSr)],Qn.prototype,"layerCornerRadius",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"stroke-width",converter:pn.Id}),Jn(qn.Han)],Qn.prototype,"strokeWidth",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"focus-stroke-width",converter:pn.Id}),Jn(qn.vxp)],Qn.prototype,"focusStrokeWidth",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"disabled-opacity",converter:pn.Id}),Jn(qn.VFZ)],Qn.prototype,"disabledOpacity",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"type-ramp-minus-2-font-size"}),Jn(qn.G8g)],Qn.prototype,"typeRampMinus2FontSize",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"type-ramp-minus-2-line-height"}),Jn(qn.MwG)],Qn.prototype,"typeRampMinus2LineHeight",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"type-ramp-minus-1-font-size"}),Jn(qn.sNp)],Qn.prototype,"typeRampMinus1FontSize",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"type-ramp-minus-1-line-height"}),Jn(qn.vgC)],Qn.prototype,"typeRampMinus1LineHeight",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"type-ramp-base-font-size"}),Jn(qn.cSu)],Qn.prototype,"typeRampBaseFontSize",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"type-ramp-base-line-height"}),Jn(qn.RUt)],Qn.prototype,"typeRampBaseLineHeight",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"type-ramp-plus-1-font-size"}),Jn(qn.PwC)],Qn.prototype,"typeRampPlus1FontSize",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"type-ramp-plus-1-line-height"}),Jn(qn.b3W)],Qn.prototype,"typeRampPlus1LineHeight",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"type-ramp-plus-2-font-size"}),Jn(qn.mWK)],Qn.prototype,"typeRampPlus2FontSize",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"type-ramp-plus-2-line-height"}),Jn(qn.I7_)],Qn.prototype,"typeRampPlus2LineHeight",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"type-ramp-plus-3-font-size"}),Jn(qn.ipv)],Qn.prototype,"typeRampPlus3FontSize",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"type-ramp-plus-3-line-height"}),Jn(qn.yGZ)],Qn.prototype,"typeRampPlus3LineHeight",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"type-ramp-plus-4-font-size"}),Jn(qn.IWd)],Qn.prototype,"typeRampPlus4FontSize",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"type-ramp-plus-4-line-height"}),Jn(qn.iL4)],Qn.prototype,"typeRampPlus4LineHeight",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"type-ramp-plus-5-font-size"}),Jn(qn.CXZ)],Qn.prototype,"typeRampPlus5FontSize",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"type-ramp-plus-5-line-height"}),Jn(qn.n5T)],Qn.prototype,"typeRampPlus5LineHeight",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"type-ramp-plus-6-font-size"}),Jn(qn.Zaf)],Qn.prototype,"typeRampPlus6FontSize",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"type-ramp-plus-6-line-height"}),Jn(qn.yDy)],Qn.prototype,"typeRampPlus6LineHeight",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"accent-fill-rest-delta",converter:pn.Id}),Jn(qn.N7s)],Qn.prototype,"accentFillRestDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"accent-fill-hover-delta",converter:pn.Id}),Jn(qn.B23)],Qn.prototype,"accentFillHoverDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"accent-fill-active-delta",converter:pn.Id}),Jn(qn.Woc)],Qn.prototype,"accentFillActiveDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"accent-fill-focus-delta",converter:pn.Id}),Jn(qn.v$0)],Qn.prototype,"accentFillFocusDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"accent-foreground-rest-delta",converter:pn.Id}),Jn(qn.kpA)],Qn.prototype,"accentForegroundRestDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"accent-foreground-hover-delta",converter:pn.Id}),Jn(qn.L8d)],Qn.prototype,"accentForegroundHoverDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"accent-foreground-active-delta",converter:pn.Id}),Jn(qn.kb6)],Qn.prototype,"accentForegroundActiveDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"accent-foreground-focus-delta",converter:pn.Id}),Jn(qn.ndN)],Qn.prototype,"accentForegroundFocusDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-fill-rest-delta",converter:pn.Id}),Jn(qn.MYN)],Qn.prototype,"neutralFillRestDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-fill-hover-delta",converter:pn.Id}),Jn(qn.jWw)],Qn.prototype,"neutralFillHoverDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-fill-active-delta",converter:pn.Id}),Jn(qn.hDF)],Qn.prototype,"neutralFillActiveDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-fill-focus-delta",converter:pn.Id}),Jn(qn.VQw)],Qn.prototype,"neutralFillFocusDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-fill-input-rest-delta",converter:pn.Id}),Jn(qn.efx)],Qn.prototype,"neutralFillInputRestDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-fill-input-hover-delta",converter:pn.Id}),Jn(qn.EL3)],Qn.prototype,"neutralFillInputHoverDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-fill-input-active-delta",converter:pn.Id}),Jn(qn.q_p)],Qn.prototype,"neutralFillInputActiveDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-fill-input-focus-delta",converter:pn.Id}),Jn(qn.Zbo)],Qn.prototype,"neutralFillInputFocusDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-fill-layer-rest-delta",converter:pn.Id}),Jn(qn.YL4)],Qn.prototype,"neutralFillLayerRestDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-fill-stealth-rest-delta",converter:pn.Id}),Jn(qn.qDs)],Qn.prototype,"neutralFillStealthRestDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-fill-stealth-hover-delta",converter:pn.Id}),Jn(qn.fqe)],Qn.prototype,"neutralFillStealthHoverDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-fill-stealth-active-delta",converter:pn.Id}),Jn(qn.gs2)],Qn.prototype,"neutralFillStealthActiveDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-fill-stealth-focus-delta",converter:pn.Id}),Jn(qn.IU$)],Qn.prototype,"neutralFillStealthFocusDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-fill-strong-hover-delta",converter:pn.Id}),Jn(qn.sc1)],Qn.prototype,"neutralFillStrongHoverDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-fill-strong-active-delta",converter:pn.Id}),Jn(qn.Vt5)],Qn.prototype,"neutralFillStrongActiveDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-fill-strong-focus-delta",converter:pn.Id}),Jn(qn.UCF)],Qn.prototype,"neutralFillStrongFocusDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"base-layer-luminance",converter:pn.Id}),Jn(qn.q2d)],Qn.prototype,"baseLayerLuminance",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-stroke-divider-rest-delta",converter:pn.Id}),Jn(qn.hD7)],Qn.prototype,"neutralStrokeDividerRestDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-stroke-rest-delta",converter:pn.Id}),Jn(qn.fd1)],Qn.prototype,"neutralStrokeRestDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-stroke-hover-delta",converter:pn.Id}),Jn(qn.rnN)],Qn.prototype,"neutralStrokeHoverDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-stroke-active-delta",converter:pn.Id}),Jn(qn.IMz)],Qn.prototype,"neutralStrokeActiveDelta",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-stroke-focus-delta",converter:pn.Id}),Jn(qn.Bxy)],Qn.prototype,"neutralStrokeFocusDelta",void 0);const eo=Qn.compose({baseName:"design-system-provider",template:$n` <slot></slot> `,styles:dn`
${zn("block")}
`});var to;!function(e){e[e.alt=18]="alt",e[e.arrowDown=40]="arrowDown",e[e.arrowLeft=37]="arrowLeft",e[e.arrowRight=39]="arrowRight",e[e.arrowUp=38]="arrowUp",e[e.back=8]="back",e[e.backSlash=220]="backSlash",e[e.break=19]="break",e[e.capsLock=20]="capsLock",e[e.closeBracket=221]="closeBracket",e[e.colon=186]="colon",e[e.colon2=59]="colon2",e[e.comma=188]="comma",e[e.ctrl=17]="ctrl",e[e.delete=46]="delete",e[e.end=35]="end",e[e.enter=13]="enter",e[e.equals=187]="equals",e[e.equals2=61]="equals2",e[e.equals3=107]="equals3",e[e.escape=27]="escape",e[e.forwardSlash=191]="forwardSlash",e[e.function1=112]="function1",e[e.function10=121]="function10",e[e.function11=122]="function11",e[e.function12=123]="function12",e[e.function2=113]="function2",e[e.function3=114]="function3",e[e.function4=115]="function4",e[e.function5=116]="function5",e[e.function6=117]="function6",e[e.function7=118]="function7",e[e.function8=119]="function8",e[e.function9=120]="function9",e[e.home=36]="home",e[e.insert=45]="insert",e[e.menu=93]="menu",e[e.minus=189]="minus",e[e.minus2=109]="minus2",e[e.numLock=144]="numLock",e[e.numPad0=96]="numPad0",e[e.numPad1=97]="numPad1",e[e.numPad2=98]="numPad2",e[e.numPad3=99]="numPad3",e[e.numPad4=100]="numPad4",e[e.numPad5=101]="numPad5",e[e.numPad6=102]="numPad6",e[e.numPad7=103]="numPad7",e[e.numPad8=104]="numPad8",e[e.numPad9=105]="numPad9",e[e.numPadDivide=111]="numPadDivide",e[e.numPadDot=110]="numPadDot",e[e.numPadMinus=109]="numPadMinus",e[e.numPadMultiply=106]="numPadMultiply",e[e.numPadPlus=107]="numPadPlus",e[e.openBracket=219]="openBracket",e[e.pageDown=34]="pageDown",e[e.pageUp=33]="pageUp",e[e.period=190]="period",e[e.print=44]="print",e[e.quote=222]="quote",e[e.scrollLock=145]="scrollLock",e[e.shift=16]="shift",e[e.space=32]="space",e[e.tab=9]="tab",e[e.tilde=192]="tilde",e[e.windowsLeft=91]="windowsLeft",e[e.windowsOpera=219]="windowsOpera",e[e.windowsRight=92]="windowsRight"}(to||(to={}));const io="ArrowDown",no="ArrowLeft",oo="ArrowRight",ro="ArrowUp",ao="Enter",so="Escape",lo="Home",co="End",uo=" ",ho="Tab",po={ArrowDown:io,ArrowLeft:no,ArrowRight:oo,ArrowUp:ro};function go(e,t,i){return i<e?t:i>t?e:i}function fo(e,t,i=0){return[t,i]=[t,i].sort(((e,t)=>e-t)),t<=e&&e<i}class mo{constructor(e,t){this.target=e,this.propertyName=t}bind(e){e[this.propertyName]=this.target}unbind(){}}function vo(e){return new vn("fast-ref",mo,e)}class yo{handleStartContentChange(){this.startContainer.classList.toggle("start",this.start.assignedNodes().length>0)}handleEndContentChange(){this.endContainer.classList.toggle("end",this.end.assignedNodes().length>0)}}const Co=(e,t)=>$n`
<span
part="end"
${vo("endContainer")}
class=${e=>t.end?"end":void 0}
>
<slot name="end" ${vo("end")} @slotchange="${e=>e.handleEndContentChange()}">
${t.end||""}
</slot>
</span>
`,bo=(e,t)=>$n`
<span
part="start"
${vo("startContainer")}
class="${e=>t.start?"start":void 0}"
>
<slot
name="start"
${vo("start")}
@slotchange="${e=>e.handleStartContentChange()}"
>
${t.start||""}
</slot>
</span>
`;function So(e,...t){const i=pn.Ax.locate(e);t.forEach((t=>{Object.getOwnPropertyNames(t.prototype).forEach((i=>{"constructor"!==i&&Object.defineProperty(e.prototype,i,Object.getOwnPropertyDescriptor(t.prototype,i))})),pn.Ax.locate(t).forEach((e=>i.push(e)))}))}$n`
<span part="end" ${vo("endContainer")}>
<slot
name="end"
${vo("end")}
@slotchange="${e=>e.handleEndContentChange()}"
></slot>
</span>
`,$n`
<span part="start" ${vo("startContainer")}>
<slot
name="start"
${vo("start")}
@slotchange="${e=>e.handleStartContentChange()}"
></slot>
</span>
`;class xo extends zi{constructor(){super(...arguments),this.headinglevel=2,this.expanded=!1,this.clickHandler=e=>{this.expanded=!this.expanded,this.change()},this.change=()=>{this.$emit("change")}}}(0,ii.gn)([(0,pn.Lj)({attribute:"heading-level",mode:"fromView",converter:pn.Id})],xo.prototype,"headinglevel",void 0),(0,ii.gn)([(0,pn.Lj)({mode:"boolean"})],xo.prototype,"expanded",void 0),(0,ii.gn)([pn.Lj],xo.prototype,"id",void 0),So(xo,yo);class To extends zi{constructor(){super(...arguments),this.expandmode="multi",this.activeItemIndex=0,this.change=()=>{this.$emit("change",this.activeid)},this.setItems=()=>{var e;0!==this.accordionItems.length&&(this.accordionIds=this.getItemIds(),this.accordionItems.forEach(((e,t)=>{e instanceof xo&&(e.addEventListener("change",this.activeItemChange),this.isSingleExpandMode()&&(this.activeItemIndex!==t?e.expanded=!1:e.expanded=!0));const i=this.accordionIds[t];e.setAttribute("id","string"!=typeof i?`accordion-${t+1}`:i),this.activeid=this.accordionIds[this.activeItemIndex],e.addEventListener("keydown",this.handleItemKeyDown),e.addEventListener("focus",this.handleItemFocus)})),this.isSingleExpandMode())&&(null!==(e=this.findExpandedItem())&&void 0!==e?e:this.accordionItems[0]).setAttribute("aria-disabled","true")},this.removeItemListeners=e=>{e.forEach(((e,t)=>{e.removeEventListener("change",this.activeItemChange),e.removeEventListener("keydown",this.handleItemKeyDown),e.removeEventListener("focus",this.handleItemFocus)}))},this.activeItemChange=e=>{if(e.defaultPrevented||e.target!==e.currentTarget)return;e.preventDefault();const t=e.target;this.activeid=t.getAttribute("id"),this.isSingleExpandMode()&&(this.resetItems(),t.expanded=!0,t.setAttribute("aria-disabled","true"),this.accordionItems.forEach((e=>{e.hasAttribute("disabled")||e.id===this.activeid||e.removeAttribute("aria-disabled")}))),this.activeItemIndex=Array.from(this.accordionItems).indexOf(t),this.change()},this.handleItemKeyDown=e=>{if(e.target===e.currentTarget)switch(this.accordionIds=this.getItemIds(),e.key){case ro:e.preventDefault(),this.adjust(-1);break;case io:e.preventDefault(),this.adjust(1);break;case lo:this.activeItemIndex=0,this.focusItem();break;case co:this.activeItemIndex=this.accordionItems.length-1,this.focusItem()}},this.handleItemFocus=e=>{if(e.target===e.currentTarget){const t=e.target,i=this.activeItemIndex=Array.from(this.accordionItems).indexOf(t);this.activeItemIndex!==i&&-1!==i&&(this.activeItemIndex=i,this.activeid=this.accordionIds[this.activeItemIndex])}}}accordionItemsChanged(e,t){this.$fastController.isConnected&&(this.removeItemListeners(e),this.setItems())}findExpandedItem(){for(let e=0;e<this.accordionItems.length;e++)if("true"===this.accordionItems[e].getAttribute("expanded"))return this.accordionItems[e];return null}resetItems(){this.accordionItems.forEach(((e,t)=>{e.expanded=!1}))}getItemIds(){return this.accordionItems.map((e=>e.getAttribute("id")))}isSingleExpandMode(){return"single"===this.expandmode}adjust(e){this.activeItemIndex=go(0,this.accordionItems.length-1,this.activeItemIndex+e),this.focusItem()}focusItem(){const e=this.accordionItems[this.activeItemIndex];e instanceof xo&&e.expandbutton.focus()}}function wo(e){return e?function(t,i,n){return 1===t.nodeType&&t.matches(e)}:function(e,t,i){return 1===e.nodeType}}(0,ii.gn)([(0,pn.Lj)({attribute:"expand-mode"})],To.prototype,"expandmode",void 0),(0,ii.gn)([oi.LO],To.prototype,"accordionItems",void 0);class Oo{constructor(e,t){this.target=e,this.options=t,this.source=null}bind(e){const t=this.options.property;this.shouldUpdate=oi.y$.getAccessors(e).some((e=>e.name===t)),this.source=e,this.updateTarget(this.computeNodes()),this.shouldUpdate&&this.observe()}unbind(){this.updateTarget(ai.ow),this.source=null,this.shouldUpdate&&this.disconnect()}handleEvent(){this.updateTarget(this.computeNodes())}computeNodes(){let e=this.getNodes();return void 0!==this.options.filter&&(e=e.filter(this.options.filter)),e}updateTarget(e){this.source[this.options.property]=e}}class Po extends Oo{constructor(e,t){super(e,t)}observe(){this.target.addEventListener("slotchange",this)}disconnect(){this.target.removeEventListener("slotchange",this)}getNodes(){return this.target.assignedNodes(this.options)}}function Ao(e){return"string"==typeof e&&(e={property:e}),new vn("fast-slotted",Po,e)}const Eo=hn`
font-family: ${qn.SVJ};
font-size: ${qn.cSu};
line-height: ${qn.RUt};
font-weight: initial;
font-variation-settings: ${qn.Ww_};
`,ko=hn`
font-family: ${qn.SVJ};
font-size: ${qn.sNp};
line-height: ${qn.vgC};
font-weight: initial;
font-variation-settings: ${qn.FMB};
`,Io=(hn`
font-family: ${qn.SVJ};
font-size: ${qn.G8g};
line-height: ${qn.MwG};
font-weight: initial;
font-variation-settings: ${qn.Tp7};
`,hn`
font-family: ${qn.SVJ};
font-size: ${qn.PwC};
line-height: ${qn.b3W};
font-weight: initial;
font-variation-settings: ${qn.GQL};
`,hn`
font-family: ${qn.SVJ};
font-size: ${qn.mWK};
line-height: ${qn.I7_};
font-weight: initial;
font-variation-settings: ${qn.YQw};
`,hn`
font-family: ${qn.SVJ};
font-size: ${qn.ipv};
line-height: ${qn.yGZ};
font-weight: initial;
font-variation-settings: ${qn.pqD};
`,hn`
font-family: ${qn.SVJ};
font-size: ${qn.IWd};
line-height: ${qn.iL4};
font-weight: initial;
font-variation-settings: ${qn.SZp};
`,hn`
font-family: ${qn.SVJ};
font-size: ${qn.CXZ};
line-height: ${qn.n5T};
font-weight: initial;
font-variation-settings: ${qn.NIE};
`,hn`
font-family: ${qn.SVJ};
font-size: ${qn.Zaf};
line-height: ${qn.yDy};
font-weight: initial;
font-variation-settings: ${qn.dm2};
`,To.compose({baseName:"accordion",template:(e,t)=>$n`
<template>
<slot ${Ao({property:"accordionItems",filter:wo()})}></slot>
<slot name="item" part="item" ${Ao("accordionItems")}></slot>
</template>
`,styles:(e,t)=>dn`
${zn("flex")} :host {
box-sizing: border-box;
flex-direction: column;
${Eo}
color: ${qn.CHi};
gap: calc(${qn._5n} * 1px);
}
`}));function Do(...e){return e.every((e=>e instanceof HTMLElement))}let _o;const No=function(){if("boolean"==typeof _o)return _o;if("undefined"==typeof window||!window.document||!window.document.createElement)return _o=!1,_o;const e=document.createElement("style"),t=function(){const e=document.querySelector('meta[property="csp-nonce"]');return e?e.getAttribute("content"):null}();null!==t&&e.setAttribute("nonce",t),document.head.appendChild(e);try{e.sheet.insertRule("foo:focus-visible {color:inherit}",0),_o=!0}catch(e){_o=!1}finally{document.head.removeChild(e)}return _o}()?"focus-visible":"focus",Ro=hn`
outline: calc(${qn.vxp} * 1px) solid ${qn.yGg};
outline-offset: calc(${qn.vxp} * -1px);
`,Mo=hn`
outline: calc(${qn.vxp} * 1px) solid ${qn.yGg};
outline-offset: calc(${qn.Han} * 1px);
`,Lo=hn`(${qn.nfe} + ${qn.hVk}) * ${qn._5n}`,Bo=qi.DesignToken.create("neutral-fill-stealth-rest-on-neutral-fill-layer-rest").withDefault((e=>{const t=qn.abR.getValueFor(e);return qn.DFW.getValueFor(e).evaluate(e,t.evaluate(e).rest).rest})),Fo=qi.DesignToken.create("neutral-fill-stealth-hover-on-neutral-fill-layer-rest").withDefault((e=>{const t=qn.abR.getValueFor(e);return qn.DFW.getValueFor(e).evaluate(e,t.evaluate(e).rest).hover})),Uo=qi.DesignToken.create("neutral-fill-stealth-active-on-neutral-fill-layer-rest").withDefault((e=>{const t=qn.abR.getValueFor(e);return qn.DFW.getValueFor(e).evaluate(e,t.evaluate(e).rest).active})),Ho=xo.compose({baseName:"accordion-item",template:(e,t)=>$n`
<template class="${e=>e.expanded?"expanded":""}">
<div
class="heading"
part="heading"
role="heading"
aria-level="${e=>e.headinglevel}"
>
<button
class="button"
part="button"
${vo("expandbutton")}
aria-expanded="${e=>e.expanded}"
aria-controls="${e=>e.id}-panel"
id="${e=>e.id}"
@click="${(e,t)=>e.clickHandler(t.event)}"
>
<span class="heading-content" part="heading-content">
<slot name="heading"></slot>
</span>
</button>
${bo(0,t)}
${Co(0,t)}
<span class="icon" part="icon" aria-hidden="true">
<slot name="expanded-icon" part="expanded-icon">
${t.expandedIcon||""}
</slot>
<slot name="collapsed-icon" part="collapsed-icon">
${t.collapsedIcon||""}
</slot>
<span>
</div>
<div
class="region"
part="region"
id="${e=>e.id}-panel"
role="region"
aria-labelledby="${e=>e.id}"
>
<slot></slot>
</div>
</template>
`,styles:(e,t)=>dn`
${zn("flex")} :host {
box-sizing: border-box;
${Eo};
flex-direction: column;
background: ${qn.RJY};
color: ${qn.CHi};
border: calc(${qn.Han} * 1px) solid ${qn.Ja_};
border-radius: calc(${qn.rSr} * 1px);
}
.region {
display: none;
padding: calc(${qn._5n} * 2 * 1px);
background: ${qn.Y5u};
}
.heading {
display: grid;
position: relative;
grid-template-columns: auto 1fr auto auto;
align-items: center;
}
.button {
appearance: none;
border: none;
background: none;
grid-column: 2;
grid-row: 1;
outline: none;
margin: calc(${qn._5n} * 3 * 1px) 0;
padding: 0 calc(${qn._5n} * 2 * 1px);
text-align: left;
color: inherit;
cursor: pointer;
font: inherit;
}
.button::before {
content: '';
position: absolute;
top: calc(${qn.Han} * -1px);
left: calc(${qn.Han} * -1px);
right: calc(${qn.Han} * -1px);
bottom: calc(${qn.Han} * -1px);
cursor: pointer;
}
.button:${No}::before {
${Ro}
border-radius: calc(${qn.rSr} * 1px);
}
:host(.expanded) .button:${No}::before {
border-bottom-left-radius: 0;
border-bottom-right-radius: 0;
}
:host(.expanded) .region {
display: block;
border-top: calc(${qn.Han} * 1px) solid ${qn.Ja_};
border-bottom-left-radius: calc((${qn.rSr} - ${qn.Han}) * 1px);
border-bottom-right-radius: calc((${qn.rSr} - ${qn.Han}) * 1px);
}
.icon {
display: flex;
align-items: center;
justify-content: center;
grid-column: 4;
pointer-events: none;
background: ${Bo};
border-radius: calc(${qn.UWU} * 1px);
fill: currentcolor;
width: calc(${Lo} * 1px);
height: calc(${Lo} * 1px);
margin: calc(${qn._5n} * 2 * 1px);
}
.heading:hover .icon {
background: ${Fo};
}
.heading:active .icon {
background: ${Uo};
}
slot[name='collapsed-icon'] {
display: flex;
}
:host(.expanded) slot[name='collapsed-icon'] {
display: none;
}
slot[name='expanded-icon'] {
display: none;
}
:host(.expanded) slot[name='expanded-icon'] {
display: flex;
}
.start {
display: flex;
align-items: center;
padding-inline-start: calc(${qn._5n} * 2 * 1px);
justify-content: center;
grid-column: 1;
}
.end {
display: flex;
align-items: center;
justify-content: center;
grid-column: 3;
}
.icon,
.start,
.end {
position: relative;
}
`.withBehaviors(Gn(dn`
.button:${No}::before {
outline-color: ${Wn.Highlight};
}
.icon {
fill: ${Wn.ButtonText};
}
`)),collapsedIcon:'\n <svg width="12" height="12" xmlns="http://www.w3.org/2000/svg">\n <path d="M2.15 4.65c.2-.2.5-.2.7 0L6 7.79l3.15-3.14a.5.5 0 11.7.7l-3.5 3.5a.5.5 0 01-.7 0l-3.5-3.5a.5.5 0 010-.7z"/>\n </svg>\n ',expandedIcon:'\n <svg width="12" height="12" xmlns="http://www.w3.org/2000/svg">\n <path d="M2.15 7.35c.2.2.5.2.7 0L6 4.21l3.15 3.14a.5.5 0 10.7-.7l-3.5-3.5a.5.5 0 00-.7 0l-3.5 3.5a.5.5 0 000 .7z"/>\n </svg>\n '});class $o{}(0,ii.gn)([(0,pn.Lj)({attribute:"aria-atomic"})],$o.prototype,"ariaAtomic",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-busy"})],$o.prototype,"ariaBusy",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-controls"})],$o.prototype,"ariaControls",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-current"})],$o.prototype,"ariaCurrent",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-describedby"})],$o.prototype,"ariaDescribedby",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-details"})],$o.prototype,"ariaDetails",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-disabled"})],$o.prototype,"ariaDisabled",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-errormessage"})],$o.prototype,"ariaErrormessage",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-flowto"})],$o.prototype,"ariaFlowto",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-haspopup"})],$o.prototype,"ariaHaspopup",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-hidden"})],$o.prototype,"ariaHidden",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-invalid"})],$o.prototype,"ariaInvalid",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-keyshortcuts"})],$o.prototype,"ariaKeyshortcuts",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-label"})],$o.prototype,"ariaLabel",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-labelledby"})],$o.prototype,"ariaLabelledby",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-live"})],$o.prototype,"ariaLive",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-owns"})],$o.prototype,"ariaOwns",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-relevant"})],$o.prototype,"ariaRelevant",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-roledescription"})],$o.prototype,"ariaRoledescription",void 0);class Zo extends zi{constructor(){super(...arguments),this.handleUnsupportedDelegatesFocus=()=>{var e;window.ShadowRoot&&!window.ShadowRoot.prototype.hasOwnProperty("delegatesFocus")&&(null===(e=this.$fastController.definition.shadowOptions)||void 0===e?void 0:e.delegatesFocus)&&(this.focus=()=>{var e;null===(e=this.control)||void 0===e||e.focus()})}}connectedCallback(){super.connectedCallback(),this.handleUnsupportedDelegatesFocus()}}(0,ii.gn)([pn.Lj],Zo.prototype,"download",void 0),(0,ii.gn)([pn.Lj],Zo.prototype,"href",void 0),(0,ii.gn)([pn.Lj],Zo.prototype,"hreflang",void 0),(0,ii.gn)([pn.Lj],Zo.prototype,"ping",void 0),(0,ii.gn)([pn.Lj],Zo.prototype,"referrerpolicy",void 0),(0,ii.gn)([pn.Lj],Zo.prototype,"rel",void 0),(0,ii.gn)([pn.Lj],Zo.prototype,"target",void 0),(0,ii.gn)([pn.Lj],Zo.prototype,"type",void 0),(0,ii.gn)([oi.LO],Zo.prototype,"defaultSlottedContent",void 0);class Vo{}(0,ii.gn)([(0,pn.Lj)({attribute:"aria-expanded"})],Vo.prototype,"ariaExpanded",void 0),So(Vo,$o),So(Zo,yo,Vo);const Go=(e,t,i,n="[disabled]")=>dn`
${zn("inline-flex")}
:host {
position: relative;
box-sizing: border-box;
${Eo}
height: calc(${Lo} * 1px);
min-width: calc(${Lo} * 1px);
color: ${qn.CHi};
border-radius: calc(${qn.UWU} * 1px);
fill: currentcolor;
}
.control {
border: calc(${qn.Han} * 1px) solid transparent;
flex-grow: 1;
box-sizing: border-box;
display: inline-flex;
justify-content: center;
align-items: center;
padding: 0 calc((10 + (${qn._5n} * 2 * ${qn.hVk})) * 1px);
white-space: nowrap;
outline: none;
text-decoration: none;
color: inherit;
border-radius: inherit;
fill: inherit;
font-family: inherit;
}
.control,
.end,
.start {
font: inherit;
}
.control.icon-only {
padding: 0;
line-height: 0;
}
.control:${No} {
${Ro}
}
.control::-moz-focus-inner {
border: 0;
}
.content {
pointer-events: none;
}
.start,
.end {
display: flex;
pointer-events: none;
}
.start {
margin-inline-end: 11px;
}
.end {
margin-inline-start: 11px;
}
`,jo=(e,t,i,n="[disabled]")=>dn`
.control {
background: padding-box linear-gradient(${qn.wFS}, ${qn.wFS}),
border-box ${qn.U_Q};
}
:host(${i}:hover) .control {
background: padding-box linear-gradient(${qn.XiB}, ${qn.XiB}),
border-box ${qn.xBI};
}
:host(${i}:active) .control {
background: padding-box linear-gradient(${qn.Gy2}, ${qn.Gy2}),
border-box ${qn._ro};
}
:host(${n}) .control {
background: padding-box linear-gradient(${qn.wFS}, ${qn.wFS}),
border-box ${qn.akT};
}
`.withBehaviors(Gn(dn`
.control {
background: ${Wn.ButtonFace};
border-color: ${Wn.ButtonText};
color: ${Wn.ButtonText};
}
:host(${i}:hover) .control,
:host(${i}:active) .control {
forced-color-adjust: none;
background: ${Wn.HighlightText};
border-color: ${Wn.Highlight};
color: ${Wn.Highlight};
}
:host(${n}) .control {
background: transparent;
border-color: ${Wn.GrayText};
color: ${Wn.GrayText};
}
.control:${No} {
outline-color: ${Wn.CanvasText};
}
:host([href]) .control {
background: transparent;
border-color: ${Wn.LinkText};
color: ${Wn.LinkText};
}
:host([href]:hover) .control,
:host([href]:active) .control {
background: transparent;
border-color: ${Wn.CanvasText};
color: ${Wn.CanvasText};
}
`)),zo=(e,t,i,n="[disabled]")=>dn`
.control {
background: padding-box linear-gradient(${qn.Avx}, ${qn.Avx}),
border-box ${qn.z0S};
color: ${qn.w41};
}
:host(${i}:hover) .control {
background: padding-box linear-gradient(${qn.OCG}, ${qn.OCG}),
border-box ${qn.fbQ};
color: ${qn.lJV};
}
:host(${i}:active) .control {
background: padding-box linear-gradient(${qn.UEO}, ${qn.UEO}),
border-box ${qn.oi3};
color: ${qn.PpH};
}
:host(${n}) .control {
background: ${qn.Avx};
}
.control:${No} {
box-shadow: 0 0 0 calc(${qn.vxp} * 1px) ${qn.a2F} inset !important;
}
`.withBehaviors(Gn(dn`
.control {
forced-color-adjust: none;
background: ${Wn.Highlight};
color: ${Wn.HighlightText};
}
:host(${i}:hover) .control,
:host(${i}:active) .control {
background: ${Wn.HighlightText};
border-color: ${Wn.Highlight};
color: ${Wn.Highlight};
}
:host(${n}) .control {
background: transparent;
border-color: ${Wn.GrayText};
color: ${Wn.GrayText};
}
.control:${No} {
outline-color: ${Wn.CanvasText};
box-shadow: 0 0 0 calc(${qn.vxp} * 1px) ${Wn.HighlightText} inset !important;
}
:host([href]) .control {
background: ${Wn.LinkText};
color: ${Wn.HighlightText};
}
:host([href]:hover) .control,
:host([href]:active) .control {
background: ${Wn.ButtonFace};
border-color: ${Wn.LinkText};
color: ${Wn.LinkText};
}
`)),Wo=(e,t,i,n="[disabled]")=>dn`
:host {
color: ${qn.goi};
}
.control {
background: ${qn.jql};
}
:host(${i}:hover) .control {
background: ${qn.QpD};
color: ${qn.D9J};
}
:host(${i}:active) .control {
background: ${qn.sG3};
color: ${qn.VNr};
}
:host(${n}) .control {
background: ${qn.jql};
}
`.withBehaviors(Gn(dn`
:host {
color: ${Wn.ButtonText};
}
.control {
forced-color-adjust: none;
background: transparent;
}
:host(${i}:hover) .control,
:host(${i}:active) .control {
background: transparent;
border-color: ${Wn.ButtonText};
color: ${Wn.ButtonText};
}
:host(${n}) .control {
background: transparent;
color: ${Wn.GrayText};
}
.control:${No} {
outline-color: ${Wn.CanvasText};
}
:host([href]) .control {
color: ${Wn.LinkText};
}
:host([href]:hover) .control,
:host([href]:active) .control {
border-color: ${Wn.LinkText};
color: ${Wn.LinkText};
}
`)),Ko=(e,t,i,n="[disabled]")=>dn`
.control {
background: transparent !important;
border-color: ${qn.akT};
}
:host(${i}:hover) .control {
border-color: ${qn.QPc};
}
:host(${i}:active) .control {
border-color: ${qn.c1L};
}
:host(${n}) .control {
background: transparent !important;
border-color: ${qn.akT};
}
`.withBehaviors(Gn(dn`
.control {
border-color: ${Wn.ButtonText};
color: ${Wn.ButtonText};
}
:host(${i}:hover) .control,
:host(${i}:active) .control {
background: ${Wn.HighlightText};
border-color: ${Wn.Highlight};
color: ${Wn.Highlight};
}
:host(${n}) .control {
border-color: ${Wn.GrayText};
color: ${Wn.GrayText};
}
.control:${No} {
outline-color: ${Wn.CanvasText};
}
:host([href]) .control {
border-color: ${Wn.LinkText};
color: ${Wn.LinkText};
}
:host([href]:hover) .control,
:host([href]:active) .control {
border-color: ${Wn.CanvasText};
color: ${Wn.CanvasText};
}
`)),qo=(e,t,i,n="[disabled]")=>dn`
.control {
background: ${qn.jql};
}
:host(${i}:hover) .control {
background: ${qn.QpD};
}
:host(${i}:active) .control {
background: ${qn.sG3};
}
:host(${n}) .control {
background: ${qn.jql};
}
`.withBehaviors(Gn(dn`
.control {
forced-color-adjust: none;
background: transparent;
color: ${Wn.ButtonText};
}
:host(${i}:hover) .control,
:host(${i}:active) .control {
background: transparent;
border-color: ${Wn.ButtonText};
color: ${Wn.ButtonText};
}
:host(${n}) .control {
background: transparent;
color: ${Wn.GrayText};
}
.control:${No} {
outline-color: ${Wn.CanvasText};
}
:host([href]) .control {
color: ${Wn.LinkText};
}
:host([href]:hover) .control,
:host([href]:active) .control {
background: transparent;
border-color: ${Wn.LinkText};
color: ${Wn.LinkText};
}
`));class Yo{constructor(e,t,i){this.propertyName=e,this.value=t,this.styles=i}bind(e){oi.y$.getNotifier(e).subscribe(this,this.propertyName),this.handleChange(e,this.propertyName)}unbind(e){oi.y$.getNotifier(e).unsubscribe(this,this.propertyName),e.$fastController.removeStyles(this.styles)}handleChange(e,t){e[t]===this.value?e.$fastController.addStyles(this.styles):e.$fastController.removeStyles(this.styles)}}function Xo(e,t){return new Yo("appearance",e,t)}const Jo="[href]";class Qo extends Zo{appearanceChanged(e,t){e!==t&&(this.classList.add(t),this.classList.remove(e))}connectedCallback(){super.connectedCallback(),this.appearance||(this.appearance="neutral")}defaultSlottedContentChanged(){var e,t;const i=this.defaultSlottedContent.filter((e=>e.nodeType===Node.ELEMENT_NODE));1===i.length&&i[0]instanceof SVGElement?null===(e=this.control)||void 0===e||e.classList.add("icon-only"):null===(t=this.control)||void 0===t||t.classList.remove("icon-only")}}(0,an.gn)([pn.Lj],Qo.prototype,"appearance",void 0);const er=Qo.compose({baseName:"anchor",baseClass:Zo,template:(e,t)=>$n`
<a
class="control"
part="control"
download="${e=>e.download}"
href="${e=>e.href}"
hreflang="${e=>e.hreflang}"
ping="${e=>e.ping}"
referrerpolicy="${e=>e.referrerpolicy}"
rel="${e=>e.rel}"
target="${e=>e.target}"
type="${e=>e.type}"
aria-atomic="${e=>e.ariaAtomic}"
aria-busy="${e=>e.ariaBusy}"
aria-controls="${e=>e.ariaControls}"
aria-current="${e=>e.ariaCurrent}"
aria-describedby="${e=>e.ariaDescribedby}"
aria-details="${e=>e.ariaDetails}"
aria-disabled="${e=>e.ariaDisabled}"
aria-errormessage="${e=>e.ariaErrormessage}"
aria-expanded="${e=>e.ariaExpanded}"
aria-flowto="${e=>e.ariaFlowto}"
aria-haspopup="${e=>e.ariaHaspopup}"
aria-hidden="${e=>e.ariaHidden}"
aria-invalid="${e=>e.ariaInvalid}"
aria-keyshortcuts="${e=>e.ariaKeyshortcuts}"
aria-label="${e=>e.ariaLabel}"
aria-labelledby="${e=>e.ariaLabelledby}"
aria-live="${e=>e.ariaLive}"
aria-owns="${e=>e.ariaOwns}"
aria-relevant="${e=>e.ariaRelevant}"
aria-roledescription="${e=>e.ariaRoledescription}"
${vo("control")}
>
${bo(0,t)}
<span class="content" part="content">
<slot ${Ao("defaultSlottedContent")}></slot>
</span>
${Co(0,t)}
</a>
`,styles:(e,t)=>Go().withBehaviors(Xo("neutral",jo(0,0,Jo)),Xo("accent",zo(0,0,Jo)),Xo("hypertext",((e,t,i,n="[disabled]")=>dn`
:host {
height: auto;
font-family: inherit;
font-size: inherit;
line-height: inherit;
min-width: 0;
}
.control {
display: inline;
padding: 0;
border: none;
box-shadow: none;
line-height: 1;
}
:host(${i}) .control {
color: ${qn.goi};
text-decoration: underline 1px;
}
:host(${i}:hover) .control {
color: ${qn.D9J};
text-decoration: none;
}
:host(${i}:active) .control {
color: ${qn.VNr};
text-decoration: none;
}
.control:${No} {
${Mo}
}
`.withBehaviors(Gn(dn`
:host(${i}) .control {
color: ${Wn.LinkText};
}
:host(${i}:hover) .control,
:host(${i}:active) .control {
color: ${Wn.CanvasText};
}
.control:${No} {
outline-color: ${Wn.CanvasText};
}
`)))(0,0,Jo)),Xo("lightweight",Wo(0,0,Jo)),Xo("outline",Ko(0,0,Jo)),Xo("stealth",qo(0,0,Jo))),shadowOptions:{delegatesFocus:!0}}),tr="form-associated-proxy",ir="ElementInternals",nr=ir in window&&"setFormValue"in window[ir].prototype,or=new WeakMap;function rr(e){const t=class extends e{constructor(...e){super(...e),this.dirtyValue=!1,this.disabled=!1,this.proxyEventsToBlock=["change","click"],this.proxyInitialized=!1,this.required=!1,this.initialValue=this.initialValue||"",this.elementInternals||(this.formResetCallback=this.formResetCallback.bind(this))}static get formAssociated(){return nr}get validity(){return this.elementInternals?this.elementInternals.validity:this.proxy.validity}get form(){return this.elementInternals?this.elementInternals.form:this.proxy.form}get validationMessage(){return this.elementInternals?this.elementInternals.validationMessage:this.proxy.validationMessage}get willValidate(){return this.elementInternals?this.elementInternals.willValidate:this.proxy.willValidate}get labels(){if(this.elementInternals)return Object.freeze(Array.from(this.elementInternals.labels));if(this.proxy instanceof HTMLElement&&this.proxy.ownerDocument&&this.id){const e=this.proxy.labels,t=Array.from(this.proxy.getRootNode().querySelectorAll(`[for='${this.id}']`)),i=e?t.concat(Array.from(e)):t;return Object.freeze(i)}return ai.ow}valueChanged(e,t){this.dirtyValue=!0,this.proxy instanceof HTMLElement&&(this.proxy.value=this.value),this.currentValue=this.value,this.setFormValue(this.value),this.validate()}currentValueChanged(){this.value=this.currentValue}initialValueChanged(e,t){this.dirtyValue||(this.value=this.initialValue,this.dirtyValue=!1)}disabledChanged(e,t){this.proxy instanceof HTMLElement&&(this.proxy.disabled=this.disabled),gn.SO.queueUpdate((()=>this.classList.toggle("disabled",this.disabled)))}nameChanged(e,t){this.proxy instanceof HTMLElement&&(this.proxy.name=this.name)}requiredChanged(e,t){this.proxy instanceof HTMLElement&&(this.proxy.required=this.required),gn.SO.queueUpdate((()=>this.classList.toggle("required",this.required))),this.validate()}get elementInternals(){if(!nr)return null;let e=or.get(this);return e||(e=this.attachInternals(),or.set(this,e)),e}connectedCallback(){super.connectedCallback(),this.addEventListener("keypress",this._keypressHandler),this.value||(this.value=this.initialValue,this.dirtyValue=!1),this.elementInternals||(this.attachProxy(),this.form&&this.form.addEventListener("reset",this.formResetCallback))}disconnectedCallback(){this.proxyEventsToBlock.forEach((e=>this.proxy.removeEventListener(e,this.stopPropagation))),!this.elementInternals&&this.form&&this.form.removeEventListener("reset",this.formResetCallback)}checkValidity(){return this.elementInternals?this.elementInternals.checkValidity():this.proxy.checkValidity()}reportValidity(){return this.elementInternals?this.elementInternals.reportValidity():this.proxy.reportValidity()}setValidity(e,t,i){this.elementInternals?this.elementInternals.setValidity(e,t,i):"string"==typeof t&&this.proxy.setCustomValidity(t)}formDisabledCallback(e){this.disabled=e}formResetCallback(){this.value=this.initialValue,this.dirtyValue=!1}attachProxy(){var e;this.proxyInitialized||(this.proxyInitialized=!0,this.proxy.style.display="none",this.proxyEventsToBlock.forEach((e=>this.proxy.addEventListener(e,this.stopPropagation))),this.proxy.disabled=this.disabled,this.proxy.required=this.required,"string"==typeof this.name&&(this.proxy.name=this.name),"string"==typeof this.value&&(this.proxy.value=this.value),this.proxy.setAttribute("slot",tr),this.proxySlot=document.createElement("slot"),this.proxySlot.setAttribute("name",tr)),null===(e=this.shadowRoot)||void 0===e||e.appendChild(this.proxySlot),this.appendChild(this.proxy)}detachProxy(){var e;this.removeChild(this.proxy),null===(e=this.shadowRoot)||void 0===e||e.removeChild(this.proxySlot)}validate(e){this.proxy instanceof HTMLElement&&this.setValidity(this.proxy.validity,this.proxy.validationMessage,e)}setFormValue(e,t){this.elementInternals&&this.elementInternals.setFormValue(e,t||e)}_keypressHandler(e){if(e.key===ao&&this.form instanceof HTMLFormElement){const e=this.form.querySelector("[type=submit]");null==e||e.click()}}stopPropagation(e){e.stopPropagation()}};return(0,pn.Lj)({mode:"boolean"})(t.prototype,"disabled"),(0,pn.Lj)({mode:"fromView",attribute:"value"})(t.prototype,"initialValue"),(0,pn.Lj)({attribute:"current-value"})(t.prototype,"currentValue"),(0,pn.Lj)(t.prototype,"name"),(0,pn.Lj)({mode:"boolean"})(t.prototype,"required"),(0,oi.LO)(t.prototype,"value"),t}function ar(e){class t extends(rr(e)){}class i extends t{constructor(...e){super(e),this.dirtyChecked=!1,this.checkedAttribute=!1,this.checked=!1,this.dirtyChecked=!1}checkedAttributeChanged(){this.defaultChecked=this.checkedAttribute}defaultCheckedChanged(){this.dirtyChecked||(this.checked=this.defaultChecked,this.dirtyChecked=!1)}checkedChanged(e,t){this.dirtyChecked||(this.dirtyChecked=!0),this.currentChecked=this.checked,this.updateForm(),this.proxy instanceof HTMLInputElement&&(this.proxy.checked=this.checked),void 0!==e&&this.$emit("change"),this.validate()}currentCheckedChanged(e,t){this.checked=this.currentChecked}updateForm(){const e=this.checked?this.value:null;this.setFormValue(e,e)}connectedCallback(){super.connectedCallback(),this.updateForm()}formResetCallback(){super.formResetCallback(),this.checked=!!this.checkedAttribute,this.dirtyChecked=!1}}return(0,pn.Lj)({attribute:"checked",mode:"boolean"})(i.prototype,"checkedAttribute"),(0,pn.Lj)({attribute:"current-checked",converter:pn.bw})(i.prototype,"currentChecked"),(0,oi.LO)(i.prototype,"defaultChecked"),(0,oi.LO)(i.prototype,"checked"),i}class sr extends zi{}class lr extends(rr(sr)){constructor(){super(...arguments),this.proxy=document.createElement("input")}}class cr extends lr{constructor(){super(...arguments),this.handleClick=e=>{var t;this.disabled&&(null===(t=this.defaultSlottedContent)||void 0===t?void 0:t.length)<=1&&e.stopPropagation()},this.handleSubmission=()=>{if(!this.form)return;const e=this.proxy.isConnected;e||this.attachProxy(),"function"==typeof this.form.requestSubmit?this.form.requestSubmit(this.proxy):this.proxy.click(),e||this.detachProxy()},this.handleFormReset=()=>{var e;null===(e=this.form)||void 0===e||e.reset()},this.handleUnsupportedDelegatesFocus=()=>{var e;window.ShadowRoot&&!window.ShadowRoot.prototype.hasOwnProperty("delegatesFocus")&&(null===(e=this.$fastController.definition.shadowOptions)||void 0===e?void 0:e.delegatesFocus)&&(this.focus=()=>{this.control.focus()})}}formactionChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.formAction=this.formaction)}formenctypeChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.formEnctype=this.formenctype)}formmethodChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.formMethod=this.formmethod)}formnovalidateChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.formNoValidate=this.formnovalidate)}formtargetChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.formTarget=this.formtarget)}typeChanged(e,t){this.proxy instanceof HTMLInputElement&&(this.proxy.type=this.type),"submit"===t&&this.addEventListener("click",this.handleSubmission),"submit"===e&&this.removeEventListener("click",this.handleSubmission),"reset"===t&&this.addEventListener("click",this.handleFormReset),"reset"===e&&this.removeEventListener("click",this.handleFormReset)}validate(){super.validate(this.control)}connectedCallback(){var e;super.connectedCallback(),this.proxy.setAttribute("type",this.type),this.handleUnsupportedDelegatesFocus();const t=Array.from(null===(e=this.control)||void 0===e?void 0:e.children);t&&t.forEach((e=>{e.addEventListener("click",this.handleClick)}))}disconnectedCallback(){var e;super.disconnectedCallback();const t=Array.from(null===(e=this.control)||void 0===e?void 0:e.children);t&&t.forEach((e=>{e.removeEventListener("click",this.handleClick)}))}}(0,ii.gn)([(0,pn.Lj)({mode:"boolean"})],cr.prototype,"autofocus",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"form"})],cr.prototype,"formId",void 0),(0,ii.gn)([pn.Lj],cr.prototype,"formaction",void 0),(0,ii.gn)([pn.Lj],cr.prototype,"formenctype",void 0),(0,ii.gn)([pn.Lj],cr.prototype,"formmethod",void 0),(0,ii.gn)([(0,pn.Lj)({mode:"boolean"})],cr.prototype,"formnovalidate",void 0),(0,ii.gn)([pn.Lj],cr.prototype,"formtarget",void 0),(0,ii.gn)([pn.Lj],cr.prototype,"type",void 0),(0,ii.gn)([oi.LO],cr.prototype,"defaultSlottedContent",void 0);class dr{}(0,ii.gn)([(0,pn.Lj)({attribute:"aria-expanded"})],dr.prototype,"ariaExpanded",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-pressed"})],dr.prototype,"ariaPressed",void 0),So(dr,$o),So(cr,yo,dr);const ur="not-allowed",hr=":not([disabled])",pr="[disabled]";class gr extends cr{appearanceChanged(e,t){e!==t&&(this.classList.add(t),this.classList.remove(e))}connectedCallback(){super.connectedCallback(),this.appearance||(this.appearance="neutral")}defaultSlottedContentChanged(){const e=this.defaultSlottedContent.filter((e=>e.nodeType===Node.ELEMENT_NODE));1===e.length&&e[0]instanceof SVGElement?this.control.classList.add("icon-only"):this.control.classList.remove("icon-only")}}(0,an.gn)([pn.Lj],gr.prototype,"appearance",void 0);const fr=gr.compose({baseName:"button",baseClass:cr,template:(e,t)=>$n`
<button
class="control"
part="control"
?autofocus="${e=>e.autofocus}"
?disabled="${e=>e.disabled}"
form="${e=>e.formId}"
formaction="${e=>e.formaction}"
formenctype="${e=>e.formenctype}"
formmethod="${e=>e.formmethod}"
formnovalidate="${e=>e.formnovalidate}"
formtarget="${e=>e.formtarget}"
name="${e=>e.name}"
type="${e=>e.type}"
value="${e=>e.value}"
aria-atomic="${e=>e.ariaAtomic}"
aria-busy="${e=>e.ariaBusy}"
aria-controls="${e=>e.ariaControls}"
aria-current="${e=>e.ariaCurrent}"
aria-describedby="${e=>e.ariaDescribedby}"
aria-details="${e=>e.ariaDetails}"
aria-disabled="${e=>e.ariaDisabled}"
aria-errormessage="${e=>e.ariaErrormessage}"
aria-expanded="${e=>e.ariaExpanded}"
aria-flowto="${e=>e.ariaFlowto}"
aria-haspopup="${e=>e.ariaHaspopup}"
aria-hidden="${e=>e.ariaHidden}"
aria-invalid="${e=>e.ariaInvalid}"
aria-keyshortcuts="${e=>e.ariaKeyshortcuts}"
aria-label="${e=>e.ariaLabel}"
aria-labelledby="${e=>e.ariaLabelledby}"
aria-live="${e=>e.ariaLive}"
aria-owns="${e=>e.ariaOwns}"
aria-pressed="${e=>e.ariaPressed}"
aria-relevant="${e=>e.ariaRelevant}"
aria-roledescription="${e=>e.ariaRoledescription}"
${vo("control")}
>
${bo(0,t)}
<span class="content" part="content">
<slot ${Ao("defaultSlottedContent")}></slot>
</span>
${Co(0,t)}
</button>
`,styles:(e,t)=>dn`
:host(${hr}) .control {
cursor: pointer;
}
:host(${pr}) .control {
cursor: ${ur};
}
@media (forced-colors: none) {
:host(${pr}) .control {
opacity: ${qn.VFZ};
}
}
${Go(0,0,0,pr)}
`.withBehaviors(Xo("neutral",jo(0,0,hr,pr)),Xo("accent",zo(0,0,hr,pr)),Xo("lightweight",Wo(0,0,hr,pr)),Xo("outline",Ko(0,0,hr,pr)),Xo("stealth",qo(0,0,hr,pr))),shadowOptions:{delegatesFocus:!0}});class mr extends zi{}var vr=o(98584),yr=o(6205);const Cr=qi.DesignToken.create({name:"elevation-shadow",cssCustomPropertyName:null}).withDefault({evaluate:(e,t,i)=>{let n=.12,o=.14;return t>16&&(n=.2,o=.24),`0 0 2px rgba(0, 0, 0, ${n}), 0 calc(${t} * 0.5px) calc((${t} * 1px)) rgba(0, 0, 0, ${o})`}}),br=qi.DesignToken.create("elevation-shadow-card-rest-size").withDefault(4),Sr=qi.DesignToken.create("elevation-shadow-card-hover-size").withDefault(8),xr=qi.DesignToken.create("elevation-shadow-card-active-size").withDefault(0),Tr=qi.DesignToken.create("elevation-shadow-card-focus-size").withDefault(8),wr=qi.DesignToken.create("elevation-shadow-card-rest").withDefault((e=>Cr.getValueFor(e).evaluate(e,br.getValueFor(e)))),Or=(qi.DesignToken.create("elevation-shadow-card-hover").withDefault((e=>Cr.getValueFor(e).evaluate(e,Sr.getValueFor(e)))),qi.DesignToken.create("elevation-shadow-card-active").withDefault((e=>Cr.getValueFor(e).evaluate(e,xr.getValueFor(e)))),qi.DesignToken.create("elevation-shadow-card-focus").withDefault((e=>Cr.getValueFor(e).evaluate(e,Tr.getValueFor(e)))),qi.DesignToken.create("elevation-shadow-tooltip-size").withDefault(16)),Pr=qi.DesignToken.create("elevation-shadow-tooltip").withDefault((e=>Cr.getValueFor(e).evaluate(e,Or.getValueFor(e)))),Ar=qi.DesignToken.create("elevation-shadow-flyout-size").withDefault(32),Er=qi.DesignToken.create("elevation-shadow-flyout").withDefault((e=>Cr.getValueFor(e).evaluate(e,Ar.getValueFor(e)))),kr=qi.DesignToken.create("elevation-shadow-dialog-size").withDefault(128),Ir=qi.DesignToken.create("elevation-shadow-dialog").withDefault((e=>Cr.getValueFor(e).evaluate(e,kr.getValueFor(e))));class Dr extends mr{cardFillColorChanged(e,t){if(t){const e=(0,sn.in)(t);null!==e&&(this.neutralPaletteSource=t,qn.IfY.setValueFor(this,Kn.w.create(e.r,e.g,e.b)))}}neutralPaletteSourceChanged(e,t){if(t){const e=(0,sn.in)(t),i=Kn.w.create(e.r,e.g,e.b);qn.yvm.setValueFor(this,yr.v.create(i))}}handleChange(e,t){this.cardFillColor||qn.IfY.setValueFor(this,(t=>qn.abR.getValueFor(t).evaluate(t,qn.IfY.getValueFor(e)).rest))}connectedCallback(){super.connectedCallback();const e=(0,vr.T)(this);if(e){const t=oi.y$.getNotifier(e);t.subscribe(this,"fillColor"),t.subscribe(this,"neutralPalette"),this.handleChange(e,"fillColor")}}}(0,an.gn)([(0,pn.Lj)({attribute:"card-fill-color",mode:"fromView"})],Dr.prototype,"cardFillColor",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"neutral-palette-source",mode:"fromView"})],Dr.prototype,"neutralPaletteSource",void 0);const _r=Dr.compose({baseName:"card",baseClass:mr,template:(e,t)=>$n`
<slot></slot>
`,styles:(e,t)=>dn`
${zn("block")} :host {
display: block;
contain: content;
height: var(--card-height, 100%);
width: var(--card-width, 100%);
box-sizing: border-box;
background: ${qn.IfY};
color: ${qn.CHi};
border: calc(${qn.Han} * 1px) solid ${qn.Ja_};
border-radius: calc(${qn.rSr} * 1px);
box-shadow: ${wr};
}
:host {
content-visibility: auto;
}
`.withBehaviors(Gn(dn`
:host {
background: ${Wn.Canvas};
color: ${Wn.CanvasText};
}
`))}),Nr="menuitem",Rr="menuitemcheckbox",Mr="menuitemradio",Lr={[Nr]:"menuitem",[Rr]:"menuitemcheckbox",[Mr]:"menuitemradio"};var Br;!function(e){e.ltr="ltr",e.rtl="rtl"}(Br||(Br={}));const Fr=e=>{const t=e.closest("[dir]");return null!==t&&"rtl"===t.dir?Br.rtl:Br.ltr};class Ur extends zi{constructor(){super(...arguments),this.role=Nr,this.hasSubmenu=!1,this.currentDirection=Br.ltr,this.focusSubmenuOnLoad=!1,this.handleMenuItemKeyDown=e=>{if(e.defaultPrevented)return!1;switch(e.key){case ao:case uo:return this.invoke(),!1;case oo:return this.expandAndFocus(),!1;case no:if(this.expanded)return this.expanded=!1,this.focus(),!1}return!0},this.handleMenuItemClick=e=>(e.defaultPrevented||this.disabled||this.invoke(),!1),this.submenuLoaded=()=>{this.focusSubmenuOnLoad&&(this.focusSubmenuOnLoad=!1,this.hasSubmenu&&(this.submenu.focus(),this.setAttribute("tabindex","-1")))},this.handleMouseOver=e=>(this.disabled||!this.hasSubmenu||this.expanded||(this.expanded=!0),!1),this.handleMouseOut=e=>(!this.expanded||this.contains(document.activeElement)||(this.expanded=!1),!1),this.expandAndFocus=()=>{this.hasSubmenu&&(this.focusSubmenuOnLoad=!0,this.expanded=!0)},this.invoke=()=>{if(!this.disabled)switch(this.role){case Rr:this.checked=!this.checked;break;case Nr:this.updateSubmenu(),this.hasSubmenu?this.expandAndFocus():this.$emit("change");break;case Mr:this.checked||(this.checked=!0)}},this.updateSubmenu=()=>{this.submenu=this.domChildren().find((e=>"menu"===e.getAttribute("role"))),this.hasSubmenu=void 0!==this.submenu}}expandedChanged(e){if(this.$fastController.isConnected){if(void 0===this.submenu)return;!1===this.expanded?this.submenu.collapseExpandedItem():this.currentDirection=Fr(this),this.$emit("expanded-change",this,{bubbles:!1})}}checkedChanged(e,t){this.$fastController.isConnected&&this.$emit("change")}connectedCallback(){super.connectedCallback(),gn.SO.queueUpdate((()=>{this.updateSubmenu()})),this.startColumnCount||(this.startColumnCount=1),this.observer=new MutationObserver(this.updateSubmenu)}disconnectedCallback(){super.disconnectedCallback(),this.submenu=void 0,void 0!==this.observer&&(this.observer.disconnect(),this.observer=void 0)}domChildren(){return Array.from(this.children).filter((e=>!e.hasAttribute("hidden")))}}(0,ii.gn)([(0,pn.Lj)({mode:"boolean"})],Ur.prototype,"disabled",void 0),(0,ii.gn)([(0,pn.Lj)({mode:"boolean"})],Ur.prototype,"expanded",void 0),(0,ii.gn)([oi.LO],Ur.prototype,"startColumnCount",void 0),(0,ii.gn)([pn.Lj],Ur.prototype,"role",void 0),(0,ii.gn)([(0,pn.Lj)({mode:"boolean"})],Ur.prototype,"checked",void 0),(0,ii.gn)([oi.LO],Ur.prototype,"submenuRegion",void 0),(0,ii.gn)([oi.LO],Ur.prototype,"hasSubmenu",void 0),(0,ii.gn)([oi.LO],Ur.prototype,"currentDirection",void 0),(0,ii.gn)([oi.LO],Ur.prototype,"submenu",void 0),So(Ur,yo);class Hr extends zi{constructor(){super(...arguments),this.expandedItem=null,this.focusIndex=-1,this.isNestedMenu=()=>null!==this.parentElement&&Do(this.parentElement)&&"menuitem"===this.parentElement.getAttribute("role"),this.handleFocusOut=e=>{if(!this.contains(e.relatedTarget)&&void 0!==this.menuItems){this.collapseExpandedItem();const e=this.menuItems.findIndex(this.isFocusableElement);this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.menuItems[e].setAttribute("tabindex","0"),this.focusIndex=e}},this.handleItemFocus=e=>{const t=e.target;void 0!==this.menuItems&&t!==this.menuItems[this.focusIndex]&&(this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.focusIndex=this.menuItems.indexOf(t),t.setAttribute("tabindex","0"))},this.handleExpandedChanged=e=>{if(e.defaultPrevented||null===e.target||void 0===this.menuItems||this.menuItems.indexOf(e.target)<0)return;e.preventDefault();const t=e.target;null===this.expandedItem||t!==this.expandedItem||!1!==t.expanded?t.expanded&&(null!==this.expandedItem&&this.expandedItem!==t&&(this.expandedItem.expanded=!1),this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.expandedItem=t,this.focusIndex=this.menuItems.indexOf(t),t.setAttribute("tabindex","0")):this.expandedItem=null},this.removeItemListeners=()=>{void 0!==this.menuItems&&this.menuItems.forEach((e=>{e.removeEventListener("expanded-change",this.handleExpandedChanged),e.removeEventListener("focus",this.handleItemFocus)}))},this.setItems=()=>{const e=this.domChildren();this.removeItemListeners(),this.menuItems=e;const t=this.menuItems.filter(this.isMenuItemElement);t.length&&(this.focusIndex=0);const i=t.reduce(((e,t)=>{const i=function(e){const t=e.getAttribute("role"),i=e.querySelector("[slot=start]");return t!==Nr&&null===i||t===Nr&&null!==i?1:t!==Nr&&null!==i?2:0}(t);return e>i?e:i}),0);t.forEach(((e,t)=>{e.setAttribute("tabindex",0===t?"0":"-1"),e.addEventListener("expanded-change",this.handleExpandedChanged),e.addEventListener("focus",this.handleItemFocus),e instanceof Ur&&(e.startColumnCount=i)}))},this.changeHandler=e=>{if(void 0===this.menuItems)return;const t=e.target,i=this.menuItems.indexOf(t);if(-1!==i&&"menuitemradio"===t.role&&!0===t.checked){for(let e=i-1;e>=0;--e){const t=this.menuItems[e],i=t.getAttribute("role");if(i===Mr&&(t.checked=!1),"separator"===i)break}const e=this.menuItems.length-1;for(let t=i+1;t<=e;++t){const e=this.menuItems[t],i=e.getAttribute("role");if(i===Mr&&(e.checked=!1),"separator"===i)break}}},this.isMenuItemElement=e=>Do(e)&&Hr.focusableElementRoles.hasOwnProperty(e.getAttribute("role")),this.isFocusableElement=e=>this.isMenuItemElement(e)}itemsChanged(e,t){this.$fastController.isConnected&&void 0!==this.menuItems&&this.setItems()}connectedCallback(){super.connectedCallback(),gn.SO.queueUpdate((()=>{this.setItems()})),this.addEventListener("change",this.changeHandler)}disconnectedCallback(){super.disconnectedCallback(),this.removeItemListeners(),this.menuItems=void 0,this.removeEventListener("change",this.changeHandler)}focus(){this.setFocus(0,1)}collapseExpandedItem(){null!==this.expandedItem&&(this.expandedItem.expanded=!1,this.expandedItem=null)}handleMenuKeyDown(e){if(!e.defaultPrevented&&void 0!==this.menuItems)switch(e.key){case io:return void this.setFocus(this.focusIndex+1,1);case ro:return void this.setFocus(this.focusIndex-1,-1);case co:return void this.setFocus(this.menuItems.length-1,-1);case lo:return void this.setFocus(0,1);default:return!0}}domChildren(){return Array.from(this.children).filter((e=>!e.hasAttribute("hidden")))}setFocus(e,t){if(void 0!==this.menuItems)for(;e>=0&&e<this.menuItems.length;){const i=this.menuItems[e];if(this.isFocusableElement(i)){this.focusIndex>-1&&this.menuItems.length>=this.focusIndex-1&&this.menuItems[this.focusIndex].setAttribute("tabindex","-1"),this.focusIndex=e,i.setAttribute("tabindex","0"),i.focus();break}e+=t}}}Hr.focusableElementRoles=Lr,(0,ii.gn)([oi.LO],Hr.prototype,"items",void 0);const $r="horizontal";class Zr extends zi{constructor(){super(...arguments),this.role="separator",this.orientation=$r}}(0,ii.gn)([pn.Lj],Zr.prototype,"role",void 0),(0,ii.gn)([pn.Lj],Zr.prototype,"orientation",void 0);const Vr=class extends Hr{connectedCallback(){super.connectedCallback(),qn.IfY.setValueFor(this,qn.s55)}}.compose({baseName:"menu",baseClass:Hr,template:(e,t)=>$n`
<template
slot="${e=>e.slot?e.slot:e.isNestedMenu()?"submenu":void 0}"
role="menu"
@keydown="${(e,t)=>e.handleMenuKeyDown(t.event)}"
@focusout="${(e,t)=>e.handleFocusOut(t.event)}"
>
<slot ${Ao("items")}></slot>
</template>
`,styles:(e,t)=>dn`
${zn("block")} :host {
background: ${qn.s55};
border: calc(${qn.Han} * 1px) solid transparent;
border-radius: calc(${qn.rSr} * 1px);
box-shadow: ${Er};
padding: calc((${qn._5n} - ${qn.Han}) * 1px) 0;
max-width: 368px;
min-width: 64px;
}
:host([slot='submenu']) {
width: max-content;
margin: 0 calc(${qn._5n} * 2px);
}
::slotted(${e.tagFor(Ur)}) {
margin: 0 calc(${qn._5n} * 1px);
}
::slotted(${e.tagFor(Zr)}) {
margin: calc(${qn._5n} * 1px) 0;
}
::slotted(hr) {
box-sizing: content-box;
height: 0;
margin: calc(${qn._5n} * 1px) 0;
border: none;
border-top: calc(${qn.Han} * 1px) solid ${qn.dtw};
}
`.withBehaviors(Gn(dn`
:host([slot='submenu']) {
background: ${Wn.Canvas};
border-color: ${Wn.CanvasText};
}
`))}),Gr=e=>"function"==typeof e,jr=()=>null;function zr(e){return void 0===e?jr:Gr(e)?e:()=>e}function Wr(e,t,i){const n=Gr(e)?e:()=>e,o=zr(t),r=zr(i);return(e,t)=>n(e,t)?o(e,t):r(e,t)}const Kr="resize",qr="scroll";class Yr extends zi{constructor(){super(...arguments),this.anchor="",this.viewport="",this.horizontalPositioningMode="uncontrolled",this.horizontalDefaultPosition="unset",this.horizontalViewportLock=!1,this.horizontalInset=!1,this.horizontalScaling="content",this.verticalPositioningMode="uncontrolled",this.verticalDefaultPosition="unset",this.verticalViewportLock=!1,this.verticalInset=!1,this.verticalScaling="content",this.fixedPlacement=!1,this.autoUpdateMode="anchor",this.anchorElement=null,this.viewportElement=null,this.initialLayoutComplete=!1,this.resizeDetector=null,this.baseHorizontalOffset=0,this.baseVerticalOffset=0,this.pendingPositioningUpdate=!1,this.pendingReset=!1,this.currentDirection=Br.ltr,this.regionVisible=!1,this.forceUpdate=!1,this.updateThreshold=.5,this.update=()=>{this.pendingPositioningUpdate||this.requestPositionUpdates()},this.startObservers=()=>{this.stopObservers(),null!==this.anchorElement&&(this.requestPositionUpdates(),null!==this.resizeDetector&&(this.resizeDetector.observe(this.anchorElement),this.resizeDetector.observe(this)))},this.requestPositionUpdates=()=>{null===this.anchorElement||this.pendingPositioningUpdate||(Yr.intersectionService.requestPosition(this,this.handleIntersection),Yr.intersectionService.requestPosition(this.anchorElement,this.handleIntersection),null!==this.viewportElement&&Yr.intersectionService.requestPosition(this.viewportElement,this.handleIntersection),this.pendingPositioningUpdate=!0)},this.stopObservers=()=>{this.pendingPositioningUpdate&&(this.pendingPositioningUpdate=!1,Yr.intersectionService.cancelRequestPosition(this,this.handleIntersection),null!==this.anchorElement&&Yr.intersectionService.cancelRequestPosition(this.anchorElement,this.handleIntersection),null!==this.viewportElement&&Yr.intersectionService.cancelRequestPosition(this.viewportElement,this.handleIntersection)),null!==this.resizeDetector&&this.resizeDetector.disconnect()},this.getViewport=()=>"string"!=typeof this.viewport||""===this.viewport?document.documentElement:document.getElementById(this.viewport),this.getAnchor=()=>document.getElementById(this.anchor),this.handleIntersection=e=>{this.pendingPositioningUpdate&&(this.pendingPositioningUpdate=!1,this.applyIntersectionEntries(e)&&this.updateLayout())},this.applyIntersectionEntries=e=>{const t=e.find((e=>e.target===this)),i=e.find((e=>e.target===this.anchorElement)),n=e.find((e=>e.target===this.viewportElement));return void 0!==t&&void 0!==n&&void 0!==i&&!!(!this.regionVisible||this.forceUpdate||void 0===this.regionRect||void 0===this.anchorRect||void 0===this.viewportRect||this.isRectDifferent(this.anchorRect,i.boundingClientRect)||this.isRectDifferent(this.viewportRect,n.boundingClientRect)||this.isRectDifferent(this.regionRect,t.boundingClientRect))&&(this.regionRect=t.boundingClientRect,this.anchorRect=i.boundingClientRect,this.viewportElement===document.documentElement?this.viewportRect=new DOMRectReadOnly(n.boundingClientRect.x+document.documentElement.scrollLeft,n.boundingClientRect.y+document.documentElement.scrollTop,n.boundingClientRect.width,n.boundingClientRect.height):this.viewportRect=n.boundingClientRect,this.updateRegionOffset(),this.forceUpdate=!1,!0)},this.updateRegionOffset=()=>{this.anchorRect&&this.regionRect&&(this.baseHorizontalOffset=this.baseHorizontalOffset+(this.anchorRect.left-this.regionRect.left)+(this.translateX-this.baseHorizontalOffset),this.baseVerticalOffset=this.baseVerticalOffset+(this.anchorRect.top-this.regionRect.top)+(this.translateY-this.baseVerticalOffset))},this.isRectDifferent=(e,t)=>Math.abs(e.top-t.top)>this.updateThreshold||Math.abs(e.right-t.right)>this.updateThreshold||Math.abs(e.bottom-t.bottom)>this.updateThreshold||Math.abs(e.left-t.left)>this.updateThreshold,this.handleResize=e=>{this.update()},this.reset=()=>{this.pendingReset&&(this.pendingReset=!1,null===this.anchorElement&&(this.anchorElement=this.getAnchor()),null===this.viewportElement&&(this.viewportElement=this.getViewport()),this.currentDirection=Fr(this),this.startObservers())},this.updateLayout=()=>{let e,t;if("uncontrolled"!==this.horizontalPositioningMode){const e=this.getPositioningOptions(this.horizontalInset);if("center"===this.horizontalDefaultPosition)t="center";else if("unset"!==this.horizontalDefaultPosition){let e=this.horizontalDefaultPosition;if("start"===e||"end"===e){const t=Fr(this);if(t!==this.currentDirection)return this.currentDirection=t,void this.initialize();e=this.currentDirection===Br.ltr?"start"===e?"left":"right":"start"===e?"right":"left"}switch(e){case"left":t=this.horizontalInset?"insetStart":"start";break;case"right":t=this.horizontalInset?"insetEnd":"end"}}const i=void 0!==this.horizontalThreshold?this.horizontalThreshold:void 0!==this.regionRect?this.regionRect.width:0,n=void 0!==this.anchorRect?this.anchorRect.left:0,o=void 0!==this.anchorRect?this.anchorRect.right:0,r=void 0!==this.anchorRect?this.anchorRect.width:0,a=void 0!==this.viewportRect?this.viewportRect.left:0,s=void 0!==this.viewportRect?this.viewportRect.right:0;(void 0===t||"locktodefault"!==this.horizontalPositioningMode&&this.getAvailableSpace(t,n,o,r,a,s)<i)&&(t=this.getAvailableSpace(e[0],n,o,r,a,s)>this.getAvailableSpace(e[1],n,o,r,a,s)?e[0]:e[1])}if("uncontrolled"!==this.verticalPositioningMode){const t=this.getPositioningOptions(this.verticalInset);if("center"===this.verticalDefaultPosition)e="center";else if("unset"!==this.verticalDefaultPosition)switch(this.verticalDefaultPosition){case"top":e=this.verticalInset?"insetStart":"start";break;case"bottom":e=this.verticalInset?"insetEnd":"end"}const i=void 0!==this.verticalThreshold?this.verticalThreshold:void 0!==this.regionRect?this.regionRect.height:0,n=void 0!==this.anchorRect?this.anchorRect.top:0,o=void 0!==this.anchorRect?this.anchorRect.bottom:0,r=void 0!==this.anchorRect?this.anchorRect.height:0,a=void 0!==this.viewportRect?this.viewportRect.top:0,s=void 0!==this.viewportRect?this.viewportRect.bottom:0;(void 0===e||"locktodefault"!==this.verticalPositioningMode&&this.getAvailableSpace(e,n,o,r,a,s)<i)&&(e=this.getAvailableSpace(t[0],n,o,r,a,s)>this.getAvailableSpace(t[1],n,o,r,a,s)?t[0]:t[1])}const i=this.getNextRegionDimension(t,e),n=this.horizontalPosition!==t||this.verticalPosition!==e;if(this.setHorizontalPosition(t,i),this.setVerticalPosition(e,i),this.updateRegionStyle(),!this.initialLayoutComplete)return this.initialLayoutComplete=!0,void this.requestPositionUpdates();this.regionVisible||(this.regionVisible=!0,this.style.removeProperty("pointer-events"),this.style.removeProperty("opacity"),this.classList.toggle("loaded",!0),this.$emit("loaded",this,{bubbles:!1})),this.updatePositionClasses(),n&&this.$emit("positionchange",this,{bubbles:!1})},this.updateRegionStyle=()=>{this.style.width=this.regionWidth,this.style.height=this.regionHeight,this.style.transform=`translate(${this.translateX}px, ${this.translateY}px)`},this.updatePositionClasses=()=>{this.classList.toggle("top","start"===this.verticalPosition),this.classList.toggle("bottom","end"===this.verticalPosition),this.classList.toggle("inset-top","insetStart"===this.verticalPosition),this.classList.toggle("inset-bottom","insetEnd"===this.verticalPosition),this.classList.toggle("vertical-center","center"===this.verticalPosition),this.classList.toggle("left","start"===this.horizontalPosition),this.classList.toggle("right","end"===this.horizontalPosition),this.classList.toggle("inset-left","insetStart"===this.horizontalPosition),this.classList.toggle("inset-right","insetEnd"===this.horizontalPosition),this.classList.toggle("horizontal-center","center"===this.horizontalPosition)},this.setHorizontalPosition=(e,t)=>{if(void 0===e||void 0===this.regionRect||void 0===this.anchorRect||void 0===this.viewportRect)return;let i=0;switch(this.horizontalScaling){case"anchor":case"fill":i=this.horizontalViewportLock?this.viewportRect.width:t.width,this.regionWidth=`${i}px`;break;case"content":i=this.regionRect.width,this.regionWidth="unset"}let n=0;switch(e){case"start":this.translateX=this.baseHorizontalOffset-i,this.horizontalViewportLock&&this.anchorRect.left>this.viewportRect.right&&(this.translateX=this.translateX-(this.anchorRect.left-this.viewportRect.right));break;case"insetStart":this.translateX=this.baseHorizontalOffset-i+this.anchorRect.width,this.horizontalViewportLock&&this.anchorRect.right>this.viewportRect.right&&(this.translateX=this.translateX-(this.anchorRect.right-this.viewportRect.right));break;case"insetEnd":this.translateX=this.baseHorizontalOffset,this.horizontalViewportLock&&this.anchorRect.left<this.viewportRect.left&&(this.translateX=this.translateX-(this.anchorRect.left-this.viewportRect.left));break;case"end":this.translateX=this.baseHorizontalOffset+this.anchorRect.width,this.horizontalViewportLock&&this.anchorRect.right<this.viewportRect.left&&(this.translateX=this.translateX-(this.anchorRect.right-this.viewportRect.left));break;case"center":if(n=(this.anchorRect.width-i)/2,this.translateX=this.baseHorizontalOffset+n,this.horizontalViewportLock){const e=this.anchorRect.left+n,t=this.anchorRect.right-n;e<this.viewportRect.left&&!(t>this.viewportRect.right)?this.translateX=this.translateX-(e-this.viewportRect.left):t>this.viewportRect.right&&!(e<this.viewportRect.left)&&(this.translateX=this.translateX-(t-this.viewportRect.right))}}this.horizontalPosition=e},this.setVerticalPosition=(e,t)=>{if(void 0===e||void 0===this.regionRect||void 0===this.anchorRect||void 0===this.viewportRect)return;let i=0;switch(this.verticalScaling){case"anchor":case"fill":i=this.verticalViewportLock?this.viewportRect.height:t.height,this.regionHeight=`${i}px`;break;case"content":i=this.regionRect.height,this.regionHeight="unset"}let n=0;switch(e){case"start":this.translateY=this.baseVerticalOffset-i,this.verticalViewportLock&&this.anchorRect.top>this.viewportRect.bottom&&(this.translateY=this.translateY-(this.anchorRect.top-this.viewportRect.bottom));break;case"insetStart":this.translateY=this.baseVerticalOffset-i+this.anchorRect.height,this.verticalViewportLock&&this.anchorRect.bottom>this.viewportRect.bottom&&(this.translateY=this.translateY-(this.anchorRect.bottom-this.viewportRect.bottom));break;case"insetEnd":this.translateY=this.baseVerticalOffset,this.verticalViewportLock&&this.anchorRect.top<this.viewportRect.top&&(this.translateY=this.translateY-(this.anchorRect.top-this.viewportRect.top));break;case"end":this.translateY=this.baseVerticalOffset+this.anchorRect.height,this.verticalViewportLock&&this.anchorRect.bottom<this.viewportRect.top&&(this.translateY=this.translateY-(this.anchorRect.bottom-this.viewportRect.top));break;case"center":if(n=(this.anchorRect.height-i)/2,this.translateY=this.baseVerticalOffset+n,this.verticalViewportLock){const e=this.anchorRect.top+n,t=this.anchorRect.bottom-n;e<this.viewportRect.top&&!(t>this.viewportRect.bottom)?this.translateY=this.translateY-(e-this.viewportRect.top):t>this.viewportRect.bottom&&!(e<this.viewportRect.top)&&(this.translateY=this.translateY-(t-this.viewportRect.bottom))}}this.verticalPosition=e},this.getPositioningOptions=e=>e?["insetStart","insetEnd"]:["start","end"],this.getAvailableSpace=(e,t,i,n,o,r)=>{const a=t-o,s=r-(t+n);switch(e){case"start":return a;case"insetStart":return a+n;case"insetEnd":return s+n;case"end":return s;case"center":return 2*Math.min(a,s)+n}},this.getNextRegionDimension=(e,t)=>{const i={height:void 0!==this.regionRect?this.regionRect.height:0,width:void 0!==this.regionRect?this.regionRect.width:0};return void 0!==e&&"fill"===this.horizontalScaling?i.width=this.getAvailableSpace(e,void 0!==this.anchorRect?this.anchorRect.left:0,void 0!==this.anchorRect?this.anchorRect.right:0,void 0!==this.anchorRect?this.anchorRect.width:0,void 0!==this.viewportRect?this.viewportRect.left:0,void 0!==this.viewportRect?this.viewportRect.right:0):"anchor"===this.horizontalScaling&&(i.width=void 0!==this.anchorRect?this.anchorRect.width:0),void 0!==t&&"fill"===this.verticalScaling?i.height=this.getAvailableSpace(t,void 0!==this.anchorRect?this.anchorRect.top:0,void 0!==this.anchorRect?this.anchorRect.bottom:0,void 0!==this.anchorRect?this.anchorRect.height:0,void 0!==this.viewportRect?this.viewportRect.top:0,void 0!==this.viewportRect?this.viewportRect.bottom:0):"anchor"===this.verticalScaling&&(i.height=void 0!==this.anchorRect?this.anchorRect.height:0),i},this.startAutoUpdateEventListeners=()=>{window.addEventListener(Kr,this.update,{passive:!0}),window.addEventListener(qr,this.update,{passive:!0,capture:!0}),null!==this.resizeDetector&&null!==this.viewportElement&&this.resizeDetector.observe(this.viewportElement)},this.stopAutoUpdateEventListeners=()=>{window.removeEventListener(Kr,this.update),window.removeEventListener(qr,this.update),null!==this.resizeDetector&&null!==this.viewportElement&&this.resizeDetector.unobserve(this.viewportElement)}}anchorChanged(){this.initialLayoutComplete&&(this.anchorElement=this.getAnchor())}viewportChanged(){this.initialLayoutComplete&&(this.viewportElement=this.getViewport())}horizontalPositioningModeChanged(){this.requestReset()}horizontalDefaultPositionChanged(){this.updateForAttributeChange()}horizontalViewportLockChanged(){this.updateForAttributeChange()}horizontalInsetChanged(){this.updateForAttributeChange()}horizontalThresholdChanged(){this.updateForAttributeChange()}horizontalScalingChanged(){this.updateForAttributeChange()}verticalPositioningModeChanged(){this.requestReset()}verticalDefaultPositionChanged(){this.updateForAttributeChange()}verticalViewportLockChanged(){this.updateForAttributeChange()}verticalInsetChanged(){this.updateForAttributeChange()}verticalThresholdChanged(){this.updateForAttributeChange()}verticalScalingChanged(){this.updateForAttributeChange()}fixedPlacementChanged(){this.$fastController.isConnected&&this.initialLayoutComplete&&this.initialize()}autoUpdateModeChanged(e,t){this.$fastController.isConnected&&this.initialLayoutComplete&&("auto"===e&&this.stopAutoUpdateEventListeners(),"auto"===t&&this.startAutoUpdateEventListeners())}anchorElementChanged(){this.requestReset()}viewportElementChanged(){this.$fastController.isConnected&&this.initialLayoutComplete&&this.initialize()}connectedCallback(){super.connectedCallback(),"auto"===this.autoUpdateMode&&this.startAutoUpdateEventListeners(),this.initialize()}disconnectedCallback(){super.disconnectedCallback(),"auto"===this.autoUpdateMode&&this.stopAutoUpdateEventListeners(),this.stopObservers(),this.disconnectResizeDetector()}adoptedCallback(){this.initialize()}disconnectResizeDetector(){null!==this.resizeDetector&&(this.resizeDetector.disconnect(),this.resizeDetector=null)}initializeResizeDetector(){this.disconnectResizeDetector(),this.resizeDetector=new window.ResizeObserver(this.handleResize)}updateForAttributeChange(){this.$fastController.isConnected&&this.initialLayoutComplete&&(this.forceUpdate=!0,this.update())}initialize(){this.initializeResizeDetector(),null===this.anchorElement&&(this.anchorElement=this.getAnchor()),this.requestReset()}requestReset(){this.$fastController.isConnected&&!1===this.pendingReset&&(this.setInitialState(),gn.SO.queueUpdate((()=>this.reset())),this.pendingReset=!0)}setInitialState(){this.initialLayoutComplete=!1,this.regionVisible=!1,this.translateX=0,this.translateY=0,this.baseHorizontalOffset=0,this.baseVerticalOffset=0,this.viewportRect=void 0,this.regionRect=void 0,this.anchorRect=void 0,this.verticalPosition=void 0,this.horizontalPosition=void 0,this.style.opacity="0",this.style.pointerEvents="none",this.forceUpdate=!1,this.style.position=this.fixedPlacement?"fixed":"absolute",this.updatePositionClasses(),this.updateRegionStyle()}}Yr.intersectionService=new class{constructor(){this.intersectionDetector=null,this.observedElements=new Map,this.requestPosition=(e,t)=>{var i;null!==this.intersectionDetector&&(this.observedElements.has(e)?null===(i=this.observedElements.get(e))||void 0===i||i.push(t):(this.observedElements.set(e,[t]),this.intersectionDetector.observe(e)))},this.cancelRequestPosition=(e,t)=>{const i=this.observedElements.get(e);if(void 0!==i){const e=i.indexOf(t);-1!==e&&i.splice(e,1)}},this.initializeIntersectionDetector=()=>{ai.P3.IntersectionObserver&&(this.intersectionDetector=new IntersectionObserver(this.handleIntersection,{root:null,rootMargin:"0px",threshold:[0,1]}))},this.handleIntersection=e=>{if(null===this.intersectionDetector)return;const t=[],i=[];e.forEach((e=>{var n;null===(n=this.intersectionDetector)||void 0===n||n.unobserve(e.target);const o=this.observedElements.get(e.target);void 0!==o&&(o.forEach((n=>{let o=t.indexOf(n);-1===o&&(o=t.length,t.push(n),i.push([])),i[o].push(e)})),this.observedElements.delete(e.target))})),t.forEach(((e,t)=>{e(i[t])}))},this.initializeIntersectionDetector()}},(0,ii.gn)([pn.Lj],Yr.prototype,"anchor",void 0),(0,ii.gn)([pn.Lj],Yr.prototype,"viewport",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"horizontal-positioning-mode"})],Yr.prototype,"horizontalPositioningMode",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"horizontal-default-position"})],Yr.prototype,"horizontalDefaultPosition",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"horizontal-viewport-lock",mode:"boolean"})],Yr.prototype,"horizontalViewportLock",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"horizontal-inset",mode:"boolean"})],Yr.prototype,"horizontalInset",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"horizontal-threshold"})],Yr.prototype,"horizontalThreshold",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"horizontal-scaling"})],Yr.prototype,"horizontalScaling",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"vertical-positioning-mode"})],Yr.prototype,"verticalPositioningMode",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"vertical-default-position"})],Yr.prototype,"verticalDefaultPosition",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"vertical-viewport-lock",mode:"boolean"})],Yr.prototype,"verticalViewportLock",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"vertical-inset",mode:"boolean"})],Yr.prototype,"verticalInset",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"vertical-threshold"})],Yr.prototype,"verticalThreshold",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"vertical-scaling"})],Yr.prototype,"verticalScaling",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"fixed-placement",mode:"boolean"})],Yr.prototype,"fixedPlacement",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"auto-update-mode"})],Yr.prototype,"autoUpdateMode",void 0),(0,ii.gn)([oi.LO],Yr.prototype,"anchorElement",void 0),(0,ii.gn)([oi.LO],Yr.prototype,"viewportElement",void 0),(0,ii.gn)([oi.LO],Yr.prototype,"initialLayoutComplete",void 0);class Xr{constructor(e,t){this.cache=new WeakMap,this.ltr=e,this.rtl=t}bind(e){this.attach(e)}unbind(e){const t=this.cache.get(e);t&&qn.o7V.unsubscribe(t)}attach(e){const t=this.cache.get(e)||new Jr(this.ltr,this.rtl,e),i=qn.o7V.getValueFor(e);qn.o7V.subscribe(t),t.attach(i),this.cache.set(e,t)}}class Jr{constructor(e,t,i){this.ltr=e,this.rtl=t,this.source=i,this.attached=null}handleChange({target:e,token:t}){this.attach(t.getValueFor(this.source))}attach(e){this.attached!==this[e]&&(null!==this.attached&&this.source.$fastController.removeStyles(this.attached),this.attached=this[e],null!==this.attached&&this.source.$fastController.addStyles(this.attached))}}const Qr=Ur.compose({baseName:"menu-item",template:(e,t)=>$n`
<template
role="${e=>e.role}"
aria-haspopup="${e=>e.hasSubmenu?"menu":void 0}"
aria-checked="${e=>e.role!==Nr?e.checked:void 0}"
aria-disabled="${e=>e.disabled}"
aria-expanded="${e=>e.expanded}"
@keydown="${(e,t)=>e.handleMenuItemKeyDown(t.event)}"
@click="${(e,t)=>e.handleMenuItemClick(t.event)}"
@mouseover="${(e,t)=>e.handleMouseOver(t.event)}"
@mouseout="${(e,t)=>e.handleMouseOut(t.event)}"
class="${e=>e.disabled?"disabled":""} ${e=>e.expanded?"expanded":""} ${e=>`indent-${e.startColumnCount}`}"
>
${Wr((e=>e.role===Rr),$n`
<div part="input-container" class="input-container">
<span part="checkbox" class="checkbox">
<slot name="checkbox-indicator">
${t.checkboxIndicator||""}
</slot>
</span>
</div>
`)}
${Wr((e=>e.role===Mr),$n`
<div part="input-container" class="input-container">
<span part="radio" class="radio">
<slot name="radio-indicator">
${t.radioIndicator||""}
</slot>
</span>
</div>
`)}
</div>
${bo(0,t)}
<span class="content" part="content">
<slot></slot>
</span>
${Co(0,t)}
${Wr((e=>e.hasSubmenu),$n`
<div
part="expand-collapse-glyph-container"
class="expand-collapse-glyph-container"
>
<span part="expand-collapse" class="expand-collapse">
<slot name="expand-collapse-indicator">
${t.expandCollapseGlyph||""}
</slot>
</span>
</div>
`)}
${Wr((e=>e.expanded),$n`
<${e.tagFor(Yr)}
:anchorElement="${e=>e}"
vertical-positioning-mode="dynamic"
vertical-default-position="bottom"
vertical-inset="true"
horizontal-positioning-mode="dynamic"
horizontal-default-position="end"
class="submenu-region"
dir="${e=>e.currentDirection}"
@loaded="${e=>e.submenuLoaded()}"
${vo("submenuRegion")}
part="submenu-region"
>
<slot name="submenu"></slot>
</${e.tagFor(Yr)}>
`)}
</template>
`,styles:(e,t)=>dn`
${zn("grid")} :host {
contain: layout;
overflow: visible;
${Eo}
box-sizing: border-box;
height: calc(${Lo} * 1px);
grid-template-columns: minmax(32px, auto) 1fr minmax(32px, auto);
grid-template-rows: auto;
justify-items: center;
align-items: center;
padding: 0;
white-space: nowrap;
color: ${qn.CHi};
fill: currentcolor;
cursor: pointer;
border-radius: calc(${qn.UWU} * 1px);
border: calc(${qn.Han} * 1px) solid transparent;
position: relative;
}
:host(.indent-0) {
grid-template-columns: auto 1fr minmax(32px, auto);
}
:host(.indent-0) .content {
grid-column: 1;
grid-row: 1;
margin-inline-start: 10px;
}
:host(.indent-0) .expand-collapse-glyph-container {
grid-column: 5;
grid-row: 1;
}
:host(.indent-2) {
grid-template-columns: minmax(32px, auto) minmax(32px, auto) 1fr minmax(32px, auto) minmax(32px, auto);
}
:host(.indent-2) .content {
grid-column: 3;
grid-row: 1;
margin-inline-start: 10px;
}
:host(.indent-2) .expand-collapse-glyph-container {
grid-column: 5;
grid-row: 1;
}
:host(.indent-2) .start {
grid-column: 2;
}
:host(.indent-2) .end {
grid-column: 4;
}
:host(:${No}) {
${Ro}
}
:host(:not([disabled]):hover) {
background: ${qn.QpD};
}
:host(:not([disabled]):active),
:host(.expanded) {
background: ${qn.sG3};
color: ${qn.CHi};
z-index: 2;
}
:host([disabled]) {
cursor: ${ur};
opacity: ${qn.VFZ};
}
.content {
grid-column-start: 2;
justify-self: start;
overflow: hidden;
text-overflow: ellipsis;
}
.start,
.end {
display: flex;
justify-content: center;
}
:host(.indent-0[aria-haspopup='menu']) {
display: grid;
grid-template-columns: minmax(32px, auto) auto 1fr minmax(32px, auto) minmax(32px, auto);
align-items: center;
min-height: 32px;
}
:host(.indent-1[aria-haspopup='menu']),
:host(.indent-1[role='menuitemcheckbox']),
:host(.indent-1[role='menuitemradio']) {
display: grid;
grid-template-columns: minmax(32px, auto) auto 1fr minmax(32px, auto) minmax(32px, auto);
align-items: center;
min-height: 32px;
}
:host(.indent-2:not([aria-haspopup='menu'])) .end {
grid-column: 5;
}
:host .input-container,
:host .expand-collapse-glyph-container {
display: none;
}
:host([aria-haspopup='menu']) .expand-collapse-glyph-container,
:host([role='menuitemcheckbox']) .input-container,
:host([role='menuitemradio']) .input-container {
display: grid;
}
:host([aria-haspopup='menu']) .content,
:host([role='menuitemcheckbox']) .content,
:host([role='menuitemradio']) .content {
grid-column-start: 3;
}
:host([aria-haspopup='menu'].indent-0) .content {
grid-column-start: 1;
}
:host([aria-haspopup='menu']) .end,
:host([role='menuitemcheckbox']) .end,
:host([role='menuitemradio']) .end {
grid-column-start: 4;
}
:host .expand-collapse,
:host .checkbox,
:host .radio {
display: flex;
align-items: center;
justify-content: center;
position: relative;
box-sizing: border-box;
}
:host .checkbox-indicator,
:host .radio-indicator,
slot[name='checkbox-indicator'],
slot[name='radio-indicator'] {
display: none;
}
::slotted([slot='end']:not(svg)) {
margin-inline-end: 10px;
color: ${qn.Q5n};
}
:host([aria-checked='true']) .checkbox-indicator,
:host([aria-checked='true']) slot[name='checkbox-indicator'],
:host([aria-checked='true']) .radio-indicator,
:host([aria-checked='true']) slot[name='radio-indicator'] {
display: flex;
}
`.withBehaviors(Gn(dn`
:host,
::slotted([slot='end']:not(svg)) {
forced-color-adjust: none;
color: ${Wn.ButtonText};
fill: currentcolor;
}
:host(:not([disabled]):hover) {
background: ${Wn.Highlight};
color: ${Wn.HighlightText};
fill: currentcolor;
}
:host(:hover) .start,
:host(:hover) .end,
:host(:hover)::slotted(svg),
:host(:active) .start,
:host(:active) .end,
:host(:active)::slotted(svg),
:host(:hover) ::slotted([slot='end']:not(svg)),
:host(:${No}) ::slotted([slot='end']:not(svg)) {
color: ${Wn.HighlightText};
fill: currentcolor;
}
:host(.expanded) {
background: ${Wn.Highlight};
color: ${Wn.HighlightText};
}
:host(:${No}) {
background: ${Wn.Highlight};
outline-color: ${Wn.ButtonText};
color: ${Wn.HighlightText};
fill: currentcolor;
}
:host([disabled]),
:host([disabled]:hover),
:host([disabled]:hover) .start,
:host([disabled]:hover) .end,
:host([disabled]:hover)::slotted(svg),
:host([disabled]:${No}) {
background: ${Wn.ButtonFace};
color: ${Wn.GrayText};
fill: currentcolor;
opacity: 1;
}
:host([disabled]:${No}) {
outline-color: ${Wn.GrayText};
}
:host .expanded-toggle,
:host .checkbox,
:host .radio {
border-color: ${Wn.ButtonText};
background: ${Wn.HighlightText};
}
:host([checked]) .checkbox,
:host([checked]) .radio {
background: ${Wn.HighlightText};
border-color: ${Wn.HighlightText};
}
:host(:hover) .expanded-toggle,
:host(:hover) .checkbox,
:host(:hover) .radio,
:host(:${No}) .expanded-toggle,
:host(:${No}) .checkbox,
:host(:${No}) .radio,
:host([checked]:hover) .checkbox,
:host([checked]:hover) .radio,
:host([checked]:${No}) .checkbox,
:host([checked]:${No}) .radio {
border-color: ${Wn.HighlightText};
}
:host([aria-checked='true']) {
background: ${Wn.Highlight};
color: ${Wn.HighlightText};
}
:host([aria-checked='true']) .checkbox-indicator,
:host([aria-checked='true']) ::slotted([slot='checkbox-indicator']),
:host([aria-checked='true']) ::slotted([slot='radio-indicator']) {
fill: ${Wn.Highlight};
}
:host([aria-checked='true']) .radio-indicator {
background: ${Wn.Highlight};
}
`),new Xr(dn`
.expand-collapse-glyph-container {
transform: rotate(0deg);
}
`,dn`
.expand-collapse-glyph-container {
transform: rotate(180deg);
}
`)),checkboxIndicator:'\n <svg width="16" height="16" xmlns="http://www.w3.org/2000/svg">\n <path d="M13.86 3.66a.5.5 0 01-.02.7l-7.93 7.48a.6.6 0 01-.84-.02L2.4 9.1a.5.5 0 01.72-.7l2.4 2.44 7.65-7.2a.5.5 0 01.7.02z"/>\n </svg>\n ',expandCollapseGlyph:'\n <svg width="16" height="16" xmlns="http://www.w3.org/2000/svg">\n <path d="M5.65 3.15a.5.5 0 000 .7L9.79 8l-4.14 4.15a.5.5 0 00.7.7l4.5-4.5a.5.5 0 000-.7l-4.5-4.5a.5.5 0 00-.7 0z"/>\n </svg>\n ',radioIndicator:'\n <svg width="16" height="16" xmlns="http://www.w3.org/2000/svg">\n <circle cx="8" cy="8" r="2"/>\n </svg>\n '});class ea extends zi{}(0,ii.gn)([(0,pn.Lj)({mode:"boolean"})],ea.prototype,"disabled",void 0);const ta=ea.compose({baseName:"tab",template:(e,t)=>$n`
<template slot="tab" role="tab" aria-disabled="${e=>e.disabled}">
<slot></slot>
</template>
`,styles:(e,t)=>dn`
${zn("inline-flex")} :host {
box-sizing: border-box;
${Eo}
height: calc((${Lo} + (${qn._5n} * 2)) * 1px);
padding: 0 calc((6 + (${qn._5n} * 2 * ${qn.hVk})) * 1px);
color: ${qn.CHi};
border-radius: calc(${qn.UWU} * 1px);
border: calc(${qn.Han} * 1px) solid transparent;
align-items: center;
justify-content: center;
grid-row: 1 / 3;
cursor: pointer;
}
:host([aria-selected='true']) {
z-index: 2;
}
:host(:hover),
:host(:active) {
color: ${qn.CHi};
}
:host(:${No}) {
${Ro}
}
:host(.vertical) {
justify-content: start;
grid-column: 1 / 3;
}
:host(.vertical[aria-selected='true']) {
z-index: 2;
}
:host(.vertical:hover),
:host(.vertical:active) {
color: ${qn.CHi};
}
:host(.vertical:hover[aria-selected='true']) {
}
`.withBehaviors(Gn(dn`
:host {
forced-color-adjust: none;
border-color: transparent;
color: ${Wn.ButtonText};
fill: currentcolor;
}
:host(:hover),
:host(.vertical:hover),
:host([aria-selected='true']:hover) {
background: transparent;
color: ${Wn.Highlight};
fill: currentcolor;
}
:host([aria-selected='true']) {
background: transparent;
color: ${Wn.Highlight};
fill: currentcolor;
}
:host(:${No}) {
background: transparent;
outline-color: ${Wn.ButtonText};
}
`))}),ia=class extends zi{}.compose({baseName:"tab-panel",template:(e,t)=>$n`
<template slot="tabpanel" role="tabpanel">
<slot></slot>
</template>
`,styles:(e,t)=>dn`
${zn("block")} :host {
box-sizing: border-box;
${Eo}
padding: 0 calc((6 + (${qn._5n} * 2 * ${qn.hVk})) * 1px);
}
`});let na=0;function oa(e=""){return`${e}${na++}`}const ra="horizontal";class aa extends zi{constructor(){super(...arguments),this.orientation=ra,this.activeindicator=!0,this.showActiveIndicator=!0,this.prevActiveTabIndex=0,this.activeTabIndex=0,this.ticking=!1,this.change=()=>{this.$emit("change",this.activetab)},this.isDisabledElement=e=>"true"===e.getAttribute("aria-disabled"),this.isFocusableElement=e=>!this.isDisabledElement(e),this.setTabs=()=>{const e="gridColumn",t="gridRow",i=this.isHorizontal()?e:t;this.activeTabIndex=this.getActiveIndex(),this.showActiveIndicator=!1,this.tabs.forEach(((n,o)=>{if("tab"===n.slot){const e=this.activeTabIndex===o&&this.isFocusableElement(n);this.activeindicator&&this.isFocusableElement(n)&&(this.showActiveIndicator=!0);const t=this.tabIds[o],i=this.tabpanelIds[o];n.setAttribute("id",t),n.setAttribute("aria-selected",e?"true":"false"),n.setAttribute("aria-controls",i),n.addEventListener("click",this.handleTabClick),n.addEventListener("keydown",this.handleTabKeyDown),n.setAttribute("tabindex",e?"0":"-1"),e&&(this.activetab=n)}n.style[e]="",n.style[t]="",n.style[i]=`${o+1}`,this.isHorizontal()?n.classList.remove("vertical"):n.classList.add("vertical")}))},this.setTabPanels=()=>{this.tabpanels.forEach(((e,t)=>{const i=this.tabIds[t],n=this.tabpanelIds[t];e.setAttribute("id",n),e.setAttribute("aria-labelledby",i),this.activeTabIndex!==t?e.setAttribute("hidden",""):e.removeAttribute("hidden")}))},this.handleTabClick=e=>{const t=e.currentTarget;1===t.nodeType&&this.isFocusableElement(t)&&(this.prevActiveTabIndex=this.activeTabIndex,this.activeTabIndex=this.tabs.indexOf(t),this.setComponent())},this.handleTabKeyDown=e=>{if(this.isHorizontal())switch(e.key){case no:e.preventDefault(),this.adjustBackward(e);break;case oo:e.preventDefault(),this.adjustForward(e)}else switch(e.key){case ro:e.preventDefault(),this.adjustBackward(e);break;case io:e.preventDefault(),this.adjustForward(e)}switch(e.key){case lo:e.preventDefault(),this.adjust(-this.activeTabIndex);break;case co:e.preventDefault(),this.adjust(this.tabs.length-this.activeTabIndex-1)}},this.adjustForward=e=>{const t=this.tabs;let i=0;for(i=this.activetab?t.indexOf(this.activetab)+1:1,i===t.length&&(i=0);i<t.length&&t.length>1;){if(this.isFocusableElement(t[i])){this.moveToTabByIndex(t,i);break}if(this.activetab&&i===t.indexOf(this.activetab))break;i+1>=t.length?i=0:i+=1}},this.adjustBackward=e=>{const t=this.tabs;let i=0;for(i=this.activetab?t.indexOf(this.activetab)-1:0,i=i<0?t.length-1:i;i>=0&&t.length>1;){if(this.isFocusableElement(t[i])){this.moveToTabByIndex(t,i);break}i-1<0?i=t.length-1:i-=1}},this.moveToTabByIndex=(e,t)=>{const i=e[t];this.activetab=i,this.prevActiveTabIndex=this.activeTabIndex,this.activeTabIndex=t,i.focus(),this.setComponent()}}orientationChanged(){this.$fastController.isConnected&&(this.setTabs(),this.setTabPanels(),this.handleActiveIndicatorPosition())}activeidChanged(e,t){this.$fastController.isConnected&&this.tabs.length<=this.tabpanels.length&&(this.prevActiveTabIndex=this.tabs.findIndex((t=>t.id===e)),this.setTabs(),this.setTabPanels(),this.handleActiveIndicatorPosition())}tabsChanged(){this.$fastController.isConnected&&this.tabs.length<=this.tabpanels.length&&(this.tabIds=this.getTabIds(),this.tabpanelIds=this.getTabPanelIds(),this.setTabs(),this.setTabPanels(),this.handleActiveIndicatorPosition())}tabpanelsChanged(){this.$fastController.isConnected&&this.tabpanels.length<=this.tabs.length&&(this.tabIds=this.getTabIds(),this.tabpanelIds=this.getTabPanelIds(),this.setTabs(),this.setTabPanels(),this.handleActiveIndicatorPosition())}getActiveIndex(){return void 0!==this.activeid?-1===this.tabIds.indexOf(this.activeid)?0:this.tabIds.indexOf(this.activeid):0}getTabIds(){return this.tabs.map((e=>{var t;return null!==(t=e.getAttribute("id"))&&void 0!==t?t:`tab-${oa()}`}))}getTabPanelIds(){return this.tabpanels.map((e=>{var t;return null!==(t=e.getAttribute("id"))&&void 0!==t?t:`panel-${oa()}`}))}setComponent(){this.activeTabIndex!==this.prevActiveTabIndex&&(this.activeid=this.tabIds[this.activeTabIndex],this.focusTab(),this.change())}isHorizontal(){return this.orientation===ra}handleActiveIndicatorPosition(){this.showActiveIndicator&&this.activeindicator&&this.activeTabIndex!==this.prevActiveTabIndex&&(this.ticking?this.ticking=!1:(this.ticking=!0,this.animateActiveIndicator()))}animateActiveIndicator(){this.ticking=!0;const e=this.isHorizontal()?"gridColumn":"gridRow",t=this.isHorizontal()?"translateX":"translateY",i=this.isHorizontal()?"offsetLeft":"offsetTop",n=this.activeIndicatorRef[i];this.activeIndicatorRef.style[e]=`${this.activeTabIndex+1}`;const o=this.activeIndicatorRef[i];this.activeIndicatorRef.style[e]=`${this.prevActiveTabIndex+1}`;const r=o-n;this.activeIndicatorRef.style.transform=`${t}(${r}px)`,this.activeIndicatorRef.classList.add("activeIndicatorTransition"),this.activeIndicatorRef.addEventListener("transitionend",(()=>{this.ticking=!1,this.activeIndicatorRef.style[e]=`${this.activeTabIndex+1}`,this.activeIndicatorRef.style.transform=`${t}(0px)`,this.activeIndicatorRef.classList.remove("activeIndicatorTransition")}))}adjust(e){this.prevActiveTabIndex=this.activeTabIndex,this.activeTabIndex=go(0,this.tabs.length-1,this.activeTabIndex+e),this.setComponent()}focusTab(){this.tabs[this.activeTabIndex].focus()}connectedCallback(){super.connectedCallback(),this.tabIds=this.getTabIds(),this.tabpanelIds=this.getTabPanelIds(),this.activeTabIndex=this.getActiveIndex()}}(0,ii.gn)([pn.Lj],aa.prototype,"orientation",void 0),(0,ii.gn)([pn.Lj],aa.prototype,"activeid",void 0),(0,ii.gn)([oi.LO],aa.prototype,"tabs",void 0),(0,ii.gn)([oi.LO],aa.prototype,"tabpanels",void 0),(0,ii.gn)([(0,pn.Lj)({mode:"boolean"})],aa.prototype,"activeindicator",void 0),(0,ii.gn)([oi.LO],aa.prototype,"activeIndicatorRef",void 0),(0,ii.gn)([oi.LO],aa.prototype,"showActiveIndicator",void 0),So(aa,yo);const sa=aa.compose({baseName:"tabs",template:(e,t)=>$n`
<template class="${e=>e.orientation}">
${bo(0,t)}
<div class="tablist" part="tablist" role="tablist">
<slot class="tab" name="tab" part="tab" ${Ao("tabs")}></slot>
${Wr((e=>e.showActiveIndicator),$n`
<div
${vo("activeIndicatorRef")}
class="activeIndicator"
part="activeIndicator"
></div>
`)}
</div>
${Co(0,t)}
<div class="tabpanel" part="tabpanel">
<slot name="tabpanel" ${Ao("tabpanels")}></slot>
</div>
</template>
`,styles:(e,t)=>dn`
${zn("grid")} :host {
box-sizing: border-box;
${Eo}
color: ${qn.CHi};
grid-template-columns: auto 1fr auto;
grid-template-rows: auto 1fr;
}
.tablist {
display: grid;
grid-template-rows: calc(${Lo} * 1px); auto;
grid-template-columns: auto;
position: relative;
width: max-content;
align-self: end;
}
.start,
.end {
align-self: center;
}
.activeIndicator {
grid-row: 2;
grid-column: 1;
width: 20px;
height: 3px;
border-radius: calc(${qn.UWU} * 1px);
justify-self: center;
background: ${qn.Avx};
}
.activeIndicatorTransition {
transition: transform 0.2s ease-in-out;
}
.tabpanel {
grid-row: 2;
grid-column-start: 1;
grid-column-end: 4;
position: relative;
}
:host(.vertical) {
grid-template-rows: auto 1fr auto;
grid-template-columns: auto 1fr;
}
:host(.vertical) .tablist {
grid-row-start: 2;
grid-row-end: 2;
display: grid;
grid-template-rows: auto;
grid-template-columns: auto 1fr;
position: relative;
width: max-content;
justify-self: end;
align-self: flex-start;
width: 100%;
}
:host(.vertical) .tabpanel {
grid-column: 2;
grid-row-start: 1;
grid-row-end: 4;
}
:host(.vertical) .end {
grid-row: 3;
}
:host(.vertical) .activeIndicator {
grid-column: 1;
grid-row: 1;
width: 3px;
height: 20px;
margin-inline-start: calc(${qn.vxp} * 1px);
border-radius: calc(${qn.UWU} * 1px);
align-self: center;
background: ${qn.Avx};
}
:host(.vertical) .activeIndicatorTransition {
transition: transform 0.2s linear;
}
`.withBehaviors(Gn(dn`
.activeIndicator,
:host(.vertical) .activeIndicator {
background: ${Wn.Highlight};
}
`))});class la extends zi{constructor(){super(...arguments),this.generateBadgeStyle=()=>{if(!this.fill&&!this.color)return;const e=`background-color: var(--badge-fill-${this.fill});`,t=`color: var(--badge-color-${this.color});`;return this.fill&&!this.color?e:this.color&&!this.fill?t:`${t} ${e}`}}}(0,ii.gn)([(0,pn.Lj)({attribute:"fill"})],la.prototype,"fill",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"color"})],la.prototype,"color",void 0),(0,ii.gn)([(0,pn.Lj)({mode:"boolean"})],la.prototype,"circular",void 0);class ca extends la{constructor(){super(...arguments),this.appearance="lightweight"}appearanceChanged(e,t){e!==t&&gn.SO.queueUpdate((()=>{this.classList.add(t),this.classList.remove(e)}))}}(0,an.gn)([(0,pn.Lj)({mode:"fromView"})],ca.prototype,"appearance",void 0);const da=ca.compose({baseName:"badge",baseClass:la,template:(e,t)=>$n`
<template class="${e=>e.circular?"circular":""}">
<div class="control" part="control" style="${e=>e.generateBadgeStyle()}">
<slot></slot>
</div>
</template>
`,styles:(e,t)=>dn`
${zn("inline-block")} :host {
box-sizing: border-box;
${ko};
}
.control {
border-radius: calc(${qn.UWU} * 1px);
padding: calc(((${qn._5n} * 0.5) - ${qn.Han}) * 1px) calc((${qn._5n} - ${qn.Han}) * 1px);
border: calc(${qn.Han} * 1px) solid transparent;
}
:host(.lightweight) .control {
background: transparent;
color: ${qn.CHi};
font-weight: 600;
}
:host(.accent) .control {
background: ${qn.Avx};
color: ${qn.w41};
}
:host(.neutral) .control {
background: ${qn._jX};
color: ${qn.CHi};
}
:host([circular]) .control {
border-radius: 100px;
min-width: calc(${qn.vgC} - calc(${qn._5n} * 1px));
display: flex;
align-items: center;
justify-content: center;
}
`});class ua extends zi{}class ha extends(ar(ua)){constructor(){super(...arguments),this.proxy=document.createElement("input")}}class pa extends ha{constructor(){super(),this.initialValue="on",this.keypressHandler=e=>{if(!this.readOnly)switch(e.key){case ao:case uo:this.checked=!this.checked}},this.clickHandler=e=>{this.disabled||this.readOnly||(this.checked=!this.checked)},this.proxy.setAttribute("type","checkbox")}readOnlyChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.readOnly=this.readOnly),this.readOnly?this.classList.add("readonly"):this.classList.remove("readonly")}checkedChanged(e,t){super.checkedChanged(e,t),this.checked?this.classList.add("checked"):this.classList.remove("checked")}}(0,ii.gn)([(0,pn.Lj)({attribute:"readonly",mode:"boolean"})],pa.prototype,"readOnly",void 0),(0,ii.gn)([oi.LO],pa.prototype,"defaultSlottedNodes",void 0);const ga=pa.compose({baseName:"switch",template:(e,t)=>$n`
<template
role="switch"
aria-checked="${e=>e.checked}"
aria-disabled="${e=>e.disabled}"
aria-readonly="${e=>e.readOnly}"
tabindex="${e=>e.disabled?null:0}"
@keypress="${(e,t)=>e.keypressHandler(t.event)}"
@click="${(e,t)=>e.clickHandler(t.event)}"
class="${e=>e.checked?"checked":""}"
>
<label
part="label"
class="${e=>e.defaultSlottedNodes&&e.defaultSlottedNodes.length?"label":"label label__hidden"}"
>
<slot ${Ao("defaultSlottedNodes")}></slot>
</label>
<div part="switch" class="switch">
<slot name="switch">${t.switch||""}</slot>
</div>
<span class="status-message" part="status-message">
<span class="checked-message" part="checked-message">
<slot name="checked-message"></slot>
</span>
<span class="unchecked-message" part="unchecked-message">
<slot name="unchecked-message"></slot>
</span>
</span>
</template>
`,styles:(e,t)=>dn`
:host([hidden]) {
display: none;
}
${zn("inline-flex")} :host {
align-items: center;
outline: none;
font-family: ${qn.SVJ};
${""} user-select: none;
}
:host(.disabled) {
opacity: ${qn.VFZ};
}
:host(.disabled) .label,
:host(.readonly) .label,
:host(.disabled) .switch,
:host(.readonly) .switch,
:host(.disabled) .status-message,
:host(.readonly) .status-message {
cursor: ${ur};
}
.switch {
position: relative;
box-sizing: border-box;
width: calc(((${Lo} / 2) + ${qn._5n}) * 2px);
height: calc(((${Lo} / 2) + ${qn._5n}) * 1px);
background: ${qn.pB6};
border-radius: calc(${Lo} * 1px);
border: calc(${qn.Han} * 1px) solid ${qn.rU8};
cursor: pointer;
}
:host(:not(.disabled):hover) .switch {
background: ${qn.vFq};
border-color: ${qn.gKw};
}
:host(:not(.disabled):active) .switch {
background: ${qn.bWE};
border-color: ${qn.ekh};
}
:host(:${No}) .switch {
${Mo}
background: ${qn.W3V};
}
:host(.checked) .switch {
background: ${qn.Avx};
border-color: transparent;
}
:host(.checked:not(.disabled):hover) .switch {
background: ${qn.OCG};
border-color: transparent;
}
:host(.checked:not(.disabled):active) .switch {
background: ${qn.UEO};
border-color: transparent;
}
slot[name='switch'] {
position: absolute;
display: flex;
border: 1px solid transparent; /* Spacing included in the transform reference box */
fill: ${qn.CHi};
transition: all 0.2s ease-in-out;
}
.status-message {
color: ${qn.CHi};
cursor: pointer;
${Eo}
}
.label__hidden {
display: none;
visibility: hidden;
}
.label {
color: ${qn.CHi};
${Eo}
margin-inline-end: calc(${qn._5n} * 2px + 2px);
cursor: pointer;
}
::slotted([slot="checked-message"]),
::slotted([slot="unchecked-message"]) {
margin-inline-start: calc(${qn._5n} * 2px + 2px);
}
:host(.checked) .switch {
background: ${qn.Avx};
}
:host(.checked) .switch slot[name='switch'] {
fill: ${qn.w41};
filter: drop-shadow(0px 1px 1px rgba(0, 0, 0, 0.15));
}
:host(.checked:not(.disabled)) .switch:hover {
background: ${qn.OCG};
}
:host(.checked:not(.disabled)) .switch:hover slot[name='switch'] {
fill: ${qn.lJV};
}
:host(.checked:not(.disabled)) .switch:active {
background: ${qn.UEO};
}
:host(.checked:not(.disabled)) .switch:active slot[name='switch'] {
fill: ${qn.PpH};
}
.unchecked-message {
display: block;
}
.checked-message {
display: none;
}
:host(.checked) .unchecked-message {
display: none;
}
:host(.checked) .checked-message {
display: block;
}
`.withBehaviors(new Xr(dn`
slot[name='switch'] {
left: 0;
}
:host(.checked) slot[name='switch'] {
left: 100%;
transform: translateX(-100%);
}
`,dn`
slot[name='switch'] {
right: 0;
}
:host(.checked) slot[name='switch'] {
right: 100%;
transform: translateX(100%);
}
`),Gn(dn`
:host(:not(.disabled)) .switch slot[name='switch'] {
forced-color-adjust: none;
fill: ${Wn.FieldText};
}
.switch {
background: ${Wn.Field};
border-color: ${Wn.FieldText};
}
:host(.checked) .switch {
background: ${Wn.Highlight};
border-color: ${Wn.Highlight};
}
:host(:not(.disabled):hover) .switch ,
:host(:not(.disabled):active) .switch,
:host(.checked:not(.disabled):hover) .switch {
background: ${Wn.HighlightText};
border-color: ${Wn.Highlight};
}
:host(.checked:not(.disabled)) .switch slot[name="switch"] {
fill: ${Wn.HighlightText};
}
:host(.checked:not(.disabled):hover) .switch slot[name='switch'] {
fill: ${Wn.Highlight};
}
:host(:${No}) .switch {
forced-color-adjust: none;
background: ${Wn.Field};
border-color: ${Wn.Highlight};
outline-color: ${Wn.FieldText};
}
:host(.disabled) {
opacity: 1;
}
:host(.disabled) slot[name='switch'] {
forced-color-adjust: none;
fill: ${Wn.GrayText};
}
:host(.disabled) .switch {
background: ${Wn.Field};
border-color: ${Wn.GrayText};
}
.status-message,
.label {
color: ${Wn.FieldText};
}
`)),switch:'\n <svg width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">\n <rect x="2" y="2" width="12" height="12" rx="6"/>\n </svg>\n '});class fa extends zi{}class ma extends(rr(fa)){constructor(){super(...arguments),this.proxy=document.createElement("input")}}class va extends ma{constructor(){super(...arguments),this.type="text"}readOnlyChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.readOnly=this.readOnly,this.validate())}autofocusChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.autofocus=this.autofocus,this.validate())}placeholderChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.placeholder=this.placeholder)}typeChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.type=this.type,this.validate())}listChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.setAttribute("list",this.list),this.validate())}maxlengthChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.maxLength=this.maxlength,this.validate())}minlengthChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.minLength=this.minlength,this.validate())}patternChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.pattern=this.pattern,this.validate())}sizeChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.size=this.size)}spellcheckChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.spellcheck=this.spellcheck)}connectedCallback(){super.connectedCallback(),this.proxy.setAttribute("type",this.type),this.validate(),this.autofocus&&gn.SO.queueUpdate((()=>{this.focus()}))}select(){this.control.select(),this.$emit("select")}handleTextInput(){this.value=this.control.value}handleChange(){this.$emit("change")}validate(){super.validate(this.control)}}(0,ii.gn)([(0,pn.Lj)({attribute:"readonly",mode:"boolean"})],va.prototype,"readOnly",void 0),(0,ii.gn)([(0,pn.Lj)({mode:"boolean"})],va.prototype,"autofocus",void 0),(0,ii.gn)([pn.Lj],va.prototype,"placeholder",void 0),(0,ii.gn)([pn.Lj],va.prototype,"type",void 0),(0,ii.gn)([pn.Lj],va.prototype,"list",void 0),(0,ii.gn)([(0,pn.Lj)({converter:pn.Id})],va.prototype,"maxlength",void 0),(0,ii.gn)([(0,pn.Lj)({converter:pn.Id})],va.prototype,"minlength",void 0),(0,ii.gn)([pn.Lj],va.prototype,"pattern",void 0),(0,ii.gn)([(0,pn.Lj)({converter:pn.Id})],va.prototype,"size",void 0),(0,ii.gn)([(0,pn.Lj)({mode:"boolean"})],va.prototype,"spellcheck",void 0),(0,ii.gn)([oi.LO],va.prototype,"defaultSlottedNodes",void 0);class ya{}function Ca(e,t,i){return e.nodeType!==Node.TEXT_NODE||"string"==typeof e.nodeValue&&!!e.nodeValue.trim().length}So(ya,$o),So(va,yo,ya);const ba=qi.DesignToken.create("input-placeholder-rest").withDefault((e=>{const t=qn.smF.getValueFor(e);return qn.axZ.getValueFor(e).evaluate(e,t.evaluate(e).rest)})),Sa=qi.DesignToken.create("input-placeholder-hover").withDefault((e=>{const t=qn.smF.getValueFor(e);return qn.axZ.getValueFor(e).evaluate(e,t.evaluate(e).hover)})),xa=qi.DesignToken.create("input-filled-placeholder-rest").withDefault((e=>{const t=qn.TuC.getValueFor(e);return qn.axZ.getValueFor(e).evaluate(e,t.evaluate(e).rest)})),Ta=qi.DesignToken.create("input-filled-placeholder-hover").withDefault((e=>{const t=qn.TuC.getValueFor(e);return qn.axZ.getValueFor(e).evaluate(e,t.evaluate(e).hover)})),wa=(e,t,i,n=":not([disabled]):not(:focus-within)")=>dn`
${i} {
background: ${qn._jX};
}
:host(${n}:hover) ${i} {
background: ${qn.d$x};
}
:host(:not([disabled]):focus-within) ${i} {
background: ${qn.KTo};
}
:host([disabled]) ${i} {
background: ${qn._jX};
}
.control::placeholder {
color: ${xa};
}
:host(${n}:hover) .control::placeholder {
color: ${Ta};
}
`,Oa=(e,t,i,n=":not([disabled]):not(:focus-within)")=>dn`
:host {
color: ${Wn.ButtonText};
}
${i} {
background: ${Wn.ButtonFace};
border-color: ${Wn.ButtonText};
}
:host(${n}:hover) ${i},
:host(:not([disabled]):focus-within) ${i} {
border-color: ${Wn.Highlight};
}
:host([disabled]) ${i} {
opacity: 1;
background: ${Wn.ButtonFace};
border-color: ${Wn.GrayText};
}
.control::placeholder,
:host(${n}:hover) .control::placeholder {
color: ${Wn.CanvasText};
}
:host(:not([disabled]):focus) ${i} {
${Ro}
outline-color: ${Wn.Highlight};
}
:host([disabled]) {
opacity: 1;
color: ${Wn.GrayText};
}
:host([disabled]) ::placeholder,
:host([disabled]) ::-webkit-input-placeholder {
color: ${Wn.GrayText};
}
`,Pa=".root";class Aa extends va{appearanceChanged(e,t){e!==t&&(this.classList.add(t),this.classList.remove(e))}connectedCallback(){super.connectedCallback(),this.appearance||(this.appearance="outline")}}(0,an.gn)([pn.Lj],Aa.prototype,"appearance",void 0);const Ea=Aa.compose({baseName:"text-field",baseClass:va,template:(e,t)=>$n`
<template
class="
${e=>e.readOnly?"readonly":""}
"
>
<label
part="label"
for="control"
class="${e=>e.defaultSlottedNodes&&e.defaultSlottedNodes.length?"label":"label label__hidden"}"
>
<slot
${Ao({property:"defaultSlottedNodes",filter:Ca})}
></slot>
</label>
<div class="root" part="root">
${bo(0,t)}
<input
class="control"
part="control"
id="control"
@input="${e=>e.handleTextInput()}"
@change="${e=>e.handleChange()}"
?autofocus="${e=>e.autofocus}"
?disabled="${e=>e.disabled}"
list="${e=>e.list}"
maxlength="${e=>e.maxlength}"
minlength="${e=>e.minlength}"
pattern="${e=>e.pattern}"
placeholder="${e=>e.placeholder}"
?readonly="${e=>e.readOnly}"
?required="${e=>e.required}"
size="${e=>e.size}"
?spellcheck="${e=>e.spellcheck}"
:value="${e=>e.value}"
type="${e=>e.type}"
aria-atomic="${e=>e.ariaAtomic}"
aria-busy="${e=>e.ariaBusy}"
aria-controls="${e=>e.ariaControls}"
aria-current="${e=>e.ariaCurrent}"
aria-describedby="${e=>e.ariaDescribedby}"
aria-details="${e=>e.ariaDetails}"
aria-disabled="${e=>e.ariaDisabled}"
aria-errormessage="${e=>e.ariaErrormessage}"
aria-flowto="${e=>e.ariaFlowto}"
aria-haspopup="${e=>e.ariaHaspopup}"
aria-hidden="${e=>e.ariaHidden}"
aria-invalid="${e=>e.ariaInvalid}"
aria-keyshortcuts="${e=>e.ariaKeyshortcuts}"
aria-label="${e=>e.ariaLabel}"
aria-labelledby="${e=>e.ariaLabelledby}"
aria-live="${e=>e.ariaLive}"
aria-owns="${e=>e.ariaOwns}"
aria-relevant="${e=>e.ariaRelevant}"
aria-roledescription="${e=>e.ariaRoledescription}"
${vo("control")}
/>
${Co(0,t)}
</div>
</template>
`,styles:(e,t)=>dn`
${zn("inline-block")}
${((e,t,i)=>dn`
:host {
${Eo}
color: ${qn.CHi};
fill: currentcolor;
user-select: none;
position: relative;
}
${i} {
box-sizing: border-box;
position: relative;
color: inherit;
border: calc(${qn.Han} * 1px) solid transparent;
border-radius: calc(${qn.UWU} * 1px);
height: calc(${Lo} * 1px);
font-family: inherit;
font-size: inherit;
line-height: inherit;
}
.control {
width: 100%;
outline: none;
}
.label {
display: block;
color: ${qn.CHi};
cursor: pointer;
${Eo}
margin-bottom: 4px;
}
.label__hidden {
display: none;
visibility: hidden;
}
:host([disabled]) ${i},
:host([readonly]) ${i},
:host([disabled]) .label,
:host([readonly]) .label,
:host([disabled]) .control,
:host([readonly]) .control {
cursor: ${ur};
}
:host([disabled]) {
opacity: ${qn.VFZ};
}
`)(0,0,Pa)}
${dn`
@media (forced-colors: none) {
:host(:not([disabled]):active)::after {
left: 50%;
width: 40%;
transform: translateX(-50%);
border-bottom-left-radius: 0;
border-bottom-right-radius: 0;
}
:host(:not([disabled]):focus-within)::after {
left: 0;
width: 100%;
transform: none;
}
:host(:not([disabled]):active)::after,
:host(:not([disabled]):focus-within:not(:active))::after {
content: '';
position: absolute;
height: calc(${qn.vxp} * 1px);
bottom: 0;
border-bottom: calc(${qn.vxp} * 1px) solid ${qn.Avx};
border-bottom-left-radius: calc(${qn.UWU} * 1px);
border-bottom-right-radius: calc(${qn.UWU} * 1px);
z-index: 2;
transition: all 300ms cubic-bezier(0.1, 0.9, 0.2, 1);
}
}
`}
.root {
display: flex;
flex-direction: row;
}
.control {
-webkit-appearance: none;
color: inherit;
background: transparent;
border: 0;
height: calc(100% - 4px);
margin-top: auto;
margin-bottom: auto;
padding: 0 calc(${qn._5n} * 2px + 1px);
font-family: inherit;
font-size: inherit;
line-height: inherit;
}
.start,
.end {
display: flex;
margin: auto;
}
.start {
display: flex;
margin-inline-start: 11px;
}
.end {
display: flex;
margin-inline-end: 11px;
}
`.withBehaviors(Xo("outline",((e,t,i,n=":not([disabled]):not(:focus-within)")=>dn`
${i} {
background: padding-box linear-gradient(${qn._Bj}, ${qn._Bj}),
border-box ${qn.iAs};
}
:host(${n}:hover) ${i} {
background: padding-box linear-gradient(${qn.Tm7}, ${qn.Tm7}),
border-box ${qn.zt3};
}
:host(:not([disabled]):focus-within) ${i} {
background: padding-box linear-gradient(${qn.rFm}, ${qn.rFm}),
border-box ${qn.iAs};
}
:host([disabled]) ${i} {
background: padding-box linear-gradient(${qn._Bj}, ${qn._Bj}),
border-box ${qn.akT};
}
.control::placeholder {
color: ${ba};
}
:host(${n}:hover) .control::placeholder {
color: ${Sa};
}
`)(0,0,Pa)),Xo("filled",wa(0,0,Pa)),Gn(Oa(0,0,Pa))),shadowOptions:{delegatesFocus:!0}});class ka extends zi{}class Ia extends(ar(ka)){constructor(){super(...arguments),this.proxy=document.createElement("input")}}class Da extends Ia{constructor(){super(),this.initialValue="on",this.indeterminate=!1,this.keypressHandler=e=>{this.readOnly||e.key!==uo||(this.indeterminate&&(this.indeterminate=!1),this.checked=!this.checked)},this.clickHandler=e=>{this.disabled||this.readOnly||(this.indeterminate&&(this.indeterminate=!1),this.checked=!this.checked)},this.proxy.setAttribute("type","checkbox")}readOnlyChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.readOnly=this.readOnly)}}(0,ii.gn)([(0,pn.Lj)({attribute:"readonly",mode:"boolean"})],Da.prototype,"readOnly",void 0),(0,ii.gn)([oi.LO],Da.prototype,"defaultSlottedNodes",void 0),(0,ii.gn)([oi.LO],Da.prototype,"indeterminate",void 0);const _a=Da.compose({baseName:"checkbox",template:(e,t)=>$n`
<template
role="checkbox"
aria-checked="${e=>e.checked}"
aria-required="${e=>e.required}"
aria-disabled="${e=>e.disabled}"
aria-readonly="${e=>e.readOnly}"
tabindex="${e=>e.disabled?null:0}"
@keypress="${(e,t)=>e.keypressHandler(t.event)}"
@click="${(e,t)=>e.clickHandler(t.event)}"
class="${e=>e.readOnly?"readonly":""} ${e=>e.checked?"checked":""} ${e=>e.indeterminate?"indeterminate":""}"
>
<div part="control" class="control">
<slot name="checked-indicator">
${t.checkedIndicator||""}
</slot>
<slot name="indeterminate-indicator">
${t.indeterminateIndicator||""}
</slot>
</div>
<label
part="label"
class="${e=>e.defaultSlottedNodes&&e.defaultSlottedNodes.length?"label":"label label__hidden"}"
>
<slot ${Ao("defaultSlottedNodes")}></slot>
</label>
</template>
`,styles:(e,t)=>dn`
${zn("inline-flex")} :host {
align-items: center;
outline: none;
${""} user-select: none;
}
.control {
position: relative;
width: calc((${Lo} / 2 + ${qn._5n}) * 1px);
height: calc((${Lo} / 2 + ${qn._5n}) * 1px);
box-sizing: border-box;
border-radius: calc(${qn.UWU} * 1px);
border: calc(${qn.Han} * 1px) solid ${qn.rU8};
background: ${qn.pB6};
cursor: pointer;
}
.label__hidden {
display: none;
visibility: hidden;
}
.label {
${Eo}
color: ${qn.CHi};
${""} padding-inline-start: calc(${qn._5n} * 2px + 2px);
margin-inline-end: calc(${qn._5n} * 2px + 2px);
cursor: pointer;
}
slot[name='checked-indicator'],
slot[name='indeterminate-indicator'] {
display: flex;
align-items: center;
justify-content: center;
width: 100%;
height: 100%;
fill: ${qn.CHi};
opacity: 0;
pointer-events: none;
}
slot[name='indeterminate-indicator'] {
position: absolute;
top: 0;
}
:host(.checked) slot[name='checked-indicator'],
:host(.checked) slot[name='indeterminate-indicator'] {
fill: ${qn.w41};
}
:host(:not(.disabled):hover) .control {
background: ${qn.vFq};
border-color: ${qn.gKw};
}
:host(:not(.disabled):active) .control {
background: ${qn.bWE};
border-color: ${qn.ekh};
}
:host(:${No}) .control {
background: ${qn.W3V};
${Mo}
}
:host(.checked) .control {
background: ${qn.Avx};
border-color: transparent;
}
:host(.checked:not(.disabled):hover) .control {
background: ${qn.OCG};
border-color: transparent;
}
:host(.checked:not(.disabled):active) .control {
background: ${qn.UEO};
border-color: transparent;
}
:host(.disabled) .label,
:host(.readonly) .label,
:host(.readonly) .control,
:host(.disabled) .control {
cursor: ${ur};
}
:host(.checked:not(.indeterminate)) slot[name='checked-indicator'],
:host(.indeterminate) slot[name='indeterminate-indicator'] {
opacity: 1;
}
:host(.disabled) {
opacity: ${qn.VFZ};
}
`.withBehaviors(Gn(dn`
.control {
border-color: ${Wn.FieldText};
background: ${Wn.Field};
}
:host(:not(.disabled):hover) .control,
:host(:not(.disabled):active) .control {
border-color: ${Wn.Highlight};
background: ${Wn.Field};
}
slot[name='checked-indicator'],
slot[name='indeterminate-indicator'] {
fill: ${Wn.FieldText};
}
:host(:${No}) .control {
forced-color-adjust: none;
outline-color: ${Wn.FieldText};
background: ${Wn.Field};
border-color: ${Wn.Highlight};
}
:host(.checked) .control {
background: ${Wn.Highlight};
border-color: ${Wn.Highlight};
}
:host(.checked:not(.disabled):hover) .control,
:host(.checked:not(.disabled):active) .control {
background: ${Wn.HighlightText};
border-color: ${Wn.Highlight};
}
:host(.checked) slot[name='checked-indicator'],
:host(.checked) slot[name='indeterminate-indicator'] {
fill: ${Wn.HighlightText};
}
:host(.checked:hover ) .control slot[name='checked-indicator'],
:host(.checked:hover ) .control slot[name='indeterminate-indicator'] {
fill: ${Wn.Highlight};
}
:host(.disabled) {
opacity: 1;
}
:host(.disabled) .control {
border-color: ${Wn.GrayText};
background: ${Wn.Field};
}
:host(.disabled) slot[name='checked-indicator'],
:host(.checked.disabled:hover) .control slot[name='checked-indicator'],
:host(.disabled) slot[name='indeterminate-indicator'],
:host(.checked.disabled:hover) .control slot[name='indeterminate-indicator'] {
fill: ${Wn.GrayText};
}
`)),checkedIndicator:'\n <svg width="16" height="16" xmlns="http://www.w3.org/2000/svg">\n <path d="M13.86 3.66a.5.5 0 01-.02.7l-7.93 7.48a.6.6 0 01-.84-.02L2.4 9.1a.5.5 0 01.72-.7l2.4 2.44 7.65-7.2a.5.5 0 01.7.02z"/>\n </svg>\n ',indeterminateIndicator:'\n <svg width="16" height="16" xmlns="http://www.w3.org/2000/svg">\n <path d="M3 8c0-.28.22-.5.5-.5h9a.5.5 0 010 1h-9A.5.5 0 013 8z"/>\n </svg>\n '});function Na(e){return Do(e)&&("option"===e.getAttribute("role")||e instanceof HTMLOptionElement)}class Ra extends zi{constructor(e,t,i,n){super(),this.defaultSelected=!1,this.dirtySelected=!1,this.selected=this.defaultSelected,this.dirtyValue=!1,e&&(this.textContent=e),t&&(this.initialValue=t),i&&(this.defaultSelected=i),n&&(this.selected=n),this.proxy=new Option(`${this.textContent}`,this.initialValue,this.defaultSelected,this.selected),this.proxy.disabled=this.disabled}checkedChanged(e,t){this.ariaChecked="boolean"!=typeof t?null:t?"true":"false"}contentChanged(e,t){this.proxy instanceof HTMLOptionElement&&(this.proxy.textContent=this.textContent),this.$emit("contentchange",null,{bubbles:!0})}defaultSelectedChanged(){this.dirtySelected||(this.selected=this.defaultSelected,this.proxy instanceof HTMLOptionElement&&(this.proxy.selected=this.defaultSelected))}disabledChanged(e,t){this.ariaDisabled=this.disabled?"true":"false",this.proxy instanceof HTMLOptionElement&&(this.proxy.disabled=this.disabled)}selectedAttributeChanged(){this.defaultSelected=this.selectedAttribute,this.proxy instanceof HTMLOptionElement&&(this.proxy.defaultSelected=this.defaultSelected)}selectedChanged(){this.ariaSelected=this.selected?"true":"false",this.dirtySelected||(this.dirtySelected=!0),this.proxy instanceof HTMLOptionElement&&(this.proxy.selected=this.selected)}initialValueChanged(e,t){this.dirtyValue||(this.value=this.initialValue,this.dirtyValue=!1)}get label(){var e;return null!==(e=this.value)&&void 0!==e?e:this.text}get text(){var e,t;return null!==(t=null===(e=this.textContent)||void 0===e?void 0:e.replace(/\s+/g," ").trim())&&void 0!==t?t:""}set value(e){const t=`${null!=e?e:""}`;this._value=t,this.dirtyValue=!0,this.proxy instanceof HTMLOptionElement&&(this.proxy.value=t),oi.y$.notify(this,"value")}get value(){var e;return oi.y$.track(this,"value"),null!==(e=this._value)&&void 0!==e?e:this.text}get form(){return this.proxy?this.proxy.form:null}}(0,ii.gn)([oi.LO],Ra.prototype,"checked",void 0),(0,ii.gn)([oi.LO],Ra.prototype,"content",void 0),(0,ii.gn)([oi.LO],Ra.prototype,"defaultSelected",void 0),(0,ii.gn)([(0,pn.Lj)({mode:"boolean"})],Ra.prototype,"disabled",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"selected",mode:"boolean"})],Ra.prototype,"selectedAttribute",void 0),(0,ii.gn)([oi.LO],Ra.prototype,"selected",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"value",mode:"fromView"})],Ra.prototype,"initialValue",void 0);class Ma{}(0,ii.gn)([oi.LO],Ma.prototype,"ariaChecked",void 0),(0,ii.gn)([oi.LO],Ma.prototype,"ariaPosInSet",void 0),(0,ii.gn)([oi.LO],Ma.prototype,"ariaSelected",void 0),(0,ii.gn)([oi.LO],Ma.prototype,"ariaSetSize",void 0),So(Ma,$o),So(Ra,yo,Ma);class La extends zi{constructor(){super(...arguments),this._options=[],this.selectedIndex=-1,this.selectedOptions=[],this.shouldSkipFocus=!1,this.typeaheadBuffer="",this.typeaheadExpired=!0,this.typeaheadTimeout=-1}get firstSelectedOption(){var e;return null!==(e=this.selectedOptions[0])&&void 0!==e?e:null}get hasSelectableOptions(){return this.options.length>0&&!this.options.every((e=>e.disabled))}get length(){var e,t;return null!==(t=null===(e=this.options)||void 0===e?void 0:e.length)&&void 0!==t?t:0}get options(){return oi.y$.track(this,"options"),this._options}set options(e){this._options=e,oi.y$.notify(this,"options")}get typeAheadExpired(){return this.typeaheadExpired}set typeAheadExpired(e){this.typeaheadExpired=e}clickHandler(e){const t=e.target.closest("option,[role=option]");if(t&&!t.disabled)return this.selectedIndex=this.options.indexOf(t),!0}focusAndScrollOptionIntoView(e=this.firstSelectedOption){this.contains(document.activeElement)&&null!==e&&(e.focus(),requestAnimationFrame((()=>{e.scrollIntoView({block:"nearest"})})))}focusinHandler(e){this.shouldSkipFocus||e.target!==e.currentTarget||(this.setSelectedOptions(),this.focusAndScrollOptionIntoView()),this.shouldSkipFocus=!1}getTypeaheadMatches(){const e=this.typeaheadBuffer.replace(/[.*+\-?^${}()|[\]\\]/g,"\\$&"),t=new RegExp(`^${e}`,"gi");return this.options.filter((e=>e.text.trim().match(t)))}getSelectableIndex(e=this.selectedIndex,t){const i=e>t?-1:e<t?1:0,n=e+i;let o=null;switch(i){case-1:o=this.options.reduceRight(((e,t,i)=>!e&&!t.disabled&&i<n?t:e),o);break;case 1:o=this.options.reduce(((e,t,i)=>!e&&!t.disabled&&i>n?t:e),o)}return this.options.indexOf(o)}handleChange(e,t){"selected"===t&&(La.slottedOptionFilter(e)&&(this.selectedIndex=this.options.indexOf(e)),this.setSelectedOptions())}handleTypeAhead(e){this.typeaheadTimeout&&window.clearTimeout(this.typeaheadTimeout),this.typeaheadTimeout=window.setTimeout((()=>this.typeaheadExpired=!0),La.TYPE_AHEAD_TIMEOUT_MS),e.length>1||(this.typeaheadBuffer=`${this.typeaheadExpired?"":this.typeaheadBuffer}${e}`)}keydownHandler(e){if(this.disabled)return!0;this.shouldSkipFocus=!1;const t=e.key;switch(t){case lo:e.shiftKey||(e.preventDefault(),this.selectFirstOption());break;case io:e.shiftKey||(e.preventDefault(),this.selectNextOption());break;case ro:e.shiftKey||(e.preventDefault(),this.selectPreviousOption());break;case co:e.preventDefault(),this.selectLastOption();break;case ho:return this.focusAndScrollOptionIntoView(),!0;case ao:case so:return!0;case uo:if(this.typeaheadExpired)return!0;default:return 1===t.length&&this.handleTypeAhead(`${t}`),!0}}mousedownHandler(e){return this.shouldSkipFocus=!this.contains(document.activeElement),!0}multipleChanged(e,t){this.ariaMultiSelectable=t?"true":null}selectedIndexChanged(e,t){var i;if(this.hasSelectableOptions){if((null===(i=this.options[this.selectedIndex])||void 0===i?void 0:i.disabled)&&"number"==typeof e){const i=this.getSelectableIndex(e,t),n=i>-1?i:e;return this.selectedIndex=n,void(t===n&&this.selectedIndexChanged(t,n))}this.setSelectedOptions()}else this.selectedIndex=-1}selectedOptionsChanged(e,t){var i;const n=t.filter(La.slottedOptionFilter);null===(i=this.options)||void 0===i||i.forEach((e=>{const t=oi.y$.getNotifier(e);t.unsubscribe(this,"selected"),e.selected=n.includes(e),t.subscribe(this,"selected")}))}selectFirstOption(){var e,t;this.disabled||(this.selectedIndex=null!==(t=null===(e=this.options)||void 0===e?void 0:e.findIndex((e=>!e.disabled)))&&void 0!==t?t:-1)}selectLastOption(){this.disabled||(this.selectedIndex=function(e,t){let i=e.length;for(;i--;)if(!e[i].disabled)return i;return-1}(this.options))}selectNextOption(){!this.disabled&&this.selectedIndex<this.options.length-1&&(this.selectedIndex+=1)}selectPreviousOption(){!this.disabled&&this.selectedIndex>0&&(this.selectedIndex=this.selectedIndex-1)}setDefaultSelectedOption(){var e,t;this.selectedIndex=null!==(t=null===(e=this.options)||void 0===e?void 0:e.findIndex((e=>e.defaultSelected)))&&void 0!==t?t:-1}setSelectedOptions(){var e,t,i;(null===(e=this.options)||void 0===e?void 0:e.length)&&(this.selectedOptions=[this.options[this.selectedIndex]],this.ariaActiveDescendant=null!==(i=null===(t=this.firstSelectedOption)||void 0===t?void 0:t.id)&&void 0!==i?i:"",this.focusAndScrollOptionIntoView())}slottedOptionsChanged(e,t){this.options=t.reduce(((e,t)=>(Na(t)&&e.push(t),e)),[]);const i=`${this.options.length}`;this.options.forEach(((e,t)=>{e.id||(e.id=oa("option-")),e.ariaPosInSet=`${t+1}`,e.ariaSetSize=i})),this.$fastController.isConnected&&(this.setSelectedOptions(),this.setDefaultSelectedOption())}typeaheadBufferChanged(e,t){if(this.$fastController.isConnected){const e=this.getTypeaheadMatches();if(e.length){const t=this.options.indexOf(e[0]);t>-1&&(this.selectedIndex=t)}this.typeaheadExpired=!1}}}La.slottedOptionFilter=e=>Na(e)&&!e.hidden,La.TYPE_AHEAD_TIMEOUT_MS=1e3,(0,ii.gn)([(0,pn.Lj)({mode:"boolean"})],La.prototype,"disabled",void 0),(0,ii.gn)([oi.LO],La.prototype,"selectedIndex",void 0),(0,ii.gn)([oi.LO],La.prototype,"selectedOptions",void 0),(0,ii.gn)([oi.LO],La.prototype,"slottedOptions",void 0),(0,ii.gn)([oi.LO],La.prototype,"typeaheadBuffer",void 0);class Ba{}(0,ii.gn)([oi.LO],Ba.prototype,"ariaActiveDescendant",void 0),(0,ii.gn)([oi.LO],Ba.prototype,"ariaDisabled",void 0),(0,ii.gn)([oi.LO],Ba.prototype,"ariaExpanded",void 0),(0,ii.gn)([oi.LO],Ba.prototype,"ariaMultiSelectable",void 0),So(Ba,$o),So(La,Ba);class Fa extends La{constructor(){super(...arguments),this.activeIndex=-1,this.rangeStartIndex=-1}get activeOption(){return this.options[this.activeIndex]}get checkedOptions(){var e;return null===(e=this.options)||void 0===e?void 0:e.filter((e=>e.checked))}get firstSelectedOptionIndex(){return this.options.indexOf(this.firstSelectedOption)}activeIndexChanged(e,t){var i,n;this.ariaActiveDescendant=null!==(n=null===(i=this.options[t])||void 0===i?void 0:i.id)&&void 0!==n?n:"",this.focusAndScrollOptionIntoView()}checkActiveIndex(){if(!this.multiple)return;const e=this.activeOption;e&&(e.checked=!0)}checkFirstOption(e=!1){e?(-1===this.rangeStartIndex&&(this.rangeStartIndex=this.activeIndex+1),this.options.forEach(((e,t)=>{e.checked=fo(t,this.rangeStartIndex)}))):this.uncheckAllOptions(),this.activeIndex=0,this.checkActiveIndex()}checkLastOption(e=!1){e?(-1===this.rangeStartIndex&&(this.rangeStartIndex=this.activeIndex),this.options.forEach(((e,t)=>{e.checked=fo(t,this.rangeStartIndex,this.options.length)}))):this.uncheckAllOptions(),this.activeIndex=this.options.length-1,this.checkActiveIndex()}connectedCallback(){super.connectedCallback(),this.addEventListener("focusout",this.focusoutHandler)}disconnectedCallback(){this.removeEventListener("focusout",this.focusoutHandler),super.disconnectedCallback()}checkNextOption(e=!1){e?(-1===this.rangeStartIndex&&(this.rangeStartIndex=this.activeIndex),this.options.forEach(((e,t)=>{e.checked=fo(t,this.rangeStartIndex,this.activeIndex+1)}))):this.uncheckAllOptions(),this.activeIndex+=this.activeIndex<this.options.length-1?1:0,this.checkActiveIndex()}checkPreviousOption(e=!1){e?(-1===this.rangeStartIndex&&(this.rangeStartIndex=this.activeIndex),1===this.checkedOptions.length&&(this.rangeStartIndex+=1),this.options.forEach(((e,t)=>{e.checked=fo(t,this.activeIndex,this.rangeStartIndex)}))):this.uncheckAllOptions(),this.activeIndex-=this.activeIndex>0?1:0,this.checkActiveIndex()}clickHandler(e){var t;if(!this.multiple)return super.clickHandler(e);const i=null===(t=e.target)||void 0===t?void 0:t.closest("[role=option]");return i&&!i.disabled?(this.uncheckAllOptions(),this.activeIndex=this.options.indexOf(i),this.checkActiveIndex(),this.toggleSelectedForAllCheckedOptions(),!0):void 0}focusAndScrollOptionIntoView(){super.focusAndScrollOptionIntoView(this.activeOption)}focusinHandler(e){if(!this.multiple)return super.focusinHandler(e);this.shouldSkipFocus||e.target!==e.currentTarget||(this.uncheckAllOptions(),-1===this.activeIndex&&(this.activeIndex=-1!==this.firstSelectedOptionIndex?this.firstSelectedOptionIndex:0),this.checkActiveIndex(),this.setSelectedOptions(),this.focusAndScrollOptionIntoView()),this.shouldSkipFocus=!1}focusoutHandler(e){this.multiple&&this.uncheckAllOptions()}keydownHandler(e){if(!this.multiple)return super.keydownHandler(e);if(this.disabled)return!0;const{key:t,shiftKey:i}=e;switch(this.shouldSkipFocus=!1,t){case lo:return void this.checkFirstOption(i);case io:return void this.checkNextOption(i);case ro:return void this.checkPreviousOption(i);case co:return void this.checkLastOption(i);case ho:return this.focusAndScrollOptionIntoView(),!0;case so:return this.uncheckAllOptions(),this.checkActiveIndex(),!0;case uo:if(e.preventDefault(),this.typeAheadExpired)return void this.toggleSelectedForAllCheckedOptions();default:return 1===t.length&&this.handleTypeAhead(`${t}`),!0}}mousedownHandler(e){if(e.offsetX>=0&&e.offsetX<=this.scrollWidth)return super.mousedownHandler(e)}multipleChanged(e,t){var i;this.ariaMultiSelectable=t?"true":null,null===(i=this.options)||void 0===i||i.forEach((e=>{e.checked=!t&&void 0})),this.setSelectedOptions()}setSelectedOptions(){this.multiple?this.$fastController.isConnected&&this.options&&(this.selectedOptions=this.options.filter((e=>e.selected)),this.focusAndScrollOptionIntoView()):super.setSelectedOptions()}sizeChanged(e,t){var i;const n=Math.max(0,parseInt(null!==(i=null==t?void 0:t.toFixed())&&void 0!==i?i:"",10));n!==t&&gn.SO.queueUpdate((()=>{this.size=n}))}toggleSelectedForAllCheckedOptions(){const e=this.checkedOptions.filter((e=>!e.disabled)),t=!e.every((e=>e.selected));e.forEach((e=>e.selected=t)),this.selectedIndex=this.options.indexOf(e[e.length-1]),this.setSelectedOptions()}typeaheadBufferChanged(e,t){if(this.multiple){if(this.$fastController.isConnected){const e=this.getTypeaheadMatches(),t=this.options.indexOf(e[0]);t>-1&&(this.activeIndex=t,this.uncheckAllOptions(),this.checkActiveIndex()),this.typeAheadExpired=!1}}else super.typeaheadBufferChanged(e,t)}uncheckAllOptions(e=!1){this.options.forEach((e=>e.checked=!this.multiple&&void 0)),e||(this.rangeStartIndex=-1)}}(0,ii.gn)([oi.LO],Fa.prototype,"activeIndex",void 0),(0,ii.gn)([(0,pn.Lj)({mode:"boolean"})],Fa.prototype,"multiple",void 0),(0,ii.gn)([(0,pn.Lj)({converter:pn.Id})],Fa.prototype,"size",void 0);const Ua=class extends La{}.compose({baseName:"listbox",template:(e,t)=>$n`
<template
aria-activedescendant="${e=>e.ariaActiveDescendant}"
aria-multiselectable="${e=>e.ariaMultiSelectable}"
class="listbox"
role="listbox"
tabindex="${e=>e.disabled?null:"0"}"
@click="${(e,t)=>e.clickHandler(t.event)}"
@focusin="${(e,t)=>e.focusinHandler(t.event)}"
@keydown="${(e,t)=>e.keydownHandler(t.event)}"
@mousedown="${(e,t)=>e.mousedownHandler(t.event)}"
>
<slot
${Ao({filter:Fa.slottedOptionFilter,flatten:!0,property:"slottedOptions"})}
></slot>
</template>
`,styles:(e,t)=>dn`
${zn("inline-flex")} :host {
border: calc(${qn.Han} * 1px) solid ${qn.akT};
border-radius: calc(${qn.UWU} * 1px);
box-sizing: border-box;
flex-direction: column;
padding: calc(${qn._5n} * 1px) 0;
}
::slotted(${e.tagFor(Ra)}) {
margin: 0 calc(${qn._5n} * 1px);
}
:host(:focus-within:not([disabled])) {
${Ro}
}
`}),Ha=Ra.compose({baseName:"option",template:(e,t)=>$n`
<template
aria-checked="${e=>e.ariaChecked}"
aria-disabled="${e=>e.ariaDisabled}"
aria-posinset="${e=>e.ariaPosInSet}"
aria-selected="${e=>e.ariaSelected}"
aria-setsize="${e=>e.ariaSetSize}"
class="${e=>[e.checked&&"checked",e.selected&&"selected",e.disabled&&"disabled"].filter(Boolean).join(" ")}"
role="option"
>
${bo(0,t)}
<span class="content" part="content">
<slot ${Ao("content")}></slot>
</span>
${Co(0,t)}
</template>
`,styles:(e,t)=>dn`
${zn("inline-flex")} :host {
position: relative;
${Eo}
background: ${qn.jql};
border-radius: calc(${qn.UWU} * 1px);
border: calc(${qn.Han} * 1px) solid transparent;
box-sizing: border-box;
color: ${qn.CHi};
cursor: pointer;
fill: currentcolor;
height: calc(${Lo} * 1px);
overflow: hidden;
align-items: center;
padding: 0 calc(((${qn._5n} * 3) - ${qn.Han} - 1) * 1px);
user-select: none;
white-space: nowrap;
}
:host::before {
content: '';
display: block;
position: absolute;
left: calc((${qn.vxp} - ${qn.Han}) * 1px);
top: calc((${Lo} / 4) - ${qn.vxp} * 1px);
width: 3px;
height: calc((${Lo} / 2) * 1px);
background: transparent;
border-radius: calc(${qn.UWU} * 1px);
}
:host(:not([disabled]):hover) {
background: ${qn.QpD};
}
:host(:not([disabled]):active) {
background: ${qn.sG3};
}
:host(:not([disabled]):active)::before {
background: ${qn.Avx};
height: calc(((${Lo} / 2) - 6) * 1px);
}
:host([aria-selected='true'])::before {
background: ${qn.Avx};
}
:host(:${No}) {
${Ro}
background: ${qn.s0z};
}
:host([aria-selected='true']) {
background: ${qn._jX};
}
:host(:not([disabled])[aria-selected='true']:hover) {
background: ${qn.d$x};
}
:host(:not([disabled])[aria-selected='true']:active) {
background: ${qn._ii};
}
:host(:not([disabled]):not([aria-selected='true']):hover) {
background: ${qn.QpD};
}
:host(:not([disabled]):not([aria-selected='true']):active) {
background: ${qn.sG3};
}
:host([disabled]) {
cursor: ${ur};
opacity: ${qn.VFZ};
}
.content {
grid-column-start: 2;
justify-self: start;
overflow: hidden;
text-overflow: ellipsis;
}
.start,
.end,
::slotted(svg) {
display: flex;
}
::slotted([slot='end']) {
margin-inline-start: 1ch;
}
::slotted([slot='start']) {
margin-inline-end: 1ch;
}
`.withBehaviors(new Xr(null,dn`
:host::before {
right: calc((${qn.vxp} - ${qn.Han}) * 1px);
}
`),Gn(dn`
:host {
background: ${Wn.ButtonFace};
border-color: ${Wn.ButtonFace};
color: ${Wn.ButtonText};
}
:host(:not([disabled]):not([aria-selected="true"]):hover),
:host(:not([disabled])[aria-selected="true"]:hover),
:host([aria-selected="true"]) {
forced-color-adjust: none;
background: ${Wn.Highlight};
color: ${Wn.HighlightText};
}
:host(:not([disabled]):active)::before,
:host([aria-selected='true'])::before {
background: ${Wn.HighlightText};
}
:host([disabled]),
:host([disabled]:not([aria-selected='true']):hover) {
background: ${Wn.Canvas};
color: ${Wn.GrayText};
fill: currentcolor;
opacity: 1;
}
:host(:${No}) {
outline-color: ${Wn.CanvasText};
}
`))});class $a extends zi{}class Za extends(ar($a)){constructor(){super(...arguments),this.proxy=document.createElement("input")}}class Va extends Za{constructor(){super(),this.initialValue="on",this.keypressHandler=e=>{if(e.key!==uo)return!0;this.checked||this.readOnly||(this.checked=!0)},this.proxy.setAttribute("type","radio")}readOnlyChanged(){this.proxy instanceof HTMLInputElement&&(this.proxy.readOnly=this.readOnly)}defaultCheckedChanged(){var e;this.$fastController.isConnected&&!this.dirtyChecked&&(this.isInsideRadioGroup()||(this.checked=null!==(e=this.defaultChecked)&&void 0!==e&&e,this.dirtyChecked=!1))}connectedCallback(){var e,t;super.connectedCallback(),this.validate(),"radiogroup"!==(null===(e=this.parentElement)||void 0===e?void 0:e.getAttribute("role"))&&null===this.getAttribute("tabindex")&&(this.disabled||this.setAttribute("tabindex","0")),this.checkedAttribute&&(this.dirtyChecked||this.isInsideRadioGroup()||(this.checked=null!==(t=this.defaultChecked)&&void 0!==t&&t,this.dirtyChecked=!1))}isInsideRadioGroup(){return null!==this.closest("[role=radiogroup]")}clickHandler(e){this.disabled||this.readOnly||this.checked||(this.checked=!0)}}(0,ii.gn)([(0,pn.Lj)({attribute:"readonly",mode:"boolean"})],Va.prototype,"readOnly",void 0),(0,ii.gn)([oi.LO],Va.prototype,"name",void 0),(0,ii.gn)([oi.LO],Va.prototype,"defaultSlottedNodes",void 0);const Ga=Va.compose({baseName:"radio",template:(e,t)=>$n`
<template
role="radio"
class="${e=>e.checked?"checked":""} ${e=>e.readOnly?"readonly":""}"
aria-checked="${e=>e.checked}"
aria-required="${e=>e.required}"
aria-disabled="${e=>e.disabled}"
aria-readonly="${e=>e.readOnly}"
@keypress="${(e,t)=>e.keypressHandler(t.event)}"
@click="${(e,t)=>e.clickHandler(t.event)}"
>
<div part="control" class="control">
<slot name="checked-indicator">
${t.checkedIndicator||""}
</slot>
</div>
<label
part="label"
class="${e=>e.defaultSlottedNodes&&e.defaultSlottedNodes.length?"label":"label label__hidden"}"
>
<slot ${Ao("defaultSlottedNodes")}></slot>
</label>
</template>
`,styles:(e,t)=>dn`
${zn("inline-flex")} :host {
--input-size: calc((${Lo} / 2) + ${qn._5n});
align-items: center;
outline: none;
${""} user-select: none;
position: relative;
flex-direction: row;
transition: all 0.2s ease-in-out;
}
.control {
position: relative;
width: calc(var(--input-size) * 1px);
height: calc(var(--input-size) * 1px);
box-sizing: border-box;
border-radius: 50%;
border: calc(${qn.Han} * 1px) solid ${qn.rU8};
background: ${qn.pB6};
cursor: pointer;
}
.label__hidden {
display: none;
visibility: hidden;
}
.label {
${Eo}
color: ${qn.CHi};
${""} padding-inline-start: calc(${qn._5n} * 2px + 2px);
margin-inline-end: calc(${qn._5n} * 2px + 2px);
cursor: pointer;
}
.control,
slot[name='checked-indicator'] {
flex-shrink: 0;
}
slot[name='checked-indicator'] {
display: flex;
align-items: center;
justify-content: center;
width: 100%;
height: 100%;
fill: ${qn.w41};
opacity: 0;
pointer-events: none;
}
:host(:not(.disabled):hover) .control {
background: ${qn.vFq};
border-color: ${qn.gKw};
}
:host(:not(.disabled):active) .control {
background: ${qn.bWE};
border-color: ${qn.ekh};
}
:host(:not(.disabled):active) slot[name='checked-indicator'] {
opacity: 1;
}
:host(:${No}) .control {
${Mo}
background: ${qn.W3V};
}
:host(.checked) .control {
background: ${qn.Avx};
border-color: transparent;
}
:host(.checked:not(.disabled):hover) .control {
background: ${qn.OCG};
border-color: transparent;
}
:host(.checked:not(.disabled):active) .control {
background: ${qn.UEO};
border-color: transparent;
}
:host(.disabled) .label,
:host(.readonly) .label,
:host(.readonly) .control,
:host(.disabled) .control {
cursor: ${ur};
}
:host(.checked) slot[name='checked-indicator'] {
opacity: 1;
}
:host(.disabled) {
opacity: ${qn.VFZ};
}
`.withBehaviors(Gn(dn`
.control {
background: ${Wn.Field};
border-color: ${Wn.FieldText};
}
:host(:not(.disabled):hover) .control,
:host(:not(.disabled):active) .control {
border-color: ${Wn.Highlight};
}
:host(:${No}) .control {
forced-color-adjust: none;
background: ${Wn.Field};
outline-color: ${Wn.FieldText};
}
:host(.checked:not(.disabled):hover) .control,
:host(.checked:not(.disabled):active) .control {
border-color: ${Wn.Highlight};
background: ${Wn.Highlight};
}
:host(.checked) slot[name='checked-indicator'] {
fill: ${Wn.Highlight};
}
:host(.checked:hover) .control slot[name='checked-indicator'] {
fill: ${Wn.HighlightText};
}
:host(.disabled) {
opacity: 1;
}
:host(.disabled) .label {
color: ${Wn.GrayText};
}
:host(.disabled) .control,
:host(.checked.disabled) .control {
background: ${Wn.Field};
border-color: ${Wn.GrayText};
}
:host(.disabled) slot[name='checked-indicator'],
:host(.checked.disabled) slot[name='checked-indicator'] {
fill: ${Wn.GrayText};
}
`)),checkedIndicator:'\n <svg width="16" height="16" xmlns="http://www.w3.org/2000/svg">\n <circle cx="8" cy="8" r="4"/>\n </svg>\n '});class ja extends zi{constructor(){super(...arguments),this.orientation=$r,this.radioChangeHandler=e=>{const t=e.target;t.checked&&(this.slottedRadioButtons.forEach((e=>{e!==t&&(e.checked=!1,this.isInsideFoundationToolbar||e.setAttribute("tabindex","-1"))})),this.selectedRadio=t,this.value=t.value,t.setAttribute("tabindex","0"),this.focusedRadio=t),e.stopPropagation()},this.moveToRadioByIndex=(e,t)=>{const i=e[t];this.isInsideToolbar||(i.setAttribute("tabindex","0"),i.readOnly?this.slottedRadioButtons.forEach((e=>{e!==i&&e.setAttribute("tabindex","-1")})):(i.checked=!0,this.selectedRadio=i)),this.focusedRadio=i,i.focus()},this.moveRightOffGroup=()=>{var e;null===(e=this.nextElementSibling)||void 0===e||e.focus()},this.moveLeftOffGroup=()=>{var e;null===(e=this.previousElementSibling)||void 0===e||e.focus()},this.focusOutHandler=e=>{const t=this.slottedRadioButtons,i=e.target,n=null!==i?t.indexOf(i):0,o=this.focusedRadio?t.indexOf(this.focusedRadio):-1;return(0===o&&n===o||o===t.length-1&&o===n)&&(this.selectedRadio?(this.focusedRadio=this.selectedRadio,this.isInsideFoundationToolbar||(this.selectedRadio.setAttribute("tabindex","0"),t.forEach((e=>{e!==this.selectedRadio&&e.setAttribute("tabindex","-1")})))):(this.focusedRadio=t[0],this.focusedRadio.setAttribute("tabindex","0"),t.forEach((e=>{e!==this.focusedRadio&&e.setAttribute("tabindex","-1")})))),!0},this.clickHandler=e=>{const t=e.target;if(t){const e=this.slottedRadioButtons;t.checked||0===e.indexOf(t)?(t.setAttribute("tabindex","0"),this.selectedRadio=t):(t.setAttribute("tabindex","-1"),this.selectedRadio=null),this.focusedRadio=t}e.preventDefault()},this.shouldMoveOffGroupToTheRight=(e,t,i)=>e===t.length&&this.isInsideToolbar&&i===oo,this.shouldMoveOffGroupToTheLeft=(e,t)=>(this.focusedRadio?e.indexOf(this.focusedRadio)-1:0)<0&&this.isInsideToolbar&&t===no,this.checkFocusedRadio=()=>{null===this.focusedRadio||this.focusedRadio.readOnly||this.focusedRadio.checked||(this.focusedRadio.checked=!0,this.focusedRadio.setAttribute("tabindex","0"),this.focusedRadio.focus(),this.selectedRadio=this.focusedRadio)},this.moveRight=e=>{const t=this.slottedRadioButtons;let i=0;if(i=this.focusedRadio?t.indexOf(this.focusedRadio)+1:1,this.shouldMoveOffGroupToTheRight(i,t,e.key))this.moveRightOffGroup();else for(i===t.length&&(i=0);i<t.length&&t.length>1;){if(!t[i].disabled){this.moveToRadioByIndex(t,i);break}if(this.focusedRadio&&i===t.indexOf(this.focusedRadio))break;if(i+1>=t.length){if(this.isInsideToolbar)break;i=0}else i+=1}},this.moveLeft=e=>{const t=this.slottedRadioButtons;let i=0;if(i=this.focusedRadio?t.indexOf(this.focusedRadio)-1:0,i=i<0?t.length-1:i,this.shouldMoveOffGroupToTheLeft(t,e.key))this.moveLeftOffGroup();else for(;i>=0&&t.length>1;){if(!t[i].disabled){this.moveToRadioByIndex(t,i);break}if(this.focusedRadio&&i===t.indexOf(this.focusedRadio))break;i-1<0?i=t.length-1:i-=1}},this.keydownHandler=e=>{const t=e.key;if(t in po&&this.isInsideFoundationToolbar)return!0;switch(t){case ao:this.checkFocusedRadio();break;case oo:case io:this.direction===Br.ltr?this.moveRight(e):this.moveLeft(e);break;case no:case ro:this.direction===Br.ltr?this.moveLeft(e):this.moveRight(e);break;default:return!0}}}readOnlyChanged(){void 0!==this.slottedRadioButtons&&this.slottedRadioButtons.forEach((e=>{this.readOnly?e.readOnly=!0:e.readOnly=!1}))}disabledChanged(){void 0!==this.slottedRadioButtons&&this.slottedRadioButtons.forEach((e=>{this.disabled?e.disabled=!0:e.disabled=!1}))}nameChanged(){this.slottedRadioButtons&&this.slottedRadioButtons.forEach((e=>{e.setAttribute("name",this.name)}))}valueChanged(){this.slottedRadioButtons&&this.slottedRadioButtons.forEach((e=>{e.value===this.value&&(e.checked=!0,this.selectedRadio=e)})),this.$emit("change")}slottedRadioButtonsChanged(e,t){this.slottedRadioButtons&&this.slottedRadioButtons.length>0&&this.setupRadioButtons()}get parentToolbar(){return this.closest('[role="toolbar"]')}get isInsideToolbar(){var e;return null!==(e=this.parentToolbar)&&void 0!==e&&e}get isInsideFoundationToolbar(){var e;return!!(null===(e=this.parentToolbar)||void 0===e?void 0:e.$fastController)}connectedCallback(){super.connectedCallback(),this.direction=Fr(this),this.setupRadioButtons()}disconnectedCallback(){this.slottedRadioButtons.forEach((e=>{e.removeEventListener("change",this.radioChangeHandler)}))}setupRadioButtons(){const e=this.slottedRadioButtons.filter((e=>e.hasAttribute("checked"))),t=e?e.length:0;t>1&&(e[t-1].checked=!0);let i=!1;if(this.slottedRadioButtons.forEach((e=>{void 0!==this.name&&e.setAttribute("name",this.name),this.disabled&&(e.disabled=!0),this.readOnly&&(e.readOnly=!0),this.value&&this.value===e.value?(this.selectedRadio=e,this.focusedRadio=e,e.checked=!0,e.setAttribute("tabindex","0"),i=!0):(this.isInsideFoundationToolbar||e.setAttribute("tabindex","-1"),e.checked=!1),e.addEventListener("change",this.radioChangeHandler)})),void 0===this.value&&this.slottedRadioButtons.length>0){const e=this.slottedRadioButtons.filter((e=>e.hasAttribute("checked"))),t=null!==e?e.length:0;if(t>0&&!i){const i=e[t-1];i.checked=!0,this.focusedRadio=i,i.setAttribute("tabindex","0")}else this.slottedRadioButtons[0].setAttribute("tabindex","0"),this.focusedRadio=this.slottedRadioButtons[0]}}}(0,ii.gn)([(0,pn.Lj)({attribute:"readonly",mode:"boolean"})],ja.prototype,"readOnly",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"disabled",mode:"boolean"})],ja.prototype,"disabled",void 0),(0,ii.gn)([pn.Lj],ja.prototype,"name",void 0),(0,ii.gn)([pn.Lj],ja.prototype,"value",void 0),(0,ii.gn)([pn.Lj],ja.prototype,"orientation",void 0),(0,ii.gn)([oi.LO],ja.prototype,"childItems",void 0),(0,ii.gn)([oi.LO],ja.prototype,"slottedRadioButtons",void 0);const za=ja.compose({baseName:"radio-group",template:(e,t)=>$n`
<template
role="radiogroup"
aria-disabled="${e=>e.disabled}"
aria-readonly="${e=>e.readOnly}"
@click="${(e,t)=>e.clickHandler(t.event)}"
@keydown="${(e,t)=>e.keydownHandler(t.event)}"
@focusout="${(e,t)=>e.focusOutHandler(t.event)}"
>
<slot name="label"></slot>
<div
class="positioning-region ${e=>e.orientation===$r?"horizontal":"vertical"}"
part="positioning-region"
>
<slot
${Ao({property:"slottedRadioButtons",filter:wo("[role=radio]")})}
></slot>
</div>
</template>
`,styles:(e,t)=>dn`
${zn("flex")} :host {
align-items: flex-start;
flex-direction: column;
}
.positioning-region {
display: flex;
flex-wrap: wrap;
}
:host([orientation='vertical']) .positioning-region {
flex-direction: column;
}
:host([orientation='horizontal']) .positioning-region {
flex-direction: row;
}
`});class Wa extends zi{constructor(){super(...arguments),this.percentComplete=0}valueChanged(){this.$fastController.isConnected&&this.updatePercentComplete()}minChanged(){this.$fastController.isConnected&&this.updatePercentComplete()}maxChanged(){this.$fastController.isConnected&&this.updatePercentComplete()}connectedCallback(){super.connectedCallback(),this.updatePercentComplete()}updatePercentComplete(){const e="number"==typeof this.min?this.min:0,t="number"==typeof this.max?this.max:100,i="number"==typeof this.value?this.value:0,n=t-e;this.percentComplete=0===n?0:Math.fround((i-e)/n*100)}}(0,ii.gn)([(0,pn.Lj)({converter:pn.Id})],Wa.prototype,"value",void 0),(0,ii.gn)([(0,pn.Lj)({converter:pn.Id})],Wa.prototype,"min",void 0),(0,ii.gn)([(0,pn.Lj)({converter:pn.Id})],Wa.prototype,"max",void 0),(0,ii.gn)([(0,pn.Lj)({mode:"boolean"})],Wa.prototype,"paused",void 0),(0,ii.gn)([oi.LO],Wa.prototype,"percentComplete",void 0);class Ka extends Wa{}const qa=Ka.compose({baseName:"progress",template:(e,t)=>$n`
<template
role="progressbar"
aria-valuenow="${e=>e.value}"
aria-valuemin="${e=>e.min}"
aria-valuemax="${e=>e.max}"
class="${e=>e.paused?"paused":""}"
>
${Wr((e=>"number"==typeof e.value),$n`
<div class="progress" part="progress" slot="determinate">
<div
class="determinate"
part="determinate"
style="width: ${e=>e.percentComplete}%"
></div>
</div>
`,$n`
<div class="progress" part="progress" slot="indeterminate">
<slot class="indeterminate" name="indeterminate">
${t.indeterminateIndicator1||""}
${t.indeterminateIndicator2||""}
</slot>
</div>
`)}
</template>
`,styles:(e,t)=>dn`
${zn("flex")} :host {
align-items: center;
height: calc((${qn.Han} * 3) * 1px);
}
.progress {
background-color: ${qn.rU8};
border-radius: calc(${qn._5n} * 1px);
width: 100%;
height: calc(${qn.Han} * 1px);
display: flex;
align-items: center;
position: relative;
}
.determinate {
background-color: ${qn.Avx};
border-radius: calc(${qn._5n} * 1px);
height: calc((${qn.Han} * 3) * 1px);
transition: all 0.2s ease-in-out;
display: flex;
}
.indeterminate {
height: calc((${qn.Han} * 3) * 1px);
border-radius: calc(${qn._5n} * 1px);
display: flex;
width: 100%;
position: relative;
overflow: hidden;
}
.indeterminate-indicator-1 {
position: absolute;
opacity: 0;
height: 100%;
background-color: ${qn.Avx};
border-radius: calc(${qn._5n} * 1px);
animation-timing-function: cubic-bezier(0.4, 0, 0.6, 1);
width: 40%;
animation: indeterminate-1 2s infinite;
}
.indeterminate-indicator-2 {
position: absolute;
opacity: 0;
height: 100%;
background-color: ${qn.Avx};
border-radius: calc(${qn._5n} * 1px);
animation-timing-function: cubic-bezier(0.4, 0, 0.6, 1);
width: 60%;
animation: indeterminate-2 2s infinite;
}
:host(.paused) .indeterminate-indicator-1,
:host(.paused) .indeterminate-indicator-2 {
animation: none;
background-color: ${qn.Q5n};
width: 100%;
opacity: 1;
}
:host(.paused) .determinate {
background-color: ${qn.Q5n};
}
@keyframes indeterminate-1 {
0% {
opacity: 1;
transform: translateX(-100%);
}
70% {
opacity: 1;
transform: translateX(300%);
}
70.01% {
opacity: 0;
}
100% {
opacity: 0;
transform: translateX(300%);
}
}
@keyframes indeterminate-2 {
0% {
opacity: 0;
transform: translateX(-150%);
}
29.99% {
opacity: 0;
}
30% {
opacity: 1;
transform: translateX(-150%);
}
100% {
transform: translateX(166.66%);
opacity: 1;
}
}
`.withBehaviors(Gn(dn`
.indeterminate-indicator-1,
.indeterminate-indicator-2,
.determinate,
.progress {
background-color: ${Wn.ButtonText};
}
:host(.paused) .indeterminate-indicator-1,
:host(.paused) .indeterminate-indicator-2,
:host(.paused) .determinate {
background-color: ${Wn.GrayText};
}
`)),indeterminateIndicator1:'\n <span class="indeterminate-indicator-1" part="indeterminate-indicator-1"></span>\n ',indeterminateIndicator2:'\n <span class="indeterminate-indicator-2" part="indeterminate-indicator-2"></span>\n '}),Ya=class extends Wa{}.compose({baseName:"progress-ring",template:(e,t)=>$n`
<template
role="progressbar"
aria-valuenow="${e=>e.value}"
aria-valuemin="${e=>e.min}"
aria-valuemax="${e=>e.max}"
class="${e=>e.paused?"paused":""}"
>
${Wr((e=>"number"==typeof e.value),$n`
<svg
class="progress"
part="progress"
viewBox="0 0 16 16"
slot="determinate"
>
<circle
class="background"
part="background"
cx="8px"
cy="8px"
r="7px"
></circle>
<circle
class="determinate"
part="determinate"
style="stroke-dasharray: ${e=>44*e.percentComplete/100}px ${44}px"
cx="8px"
cy="8px"
r="7px"
></circle>
</svg>
`,$n`
<slot name="indeterminate" slot="indeterminate">
${t.indeterminateIndicator||""}
</slot>
`)}
</template>
`,styles:(e,t)=>dn`
${zn("flex")} :host {
align-items: center;
height: calc(${Lo} * 1px);
width: calc(${Lo} * 1px);
}
.progress {
height: 100%;
width: 100%;
}
.background {
fill: none;
stroke-width: 2px;
}
.determinate {
stroke: ${qn.Avx};
fill: none;
stroke-width: 2px;
stroke-linecap: round;
transform-origin: 50% 50%;
transform: rotate(-90deg);
transition: all 0.2s ease-in-out;
}
.indeterminate-indicator-1 {
stroke: ${qn.Avx};
fill: none;
stroke-width: 2px;
stroke-linecap: round;
transform-origin: 50% 50%;
transform: rotate(-90deg);
transition: all 0.2s ease-in-out;
animation: spin-infinite 2s linear infinite;
}
:host(.paused) .indeterminate-indicator-1 {
animation: none;
stroke: ${qn.Q5n};
}
:host(.paused) .determinate {
stroke: ${qn.Q5n};
}
@keyframes spin-infinite {
0% {
stroke-dasharray: 0.01px 43.97px;
transform: rotate(0deg);
}
50% {
stroke-dasharray: 21.99px 21.99px;
transform: rotate(450deg);
}
100% {
stroke-dasharray: 0.01px 43.97px;
transform: rotate(1080deg);
}
}
`.withBehaviors(Gn(dn`
.background {
stroke: ${Wn.Field};
}
.determinate,
.indeterminate-indicator-1 {
stroke: ${Wn.ButtonText};
}
:host(.paused) .determinate,
:host(.paused) .indeterminate-indicator-1 {
stroke: ${Wn.GrayText};
}
`)),indeterminateIndicator:'\n <svg class="progress" part="progress" viewBox="0 0 16 16">\n <circle\n class="background"\n part="background"\n cx="8px"\n cy="8px"\n r="7px"\n ></circle>\n <circle\n class="indeterminate-indicator-1"\n part="indeterminate-indicator-1"\n cx="8px"\n cy="8px"\n r="7px"\n ></circle>\n </svg>\n '}),Xa=Zr.compose({baseName:"divider",template:(e,t)=>$n`
<template role="${e=>e.role}" aria-orientation="${e=>e.orientation}"></template>
`,styles:(e,t)=>dn`
${zn("block")} :host {
box-sizing: content-box;
height: 0;
border: none;
border-top: calc(${qn.Han} * 1px) solid ${qn.dtw};
}
:host([orientation="vertical"]) {
border: none;
height: 100%;
margin: 0 calc(${qn._5n} * 1px);
border-left: calc(${qn.Han} * 1px) solid ${qn.dtw};
}
`});var Ja=["input","select","textarea","a[href]","button","[tabindex]:not(slot)","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])',"details>summary:first-of-type","details"].join(","),Qa="undefined"==typeof Element,es=Qa?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,ts=!Qa&&Element.prototype.getRootNode?function(e){return e.getRootNode()}:function(e){return e.ownerDocument},is=function(e){return"INPUT"===e.tagName},ns=function(e){var t=e.getBoundingClientRect(),i=t.width,n=t.height;return 0===i&&0===n},os=function(e,t){return!(function(e){return function(e){return is(e)&&"radio"===e.type}(e)&&!function(e){if(!e.name)return!0;var t,i=e.form||ts(e),n=function(e){return i.querySelectorAll('input[type="radio"][name="'+e+'"]')};if("undefined"!=typeof window&&void 0!==window.CSS&&"function"==typeof window.CSS.escape)t=n(window.CSS.escape(e.name));else try{t=n(e.name)}catch(e){return!1}var o=function(e,t){for(var i=0;i<e.length;i++)if(e[i].checked&&e[i].form===t)return e[i]}(t,e.form);return!o||o===e}(e)}(t)||function(e,t){return e.tabIndex<0&&(t||/^(AUDIO|VIDEO|DETAILS)$/.test(e.tagName)||e.isContentEditable)&&isNaN(parseInt(e.getAttribute("tabindex"),10))?0:e.tabIndex}(t)<0||!function(e,t){return!(t.disabled||function(e){return is(e)&&"hidden"===e.type}(t)||function(e,t){var i=t.displayCheck,n=t.getShadowRoot;if("hidden"===getComputedStyle(e).visibility)return!0;var o=es.call(e,"details>summary:first-of-type")?e.parentElement:e;if(es.call(o,"details:not([open]) *"))return!0;var r=ts(e).host,a=(null==r?void 0:r.ownerDocument.contains(r))||e.ownerDocument.contains(e);if(i&&"full"!==i){if("non-zero-area"===i)return ns(e)}else{if("function"==typeof n){for(var s=e;e;){var l=e.parentElement,c=ts(e);if(l&&!l.shadowRoot&&!0===n(l))return ns(e);e=e.assignedSlot?e.assignedSlot:l||c===e.ownerDocument?l:c.host}e=s}if(a)return!e.getClientRects().length}return!1}(t,e)||function(e){return"DETAILS"===e.tagName&&Array.prototype.slice.apply(e.children).some((function(e){return"SUMMARY"===e.tagName}))}(t)||function(e){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(e.tagName))for(var t=e.parentElement;t;){if("FIELDSET"===t.tagName&&t.disabled){for(var i=0;i<t.children.length;i++){var n=t.children.item(i);if("LEGEND"===n.tagName)return!!es.call(t,"fieldset[disabled] *")||!n.contains(e)}return!0}t=t.parentElement}return!1}(t))}(e,t))},rs=function(e,t){if(t=t||{},!e)throw new Error("No node provided");return!1!==es.call(e,Ja)&&os(t,e)};class as extends zi{constructor(){super(...arguments),this.modal=!0,this.hidden=!1,this.trapFocus=!0,this.trapFocusChanged=()=>{this.$fastController.isConnected&&this.updateTrapFocus()},this.isTrappingFocus=!1,this.handleDocumentKeydown=e=>{if(!e.defaultPrevented&&!this.hidden)switch(e.key){case so:this.dismiss(),e.preventDefault();break;case ho:this.handleTabKeyDown(e)}},this.handleDocumentFocus=e=>{!e.defaultPrevented&&this.shouldForceFocus(e.target)&&(this.focusFirstElement(),e.preventDefault())},this.handleTabKeyDown=e=>{if(!this.trapFocus||this.hidden)return;const t=this.getTabQueueBounds();return 0!==t.length?1===t.length?(t[0].focus(),void e.preventDefault()):void(e.shiftKey&&e.target===t[0]?(t[t.length-1].focus(),e.preventDefault()):e.shiftKey||e.target!==t[t.length-1]||(t[0].focus(),e.preventDefault())):void 0},this.getTabQueueBounds=()=>as.reduceTabbableItems([],this),this.focusFirstElement=()=>{const e=this.getTabQueueBounds();e.length>0?e[0].focus():this.dialog instanceof HTMLElement&&this.dialog.focus()},this.shouldForceFocus=e=>this.isTrappingFocus&&!this.contains(e),this.shouldTrapFocus=()=>this.trapFocus&&!this.hidden,this.updateTrapFocus=e=>{const t=void 0===e?this.shouldTrapFocus():e;t&&!this.isTrappingFocus?(this.isTrappingFocus=!0,document.addEventListener("focusin",this.handleDocumentFocus),gn.SO.queueUpdate((()=>{this.shouldForceFocus(document.activeElement)&&this.focusFirstElement()}))):!t&&this.isTrappingFocus&&(this.isTrappingFocus=!1,document.removeEventListener("focusin",this.handleDocumentFocus))}}dismiss(){this.$emit("dismiss"),this.$emit("cancel")}show(){this.hidden=!1}hide(){this.hidden=!0,this.$emit("close")}connectedCallback(){super.connectedCallback(),document.addEventListener("keydown",this.handleDocumentKeydown),this.notifier=oi.y$.getNotifier(this),this.notifier.subscribe(this,"hidden"),this.updateTrapFocus()}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("keydown",this.handleDocumentKeydown),this.updateTrapFocus(!1),this.notifier.unsubscribe(this,"hidden")}handleChange(e,t){"hidden"===t&&this.updateTrapFocus()}static reduceTabbableItems(e,t){return"-1"===t.getAttribute("tabindex")?e:rs(t)||as.isFocusableFastElement(t)&&as.hasTabbableShadow(t)?(e.push(t),e):t.childElementCount?e.concat(Array.from(t.children).reduce(as.reduceTabbableItems,[])):e}static isFocusableFastElement(e){var t,i;return!!(null===(i=null===(t=e.$fastController)||void 0===t?void 0:t.definition.shadowOptions)||void 0===i?void 0:i.delegatesFocus)}static hasTabbableShadow(e){var t,i;return Array.from(null!==(i=null===(t=e.shadowRoot)||void 0===t?void 0:t.querySelectorAll("*"))&&void 0!==i?i:[]).some((e=>rs(e)))}}(0,ii.gn)([(0,pn.Lj)({mode:"boolean"})],as.prototype,"modal",void 0),(0,ii.gn)([(0,pn.Lj)({mode:"boolean"})],as.prototype,"hidden",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"trap-focus",mode:"boolean"})],as.prototype,"trapFocus",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-describedby"})],as.prototype,"ariaDescribedby",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-labelledby"})],as.prototype,"ariaLabelledby",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"aria-label"})],as.prototype,"ariaLabel",void 0);const ss=as.compose({baseName:"dialog",template:(e,t)=>$n`
<div class="positioning-region" part="positioning-region">
${Wr((e=>e.modal),$n`
<div
class="overlay"
part="overlay"
role="presentation"
@click="${e=>e.dismiss()}"
></div>
`)}
<div
role="dialog"
tabindex="-1"
class="control"
part="control"
aria-modal="${e=>e.modal}"
aria-describedby="${e=>e.ariaDescribedby}"
aria-labelledby="${e=>e.ariaLabelledby}"
aria-label="${e=>e.ariaLabel}"
${vo("dialog")}
>
<slot></slot>
</div>
</div>
`,styles:(e,t)=>dn`
:host([hidden]) {
display: none;
}
:host {
--dialog-height: 480px;
--dialog-width: 640px;
display: block;
}
.overlay {
position: fixed;
top: 0;
left: 0;
right: 0;
bottom: 0;
background: rgba(0, 0, 0, 0.3);
touch-action: none;
}
.positioning-region {
display: flex;
justify-content: center;
position: fixed;
top: 0;
bottom: 0;
left: 0;
right: 0;
overflow: auto;
}
.control {
box-shadow: ${Ir};
margin-top: auto;
margin-bottom: auto;
border-radius: calc(${qn.rSr} * 1px);
width: var(--dialog-width);
height: var(--dialog-height);
background: ${qn.IfY};
z-index: 1;
border: calc(${qn.Han} * 1px) solid transparent;
}
`});class ls extends Fa{}class cs extends(rr(ls)){constructor(){super(...arguments),this.proxy=document.createElement("select")}}const ds="above";class us extends cs{constructor(){super(...arguments),this.open=!1,this.forcedPosition=!1,this.listboxId=oa("listbox-"),this.maxHeight=0}openChanged(e,t){if(this.collapsible){if(this.open)return this.ariaControls=this.listboxId,this.ariaExpanded="true",this.setPositioning(),this.focusAndScrollOptionIntoView(),this.indexWhenOpened=this.selectedIndex,void gn.SO.queueUpdate((()=>this.focus()));this.ariaControls="",this.ariaExpanded="false"}}get collapsible(){return!(this.multiple||"number"==typeof this.size)}get value(){return oi.y$.track(this,"value"),this._value}set value(e){var t,i,n,o,r,a,s;const l=`${this._value}`;if(null===(t=this._options)||void 0===t?void 0:t.length){const t=this._options.findIndex((t=>t.value===e)),l=null!==(n=null===(i=this._options[this.selectedIndex])||void 0===i?void 0:i.value)&&void 0!==n?n:null,c=null!==(r=null===(o=this._options[t])||void 0===o?void 0:o.value)&&void 0!==r?r:null;-1!==t&&l===c||(e="",this.selectedIndex=t),e=null!==(s=null===(a=this.firstSelectedOption)||void 0===a?void 0:a.value)&&void 0!==s?s:e}l!==e&&(this._value=e,super.valueChanged(l,e),oi.y$.notify(this,"value"),this.updateDisplayValue())}updateValue(e){var t,i;this.$fastController.isConnected&&(this.value=null!==(i=null===(t=this.firstSelectedOption)||void 0===t?void 0:t.value)&&void 0!==i?i:""),e&&(this.$emit("input"),this.$emit("change",this,{bubbles:!0,composed:void 0}))}selectedIndexChanged(e,t){super.selectedIndexChanged(e,t),this.updateValue()}positionChanged(e,t){this.positionAttribute=t,this.setPositioning()}setPositioning(){const e=this.getBoundingClientRect(),t=window.innerHeight-e.bottom;this.position=this.forcedPosition?this.positionAttribute:e.top>t?ds:"below",this.positionAttribute=this.forcedPosition?this.positionAttribute:this.position,this.maxHeight=this.position===ds?~~e.top:~~t}get displayValue(){var e,t;return oi.y$.track(this,"displayValue"),null!==(t=null===(e=this.firstSelectedOption)||void 0===e?void 0:e.text)&&void 0!==t?t:""}disabledChanged(e,t){super.disabledChanged&&super.disabledChanged(e,t),this.ariaDisabled=this.disabled?"true":"false"}formResetCallback(){this.setProxyOptions(),super.setDefaultSelectedOption(),-1===this.selectedIndex&&(this.selectedIndex=0)}clickHandler(e){if(!this.disabled){if(this.open){const t=e.target.closest("option,[role=option]");if(t&&t.disabled)return}return super.clickHandler(e),this.open=this.collapsible&&!this.open,this.open||this.indexWhenOpened===this.selectedIndex||this.updateValue(!0),!0}}focusoutHandler(e){var t;if(super.focusoutHandler(e),!this.open)return!0;const i=e.relatedTarget;this.isSameNode(i)?this.focus():(null===(t=this.options)||void 0===t?void 0:t.includes(i))||(this.open=!1,this.indexWhenOpened!==this.selectedIndex&&this.updateValue(!0))}handleChange(e,t){super.handleChange(e,t),"value"===t&&this.updateValue()}slottedOptionsChanged(e,t){this.options.forEach((e=>{oi.y$.getNotifier(e).unsubscribe(this,"value")})),super.slottedOptionsChanged(e,t),this.options.forEach((e=>{oi.y$.getNotifier(e).subscribe(this,"value")})),this.setProxyOptions(),this.updateValue()}mousedownHandler(e){var t;return e.offsetX>=0&&e.offsetX<=(null===(t=this.listbox)||void 0===t?void 0:t.scrollWidth)?super.mousedownHandler(e):this.collapsible}multipleChanged(e,t){super.multipleChanged(e,t),this.proxy&&(this.proxy.multiple=t)}selectedOptionsChanged(e,t){var i;super.selectedOptionsChanged(e,t),null===(i=this.options)||void 0===i||i.forEach(((e,t)=>{var i;const n=null===(i=this.proxy)||void 0===i?void 0:i.options.item(t);n&&(n.selected=e.selected)}))}setDefaultSelectedOption(){var e;const t=null!==(e=this.options)&&void 0!==e?e:Array.from(this.children).filter(La.slottedOptionFilter),i=null==t?void 0:t.findIndex((e=>e.hasAttribute("selected")||e.selected||e.value===this.value));this.selectedIndex=-1===i?0:i}setProxyOptions(){this.proxy instanceof HTMLSelectElement&&this.options&&(this.proxy.options.length=0,this.options.forEach((e=>{const t=e.proxy||(e instanceof HTMLOptionElement?e.cloneNode():null);t&&this.proxy.options.add(t)})))}keydownHandler(e){super.keydownHandler(e);const t=e.key||e.key.charCodeAt(0);switch(t){case uo:e.preventDefault(),this.collapsible&&this.typeAheadExpired&&(this.open=!this.open);break;case lo:case co:e.preventDefault();break;case ao:e.preventDefault(),this.open=!this.open;break;case so:this.collapsible&&this.open&&(e.preventDefault(),this.open=!1);break;case ho:return this.collapsible&&this.open&&(e.preventDefault(),this.open=!1),!0}return this.open||this.indexWhenOpened===this.selectedIndex||(this.updateValue(!0),this.indexWhenOpened=this.selectedIndex),!(t===io||t===ro)}connectedCallback(){super.connectedCallback(),this.forcedPosition=!!this.positionAttribute,this.addEventListener("contentchange",this.updateDisplayValue)}disconnectedCallback(){this.removeEventListener("contentchange",this.updateDisplayValue),super.disconnectedCallback()}sizeChanged(e,t){super.sizeChanged(e,t),this.proxy&&(this.proxy.size=t)}updateDisplayValue(){this.collapsible&&oi.y$.notify(this,"displayValue")}}(0,ii.gn)([(0,pn.Lj)({attribute:"open",mode:"boolean"})],us.prototype,"open",void 0),(0,ii.gn)([oi.lk],us.prototype,"collapsible",null),(0,ii.gn)([oi.LO],us.prototype,"control",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"position"})],us.prototype,"positionAttribute",void 0),(0,ii.gn)([oi.LO],us.prototype,"position",void 0),(0,ii.gn)([oi.LO],us.prototype,"maxHeight",void 0);class hs{}(0,ii.gn)([oi.LO],hs.prototype,"ariaControls",void 0),So(hs,Ba),So(us,yo,hs);const ps=".control",gs=":not([disabled]):not([open])",fs="[disabled]";class ms extends us{appearanceChanged(e,t){e!==t&&(this.classList.add(t),this.classList.remove(e))}connectedCallback(){super.connectedCallback(),this.appearance||(this.appearance="outline"),this.listbox&&qn.IfY.setValueFor(this.listbox,qn.s55)}}(0,an.gn)([(0,pn.Lj)({mode:"fromView"})],ms.prototype,"appearance",void 0);const vs=ms.compose({baseName:"select",baseClass:us,template:(e,t)=>$n`
<template
class="${e=>[e.collapsible&&"collapsible",e.collapsible&&e.open&&"open",e.disabled&&"disabled",e.collapsible&&e.position].filter(Boolean).join(" ")}"
aria-activedescendant="${e=>e.ariaActiveDescendant}"
aria-controls="${e=>e.ariaControls}"
aria-disabled="${e=>e.ariaDisabled}"
aria-expanded="${e=>e.ariaExpanded}"
aria-haspopup="${e=>e.collapsible?"listbox":null}"
aria-multiselectable="${e=>e.ariaMultiSelectable}"
?open="${e=>e.open}"
role="combobox"
tabindex="${e=>e.disabled?null:"0"}"
@click="${(e,t)=>e.clickHandler(t.event)}"
@focusin="${(e,t)=>e.focusinHandler(t.event)}"
@focusout="${(e,t)=>e.focusoutHandler(t.event)}"
@keydown="${(e,t)=>e.keydownHandler(t.event)}"
@mousedown="${(e,t)=>e.mousedownHandler(t.event)}"
>
${Wr((e=>e.collapsible),$n`
<div
class="control"
part="control"
?disabled="${e=>e.disabled}"
${vo("control")}
>
${bo(0,t)}
<slot name="button-container">
<div class="selected-value" part="selected-value">
<slot name="selected-value">${e=>e.displayValue}</slot>
</div>
<div aria-hidden="true" class="indicator" part="indicator">
<slot name="indicator">
${t.indicator||""}
</slot>
</div>
</slot>
${Co(0,t)}
</div>
`)}
<div
class="listbox"
id="${e=>e.listboxId}"
part="listbox"
role="listbox"
?disabled="${e=>e.disabled}"
?hidden="${e=>!!e.collapsible&&!e.open}"
${vo("listbox")}
>
<slot
${Ao({filter:La.slottedOptionFilter,flatten:!0,property:"slottedOptions"})}
></slot>
</div>
</template>
`,styles:(e,t)=>dn`
${zn("inline-flex")}
:host {
border-radius: calc(${qn.UWU} * 1px);
box-sizing: border-box;
color: ${qn.CHi};
fill: currentcolor;
font-family: ${qn.SVJ};
position: relative;
user-select: none;
min-width: 250px;
vertical-align: top;
}
.listbox {
box-shadow: ${Er};
background: ${qn.IfY};
border-radius: calc(${qn.rSr} * 1px);
box-sizing: border-box;
display: inline-flex;
flex-direction: column;
left: 0;
max-height: calc(var(--max-height) - (${Lo} * 1px));
padding: calc((${qn._5n} - ${qn.Han} ) * 1px);
overflow-y: auto;
position: absolute;
width: 100%;
z-index: 1;
margin: 1px 0;
border: calc(${qn.Han} * 1px) solid transparent;
}
.listbox[hidden] {
display: none;
}
.control {
border: calc(${qn.Han} * 1px) solid transparent;
border-radius: calc(${qn.UWU} * 1px);
height: calc(${Lo} * 1px);
align-items: center;
box-sizing: border-box;
cursor: pointer;
display: flex;
${Eo}
min-height: 100%;
padding: 0 calc(${qn._5n} * 2.25px);
width: 100%;
}
:host(:${No}) {
${Ro}
}
:host([disabled]) .control {
cursor: ${ur};
opacity: ${qn.VFZ};
user-select: none;
}
:host([open][position='above']) .listbox {
bottom: calc((${Lo} + ${qn._5n} * 2) * 1px);
}
:host([open][position='below']) .listbox {
top: calc((${Lo} + ${qn._5n} * 2) * 1px);
}
.selected-value {
font-family: inherit;
flex: 1 1 auto;
text-align: start;
}
.indicator {
flex: 0 0 auto;
margin-inline-start: 1em;
}
slot[name='listbox'] {
display: none;
width: 100%;
}
:host([open]) slot[name='listbox'] {
display: flex;
position: absolute;
}
.start {
margin-inline-end: 11px;
}
.end {
margin-inline-start: 11px;
}
.start,
.end,
.indicator,
::slotted(svg) {
display: flex;
}
::slotted([role='option']) {
flex: 0 0 auto;
}
`.withBehaviors(Xo("outline",jo(0,0,gs,fs)),Xo("filled",wa(0,0,ps,gs).withBehaviors(Gn(Oa(0,0,ps,gs)))),Xo("stealth",qo(0,0,gs,fs)),Gn(dn`
:host([open]) .listbox {
background: ${Wn.ButtonFace};
border-color: ${Wn.CanvasText};
}
`)),indicator:'\n <svg width="12" height="12" xmlns="http://www.w3.org/2000/svg">\n <path d="M2.15 4.65c.2-.2.5-.2.7 0L6 7.79l3.15-3.14a.5.5 0 11.7.7l-3.5 3.5a.5.5 0 01-.7 0l-3.5-3.5a.5.5 0 010-.7z"/>\n </svg>\n '}),ys=Yr.compose({baseName:"anchored-region",template:(e,t)=>$n`
<template class="${e=>e.initialLayoutComplete?"loaded":""}">
${Wr((e=>e.initialLayoutComplete),$n`
<slot></slot>
`)}
</template>
`,styles:(e,t)=>dn`
:host {
contain: layout;
display: block;
}
`});class Cs extends zi{constructor(){super(...arguments),this.anchor="",this.delay=300,this.autoUpdateMode="anchor",this.anchorElement=null,this.viewportElement=null,this.verticalPositioningMode="dynamic",this.horizontalPositioningMode="dynamic",this.horizontalInset="false",this.verticalInset="false",this.horizontalScaling="content",this.verticalScaling="content",this.verticalDefaultPosition=void 0,this.horizontalDefaultPosition=void 0,this.tooltipVisible=!1,this.currentDirection=Br.ltr,this.showDelayTimer=null,this.hideDelayTimer=null,this.isAnchorHoveredFocused=!1,this.isRegionHovered=!1,this.handlePositionChange=e=>{this.classList.toggle("top","start"===this.region.verticalPosition),this.classList.toggle("bottom","end"===this.region.verticalPosition),this.classList.toggle("inset-top","insetStart"===this.region.verticalPosition),this.classList.toggle("inset-bottom","insetEnd"===this.region.verticalPosition),this.classList.toggle("center-vertical","center"===this.region.verticalPosition),this.classList.toggle("left","start"===this.region.horizontalPosition),this.classList.toggle("right","end"===this.region.horizontalPosition),this.classList.toggle("inset-left","insetStart"===this.region.horizontalPosition),this.classList.toggle("inset-right","insetEnd"===this.region.horizontalPosition),this.classList.toggle("center-horizontal","center"===this.region.horizontalPosition)},this.handleRegionMouseOver=e=>{this.isRegionHovered=!0},this.handleRegionMouseOut=e=>{this.isRegionHovered=!1,this.startHideDelayTimer()},this.handleAnchorMouseOver=e=>{this.tooltipVisible?this.isAnchorHoveredFocused=!0:this.startShowDelayTimer()},this.handleAnchorMouseOut=e=>{this.isAnchorHoveredFocused=!1,this.clearShowDelayTimer(),this.startHideDelayTimer()},this.handleAnchorFocusIn=e=>{this.startShowDelayTimer()},this.handleAnchorFocusOut=e=>{this.isAnchorHoveredFocused=!1,this.clearShowDelayTimer(),this.startHideDelayTimer()},this.startHideDelayTimer=()=>{this.clearHideDelayTimer(),this.tooltipVisible&&(this.hideDelayTimer=window.setTimeout((()=>{this.updateTooltipVisibility()}),60))},this.clearHideDelayTimer=()=>{null!==this.hideDelayTimer&&(clearTimeout(this.hideDelayTimer),this.hideDelayTimer=null)},this.startShowDelayTimer=()=>{this.isAnchorHoveredFocused||(this.delay>1?null===this.showDelayTimer&&(this.showDelayTimer=window.setTimeout((()=>{this.startHover()}),this.delay)):this.startHover())},this.startHover=()=>{this.isAnchorHoveredFocused=!0,this.updateTooltipVisibility()},this.clearShowDelayTimer=()=>{null!==this.showDelayTimer&&(clearTimeout(this.showDelayTimer),this.showDelayTimer=null)},this.getAnchor=()=>{const e=this.getRootNode();return e instanceof ShadowRoot?e.getElementById(this.anchor):document.getElementById(this.anchor)},this.handleDocumentKeydown=e=>{!e.defaultPrevented&&this.tooltipVisible&&e.key===so&&(this.isAnchorHoveredFocused=!1,this.updateTooltipVisibility(),this.$emit("dismiss"))},this.updateTooltipVisibility=()=>{if(!1===this.visible)this.hideTooltip();else{if(!0===this.visible)return void this.showTooltip();if(this.isAnchorHoveredFocused||this.isRegionHovered)return void this.showTooltip();this.hideTooltip()}},this.showTooltip=()=>{this.tooltipVisible||(this.currentDirection=Fr(this),this.tooltipVisible=!0,document.addEventListener("keydown",this.handleDocumentKeydown),gn.SO.queueUpdate(this.setRegionProps))},this.hideTooltip=()=>{this.tooltipVisible&&(this.clearHideDelayTimer(),null!==this.region&&void 0!==this.region&&(this.region.removeEventListener("positionchange",this.handlePositionChange),this.region.viewportElement=null,this.region.anchorElement=null,this.region.removeEventListener("mouseover",this.handleRegionMouseOver),this.region.removeEventListener("mouseout",this.handleRegionMouseOut)),document.removeEventListener("keydown",this.handleDocumentKeydown),this.tooltipVisible=!1)},this.setRegionProps=()=>{this.tooltipVisible&&(this.region.viewportElement=this.viewportElement,this.region.anchorElement=this.anchorElement,this.region.addEventListener("positionchange",this.handlePositionChange),this.region.addEventListener("mouseover",this.handleRegionMouseOver,{passive:!0}),this.region.addEventListener("mouseout",this.handleRegionMouseOut,{passive:!0}))}}visibleChanged(){this.$fastController.isConnected&&(this.updateTooltipVisibility(),this.updateLayout())}anchorChanged(){this.$fastController.isConnected&&(this.anchorElement=this.getAnchor())}positionChanged(){this.$fastController.isConnected&&this.updateLayout()}anchorElementChanged(e){if(this.$fastController.isConnected){if(null!=e&&(e.removeEventListener("mouseover",this.handleAnchorMouseOver),e.removeEventListener("mouseout",this.handleAnchorMouseOut),e.removeEventListener("focusin",this.handleAnchorFocusIn),e.removeEventListener("focusout",this.handleAnchorFocusOut)),null!==this.anchorElement&&void 0!==this.anchorElement){this.anchorElement.addEventListener("mouseover",this.handleAnchorMouseOver,{passive:!0}),this.anchorElement.addEventListener("mouseout",this.handleAnchorMouseOut,{passive:!0}),this.anchorElement.addEventListener("focusin",this.handleAnchorFocusIn,{passive:!0}),this.anchorElement.addEventListener("focusout",this.handleAnchorFocusOut,{passive:!0});const e=this.anchorElement.id;null!==this.anchorElement.parentElement&&this.anchorElement.parentElement.querySelectorAll(":hover").forEach((t=>{t.id===e&&this.startShowDelayTimer()}))}null!==this.region&&void 0!==this.region&&this.tooltipVisible&&(this.region.anchorElement=this.anchorElement),this.updateLayout()}}viewportElementChanged(){null!==this.region&&void 0!==this.region&&(this.region.viewportElement=this.viewportElement),this.updateLayout()}connectedCallback(){super.connectedCallback(),this.anchorElement=this.getAnchor(),this.updateTooltipVisibility()}disconnectedCallback(){this.hideTooltip(),this.clearShowDelayTimer(),this.clearHideDelayTimer(),super.disconnectedCallback()}updateLayout(){switch(this.verticalPositioningMode="locktodefault",this.horizontalPositioningMode="locktodefault",this.position){case"top":case"bottom":this.verticalDefaultPosition=this.position,this.horizontalDefaultPosition="center";break;case"right":case"left":case"start":case"end":this.verticalDefaultPosition="center",this.horizontalDefaultPosition=this.position;break;case"top-left":this.verticalDefaultPosition="top",this.horizontalDefaultPosition="left";break;case"top-right":this.verticalDefaultPosition="top",this.horizontalDefaultPosition="right";break;case"bottom-left":this.verticalDefaultPosition="bottom",this.horizontalDefaultPosition="left";break;case"bottom-right":this.verticalDefaultPosition="bottom",this.horizontalDefaultPosition="right";break;case"top-start":this.verticalDefaultPosition="top",this.horizontalDefaultPosition="start";break;case"top-end":this.verticalDefaultPosition="top",this.horizontalDefaultPosition="end";break;case"bottom-start":this.verticalDefaultPosition="bottom",this.horizontalDefaultPosition="start";break;case"bottom-end":this.verticalDefaultPosition="bottom",this.horizontalDefaultPosition="end";break;default:this.verticalPositioningMode="dynamic",this.horizontalPositioningMode="dynamic",this.verticalDefaultPosition=void 0,this.horizontalDefaultPosition="center"}}}(0,ii.gn)([(0,pn.Lj)({mode:"boolean"})],Cs.prototype,"visible",void 0),(0,ii.gn)([pn.Lj],Cs.prototype,"anchor",void 0),(0,ii.gn)([pn.Lj],Cs.prototype,"delay",void 0),(0,ii.gn)([pn.Lj],Cs.prototype,"position",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"auto-update-mode"})],Cs.prototype,"autoUpdateMode",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"horizontal-viewport-lock"})],Cs.prototype,"horizontalViewportLock",void 0),(0,ii.gn)([(0,pn.Lj)({attribute:"vertical-viewport-lock"})],Cs.prototype,"verticalViewportLock",void 0),(0,ii.gn)([oi.LO],Cs.prototype,"anchorElement",void 0),(0,ii.gn)([oi.LO],Cs.prototype,"viewportElement",void 0),(0,ii.gn)([oi.LO],Cs.prototype,"verticalPositioningMode",void 0),(0,ii.gn)([oi.LO],Cs.prototype,"horizontalPositioningMode",void 0),(0,ii.gn)([oi.LO],Cs.prototype,"horizontalInset",void 0),(0,ii.gn)([oi.LO],Cs.prototype,"verticalInset",void 0),(0,ii.gn)([oi.LO],Cs.prototype,"horizontalScaling",void 0),(0,ii.gn)([oi.LO],Cs.prototype,"verticalScaling",void 0),(0,ii.gn)([oi.LO],Cs.prototype,"verticalDefaultPosition",void 0),(0,ii.gn)([oi.LO],Cs.prototype,"horizontalDefaultPosition",void 0),(0,ii.gn)([oi.LO],Cs.prototype,"tooltipVisible",void 0),(0,ii.gn)([oi.LO],Cs.prototype,"currentDirection",void 0);const bs=class extends Cs{connectedCallback(){super.connectedCallback(),qn.IfY.setValueFor(this,qn.s55)}}.compose({baseName:"tooltip",baseClass:Cs,template:(e,t)=>$n`
${Wr((e=>e.tooltipVisible),$n`
<${e.tagFor(Yr)}
fixed-placement="true"
auto-update-mode="${e=>e.autoUpdateMode}"
vertical-positioning-mode="${e=>e.verticalPositioningMode}"
vertical-default-position="${e=>e.verticalDefaultPosition}"
vertical-inset="${e=>e.verticalInset}"
vertical-scaling="${e=>e.verticalScaling}"
horizontal-positioning-mode="${e=>e.horizontalPositioningMode}"
horizontal-default-position="${e=>e.horizontalDefaultPosition}"
horizontal-scaling="${e=>e.horizontalScaling}"
horizontal-inset="${e=>e.horizontalInset}"
vertical-viewport-lock="${e=>e.horizontalViewportLock}"
horizontal-viewport-lock="${e=>e.verticalViewportLock}"
dir="${e=>e.currentDirection}"
${vo("region")}
>
<div class="tooltip" part="tooltip" role="tooltip">
<slot></slot>
</div>
</${e.tagFor(Yr)}>
`)}
`,styles:(e,t)=>dn`
:host {
position: relative;
contain: layout;
overflow: visible;
height: 0;
width: 0;
z-index: 10000;
}
.tooltip {
box-sizing: border-box;
border-radius: calc(${qn.UWU} * 1px);
border: calc(${qn.Han} * 1px) solid ${qn.Ja_};
background: ${qn.IfY};
color: ${qn.CHi};
padding: 4px 12px;
height: fit-content;
width: fit-content;
${Eo}
white-space: nowrap;
box-shadow: ${Pr};
}
${e.tagFor(Yr)} {
display: flex;
justify-content: center;
align-items: center;
overflow: visible;
flex-direction: row;
}
${e.tagFor(Yr)}.right,
${e.tagFor(Yr)}.left {
flex-direction: column;
}
${e.tagFor(Yr)}.top .tooltip::after,
${e.tagFor(Yr)}.bottom .tooltip::after,
${e.tagFor(Yr)}.left .tooltip::after,
${e.tagFor(Yr)}.right .tooltip::after {
content: '';
width: 12px;
height: 12px;
background: ${qn.IfY};
border-top: calc(${qn.Han} * 1px) solid ${qn.Ja_};
border-left: calc(${qn.Han} * 1px) solid ${qn.Ja_};
position: absolute;
}
${e.tagFor(Yr)}.top .tooltip::after {
transform: translateX(-50%) rotate(225deg);
bottom: 5px;
left: 50%;
}
${e.tagFor(Yr)}.top .tooltip {
margin-bottom: 12px;
}
${e.tagFor(Yr)}.bottom .tooltip::after {
transform: translateX(-50%) rotate(45deg);
top: 5px;
left: 50%;
}
${e.tagFor(Yr)}.bottom .tooltip {
margin-top: 12px;
}
${e.tagFor(Yr)}.left .tooltip::after {
transform: translateY(-50%) rotate(135deg);
top: 50%;
right: 5px;
}
${e.tagFor(Yr)}.left .tooltip {
margin-right: 12px;
}
${e.tagFor(Yr)}.right .tooltip::after {
transform: translateY(-50%) rotate(-45deg);
top: 50%;
left: 5px;
}
${e.tagFor(Yr)}.right .tooltip {
margin-left: 12px;
}
`.withBehaviors(Gn(dn`
:host([disabled]) {
opacity: 1;
}
${e.tagFor(Yr)}.top .tooltip::after,
${e.tagFor(Yr)}.bottom .tooltip::after,
${e.tagFor(Yr)}.left .tooltip::after,
${e.tagFor(Yr)}.right .tooltip::after {
content: '';
width: unset;
height: unset;
}
`))});class Ss extends HTMLElement{constructor(){super(),(0,s.Z)(this,"textContent",void 0),(0,s.Z)(this,"checked",void 0),(0,s.Z)(this,"shadow",void 0),(0,s.Z)(this,"switchLabelID","switchLabel"),(0,s.Z)(this,"checkboxBtnID","checkboxBtnID"),this.buildComponent()}connectedCallback(){this.initailState()}buildComponent(){const e=this.getySwitchButton(),t=this.getSwitchLabel(),i=this.getStylesSheet();this.shadow=this.attachShadow({mode:"open"}),this.shadow.appendChild(i),this.shadow.appendChild(t),this.shadow.appendChild(e),this.registerEvents()}getySwitchButton(){const e=document.createElement("label");e.className="switch";const t=document.createElement("input");t.type="checkbox",t.id=this.checkboxBtnID;const i=document.createElement("span");return i.className="slider round",e.appendChild(t),e.appendChild(i),e}getSwitchLabel(){const e=document.createElement("span");return e.id=this.switchLabelID,e}getStylesSheet(){const e=document.createElement("link");return e.setAttribute("rel","stylesheet"),e.setAttribute("href","data:text/css,"+this.getStyles()),e}getStyles(){return'\n span {\n cursor: pointer;\n }\n\n .switch {\n position: relative;\n display: inline-block;\n width: 38px;\n height: 18px;\n }\n\n .switch input {\n opacity: 0;\n width: 0;\n height: 0;\n }\n\n .slider {\n position: absolute;\n cursor: pointer;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background: white;\n -webkit-transition: .4s;\n transition: .4s;\n }\n\n .slider:before {\n position: absolute;\n content: "";\n height: 12px;\n width: 12px;\n left: 3px;\n bottom: 2px;\n background-color: black;\n -webkit-transition: .4s;\n transition: .4s;\n }\n\n .slider.round {\n border-radius: 34px;\n border: 0.5px solid black;\n }\n\n .slider.round:before {\n border-radius: 50%;\n }\n\n input:checked + .slider:before {\n -webkit-transform: translateX(19px);\n -ms-transform: translateX(19px);\n transform: translateX(19px);\n background-color: white;\n }\n\n input:checked + .slider {\n background-color: rgb(33,150,243);\n border: 0.5px solid transparent;\n }\n '}registerEvents(){this.shadow.addEventListener("click",(()=>{const e=this.shadow.getElementById(this.checkboxBtnID);e&&(e.checked=!e.checked,this.checked=e.checked,this.dispatchEvent(new Event("change")))}))}initailState(){const e=this.shadow.getElementById(this.switchLabelID);e&&(e.textContent=this.textContent);const t=this.shadow.getElementById(this.checkboxBtnID);t&&(t.checked="true"===this.getAttribute("checked"))}}var xs={randomUUID:"undefined"!=typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};let Ts;const ws=new Uint8Array(16);function Os(){if(!Ts&&(Ts="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!Ts))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return Ts(ws)}const Ps=[];for(let e=0;e<256;++e)Ps.push((e+256).toString(16).slice(1));var As=function(e,t,i){if(xs.randomUUID&&!t&&!e)return xs.randomUUID();const n=(e=e||{}).random||(e.rng||Os)();if(n[6]=15&n[6]|64,n[8]=63&n[8]|128,t){i=i||0;for(let e=0;e<16;++e)t[i+e]=n[e];return t}return function(e,t=0){return Ps[e[t+0]]+Ps[e[t+1]]+Ps[e[t+2]]+Ps[e[t+3]]+"-"+Ps[e[t+4]]+Ps[e[t+5]]+"-"+Ps[e[t+6]]+Ps[e[t+7]]+"-"+Ps[e[t+8]]+Ps[e[t+9]]+"-"+Ps[e[t+10]]+Ps[e[t+11]]+Ps[e[t+12]]+Ps[e[t+13]]+Ps[e[t+14]]+Ps[e[t+15]]}(n)};class Es extends V.Z{constructor(e,t,i,n,o=!1,r=!1,a=!1,l=!1,c=!1,d=!1,u=-1,h=-1,p=-1,g=-1,f=-1,m=-1,v=-1,y=-1,C=-1,b=-1,S=-1,x=-1,T=-1,w=-1,O=-1,P=-1,A=-1,E=-1,k=-1,I=-1,D=-1){super(),(0,s.Z)(this,"FlyoutId",void 0),(0,s.Z)(this,"TimelineId",void 0),(0,s.Z)(this,"Domain",void 0),(0,s.Z)(this,"FetchURL",void 0),(0,s.Z)(this,"openedWith",void 0),(0,s.Z)(this,"IsSupportedDomain",void 0),(0,s.Z)(this,"IsFallBack",void 0),(0,s.Z)(this,"IsPane",void 0),(0,s.Z)(this,"IsFirstRender",null),(0,s.Z)(this,"IsPDP",null),(0,s.Z)(this,"isRerank",null),(0,s.Z)(this,"StartOrNavTime",void 0),(0,s.Z)(this,"TimeDataLoaded",void 0),(0,s.Z)(this,"FlyoutFlyoutV2FetchLoaded",void 0),(0,s.Z)(this,"FlyoutDOMContentLoaded",void 0),(0,s.Z)(this,"FlyoutInitialDataReceived",void 0),(0,s.Z)(this,"FlyoutManifestFetchStart",void 0),(0,s.Z)(this,"FlyoutManifestFetchEnd",void 0),(0,s.Z)(this,"FlyoutHashFetchStart",void 0),(0,s.Z)(this,"FlyoutHashFetchEnd",void 0),(0,s.Z)(this,"FlyoutFastInitializeStart",void 0),(0,s.Z)(this,"FlyoutFastInitializeEnd",void 0),(0,s.Z)(this,"FlyoutNavigation",void 0),(0,s.Z)(this,"FlyoutLoadTimeDataUpdate",void 0),(0,s.Z)(this,"FlyoutInitializeStart",void 0),(0,s.Z)(this,"FlyoutRefreshStart",void 0),(0,s.Z)(this,"FlyoutRemoveRenderedModulesStart",void 0),(0,s.Z)(this,"FlyoutRemoveRenderedModulesEnd",void 0),(0,s.Z)(this,"FlyoutInitializeModuleDataStart",void 0),(0,s.Z)(this,"FlyoutInitializeModuleDataEnd",void 0),(0,s.Z)(this,"FlyoutRenderStart",void 0),(0,s.Z)(this,"FlyoutRenderEnd",void 0),this.TimelineId=e,this.Domain=t,this.FetchURL=i,this.openedWith=n,this.IsSupportedDomain=o,this.IsFallBack=r,this.IsPane=a,this.IsFirstRender=l,this.IsPDP=c,this.isRerank=d,this.StartOrNavTime=u,this.TimeDataLoaded=h,this.FlyoutFlyoutV2FetchLoaded=p,this.FlyoutDOMContentLoaded=g,this.FlyoutInitialDataReceived=f,this.FlyoutManifestFetchStart=m,this.FlyoutManifestFetchEnd=v,this.FlyoutHashFetchStart=y,this.FlyoutHashFetchEnd=C,this.FlyoutFastInitializeStart=b,this.FlyoutFastInitializeEnd=S,this.FlyoutNavigation=x,this.FlyoutLoadTimeDataUpdate=T,this.FlyoutInitializeStart=w,this.FlyoutRefreshStart=O,this.FlyoutRemoveRenderedModulesStart=P,this.FlyoutRemoveRenderedModulesEnd=A,this.FlyoutInitializeModuleDataStart=E,this.FlyoutInitializeModuleDataEnd=k,this.FlyoutRenderStart=I,this.FlyoutRenderEnd=D}}var ks=Es;let Is=function(e){return e.FlyoutEdgeFlyoutV2FetchLoaded="FlyoutEdgeFlyoutV2FetchLoaded",e.FlyoutDOMContentLoaded="FlyoutDOMContentLoaded",e.FlyoutInitialDataReceived="FlyoutInitialDataReceived",e.FlyoutInitialize="FlyoutInitialize",e.FlyoutManifestFetchStart="FlyoutManifestFetchStart",e.FlyoutManifestFetchEnd="FlyoutManifestFetchEnd",e.FlyoutHashFetchStart="FlyoutHashFetchStart",e.FlyoutHashFetchEnd="FlyoutHashFetchEnd",e.FlyoutScriptsLoaded="FlyoutScriptsLoaded",e.FlyoutFastInitializeStart="FlyoutFastInitializeStart",e.FlyoutFastInitializeEnd="FlyoutFastInitializeEnd",e.FlyoutNavigation="FlyoutNavigationNavigation",e.FlyoutLoadTimeDataUpdate="LoadTimeDataUpdate",e.FlyoutInitializeStart="FlyoutInitializeStart",e.FlyoutRefreshStart="FlyoutRefreshStart",e.FlyoutRemoveRenderedModulesStart="FlyoutRemoveRenderedModulesStart",e.FlyoutRemoveRenderedModulesEnd="FlyoutRemoveRenderedModulesEnd",e.FlyoutRenderStart="FlyoutRenderStart",e.FlyoutRenderEnd="FlyoutRenderEnd",e.FlyoutInitializeModuleDataStart="FlyoutInitializeModuleDataStart",e.FlyoutInitializeModuleDataEnd="FlyoutInitializeModuleDataEnd",e}({});class Ds{static setGlobalMark(e){Ds.throttled()||performance.mark(e)}static throttled(){return!e.R.getServiceExperimentValue(f.H.loggingThrottle)}constructor(e,t=null,i=!1,n=!1){(0,s.Z)(this,"id",void 0),(0,s.Z)(this,"isPane",!1),(0,s.Z)(this,"fetchURL",void 0),(0,s.Z)(this,"openedWith",""),(0,s.Z)(this,"isSupportedDomain",!1),(0,s.Z)(this,"isFallback",!1),(0,s.Z)(this,"isPDP",!1),(0,s.Z)(this,"addedMarkers",new Set),(0,s.Z)(this,"startOrNavTime",-1),(0,s.Z)(this,"timeDataLoaded",-1),(0,s.Z)(this,"isFirstRender",!1),(0,s.Z)(this,"isRerank",!1),(0,s.Z)(this,"resetCompleted",!1),(0,s.Z)(this,"logModule",null),(0,s.Z)(this,"flyoutData",null),(0,s.Z)(this,"published",!1),this.startOrNavTime=e??-1,this.timeDataLoaded=t??-1,this.id=As(),this.isFirstRender=i,this.isPDP=n??!1,setTimeout((()=>{this.resetMarkers()}),Ds.resetTimeoutMS)}markEvent(e){if(!Ds.throttled())switch(e){case Is.FlyoutEdgeFlyoutV2FetchLoaded:this.addMark(e);break;case Is.FlyoutRenderEnd:this.addMark(e),this.publish(),this.resetMarkers();break;default:this.addMark(e)}}resetMarkers(){try{if(Ds.throttled()||this.resetCompleted)return;this.addedMarkers.forEach((e=>performance.clearMarks(e))),this.resetCompleted=!0}catch(e){}}publish(){if(this.published||Ds.throttled())return;if(!this.logModule||!this.flyoutData)return;const e=this.isFirstRender?this.getLatestGlobalEntryValue(Is.FlyoutEdgeFlyoutV2FetchLoaded):-1,t=this.isFirstRender?this.getLatestGlobalEntryValue(Is.FlyoutDOMContentLoaded):-1,n=this.isFirstRender?this.getLatestGlobalEntryValue(Is.FlyoutInitialDataReceived):-1,o=this.isFirstRender?this.getLatestGlobalEntryValue(Is.FlyoutManifestFetchStart):-1,r=this.isFirstRender?this.getLatestGlobalEntryValue(Is.FlyoutManifestFetchEnd):-1,a=this.isFirstRender?this.getLatestGlobalEntryValue(Is.FlyoutHashFetchStart):-1,s=this.isFirstRender?this.getLatestGlobalEntryValue(Is.FlyoutHashFetchEnd):-1,l=this.isFirstRender?this.getLatestGlobalEntryValue(Is.FlyoutFastInitializeStart):-1,c=this.isFirstRender?this.getLatestGlobalEntryValue(Is.FlyoutFastInitializeEnd):-1,d=this.getLatestEntryValue(Is.FlyoutNavigation),u=this.getLatestEntryValue(Is.FlyoutLoadTimeDataUpdate),h=this.getLatestEntryValue(Is.FlyoutInitializeStart),p=this.getLatestEntryValue(Is.FlyoutRefreshStart),g=this.getLatestEntryValue(Is.FlyoutRemoveRenderedModulesStart),f=this.getLatestEntryValue(Is.FlyoutRemoveRenderedModulesEnd),m=this.getLatestEntryValue(Is.FlyoutInitializeModuleDataStart),v=this.getLatestEntryValue(Is.FlyoutInitializeModuleDataEnd),y=this.getLatestEntryValue(Is.FlyoutRenderStart),C=this.getLatestEntryValue(Is.FlyoutRenderEnd),b=new ks(this.id,this.flyoutData.common?.domain,this.fetchURL,this.openedWith,this.isSupportedDomain,this.isFallback,this.isPane,this.isFirstRender,this.isPDP,this.isRerank,this.startOrNavTime,this.timeDataLoaded,e,t,n,o,r,a,s,l,c,d,u,h,p,g,f,m,v,y,C);this.logModule?.LogInfoEvent(i.R.RenderTimeline,"",b),this.published=!0}setIsFallback(e){this.isFallback=e??!1}setIsRerank(e){this.isRerank=e??!1}setFetchUrl(e){this.fetchURL=e??""}addLogModule(e){this.logModule=e}addFlyoutData(e){this.flyoutData=e,this.isSupportedDomain=e?.common?.isDomainEligible??!1,this.isPane=e?.common?.isPane??!1,this.openedWith=e?.common?.openedWith?.toString()??""}setIsSupportedDomain(e){this.isSupportedDomain=e}setIsPane(e){this.isPane=e}getLatestGlobalEntryValue(e){return performance.getEntriesByName(e)?.at(-1)?.startTime??-1}getLatestEntryValue(e){const t=this.getMarkerName(e);return performance.getEntriesByName(t)?.at(-1)?.startTime??-1}addMark(e){const t=this.getMarkerName(e);this.addedMarkers.add(t),performance.mark(t)}getMarkerName(e){return e+"-"+this.id}}(0,s.Z)(Ds,"resetTimeoutMS",5e4);class _s extends zi{handleImageContentChange(){this.imageContainer.classList.toggle("image",this.image.assignedNodes().length>0)}}var Ns;(0,an.gn)([pn.Lj],_s.prototype,"isAffiliate",void 0),function(e){e.Canvas="Canvas",e.CanvasText="CanvasText",e.LinkText="LinkText",e.VisitedText="VisitedText",e.ActiveText="ActiveText",e.ButtonFace="ButtonFace",e.ButtonText="ButtonText",e.Field="Field",e.FieldText="FieldText",e.Highlight="Highlight",e.HighlightText="HighlightText",e.GrayText="GrayText"}(Ns||(Ns={}));const Rs=_s.compose({baseName:"attribution",styles:(e,t)=>dn`
${zn("inline-flex")} :host {
box-sizing: border-box;
font-family: ${qn.SVJ};
font-size: ${qn.sNp};
font-weight: 400;
line-height: ${qn.vgC};
align-items: center;
color: ${qn.Q5n};
min-height: 16px;
}
.content {
display: flex;
flex-direction: row;
column-gap: 8px;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
.content.affiliate {
align-items: center;
overflow: unset;
}
.image {
display: flex;
margin-inline-end: calc(${qn._5n} * 2px);
}
`.withBehaviors(Gn(dn`
:host,
.content {
color: ${Ns.CanvasText};
fill: currentcolor;
}
`)),template:(e,t)=>$n`
<span part="image" ${vo("imageContainer")}>
<slot
name="image"
${vo("image")}
@slotchange=${e=>e.handleImageContentChange()}
></slot>
</span>
<span part="content" class="content ${e=>e.isAffiliate?"affiliate":""}">
<slot></slot>
</span>
`});class Ms extends zi{handleCTALinkClick(e){return e.preventDefault(),e.stopPropagation(),this.onCTAClick(this.ctaUrl),!1}}(0,an.gn)([oi.LO],Ms.prototype,"onCTAClick",void 0),(0,an.gn)([pn.Lj],Ms.prototype,"backgroundStyles",void 0),(0,an.gn)([pn.Lj],Ms.prototype,"titleText",void 0),(0,an.gn)([pn.Lj],Ms.prototype,"ctaText",void 0),(0,an.gn)([pn.Lj],Ms.prototype,"ctaUrl",void 0);const Ls=dn`
.banner-card-container {
padding: 20px 0;
margin: 0 20px;
}
.banner-card {
width: 100%;
height: 189px;
background: ${qn._Bj};
box-shadow: none;
}
.banner-card:hover {
box-shadow: 0px 3px 6px rgba(0, 0, 0, 0.12);
}
.banner-card-background {
background: var(--shopping-stripe-background, ${qn._Bj});
background-position: left bottom;
width: 100%;
height: 189px;
transform: scaleX(-1);
}
.banner-info {
position: absolute;
inset: 0;
left: 20px;
right: 20px;
display: flex;
flex-direction: row;
align-items: center;
}
.title {
color: var(--shopping-stripe-heading-color);
font-weight: 700;
font-size: 22px;
line-height: 24px;
}
.cta-text {
margin-top: 6px;
text-decoration: underline;
color: var(--shopping-stripe-heading-color);
}
@media (-ms-high-contrast: active) {
.banner-card {
border: 1px solid linkText;
color: linkText;
}
.banner-card:hover {
outline: 1px solid highlight;
}
}
`,Bs=$n`
<a
class="anchor-wrapper"
target="_blank"
href="${e=>e.ctaUrl}"
aria-label="${e=>`${e.titleText} - ${e.ctaText}`}"
@click="${(e,t)=>e.handleCTALinkClick(t.event)}">
<fluent-card class="banner-card" style="${e=>e.backgroundStyles}">
<div class="banner-card-background"></div>
<div class="banner-info">
<div class="banner-info-inner">
<div class="title">${e=>e.titleText}</div>
<div class="cta-text">
${e=>e.ctaText}
</div>
</div>
</div>
</fluent-card>
</a>
`,Fs=$n`<fluent-card class="banner-card"></fluent-card>`,Us=Ms.compose({baseName:"banner-card",shadowOptions:{delegatesFocus:!0},styles:Ls,template:(e,t)=>$n`
<template>
<div class="banner-card-container">
${Wr((e=>e.titleText),Bs)}
${Wr((e=>!e.titleText),Fs)}
</div>
</template>
`});class Hs extends Zo{constructor(){super(...arguments),this.isFirst=!1,this.isLast=!1,this.isPane=!1}}(0,an.gn)([pn.Lj],Hs.prototype,"minPurchaseValue",void 0),(0,an.gn)([pn.Lj],Hs.prototype,"cashBackAmount",void 0),(0,an.gn)([pn.Lj],Hs.prototype,"scope",void 0),(0,an.gn)([pn.Lj],Hs.prototype,"expireTime",void 0),(0,an.gn)([pn.Lj],Hs.prototype,"domain",void 0),(0,an.gn)([pn.Lj],Hs.prototype,"cashbackStr",void 0),(0,an.gn)([oi.LO],Hs.prototype,"isFirst",void 0),(0,an.gn)([oi.LO],Hs.prototype,"isLast",void 0),(0,an.gn)([pn.Lj],Hs.prototype,"isPane",void 0);const $s=dn`
${zn("grid")} :host {
--content-max-lines: 2;
outline: none;
font-family: ${qn.SVJ};
font-size: ${qn.sNp};
font-weight: 600;
line-height: ${qn.vgC};
min-width: calc(${Lo} * 1px);
border-radius: calc(${qn.rSr} * 1px);
box-sizing: border-box;
color: ${qn.CHi};
fill: currentcolor;
cursor: pointer;
position: relative;
}
:host {
display: block;
box-sizing: border-box;
}
:host(:hover) {
background: linear-gradient(265.08deg, rgba(36, 255, 0, 0.06) -6.71%, rgba(0, 210, 255, 0.06) 38.87%, rgba(255, 188, 125, 0.06) 93.88%);
}
.control:${No} {
box-shadow: 0 0 0 calc(${qn.vxp} * 1px) ${qn.yGg};
}
.aCashbackCardWrapper {
display: grid;
width: 100%;
align-items: center;
gap: 15px;
padding: 12px 12px;
box-sizing: border-box;
text-decoration: none;
background: transparent;
outline: none;
border: none;
color: inherit;
fill: inherit;
border-radius: 0px;
border-top: var(--product-wrapper-border, 1px solid rgb(236, 236, 236));
position: relative;
}
.aCashbackCardWrapperPane {
display: grid;
grid-template-columns: 66px 1fr;
height: 80px;
width: 100%;
align-items: center;
gap: 15px;
box-sizing: border-box;
text-decoration: none;
outline: none;
border: none;
color: inherit;
fill: inherit;
background-color: #FFFFFF;
border-radius: 0px;
padding: 0px 16px;
position: relative;
}
.minPurchaseValue {
color: var(--text-price-color, rgba(0, 0, 0, 0.83));
margin-left: 2px;
}
.favIconRow {
display: flex;
align-items: center;
column-gap: 6px;
}
.isFirst {
border-top-left-radius: 8px;
border-top-right-radius: 8px;
}
.isLast {
border-bottom-left-radius: 8px;
border-bottom-right-radius: 8px;
}
.divPriceInfo {
display: flex;
flex-direction: column;
row-gap: 5px;
margin-left: auto;
}
.divPrice {
display = inline-flex;
justify-content = center;
}
.divCommissionValue {
display: inline-flex;
margin: 0px;
vertical-align: middle;
}
.pcbSpanCommissionValueSmall {
background: #036AC4;
height: 18px;
box-sizing: border-box;
display: flex;
line-height: 12px;
font-size: 14px;
color: #fff;
font-weight: 600;
float: left;
align-items: center;
padding: 0 1px;
margin: 0 -1px;
}
.pcbSpanCommissionValueLarge {
background: #036AC4;
height: 30px;
box-sizing: border-box;
display: flex;
line-height: 24px;
font-size: 24px;
color: #fff;
font-weight: 600;
float: left;
align-items: center;
}
.cashbackStr {
color: var(--text-price-color, rgba(0, 0, 0, 0.83));
}
.priceDiv {
display: inline-flex;
column-gap: 3px;
}
.txtPrice {
font-size: 16px;
line-height: 22px;
text-align: right;
color: var(--text-price-color, rgba(0, 0, 0, 0.83));
font-weight: 600;
}
.txtDescription {
display: -webkit-box;
-webkit-line-clamp: 1;
-webkit-box-orient: vertical;
overflow: hidden;
font-style: normal;
text-align: left;
color: var(--text-price-color, rgba(0, 0, 0, 0.83));
}
.txtDescriptionFirst {
font-weight: 600;
font-size: 16px;
line-height: 22px;
}
.txtDescriptionElse{
font-weight: 400;
font-size: 12px;
line-height: 16px;
}
.txtExpireTime {
font-size: 12px;
line-height: 16px;
text-align: right;
color: var(--text-red-savings-color, #DE3700);
font-weight: 400;
}
.txtCashbackFirst {
font-style: normal;
font-weight: 600;
font-size: 32px;
line-height: 40px;
color: #008A21;
}
.divTopAnnotation {
display: grid;
grid-template-columns: auto 1fr;
align-items: center;
}
.divAttribution {
display: grid;
grid-template-columns: auto minmax(0px, 1fr);
}
.divTextContent {
display: flex;
flex-direction: row;
margin-top: 9px;
min-width: 0;
align-item: center;
}
.divCashbackAmount{
font-size: 12px;
font-weight: 600;
line-height: 16px;
}
::slotted([slot="cashBack"]){
font-size: 12px;
line-height: 16px;
text-align: left;
align-self: center;
font-weight: 400;
color: var(--text-price-color, rgba(0, 0, 0, 0.83));
}
::slotted([slot="expireTime"]) {
font-size: 12px;
line-height: 16px;
text-align: right;
color: var(--text-price-color, rgba(0, 0, 0, 0.83));
font-weight: 400;
}
::slotted([slot="image"]) {
max-width: 66px;
max-height: 66px;
}
@media (prefers-color-scheme: dark) {
.txtPrice {
color: var(--text-price-color, #FFFFFF);
}
::slotted([slot="expireTime"]) {
color: var(--text-price-color, #FFFFFF);
}
::slotted([slot="cashBack"]){
color: var(--text-retailer-color, #FFFFFF);
}
.cashbackStr {
color: var(--text-price-color, #FFFFFF);
}
.txtDescription {
color: var(--text-price-color, #FFFFFF);
}
.aCashbackCardWrapperPane {
background-color: rgb(66, 66, 66);
}
}
`.withBehaviors(Gn(dn`
:host {
forced-color-adjust: auto;
}
:host .control:hover,
:host .control:${No} {
forced-color-adjust: none;
box-shadow: inset 0 0 0 calc((${qn.Han} * 1px)) ${Ns.ButtonText};
}
:host([href]),
:host([href]) .control {
color: ${Ns.LinkText};
border-color: ${Ns.LinkText};
}
:host([href]) .control:hover,
:host([href]) .control:${No} {
forced-color-adjust: none;
box-shadow: inset 0 0 0 calc((${qn.Han} * 1px)) ${Ns.LinkText};
}
::slotted([slot="image"]),
::slotted([slot="start"]),
::slotted([slot="end"]) {
color: ${Ns.ButtonText};
fill: currentcolor;
}
`)),Zs=Hs.compose({baseName:"cashback-card",shadowOptions:{delegatesFocus:!0},styles:$s,template:(e,t)=>$n`
<template>
<a
class="${e=>e.isPane?"aCashbackCardWrapperPane control":"aCashbackCardWrapper control"} ${e=>e.isFirst?"isFirst":""} ${e=>e.isLast?"isLast":""}"
part="control"
${vo("control")}
download="${e=>e.download}"
href="#"
hreflang="${e=>e.hreflang}"
ping="${e=>e.ping}"
referrerpolicy="${e=>e.referrerpolicy}"
rel="${e=>e.rel}"
target="${e=>e.target}"
type="${e=>e.type}"
aria-atomic="${e=>e.ariaAtomic}"
aria-busy="${e=>e.ariaBusy}"
aria-controls="${e=>e.ariaControls}"
aria-current="${e=>e.ariaCurrent}"
aria-describedBy="${e=>e.ariaDescribedby}"
aria-details="${e=>e.ariaDetails}"
aria-disabled="${e=>e.ariaDisabled}"
aria-errormessage="${e=>e.ariaErrormessage}"
aria-expanded="${e=>e.ariaExpanded}"
aria-flowto="${e=>e.ariaFlowto}"
aria-haspopup="${e=>e.ariaHaspopup}"
aria-hidden="${e=>e.ariaHidden}"
aria-invalid="${e=>e.ariaInvalid}"
aria-keyshortcuts="${e=>e.ariaKeyshortcuts}"
aria-label="${e=>e.ariaLabel}"
aria-labelledby="${e=>e.ariaLabelledby}"
aria-live="${e=>e.ariaLive}"
aria-owns="${e=>e.ariaOwns}"
aria-relevant="${e=>e.ariaRelevant}"
aria-roledescription="${e=>e.ariaRoledescription}">
<slot name="image"></slot>
<div class="divContent" part="divContent">
<div class="favIconRow">
<slot name="icon"></slot>
${Wr((e=>e.scope),$n`<span class="txtDescription ${e=>(e.isFirst,"txtDescriptionElse")}" title="${e=>e.scope}">${e=>e.scope}</span>`)}
</div>
<div class="divTextContent" part="divTextContent">
<div class="divTopAnnotation">
<msft-attribution class="divAttribution" part="divAttribution">
<div class="priceDiv">
<div class="divCommissionValue">
<div>
<svg width="4" height="18" viewBox="0 0 4 18" fill="none" aria-hidden="true" xmlns="http://www.w3.org/2000/svg">
<path d="M0 3C0 1.34315 1.34315 0 3 0H4V18H3C1.34315 18 0 16.6569 0 15V3Z" fill="#036AC4"/>
</svg>
</div>
<div class="pcbSpanCommissionValueSmall">
${e=>e.cashBackAmount}
</div>
<div aria-hidden="true">
<svg width="8" height="18" viewBox="0 0 8 18" fill="none" aria-hidden="true" xmlns="http://www.w3.org/2000/svg">
<path d="M2.73963 16.6933C2.18051 17.511 1.25378 18 0.263187 18H-1.19209e-07V0H0.263187C1.25378 0 2.18051 0.488995 2.73963 1.30671L6.84219 7.30671C7.54027 8.32765 7.54027 9.67235 6.84219 10.6933L2.73963 16.6933Z" fill="#036AC4"/>
</svg>
</div>
${Wr((e=>e.minPurchaseValue),$n`
<span class="minPurchaseValue">${e=>e.minPurchaseValue}</span>
`)}
</div>
<div class="cashbackStr">
${e=>e.cashbackStr}
</div>
</div>
</msft-attribution>
</div>
<div class="divPriceInfo" part="divPriceInfo">
${Wr((e=>e.expireTime),$n`
<span class="txtExpireTime" part="txtExpireTime">
${e=>e.expireTime}</span>`)}
<slot name="expireTime"></slot>
</div>
</div>
<slot name="end">
</div>
</a>
</template>
`});class Vs extends Zo{}(0,an.gn)([pn.Lj],Vs.prototype,"description",void 0);const Gs=dn`
${zn("grid")} :host {
--content-max-lines: 2;
outline: none;
font-family: ${qn.SVJ};
font-size: ${qn.sNp};
font-weight: 600;
line-height: ${qn.vgC};
min-width: calc(${Lo} * 1px);
border-radius: calc(${qn.rSr} * 1px);
box-sizing: border-box;
color: ${qn.CHi};
fill: currentcolor;
cursor: default;
position: relative;
}
.cardWrapper {
display: block;
height: min-content;
box-sizing: border-box;
width: 310px;
background-color: #fff;
position: absolute;
z-index: 10000;
outline: none;
padding: 16px;
border-radius: 8px;
box-shadow: 0 2px 16px rgba(0, 0, 0, 0.25);
}
.divContent {
display: flex;
flex-direction: row;
gap: 16px;
}
.imageWrapper {
width: 40px;
height: 40px;
display: flex;
align-items: center;
justify-content: center;
border-radius: 8px;
}
.textWrapper {
width: 220px;
height: min-content;
font-weight: 400;
font-size: 14px;
line-height: 20px;
display: flex;
flex-direction: column;
gap: 8px;
}
.hyperlinkWrapper {
cursor: pointer;
width: fit-content;
display: flex;
align-items: center;
gap: 4.5px;
}
::slotted([slot="image"]) {
pointer-events: none;
height: 40px;
width: 40px;
border-radius: 8px;
}
::slotted([slot="description"]) {
margin: 0;
}
::slotted([slot="hyperlink"]) {
text-decoration: none;
color: #036ac4;
height: 20px;
line-height: 20px;
}
@media (prefers-color-scheme: dark) {
.cardWrapper {
background-color: var(--fill-color);
}
.textWrapper {
color: #fff;
}
::slotted([slot="hyperlink"]) {
color: #63ade5;
}
#hyperlinkIcon {
fill: #fff;
}
}
`,js=Vs.compose({baseName:"cashback-header-card",shadowOptions:{delegatesFocus:!0},styles:Gs,template:(e,t)=>$n`
<template>
<div
class="cardWrapper"
part="control"
${vo("control")}
download="${e=>e.download}"
href="#"
hreflang="${e=>e.hreflang}"
ping="${e=>e.ping}"
referrerpolicy="${e=>e.referrerpolicy}"
rel="${e=>e.rel}"
target="${e=>e.target}"
type="${e=>e.type}"
aria-atomic="${e=>e.ariaAtomic}"
aria-busy="${e=>e.ariaBusy}"
aria-controls="${e=>e.ariaControls}"
aria-current="${e=>e.ariaCurrent}"
aria-describedBy="${e=>e.ariaDescribedby}"
aria-details="${e=>e.ariaDetails}"
aria-disabled="${e=>e.ariaDisabled}"
aria-errormessage="${e=>e.ariaErrormessage}"
aria-expanded="${e=>e.ariaExpanded}"
aria-flowto="${e=>e.ariaFlowto}"
aria-haspopup="${e=>e.ariaHaspopup}"
aria-hidden="${e=>e.ariaHidden}"
aria-invalid="${e=>e.ariaInvalid}"
aria-keyshortcuts="${e=>e.ariaKeyshortcuts}"
aria-label="${e=>e.ariaLabel}"
aria-labelledby="${e=>e.ariaLabelledby}"
aria-live="${e=>e.ariaLive}"
aria-owns="${e=>e.ariaOwns}"
aria-relevant="${e=>e.ariaRelevant}"
aria-roledescription="${e=>e.ariaRoledescription}">
<div class="divContent" part="divContent">
<div class="imageWrapper">
<slot name="image"></slot>
</div>
<div class="textWrapper">
<slot name="description"></slot>
<div class="hyperlinkWrapper">
<slot name="hyperlink"></slot>
<svg aria-hidden="true" width="9" height="9" viewBox="0 0 9 9" fill="none" xmlns="http://www.w3.org/2000/svg">
<path id="hyperlinkIcon" d="M4.25 4.375C4.25 4.27344 4.28711 4.18555 4.36133 4.11133L7.47266 1H5.375C5.27344 1 5.18555 0.962891 5.11133 0.888672C5.03711 0.814453 5 0.726562 5 0.625C5 0.523438 5.03711 0.435547 5.11133 0.361328C5.18555 0.287109 5.27344 0.25 5.375 0.25H8.375C8.47656 0.25 8.56445 0.285156 8.63867 0.355469C8.71289 0.425781 8.75 0.511719 8.75 0.613281V3.625C8.75 3.72656 8.71289 3.81445 8.63867 3.88867C8.56445 3.96289 8.47656 4 8.375 4C8.27344 4 8.18555 3.96289 8.11133 3.88867C8.03711 3.81445 8 3.72656 8 3.625V1.52734L4.88867 4.63867C4.81445 4.71289 4.72656 4.75 4.625 4.75C4.52344 4.75 4.43555 4.71289 4.36133 4.63867C4.28711 4.56445 4.25 4.47656 4.25 4.375ZM1.9707 8.5C1.77539 8.5 1.58984 8.46094 1.41406 8.38281C1.23828 8.30469 1.08203 8.19727 0.945312 8.06055C0.808594 7.92383 0.701172 7.76758 0.623047 7.5918C0.544922 7.41602 0.503906 7.22852 0.5 7.0293V2.4707C0.5 2.27539 0.539062 2.08984 0.617188 1.91406C0.695312 1.73828 0.802734 1.58203 0.939453 1.44531C1.07617 1.30859 1.23242 1.20117 1.4082 1.12305C1.58398 1.04492 1.77148 1.00391 1.9707 1H3.875C3.97656 1 4.06445 1.03711 4.13867 1.11133C4.21289 1.18555 4.25 1.27344 4.25 1.375C4.25 1.47656 4.21289 1.56445 4.13867 1.63867C4.06445 1.71289 3.97656 1.75 3.875 1.75H2C1.89453 1.75 1.79688 1.76953 1.70703 1.80859C1.61719 1.84766 1.53906 1.90039 1.47266 1.9668C1.40625 2.0332 1.35156 2.11328 1.30859 2.20703C1.26562 2.30078 1.24609 2.39844 1.25 2.5V7C1.25 7.10547 1.26953 7.20312 1.30859 7.29297C1.34766 7.38281 1.40039 7.46289 1.4668 7.5332C1.5332 7.60352 1.61133 7.65625 1.70117 7.69141C1.79102 7.72656 1.89062 7.74609 2 7.75H6.5C6.60547 7.75 6.70312 7.73047 6.79297 7.69141C6.88281 7.65234 6.96094 7.59961 7.02734 7.5332C7.09375 7.4668 7.14844 7.38672 7.19141 7.29297C7.23438 7.19922 7.25391 7.10156 7.25 7V5.125C7.25 5.02344 7.28711 4.93555 7.36133 4.86133C7.43555 4.78711 7.52344 4.75 7.625 4.75C7.72656 4.75 7.81445 4.78711 7.88867 4.86133C7.96289 4.93555 8 5.02344 8 5.125V7.0293C8 7.22461 7.96094 7.41016 7.88281 7.58594C7.80469 7.76172 7.69727 7.91797 7.56055 8.05469C7.42383 8.19141 7.26758 8.29883 7.0918 8.37695C6.91602 8.45508 6.72852 8.49609 6.5293 8.5H1.9707Z" fill="#717171"/>
</svg>
</div>
</div>
</div>
</div>
</template>
`});class zs extends Zo{}(0,an.gn)([pn.Lj],zs.prototype,"description",void 0),(0,an.gn)([pn.Lj],zs.prototype,"subtitle",void 0);const Ws=dn`
${zn("grid")} :host {
--content-max-lines: 2;
outline: none;
font-family: ${qn.SVJ};
font-size: ${qn.sNp};
font-weight: 600;
line-height: ${qn.vgC};
min-width: calc(${Lo} * 1px);
border-radius: calc(${qn.rSr} * 1px);
box-sizing: border-box;
color: ${qn.CHi};
fill: currentcolor;
cursor: pointer;
height: 100px;
position: relative;
}
:host {
display: block;
box-sizing: border-box;
}
.control:${No} {
box-shadow: 0 0 0 calc(${qn.vxp} * 1px) ${qn.yGg};
}
.wrapper {
display: block;
height: 100%;
width: 100%;
align-items: center;
gap: 15px;
box-sizing: border-box;
text-decoration: none;
outline: none;
border: none;
color: inherit;
fill: inherit;
border-radius: 8px;
position: relative;
cursor: default;
padding: 0;
}
.image {
height: 123px;
}
.divTextContent {
display: flex;
flex-direction: column;
row-gap: 0px;
padding: 5px;
min-width: 0;
padding: 0;
}
.description {
display: -webkit-box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
font-weight: 600;
font-size: 20px;
line-height: 26px;
text-align: center;
margin: 0;
}
.subtitle {
font-size: 14px;
line-height: 18px;
text-align: center;
color: #616161;
font-weight: 400;
padding-top: 4px;
}
@media (prefers-color-scheme: dark) {
.subtitle {
color: #ADADAD;
}
}
`.withBehaviors(Gn(dn`
:host {
forced-color-adjust: auto;
}
:host .control:hover,
:host .control:${No} {
forced-color-adjust: none;
box-shadow: inset 0 0 0 calc((${qn.Han} * 1px)) ${Ns.ButtonText};
}
:host([href]),
:host([href]) .control {
color: ${Ns.LinkText};
border-color: ${Ns.LinkText};
}
:host([href]) .control:hover,
:host([href]) .control:${No} {
forced-color-adjust: none;
box-shadow: inset 0 0 0 calc((${qn.Han} * 1px)) ${Ns.LinkText};
}
::slotted([slot="image"]),
::slotted([slot="start"]),
::slotted([slot="end"]) {
color: ${Ns.ButtonText};
fill: currentcolor;
}
`)),Ks=zs.compose({baseName:"consent-card",shadowOptions:{delegatesFocus:!0},styles:Ws,template:(e,t)=>$n`
<template>
<a
class="wrapper control"
part="control"
${vo("control")}
download="${e=>e.download}"
href="#"
hreflang="${e=>e.hreflang}"
ping="${e=>e.ping}"
referrerpolicy="${e=>e.referrerpolicy}"
rel="${e=>e.rel}"
target="${e=>e.target}"
type="${e=>e.type}"
aria-atomic="${e=>e.ariaAtomic}"
aria-busy="${e=>e.ariaBusy}"
aria-controls="${e=>e.ariaControls}"
aria-current="${e=>e.ariaCurrent}"
aria-describedBy="${e=>e.ariaDescribedby}"
aria-details="${e=>e.ariaDetails}"
aria-disabled="${e=>e.ariaDisabled}"
aria-errormessage="${e=>e.ariaErrormessage}"
aria-expanded="${e=>e.ariaExpanded}"
aria-flowto="${e=>e.ariaFlowto}"
aria-haspopup="${e=>e.ariaHaspopup}"
aria-hidden="${e=>e.ariaHidden}"
aria-invalid="${e=>e.ariaInvalid}"
aria-keyshortcuts="${e=>e.ariaKeyshortcuts}"
aria-label="${e=>e.ariaLabel}"
aria-labelledby="${e=>e.ariaLabelledby}"
aria-live="${e=>e.ariaLive}"
aria-owns="${e=>e.ariaOwns}"
aria-relevant="${e=>e.ariaRelevant}"
aria-roledescription="${e=>e.ariaRoledescription}">
<slot class="image" name="image"></slot>
<div class="divTextContent" part="divTextContent">
<span class="description" title="${e=>e.description}">${e=>e.description}</span>
<span class="subtitle" title="${e=>e.subtitle}">${e=>e.subtitle}</span>
<slot name="end">
</div>
</a>
</template>
`});class qs extends zi{handleFooterContentChange(){this.footerContainer.classList.toggle("footer",this.footer.assignedNodes().length>0)}handleActionsContentChange(){this.actionsContainer.classList.toggle("actions",this.actions.assignedNodes().length>0)}handleHeaderIconContentChange(){this.headerIconContainer.classList.toggle("header-icon",this.headerIcon.assignedNodes().length>0)}handleStartContentChange(){this.startContentContainer.classList.toggle("start-content",this.startContent.assignedNodes().length>0)}}(0,an.gn)([(0,pn.Lj)({attribute:"fixed-title"})],qs.prototype,"fixedTitle",void 0),(0,an.gn)([(0,pn.Lj)({mode:"fromView"})],qs.prototype,"title",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"sub-title",mode:"fromView"})],qs.prototype,"subTitle",void 0),(0,an.gn)([oi.LO],qs.prototype,"footerSlottedNodes",void 0),(0,an.gn)([oi.LO],qs.prototype,"actionsSlottedNodes",void 0),(0,an.gn)([oi.LO],qs.prototype,"startContentSlottedNodes",void 0);const Ys=qs.compose({baseName:"edge-shopping",styles:(e,t)=>dn`
${zn("flex")} :host {
--side-padding: 12px;
flex-direction: column;
height: 100%;
font-size: ${qn.cSu};
line-height: ${qn.RUt};
}
.content {
overflow: hidden;
overflow-y: auto;
}
.header-fixed {
display: flex;
justify-content: space-between;
align-items: center;
height: 40px;
}
.header-title-wrapper {
display: flex;
align-items: center;
margin-inline-start: 8px;
}
.header-icon {
display: flex;
margin-inline-start: 4px;
}
.header-fixed-title {
display: inline-block;
font-weight: 600;
margin-inline-start: 8px;
font-size: ${qn.cSu};
line-height: ${qn.RUt};
}
.header-actions {
margin: 6px;
margin-top: 0px;
margin-bottom: 0px;
}
.illustration-container {
display: flex;
justify-content: center;
}
.header {
text-align: center;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
}
.header-title,
.header-sub-title {
display: inline;
}
.header-title {
margin: 16px 16px 8px;
font-size: ${qn.b3W};
line-height: ${qn.I7_};
}
.header-sub-title {
margin: 0 32px 8px 32px;
font-weight: 600;
font-size: ${qn.cSu};
line-height: ${qn.RUt};
}
.sections {
padding: 0 var(--side-padding);
}
.footer,
.actions {
display: flex;
align-items: center;
justify-content: center;
}
.footer {
padding: 10px 12px;
border-top: calc(${qn.Han} * 1px) solid ${qn.dtw};
}
::slotted([slot="feedback"]) {
display: flex;
align-items: center;
padding: 10px 12px;
border-top: calc(${qn.Han} * 1px) solid ${qn.dtw};
}
.actions {
display: flex;
flex-direction: column;
width: calc(100% - 24px);
padding: 10px 12px 13px;
border-bottom: calc(${qn.Han} * 1px) solid ${qn.dtw};
}
.footer__hidden,
.actions__hidden {
display: none;
}
.start-content {
display: flex;
align-items: center;
justify-content: center;
padding: 10px 12px;
}
.start-content__hidden {
display: none;
}
`,template:(e,t)=>$n`
<template>
<header class="header-fixed" part="header-fixed">
<div class="header-title-wrapper">
<span part="header-icon" aria-hidden="true" ${vo("headerIconContainer")}>
<slot
name="header-icon"
${vo("headerIcon")}
@slotchange=${e=>e.handleHeaderIconContentChange()}
></slot>
</span>
<h1 class="header-fixed-title" part="header-fixed-title">
${e=>e.fixedTitle}
</h1>
</div>
<div class="header-actions" part="header-actions">
<slot name="header-actions"></slot>
</div>
</header>
<div class="content" part="content">
<div
class="${e=>e.startContentSlottedNodes&&e.startContentSlottedNodes.length?"start-content":"start-content__hidden"}"
part="start-content"
${vo("startContentContainer")}
>
<slot
name="start-content"
${vo("startContent")}
${Ao("startContentSlottedNodes")}
@slotchange="${e=>e.handleStartContentChange()}"
></slot>
</div>
<div class="header" part="header">
<slot name="header-content" part="header-content">
${Wr((e=>e.title),$n`
<h2 class="header-title" part="header-title">
${e=>e.title}
</h2>
`)}
${Wr((e=>e.subTitle),$n`
<p class="header-sub-title" part="header-sub-title">
${e=>e.subTitle}
</p>
`)}
</slot>
<div
class="${e=>e.actionsSlottedNodes&&e.actionsSlottedNodes.length?"actions":"actions__hidden"}"
part="actions"
${vo("actionsContainer")}
>
<slot
name="actions"
${vo("actions")}
${Ao("actionsSlottedNodes")}
@slotchange="${e=>e.handleActionsContentChange()}"
></slot>
</div>
</div>
<div class="sections" part="sections">
<slot></slot>
</div>
<footer
class="${e=>e.footerSlottedNodes&&e.footerSlottedNodes.length?"footer":"footer__hidden"}"
aria-hidden="${e=>e.footerSlottedNodes&&e.footerSlottedNodes.length?"false":"true"}"
part="footer"
${vo("footerContainer")}
>
<slot
name="footer"
${vo("footer")}
${Ao("footerSlottedNodes")}
@slotchange="${e=>e.handleFooterContentChange()}"
></slot>
</footer>
<slot name="feedback"></slot>
</div>
</template>
`});class Xs extends zi{constructor(){super(...arguments),this.accordion=!1,this.hideTitle=!1,this.isPane=!1,this.isBlock=!1,this.hasPadding=!1,this.hasTransparentBackground=!1,this.hasSectionEndContent=!1,this.isSingleScroll=!1,this.truncateOverflowedHeader=!1,this.isAiHeading=!1,this.isShadow=!1,this.seeMoreSeparate=!1,this.isHeader=!1,this.headerBlock=!1,this.titleLevel=2,this.isCjk=!1,this.isCjkNotification=!1}connectedCallback(){super.connectedCallback(),null!==this.expanded&&void 0!==this.expanded||(this.expanded=!0)}}(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Xs.prototype,"accordion",void 0),(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Xs.prototype,"expanded",void 0),(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Xs.prototype,"hideTitle",void 0),(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Xs.prototype,"isPane",void 0),(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Xs.prototype,"isBlock",void 0),(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Xs.prototype,"hasPadding",void 0),(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Xs.prototype,"hasTransparentBackground",void 0),(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Xs.prototype,"hasSectionEndContent",void 0),(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Xs.prototype,"isSingleScroll",void 0),(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Xs.prototype,"truncateOverflowedHeader",void 0),(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Xs.prototype,"isAiHeading",void 0),(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Xs.prototype,"isShadow",void 0),(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Xs.prototype,"seeMoreSeparate",void 0),(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Xs.prototype,"isHeader",void 0),(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Xs.prototype,"headerBlock",void 0),(0,an.gn)([pn.Lj],Xs.prototype,"titleText",void 0),(0,an.gn)([pn.Lj],Xs.prototype,"titleIcon",void 0),(0,an.gn)([pn.Lj],Xs.prototype,"aiSummryIndicator",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"title-level",converter:pn.Id,mode:"fromView"})],Xs.prototype,"titleLevel",void 0),(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Xs.prototype,"isCjk",void 0),(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Xs.prototype,"isCjkNotification",void 0),(0,an.gn)([pn.Lj],Xs.prototype,"countNumber",void 0),(0,an.gn)([pn.Lj],Xs.prototype,"cjkSectionNumberIcon",void 0),(0,an.gn)([oi.LO],Xs.prototype,"childElements",void 0);class Js extends Oo{constructor(e,t){super(e,t),this.observer=null,t.childList=!0}observe(){null===this.observer&&(this.observer=new MutationObserver(this.handleEvent.bind(this))),this.observer.observe(this.target,this.options)}disconnect(){this.observer.disconnect()}getNodes(){return"subtree"in this.options?Array.from(this.target.querySelectorAll(this.options.selector)):Array.from(this.target.childNodes)}}function Qs(e){return"string"==typeof e&&(e={property:e}),new vn("fast-children",Js,e)}function el(e,t){return t&&t.some((t=>t.slot===e))}const tl=Xs.compose({baseName:"edge-shopping-section",styles:(e,t)=>dn`
:host {
overflow: hidden;
}
.action {
color: ${qn.Avx};
font-size: ${qn.sNp};
min-height: 38px;
height: auto;
display: flex;
margin-inline-start: 16px;
align-items: center;
}
.seeMoreSeparateRegion {
background-color: var(--fill-color);
box-sizing: border-box;
border-radius: 8px;
margin-bottom: 12px;
}
.cjk-region-single-pane {
border-radius: 8px;
background-color: white;
margin-bottom: 12px!important;
padding-bottom: 12px!important;
}
.cjk-region {
border-radius: 8px;
background-color: white;
}
.cjk-region-top {
border-radius: 8px;
background-color: white;
margin-bottom: 12px;
}
.cjk-title {
display: flex;
direction: row;
column-gap: 8px;
}
.cjk-title-number {
display: flex;
align-items: center;
justify-content: center;
width: 20px;
color: #2169EB;
text-align: justify;
font-family: "Segoe UI Variable", "Roboto", Helvetica, Verdana, sans-serif;
font-style: normal;
font-weight: 400;
font-size: 12px;
line-height: 16px;
}
@media (prefers-color-scheme: dark) {
.seeMoreSeparateRegion {
background-color: #424242;
}
.cjk-region,
.cjk-region-top,
.cjk-region-single-pane {
background-color: var(--fill-color);
}
}
`.withBehaviors(Gn(dn`
fluent-accordion-item {
color: ${Ns.ButtonText};
}
`)),template:(e,t)=>$n`
<template ${Qs({property:"childElements",filter:wo()})}>
<style>
fluent-accordion-item::part(region) {
position: relative;
}
</style>
${Wr((e=>e.isPane),$n`<style>
fluent-accordion-item::part(icon) {
background-color: unset;
}
fluent-accordion-item::part(region) {
padding: 0px;
background-color: unset;
border: none;
}
fluent-accordion-item {
background-color: unset;
border: none;
}
</style>`)}
${Wr((e=>e.hasTransparentBackground),$n`<style>
fluent-accordion-item::part(region) {
background-color: unset!important;
}
</style>`)}
${Wr((e=>e.accordion&&!e.isSingleScroll),$n`
<fluent-accordion part="control">
${Wr((e=>e.hideTitle),$n`<style>
fluent-accordion-item::part(heading) {
display: none!important;
}
</style>`)}
${Wr((e=>e.isBlock),$n`<style>
fluent-accordion-item::part(region) {
margin: 0 20px 20px 20px;
background-color: var(--fill-color);
box-sizing: border-box;
border-radius: 8px;
}
fluent-accordion-item::part(action) {
margin-inline-start: 0px;
height: auto;
}
@media (prefers-color-scheme: dark) {
fluent-accordion-item::part(region) {
background-color: #424242;
}
}
</style>`)}
${Wr((e=>e.hasPadding),$n`<style>
fluent-accordion-item::part(region) {
padding: 10px!important;
}
</style>`)}
${Wr((e=>e.titleIcon),$n`<style>
.headerIcon img {
max-width: 100%;
max-height: 100%;
display: inline-block;
}
.headerIcon {
height: 24px;
width: 24px;
display: inline-block; /* Make the span a block container */
overflow: hidden; /* Hide any content that overflows */
padding-inline-start: 8px;
text-align: center;
}
.headerAiSummaryText {
color: var(--neutral-foreground-hint);
font-size: 0.65em;
font-weight: 400;
}
.headerIconContainer {
display: flex;
align-items: center;
justify-content: space-between;
}
.headerTextIcon {
display: flex;
}
</style>`)}
<fluent-accordion-item
part="item"
class="item ${e=>e.seeMoreSeparate&&e.isHeader?"seeMoreSeparateRegion":""} ${e=>e.isCjk?"cjk-region":""}"
expanded="${e=>e.expanded?"true":"false"}"
heading-level="${e=>e.titleLevel}"
>
<svg
class="icon"
part="expanded-icon"
slot="expanded-icon"
width="12"
height="12"
viewBox="0 0 12 12"
xmlns="http://www.w3.org/2000/svg"
>
<path
fill="currentcolor"
d="M11.4551 8.98242L6 3.5332L0.544922 8.98242L0.0175781 8.45508L6 2.4668L11.9824 8.45508L11.4551 8.98242Z"
/>
</svg>
<svg
class="icon"
part="collapsed-icon"
slot="collapsed-icon"
width="12"
height="12"
viewBox="0 0 12 12"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path
fill="currentcolor"
d="M11.3613 2.73633L11.8887 3.26367L6 9.15234L0.111328 3.26367L0.638672 2.73633L6 8.09766L11.3613 2.73633Z"
fill="black"
/>
</svg>
${Wr((e=>!e.titleIcon&&!e.isCjkNotification),$n`<span part="title" slot="heading">${e=>e.titleText}</span>`)}
${Wr((e=>!e.titleIcon&&e.isCjkNotification),$n`
<span part="title" slot="heading" class="cjk-title">${e=>e.titleText}
${Wr((e=>e.countNumber>0),$n`<span class="cjk-title-number" style="background-image: url(${e=>e.cjkSectionNumberIcon})">
${e=>e.countNumber}
</span>`)}
</span>
`)}
${Wr((e=>e.titleIcon&&!e.aiSummryIndicator),$n`
<span part="title" class="headerIconContainer" slot="heading">
<span class="headerTextIcon">
<span>${e=>e.titleText}</span>
<span class="headerIcon">
<img src="${e=>e.titleIcon}"></img>
</span>
</span>
</span>
`)}
${Wr((e=>e.titleIcon&&e.aiSummryIndicator),$n`
<span part="title" class="headerIconContainer" slot="heading">
<span class="headerTextIcon">
<span>${e=>e.titleText}</span>
<span class="headerIcon">
<img src="${e=>e.titleIcon}"></img>
</span>
</span>
<span class="headerAiSummaryText">${e=>e.aiSummryIndicator}</span>
</span>
`)}
<slot></slot>
${Wr((e=>el("action",e.childElements)&&!e.seeMoreSeparate),$n`
<div class="action" part="action">
<slot name="action"></slot>
</div>
`)}
<style>
fluent-accordion-item::part(button) {
padding: ${e=>e.isAiHeading?"0px 4px 0px calc(var(--design-unit) * 5 * 1px)":"0 calc(var(--design-unit) * 5 * 1px)"};
margin: calc(var(--design-unit) * 3 * 1px) 0;
display: block;
border: 1px solid #000000 rgba(255, 0, 0, .04);
box-sizing: border-box;
}
fluent-accordion-item::part(icon) {
margin-right: calc(var(--design-unit) * 5 * 1px);
}
</style>
</fluent-accordion-item>
${Wr((e=>el("action",e.childElements)&&e.seeMoreSeparate),$n`
<div class="action" part="action">
<slot name="action"></slot>
</div>
`)}
${Wr((e=>e.hasSectionEndContent),$n`
<style>
fluent-accordion-item[expanded] ~ .section-end-content {
display: block;
}
.section-end-content {
display: none;
text-align: left;
padding: 0 ${e=>e.isHeader?"":"calc(var(--design-unit) * 5 * 1px)"};
}
</style>
<div class="section-end-content" part="section-end-content">
<slot name="section-end-content"></slot>
</div>
`)}
</fluent-accordion>
`)}
${Wr((e=>!e.accordion&&!e.isSingleScroll),$n`
<style>
.heading {
padding: 0 calc(var(--design-unit) * 5 * 1px);
margin: 0px;
display: flex;
height: 50px;
box-sizing: border-box;
align-items: center;
white-space: pre;
}
.headerContainer {
display: flex;
}
.headerIcon {
position: relative;
}
.headerIcon img {
padding-top: 2px;
position: absolute;
top: 0;
bottom: 0;
left: 0;
right: 0;
margin: auto;
height: 30px;
width: 30px;
}
</style>
<div class="control" part="control">
<div class="headerContainer">
${Wr((e=>!e.hideTitle),$n`<span
class="heading"
part="title"
slot="heading"
role="heading"
style="${e=>e.titleIcon?"padding-right: 3px!important":""}"
aria-level="${e=>e.titleLevel}"
title="${e=>e.truncateOverflowedHeader?e.titleText:""}"
>${e=>e.titleText}</span>`)}
${Wr((e=>e.titleIcon),$n`<div class="headerIcon"><img src="${e=>e.titleIcon}">
</img></div>`)}
</div>
<slot></slot>
${Wr((e=>el("action",e.childElements)),$n`
<div class="action" part="action">
<slot name="action"></slot>
</div>
`)}
</div>
`)}
${Wr((e=>e.isSingleScroll),$n`
<style>
.heading {
padding: 0 calc(var(--design-unit) * 5 * 1px);
margin: 0px;
display: flex;
height: 50px;
box-sizing: border-box;
align-items: center;
white-space: pre;
}
.headerContainer {
display: flex;
}
.headerIcon {
position: relative;
}
.headerIcon img {
padding-top: 2px;
position: absolute;
top: 0;
bottom: 0;
left: 0;
right: 0;
margin: auto;
height: 30px;
width: 30px;
}
.region {
position: relative;
}
</style>
${Wr((e=>e.isBlock),$n`<style>
.region {
margin: 0 20px 20px 20px;
background-color: var(--fill-color);
box-sizing: border-box;
border-radius: 8px;
}
.action {
margin-inline-start: 0px;
height: auto;
}
@media (prefers-color-scheme: dark) {
.region {
background-color: #424242;
}
}
</style>`)}
${Wr((e=>e.hasPadding),$n`<style>
.region {
padding: 10px!important;
}
</style>`)}
<div class="control ${e=>e.isCjk?"cjk-region-single-pane":""}" part="control">
<div class="headerContainer">
${Wr((e=>!e.hideTitle),$n`<span
class="heading"
part="title"
slot="heading"
role="heading"
style="${e=>e.titleIcon?"padding-right: 3px!important":""}"
aria-level="${e=>e.titleLevel}"
title="${e=>e.truncateOverflowedHeader?e.titleText:""}"
>${e=>e.titleText}</span>`)}
${Wr((e=>e.titleIcon),$n`<div class="headerIcon"><img src="${e=>e.titleIcon}">
</img></div>`)}
</div>
<div class="region">
<slot></slot>
</div>
${Wr((e=>el("action",e.childElements)),$n`
<div class="action" part="action">
<slot name="action"></slot>
</div>
`)}
</div>
`)}
${Wr((e=>e.expanded&&e.isShadow),$n`
<style>
fluent-accordion-item::part(region) {
box-shadow: 0 0 2px rgba(0,0,0,0.12), 0 2px 4px rgba(0,0,0,0.14) !important;
}
</style>
`)}
${Wr((e=>e.truncateOverflowedHeader),$n`
<style>
.headerContainer {
align-items: center;
height: 50px;
}
.heading {
display: block;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
height: unset;
}
</style>
`)}
</template>
`});class il extends zi{constructor(){super(...arguments),this.infiniteProductFeedsData=[],this.paginationThreshold=2e3,this.intersectionObserverCallback=e=>{!e||e.length<1||e.find((e=>e.isIntersecting))&&this.paginate()}}disconnectedCallback(){super.disconnectedCallback(),this.intersectionObserver&&this.intersectionObserver.disconnect()}infiniteProductFeedsDataChanged(e,t){t&&0!==t.length||(this.infiniteProductFeedsData=[{}])}setupPagination(e,t){this.getNextFeed=e,this.requestParamsList=t,this.intersectionObserver=new IntersectionObserver(this.intersectionObserverCallback,{}),this.intersectionObserver.observe(this.feedBottom)}paginate(){return(0,an.mG)(this,void 0,void 0,(function*(){this.getNextFeed&&this.requestParamsList&&this.requestParamsList.length>0&&(this.infiniteProductFeedsData.push({dataFetchOnVisibleCallback:this.getNextFeed.bind(this,this.requestParamsList.shift())}),requestAnimationFrame((()=>{this.feedBottom.getBoundingClientRect().top<this.paginationThreshold&&this.paginate()})))}))}}(0,an.gn)([oi.LO],il.prototype,"infiniteProductFeedsData",void 0),(0,an.gn)([oi.LO],il.prototype,"navigateToTitleDestination",void 0),(0,an.gn)([oi.LO],il.prototype,"navigateToDestination",void 0),(0,an.gn)([oi.LO],il.prototype,"navigateToAdSlugDestination",void 0),(0,an.gn)([oi.LO],il.prototype,"handleClickPingUrl",void 0),(0,an.gn)([oi.LO],il.prototype,"logShowMoreButtonClicked",void 0),(0,an.gn)([oi.LO],il.prototype,"navigateToAdDestination",void 0),(0,an.gn)([oi.LO],il.prototype,"logShowMoreAdButtonClicked",void 0),(0,an.gn)([pn.Lj],il.prototype,"productsToShow",void 0),(0,an.gn)([pn.Lj],il.prototype,"showMoreButtonText",void 0),(0,an.gn)([pn.Lj],il.prototype,"seeAllButtonText",void 0),(0,an.gn)([pn.Lj],il.prototype,"adSlugText",void 0),(0,an.gn)([pn.Lj],il.prototype,"adSlugPolicyText",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"include-separator",mode:"boolean"})],il.prototype,"includeSeparator",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"use-clickable-titles",mode:"boolean"})],il.prototype,"useClickableTitles",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"use-show-more-clickout",mode:"boolean"})],il.prototype,"useShowMoreClickout",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"use-two-click-show-more-clickout",mode:"boolean"})],il.prototype,"useTwoClickShowMoreClickout",void 0);const nl=dn`
.feed-bottom {
height: 1000px;
width: 100%;
position: absolute;
left: 0px;
right: 0px;
bottom: 0px;
visibility: hidden;
}
`;function ol(e,t,i){return{index:e,removed:t,addedCount:i}}const rl=0,al=1,sl=2,ll=3;function cl(e,t,i,n,o,r){let a=0,s=0;const l=Math.min(i-t,r-o);if(0===t&&0===o&&(a=function(e,t,i){for(let n=0;n<i;++n)if(e[n]!==t[n])return n;return i}(e,n,l)),i===e.length&&r===n.length&&(s=function(e,t,i){let n=e.length,o=t.length,r=0;for(;r<i&&e[--n]===t[--o];)r++;return r}(e,n,l-a)),o+=a,r-=s,(i-=s)-(t+=a)==0&&r-o==0)return ai.ow;if(t===i){const e=ol(t,[],0);for(;o<r;)e.removed.push(n[o++]);return[e]}if(o===r)return[ol(t,[],i-t)];const c=function(e){let t=e.length-1,i=e[0].length-1,n=e[t][i];const o=[];for(;t>0||i>0;){if(0===t){o.push(sl),i--;continue}if(0===i){o.push(ll),t--;continue}const r=e[t-1][i-1],a=e[t-1][i],s=e[t][i-1];let l;l=a<s?a<r?a:r:s<r?s:r,l===r?(r===n?o.push(rl):(o.push(al),n=r),t--,i--):l===a?(o.push(ll),t--,n=a):(o.push(sl),i--,n=s)}return o.reverse(),o}(function(e,t,i,n,o,r){const a=r-o+1,s=i-t+1,l=new Array(a);let c,d;for(let e=0;e<a;++e)l[e]=new Array(s),l[e][0]=e;for(let e=0;e<s;++e)l[0][e]=e;for(let i=1;i<a;++i)for(let r=1;r<s;++r)e[t+r-1]===n[o+i-1]?l[i][r]=l[i-1][r-1]:(c=l[i-1][r]+1,d=l[i][r-1]+1,l[i][r]=c<d?c:d);return l}(e,t,i,n,o,r)),d=[];let u,h=t,p=o;for(let e=0;e<c.length;++e)switch(c[e]){case rl:void 0!==u&&(d.push(u),u=void 0),h++,p++;break;case al:void 0===u&&(u=ol(h,[],0)),u.addedCount++,h++,u.removed.push(n[p]),p++;break;case sl:void 0===u&&(u=ol(h,[],0)),u.addedCount++,h++;break;case ll:void 0===u&&(u=ol(h,[],0)),u.removed.push(n[p]),p++}return void 0!==u&&d.push(u),d}const dl=Array.prototype.push;function ul(e,t,i,n){const o=ol(t,i,n);let r=!1,a=0;for(let t=0;t<e.length;t++){const i=e[t];if(i.index+=a,r)continue;const n=(s=o.index,l=o.index+o.removed.length,c=i.index,d=i.index+i.addedCount,l<c||d<s?-1:l===c||d===s?0:s<c?l<d?l-c:d-c:d<l?d-s:l-s);if(n>=0){e.splice(t,1),t--,a-=i.addedCount-i.removed.length,o.addedCount+=i.addedCount-n;const s=o.removed.length+i.removed.length-n;if(o.addedCount||s){let e=i.removed;if(o.index<i.index){const t=o.removed.slice(0,i.index-o.index);dl.apply(t,e),e=t}if(o.index+o.removed.length>i.index+i.addedCount){const t=o.removed.slice(i.index+i.addedCount-o.index);dl.apply(e,t)}o.removed=e,i.index<o.index&&(o.index=i.index)}else r=!0}else if(o.index<i.index){r=!0,e.splice(t,0,o),t++;const n=o.addedCount-o.removed.length;i.index+=n,a+=n}}var s,l,c,d;r||e.push(o)}var hl=o(55208);let pl=!1;function gl(e,t){let i=e.index;const n=t.length;return i>n?i=n-e.addedCount:i<0&&(i=n+e.removed.length+i-e.addedCount),i<0&&(i=0),e.index=i,e}class fl extends hl.q{constructor(e){super(e),this.oldCollection=void 0,this.splices=void 0,this.needsQueue=!0,this.call=this.flush,Reflect.defineProperty(e,"$fastController",{value:this,enumerable:!1})}subscribe(e){this.flush(),super.subscribe(e)}addSplice(e){void 0===this.splices?this.splices=[e]:this.splices.push(e),this.needsQueue&&(this.needsQueue=!1,gn.SO.queueUpdate(this))}reset(e){this.oldCollection=e,this.needsQueue&&(this.needsQueue=!1,gn.SO.queueUpdate(this))}flush(){const e=this.splices,t=this.oldCollection;if(void 0===e&&void 0===t)return;this.needsQueue=!0,this.splices=void 0,this.oldCollection=void 0;const i=void 0===t?function(e,t){let i=[];const n=function(e){const t=[];for(let i=0,n=e.length;i<n;i++){const n=e[i];ul(t,n.index,n.removed,n.addedCount)}return t}(t);for(let t=0,o=n.length;t<o;++t){const o=n[t];1!==o.addedCount||1!==o.removed.length?i=i.concat(cl(e,o.index,o.index+o.addedCount,o.removed,0,o.removed.length)):o.removed[0]!==e[o.index]&&i.push(o)}return i}(this.source,e):cl(this.source,0,this.source.length,t,0,t.length);this.notify(i)}}const ml=Object.freeze({positioning:!1,recycle:!0});function vl(e,t,i,n){e.bind(t[i],n)}function yl(e,t,i,n){const o=Object.create(n);o.index=i,o.length=t.length,e.bind(t[i],o)}class Cl{constructor(e,t,i,n,o,r){this.location=e,this.itemsBinding=t,this.templateBinding=n,this.options=r,this.source=null,this.views=[],this.items=null,this.itemsObserver=null,this.originalContext=void 0,this.childContext=void 0,this.bindView=vl,this.itemsBindingObserver=oi.y$.binding(t,this,i),this.templateBindingObserver=oi.y$.binding(n,this,o),r.positioning&&(this.bindView=yl)}bind(e,t){this.source=e,this.originalContext=t,this.childContext=Object.create(t),this.childContext.parent=e,this.childContext.parentContext=this.originalContext,this.items=this.itemsBindingObserver.observe(e,this.originalContext),this.template=this.templateBindingObserver.observe(e,this.originalContext),this.observeItems(!0),this.refreshAllViews()}unbind(){this.source=null,this.items=null,null!==this.itemsObserver&&this.itemsObserver.unsubscribe(this),this.unbindAllViews(),this.itemsBindingObserver.disconnect(),this.templateBindingObserver.disconnect()}handleChange(e,t){e===this.itemsBinding?(this.items=this.itemsBindingObserver.observe(this.source,this.originalContext),this.observeItems(),this.refreshAllViews()):e===this.templateBinding?(this.template=this.templateBindingObserver.observe(this.source,this.originalContext),this.refreshAllViews(!0)):this.updateViews(t)}observeItems(e=!1){if(!this.items)return void(this.items=ai.ow);const t=this.itemsObserver,i=this.itemsObserver=oi.y$.getNotifier(this.items),n=t!==i;n&&null!==t&&t.unsubscribe(this),(n||e)&&i.subscribe(this)}updateViews(e){const t=this.childContext,i=this.views,n=this.bindView,o=this.items,r=this.template,a=this.options.recycle,s=[];let l=0,c=0;for(let d=0,u=e.length;d<u;++d){const u=e[d],h=u.removed;let p=0,g=u.index;const f=g+u.addedCount,m=i.splice(u.index,h.length),v=c=s.length+m.length;for(;g<f;++g){const e=i[g],d=e?e.firstChild:this.location;let u;a&&c>0?(p<=v&&m.length>0?(u=m[p],p++):(u=s[l],l++),c--):u=r.create(),i.splice(g,0,u),n(u,o,g,t),u.insertBefore(d)}m[p]&&s.push(...m.slice(p))}for(let e=l,t=s.length;e<t;++e)s[e].dispose();if(this.options.positioning)for(let e=0,t=i.length;e<t;++e){const n=i[e].context;n.length=t,n.index=e}}refreshAllViews(e=!1){const t=this.items,i=this.childContext,n=this.template,o=this.location,r=this.bindView;let a=t.length,s=this.views,l=s.length;if(0!==a&&!e&&this.options.recycle||(Fn.disposeContiguousBatch(s),l=0),0===l){this.views=s=new Array(a);for(let e=0;e<a;++e){const a=n.create();r(a,t,e,i),s[e]=a,a.insertBefore(o)}}else{let e=0;for(;e<a;++e)if(e<l)r(s[e],t,e,i);else{const a=n.create();r(a,t,e,i),s.push(a),a.insertBefore(o)}const c=s.splice(e,l-e);for(e=0,a=c.length;e<a;++e)c[e].dispose()}}unbindAllViews(){const e=this.views;for(let t=0,i=e.length;t<i;++t)e[t].unbind()}}class bl extends fn{constructor(e,t,i){super(),this.itemsBinding=e,this.templateBinding=t,this.options=i,this.createPlaceholder=gn.SO.createBlockPlaceholder,function(){if(pl)return;pl=!0,oi.y$.setArrayObserverFactory((e=>new fl(e)));const e=Array.prototype;if(e.$fastPatch)return;Reflect.defineProperty(e,"$fastPatch",{value:1,enumerable:!1});const t=e.pop,i=e.push,n=e.reverse,o=e.shift,r=e.sort,a=e.splice,s=e.unshift;e.pop=function(){const e=this.length>0,i=t.apply(this,arguments),n=this.$fastController;return void 0!==n&&e&&n.addSplice(ol(this.length,[i],0)),i},e.push=function(){const e=i.apply(this,arguments),t=this.$fastController;return void 0!==t&&t.addSplice(gl(ol(this.length-arguments.length,[],arguments.length),this)),e},e.reverse=function(){let e;const t=this.$fastController;void 0!==t&&(t.flush(),e=this.slice());const i=n.apply(this,arguments);return void 0!==t&&t.reset(e),i},e.shift=function(){const e=this.length>0,t=o.apply(this,arguments),i=this.$fastController;return void 0!==i&&e&&i.addSplice(ol(0,[t],0)),t},e.sort=function(){let e;const t=this.$fastController;void 0!==t&&(t.flush(),e=this.slice());const i=r.apply(this,arguments);return void 0!==t&&t.reset(e),i},e.splice=function(){const e=a.apply(this,arguments),t=this.$fastController;return void 0!==t&&t.addSplice(gl(ol(+arguments[0],e,arguments.length>2?arguments.length-2:0),this)),e},e.unshift=function(){const e=s.apply(this,arguments),t=this.$fastController;return void 0!==t&&t.addSplice(gl(ol(0,[],arguments.length),this)),e}}(),this.isItemsBindingVolatile=oi.y$.isVolatileBinding(e),this.isTemplateBindingVolatile=oi.y$.isVolatileBinding(t)}createBehavior(e){return new Cl(e,this.itemsBinding,this.isItemsBindingVolatile,this.templateBinding,this.isTemplateBindingVolatile,this.options)}}function Sl(e,t,i=ml){return new bl(e,"function"==typeof t?t:()=>t,Object.assign(Object.assign({},ml),i))}function xl(e,t){if(!e)return;const i=t.filter((e=>!!e));i?.length&&fetch(`${e}&tids=${i.join(",")}`)}const Tl=il.compose({baseName:"infinite-product-feeds",shadowOptions:{delegatesFocus:!0},styles:nl,template:(e,t)=>$n`
<template>
<div class="infinite-product-feeds-container">
${Wr((e=>{var t;return(null===(t=e.infiniteProductFeedsData)||void 0===t?void 0:t.length)>0}),$n`
<div class="infinite-product-feeds">
${Sl((e=>e.infiniteProductFeedsData),$n`
<msft-product-feed
class="product-feed"
adSlugText="${(e,t)=>t.parent.adSlugText}"
adSlugPolicyText="${(e,t)=>t.parent.adSlugPolicyText}"
visibilityFeedbackUrl="${e=>e.visibilityFeedbackUrl}"
include-separator="${(e,t)=>t.parent.includeSeparator}"
use-clickable-titles="${(e,t)=>t.parent.useClickableTitles}"
use-show-more-clickout="${(e,t)=>t.parent.useShowMoreClickout}"
use-two-click-show-more-clickout="${(e,t)=>t.parent.useTwoClickShowMoreClickout}"
include-ad-slug="${e=>e.includeAdSlug}"
showMoreButtonText="${(e,t)=>t.parent.showMoreButtonText}"
seeAllButtonText="${(e,t)=>t.parent.seeAllButtonText}"
:shoppingEntities="${e=>e.shoppingEntities}"
:titleText="${e=>e.titleText}"
:clickoutUrl="${e=>e.clickoutUrl}"
:productsToShow="${(e,t)=>t.parent.productsToShow}"
:dataFetchOnVisibleCallback="${e=>e.dataFetchOnVisibleCallback}"
:navigateToAdSlugDestination="${(e,t)=>t.parent.navigateToAdSlugDestination}"
:navigateToDestination="${(e,t)=>e.includeAdSlug?t.parent.navigateToAdDestination:t.parent.navigateToDestination}"
:navigateToTitleDestination="${(e,t)=>t.parent.navigateToTitleDestination}"
:handleClickPingUrl="${(e,t)=>t.parent.handleClickPingUrl}"
:logShowMoreButtonClicked="${(e,t)=>e.includeAdSlug?t.parent.logShowMoreAdButtonClicked:t.parent.logShowMoreButtonClicked}"
:sendAdVisibilityFeedback="${(e,t)=>xl.bind(null,e.visibilityFeedbackUrl)}">
</msft-product-feed>
`)}
</div>`)}
<div class="feed-bottom" ${vo("feedBottom")}></div>
</div>
</template>
`});class wl extends zi{constructor(){super(...arguments),this.messageVisible=!1,this.setItems=()=>{for(const e of this.slottedFeedbackItems)e.addEventListener("selected-change",this.handleItemSelected),e.addEventListener("menu-changed",this.handleMenuChanged);this.currentSelected=this.slottedFeedbackItems[0]},this.resetItems=()=>{this.messageVisible=!1;for(const e of this.slottedFeedbackItems)e.removeEventListener("selected-change",this.handleItemSelected),e.removeEventListener("menu-changed",this.handleMenuChanged)},this.handleItemSelected=e=>{const t=e.target;t!==this.currentSelected&&(this.currentSelected.selected=!1,this.currentSelected.menuVisible=!1,this.messageVisible=!1),this.handleSelected(t)},this.handleMenuChanged=e=>{const t=e.target;this.hideMessage(t)}}messageVisibleChanged(){this.$emit("message-visibility")}slottedFeedbackItemsChanged(){this.$fastController.isConnected&&this.setItems()}disconnectedCallback(){super.disconnectedCallback(),this.menuTimer&&clearTimeout(this.menuTimer),this.resetItems()}handleMenuTimer(e){this.menuTimer&&(e.toggleMenu(!1),this.messageVisible=!1,clearTimeout(this.menuTimer))}handleSelected(e){this.currentSelected=e,e.selected=!e.selected,e.selected?e.toggleMenu(!0):(e.toggleMenu(!1),this.menuTimer&&(this.messageVisible=!1,clearTimeout(this.menuTimer))),this.hideMessage(e)}hideMessage(e){this.calloutDuration&&e.menuVisible&&e.showMessage&&(this.messageVisible=!0,this.menuTimer=setTimeout((()=>{this.handleMenuTimer(e)}),this.calloutDuration))}}(0,an.gn)([(0,pn.Lj)({attribute:"callout-duration"})],wl.prototype,"calloutDuration",void 0),(0,an.gn)([oi.LO],wl.prototype,"messageVisible",void 0),(0,an.gn)([oi.LO],wl.prototype,"slottedFeedbackItems",void 0);var Ol,Pl=o(56493);!function(e){e.top="top",e.bottom="bottom"}(Ol||(Ol={}));class Al extends zi{constructor(){super(...arguments),this.selected=!1,this.flyoutVerticalPosition=Ol.bottom,this.menuVisible=!1,this.slottedMenu=[],this.showMessage=!1,this.handleClick=e=>{this.handleSelected(e)},this.handleMenuKeydown=e=>{e.key===Pl.CX&&(this.toggleMenu(!1),document.activeElement!==this&&this.anchorElement.focus())},this.toggleMenu=e=>{this.menuVisible=e,this.showMessage=null===this.querySelector('[role="menu"]'),this.$emit("menu-toggled"),gn.SO.queueUpdate(this.setRegionProps)},this.menuItemChange=()=>{this.showMessage=!0,this.$emit("menu-changed"),document.activeElement!==this&&this.anchorElement&&this.anchorElement.focus()},this.setRegionProps=()=>{this.menuVisible&&this.regionElement&&(this.regionElement.anchorElement=this.anchorElement)}}handleRegionLoaded(e){gn.SO.queueUpdate((()=>{if(this.menuVisible&&this.slottedMenu.length>0&&this.slottedMenu[0]instanceof Hr){const e=this.slottedMenu[0];gn.SO.queueUpdate((()=>e.focus()))}}))}connectedCallback(){super.connectedCallback(),gn.SO.queueUpdate(this.setRegionProps),gn.SO.queueUpdate((()=>{this.showMessage=null===this.querySelector('[role="menu"]')})),gn.SO.queueUpdate((()=>{var e,t,i;const n=null===(i=null===(t=null===(e=this.shadowRoot)||void 0===e?void 0:e.querySelector("fluent-button"))||void 0===t?void 0:t.shadowRoot)||void 0===i?void 0:i.querySelector("button.control");n&&(n.style.backgroundColor="unset")}))}disconnectedCallback(){super.disconnectedCallback();const e=this.slottedMenu[0];e&&(e.childNodes.forEach((e=>{e.addEventListener("change",this.menuItemChange)})),e.removeEventListener("keydown",this.handleMenuKeydown))}handleSelected(e){this.$emit("selected-change",e)}}(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Al.prototype,"selected",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"flyout-vertical-position",mode:"fromView"})],Al.prototype,"flyoutVerticalPosition",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"aria-label",mode:"fromView"})],Al.prototype,"ariaLabel",void 0),(0,an.gn)([oi.LO],Al.prototype,"menuVisible",void 0),(0,an.gn)([oi.LO],Al.prototype,"slottedMenu",void 0),(0,an.gn)([oi.LO],Al.prototype,"showMessage",void 0);const El=wl.compose({baseName:"micro-feedback",styles:(e,t)=>dn`
${zn("inline-grid")} :host {
grid-auto-flow: column;
grid-column-gap: 4px;
}
`,template:(e,t)=>$n`
<slot
${Ao({filter:wo(),property:"slottedFeedbackItems"})}
></slot>
`}),kl=Al.compose({baseName:"micro-feedback-item",styles:(e,t)=>dn`
${zn("grid")} :host {
}
fluent-anchored-region {
z-index: 1;
}
fluent-button::part(content) {
display: flex;
}
.hidden {
display: none;
}
.visible {
display: flex;
}
`,template:(e,t)=>$n`
<template>
<${e.tagFor(cr)?e.tagFor(cr):"fluent-button"}
${vo("anchorElement")}
appearance="stealth"
class="button"
part="button"
aria-label="${e=>e.ariaLabel}"
aria-pressed="${e=>e.selected}"
@click="${(e,t)=>e.handleClick(t.event)}"
>
<span name="unselected-glyph" class="unselected-glyph ${e=>e.selected?"hidden":"visible"}">
<slot name="unselected-glyph">${t.unselectedGlyph||""}</slot>
</span>
<span name="selected-glyph" class="selected-glyph ${e=>e.selected?"visible":"hidden"}">
<slot name="selected-glyph">${t.selectedGlyph||""}</slot>
</span>
<slot></slot>
</${e.tagFor(cr)?e.tagFor(cr):"fluent-button"}>
${Wr((e=>e.menuVisible),$n`
<${e.tagFor(Yr)}
${vo("regionElement")}
class="flyout"
part="flyout"
vertical-positioning-mode="locktodefault"
vertical-default-position="${e=>e.flyoutVerticalPosition}"
vertical-scaling="content"
horizontal-positioning-mode="locktodefault"
horizontal-scaling="content"
horizontal-inset="true"
auto-update-mode="auto"
@loaded="${(e,t)=>e.handleRegionLoaded(t.event)}"
>
${Wr((e=>!e.showMessage),$n`<slot
name="menu"
${Ao({filter:wo('[role="menu"]'),property:"slottedMenu"})}
></slot>`)}
${Wr((e=>e.showMessage),$n`<slot name="feedback-message"></slot>`)}
</${e.tagFor(Yr)}>`)}
</template>
`});class Il extends zi{handleSeeMoreItemsButtonClick(){this.openPaneSeeMoreOffers&&this.openPaneSeeMoreOffers()}}(0,an.gn)([pn.Lj],Il.prototype,"title",void 0),(0,an.gn)([pn.Lj],Il.prototype,"seeAllOffersText",void 0),(0,an.gn)([oi.LO],Il.prototype,"openPaneSeeMoreOffers",void 0);const Dl=dn`
:host {
width: 100%;
font-weight: 600;
letter-spacing: 0em;
}
.multiPcWrapper {
text-align: center;
}
.multiPcWrapper h2 {
margin: 0;
font-family: Segoe UI;
font-size: 20px;
font-weight: 600;
line-height: 28px;
letter-spacing: 0em;
text-align: center;
}
.see-more-offers-button {
width: 100%;
radius: 4px;
padding-left: 16px;
padding-right: 16px;
}
`.withBehaviors(Gn(dn`
:host {
forced-color-adjust: auto;
}
`)),_l=Il.compose({baseName:"multi-price-comparison",shadowOptions:{delegatesFocus:!0},styles:Dl,template:(e,t)=>$n`
<template>
<div class="multiPcWrapper">
<h2>${e=>e.title}</h2>
<slot name="tile1"></slot>
<slot name="tile2"></slot>
<fluent-button aria-label="${e=>e.seeAllOffersText}" class="see-more-offers-button" appearance="accent" @click="${e=>e.handleSeeMoreItemsButtonClick()}">
${e=>e.seeAllOffersText}
</fluent-button>
</div>
</template>
`});class Nl extends zi{handleVisitItemButtonClick(){this.navigateToDestination&&this.navigateToDestination()}handleSeeMoreItemsButtonClick(){this.openPaneSeeMoreOffers&&this.openPaneSeeMoreOffers()}isBuyDirect(){return"Buy with Microsoft"===this.RetailerName}}(0,an.gn)([oi.LO],Nl.prototype,"navigateToDestination",void 0),(0,an.gn)([oi.LO],Nl.prototype,"ImageElement",void 0),(0,an.gn)([oi.LO],Nl.prototype,"openPaneSeeMoreOffers",void 0),(0,an.gn)([pn.Lj],Nl.prototype,"VisitItemButtonText",void 0),(0,an.gn)([pn.Lj],Nl.prototype,"TitleText",void 0),(0,an.gn)([pn.Lj],Nl.prototype,"Savings",void 0),(0,an.gn)([pn.Lj],Nl.prototype,"Price",void 0),(0,an.gn)([pn.Lj],Nl.prototype,"RetailerName",void 0),(0,an.gn)([pn.Lj],Nl.prototype,"ProductImageUrl",void 0),(0,an.gn)([pn.Lj],Nl.prototype,"ProductTitle",void 0),(0,an.gn)([pn.Lj],Nl.prototype,"ProductUrl",void 0),(0,an.gn)([pn.Lj],Nl.prototype,"FavIconImageUrl",void 0),(0,an.gn)([pn.Lj],Nl.prototype,"enableAdSlug",void 0),(0,an.gn)([pn.Lj],Nl.prototype,"isOutOfStock",void 0),(0,an.gn)([pn.Lj],Nl.prototype,"adSlugSrc",void 0),(0,an.gn)([pn.Lj],Nl.prototype,"adSlugAriaLabel",void 0),(0,an.gn)([pn.Lj],Nl.prototype,"enableSeeMoreOffers",void 0),(0,an.gn)([pn.Lj],Nl.prototype,"seeMoreOffersText",void 0),(0,an.gn)([pn.Lj],Nl.prototype,"IsCashback",void 0),(0,an.gn)([pn.Lj],Nl.prototype,"CashbackStr",void 0),(0,an.gn)([pn.Lj],Nl.prototype,"CompetingPriceInImage",void 0);const Rl=dn`
:host {
width: 100%;
font-weight: 600;
letter-spacing: 0em;
}
.notification-header {
text-align: center;
}
.divProductImageContainer {
position: relative;
width: 78px;
height: 78px;
border-radius: 8px;
display: flex;
justify-content: center;
align-items: center;
background: #0000000A;
}
.divCompetingPrice {
position: absolute;
bottom: 0px;
left: 0px;
display: flex;
justify-content: center;
align-items: center;
background: rgba(255, 255, 255, 0.8);
backdrop-filter: blur(10px);
border-radius: 4px;
padding: 4px;
color: #000000
}
.divProductImage {
border-radius: inherit;
width: 100%;
aspect-ratio: 1 / 1;
}
.notification-header-wrapper {
text-decoration: none;
}
.notification-header-button {
width: 100%;
radius: 4px;
margin-top: 12px;
padding-left: 16px;
padding-right: 16px;
}
.see-more-offers-button {
margin: auto;
padding-top: 8px;
font-weight: 600;
}
.buyDirectIcon {
max-width: 16px;
}
.notificationAdSlug {
margin-left: 8px;
width: 22px;
height: 14px;
}
.cashbackLeft {
float: left;
}
.cashbackRight {
float: left;
}
.cashbackValue {
background: #0078D4;
height: 20px;
font-size: 20px;
color: #fff;
float: left;
line-height: 20px;
font-size: 14px;
}
`.withBehaviors(Gn(dn`
:host {
forced-color-adjust: auto;
}
`)),Ml=$n`<svg class="cashbackLeft" xmlns="http://www.w3.org/2000/svg" width="4.5" height="20" viewBox="0 0 4.5 30" fill="none"><path fill-rule="evenodd" clip-rule="evenodd" d="M7.0003 0H3.5C1.567 0 0 1.567 0 3.5V26.5C0 28.433 1.567 30 3.5 30H7.0003V0Z" fill="#0078D4"/>`,Ll=$n`<svg class="cashbackRight" xmlns="http://www.w3.org/2000/svg" width="10" height="20" viewBox="0 0 15 30" fill="none"><path fill-rule="evenodd" clip-rule:"evenodd" d="M0,30h0.6c1,0,1.9-0.4,2.5-1.1L14,17.4c1.3-1.4,1.3-3.5,0-4.8L3.1,1.1C2.5,0.4,1.5,0,0.6,0H0V30z" fill="#0078D4"/>`,Bl=$n`
<msft-notification-header
isAd=${e=>e.enableAdSlug}
isOOSNotification=${e=>e.isOutOfStock}
hasCashback=${e=>e.IsCashback}
otherStockPrice="${e=>e.Price}"
title="${e=>e.TitleText}"
savings="${e=>e.Savings}"
retailer="${e=>e.RetailerName}">
${Wr((e=>e.isBuyDirect()),$n`
<div aria-hidden=true class="buyDirectIcon" slot="icon">
${$n`<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16" fill="none">
<path fill="#1B5AD4" d="M2.5 2C2.22386 2 2 2.22386 2 2.5C2 2.77614 2.22386 3 2.5 3H2.7457C2.96894 3 3.16513 3.14799 3.22646 3.36264L4.81202 8.91208C4.996 9.55603 5.58458 10 6.2543 10H10.823C11.4363 10 11.9879 9.62657 12.2157 9.05709L13.69 5.37139C13.9527 4.71453 13.4689 4 12.7615 4H4.44858L4.18798 3.08792C4.004 2.44397 3.41542 2 2.7457 2H2.5ZM6.5 14C7.32843 14 8 13.3284 8 12.5C8 11.6716 7.32843 11 6.5 11C5.67157 11 5 11.6716 5 12.5C5 13.3284 5.67157 14 6.5 14ZM10.5 14C11.3284 14 12 13.3284 12 12.5C12 11.6716 11.3284 11 10.5 11C9.67157 11 9 11.6716 9 12.5C9 13.3284 9.67157 14 10.5 14Z"/>
</svg>`}
</div>
`)}
${Wr((e=>!e.isBuyDirect()&&e.FavIconImageUrl),$n`
<img aria-hidden=true slot="icon" src="${e=>e.FavIconImageUrl}"/>
`)}
<div class="divProductImageContainer" slot="image">
<img class="divProductImage" src="${e=>e.ProductImageUrl}" aria-label="${e=>e.ProductTitle}"/>
${Wr((e=>e.CompetingPriceInImage),$n`
<div class="divCompetingPrice">${e=>e.CompetingPriceInImage}</div>
`)}
</div>
${Wr((e=>e.enableAdSlug),$n`
<img class="notificationAdSlug" src="${e=>e.adSlugSrc}" slot="adslug" aria-label="${e=>e.adSlugAriaLabel}"/>
`)}
${Wr((e=>e.IsCashback&&e.CashbackStr),$n`
<div slot="cbicon">
${Ml}
<span class="cashbackValue">${e=>e.CashbackStr}</span>
${Ll}
</div>
`)}
</msft-notification-header>
`,Fl=Nl.compose({baseName:"notification-competing-price-header",shadowOptions:{delegatesFocus:!0},styles:Rl,template:(e,t)=>$n`
<template>
<div class="notification-header">
<a
class="notification-header-wrapper"
@click="${(e,t)=>e.handleVisitItemButtonClick()}"
href="${e=>e.ProductUrl}"
aria-label="${e=>e.VisitItemButtonText}">
${Bl}
</a>
<fluent-button aria-label="${e=>e.VisitItemButtonText}" class="notification-header-button" appearance="accent" @click="${e=>e.handleVisitItemButtonClick()}">
${e=>e.VisitItemButtonText}
</fluent-button>
${Wr((e=>e.enableSeeMoreOffers),$n`
<fluent-button aria-label="${e=>e.seeMoreOffersText}" class="see-more-offers-button" appearance="lightweight" @click="${e=>e.handleSeeMoreItemsButtonClick()}">
${e=>e.seeMoreOffersText}
</fluent-button>
`)}
</div>
</template>
`});class Ul extends zi{get iconAfterRetailer(){return this.v2Design||this.isOOSNotification&&!this.isAd}}(0,an.gn)([pn.Lj],Ul.prototype,"currentPrice",void 0),(0,an.gn)([pn.Lj],Ul.prototype,"oldPrice",void 0),(0,an.gn)([pn.Lj],Ul.prototype,"title",void 0),(0,an.gn)([pn.Lj],Ul.prototype,"savings",void 0),(0,an.gn)([pn.Lj],Ul.prototype,"retailer",void 0),(0,an.gn)([pn.Lj],Ul.prototype,"isAd",void 0),(0,an.gn)([pn.Lj],Ul.prototype,"hasArrow",void 0),(0,an.gn)([pn.Lj],Ul.prototype,"hasGraph",void 0),(0,an.gn)([pn.Lj],Ul.prototype,"hasCashback",void 0),(0,an.gn)([pn.Lj],Ul.prototype,"priceAfterCb",void 0),(0,an.gn)([pn.Lj],Ul.prototype,"priceHistoryType",void 0),(0,an.gn)([pn.Lj],Ul.prototype,"useSlotTitle",void 0),(0,an.gn)([pn.Lj],Ul.prototype,"isOOSNotification",void 0),(0,an.gn)([pn.Lj],Ul.prototype,"otherStockPrice",void 0),(0,an.gn)([pn.Lj],Ul.prototype,"isNewPHInsights",void 0),(0,an.gn)([pn.Lj],Ul.prototype,"productInsights",void 0),(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Ul.prototype,"v2Design",void 0),(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Ul.prototype,"isAdditionalCashback",void 0),(0,an.gn)([oi.lk],Ul.prototype,"iconAfterRetailer",null);const Hl=dn`
:host {
--content-max-lines: 2;
outline: none;
font-family: ${qn.SVJ};
font-size: ${qn.sNp};
font-weight: 600;
line-height: ${qn.vgC};
min-width: calc(${Lo} * 1px);
border-radius: calc(${qn.rSr} * 1px);
box-sizing: border-box;
color: ${qn.CHi};
fill: currentcolor;
cursor: pointer;
height: auto;
position: relative;
width: 100%;
box-sizing: border-box;
align-items: center;
text-align: left;
margin-bottom: 12px;
}
.control {
display: grid !important;
grid-template-columns: auto 78px;
justify-content: space-between;
}
.control.smallImage {
grid-template-columns: auto 60px;
}
.control.v2 {
grid-template-columns: auto 88px;
}
.lateralMargin {
width: calc(100% - 32px) !important;
margin: auto;
}
.divSavingsContent {
display: flex;
flex-direction: row;
margin-bottom: 2px;
}
.phTextArrow {
margin-top: 4px;
}
::slotted([slot="arrow"]) {
margin-left: 8px;
margin-top: 20px;
}
.divAttribution {
display: grid;
grid-template-columns: auto minmax(0px, 1fr);
}
.divAttrWrapper {
display: flex;
flex-direction: row;
align-items: center;
}
.divTextContent {
display: flex;
flex-direction: column;
row-gap: 4px;
}
.divTextContent.spaced {
row-gap: unset;
justify-content: space-evenly;
}
.txtHeader {
font-size: 16px;
line-height: 22px;
font-weight: 600;
margin: 0px;
}
.txtHeader.oos {
color: var(--text-green-savings-color);
font-size: 20px;
line-height: 24px;
}
.txtSavings {
font-weight: 600;
line-height: 40px;
color: var(--text-green-savings-color);
}
.txtSavings.decrease {
color: var(--price-history-decrease-color);
}
.txtSavings.increase {
color: var(--price-history-increase-color);
}
.txtSavings.stable {
color: var(--price-history-stable-color);
}
.txtOlPrice {
font-size: 14px;
font-weight: 600;
line-height: 20px;
color: var(--neutral-foreground-hint);
}
.txtOlPrice.small {
font-weight: 400;
font-size: 12px;
}
.txtLight {
font-weight: 400;
}
.divPriceWrapper {
display: flex;
flex-direction: row;
column-gap: 8px;
font-size: 14px;
font-weight: 600;
line-height: 20px;
color: var(--text-green-savings-color);
}
.divInsightsWrapper {
border-radius: 4px;
border: 1px solid var(--stroke-neutral-1-rest, rgba(0, 0, 0, 0.18));
border: 1px solid var(--stroke-neutral-1-rest, color(display-p3 0 0 0 / 0.18));
background: var(--acrylic-light, rgba(255, 255, 255, 0.77));
background: var(--acrylic-light, color(display-p3 1 1 1 / 0.77));
display: flex;
padding: 6px 8px 6px 6px;
align-items: center;
gap: var(--corner-radius-control-regular, 4px);
width: fit-content;
height: auto;
margin: 10px 15px -2px;
}
.insightsText {
color: var(--foreground-neutral-2-rest, rgba(0, 0, 0, 0.74));
font-size: 12px;
font-style: normal;
font-weight: 600;
line-height: 14px;
}
#insightsIcon {
display: flex;
}
.divPriceWrapper.oos {
color: var(--neutral-foreground-rest);
}
.txtCurrentPrice.decrease {
color: var(--price-history-decrease-color);
}
.txtCurrentPrice.increase {
color: var(--price-history-increase-color);
}
.txtCurrentPrice.stable {
color: var(--neutral-foreground-rest);
}
.cashbackPriceWrapper {
display: flex;
column-gap: 10px;
margin-bottom: 4px;
}
.txtRetailer.oos {
font-size: 20px;
line-height: 24px;
font-weight: 600;
color: var(--neutral-foreground-rest);
text-overflow: ellipsis;
overflow: hidden;
}
`.withBehaviors(Gn(dn`
:host {
forced-color-adjust: auto;
}
`)),$l=Ul.compose({baseName:"notification-header",shadowOptions:{delegatesFocus:!0},styles:Hl,template:(e,t)=>$n`
<template>
<div
class="divHeaderWrapper control lateralMargin ${e=>e.v2Design?" v2":""}${e=>e.isNewPHInsights?" smallImage":""}"
style="border-bottom: ${e=>e.hasGraph?"1px solid #F1F1F1":"none"};
padding-bottom: ${e=>e.hasGraph?"12px":"0px"};"
part="control"
>
<div class="divTextContent${e=>e.isNewPHInsights?" spaced":""}" part="divTextContent">
<slot name="slotTitle"></slot>
${Wr((e=>!e.useSlotTitle),$n`
<h2
class="txtHeader ${e=>e.isOOSNotification?"oos":""}"
title="${e=>e.title+(e.savings?" "+e.savings:"")}"
>
${e=>e.title}
<slot name="priceMatchTitle"></slot><br />
<div class="divSavingsContent ${e=>e.hasArrow?"phTextArrow":""}">
<span
class="txtSavings ${e=>e.priceHistoryType?e.priceHistoryType:""}"
style="font-size: ${e=>e.hasArrow?"40px":"32px"} "
>${e=>e.savings}</span
>
${Wr((e=>e.hasArrow),$n` <slot name="arrow"></slot>`)}
</div>
</h2>
`)}
${Wr((e=>e.currentPrice&&e.oldPrice),$n`<div class="divPriceWrapper">
<span
class="txtCurrentPrice ${e=>e.priceHistoryType?e.priceHistoryType:""}"
title="${e=>e.currentPrice}"
>${e=>e.currentPrice}</span
>
<s class="txtOlPrice${e=>e.isNewPHInsights?" small":""}" title="${e=>e.oldPrice}">${e=>e.oldPrice}</s>
<slot name="arrowInPrice" />
</div>`)}
<slot name="PriceComparePT"></slot>
<slot name="notificationDescription"></slot>
${Wr((e=>e.currentPrice&&!e.oldPrice),$n`<div class="divPriceWrapper">
<span
class="txtCurrentPrice ${e=>e.priceHistoryType?e.priceHistoryType:""}"
title="${e=>e.currentPrice}"
>${e=>e.currentPrice}</span
>
</div>`)}
${Wr((e=>e.hasCashback&&(!e.v2Design||e.isAdditionalCashback)),$n` <div class="cashbackPriceWrapper">
<div class="divAttrWrapper">
<msft-attribution class="divAttribution" part="divAttribution">
<slot name="cbicon"></slot>
<slot name="cbtext"></slot>
</msft-attribution>
</div>
</div>`)}
${Wr((e=>e.retailer),$n`<div class="divAttrWrapper">
<msft-attribution class="divAttribution" part="divAttribution">
${Wr((e=>!e.iconAfterRetailer),$n`
<slot name="icon"></slot>
<span
class="txtRetailer ${e=>e.isOOSNotification?"oos":""}"
title="${e=>e.retailer}"
>${e=>e.retailer}</span
>
`)}
${Wr((e=>e.iconAfterRetailer),$n`
<span
class="txtRetailer ${e=>e.isOOSNotification?"oos":""}"
title="${e=>e.retailer}"
>${e=>e.retailer}</span
>
<slot name="icon"></slot>
`)}
</msft-attribution>
${Wr((e=>e.isAd),$n`<slot name="adslug"></slot>`)}
</div>`)}
${Wr((e=>e.otherStockPrice),$n`<div class="divPriceWrapper ${e=>e.isOOSNotification?"oos":""}">
${e=>e.otherStockPrice}
</div>`)}
</div>
<slot name="image"></slot>
</div>
${Wr((e=>e.productInsights&&0!==e.productInsights.length),$n`<div class="divInsightsWrapper">
<span id="insightsIcon">
<svg width="13" height="13" viewBox="0 0 13 13" fill="none" xmlns="http://www.w3.org/2000/svg">
<path
d="M2.25 7.09375C2.25 6.75846 2.28906 6.42806 2.36719 6.10254C2.44531 5.77702 2.56738 5.46615 2.7334 5.16992C2.75944 5.12435 2.78548 5.07715 2.81152 5.02832C2.83757 4.97949 2.86849 4.93392 2.9043 4.8916C2.9401 4.84603 2.97754 4.81185 3.0166 4.78906C3.05566 4.76628 3.10612 4.75326 3.16797 4.75C3.22005 4.75 3.27051 4.76302 3.31934 4.78906C3.36816 4.8151 3.4056 4.85091 3.43164 4.89648L4.08105 5.95605C4.11035 6.00488 4.14941 6.04232 4.19824 6.06836C4.24707 6.0944 4.30241 6.10905 4.36426 6.1123C4.47493 6.1123 4.5612 6.07161 4.62305 5.99023C4.6849 5.90885 4.71745 5.81608 4.7207 5.71191C4.7207 5.66634 4.71582 5.62565 4.70605 5.58984C4.69629 5.55404 4.68164 5.51497 4.66211 5.47266C4.52865 5.1862 4.4196 4.90462 4.33496 4.62793C4.25033 4.35124 4.20801 4.05013 4.20801 3.72461C4.20801 3.31445 4.27637 2.95475 4.41309 2.64551C4.5498 2.33626 4.74023 2.07096 4.98438 1.84961C5.22852 1.62826 5.51335 1.44922 5.83887 1.3125C6.16439 1.17578 6.5127 1.07324 6.88379 1.00488C6.89681 1.00163 6.91471 1 6.9375 1C7.01237 1 7.0791 1.02441 7.1377 1.07324C7.21256 1.13835 7.25 1.2181 7.25 1.3125C7.25 1.80078 7.33301 2.26628 7.49902 2.70898C7.66504 3.15169 7.89453 3.56673 8.1875 3.9541C8.36654 4.18848 8.5472 4.42448 8.72949 4.66211C8.91178 4.89974 9.07943 5.14714 9.23242 5.4043C9.38542 5.66146 9.50911 5.92839 9.60352 6.20508C9.69792 6.48177 9.74675 6.778 9.75 7.09375C9.75 7.44206 9.70768 7.7806 9.62305 8.10938C9.53841 8.43815 9.41471 8.7474 9.25195 9.03711C9.08919 9.32682 8.89714 9.5905 8.67578 9.82812C8.45443 10.0658 8.20378 10.2725 7.92383 10.4482C7.64388 10.624 7.34277 10.7591 7.02051 10.8535C6.69824 10.9479 6.35807 10.9967 6 11C5.64193 11 5.30176 10.9528 4.97949 10.8584C4.65723 10.764 4.35775 10.6289 4.08105 10.4531C3.80436 10.2773 3.55208 10.0706 3.32422 9.83301C3.09635 9.59538 2.9043 9.33008 2.74805 9.03711C2.5918 8.74414 2.46973 8.4349 2.38184 8.10938C2.29395 7.78385 2.25 7.44531 2.25 7.09375Z"
fill="#D63600"
style="fill:#D63600;fill:color(display-p3 0.8400 0.2100 0.0000);fill-opacity:1;"
/>
</svg>
</span>
<span class="insightsText" title="${e=>e.productInsights}">${e=>e.productInsights}</span>
</div>`)}
</template>
`});class Zl extends zi{constructor(){super(...arguments),this.onKeyPressHandler=e=>{switch(e.key){case"Space":case"Enter":e.preventDefault(),this.onSelectedHandler()}},this.onSelectedHandler=()=>{document.activeElement!==this&&this.focus(),this.$emit("selected")}}connectedCallback(){super.connectedCallback()}disconnectedCallback(){super.disconnectedCallback()}onClickHandler(){this.onSelectedHandler()}}function Vl(e){try{return JSON.parse(e.imageSrcs)}catch(e){return[]}}(0,an.gn)([pn.Lj],Zl.prototype,"mainTitle",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"sub-title"})],Zl.prototype,"subTitle",void 0),(0,an.gn)([pn.Lj],Zl.prototype,"otherItemsTitle",void 0),(0,an.gn)([pn.Lj],Zl.prototype,"orderSummary",void 0),(0,an.gn)([pn.Lj],Zl.prototype,"hasMultiple",void 0),(0,an.gn)([pn.Lj],Zl.prototype,"isV2",void 0),(0,an.gn)([pn.Lj],Zl.prototype,"progressPercentage",void 0),(0,an.gn)([pn.Lj],Zl.prototype,"heading",void 0),(0,an.gn)([pn.Lj],Zl.prototype,"trackerKey",void 0),(0,an.gn)([pn.Lj],Zl.prototype,"imageSrcs",void 0),(0,an.gn)([oi.LO],Zl.prototype,"childElements",void 0);const Gl=Zl.compose({baseName:"package-tracker-card-new",shadowOptions:{delegatesFocus:!0},styles:(e,t)=>dn`
${zn("flex")} :host {
position: relative;
box-sizing: border-box;
border: none;
border-radius: 10px;
font-family: ${qn.SVJ};
font-size: ${qn.cSu};
line-height: ${qn.RUt};
color: ${qn.CHi};
width: 100%;
}
.control {
position: relative;
font-family: ${qn.SVJ};
box-sizing: border-box;
box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.15);
border-radius: 10px;
border-radius: 10px;
display: flex;
flex-direction: column;
padding: 16px 0px;
width: 100%;
cursor: pointer;
justify-content: center;
background: var(--fill-color);
margin-bottom: 12px!important;
}
.control-v2 {
position: relative;
font-family: ${qn.SVJ};
box-sizing: border-box;
border-radius: 8px;
display: flex;
flex-direction: column;
padding: 12px 0px;
width: 336px;
cursor: pointer;
justify-content: center;
background: var(--fill-color);
margin-bottom: 12px!important;
margin-top: 12px!important;
}
.order-summary {
font-weight: 600;
}
.productList {
margin-top: 8px;
display: flex;
flex-direction: row;
column-gap: 8px;
}
.product {
background-color: #FFFFFF;
background-position: center;
background-size: contain;
background-repeat: no-repeat;
border-radius: 8px;
font-weight: 400;
font-size: 20px;
text-align: center;
color: #000000;
display: flex;
justify-content: center;
align-items: center;
overflow: hidden;
place-self: center;
width: 66px;
height: 66px;
}
.content-info {
max-width: 200px;
}
.other-products {
display: flex;
flex-direction: row;
gap: 10px;
}
.product-v2 {
background-color: #FFFFFF;
background-position: center;
background-size: cover;
border-radius: 8px;
font-weight: 400;
font-size: 20px;
text-align: center;
color: #000000;
display: flex;
justify-content: center;
align-items: center;
overflow: hidden;
place-self: center;
width: 40px;
height: 40px;
}
hr {
margin-top: 20px;
border: 2px solid #000000;
opacity: 0.04;
border-bottom: unset;
}
.card-content {
width: calc(100% - 24px);
margin: auto;
display: grid;
grid-template-columns: auto auto;
justify-content: flex-start;
align-items: center;
gap: 10px;
height: auto;
}
.card-content-v2 {
width: 250px;
margin: auto;
margin-left: 40px;
display: grid;
grid-template-columns: auto auto;
justify-content: flex-start;
align-items: center;
gap: 10px;
height: auto;
}
.card-header {
display: grid;
grid-template-columns: 16px auto;
grid-column-gap: 3px;
justify-content: flex-start;
align-content: center;
align-content: flex-start;
align-items: center;
}
.heading {
margin-left: 3px;
}
.card-header-v2 {
display: flex;
flex-direction: column;
}
.card-header-top {
display: flex;
flex-direction: row;
gap: 8px;
}
.card-header-bottom {
margin-top: 8px;
margin-left: 28px;
width: 276px;
}
.header-wrapper {
width: calc(100% - 24px);
display: flex;
justify-content: space-between;
flex-direction: row;
margin: auto;
margin-bottom: 20px;
}
.others-wrapper {
width: calc(100% - 24px);
margin: auto;
}
.txtMainTitle {
display: -webkit-box;
-webkit-line-clamp: 1;
-webkit-box-orient: vertical;
overflow: hidden;
overflow-wrap: break-word;
font-weight: 600;
}
.txtDescription {
font-size: 12px;
display: -webkit-box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
overflow: hidden;
overflow-wrap: break-word;
color: rgba(0, 0, 0, 0.55);
}
::slotted([slot="main-image"]) {
border-radius: 4px;
filter: drop-shadow(0px 1.6px 3.6px rgba(0, 0, 0, 0.13)) drop-shadow(0px 0px 2.9px rgba(0, 0, 0, 0.11));
width: 80px;
height: 80px;
overflow: hidden;
}
::slotted([slot="main-image-v2"]) {
border-radius: 8px;
width: 40px;
height: 40px;
background: rgba(0, 0, 0, 0.04);
background-blend-mode: multiply, normal;
overflow: hidden;
}
::slotted([slot="icon"]) {
width: 20px;
max-width: 20px!important;
height: 20px;
overflow: hidden;
}
::slotted([slot="drop-image"]) {
width: 83px;
height: 64px;
overflow: hidden;
}
::slotted([slot="more-actions"]) {
background-color: transparent;
height: 12px;
width: 12px;
}
.title {
overflow: hidden;
display: -webkit-box!important;
-webkit-line-clamp: 1;
-webkit-box-orient: vertical;
margin: 0 8px;
grid-column: 1/2;
font-style: normal;
font-weight: 700;
font-size: 14px;
line-height: 28px;
text-align: center;
word-break: break-all;
overflow-wrap: break-all;
color: #FFFFFF !important;
}
.sub-title {
font-size: ${qn.G8g};
line-height: ${qn.MwG};
color: ${qn.Q5n};
text-align: start;
margin-inline-start: 0px;
margin-top: 0px;
overflow: hidden;
overflow-wrap: break-word;
display: -webkit-box;
-webkit-line-clamp: 1;
-webkit-box-orient: vertical;
max-width:75px;
}
@media (prefers-color-scheme: dark) {
span {
color: var(--neutral-foreground-rest)!important;
}
hr {
opacity: 0.08;
}
.control-v2 {
background-color: #424242;
}
}
`,template:(e,t)=>$n`
<template>
<a
class=${e=>e.isV2?"control-v2":"control"}
part="control"
tabindex="0">
${Wr((e=>e.heading),$n`
<div class="header-wrapper">
<div class=${e=>e.isV2?"card-header-v2":"card-header"}>
${Wr((e=>e.isV2),$n`
<div class="card-header-top">
<slot name="icon"></slot>
<span>${e=>e.heading}</span>
${Wr((e=>e.orderSummary),$n`<span class="order-summary"> · ${e=>e.orderSummary}</span>`)}
</div>
<div class="card-header-bottom">
<slot name="progress-bar">
<${e.tagFor(Ka)} class="progress-bar" part="progress-bar" min="0" max="100" value="${e=>e.progressPercentage}" aria-hidden="true">
</${e.tagFor(Ka)}>
</slot>
</div>
`)}
${Wr((e=>!e.isV2),$n`
<slot name="icon"></slot>
<span class="heading">${e=>e.heading}</span>
`)}
</div>
<slot name="more-actions" slot="more-actions"></slot>
</div>`)}
<div class=${e=>e.isV2?"card-content-v2":"card-content"}>
<slot name=${e=>e.isV2?"main-image-v2":"main-image"}></slot>
<div class="content-info">
${Wr((e=>!e.isV2),$n`
<span class="txtMainTitle">${e=>e.mainTitle}</span>
<slot name="progress-bar">
<${e.tagFor(Ka)} class="progress-bar" part="progress-bar" min="0" max="100" value="${e=>e.progressPercentage}" aria-hidden="true">
</${e.tagFor(Ka)}>
</slot>
`)}
${Wr((e=>e.hasMultiple&&e.isV2),$n`
<div class="other-products">
${Sl((e=>Vl(e)),$n`
${Wr(((e,t)=>t.length<5||t.index<3),$n`
<div
class="product-v2"
style="background-image: linear-gradient(0deg, rgba(0, 0, 0, 0.03), rgba(0, 0, 0, 0.03)), url('${e=>e.productImageUrl}');"
aria-label="${e=>e.productName}"
>
</div>
`)}
`,{positioning:!0})}
${Wr((e=>{var t;return(null===(t=Vl(e))||void 0===t?void 0:t.length)>4}),$n`
<div
class="product-v2"
style="background-image: linear-gradient(0deg, rgba(0, 0, 0, 0.03), rgba(0, 0, 0, 0.03));"
aria-label="+${e=>{var t;return(null===(t=Vl(e))||void 0===t?void 0:t.length)-3}}"
>
+${e=>{var t;return(null===(t=Vl(e))||void 0===t?void 0:t.length)-3}}
</div>
`)}
</div>
`)}
${Wr((e=>!e.hasMultiple||!e.isV2),$n`
<span class="txtDescription">${e=>e.subTitle}</span>
`)}
</div>
</div>
${Wr((e=>e.otherItemsTitle),$n`
<div>
<hr></hr>
<div class="others-wrapper">
<span>${e=>e.otherItemsTitle}</span>
<div class="productList">
${Sl((e=>Vl(e)),$n`
${Wr(((e,t)=>t.length<5||t.index<3),$n`
<div
class="product"
style="background-image: linear-gradient(0deg, rgba(0, 0, 0, 0.03), rgba(0, 0, 0, 0.03)), url('${e=>e.productImageUrl}');"
aria-label="${e=>e.productName}"
>
</div>
`)}
`,{positioning:!0})}
${Wr((e=>{var t;return(null===(t=Vl(e))||void 0===t?void 0:t.length)>4}),$n`
<div
class="product"
style="background-image: linear-gradient(0deg, rgba(0, 0, 0, 0.03), rgba(0, 0, 0, 0.03));"
aria-label="+${e=>{var t;return(null===(t=Vl(e))||void 0===t?void 0:t.length)-3}}"
>
+${e=>{var t;return(null===(t=Vl(e))||void 0===t?void 0:t.length)-3}}
</div>
`)}
</div>
</div>
</div>
`)}
</a>
</template>
`});class jl extends zi{constructor(){super(...arguments),this.onKeyPressHandler=e=>{switch(e.key){case"Space":case"Enter":e.preventDefault(),this.onSelectedHandler()}},this.onSelectedHandler=()=>{document.activeElement!==this&&this.focus(),this.$emit("selected")}}connectedCallback(){super.connectedCallback()}disconnectedCallback(){super.disconnectedCallback()}onClickHandler(){this.onSelectedHandler()}}(0,an.gn)([pn.Lj],jl.prototype,"supportPageUrl",void 0),(0,an.gn)([oi.LO],jl.prototype,"childElements",void 0);const zl=jl.compose({baseName:"price-match-card",shadowOptions:{delegatesFocus:!0},styles:(e,t)=>dn`
${zn("flex")} :host {
position: relative;
box-sizing: border-box;
border: none;
border-radius: 10px;
font-family: ${qn.SVJ};
font-size: ${qn.cSu};
line-height: ${qn.RUt};
color: ${qn.CHi};
width: 100%;
}
.control {
position: relative;
font-family: ${qn.SVJ};
box-sizing: border-box;
border-radius: 10px;
border-radius: 10px;
display: flex;
flex-direction: column;
padding: 12px 16px;
max-height: 120px;
width: 100%;
cursor: pointer;
justify-content: space-between;
background: var(--fill-color);
margin-top: 6px!important;
margin-bottom: 6px!important;
}
.productDetailsWrapper {
display: flex;
flex-direction: row;
justify-content: space-between;
height: 50px;
}
.priceMatchTexts {
width: 230px;
height: 50px;
display: flex;
flex-direction: column;
justify-content: space-between;
}
.priceMatch {
height: 40px;
font-weight: 600;
font-size: 14px;
line-height: 20px;
}
.priceMatchTitle {
color: #1A1A1A;
height: 32px;
}
::slotted([slot="claimText"]) {
display: inline-block;
font-size: 12px;
color: #424242;
font-weight: 400;
line-height: 16px;
height: 16px;
}
.buttonWrapper {
padding-top: 12px;
}
@media (prefers-color-scheme: dark) {
.control {
background-color: #424242;
}
.priceMatchTitle {
color: #FFFFFF;
}
}
`,template:(e,t)=>$n`
<template>
<div class="control wrapper" part="control" tabindex="0">
<div class="productDetailsWrapper">
<div class="priceMatchTexts">
<div class="priceMatch">
<slot name="priceMatchTitle"></slot>
</div>
<slot name="claimText"></slot>
</div>
<slot name="image"></slot>
</div>
${Wr((e=>e.supportPageUrl),$n`
<div class="buttonWrapper">
<slot name="button"></slot>
</div>
`)}
</div>
</template>
`});class Wl extends Zo{constructor(){super(...arguments),this.isRevampExpActive=!1,this.isVideoCard=!1,this.hasAnnotation=!1,this.inCollections=!1,this.isCjk=!1}}(0,an.gn)([pn.Lj],Wl.prototype,"priceCurrency",void 0),(0,an.gn)([pn.Lj],Wl.prototype,"price",void 0),(0,an.gn)([pn.Lj],Wl.prototype,"priceHundredthText",void 0),(0,an.gn)([pn.Lj],Wl.prototype,"priceDescriptor",void 0),(0,an.gn)([pn.Lj],Wl.prototype,"savings",void 0),(0,an.gn)([pn.Lj],Wl.prototype,"lowest",void 0),(0,an.gn)([pn.Lj],Wl.prototype,"retailer",void 0),(0,an.gn)([pn.Lj],Wl.prototype,"description",void 0),(0,an.gn)([pn.Lj],Wl.prototype,"isPWILOExpActive",void 0),(0,an.gn)([pn.Lj],Wl.prototype,"isAd",void 0),(0,an.gn)([pn.Lj],Wl.prototype,"isAffiliate",void 0),(0,an.gn)([pn.Lj],Wl.prototype,"ariaSetSize",void 0),(0,an.gn)([pn.Lj],Wl.prototype,"ariaPosInSet",void 0),(0,an.gn)([pn.Lj],Wl.prototype,"isPCBOffer",void 0),(0,an.gn)([pn.Lj],Wl.prototype,"strikethroughprice",void 0),(0,an.gn)([pn.Lj],Wl.prototype,"originalPrice",void 0),(0,an.gn)([pn.Lj],Wl.prototype,"ariaLabel",void 0),(0,an.gn)([pn.Lj],Wl.prototype,"isInCjkFlyout",void 0),(0,an.gn)([pn.Lj],Wl.prototype,"isFirst",void 0),(0,an.gn)([pn.Lj],Wl.prototype,"isNotification",void 0),(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Wl.prototype,"isNoAlign",void 0),(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Wl.prototype,"isRevampExpActive",void 0),(0,an.gn)([oi.LO],Wl.prototype,"isVideoCard",void 0),(0,an.gn)([oi.LO],Wl.prototype,"hasAnnotation",void 0),(0,an.gn)([oi.LO],Wl.prototype,"inCollections",void 0),(0,an.gn)([oi.LO],Wl.prototype,"isCjk",void 0),(0,an.gn)([pn.Lj],Wl.prototype,"installmentDescription",void 0);const Kl=dn`
${zn("grid")} :host {
--content-max-lines: 2;
--text-price-color: #1a1a1a;
--ad-slug-color: #d1d1d1;
--ad-slug-text-color: #000000bd;
outline: none;
font-family: ${qn.SVJ};
font-size: ${qn.sNp};
font-weight: 600;
line-height: ${qn.vgC};
min-width: calc(${Lo} * 1px);
border-radius: calc(${qn.rSr} * 1px);
box-shadow: 0px 0px 2px 0px rgba(0, 0, 0, 0.12), 0px 1px 2px 0px rgba(0, 0, 0, 0.14);
box-sizing: border-box;
color: ${qn.CHi};
fill: currentcolor;
cursor: pointer;
height: auto;
position: relative;
}
:host {
display: block;
box-sizing: border-box;
}
:host(:hover) {
background: linear-gradient(
265.08deg,
rgba(36, 255, 0, 0.06) -6.71%,
rgba(0, 210, 255, 0.06) 38.87%,
rgba(255, 188, 125, 0.06) 93.88%
);
}
.control: ${No} {
box-shadow: 0 0 0 calc(${qn.vxp} * 1px) ${qn.yGg};
}
.productCardWrapper {
display: flex;
flex-direction: row;
column-gap: 12px;
padding: 12px;
height: auto;
width: 100%;
align-items: center;
box-sizing: border-box;
text-decoration: none;
background: transparent;
outline: none;
border: none;
color: inherit;
fill: inherit;
border-radius: 0px;
border-top: var(--product-wrapper-border, 1px solid rgb(236, 236, 236));
position: relative;
}
.productCardWrapper.notification {
margin-left: 16px;
margin-right: 16px;
width: unset;
padding-left: unset;
padding-right: unset;
column-gap: 6px;
}
.productCardWrapper.noAlign {
align-items: unset;
}
.productCardWrapperCjk {
display: flex;
flex-direction: row;
column-gap: 12px;
margin: 12px 12px 12px 0px;
margin-left: 16px;
margin-bottom: 12px !important;
height: auto;
width: auto;
align-items: center;
box-sizing: border-box;
text-decoration: none;
background: transparent;
outline: none;
border: none;
color: inherit;
fill: inherit;
border-radius: 0px;
position: relative;
}
.isFirst {
border-top: none !important;
}
.divPriceInfo {
display: flex;
flex-direction: column;
margin-left: auto;
width: max-content;
}
.divLowestPrice {
width: auto;
height: 16px;
background-color: #eff9f4;
border-radius: 4px;
display: flex;
justify-content: center;
align-items: center;
width: max-content;
}
.divLowestPriceNoBackGround {
background-color: transparent;
}
.divPrice {
text-align: right;
display: flex;
flex-direction: row;
align-items: center;
margin-left: auto;
}
.divInstallmentDescription {
font-size: ${qn.sNp};
font-weight: 400;
line-height: ${qn.vgC};
color: var(--neutral-foreground-hint);
}
.txtPrice {
font-size: 20px;
font-weight: 600;
line-height: 22px;
color: var(--text-price-color);
}
.txtPriceStrikeThrough {
font-size: 12px;
font-weight: 400;
line-height: 16px;
color: #707070;
display: flex;
align-items: center;
margin-left: auto;
text-decoration: line-through;
}
.txtPriceDecorative {
font-size: 14px;
font-weight: 600;
line-height: 14px;
color: var(--text-price-color);
margin-bottom: 2px;
margin-left: 1px;
}
.txtPriceDecorativeCjk {
font-family: "Roboto", "Segoe UI", Helvetica, Verdana, sans-serif;
font-size: 20px;
font-weight: 600;
line-height: 14px;
color: var(--text-price-color);
margin-left: 1px;
}
.txtPriceSmall {
font-size: 14px;
font-weight: 600;
line-height: 22px;
color: var(--text-price-color);
}
.txtPriceDecorativeSmall {
font-size: 10px;
font-weight: 600;
line-height: 14px;
color: var(--text-price-color);
margin-bottom: 2px;
margin-left: 1px;
}
.txtPriceDecorativeSmallCjk {
font-family: "Roboto", "Segoe UI", Helvetica, Verdana, sans-serif;
font-size: 14px;
font-weight: 600;
line-height: 14px;
color: var(--text-price-color);
margin-left: 1px;
}
.txtPriceDescriptor {
margin-left: 4px;
font-size: 12px;
font-weight: 600;
display: flex;
align-self: stretch;
align-items: end;
color: var(--text-price-color);
}
.txtDescription {
display: -webkit-box;
-webkit-line-clamp: 1;
-webkit-box-orient: vertical;
overflow: hidden;
}
.txtDescriptionBold {
font-weight: 600;
-webkit-line-clamp: 1;
}
#couponText {
color: var(--text-neutral-foreground-hint);
}
.currency {
display: flex;
}
#cents {
margin-top: 2px;
margin-left: 1px;
font-weight: 600;
font-size: 10px;
}
#dollarSign {
margin-top: 2px;
margin-right: 1px;
font-weight: 600;
font-size: 10px;
}
.txtDescriptionFirst {
font-weight: 600;
font-size: 14px;
line-height: 22px;
}
#couponDiscount {
display: flex;
}
#couponIcon {
margin-right: 5px;
}
.txtCollSavings {
display: flex;
}
.txtSavings {
font-size: 11px;
font-weight: 400;
line-height: 16px;
text-align: right;
color: var(--text-green-savings-color);
}
.txtSavingsCJK {
font-size: 11px;
font-weight: 400;
line-height: 16px;
text-align: right;
margin-top: 4px;
color: #de3700;
}
.txtLowestPrice {
font-size: 9px;
line-height: 8px;
letter-spacing: 0.02em;
color: var(--text-green-savings-color);
text-align: center;
font-weight: 600;
margin: 0px 5px;
}
.txtRetailer {
font-size: 12px;
line-height: 16px;
text-align: left;
vertical-align: middle;
font-weight: 400;
max-width: 120px;
color: var(--text-price-color);
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
.txtRetailerV2 {
color: var(--light-foreground-foreground-1, #242424);
color: var(--light-foreground-foreground-1, color(display-p3 0.1412 0.1412 0.1412));
leading-trim: both;
text-edge: cap;
font-family: Segoe UI;
font-size: 16px;
font-style: normal;
font-weight: 600;
line-height: 22px; /* 137.5% */
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
.txtRetailer.notification {
font-size: 16px;
font-weight: 600;
}
.divTextContent {
display: flex;
flex-direction: column;
row-gap: 4px;
min-width: 0;
}
.divTextContentPWILO {
row-gap: 0px;
}
.divTextContentSmallWidth {
max-width: 80px;
}
.divNoTextGap {
display: flex;
flex-direction: column;
padding: 5px;
min-width: 0;
}
::slotted([slot="adslug"]) {
border: 1px solid var(--ad-slug-color);
color: var(--ad-slug-text-color);
border-radius: 4px;
padding: 0px 4px 1px 4px;
height: 16px;
font-weight: 400;
font-size: 11px;
text-align: center;
vertical-align: middle;
}
::slotted([slot="previous-price"]) {
text-align: end;
}
::slotted([slot="delete"]) {
position: absolute;
right: 0px;
top: 0px;
z-index: 10;
}
::slotted([slot="image"]) {
max-width: 66px;
max-height: 66px;
}
::slotted([slot="tracked-previous-price"]) {
text-decoration: line-through;
color: var(--text-neutral-foreground-hint) !important;
font-weight: 400;
}
::slotted([slot="trackingBell"]) {
position: absolute;
top: 42px;
right: 43px;
}
::slotted([slot="options"]) {
position: absolute;
top: 41.5px;
right: 18px;
z-index: 1;
}
@media (prefers-color-scheme: dark) {
${zn("grid")} :host {
--text-price-color: #f7f7f7;
--ad-slug-text-color: #ffffffd6;
}
.txtRetailer {
color: var(--text-retailer-color, #ffffff);
}
.txtRetailerV2 {
color: var(--text-retailer-color, #ffffff);
}
.txtPrice,
.txtPriceDecorative,
.txtPriceSmall,
.txtPriceDecorativeSmall {
color: var(--text-price-color, #ffffff);
}
.productCardWrapper {
border-top: var(--product-wrapper-border, 1px solid rgb(236, 236, 236, 0.08));
}
.divLowestPrice {
background: rgba(49, 191, 82, 0.1);
}
::slotted([slot="tracked-previous-price"]) {
color: var(--text-neutral-foreground-hint, #ffffff) !important;
}
}
`.withBehaviors(Gn(dn`
:host {
forced-color-adjust: auto;
}
:host .control:hover,
:host .control:${No} {
forced-color-adjust: none;
box-shadow: inset 0 0 0 calc((${qn.Han} * 1px)) ${Ns.ButtonText};
}
:host([href]),
:host([href]) .control {
color: ${Ns.LinkText};
border-color: ${Ns.LinkText};
}
:host([href]) .control:hover,
:host([href]) .control:${No} {
forced-color-adjust: none;
box-shadow: inset 0 0 0 calc((${qn.Han} * 1px)) ${Ns.LinkText};
}
::slotted([slot="image"]),
::slotted([slot="start"]),
::slotted([slot="end"]) {
color: ${Ns.ButtonText};
fill: currentcolor;
}
::slotted([slot="affiliateslug"]) {
forced-color-adjust: auto;
}
::slotted([slot="affiliateslug"]) .svg .path {
fill: ${Ns.LinkText};
}
.divLowestPrice {
z-index: 1;
outline: solid 1px;
}
`)),ql=Wl.compose({baseName:"product-card",shadowOptions:{delegatesFocus:!0},styles:Kl,template:(e,t)=>$n`
<template>
<a
class="${e=>e.isCjk?"productCardWrapperCjk":"productCardWrapper"} control ${e=>e.isFirst?"isFirst":""} ${e=>e.isNotification?"notification":""} ${e=>e.isNoAlign?"noAlign":""}"
part="control"
${vo("control")}
download="${e=>e.download}"
href="#"
hreflang="${e=>e.hreflang}"
ping="${e=>e.ping}"
title="${e=>e.title}"
referrerpolicy="${e=>e.referrerpolicy}"
rel="${e=>e.rel}"
target="${e=>e.target}"
role="listitem"
type="${e=>e.type}"
aria-atomic="${e=>e.ariaAtomic}"
aria-busy="${e=>e.ariaBusy}"
aria-controls="${e=>e.ariaControls}"
aria-current="${e=>e.ariaCurrent}"
aria-describedBy="${e=>e.ariaDescribedby}"
aria-details="${e=>e.ariaDetails}"
aria-disabled="${e=>e.ariaDisabled}"
aria-errormessage="${e=>e.ariaErrormessage}"
aria-expanded="${e=>e.ariaExpanded}"
aria-flowto="${e=>e.ariaFlowto}"
aria-haspopup="${e=>e.ariaHaspopup}"
aria-hidden="${e=>e.ariaHidden}"
aria-invalid="${e=>e.ariaInvalid}"
aria-keyshortcuts="${e=>e.ariaKeyshortcuts}"
aria-label="${e=>e.ariaLabel}"
aria-labelledby="${e=>e.ariaLabelledby}"
aria-live="${e=>e.ariaLive}"
aria-owns="${e=>e.ariaOwns}"
aria-relevant="${e=>e.ariaRelevant}"
aria-setsize="${e=>e.ariaSetSize}"
aria-posinset="${e=>e.ariaPosInSet}"
aria-roledescription="${e=>e.ariaRoledescription}">
${Wr((e=>e.hasAnnotation),$n`
<style>
.productCardWrapper {
height: 100px!important;
}
</style>
`)}
${Wr((e=>e.isRevampExpActive),$n`
<style>
.productCardWrapper {
padding: 16px !important;
}
@media (prefers-color-scheme: dark) {
.productCardWrapper {
background: #292929;
}
}
</style>
`)}
${Wr((e=>e.inCollections),$n`
<style>
.productCardWrapper {
border-top: 0!important;
}
::slotted([slot="image"]) {
max-width: 76px!important;
max-height: 76px!important;
}
@media (prefers-color-scheme: dark) {
.productCardWrapper {
border-top: none!important;
}
}
</style>
`)}
<slot name="delete"></slot>
<slot name="image"></slot>
<div class="${e=>e.isPWILOExpActive?"divTextContent divTextContentPWILO":e.inCollections?"divNoTextGap":"divTextContent"}" part="divTextContent ${e=>e.isPWILOExpActive?"divTextContentPwilo":""}">
${Wr((e=>e.description),$n`<span class="txtDescription ${e=>e.isPWILOExpActive?"txtDescriptionBold":""}" title="${e=>e.description}" style="${e=>e.isVideoCard?"-webkit-line-clamp: 3;":""}">${e=>e.description}</span>`)}
${Wr((e=>e.inCollections),$n`
<span class="divPrice" part="divPrice" style="margin-left: 0px;">
<div class="${e=>e.isCjk?"txtPriceDecorativeSmallCjk":"txtPriceDecorativeSmall"}}">
${e=>e.priceCurrency}
</div>
<div class="txtPriceSmall">
${e=>e.price}
</div>
${Wr((e=>e.priceHundredthText),$n`
<div class="${e=>e.isCjk?"txtPriceDecorativeSmallCjk":"txtPriceDecorativeSmall"}">
${e=>(e.isCjk?".":"")+e.priceHundredthText}
</div>
`)}
<slot name="tracked-previous-price"></slot>
<slot name="previous-price"></slot>
</span>
`)}
${Wr((e=>e.inCollections),$n`<slot name="end">`)}
${Wr((e=>e.isPWILOExpActive&&e.savings),$n`<div id="couponDiscount">
<span id="couponIcon">
<svg width="14" height="15" viewBox="0 0 14 15" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M8.97607 1.35238C8.42353 0.845867 7.57008 0.86441 7.04006 1.39444L0.424195 8.01051C-0.122524 8.55725 -0.122517 9.44367 0.424211 9.9904L1.35036 10.9165C1.6975 11.2637 2.19693 11.1801 2.49108 10.984C2.66528 10.8679 2.87418 10.8002 3.1001 10.8002C3.70761 10.8002 4.2001 11.2927 4.2001 11.9002C4.2001 12.1262 4.13242 12.3351 4.01631 12.5093C3.82025 12.8034 3.73665 13.3028 4.0838 13.65L4.98826 14.5544C5.54674 15.1129 6.45638 15.0991 6.99769 14.524L13.5968 7.51243C14.1317 6.94415 14.0986 6.04827 13.5234 5.52093L12.637 4.70837C12.418 4.50765 12.1409 4.46974 11.9104 4.51087C11.6834 4.55138 11.4682 4.67151 11.3128 4.84169C11.1111 5.06269 10.822 5.20044 10.5001 5.20044C9.89258 5.20044 9.4001 4.70795 9.4001 4.10044C9.4001 3.81258 9.51015 3.55132 9.69119 3.355C9.84743 3.18557 9.94851 2.96074 9.96917 2.7311C9.99015 2.49787 9.92826 2.22527 9.70942 2.02465L8.97607 1.35238Z" fill="#18AB6E"/>
</svg>
</span>
<span id ="couponText" class="txtDescription">Save ${e=>e.savings}% with coupon</span>
</div>
`)}
<msft-attribution class="divAttribution" part="divAttribution" isAffiliate=${e=>e.isAffiliate}>
${Wr((e=>!e.isPWILOExpActive),$n`<slot name="icon"></slot>`)}
<span class="txtRetailer${e=>e.isNotification?" notification":e.isRevampExpActive?"V2":""}" part="txtRetailer" style="${e=>e.isCjk?"line-height: 20px":""}" title="${e=>e.retailer}">${e=>e.retailer}</span>
${Wr((e=>e.isAd),$n`<slot name="adslug"></slot>`)}
${Wr((e=>e.isAffiliate),$n`<slot name="affiliateslug"></slot>`)}
</msft-attribution>
${Wr((e=>!e.inCollections),$n`<slot name="end">`)}
</div>
<div class="divPriceInfo" part="divPriceInfo" style="${e=>e.isCjk||e.installmentDescription?"align-items:end":""}">
${Wr((e=>e.lowest),$n`
<div class="divLowestPrice" part="divLowestPrice" style="${e=>e.isCjk?(e.isInCjkFlyout?"":"width:fit-content;")+" background-color:#DE3700; margin-bottom: 3px":""}">
<span class="txtLowestPrice" part="txtLowestPrice" style="${e=>e.isCjk?"color:#FFFFFF":""}">${e=>e.lowest}</span>
</div>
`)}
${Wr((e=>e.isRevampExpActive),$n`
<style>
.divLowestPrice {
background-color: rgba(220, 250, 237, 1) !important;
}
.txtLowestPrice {
color: rgba(15, 117, 75, 1) !important;
}
</style>`)}
${Wr((e=>e.strikethroughprice),$n`<span class="txtPriceStrikeThrough" part="divPrice">
<span>${e=>e.priceCurrency}</span>
<span>${e=>e.originalPrice}</span>
</span>`)}
${Wr((e=>!e.isPWILOExpActive&&!e.inCollections&&e.price&&e.priceCurrency),$n`
<span class="divPrice" part="divPrice">
<span part="priceCurrencySign" class="${e=>e.isCjk?"txtPriceDecorativeCjk":"txtPriceDecorative"}">${e=>e.priceCurrency}</span>
<span part= "priceValue" class="txtPrice">${e=>e.price}</span>
${Wr((e=>e.priceHundredthText),$n`<span part="priceFraction" class="${e=>e.isCjk?"txtPriceDecorativeCjk":"txtPriceDecorative"}">${e=>(e.isCjk?".":"")+e.priceHundredthText}</span>`)}
${Wr((e=>e.priceDescriptor),$n`<div part="priceDescription" class="txtPriceDescriptor">${e=>e.priceDescriptor}</div>`)}
</span>`)}
${Wr((e=>e.installmentDescription),$n`<div class="divInstallmentDescription">
${e=>e.installmentDescription}
</div>`)}
${Wr((e=>!e.isCjk&&!e.inCollections&&!e.isPWILOExpActive&&e.savings),$n`
<span class="txtSavings" part="txtSavings">
${e=>e.savings}</span>`)}
${Wr((e=>e.isCjk&&!e.inCollections&&!e.isPWILOExpActive&&!e.isPCBOffer&&e.savings),$n`
<span class="txtSavingsCJK">
${e=>e.savings}</span>`)}
<slot name="previous-price"></slot>
</div>
</a>
${Wr((e=>e.inCollections),$n`<slot name="options"></slot>`)}
${Wr((e=>e.inCollections),$n`<slot name="trackingBell"></slot>`)}
</template>
`});class Yl extends zi{constructor(){super(...arguments),this.shoppingEntities=[],this.displayedShoppingEntities=[],this.showMoreButtonVisible=!1,this.showMoreClicked=!1,this.isPolePosition=!1,this.includeSeparator=!1,this.includeAdSlug=!1,this.useMasonryGrid=!1,this.useClickableTitles=!1,this.useShowMoreClickout=!1,this.useTwoClickShowMoreClickout=!1,this.cardsVisuallyReady=0,this.showMoreCount=6,this.componentVisibleAndNeedsToHydrate=(e,t)=>{!e||e.length<1||e.find((e=>e.isIntersecting))&&this.dataFetchOnVisibleCallback&&(this.intersectionObserver&&this.intersectionObserver.disconnect(),this.dataFetchOnVisibleCallback().then(this.hydrateComponent))},this.hydrateComponent=e=>{var t;e&&e.clickoutUrl&&e.titleText&&(null===(t=e.shoppingEntities)||void 0===t?void 0:t.length)>0?(this.titleText=e.titleText,this.clickoutUrl=e.clickoutUrl,this.shoppingEntities=e.shoppingEntities):this.displayedShoppingEntities=[],this.includeAdSlug&&this.sendAdVisibilityFeedback&&this.sendAdVisibilityFeedback(this.transformEntitiesToImpressionTokens(this.displayedShoppingEntities))}}connectedCallback(){super.connectedCallback(),this.dataFetchOnVisibleCallback&&(this.intersectionObserver=new IntersectionObserver(this.componentVisibleAndNeedsToHydrate,{rootMargin:"400px"}),this.intersectionObserver.observe(this))}disconnectedCallback(){super.disconnectedCallback(),this.intersectionObserver&&this.intersectionObserver.disconnect()}transformEntitiesToImpressionTokens(e){return e.map((e=>e.impressionToken))}shoppingEntitiesChanged(e,t){if((null==t?void 0:t.length)>0){const e=Math.min(this.productsToShow,t.length);this.displayedShoppingEntities=t.slice(0,e),this.displayedShoppingEntities.length<t.length&&!this.showMoreButtonVisible?this.showMoreButtonVisible=!0:this.useMasonryGrid&&this.masonryProductsRef&&(this.masonryProductsRef.style.marginBottom="unset")}else this.productsToShow>0&&(this.displayedShoppingEntities=new Array(this.productsToShow))}productsToShowChanged(e,t){(!this.displayedShoppingEntities||0===this.displayedShoppingEntities.length)&&t>0&&(this.displayedShoppingEntities=new Array(this.productsToShow))}handleCardClick(e,t,i){return this.handleClickPingUrl&&i&&this.handleClickPingUrl(i),t.preventDefault(),t.stopPropagation(),this.navigateToDestination(e),!1}handleAdSlugClick(e){return e.preventDefault(),e.stopPropagation(),this.navigateToAdSlugDestination("https://choice.microsoft.com"),!1}handleTitleClick(e){if(this.useClickableTitles)return e.preventDefault(),e.stopPropagation(),this.navigateToTitleDestination(this.clickoutUrl),!1}handleShowMoreClick(){var e,t;if(this.useShowMoreClickout||this.useTwoClickShowMoreClickout&&this.showMoreClicked)this.navigateToTitleDestination(this.clickoutUrl);else if((null===(e=this.shoppingEntities)||void 0===e?void 0:e.length)>0&&(null===(t=this.displayedShoppingEntities)||void 0===t?void 0:t.length)>0&&this.displayedShoppingEntities.length<this.shoppingEntities.length){const e=Math.min(this.displayedShoppingEntities.length+this.showMoreCount,this.shoppingEntities.length);e===this.shoppingEntities.length&&(this.showMoreButtonVisible=!1);const t=this.shoppingEntities.slice(this.displayedShoppingEntities.length,e),i=this.displayedShoppingEntities.length;this.displayedShoppingEntities.push(...t),this.useMasonryGrid&&this.masonryProductsRef&&this.displayedShoppingEntities.length===this.shoppingEntities.length&&(this.masonryProductsRef.style.marginBottom="unset"),this.showMoreClicked=!0,this.logShowMoreButtonClicked(),requestAnimationFrame(this.focusFeedItem.bind(this,i)),this.includeAdSlug&&this.sendAdVisibilityFeedback&&this.sendAdVisibilityFeedback(this.transformEntitiesToImpressionTokens(t))}}feedItemsLeftChanged(e,t){t.length>0&&t.forEach((e=>{e.addEventListener("keydown",(t=>this.checkTabPress(t,e.getAttribute("taborder"))))}))}feedItemsRightChanged(e,t){t.length>0&&t.forEach((e=>{e.addEventListener("keydown",(t=>this.checkTabPress(t,e.getAttribute("taborder"))))}))}checkTabPress(e,t){var i,n;if("Tab"===e.key)if(this.bottomMist&&this.bottomMist.remove(),e.shiftKey){if(e.shiftKey){const i=Number(t)-1;if(i>=0){e.preventDefault();const t=null===(n=this.shadowRoot)||void 0===n?void 0:n.querySelector(`[taborder='${i}']`);null==t||t.focus()}}}else{const n=Number(t)+1;if(n<this.shoppingEntities.length){e.preventDefault();const t=n<this.displayedShoppingEntities.length?null===(i=this.shadowRoot)||void 0===i?void 0:i.querySelector(`[taborder='${n}']`):this.showMoreButton;null==t||t.focus()}}}focusFeedItem(e){var t;this.useMasonryGrid&&this.feedItemsLeft?null===(t=this.feedItemsLeft[e/2])||void 0===t||t.focus({preventScroll:!0}):this.feedItems&&e<this.feedItems.length&&this.feedItems[e].focus()}get placeholdersVisible(){var e;return this.productsToShow>0&&(null===(e=this.displayedShoppingEntities)||void 0===e?void 0:e.length)>0&&void 0===this.displayedShoppingEntities[0]}markCardVisuallyReady(){this.cardsVisuallyReady++}getShowMoreButtonText(){return this.useShowMoreClickout||this.useTwoClickShowMoreClickout&&this.showMoreClicked?this.seeAllButtonText:this.showMoreButtonText}}(0,an.gn)([oi.LO],Yl.prototype,"shoppingEntities",void 0),(0,an.gn)([oi.LO],Yl.prototype,"displayedShoppingEntities",void 0),(0,an.gn)([oi.LO],Yl.prototype,"showMoreButtonVisible",void 0),(0,an.gn)([oi.LO],Yl.prototype,"navigateToTitleDestination",void 0),(0,an.gn)([oi.LO],Yl.prototype,"navigateToDestination",void 0),(0,an.gn)([oi.LO],Yl.prototype,"navigateToAdSlugDestination",void 0),(0,an.gn)([oi.LO],Yl.prototype,"handleClickPingUrl",void 0),(0,an.gn)([oi.LO],Yl.prototype,"logShowMoreButtonClicked",void 0),(0,an.gn)([oi.LO],Yl.prototype,"sendAdVisibilityFeedback",void 0),(0,an.gn)([oi.LO],Yl.prototype,"dataFetchOnVisibleCallback",void 0),(0,an.gn)([oi.LO],Yl.prototype,"feedItems",void 0),(0,an.gn)([oi.LO],Yl.prototype,"feedItemsLeft",void 0),(0,an.gn)([oi.LO],Yl.prototype,"feedItemsRight",void 0),(0,an.gn)([oi.LO],Yl.prototype,"productsToShow",void 0),(0,an.gn)([oi.LO],Yl.prototype,"showMoreClicked",void 0),(0,an.gn)([pn.Lj],Yl.prototype,"titleText",void 0),(0,an.gn)([pn.Lj],Yl.prototype,"clickoutUrl",void 0),(0,an.gn)([pn.Lj],Yl.prototype,"showMoreButtonText",void 0),(0,an.gn)([pn.Lj],Yl.prototype,"seeAllButtonText",void 0),(0,an.gn)([pn.Lj],Yl.prototype,"adSlugText",void 0),(0,an.gn)([pn.Lj],Yl.prototype,"productCardAdSlugText",void 0),(0,an.gn)([pn.Lj],Yl.prototype,"adSlugPolicyText",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"is-pole-position",mode:"boolean"})],Yl.prototype,"isPolePosition",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"include-separator",mode:"boolean"})],Yl.prototype,"includeSeparator",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"include-ad-slug",mode:"boolean"})],Yl.prototype,"includeAdSlug",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"use-masonry-grid",mode:"boolean"})],Yl.prototype,"useMasonryGrid",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"use-clickable-titles",mode:"boolean"})],Yl.prototype,"useClickableTitles",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"use-show-more-clickout",mode:"boolean"})],Yl.prototype,"useShowMoreClickout",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"use-two-click-show-more-clickout",mode:"boolean"})],Yl.prototype,"useTwoClickShowMoreClickout",void 0),(0,an.gn)([oi.lk],Yl.prototype,"placeholdersVisible",null);const Xl=dn`
:host {
font-family: ${qn.SVJ};
}
.section-separator {
width: 100vw;
border: 1px solid #000000;
opacity: 0.04;
margin-bottom: 0px;
margin-top: 0px;
border-bottom: unset;
left: 0px;
right: 0px;
}
@media (prefers-color-scheme: dark) {
.section-separator {
opacity: 0.08;
}
}
.anchor-wrapper {
text-decoration: none;
color: ${qn.CHi};
border-radius: 8px;
cursor: pointer;
}
.anchor-wrapper:active {
color: ${qn.CHi};
}
.product-card {
width: var(--card-width);
box-shadow: none;
border-radius: 8px;
background-color: ${qn.wFS};
display: block;
}
.product-card:hover {
box-shadow: 0px 3px 6px rgba(0, 0, 0, 0.12);
border-radius: 8px;
}
.product-feed-container {
--product-feed-padding: 20px;
--products-gap: 12px;
--feed-width: calc(100vw - var(--scrollbar-width));
--feed-without-spacing: calc(calc(var(--feed-width) - var(--products-gap)) - calc(var(--product-feed-padding)) * 2);
--card-width: calc(var(--feed-without-spacing) / 2);
padding: var(--product-feed-padding) var(--product-feed-padding) 0px;
background: var(--product-feed-background, unset);
}
.product-feed-heading {
height: 24px;
margin-bottom: 12px;
display: flex;
gap: 24px;
justify-content: space-between;
}
.product-feed-heading h2 {
font-weight: 600;
font-size: 18px;
line-height: 24px;
margin: 0;
flex-grow: 1;
text-overflow: ellipsis;
overflow: hidden;
white-space: nowrap;
display: inline;
}
.product-feed-heading svg path {
fill: ${qn.CHi};
}
.product-feed-heading-title-wrapper {
text-decoration: none;
color: ${qn.CHi};
cursor: pointer;
}
.product-feed-heading-title-wrapper:hover, .product-feed-heading-title-wrapper:active, .product-feed-heading-title-wrapper:focus {
text-decoration: underline;
cursor: pointer;
}
.ad-slug-container {
display: flex;
justify-content: flex-end;
}
.ad-slug {
display: flex;
align-items: center;
border: 1px solid #d3d3d3;
border-radius: 5px;
margin-top: 4px;
}
.ad-slug-text {
font-size: 12px;
padding-left: 4px;
padding-right: 4px;
white-space: nowrap;
color: var(--text-normal);
}
.products {
display: flex;
flex-wrap: wrap;
flex-direction: row;
gap: var(--products-gap);
width: var(--feed-width);
}
.products-masonry-container .products {
margin-bottom: calc(var(--card-width) / -2);
}
.products-masonry-column-left, .products-masonry-column-right {
width: var(--card-width);
display: flex;
flex-direction: column;
gap: 12px;
}
.products-masonry-column-left .product-card, .products-masonry-column-left .product-card.placeholder, .products-masonry-column-right .product-card, .products-masonry-column-right .product-card.placeholder {
width: 100%;
height: calc(var(--card-width) * 1.5);
}
.products-masonry-column-left .product-image-container, .products-masonry-column-right .product-image-container {
flex-grow: 1;
overflow: hidden;
}
.products-masonry-column-right a:first-child .product-card, .products-masonry-column-right .product-card.placeholder:first-child {
height: calc(var(--card-width) * 1);
}
.products-masonry-container {
position: relative;
overflow: hidden;
border-radius: 8px;
height: auto;
}
:host([is-pole-position=true]) .products:last-child {
margin-bottom: 12px;
}
.products:last-child {
padding-bottom: 24px;
}
.product-card.placeholder {
height: calc(var(--card-width) + 70px); // 70px is approximately height of product-info
border-radius: 8px;
background-color: ${qn.wFS};
}
.card-inner {
display: flex;
flex-direction: column;
height: 100%;
border-radius: 8px;
overflow: auto;
position: relative;
}
.product-image-container {
background: rgb(255, 255, 255);
}
.product-info {
padding: 8px 12px;
}
.bottom-mist {
height: 48px;
background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.4) 29.69%, rgba(255, 255, 255, 1) 100%);
z-index: 100;
position: absolute;
width: 100%;
bottom: 0px;
left: 0px;
pointer-events: none;
}
.title {
display: -webkit-box;
-webkit-line-clamp: 1;
-webkit-box-orient: vertical;
white-space: normal;
overflow: hidden;
height: 16px;
font-size: ${qn.sNp};
line-height: ${qn.vgC};
word-break: break-all;
}
.seller-and-slug {
padding-top: 2px;
display: flex;
gap: 4px;
white-space: normal;
overflow: hidden;
height: 16px;
}
.seller {
word-break: break-all;
color: ${qn.Q5n};
font-size: ${qn.sNp};
line-height: ${qn.vgC};
}
.price {
display: flex;
gap: 6px;
align-items: flex-end;
}
.current-price {
font-weight: 600;
display: flex;
align-items: flex-start;
}
.current-price.sale {
color: #DE3700;
}
.current-price-hundredth {
padding-top: 1px;
padding-left: 1px;
font-size: ${qn.G8g};
line-height: ${qn.MwG};
}
@media
(-webkit-min-device-pixel-ratio: 1.5),
(min-resolution: 144dpi){
.current-price-hundredth {
padding-top: 2px;
}
}
.previous-price {
padding-bottom: 2px;
text-decoration-line: line-through;
font-size: ${qn.G8g};
line-height: ${qn.MwG};
}
.show-more-container {
display: flex;
justify-content: center;
margin-top: 12px;
margin-bottom: 24px;
}
.no-margin {
margin-bottom: 12px!important;
}
.show-more-button {
width: 100%;
border-radius: 8px;
}
.show-more-button.placeholder {
background: ${qn.wFS};
height: 32px;
padding: 2px 0;
border-radius: 8px;
}
.show-more-button-inner {
display: flex;
align-items: center;
gap: 10px;
}
.show-more-button-inner path {
fill: ${qn.CHi};
}
.decoration {
padding: 2px 5px;
position: absolute;
top: 8px;
left: 8px;
background: rgba(0, 0, 0, 0.7);
border-radius: 6px;
display: flex;
align-items: center;
gap: 4px;
color: #FFF;
}
.decoration-text {
font-size: ${qn.sNp};
line-height: ${qn.vgC};
}
.decoration svg {
display: inline-block;
padding-top: 1px;
height: 12px;
width: 12px;
fill: #FFFFFF;
}
.show-more-button:hover {
box-shadow: 0px 3px 6px rgba(0, 0, 0, 0.12);
}
@media (prefers-color-scheme: dark) {
.current-price.sale {
color: #FA9370;
}
.product-feed-container {
background: var(--product-feed-background-dark, unset);
}
}
@media (-ms-high-contrast: active) {
.product-card {
border: 1px solid linkText;
color: linkText;
}
.product-card:hover {
outline: 1px solid highlight;
}
.decoration {
background: #000;
}
.seller, .current-price.sale, .previous-price, .decoration-text {
color: linkText;
}
.ad-slug {
border: 1px solid linkText;
}
.ad-slug-text {
color: linkText;
}
.decoration svg {
fill: linkText;
}
.show-more-button-inner path {
fill: buttonText;
}
.bottom-mist {
display: none;
}
.product-feed-heading svg path {
fill: linkText;
}
.product-feed-heading-title-wrapper {
color: linkText;
text-decoration: underline;
}
}
`;var Jl=o(56764);function Ql(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function ec(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Ql(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Ql(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}class tc{static async fetchFrom1S(e,n,o){try{const t=await fetch(e),i=await t.json(),n=JSON.parse(i[0].data);return n.metadata=ec(ec({},n.metadata),i[0]?.metadata),n}catch(r){const a=this.createErrorMessage("Fetch from 1S failed",e,void 0,r);return void(o&&o.LogErrorEvent(i.R.EdgeFlyoutStatus,a,new t.Z(n),Jl.g.EdgeImpressionId))}}static createErrorMessage(e,t,i,n){const o={message:n?`${e} | ${n}`:e};return t&&(o.url=t),void 0!==i&&i.length>0&&(o.emptyKeys=i),JSON.stringify(o)}}const ic=$n`
<svg width="12" height="7" viewBox="0 0 12 7" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M5.99984 4.94948L1.60844 0.558118C1.36437 0.314042 0.968636 0.314042 0.724561 0.558118C0.480485 0.802193 0.480485 1.19793 0.724561 1.442L0.724561 1.442L5.55791 6.27531C5.802 6.5194 6.19768 6.5194 6.44176 6.27531L11.2751 1.442C11.5192 1.19793 11.5192 0.802192 11.2751 0.558116C11.031 0.314043 10.6353 0.314043 10.3913 0.558116L5.99984 4.94948Z" fill="#202124" stroke="#202124" stroke-width="0.25"/>
</svg>
`,nc=$n`
<svg width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
<path d="M8.08674 2.19636L2.19583 8.08727C1.94493 8.33818 1.94493 8.75273 2.19583 9.01455L6.99583 13.8145C7.24674 14.0655 7.66129 14.0655 7.92311 13.8145L13.814 7.92364C13.934 7.79273 13.9995 7.62909 13.9995 7.45455V2.65455C13.9995 2.29455 13.7049 2 13.3449 2H8.54493C8.37038 2 8.20674 2.06545 8.08674 2.19636ZM12.2431 5.32727C12.1777 5.46909 12.0904 5.6 11.9813 5.70909C11.8722 5.81818 11.7522 5.90545 11.5995 5.96C11.4467 6.01455 11.3049 6.05818 11.1413 6.05818C10.9777 6.05818 10.814 6.02545 10.6722 5.96C10.5304 5.90545 10.3995 5.81818 10.2904 5.70909C10.1813 5.6 10.094 5.46909 10.0395 5.32727C9.97402 5.18545 9.94129 5.03273 9.94129 4.85818C9.94129 4.68364 9.97402 4.53091 10.0395 4.38909C10.094 4.25818 10.1813 4.12727 10.2904 4.02909C10.3995 3.92 10.5304 3.83273 10.6722 3.76727C10.814 3.70182 10.9667 3.66909 11.1413 3.66909C11.3158 3.66909 11.4686 3.70182 11.6104 3.76727C11.7522 3.83273 11.8831 3.92 11.9813 4.02909C12.0904 4.13818 12.1777 4.25818 12.2431 4.4C12.3086 4.54182 12.3413 4.69455 12.3413 4.86909C12.3413 5.04364 12.2977 5.18545 12.2431 5.32727Z"></path>
</svg>
`,oc=$n`
<svg width="5" height="9" viewBox="0 0 5 9" fill="none" xmlns="http://www.w3.org/2000/svg" aria-hidden=true>
<path d="M0.646447 0.646447C0.451184 0.841709 0.451184 1.15829 0.646447 1.35355L3.79289 4.5L0.646447 7.64645C0.451185 7.84171 0.451185 8.15829 0.646447 8.35355C0.841709 8.54882 1.15829 8.54882 1.35355 8.35355L4.85355 4.85355C5.04882 4.65829 5.04882 4.34171 4.85355 4.14645L1.35355 0.646447C1.15829 0.451184 0.841709 0.451184 0.646447 0.646447Z" fill="#212121"/>
</svg>
`,rc=$n`
<svg width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M2.49999 1C1.67157 1 0.999995 1.67157 0.999995 2.5V9.5C0.999995 10.3284 1.67157 11 2.49999 11H9.49996C10.3284 11 10.9999 10.3284 10.9999 9.5V7.26923C10.9999 6.99309 11.2238 6.76923 11.4999 6.76923C11.7761 6.76923 11.9999 6.99309 11.9999 7.26923V9.5C11.9999 10.8807 10.8807 12 9.49996 12H2.49999C1.11928 12 0 10.8807 0 9.5V2.5C0 1.11929 1.11928 0 2.49999 0H4.73075C5.00689 0 5.23074 0.223858 5.23074 0.5C5.23074 0.776142 5.00689 1 4.73075 1H2.49999ZM6.76926 0.5C6.76926 0.223858 6.99311 0 7.26925 0H11.5C11.7761 0 12 0.223858 12 0.5V4.73077C12 5.00691 11.7761 5.23077 11.5 5.23077C11.2239 5.23077 11 5.00691 11 4.73077V1.70711L7.6228 5.08433C7.42754 5.27959 7.11096 5.27959 6.9157 5.08433C6.72044 4.88906 6.72044 4.57248 6.9157 4.37722L10.2929 1H7.26925C6.99311 1 6.76926 0.776142 6.76926 0.5Z" fill="#202124" stroke="#202124" stroke-width="0.25"/>
</svg>
`,ac=$n`
<div class="decoration">
${nc}
<div class="decoration-text">
${e=>e.dealPercentageLocalized}
</div>
</div>
`,sc=$n`
<div class="seller-and-slug">
<div class="seller">${e=>e.seller}</div>
${Wr(((e,t)=>e.adType&&!t.parent.includeAdSlug),$n`
<div class="ad-slug">
<span class="ad-slug-text" @click=${(e,t)=>t.parent.handleAdSlugClick(t.event)}>${(e,t)=>t.parent.productCardAdSlugText}</span>
</div>
`)}
</div>
`,lc=$n`
<a
taborder="${e=>e.tabOrder}"
class="anchor-wrapper"
target="_blank"
@click=${(e,t)=>t.parent.handleCardClick(e.destination,t.event,e.clickPingUrl)}
href="${e=>e.destination}"
aria-label="${e=>e.altText}">
<fluent-card class="product-card" aria-hidden="true">
${Wr((e=>"SimilarOffers"===e.adType),$n`<div class="ad-slug-wrapper">
<img aria-label="Ad" class="ad-slug" slot="adslug" src="https://www.bing.com/api/shopping/v1/ux/images/priceComparison/adSlug.png"/>
</div>`)}
<div class="card-inner">
${Wr((e=>e.dealPercentage),ac)}
<div class="product-image-container">
<msft-shopping-image
:onImageLoad="${(e,t)=>t.parent.markCardVisuallyReady.bind(t.parent)}"
src="${e=>{var t;return null===(t=e.imageInfo)||void 0===t?void 0:t.sourceImageUrl}}${(e,t)=>t.parent.useMasonryGrid?"":"&w=304&h=304"}"
alt="${e=>e.title}"
aria-label="${e=>e.title}"
/>
</div>
<div class="product-info">
${Wr((e=>e.priceInfo),$n`
<div class="price">
<div class="current-price${e=>e.priceInfo.originalPrice?" sale":""}">
<div class="current-price-currency">
${e=>e.priceInfo.priceCurrencySymbol}
</div>
<div class="current-price-int">
${e=>e.priceInfo.priceIntText}
</div>
<div class="current-price-hundredth">
${e=>e.priceInfo.priceHundredthText}
</div>
</div>
${Wr((e=>e.priceInfo.originalPrice),$n`
<div class="previous-price">
${e=>e.priceInfo.originalPrice}
</div>
`)}
</div>
`)}
<div class="title">${e=>e.title}</div>
${sc}
</div>
</div>
</fluent-card>
</a>
`,cc=$n`
<fluent-card class="product-card placeholder">
<div class="card-inner">
</div>
</fluent-card>
`,dc=$n`
${Wr((e=>e),lc)}
${Wr((e=>!e),cc)}
`,uc=$n`
<div class="ad-slug">
<span class="ad-slug-text">${e=>e.adSlugText}</span>
</div>
`,hc=$n`
<div class="ad-slug-container">
<a href="https://choice.microsoft.com" class="anchor-wrapper" target="_blank" aria-label="${e=>e.adSlugPolicyText}">
${uc}
</a>
</div>
`,pc=$n`
<div class="products" ${Qs({property:"feedItems",filter:wo("a.anchor-wrapper")})}>
${Sl((e=>e.displayedShoppingEntities),dc)}
</div>
`,gc=$n`
<span class="bottom-mist" ${vo("bottomMist")}/>
`,fc=$n`
<div class="products-masonry-column-left" ${Qs({property:"feedItemsLeft",filter:wo("a.anchor-wrapper")})}>
${Sl((e=>e.displayedShoppingEntities),$n`${Wr(((e,t)=>t.isEven),dc)}`,{positioning:!0})}
</div>
`,mc=$n`
<div class="products-masonry-column-right" ${Qs({property:"feedItemsRight",filter:wo("a.anchor-wrapper")})}>
${Sl((e=>e.displayedShoppingEntities),$n`${Wr(((e,t)=>t.isOdd),dc)}`,{positioning:!0})}
</div>
`,vc=$n`
<div class="products-masonry-container">
${$n`
<div class="products" ${vo("masonryProductsRef")}>
${fc}
${mc}
</div>
`}
${Wr((e=>e.showMoreButtonVisible),gc)}
</div>
`,yc=$n`
<a
class="product-feed-heading-title-wrapper"
@click="${(e,t)=>e.handleTitleClick(t.event)}"
href="${e=>e.clickoutUrl}"
aria-label="${e=>`${e.getShowMoreButtonText()} ${e.titleText}`}">
<h2 aria-hidden=true>${Wr((e=>e.titleText),$n`${e=>e.titleText}`)}</h2>
${Wr((e=>e.useClickableTitles&&!e.placeholdersVisible),oc)}
</a>
`,Cc=$n`
<h2>${Wr((e=>e.titleText),$n`${e=>e.titleText}`)}</h2>
`,bc=$n`
<div class="product-feed-heading">
${Wr((e=>e.useClickableTitles),yc)}
${Wr((e=>!e.useClickableTitles),Cc)}
${Wr((e=>e.includeAdSlug),hc)}
</div>
`,Sc=Yl.compose({baseName:"product-feed",shadowOptions:{delegatesFocus:!0},styles:Xl,template:(e,t)=>$n`
<template>
${Wr((e=>{var t;return(null===(t=e.displayedShoppingEntities)||void 0===t?void 0:t.length)>0}),$n`
<div class="product-feed-container">
<slot name="product-feed-heading">
${bc}
</slot>
${Wr((e=>!e.useMasonryGrid),pc)}
${Wr((e=>e.useMasonryGrid),vc)}
${Wr((e=>e.showMoreButtonVisible),$n`
<div class="show-more-container ${e=>e.isPolePosition?"no-margin":""}">
<fluent-button aria-label="${e=>`${e.getShowMoreButtonText()} ${e.titleText}`}" class="show-more-button" @click="${e=>e.handleShowMoreClick()}" ${vo("showMoreButton")}>
<div class="show-more-button-inner">
<div>
${e=>e.getShowMoreButtonText()}
</div>
<div class="show-more-button-arrow">
${Wr((e=>e.useShowMoreClickout||e.useTwoClickShowMoreClickout&&e.showMoreClicked),rc)}
${Wr((e=>!(e.useShowMoreClickout||e.useTwoClickShowMoreClickout&&e.showMoreClicked)),ic)}
</div>
</div>
</fluent-button>
</div>
`)}
${Wr((e=>!e.showMoreButtonVisible&&e.placeholdersVisible),$n`
<div class="show-more-container ${e=>e.isPolePosition?"no-margin":""}">
<div class="show-more-button placeholder">
</div>
</div>
`)}
</div>
${Wr((e=>e.includeSeparator),$n`
<hr class="section-separator" aria-hidden="true">
`)}
`)}
</template>
`}),xc=Object.freeze({Wishlist:"Wishlist"});class Tc extends zi{}(0,an.gn)([oi.LO],Tc.prototype,"icon",void 0),(0,an.gn)([oi.LO],Tc.prototype,"text",void 0),(0,an.gn)([oi.LO],Tc.prototype,"linkHref",void 0),(0,an.gn)([oi.LO],Tc.prototype,"linkAria",void 0),(0,an.gn)([oi.LO],Tc.prototype,"linkText",void 0),(0,an.gn)([oi.LO],Tc.prototype,"linkClickCallback",void 0);const wc=dn`
:host {
font-family: ${qn.SVJ};
}
.setting-wrapper {
display: flex;
flex-direction: row;
padding: 12px 16px;
gap: 12px;
border-radius: 8px;
background-color: ${qn.wFS};
align-items: center;
}
.card-icon {
background: #E0EDFF;
height: 30px;
width: 30px;
min-width: 30px;
border-radius: 15px;
display: flex;
align-items: center;
justify-content: center;
}
.card-icon path {
fill: #2169EB;
}
.card-text-and-link {
flex-grow: 1;
width: 0px;
}
.card-text {
text-overflow: ellipsis;
overflow: hidden;
white-space: nowrap;
}
.card-link {
text-decoration: none;
font-size: ${qn.sNp};
line-height: ${qn.vgC};
color: ${qn.Avx};
}
.card-link:hover {
text-decoration: underline;
}
@media (prefers-color-scheme: dark) {
}
@media (-ms-high-contrast: active) {
}
`,Oc=$n`
<svg aria-hidden="true" xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none">
<path d="M15.5008 6.99918C16.8263 6.99918 17.9108 8.03071 17.9955 9.3348L18.0008 9.49918V10.256C17.6937 10.0024 17.3586 9.7815 17.0008 9.59864V9.49918C17.0008 8.71948 16.4059 8.07873 15.6453 8.00604L15.5008 7.99918H9.50113C8.72144 7.99918 8.08068 8.59407 8.008 9.35472L8.00113 9.49918V15.4989C8.00113 16.2785 8.59602 16.9193 9.35667 16.992L9.50113 16.9989H9.60078C9.78365 17.3566 10.0045 17.6917 10.2581 17.9989H9.50113C8.17565 17.9989 7.09109 16.9673 7.00645 15.6632L7.00113 15.4989V9.49918C7.00113 8.17369 8.03267 7.08914 9.33676 7.0045L9.50113 6.99918H15.5008ZM12.663 3.69422L12.7107 3.85162L13.286 5.99905H12.25L11.7448 4.11044C11.543 3.35731 10.8025 2.89236 10.0489 3.01902L9.90763 3.04978L4.11239 4.60261C3.35926 4.80441 2.89431 5.54487 3.02098 6.29841L3.05173 6.43973L4.60456 12.235C4.77949 12.8878 5.35918 13.3241 6.00129 13.3462L6.00141 14.3468C4.97445 14.3259 4.03721 13.6687 3.69081 12.6643L3.63864 12.4938L2.08581 6.69855C1.74275 5.41823 2.45843 4.10365 3.69617 3.68436L3.85357 3.63668L9.64881 2.08385C10.8758 1.75509 12.1342 2.39867 12.606 3.54226L12.663 3.69422ZM19.0012 14.4991C19.0012 16.9844 16.9865 18.9991 14.5012 18.9991C12.0159 18.9991 10.0012 16.9844 10.0012 14.4991C10.0012 12.0139 12.0159 9.99915 14.5012 9.99915C16.9865 9.99915 19.0012 12.0139 19.0012 14.4991ZM15.0012 12.4991C15.0012 12.223 14.7774 11.9991 14.5012 11.9991C14.2251 11.9991 14.0012 12.223 14.0012 12.4991V13.9991H12.5012C12.2251 13.9991 12.0012 14.223 12.0012 14.4991C12.0012 14.7753 12.2251 14.9991 12.5012 14.9991H14.0012V16.4991C14.0012 16.7753 14.2251 16.9991 14.5012 16.9991C14.7774 16.9991 15.0012 16.7753 15.0012 16.4991V14.9991H16.5012C16.7774 14.9991 17.0012 14.7753 17.0012 14.4991C17.0012 14.223 16.7774 13.9991 16.5012 13.9991H15.0012V12.4991Z" />
</svg>
`,Pc={[xc.Wishlist]:Oc},Ac=Tc.compose({baseName:"setting-module",shadowOptions:{delegatesFocus:!1},styles:wc,template:(e,t)=>$n`
<template>
${Wr((e=>e.text&&e.icon&&e.linkText&&e.linkHref&&e.linkAria),$n`
<div class="setting-wrapper">
<div class="card-icon">${e=>Pc[e.icon]}</div>
<div class="card-text-and-link">
<div class="card-text">${e=>e.text}</div>
<div class="card-link-wrapper">
<a
class="card-link"
target="_blank"
href="${e=>e.linkHref}"
aria-label="${e=>e.linkAria}"
@click=${(e,t)=>e.linkClickCallback(t.event,e.linkHref)}>
${e=>e.linkText}
</a>
</div>
</div>
<slot name="control"></slot>
</div>
`)}
</template>
`});class Ec extends zi{connectedCallback(){super.connectedCallback()}}function kc(e){try{return JSON.parse(e.imageSrcs)}catch(e){return[]}}(0,an.gn)([pn.Lj],Ec.prototype,"name",void 0),(0,an.gn)([pn.Lj],Ec.prototype,"subTitle",void 0),(0,an.gn)([pn.Lj],Ec.prototype,"iconSrc",void 0),(0,an.gn)([pn.Lj],Ec.prototype,"imageSrcs",void 0),(0,an.gn)([pn.Lj],Ec.prototype,"isClickable",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"label"})],Ec.prototype,"label",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"more-items-label"})],Ec.prototype,"moreItemsLabel",void 0),(0,an.gn)([oi.LO],Ec.prototype,"childElements",void 0);const Ic=(e,t)=>$n`
${e=>(0,p.TF)(e.iconSrc)?"":$n`<img class="icon" src="${e.iconSrc}" aria-hidden="true"></img>`}
<div class="details">
<h3 class="text">${e=>e.title}</h3>
<p class="text">${e=>e.subTitle}</p>
<slot name="description" class="text"></slot>
<div class="productList ${e=>"true"===e.isClickable?"clickable":"unclickable"}" part="productList">
${Sl((e=>kc(e)),$n`
${Wr(((e,t)=>t.length<5||t.index<3),$n`
<div
class="product"
style="${e=>`background-image: ${function(e){const t=`linear-gradient(0deg, rgba(0, 0, 0, 0.03), rgba(0, 0, 0, 0.03)), url('${e.ImageUrl}')`,i=`linear-gradient(0deg, rgba(0, 0, 0, 0.2), rgba(0, 0, 0, 0.2)), url('${e.ImageUrl}')`;return window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?i:t}(e)};`}"
aria-label="${e=>{var t;return null!==(t=e.Title)&&void 0!==t?t:""}}"
>
</div>
`)}
`,{positioning:!0})}
${Wr((e=>{var t;return(null===(t=kc(e))||void 0===t?void 0:t.length)>4}),$n`
<div
class="product"
style="background-image: linear-gradient(0deg, rgba(0, 0, 0, 0.03), rgba(0, 0, 0, 0.03));"
aria-label="+${e=>{var t;return(null===(t=kc(e))||void 0===t?void 0:t.length)-3}} ${e=>{var t;return null!==(t=e.moreItemsLabel)&&void 0!==t?t:""}}"
>
+${e=>{var t;return(null===(t=kc(e))||void 0===t?void 0:t.length)-3}}
</div>
`)}
</div>
</div>
<slot name="options"></slot>
`,Dc=Ec.compose({baseName:"shopping-cart",shadowOptions:{delegatesFocus:!0},styles:(e,t)=>dn`
.control {
background: var(--fill-color);
border-radius: 8px;
box-shadow: 0px 0px 2px 0px rgba(0, 0, 0, 0.12), 0px 1px 2px 0px rgba(0, 0, 0, 0.14);
margin-bottom: 20px;
display: flex;
flex-direction: row;
column-gap: 12px;
text-align: left;
font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;
border: none;
width: -webkit-fill-available;
}
.control:focus {
outline: 2px solid #898989;
}
.icon {
height: 20px;
}
.details {
display: flex;
flex-direction: column;
row-gap: 2px;
}
.text {
font-weight: 600;
font-size: 14px;
line-height: 20px;
margin: 0px;
}
.clickable {
column-gap: 10px;
}
.unclickable {
column-gap: 16px;
}
.productList {
margin-top: 12px;
display: flex;
flex-direction: row;
}
.clickable > .product {
height: 60px;
width: 60px;
}
::slotted([slot="options"]) {
position: absolute;
top: 0px;
right: 0px;
}
.unclickable > .product {
height: 48px;
width: 48px;
}
.product {
background-color: #FFFFFF;
background-position: center;
background-size: cover;
border-radius: 8px;
font-weight: 400;
font-size: 20px;
text-align: center;
color: #000000;
display: flex;
justify-content: center;
align-items: center;
overflow: hidden;
place-self: center;
}
@media (prefers-color-scheme: dark) {
button.control {
background-color: #414141;
}
.text {
color: #FFFFFF;
}
};`,template:(e,t)=>$n`
<template>
${e=>{var t,i,n,o;return"true"===e.isClickable?$n`
<button
class="control"
part="control"
style="cursor: pointer; padding: 12px;"
aria-label="${null!==(t=e.subTitle)&&void 0!==t?t:""} ${null!==(i=e.label)&&void 0!==i?i:""}"
>
${Ic}
</button>`:$n`
<div
class="control"
part="control"
style="cursor: default;"
aria-label="${null!==(n=e.subTitle)&&void 0!==n?n:""} ${null!==(o=e.label)&&void 0!==o?o:""}"
>
${Ic}
</div>`}}
</template>
`});var _c;!function(e){e.grid="grid",e.carousel="carousel"}(_c||(_c={}));class Nc extends Qo{constructor(){super(...arguments),this.noHoverGradient=!1}handleImageContentChange(){this.control.classList.toggle("has-image",this.image.assignedNodes().length>0)}}(0,an.gn)([pn.Lj],Nc.prototype,"layout",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"no-hover-gradient",mode:"boolean"})],Nc.prototype,"noHoverGradient",void 0);const Rc=Nc.compose({baseName:"shopping-cashback-card",shadowOptions:{delegatesFocus:!0},styles:(e,t)=>dn`
${zn("block")} :host {
outline: none;
font-family: ${qn.SVJ};
font-size: ${qn.G8g};
font-weight: 400;
line-height: ${qn.MwG};
min-width: calc(${Lo} * 1px);
border-radius: calc((${qn.rSr} * 1px) * 2);
box-sizing: border-box;
color: ${qn.CHi};
cursor: pointer;
background: ${qn.IfY};
}
.control {
display: grid;
grid-template-rows: 42px minmax(16px, 1fr);
grid-gap: 6px;
justify-content: center;
align-items: center;
box-sizing: border-box;
border: calc(${qn.Han} * 1px) solid ${qn.dtw};
border-radius: inherit;
padding: 8px 23px 24px;
width: 100%;
outline: none;
text-decoration: none;
color: inherit;
cursor: inherit;
font-family: inherit;
overflow: hidden;
}
.control:${No} {
box-shadow: 0 0 0 calc(${qn.vxp} * 1px) ${qn.yGg};
}
.control:active {
background-color: ${qn.Gy2};
}
.control:hover {
background: linear-gradient(265.08deg, rgba(36, 255, 0, 0.06) -6.71%, rgba(0, 210, 255, 0.06) 38.87%, rgba(255, 188, 125, 0.06) 93.88%);
}
:host([no-hover-gradient]) .control {
background: transparent;
}
.control:not(.has-image) {
display: flex;
min-height: 97px;
padding: 18px 23px;
}
:host([layout="carousel"]) .control {
grid-template-rows: 56px 50px;
padding: 0 12px 12px;
}
.content {
display: flex;
flex-direction: column;
align-items: center;
justify-content: space-between;
max-height: 50px;
}
.action-container {
display: flex;
align-items: center;
justify-content: center;
margin-top: 12px;
width: 102px;
height: 26px;
overflow: hidden;
background: var(--accent-fill-muted-rest);
border: 1px solid transparent;
border-radius: calc(${qn.UWU} * 1px);
color: ${qn.goi};
}
.action-message {
font-weight: 600;
}
::slotted(*) {
display: flex;
align-items: center;
justify-content: center;
min-height: 16px;
text-align: center;
}
::slotted([slot="image"]) {
align-self: center;
justify-self: center;
max-width: 100%;
max-height: 100%;
}
`.withBehaviors(Gn(dn`
:host {
forced-color-adjust: auto;
}
:host .control:hover,
:host .control:${No} {
forced-color-adjust: none;
box-shadow: inset 0 0 0 calc((${qn.Han} * 1px)) ${Ns.ButtonText};
}
:host([href]),
:host([href]) .control {
color: ${Ns.LinkText};
border-color: ${Ns.LinkText};
}
:host([href]) .control:hover,
:host([href]) .control:${No} {
forced-color-adjust: none;
box-shadow: inset 0 0 0 calc((${qn.Han} * 1px)) ${Ns.LinkText};
}
::slotted([slot="image"]),
::slotted([slot="start"]),
::slotted([slot="end"]) {
color: ${Ns.ButtonText};
fill: currentcolor;
}
`)),template:(e,t)=>$n`
<a
class="control"
part="control"
${vo("control")}
download="${e=>e.download}"
href="${e=>e.href}"
hreflang="${e=>e.hreflang}"
ping="${e=>e.ping}"
referrerpolicy="${e=>e.referrerpolicy}"
rel="${e=>e.rel}"
target="${e=>e.target}"
type="${e=>e.type}"
aria-atomic="${e=>e.ariaAtomic}"
aria-busy="${e=>e.ariaBusy}"
aria-controls="${e=>e.ariaControls}"
aria-current="${e=>e.ariaCurrent}"
aria-describedBy="${e=>e.ariaDescribedby}"
aria-details="${e=>e.ariaDetails}"
aria-disabled="${e=>e.ariaDisabled}"
aria-errormessage="${e=>e.ariaErrormessage}"
aria-expanded="${e=>e.ariaExpanded}"
aria-flowto="${e=>e.ariaFlowto}"
aria-haspopup="${e=>e.ariaHaspopup}"
aria-hidden="${e=>e.ariaHidden}"
aria-invalid="${e=>e.ariaInvalid}"
aria-keyshortcuts="${e=>e.ariaKeyshortcuts}"
aria-label="${e=>e.ariaLabel}"
aria-labelledby="${e=>e.ariaLabelledby}"
aria-live="${e=>e.ariaLive}"
aria-owns="${e=>e.ariaOwns}"
aria-relevant="${e=>e.ariaRelevant}"
aria-roledescription="${e=>e.ariaRoledescription}"
>
<slot
name="image"
${vo("image")}
@slotchange="${e=>e.handleImageContentChange()}"
></slot>
<div class="content" part="content">
<slot> </slot>
</div>
</a>
`});var Mc="object"==typeof global&&global&&global.Object===Object&&global,Lc="object"==typeof self&&self&&self.Object===Object&&self,Bc=(Mc||Lc||Function("return this")()).Symbol,Fc=Array.isArray,Uc=Object.prototype,Hc=Uc.hasOwnProperty,$c=Uc.toString,Zc=Bc?Bc.toStringTag:void 0,Vc=Object.prototype.toString,Gc=Bc?Bc.toStringTag:void 0,jc=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":Gc&&Gc in Object(e)?function(e){var t=Hc.call(e,Zc),i=e[Zc];try{e[Zc]=void 0;var n=!0}catch(e){}var o=$c.call(e);return n&&(t?e[Zc]=i:delete e[Zc]),o}(e):function(e){return Vc.call(e)}(e)},zc=Bc?Bc.prototype:void 0,Wc=zc?zc.toString:void 0,Kc=function e(t){if("string"==typeof t)return t;if(Fc(t))return function(e,t){for(var i=-1,n=null==e?0:e.length,o=Array(n);++i<n;)o[i]=t(e[i],i,e);return o}(t,e)+"";if(function(e){return"symbol"==typeof e||function(e){return null!=e&&"object"==typeof e}(e)&&"[object Symbol]"==jc(e)}(t))return Wc?Wc.call(t):"";var i=t+"";return"0"==i&&1/t==-1/0?"-0":i},qc=0,Yc=function(e){var t=++qc;return function(e){return null==e?"":Kc(e)}(e)+t};class Xc extends zi{constructor(){super(...arguments),this.subTitleId=Yc("subTitleId"),this.descriptionId=Yc("descriptionId"),this.cashbackNonstackableMessageId=Yc("cashbackMessageId"),this.successRateId=Yc("successRateId"),this.isSelected=!1,this.isHover=!1,this.controlClass="control",this.startContentClass="start-content",this.retailerSuccessrateContentClass="retailer-successrate-content",this.descriptionClass="description",this.titleClass="title",this.successrateClass="",this.handleSelected=e=>{this.isSelected&&this.controlCopy.addEventListener("transitionend",this.handleTransitionEnd)},this.handleTransitionEnd=e=>{this.isSelected=!1,this.controlCopy.removeEventListener("transitionend",this.handleTransitionEnd)},this.onKeyPressHandler=e=>{switch(e.key){case Pl.BI:case Pl.kL:e.preventDefault(),this.onSelectedHandler()}},this.onSelectedHandler=()=>{document.activeElement!==this&&this.focus(),this.isSelected=!0,this.$emit("selected")}}connectedCallback(){super.connectedCallback(),this.addEventListener("selected",this.handleSelected)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("selected",this.handleSelected)}onClickHandler(){this.onSelectedHandler()}onHoverHandler(){this.isHover=!0}onHoverEndHandler(){this.isHover=!1}onBlurHandler(){this.isSelected=!1,this.isHover=!1,this.controlCopy.removeEventListener("transitionend",this.handleTransitionEnd)}}(0,an.gn)([pn.Lj],Xc.prototype,"name",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"sub-title"})],Xc.prototype,"subTitle",void 0),(0,an.gn)([pn.Lj],Xc.prototype,"description",void 0),(0,an.gn)([pn.Lj],Xc.prototype,"lastSuccessfulCouponTime",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"indicator-message"})],Xc.prototype,"indicatorMessage",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"selected-indicator-message"})],Xc.prototype,"selectedIndicatorMessage",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"cashback-nonstackable-message"})],Xc.prototype,"cashbackNonstackableMessage",void 0),(0,an.gn)([pn.Lj],Xc.prototype,"regularColors",void 0),(0,an.gn)([pn.Lj],Xc.prototype,"hasIcon",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"label"})],Xc.prototype,"label",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"aria-setsize"})],Xc.prototype,"ariaSetSize",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"aria-posinset"})],Xc.prototype,"ariaPosInSet",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"success-rate"})],Xc.prototype,"successRate",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"is-youtuber"})],Xc.prototype,"isYoutuber",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"isInboxCoupon"})],Xc.prototype,"isInboxCoupon",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"inboxCouponIconUrl"})],Xc.prototype,"inboxCouponIconUrl",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"isTrendingCoupon"})],Xc.prototype,"isTrendingCoupon",void 0),(0,an.gn)([oi.LO],Xc.prototype,"isSelected",void 0),(0,an.gn)([oi.LO],Xc.prototype,"isHover",void 0),(0,an.gn)([pn.Lj],Xc.prototype,"controlClass",void 0),(0,an.gn)([pn.Lj],Xc.prototype,"startContentClass",void 0),(0,an.gn)([pn.Lj],Xc.prototype,"retailerSuccessrateContentClass",void 0),(0,an.gn)([pn.Lj],Xc.prototype,"descriptionClass",void 0),(0,an.gn)([pn.Lj],Xc.prototype,"titleClass",void 0),(0,an.gn)([pn.Lj],Xc.prototype,"successrateClass",void 0),(0,an.gn)([oi.LO],Xc.prototype,"childElements",void 0);const Jc=Xc.compose({baseName:"shopping-coupon-new",shadowOptions:{delegatesFocus:!0},styles:(e,t)=>dn`
${zn("flex")} :host {
position: relative;
box-sizing: border-box;
border: none;
border-radius: 8px;
font-family: ${qn.SVJ};
font-size: ${qn.cSu};
line-height: ${qn.RUt};
color: ${qn.CHi};
outline: none;
}
.control {
position: relative;
font-family: ${qn.SVJ};
background: var(--coupon-single-row-bg, #FFFFFF) !important;
border: 1px dashed #44D498 !important;
box-sizing: border-box;
border-radius: 8px;
display: flex;
flex-direction: column;
padding: 16px 12px;
width: 100%;
height: 72px;
cursor: pointer;
outline: none;
justify-content: center;
}
.controlSuccessHover {
background: linear-gradient(224.24deg,
var(--coupon-success-hover-bg-start, #FFF1F7) 0%,
var(--coupon-success-hover-bg-mid, #FFFEF0) 33.85%,
var(--coupon-success-hover-bg-end, #FFFFFF) 81.25%)!important;
}
.controlSuccess {
border: 1px dashed var(--coupon-success-bg, #F5D6D8);
background: linear-gradient(44.89deg,
var(--coupon-success-bg-start, #FFEEF5) 0%,
var(--coupon-success-bg-mid, #FFFBF0) 37.1%,
var(--coupon-success-bg-end, #FFFFFF) 89.03%);
}
.controlHover {
background: linear-gradient(44.89deg,
var(--coupon-control-hover-bg-start, #FFFFFF) 26.25%,
var(--coupon-control-hover-bg-end, #EDFBFF) 109.58%);
}
.control:${No} {
border-color: ${qn.yGg};
box-shadow: 0 0 0 calc(${qn.vxp} * 1px) ${qn.yGg};
}
.content {
display: flex;
flex-direction: row;
justify-content: flex-start;
align-items: center;
gap: 10px;
width: 100%;
height: auto;
}
.start-content {
display: grid;
grid-template-columns: 1fr auto;
margin-bottom: 0px;
border-radius: 4px;
min-width: 120px;
height: 48px;
justify-content: center;
align-items: center;
margin-bottom: 0px;
background: #18AB6E;
}
.start-content.hover {
background: #159962;
}
.end-content {
display: flex;
flex-direction: column;
height: 100%;
width: 100%;
justify-content: center;
}
.trendingcoupons-end-content-bottom {
display: flex;
flex-direction: row;
justify-content: space-between
}
.trendingcoupons-end-content-bottom {
height: 50px;
}
.title {
overflow: hidden;
display: -webkit-box!important;
-webkit-line-clamp: 1;
-webkit-box-orient: vertical;
margin: 0 8px;
grid-column: 1/2;
font-style: normal;
font-weight: 700;
font-size: 14px;
line-height: 28px;
text-align: center;
word-break: break-all;
overflow-wrap: break-all;
color: #FFFFFF !important;
}
.titleHover {
color: var(--coupon-title-hover-color, #666666);
}
.titleSuccess {
color: var(--coupon-success-color, #DE3700);
}
.sub-title {
font-size: ${qn.G8g};
line-height: ${qn.MwG};
color: ${qn.Q5n};
text-align: start;
margin-inline-start: 0px;
margin-top: 0px;
overflow: hidden;
overflow-wrap: break-word;
display: -webkit-box;
-webkit-line-clamp: 1;
-webkit-box-orient: vertical;
max-width:75px;
width: 0;
flex-grow: 1;
}
.description-lockicon-content {
display: flex;
max-width: 328px;
}
.retailer-successrate-content {
display:flex;
justify-content:space-between;
gap:10px;
margin-top: 3px;
align-items: center;
width: 100%;
}
.trendingCoupons-retailer-successrate-content {
width: 100px;
}
.trendingCoupons-retailer-successrate-content-notification {
height: 28px;
font-size: 12px;
}
.trendingCoupons-successrate-notification {
min-width: 65px;
}
.description {
font-size: ${qn.sNp};
font-weight: 400;
line-height: ${qn.vgC};
color: ${qn.CHi};
text-align: start;
display: -webkit-box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
overflow: hidden;
overflow-wrap: break-word;
margin: 0 0px;
}
.success-rate {
font-size: ${qn.G8g};
line-height: ${qn.MwG};
display: flex;
justify-content: center;
margin-inline-end: 6px;
width: auto;
background: black;
grid-column: 3/4;
height: 16px;
padding: 0 6px;
align-items: flex-end;
margin-top: 6px;
margin: 0px;
border-radius: 4px;
}
.txtSuccessRate {
font-family: ${qn.SVJ};
color: #FFFFFF;
font-weight: 500;
font-size: 10px;
line-height: 16px;
}
.corner-icon {
display: flex;
justify-content: center;
margin-inline-end: 6px;
width: auto;
height: 13.5px;
margin: 0px;
padding: 0px;
padding-left: 8px;
padding-top: -4px;
padding-right: -4px;
}
.copiedIndicator {
opacity: 0;
position: absolute;
pointer-events: none;
}
.nonStackableMessage {
display: inline;
color: var(--coupon-non-stackable-msg-color, #666666);
font-weight: normal;
}
.cashback-nonstackable-message {
font-size: ${qn.sNp};
line-height: ${qn.vgC};
color: ${qn.Q5n};
}
.check-icon {
display: flex;
fill: #8BB73A;
}
.warning-icon {
height: 12px;
}
.warning-icon svg {
fill: #BE5A00;
transform: translate(-3px, 1px);
}
.selected-success {
color: var(--coupon-success-color, #DE3700);
}
.selected-success svg {
fill: var(--coupon-success-color, #DE3700);
}
.selected {
color: var(--coupon-selected-color, #207A90);
}
.selected svg {
fill: var(--coupon-selected-color, #207A90);
}
.inboxCouponContainer {
position: absolute;
top: -12px;
right: -12px;
border-radius: 50%;
width: 25px;
height: 25px;
background-color: var(--fill-color);
display: flex;
justify-content: center;
align-items: center;
box-shadow: var(--neutral-fill-active) 0px 3px 6px;
z-index: 1;
}
.inboxCouponIcon {
width: 65%;
}
.trendingCouponshidden {
display: none;
}
.trendingCoupons-start-content {
min-width: 95px!important;
max-width: 95px!important;
}
.trendingCoupons-start-content-notification {
min-width: 55px!important;
max-width: 55px!important;
height: 34px!important;
}
.trendingCoupons-control-notification {
height: 55px!important;
width: 100%;
}
.trendingCoupons-title-notification {
font-size: 12px!important;
}
`.withBehaviors(Gn(dn`
.title-container {
background: ${Ns.ButtonFace};
border-color: ${Ns.ButtonText};
}
.control,
.controlSuccess,
.sub-title,
.description,
.controlSuccess:hover
.control:hover .title-container {
color: ${Ns.ButtonText};
border-color: ${Ns.ButtonText};
}
.title,
.selected-success,
.selected {
color: ${Ns.Highlight};
}
.selected-success svg {
fill: ${Ns.Highlight};
}
.selected svg {
fill: ${Ns.Highlight};
}
.controlSuccess:hover,
.controlSuccess:${No},
.control:hover,
.control:${No} {
forced-color-adjust: none;
background: ${Ns.ButtonFace}!important;
color: ${Ns.ButtonText};
box-shadow: 0 0 0 calc((${qn.vxp} - ${qn.Han}) * 1px)
${Ns.Highlight};
}
.success-rate {
background: ${Ns.ButtonFace};
}
.cashback-nonstackable-message {
color: ${Ns.HighlightText};
}
.warning-icon,
.copy-icon {
fill: ${Ns.HighlightText};
}
.start-content{
background:${Ns.ButtonFace} !important;
}
.titleHover{
color: ${Ns.ButtonText} !important;
}
.selected-success {
color: ${Ns.ButtonText} !important;
}
.selected-success svg {
fill: ${Ns.ButtonText} !important;
}
.selected {
color: ${Ns.ButtonText} !important;
}
.selected svg {
fill: ${Ns.ButtonText} !important;
}
.title {
color: buttontext !important;
}
`),jn(dn`
.warning-icon svg {
fill: var(--coupon-success-color, #FFB833);
}
.selected-success {
color: var(--coupon-success-color, #FFB833);
}
.selected-success svg {
fill: var(--coupon-success-color, #FFB833);
}
.selected {
color: var(--coupon-selected-color, #41CFF2);
}
.selected svg {
fill: var(--coupon-selected-color, #41CFF2);
}
.control {
background: linear-gradient(44.89deg,
var(--coupon-control-bg-start, rgba(0, 198, 255, 0.08)) 0%,
var(--coupon-control-bg-end, rgba(255, 255, 255, 0)) 82.76%);
border: 1px dashed var(--coupon-control-border, rgba(201, 225, 231, 0.3));
}
.controlHover {
background: linear-gradient(44.89deg,
var(--coupon-control-bg-end, rgba(255, 255, 255, 0)) 26.25%,
var(--coupon-control-bg-start, rgba(0, 198, 255, 0.08)) 109.58%) !important;
color: red;
}
.controlSuccess {
background: linear-gradient(44.89deg,
var(--coupon-success-bg-start, rgba(255, 0, 107, 0.08)) 0%,
var(--coupon-success-bg-mid, rgba(255, 184, 0, 0.08)) 38.24%,
var(--coupon-success-bg-end, rgba(255, 255, 255, 0)) 86.18%);
border: 1px dashed var(--coupon-success-border, rgba(245, 214, 216, 0.3));
}
.controlSuccessHover {
background: linear-gradient(224.24deg,
var(--coupon-success-hover-bg-start, rgba(255, 0, 107, 0.08)) 0%,
var(--coupon-success-hover-bg-mid, rgba(255, 230, 0, 0.08)) 33.85%,
var(--coupon-success-hover-bg-end, rgba(255, 255, 255, 0)) 81.25%) !important;
}
.nonStackableMessage {
color: var(--coupon-non-stackable-msg-color, #FFFFFF);
}
.title {
color: var(--coupon-selected-color, #41CFF2);
}
.titleHover {
color: var(--coupon-title-hover-color, #C4C4C4);
}
.titleSuccess {
color: var(--coupon-success-color, #FFB833);
}
`)),template:(e,t)=>$n`
<template ${Qs({property:"childElements",filter:wo()})}>
<button
id="couponButton"
class= "${e=>e.successRate&&!e.regularColors?e.isHover?e.controlClass+" controlSuccess controlSuccessHover":e.controlClass+" controlSuccess":e.isHover?e.controlClass+" control controlHover":e.controlClass+" control"}"
part="${e=>e.controlClass}"
aria-label="${e=>e.label}"
aria-describedby="${e=>e.name} ${e=>e.subTitleId} ${e=>e.descriptionId} ${e=>e.cashbackNonstackableMessageId} ${e=>e.successRateId}"
aria-setsize="${e=>e.ariaSetSize}"
aria-posinset="${e=>e.ariaPosInSet}"
@click="${e=>e.onClickHandler()}"
@keypress="${(e,t)=>e.onKeyPressHandler(t.event)}"
@blur="${e=>e.onBlurHandler()}"
@mouseover="${(e,t)=>e.onHoverHandler()}"
@mouseout="${e=>e.onHoverEndHandler()}"
@focus="${e=>e.onHoverHandler()}"
role="button"
>
<div class="content">
<div id="couponCodeDiv" class= "${e=>e.isHover?e.startContentClass+" start-content hover":e.startContentClass+" start-content"} ${e=>e.isSelected&&e.selectedIndicatorMessage?e.startContentClass+" start-content hover":""}" part="${e=>e.startContentClass} start-content">
<span class="${e=>e.isHover?e.titleClass+" title titleHover":e.successRate&&!e.regularColors?e.titleClass+" title titleSuccess":e.titleClass+" title"}" part=${e=>e.controlClass} ${vo("controlCopy")}>
${e=>e.isSelected&&e.selectedIndicatorMessage?$n`<span class="${e.successRate&&!e.regularColors?"selected-success":"selected"}">${e.selectedIndicatorMessage} ${'<svg xmlns="http://www.w3.org/2000/svg" width="8" height="6" viewBox="0 0 8 6" fill="none">\n <path d="M7.85355 0.146447C8.04882 0.341709 8.04882 0.658291 7.85355 0.853553L3.35355 5.35355C3.15829 5.54882 2.84171 5.54882 2.64645 5.35355L0.646447 3.35355C0.451184 3.15829 0.451184 2.84171 0.646447 2.64645C0.841709 2.45118 1.15829 2.45118 1.35355 2.64645L3 4.29289L7.14645 0.146447C7.34171 -0.0488155 7.65829 -0.0488155 7.85355 0.146447Z"/>\n </svg>'}</span>`:e.isHover&&e.indicatorMessage?$n`${e.indicatorMessage} <slot name="copy-icon"></slot>`:e.name}
</span>
</div>
<div class="end-content" part="end-content">
<div class="description-lockicon-content">
<span
id="${e=>e.descriptionId}"
class="description ${e=>e.descriptionClass}"
part="description ${e=>e.descriptionClass}"
>
${e=>e.cashbackNonstackableMessage&&(e.isSelected||e.isHover)?$n`
<div class="nonStackableMessage">
<span aria-hidden="true" class="warning-icon">
${'<svg xmlns="http://www.w3.org/2000/svg" width="12" height="12" viewBox="0 0 12 12" fill="none">\n <path d="M4.2829 2.9799C4.13361 1.93492 4.94447 1 6.00005 1C7.05564 1 7.86649 1.93492 7.71721 2.9799L7.14147 7.01005C7.06033 7.57808 6.57385 8 6.00005 8C5.42626 8 4.93978 7.57808 4.85863 7.01005L4.2829 2.9799ZM7 10C7 10.5523 6.55228 11 6 11C5.44772 11 5 10.5523 5 10C5 9.44771 5.44772 9 6 9C6.55228 9 7 9.44771 7 10Z"/>\n </svg>'}
</span>
${e.cashbackNonstackableMessage}
</div>`:e.description?$n`${e.description}`:""}
</span>
${Wr((e=>e.hasIcon),$n`
<div class="corner-icon" part="corner-icon">
<slot name="icon"></slot>
</div>
`)}
</div>
${Wr((e=>e.isTrendingCoupon),$n`<slot name="trendingcoupon-info"></slot>`)}
<div class="${e=>e.isTrendingCoupon?"trendingcoupons-end-content-bottom":""} end-content-bottom">
${Wr((e=>e.isTrendingCoupon),$n`<slot name="trendingcoupon-retailer"></slot>`)}
<div class="${e=>e.retailerSuccessrateContentClass} retailer-successrate-content">
<span id="${e=>e.subTitleId}" class="sub-title" part="sub-title">
${Wr((e=>!(e.cashbackNonstackableMessage&&(e.isSelected||e.isHover))),$n`${e=>e.subTitle}`)}
</span>
<span>${Wr((e=>e.successRate&&!e.hasIcon),$n`
<div class="${e=>e.successrateClass} success-rate" part="success-rate">
<span class="txtSuccessRate" part="txtSuccessRate" id="${e=>e.successRateId}">${e=>e.successRate}</span>
</div>`)}
</span>
<span>${Wr((e=>!(e.successRate&&!e.hasIcon)&&e.lastSuccessfulCouponTime),$n`
<div class="${e=>e.successrateClass} success-rate" part="success-rate">
<span class="txtSuccessRate" part="txtSuccessRate" id="${e=>e.successRateId}">${e=>e.lastSuccessfulCouponTime}</span>
</div>`)}
</span>
</div>
</div>
</div>
${Wr((e=>e.isYoutuber),$n`<slot name="youtuber-info"></slot>`)}
<span aria-live="polite" aria-relevant="all" aria-atomic="true" class="copiedIndicator">
${Wr((e=>e.isSelected&&e.selectedIndicatorMessage),$n`${e=>e.selectedIndicatorMessage}`)},
</span>
</button>
${Wr((e=>e.isInboxCoupon),$n`<div class="inboxCouponContainer">
<img src="${e=>e.inboxCouponIconUrl}" class="inboxCouponIcon"/>
</div>`)}
</template>
`});class Qc extends Zo{constructor(){super(...arguments),this.deselectable=!0,this.isSelected=!1,this.nameId=Yc("nameId"),this.descriptionId=Yc("descriptionId"),this.onSelectedHandler=()=>{document.activeElement!==this&&this.focus(),this.deselectable||this.isSelected||(this.isSelected=!0,this.$emit("selected-changed")),this.deselectable&&(this.isSelected=!this.isSelected,this.$emit("selected-changed"))}}handleImageContentChange(){this.control.classList.toggle("has-image",this.image.assignedNodes().length>0)}onClickHandler(){this.onSelectedHandler()}}(0,an.gn)([pn.Lj],Qc.prototype,"name",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"description"})],Qc.prototype,"description",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"selected-aria-label"})],Qc.prototype,"selectedAriaLabel",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"unselected-aria-label"})],Qc.prototype,"unselectedAriaLabel",void 0),(0,an.gn)([(0,pn.Lj)({mode:"boolean"})],Qc.prototype,"deselectable",void 0),(0,an.gn)([oi.LO],Qc.prototype,"isSelected",void 0);const ed=dn`
.indicator {
right: calc(${qn._5n} * 2px);
}
`,td=dn`
.indicator {
left: calc(${qn._5n} * 2px);
}
`,id=Qc.compose({baseName:"shopping-coupon-printable",shadowOptions:{delegatesFocus:!0},styles:(e,t)=>dn`
${zn("flex")} :host {
box-sizing: border-box;
border-radius: calc(${qn.rSr} * 1px);
font-family: ${qn.SVJ};
font-size: ${qn.sNp};
line-height: ${qn.vgC};
color: ${qn.CHi};
outline: none;
}
:host(:active) {
background-color: ${qn.Gy2};
}
.control {
position: relative;
color: ${qn.CHi};
font-family: ${qn.SVJ};
background: transparent;
box-sizing: border-box;
border: calc(${qn.Han} * 1px) solid ${qn.dtw};
border-radius: inherit;
display: flex;
flex-direction: column;
justify-content: flex-start;
align-items: stretch;
padding: 0 0 8px;
width: 100%;
min-height: 68px;
cursor: pointer;
outline: none;
text-decoration: none;
overflow: hidden;
}
.control:${No} {
border-color: ${qn.yGg};
box-shadow: 0 0 0 calc((${qn.vxp} - ${qn.Han}) * 1px) ${qn.yGg};
}
.image-container {
display: flex;
align-items: center;
justify-content: center;
height: 138px;
overflow: hidden;
}
.image-container svg {
fill: ${qn.wFS};
}
::slotted([slot="image"]){
width: 100%;
object-fit:none;
}
.content {
display: flex;
flex-direction: column;
padding: 0 12px;
overflow: hidden;
}
.name {
font-size: ${qn.PwC};
line-height: ${qn.b3W};
margin-top: 8px;
font-weight: 600;
display: -webkit-box;
overflow: hidden;
overflow-wrap: break-word;
text-align: start;
-webkit-line-clamp: 1;
-webkit-box-orient: vertical;
}
.name-container {
display: flex;
justify-content: space-between;
align-items: flex-end;
}
.description {
margin-top: 4px;
color: ${qn.Q5n};
overflow: hidden;
overflow-wrap: break-word;
font-size: ${qn.sNp};
line-height: ${qn.vgC};
text-align: start;
display: -webkit-box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
}
.indicator {
display: inline-flex;
position: absolute;
top: calc(${qn._5n} *2px);
align-items: center;
justify-content: center;
font-size: ${qn.sNp};
line-height: ${qn.I7_};
border-radius: 2px;
pointer-events: none;
border-radius: calc(${qn.UWU} * 1px);
background-color: ${qn.Avx};
}
.checkbox {
box-sizing: border-box;
display: flex;
align-items: center;
justify-content: center;
margin: 0;
border: calc(${qn.Han} * 1px) solid ${qn.rU8};
border-radius: inherit;
background: ${qn._Bj};
outline: none;
cursor: pointer;
width: 26px;
height: 26px;
}
.indicator.selected .checkbox {
background: var(--checkbox-selected-background, linear-gradient(92.91deg, #15835B 31.47%, #3E8624 99.7%));
border: none;
}
.checkbox svg {
height: 14px;
width: 14px;
fill: ${qn.jql};
display: block;
pointer-events: none;
}
.indicator-message {
display: -webkit-box;
overflow: hidden;
overflow-wrap: break-word;
text-align: start;
-webkit-line-clamp: 1;
-webkit-box-orient: vertical;
}
.indicator-message-selected, .selected-icon-container {
display: flex;
justify-content: center;
align-content: center;
}
`.withBehaviors(new Xr(ed,td),Gn(dn`
.control,
.name,
.description,
.control:hover {
color: ${Ns.ButtonText};
border-color: ${Ns.ButtonText}
}
.control:hover,
.control:${No} {
forced-color-adjust: none;
background: ${Ns.ButtonFace};
color: ${Ns.ButtonText};
border-color: ${Ns.Highlight};
box-shadow: 0 0 0 2px ${Ns.Field}, 0 0 0 4px ${Ns.FieldText};
}
.indicator.selected .checkbox {
forced-color-adjust: none;
background: ${Ns.Highlight};
border-color: ${Ns.Highlight};
color: ${Ns.HighlightText};
}
.checkbox svg {
fill: ${Ns.HighlightText};
}
`)),template:(e,t)=>$n`
<button
class="control"
part="control"
${vo("control")}
aria-live="polite"
aria-label="${e=>e.isSelected?e.selectedAriaLabel:e.unselectedAriaLabel}"
aria-describedby="${e=>e.nameId} ${e=>e.descriptionId}"
@click="${e=>e.onClickHandler()}"
>
<div class="image-container" part="image-container">
<slot
name="image"
${vo("image")}
@slotchange="${e=>e.handleImageContentChange()}"
>
${'<svg width="48" height="48" viewBox="0 0 48 48" xmlns="http://www.w3.org/2000/svg">\n<path d="M42 12.5C42 8.91014 39.0898 6 35.5 6H12.5C8.91014 6 6 8.91014 6 12.5V21.5144C6.89262 20.7772 7.90354 20.178 9 19.7499V12.5C9 10.567 10.567 9 12.5 9H35.5C37.433 9 39 10.567 39 12.5V35.5C39 35.9176 38.9268 36.318 38.7928 36.6894L27.1484 25.2862L26.8916 25.0532C25.6182 23.9832 23.8928 23.7296 22.4052 24.2922C22.9232 25.144 23.3288 26.0718 23.6014 27.055C24.0996 26.9182 24.6546 27.043 25.0494 27.4296L36.661 38.8028C36.2978 38.9306 35.907 39 35.5 39H25.9496L26.9748 40.0252C27.5308 40.581 27.8606 41.2774 27.9642 42H35.5C39.0898 42 42 39.0898 42 35.5V12.5Z"/><path d="M35.0084 17.5042C35.0084 15.0166 32.9918 13 30.5042 13C28.0166 13 26 15.0166 26 17.5042C26 19.9918 28.0166 22.0084 30.5042 22.0084C32.9918 22.0084 35.0084 19.9918 35.0084 17.5042ZM29 17.5042C29 16.6735 29.6734 16 30.5042 16C31.335 16 32.0084 16.6735 32.0084 17.5042C32.0084 18.335 31.335 19.0085 30.5042 19.0085C29.6734 19.0085 29 18.335 29 17.5042Z"/><path d="M19.9 35.7788C21.2108 34.2152 22 32.1998 22 30C22 25.0294 17.9706 21 13 21C8.02944 21 4 25.0294 4 30C4 34.9706 8.02944 39 13 39C14.6849 39 16.2616 38.537 17.61 37.7312L23.4394 43.5606C24.0252 44.1464 24.9748 44.1464 25.5606 43.5606C26.1464 42.9748 26.1464 42.0252 25.5606 41.4394L19.9 35.7788ZM13 36C9.6863 36 7 33.3138 7 30C7 26.6862 9.6863 24 13 24C16.3137 24 19 26.6862 19 30C19 33.3138 16.3137 36 13 36Z"/></svg>'}
</slot>
</div>
<div class="content" part="content">
<span id="${e=>e.nameId}" class="name" part="name">${e=>e.name} </span>
<span id="${e=>e.descriptionId}" class="description" part="description"
>${e=>e.description}
</span>
</div>
<div
class="${e=>e.isSelected?"indicator selected":"indicator"}"
part="indicator"
>
<span class="checkbox">
${Wr((e=>e.isSelected),$n`<span aria-hidden="true">
<svg
viewBox="0 0 16 16"
xmlns="http://www.w3.org/2000/svg"
part="checkbox-svg"
>
<path
d="M13.86 3.66a.5.5 0 01-.02.7l-7.93 7.48a.6.6 0 01-.84-.02L2.4 9.1a.5.5 0 01.72-.7l2.4 2.44 7.65-7.2a.5.5 0 01.7.02z"
/>
</svg>
</span>`)}
</span>
</div>
</button>
`});class nd extends zi{connectedCallback(){const e=Object.create(null,{connectedCallback:{get:()=>super.connectedCallback}});return(0,an.mG)(this,void 0,void 0,(function*(){e.connectedCallback.call(this),this.imageElement&&this.onImageLoad&&(this.imageElement.onload=this.onImageLoad.bind(this),this.imageElement.onerror=this.onImageLoad.bind(this))}))}}(0,an.gn)([(0,pn.Lj)()],nd.prototype,"src",void 0),(0,an.gn)([(0,pn.Lj)()],nd.prototype,"alt",void 0),(0,an.gn)([oi.LO],nd.prototype,"onImageLoad",void 0);const od=dn`
img {
display: block;
width: 100%;
height: fit-content;
object-fit: contain;
}
`,rd=nd.compose({baseName:"shopping-image",shadowOptions:{delegatesFocus:!0},styles:od,template:(e,t)=>$n`
<template>
<img
src="${e=>e.src}"
alt="${e=>e.alt}"
${vo("imageElement")} />
</template>
`});class ad extends Qo{}(0,an.gn)([(0,pn.Lj)({attribute:"destination"})],ad.prototype,"destination",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"altText"})],ad.prototype,"altText",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"dealPercentage"})],ad.prototype,"dealPercentage",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"originalPrice"})],ad.prototype,"originalPrice",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"currentPrice"})],ad.prototype,"currentPrice",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"titleText"})],ad.prototype,"titleText",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"alt-color"})],ad.prototype,"useAltColors",void 0);const sd=$n`
<svg width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
<path fill="#FFFFFF" d="M8.08674 2.19636L2.19583 8.08727C1.94493 8.33818 1.94493 8.75273 2.19583 9.01455L6.99583 13.8145C7.24674 14.0655 7.66129 14.0655 7.92311 13.8145L13.814 7.92364C13.934 7.79273 13.9995 7.62909 13.9995 7.45455V2.65455C13.9995 2.29455 13.7049 2 13.3449 2H8.54493C8.37038 2 8.20674 2.06545 8.08674 2.19636ZM12.2431 5.32727C12.1777 5.46909 12.0904 5.6 11.9813 5.70909C11.8722 5.81818 11.7522 5.90545 11.5995 5.96C11.4467 6.01455 11.3049 6.05818 11.1413 6.05818C10.9777 6.05818 10.814 6.02545 10.6722 5.96C10.5304 5.90545 10.3995 5.81818 10.2904 5.70909C10.1813 5.6 10.094 5.46909 10.0395 5.32727C9.97402 5.18545 9.94129 5.03273 9.94129 4.85818C9.94129 4.68364 9.97402 4.53091 10.0395 4.38909C10.094 4.25818 10.1813 4.12727 10.2904 4.02909C10.3995 3.92 10.5304 3.83273 10.6722 3.76727C10.814 3.70182 10.9667 3.66909 11.1413 3.66909C11.3158 3.66909 11.4686 3.70182 11.6104 3.76727C11.7522 3.83273 11.8831 3.92 11.9813 4.02909C12.0904 4.13818 12.1777 4.25818 12.2431 4.4C12.3086 4.54182 12.3413 4.69455 12.3413 4.86909C12.3413 5.04364 12.2977 5.18545 12.2431 5.32727Z"></path>
</svg>
`,ld=ad.compose({baseName:"shopping-recommendation",shadowOptions:{delegatesFocus:!0},styles:(e,t)=>dn`
${zn("flex")} :host {
border: calc(${qn.Han} * 1px) solid transparent;
border-radius: calc(${qn.rSr} * 1px);
box-sizing: border-box;
color: ${qn.CHi};
cursor: pointer;
fill: currentcolor;
font-family: ${qn.SVJ};
font-size: ${qn.sNp};
line-height: ${qn.vgC};
outline: none;
position: relative;
}
.anchor-wrapper {
width: 100%;
text-decoration: none;
color: ${qn.CHi};
border-radius: 8px;
transition: box-shadow 500ms;
}
.anchor-wrapper:active {
color: ${qn.CHi};
}
.anchor-wrapper:hover {
box-shadow: 0px 3px 6px rgb(0, 0, 0, 0.12);
}
.product-card {
position: relative;
content-visibility: visible;
border-radius: 8px;
box-shadow: none;
width: 100%;
}
.product-info {
margin-top: 8px;
padding: 0px 12px 12px 12px;
}
.title {
display: -webkit-box;
-webkit-line-clamp: 1;
-webkit-box-orient: vertical;
white-space: normal;
overflow: hidden;
height: 16px;
font-size: ${qn.sNp};
line-height: ${qn.vgC};
word-break: break-all;
}
.price {
display: flex;
gap: 6px;
align-items: flex-end;
}
.current-price {
font-weight: 700;
font-size: 16px;
line-height: 22px;
}
.current-price.sale {
color: #DE3700;
}
@media
(-webkit-min-device-pixel-ratio: 1.5),
(min-resolution: 144dpi) {
.current-price-hundredth {
padding-top: 2px;
}
}
.previous-price {
font-weight: 400;
font-size: 12px;
line-height: 16px
color: var(--text-neutral-foreground-hint);
text-decoration-line: line-through;
display: flex;
align-self: center;
}
.decoration {
padding: 2px 5px;
position: absolute;
top: 6px;
left: 6px;
background: rgba(0, 0, 0, 0.7);
border-radius: 6px;
display: flex;
align-items: center;
gap: 4px;
color: #FFF;
z-index: 10;
}
.decoration-text {
font-size: ${qn.sNp};
line-height: ${qn.vgC};
}
.decoration svg {
display: inline-block;
padding-top: 1px;
height: 12px;
width: 12px;
}
@media (prefers-color-scheme: dark) {
.current-price.sale {
color: #FA9370;
}
}
@media (-ms-high-contrast: active) {
.product-card {
border: 1px solid linkText;
color: linkText;
}
.product-card:hover {
outline: 1px solid highlight;
}
.decoration {
background: #000;
}
.seller, .current-price.sale, .previous-price {
color: linkText;
}
}
`.withBehaviors(Gn(dn`
:host,
.previous-price,
.product-title {
forced-color-adjust: auto;
color: ${Ns.LinkText};
}
:host .control:hover,
:host([href]) .control:hover,
:host([href]) .control:${No} {
forced-color-adjust: none;
box-shadow: inset 0 0 0 calc((${qn.vxp} * 1px)) ${Ns.LinkText};
}
.image svg {
fill: ${Ns.ButtonText};
}
`)),template:(e,t)=>$n`
<a
class="anchor-wrapper"
target="_blank"
href="${e=>e.destination}"
aria-label="${e=>e.altText}">
<fluent-card class="product-card" aria-hidden="true">
<div class="card-inner">
${Wr((e=>e.dealPercentage),$n`
<div class="decoration">
${sd}
<div class="decoration-text">
${e=>e.dealPercentage}
</div>
</div>`)}
<slot name="image"></slot>
<div class="product-info">
<div class="price">
<div class="current-price${e=>e.originalPrice?" sale":""}">
${e=>e.currentPrice}
</div>
${Wr((e=>e.originalPrice),$n`
<div class="previous-price">
${e=>e.originalPrice}
</div>
`)}
</div>
<div class="title">${e=>e.titleText}</div>
</div>
</div>
</fluent-card>
</a>
`});class cd extends zi{constructor(){super(...arguments),this.hasShippingCost=!1,this.itemTitleId=Yc("itemTitleId"),this.deliveryLabelId=Yc("deliveryLabelId"),this.deliveryInfoId=Yc("deliveryInfoId"),this.shipperLabelId=Yc("shipperLabelId"),this.ratingLabelId=Yc("ratingLabelId"),this.ratingId=Yc("ratingId"),this.shipperLinkId=Yc("shipperLinkId"),this.actionButtonPressed=!1,this.onKeyPressHandler=e=>{e.key===Pl.BI&&(e.preventDefault(),this.onClickHandler())},this.linkKeyPressHandler=e=>{e.key===Pl.BI&&(e.preventDefault(),this.linkClickHandler())}}connectedCallback(){super.connectedCallback(),this.actionButtonPressed&&this.actionButtonRef&&(this.actionButtonRef.disabled=!0)}onClickHandler(){this.actionButtonPressed=!0,this.actionButtonRef.disabled=!0,this.$emit("add-to-cart")}linkClickHandler(){this.$emit("link-invoked")}actionButtonPressedChanged(){this.actionButtonPressed&&this.actionButtonRef&&(this.actionButtonRef.disabled=!0)}}(0,an.gn)([(0,pn.Lj)({attribute:"item-title"})],cd.prototype,"itemTitle",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"item-currency"})],cd.prototype,"itemCurrency",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"item-price"})],cd.prototype,"itemPrice",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"item-price-hundredths"})],cd.prototype,"itemPriceHundredths",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"delivery-label"})],cd.prototype,"deliveryLabel",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"delivery-info"})],cd.prototype,"deliveryInfo",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"shipper-label"})],cd.prototype,"shipperLabel",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"shipper-name"})],cd.prototype,"shipperName",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"rating-label"})],cd.prototype,"ratingLabel",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"rating"})],cd.prototype,"rating",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"shipper-url"})],cd.prototype,"shipperUrl",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"has-shipping-cost",mode:"boolean"})],cd.prototype,"hasShippingCost",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"action-button-text"})],cd.prototype,"actionButtonText",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"pressed-action-button-text"})],cd.prototype,"pressedActionButtonText",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"action-button-aria-label"})],cd.prototype,"actionButtonAriaLabel",void 0),(0,an.gn)([(0,pn.Lj)({attribute:"action-button-pressed",mode:"boolean"})],cd.prototype,"actionButtonPressed",void 0);const dd=dn`
:host {
--content-max-lines: 2;
--shipping-cost-color: #C42B1C;
--shipping-cost-color-dark-mode: #f99a91;
outline: none;
font-family: ${qn.SVJ};
font-size: ${qn.sNp};
font-weight: 500;
line-height: ${qn.vgC};
min-width: calc(${Lo} * 1px);
border-radius: calc(${qn.rSr} * 1px);
box-sizing: border-box;
color: ${qn.CHi};
fill: currentcolor;
min-height: 78px;
display: block;
}
.control {
display: grid;
grid-template-columns: 1fr 90px;
grid-column-gap: 8px;
box-sizing: border-box;
background: transparent;
justify-content: center;
align-items: flex-start;
padding: 16px;
outline: none;
text-decoration: none;
border: calc(${qn.Han} * 1px) solid transparent;
color: inherit;
border-radius: inherit;
fill: inherit;
cursor: inherit;
font-family: inherit;
width: 100%;
height: 100%;
--elevation: 4;
min-height: 78px;
${"box-shadow: 0 0 2px rgba(0, 0, 0, 0.14), 0 calc(var(--elevation) * 0.5px) calc((var(--elevation) * 1px)) rgba(0, 0, 0, 0.2);"};
}
.delivery-label.has-shipping-cost {
color: var(--shipping-cost-color);
}
.price-container {
grid-column: 2;
grid-row: 1;
display: flex;
flex-direction: column;
justify-self: end;
align-items: flex-end;
justify-content: space-between;
font-size: ${qn.PwC};
text-overflow: ellipsis;
height: 100%;
overflow: hidden;
min-height: ${qn.b3W};
max-width: 90px;
min-height: 12px;
}
.action-button {
height: 24px;
margin: 0 1px;
}
.action-button::part(control) {
max-height: 24px;
padding: 0 8px;
font-size: 12px;
}
.action-button,
.action-button::part(control) {
color: #FFFFFF;
max-width: 93px;
font-weight: 600;
background: #2169EB;
}
.action-button.disabled,
.action-button.disabled::part(control) {
background: #0000000F;
color: #0000008F;
}
.shipper-link::part(control) {
text-decoration: none;
border-bottom: none;
margin: calc(${qn.Han} * 1px);
}
.action-button::part(content) {
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
.shipper-link::part(control):focus {
border: calc(${qn.Han} * 1px) solid ${qn.yGg};
margin: 0;
}
.item-title {
margin-bottom: 5px;
font-weight: 600;
}
.delivery-label,
.shipper-label,
.rating-label {
color: ${qn.Q5n};
}
.shipper-link {
font-weight: 400;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
max-width: 16ch;
}
.content {
display: flex;
flex-direction: column;
align-items: flex-start;
justify-content: space-between;
font-weight: 400;
text-align: left;
}
.item-price {
text-align: right;
display: flex;
flex-direction: row;
align-items: center;
margin-bottom: 6px;
}
.txtPrice {
font-size: 24px;
font-weight: 600;
line-height: 26px;
color: var(--text-price-color);
}
.txtPriceDecorative {
font-size: 18px;
font-weight: 600;
line-height: 18px;
color: var(--text-price-color);
margin-bottom: 2px;
margin-left: 1px;
}
.item-description {
overflow: hidden;
display: flex;
justify-content: space-between;
gap: 2px;
flex-direction: column;
}
.shipper-label {
display: flex;
height: 16px;
align-items: center;
gap: 4px;
}
.rating-container {
display: inline-flex;
gap: 2px;
align-items: center;
color: var(--text-price-color);
font-weight: 600;
}
@media (max-width: 655px) {
:host {
max-width: 602px;
}
}
@media (prefers-color-scheme: dark) {
.action-button.disabled,
.action-button.disabled::part(control) {
color: #FFFFFF;
background: #00000040;
}
.delivery-label.has-shipping-cost {
color: var(--shipping-cost-color-dark-mode);
}
}
`,ud=$n`
<svg width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_1856_6605)">
<path d="M5.28347 1.54605C5.57692 0.951448 6.42479 0.951449 6.71825 1.54605L7.82997 3.79866L10.3159 4.15988C10.9721 4.25523 11.2341 5.0616 10.7592 5.52443L8.96043 7.27785L9.38507 9.7537C9.49716 10.4072 8.81122 10.9056 8.22431 10.597L6.00086 9.4281L3.7774 10.597C3.19049 10.9056 2.50455 10.4072 2.61664 9.7537L3.04128 7.27784L1.24246 5.52443C0.767651 5.0616 1.02966 4.25523 1.68584 4.15988L4.17174 3.79865L5.28347 1.54605Z" fill="#F5C32F"/>
</g>
<defs>
<clipPath id="clip0_1856_6605">
<rect width="12" height="12" fill="white"/>
</clipPath>
</defs>
</svg>
`,hd=$n`
<fluent-button ${vo("actionButtonRef")}
class="action-button"
title="${e=>e.actionButtonText}"
aria-label="${e=>e.actionButtonAriaLabel}"
aria-describedby="${e=>e.itemTitleId} ${e=>e.deliveryLabelId} ${e=>e.deliveryInfoId} ${e=>e.shipperLabelId} ${e=>e.shipperLinkId} ${e=>e.ratingLabelId} ${e=>e.ratingId}"
@click="${e=>e.onClickHandler()}"
@keyup="${(e,t)=>e.onKeyPressHandler(t.event)}"
${e=>e.actionButtonPressed?"disabled":""}
>
${e=>e.actionButtonPressed?e.pressedActionButtonText:e.actionButtonText}
</fluent-button>
`,pd=cd.compose({baseName:"shopping-similar-seller",shadowOptions:{delegatesFocus:!0},styles:dd,template:(e,t)=>$n`
<div class="control" part="control">
<div class="price-container" part="price-container">
${Wr((e=>e.itemPrice&&e.itemCurrency),$n`
<span class="item-price" part="item-price">
<span class="txtPriceDecorative">${e=>e.itemCurrency}</span>
<span class="txtPrice">${e=>e.itemPrice}</span>
${Wr((e=>e.itemPriceHundredths),$n`<span class="txtPriceDecorative">${e=>e.itemPriceHundredths}</span>`)}
</span>`)}
${Wr((e=>e.actionButtonText),$n`${hd}`)}
</div>
<div class="content" part="content">
<div class="item-title" id="${e=>e.itemTitleId}">
${e=>e.itemTitle}
</div>
<div class="item-description">
<div>
<span
id="${e=>e.deliveryLabelId}"
class="delivery-label ${e=>e.hasShippingCost?"has-shipping-cost":""}"
part="delivery-label"
>${e=>e.deliveryLabel}</span
>
<span
id="${e=>e.deliveryInfoId}"
class="delivery-info"
part="delivery-info"
>${e=>e.deliveryInfo}</span
>
</div>
${Wr((e=>e.shipperLabel),$n`<div class="shipper-label">
<span
class="shipper-label"
part="shipper-label"
id="${e=>e.shipperLabelId}"
>${e=>e.shipperLabel}</span
>
<fluent-anchor
id="${e=>e.shipperLinkId}"
appearance="hypertext"
class="shipper-link"
part="shipper-link"
title="${e=>e.shipperName}"
href="${e=>e.shipperUrl}"
@click="${e=>e.linkClickHandler()}"
@keyup="${(e,t)=>e.linkKeyPressHandler(t.event)}"
>${e=>e.shipperName}</fluent-anchor
>
${Wr((e=>e.rating),$n`
<span class="rating-container">
${ud}
${e=>e.rating}
</span>
`)}
</div>`)}
</div>
</div>
</div>
`});var gd=o(46357);class fd extends Zo{constructor(){super(...arguments),this.isVisible=!1,this.isFocused=!1,this.hasLink=!1,this.isCjk=!1,this.onKeyDownHandlerLink=e=>{var t;switch(e.key){case"Space":case"Enter":e.preventDefault(),this.linkHandler();break;case"Tab":case"Escape":e.preventDefault(),this.isVisible=!1;const i=null===(t=this.shadowRoot)||void 0===t?void 0:t.querySelector(".control");i&&i.focus()}}}onHoverHandler(){this.isVisible=!0,this.$emit("hover")}onHoverEndHandler(e){this.isVisible=null!=e&&e}onFocusHandler(){this.isFocused=!0,this.isVisible=!1}onBlurHandler(){var e;this.isFocused=!1,(null===(e=this.shadowRoot)||void 0===e?void 0:e.querySelector(".link"))||(this.isVisible=!1)}onKeypressHandler(e){var t;switch(e.key){case"Escape":this.isVisible&&(e.preventDefault(),this.isVisible=!1);break;case"Enter":if(this.isFocused){e.preventDefault(),this.isVisible=!0;const i=null===(t=this.shadowRoot)||void 0===t?void 0:t.querySelector(".link");i&&this.linkText&&i.focus()}}}onClickHandlerLink(){this.linkHandler()}onLearnMoreClickHandlerLink(){this.learnMoreLinkHandler()}onTermsAndConditionsClickHandlerLink(){this.termsAndConditionsLinkHandler()}generateTooltipOffsets(){var e;const t=null!==(e=this.caratSide)&&void 0!==e?e:gd.W.Top;t!==gd.W.Bottom&&t!==gd.W.Top||!this.caratLeftOffset?t!==gd.W.Left&&t!==gd.W.Right||!this.caratTopOffset||this.style.setProperty("--carat-top-offset",this.caratTopOffset):this.style.setProperty("--carat-left-offset",this.caratLeftOffset)}connectedCallback(){super.connectedCallback(),(this.caratTopOffset||this.caratLeftOffset)&&this.generateTooltipOffsets(),this.width&&this.style.setProperty("--tooltip-width",this.width),this.addEventListener("keydown",(e=>{this.onKeypressHandler(e)}))}}(0,an.gn)([pn.Lj],fd.prototype,"header",void 0),(0,an.gn)([pn.Lj],fd.prototype,"content",void 0),(0,an.gn)([pn.Lj],fd.prototype,"contentLength",void 0),(0,an.gn)([pn.Lj],fd.prototype,"contentElement",void 0),(0,an.gn)([pn.Lj],fd.prototype,"linkText",void 0),(0,an.gn)([pn.Lj],fd.prototype,"linkHandler",void 0),(0,an.gn)([pn.Lj],fd.prototype,"learnMoreText",void 0),(0,an.gn)([pn.Lj],fd.prototype,"learnMoreLinkHandler",void 0),(0,an.gn)([pn.Lj],fd.prototype,"termsAndConditionsText",void 0),(0,an.gn)([pn.Lj],fd.prototype,"termsAndConditionsLinkHandler",void 0),(0,an.gn)([pn.Lj],fd.prototype,"termsAndConditionsTip",void 0),(0,an.gn)([pn.Lj],fd.prototype,"isTextHoverable",void 0),(0,an.gn)([pn.Lj],fd.prototype,"caratSide",void 0),(0,an.gn)([pn.Lj],fd.prototype,"width",void 0),(0,an.gn)([pn.Lj],fd.prototype,"fontSize",void 0),(0,an.gn)([pn.Lj],fd.prototype,"caratLeftOffset",void 0),(0,an.gn)([pn.Lj],fd.prototype,"caratTopOffset",void 0),(0,an.gn)([oi.LO],fd.prototype,"isVisible",void 0),(0,an.gn)([oi.LO],fd.prototype,"isFocused",void 0),(0,an.gn)([oi.LO],fd.prototype,"hasLink",void 0),(0,an.gn)([oi.LO],fd.prototype,"isCjk",void 0);const md=fd.compose({baseName:"shopping-tooltip",shadowOptions:{delegatesFocus:!0},styles:(e,t)=>dn`
.title {
font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;
font-weight: 600;
font-size: 14px;
line-height: 20px;
margin: 0px;
margin-bottom: 10px;
color: var(--neutral-foreground-rest);
}
.content {
font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;
line-height: 16px;
margin: 0px;
font-weight: 400;
color: var(--neutral-foreground-rest);
}
.link {
font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;
font-size: 12px;
font-weight: 600;
line-height: 16px;
color: rgba(0, 0, 0, 0.5);
text-decoration: none;
}
.tooltip {
position: absolute;
background: var(--tooltip-background-color, #FFFFFF);
text-align: left;
box-shadow: 0px 12.8px 28.8px rgba(0, 0, 0, 0.13), 0px 0px 9.2px rgba(0, 0, 0, 0.11);
border-radius: 4px;
padding: 12px;
padding-bottom: 10px;
z-index: 900;
cursor: default;
width: var(--tooltip-width);
box-sizing: border-box;
}
.tooltip-cjk {
background: var(--tooltip-background-color, #FFFFFF);
text-align: left;
box-shadow: 0px 12.8px 28.8px rgba(0, 0, 0, 0.13), 0px 0px 9.2px rgba(0, 0, 0, 0.11);
border-radius: 4px;
padding: 12px;
padding-bottom: 10px;
z-index: 900;
cursor: default;
width: var(--tooltip-width);
box-sizing: border-box;
}
.tooltip.top {
margin-top: 18px;
margin-left: calc(var(--carat-left-offset, calc(var(--tooltip-width) / 2)) * -1 - 4px);
}
.tooltip.bottom {
margin-bottom: 18px;
margin-left: calc(var(--carat-left-offset, calc(var(--tooltip-width) / 2)) * -1 - 4px);
bottom: 0px;
left: 0px;
}
.tooltip.right {
margin-right: 18px;
margin-top: calc(var(--carat-top-offset, 5px) * -1);
}
.tooltip.left {
margin-left: 18px;
margin-top: calc(var(--carat-top-offset, 5px) * -1);
}
.top .carat {
content: " ";
width: 0;
height: 0;
border-left: 10px solid transparent;
border-right: 10px solid transparent;
border-bottom: 6px solid var(--tooltip-background-color, #FFFFFF);
position: absolute;
top: -5px;
left: var(--carat-left-offset, calc(var(--tooltip-width) / 2));
}
.bottom .carat {
content: " ";
width: 0;
height: 0;
border-left: 10px solid transparent;
border-right: 10px solid transparent;
border-top: 6px solid var(--tooltip-background-color, #FFFFFF);
position: absolute;
bottom: -5px;
left: var(--carat-left-offset, calc(var(--tooltip-width) / 2));
}
.right .carat {
content: " ";
width: 0;
height: 0;
border-top: 10px solid transparent;
border-bottom: 10px solid transparent;
border-left: 6px solid var(--tooltip-background-color, #FFFFFF);
position: absolute;
top: var(--carat-top-offset);
right: -5px;
}
.left .carat {
content: " ";
width: 0;
height: 0;
border-top: 10px solid transparent;
border-bottom: 10px solid transparent;
border-right: 6px solid var(--tooltip-background-color, #FFFFFF);
position: absolute;
top: var(--carat-top-offset);
left: -5px;
}
.icon:focus {
outline: none;
box-shadow: 0px 0px 0px 2px #898989;
border-radius: 4px;
}
.link:focus {
outline: none;
box-shadow: 0px 0px 0px 2px #898989;
border-radius: 4px;
}
@media (prefers-color-scheme: dark) {
.tooltip {
background: var(--tooltip-background-color, #3b3b3b);
}
.top .carat {
border-bottom: 6px solid var(--tooltip-background-color, #3b3b3b);
}
.bottom .carat {
border-top: 6px solid var(--tooltip-background-color, #3b3b3b);
}
.right .carat {
border-left: 6px solid var(--tooltip-background-color, #3b3b3b);
}
.left .carat {
border-right: 6px solid var(--tooltip-background-color, #3b3b3b);
}
.link {
color: rgba(255, 255, 255, 0.7);
}
.icon:focus {
outline: none;
box-shadow: 0px 0px 0px 2px #898989;
border-radius: 4px;
}
}
@media (-ms-high-contrast: active) {
.content {
color: windowText;
}
.tooltip {
border: 0.5px solid windowText;
}
}`,template:(e,t)=>$n`
<template>
<div
style="
display:flex;
flex-direction:${e=>e.caratSide===gd.W.Right||e.caratSide===gd.W.Left?"column":"row"};
align-items:${e=>e.caratSide===gd.W.Right?"flex-end":"flex-start"};
justify-content:${e=>e.caratSide===gd.W.Bottom?"flex-end":"flex-start"};
position: relative;
${e=>e.isCjk?"margin-bottom: 32px":""};
"
>
<div
class="icon control"
style="display:flex;"
part="control"
${vo("control")}
role="button"
tabindex="0"
aria-atomic="${e=>e.ariaAtomic}"
aria-busy="${e=>e.ariaBusy}"
aria-controls="${e=>e.ariaControls}"
aria-current="${e=>e.ariaCurrent}"
aria-describedBy="${e=>e.ariaDescribedby}"
aria-details="${e=>e.ariaDetails}"
aria-disabled="${e=>e.ariaDisabled}"
aria-errormessage="${e=>e.ariaErrormessage}"
aria-expanded="${e=>e.isVisible}"
aria-flowto="${e=>e.ariaFlowto}"
aria-haspopup="${e=>e.linkText&&e.linkHandler}"
aria-hidden="${e=>e.ariaHidden}"
aria-invalid="${e=>e.ariaInvalid}"
aria-keyshortcuts="${e=>e.ariaKeyshortcuts}"
aria-label="${e=>e.ariaLabel}"
aria-labelledby="hover-anchor"
aria-live="${e=>e.ariaLive}"
aria-owns="${e=>e.ariaOwns}"
aria-relevant="${e=>e.ariaRelevant}"
aria-roledescription="${e=>e.ariaRoledescription}"
@blur="${e=>e.onBlurHandler()}"
@mouseenter="${e=>e.onHoverHandler()}"
@mouseleave="${e=>e.onHoverEndHandler()}"
@focus="${e=>e.onFocusHandler()}"">
<slot name="hover-anchor" id="hover-anchor" class="hover-anchor"></slot>
</div>
<div
@mouseenter="${e=>e.isTextHoverable||e.termsAndConditionsTip?e.onHoverHandler():""}
@mouseleave="${e=>e.isTextHoverable||e.termsAndConditionsTip?e.onHoverEndHandler(!0):""}"
class=${e=>e.isCjk?e.caratSide===gd.W.Right?"tooltip-cjk right":e.caratSide===gd.W.Left?"tooltip-cjk left":e.caratSide===gd.W.Bottom?"tooltip-cjk bottom":"tooltip-cjk top":e.caratSide===gd.W.Right?"tooltip right":e.caratSide===gd.W.Left?"tooltip left":e.caratSide===gd.W.Bottom?"tooltip bottom":"tooltip top"}
role=${e=>e.linkText?"dialog":"tooltip"}
style="display:${e=>e.isVisible?"block":"none"}; padding: ${e=>e.fontSize?"6px":"12px"};"
aria-hidden="${e=>!e.isVisible}"
aria-labelledby="title content">
<div class="carat"></div>
${Wr((e=>e.header),$n`
<p id="title" class="title">
${e=>e.header}
</p>`)}
${Wr((e=>e.content),$n`
<p id="content"
@mouseenter="${e=>e.isTextHoverable||e.termsAndConditionsTip?e.onHoverHandler():""}"
@mouseleave="${e=>e.isTextHoverable||e.termsAndConditionsTip?e.onHoverEndHandler(!0):""}"
class="content" title="${e=>e.content}" style="margin-bottom: ${e=>e.linkHandler&&e.linkText?"4px":"0px"}; font-size: ${e=>{var t;return null!==(t=e.fontSize)&&void 0!==t?t:"12px;"}}">
${e=>e.content}
</p>`)}
${Wr((e=>e.contentElement),$n`
<div id="content" class="content" :innerHTML="${e=>e.contentElement}">
</div>`)}
${Wr((e=>e.termsAndConditionsTip),$n`
<div style='text-align: center'>
<a href="#" tabindex="0" style='margin-right: 5px' @click="${e=>e.onLearnMoreClickHandlerLink()}" @keydown="${(e,t)=>e.onKeyDownHandlerLink(t.event)}">
${e=>e.learnMoreText}
</a> | <a href="#" tabindex="0" style='margin-left: 5px' @click="${e=>e.onTermsAndConditionsClickHandlerLink()}" @keydown="${(e,t)=>e.onKeyDownHandlerLink(t.event)}">
${e=>e.termsAndConditionsText}
</a>
</div>`)}
${Wr((e=>e.linkText&&e.linkHandler),$n`
<a class="link"
href="#"
tabindex="0"
@mouseenter="${e=>e.isTextHoverable||e.termsAndConditionsTip?e.onHoverHandler():""}"
@mouseleave="${e=>e.isTextHoverable||e.termsAndConditionsTip?e.onHoverEndHandler(!0):""}"
@click="${e=>e.onClickHandlerLink()}"
@keydown="${(e,t)=>e.onKeyDownHandlerLink(t.event)}">
${e=>e.linkText}
</a>`)}
</div>
</div>
</template>
`});function vd(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function yd(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?vd(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):vd(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function Cd(e,t){if(!t||isNaN(t?.Value)||t.Value<=0||!e||isNaN(e?.Value)||e.Value<=0)return null;const i=e.Value-t.Value;return i<=0?null:yd(yd({},t),{},{Value:Math.trunc(i)})}class bd extends zi{connectedCallback(){super.connectedCallback()}bookOnProviderClicked(e){var t,n,o,r,a,s,l,c,d,u,h,p,g,f,m,v,y,C,b,S,x,T,w,O,P,A;const E=null===(a=null===(r=null===(o=null===(n=null===(t=this.data)||void 0===t?void 0:t.hotelSearchResponse)||void 0===n?void 0:n.HotelResults)||void 0===o?void 0:o[0])||void 0===r?void 0:r.BookingOptions)||void 0===a?void 0:a[0];null==e||e.preventDefault(),null==e||e.stopPropagation();const k=Cd(null===(c=null===(l=null===(s=this.data)||void 0===s?void 0:s.hotelSearchResponse)||void 0===l?void 0:l.HotelQuery)||void 0===c?void 0:c.MaximumPrice,null==E?void 0:E.Price),I=null===(d=this.data)||void 0===d?void 0:d.cardType,D=null!==(h=null===(u=null==E?void 0:E.MetaData)||void 0===u?void 0:u.Index)&&void 0!==h?h:-1,_=null!==(p=null==E?void 0:E.ProviderName)&&void 0!==p?p:"",N=null!==(g=null==k?void 0:k.Value)&&void 0!==g?g:-1,R=null!==(f=null==k?void 0:k.CurrencySymbol)&&void 0!==f?f:"#",M=null!==(b=null===(C=null===(y=null===(v=null===(m=this.data)||void 0===m?void 0:m.hotelSearchResponse)||void 0===v?void 0:v.HotelQuery)||void 0===y?void 0:y.MaximumPrice)||void 0===C?void 0:C.Value)&&void 0!==b?b:-1,L=null!==(O=null===(w=null===(T=null===(x=null===(S=this.data)||void 0===S?void 0:S.hotelSearchResponse)||void 0===x?void 0:x.HotelQuery)||void 0===T?void 0:T.MaximumPrice)||void 0===w?void 0:w.CurrencySymbol)&&void 0!==O?O:"#",B=null===(P=this.data)||void 0===P?void 0:P.clientActivityId,F=null!==(A=null==E?void 0:E.Link)&&void 0!==A?A:"",U={Message:"",ButtonName:i.$S.TravelHotelCardClicked,UrlToRedirect:F,ClientActivityId:B,Metadata:Object.assign({cardClicked:"BookOnHotelProviderClicked",scenario:I,index:D,provider:_,expectedSavings:N,currency:R,minimumPriceOnPage:M,minimumPriceOnPageCurrency:L,clientActivityId:B},null==E?void 0:E.Telemetry)};return this.eventListener(U),!1}}(0,an.gn)([oi.LO],bd.prototype,"data",void 0),(0,an.gn)([oi.LO],bd.prototype,"stayDatesString",void 0),(0,an.gn)([oi.LO],bd.prototype,"roomsGuestsString",void 0),(0,an.gn)([oi.LO],bd.prototype,"cheapestProviderName",void 0),(0,an.gn)([oi.LO],bd.prototype,"getDealNowString",void 0),(0,an.gn)([oi.LO],bd.prototype,"cheapestProviderLogo",void 0),(0,an.gn)([oi.LO],bd.prototype,"saveString",void 0),(0,an.gn)([oi.LO],bd.prototype,"maximumSavingsString",void 0),(0,an.gn)([oi.LO],bd.prototype,"propertyImage",void 0),(0,an.gn)([oi.LO],bd.prototype,"propertyName",void 0),(0,an.gn)([oi.LO],bd.prototype,"cheapestPriceCurrencyString",void 0),(0,an.gn)([oi.LO],bd.prototype,"cheapestPriceValueString",void 0),(0,an.gn)([oi.LO],bd.prototype,"originalPriceString",void 0),(0,an.gn)([oi.LO],bd.prototype,"perRoomPerNightString",void 0),(0,an.gn)([oi.LO],bd.prototype,"providerBookNowUrl",void 0),(0,an.gn)([oi.LO],bd.prototype,"eventListener",void 0);const Sd=dn`
.card-container {
--black-white: #1A1A1A;
--gray-text: #6E6E6E;
--green-text: #44A856;
--gray-line: #EBEBEB;
--ad-slug: #737373;
display: flex;
flex-direction: column;
padding: 0 16px;
text-decoration: none;
}
.query-info {
display: flex;
align-items: center;
gap: 6px;
font-size: 16px;
line-height: 16px;
color: var(--gray-text);
border-bottom: 1px solid var(--gray-line);
padding: 8px 0px 20px 0px;
}
.hotel-details-provider {
display: flex;
align-items: center;
gap: 4px;
margin-top: auto;
}
.hotel-details-provider-text {
color: var(--gray-text);
font-size: 12px;
font-weight: 400;
line-height: 16px;
}
.hotel-details-provider-logo {
height: 12px;
width: 12px;
}
.savings {
display: flex;
align-items: center;
font-size: 28px;
font-weight: 700;
line-height: 32px;
gap: 4px;
}
.savings-value {
color: var(--green-text);
}
.hotel-details {
display: flex;
margin-top: 12px;
gap: 14px;
}
.hotel-details-text {
display: flex;
flex-direction: column;
}
.hotel-details-img {
height: 78px;
width: 78px;
border-radius: 4px;
min-width: 78px;
}
.hotel-details-name {
color: var(--black-white);
font-size: 16px;
line-height: 22px;
text-align: left;
overflow: hidden;
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 1;
}
.hotel-details-price {
display: flex;
align-items: center;
gap: 4px;
}
.hotel-details-price-new {
display: inline-flex;
font-weight: 600;
align-items: flex-start;
}
.hotel-details-price-new-currency {
font-size: 10px;
line-height: 14px;
padding-top: 4px;
}
.hotel-details-price-new-value {
font-size: 20px;
line-height: 28px;
}
.hotel-details-price-old {
color: var(--gray-text);
font-size: 12px;
line-height: 14px;
text-decoration-line: line-through;
padding-top: 4px;
}
.hotel-details-price-nights {
color: var(--black-white);
font-size: 12px;
line-height: 16px;
padding-top: 4px;
}
.adsIcon {
display: flex;
border: 1px solid var(--ad-slug);
margin-right: 4px;
font-weight: 600;
font-size: 10px;
line-height: 14px;
color: var(--ad-slug);
padding: 0 5px;
border-radius: 10px;
}
.book-on-provider {
text-decoration: none;
border-radius: 4px;
border: 1px solid #1C79CA;
background: #036AC4;
display: flex;
padding: 6px;
justify-content: center;
color: #FFFFFF;
text-align: center;
font-size: 14px;
margin-top: 14px;
}
@media (prefers-color-scheme: dark) {
.card-container {
--black-white: #FEFEFE;
--gray-text: #B8B8B8;
--green-text: #7FDA91;
--gray-line: #FFFFFF3D;
--ad-slug: #B8B8B8;
}
.provider-details svg {
path: #B8B8B8;
}
}
`,xd=$n`
<div class="query-info">
<div tabindex="0">${e=>e.stayDatesString}</div>
<div tabindex="0">${e=>e.roomsGuestsString}</div>
</div>
`,Td=$n`
<div class="savings" tabindex="0">
${e=>e.saveString}
<div class="savings-value">${e=>e.maximumSavingsString}</div>
</div>
`,wd=$n`
<div class="hotel-details">
<img class="hotel-details-img" src="${e=>e.propertyImage}" alt=${e=>e.propertyName} />
<div class="hotel-details-text">
<div class="hotel-details-name" tabindex="0">${e=>e.propertyName}</div>
<div class="hotel-details-price">
<div class="hotel-details-price-new" tabindex="0">
<div class="hotel-details-price-new-currency">${e=>e.cheapestPriceCurrencyString}</div>
<div class="hotel-details-price-new-value">${e=>e.cheapestPriceValueString}</div>
</div>
<div class="hotel-details-price-old">${e=>e.originalPriceString}</div>
<div class="hotel-details-price-nights" tabindex="0">${e=>e.perRoomPerNightString}</div>
</div>
<div class="hotel-details-provider">
<p class="adsIcon" tabindex="0">Ad</p>
<img class="hotel-details-provider-logo" src="${e=>e.cheapestProviderLogo}" alt=${e=>e.cheapestProviderName} />
<div class="hotel-details-provider-text" tabindex="0">${e=>e.cheapestProviderName}</div>
</div>
</div>
</div>
`,Od=$n`
<a
href="${e=>e.providerBookNowUrl}"
target="_blank"
class="book-on-provider"
@click=${(e,t)=>e.bookOnProviderClicked(t.event)}
>
${e=>e.getDealNowString}
</a>
`,Pd=$n`
<template>
<div class="card-container">
${Td}
${xd}
${wd}
${Od}
</div>
</template>
`,Ad=bd.compose({baseName:"travel-cheaper-hotel-card",shadowOptions:{delegatesFocus:!0},styles:Sd,template:(e,t)=>$n`
${Pd}
`});function Ed(){return(navigator?.language??Intl?.NumberFormat()?.resolvedOptions()?.locale)||""}let kd=function(e){return e[e.OneWay=1]="OneWay",e[e.RoundTrip=2]="RoundTrip",e}({});const Id="travel_click";let Dd=function(e){return e.CheapFlights="CheapFlights",e.CheapItinerary="CheapItinerary",e.CheapHotelRoom="CheapHotelRoom",e}({});function _d(e,t=60,i=60){return e?e.ThumbnailId?`https://bing.com/th?id=${e.ThumbnailId}&w=${i}&h=${t}`:e.SourceUrl?e.SourceUrl:"":""}class Nd extends zi{constructor(){super(...arguments),this.zeroPad=(e,t)=>String(e).padStart(t,"0")}connectedCallback(){super.connectedCallback()}get strings(){var e,t,i,n,o,r,a,s,l,c,d,u,h,p,g,f,m,v,y,C,b,S,x,T,w,O,P,A,E,k,I,D,_,N,R,M,L,B,F,U,H,$,Z,V,G,j,z,W,K,q,Y,X,J,Q,ee,te,ie,ne,oe;const re={_1Stop:null!==(i=null===(t=null===(e=this.data)||void 0===e?void 0:e.strings)||void 0===t?void 0:t._1Stop)&&void 0!==i?i:"1-stop",bookNow:null!==(r=null===(o=null===(n=this.data)||void 0===n?void 0:n.strings)||void 0===o?void 0:o.bookNow)&&void 0!==r?r:"Book Now",bookOn:null!==(l=null===(s=null===(a=this.data)||void 0===a?void 0:a.strings)||void 0===s?void 0:s.bookOn)&&void 0!==l?l:"Book on $1",bookThisFlight:null!==(u=null===(d=null===(c=this.data)||void 0===c?void 0:c.strings)||void 0===d?void 0:d.bookThisFlight)&&void 0!==u?u:"Book this flight",cheaperDealsForYou:null!==(g=null===(p=null===(h=this.data)||void 0===h?void 0:h.strings)||void 0===p?void 0:p.cheaperDealsForYou)&&void 0!==g?g:"Cheaper deals for you",for1Adult:null!==(v=null===(m=null===(f=this.data)||void 0===f?void 0:f.strings)||void 0===m?void 0:m.for1Adult)&&void 0!==v?v:"for 1 adult",forNAdults:null!==(b=null===(C=null===(y=this.data)||void 0===y?void 0:y.strings)||void 0===C?void 0:C.forNAdults)&&void 0!==b?b:"for $1 adults",nonStop:null!==(T=null===(x=null===(S=this.data)||void 0===S?void 0:S.strings)||void 0===x?void 0:x.nonStop)&&void 0!==T?T:"Non-stop",nStops:null!==(P=null===(O=null===(w=this.data)||void 0===w?void 0:w.strings)||void 0===O?void 0:O.nStops)&&void 0!==P?P:"$1-stops",oneWay:null!==(k=null===(E=null===(A=this.data)||void 0===A?void 0:A.strings)||void 0===E?void 0:E.oneWay)&&void 0!==k?k:"One way",roundTrip:null!==(_=null===(D=null===(I=this.data)||void 0===I?void 0:I.strings)||void 0===D?void 0:D.roundTrip)&&void 0!==_?_:"Round trip",save:null!==(M=null===(R=null===(N=this.data)||void 0===N?void 0:N.strings)||void 0===R?void 0:R.save)&&void 0!==M?M:"Save",saveUpto:null!==(F=null===(B=null===(L=this.data)||void 0===L?void 0:L.strings)||void 0===B?void 0:B.saveUpto)&&void 0!==F?F:"Save upto",moreOptions:null!==($=null===(H=null===(U=this.data)||void 0===U?void 0:U.strings)||void 0===H?void 0:H.moreOptions)&&void 0!==$?$:"More options",weFoundTheBestFlightForYou:null!==(G=null===(V=null===(Z=this.data)||void 0===Z?void 0:Z.strings)||void 0===V?void 0:V.weFoundTheBestFlightForYou)&&void 0!==G?G:"We found the best flight for you!",getSameFlightAtCheaperPrice:null!==(W=null===(z=null===(j=this.data)||void 0===j?void 0:j.strings)||void 0===z?void 0:z.getSameFlightAtCheaperPrice)&&void 0!==W?W:"Get same flight at cheaper price!",getDeal:null!==(Y=null===(q=null===(K=this.data)||void 0===K?void 0:K.strings)||void 0===q?void 0:q.getDeal)&&void 0!==Y?Y:"Get deal"};return(null!==(J=null===(X=this.flightQuery)||void 0===X?void 0:X.Adults)&&void 0!==J?J:1)>1&&(re.for1Adult=null!==(oe=null===(te=null===(ee=null===(Q=this.data)||void 0===Q?void 0:Q.strings)||void 0===ee?void 0:ee.forNAdults)||void 0===te?void 0:te.replace("$1",(null!==(ne=null===(ie=this.flightQuery)||void 0===ie?void 0:ie.Adults)&&void 0!==ne?ne:1).toString()))&&void 0!==oe?oe:""),re}get flightQuery(){var e,t;return null===(t=null===(e=this.data)||void 0===e?void 0:e.flightSearchResponse)||void 0===t?void 0:t.FlightQuery}get flightResults(){var e,t,i;return null===(i=null===(t=null===(e=this.data)||void 0===e?void 0:e.flightSearchResponse)||void 0===t?void 0:t.FlightResults)||void 0===i?void 0:i.slice(0,1)}get cheapestFlight(){var e;return null===(e=this.flightResults)||void 0===e?void 0:e[0]}get cheapestBookingOption(){var e,t;return null===(t=null===(e=this.cheapestFlight)||void 0===e?void 0:e.BookingOptions)||void 0===t?void 0:t[0]}get totalSavings(){var e;return Cd(null===(e=this.flightQuery)||void 0===e?void 0:e.MaximumPrice,this.cheapestPrice)}get isItineraryMatch(){var e;return(null===(e=this.data)||void 0===e?void 0:e.cardType)===Dd.CheapItinerary}get originIata(){var e,t;return null!==(t=null===(e=this.flightQuery)||void 0===e?void 0:e.OriginIata)&&void 0!==t?t:""}get destinationIata(){var e,t;return null!==(t=null===(e=this.flightQuery)||void 0===e?void 0:e.DestinationIata)&&void 0!==t?t:""}get dateString(){return" • "+this.startDate+(this.isRoundTrip?" - "+this.returnDate:"")+" • "+(this.isRoundTrip?this.strings.roundTrip:this.strings.oneWay)}get startDate(){var e;return this.getDataString(null===(e=this.flightQuery)||void 0===e?void 0:e.StartDate)}get returnDate(){var e;return this.getDataString(null===(e=this.flightQuery)||void 0===e?void 0:e.ReturnDate)}get isRoundTrip(){var e;return(null===(e=this.flightQuery)||void 0===e?void 0:e.Type)===kd.RoundTrip}get cheapestPrice(){var e;return null===(e=this.cheapestBookingOption)||void 0===e?void 0:e.Price}get cheapestPriceString(){return this.FormatPrice(this.cheapestPrice)}get totalSavingsString(){return this.FormatPrice(this.totalSavings)}get cheapestFlightImage(){var e;return _d(null===(e=this.cheapestFlight)||void 0===e?void 0:e.Logo,60,60)}get cheapestBookingOptionImage(){var e;return _d(null===(e=this.cheapestBookingOption)||void 0===e?void 0:e.Logo,18,18)}get ctaUrl(){var e,t,i,n,o,r,a;return null!==(a=null!==(n=null!==(t=null===(e=this.cheapestBookingOption)||void 0===e?void 0:e.Link)&&void 0!==t?t:null===(i=this.cheapestFlight)||void 0===i?void 0:i.TravelHubUrl)&&void 0!==n?n:null===(r=null===(o=this.data)||void 0===o?void 0:o.flightSearchResponse)||void 0===r?void 0:r.RedirectionUrl)&&void 0!==a?a:""}get ctaText(){var e;return null!==(e=this.strings.getDeal)&&void 0!==e?e:""}getFlightAirlineName(e){var t,i,n,o;return e&&Array.isArray(null==e?void 0:e.OutboundFlights)&&0!==(null!==(i=null===(t=null==e?void 0:e.OutboundFlights)||void 0===t?void 0:t.length)&&void 0!==i?i:0)&&null!==(o=null===(n=e.OutboundFlights[0].Airline)||void 0===n?void 0:n.Name)&&void 0!==o?o:""}getFlightBookingLink(e){var t,i,n;return e&&Array.isArray(null==e?void 0:e.BookingOptions)&&0!==(null!==(i=null===(t=null==e?void 0:e.BookingOptions)||void 0===t?void 0:t.length)&&void 0!==i?i:0)&&null!==(n=e.BookingOptions[0].Link)&&void 0!==n?n:""}getFlightImageUrl(e){var t,i,n,o;return(null==e?void 0:e.Logo)?_d(null==e?void 0:e.Logo,50,50):(null===(i=null===(t=null==e?void 0:e.OutboundFlights)||void 0===t?void 0:t[0])||void 0===i?void 0:i.Logo)?_d(null===(o=null===(n=null==e?void 0:e.OutboundFlights)||void 0===n?void 0:n[0])||void 0===o?void 0:o.Logo,50,50):""}getFlightPriceString(e){var t,i;return e&&Array.isArray(null==e?void 0:e.BookingOptions)&&0!==(null!==(i=null===(t=null==e?void 0:e.BookingOptions)||void 0===t?void 0:t.length)&&void 0!==i?i:0)?this.FormatPrice(e.BookingOptions[0].Price):""}getFlightStops(e){var t,i,n,o,r,a;if(!e||!Array.isArray(null==e?void 0:e.OutboundFlights)||0===(null!==(i=null===(t=null==e?void 0:e.OutboundFlights)||void 0===t?void 0:t.length)&&void 0!==i?i:0))return"";const s=[],l=e.OutboundFlights.length;let c="";switch(l){case 1:c=null!==(n=this.strings.nonStop)&&void 0!==n?n:"";break;case 2:c=null!==(o=this.strings._1Stop)&&void 0!==o?o:"";break;default:c=null!==(a=null===(r=this.strings.nStops)||void 0===r?void 0:r.replace("$1",l.toString()))&&void 0!==a?a:""}if(s.push(c),e.Duration){const t=[];e.Duration&&(!isNaN(e.Duration.Hour)&&e.Duration.Hour>0&&t.push(e.Duration.Hour+"h"),!isNaN(e.Duration.Minute)&&e.Duration.Minute>0&&t.push(e.Duration.Minute+"m")),t.length>0&&s.push(t.join(" "))}return s.join(" • ")}getFlightTimings(e){var t,i;if(!e||!Array.isArray(null==e?void 0:e.OutboundFlights)||0===(null!==(i=null===(t=null==e?void 0:e.OutboundFlights)||void 0===t?void 0:t.length)&&void 0!==i?i:0))return"";const n=e.OutboundFlights[0].DepartureTime,o=e.OutboundFlights[e.OutboundFlights.length-1].ArrivalTime;return`${this.getTimeString(n)} - ${this.getTimeString(o)}`}getFlightAdultCountString(e){var t,i;return 0===(null!==(i=null===(t=this.flightQuery)||void 0===t?void 0:t.Adults)&&void 0!==i?i:0)?"":this.strings.for1Adult}getFlightExtraDays(e){var t,i,n,o;if(!Array.isArray(null==e?void 0:e.OutboundFlights))return"";const r=e.OutboundFlights.length;if(r<=1)return"";const a=e.OutboundFlights[r-1],s=e.OutboundFlights[0],l=(null!==(i=null===(t=null==a?void 0:a.DepartureTime)||void 0===t?void 0:t.Day)&&void 0!==i?i:0)-(null!==(o=null===(n=null==s?void 0:s.DepartureTime)||void 0===n?void 0:n.Day)&&void 0!==o?o:0);return l>0?"+"+l+"D":""}getFlightSavings(e){var t,i,n;if(!e||!Array.isArray(null==e?void 0:e.BookingOptions)||0===(null!==(i=null===(t=null==e?void 0:e.BookingOptions)||void 0===t?void 0:t.length)&&void 0!==i?i:0))return null;const o=e.BookingOptions[0].Price;return Cd(null===(n=this.flightQuery)||void 0===n?void 0:n.MaximumPrice,o)}getFlightBookingProviderName(e){var t,i,n;return e&&Array.isArray(null==e?void 0:e.BookingOptions)&&0!==(null!==(i=null===(t=null==e?void 0:e.BookingOptions)||void 0===t?void 0:t.length)&&void 0!==i?i:0)&&null!==(n=e.BookingOptions[0].ProviderName)&&void 0!==n?n:""}flightCardClicked(e,t){return null==e||e.preventDefault(),null==e||e.stopPropagation(),this.SendClickEvent("FlightCardClicked",t),!1}ctaClicked(e){return null==e||e.preventDefault(),null==e||e.stopPropagation(),this.SendClickEvent("BookOnProviderClicked",this.cheapestFlight),!1}getDataString(e){var t;if(!e)return"";try{const i={day:"numeric",month:"short"},n=Ed(),o=new Date(e);return o instanceof Date&&!isNaN(o.valueOf())&&null!==(t=o.toLocaleString(n,i))&&void 0!==t?t:""}catch(e){return""}}getTimeString(e){var t,i;if(!e)return"";const n=(null==e?void 0:e.Hour)>=12?(null==e?void 0:e.Hour)-12:null!==(t=null==e?void 0:e.Hour)&&void 0!==t?t:0,o=null!==(i=null==e?void 0:e.Minute)&&void 0!==i?i:0,r=(null==e?void 0:e.Hour)>=12?"PM":"AM";return`${this.zeroPad(n,2)}:${this.zeroPad(o,2)} ${r}`}FormatPrice(e){var t,i,n;const o=null!==(t=null==e?void 0:e.Value)&&void 0!==t?t:0;return isNaN(o)||0==o?"":`${null!==(i=null==e?void 0:e.CurrencySymbol)&&void 0!==i?i:""}${null!==(n=Math.trunc(o))&&void 0!==n?n:""}`}SendClickEvent(e,t){var n,o,r,a,s,l,c,d,u,h,p,g,f;const m=this.getFlightSavings(t),v=e,y=null===(n=this.data)||void 0===n?void 0:n.cardType,C="Summary",b=null!==(r=null===(o=null==t?void 0:t.MetaData)||void 0===o?void 0:o.Index)&&void 0!==r?r:-1,S=this.getFlightBookingProviderName(t),x=null!==(a=null==m?void 0:m.Value)&&void 0!==a?a:-1,T=null!==(s=null==m?void 0:m.CurrencySymbol)&&void 0!==s?s:"#",w=null!==(d=null===(c=null===(l=this.flightQuery)||void 0===l?void 0:l.MaximumPrice)||void 0===c?void 0:c.Value)&&void 0!==d?d:-1,O=null!==(p=null===(h=null===(u=this.flightQuery)||void 0===u?void 0:u.MaximumPrice)||void 0===h?void 0:h.CurrencySymbol)&&void 0!==p?p:"#",P=null!==(g=null==t?void 0:t.NumberOfStops)&&void 0!==g?g:-1,A=null===(f=this.data)||void 0===f?void 0:f.clientActivityId,E=this.getFlightBookingLink(t);var k,I;k=this,I={Message:`${v}_${y}_${C}_${b}_${S}_${x}_${T}_${w}_${O}_${P}_${A}`,ButtonName:i.$S.TravelFlightCardClicked,UrlToRedirect:E,ClientActivityId:A,Metadata:Object.assign({cardClicked:v,scenario:y,variant:C,index:b,provider:S,expectedSavings:x,currency:T,minimumPriceOnPage:w,minimumPriceOnPageCurrency:O,numberOfStops:P,clientActivityId:A},null==t?void 0:t.Telemetry)},k.$emit&&k.$emit(Id,I)}}(0,an.gn)([oi.LO],Nd.prototype,"data",void 0),(0,an.gn)([oi.lk],Nd.prototype,"strings",null),(0,an.gn)([oi.lk],Nd.prototype,"flightQuery",null),(0,an.gn)([oi.lk],Nd.prototype,"flightResults",null),(0,an.gn)([oi.lk],Nd.prototype,"cheapestFlight",null),(0,an.gn)([oi.lk],Nd.prototype,"cheapestBookingOption",null),(0,an.gn)([oi.lk],Nd.prototype,"totalSavings",null),(0,an.gn)([oi.lk],Nd.prototype,"isItineraryMatch",null),(0,an.gn)([oi.lk],Nd.prototype,"originIata",null),(0,an.gn)([oi.lk],Nd.prototype,"destinationIata",null),(0,an.gn)([oi.lk],Nd.prototype,"dateString",null),(0,an.gn)([oi.lk],Nd.prototype,"startDate",null),(0,an.gn)([oi.lk],Nd.prototype,"returnDate",null),(0,an.gn)([oi.lk],Nd.prototype,"isRoundTrip",null),(0,an.gn)([oi.lk],Nd.prototype,"cheapestPrice",null),(0,an.gn)([oi.lk],Nd.prototype,"cheapestPriceString",null),(0,an.gn)([oi.lk],Nd.prototype,"totalSavingsString",null),(0,an.gn)([oi.lk],Nd.prototype,"cheapestFlightImage",null),(0,an.gn)([oi.lk],Nd.prototype,"cheapestBookingOptionImage",null),(0,an.gn)([oi.lk],Nd.prototype,"ctaUrl",null),(0,an.gn)([oi.lk],Nd.prototype,"ctaText",null);const Rd=dn`
${dn`
.flight-card {
display: flex;
flex-direction: column;
gap: 4px;
height: 96px;
width: 96px;
border-radius: 8px;
border: 1px solid #ECECEC;
align-items: center;
background-color: var(--light-gray);
text-decoration: none;
padding: 4px;
position: relative;
}
.flight-card-icon {
max-width: 100%;
max-height: 100%;
display: flex;
align-items: center;
}
.flight-card-icon-img {
max-width: 100%;
max-height: 100%;
width: 100%;
border-radius: 8px;
}
.flight-card-booking-option {
display: flex;
flex-direction: column;
align-items: flex-end;
gap: 1px;
background-color: var(--white);
color: var(--black-white);
padding: 2px 16px;
border-radius: 16px;
position: absolute;
bottom: 4px;
z-index: 1;
box-shadow: 0px 2px 4px rgba(0, 0, 0, 0.1);
}
.flight-card-booking-option-price {
color: var(--black-white);
font-size: 16px;
font-style: normal;
font-weight: 600;
line-height: 22px;
}
.flight-card-booking-option-provider {
display: flex;
flex-direction: row;
align-items: center;
gap: 8px;
border-radius: 436px;
border: 1px solid #CCC;
background: #FFF;
padding: 0px 8px;
}
@media (prefers-color-scheme: dark) {
.flight-card-booking-option-provider {
background: rgba(255, 255, 255, 0.12);
}
}
.flight-card-booking-option-provider-logo {
height: 21px;
}
.flight-card-booking-option-provider-logo-img {
height: 100%;
}
.flight-card-booking-option-provider-name {
color: var(--black-white);
font-size: 12px;
font-style: normal;
font-weight: 400;
line-height: 16px;
}
`}
${dn`
h1,h2 {
margin: 0;
}
a {
text-decoration: none;
}
.card-container {
--white: #FEFEFE;
--black-white: #1A1A1A;
--gray: #737373;
--light-gray: #F0F0F0;
--dark-gray: #676767;
--savings-value-color: #008A20;
--divider-color: #EBEBEB;
--action-button-background-color: #036AC4;
--action-button-text-color: white;
--ad-slug: #737373;
display: flex;
flex-direction: column;
padding: 0 16px;
text-decoration: none;
}
@media (prefers-color-scheme: dark) {
.card-container {
--white: #1A1A1A;
--black-white: #FEFEFE;
--gray: #b8b8b8;
--light-gray: #F0F0F0;
--dark-gray: #e9e9e9;
--savings-value-color: #7FDA91;
--divider-color: #6E6E6E;
--action-button-background-color: #036AC4;
--action-button-text-color: white;
--ad-slug: #B8B8B8;
}
}
.card-content {
display: flex;
flex-direction: row;
justify-content: space-between;
align-items: center;
margin-bottom: 4px;
}
.savings {
display: flex;
flex-direction: column;
gap: 2px;
}
.savings-declaration {
color: var(--black-white);
font-size: 20px;
font-style: normal;
font-weight: 700;
line-height: 10px;
text-align: left;
}
.savings-value {
color: var(--savings-value-color);
font-size: 64px;
font-style: normal;
font-weight: 700;
line-height: 72px;
}
.flights {
display: flex;
flex-direction: column;
}
.divider {
border: 1px solid var(--divider-color);
margin: 8px 0;
}
.banner {
text-align: center;
font-size: 14px;
font-weight: 600;
line-height: 22px;
margin: 0px;
display: flex;
flex-direction: row;
justify-content: center;
align-items: center;
}
.cheaper-price {
color: var(--savings-value-color);
}
.provider {
display: flex;
flex-direction: row;
gap: 4px;
align-items: center;
}
.provider-icon {
height: 18px;
}
.provider-icon img{
height: 100%;
}
.provider-name {
color: var(--black-white);
font-size: 18px;
font-weight: 400;
line-height: 18px;
}
.adsIcon {
display: flex;
border: 1px solid var(--ad-slug);
margin-right: 4px;
font-weight: 600;
font-size: 10px;
line-height: 14px;
color: var(--ad-slug);
padding: 0 5px;
border-radius: 10px;
}
${dn`
.card-footer {
display: flex;
flex-direction: row;
justify-content: space-between;
gap: 10px;
}
.action-button {
text-decoration: none;
padding: 6px 20px;
font-size: 14px;
font-weight: 600;
line-height: 20px;
width: 100%;
text-align: center;
border-radius: 4px;
background: var(--action-button-background-color);
color: var(--action-button-text-color);
margin-top: 11px;
}`}
`}
`,Md=$n`<svg width="12" height="12" viewBox="0 0 16 20" fill="currentcolor" xmlns="http://www.w3.org/2000/svg"> <path d="M10.7824 0.219651L15.2774 4.71441C15.5435 4.98047 15.5679 5.39676 15.3505 5.69038L15.278 5.77451L10.783 10.2794C10.4904 10.5726 10.0155 10.5731 9.7223 10.2805C9.4558 10.0145 9.4311 9.5979 9.6486 9.3041L9.7212 9.2199L12.938 5.997L1.24219 5.99766C0.862487 5.99766 0.548698 5.71551 0.499028 5.34943L0.492188 5.24766C0.492188 4.86797 0.774338 4.55417 1.14042 4.50451L1.24219 4.49766L12.94 4.497L9.7218 1.28035C9.4555 1.01409 9.4313 0.597431 9.6491 0.303811L9.7217 0.219691C9.988 -0.046589 10.4047 -0.0708092 10.6983 0.147041L10.7824 0.219651L15.2774 4.71441L10.7824 0.219651ZM15.5002 14.6491L15.507 14.7509C15.507 15.1306 15.2249 15.4444 14.8588 15.494L14.757 15.5009L3.06103 15.5L6.2822 18.7194C6.5486 18.9856 6.5729 19.4023 6.3552 19.696L6.2826 19.7801C6.0165 20.0465 5.59982 20.0709 5.30612 19.8531L5.22197 19.7806L0.721968 15.2843C0.455588 15.0182 0.431208 14.6015 0.648938 14.3078L0.721528 14.2237L5.22153 9.7199C5.5143 9.4269 5.98917 9.4267 6.2822 9.7194C6.5486 9.9856 6.5729 10.4023 6.3552 10.696L6.2826 10.7801L3.06503 14L14.757 14.0009C15.1367 14.0009 15.4505 14.283 15.5002 14.6491L15.507 14.7509L15.5002 14.6491Z" fill="currentcolor"/> </svg>`,Ld=$n`<svg width="15" height="15" viewBox="0 2 20 20" fill="currentcolor" style="transform: rotate(90deg);" xmlns="http://www.w3.org/2000/svg"> <path d="M6.71965 8.71474L11.2144 4.21969C11.4805 3.95361 11.8968 3.9292 12.1904 4.14661L12.2745 4.21909L16.7794 8.71415C17.0726 9.00672 17.0731 9.4816 16.7805 9.77481C16.5145 10.0414 16.0979 10.066 15.8041 9.84849L15.7199 9.77596L12.497 6.55911L12.4977 19.2549C12.4977 19.6346 12.2155 19.9484 11.8494 19.9981L11.7477 20.0049C11.368 20.0049 11.0542 19.7228 11.0045 19.3567L10.9977 19.2549L10.997 6.55711L7.78035 9.77537C7.51409 10.0416 7.09743 10.0659 6.80381 9.84802L6.71969 9.7754C6.45341 9.50914 6.42919 9.09248 6.64704 8.79886L6.71965 8.71474L11.2144 4.21969L6.71965 8.71474Z" fill="currentcolor" /> </svg>`,Bd=$n`
<a
class="flight-card"
target="_blank"
href="${(e,t)=>t.parent.getFlightBookingLink(e)}"
@click=${(e,t)=>t.parent.flightCardClicked(t.event,e)}
>
<div class="flight-card-icon">
<img class="flight-card-icon-img" src="${(e,t)=>t.parent.getFlightImageUrl(e)}" alt="${(e,t)=>t.parent.getFlightAirlineName(e)}"/>
</div>
<div class="flight-card-booking-option">
<div class="flight-card-booking-option-price">
${(e,t)=>t.parent.getFlightPriceString(e)}
</div>
</div>
</a>
`,Fd=Nd.compose({baseName:"travel-cheaper-flight-card",shadowOptions:{delegatesFocus:!0},styles:Rd,template:(e,t)=>$n`
<template>
<div class="card-container">
<a class="card-content" href="${(e,t)=>e.getFlightBookingLink(e.cheapestFlight)}" @click=${(e,t)=>e.flightCardClicked(t.event,e.cheapestFlight)}>
<div class="savings" aria-label="${e=>e.strings.save+" "+e.totalSavingsString}">
<div class="savings-declaration">${e=>e.strings.save+" "} </div>
<div class="savings-value">${e=>e.totalSavingsString}</div>
<div class="provider">
<p class="adsIcon" tabindex="0">Ad</p>
<div class="provider-icon">
<img src="${e=>e.cheapestBookingOptionImage}" alt="${e=>{var t;return null===(t=e.cheapestBookingOption)||void 0===t?void 0:t.ProviderName}}"/>
</div>
<div class="provider-name">${e=>{var t;return null===(t=e.cheapestBookingOption)||void 0===t?void 0:t.ProviderName}}</div>
</div>
</div>
<div class="flights">
${Sl((e=>{var t;return null!==(t=e.flightResults)&&void 0!==t?t:[]}),$n`
${Bd}
`)}
</div>
</a>
<div class="divider"></div>
<div class="banner">
Book a <div class="cheaper-price">cheaper flight</div> for ${e=>e.originIata} ${e=>e.isRoundTrip?Md:Ld} ${e=>e.destinationIata}
</div>
<div class="card-footer">
<a class="action-button" href="${e=>e.ctaUrl}" target="_blank" @click=${(e,t)=>e.ctaClicked(t.event)}>${e=>e.ctaText}</a>
</div>
</div>
</template>
`});class Ud extends Zo{constructor(){super(...arguments),this.hasAnnotation=!1,this.isEmpty=!1,this.addingItem=!1}}(0,an.gn)([pn.Lj],Ud.prototype,"description",void 0),(0,an.gn)([pn.Lj],Ud.prototype,"currency",void 0),(0,an.gn)([pn.Lj],Ud.prototype,"price",void 0),(0,an.gn)([pn.Lj],Ud.prototype,"hundredthText",void 0),(0,an.gn)([pn.Lj],Ud.prototype,"retailer",void 0),(0,an.gn)([pn.Lj],Ud.prototype,"changes",void 0),(0,an.gn)([oi.LO],Ud.prototype,"hasAnnotation",void 0),(0,an.gn)([oi.LO],Ud.prototype,"isEmpty",void 0),(0,an.gn)([oi.LO],Ud.prototype,"addingItem",void 0);const Hd=dn`
${zn("grid")} :host {
--content-max-lines: 2;
outline: none;
font-family: ${qn.SVJ};
font-size: ${qn.sNp};
font-weight: 600;
line-height: ${qn.vgC};
min-width: calc(${Lo} * 1px);
border-radius: calc(${qn.rSr} * 1px);
box-sizing: border-box;
color: ${qn.CHi};
fill: currentcolor;
cursor: pointer;
height: 100px;
position: relative;
}
:host {
display: block;
box-sizing: border-box;
}
.control:${No} {
box-shadow: 0 0 0 calc(${qn.vxp} * 1px) ${qn.yGg};
}
.emptyProductCardWrapper {
display: block;
height: 100%;
width: 100%;
align-items: center;
gap: 15px;
padding: 12px 16px;
box-sizing: border-box;
text-decoration: none;
outline: none;
border: none;
color: inherit;
fill: inherit;
border-radius: 8px;
position: relative;
}
.aProductCardWrapper {
display: grid;
grid-template-columns: 66px 1fr auto;
height: 100px;
width: 100%;
align-items: center;
gap: 15px;
padding: 12px 16px;
box-sizing: border-box;
text-decoration: none;
background: transparent;
outline: none;
border: none;
color: inherit;
fill: inherit;
border-radius: 0px;
position: relative;
}
.isFirst {
border-top: none!important;
}
.divPriceInfo {
display: flex;
flex-direction: row;
justify-content: flex-start;
row-gap: 5px;
}
.optionsIcon {
display: inline-block;
flex-direction: column;
justify-content: flex-end;
background-color: transparent;
}
.smallerPrice {
display: inline-block;
padding-top: 5px;
font-size: 11px;
line-height: 12px;
}
.divLowestPrice {
width: auto;
height: 22px;
background-color: #DE3700;
border-radius: 4px;
display: flex;
justify-content: center;
align-items: center;
padding-left: 8px;
padding-right: 8px;
letter-spacing: 0.02em;
}
.txtPrice {
font-size: 16px;
line-height: 24px;
text-align: right;
color: var(--text-price-color, rgba(0, 0, 0, 0.83));
font-weight: 700;
display: flex;
}
.prodTxtName {
display: -webkit-box;
-webkit-line-clamp: 1;
-webkit-box-orient: vertical;
overflow: hidden;
font-weight: 700;
font-size: 14px;
}
.emptyMessage {
display: -webkit-box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
font-weight: 600;
font-size: 20px;
line-height: 26px;
text-align: center;
margin: 5px 20px;
}
.txtSavings {
font-size: 11px;
line-height: 16px;
text-align: right;
color: var(--text-green-savings-color);
font-weight: 400;
}
.txtRetailer {
font-size: 15px;
line-height: 16px;
text-align: left;
align-self: center;
font-weight: normal;
color: var(--text-neutral-foreground-hint);
}
.divTopAnnotation {
display: grid;
grid-template-columns: auto 1fr;
align-items: center;
}
.divAttribution {
display: grid;
grid-template-columns: auto minmax(0px, 1fr);
}
.divTextContent {
display: flex;
flex-direction: column;
row-gap: 0px;
padding: 5px;
min-width: 0;
}
::slotted([slot="view-steps"]) {
display: none;
}
::slotted([slot="previous-price"]) {
text-align: end;
}
::slotted([slot="delete"]) {
position: absolute;
right: 0px;
top: 0px;
z-index: 10;
}
::slotted([slot="image"]) {
max-width: 66px;
max-height: 66px;
}
@media (prefers-color-scheme: dark) {
.txtRetailer {
color: var(--text-retailer-color, #FFFFFF);
}
.txtPrice {
color: var(--text-price-color, #FFFFFF);
}
.divLowestPrice {
background: rgba(49, 191, 82, 0.1);
}
}
`.withBehaviors(Gn(dn`
:host {
forced-color-adjust: auto;
}
:host .control:hover,
:host .control:${No} {
forced-color-adjust: none;
box-shadow: inset 0 0 0 calc((${qn.Han} * 1px)) ${Ns.ButtonText};
}
:host([href]),
:host([href]) .control {
color: ${Ns.LinkText};
border-color: ${Ns.LinkText};
}
:host([href]) .control:hover,
:host([href]) .control:${No} {
forced-color-adjust: none;
box-shadow: inset 0 0 0 calc((${qn.Han} * 1px)) ${Ns.LinkText};
}
::slotted([slot="image"]),
::slotted([slot="start"]),
::slotted([slot="end"]) {
color: ${Ns.ButtonText};
fill: currentcolor;
}
`)),$d=Ud.compose({baseName:"wishlist-card",shadowOptions:{delegatesFocus:!0},styles:Hd,template:(e,t)=>$n`
<template>
<a
class="${e=>e.isEmpty?"emptyProductCardWrapper control":"aProductCardWrapper control"}"
part="control"
${vo("control")}
download="${e=>e.download}"
href="#"
hreflang="${e=>e.hreflang}"
ping="${e=>e.ping}"
referrerpolicy="${e=>e.referrerpolicy}"
rel="${e=>e.rel}"
target="${e=>e.target}"
type="${e=>e.type}"
aria-atomic="${e=>e.ariaAtomic}"
aria-busy="${e=>e.ariaBusy}"
aria-controls="${e=>e.ariaControls}"
aria-current="${e=>e.ariaCurrent}"
aria-describedBy="${e=>e.ariaDescribedby}"
aria-details="${e=>e.ariaDetails}"
aria-disabled="${e=>e.ariaDisabled}"
aria-errormessage="${e=>e.ariaErrormessage}"
aria-expanded="${e=>e.ariaExpanded}"
aria-flowto="${e=>e.ariaFlowto}"
aria-haspopup="${e=>e.ariaHaspopup}"
aria-hidden="${e=>e.ariaHidden}"
aria-invalid="${e=>e.ariaInvalid}"
aria-keyshortcuts="${e=>e.ariaKeyshortcuts}"
aria-label="${e=>e.ariaLabel}"
aria-labelledby="${e=>e.ariaLabelledby}"
aria-live="${e=>e.ariaLive}"
aria-owns="${e=>e.ariaOwns}"
aria-relevant="${e=>e.ariaRelevant}"
aria-roledescription="${e=>e.ariaRoledescription}">
<style>
${Wr((e=>e.hasAnnotation),$n`
.aProductCardWrapper {
height: 115px!important;
}
`)}
${Wr((e=>e.isEmpty),$n`
.emptyProductCardWrapper {
cursor: default;
}
`)}
</style>
${Wr((e=>e.isEmpty),$n`
<slot name="empty-image"></slot>
`)}
${Wr((e=>!e.isEmpty),$n`
<slot name="image"></slot>
`)}
<div class="divTextContent" part="divTextContent">
${Wr((e=>e.isEmpty),$n`
<slot name="empty-content"></slot>
<slot name="view-steps"></slot>
`)}
${Wr((e=>e.description),$n`<span class=${e=>e.isEmpty?e.addingItem?"addingTxtMessage":"emptyMessage":"prodTxtName"} title="${e=>e.description}">${e=>e.description}</span>`)}
<div class="divPriceInfo" part="divPriceInfo">
<span class="txtPrice" part="txtPrice">
<div class="smallerPrice">
${e=>e.currency}
</div>
<div>
${e=>e.price}
</div>
<div class="smallerPrice">
${e=>e.hundredthText}
</div>
</div>
</span>
${Wr((e=>e.changes),$n`
<span class="txtSavings" part="txtSavings">
${e=>e.changes}</span>`)}
<slot name="previous-price"></slot>
${Wr((e=>!e.isEmpty),$n`
<div class="divTopAnnotation">
<msft-attribution class="divAttribution" part="divAttribution">
<span class="txtRetailer" title="${e=>e.retailer}">${e=>e.retailer}</span>
</msft-attribution>
</div>`)}
</div>
<slot name="end">
</div>
${Wr((e=>!e.isEmpty&&!e.addingItem),$n`
<fluent-button class="optionsIcon">
<svg xmlns="http://www.w3.org/2000/svg" width="14" height="12" viewBox="0 0 14 12">
<path d="M1 5C1.14062 5 1.27083 5.02604 1.39062 5.07812C1.51042 5.13021 1.61458 5.20312 1.70312 5.29688C1.79688 5.38542 1.86979 5.48958 1.92188 5.60938C1.97396 5.72917 2 5.85938 2 6C2 6.14062 1.97396 6.27083 1.92188 6.39062C1.86979 6.51042 1.79688 6.61719 1.70312 6.71094C1.61458 6.79948 1.51042 6.86979 1.39062 6.92188C1.27083 6.97396 1.14062 7 1 7C0.859375 7 0.729167 6.97396 0.609375 6.92188C0.489583 6.86979 0.382812 6.79948 0.289062 6.71094C0.200521 6.61719 0.130208 6.51042 0.078125 6.39062C0.0260417 6.27083 0 6.14062 0 6C0 5.85938 0.0260417 5.72917 0.078125 5.60938C0.130208 5.48958 0.200521 5.38542 0.289062 5.29688C0.382812 5.20312 0.489583 5.13021 0.609375 5.07812C0.729167 5.02604 0.859375 5 1 5ZM7 5C7.14062 5 7.27083 5.02604 7.39062 5.07812C7.51042 5.13021 7.61458 5.20312 7.70312 5.29688C7.79688 5.38542 7.86979 5.48958 7.92188 5.60938C7.97396 5.72917 8 5.85938 8 6C8 6.14062 7.97396 6.27083 7.92188 6.39062C7.86979 6.51042 7.79688 6.61719 7.70312 6.71094C7.61458 6.79948 7.51042 6.86979 7.39062 6.92188C7.27083 6.97396 7.14062 7 7 7C6.85938 7 6.72917 6.97396 6.60938 6.92188C6.48958 6.86979 6.38281 6.79948 6.28906 6.71094C6.20052 6.61719 6.13021 6.51042 6.07812 6.39062C6.02604 6.27083 6 6.14062 6 6C6 5.85938 6.02604 5.72917 6.07812 5.60938C6.13021 5.48958 6.20052 5.38542 6.28906 5.29688C6.38281 5.20312 6.48958 5.13021 6.60938 5.07812C6.72917 5.02604 6.85938 5 7 5ZM13 5C13.1406 5 13.2708 5.02604 13.3906 5.07812C13.5104 5.13021 13.6146 5.20312 13.7031 5.29688C13.7969 5.38542 13.8698 5.48958 13.9219 5.60938C13.974 5.72917 14 5.85938 14 6C14 6.14062 13.974 6.27083 13.9219 6.39062C13.8698 6.51042 13.7969 6.61719 13.7031 6.71094C13.6146 6.79948 13.5104 6.86979 13.3906 6.92188C13.2708 6.97396 13.1406 7 13 7C12.8594 7 12.7292 6.97396 12.6094 6.92188C12.4896 6.86979 12.3828 6.79948 12.2891 6.71094C12.2005 6.61719 12.1302 6.51042 12.0781 6.39062C12.026 6.27083 12 6.14062 12 6C12 5.85938 12.026 5.72917 12.0781 5.60938C12.1302 5.48958 12.2005 5.38542 12.2891 5.29688C12.3828 5.20312 12.4896 5.13021 12.6094 5.07812C12.7292 5.02604 12.8594 5 13 5Z"></path>
</svg>
</fluent-button>
`)}
${Wr((e=>e.addingItem),$n`<span id="saveItemBtn" />`)}
</a>
</template>
`});class Zd extends zi{constructor(){super(...arguments),this.balanceCards=[],this.hasTransactions=!1}}(0,an.gn)([oi.LO],Zd.prototype,"balanceCards",void 0),(0,an.gn)([oi.LO],Zd.prototype,"hasTransactions",void 0),(0,an.gn)([oi.LO],Zd.prototype,"onBalanceClick",void 0),(0,an.gn)([oi.LO],Zd.prototype,"chevronRight",void 0);const Vd=dn`
.container {
display: flex;
height: 72px;
padding: 0px;
justify-content: space-around;
align-items: flex-start;
align-self: stretch;
}
.cardTitle {
font-size: 12px;
text-align: center;
line-height: 16px;
color:${qn.Q5n};
margin-top: 12px;
}
.cardAmount {
text-align: center;
font-weight: 600;
line-height: 28px;
font-size: 20px;
color:${qn.CHi};
margin-top: 4px;
padding: 0px 0px 12px 0px;
display: flex;
align-items: center;
justify-content: center;
font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;
border: none;
background: transparent;
}
.cardAmount.availableBalance {
color: ${qn.Avx};
margin-left: 7px;
cursor: pointer;
}
.cardAmount.grayedOut,
.cardAmount.availableBalance.grayedOut {
color: ${qn.Q5n};
opacity: 0.5;
cursor: default;
}
.boxWrapper {
display: flex;
flex-direction: column;
justify-content: flex-start;
align-items: center;
height: 100%;
flex: 1 0 0;
}
.boxWrapper:not(:last-child) {
border-right: 1px solid ${qn.dtw};
}
.rightChevron {
padding-top: 2px;
}
`,Gd=$n`
<div>
<fluent-card class="container">
${Sl((e=>e.balanceCards),$n`
<div class="boxWrapper">
<div class="cardTitle">${e=>e.title}</div>
${e=>e.isAvailableBalance?$n`
<button
class="cardAmount availableBalance"
@click="${(e,t)=>t.parent.hasTransactions?t.parent.onBalanceClick():null}"
>
<span>${e=>e.amount}</span>
${Wr(((e,t)=>t.parent.hasTransactions),$n`<img
src="${(e,t)=>t.parent.chevronRight}"
class="rightChevron"
/>`)}
</button>
`:$n`
<div class="cardAmount">
<span>${e=>e.amount}</span>
</div>
`}
</div>
`)}
</fluent-card>
</div>
`,jd=Zd.compose({baseName:"cb-balance-card",styles:Vd,template:Gd});class zd extends zi{constructor(){super(...arguments),this.transactions=[],this.isLong=!1,this.ShortListLength=5,this.LongListLength=50}toggleHistoryLength(){this.onToggleHistoryLength(),this.isLong=!this.isLong}getMaxNumberOfRows(){const e=this.transactions.length;return this.isLong?Math.min(e,this.LongListLength):Math.min(e,this.ShortListLength)}isExpandableList(){return this.transactions.length>this.ShortListLength}getFooterString(){return this.isLong?this.seeLessString:this.seeMoreString}}(0,an.gn)([oi.LO],zd.prototype,"transactions",void 0),(0,an.gn)([oi.LO],zd.prototype,"totalTransactions",void 0),(0,an.gn)([oi.LO],zd.prototype,"headerString",void 0),(0,an.gn)([oi.LO],zd.prototype,"seeFullString",void 0),(0,an.gn)([oi.LO],zd.prototype,"seeMoreString",void 0),(0,an.gn)([oi.LO],zd.prototype,"seeLessString",void 0),(0,an.gn)([oi.LO],zd.prototype,"seeAllIcon",void 0),(0,an.gn)([oi.LO],zd.prototype,"arrowDownIcon",void 0),(0,an.gn)([oi.LO],zd.prototype,"isLong",void 0),(0,an.gn)([oi.LO],zd.prototype,"onSeeFullClick",void 0),(0,an.gn)([oi.LO],zd.prototype,"onToggleHistoryLength",void 0);const Wd=dn`
.main-container {
margin-top: 24px;
}
.header,
.footer {
font-size: 14px;
font-weight: 600;
color: var(--color-neutral-foreground-1, #000000db);
}
.header {
display: flex;
justify-content: space-between;
align-items: center;
line-height: 20px;
margin-bottom: 12px;
color: ${qn.CHi};
}
.see-full {
display: flex;
align-items: center;
justify-content: center;
}
.footer {
margin-top: 17px;
display: flex;
align-items: center;
justify-content: center;
}
.see-full-button,
.footer-button {
display: flex;
align-items: center;
border: none;
cursor: pointer;
background: transparent;
}
.see-full-text {
color: ${qn.CHi};
margin-left: 7px;
}
.footer-text {
color: ${qn.CHi};
margin-right: 7px;
}
.transaction-card {
display: block;
padding: 12px 16px;
box-sizing: border-box;
border-bottom: 1px solid ${qn.dtw};
}
.transaction-card.last-item {
border-bottom: none;
}
.top {
font-size: 14px;
font-weight: 600;
color: ${qn.CHi};
}
.bottom {
margin-top: 4px;
font-size: 12px;
font-weight: 400;
color: ${qn.Q5n};
}
.top,
.bottom {
display: flex;
justify-content: space-between;
align-items: center;
line-height: 20px;
}
.merchant-group {
display: flex;
align-items: center;
}
.merchant-logo {
height: 16px;
width: 16px;
}
.merchant-name {
margin-left: 7px;
}
.arrowIcon {
padding-bottom: 3px;
}
.flip {
transform: rotate(180deg);
}
`;function Kd(e,t,i){try{return new Intl.NumberFormat(t||"en-us",{style:"currency",currency:i||"usd"}).format(e)}catch(e){return""}}const qd=$n`
${Wr((e=>e.transactions.length>0),$n`
<div class="main-container">
<div class="header">
<div>${e=>e.headerString}</div>
<div class="see-full-container">
<button class="see-full-button" @click="${e=>e.onSeeFullClick()}">
<img src="${e=>e.seeAllIcon}" />
${Wr((e=>e.totalTransactions),$n`<span class="see-full-text"
>${e=>`${e.seeFullString} (${e.totalTransactions})`}</span
>`)}
</button>
</div>
</div>
<fluent-card>
${Sl((e=>e.transactions.slice(0,e.getMaxNumberOfRows())),$n`
<div
class=${(e,t)=>"transaction-card"+(t.index===t.parent.getMaxNumberOfRows()-1?" last-item":"")}
>
<div class="top">
<div class="merchant-group">
${e=>e.merchantLogo?$n`
<img
class="merchant-logo"
src=${e=>e.merchantLogo}
alt="merchant logo"
/>
`:$n`<msft-first-letter-logo
word="${e=>e.merchantName}"
></msft-first-letter-logo>`}
<span class="merchant-name">${e=>e.merchantName}</span>
</div>
<span class="transaction-amount">${e=>e.commission}</span>
</div>
<div class="bottom">
<span class="transaction-date">${e=>e.orderDate}</span>
<span class="transaction-state">${e=>function(e){return e?e.charAt(0).toUpperCase()+e.slice(1).toLowerCase():e}(e.state)}</span>
</div>
</div>
`,{positioning:!0})}
</fluent-card>
${Wr((e=>e.isExpandableList()),$n`
<div class="footer">
<button class="footer-button" @click="${e=>e.toggleHistoryLength()}">
<span class="footer-text">${e=>e.getFooterString()}</span>
<img src="${e=>e.arrowDownIcon}" class="arrowIcon${e=>e.isLong?" flip":""}" />
</button>
</div>
`)}
</div>
`)}
`,Yd=zd.compose({baseName:"cb-transaction-history",styles:Wd,template:qd});class Xd extends zi{constructor(){super(...arguments),this.word="",this.textColor="",this.backgroundColor=""}connectedCallback(){super.connectedCallback();const e=this.pickColors();this.textColor=e.textColor,this.backgroundColor=e.backgroundColor}pickColors(){const e=Math.floor(7*Math.random())+0;return{textColor:["#264587","#C42E00","#0F754B","#950DDE","#B8166F","#8A5A00","#006F91"][e],backgroundColor:["#E0EDFF","#FFE7DE","#DCFAED","#F5E5FF","#FFDEEC","#FFF5D9","#DCF4FC"][e]}}}(0,an.gn)([pn.Lj],Xd.prototype,"word",void 0),(0,an.gn)([oi.LO],Xd.prototype,"textColor",void 0),(0,an.gn)([oi.LO],Xd.prototype,"backgroundColor",void 0);const Jd=dn`
.logo {
display: flex;
align-items: center;
justify-content: center;
width: 16px;
height: 16px;
font-size: 14px;
font-weight: 600;
border-radius: 2px 0px 0px 0px;
border: 0.5px 0px 0px 0px;
}
`,Qd=$n`
<span class="logo" style="${e=>`color: ${e.textColor}; background-color: ${e.backgroundColor};`}"
>${e=>e.word.charAt(0).toUpperCase()}</span
>
`,eu=Xd.compose({baseName:"first-letter-logo",styles:Jd,template:Qd});class tu extends zi{}(0,an.gn)([pn.Lj],tu.prototype,"headerText",void 0),(0,an.gn)([pn.Lj],tu.prototype,"bodyText",void 0);const iu=dn`
.container {
padding: 12px 16px 12px 16px;
font-size: 12px;
line-height: 16px;
color: #000000DB;
background: #e0edff;
margin-top: 8px;
border: none;
box-shadow: none;
}
.headerText {
font-weight: 600;
}
.bodyText {
font-weight: 400;
margin-top: 4px;
}
`,nu=$n`
<fluent-card class="container">
<div class="headerText">${e=>e.headerText}</div>
<div class="bodyText">${e=>e.bodyText}</div>
</fluent-card>
`,ou=tu.compose({baseName:"cb-welcome-banner",styles:iu,template:nu});class ru extends zi{constructor(){super(...arguments),this.isSignedInUser=!1,this.isRebatesUser=!1,this.selectedImage=0,this.images=[{src:"https://groceryassets.blob.core.windows.net/publicassets/cashback-dashboard/cashbackCarousel1.png",alt:"Computer monitor with Microsoft Edge open, displaying a prompt of available cash back",caption:""},{src:"https://groceryassets.blob.core.windows.net/publicassets/cashback-dashboard/cashbackCarousel2.png",alt:"Price tags with a percent symbol",caption:""},{src:"https://groceryassets.blob.core.windows.net/publicassets/cashback-dashboard/cashbackCarousel3.png",alt:"Wallet with balloons and confetti",caption:""}],this.IntervalTimeMs=5e3}joinRebates(){var e;return(0,an.mG)(this,void 0,void 0,(function*(){this.actionCallbacks.joinRebates();try{if(!this.isSignedInUser){const t=yield this.pageHandlerFunctions.SignInToEdgeProfile(!0);"MSA"===(null===(e=JSON.parse(t.result))||void 0===e?void 0:e.accountType)&&(this.isSignedInUser=!0)}this.isSignedInUser&&(this.pageHandlerFunctions.ActivateRebates(!0),this.isRebatesUser=!0)}catch(e){this.actionCallbacks.error(e)}}))}onLearnMore(){this.actionCallbacks.learnMore(),this.pageHandlerFunctions.NavigateToBingRebates()}onMsRewards(){this.actionCallbacks.msRewards(),this.pageHandlerFunctions.NavigateToMicrosoftRewards()}onTerms(){this.actionCallbacks.terms(),this.pageHandlerFunctions.NavigateToTermsStatement()}onPrivacy(){this.actionCallbacks.privacy(),this.pageHandlerFunctions.NavigateToPrivacyCookiesStatement()}setImage(e){this.selectedImage=e%this.images.length,clearInterval(this.interval),this.interval=setInterval((()=>this.nextImage()),this.IntervalTimeMs)}nextImage(){this.selectedImage=(this.selectedImage+1)%this.images.length}connectedCallback(){super.connectedCallback(),this.interval=setInterval((()=>this.nextImage()),this.IntervalTimeMs),this.images=this.images.map(((e,t)=>Object.assign(Object.assign({},e),{caption:this.captions[t]})));const e=this.legalese.split("$1");this.legalesePart1=e[0],this.legalesePart2=e[1]}disconnectedCallback(){super.disconnectedCallback(),clearInterval(this.interval)}}(0,an.gn)([pn.Lj],ru.prototype,"pageHandlerFunctions",void 0),(0,an.gn)([pn.Lj],ru.prototype,"actionCallbacks",void 0),(0,an.gn)([pn.Lj],ru.prototype,"captions",void 0),(0,an.gn)([pn.Lj],ru.prototype,"legalese",void 0),(0,an.gn)([pn.Lj],ru.prototype,"learnMoreText",void 0),(0,an.gn)([pn.Lj],ru.prototype,"termsText",void 0),(0,an.gn)([pn.Lj],ru.prototype,"privacyText",void 0),(0,an.gn)([pn.Lj],ru.prototype,"enrollSuccessTitle",void 0),(0,an.gn)([pn.Lj],ru.prototype,"enrollSuccessLink",void 0),(0,an.gn)([oi.LO],ru.prototype,"onWelcomeLinkClick",void 0),(0,an.gn)([oi.LO],ru.prototype,"isSignedInUser",void 0),(0,an.gn)([oi.LO],ru.prototype,"isRebatesUser",void 0),(0,an.gn)([oi.LO],ru.prototype,"legalesePart1",void 0),(0,an.gn)([oi.LO],ru.prototype,"legalesePart2",void 0),(0,an.gn)([oi.LO],ru.prototype,"selectedImage",void 0),(0,an.gn)([oi.LO],ru.prototype,"interval",void 0),(0,an.gn)([oi.LO],ru.prototype,"images",void 0);const au=$n`
<div class="container">
<div class="carousel-container">
${Sl((e=>e.images),$n`
<div class="carousel-item${(e,t)=>t.index!==t.parent.selectedImage?" carousel-hide":""}">
<div class="image-wrapper">
<img class="image" src="${e=>e.src}" alt="${e=>e.alt}" />
</div>
<div class="caption">${e=>e.caption}</div>
</div>
`,{positioning:!0})}
</div>
<div class="switcher">
${Sl((e=>e.images),$n`
<span
@click=${(e,t)=>t.parent.setImage(t.index)}
class="${(e,t)=>t.index===t.parent.selectedImage?"active-dot":"dot"}"
></span>
`,{positioning:!0})}
</div>
${Wr((e=>!e.isRebatesUser),$n`
<div>
<div class="button-row">
<fluent-button @click=${e=>e.joinRebates()} appearance="accent" class="button-accent"
>Join Microsoft Cashback</fluent-button
>
</div>
<div class="legal">
<a @click=${e=>e.onLearnMore()} class="learnMore">${e=>e.learnMoreText}</a> —
${e=>e.legalesePart1}<a @click=${e=>e.onMsRewards()}>Microsoft Rewards</a>${e=>e.legalesePart2}<br /><a @click=${e=>e.onTerms()}>${e=>e.termsText}</a> |
<a @click=${e=>e.onPrivacy()}>${e=>e.privacyText}</a>
</div>
</div>
`)}
${Wr((e=>e.isRebatesUser),$n`
<div class="is-enroled">
<div class="welcome-row">
<div class="welcome-box big-star-box">
<img
src="https://groceryassets.blob.core.windows.net/publicassets/cashback-dashboard/BigPinkStar.png"
alt="Big pink star"
/>
</div>
<div class="welcome-box welcome-message">
<p>${e=>e.enrollSuccessTitle}</p>
</div>
<div class="welcome-box big-star-box">
<img
src="https://groceryassets.blob.core.windows.net/publicassets/cashback-dashboard/BigBlueStar.png"
alt="Big blue star"
/>
</div>
</div>
<div class="welcome-row">
<div class="welcome-box small-star-box">
<img
src="https://groceryassets.blob.core.windows.net/publicassets/cashback-dashboard/SmallBlueStar.png"
alt="Small Blue star"
/>
</div>
<div class="welcome-box welcome-button-box">
<button class="welcome-button" @click="${e=>e.onWelcomeLinkClick()}">
${e=>e.enrollSuccessLink}
</button>
</div>
<div class="welcome-box small-star-box">
<img
src="https://groceryassets.blob.core.windows.net/publicassets/cashback-dashboard/SmallPinkStar.png"
alt="Small Pink star"
/>
</div>
</div>
</div>
`)}
</div>
`,su=dn`
.container {
margin-top: 12px;
}
.carousel-container {
display: flex;
overflow: hidden;
}
@keyframes fade {
from {
opacity: 0.3;
}
to {
opacity: 1;
}
}
.carousel-item {
flex: 0 0 100%;
transition: transform 0.3s ease;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
animation-name: fade;
animation-duration: 0.5s;
}
.carousel-hide {
display: none;
animation-name: fade;
animation-duration: 0.5s;
}
.image-wrapper {
height: 193.5px;
width: 100%;
background: linear-gradient(236.16deg, #a8d5ff -43.08%, #d5d7ff 88.63%);
border-radius: 8px;
display: flex;
justify-content: center;
align-items: center;
}
.image {
height: 171.23px;
width: 265.85px;
box-shadow: 0px 1.08px 6.46px 0px #00000029;
border-radius: 8px;
}
.caption {
margin-top: 12px;
font-weight: 400;
font-size: 16px;
text-align: center;
line-height: 22px;
}
.switcher {
margin-top: 12px;
display: flex;
justify-content: center;
align-items: center;
gap: 8px;
}
.active-dot {
background: ${qn.CHi};
height: 8px;
width: 16px;
border-radius: 40em;
cursor: pointer;
}
.dot {
height: 4px;
width: 4px;
background: ${qn.Ttg};
border-radius: 50%;
cursor: pointer;
}
.button-row {
margin-top: 12px;
display: flex;
justify-content: center;
align-items: center;
}
.button-accent {
background: #2169eb;
height: 32px;
width: 203px;
font-weight: 600;
font-size: 14px;
}
.legal {
margin-top: 12px;
font-size: 10px;
color: ${qn.Q5n};
line-height: 14px;
text-align: center;
}
a {
text-decoration: none;
color: ${qn.goi};
cursor: pointer;
}
.learnMore {
font-weight: 600;
}
.is-enroled {
margin-top: 12px;
}
.welcome-row {
display: flex;
height: 20px;
}
.welcome-box {
display: flex;
justify-content: center;
align-items: center;
}
.big-star-box {
width: 53px;
}
.welcome-message {
width: 238px;
font-size: 14px;
font-weight: 600;
color: ${qn.CHi};
}
.small-star-box {
width: 22px;
}
.welcome-button-box {
width: 300px;
}
.welcome-button {
border: none;
cursor: pointer;
font-size: 14px;
font-weight: 400;
color: ${qn.goi};
background: transparent;
}
`,lu=ru.compose({baseName:"cashback-carousel",template:au,styles:su});class cu extends zi{constructor(){super(...arguments),this.titleText="You have $1 ready to cash out.",this.linkText="Redeem your cash back",this.amount=0,this.currency="usd",this.onLinkClick=()=>{},this.isOpened=!0,this.handleCloseClick=()=>{this.onCloseClick(),this.isOpened=!1},this.handleLinkClick=()=>{this.onLinkClick()}}}(0,an.gn)([oi.LO],cu.prototype,"titleText",void 0),(0,an.gn)([oi.LO],cu.prototype,"linkText",void 0),(0,an.gn)([oi.LO],cu.prototype,"moneyIcon",void 0),(0,an.gn)([oi.LO],cu.prototype,"closeIcon",void 0),(0,an.gn)([oi.LO],cu.prototype,"amount",void 0),(0,an.gn)([oi.LO],cu.prototype,"currency",void 0),(0,an.gn)([oi.LO],cu.prototype,"onLinkClick",void 0),(0,an.gn)([oi.LO],cu.prototype,"onCloseClick",void 0),(0,an.gn)([oi.LO],cu.prototype,"isOpened",void 0);const du=$n`
${Wr((e=>e.isOpened),$n`
<div>
<fluent-card class="redeem-banner">
<img src="${e=>e.moneyIcon}" class="icon" />
<div>
${e=>e.titleText.split("$1")[0]}
<b>${e=>Kd(e.amount,void 0,e.currency)} </b> ${e=>e.titleText.split("$1")[1]}
<button class="link" @click=${e=>e.handleLinkClick()}>${e=>e.linkText}</button>
</div>
<button class="iconButton" aria-label="Close redeem banner" @click=${e=>e.handleCloseClick()}>
<img src="${e=>e.closeIcon}" class="close" />
</button>
</fluent-card>
</div>
`)}
`,uu=dn`
.redeem-banner {
display: flex;
gap: 12px;
padding: 16px;
font-size: 14px;
line-height: 20px;
margin-top: 8px;
}
.link {
color: ${qn.Avx};
font-weight: 600;
text-decoration: none;
cursor: pointer;
font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;
border: none;
background: transparent;
padding-left: 0;
padding-right: 0;
}
.icon {
margin-top: 4px;
}
.iconButton {
padding: 0px;
background: none;
border: none;
cursor: pointer;
align-items: center;
}
.close {
height: 20px;
width: 20px;
}
`,hu=cu.compose({baseName:"cb-redeem-banner",template:du,styles:uu}),pu=$n`
<button
class="icon-button"
@click="${e=>e.handleClick()}"
>
<img
class="icon"
src="${e=>e.src}"
/>
</button>
`;class gu extends zi{constructor(){super(...arguments),this.src="",this.handleClick=()=>{}}}(0,an.gn)([pn.Lj],gu.prototype,"src",void 0),(0,an.gn)([pn.Lj],gu.prototype,"handleClick",void 0);const fu=dn`
.icon-button {
padding: 2px;
background: none;
border: none;
cursor: pointer;
align-items: center;
width: 100%;
height: 100%;
}
.icon {
width: 100%;
height: 100%;
}
`,mu=gu.compose({baseName:"icon-button",template:pu,styles:fu}),vu=$n`
<div class="offer-item" @click=${e=>"true"===e.isMobile?e.handleLinkClick():null}>
<div class="left">
<div class="title">
${e=>e.src?$n`<img
class="icon"
src="${e=>e.src}"
alt="merchant logo"
/>`:$n`<msft-first-letter-logo
word="${e=>e.brand}"
></msft-first-letter-logo>`}
<b class="brand"> ${e=>e.brand} </b>
</div>
<div class="timer">${e=>e.endsIn}</div>
</div>
<div class="right">
<div class="offer">
<img src="${e=>e.cashbackTag}" />
<div class="offer_title">
${e=>`${e.offer} ${e.offerPostfix.split("$1")[0]}${e.minPurchaseValue}${e.offerPostfix.split("$1")[1]}`}
</div>
</div>
${Wr((e=>"true"!==e.isMobile),$n`
<button class="link" @click=${e=>e.handleLinkClick()}> ${e=>e.linkText} </button>`)}
</div>
</div>`,yu=dn`
.offer-item {
display: flex;
justify-content: space-between;
padding: 12px 16px;
font-size: 12px;
line-height: 16px;
}
.title {
display: flex;
gap: 8px;
height: 22px;
align-items: center;
color: ${qn.CHi};
}
.icon {
width: 16px;
height: 16px;
}
.brand {
display: block
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
font-size: 16px;
font-weight: 600;
line-height: 22px;
text-align: start;
}
.timer {
margin-top: 8px;
color: rgba(0, 0, 0, 0.74);
font-weight: 400;
color: ${qn.CHi};
text-align: start;
}
.offer {
display: flex;
justify-content: flex-end;
gap: 4px;
align-items: center;
height: 22px;
}
.offer_title {
font-size: 12px;
font-style: normal;
font-weight: 600;
color: ${qn.CHi};
}
.link {
display: flex;
margin-top: 8px;
align-items: center;
gap: 4px;
font-weight: 400;
text-decoration: none;
cursor: pointer;
color: ${qn.Avx};
font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;
border: none;
background: transparent;
padding-left: 0;
padding-right: 0;
}
.link_icon {
width: 12px;
height: 12px;
}
.left {
overflow: hidden;
margin-right: 5px;
}
.right {
display: flex;
flex-direction: column;
align-items: flex-end;
flex-shrink: 0;
}
`;class Cu extends zi{constructor(){super(...arguments),this.linkText="Continue shopping",this.offerPostfix="back",this.src="",this.brand="",this.offer="",this.endsIn="",this.href="",this.minPurchaseValue="",this.isMobile="false",this.handleLinkClick=()=>{this.onLinkClick(this.href)}}}(0,an.gn)([pn.Lj],Cu.prototype,"linkText",void 0),(0,an.gn)([pn.Lj],Cu.prototype,"offerPostfix",void 0),(0,an.gn)([pn.Lj],Cu.prototype,"src",void 0),(0,an.gn)([pn.Lj],Cu.prototype,"brand",void 0),(0,an.gn)([pn.Lj],Cu.prototype,"offer",void 0),(0,an.gn)([pn.Lj],Cu.prototype,"endsIn",void 0),(0,an.gn)([pn.Lj],Cu.prototype,"href",void 0),(0,an.gn)([pn.Lj],Cu.prototype,"onLinkClick",void 0),(0,an.gn)([pn.Lj],Cu.prototype,"cashbackTag",void 0),(0,an.gn)([pn.Lj],Cu.prototype,"minPurchaseValue",void 0),(0,an.gn)([pn.Lj],Cu.prototype,"isMobile",void 0);const bu=Cu.compose({baseName:"cb-activated-ad-retailer-offer",template:vu,styles:yu}),Su=dn`
.ad-offer-list {
margin-top: 12px
}
`,xu=$n`
<div>
<fluent-card class="ad-offer-list">
${Sl((e=>JSON.parse(e.offers)),$n`<msft-cb-activated-ad-retailer-offer
src=${e=>e.src}
brand=${e=>e.brand}
offer=${e=>e.offer}
offerPostfix=${(e,t)=>t.parent.offerPostfix}
endsIn=${e=>e.endsIn}
href=${e=>e.href}
linkText=${(e,t)=>t.parent.linkText}
:onLinkClick=${(e,t)=>t.parent.onLinkClick}
cashbackTag=${(e,t)=>t.parent.cashbackTag}
minPurchaseValue=${e=>e.minPurchaseValue}
isMobile=${(e,t)=>t.parent.isMobile}
></msft-cb-activated-ad-retailer-offer>`)}
</fluent-card>
</div>
`;class Tu extends zi{constructor(){super(...arguments),this.linkText="Continue shopping",this.offerPostfix="back",this.offers="",this.isMobile="false"}}(0,an.gn)([pn.Lj],Tu.prototype,"linkText",void 0),(0,an.gn)([pn.Lj],Tu.prototype,"offerPostfix",void 0),(0,an.gn)([pn.Lj],Tu.prototype,"offers",void 0),(0,an.gn)([pn.Lj],Tu.prototype,"onLinkClick",void 0),(0,an.gn)([pn.Lj],Tu.prototype,"cashbackTag",void 0),(0,an.gn)([pn.Lj],Tu.prototype,"isMobile",void 0);const wu=Tu.compose({baseName:"cb-activated-ad-retailer-offer-list",template:xu,styles:Su});class Ou extends zi{constructor(){super(...arguments),this.linkText="View item",this.offerPostfix="back",this.isMobile="false",this.handleLinkClick=()=>{this.onLinkClick(this.href)}}}(0,an.gn)([pn.Lj],Ou.prototype,"linkText",void 0),(0,an.gn)([pn.Lj],Ou.prototype,"offerPostfix",void 0),(0,an.gn)([pn.Lj],Ou.prototype,"productImageUrl",void 0),(0,an.gn)([pn.Lj],Ou.prototype,"retailerLogoUrl",void 0),(0,an.gn)([pn.Lj],Ou.prototype,"retailerName",void 0),(0,an.gn)([pn.Lj],Ou.prototype,"offerValue",void 0),(0,an.gn)([pn.Lj],Ou.prototype,"offerDescription",void 0),(0,an.gn)([pn.Lj],Ou.prototype,"endsIn",void 0),(0,an.gn)([pn.Lj],Ou.prototype,"href",void 0),(0,an.gn)([pn.Lj],Ou.prototype,"cashbackTag",void 0),(0,an.gn)([pn.Lj],Ou.prototype,"seeAllIcon",void 0),(0,an.gn)([pn.Lj],Ou.prototype,"onLinkClick",void 0),(0,an.gn)([pn.Lj],Ou.prototype,"isMobile",void 0);const Pu=dn`
.offer {
padding: 16px;
display: flex;
}
.product-image-container {
width: 76px;
height: 76px;
background-color: white;
border-radius: 4px;
}
.product-image {
max-width: 76px;
max-height: 76px;
width: 100%;
height: 100%;
object-fit: contain;
border-radius: 4px;
}
.content {
margin-inline-start: 12px;
display: flex;
flex-direction: column;
gap: 8px;
flex: 1
}
.header {
display: flex;
justify-content: space-between;
align-items: center;
font-weight: 600;
font-size: 12px;
line-height: 16px;
}
.left {
display: flex;
align-items: center;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
flex-grow: 1;
min-width: 0;
}
.icon {
width: 16px;
height: 16px;
}
.retailer-name {
margin-left: 8px;
overflow: hidden;
text-align: start;
text-overflow: ellipsis;
color: ${qn.CHi};
flex-grow: 1;
}
.right {
display: flex;
flex-shrink: 0;
align-items: center;
}
.offer-value {
margin-left: 4px;
}
.description {
color: ${qn.Q5n};
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 2;
overflow: hidden;
height: 28px;
text-align: start;
text-overflow: ellipsis;
font-size: 10px;
font-weight: 400;
line-height: 14px;
}
.footer {
display: flex;
justify-content: space-between;
font-size: 12px;
font-weight: 400;
line-height: 16px;
}
.link {
color: ${qn.Avx};
cursor: pointer;
display: flex;
align-items: center;
font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;
border: none;
background: transparent;
padding-left: 0;
padding-right: 0;
}
.link_icon {
width: 12px;
height: 12px;
margin-left: 6px;
}
`,Au=$n`
<div class="offer" @click=${e=>"true"===e.isMobile?e.handleLinkClick():null}>
<div class="product-image-container">
<img class="product-image" src="${e=>e.productImageUrl}" alt="product picture" />
</div>
<div class="content">
<div class="header">
<div class="left">
<img class="icon" src="${e=>e.retailerLogoUrl}" alt="retailer logo" />
<span class="retailer-name">${e=>e.retailerName}</span>
</div>
<div class="right">
<img src="${e=>e.cashbackTag}" />
<span class="offer-value">${e=>e.offerValue} ${e=>e.offerPostfix}</span>
</div>
</div>
<span class="description">${e=>e.offerDescription}</span>
<div class="footer">
<span class="timer">${e=>e.endsIn}</span>
${Wr((e=>"true"!==e.isMobile),$n`
<button class="link" @click=${e=>e.handleLinkClick()}>
${e=>e.linkText}
<img src="${e=>e.seeAllIcon}" class="link_icon" />
</button>`)}
</div>
</div>
</div>
`,Eu=Ou.compose({baseName:"cb-activated-product-offer",styles:Pu,template:Au});class ku extends zi{constructor(){super(...arguments),this.linkText="Continue shopping",this.offerPostfix="back",this.offers="",this.isMobile="false"}}(0,an.gn)([pn.Lj],ku.prototype,"linkText",void 0),(0,an.gn)([pn.Lj],ku.prototype,"offerPostfix",void 0),(0,an.gn)([pn.Lj],ku.prototype,"offers",void 0),(0,an.gn)([pn.Lj],ku.prototype,"onLinkClick",void 0),(0,an.gn)([pn.Lj],ku.prototype,"cashbackTag",void 0),(0,an.gn)([pn.Lj],ku.prototype,"seeAllIcon",void 0),(0,an.gn)([pn.Lj],ku.prototype,"isMobile",void 0);const Iu=$n`
<div>
<fluent-card class="offer-list">
${Sl((e=>JSON.parse(e.offers)),$n`<div class="item">
<msft-cb-activated-product-offer
linkText=${(e,t)=>t.parent.linkText}
offerPostfix=${(e,t)=>t.parent.offerPostfix}
productImageUrl=${e=>e.productImageUrl}
retailerLogoUrl=${e=>e.retailerLogoUrl}
retailerName=${e=>e.retailerName}
offerValue=${e=>e.offerValue}
offerDescription=${e=>e.offerDescription}
endsIn=${e=>e.endsIn}
href=${e=>e.href}
:onLinkClick=${(e,t)=>t.parent.onLinkClick}
cashbackTag=${(e,t)=>t.parent.cashbackTag}
seeAllIcon=${(e,t)=>t.parent.seeAllIcon}
isMobile=${(e,t)=>t.parent.isMobile}
></msft-cb-activated-product-offer>
</div>`)}
</fluent-card>
</div>
`,Du=dn`
.offer-list {
margin-top: 8px;
}
.item:not(:last-child) {
border-bottom: 1px solid ${qn.dtw};
}
`,_u=ku.compose({baseName:"cb-activated-product-offer-list",template:Iu,styles:Du});class Nu extends zi{constructor(){super(...arguments),this.productOffers=[],this.retailerOffers=[],this.productOffersLinkText="Continue shopping",this.productOffersTagPostfix="back",this.retailerOffersLinkText="Continue shopping",this.retailerOffersTagPostfix="back",this.cashbackHistoryText="Cashback history",this.isMobile="false",this.ShortListLength=5,this.LongListLength=50}toggleHistoryLength(){this.isLong=!this.isLong}getMaxNumberOfRows(){const e=this.getListLength();return this.isLong?Math.min(e,this.LongListLength):Math.min(e,this.ShortListLength)}isExpandableList(){return this.getListLength()>this.ShortListLength}getFooterString(){return this.isLong?this.seeLessString:this.seeMoreString}getListLength(){return this.productOffers.length+this.retailerOffers.length}}(0,an.gn)([oi.LO],Nu.prototype,"productOffers",void 0),(0,an.gn)([oi.LO],Nu.prototype,"retailerOffers",void 0),(0,an.gn)([oi.LO],Nu.prototype,"headerString",void 0),(0,an.gn)([oi.LO],Nu.prototype,"seeFullString",void 0),(0,an.gn)([oi.LO],Nu.prototype,"seeMoreString",void 0),(0,an.gn)([oi.LO],Nu.prototype,"seeLessString",void 0),(0,an.gn)([oi.LO],Nu.prototype,"isLong",void 0),(0,an.gn)([oi.LO],Nu.prototype,"onSeeFullClick",void 0),(0,an.gn)([oi.LO],Nu.prototype,"arrowDownIcon",void 0),(0,an.gn)([oi.LO],Nu.prototype,"productOffersLinkText",void 0),(0,an.gn)([oi.LO],Nu.prototype,"productOffersTagPostfix",void 0),(0,an.gn)([oi.LO],Nu.prototype,"productOffersOnLinkClick",void 0),(0,an.gn)([oi.LO],Nu.prototype,"retailerOffersLinkText",void 0),(0,an.gn)([oi.LO],Nu.prototype,"retailerOffersTagPostfix",void 0),(0,an.gn)([oi.LO],Nu.prototype,"retailerOffersOnLinkClick",void 0),(0,an.gn)([oi.LO],Nu.prototype,"cashbackTag",void 0),(0,an.gn)([oi.LO],Nu.prototype,"seeAllIcon",void 0),(0,an.gn)([oi.LO],Nu.prototype,"cashbackHistoryText",void 0),(0,an.gn)([oi.LO],Nu.prototype,"isMobile",void 0);const Ru=dn`
.main-container {
margin-top: 24px;
}
.header,
.footer {
font-size: 14px;
font-weight: 600;
color: ${qn.CHi};
}
.header {
display: flex;
justify-content: space-between;
align-items: center;
line-height: 20px;
margin-bottom: 12px;
}
.mobile-header {
font-size: 18px;
line-height: 24px;
font-weight: 600;
}
.see-full {
display: flex;
align-items: center;
justify-content: center;
}
.footer {
margin-top: 17px;
display: flex;
align-items: center;
justify-content: center;
}
.see-full-container {
display: none; // temporarily disabled
}
.see-full-button,
.footer-button {
display: flex;
align-items: center;
border: none;
cursor: pointer;
background: transparent;
}
.flip {
transform: rotate(180deg);
}
.footer-logo {
padding-bottom: 3px;
}
.see-full-text {
margin-left: 7px;
}
.footer-text {
margin-right: 7px;
}
.transaction-card {
display: block;
padding: 12px 16px;
box-sizing: border-box;
border-bottom: 1px solid ${qn.dtw};
}
.transaction-card.last-item {
border-bottom: none;
}
.top {
font-size: 14px;
font-weight: 600;
color: ${qn.CHi};
}
.bottom {
margin-top: 4px;
font-size: 12px;
font-weight: 400;
color: ${qn.Q5n};
}
.top,
.bottom {
display: flex;
justify-content: space-between;
align-items: center;
line-height: 20px;
}
.merchant-group {
display: flex;
align-items: center;
}
.merchant-logo {
height: 16px;
width: 16px;
}
.merchant-name {
margin-left: 7px;
}
.link {
color: ${qn.Avx};
cursor: pointer;
display: flex;
align-items: center;
font-weight: 400;
}
.link_icon {
width: 16px;
height: 16px;
margin-left: 4px;
}
`,Mu=$n`
${Wr((e=>e.getListLength()>0),$n`
<div class="${e=>"true"===e.isMobile?"":"main-container"}">
<div class="header">
<div class="${e=>"true"===e.isMobile?"mobile-header":""}">${e=>e.headerString}</div>
${Wr((e=>"true"!==e.isMobile),$n`
<div class="see-full-container">
<button class="see-full-button" @click="${e=>e.onSeeFullClick()}">
<msft-cb-see-all-icon></msft-cb-see-all-icon>
<span class="see-full-text">${e=>`${e.seeFullString} (${e.getListLength()})`}</span>
</button>
</div>
`,$n`
<a class="link" @click="${e=>e.onSeeFullClick()}">
${e=>e.cashbackHistoryText}
<img src="${e=>e.seeAllIcon}" class="link_icon" />
</a>`)}
</div>
${Wr((e=>e.retailerOffers.length>0),$n`
<msft-cb-activated-ad-retailer-offer-list
linkText="${e=>e.retailerOffersLinkText}"
offerPostfix="${e=>e.retailerOffersTagPostfix}"
offers="${e=>JSON.stringify(e.retailerOffers)}"
:onLinkClick=${e=>e.retailerOffersOnLinkClick}
cashbackTag=${e=>e.cashbackTag}
isMobile=${e=>e.isMobile}
>
</msft-cb-activated-ad-retailer-offer-list>
`)}
${Wr((e=>e.productOffers.length>0),$n`
<msft-cb-activated-product-offer-list
linkText="${e=>e.productOffersLinkText}"
offerPostfix="${e=>e.productOffersTagPostfix}"
offers="${e=>JSON.stringify(e.productOffers.slice(0,e.getMaxNumberOfRows()))}"
:onLinkClick=${e=>e.productOffersOnLinkClick}
cashbackTag=${e=>e.cashbackTag}
seeAllIcon=${e=>e.seeAllIcon}
isMobile=${e=>e.isMobile}
>
</msft-cb-activated-product-offer-list>
`)}
${Wr((e=>e.isExpandableList()),$n`
<div class="footer">
<button class="footer-button" @click="${e=>e.toggleHistoryLength()}">
<span class="footer-text">${e=>e.getFooterString()}</span>
<img src="${e=>e.arrowDownIcon}" class="footer-logo${e=>e.isLong?" flip":""}" />
</button>
</div>
`)}
</div>
`)}
`,Lu=Nu.compose({baseName:"cb-activated-offers",styles:Ru,template:Mu});class Bu extends zi{constructor(){super(...arguments),this.isActive=!1}}(0,an.gn)([pn.Lj],Bu.prototype,"id",void 0),(0,an.gn)([pn.Lj],Bu.prototype,"hasVisitedCashbackTab",void 0),(0,an.gn)([pn.Lj],Bu.prototype,"isActive",void 0),(0,an.gn)([oi.LO],Bu.prototype,"balanceString",void 0),(0,an.gn)([oi.LO],Bu.prototype,"onClick",void 0);const Fu=dn`
.container {
height: 20px;
padding-left: 3px;
padding-right: 5px;
}
.cashbackPaneTabContainer {
display: flex;
height: 20px;
align-items: center;
cursor: pointer;
border-bottom: 2px solid transparent;
}
.cashbackPaneTabContainer.active {
border-bottom: 2px solid #036ec9;
}
.cashbackPaneTabIconContainer {
width: 22px;
height: 20px;
overflow: hidden;
position: relative;
flex-shrink: 0; /* Prevent shrinking */
}
.cashbackPaneTabIcon {
top: 0;
left: 0;
position: absolute;
width: 100%;
height: 100%;
object-fit: none;
}
.iconWithShadow {
opacity: 0;
animation: fadeInOut 2.5s ease-in-out 6;
}
:host([hasVisitedCashbackTab="true"]) .iconWithShadow {
display: none;
}
:host([hasVisitedCashbackTab="false"]) .iconWithShadow {
display: block;
}
@keyframes fadeInOut {
0%,
100% {
opacity: 0;
}
40%,
60% {
opacity: 1;
}
}
.cashbackPaneTabText {
font-size: 14px;
font-weight: 400;
line-height: 20px;
text-align: left;
color: ${qn.CHi};
margin-left: 3px;
}
:host([isActive="true"]) .cashbackPaneTabText {
font-weight: 600;
}
`,Uu=$n`
<div class="container" @click="${e=>e.onClick()}">
<div class="cashbackPaneTabContainer">
<div class="cashbackPaneTabIconContainer">
<img
class="cashbackPaneTabIcon"
src="https://groceryassets.blob.core.windows.net/publicassets/cashback-dashboard/LeftToRightBlueTag.png"
alt="Cashback Icon">
</img>
<img
class="cashbackPaneTabIcon iconWithShadow"
src="https://groceryassets.blob.core.windows.net/publicassets/cashback-dashboard/BlueTagWithShadow.png"
alt="Cashback Icon">
</img>
</div>
<span class="cashbackPaneTabText">${e=>e.balanceString}</span>
</div>
</div>
`,Hu=Bu.compose({baseName:"cb-tab-header",styles:Fu,template:Uu});class $u extends zi{constructor(){super(...arguments),this.offers=[],this.postTagString="",this.usageCountString="",this.titleString=""}}(0,an.gn)([pn.Lj],$u.prototype,"offers",void 0),(0,an.gn)([pn.Lj],$u.prototype,"onCardClick",void 0),(0,an.gn)([oi.LO],$u.prototype,"postTagString",void 0),(0,an.gn)([oi.LO],$u.prototype,"usageCountString",void 0),(0,an.gn)([oi.LO],$u.prototype,"titleString",void 0);const Zu=$n`
<div>
<h3 id="title">${e=>e.titleString}</h3>
<div class="container">
${Sl((e=>e.offers),$n`
<fluent-card class="card" @click=${(e,t)=>t.parent.onCardClick(e)}>
<div class="body">
<div class="items cardTitle">
<div class="cardTitleText">${e=>e.retailerName}</div>
</div>
<div class="items cardSubtitle">
<img
class="icon"
src="https://groceryassets.blob.core.windows.net/publicassets/cashback-dashboard/LeftToRightBlueTag.png"
alt="cashback icon"
/>
${(e,t)=>`${e.cashbackValue} ${t.parent.postTagString}`}
</div>
${Wr((e=>e.usageCount),$n`
<div class="items count">
${(e,t)=>{var i;return`${null===(i=e.usageCount)||void 0===i?void 0:i.toLocaleString(void 0)} ${t.parent.usageCountString}`}}
</div>
`)}
</div>
<div class="imageContainer">
<img class="image" src="${e=>e.imageUrl}" />
</div>
</fluent-card>
`)}
</div>
</div>
`,Vu=dn`
#title {
font-size: 14px;
font-weight: 600;
line-height: 20px;
}
.container {
display: grid;
grid-template-columns: 49% 1fr;
grid-template-rows: 72px 72px;
gap: 8px;
}
.card {
display: flex;
justify-content: space-between;
align-items: flex-start;
padding: 0px;
cursor: pointer;
border: none;
}
.body {
padding: 0px 8px;
display: grid;
grid-template-rows: 1fr 1fr 1fr;
height: 72px;
width: calc(100% - 88px);
}
.imageContainer {
flex-grow: 1;
height: 72px;
width: 72px;
min-width: 72px;
margin: 0px;
overflow: visible;
}
.image {
height: 100%;
width: 100%;
margin: 0px;
object-fit: cover;
overflow: visible;
}
.icon {
height: 9px;
margin-inline-end: 3px;
}
.items {
display: flex;
height: -webkit-fill-available;
line-height: 16px;
}
.cardTitle {
font-size: 12px;
font-weight: 600;
max-width: 100%;
overflow: hidden;
align-items: flex-end;
}
.cardTitleText {
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
min-width: 0;
}
.cardSubtitle {
font-weight: 600;
font-size: 11px;
align-items: center;
}
.count {
font-weight: 600;
font-size: 10px;
color: #707070;
align-items: flex-start;
}
`,Gu=$u.compose({baseName:"cb-top-offers",template:Zu,styles:Vu});var ju=o(86127),zu=o(3960),Wu=o(17609),Ku=o(81687),qu=o(8553),Yu=o(31714);class Xu extends qu.ZP{constructor(...e){super(...e),(0,s.Z)(this,"abandonedCartNotificationTrackingEnabled",void 0),(0,s.Z)(this,"assets",new class{getStyles(){return"\n .productTrackingViewContainer {\n width: 100%;\n padding: 0;\n box-sizing: border-box;\n }\n .subContainer {\n display: flex;\n padding-top: 12px;\n padding-bottom: 16px;\n }\n .iconContainer {\n position: static;\n display: flex;\n justify-content: center;\n align-items: center;\n width: 36px;\n height: 36px;\n border-radius: 50%;\n background: #F3F3F3;\n box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.08);\n }\n .trackedStateIcon {\n max-width: 20px;\n }\n .textContainer {\n flex: 1;\n text-align: left;\n padding: 0 12px 0 8px;\n }\n .trackedPriceNotifText {\n font-weight: 600;\n }\n fluent-switch {\n --design-unit: 4;\n }\n ::part(switch) {\n border: 1px solid #616161;\n }\n .checked::part(switch) {\n border: 1px solid transparent;\n background: #0F6CBD;\n }\n ::part(checked-indicator) {\n --design-unit: 4;\n background: #616161;\n border: 2px solid transparent;\n top: 2px;\n left: 2px;\n }\n .checked::part(checked-indicator) {\n background: #FFFFFF;\n left: 22px;\n }\n hr {\n border: none;\n height: 1px;\n background: #F5F5F5;\n }\n .trackedProductText {\n color: var(--accent-fill-rest);\n font-weight: 400;\n background: inherit;\n }\n .trackedProductText::part(control) {\n padding-left: 0\n }\n .retailerContainer {\n position: relative;\n left: 4px;\n top: 2px;\n }\n .subtitleContainer {\n color: var(--neutral-foreground-hint);\n font-size: 12px;\n max-width: 160px;\n display: -webkit-box;\n -webkit-box-orient: vertical;\n -webkit-line-clamp: 2;\n overflow: hidden;\n text-align: left;\n }\n "}getConciseStyles(){return"\n .productTrackingViewContainer {\n width: 100%;\n padding: 0;\n box-sizing: border-box;\n }\n .subContainer {\n display: flex;\n padding-top: 12px;\n padding-bottom: 16px;\n }\n .iconContainer {\n position: static;\n display: flex;\n justify-content: center;\n align-items: center;\n width: 36px;\n height: 36px;\n border-radius: 50%;\n background: #F3F3F3;\n box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.08);\n }\n .textContainer {\n flex: 1;\n text-align: left;\n padding: 0 12px 0 8px;\n }\n .trackedPriceNotifText {\n font-weight: 600;\n }\n fluent-switch {\n --design-unit: 4;\n }\n ::part(switch) {\n border: 1px solid #616161;\n }\n .checked::part(switch) {\n border: 1px solid transparent;\n background: #0F6CBD;\n }\n ::part(checked-indicator) {\n --design-unit: 4;\n background: #616161;\n border: 1px solid transparent;\n top: 1.5px;\n left: 1px;\n }\n .checked::part(checked-indicator) {\n background: #FFFFFF;\n left: 16px;\n }\n .trackingToggleContainer {\n display: flex;\n align-items: center;\n }\n .trackedProductTextContainer {\n line-height: 20px;\n height: 20px;\n display: flex;\n }\n .trackedProductText {\n color: var(--accent-fill-rest);\n font-weight: 400;\n background: inherit;\n font-size: 12px;\n line-height: 16px;\n height: 16px;\n }\n .trackedProductText::part(control) {\n padding-left: 0;\n line-height: 20px;\n height: 20px;\n }\n .retailerContainer {\n position: relative;\n left: 4px;\n top: 2px;\n }\n .subtitleContainer {\n color: var(--neutral-foreground-hint);\n font-size: 12px;\n max-width: 160px;\n display: -webkit-box;\n -webkit-box-orient: vertical;\n -webkit-line-clamp: 2;\n overflow: hidden;\n text-align: left;\n }\n "}getNotificationStyles(){return"\n .productTrackingViewContainer {\n padding-bottom: 4px;\n }\n .subContainer {\n display: flex;\n align-items: center;\n padding-top: 12px;\n padding-bottom: 0px;\n }\n .iconContainer {\n position: static;\n display: flex;\n justify-content: center;\n align-items: center;\n width: 36px;\n height: 36px;\n border-radius: 50%;\n background: #F3F3F3;\n box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.08);\n }\n .trackedPriceNotifText {\n font-weight: 600;\n }\n "}getDarkModeStyles(){return"\n ::part(switch) {\n border: 1px solid #ADADAD;\n }\n .checked::part(switch) {\n background: #479EF5;\n }\n ::part(checked-indicator) {\n background: #ADADAD;\n }\n .checked::part(checked-indicator) {\n background: #3B3B3B;\n }\n hr {\n background: #555555;\n }\n .trackedProductText {\n color: #63ADE5;\n }\n "}}),(0,s.Z)(this,"isOutOfStock",void 0),(0,s.Z)(this,"isPriceTracked",void 0),(0,s.Z)(this,"priceTrackingSectionId","price-tracking-section"),(0,s.Z)(this,"productDetails",void 0)}static shouldRenderProductTrackingUtilities(e,t,i){try{const n=new URL(e).hostname;return this.isSupportedDomainForPrice(n,t,i)}catch(e){}return!1}async createTrackingToggleSection(n,o,a,s=!1){const{strings:l,common:c,dataStoreModule:d}=this.flyoutData;if(this.isOutOfStock=o,n&&n.ProductUrl&&n.title&&(n.price||o))try{const t=e.R.isExperimentActive(f.H.ptConciseUi),i=e.R.isExperimentActive(f.H.PCOutOfStock),u=e.R.isExperimentActive(f.H.ptNotifications)&&e.R.getServiceExperimentValue(f.H.ptNotifications)==Yu.cO.NewDesign,h=c.openedWith===r.Te.Auto;let p;if(this.productDetails=n,h||this.logContentViewed(o),this.abandonedCartNotificationTrackingEnabled){p=await this.isUserTrackingAbandonedCart(),d.ProductTrackingData||(d.ProductTrackingData=new ue.Z(void 0)),d.ProductTrackingData._abandonedCartNotificationToggle=!0;const e=d.ProductTrackingData.trackingPreferences?._abandonedCartTrackingUnset;p&&e&&this.SetAbandondedCartPreferences(!0)}else p=await this.isTrackedProduct(n?.ProductUrl);const g=(0,Y.Ux)("div",{className:"productTrackingViewContainer lateralMargin",id:this.priceTrackingSectionId}),m=u?(0,Y.Ux)("div",{className:"subContainer",style:"display: flex; align-items: center; justify-content: space-between; padding-bottom: 12px; padding-top: 6px;"}):(0,Y.Ux)("div",{className:"subContainer"}),v=u?(0,Y.Ux)("div",{className:"iconContainerV2",style:"display: flex; align-items: center;"}):(0,Y.Ux)("div",{className:"iconContainer"}),y=(0,Y.Ux)("img",{className:"trackedStateIcon"});let C="";C=u?p?c.resourcesEndpoint+"productTracking/trackProductActiveWhiteBlack.svg":c.resourcesEndpoint+"productTracking/trackProductInactiveWhiteBlack.svg":p?c.resourcesEndpoint+"productTracking/trackProductActiveBlack.svg":c.resourcesEndpoint+"productTracking/trackProductInactiveBlack.svg",t?y.height=17:u?(y.width=18,y.height=18):y.width=p?19:15,y.src=C,y.setAttribute("aria-hidden","true");const b=(0,Y.Ux)("div",{className:"textContainer"}),S=(0,Y.Ux)("div",{className:"trackedPriceNotifText"+(u?"":" txtMedium"),textContent:u?"Tracking product":o?l.productTrackingTitleAvailability:l.productTrackingTitlePrice,style:u?"font-size: 14px line-height: 20px; font-weight: 400;":""}),x=this.getSubtitleText(p,o,s),T=(0,Y.Ux)("span",{className:"subtitleContainer",title:x}),w=(0,Y.Ux)("span",{className:"subtitleTextContainer",textContent:x}),O=(0,Y.Ux)("div",{className:"trackingToggleContainer"}),P=(0,Y.Ux)("fluent-switch",{id:"ptvuTrackingToggle"});if(P.checked=p??!1,P.name="Tracking toggle",P.title="Tracking toggle",T.textContent&&P.setAttribute("aria-label",T.textContent),P.addEventListener("change",(e=>{this.isPriceTracked=e.target?.checked;const t=this.logButtonClickAndGetButtonName(this.isPriceTracked);this.recordTrackingToggleChange(t,n,this.isPriceTracked,this.isOutOfStock,a),this.sendTrackingData(this.productDetails,this.isPriceTracked,this.isOutOfStock),this.handlePriceTrackingChange(this.isPriceTracked,o,s),this.abandonedCartNotificationTrackingEnabled&&this.handleAbandonedCartToggleChange(this.isPriceTracked,a)})),!t&&!i){const e=(0,Y.Ux)("hr");g.appendChild(e)}if(T.appendChild(w),O.appendChild(P),v.appendChild(y),b.appendChild(S),u||b.appendChild(T),m.appendChild(v),m.appendChild(b),m.appendChild(O),g.appendChild(m),h||g.appendChild(this.createTrackedProductsText(a,t)),s&&h){const e=(0,Y.Ux)("span",{className:"retailerContainer"}),t=(0,Y.Ux)("IMG",{className:"retailerLogo"});this.utilities.addFavIconSrc(t,e,c.domain),T.appendChild(e)}return t?this.utilities.applyStyles(g,this.assets.getConciseStyles(),void 0,this.assets.getDarkModeStyles()):this.utilities.applyStyles(g,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),h&&this.utilities.applyStyles(g,this.assets.getNotificationStyles(),void 0),this.isTrackingToggleRendered()||h||this.updateTrackingToggleRenderedState(),g}catch(e){const r=new t.Z(i.xu.ProductTrackingDebug);r.Metadata=JSON.stringify({url:c.lastCommittedURL,product:n,isOutOfStock:o,err:e}),this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Product Tracking Toggle Rendering error: ${e}`,r)}}createTrackedProductsText(e,t){const{strings:n,common:o}=this.flyoutData,a=t?n.productTrackingViewTrackedTextConcise:n.productTrackingViewTrackedText,s=(0,Y.Ux)("fluent-anchor",{className:"trackedProductText txtSmall",href:"#",textContent:a});let l;if(s.appearance="stealth",s.addEventListener("click",(t=>{t.preventDefault();const n=new W.Z(i.$S.ProductTrackingViewAllProducts,this.telemetryUtilities.setContentViewed(e),o.domain,JSON.stringify(this.productDetails));this.logModule.LogInfoEvent(i.R.ButtonClick,a,n),this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKED_VIEW_TRACKED_PRODUCTS),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_TRACKED_VIEW_TRACKED_PRODUCTS,o.popupOrigination),this.utilities.switchShoppingTab(r.d$.Home);const s=new CustomEvent(Ku.e1.FocusProductCollections,{detail:{tabId:r._E.TrackedProducts}});this.stateManagement.dispatchEvent(s)})),t)l=(0,Y.Ux)("div",{className:"trackedProductTextContainer"}),l.appendChild(s),this.utilities.applyStyles(l,this.assets.getConciseStyles(),void 0,this.assets.getDarkModeStyles());else{const e=(0,Y.Ux)("hr");l=(0,Y.Ux)("div"),l.appendChild(e),l.appendChild(s),this.utilities.applyStyles(l,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles())}return o.openedWith===r.Te.Auto&&this.utilities.applyStyles(l,this.assets.getNotificationStyles(),void 0),l}switchToggleOff(){this.handlePriceTrackingChange(!1,this.isOutOfStock)}switchToggleOn(){this.handlePriceTrackingChange(!0,this.isOutOfStock)}async isUserTrackingAbandonedCart(){const e=await this.getProductTrackingData();return e.trackingPreferences??=new Wu.Z(void 0),e.trackingPreferences.abandonedCartTrackingEnabled??!0}async handleAbandonedCartToggleChange(e,t){const{domain:n,popupOrigination:o,openedWith:a}=this.flyoutData.common,s=a===r.Te.Auto,l=e?K.bS.PRODUCT_TRACKING_ABANDONED_CART_TRACK_CLICK:K.bS.PRODUCT_TRACKING_ABANDONED_CART_UNTRACK_CLICK;this.pageHandlerModule.RecordAsUserAction(l),e&&this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_TRACKING_ABANDONED_CART_TRACK_CLICK,o);const c=e?i.$S.ProductTrackingAbandonedCartTrack:i.$S.ProductTrackingAbandonedCartUntrack,d=new W.Z(c,this.telemetryUtilities.setContentViewed(t),n),u=`Abandoned Cart Tracking Toggle ${e?"On":"Off"}${s?" Notification":""}`;this.logModule.LogInfoEvent(i.R.ButtonClick,u,d),await this.SetAbandondedCartPreferences(e)}isTrackingToggleRendered(){return!0===this.stateManagement.getState(Ku.IY.isTrackingToggleRendered)}updateTrackingToggleRenderedState(){this.stateManagement.setState(Ku.IY.isTrackingToggleRendered,!0)}handlePriceTrackingChange(t,i,n=!1){const{common:o}=this.flyoutData,r=e.R.isExperimentActive(f.H.ptNotifications)&&e.R.getServiceExperimentValue(f.H.ptNotifications)==Yu.cO.NewDesign,a=document?.querySelector(".trackedPriceNotifText"),s=document?.querySelector(".trackedStateIcon"),l=document?.querySelector(".subtitleContainer"),c=document?.querySelector("#ptvuTrackingToggle, #trackingToggle");if(a&&r&&(a.textContent=t?"Tracking product":"Track product"),l){const e=this.getSubtitleText(t,i,n);l.title=e;const o=l.querySelector(".subtitleTextContainer");o&&(o.textContent=e)}s&&(s.src=r?t?o.resourcesEndpoint+"productTracking/trackProductActiveWhiteBlack.svg":o.resourcesEndpoint+"productTracking/trackProductInactiveWhiteBlack.svg":t?o.resourcesEndpoint+"productTracking/trackProductActiveBlack.svg":o.resourcesEndpoint+"productTracking/trackProductInactiveBlack.svg"),c&&(c.checked=t)}getSubtitleText(t,i,n){const o=e.R.isExperimentActive(f.H.ptConciseUi),{strings:r}=this.flyoutData;let a="";return this.abandonedCartNotificationTrackingEnabled?t?r.productTrackingAbandonedCartTrackedPriceDropText:r.productTrackingAbandonedCartPriceDropText:(a+=o?t&&i||t&&!i?r.productTrackingAlertsOnConcise:!t&&i?r.productTrackingAvailabilitySubtitleConcise:r.productTrackingOnRetailerPreTextConcise:t&&i?r.productTrackingBackInStockAlertsOn:t&&!i?r.productTrackingPriceDropAlertText:!t&&i?r.productTrackingDescription:r.productTrackingPriceDropText,n&&(a+=this.getRetailerText(t,i)),a)}getRetailerText(e,t){const{common:i,strings:n}=this.flyoutData,o=e&&!t?n.productTrackingForRetailerTextConcise:n.productTrackingOnRetailerText,r=qu.ZP.getDomainFromUrl(i.lastCommittedURL);return(0,T.fZ)("retailerName",o,r)}logContentViewed(e){const{PRODUCT_TRACKING_OUT_OF_STOCK:t,PRODUCT_TRACKING_PRICE_DROP:i}=r.ModuleNames,n=e?t:i;this.flyoutData.dataStoreModule.ProductTrackingData||(this.flyoutData.dataStoreModule.ProductTrackingData=new ue.Z(void 0)),this.productDetails&&(this.flyoutData.dataStoreModule.ProductTrackingData._currentProduct=this.productDetails),this.telemetryUtilities.recordContentViewed(n,Jl.g.EdgeImpressionId,!1,-1)}logButtonClickAndGetButtonName(e){return e?this.isOutOfStock?(this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKED_STOCK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_TRACKED_STOCK,this.flyoutData.common.popupOrigination),i.$S.ProductTrackingUtilitiesTrackStock):(this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKED_PRICE),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_TRACKED_PRICE,this.flyoutData.common.popupOrigination),i.$S.ProductTrackingUtilitiesTrackPrice):this.isOutOfStock?(this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKED_STOCK_UNTRACK),i.$S.ProductTrackingUtilitiesUntrackStock):(this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKED_PRICE_UNTRACK),i.$S.ProductTrackingUtilitiesUntrackPrice)}}var Ju=Xu,Qu=class{constructor(){(0,s.Z)(this,"assets",void 0)}PostProcessing(e,t,i){}CalculateRanking(){return r.zz.Unknown}ShowAlways(){return!1}GetAssets(){return this.assets}IsZerostate(){return!1}CreateModule(e,t,i,n,o){const r=new class{constructor(){(0,s.Z)(this,"element",void 0),(0,s.Z)(this,"priority",void 0),(0,s.Z)(this,"name",void 0),(0,s.Z)(this,"moduleInterface",void 0),(0,s.Z)(this,"paneTab",void 0),(0,s.Z)(this,"moduleLayout",void 0),(0,s.Z)(this,"isZerostateModule",void 0)}};return r.element=e,r.priority=t,r.name=i,r.moduleInterface=this,r.paneTab=n,r.moduleLayout=o,r.isZerostateModule=this.IsZerostate(),r}},eh=o(23582),th=o(605),ih=class extends Qu{constructor(e,t,i){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"querySuffix","rf=acm"),(0,s.Z)(this,"productTrackingUtilities",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),this.flyoutData=e,this.utilities=t.viewModulesUtilities,this.pageHandlerModule=t.pageHandlerModule,this.logModule=t.logModule,this.stateManagement=i,this.telemetryUtilities=t.telemetryHandler,this.storageHandler=t.storageHandler,this.assets=new class{getStyles(){return"\n #abandonedCartSectionWrapper {\n padding: 0 20px;\n display: flex;\n flex-direction: column;\n }\n #abandonedCartNotificationDiv {\n display: flex;\n flex-direction: column;\n row-gap: 12px;\n }\n #abandonedCartNotifHeader {\n font-style: normal;\n font-size: 20px;\n font-weight: 600;\n line-height: 26px;\n margin: 0px;\n }\n .abandonedCartIcon {\n height: 16px;\n }\n .abandonedCartText {\n font-weight: 600;\n font-size: 14px;\n line-height: 20px;\n margin: 0px;\n }\n .abandonedCartSpan {\n color: #008A21;\n }\n .noDeals::part(productList) {\n margin-top: 0px;\n }\n .divCommissionValue {\n display: inline-block;\n margin: 0px;\n vertical-align: text-bottom;\n }\n .spanCommissionValueSmall {\n display: flex;\n height: 20px;\n line-height: 20px;\n font-size: 14px;\n background: #0078D4;\n color: #fff;\n font-weight: 500;\n float: left;\n }\n .productImage {\n height: 100%;\n width: 100%;\n objectFit: contain;\n }\n .productImageWrapper {\n height: 48px;\n width: 48px;\n }\n .productNameDiv {\n font-size: 12px;\n line-height: 16px;\n color: #717171;\n display: -webkit-box;\n -webkit-box-orient: vertical;\n -webkit-line-clamp: 2; /* number of lines to show */\n overflow: hidden;\n height: 35px;\n align-self: center;\n }\n #trackingToggleSection {\n background: var(--fill-color);\n border-radius: 8px;\n border: none;\n margin: 0 20px 12px 20px;\n }\n #trackingToggleContainer {\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n align-items: center;\n box-sizing: border-box;\n height: 36px;\n padding: 8px 10px;\n }\n #leftContainer {\n display: flex;\n gap: 11px;\n }\n #trackingToggleIcon {\n display: flex;\n align-items: center;\n }\n #trackingToggleText {\n font-size: 14px;\n line-height: 20px;\n }\n .exclusiveCouponCodeTitle {\n margin-top: 6px;\n font-size: 12px;\n font-weight: 400;\n line-height: 16px;\n }\n .exclusiveCouponCodeSpan {\n color: var(--background-brand-1-rest, #2169EB);\n font-size: 12px;\n font-weight: 600;\n line-height: 16px;\n }\n "}getDarkModeStyles(){return"\n @media (prefers-color-scheme: dark) {\n .abandonedCartText {\n color: #FFFFFF;\n }\n .abandonedCartSpan {\n color: #56df77;\n }\n #trackingToggleSection {\n background: #414141;\n }\n .exclusiveCouponCodeSpan {\n color: var(--background-brand-1-rest, #A7C9FC);\n }\n };\n "}getAdSlugSvg(){return eh.Z.getTrustedHTML`
<svg width="22" height="16" viewBox="0 0 22 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M4.1665 12L7.10449 4.29785H8.14648L11.0898 12H10.0049L9.25293 9.98047H5.96582L5.25146 12H4.1665ZM6.27197 9.12109H8.94678L7.73828 5.80713C7.71322 5.74984 7.69173 5.67822 7.67383 5.59229C7.65592 5.50635 7.63623 5.4043 7.61475 5.28613H7.59326C7.57536 5.39355 7.55566 5.49023 7.53418 5.57617C7.51628 5.66211 7.49479 5.7373 7.46973 5.80176L6.27197 9.12109ZM16.0796 11.0547C15.8719 11.4128 15.6069 11.6831 15.2847 11.8657C14.966 12.0448 14.59 12.1343 14.1567 12.1343C13.4478 12.1343 12.8802 11.8818 12.4541 11.377C12.0316 10.8721 11.8203 10.1846 11.8203 9.31445C11.8203 8.37988 12.0549 7.6333 12.5239 7.07471C12.993 6.51253 13.6178 6.23145 14.3984 6.23145C14.7852 6.23145 15.1182 6.30664 15.3975 6.45703C15.6768 6.60742 15.9041 6.8348 16.0796 7.13916H16.1011V3.85742H17.0571V12H16.1011V11.0547H16.0796ZM12.7979 9.26611C12.7979 9.91064 12.9465 10.4173 13.2437 10.7861C13.5409 11.1549 13.9383 11.3394 14.436 11.3394C14.9373 11.3394 15.3402 11.1603 15.6445 10.8022C15.9489 10.4442 16.1011 9.99121 16.1011 9.44336V8.6377C16.1011 8.18652 15.9525 7.80518 15.6553 7.49365C15.3617 7.18213 14.9893 7.02637 14.5381 7.02637C13.9974 7.02637 13.5713 7.2251 13.2598 7.62256C12.9518 8.02002 12.7979 8.56787 12.7979 9.26611Z" fill="#242424"/>
<rect x="0.25" y="0.25" width="21.5" height="15.5" rx="3.75" stroke="#D1D1D1" stroke-width="0.5"/>
</svg>`}},this.productTrackingUtilities=new Ju(t,this.flyoutData,i)}GetModuleName(){return r.ModuleNames.ABANDONED_CART}ShouldRenderModule(){const e=this.flyoutData.dataStoreModule.AbandonedCartData,t=(e&&e.size>0&&this.flyoutData.common.isPane)??!1;return Promise.resolve(t)}populateMainHeader(){if(this.flyoutData.common.shoppingPersistent){const e=this.flyoutData.common.shoppingPersistent.querySelector("#abandonedCartDiv");if(e){e.style.marginTop="0px",e.slot="header-content";const t=e.querySelector("#abandonedCartSectionWrapper");t&&(t.style.margin="0px!important")}}}shouldRenderTrackingToggle(){const t=e.R.isExperimentActive(f.H.acTrackingToggle),i=this.flyoutData.common.domain,n=qu.ZP.isSupportedDomainForPrice(i,this.flyoutData?.dataStoreModule?.ProductTrackingData,this.flyoutData?.common?.market);return t&&n}renderTrackingToggle(){const e=(0,Y.Ux)("div",{id:"trackingToggleSection"}),t=(0,Y.Ux)("div",{id:"trackingToggleContainer"}),i=(0,Y.Ux)("div",{id:"leftContainer"}),n=this.utilities.commonAssets.getBlueBellIcon(),o=(0,Y.Ux)("div",{id:"trackingToggleIcon",innerHTML:n}),r=this.flyoutData.strings.abandonedCartTrackAll,a=(0,Y.Ux)("div",{id:"trackingToggleText",textContent:r}),s=(0,Y.Ux)("div"),l=(0,Y.Ux)("fluent-switch",{id:"toggle"});return s.appendChild(l),i.append(o,a),t.append(i,s),e.append(t),this.productTrackingUtilities.isUserTrackingAbandonedCart().then((e=>{l.checked=e})).finally((()=>{l.addEventListener("change",(async e=>{this.productTrackingUtilities.handleAbandonedCartToggleChange(l.checked,this.GetModuleName())}))})),e}renderModule(){this.utilities.applyStyles(this.flyoutData.common.shoppingPersistent,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());const e=(0,Y.Ux)("msft-edge-shopping-section");e.id="abandonedCartDiv";const t=this.flyoutData.dataStoreModule?.AbandonedCartData;if(t){if(this.shouldRenderTrackingToggle()){const o=this.renderTrackingToggle();e.prepend(o)}this.populateAbandonedCartList(e,!1,!1);const i=this.flyoutData;function n(e){let t=r.CS.ABANDONED_CART;const n=e?[...e.keys()]:null;return n&&i.common.bannerContext===r.De.VIEWALL&&(t=n.length),t}this.utilities.createCommonListStructure(e,this.flyoutData.strings.abandonedCartTitle,this.flyoutData.dataStoreModule?.AbandonedCartData,this.GetModuleName(),n,this.populateAbandonedCartList.bind(this),void 0,!0)}return Promise.resolve(this.CreateModule(e,r.H7.ABANDONED_CART,r.ModuleNames.ABANDONED_CART,r.$k.HOME,r.SV.LIST))}populateAbandonedCartList(e,t,i){const n=this.flyoutData.dataStoreModule.AbandonedCartData;if(n){let o=0;n.size>0&&(o=n.size);let a=0;t?a=r.CS.ABANDONED_CART:o>r.CS.ABANDONED_CART&&(o=r.CS.ABANDONED_CART);let s=null;t?s=e.querySelector("#abandonedCartSectionWrapper"):(s=(0,Y.Ux)("DIV"),s.id="abandonedCartSectionWrapper");const l=[...n.keys()];for(let c=a;c<o;c++){const o=l[c],d=n.get(o),u=this.createAbandonedCart(o,d);s?u&&(s.appendChild(u),c===a&&t&&i&&this.flyoutData.common.currentDevice===r.AS.Desktop&&u.focus(),t||e.appendChild(s)):u&&(e.appendChild(u),c===a&&t&&i&&this.flyoutData.common.currentDevice===r.AS.Desktop&&u.focus())}}}addClickHandler(e,n,o,a,l,c){const d=o?.RetailerCartPage?.startsWith("https")?o?.RetailerCartPage:o?.RetailerCartPage!==n?`https://www.${n}${o.RetailerCartPage}`:`https://www.${n}`;let u=a?i.$S.AbandonedCartNotificationButton:i.$S.AbandonedCartTile;l?u=i.$S.AbandonedCartPcbVisitProductNotification:c&&(u=i.$S.AbandonedCartExclusiveCouponsNotification);const h=new W.Z(u,this.telemetryUtilities.setContentViewed(this.GetModuleName()),n,JSON.stringify(o)),g=this.pageHandlerModule,f=this.flyoutData,m=this.logModule,v=this.querySuffix,y=this.storageHandler;async function C(){if(g.RecordAsUserAction(K.bS.GO_TO_ABANDONED_CART),g.RecordAsUserEngagement(q.FV.GO_TO_ABANDONED_CART,f.common.popupOrigination),m.LogInfoEvent(i.R.ButtonClick,`Clicked on abandoned cart for ${n} on ${f.common.domain}`,h),c)if("temu.com"!==n){const e=new class{constructor(){(0,s.Z)(this,"timeStamp",void 0),(0,s.Z)(this,"allowed",void 0),(0,s.Z)(this,"exclusiveCoupon",void 0)}},r=await y.getStorageString(Ce.Q.ExclusiveCouponConsent),a=(0,p.TF)(r)?{}:JSON.parse(r);e.timeStamp=(new Date).toUTCString(),e.allowed=!0,e.exclusiveCoupon=new th.Z,e.exclusiveCoupon.couponCode=o.ExclusiveCouponCode,a[n]=e;try{y.setStorageString(Ce.Q.ExclusiveCouponConsent,JSON.stringify(a))}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);n.Metadata=JSON.stringify({error:e}),this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,e,n)}await x.ZP.Sleep(150)}else g.CopyCoupon(o.ExclusiveCouponCode),e.textContent=f.strings.abandonedCartCopiedButtonForExclusiveCoupon;f.common.currentDevice!==r.AS.Mobile&&(l?g.NavigateToUrl(o.ProductUrl):"temu.com"!==n&&g.NavigateToRetailerSite((0,T.m2)(d,v),f.common.popupOrigination,ju.$.NEW_FOREGROUND_TAB))}e.addEventListener("click",(()=>{C()})),e.addEventListener("mousedown",(e=>{1===e.button&&C()}))}createAbandonedCart(e,t){if(!t)return null;t.Products=t.Products.filter((e=>!!e.ImageUrl)),0===t.Products.length&&t.Products.push({ImageUrl:`${this.flyoutData.common.resourcesEndpoint}defaultProductImage.png`});const i=!!t?.DiscountRate,n=!!t?.CashbackCommissionType&&!!t?.CashbackCommissionValue,o=(0,Y.Ux)("msft-shopping-cart");if(o.title=(0,p.TF)(t.RetailerName)?e:t.RetailerName,o.style.marginBottom="12px",o.iconSrc=this.utilities.getFavIconSrc(e),o.imageSrcs=JSON.stringify(t.Products),o.isClickable="true",i||n){const e=(0,Y.Ux)("div");e.className="abandonedCartText",e.slot="description";const r=[];if(i){const e=(0,Y.Ux)("span");e.textContent=t.DiscountRate+"%",e.className="abandonedCartSpan",r.push(e)}if(n){const e={commissionType:t.CashbackCommissionType,commissionValue:t.CashbackCommissionValue,adsCurrencySymbol:t.CurrencySymbol},i=this.utilities.retrieveCashBackAmount(e,!0),n=this.utilities.createCommissionArrow(i.cashBackAmount,!1,zu.h.Small);r.push(n)}const a=i&&n?this.flyoutData.strings.abandonedCartPrompt:i?this.flyoutData.strings.abandonedCartCouponPrompt:this.flyoutData.strings.abandonedCartCashbackPrompt;(0,T.B7)(e,a,...r),o.append(e),o.label=`${e.textContent}, ${this.flyoutData.strings.abandonedCartButton}`}else o.className+=" noDeals",o.label=`${this.flyoutData.strings.abandonedCartButton}`;return o.moreItemsLabel=this.flyoutData.strings.abandonedCartMoreItemsLabel,this.addClickHandler(o,e,t),o}createAbandonedCartNotification(e,t){if(!e)return null;e.Products=e.Products.filter((e=>!!e.ImageUrl)),0===e.Products.length&&e.Products.push({ImageUrl:`${this.flyoutData.common.resourcesEndpoint}defaultProductImage.png`});const i=(0,Y.Ux)("msft-shopping-cart");return i.imageSrcs=JSON.stringify(e.Products),i.isClickable="false",i.label=t,i.moreItemsLabel=this.flyoutData.strings.abandonedCartMoreItemsLabel,i}},nh=class extends ih{constructor(...e){super(...e),(0,s.Z)(this,"abandonedCart",void 0),(0,s.Z)(this,"abandonedCartDomain",void 0),(0,s.Z)(this,"isOutOfFlow",void 0),(0,s.Z)(this,"abandonedCartDataType",void 0),(0,s.Z)(this,"abandonedCartCategory",void 0)}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION]}PostProcessingNotification(e,t){e===r.sM.ABANDONED_CART&&(this.stateManagement.setState(Ku.IY.outOfFlow,u.W5.ABANDONED_CART_COUPONS),this.pageHandlerModule.OnOpenNotification(u.W5.ABANDONED_CART_COUPONS,"","")),this.utilities.logMuidNotificationShown(this.flyoutData.common.muid,this.abandonedCart.NotificationType)}RenderNotification(){this.flyoutData.common.shopping.classList.add("noSections");const n=(0,Y.Ux)("div");n.id="abandonedCartNotificationDiv",n.className="lateralMargin",this.utilities.applyStyles(n,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());const o=(0,Y.Ux)("h2");if(o.id="abandonedCartNotifHeader",o.slot="description",this.abandonedCartDataType===pt.CategoryDeals)return this.renderCategoryDealsNotification(n,o);if(this.abandonedCartDataType===pt.ExclusiveCoupons)return this.renderExclusiveCouponsNotification(n,o);const r=this.GetSavingsSpan(),a=this.GetOfferTypeSpan(),s=(0,Y.Ux)("img");s.className="abandonedCartIcon",s.src=this.utilities.getFavIconSrc(this.abandonedCartDomain),s.setAttribute("aria-hidden","true");const l=(0,Y.Ux)("div");l.style.minHeight="16px",l.style.minWidth="16px",l.style.display="inline-block",l.appendChild(s);const c=(0,Y.lw)(this.utilities);if(this.abandonedCartDataType!==pt.PersonalizedCashback){if(this.isOutOfFlow){const e=(0,Y.Ux)("span");e.textContent=this.abandonedCart.RetailerName,(0,T.B7)(o,this.flyoutData.strings.abandonedCartNotif,r,e,a,l)}else(0,T.B7)(o,this.flyoutData.strings.abandonedCartNotifOnDomain,r,a,l);c.textContent=this.flyoutData.strings.abandonedCartButton,this.addClickHandler(c,this.abandonedCartDomain,this.abandonedCart,!0);const e=this.createAbandonedCartNotification(this.abandonedCart,`${o.textContent??""}`);e&&(e.id="unselectable",e.append(o),n.append(e))}else{o.style.fontSize="18px";const e={commissionValue:this.abandonedCart.CashbackCommissionValue,commissionType:this.abandonedCart.CashbackCommissionType},r=this.utilities.retrieveCashBackAmount(e,!0),a=this.utilities.createCommissionArrow(r.cashBackAmount,!1,zu.h.Medium,void 0,void 0),s=(0,Y.Ux)("DIV");s.innerHTML=this.assets.getAdSlugSvg(),s.setAttribute("aria-label","Ad"),s.style.display="inline";const d=(0,Y.Ux)("span");d.textContent=this.utilities.getDomainNameAndCapitalize(this.abandonedCart.Domain),(0,T.B7)(o,this.flyoutData.strings.pcbAbandonedCart,a,d,l,s),c.textContent=this.flyoutData.strings.viewProductButton,this.addClickHandler(c,this.abandonedCartDomain,this.abandonedCart,!0,!0);const u=(0,Y.Ux)("div");u.style.display="flex",u.style.columnGap="16px";const h=(0,Y.Ux)("IMG");h.src=this.abandonedCart.ImageUrl??`${this.flyoutData.common.resourcesEndpoint}defaultProductImage.png`,h.setAttribute("aria-label",this.abandonedCart.Scope),h.classList.add("productImage");const p=(0,Y.Ux)("div");p.appendChild(this.utilities.createProductImage(48,48,h)),p.classList.add("productImageWrapper"),p.slot="image",u.append(p);const g=(0,Y.Ux)("div");g.textContent=this.abandonedCart.Scope,g.classList.add("productNameDiv"),u.append(g),n.append(o),n.append(u),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"User saw Cashback of "+r.currencySymbol+r.cashBackAmount,new t.Z(i.xu.AbandonedCartPersonalizedCashback)),this.logVisibilityFeedback(this.abandonedCart.VisibilityFeedbackUrl,this.abandonedCart.ImpressionToken)}if(n.append(c),e.R.isVariantActive(f.H.muidNotifications,Yu.K8.AutoDismiss)){const e=this.pageHandlerModule;setTimeout((()=>{e.DismissPopup()}),9e5)}const d=this.utilities.createNotificationModule(n,this.GetNotificationName(),this);return Promise.resolve(d)}ShouldRenderNotification(){const t=this.flyoutData.common.openedWith===r.Te.Auto,i=e.R.isExperimentActive(f.H.categoryDeals),n=this.GetDatastoreAbandonedCartData(),o=this.GetDatastoreCategoryDealsData(),a=n?.keys()?[...n.keys()]:[];let s=!1;if(t&&a.length>0&&n){const e=this.flyoutData.common.domain;this.isOutOfFlow=!a.includes(e);const[t]=n.values(),i=this.isOutOfFlow?t:n.get(e);if(i){s=!0,this.abandonedCart=i;const[t]=n.keys();this.abandonedCartDomain=this.isOutOfFlow?t:e,this.abandonedCart.ImageUrl&&this.abandonedCart.ProductUrl&&this.abandonedCart.CashbackCommissionValue?this.abandonedCartDataType=pt.PersonalizedCashback:this.abandonedCart.NotificationType===pt.ExclusiveCoupons&&(this.abandonedCartDataType=pt.ExclusiveCoupons)}}return!s&&i&&o?(this.abandonedCartDataType=pt.CategoryDeals,this.abandonedCartDomain=o.Domain,this.abandonedCartCategory=o.Category,Promise.resolve(t)):Promise.resolve(s)}GetNotificationName(){return r.sM.ABANDONED_CART}GetDatastoreAbandonedCartData(){const t=this.flyoutData.common.popupOrigination;if(this.pageHandlerModule.TriggerExperiment(f.H.muidNotifications),t===u.sR.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION&&e.R.isExperimentActive(f.H.muidNotifications))return this.flyoutData.dataStoreModule.AbandonedCartCouponsData}GetDatastoreCategoryDealsData(){const t=this.flyoutData.common.popupOrigination;if(this.pageHandlerModule.TriggerExperiment(f.H.muidNotifications),t===u.sR.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION&&e.R.isExperimentActive(f.H.muidNotifications))return this.flyoutData.dataStoreModule.CategoryDealsData}renderCategoryDealsNotification(e,t){const i=(0,Y.lw)(this.utilities),n=(0,Y.Ux)("span",{style:"color: #008A21;",textContent:this.abandonedCartCategory}),o=(0,Y.Ux)("span",{textContent:this.abandonedCartDomain});(0,T.B7)(t,this.flyoutData.strings.abandonedCartCategoryDealsText,n,o),i.textContent=(0,T.fZ)("prodHPriceDropViewAt",this.flyoutData.strings.prodHPriceDropViewAt,this.abandonedCartDomain),i.addEventListener("click",(()=>{this.flyoutData.common.currentDevice===r.AS.Desktop&&this.pageHandlerModule.NavigateToRetailerSite(this.abandonedCartDomain,this.flyoutData.common.popupOrigination,ju.$.NEW_FOREGROUND_TAB)})),e.append(t),e.append(i);const a=this.utilities.createNotificationModule(e,this.GetNotificationName(),this);return Promise.resolve(a)}GetOfferTypeSpan(){const e=(0,Y.Ux)("span");return e.textContent=this.abandonedCart.NotificationType===pt.Coupons?this.flyoutData.strings.rewardCoupons:this.flyoutData.strings.rewardCashback,e.textContent=e.textContent.toLocaleLowerCase(),e}GetSavingsSpan(){const e=(0,Y.Ux)("span");if(this.abandonedCart.NotificationType===pt.Coupons||this.abandonedCart.NotificationType===pt.ExclusiveCoupons)e.className="abandonedCartSpan",e.textContent=(0,T.fZ)("abandonedCartNotifSpan",this.flyoutData.strings.commonSave,`${this.abandonedCart.DiscountRate}%`);else if(this.abandonedCart.NotificationType===pt.Cashback){const t={commissionType:this.abandonedCart.CashbackCommissionType,commissionValue:this.abandonedCart.CashbackCommissionValue,adsCurrencySymbol:this.abandonedCart.CurrencySymbol},i=this.utilities.retrieveCashBackAmount(t,!0);(0,T.B7)(e,this.flyoutData.strings.commonSave,this.utilities.createCommissionArrow(i.cashBackAmount,!1,zu.h.Medium))}return e}renderExclusiveCouponsNotification(e,n){n.style.fontSize="16px",n.style.lineHeight="20px",e.style.rowGap="9px";const o=this.GetSavingsSpan(),r=(0,Y.Ux)("img");r.className="abandonedCartIcon",r.src=this.utilities.getFavIconSrc(this.abandonedCartDomain),r.setAttribute("aria-hidden","true");const a=(0,Y.Ux)("div");a.style.minHeight="16px",a.style.minWidth="16px",a.style.display="inline-block",a.style.position="relative",a.style.top="2px",a.appendChild(r);const s=(0,Y.Ux)("span",{textContent:this.abandonedCartDomain}),l=(0,Y.Ux)("div",{className:"exclusiveCouponCodeTitle"}),c=(0,Y.Ux)("span",{className:"exclusiveCouponCodeSpan",textContent:"MSFTXXXX"});(0,T.B7)(l,this.flyoutData.strings.abandonedCartOOFNotificationCouponCodeForExclusiveCoupon,c),(0,T.B7)(n,this.flyoutData.strings.abandonedCartOOFNotificationTitleForExclusiveCoupon,o,s,a,l);const d=(0,Y.Ux)("img");d.style.height="88px",d.style.width="88px",d.src=""!==this.abandonedCart.ImageUrl?this.abandonedCart.ImageUrl:`${this.flyoutData.common.resourcesEndpoint}defaultProductImage.png`;const u=(0,Y.lw)(this.utilities);u.textContent="temu.com"===this.abandonedCart.Domain?this.flyoutData.strings.abandonedCartCopyButtonForExclusiveCoupon:this.flyoutData.strings.abandonedCartButtonForExclusiveCoupon,this.addClickHandler(u,this.abandonedCartDomain,this.abandonedCart,!0,!1,!0);const h=(0,Y.Ux)("div",{className:"parentHeader",style:"display: flex;\n gap: 6px;"});h.append(n),h.append(d),e.append(h),e.append(u);const p=this.utilities.createNotificationModule(e,this.GetNotificationName(),this),g=new t.Z(i.xu.ExclusiveCouponsNotificationRendered);return g.Metadata=JSON.stringify(this.abandonedCart),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,`Exclusive coupons notification rendered for ${this.abandonedCart.Domain} on ${this.flyoutData.common.domain}`,g),Promise.resolve(p)}async logVisibilityFeedback(e,t){e&&fetch(t?`${e}&tids=${t}`:e)}},oh=o(71455),rh=class{getStyles(){return`\n ::part(header) {\n margin-bottom: 0px;\n }\n ::part(title) {\n margin: 10px 0px 6px;\n }\n .headerContentWrapper {\n align-self: flex-start;\n margin-left: 20px;\n }\n .headerTitle {\n font-weight: 600;\n font-size: 18px;\n line-height: 24px;\n margin: 12px 0;\n }\n .imageWrapper {\n min-width: 72px;\n width: 72px;\n height: 60px;\n overflow: hidden;\n margin-right: 12px;\n border-radius: 8px;\n position: relative;\n }\n .productImage {\n min-width: 100%;\n object-fit: cover;\n transition: min-width 0.5s;\n z-index: 10;\n }\n .productImage:hover {\n min-width: 125%;\n object-fit: cover;\n transition: min-width 0.5s;\n }\n .btnSeeMore {\n all: unset;\n cursor: pointer;\n font-size: 14px;\n font-weight: 600;\n color: rgba(0, 0, 0, 0.86);\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: center;\n margin-bottom: 16px;\n height: 22px;\n width: -webkit-fill-available;\n column-gap: 6px;\n }\n .listingsWrapper {\n margin: 0 20px 12px;\n border-radius: 8px;\n overflow: hidden;\n background: rgba(255, 255, 255, 0.50);\n box-shadow: 0px 0px 2px 0px rgba(0, 0, 0, 0.12), 0px 1px 2px 0px rgba(0, 0, 0, 0.14);\n display: flex;\n flex-direction: column;\n\n }\n .listingsWrapper > .autosMarketplaceListing:last-child {\n border-bottom: none;\n }\n .autosMarketplaceListing {\n display: flex;\n height: 60px;\n align-items: center;\n padding: 12px;\n border-bottom: 1px solid rgba(0, 0, 0, 0.06);\n position: relative;\n cursor: pointer;\n color: var(--text-normal);\n }\n .autosMarketplaceListing:focus-visible {\n box-shadow: 0 0 0 calc(var(--focus-stroke-width) * 1px) var(--focus-stroke-outer);\n outline: 1px solid var(--focus-stroke-outer);\n }\n .autosMarketplaceListing:hover {\n background: rgba(0,0,0,0.04);\n }\n .infoWrapper {\n font-size: 12px;\n line-height: 16px;\n margin-right: 12px;\n }\n .vehicleTitle {\n font-weight: 600;\n -webkit-line-clamp: 1;\n text-overflow: ellipsis;\n overflow: hidden;\n display: -webkit-box;\n -webkit-box-orient: vertical;\n margin-bottom: 4px;\n }\n .vehicleMileage {\n display: flex;\n margin-bottom: 4px;\n }\n .vehicleMileageText {\n -webkit-line-clamp: 1;\n text-overflow: ellipsis;\n overflow: hidden;\n display: -webkit-box;\n -webkit-box-orient: vertical;\n color: var(--text-neutral-foreground-hint);\n }\n .vehicleLocation {\n display: flex;\n column-gap: 4px;\n align-items: center;\n color: var(--text-neutral-foreground-hint);\n }\n .vehicleLocationText {\n -webkit-line-clamp: 1;\n text-overflow: ellipsis;\n overflow: hidden;\n display: -webkit-box;\n -webkit-box-orient: vertical;\n }\n .priceWrapper {\n display: flex;\n flex-direction: column;\n justify-content: center;\n height: 100%;\n flex: 1;\n align-items: flex-end;\n }\n .price {\n display: flex;\n font-weight: 600;\n }\n .vehiclePriceSign {\n font-size: 10px;\n line-height: 20px;\n }\n .vehiclePriceNumber {\n font-size: 16px;\n line-height: 22px;\n }\n .badgeRating {\n font-size: 12px;\n font-weight: 600;\n line-height: 16px;\n text-wrap: nowrap;\n color: rgba(0, 138, 33, 1);\n }\n @media (forced-colors: active) {\n .autosMarketplaceListing {\n color: ${Ns.LinkText} !important;\n }\n .vehicleLocation {\n color: ${Ns.LinkText} !important;\n }\n }\n `}getDarkModeStyles(){return`\n @media (prefers-color-scheme: dark) {\n .autosMarketplaceListing {\n border-bottom: 1px solid #555;\n color: #FFFFFF;\n }\n .autosMarketplaceListing:focus-visible {\n box-shadow: 0 0 0 calc(var(--focus-stroke-width) * 1px) ${Ns.ButtonText};\n outline: 1px solid ${Ns.ButtonText};\n }\n .btnSeeMore {\n color: #FFFFFF;\n }\n .listingsWrapper {\n background: #424242;\n }\n .btnSeeMore > svg > path {\n fill: white;\n }\n .vehicleLocation > svg > path {\n fill: #C2C2C2;\n }\n }\n `}getNotificationStyles(){return`\n @keyframes zoom {\n 0% { width: 100%; }\n 25% { width: 125%; }\n 75% { width: 125%; }\n 100% { width: 100%; }\n }\n .upperContent {\n display: flex;\n justify-content: space-between;\n text-align: start;\n cursor: pointer;\n color: var(--text-normal);\n }\n .upperContent:focus-visible {\n box-shadow: 0 0 0 calc(var(--focus-stroke-width) * 1px) var(--focus-stroke-outer);\n outline: 1px solid var(--focus-stroke-outer);\n }\n .titleV2 {\n font-size: 16px;\n font-weight: 600;\n line-height: 22px;\n }\n .vehiclePrice {\n display: flex;\n }\n .vehiclePriceIconV2 {\n font-size: 16px;\n font-weight: 600;\n line-height: 22px;\n color: #008A21;\n }\n .vehiclePriceNumberV2 {\n font-size: 28px;\n font-weight: 600;\n line-height: 32px;\n color: #008A21;\n }\n .imageWrapperV2 {\n display: flex;\n align-items: center;\n justify-content: center;\n width: 120px;\n height: 98px;\n overflow: hidden;\n border-radius: 8px;\n position: relative;\n }\n .notifProductImage {\n width: 100%;\n object-fit: cover;\n transition: width 0.5s;\n animation-name: zoom;\n animation-duration: 3s;\n animation-delay: 0.5s;\n z-index: 1;\n }\n .notifProductImageBg {\n min-width: 100%;\n min-height: 100%;\n object-fit: cover;\n position: absolute;\n filter: blur(10px);\n }\n .notifProductImage:hover {\n width: 125%;\n object-fit: cover;\n transition: width 0.5s;\n }\n .btnActions {\n width: calc(100% - 32px);\n margin-top: 12px;\n justify-content: center;\n }\n .accidentsIcon {\n display: flex;\n }\n .accidentsContainer {\n display: flex; \n align-items: center; \n margin-top: 2px;\n }\n @media (forced-colors: active) {\n .upperContent {\n color: ${Ns.LinkText};\n }\n .upperContent:focus-visible {\n box-shadow: 0 0 0 calc(var(--focus-stroke-width) * 1px) ${Ns.ButtonText};\n outline: 1px solid ${Ns.ButtonText};\n }\n }\n `}getNotificationDarkModeStyles(){return"\n @media (prefers-color-scheme: dark) {\n .accidentsIcon > svg > path {\n fill: #FFFFFF;\n }\n }\n "}},ah=class extends Qu{constructor(e,t){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"scenario",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"competingOffers",[]),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"sectionId","autosMarketplaceSection"),(0,s.Z)(this,"parent",void 0),(0,s.Z)(this,"searchQuery",void 0),this.logModule=t.logModule,this.pageHandlerModule=t.pageHandlerModule,this.flyoutData=e,this.utilities=t.viewModulesUtilities,this.telemetryUtilities=t.telemetryHandler,this.assets=new rh,this.storageHandler=t.storageHandler,this.flyoutData.common.isPane?this.parent=this.flyoutData.common.shoppingPersistent:this.parent=this.flyoutData.common.shopping}GetModuleName(){return r.ModuleNames.AUTOSMARKETPLACE}async ShouldRenderModule(){if(void 0===this.flyoutData.dataStoreModule.AutosData)return Promise.resolve(!1);const e=this.flyoutData.common?.lastCommittedURL?.toLowerCase(),t=this.flyoutData.dataStoreModule.PriceComparisonData,i=t?.segment?.toLowerCase()===r.VG.AUTOS;if(t&&t.CompetingPrices&&t.CompetingPrices.length>0&&this.hasValidOffer(t.CompetingPrices)&&i&&(this.scenario=r.tl.PDP,this.competingOffers=t?.CompetingPrices||[],this.competingOffers&&this.competingOffers.length>0))return Promise.resolve(!0);if(this.flyoutData.dataStoreModule.AutosData.isAutosSupportedDomain){const t=await this.storageHandler.getStorageString(Ce.Q.AutosMarketplace);if(t&&oh.Z.isSERPPage(t,e)&&(this.scenario=r.tl.SERP,this.competingOffers=oh.Z.getSERPComparableOffersData(t),this.competingOffers&&this.competingOffers.length>0))return Promise.resolve(!0)}return Promise.resolve(!1)}renderModule(){if(this.competingOffers&&this.competingOffers?.length>0){const e=document.createElement("msft-edge-shopping-section");e.id=this.sectionId,e.accordion=!0,e.expanded=!0,e.titleText=this.flyoutData.strings.autosMarketplaceSectionTitle;const n=this.flyoutData.common.isDomainEligible,o=(0,Y.Ux)("DIV",{className:"listingsWrapper"});e.appendChild(o),this.populateListings(o),n?this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()):this.utilities.applyStyles(this.parent,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),this.renderSeeMoreButton(e,this.competingOffers[0].marketHint);const a=this.CreateModule(e,r.H7.AUTOSMARKETPLACE,r.ModuleNames.AUTOSMARKETPLACE,r.$k.CONTEXTUAL,r.SV.LIST),s=new t.Z(i.xu.AutosMarketplaceRenderViewModule,void 0,void 0,void 0,this.constructTelemetryMetaData());return this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Autos Marketplace Module",s),Promise.resolve(a)}return Promise.resolve(null)}populateMainHeader(){const e=this.flyoutData.common.shopping,t=(0,Y.Ux)("DIV",{className:"headerContentWrapper"});t.slot="header-content";const i=(0,Y.Ux)("H2",{className:"headerTitle"});i.textContent=this.flyoutData.strings.autosMarketplaceSectionTitle,t.appendChild(i),e.appendChild(t)}setSearchQuery(e){let t="";void 0!==e.vehicleDetails?.year&&(t+=e.vehicleDetails?.year),void 0!==e.vehicleDetails?.make&&(t+=" "+e.vehicleDetails?.make),void 0!==e.vehicleDetails?.model&&(t+=" "+e.vehicleDetails?.model),this.searchQuery=t}sendAutosMarketplaceDwellTimeTelemery(e,n,o){const r=Date.now()-e,a=new t.Z(n,void 0,void 0,void 0,this.constructTelemetryMetaData());this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,`${o} - ${r} ms`,a),r>=1e3&&K.bS&&this.pageHandlerModule.RecordAsUserAction(K.bS.AUTOS_MARKETPLACE_LISTING_HOVER)}constructTelemetryMetaData(){try{return JSON.stringify({pageType:this.scenario})}catch(e){return""}}constructImageUrl(e,t,i){let n=-1!==e.indexOf("?")?e+`&w=${t}`:e+`?w=${t}`;return i&&(n+=`&h=${i}`),n}async getPageInfo(e,t){const i=`https://www.bingapis.com/api/autosmarketplace/v1/pageinfo?scenario=edgeflyoutv3&url=${e}&title=${t}`;try{const e=await fetch(i,{method:"GET"});if(e.ok){const t=await e.json();return Promise.resolve(t)}return Promise.resolve(null)}catch(e){return Promise.resolve(null)}}navigateToRetailer(e,t,n){const o=new W.Z(i.$S.NavigatedToAutosMarketplaceRecommendation,this.telemetryUtilities.setContentViewed(this.GetModuleName()),void 0,this.constructTelemetryMetaData());this.pageHandlerModule.RecordAsUserAction(K.bS.AUTOS_MARKETPLACE_RECOMMENDATION_CLICK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.AUTOS_MARKETPLACE_RECOMMENDATION_CLICK,this.flyoutData.common.popupOrigination);const a=t?"Navigate to Autos Marketplace from Autoshow - [AutosMarketplaceModuleNotification] - click on recommended":"Navigate to Autos Marketplace - [AutosMarketplaceModule] - click on recommended car";if(this.logModule.LogInfoEvent(i.R.ButtonClick,a,o),this.flyoutData.dataLoader.IsServerData()||this.flyoutData.common.currentDevice===r.AS.Mobile)this.pageHandlerModule.NavigateToRetailerSite(e.Url,this.flyoutData.common.popupOrigination);else{const t=""!==e.PriceId?e.PriceId:e.ImpressionToken;this.pageHandlerModule.NavigateToRetailerSite(t,this.flyoutData.common.popupOrigination,n)}}populateListings(e){let t;const i=this.competingOffers;if(i){i.length>0&&(t=i.length),t>r.CS.AUTOSMARKETPLACE&&this.scenario!==r.tl.FEED&&this.scenario!==r.tl.FAllBACK&&(t=r.CS.AUTOSMARKETPLACE);for(let n=0;n<t;n++)i[n].validAutosOffer&&this.createNewTile(e,i[n])}}constructSearchQuery(){if(this.flyoutData.dataStoreModule.PriceComparisonData?.entityName)return this.flyoutData.dataStoreModule.PriceComparisonData?.entityName;if(this.competingOffers&&this.competingOffers?.length>0)try{const e=new URL(this.competingOffers[0].Url).searchParams.get("q");if(e)return e}catch{return"SUV"}return"SUV"}manageLinkEvents(e,n){let o=0,r=0,a=!0;e.addEventListener("mouseenter",(()=>{l()})),e.addEventListener("mouseleave",(()=>{c()})),e.addEventListener("focus",(()=>{l()})),e.addEventListener("blur",(()=>{c()}));const s=this.logModule,l=()=>{if(!(Date.now()-r>200))return;a=!0,o=Date.now();const e=new t.Z(i.xu.AutosMarketplaceListingHovered,void 0,void 0,void 0,this.constructTelemetryMetaData());s.LogInfoEvent(i.R.EdgeFlyoutStatus,"Autos Marketplace Module - listing hovered",e)},c=()=>{r=Date.now(),setTimeout((()=>{if(a){a=!1,this.sendAutosMarketplaceDwellTimeTelemery(o,i.xu.AutosMarketDwellTimeHover,"Autos Marketplace - hover time over listing");const e=new t.Z(i.xu.AutosMarketDwellTimeHover,void 0,void 0,void 0,this.constructTelemetryMetaData());s.LogInfoEvent(i.R.EdgeFlyoutStatus,"Autos Marketplace Module - listing exited hover",e)}}),200)};e.addEventListener("click",(()=>{this.navigateToRetailer(n,!1)})),e.addEventListener("mousedown",(e=>{1===e.button&&this.navigateToRetailer(n,!1)})),e.addEventListener("keydown",(e=>{e&&"Enter"===e.key&&this.navigateToRetailer(n,!1)}))}createNewTile(e,t){if(!t)return;const i=t.ProductImageOriginalUrl.replace("edge://image?",""),n=(0,Y.Ux)("A");n.className="autosMarketplaceListing";const o=(0,Y.Ux)("DIV",{className:"imageWrapper"}),a=(0,Y.Ux)("IMG",{className:"productImage"});a.src=this.constructImageUrl(i,150),a.onerror=()=>{a.onerror=null,a.src="https://marketplaceassets.azureedge.net/publicassets/misc/imageplaceholderlight.webp"},a.setAttribute("aria-hidden","true");const s=a.cloneNode(!0);s.style.filter="blur(30px)",s.style.position="absolute",s.style.zIndex="0",s.style.minHeight="100%",o.appendChild(a),o.appendChild(s);const l=(0,Y.Ux)("DIV",{className:"infoWrapper"}),c=(0,Y.Ux)("DIV",{className:"vehicleTitle"});c.textContent=t.Description;const d=(0,Y.Ux)("DIV",{className:"vehicleMileage"}),u=(0,Y.Ux)("DIV",{className:"vehicleMileageText"});u.textContent=this.utilities.formatPrice(t.mileageValue)+" "+t.mileageUnit,d.appendChild(u),d.setAttribute("aria-label","Mileage: "+u.textContent);const h=(0,Y.Ux)("DIV",{className:"vehicleLocation"}),p=(0,Y.Ux)("DIV",{className:"vehicleLocationText"});h.innerHTML=eh.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="12" height="12" viewBox="0 0 12 12" fill="none">
<path d="M6 0.5C8.48528 0.5 10.5 2.51472 10.5 5C10.5 6.86262 9.0802 8.81485 6.3 10.9C6.12222 11.0333 5.87778 11.0333 5.7 10.9C2.9198 8.81485 1.5 6.86262 1.5 5C1.5 2.51472 3.51472 0.5 6 0.5ZM6 1.5C4.067 1.5 2.5 3.067 2.5 5C2.5 6.35543 3.55905 7.91787 5.72366 9.65342L6 9.87127L6.27634 9.65342C8.44095 7.91787 9.5 6.35543 9.5 5C9.5 3.067 7.933 1.5 6 1.5ZM6 4C6.55228 4 7 4.44772 7 5C7 5.55228 6.55228 6 6 6C5.44772 6 5 5.55228 5 5C5 4.44772 5.44772 4 6 4Z" fill="rgba(0,0,0,0.56)" />
</svg>`,t.listingTypes?.includes(r.$U.ONLINEONLY)?p.textContent=this.flyoutData.strings.autosMarketplaceOnlineDealer:(p.textContent=t.SellerName+` · ${t.geoDistance} ${t.mileageUnit}`,h.setAttribute("aria-label",p.textContent+" from your location")),h.appendChild(p),l.appendChild(c),l.appendChild(d),l.appendChild(h);const g=(0,Y.Ux)("DIV",{className:"priceWrapper"}),f=(0,Y.Ux)("DIV",{className:"badgeRating"});"GreatDeal"===t.dealRating&&(f.textContent=this.flyoutData.strings.autosMarketplaceGreatDeal);const m=(0,Y.Ux)("DIV",{className:"price"}),v=(0,Y.Ux)("DIV",{className:"vehiclePriceSign"}),y=(0,Y.Ux)("DIV",{className:"vehiclePriceNumber"});v.textContent=t.CurrencySymbol,y.textContent=this.utilities.formatPrice(t.IntendedPrice||t.Price),m.appendChild(v),m.appendChild(y),this.utilities.isDarkMode()&&(c.style.color="#FFFFFF",d.style.color="#C2C2C2",h.style.color="#C2C2C2",f.style.color="#44D498",m.style.color="#FFFFFF"),g.appendChild(f),g.appendChild(m),n.appendChild(o),n.appendChild(l),n.appendChild(g),n.tabIndex=0,this.manageLinkEvents(n,t),e.appendChild(n)}renderSeeMoreButton(e,t="en-us"){const n=(0,Y.Ux)("button",{className:"btnSeeMore"}),o=this.flyoutData.common.currentDevice;n.addEventListener("click",(()=>{this.pageHandlerModule.RecordAsUserAction(K.bS.AUTOS_MARKETPLACE_SEE_MORE_CLICK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.AUTOS_MARKETPLACE_SEE_MORE_CLICK,this.flyoutData.common.popupOrigination);const e=new W.Z(i.$S.NavigatedToAutosMarketplace,this.telemetryUtilities.setContentViewed(this.GetModuleName()),void 0,this.constructTelemetryMetaData());this.logModule.LogInfoEvent(i.R.ButtonClick,"Navigate to Autos Marketplace from listing module",e);const n=this.searchQuery??this.constructSearchQuery(),a=this.scenario===r.tl.FEED?`https://www.msn.com/${t}/autos/marketplace/search?form=MARFL2&personalization=edge`:`https://www.msn.com/${t}/autos/marketplace/search?q=${n}&form=MARFL2`;o===r.AS.Desktop&&this.pageHandlerModule.NavigateToOtherSellerWithDisposition(a,ju.$.NEW_FOREGROUND_TAB)}));const a=(0,Y.Ux)("div");a.textContent=this.flyoutData.strings.autosMarketplaceSeeMoreButton,n.innerHTML=eh.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none">
<path d="M5.14645 7.64645C5.34171 7.45118 5.65829 7.45118 5.85355 7.64645L10 11.7929L14.1464 7.64645C14.3417 7.45118 14.6583 7.45118 14.8536 7.64645C15.0488 7.84171 15.0488 8.15829 14.8536 8.35355L10.3536 12.8536C10.1583 13.0488 9.84171 13.0488 9.64645 12.8536L5.14645 8.35355C4.95118 8.15829 4.95118 7.84171 5.14645 7.64645Z" fill="black"/>
</svg>`,n.appendChild(a),e.appendChild(n)}hasValidOffer(e){let t=!1;return e.forEach((e=>{e.validAutosOffer&&(t=!0)})),t}},sh=o(88524),lh=o(51329),ch=o(8559),dh=o.t(ch,2);const uh=(0,ch.lazy)((()=>Promise.resolve().then(o.bind(o,44077)).then((e=>({default:e.Stack}))))),hh=(0,ch.lazy)((()=>Promise.resolve().then(o.bind(o,44077)).then((e=>({default:e.Box}))))),ph=async()=>await Promise.resolve().then(o.bind(o,44323)).then((e=>e.shoppingTheme)),gh=(0,ch.lazy)((()=>Promise.resolve().then(o.bind(o,37116)).then((e=>({default:e.PriceActivity}))))),fh=(0,ch.lazy)((()=>Promise.resolve().then(o.bind(o,66202)).then((e=>({default:e.PriceHistory})))));var mh=o(12211),vh=o(85440),yh=o(3421);const Ch=ch.createContext(void 0),bh={},Sh=Ch.Provider;var xh=o(10910),Th=o(61068);var wh=o(11122),Oh=o(58092),Ph=o(29924),Ah=o(32535),Eh=o(38283),kh=o(70617),Ih=o(48628),Dh=o(82142),_h=o(32384),Nh=o(34325);const Rh=e=>{var t,i,n,o;const r=null!==(a=ch.useContext(Ch))&&void 0!==a?a:bh;var a;const s=(0,Th.Av)(),{targetDocument:l}=(0,xh.O)(),[c,d]=function(e,t){const i=ch.useRef(void 0),n=ch.useCallback(((n,o)=>(void 0!==i.current&&t(i.current),i.current=e(n,o),i.current)),[t,e]),o=ch.useCallback((()=>{void 0!==i.current&&(t(i.current),i.current=void 0)}),[t]);return ch.useEffect((()=>o),[o]),[n,o]}(setTimeout,clearTimeout),{appearance:u="normal",children:h,content:p,withArrow:g=!1,positioning:f="above",onVisibleChange:m,relationship:v,showDelay:y=250,hideDelay:C=250,mountNode:b}=e,[S,x]=(0,wh.T)({state:e.visible,initialState:!1}),T=ch.useCallback(((e,t)=>{d(),x((i=>(t.visible!==i&&(null==m||m(e,t)),t.visible)))}),[d,x,m]),w={withArrow:g,positioning:f,showDelay:y,hideDelay:C,relationship:v,visible:S,shouldRenderTooltip:S,appearance:u,mountNode:b,components:{content:"div"},content:Oh.Bx(p,{defaultProps:{role:"tooltip"},elementType:"div"})};w.content.id=(0,Ph.Me)("tooltip-",w.content.id);const O={enabled:w.visible,arrowPadding:8,position:"above",align:"center",offset:4,...(0,mh.j)(w.positioning)};w.withArrow&&(O.offset=(0,vh.w)(O.offset,6));const{targetRef:P,containerRef:A,arrowRef:E}=(0,yh.m)(O);w.content.ref=(0,Ah.r)(w.content.ref,A),w.arrowRef=E,(0,Eh.L)((()=>{if(S){var e;const t={hide:e=>T(void 0,{visible:!1,documentKeyboardEvent:e})};null===(e=r.visibleTooltip)||void 0===e||e.hide(),r.visibleTooltip=t;const i=e=>{e.key!==Nh.L1R||e.defaultPrevented||(t.hide(e),e.preventDefault())};return null==l||l.addEventListener("keydown",i,{capture:!0}),()=>{r.visibleTooltip===t&&(r.visibleTooltip=void 0),null==l||l.removeEventListener("keydown",i,{capture:!0})}}}),[r,l,S,T]);const k=ch.useRef(!1),I=ch.useCallback((e=>{if("focus"===e.type&&k.current)return void(k.current=!1);const t=r.visibleTooltip?0:w.showDelay;c((()=>{T(e,{visible:!0})}),t),e.persist()}),[c,T,w.showDelay,r]),D=ch.useCallback((e=>{let t=w.hideDelay;"blur"===e.type&&(t=0,k.current=(null==l?void 0:l.activeElement)===e.target),c((()=>{T(e,{visible:!1})}),t),e.persist()}),[c,T,w.hideDelay,l]);w.content.onPointerEnter=(0,kh.E)(w.content.onPointerEnter,d),w.content.onPointerLeave=(0,kh.E)(w.content.onPointerLeave,D),w.content.onFocus=(0,kh.E)(w.content.onFocus,d),w.content.onBlur=(0,kh.E)(w.content.onBlur,D);const _=(0,Ih.W)(h),N={};"label"===v?"string"==typeof w.content.children?N["aria-label"]=w.content.children:(N["aria-labelledby"]=w.content.id,w.shouldRenderTooltip=!0):"description"===v&&(N["aria-describedby"]=w.content.id,w.shouldRenderTooltip=!0),s&&(w.shouldRenderTooltip=!1);const R=(0,Ah.r)(null==_?void 0:_.ref,P);return w.children=(0,Dh.a)(h,{...N,...null==_?void 0:_.props,ref:void 0===O.target?R:null==_?void 0:_.ref,onPointerEnter:(0,_h.$)((0,kh.E)(null==_||null===(t=_.props)||void 0===t?void 0:t.onPointerEnter,I)),onPointerLeave:(0,_h.$)((0,kh.E)(null==_||null===(i=_.props)||void 0===i?void 0:i.onPointerLeave,D)),onFocus:(0,_h.$)((0,kh.E)(null==_||null===(n=_.props)||void 0===n?void 0:n.onFocus,I)),onBlur:(0,_h.$)((0,kh.E)(null==_||null===(o=_.props)||void 0===o?void 0:o.onBlur,D))}),w};var Mh=o(64821),Lh=o(77688),Bh=o(94270),Fh=o(44906),Uh=o(94183),Hh=o(74551);const $h=(0,Uh.s)({root:{mc9l5x:"fjseox",B7ck84d:"f1ewtqcl",B2u0y6b:"f132xexn",Bceei9c:"f158kwzp",Bahqtrf:"fk6fouc",Be2twd7:"fy9rknc",Bg96gwp:"fwrc4pm",Btd35i7:"fokg9q4",Bbmb7ep:["f1aa9q02","f16jpd5f"],Beyfa6y:["f16jpd5f","f1aa9q02"],B7oj6ja:["f1jar5jt","fyu767a"],Btl43ni:["fyu767a","f1jar5jt"],B4j52fo:"f5ogflp",Bekrc4i:["f1hqa2wf","finvdd3"],Bn0qgzm:"f1f09k3d",ibv6hh:["finvdd3","f1hqa2wf"],icvyot:"fzkkow9",vrafjx:["fcdblym","fjik90z"],oivjwe:"fg706s2",wvpqe5:["fjik90z","fcdblym"],g2u3we:"fghlq4f",h3c5rm:["f1gn591s","fjscplz"],B9xav0g:"fb073pr",zhjwy3:["fjscplz","f1gn591s"],z8tnut:"f10ra9hq",z189sj:["fd9xhir","f1jlaasf"],Byoj8tv:"f1d7kygh",uwmqm3:["f1jlaasf","fd9xhir"],De3pzq:"fxugw4r",sj55zd:"f19n0e5",Bhu2qc9:"fxeb0a7"},visible:{mc9l5x:"ftgm304"},inverted:{De3pzq:"fg3r6xk",sj55zd:"fonrgv7"},arrow:{qhf8xq:"f1euv43f",De3pzq:"f1u2r49w",Bcdw1i0:"fd7fpy0",Bj3rh1h:"f1bsuimh",a9b677:"f1ekdpwm",Bqenvij:"f83vc9z",Ftih45:"f1wl9k8s",B1puzpu:"f1wkw4r9",Brfgrao:"f1j7ml58",Bcvre1j:"fyl8oag",Ccq8qp:"frdoeuz",Baz25je:"fb81m9q",cmx5o7:"f1ljr5q2",B4f6apu:"fyfemzf",m598lv:"focyt6c",Bk5zm6e:"fnhxbxj",y0oebl:"fdw6hkg",qa3bma:"f11yjt3y",Bqjgrrk:"f1172wan",Budzafs:["f9e5op9","f112wvtl"],Hv9wc6:["ftj5xct","fyavhwi"],hl6cv3:"f1773hnp",Bh2vraf:"f1n8855c",yayu3t:"f1v7783n",wedwtw:"fsw6im5",rhl9o9:"fh2hsk5",Bu8t5uz:"f159pzir",B6q6orb:"f11yvu4",Bwwlvwl:"fm1ycve"}},{d:[".fjseox{display:none;}",".f1ewtqcl{box-sizing:border-box;}",".f132xexn{max-width:240px;}",".f158kwzp{cursor:default;}",".fk6fouc{font-family:var(--fontFamilyBase);}",".fy9rknc{font-size:var(--fontSizeBase200);}",".fwrc4pm{line-height:var(--lineHeightBase200);}",".fokg9q4{overflow-wrap:break-word;}",".f1aa9q02{border-bottom-right-radius:var(--borderRadiusMedium);}",".f16jpd5f{border-bottom-left-radius:var(--borderRadiusMedium);}",".f1jar5jt{border-top-right-radius:var(--borderRadiusMedium);}",".fyu767a{border-top-left-radius:var(--borderRadiusMedium);}",".f5ogflp{border-top-width:1px;}",".f1hqa2wf{border-right-width:1px;}",".finvdd3{border-left-width:1px;}",".f1f09k3d{border-bottom-width:1px;}",".fzkkow9{border-top-style:solid;}",".fcdblym{border-right-style:solid;}",".fjik90z{border-left-style:solid;}",".fg706s2{border-bottom-style:solid;}",".fghlq4f{border-top-color:var(--colorTransparentStroke);}",".f1gn591s{border-right-color:var(--colorTransparentStroke);}",".fjscplz{border-left-color:var(--colorTransparentStroke);}",".fb073pr{border-bottom-color:var(--colorTransparentStroke);}",".f10ra9hq{padding-top:4px;}",".fd9xhir{padding-right:11px;}",".f1jlaasf{padding-left:11px;}",".f1d7kygh{padding-bottom:6px;}",".fxugw4r{background-color:var(--colorNeutralBackground1);}",".f19n0e5{color:var(--colorNeutralForeground1);}",".fxeb0a7{filter:drop-shadow(0 0 2px var(--colorNeutralShadowAmbient)) drop-shadow(0 4px 8px var(--colorNeutralShadowKey));}",".ftgm304{display:block;}",".fg3r6xk{background-color:var(--colorNeutralBackgroundStatic);}",".fonrgv7{color:var(--colorNeutralForegroundStaticInverted);}",".f1euv43f{position:absolute;}",".f1u2r49w{background-color:inherit;}",".fd7fpy0{visibility:hidden;}",".f1bsuimh{z-index:-1;}",".f1ekdpwm{width:8.484px;}",".f83vc9z{height:8.484px;}",'.f1wl9k8s::before{content:"";}',".f1wkw4r9::before{visibility:visible;}",".f1j7ml58::before{position:absolute;}",".fyl8oag::before{box-sizing:border-box;}",".frdoeuz::before{width:inherit;}",".fb81m9q::before{height:inherit;}",".f1ljr5q2::before{background-color:inherit;}",".fyfemzf::before{border-right-width:1px;}",".focyt6c::before{border-right-style:solid;}",".fnhxbxj::before{border-right-color:var(--colorTransparentStroke);}",".fdw6hkg::before{border-bottom-width:1px;}",".f11yjt3y::before{border-bottom-style:solid;}",".f1172wan::before{border-bottom-color:var(--colorTransparentStroke);}",".f9e5op9::before{border-bottom-right-radius:var(--borderRadiusSmall);}",".f112wvtl::before{border-bottom-left-radius:var(--borderRadiusSmall);}",".ftj5xct::before{transform:rotate(var(--angle)) translate(0, 50%) rotate(45deg);}",".fyavhwi::before{transform:rotate(var(--angle)) translate(0, 50%) rotate(-45deg);}",'[data-popper-placement^="top"] .f1773hnp{bottom:-1px;}','[data-popper-placement^="top"] .f1n8855c{--angle:0;}','[data-popper-placement^="right"] .f1v7783n{left:-1px;}','[data-popper-placement^="right"] .fsw6im5{--angle:90deg;}','[data-popper-placement^="bottom"] .fh2hsk5{top:-1px;}','[data-popper-placement^="bottom"] .f159pzir{--angle:180deg;}','[data-popper-placement^="left"] .f11yvu4{right:-1px;}','[data-popper-placement^="left"] .fm1ycve{--angle:270deg;}']}),Zh=e=>{const t=Rh(e);return(e=>{const t=$h();e.content.className=(0,Hh.z)("fui-Tooltip__content",t.root,"inverted"===e.appearance&&t.inverted,e.visible&&t.visible,e.content.className),e.arrowClassName=t.arrow})(t),(0,Fh.oj)("useTooltipStyles_unstable")(t),(e=>((0,Bh.a)(e),(0,Mh.BX)(ch.Fragment,{children:[e.children,e.shouldRenderTooltip&&(0,Mh.tZ)(Lh.h,{mountNode:e.mountNode,children:(0,Mh.BX)(e.content,{children:[e.withArrow&&(0,Mh.tZ)("div",{ref:e.arrowRef,className:e.arrowClassName}),e.content.children]})})]})))(t)};Zh.displayName="Tooltip",Zh.isFluentTriggerComponent=!0;var Vh=o(90100),Gh=o(16503);const jh=ch.createContext(void 0),zh=jh.Provider;var Wh=o(64143);const Kh=ch.createContext(void 0),qh=Kh.Provider;var Yh=o(1598),Xh=o(67659),Jh=o(16049),Qh=o(54194),ep=o(65538);const tp="fui-FluentProvider",ip=(0,ep.s)({root:{sj55zd:"f19n0e5",De3pzq:"fxugw4r",fsow6f:["f1o700av","fes3tcz"],Bahqtrf:"fk6fouc",Be2twd7:"fkhj508",Bhrd7zp:"figsok6",Bg96gwp:"f1i3iumi"}},{d:[".f19n0e5{color:var(--colorNeutralForeground1);}",".fxugw4r{background-color:var(--colorNeutralBackground1);}",".f1o700av{text-align:left;}",".fes3tcz{text-align:right;}",".fk6fouc{font-family:var(--fontFamilyBase);}",".fkhj508{font-size:var(--fontSizeBase300);}",".figsok6{font-weight:var(--fontWeightRegular);}",".f1i3iumi{line-height:var(--lineHeightBase300);}"]}),np=dh.useInsertionEffect?dh.useInsertionEffect:Eh.L,op=(e,t)=>{const i=(0,xh.O)(),n=ch.useContext(jh),o=null!==(r=ch.useContext(Kh))&&void 0!==r?r:{};var r;const a=ch.useContext(Fh.Qb)||{},{applyStylesToPortals:s=!0,customStyleHooks_unstable:l,dir:c=i.dir,targetDocument:d=i.targetDocument,theme:u,overrides_unstable:h={}}=e,p=rp(n,u),g=rp(o,h),f=rp(a,l),m=(0,Xh.a)();var v;const{styleTagId:y,rule:C}=(e=>{const{targetDocument:t,theme:i,rendererAttributes:n}=e,o=ch.useRef(),r=(0,Ph.Me)(tp),a=n,s=ch.useMemo((()=>function(e,t){return t?`${e} { ${Object.keys(t).reduce(((e,i)=>`${e}--${i}: ${t[i]}; `),"")} }`:`${e} {}`}(`.${r}`,i)),[i,r]);return function(e,t){ch.useState((()=>{if(!e)return;const i=e.getElementById(t);i&&e.head.append(i)}))}(t,r),np((()=>{const e=null==t?void 0:t.getElementById(r);return e?o.current=e:(o.current=((e,t)=>{if(!e)return;const i=e.createElement("style");return Object.keys(t).forEach((e=>{i.setAttribute(e,t[e])})),e.head.appendChild(i),i})(t,{...a,id:r}),o.current&&((e,t)=>{const i=e.sheet;i&&(i.cssRules.length>0&&i.deleteRule(0),i.insertRule(t,0))})(o.current,s)),()=>{var e;null===(e=o.current)||void 0===e||e.remove()}}),[r,t,s,a]),{styleTagId:r,rule:s}})({theme:p,targetDocument:d,rendererAttributes:null!==(v=m.styleElementAttributes)&&void 0!==v?v:{}});return{applyStylesToPortals:s,customStyleHooks_unstable:f,dir:c,targetDocument:d,theme:p,overrides_unstable:g,themeClassName:y,components:{root:"div"},root:Oh.Bx((0,Qh.h)("div",{...e,dir:c,ref:(0,Ah.r)(t,(0,Jh._)({targetDocument:d}))}),{elementType:"div"}),serverStyleProps:{cssRule:C,attributes:{...m.styleElementAttributes,id:y}}}};function rp(e,t){return e&&t?{...e,...t}:e||t}const ap=ch.forwardRef(((e,t)=>{const i=op(e,t);(e=>{const t=(0,Xh.a)(),i=ip({dir:e.dir,renderer:t});e.root.className=(0,Hh.z)(tp,e.themeClassName,i.root,e.root.className)})(i);const n=function(e){const{applyStylesToPortals:t,customStyleHooks_unstable:i,dir:n,root:o,targetDocument:r,theme:a,themeClassName:s,overrides_unstable:l}=e,c=ch.useMemo((()=>({dir:n,targetDocument:r})),[n,r]),[d]=ch.useState((()=>({}))),u=ch.useMemo((()=>({textDirection:n})),[n]);return{customStyleHooks_unstable:i,overrides_unstable:l,provider:c,textDirection:n,iconDirection:u,tooltip:d,theme:a,themeClassName:t?o.className:s}}(i);return((e,t)=>((0,Bh.a)(e),(0,Mh.tZ)(xh.z,{value:t.provider,children:(0,Mh.tZ)(zh,{value:t.theme,children:(0,Mh.tZ)(Wh.U,{value:t.themeClassName,children:(0,Mh.tZ)(Fh.UF,{value:t.customStyleHooks_unstable,children:(0,Mh.tZ)(Sh,{value:t.tooltip,children:(0,Mh.tZ)(Gh.n,{dir:t.textDirection,children:(0,Mh.tZ)(Yh._,{value:t.iconDirection,children:(0,Mh.tZ)(qh,{value:t.overrides_unstable,children:(0,Mh.BX)(e.root,{children:[(0,Vh.N)()?null:(0,Mh.tZ)("style",{dangerouslySetInnerHTML:{__html:e.serverStyleProps.cssRule},...e.serverStyleProps.attributes}),e.root.children]})})})})})})})})})))(i,n)}));ap.displayName="FluentProvider";var sp=o(43763);function lp(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function cp(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?lp(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):lp(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}function dp(e){const t=[...e.DailyPrices].sort(((e,t)=>e.minPrice===t.minPrice?+e.dtg-+e.dtg:e.minPrice-t.minPrice)),i=e.DailyPrices.findIndex((e=>e===t.at(0))),n=e.DailyPrices.findIndex((e=>e===t.at(-1)));let o=e.MedianPrice;o&&!e?.UseV2Insights||(o=t[Math.floor(t.length/2)].minPrice);const r=e.DailyPrices.findIndex((e=>e.minPrice===o));return{lowestIndex:i,highestIndex:n,medianIndex:r}}function up(e,t,i,n,o){const r=t.ProductDetails.currency||"$",a=Intl.DateTimeFormat(navigator.language),s=`${r}${t.DailyPrices[i]?.minPrice}`,l=a.format(t.DailyPrices[i]?.dtg),c=`${r}${t.DailyPrices[n]?.minPrice}`,d=a.format(t.DailyPrices[n]?.dtg),u={chart:{"aria-describedby":"price-history-chart-description","aria-label":e.phSectionTitle},highestPricePoint:{"aria-describedby":"highest-price-point-description","aria-label":(0,T.fZ)("phNewHighestPriceLabel",e.phNewHighestPriceLabel,c,d)},lowestPricePoint:{"aria-describedby":"lowest-price-point-description","aria-label":(0,T.fZ)("phNewLowestPriceLabel",e.phNewLowestPriceLabel,s,l)}};if(isNaN(t.CurrentPrice)||(u.tooltip={"aria-describedby":"price-tooltip","aria-label":(0,T.fZ)("phNewTodayPrice",e.phNewTodayPrice,t.CurrentPrice.toString())},u.activePricePoint={"aria-describedby":"active-price-point-description","aria-label":(0,T.fZ)("phNewSelectedPrice",e.phNewSelectedPrice,t.CurrentPrice.toString())}),o>-1&&t.MedianPrice){const i=`${r}${t.MedianPrice}`,n=a.format(t.DailyPrices[o]?.dtg);u.chart["aria-label"]=(0,T.fZ)("phNewChartLabel",e.phNewChartLabel,s,l,c,d,i,n),u.medianPricePoint={"aria-describedby":"median-price-point-description","aria-label":(0,T.fZ)("phNewMedianPriceLabel",e.phNewMedianPriceLabel,i,n)},u.activePricePoint||(u.activePricePoint={"aria-describedby":"active-price-point-description","aria-label":(0,T.fZ)("phNewSelectedPrice",e.phNewSelectedPrice,i)})}return u}const hp=async(e,t=!1,i,n,o)=>{const r=await ph(),a=t?r.dark:r.light,s=e.DailyPrices.map((e=>({date:e.dtg.toISOString(),price:e.minPrice}))),l=e.ProductDetails.currency?e.ProductDetails.currency:"¥",c="¥"===l||"¥"===l?"CNY":(0,ne.Vv)(l),{highestIndex:d,lowestIndex:u,medianIndex:h}=dp(e),p=up(i,e,u,d,h);return ch.createElement(ap,{theme:a,style:{backgroundColor:"transparent"}},ch.createElement("div",{onMouseEnter:n,onMouseLeave:o},ch.createElement(ch.Suspense,null,ch.createElement(hh,{type:"default",style:{padding:"14px"}},ch.createElement(uh,{direction:"vertical",spacing:"large"},ch.createElement(fh,{ariaProps:cp({},p),color:"brand",data:s,currency:c,locale:"zh-CN"===navigator.language?"zh-CN":"en-US"}),ch.createElement("div",{style:{display:"flex",padding:"2px",flexDirection:"column",width:"100%",justifyContent:"space-between"}},ch.createElement(pp,{label:i.pcLowestUpdated,content1:l+e.DailyPrices[u].minPrice,content2:e.DailyPrices[u].dtg.toLocaleDateString(),isDarkMode:t}),ch.createElement(pp,{label:i.cjkHighestPrice,content1:l+e.DailyPrices[d].minPrice,content2:e.DailyPrices[d].dtg.toLocaleDateString(),isDarkMode:t})))))))},pp=({label:e,content1:t,content2:i,isDarkMode:n})=>ch.createElement("div",{style:{display:"flex",padding:"2px",flexDirection:"row",fontSize:"12px"}},ch.createElement("div",{style:{color:n?"#ffffff":"#000000",opacity:.8,marginRight:"16px"}},e," "),ch.createElement("div",{style:{color:n?"#ffffff":"#000000",opacity:.6,marginRight:"16px"}},t),ch.createElement("div",{style:{color:n?"#ffffff":"#000000",opacity:.6}},i)),gp=(e,t)=>{sp.render(ch.createElement(e,null),t)};var fp=class extends Qu{constructor(e,t){super(),(0,s.Z)(this,"vehicleInfo",void 0),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"scenario",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"sectionId","autosMyGarageSection"),(0,s.Z)(this,"heroImgUrl",void 0),(0,s.Z)(this,"addToMyGarageUrl",void 0),(0,s.Z)(this,"marketValue",void 0),(0,s.Z)(this,"supportedMarkets",new Set(["en-us"])),(0,s.Z)(this,"base64",new sh.D),(0,s.Z)(this,"addToMyGarageUrlTemplateMap",new Map([["en-us","https://www.msn.com/en-us/autos/marketplace/mygarage?q="]])),(0,s.Z)(this,"market",void 0),(0,s.Z)(this,"enableV2",!1),(0,s.Z)(this,"formCode","MARNOT"),this.logModule=t.logModule,this.pageHandlerModule=t.pageHandlerModule,this.flyoutData=e,this.utilities=t.viewModulesUtilities,this.telemetryUtilities=t.telemetryHandler,this.assets=new class{getStyles(){return"\n .myGarageUppperPartWrapper {\n cursor: pointer;\n display: flex;\n }\n .myGarageUppperPartWrapperV2 {\n cursor: pointer;\n display: flex;\n flex-direction: column;\n }\n .myGarageImageWrapper {\n display: flex;\n width: 162px;\n height: 97px;\n overflow: hidden;\n display: flex;\n align-items: center;\n justify-content: center;\n display: flex;\n }\n .myGaragebtnCheckNow {\n font-size: 14px;\n border-radius: 4px;\n color: rgba(26,26,26,1);\n background-color: #036EC9;\n margin-bottom: 10px;\n margin-left: 16px;\n margin-right: 16px;\n height: 36px;\n width: -webkit-fill-available;\n border: 1px solid rgba(214, 214, 214, 1);\n }\n .myGaragebtnCheckNowV2 {\n font-size: 12px;\n line-height: 24px;\n width: -webkit-fill-available;\n height: 24px;\n color: rgba(0, 0, 0, 0.86);\n margin-bottom: 12px;\n margin-left: 16px;\n margin-right: 16px;\n }\n .myGaragebtnCheckNowV2::part(control) {\n border: 1px solid rgba(0, 0, 0, 0.18);\n padding: 2px 8px 2px 8px;\n }\n .myGarageTitleWrapper {\n width: 137px;\n margin-left: 16px;\n margin-top: 17px;\n }\n .myGarageTitleWrapperV2 {\n margin-top: 17px;\n }\n .myGarageTitle {\n font-weight: 600;\n font-size: 16px;\n display: flex;\n text-overflow: ellipsis;\n overflow: hidden;\n margin-bottom: 6px;\n }\n .autosMyGarageProductImage {\n width: 100%;\n object-fit: cover;\n transition: width 0.5s;\n }\n .autosMyGarageProductImage:hover {\n width: 125%;\n object-fit: cover;\n transition: width 0.5s;\n }\n .MyGarageheaderTitle {\n font-weight: 600;\n text-align: start;\n font-size: 18px;\n line-height: 24px;\n margin: 16px 0px 12px 0;\n }\n .myGaragePriceHistoryWrapper {\n padding: 12px 16px;\n overflow: hidden;\n border-radius: 8px;\n }\n .myGarageDisclaimer {\n color: #707070;\n font-size: 12px;\n padding: 0 16px 8px 16px;\n }\n "}getDarkModeStyles(){return"\n .myGaragebtnCheckNowV2 {\n color: #FFF;\n }\n .myGaragebtnCheckNowV2::part(control) {\n background: transparent;\n border: 1px solid rgba(255, 255, 255, 0.28);\n padding: 2px 8px 2px 8px;\n }\n "}},this.storageHandler=t.storageHandler}GetModuleName(){return r.ModuleNames.AUTOSMYGARAGE}async ShouldRenderModule(){if(this.pageHandlerModule.TriggerExperiment(f.H.autosMyGarageEntryPoint),this.pageHandlerModule.TriggerExperiment(f.H.autosMyGarageEntryPointV2),this.pageHandlerModule.TriggerExperiment(f.H.autosMarketValueV2),this.enableV2=e.R.isExperimentActive(f.H.autosMarketValueV2),!(e.R.isExperimentActive(f.H.autosMyGarageEntryPoint)||e.R.isExperimentActive(f.H.autosMyGarageEntryPointV2)||this.enableV2))return Promise.resolve(!1);if(this.market=(0,T.uf)(this.flyoutData.common.market,this.flyoutData.dataStoreModule.ApiData?.retailerData?.exclusiveMarket),!this.supportedMarkets.has(this.market))return!1;const t=await this.storageHandler.getStorageString(Ce.Q.AutosMarketplace);if(!t)return Promise.resolve(!1);try{const e=JSON.parse(t);if(e?.currentUrl?.toLowerCase()!==this.flyoutData.common.lastCommittedURL?.toLowerCase())return Promise.resolve(!1);if(e?.autosData){if(this.vehicleInfo=new lh.Z(e?.autosData?.vehicleInfo),!this.vehicleInfo.isValid)return Promise.resolve(!1);const t=await this.getAutosEntity(this.vehicleInfo.make,this.vehicleInfo.model,this.vehicleInfo.year);if(null===t||!t?.defaultImage)return Promise.resolve(!1);if(this.enableV2){const e=await this.getAutosEntityMarketValue(this.vehicleInfo.make,this.vehicleInfo.model,this.vehicleInfo.year,t.autosTrim,this.market);if(null===e||!e?.marketValues?.[0]?.values)return Promise.resolve(!1);this.marketValue=e.marketValues[0].values.reverse()}return this.heroImgUrl=t.defaultImage,this.addToMyGarageUrl=this.createAddToMyGarageUrl(this.vehicleInfo.make,this.vehicleInfo.model,this.vehicleInfo.year),Promise.resolve(this.vehicleInfo.isValid)}}catch(e){}return Promise.resolve(!1)}async renderModule(){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());const e=document.createElement("msft-edge-shopping-section");e.id=this.sectionId,e.accordion=!0,e.expanded=!0,e.isBlock=!0,e.titleText=this.enableV2?(0,T.fZ)("autosMyGarageTitleText",this.flyoutData.strings.autosMyGarageTitleTextV2,this.formatMakeModel(this.vehicleInfo?.make),this.formatMakeModel(this.vehicleInfo?.model)):this.flyoutData.strings.autosMyGarageHeaderTitle;const n=(0,Y.Ux)("DIV",{className:"mygarageContainer"});n.id="mygaragecontainer";const o=(0,Y.Ux)("DIV",{className:this.enableV2?"myGarageUppperPartWrapperV2":"myGarageUppperPartWrapper"});if(this.enableV2){const e=(0,Y.Ux)("DIV",{className:"myGaragePriceHistoryWrapper"});let t="";if(this.marketValue.at(-1)?.mileage){const e=this.marketValue.at(-1)?.mileage||0;t=(0,T.fZ)("autosMyGarageDisclaimer",this.flyoutData.strings.autosMyGarageDisclaimer,this.formatMileage(e))}const i=await(async(e,t=!1,i,n,o)=>{const r=await ph(),a=cp({},t?r.dark:r.light),s=e.filter((e=>!!e)).map((e=>{const t=e.period.split("-"),i=parseInt(t[0],10),n=parseInt(t[1],10)-1;return{date:new Date(i,n,1,12).toISOString(),price:e.marketValue}})),l=s.at(0)?.price,c=s.at(-1)?.price,d=Math.round((c-l)/l*100*-1);let u,h,p;const g=e[0].period.split("-"),f=g[0],m=parseInt(g[1],10),v=[e.at(-1)?.minMarketValue,e.at(-1)?.maxMarketValue],y=new Date(0,m,0).toLocaleString("default",{month:"short"});t&&(a.colorNeutralForeground4="rgba(255, 255, 255, 0.84)"),d>=0?(u=0===d?"brand":"green",p=0===d?a.colorBrandForeground1:a.colorPaletteGreenForeground1,h=(0,T.fZ)("autosMyGarageTitleText",i.autosMyGaragePriceDropText,y,f)):(u="red",p=a.colorPaletteRedForeground1,h=(0,T.fZ)("autosMyGarageTitleText",i.autosMyGaragePriceIncreaseText,y,f));const{lowestIndex:C,highestIndex:b,medianIndex:S}=function(e){const t=[...e].sort(((e,t)=>e.price===t.price?+e.date-+t.date:e.price-t.price)),i=e.findIndex((e=>e===t.at(0))),n=e.findIndex((e=>e===t.at(-1))),o=t[Math.floor(t.length/2)].price,r=e.findIndex((e=>e.price===o));return{lowestIndex:i,highestIndex:n,medianIndex:r}}(s),x=function(e,t,i,n,o){const r=`$${t[i].price}`,a=new Date(t[i].date),s=`$${t[n].price}`,l=new Date(t[n].date),c=t.at(-1)?.price,d={chart:{"aria-describedby":"price-history-chart-description","aria-label":e.phSectionTitle},highestPricePoint:{"aria-describedby":"highest-price-point-description","aria-label":(0,T.fZ)("phNewHighestPriceLabel",e.phNewHighestPriceLabel,s,`${l.toLocaleString("default",{month:"long"})} ${l.getFullYear()}`)},lowestPricePoint:{"aria-describedby":"lowest-price-point-description","aria-label":(0,T.fZ)("phNewLowestPriceLabel",e.phNewLowestPriceLabel,r,`${a.toLocaleString("default",{month:"long"})} ${a.getFullYear()}`)}};if(c&&(d.tooltip={"aria-describedby":"price-tooltip","aria-label":(0,T.fZ)("phNewTodayPrice",e.phNewTodayPrice,c.toString())},d.activePricePoint={"aria-describedby":"active-price-point-description","aria-label":(0,T.fZ)("phNewSelectedPrice",e.phNewSelectedPrice,c.toString())}),o>-1){const i=`$${t[o].price}`,n=new Date(t[o].date);d.chart["aria-label"]=(0,T.fZ)("phNewChartLabel",e.phNewChartLabel,r,`${a.toLocaleString("default",{month:"long"})} ${a.getFullYear()}`,s,`${l.toLocaleString("default",{month:"long"})} ${l.getFullYear()}`,i,`${n.toLocaleString("default",{month:"long"})} ${n.getFullYear()}`),d.medianPricePoint={"aria-describedby":"median-price-point-description","aria-label":(0,T.fZ)("phNewMedianPriceLabel",e.phNewMedianPriceLabel,i,`${n.toLocaleString("default",{month:"long"})} ${n.getFullYear()}`)},d.activePricePoint||(d.activePricePoint={"aria-describedby":"active-price-point-description","aria-label":(0,T.fZ)("phNewSelectedPrice",e.phNewSelectedPrice,i)})}return d}(i,s,C,b,S),w=(0,ne.qm)("$")?"$":(0,ne.Vv)("$"),O=`${Math.abs(d)}% ${h}.`,P=v&&v[0]&&v[1]?`This vehicle ranges from $${v[0].toLocaleString(void 0,{maximumFractionDigits:2})} to $${v[1].toLocaleString(void 0,{maximumFractionDigits:2})}`:"";return ch.createElement(ap,{theme:a,style:{backgroundColor:"transparent"},"aria-label":`${O} ${P}`},ch.createElement("div",null,ch.createElement(ch.Suspense,null,ch.createElement(uh,{direction:"vertical",spacing:"large"},ch.createElement(uh,{spacing:"small"},d>=0?ch.createElement("svg",{role:"presentation",xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 32 32",fill:"none"},ch.createElement("path",{d:"M16 2C8.26801 2 2 8.26801 2 16C2 23.732 8.26801 30 16 30C23.732 30 30 23.732 30 16C30 8.26801 23.732 2 16 2ZM9.29289 15.2929C9.68342 14.9024 10.3166 14.9024 10.7071 15.2929L15 19.5858L15 10C15 9.44771 15.4477 9 16 9C16.5523 9 17 9.44771 17 10L17 19.5858L21.2929 15.2929C21.6834 14.9024 22.3166 14.9024 22.7071 15.2929C23.0976 15.6834 23.0976 16.3166 22.7071 16.7071L16.7071 22.7071C16.3166 23.0976 15.6834 23.0976 15.2929 22.7071L9.29289 16.7071C8.90237 16.3166 8.90237 15.6834 9.29289 15.2929Z",fill:p})):ch.createElement("svg",{role:"presentation",xmlns:"http://www.w3.org/2000/svg",width:"32",height:"32",viewBox:"0 0 32 32",fill:"none"},ch.createElement("path",{d:"M16 30C8.26801 30 2 23.732 2 16C2 8.26801 8.26801 2 16 2C23.732 2 30 8.26801 30 16C30 23.732 23.732 30 16 30ZM9.29289 16.7071C9.68342 17.0976 10.3166 17.0976 10.7071 16.7071L15 12.4142L15 22C15 22.5523 15.4477 23 16 23C16.5523 23 17 22.5523 17 22L17 12.4142L21.2929 16.7071C21.6834 17.0976 22.3166 17.0976 22.7071 16.7071C23.0976 16.3166 23.0976 15.6834 22.7071 15.2929L16.7071 9.29289C16.3166 8.90237 15.6834 8.90237 15.2929 9.29289L9.29289 15.2929C8.90237 15.6834 8.90237 16.3166 9.29289 16.7071Z",fill:p})),ch.createElement("div",{style:{display:"flex",flexDirection:"row",alignItems:"baseline"}},ch.createElement("div",{style:{fontSize:"24px",fontWeight:600,lineHeight:"32px",color:p}},Math.abs(d),"%"),ch.createElement("div",{style:{fontSize:"16px",fontWeight:600,lineHeight:"22px",color:a.colorNeutralForeground1}}," ",h))),v&&v[0]&&v[1]&&ch.createElement(uh,{direction:"horizontal",spacing:"medium"},ch.createElement("svg",{role:"presentation",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",fill:"none"},ch.createElement("path",{d:"M10.5 8C8.84315 8 7.5 9.34315 7.5 11C7.5 12.6569 8.84315 14 10.5 14C12.1569 14 13.5 12.6569 13.5 11C13.5 9.34315 12.1569 8 10.5 8ZM9 11C9 10.1716 9.67157 9.5 10.5 9.5C11.3284 9.5 12 10.1716 12 11C12 11.8284 11.3284 12.5 10.5 12.5C9.67157 12.5 9 11.8284 9 11ZM2 7.25C2 6.00736 3.00736 5 4.25 5H16.75C17.9926 5 19 6.00736 19 7.25V14.75C19 15.9926 17.9926 17 16.75 17H4.25C3.00736 17 2 15.9926 2 14.75V7.25ZM4.25 6.5C3.83579 6.5 3.5 6.83579 3.5 7.25V8H4.25C4.66421 8 5 7.66421 5 7.25V6.5H4.25ZM3.5 12.5H4.25C5.49264 12.5 6.5 13.5074 6.5 14.75V15.5H14.5V14.75C14.5 13.5074 15.5074 12.5 16.75 12.5H17.5V9.5H16.75C15.5074 9.5 14.5 8.49264 14.5 7.25V6.5H6.5V7.25C6.5 8.49264 5.49264 9.5 4.25 9.5H3.5V12.5ZM17.5 8V7.25C17.5 6.83579 17.1642 6.5 16.75 6.5H16V7.25C16 7.66421 16.3358 8 16.75 8H17.5ZM17.5 14H16.75C16.3358 14 16 14.3358 16 14.75V15.5H16.75C17.1642 15.5 17.5 15.1642 17.5 14.75V14ZM3.5 14.75C3.5 15.1642 3.83579 15.5 4.25 15.5H5V14.75C5 14.3358 4.66421 14 4.25 14H3.5V14.75ZM4.40137 18.5C4.92008 19.3967 5.8896 20 7.00002 20H17.25C19.8734 20 22 17.8734 22 15.25V10C22 8.8896 21.3967 7.92008 20.5 7.40137V15.25C20.5 17.0449 19.0449 18.5 17.25 18.5H4.40137Z",style:{fill:t?"white":"black",fillOpacity:"0.56"}})),ch.createElement("div",{style:{fontWeight:600,lineHeight:"20px",fontSize:"14px",color:t?"rgba(255, 255, 255, 0.84)":"rgba(0, 0, 0, 0.74)",marginRight:"-8px"}},"$",v[0].toLocaleString(void 0,{maximumFractionDigits:2})," - $",v[1].toLocaleString(void 0,{maximumFractionDigits:2})),o&&ch.createElement(Zh,{relationship:"label",content:o},ch.createElement("svg",{tabIndex:0,role:"tooltip",xmlns:"http://www.w3.org/2000/svg",width:"20",height:"20",viewBox:"0 0 20 20",fill:"none"},ch.createElement("path",{d:"M9.5 10.5C9.5 10.2239 9.72386 10 10 10C10.2761 10 10.5 10.2239 10.5 10.5V12C10.5 12.2761 10.2761 12.5 10 12.5C9.72386 12.5 9.5 12.2761 9.5 12V10.5ZM10 7.75C9.58579 7.75 9.25 8.08579 9.25 8.5C9.25 8.91421 9.58579 9.25 10 9.25C10.4142 9.25 10.75 8.91421 10.75 8.5C10.75 8.08579 10.4142 7.75 10 7.75ZM5 10C5 7.23858 7.23858 5 10 5C12.7614 5 15 7.23858 15 10C15 12.7614 12.7614 15 10 15C7.23858 15 5 12.7614 5 10ZM10 6C7.79086 6 6 7.79086 6 10C6 12.2091 7.79086 14 10 14C12.2091 14 14 12.2091 14 10C14 7.79086 12.2091 6 10 6Z",fill:t?"#D6D6D6":"#424242"})))),ch.createElement(fh,{ariaProps:cp({},x),color:u,data:s,tooltipTodayLabel:"Today",tooltipDateFormatter:e=>`${e.toLocaleString("default",{month:"short"})} ${e.getFullYear()}`,currency:w,disableAnimation:!0,locale:n||"en-US"})))))})(this.marketValue,this.utilities.isDarkMode(),this.flyoutData.strings,this.market,t);gp((()=>i),e),o.appendChild(e)}else{const e=(0,Y.Ux)("DIV",{className:"myGarageTitleWrapper"}),t=(0,Y.Ux)("DIV",{className:"myGarageTitle"});t.textContent=(0,T.fZ)("autosMyGarageTitleText",this.flyoutData.strings.autosMyGarageTitleText,this.formatMakeModel(this.vehicleInfo?.make),this.formatMakeModel(this.vehicleInfo?.model)),e.appendChild(t),o.appendChild(e);const i=(0,Y.Ux)("DIV",{className:"myGarageImageWrapper"}),n=(0,Y.Ux)("IMG",{className:"autosMyGarageProductImage"});n.src=this.heroImgUrl,n.setAttribute("aria-hidden","true"),i.appendChild(n),o.appendChild(i)}n.appendChild(o),this.renderCheckNowButton(n),e.appendChild(n),this.manageLinkEvents(o);const a=this.CreateModule(e,r.H7.AUTOSMYGARAGE,r.ModuleNames.AUTOSMYGARAGE,r.$k.CONTEXTUAL,r.SV.BLOCK),s=new t.Z(i.xu.AutosMyGarageRenderViewModule,void 0,void 0,void 0,this.constructTelemetryMetaData());return this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Autos MyGarage Module",s),Promise.resolve(a)}populateMainHeader(){const e=this.flyoutData.common.shopping,t=(0,Y.Ux)("DIV",{className:"headerContentWrapper"});t.slot="header-content";const i=(0,Y.Ux)("H2",{className:"MyGarageheaderTitle"});i.textContent=this.enableV2?(0,T.fZ)("autosMyGarageTitleText",this.flyoutData.strings.autosMyGarageTitleTextV2,this.formatMakeModel(this.vehicleInfo?.make),this.formatMakeModel(this.vehicleInfo?.model)):this.flyoutData.strings.autosMyGarageHeaderTitle,t.appendChild(i),e.appendChild(t)}sendAutosMarketplaceDwellTimeTelemery(e,n,o){const r=Date.now()-e,a=new t.Z(n,void 0,void 0,void 0,this.constructTelemetryMetaData());this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,`${o} - ${r} ms`,a),r>=1e3&&K.bS&&this.pageHandlerModule.RecordAsUserAction(K.bS.AUTOS_MYGARAGE_HOVER)}async getAutosEntityMarketValue(e,t,i,n,o="en-us"){try{const r="https://www.bingapis.com/api/autosmarketplace/v1/marketvalue?scenario=edgeflyoutv3",a={graph:!0,vehicles:[{make:e,model:t,market:o,trim:n,year:i,vin:null}]},s=await fetch(r,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(a)});if(s.ok)return await s.json()}catch(e){return null}return null}async getAutosEntity(e,t,i,n="en-us"){try{const o=`https://www.bingapis.com/api/autosmarketplace/v1/autosentity?scenario=edgeflyoutv3&market=${n}&make=${e}&model=${t}&year=${i}`,r=await fetch(o,{method:"GET",headers:{"Content-Type":"application/json"}});if(r.ok)return await r.json()}catch(e){return null}return null}renderCheckNowButton(e){const t=(0,Y.Ux)("fluent-button",{className:this.enableV2?"myGaragebtnCheckNowV2":"myGaragebtnCheckNow"});this.enableV2||t.setAttribute("appearance","accent"),t.textContent=this.enableV2?this.flyoutData.strings.autosMyGarageActionButtonTextV2:this.flyoutData.strings.autosMyGarageActionButtonText;const n=this.flyoutData.common.currentDevice;t.addEventListener("click",(()=>{this.pageHandlerModule.RecordAsUserAction(K.bS.AUTOS_MARKETPLACE_MYGARAGE_CHECK_NOW),this.pageHandlerModule.RecordAsUserEngagement(q.FV.AUTOS_MARKETPLACE_MYGARAGE_CHECK_NOW,this.flyoutData.common.popupOrigination);const e=new W.Z(i.$S.NavigatedToMyGarage,this.telemetryUtilities.setContentViewed(this.GetModuleName()),void 0);this.logModule.LogInfoEvent(i.R.ButtonClick,"Navigate to Autos Marketplace MyGarage",e);const t=this.addToMyGarageUrl;n===r.AS.Desktop&&this.pageHandlerModule.NavigateToOtherSellerWithDisposition(t,ju.$.NEW_FOREGROUND_TAB)})),e.appendChild(t)}manageLinkEvents(e){let n=0,o=0,r=!0;e.addEventListener("mouseenter",(()=>{s()})),e.addEventListener("mouseleave",(()=>{l()})),e.addEventListener("focus",(()=>{s()})),e.addEventListener("blur",(()=>{l()}));const a=this.logModule,s=()=>{if(!(Date.now()-o>200))return;r=!0,n=Date.now();const e=new t.Z(i.xu.AutosMyGarageHovered,void 0,void 0,void 0,this.constructTelemetryMetaData());a.LogInfoEvent(i.R.EdgeFlyoutStatus,"Autos My Garage module hover",e)},l=()=>{o=Date.now(),setTimeout((()=>{if(r){r=!1,this.sendAutosMarketplaceDwellTimeTelemery(n,i.xu.AutosMyGarageDwellTimeHover,"Autos My Garage hover time over module");const e=new t.Z(i.xu.AutosMyGarageDwellTimeHover,void 0,void 0,void 0,this.constructTelemetryMetaData());a.LogInfoEvent(i.R.EdgeFlyoutStatus,"Autos My Garage Module hover exit",e)}}),200)};e.addEventListener("click",(()=>{this.navigateToMyGarage(!1)})),e.addEventListener("mousedown",(e=>{1===e.button&&this.navigateToMyGarage(!1)})),e.addEventListener("keydown",(e=>{e&&"Enter"===e.key&&this.navigateToMyGarage(!1)}))}navigateToMyGarage(e){const t=new W.Z(i.$S.NavigatedToMyGarage,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.pageHandlerModule.RecordAsUserAction(K.bS.AUTOS_MYGARAGE_MODULE_CLICK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.AUTOS_MYGARAGE_MODULE_CLICK,this.flyoutData.common.popupOrigination);const n=e?"Navigate to Autos Marketplace (MyGarage) from Autoshow Click":"Navigate to Autos Marketplace (MyGarage) - Module Click";this.logModule.LogInfoEvent(i.R.ButtonClick,n,t),this.pageHandlerModule.NavigateToRetailerSite(this.addToMyGarageUrl,this.flyoutData.common.popupOrigination)}createAddToMyGarageUrl(e,t,i,n="en-us"){const o={market:n,vehicles:[{make:e??"",model:t??"",year:i??"",inferred:!1}],focus:{module:"",id:""},mode:""},r=JSON.stringify(o);return`${this.addToMyGarageUrlTemplateMap.get(n)}${this.base64.urlEncode(r)}&form=${this.formCode}`}formatMakeModel(e){return void 0===e?"":e.toLowerCase()===e?e.charAt(0).toUpperCase()+e.slice(1).toLowerCase():e}formatMileage(e){let t="";return t=(e/=1e3).toString().split(".")[0],t}constructTelemetryMetaData(){try{return JSON.stringify({pageType:this.scenario})}catch(e){return""}}},mp=class{getStyles(){return`\n ::part(header) {\n margin-bottom: 0px;\n }\n ::part(title) {\n margin: 10px 0px 6px;\n }\n .headerContentWrapper {\n display: flex;\n text-align: center;\n flex-direction: column;\n align-items: center;\n }\n .headerTitle {\n font-weight: 600;\n align-items: center;\n font-size: 18px;\n line-height: 24px;\n margin: 0px;\n }\n msft-horizontal-card-slider msft-shopping-link, .vid_cds msft-shopping-link {\n margin: 0 !important;\n }\n #rnrWrapper {\n padding: 0 20px 20px;\n border-radius: 8px;\n display: flex;\n flex-direction: column;\n row-gap: 12px;\n }\n #rnrWrapper msft-product-card {\n border-radius: 8px;\n background-color: var(--fill-color);\n overflow: hidden;\n }\n #rnrWrapper msft-product-card::part(control) {\n border: none;\n }\n #rnrWrapper msft-product-card::part(txtRetailer) {\n color: var(--text-neutral-foreground);\n }\n .vid_cds {\n display: flex;\n column-gap: 8px;\n }\n .vid_cds msft-shopping-link { flex: 1 }\n msft-shopping-link + .vid_cds { margin-top: 5px; }\n .vid_cds:last-of-type { margin-bottom: 5px; }\n .vid_thv, .vid_thh { position: relative; }\n .vid_thv img {\n border-radius: 4px 4px 0 0;\n max-width: 100%;\n }\n .vid_thh {\n max-width: unset;\n max-height: unset;\n }\n .vid_thov {\n position: absolute;\n bottom: 0;\n right: 0;\n margin: 8px;\n border-radius: 2px\n }\n .vid_thov span {\n background-color: rgba(0,0,0,0.75);\n color: #fff;\n padding: 1px 4px;\n font-weight: bold;\n font-size: 11px;\n line-height: 14px;\n float: right;\n }\n .vid_thov .vid_thply {\n background-image: url(${this.getPlayIconUri()});\n background-repeat: no-repeat;\n background-position: center;\n width: 7px;\n height: 14px;\n }\n .seeAllLinkContainer {\n display: flex;\n justify-content: flex-end;\n padding: 0px 20px;\n }\n .seeAllLink: {\n text-decoration: none;\n cursor: pointer;\n }\n .seeAllLink:hover {\n text-decoration: underline;\n cursor: pointer;\n }\n #rnrWrapper msft-product-card:focus-visible, #rnrWrapper msft-product-card:focus {\n box-shadow: 0 0 0 calc(var(--focus-stroke-width) * 1px) var(--focus-stroke-outer);\n outline: 1px solid var(--focus-stroke-outer);\n }\n @media (prefers-color-scheme: dark) {\n #rnrWrapper msft-product-card::part(control) {\n background-color: #424242;\n }\n #rnrWrapper msft-product-card::part(txtRetailer) {\n color: #c2c2c2;\n }\n }`}getExpertReviewShoppingLinkShadowStyles(){return"\n .control {\n padding: 8px 15px 10px 15px !important;\n grid-template-columns: auto 1fr auto !important;\n grid-template-rows: minmax(20px, auto) 1fr;\n grid-row-gap: 8px;\n }\n .control .caption, .provider, .cardtitle {\n overflow: hidden;\n text-overflow: ellipsis;\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n }\n .provider, .cardtitle { font-size: 14px; }\n .cardtitle { grid-column: 1 / 3; }\n .rating { font-size: 16px; }\n .control .caption {\n grid-column: 1 / 4;\n font-weight: normal;\n }"}getPlayIconUri(){return"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAcAAAAIBAMAAADHKvg1AAAAIVBMVEX///////////////////////////////////////////9/gMdvAAAACnRSTlMAETNEVWaImbvuo4D1oAAAAB9JREFUCB1jmMoABKuaQcSqQhCxKgFGgLhNQIkpQAwA8zkLyQAl6F0AAAAASUVORK5CYII="}getNotificationStyles(){return"\n .title {\n font-size: 16px;\n font-weight: 600;\n line-height: 22px;\n margin-top: 0px;\n margin-bottom: 12px;\n text-align: left;\n overflow: hidden;\n text-overflow: ellipsis;\n display: -webkit-box;\n -webkit-line-clamp: 1;\n -webkit-box-orient: vertical;\n }\n .titleV2 {\n font-size: 16px;\n font-weight: 600;\n line-height: 22px;\n text-align: left;\n overflow: hidden;\n text-overflow: ellipsis;\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical; \n }\n .reviewTitle {\n font-size: 16px;\n font-weight: 600;\n line-height: 22px;\n width: 100%;\n text-align: left;\n overflow: hidden;\n text-overflow: ellipsis;\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n margin-top: 12px;\n }\n .reviewTitleV2 {\n font-size: 14px;\n line-height: 20px;\n width: 100%;\n text-align: left;\n overflow: hidden;\n text-overflow: ellipsis;\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n margin-top: 12px;\n margin-right: 10px;\n }\n .reviewTitleV3 {\n font-size: 14px;\n line-height: 20px;\n text-align: left;\n overflow: hidden;\n text-overflow: ellipsis;\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n margin-top: 4px;\n margin-right: 10px;\n }\n .imageWrapper {\n width: 250px;\n height: 130px;\n overflow: hidden;\n margin-right: 12px;\n border-radius: 8px;\n display: flex;\n align-items: center;\n justify-content: center;\n cursor: pointer;\n }\n .imageWrapperV2 {\n overflow: hidden;\n border-radius: 8px;\n display: flex;\n align-items: center;\n justify-content: center;\n cursor: pointer;\n min-width: 112px;\n width: 112px;\n }\n .notifCoverImage {\n width: 100%;\n object-fit: cover;\n transition: width 0.5s;\n }\n .videoPlayButton {\n position: absolute;\n }\n .btnActions {\n width: calc(100% - 32px);\n margin-top: 12px;\n justify-content: center;\n }\n .reviewDetails {\n display: flex;\n align-items: center;\n justify-content: space-between;\n margin-top: 8px;\n }\n .reviewDate {\n color: #767676;\n font-size: 12px;\n line-height: 16px;\n }\n .reviewViews {\n color: #424242;\n font-weight: 600;\n font-size: 12px;\n line-height: 16px;\n display: flex;\n gap: 8px;\n align-items: center;\n }\n .mainContent {\n display: flex;\n display: flex;\n padding-bottom: 12px;\n border-bottom: 1px solid #f3f3f3;\n }\n "}getNotificationDarkModeStyles(){return"\n .reviewDate {\n color: #D0D0D0;\n }\n .reviewViews {\n color: #FFFFFF;\n }\n .reviewViews path {\n fill: #FFFFFF;\n }\n .mainContent {\n border-bottom: 1px solid #5b5b5b;\n }\n "}};class vp extends Qu{constructor(e,t,i){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"reviewData",void 0),(0,s.Z)(this,"newsAsReviewData",void 0),(0,s.Z)(this,"scenario",void 0),this.stateManagement=e,this.pageHandlerModule=i.pageHandlerModule,this.logModule=i.logModule,this.flyoutData=t,this.utilities=i.viewModulesUtilities,this.telemetryUtilities=i.telemetryHandler,this.assets=new mp}GetModuleName(){return r.ModuleNames.AUTOSREVIEWS}async ShouldRenderModule(){if(!this.flyoutData.dataStoreModule.AutosData?.isAutosSupportedDomain)return Promise.resolve(!1);const e=this.flyoutData.dataStoreModule.AutosData.isAutosSupportedDomain,t=this.flyoutData.common?.lastCommittedURL?.toLowerCase();return!!oh.Z.checkPathAllowed(t,e,this.flyoutData.dataStoreModule.AutosData.includePaths)&&(this.reviewData=this.flyoutData.dataStoreModule.RatingsAndReviewsData,this.reviewData&&(this.reviewData.hasExpertReviews||this.reviewData.hasVideos)?(this.scenario=r.tl.SERP,Promise.resolve(!0)):Promise.resolve(!1))}renderModule(){if(!this.reviewData&&!this.newsAsReviewData)return Promise.resolve(null);const e=(0,Y.Ux)("msft-edge-shopping-section");e.id=vp.ShoppingSectionId,e.accordion=!0,e.expanded=!0;const n=(0,Y.Ux)("DIV");if(n.id=vp.ReviewAndRatingsContainerId,this.reviewData){e.titleText=this.reviewData.sectionTitle??(this.reviewData.hasExpertReviews?this.reviewData.hasVideos?this.flyoutData.strings.rrExpertAndVideoReviews:this.flyoutData.strings.rrExpertReviews:this.flyoutData.strings.rrVideoReviews),e.append(n),this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles());const t=this.RankOrderedCards(this.reviewData),i={l:[]};this.RenderCards(n,t,i)}else if(this.newsAsReviewData){e.titleText=this.newsAsReviewData.sectionTitle||this.flyoutData.strings.autosLatestNews,e.append(n),this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles());const t=this.RankOrderedCards(this.newsAsReviewData),i={l:[]};this.RenderCards(n,t,i),this.renderSeeMoreLink(e)}const o=this.CreateModule(e,r.H7.AUTOSREVIEWS,r.ModuleNames.AUTOSREVIEWS,r.$k.CONTEXTUAL,r.SV.LIST),a=new t.Z(i.xu.AutosRatingsAndReviewsRendered,void 0,void 0,void 0,this.constructTelemetryMetaData());return this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Autos RatingAndReview Rendered",a),Promise.resolve(o)}populateMainHeader(){const e=this.flyoutData.common.shopping,t=(0,Y.Ux)("DIV",{className:"headerContentWrapper"});t.slot="header-content";const i=(0,Y.Ux)("H2",{className:"headerTitle"});i.textContent=this.reviewData?.sectionTitle||this.newsAsReviewData?.sectionTitle||this.flyoutData.strings.autosLatestNews,t.appendChild(i),e.appendChild(t)}RankOrderedCards(e){let t=[];const i=e.hasExpertReviews,n=e.hasVideos;if(i&&!n&&e.expertReviews)t=e.expertReviews;else if(!i&&n&&e.videos){for(const t of e.videos)t.cardOrientation=It.V;t=e.videos}else e.expertReviews&&e.videos&&(t=e.expertReviews.concat(e.videos));return t.sort(Ot.Compare),t}sendAutosMarketplaceDwellTimeTelemery(e,n,o){const r=Date.now()-e,a=new t.Z(n,void 0,void 0,void 0,this.constructTelemetryMetaData());this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,`${o} - ${r} ms`,a),r>=1e3&&K.bS&&this.pageHandlerModule.RecordAsUserAction(K.bS.AUTOS_MARKETPLACE_RATING_REVIEW_HOVER)}RenderCards(e,t,i){for(let n=0,o=0;n<t.length&&o<vp.MaxCardRows;n++,o++){const o=t[n],r=_t.Narrow(o),a=void 0===r?o:void 0;if(r){const o=[r];if(i.l.push({t:"V",id:r.id,o:It[r.cardOrientation]}),r.cardOrientation===It.H)for(;t[n+1]?.cardOrientation===It.H;){const e=t[++n];o.push(e),i.l.push({t:"V",id:e.id,o:It[e.cardOrientation]})}this.renderVideosCarousel(o,e)}else a&&(this.renderExpertReview(a,e),i.l.push({t:"R",id:a.id}))}}addNavigateHandler(e,n,o,r,a,s){const l=this.logModule,c=this.pageHandlerModule,d=()=>{l.LogInfoEvent(i.R.ButtonClick,`Navigate to Autos Marketplace from review Id:${r}`,new W.Z(o,this.telemetryUtilities.setContentViewed(this.GetModuleName()),void 0,this.constructTelemetryMetaData())),c.RecordAsUserAction(s),n(c,r,a,ju.$.NEW_FOREGROUND_TAB)};e.addEventListener("click",(()=>{d()})),e.addEventListener("mousedown",(e=>{1===e.button&&d()}));let u=0,h=0,p=!0;e.addEventListener("mouseenter",(()=>{g()})),e.addEventListener("mouseleave",(()=>{f()})),e.addEventListener("focus",(()=>{g()})),e.addEventListener("blur",(()=>{f()}));const g=()=>{if(!(Date.now()-h>200))return;p=!0,u=Date.now();const e=new t.Z(i.xu.AutosMarketplaceRatingAndReviewHovered,void 0,void 0,void 0,this.constructTelemetryMetaData());l.LogInfoEvent(i.R.EdgeFlyoutStatus,"Autos Marketplace Module - ratingreview hovered",e)},f=()=>{h=Date.now(),setTimeout((()=>{if(p){p=!1,this.sendAutosMarketplaceDwellTimeTelemery(u,i.xu.AutosMarketDwellTimeHover,"Autos Marketplace - hover time over listing");const e=new t.Z(i.xu.AutosMarketDwellTimeHover,void 0,void 0,void 0,this.constructTelemetryMetaData());l.LogInfoEvent(i.R.EdgeFlyoutStatus,"Autos Marketplace Module - ratingreview exited hover",e)}}),200)}}renderExpertReview(e,t){let n;n=(0,Y.Ux)("msft-product-card"),n.shadowRoot&&(n.href="#",this.addNavigateHandler(n,((e,t,i,n)=>e.NavigateToProfessionalReviewWithDisposition(t,i,n)),i.$S.ClickExpertReview,e.id,e.url,K.bS.NAVIGATE_TO_PROFESSIONAL_REVIEW),this.utilities.applyStyles(n.shadowRoot,this.assets.getExpertReviewShoppingLinkShadowStyles()),this.stateManagement.addEventListener(Ku.e1.ModulesRendered,(()=>{const t=n.shadowRoot?.querySelector(".control");if(t){for(;t.childElementCount>0;)t.removeChild(t.children[0]);const i=!!e.attribution;if(i)t.appendChild((0,Y.Ux)("div",{className:"cardtitle"},e.title));else{if(e.favIconDomain){const i=(0,Y.Ux)("img",{className:"icon",role:"presentation"});this.utilities.addFavIconSrc(i,t,e.favIconDomain)}t.appendChild((0,Y.Ux)("div",{className:"provider"},e.provider))}if(e.rating){const i=(0,Y.Ux)("div",{className:"rating"},e.rating.rawValue.toFixed(1)),n=(0,Y.Ux)("SPAN");n.textContent="/"+e.rating.maxValue,n.style.fontWeight="normal",this.utilities.isDarkMode()?n.style.color="#FFFFFF":n.style.color="#666666",i.appendChild(n),t.appendChild(i)}if(e.caption){let i=e.caption;if(i.length>160){const e=i.match(/^.{160}\S{0,20}/),t=e&&e[0]?e[0]:i.substr(0,160);t.length<i.length&&(i=t+"...")}t.appendChild((0,Y.Ux)("div",{className:"caption"},i))}if(i&&e.attribution){const i=(0,Y.Ux)("msft-attribution");if(i.innerText=e.attribution,e.favIconDomain){const t=(0,Y.Ux)("img",{className:"icon",role:"presentation",slot:"image"});this.utilities.addFavIconSrc(t,i,e.favIconDomain)}t.appendChild(i)}}})),t.appendChild(n))}renderVideosCarousel(e,t){if(e&&e.length>0){let i=t;2===e.length&&(i=(0,Y.Ux)("div",{className:"vid_cds"}));for(let t=0;t<e.length&&t<vp.MaxVideos;t++)this.renderVideo(e[t],i,e.length);e.length>1&&t.appendChild(i)}}renderVideo(e,t,n){const o=n>2,a=n>1,s=o?128:a?166:160,l=a?160:90,c=e.publisher?e.creator?`${e.publisher} > ${e.creator}`:e.publisher:e.creator;let d,u=e.title;e.creator&&(u+=" from "+e.creator),e.publisher&&(u+=" on "+e.publisher),u+=" · Duration: "+e.durationLabel,d=(0,Y.Ux)("msft-product-card",{"aria-label":u}),d.isVideoCard=!0,d.description=e.title,d.retailer=c,d.href="#",this.addNavigateHandler(d,((e,t,i,n)=>e.NavigateToVideoReviewWithDisposition(t,i,n)),i.$S.ClickVideoReview,e.id,e.clickthroughUrl,K.bS.NAVIGATE_TO_VIDEO_REVIEW);const h=(0,Y.Ux)("style");h.textContent=`\n .control {\n height: ${l}px !important;\n padding: 0 !important;\n }\n .control .content {\n padding: 8px;\n display: block;\n }\n msft-attribution.attribution { grid-template-columns: initial; }`,a&&(o&&(h.textContent+=`.control { width: ${s} !important; }`),h.textContent+="\n .control {\n grid-template-columns: 1fr !important;\n grid-template-rows: auto 1fr;\n }"),d.shadowRoot?.appendChild(h);const p=(0,Y.Ux)("div",{className:a?"vid_thv":"vid_thh"});p.slot="image",a||(p.style.height=l+"px");const g=(0,Y.Ux)("img",{role:"presentation"});g.width=s,g.height=a?l-74:l;const f=this.flyoutData.common.urlPrefix;e.thumbnailUrl?g.src=`${f}${e.thumbnailUrl}&w=${g.width}&h=${g.height}&c=7&rs=1`:e.thumbnailId&&(g.src=`${f}https://th.bing.com/th?id=${e.thumbnailId}&pid=Api&w=${g.width}&h=${g.height}&c=7&rs=1`),p.appendChild(g);const m=(0,Y.Ux)("div",{className:"vid_thov"});e.durationText&&m.appendChild((0,Y.Ux)("span",{className:"vid_thdur"},e.durationText)),m.appendChild((0,Y.Ux)("span",{className:"vid_thply"})),this.scenario!==r.tl.FEED&&p.appendChild(m),d.appendChild(p),t.appendChild(d)}renderSeeMoreLink(e){const t=(0,Y.Ux)("DIV",{className:"seeAllLinkContainer"}),n=(0,Y.Ux)("A",{className:"seeAllLink"});n.textContent=this.flyoutData.strings.commonSeeAll;const o=this.flyoutData.common.currentDevice;n.onclick=e=>{e.preventDefault(),this.pageHandlerModule.RecordAsUserAction(K.bS.AUTOS_REVIEWS_VIDEO_SEE_MORE_CLICK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.AUTOS_REVIEWS_VIDEO_SEE_MORE_CLICK,this.flyoutData.common.popupOrigination);const t=new W.Z(i.$S.NavigatedToAutosMarketplace,this.telemetryUtilities.setContentViewed(this.GetModuleName()),void 0,this.constructTelemetryMetaData());this.logModule.LogInfoEvent(i.R.ButtonClick,"Navigate to Autos Marketplace News",t),o===r.AS.Desktop&&this.pageHandlerModule.NavigateToOtherSellerWithDisposition("https://www.msn.com/en-us/news/autos?cvid=044D3187FEA440ED9A67A784BB24C135",ju.$.NEW_FOREGROUND_TAB)},t.appendChild(n),e.appendChild(t)}constructTelemetryMetaData(){try{return JSON.stringify({pageType:this.scenario})}catch(e){return""}}}(0,s.Z)(vp,"ShoppingSectionId","sectRatingsAndReviews"),(0,s.Z)(vp,"MaxCardRows",3),(0,s.Z)(vp,"MaxVideos",5),(0,s.Z)(vp,"ReviewAndRatingsContainerId","rnrWrapper");var yp=vp,Cp=class{getStyles(){return"\n html {\n overflow: hidden;\n }\n .btnBannerPrimary {\n background: #0078D4;\n border: none;\n border-radius: 2px;\n color: #FFFFFF;\n min-height: 32px;\n height: auto;\n padding: 10px 24px;\n text-align: center;\n align-items: center;\n justify-content: center;\n display: flex;\n border-width: 0px;\n cursor: pointer;\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 12px;\n line-height: 12px;\n font-weight: bold;\n outline: none;\n }\n .bannerMainTitleAlt {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 18px;\n line-height: 25px;\n margin: 0px;\n }\n .btnBannerPrimary:focus-visible {\n border-color: #000000;\n box-shadow: 0 0 0px 2px #000000;\n }\n .btnBannerSecondary {\n border: none;\n border-radius: 2px;\n min-height: 32px;\n height: auto;\n text-align: center;\n align-items: center;\n justify-content: center;\n display: flex;\n cursor: pointer;\n background: rgba(0, 0, 0, 0.07);\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 12px;\n line-height: 12px;\n outline: none;\n padding: 1px 15px;\n }\n .btnBannerSecondary:focus-visible {\n border-color: #000000;\n box-shadow: 0 0 0px 2px #000000;\n }\n #mainDiv {\n display: grid;\n grid-template-columns: auto auto auto auto;\n position: fixed;\n top: 0px;\n left: 0px;\n width: 100%;\n height: 50px;\n overflow-y: auto;\n box-shadow: 0px 3.2px 7.2px rgba(0, 0, 0, 0.13), 0px 0px 3.8px rgba(0, 0, 0, 0.11);\n z-index: 3000000000;\n }\n .divTitle {\n display: grid;\n grid-gap: 10px;\n grid-template-columns: 1fr auto;\n justify-self: start;\n grid-column-start: 1;\n align-items: center;\n margin-left: 16px;\n margin-right: 16px;\n }\n #divContent {\n display: flex;\n flex-direction: row;\n justify-content: center;\n justify-self: flex-end;\n align-items: center;\n grid-column-start: 4;\n grid-gap: 10px;\n margin-left: 5px;\n margin-right: 5px;\n }\n .txtSmall {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 14px;\n line-height: 22px;\n margin: 0px;\n }\n .copiedIndicator {\n display: flex;\n flex-direction: row;\n width: 100%;\n height: 100%;\n z-index: 1;\n background-color: #0078D4;\n position: absolute;\n align-items: center;\n justify-content: center;\n position: absolute;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n padding: 0px;\n }\n .btnBannerClose {\n width: 30px;\n height: 30px;\n display: flex;\n align-items: center;\n cursor: pointer;\n appearance: none;\n background: none;\n border-width: 0px;\n outline: none;\n }\n .btnBannerClose:focus-visible {\n border-color: #000000;\n box-shadow: 0 0 0px 2px #000000;\n border-radius: 2px;\n }\n #btnDisableAutoShowBanner {\n width: 0px;\n overflow: hidden;\n min-width: unset;\n transition: width 2s;\n }\n .bannerBackground1 {\n background: linear-gradient(269.25deg, #FFFFFF 3.48%, #DDF1FF 34.6%, #DDFDFF 56.91%, #F3FFF9 80.98%, #FFFFFF 100.94%);\n box-shadow: 0px 12.8px 28.8px rgba(0, 0, 0, 0.13), 0px 0px 9.2px rgba(0, 0, 0, 0.11);\n }\n .bannerBackground2 {\n background: white;\n box-shadow: 0px 12.8px 28.8px rgba(0, 0, 0, 0.13), 0px 0px 9.2px rgba(0, 0, 0, 0.11);\n }\n .bannerBackground3 {\n background: linear-gradient(91.11deg, #2250AB -2.43%, #3C79D6 2.35%, #D2EFFF 21.53%, #DBFDFF 42.49%, #63B8E8 52.13%, #3C79D6 58.88%, #2250AB 69.83%, #0840B0 86.55%);\n box-shadow: 0px 3.2px 7.2px rgba(0, 0, 0, 0.13), 0px 0px 3.8px rgba(0, 0, 0, 0.11);\n }\n .bannerBackground4 {\n height: 50px;\n background: linear-gradient(91.11deg, #D2EFFF -2.41%, #DBFDFF 18.89%, #D8F5FF 27.92%, #63B8E8 40.11%, #3C79D6 49.19%, #2250AB 64.05%, #0840B0 89.38%);\n box-shadow: 0px 3.2px 7.2px rgba(0, 0, 0, 0.13), 0px 0px 3.8px rgba(0, 0, 0, 0.11);\n }\n .bannerBackground5 {\n height: 50px;\n background: linear-gradient(269.29deg, #FFF4F8 0.61%, #FFFCDE 21.7%, #FFFDE7 63.38%, #ECFFEF 86.01%, #F1FFFE 99.39%);\n box-shadow: 0px 12.8px 28.8px rgba(0, 0, 0, 0.13), 0px 0px 9.2px rgba(0, 0, 0, 0.11);\n }\n #viewMorePricesButton {\n display: flex;\n flex-direction: row;\n justify-content: center;\n align-items: center;\n padding: 5px 28px 5px 27px;\n background: linear-gradient(221.42deg, #FF8A1E -21.61%, #FC5C82 109.89%, #FFD98E 150.42%);\n box-shadow: 0px 1px 2px 1px rgba(0, 0, 0, 0.1), 0px 4px 4px rgba(0, 0, 0, 0.15);\n border-radius: 100px;\n }\n "}getWhiteTriangleButtonIcon(){return eh.Z.getTrustedHTML`<svg aria-hidden="true" width="8" height="8" viewBox="0 0 8 8" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M4.39519 6.5125L7.38869 2.8125C7.52119 2.649 7.52819 2.4455 7.44969 2.2835C7.37119 2.1215 7.20569 2 6.99369 2H1.00669C0.794689 2 0.629689 2.121 0.551189 2.2835C0.472689 2.446 0.479689 2.6485 0.612189 2.8125L3.60569 6.5125C3.70669 6.6375 3.85319 6.7 4.00019 6.7C4.14719 6.7 4.29369 6.6375 4.39519 6.5125Z" fill="white"/>
</svg>`}getCloseButtonWhite(){return eh.Z.getTrustedHTML`<svg id="flyoutCloseWhite" width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
<path d="M8.5332 8L12.5762 12.0488L12.0488 12.5762L8 8.5332L3.95117 12.5762L3.42383 12.0488L7.4668 8L3.42383 3.95117L3.95117 3.42383L8 7.4668L12.0488 3.42383L12.5762 3.95117L8.5332 8Z" fill="#FFFFFF"/>
</svg>`}getCloseButtonSeparatorCss(){return"width: 22px;\n height: 0px;\n top: 16px;\n border: 1px solid #ECECEC;\n transform: rotate(90deg);"}getCloseButtonSeparatorCssWhite(){return"width: 22px;\n height: 0px;\n top: 16px;\n border: 1px solid rgba(255, 255, 255, 0.16);\n transform: rotate(90deg);"}getBannerConfettiImage(){return eh.Z.getTrustedHTML`<svg width="405" height="50" viewBox="0 0 405 54" fill="none" xmlns="http://www.w3.org/2000/svg">
<mask id="mask0" style="mask-type:alpha" maskUnits="userSpaceOnUse" x="0" y="0" width="405" height="54">
<rect width="405" height="54" fill="#C4C4C4"/>
</mask>
<g mask="url(#mask0)">
<rect width="11.4496" height="11.4496" transform="matrix(-0.691149 0.722712 0.722712 0.691149 216.914 7)" fill="#77E0B5"/>
<circle r="5.72479" transform="matrix(-4.37114e-08 1 1 4.37114e-08 6.72479 30.7248)" fill="#77E0B5"/>
<rect width="11.4496" height="22.8992" transform="matrix(-0.258819 0.965926 0.965926 0.258819 382.963 23)" fill="#FEAC93"/>
<g filter="url(#filter0_f)">
<rect width="11.4496" height="22.8992" rx="5.72479" transform="matrix(-0.915822 -0.401584 -0.401584 0.915822 337.682 -1.40186)" fill="#F67173"/>
</g>
<path d="M111.904 13.3424C117.117 8.12971 125.569 8.12972 130.781 13.3424C135.994 18.5551 135.994 27.0065 130.781 32.2192L111.904 13.3424Z" fill="#F67173"/>
<rect width="9.72902" height="6.94028" transform="matrix(-0.5 0.866025 0.866025 0.5 86.8643 -5)" fill="#3F8EF6"/>
<rect width="11.4496" height="23.3405" transform="matrix(0.965926 0.258819 0.258819 -0.965926 235 54.5454)" fill="#38D4FA"/>
</g>
<defs>
<filter id="filter0_f" x="309" y="-15" width="37.6817" height="43.5695" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
<feFlood flood-opacity="0" result="BackgroundImageFix"/>
<feBlend mode="normal" in="SourceGraphic" in2="BackgroundImageFix" result="shape"/>
<feGaussianBlur stdDeviation="4.5" result="effect1_foregroundBlur"/>
</filter>
</defs>
</svg>
`}},bp=o(2388);const Sp=(e,t)=>{const i=(0,Y.Ux)("DIV",{style:"\n background: rgba(0, 0, 0, 0.7);\n background-blend-mode: luminosity;\n backdrop-filter: blur(2px);\n border-radius: 6px;\n width: fit-content;\n padding: 0px 6px;\n display: flex;\n gap: 4px;\n justify-content: center;\n align-items: center;\n height: 18px;\n box-sizing: border-box;\n text-transform: uppercase;\n "}),n=(0,Y.Ux)("p",{style:"\n font-weight: 400;\n font-size: 12px;\n line-height: 12px;\n margin: 0;\n color: #ffffff;\n margin-bottom: 2px;\n "},t),o=Ep(e.common.resourcesEndpoint+"common/whiteCoupon.svg",12,12);return i.appendChild(o),i.appendChild(n),i},xp=(e,t,i,n,o,r,a,s,l,c,d,u)=>{const h=(0,Y.Ux)("DIV",{style:"\n display: flex;\n position: relative;\n width: fit-content;\n gap: 6px;\n "});h.className="gcPriceContainer";const p=(0,Y.Ux)("p",{style:`\n font-weight: 600;\n font-size: ${c||"32px"};\n line-height: ${d||"22px"};\n color: ${a?"#008A21":r?"#DE3700":"unset"};\n margin: 0;\n `},i.toDisplay);if(p.className="gcAfterDiscountPrice",h.appendChild(p),s){const n=wp(e,"","",void 0,l);n.style.marginLeft="2px";const r=(0,Y.Ux)("DIV",{style:"\n display: flex;\n gap: 3px;\n "});n.contentElement=s.outerHTML,n.caratTopOffset="70px",n.width="160px",t.amount!==i.amount&&r.appendChild(Tp(o,t.amount,c,d,u)),r.appendChild(n),h.appendChild(r)}else t.amount!==i.amount&&h.appendChild(Tp(o,t.amount,c,d,u));return h},Tp=(e,t,i,n,o)=>{const r=new Intl.NumberFormat("en-US",{style:"currency",currency:"USD"}),a=(0,Y.Ux)("p",{style:`\n font-weight: ${o??400};\n font-size: ${i||"18px"};\n line-height: ${n||"22px"};\n display: flex;\n align-items: center;\n text-decoration-line: line-through;\n color: ${e?"#ffffff":"#7A7A7A"};\n margin: 0;\n `},r.format(t));return a.className="gcCrossedPrice",a},wp=(e,t,i,n,o,r=!1)=>{const a=(0,Y.Ux)("IMG"),s=r?"infoIconGrey.svg":"infoIcon.svg";a.src=e.common.resourcesEndpoint+"/common/"+s,a.style.width="10px",a.slot="hover-anchor",a.setAttribute("aria-label","Info icon");const l=(0,Y.Ux)("msft-shopping-tooltip");return l.className="gcTooltip",t&&(l.isTextHoverable=!0,l.content=t),n&&i&&(l.linkText=i,l.linkHandler=n),l.addEventListener("click",(e=>{e.stopPropagation()})),o&&l.addEventListener("hover",(()=>{o()})),l.append(a),l},Op=(e,t,i,n=!1)=>{const o=n?e.strings.gcWithAfterCashback:e.strings.gcEarnAfterCashback;if(t){const e=o.split("<value>");return(0,Y.Ux)("p",{style:`\n display: flex;\n margin: 0;\n font-weight: 600;\n font-size: 14px;\n line-height: 22px;\n color: ${i?"#ffffff":"#7A7A7A"};\n `},`${e[0]} ${t} ${e[1]}`)}return(0,Y.Ux)("p",{style:`\n display: flex;\n align-items: center;\n letter-spacing: -0.01em;\n color: ${i?"#ffffff":"#7A7A7A"};\n text-shadow: 0px 0px 1px rgba(0, 0, 0, 0.17);\n margin: 0;\n `},o.replace(/<value>/g,""))},Pp=(e,t,i,n,o)=>{const r=(0,Y.Ux)("DIV",{style:"\n display: flex;\n position: relative;\n width: fit-content;\n "}),a=document.createElement("DIV");a.innerHTML=kp(),a.style.marginLeft="-3px",a.style.height=`${n??20}px`,a.ariaHidden="true";const s=a.firstElementChild;if(s&&(s.style.height=`${n??20}px`),e){const n=Ap(e,"#0078D4",i,t);n.title=e,r.appendChild(n)}return r.appendChild(a),r},Ap=(e,t,i,n)=>{const o=`\n font-weight: 600;\n font-size: 24px;\n line-height: 24px;\n color: #FFFFFF;\n inset: 0px;\n display: flex;\n justify-content: center;\n height: fit-content;\n margin: auto;\n border-radius: 6px;\n white-space: nowrap;\n padding: 0px 5px;\n border-radius: 6px 0px 0px 6px;\n background-color: ${t};\n `,r=(0,Y.Ux)("div",{style:`\n display: flex;\n height: 100%;\n border-radius: 6px 0px 0px 6px;\n background-color: ${t};\n `});if(!i){const t=(0,Y.Ux)("p",{style:`\n ${o}\n ${n}\n `},e);return r.appendChild(t),r}const a=(0,be.jK)(e),s=e.replace(a,"").split("."),l=(0,Y.Ux)("p",{style:`\n ${o}\n ${n}\n `});l.setAttribute("aria-label",e);const c={style:"\n font-weight: 600;\n font-size: 14px;\n line-height: 16px;\n "};if(a){const e=(0,Y.Ux)("span",c,a);l.appendChild(e)}const d=(0,Y.Ux)("span",{style:"\n font-weight: 600;\n font-size: 22px;\n line-height: 22px;\n "},s[0]);if(l.appendChild(d),s.length>1){const e=(0,Y.Ux)("span",c,s[1]);l.appendChild(e)}return r.appendChild(l),r},Ep=(e,t,i)=>{const n=document.createElement("IMG");return n.src=e,i>0&&(n.width=i),t>0&&(n.height=t),n.style.objectFit="contain",n.addEventListener("contextmenu",(e=>{e.preventDefault()})),n},kp=()=>eh.Z.getTrustedHTML`<svg width="14" height="30" viewBox="0 0 14 30" fill="none" xmlns="http://www.w3.org/2000/svg">
<path class="tagRightPath" d="M4.96265 28.0486C4.01617 29.279 2.55188 30 0.999532 30H0V0H0.999532C2.55188 0 4.01617 0.72102 4.96265 1.95145L12.655 11.9514C14.0375 13.7487 14.0375 16.2513 12.655 18.0486L4.96265 28.0486Z" />
</svg>`,Ip=()=>eh.Z.getTrustedHTML`<svg id="closeButtonSvg" width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
<path d="M8.5332 8L12.5762 12.0488L12.0488 12.5762L8 8.5332L3.95117 12.5762L3.42383 12.0488L7.4668 8L3.42383 3.95117L3.95117 3.42383L8 7.4668L12.0488 3.42383L12.5762 3.95117L8.5332 8Z"/>
</svg>`,Dp=(e,t,i)=>{const n=(0,Y.Ux)("fluent-button");n.ariaLabel=e,n.title=e;const o=(0,Y.Ux)("DIV");return o.style.display="flex",o.style.alignContent="center",o.style.alignItems="center",o.setAttribute("aria-hidden","true"),o.innerHTML=t(),n.appearance="stealth",n.appendChild(o),i&&(o.style.width=i,o.style.height=i),n},_p=e=>(0,Y.Ux)("p",{style:"\n font-weight: 700;\n font-size: 12px;\n line-height: 16px;\n display: flex;\n align-items: center;\n letter-spacing: -0.01em;\n margin: 0;\n text-transform: uppercase;\n "},e),Np=(e,t,i,n,o,r,a,s,l)=>{const c=a?(0,Y.Ux)("a"):(0,Y.Ux)("div");if(c.id=e,a&&s&&(c.href="#",c.addEventListener("click",(e=>{e.stopPropagation(),s()})),c.style.textDecoration="none"),l){const e=()=>{l(),c.removeEventListener("mouseover",e)};c.addEventListener("mouseover",e)}const d=(0,Y.Ux)("div",{style:"\n padding: 0 16px 12px 16px;\n display: flex;\n flex-direction: column;\n margin: 0 auto;\n "});d.id=t;const u=`\n background-color: ${n?o?"unset":"#424242":"#ffffff"};\n `,h=r?`\n border: 1px solid ${n?"unset":"#F2F2F2"};\n border-radius: 6px;\n padding: 16px;\n `:"",p=(0,Y.Ux)("div",{style:`${u} ${h}`});return p.id=i,d.appendChild(p),c.appendChild(d),{rootDiv:c,wrapper:d,content:p}},Rp=(e,t,i,n=!1)=>{const o=(0,Y.Ux)("div",{style:"\n display: flex;\n flex-direction: column;\n "}),r=(0,Y.Ux)("div",{style:`\n border: 1px solid ${i?"#5E5E5E":"#F2F2F2"};\n border-radius: 6px;\n padding: 8px;\n display: flex;\n justify-content: center;\n align-items: center;\n gap: 7px;\n `}),a=(0,Y.Ux)("p",{style:"\n font-weight: 400;\n font-size: 14px;\n line-height: 20px;\n margin: 0;\n "},n?e.strings.gcInstantAddedToCartActivated:e.strings.gcPurchaseToEarn),s=(0,Y.Ux)("div");return s.innerHTML=t.getGreenCheckCircle(),s.style.display="flex",s.setAttribute("role","presentation"),s.setAttribute("aria-hidden","true"),r.appendChild(s),r.appendChild(a),o.appendChild(r),o},Mp=(e,t,i=2)=>{const n=(0,Y.Ux)("p",{style:`\n margin: 0;\n color: ${e?"#ffffff":"#1A1A1A"};\n font-weight: 400;\n font-size: 12px;\n line-height: 16px;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n display: -webkit-box !important;\n -webkit-line-clamp: ${i};\n -webkit-box-orient: vertical;\n white-space: normal;\n margin-top: 2px;\n `},t);return n.title=t,n},Lp=(e,t,i,n,o)=>{const r=t.map((e=>((t,i,n)=>{const r=(0,Y.Ux)("a",{style:`\n cursor: pointer;\n color: ${i?"#9EECFD":"#2533D4"};\n text-decoration: none;\n `});return r.textContent=t,r.href="#",r.addEventListener("click",(()=>{e.navigationFunc(),e.telemetryEvent&&o&&o.LogICSpecificTelemetry(e.telemetryEvent,`${e.linkText} clicked`,"")})),r})(e.linkText,n)));(0,T.B7)(e,i,...r)};var Bp=class extends Qu{constructor(e,t,i,n){super(),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"renderedPageType",void 0),(0,s.Z)(this,"telemetryHandler",void 0),(0,s.Z)(this,"uxUtils",void 0),(0,s.Z)(this,"moduleName",r.ModuleNames.BUYING_GUIDES),(0,s.Z)(this,"isDarkMode",!1),(0,s.Z)(this,"sectionId","buying-guides-shopping-section"),(0,s.Z)(this,"buyingGuides",[]),(0,s.Z)(this,"categoryName",void 0),this.flyoutData=e,this.uxUtils=t,this.utilities=t.viewModulesUtilities,this.telemetryHandler=t.discoverTelemetryHandler,this.pageHandlerModule=t.pageHandlerModule,this.logModule=t.logModule,this.storageHandler=t.storageHandler,this.commonAssets=i,this.stateManagement=n,this.isDarkMode=this.utilities.isDarkMode(),this.assets=new class{getStyles(){return"\n .buying-guides__containerPane {\n padding: 0px 16px;\n }\n\n .buying-guides__card {\n display: flex;\n flex-direction: column;\n gap: 8px;\n isolation: isolate;\n color: #242424;\n margin: 0;\n padding: 10px 16px 16px 16px;\n }\n\n .buying-guides__cardPane {\n border-radius: 8px;\n background: #FFFFFF;\n box-shadow: 0px 2px 4px rgba(0, 0, 0, 0.14), 0px 0px 2px rgba(0, 0, 0, 0.12);\n margin-bottom: 20px;\n }\n\n .buying-guides__guide {\n display: flex;\n flex-direction: column;\n gap: 2px;\n width: 100%;\n border-bottom: 1px solid #E0E0E0;\n }\n\n .buying-guides__guide:last-child,\n .buying-guides__guide.no-bottom {\n border-bottom: none;\n }\n\n .buying-guides__guide-title-container {\n margin-top: 13px;\n display: flex;\n justify-content: space-between;\n align-items: center;\n }\n .buying-guides__dropdown-arrow {\n border-radius: 4px;\n margin-right: -10px;\n }\n\n .buying-guides__guide[active] .buying-guides__dropdown-arrow {\n transform: rotate(180deg);\n background: #E0E0E0;\n }\n .buying-guides__dropdown-arrow::part(control) {\n background-color: transparent;\n }\n\n .buying-guides__guide[active] .buying-guides__dropdown-arrow svg>path {\n fill: #115EA3;\n }\n\n .buying-guides__guide-title {\n font-style: normal;\n font-weight: 600;\n font-size: 16px;\n line-height: 22px;\n }\n\n .buying-guides__guide-description-container {\n margin-top: 5px;\n margin-bottom: 12px;\n overflow: hidden;\n display: -webkit-box;\n -webkit-box-orient: vertical;\n -webkit-line-clamp: 1;\n }\n\n .buying-guides__guide[active] .buying-guides__guide-description-container {\n -webkit-line-clamp: unset;\n }\n\n .buying-guides__guide-description-container.multi-line {\n -webkit-line-clamp: 2;\n }\n\n .buying-guides__guide-description {\n font-style: normal;\n font-weight: 400;\n font-size: 14px;\n line-height: 20px;\n\n margin-inline: 0px;\n\n color: #111111;\n }\n\n .buying-guides__title-main {\n font-style: normal;\n font-weight: 600;\n font-size: 16px;\n line-height: 22px;\n }\n\n .buying-guides__title-pipe {\n font-style: normal;\n font-weight: 400;\n font-size: 14px;\n line-height: 20px;\n\n margin-inline: 0px;\n\n color: #111111;\n }\n\n .buying-guides__title-category {\n font-style: normal;\n font-weight: 400;\n font-size: 12px;\n line-height: 20px;\n\n margin-top: 3px;\n margin-inline: 0px;\n\n color: #111111;\n }\n\n .buying-guides__title-container {\n margin-top: 8px;\n }\n\n .buying-guides__title-pipe {\n margin: 0px 4px 0px 4px;\n }\n\n .buying-guides__title-icon svg {\n fill: #212121;\n }\n\n button.buying-guides__show-button {\n box-sizing: border-box;\n margin: 4px 6px 4px 0px;\n padding: 3px 7px;\n height: 36px;\n color: #174AE4;\n backdrop-filter: blur(120px);\n font-style: normal;\n font-weight: 600;\n font-size: 14px;\n line-height: 22px;\n font-family: 'Segoe UI Variable', 'Segoe UI';\n cursor: pointer;\n background: #FFFFFF;\n border: 1px solid #DDDDDD;\n border-radius: 20px;\n display: flex;\n align-items: center;\n justify-content: center;\n }\n\n button.buying-guides__show-button:hover {\n box-shadow: 0px 1.2px 3.6px rgba(0, 0, 0, 0.1), 0px 6.4px 14.4px rgba(0, 0, 0, 0.13);\n }\n\n button.buying-guides__show-button:active {\n background: #F5F5F5;\n box-shadow: none;\n }\n\n .buying-guides__show-button-icon {\n margin: 6px 0px 0px 10px;\n }\n\n .buying-guides__show-button-icon svg {\n fill: #212121;\n }\n\n .buying-guides__show-more-icon svg {\n transform: rotate(90deg);\n }\n\n .buying-guides__show-less-icon svg {\n transform: rotate(270deg);\n }\n\n .buying-guides__hidden {\n display: none!important;\n }\n\n .buying-guides__card > div:first-child .buying-guides__guide-title-container {\n margin-top: 0;\n }\n .buying-guides__card > div:last-child .buying-guides__guide-description-container {\n margin-bottom: 0;\n }\n "}getDarkModeStyles(){return"\n .buying-guides__card {\n color: #FFFFFF\n }\n .buying-guides__cardPane {\n background: #444444;\n box-shadow: 0px 2px 4px rgba(0, 0, 0, 0.14), 0px 0px 2px rgba(0, 0, 0, 0.12);\n }\n\n .buying-guides__guide {\n border-color: #666666;\n }\n\n .buying-guides__guide-description,\n .buying-guides__title-category,\n .buying-guides__title-pipe {\n color: currentColor;\n }\n .buying-guides__dropdown-arrow svg>path {\n fill: #D6D6D6;\n }\n .buying-guides__dropdown-arrow {\n background: none;\n }\n .buying-guides__guide[active] .buying-guides__dropdown-arrow {\n background: #2E2E2E;\n }\n .buying-guides__guide[active] .buying-guides__dropdown-arrow svg>path {\n fill: #2886DE;\n }\n .buying-guides__title-icon svg {\n fill: #ffffff;\n }\n .buying-guides__title-container {\n color: currentColor;\n }\n .buying-guides__show-button-icon svg {\n fill: #A2B7F4;\n }\n button.buying-guides__show-button {\n background-color: #343434;\n color: #A2B7F4;\n border: 1px solid #A2B7F4;\n }\n\n button.buying-guides__show-button:hover {\n background-color: #2B2B2B;\n color: #A2B7F4;\n border: 1px solid #A2B7F4;\n }\n\n button.buying-guides__show-button:active {\n background-color: #2B2B2B;\n color: #A2B7F4;\n border: 1px solid #A2B7F4;\n }\n "}}}GetModuleName(){return this.moduleName}async ShouldRenderModule(){const t=this.GetBuyingGuides();if(this.buyingGuides=t?.guides??[],this.categoryName=t?.name,this.buyingGuides.length>0){if(this.stateManagement.AddDiscoverRenderModule(r.ModuleNames.BUYING_GUIDES),e.R.isExperimentActive(f.H.discoverShopping)&&this.flyoutData.common.isDiscoverPane)return Promise.resolve(!0);if(e.R.isTestFlagActive(Zt.t.msShoppingTestExp99))return Promise.resolve(!0)}return Promise.resolve(!1)}populateMainHeader(){const e=this.flyoutData.common.shopping.querySelector("#buying-guides-shopping-section");e&&(e.slot="header-content")}async renderModule(){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());const e=(0,Y.Ux)("msft-edge-shopping-section",{id:this.sectionId,titleText:this.flyoutData.strings.bgSectionTitle,accordion:this.flyoutData.common.currentDevice===r.AS.Desktop,expanded:!0});return this.CreateUx(e),this.CreateModule(e,r.H7.BUYING_GUIDES,this.moduleName,r.$k.CONTEXTUAL,r.SV.LIST)}PostProcessing(e,t,n){const o=`position ${t}`;0===t&&this.flyoutData.common.isDiscoverPane&&this.telemetryHandler.LogEventTelemetry(i.xu.BuyingGuidesView,o,this.renderedPageType,e,{buyingGuidesCount:this.buyingGuides?.length||0},bp.r.BUYING_GUIDES)}GetBuyingGuides(){return this.flyoutData.dataStoreModule.DiscoverShoppingData?.BuyingGuideData}CreateUx(e){const t=(0,Y.Ux)("div",{className:this.withClassNamePrefix("container")}),n=(0,Y.Ux)("dl",{className:this.withClassNamePrefix("card"),title:this.flyoutData.strings.bgSectionTitle});this.flyoutData.common.isDiscoverPane||(n.classList.add(this.withClassNamePrefix("cardPane")),t.classList.add(this.withClassNamePrefix("containerPane"))),n.appendChild(this.createBuyingGuideTitle());for(const[e,{title:i,description:o}]of this.buyingGuides.entries()){const r=this.createBuyingGuideCard(i,o,t,e,e===this.buyingGuides.length-1);n.appendChild(r)}if(this.buyingGuides.length>3&&(n.appendChild(this.createBuyingGuideShowMoreButton(n)),n.appendChild(this.createBuyingGuideShowLessButton(n))),t.appendChild(n),this.flyoutData.common.isDiscoverPane){const e=()=>{const n={buyingGuideData:this.buyingGuides,buyingGuidesCount:this.buyingGuides?.length||0};this.telemetryHandler.LogEventTelemetry(i.xu.BuyingGuidesHover,"Buying Guides Hover",this.renderedPageType,this.moduleName,n,void 0,q.FV.BUYING_GUIDES),t.removeEventListener("mouseover",e)};t.addEventListener("mouseover",e)}e.appendChild(t)}createBuyingGuideShowMoreButton(e){const t=`${this.withClassNamePrefix("show-button")} ${this.withClassNamePrefix("show-more-button")}`,n=(0,Y.Ux)("button",{className:t});n.title=this.flyoutData.strings.bgShowMore,n.setAttribute("aria-label",`${this.flyoutData.strings.bgShowMore} ${this.flyoutData.strings.bgSectionTitle}`);const o=(0,Y.Ux)("span",{className:this.withClassNamePrefix("show-button")},this.flyoutData.strings.bgShowMore),r=(0,Y.Ux)("span",{className:`${this.withClassNamePrefix("show-button-icon")} ${this.withClassNamePrefix("show-more-icon")}`});return r.innerHTML=this.commonAssets.getRightChevronIcon(),n.appendChild(o),n.appendChild(r),n.addEventListener("click",(()=>{this.show(e,".buying-guides__show-less-button"),this.show(e,".buying-guides__guide-overflow"),n.classList.add(this.withClassNamePrefix("hidden")),e.querySelector(".buying-guides__guide-pre-overflow")?.classList.remove("no-bottom"),e.querySelector(".buying-guides__show-less-button")?.focus(),this.flyoutData.common.isDiscoverPane&&this.telemetryHandler.LogClickTelemetry(i.xu.BuyingGuidesClick,"Buying guide Show More button click",this.renderedPageType,this.moduleName,{buyingGuidesCount:this.buyingGuides?.length||0},q.FV.BUYING_GUIDES)})),n}createBuyingGuideShowLessButton(e){const t=`${this.withClassNamePrefix("show-button")} ${this.withClassNamePrefix("show-less-button")} ${this.withClassNamePrefix("hidden")}`,n=(0,Y.Ux)("button",{className:t});n.title=this.flyoutData.strings.bgShowLess,n.setAttribute("aria-label",`${this.flyoutData.strings.bgShowLess} ${this.flyoutData.strings.bgSectionTitle}`);const o=(0,Y.Ux)("span",{className:this.withClassNamePrefix("show-button")},this.flyoutData.strings.bgShowLess),r=(0,Y.Ux)("span",{className:`${this.withClassNamePrefix("show-button-icon")} ${this.withClassNamePrefix("show-less-icon")}`});return r.innerHTML=this.commonAssets.getRightChevronIcon(),n.appendChild(o),n.appendChild(r),n.addEventListener("click",(()=>{this.show(e,".buying-guides__show-more-button"),this.hide(e,".buying-guides__guide-overflow"),n.classList.add(this.withClassNamePrefix("hidden")),e.querySelector(".buying-guides__guide-pre-overflow")?.classList.add("no-bottom"),e.querySelector(".buying-guides__show-more-button")?.focus(),this.flyoutData.common.isDiscoverPane&&this.telemetryHandler.LogClickTelemetry(i.xu.BuyingGuidesClick,"Buying guide Show Less button click",this.renderedPageType,this.moduleName,{buyingGuidesCount:this.buyingGuides?.length||0},q.FV.BUYING_GUIDES)})),n}show(e,t){const i=e.querySelectorAll(t);i?.forEach((e=>e.classList.remove(this.withClassNamePrefix("hidden"))))}hide(e,t){const i=e.querySelectorAll(t);i?.forEach((e=>e.classList.add(this.withClassNamePrefix("hidden"))))}createBuyingGuideTitle(){const e=(0,Y.Ux)("div",{className:this.withClassNamePrefix("title-container")}),t=(0,Y.Ux)("div",{className:this.withClassNamePrefix("title-main")},this.flyoutData.strings.bgCardTitle);return e.appendChild(t),this.categoryName&&e.appendChild((0,Y.Ux)("div",{className:this.withClassNamePrefix("title-category")},this.categoryName)),e}createBuyingGuideCard(t,n,o,r,a){let s;s=2===r?`${this.withClassNamePrefix("guide")} ${this.withClassNamePrefix("guide-pre-overflow")} no-bottom`:r<2?this.withClassNamePrefix("guide"):a?`${this.withClassNamePrefix("guide")} ${this.withClassNamePrefix("guide-overflow")} ${this.withClassNamePrefix("hidden")} no-bottom`:`${this.withClassNamePrefix("guide")} ${this.withClassNamePrefix("guide-overflow")} ${this.withClassNamePrefix("hidden")}`;const l=(0,Y.Ux)("div",{className:s}),c=(0,Y.Ux)("div",{className:this.withClassNamePrefix("guide-title-container")});l.title=t,l.setAttribute("aria-label",t),l.tabIndex=0;const d=(0,Y.Ux)("dt",{className:this.withClassNamePrefix("guide-title")},t);d.role="heading",c.appendChild(d);const u=Dp(this.flyoutData.strings.bgChevronTitle,this.commonAssets.getChevronIcon);u.className=this.withClassNamePrefix("dropdown-arrow"),u.role="button",u.setAttribute("aria-pressed","false"),u.setAttribute("aria-expanded","false"),u.setAttribute("aria-label",t),c.appendChild(u),l.addEventListener("click",(()=>{const e=Array.from(o.getElementsByClassName(this.withClassNamePrefix("guide"))),t=!l.hasAttribute("active");e.forEach((e=>{e.removeAttribute("active")})),t&&l.toggleAttribute("active"),u.setAttribute("aria-pressed",t?"true":"false"),u.setAttribute("aria-expanded",t?"true":"false"),this.flyoutData.common.isDiscoverPane&&this.telemetryHandler.LogClickTelemetry(i.xu.BuyingGuidesClick,"Toggle buying guide section click",this.renderedPageType,this.moduleName,{buyingGuidesCount:this.buyingGuides?.length||0,isExpand:t},q.FV.BUYING_GUIDES)})),l.addEventListener("focus",(e=>{const t=e?.target?.querySelector(`.${this.withClassNamePrefix("dropdown-arrow")}`);t?.shadowRoot?.querySelector("button")?.setAttribute("aria-hidden","true")}));const h=(0,Y.Ux)("div",{className:this.withClassNamePrefix("guide-description-container")});e.R.isExperimentActive(f.H.buyingGuideMultiLine)&&h.classList.add("multi-line");const p=(0,Y.Ux)("dd",{className:this.withClassNamePrefix("guide-description")},n);return h.appendChild(p),l.appendChild(c),l.appendChild(h),l}withClassNamePrefix(e){return`buying-guides__${e}`}},Fp=class{getStyles(){return"\n .campaign-logo-text, .campaign-pdp-cashback-title, .campaign-merchant-banner-title {\n background: linear-gradient(89.58deg, #050F8D -0.77%, #0077D4 100%);\n -webkit-text-fill-color: transparent;\n -webkit-background-clip: text;\n }\n\n .campaign-merchant-banner {\n background: linear-gradient(271.34deg, rgba(214, 222, 255, 0.8) -0.15%, rgba(224, 234, 255, 0.8) 99.85%);\n }\n\n .campaign-merchant-banner-timer {\n color: #000;\n }\n\n .campaign-merchant-banner-title {\n border-right-color: rgba(0, 0, 0, 0.2);\n }\n\n .campaign-merchant-banner-link-text {\n color: #235CCF;\n text-decoration: none;\n }\n\n .campaign-merchant-banner:hover .campaign-merchant-banner-link-text {\n color: #235CCF;\n text-decoration: underline;\n text-decoration-color: #235CCF;\n }\n\n .campaign-banner {\n background: linear-gradient(118deg, rgba(224, 234, 255, 0.8) 0%, rgba(214, 222, 255, 0.8) 100%);\n }\n\n .campaign-shop-now-button {\n background: #2169EB;\n color: #FFF;\n }\n\n .campaign-shop-now-button:hover {\n background: #145cdd;\n cursor: pointer;\n }\n\n .campaign-feed-module {\n background: linear-gradient(180deg, rgba(214, 222, 255, 0.8) 0%, rgba(239, 250, 255, 0) 27.6%);\n margin-bottom: -10px;\n }\n\n .campaign-timer {\n border-color: #FFF;\n background-color: #FFF;\n }\n\n .campaign-timer-icon {\n background-image: url(\"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0nMTAnIGhlaWdodD0nMTEnIHZpZXdCb3g9JzAgMCAxMCAxMScgZmlsbD0nbm9uZScgeG1sbnM9J2h0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnJz48cGF0aCBkPSdNMiAwLjVDMiAwLjIyMzg1OCAyLjIyMzg2IDAgMi41IDBINi41QzYuNzc2MTQgMCA3IDAuMjIzODU4IDcgMC41QzcgMC43NzYxNDIgNi43NzYxNCAxIDYuNSAxSDIuNUMyLjIyMzg2IDEgMiAwLjc3NjE0MiAyIDAuNVpNNCA3LjVDNCA3Ljc3NjE0IDQuMjIzODYgOCA0LjUgOEM0Ljc3NjE0IDggNSA3Ljc3NjE0IDUgNy41VjQuNUM1IDQuMjIzODYgNC43NzYxNCA0IDQuNSA0QzQuMjIzODYgNCA0IDQuMjIzODYgNCA0LjVWNy41Wk00LjUgMkMyLjAxNDcyIDIgMCA0LjAxNDcyIDAgNi41QzAgOC45ODUyOCAyLjAxNDcyIDExIDQuNSAxMUM2Ljk4NTI4IDExIDkgOC45ODUyOCA5IDYuNUM5IDQuMDE0NzIgNi45ODUyOCAyIDQuNSAyWk0xIDYuNUMxIDQuNTY3IDIuNTY3IDMgNC41IDNDNi40MzMgMyA4IDQuNTY3IDggNi41QzggOC40MzMgNi40MzMgMTAgNC41IDEwQzIuNTY3IDEwIDEgOC40MzMgMSA2LjVaTTkuMTQ4MDEgMy44NTMyMkM5LjM0MzU5IDQuMDQ4MTYgOS42NjAxNyA0LjA0NzY0IDkuODU1MTEgMy44NTIwNUMxMC4wNTAxIDMuNjU2NDcgMTAuMDQ5NSAzLjMzOTg5IDkuODUzOTUgMy4xNDQ5NUw4Ljg1MjI5IDIuMTQ2NkM4LjY1NjcxIDEuOTUxNjYgOC4zNDAxMyAxLjk1MjE4IDguMTQ1MTkgMi4xNDc3N0M3Ljk1MDI1IDIuMzQzMzUgNy45NTA3NyAyLjY1OTkzIDguMTQ2MzYgMi44NTQ4N0w5LjE0ODAxIDMuODUzMjJaJyBmaWxsPScjNjE2MTYxJy8+PC9zdmc+Cg==\");\n }\n\n .campaign-timer-text {\n color: #424242;\n }\n\n .campaign-pdp-cashback-new-price {\n color: #D63600;\n }\n\n .campaign-pdp-cashback-old-price {\n color: #616161;\n }\n\n .campaign-pdp-cashback-discount-info {\n color: #707070;\n }\n\n .campaign-special-offer-icon {\n background-image: url(\"data:image/svg+xml,%3Csvg width='10' height='11' viewBox='0 0 10 11' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0 5.5C0 2.73858 2.23858 0.5 5 0.5C7.76142 0.5 10 2.73858 10 5.5C10 8.26142 7.76142 10.5 5 10.5C2.23858 10.5 0 8.26142 0 5.5ZM5 3C4.76988 3 4.58333 3.18655 4.58333 3.41667V5.08333H2.91667C2.68655 5.08333 2.5 5.26988 2.5 5.5C2.5 5.73012 2.68655 5.91667 2.91667 5.91667H4.58333V7.58333C4.58333 7.81345 4.76988 8 5 8C5.23012 8 5.41667 7.81345 5.41667 7.58333V5.91667H7.08333C7.31345 5.91667 7.5 5.73012 7.5 5.5C7.5 5.26988 7.31345 5.08333 7.08333 5.08333H5.41667V3.41667C5.41667 3.18655 5.23012 3 5 3Z' fill='%23008A21'/%3E%3C/svg%3E%0A\");\n }\n\n .campaign-special-offer-condition {\n color: #707070;\n }\n\n .campaign-banner-spacing {\n background: #f3f3f3;\n }\n "}getDarkModeStyles(){return'\n .campaign-logo-text, .campaign-pdp-cashback-title, .campaign-merchant-banner-title {\n background: unset;\n -webkit-text-fill-color: unset;\n -webkit-background-clip: unset;\n color: #FFF;\n }\n\n .campaign-merchant-banner {\n background: linear-gradient(91.34deg, #264B50 0%, #292448 100%);\n }\n\n .campaign-merchant-banner-title {\n border-right-color: #707070;\n }\n\n .campaign-merchant-banner-timer {\n color: #FFF;\n }\n\n .campaign-merchant-banner-link-text {\n color: #66CDFC;\n }\n\n .campaign-merchant-banner:hover .campaign-merchant-banner-link-text {\n color: #66CDFC;\n text-decoration-color: #66CDFC;\n }\n\n .campaign-banner {\n background: linear-gradient(118deg, #264B50 0%, #292448 100%);\n }\n\n .campaign-shop-now-button {\n background: #82DDFD;\n color: rgba(0, 0, 0, 0.898039);\n }\n\n .campaign-shop-now-button:hover {\n background: #5cd3fc;\n }\n\n .campaign-feed-module {\n background: unset;\n }\n\n .campaign-timer {\n border-color: #FFF;\n background-color: unset;\n }\n\n .campaign-timer-icon {\n background-image: url("data:image/svg+xml;base64,PHN2ZyB3aWR0aD0nMTAnIGhlaWdodD0nMTEnIHZpZXdCb3g9JzAgMCAxMCAxMScgZmlsbD0nbm9uZScgeG1sbnM9J2h0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnJz48cGF0aCBkPSdNMiAwLjVDMiAwLjIyMzg1OCAyLjIyMzg2IDAgMi41IDBINi41QzYuNzc2MTQgMCA3IDAuMjIzODU4IDcgMC41QzcgMC43NzYxNDIgNi43NzYxNCAxIDYuNSAxSDIuNUMyLjIyMzg2IDEgMiAwLjc3NjE0MiAyIDAuNVpNNCA3LjVDNCA3Ljc3NjE0IDQuMjIzODYgOCA0LjUgOEM0Ljc3NjE0IDggNSA3Ljc3NjE0IDUgNy41VjQuNUM1IDQuMjIzODYgNC43NzYxNCA0IDQuNSA0QzQuMjIzODYgNCA0IDQuMjIzODYgNCA0LjVWNy41Wk00LjUgMkMyLjAxNDcyIDIgMCA0LjAxNDcyIDAgNi41QzAgOC45ODUyOCAyLjAxNDcyIDExIDQuNSAxMUM2Ljk4NTI4IDExIDkgOC45ODUyOCA5IDYuNUM5IDQuMDE0NzIgNi45ODUyOCAyIDQuNSAyWk0xIDYuNUMxIDQuNTY3IDIuNTY3IDMgNC41IDNDNi40MzMgMyA4IDQuNTY3IDggNi41QzggOC40MzMgNi40MzMgMTAgNC41IDEwQzIuNTY3IDEwIDEgOC40MzMgMSA2LjVaTTkuMTQ4MDEgMy44NTMyMkM5LjM0MzU5IDQuMDQ4MTYgOS42NjAxNyA0LjA0NzY0IDkuODU1MTEgMy44NTIwNUMxMC4wNTAxIDMuNjU2NDcgMTAuMDQ5NSAzLjMzOTg5IDkuODUzOTUgMy4xNDQ5NUw4Ljg1MjI5IDIuMTQ2NkM4LjY1NjcxIDEuOTUxNjYgOC4zNDAxMyAxLjk1MjE4IDguMTQ1MTkgMi4xNDc3N0M3Ljk1MDI1IDIuMzQzMzUgNy45NTA3NyAyLjY1OTkzIDguMTQ2MzYgMi44NTQ4N0w5LjE0ODAxIDMuODUzMjJaJyBmaWxsPSd3aGl0ZScvPjwvc3ZnPgo=");\n }\n\n .campaign-timer-text {\n color: #FFF;\n }\n\n .campaign-pdp-cashback-new-price {\n color: #F75823;\n }\n\n .campaign-pdp-cashback-discount-info, .campaign-pdp-cashback-old-price {\n color: #BDBDBD;\n }\n\n .campaign-special-offer-icon {\n background-image: url("data:image/svg+xml;base64,PHN2ZyB3aWR0aD0nMTAnIGhlaWdodD0nMTEnIHZpZXdCb3g9JzAgMCAxMCAxMScgZmlsbD0nbm9uZScgeG1sbnM9J2h0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnJz48cGF0aCBkPSdNMCA1LjVDMCAyLjczODU4IDIuMjM4NTggMC41IDUgMC41QzcuNzYxNDIgMC41IDEwIDIuNzM4NTggMTAgNS41QzEwIDguMjYxNDIgNy43NjE0MiAxMC41IDUgMTAuNUMyLjIzODU4IDEwLjUgMCA4LjI2MTQyIDAgNS41Wk01IDNDNC43Njk4OCAzIDQuNTgzMzMgMy4xODY1NSA0LjU4MzMzIDMuNDE2NjdWNS4wODMzM0gyLjkxNjY3QzIuNjg2NTUgNS4wODMzMyAyLjUgNS4yNjk4OCAyLjUgNS41QzIuNSA1LjczMDEyIDIuNjg2NTUgNS45MTY2NyAyLjkxNjY3IDUuOTE2NjdINC41ODMzM1Y3LjU4MzMzQzQuNTgzMzMgNy44MTM0NSA0Ljc2OTg4IDggNSA4QzUuMjMwMTIgOCA1LjQxNjY3IDcuODEzNDUgNS40MTY2NyA3LjU4MzMzVjUuOTE2NjdINy4wODMzM0M3LjMxMzQ1IDUuOTE2NjcgNy41IDUuNzMwMTIgNy41IDUuNUM3LjUgNS4yNjk4OCA3LjMxMzQ1IDUuMDgzMzMgNy4wODMzMyA1LjA4MzMzSDUuNDE2NjdWMy40MTY2N0M1LjQxNjY3IDMuMTg2NTUgNS4yMzAxMiAzIDUgM1onIGZpbGw9JyMwOUU2QzMnLz48L3N2Zz4K");\n }\n\n .campaign-special-offer-condition {\n color: #BDBDBD;\n }\n\n .campaign-banner-spacing {\n background: #3b3b3b;\n }\n '}};const Up="https://www.bing.com/shop/deals?FORM=DLHEDB";function Hp(e){const t=new Date(e.getTime()-Date.now()).getTime(),i=Math.floor(t/864e5),n=Math.floor(t/36e5)%24;let o=i>0?`${i}d:`:"";if(n<10&&(o+="0"),o+=`${n}h`,i<1){const e=Math.floor(t/6e4)%60;e<10&&(o+="0"),o+=`:${e}m`}return o}function $p(e,t,i=!1){const n=i?e.dealDayTimePrefixCompact:e.dealDayTimePrefix;return(0,T.fZ)("campaignRemainingTime",n,Hp(t))}function Zp(){document.querySelectorAll(".campaign-module")?.forEach((e=>{e.remove()}))}function Vp(e,t){const i=document.createElement("DIV");i.style.display="flex",i.style.alignItems="flex-end";const n=function(e){const t=document.createElement("DIV");return t.textContent=e.dealDays,t.className="campaign-logo-text",t.style.backgroundClip="text",t.style.fontStyle="normal",t.style.fontWeight="600",t.style.fontSize="36px",t.style.lineHeight="48px",t}(e),o=function(e,t,i){const n=document.createElement("IMG");return n.setAttribute("aria-hidden","true"),n.src=e+"campaign/cartIcon.png",n.style.height="62px",n.style.width="72px",n}(t);return o.style.marginLeft="-2px",i.appendChild(n),i.appendChild(o),i}function Gp(e,t){const i=document.createElement("DIV");i.className="campaign-timer",i.style.display="flex",i.style.flexDirection="row",i.style.alignItems="center",i.style.gap="7px",i.style.padding="2px 6px",i.style.borderRadius="4px",i.style.borderWidth="1px",i.style.borderStyle="solid";const n=document.createElement("div");n.className="campaign-timer-icon",n.style.height="11px",n.style.width="10px";const o=document.createElement("DIV");o.className="campaign-timer-text",o.style.fontFamily="'Segoe UI','Roboto', Helvetica, Verdana, sans-serif",o.style.fontWeight="400",o.style.fontSize="12px",o.style.lineHeight="16px",o.textContent=$p(e,t);const r=setInterval((()=>{const i=$p(e,t);i.indexOf("00h:00m")>=0&&(Zp(),clearInterval(r)),o&&(o.textContent=i)}),1e4);return i.appendChild(n),i.appendChild(o),i}function jp(e,n,o,r,a,s){const l=new Fp;e.applyStyles(n.common.shopping,l.getStyles(),void 0,l.getDarkModeStyles());const c=document.createElement("DIV"),d=document.createElement("DIV");d.className="campaign-merchant-banner",d.style.display="flex",d.style.flexDirection="row",d.style.alignItems="center",d.style.padding="8px 16px",d.style.position="absolute",d.style.top=s?"45px":"0",d.style.left="0",d.style.right="0",d.style.borderRadius=n.common.isPane?"4px 4px 0px 0px":"0";const u=document.createElement("DIV");u.className="campaign-merchant-banner-title",u.style.fontSize="17px",u.style.lineHeight="23px",u.style.fontWeight="600",u.style.paddingRight="8px",u.style.borderRightStyle="solid",u.style.borderRightWidth="1px",u.style.marginRight="8px";const h=function(e){const t=document.createElement("DIV");return t.textContent=e.dealDays,t}(n.strings);h.style.marginBottom="2px",u.appendChild(h);const p=document.createElement("DIV");p.className="campaign-merchant-banner-timer",p.style.fontSize="14px",p.style.lineHeight="20px",p.textContent=$p(n.strings,a,s);const g=setInterval((()=>{const e=$p(n.strings,a,s);e.indexOf("00h:00m")>=0&&(Zp(),clearInterval(g)),p&&(p.textContent=e)}),1e4),f=document.createElement("DIV");f.style.flexGrow="1",f.style.textAlign="right";const m=document.createElement("span");m.className="campaign-merchant-banner-link-text",m.style.fontSize="14px",m.style.lineHeight="20px",m.style.fontWeight="400",m.style.margin="12px 0",m.textContent=s?n.strings.dealDaysAllDeals:n.strings.dealDaysSeeAllDeals,f.appendChild(m),d.appendChild(u),d.appendChild(p),d.appendChild(f);const v=document.createElement("a");v.href=Up;const y=e=>{e.preventDefault(),e.stopPropagation();const t=new W.Z(i.$S.CampaignCashbackBanner,bp.r.CAMPAIGN_BANNER);r.LogInfoEvent(i.R.ButtonClick,"User clicked deal days merchant notification banner",t),o.RecordAsUserEngagement(q.FV.CAMPAIGN_CASHBACK_BANNER,n.common.popupOrigination),o.NavigateToUrl(Up)};v.addEventListener("click",y),v.addEventListener("keypress",(e=>{"Enter"===e.key&&y(e)})),v.appendChild(d);const C=document.createElement("DIV");C.style.height="36px",C.style.width="100%",c.appendChild(v),c.appendChild(C);const b=new t.Z(i.xu.CampaignCashbackBannerRendered);return r.LogInfoEvent(i.R.EdgeFlyoutStatus,"Deal Days rendered in merchant cashback banner",b),c}function zp(e,t){const i=document.createElement("DIV");i.style.marginTop="8px",i.style.display="flex",i.style.gap="3px",i.style.alignItems="center";const n=document.createElement("DIV");n.style.display="inline-block",n.className="campaign-special-offer-icon",n.style.height="11px",n.style.width="10px",n.style.marginTop="1px";const o=document.createElement("SPAN");o.innerText=e+" ",o.className="campaign-special-offer-amount",o.style.fontWeight="600",o.style.fontSize="12px",o.style.lineHeight="17px";const r=document.createElement("SPAN");r.innerText=t,r.className="campaign-special-offer-condition",r.style.fontSize="12px",r.style.lineHeight="17px";const a=document.createElement("DIV");return a.style.lineHeight="14px",a.appendChild(o),a.appendChild(r),i.appendChild(n),i.appendChild(a),i}var Wp=class extends Qu{constructor(e,t){super(),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"divWrapper",void 0),(0,s.Z)(this,"spacing",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),this.flyoutData=e,this.utilities=t.viewModulesUtilities,this.logModule=t.logModule,this.pageHandlerModule=t.pageHandlerModule,this.telemetryUtilities=t.telemetryHandler,this.assets=new Fp}GetModuleName(){return r.ModuleNames.CAMPAIGN_BANNER}ShouldRenderModule(){return Promise.resolve(this.flyoutData.common.isPane&&!!this.flyoutData.dataStoreModule.CampaignData?.expData.isCampaignActive())}async renderModule(){if(!this.flyoutData.dataStoreModule.CampaignData)return Promise.resolve(null);this.divWrapper=document.createElement("DIV"),this.divWrapper.className="campaign-module",this.spacing=document.createElement("DIV"),this.spacing.className="campaign-banner-spacing",this.spacing.style.height="20px",this.spacing.style.width="100%";const e=document.createElement("DIV");e.className="campaign-banner",e.style.padding="12px 16px 16px 16px",e.style.borderRadius="8px";const t=Vp(this.flyoutData.strings,this.flyoutData.common.resourcesEndpoint),n=document.createElement("DIV");n.textContent=this.flyoutData.strings.dealDaysDetailsText,n.style.marginTop="8px",n.style.fontSize="16px",n.style.lineHeight="22px";const o=document.createElement("DIV");o.style.display="flex",o.style.justifyContent="space-between",o.style.flexDirection="row",o.style.alignItems="flex-end",o.style.marginTop="20px";const a=document.createElement("button");a.className="campaign-shop-now-button",a.textContent="Shop now",a.style.fontWeight="600",a.style.fontSize="14px",a.style.lineHeight="20px",a.style.border="none",a.style.padding="7px 12px",a.style.borderRadius="4px",a.addEventListener("click",(()=>{this.pageHandlerModule.NavigateToUrl(Up);const e=new W.Z(i.$S.CampaignShopNowPaneButton,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"Deal Days shop now button clicked in pane banner",e),this.pageHandlerModule.RecordAsUserEngagement(q.FV.CAMPAIGN_SHOP_NOW_BANNER_BUTTON_CLICK,this.flyoutData.common.popupOrigination)})),o.appendChild(a);const s=this.flyoutData.dataStoreModule.CampaignData.expData.endTime;if(s){const e=Gp(this.flyoutData.strings,s);o.appendChild(e)}e.appendChild(t),e.appendChild(n),e.appendChild(o),this.utilities.applyStyles(this.divWrapper,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),this.divWrapper.appendChild(this.spacing),this.divWrapper.appendChild(e);const l=this.CreateModule(this.divWrapper,r.H7.CAMPAIGN_BANNER,r.ModuleNames.CAMPAIGN_BANNER,r.$k.CONTEXTUAL,r.SV.BLOCK);return Promise.resolve(l)}populateMainHeader(){this.divWrapper&&(this.spacing.style.height="0",this.divWrapper.parentElement?.classList.add("no-padding-header"),this.divWrapper.slot="header-content")}PostProcessing(e,t,i){}};class Kp extends V.Z{constructor(e,t,i,n,o,r,a,l,c,d,u,h,p){super(),(0,s.Z)(this,"CashbackCategory",void 0),(0,s.Z)(this,"CashbackCommissionType",void 0),(0,s.Z)(this,"CashbackCommissionValue",void 0),(0,s.Z)(this,"Domain",void 0),(0,s.Z)(this,"AffiliateNetworkName",void 0),(0,s.Z)(this,"Profile",void 0),(0,s.Z)(this,"IsRebatesUser",void 0),(0,s.Z)(this,"IsRebatesSupportedDomain",void 0),(0,s.Z)(this,"IsSignInSupportedDomain",void 0),(0,s.Z)(this,"MerchantFullName",void 0),(0,s.Z)(this,"ButtonPosition",void 0),(0,s.Z)(this,"FlyoutId",void 0),(0,s.Z)(this,"IsEstimatedCashback",void 0),(0,s.Z)(this,"PageType",void 0),this.CashbackCategory=e??"",this.CashbackCommissionType=t??"",this.CashbackCommissionValue=i??"",this.Domain=n??"",this.AffiliateNetworkName=o??"",this.Profile=r??"",this.IsRebatesUser=a,this.IsRebatesSupportedDomain=l??"",this.IsSignInSupportedDomain=c??!1,this.MerchantFullName=d??"",this.ButtonPosition=u??"",this.IsEstimatedCashback=h??!1,this.PageType=p??""}}var qp=Kp;class Yp extends V.Z{constructor(e,t,i,n){super(),(0,s.Z)(this,"Points",void 0),(0,s.Z)(this,"MaxPointsLimitPerDomainPerDay",void 0),(0,s.Z)(this,"Domain",void 0),(0,s.Z)(this,"TotalMaxPointsLimitPerDay",void 0),this.Points=e,this.MaxPointsLimitPerDomainPerDay=t,this.Domain=i,this.TotalMaxPointsLimitPerDay=n}}var Xp=Yp,Jp=o(54380),Qp=class{getStyles(){return"\n .icTextContainer {\n display: flex;\n flex-direction: column;\n width: 100%;\n color: #222222;\n gap: 2px;\n margin-bottom: 16px;\n margin-top: 12px;\n }\n .icPercentOff {\n position: absolute;\n }\n #activatedIcon {\n display: inline-flex;\n column-gap: 6px;\n box-sizing: border-box;\n border: 1px solid rgb(235, 235, 235);\n border-radius: 4px;\n height: 38px;\n align-items: center;\n justify-content: center;\n margin-top: 8px;\n margin-left: auto;\n margin-right: auto;\n width: 100%;\n }\n .adsIconContainer {\n display: flex;\n gap: 6px;\n }\n .adsIcon {\n display: flex;\n border: 1px solid #737373;\n margin: 0;\n font-weight: 600;\n font-size: 10px;\n line-height: 14px;\n color: #737373;\n padding: 0 5px;\n border-radius: 4px;\n }\n .icCashbackValueText {\n font-weight: 700;\n font-size: 32px;\n line-height: 43px;\n display: flex;\n align-items: center;\n color: #008A21;\n margin: 0;\n }\n .icCashbackText {\n font-weight: 700;\n font-size: 18px;\n line-height: 22px;\n color: #008A21;\n margin: 0;\n }\n .icCashbackContainer {\n display: flex;\n align-items: baseline;\n gap: 7px;\n }\n .icImageContainerWrapper {\n display: flex;\n justify-content: right;\n align-items: center;\n width: 30%;\n padding: 2px;\n background-color: white;\n border-radius: 8px;\n width: fit-content;\n }\n .icImageContainer {\n border-radius: 8px;\n }\n .icTextAndImageContainer {\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n }\n .divider {\n width: 100%;\n border-top: 1px solid #EBEBEB;\n padding-right: 16px;\n padding-left: 16px;\n }\n .icActionButton {\n border-radius: 4px;\n height: 32px;\n font-size: 14px;\n font-weight: 400;\n width: 100%;\n }\n .icSeeMoreOffersButton {\n font-weight: 600;\n font-size: 14px;\n line-height: 20px;\n color: #036AC4;\n background-color: transparent;\n display: flex;\n width: fit-content;\n margin: 8px auto 0 auto;\n height: auto;\n }\n .asLink::part(control) {\n border: unset;\n }\n .icDescriptionText {\n margin: 0 !important;\n color: #464646 !important;\n }\n .icDescriptionTextGridCard {\n color: var(--text-neutral-foreground-hint) !important;\n }\n .icAfterText {\n margin: 0;\n font-weight: 400;\n font-size: 12px;\n line-height: 16px;\n display: flex;\n align-items: center;\n }\n .isSponsoredIconContainer {\n display: flex;\n gap: 3px;\n justify-content: end;\n margin-bottom: 10px;\n margin-top: -10px;\n }\n .icSponsoredContainer {\n display: flex;\n align-items: center;\n justify-content: end;\n gap: 6px;\n margin-top: 9px;\n width: 100%;\n }\n .icSponsoredText {\n font-weight: 400;\n font-size: 10px;\n line-height: 12px;\n display: flex;\n align-items: center;\n color: var(--text-neutral-foreground);\n margin: 0;\n }\n .icPriceContainer {\n display: flex;\n position: relative;\n width: fit-content;\n gap: 6px;\n margin: 5px 0 2px 0;\n align-items: baseline;\n }\n .icPriceContainerMainPrice {\n margin: 0;\n font-weight: 700;\n font-size: 16px;\n line-height: 22px;\n display: flex;\n align-items: center;\n color: #D63600;\n }\n .icPriceContainerCrossedPrice {\n font-weight: 400;\n font-size: 12px;\n line-height: 16px;\n display: flex;\n align-items: center;\n text-decoration-line: line-through;\n color: var(--text-neutral-foreground-hint);\n margin: 0;\n }\n .icSubTitle {\n margin: 0 0 10px 0;\n padding: 0 20px;\n }\n .icSubtitleQuery {\n font-weight: 700;\n }\n .searchTitleContainer {\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n margin: 10px 0;\n }\n .searchTitleText {\n font-size: 18px;\n line-height: 24px;\n font-weight: 600;\n margin: 0;\n }\n .searchTitleContainer .isSponsoredIconContainer {\n margin: 0;\n }\n .loader {\n border: 6px solid #f3f3f3; /* Light grey */\n border-top: 6px solid #3498db; /* Blue */\n border-radius: 100%;\n width: 30px;\n height: 30px;\n animation: spin 2s linear infinite;\n }\n @keyframes spin {\n 0% { transform: rotate(0deg); }\n 100% { transform: rotate(360deg); }\n }\n "}getVariantAutoActivate(){return"\n #divContentWrapper {\n width: 280px !important;\n }\n .priceIcon {\n position: absolute;\n width: 48px;\n height: 18px;\n left: 0px;\n bottom: 3px;\n background: #FFFFFF;\n box-shadow: 0px 1px 1px rgba(0, 0, 0, 0.07);\n border-radius: 4px;\n }\n .priceText {\n position: absolute;\n width: 35px;\n height: 12px;\n left: 4px;\n top: 2px;\n font-style: normal;\n font-weight: 600;\n font-size: 12px;\n line-height: 12px;\n color: #000000;\n }\n .icDescriptionTextGridCard {\n color: var(--text-neutral-foreground-hint) !important;\n height: 16px;\n text-overflow: ellipsis;\n white-space: nowrap !important;\n display: block !important;\n overflow: hidden;\n width:142px;\n margin: 0;\n font-weight: 400;\n font-size: 12px;\n line-height: 16px;\n overflow: hidden;\n white-space: normal;\n margin-top: 2px;\n }\n .infoIcon {\n width: 10px;\n height: 10px;\n position: relative;\n padding-left: 3px;\n padding-bottom: 7px;\n }\n .divCommissionValue {\n display: inline-block;\n margin: 0px;\n vertical-align: text-bottom;\n }\n .spanCommissionValue {\n display: flex;\n justify-content: center;\n align-items: center;\n height: 28px;\n line-height: 22px;\n font-size: 20px;\n background: #3267FA;\n border-radius: 6px 0px 0px 6px;\n color: #fff;\n font-weight: 500;\n float: left;\n padding: 0px 1px 0px 6px;\n margin-right: -1px;\n }\n .spanCommissionValueSmall {\n display: flex;\n justify-content: center;\n align-items: center;\n height: 20px;\n line-height: 16px;\n font-size: 12px;\n background: #3267FA;\n border-radius: 4px 0px 0px 4px;\n color: #fff;\n font-weight: 400;\n float: left;\n padding: 0px 2px 0px 4px;\n margin-right: -1px;\n }\n .adsIcon {\n color: #000000;\n padding: 0px 4px 1px 4px;\n border: 1px solid rgba(209, 209, 209, 1);\n }\n .icCashbackContainer {\n flex-direction: column;\n }\n .icCashbackText {\n font-size: 20px;\n line-height: 22px;\n font-style: normal;\n font-weight: 600;\n /* Neutral foreground/neutralForegroundRest */\n color: #1A1A1A;\n margin-top: 3px;\n }\n img.icImageContainer {\n width: 94px;\n height: 100px;\n }\n .icTextAndImageContainer {\n flex-direction: row;\n margin-bottom: 18px;\n margin-top: 16px;\n gap: 7px;\n height:100px;\n }\n .icCashbackContainer {\n gap: 2px;\n }\n .gcMainContentSpbCard {\n background-color: #ffffff;\n }\n .icAddToCartSpbBtn {\n width: 100% !important;\n }\n div.header {\n display: none;\n }\n ::part(sections) {\n position: relative;\n margin-top: 0px;\n padding: 0px;\n }\n msft-edge-shopping::part(header) {\n margin-top: 0px !important;\n margin-bottom: 0px !important;\n }\n p.icMessageText {\n height: 12px;\n margin-top: 7px;\n }\n msft-edge-shopping::part(footer){\n padding: 0.1rem;\n margin-top: 0px;\n display: flex;\n flex-direction: column;\n }\n #footerDiv {\n margin-bottom: 13px !important;\n }\n "}getVariant2Styles(){return"\n .icCashbackContainer {\n flex-direction: column;\n }\n .icCashbackText {\n font-size: 20px;\n line-height: 22px;\n color: var(--text-normal);\n }\n .icTextAndImageContainer {\n flex-direction: row;\n margin-bottom: 18px;\n gap: 7px;\n }\n .icCashbackContainer {\n gap: 2px;\n }\n .gcMainContentSpbCard {\n background-color: #ffffff;\n }\n .icAddToCartSpbBtn {\n width: 100% !important;\n }\n "}getVariant6Styles(){return"\n .icCashbackContainer {\n flex-direction: column;\n align-items: center;\n justify-content: center;\n gap: 2px !important;\n }\n .icCashbackText {\n font-size: 12px !important;\n line-height: 17px !important;\n font-weight: 400 !important;\n color: var(--text-normal) !important;\n }\n .icCashbackSaveText {\n font-size: 19px;\n line-height: 19px;\n font-weight: 600;\n margin-bottom: 0;\n color: var(--text-normal);\n }\n .icTextAndImageContainer {\n flex-direction: row !important;\n margin-bottom: 18px;\n gap: 7px;\n }\n .gcMainContentSpbCard {\n background-color: #ffffff;\n }\n .icCashbackAdsHeaderContainer{\n width: 100%;\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n align-items: center;\n margin-bottom: 5px;\n }\n .icCashbackAdsHeaderTextContainer{\n font-size: 12px;\n line-height: 17px;\n font-weight: 400;\n color: var(--text-normal);\n }\n .icCashbackDomainNameSpan {\n font-weight: 600;\n text-transform: capitalize;\n }\n .adsIconContainer {\n display: block !important;\n }\n .icNotificationDescriptionText {\n font-size: 12px !important;\n line-height: 12px !important;\n font-weight: 600 !important;\n color: var(--text-normal) !important;\n margin-bottom: 8px !important;\n }\n .icPercentOff {\n top: 27px;\n }\n "}getVariant6DarkModeStyles(){return"\n .icCashbackContainer {\n flex-direction: column;\n align-items: center;\n justify-content: center;\n gap: 2px !important;\n }\n .icCashbackText {\n font-size: 12px !important;\n line-height: 17px !important;\n font-weight: 400 !important;\n color: color: #ffffff; !important;\n }\n .icCashbackSaveText {\n font-size: 19px;\n line-height: 19px;\n font-weight: 600;\n margin-bottom: 0;\n color: color: #ffffff;;\n }\n .icTextAndImageContainer {\n flex-direction: row !important;\n margin-bottom: 18px;\n gap: 7px;\n }\n .gcMainContentSpbCard {\n background-color: #424242;\n }\n .icCashbackAdsHeaderContainer{\n width: 100%;\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n align-items: center;\n margin-bottom: 5px;\n }\n .icCashbackAdsHeaderTextContainer{\n font-size: 12px;\n line-height: 17px;\n font-weight: 400;\n color: color: #ffffff;;\n }\n .icCashbackDomainNameSpan {\n font-weight: 600;\n text-transform: capitalize;\n }\n .adsIconContainer {\n display: block !important;\n }\n .icNotificationDescriptionText {\n font-size: 12px !important;\n line-height: 12px !important;\n font-weight: 600 !important;\n color: color: #ffffff; !important;\n margin-bottom: 8px !important;\n }\n .icPercentOff {\n top: 27px;\n }\n "}getActivatedStyles(){return"\n .textAndImageContainerActivated {\n display: flex;\n width: 100%;\n margin-bottom: 4px;\n }\n .textContainerActivated {\n display: flex;\n flex-direction: column;\n width: 50%;\n }\n .cashBackTextActivated {\n font-style: normal;\n font-weight: 600;\n font-size: 16px;\n line-height: 22px;\n margin: 0 0 8px 0;\n }\n .forYouTextActivated {\n background: #1A1A1A;\n border-radius: 3px;\n letter-spacing: -0.01em;\n font-style: normal;\n font-weight: 700;\n font-size: 10px;\n line-height: 16px;\n color: #FFFFFF;\n text-shadow: 0px 0px 1px rgba(0, 0, 0, 0.17);\n margin: 8px 0 0 0;\n padding: 5px 4px;\n width: fit-content;\n }\n .expirationDateDivActivated {\n font-weight: 400;\n font-size: 14px;\n line-height: 20px;\n text-align: center;\n text-transform: capitalize;\n margin-top: 4px;\n padding: 4px 0;\n }\n "}getVariant3Styles(){return"\n #gcMainContentSpbCard {\n text-align: center;\n }\n #gcMainRootSpbCard {\n margin-top: -10px;\n }\n .icFoundCashbackText {\n font-weight: 600;\n font-size: 18px;\n line-height: 30px;\n text-align: center;\n margin: 0 0 15px 0;\n display: inline-flex;\n justify-content: center;\n align-items: center;\n gap: 4px;\n }\n .icFoundCashbackTextCount {\n color: #036EC9;\n font-weight: 700;\n }\n .icSeeMoreOffersButton {\n width: 100%;\n font-weight: 400;\n font-size: 14px;\n line-height: 20px;\n }\n .divCommissionValue {\n display: inline-flex;\n justify-content: center;\n align-items: center;\n margin: 0px;\n }\n .divCommissionValue .spanCommissionValue {\n background: #036AC4;\n color: #ffffff;\n height: 24px;\n display: flex;\n justify-content: center;\n align-items: center;\n }\n "}getVariant5Styles(){return"\n .icFinalPrice {\n font-weight: 600;\n font-size: 32px;\n line-height: 43px;\n color: #DE3700;\n margin: 0;\n }\n .icListPrice {\n font-weight: 400;\n font-size: 18px;\n line-height: 22px;\n text-decoration-line: line-through;\n color: var(--text-neutral-foreground);\n margin: 0;\n }\n .icPercentOffText {\n font-weight: 400;\n font-size: 18px;\n line-height: 22px;\n color: var(--text-neutral-foreground);\n margin: 0;\n }\n .icCashbackContainer {\n display: flex;\n flex-wrap: nowrap;\n }\n .icTextContainer {\n margin-bottom: 12px;\n gap: 0;\n }\n .icDescriptionText {\n margin-top: 10px !important;\n }\n "}getVariant2DarkModeStyles(){return"\n .gcMainContentSpbCard {\n background-color: #424242;\n }\n "}getDarkModeStyles(){return"\n .icPercentOffText,\n .icListPrice,\n .icSeeMoreOffersButton,\n .icSponsoredText,\n .adsIcon,\n .icTextContainer {\n color: #ffffff;\n }\n\n .icDescriptionText,\n .icDescriptionTextGridCard {\n color: #ffffff !important;\n height: 16px;\n }\n\n .icFoundCashbackTextCount {\n color: #6FAFE2;\n }\n "}getSanConsentPaneAssets(){return"\n .icSanConsentRootDiv {\n background-color: #FFFFFF;\n margin: 0 20px;\n border-radius: 8px;\n padding: 16px;\n }\n .sanConsentButton {\n width: 100% !important;\n background-color: #036AC4;\n border-radius: 4px;\n }\n .sanConsentHeaderTopTextActivated {\n font-size: 15px !important;\n line-height: 18px !important;\n }\n "}getSanConsentPaneAssetsDarkMode(){return"\n .icSanConsentRootDiv {\n background-color: rgb(66, 66, 66);\n }\n .sanConsentButton {\n background-color: #82DDFD;\n\n }\n "}getSanConsentNotificationAssets(){return"\n .icSanConsentRootDiv {\n padding: 0 16px;\n margin-top: -20px;\n }\n .sanConsentButton {\n width: 100% !important;\n background: #036AC4;\n border-radius: 4px;\n }\n #sanConsentHeaderBottomText {\n font-weight: 600;\n font-size: 16px;\n line-height: 20px;\n }\n #sanConsentHeaderContent {\n width: 100%;\n }\n .sanConsentBodyText {\n font-weight: 400;\n font-size: 12px;\n line-height: 16px;\n margin: 0;\n }\n #sanConsentHeaderTopText {\n font-weight: 400;\n font-size: 14px;\n line-height: 20px;\n margin-bottom: 4px;\n }\n "}getConfirmationPageAssets(){return"\n #gcMainContent {\n background-color: rgb(255, 255, 255);\n border: unset;\n border-radius: 6px;\n padding: 16px;\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n }\n .earningText {\n font-weight: 600;\n font-size: 16px;\n line-height: 20px;\n text-align: center;\n margin: 0;\n margin-bottom: 11px;\n }\n .cashbackContainer {\n display: flex;\n }\n .emailContainer {\n display: flex;\n gap: 8px;\n align-items: center;\n }\n .emailIconContainer {\n min-width: 40px;\n height: 40px;\n background: rgba(0, 0, 0, 0.03);\n border-radius: 8px;\n display: flex;\n justify-content: center;\n align-items: center;\n margin: 15px 0;\n }\n .emailText {\n font-weight: 400;\n font-size: 12px;\n line-height: 18px;\n margin: 0;\n }\n .disclaimerContainer {\n font-weight: 400;\n font-size: 10px;\n line-height: 14px;\n text-align: center;\n }\n @media (-ms-high-contrast: active) {\n .gcCouponContainer svg path {\n fill: transparent !important;\n }\n }\n "}getConfirmationPageAssetsDarkMode(){return"\n #gcMainContent {\n background-color: #424242;\n }\n .imageIcon svg path {\n fill: #ffffff;\n }\n "}getSecondaryOfferStyles(){return"\n .icSecOfferContainer {\n display: flex;\n flex-direction: row;\n width: 100%;\n color: #222222;\n gap: 2px;\n margin-bottom: 16px;\n margin-top: 12px;\n cursor: pointer;\n }\n .icSecOfferTextContainer {\n display: flex;\n flex-direction: column;\n width: 100%;\n color: #222222;\n gap: 2px;\n margin-bottom: 16px;\n margin-top: 12px;\n }\n .icSecOfferValueTextContainer {\n display: flex;\n flex-direction: row;\n width: 100%;\n gap: 8px;\n }\n .icSecOfferCashbackValueText {\n font-weight: 400;\n font-size: 16px;\n line-height: 22px;\n display: flex;\n align-items: center;\n color: #18AB6E;\n margin: 0;\n }\n .icSecOfferImage {\n min-width: 84px;\n max-width: 84px;\n min-height: 84px;\n max-height: 84px;\n border-radius: 8px;\n }\n .icSecOfferCashbackText {\n font-weight: 400;\n font-size: 12px;\n line-height: 17px;\n display: flex;\n align-items: center;\n color: #464646;\n margin: 0;\n }\n "}getSecondaryOfferDarkModeStyles(){return"\n .icSecOfferContainer {\n display: flex;\n flex-direction: row;\n width: 100%;\n color: #ffffff;;\n gap: 2px;\n margin-bottom: 16px;\n margin-top: 12px;\n cursor: pointer;\n }\n .icSecOfferTextContainer {\n display: flex;\n flex-direction: column;\n width: 100%;\n color: #ffffff;\n gap: 2px;\n margin-bottom: 16px;\n margin-top: 12px;\n }\n .icSecOfferValueTextContainer {\n display: flex;\n flex-direction: row;\n width: 100%;\n gap: 8px;\n }\n .icSecOfferCashbackValueText {\n font-weight: 400;\n font-size: 16px;\n line-height: 22px;\n display: flex;\n align-items: center;\n color: #18AB6E;\n margin: 0;\n }\n .icSecOfferImage {\n min-width: 84px;\n max-width: 84px;\n min-height: 84px;\n max-height: 84px;\n border-radius: 8px;\n }\n .icSecOfferCashbackText {\n font-weight: 400;\n font-size: 12px;\n line-height: 17px;\n display: flex;\n align-items: center;\n color: #ffffff;\n margin: 0;\n }\n "}getAdsDisclaimerAssets(){return"\n .adsDisclaimerContainer {\n font-weight: 400;\n font-size: 12px;\n line-height: 14px;\n margin: 0;\n padding: 0px 2px 10px 2px;\n width: 245px;\n }\n #gcTooltipIcon::part(control) {\n padding: 0;\n width: 20px;\n max-width: 20px;\n background-color: transparent;\n }\n "}getSearchBarAssets(){return"\n .icSearchBarContainer {\n margin: 0px 20px 15px 20px;\n display: flex;\n position: relative;\n overflow: hidden;\n border-radius: 99px;\n height: 32px;\n border: 1px solid #D6D6D6;\n }\n .icSearchBar {\n background-color: #FFFFFF;\n border-radius: 99px;\n padding: 6px 6px 6px 42px;\n flex: 1;\n display: flex;\n border: unset;\n overflow: hidden;\n }\n .icClearIcon {\n position: absolute;\n right: 1px;\n top: 1px;\n bottom: 1px;\n border-radius: 99px;\n height:29px;\n background-color: transparent;\n }\n .icSearchIcon {\n position: absolute;\n left: 1px;\n top: 1px;\n bottom: 1px;\n border-radius: 99px;\n height:29px;\n background-color: transparent;\n }\n "}getSearchBarDarkModeAssets(){return"\n "}},eg=o(93078),tg=class{getStyles(){return'\n #divErrorCashbackActivation {\n display: grid;\n margin-bottom: 5px;\n grid-template-columns: auto auto;\n grid-gap: 10px;\n justify-content: center;\n background-color: var(--fill-color)!important;\n width: 100%;\n }\n #divCashBackPopup {\n display: flex;\n flex-direction: column;\n text-align: center;\n justify-content: center;\n }\n #divCashBackCategoriesPopup {\n display: flex;\n flex-direction: column;\n text-align: center;\n justify-content: center;\n background-color: var(--fill-color);\n border-radius: 8px;\n }\n #cashBackSection.region {\n background-color: unset!important;\n }\n\n #cbTooltip {\n display: inline-block;\n vertical-align: top;\n white-space: initial;\n margin-left: 1px;\n }\n #divCashBackTitle {\n align-items: center;\n display: flex;\n flex-direction: column;\n width: calc(100% - 20px);\n }\n #divMerchantInfo {\n column-gap: 5px;\n font-size: 14px;\n display: inline-flex;\n }\n #txtMerchantInfo {\n position: relative;\n margin-top: 0px;\n margin-bottom: 0px;\n }\n #onTxtMerchantInfo {\n position: relative;\n margin-top: 0px;\n margin-bottom: 0px;\n }\n #divMerchantIcon {\n display: flex;\n justify-content: center;\n align-items: center;\n }\n #imgMerchantIcon {\n max-height: 16px;\n max-width: 16px;\n }\n #txtSubtitleCb {\n font-weight: 400;\n margin: 5px 27px;\n font-size: 12px;\n }\n #divWrapperPcb {\n width: -webkit-fill-available;\n margin-left: 16px;\n margin-right: 16px;\n margin-bottom: 5px;\n }\n #divContentPcb {\n display: grid;\n grid-template-columns: 50% 50%;\n height: 100px;\n }\n #divInfoPcb {\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n row-gap: 7px;\n }\n #txtTitlePcb {\n font-size: 16px;\n line-height: 22px;\n font-weight: 600;\n }\n #divForYouPcb {\n display: flex;\n flex-direction: row;\n justify-content: center;\n align-items: center;\n padding: 0px 6px 1px;\n gap: 6px;\n width: 43px;\n background: #1A1A1A;\n border-radius: 3px;\n color: #FFFFFF;\n }\n #txtForYouPcb {\n line-height: 16px;\n font-size: 10px;\n font-weight: 700;\n display: flex;\n align-items: center;\n letter-spacing: -0.01em;\n text-shadow: rgb(0 0 0 / 17%) 0px 0px 1px;\n }\n #divCIPcb {\n border-radius: 4px;\n border: 1px solid var(--stroke-neutral-1-rest, rgba(0, 0, 0, 0.18));\n border: 1px solid var(--stroke-neutral-1-rest, color(display-p3 0 0 0 / 0.18));\n background: var(--acrylic-light, rgba(255, 255, 255, 0.77));\n background: var(--acrylic-light, color(display-p3 1 1 1 / 0.77));\n display: flex;\n padding: var(--Corner-Radius-Control-Regular, 4px) 8px 5px 6px;\n align-items: center;\n gap: var(--corner-radius-control-regular, 4px);\n width: fit-content;\n height: auto;\n margin-bottom: 8px;\n margin-top: -8px;\n }\n #txtCIPcb {\n color: var(--foreground-neutral-2-rest, rgba(0, 0, 0, 0.74));\n font-size: 12px;\n font-style: normal;\n font-weight: 600;\n line-height: 14px;\n }\n #ciIcon{\n display: flex;\n }\n #dividerPcb {\n width: 100%;\n height: 1px;\n background: rgb(235, 235, 235);\n }\n #dividerHeader {\n width: 100%;\n height: 1px;\n background: rgb(235, 235, 235);\n margin-bottom: 30px;\n margin-top: 2px;\n }\n #divExpWrapperPcb {\n display: inline-flex;\n font-weight: 400;\n font-size: 14px;\n line-height: 20px;\n margin-top: 10px;\n }\n #divEnabledPcb {\n display: inline-flex;\n column-gap: 6px;\n box-sizing: border-box;\n border: 1px solid rgb(235, 235, 235);\n border-radius: 4px;\n height: 38px;\n align-items: center;\n justify-content: center;\n margin-top: 8px;\n }\n #divPrivacyMessage {\n font-size: 10px;\n line-height: 14px;\n margin-top: 12px;\n }\n #divPrivacyMessage.smallStyles {\n margin-bottom: 5px;\n margin-left: 16px;\n margin-right: 16px;\n margin-top: 16px;\n text-align: center;\n width: 95%;\n }\n .aLinkCb {\n font-size: 10px;\n line-height: 14px;\n position: relative;\n height: 14px;\n vertical-align: bottom;\n align-self: center;\n }\n .aLinkCb::part(control) {\n padding: 2px 0px 2px 0px !important;\n }\n .aLinkCbenroll {\n font-size: 14px;\n line-height: 14px;\n position: relative;\n height: 10px;\n align-self: center;\n bottom: 4px;\n }\n\n .wrappedText {\n white-space: nowrap;\n }\n .wrappedTextLong {\n white-space: nowrap;\n text-wrap: balance;\n display: block;\n max-width: 100%;\n width: fit-content;\n }\n\n .h2RebatesTitlev2 {\n display: flex !important;\n flex-wrap: wrap;\n column-gap: 4px;\n justify-content: center;\n align-items: center;\n }\n\n .btnWrapper {\n max-width: 100%;\n width: 100%;\n box-sizing: border-box;\n }\n .btnWrapper .btnPrimary {\n width: 100% !important;\n min-width: 100%;\n max-width: 100%;\n }\n .btnWrapper .btnPrimary::part(control) {\n width: 100% !important;\n min-width: 100%;\n max-width: 100%;\n padding: 4px 16px;\n }\n .btnWrapper .btnPrimary::part(content) {\n overflow: hidden;\n text-overflow: ellipsis;\n }\n\n #previousCashbackSection {\n margin-top: 4px;\n display: flex;\n flex-direction: column;\n }\n #divPreviousCashBack {\n display: grid;\n box-sizing: border-box;\n justify-content: center;\n grid-template-columns: 55% 45%;\n }\n #btnPreviousCashBack {\n min-height: 64px;\n height: auto;\n padding: 12px;\n margin-bottom: 10px;\n background: linear-gradient(90deg, rgba(221, 235, 255, 0.3) 0%, rgba(233, 251, 255, 0.3) 30.73%, rgba(255, 249, 217, 0.3) 100%);\n cursor: pointer;\n border: 1px solid rgba(0, 0, 0, 0.03);\n border-radius: 8px;\n box-sizing: border-box;\n font-family: inherit;\n }\n #btnPreviousCashBack:focus {\n border: 1px solid #000000;\n box-shadow: 0 0 0px 2px #ffffff inset;\n }\n #btnPreviousCashBack.isPersonalized {\n width: 100%;\n min-height: 52px;\n margin-bottom: 10px;\n background: white;\n }\n #btnPreviousCashBack.isPane {\n margin-bottom: 0px;\n border-radius: 0px 0px 8px 8px;\n border: 0px;\n width: 100%;\n }\n #divLastCashbackInfo {\n display: flex;\n row-gap: 2px;\n flex-direction: column;\n justify-content: flex-start;\n text-align: left;\n }\n #txtLastCashbackInfo {\n text-align: start;\n overflow-wrap: break-word;\n font-weight: 600;\n font-size: 12px;\n line-height: 16px;\n }\n #btnPreviousTransactions {\n font-weight: 400;\n place-self: start;\n font-size: 12px;\n line-height: 16px;\n margin-top: auto;\n height: auto;\n }\n #btnPreviousTransactions::part(control) {\n background: transparent;\n padding: 0px;\n }\n #divCashbackBalances {\n display: flex;\n flex-direction: column;\n text-align: right;\n align-items: flex-end;\n width: -webkit-fill-available;\n }\n #txtGreyBalance {\n font-weight: 400;\n font-size: 12px;\n line-height: 16px;\n text-align: right;\n color: var(--text-neutral-foreground-hint);\n }\n #txtCashbackAmount {\n font-size: 20px;\n line-height: 26px;\n }\n #txtMyCashBack {\n margin-left: 10px;\n font-size: 12px;\n font-weight: 600;\n color: rgb(3, 106, 196);\n align-self: center;\n }\n #divLifetimeEarned {\n display: flex;\n margin-left: auto;\n margin-right: 10px;\n column-gap: 8px;\n align-items: center;\n }\n #txtLifetimeEarned {\n font-size: 12px;\n font-weight: 400;\n color: var(--text-neutral-foreground-hint);\n }\n #txtPriceDecorative {\n font-size: 10px;\n line-height: 14px;\n font-weight: 600;\n margin-top: 2px;\n color: var(--text-normal);\n }\n #txtPriceBalance {\n font-size: 16px;\n line-height: 22px;\n font-weight: 600;\n position: relative;\n color: var(--text-normal);\n }\n .activated::part(control) {\n border-color: transparent;\n background: rgba(0, 0, 0, 0.07);\n font-weight: 500;\n box-sizing: border-box;\n border-radius: 4px;\n opacity: 1;\n color: #000000;\n pointer-events: none;\n }\n .activated:hover {\n outline: 2px solid transparent;\n background-color: ButtonFace;\n color: ButtonText;\n border-color: ButtonText;\n }\n .activated:focus {\n border-color: #000000;\n box-shadow: 0 0 0px 2px #ffffff inset;\n }\n .activatedText\n {\n overflow: hidden;\n text-overflow: ellipsis;\n display: -webkit-box;\n -webkit-line-clamp: 1;\n -webkit-box-orient: vertical;\n margin: 0;\n white-space: break-spaces;\n }\n #aOfferDetails {\n font-size: 12px;\n font-weight: 400;\n display: flex;\n align-items: center;\n line-height: 10px;\n gap: 8px;\n justify-content: center;\n }\n #aOfferDetailsText {\n font-weight: 400;\n }\n #h2CashbackSectionTitle {\n font-size: 18px;\n font-style: normal;\n font-weight: 600;\n line-height: 24px;\n margin-bottom: 8px!important\n }\n #divConfirmationCb {\n width: 100%;\n display: flex;\n flex-direction: column;\n flex-grow: 2;\n justify-content: center;\n }\n #divConfirmationPcb {\n display: flex;\n flex-direction: column;\n flex-grow: 2;\n margin-left: 8px;\n margin-right: 8px;\n justify-content: center;\n }\n #divConfHeaderPcb {\n display: flex;\n flex-direction: column;\n row-gap: 10px;\n }\n #divConfTitlePcb {\n margin-left: 2px;\n font-size: 16px;\n line-height: 22px;\n font-weight: 600;\n }\n #divEmailUpdatesPcb {\n font-size: 12px;\n line-height: 18px;\n font-weight: 400;\n text-align: left;\n }\n #divConfTitleCb {\n margin: 0px;\n font-weight: 500;\n font-size: 24px;\n line-height: 34px;\n }\n #divCashBackContent {\n width: 100%;\n display: flex;\n flex-direction: column;\n flex-grow: 2;\n margin: 0px;\n justify-content: center;\n align-items: center;\n box-sizing: border-box;\n }\n #divDelayedCashBackTitleWrapper {\n display: flex;\n padding: 16px 54px 0;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n gap: var(--corner-radius-control-large, 8px);\n }\n #divDelayedCashBackActivatedMessageWrapper {\n display: flex;\n align-items: center;\n gap: 6px;\n }\n #divDelayedCashBackBottomContent {\n display: flex;\n flex-direction: column;\n align-items: center;\n padding: 0px 16px 16px;\n margin-top: 12px;\n }\n .divCommissionValue {\n display: inline-block;\n margin: 0px;\n vertical-align: text-bottom;\n }\n .spanCommissionValue,\n .spanCommissionValueLarge {\n display: flex;\n height: 30px;\n line-height: 28px;\n font-size: 24px;\n background: #0078D4;\n color: #fff;\n font-weight: 600;\n float: left;\n }\n .spanCommissionValueSmall {\n display: flex;\n height: 20px;\n line-height: 20px;\n font-size: 12px;\n background: #0078D4;\n color: #fff;\n font-weight: 400;\n float: left;\n }\n .splitPrice {\n font-size: 16px;\n position: relative;\n line-height: 25px;\n align-self: flex-start;\n }\n .splitPriceSmall {\n font-size: 14px;\n position: relative;\n line-height: 18px;\n align-self: flex-start;\n }\n #h2RebatesTitle {\n display: inline;\n margin: 0px;\n font-weight: 600;\n font-size: 24px;\n line-height: 32px;\n vertical-align: middle;\n text-align: center;\n }\n #h2RebatesTitlejP {\n margin: 0px;\n font-weight: 600;\n font-size: 24px;\n line-height: 32px;\n vertical-align: middle;\n text-align: center;\n display: flex;\n gap: 3px;\n align-items: center;\n min-width: fit-content;\n flex-wrap: wrap;\n justify-content: center;\n }\n .pcbSeeMore {\n margin: 0px !important;\n }\n #divBadge {\n display: flex;\n justify-content: left;\n align-items: center;\n }\n #divBadgeContainer {\n display: flex;\n flex-direction: row;\n align-items: center;\n margin: 12px 0px;\n border-radius: 4px;\n color: #F3F3F3;\n background-color: #017294;\n }\n #txtBadge {\n font-size: 12px;\n font-weight: 700;\n text-align: center;\n padding: 0px 6px;\n margin: 0;\n text-transform: uppercase;\n }\n .btnTooltip svg path {\n fill: buttonText;\n }\n #divAutoApplyActions {\n width: 100%;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n }\n #h2TurnedOffCb {\n margin: 0px;\n font-weight: 500;\n font-size: 20px;\n line-height: 34px;\n }\n #spanTurnedOffCb {\n line-height: 20px;\n margin-top: 16px;\n word-break: break-word;\n }\n #animatedWrapperA {\n position: relative;\n overflow: hidden;\n height: 18px;\n width: 100%;\n display: flex;\n flex-direction: row;\n justify-content: center;\n gap: 8px;\n font-weight: 600;\n line-height: 16px;\n font-size: 12px;\n margin: 16px 0 8px 0;\n box-sizing: border-box;\n }\n .arrowAnimatedStep {\n height: 18px;\n width: fit-content;\n opacity: 0;\n animation: slidein 0.5s ease-out forwards;\n }\n .arrowActivatedStep {\n color: #6D6D6D;\n }\n @keyframes slidein {\n 0% {\n opacity: 0;\n transform: translateX(-45px);\n }\n 50% {\n opacity: 0;\n }\n 100% {\n opacity: 1;\n }\n }\n #animatedWrapperB {\n position: relative;\n width: min(100%, 248px);\n height: 104px;\n background-color: #FAFAFA;\n border-radius: 4px;\n margin: 8px 16px 0 16px;\n display: flex;\n flex-direction: row;\n }\n #downTextWrapper {\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n padding: 0 16px 12px 16px;\n gap: 8px;\n }\n #downVarTitle {\n position: absolute;\n margin: 0;\n padding-bottom: 8px;\n font-size: 14px;\n font-weight: 600;\n line-height: 16px;\n animation: slidedown 0.5s linear forwards;\n }\n #downImageWrapper {\n position: absolute;\n width: 60px;\n height: 35px;\n right: 0px;\n top: 0px;\n }\n .downStepWrapper {\n display: flex;\n flex-direction: row;\n width: 100%;\n height: 20px;\n gap: 6px;\n align-items: center;\n font-weight: 400;\n padding-bottom: 4px;\n opacity: 0;\n position: absolute;\n animation: slidedown 0.5s ease-out forwards;\n }\n .microsoftLogo {\n width: 20px;\n height: 20px;\n border: 0.5px solid rgba(0, 0, 0, 0.1);\n border-radius: 22px;\n }\n #divExpirationStringPcb {\n display: inline-flex;\n margin-top: 8px;\n gap: 6px;\n font-size: 14px;\n line-height: 20px;\n }\n .pcbButtonAddressbar {\n margin-top: 16px;\n width: auto;\n }\n #limitedOffer3xincentive{\n font-size: 14px;\n font-weight: 600;\n line-height: 16px;\n letter-spacing: 0em;\n text-align: left;\n margin: 0px;\n margin-bottom: 5px;\n }\n .coloredBanner {\n width: 100%;\n height: 52px;\n display: block;\n background: linear-gradient(91.21deg, #E8E0FC 0%, #EAFEFC 100%);\n }\n #blossomBox {\n background: #E0EDFF;\n height: 54px;\n width: 100%;\n border-radius: 6px;\n font-size: 14px;\n line-height: 20px;\n margin-top: 8px;\n display: flex;\n flex-direction: column;\n justify-content: center;\n }\n .blossomLink {\n color: #235CCF;\n text-decoration: none;\n white-space: nowrap;\n }\n #div3xIncentiveTitle{\n display:flex;\n }\n #div3xMerchantInfo{\n display:flex;\n }\n .infoIcon {\n width: 10px;\n height: 10px;\n position: relative;\n padding-left: 3px;\n padding-bottom: 7px;\n margin-top: 15px;\n margin-right: 12px;\n }\n .microsoftExclusiveText{\n font-size: 12px;\n font-weight: 600;\n line-height: 16px;\n letter-spacing: 0em;\n text-align: center;\n margin-left: auto;\n margin-right: auto;\n margin: 1px;\n margin-top: 6px;\n }\n #onTxtMerchantInfo {\n position: relative;\n margin-top: 0px;\n margin-bottom: 0px;\n font-size: 14px;\n font-weight: 400;\n line-height: 16px;\n letter-spacing: 0em;\n text-align: center;\n margin-right: 5px;\n }\n .microsoftCashbackText{\n font-size: 18px;\n font-weight: 700;\n line-height: 24px;\n letter-spacing: 0em;\n margin: 1px;\n text-align: center;\n background: linear-gradient(180deg, #163398 27.46%, #4768DC 82.39%);\n -webkit-background-clip: text;\n background-clip: text;\n -webkit-text-fill-color: transparent;\n }\n .microsoftCashbackTextDark{\n font-size: 18px;\n font-weight: 700;\n line-height: 24px;\n letter-spacing: 0em;\n margin: 1px;\n text-align: center;\n font-color:white;\n }\n #cashbackBtn3xIncentive {\n width: "80% !important";\n height: 40px;\n margin-bottom: 15px;\n padding-left: 15px;\n padding-right: 15px;\n }\n #cashbackTitle3xIncentive {\n display: inline;\n margin: 0px;\n font-weight: 600;\n font-size: 20px;\n line-height: 32px;\n vertical-align: middle;\n text-align: center;\n margin: 12px;\n margin-right: 0px;\n }\n #div3xCashbackContent{\n width: 100%;\n display: flex;\n flex-direction: column;\n flex-grow: 2;\n margin: 0px;\n justify-content: center;\n align-items: center;\n background-color:white;\n\n }\n .spanCommissionValue3xIncentive {\n display: flex;\n height: 30px;\n line-height: 28px;\n font-size: 20px !important;\n background: #0078D4;\n color: #fff;\n font-weight: 600;\n float: left;\n }\n #divBadge {\n display: flex;\n justify-content: left;\n align-items: center;\n }\n #divBadgeContainer {\n display: flex;\n flex-direction: row;\n align-items: center;\n margin: 12px 0px;\n border-radius: 4px;\n color: #F3F3F3;\n background-color: #017294;\n }\n #txtBadge {\n font-size: 12px;\n font-weight: 700;\n text-align: center;\n padding: 0px 6px;\n margin: 0;\n text-transform: uppercase;\n }\n .downStepNumber {\n border-radius: 50%;\n width: 15px;\n height: 15px;\n border: 1px solid #3267FA;\n color: #3267FA;\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n font-size: 12px;\n font-weight: 700;\n }\n .downStepText {\n line-height: 16px;\n font-size: 12px;\n }\n @keyframes slidedown {\n 100% {\n opacity: 1;\n transform: translateY(12px);\n }\n }\n @media (forced-colors: active) {\n .activated {\n background-color: Highlight;\n forced-color-adjust: none;\n color: highlightText;\n }\n .activated: focus {\n box-shadow: 0 0 0 2px HighlightText inset;\n border-color: buttonText;\n }\n .imgCBTag {\n display: none;\n }\n }\n @media (prefers-reduced-motion: reduce) {\n .arrowAnimatedStep {\n animation: none;\n opacity: 1;\n }\n #downVarTitle {\n animation: none;\n top: 12px;\n }\n .downStepWrapper {\n animation: none;\n opacity: 1;\n margin-top: 12px;\n }\n }\n '}getDarkModeStyles(){return"\n .activated::part(control) {\n background: rgba(255, 255, 255, 0.09);\n color: #FFFFFF;\n }\n .activated:hover {\n outline: 2px solid transparent;\n background-color: transparent;\n border-color: ButtonText;\n }\n #divForYouPcb {\n background: #DCF4FC;\n color: #1A1A1A;\n }\n #divCategoryExclusions {\n color: var(--neutral-foreground-rest)!important;\n }\n #btnPreviousCashBack {\n background: linear-gradient(90deg, #4C544A 0%, #425559 47.4%, #544E5D 100%);\n border: 1px solid rgba(255, 255, 255, 0.03);\n }\n #btnPreviousCashBack.isPersonalized {\n background: linear-gradient(91.32deg, rgba(242, 242, 242, 0.049) 0%, rgba(242, 242, 242, 0.014) 51.56%, rgba(242, 242, 242, 0.049) 100%);\n }\n #txtMyCashBack {\n color: #63ADE5;\n }\n .arrowActivatedStep {\n color: #AFAFAF;\n }\n #grayArrow {\n fill: #FFFFFF;\n }\n #animatedWrapperB, #divCashBackPopup, #divCashBackCategoriesPopup {\n background-color: #424242;\n }\n #blossomBox {\n background: #243966;\n }\n .blossomLink {\n color: #4D8DFA;\n }\n "}getErrorIcon(){return eh.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16" fill="none"><path d="M8 0C12.4183 0 16 3.58172 16 8C16 12.4183 12.4183 16 8 16C3.58172 16 0 12.4183 0 8C0 3.58172 3.58172 0 8 0ZM8 1C4.13401 1 1 4.13401 1 8C1 11.866 4.13401 15 8 15C11.866 15 15 11.866 15 8C15 4.13401 11.866 1 8 1ZM8 10.5C8.41421 10.5 8.75 10.8358 8.75 11.25C8.75 11.6642 8.41421 12 8 12C7.58579 12 7.25 11.6642 7.25 11.25C7.25 10.8358 7.58579 10.5 8 10.5ZM8 4C8.24546 4 8.44961 4.17688 8.49194 4.41012L8.5 4.5V9C8.5 9.27614 8.27614 9.5 8 9.5C7.75454 9.5 7.55039 9.32312 7.50806 9.08988L7.5 9V4.5C7.5 4.22386 7.72386 4 8 4Z" fill="#CC0000"/></svg>`}getConfirmationInfoIcon(){return eh.Z.getTrustedHTML`<svg width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
<path opacity="0.4" d="M5.4 6.6C5.4 6.26863 5.66863 6 6 6C6.33137 6 6.6 6.26863 6.6 6.6V8.4C6.6 8.73137 6.33137 9 6 9C5.66863 9 5.4 8.73137 5.4 8.4V6.6ZM6 3.3C5.50294 3.3 5.1 3.70294 5.1 4.2C5.1 4.69706 5.50294 5.1 6 5.1C6.49706 5.1 6.9 4.69706 6.9 4.2C6.9 3.70294 6.49706 3.3 6 3.3ZM0 6C0 2.68629 2.68629 0 6 0C9.31371 0 12 2.68629 12 6C12 9.31371 9.31371 12 6 12C2.68629 12 0 9.31371 0 6ZM6 1.2C3.34903 1.2 1.2 3.34903 1.2 6C1.2 8.65097 3.34903 10.8 6 10.8C8.65097 10.8 10.8 8.65097 10.8 6C10.8 3.34903 8.65097 1.2 6 1.2Z" fill="black" fill-opacity="0.83"/>
</svg>`}getCommunityInsightsIcon(){return eh.Z.getTrustedHTML`<svg width="13" height="13" viewBox="0 0 13 13" fill="none" xmlns="http://www.w3.org/2000/svg">
<path
d="M2.25 7.09375C2.25 6.75846 2.28906 6.42806 2.36719 6.10254C2.44531 5.77702 2.56738 5.46615 2.7334 5.16992C2.75944 5.12435 2.78548 5.07715 2.81152 5.02832C2.83757 4.97949 2.86849 4.93392 2.9043 4.8916C2.9401 4.84603 2.97754 4.81185 3.0166 4.78906C3.05566 4.76628 3.10612 4.75326 3.16797 4.75C3.22005 4.75 3.27051 4.76302 3.31934 4.78906C3.36816 4.8151 3.4056 4.85091 3.43164 4.89648L4.08105 5.95605C4.11035 6.00488 4.14941 6.04232 4.19824 6.06836C4.24707 6.0944 4.30241 6.10905 4.36426 6.1123C4.47493 6.1123 4.5612 6.07161 4.62305 5.99023C4.6849 5.90885 4.71745 5.81608 4.7207 5.71191C4.7207 5.66634 4.71582 5.62565 4.70605 5.58984C4.69629 5.55404 4.68164 5.51497 4.66211 5.47266C4.52865 5.1862 4.4196 4.90462 4.33496 4.62793C4.25033 4.35124 4.20801 4.05013 4.20801 3.72461C4.20801 3.31445 4.27637 2.95475 4.41309 2.64551C4.5498 2.33626 4.74023 2.07096 4.98438 1.84961C5.22852 1.62826 5.51335 1.44922 5.83887 1.3125C6.16439 1.17578 6.5127 1.07324 6.88379 1.00488C6.89681 1.00163 6.91471 1 6.9375 1C7.01237 1 7.0791 1.02441 7.1377 1.07324C7.21256 1.13835 7.25 1.2181 7.25 1.3125C7.25 1.80078 7.33301 2.26628 7.49902 2.70898C7.66504 3.15169 7.89453 3.56673 8.1875 3.9541C8.36654 4.18848 8.5472 4.42448 8.72949 4.66211C8.91178 4.89974 9.07943 5.14714 9.23242 5.4043C9.38542 5.66146 9.50911 5.92839 9.60352 6.20508C9.69792 6.48177 9.74675 6.778 9.75 7.09375C9.75 7.44206 9.70768 7.7806 9.62305 8.10938C9.53841 8.43815 9.41471 8.7474 9.25195 9.03711C9.08919 9.32682 8.89714 9.5905 8.67578 9.82812C8.45443 10.0658 8.20378 10.2725 7.92383 10.4482C7.64388 10.624 7.34277 10.7591 7.02051 10.8535C6.69824 10.9479 6.35807 10.9967 6 11C5.64193 11 5.30176 10.9528 4.97949 10.8584C4.65723 10.764 4.35775 10.6289 4.08105 10.4531C3.80436 10.2773 3.55208 10.0706 3.32422 9.83301C3.09635 9.59538 2.9043 9.33008 2.74805 9.03711C2.5918 8.74414 2.46973 8.4349 2.38184 8.10938C2.29395 7.78385 2.25 7.44531 2.25 7.09375Z"
fill="#D63600"
style="fill:#D63600;fill:color(display-p3 0.8400 0.2100 0.0000);fill-opacity:1;"/>
</svg>`}},ig=class{constructor(e,t){(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"cashbackAssets",void 0),this.flyoutData=e,this.commonAssets=t,this.cashbackAssets=new tg}styleDefaultState(e,t){e&&(e.disabled=!1,e.appearance="accent",e.textContent=t,e.setAttribute("aria-live","assertive"))}styleSeeMoreButton(e,t){const i=(0,Y.Ux)("DIV");i.style.display="inline-block",i.style.paddingLeft="10px",i.style.verticalAlign="middle",i.style.paddingBottom="3px",i.innerHTML=this.commonAssets.getCaretDownIcon(),e.textContent=t?this.flyoutData.strings.cbOfferSeeLessButtonTitle:this.flyoutData.strings.cbOfferDetailsButtonTitle,t&&(i.style.transform="rotate(180deg)",i.style.paddingRight="10px",i.style.paddingLeft="0px"),e.appendChild(i)}styleProcessingState(e){const t=(0,Y.Ux)("fluent-progress-ring");t.style.width="17px",t.style.height="17px",t.style.margin="0px",t.style.stroke="white",t.slot="start",t.setAttribute("aria-hidden","true"),e&&(e.textContent=this.flyoutData.strings.cbProcessing,e.style.backgroundColor="#0656F8",e.style.color="#FFFFFF",e.setAttribute("aria-live","assertive"),e.appendChild(t))}styleActivatedState(e){const t=this.flyoutData.common.shopping.querySelector("#divErrorCashbackActivation");if(t&&t.remove(),e){e.style.backgroundColor="unset";const t=e.querySelector("fluent-progress-ring");t&&t.remove();const i=(0,Y.Ux)("DIV");i.innerHTML=this.commonAssets.getGreenCheck(),i.slot="start",i.setAttribute("aria-hidden","true"),e.classList.add("activated");{const t=(0,Y.Ux)("p");t.className="activatedText";const i=this.flyoutData.strings.cbActivatedButton;t.textContent=i,e.title=i,e.textContent="",e.appendChild(t)}e.appendChild(i)}}renderErrorState(e,t,i){if(this.flyoutData.common.shopping.querySelector("#divErrorCashbackActivation"))return;const n=(0,Y.Ux)("DIV",{style:"display: flex; flex-direction: row;"});n.id="divErrorCashbackActivation";const o=(0,Y.Ux)("DIV",{style:"align-self: center;"});o.innerHTML=this.cashbackAssets.getErrorIcon(),o.setAttribute("aria-label","hidden");const r=(0,Y.Ux)("P");r.className="txtMedium",r.textContent=i??this.flyoutData.strings.cbErrorMessage,r.setAttribute("role","alert"),this.flyoutData.dataStoreModule.CashBackData?.shouldRenderCashBackNotification&&(r.style.fontSize="12px"),n.appendChild(o),n.appendChild(r),"actions"===t?(n.slot="header-content",this.flyoutData.common.shopping.prepend(n)):e&&e.parentElement&&e.parentElement.prepend(n)}},ng=class{constructor(e,t,i,n){(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),this.telemetryUtilities=e,this.flyoutData=t,this.pageHandlerModule=i,this.logModule=n}recordCashbackButtonClick(e,t,n,o,r,a,s){const l=this.createClickData(e,t,n,n.estimatedCashbackData);this.pageHandlerModule.RecordAsUserAction(o),this.pageHandlerModule.RecordAsUserEngagement(r,a),this.logModule.LogInfoEvent(i.R.ButtonClick,s,l,Jl.g.CouponImpressionId)}recordCashBackOfferDetailsButtonClick(e,t){const n=t?"User clicked on cashback categories see less":"User clicked on cashback offer details",o=new W.Z(i.$S.CashbackInfoOfferDetails,this.telemetryUtilities.setContentViewed(e));this.logModule.LogInfoEvent(i.R.ButtonClick,n,o,Jl.g.CouponImpressionId),t?this.pageHandlerModule.RecordAsUserEngagement(q.FV.CASHBACK_MODULE_VIEW_OFFER_DETAILS_SEELESS_CLICK,this.flyoutData.common.popupOrigination):this.pageHandlerModule.RecordAsUserEngagement(q.FV.CASHBACK_MODULE_VIEW_OFFER_DETAILS_CLICK,this.flyoutData.common.popupOrigination)}recordDelayedCashbackActivateButton(e){const t=e?"User clicked on delayed Cashback Activate Button Ok":"User clicked on delayed Cashback Activate Button Sign up",n=this.createClickData(i.$S.ActivateCashBack,r.ModuleNames.CASHBACK_DELAYED_ENROLLMENT,this.flyoutData.dataStoreModule.CashBackData,this.flyoutData.dataStoreModule.CashBackData?.estimatedCashbackData);this.logModule.LogInfoEvent(i.R.ButtonClick,t,n,Jl.g.CouponImpressionId)}createClickData(e,t,n,o){const r=new W.Z(e,this.telemetryUtilities.setContentViewed(t));return r.Metadata=JSON.stringify({profile:n?.isEdgeProfile?i.E_.Edge:i.E_.Bing,isEstimatedPDP:o?.isPdp,isEstimatedCheckoutPage:o&&this.flyoutData.common.isCheckoutPageUsingUrlMatch,isPercentageCashback:!o}),r}},og=class{constructor(e,t,i,n,o,r,a,l){(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"viewModuleUtilities",void 0),(0,s.Z)(this,"tooltipUtilities",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"cashbackTelemetry",void 0),(0,s.Z)(this,"cashbackStyles",void 0),(0,s.Z)(this,"isCashBackOfferDetailsVisible",!1),this.stateManagement=e,this.flyoutData=t,this.pageHandlerModule=i,this.logModule=n,this.viewModuleUtilities=o,this.tooltipUtilities=r,this.telemetryUtilities=a,this.commonAssets=l,this.cashbackTelemetry=new ng(this.telemetryUtilities,this.flyoutData,this.pageHandlerModule,this.logModule),this.cashbackStyles=new ig(this.flyoutData,this.commonAssets)}createCashbackSection(){const e=document.createElement("msft-edge-shopping-section");return e.id="cashBackSection",e.style.width="100%",e.accordion=!0,e.expanded=!1,e.isShadow=!0,e}createCashbackWrapper(){const e=(0,Y.Ux)("div",{id:"divCashBackPopup"});return e.style.padding="16px 0 0",e}createDelayedCashbackWrapper(){return(0,Y.Ux)("div",{id:"divDelayedCashBackPopup"})}createCashbackCategoriesWrapper(){const e=(0,Y.Ux)("div",{id:"divCashBackCategoriesPopup"});return e.style.padding="16px",e.style.marginTop="12px",e}createCashBackCategoriesContent(){return(0,Y.Ux)("div",{className:"txtXSmall",id:"divCashBackCategoriesContent"})}createCashbackContent(){return(0,Y.Ux)("div",{className:"txtMedium",id:"divCashBackContent"})}createDelayedCashbackTitleWrapper(e){const t=(0,Y.Ux)("div",{className:"txtMedium",id:"divDelayedCashBackTitleWrapper"});return t.style.background=e&&!this.viewModuleUtilities.isDarkMode()?`url(${this.flyoutData.common.resourcesEndpoint}cashback/DelayedCashbackBackground.png)`:"",t.style.backgroundSize="cover",t.style.paddingBottom=e?"16px":"0px",t}createCashBackBottomContentWrapper(){return(0,Y.Ux)("div",{className:"txtMedium",id:"divDelayedCashBackBottomContent"})}createCashBackActivatedMessageWrapper(e){const t=(0,Y.Ux)("div",{className:"txtMedium",id:"divDelayedCashBackActivatedMessageWrapper"}),i=(0,Y.Ux)("div",{style:"height: 20px;"});i.innerHTML=this.commonAssets.getGreenCheck(),i.slot="start",i.setAttribute("aria-hidden","true");const n=(0,Y.Ux)("span",{style:"font-weight: 400;"});return n.textContent=e?this.flyoutData.strings.pcbActivatedButton:this.flyoutData.strings.cbDelayedCashBackSigninAnytimeMessage,e?(t.appendChild(i),n.style.fontSize="14px"):(n.style.color="var(--neutral-foreground-neutral-foreground-hint, #717171)",n.style.fontSize="12px"),t.appendChild(n),t}createButtonSection(){const e=(0,Y.Ux)("DIV");return e.style.display="flex",e.id="cbActivateButtonSection",e.style.flexDirection="column",e}createCashbackActivateButton(e,t){const n=this.createCashbackGenericButton(this.flyoutData.common.isPane?this.flyoutData.strings.cbActivateButton:this.flyoutData.strings.cbActivateButtonRefresh);return n.style.marginTop="10px",n.addEventListener("click",(async o=>{n.classList.add("activated"),n.textContent=this.flyoutData.strings.cbActivatedButton,n.disabled=!0,n.setAttribute("aria-live","off"),this.cashbackTelemetry.recordCashbackButtonClick(i.$S.ActivateCashBack,e,t,K.bS.ACTIVATE_CASHBACK,q.FV.ACTIVATE_CASHBACK,this.flyoutData.common.popupOrigination,"Cash back activation started"),this.pageHandlerModule.ActivateRebates(!1),t.isCashBackActivated=!0;const a=new CustomEvent(Ku.e1.onCashBackActivated),s=new CustomEvent(Ku.e1.onCashBackActivatedForRewards);if(this.stateManagement.dispatchEvent(a),this.stateManagement.dispatchEvent(s),0===o.screenX&&0===o.screenY){const e=document.querySelector(`#${r.z6.CLOSE}`);e&&e.focus()}else n.focus();t.isCashBackActivated?this.cashbackStyles.styleActivatedState(n):this.cashbackStyles.styleDefaultState(n,this.flyoutData.strings.cbActivateButtonRefresh)})),n}createCashbackJoinNowAndActivateButton(e,t){const n=this.createCashbackGenericButton(this.flyoutData.strings.cbBingActivateButton);return n.addEventListener("click",(async n=>{this.cashbackTelemetry.recordCashbackButtonClick(i.$S.JoinAndActivateCashback,e,t,K.bS.ACTIVATE_CASHBACK_NEW,q.FV.ACTIVATE_CASHBACK_NEW,this.flyoutData.common.popupOrigination,"Sign in started"),await this.pageHandlerModule.ActivateRebates(!0)})),n}createCashbackTitle(e,t,i,n,o){const r=(0,Y.Ux)("div",{id:"divCashBackTitle"});r.style.whiteSpace="no-wrap",r.style.width=n?"100%":"calc(100% - 20px)";const a=(0,Y.Ux)("h2",{id:i?.isPdp&&this.viewModuleUtilities.shouldRenderSmallNotification()?"h2PdpEstimateTitle":"h2RebatesTitle"}),s=this.viewModuleUtilities.createCommissionArrow(t,!!i,zu.h.Large,void 0,i?.currency,i?.isPdp&&this.viewModuleUtilities.shouldRenderSmallNotification(),!1),l=this.flyoutData.common.isPane;if(e){const t=this.createOldCashbackText(e);(0,T.B7)(a,this.flyoutData.strings.cbActivateTitleWithOldCashback,t,s);const i=this.tooltipUtilities.createCashbackTooltip(this.pageHandlerModule,this.logModule);l||a.appendChild(i)}else if(i)(0,T.B7)(a,i.isPdp?this.flyoutData.strings.cbMainTitleOffWithPdpCashbackEstimate:this.flyoutData.strings.cbMainTitleOffWithCashbackEstimate,this.tooltipUtilities.createCashbackTooltip(this.pageHandlerModule,this.logModule),s);else{(0,T.B7)(a,n?this.flyoutData.strings.cbMainTitleDelayedEnrollment:this.flyoutData.strings.cbMainTitleOff,s);const e=this.tooltipUtilities.createCashbackTooltip(this.pageHandlerModule,this.logModule);l||a.appendChild(e)}return r.appendChild(a),r}createCashbackTitle3xIncentive(e,t,i,n=!1){const o=(0,Y.Ux)("div",{id:"divCashBackTitle"});o.style.whiteSpace="no-wrap",o.style.width="100%";const r=(0,Y.Ux)("h2",{id:"cashbackTitle3xIncentive"}),a=this.viewModuleUtilities.createCommissionArrow(t,!1,zu.h.Large,void 0,void 0,void 0,!1),s=a.querySelector(".spanCommissionValueLarge");s&&(s.style.fontSize="20px");let l=!0,c=(0,Y.Ux)("SPAN");if(i){let e="";e=n?this.flyoutData.strings.cbMainTitleOnStoreWide:this.flyoutData.strings.cbMainTitleOn,(0,T.B7)(r,e,a),c=this.tooltipUtilities.createCashbackTooltip(this.pageHandlerModule,this.logModule),l=this.flyoutData.common.isPane}else if(e){const t=this.createOldCashbackText3xIncentive(e);(0,T.B7)(r,this.flyoutData.strings.cbActivateTitle3xIncentive,t,a),c=this.tooltipUtilities.createCashbackTooltip(this.pageHandlerModule,this.logModule),l=this.flyoutData.common.isPane}if(r.lastChild){const e=r.lastChild.previousSibling,t=(0,Y.Ux)("SPAN",{style:"white-space: nowrap;"});e&&t.appendChild(e),t.appendChild(r.lastChild),r.appendChild(t)}return l||r.appendChild(c),o.appendChild(r),o}createBlossomInfoSection(e){const n=new t.Z(i.xu.CashBackBlossomCampaign);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,`Creating Blossom info section. isBlossomPurchaseCompleted: ${e}. isPane: ${this.flyoutData.common.isPane}.`,n);const o=(0,Y.Ux)("div",{id:"blossomBox"});this.flyoutData.common.isPane||(o.style.borderRadius="0px",o.style.width="100%");const r=(0,Y.Ux)("p");if(r.style.margin="0px",e&&!this.flyoutData.common.isPane){const e=(0,Y.Ux)("span");e.innerText="Congrats, you're getting ",r.appendChild(e);const t=(0,Y.Ux)("span",{style:"white-space: nowrap;"}),i=(0,Y.Ux)("strong",{style:"white-space: nowrap;"});i.innerText="$5 bonus cash back. ",t.appendChild(i);const n=(0,Y.Ux)("a",{href:"https://www.bing.com/rebates/history",target:"_blank",rel:"noopener noreferrer",className:"blossomLink"});n.innerText="Track cash back",t.appendChild(n),r.appendChild(t)}else if(e&&this.flyoutData.common.isPane){const e=(0,Y.Ux)("span",{style:"white-space: nowrap;"}),t=(0,Y.Ux)("span");t.innerText="You're also getting ",e.appendChild(t);const i=(0,Y.Ux)("strong",{style:"white-space: nowrap;"});i.innerText="$5 bonus cash back ",e.appendChild(i);const n=(0,Y.Ux)("span");n.innerText="for ",e.appendChild(n),r.appendChild(e);const o=(0,Y.Ux)("br");r.appendChild(o);const a=(0,Y.Ux)("span",{style:"white-space: nowrap;"}),s=(0,Y.Ux)("span");s.innerText="completing a purchase. ",a.appendChild(s);const l=(0,Y.Ux)("a",{href:"https://www.bing.com/rebates/history",target:"_blank",rel:"noopener noreferrer",className:"blossomLink"});l.innerText="Track cash back",a.appendChild(l),r.appendChild(a)}else{const e=(0,Y.Ux)("span");e.innerText="Complete a purchase and get ",r.appendChild(e);const t=(0,Y.Ux)("span",{style:"white-space: nowrap;"}),i=(0,Y.Ux)("span");i.innerText="an extra ",t.appendChild(i);const n=(0,Y.Ux)("strong",{style:"white-space: nowrap;"});n.innerText="$5 cash back. ",t.appendChild(n),r.appendChild(t);const o=this.flyoutData?.dataStoreModule?.UserInfo?.hanid,a=o?`https://bing.com/shop/deals?FORM=EDGTSK&ocid=MT00MZ&hashid=${o}`:"https://bing.com/shop/deals",s=(0,Y.Ux)("a",{href:a,target:"_blank",rel:"noopener noreferrer",className:"blossomLink"});s.innerText="See details",r.appendChild(s)}return o.appendChild(r),o}createRebatesHistoryLinkSection(){const e=(0,Y.Ux)("div",{id:"rebatesHistoryLinkSection",style:"margin-top: 6px"}),t=(0,Y.Ux)("a",{href:"https://www.bing.com/rebates/history",innerText:this.flyoutData.strings.rebatesHistoryLinkText,target:"_blank",rel:"noopener noreferrer",style:"text-decoration: none; font-size: 14px;"});return this.viewModuleUtilities.isDarkMode()?t.style.color="#4082F5":t.style.color="#235CCF",e.appendChild(t),e}createMerchantInfoSection(e){const t=this.flyoutData.dataStoreModule.CashBackData?.merchantFullName?this.flyoutData.dataStoreModule.CashBackData?.merchantFullName:this.flyoutData.common.domain,i=e?t:(0,T.fZ)("gcbOnMerchantName",this.flyoutData.strings.gcbOnMerchantName,t),n=(0,Y.Ux)("div",{id:"divMerchantInfo"}),o=(0,Y.Ux)("p",{id:"txtMerchantInfo"});o.textContent=i;const r=(0,Y.Ux)("div",{id:"divMerchantIcon"}),a=(0,Y.Ux)("img",{id:"imgMerchantIcon"});return this.viewModuleUtilities.addFavIconSrc(a,r,this.flyoutData.common.domain),"microsoft.com"!==this.flyoutData.common.domain||e?"microsoft.com"===this.flyoutData.common.domain?(n.appendChild(r),n.appendChild(o)):(n.appendChild(o),n.appendChild(r)):(o.textContent=t,n.style.marginTop="3px",r.style.alignItems="center",(0,T.B7)(n,this.flyoutData.strings.gcbOnLogoMerchantName,r,o)),n}createYellowLight(){const e=(0,Y.Ux)("DIV");return e.setAttribute("aria-hidden","true"),e.style.display="inline-block",e.style.verticalAlign="vertical-align: -webkit-baseline-middle",e.innerHTML=this.commonAssets.getYellowLightIcon(),e}createCashbackSeeOffersButton(e){return this.createSeeOffersButton(this.flyoutData.strings.cbLearnMore,r.ModuleNames.CASHBACK_ACTIVATE,(()=>this.pageHandlerModule.NavigateToLearnMore(ju.$.NEW_FOREGROUND_TAB,this.flyoutData.dataStoreModule.CashBackData?.merchantName,this.flyoutData.common.domain)),e)}CreateSeeMoreButton(e,t,i){const n=document.createElement("fluent-button");return this.isCashBackOfferDetailsVisible=t,n.className+="btnSeeMore",n.id="offerDetails",n.style.fontWeight="400",n.classList.add("newSeeMore"),n.appearance="neutral",this.cashbackStyles.styleSeeMoreButton(n,t),this.viewModuleUtilities.isDarkMode()?n.style.color="#FFFFFF":n.style.color="#1A1A1A",n.style.marginLeft="0px",n.style.marginTop="12px",n.addEventListener("click",(t=>{this.cashbackTelemetry.recordCashBackOfferDetailsButtonClick(e,this.isCashBackOfferDetailsVisible),this.isCashBackOfferDetailsVisible?i.style.display="none":i.style.display="flex",this.isCashBackOfferDetailsVisible=!this.isCashBackOfferDetailsVisible,this.cashbackStyles.styleSeeMoreButton(n,this.isCashBackOfferDetailsVisible)})),n}createRecieveCashbackText(){const e=(0,Y.Ux)("div",{id:"aOfferDetails",className:"action"}),t=(0,Y.Ux)("div",{id:"cashBackInfoText"}),i=(0,Y.Ux)("P");return i.className="txtSmall",i.textContent=this.flyoutData.strings.cbReceiveCashBackTitle,t.append(i),e.append(this.createYellowLight()),e.append(t),e.style.marginTop="12px",e.style.marginBottom="12px",e}createPersonalizedSeeOffersButton(e){return this.createSeeOffersButton(this.flyoutData.strings.commonLearnMore,r.ModuleNames.CASHBACK,(()=>this.pageHandlerModule.NavigateToBingRebates()),e)}createSeeOffersButton(e,t,n,o){const r=(0,Y.Ux)("fluent-anchor",{id:"aOfferDetails",className:"action"});return r.appearance="lightweight",r.href="#",r.textContent=e,r.style.alignSelf="center",r.addEventListener("click",(()=>{const e=new W.Z(i.$S.RebatesLearnMore,this.telemetryUtilities.setContentViewed(t));this.pageHandlerModule.RecordAsUserAction(K.bS.REBATES_LEARN_MORE),this.pageHandlerModule.RecordAsUserEngagement(q.FV.REBATES_LEARN_MORE,this.flyoutData.common.popupOrigination),this.logModule.LogInfoEvent(i.R.ButtonClick,"User navigated to rebates learn more",e,Jl.g.CouponImpressionId),n()})),o&&o(r),r}createExclusiveBadge(e){const t=(0,Y.Ux)("div",{id:"divBadge"}),i=(0,Y.Ux)("div",{id:"divBadgeContainer"}),n=(0,Y.Ux)("p",{id:"txtBadge"});return n.innerText=e,n.setAttribute("aria-label",e),i.appendChild(n),t.appendChild(i),t}createOldCashbackText(e){const t=document.createElement("SPAN");return t.style.textDecoration="line-through",t.textContent=e,t.style.float="left",t.style.marginRight="5px",t}createOldCashbackText3xIncentive(e){const t=document.createElement("SPAN");return t.style.textDecoration="line-through",t.textContent=e,t.style.marginRight="5px",t}createAnimationDownVariation(){const e=(0,Y.Ux)("div",{id:"animatedWrapperB"}),t=(0,Y.Ux)("div",{id:"downImageWrapper"}),i=(0,Y.Ux)("img");this.viewModuleUtilities.setImageSrc(i,this.flyoutData.common.resourcesEndpoint+"cashback/coinfall.png"),i.setAttribute("aria-hidden","true"),i.slot="image",t.appendChild(i),e.appendChild(t);const n=(0,Y.Ux)("div",{id:"downTextWrapper"}),o=(0,Y.Ux)("p",{id:"downVarTitle",textContent:this.flyoutData.strings.cbEasyTitle});n.append(o);const r=[this.flyoutData.strings.cbOK,this.flyoutData.strings.cbShop,this.flyoutData.strings.cbEarn];for(const[e,t]of r.entries()){const i=e+1,o=(0,T.fZ)("cbStep",this.flyoutData.strings.cbStep,`${i}`),r=(0,Y.Ux)("div",{className:"downStepWrapper"}),a=(0,Y.Ux)("div",{className:"downStepNumber",textContent:i,ariaLabel:o}),s=(0,Y.Ux)("div",{className:"downStepText",textContent:t});r.style.top=20*i+4+"px",r.style.animationDelay=.5*i+"s",r.append(a,s),n.append(r)}return e.appendChild(n),this.writeFREAnimationShownTimestamp(),e}createAnimationArrowVariation(e=!1){const t=(0,Y.Ux)("div",{id:"animatedWrapperA"}),i=this.commonAssets.getGrayArrow(),n=(0,Y.Ux)("div",{id:"stepOne"}),o=(0,Y.Ux)("div",{textContent:this.flyoutData.strings.cbPurchase}),r=(0,Y.Ux)("div",{textContent:this.flyoutData.strings.cbGetCashback}),a=[n,(0,Y.Ux)("div",{innerHTML:i}),o,(0,Y.Ux)("div",{innerHTML:i}),r];if(e)n.textContent=this.flyoutData.strings.cbNext,n.classList.add("arrowActivatedStep");else if(!1===e){n.textContent=this.flyoutData.strings.cbOK;for(const[e,t]of a.entries())t.classList.add("arrowAnimatedStep"),t.style.animationDelay=.5*e+"s"}return t.append(...a),this.writeFREAnimationShownTimestamp(),t}createActivatedArrowAnimation(){const e=document.querySelector("#stepOne");e&&(e.textContent=this.flyoutData.strings.cbNext,e.style.animationName="none",requestAnimationFrame((()=>{setTimeout((()=>{e.style.animationName="",e.classList.add("arrowActivatedStep")}),0)})))}createDelayedEnrollmentCashbackButton(e){const t=e?this.flyoutData.strings.cbBingActivateButtonDelayedEnrollment:this.flyoutData.strings.cbActivateButtonRefresh,i=(0,Y.Ux)("fluent-button");return i.setAttribute("appearance","accent"),i.classList.add(a.q.Primary),i.id="delayedCashbackActivateButton",i.disabled=!1,i.textContent=t,i.setAttribute("aria-live","assertive"),i.addEventListener("click",(async t=>{if(this.cashbackTelemetry.recordDelayedCashbackActivateButton(e),e)await this.pageHandlerModule.ActivateRebates(!0);else{const e=new CustomEvent(Ku.e1.onDelayedCashBackActivated);this.stateManagement.dispatchEvent(e)}})),i}setCashbackSectionTitle(e,t){const i=(0,Y.Ux)("B"),n=this.flyoutData.strings.cbCashBackOnOff;t.isCashBackActivated?i.textContent=this.flyoutData.strings.cbRebatesOn:t.isCashBackActivated||(i.textContent=this.flyoutData.strings.cbRebatesOff),(0,T.B7)(e,n,i)}async populateCashbackCategoriesList(e,t,i){if(e&&t.length>0){for(let i=0;i<t.length;i++){const n=t[i],o=(0,Y.Ux)("div",{id:"divCatgoryRow"+i,style:"display: flex; flex-direction: row;"}),r=this.viewModuleUtilities.retrieveCashBackAmount(null,!1,n).cashBackAmount,a=this.viewModuleUtilities.createCommissionArrow(r,!1,zu.h.Small),s=(0,Y.Ux)("div",{className:"txtXSmall",id:"divCatgoryDetail"+i});o.style.marginBottom="12px",s.style.marginLeft="12px",s.style.textAlign="left",s.innerText=n.category,a.style.display="flex",a.style.alignSelf="center",o.appendChild(a),o.appendChild(s),o.setAttribute("aria-label",r+" "+n.category),e.appendChild(o)}if(i){const t=(0,Y.Ux)("div",{id:"divCategoryExclusions",style:"font-size: 10px; line-height: 14px;"});t.style.color="var(--light-foreground-foreground-4, var(--color-neutral-foreground-4-rest, #707070))",t.style.marginTop="4px",t.style.textAlign="left",t.innerText=this.flyoutData.strings.cashbackExclusionsTitle+": "+i+".",t.setAttribute("aria-label",this.flyoutData.strings.cashbackExclusionsTitle+": "+i),e.appendChild(t)}}}createCashbackGenericButton(e){const t=(0,Y.lw)(this.viewModuleUtilities);return t.disabled=!1,t.appearance="accent",t.textContent=e,t.setAttribute("aria-live","assertive"),t}writeFREAnimationShownTimestamp(){const e=new Date,t=(0,h.WN)("cbAnimShown");Array.isArray(t)?(t.push(e),(0,h.Ev)("cbAnimShown",t)):(0,h.Ev)("cbAnimShown",[e])}};class rg{constructor(e,t,i,n,o,r,a,l,c){this.stateManagement=e,this.flyoutData=t,this.commonAssets=n,this.logModule=o,this.moduleName=r,this.estimatedCashbackData=a,this.initialBtnText=l,this.onButtonClickAddedBehavior=c,(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"footerUtilities",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"addedStyles",!1),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"cashbackComponents",void 0),(0,s.Z)(this,"cashbackTelemetry",void 0),(0,s.Z)(this,"cashbackStyles",void 0),this.pageHandlerModule=i.pageHandlerModule,this.footerUtilities=i.footerUtilities,this.utilities=i.viewModulesUtilities,this.telemetryUtilities=i.telemetryHandler,this.assets=new tg,this.cashbackComponents=new og(e,t,this.pageHandlerModule,o,i.viewModulesUtilities,i.tooltipUtilities,i.telemetryHandler,n),this.cashbackTelemetry=new ng(this.telemetryUtilities,t,this.pageHandlerModule,this.logModule),this.cashbackStyles=new ig(this.flyoutData,this.commonAssets)}addCashbackStyles(e=!1){!e&&this.addedStyles||(this.addedStyles=!0,this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()))}setEstimatedCashbackData(e){this.estimatedCashbackData=e}createActivateButton(e=!1){const t=this.flyoutData.dataStoreModule.CashBackData;if(t){const i=document.createElement("DIV");i.style.width="100%",i.style.display="flex",i.style.flexDirection="column",i.style.alignItems="center",i.style.justifyContent="center",i.style.marginTop="8px";const n=(0,Y.lw)(this.utilities);let o;this.createCashbackActivateButton(n,t,e),n.id="rebatesButton";let r=this.flyoutData.strings.cbActivateButtonRefresh;return this.flyoutData.dataStoreModule.UserInfo.isMSASignedIn&&this.flyoutData.dataStoreModule.UserInfo.isRebatesUser||(r="Join and Activate",o=this.createPrivacyMessage("hypertext"),o.style.marginTop="5px",o.style.marginLeft="10px",o.style.marginRight="10px",o.style.textAlign="justify"),this.cashbackStyles.styleDefaultState(n,r),t.isCashBackActivated&&this.cashbackStyles.styleActivatedState(n),this.initialBtnText&&(n.textContent=this.initialBtnText),i.appendChild(n),o&&i.appendChild(o),i}return null}createCashbackActivateButtonWithStateUpdate(n,o,a){o?.isSignInSupportedDomainCashBack&&(n.id="rebatesButton",this.flyoutData.common.openedWith===r.Te.Auto&&this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK&&(n.style.width="95%"));const s=e.R.isExperimentActive(f.H.cashBackDelayedEnrollmentEdgeFlow),l=this.renderCurrentButtonState(n);this.pageHandlerModule.TriggerExperiment(f.H.rewardFlyout);const c=async e=>{n.removeEventListener("click",c),a?this.footerUtilities.removeFooterButtons():this.footerUtilities.disableFooterButtons();const t=this.flyoutData.common.shopping?.querySelector("#remindLaterFooter");if(t&&(t.style.display="none"),o?.isSignInSupportedDomainCashBack&&o?.isLinkYourMSAWorkflow)this.handleLinkYourMSAClick(n,"Link personal account started");else if(o?.isSignInSupportedDomainCashBack){const e=this.cashbackTelemetry.createClickData(i.$S.ActivateCashBack,this.moduleName,o,this.estimatedCashbackData);if(this.utilities.isPinterest()?(this.pageHandlerModule.RecordAsUserAction(K.bS.PINTEREST_CASHBACK_ACTIVATED),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PINTEREST_CASHBACK_ACTIVATED,this.flyoutData.common.popupOrigination)):o.IsRebatesUser()?(this.pageHandlerModule.RecordAsUserAction(K.bS.ACTIVATE_CASHBACK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.ACTIVATE_CASHBACK,this.flyoutData.common.popupOrigination)):(this.pageHandlerModule.RecordAsUserAction(K.bS.ACTIVATE_CASHBACK_NEW),this.pageHandlerModule.RecordAsUserEngagement(q.FV.ACTIVATE_CASHBACK_NEW,this.flyoutData.common.popupOrigination)),s&&!this.flyoutData.common.isPane){this.logModule.LogInfoEvent(i.R.ButtonClick,"Delayed Cashback Activated from Flyout",e,Jl.g.CouponImpressionId);const t=new CustomEvent(Ku.e1.onDelayedCashBackActivated);this.stateManagement.dispatchEvent(t);const n=new Map((0,h.WN)(Jp.Q.DelayedCashbackActivatedDomains));n.set(this.flyoutData.common.domain,Date.now()),(0,h.Ev)(Jp.Q.DelayedCashbackActivatedDomains,[...n]),this.pageHandlerModule.OpenPane(this.flyoutData.common.popupOrigination)}else this.logModule.LogInfoEvent(i.R.ButtonClick,"Sign in started",e,Jl.g.CouponImpressionId),await this.pageHandlerModule.ActivateRebates(!0)}else this.pageHandlerModule.ActivateRebates(!1);this.onButtonClickAddedBehavior&&this.onButtonClickAddedBehavior()},d=async e=>{n.removeEventListener("click",d),this.pageHandlerModule.RetryFetchUserInfo(!1)};if(n.addEventListener("click",c),this.stateManagement.addEventListener(Ku.e1.rebatesNotActivating,(()=>{n.disabled=!1,n.addEventListener("click",c),this.cashbackStyles.styleDefaultState(n,l)})),this.stateManagement.addEventListener(Ku.e1.rebatesSignInPendingSuccess,(()=>{n.disabled=!1,n.removeEventListener("click",c),this.cashbackStyles.styleProcessingState(n)})),this.stateManagement.addEventListener(Ku.e1.onRebatesTelemetrySuccess,(()=>{n.disabled=!0,this.cashbackStyles.styleActivatedState(n)})),this.stateManagement.addEventListener(Ku.e1.rebatesSignInFail,(()=>{n.disabled=!1,n.addEventListener("click",c),n.textContent="Retry",this.cashbackStyles.renderErrorState(n,"")})),this.stateManagement.addEventListener(Ku.e1.rebatesFetchUserInfoFail,(()=>{n.disabled=!1,n.addEventListener("click",d),n.textContent="Retry",this.cashbackStyles.renderErrorState(n,"",this.flyoutData.strings.cbFetchUserProfileErrorMessage)})),this.isFailedState()||this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_REBATES_ACTIVATION_FAILED){const e=new CustomEvent(Ku.e1.onCashbackActivationError,{detail:{cashbackButton:n,slot:n?.parentElement?.slot}});this.stateManagement.dispatchEvent(e);const o=new t.Z(i.xu.ErrorCashBackActivation);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Cashback activation error -\n ${this.flyoutData.dataStoreModule.CashBackData?.activateRebatesStatus}`,o)}return l}createCashbackActivateButton(n,o,a){o?.isSignInSupportedDomainCashBack&&(n.id="rebatesButton",this.flyoutData.common.openedWith===r.Te.Auto&&this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK&&(n.style.width="95%"));const s=e.R.isExperimentActive(f.H.cashBackDelayedEnrollmentEdgeFlow),l=this.renderCurrentButtonState(n);if(this.pageHandlerModule.TriggerExperiment(f.H.rewardFlyout),n.addEventListener("click",(async e=>{a?this.footerUtilities.removeFooterButtons():this.footerUtilities.disableFooterButtons();const t=this.flyoutData.common.shopping?.querySelector("#remindLaterFooter");if(t&&(t.style.display="none"),o?.isSignInSupportedDomainCashBack&&o?.isLinkYourMSAWorkflow)this.handleLinkYourMSAClick(n,"Link personal account started");else if(o?.isSignInSupportedDomainCashBack){const e=this.cashbackTelemetry.createClickData(i.$S.ActivateCashBack,this.moduleName,o,this.estimatedCashbackData);if(this.utilities.isPinterest()?(this.pageHandlerModule.RecordAsUserAction(K.bS.PINTEREST_CASHBACK_ACTIVATED),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PINTEREST_CASHBACK_ACTIVATED,this.flyoutData.common.popupOrigination)):o.IsRebatesUser()?(this.pageHandlerModule.RecordAsUserAction(K.bS.ACTIVATE_CASHBACK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.ACTIVATE_CASHBACK,this.flyoutData.common.popupOrigination)):(this.pageHandlerModule.RecordAsUserAction(K.bS.ACTIVATE_CASHBACK_NEW),this.pageHandlerModule.RecordAsUserEngagement(q.FV.ACTIVATE_CASHBACK_NEW,this.flyoutData.common.popupOrigination)),s&&!this.flyoutData.common.isPane){this.logModule.LogInfoEvent(i.R.ButtonClick,"Delayed Cashback Activated from Flyout",e,Jl.g.CouponImpressionId);const t=new CustomEvent(Ku.e1.onDelayedCashBackActivated);this.stateManagement.dispatchEvent(t);const n=new Map((0,h.WN)(Jp.Q.DelayedCashbackActivatedDomains));n.set(this.flyoutData.common.domain,Date.now()),(0,h.Ev)(Jp.Q.DelayedCashbackActivatedDomains,[...n]),this.pageHandlerModule.OpenPane(this.flyoutData.common.popupOrigination)}else this.logModule.LogInfoEvent(i.R.ButtonClick,"Sign in started",e,Jl.g.CouponImpressionId),await this.pageHandlerModule.ActivateRebates(!0)}else await this.handleActivateCashbackClick(n,e,"Cash back activation started")?this.cashbackStyles.styleActivatedState(n):this.cashbackStyles.styleDefaultState(n,this.flyoutData.strings.cbActivateButtonRefresh);this.onButtonClickAddedBehavior&&this.onButtonClickAddedBehavior()})),this.isFailedState()||this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_REBATES_ACTIVATION_FAILED){const e=new CustomEvent(Ku.e1.onCashbackActivationError,{detail:{cashbackButton:n,slot:n?.parentElement?.slot}});this.stateManagement.dispatchEvent(e);const o=new t.Z(i.xu.ErrorCashBackActivation);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Cashback activation error -\n ${this.flyoutData.dataStoreModule.CashBackData?.activateRebatesStatus}`,o)}return l}renderCurrentButtonState(n){const o=this.flyoutData.dataStoreModule.CashBackData,a=this.flyoutData.common,s=e.R,l=a.popupOrigination===u.sR.AUTO_SHOW_REBATES_SWITCHED_TO_MSA&&s.isExperimentActive(f.H.signinRebates),c=o?.activateRebatesStatus===r.FA.PENDING_ACTIVATION_IN_PROFILE,d=s.isExperimentActive(f.H.cashBackDelayedEnrollmentEdgeFlow)&&o?.isSignInSupportedDomainCashBack&&o?.activateRebatesStatus!==r.FA.PENDING_SIGN_INTO_PROFILE;let h=this.flyoutData.strings.cbActivateButtonRefresh;if(d&&this.flyoutData.common.isPane&&(h=this.flyoutData.strings.cbBingActivateButtonDelayedEnrollment),o?.isSignInSupportedDomainCashBack&&o?.isLinkYourMSAWorkflow){h=this.flyoutData.strings.pcbLinkMsaActivateButton;const e={userInfo:this.flyoutData?.dataStoreModule?.UserInfo,isLinkYourMSAWorkflow:o?.isLinkYourMSAWorkflow,isSignInSupportedDomainCashBack:o?.isSignInSupportedDomainCashBack},n=new t.Z(i.xu.AadUserLinking);n.Metadata=JSON.stringify(e),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"AAD linking shown",n)}else if(o?.isSignInSupportedDomainCashBack&&!o?.IsRebatesUser()&&o?.activateRebatesStatus!==r.FA.PENDING_SIGN_INTO_PROFILE&&!d){h=this.flyoutData.strings.cbBingActivateButton;const e=new t.Z(i.xu.JoinAndActivateImpression,void 0,void 0,this.flyoutData.common.domain,JSON.stringify({popupOrigination:this.flyoutData.common.popupOrigination,url:this.flyoutData.common.lastCommittedURL,openedWith:this.flyoutData.common.openedWith,cashback:o?.CreateLogMetadata()}));this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Join and activate cashback notification",e)}if(o?.isCashBackActivated||l||c){this.cashbackStyles.styleDefaultState(n,h),this.cashbackStyles.styleActivatedState(n),this.flyoutData.dataStoreModule.CashBackData&&(this.flyoutData.dataStoreModule.CashBackData.isCashBackActivated=!0);const e=new CustomEvent(Ku.e1.onCashBackActivated);this.stateManagement.dispatchEvent(e)}else this.cashbackStyles.styleDefaultState(n,h);return h}async handleLinkYourMSAClick(e,t){e.classList.add("activated"),rg.navigateToLinkPage(this.pageHandlerModule);const n=this.cashbackTelemetry.createClickData(i.$S.LinkYourMSAButton,this.moduleName,this.flyoutData.dataStoreModule.CashBackData,this.estimatedCashbackData);this.logModule.LogInfoEvent(i.R.ButtonClick,t,n,Jl.g.CouponImpressionId)}static async navigateToLinkPage(e){e.NavigateToUrl("https://www.msn.com/en-us/feed/personalize/settings?pc=edge")}async handleActivateCashbackClick(e,t,n){e.classList.add("activated"),e.textContent=this.flyoutData.strings.cbActivatedButton,this.cashbackComponents.createActivatedArrowAnimation();const o=this.cashbackTelemetry.createClickData(i.$S.ActivateCashBack,this.moduleName,this.flyoutData.dataStoreModule.CashBackData,this.estimatedCashbackData);this.utilities.isPinterest()?(this.pageHandlerModule.RecordAsUserAction(K.bS.PINTEREST_CASHBACK_ACTIVATED),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PINTEREST_CASHBACK_ACTIVATED,this.flyoutData.common.popupOrigination)):(this.pageHandlerModule.RecordAsUserAction(K.bS.ACTIVATE_CASHBACK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.ACTIVATE_CASHBACK,this.flyoutData.common.popupOrigination)),this.logModule.LogInfoEvent(i.R.ButtonClick,n,o,Jl.g.CouponImpressionId),e.disabled=!0;let a=!1;if(this.flyoutData.common.isCheckoutPage?(this.cashbackStyles.styleProcessingState(e),a=(await this.pageHandlerModule.ActivateRebates(!0)).activated):(this.pageHandlerModule.ActivateRebates(!1),a=!0),a){e?.setAttribute("aria-live","off"),this.flyoutData.dataStoreModule.CashBackData&&(this.flyoutData.dataStoreModule.CashBackData.isCashBackActivated=!0);const t=new CustomEvent(Ku.e1.onCashBackActivated),i=new CustomEvent(Ku.e1.onCashBackActivatedForRewards);this.stateManagement.dispatchEvent(t),this.stateManagement.dispatchEvent(i)}else{const t=new CustomEvent(Ku.e1.onCashbackActivationError,{detail:{cashbackButton:e,slot:e?.parentElement?.slot}});this.stateManagement.dispatchEvent(t)}if(0===t.screenX&&0===t.screenY)if(a){const e=document.querySelector(`#${r.z6.CLOSE}`);e&&e.focus()}else e&&e.focus();else e&&e.focus();if(this.flyoutData.common.openedWith===r.Te.Auto&&this.flyoutData.common.popupOrigination&&Fe.includes(this.flyoutData.common.popupOrigination)){const e=this.pageHandlerModule;setTimeout((()=>{e.DismissPopup()}),4500)}return a}createPrivacyMessage(e="lightweight"){return rg.createPrivacyBlock(e,this.pageHandlerModule,this.utilities,this.flyoutData)}static createPrivacyBlock(e="hypertext",t,i,n){const o=(0,Y.Ux)("span",{id:"divPrivacyMessage",className:"txtSmall"});i.shouldRenderSmallNotification()&&o.classList.add("smallStyles");const r=(0,Y.Ux)("fluent-anchor",{className:"aLinkCb"});r.appearance=e,r.href="#",r.textContent=n.strings.commonMicrosoftRewards,r.addEventListener("click",(()=>{t.NavigateToMicrosoftRewards()}));const a=(0,Y.Ux)("fluent-anchor",{className:"aLinkCb"});a.appearance=e,a.href="#",a.textContent=n.strings.cbPrivacyMessageTerm,a.addEventListener("click",(()=>{t.NavigateToTermsStatementFlyout()}));const s=(0,Y.Ux)("fluent-anchor",{className:"aLinkCb"});return s.appearance=e,s.href="#",s.textContent=n.strings.cbPrivacyMessagePrivacyCookies,s.addEventListener("click",(()=>{t.NavigateToPrivacyCookiesStatement()})),(0,T.B7)(o,n.strings.cbPrivacyMessage,r,a,s),o}isFailedState(){const e=this.flyoutData.dataStoreModule.CashBackData?.activateRebatesStatus;return void 0!==e&&Object.keys(r.FA).some((t=>{if(r.FA[t]===e)return!!t.toString().includes("FAILED")})),!1}}var ag=rg;function sg(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function lg(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?sg(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):sg(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var cg=class{static ShowItemizedCashbackAddToCart(t){const i=e.R.isExperimentActive(f.H.instantAddToCart)||e.R.isExperimentActive(f.H.instantAddToCartExperiment),n=t?.dataStoreModule?.ApiData?.retailerData,o=n?.GetCurrentCheckoutPage(t.common.lastCommittedURL),r=o?.productAddToCartSelector;return Boolean(i&&r&&!(0,p.TF)(r))}static animateText(){const e=document.querySelector("#activatedSign"),t=document.querySelector("#offerEndDate");e?.classList.remove("text-in","text-out"),t?.classList.remove("text-in","text-out"),e.setAttribute("style","display: block;"),setTimeout((()=>{e?.classList.add("text-out")}),1300),setTimeout((()=>{e?.classList.remove("text-in","text-out"),t?.classList.remove("text-in","text-out"),t?.classList.add("text-in"),e.setAttribute("style","display: none;"),t.setAttribute("style","display: block;\n text-align:center;\n padding: 8px;\n display: flex;\n height:20px;\n justify-content: center;\n align-items: center;\n gap: 7px;")}),1500)}static GetActivatedAnimationStyles(){return"\n #activated-animation div {\n\t margin:0;\n\t overflow: hidden;\n }\n\n #activated-animation div div {\n line-height: 35px;\n display: none;\n }\n\n #activated-animation div div.text-in {\n\t display: block;\n\t animation: textIn .5s ease;\n }\n\n #activated-animation div div.text-out {\n\t animation: textOut .5s ease;\n }\n\n @keyframes textIn {\n 0% {\n transform: translateY(100%);\n }\n\n\t 100% {\n\t\t transform: translateY(0%);\n\t }\n }\n\n @keyframes textOut{\n\t 0% {\n\t\t transform: translateY(0%);\n\t }\n\t 100% {\n\t\t transform: translateY(-100%);\n\t }\n }\n "}static async hasInstantAddToCartConsent(e){const t=!!await e.getStorageBool(Ce.Q.GroceryInstantAddToCart);return t&&e.setStorageBool(Ce.Q.GroceryInstantAddToCart,!1),t}static IsInstantAddToCartShowConsent(t,i,n){const o=e.R.isExperimentActive(f.H.instantAddToCart)||e.R.isExperimentActive(f.H.instantAddToCartExperiment);return i&&o&&!n&&"amazon.com"===t.common.domain}static IsSpbInstantATCExpEnabled(t){const i=t.common.domain;return(e.R.isExperimentActive(f.H.instantAddToCart)||e.R.isExperimentActive(f.H.instantAddToCartExperiment))&&"amazon.com"===i}static IsSpbAutoActivateExpEnabled(){return e.R.isExperimentActive(f.H.spbAutoActivationOnSearch)||e.R.getServiceExperimentValue(f.H.spbSearchAutoActivation)}static HandleAddToCartButton(e,t,n,o,r,a,s,l,c){const d=n.dataStoreModule.CashBackData,u=this.addToCartDataHandler(t,n,s);if(s===i.e4.SPBActivatedNotification)e.classList.add("lateralMargin"),e.style.marginBottom="10px",e.textContent=n.strings.itemizedCashBackSpbAddToCart;else if(s===i.e4.SPBpdpExactMatchNotification)e.className="icActionButton",e.textContent=n.strings.gcOkButtonText;else if(s===i.e4.ActivatedNotification)e.textContent=n.strings.itemizedCashBackSpbAddToCart,e.className="icActionButton",e.style.fontSize="15px";else{const t=u?.value||void 0,i=t?(0,T.fZ)("itemizedCashBackAddToCart",n.strings.itemizedCashBackAddToCart,`$${t}`):n.strings.itemizedCashBackSpbAddToCart;e.textContent=i,e.style.marginLeft="auto",e.style.marginRight="auto"}return d?.isSignInSupportedDomainCashBack&&d?.isLinkYourMSAWorkflow&&d?.isLinkingEnabledForSPB?(e.textContent=n.strings.pcbLinkMsaActivateButton,e.addEventListener("click",(e=>{ag.navigateToLinkPage(a)})),r.LogICSpecificTelemetry(i.xu.AadUserLinking,"AAD linking on add to cart",s??"",{cashbackData:d})):e.addEventListener("click",(e=>{e.stopPropagation(),c&&c(),r.LogButtonClickICSpecificTelemetry(i.$S.ItemizedCashBackAddToCartButton,K.bS.ITEMIZED_CASHBACK_ADD_TO_CART,"Itemized Cash Back Add To Cart click",s??"",{itemCashBackData:u}),this.addToCartMessagingHandler(u,a)})),e}static addToCartMessagingHandler(e,t){try{t.StartEdgeDriver(JSON.stringify({action:eg.v.ItemizedCashbackAddToCart,data:lg({},e)}))}catch(e){}}static addToCartDataHandler(e,t,i){const n=new class{constructor(){(0,s.Z)(this,"value",void 0),(0,s.Z)(this,"id",void 0),(0,s.Z)(this,"description",void 0),(0,s.Z)(this,"brand",void 0),(0,s.Z)(this,"expiryDate",void 0),(0,s.Z)(this,"minQty",void 0),(0,s.Z)(this,"source",void 0),(0,s.Z)(this,"productUrl",void 0),(0,s.Z)(this,"productId",void 0),(0,s.Z)(this,"domain",void 0),(0,s.Z)(this,"isSpbOverlay",void 0),(0,s.Z)(this,"renderedPageType",void 0),(0,s.Z)(this,"quotientProductDetails",void 0),(0,s.Z)(this,"spbProductDetails",void 0),(0,s.Z)(this,"pcbProductDetails",void 0)}};if(t){const e=t.dataStoreModule?.SPBItemizedCashbackData?.domainData,o=(0,Ie.en)(t.common.lastCommittedURL);if(e&&o){const t=(0,Ie.xJ)(o,e);n.productId=t.productId}n.productUrl=t.common.lastCommittedURL,n.domain=t.common.domain,n.renderedPageType=i}return void 0!==e.cashbackProducts?(n.value=e?.offerValue,n.id=e?.id,n.description=e?.description,n.expiryDate=e?.expiryDate,n.minQty=e?.minQty,n.source=e?.source,n.quotientProductDetails=e?.cashbackProducts.find((e=>e.url===n.productUrl))):void 0!==e.adsOffer?(n.value=e?.value,n.id=e?.id,n.description=e?.description,n.expiryDate=e?.expiryDate,n.minQty=e?.minQty,n.source=e?.source,n.spbProductDetails=e?.adsOffer):void 0!==e.adsCashback&&(n.value=e?.commissionValue,n.id=e?.offerId,n.description=e?.scope,n.pcbProductDetails=e?.adsCashback[0]),n}},dg=o(18491);function ug(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function hg(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?ug(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):ug(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var pg=class{constructor(e,t,i){(0,s.Z)(this,"textAndImageContainerClassName","icTextAndImageContainer"),(0,s.Z)(this,"showDiscountMin",5),(0,s.Z)(this,"assetsItemizedCashback",void 0),(0,s.Z)(this,"gcMainRoot","gcMainRootSpbCard"),(0,s.Z)(this,"gcMainBody","gcMainBodySpbCard"),(0,s.Z)(this,"gcMainContent","gcMainContentSpbCard"),(0,s.Z)(this,"gcActivatedContainer","gcActivatedContainer"),(0,s.Z)(this,"gcActivateBtnId","gcActivateBtn"),(0,s.Z)(this,"gridAndImageContainerClassName","icGridAndImageContainerClassName"),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"telemetryHandler",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"isDarkMode",!1),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"OnNewSearchResultsSpbOrQt",(async(e,t,i,n,o)=>{const{newOffersQt:r,newOffers:a,visibilityFeedbackUrl:s}=await this.ProcessNewSearchData(e,this.storageHandler,t,i,"",n,!0,!0);let l=[];const c=document.querySelector("#icOffersFeed");if(c&&c.remove(),0===r.length&&0===a.length)return{spbOffersWrapper:void 0,offersCount:0,formattedOffers:l};this.utilities.applyStyles(this.flyoutData.common.shopping,this.assetsItemizedCashback.getStyles(),void 0,this.assetsItemizedCashback.getDarkModeStyles());const d=this.CreateGCSectionWrapper("icOffersFeed");d.style.marginTop="20px";const u=this.CreateGCSectionList();this.AddGridStyling(u);let h=0;const p=(0,Y.Ux)("div");p.className="searchTitleContainer";const g=(0,Y.Ux)("p",void 0,this.flyoutData.strings.gcbSectionTitle);if(g.className="searchTitleText",p.appendChild(g),d.appendChild(p),a.length>0){const e=this.CreateSponsoredElement("");e.className="isSponsoredIconContainer",p.appendChild(e),h=a.length,l=this.transformSpbResponse(a);for(const e of a){const t=this.CreateSPBGridCard(e,"",!1,!1,!0,s);u.appendChild(t)}this.CreateAndSendVisibilityFeedbackUrl(a,s,!1)}else if(r.length>0){h=r.length,l=this.transformQtResponse(r);for(const e of r){const t=o.CreateGridCard(e,"",!1,!0);u.appendChild(t)}}return d.appendChild(u),{spbOffersWrapper:d,offersCount:h,formattedOffers:l}})),this.flyoutData=e,this.commonAssets=i,this.utilities=t.viewModulesUtilities,this.isDarkMode=this.utilities.isDarkMode(),this.telemetryHandler=t.telemetryHandler,this.pageHandlerModule=t.pageHandlerModule,this.assetsItemizedCashback=new Qp,this.storageHandler=t.storageHandler}CreateSPBGridCard(e,t,n,o,r=!1,a,s={},l=i.xu.SPBOfferCardClick,c=i.xu.SPBOfferCardHover){const d=!1,u=this.GetPriceData(e);e.visibilityFeedbackUrlBase||(e.visibilityFeedbackUrlBase=a);const{rootDiv:h,wrapper:p,content:g}=Np("gcGridCardRoot","gcGridCardMainBody","gcGridCardContent",this.isDarkMode,d,!0,!0,(()=>{this.addIcTelemetry(t,l,"",e.source,!1,n,hg({isFromSearchBar:o,offerId:e.id,destUrl:e.adsOffer.destinationUrl,isFromMainSearchBar:r,offerItem:e.adsOffer},s)),this.activateCashbackHandler(e,t,!1,!0,d,n)}),(()=>{this.addIcTelemetry(t,c,"",e.source,!1,n,hg({isFromSearchBar:o,isFromMainSearchBar:r},s))}));h.style.padding="0",h.style.height="100%",p.style.padding="0",p.style.height="100%",g.style.padding="12px",g.style.height="100%",g.title=e.adsOffer.name;const f=(0,Y.Ux)("DIV");f.className="gcTextContainer",f.style.color=this.isDarkMode?"#ffffff":"#222222",f.style.width="100%";const m=this.CreatePricesContainer(u.listPrice,u.finalPrice),v=Mp(this.isDarkMode,e.adsOffer.name);if(v.className="icDescriptionTextGridCard",f.appendChild(m),u.cashbackValue.amount>0){const e=(0,Y.Ux)("DIV",{style:"\n display: flex;\n gap: 5px;\n "}),t=Pp(`$${u.cashbackValue.amount} ${this.flyoutData.strings.gcBack}`,"\n font-weight: 400;\n font-size: 12px;\n line-height: 16px;\n ",!1,20);t.className="gcCouponContainer";const i=(0,Y.Ux)("p",void 0,this.flyoutData.strings.gcAfter);i.className="icAfterText",e.appendChild(i),e.appendChild(t),f.appendChild(e)}f.appendChild(v);const y=this.createCashImageInWrapper(d,e.imageUrl),C=(0,Y.Ux)("DIV");return C.className=this.gridAndImageContainerClassName,C.appendChild(y),C.appendChild(f),g.appendChild(C),h}createCommissionArrow(e,t,i){const n=(0,Y.Ux)("div",{className:"imgCBTag"});n.innerHTML=i?eh.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="9" height="20" viewBox="0 0 9 20" fill="none">
<path d="M3.47164 18.7076C2.91129 19.517 1.9895 20 1.00506 20H0.5V0H1.00506C1.9895 0 2.91129 0.482975 3.47164 1.29237L8.31779 8.29237C9.02902 9.3197 9.02903 10.6803 8.31779 11.7076L3.47164 18.7076Z" fill="#3267FA"/>
</svg>`:eh.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="14" height="28" viewBox="0 0 14 28" fill="none">
<path d="M5.11245 26.0697C4.16517 27.2876 2.70864 28 1.16569 28H0.5V0H1.16569C2.70865 0 4.16517 0.712362 5.11245 1.9303L12.1125 10.9303C13.5168 12.7359 13.5168 15.2642 12.1125 17.0697L5.11245 26.0697Z" fill="#3267FA"/>
</svg>`,n.setAttribute("aria-hidden","true"),n.style.float="left",n.style.display="block";const o=(0,Y.Ux)("span",{role:"group"});o.className=i?"spanCommissionValueSmall":"spanCommissionValue";const r=(0,Y.Ux)("div",{className:"divCommissionValue"});if(r.append(o,n),e){const t=(0,Y.Ux)("span");t.textContent="$",t.style.fontSize=i?"8px":"10px",t.style.position="relative",t.style.bottom="0.3ex";const n=`${e}`.split(".");1===n.length&&n.push("00");const r=(0,Y.Ux)("span");r.style.fontSize=i?"12px":"16px",r.textContent=n[0];const a=(0,Y.Ux)("span");a.textContent=n[1],a.style.fontSize=i?"8px":"10px",a.style.position="relative",a.style.bottom="0.3ex",o.append(t,r,a),o.setAttribute("aria-label",`${t.textContent}${n[0]}.${n[1]}`)}return r}createElementForOfferV6Card(e,t,i,n,o,r,a,s){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assetsItemizedCashback.getStyles()+this.assetsItemizedCashback.getVariant6Styles(),void 0,this.assetsItemizedCashback.getDarkModeStyles()+this.assetsItemizedCashback.getVariant6DarkModeStyles());const{rootDiv:l,content:c,wrapper:d}=this.commonSetUp(e,t,i,a,r,s);if(e.isActivated)return this.GetActivatedSpbOfferUx(e,r,c),{rootDiv:l,content:c,wrapper:d};const u=this.GetPriceData(e),h=u.discount.amount>this.showDiscountMin,p=(0,Y.Ux)("DIV");if(p.className="icTextContainer",h){const e=Sp(this.flyoutData,`${u.discount.toDisplay} ${this.flyoutData.strings.gcOff}`);e.className="icPercentOff",c.style.position="relative",c.appendChild(e)}const g=(0,Y.Ux)("div");g.className="icCashbackContainer";const f=(0,Y.Ux)("p",void 0,u.cashbackValue.toDisplay);f.className="icCashbackValueText";const m=(0,Y.Ux)("p",void 0,this.flyoutData.strings.gcAfterCashBack);m.className="icCashbackText";const v=(0,Y.Ux)("p",void 0,this.flyoutData.strings.gcSave);v.className="icCashbackSaveText",g.appendChild(v),g.appendChild(f),g.appendChild(m);const y=(0,Y.Ux)("div");y.className="icCashbackAdsHeaderContainer";const C=this.CreateAdsIcon(),b=(0,Y.Ux)("div");b.className="icCashbackAdsHeaderTextContainer";const S=(0,Y.Ux)("span");S.className="icCashbackDomainNameSpan";const x=this.flyoutData.common.domain.split(".")[0],T=(0,Y.Ux)("span",void 0,x);S.appendChild(T);const w=(0,Y.Ux)("span",void 0,this.flyoutData.strings.gcAdsHeader);b.appendChild(w),b.appendChild(S),y.appendChild(b),y.appendChild(C),p.appendChild(g);const O=this.createCashImageInWrapper(!0,e.imageUrl);O.title=e.adsOffer.name,O.style.flex="1";const P=(0,Y.Ux)("DIV");P.className=this.textAndImageContainerClassName,P.appendChild(O),P.appendChild(p);const A=this.CreateActionButton(u.cashbackValue.toDisplay,e,n,o,r,t),E=Mp(this.isDarkMode,e.adsOffer.name,1);return E.className="icNotificationDescriptionText",c.appendChild(y),c.appendChild(P),c.appendChild(E),c.appendChild(A),{rootDiv:l,content:c,wrapper:d}}createElementForSecondaryOffer(e,t,n,o,r){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assetsItemizedCashback.getStyles()+this.assetsItemizedCashback.getSecondaryOfferStyles(),void 0,this.assetsItemizedCashback.getDarkModeStyles()+this.assetsItemizedCashback.getSecondaryOfferDarkModeStyles());const a=(0,Y.Ux)("div");a.className="icSecOfferContainer";const s=Ep(e.imageUrl,84,84);s.className="icSecOfferImage",a.appendChild(s);const l=(0,Y.Ux)("div");l.className="icSecOfferTextContainer";const c=Mp(this.isDarkMode,e.adsOffer.name);c.className="icDescriptionText",l.appendChild(c);const d=(0,Y.Ux)("div");d.className="icSecOfferValueTextContainer";const u=this.GetPriceData(e),h=(0,Y.Ux)("p",void 0,u.cashbackValue.toDisplay);h.className="icSecOfferCashbackValueText";const p=(0,Y.Ux)("p",void 0,(0,T.fm)(this.flyoutData.strings.cbFeatureName));p.className="icSecOfferCashbackText",d.appendChild(h),d.appendChild(p),l.appendChild(d),a.appendChild(l),a.addEventListener("click",(i=>{i.stopPropagation(),this.activateCashbackHandler(e,t,r,o,!0)}));const g=i.xu.SPBActivateButtonHover,f=()=>{this.addIcTelemetry(t,g,"Button name: secondary offer card",e.source,!1),a.removeEventListener("mouseover",f)};return a.addEventListener("mouseover",f),a}createElementForOfferV2Card(e,t,i,n,o,r,a,s=!1){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assetsItemizedCashback.getStyles()+this.assetsItemizedCashback.getVariant2Styles(),void 0,this.assetsItemizedCashback.getDarkModeStyles()+this.assetsItemizedCashback.getVariant2DarkModeStyles());const{rootDiv:l,content:c,wrapper:d}=this.commonSetUp(e,t,i,a,r);if(e.isActivated)return this.GetActivatedSpbOfferUx(e,r,c),{rootDiv:l,content:c,wrapper:d};const u=this.GetPriceData(e),h=u.discount.amount>this.showDiscountMin,p=(0,Y.Ux)("DIV");if(p.className="icTextContainer",h){const e=Sp(this.flyoutData,`${u.discount.toDisplay} ${this.flyoutData.strings.gcOff}`);e.className="icPercentOff",c.style.position="relative",c.appendChild(e)}const g=(0,Y.Ux)("div");g.className="icCashbackContainer";const f=(0,Y.Ux)("p",void 0,u.cashbackValue.toDisplay);f.className="icCashbackValueText";const m=(0,Y.Ux)("p",void 0,(0,T.fm)(this.flyoutData.strings.cbFeatureName));m.className="icCashbackText",g.appendChild(f),g.appendChild(m);const v=this.CreateAdsIconWithText();p.appendChild(v),p.appendChild(g);const y=this.createCashImageInWrapper(!0,e.imageUrl);y.title=e.adsOffer.name,y.style.flex="1";const C=(0,Y.Ux)("DIV");if(C.className=this.textAndImageContainerClassName,C.appendChild(y),C.appendChild(p),c.appendChild(C),s&&cg.ShowItemizedCashbackAddToCart(this.flyoutData)&&this.flyoutData.dataStoreModule.SPBItemizedCashbackData?.isSpbAddToCartEnabled){const i=(0,Y.lw)(this.utilities);i.className="icAddToCartSpbBtn",cg.HandleAddToCartButton(i,e,this.flyoutData,this.utilities,this.telemetryHandler,this.pageHandlerModule,t,"",(()=>{this.activateCashbackHandler(e,t,n,!1,r)})),c.appendChild(i)}else{const i=this.CreateActionButton(u.cashbackValue.toDisplay,e,n,o,r,t);c.appendChild(i)}return r||this.SetStyleForContent(c),{rootDiv:l,content:c,wrapper:d}}createElementForSpbCheckOutNotification(e,t,i,n,o,r,a,s){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assetsItemizedCashback.getStyles()+this.assetsItemizedCashback.getVariantAutoActivate(),void 0,this.assetsItemizedCashback.getDarkModeStyles()+this.assetsItemizedCashback.getVariant2DarkModeStyles());const{rootDiv:l,content:c,wrapper:d}=this.commonSetUp(e[0],t,i,a,r),u=this.GetCheckoutTotalPriceData(e,t),h=(0,Y.Ux)("DIV");h.className="icTextContainer";const p=(0,Y.Ux)("div");p.className="icCashbackContainer";const g=this.createCommissionArrow(u.cashbackValue.amount,!1);g.className="gcCouponContainer",g.style.marginTop="6px",g.style.marginTop="6px";const f=(0,Y.Ux)("p",{style:`\n color: ${this.isDarkMode?"#ffffff":"#1A1A1A"};\n `},(0,T.fm)(this.flyoutData.strings.cbFeatureName));f.className="icCashbackText";const m=(0,Y.Ux)("IMG");m.src=this.flyoutData.common.resourcesEndpoint+"/common/infoIcon.svg",m.className="infoIcon",m.setAttribute("aria-hidden","true"),f.appendChild(m),p.appendChild(f),p.appendChild(g);const v=this.CreateAdsIcon();h.appendChild(v),h.appendChild(p);const y=this.createCashImageInWrapper(!0,e[0].imageUrl);y.title=e[0].adsOffer.name,y.style.position="relative",y.style.flex="1";const C=(0,Y.Ux)("DIV");C.className=this.textAndImageContainerClassName,C.style.marginBottom="2px",C.style.cursor="pointer",C.appendChild(h),C.appendChild(y),c.appendChild(C);const b=(0,Y.Ux)("div");return b.className="icMessageContainer",b.appendChild(this.createActivatedButton()),c.appendChild(b),{rootDiv:l,content:c,wrapper:d}}createElementForOfferSpbPdpExactMatch(e,t,n,o,r,a,s,l){const{rootDiv:c,content:d,wrapper:u}=this.createAutoActivateOfferBody(e,t,n,o,r,a,s,l);if(cg.ShowItemizedCashbackAddToCart(this.flyoutData)){const t=(0,Y.lw)(this.utilities);t.id=this.gcActivateBtnId,cg.HandleAddToCartButton(t,e,this.flyoutData,this.utilities,this.telemetryHandler,this.pageHandlerModule,i.e4.SPBpdpExactMatchNotification),d.appendChild(t)}return a||this.SetStyleForContent(d),{rootDiv:c,content:d,wrapper:u}}createAutoActivateOfferBody(e,t,i,n,o,r,a,s){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assetsItemizedCashback.getStyles()+this.assetsItemizedCashback.getVariantAutoActivate(),void 0,this.assetsItemizedCashback.getDarkModeStyles()+this.assetsItemizedCashback.getVariant2DarkModeStyles());const{rootDiv:l,content:c,wrapper:d}=this.commonSetUp(e,t,i,a,r),u=this.GetPriceData(e),h=(0,Y.Ux)("DIV");h.className="icTextContainer";const p=(0,Y.Ux)("div");p.className="icCashbackContainer";const g=this.createCommissionArrow(u.cashbackValue.amount,!1);g.className="gcCouponContainer",g.style.marginTop="6px",g.style.marginTop="6px";const f=(0,Y.Ux)("p",{style:`\n color: ${this.isDarkMode?"#ffffff":"#1A1A1A"};\n `},(0,T.fm)(this.flyoutData.strings.cbFeatureName));f.className="icCashbackText";const m=(0,Y.Ux)("IMG");m.src=this.flyoutData.common.resourcesEndpoint+"/common/infoIcon.svg",m.className="infoIcon",m.setAttribute("aria-hidden","true"),f.appendChild(m),p.appendChild(f),p.appendChild(g);const v=this.CreateAdsIcon(),y=(0,Y.Ux)("p",{style:`\n color: ${this.isDarkMode?"#ffffff":"#1A1A1A"};\n `},e.adsOffer.name);y.className="icDescriptionTextGridCard",h.appendChild(v),h.appendChild(p),h.appendChild(y);const C=this.createCashImageInWrapper(!0,e.imageUrl);C.title=e.adsOffer.name,C.style.position="relative",C.style.flex="1";const b=(0,Y.Ux)("DIV");b.className="priceIcon";const S=(0,Y.Ux)("SPAN");S.className="priceText",S.textContent=s?`$${s}`:`${u?.listPrice?.toDisplay}`,b.appendChild(S),C.appendChild(b);const x=(0,Y.Ux)("DIV");x.className=this.textAndImageContainerClassName,x.style.marginBottom="2px",x.style.cursor="pointer",x.addEventListener("click",(i=>{i.preventDefault(),this.activateCashbackHandler(e,t,!1,!0,r,!1,!0)})),x.appendChild(h),x.appendChild(C),c.appendChild(x);const w=cg.IsSpbInstantATCExpEnabled(this.flyoutData)?this.flyoutData.strings.itemizedCashBackSpbAutoATC:this.flyoutData.strings.itemizedCashBackSpbAutoActivate,O=(0,Y.Ux)("div");O.className="icMessageContainer";const P=(0,Y.Ux)("p",void 0,w);return P.className="icMessageText",P.style.fontSize="12px",P.style.textAlign="center",P.style.fontWeight="bold",O.appendChild(P),c.appendChild(O),{rootDiv:l,content:c,wrapper:d}}createElementForOfferAutoActivateCard(e,t,i,n,o,r,a){const{rootDiv:s,content:l,wrapper:c}=this.createAutoActivateOfferBody(e,t,i,n,o,r,a),d=this.GetPriceData(e),u=this.CreateActionButton(d.cashbackValue.toDisplay,e,!1,o,!0,t,!0);return u.style.borderTopStyle="none",l.appendChild(u),r||this.SetStyleForContent(l),{rootDiv:s,content:l,wrapper:c}}commonSetUp(e,t,i,n,o,r){let a=e.visibilityFeedbackUrlBase;e.visibilityFeedbackUrlBase||(a=n);const s=r?[e,...r]:[e];this.CreateAndSendVisibilityFeedbackUrl(s,a,o,t);const l=i?()=>{this.addIcTelemetry(t,i,o?"GroceryOfferCardNotification":"GroceryOfferCard",e.source,!1)}:void 0,c=Np(this.gcMainRoot,this.gcMainBody,this.gcMainContent,this.isDarkMode,!0,!1,void 0,void 0,l);return c.wrapper.style.paddingBottom="0px",c}CreateActionButton(e,t,i,n,o,r,a=!1){const s=this.makeActivatedContainer(a),l=this.MakeButton(r,t,e,i,n,o,a);return s.appendChild(l),s}CreateAdsIcon(){const e=(0,Y.Ux)("div");e.className="adsIconContainer";const t=(0,Y.Ux)("p",void 0,this.flyoutData.strings.gcAd);return t.className="adsIcon",e.appendChild(t),e}CreateAdsIconWithText(){const e=(0,Y.Ux)("div");e.className="adsIconContainer";const t=(0,Y.Ux)("p",void 0,this.flyoutData.strings.gcAd);t.className="adsIcon";const i=_p(this.flyoutData.strings.gcTopDeal);return i.style.textTransform="unset",e.appendChild(t),e.appendChild(i),e}GetSpbConfirmationScreenUx(e,t,i){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assetsItemizedCashback.getConfirmationPageAssets(),void 0,this.assetsItemizedCashback.getConfirmationPageAssetsDarkMode());const{rootDiv:n,wrapper:o,content:r}=Np(this.gcMainRoot+"Confirmation",this.gcMainBody+"Confirmation",this.gcMainContent+"Confirmation",this.isDarkMode,e,!e),a=()=>{this.addIcTelemetry(t,i,"SpbConfirmationNotification",void 0,void 0),n.removeEventListener("mouseover",a)};n.addEventListener("mouseover",a);const s=(0,Y.Ux)("DIV");s.className="imageIcon",s.style.display="flex",s.style.alignContent="center",s.setAttribute("aria-hidden","true"),s.innerHTML=eh.Z.getTrustedHTML`<svg width="20" height="18" viewBox="0 0 20 18" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M2.7999 3.59998C2.7999 1.94312 4.14305 0.599976 5.7999 0.599976H16.5999C18.2568 0.599976 19.5999 1.94312 19.5999 3.59998V12C19.5999 13.6568 18.2568 15 16.5999 15H5.7999C4.14305 15 2.7999 13.6568 2.7999 12V3.59998ZM10.8957 8.91714L3.9999 5.35318V12C3.9999 12.9941 4.80579 13.8 5.7999 13.8H16.5999C17.594 13.8 18.3999 12.9941 18.3999 12V5.35558L11.5041 8.91714L11.4069 8.96316C11.24 9.02452 11.0522 9.00918 10.8957 8.91714ZM16.5999 1.79998H5.7999C4.80579 1.79998 3.9999 2.60586 3.9999 3.59998V3.96118L11.1999 7.70387L18.3999 3.96238V3.59998C18.3999 2.60586 17.594 1.79998 16.5999 1.79998ZM14.1999 17.4C15.1814 17.4 16.0528 16.9286 16.6001 16.2H5.7999C3.48031 16.2 1.5999 14.3196 1.5999 12V3.59997C0.871234 4.1473 0.399902 5.01848 0.399902 5.99997V12C0.399902 14.9823 2.81757 17.4 5.7999 17.4H14.1999Z" fill="#1A1A1A"/>
</svg>`;const l=(0,Y.Ux)("p",void 0,this.flyoutData.strings.instantcbRefresh);l.className="earningText";const c=(0,Y.Ux)("DIV");c.className="emailContainer";const d=(0,Y.Ux)("DIV");d.className="emailIconContainer",d.appendChild(s);const u=(0,Y.Ux)("p",void 0,this.flyoutData.strings.gcConfirmationTextSpb);u.className="emailText",c.appendChild(d),c.appendChild(u);const h=this.CreateTrackCashbackButton(t,ve.h.Unknown,e);return r.appendChild(l),r.appendChild(c),r.appendChild(h),e||this.SetStyleForContent(r),{rootDiv:n,wrapper:o,content:r}}addIcTelemetry(e,t,i,n,o,r=!1,a={}){const s=void 0!==o?{isActivated:o}:{},l=hg(hg({itemSource:n??ve.h.Unknown,isRecentlySeenOffer:r},s),a);this.telemetryHandler.LogICSpecificTelemetry(t,i,e,l)}GetCheckoutTotalPriceData(e,t){const i=new Intl.NumberFormat("en-US",{style:"currency",currency:"USD"}),n={cashbackValue:{amount:0,toDisplay:""},discount:{amount:0,toDisplay:""},finalPrice:{amount:0,toDisplay:""},listPrice:{amount:0,toDisplay:""},salePrice:{amount:0,toDisplay:""}};let o=0,r=0,a=0;return e.forEach((e=>{const i=e?.adsOffer,n=i?.price;a+=i?.discountedPrice?i.discountedPrice:n,o+=i.promotionInformation.rebateValue,r+=n,this.makeBackgroundActivation(e,t)})),n.cashbackValue.amount=o,n.cashbackValue.toDisplay=i.format(o),n.salePrice.amount=a,n.salePrice.toDisplay=i.format(a),n.listPrice.amount=r,n.listPrice.toDisplay=i.format(r),n}GetPriceData(e){const t=e?.adsOffer,i=new Intl.NumberFormat("en-US",{style:"currency",currency:"USD"}),n=t?.price,o=t?.discountedPrice?t.discountedPrice:n,r={cashbackValue:{amount:t?.promotionInformation?.rebateValue,toDisplay:i.format(t?.promotionInformation?.rebateValue)},discount:{amount:0,toDisplay:""},finalPrice:{amount:0,toDisplay:""},listPrice:{amount:n,toDisplay:i.format(n)},salePrice:{amount:o,toDisplay:i.format(o)}};return r.finalPrice.amount=r.salePrice.amount-r.cashbackValue.amount,r.finalPrice.amount<0&&(r.finalPrice.amount=0),r.discount.amount=r.listPrice.amount>0?100-100*r.finalPrice.amount/r.listPrice.amount:0,r.finalPrice.toDisplay=i.format(r.finalPrice.amount),r.discount.toDisplay=`${r.discount.amount?.toFixed(0)}%`,r}CreateSponsoredElement(e){return this.flyoutData.dataStoreModule.SPBItemizedCashbackData?.isRecentlyViewedSpbEnabled?this.CreateSponsoredTextV2(e):this.CreateSponsoredText(this.flyoutData,this.pageHandlerModule,this.telemetryHandler,this.isDarkMode,e,ve.h.SPB)}createCashImageInWrapper(e,t){const i=e?116:120,n=Ep(t,i,i);n.className="icImageContainer";const o=(0,Y.Ux)("div");return o.className="icImageContainerWrapper",o.appendChild(n),o}SendSPBViewedLog(e,t,n=""){try{let o="pane";t&&(o="notification");const r=(0,Ie.en)(e),a={rGuid:{rg:r?r.searchParams?.get("rg"):""}??"",visiblityUrl:{visiblityUrl:e},viewedAt:{viewedAt:o}};this.addIcTelemetry(n,i.xu.ICSPBVisibilityFeedback,"Sent visibility feedback url",void 0,!1,!1,a)}catch(e){}}CreateSearchBar(e){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assetsItemizedCashback.getSearchBarAssets(),void 0,this.assetsItemizedCashback.getSearchBarDarkModeAssets());const t=(0,Y.Ux)("form");t.className="icSearchBarContainer";const i="search",n=(0,Y.Ux)("input");n.id="icSearchBox",n.className="icSearchBar";const o=(0,T.fZ)("gcbSearchSectionTitle",this.flyoutData.strings.gcSearchBarPlaceholder,this.flyoutData.common.domain);n.placeholder=o,n.type="text",n.name=i;const r=((e,t)=>{const i=(0,Y.Ux)("fluent-button");i.ariaLabel=e.strings.commonClear,i.title=e.strings.commonClear;const n=(0,Y.Ux)("DIV");return n.style.display="flex",n.style.alignContent="center",n.setAttribute("aria-hidden","true"),n.innerHTML=eh.Z.getTrustedHTML`<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M8 0C12.4183 0 16 3.58172 16 8C16 12.4183 12.4183 16 8 16C3.58172 16 0 12.4183 0 8C0 3.58172 3.58172 0 8 0ZM5.80943 5.11372C5.61456 4.97872 5.34514 4.99801 5.17157 5.17157L5.11372 5.24082C4.97872 5.43569 4.99801 5.70511 5.17157 5.87868L7.29289 8L5.17157 10.1213L5.11372 10.1906C4.97872 10.3854 4.99801 10.6549 5.17157 10.8284L5.24082 10.8863C5.43569 11.0213 5.70511 11.002 5.87868 10.8284L8 8.70711L10.1213 10.8284L10.1906 10.8863C10.3854 11.0213 10.6549 11.002 10.8284 10.8284L10.8863 10.7592C11.0213 10.5643 11.002 10.2949 10.8284 10.1213L8.70711 8L10.8284 5.87868L10.8863 5.80943C11.0213 5.61456 11.002 5.34514 10.8284 5.17157L10.7592 5.11372C10.5643 4.97872 10.2949 4.99801 10.1213 5.17157L8 7.29289L5.87868 5.17157L5.80943 5.11372Z" fill="#767676"/>
</svg>`,i.appearance="stealth",i.appendChild(n),i})(this.flyoutData);r.className="icClearIcon",r.addEventListener("click",(e=>{e.preventDefault(),n.value=""}));const a=((e,t)=>{const i=(0,Y.Ux)("fluent-button");i.ariaLabel=e.strings.commonSearch,i.title=e.strings.commonSearch;const n=(0,Y.Ux)("DIV");return n.style.display="flex",n.style.alignContent="center",n.setAttribute("aria-hidden","true"),n.innerHTML=eh.Z.getTrustedHTML`<svg width="14" height="14" viewBox="0 0 14 14" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M5.5 0C8.53757 0 11 2.46243 11 5.5C11 6.83879 10.5217 8.06586 9.72656 9.01962L13.8536 13.1464C14.0488 13.3417 14.0488 13.6583 13.8536 13.8536C13.68 14.0271 13.4106 14.0464 13.2157 13.9114L13.1464 13.8536L9.01962 9.72656C8.06586 10.5217 6.83879 11 5.5 11C2.46243 11 0 8.53757 0 5.5C0 2.46243 2.46243 0 5.5 0ZM5.5 1C3.01472 1 1 3.01472 1 5.5C1 7.98528 3.01472 10 5.5 10C7.98528 10 10 7.98528 10 5.5C10 3.01472 7.98528 1 5.5 1Z" fill="#1A1A1A"/>
</svg>`,i.appearance="stealth",i.appendChild(n),i})(this.flyoutData);return a.className="icSearchIcon",a.type="submit",t.addEventListener("submit",(async t=>{t.preventDefault();const n=t.target?new FormData(t.target):void 0,o=n?.get(i)||"";if(o){const t=o.toString(),i=(new Date).getTime(),n=await this.GetSearchResults(t,dg.x.SearchInPane),r=(new Date).getTime();await e(n,i,r,t)}})),t.appendChild(a),t.appendChild(n),t.appendChild(r),t}CreateSubTitle(e,t,i){const n=this.GetSearchTitleElement(e,i||t);return n?(n.className="icSubTitle",n):null}GetSearchTitleElement(e,t){if(t&&e!==i.e4.SPBPdpPage){const e=(0,Y.Ux)("p"),i=(0,Y.Ux)("span",void 0,t);return i.className="icSubtitleQuery",(0,T.B7)(e,this.flyoutData.strings.gcbSearchSectionTitle,i),e}return null}CreateAndSendVisibilityFeedbackUrl(e,t,i,n=""){if(0===e.length||!t)return;const o=this.CreateVisibilityFeedbackUrl(e,t);this.SendVisibilityUrl(o),this.SendSPBViewedLog(t,i,n)}async ProcessNewSearchData(e,t,n,o,r,a,s,l){let c=[],d=[],u="";const h={latencyData:{sentTimeMs:n,receivedTimeMs:o},isSearchBarOffers:!0,responseData:e,userInfo:this.flyoutData.dataStoreModule.UserInfo,query:a};let p=ve.h.Unknown;try{let t=!1;const n=e?.itemizedCashBackResponse?.offersType===ve.h.SPB,o=e?.itemizedCashBackResponse?.offersType===ve.h.Quotient,a=!1;if(n&&s){p=ve.h.SPB;const i=(0,Ie.Sq)(e),n=this.flyoutData.dataStoreModule.CashBackData?.personalizedCashback,o=(0,Ie.rP)(i,n),r=(0,Ie.wu)(e);t=o?.length>0,u=r,c=o??[]}else if(o&&l){const i=yt.Z.CreateFromUAPIList(e.itemizedCashBackResponse.offers),n=await(0,we.eD)(this.flyoutData,this.storageHandler),o=i?.filter((e=>!n.has(e.id)));p=ve.h.Quotient,d=o??[],t=o?.length>0}const g=t?"Show offers from search bar query":a?"No non activated offers from search bar query":"No offers in search bar response";this.addIcTelemetry(r,i.xu.ICSPBOfferSearchBar,g,p,!1,!1,h)}catch(e){this.addIcTelemetry(r,i.xu.ICSPBOfferSearchBar,"Error in ProcessNewSearchData",p,!1,!1,hg({error:e},h))}return{visibilityFeedbackUrl:u,newOffers:c,newOffersQt:d,queryFromSearchBar:a}}async GetSearchResults(e,t){const i=this.flyoutData.dataStoreModule.UserInfo,o=this.flyoutData.dataStoreModule.ClientInfo,r={appName:"Edge",buildVersion:o.buildVersion,enabledfeatures:[],Muid:this.flyoutData.common.muid},a={ageGroup:i.ageGroup,clientContext:r,consentCanPrompt:this.flyoutData.dataStoreModule.SANConsentData.PersonalizationInContextCanPrompt??!1,domainName:this.flyoutData.common.domain,isAADSignedIn:i.isAADSignedIn,isAnonymousFlowEnabled:i.isAnonymousFlowEnabled,isPendingTransaction:this.flyoutData.dataStoreModule.GroceryCashbackData?.isPendingCashbackExists??!1,isEdgeProfileRebatesUser:i.isRebatesUser,isOffTheRecord:o.isOffTheRecord,isPersonalizationDataConsentChanged:i.isPersonalizationDataConsentChanged,isPersonalizationDataConsentEnabled:i.isPersonalizationDataConsentEnabled,isPersonalizationDataConsentEnabledV2:i.isPersonalizationDataConsentEnabled,isRebatesEnabled:this.flyoutData.common.isRebatesEnabled,isRebatesUser:i.isRebatesUser,jsVersion:n.W1,pageUrl:this.flyoutData.common.currentUrl,queries:[{keyword:e}],queryType:t},s={headers:{"Content-Type":"application/json",Origin:"chrome-untrusted://shopping"},method:"POST",body:JSON.stringify(a)},l=await fetch("https://www.bing.com/api/shopping/v1/itemizedcashback/search?mkt=en-us",s);return await l.json()}CreateGCSectionWrapper(e){const t=(0,Y.Ux)("DIV");return t.className="icSectionWrapper",t.id=e,this.flyoutData.common.isPane&&(t.style.padding="0px 20px",t.style.marginBottom="10px"),t.setAttribute("role","group"),t}CreateGCSectionList(){const e=(0,Y.Ux)("DIV");return e.id="gcSectionList",this.AddGridStyling(e),e}AddGridStyling(e){e.style.display="grid",e.style.gridTemplateColumns="1fr 1fr",e.style.columnGap=this.flyoutData.common.isPane?"12px":"6px",e.style.rowGap="12px"}makeBackgroundActivation(e,t){const n=this.pageHandlerModule.NavigateToUrlBackgroundWithResult(e.adsOffer.url,e.adsOffer.destinationUrl,!0),o=this;n.then((async n=>{const r=n.result,a=(0,we.rm)(r);if(a){const n=(0,be.sc)(a.destinationUrl,"msclkid"),r=(0,be.sc)(e.adsOffer.url,"ld");o.pageHandlerModule.RefreshDealsResponse(r,n,!1),await x.ZP.Sleep(100),o.pageHandlerModule.UpdateLoadTimeData(),o.telemetryHandler.LogICSpecificTelemetry(i.xu.SPBAutoActivationTriggered,"Auto Activate SPB offer",t,{parsedNavigationResponse:a,offerItem:e??""}),o.pageHandlerModule.RecordAsUserEngagement(q.FV.ACTIVATE_CLICK_SPB_CASHBACK,o.flyoutData.common.popupOrigination)}else o.telemetryHandler.LogIcError("Failed to make background auto activation. SPB response not parsed",void 0,t)})).catch((e=>{o.telemetryHandler.LogIcError("Failed to handle spb response",e,t)}))}transformSpbResponse(e){return e.map((e=>({adType:"SearchResults",title:e.adsOffer.name,seller:this.flyoutData.common.domain,imageInfo:{altText:e.adsOffer.name+" image",sourceImageUrl:e.imageUrl},priceInfo:{price:e.adsOffer.price.toString()??0,priceCurrencySymbol:"$"},globalOfferId:e.id,shippingPrice:0,destination:e.adsOffer.url})))}transformQtResponse(e){return e.map((e=>{const t=e.cashbackProducts[0];return{adType:"SearchResults",title:t.title,seller:this.flyoutData.common.domain,imageInfo:{altText:t.title+" image",sourceImageUrl:t.image},priceInfo:{price:t.price.toString()??0,priceCurrencySymbol:"$"},globalOfferId:e.id,shippingPrice:0,destination:t.url}}))}CreateVisibilityFeedbackUrl(e,t){const i=e.map((e=>e.adsOffer?.impressionToken??"")).filter((e=>!!e));return i.length>0?`${t}&tids=${i.join(",")}`:""}SendVisibilityUrl(e){e&&this.pageHandlerModule.SendVisibilityFeedbBackUrl(e)}CreateSponsoredText(e,t,n,o,r,a,s=!1){const l=(0,Y.Ux)("div");l.className="icSponsoredContainer";const c=e.strings.gcSponsoredTooltip.split("<link_find_out>"),d=e.strings.gcSponsoredTooltip.replace(/<link_find_out>/g,""),u=wp(e,d,c[1],(()=>{n.LogICSpecificTelemetry(i.xu.SponsoredTooltipFindMoreClick,"",r,{itemSource:a}),t.NavigateToUrl("https://choice.microsoft.com")}),(()=>{n.LogICSpecificTelemetry(i.xu.SponsoredTooltipHover,"",r,{itemSource:a})}),!1);if(u.width="270px",u.caratTopOffset="0px",u.caratSide=gd.W.Right,!s){const t=(0,Y.Ux)("p",void 0,e.strings.gcAdsSponsored);t.className="icSponsoredText",l.appendChild(t)}return l.appendChild(u),l}CreateSponsoredTextV2(e){const t=this.flyoutData.strings.gcAdsSponsored,n=this.flyoutData.strings.gcFindOutLinkText,o=this.flyoutData.strings.gcSponsoredTooltip2,r=this.flyoutData.strings.gcAdsSponsoredDisclaimer;this.utilities.applyStyles(this.flyoutData.common.shopping,this.assetsItemizedCashback.getAdsDisclaimerAssets());const a=ve.h.SPB,s=(0,Y.Ux)("p");s.className="adsDisclaimerContainer",s.textContent=o;const l=this.telemetryHandler,c=this.pageHandlerModule;return Lp(s,[{navigationFunc:()=>{l.LogICSpecificTelemetry(i.xu.SponsoredTooltipFindMoreClick,"",e,{itemSource:a}),c.NavigateToUrl("https://choice.microsoft.com")},linkText:n}],o,this.isDarkMode),((e,t,i,n,o,r,a)=>{const s=(0,Y.Ux)("div",{style:"\n align-items: center;\n "});s.className="tooltipContainer",s.title="";const l=(0,Y.Ux)("p",{style:`\n margin: 0;\n font-weight: 400;\n font-size: 12px;\n line-height: 16px;\n display: flex;\n align-items: center;\n color: ${a?"#ffffff":"#666666"};\n `},i);l.className="gcTooltipText";const c=(0,Y.Ux)("div",{style:`\n position: absolute;\n top: 2px;\n right: 15px;\n width: fit-content;\n border: 1px solid rgba(0, 0, 0, 0.08);\n box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.08);\n border-radius: 8px;\n padding: 10px;\n visibility: hidden;\n z-index: 5;\n background-color: ${a?"#424242":"#ffffff"};\n `}),d="gcTooltipTextId";c.className="gcTooltipBody",c.id=d,c.setAttribute("aria-modal","true"),c.setAttribute("role","dialog"),c.setAttribute("aria-label",n);const u=t;u.title=n;const h=((e,t)=>{const i=(0,Y.Ux)("fluent-button");i.ariaLabel=e.strings.commonClose,i.title=e.strings.commonClose;const n=(0,Y.Ux)("DIV");return n.style.display="flex",n.style.alignContent="center",n.setAttribute("aria-hidden","true"),n.innerHTML=Ip(),i.appearance="stealth",i.appendChild(n),t&&(n.style.width=t,n.style.height=t,n.style.alignItems="center"),i})(e,"12px");h.className="closeButton",h.style.display="flex",h.style.width="fit-content",h.style.height="fit-content",h.style.marginLeft="auto",h.style.marginTop="-5px",h.style.padding="5px 0",h.addEventListener("click",(()=>{c.style.visibility="hidden"}));const p=(0,Y.Ux)("div",{style:"\n position: relative !important;\n display: flex;\n justify-content: center;\n "});p.className="tooltipAndBody";const g=((e,t,i)=>{const n=(0,Y.Ux)("fluent-button");n.ariaLabel=t,n.title=t,n.appearance="stealth";const o=(0,Y.Ux)("IMG");return o.style.display="flex",o.style.alignContent="center",o.setAttribute("aria-hidden","true"),o.src=e.common.resourcesEndpoint+"/common/infoIcon.svg",n.appendChild(o),i&&(o.style.width=i,o.style.height=i),n})(e,n,"10px"),f="gcTooltipIcon";g.id=f,g.className="tooltipButton",g.style.border="unset",g.style.background="transparent",g.style.height="fit-content",g.style.maxWidth="20px",g.style.minWidth="20px",g.style.width="20px",g.style.padding="0",g.setAttribute("aria-expanded","false"),g.setAttribute("aria-controls",d);const m=e=>{const t=e.target;t&&t.id!==f&&!t.closest(".gcTooltipBody")&&(c.style.visibility="hidden",g.setAttribute("aria-expanded","false"),document.removeEventListener("mouseover",m))},v=()=>{const e="visible"===c.style.visibility?"hidden":"visible";c.style.visibility=e,g.setAttribute("aria-expanded",`${"visible"===e}`),document.addEventListener("mouseover",m)};return g.addEventListener("mouseover",(e=>{e.stopPropagation(),"visible"!==c.style.visibility&&(o(),v())})),g.addEventListener("click",(()=>{r(),v()})),c.appendChild(h),c.appendChild(u),p.appendChild(g),p.appendChild(c),s.appendChild(l),s.appendChild(p),s})(this.flyoutData,s,t,r,(()=>{l.LogICSpecificTelemetry(i.xu.SponsoredTooltipHover,"",e,{itemSource:a})}),(()=>{l.LogICSpecificTelemetry(i.xu.SponsoredTooltipHover,"click",e,{itemSource:a})}),this.isDarkMode)}SetStyleForContent(e){e.style.padding="20px",e.style.borderRadius="4px",e.style.backgroundColor=this.isDarkMode?"#424242":"#ffffff"}CreatePricesContainer(e,t){const i=(0,Y.Ux)("DIV");i.className="icPriceContainer";const n=(0,Y.Ux)("p",void 0,t.toDisplay);if(n.className="icPriceContainerMainPrice",i.appendChild(n),e.amount!==t.amount){const t=(0,Y.Ux)("p",void 0,e.toDisplay);t.className="icPriceContainerCrossedPrice",i.appendChild(t)}return i}async activateCashbackHandler(e,t,n,o,r,a=!1,s=!1){await this.ActivateCashbackClickHandler(e,t,i.xu.ItemizedCashbackActivateClick,n,o,r,a,s)}async ActivateCashbackClickHandler(e,t,n,o,r,a,s,l){cg.IsInstantAddToCartShowConsent(this.flyoutData,a,l)&&(this.storageHandler.setStorageBool(Ce.Q.GroceryInstantAddToCartSpb,a),this.telemetryHandler.LogICSpecificTelemetry(i.xu.SPBInstantATCNotificationClick,"SPB Search Notification Clicked",t,{offerItem:e}),this.pageHandlerModule.RecordAsUserEngagement(q.FV.ACTIVATE_CLICK_SPB_CASHBACK,this.flyoutData.common.popupOrigination));const c=K.bS.ACTIVATE_CLICK_SPB_CASHBACK,d=(0,Ie.en)(e.visibilityFeedbackUrlBase||""),u=d?d.searchParams?.get("rg"):"",h={OfferId:e.id,ProductId:e.id,ProductTitle:e.adsOffer?.name,itemSource:ve.h.SPB,isNotification:a,isPdp:o,rguid:u,isRecentlySeenOffer:s,offerItem:e?.adsOffer};this.telemetryHandler.LogButtonClickICSpecificTelemetry(i.$S.SPBActivateButtonClick,c,"",t,h),this.telemetryHandler.LogICSpecificTelemetry(n,"Activate SPB offer clicked",t,h),await x.ZP.Sleep(10),r?this.pageHandlerModule.NavigateToUrl(e.adsOffer.url):(this.SwitchToActivatedUx(e,a),this.makeBackgroundActivation(e,t))}SwitchToActivatedUx(e,t){const i=document.querySelector(`#${this.gcMainBody}`),n=i?.querySelector(`#${this.gcMainContent}`);if(n&&i){const o=this.GetActivatedSpbOfferUx(e,t);i.replaceChild(o,n)}}CreateTrackCashbackButton(e,t,n){const o=(0,Y.lw)(this.utilities);return o.id=this.gcActivateBtnId,o.textContent=this.flyoutData.strings.gcTrackCashback,o.addEventListener("click",(o=>{o.stopPropagation(),this.telemetryHandler.LogButtonClickICSpecificTelemetry(n?i.$S.ICTrackCashbackButtonNotification:i.$S.ICTrackCashbackButton,K.bS.MS_CASHBACK_ACCOUNT_CLICKED,"Microsoft cashback account click",e,{isNotification:n,offerSource:t}),this.pageHandlerModule.NavigateToBingRebatesHistory()})),o.style.borderRadius="4px",o.style.height="32px",o.style.fontSize="14px",o.style.fontWeight="400",o}GetActivatedSpbOfferUx(e,t,i){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assetsItemizedCashback.getActivatedStyles());const n=i??(0,Y.Ux)("div");n.id=this.gcMainContent,n.className="activatedContent",t||this.SetStyleForContent(n);const o=(0,Y.Ux)("div");o.className="textAndImageContainerActivated";const r=(0,Y.Ux)("div");r.className="textContainerActivated";const a=(0,Y.Ux)("p",void 0,(0,T.fm)(this.flyoutData.strings.cbFeatureName));a.className="cashBackTextActivated";const s=Pp(`$${e.adsOffer.promotionInformation.rebateValue}`,"",!0,30);s.className="backBackValueActivated";const l=(0,Y.Ux)("p",void 0,this.flyoutData.strings.forYou);l.className="forYouTextActivated",r.appendChild(a),r.appendChild(s),r.appendChild(l);const c=(0,Y.Ux)("div"),d=this.createCashImageInWrapper(!0,e.imageUrl);var u;if(d.title=e.adsOffer.name,d.style.flex="1",c.appendChild(d),o.appendChild(r),o.appendChild(c),n.appendChild(o),n.appendChild((u=this.isDarkMode,(0,Y.Ux)("div",{style:`\n background: #FFFFFF;\n border-top: 1px solid ${u?"#5a5a5a":"#EFEFEF"};\n box-shadow: 0px 16px 32px rgba(0, 0, 0, 0.14);\n border-radius: 8px;\n `}))),n.appendChild(this.createCashbackExpiryTime(e.expireTimeEpoch)),n.appendChild(this.createCashbackActivatedStateButon(e)),t){const e=document.querySelector("#footerDiv");e&&(e.remove(),n.style.marginBottom="10px")}return n}createCashbackExpiryTime(e){const t=(0,Y.Ux)("DIV");t.className="expirationDateDivActivated";const i=(0,Y.Ux)("SPAN");i.style.color="rgba(196, 43, 28, 1)";const n=Date.now(),o=e?1e3*e:n+864e5-1;return i.textContent=this.getTimeDifference(n,o),(0,T.B7)(t,this.flyoutData.strings.cbExpiryDateTime,i),t}getTimeDifference(e,t){let i=t-e;const n=36e5;let o=i/n;i%=n,o|=0;let r=i/6e4;return i%=6e4,r|=0,0===o?r+"m":o+"h "+r+"m"}createCashbackActivatedStateButon(e){const t=(0,Y.Ux)("DIV");t.style.display="inline-flex",t.style.columnGap="6px",t.style.width="100%",t.style.height="38px",t.style.alignItems="center",t.style.justifyContent="center",t.style.marginTop="8px";const i=(0,Y.Ux)("DIV");i.innerHTML=this.commonAssets.getGreenCheck(),i.slot="start",i.style.width="20px",i.style.height="20px",i.setAttribute("aria-hidden","true");const n=(0,Y.Ux)("SPAN");if(n.textContent=this.flyoutData.strings.pcbActivatedButton,n.style.fontSize="14px",cg.ShowItemizedCashbackAddToCart(this.flyoutData)&&this.flyoutData.dataStoreModule.SPBItemizedCashbackData?.isSpbAddToCartEnabled){const i=(0,Y.lw)(this.utilities);cg.HandleAddToCartButton(i,e,this.flyoutData,this.utilities,this.telemetryHandler,this.pageHandlerModule),t.appendChild(i)}else t.style.boxSizing="border-box",t.style.border="1px solid #EBEBEB",t.style.borderRadius="4px",t.appendChild(i),t.appendChild(n);return t}createActivatedButton(){const e=(0,Y.Ux)("div",{id:"activatedIcon"}),t=(0,Y.Ux)("div",{style:"height: 20px;"});t.innerHTML=this.commonAssets.getGreenCheck(),t.slot="start",t.setAttribute("aria-hidden","true");const i=(0,Y.Ux)("span",{style:"font-size: 14px;"});return i.textContent=this.flyoutData.strings.pcbActivatedButton,e.appendChild(t),e.appendChild(i),e}MakeButton(e,t,n,o,r,a,s=!1){const l=(0,Y.lw)(this.utilities);l.id=this.gcActivateBtnId,l.className="icActionButton";const c=cg.IsSpbInstantATCExpEnabled(this.flyoutData)?this.flyoutData.strings.gcOkButtonText:s?`${this.flyoutData.strings.pcNotificationVisitItem}`:`${this.flyoutData.strings.gcGetDeal}${n?` ${n} ${this.flyoutData.strings.cbFeatureName}`:""}`;l.textContent=c,l.addEventListener("click",(i=>{i.stopPropagation(),this.activateCashbackHandler(t,e,o,r,!0)}));const d=i.xu.SPBActivateButtonHover,u=()=>{this.addIcTelemetry(e,d,`Button name: ${c}`,t.source,!1),l.removeEventListener("mouseover",u)};return l.addEventListener("mouseover",u),l}makeActivatedContainer(e=!1){const t=(0,Y.Ux)("DIV",{style:"\n "});if(t.id=this.gcActivatedContainer,!e){const e=(0,Y.Ux)("DIV",{style:"\n width: 100%;\n border-top: 1px solid #EBEBEB;\n padding-right: 16px;\n padding-left: 16px;\n margin-bottom: 6px;\n "});t.appendChild(e)}return t}async updateHomePageOffers(){try{const e=this.flyoutData.common.domain,t=await this.getCachedOffers();t&&t.offersPerDomain&&(Object.keys(t.offersPerDomain).forEach((i=>{if(i!==e){const e=t.offersPerDomain[i];e&&(e.requestPersonalizedQuery=!0)}})),this.storageHandler.setStorageString(Ce.Q.ShorelineSpbOffers,JSON.stringify(t)))}catch(e){this.telemetryHandler.LogIcError("Error during storage update",void 0,void 0,void 0,i.xu.HomePageOffersOnShorelineOpen)}}showSPBOffersOnShorelineOpenExp(){try{const t=this.flyoutData.dataStoreModule.UserInfo.isPersonalizationDataConsentEnabled,i=e.R.isTestFlagActive(Zt.t.msShoppingTestExp5)||e.R.isExperimentActive(f.H.showSpbOffersOnShorelineOpen)||e.R.isExperimentActive(f.H.showSpbOffersOnShorelineOpenV2),n=e.R.isTestFlagActive(Zt.t.msShoppingTestExp12);if(this.flyoutData.dataStoreModule?.SPBItemizedCashbackData,!this.flyoutData.dataStoreModule?.ICVariations)return!1;const o=this.flyoutData.dataStoreModule.ICVariations.get("pauseHomePage");return!(o&&"pauseHomePageOnDomain"===o||(!t||!i)&&!n)}catch(e){return this.telemetryHandler.LogIcError("Unable to identify exp flag"+e.message,e,void 0,void 0,i.xu.HomePageOffersOnShorelineOpen),!1}}async getCachedOffers(){const e=await this.storageHandler.getStorageString(Ce.Q.ShorelineSpbOffers,!0);if(e&&""!==e)return JSON.parse(e)}},gg=class{constructor(e,t,i,n){(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"landingPageUrl","https://microsoft.com/en-us/edge/launch/59?form=ML2F1I"),(0,s.Z)(this,"logModule",void 0),this.utilities=e,this.flyoutData=t,this.assets=new class{getStyles(){return`\n #pinkStar {\n fill : #EE7DD5;\n }\n #blueStar {\n fill : #54C6F3;\n }\n .iconPinkStar {\n margin-top: 12px;\n margin-right: 13px;\n }\n .iconBlueStarUp {\n margin-left: -1px;\n margin-top: -8px;\n }\n .iconBlueStarDown {\n margin-left: 16px;\n }\n .spanRewardClaimText {\n width: auto;\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-style: normal;\n font-weight: 600;\n font-size: 12px;\n line-height: 16px;\n\n display: flex;\n align-items: center;\n\n color: var(--text-normal);\n }\n .divProgress, .divProgressNotification, .divClaim, .divClaimNotification {\n margin-top: 10px;\n margin-bottom: 10px;\n height: 28px;\n width: 100%;\n flex: auto;\n box-sizing: border-box;\n\n display: flex;\n flex-direction: row;\n align-items: center;\n\n border-radius: 20px;\n border: 2px solid #EDEFED;\n }\n .divProgress:hover, .divProgressNotification:hover, .divClaim:hover, .divClaimNotification:hover {\n cursor: pointer;\n border: 2px solid #07978A;\n }\n .divProgress:focus, .divProgressNotification:focus, .divClaim:focus, .divClaimNotification:focus {\n outline: 2px solid transparent;\n border: 2px solid #878787;\n }\n .divProgress, .divClaim {\n margin-left: 20px;\n margin-right: 20px;\n background: linear-gradient(271.69deg, #EBF5F5 48.57%, #FFFFFF 100%);\n }\n .divProgressNotification, .divClaimNotification {\n margin-left: 16px;\n margin-right: 16px;\n background: linear-gradient(272.2deg, #EBF5F5 62.52%, #FFFFFF 147.61%);\n }\n .divClaim, .divClaimNotification {\n justify-content: center;\n text-align: center;\n justify-content: center;\n }\n @media (forced-colors: active) {\n .spanRewardClaimText, .spanRewardProgressText {\n color: ${Ns.Highlight} !important;\n }\n .divProgress, .divProgressNotification, .divClaim, .divClaimNotification {\n forced-color-adjust: none;\n background: ${Ns.HighlightText} !important;\n border: 2px solid ${Ns.HighlightText} !important;\n }\n .divProgress:hover, .divProgressNotification:hover, .divClaim:hover, .divClaimNotification:hover {\n border: 2px solid ${Ns.Highlight} !important;\n }\n .divProgress:focus, .divProgressNotification:focus, .divClaim:focus, .divClaimNotification:focus {\n border: 2px solid ${Ns.ButtonText} !important;\n }\n .spanProgressReward {\n background: ${Ns.Highlight};\n color: ${Ns.HighlightText};\n }\n #actionDone {\n fill: ${Ns.Highlight};\n }\n #correctActionDone {\n stroke: ${Ns.HighlightText};\n }\n #actionToDo {\n stroke: ${Ns.Highlight};\n }\n #pinkStar {\n fill: ${Ns.Highlight};\n }\n #blueStar {\n fill: ${Ns.Highlight};\n }\n }\n `}getDarkModeStyles(){return"\n .divProgress, .divProgressNotification, .divClaim, .divClaimNotification {\n background: linear-gradient(90deg, rgba(14, 14, 18, 0.4) 0%, rgba(14, 24, 40, 0.4) 30.73%, rgba(5, 29, 48, 0.4) 100%);\n border: 2px solid #24282E;\n }\n .divProgress:hover, .divProgressNotification:hover, .divClaim:hover, .divClaimNotification:hover {\n cursor: pointer;\n border: 2px solid #079188;\n }\n .divProgress:focus, .divProgressNotification:focus, .divClaim:focus, .divClaimNotification:focus {\n outline: 2px solid transparent;\n border: 2px solid #878787;\n }\n "}getPinkStarIcon(){return eh.Z.getTrustedHTML`<svg width="10" height="10" viewBox="0 0 10 10" fill="none" xmlns="http://www.w3.org/2000/svg">
<path id="pinkStar" d="M4.50513 0C4.50513 0 5.03612 2.70012 5.6731 3.3371C6.31008 3.97408 9.0102 4.50507 9.0102 4.50507C9.0102 4.50507 6.4164 4.92975 5.6731 5.67305C4.9298 6.41634 4.50513 9.01014 4.50513 9.01014C4.50513 9.01014 3.9742 6.31009 3.33715 5.67305C2.70011 5.036 5.61249e-05 4.50507 5.61249e-05 4.50507C5.61249e-05 4.50507 2.70011 3.97414 3.33715 3.3371C3.9742 2.70005 4.50513 0 4.50513 0Z" />
</svg>`}getBlueStarIcon(){return eh.Z.getTrustedHTML`<svg width="8" height="8" viewBox="0 0 8 8" fill="none" xmlns="http://www.w3.org/2000/svg">
<path id="blueStar" d="M3.84399 0C3.84399 0 4.29701 2.30361 4.84045 2.84705C5.38389 3.39049 7.6875 3.84351 7.6875 3.84351C7.6875 3.84351 5.4746 4.20582 4.84045 4.83996C4.20631 5.47411 3.84399 7.68701 3.84399 7.68701C3.84399 7.68701 3.39103 5.38346 2.84754 4.83996C2.30404 4.29647 0.000488221 3.84351 0.000488221 3.84351C0.000488221 3.84351 2.30404 3.39054 2.84754 2.84705C3.39103 2.30355 3.84399 0 3.84399 0Z" />
</svg>`}},this.pageHandlerModule=i,this.logModule=n}RenderCUCBanner(){if(this.shouldRenderCUCBanner()){const e=this.renderChromeUserCampaignBanner();e.id="chromeUserCampaignBannerId",e.slot="start-content",this.flyoutData.common.shopping?.prepend(e)}}RenderCUCNotificationBanner(){if(this.shouldRenderCUCBanner()){const e=this.renderChromeUserCampaignBanner();e.id="chromeUserCampaignBannerId",e.slot="start-content",this.flyoutData.common.shopping?.prepend(e)}}shouldRenderCUCBanner(){return this.flyoutData.dataStoreModule.UserInfo?.isMarketingCampaignEventEnrolled,this.flyoutData.dataStoreModule.UserInfo?.isCashbackPlatformAcknowledged,this.flyoutData.dataStoreModule.CashBackData?.userRebatesResponse?.isChromeUserCampaignEligible,!1}renderRewardClaimText(){const e=(0,Y.Ux)("SPAN");e.className="spanRewardClaimText";const t=(0,T.fZ)("cucRewardClaimText",this.flyoutData.strings.cucRewardClaimText,"$20");return e.textContent=t,e.setAttribute("aria-label",t),e}renderPinkStarIcon(){const e=(0,Y.Ux)("SPAN");return e.className="iconPinkStar",e.setAttribute("aria-hidden","true"),e.innerHTML=this.assets.getPinkStarIcon(),e}renderBlueStarIcon(){const e=(0,Y.Ux)("SPAN");return e.setAttribute("aria-hidden","true"),e.innerHTML=this.assets.getBlueStarIcon(),e}renderChromeUserCampaignBanner(){return this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),this.renderClaimWrapper()}renderClaimWrapper(){const e=(0,Y.Ux)("DIV");e.className="divClaim",e.addEventListener("click",(()=>{this.onClickBanner(i.$S.ChromeUserCampaignButton)})),e.addEventListener("keypress",(e=>{"Enter"!==e.key&&" "!==e.key||this.onClickBanner(i.$S.ChromeUserCampaignButton)})),e.setAttribute("role","link"),e.setAttribute("tabindex","0");const t=this.renderRewardClaimText(),n=this.renderPinkStarIcon(),o=this.renderBlueStarIcon();o.className="iconBlueStarUp";const r=this.renderBlueStarIcon();return r.className="iconBlueStarDown",e.appendChild(n),e.appendChild(t),e.appendChild(r),e.appendChild(o),e}onClickBanner(e){const t=new W.Z(e,bp.r.CAMPAIGN_BANNER);this.logModule.LogInfoEvent(i.R.ButtonClick,"Chrome User Campaign clicked",t),this.pageHandlerModule.NavigateToUrl(this.landingPageUrl)}},fg=o(64550);function mg(e,t=32){if(e)return`https://edge.microsoft.com/favicon/v1/?client=chrome_desktop&nfrp=2&check_seen=true&size=${t}&min_size=16&max_size=256&fallback_opts=TYPE%2CSIZE%2CURL&url=${e}&origin=ShorelineCashback`}const vg=(e,t,i,n,o)=>{const r=n-o,a=Math.floor(r/3600),s=Math.floor(r%3600/60);let l=`${e}`;return 0!==a&&(l+=` ${a}${t}`),0!==s&&(l+=` ${s}${i}`),l.trim()},yg=(e,t,i=!1)=>`https://groceryassets.blob.core.windows.net/publicassets/cashback-dashboard/${e}${i?"-accent":""}${t?"-dark":""}.svg`;var Cg=o(12265);function bg(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Sg(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?bg(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):bg(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var xg=class{constructor(e,t,i,n,o,r=void 0,a=void 0){(0,s.Z)(this,"cashbackScenarioService",void 0),(0,s.Z)(this,"cashbackLogger",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"retailerOffers",[]),(0,s.Z)(this,"productOffers",[]),(0,s.Z)(this,"userCashbackData",void 0),(0,s.Z)(this,"parentElement",void 0),this.flyoutData=e,this.utilities=t,this.pageHandlerModule=i,this.userCashbackData=n,this.parentElement=o,this.cashbackScenarioService=r,this.cashbackLogger=a,n?.activatedOffers?.forEach((e=>{"Storewide"===e.scope?this.retailerOffers.push(e):this.productOffers.push(e)}))}render(){this.renderHidden(),this.renderBalanceCard(),this.renderWelcomeBanner(),this.renderRedeemBanner(),this.renderTopOffers(),this.renderActivatedOffers(),this.renderCashbackCarousel(),this.renderTransactionHistory()}renderHidden(){const e=(0,Y.Ux)("div");this.parentElement?.appendChild(e),this.respondToVisibility(e,(e=>{e&&this.cashbackScenarioService?.LogUserShownModule(r.ModuleNames.CASHBACK_DASHBOARD,void 0)}))}renderBalanceCard(){if(this.userCashbackData?.enrolled&&(this.userCashbackData?.formattedTransactions?.length??0)>0){const e=(0,Y.Ux)("msft-cb-balance-card");e.balanceCards=this.getBalanceCardsData(),e.hasTransactions=this.hasTransactions(),e.onBalanceClick=()=>{this.cashbackScenarioService?.LogButtonClick(r.ModuleNames.CASHBACK_DASHBOARD,Cg.mh.BALANCE_BUTTON,void 0),this.pageHandlerModule.NavigateToBingRebatesPayouts()},e.chevronRight=yg("chevron-right",this.utilities.isDarkMode(),!0),this.parentElement?.appendChild(e)}}renderTransactionHistory(){const e=this.userCashbackData?.formattedTransactions,t=(0,Y.Ux)("msft-cb-transaction-history");t.transactions=this.formatTransactions(e),t.totalTransactions=this.userCashbackData?.totalTransactions,t.headerString=this.flyoutData.strings.cashbackHistoryHeader,t.seeFullString=this.flyoutData.strings.cashbackHistorySeeFull,t.seeMoreString=this.flyoutData.strings.cashbackHistorySeeMore,t.seeLessString=this.flyoutData.strings.cashbackHistorySeeLess,t.seeAllIcon=yg("see-all",this.utilities.isDarkMode()),t.arrowDownIcon=yg("arrow-down",this.utilities.isDarkMode()),t.onSeeFullClick=()=>{this.cashbackScenarioService?.LogButtonClick(r.ModuleNames.CASHBACK_DASHBOARD,Cg.mh.SEE_FULL_HISTORY,void 0),this.pageHandlerModule.NavigateToBingRebatesHistory()},t.onToggleHistoryLength=()=>{this.cashbackScenarioService?.LogButtonClick(r.ModuleNames.CASHBACK_DASHBOARD,Cg.mh.TOGGLE_HISTORY_LENGTH,void 0)},this.parentElement?.appendChild(t)}renderCashbackCarousel(){if(!this.userCashbackData?.enrolled){const e=(0,Y.Ux)("msft-cashback-carousel");e.pageHandlerFunctions={ActivateRebates:e=>this.pageHandlerModule.ActivateRebates(e),NavigateToBingRebates:()=>this.pageHandlerModule.NavigateToBingRebates(),NavigateToMicrosoftRewards:()=>this.pageHandlerModule.NavigateToMicrosoftRewards(),NavigateToTermsStatement:()=>this.pageHandlerModule.NavigateToTermsStatement(),NavigateToPrivacyCookiesStatement:()=>this.pageHandlerModule.NavigateToPrivacyCookiesStatement(),SignInToEdgeProfile:e=>this.pageHandlerModule.SignInToEdgeProfile(e)},e.actionCallbacks={joinRebates:()=>{this.cashbackScenarioService?.LogButtonClick(r.ModuleNames.CASHBACK_DASHBOARD,Cg.mh.CAROUSEL_JOIN_REBATES,void 0)},error:e=>{this.cashbackLogger?.LogError(e,{})},learnMore:()=>{this.cashbackScenarioService?.LogButtonClick(r.ModuleNames.CASHBACK_DASHBOARD,Cg.mh.CAROUSEL_LEARN_MORE,void 0)},msRewards:()=>{this.cashbackScenarioService?.LogButtonClick(r.ModuleNames.CASHBACK_DASHBOARD,Cg.mh.CAROUSEL_MS_REWARDS,void 0)},terms:()=>{this.cashbackScenarioService?.LogButtonClick(r.ModuleNames.CASHBACK_DASHBOARD,Cg.mh.CAROUSEL_TERMS,void 0)},privacy:()=>{this.cashbackScenarioService?.LogButtonClick(r.ModuleNames.CASHBACK_DASHBOARD,Cg.mh.CAROUSEL_PRIVACY_POLICY,void 0)}},e.captions=[this.flyoutData.strings.cashbackCarouselStepOne,this.flyoutData.strings.cashbackCarouselStepTwo,this.flyoutData.strings.cashbackCarouselStepThree],e.isSignedInUser=this.userCashbackData?.isSignedIn??!1,e.isRebatesUser=!1,e.legalese=this.flyoutData.strings.cashbackCarouselLegalese,e.learnMoreText=this.flyoutData.strings.commonLearnMore,e.termsText=this.flyoutData.strings.terms,e.privacyText=this.flyoutData.strings.cbPrivacyMessagePrivacyCookies,e.enrollSuccessTitle=this.flyoutData.strings.cashbackEnrollSuccessMessage,e.enrollSuccessLink=this.flyoutData.strings.cashbackEnrollSuccessLink,e.onWelcomeLinkClick=()=>{this.cashbackScenarioService?.LogButtonClick(r.ModuleNames.CASHBACK_DASHBOARD,Cg.mh.CAROUSEL_WELCOME_LINK,void 0),this.pageHandlerModule.NavigateToUrl("https://bing.com/deals")},this.parentElement?.appendChild(e)}}renderRedeemBanner(){if(this.userCashbackData&&this.userCashbackData.enrolled&&(this.userCashbackData.profile?.availableBalance??0)>0){const e=(0,Y.Ux)("msft-cb-redeem-banner");e.titleText=this.flyoutData.strings.cashbackRedeemBannerTitle,e.linkText=this.flyoutData.strings.cashbackRedeemBannerLinkText,e.moneyIcon=yg("money",this.utilities.isDarkMode(),!0),e.closeIcon=yg("close",this.utilities.isDarkMode()),e.amount=this.userCashbackData?.profile?.availableBalance??0,e.onLinkClick=()=>{this.cashbackScenarioService?.LogButtonClick(r.ModuleNames.CASHBACK_DASHBOARD,Cg.mh.REDEEM_BANNER_BUTTON,void 0),this.pageHandlerModule.NavigateToBingRebatesPayouts()},e.onCloseClick=()=>{this.cashbackScenarioService?.LogButtonClick(r.ModuleNames.CASHBACK_DASHBOARD,Cg.mh.CLOSE_REDEEM_BANNER,void 0)},e.currency=this.userCashbackData?.profile?.userCurrency??"usd",this.parentElement?.appendChild(e)}}renderActivatedOffers(){const e=this.retailerOffers.map((e=>{const t=e.domain?.split(",")[0];return{brand:t,src:mg(t||"",16),href:`https://${t}`,offer:`${e.adsCurrencySymbol}${e.commissionValue}`,minPurchaseValue:`${e.adsCurrencySymbol}${e.minPurchaseValue}`,endsIn:vg(this.flyoutData.strings.cashbackActivatedOfferTimePrefix,this.flyoutData.strings.cashbakcActivatedOfferHourSymbol,this.flyoutData.strings.cashbackActivatedOfferMinuteSymbol,e.expireTimeEpoch||0,Math.floor(Date.now()/1e3))}})).filter((e=>Boolean(e.brand&&e.endsIn&&e.offer&&e.src))),t=this.productOffers.map((e=>{return{productImageUrl:(t=e.imageUrl??"",t.startsWith("/th?")?`https://th.bing.com${t}`:t),retailerLogoUrl:mg(e.domain||"",16),retailerName:e.domain,offerValue:`${e.adsCurrencySymbol}${e.commissionValue}`,offerDescription:e.scope,endsIn:vg(this.flyoutData.strings.cashbackActivatedOfferTimePrefix,this.flyoutData.strings.cashbakcActivatedOfferHourSymbol,this.flyoutData.strings.cashbackActivatedOfferMinuteSymbol,e.expireTimeEpoch||0,Math.floor(Date.now()/1e3)),href:e.productUrl};var t})).filter((e=>Boolean(e.productImageUrl&&e.retailerLogoUrl&&e.retailerName&&e.offerDescription&&e.href))),i=this.flyoutData.dataLoader.GetLoadTimeDataValue("isMobile",!1),n=(0,Y.Ux)("msft-cb-activated-offers");n.style.width="100%",n.isMobile=i?"true":"false",n.headerString=i?this.flyoutData.strings.rewardCashback:this.flyoutData.strings.cashbackActivatedOffersHeader,n.seeFullString=this.flyoutData.strings.cashbackActivatedOffersSeeFull,n.seeMoreString=this.flyoutData.strings.cashbackActivatedOffersSeeMore,n.seeLessString=this.flyoutData.strings.cashbackActivatedOffersSeeLess,n.arrowDownIcon=yg("arrow-down",this.utilities.isDarkMode()),n.cashbackTag=yg("cashback-tag",this.utilities.isDarkMode()),n.seeAllIcon=yg("see-all",this.utilities.isDarkMode(),!0),n.retailerOffers=e,n.retailerOffersLinkText=this.flyoutData.strings.cashbackRetailerOfferLinkText,n.retailerOffersTagPostfix=this.flyoutData.strings.cashbackRetailerOfferPostfix,n.retailerOffersOnLinkClick=e=>{this.cashbackScenarioService?.LogButtonClick(r.ModuleNames.CASHBACK_DASHBOARD,Cg.mh.ACTIVATED_OFFER_CLICK,void 0),this.pageHandlerModule.NavigateToPcbProductPage(e)},n.productOffers=t,n.productOffersLinkText=this.flyoutData.strings.cashbackProductOfferLinkText,n.productOffersTagPostfix=this.flyoutData.strings.cashbackProductOfferPostfix,n.productOffersOnLinkClick=e=>{this.cashbackScenarioService?.LogButtonClick(r.ModuleNames.CASHBACK_DASHBOARD,Cg.mh.ACTIVATED_OFFER_CLICK,void 0),this.pageHandlerModule.NavigateToPcbProductPage(e)},n.cashbackHistoryText=this.flyoutData.strings.shoppingTripsTitle,n.onSeeFullClick=()=>{this.cashbackScenarioService?.LogButtonClick(r.ModuleNames.CASHBACK_DASHBOARD,Cg.mh.SEE_FULL_ACTIVATED_OFFERS,void 0),this.pageHandlerModule.NavigateToBingRebatesHistory()},this.parentElement?.appendChild(n)}renderWelcomeBanner(){const e=this.userCashbackData?.profile,t=this.userCashbackData?.enrolled;if(t&&0===e?.availableBalance&&0===e?.pendingBalance&&0===e?.redeemedBalance){const e=(0,Y.Ux)("msft-cb-welcome-banner");e.headerText=this.flyoutData.strings.cashbackWelcomeBannerHeader,e.bodyText=this.flyoutData.strings.cashbackWelcomeBannerBody,this.parentElement?.appendChild(e)}}renderTopOffers(){const e=this.userCashbackData?.profile,t=this.userCashbackData?.enrolled;if(t&&0===e?.availableBalance&&0===e?.pendingBalance&&0===e?.redeemedBalance){const e=(0,Y.Ux)("msft-cb-top-offers");e.offers=this.userCashbackData?.topCashbackOffers??[],e.titleString=this.flyoutData.strings.cashbackTopOfferTitle,e.postTagString=this.flyoutData.strings.cashbackTopOfferPostTag,e.usageCountString=this.flyoutData.strings.cashbackTopOfferPostUsageCount,e.onCardClick=e=>{this.cashbackScenarioService?.LogButtonClick(r.ModuleNames.CASHBACK_DASHBOARD,Cg.mh.TOP_OFFER_CLICK,void 0,e.retailerName),this.pageHandlerModule.NavigateToUrl(e.merchantUrlWithFormCode)},this.parentElement?.appendChild(e)}}getBalanceCardsData(){const e=this.userCashbackData?.profile;return[{title:"Balance",amount:this.formatAmount(e?.availableBalance),isAvailableBalance:!0},{title:"Pending",amount:this.formatAmount(e?.pendingBalance),isAvailableBalance:!1},{title:"All time",amount:this.formatAmount(e?.redeemedBalance),isAvailableBalance:!1}]}hasTransactions(){return(this.userCashbackData?.formattedTransactions?.length??0)>0}formatTransactions(e){return e?e.map((e=>{const t=parseFloat(e.commission);return Sg(Sg({},e),{},{orderDate:isNaN(Date.parse(e.orderDate))?"":new Date(e.orderDate).toLocaleDateString(),commission:isNaN(t)||!t?"":this.formatAmount(t),merchantLogo:mg(e.merchantDomain)})})):[]}formatAmount(e){const t=this.flyoutData.common.afdMarket,i=this.userCashbackData?.profile?.userCurrency;return Kd(e??0,t,i)}respondToVisibility(e,t){const i={root:this.parentElement};new IntersectionObserver(((e,i)=>{e.forEach((e=>{t(e.intersectionRatio>0)}))}),i).observe(e)}},Tg=class{constructor(e,t,i,n,o,r,l){(0,s.Z)(this,"currencySymbol","$"),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"moduleName",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"storageUtilities",void 0),(0,s.Z)(this,"cashbackAssets",new tg),this.flyoutData=e,this.pageHandlerModule=t,this.logModule=i,this.utilities=n,this.commonAssets=new a.Z,this.moduleName=o,this.telemetryUtilities=r,this.storageUtilities=l}async renderPersonalizedCashback(n,o){let a=e.R.isExperimentActive(f.H.cashbackDismissTimeout)?3e3:1e4;if(n.personalizedCashback?.adsCashback?.length>0&&"LdClickData"===n.personalizedCashback?.adsCashback[0]?.scope||"LdClickDataStorewide"===n.personalizedCashback?.adsCashback[0]?.scope){const r=n.personalizedCashback.adsCashback[0],s=(0,Y.Ux)("div",{id:"divWrapperPcb"}),l=(0,Y.Ux)("div",{id:"divContentPcb"}),c=(0,Y.Ux)("div",{id:"divInfoPcb"}),d=(0,Y.Ux)("div",{id:"txtTitlePcb"});d.textContent=(0,T.fm)(this.flyoutData.strings.cbFeatureName);const u=n.personalizedCashback.adsCashback[0].adsCurrencySymbol??this.currencySymbol,h=this.utilities.createCommissionArrow(r.commissionValue,!0,zu.h.Large,void 0,u);h.setAttribute("aria-hidden","true");const p=(0,Y.Ux)("div",{id:"divForYouPcb"}),g=(0,Y.Ux)("div",{id:"txtForYouPcb"});g.textContent=this.flyoutData.strings.forYou,p.appendChild(g),c.appendChild(d),c.appendChild(h),c.appendChild(p),l.appendChild(c);const m=this.createImagePcb(r);m.style.marginLeft="auto",m.style.marginBottom="auto",l.appendChild(m);const v=(0,Y.Ux)("div",{id:"dividerPcb"});s.appendChild(l);const y=this.flyoutData.dataStoreModule.ProductInsightsData;if(e.R.isExperimentActive(f.H.communityInsightsCB)&&y?.TopInsight){const e=(0,Y.Ux)("div",{id:"divCIPcb"}),t=(0,Y.Ux)("div",{className:"ciIcon"});t.innerHTML=this.cashbackAssets.getCommunityInsightsIcon();const i=(0,Y.Ux)("div",{id:"txtCIPcb"});i.textContent=y?.TopInsight,e.appendChild(t),e.appendChild(i),s.appendChild(e)}s.appendChild(v);const C=this.getExpirationWrapper(r.expireTimeEpoch),b=(0,T.fZ)("pcbAriaLabel",this.flyoutData.strings.pcbAriaLabel,r.scope,r.commissionValue,this.getTimeDifference(Date.now(),1e3*r.expireTimeEpoch));if(d.setAttribute("aria-label",b),s.appendChild(C),n.IsRebatesUser()){const e=this.createActivatedButtonPcb();s.appendChild(e)}o.appendChild(s);const S=new t.Z(i.xu.PersonalizedCashbackNotification);S.Metadata=JSON.stringify({userInfo:this.flyoutData?.dataStoreModule?.UserInfo,Rguid:n.personalizedCashback?.rGuid,OfferId:n.personalizedCashback?.offerId,personalizedCashBackInfo:n.CreatePersonalizedCashbackLogMetadata(),openedWith:this.flyoutData.common.openedWith}),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Personalized cashback rendered in fallback mode",S),setTimeout((()=>{this.pageHandlerModule.DismissPopup()}),a)}else if(this.flyoutData.common.openedWith===r.Te.Auto&&"Storewide"===n.personalizedCashback?.adsCashback[0]?.scope){const e=(0,Y.Ux)("DIV");e.style.display="flex",e.style.flexDirection="column";const r=(0,Y.Ux)("div");r.id="txtTitlePcb",r.textContent=(0,T.fm)(this.flyoutData.strings.cbFeatureName);const s=n.personalizedCashback.adsCashback[0].adsCurrencySymbol??this.currencySymbol,l=this.utilities.createCommissionArrow(n.personalizedCashback.adsCashback[0].commissionValue.toString(),!0,zu.h.Large,void 0,s);l.style.marginTop="8px",l.style.display="inline-flex",l.style.alignSelf="center",e.appendChild(r),e.appendChild(l);const c=(0,Y.Ux)("div");c.id="divMinPurchasePcb",c.textContent=(0,T.fZ)("pcbStorewideCashbackAutoshow",this.flyoutData.strings.pcbStorewideCashbackAutoshow,n.personalizedCashback.adsCashback[0].adsCurrencySymbol+n.personalizedCashback.adsCashback[0].minPurchaseValue),c.style.fontSize="12px",c.style.lineHeight="16px",c.style.marginTop="4px",e.appendChild(c);const d=(0,Y.Ux)("div",{id:"dividerPcb"});d.style.marginTop="10px",d.style.marginLeft="10px",d.style.marginRight="10px",d.style.width="auto",e.appendChild(d);const u=this.getExpirationWrapper(n.personalizedCashback.adsCashback[0].expireTimeEpoch);if(u.style.alignSelf="center",e.appendChild(u),n.IsRebatesUser()){const t=this.createActivatedButtonPcb();t.classList.add("pcbButtonAddressbar"),e.appendChild(t)}o.appendChild(e);const h=new t.Z(i.xu.PersonalizedCashbackStoreWideNotification);h.Metadata=JSON.stringify({userInfo:this.flyoutData?.dataStoreModule?.UserInfo,Rguid:n.personalizedCashback?.rGuid,OfferId:n.personalizedCashback?.offerId,personalizedCashBackInfo:n.CreatePersonalizedCashbackLogMetadata(),openedWith:this.flyoutData.common.openedWith}),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Personalized cashback rendered",h),setTimeout((()=>{this.pageHandlerModule.DismissPopup()}),a)}else if(this.flyoutData.common.openedWith===r.Te.Auto&&n?.personalizedCashback?.adsCashback?.length>0){const r=n.personalizedCashback.adsCashback[0],s=(0,Y.Ux)("div",{id:"divWrapperPcb"}),l=(0,Y.Ux)("div",{id:"divContentPcb"}),c=(0,Y.Ux)("div",{id:"divInfoPcb"}),d=(0,Y.Ux)("div",{id:"txtTitlePcb"});d.textContent=(0,T.fm)(this.flyoutData.strings.cbFeatureName);const u=n.personalizedCashback.adsCashback[0].adsCurrencySymbol??this.currencySymbol,h=this.utilities.createCommissionArrow(r.commissionValue,!0,zu.h.Large,void 0,u);h.setAttribute("aria-hidden","true");const p=(0,Y.Ux)("div",{id:"divForYouPcb"}),g=(0,Y.Ux)("div",{id:"txtForYouPcb"});g.textContent=this.flyoutData.strings.forYou,p.appendChild(g),c.appendChild(d),c.appendChild(h),c.appendChild(p),l.appendChild(c);const m=this.createImagePcb(r);m.style.marginLeft="auto",m.style.marginBottom="auto",l.appendChild(m);const v=(0,Y.Ux)("div",{id:"dividerPcb"});s.appendChild(l);const y=this.flyoutData.dataStoreModule.ProductInsightsData;if(e.R.isExperimentActive(f.H.communityInsightsCB)&&y?.TopInsight){const e=(0,Y.Ux)("div",{id:"divCIPcb"}),t=(0,Y.Ux)("div",{className:"ciIcon"});t.innerHTML=this.cashbackAssets.getCommunityInsightsIcon();const i=(0,Y.Ux)("div",{id:"txtCIPcb"});i.textContent=y?.TopInsight,e.appendChild(t),e.appendChild(i),s.appendChild(e)}s.appendChild(v);const C=this.getExpirationWrapper(r.expireTimeEpoch),b=(0,T.fZ)("pcbAriaLabel",this.flyoutData.strings.pcbAriaLabel,r.scope,r.commissionValue,this.getTimeDifference(Date.now(),1e3*r.expireTimeEpoch));if(d.setAttribute("aria-label",b),s.appendChild(C),n.IsRebatesUser()){const e=this.createActivatedButtonPcb();s.appendChild(e)}o.appendChild(s);const S=new t.Z(i.xu.PersonalizedCashbackNotification);S.Metadata=JSON.stringify({userInfo:this.flyoutData?.dataStoreModule?.UserInfo,Rguid:n.personalizedCashback?.rGuid,OfferId:n.personalizedCashback?.offerId,personalizedCashBackInfo:n.CreatePersonalizedCashbackLogMetadata(),openedWith:this.flyoutData.common.openedWith}),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Personalized cashback rendered",S),setTimeout((()=>{this.pageHandlerModule.DismissPopup()}),a)}else{const e=this.flyoutData;this.flyoutData.dataLoader.GetLoadTimeDataValue("isMobile",!1)?await this.renderListPcbMobile(n.personalizedCashback,o,e):await this.renderListPcb(n.personalizedCashback,o,e);const r=new t.Z(i.xu.PersonalizedCashbackPaneModule);r.Metadata=JSON.stringify({userInfo:this.flyoutData?.dataStoreModule?.UserInfo,Rguid:n.personalizedCashback?.rGuid,OfferId:n.personalizedCashback?.offerId,personalizedCashBackInfo:n.CreatePersonalizedCashbackLogMetadata(),openedWith:this.flyoutData.common.openedWith}),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Personalized cashback rendered",r)}}createCashback3xIncentiveOfferBody(e,t,i){const n=this.flyoutData.strings.cbExclusiveBadgeText,o=(0,Y.Ux)("DIV",{id:"div3xCashbackContent"});this.utilities.isDarkMode()&&(o.style.backgroundColor="transparent"),o.appendChild(this.createExclusiveBadge(n,i));const r=(0,Y.Ux)("DIV",{id:"div3xIncentiveTitle"}),a=this.getIncentiveCashbackValues(),s=i?.createCashbackTitle3xIncentive(a.oldCashback,a.newIncentiveCashback??"",e.isCashBackActivated);s&&(r.appendChild(s),o.appendChild(r));const l=this.flyoutData?.dataStoreModule.CashBackData?.merchantFullName?this.flyoutData?.dataStoreModule.CashBackData?.merchantFullName:this.flyoutData?.common?.domain,c=(0,Y.Ux)("div",{id:"div3xMerchantInfo"}),d=(0,Y.Ux)("p",{id:"onTxtMerchantInfo"});d.textContent=(0,T.fZ)("gcbOnMerchantName",this.flyoutData.strings.gcbOnMerchantName,l),c.appendChild(d);const u=(0,Y.Ux)("div",{id:"divMerchantIcon"}),h=(0,Y.Ux)("img",{id:"imgMerchantIcon"});if(this.utilities.addFavIconSrc(h,u,this.flyoutData.common.domain),c.appendChild(u),o.appendChild(c),!e.isCashBackActivated){const e=(0,Y.Ux)("div",{style:`\n background: rgba(239, 239, 239, 0.14);\n border-top: 1px solid ${this.utilities.isDarkMode()?"#5a5a5a":"#EFEFEF"};\n box-shadow: 0px 16px 32px rgba(0, 0, 0, 0.14);\n border-radius: 8px;\n margin: 10px;\n width: 90%;\n margint-bottom:20px;\n `}),t=(0,Y.Ux)("p",{id:"limitedOffer3xincentive"});t.textContent=this.flyoutData.strings.cbActivateLimitedTimeOffer,o.appendChild(e),o.appendChild(t)}t.appendChild(o)}createExclusiveBadge(e,t){const i=(0,Y.Ux)("DIV");i.className="coloredBanner";const n=(0,Y.Ux)("p",void 0,(0,T.fm)("3x Cash Back"));n.className="microsoftCashbackText";const o=(0,Y.Ux)("p",void 0,(0,T.fm)("Microsoft Shopping Exclusive"));return o.className="microsoftExclusiveText",this.utilities.isDarkMode()&&(i.style.background="linear-gradient(91.21deg, #274A50 0%, #292649 100%)",n.className="microsoftCashbackTextDark"),i.appendChild(o),i.appendChild(n),this.flyoutData.common.openedWith===r.Te.Auto&&(i.style.padding="0px 16px"),i}async renderAddressBarPersonalizedCashback(e,n){if(!e?.productAd?.promotionInformation?.rebateValue)return;const o=(0,Y.Ux)("DIV");o.style.display="flex",o.style.flexDirection="column";const r=(0,Y.Ux)("div");r.id="txtTitlePcb",r.textContent=(0,T.fm)(this.flyoutData.strings.cbFeatureName);const a=e.productAd?.offer?.priceCurrencySymbol??this.currencySymbol,s=this.utilities.createCommissionArrow(e.productAd.promotionInformation.rebateValue.toString(),!0,zu.h.Large,void 0,a);s.style.marginTop="8px",s.style.display="inline-flex",s.style.alignSelf="center",o.appendChild(r),o.appendChild(s);const l=(0,Y.Ux)("div");l.id="divMinPurchasePcb",l.textContent=(0,T.fZ)("pcbStorewideCashbackAutoshow",this.flyoutData.strings.pcbStorewideCashbackAutoshow,e.productAd.offer.priceCurrencySymbol+e.productAd.promotionInformation.minPurchaseValue),l.style.fontSize="12px",l.style.lineHeight="16px",l.style.marginTop="4px",o.appendChild(l);const c=(0,Y.Ux)("div",{id:"dividerPcb"});c.style.marginTop="10px",c.style.width="auto",o.appendChild(c);const d=Date.now()+864e5,u=Math.floor(d/1e3),h=this.getExpirationWrapper(u);if(h.style.alignSelf="center",o.appendChild(h),e.IsRebatesUser()){const e=this.createActivatedButtonPcb();e.classList.add("pcbButtonAddressbar"),o.appendChild(e)}n.appendChild(o),this.pageHandlerModule.NavigateToUrlBackground(e.productAd.offer.url,e.productAd.offer.url,!1);const p=new t.Z(i.xu.PersonalizedCashbackAddressBarNotification);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Addressbar Personalized cashback rendered",p)}shouldRenderCashbackHistory(e){const t=e?.userRebatesResponse?.lifetimeBalance&&e?.userRebatesResponse?.isRebatesUser&&e?.userRebatesResponse?.latestCashbackApproved;return!(this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_REBATES_ORGANIC||this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_REBATES||this.flyoutData.common.openedWith===r.Te.Auto||!t)}renderCashbackHistory(e,t){if(!e||!t.userRebatesResponse?.lifetimeBalance)return;e.style.padding=t.isPersonalizedCashback?"0px 16px 0px":"16px 0px 0px";const n=(0,Y.Ux)("div",{id:"previousCashBackSection"}),o=(0,Y.Ux)("button",{id:"btnPreviousCashBack"}),a=(0,ne.qk)(t.userRebatesResponse?.latestCashbackApprovedCurrency),s=(0,Y.Ux)("div");if(t.isPersonalizedCashback){o.classList.add("isPersonalized");const e=(0,Y.Ux)("div",{style:"display: flex; flex-direction: row;"}),i=(0,Y.Ux)("p",{id:"txtMyCashBack",className:"txtSmall"});i.textContent=this.flyoutData.strings.myCashback;const n=(0,Y.Ux)("div",{id:"divLifetimeEarned"}),r=(0,Y.Ux)("p",{id:"txtLifetimeEarned",className:"txtSmall"});r.textContent=(0,Y.oZ)(this.flyoutData.strings.lifetimeearned);const l=(0,Y.Ux)("div",{style:"display: inline-flex; font-family: inherit;"});let c,d;if(t.userRebatesResponse?.lifetimeBalance){const e=this.utilities.formatPrice(t.userRebatesResponse?.lifetimeBalance),i=(0,ne.nR)(e);"object"==typeof i?(c=i.dollars,d=i.cents):c=e}const u=(0,Y.Ux)("span",{id:"txtPriceDecorative"},a),h=(0,Y.Ux)("span",{id:"txtPriceBalance"},c),p=(0,Y.Ux)("span",{id:"txtPriceDecorative"},d??"00");l.appendChild(u),l.appendChild(h),l.appendChild(p),l.setAttribute("aria-label",u+c+"."+p.textContent),n.appendChild(r),n.appendChild(l),e.appendChild(i),e.appendChild(n),s.appendChild(e)}else{s.id="divPreviousCashBack",this.flyoutData.common.isPane&&o.classList.add("isPane");const e=(0,Y.Ux)("div",{id:"divLastCashbackInfo"}),i=(0,Y.Ux)("p",{id:"txtLastCashbackInfo",className:"txtSmall"});if(i.textContent=this.getMostRecentTransactionString(t.userRebatesResponse),e.appendChild(i),this.addPreviousTransactionsLink(e),s.appendChild(e),t.userRebatesResponse?.cashbackAvailable){const e=(0,Y.Ux)("div",{id:"divCashbackBalances"}),i=(0,Y.Ux)("p",{id:"txtGreyBalance",className:"txtSmall"});i.textContent=(0,Y.oZ)(this.flyoutData.strings.cbCurrBalance);const n=(0,Y.Ux)("p",{id:"txtCashbackAmount",className:"txtMedium"});n.textContent=`${a}${this.utilities.formatPrice(t.userRebatesResponse?.cashbackAvailable)}`,e.append(i),e.appendChild(n);const o=(0,Y.Ux)("p",{id:"txtGreyBalance",className:"txtSmall"});o.style.width="max-content";const r=this.utilities.toFixedSafe(t.userRebatesResponse?.lifetimeBalance,2);o.textContent=(0,T.fZ)("lifetimeEarned",this.flyoutData.strings.cbLifetimeEarned,`${a}${r}`),e.appendChild(o),s.appendChild(e)}}if(o.appendChild(s),o.addEventListener("click",(()=>{const e=new W.Z(i.$S.PreviousCashBack,this.telemetryUtilities.setContentViewed(r.ModuleNames.CASHBACK));this.pageHandlerModule.RecordAsUserAction(K.bS.REBATES_HISTORY),this.pageHandlerModule.RecordAsUserEngagement(q.FV.REBATES_HISTORY,this.flyoutData.common.popupOrigination),this.logModule.LogInfoEvent(i.R.ButtonClick,"User navigated to previous cash back",e,Jl.g.CouponImpressionId),this.pageHandlerModule.NavigateToRebatesPayouts(ju.$.NEW_FOREGROUND_TAB)})),n.appendChild(o),t.isPersonalizedCashback){const t=e.querySelector("#pcbRows"),i=e.querySelector(".newSeeMore");t&&i?(t.insertBefore(n,i),i.addEventListener("click",(()=>{t.removeChild(n),t.appendChild(n)}))):t?t.appendChild(n):e.appendChild(n)}else e.appendChild(n)}isTripleCashbackQualified(){const e=this.flyoutData.dataStoreModule.CashBackData?.categories;if(e)for(let t=0;t<e.length;t++){const i=e[t];if(i.category?.toLowerCase().includes(tt.eS))return!0}return!1}isDelayedCashbckActivatedin24Hrs(e){if(e.has(this.flyoutData.common.domain)){const t=e.get(this.flyoutData.common.domain);if(t&&Date.now()-t<864e5)return!0}return!1}getIncentiveCashbackValues(){const e=this.flyoutData.dataStoreModule.CashBackData?.highestCashBackCategory?.commissionType,t=this.flyoutData.dataStoreModule.CashBackData?.highestCashBackCategory?.commissionValue;if(this.is3xIncentiveOfferValid()&&t){let i=t/3;return i%1!=0&&(i=i.toFixed(2)),{newIncentiveCashback:"%"===e?`${t}%`:`$${t}`,oldCashback:"%"===e?`${i}%`:`$${i}`}}return{newIncentiveCashback:void 0,oldCashback:void 0}}is3xIncentiveOfferValid(){const e=(0,T.uf)(this.flyoutData.dataStoreModule.ApiData?.market,this.flyoutData.dataStoreModule.ApiData?.retailerData?.exclusiveMarket),t=this.flyoutData.dataStoreModule.ApiData?.aFDMarket,i=this.flyoutData.dataStoreModule.CashBackData?.highestCashBackCategory?.commissionType,n=this.flyoutData.dataStoreModule.CashBackData?.highestCashBackCategory?.commissionValue;return!("en-us"!==e&&"en-us"!==t||!i||!n||!this.isTripleCashbackQualified())}async checkIsEligibleForBlossomCampaign(){if(!e.R.isExperimentActive(f.H.blossomCampaign))return!1;const t=this.flyoutData.common.domain;if(!["bedbathandbeyond.com","chewy.com","homedepot.com","hsn.com","kroger.com","landsend.com","lowes.com","macys.com","marksandspencer.com","nike.com","photo.walgreens.com","qvc.com","sephora.com","shutterfly.com","staples.com","ulta.com","vistaprint.com","walgreens.com","zoro.com"].includes(t))return this.logBlossomCampaignTelemetry(`Domain not eligible for Blossom campaign. Domain: ${t}`,!1),!1;const i=await this.getBlossomStatus(),n="EligibleUser"===i;return this.logBlossomCampaignTelemetry(`User is ${n?"":"not "}eligible for Blossom campaign. Status: ${i}`,!1),n}async getBlossomStatus(){if(!e.R.isExperimentActive(f.H.blossomCampaign))return"";const t=await this.storageUtilities.getStorageString(Ce.Q.BlossomCampaignUserStatus),i=Number(await this.storageUtilities.getStorageString(Ce.Q.BlossomCampaignUserStatusTimestamp));if(t&&!isNaN(i)&&(new Date).getTime()-i<3e5)return this.logBlossomCampaignTelemetry(`Using cache for user Blossom campaign eligibility. Status: ${t}`,!1),t;this.logBlossomCampaignTelemetry("Checking for user eligibility in Blossom campaign",!1);const n=await(0,we.H)(this.pageHandlerModule);return n?await this.getBlossomCampaignUserStatus(n):(this.logBlossomCampaignTelemetry("Anid not available",!1),"")}async shouldShowBlossomPostPurchase(e){const t=await this.storageUtilities.getStorageString(Ce.Q.BlossomShouldShowPostPurchaseUX,!0);return"true"!==t||e||await this.storageUtilities.clearStorage(Ce.Q.BlossomShouldShowPostPurchaseUX),"true"===t}shouldRenderFREAnimation(t,i){if(i)return!1;const n=(0,T.uf)(this.flyoutData.common.market,this.flyoutData.dataStoreModule.ApiData?.retailerData?.exclusiveMarket);return!!["en-us","en-ca","en-gb"].some((e=>e===n))&&(!!e.R.isExperimentActive(t)&&(!!this.isNewOrPassiveUser()&&!this.isFREAnimationShownAlready()))}createCashbackOfferDetails(e,t,i){let n=e;const o=(0,Y.Ux)("div",{id:"divCashBackCategoriesPopup"});o.style.padding="16px",o.style.marginTop="12px",o.style.display=n?"flex":"none";const r=(0,Y.Ux)("div",{className:"txtXSmall",id:"divCashBackCategoriesContent"});this.populateCashbackCategoriesList(r,t.categories,t.exclusions),o.appendChild(r);const a=this.CreateSeeMoreButton(n);return a.addEventListener("click",(e=>{o.style.display=n?"none":"flex",n=!n,i(),this.SeeMoreButtonAddContent(a,n)})),[o,a]}CreateSeeMoreButton(e){const t=document.createElement("fluent-button");return t.className+="btnSeeMore",t.id="offerDetails",t.style.fontWeight="400",t.classList.add("newSeeMore"),t.appearance="neutral",this.SeeMoreButtonAddContent(t,e),this.utilities.isDarkMode()?t.style.color="#FFFFFF":t.style.color="#1A1A1A",t.style.marginLeft="0px",t.style.marginTop="12px",t}SeeMoreButtonAddContent(e,t){const i=(0,Y.Ux)("DIV");i.style.display="inline-block",i.style.paddingLeft="10px",i.style.verticalAlign="middle",i.style.paddingBottom="3px",i.innerHTML=this.commonAssets.getCaretDownIcon(),e.textContent=t?this.flyoutData.strings.cbOfferSeeLessButtonTitle:this.flyoutData.strings.cbOfferDetailsButtonTitle,t&&(i.style.transform="rotate(180deg)",i.style.paddingRight="10px",i.style.paddingLeft="0px"),e.appendChild(i)}async populateCashbackCategoriesList(e,t,i){if(e&&t.length>0){for(let i=0;i<t.length;i++){const n=t[i],o=(0,Y.Ux)("div",{id:"divCatgoryRow"+i,style:"display: flex; flex-direction: row;"}),r=this.utilities.retrieveCashBackAmount(null,!1,n).cashBackAmount,a=this.utilities.createCommissionArrow(r,!1,zu.h.Small),s=(0,Y.Ux)("div",{className:"txtXSmall",id:"divCatgoryDetail"+i});o.style.marginBottom="12px",s.style.marginLeft="12px",s.style.textAlign="left",s.innerText=n.category,a.style.display="flex",a.style.alignSelf="center",o.appendChild(a),o.appendChild(s),o.setAttribute("aria-label",r+" "+n.category),e.appendChild(o)}if(i){const t=(0,Y.Ux)("div",{id:"divCategoryExclusions",style:"font-size: 10px; line-height: 14px;"});t.style.color="var(--light-foreground-foreground-4, var(--color-neutral-foreground-4-rest, #707070))",t.style.marginTop="4px",t.style.textAlign="left",t.innerText=this.flyoutData.strings.cashbackExclusionsTitle+": "+i+".",t.setAttribute("aria-label",this.flyoutData.strings.cashbackExclusionsTitle+": "+i),e.appendChild(t)}}}isFREAnimationShownAlready(){const e=(0,h.WN)("cbAnimShown");if(Array.isArray(e)){const t=e?.length;if(!(t<3))return!0;{const i=new Date(e[t-1]),n=new Date,o=Math.abs(n.getTime()-i.getTime());if(Math.ceil(o/tt.Jg)<7)return!0}}return!1}isNewOrPassiveUser(){const e=this.flyoutData.dataStoreModule.CashBackData?.userRebatesResponse;return!(!e||!e.isRebatesUser||e.lifetimeBalance&&e.lifetimeBalance>0)}getExpirationWrapper(e){const t=(0,Y.Ux)("div",{id:"divExpirationStringPcb"}),i=(0,Y.Ux)("span");i.style.color=this.utilities.isDarkMode()?"rgba(250, 124, 82, 1)":"rgba(196, 43, 28, 1)",i.textContent=this.getTimeDifference(Date.now(),1e3*e);const n=(0,Y.Ux)("DIV");return n.setAttribute("aria-hidden","true"),n.classList.add("microsoftLogo"),n.innerHTML=this.commonAssets.getMicrosoftLogo(),(0,T.B7)(t,this.flyoutData.strings.pcbExpirationText,n,i),t}getMostRecentTransactionString(e){let t,i="";if(!(e?.latestOrderDate&&e?.latestCashbackApprovedCurrency&&e?.latestCashbackApproved&&e?.latestOrderMerchantName))return i;const n=e.latestOrderDate?.split(" ");if(n&&n.length>0){const e=new Date(n[0]),i=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];e&&null!==e.getMonth()&&e.getDate()&&e.getFullYear()&&(t=`${i[e.getMonth()]} ${e.getDate()}, ${e.getFullYear()}`)}const o=(0,ne.qk)(e.latestCashbackApprovedCurrency),r=o+this.utilities.toFixedSafe(e.latestCashbackApproved,2);return r!==o&&t&&(i=(0,T.fZ)("cbPreviousCashbackDomain",this.flyoutData.strings.cbPreviousCashbackDomain,r,t,e.latestOrderMerchantName)),i}addPreviousTransactionsLink(e){const t=(0,Y.Ux)("fluent-anchor",{id:"btnPreviousTransactions",className:"action"});t.slot="action",t.href="#",t.appearance="lightweight",t.textContent=this.flyoutData.strings.cbPreviousTransactions,t.addEventListener("click",(()=>{const e=new W.Z(i.$S.RebatesAccount,this.telemetryUtilities.setContentViewed(r.ModuleNames.CASHBACK));this.pageHandlerModule.RecordAsUserAction(K.bS.REBATES_ACCOUNT),this.pageHandlerModule.RecordAsUserEngagement(q.FV.REBATES_ACCOUNT,this.flyoutData.common.popupOrigination),this.logModule.LogInfoEvent(i.R.ButtonClick,"User navigated to rebates account",e,Jl.g.CouponImpressionId)})),e.appendChild(t)}getTimeDifference(e,t){let i=t-e;i<0&&(i=0);const n=36e5;let o=i/n;i%=n,o|=0;let r=i/6e4;return i%=6e4,r|=0,0===o?r+"m":o+"h "+r+"m"}async renderListPcbMobile(e,t,i){const n={isSignedIn:!1,activatedOffers:e.adsCashback};new xg(i,this.utilities,this.pageHandlerModule,n,t).renderActivatedOffers()}async renderListPcb(e,t,i){const n=[];for(let t=0;t<e?.adsCashback?.length;t++){const i=e.adsCashback[t];!i?.scope||""===i.scope||0!==t&&"storewide"!==i?.scope?.toLowerCase()&&i?.scope===e.adsCashback[t-1]?.scope||n.push(i)}t.style.alignItems="normal";const o=(0,Y.Ux)("DIV",{id:"pcbRows"});o.style.display="flex",o.style.flexDirection="column",o.style.rowGap="2px",await this.populateActiveListPcb(o,!1,!1,n),t.appendChild(o),this.utilities.createCommonListStructure(o,"",n,this.moduleName,(function(e){let t=r.CS.PREVIOUS_CASHBACKREFRESH;return e&&i.common.bannerContext===r.De.VIEWALL&&(t=e.length),t}),this.populateActiveListPcb.bind(this)),o.style.marginBottom="0px";const a=o.querySelector(".newSeeMore");a&&(a.style.marginLeft="0px",a.style.marginTop="10px")}async populateActiveListPcb(e,t,i,n){if(n){let o=0;n.length>0&&(o=n.length);let a=0;if(t){const t=r.CS.PREVIOUS_CASHBACKREFRESH-1,i=e?.querySelector("#productRow"+t);i&&(i.isLast=!1)}t?a=r.CS.PREVIOUS_CASHBACKREFRESH:o>r.CS.PREVIOUS_CASHBACKREFRESH&&(o=r.CS.PREVIOUS_CASHBACKREFRESH);for(let s=a;s<o;s++){const l=n[s];if(l?.scope&&""!==l.scope){const n=await this.createCardPcb(l,s,s===o-1);n.id="productRow"+s,s===a&&t&&i&&this.flyoutData.common.currentDevice===r.AS.Desktop&&n.focus(),e.appendChild(n)}}return Promise.resolve()}return Promise.resolve()}async createCardPcb(e,t,i){const n=document.createElement("msft-cashback-card");n.href="#";const o=0===t;return n.isFirst=o,n.isLast=i,n.domain=e.domain,this.flyoutData.common.isPane&&(n.isPane=this.flyoutData.common.isPane),this.createTitlePcb(e,n),this.createCardImagePcb(e,n),e.productUrl&&""!==e.productUrl?n.addEventListener("click",(async t=>{t.preventDefault(),this.pageHandlerModule.RecordAsUserAction(K.bS.CLICK_PCB_CROSS_SESSION),this.pageHandlerModule.NavigateToUrl(e.productUrl+"&fromAdsFlyout=1")})):n.style.pointerEvents="none",this.createFavIcon(e,n),"storewide"!==e.scope?.toLowerCase()?(n.cashbackStr=this.flyoutData.strings.cbFeatureName,n.scope=e.scope):n.scope=this.flyoutData.strings.pcbStorewideCashback,this.createExpiryTimePcb(e,n),n}createCardImagePcb(e,t){const i=(0,Y.Ux)("IMG",{id:"productImage"});e.imageUrl&&""!==e.imageUrl?e.imageUrl.indexOf("bing.com")>0?i.src=e.imageUrl:i.src="https://www.bing.com"+e.imageUrl:i.src=this.utilities.getFavIconSrc(e.domain,64),i.setAttribute("aria-label",e.scope),i.style.height="100%",i.style.width="100%",i.style.objectFit="contain",i.style.top="16px",i.style.left="16px";const n=this.utilities.createProductImage(64,64,i);n.slot="image",t.appendChild(n)}createTitlePcb(e,t){const i=this.utilities.retrieveCashBackAmount(e),n=i.cashBackAmount;this.currencySymbol=i.currencySymbol,"storewide"===e.scope?.toLowerCase()?(t.cashBackAmount=(0,T.fZ)("pcbCommissionStoreWide",this.flyoutData.strings.pcbCommissionStoreWide,n),t.minPurchaseValue=(0,T.fZ)("pcbCommissionStoreWideOff",this.flyoutData.strings.pcbCommissionStoreWideOff,this.currencySymbol+e.minPurchaseValue)):t.cashBackAmount=n;const o=(0,Y.Ux)("DIV");o.slot="cashBack",t.appendChild(o)}createExpiryTimePcb(e,t){const i=(0,Y.Ux)("DIV"),n=(0,Y.Ux)("SPAN");n.style.color="rgba(196, 43, 28, 1)",n.textContent=this.getTimeDifference(Date.now(),1e3*e.expireTimeEpoch),(0,T.B7)(i,this.flyoutData.strings.cbExpiryDateTime,n),i.slot="expireTime",t.appendChild(i)}createFavIcon(e,t){const i=(0,Y.Ux)("DIV",{id:"favIconRow"}),n=(0,Y.Ux)("IMG",{id:"domainFavIcon"});n.style.maxHeight="18px",n.style.maxWidth="18px",this.utilities.addFavIconSrc(n,i,e.domain),i.slot="icon",t.appendChild(i)}createImagePcb(e){const t=(0,Y.Ux)("IMG",{id:"productImage"});e.imageUrl&&""!==e.imageUrl?e.imageUrl.indexOf("bing.com")>0?t.src=e.imageUrl:t.src="https://www.bing.com"+e.imageUrl:t.src=`${this.flyoutData.common.resourcesEndpoint}retailerBranding/SquareIcons/${e.domain}.png`,t.setAttribute("aria-label",e.scope),t.style.height="100%",t.style.width="100%",t.style.objectFit="contain";const i=(0,Y.Ux)("DIV");i.style.width="88px",i.style.height="88px",i.style.position="relative",i.appendChild(t);const n=this.utilities.createProductImage(88,88,t);return n.slot="image",n}createActivatedButtonPcb(){const e=(0,Y.Ux)("div",{id:"divEnabledPcb"}),t=(0,Y.Ux)("div",{style:"height: 20px;"});t.innerHTML=this.commonAssets.getGreenCheck(),t.slot="start",t.setAttribute("aria-hidden","true");const i=(0,Y.Ux)("span",{style:"font-size: 14px;"});return i.textContent=this.flyoutData.strings.pcbActivatedButton,e.appendChild(t),e.appendChild(i),e}async getBlossomCampaignUserStatus(e){const t={headers:{"Content-Type":"application/json",Origin:"chrome-untrusted://shopping"},method:"GET"},i=`https://www.bing.com/api/shopping/v1/grocery/campaigns/projectBlossom022024/status?anid=${e}`;try{const e=await fetch(i,t),n=await e.json();if(200===e.status){const e=n?.userStatus??"";return this.storageUtilities.setStorageString(Ce.Q.BlossomCampaignUserStatus,e),this.storageUtilities.setStorageString(Ce.Q.BlossomCampaignUserStatusTimestamp,(new Date).getTime().toString()),e}throw new Error(`HTTP error. status: ${e.status}`)}catch(e){return this.logBlossomCampaignTelemetry("getBlossomCampaignUserStatus: Failed to fetch user enrollment in Blossom campaign",!0),""}}logBlossomCampaignTelemetry(e,n){const o=new t.Z(i.xu.CashBackBlossomCampaign);n?this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,e,o):this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,e,o)}},wg=class{constructor(e,t,i,n,o,r,a,l,c=!1){this.flyoutData=e,this.stateManagement=t,this.storageHandler=i,this.logModule=n,this.pageHandlerModule=o,this.isCompositeNotification=c,(0,s.Z)(this,"cashbackUtilities",void 0),(0,s.Z)(this,"cachedCanRenderCashback",!1),(0,s.Z)(this,"estimatedCashbackData",void 0),this.cashbackUtilities=new Tg(e,o,n,r,l,a,i)}async shouldRenderNotification(){if(!this.isCompositeNotificationValidIfThisIsComposite())return Promise.resolve(!1);const e=this.flyoutData.dataStoreModule.CashBackData;let t=!1;const i=this.stateManagement.getState(Ku.IY.canRenderAutoApply);this.estimatedCashbackData=await this.getEstimatedCashbackData(),i||(t=this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_REBATES||this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_REBATES_CHECKOUT);let n=!1;const o=this.flyoutData.dataStoreModule.ApiData?.retailerData?.orderConfirmationPageUrl;if(o&&e?.isPersonalizedCashback){const t=new RegExp(o,"i");n=e.isPersonalizedCashback&&t.test(this.flyoutData.common.lastCommittedURL)}const a=e?.estimatedCashbackData?.isPdp&&this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_REBATES_PDP;return this.flyoutData.common.openedWith===r.Te.Auto&&this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_ADDRESSBAR?Promise.resolve(!0):Promise.resolve((e&&e.shouldRenderCashBackNotification&&(this.flyoutData.common.isRebatesEnabled||e.isSignInSupportedDomainCashBack)&&this.flyoutData.common.openedWith===r.Te.Auto&&(a||this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_REBATES_CONFIRMATION||this.isCompositeNotification&&this.isPopupOriginationForCompositeNotification()||this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_REBATES_DEACTIVATED||(this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_CONFIRMATION||this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_REBATES_SWITCHED_TO_MSA)&&n||this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_REBATES_ORGANIC||this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_REBATES_ORGANIC_NEW||this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK&&!e?.isSpbActivated||t))??!1)}async canRenderCashback(){if(this.flyoutData.common.suppressRebatesScenarios)return Promise.resolve(!1);if(this.cachedCanRenderCashback)return this.cachedCanRenderCashback;const e=this.flyoutData.dataStoreModule.CashBackData;if(e&&!e.IsRebatesUser()){if(!e.isSignInSupportedDomainCashBack&&!e.isLinkYourMSAWorkflow)return!1;this.pageHandlerModule.TriggerExperiment(f.H.signinRebates)}this.estimatedCashbackData=await this.getEstimatedCashbackData();const n=e?.canRenderCashback??!1;if(!n){const n=new t.Z(i.xu.CashBackWillNotRender),o={profile:e?.isEdgeProfile?i.E_.Edge:i.E_.Bing,isRebatesUser:e?.IsRebatesUser(),isRebatesSupportedDomain:e?.IsRebatesSupportedDomain??!1,commisionValue:e?.highestCashBackCategory?.commissionValue??""};n.Metadata=JSON.stringify(o),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatusDiagnostic,"",n)}return this.cachedCanRenderCashback=n,Promise.resolve(n)}async canRenderActivateModule(){const e=await this.canRenderCashback(),t=this.flyoutData.dataStoreModule.CashBackData,i=t?.IsRebatesUser()??!1,n=t?.isCashBackActivated??!1,o=this.isMergedScenario(),r=this.flyoutData.common.isCheckoutPage,a=t?.isPersonalizedCashback??!1,s=t?.isAddressBarPersonalizedCashback??!1,l=this.isPopupOriginationForCompositeNotification();return Promise.resolve(i&&!n&&e&&!o&&!r&&!a&&!s&&!l)}async canRenderDelayedEnrollmentModule(){const e=await this.canRenderCashback(),t=this.flyoutData.dataStoreModule.CashBackData,i=t?.isSignInSupportedDomainCashBack??!1,n=this.flyoutData.common.isCheckoutPage,o=t?.isPersonalizedCashback??!1,r=t?.isAddressBarPersonalizedCashback??!1,a=this.isPopupOriginationForCompositeNotification(),s=this.flyoutData.common.isPane;return Promise.resolve(i&&e&&s&&!n&&!o&&!r&&!a)}async shouldRender(e){if(!this.isCompositeNotificationValidIfThisIsComposite())return Promise.resolve(!1);const t=this.flyoutData.dataStoreModule.CashBackData,i=await this.canRenderCashback();void 0===e&&(e=this.isMergedScenario());const n=this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_CASHBACK_PDP_PLUS_COUPONS&&i&&(!e||e&&this.cashbackUtilities.shouldRenderCashbackHistory(t));return Promise.resolve(n)}isMergedScenario(){const e=this.flyoutData.dataStoreModule.CashBackData;return(this.flyoutData.dataStoreModule.CouponData?.isCheckoutPageWithAutoApply&&!this.flyoutData.dataStoreModule.CashBackData?.isCashBackActivated&&!(this.flyoutData.common.openedWith===r.Te.Auto&&this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_REBATES_ORGANIC)&&this.flyoutData.dataStoreModule.UserInfo.isMSASignedIn&&(e?.IsRebatesUser()??!1))??!1}async getEstimatedCashbackData(){const e=this.flyoutData.dataStoreModule.CashBackData;if(e)return this.estimatedCashbackData||(this.estimatedCashbackData=await e.getEstimatedCashbackData(this.flyoutData,this.storageHandler,this.logModule)),this.estimatedCashbackData}isPopupOriginationForCompositeNotification(){return!!this.flyoutData.common.popupOrigination&&Be.includes(this.flyoutData.common.popupOrigination)}isCompositeNotificationValidIfThisIsComposite(){return this.isPopupOriginationForCompositeNotification()===this.isCompositeNotification}},Og=o(49259),Pg=class extends Qu{constructor(e,t,i,n){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"estimatedCashbackData",void 0),(0,s.Z)(this,"cashbackStyles",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"uxUtilities",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"footerUtilities",void 0),(0,s.Z)(this,"tooltipUtilities",void 0),(0,s.Z)(this,"cashbackUtilities",void 0),(0,s.Z)(this,"spbComponentUtils",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"cashbackMetadata","{}"),(0,s.Z)(this,"stylesAdded",!1),(0,s.Z)(this,"isMergedScenario",!1),(0,s.Z)(this,"activateCashbackButtonCreator",void 0),(0,s.Z)(this,"isCashBackOfferDetailsVisible",!1),(0,s.Z)(this,"cashbackComponents",void 0),(0,s.Z)(this,"cashbackTelemetry",void 0),(0,s.Z)(this,"activateCashbackRenderedTitle",""),(0,s.Z)(this,"activateCashbackRenderedButtonText",""),(0,s.Z)(this,"shouldShowBlossomPostPurchase",!1),this.uxUtilities=i,this.logModule=i.logModule,this.pageHandlerModule=i.pageHandlerModule,this.stateManagement=e,this.flyoutData=t,this.utilities=i.viewModulesUtilities,this.storageHandler=i.storageHandler,this.footerUtilities=i.footerUtilities,this.tooltipUtilities=i.tooltipUtilities,this.cashbackUtilities=new Tg(t,i.pageHandlerModule,i.logModule,i.viewModulesUtilities,this.GetModuleName(),i.telemetryHandler,i.storageHandler),this.spbComponentUtils=new pg(t,i,n),this.assets=new tg,this.commonAssets=n,this.cashbackComponents=new og(this.stateManagement,this.flyoutData,this.pageHandlerModule,this.logModule,this.utilities,this.tooltipUtilities,this.telemetryUtilities,this.commonAssets),this.activateCashbackButtonCreator=new ag(this.stateManagement,this.flyoutData,this.uxUtilities,this.commonAssets,this.logModule,this.GetModuleName(),this.estimatedCashbackData),this.cashbackTelemetry=new ng(this.telemetryUtilities,this.flyoutData,this.pageHandlerModule,this.logModule),this.cashbackStyles=new ig(this.flyoutData,this.commonAssets),this.setInitialStatesAndListeners(),this.telemetryUtilities=i.telemetryHandler}setInitialStatesAndListeners(){this.stateManagement.addEventListener(Ku.e1.StyleProcessingState,(e=>{e.detail&&e.detail.target&&this.cashbackStyles.styleProcessingState(e.detail.target)})),this.stateManagement.addEventListener(Ku.e1.onRebatesTelemetryFail,(e=>{if(e.detail&&e.detail.status){const n=new t.Z(i.xu.ErrorCashBackActivation),o=this.flyoutData.dataStoreModule.CashBackData,r=JSON.stringify({profile:o?.isEdgeProfile?i.E_.Edge:i.E_.Bing,affiliateNetwork:o?.affiliateNetwork,commission:o?.highestCashBackCategory?.commissionValue+","+o?.highestCashBackCategory?.commissionType,merchantFullName:o?.merchantFullName,merchantId:o?.merchantId,merchantName:o?.merchantName,merchantUri:o?.merchantUri,originalUrl:window.location.href});n.Metadata=r,this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Cashback activation error - ${e.detail.status}`,n)}})),this.stateManagement.addEventListener(Ku.e1.onRebatesTelemetrySuccess,(()=>{const e=JSON.stringify({profile:this.flyoutData.dataStoreModule.CashBackData?.isEdgeProfile?i.E_.Edge:i.E_.Bing}),n=new t.Z(i.xu.CashBackActivated);n.Metadata=e,this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Cashback activated",n)})),this.flyoutData.common.currentDevice===r.AS.Mobile?this.stateManagement.addEventListener(Ku.e1.onRebatesTelemetrySuccess,(()=>{this.updateFlyoutSuccessStatus()})):this.stateManagement.addEventListener(Ku.e1.rebatesSignInPendingSuccess,(()=>{this.updateFlyoutSuccessStatus()})),this.stateManagement.addEventListener(Ku.e1.rebatesSignInFail,(()=>{this.updateFlyoutFailStatus()})),this.stateManagement.addEventListener(Ku.e1.CreateCBLearnMore,(e=>{e.detail&&e.detail.callback&&(this.stylesAdded||this.activateCashbackButtonCreator.addCashbackStyles(!0),this.createSeeOffersButton(e.detail.callback))}))}GetModuleName(){return r.ModuleNames.CASHBACK}CalculateRanking(){const e=this.flyoutData.dataStoreModule.CashBackData;return e?e.isCashBackActivated?r.zz.InformRetailer:r.zz.SaveMoneyRetailer:r.zz.Unknown}async ShouldRenderModule(){if(e.R.isExperimentActive(f.H.cashbackConsolidationExp))return Promise.resolve(!1);const t=new wg(this.flyoutData,this.stateManagement,this.storageHandler,this.logModule,this.pageHandlerModule,this.utilities,this.telemetryUtilities,r.ModuleNames.CASHBACK);this.estimatedCashbackData=await t.getEstimatedCashbackData(),this.activateCashbackButtonCreator.setEstimatedCashbackData(this.estimatedCashbackData),await t.canRenderCashback()&&!this.stylesAdded&&(this.stylesAdded=!0,this.activateCashbackButtonCreator.addCashbackStyles()),this.isMergedScenario=await t.isMergedScenario();const i=await t.canRenderActivateModule();if(e.R.getServiceExperimentValue(f.H.cbSplitModules)===Yu.l1.CashBackActivateModule&&i)return Promise.resolve(!1);const n=await t.canRenderDelayedEnrollmentModule();if(e.R.isExperimentActive(f.H.cashBackDelayedEnrollmentEdgeFlow)&&n)return Promise.resolve(!1);const o=await t.shouldRender(),a=this.flyoutData.dataStoreModule.CashBackData?.isConfirmationPage,s=["EligibleUser","OfferClaimed","PayoutCompleted"].includes(await this.cashbackUtilities.getBlossomStatus()),l=await this.cashbackUtilities.shouldShowBlossomPostPurchase(!0);return o&&a&&s&&!l?(await new Promise((e=>setTimeout(e,3e3))),!0):o}populateMainHeader(){if(this.flyoutData.common.shopping){const e=this.flyoutData.common.shopping.querySelector("#cashBackSection");e&&(this.flyoutData.common.isPane&&!this.isPersonalizedCashbackListUX()||(e.style.marginTop="10px"),e.slot="header-content")}}async renderModule(){"true"===(0,h.Mw)(Jp.Q.CashBackOfferDetailsVisible)&&(this.isCashBackOfferDetailsVisible=!0,(0,h.Xo)(Jp.Q.CashBackOfferDetailsVisible,"false")),this.stylesAdded||this.activateCashbackButtonCreator.addCashbackStyles(!0),this.flyoutData.common.openedWith===r.Te.Auto&&this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK&&(this.pageHandlerModule.RecordAsUserAction(K.bS.ACTIVATE_CASHBACK_RETURNED),this.pageHandlerModule.RecordAsUserEngagement(q.FV.ACTIVATE_CASHBACK_RETURNED,this.flyoutData.common.popupOrigination));const n=this.flyoutData.dataStoreModule.CashBackData;if(n){const o=await this.storageHandler.getStorageString(Ce.Q.ShoppingTripsActivateRebateDomain);n.merchantName&&o===n.merchantName&&(this.storageHandler.clearStorage(Ce.Q.ShoppingTripsActivateRebateDomain),n.isCashBackActivated||await this.pageHandlerModule.ActivateRebates(!1));const a=document.createElement("msft-edge-shopping-section");a.id="cashBackSection",a.style.width="100%",this.flyoutData.dataLoader.GetLoadTimeDataValue("isMobile",!1)||(a.accordion=!0,a.expanded=!1);const s=(0,Y.Ux)("div",{id:"divCashBackPopup"});this.flyoutData.common.isPane?(s.style.padding="16px 8px",n.isPersonalizedCashback||(s.style.backgroundColor="var(--fill-color)",s.style.borderRadius="8px")):this.flyoutData.common.openedWith!==r.Te.Auto||n.isPersonalizedCashback||s.classList.add("lateralMargin"),n.isCashBackActivated&&(this.isCashBackOfferDetailsVisible=!1);const l=this.flyoutData.dataStoreModule.SPBItemizedCashbackData?.SpbPDPData;if(l?.ItemizedCashbackExactMatch?.isActivated){const e="pdpSPB"===this.flyoutData.dataStoreModule.SPBItemizedCashbackData?.PageInfoType,t=this.spbComponentUtils.createElementForOfferV2Card(l.ItemizedCashbackExactMatch,e?i.e4.SPBPdpPage:"",i.xu.SPBActivatedOfferHover,e,!1,!1,"");if(t.wrapper.style.padding="0",t.content.style.paddingLeft="16px",t.content.style.paddingRight="16px",t.content.style.textAlign="left",s.appendChild(t.rootDiv),n.personalizedCashback?.adsCashback&&n.personalizedCashback.adsCashback.length>0){const e=l.ItemizedCashbackExactMatch.adsOffer.destinationUrl||"";n.personalizedCashback.adsCashback=n.personalizedCashback.adsCashback.filter((t=>{const i=t.destinationUrl||t.productUrl;return(0,Ie.ru)(i)!==e}))}}if(e.R.isExperimentActive(f.H.pcbAddressBar)&&this.flyoutData.common.openedWith===r.Te.Auto&&this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_ADDRESSBAR){const e=(0,Y.Ux)("div",{id:"divCashBackContent"});if(await this.cashbackUtilities.renderAddressBarPersonalizedCashback(n,e),s.appendChild(e),a.appendChild(s),!n.IsRebatesUser()){const t=this.createSeeOffersButton();t&&e.appendChild(t);const i=this.createPrivacyMessage();i&&e.appendChild(i)}const t=r.SV.BLOCK,i=this.CreateModule(a,r.H7.CASHBACK,r.ModuleNames.CASHBACK,r.$k.CONTEXTUAL,t),o=await this.storageHandler.getStorageString(Ce.Q.PCBStorewideAddressBar,!1),l=(0,T.BQ)(o);return l[this.flyoutData.common.domain]=null,this.storageHandler.setStorageString(Ce.Q.PCBStorewideAddressBar,JSON.stringify(l)),this.storageHandler.clearStorage(Ce.Q.IsNavigatedFromAddressBarPersonalizedCashback),Promise.resolve(i)}const c=this.flyoutData.common.isPane&&n?.personalizedCashback?.adsCashback?.length>0&&"amazon.com"===this.flyoutData.common.domain?n.personalizedCashback.adsCashback[0]:n.personalizedCashback;if(""!==this.utilities.retrieveCashBackAmount(c).cashBackAmount){const o=(0,Y.Ux)("div",{className:"txtMedium",id:"divCashBackContent"}),l=this.cashbackUtilities.is3xIncentiveOfferValid();n.isPersonalizedCashback?await this.cashbackUtilities.renderPersonalizedCashback(n,o):l&&(s.style.padding="0px",s.style.paddingBottom="10px",await this.cashbackUtilities.createCashback3xIncentiveOfferBody(n,o,this.cashbackComponents));const c=this.flyoutData.dataStoreModule.CampaignData?.expData.endTime;if(!this.flyoutData.dataStoreModule.CampaignData?.expData.isCampaignActive()||!c||n.isPersonalizedCashback||l||this.estimatedCashbackData?.cashbackValue){if(this.flyoutData.dataStoreModule.CashBackData?.isExclusiveOffer&&!n.isPersonalizedCashback&&!l){this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"User visited domain with exclusive deal",new t.Z(i.xu.ExclusiveOfferDomainVisited));const e=this.flyoutData.strings.cbExclusiveBadgeText,n=this.createExclusiveBadge(e);o.appendChild(n)}}else{const e=this.flyoutData.common.openedWith===r.Te.Auto,t=new gg(this.utilities,this.flyoutData,this.pageHandlerModule,this.logModule);e&&t.shouldRenderCUCBanner()||(o.appendChild(this.renderCampaignBanner(c)),a.classList.add("campaign-module"))}if(!n.isPersonalizedCashback&&!l){const e=("storewide"===n.highestCashBackCategory?.category?.toLowerCase()||"storewide"===n.personalizedCashback?.scope?.toLowerCase())??!1,t=await this.cashbackUtilities.checkIsEligibleForBlossomCampaign();this.shouldShowBlossomPostPurchase=!!this.flyoutData.common.isPane&&await this.cashbackUtilities.shouldShowBlossomPostPurchase();const i=t||this.shouldShowBlossomPostPurchase,r=(e,t)=>{if(!this.shouldShowBlossomPostPurchase&&this.flyoutData.dataStoreModule.CashBackData?.isConfirmationPage){let i=30;const n=setInterval((async()=>{const o=await this.cashbackUtilities.shouldShowBlossomPostPurchase();if(o){const i=e(o);t.textContent="",t.appendChild(i)}o||i<=0||!this.flyoutData.dataStoreModule.CashBackData?.isConfirmationPage?clearInterval(n):i--}),1e3)}};if(i&&!this.flyoutData.common.isPane){const e=e=>{const t=this.cashbackComponents.createBlossomInfoSection(e);return t.style.width="calc(100% + 32px)",t.style.marginTop="0px",t.style.marginBottom="8px",t},t=(0,Y.Ux)("div",{style:"width: 100%; display: flex; justify-content: center;"}),i=e(this.shouldShowBlossomPostPurchase);t.appendChild(i),o.appendChild(t),r(e,t)}const a=this.createCashBackTitle(n.isCashBackActivated,e,n,o);if(o.appendChild(a),i&&this.flyoutData.common.isPane){const e=e=>{const t=this.cashbackComponents.createBlossomInfoSection(e);return n.isCashBackActivated&&(t.style.width="calc(100% - 16px)"),t},t=(0,Y.Ux)("div",{style:"width: 100%; display: flex; justify-content: center;"}),i=e(this.shouldShowBlossomPostPurchase);t.appendChild(i),o.appendChild(t),r(e,t)}}const d=this.flyoutData.dataStoreModule.CampaignData?.retailerData?.specialCashBackOffer;if(d?.cashBackAmount&&d?.cashBackCondition&&o.appendChild(zp(d.cashBackAmount,d?.cashBackCondition)),n.isSignInSupportedDomainCashBack&&this.flyoutData.dataStoreModule.CouponData?.isCheckoutPageWithAutoApply){const e=(0,Y.lw)(this.utilities);e.id="rebatesButton",e.classList.add("lateralMargin"),this.renderCurrentButtonState(e),this.pageHandlerModule.TriggerExperiment(f.H.rewardFlyout),e.addEventListener("click",(async t=>{if(n?.isLinkYourMSAWorkflow)this.handleLinkYourMSAClick(e,"Link personal account started");else if(n?.isSignInSupportedDomainCashBack){const e=this.createClickData(i.$S.ActivateCashBack,n);this.utilities.isPinterest()?(this.pageHandlerModule.RecordAsUserAction(K.bS.PINTEREST_CASHBACK_ACTIVATED),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PINTEREST_CASHBACK_ACTIVATED,this.flyoutData.common.popupOrigination)):n.IsRebatesUser()?(this.pageHandlerModule.RecordAsUserAction(K.bS.ACTIVATE_CASHBACK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.ACTIVATE_CASHBACK,this.flyoutData.common.popupOrigination)):(this.pageHandlerModule.RecordAsUserAction(K.bS.ACTIVATE_CASHBACK_NEW),this.pageHandlerModule.RecordAsUserEngagement(q.FV.ACTIVATE_CASHBACK_NEW,this.flyoutData.common.popupOrigination)),this.logModule.LogInfoEvent(i.R.ButtonClick,"Sign in started",e,Jl.g.CouponImpressionId),await this.pageHandlerModule.ActivateRebates(!0)}else await this.handleActivateCashbackClick(e,t,"Cash back activation started")?this.cashbackStyles.styleActivatedState(e):this.cashbackStyles.styleDefaultState(e,this.flyoutData.common.isPane?this.flyoutData.strings.cbActivateButton:this.flyoutData.strings.cbActivateButtonRefresh)})),o.appendChild(e)}if(this.cashbackUtilities.shouldRenderFREAnimation(f.H.cbAnimationVar4,n?.isPersonalizedCashback)){const e=this.cashbackComponents.createAnimationDownVariation();o.appendChild(e)}if(this.flyoutData.common.openedWith!==r.Te.Auto||this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_REBATES&&this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_REBATES_ORGANIC&&this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_REBATES_PDP){if(!this.isMergedScenario){const e=this.createSeeOffersButton();if(this.flyoutData.common.openedWith!==r.Te.Auto||this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_REBATES&&this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_REBATES_ORGANIC)e&&o.appendChild(e);else{const e=(0,Y.Ux)("DIV");e.style.display="flex",e.id="cbButtonSection",e.style.flexDirection="column",e.style.marginTop="10px",e.style.marginBottom="2px",o.appendChild(e)}}}else{const e=this.createSeeOffersButton(),t=(0,Y.Ux)("DIV");t.style.display="flex",t.id="cbButtonSection",t.style.flexDirection="column",o.appendChild(t),e&&o.appendChild(e)}if(this.cashbackUtilities.shouldRenderFREAnimation(f.H.cbAnimationVar1,n?.isPersonalizedCashback)){const e=this.cashbackComponents.createAnimationArrowVariation(n?.isCashBackActivated);o.appendChild(e),this.cashbackComponents.createActivatedArrowAnimation()}if(n.isSignInSupportedDomainCashBack&&!e.R.isExperimentActive(f.H.cashBackDelayedEnrollmentEdgeFlow)){const e=this.createPrivacyMessage();e&&o.appendChild(e)}if(s.appendChild(o),a.appendChild(s),n.isPersonalizedCashback||(s.style.backgroundColor="var(--fill-color)",s.style.borderRadius="8px"),!n.isPersonalizedCashback&&n.categories.length>0&&this.flyoutData.common.isPane){const e=()=>{const e=new W.Z(i.$S.CashbackInfoOfferDetails,this.telemetryUtilities.setContentViewed(this.GetModuleName())),t=this.isCashBackOfferDetailsVisible?"User clicked on cashback categories see less":"User clicked on cashback offer details";this.logModule.LogInfoEvent(i.R.ButtonClick,t,e,Jl.g.CouponImpressionId),this.isCashBackOfferDetailsVisible?this.pageHandlerModule.RecordAsUserEngagement(q.FV.CASHBACK_MODULE_VIEW_OFFER_DETAILS_SEELESS_CLICK,this.flyoutData.common.popupOrigination):this.pageHandlerModule.RecordAsUserEngagement(q.FV.CASHBACK_MODULE_VIEW_OFFER_DETAILS_CLICK,this.flyoutData.common.popupOrigination),this.isCashBackOfferDetailsVisible=!this.isCashBackOfferDetailsVisible},[t,o]=this.cashbackUtilities.createCashbackOfferDetails(this.isCashBackOfferDetailsVisible,n,e);a.appendChild(t),a.classList.add("noInlinePadding"),a.appendChild(o),this.utilities.applyStyles(this.flyoutData.common.shopping,".headerBlock::part(header) {\n background-color: unset!important;\n }")}const h=this.isPersonalizedCashbackListUX()?r.SV.LIST:r.SV.BLOCK,p=this.CreateModule(a,r.H7.CASHBACK,r.ModuleNames.CASHBACK,r.$k.CONTEXTUAL,h);this.stateManagement.addEventListener(Ku.e1.onCashbackActivationError,(e=>{this.renderErrorState(e.detail.cashbackButton,e.detail.slot)})),this.stateManagement.addEventListener(Ku.e1.onCashBackActivated,(()=>{if(!0===a.accordion){const e=a.shadowRoot?.querySelector("span[part=title]");if(e){const t=this.flyoutData.strings.cbRebatesOn,i=(0,Y.Ux)("B");i.textContent=t;const n=this.flyoutData.strings.cbCashBackOnOff;(0,T.B7)(e,n,i)}}})),this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_REBATES&&this.pageHandlerModule.RecordAsUserEngagement(q.FV.ACTIVATE_CASHBACK,this.flyoutData.common.popupOrigination);const g=(0,fg.U)(this.flyoutData.dataStoreModule.ApiData?.retailerData,this.flyoutData.common.lastCommittedURL,this.flyoutData.common.extractedEntity),m=Og.Z.getFactory()?.getCasbackContext(),v=new t.Z(i.xu.CashBackNotificationImpression,void 0,void 0,this.flyoutData.common.domain,JSON.stringify({title:this.activateCashbackRenderedTitle,pageType:g,popupOrigination:this.flyoutData.common.popupOrigination,url:m?.getCurrentUrl(),openedWith:this.flyoutData.common.openedWith,cashback:n?.CreateLogMetadata(),personalizedCashback:n?.CreatePersonalizedCashbackLogMetadata()}));return this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Cashback notification shown",v),Promise.resolve(p)}}return Promise.resolve(null)}PostProcessing(n,o,a){const s=Og.Z.getFactory()?.getCasbackContext(),l=this.flyoutData.dataStoreModule.CashBackData;if(0!==o)this.SetSectionTitle(a);else if(this.flyoutData.common.isPane&&l&&!l.personalizedCashback){const e=(0,Y.Ux)("DIV");e.setAttribute("role","heading"),e.setAttribute("aria-level","2");const t=(0,Y.Ux)("h2",{id:"h2CashbackSectionTitle"});a.classList.contains("actionPane")&&(t.style.marginLeft="20px"),t.innerText=(0,T.fm)(this.flyoutData.strings.cbFeatureName),e.appendChild(t),a.prepend(e)}const c=this.flyoutData.dataStoreModule.CouponData?.isCheckoutPageWithAutoApply??!1,d=(l&&!l.isCashBackActivated&&!c&&(!l.isPersonalizedCashback||!l.IsRebatesUser())&&(!e.R.isExperimentActive(f.H.pcbAddressBar)||!l.isAddressBarPersonalizedCashback||!l.IsRebatesUser()))??!1,h=l?.shouldRenderCashBackNotification??!1;if(l){let e,t,n;l.highestCashBackCategory?(e=l.highestCashBackCategory.category,t=l.highestCashBackCategory.commissionType,n=l.highestCashBackCategory.commissionValue):l.personalizedCashback&&(e=l.personalizedCashback.scope,t=l.personalizedCashback.commissionType,n=l.personalizedCashback.commissionValue);const o=l?.isEdgeProfile?i.E_.Edge:i.E_.Bing,r=new qp(e,t,n,this.flyoutData.common.domain,l.affiliateNetwork,o,l.IsRebatesUser(),l.IsRebatesSupportedDomain?.toString()??"",l.isSignInSupportedDomain,l.merchantFullName,d||h?c?"merged with AA":"cashback section":"",!!this.estimatedCashbackData,(0,fg.U)(this.flyoutData.dataStoreModule.ApiData?.retailerData,this.flyoutData.common.lastCommittedURL,this.flyoutData.common.extractedEntity));this.logModule.LogInfoEvent(i.R.CashbackInfo,"",r,Jl.g.CouponImpressionId)}if(d){this.createActivateButton(o,a);const e=(0,fg.U)(this.flyoutData.dataStoreModule.ApiData?.retailerData,this.flyoutData.common.lastCommittedURL,this.flyoutData.common.extractedEntity),n=new t.Z(i.xu.ActivateCashBackNotificationImpression,void 0,void 0,this.flyoutData.common.domain,JSON.stringify({title:this.activateCashbackRenderedTitle,button:this.activateCashbackRenderedButtonText,pageType:e,popupOrigination:this.flyoutData.common.popupOrigination,url:s?.getCurrentUrl(),openedWith:this.flyoutData.common.openedWith,cashback:l?.CreateLogMetadata(),personalizedCashBack:l?.CreatePersonalizedCashbackLogMetadata()}));this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Activate cashback notification",n),this.logIfDataIsInconsistent(l,s?.getCurrentUrl(),this.flyoutData.common.isPane),this.addUserDsatEventHandler(l)}const p=l?.canRenderCashback;if(p&&this.HidePreviousCashbackFromShopping(),this.flyoutData.common.openedWith===r.Te.Auto&&(this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_REBATES||this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_REBATES_ORGANIC)){const e=this.flyoutData.common.shopping.querySelector("#seeOffersAutoShow");e&&gn.SO.queueUpdate((()=>{e.shadowRoot?.querySelector(".content")?.setAttribute("style","\n font-weight: 400;\n ")}))}(0,x.mE)(a,this.GetModuleName())}createCashbackActivateButton(e,t){const i=this.activateCashbackButtonCreator.createCashbackActivateButton(e,t,!0);return this.activateCashbackRenderedButtonText=i,i}createActivateButton(n,o){if(!this.flyoutData.common.shopping||!o)return;this.flyoutData.dataStoreModule.CouponData?.isCheckoutPageWithAutoApply&&(o.expanded=!1);const a=this.flyoutData.dataStoreModule.CashBackData;if(a){const s=(0,Y.lw)(this.utilities);this.flyoutData.common.isPane&&a.isPersonalizedCashback&&(s.style.marginLeft="auto",s.style.marginRight="auto"),this.flyoutData.common.currentDevice===r.AS.Mobile?this.activateCashbackButtonCreator.createCashbackActivateButtonWithStateUpdate(s,a,!0):this.createCashbackActivateButton(s,a);const l=this.stateManagement.getState(Ku.IY.topModuleName);if(0===n||l!==r.ModuleNames.COUPON){const e=this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_REBATES&&this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_REBATES_ORGANIC&&this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_REBATES_PDP||this.flyoutData.common.openedWith!==r.Te.Auto?"#aOfferDetails":"#cbButtonSection",t=o.querySelectorAll(e),i=o.querySelector("#divCashBackContent"),n=(0,Y.Ux)("div",{className:"btnWrapper"});n.appendChild(s),i&&this.flyoutData.common.isPane&&(i.style.padding="0 8px"),i&&t&&t.length>0&&(n.style.marginTop="10px",t.forEach((e=>{i.insertBefore(n,e)})))}else{const n=(0,Y.Ux)("DIV",{id:"divAutoApplyActions"});n.slot="actions",n.appendChild(s);const o=this.createSeeOffersButton();if(o&&n.appendChild(o),a?.isSignInSupportedDomainCashBack&&!e.R.isExperimentActive(f.H.cashBackDelayedEnrollmentEdgeFlow)){const e=this.createPrivacyMessage();n.appendChild(e),gn.SO.queueUpdate((()=>{const e=document.getElementById("divCashBackContent"),t=e.querySelector("#divPrivacyMessage");e.removeChild(t)}))}this.flyoutData.common.shopping.prepend(n);const r=new t.Z(i.xu.ModuleViewed);let l=`${bp.r.REBATES_ACTIVATE_CASHBACK}`;l+=" merged with coupons",this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,l,r),this.flyoutData.common.shopping.prepend(n)}}}async handleActivateCashbackClick(e,t,i){return await this.activateCashbackButtonCreator.handleActivateCashbackClick(e,t,i)}async handleLinkYourMSAClick(e,t){return await this.activateCashbackButtonCreator.handleLinkYourMSAClick(e,t)}createPrivacyMessage(e="lightweight"){return this.activateCashbackButtonCreator.createPrivacyMessage(e)}renderCampaignBanner(e){return jp(this.utilities,this.flyoutData,this.pageHandlerModule,this.logModule,e,!1)}logAadUser(e){const n=this.flyoutData?.dataStoreModule?.UserInfo;if(n?.isAadEmailPresent){const o={userInfo:n,cashBackData:e,isLinkYourMSAWorkflow:e?.isLinkYourMSAWorkflow,isSignInSupportedDomainCashBack:e?.isSignInSupportedDomainCashBack},r=new t.Z(i.xu.AadUserLinking);r.Metadata=JSON.stringify(o),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Cashback rendered aad user",r)}}createSeeOffersButton(t){const n=(0,Y.Ux)("div"),o=this.flyoutData.dataStoreModule.CashBackData,r=o?.userRebatesResponse?.latestCashbackApproved&&o?.userRebatesResponse?.latestOrderMerchantName,a=o?.isCashBackActivated;if(this.flyoutData.dataStoreModule.CashBackData?.isPersonalizedCashback&&this.flyoutData.dataStoreModule.CashBackData?.IsRebatesUser())return null;const s=(0,Y.Ux)("span",{id:"seeOffersWrapper"}),l=(0,Y.Ux)("div",{id:"aOfferDetails",className:"action"}),c=(0,Y.Ux)("fluent-anchor",{id:"aOfferDetailsText"});c.appearance="lightweight",c.href="#",c.textContent=this.flyoutData.common.isPane?this.flyoutData.dataStoreModule.CashBackData?.isPersonalizedCashback?this.flyoutData.strings.commonLearnMore:this.flyoutData.strings.cbLearnMore:this.flyoutData.strings.cbLearnMoreFlyout;const d=this.flyoutData.common.isPane?i.$S.RebatesLearnMore:i.$S.RebatesLearnMoreFlyout;c.style.alignSelf="center",c.addEventListener("click",(()=>{const e=new W.Z(d,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.pageHandlerModule.RecordAsUserAction(K.bS.REBATES_LEARN_MORE),this.pageHandlerModule.RecordAsUserEngagement(q.FV.REBATES_LEARN_MORE,this.flyoutData.common.popupOrigination),this.logModule.LogInfoEvent(i.R.ButtonClick,"User navigated to rebates learn more",e,Jl.g.CouponImpressionId),this.flyoutData.dataStoreModule.CashBackData?.isPersonalizedCashback?this.pageHandlerModule.NavigateToBingRebates():this.flyoutData.common.isPane?this.pageHandlerModule.NavigateToLearnMore(ju.$.NEW_FOREGROUND_TAB,this.flyoutData.dataStoreModule.CashBackData?.merchantName,this.flyoutData.common.domain):((0,h.Xo)(Jp.Q.CashBackOfferDetailsVisible,"true"),this.pageHandlerModule.OpenPane(this.flyoutData.common.popupOrigination))})),t&&t(c);const u=e.R.isExperimentActive(f.H.blossomCampaign);if(this.flyoutData.common.isPane){if(!u||u&&!this.shouldShowBlossomPostPurchase){const e=(0,Y.Ux)("div",{id:"cashBackInfoText"}),t=(0,Y.Ux)("P");t.className="txtSmall",t.textContent=this.flyoutData.strings.cbReceiveCashBackTitle,e.append(t),l.append(this.createYellowLight()),l.append(e),l.style.marginTop="12px"}}else l.style.marginTop="12px",l.append(c);if(a&&r){const e=this.cashbackComponents.createRebatesHistoryLinkSection();n.appendChild(e)}return s.appendChild(n),this.stateManagement.addEventListener(Ku.e1.onCashBackActivated,(()=>{if(null===n.firstChild&&r){const e=this.cashbackComponents.createRebatesHistoryLinkSection();n.appendChild(e)}if(!document.getElementById("seeOffersWrapper")){const e=l.parentElement;e?.removeChild(l),s.prepend(l),e?.appendChild(s)}})),a?(s.prepend(l),s):l}isPersonalizedCashbackListUX(){const e=this.flyoutData.dataStoreModule.CashBackData;if(!e)return!1;const t=e.personalizedCashback?.adsCashback?.length>0&&("LdClickData"===e.personalizedCashback?.adsCashback[0]?.scope||"LdClickDataStorewide"===e.personalizedCashback?.adsCashback[0]?.scope);return e?.isPersonalizedCashback&&!t&&this.flyoutData.common.isPane}renderErrorState(e,t){if(!this.flyoutData.common.shopping.querySelector("#divErrorCashbackActivation")){const i=(0,Y.Ux)("DIV",{style:"display: flex; flex-direction: row;"});i.id="divErrorCashbackActivation";const n=(0,Y.Ux)("DIV",{style:"align-self: center;"});n.innerHTML=this.assets.getErrorIcon(),n.setAttribute("aria-label","hidden");const o=(0,Y.Ux)("P");o.className="txtMedium",o.textContent=this.flyoutData.strings.cbErrorMessage,o.setAttribute("role","alert"),this.flyoutData.dataStoreModule.CashBackData?.shouldRenderCashBackNotification&&(o.style.fontSize="12px"),i.appendChild(n),i.appendChild(o),"actions"===t?(i.slot="header-content",this.flyoutData.common.shopping.prepend(i)):e&&e.parentElement&&e.parentElement.prepend(i)}}async updateFlyoutSuccessStatus(){const t=document.getElementById("rebatesButton");this.flyoutData.common.isCheckoutPage&&this.cashbackStyles.styleProcessingState(t),t?.setAttribute("aria-live","off"),this.flyoutData.dataStoreModule.CashBackData&&(this.flyoutData.dataStoreModule.CashBackData.isCashBackActivated=!0);const n=new CustomEvent(Ku.e1.onCashBackActivated),o=new CustomEvent(Ku.e1.onCashBackActivatedForRewards);if(this.stateManagement.dispatchEvent(n),this.stateManagement.dispatchEvent(o),e.R.isVariantActive(f.H.rewardFlyout,Yu.Az.Rewards_0)&&!0===this.flyoutData?.dataStoreModule?.RewardData?.IsControlUser){const e=new Xp(0,0,this.flyoutData.common.domain,0);this.logModule.LogInfoEvent(i.R.RewardsActivity,"rewards points info for control flight",e,Jl.g.CouponImpressionId)}this.cashbackStyles.styleActivatedState(t)}async updateFlyoutFailStatus(){const e=document.getElementById("rebatesButton"),t=new CustomEvent(Ku.e1.onCashbackActivationError,{detail:{cashbackButton:e,slot:e?.parentElement?.slot}});this.stateManagement.dispatchEvent(t),this.cashbackStyles.styleDefaultState(e,this.flyoutData.strings.cbBingActivateButton)}renderCurrentButtonState(e){return this.activateCashbackButtonCreator.renderCurrentButtonState(e)}createExclusiveBadge(e){const t=(0,Y.Ux)("div",{id:"divBadge"}),i=(0,Y.Ux)("div",{id:"divBadgeContainer"}),n=(0,Y.Ux)("p",{id:"txtBadge"});return n.innerText=e,n.setAttribute("aria-label",e),i.appendChild(n),t.appendChild(i),t}createYellowLight(){const e=(0,Y.Ux)("DIV");return e.setAttribute("aria-hidden","true"),e.style.display="inline-block",e.style.verticalAlign="vertical-align: -webkit-baseline-middle",e.innerHTML=this.commonAssets.getYellowLightIcon(),e}campaignCashbackPromo(e){const t=this.flyoutData.dataStoreModule.CampaignData?.retailerData?.oldCashBack;if(e&&t?.commisionValue&&parseFloat(e)>parseFloat(t.commisionValue)){const e="%"===t.commisionType?`${t.commisionValue}${t.commisionType}`:`${t.commisionType}${parseFloat(t.commisionValue).toFixed(2)}`,i=document.createElement("SPAN");return i.style.textDecoration="line-through",i.textContent=e,i.style.float="left",i.style.marginRight="5px",i}}getOldCashback(e){if(e){const t=document.createElement("SPAN");return t.style.textDecoration="line-through",t.textContent=e,t.style.float="left",t.style.marginRight="5px",t}}createCashBackTitle(t,n,o,r){const a=(0,Y.Ux)("div",{id:"divCashBackTitle"});this.utilities.shouldRenderSmallNotification()&&(a.style.width="100%");const s=(0,T.uf)(this.flyoutData.dataStoreModule.ApiData?.market,this.flyoutData.dataStoreModule.ApiData?.retailerData?.exclusiveMarket),l=(0,ne.N6)(s);if(e.R.isExperimentActive(f.H.cashBackDelayedEnrollmentEdgeFlow)&&!this.flyoutData.common.isPane&&(!this.flyoutData.dataStoreModule.UserInfo.isMSASignedIn||!this.flyoutData.dataStoreModule.UserInfo.isRebatesUser)){const e=this.cashbackComponents.createCashBackActivatedMessageWrapper(!1);e.style.marginBottom="8px",a.appendChild(e)}const c=(0,Y.Ux)("h2",{id:this.estimatedCashbackData?.isPdp&&this.utilities.shouldRenderSmallNotification()?"h2PdpEstimateTitle":"h2RebatesTitle"});c.classList.add("h2RebatesTitlev2");const d=this.utilities.shouldRenderSmallNotification()?this.estimatedCashbackData?.isPdp?zu.h.Large:zu.h.Medium:void 0,{newIncentiveCashback:u,oldCashback:p}=this.cashbackUtilities.getIncentiveCashbackValues(),g=this.utilities.createCommissionArrow(u??this.estimatedCashbackData?.cashbackValue,!!this.estimatedCashbackData,d,void 0,l,this.utilities.shouldRenderSmallNotification()&&this.estimatedCashbackData?.isPdp);if(g.addEventListener("click",(e=>{if(!this.flyoutData.common.isPane){const e=new W.Z(i.$S.CashbackNotificationCommision,this.telemetryUtilities.setContentViewed(this.GetModuleName())),t="User clicked commision tag on cashback notification";this.logModule.LogInfoEvent(i.R.ButtonClick,t,e,Jl.g.CouponImpressionId),this.pageHandlerModule.RecordAsUserEngagement(q.FV.CASHBACK_MODULE_FLYOUT_TAG_CLICK,this.flyoutData.common.popupOrigination),(0,h.Xo)(Jp.Q.CashBackOfferDetailsVisible,"true"),this.pageHandlerModule.OpenPane(this.flyoutData.common.popupOrigination)}})),this.flyoutData.dataStoreModule.CampaignData?.expData.isCampaignActive()&&!this.estimatedCashbackData?.cashbackValue){const e=this.utilities.retrieveCashBackAmount(),t=e.cashBackAmount?.replace(e.currencySymbol||"",""),i=this.campaignCashbackPromo(t);i&&g.prepend(i)}if(u&&p){const e=this.getOldCashback(p);if(e){const t=this.flyoutData.strings.cbIncentiveExclusiveBadgeText,i=this.createExclusiveBadge(t);r.appendChild(i),g.prepend(e)}}this.CreateCashBackHeaderText(c,n,t,g),a.appendChild(c);const m=this.cashbackComponents.createMerchantInfoSection(!!this.estimatedCashbackData?.isPdp);a.appendChild(m);const v=(0,Y.Ux)("span");e.R.isExperimentActive(f.H.blossomCampaign)&&a.appendChild(v);const y=o.userRebatesResponse?.latestCashbackApproved&&o.userRebatesResponse?.latestOrderMerchantName;if(t&&this.utilities.shouldRenderSmallNotification()&&y){const e=(0,Y.Ux)("p",{className:"txtSmall",id:"txtSubtitleCb"}),t=(0,Y.Ux)("span",{style:"color: var(--text-green-savings-color);"});t.textContent=`$${this.utilities.formatPrice(o.userRebatesResponse.latestCashbackApproved)}`;const i=(0,Y.Ux)("span");i.textContent=o.userRebatesResponse.latestOrderMerchantName,(0,T.B7)(e,this.flyoutData.strings.cbSubtitle,t,i),a.appendChild(e)}return this.stateManagement.addEventListener(Ku.e1.onCashBackActivated,(()=>{if(this.isCashBackOfferDetailsVisible=!1,this.CreateCashBackHeaderText(c,n,!0,g),!this.flyoutData.common.isPane&&y&&null===v.firstChild){const e=this.cashbackComponents.createRebatesHistoryLinkSection();e.style.marginTop="0px",v.appendChild(e)}})),a}CreateCashBackHeaderText(e,t,i,n){let o=this.flyoutData.strings.cbMainTitleOff,r=!1;this.flyoutData.dataStoreModule.CashBackData?.isSignInSupportedDomainCashBack&&i?(o=this.flyoutData.strings.cbTitleSignInOn,r=!0):i&&(o=t?this.flyoutData.strings.cbMainTitleOnStoreWide:this.flyoutData.strings.cbMainTitleOn,this.utilities.shouldRenderSmallNotification()||(e.style.marginLeft="10px",e.style.marginRight="10px")),this.estimatedCashbackData&&(o=this.estimatedCashbackData.isPdp?this.flyoutData.strings.cbMainTitleOffWithPdpCashbackEstimate:this.flyoutData.strings.cbMainTitleOffWithCashbackEstimate),this.activateCashbackRenderedTitle=o,this.PopulateCreateCashBackHeaderHtml(e,o,n,r)}createTooltipSpanWrapper(e){const t=(0,Y.Ux)("SPAN");t.className="wrappedTextLong",e&&t.appendChild(e);const i=this.tooltipUtilities.createCashbackTooltip(this.pageHandlerModule,this.logModule);return this.flyoutData.common.isPane||t.appendChild(i),t}PopulateCreateCashBackHeaderHtml(e,t,i,n){this.flyoutData.strings.cbMainTitleOffWithPdpCashbackEstimate===t||this.flyoutData.strings.cbMainTitleOffWithCashbackEstimate===t?(0,T.B7)(e,t,this.createTooltipSpanWrapper(e.lastChild),i):((0,T.B7)(e,t,i),n||e.appendChild(this.createTooltipSpanWrapper(e.lastChild))),this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_REBATES_ORGANIC&&this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_REBATES_ORGANIC_NEW&&this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_REBATES_CHECKOUT&&this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_REBATES||(e.style.fontSize="21px",e.style.lineHeight="32px",e.style.fontWeight="600",this.utilities.shouldRenderSmallNotification()&&(e.style.fontSize="20px",e.style.lineHeight="28px"))}HidePreviousCashbackFromShopping(){this.stateManagement.getState(Ku.IY.topModuleName)===r.ModuleNames.CASHBACK&&gn.SO.queueUpdate((()=>{const e=document.querySelector("#previousCashBackSection");if(e){const t=e.shadowRoot;if(t){const e=t.querySelector("fluent-accordion");e&&(e.style.marginBottom="0px")}}}))}SetSectionTitle(e){const t=this.flyoutData.dataStoreModule.CashBackData;t&&gn.SO.queueUpdate((()=>{const i=e.shadowRoot?.querySelector("span[part=title]"),n=t.isCashBackActivated;if(i)if(n){const e=this.flyoutData.strings.cbRebatesOn,n=(0,Y.Ux)("B");n.textContent=e;const o=t.isPersonalizedCashback?this.flyoutData.strings.cbSectionTitle:this.flyoutData.strings.cbCashBackOnOff;(0,T.B7)(i,o,n)}else if(t.isPersonalizedCashback){const e=this.flyoutData.strings.cbRebatesOn,t=(0,Y.Ux)("B");t.textContent=e;const n=this.flyoutData.strings.cbSectionTitle;(0,T.B7)(i,n,t)}else{const e=this.flyoutData.strings.cbRebatesOff,t=(0,Y.Ux)("B");t.textContent=e;const n=this.flyoutData.strings.cbCashBackOnOff;(0,T.B7)(i,n,t)}}))}createClickData(e,t){return this.cashbackTelemetry.createClickData(e,this.GetModuleName(),t,this.estimatedCashbackData)}addUserDsatEventHandler(e){const t=document.querySelector("#footerDiv #notshow"),n=this.createTelemetryMetaDataForDsat(e);t&&t.addEventListener("click",(e=>{const t=new W.Z(i.$S.CashbackDoNotShowButton,this.telemetryUtilities.setContentViewed(this.GetModuleName()));t.Metadata=JSON.stringify(n),this.logModule.LogInfoEvent(i.R.ButtonClick,"Do not show button clicked on cashback notification",t)}))}createTelemetryMetaDataForDsat(e){return{popupOrigination:this.flyoutData.common.popupOrigination,url:this.flyoutData.common.lastCommittedURL,openedWith:this.flyoutData.common.openedWith,cashback:e?.CreateLogMetadata()}}logIfDataIsInconsistent(e,n,o){const r=e?.CreateLogMetadata()??{},a=JSON.parse(this.cashbackMetadata);if((a.isRebatesUser!==r.isRebatesUser||a.isBingRebatesUser!==r.isBingRebatesUser||a.isEdgeRebatesUser!==r.isEdgeRebatesUser||a.isBingRebatesUserFromApiResponse!==r.isBingRebatesUserFromApiResponse)&&!o){const o=new t.Z(i.xu.ActivateCashBackNotificationInconsistentData,void 0,void 0,this.flyoutData.common.domain,JSON.stringify({title:this.activateCashbackRenderedTitle,button:this.activateCashbackRenderedButtonText,popupOrigination:this.flyoutData.common.popupOrigination,url:n,openedWith:this.flyoutData.common.openedWith,cashback:e?.CreateLogMetadata()}));this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Activate cashback notification rebates user check has inconsistent data",o)}}},Ag=class extends Pg{constructor(e,t,i,n){super(e,t,i,n),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"refreshCount",0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"footerUtilities",void 0),(0,s.Z)(this,"tooltipUtilities",void 0),(0,s.Z)(this,"telemetryHandler",void 0),(0,s.Z)(this,"todayString",void 0),(0,s.Z)(this,"lowString",void 0),(0,s.Z)(this,"highString",void 0),(0,s.Z)(this,"wasPriceHistorySectionExpanded",void 0),this.logModule=i.logModule,this.stateManagement=e,this.pageHandlerModule=i.pageHandlerModule,this.flyoutData=t,this.utilities=i.viewModulesUtilities,this.storageHandler=i.storageHandler,this.footerUtilities=i.footerUtilities,this.tooltipUtilities=i.tooltipUtilities,this.telemetryHandler=i.telemetryHandler}GetModuleName(){return r.ModuleNames.CAMPAIGN_PDP_CASHBACK}ShouldRenderModule(){const e=this.flyoutData.dataStoreModule.CampaignData?.product;if(e&&this.flyoutData.dataStoreModule.CampaignData?.expData.isCampaignActive()&&e){const t=!!e?.cashback?.commisionValue||!!e?.coupon?.discountValue;return Promise.resolve(t)}return Promise.resolve(!1)}async renderModule(){const e=this.flyoutData.dataStoreModule.CampaignData?.product;if(!e)return null;const t=document.createElement("div");t.id="campaign-pdp-cashback-module",t.className="campaign-module",t.style.textAlign="left",t.style.margin="auto",t.style.width="90%";const i=document.createElement("div");i.style.display="flex",i.style.flexDirection="column";const n=!!e?.coupon?.discountValue,o=!!e?.cashback?.commisionType,a=this.getProductInfo(e,this.discountText(n,o));i.appendChild(a),i.appendChild(this.getCountDownCounter());const s=o?this.createActivateButton():void 0;s&&i.appendChild(s),t.appendChild(i);const l=new Fp;this.utilities.applyStyles(t,l.getStyles(),void 0,l.getDarkModeStyles());const c=this.CreateModule(t,r.H7.CAMPAIGN_PDP_CASHBACK,r.ModuleNames.CAMPAIGN_PDP_CASHBACK,r.$k.CONTEXTUAL,r.SV.BLOCK);return Promise.resolve(c)}PostProcessing(e,t,i){}getProductInfo(e,t){const i=document.createElement("div");i.style.display="flex",i.style.margin="8px 0px",i.style.flexDirection="row",i.style.justifyContent="space-between",i.style.gap="8px";const n=document.createElement("DIV"),o=document.createElement("div");o.className="campaign-pdp-cashback-title",o.style.fontSize="20px",o.style.lineHeight="27px",o.style.fontWeight="600",o.textContent=this.flyoutData.strings.dealDays,n.appendChild(o);const r=document.createElement("div");r.style.marginTop="5px",r.style.display="flex",r.style.flexDirection="row",r.style.gap="4px",r.style.alignItems="baseline";const a=document.createElement("span");a.className="campaign-pdp-cashback-new-price",a.style.fontSize="16px",a.style.lineHeight="22px",a.style.fontWeight="600",a.textContent=this.getNewPrice(e);const s=document.createElement("span");s.className="campaign-pdp-cashback-old-price",s.style.fontSize="12px",s.style.marginLeft="4px",s.style.lineHeight="14px",s.style.textDecorationLine="line-through",e?.originalPrice&&(s.textContent=e.originalPrice),r.appendChild(a),r.appendChild(s),n.append(r);const l=document.createElement("div");l.className="campaign-pdp-cashback-discount-info",l.textContent=t,l.style.fontSize="12px",l.style.lineHeight="16px",l.style.maxWidth="120px",n.appendChild(l),i.appendChild(n);const c=document.createElement("DIV"),d=document.createElement("IMG");e?.imageUrl&&(d.src=e?.imageUrl),d.style.height="88px",d.style.width="107px",d.style.borderRadius="8px";const u=document.createElement("DIV");return u.appendChild(d),c.appendChild(u),i.appendChild(c),i}getNewPrice(e){const t=e.discountPrice||e.originalPrice;if(!t)return"";let i=(0,ne.K)(t);return e?.coupon?.discountValue&&e.coupon?.discountType&&("$"===e.coupon.discountType?i-=(0,ne.K)(e.coupon.discountValue):"%"===e.coupon.discountType&&(i*=1-parseFloat(e.coupon.discountValue)/100)),e.cashback?.commisionType&&e.cashback?.commisionValue&&("$"===e.cashback.commisionType?i-=(0,ne.K)(e.cashback.commisionValue):"%"===e.cashback.commisionType&&(i*=1-parseFloat(e.cashback.commisionValue)/100)),"$"+i.toFixed(2).toString()}getCountDownCounter(){const e=document.createElement("div");e.style.textAlign="center",e.style.borderTop="1px solid rgb(237 237 237)",e.style.padding="8px",e.textContent="Ends in ",e.style.fontSize="14px",e.style.lineHeight="16px";const t=this.flyoutData.dataStoreModule.CampaignData?.expData.endTime;return t&&(e.textContent=`Ends in ${Hp(t)}`),e}createActivateButton(){const e=this.flyoutData.dataStoreModule.CashBackData;if(e){const t=document.createElement("DIV");t.style.width="100%",t.style.display="flex",t.style.flexDirection="column",t.style.alignItems="center",t.style.justifyContent="center",t.style.marginTop="8px";const i=(0,Y.lw)(this.utilities);let n;this.createCashbackActivateButton(i,e),i.id="rebatesButton";let o=this.flyoutData.strings.cbActivateButtonRefresh;return this.flyoutData.dataStoreModule.UserInfo.isMSASignedIn&&this.flyoutData.dataStoreModule.UserInfo.isRebatesUser||(o="Join and Activate",n=this.createPrivacyMessage("hypertext"),n.style.marginTop="5px",n.style.marginLeft="10px",n.style.marginRight="10px",n.style.textAlign="justify"),this.cashbackStyles.styleDefaultState(i,o),e.isCashBackActivated&&this.cashbackStyles.styleActivatedState(i),t.appendChild(i),n&&t.appendChild(n),t}return null}populateMainHeader(){const e=this.flyoutData.common.shopping?.querySelector("#campaign-pdp-cashback-module");e&&(this.flyoutData.common.isPane||(e.style.marginTop="10px"),e.slot="header-content")}GetAssets(){return null}discountText(e,t){return t&&e?this.flyoutData.strings.dealDaysMultiDiscount:t?this.flyoutData.strings.dealDaysCashbackDiscount:e?this.flyoutData.strings.dealDaysCouponDiscount:""}},Eg=class extends Qu{constructor(e,t,i,n){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"cashBackData",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"uxUtilities",void 0),(0,s.Z)(this,"viewModuleUtilities",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"footerUtilities",void 0),(0,s.Z)(this,"tooltipUtilities",void 0),(0,s.Z)(this,"cashbackUtilities",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"activateCashbackButtonCreator",void 0),(0,s.Z)(this,"cashbackComponents",void 0),(0,s.Z)(this,"cashbackStyles",void 0),(0,s.Z)(this,"stylesAdded",!1),(0,s.Z)(this,"isCashBackOfferDetailsVisible",!1),(0,s.Z)(this,"estimatedCashbackData",void 0),this.uxUtilities=i,this.logModule=i.logModule,this.pageHandlerModule=i.pageHandlerModule,this.stateManagement=e,this.flyoutData=t,this.viewModuleUtilities=i.viewModulesUtilities,this.storageHandler=i.storageHandler,this.footerUtilities=i.footerUtilities,this.tooltipUtilities=i.tooltipUtilities,this.cashbackUtilities=new Tg(t,i.pageHandlerModule,i.logModule,i.viewModulesUtilities,this.GetModuleName(),i.telemetryHandler,i.storageHandler),this.assets=null,this.commonAssets=n,this.telemetryUtilities=i.telemetryHandler,this.cashbackComponents=new og(this.stateManagement,this.flyoutData,this.pageHandlerModule,this.logModule,this.viewModuleUtilities,this.tooltipUtilities,this.telemetryUtilities,this.commonAssets),this.cashbackStyles=new ig(this.flyoutData,this.commonAssets),this.activateCashbackButtonCreator=new ag(this.stateManagement,this.flyoutData,this.uxUtilities,this.commonAssets,this.logModule,this.GetModuleName(),void 0)}GetModuleName(){return r.ModuleNames.CASHBACK_ACTIVATE}async ShouldRenderModule(){const t=this.flyoutData.dataStoreModule.CashBackData;if(!t||!t.highestCashBackCategory||!t.highestCashBackCategory.commissionType&&!t.highestCashBackCategory.commissionValue)return Promise.resolve(!1);if(this.cashBackData=t,e.R.getServiceExperimentValue(f.H.cbSplitModules)!==Yu.l1.CashBackActivateModule)return Promise.resolve(!1);const i=new wg(this.flyoutData,this.stateManagement,this.storageHandler,this.logModule,this.pageHandlerModule,this.viewModuleUtilities,this.telemetryUtilities,this.GetModuleName()),n=await i.canRenderDelayedEnrollmentModule();return e.R.isExperimentActive(f.H.cashBackDelayedEnrollmentEdgeFlow)&&n?Promise.resolve(!1):(this.estimatedCashbackData=await i.getEstimatedCashbackData(),await i.canRenderActivateModule())}async renderModule(){const e=this.cashBackData.isCashBackActivated,t=this.cashBackData?.userRebatesResponse?.latestCashbackApproved&&this.cashBackData?.userRebatesResponse?.latestOrderMerchantName;this.activateCashbackButtonCreator.setEstimatedCashbackData(this.estimatedCashbackData),this.stylesAdded||(this.activateCashbackButtonCreator.addCashbackStyles(),this.stylesAdded=!0),"true"===(0,h.Mw)(Jp.Q.CashBackOfferDetailsVisible)&&(this.isCashBackOfferDetailsVisible=!0,(0,h.Xo)(Jp.Q.CashBackOfferDetailsVisible,"false"));const i=this.cashbackComponents.createCashbackSection(),n=this.cashbackComponents.createCashbackWrapper(),o=this.cashbackComponents.createCashbackContent(),a=this.cashbackUtilities.is3xIncentiveOfferValid();if(a){await this.cashbackUtilities.createCashback3xIncentiveOfferBody(this.cashBackData,o,this.cashbackComponents);const e=this.cashbackComponents.createCashbackActivateButton(this.GetModuleName(),this.cashBackData);e.style.marginBottom="10px",o.appendChild(e)}else{await this.storageHandler.getStorageString(Ce.Q.ShoppingTripsActivateRebateDomain)===this.cashBackData.merchantName&&(this.storageHandler.clearStorage(Ce.Q.ShoppingTripsActivateRebateDomain),e||await this.pageHandlerModule.ActivateRebates(!1));let n=this.viewModuleUtilities.retrieveCashBackAmount().cashBackAmount;const{newIncentiveCashback:r,oldCashback:a}=this.cashbackUtilities.getIncentiveCashbackValues();r&&a&&(n=r);const s=this.cashbackComponents.createCashbackTitle(a,n,this.estimatedCashbackData);o.appendChild(s);const l=this.cashbackComponents.createMerchantInfoSection(!!this.estimatedCashbackData?.isPdp);o.appendChild(l);const c=this.flyoutData.dataStoreModule.CampaignData?.retailerData?.specialCashBackOffer;if(c?.cashBackAmount&&c?.cashBackCondition&&o.appendChild(zp(c.cashBackAmount,c.cashBackCondition)),this.cashbackUtilities.shouldRenderFREAnimation(f.H.cbAnimationVar4,this.cashBackData?.isPersonalizedCashback)){const e=this.cashbackComponents.createAnimationDownVariation();o.appendChild(e)}if(await this.cashbackUtilities.checkIsEligibleForBlossomCampaign()&&this.flyoutData.common.isPane){const e=this.cashbackComponents.createBlossomInfoSection(!1);e.style.width="calc(100% - 32px)",o.appendChild(e)}const d=this.cashbackComponents.createCashbackActivateButton(this.GetModuleName(),this.cashBackData);this.stateManagement.addEventListener(Ku.e1.onCashBackActivated,(()=>{if(!0===i.accordion){const e=i.shadowRoot?.querySelector("span[part=title]");if(e){const t=this.flyoutData.strings.cbRebatesOn,i=(0,Y.Ux)("B");i.textContent=t;const n=this.flyoutData.strings.cbCashBackOnOff;(0,T.B7)(e,n,i)}}if(!document.getElementById("rebatesHistoryLinkSection")&&t){const e=this.cashbackComponents.createRebatesHistoryLinkSection();e.style.marginTop="0px",e.style.marginBottom="12px",o.appendChild(e)}})),o.appendChild(d);const u=this.cashbackComponents.createRecieveCashbackText();if(o.appendChild(u),this.stateManagement.addEventListener(Ku.e1.onCashbackActivationError,(e=>{this.cashbackStyles.renderErrorState(e.detail.cashbackButton,e.detail.slot)})),this.cashbackUtilities.shouldRenderFREAnimation(f.H.cbAnimationVar1,this.cashBackData?.isPersonalizedCashback)){const t=this.cashbackComponents.createAnimationArrowVariation(e);o.appendChild(t),this.cashbackComponents.createActivatedArrowAnimation()}}if(e&&t&&!document.getElementById("rebatesHistoryLinkSection")){const e=this.cashbackComponents.createRebatesHistoryLinkSection();o.appendChild(e)}if(n.appendChild(o),i.appendChild(n),(e||a)&&(this.isCashBackOfferDetailsVisible=!1),this.cashBackData.categories.length>0){const e=this.cashbackComponents.createCashbackCategoriesWrapper();e.style.display=this.isCashBackOfferDetailsVisible?"flex":"none";const t=this.cashbackComponents.createCashBackCategoriesContent();this.cashbackComponents.populateCashbackCategoriesList(t,this.cashBackData.categories,this.cashBackData.exclusions),e.appendChild(t),i.appendChild(e);const o=this.cashbackComponents.CreateSeeMoreButton(this.GetModuleName(),this.isCashBackOfferDetailsVisible,e);i.classList.add("noInlinePadding"),i.appendChild(o),this.viewModuleUtilities.applyStyles(this.flyoutData.common.shopping,".headerBlock::part(header) {\n background-color: unset!important;\n }"),this.viewModuleUtilities.isDarkMode()||(n.style.backgroundColor="var(--fill-color)"),n.style.borderRadius="8px"}const s=r.SV.BLOCK,l=this.CreateModule(i,r.H7.CASHBACK,r.ModuleNames.CASHBACK_ACTIVATE,r.$k.CONTEXTUAL,s);return Promise.resolve(l)}populateMainHeader(){if(!this.flyoutData.common.shopping)return;const e=this.flyoutData.common.shopping.querySelector("#cashBackSection");e&&(e.slot="header-content",e.parentElement?.classList.add("no-padding-header"))}PostProcessing(e,t,n){0!==t&&gn.SO.queueUpdate((()=>{const e=n.shadowRoot?.querySelector("span[part=title]");e&&this.cashbackComponents.setCashbackSectionTitle(e,this.cashBackData)}));const o=new qp(this.cashBackData.highestCashBackCategory.category,this.cashBackData.highestCashBackCategory.commissionType,this.cashBackData.highestCashBackCategory.commissionValue.toString(),this.flyoutData.common.domain,this.cashBackData.affiliateNetwork,this.cashBackData.isEdgeProfile?i.E_.Edge:i.E_.Bing,this.cashBackData.IsRebatesUser(),this.cashBackData.IsRebatesSupportedDomain?.toString()??"",this.cashBackData.isSignInSupportedDomain,this.cashBackData.merchantFullName,"cashback section",!!this.estimatedCashbackData,(0,fg.U)(this.flyoutData.dataStoreModule.ApiData?.retailerData,this.flyoutData.common.lastCommittedURL,this.flyoutData.common.extractedEntity));this.logModule.LogInfoEvent(i.R.CashbackInfo,"",o,Jl.g.CouponImpressionId),this.stateManagement.getState(Ku.IY.topModuleName)===r.ModuleNames.CASHBACK&&gn.SO.queueUpdate((()=>{const e=document.querySelector("#previousCashBackSection");if(e){const t=e.shadowRoot;if(t){const e=t.querySelector("fluent-accordion");e&&(e.style.marginBottom="0px")}}})),(0,x.mE)(n,this.GetModuleName())}},kg=class extends Qu{constructor(e,t,i,n){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"cashBackData",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"uxUtilities",void 0),(0,s.Z)(this,"viewModuleUtilities",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"footerUtilities",void 0),(0,s.Z)(this,"tooltipUtilities",void 0),(0,s.Z)(this,"cashbackUtilities",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"activateCashbackButtonCreator",void 0),(0,s.Z)(this,"cashbackComponents",void 0),(0,s.Z)(this,"cashbackStyles",void 0),(0,s.Z)(this,"stylesAdded",!1),(0,s.Z)(this,"isCashBackOfferDetailsVisible",!1),(0,s.Z)(this,"isDelayedCashbackActivated",!1),(0,s.Z)(this,"estimatedCashbackData",void 0),(0,s.Z)(this,"delayedCashbackActivatedDomains",void 0),this.uxUtilities=i,this.logModule=i.logModule,this.pageHandlerModule=i.pageHandlerModule,this.stateManagement=e,this.flyoutData=t,this.viewModuleUtilities=i.viewModulesUtilities,this.storageHandler=i.storageHandler,this.footerUtilities=i.footerUtilities,this.tooltipUtilities=i.tooltipUtilities,this.cashbackUtilities=new Tg(t,i.pageHandlerModule,i.logModule,i.viewModulesUtilities,this.GetModuleName(),i.telemetryHandler,this.storageHandler),this.assets=null,this.commonAssets=n,this.telemetryUtilities=i.telemetryHandler,this.cashbackComponents=new og(this.stateManagement,this.flyoutData,this.pageHandlerModule,this.logModule,this.viewModuleUtilities,this.tooltipUtilities,this.telemetryUtilities,this.commonAssets),this.cashbackStyles=new ig(this.flyoutData,this.commonAssets),this.activateCashbackButtonCreator=new ag(this.stateManagement,this.flyoutData,this.uxUtilities,this.commonAssets,this.logModule,this.GetModuleName(),void 0)}GetModuleName(){return r.ModuleNames.CASHBACK_DELAYED_ENROLLMENT}async ShouldRenderModule(){const t=this.flyoutData.dataStoreModule.CashBackData;if(!t?.isSignInSupportedDomainCashBack||!t.highestCashBackCategory||!t.highestCashBackCategory.commissionType&&!t.highestCashBackCategory.commissionValue)return Promise.resolve(!1);if(this.cashBackData=t,!e.R.isExperimentActive(f.H.cashBackDelayedEnrollmentEdgeFlow))return Promise.resolve(!1);const i=new wg(this.flyoutData,this.stateManagement,this.storageHandler,this.logModule,this.pageHandlerModule,this.viewModuleUtilities,this.telemetryUtilities,this.GetModuleName()),n=await i.canRenderActivateModule();return e.R.getServiceExperimentValue(f.H.cbSplitModules)===Yu.l1.CashBackActivateModule&&n?Promise.resolve(!1):(this.estimatedCashbackData=await i.getEstimatedCashbackData(),await i.canRenderDelayedEnrollmentModule())}async renderModule(){this.delayedCashbackActivatedDomains=new Map((0,h.WN)(Jp.Q.DelayedCashbackActivatedDomains)),this.isDelayedCashbackActivated=this.cashbackUtilities.isDelayedCashbckActivatedin24Hrs(this.delayedCashbackActivatedDomains),this.activateCashbackButtonCreator.setEstimatedCashbackData(this.estimatedCashbackData),this.stylesAdded||(this.activateCashbackButtonCreator.addCashbackStyles(),this.stylesAdded=!0),"true"===(0,h.Mw)(Jp.Q.CashBackOfferDetailsVisible)&&(this.isCashBackOfferDetailsVisible=!0,(0,h.Xo)(Jp.Q.CashBackOfferDetailsVisible,"false"));const e=this.cashbackComponents.createCashbackSection(),t=this.cashbackComponents.createDelayedCashbackWrapper();if(this.renderDelayedCashbackContent(t),e.appendChild(t),this.stateManagement.addEventListener(Ku.e1.onCashbackActivationError,(e=>{this.cashbackStyles.renderErrorState(e.detail.cashbackButton,e.detail.slot)})),this.stateManagement.addEventListener(Ku.e1.onDelayedCashBackActivated,(e=>{this.isDelayedCashbackActivated=!0,this.delayedCashbackActivatedDomains.set(this.flyoutData.common.domain,Date.now()),(0,h.Ev)(Jp.Q.DelayedCashbackActivatedDomains,[...this.delayedCashbackActivatedDomains]),gn.SO.queueUpdate((()=>{const e=t.querySelector("#divCashBackContent");t.removeChild(e),this.renderDelayedCashbackContent(t)}))})),this.cashBackData.isCashBackActivated&&(this.isCashBackOfferDetailsVisible=!1),this.cashBackData.categories.length>0){const i=this.cashbackComponents.createCashbackCategoriesWrapper();i.style.display=this.isCashBackOfferDetailsVisible?"flex":"none";const n=this.cashbackComponents.createCashBackCategoriesContent();this.cashbackComponents.populateCashbackCategoriesList(n,this.cashBackData.categories,this.cashBackData.exclusions),i.appendChild(n),e.appendChild(i);const o=this.cashbackComponents.CreateSeeMoreButton(this.GetModuleName(),this.isCashBackOfferDetailsVisible,i);e.classList.add("noInlinePadding"),e.appendChild(o),this.viewModuleUtilities.applyStyles(this.flyoutData.common.shopping,".headerBlock::part(header) {\n background-color: unset!important;\n }"),this.viewModuleUtilities.isDarkMode()||(t.style.backgroundColor="var(--fill-color)"),t.style.borderRadius="8px"}const i=r.SV.BLOCK,n=this.CreateModule(e,r.H7.CASHBACK,r.ModuleNames.CASHBACK_DELAYED_ENROLLMENT,r.$k.CONTEXTUAL,i);return Promise.resolve(n)}renderDelayedCashbackContent(e){const t=this.cashbackComponents.createCashbackContent(),i=this.cashbackComponents.createDelayedCashbackTitleWrapper(this.isDelayedCashbackActivated),n=this.cashbackComponents.createCashBackBottomContentWrapper(),o=this.cashbackComponents.createCashBackActivatedMessageWrapper(this.isDelayedCashbackActivated);let r=this.viewModuleUtilities.retrieveCashBackAmount().cashBackAmount;const{newIncentiveCashback:a,oldCashback:s}=this.cashbackUtilities.getIncentiveCashbackValues();a&&s&&(r=a);const l=this.cashbackComponents.createCashbackTitle(s,r,this.estimatedCashbackData,this.isDelayedCashbackActivated);i.appendChild(o),i.appendChild(l);const c=this.cashbackComponents.createMerchantInfoSection(!!this.estimatedCashbackData?.isPdp);i.appendChild(c),t.appendChild(i);const d=this.cashbackComponents.createDelayedEnrollmentCashbackButton(this.isDelayedCashbackActivated);if(n.appendChild(d),this.isDelayedCashbackActivated){const e=this.activateCashbackButtonCreator.createPrivacyMessage("lightweight");e.style.marginTop="12px",e.style.textAlign="center",n.appendChild(e)}t.appendChild(n),e.appendChild(t)}populateMainHeader(){if(!this.flyoutData.common.shopping)return;const e=this.flyoutData.common.shopping.querySelector("#cashBackSection");e&&(e.slot="header-content",e.parentElement?.classList.add("no-padding-header"))}PostProcessing(e,t,n){0!==t&&gn.SO.queueUpdate((()=>{const e=n.shadowRoot?.querySelector("span[part=title]");e&&this.cashbackComponents.setCashbackSectionTitle(e,this.cashBackData)}));const o=new qp(this.cashBackData.highestCashBackCategory.category,this.cashBackData.highestCashBackCategory.commissionType,this.cashBackData.highestCashBackCategory.commissionValue.toString(),this.flyoutData.common.domain,this.cashBackData.affiliateNetwork,this.cashBackData.isEdgeProfile?i.E_.Edge:i.E_.Bing,this.cashBackData.IsRebatesUser(),this.cashBackData.IsRebatesSupportedDomain?.toString()??"",this.cashBackData.isSignInSupportedDomain,this.cashBackData.merchantFullName,"cashback section",!!this.estimatedCashbackData,(0,fg.U)(this.flyoutData.dataStoreModule.ApiData?.retailerData,this.flyoutData.common.lastCommittedURL,this.flyoutData.common.extractedEntity));this.logModule.LogInfoEvent(i.R.CashbackInfo,"",o,Jl.g.CouponImpressionId),this.stateManagement.getState(Ku.IY.topModuleName)===r.ModuleNames.CASHBACK&&gn.SO.queueUpdate((()=>{const e=document.querySelector("#previousCashBackSection");if(e){const t=e.shadowRoot;if(t){const e=t.querySelector("fluent-accordion");e&&(e.style.marginBottom="0px")}}})),(0,x.mE)(n,this.GetModuleName())}},Ig=class extends Pg{constructor(e,t,i,n){super(e,t,i,n)}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_REBATES,u.sR.AUTO_SHOW_REBATES_CONFIRMATION,u.sR.AUTO_SHOW_REBATES_DEACTIVATED,u.sR.AUTO_SHOW_REBATES_ORGANIC,u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_CONFIRMATION,u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK,u.sR.AUTO_SHOW_REBATES_SWITCHED_TO_MSA,u.sR.AUTO_SHOW_REBATES_CHECKOUT,u.sR.AUTO_SHOW_REBATES_ORGANIC_NEW,u.sR.AUTO_SHOW_REBATES_PDP,u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_ADDRESSBAR]}GetNotificationName(){const e=this.flyoutData.dataStoreModule.CashBackData;return e?.isTurnedOff?r.sM.CASHBACKTURNEDOFF:e?.isConfirmationPage?r.sM.CASHBACKCONFIRMATION:this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_REBATES_CHECKOUT?r.sM.CASHBACK_CHECKOUT_NOTIFICATION:this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_REBATES_PDP?r.sM.CASHBACK_PDP_NOTIFICATION:r.sM.CASHBACK}async RenderNotification(){const e=this.flyoutData.dataStoreModule.CashBackData;let t=null,i="",n="";if(e&&e.shouldRenderCashBackNotification)if(e?.isTurnedOff)i="isTurnedOff",t=this.renderTurnedOffCashBackModule();else if(e?.isConfirmationPage)i="isConfirmationPage",t=await this.renderConfirmationCashBackModule();else{const o=await this.renderModuleInNotification();o&&o.element?(i="renderModuleInNotification",t=this.utilities.createNotificationModule(o.element,r.sM.CASHBACK,this),this.logAadUser(e)):n="Unable to render module"}else n="Cashback data shound not render notificaiton";this.cashbackMetadata=JSON.stringify(this.flyoutData.dataStoreModule.CashBackData?.CreateLogMetadata());const o=!t;return(0,we.Jp)(o,this.flyoutData,this.logModule,o?`Error triggering cashback notification ${n}`:"Should render cashback notification",void 0,void 0,{method:"RenderNotification",notificationKind:i,cashbackData:e?.CreateLogMetadata()}),Promise.resolve(t)}async ShouldRenderNotification(){if(e.R.isExperimentActive(f.H.cashbackConsolidationExp))return Promise.resolve(!1);const t=new wg(this.flyoutData,this.stateManagement,this.storageHandler,this.logModule,this.pageHandlerModule,this.utilities,this.telemetryUtilities,r.ModuleNames.CASHBACK);this.estimatedCashbackData=await t.getEstimatedCashbackData();const i=await t.shouldRenderNotification();if(this.flyoutData.common.openedWith===r.Te.Auto&&this.flyoutData.common.popupOrigination&&this.GetPopupOriginationList().includes(this.flyoutData.common.popupOrigination)){const e=!i,t=this.flyoutData.dataStoreModule.CashBackData;(0,we.Jp)(e,this.flyoutData,this.logModule,e?"Error triggering cashback notification":"Should render cashback notification",void 0,void 0,{method:"ShouldRenderNotification",cashbackData:t?.CreateLogMetadata()})}return i}PostProcessingNotification(t,i){const n=this.flyoutData.dataStoreModule.CashBackData;if(n?.isTurnedOff){const e=(0,Y.lw)(this.utilities);e.classList.add("lateralMargin"),e.slot="actions",this.cashbackStyles.styleDefaultState(e,this.flyoutData.strings.cbActivateButtonRefresh),e.addEventListener("click",(async t=>{await this.handleActivateCashbackClick(e,t,"Cash back activated from turned off notification")?this.cashbackStyles.styleActivatedState(e):this.cashbackStyles.styleDefaultState(e,this.flyoutData.strings.cbActivateButtonRefresh)})),this.flyoutData.common.shopping.appendChild(e)}else{if(n?.isConfirmationPage)return;{this.PostProcessing(r.ModuleNames.CASHBACK,0,i);let t=e.R.isExperimentActive(f.H.cashbackDismissTimeout)?3e3:4500;if(this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_REBATES){const e=this.pageHandlerModule;setTimeout((()=>{e.DismissPopup()}),t)}}}}renderCampaignBanner(e){return jp(this.utilities,this.flyoutData,this.pageHandlerModule,this.logModule,e,!0)}async renderModuleInNotification(){const e=await this.renderModule();return e&&e.element?(e.element.style.marginTop="0px",e.element.slot="header-content",e.element.accordion=!1,e.element.hideTitle=!0,this.flyoutData.common.shopping.classList.add("noSections"),this.utilities.applyStyles(this.flyoutData.common.shopping,"::part(header) {\n margin-top: 0px;\n margin-bottom: 0px;\n }"),e):null}async renderConfirmationCashBackModule(){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles());const e=(0,Y.Ux)("div",{id:"divCashBackPopup"});e.slot="header-content";const n=(0,Y.Ux)("DIV",{className:"lateralMargin"});n.id="divConfirmationCb";const o=this.flyoutData.dataStoreModule.CashBackData;if(o?.isPersonalizedCashback){n.className="divPcbNotificationContent";const e=(0,Y.Ux)("div",{id:"divConfHeaderPcb",className:"lateralMargin"}),t=(0,Y.Ux)("div",{id:"divConfTitlePcb"});if(t.textContent=this.flyoutData.strings.instantcbRefresh,e.appendChild(t),this.flyoutData.dataStoreModule.CashBackData?.userRebatesResponse?.isRebatesUser||this.flyoutData.dataStoreModule.CashBackData?.isCashBackActivated){const t=(0,Y.Ux)("div",{style:"display: flex; column-gap: 8px;"}),i=(0,Y.Ux)("img",{style:"width: 40px; height: 40px;"});i.src=this.flyoutData.common.resourcesEndpoint+"common/mail.png",i.setAttribute("aria-hidden","true"),t.appendChild(i);const n=(0,Y.Ux)("div",{id:"divEmailUpdatesPcb"});n.textContent=this.flyoutData.strings.instantcbConfirmationMessage,t.appendChild(n),e.appendChild(t)}if(n.appendChild(e),this.flyoutData.dataStoreModule.CashBackData?.userRebatesResponse?.isRebatesUser||this.flyoutData.dataStoreModule.CashBackData?.isCashBackActivated){const e=(0,Y.lw)(this.utilities);e.textContent=this.flyoutData.strings.trackCashback,e.style.marginTop="12px",e.addEventListener("click",(()=>{this.pageHandlerModule.NavigateToBingRebates()})),n.appendChild(e)}else{const e=(0,Y.lw)(this.utilities);e.style.marginTop="12px",e.classList.add("lateralMargin"),this.createCashbackActivateButton(e,o),n.appendChild(e);const t=this.createPrivacyMessage();t.style.marginTop="12px",n.appendChild(t)}}const a=await this.getBlossomPostPurchaseNotification();if(a)n.appendChild(a);else{const e=(0,Y.Ux)("p",{className:"txtSmall",style:"line-height: 20px; margin-top: 16px;"});if(o?.isPersonalizedCashback){const t=(0,Y.Ux)("div",{style:"position: relative; display: inherit"}),i=(0,Y.Ux)("div",{className:"infoicon"});i.innerHTML=this.assets.getConfirmationInfoIcon(),i.setAttribute("aria-label","hidden"),t.appendChild(i),e.style.color="rgba(0, 0, 0, 0.55);",e.textContent=this.flyoutData.strings.pcbConfirmationMessage,t.appendChild(e)}else{e.textContent=this.flyoutData.strings.cbConfirmationMessage;const t=this.createSeeOffersButton();n.appendChild(e),t&&n.appendChild(t)}}if(e.appendChild(n),o?.isPersonalizedCashback){const e=new t.Z(i.xu.PersonalizedCashbackConfirmationNotification);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"User saw confirmation notification",e,Jl.g.CouponImpressionId)}else{const e=new t.Z(i.xu.RebatesConfirmationNotification);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"User saw confirmation notification",e,Jl.g.CouponImpressionId)}return this.utilities.createNotificationModule(e,r.sM.CASHBACKCONFIRMATION,this)}async getBlossomPostPurchaseNotification(){if(!e.R.isExperimentActive(f.H.blossomCampaign))return null;const n=new t.Z(i.xu.RebatesConfirmationBlossomNotification),o="true"===await this.uxUtilities.storageHandler.getStorageString(Ce.Q.BlossomShouldShowNotification);return this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,`getBlossomNotificationString: Blossom string requested. Should show: ${o}.`,n),o?(await this.uxUtilities.storageHandler.clearStorage(Ce.Q.BlossomShouldShowNotification),this.createBlossomPostPurchaseNotification()):null}createBlossomPostPurchaseNotification(){const e=(0,Y.Ux)("div",{style:"margin-top: 8px;"}),t=(0,Y.Ux)("p",{style:"font-size: 20px; line-height: 28px; font-weight: 600; margin: 0px"}),i=(0,Y.Ux)("span");i.innerText="Congrats, you're getting ",t.appendChild(i);const n=(0,Y.Ux)("span",{style:"white-space: nowrap;"});n.innerText="$5 bonus cash back!",t.appendChild(n),e.appendChild(t);const o=(0,Y.Ux)("p",{style:"margin: 8px 16px 0px 16px;"}),r=(0,Y.Ux)("span");r.innerText="Cash back for eligible purchases will be confirmed in a few days via email. ",o.appendChild(r);const a=(0,Y.Ux)("a",{href:"https://www.bing.com/rebates/history",target:"_blank",rel:"noopener noreferrer",className:"blossomLink",style:"white-space: nowrap;"});return a.innerText="Track cash back",o.appendChild(a),e.appendChild(o),e}renderTurnedOffCashBackModule(){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles());const e=(0,Y.Ux)("div",{id:"divCashBackPopup",className:"lateralMargin"});e.style.flexDirection="column",e.slot="header-content";const n=(0,Y.Ux)("h2",{id:"h2TurnedOffCb"});(0,T.B7)(n,this.flyoutData.strings.cbTurnedOffTitle);const o=(0,Y.Ux)("span",{className:"txtSmall",id:"spanTurnedOffCb"});(0,T.B7)(o,this.flyoutData.strings.cbTurnedOffMessage),e.appendChild(n),e.appendChild(o);const a=new t.Z(i.xu.RebatesTurnedOffNotification);return this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"User saw rebates turned off notification",a,Jl.g.CouponImpressionId),this.utilities.createNotificationModule(e,r.sM.CASHBACK,this)}},Dg=o(28060);function _g(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Ng(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?_g(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):_g(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var Rg=class{constructor(e,t,i){(0,s.Z)(this,"gcMainRoot","gcMainRoot"),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"telemetryHandler",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"isDarkMode",!1),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"gcMainBody","gcMainBody"),(0,s.Z)(this,"gcMainContent","gcMainContent"),(0,s.Z)(this,"gcActivatedContainer","gcActivatedContainer"),(0,s.Z)(this,"gcActivateBtnId","gcActivateBtn"),(0,s.Z)(this,"textContainerId","gcTextContainerForOffer"),(0,s.Z)(this,"textAndImageContainerClassName","gcTextAndImageContainer"),(0,s.Z)(this,"showDiscountMin",0),(0,s.Z)(this,"footerUtilities",void 0),(0,s.Z)(this,"shouldDisableFooterOnPdp",!0),(0,s.Z)(this,"shouldRemoveTooltipOnNotification",!0),this.flyoutData=e,this.commonAssets=i,this.utilities=t.viewModulesUtilities,this.footerUtilities=t.footerUtilities,this.isDarkMode=this.utilities.isDarkMode(),this.telemetryHandler=t.telemetryHandler,this.pageHandlerModule=t.pageHandlerModule,this.storageHandler=t.storageHandler,this.assets=new class{getConfirmationPageAssets(){return"\n #gcMainContent {\n background-color: rgb(255, 255, 255);\n border: unset;\n border-radius: 6px;\n padding: 16px;\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n }\n .earningText {\n font-weight: 600;\n font-size: 16px;\n line-height: 20px;\n text-align: center;\n margin: 0;\n margin-bottom: 11px;\n }\n .cashbackContainer {\n display: flex;\n }\n .emailContainer {\n display: flex;\n gap: 8px;\n align-items: center;\n }\n .emailIconContainer {\n min-width: 40px;\n height: 40px;\n background: rgba(0, 0, 0, 0.03);\n border-radius: 8px;\n display: flex;\n justify-content: center;\n align-items: center;\n margin: 15px 0;\n }\n .emailText {\n font-weight: 400;\n font-size: 12px;\n line-height: 18px;\n margin: 0;\n }\n .disclaimerContainer {\n font-weight: 400;\n font-size: 10px;\n line-height: 14px;\n text-align: center;\n }\n @media (-ms-high-contrast: active) {\n .gcCouponContainer svg path {\n fill: transparent !important;\n }\n }\n "}getActivatedContainerStyles(){return"\n #gcActivatedContainer {\n width: 100%;\n }\n @media (-ms-high-contrast: active) {\n #gcActivatedContainer svg path {\n fill: #ffffff !important;\n }\n }\n "}getConfirmationPageAssetsDarkMode(){return"\n #gcMainContent {\n background-color: #424242;\n }\n .imageIcon svg path {\n fill: #ffffff;\n }\n "}getConfirmationNotificationAssets(){return"\n #gcMainRoot {\n margin-top: -15px !important;\n padding-bottom: 5px !important;\n }\n #gcMainBody {\n padding: 0 0 15px 0 !important;\n }\n #gcMainContent {\n padding-top: 0 !important;\n padding-bottom: 0 !important;\n }\n "}getPrivacyAssets(){return"\n .gcPrivacyContainer {\n display: flex;\n justify-content: end;\n margin: 0 20px 10px 20px;\n align-items: center;\n }\n .gcPrivacyText {\n margin: 0;\n font-weight: 400;\n font-size: 12px;\n line-height: 16px;\n display: flex;\n align-items: center;\n color: #666666;\n }\n .gcPrivacyTooltipBody {\n position: absolute;\n top: 2px;\n right: 15px;\n width: 200px;\n background: #FFFFFF;\n border: 1px solid rgba(0, 0, 0, 0.08);\n box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.08);\n border-radius: 8px;\n padding: 10px;\n visibility: hidden;\n z-index: 5;\n }\n .tooltipAndBody {\n position: relative !important;\n display: flex;\n justify-content: center;\n }\n .tooltipButton {\n border: unset;\n background: transparent;\n height: fit-content;\n max-width: 20px;\n min-width: 20px;\n width: 20px;\n padding: 0;\n }\n .tooltipButton img {\n height: 10px;\n width: 10px;\n }\n #gcPrivacyTooltip::part(control) {\n padding: 0;\n width: 20px;\n max-width: 20px;\n }\n .privacyDisclaimerContainer {\n font-weight: 400;\n font-size: 12px;\n line-height: 14px;\n text-align: center;\n margin: 0;\n }\n .closeButton {\n display: flex;\n width: fit-content;\n height: fit-content;\n margin-left: auto;\n padding: 5px 0;\n margin-top: -5px;\n }\n #closeButtonSvg {\n height: 12px;\n width: 12px;\n }\n "}getPrivacyAssetsDarkMode(){return"\n .gcPrivacyText {\n color: #ffffff;\n }\n .gcPrivacyTooltipBody {\n background-color: #424242\n }\n "}getErrorCardAssets(){return"\n .gcErrorIcon {\n display: flex;\n justify-content: center;\n align-items: center;\n background-color: rgba(0, 0, 0, 0.03);\n border-radius: 8px;\n height: 40px;\n width: 40px;\n min-height: 40px;\n min-width: 40px;\n }\n .gcErrorTextAndIcon {\n display: flex;\n justify-content: center;\n align-items: center;\n gap: 8px;\n }\n .gcErrorText {\n font-weight: 600;\n font-size: 16px;\n line-height: 20px;\n color: var(--text-normal);\n margin: 4px 0;\n }\n "}getErrorCardDarkModeAssets(){return"\n .gcErrorIcon svg path {\n fill: #ffffff !important;\n }\n .gcErrorIcon {\n background-color: #2B2B2B;\n }\n "}}}CreateGridCard(e,t,n=!1,o=!1){const r=this.GetPriceData(e),a=e.cashbackProducts[0],s=r.discount.amount>this.showDiscountMin,l=this.GetIsActivatedOffer(e.id),c=i.xu.GroceryOfferCardClick,d=i.xu.GroceryOfferCardHover,{rootDiv:u,wrapper:h,content:g}=Np("gcGridCardRoot","gcGridCardMainBody","gcGridCardContent",this.isDarkMode,false,!0,!0,(()=>{this.addIcTelemetry(t,c,"",e.source,l,{offerId:e.id,offerItem:a,productTitle:a.title,productId:a.productId,isFromSearchBar:n,isFromMainSearchBar:o}),this.activateCashbackHandler(e,!1,t,l,!1)}),(()=>{this.addIcTelemetry(t,d,"",e.source,l,{offerId:e.id,isFromSearchBar:n,isFromMainSearchBar:o})}));u.style.padding="0",u.style.height="100%",h.style.padding="0",h.style.height="100%",g.style.padding="8px",g.style.height="100%",g.title=a.title;const f=(0,Y.Ux)("DIV");f.className="gcTextContainer",f.style.color=this.isDarkMode?"#ffffff":"#222222",f.style.width="100%";const m=xp(this.flyoutData,r.listPrice,r.finalPrice,0,this.isDarkMode,s,l);m.style.margin="5px 0 2px 0",m.firstChild.style.fontSize="14px",m.lastChild.style.fontSize="12px";const v=Mp(this.isDarkMode,a.title);if(f.appendChild(m),r.cashbackValue.amount>0){const t=(0,Y.Ux)("DIV",{style:"\n display: flex;\n gap: 5px;\n "}),i=Pp(`$${e.offerValue} ${this.flyoutData.strings.gcBack}`,"\n font-weight: 400;\n font-size: 12px;\n line-height: 16px;\n ",!1,20);i.className="gcCouponContainer";const n=(0,Y.Ux)("p",{style:"\n margin: 0;\n font-weight: 400;\n font-size: 12px;\n "},this.flyoutData.strings.gcAfter);t.appendChild(n),t.appendChild(i),f.appendChild(t)}f.appendChild(v);const y=void 0!==a.productRatings&&void 0!==a.productReviewsCount&&!(0,p.TF)(a.productRatings)&&!(0,p.TF)(a.productReviewsCount);if(!l&&y){const e=this.CreateUserRatingsComponent(a);e&&f.appendChild(e)}const C=this.createCashImageInWrapper(false,a.image);C.style.width="fit-content";const b=(0,Y.Ux)("DIV",{style:"\n display: flex;\n gap: 8px;\n flex-direction: column;\n justify-content: center;\n align-items: center;\n "});if(b.className=this.textAndImageContainerClassName,b.appendChild(C),b.appendChild(f),s){const e=`${r.discount.toDisplay} ${this.flyoutData.strings.gcOff}`,t=Sp(this.flyoutData,e);g.appendChild(t),u.ariaLabel=e}return g.appendChild(b),u}createElementForOfferPdp(e,t,n,o,r,a,s){n&&t===i.e4.PdpItemNotification&&this.utilities.applyStyles(this.flyoutData.common.shopping,this.commonAssets.getSmallerNotificationCssStyles(),Dg.E.ICNotification);const l=this.flyoutData.common.isPane&&!n;a||(a=this.GetIsActivatedOffer(e.id));const c=this.GetPriceData(e),d=e.cashbackProducts[0],u=n&&o?()=>{this.addIcTelemetry(t,o,"GroceryOfferCardNotification",e.source,a)}:void 0,{rootDiv:h,wrapper:p,content:g}=Np(this.gcMainRoot,this.gcMainBody,this.gcMainContent,this.isDarkMode,n,!n,void 0,void 0,u),f=this.MakeTextContainer(a,l,c.cashbackValue.toDisplay,e,n,!a&&void 0);f.style.width="fit-content";const m=this.createCashImageInWrapper(n,d.image,84);m.style.width="fit-content",m.title=d.title;const v=(0,Y.Ux)("DIV",{style:"\n display: flex;\n gap: 8px;\n justify-content: space-evenly;\n align-items: center;\n margin-bottom: 12px;\n "});v.className=this.textAndImageContainerClassName,v.appendChild(m),v.appendChild(f);const y=this.makeActivatedContainer();if(a)y.appendChild(this.MakeActivatedSign("",e,l,a,t,s)),n||this.flyoutData.common.isPane||(y.style.marginTop="-15px");else{const i=this.MakeButton(t,e,!0,c.cashbackValue.amount>0?c.cashbackValue.toDisplay:"",n,a,r),o=(0,Y.Ux)("p",{style:`\n font-weight: 400;\n font-size: ${l?"14px":"12px"};\n line-height: 20px;\n margin: 0 0 12px 0;\n text-align: center;\n color: #767676;\n `},this.flyoutData.strings.gcbNotifPdpActivation);y.appendChild(o),y.appendChild(i)}return g.appendChild(v),g.appendChild(y),n&&!a&&(f.style.marginBottom="10px",p.style.paddingBottom="0px"),h}createElementForOffer(e,t,n,o,r,a,s,l,c,d,u,h){if(o)return this.createElementForOfferPdp(e,t,n,r,d,!1,h);const g=this.flyoutData.common.isPane&&!n,f=!(n&&!o&&a)&&this.GetIsActivatedOffer(e.id),m=this.GetPriceData(e),v=e.cashbackProducts[0],y=n&&r?()=>{this.addIcTelemetry(t,r,"GroceryOfferCardNotification",e.source,f)}:void 0,{rootDiv:C,wrapper:b,content:S}=Np(this.gcMainRoot,this.gcMainBody,this.gcMainContent,this.isDarkMode,n,!n,void 0,void 0,y),x=(0,Y.Ux)("DIV",{style:`\n display: flex;\n flex-direction: column;\n color: ${this.isDarkMode?"#ffffff":"#222222"};\n width: 100%;\n `});x.className="gcTextContainer";const w=m.discount.amount>this.showDiscountMin;if(w){const e=Sp(this.flyoutData,`${m.discount.toDisplay} ${this.flyoutData.strings.gcOff}`);e.style.position="absolute",e.style.top=n?"0":"8px",e.style.left=n?"0":"8px",S.style.position="relative",S.appendChild(e)}const O=_p(s?this.flyoutData.strings.gcRelatedDeal:this.flyoutData.strings.gcTopDeal);if(x.appendChild(O),void 0!==v.productRatings&&void 0!==v.productReviewsCount&&!(0,p.TF)(v.productRatings)&&!(0,p.TF)(v.productReviewsCount)){const e=this.CreateUserRatingsComponent(v);e&&x.appendChild(e)}let P;P=!v.productShortTitle||"variation1"!==u&&"variation2"!==u?Mp(this.isDarkMode,v.title):((e,t,i=2)=>{const n=(0,Y.Ux)("p",{style:`\n margin: 0;\n color: ${e?"#ffffff":"#1A1A1A"};\n font-weight: 600;\n font-size: 13px;\n line-height: 16px;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n display: -webkit-box !important;\n -webkit-line-clamp: ${i};\n -webkit-box-orient: vertical;\n white-space: normal;\n margin-top: 2px;\n `},t);return n.title=t,n})(this.isDarkMode,v.productShortTitle);const A=xp(this.flyoutData,m.listPrice,m.finalPrice,0,this.isDarkMode,w,f,n?void 0:this.createPriceExplanationContainer(m,n),n?void 0:()=>{this.addIcTelemetry(t,i.xu.OfferDetailedPriceTooltipHover,"View detailed price breakdown",e.source,f)},g?"14px":"",g?"20px":"",600);if(g)A.style.margin="8px 0 2px 0",x.appendChild(A),x.appendChild(P);else if(l){const e="\n font-weight: 700;\n font-size: 22px;\n line-height: 43px;\n color: #008A21;\n margin: 0;\n ",t=this.CreateTextWithTooltip(m.cashbackValue.toDisplay+" "+(0,T.fm)(this.flyoutData.strings.cbFeatureName),e);x.appendChild(t),x.appendChild(P)}else A.style.margin=f?"12px 0":"12px 0 0 0",x.appendChild(P),x.appendChild(A);const E=this.createCashClickableImageInWrapper(n,v.image,t,e,o,m.cashbackValue.amount>0?m.cashbackValue.toDisplay:"",f,d);E.style.width="fit-content",E.title=v.title,E.style.flex="1";const k=(0,Y.Ux)("DIV",{style:`\n display: flex;\n gap: 8px;\n flex-direction: ${g?"row":"column"};\n justify-content: center;\n align-items: center;\n `});if(n||(k.style.marginBottom="12px"),k.className=this.textAndImageContainerClassName,k.appendChild(E),!g){const e=(0,Y.Ux)("DIV",{style:"\n width: 100%;\n border-top: 1px solid #EBEBEB;\n padding-right: 16px;\n padding-left: 16px;\n "});k.appendChild(e)}let I=!1;const D=(0,Y.Ux)("DIV",{style:"\n align-items: center;"});if(!f&&m.cashbackValue.amount>0&&!l){const e=Op(this.flyoutData,m.cashbackValue.toDisplay,this.isDarkMode);I=!0,D.appendChild(e),g?(e.style.fontSize="12px",e.style.lineHeight="16px",e.style.fontWeight="400",e.style.margin="8px 0 12px 0",e.style.justifyContent="center"):e.style.margin="0 0 8px 0"}k.appendChild(x);const _=this.makeActivatedContainer();if(f){if(m.cashbackValue.amount>0){if(g){const e=this.CreatePurchaseBeforeTimerText();e.style.marginTop="2px",e.style.marginBottom="12px",e.style.lineHeight="16px",_.appendChild(e)}_.appendChild(this.MakeActivatedSign(m.cashbackValue.toDisplay,e,g,f,t)),n||this.flyoutData.common.isPane||(_.style.marginTop="-15px")}}else{const i=this.MakeButton(t,e,o,m.cashbackValue.amount>0?m.cashbackValue.toDisplay:"",n,f,d,u),r=(0,Y.Ux)("DIV",{style:"\n width: 100%;\n padding-left: 4px;\n font-weight: bold;\n font-size: 12px;\n margin-bottom: 12px;\n height: 12px;\n "});r.innerText=this.flyoutData.strings.gcActivateInstantAddToCart,r.style.display="block",r.style.justifyContent="center";const a=(0,Y.Ux)("DIV",{style:"\n width: 100%;\n border-top: 1px solid #EBEBEB;\n padding-right: 16px;\n padding-left: 16px;\n margin-bottom: 6px;\n "});_.appendChild(a),cg.IsInstantAddToCartShowConsent(this.flyoutData,n,!1)&&(this.utilities.applyStyles(this.flyoutData.common.shopping,this.commonAssets.getGroceryNotificationFooterCss(),Dg.E.ICNotification),_.appendChild(r)),_.appendChild(i),_.style.display="block",_.style.justifyContent="center"}return S.appendChild(k),I&&S.appendChild(D),S.appendChild(_),n&&!o&&(b.style.paddingBottom="0px"),n&&!f&&(x.style.marginBottom="10px"),C}createElementQTAutoAddToCart(e,t,n,o,r){const a=r&&n?()=>{this.addIcTelemetry(t,n,"GroceryOfferCardNotification",e.source,!1)}:void 0,{rootDiv:s,content:l}=Np(this.gcMainRoot,this.gcMainBody,this.gcMainContent,this.isDarkMode,r,!r,void 0,void 0,a),c=this.GetPriceData(e),d=(0,Y.Ux)("DIV");d.className="icTextContainer";const u=(0,Y.Ux)("div");u.className="icCashbackContainer";const h=Pp(`$${c.cashbackValue.amount}`,"\n font-weight: 400;\n font-size: 16px;\n line-height: 22px;\n ",!1,22);h.className="gcCouponContainer",h.style.marginTop="6px";const p=(0,Y.Ux)("p",void 0,(0,T.fm)(this.flyoutData.strings.cbFeatureName));p.className="icCashbackText",u.appendChild(p),u.appendChild(h);const g=Mp(this.isDarkMode,e.cashbackProducts[0].title,1);g.className="icDescriptionTextGridCard";const f=this.CreateUserRatingsComponent(e.cashbackProducts[0]);d.appendChild(u),d.appendChild(g),f&&d.appendChild(f);const m=this.createCashImageInWrapperForAutoActivate(!0,e.cashbackProducts[0].image);m.title=e.cashbackProducts[0].title,m.style.position="relative",m.style.flex="1";const v=(0,Y.Ux)("DIV",{style:"position: absolute;\n bottom: 8px;\n left: 4px;\n display: flex;\n justify-content: center;\n align-items: center;\n background: rgba(255, 255, 255, 0.8);\n backdrop-filter: blur(10px);\n border-radius: 4px;\n padding: 4px;\n color: #000000"}),y=(0,Y.Ux)("SPAN");y.textContent=`${c.listPrice.toDisplay}`,v.appendChild(y),m.appendChild(v);const C=(0,Y.Ux)("DIV");C.className="icTextAndImageContainer",C.style.marginBottom="2px",C.style.cursor="pointer",C.addEventListener("click",(t=>{t.preventDefault(),this.activateCashbackHandler(e,!1,i.e4.SearchPage,!1,!0)})),C.appendChild(d),C.appendChild(m),l.appendChild(C);const b=cg.IsSpbInstantATCExpEnabled(this.flyoutData)?this.flyoutData.strings.itemizedCashBackSpbAutoATC:this.flyoutData.strings.itemizedCashBackSpbAutoActivate,S=(0,Y.Ux)("div");S.className="icMessageContainer";const x=(0,Y.Ux)("p",void 0,b);x.className="icMessageText",x.style.fontSize="12px",x.style.textAlign="center",x.style.fontWeight="bold",S.appendChild(x),l.appendChild(S);const w=this.MakeButton(t,e,!1,c.cashbackValue.amount>0?c.cashbackValue.toDisplay:"",r,!1,o,`${this.flyoutData.strings.gcOkButtonText}`);return w.style.borderTopStyle="none",l.appendChild(w),s}CreateUserRatingsComponent(e){const t=this.flyoutData.dataStoreModule?.GroceryCashbackData?.Cashback?.Variations?.get("userRatings");if(void 0===t)return;const i=(0,Y.Ux)("div",{});i.className="ratingImageWrapper",i.style.display="inline-flex",i.style.margin="7px 0 0 0",i.style.alignItems="center";const n="variation2"===t?`${this.flyoutData.common.resourcesEndpoint}groceriesCashback/userRatings/star-yellow2.png`:this.isDarkMode?`${this.flyoutData.common.resourcesEndpoint}groceriesCashback/userRatings/star-white2.png`:`${this.flyoutData.common.resourcesEndpoint}groceriesCashback/userRatings/star-black2.png`,o=(0,Y.Ux)("IMG",{});o.className="ratingImage",o.style.margin="0 5px 0 0",o.style.height="12px",o.style.width="12px",o.src=n;const r=(0,Y.Ux)("div",{},`${e.productRatings} · ${e.productReviewsCount}`);return r.className="ratingText",r.style.fontSize="12px",i.appendChild(o),i.appendChild(r),i}CreateTextWithTooltip(e,t,i){const n=(0,Y.Ux)("p",{style:t},e);if(n.setAttribute("aria-hidden","true"),i){const e=(0,Y.Ux)("div",{style:"\n display: flex;\n flex-direction: row;\n margin-top: 4px;\n margin-bottom: 4px;\n column-gap: 4px;\n "}),t=this.CreateICInfoIconToolTip(i,"12px");return e.append(n),e.append(t),e}return n}CreateICInfoIconToolTip(e,t){const n=(0,Y.Ux)("IMG");n.src=this.flyoutData.common.resourcesEndpoint+"/common/infoIcon.svg",n.style.width=t||"10px",n.slot="hover-anchor",n.setAttribute("aria-label","Info icon");const o=e.id,r=e.cashbackProducts[0].title,a=e.cashbackProducts[0].url,s=this.pageHandlerModule,l=e.source===ve.h.SPB?K.bS.CLICK_DISCLAIMER_SPB_CASHBACK:K.bS.CLICK_DISCLAIMER_ITEMIZED_CASHBACK,c=(0,Y.Ux)("msft-shopping-tooltip");c.className="gcTooltip",c.width="225px",c.caratLeftOffset="205px",c.content=(0,Y.Oo)(e.description.replace(/on (any )*/,"").trim());const d=()=>{this.telemetryHandler.LogButtonClickICSpecificTelemetry(i.$S.GroceryItemDisclaimer,l,`Navigated to disclaimer for ${r}`,"");const e=`https://www.msn.com/en-us/foodanddrink/groceries/cashback/${o}?productUrl=${encodeURIComponent(a)}`;s.NavigateToUrl(e)};c.addEventListener("click",(e=>{e.stopPropagation(),d()})),c.addEventListener("keydown",(e=>{e.preventDefault(),"Enter"===e.key&&d()}));const u=e.source===ve.h.SPB?K.bS.HOVER_INFO_ICON_SPB_CASHBACK:K.bS.HOVER_INFO_ICON_ITEMIZED_CASHBACK,h=()=>{this.telemetryHandler.LogButtonClickICSpecificTelemetry(i.$S.GroceryItemTooltipViewed,u,"Grocery item-level cashback tooltip viewed",""),c.removeEventListener("hover",h)};return c.addEventListener("hover",h),c.append(n),c}GetIsActivatedOffer(e){const{GroceryCashbackData:t}=this.flyoutData.dataStoreModule,i=t?.Cashback;return!!i&&void 0!==i.ActivatedOffers.find((t=>t.id===e))}addIcTelemetry(e,t,i,n,o,r={}){const a=void 0!==o?{isActivated:o}:{},s=Ng(Ng({itemSource:n??ve.h.Unknown},a),r);this.telemetryHandler.LogICSpecificTelemetry(t,i,e,s)}GetPriceData(e){const t=e.cashbackProducts[0],i=(0,be.gx)(t.price),n={cashbackValue:{amount:(0,be.gx)(e.offerValue),toDisplay:`$${(0,be.gx)(e.offerValue).toFixed(2)}`},discount:{amount:0,toDisplay:""},finalPrice:{amount:0,toDisplay:""},listPrice:{amount:i,toDisplay:t.price},salePrice:{amount:t.discountedPrice?(0,be.gx)(t.discountedPrice):i,toDisplay:t.discountedPrice??t.price}};return n.finalPrice.amount=n.salePrice.amount-n.cashbackValue.amount,n.finalPrice.amount<0&&(n.finalPrice.amount=0),n.discount.amount=n.listPrice.amount>0?100-100*n.finalPrice.amount/n.listPrice.amount:0,n.finalPrice.toDisplay=`$${n.finalPrice.amount.toFixed(2)}`,n.discount.toDisplay=`${n.discount.amount.toFixed(0)}%`,n}createPriceExplanationContainer(e,t){const i=this.isDarkMode?"#ffffff":"#222222",n=t?"4px":"",o=(0,Y.Ux)("DIV",{style:""}),r=this.createPriceLine(e.listPrice.toDisplay,this.flyoutData.strings.gcListPrice,n,i);if(o.appendChild(r),e.listPrice.amount!==e.salePrice.amount){const t=this.createPriceLine(e.salePrice.toDisplay,this.flyoutData.strings.gcSalePrice,n,i);o.appendChild(t)}if(e.cashbackValue.amount>0){const t=this.createPriceLine(e.cashbackValue.toDisplay,(0,T.fm)(this.flyoutData.strings.cbFeatureName),n,this.isDarkMode?"#00b4ac":"#3267FA","600");o.appendChild(t)}const a=this.createPriceLine(e.finalPrice.toDisplay,this.flyoutData.strings.gcFinalPrice,n,i,"600"),s=(0,Y.Ux)("DIV",{style:"\n border-top: 1px solid #F3F3F3;\n "});return o.appendChild(s),o.appendChild(a),o}createPriceLine(e,t,i,n,o="400"){const r=(0,Y.Ux)("DIV",{style:`\n display: flex;\n margin: 5px 0;\n gap: ${i||"16px"};\n `}),a={style:`\n font-size: 14px;\n line-height: 20px;\n margin: 0;\n font-weight: ${o};\n min-width: fit-content;\n color: ${n};\n `},s=(0,Y.Ux)("p",a,e);s.style.flex="1";const l=(0,Y.Ux)("p",a,t+":");return l.style.flex="2",r.appendChild(l),r.appendChild(s),r}makeActivateButtonActivated(e,t,i,n,o){o||(o=document.querySelector(`#${this.gcMainContent}`));const r=o?.querySelector(`#${this.gcActivatedContainer}`);if(o&&r){const a=this.MakeActivatedSign(e,t,i,!0,n),s=this.makeActivatedContainer();s.appendChild(a),o.replaceChild(s,r)}}makeTextContainerActivated(e,t,i,n,o){o||(o=document.querySelector(`#${this.gcMainContent}`));const r=o?.querySelector(`.${this.textAndImageContainerClassName}`),a=r?.querySelector(`#${this.textContainerId}`);if(r&&a){const o=this.MakeTextContainer(!0,i,e,t,n);r.replaceChild(o,a)}}makeActivatedContainer(){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getActivatedContainerStyles());const e=(0,Y.Ux)("DIV");return e.id=this.gcActivatedContainer,e}MakeButton(e,t,n,o,r,a,s,l){const c=(0,Y.lw)(this.utilities);c.id=this.gcActivateBtnId,l||(l=`${this.flyoutData.strings.gcGetDeal}${o?` ${o} ${this.flyoutData.strings.cbFeatureName}`:""}`),cg.IsSpbInstantATCExpEnabled(this.flyoutData)&&(l=this.flyoutData.strings.gcOkButtonText),c.textContent=l,c.addEventListener("click",(i=>{i.stopPropagation(),this.ActivateOfferClick(e,t,n,o,r,a,"Activate cashback button clicked",s)}));const d=()=>{this.addIcTelemetry(e,i.xu.ItemizedCashbackActivatedHover,`Button name: ${l}`,t.source,a),c.removeEventListener("hover",d)};return c.addEventListener("hover",d),r&&(c.style.borderRadius="4px",c.style.height="32px",c.style.fontSize="14px",c.style.fontWeight="400"),c}ActivateOfferClick(e,t,n,o,r,a,s,l,c=!1){if(this.activateCashbackHandler(t,n,e,a,r),l&&this.addIcTelemetry(e,l,s,void 0,a),n){const i=this.flyoutData.common.isPane&&!r;this.shouldDisableFooterOnPdp&&this.footerUtilities.removeFooterButtons(),gn.SO.queueUpdate((()=>{this.makeActivateButtonActivated(o,t,i,e),this.makeTextContainerActivated(o,t,i,r)}))}else cg.IsInstantAddToCartShowConsent(this.flyoutData,r,c)&&(this.storageHandler.setStorageBool(Ce.Q.GroceryInstantAddToCart,!0),this.telemetryHandler.LogICSpecificTelemetry(i.xu.QuotientInstantATCNotificationClick,"Quotient Search Notification Clicked",e,{offerItem:t}))}async activateCashbackHandler(e,t,n,o,r){o?this.navigateToRetailer(e,o):await this.ActivateCashbackClickHandler(e,t,n,i.xu.ItemizedCashbackActivateClick,r)}async ActivateCashbackClickHandler(e,t,n,o,r){const a=e.source===ve.h.SPB?K.bS.ACTIVATE_CLICK_SPB_CASHBACK:K.bS.ACTIVATE_CLICK_ITEMIZED_CASHBACK,s={offerId:e.id,offerItem:e,ProductId:e.cashbackProducts[0]?.productId,ProductTitle:e.cashbackProducts[0]?.title,itemSource:e.source??ve.h.Unknown,isNotification:r};this.telemetryHandler.LogButtonClickICSpecificTelemetry(i.$S.GroceryItemShopAndActivate,a,"",n,s),this.telemetryHandler.LogICSpecificTelemetry(o,"Activate Qt offer clicked",n,s),this.ActivateOffer(e),this.AddActivatedCashbackItem(e),this.pageHandlerModule.RecordAsUserEngagement(q.FV.ACTIVATE_CASHBACK,this.flyoutData.common.popupOrigination),t||(this.storageHandler.setStorageString(Ce.Q.GroceryCashbackItem,JSON.stringify(e)),this.storageHandler.setStorageBool(Ce.Q.ICActivatedPending,!0)),await x.ZP.Sleep(25),t||this.pageHandlerModule.NavigateToUrl(e.cashbackProducts[0].url)}async ActivateOffer(e){try{await(0,we.bu)(this.flyoutData,this.pageHandlerModule,e)}catch(e){this.telemetryHandler.LogIcError("error in ActivateOffer",e)}}async AddActivatedCashbackItem(e){if(!e)return;const t=this.flyoutData.common.domain,i=(await(0,we.ut)(t,this.storageHandler)).activatedItemsMap,n=e.id;(!i[t]||i[t]&&!i[t].fullItems)&&(i[t]={fullItems:{}});try{const o=new Date,r=24;e.addedTimestamp=o.getTime(),e.expAfterActivatingDate=o.setHours(o.getHours()+r),e.quotientTimestamp=Pe.Z.getQuotientDate(),i[t].impressionId=(0,we.ZK)(this.flyoutData),i[t].fullItems[n]=e;const a=JSON.stringify(i);this.storageHandler.setStorageString(Ce.Q.GroceryCashbackActivated,a)}catch(e){}}navigateToRetailer(e,t){const n=K.bS.ACTIVATED_CLICK_ITEMIZED_CASHBACK;this.telemetryHandler.LogButtonClickICSpecificTelemetry(i.$S.ActivatedGroceryItem,n,"Navigation to product details page from activated cashback","",{isActivated:t}),this.telemetryHandler.LogICSpecificTelemetry(i.xu.ItemizedCashbackActivatedNavigateToRetailer,"",""),this.pageHandlerModule.NavigateToRetailerSite(e.cashbackProducts[0].url,this.flyoutData.common.popupOrigination)}MakeTextContainer(e,t,i,n,o,r,a){const s=(0,Y.Ux)("DIV",{style:`\n display: flex;\n flex-direction: column;\n color: ${this.isDarkMode?"#ffffff":"#222222"};\n `});s.className="gcTextContainer",s.id=this.textContainerId;const l=`\n font-weight: 600;\n font-size: ${e?"32px":"28px"};\n line-height: ${e?"unset":"40px"};\n color: #008A21;\n margin: 0;\n `,c=void 0!==r?r:this.shouldRemoveTooltipOnNotification&&o,d=this.CreateTextWithTooltip(i,l,e&&!c?n:void 0);if(e){const e=(0,Y.Ux)("p",{style:`\n font-weight: 600;\n font-size: ${o?"16px":"20px"};\n line-height: ${o?"22px":"26px"};\n margin: 8px 0 0 0;\n `},this.flyoutData.strings.gcCashbackApplied);if(s.appendChild(d),s.appendChild(e),t){const e=this.CreatePurchaseBeforeTimerText();e.style.marginTop="4px",e.style.lineHeight="16px",s.appendChild(e)}}else{const e=`\n font-weight: 600;\n font-size: ${o?"16px":"20px"};\n margin: 0;\n `,t=this.CreateTextWithTooltip(a?(0,T.fm)(this.flyoutData.strings.cbFeatureName):this.flyoutData.strings.gcbPdpHeaderText,e,c&&a?void 0:n);if(a){const e=(0,Y.Ux)("p",{style:"\n font-family: 'Segoe UI';\n font-style: normal;\n font-weight: 700;\n font-size: 12px;\n line-height: 16px;\n margin: 8px 0 0 0;\n "},this.flyoutData.strings.gcTopDeal);s.appendChild(e),s.appendChild(d),s.appendChild(t),e.style.fontSize="12px",e.style.fontWeight="700",e.style.lineHeight="16px",d.style.fontSize="32px",d.style.fontWeight="700",d.style.lineHeight="43px",t.style.fontSize="20px",t.style.fontWeight="700",t.style.lineHeight="22px"}else s.appendChild(t),s.appendChild(d)}return s}MakeActivatedSign(e,t,i,n,o,r){const a=(0,Y.Ux)("div",{style:"\n display: flex;\n flex-direction: column;\n gap: 8px;\n "});i||a.appendChild(this.CreatePurchaseBeforeTimerText());let s=t.expAfterActivatingDate??0;if(0===s){const e=(this.flyoutData.dataStoreModule.GroceryCashbackData?.activatedCashbackData??[]).find((e=>e.id===t.id));s=e?.expAfterActivatingDate??0}if(s){const e=this.CreateEndsIn(s);e&&(a.appendChild(e),n&&(e.style.textAlign="center"))}if(r)a.appendChild(Rp(this.flyoutData,this.commonAssets,this.isDarkMode,r));else if(cg.ShowItemizedCashbackAddToCart(this.flyoutData)&&this.flyoutData.dataStoreModule.GroceryCashbackData?.Cashback?.isQAddToCartEnabled){const e=(0,Y.lw)(this.utilities);cg.HandleAddToCartButton(e,t,this.flyoutData,this.utilities,this.telemetryHandler,this.pageHandlerModule,o,this.flyoutData.common.domain),a.appendChild(e)}else a.appendChild(Rp(this.flyoutData,this.commonAssets,this.isDarkMode));return a}CreateEndsIn(e){const t=this.MakeEndsnText(e);if(!t)return;const i=(0,Y.Ux)("div",{style:"\n display: flex;\n flex-direction: column;\n gap: 8px;\n "});return i.appendChild(this.CreateDivider()),i.appendChild(t),i}CreatePurchaseBeforeTimerText(){return(0,Y.Ux)("p",{style:"\n font-weight: 400;\n font-size: 14px;\n line-height: 22px;\n color: var(--text-neutral-foreground);\n margin: 0;\n "},this.flyoutData.strings.gcPurchaseBeforeTimer)}CreateDivider(){return(0,Y.Ux)("div",{style:`\n background: #FFFFFF;\n border-top: 1px solid ${this.isDarkMode?"#5a5a5a":"#EFEFEF"};\n box-shadow: 0px 16px 32px rgba(0, 0, 0, 0.14);\n border-radius: 8px;\n `})}MakeEndsnText(e){const t=this.flyoutData.strings.gcEndsIn,i=e-(new Date).getTime();let n="0h 00m";if(!(i>0))return;{const e=i/1e3/60,t=e/60,o=Math.floor(t/24),r=o>0?` ${o} days `:"",a=Math.floor(t-24*o),s=Math.floor(e-24*o*60-60*a);n=`${r} ${a>0?a:0}h ${s>0?s:"00"}m`}const o=(0,Y.Ux)("p",{style:"\n font-weight: 400;\n font-size: 14px;\n line-height: 20px;\n margin: 0;\n "},t),r=(0,Y.Ux)("span",{style:"\n font-weight: 400;\n font-size: 14px;\n line-height: 20px;\n margin: 0;\n color: #C42B1C;\n "},` ${n}`);return o.appendChild(r),o}createCashImageInWrapperForAutoActivate(e,t){const i=e?116:120,n=Ep(t,i,i);n.className="icImageContainer";const o=(0,Y.Ux)("div");return o.className="icImageContainerWrapper",o.appendChild(n),o}createCashImageInWrapper(e,t,i){const n=i&&i>0?i:e?116:120,o=Ep(t,n,n),r=(0,Y.Ux)("div",{style:"\n display: flex;\n justify-content: right;\n align-items: center;\n width: 30%;\n padding: 2px;\n background-color: white;\n border-radius: 8px;\n "});return r.appendChild(o),o.style.borderRadius="8px",r}createCashClickableImageInWrapper(e,t,i,n,o,r,a,s){const l=this.createCashImageInWrapper(e,t);return l.style.cursor="pointer",l.addEventListener("click",(t=>{t.stopPropagation(),this.ActivateOfferClick(i,n,o,r,e,a,"Activate cashback. Image clicked",s,!0)})),l}};let Mg=function(e){return e.PDP="PDP",e.Clipping="Clipping",e.PaneStuck="PaneStuck",e}({});var Lg=class extends Qu{constructor(e,t,n,o){super(),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"spbData",void 0),(0,s.Z)(this,"renderedPageType",void 0),(0,s.Z)(this,"visibilityFeedbackUrlBase",""),(0,s.Z)(this,"telemetryHandler",void 0),(0,s.Z)(this,"uxUtils",void 0),(0,s.Z)(this,"spbComponentUtils",void 0),(0,s.Z)(this,"spbActivatedNotificationUtils",void 0),(0,s.Z)(this,"groceryComponentUtils",void 0),(0,s.Z)(this,"isDarkMode",!1),(0,s.Z)(this,"infiniteScrollWrapperId","gcSectionInfiniteScrollWrapper"),(0,s.Z)(this,"numberOfOffersToShow",4),(0,s.Z)(this,"numberOfOffersRequestedFromBackend",0),(0,s.Z)(this,"recordsPerPage",10),(0,s.Z)(this,"maxSpbOffersToShow",10),(0,s.Z)(this,"isShowConfirmation",!1),(0,s.Z)(this,"isSearchBarEnabledForSpb",!1),(0,s.Z)(this,"isSearchBarEnabledForQt",!1),(0,s.Z)(this,"recentlySeenOffersShown",!1),(0,s.Z)(this,"queryFromSearchBar",""),(0,s.Z)(this,"showHomeSpb",!1),this.flyoutData=e,this.uxUtils=t,this.utilities=t.viewModulesUtilities,this.telemetryHandler=t.telemetryHandler,this.pageHandlerModule=t.pageHandlerModule,this.logModule=t.logModule,this.assets=new class{getStyles(){return"\n .centerTitleForCard::part(title) {\n width: calc(100% - 12px);\n margin: 0;\n font-style: normal;\n font-weight: 600;\n font-size: 16px;\n line-height: 20px;\n display: flex;\n justify-content: center;\n color: var(--text-normal);\n }\n .categoryButton {\n padding: 8px 11px;\n border-radius: 20px;\n text-align: center;\n text-overflow: ellipsis;\n overflow: hidden;\n white-space: nowrap;\n border: unset;\n background-color: rgb(235, 235, 235);\n color: rgb(26, 26, 26);\n font-weight: 400;\n font-size: 12px;\n line-height: 16px;\n cursor: pointer;\n }\n .categoryButton.selected {\n background-color: rgb(10, 134, 218);\n color: rgb(255, 255, 255);\n font-weight: 600;\n }\n .qcHeaderWrapper {\n display: flex;\n margin: 12px;\n height: 25px;\n }\n .qcHeaderTitle {\n margin: 0px;\n font-weight: 600;\n font-size: 14px;\n line-height: 20px;\n padding-right: 2px;\n align-items: end;\n display: flex;\n }\n .gcSectionWrapper {\n margin: 0;\n padding: 0 16px;\n width: auto;\n }\n .groceryCashback {\n padding: 10px;\n display: flex;\n flex-direction: row;\n align-items: center;\n column-gap: 8px;\n text-decoration: none;\n color: unset;\n background: #FFFFFF;\n border-radius: 8px;\n margin-bottom: 4px;\n }\n .groceryCashback:hover {\n background: linear-gradient(265.08deg, rgba(36, 255, 0, 0.02) -6.71%, rgba(0, 210, 255, 0.02) 93.88%);\n }\n .gcHR {\n margin: 0;\n border: 1px solid #F5F5F5;\n }\n .gcImageDiv {\n height: 64px;\n flex: 0 0 64px;\n border-radius: 4px;\n background-repeat: no-repeat;\n background-size: contain;\n background-position: center center\n }\n .gcImageLargeDiv {\n height: 88px;\n flex: 0 0 88px;\n border-radius: 8px;\n background-repeat: no-repeat;\n background-size: contain;\n background-position: center center;\n margin-bottom: 12px;\n }\n .gcTextDiv {\n display: flex;\n flex-direction: column;\n row-gap: 8px;\n justify-content: center;\n }\n .gcTitle {\n color: var(--text-normal);\n font-size: 12px;\n line-height: 16px;\n display: -webkit-box;\n -webkit-box-orient: vertical;\n -webkit-line-clamp: 1;\n overflow: hidden;\n margin: 0px;\n }\n .gcButton {\n background: #FFFFFF;\n color: #008076;\n font-weight: 600;\n height: 26px;\n width: 70px;\n border-color: transparent;\n border-radius: 4px;\n box-sizing: border-box;\n font-size: 12px;\n font-family: inherit;\n line-height: 16px;\n cursor: pointer;\n }\n .gcButton:focus {\n outline: none;\n }\n fluent-button[id*='gcButton']::part(control):focus {\n box-shadow: 0 0 3px 3px #898989;\n }\n .gcButtonColorful {\n background: linear-gradient(88.14deg, #018DC8 0.49%, #01CC83 53.44%, #0CBFC9 104.22%);\n border-radius: 4px;\n padding: 1px;\n height: min-content;\n width: min-content;\n display: flex;\n }\n .gcButtonColorful:focus-within {\n box-shadow: 0px 0px 0px 2px #898989;\n }\n .gcCashbackDiv {\n display: flex;\n flex-direction: row;\n margin-top: 4px;\n margin-bottom: 4px;\n column-gap: 4px;\n width: 100%;\n }\n .gcCashback {\n font-size: 20px;\n line-height: 24px;\n font-weight: 600;\n margin: 0px;\n }\n .gcInfoIcon {\n margin-top: 5px;\n }\n .gcTooltip:focus {\n outline: none;\n }\n\n .gcActivatedDiv {\n display: flex;\n align-content: center;\n column-gap: 4px;\n }\n .gcActivated {\n margin: 0px;\n }\n #gcActivationNotif {\n background: #FFF;\n padding: 12px 20px;\n margin-top: -20px;\n }\n .gcActivationNotifBody{\n display: flex;\n flex-direction: row;\n width: 100%;\n height: 100%;\n column-gap: 8px;\n justify-content: space-between;\n }\n .gcActivationContainer {\n border-radius: 8px;\n }\n .gcActivatedText {\n font-weight: 600;\n font-size: 20px;\n line-height: 26px;\n margin: 0;\n }\n .gcActivationNotifSeparator {\n height: 1px;\n width: 100%;\n background: #F1F1F1;\n }\n .gcActivationFooter {\n font-weight: 400;\n font-size: 12px;\n line-height: 16px;\n margin-top: 12px;\n margin-bottom: 0px;\n }\n .gcCategoriesSectionWrapper {\n display: flex;\n flex-wrap: wrap;\n flex-direction: row;\n row-gap: 5px;\n column-gap: 7px;\n margin: 0px 20px 8px 20px;\n box-sizing: border-box;\n }\n #groceryRebatesTitle {\n font-family: 'Segoe UI Variable Static Text','Segoe UI';\n font-size: 20px;\n line-height: 24px;\n font-weight: 800;\n text-align: center;\n margin: 0px;\n width: calc(75%);\n }\n #groceryCashbackSection {\n text-align: left;\n }\n #groceryRebatesSubtitle {\n font-family: 'Segoe UI';\n font-size: 12px;\n line-height: 16px;\n text-align: center;\n color: #333333;\n margin: 0px;\n width: calc(75%);\n }\n #gcReceiptScannerBannerContainer {\n margin: 0px 20px 8px 20px;\n position: relative;\n height: auto;\n }\n #gcReceiptScannerBannerContainer .backgroundImage {\n width: 100%;\n height: 195px;\n background-size: cover;\n border-radius: 6px;\n }\n #gcReceiptScannerBannerContainer .getAppText {\n position: absolute;\n width: 172px;\n height: 20px;\n left: 16px;\n top: 104px;\n font-family: 'Segoe UI Variable Static Text', sans-serif;\n font-style: normal;\n font-weight: 400;\n font-size: 14px;\n line-height: 20px;\n color: #FFFFFF;\n text-shadow: 0px 4px 25px rgba(0, 0, 0, 0.8);\n }\n #gcReceiptScannerBannerContainer .scanReceiptText {\n position: absolute;\n width: 170px;\n height: 52px;\n left: 16px;\n top: 123px;\n font-family: 'Segoe UI Variable Static Display', 'Segoe UI';\n font-style: normal;\n font-weight: 600;\n font-size: 20px;\n line-height: 26px;\n color: #FFFFFF;\n text-shadow: 0px 4px 25px rgba(0, 0, 0, 0.8);\n }\n #gcReceiptScannerBannerContainer .qRCodeText {\n position: absolute;\n width: 86px;\n height: 20px;\n left: 219px;\n top: 157px;\n font-family: 'Segoe UI Variable Static Text', 'Segoe UI';\n font-style: normal;\n font-weight: 400;\n font-size: 14px;\n line-height: 20px;\n color: #FFFFFF;\n text-shadow: 0px 4px 25px rgba(0, 0, 0, 0.8);\n }\n #gcReceiptScannerBannerContainer .qRCodeImage {\n position: relative;\n display: block;\n width: 80px;\n height: 80px;\n border-radius: 5%;\n }\n #gcReceiptScannerBannerContainer .qRCodeImageWrapper {\n position: absolute;\n left: 221px;\n top: 73px;\n border-radius: 10.9211px;\n }\n #gcReceiptScannerDealContainer {\n margin: 0px 20px 12px 20px;\n cursor: pointer;\n }\n #receiptScanningDealBanner {\n width: 100%;\n }\n "}getSpbStyles(){return"#btnMainMenu div {\n display: flex;\n }\n #btnFlyoutClose div {\n display: flex;\n }\n #btnFlyoutClose.timed {\n margin-right: 2px;\n margin-left: 3px;\n border-radius: 50%;\n position: relative;\n }\n #btnFlyoutClose.timed::part(control) {\n border: 1px solid #EFEFEF;\n height: 33px;\n width: 33px;\n }\n #btnFlyoutClose #progressCircle {\n display: initial !important;\n }\n .closeIconWrapperForTimed {\n background-color: #ffffff;\n position: absolute;\n display: flex;\n justify-content: center;\n align-items: center;\n border-radius: 50%;\n top: 2px;\n left: 2px;\n height: 29px;\n width: 29px;\n }\n #divPrivacyMessage {\n font-size: 10px;\n line-height: 14px;\n }\n #divPrivacySpbBlock {\n margin-top: 12px;\n margin-left: 5px;\n text-align: center;\n line-height: 14px;\n width: 95%;\n }\n "}getSpbStylesDarkMode(){return"#btnMainMenu div {\n display: flex;\n }\n #btnFlyoutClose div {\n display: flex;\n }\n #btnFlyoutClose.timed {\n margin-right: 2px;\n margin-left: 3px;\n border-radius: 50%;\n position: relative;\n }\n #btnFlyoutClose.timed::part(control) {\n border: 1px solid #EFEFEF;\n height: 33px;\n width: 33px;\n }\n #btnFlyoutClose #progressCircle {\n display: initial !important;\n }\n .closeIconWrapperForTimed {\n background-color: #3b3b3b;\n position: absolute;\n display: flex;\n justify-content: center;\n align-items: center;\n border-radius: 50%;\n top: 2px;\n left: 2px;\n height: 29px;\n width: 29px;\n }\n #divPrivacyMessage {\n font-size: 10px;\n }\n #divPrivacySpbBlock {\n margin-top: 12px;\n margin-left: 5px;\n text-align: center;\n line-height: 14px;\n width: 95%;\n }\n "}getDarkModeStyles(){return"\n .groceryCashback {\n background: #3b3b3b\n }\n .gcButton {\n background: #3b3b3b;\n color: #02d9c8;\n }\n .gcHR {\n border: solid 0.5px #656565;\n }\n .categoryButton {\n background-color: #2B2B2B;\n color: #ffffff;\n }\n #gcActivationNotif {\n background: #464b4d;\n }\n #groceryRebatesSubtitle {\n color: #dedede;\n }\n #groceryCashbackSection {\n text-align: left;\n }\n "}getSmallerNotificationCssStyles(){return"\n #divContentWrapper {\n width: 268px;\n }\n .actionsPrimaryButtonRefresh {\n width: 236px;\n background: linear-gradient(90.05deg, #8300D4 0.59%, #0048D4 67.54%, #00D4A1 104.11%);\n }\n .actionsPrimaryButtonRefresh:hover {\n background: linear-gradient(90.05deg, #9E00FF 0.59%, #0048D4 67.54%, #00FFC2 104.11%);\n }\n "}},this.storageHandler=t.storageHandler,this.commonAssets=n,this.stateManagement=o,this.isDarkMode=this.utilities.isDarkMode(),this.spbComponentUtils=new pg(e,t,this.commonAssets),this.spbActivatedNotificationUtils=new class{constructor(e,t,i){(0,s.Z)(this,"textAndImageContainerClassName","icTextAndImageContainer"),(0,s.Z)(this,"showDiscountMin",5),(0,s.Z)(this,"assetsItemizedCashback",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"telemetryHandler",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),this.flyoutData=e,this.commonAssets=i,this.utilities=t.viewModulesUtilities,this.telemetryHandler=t.telemetryHandler,this.pageHandlerModule=t.pageHandlerModule,this.assetsItemizedCashback=new Qp}createSpbActivatedNotification(e,t){const n=this.CreateSpbActivatedNotificationHeader(),o=(0,Y.Ux)("div",{id:"divCashBackPopup"}),r=(0,Y.Ux)("div",{className:"txtMedium",id:"divCashBackContent"}),a=(0,Y.Ux)("div",{id:"divWrapperPcb"}),s=(0,Y.Ux)("div",{id:"divContentPcb"}),l=(0,Y.Ux)("div",{id:"divInfoPcb"}),c=(0,Y.Ux)("div",{id:"txtTitlePcb"});c.textContent=(0,T.fm)(this.flyoutData.strings.cbFeatureName);const d=e?.personalizedCashback.commissionValue,u=this.utilities.createCommissionArrow(d,!1,zu.h.Medium,void 0,"$",!1,!0);u.setAttribute("aria-hidden","true");const h=(0,Y.Ux)("div",{id:"divForYouPcb"}),p=(0,Y.Ux)("div",{id:"txtForYouPcb"});p.textContent=this.flyoutData.strings.forYou,h.appendChild(p),l.appendChild(c),l.appendChild(u),l.appendChild(h),s.appendChild(l);const g=e?.personalizedCashback.adsCashback[0],f=this.createImagePcb(g);f.style.marginLeft="auto",f.style.marginBottom="auto",s.appendChild(f);const m=(0,Y.Ux)("div",{id:"dividerPcb"});a.appendChild(s),a.appendChild(m);const v=this.CreateOfferEndDate(c),y=this.createActivatedGreenSign(this.flyoutData.strings.pcbActivatedButton),C=this.createActivatedGreenSign(this.flyoutData.strings.gcInstantAddedToCartActivated);if(t?a.appendChild(this.CreateActivatedAnimation(y,C)):a.appendChild(this.CreateActivatedAnimation(y,v)),setTimeout((()=>{cg.animateText()}),1e3),r.appendChild(a),cg.ShowItemizedCashbackAddToCart(this.flyoutData)){const n=(0,Y.lw)(this.utilities);cg.HandleAddToCartButton(n,e.personalizedCashback,this.flyoutData,this.utilities,this.telemetryHandler,this.pageHandlerModule,i.e4.SPBActivatedNotification),t||r.appendChild(n)}const b=(0,Y.Ux)("div",{id:"dividerHeader"}),S=(0,Y.Ux)("div");return S.appendChild(n),S.appendChild(b),o.appendChild(r),S.appendChild(o),S}CreateSpbActivatedNotificationHeader(e=10){const t=(0,Y.Ux)("div",{style:"display: flex;\n justify-content: space-between;\n align-items: center;\n height: 40px;"}),i=new class{getStyles(){return"\n html {\n overflow: hidden;\n }\n #divContentWrapper {\n width: 280 px;\n height: auto;\n display: inline-block;\n }\n #divWrapperPcb {\n width: -webkit-fill-available;\n margin-left: 16px;\n margin-right: 16px;\n margin-bottom: 5px;\n }\n #divContentPcb {\n display: grid;\n grid-template-columns: 50% 50%;\n height: 100px;\n }\n body {\n margin: 0px;\n }\n fluent-design-system-provider {\n margin: 0px;\n display: flex;\n }\n .txtLarge {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 24px;\n line-height: 24px;\n margin: 0px;\n }\n .txtMedium {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 16px;\n line-height: 20px;\n margin: 0px;\n }\n .txtSmall {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 14px;\n line-height: 16px;\n margin: 0px;\n }\n #shopping-tag-icon {\n fill: #1F65F1;\n height: 17px;\n width: 17px;\n margin: auto;\n }\n ::part(header-fixed) {\n display: none;\n }\n ::part(header) {\n display: none;\n }\n ::part(sections) {\n margin-top: 0px!important;\n }\n #countdown-container {\n fill: rgb(255, 255, 255);\n position: absolute;\n left: 50%;\n display: inline;\n top: 50%;\n background: transparent;\n border: unset;\n cursor: pointer;\n transform: translate(-50%, -50%);\n padding:0;\n }\n #countdown-svg {\n width: 30px;\n height: 30px;\n display:block;\n margin:auto;\n transform: rotateY(-180deg) rotateZ(-90deg) scale(1,-1);\n }\n #countdown-circle {\n stroke-dasharray: 81.6px;\n stroke-dashoffset: 0px;\n stroke-linecap: round;\n stroke-width: 1.3px;\n stroke: #4F94D3;\n fill: none;\n animation: countdown 10s linear 1 forwards;\n }\n #back-countdown-circle {\n stroke-dasharray: 81.6px;\n stroke-dashoffset: 0px;\n stroke-linecap: round;\n stroke-width: 1px;\n stroke: #afacac;\n fill: none;\n }\n @keyframes countdown {\n from {\n stroke-dashoffset: 81.6px;\n }\n to {\n stroke-dashoffset: 0px;\n }\n }\n @media (-ms-high-contrast: active) {\n #flyoutClose {\n fill: ButtonText;\n }\n #shopping-tag-icon path {\n d: path(\"M12 5C12.5523 5 13 4.55228 13 4C13 3.44772 12.5523 3 12 3C11.4477 3 11 3.44772 11 4C11 4.55228 11.4477 5 12 5ZM9.12922 4.30281e-05C8.59514 -0.00345791 8.08184 0.206807 7.7037 0.583987L1.02216 7.24852C0.239412 8.02928 0.238604 9.297 1.02036 10.0788L5.96875 15.0271C6.7498 15.8082 8.01613 15.8082 8.79718 15.0271L15.428 8.39633C15.8038 8.02054 16.0146 7.51063 16.0138 6.97917L16.0065 2.02911C16.0049 0.930807 15.1179 0.0393006 14.0196 0.032101L9.12922 4.30281e-05ZM8.4099 1.29199C8.59897 1.1034 8.85562 0.998271 9.12266 1.00002L14.013 1.03208C14.5622 1.03568 15.0057 1.48143 15.0065 2.03058L15.0138 6.98065C15.0142 7.24637 14.9088 7.50133 14.7209 7.68923L8.09007 14.32C7.69955 14.7106 7.06638 14.7106 6.67586 14.32L1.72746 9.37164C1.33659 8.98077 1.33699 8.34691 1.72836 7.95653L8.4099 1.29199Z\");\n fill: ButtonText;\n transform: scale(0.85);\n }\n #countdown-circle{\n stroke: Text;\n }\n #back-countdown-circle {\n display: none;\n }\n }\n "}getDarkModeStyles(){return"\n .txtSmall {\n color: #FFFFFF;\n }\n .txtMedium {\n color: #FFFFFF;\n }\n .txtLarge {\n color: #FFFFFF;\n }\n #shopping-tag-icon {\n fill:#86BFEB;\n }\n "}};this.utilities.applyStyles(this.flyoutData.common.shopping,i.getStyles(),void 0,i.getDarkModeStyles());const n=(0,Y.Ux)("div",{style:"display: flex;\n align-items: center;\n margin-inline-start: 8px;\n "}),o=(0,Y.Ux)("span",{style:" display: inline-block;\n font-weight: 600;\n margin-inline-start: 8px;\n "});o.textContent=this.flyoutData.strings.commonFixedTitle;const r=(0,Y.Ux)("div",{style:"display: flex;\n margin-inline-start: 4px;\n "});r.innerHTML=this.commonAssets.getShoppingIcon(),r.setAttribute("aria-hidden","true"),n.appendChild(r),n.appendChild(o);const a=(0,Y.Ux)("button");a.id="countdown-container",a.innerHTML=this.commonAssets.getCountdownTimerIcon(),a.title=this.flyoutData.strings.commonClose,a.setAttribute("aria-label",this.flyoutData.strings.commonClose);const s=(0,Y.Ux)("div",{style:" margin: 6px;\n width: 30px;\n height: 30px;\n position: relative;\n "});s.appendChild(a),s.setAttribute("aria-labelledby","countdown-container");const l=s.querySelector("#countdown-circle");l.style.animationDuration=`${e}s`,l.setAttribute("aria-hidden","true");const c=(0,Y.Ux)("span");c.innerHTML=this.commonAssets.getCloseButton(),c.style.fill="#808080",c.setAttribute("aria-hidden","true");const d=c.querySelector("#flyoutClose");d.style.position="absolute",d.style.top="50%",d.style.left="50%",d.style.transform="translate(-50%,-50%)",this.utilities.isDarkMode()&&(l.style.stroke="#FFFFFF",c.style.fill="#FFFFFF"),a.addEventListener("click",(async e=>{e.stopPropagation(),this.pageHandlerModule.DismissPopup()})),a.appendChild(c);const u=document.querySelector("html");return u&&(u.style.overflow="hidden"),t.appendChild(n),t.appendChild(s),this.postNotification(t,e),t}postNotification(e,t){const n=e.querySelector("#countdown-circle"),o=()=>{clearTimeout(s),n.style.display="none"},a=()=>{s=setTimeout((()=>{this.pageHandlerModule.DismissPopup()}),1e3*t),n.style.display="block"};let s=setTimeout((()=>{this.pageHandlerModule.DismissPopup()}),1e3*t);n.style.animationDuration=`${t}s`,e.addEventListener("click",(async t=>{clearTimeout(s),new W.Z(i.$S.SpbActivatedNotificationHeaderClick,this.telemetryHandler.setContentViewed(r.sM.ITEMIZED_CASHBACK_NOTIFICATION)).Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),e.removeEventListener("mouseenter",o),e.removeEventListener("focusin",o),e.removeEventListener("mouseleave",a),e.removeEventListener("focusout",a)})),e.addEventListener("mouseenter",o),e.addEventListener("focusin",o),e.addEventListener("mouseleave",a),e.addEventListener("focusout",a)}CreateActivatedAnimation(e,t){const i=(0,Y.Ux)("div");this.utilities.applyStyles(i,cg.GetActivatedAnimationStyles()),i.setAttribute("id","activated-animation");const n=(0,Y.Ux)("div");return i.appendChild(n),e.setAttribute("id","activatedSign"),t.setAttribute("id","offerEndDate"),e.setAttribute("style","display: block;"),t.setAttribute("style","display: none;"),n.appendChild(e),n.appendChild(t),i}createImagePcb(e){const t=(0,Y.Ux)("IMG",{id:"productImage"});e.imageUrl&&""!==e.imageUrl?e.imageUrl.indexOf("bing.com")>0?t.src=e.imageUrl:t.src="https://www.bing.com"+e.imageUrl:t.src=`${this.flyoutData.common.resourcesEndpoint}retailerBranding/SquareIcons/${e.domain}.png`,t.setAttribute("aria-label",e.scope),t.style.height="100%",t.style.width="100%",t.style.objectFit="contain";const i=(0,Y.Ux)("DIV");i.style.width="88px",i.style.height="88px",i.style.position="relative",i.appendChild(t);const n=this.utilities.createProductImage(88,88,t);return n.slot="image",n}createActivatedGreenSign(e){const t=(0,Y.Ux)("div",{style:"\n display: flex;\n flex-direction: column;\n "}),i=(0,Y.Ux)("div",{style:"\n padding: 8px;\n display: flex;\n justify-content: center;\n align-items: center;\n gap: 7px;\n "}),n=(0,Y.Ux)("p",{style:"\n font-weight: 400;\n font-size: 14px;\n line-height: 20px;\n margin: 0;"},e),o=(0,Y.Ux)("div");return o.innerHTML=this.commonAssets.getGreenCheckCircle(),o.style.display="flex",o.setAttribute("role","presentation"),o.setAttribute("aria-hidden","true"),i.appendChild(o),i.appendChild(n),t.appendChild(i),t}CreateOfferEndDate(e){const t=(0,Y.Ux)("div",{style:"\n display: inline-flex;\n font-weight: 400;\n font-size: 14px;\n line-height: 20px;\n margin-top: 10px;\n "}),i=(0,Y.Ux)("div",{style:"\n display: inline-flex;\n font-weight: 400;\n font-size: 14px;\n line-height: 20px;\n margin-top: 10px;\n "});i.style.textAlign="left";const n=(0,Y.Ux)("span",{style:"\n margin-left: 5px;\n display: inline-flex;\n font-weight: 400;\n font-size: 14px;\n "});n.style.color=this.utilities.isDarkMode()?"rgba(250, 124, 82, 1)":"rgba(196, 43, 28, 1)";const o=(new Date).getTime()+8634e4;n.textContent=this.getTimeDifference(Date.now(),o),(0,T.B7)(i,this.flyoutData.strings.cbSpbExpiryDateTime,n);const r=(0,T.fZ)("pcbAriaLabel",this.flyoutData.strings.pcbAriaLabel,"test","23",n.textContent);return e.setAttribute("aria-label",r),t.appendChild(i),t}getTimeDifference(e,t){let i=t-e;const n=36e5;let o=i/n;i%=n,o|=0;let r=i/6e4;return i%=6e4,r|=0,0===o?r+"m":o+"h "+r+"m"}}(e,t,this.commonAssets)}GetModuleName(){return r.ModuleNames.ITEMIZED_CASHBACK}async ShouldRenderModule(){if(this.flyoutData.common.openedWith===r.Te.Auto&&this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_SPB_CASHBACK_LANDING)return Promise.resolve(!1);if(e.R.isExperimentActive(f.H.cashbackConsolidationExp))return Promise.resolve(!1);if(this.HandleSpbPdpExactMatchRefresh(),this.spbComponentUtils.showSPBOffersOnShorelineOpenExp())return!1;if(this.flyoutData.dataStoreModule.SPBItemizedCashbackData&&(this.spbData=this.flyoutData.dataStoreModule.SPBItemizedCashbackData),this.spbData?.IsSpbFlightActive){this.CheckIfShowSpbHomePage();const t=Boolean(this.spbData.SpbPDPData?.pdpActivatedData?.adsCashbackItem);this.stateManagement.setState(Ku.IY.pdpForActivatedAd,t);let n=!1,o=!1;if(this.SetPageInfoType(),this.spbData.ItemizedCashback.length>0?(n=!0,this.visibilityFeedbackUrlBase=this.spbData.AdsMetadata.visibilityFeedbackUrl??""):!1===this.spbData.SpbPDPData?.ItemizedCashbackExactMatch?.isActivated||this.spbData.SpbPDPData?.RelatedOffers&&this.spbData.SpbPDPData.RelatedOffers.length>0?(n=!0,this.visibilityFeedbackUrlBase=this.spbData.SpbPDPData?.AdsMetadata?.visibilityFeedbackUrl??""):this.showHomeSpb&&this.spbData.homePageSpbOffers?.homePageSpbOffers&&this.spbData.homePageSpbOffers.homePageSpbOffers.length>0?(n=!0,this.renderedPageType=i.e4.HomePage,this.visibilityFeedbackUrlBase=""):this.spbData.seenSpbOffers&&this.spbData.seenSpbOffers.length>0&&(o=!0,n=o,this.visibilityFeedbackUrlBase=""),!n)return Promise.resolve(!1);if(o){if((0,we.KI)(this.flyoutData.dataStoreModule.GroceryCashbackData))return Promise.resolve(!1);if(this.spbData.homePageSpbOffers?.homePageSpbOffers&&this.spbData.homePageSpbOffers.homePageSpbOffers.length>0)return Promise.resolve(!1)}if(!e.R.isExperimentActive(f.H.searchInPane)){const e=this.flyoutData.dataStoreModule?.GroceryCashbackData?.Cashback?.Variations?.get("searchInPane");this.isSearchBarEnabledForSpb="enabled"===e&&this.renderedPageType===i.e4.SPBSearchPage;const t=this.flyoutData.dataStoreModule?.GroceryCashbackData?.Cashback?.Variations?.get("searchInPaneQt");this.isSearchBarEnabledForQt="enabled"===t&&this.renderedPageType===i.e4.SPBSearchPage,(this.isSearchBarEnabledForSpb||this.isSearchBarEnabledForQt)&&(this.groceryComponentUtils=new Rg(this.flyoutData,this.uxUtils,this.commonAssets))}return Promise.resolve(n)}return Promise.resolve(!1)}populateMainHeader(){const e=this.flyoutData.common.shopping.querySelector("#icCashbackSection");e&&(e.slot="header-content")}async renderModule(){this.utilities.applyStyles(this.flyoutData.common.shopping,this.spbComponentUtils.assetsItemizedCashback.getStyles(),void 0,this.spbComponentUtils.assetsItemizedCashback.getDarkModeStyles());const e=(0,Y.Ux)("msft-edge-shopping-section"),t=e;if(t.id="icCashbackSection",t.titleText=this.flyoutData.strings.gcbSectionTitle,t.accordion=this.flyoutData.common.currentDevice===r.AS.Desktop,t.expanded=!0,(this.isSearchBarEnabledForSpb||this.isSearchBarEnabledForQt)&&this.CreateSearchBar(t),this.CreateSubTitle(e),this.isShowConfirmation){this.telemetryHandler.LogICSpecificTelemetry(i.xu.SPBConfirmationCardView,"",this.renderedPageType);const t=this.spbComponentUtils.GetSpbConfirmationScreenUx(!1,this.renderedPageType,i.xu.SPBConfirmationCardHover);t.rootDiv.style.marginBottom="20px",e.appendChild(t.rootDiv)}let n=!1;if(this.spbData.SpbPDPData?.ItemizedCashbackExactMatch&&!this.spbData.SpbPDPData.ItemizedCashbackExactMatch.isActivated){const t=this.spbData.SpbPDPData.ItemizedCashbackExactMatch.isActivated;this.telemetryHandler.LogICSpecificTelemetry(i.xu.SPBOfferCardView,"Exact match spb offer view",this.renderedPageType,{isActivated:this.spbData.SpbPDPData.ItemizedCashbackExactMatch.isActivated,offerId:this.spbData.SpbPDPData.ItemizedCashbackExactMatch.id,offerItem:this.spbData.SpbPDPData.ItemizedCashbackExactMatch.adsOffer});const o=this.spbComponentUtils.createElementForOfferV2Card(this.spbData.SpbPDPData.ItemizedCashbackExactMatch,this.renderedPageType,i.xu.SPBOfferCardHover,"pdpSPB"===this.spbData.PageInfoType,!1,!1,t?"":this.visibilityFeedbackUrlBase,!0);o.rootDiv.style.marginBottom="20px",e.appendChild(o.rootDiv),n=!0}return this.spbData.ItemizedCashback.length>0?this.CreateInfiniteScroll(t,this.spbData.ItemizedCashback):this.spbData.SpbPDPData?.RelatedOffers&&this.spbData.SpbPDPData.RelatedOffers.length>0?this.CreateInfiniteScroll(t,this.spbData.SpbPDPData.RelatedOffers):this.showHomeSpb&&this.spbData.homePageSpbOffers?.homePageSpbOffers&&this.spbData.homePageSpbOffers.homePageSpbOffers.length>0?this.CreateInfiniteScroll(t,this.spbData.homePageSpbOffers.homePageSpbOffers):this.spbData.seenSpbOffers&&this.spbData.seenSpbOffers.length>0&&!n&&(this.recentlySeenOffersShown=!0,this.CreateInfiniteScroll(t,this.spbData.seenSpbOffers)),this.spbComponentUtils.updateHomePageOffers(),Promise.resolve(this.CreateModule(e,r.H7.IC_CASHBACK,r.ModuleNames.ITEMIZED_CASHBACK,r.$k.CONTEXTUAL,r.SV.LIST))}PostProcessing(e,t,n){const o=this.spbData.SpbPDPData?.ItemizedCashbackExactMatch?.isActivated??!1,r=`position ${t}`;this.telemetryHandler.LogICSpecificTelemetry(o?i.xu.ItemizedCashbackWithPdpActivated:this.recentlySeenOffersShown?i.xu.ItemizedCashbackRecentlyShown:i.xu.ItemizedCashback,r,this.renderedPageType,{itemSource:ve.h.SPB,isRecentlySeenOffersShown:this.recentlySeenOffersShown,spbData:this.spbData??""})}CheckIfShowSpbHomePage(){const e=this.flyoutData.dataStoreModule.GroceryCashbackData?.useCategoryFiltering;this.showHomeSpb=!e}IsExactMatchActivated(e,t){let i;if(e&&e.detail&&e.detail.data&&e.detail.data.couponsApiResponse){const n=JSON.parse(e.detail.data.couponsApiResponse);if(n.personalizedAdsResponse&&n.personalizedAdsResponse.personalizedCashback){const e=n.personalizedAdsResponse.personalizedCashback||void 0,{activatedDestinationUrlPathnames:o}=(0,Ie.An)(e),r=t.pathname||(0,Ie.en)(t.adsOffer.destinationUrl)?.pathname||"";i=o.has(r)}}return i}HandleSpbPdpExactMatchRefresh(){let e,t=!1;this.stateManagement.addEventListener(Ku.e1.PDPUpdate,(i=>{const n=new CustomEvent(Ku.e1.PDPRemoved,{detail:{moduleName:this.GetModuleName()}});if(i&&i.detail&&i.detail.data&&i.detail.data.comparableOffers&&i.detail.data.comparableOffers.value&&this.isExactMatch(i.detail.data.comparableOffers)){const n=this.isExactMatch(i.detail.data.comparableOffers),o=i.detail.data.comparableOffers,r=Ve.CreateFromComparableOffer(n,o?.visibilityFeedbackUrl||"");e=r,t=!0}if(e&&t){this.flyoutData&&this.flyoutData.dataStoreModule&&this.flyoutData.dataStoreModule.SPBItemizedCashbackData&&(this.flyoutData.dataStoreModule.SPBItemizedCashbackData.SpbPDPData?(this.flyoutData.dataStoreModule.SPBItemizedCashbackData.SpbPDPData.ItemizedCashbackExactMatch=e,this.flyoutData.dataStoreModule.SPBItemizedCashbackData.SpbPDPData.ItemizedCashbackExactMatch.isActivated=this.IsExactMatchActivated(i,e)):(this.flyoutData.dataStoreModule.SPBItemizedCashbackData.SpbPDPData=new je,this.flyoutData.dataStoreModule.SPBItemizedCashbackData.SpbPDPData.ItemizedCashbackExactMatch=e,this.flyoutData.dataStoreModule.SPBItemizedCashbackData.SpbPDPData.ItemizedCashbackExactMatch.isActivated=this.IsExactMatchActivated(i,e)));const t=new CustomEvent(Ku.e1.ReRankFlyout,{detail:{refreshType:Mg.PDP}});this.stateManagement.dispatchEvent(t)}else this.stateManagement.dispatchEvent(n)}))}CreateSubTitle(e){const t=this.spbComponentUtils.CreateSubTitle(this.renderedPageType,this.flyoutData.dataStoreModule?.SPBItemizedCashbackData?.PageTitle??"",this.queryFromSearchBar);t&&e.appendChild(t)}ReplaceSubTitleQuery(e,t){const i=e.querySelector(".icSubtitleQuery");i&&(i.textContent=t)}isExactMatch(e){return(e?.value||[]).find((e=>e.position===r.zE.SPB_OFFERS))}SetPageInfoType(){"search"===this.spbData.PageInfoType||"searchSPB"===this.spbData.PageInfoType?this.renderedPageType=i.e4.SPBSearchPage:"category"===this.spbData.PageInfoType?this.renderedPageType=i.e4.SPBCategoryPage:"ConfirmationSpb"===this.spbData.PageInfoType?this.isShowConfirmation=!0:"pdpSPB"===this.spbData.PageInfoType&&(this.renderedPageType=i.e4.SPBPdpPage)}CreateSearchBar(e){const t=this.spbComponentUtils.CreateSearchBar((async(e,t,i,n)=>{const{newOffersQt:o,newOffers:r,visibilityFeedbackUrl:a,queryFromSearchBar:s}=await this.spbComponentUtils.ProcessNewSearchData(e,this.storageHandler,t,i,this.renderedPageType,n,this.isSearchBarEnabledForSpb,this.isSearchBarEnabledForQt),l=this.flyoutData.common.shopping.querySelector("#icCashbackSection");l&&(this.queryFromSearchBar=s,this.visibilityFeedbackUrlBase=a,this.CreateInfiniteScroll(l,r,o,!0,!0,!0),this.ReplaceSubTitleQuery(l,s))}));e.appendChild(t)}async CreateInfiniteScroll(e,t,i=[],n=!1,o=!1,r=!1){const a=this.spbComponentUtils.CreateGCSectionWrapper(this.infiniteScrollWrapperId),s=this.spbComponentUtils.CreateGCSectionList(),l=t.slice(0,this.numberOfOffersToShow);if(l.length>0){const e=this.spbComponentUtils.CreateSponsoredElement(this.renderedPageType);e.className="isSponsoredIconContainer",a.appendChild(e)}else i.length>0&&(s.style.marginTop="10px");if(this.numberOfOffersRequestedFromBackend=l.length,this.AppendGroceryCashbackList(s,l,i,r),a.appendChild(s),n){if(0===l.length&&0===i.length&&o){const e=(0,Y.Ux)("p",void 0,this.flyoutData.strings.gcSpbSearchBarOffersNotFound);s.appendChild(e)}const t=e.querySelector(`#${this.infiniteScrollWrapperId}`);t?e.replaceChild(a,t):e.appendChild(a)}else e.appendChild(a);if(this.numberOfOffersToShow<t.length){const e=this.CreateSeeMoreButton();a.appendChild(e),e.addEventListener("click",(async()=>{await this.SeeMoreOffersListen(t,s,e,i,r)}))}}async SeeMoreOffersListen(e,t,n,o,r){this.telemetryHandler.LogButtonClickICSpecificTelemetry(i.$S.SeeMoreItemizedCashback,K.bS.CLICK_SPB_CASHBACK_SEE_MORE,"",this.renderedPageType,{isActivated:!1});let a=this.numberOfOffersRequestedFromBackend;if(a<e.length)this.AppendGroceryCashbackList(t,e.slice(a),o?.slice(a),r),a=e.length,a>=this.maxSpbOffersToShow&&n.remove();else{const e={startRecord:a,recordsPerPage:this.recordsPerPage},i=await this.GetOffersPagination(e.startRecord,e.recordsPerPage),s=i.returnData.length,l=i.returnData;l.length>0?(this.AppendGroceryCashbackList(t,l,o,r),a+=s,a>=i.totalRecords&&n.remove()):n.remove()}this.numberOfOffersRequestedFromBackend=a}async GetOffersPagination(e,t){return{returnData:[],totalRecords:this.maxSpbOffersToShow}}CreateSeeMoreButton(){const e=document.createElement("fluent-button");e.slot="action",e.className+="action btnSeeMore",e.id="seeMoreButton";const t=this.flyoutData.common.isPane;return t?(e.style.fontWeight="400",e.classList.add("newSeeMore"),e.appearance="neutral",this.SeeMoreButtonAddContent(e,!1)):(e.appearance="lightweight",e.style.backgroundColor="transparent",e.style.padding="0px"),this.utilities.isDarkMode()?e.style.color="#FFFFFF":e.style.color=t?"#1A1A1A":"#666666",t&&(e.style.marginLeft="0px",e.style.marginTop="10px"),e}SeeMoreButtonAddContent(e,t){if(this.flyoutData.common.isPane){const i=(0,Y.Ux)("DIV");i.style.display="inline-block",i.style.paddingLeft="10px",i.innerHTML=this.commonAssets.getCaretDownIcon(),e.textContent=t?this.flyoutData.strings.sectionSeeMoreViewLess:this.flyoutData.strings.commonSeeMore,t&&(i.style.transform="rotate(180deg)",i.style.paddingRight="10px",i.style.paddingLeft="0px"),e.appendChild(i)}else e.textContent=t?this.flyoutData.strings.sectionSeeMoreViewLess:this.flyoutData.strings.commonSeeMore}AppendGroceryCashbackList(e,t,i,n){if(e)if(t&&t.length>0){const i={};for(const o of t){const t=this.spbComponentUtils.CreateSPBGridCard(o,this.renderedPageType,this.recentlySeenOffersShown,n,!1,this.visibilityFeedbackUrlBase);e.appendChild(t),this.visibilityFeedbackUrlBase||(i[o.visibilityFeedbackUrlBase]?i[o.visibilityFeedbackUrlBase].push(o):i[o.visibilityFeedbackUrlBase]=[o])}this.visibilityFeedbackUrlBase?this.spbComponentUtils.CreateAndSendVisibilityFeedbackUrl(t,this.visibilityFeedbackUrlBase,!1,this.renderedPageType):Object.keys(i).forEach((e=>{this.spbComponentUtils.CreateAndSendVisibilityFeedbackUrl(i[e],e,!1,this.renderedPageType)}))}else if(i.length>0&&this.groceryComponentUtils)for(const t of i){const i=this.groceryComponentUtils.CreateGridCard(t,this.renderedPageType,n);e.appendChild(i)}}};function Bg(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}var Fg=class extends Lg{constructor(...e){super(...e),(0,s.Z)(this,"adsMetadata",void 0),(0,s.Z)(this,"cashbackItem",void 0),(0,s.Z)(this,"secondaryCashbackOffers",[]),(0,s.Z)(this,"spbCheckoutMatchedOffers",[]),(0,s.Z)(this,"spbOffersCount",0),(0,s.Z)(this,"variationToShow",pe.b.variation7),(0,s.Z)(this,"isExactMatchPdp",!1),(0,s.Z)(this,"isPdp",!1),(0,s.Z)(this,"isHomePage",!1),(0,s.Z)(this,"shouldDismiss",!1),(0,s.Z)(this,"notificationWrapper",void 0)}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_SPB_CASHBACK_LANDING,u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK,u.sR.AUTO_SHOW_SPB_CHECK_OUT_PAGE_NOTIFICATION]}PostProcessingNotification(e,n){const o=document.querySelector("#footerDiv #snooze"),r=document.querySelector("#footerDiv #notshow"),a=document.querySelector("#divContentWrapper"),s=document.querySelectorAll("#footerDiv #doNotShowOverlay > fluent-menu-item"),l=document.querySelector("#btnFlyoutClose");this.shouldDismiss&&this.notificationWrapper&&this.setNotificationTimeout(this.notificationWrapper),o&&o.addEventListener("click",(e=>{this.telemetryHandler.LogButtonClickICSpecificTelemetry(i.$S.ICGrocerySnoozeButton,void 0,"Snooze button clicked on SPB notification",this.renderedPageType)})),r&&r.addEventListener("click",(e=>{this.telemetryHandler.LogButtonClickICSpecificTelemetry(i.$S.ICGroceryDoNotShowButton,void 0,"Do not show button clicked on SPB notification",this.renderedPageType)})),l&&l.addEventListener("click",(e=>{this.telemetryHandler.LogButtonClickICSpecificTelemetry(i.$S.ICGroceryDismissButton,void 0,"Dismiss button clicked on grocery cashback notification",this.renderedPageType)})),s&&s.forEach((e=>{e.addEventListener("click",(t=>{this.telemetryHandler.LogButtonClickICSpecificTelemetry(i.$S.ICGroceryDoNotShowButtonOption,void 0,JSON.stringify({dontShowOption:e.innerHTML}),this.renderedPageType)}))})),a&&document.addEventListener("click",(e=>{const t=e.target;a?.contains(t)||this.pageHandlerModule.DismissPopup()}));const c=this.flyoutData.dataStoreModule.CashBackData,d=this.flyoutData.dataStoreModule.UserInfo;if(c?.isLinkYourMSAWorkflow||d?.isAADLinkedAccountValid||d?.isAADSignedIn){const e={userInfo:d,isLinkYourMSAWorkflow:c?.isLinkYourMSAWorkflow,isSignInSupportedDomainCashBack:c?.isSignInSupportedDomainCashBack},n=new t.Z(i.xu.AadUserLinking);n.Metadata=JSON.stringify(e),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"AAD linking shown for SPB",n)}}async RenderNotification(){const t=this.flyoutData.dataStoreModule.CashBackData;this.spbComponentUtils.updateHomePageOffers();let n=null,o=!1;if(this.cashbackItem){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles()+" "+this.assets.getSpbStyles(),void 0,this.assets.getDarkModeStyles()+" "+this.assets.getSpbStylesDarkMode()),n=this.CreateSpbNotificationDiv(this.cashbackItem);const e=Boolean(this.isExactMatchPdp&&this.cashbackItem.isActivated);o=!e&&!this.isHomePage&&!this.isPdp,this.telemetryHandler.LogICSpecificTelemetry(this.isPdp?e?i.xu.ICPdpNotificationSPBActivated:i.xu.ICPdpNotificationSPB:this.isHomePage?i.xu.ICHomeNotificationSPB:i.xu.ICSearchNotificationSPB,JSON.stringify({OffersCount:this.spbOffersCount,variation:this.variationToShow,userInfo:this.flyoutData.dataStoreModule.UserInfo}),this.renderedPageType,{offerId:this.cashbackItem.id,offerItem:this.cashbackItem.adsOffer,adsMetadata:this.adsMetadata})}else if(t&&t.isSpbActivated){const e=new tg;this.utilities.applyStyles(this.flyoutData.common.shopping,e.getStyles(),Dg.E.ICNotification),this.renderedPageType=i.e4.SPBActivatedNotification,n=this.spbActivatedNotificationUtils.createSpbActivatedNotification(t),this.telemetryHandler.LogICSpecificTelemetry(i.xu.SPBActivatedNotificationShown,"SPB activation rendered",this.renderedPageType,{offerId:t.personalizedCashback.offerId,offerItem:t.personalizedCashback.adsCashback[0]})}if(n){const t=this.utilities.createNotificationModule(n,this.GetNotificationName(),this);return o&&(e.R.isExperimentActive(f.H.spbDismissTimeout)||e.R.isExperimentActive(f.H.spbAutoDismissTreatment))&&(this.shouldDismiss=!0,this.notificationWrapper=n),Promise.resolve(t)}return this.telemetryHandler.LogIcError("Error in render spb notification. Notification not shown",void 0,this.renderedPageType),Promise.resolve(null)}async ShouldRenderNotification(){if(e.R.isExperimentActive(f.H.cashbackConsolidationExp))return Promise.resolve(!1);const t=this.flyoutData.dataStoreModule.CashBackData;if(this.IsItemizedCashBackNotification(t)){let e=await this.storageHandler.getStorageString(Ce.Q.ICNotificationType);if(this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK&&t?.isSpbActivated)return Promise.resolve(!0);const{SPBItemizedCashbackData:n}=this.flyoutData.dataStoreModule;if(!n)return this.telemetryHandler.LogIcError("Error in should render spb notification. No SPBItemizedCashbackData",void 0,this.renderedPageType,{notificationType:e},i.xu.OnErrorInvoked),Promise.resolve(!1);this.visibilityFeedbackUrlBase=n?.AdsMetadata?.visibilityFeedbackUrl??"",this.variationToShow=pe.b.variation1;const o={};switch(n.SpbPDPData&&(n.SpbPDPData.RelatedOffers.length>0||n.SpbPDPData.ItemizedCashbackExactMatch)&&(e=ke.c.PdpSPB),this.adsMetadata=n?.AdsMetadata,e){case ke.c.SpbHomePage:n.homePageSpbOffers?.notificationOffer?(this.isHomePage=!0,this.renderedPageType=i.e4.HomePageNotification,this.cashbackItem=n.homePageSpbOffers.notificationOffer,this.spbOffersCount=n.homePageSpbOffers.homePageSpbOffers.length,this.variationToShow=pe.b.variation3,this.visibilityFeedbackUrlBase=n.homePageSpbOffers.notificationOffer.visibilityFeedbackUrlBase):o.isSpbHomePageNotificationItemPresent=!1;break;case ke.c.PdpSPB:{this.isPdp=!0,this.visibilityFeedbackUrlBase=n.SpbPDPData?.AdsMetadata?.visibilityFeedbackUrl||"";const e=n.SpbPDPData?.RelatedOffers,t=n.SpbPDPData?.ItemizedCashbackExactMatch;t?(this.cashbackItem=t,this.renderedPageType=i.e4.SPBpdpExactMatchNotification,this.spbOffersCount=1,this.isExactMatchPdp=!0,this.variationToShow=pe.b.pdpExactMatch):e&&e.length>0&&(this.cashbackItem=e[0],this.renderedPageType=i.e4.SPBpdpNotification,this.spbOffersCount=e.length,n?.pdpNotificationVariation&&(this.variationToShow=n.pdpNotificationVariation));break}case ke.c.SpbCartPageNotification:this.cashbackItem=n?.matchedCartSpbOffers&&n?.matchedCartSpbOffers.length>0?n?.matchedCartSpbOffers[0]:void 0,this.renderedPageType=i.e4.SPBCheckoutPageNotification,this.spbOffersCount=n?.matchedCartSpbOffers?.length??0,this.spbCheckoutMatchedOffers=n?.matchedCartSpbOffers??[],this.spbCheckoutMatchedOffers&&this.spbCheckoutMatchedOffers.length>0&&(this.variationToShow=pe.b.spbCartPageAutoActivationVariation);break;default:{const e=cg.IsSpbInstantATCExpEnabled(this.flyoutData),t=e||cg.IsSpbAutoActivateExpEnabled();t?this.variationToShow=pe.b.autoActivationVariation:n?.searchNotificationVariation&&(this.variationToShow=n.searchNotificationVariation);const r=n?.ItemizedCashback||[];if(r.length>0){const n=this.getOfferToShow(r);if(void 0===n)return Promise.resolve(!1);this.cashbackItem=n,r.length>1&&(this.secondaryCashbackOffers=r.slice(1,2)),this.renderedPageType=e?i.e4.SPBSearchInstantATCNotification:t?i.e4.SPBSearchAutoActivateNotification:i.e4.SPBSearchNotification,this.spbOffersCount=r.length}else o.isCashbackItemsFromSearchAndCategory=!1}}t?.isSignInSupportedDomainCashBack&&t?.isLinkYourMSAWorkflow&&t?.isLinkingEnabledForSPB&&(this.variationToShow=pe.b.spbAADLinkingNotification);const r=void 0!==this.cashbackItem;return r||this.telemetryHandler.LogIcError("Error in should render spb notification. Cannot show",void 0,this.renderedPageType,function(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Bg(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Bg(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}({notificationType:e,currentPageInfo:await this.storageHandler.getStorageString(Ce.Q.ICCurrentPageInfo)},o),i.xu.OnErrorInvoked),Promise.resolve(r)}return Promise.resolve(!1)}getOfferToShow(e){for(let t of e){if(void 0===t.shouldAutoshow||null===t.shouldAutoshow)return t;if((0,x.Nx)(t.shouldAutoshow))return t}}GetNotificationName(){return r.sM.ITEMIZED_CASHBACK_NOTIFICATION}IsItemizedCashBackNotification(e){return this.flyoutData.common.openedWith===r.Te.Auto&&(this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_SPB_CASHBACK_LANDING||this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_SPB_CHECK_OUT_PAGE_NOTIFICATION||this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK&&e&&e?.isSpbActivated)}CreateSpbNotificationDiv(e){return this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getSmallerNotificationCssStyles(),Dg.E.ICNotification),this.pickVariation(e,this.variationToShow)}pickVariation(e,t){const n=!this.isExactMatchPdp,o=this.isPdp?i.xu.ICPdpNotificationSPBHover:this.isHomePage?i.xu.ICHomeNotificationSPBHover:i.xu.ICSearchNotificationSPBHover;switch(t){case pe.b.variation1:return this.createElementForOfferV1(e,this.renderedPageType,o,n);case pe.b.variation2:return this.createElementForOfferV2(e,this.renderedPageType,o,n);case pe.b.variation3:return this.createElementForOfferV3And4(e,this.renderedPageType,o,!0);case pe.b.variation4:return this.createElementForOfferV3And4(e,this.renderedPageType,o,!1);case pe.b.variation5:return this.createElementForOfferV5(e,this.renderedPageType,o,n);case pe.b.variation6:return this.createElementForOfferV6(e,this.renderedPageType,o,n);case pe.b.variation7:return this.createElementForOfferV7(e,this.renderedPageType,o,n);case pe.b.variation8:return this.createElementForOfferV8(e,this.renderedPageType,o,n);case pe.b.variation9:return this.createElementForOfferV9(e,this.renderedPageType,o,n);case pe.b.autoActivationVariation:return this.createElementForOfferV2AutoActivate(e,this.renderedPageType,o,n);case pe.b.pdpExactMatch:const{SPBItemizedCashbackData:t}=this.flyoutData.dataStoreModule;return this.createElementForOfferSpbPdpExactMatch(e,this.renderedPageType,o,n,t?.SpbPDPData?.pdpData?.price??"");case pe.b.spbCartPageAutoActivationVariation:return this.telemetryHandler.LogICSpecificTelemetry(i.xu.SPBCheckoutNotificationShown,"SPB Cart Auto Activation rendered",this.renderedPageType,{matchedOffers:this.spbCheckoutMatchedOffers}),this.createElementForSpbCheckOutNotification(this.spbCheckoutMatchedOffers,this.renderedPageType,o,n,"");case pe.b.spbAADLinkingNotification:return this.createMsaLinkNotification(e,this.renderedPageType,o,n);default:return this.createElementForOfferV7(e,this.renderedPageType,o,n)}}createElementForOfferV9(e,t,i,n){const o=this.createElementForOfferV1(e,t,i,n,!0),r=o.querySelector(".icTextContainer"),a=r?.querySelector(".icCashbackContainer");if(r&&a){const t=new Intl.NumberFormat("en-US",{style:"currency",currency:"USD"}).format(e.adsOffer?.promotionInformation?.rebateValue),i=(0,Y.Ux)("span",void 0,t),n=(0,Y.Ux)("p");n.className="icCashbackText",(0,T.B7)(n,this.flyoutData.strings.gcGetCashBack,i),n.style.fontSize="24px",n.style.padding="5px 0",r.replaceChild(n,a)}const s=o.querySelector("#gcActivateBtn");return s&&(s.textContent=this.flyoutData.strings.gcOkButtonText),o}createElementForOfferV7(e,t,i,n){const o=this.createElementForOfferV1(e,t,i,n),r=o.querySelector(".icTextContainer"),a=r?.querySelector(".icCashbackContainer");if(r&&a){const t=new Intl.NumberFormat("en-US",{style:"currency",currency:"USD"}).format(e.adsOffer?.promotionInformation?.rebateValue),i=(0,Y.Ux)("span",void 0,t),n=(0,Y.Ux)("p");n.className="icCashbackText",(0,T.B7)(n,this.flyoutData.strings.gcGetCashBack,i),n.style.fontSize="24px",n.style.padding="5px 0",r.replaceChild(n,a)}const s=o.querySelector("#gcActivateBtn");return s&&(s.textContent=this.flyoutData.strings.gcOkButtonText),o}createMsaLinkNotification(e,t,i,n){const o=this.createElementForOfferV7(e,t,i,n),r=o.querySelector("#gcActivateBtn");if(r){const e=r.cloneNode(!0);r.replaceWith(e),e.textContent=this.flyoutData.strings.pcbLinkMsaActivateButton;const t=new ag(this.stateManagement,this.flyoutData,this.uxUtils,this.commonAssets,this.logModule,this.GetModuleName());e.addEventListener("click",(i=>{t.handleLinkYourMSAClick(e,"Spb Linking")}))}const a=ag.createPrivacyBlock("hypertext",this.pageHandlerModule,this.utilities,this.flyoutData),s=(0,Y.Ux)("div",{id:"divPrivacySpbBlock"});return s.appendChild(a),o.appendChild(s),o}createElementForOfferV2AutoActivate(e,t,i,n){const{rootDiv:o,content:r}=this.spbComponentUtils.createElementForOfferAutoActivateCard(e,t,i,this.isPdp,n,!0,this.visibilityFeedbackUrlBase);if(this.spbOffersCount>1){const e=this.CreateSeeMoreOffersButton(!1);r.appendChild(e)}return cg.IsSpbAutoActivateExpEnabled()&&this.spbComponentUtils.makeBackgroundActivation(e,t),o}createElementForSpbCheckOutNotification(e,t,i,n,o){const{rootDiv:r}=this.spbComponentUtils.createElementForSpbCheckOutNotification(e,t,i,this.isPdp,n,!0,this.visibilityFeedbackUrlBase,o);return r}createElementForOfferSpbPdpExactMatch(e,t,i,n,o){const{rootDiv:r,content:a}=this.spbComponentUtils.createElementForOfferSpbPdpExactMatch(e,t,i,this.isPdp,n,!0,this.visibilityFeedbackUrlBase,o);if(this.spbOffersCount>1){const e=this.CreateSeeMoreOffersButton(!1);a.appendChild(e)}return cg.IsSpbAutoActivateExpEnabled()&&this.spbComponentUtils.makeBackgroundActivation(e,t),r}createElementForOfferV8(e,t,i,n){const o=this.createElementForOfferV1(e,t,i,n),r=o.querySelector("#gcActivateBtn");if(r){const e=this.flyoutData.common.domain.split("."),t=e.length>0?e[0]:"",i=t.charAt(0).toUpperCase()+t.slice(1),n=this.flyoutData.strings.gcGetDealOnRetailer.replace("$1",i);r.textContent=n}return o}createElementForOfferV6(e,t,i,n){if(1===this.spbOffersCount)return this.createElementForOfferV2(e,this.renderedPageType,i,n);this.utilities.applyStyles(this.flyoutData.common.shopping,"msft-edge-shopping::part(header) {\n margin-top: 0px !important;\n margin-bottom: 0px !important;\n }");const{rootDiv:o,content:r}=this.spbComponentUtils.createElementForOfferV6Card(e,t,i,this.isPdp,n,!0,this.visibilityFeedbackUrlBase,this.secondaryCashbackOffers);if(this.spbOffersCount>1){this.secondaryCashbackOffers[0].visibilityFeedbackUrlBase=this.visibilityFeedbackUrlBase;const e=this.spbComponentUtils.createElementForSecondaryOffer(this.secondaryCashbackOffers[0],t,i,n,this.isPdp);r.appendChild(e)}if(this.spbOffersCount>2){const e=this.CreateSeeMoreOffersButton(!1);r.appendChild(e)}return o}createElementForOfferV5(e,t,i,n){this.utilities.applyStyles(this.flyoutData.common.shopping,this.spbComponentUtils.assetsItemizedCashback.getStyles()+this.spbComponentUtils.assetsItemizedCashback.getVariant5Styles(),void 0,this.spbComponentUtils.assetsItemizedCashback.getDarkModeStyles());const o=this.spbComponentUtils.GetPriceData(e),r=o.discount.amount>this.spbComponentUtils.showDiscountMin,{rootDiv:a,content:s}=this.spbComponentUtils.commonSetUp(e,t,i,this.visibilityFeedbackUrlBase,!0),l=(0,Y.Ux)("DIV");if(l.className="icTextContainer",r){const e=Sp(this.flyoutData,`${o.discount.toDisplay} ${this.flyoutData.strings.gcOff}`);e.className="icPercentOff",s.style.position="relative",s.appendChild(e)}const c=(0,Y.Ux)("div");c.className="icCashbackContainer";const d=(0,Y.Ux)("p",void 0,o.finalPrice.toDisplay);d.className="icFinalPrice";const u=(0,Y.Ux)("p",void 0,o.listPrice.toDisplay);u.className="icListPrice";const h=(0,Y.Ux)("p",void 0,`(${o.discount.toDisplay} ${this.flyoutData.strings.gcOff})`);h.className="icPercentOffText",c.appendChild(d),c.appendChild(u),c.appendChild(h);const p=Mp(this.isDarkMode,e.adsOffer.name);p.className="icDescriptionText";const g=this.spbComponentUtils.CreateAdsIconWithText(),f=Op(this.flyoutData,o.cashbackValue.toDisplay,this.isDarkMode,!0);f.className="icWithCashback",l.appendChild(g),l.appendChild(p),l.appendChild(c),l.appendChild(f);const m=this.spbComponentUtils.createCashImageInWrapper(!0,e.imageUrl);m.title=e.adsOffer.name,m.style.flex="1";const v=(0,Y.Ux)("DIV");v.className=this.spbComponentUtils.textAndImageContainerClassName,v.appendChild(m);const y=(0,Y.Ux)("DIV");y.className="divider",v.appendChild(y),v.appendChild(l);const C=this.spbComponentUtils.CreateActionButton(o.cashbackValue.toDisplay,e,this.isPdp,n,!0,t);if(s.appendChild(v),s.appendChild(C),this.spbOffersCount>1){const e=this.CreateSeeMoreOffersButton(!1);s.appendChild(e)}return a}createElementForOfferV3And4(e,t,i,n){this.utilities.applyStyles(this.flyoutData.common.shopping,this.spbComponentUtils.assetsItemizedCashback.getVariant3Styles(),void 0,this.spbComponentUtils.assetsItemizedCashback.getDarkModeStyles());const{rootDiv:o,content:r}=this.spbComponentUtils.commonSetUp(e,t,i,this.visibilityFeedbackUrlBase,!0),a=(0,Y.Ux)("DIV");let s;a.className="icFoundCashbackText",a.style.display="flex",a.style.flexWrap="wrap";let l="";const c=(0,Ie.j_)(this.flyoutData);if(c)s=this.utilities.createCommissionArrow(`$${c}`,!1,zu.h.Medium),l=this.flyoutData.strings.gcSpbHomePageText1;else{const e=(0,Ie.q6)(this.flyoutData);e?(s=(0,Y.Ux)("span",void 0,`${e}`),l=this.flyoutData.strings.gcSpbHomePageText2):l=this.flyoutData.strings.gcSpbHomePageTextDefault}s?(0,T.B7)(a,l,s):a.textContent=l,r.appendChild(a);const d=this.CreateSeeMoreOffersButton(!0,this.flyoutData.strings.gcSeeCashbackDeals);return r.appendChild(d),o}createElementForOfferV2(e,t,i,n){const{rootDiv:o,content:r}=this.spbComponentUtils.createElementForOfferV2Card(e,t,i,this.isPdp,n,!0,this.visibilityFeedbackUrlBase,this.isExactMatchPdp);if(this.spbOffersCount>1){const e=this.CreateSeeMoreOffersButton(!1);r.appendChild(e)}return o}createElementForOfferV1(e,t,i,n,o){this.utilities.applyStyles(this.flyoutData.common.shopping,this.spbComponentUtils.assetsItemizedCashback.getStyles(),void 0,this.spbComponentUtils.assetsItemizedCashback.getDarkModeStyles());const r=this.spbComponentUtils.GetPriceData(e),a=r.discount.amount>this.spbComponentUtils.showDiscountMin,{rootDiv:s,content:l}=this.spbComponentUtils.commonSetUp(e,t,i,this.visibilityFeedbackUrlBase,!0,o?this.secondaryCashbackOffers:void 0),c=(0,Y.Ux)("DIV");if(c.className="icTextContainer",a){const e=Sp(this.flyoutData,`${r.discount.toDisplay} ${this.flyoutData.strings.gcOff}`);e.className="icPercentOff",l.style.position="relative",l.appendChild(e)}const d=(0,Y.Ux)("div");d.className="icCashbackContainer";const u=(0,Y.Ux)("p",void 0,r.cashbackValue.toDisplay);u.className="icCashbackValueText";const h=(0,Y.Ux)("p",void 0,(0,T.fm)(this.flyoutData.strings.cbFeatureName));h.className="icCashbackText",d.appendChild(u),d.appendChild(h);const p=Mp(this.isDarkMode,e.adsOffer.name);p.className="icDescriptionText";const g=this.spbComponentUtils.CreateAdsIconWithText();c.appendChild(g),c.appendChild(d),c.appendChild(p);const f=this.spbComponentUtils.createCashImageInWrapper(!0,e.imageUrl);f.title=e.adsOffer.name,f.style.flex="1";const m=(0,Y.Ux)("DIV");m.className=this.spbComponentUtils.textAndImageContainerClassName,m.appendChild(f);const v=(0,Y.Ux)("DIV");v.className="divider",m.appendChild(v),m.appendChild(c);const y=this.spbComponentUtils.CreateActionButton(r.cashbackValue.toDisplay,e,this.isPdp,n,!0,t);if(l.appendChild(m),l.appendChild(y),o){if(this.spbOffersCount>1){this.secondaryCashbackOffers[0].visibilityFeedbackUrlBase=this.visibilityFeedbackUrlBase;const e=this.spbComponentUtils.createElementForSecondaryOffer(this.secondaryCashbackOffers[0],t,i,n,this.isPdp);l.appendChild(e)}if(this.spbOffersCount>2){const e=this.CreateSeeMoreOffersButton(!1);l.appendChild(e)}}else if(this.spbOffersCount>1){const e=this.CreateSeeMoreOffersButton(!1);l.appendChild(e)}return s}CreateSeeMoreOffersButton(e,t){const n=e?(0,Y.Ci)():(0,Y.s1)();return n.className="icSeeMoreOffersButton",e||n.classList.add("asLink"),n.textContent=t||this.flyoutData.strings.gcSeeOtherDeals,n.addEventListener("click",(e=>{e.stopPropagation(),this.isHomePage&&this.telemetryHandler.LogICSpecificTelemetry(i.xu.ICHomeNotificationSPBClick,"Home page micro notification clicked for spb",this.renderedPageType),this.telemetryHandler.LogButtonClickICSpecificTelemetry(i.$S.SPBSeeMoreDealsButton,void 0,"See more deals clicked on spb notification",this.renderedPageType),this.pageHandlerModule.OpenPane(this.flyoutData.common.popupOrigination)})),n}setNotificationTimeout(e){let t=setTimeout((()=>{this.pageHandlerModule.DismissPopup()}),5e3);e.addEventListener("mouseenter",(()=>{clearTimeout(t)})),e.addEventListener("mouseleave",(()=>{t=setTimeout((()=>{this.pageHandlerModule.DismissPopup()}),5e3)}))}};let Ug=function(e){return e.HOVER_BUTTON_SHOW_FLYOUT="HOVER_BUTTON_SHOW_FLYOUT",e.OPEN_PANE_FROM_FLYOUT="OPEN_PANE_FROM_FLYOUT",e.OPEN_PANE_FROM_SIDEBAR="OPEN_PANE_FROM_SIDEBAR",e.SCROLL_PAGE="SCROLL_PAGE",e.SWITCH_TO_TAB1="SWITCH_TO_TAB1",e.SWITCH_TO_TAB2="SWITCH_TO_TAB2",e.COUPONS="COUPONS",e.COUPONS_SEE_MORE="COUPONS_SEE_MORE",e.PRICE_HISTORY="PRICE_HISTORY",e.PRICE_HISTORY_SET_TIMERANGE="PRICE_HISTORY_SET_TIMERANGE",e.PRICE_COMPARISON="PRICE_COMPARISON",e.PRICE_COMPARISON_SEE_MORE="PRICE_COMPARISON_SEE_MORE",e.SIMILAR_PRODUCTS="SIMILAR_PRODUCTS",e.ACTIVITY="ACTIVITY",e.ACTIVITY_SEE_MORE="ACTIVITY_SEE_MORE",e.TRENDING_PRODUCTS="TRENDING_PRODUCTS",e.TRENDING_PRODUCTS_SET_CATEGORY="TRENDING_PRODUCTS_SET_CATEGORY",e.TRENDING_PRODUCTS_SET_RETAILER="TRENDING_PRODUCTS_SET_RETAILER",e}({}),Hg=function(e){return e.SHOW=".Show",e.ACTION=".Action",e}({}),$g=function(e){return e.MMZ=".MMZ",e.GWD=".GWD",e.SMZDM=".SMZDM",e}({});var Zg=o(84045),Vg=o(37787),Gg=o(33048),jg=o.n(Gg),zg=function(e){function t(e,n,l,c,h){for(var p,g,f,m,b,x=0,T=0,w=0,O=0,P=0,_=0,R=f=p=0,L=0,B=0,F=0,U=0,H=l.length,$=H-1,Z="",V="",G="",j="";L<H;){if(g=l.charCodeAt(L),L===$&&0!==T+O+w+x&&(0!==T&&(g=47===T?10:47),O=w=x=0,H++,$++),0===T+O+w+x){if(L===$&&(0<B&&(Z=Z.replace(u,"")),0<Z.trim().length)){switch(g){case 32:case 9:case 59:case 13:case 10:break;default:Z+=l.charAt(L)}g=59}switch(g){case 123:for(p=(Z=Z.trim()).charCodeAt(0),f=1,U=++L;L<H;){switch(g=l.charCodeAt(L)){case 123:f++;break;case 125:f--;break;case 47:switch(g=l.charCodeAt(L+1)){case 42:case 47:e:{for(R=L+1;R<$;++R)switch(l.charCodeAt(R)){case 47:if(42===g&&42===l.charCodeAt(R-1)&&L+2!==R){L=R+1;break e}break;case 10:if(47===g){L=R+1;break e}}L=R}}break;case 91:g++;case 40:g++;case 34:case 39:for(;L++<$&&l.charCodeAt(L)!==g;);}if(0===f)break;L++}if(f=l.substring(U,L),0===p&&(p=(Z=Z.replace(d,"").trim()).charCodeAt(0)),64===p){switch(0<B&&(Z=Z.replace(u,"")),g=Z.charCodeAt(1)){case 100:case 109:case 115:case 45:B=n;break;default:B=D}if(U=(f=t(n,B,f,g,h+1)).length,0<N&&(b=s(3,f,B=i(D,Z,F),n,E,A,U,g,h,c),Z=B.join(""),void 0!==b&&0===(U=(f=b.trim()).length)&&(g=0,f="")),0<U)switch(g){case 115:Z=Z.replace(S,a);case 100:case 109:case 45:f=Z+"{"+f+"}";break;case 107:f=(Z=Z.replace(v,"$1 $2"))+"{"+f+"}",f=1===I||2===I&&r("@"+f,3)?"@-webkit-"+f+"@"+f:"@"+f;break;default:f=Z+f,112===c&&(V+=f,f="")}else f=""}else f=t(n,i(n,Z,F),f,c,h+1);G+=f,f=F=B=R=p=0,Z="",g=l.charCodeAt(++L);break;case 125:case 59:if(1<(U=(Z=(0<B?Z.replace(u,""):Z).trim()).length))switch(0===R&&(p=Z.charCodeAt(0),45===p||96<p&&123>p)&&(U=(Z=Z.replace(" ",":")).length),0<N&&void 0!==(b=s(1,Z,n,e,E,A,V.length,c,h,c))&&0===(U=(Z=b.trim()).length)&&(Z="\0\0"),p=Z.charCodeAt(0),g=Z.charCodeAt(1),p){case 0:break;case 64:if(105===g||99===g){j+=Z+l.charAt(L);break}default:58!==Z.charCodeAt(U-1)&&(V+=o(Z,p,g,Z.charCodeAt(2)))}F=B=R=p=0,Z="",g=l.charCodeAt(++L)}}switch(g){case 13:case 10:47===T?T=0:0===1+p&&107!==c&&0<Z.length&&(B=1,Z+="\0"),0<N*M&&s(0,Z,n,e,E,A,V.length,c,h,c),A=1,E++;break;case 59:case 125:if(0===T+O+w+x){A++;break}default:switch(A++,m=l.charAt(L),g){case 9:case 32:if(0===O+x+T)switch(P){case 44:case 58:case 9:case 32:m="";break;default:32!==g&&(m=" ")}break;case 0:m="\\0";break;case 12:m="\\f";break;case 11:m="\\v";break;case 38:0===O+T+x&&(B=F=1,m="\f"+m);break;case 108:if(0===O+T+x+k&&0<R)switch(L-R){case 2:112===P&&58===l.charCodeAt(L-3)&&(k=P);case 8:111===_&&(k=_)}break;case 58:0===O+T+x&&(R=L);break;case 44:0===T+w+O+x&&(B=1,m+="\r");break;case 34:case 39:0===T&&(O=O===g?0:0===O?g:O);break;case 91:0===O+T+w&&x++;break;case 93:0===O+T+w&&x--;break;case 41:0===O+T+x&&w--;break;case 40:0===O+T+x&&(0===p&&(2*P+3*_==533||(p=1)),w++);break;case 64:0===T+w+O+x+R+f&&(f=1);break;case 42:case 47:if(!(0<O+x+w))switch(T){case 0:switch(2*g+3*l.charCodeAt(L+1)){case 235:T=47;break;case 220:U=L,T=42}break;case 42:47===g&&42===P&&U+2!==L&&(33===l.charCodeAt(U+2)&&(V+=l.substring(U,L+1)),m="",T=0)}}0===T&&(Z+=m)}_=P,P=g,L++}if(0<(U=V.length)){if(B=n,0<N&&void 0!==(b=s(2,V,B,e,E,A,U,c,h,c))&&0===(V=b).length)return j+V+G;if(V=B.join(",")+"{"+V+"}",0!=I*k){switch(2!==I||r(V,2)||(k=0),k){case 111:V=V.replace(C,":-moz-$1")+V;break;case 112:V=V.replace(y,"::-webkit-input-$1")+V.replace(y,"::-moz-$1")+V.replace(y,":-ms-input-$1")+V}k=0}}return j+V+G}function i(e,t,i){var o=t.trim().split(f);t=o;var r=o.length,a=e.length;switch(a){case 0:case 1:var s=0;for(e=0===a?"":e[0]+" ";s<r;++s)t[s]=n(e,t[s],i).trim();break;default:var l=s=0;for(t=[];s<r;++s)for(var c=0;c<a;++c)t[l++]=n(e[c]+" ",o[s],i).trim()}return t}function n(e,t,i){var n=t.charCodeAt(0);switch(33>n&&(n=(t=t.trim()).charCodeAt(0)),n){case 38:return t.replace(m,"$1"+e.trim());case 58:return e.trim()+t.replace(m,"$1"+e.trim());default:if(0<1*i&&0<t.indexOf("\f"))return t.replace(m,(58===e.charCodeAt(0)?"":"$1")+e.trim())}return e+t}function o(e,t,i,n){var a=e+";",s=2*t+3*i+4*n;if(944===s){e=a.indexOf(":",9)+1;var l=a.substring(e,a.length-1).trim();return l=a.substring(0,e).trim()+l+";",1===I||2===I&&r(l,1)?"-webkit-"+l+l:l}if(0===I||2===I&&!r(a,1))return a;switch(s){case 1015:return 97===a.charCodeAt(10)?"-webkit-"+a+a:a;case 951:return 116===a.charCodeAt(3)?"-webkit-"+a+a:a;case 963:return 110===a.charCodeAt(5)?"-webkit-"+a+a:a;case 1009:if(100!==a.charCodeAt(4))break;case 969:case 942:return"-webkit-"+a+a;case 978:return"-webkit-"+a+"-moz-"+a+a;case 1019:case 983:return"-webkit-"+a+"-moz-"+a+"-ms-"+a+a;case 883:if(45===a.charCodeAt(8))return"-webkit-"+a+a;if(0<a.indexOf("image-set(",11))return a.replace(P,"$1-webkit-$2")+a;break;case 932:if(45===a.charCodeAt(4))switch(a.charCodeAt(5)){case 103:return"-webkit-box-"+a.replace("-grow","")+"-webkit-"+a+"-ms-"+a.replace("grow","positive")+a;case 115:return"-webkit-"+a+"-ms-"+a.replace("shrink","negative")+a;case 98:return"-webkit-"+a+"-ms-"+a.replace("basis","preferred-size")+a}return"-webkit-"+a+"-ms-"+a+a;case 964:return"-webkit-"+a+"-ms-flex-"+a+a;case 1023:if(99!==a.charCodeAt(8))break;return"-webkit-box-pack"+(l=a.substring(a.indexOf(":",15)).replace("flex-","").replace("space-between","justify"))+"-webkit-"+a+"-ms-flex-pack"+l+a;case 1005:return p.test(a)?a.replace(h,":-webkit-")+a.replace(h,":-moz-")+a:a;case 1e3:switch(t=(l=a.substring(13).trim()).indexOf("-")+1,l.charCodeAt(0)+l.charCodeAt(t)){case 226:l=a.replace(b,"tb");break;case 232:l=a.replace(b,"tb-rl");break;case 220:l=a.replace(b,"lr");break;default:return a}return"-webkit-"+a+"-ms-"+l+a;case 1017:if(-1===a.indexOf("sticky",9))break;case 975:switch(t=(a=e).length-10,s=(l=(33===a.charCodeAt(t)?a.substring(0,t):a).substring(e.indexOf(":",7)+1).trim()).charCodeAt(0)+(0|l.charCodeAt(7))){case 203:if(111>l.charCodeAt(8))break;case 115:a=a.replace(l,"-webkit-"+l)+";"+a;break;case 207:case 102:a=a.replace(l,"-webkit-"+(102<s?"inline-":"")+"box")+";"+a.replace(l,"-webkit-"+l)+";"+a.replace(l,"-ms-"+l+"box")+";"+a}return a+";";case 938:if(45===a.charCodeAt(5))switch(a.charCodeAt(6)){case 105:return l=a.replace("-items",""),"-webkit-"+a+"-webkit-box-"+l+"-ms-flex-"+l+a;case 115:return"-webkit-"+a+"-ms-flex-item-"+a.replace(T,"")+a;default:return"-webkit-"+a+"-ms-flex-line-pack"+a.replace("align-content","").replace(T,"")+a}break;case 973:case 989:if(45!==a.charCodeAt(3)||122===a.charCodeAt(4))break;case 931:case 953:if(!0===O.test(e))return 115===(l=e.substring(e.indexOf(":")+1)).charCodeAt(0)?o(e.replace("stretch","fill-available"),t,i,n).replace(":fill-available",":stretch"):a.replace(l,"-webkit-"+l)+a.replace(l,"-moz-"+l.replace("fill-",""))+a;break;case 962:if(a="-webkit-"+a+(102===a.charCodeAt(5)?"-ms-"+a:"")+a,211===i+n&&105===a.charCodeAt(13)&&0<a.indexOf("transform",10))return a.substring(0,a.indexOf(";",27)+1).replace(g,"$1-webkit-$2")+a}return a}function r(e,t){var i=e.indexOf(1===t?":":"{"),n=e.substring(0,3!==t?i:10);return i=e.substring(i+1,e.length-1),R(2!==t?n:n.replace(w,"$1"),i,t)}function a(e,t){var i=o(t,t.charCodeAt(0),t.charCodeAt(1),t.charCodeAt(2));return i!==t+";"?i.replace(x," or ($1)").substring(4):"("+t+")"}function s(e,t,i,n,o,r,a,s,l,d){for(var u,h=0,p=t;h<N;++h)switch(u=_[h].call(c,e,p,i,n,o,r,a,s,l,d)){case void 0:case!1:case!0:case null:break;default:p=u}if(p!==t)return p}function l(e){return void 0!==(e=e.prefix)&&(R=null,e?"function"!=typeof e?I=1:(I=2,R=e):I=0),l}function c(e,i){var n=e;if(33>n.charCodeAt(0)&&(n=n.trim()),n=[n],0<N){var o=s(-1,i,n,n,E,A,0,0,0,0);void 0!==o&&"string"==typeof o&&(i=o)}var r=t(D,n,i,0,0);return 0<N&&void 0!==(o=s(-2,r,n,n,E,A,r.length,0,0,0))&&(r=o),k=0,A=E=1,r}var d=/^\0+/g,u=/[\0\r\f]/g,h=/: */g,p=/zoo|gra/,g=/([,: ])(transform)/g,f=/,\r+?/g,m=/([\t\r\n ])*\f?&/g,v=/@(k\w+)\s*(\S*)\s*/,y=/::(place)/g,C=/:(read-only)/g,b=/[svh]\w+-[tblr]{2}/,S=/\(\s*(.*)\s*\)/g,x=/([\s\S]*?);/g,T=/-self|flex-/g,w=/[^]*?(:[rp][el]a[\w-]+)[^]*/,O=/stretch|:\s*\w+\-(?:conte|avail)/,P=/([^-])(image-set\()/,A=1,E=1,k=0,I=1,D=[],_=[],N=0,R=null,M=0;return c.use=function e(t){switch(t){case void 0:case null:N=_.length=0;break;default:if("function"==typeof t)_[N++]=t;else if("object"==typeof t)for(var i=0,n=t.length;i<n;++i)e(t[i]);else M=0|!!t}return e},c.set=l,void 0!==e&&l(e),c},Wg={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1};function Kg(e){var t=Object.create(null);return function(i){return void 0===t[i]&&(t[i]=e(i)),t[i]}}var qg=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|enterKeyHint|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,Yg=Kg((function(e){return qg.test(e)||111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&e.charCodeAt(2)<91})),Xg=o(20495),Jg=o.n(Xg);function Qg(){return(Qg=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e}).apply(this,arguments)}var ef=function(e,t){for(var i=[e[0]],n=0,o=t.length;n<o;n+=1)i.push(t[n],e[n+1]);return i},tf=function(e){return null!==e&&"object"==typeof e&&"[object Object]"===(e.toString?e.toString():Object.prototype.toString.call(e))&&!(0,Vg.typeOf)(e)},nf=Object.freeze([]),of=Object.freeze({});function rf(e){return"function"==typeof e}function af(e){return e.displayName||e.name||"Component"}function sf(e){return e&&"string"==typeof e.styledComponentId}var lf="undefined"!=typeof process&&void 0!==process.env&&(process.env.REACT_APP_SC_ATTR||process.env.SC_ATTR)||"data-styled",cf="undefined"!=typeof window&&"HTMLElement"in window,df=Boolean("boolean"==typeof SC_DISABLE_SPEEDY?SC_DISABLE_SPEEDY:"undefined"!=typeof process&&void 0!==process.env&&(void 0!==process.env.REACT_APP_SC_DISABLE_SPEEDY&&""!==process.env.REACT_APP_SC_DISABLE_SPEEDY?"false"!==process.env.REACT_APP_SC_DISABLE_SPEEDY&&process.env.REACT_APP_SC_DISABLE_SPEEDY:void 0!==process.env.SC_DISABLE_SPEEDY&&""!==process.env.SC_DISABLE_SPEEDY&&"false"!==process.env.SC_DISABLE_SPEEDY&&process.env.SC_DISABLE_SPEEDY));function uf(e){for(var t=arguments.length,i=new Array(t>1?t-1:0),n=1;n<t;n++)i[n-1]=arguments[n];throw new Error("An error occurred. See https://git.io/JUIaE#"+e+" for more information."+(i.length>0?" Args: "+i.join(", "):""))}var hf=function(){function e(e){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=e}var t=e.prototype;return t.indexOfGroup=function(e){for(var t=0,i=0;i<e;i++)t+=this.groupSizes[i];return t},t.insertRules=function(e,t){if(e>=this.groupSizes.length){for(var i=this.groupSizes,n=i.length,o=n;e>=o;)(o<<=1)<0&&uf(16,""+e);this.groupSizes=new Uint32Array(o),this.groupSizes.set(i),this.length=o;for(var r=n;r<o;r++)this.groupSizes[r]=0}for(var a=this.indexOfGroup(e+1),s=0,l=t.length;s<l;s++)this.tag.insertRule(a,t[s])&&(this.groupSizes[e]++,a++)},t.clearGroup=function(e){if(e<this.length){var t=this.groupSizes[e],i=this.indexOfGroup(e),n=i+t;this.groupSizes[e]=0;for(var o=i;o<n;o++)this.tag.deleteRule(i)}},t.getGroup=function(e){var t="";if(e>=this.length||0===this.groupSizes[e])return t;for(var i=this.groupSizes[e],n=this.indexOfGroup(e),o=n+i,r=n;r<o;r++)t+=this.tag.getRule(r)+"/*!sc*/\n";return t},e}(),pf=new Map,gf=new Map,ff=1,mf=function(e){if(pf.has(e))return pf.get(e);for(;gf.has(ff);)ff++;var t=ff++;return pf.set(e,t),gf.set(t,e),t},vf=function(e){return gf.get(e)},yf=function(e,t){t>=ff&&(ff=t+1),pf.set(e,t),gf.set(t,e)},Cf="style["+lf+'][data-styled-version="5.3.11"]',bf=new RegExp("^"+lf+'\\.g(\\d+)\\[id="([\\w\\d-]+)"\\].*?"([^"]*)'),Sf=function(e,t,i){for(var n,o=i.split(","),r=0,a=o.length;r<a;r++)(n=o[r])&&e.registerName(t,n)},xf=function(e,t){for(var i=(t.textContent||"").split("/*!sc*/\n"),n=[],o=0,r=i.length;o<r;o++){var a=i[o].trim();if(a){var s=a.match(bf);if(s){var l=0|parseInt(s[1],10),c=s[2];0!==l&&(yf(c,l),Sf(e,c,s[3]),e.getTag().insertRules(l,n)),n.length=0}else n.push(a)}}},Tf=function(){return o.nc},wf=function(e){var t=document.head,i=e||t,n=document.createElement("style"),o=function(e){for(var t=e.childNodes,i=t.length;i>=0;i--){var n=t[i];if(n&&1===n.nodeType&&n.hasAttribute(lf))return n}}(i),r=void 0!==o?o.nextSibling:null;n.setAttribute(lf,"active"),n.setAttribute("data-styled-version","5.3.11");var a=Tf();return a&&n.setAttribute("nonce",a),i.insertBefore(n,r),n},Of=function(){function e(e){var t=this.element=wf(e);t.appendChild(document.createTextNode("")),this.sheet=function(e){if(e.sheet)return e.sheet;for(var t=document.styleSheets,i=0,n=t.length;i<n;i++){var o=t[i];if(o.ownerNode===e)return o}uf(17)}(t),this.length=0}var t=e.prototype;return t.insertRule=function(e,t){try{return this.sheet.insertRule(t,e),this.length++,!0}catch(e){return!1}},t.deleteRule=function(e){this.sheet.deleteRule(e),this.length--},t.getRule=function(e){var t=this.sheet.cssRules[e];return void 0!==t&&"string"==typeof t.cssText?t.cssText:""},e}(),Pf=function(){function e(e){var t=this.element=wf(e);this.nodes=t.childNodes,this.length=0}var t=e.prototype;return t.insertRule=function(e,t){if(e<=this.length&&e>=0){var i=document.createTextNode(t),n=this.nodes[e];return this.element.insertBefore(i,n||null),this.length++,!0}return!1},t.deleteRule=function(e){this.element.removeChild(this.nodes[e]),this.length--},t.getRule=function(e){return e<this.length?this.nodes[e].textContent:""},e}(),Af=function(){function e(e){this.rules=[],this.length=0}var t=e.prototype;return t.insertRule=function(e,t){return e<=this.length&&(this.rules.splice(e,0,t),this.length++,!0)},t.deleteRule=function(e){this.rules.splice(e,1),this.length--},t.getRule=function(e){return e<this.length?this.rules[e]:""},e}(),Ef=cf,kf={isServer:!cf,useCSSOMInjection:!df},If=function(){function e(e,t,i){void 0===e&&(e=of),void 0===t&&(t={}),this.options=Qg({},kf,{},e),this.gs=t,this.names=new Map(i),this.server=!!e.isServer,!this.server&&cf&&Ef&&(Ef=!1,function(e){for(var t=document.querySelectorAll(Cf),i=0,n=t.length;i<n;i++){var o=t[i];o&&"active"!==o.getAttribute(lf)&&(xf(e,o),o.parentNode&&o.parentNode.removeChild(o))}}(this))}e.registerId=function(e){return mf(e)};var t=e.prototype;return t.reconstructWithOptions=function(t,i){return void 0===i&&(i=!0),new e(Qg({},this.options,{},t),this.gs,i&&this.names||void 0)},t.allocateGSInstance=function(e){return this.gs[e]=(this.gs[e]||0)+1},t.getTag=function(){return this.tag||(this.tag=(i=(t=this.options).isServer,n=t.useCSSOMInjection,o=t.target,e=i?new Af(o):n?new Of(o):new Pf(o),new hf(e)));var e,t,i,n,o},t.hasNameForId=function(e,t){return this.names.has(e)&&this.names.get(e).has(t)},t.registerName=function(e,t){if(mf(e),this.names.has(e))this.names.get(e).add(t);else{var i=new Set;i.add(t),this.names.set(e,i)}},t.insertRules=function(e,t,i){this.registerName(e,t),this.getTag().insertRules(mf(e),i)},t.clearNames=function(e){this.names.has(e)&&this.names.get(e).clear()},t.clearRules=function(e){this.getTag().clearGroup(mf(e)),this.clearNames(e)},t.clearTag=function(){this.tag=void 0},t.toString=function(){return function(e){for(var t=e.getTag(),i=t.length,n="",o=0;o<i;o++){var r=vf(o);if(void 0!==r){var a=e.names.get(r),s=t.getGroup(o);if(a&&s&&a.size){var l=lf+".g"+o+'[id="'+r+'"]',c="";void 0!==a&&a.forEach((function(e){e.length>0&&(c+=e+",")})),n+=""+s+l+'{content:"'+c+'"}/*!sc*/\n'}}}return n}(this)},e}(),Df=/(a)(d)/gi,_f=function(e){return String.fromCharCode(e+(e>25?39:97))};function Nf(e){var t,i="";for(t=Math.abs(e);t>52;t=t/52|0)i=_f(t%52)+i;return(_f(t%52)+i).replace(Df,"$1-$2")}var Rf=function(e,t){for(var i=t.length;i;)e=33*e^t.charCodeAt(--i);return e},Mf=function(e){return Rf(5381,e)};function Lf(e){for(var t=0;t<e.length;t+=1){var i=e[t];if(rf(i)&&!sf(i))return!1}return!0}var Bf=Mf("5.3.11"),Ff=function(){function e(e,t,i){this.rules=e,this.staticRulesId="",this.isStatic=(void 0===i||i.isStatic)&&Lf(e),this.componentId=t,this.baseHash=Rf(Bf,t),this.baseStyle=i,If.registerId(t)}return e.prototype.generateAndInjectStyles=function(e,t,i){var n=this.componentId,o=[];if(this.baseStyle&&o.push(this.baseStyle.generateAndInjectStyles(e,t,i)),this.isStatic&&!i.hash)if(this.staticRulesId&&t.hasNameForId(n,this.staticRulesId))o.push(this.staticRulesId);else{var r=tm(this.rules,e,t,i).join(""),a=Nf(Rf(this.baseHash,r)>>>0);if(!t.hasNameForId(n,a)){var s=i(r,"."+a,void 0,n);t.insertRules(n,a,s)}o.push(a),this.staticRulesId=a}else{for(var l=this.rules.length,c=Rf(this.baseHash,i.hash),d="",u=0;u<l;u++){var h=this.rules[u];if("string"==typeof h)d+=h;else if(h){var p=tm(h,e,t,i),g=Array.isArray(p)?p.join(""):p;c=Rf(c,g+u),d+=g}}if(d){var f=Nf(c>>>0);if(!t.hasNameForId(n,f)){var m=i(d,"."+f,void 0,n);t.insertRules(n,f,m)}o.push(f)}}return o.join(" ")},e}(),Uf=/^\s*\/\/.*$/gm,Hf=[":","[",".","#"];function $f(e){var t,i,n,o,r=void 0===e?of:e,a=r.options,s=void 0===a?of:a,l=r.plugins,c=void 0===l?nf:l,d=new zg(s),u=[],h=function(e){function t(t){if(t)try{e(t+"}")}catch(e){}}return function(i,n,o,r,a,s,l,c,d,u){switch(i){case 1:if(0===d&&64===n.charCodeAt(0))return e(n+";"),"";break;case 2:if(0===c)return n+"/*|*/";break;case 3:switch(c){case 102:case 112:return e(o[0]+n),"";default:return n+(0===u?"/*|*/":"")}case-2:n.split("/*|*/}").forEach(t)}}}((function(e){u.push(e)})),p=function(e,n,r){return 0===n&&-1!==Hf.indexOf(r[i.length])||r.match(o)?e:"."+t};function g(e,r,a,s){void 0===s&&(s="&");var l=e.replace(Uf,""),c=r&&a?a+" "+r+" { "+l+" }":l;return t=s,i=r,n=new RegExp("\\"+i+"\\b","g"),o=new RegExp("(\\"+i+"\\b){2,}"),d(a||!r?"":r,c)}return d.use([].concat(c,[function(e,t,o){2===e&&o.length&&o[0].lastIndexOf(i)>0&&(o[0]=o[0].replace(n,p))},h,function(e){if(-2===e){var t=u;return u=[],t}}])),g.hash=c.length?c.reduce((function(e,t){return t.name||uf(15),Rf(e,t.name)}),5381).toString():"",g}var Zf=ch.createContext(),Vf=(Zf.Consumer,ch.createContext()),Gf=(Vf.Consumer,new If),jf=$f();function zf(){return(0,ch.useContext)(Zf)||Gf}function Wf(e){var t=(0,ch.useState)(e.stylisPlugins),i=t[0],n=t[1],o=zf(),r=(0,ch.useMemo)((function(){var t=o;return e.sheet?t=e.sheet:e.target&&(t=t.reconstructWithOptions({target:e.target},!1)),e.disableCSSOMInjection&&(t=t.reconstructWithOptions({useCSSOMInjection:!1})),t}),[e.disableCSSOMInjection,e.sheet,e.target]),a=(0,ch.useMemo)((function(){return $f({options:{prefix:!e.disableVendorPrefixes},plugins:i})}),[e.disableVendorPrefixes,i]);return(0,ch.useEffect)((function(){jg()(i,e.stylisPlugins)||n(e.stylisPlugins)}),[e.stylisPlugins]),ch.createElement(Zf.Provider,{value:r},ch.createElement(Vf.Provider,{value:a},e.children))}var Kf=function(){function e(e,t){var i=this;this.inject=function(e,t){void 0===t&&(t=jf);var n=i.name+t.hash;e.hasNameForId(i.id,n)||e.insertRules(i.id,n,t(i.rules,n,"@keyframes"))},this.toString=function(){return uf(12,String(i.name))},this.name=e,this.id="sc-keyframes-"+e,this.rules=t}return e.prototype.getName=function(e){return void 0===e&&(e=jf),this.name+e.hash},e}(),qf=/([A-Z])/,Yf=/([A-Z])/g,Xf=/^ms-/,Jf=function(e){return"-"+e.toLowerCase()};function Qf(e){return qf.test(e)?e.replace(Yf,Jf).replace(Xf,"-ms-"):e}var em=function(e){return null==e||!1===e||""===e};function tm(e,t,i,n){if(Array.isArray(e)){for(var o,r=[],a=0,s=e.length;a<s;a+=1)""!==(o=tm(e[a],t,i,n))&&(Array.isArray(o)?r.push.apply(r,o):r.push(o));return r}return em(e)?"":sf(e)?"."+e.styledComponentId:rf(e)?"function"!=typeof(l=e)||l.prototype&&l.prototype.isReactComponent||!t?e:tm(e(t),t,i,n):e instanceof Kf?i?(e.inject(i,n),e.getName(n)):e:tf(e)?function e(t,i){var n,o,r=[];for(var a in t)t.hasOwnProperty(a)&&!em(t[a])&&(Array.isArray(t[a])&&t[a].isCss||rf(t[a])?r.push(Qf(a)+":",t[a],";"):tf(t[a])?r.push.apply(r,e(t[a],a)):r.push(Qf(a)+": "+(n=a,(null==(o=t[a])||"boolean"==typeof o||""===o?"":"number"!=typeof o||0===o||n in Wg||n.startsWith("--")?String(o).trim():o+"px")+";")));return i?[i+" {"].concat(r,["}"]):r}(e):e.toString();var l}var im=function(e){return Array.isArray(e)&&(e.isCss=!0),e};function nm(e){for(var t=arguments.length,i=new Array(t>1?t-1:0),n=1;n<t;n++)i[n-1]=arguments[n];return rf(e)||tf(e)?im(tm(ef(nf,[e].concat(i)))):0===i.length&&1===e.length&&"string"==typeof e[0]?e:im(tm(ef(e,i)))}new Set;var om=/[!"#$%&'()*+,./:;<=>?@[\\\]^`{|}~-]+/g,rm=/(^-|-$)/g;function am(e){return e.replace(om,"-").replace(rm,"")}var sm=function(e){return Nf(Mf(e)>>>0)};function lm(e){return"string"==typeof e&&!0}var cm=function(e){return"function"==typeof e||"object"==typeof e&&null!==e&&!Array.isArray(e)},dm=function(e){return"__proto__"!==e&&"constructor"!==e&&"prototype"!==e};function um(e,t,i){var n=e[i];cm(t)&&cm(n)?hm(n,t):e[i]=t}function hm(e){for(var t=arguments.length,i=new Array(t>1?t-1:0),n=1;n<t;n++)i[n-1]=arguments[n];for(var o=0,r=i;o<r.length;o++){var a=r[o];if(cm(a))for(var s in a)dm(s)&&um(e,a[s],s)}return e}var pm=ch.createContext();function gm(e){var t=(0,ch.useContext)(pm),i=(0,ch.useMemo)((function(){return function(e,t){return e?rf(e)?e(t):Array.isArray(e)||"object"!=typeof e?uf(8):t?Qg({},t,{},e):e:uf(14)}(e.theme,t)}),[e.theme,t]);return e.children?ch.createElement(pm.Provider,{value:i},e.children):null}pm.Consumer;var fm={};function mm(e,t,i){var n=sf(e),o=!lm(e),r=t.attrs,a=void 0===r?nf:r,s=t.componentId,l=void 0===s?function(e,t){var i="string"!=typeof e?"sc":am(e);fm[i]=(fm[i]||0)+1;var n=i+"-"+sm("5.3.11"+i+fm[i]);return t?t+"-"+n:n}(t.displayName,t.parentComponentId):s,c=t.displayName,d=void 0===c?function(e){return lm(e)?"styled."+e:"Styled("+af(e)+")"}(e):c,u=t.displayName&&t.componentId?am(t.displayName)+"-"+t.componentId:t.componentId||l,h=n&&e.attrs?Array.prototype.concat(e.attrs,a).filter(Boolean):a,p=t.shouldForwardProp;n&&e.shouldForwardProp&&(p=t.shouldForwardProp?function(i,n,o){return e.shouldForwardProp(i,n,o)&&t.shouldForwardProp(i,n,o)}:e.shouldForwardProp);var g,f=new Ff(i,u,n?e.componentStyle:void 0),m=f.isStatic&&0===a.length,v=function(e,t){return function(e,t,i,n){var o=e.attrs,r=e.componentStyle,a=e.defaultProps,s=e.foldedComponentIds,l=e.shouldForwardProp,c=e.styledComponentId,d=e.target,u=function(e,t,i){void 0===e&&(e=of);var n=Qg({},t,{theme:e}),o={};return i.forEach((function(e){var t,i,r,a=e;for(t in rf(a)&&(a=a(n)),a)n[t]=o[t]="className"===t?(i=o[t],r=a[t],i&&r?i+" "+r:i||r):a[t]})),[n,o]}(function(e,t,i){return void 0===i&&(i=of),e.theme!==i.theme&&e.theme||t||i.theme}(t,(0,ch.useContext)(pm),a)||of,t,o),h=u[0],p=u[1],g=function(e,t,i,n){var o=zf(),r=(0,ch.useContext)(Vf)||jf;return t?e.generateAndInjectStyles(of,o,r):e.generateAndInjectStyles(i,o,r)}(r,n,h),f=i,m=p.$as||t.$as||p.as||t.as||d,v=lm(m),y=p!==t?Qg({},t,{},p):t,C={};for(var b in y)"$"!==b[0]&&"as"!==b&&("forwardedAs"===b?C.as=y[b]:(l?l(b,Yg,m):!v||Yg(b))&&(C[b]=y[b]));return t.style&&p.style!==t.style&&(C.style=Qg({},t.style,{},p.style)),C.className=Array.prototype.concat(s,c,g!==c?g:null,t.className,p.className).filter(Boolean).join(" "),C.ref=f,(0,ch.createElement)(m,C)}(g,e,t,m)};return v.displayName=d,(g=ch.forwardRef(v)).attrs=h,g.componentStyle=f,g.displayName=d,g.shouldForwardProp=p,g.foldedComponentIds=n?Array.prototype.concat(e.foldedComponentIds,e.styledComponentId):nf,g.styledComponentId=u,g.target=n?e.target:e,g.withComponent=function(e){var n=t.componentId,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(t,["componentId"]),r=n&&n+"-"+(lm(e)?e:am(af(e)));return mm(e,Qg({},o,{attrs:h,componentId:r}),i)},Object.defineProperty(g,"defaultProps",{get:function(){return this._foldedDefaultProps},set:function(t){this._foldedDefaultProps=n?hm({},e.defaultProps,t):t}}),Object.defineProperty(g,"toString",{value:function(){return"."+g.styledComponentId}}),o&&Jg()(g,e,{attrs:!0,componentStyle:!0,displayName:!0,foldedComponentIds:!0,shouldForwardProp:!0,styledComponentId:!0,target:!0,withComponent:!0}),g}var vm,ym=function(e){return function e(t,i,n){if(void 0===n&&(n=of),!(0,Vg.isValidElementType)(i))return uf(1,String(i));var o=function(){return t(i,n,nm.apply(void 0,arguments))};return o.withConfig=function(o){return e(t,i,Qg({},n,{},o))},o.attrs=function(o){return e(t,i,Qg({},n,{attrs:Array.prototype.concat(n.attrs,o).filter(Boolean)}))},o}(mm,e)};function Cm(e){for(var t=arguments.length,i=new Array(t>1?t-1:0),n=1;n<t;n++)i[n-1]=arguments[n];var o=nm.apply(void 0,[e].concat(i)).join(""),r=sm(o);return new Kf(r,o)}["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","marker","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","textPath","tspan"].forEach((function(e){ym[e]=ym(e)})),vm=function(e,t){this.rules=e,this.componentId=t,this.isStatic=Lf(e),If.registerId(this.componentId+1)}.prototype,vm.createStyles=function(e,t,i,n){var o=n(tm(this.rules,t,i,n).join(""),""),r=this.componentId+e;i.insertRules(r,r,o)},vm.removeStyles=function(e,t){t.clearRules(this.componentId+e)},vm.renderStyles=function(e,t,i,n){e>2&&If.registerId(this.componentId+e),this.removeStyles(e,i),this.createStyles(e,t,i,n)},function(){var e=function(){var e=this;this._emitSheetCSS=function(){var t=e.instance.toString();if(!t)return"";var i=Tf();return"<style "+[i&&'nonce="'+i+'"',lf+'="true"','data-styled-version="5.3.11"'].filter(Boolean).join(" ")+">"+t+"</style>"},this.getStyleTags=function(){return e.sealed?uf(2):e._emitSheetCSS()},this.getStyleElement=function(){var t;if(e.sealed)return uf(2);var i=((t={})[lf]="",t["data-styled-version"]="5.3.11",t.dangerouslySetInnerHTML={__html:e.instance.toString()},t),n=Tf();return n&&(i.nonce=n),[ch.createElement("style",Qg({},i,{key:"sc-0-0"}))]},this.seal=function(){e.sealed=!0},this.instance=new If({isServer:!0}),this.sealed=!1}.prototype;e.collectStyles=function(e){return this.sealed?uf(2):ch.createElement(Wf,{sheet:this.instance},e)},e.interleaveWithNodeStream=function(e){return uf(3)}}();var bm=ym;const Sm=e=>ch.createElement(wm,null,ch.createElement(xm,null,e.currencySign,e.productCurrentPrice),e.productOrgPrice>0?ch.createElement(Tm,null,ch.createElement("del",null," ",e.currencySign,e.productOrgPrice," ")):null),xm=bm.div`
font-family: "Roboto", "Segoe UI", Helvetica, Verdana, sans-serif;
font-style: normal;
font-weight: 700;
font-size: 16px;
line-height: 22px;
color: ${e=>e.theme.productCard.currentPriceColor};
`,Tm=bm.div`
font-family: "Roboto", "Segoe UI", Helvetica, Verdana, sans-serif;
font-style: normal;
font-weight: 400;
font-size: 12px;
line-height: 16px;
text-decoration-line: line-through;
color: ${e=>e.theme.productCard.oriPriceColor};
margin-left: 10px;
`,wm=bm.div`
display: flex;
flex-direction: row;
justify-content: flex-start;
align-items: center;
`,Om=bm.div`
display: flex;
flex-direction: row;
align-items: flex-start;
padding: 2px 4px;
gap: 10px;
background: rgba(224, 44, 35, 0.06);
border-radius: 4px;
font-family: "Segoe UI", "Roboto", Helvetica, Verdana, sans-serif;
font-style: normal;
font-weight: 400;
font-size: 10px;
line-height: 14px;
color: #E02C23;
`,Pm=bm(Om)`
background: rgb(0, 0, 0, 0.06);
color: #717171;
order: 1;
`,Am=(0,Zg.Z)({container:{display:"flex",flexDirection:"column","&:hover":{cursor:"pointer"}},tags:{display:"flex",flexDirection:"row",columnGap:"14px",marginLeft:"12px",marginTop:"8px"},vendor:{display:"flex",flexDirection:"row",marginLeft:"12px",marginTop:"12px",marginBottom:"12px",columnGap:"2px"},productDetails:{marginLeft:"12px",marginTop:"4px"},productDetailContent:{marginLeft:"12px",marginTop:"4px"}}),Em=e=>{const{productImgUrl:t,defaultProductImgUrl:i,safeFetchImg:n,onLoadError:o,pageHandler:r}=e,[a,s]=ch.useState("");return(0,ch.useEffect)((()=>{n&&r.GetSafeImage(t).then((e=>e)).then((e=>{e.succ&&""!==e.safeImgData?s(e.safeImgData):(s(i),null==o||o())})).catch((e=>{s(i),null==o||o()}))}),[]),ch.createElement(e.img,{"aria-hidden":!0,tabIndex:-1,src:n?a:t,onError:e=>{e.currentTarget.src!==i&&(e.currentTarget.src=i)}})},km=e=>{const{iconImgUrl:t,safeFetchImg:i}=e,[n,o]=ch.useState("");return(0,ch.useEffect)((()=>{i&&(0,an.mG)(void 0,void 0,void 0,(function*(){return e.pageHandler.GetSafeImage(t).then((e=>{e.succ?o(e.safeImgData):o("")}))})).catch((e=>{o("")}))}),[]),ch.createElement(Mm,{"aria-hidden":!0,tabIndex:-1,src:i?n:t})},Im=e=>{const t=Am(),i=e.productData,[n,o]=(0,ch.useState)(!1),r=(0,ch.useCallback)((()=>{e.pageHandler.NavigateToUrl(e.productData.Url),e.onDivClick()}),[e.productData,e.onDivClick]),a=(0,ch.useCallback)((e=>{"Enter"!==e.key&&" "!==e.key||r()}),[r]);return ch.createElement(ch.Fragment,null,!n&&ch.createElement(Dm,{tabIndex:0,className:t.container,onClick:r,onKeyDown:a},ch.createElement(Em,{safeFetchImg:e.safeFetchImg,pageHandler:e.pageHandler,onLoadError:()=>{e.shouldHideIfError&&o(!0)},productImgUrl:i.ImageUrl,defaultProductImgUrl:e.svgBasePath+"common/defaultProduct.svg",img:Nm}),ch.createElement("div",{"aria-hidden":"true",tabIndex:-1,className:t.productDetails},ch.createElement(Sm,{productCurrentPrice:i.Price,productOrgPrice:i.OriginalPrice,currencySign:i.CurrencySymbol})),ch.createElement("div",{"aria-hidden":"true",tabIndex:-1,className:t.productDetailContent},ch.createElement(Rm,null,i.ProductTitle)),e.tags?ch.createElement("div",{className:t.tags},e.tags.map(((e,t,i)=>"grey"===e.color?ch.createElement(Pm,{key:t},e.title):ch.createElement(Om,{key:t},e.title)))):null,ch.createElement("div",{"aria-hidden":"true",tabIndex:-1,className:t.vendor},ch.createElement(km,{iconImgUrl:i.FavIcon,safeFetchImg:e.safeFetchImg,pageHandler:e.pageHandler}),ch.createElement(_m,null,i.SellerName))))},Dm=bm.div`
border-radius: 8px;
border: 1px solid ${e=>e.theme.productCard.borderColor};
`,_m=bm.div`
font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;
font-style: normal;
font-weight: 400;
font-size: 12px;
line-height: 16px;
color: ${e=>e.theme.similarProduct.detail};
white-space: nowrap;
max-width: 100px;
overflow: hidden;
text-overflow: ellipsis;
`,Nm=bm.img`
width: 154px;
height: 154px;
background: ${e=>e.theme.similarProduct.imgBackgroundColor};
border-radius: 8px 8px 0px 0px;
`,Rm=bm.div`
font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;
font-style: normal;
font-weight: 400;
font-size: 12px;
line-height: 16px;
color: ${e=>e.theme.similarProduct.detail};
white-space: nowrap;
max-width: 138px;
overflow: hidden;
text-overflow: ellipsis;
`,Mm=bm.img`
width: 16px;
height: 16px;
`,Lm={textColor:"#000000",priceHistory:{priceColor:"#1A1A1A",priceOriColor:"#717171",priceStableColor:"#444444"},similarProduct:{vendorColor:"#717171",imgBackgroundColor:"#F8F8F8",detail:"#717171"},productCard:{currentPriceColor:"#1A1A1A",oriPriceColor:"#717171",borderColor:"#ECECEC"},priceNotification:{titleColor:"#1A1A1A",oriPriceColor:"#717171"}},Bm={textColor:"#FFFFFF",priceHistory:{priceColor:"#FFFFFF",priceOriColor:"rgba(255, 255, 255, 0.523364)",priceStableColor:"#FFFFFF"},similarProduct:{vendorColor:"#FFFFFF",imgBackgroundColor:"#1F1F1F",detail:"rgba(255, 255, 255, 0.523364)"},productCard:{currentPriceColor:"#FFFFFF",oriPriceColor:"rgba(255, 255, 255, 0.523364)",borderColor:"rgba(255, 255, 255, 0.191589)"},priceNotification:{titleColor:"#FFFFFF",oriPriceColor:"rgba(255, 255, 255, 0.523364)"}},Fm=(0,Zg.Z)({container:{display:"flex",flexDirection:"row",paddingLeft:"16px",paddingBottom:"16px",height:"100%",flexWrap:"wrap",rowGap:"12px",columnGap:"10px",paddingRight:"16px"}}),Um=e=>{const t=Fm();return ch.createElement(gm,{theme:e.isDarkMode?Bm:Lm},ch.createElement("div",{className:t.container},e.cjkSimilarProductsData?.ProductData.map(((t,i,n)=>ch.createElement(Im,{key:i,svgBasePath:e.sourceEndPoint,productData:t,onDivClick:e.manageClickHandler,pageHandler:e.pageHandler,shouldHideIfError:!0,safeFetchImg:e.safeFetchImg})))))};class Hm extends Qu{constructor(e,t,i,n){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"cjkSimilarProductsData",void 0),(0,s.Z)(this,"cjkspSection",void 0),(0,s.Z)(this,"sectionId",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"isCjkEnabled",void 0),(0,s.Z)(this,"cjkDataVendor",void 0),(0,s.Z)(this,"manageClickHandler",(()=>{this.pageHandlerModule.RecordAsUserAction(K.bS.CJK_SIMILAR_PRODUCTS_CLICK),this.pageHandlerModule.RecordAsCjkScenario(Hg.ACTION,Ug.SIMILAR_PRODUCTS),this.cjkDataVendor&&this.cjkDataVendor in $g&&this.pageHandlerModule.RecordAsCjkScenario(Hg.ACTION+$g[this.cjkDataVendor],Ug.SIMILAR_PRODUCTS)})),this.pageHandlerModule=t.pageHandlerModule,this.flyoutData=e,this.utilities=t.viewModulesUtilities,this.cjkSimilarProductsData=this.flyoutData.dataStoreModule.CjkSimilarProductsData,this.isCjkEnabled=e.common.isCJKEnabled,this.cjkDataVendor=e.common.cjkDataVendor}GetModuleName(){return r.ModuleNames.CJK_SIMILAR_PRODUCTS}ShouldRenderModule(){return this.isCjkEnabled&&this.cjkSimilarProductsData&&0!==this.cjkSimilarProductsData.ProductData.length?Promise.resolve(!0):Promise.resolve(!1)}renderModule(){return this.isCjkEnabled&&this.cjkSimilarProductsData&&0!==this.cjkSimilarProductsData.ProductData.length?(this.cjkspSection=document.createElement("msft-edge-shopping-section"),this.cjkspSection.id=this.sectionId,this.cjkspSection.isCjk=!0,sp.render(ch.createElement(Um,{sourceEndPoint:this.flyoutData.common.resourcesEndpoint,cjkSimilarProductsData:this.cjkSimilarProductsData,isDarkMode:this.utilities.isDarkMode(),manageClickHandler:this.manageClickHandler,pageHandler:this.pageHandlerModule,safeFetchImg:this.flyoutData.common.isCjkShouldGetSafeImage&&this.pageHandlerModule.IsMessageAllowed("getSafeImage")}),this.cjkspSection),this.utilities.createCommonListStructure(this.cjkspSection,this.flyoutData.strings.cjkSimilarProductsSectionTitle,this.cjkSimilarProductsData,this.GetModuleName(),this.numbersToRender.bind(this),this.populatePriceList.bind(this),void 0,void 0,this.isCjkEnabled),this.pageHandlerModule.RecordAsCjkScenario(Hg.SHOW,Ug.SIMILAR_PRODUCTS),this.cjkDataVendor&&this.cjkDataVendor in $g&&this.pageHandlerModule.RecordAsCjkScenario(Hg.SHOW+$g[this.cjkDataVendor],Ug.SIMILAR_PRODUCTS),Promise.resolve(this.CreateModule(this.cjkspSection,r.H7.CJK_SIMILAR_PRODUCTS,r.ModuleNames.CJK_SIMILAR_PRODUCTS,r.$k.CONTEXTUAL,r.SV.SQUARES))):Promise.resolve(null)}populateMainHeader(){if(this.flyoutData.common.shoppingPersistent){const e=this.flyoutData.common.shoppingPersistent.querySelector("#CJK-Similar-Products");if(e){e.style.marginTop="0px",e.slot="header-content";const t=e.querySelector("#CJK-Similar-Products");t&&(t.style.margin="0px!important"),gn.SO.queueUpdate((()=>{this.utilities.handleCjkSectionAsTopModuleStyle(e)}))}}}numbersToRender(){return r.CS.CJK_SIMILAR_PRODUCTS}populatePriceList(e,t,i){}}var $m=o(93190),Zm=o(50616),Vm=function(e){return e.enus="en-us",e.engb="en-gb",e.enca="en-ca",e}(Vm||{}),Gm=class extends Qu{constructor(t,i,n,o){super(),(0,s.Z)(this,"assets",null),(0,s.Z)(this,"clippingAssets",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"shouldRenderClipping",void 0),(0,s.Z)(this,"clippingCompleted",!1),(0,s.Z)(this,"market",void 0),(0,s.Z)(this,"discountDetails",void 0),(0,s.Z)(this,"initialPrice",void 0),(0,s.Z)(this,"promoCode",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"clippingState",void 0),(0,s.Z)(this,"wasSignedIn",void 0),(0,s.Z)(this,"shouldReadFromState",void 0),(0,s.Z)(this,"clippingSection",void 0),(0,s.Z)(this,"promoCodeElement",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"rakutenJP","rakuten.co.jp"),(0,s.Z)(this,"isClippingV2",void 0),(0,s.Z)(this,"simpleDomainName",void 0),this.flyoutData=t,this.utilities=i.viewModulesUtilities,this.pageHandlerModule=i.pageHandlerModule,this.logModule=i.logModule,this.stateManagement=n,this.commonAssets=o,this.storageHandler=i.storageHandler,this.telemetryUtilities=i.telemetryHandler,this.market=(0,T.uf)(this.flyoutData.dataStoreModule.ApiData?.market,this.flyoutData.dataStoreModule.ApiData?.retailerData?.exclusiveMarket),this.isClippingV2=e.R.isExperimentActive(f.H.clippingV2),this.simpleDomainName=Zm.Z.getSimpleDomainName(this.flyoutData.common.domain),this.clippingAssets=new class{getStyles(){return"\n #clippingSection {\n text-align: left;\n }\n #clippingButton {\n width: 228px !important;\n }\n #clippingMainTitleV2 {\n text-align: center;\n font-size: 16px;\n font-weight: 600;\n line-height: 22px;\n }\n #clippingSubtitleV2 {\n text-align: center;\n font-size: 14px;\n font-weight: 400;\n line-height: 20px;\n margin-top: 4px;\n margin-bottom: 8px;\n }\n #conditionsMayApplySubtitle {\n text-align: center;\n font-size: 12px;\n font-weight: 400;\n line-height: 16px;\n margin-bottom: 4px\n }\n #clippingCompletedSection {\n overflow: hidden;\n }\n #clippingCompletedMainTitle {\n text-align: center;\n font-weight: 600;\n line-height: 22px;\n }\n #clippingCompletedSubtitleSection {\n display: flex;\n justify-content: center;\n height: 22px;\n }\n #clippingCompletedSubtitle {\n font-size: 14px;\n max-width: 220px;\n font-weight: 400;\n line-height: 20px;\n margin-left: 5px;\n }\n "}}}GetModuleName(){return r.ModuleNames.COUPONCLIPPING}CalculateRanking(){return this.clippingCompleted?r.zz.InformPage:r.zz.SaveMoneyPage}SetClippingCompleted(e){this.clippingCompleted=e}async ShouldRenderModule(){if(void 0!==this.shouldRenderClipping)return this.shouldRenderClipping;const e=this.getClippingSelectors();if(!e)return!1;if(this.shouldRenderClipping=this.isClippingDataAvailable(),this.shouldRenderClipping)return!!this.flyoutData.common.lastCommittedURL;if(globalThis.clippingUpdated){const t=globalThis.clippingState;return t&&(this.clippingState=t,this.shouldReadFromState=!0),await this.getClippingData(e),!!this.shouldRenderClipping&&!!this.flyoutData.common.lastCommittedURL}if(this.flyoutData.common.isPane&&this.flyoutData.common.lastCommittedURL){const t=this.flyoutData.common.lastCommittedURL;return this.getClippingData(e).then((()=>{if(!globalThis.clippingUpdated&&t===this.flyoutData.common.lastCommittedURL&&this.shouldRenderClipping){globalThis.clippingState=this.clippingState;const e=this.stateManagement.getState(Ku.IY.renderedModules),t=e?.map((e=>e.name))??[],i=new CustomEvent(Ku.e1.ReRankFlyout,{detail:{refreshType:Mg.Clipping,moduleNames:[this.GetModuleName(),...t]}});this.stateManagement.dispatchEvent(i)}})),!1}return!1}PostProcessing(e,t,n){if(this.shouldRenderClipping&&!this.clippingCompleted){const e=(0,Y.Ux)("DIV");0===t&&(e.slot="actions"),this.flyoutData.common.isPane&&(e.style.display="flex",e.style.justifyContent="center",e.style.width="100%");const o=(0,Y.lw)(this.utilities);this.utilities.shouldRenderSmallNotification()||(o.id="clippingButton"),e&&o&&(o.setAttribute("aria-labelledby","clippingTitle"),o.setAttribute("aria-describedby","clippingTitle"),this.isClippingV2?(o.textContent=this.flyoutData.strings.autoClipButtonTitleV2,o.style.fontSize="14px",o.style.borderRadius="4px",o.style.minWidth="unset",o.style.minHeight="32px",o.style.height="auto",e.style.marginTop="5px",e.style.marginBottom="5px",this.utilities.shouldRenderSmallNotification()&&(e.style.textAlign="center",e.style.marginTop="10px",e.style.marginBottom="1px")):o.textContent=this.flyoutData.strings.autoClipButtonTitle,(0,dt.tB)(this.flyoutData)&&(o.style.width="90%",o.style.height="32px",o.style.background="padding-box linear-gradient(var(--accent-fill-rest), var(--accent-fill-rest)), border-box var(--accent-stroke-control-rest)"),o.addEventListener("click",(()=>{this.turnOnAutoClip(this.flyoutData.common.domain);const e=new W.Z(i.$S.AutoApply,this.telemetryUtilities.setContentViewed(this.GetModuleName()));let t;this.pageHandlerModule.RecordAsUserAction(K.bS.CLIP_COUPON),this.pageHandlerModule.RecordAsUserEngagement(q.FV.CLIP_COUPON,this.flyoutData.common.popupOrigination),this.logModule.LogInfoEvent(i.R.ButtonClick,"Coupon clipped",e,Jl.g.CouponImpressionId),t=(0,dt.tB)(this.flyoutData)?{discount:this.discountDetails?.discount,initialPrice:this.initialPrice,selectors:this.getClippingSelectors()}:{discount:this.discountDetails?.discount,initialPrice:this.initialPrice},this.pageHandlerModule.StartEdgeDriver(JSON.stringify({action:eg.v.Clipping,data:t})),this.flyoutData.common.isPane||this.pageHandlerModule.DismissPopup()})),e.appendChild(o),0===t?n.appendChild(e):(n.appendChild(e),n.style.padding=this.isClippingV2?"12px 16px":"12px"),o.control.style.whiteSpace="normal",(0,dt.tB)(this.flyoutData)&&(n.style.padding="0px"))}else this.clippingCompleted&&this.isClippingV2&&t>0&&(n.style.padding="12px 16px")}async renderModule(){if(this.isClippingV2&&!(0,dt.tB)(this.flyoutData))return this.renderModuleV2();if(await this.setInitialAndDiscountPriceAndPromoCode(),this.clippingCompleted){this.clippingSection=await this.renderCompleted();const e=this.CreateModule(this.clippingSection,r.H7.COUPONCLIPPING,r.ModuleNames.COUPONCLIPPING,r.$k.CONTEXTUAL,r.SV.BLOCK);return Promise.resolve(e)}if(this.clippingSection=(0,Y.Ux)("DIV"),this.clippingSection.id="clippingSection",this.clippingSection.style.textAlign="center",this.flyoutData.common.isPane&&this.utilities.isValidScenarioForProductSummary()&&(this.clippingSection.style.position="relative",this.clippingSection.style.top="10px"),(0,dt.tB)(this.flyoutData)){const e=(0,Y.Ux)("IMG");e.src=await this.pageHandlerModule.GetImageSrc("../images/coupons-stars-icon.png"),this.clippingSection.appendChild(e),this.clippingSection.style.paddingTop="0px"}const e=this.createMainTitle();this.clippingSection.appendChild(e),this.discountDetails?.conditionsMayApply&&this.clippingSection.appendChild(this.createconditionsMayApplySubTitleSection());const t=this.createPromoCodeBtn();t&&this.clippingSection.appendChild(t);const i=this.createSubtitle();this.clippingSection.appendChild(i),this.utilities.shouldRenderSmallNotification()&&this.clippingSection.classList.add("lateralMargin");const n=this.CreateModule(this.clippingSection,r.H7.COUPONCLIPPING,r.ModuleNames.COUPONCLIPPING,r.$k.CONTEXTUAL,r.SV.BLOCK);return Promise.resolve(n)}async renderModuleV2(){if(await this.setInitialAndDiscountPriceAndPromoCode(),this.clippingCompleted){this.clippingSection=await this.renderCompletedV2();const e=this.CreateModule(this.clippingSection,r.H7.COUPONCLIPPING,r.ModuleNames.COUPONCLIPPING,r.$k.CONTEXTUAL,r.SV.BLOCK);return Promise.resolve(e)}this.clippingSection=(0,Y.Ux)("DIV"),this.clippingSection.id="clippingSection",this.flyoutData.common.isPane&&this.utilities.isValidScenarioForProductSummary()&&(this.clippingSection.style.position="relative",this.clippingSection.style.top="10px"),this.utilities.applyStyles(this.clippingSection,this.clippingAssets.getStyles());const e=this.createMainTitleV2();this.clippingSection.appendChild(e);const t=this.createSubTitleV2();this.clippingSection.appendChild(t),this.utilities.shouldRenderSmallNotification()&&this.clippingSection.classList.add("lateralMargin");const i=this.CreateModule(this.clippingSection,r.H7.COUPONCLIPPING,r.ModuleNames.COUPONCLIPPING,r.$k.CONTEXTUAL,r.SV.BLOCK);return Promise.resolve(i)}populateMainHeader(){this.clippingSection&&(this.clippingSection.style.marginTop="0px",this.clippingSection.slot="header-content"),this.flyoutData.common.openedWith===r.Te.Auto&&this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_COUPONS_CLIPPING&&this.flyoutData.common.shopping.classList.add("noSections")}async renderCompleted(){const e=(0,Y.Ux)("DIV");e.id="clippingSection",e.style.overflow="hidden",e.style.padding="16px",this.utilities.isValidScenarioForProductSummary()&&(e.style.position="relative",e.style.top="10px");const t=(0,Y.Ux)("H2");t.id="clippingTitle",t.className="txtLarge",t.style.textAlign="center";let i=this.discountDetails?.discount??0;const n=this.discountDetails?.maxDiscount??0;let o;if(n>i?(i=n,o=this.flyoutData.strings.clippedTitleUpTo):o=this.flyoutData.strings.clippedTitle,this.discountDetails?.discount){const e=(0,Y.Ux)("SPAN"),n=this.utilities.formatPrice(i,this.market);if(e.textContent=(0,T.Ow)(`${r.iM.currency}${n}`,this.market),e.className="txtSavingsColor",e.style.fontSize="26px",e.style.lineHeight="30px",e.style.fontWeight="700",!this.utilities.shouldRenderSmallNotification()){const t=(0,Y.Ux)("BR");e.appendChild(t)}(0,T.B7)(t,o,e)}else o=o.split(/\$\d/).join("").replace(" "," "),t.textContent=o;e.appendChild(t),this.discountDetails?.conditionsMayApply&&e.appendChild(this.createconditionsMayApplySubTitleSection());const a=this.createClippedCouponSubTitleSection();return e.appendChild(a),Promise.resolve(e)}async renderCompletedV2(){const e=(0,Y.Ux)("DIV");e.id="clippingCompletedSection",this.utilities.applyStyles(e,this.clippingAssets.getStyles()),this.utilities.isValidScenarioForProductSummary()&&(e.style.position="relative",e.style.top="10px");const t=(0,Y.Ux)("H2");t.id="clippingCompletedMainTitle",t.className="txtMedium";let i=this.discountDetails?.discount??0;const n=this.discountDetails?.maxDiscount??0;let o;if(n>i?(i=n,o=this.flyoutData.strings.clippedCompletedTitleUpTo):o=this.flyoutData.strings.clippedCompletedTitle,this.discountDetails?.discount){const e=(0,Y.Ux)("SPAN"),n=this.utilities.formatPrice(i,this.market);if(e.textContent=(0,T.Ow)(`${r.iM.currency}${n}`,this.market),e.className="txtSavingsColor",e.style.fontSize="16px",e.style.lineHeight="22px",e.style.fontWeight="600",e.style.display="inline-block",!this.utilities.shouldRenderSmallNotification()){const t=(0,Y.Ux)("BR");e.appendChild(t)}(0,T.B7)(t,o,e)}else o=o.split(/\$\d/).join("").replace(" "," "),t.textContent=o;e.appendChild(t);const a=this.createClippedCouponSubTitleSectionV2();return e.appendChild(a),Promise.resolve(e)}createClippedCouponSubTitleSection(){const e=(0,Y.Ux)("DIV");e.slot="actions",e.style.display="flex",e.style.justifyContent="center",e.style.marginTop="15px",e.style.marginBottom="15px",e.style.height="22px";const t=(0,Y.Ux)("DIV");t.innerHTML=this.commonAssets.getGreenCheck(),t.slot="start",this.market===Vm.engb&&(t.style.marginRight="6px"),t.style.marginTop="8px",e.appendChild(t);const i=(0,Y.Ux)("DIV");return i.textContent=this.getClippedSubTitle(),i.style.fontSize="16px",i.style.maxWidth="220px",i.style.width="100%",i.style.marginTop="8px",i.style.fontWeight="500",i.style.marginLeft="5px",this.utilities.isDarkMode()?(i.style.color="#FFFFFF",i.style.borderColor="#FFFFFF"):i.style.color="#000000",e.appendChild(i),e}createClippedCouponSubTitleSectionV2(){const e=(0,Y.Ux)("DIV");e.id="clippingCompletedSubtitleSection",e.slot="actions";const t=(0,Y.Ux)("DIV");t.innerHTML=this.commonAssets.getGreenCheck(),t.slot="start",t.style.height="16px",t.style.marginTop="2px";const i=t.querySelector("SVG");i&&(i.setAttribute("width","16"),i.setAttribute("height","16")),this.market===Vm.engb&&(t.style.marginRight="6px"),e.appendChild(t);const n=(0,Y.Ux)("DIV");return n.textContent=this.getClippedSubTitle(),n.id="clippingCompletedSubtitle",this.utilities.isDarkMode()?(n.style.color="#FFFFFF",n.style.borderColor="#FFFFFF"):n.style.color="#000000",e.appendChild(n),e}createconditionsMayApplySubTitleSection(){const e=(0,Y.Ux)("H2");return e.id="conditionsMayApplySubtitle",e.className="txtLarge",this.utilities.isDarkMode()||(e.style.color="gray"),e.textContent=this.flyoutData.strings.conditionsMayApplySubTitle,e}createMainTitle(){const e=(0,Y.Ux)("H2");e.id="clippingTitle";let t=this.discountDetails?.discount??0;const i=this.discountDetails?.maxDiscount??0;let n=!1;return(i>t||this.promoCodeElement)&&(t=i,n=!0),this.utilities.shouldRenderSmallNotification()?(e.className="txtMedium",e.style.fontSize="20px",e.style.lineHeight="26px",e.style.fontWeight="600"):(e.className="txtLarge",e.style.fontSize="26px",e.style.lineHeight="36px",e.style.fontWeight="600",e.style.marginLeft="40px",e.style.marginRight="40px"),e.style.textAlign="center",e.style.marginBottom="8px",e.textContent=this.getClippingDefaultTitle(),t&&this.getClippingMainTitle(t,e,n),e}createMainTitleV2(){const e=(0,Y.Ux)("H2");e.id="clippingMainTitleV2",e.className="txtLarge";const t=(0,Y.Ux)("SPAN");return t.textContent=this.simpleDomainName??"",(0,T.B7)(e,this.flyoutData.strings.clippingMainTitleV2,t),this.utilities.isDarkMode()||(e.style.color="rgba(0, 0, 0, 0.86)"),this.utilities.shouldRenderSmallNotification()&&(e.style.fontSize="20px",e.style.lineHeight="28px"),e}createSubtitle(){const e=(0,Y.Ux)("H2");return e.id="clippingSubtitle",e.className="txtLarge",e.style.textAlign="center",e.style.fontSize="12px",e.style.fontWeight="400",e.style.lineHeight="16px",e.style.marginBottom="4px",this.utilities.isDarkMode()||(e.style.color="gray"),e.textContent=(0,dt.tB)(this.flyoutData)?this.flyoutData.strings.autoClipSafariSubTitle:this.flyoutData.strings.autoClipSubTitle,e}createSubTitleV2(){const e=(0,Y.Ux)("H2");e.id="clippingSubtitleV2",e.className="txtMedium";let t=this.discountDetails?.discount??0;const i=this.discountDetails?.maxDiscount??0;let n=!1;return(i>t||this.promoCodeElement)&&(t=i,n=!0),e.textContent=this.flyoutData.strings.defaultClippedSubTitleV2,t&&this.getClippingSubTitleV2(t,e,n),e}createPromoCodeBtn(){if(!(0,p.TF)(this.promoCode)){const e=(0,Y.Ux)("fluent-button");e.appearance="stealth",e.classList.add("copyCouponBtn"),e.textContent=this.promoCode,e.setAttribute("aria-label","Promo code for current product"),this.clippingSection.appendChild(e);const t=(0,Y.Ux)("DIV");return t.style.display="flex",t.style.marginLeft="6px",t.slot="end",t.innerHTML=this.utilities.commonAssets.getCopyIcon(),t.setAttribute("aria-hidden","true"),e.appendChild(t),e.addEventListener("click",(async()=>{t.innerHTML=this.utilities.commonAssets.getBlueCheckCircle(),this.pageHandlerModule.CopyCoupon(this.promoCode);const e=new W.Z(i.$S.CouponCopied,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.pageHandlerModule.RecordAsUserAction(K.bS.COUPONS_COPIED),this.logModule.LogInfoEvent(i.R.ButtonClick,"Amazon promo code copied",e)})),e}}extractPromoCode(e){if(e&&e?.InnerText?.length>0){const t=new RegExp(/(?:promo code: )(\w+)/gi).exec(e.InnerText.trim());if(t?.[1]&&t[1].length>0&&t[1].length<20)return t[1]}return""}async setInitialAndDiscountPriceAndPromoCode(){const e=this.flyoutData.dataStoreModule.ApiData?.retailerData,n=e?.GetCurrentCheckoutPage(this.flyoutData.common.lastCommittedURL),o=n?.clippingSelectors?.orderTotalDataElementSelector,r=n?.clippingSelectors?.promoCodeSelector,a=await this.GetElements([o,r]);if(a){const e=new t.Z(i.xu.CouponClippingElements);e.Metadata=JSON.stringify({orderTotalSelector:o,promoCodeSelector:r,Url:this.flyoutData.common.lastCommittedURL}),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"setInitialAndDiscountPriceAndPromoCode successful",e);const s=a[0]?.at(0);this.promoCodeElement=a[1]?.at(0),this.promoCode=this.extractPromoCode(this.promoCodeElement);const l=s?.InnerText??"";let c,d;if(l.includes("-")){const e=l.split("-");c=Zm.Z.getInitialPrice(e[0]),d=Zm.Z.getInitialPrice(e[1])}else c=Zm.Z.getInitialPrice(l);this.initialPrice=c,this.discountDetails=await this.getDiscount(c,d,n?.clippingSelectors)}}async getDiscount(e,n,o){let r;if(this.flyoutData.common.domain===this.rakutenJP){const t=[],i=o?.discountSelector?await this.getAllVisibleElements(o?.discountSelector):void 0;if(!i||!i.length)return;JSON.parse(i)[0].forEach((i=>{const n=i.InnerText.toString().includes("%")||i.InnerText.toString().includes("%")?Math.floor((0,ne.K)(i.InnerText??"0")*e/100):(0,ne.K)(i.InnerText??"0");t.push(n)})),t.sort(((e,t)=>e-t)),r={discount:t[0],maxDiscount:t[t.length-1],discountString:t[0].toString(),conditionsMayApply:!0}}else{const a=this.clippingCompleted?o?.clippedDiscountSelector:o?.discountSelector,s=(await this.GetElements([a]))?.at(0);if(s){const l=new t.Z(i.xu.CouponClippingElements);if(l.Metadata=JSON.stringify({discountSelector:a,Url:this.flyoutData.common.lastCommittedURL}),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"getDiscount successful",l),s.length>1){const t=this.getAmazonClippingDiscountFromDiscountElement(e,s);r={discount:t??0,maxDiscount:t??0,discountString:t?.toString()??"",conditionsMayApply:!1}}else{const t=s[0],i=t?.InnerText??"";if(i.match("[^a-zA-Z]-[^a-zA-Z]")){const a=i.split("-"),s=Zm.Z.getAmazonClippingDiscount(e,a[0])??0,l=Zm.Z.getAmazonClippingDiscount(e,a[1])??0;let c=0,d=0;if(o?.isSalePriceNotDiscount)if(n){const t=0===s?0:e-s,i=0===l?0:n-l;c=Math.min(t,i),d=Math.max(t,i)}else d=0===s?0:e-s,c=0===l?0:e-l;else c=s,d=l;r={discount:c,maxDiscount:d,discountString:t?.InnerText??"",conditionsMayApply:!1}}else{let n=Zm.Z.getAmazonClippingDiscount(e,i)??0;o?.isSalePriceNotDiscount&&(n=0===n?0:e-n),r={discount:n??0,maxDiscount:n??0,discountString:t?.InnerText??"",conditionsMayApply:!1}}}}else r=void 0}return r}getAmazonClippingDiscountFromDiscountElement(e,n){let o=0;try{e&&n&&n.forEach((t=>{o+=Zm.Z.getAmazonClippingDiscount(e,t?.InnerText)??0}))}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Clipping flyout getDiscount error, with Type: ${e.name}, with message: ${e.message}`,n)}return o}async getClippingData(e){let t=await this.checkElementsFromPage(e);const{isPane:i}=this.flyoutData.common;t&&this.clippingCompleted&&!i&&(t=0===await this.stateManagement.getState(Ku.IY.renderedViewModuleCount)),this.shouldRenderClipping=t,this.shouldRenderClipping&&await this.setInitialAndDiscountPriceAndPromoCode()}getClippingSelectors(){const e=this.flyoutData.dataStoreModule.ApiData?.retailerData,t=e?.GetCurrentCheckoutPage(this.flyoutData.common.lastCommittedURL);return t?.clippingSelectors}getAutoEnabledDomains(){const e=this.flyoutData.dataLoader.GetLoadTimeDataValue("storage",void 0);if(e){const t=e[Ce.Q.AutoClipData];try{const e=JSON.parse(t);if(e?.enabledDomains)return e.enabledDomains}catch{}}}isClippingDataAvailable(){const e=this.flyoutData.common;if(this.shouldReadFromState=!0,this.clippingState||(this.clippingState=new class{constructor(){(0,s.Z)(this,"isSignedIn",void 0),(0,s.Z)(this,"clippingCompleted",void 0),(0,s.Z)(this,"clipButtonVisible",void 0),(0,s.Z)(this,"clickBeforeVisible",void 0),(0,s.Z)(this,"discount",void 0),(0,s.Z)(this,"initialPrice",void 0)}},this.shouldReadFromState=!1),e?.popupOrigination===u.sR.AUTO_SHOW_COUPONS_CLIPPING&&e.openedWith===r.Te.Auto)return this.clippingCompleted=!1,this.clippingState.clippingCompleted=this.clippingCompleted,!0;this.wasSignedIn=!1;const t=e?.pageStatus?.PageValidations;if(t){if(!t.includes($m.p.COUPONS_CLIPPING))return!1;this.wasSignedIn=!0}return!1}async checkElementsFromPage(e){const n=e.signedInSelector,o=e.clipCouponSelector,r=e.alreadyClippedSelector,a=e.clickBeforeClipSelector;if(!this.shouldReadFromState){const s=await this.GetElements([n,o,r,a]),l=s?.at(0)?.at(0),c=s?.at(1)?.at(0),d=s?.at(2)?.at(0),u=s?.at(3)?.at(0);if(this.clippingState.isSignedIn=!!l,this.clippingState.clipButtonVisible=!!c,this.clippingState.clickBeforeVisible=!!u,this.clippingState.clippingCompleted=!!d&&!c,d){const n=new t.Z(i.xu.CouponClippingElements);n.Metadata=JSON.stringify({alreadyClippedSelector:e.alreadyClippedSelector,Url:this.flyoutData.common.lastCommittedURL}),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"alreadyClippedElement successful",n)}}const s=this.flyoutData.common;if(!this.wasSignedIn&&!this.clippingState.isSignedIn)return Promise.resolve(!1);this.clippingCompleted=this.clippingState.clippingCompleted;const l=s.lastClippingAutoApplyDetailsForCurrentUrl;return l&&(this.clippingCompleted=this.clippingCompleted||!!l?.cart_value),this.clippingCompleted||this.clippingState.clipButtonVisible||this.clippingState.clickBeforeVisible?Promise.resolve(!0):Promise.resolve(!1)}turnOnAutoClip(e){let t=this.getAutoEnabledDomains();if(void 0===t&&(t=[]),t.includes(e))return;t.push(e);const i={enabledDomains:t},n=JSON.stringify(i);this.storageHandler.setStorageString(Ce.Q.AutoClipData,n)}async GetElements(e){const t=e.filter((e=>!!e)).join(";");if(!t)return;const i=await this.getAllVisibleElements(t),n=new Array;if(void 0===i)for(const t of e){const e=[t?await this.getVisibleElement(t):void 0];n.push(e)}else try{const t=JSON.parse(i);let o=0;for(const i of e){if(!i){n.push(void 0);continue}const e=i?.split(";").length??0;let r=!1;const a=t.slice(o,o+e),s=[];for(const e of a)for(const t of e)t&&t.offsetHeight>0&&t.offsetWidth>0&&(r=!0,s.push(t));r?n.push(s):n.push(void 0),o+=e}}catch(e){return}return n}async getVisibleElement(e){const t=e.split(";");for(const e of t)try{const t=await this.pageHandlerModule.RunQuerySelectorOnBodyWithReponse(e),i=JSON.parse(t.extractedValues);if(t.found&&i?.offsetHeight>0&&i?.offsetWidth>0)return{InnerText:t.innerText,offsetHeight:i.offsetHeight,offsetWidth:i.offsetWidth}}catch(e){}return Promise.resolve(void 0)}async getAllVisibleElements(e){if(!1===this.pageHandlerModule.IsMessageAllowed("runQuerySelectorAllOnBodySemicolonSeparated"))return Promise.resolve(void 0);try{const n=await this.pageHandlerModule.RunQuerySelectorAllOnBodyWithReponse(e),o=new t.Z(i.xu.CouponClippingElements);return o.Metadata=JSON.stringify({selectors:e,element:n.response}),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Get clipping selectors and elements",o),n.response}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);n.Metadata=JSON.stringify(e),this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Error on getting clipping elements with Type: ${e.name}, with message: ${e.message}`,n)}return Promise.resolve(void 0)}getClippedSubTitle(){return this.market===Vm.engb?this.isClippingV2?this.flyoutData.strings.clippedCompletedSubTitleEnGb:this.flyoutData.strings.clippedSubTitleEnGb:this.isClippingV2?this.flyoutData.strings.clippedCompletedSubTitle:this.flyoutData.strings.clippedSubTitle}getClippingMainTitle(e,t,i=!1){const n=(0,Y.Ux)("SPAN"),o=this.utilities.formatPrice(e,this.market);if(n.textContent=(0,T.Ow)(`${r.iM.currency}${o}`,this.market),n.style.color="var(--text-green-savings-color)",this.utilities.shouldRenderSmallNotification()||(0,dt.tB)(this.flyoutData))n.style.fontSize="20px",n.style.lineHeight="26px",n.style.fontWeight="600";else{n.style.fontSize="26px",n.style.lineHeight="30px",n.style.fontWeight="600";const e=(0,Y.Ux)("BR");n.appendChild(e)}let a;this.market===Vm.engb?a=i?this.flyoutData.strings.clippingMainTitleEnGbUpTo:this.flyoutData.strings.clippingMainTitleEnGb:(a=i?this.utilities.shouldRenderSmallNotification()?this.flyoutData.strings.clippingMainTitleSmallNotificationUpTo:this.flyoutData.strings.clippingMainTitleUpTo:this.utilities.shouldRenderSmallNotification()?this.flyoutData.strings.clippingMainTitleSmallNotification:this.flyoutData.strings.clippingMainTitle,a=(0,dt.tB)(this.flyoutData)?this.flyoutData.strings.clippingMainTitleForSafari:a),(0,dt.tB)(this.flyoutData)&&(n.style.color="green",n.style.fontFamily="Segoe UI",n.style.fontSize="20px",n.style.lineHeight="24px",n.style.fontWeight="500",t.style.fontFamily="Segoe UI",t.style.fontSize="20px",t.style.lineHeight="24px",t.style.fontWeight="500"),(0,T.B7)(t,a,n)}getClippingSubTitleV2(e,t,i=!1){const n=(0,Y.Ux)("SPAN"),o=this.utilities.formatPrice(e,this.market);n.textContent=(0,T.Ow)(`${r.iM.currency}${o}`,this.market),n.style.color="var(--text-green-savings-color)",n.style.display="inline-block",n.style.fontSize="14px",n.style.lineHeight="20px",n.style.fontWeight="600";const a=(0,Y.Ux)("BR");n.appendChild(a);const s=i?this.flyoutData.strings.clippingSubTitleUpTo:this.flyoutData.strings.clippedSubTitleV2;(0,T.B7)(t,s,n)}getClippingDefaultTitle(){return this.market===Vm.engb?this.flyoutData.strings.defaultClippingTitleEnGb:this.flyoutData.strings.defaultClippingTitle}},jm=class extends Gm{async RenderNotification(){const e=await this.renderModule();if(e){const t=this.utilities.createNotificationModule(e.element,this.GetNotificationName(),this);return Promise.resolve(t)}return Promise.resolve(null)}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_COUPONS_CLIPPING]}async ShouldRenderNotification(){return await this.ShouldRenderModule()&&this.flyoutData.common.openedWith===r.Te.Auto&&this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_COUPONS_CLIPPING?Promise.resolve(!0):Promise.resolve(!1)}GetNotificationName(){return r.sM.COUPONCLIPPING}PostProcessingNotification(e,t){this.PostProcessing(r.ModuleNames.COUPONCLIPPING,0,t),this.populateMainHeader()}},zm=o(52961),Wm=o(61492),Km=o(44956),qm=o(89832);const Ym=(e,t)=>{const i=((e,t)=>Oh.jt(e,{...t,renderByDefault:null==t?void 0:t.required,elementType:void 0}))(e,t);var n;const o=(0,qm.Q)(null!==(n=null==i?void 0:i.as)&&void 0!==n?n:"button",i);return i&&o},Xm=ch.createContext(void 0),Jm={},Qm=(Xm.Provider,(e,t)=>{const{size:i}=null!==(n=ch.useContext(Xm))&&void 0!==n?n:Jm;var n;const{appearance:o="secondary",as:r="button",disabled:a=!1,disabledFocusable:s=!1,icon:l,iconPosition:c="before",shape:d="rounded",size:u=(null!=i?i:"medium")}=e,h=Oh.jt(l,{elementType:"span"});return{appearance:o,disabled:a,disabledFocusable:s,iconPosition:c,shape:d,size:u,iconOnly:Boolean((null==h?void 0:h.children)&&!e.children),components:{root:"button",icon:"span"},root:Oh.Bx((0,Qh.h)(r,Ym(e,{required:!0,defaultProps:{ref:t,type:"button"}})),{elementType:"button"}),icon:h}});var ev=o(12878),tv=o(90893);function iv(e,t,i){const n=function(e,t,i,n=ev.F){const o=n();return function(n){const{dir:r,renderer:a}=n,s="ltr"===r?e:t||e;return o(a,Array.isArray(i)?{r:i}:i),s}}(e,t,i,tv.F);return function(){const e=(0,Gh.s)(),t=(0,Xh.a)();return n({dir:e,renderer:t})}}const nv=iv("r1alrhcs",null,{r:[".r1alrhcs{align-items:center;box-sizing:border-box;display:inline-flex;justify-content:center;text-decoration-line:none;vertical-align:middle;margin:0;overflow:hidden;background-color:var(--colorNeutralBackground1);color:var(--colorNeutralForeground1);border:var(--strokeWidthThin) solid var(--colorNeutralStroke1);font-family:var(--fontFamilyBase);outline-style:none;padding:5px var(--spacingHorizontalM);min-width:96px;border-radius:var(--borderRadiusMedium);font-size:var(--fontSizeBase300);font-weight:var(--fontWeightSemibold);line-height:var(--lineHeightBase300);transition-duration:var(--durationFaster);transition-property:background,border,color;transition-timing-function:var(--curveEasyEase);}",".r1alrhcs:hover{background-color:var(--colorNeutralBackground1Hover);border-color:var(--colorNeutralStroke1Hover);color:var(--colorNeutralForeground1Hover);cursor:pointer;}",".r1alrhcs:hover:active{background-color:var(--colorNeutralBackground1Pressed);border-color:var(--colorNeutralStroke1Pressed);color:var(--colorNeutralForeground1Pressed);outline-style:none;}",".r1alrhcs[data-fui-focus-visible]{border-color:var(--colorStrokeFocus2);border-radius:var(--borderRadiusMedium);border-width:1px;outline:var(--strokeWidthThick) solid var(--colorTransparentStroke);box-shadow:0 0 0 var(--strokeWidthThin) var(--colorStrokeFocus2) inset;z-index:1;}"],s:["@media screen and (prefers-reduced-motion: reduce){.r1alrhcs{transition-duration:0.01ms;}}","@media (forced-colors: active){.r1alrhcs:focus{border-color:ButtonText;}.r1alrhcs:hover{background-color:HighlightText;border-color:Highlight;color:Highlight;forced-color-adjust:none;}.r1alrhcs:hover:active{background-color:HighlightText;border-color:Highlight;color:Highlight;forced-color-adjust:none;}}","@supports (-moz-appearance:button){.r1alrhcs[data-fui-focus-visible]{box-shadow:0 0 0 calc(var(--strokeWidthThin) + 0.25px) var(--colorStrokeFocus2) inset;}}"]}),ov=iv("rywnvv2",null,[".rywnvv2{align-items:center;display:inline-flex;justify-content:center;font-size:20px;height:20px;width:20px;--fui-Button__icon--spacing:var(--spacingHorizontalSNudge);}"]),rv=(0,Uh.s)({outline:{De3pzq:"f1c21dwh",Jwef8y:"fjxutwb",iro3zm:"fwiml72"},primary:{De3pzq:"ffp7eso",g2u3we:"f1p3nwhy",h3c5rm:["f11589ue","f1pdflbu"],B9xav0g:"f1q5o8ev",zhjwy3:["f1pdflbu","f11589ue"],sj55zd:"f1phragk",Jwef8y:"f15wkkf3",Bgoe8wy:"f1s2uweq",Bwzppfd:["fr80ssc","fecsdlb"],oetu4i:"f1ukrpxl",gg5e9n:["fecsdlb","fr80ssc"],Bi91k9c:"f1rq72xc",iro3zm:"fnp9lpt",b661bw:"f1h0usnq",Bk6r4ia:["fs4ktlq","fx2bmrt"],B9zn80p:"f16h9ulv",Bpld233:["fx2bmrt","fs4ktlq"],B2d53fq:"f1d6v5y2",Bsw6fvg:"f1rirnrt",Bjwas2f:"f1uu00uk",Bn1d65q:["fkvaka8","f9a0qzu"],Bxeuatn:"f1ux7til",n51gp8:["f9a0qzu","fkvaka8"],Bbusuzp:"f1lkg8j3",ycbfsm:"fkc42ay",Bqrx1nm:"fq7113v",pgvf35:"ff1wgvm",Bh7lczh:["fiob0tu","f1x4h75k"],dpv3f4:"f1j6scgf",Bpnjhaq:["f1x4h75k","fiob0tu"],ze5xyy:"f4xjyn1",g2kj27:"fbgcvur",Bf756sw:"f1ks1yx8",Bow2dr7:["f1o6qegi","fmxjhhp"],Bvhedfk:"fcnxywj",Gye4lf:["fmxjhhp","f1o6qegi"],pc6evw:"f9ddjv3"},secondary:{},subtle:{De3pzq:"fhovq9v",g2u3we:"f1p3nwhy",h3c5rm:["f11589ue","f1pdflbu"],B9xav0g:"f1q5o8ev",zhjwy3:["f1pdflbu","f11589ue"],sj55zd:"fkfq4zb",Jwef8y:"f1t94bn6",Bgoe8wy:"f1s2uweq",Bwzppfd:["fr80ssc","fecsdlb"],oetu4i:"f1ukrpxl",gg5e9n:["fecsdlb","fr80ssc"],Bi91k9c:"fnwyq0v",Bk3fhr4:"ft1hn21",Bmfj8id:"fuxngvv",Bbdnnc7:"fy5bs14",iro3zm:"fsv2rcd",b661bw:"f1h0usnq",Bk6r4ia:["fs4ktlq","fx2bmrt"],B9zn80p:"f16h9ulv",Bpld233:["fx2bmrt","fs4ktlq"],B2d53fq:"f1omzyqd",em6i61:"f1dfjoow",vm6p8p:"f1j98vj9",x3br3k:"fj8yq94",ze5xyy:"f4xjyn1",Bx3q9su:"f1et0tmh",pc6evw:"f9ddjv3",xd2cci:"f1wi8ngl"},transparent:{De3pzq:"f1c21dwh",g2u3we:"f1p3nwhy",h3c5rm:["f11589ue","f1pdflbu"],B9xav0g:"f1q5o8ev",zhjwy3:["f1pdflbu","f11589ue"],sj55zd:"fkfq4zb",Jwef8y:"fjxutwb",Bgoe8wy:"f1s2uweq",Bwzppfd:["fr80ssc","fecsdlb"],oetu4i:"f1ukrpxl",gg5e9n:["fecsdlb","fr80ssc"],Bi91k9c:"f139oj5f",Bk3fhr4:"ft1hn21",Bmfj8id:"fuxngvv",iro3zm:"fwiml72",b661bw:"f1h0usnq",Bk6r4ia:["fs4ktlq","fx2bmrt"],B9zn80p:"f16h9ulv",Bpld233:["fx2bmrt","fs4ktlq"],B2d53fq:"f1fg1p5m",em6i61:"f1dfjoow",vm6p8p:"f1j98vj9",Bqrx1nm:"f1tme0vf",ze5xyy:"f4xjyn1",g2kj27:"f18onu3q",pc6evw:"f9ddjv3"},circular:{Bbmb7ep:["f8fbkgy","f1nfllo7"],Beyfa6y:["f1nfllo7","f8fbkgy"],B7oj6ja:["f1djnp8u","f1s8kh49"],Btl43ni:["f1s8kh49","f1djnp8u"]},rounded:{},square:{Bbmb7ep:["fzi6hpg","fyowgf4"],Beyfa6y:["fyowgf4","fzi6hpg"],B7oj6ja:["f3fg2lr","f13av6d4"],Btl43ni:["f13av6d4","f3fg2lr"]},small:{Bf4jedk:"fh7ncta",z8tnut:"f1khb0e9",z189sj:["f1vdfbxk","f1f5gg8d"],Byoj8tv:"f1jnq6q7",uwmqm3:["f1f5gg8d","f1vdfbxk"],Bbmb7ep:["f1aa9q02","f16jpd5f"],Beyfa6y:["f16jpd5f","f1aa9q02"],B7oj6ja:["f1jar5jt","fyu767a"],Btl43ni:["fyu767a","f1jar5jt"],Be2twd7:"fy9rknc",Bhrd7zp:"figsok6",Bg96gwp:"fwrc4pm"},smallWithIcon:{Byoj8tv:"f1brlhvm",z8tnut:"f1sl3k7w"},medium:{},large:{Bf4jedk:"f14es27b",z8tnut:"fp9bwmr",z189sj:["fjodcmx","fhx4nu"],Byoj8tv:"f150uoa4",uwmqm3:["fhx4nu","fjodcmx"],Bbmb7ep:["f1aa9q02","f16jpd5f"],Beyfa6y:["f16jpd5f","f1aa9q02"],B7oj6ja:["f1jar5jt","fyu767a"],Btl43ni:["fyu767a","f1jar5jt"],Be2twd7:"fod5ikn",Bhrd7zp:"fl43uef",Bg96gwp:"faaz57k"},largeWithIcon:{Byoj8tv:"fy7v416",z8tnut:"f1a1bwwz"}},{d:[".f1c21dwh{background-color:var(--colorTransparentBackground);}",".ffp7eso{background-color:var(--colorBrandBackground);}",".f1p3nwhy{border-top-color:transparent;}",".f11589ue{border-right-color:transparent;}",".f1pdflbu{border-left-color:transparent;}",".f1q5o8ev{border-bottom-color:transparent;}",".f1phragk{color:var(--colorNeutralForegroundOnBrand);}",".fhovq9v{background-color:var(--colorSubtleBackground);}",".fkfq4zb{color:var(--colorNeutralForeground2);}",".f8fbkgy{border-bottom-right-radius:var(--borderRadiusCircular);}",".f1nfllo7{border-bottom-left-radius:var(--borderRadiusCircular);}",".f1djnp8u{border-top-right-radius:var(--borderRadiusCircular);}",".f1s8kh49{border-top-left-radius:var(--borderRadiusCircular);}",".fzi6hpg{border-bottom-right-radius:var(--borderRadiusNone);}",".fyowgf4{border-bottom-left-radius:var(--borderRadiusNone);}",".f3fg2lr{border-top-right-radius:var(--borderRadiusNone);}",".f13av6d4{border-top-left-radius:var(--borderRadiusNone);}",".fh7ncta{min-width:64px;}",".f1khb0e9{padding-top:3px;}",".f1vdfbxk{padding-right:var(--spacingHorizontalS);}",".f1f5gg8d{padding-left:var(--spacingHorizontalS);}",".f1jnq6q7{padding-bottom:3px;}",".f1aa9q02{border-bottom-right-radius:var(--borderRadiusMedium);}",".f16jpd5f{border-bottom-left-radius:var(--borderRadiusMedium);}",".f1jar5jt{border-top-right-radius:var(--borderRadiusMedium);}",".fyu767a{border-top-left-radius:var(--borderRadiusMedium);}",".fy9rknc{font-size:var(--fontSizeBase200);}",".figsok6{font-weight:var(--fontWeightRegular);}",".fwrc4pm{line-height:var(--lineHeightBase200);}",".f1brlhvm{padding-bottom:1px;}",".f1sl3k7w{padding-top:1px;}",".f14es27b{min-width:96px;}",".fp9bwmr{padding-top:8px;}",".fjodcmx{padding-right:var(--spacingHorizontalL);}",".fhx4nu{padding-left:var(--spacingHorizontalL);}",".f150uoa4{padding-bottom:8px;}",".fod5ikn{font-size:var(--fontSizeBase400);}",".fl43uef{font-weight:var(--fontWeightSemibold);}",".faaz57k{line-height:var(--lineHeightBase400);}",".fy7v416{padding-bottom:7px;}",".f1a1bwwz{padding-top:7px;}"],h:[".fjxutwb:hover{background-color:var(--colorTransparentBackgroundHover);}",".fwiml72:hover:active{background-color:var(--colorTransparentBackgroundPressed);}",".f15wkkf3:hover{background-color:var(--colorBrandBackgroundHover);}",".f1s2uweq:hover{border-top-color:transparent;}",".fr80ssc:hover{border-right-color:transparent;}",".fecsdlb:hover{border-left-color:transparent;}",".f1ukrpxl:hover{border-bottom-color:transparent;}",".f1rq72xc:hover{color:var(--colorNeutralForegroundOnBrand);}",".fnp9lpt:hover:active{background-color:var(--colorBrandBackgroundPressed);}",".f1h0usnq:hover:active{border-top-color:transparent;}",".fs4ktlq:hover:active{border-right-color:transparent;}",".fx2bmrt:hover:active{border-left-color:transparent;}",".f16h9ulv:hover:active{border-bottom-color:transparent;}",".f1d6v5y2:hover:active{color:var(--colorNeutralForegroundOnBrand);}",".f1t94bn6:hover{background-color:var(--colorSubtleBackgroundHover);}",".fnwyq0v:hover{color:var(--colorNeutralForeground2Hover);}",".ft1hn21:hover .fui-Icon-filled{display:inline;}",".fuxngvv:hover .fui-Icon-regular{display:none;}",".fy5bs14:hover .fui-Button__icon{color:var(--colorNeutralForeground2BrandHover);}",".fsv2rcd:hover:active{background-color:var(--colorSubtleBackgroundPressed);}",".f1omzyqd:hover:active{color:var(--colorNeutralForeground2Pressed);}",".f1dfjoow:hover:active .fui-Icon-filled{display:inline;}",".f1j98vj9:hover:active .fui-Icon-regular{display:none;}",".fj8yq94:hover:active .fui-Button__icon{color:var(--colorNeutralForeground2BrandPressed);}",".f139oj5f:hover{color:var(--colorNeutralForeground2BrandHover);}",".f1fg1p5m:hover:active{color:var(--colorNeutralForeground2BrandPressed);}"],m:[["@media (forced-colors: active){.f1rirnrt{background-color:Highlight;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1uu00uk{border-top-color:HighlightText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f9a0qzu{border-left-color:HighlightText;}.fkvaka8{border-right-color:HighlightText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1ux7til{border-bottom-color:HighlightText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1lkg8j3{color:HighlightText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.fkc42ay{forced-color-adjust:none;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.fq7113v:hover{background-color:HighlightText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.ff1wgvm:hover{border-top-color:Highlight;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1x4h75k:hover{border-left-color:Highlight;}.fiob0tu:hover{border-right-color:Highlight;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1j6scgf:hover{border-bottom-color:Highlight;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f4xjyn1:hover{color:Highlight;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.fbgcvur:hover:active{background-color:HighlightText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1ks1yx8:hover:active{border-top-color:Highlight;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1o6qegi:hover:active{border-right-color:Highlight;}.fmxjhhp:hover:active{border-left-color:Highlight;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.fcnxywj:hover:active{border-bottom-color:Highlight;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f9ddjv3:hover:active{color:Highlight;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1et0tmh:hover .fui-Button__icon{color:Highlight;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1wi8ngl:hover:active .fui-Button__icon{color:Highlight;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1tme0vf:hover{background-color:var(--colorTransparentBackground);}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f18onu3q:hover:active{background-color:var(--colorTransparentBackground);}}",{m:"(forced-colors: active)"}]]}),av=(0,Uh.s)({base:{De3pzq:"f1bg9a2p",g2u3we:"f1jj8ep1",h3c5rm:["f15xbau","fy0fskl"],B9xav0g:"f4ikngz",zhjwy3:["fy0fskl","f15xbau"],sj55zd:"f1s2aq7o",Bceei9c:"fdrzuqr",Bfinmwp:"f15x8b5r",Jwef8y:"f1falr9n",Bgoe8wy:"f12mpcsy",Bwzppfd:["f1gwvigk","f18rmfxp"],oetu4i:"f1jnshp0",gg5e9n:["f18rmfxp","f1gwvigk"],Bi91k9c:"fvgxktp",eoavqd:"fphbwmw",Bk3fhr4:"f19vpps7",Bmfj8id:"fv5swzo",Bbdnnc7:"f1al02dq",iro3zm:"f1t6o4dc",b661bw:"f10ztigi",Bk6r4ia:["f1ft5sdu","f1gzf82w"],B9zn80p:"f12zbtn2",Bpld233:["f1gzf82w","f1ft5sdu"],B2d53fq:"fcvwxyo",c3iz72:"f8w4c43",em6i61:"f1ol4fw6",vm6p8p:"f1q1lw4e",x3br3k:"f1dwjv2g"},highContrast:{Bsw6fvg:"f4lkoma",Bjwas2f:"fg455y9",Bn1d65q:["f1rvyvqg","f14g86mu"],Bxeuatn:"f1cwzwz",n51gp8:["f14g86mu","f1rvyvqg"],Bbusuzp:"f1dcs8yz",G867l3:"fjwq6ea",gdbnj:["f1lr3nhc","f1mbxvi6"],mxns5l:"fn5gmvv",o3nasb:["f1mbxvi6","f1lr3nhc"],Bqrx1nm:"f1vmkb5g",pgvf35:"f53ppgq",Bh7lczh:["f1663y11","f80fkiy"],dpv3f4:"f18v5270",Bpnjhaq:["f80fkiy","f1663y11"],ze5xyy:"f1kc2mi9",g2kj27:"f1y0svfh",Bf756sw:"fihuait",Bow2dr7:["fnxhupq","fyd6l6x"],Bvhedfk:"fx507ft",Gye4lf:["fyd6l6x","fnxhupq"],pc6evw:"fb3rf2x"},outline:{De3pzq:"f1c21dwh",Jwef8y:"f9ql6rf",iro3zm:"f3h1zc4"},primary:{g2u3we:"f1p3nwhy",h3c5rm:["f11589ue","f1pdflbu"],B9xav0g:"f1q5o8ev",zhjwy3:["f1pdflbu","f11589ue"],Bgoe8wy:"f1s2uweq",Bwzppfd:["fr80ssc","fecsdlb"],oetu4i:"f1ukrpxl",gg5e9n:["fecsdlb","fr80ssc"],b661bw:"f1h0usnq",Bk6r4ia:["fs4ktlq","fx2bmrt"],B9zn80p:"f16h9ulv",Bpld233:["fx2bmrt","fs4ktlq"]},secondary:{},subtle:{De3pzq:"f1c21dwh",g2u3we:"f1p3nwhy",h3c5rm:["f11589ue","f1pdflbu"],B9xav0g:"f1q5o8ev",zhjwy3:["f1pdflbu","f11589ue"],Jwef8y:"f9ql6rf",Bgoe8wy:"f1s2uweq",Bwzppfd:["fr80ssc","fecsdlb"],oetu4i:"f1ukrpxl",gg5e9n:["fecsdlb","fr80ssc"],iro3zm:"f3h1zc4",b661bw:"f1h0usnq",Bk6r4ia:["fs4ktlq","fx2bmrt"],B9zn80p:"f16h9ulv",Bpld233:["fx2bmrt","fs4ktlq"]},transparent:{De3pzq:"f1c21dwh",g2u3we:"f1p3nwhy",h3c5rm:["f11589ue","f1pdflbu"],B9xav0g:"f1q5o8ev",zhjwy3:["f1pdflbu","f11589ue"],Jwef8y:"f9ql6rf",Bgoe8wy:"f1s2uweq",Bwzppfd:["fr80ssc","fecsdlb"],oetu4i:"f1ukrpxl",gg5e9n:["fecsdlb","fr80ssc"],iro3zm:"f3h1zc4",b661bw:"f1h0usnq",Bk6r4ia:["fs4ktlq","fx2bmrt"],B9zn80p:"f16h9ulv",Bpld233:["fx2bmrt","fs4ktlq"]}},{d:[".f1bg9a2p{background-color:var(--colorNeutralBackgroundDisabled);}",".f1jj8ep1{border-top-color:var(--colorNeutralStrokeDisabled);}",".f15xbau{border-right-color:var(--colorNeutralStrokeDisabled);}",".fy0fskl{border-left-color:var(--colorNeutralStrokeDisabled);}",".f4ikngz{border-bottom-color:var(--colorNeutralStrokeDisabled);}",".f1s2aq7o{color:var(--colorNeutralForegroundDisabled);}",".fdrzuqr{cursor:not-allowed;}",".f15x8b5r .fui-Button__icon{color:var(--colorNeutralForegroundDisabled);}",".f1c21dwh{background-color:var(--colorTransparentBackground);}",".f1p3nwhy{border-top-color:transparent;}",".f11589ue{border-right-color:transparent;}",".f1pdflbu{border-left-color:transparent;}",".f1q5o8ev{border-bottom-color:transparent;}"],h:[".f1falr9n:hover{background-color:var(--colorNeutralBackgroundDisabled);}",".f12mpcsy:hover{border-top-color:var(--colorNeutralStrokeDisabled);}",".f1gwvigk:hover{border-right-color:var(--colorNeutralStrokeDisabled);}",".f18rmfxp:hover{border-left-color:var(--colorNeutralStrokeDisabled);}",".f1jnshp0:hover{border-bottom-color:var(--colorNeutralStrokeDisabled);}",".fvgxktp:hover{color:var(--colorNeutralForegroundDisabled);}",".fphbwmw:hover{cursor:not-allowed;}",".f19vpps7:hover .fui-Icon-filled{display:none;}",".fv5swzo:hover .fui-Icon-regular{display:inline;}",".f1al02dq:hover .fui-Button__icon{color:var(--colorNeutralForegroundDisabled);}",".f1t6o4dc:hover:active{background-color:var(--colorNeutralBackgroundDisabled);}",".f10ztigi:hover:active{border-top-color:var(--colorNeutralStrokeDisabled);}",".f1ft5sdu:hover:active{border-right-color:var(--colorNeutralStrokeDisabled);}",".f1gzf82w:hover:active{border-left-color:var(--colorNeutralStrokeDisabled);}",".f12zbtn2:hover:active{border-bottom-color:var(--colorNeutralStrokeDisabled);}",".fcvwxyo:hover:active{color:var(--colorNeutralForegroundDisabled);}",".f8w4c43:hover:active{cursor:not-allowed;}",".f1ol4fw6:hover:active .fui-Icon-filled{display:none;}",".f1q1lw4e:hover:active .fui-Icon-regular{display:inline;}",".f1dwjv2g:hover:active .fui-Button__icon{color:var(--colorNeutralForegroundDisabled);}",".f9ql6rf:hover{background-color:var(--colorTransparentBackground);}",".f3h1zc4:hover:active{background-color:var(--colorTransparentBackground);}",".f1s2uweq:hover{border-top-color:transparent;}",".fr80ssc:hover{border-right-color:transparent;}",".fecsdlb:hover{border-left-color:transparent;}",".f1ukrpxl:hover{border-bottom-color:transparent;}",".f1h0usnq:hover:active{border-top-color:transparent;}",".fs4ktlq:hover:active{border-right-color:transparent;}",".fx2bmrt:hover:active{border-left-color:transparent;}",".f16h9ulv:hover:active{border-bottom-color:transparent;}"],m:[["@media (forced-colors: active){.f4lkoma{background-color:ButtonFace;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.fg455y9{border-top-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f14g86mu{border-left-color:GrayText;}.f1rvyvqg{border-right-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1cwzwz{border-bottom-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1dcs8yz{color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.fjwq6ea:focus{border-top-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1lr3nhc:focus{border-right-color:GrayText;}.f1mbxvi6:focus{border-left-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.fn5gmvv:focus{border-bottom-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1vmkb5g:hover{background-color:ButtonFace;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f53ppgq:hover{border-top-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1663y11:hover{border-right-color:GrayText;}.f80fkiy:hover{border-left-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f18v5270:hover{border-bottom-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1kc2mi9:hover{color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1y0svfh:hover:active{background-color:ButtonFace;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.fihuait:hover:active{border-top-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.fnxhupq:hover:active{border-right-color:GrayText;}.fyd6l6x:hover:active{border-left-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.fx507ft:hover:active{border-bottom-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.fb3rf2x:hover:active{color:GrayText;}}",{m:"(forced-colors: active)"}]]}),sv=(0,Uh.s)({circular:{kdpuga:["fanj13w","f1gou5sz"],Bw81rd7:["f1gou5sz","fanj13w"],B6xbmo0:["fulf6x3","foeb2x"],dm238s:["foeb2x","fulf6x3"]},rounded:{},square:{kdpuga:["f1ndz5i7","f1co4qro"],Bw81rd7:["f1co4qro","f1ndz5i7"],B6xbmo0:["f146y5a9","f1k2ftg"],dm238s:["f1k2ftg","f146y5a9"]},primary:{B8q5s1w:"f17t0x8g",Bci5o5g:["f194v5ow","fk7jm04"],n8qw10:"f1qgg65p",Bdrgwmp:["fk7jm04","f194v5ow"],j6ew2k:["fhgccpy","fjo7pq6"],he4mth:"f32wu9k",Byr4aka:"fu5nqqq",lks7q5:["f13prjl2","f1nl83rv"],Bnan3qt:"f1czftr5",k1dn9:["f1nl83rv","f13prjl2"],Boium3a:["f12k37oa","fdnykm2"],tm8e47:"fr96u23"},small:{kdpuga:["fg3gtdo","fwii5mg"],Bw81rd7:["fwii5mg","fg3gtdo"],B6xbmo0:["f1palphq","f12nxie7"],dm238s:["f12nxie7","f1palphq"]},medium:{},large:{kdpuga:["ft3lys4","f1la4x2g"],Bw81rd7:["f1la4x2g","ft3lys4"],B6xbmo0:["f156y0zm","fakimq4"],dm238s:["fakimq4","f156y0zm"]}},{d:[".fanj13w[data-fui-focus-visible]{border-bottom-right-radius:var(--borderRadiusCircular);}",".f1gou5sz[data-fui-focus-visible]{border-bottom-left-radius:var(--borderRadiusCircular);}",".fulf6x3[data-fui-focus-visible]{border-top-right-radius:var(--borderRadiusCircular);}",".foeb2x[data-fui-focus-visible]{border-top-left-radius:var(--borderRadiusCircular);}",".f1ndz5i7[data-fui-focus-visible]{border-bottom-right-radius:var(--borderRadiusNone);}",".f1co4qro[data-fui-focus-visible]{border-bottom-left-radius:var(--borderRadiusNone);}",".f146y5a9[data-fui-focus-visible]{border-top-right-radius:var(--borderRadiusNone);}",".f1k2ftg[data-fui-focus-visible]{border-top-left-radius:var(--borderRadiusNone);}",".f17t0x8g[data-fui-focus-visible]{border-top-color:var(--colorStrokeFocus2);}",".f194v5ow[data-fui-focus-visible]{border-right-color:var(--colorStrokeFocus2);}",".fk7jm04[data-fui-focus-visible]{border-left-color:var(--colorStrokeFocus2);}",".f1qgg65p[data-fui-focus-visible]{border-bottom-color:var(--colorStrokeFocus2);}",".fhgccpy[data-fui-focus-visible]{box-shadow:var(--shadow2),0 0 0 var(--strokeWidthThin) var(--colorStrokeFocus2) inset,0 0 0 var(--strokeWidthThick) var(--colorNeutralForegroundOnBrand) inset;}",".fjo7pq6[data-fui-focus-visible]{box-shadow:var(--shadow2),0 0 0 var(--strokeWidthThin) var(--colorStrokeFocus2) inset,0 0 0 var(--strokeWidthThick) var(--colorNeutralForegroundOnBrand) inset;}",".f32wu9k[data-fui-focus-visible]:hover{box-shadow:var(--shadow2),0 0 0 var(--strokeWidthThin) var(--colorStrokeFocus2) inset;}",".fu5nqqq[data-fui-focus-visible]:hover{border-top-color:var(--colorStrokeFocus2);}",".f13prjl2[data-fui-focus-visible]:hover{border-right-color:var(--colorStrokeFocus2);}",".f1nl83rv[data-fui-focus-visible]:hover{border-left-color:var(--colorStrokeFocus2);}",".f1czftr5[data-fui-focus-visible]:hover{border-bottom-color:var(--colorStrokeFocus2);}",".fg3gtdo[data-fui-focus-visible]{border-bottom-right-radius:var(--borderRadiusSmall);}",".fwii5mg[data-fui-focus-visible]{border-bottom-left-radius:var(--borderRadiusSmall);}",".f1palphq[data-fui-focus-visible]{border-top-right-radius:var(--borderRadiusSmall);}",".f12nxie7[data-fui-focus-visible]{border-top-left-radius:var(--borderRadiusSmall);}",".ft3lys4[data-fui-focus-visible]{border-bottom-right-radius:var(--borderRadiusLarge);}",".f1la4x2g[data-fui-focus-visible]{border-bottom-left-radius:var(--borderRadiusLarge);}",".f156y0zm[data-fui-focus-visible]{border-top-right-radius:var(--borderRadiusLarge);}",".fakimq4[data-fui-focus-visible]{border-top-left-radius:var(--borderRadiusLarge);}"],t:["@supports (-moz-appearance:button){.f12k37oa[data-fui-focus-visible]{box-shadow:var(--shadow2),0 0 0 calc(var(--strokeWidthThin) + 0.25px) var(--colorStrokeFocus2) inset,0 0 0 var(--strokeWidthThick) var(--colorNeutralForegroundOnBrand) inset;}.fdnykm2[data-fui-focus-visible]{box-shadow:var(--shadow2),0 0 0 calc(var(--strokeWidthThin) + 0.25px) var(--colorStrokeFocus2) inset,0 0 0 var(--strokeWidthThick) var(--colorNeutralForegroundOnBrand) inset;}}","@supports (-moz-appearance:button){.fr96u23[data-fui-focus-visible]:hover{box-shadow:var(--shadow2),0 0 0 calc(var(--strokeWidthThin) + 0.25px) var(--colorStrokeFocus2) inset;}}"]}),lv=(0,Uh.s)({small:{z8tnut:"f1sl3k7w",z189sj:["f136y8j8","f10xn8zz"],Byoj8tv:"f1brlhvm",uwmqm3:["f10xn8zz","f136y8j8"],Bf4jedk:"f17fgpbq",B2u0y6b:"f1jt17bm"},medium:{z8tnut:"f1sbtcvk",z189sj:["fwiuce9","f15vdbe4"],Byoj8tv:"fdghr9",uwmqm3:["f15vdbe4","fwiuce9"],Bf4jedk:"fwbmr0d",B2u0y6b:"f44c6la"},large:{z8tnut:"f1a1bwwz",z189sj:["f18k1jr3","f1rtp3s9"],Byoj8tv:"fy7v416",uwmqm3:["f1rtp3s9","f18k1jr3"],Bf4jedk:"f12clzc2",B2u0y6b:"fjy1crr"}},{d:[".f1sl3k7w{padding-top:1px;}",".f136y8j8{padding-right:1px;}",".f10xn8zz{padding-left:1px;}",".f1brlhvm{padding-bottom:1px;}",".f17fgpbq{min-width:24px;}",".f1jt17bm{max-width:24px;}",".f1sbtcvk{padding-top:5px;}",".fwiuce9{padding-right:5px;}",".f15vdbe4{padding-left:5px;}",".fdghr9{padding-bottom:5px;}",".fwbmr0d{min-width:32px;}",".f44c6la{max-width:32px;}",".f1a1bwwz{padding-top:7px;}",".f18k1jr3{padding-right:7px;}",".f1rtp3s9{padding-left:7px;}",".fy7v416{padding-bottom:7px;}",".f12clzc2{min-width:40px;}",".fjy1crr{max-width:40px;}"]}),cv=(0,Uh.s)({small:{Be2twd7:"fe5j1ua",Bqenvij:"fjamq6b",a9b677:"f64fuq3",Bqrlyyl:"fbaiahx"},medium:{},large:{Be2twd7:"f1rt2boy",Bqenvij:"frvgh55",a9b677:"fq4mcun",Bqrlyyl:"f1exjqw5"},before:{t21cq0:["f1nizpg2","f1a695kz"]},after:{Frg6f3:["f1a695kz","f1nizpg2"]}},{d:[".fe5j1ua{font-size:20px;}",".fjamq6b{height:20px;}",".f64fuq3{width:20px;}",".fbaiahx{--fui-Button__icon--spacing:var(--spacingHorizontalXS);}",".f1rt2boy{font-size:24px;}",".frvgh55{height:24px;}",".fq4mcun{width:24px;}",".f1exjqw5{--fui-Button__icon--spacing:var(--spacingHorizontalSNudge);}",".f1nizpg2{margin-right:var(--fui-Button__icon--spacing);}",".f1a695kz{margin-left:var(--fui-Button__icon--spacing);}"]}),dv=ch.forwardRef(((e,t)=>{const i=Qm(e,t);return(e=>{const t=nv(),i=ov(),n=rv(),o=av(),r=sv(),a=lv(),s=cv(),{appearance:l,disabled:c,disabledFocusable:d,icon:u,iconOnly:h,iconPosition:p,shape:g,size:f}=e;e.root.className=(0,Hh.z)("fui-Button",t,l&&n[l],n[f],u&&"small"===f&&n.smallWithIcon,u&&"large"===f&&n.largeWithIcon,n[g],(c||d)&&o.base,(c||d)&&o.highContrast,l&&(c||d)&&o[l],"primary"===l&&r.primary,r[f],r[g],h&&a[f],e.root.className),e.icon&&(e.icon.className=(0,Hh.z)("fui-Button__icon",i,!!e.root.children&&s[p],s[f],e.icon.className))})(i),(0,Fh.oj)("useButtonStyles_unstable")(i),(e=>{(0,Bh.a)(e);const{iconOnly:t,iconPosition:i}=e;return(0,Mh.BX)(e.root,{children:["after"!==i&&e.icon&&(0,Mh.tZ)(e.icon,{}),!t&&e.root.children,"after"===i&&e.icon&&(0,Mh.tZ)(e.icon,{})]})})(i)}));function uv(e){return uv="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},uv(e)}function hv(e,t,i){return(t=function(e){var t=function(e,t){if("object"!==uv(e)||null===e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var n=i.call(e,"string");if("object"!==uv(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===uv(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}dv.displayName="Button";var pv,gv={exports:{}},fv={};gv.exports=function(){if(pv)return fv;pv=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),r=Symbol.for("react.provider"),a=Symbol.for("react.context"),s=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),c=Symbol.for("react.memo"),d=Symbol.for("react.lazy"),u=Symbol.iterator,h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},p=Object.assign,g={};function f(e,t,i){this.props=e,this.context=t,this.refs=g,this.updater=i||h}function m(){}function v(e,t,i){this.props=e,this.context=t,this.refs=g,this.updater=i||h}f.prototype.isReactComponent={},f.prototype.setState=function(e,t){if("object"!=typeof e&&"function"!=typeof e&&null!=e)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")},f.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},m.prototype=f.prototype;var y=v.prototype=new m;y.constructor=v,p(y,f.prototype),y.isPureReactComponent=!0;var C=Array.isArray,b=Object.prototype.hasOwnProperty,S={current:null},x={key:!0,ref:!0,__self:!0,__source:!0};function T(t,i,n){var o,r={},a=null,s=null;if(null!=i)for(o in void 0!==i.ref&&(s=i.ref),void 0!==i.key&&(a=""+i.key),i)b.call(i,o)&&!x.hasOwnProperty(o)&&(r[o]=i[o]);var l=arguments.length-2;if(1===l)r.children=n;else if(1<l){for(var c=Array(l),d=0;d<l;d++)c[d]=arguments[d+2];r.children=c}if(t&&t.defaultProps)for(o in l=t.defaultProps)void 0===r[o]&&(r[o]=l[o]);return{$$typeof:e,type:t,key:a,ref:s,props:r,_owner:S.current}}function w(t){return"object"==typeof t&&null!==t&&t.$$typeof===e}var O=/\/+/g;function P(e,t){return"object"==typeof e&&null!==e&&null!=e.key?function(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,(function(e){return t[e]}))}(""+e.key):t.toString(36)}function A(i,n,o,r,a){var s=typeof i;"undefined"!==s&&"boolean"!==s||(i=null);var l=!1;if(null===i)l=!0;else switch(s){case"string":case"number":l=!0;break;case"object":switch(i.$$typeof){case e:case t:l=!0}}if(l)return a=a(l=i),i=""===r?"."+P(l,0):r,C(a)?(o="",null!=i&&(o=i.replace(O,"$&/")+"/"),A(a,n,o,"",(function(e){return e}))):null!=a&&(w(a)&&(a=function(t,i){return{$$typeof:e,type:t.type,key:i,ref:t.ref,props:t.props,_owner:t._owner}}(a,o+(!a.key||l&&l.key===a.key?"":(""+a.key).replace(O,"$&/")+"/")+i)),n.push(a)),1;if(l=0,r=""===r?".":r+":",C(i))for(var c=0;c<i.length;c++){var d=r+P(s=i[c],c);l+=A(s,n,o,d,a)}else if(d=function(e){return null===e||"object"!=typeof e?null:"function"==typeof(e=u&&e[u]||e["@@iterator"])?e:null}(i),"function"==typeof d)for(i=d.call(i),c=0;!(s=i.next()).done;)l+=A(s=s.value,n,o,d=r+P(s,c++),a);else if("object"===s)throw n=String(i),Error("Objects are not valid as a React child (found: "+("[object Object]"===n?"object with keys {"+Object.keys(i).join(", ")+"}":n)+"). If you meant to render a collection of children, use an array instead.");return l}function E(e,t,i){if(null==e)return e;var n=[],o=0;return A(e,n,"","",(function(e){return t.call(i,e,o++)})),n}function k(e){if(-1===e._status){var t=e._result;(t=t()).then((function(t){0!==e._status&&-1!==e._status||(e._status=1,e._result=t)}),(function(t){0!==e._status&&-1!==e._status||(e._status=2,e._result=t)})),-1===e._status&&(e._status=0,e._result=t)}if(1===e._status)return e._result.default;throw e._result}var I={current:null},D={transition:null},_={ReactCurrentDispatcher:I,ReactCurrentBatchConfig:D,ReactCurrentOwner:S};return fv.Children={map:E,forEach:function(e,t,i){E(e,(function(){t.apply(this,arguments)}),i)},count:function(e){var t=0;return E(e,(function(){t++})),t},toArray:function(e){return E(e,(function(e){return e}))||[]},only:function(e){if(!w(e))throw Error("React.Children.only expected to receive a single React element child.");return e}},fv.Component=f,fv.Fragment=i,fv.Profiler=o,fv.PureComponent=v,fv.StrictMode=n,fv.Suspense=l,fv.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=_,fv.cloneElement=function(t,i,n){if(null==t)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+t+".");var o=p({},t.props),r=t.key,a=t.ref,s=t._owner;if(null!=i){if(void 0!==i.ref&&(a=i.ref,s=S.current),void 0!==i.key&&(r=""+i.key),t.type&&t.type.defaultProps)var l=t.type.defaultProps;for(c in i)b.call(i,c)&&!x.hasOwnProperty(c)&&(o[c]=void 0===i[c]&&void 0!==l?l[c]:i[c])}var c=arguments.length-2;if(1===c)o.children=n;else if(1<c){l=Array(c);for(var d=0;d<c;d++)l[d]=arguments[d+2];o.children=l}return{$$typeof:e,type:t.type,key:r,ref:a,props:o,_owner:s}},fv.createContext=function(e){return(e={$$typeof:a,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null}).Provider={$$typeof:r,_context:e},e.Consumer=e},fv.createElement=T,fv.createFactory=function(e){var t=T.bind(null,e);return t.type=e,t},fv.createRef=function(){return{current:null}},fv.forwardRef=function(e){return{$$typeof:s,render:e}},fv.isValidElement=w,fv.lazy=function(e){return{$$typeof:d,_payload:{_status:-1,_result:e},_init:k}},fv.memo=function(e,t){return{$$typeof:c,type:e,compare:void 0===t?null:t}},fv.startTransition=function(e){var t=D.transition;D.transition={};try{e()}finally{D.transition=t}},fv.unstable_act=function(){throw Error("act(...) is not supported in production builds of React.")},fv.useCallback=function(e,t){return I.current.useCallback(e,t)},fv.useContext=function(e){return I.current.useContext(e)},fv.useDebugValue=function(){},fv.useDeferredValue=function(e){return I.current.useDeferredValue(e)},fv.useEffect=function(e,t){return I.current.useEffect(e,t)},fv.useId=function(){return I.current.useId()},fv.useImperativeHandle=function(e,t,i){return I.current.useImperativeHandle(e,t,i)},fv.useInsertionEffect=function(e,t){return I.current.useInsertionEffect(e,t)},fv.useLayoutEffect=function(e,t){return I.current.useLayoutEffect(e,t)},fv.useMemo=function(e,t){return I.current.useMemo(e,t)},fv.useReducer=function(e,t,i){return I.current.useReducer(e,t,i)},fv.useRef=function(e){return I.current.useRef(e)},fv.useState=function(e){return I.current.useState(e)},fv.useSyncExternalStore=function(e,t,i){return I.current.useSyncExternalStore(e,t,i)},fv.useTransition=function(){return I.current.useTransition()},fv.version="18.2.0",fv}();var mv,vv=(mv=gv.exports)&&mv.__esModule&&Object.prototype.hasOwnProperty.call(mv,"default")?mv.default:mv;function yv(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Cv(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?yv(Object(i),!0).forEach((function(t){hv(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):yv(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var bv=(0,Zg.Z)({wrapperLayout:Cv({display:"flex",flexDirection:"row",height:"100px"},zm.q5.overflow("hidden")),startSlot:{backgroundColor:Wm.T.colorNeutralBackground1,display:"flex",flexDirection:"row"},endSlot:{display:"flex",flexGrow:1,minWidth:"0px",flexDirection:"column"},titleSlot:{display:"flex",flexGrow:1},endTopSlot:{backgroundColor:Wm.T.colorNeutralBackground1,justifyContent:"space-between",display:"flex",flexDirection:"row"},endBottomSlot:{backgroundColor:Wm.T.colorNeutralBackground1,height:"100%",display:"flex",flexDirection:"column",justifyContent:"stretch"},tear:{height:"100px",width:"11px"},tearOffsetLeft:{marginLeft:"-5px"},tail:{height:"100px",width:"12px"}}),Sv=(0,Zg.Z)({wrapperLayout:Cv({display:"flex",flexDirection:"row",height:"70px"},zm.q5.overflow("hidden")),startSlot:{backgroundColor:Wm.T.colorNeutralBackground1,display:"flex",flexDirection:"row"},middleSlot:{display:"flex",flexGrow:1,minWidth:"0px",backgroundColor:Wm.T.colorNeutralBackground1,flexDirection:"column"},endSlot:{display:"flex",backgroundColor:Wm.T.colorNeutralBackground1,flexDirection:"column"},tear:{height:"70px",width:"11px"},tail:{height:"70px",width:"9px"}}),xv=(0,Zg.Z)({container:{minWidth:"0px",minHeight:"0px"},containerHoverAnimation:{":hover":Cv(Cv({},zm.q5.transition("all","450ms","cubic-bezier(0.33,0,0.67,1)")),{},{transform:"translateY(-1px)",filter:"drop-shadow(0px 0px 4px rgba(0, 0, 0, 0.10))"})},containerClickable:{cursor:"pointer"},containerActiveAnimation:{":active":Cv({transform:"translateY(1px)"},zm.q5.transition("all","150ms","cubic-bezier(0.33,0,0.67,1)"))},wrapperDecoration:Cv(Cv({fill:Wm.T.colorNeutralBackground1},zm.q5.borderRadius("8px","0px","0px","8px")),{},{filter:"drop-shadow(0px 1px 1px rgba(0, 0, 0, 0.14)) drop-shadow(0px 0px 2px rgba(0, 0, 0, 0.12))"})}),Tv=function(e){var t=e.type,i=void 0===t?"regular":t,n=e.width,o=e.titleSlot,r=e.imageSlot,a=e.contentSlot,s=e.actionSlot,l=e.couponDescription,c=e.disableAnimation,d=e.baseOnClick,u=xv(),h=bv(),p=Sv(),g=(0,Hh.z)(u.container,d&&u.containerClickable,d&&!c&&u.containerHoverAnimation,!c&&u.containerActiveAnimation);return vv.createElement("div",{className:g,style:{width:n},onClick:d&&d,title:l&&l},"compact"===i&&vv.createElement("div",{className:(0,Hh.z)(u.wrapperDecoration,h.wrapperLayout)},r&&vv.createElement(vv.Fragment,null,vv.createElement("div",{className:h.startSlot},r),vv.createElement("div",{className:h.tear},vv.createElement("svg",{width:"11",height:"100",viewBox:"0 0 11 100",xmlns:"http://www.w3.org/2000/svg"},vv.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M4 2.50003C4 1.11932 2.88071 3.15905e-05 1.5 3.15905e-05H1C0.447715 3.15905e-05 0 0.000279114 0 0.000279114V100C0 100 0.447715 100 1 100H1.5C2.88071 100 4 98.8808 4 97.5C4 96.6716 4.67157 96 5.5 96C6.32843 96 7 96.6716 7 97.5C7 98.8808 8.11929 100 9.5 100H10C10.5523 100 11 100 11 100V0C11 0 10.5523 3.15905e-05 10 3.15905e-05H9.5C8.11929 3.15905e-05 7 1.11932 7 2.50003C7 3.32846 6.32843 4.00003 5.5 4.00003C4.67157 4.00003 4 3.32846 4 2.50003ZM5.5 12C6.32843 12 7 12.6716 7 13.5V16.5C7 17.3285 6.32843 18 5.5 18C4.67157 18 4 17.3285 4 16.5V13.5C4 12.6716 4.67157 12 5.5 12ZM7 27.5C7 26.6716 6.32843 26 5.5 26C4.67157 26 4 26.6716 4 27.5V30.5C4 31.3285 4.67157 32 5.5 32C6.32843 32 7 31.3285 7 30.5V27.5ZM5.5 40C6.32843 40 7 40.6716 7 41.5V44.5C7 45.3285 6.32843 46 5.5 46C4.67157 46 4 45.3285 4 44.5V41.5C4 40.6716 4.67157 40 5.5 40ZM7 55.5C7 54.6716 6.32843 54 5.5 54C4.67157 54 4 54.6716 4 55.5V58.5C4 59.3285 4.67157 60 5.5 60C6.32843 60 7 59.3285 7 58.5V55.5ZM5.5 68C6.32843 68 7 68.6716 7 69.5V72.5C7 73.3285 6.32843 74 5.5 74C4.67157 74 4 73.3285 4 72.5V69.5C4 68.6716 4.67157 68 5.5 68ZM7 83.5C7 82.6716 6.32843 82 5.5 82C4.67157 82 4 82.6716 4 83.5V86.5C4 87.3285 4.67157 88 5.5 88C6.32843 88 7 87.3285 7 86.5V83.5Z"})))),vv.createElement("div",{className:h.endSlot},vv.createElement("div",{className:h.endTopSlot},o&&vv.createElement("div",{className:h.titleSlot},o),s&&s),vv.createElement("div",{className:h.endBottomSlot},a&&a)),vv.createElement("div",{className:h.tail},vv.createElement("svg",{width:"12",height:"100",viewBox:"0 0 12 100",xmlns:"http://www.w3.org/2000/svg"},vv.createElement("path",{d:"M0 0.000420285C0 33.3335 0.000687227 98.9583 0.000317097 100H4C8.41828 100 12 96.2691 12 91.6667V67.1904C12 65.069 10.423 63.3542 8.56064 62.4955C4.29532 60.5289 1.31054 56.0009 1.31054 50.7294C1.31054 45.4578 4.29532 40.9299 8.56064 38.9632C10.423 38.1046 12 36.3898 12 34.2683V8.3337C12 3.73135 8.41828 0.000399393 4 0.000399393C-6 0.000399393 10 -0.000513011 0 0.000420285Z"})))),"regular"===i&&vv.createElement("div",{className:(0,Hh.z)(u.wrapperDecoration,p.wrapperLayout)},o&&vv.createElement(vv.Fragment,null,vv.createElement("div",{className:p.startSlot},o),vv.createElement("div",{className:p.tear},vv.createElement("svg",{width:"11",height:"70",viewBox:"0 0 11 70",xmlns:"http://www.w3.org/2000/svg"},vv.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M0.000353813 5.22733e-05H2.50043C3.32886 5.22733e-05 4.00043 0.671625 4.00043 1.50005C4.00043 2.32848 4.672 3.00005 5.50043 3.00005C6.32887 3.00005 7.00043 2.32848 7.00043 1.50005C7.00043 0.671625 7.67202 5.22733e-05 8.50044 5.22733e-05L11.0005 0V70.0001H8.50044C7.67201 70.0001 7.00043 69.3285 7.00043 68.5001C7.00043 67.6716 6.32887 67.0001 5.50043 67.0001C4.672 67.0001 4.00043 67.6716 4.00043 68.5001C4.00043 69.3285 3.32886 70.0001 2.50043 70.0001H0C0 63.5621 0.000353813 5.22733e-05 0.000353813 5.22733e-05ZM7.00043 12.5001C7.00043 11.6716 6.32887 11.0001 5.50043 11.0001C4.672 11.0001 4.00043 11.6716 4.00043 12.5001V15.5001C4.00043 16.3285 4.672 17.0001 5.50043 17.0001C6.32887 17.0001 7.00043 16.3285 7.00043 15.5001V12.5001ZM5.50043 25.0001C6.32887 25.0001 7.00043 25.6716 7.00043 26.5001V29.5001C7.00043 30.3285 6.32887 31.0001 5.50043 31.0001C4.672 31.0001 4.00043 30.3285 4.00043 29.5001V26.5001C4.00043 25.6716 4.672 25.0001 5.50043 25.0001ZM7.00043 40.5C7.00043 39.6716 6.32887 39 5.50043 39C4.672 39 4.00043 39.6716 4.00043 40.5V43.5C4.00043 44.3285 4.672 45 5.50043 45C6.32887 45 7.00043 44.3285 7.00043 43.5V40.5ZM5.50043 53C6.32887 53 7.00043 53.6716 7.00043 54.5V57.5C7.00043 58.3285 6.32887 59 5.50043 59C4.672 59 4.00043 58.3285 4.00043 57.5V54.5C4.00043 53.6716 4.672 53 5.50043 53Z"})))),a&&vv.createElement("div",{className:p.middleSlot},a),s&&vv.createElement("div",{className:p.endSlot},s),vv.createElement("div",{className:p.tail},vv.createElement("svg",{width:"9",height:"70",viewBox:"0 0 9 70",xmlns:"http://www.w3.org/2000/svg"},vv.createElement("path",{d:"M0.000976562 0.0002942C0.000976562 23.3335 0.00149198 69.2708 0.00121438 70H3.00098C6.31468 70 9.00097 67.3883 9.00097 64.1667V47.0333C9.00097 45.5483 7.81819 44.3479 6.42145 43.7469C3.22246 42.3702 0.983881 39.2006 0.983881 35.5106C0.983881 31.8205 3.22246 28.6509 6.42146 27.2743C7.8182 26.6732 9.00098 25.4728 9.00098 23.9878V5.83359C9.00098 2.61194 6.31469 0.000279575 3.00098 0.000279575C-4.49902 0.000279575 7.50097 -0.000359108 0.000976562 0.0002942Z"})))))};function wv(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Ov(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?wv(Object(i),!0).forEach((function(t){hv(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):wv(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}Tv.defaultProps={type:"regular",width:"100%",disableAnimation:!0,titleBackgroundColor:"transparent"};var Pv=(0,Zg.Z)({container:{paddingLeft:Wm.T.spacingHorizontalM,paddingTop:Wm.T.spacingVerticalS,display:"flex",flexDirection:"column"},tearOffsetLeft:{marginLeft:"-5px"},topSlot:{},middleContainer:{display:"flex",flexDirection:"row",columnGap:Wm.T.spacingVerticalXS,alignItems:"flex-start"},middleSlot:Ov(Ov({},Km.w.title3),{},{lineHeight:"unset",color:Wm.T.colorBrandForeground1}),middleSuffixSlot:Ov(Ov({},Km.w.caption1Strong),{},{color:Wm.T.colorNeutralForeground1}),bottomSlot:Ov(Ov({},Km.w.caption1Strong),{},{color:Wm.T.colorNeutralForeground1})}),Av=(0,Zg.Z)({container:Ov(Ov({width:"90px",display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",backgroundColor:"red",marginLeft:Wm.T.spacingHorizontalXS},zm.q5.marginBlock(Wm.T.spacingHorizontalXS)),zm.q5.borderRadius(Wm.T.borderRadiusMedium)),topSlot:Ov(Ov({},Km.w.caption2Strong),{},{color:Wm.T.colorNeutralForeground3}),middleContainer:{display:"flex",flexDirection:"row",columnGap:Wm.T.spacingVerticalXS,alignItems:"flex-start"},middleSlot:Ov(Ov({},Km.w.title3),{},{lineHeight:"unset",color:Wm.T.colorBrandForeground1}),middleSuffixSlot:Ov(Ov({},Km.w.caption1Strong),{},{color:Wm.T.colorNeutralForeground1}),bottomSlot:Ov(Ov({},Km.w.caption1Strong),{},{color:Wm.T.colorNeutralForeground1})});(0,Zg.Z)({});var Ev=function(e){var t,i=e.title,n=e.type,o=e.imageVisible,r=e.backgroundColor;switch(n){case"compact":t=Pv();break;case"regular":t=Av()}var a=(0,Hh.z)(t.container,o&&t.tearOffsetLeft);return i?vv.createElement("div",{className:a,style:{backgroundColor:r}},i.top&&vv.createElement("div",{className:t.topSlot},i.top),vv.createElement("div",null,i.middle&&vv.createElement("div",{className:t.middleContainer},i.middle&&vv.createElement("div",{className:t.middleSlot},i.middle),i.middleSuffix&&vv.createElement("div",{className:t.middleSuffixSlot},i.middleSuffix))),i.bottom&&vv.createElement("div",{className:t.bottomSlot},i.bottom)):vv.createElement(vv.Fragment,null)};function kv(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Iv(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?kv(Object(i),!0).forEach((function(t){hv(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):kv(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}Ev.defaultProps={type:"compact",contentTextSize:"small",backgroundColor:"transparent"};var Dv=(0,Zg.Z)({container:{paddingTop:Wm.T.spacingVerticalS}}),_v=(0,Zg.Z)({container:{height:"100%",display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",paddingRight:Wm.T.spacingHorizontalS}}),Nv=(0,Zg.Z)({couponIcon:{position:"absolute",fill:"none",opacity:"0"},couponIconCopied:{position:"static",opacity:"1"},couponIconCheck:Iv({opacity:"1",fill:Wm.T.colorPaletteGreenForeground1},zm.q5.transition("all","200ms","cubic-bezier(0.7,0,1,0.5)")),couponIconCheckCopied:{opacity:"1"},couponIconCheckStroke:Iv({opacity:"1",stroke:Wm.T.colorPaletteGreenForeground1,strokeDasharray:"100",strokeDashoffset:"100"},zm.q5.transition("all","1200ms","50ms","cubic-bezier(0.33,0,0.1,1)")),couponIconCheckStrokeCopied:{strokeDashoffset:"0"},couponButton:{":hover":{backgroundColor:Wm.T.colorNeutralBackground1Hover}},couponButtonCopied:{":hover":{backgroundColor:Wm.T.colorNeutralBackground1Hover},backgroundColor:Wm.T.colorNeutralBackground1Hover},copyButton:{width:"100%"},copyIconRect:{position:"absolute",opacity:"0"},copyIconRectCopied:{backgroundColor:"red",position:"static",opacity:"1",width:"100%"}});function Rv(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Mv(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Rv(Object(i),!0).forEach((function(t){hv(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Rv(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var Lv=function(e){var t,i=e.type,n=e.buttonProps,o=e.buttonLabel,r=e.buttonLabelCopied,a=e.buttonIcon,s=e.buttonOnClick,l=e.isCodeCopied,c=Nv();switch(i){case"compact":t=Dv();break;case"regular":t=_v()}var d=n||{children:l?r&&r:o&&o,icon:a&&a,appearance:"outline",size:"small",onClick:s&&s},u=(0,Hh.z)(l?c.couponButtonCopied:c.couponButton);return vv.createElement("div",{className:t.container},vv.createElement(dv,Mv(Mv({},d),{},{className:u})))};function Bv(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Fv(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Bv(Object(i),!0).forEach((function(t){hv(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Bv(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}Lv.defaultProps={type:"compact",buttonLabel:"Copy",buttonLabelCopied:"Copied",isCodeCopied:!1,buttonOnClick:function(){}};var Uv=(0,Zg.Z)({container:Fv({paddingLeft:Wm.T.spacingHorizontalM,paddingBottom:Wm.T.spacingVerticalS,marginRight:Wm.T.spacingHorizontalM,display:"flex",flexGrow:1,flexDirection:"column",alignItems:"flex-start",justifyContent:"flex-end"},zm.q5.overflow("hidden")),tearOffsetLeft:{marginLeft:"-5px"},topSlotOneLine:{"-webkit-line-clamp":"1"},topSlotTwoLine:{"-webkit-line-clamp":"2"},topSlotThreeLine:{"-webkit-line-clamp":"3"},topSlot:Fv(Fv(Fv({display:"-webkit-box","-webkit-box-orient":"vertical",marginTop:"6px","& strong":{fontWeight:Km.w.caption2Strong.fontWeight,color:Wm.T.colorBrandForeground1},width:"100%"},Km.w.caption1),{},{color:Wm.T.colorNeutralForeground1},zm.q5.overflow("hidden")),{},{textOverflow:"ellipsis"}),middleSlot:Fv(Fv(Fv({"& strong":{fontWeight:Km.w.caption2Strong.fontWeight,color:Wm.T.colorBrandForeground1},"& :not(:last-child)":{paddingRight:Wm.T.spacingHorizontalSNudge},width:"100%",color:Wm.T.colorNeutralForeground2},Km.w.caption2),zm.q5.overflow("hidden")),{},{whiteSpace:"nowrap",textOverflow:"ellipsis"}),bottomSlot:Fv(Fv(Fv({"& strong":{fontWeight:Km.w.caption2Strong.fontWeight,color:Wm.T.colorBrandForeground1}},Km.w.caption2),{},{color:Wm.T.colorNeutralForeground3,width:"100%"},zm.q5.overflow("hidden")),{},{whiteSpace:"nowrap",textOverflow:"ellipsis"})}),Hv=(0,Zg.Z)({appearanceSmallTopSlot:Fv(Fv({width:"100%","& strong":{fontWeight:Km.w.caption1Strong.fontWeight,color:Wm.T.colorBrandForeground1}},Km.w.caption1),{},{color:Wm.T.colorNeutralForeground1}),appearanceSmallMiddleSlot:Fv(Fv({"& strong":{fontWeight:Km.w.caption2Strong.fontWeight,color:Wm.T.colorBrandForeground1}},Km.w.caption2),{},{color:Wm.T.colorNeutralForeground1}),appearanceMediumTopSlot:Fv(Fv({"& strong":{fontWeight:Km.w.body1Strong.fontWeight,color:Wm.T.colorBrandForeground1}},Km.w.body1),{},{color:Wm.T.colorNeutralForeground1}),appearanceMediumMiddleSlot:Fv(Fv({"& strong":{fontWeight:Km.w.caption1Strong.fontWeight,color:Wm.T.colorBrandForeground1}},Km.w.caption1),{},{color:Wm.T.colorNeutralForeground1}),container:Fv({marginRight:Wm.T.spacingHorizontalM,paddingLeft:Wm.T.spacingHorizontalS,paddingTop:Wm.T.spacingVerticalS,paddingBottom:Wm.T.spacingVerticalS,display:"flex",flexGrow:1,flexDirection:"column",alignItems:"flex-start",rowGap:Wm.T.spacingVerticalXXS,justifyContent:"center"},zm.q5.overflow("hidden")),topSlotOneLine:{"-webkit-line-clamp":"1"},topSlotTwoLine:{"-webkit-line-clamp":"2"},topSlotThreeLine:{"-webkit-line-clamp":"3"},topSlot:Fv(Fv(Fv({display:"-webkit-box","-webkit-box-orient":"vertical","& strong":{fontWeight:Km.w.caption2Strong.fontWeight,color:Wm.T.colorBrandForeground1},width:"100%"},Km.w.caption1),{},{color:Wm.T.colorNeutralForeground1},zm.q5.overflow("hidden")),{},{textOverflow:"ellipsis"}),middleSlot:Fv(Fv(Fv({"& strong":{fontWeight:Km.w.caption2Strong.fontWeight,color:Wm.T.colorBrandForeground1},"& :not(:last-child)":{paddingRight:Wm.T.spacingHorizontalSNudge},width:"100%",color:Wm.T.colorNeutralForeground2},Km.w.caption2),zm.q5.overflow("hidden")),{},{whiteSpace:"nowrap",textOverflow:"ellipsis"}),bottomSlot:Fv(Fv(Fv({"& strong":{fontWeight:Km.w.caption2Strong.fontWeight,color:Wm.T.colorBrandForeground1}},Km.w.caption2),{},{color:Wm.T.colorNeutralForeground3,width:"100%"},zm.q5.overflow("hidden")),{},{whiteSpace:"nowrap",textOverflow:"ellipsis"})});(0,Zg.Z)({});var $v=function(e){var t,i=e.content,n=e.type,o=e.contentTextSize,r=e.imageVisible;switch(n){case"compact":t=Uv();break;case"regular":t=Hv()}var a=(0,Hh.z)(t.topSlot,"small"===o&&t.appearanceSmallTopSlot,"medium"===o&&t.appearanceMediumTopSlot,(null==i?void 0:i.top)&&(null==i?void 0:i.middle)&&(null==i?void 0:i.bottom)&&t.topSlotOneLine,(null==i?void 0:i.middle)||(null==i?void 0:i.bottom)&&t.topSlotTwoLine,!(null==i?void 0:i.middle)&&!(null==i?void 0:i.bottom)&&t.topSlotThreeLine),s=(0,Hh.z)(t.middleSlot,"small"===o&&t.appearanceSmallMiddleSlot,"medium"===o&&t.appearanceMediumMiddleSlot),l=(0,Hh.z)(t.container,r&&t.tearOffsetLeft);return i?vv.createElement("div",{className:l},i.top&&vv.createElement("div",{className:a},i.top),i.middle&&vv.createElement("div",{className:s},i.middle),i.bottom&&vv.createElement("div",{className:t.bottomSlot},i.bottom)):vv.createElement(vv.Fragment,null)};function Zv(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Vv(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Zv(Object(i),!0).forEach((function(t){hv(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Zv(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}$v.defaultProps={contentTextSize:"small",type:"compact"};var Gv=(0,Zg.Z)({container:Vv(Vv(Vv({display:"flex"},zm.q5.paddingBlock(Wm.T.spacingVerticalS)),zm.q5.paddingInline(Wm.T.spacingVerticalS)),{},{marginRight:"-5px",flexDirection:"column",alignItems:"center",justifyContent:"center"}),image:Vv(Vv({},zm.q5.borderRadius(Wm.T.borderRadiusMedium)),{},{backgroundColor:Wm.T.colorNeutralBackground3})});function jv(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}var zv=function(e){var t=Gv();return vv.createElement("div",{className:t.container},vv.createElement("img",function(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?jv(Object(i),!0).forEach((function(t){hv(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):jv(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}({className:t.image},e)))};function Wv(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Kv(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Wv(Object(i),!0).forEach((function(t){hv(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Wv(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}zv.defaultProps={type:"compact"};var qv=function(e){var t=e.type,i=e.width,n=e.contentTextSize,o=e.hideCopyButton,r=e.disableAnimation,a=e.title,s=e.titleBackgroundColor,l=e.couponDescription,c=e.content,d=e.imageArgs,u=e.imageSlot,h=e.titleSlot,p=e.contentSlot,g=e.actionSlot,f=e.buttonLabel,m=e.buttonIcon,v=e.buttonProps,y=e.buttonOnClick,C=e.baseOnClick,b=e.isCodeCopied;return vv.createElement(Tv,{type:t,width:i,disableAnimation:!(!r&&!b),couponDescription:void 0!==l&&""!==l?l:null==c?void 0:c.top,baseOnClick:C,imageSlot:u||d&&vv.createElement(zv,Kv({},d)),titleSlot:h||vv.createElement(Ev,{type:t,contentTextSize:n,title:a,backgroundColor:s&&s,imageVisible:!!d}),contentSlot:p||vv.createElement($v,{type:t,contentTextSize:n,content:c,imageVisible:!!d}),actionSlot:g||(o?vv.createElement(vv.Fragment,null):vv.createElement(Lv,{type:t,buttonProps:v,buttonLabel:f,buttonIcon:m,isCodeCopied:b,buttonOnClick:y&&y}))})};qv.defaultProps={type:"compact",contentTextSize:"small",hideCopyButton:!1};var Yv=o(44077),Xv=o(44323);function Jv(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}const Qv=e=>{const{rawCouponData:t,utilities:n,renderItems:o,isDarkMode:r,pageHandler:a,LogInfoEvent:s,popupOrigination:l,telemetryUtilities:c,moduleName:d}=e,u=r?Xv.shoppingTheme.dark:Xv.shoppingTheme.light,[h,p]=ch.useState(-1),g=ey(t,n);return ch.createElement(ap,{theme:u,style:{backgroundColor:"transparent"}},ch.createElement(Yv.Stack,{alignment:"center",spacing:"small",block:!0,direction:"vertical",gridColumns:1},g.slice(0,o).map(((e,t)=>ch.createElement(qv,{key:t,type:"regular",buttonLabel:"Copy",isCodeCopied:h===t,baseOnClick:()=>(e=>{p(e);const t=new W.Z(i.$S.CouponCopied,c.setContentViewed(d));n.isPinterest()?(a.RecordAsUserAction(K.bS.PINTEREST_COUPON_COPIED),a.RecordAsUserEngagement(q.FV.PINTEREST_COUPON_COPIED,l)):(a.RecordAsUserAction(K.bS.COUPONS_COPIED),a.RecordAsUserEngagement(q.FV.COUPONS_COPIED,l)),s(i.R.ButtonClick,"Coupon Copied",t),a.CopyCoupon(g[e].couponCode)})(t),content:{top:e.title,middle:e.shouldDisplaySuccessRate?ch.createElement(ch.Fragment,null,e.lastSuccessfulCouponTime?`${e.lastSuccessfulCouponTime} `:"",e.shouldDisplaySuccessRate?ch.createElement("span",null,ch.createElement("strong",null,e.successRate,"%")," success"):""):void 0,bottom:e.couponCode?ch.createElement(ch.Fragment,null,ch.createElement("strong",null,e.couponCode),e.attribution?` • ${e.attribution}`:""):void 0},title:{middle:ch.createElement(ch.Fragment,null," ",e.discountPercent?`${e.discountPercent}%`:"Offer"," "),middleSuffix:e.discountPercent?"off":void 0}})))))},ey=(e,t)=>e.map((e=>{const i=function(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Jv(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Jv(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}({},e);if(void 0!==e.lastSuccessfulCouponTime){const n=t.timeAgo(e.lastSuccessfulCouponTime);void 0!==n&&(i.lastSuccessfulCouponTime=n)}return i.title=t.cleanCouponDescription(e.title),i.successRate=e.successRate,i.shouldDisplaySuccessRate=e.successRate>=60,i}));var ty=class{static IsAttainableCoupon(e,t){const i=e?.minimumPurchase??e?.calculatedCutoffPrice??0;return e?.shortHeader&&void 0!==t&&i>t}static ShouldPromoteAttainableCoupon(e,t,i){const n=i&&t?i-t:0;if(!e||n<=0)return!1;let o=Number(e.amount);if(e.type.includes("Percent"))o=i*e.amount/100;else if("Amount"!==e.type)return!1;return n<o&&{couponSavings:o,amountToThreshold:n}}static GetSavingsAmount(e){if(!e)return null;const t=/(Percentage|Amount)Offer ([0-9]+)/.exec(e);return t&&t[1]&&t[2]?{amount:t[2],type:t[1]}:void 0}static GetSavingsString(e,t){if(!e)return null;if(e.type.includes("Percent"))return`${e.amount}% OFF`;if("Amount"===e.type){const i=`${r.iM.currency}${e.amount} OFF`;return(0,T.sk)(i,t)}return null}},iy=class{getStyles(){return"\n :root {\n --slide-count: 0;\n --slide-width: 76px;\n --track-width: calc(var(--slide-width) * var(--slide-count));\n --iteration-time: calc(5s * var(--slide-count));\n --coupon-color: #0F6CBD;\n }\n .divSuccessRate {\n display: flex;\n flex-direction: row;\n border-radius: 0px 3px;\n }\n .txtSuccessRate {\n color: #107C10;\n }\n #cbTooltip {\n display: inline-block;\n vertical-align: top;\n white-space: initial;\n margin-left: 1px;\n }\n #cbTooltip.couponTooltip {\n align-self: center;\n margin: 0;\n }\n #cbTooltip.couponTooltip.small div.btnTooltip {\n width: 12px;\n }\n #divCouponWrapper {\n display: grid;\n grid-template-columns: 100%;\n grid-gap: 12px;\n margin-bottom: 10px;\n margin-top: 0px;\n }\n #offerDetailsContentWrapper {\n width: 306px;\n }\n #cashbackSeeMoreWrapper {\n width: 306px;\n }\n #pdpMessage {\n font-weight: 400;\n margin: 4px 27px;\n font-size: 12px;\n text-align: center;\n }\n @keyframes scroll {\n 0% {\n transform: translateX(0);\n }\n 100% {\n transform: translateX(calc(var(--track-width) * -1));\n }\n }\n @keyframes reveal {\n 0% {\n transform: translateY(28px);\n }\n 20% {\n transform: translateY(28px);\n }\n 100% {\n transform: translateY(0);\n }\n }\n .refresh {\n animation: reveal 2s cubic-bezier(0.28, 0.86, 0, 1.02) 1;\n overflow: hidden;\n margin-right: 5px;\n }\n #carousel {\n margin-top: 6px;\n overflow: hidden;\n position: relative;\n -webkit-mask-image: linear-gradient(to right, rgba(0, 0, 0, 0) 0%, rgb(0, 0, 0) 2.5%, rgb(0, 0, 0) 97.5%, rgba(0, 0, 0, 0) 100%);\n display: flex;\n align-items: center;\n overflow: hidden;\n width: 280px;\n }\n #carousel:has(#track.stationary) {\n display: flex;\n justify-content: center;\n }\n #track.stationary {\n animation: none;\n }\n #track {\n animation: scroll var(--iteration-time) linear infinite;\n animation-play-state: running;\n list-style-type: none;\n display: flex;\n align-items: center;\n column-gap: 16px;\n margin: 0px;\n padding: 0px;\n }\n .coupon {\n display: flex;\n flex-direction: row;\n align-items: center;\n height: 24px;\n border: 1px dashed var(--coupon-color);\n box-sizing: border-box;\n border-radius: 4px;\n padding: 0px 6px;\n overflow: hidden;\n white-space: nowrap;\n }\n .coupon p {\n color: var(--coupon-color);\n margin: 0;\n font-weight: 600;\n font-size: 12px;\n line-height: 22px;\n }\n .couponInDiscover::part(success-rate) {\n display: none;\n }\n @media (forced-colors: active) {\n .divSuccessRateIcon svg path:first-child {\n fill: highlight;\n }\n .divSuccessRateIcon svg path:last-child {\n fill: highlighttext;\n }\n }\n "}getEmptyCouponStyles(){return"\n .emptyCouponSectionTitle::part(control) {\n margin-top: 6px;\n }"}getDarkModeStyles(){return"\n :root {\n --coupon-color: #63ADE5;\n }\n .txtSuccessRate {\n color: #62C90C;\n }\n .divSuccessRateIcon svg path:first-child {\n fill: #62C90C;\n }\n "}getEmptyHeaderStyles(){return"\n msft-edge-shopping::part(header) {\n display: none;\n }\n "}},ny=class{getStyles(){return'\n .couponBackgroundCJK {\n padding-top: 18px;\n padding-bottom: 18px;\n padding-left: 22px;\n padding-right: 22px;\n border-radius: 12px;\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n align-items: center;\n background: radial-gradient(circle at 0 center, transparent 0, transparent 10px, #F9E8E7 10px);\n }\n .couponBackgroundCJK:hover {\n cursor: pointer;\n }\n .couponAmountCJK {\n left: 24px;\n top: 22px;\n font-style: normal;\n font-weight: 600;\n font-size: 24px;\n display: flex;\n align-items: center;\n line-height: 32px;\n text-align: justify;\n color: #E8392C;\n }\n .couponDecriptionTextContaineCJK {\n display: flex;\n flex-direction: column;\n margin-left: 24px;\n }\n .couponSubtitleUpperCJK {\n /* Available after 2000 yuan */\n width: auto;\n font-family: \'Segoe UI\', "Roboto", Helvetica, Verdana, sans-serif;\n font-style: normal;\n font-weight: 600;\n font-size: 16px;\n line-height: 22px;\n /* identical to box height, or 138% */\n color: #E8392C;\n }\n .couponSubtitleUpperCJKFlyout {\n /* Available after 2000 yuan */\n width: auto;\n font-family: "Segoe UI", "Roboto", Helvetica, Verdana, sans-serif;\n font-style: normal;\n font-weight: 600;\n font-size: 13px;\n line-height: 22px;\n /* identical to box height, or 138% */\n color: #E8392C;\n }\n .couponSubtitleLowerCJK {\n /* Only 1 day and 10 hours from expiration of the current product */\n width: auto;\n /* Ramp/minus-1\n Font size one smaller than base.\n */\n font-family: \'Segoe UI Variable Static Small\', "Roboto", Helvetica, Verdana, sans-serif;\n font-style: normal;\n font-weight: 400;\n font-size: 12px;\n padding-top: 6px;\n line-height: 16px;\n /* or 133% */\n color: #E8392C;\n }\n .amountTextContainerCJK {\n display: flex;\n flex-direction: row;\n }\n .couponButtonCJK {\n /* Use */\n height: 16px;\n /* Ramp/minus-1\n Font size one smaller than base.\n */\n font-family: \'Segoe UI Variable Static Small\', "Roboto", Helvetica, Verdana, sans-serif;\n font-style: normal;\n font-weight: 400;\n font-size: 12px;\n line-height: 16px;\n text-align: center;\n color: #E8392C;\n /* Inside auto layout */\n flex: none;\n order: 0;\n flex-grow: 0;\n border: 1px solid red;\n border-radius: 15px;\n padding: 8px;\n }\n '}getDarkModeStyles(){return""}getCjkSectionNumberIconPath(e){return`${e}cjk/sectionnumber.svg`}},oy=class{constructor(e){(0,s.Z)(this,"numCoupons",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"instantSavingsUptoXOff",""),(0,s.Z)(this,"instantSavingsPercentage",-1),this.flyoutData=e}getInstantSavingsUptoXOff(){return this.instantSavingsUptoXOff||this.getInstantSavingsPercentage()>0&&(this.instantSavingsUptoXOff=(0,T.fZ)("coupons up to x% off",this.flyoutData.strings.couponsUpToXPercentOff,this.instantSavingsPercentage.toString())),this.instantSavingsUptoXOff}getInstantSavingsPercentage(){if(-1!==this.instantSavingsPercentage)return this.instantSavingsPercentage;if(this.flyoutData.dataStoreModule.ApiData?.retailerData.couponsFilteringEnabled){const e=this.flyoutData.dataStoreModule.CouponData?.Coupons.filter((e=>e.discountPercent&&e.successRate&&!e.isLowSuccessRateCoupon));e&&(e.sort(((e,t)=>t.successRate-e.successRate)),e[0]&&(this.instantSavingsPercentage=e[0].discountPercent))}return this.instantSavingsPercentage}shouldRender(e){const t=this.flyoutData.dataStoreModule.PriceComparisonData,i=t?.segment?.toLowerCase();if(i===r.VG.AUTOS&&t?.CompetingPrices&&t?.CompetingPrices.length>0||i===r.VG.EMPTYAUTOSSEGMENT)return e&&e("Autos Scenario"),!1;const n=this.flyoutData.dataStoreModule.CouponData?.Coupons;n?.length&&(this.numCoupons=n.length);const o=!!n?.length;return o||e&&e("No coupons found"),o}};class ry extends c.Z{constructor(e){super(i.Vm.GetFileContentFromResourcesMessage),this.filePath=e}}var ay=ry,sy=class{static async getAutoApplyContent(e,t,i){const n=(0,Y.Ux)("h1");n.slot="header-content",n.className="popup-content";const o=(0,Y.Ux)("DIV");o.className="coupon-info";const r=(0,Y.Ux)("IMG");r.src=await i.GetImageSrc("../images/left-percentage-icon.png");const a=(0,Y.Ux)("SPAN");a.className="coupon-num",a.textContent=t.Coupons.length.toString();const s=(0,Y.Ux)("IMG");s.src=await i.GetImageSrc("../images/right-percentage-icon.png");const l=(0,Y.Ux)("DIV");return l.textContent=e,l.className="coupon-text",o.appendChild(r),o.appendChild(a),o.appendChild(s),n.appendChild(o),n.appendChild(l),n}static applyStyles(e,t,i){if(e){const n=(0,Y.Ux)("STYLE");n.textContent=t,n.type="text/css",n.rel="stylesheet",i&&(n.id=i),e.appendChild(n)}}static async GetPNGIcon(e,t){const i=(await e.SendMessage(new ay(t))).fileContent,n=document.createElement("img");return n.src="data:image/png;base64,"+i,n}static GetNoHeaderBackgroundStyles(){return"\n msft-edge-shopping::part(header) {\n background-color: unset;\n padding-bottom: 0;\n margin: 0;\n }\n "}},ly=class{getStyles(){return"\n .popup-content {\n display: flex;\n flex-direction: column;\n align-items: center;\n padding-bottom: 20px;\n margin: 0;\n }\n .coupon-info {\n padding-bottom: 10px;\n }\n .coupon-num {\n font-size: 36px;\n font-weight: 500;\n }\n .coupon-text {\n font-size: 24px;\n font-weight: 500;\n }\n .safari-auto-apply-btn {\n height: 32px;\n font-size: 14px;\n font-weight: 600;\n line-height: 20px;\n background: #2169EB;\n }\n .safari-region {\n background: white;\n margin: 20px;\n margin-top: 0px;\n padding: 10px;\n border-radius: 8px;\n }\n "}},cy=o(12710),dy=o(56854),uy=class extends Qu{constructor(n,o,a,l){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"cjkAssets",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"isPDP",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"acUtilities",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"footerUtilities",void 0),(0,s.Z)(this,"tooltipUtilities",void 0),(0,s.Z)(this,"discoverTelemetryHandler",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"cashbackUtilities",void 0),(0,s.Z)(this,"shouldRenderReason",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"isPaneOnlyModule",!1),(0,s.Z)(this,"autoOpenControllerUtilities",void 0),(0,s.Z)(this,"instantSavings",void 0),(0,s.Z)(this,"emptyDiv",void 0),(0,s.Z)(this,"isCjkEnabled",!1),(0,s.Z)(this,"expectation",void 0),(0,s.Z)(this,"cjkDataVendor",void 0),(0,s.Z)(this,"cashbackTelemetry",void 0),(0,s.Z)(this,"estimatedCashbackData",void 0),(0,s.Z)(this,"currentRetailerData",void 0),this.logModule=a.logModule,this.pageHandlerModule=a.pageHandlerModule,this.stateManagement=n,this.flyoutData=o,this.utilities=a.viewModulesUtilities,this.acUtilities=new class{constructor(e,t,i,n){(0,s.Z)(this,"cartValue",void 0),(0,s.Z)(this,"lastAttainableCoupon",void 0),(0,s.Z)(this,"attainableCouponList",[]),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"tooltipUtilities",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"lockedCoupons",void 0),(0,s.Z)(this,"data",void 0),this.utilities=e.viewModulesUtilities,this.flyoutData=t,this.assets=new class{getInfoIcon(){return eh.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="12" height="13" viewBox="0 0 12 13" fill="none" aria-hidden="true">
<path opacity="0.7" d="M5.4 7.14712C5.4 6.81575 5.66863 6.54712 6 6.54712C6.33137 6.54712 6.6 6.81575 6.6 7.14712V8.94712C6.6 9.27849 6.33137 9.54712 6 9.54712C5.66863 9.54712 5.4 9.27849 5.4 8.94712V7.14712ZM6 3.84712C5.50294 3.84712 5.1 4.25006 5.1 4.74712C5.1 5.24418 5.50294 5.64712 6 5.64712C6.49706 5.64712 6.9 5.24418 6.9 4.74712C6.9 4.25006 6.49706 3.84712 6 3.84712ZM0 6.54712C0 3.23341 2.68629 0.547119 6 0.547119C9.31371 0.547119 12 3.23341 12 6.54712C12 9.86083 9.31371 12.5471 6 12.5471C2.68629 12.5471 0 9.86083 0 6.54712ZM6 1.74712C3.34903 1.74712 1.2 3.89615 1.2 6.54712C1.2 9.19809 3.34903 11.3471 6 11.3471C8.65097 11.3471 10.8 9.19809 10.8 6.54712C10.8 3.89615 8.65097 1.74712 6 1.74712Z" fill="var(--neutral-foreground-rest)"/>
</svg>`}getLockIcon(){return eh.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="12" height="15" viewBox="0 0 12 15" fill="none">
<path d="M6.00203 0.995361C7.47477 0.995361 8.6687 2.18927 8.6687 3.66203V4.99536H9.83537C10.6638 4.99536 11.3354 5.66694 11.3354 6.49536V12.8287C11.3354 13.6571 10.6638 14.3287 9.83537 14.3287H2.1687C1.34027 14.3287 0.668701 13.6571 0.668701 12.8287V6.49536C0.668701 5.66694 1.34027 4.99536 2.1687 4.99536H3.33537V3.66203C3.33537 2.18927 4.52927 0.995361 6.00203 0.995361ZM9.83537 5.99536H2.1687C1.89256 5.99536 1.6687 6.21922 1.6687 6.49536V12.8287C1.6687 13.1048 1.89256 13.3287 2.1687 13.3287H9.83537C10.1115 13.3287 10.3354 13.1048 10.3354 12.8287V6.49536C10.3354 6.21922 10.1115 5.99536 9.83537 5.99536ZM6.0021 8.66203C6.55443 8.66203 7.0021 9.10976 7.0021 9.66203C7.0021 10.2143 6.55443 10.662 6.0021 10.662C5.44983 10.662 5.0021 10.2143 5.0021 9.66203C5.0021 9.10976 5.44983 8.66203 6.0021 8.66203ZM6.00203 1.99536C5.08157 1.99536 4.33537 2.74155 4.33537 3.66203V4.99536H7.6687V3.66203C7.6687 2.74155 6.9225 1.99536 6.00203 1.99536Z" fill="black" fill-opacity="0.83"/>
</svg>`}getUnlockedIcon(){return eh.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="10" height="15" viewBox="0 0 10 15" fill="none">
<path d="M5 10.9121C5.55228 10.9121 6 10.4644 6 9.91211C6 9.35982 5.55228 8.91211 5 8.91211C4.44772 8.91211 4 9.35982 4 9.91211C4 10.4644 4.44772 10.9121 5 10.9121ZM5 1.91211C4.17157 1.91211 3.5 2.58368 3.5 3.41211V5.41211H8.5C9.32843 5.41211 10 6.08368 10 6.91211V12.9121C10 13.7405 9.32843 14.4121 8.5 14.4121H1.5C0.671573 14.4121 0 13.7405 0 12.9121V6.91211C0 6.08368 0.671573 5.41211 1.5 5.41211H2.5V3.41211C2.5 2.0314 3.61929 0.912109 5 0.912109C6.38071 0.912109 7.5 2.0314 7.5 3.41211C7.5 3.68825 7.27614 3.91211 7 3.91211C6.72386 3.91211 6.5 3.68825 6.5 3.41211C6.5 2.58368 5.82843 1.91211 5 1.91211ZM1.5 6.41211C1.22386 6.41211 1 6.63597 1 6.91211V12.9121C1 13.1883 1.22386 13.4121 1.5 13.4121H8.5C8.77614 13.4121 9 13.1883 9 12.9121V6.91211C9 6.63597 8.77614 6.41211 8.5 6.41211H1.5Z" fill="#212121"/>
</svg>`}getStyles(){return"\n #attainableCouponDiv {\n display: flex;\n flex-direction: row;\n justify-content: center;\n background: linear-gradient(90deg, rgba(255, 249, 217, 0.6) 0%, rgba(233, 251, 255, 0.6) 53.12%, rgba(221, 235, 255, 0.6) 100%);\n width: calc(100% + 40px);\n height: 52px;\n margin-left: -20px;\n margin-right: -20px;\n }\n #attLock {\n width: 20px;\n height: 20px;\n margin-right: 12px;\n align-self: center;\n }\n #attPrompt {\n font-size: 12px;\n line-height: 20px;\n margin: 0px;\n align-self: center;\n }\n #notificationDiv {\n display: flex;\n flex-direction: column;\n justify-content: center;\n background: linear-gradient(90deg, rgba(255, 249, 217, 0.6) 0%, rgba(233, 251, 255, 0.6) 53.12%, rgba(221, 235, 255, 0.6) 100%);\n width: calc(100%);\n margin-top: -20px;\n }\n #notificationBanner {\n display: flex;\n flex-direction: row;\n justify-content: center;\n width: calc(100%);\n height: 52px;\n }\n "}getDarkModeStyles(){return"\n #attainableCouponDiv, #notificationDiv {\n background: linear-gradient(90deg, rgba(105, 99, 67, 0.6) 0%, rgba(83, 101, 105, 0.6) 53.12%, rgba(71, 85, 105, 0.6) 100%);\n }\n "}},this.pageHandlerModule=i,this.storageHandler=e.storageHandler,this.tooltipUtilities=e.tooltipUtilities,this.logModule=n,this.cartValue=-1,this.lockedCoupons=[]}async setupAttainableCoupons(){const e=this.flyoutData.common.domain;(0,h.Si)(e,"lastAttainableCoupon"),(0,h.Si)(e,"attainableCouponMap");const t=await this.storageHandler.getStorageString("CartValues");if(!(0,p.TF)(t))try{const i=JSON.parse(t),n=new Date,o=i?i[e]:void 0,r=o?new Date(o.timestamp):null,a=r?n.getTime()-r.getTime():0;if(Math.floor(a/1e3/60/60/24)>0)this.storageHandler.clearDomainMappedStringStorage("CartValues",e,i);else{const e=o?.cartValue;this.cartValue=e?.OrderTotal??-1}}catch(e){}const i=(0,h.hS)("lastAttainableCoupon"),n=i[e]??{};this.lastAttainableCoupon=n.referenceCoupon;const o=(0,h.hS)("attainableCouponMap"),r=o[e]??{};if(this.attainableCouponList=r.attainableCouponList??[],await this.storageHandler.getStorageBool("CompletedPurchase"))try{i[e]={},o[e]={},this.storageHandler.setStorageBool("CompletedPurchase",!1),(0,h.Xo)("lastAttainableCoupon",JSON.stringify(i)),(0,h.Xo)("attainableCouponMap",JSON.stringify(o))}catch(e){}}async shouldCreateBanner(e){this.updateLockedCoupons(this.cartValue),this.data=await this.parseInfo(this.flyoutData.common.domain);const t=this.data?.isCouponAttained&&this.data?.lastAttainableCoupon&&!this.data?.referenceCoupon,i=this.data?.referenceCoupon&&this.lockedCoupons.length>0,n=e&&(t||i);return n||(0,h.Xo)("attainableCouponDisplayed","false"),n}createBanner(t){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());const i=(0,Y.Ux)("div");i.slot="start-content",i.id="attainableCouponDiv",i.setAttribute("role","group"),i.setAttribute("aria-labelledby","attPrompt");const n=this.flyoutData.common.domain;if(this.data&&this.data.isCouponAttained&&this.data.lastAttainableCoupon&&!this.data.referenceCoupon)this.populateCouponAttained(this.data.lastSavings,i),this.recordViewed(!0,this.data.lastAttainableCoupon.couponCode);else{if(!(this.data&&this.data.referenceCoupon&&this.lockedCoupons.length>0))return(0,h.Xo)("attainableCouponDisplayed","false"),null;this.populateAttainableCoupon(this.data.referenceCoupon,this.data.referenceSavings,this.data.lastAttainableCoupons,n,i),this.createInfoTooltip(i,this.data.referenceCoupon,this.data.referenceSavings),this.recordViewed(!1,this.data.referenceCoupon.couponCode)}(0,h.Xo)("attainableCouponDisplayed","true"),e.R.isExperimentActive(f.H.incentiveCampaign)&&void 0!==this.flyoutData.dataStoreModule.IncentiveCampaignData&&!this.flyoutData.dataStoreModule.IncentiveCampaignData.isRewardClaimed||t.prepend(i)}recordViewed(e,n){const o=new t.Z(i.xu.ModuleViewed,void 0,void 0,void 0,n),r=e?bp.r.COUPON_ATTAINED:bp.r.ATTAINABLE_COUPONS;this.pageHandlerModule.RecordAsContentViewed(r),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,`${r}`,o)}populateCouponAttained(e,t){const i=(0,Y.Ux)("p");i.id="attPrompt";const n=this.flyoutData.strings.attFlyoutUnlocked,o=(0,T.uf)(this.flyoutData.dataStoreModule.ApiData?.market,this.flyoutData.dataStoreModule.ApiData?.retailerData?.exclusiveMarket),r=ty.GetSavingsString(e,o),a=(0,Y.Ux)("span",{style:"display: inline; color: var(--neutral-foreground-rest); font-size: 14px; font-weight: bold;"});a.textContent=r,(0,T.B7)(i,n,a),t.append(i)}populateAttainableCoupon(e,t,i,n,o){if(void 0===e||void 0===t)return Promise.resolve(null);{const t=new Date;i[n]={referenceCoupon:e,timestamp:t};const o=JSON.stringify(i);(0,h.Xo)("lastAttainableCoupon",o)}const a=(0,Y.Ux)("p");a.id="attPrompt";const s=e?.minimumPurchase??e?.calculatedCutoffPrice??0,l=this.flyoutData.strings.attFlyoutLocked,c=(0,Y.Ux)("span",{style:"display: inline; color: var(--neutral-foreground-rest); font-size: 12px; font-weight: bold;"});c.textContent=`${r.iM.currency}${s.toFixed(2)}`,c.textContent=(0,T.sk)(c.textContent);const d=(0,T.uf)(this.flyoutData.dataStoreModule.ApiData?.market,this.flyoutData.dataStoreModule.ApiData?.retailerData?.exclusiveMarket),u=ty.GetSavingsString(t,d),p=(0,Y.Ux)("span",{style:"display: inline; color: var(--neutral-foreground-rest); font-size: 12px; font-weight: bold;"});p.textContent=u,(0,T.B7)(a,l,c,p),o.append(a)}createInfoTooltip(e,t,n){const o=(0,T.uf)(this.flyoutData.dataStoreModule.ApiData?.market,this.flyoutData.dataStoreModule.ApiData?.retailerData?.exclusiveMarket),a=ty.GetSavingsString(n,o)??"savings",s=t?.minimumPurchase??t?.calculatedCutoffPrice??0,l=`${r.iM.currency}${s.toFixed(2)}`,c=`${r.iM.currency}${s.toFixed(2)}`,d=(0,T.fZ)("attTooltipText",this.flyoutData.strings.attTooltipText,c),u=(0,T.fZ)("attTooltipHeader",this.flyoutData.strings.attTooltipHeader,a,l),h=this.pageHandlerModule,p=this.logModule;function g(){const e=new W.Z(i.$S.AttainableInfoIcon,this.telemetryUtilities.setContentViewed(this.GetModuleName()));h.RecordAsUserAction(K.bS.ATTAINABLE_COUPON_CLICK),p.LogInfoEvent(i.R.ButtonClick,"Attainable coupon info viewed",e)}const f=this.tooltipUtilities.createInfoIconTooltip((0,T.sk)(d),(0,T.sk)(u),void 0,g,g);f.id="header-tooltip",f.style.alignSelf="center",f.style.marginLeft="4px",e.append(f)}async parseInfo(e){await this.storageHandler.getStorageString("CartValues").then((t=>{if(!(0,p.TF)(t))try{const i=JSON.parse(t)[e].cartValue;this.cartValue=i.OrderTotal}catch(e){return{}}}));let t,i,n,o=!1;try{const r=(0,h.Mw)("lastAttainableCoupon");n=r?JSON.parse(r):{},this.cartValue>0&&n&&(t=(n[e]??{}).referenceCoupon,t&&(o=(t?.minimumPurchase??t?.calculatedCutoffPrice??0)<this.cartValue,i=ty.GetSavingsAmount(t.shortHeader)))}catch(e){return{}}this.updateLockedCoupons(this.cartValue);let r,a,s,l=75;for(const e of this.lockedCoupons){const t=ty.GetSavingsAmount(e.shortHeader),i=e.minimumPurchase??e.calculatedCutoffPrice??0;s=ty.ShouldPromoteAttainableCoupon(t,this.cartValue,i),e.successRate&&e.successRate>l&&s&&(r=e,a=t,l=e.successRate)}return{isCouponAttained:o,lastAttainableCoupon:t,lastAttainableCoupons:n,lastSavings:i,referenceCoupon:r,referenceSavings:a}}addLockIcon(e,t){const i=this.flyoutData.common.domain,n=(0,h.hS)("attainableCouponMap"),o=e?.minimumPurchase??e?.calculatedCutoffPrice??0;if(ty.IsAttainableCoupon(e,this.cartValue)){t.hasIcon=!0;const o=(0,Y.Ux)("div");o.innerHTML=this.assets.getLockIcon(),o.slot="icon";const r=o.querySelector("path");if(this.utilities.isDarkMode()&&r&&(r.style.fill="#FFFFFF"),t.append(o),!this.attainableCouponList.includes(e.couponCode)){this.attainableCouponList.push(e.couponCode);const t=new Date;n[i]={attainableCouponList:this.attainableCouponList,timestamp:t};const o=JSON.stringify(n);(0,h.Xo)("attainableCouponMap",o)}}else if(this.attainableCouponList.includes(e.couponCode)&&o<this.cartValue){t.hasIcon=!0,t.regularColors=!0;const e=(0,Y.Ux)("div");e.innerHTML=this.assets.getUnlockedIcon(),e.slot="icon";const i=e.querySelector("path");this.utilities.isDarkMode()&&i&&(i.style.fill="#FFFFFF"),t.append(e)}}updateLockedCoupons(e){if(this.flyoutData.dataStoreModule.CouponData?.Coupons)for(const t of this.flyoutData.dataStoreModule.CouponData?.Coupons){const i=t.minimumPurchase??t.calculatedCutoffPrice??0;i&&i>e&&t.shortHeader&&this.lockedCoupons.push(t)}}hasOnlyAttainableCoupons(){const e=this.flyoutData.dataStoreModule.CouponData?.Coupons??[];if(this.lastAttainableCoupon||this.attainableCouponList?.length>0){const t=e.filter((e=>!(ty.IsAttainableCoupon(e,this.cartValue)||this.attainableCouponList?.includes(e.couponCode)||this.lastAttainableCoupon&&this.lastAttainableCoupon.couponCode===e.couponCode)));return t.length<1}return!1}isCouponAttained(){return!!this.lastAttainableCoupon&&(this.lastAttainableCoupon?.minimumPurchase??this.lastAttainableCoupon?.calculatedCutoffPrice??0)<this.cartValue}filterAttainableCouponList(){const e=this.flyoutData.dataStoreModule.CouponData?.Coupons??[];if(e.length<1)return[];const t=e.filter((e=>!e.isPrivateCoupon));t.sort(((e,t)=>(t.successRate??0)-(e.successRate??0))).sort(((e,t)=>(this.filterAsAttainable(t)?1:0)-(this.filterAsAttainable(e)?1:0)));let i=0;const n=e.flatMap((e=>e.isPrivateCoupon?[e]:i<t.length?[t[i++]]:[]));return n}filterAsAttainable(e){const t=e.minimumPurchase??e.calculatedCutoffPrice??0;return ty.IsAttainableCoupon(e,this.cartValue)||this.attainableCouponList.includes(e.couponCode)||this.lastAttainableCoupon&&t<this.cartValue&&this.lastAttainableCoupon.couponCode===e.couponCode}}(a,o,a.pageHandlerModule,a.logModule),this.commonAssets=l,this.assets=new iy,this.cjkAssets=new ny,this.storageHandler=a.storageHandler,this.footerUtilities=a.footerUtilities,this.tooltipUtilities=a.tooltipUtilities,this.autoOpenControllerUtilities=a.autoOpenControllerUtilities,this.discoverTelemetryHandler=a.discoverTelemetryHandler,this.isCjkEnabled=o.common.isCJKEnabled,this.cjkDataVendor=o.common.cjkDataVendor,this.telemetryUtilities=a.telemetryHandler,this.cashbackTelemetry=new ng(this.telemetryUtilities,this.flyoutData,this.pageHandlerModule,this.logModule),this.cashbackUtilities=new Tg(o,a.pageHandlerModule,a.logModule,a.viewModulesUtilities,this.GetModuleName(),a.telemetryHandler,a.storageHandler)}GetModuleName(){return r.ModuleNames.COUPON}CalculateRanking(){return this.flyoutData.common.isCheckoutPage?r.zz.SaveMoneyPage:r.zz.InformRetailer}ShouldRenderModule(){this.expectation=this.getExpectation();const e=new oy(this.flyoutData),t=e.shouldRender(this.setShouldRenderReason.bind(this)),i=this.flyoutData.dataStoreModule.ApiData?.retailerData;this.currentRetailerData=i?.GetCurrentCheckoutPage(this.flyoutData.common.lastCommittedURL);const n=!!this.currentRetailerData?.clippingSelectors;return t&&(!1===n||0===this.stateManagement.getState(Ku.IY.renderedViewModuleCount)||!0===this.flyoutData.common.isPane)&&(this.flyoutData.common.isCheckoutPage||this.flyoutData.dataStoreModule.CouponData?.BgaaResultState)&&this.flyoutData.common.pageStatus.AutoApplyStatus&&(this.instantSavings=e.getInstantSavingsUptoXOff()),Promise.resolve(t)}async renderModule(){const e=this.flyoutData.dataStoreModule.CouponData,t=this.flyoutData.dataStoreModule.SocialCouponsData?.socialCouponsForDomain;if(e&&e.Coupons&&e.Coupons.length>0){await this.acUtilities.setupAttainableCoupons();const t=document.createElement("msft-edge-shopping-section");if(t.id="couponSection",t.isCjk=this.isCjkEnabled,t.isCjkNotification=this.isCjkEnabled&&this.flyoutData.common.openedWith===r.Te.Hover,t.isCjkNotification&&(t.countNumber=e.Coupons.length,t.cjkSectionNumberIcon=this.cjkAssets.getCjkSectionNumberIconPath(this.flyoutData.common.resourcesEndpoint)),this.utilities.applyStyles(t,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),(0,dt.tB)(this.flyoutData)){const e=new ly;this.utilities.applyStyles(t,e.getStyles())}if(this.isCjkEnabled&&this.utilities.applyStyles(t,this.cjkAssets.getStyles(),void 0,this.cjkAssets.getDarkModeStyles()),this.flyoutData.common.isDiscoverPane){const e=()=>{this.discoverTelemetryHandler.LogEventTelemetry(i.xu.CouponDiscoverHover,"Coupon Discover Hover","",r.ModuleNames.COUPON),t.removeEventListener("mouseover",e)};t.addEventListener("mouseover",e)}await this.populateCouponList(t,!1,!1,this.flyoutData.common.bannerContext);const n=this.getSectionTitle();this.flyoutData.common.isDiscoverPane||this.stateManagement.addEventListener(Ku.e1.ModulesRendered,(async e=>{if(e.detail?.modules&&o.common.isPane){const{modules:i}=e.detail,n=i.filter((({paneTab:e})=>e===r.$k.CONTEXTUAL));1===n.length&&n[0].name===r.ModuleNames.COUPON?(this.isPaneOnlyModule=!0,await this.populateCouponList(t,!1,!1,"")):this.isPaneOnlyModule=!1}}));const o=this.flyoutData,a=e=>{let t=r.CS.TWO_COUPON_ON_START;return this.isPaneOnlyModule&&(t=r.CS.COUPONPANE),e&&o.common.bannerContext===r.De.VIEWALL&&(t=e.length),t},s=this.acUtilities.filterAttainableCouponList();this.utilities.createCommonListStructure(t,n,s,this.GetModuleName(),a,this.populateCouponList.bind(this));const l=this.CreateModule(t,r.H7.COUPON,r.ModuleNames.COUPON,r.$k.CONTEXTUAL,r.SV.SQUARES);return this.isCjkEnabled&&(this.pageHandlerModule.RecordAsCjkScenario(Hg.SHOW,Ug.COUPONS),this.cjkDataVendor&&this.cjkDataVendor in $g&&this.pageHandlerModule.RecordAsCjkScenario(Hg.SHOW+$g[this.cjkDataVendor],Ug.COUPONS)),Promise.resolve(l)}if(e&&e.Coupons&&0===e.Coupons.length&&!(t&&t.length>0)&&!this.hasSocialSelectors()&&void 0!==this.flyoutData.dataStoreModule.CouponData){const e=document.createElement("msft-edge-shopping-section");e.id="emptyCouponSection",e.accordion=!0,e.titleText=this.flyoutData.strings.couponEmptyCouponTitle,this.utilities.applyStyles(e,this.assets.getEmptyCouponStyles(),void 0),this.emptyDiv=(0,Y.Ux)("DIV",{id:"emptyCouponDiv",style:"display: flex; flex-direction: column; justify-content: center; align-items: center; margin-bottom: 12px;"});const t=(0,Y.Ux)("DIV",{style:"margin: 20px;"});t.innerHTML=this.commonAssets.getErrorImage(),t.setAttribute("aria-hidden","true");const i=(0,Y.Ux)("P",{style:"font-weight: 600; margin-top: 5px; color: #666666;"});i.className=r.aM.EmptyCoupon,i.textContent=this.flyoutData.strings.couponEmptyCouponTitle;const n=(0,Y.Ux)("P",{style:"margin-top: 5px; color: #666666;"});n.className=r.aM.Small,n.textContent=this.flyoutData.strings.couponEmptyCouponSubTitle,this.emptyDiv.appendChild(t),this.emptyDiv.appendChild(i),this.emptyDiv.appendChild(n),e.appendChild(this.emptyDiv);const o=this.CreateModule(e,r.H7.EMPTYCOUPON,r.ModuleNames.EMPTYCOUPON,r.$k.CONTEXTUAL,r.SV.BLOCK);return Promise.resolve(o)}return Promise.resolve(null)}async populateMainHeader(){const e=this.flyoutData.common.shopping,t=this.flyoutData.dataStoreModule.CashBackData,n=this.flyoutData.dataStoreModule.CouponData,o=this.isValidCheckoutWithAA(),a=n?.BgaaResultState??"",l=n?.BgaaSavings??"",c=n?.Trivia,d=this.flyoutData.common.openedWith===r.Te.Auto,u=o&&!this.instantSavings&&this.flyoutData.common.openedWith===r.Te.Auto&&(this.expectation===i.Iy.Medium||this.expectation===i.Iy.None);if(this.isCjkEnabled&&gn.SO.queueUpdate((()=>{const t=e.querySelector("#couponSection");this.utilities.handleCjkSectionAsTopModuleStyle(t)})),await this.renderInfoBanner(e,o,u),this.utilities.isPinterest()&&n?.DomainName){const t=new class{getStyles(){return"\n #socialCouponSection {\n width: 100%;\n text-align: left;\n }\n #divImgWrapper {\n border-radius: 50%;\n overflow: hidden;\n z-index: 1;\n place-self: center;\n }\n #divProfileImgWrapper {\n background-color: var(--fill-color);\n border-radius: 50%;\n place-self: center;\n position: relative;\n display: flex;\n justify-content: center;\n }\n #divInfluencerInfo {\n width: 100%;\n display: flex;\n flex-direction: row;\n place-self: center;\n align-items:center;\n column-gap: 16px;\n min-height: 70px;\n box-sizing: border-box;\n padding-bottom: 0px;\n padding-top: 0px;\n z-index: 5;\n }\n .divRetailerCoupon {\n width: 100%;\n display: grid;\n grid-template-columns: 40% 60%;\n place-self: center;\n align-items:center;\n margin-bottom: 5px;\n background: linear-gradient(0deg, #FFFFFF, #FFFFFE);\n border: 1px solid rgba(234, 230, 232, 0.5);\n box-shadow: 0px 0px 12px rgba(0, 0, 0, 0.04);\n border-radius: 8px;\n column-gap: 12px;\n min-height: 105px;\n box-sizing: border-box;\n padding: 8px;\n }\n .divCouponCodeWrapper {\n display: flex;\n flex-direction: column;\n place-self: center;\n background: #F7F4F5;\n border-radius: 8px;\n width: 100%;\n height: 100%;\n justify-content: center;\n align-items: center;\n row-gap: 8px;\n }\n .divRetailerInfluencerWrapper {\n display: flex;\n flex-direction: row;\n justify-content: flex-start;\n align-items: center;\n column-gap: 8px;\n padding: 5px;\n }\n "}getDarkModeStyles(){return"\n .divRetailerInfluencerWrapper .txtSmall {\n opacity: 1!important;\n }\n "}getCouponsStyles(){return".ytCouponElement {\n display: flex;\n flex-direction: column;\n row-gap: 8px;\n justify-content: center;\n align-items: center;\n width: 150px;\n min-height: 74px;\n background: linear-gradient(0deg, #FFFFFF, #FFFFFF);\n border: 1px solid rgba(234, 230, 232, 0.5);\n box-sizing: border-box;\n box-shadow: 0px 0px 12px rgba(0, 0, 0, 0.04);\n border-radius: 8px;\n cursor: pointer;\n }\n .divYTCouponWrapperTemplate {\n display: grid;\n grid-gap: 12px;\n margin-bottom: 12px;\n }"}};this.utilities.applyStyles(this.flyoutData.common.shopping,t.getStyles(),void 0,t.getDarkModeStyles()),new class{constructor(e){(0,s.Z)(this,"flyoutData",void 0),this.flyoutData=e}createCouponHeader(e,t,n,o){const r=(0,Y.Ux)("DIV",{style:"width: 100%; display: flex; flex-direction: row; justify-content: flex-start; column-gap: 16px; text-align: left; font-weight: 500; overflow: hidden; min-height: 67px;"});r.classList.add("lateralMargin"),r.slot="header-content",this.createRetailerIcon(r,t);const a=(0,Y.Ux)("SPAN");a.textContent=e||t,a.className="txtLarge txtSavingsColor",a.style.display="inline-block",a.style.minHeight="35px";const s=(0,Y.Ux)("H2");if(s.className="txtLarge",s.style.fontWeight="500",1===n){const e=(0,T.dK)(this.flyoutData.strings.ptCouponsTitleStr,i.T4.One);(0,T.B7)(s,e,a)}else{const e=(0,T.dK)(this.flyoutData.strings.ptCouponsTitleStr,i.T4.Other,n);(0,T.B7)(s,e,a)}r.appendChild(s),o.appendChild(r)}createRetailerIcon(e,t){const i=(0,Y.Ux)("DIV");i.setAttribute("role","image");const n=(0,T.fZ)("commonAriaLogo",this.flyoutData.strings.commonAriaLogo,t);i.setAttribute("aria-label",n),i.id="divProfileImgWrapper";const o=(0,Y.Ux)("IMG",{style:"width: 50px; height: 50px; place-self: center;\n border-radius: 8px; position: relative;\n margin-bottom: 8px;"});o.src=`${this.flyoutData.common.resourcesEndpoint}retailerBranding/SquareIcons/${t}.png`,o.setAttribute("aria-hidden","true");const r=(0,Y.Ux)("IMG");r.setAttribute("aria-hidden","true"),r.src=this.flyoutData.common.resourcesEndpoint+"pinterest/icon.png",r.style.position="absolute",r.style.top="46px",r.style.zIndex="2",o.addEventListener("error",(()=>{e.style.gridTemplateColumns="auto",e.style.textAlign="center",e.style.justifyContent="center",e.style.height="auto",o.remove(),r.remove()})),i.appendChild(o),i.appendChild(r),e.appendChild(i)}}(this.flyoutData).createCouponHeader(n?.FriendlyDomainName,n?.DomainName,n?.Coupons.length,e)}else if(!t?.canRenderCashback||t?.isCashBackActivated||t?.isPersonalizedCashback||t?.isSignInSupportedDomainCashBack||!n?.Coupons||this.flyoutData.common.isDiscoverPane||this.flyoutData.common.suppressRebatesScenarios)if((0,dt.tB)(this.flyoutData))if(n?.Coupons.length&&this.canRenderAutoApplyButton()){const t=await sy.getAutoApplyContent(this.flyoutData.strings.couponTitle,n,this.pageHandlerModule);e.appendChild(t),this.renderBGAAInfo(a,l,t)}else this.utilities.applyStyles(e,this.assets.getEmptyHeaderStyles());else{const t=(0,Y.Ux)("h2",{className:"txtLarge lateralMargin"});t.style.textAlign="center",t.style.fontWeight="500",t.style.display="flex",t.style.flexDirection="row",t.style.alignItems="center",t.style.justifyContent="center",this.flyoutData.common.isDiscoverPane&&(t.style.marginTop="12px");const r=this.acUtilities.hasOnlyAttainableCoupons(),s=this.acUtilities.isCouponAttained(),h=r&&this.acUtilities.lastAttainableCoupon;t.textContent=a===i.ps.Negative?this.flyoutData.strings.bgaaFailedTitle:this.isPDP&&d?void 0!==c&&null!=c&&void 0!==c?.AverageSavings&&c?.SellerName?(0,T.fZ)("pdpTitle",this.flyoutData.strings.savePDPTitle,c?.SellerName??""):this.flyoutData.strings.savePDPTitleNoTrivia:h?s?this.flyoutData.strings.attCouponHeaderUnlocked:this.flyoutData.strings.attCouponHeaderLocked:this.flyoutData.strings.couponTitle,this.utilities.shouldRenderSmallNotification()?(t.style.marginBottom="6px",t.style.marginTop="4px"):(t.style.marginBottom="12px",t.style.marginTop=o?t.style.marginTop:"12px"),t.slot="header-content";const p=this.createCopyCouponDisclosureTooltip("copyCouponDisclosureHeader");if(t.appendChild(p),e.appendChild(t),a===i.ps.Positive||a===i.ps.Negative||this.instantSavings)this.renderBGAAInfo(a,l,t);else if(u){t.style.fontSize="20px",t.style.lineHeight="28px",t.style.height="28px",t.style.marginTop="0px",t.textContent="";const i=this.flyoutData.strings.couponSectionPanePluralTitle.split(" "),o=this.flyoutData.common.isStorybook;let r=0;for(const e of i){const i=(0,Y.Ux)("span",{className:"refresh"},e);o&&(i.style.animation="none"),i.style.animationDelay=`${r}s`,t.append(i),r+=.1}const a=this.createCopyCouponDisclosureTooltip("");a.classList.add("refresh"),a.style.marginTop="0",a.style.paddingLeft="0",a.style.marginRight="0",a.style.overflow="visible",a.style.animationDelay=`${r}s`,t.append(a),this.utilities.applyStyles(e,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),this.isCjkEnabled&&this.utilities.applyStyles(e,this.cjkAssets.getStyles(),void 0,this.cjkAssets.getDarkModeStyles());const s=document.querySelector(":root");if(s){const t=(0,Y.Ux)("section",{id:"carousel",slot:"header-content",className:"lateralMargin"});t.setAttribute("aria-label",this.flyoutData.strings.couponCarouselLabel);const i=(0,Y.Ux)("ul",{id:"track",className:"stationary"}),r=(n?.Coupons??[]).map((e=>e.couponCode));for(const e of[...new Set(r)]){const t=(0,Y.Ux)("li",{className:"txtSmall coupon"}),n=(0,Y.Ux)("p",{},e);t.append(n),i.append(t)}t.append(i),e.append(t),o||(s.style.setProperty("--slide-count",`${r.length}`),this.setCarouselTelemetry(t),this.setTrackWidth(s),this.setTrackAnimation())}}}else{const t=await this.createMergedTitle();t&&(t.style.textAlign="center",t.slot="header-content"),e.appendChild(t)}}async PostProcessing(e,t,n){if(e===r.ModuleNames.EMPTYCOUPON){const e=this.stateManagement.getState(Ku.IY.topModulePriority)!==r.H7.MAX;this.HandleEmptyModule(n,e)}else 0===t&&(this.canRenderAutoApplyButton()&&this.createAutoApplyButton(),this.flyoutData.common.isDiscoverPane&&(this.discoverTelemetryHandler.LogEventTelemetry(i.xu.CouponDiscoverRender,"Coupon Discover Render","",r.ModuleNames.COUPON),this.pageHandlerModule.RecordAsContentViewed(bp.r.COUPONS_AVAILABLE)));(0,x.mE)(n,this.GetModuleName())}async populateCouponList(t,n,o,a){let s,l=this.acUtilities.filterAttainableCouponList();if(l=await this.FilterInboxCouponsForLoggedOutUsers(l),l){l.length>0&&(s=l.length);let h=0;if(n){const t=new W.Z(i.$S.SeeMoreCoupons,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.pageHandlerModule.RecordAsUserAction(K.bS.VIEW_MORE_COUPONS),this.isCjkEnabled&&(this.pageHandlerModule.RecordAsUserAction(K.bS.CJK_COUPONS_SEE_MORE),this.pageHandlerModule.RecordAsCjkScenario(Hg.ACTION,Ug.COUPONS_SEE_MORE),this.cjkDataVendor&&this.cjkDataVendor in $g&&this.pageHandlerModule.RecordAsCjkScenario(Hg.ACTION+$g[this.cjkDataVendor],Ug.COUPONS_SEE_MORE)),this.LogInfoEvent(i.R.ButtonClick,"",t),h=this.isPaneOnlyModule?r.CS.COUPONPANE:r.CS.TWO_COUPON_ON_START,e.R.isExperimentActive(f.H.CouponsPersonalization)&&await this.autoOpenControllerUtilities.userEngagementStoreManager.addEngagement(q.w1.POSITIVE,this.flyoutData.common.popupOrigination,r.ModuleNames.COUPON.toString(),cy.e.userEngagementCouponWeights.seeMoreCouponsWeight,i.$S.SeeMoreCoupons)}else this.isPaneOnlyModule&&s>r.CS.COUPONPANE&&"viewAll"!==a?s=r.CS.COUPONPANE:s>r.CS.TWO_COUPON_ON_START&&"viewAll"!==a&&(s=r.CS.TWO_COUPON_ON_START);let p=null;if(n||this.flyoutData.common.isPane?(p=t.querySelector("#divCouponWrapper"),p?!n&&this.isPaneOnlyModule&&(p.remove(),p=(0,Y.Ux)("DIV"),p.id="divCouponWrapper"):(p=(0,Y.Ux)("DIV"),p.id="divCouponWrapper")):(p=(0,Y.Ux)("DIV"),p.id="divCouponWrapper"),n){const e=new CustomEvent(Ku.e1.SeeMoreClick,{detail:{totalCards:l.length}});p.dispatchEvent(e)}if(p.classList.add("lateralMargin"),p)if(this.isCjkEnabled)for(let e=h;e<s;e++)this.createCJKCouponTile(p,l[e],a,h,n,o,e,s),n||t.appendChild(p);else{c=Qv,d={rawCouponData:l,utilities:this.utilities,renderItems:s,isDarkMode:this.utilities.isDarkMode(),pageHandler:this.pageHandlerModule,LogInfoEvent:this.LogInfoEvent.bind(this),popupOrigination:this.flyoutData.common.popupOrigination,telemetryUtilities:this.telemetryUtilities,moduleName:this.GetModuleName()},u=p,sp.render(ch.createElement(c,d),u);for(let e=h;e<s;e++)n||t.appendChild(p)}const g=this.flyoutData;this.stateManagement.addEventListener(Ku.e1.onCashBackActivated,(()=>{const e=g.common.shopping.querySelectorAll("msft-shopping-coupon-new");e&&e.length>0&&e.forEach((e=>{e.className.includes("isStackable")||(e.cashbackNonstackableMessage=g.strings.cbNonStackableCoupon)}))}))}var c,d,u}async createAutoApplyButton(){const n=this.flyoutData.common.shopping.querySelector("#divAutoApplyActions");if(this.flyoutData.common.shopping&&!n){const n=this.flyoutData.dataStoreModule.CashBackData,o=this.flyoutData.dataStoreModule.CashBackData?.canRenderCashback,a=n?.isCashBackActivated,s=this.flyoutData.dataStoreModule.CouponData?.BgaaResultState,l=(0,Y.Ux)("DIV");l.id="divAutoApplyActions",l.style.width="100%",l.slot="actions",l.style.display="flex",l.style.justifyContent="center",l.style.alignItems="center",l.style.flexDirection="column";const c=(0,Y.lw)(this.utilities);c.id="autoApplyButton";let d=!1,h=!1;if(!o||a||n?.isSignInSupportedDomainCashBack)d=s===i.ps.Positive,h=d||s===i.ps.Negative,c.textContent=(0,dt.tB)(this.flyoutData)?this.flyoutData.strings.couponAutoApplyButton:s===i.ps.Negative?this.flyoutData.strings.couponAutoApplyButtonRetry:this.instantSavings?this.flyoutData.strings.couponAutoApplyButtonInstantSavings:this.flyoutData.strings.couponAutoApplyButtonAlt,s!==i.ps.Positive&&s!==i.ps.Negative||!h||(c.style.marginTop="12px"),(0,dt.tB)(this.flyoutData)&&c.classList.add("safari-auto-apply-btn"),l.appendChild(c),l.classList.add("lateralMargin");else{if(this.flyoutData.common.isPane||l.classList.add("lateralMargin"),c.textContent=this.flyoutData.strings.mergedNewAutoApplyButton,this.flyoutData.common.isPane&&(c.style.fontSize="14px"),l.appendChild(c),this.utilities.shouldRenderSmallNotification())l.style.marginTop="12px";else{const t=(0,Y.Ux)("fluent-button");t.style.fontWeight="600",t.setAttribute("appearance","lightweight"),t.textContent=this.flyoutData.strings.couponAutoApplyWithoutCB,t.addEventListener("click",(async()=>{const t=new W.Z(i.$S.AutoApply,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.pageHandlerModule.RecordAsUserAction(K.bS.TRY_ALL_COUPONS),this.pageHandlerModule.RecordAsUserEngagement(q.FV.TRY_ALL_COUPONS,this.flyoutData.common.popupOrigination),this.LogInfoEvent(i.R.ButtonClick,"",t),await this.autoOpenControllerUtilities.pauseAutoOpenForPopupOrigination(u.sR.AUTO_SHOW_COUPONS_CHECKOUT),e.R.isExperimentActive(f.H.CouponsPersonalization)&&await this.autoOpenControllerUtilities.userEngagementStoreManager.addEngagement(q.w1.POSITIVE,this.flyoutData.common.popupOrigination,r.ModuleNames.COUPON.toString(),cy.e.userEngagementCouponWeights.autoApplyWeight,i.$S.AutoApply),this.pageHandlerModule.ApplyAllCoupons(d)})),l.appendChild(t)}if(n&&!n.isPersonalizedCashback&&n.categories.length>0&&this.flyoutData.common.isPane){const[e,t]=this.cashbackUtilities.createCashbackOfferDetails(!1,n,(()=>{}));t.style.margin="unset";const i=(0,Y.Ux)("div",{id:"offerDetailsContentWrapper"});i.appendChild(e),l.appendChild(i);const o=(0,Y.Ux)("div",{id:"cashbackSeeMoreWrapper"});o.appendChild(t),l.appendChild(o)}this.pageHandlerModule.RecordAsContentViewed(bp.r.REBATES_ACTIVATE_CASHBACK);const o=new t.Z(i.xu.ModuleViewed);let a=`${bp.r.REBATES_ACTIVATE_CASHBACK}`;if(a+=" merged with coupons at checkout",this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,a,o),n){let e,t,o;n.highestCashBackCategory?(e=n.highestCashBackCategory.category,t=n.highestCashBackCategory.commissionType,o=n.highestCashBackCategory.commissionValue):n.personalizedCashback&&(e=n.personalizedCashback.scope,t=n.personalizedCashback.commissionType,o=n.personalizedCashback.commissionValue);const r=new qp(e,t,o,this.flyoutData.common.domain,n.affiliateNetwork,i.E_.Bing,n.userRebatesResponse?.isRebatesUser,n.IsRebatesSupportedDomain?.toString()??"",n.isSignInSupportedDomain,n.merchantFullName,"merged with AA",!!this.estimatedCashbackData,(0,fg.U)(this.flyoutData.dataStoreModule.ApiData?.retailerData,this.flyoutData.common.lastCommittedURL,this.flyoutData.common.extractedEntity));this.logModule.LogInfoEvent(i.R.CashbackInfo,"",r,Jl.g.CouponImpressionId)}}const p=this.flyoutData.common.currentDevice;if(c.addEventListener("click",(async()=>{if(p===r.AS.Desktop){let e=i.$S.AutoApply;h&&(e=d?i.$S.BackgroundAutoApplyPositive:i.$S.BackgroundAutoApplyNegative);const t=new W.Z(e,this.telemetryUtilities.setContentViewed(this.GetModuleName()));if(this.LogInfoEvent(i.R.ButtonClick,"",t),!a&&o&&!n?.isSignInSupportedDomainCashBack){const e=this.createClickData(i.$S.ActivateCashBack,n);this.LogInfoEvent(i.R.ButtonClick,"Cash back activated - merged scenario",e),c.disabled=!0;const t=new CustomEvent(Ku.e1.StyleProcessingState,{detail:{target:c}});if(this.stateManagement.dispatchEvent(t),(await this.pageHandlerModule.ActivateRebates(!0)).activated){const e=new CustomEvent(Ku.e1.onCashBackActivatedForRewards);this.stateManagement.dispatchEvent(e)}}}if(a||!o||n?.isSignInSupportedDomainCashBack){if(h){const e=d?i.pW.PositiveResultClicked:i.pW.NegativeResultClicked;this.pageHandlerModule.SendBackgroundAAMetrics(e)}}else this.utilities.isPinterest()?(this.pageHandlerModule.RecordAsUserAction(K.bS.PINTEREST_CASHBACK_ACTIVATED),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PINTEREST_CASHBACK_ACTIVATED,this.flyoutData.common.popupOrigination)):(this.pageHandlerModule.RecordAsUserAction(K.bS.ACTIVATE_CASHBACK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.ACTIVATE_CASHBACK,this.flyoutData.common.popupOrigination));this.pageHandlerModule.RecordAsUserAction(K.bS.TRY_ALL_COUPONS),this.pageHandlerModule.RecordAsUserEngagement(q.FV.TRY_ALL_COUPONS,this.flyoutData.common.popupOrigination),await this.autoOpenControllerUtilities.pauseAutoOpenForPopupOrigination(u.sR.AUTO_SHOW_COUPONS_CHECKOUT),this.pageHandlerModule.ApplyAllCoupons(d),e.R.isExperimentActive(f.H.CouponsPersonalization)&&await this.autoOpenControllerUtilities.userEngagementStoreManager.addEngagement(q.w1.POSITIVE,this.flyoutData.common.popupOrigination,r.ModuleNames.COUPON.toString(),cy.e.userEngagementCouponWeights.autoApplyWeight,i.$S.AutoApply)})),this.flyoutData.common.shouldShowCookieConsent&&"en-us"!==this.flyoutData.common.market){const e=this.createCookieConsent();e&&l.appendChild(e)}this.flyoutData.common.shopping.prepend(l);const g=new t.Z(i.xu.AutoApplyButtonShown);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"",g)}}createInfoBannerDiv(){const e=(0,Y.Ux)("DIV");return e.slot="start-content",e.style.width="100%",this.utilities.shouldRenderSmallNotification()||(e.style.minHeight="30px"),e.style.justifyContent="center",e.style.alignItems="center",e.style.display="flex",e}setShouldRenderReason(e){this.shouldRenderReason=e}async renderInfoBanner(e,t,i){await this.acUtilities.shouldCreateBanner(t)&&this.acUtilities.createBanner(e),this.canRenderAutoApplyButton()&&this.CreateCouponExpectation(e)}setTrackWidth(e,t=0){setTimeout((()=>{const i=document.querySelector("#track").offsetWidth;i>0?e.style.setProperty("--track-width",`${i+17}px`):t<4&&this.setTrackWidth(e,t+1)}),20+10*t)}setTrackAnimation(e=0){setTimeout((()=>{const t=document.querySelector("#carousel"),i=t.querySelector("#track");if(i&&i?.offsetWidth>0&&t?.offsetWidth>0&&i?.offsetWidth>t?.offsetWidth){const e=[...i.cloneNode(!0).children];e&&e.length>0&&e.forEach((e=>{i.append(e)})),i.classList.remove("stationary")}else e<4&&this.setTrackAnimation(e+1)}),20+10*e)}setCarouselTelemetry(e){let n=0;e.addEventListener("mouseenter",(async()=>{n=Date.now()})),e.addEventListener("mouseleave",(()=>{const e=Date.now()-n;if(e>=1e3)try{const n=new t.Z(i.xu.CouponCarouselHover);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,`Hovered over coupon carousel for ${e} ms`,n),this.pageHandlerModule.RecordAsUserEngagement(q.FV.COUPONS_COPIED,this.flyoutData.common.popupOrigination)}catch(e){const n=new t.Z(i.xu.ErrorToRecordEngagement);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,e,n)}}))}async CreateCouponExpectation(e){if(this.expectation===i.Iy.Medium||this.expectation===i.Iy.None)return;const t=await this.createHeaderDiv();this.createAndAppendCouponExpectation(t,this.expectation),e.prepend(t)}getCouponRates(){const e=this.acUtilities.filterAttainableCouponList();return e&&e.length>0?e.filter((e=>void 0!==e.successRate)).map((e=>e.successRate)):[]}async createHeaderDiv(){const e=(0,Y.Ux)("DIV",{style:"width: 100%;\n display: flex;\n align-items: center;\n flex-direction: column"});return e.style.marginTop="12px",e.style.marginBottom="4px",e}async createAndAppendCouponExpectation(t,i){const n=this.getIconSrcForExpectation(i),o=this.getTooltipContentForExpectation(i),r=this.getLocalizedExpectation(i),a=this.createHeaderRow(this.flyoutData.strings.couponExpectationHeader,r,n,o);e.R.isExperimentActive(f.H.incentiveCampaign)&&void 0!==this.flyoutData.dataStoreModule.IncentiveCampaignData&&!this.flyoutData.dataStoreModule.IncentiveCampaignData.isRewardClaimed||t.append(a)}getExpectation(){const e=this.getCouponRates(),t=this.getTriviaData();if(0===t?.SuccessRate)return i.Iy.Low;if(this.isHighTrafficDomain())return i.Iy.Low;if(!e||0===e.length)return i.Iy.None;const n=Math.max.apply(null,e);return n>=75||n>=50?i.Iy.High:i.Iy.None}isHighTrafficDomain(){const e=this.flyoutData.dataStoreModule.ApiData?.retailerData;return!(!e||!e.isHighTrafficDomain)&&e.isHighTrafficDomain}getIconSrcForExpectation(e){return this.flyoutData.common.resourcesEndpoint+"couponExpectation/"+e+".svg"}getTooltipContentForExpectation(e){return e===i.Iy.High?this.flyoutData.strings.highCouponExpectationTooltip:e===i.Iy.Medium?this.flyoutData.strings.mediumCouponExpectationTooltip:e===i.Iy.Low?this.flyoutData.strings.lowCouponExpectationTooltip:""}getLocalizedExpectation(e){return e===i.Iy.High?this.flyoutData.strings.couponExpectationHigh:e===i.Iy.Medium?this.flyoutData.strings.couponExpectationMedium:e===i.Iy.Low?this.flyoutData.strings.couponExpectationLow:e}createHeaderRow(e,t,i,n){const o=this.createInfoBannerDiv();return this.createAndAppendIcon(o,i),this.createAndAppendContent(o,e,t,n),o}async createAndAppendIcon(e,t){const i=this.createIcon(t);this.utilities.shouldRenderSmallNotification()?(i.style.marginRight="9px",i.style.width="14px"):(i.style.marginRight="10px",i.style.width="22px"),e.append(i)}async createAndAppendContent(e,t,i,n){const o=(0,Y.Ux)("DIV",{style:"display:flex;\n align-items: center;"});this.createAndAppendNormalContent(o,t,!1),this.createAndAppendNormalContent(o,i,!0),this.createAndAppendTooltip(o,n),e.append(o)}async createAndAppendNormalContent(e,t,i){let n;n=this.utilities.shouldRenderSmallNotification()?this.create12pxExpectationSpan(i):this.create16pxExpectationSpan(i),n.textContent=t,n.style.marginRight=i?"6px":"4px",e.append(n)}async createAndAppendTooltip(e,t){if(t){const i=this.tooltipUtilities.createInfoIconTooltip(t);i.width="200px",i.classList.add("couponTooltip"),this.utilities.shouldRenderSmallNotification()&&i.classList.add("small"),this.configureTooltipEventListeners(i),this.configureTooltipCaratSizes(i),e.append(i)}}configureTooltipEventListeners(n){let o=!0,a=Date.now();this.addTooltipEventListeners(n,(async()=>{if(o){a=Date.now();const n=new t.Z(i.xu.CouponExpectationTooltipOpen);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Coupon expectation - tooltip opened",n),o=!1,e.R.isExperimentActive(f.H.CouponsPersonalization)&&await this.autoOpenControllerUtilities.userEngagementStoreManager.addEngagement(q.w1.POSITIVE,this.flyoutData.common.popupOrigination,r.ModuleNames.COUPON.toString(),cy.e.userEngagementCouponWeights.tooltipWeight)}}),(async()=>{if(!o){if(Date.now()-a>2e3){const n=new t.Z(i.xu.CouponExpectationTooltipRead);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Coupon expectation - tooltip hovered >2s",n),e.R.isExperimentActive(f.H.CouponsPersonalization)&&await this.autoOpenControllerUtilities.userEngagementStoreManager.addEngagement(q.w1.POSITIVE,this.flyoutData.common.popupOrigination,r.ModuleNames.COUPON.toString(),cy.e.userEngagementCouponWeights.tooltipWeight)}o=!0,n.className="btnTooltip"}}))}addTooltipEventListeners(e,t,i){e.addEventListener("mouseenter",(()=>{t()})),e.addEventListener("mouseleave",(()=>{i()})),e.addEventListener("focus",(()=>{t()})),e.addEventListener("blur",(()=>{i()}))}configureTooltipCaratSizes(e){e.addEventListener("hover",(()=>{this.tooltipUtilities.setupTooltip(e)})),e.addEventListener("focus",(()=>{this.tooltipUtilities.setupTooltip(e)}))}createCookieConsent(){const e=(0,Y.Ux)("DIV",{className:"divCookies",style:"margin: 10px 10px 12px; text-align: left;line-height: 16px; font-size: 12px;"}),t=(0,Y.Ux)("P",{className:"txtSmall"});t.style.display="inline",t.style.fontSize="12px";const i=document.createElement("fluent-anchor");if(i.id="aPrivacy",i.setAttribute("href","#"),i.style.fontSize="12px",i.textContent=this.flyoutData.strings.commonMicrosoftPolicy,i.setAttribute("appearance","hypertext"),i.style.display="inline",this.flyoutData.dataLoader.IsServerData()){const e=document.createElement("fluent-anchor");e.id="thirdPartyConsent",e.setAttribute("href","#"),e.className+=" txtSmall",e.style.fontSize="12px",e.style.verticalAlign="bottom",e.textContent=this.flyoutData.strings.thirdPartCookiesText,e.setAttribute("appearance","lightweight"),e.style.display="inline",(0,T.B7)(t,this.flyoutData.strings.privacyConsentNew,e,i),this.flyoutData.dataLoader.IsServerData()&&e&&e.addEventListener("click",(()=>{this.pageHandlerModule.NavigateToPrivacyStatement()}))}else(0,T.B7)(t,this.flyoutData.strings.privacyConsent,i);return e.appendChild(t),i&&i.addEventListener("click",(()=>{this.pageHandlerModule.NavigateToPrivacyStatement()})),e}createIcon(e){const t=(0,Y.Ux)("IMG");return t.src=e,t.setAttribute("aria-hidden","true"),t}createBgaaTitleStyle(e,t,i,n,o){e.className=t,e.style.textAlign=i,e.style.fontWeight=n,e.textContent=o}createBgaaContainer(e,t){const i=(0,Y.Ux)("DIV");return i.style.width="100%",i.style.display="flex",i.style.flexDirection="column",i.style.justifyContent="space-between",i.appendChild(e),i.appendChild(t),i}create16pxExpectationSpan(e){const t=this.createSavingsSpan();return t.style.fontSize="16px",e||(t.style.fontWeight="400",t.style.color=this.utilities.isDarkMode()?"#B0B0B0":"#6C6C6C"),t}create12pxExpectationSpan(e){const t=this.createSavingsSpan();return t.style.fontSize="12px",t.style.lineHeight="16px",e||(t.style.fontWeight="400",t.style.color=this.utilities.isDarkMode()?"#B0B0B0":"#6C6C6C"),t}createSavingsSpan(){return(0,Y.Ux)("SPAN",{style:"display: inline; vertical-align: middle; color: var(--neutral-foreground-rest); font-size: 12px; font-weight: bold;"})}renderBGAAInfo(e,t,n){const o=this.flyoutData.dataStoreModule.CouponData;if(e===i.ps.Positive||e===i.ps.Negative){let n;const r=(0,Y.Ux)("H2"),a=(0,Y.Ux)("H2"),s=(0,Y.Ux)("H2"),l=(0,Y.Ux)("H2");if(e===i.ps.Positive)n=i.pW.PositiveResultShown,o&&(o.BgaaViewedContent=n.toString()),this.createBgaaTitleStyle(r,"txtMedium","center","300",this.flyoutData.strings.bgaaSuccessLeftTitle),this.createBgaaTitleStyle(a,"txtLarge","center","500","$"+t),this.createBgaaTitleStyle(s,"txtMedium","center","300",this.flyoutData.strings.bgaaSuccessRightTitle),this.createBgaaTitleStyle(l,"txtLarge","center","500",this.flyoutData.strings.bgaaSuccessRightText);else{let e;n=i.pW.NegativeResultShown,o&&(o.BgaaViewedContent=n.toString()),e=o&&o.Coupons&&o.Coupons.length>0?1===o.Coupons.length?(0,T.dK)(this.flyoutData.strings.couponSectionTitleStr,i.T4.One):(0,T.dK)(this.flyoutData.strings.couponSectionTitleStr,i.T4.Other,o.Coupons.length):this.flyoutData.strings.bgaaFailedLeftTitle,this.createBgaaTitleStyle(r,"txtMedium","center","300",e),this.createBgaaTitleStyle(a,"txtMedium","center","500",this.flyoutData.strings.bgaaFailedLeftText),a.style.color=this.utilities.isDarkMode()?"#FFFFFF":"#228B22",this.createBgaaTitleStyle(s,"txtMedium","center","300",this.flyoutData.strings.bgaaFailedRightTitle),this.createBgaaTitleStyle(l,"txtMedium","center","500",this.flyoutData.strings.bgaaFailedRightText)}this.pageHandlerModule.SendBackgroundAAMetrics(n);const c=this.createBgaaContainer(r,a),d=this.createBgaaContainer(s,l),u=(0,Y.Ux)("DIV");u.style.height="auto",u.style.width="1px",u.style.border="1px solid #00FFFF";const h=(0,Y.Ux)("DIV");h.style.top="4px",h.style.width="100%",h.style.display="flex",h.style.justifyContent="space-between",h.appendChild(c),h.appendChild(u),h.appendChild(d),h.slot="header-content",this.flyoutData.common.shopping.appendChild(h)}else if(this.instantSavings){n.textContent=this.flyoutData.strings.couponTitleInstantSavings;const e=this.createCopyCouponDisclosureTooltip("copyCouponDisclosureHeader");n.appendChild(e);const t=(0,Y.Ux)("DIV");t.textContent=this.instantSavings,t.slot="header-content",t.className="txtLarge txtInstantSavings",t.style.textAlign="center",t.style.fontWeight="600",t.style.marginBottom="12px",this.flyoutData.common.shopping.appendChild(t)}}createCopyCouponDisclosureTooltip(e){const t=this.flyoutData.strings.copyCouponDisclosureText,i=this.tooltipUtilities.createInfoIconTooltip("","",(()=>{this.pageHandlerModule.NavigateToPrivacyStatement()}));i.id=e,i.width="200px",i.style.marginTop="5px",i.style.paddingLeft="3px",i.style.marginRight="-7px",i.isTextHoverable=!0;const n=(0,Y.Ux)("p");n.style.fontSize="10px",n.style.lineHeight="14px";const o=(0,Y.Ux)("a",{style:"\n cursor: pointer;\n text-decoration: none;\n color: #2169EB;\n "});return o.textContent=this.flyoutData.strings.commonMicrosoftPolicy,o.setAttribute("aria-label","Navigate To Privacy Statement"),(0,T.B7)(n,t,o),i.contentElement=n.outerHTML,i}applyStylesToAccordionTooltip(e){e.style.marginTop="0px",e.style.paddingLeft="0px",e.style.marginRight="0px",e.style.position="absolute",e.style.zIndex="1",e.style.left="149px",e.style.top="-29px"}createCJKCouponTile(e,t,i,n,o,a,s,l){const c=document.createElement("msft-shopping-coupon-cjk");c.className="couponBackgroundCJK";const d=document.createElement("amount");d.innerText="¥"+t.quota,d.className="couponAmountCJK",c.ariaSetSize=l.toString(),c.ariaPosInSet=(s+1).toString(),c.tabIndex=0;const u=document.createElement("text-container-cjk"),h=document.createElement("subtitle-upper");if(h.innerText=(0,T.fZ)("tipsMinimumPurchase",this.flyoutData.strings.tipsMinimumPurchase,"¥"+t.minimumPurchase.toString()),h.className=this.flyoutData.common.isPane?"couponSubtitleUpperCJK":"couponSubtitleUpperCJKFlyout",u.appendChild(h),t?.expireTime){const e=document.createElement("subtitle-lower");e.innerText=this.flyoutData.strings.cjkExpiryDate+t.expireTime,e.className="couponSubtitleLowerCJK",u.appendChild(e);const i=document.createElement("subtitle-lower");i.innerText=t.expireTime,(0,T.B7)(e,this.flyoutData.strings.cjkExpiryDate,i)}u.className="couponDecriptionTextContaineCJK";const p=document.createElement("amount-text-container");p.className="amountTextContainerCJK",p.appendChild(d),p.appendChild(u),c.appendChild(p);const g=document.createElement("coupon-button-cjk");g.className="couponButtonCJK",g.innerText=this.flyoutData.strings.cjkClaim,c.appendChild(g),c.style.setProperty("--coupon-success-color","#FFFFFF"),c.style.setProperty("--coupon-selected-color","#FFFFFF"),c.addEventListener("click",(async()=>{this.pageHandlerModule.NavigateToUrl(t.clickUrl),this.sendCouponsClickTelemetryOnCJKSites()})),c.addEventListener("keydown",(async e=>{"Enter"!==e.key&&" "!==e.key||(this.pageHandlerModule.NavigateToUrl(t.clickUrl),this.sendCouponsClickTelemetryOnCJKSites())})),e.appendChild(c);const f=this.flyoutData.common.currentDevice;s===n&&o&&a&&f===r.AS.Desktop&&c&&c.focus()}getSectionTitle(){let e;return this.flyoutData.dataStoreModule.CouponData?this.isCjkEnabled?this.flyoutData.strings.couponFeatureName:(e=1===this.flyoutData.dataStoreModule.CouponData.Coupons.length?(0,T.dK)(this.flyoutData.strings.couponSectionTitleStr,i.T4.One):this.flyoutData.common.isPane||(0,dt.tB)(this.flyoutData)?this.flyoutData.strings.couponSectionPanePluralTitle:(0,T.dK)(this.flyoutData.strings.couponSectionTitleStr,i.T4.Other,this.flyoutData.dataStoreModule.CouponData.Coupons.length),e):""}hasSocialSelectors(){const e=this.flyoutData.dataStoreModule.ApiData?.retailerData;return!!(e&&e.allCheckoutPages&&e.allCheckoutPages.length>0&&e.allCheckoutPages[0].socialSelectors)}async createMergedTitle(){const e=(0,Y.Ux)("DIV");e.setAttribute("role","heading"),e.setAttribute("aria-level","2"),e.style.margin=this.flyoutData.common.openedWith===r.Te.Auto?"0 20px":"0 10px";const t=(0,Y.Ux)("h2",{id:"h2RebatesTitle"}),n=this.flyoutData,o=this.flyoutData.dataStoreModule.CashBackData,a=this.getTriviaData(),s=await(o?.getEstimatedCashbackData(this.flyoutData,this.storageHandler,this.logModule));this.estimatedCashbackData=s;const l=this.utilities.shouldRenderSmallNotification()?zu.h.Medium:void 0,c=this.utilities.createCommissionArrow(s?.cashbackValue,!!s?.cashbackValue,l);if(c){const e=n.dataStoreModule.CouponData?.Coupons?.length;if(e&&e>1){let n;n=this.isPDP?null!=a&&void 0!==a?.AverageSavings&&a?.SellerName?(0,T.fZ)("pdpTitle",this.flyoutData.strings.savePDPTitle,a?.SellerName??""):this.flyoutData.strings.savePDPTitleNoTrivia:s?(0,T.dK)(this.flyoutData.strings.cbMergedTitleEstimateStr,i.T4.Other,e):(0,T.dK)(this.flyoutData.strings.cbMergedTitleStr,i.T4.Other,e),(0,T.B7)(t,n,c)}else(0,T.B7)(t,s?(0,T.dK)(this.flyoutData.strings.cbMergedTitleEstimateStr,i.T4.One):(0,T.dK)(this.flyoutData.strings.cbMergedTitleStr,i.T4.One),c);const o=new tg;this.utilities.applyStyles(this.flyoutData.common.shopping,o.getStyles(),void 0,o.getDarkModeStyles())}const d=this.tooltipUtilities.createCashbackTooltip(this.pageHandlerModule,this.logModule);return t.appendChild(d),e.appendChild(t),e}getTriviaData(){return this.flyoutData.dataStoreModule.CouponData?.Trivia}HandleEmptyModule(e,n){if(this.emptyDiv)if(n)this.emptyDiv.style.display="none",e.classList.add("emptyCouponSectionTitle"),e.accordion=!1;else{e.accordion=!0,e.expanded=!0;const n=new t.Z(i.xu.EmptyCoupons);this.LogInfoEvent(i.R.EdgeFlyoutStatus,"Empty coupons image was shown",n)}}LogInfoEvent(e,t,n){try{this.flyoutData.common.isDiscoverPane&&e===i.R.ButtonClick&&this.discoverTelemetryHandler.LogClickTelemetry(i.xu.CouponDiscoverButtonClick,"","",r.ModuleNames.COUPON,{buttonName:n.ButtonClicked??void 0,message:t}),this.logModule.LogInfoEvent(e,t,n,Jl.g.CouponImpressionId)}catch(e){}}isValidCheckoutWithAA(){return!!this.flyoutData.dataStoreModule.CouponData?.isCheckoutPageWithAutoApply&&(!this.currentRetailerData?.isHomePageSameAsCheckout||this.currentRetailerData?.isHomePageSameAsCheckout&&this.acUtilities.cartValue>0)}canRenderAutoApplyButton(){const e=this.acUtilities.hasOnlyAttainableCoupons(),t=this.flyoutData.dataStoreModule.CouponData?.BgaaResultState,i=this.acUtilities.lastAttainableCoupon?.minimumPurchase??this.acUtilities.lastAttainableCoupon?.calculatedCutoffPrice??0;return!!(this.isValidCheckoutWithAA()&&!e||e&&this.acUtilities.lastAttainableCoupon&&i&&this.acUtilities.cartValue&&i<this.acUtilities.cartValue||t&&(0,dy.r)())}async FilterInboxCouponsForLoggedOutUsers(n){try{if(n&&e.R.isExperimentActive(f.H.shorelineinboxcoupons)&&(await this.storageHandler.getStorageString(Ce.Q.InboxCouponsUserConsented)||"")!==tt.oL)return n.filter((e=>!e.isPrivateCoupon))}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`InboxCoupons filtering Exception: ${(0,dt.YU)(e)}`,n)}return n}createClickData(e,t){return this.cashbackTelemetry.createClickData(e,this.GetModuleName(),t,this.estimatedCashbackData)}sendCouponsClickTelemetryOnCJKSites(){this.pageHandlerModule.RecordAsUserAction(K.bS.CJK_COUPONS_CLICK),this.pageHandlerModule.RecordAsCjkScenario(Hg.ACTION,Ug.COUPONS),this.cjkDataVendor&&this.cjkDataVendor in $g&&this.pageHandlerModule.RecordAsCjkScenario(Hg.ACTION+$g[this.cjkDataVendor],Ug.COUPONS)}},hy=class{constructor(){(0,s.Z)(this,"timeStamp",void 0),(0,s.Z)(this,"allowed",void 0),(0,s.Z)(this,"productBestCoupon",void 0)}},py=class extends Qu{constructor(e,t){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"domainName",void 0),this.assets=new iy,this.flyoutData=e,this.pageHandlerModule=t.pageHandlerModule,this.utilities=t.viewModulesUtilities,this.storageHandler=t.storageHandler,this.domainName=this.flyoutData.common.domain??(0,T.S8)()}GetModuleName(){return r.ModuleNames.BACKGROUND_AUTO_APPLY}async ShouldRenderModule(){const e=await this.GetBGAABestCoupon(),t=null!=e&&void 0!==e?.discountValue&&e?.discountValue>0;return Promise.resolve(t)}async renderModule(){if(null==await this.GetBGAABestCoupon())return Promise.resolve(null);const e=document.createElement("msft-edge-shopping-section"),t=this.CreateModule(e,r.H7.BGAA,r.ModuleNames.BACKGROUND_AUTO_APPLY,r.$k.CONTEXTUAL,r.SV.BLOCK);return Promise.resolve(t)}async populateMainHeader(){const e=await this.GetBGAABestCoupon();if(null==e)return Promise.resolve();const t=await this.createBGAANotificationContainer(e,!1);return this.flyoutData.common.shopping.appendChild(t),Promise.resolve()}async PostProcessing(e,t,i){return Promise.resolve()}ShowAlways(){return!1}GetAssets(){return null}CalculateRanking(){return r.zz.SaveMoneyPage}async createBGAANotificationContainer(e,t){const n=(0,Y.Ux)("DIV",{className:"lateralMargin"});n.id="divBGAAContainer",n.slot="header-content";const o=this.flyoutData.dataStoreModule.CouponData?.Coupons.length??0;if(o){const e=(0,Y.Ux)("h2",{className:"txtSmall",style:"text-align: center;font-weight: 450;"});e.innerText=(0,T.dK)(this.flyoutData.strings.bgaaModuleCouponCountMessage,1===o?i.T4.One:i.T4.Other,o),n.append(e)}const r=(0,Y.Ux)("h2",{className:"txtLarge",style:"text-align: center;font-weight: 600;line-height: 35px;"}),a=(0,Y.Ux)("span",{style:"color: #138757;"});a.innerText="$"+e.discountValue.toFixed(2).toString();const s=(0,Y.Ux)("span",{className:"txtMedium",style:"border: 3px dashed #138757;width: 80%;margin: 0 auto;border-radius: 6px;padding: 3px;"});s.innerText=e.couponCode,(0,T.B7)(r,this.flyoutData.strings.bgaaModuleMessage,a,s),r.addEventListener("click",this.handleBgaaClick.bind(this,e,t)),n.append(r);const l=(0,Y.lw)(this.utilities);return l.textContent=(0,T.fZ)("bgaaModuleApplyCoupon",this.flyoutData.strings.bgaaModuleApplyCoupon,e.couponCode),l.slot="actions",l.addEventListener("click",this.handleBgaaClick.bind(this,e,t)),n.appendChild(l),n}handleBgaaClick(e,t){this.pageHandlerModule.RecordAsUserAction(K.bS.TRY_BGAA_BEST_COUPON),this.pageHandlerModule.RecordAsUserEngagement(q.FV.TRY_BGAA_BEST_COUPON,this.flyoutData.common.popupOrigination);const i=new eg.B;i.action=eg.v.ApplyProductBestCoupon;const n=new hy;n.productBestCoupon=e,n.timeStamp=(new Date).toUTCString(),n.allowed=!0,i.data=n,this.storageHandler.setStorageString(Ce.Q.BGAAApplyButtonClicked,"true_"+this.domainName),this.pageHandlerModule.InitializeBackgroundAutoApplyNavigatorForBgaa(this.domainName,JSON.stringify(i)),t&&this.pageHandlerModule.DismissPopup()}async GetBGAABestCoupon(){const e="BackgroundAutoApplyData_"+this.domainName,t=await this.storageHandler.getStorageString(e);if(t){const e=(0,T.BQ)(t);if(e&&e.BestCoupon)return Promise.resolve(e.BestCoupon)}return Promise.resolve(null)}},gy=o(56005);const fy=(0,Zg.Z)({container:{display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",rowGap:"8px"}}),my=e=>{const t=ch.useRef(null),n=ch.useRef(null);(0,ch.useEffect)((()=>{const o=(0,Y.lw)(e.utilities);if(o.textContent=e.flyoutData.strings.cjkGetCoupon,o.className+=" lateralMargin",o.slot="actions",o.onclick=t=>{if(e.flyoutData.common.isPaneEnabled){const t=new W.Z(i.$S.SeePHGraph,e.telemetryUtilities.setContentViewed(r.ModuleNames.COUPON));e.logModule.LogInfoEvent(i.R.ButtonClick,"Click on coupon cjk Notification to open pane",t),e.pageHandler.RecordAsUserAction(K.bS.CJK_COUPONS_CHECK_COUPON),e.pageHandler.RecordAsUserEngagement(q.FV.CJK_COUPONS_CHECK_COUPON,e.flyoutData.common.popupOrigination),e.pageHandler.OpenPane(e.flyoutData.common.popupOrigination)}},t.current?.appendChild(o),n.current){const t=(0,Y.Ux)("SPAN");t.textContent="¥"+e.savedAmount,t.style.fontSize="22px",t.style.lineHeight="26px",t.style.fontWeight="600",t.style.color="#E8392C",(0,T.B7)(n.current,e.flyoutData.strings.cjkSaveWithCoupon,t)}}),[]);const o=fy();return ch.createElement(gm,{theme:e.isDarkMode?Bm:Lm},ch.createElement("div",{className:o.container,ref:t},ch.createElement(vy,{ref:n})))},vy=bm.span`
font-family: "Segoe UI", "Roboto", Helvetica, Verdana, sans-serif;
font-style: normal;
font-weight: 600;
font-size: 20px;
line-height: 26px;
text-align: center;
color: ${e=>e.theme.priceNotification.titleColor};
`;class yy{constructor(e,t,i,n,o){this.flyoutData=e,this.utilities=t,this.pageHandler=i,this.logModule=n,this.telemetryHandler=o,(0,s.Z)(this,"couponData",void 0),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"cjkAssets",void 0),this.couponData=e.dataLoader.GetLoadTimeDataValue("coupon",[]),this.assets=new iy,this.cjkAssets=new ny}RenderNotification(e){const{common:t}=this.flyoutData;this.utilities.applyStyles(t.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),this.utilities.applyStyles(t.shopping,this.cjkAssets.getStyles(),void 0,this.cjkAssets.getDarkModeStyles());const i=(0,Y.Ux)("div"),n=this.couponData[0];var o,r;o=ch.createElement(my,{savedAmount:n.quota,utilities:this.utilities,pageHandler:this.pageHandler,flyoutData:this.flyoutData,logModule:this.logModule,telemetryUtilities:this.telemetryHandler,isDarkMode:this.utilities.isDarkMode()}),r=i,sp.render(o,r);const a=this.utilities.createNotificationModule(i,this.GetNotificationName(),this);return Promise.resolve(a)}ShouldRenderNotification(){const e=this.flyoutData.common.openedWith===r.Te.Auto&&this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_CJK_COUPON_FOUND&&this.couponData.length>0;return Promise.resolve(e)}GetNotificationName(){return r.sM.COUPON}PostProcessingNotification(e,t){}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_CJK_COUPON_FOUND]}}class Cy{constructor(e,t,i){this.flyoutData=e,this.couponsModule=t,this.utilities=i,(0,s.Z)(this,"couponData",this.flyoutData.dataLoader.GetLoadTimeDataValue("coupon",[]))}async RenderNotification(e){const t=await this.couponsModule.renderModule();if(!t)return Promise.resolve(null);const i=(0,Y.Ux)("div");i.appendChild(t.element);const n=this.utilities.createNotificationModule(i,this.GetNotificationName(),this);return await Promise.resolve(n)}ShouldRenderNotification(){const e=this.flyoutData.common.openedWith===r.Te.Hover&&this.flyoutData.common.popupOrigination===u.sR.HOVER_BUTTON_SHOW_FLYOUT&&this.couponData.length>0;return Promise.resolve(e)}GetNotificationName(){return r.sM.COUPON}PostProcessingNotification(e,t){"MSFT-EDGE-SHOPPING-SECTION"!==t.previousElementSibling?.tagName?.toUpperCase()&&(t.expanded=!0)}GetPopupOriginationList(){return[u.sR.HOVER_BUTTON_SHOW_FLYOUT]}}var by=class extends uy{constructor(...e){super(...e),(0,s.Z)(this,"couponsCjkImpl",void 0)}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_COUPONS_CHECKOUT,u.sR.AUTO_SHOW_REBATES_CHECKOUT,u.sR.HOVER_BUTTON_SHOW_FLYOUT]}async RenderNotification(e){return this.InitializeCjkCouponsNotificationIfNeeded(),this.flyoutData.common.isCJKEnabled?this.couponsCjkImpl.RenderNotification(e):(this.populateMainHeader(),this.isPDP&&this.createPDPUX(),await this.footerUtilities.showFooter()&&this.flyoutData.common.shopping.classList.add("noSections"),Promise.resolve(this.utilities.createNotificationModule(document.createElement("DIV"),r.sM.COUPON,this)))}async ShouldRenderNotification(){let e=!1;if(this.InitializeCjkCouponsNotificationIfNeeded(),this.couponsCjkImpl)return e=await this.couponsCjkImpl.ShouldRenderNotification(),e||(this.shouldRenderReason="CJK Checks Failed"),e;this.isPDP=this.flyoutData.common.popupOrigination===u.sR.AA_CONSENT,e=await this.ShouldRenderModule(),e&&(this.flyoutData.common.openedWith!==r.Te.Auto?(this.shouldRenderReason="Not Opened With Auto",e=!1):this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_COUPONS_CHECKOUT||this.flyoutData.dataStoreModule.CouponData?.isCheckoutPageWithAutoApply&&this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_REBATES_CHECKOUT||this.isPDP?e=!0:(this.shouldRenderReason="Invalid popup origination or page type",e=!1));const n=this.flyoutData.common.popupOrigination;if(n&&this.GetPopupOriginationList().includes(n)&&!e){const e=new t.Z(i.xu.AutoOpenSuppressed),n={popupOrigination:this.flyoutData.common.popupOrigination,isPDP:this.isPDP,domain:this.flyoutData.common.domain,url:this.flyoutData.common.currentUrl};e.Metadata=JSON.stringify(n),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,this.shouldRenderReason??"Other",e)}return Promise.resolve(e)}GetNotificationName(){return r.sM.COUPON}PostProcessingNotification(e,t){this.PostProcessing(r.ModuleNames.COUPON,0,t),this.couponsCjkImpl?.PostProcessingNotification(e,t)}createPDPUX(){const e=(0,Y.Ux)("msft-shopping-section"),t=this.flyoutData.dataStoreModule.CouponData?.Trivia;e.slot="header-content",e.id="couponSection",this.utilities.applyStyles(e,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());const n=(0,Y.lw)(this.utilities);n.textContent=this.flyoutData.strings.pdpApplyCoupons,n.className+=" lateralMargin",n.slot="actions",this.flyoutData.common.shopping.append(e),this.flyoutData.common.shopping.append(n);const o=this.flyoutData.dataStoreModule.ApiData?.retailerData.domainName??"",a=new gy.Z;a.timeStamp=(new Date).toUTCString(),a.allowed=!1;try{this.storageHandler.setStorageString(gy.Z.GetAAConsentStorageKey(o),JSON.stringify(a))}catch(e){}let s;n.addEventListener("click",(()=>{const e=new W.Z(i.$S.AutoApplyConsent,this.telemetryUtilities.setContentViewed(this.GetNotificationName()));this.pageHandlerModule.RecordAsUserAction(K.bS.TRY_ALL_COUPONS),this.pageHandlerModule.RecordAsUserEngagement(q.FV.TRY_ALL_COUPONS,this.flyoutData.common.popupOrigination),this.logModule.LogInfoEvent(i.R.ButtonClick,"",e);const t=new gy.Z;t.timeStamp=(new Date).toUTCString(),t.allowed=!0;try{this.storageHandler.setStorageString(gy.Z.GetAAConsentStorageKey(o),JSON.stringify(t))}catch(e){}this.pageHandlerModule.DismissPopup()})),s=(0,Y.Ux)("DIV",{style:"align-items: center; width: calc(100% - 20px);"}),s.style.width="100%";const l=document.createElement("P");let c;l.id="pdpMessage",l.className="txtSmall";let d,u=`${r.iM.currency}${Number(t?.AverageSavings).toFixed(2)}`;u=(0,T.sk)(u),c=(0,Y.Ux)("SPAN"),c.textContent=u,c.style.color="var(--text-green-savings-color)",d=(0,Y.Ux)("SPAN"),d.textContent=t?.SellerName,(0,T.B7)(l,this.flyoutData.strings.pdpSubtitle,c,d),void 0!==t&&null!=t&&void 0!==t?.AverageSavings&&t?.SellerName&&(s.appendChild(l),this.flyoutData.common.shopping.append(s))}InitializeCjkCouponsNotificationIfNeeded(){this.flyoutData.common.isCJKEnabled&&!this.couponsCjkImpl&&(this.flyoutData.common.openedWith===r.Te.Hover?this.couponsCjkImpl=new Cy(this.flyoutData,this,this.utilities):this.couponsCjkImpl=new yy(this.flyoutData,this.utilities,this.pageHandlerModule,this.logModule,this.telemetryUtilities))}},Sy=class extends py{constructor(...e){super(...e),(0,s.Z)(this,"bestCoupon",null)}async RenderNotification(e){if(this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_COUPONS_BACKGROUND_AUTO_APPLY&&this.bestCoupon){const e=this.utilities.createNotificationModule(await this.createBGAANotificationContainer(this.bestCoupon,!0),this.GetNotificationName(),this);return await Promise.resolve(e)}return Promise.resolve(null)}async ShouldRenderNotification(){if(this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_COUPONS_BACKGROUND_AUTO_APPLY){const e=await this.GetBGAABestCoupon();if(e?.couponCode&&e?.discountValue)return this.bestCoupon=e,Promise.resolve(!0)}return Promise.resolve(!1)}GetNotificationName(){return r.sM.BGAA_NOTIFICATION}PostProcessingNotification(e,t){}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_COUPONS_BACKGROUND_AUTO_APPLY]}},xy=class extends Qu{constructor(e,t){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),this.logModule=t.logModule,this.pageHandlerModule=t.pageHandlerModule,this.flyoutData=e,this.utilities=t.viewModulesUtilities,this.telemetryUtilities=t.telemetryHandler}GetModuleName(){return r.ModuleNames.DEALS}ShouldRenderModule(){const e=this.flyoutData.dataStoreModule.CouponData,t=(e&&e.Deals&&e.Deals.length>0)??!1;return Promise.resolve(t)}renderModule(){const e=this.createElement("msft-edge-shopping-section");e.id="dealsSection",e.seeMoreSeparate=!0;const t=this.flyoutData.dataStoreModule.CouponData?.Deals;if(t){const i=t.length.toString()+" deal"+(t.length>1?"s":"");this.populateDealsList(e,!1,!1);const n=this.flyoutData;function o(e){let t=r.CS.DEAL;return e&&n.common.bannerContext===r.De.VIEWALL&&(t=e.length),t}this.utilities.createCommonListStructure(e,i,this.flyoutData.dataStoreModule.CouponData?.Deals,this.GetModuleName(),o,this.populateDealsList.bind(this))}return Promise.resolve(this.CreateModule(e,r.H7.DEALS,r.ModuleNames.DEALS,r.$k.CONTEXTUAL,r.SV.BLOCK))}populateDealsList(e,t,i){const n=this.flyoutData.dataStoreModule.CouponData?.Deals;if(n){let o=0;n.length>0&&(o=n.length);let a=0;t?a=r.CS.DEAL:o>r.CS.DEAL&&(o=r.CS.DEAL);for(let s=a;s<o;s++){const o=n[s],l=this.createDealsTile(o.headerText,o.id,o.offerUrl);e.appendChild(l),s===a&&t&&i&&this.flyoutData.common.currentDevice===r.AS.Desktop&&l&&l.focus()}}}populateMainHeader(){const e=this.flyoutData.common.shopping;if(e&&this.flyoutData.dataStoreModule.CouponData&&this.flyoutData.dataStoreModule.CouponData.Deals.length>0){const t=(0,Y.Ux)("DIV",{style:"width: 100%; overflow: hidden; position: relative; display: flex; flex-direction: row; justify-content: flex-start; column-gap: 10px;"}),i=(0,Y.Ux)("DIV",{style:"display: flex;\n flex-direction: column;\n justify-content: center;\n text-align:left;\n vertical-align: middle;"}),n=(0,Y.Ux)("P",{style:"font-weight: 600;\n color: var(--neutral-foreground-rest);\n place-self: center;"});n.className="txtLarge",n.style.fontSize="18px",n.style.lineHeight="21px";let o=(0,T.fZ)("dealsTitle",this.flyoutData.strings.dealsTitle,(0,Y.oZ)(this.flyoutData.dataStoreModule.CouponData.FriendlyDomainName));this.flyoutData.common.isPane||(t.style.marginBottom="13px"),n.style.fontWeight="400",n.style.placeSelf="unset",n.style.fontSize="20px",n.style.lineHeight="23px",o=(0,Y.oZ)(this.flyoutData.dataStoreModule.CouponData.FriendlyDomainName),n.textContent=o,i.appendChild(n),i.style.rowGap="2px";const r=(0,Y.Ux)("P");r.className="txtSmall",r.style.fontSize="12px",r.style.color=this.utilities.isDarkMode()?"#FFFFFF":"#666666",r.textContent=(0,T.fZ)("dealsSubTitle",this.flyoutData.strings.dealsSubTitle,this.flyoutData.dataStoreModule.CouponData.DomainName),i.appendChild(r);const a=(0,Y.Ux)("IMG",{style:"width: 38px; height: 38px; float: left;\n box-shadow: 0 0 calc((var(--elevation) * 0.225px) + 2px) rgba(0, 0, 0, calc(0.11 * (2 - var(--background-luminance, 1)))), 0 calc(var(--elevation) * 0.4px) calc((var(--elevation) * 0.9px)) rgba(0, 0, 0, calc(0.13 * (2 - var(--background-luminance, 1))));\n border: 1px solid;\n border-radius: 8px;\n border-color: #ECECEC;"});if(a.src=`${this.flyoutData.common.resourcesEndpoint}retailerBranding/SquareIcons/${this.flyoutData.dataStoreModule.CouponData.DomainName}.png`,a.setAttribute("aria-hidden","true"),a.addEventListener("error",(()=>{t.style.gridTemplateColumns="auto",a.style.visibility="hidden"})),t.appendChild(a),t.appendChild(i),this.flyoutData.common.isPane){const e=this.flyoutData.common.shopping.querySelector("#dealsSection");e&&(e.prepend(t),e.slot="header-content")}else t.slot="header-content",this.flyoutData.common.shopping.appendChild(t);const s=e.querySelector(".btnSeeMore");s&&s.classList.add("btnSeeMoreSeparate")}}createElement(e,t,i){const n=document.createElement(e);return t&&n.setAttribute("style",t),i&&(n.innerText=i),n}managePCLinkEvents(e,t,i){const n=this.flyoutData.common.currentDevice;e.addEventListener("click",(()=>{n===r.AS.Desktop&&this.navigateToRetailer(t,i,ju.$.NEW_FOREGROUND_TAB)})),e.addEventListener("mousedown",(e=>{1===e.button&&this.navigateToRetailer(t,i,ju.$.NEW_FOREGROUND_TAB)}))}navigateToRetailer(e,t,n){const o=new W.Z(i.$S.NavigateToRetailerOffer,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.pageHandlerModule.RecordAsUserAction(K.bS.NAVIGATE_TO_DEAL_OFFER),this.pageHandlerModule.RecordAsUserEngagement(q.FV.NAVIGATE_TO_DEAL_OFFER,this.flyoutData.common.popupOrigination),this.logModule.LogInfoEvent(i.R.ButtonClick,"",o),this.pageHandlerModule.NavigateToDealWithDisposition(e,t,n)}createDealsTile(e,t,i){const n=(0,Y.Ux)("BUTTON",{style:"background: transparent;\n --elevation: 5;\n overflow: hidden;\n align-items: center;\n padding: 12px 12px 10px;\n margin-bottom: 10px;\n cursor: pointer;\n border: calc(var(--outline-width) * 1px) solid transparent;\n border-radius: calc(var(--elevated-corner-radius) * 1px);\n text-align: left;\n display: table;\n width: 100%;"});n.className="divDealsLink";const o=(0,Y.Ux)("DIV",{style:"position: relative; height: 100%; display: grid; grid-template-columns: auto 60% auto; grid-gap: 20px;"});n.style.border="none",n.style.borderTop="1px solid rgb(236, 236, 236, 0.08)",n.style.marginBottom="0px",o.style.alignItems="center",n.appendChild(o);const r=(0,Y.Ux)("IMG",{style:"width: 32px; height: 32px; place-self: center"});r.src=this.flyoutData.common.resourcesEndpoint+"retailerBranding/SquareIcons/DollarIcon.png",r.addEventListener("error",(()=>{o.style.gridTemplateColumns="auto",o.removeChild(r)})),r.setAttribute("aria-hidden","true"),o.appendChild(r);const a=(0,Y.Ux)("DIV",{style:"justify-content: space-around;\n flex-direction: column;\n max-width: 192px;"});o.appendChild(a);const s=(0,Y.Ux)("P",{style:"margin: 0px;\n margin-bottom: 5px;"});s.className="txtMedium",s.style.fontWeight="600",s.style.fontSize="14px",s.style.lineHeight="16px",s.style.color="var(--neutral-foreground-rest)",s.textContent=e,a.appendChild(s),n.setAttribute("aria-label",`${this.flyoutData.strings.getDeal}, ${e}`),n.setAttribute("role","button");const l=(0,Y.Ux)("fluent-anchor");return l.appearance="lightweight",l.style.fontWeight="500",l.style.fontSize="12px",l.style.lineHeight="14px",l.style.placeSelf="center",l.textContent=this.flyoutData.strings.getDeal,o.appendChild(l),this.managePCLinkEvents(n,t,i),n}},Ty=class{static GetSuggestions(e,t){const i=e?.ChatChips||{},n={};return Object.keys(i).forEach((e=>{t.CanDiscoverRender(e)&&(n[e]=i[e])})),n}};function wy(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Oy(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?wy(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):wy(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var Py=class extends Qu{constructor(e,t,i,n){super(),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"renderedPageType",void 0),(0,s.Z)(this,"telemetryHandler",void 0),(0,s.Z)(this,"uxUtils",void 0),(0,s.Z)(this,"suggestions",{}),(0,s.Z)(this,"shouldShowLeftChevron",!1),(0,s.Z)(this,"shouldShowRightChevron",!1),(0,s.Z)(this,"mouseOverCard",!1),(0,s.Z)(this,"useInfiniteScroll",!1),(0,s.Z)(this,"isButtonFocused",!1),(0,s.Z)(this,"moduleName",r.ModuleNames.DISCOVER_CHAT_CHIPS),(0,s.Z)(this,"chatChipsSection",void 0),(0,s.Z)(this,"isDarkMode",!1),(0,s.Z)(this,"chipsCount",0),(0,s.Z)(this,"sectionId","discoverShoppingChatSection"),this.flyoutData=e,this.uxUtils=t,this.utilities=t.viewModulesUtilities,this.telemetryHandler=t.discoverTelemetryHandler,this.pageHandlerModule=t.pageHandlerModule,this.logModule=t.logModule,this.storageHandler=t.storageHandler,this.commonAssets=i,this.stateManagement=n,this.isDarkMode=this.utilities.isDarkMode(),this.assets=new class{getStyles(){return"\n .discoverChatModuleContainer {\n padding: 0px 20px 10px 20px;\n margin-bottom: 10px;\n }\n .chatCardCarousel {\n background: #FFFFFF;\n border-radius: 8px;\n }\n .carouselDiscoverBubble {\n height: 26px;\n width: 26px;\n margin-right: 3px\n }\n .carouselDiscoverBubble svg {\n height: 100%;\n width: 100%;\n }\n .carouselCardHeaderContainer {\n display: flex;\n flex-wrap: nowrap;\n overflow: hidden;\n padding: 15px 15px 3px 15px;\n position: relative;\n }\n .carouselCardTitleContainer {\n font-family: 'Segoe UI';\n font-style: normal;\n font-weight: 600;\n font-size: 16px;\n line-height: 22px;\n color: #111111;\n padding: 3px 15px 5px 15px;\n display: flex;\n align-items: flex-end;\n flex: none;\n order: 2;\n align-self: stretch;\n flex-grow: 0;\n }\n .carouselCardDismiss {\n position: absolute;\n top: 17px;\n right: 14px;\n height: 16px;\n width: 16px;\n cursor: pointer;\n margin: 0;\n padding: 0;\n border: 0;\n }\n .carouselCardDismiss svg {\n width: 100%;\n height: 100%;\n fill: #000000;\n }\n .carouselSuggestionsContainer {\n margin: 0px 0px 0px 2px;\n padding: 8px 12px 8px 8px;\n width: auto;\n height: 36px;\n position: relative;\n }\n .smartSuggestionsWrapper::-webkit-scrollbar {\n display: none;\n }\n .smartSuggestionsWrapper {\n display: flex;\n flex-wrap: nowrap;\n overflow: hidden;\n overflow-x: scroll;\n scroll-behavior: smooth;\n }\n .carouselChevron {\n background: #FFFFFF;\n border: 0.5px solid rgba(0, 0, 0, 0.1);\n\n box-shadow: 0px 1.2px 3.6px rgba(0, 0, 0, 0.1), 0px 6.4px 14.4px rgba(0, 0, 0, 0.13);\n border-radius: 32px;\n\n width: 32px;\n height: 32px;\n position: absolute;\n z-index: 1;\n }\n .carouselChevron svg {\n fill: #123BB6;\n }\n .rightChevron svg {\n padding: 8px 0px 0px 12px;\n }\n .leftChevron {\n left: 0px;\n }\n .leftChevron svg {\n rotate: 180deg;\n padding: 0px 10px 8px 0px;\n }\n .rightChevron {\n right: 5px;\n }\n .carouselChevron {\n cursor: pointer;\n }\n .chatCard {\n background: radial-gradient(112.21% 51.76% at 100% 100%, rgba(200, 250, 255, 0.08) 0%, rgba(28, 210, 229, 0.08) 40.62%, rgba(28, 210, 229, 0) 100%), radial-gradient(139.48% 64.34% at 60.31% 100%, rgba(23, 74, 228, 0.08) 0%, rgba(23, 74, 228, 0) 77.11%), linear-gradient(180deg, rgba(23, 74, 228, 0) 29.44%, rgba(23, 74, 228, 0.06) 100%), linear-gradient(90deg, #F3F3F7 0%, #EBF0F9 100%);\n border: 1px solid #E0E0E0;\n border-radius: 6px;\n position: relative;\n }\n .chipsInCardSuggestionsContainer {\n padding: 3px 15px 12px 15px;\n }\n .chipsInCardTitleContainer {\n font-family: 'Segoe UI';\n font-style: normal;\n font-weight: 400;\n font-size: 14px;\n line-height: 20px;\n color: #111111;\n padding: 5px 15px 5px 15px\n }\n .chipsInCardHeaderContainer {\n display: flex;\n flex-wrap: nowrap;\n overflow: hidden;\n padding: 15px 15px 3px 15px;\n }\n .discoverBubble {\n height: 26px;\n width: 26px;\n margin-right: 3px\n }\n .discoverBubble svg {\n height: 100%;\n width: 100%;\n }\n .chipsInCardHeaderTitle {\n font-family: 'Segoe UI Variable', 'Segoe UI';\n font-style: normal;\n font-weight: 600;\n font-size: 14px;\n line-height: 24px;\n color: #111111;\n }\n .smartSuggestionButton {\n box-sizing: border-box;\n margin: 4px 6px 4px 0px;\n padding: 3px 7px;\n height: 28px;\n background: rgba(255, 255, 255, 0.7);\n border: 1px solid #174AE4;\n color: #174AE4;\n backdrop-filter: blur(120px);\n border-radius: 8px;\n font-style: normal;\n font-weight: 600;\n font-size: 14px;\n font-family: 'Segoe UI Variable', 'Segoe UI';\n line-height: 22px;\n cursor: pointer;\n }\n .smartSuggestionButton span {\n display: block;\n font-style: normal;\n font-weight: 600;\n font-size: 14px;\n font-family: 'Segoe UI Variable', 'Segoe UI';\n line-height: 22px;\n max-width: 263px;\n width: fit-content;\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n }\n .smartSuggestionButton:hover {\n background: #eff3ff;\n border-color: #174ae4;\n color: #174ae4;\n }\n .hidden {\n visibility: hidden;\n }\n .dismissCard {\n height: 16px;\n width: 16px;\n position: absolute;\n top: 14px;\n right: 14px;\n cursor: pointer;\n }\n .dismissCard svg {\n width: 100%;\n height: 100%;\n fill: #000000;\n }\n "}getDarkModeStyles(){return"\n .chatCardCarousel {\n background: #424242;\n border: 1px solid rgba(255, 255, 255, 0.1);\n box-shadow: 0px 2px 4px rgba(0, 0, 0, 0.14), 0px 0px 2px rgba(0, 0, 0, 0.12);\n }\n .chipsInCardHeaderTitle {\n color: #ffffff;\n }\n .carouselCardTitleContainer {\n color: #ffffff;\n }\n .smartSuggestionButton {\n background-color: #343434;\n color: #A2B7F4;\n border: 1px solid #A2B7F4;\n }\n .smartSuggestionButton:hover {\n background-color: #2B2B2B;\n color: #A2B7F4;\n border: 1px solid #A2B7F4;\n }\n .carouselChevron {\n box-shadow: 0.6px 0px 1.8px rgba(0, 0, 0, 0.1), 3.2px 0px 7.2px rgba(0, 0, 0, 0.13);\n background: #323130;\n border: 1px solid #A2B7F4;\n }\n .carouselChevron svg {\n fill: #ffffff;\n }\n .carouselCardDismiss {\n background: none;\n }\n .carouselCardDismiss svg {\n fill: #ffffff;\n }\n "}}}GetModuleName(){return this.moduleName}async ShouldRenderModule(){return this.flyoutData.dataStoreModule.ClientInfo?.isOffTheRecord?Promise.resolve(!1):e.R.isExperimentActive(f.H.discoverShopping)?e.R.isExperimentActive(f.H.disableChatChips)||this.flyoutData.common.chatConsentStatus===r.lg.Declined?Promise.resolve(!1):(this.renderedPageType=i.e4.PdpPage,this.suggestions=Ty.GetSuggestions(this.flyoutData.dataStoreModule.DiscoverShoppingData?.ChatChipsData,this.stateManagement),this.chipsCount=Object.keys(this.suggestions).length,e.R.isTestFlagActive(Zt.t.msShoppingTestExp18)?Promise.resolve(!0):e.R.isExperimentActive(f.H.discoverChatChips)?e.R.getServiceExperimentValue(f.H.discoverChatChips)===Yu.LR.control?Promise.resolve(!1):Promise.resolve(!0):this.chipsCount>0?Promise.resolve(!0):Promise.resolve(!1)):Promise.resolve(!1)}populateMainHeader(){const e=this.flyoutData.common.shopping.querySelector("#discoverShoppingChatSection");e&&(e.slot="header-content",e.style.paddingTop="25px")}async renderModule(){return this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),this.chatChipsSection=(0,Y.Ux)("msft-edge-shopping-section"),this.chatChipsSection.id=this.sectionId,this.chatChipsSection.titleText=this.flyoutData.strings.chatChipsSectionTitle,this.chatChipsSection.titleIcon=`${this.flyoutData.common.resourcesEndpoint}smartSuggestions/discovery-bubble.svg`,this.chatChipsSection.accordion=this.flyoutData.common.currentDevice===r.AS.Desktop,this.chatChipsSection.expanded=!0,this.CreateUx(this.chatChipsSection),Promise.resolve(this.CreateModule(this.chatChipsSection,r.H7.DISCOVER_CHAT_CHIPS,r.ModuleNames.DISCOVER_CHAT_CHIPS,r.$k.CONTEXTUAL,r.SV.LIST))}PostProcessing(e,t,n){const o=`position ${t}`;this.telemetryHandler.LogEventTelemetry(i.xu.DiscoverChatChips,o,this.renderedPageType,e,{chipsCount:this.chipsCount},bp.r.SHOPPING_CHIPS)}CreateUx(e){const t=(0,Y.Ux)("div");t.className="discoverChatModuleContainer";const n=()=>{this.telemetryHandler.LogEventTelemetry(i.xu.DiscoverChatHover,"Discover chat suggestions Hover",this.renderedPageType,this.moduleName,Oy(Oy({},this.suggestions),{},{chipsCount:this.chipsCount}),void 0,q.FV.SHOPPING_CHIPS),t.removeEventListener("mouseover",n)};t.addEventListener("mouseover",n),this.CreateCarouselChipsUx(t),e.appendChild(t)}CreateCarouselChipsUx(e){const t=(0,Y.Ux)("div");t.className="chatCardCarousel";const i=(0,Y.Ux)("div");i.className="carouselSuggestionsContainer",i.appendChild(this.CreateChevron("rightChevron hidden",(()=>this.scrollCarousel(n))));const n=(0,Y.Ux)("div");n.className="smartSuggestionsWrapper",n.id="smartSuggestionsWrapper",Object.keys(this.suggestions).forEach((e=>{const t=this.CreateSuggestionButton(e,this.suggestions[e],n,!0,1===Object.keys(this.suggestions).length);n.appendChild(t)})),i.appendChild(n),t.addEventListener("mouseover",(()=>{this.mouseOverCard=!0,this.refreshChevrons(i,n)})),t.addEventListener("mouseout",(()=>{this.mouseOverCard=!1,this.hideChevron(i,!0),this.hideChevron(i,!1)})),n.addEventListener("scroll",(()=>{this.mouseOverCard&&this.getNextButtonIdx(n)>=this.getSuggestionButtons(n).length-2&&this.addButtonForInfiniteScroll(n)})),t.appendChild(i),this.setChevron(i,n),e.append(t)}getSuggestionButtons(e){if(e){const t=e.querySelectorAll(".smartSuggestionButton");return Array.from(t)}return[]}addButtonForInfiniteScroll(e){!this.isButtonFocused&&this.useInfiniteScroll&&Object.keys(this.suggestions).forEach(((t,i)=>{const n=this.CreateSuggestionButton(t,this.suggestions[t],e,!0,!1);e.appendChild(n)}))}setChevron(e,t){const i=new ResizeObserver((()=>{t&&t.clientWidth>0&&(t.scrollWidth>t.clientWidth&&(this.shouldShowRightChevron=!0,this.useInfiniteScroll=!0),i.disconnect())}));i.observe(e)}scrollCarousel(e){const t=this.getNextButtonIdx(e);t>=this.getSuggestionButtons(e).length-1&&this.addButtonForInfiniteScroll(e);const n=this.getSuggestionButtons(e);t<n.length&&(e.scrollLeft=n[t].offsetLeft-10),this.telemetryHandler.LogClickTelemetry(i.xu.DiscoverChatChevronClick,"Chat chips carousel scroll",this.renderedPageType,this.moduleName,{chipsCount:this.chipsCount},q.FV.SHOPPING_CHIPS)}getNextButtonIdx(e){const t=e.scrollLeft,i=this.getSuggestionButtons(e);for(let e=0;e<i.length;e++)if(i[e].offsetLeft-12>t)return e;return i.length}refreshChevrons(e,t){t.scrollLeft+t.clientWidth<t.scrollWidth?this.showChevron(e,!1):this.hideChevron(e,!1)}hideChevron(e,t){const i=e.querySelector(".rightChevron");i&&i.classList.add("hidden")}showChevron(e,t){const i=t?".leftChevron":".rightChevron",n=e.querySelector(i);n&&n.classList.remove("hidden")}CreateChevron(e,t){const i=(0,Y.Ux)("div");return i.className=`carouselChevron ${e}`,i.innerHTML=this.commonAssets.getRightChevronIcon(),i.addEventListener("click",(()=>{t()})),i}CreateSuggestionButton(e,t,n,o,r){const a=(0,Y.Ux)("button");a.className="smartSuggestionButton";const s=(0,Y.Ux)("span");return s.textContent=t,a.appendChild(s),a.id="icc_discover_"+t,a.title=t,o&&a.addEventListener("click",(()=>{this.telemetryHandler.LogClickTelemetry(i.xu.DiscoverChatSuggestionClick,t,this.renderedPageType,this.moduleName,{moduleName:e,chipsCount:this.chipsCount},q.FV.SHOPPING_CHIPS),this.OpenDiscover(t,e)})),a.addEventListener("focusin",(()=>{const e=a.offsetLeft;n.scrollLeft=e-12,this.isButtonFocused=!0})),a.addEventListener("focusout",(()=>this.isButtonFocused=!1)),r&&(s.style.maxWidth="290px"),a}OpenDiscover(e,t){const i={isShoppingPane:!0,text:e};this.pageHandlerModule.OpenChatPane(JSON.stringify(i),t)}},Ay=class extends Qu{constructor(e,t){super(),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"telemetryHandler",void 0),(0,s.Z)(this,"moduleName",r.ModuleNames.EXPERT_INSIGHTS),(0,s.Z)(this,"isDarkMode",!1),(0,s.Z)(this,"expertInsights",void 0),this.flyoutData=e,this.utilities=t.viewModulesUtilities,this.telemetryHandler=t.discoverTelemetryHandler,this.isDarkMode=this.utilities.isDarkMode(),this.assets=new class{getStyles(){return"\n .container-ei {\n background-color: var(--neutral-fill-layer-rest);\n border-radius: 10px;\n box-sizing: border-box;\n margin: 20px;\n margin-top: 5px;\n padding: 15px;\n }\n .container-ei-dpane {\n box-sizing: border-box;\n margin: 20px;\n margin-bottom: 0px;\n margin-top: 5px;\n }\n .score {\n font-size: 40px;\n font-weight: 600;\n }\n .score.above-threshold {\n color: #138757;\n }\n .score.below-threshold {\n color: #D63600;\n }\n .score-percent {\n font-size: 24px;\n font-weight: 600;\n }\n .score-percent.above-threshold {\n color: #138757;\n }\n .score-percent.below-threshold {\n color: #D63600;\n }\n .score-text {\n font-size: 14px;\n }\n .rec-text {\n font-size: 20px;\n font-weight: 600;\n }\n .sum-text {\n margin-top: 5px;\n }\n .recommendation-bar-container {\n display: flex;\n height: 8px;\n margin: 10px;\n margin-left: 0px;\n position: relative;\n width: 100%;\n }\n .recommendation-bar-section {\n border-radius: 10px;\n height: 100%;\n position: absolute;\n }\n .recommendation-bar-section.gray-bar {\n background-color: var(--neutral-layer-3);\n z-index: 1;\n }\n .recommendation-bar-section.green-bar {\n z-index: 2;\n }\n .recommendation-bar-section.green-bar.above-threshold {\n background-color: #2DCF8B;\n }\n .recommendation-bar-section.green-bar.below-threshold {\n background-color: #F76A3B;\n }\n "}getDarkModeStyles(){return"\n .recommendation-bar-section.gray-bar {\n background-color: var(--neutral-layer-2);\n }\n "}}}GetModuleName(){return r.ModuleNames.EXPERT_INSIGHTS}ShouldRenderModule(){return this.expertInsights=this.GetExpertInsightsData(),new Promise(((e,t)=>{this.expertInsights&&this.expertInsights.expertReviewsFound?e(!0):e(!1)}))}renderModule(){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());const{strings:e}=this.flyoutData,t=(0,Y.Ux)("msft-edge-shopping-section");return t.titleText=e.expertInsightsSectionTitle,this.CreateUx(t),Promise.resolve(this.CreateModule(t,r.H7.EXPERT_INSIGHTS,r.ModuleNames.EXPERT_INSIGHTS,r.$k.CONTEXTUAL,r.SV.LIST))}populateMainHeader(){const e=this.flyoutData.common.shopping.querySelector("#SimilarProductsSection");e&&(e.slot="header-content")}PostProcessing(e,t,n){const o=0===t;this.flyoutData.common.isDiscoverPane&&o&&this.telemetryHandler.LogEventTelemetry(i.xu.ExpertInsightsView,"Expert Insights Discover View","",r.ModuleNames.EXPERT_INSIGHTS,{},bp.r.EXPERT_INSIGHTS)}GetExpertInsightsData(){return this.flyoutData.dataStoreModule.ExpertInsightsData}CreateUx(e){const{strings:t}=this.flyoutData,i=this.expertInsights?.recommendationScore&&this.expertInsights?.recommendationScore>=60,n=i?"above-threshold":"below-threshold",o=(0,Y.Ux)("div");this.flyoutData.common.isDiscoverPane?o.classList.add("container-ei-dpane"):o.classList.add("container-ei");const r=(0,Y.Ux)("div"),a=(0,Y.Ux)("span");a.classList.add("score",n);const s=(0,Y.Ux)("span");s.classList.add("score-percent",n);const l=(0,Y.Ux)("span");l.classList.add("score-text"),a.innerText=`${this.expertInsights?.recommendationScore}`,s.innerText="% ",l.innerText=t.expertInsightsRecommendationScore,r.appendChild(a),r.appendChild(s),r.appendChild(l);const c=(0,Y.Ux)("div");c.classList.add("recommendation-bar-container");const d=(0,Y.Ux)("div");d.classList.add("recommendation-bar-section","gray-bar"),d.style.width=this.expertInsights?.expertReviewsFound?"100%":"0%";const u=(0,Y.Ux)("div");u.classList.add("recommendation-bar-section","green-bar",n),u.style.width=this.expertInsights?.recommendationScore?`${this.expertInsights?.recommendationScore}%`:"0%",c.append(d),c.append(u);const h=(0,Y.Ux)("div");h.classList.add("rec-text"),h.innerText=i?t.expertInsightsRecommend:t.expertInsightsDontRecommend;const p=(0,Y.Ux)("div");p.classList.add("sum-text"),p.innerText=this.expertInsights?this.expertInsights.expertInsightsSummary:"",o.append(r),o.append(c),o.append(h),o.append(p),e.appendChild(o)}};const Ey=new Map;Ey[0]=i.$S.FeedbackDislikeMenu0,Ey[1]=i.$S.FeedbackDislikeMenu1,Ey[2]=i.$S.FeedbackDislikeMenu2,Ey[3]=i.$S.FeedbackDislikeMenu3,Ey[4]=i.$S.FeedbackDislikeMenu4;var ky=class extends Qu{constructor(e,t,i,n){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"footerUtilities",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"clientId",void 0),(0,s.Z)(this,"options",void 0),(0,s.Z)(this,"isBNPL",void 0),(0,s.Z)(this,"feedbackPromptText",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"isShortVersion",!1),(0,s.Z)(this,"isEventCall",!1),(0,s.Z)(this,"wrapperHeight",void 0),(0,s.Z)(this,"autoOpenControllerUtilities",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),this.flyoutData=e,this.utilities=t.viewModulesUtilities,this.logModule=t.logModule,this.pageHandlerModule=t.pageHandlerModule,this.footerUtilities=t.footerUtilities,this.commonAssets=n,this.assets=new class{getThumbsUp(){return eh.Z.getTrustedHTML`<svg aria-hidden="true" slot="unselected-glyph" xmlns="http://www.w3.org/2000/svg" width="12" height="15" viewBox="0 0 12 15" fill="none">
<path d="M8.9999 3.0102C8.9999 1.38227 8.23983 0.211066 6.99563 0.211066C6.3457 0.211066 6.10136 0.572932 5.86823 1.40827L5.73083 1.92287C5.6635 2.162 5.5463 2.5692 5.3795 3.14353C5.37503 3.15893 5.36843 3.17347 5.3599 3.1868L3.4487 6.17727C2.99667 6.88453 2.32969 7.4282 1.54577 7.7284L1.23025 7.8492C0.399096 8.1674 -0.0834571 9.03658 0.0859628 9.91029L0.355623 11.301C0.516576 12.1311 1.14568 12.7917 1.9669 12.993L7.05203 14.2393C8.7395 14.6529 10.4451 13.6296 10.8744 11.9461L11.8176 8.2466C12.1133 7.08713 11.413 5.90747 10.2534 5.6118C10.0785 5.5672 9.8987 5.54467 9.7181 5.54467L8.50256 5.54467C8.8333 4.45607 8.9999 3.6162 8.9999 3.0102ZM1.06768 9.71993C0.99067 9.32279 1.21001 8.92771 1.58781 8.78306L1.90333 8.66226C2.88707 8.2856 3.72406 7.60333 4.29132 6.7158L6.2025 3.72533C6.2625 3.6314 6.30876 3.52933 6.33983 3.42233L6.70776 2.14213L6.8489 1.6146C6.94183 1.28927 6.98863 1.21107 6.99563 1.21107C7.5741 1.21107 7.9999 1.86713 7.9999 3.0102C7.9999 3.59987 7.7827 4.5672 7.34403 5.88693C7.23643 6.2106 7.47736 6.54467 7.8185 6.54467L9.7181 6.54467C9.81536 6.54467 9.91216 6.5568 10.0064 6.5808C10.6308 6.74 11.0078 7.3752 10.8486 7.99953L9.90536 11.699C9.61163 12.8509 8.4447 13.551 7.2901 13.2681L2.20495 12.0217C1.76276 11.9133 1.42401 11.5576 1.33734 11.1107L1.06768 9.71993Z" fill="currentcolor"/>
</svg>
<svg slot="selected-glyph" xmlns="http://www.w3.org/2000/svg" width="13" height="15" viewBox="0 0 13 15" fill="none">
<path d="M9.03773 5.54467C9.34493 4.59327 9.5 3.76053 9.5 3.04247C9.5 1.44333 8.874 0.210867 7.83334 0.210867C7.3002 0.210867 7.11474 0.510667 6.91167 1.24187L6.7318 1.92287C6.66454 2.162 6.54733 2.5692 6.38047 3.14353C6.376 3.15893 6.36947 3.17347 6.36087 3.1868L4.44971 6.17727C3.99768 6.88453 3.3307 7.4282 2.54678 7.7284L1.70862 8.04927C1.17971 8.2518 0.872628 8.80489 0.980441 9.36089L1.43788 11.72C1.54931 12.2947 1.98484 12.752 2.55337 12.8914L8.05307 14.2393C9.74053 14.6529 11.4461 13.6296 11.8754 11.9461L12.9246 7.83093C13.1748 6.8498 12.5822 5.85167 11.6011 5.60147C11.4531 5.56373 11.3009 5.54467 11.1481 5.54467L9.03773 5.54467Z" fill="currentcolor"/>
</svg>`}getThumbsDown(){return eh.Z.getTrustedHTML`<svg aria-hidden="true" slot="unselected-glyph" xmlns="http://www.w3.org/2000/svg" width="12" height="15" viewBox="0 0 12 15" fill="none">
<path d="M8.99965 11.9898C8.99965 13.6177 8.23958 14.7889 6.99539 14.7889C6.34545 14.7889 6.10112 14.4271 5.86798 13.5917L5.73058 13.0771C5.66325 12.838 5.54605 12.4308 5.37925 11.8565C5.37479 11.8411 5.36819 11.8265 5.35965 11.8132L3.44846 8.82273C2.99642 8.11547 2.32944 7.5718 1.54552 7.2716L1.23 7.1508C0.398852 6.8326 -0.0837017 5.96342 0.0857183 5.08971L0.355378 3.69899C0.516332 2.86893 1.14544 2.20833 1.96665 2.00705L7.05178 0.760694C8.73925 0.347101 10.4449 1.37039 10.8741 3.05394L11.8174 6.7534C12.1131 7.91287 11.4127 9.09253 10.2532 9.3882C10.0783 9.4328 9.89845 9.45533 9.71785 9.45533H8.50232C8.83305 10.5439 8.99965 11.3838 8.99965 11.9898ZM1.06743 5.28007C0.990425 5.67721 1.20977 6.07229 1.58757 6.21694L1.90309 6.33774C2.88683 6.7144 3.72382 7.39667 4.29108 8.2842L6.20225 11.2747C6.26225 11.3686 6.30852 11.4707 6.33958 11.5777L6.70752 12.8579L6.84865 13.3854C6.94158 13.7107 6.98839 13.7889 6.99539 13.7889C7.57385 13.7889 7.99965 13.1329 7.99965 11.9898C7.99965 11.4001 7.78245 10.4328 7.34379 9.11307C7.23619 8.7894 7.47712 8.45533 7.81825 8.45533H9.71785C9.81512 8.45533 9.91192 8.4432 10.0061 8.4192C10.6305 8.26 11.0076 7.6248 10.8484 7.00047L9.90512 3.30101C9.61138 2.14911 8.44445 1.44896 7.28985 1.73195L2.2047 2.9783C1.76251 3.08668 1.42377 3.44239 1.3371 3.88935L1.06743 5.28007Z" fill="currentcolor"/>
</svg>
<svg slot="selected-glyph" xmlns="http://www.w3.org/2000/svg" width="13" height="15" viewBox="0 0 13 15" fill="none">
<path d="M9.03773 9.45533C9.34493 10.4067 9.5 11.2395 9.5 11.9575C9.5 13.5567 8.874 14.7891 7.83334 14.7891C7.3002 14.7891 7.11474 14.4893 6.91167 13.7581L6.7318 13.0771C6.66454 12.838 6.54733 12.4308 6.38047 11.8565C6.376 11.8411 6.36947 11.8265 6.36087 11.8132L4.44971 8.82273C3.99768 8.11547 3.3307 7.5718 2.54678 7.2716L1.70862 6.95073C1.17971 6.7482 0.872628 6.19511 0.980441 5.63911L1.43788 3.27999C1.54931 2.70533 1.98484 2.24799 2.55337 2.10865L8.05307 0.760693C9.74053 0.3471 11.4461 1.37039 11.8754 3.05394L12.9246 7.16907C13.1748 8.1502 12.5822 9.14833 11.6011 9.39853C11.4531 9.43627 11.3009 9.45533 11.1481 9.45533L9.03773 9.45533Z" fill="currentcolor"/>
</svg>`}getStyles(){return"\n #feedbackDiv {\n display: flex;\n flex-direction: row;\n justify-content: flex-start;\n background: var(--fill-color);\n }\n #feedbackPrompt {\n font-size: 12px;\n line-height: 16px;\n margin-left: 12px;\n margin-top: 12px;\n margin-bottom: 10px;\n font-weight: 600;\n color: rgba(0, 0, 0, 0.83);\n }\n .iconButton {\n border-color: transparent;\n background: transparent;\n margin-top: 5px;\n width: 32px;\n height: 32px;\n cursor: pointer;\n }\n :is(.iconButton:hover, .iconButton:focus) {\n background: #E6E6E6;\n border-radius: 2px;\n outline: none;\n }\n .feedbackText {\n font-size: 14px;\n line-height: 18px;\n margin: 0px;\n color: rgba(0, 0, 0, 0.83);\n }\n #closeButton {\n margin-top: 2px;\n margin-left: auto;\n margin-right: 5px;\n padding: 0px;\n border: none;\n background: transparent;\n cursor: pointer;\n }\n #closeButton:focus {\n outline: none;\n border: 2px solid #898989;\n border-radius: 3px;\n }\n #feedbackDivThanks {\n background: linear-gradient(90deg, #EEFCFF 20.31%, #F5F9FF 46.87%, #FFFFFF 98.44%);\n padding: 10px;\n display: flex;\n flex-direction: row;\n justify-content: flex-start;\n border-top: 1px solid #F1F1F1;\n column-gap: 12px;\n }\n #btnFeedbackDislike::part(flyout) {\n transform: translate(-191px, 32px) !important;\n }\n "}getDarkModeStyles(){return"\n #feedbackDiv {\n background: #3b3b3b;\n border-top: 1px solid rgb(241, 241, 241, 0.08);\n }\n #feedbackDivThanks {\n background: linear-gradient(90deg, #324654 20.31%, #3E444E 46.87%, #3b3b3b 98.44%);\n border-top: 1px solid rgb(241, 241, 241, 0.08);\n }\n #feedbackPrompt, .feedbackText {\n color: rgba(255, 255, 255, 0.83);\n }\n :is(.iconButton:hover, .iconButton:focus) {\n background: #5f5f5f;\n }\n #closeButton svg path {\n fill: #FFFFFF;\n }\n "}},this.stateManagement=i,this.clientId="",this.isBNPL=!!this.flyoutData.dataStoreModule?.VirtualCardData?.cardProvider,this.autoOpenControllerUtilities=t.autoOpenControllerUtilities,this.telemetryUtilities=t.telemetryHandler,this.options=[],this.isBNPL?(this.options.push(this.flyoutData.dataLoader.GetLoadTimeDataValue(cy.e.feedbackMessages.feedbackAutofillDontWork.message,"")),this.options.push(this.flyoutData.dataLoader.GetLoadTimeDataValue(cy.e.feedbackMessages.feedbackTookTooMuchTime.message,""))):(this.options.push(this.flyoutData.strings.couponsDoNotWork),this.options.push(this.flyoutData.strings.popsUpTooFrequently),this.options.push(this.flyoutData.strings.incorrectProductInformation),this.options.push(this.flyoutData.strings.untrustworthyWebsite)),this.options.push(this.flyoutData.strings.other),this.feedbackPromptText=this.isBNPL?this.flyoutData.strings.bnplFeedbackPrompt:this.flyoutData.strings.feedbackPrompt,this.stateManagement.addEventListener(Ku.e1.CreateShortFeedbackModule,(async e=>{if(e&&e.detail&&e.detail.callback&&(this.isEventCall=!0,!document.querySelector("#feedbackDiv")&&await this.ShouldRenderModule())){this.isShortVersion=!0,this.wrapperHeight=e.detail.wrapperHeight;const t=await this.renderModule();t&&t.element&&(e.detail.callback(t),this.isEventCall=!1)}})),this.stateManagement.addEventListener(Ku.e1.CreateFeedbackModule,(async e=>{if(e&&e.detail&&e.detail.callback&&(this.isEventCall=!0,!document.querySelector("#feedbackDiv")&&await this.ShouldRenderModule())){this.isShortVersion=!1,this.wrapperHeight=e.detail.wrapperHeight;const t=await this.renderModule();t&&t.element&&(e.detail.callback(t),this.isEventCall=!1)}}))}GetModuleName(){return r.ModuleNames.FEEDBACK}async ShouldRenderModule(){return this.isEventCall||this.flyoutData.common.openedWith===r.Te.Auto&&!await this.footerUtilities.showFooter()&&!this.flyoutData.common.seeInfoFromPCNotification?this.isBNPL?Promise.resolve(this.flyoutData.dataLoader.GetLoadTimeDataValue("is_bnpl_feedback_enabled",!1)):Promise.resolve(this.flyoutData.dataLoader.GetLoadTimeDataValue("is_feedback_enabled",!1)):Promise.resolve(!1)}populateMainHeader(){}async renderModule(){const e=(0,Y.Ux)("div");return e.id="feedbackDiv",e.style.zIndex="50",(0,dt.tB)(this.flyoutData)?e.style.position="initial":e.style.position="sticky",e.style.bottom="0px",e.style.alignItems="center",e.style.display="flex",e.style.flexDirection="row",e.style.marginLeft="10px",e.style.marginRight="10px",e.setAttribute("role","group"),this.utilities.applyStyles(e,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),this.createFeedbackPrompt(e),Promise.resolve(this.CreateModule(e,r.H7.MAX,r.ModuleNames.FEEDBACK,r.$k.CONTEXTUAL,r.SV.BLOCK))}ShowAlways(){return!0}async createFeedbackPrompt(t){const n=(0,Y.Ux)("p");n.className="txtSmall",n.id="feedbackPrompt",n.textContent=this.feedbackPromptText,this.flyoutData.common.isPane&&(this.flyoutData.common.isSharedHeader?(n.style.fontSize="12px",n.style.lineHeight="12px"):(n.style.fontSize="14px",n.style.lineHeight="20px")),t.setAttribute("aria-labelledby","feedbackPrompt");const o=(0,Y.Ux)("msft-micro-feedback");this.isShortVersion||(o.style.marginRight="6px",o.style.marginLeft="auto");const r=(0,Y.Ux)("msft-micro-feedback-item");r.ariaLabel=`${this.flyoutData.strings.feedbackPrompt} ${this.flyoutData.strings.feedbackAriaLike}`,r.className="iconButton",r.innerHTML=this.assets.getThumbsUp(),r.addEventListener("click",(async n=>{for(await this.microFeedbackLog("like");t.lastChild;)t.lastChild.remove();const o=(0,T.pq)(n);this.createThankYouDialogue(t,o),e.R.isExperimentActive(f.H.CouponsPersonalization)&&await this.autoOpenControllerUtilities.userEngagementStoreManager.addEngagement(q.w1.POSITIVE,this.flyoutData.common.popupOrigination,this.stateManagement.getState(Ku.IY.topContextualModuleName),cy.e.userEngagementCouponWeights.likeWeight,i.$S.FeedbackLike),n.preventDefault()}));const a=(0,Y.Ux)("msft-micro-feedback-item");a.ariaLabel=`${this.flyoutData.strings.feedbackPrompt} ${this.flyoutData.strings.feedbackAriaDislike}`,a.id="btnFeedbackDislike",a.setAttribute("flyout-vertical-position","top"),a.className="iconButton",a.innerHTML=this.assets.getThumbsDown();const s=this.createDislikeMenu(t,a);a.addEventListener("click",(async n=>{const o=document.querySelector("#divContentWrapper");if(s.style.maxWidth="220px",(void 0!==this.wrapperHeight&&this.wrapperHeight<=220||void 0!==o&&o.offsetHeight<=250)&&(this.utilities.shouldRenderSmallNotification()?s.style.maxHeight="75px":s.style.maxHeight="100px"),!a.selected){for(;t.lastChild;)t.lastChild.remove();const e=(0,T.pq)(n);this.createThankYouDialogue(t,e)}const r=n.target.textContent??"";-1===this.options.indexOf(r)&&e.R.isExperimentActive(f.H.CouponsPersonalization)&&await this.autoOpenControllerUtilities.userEngagementStoreManager.addEngagement(q.w1.NEGATIVE,this.flyoutData.common.popupOrigination,this.stateManagement.getState(Ku.IY.topContextualModuleName),cy.e.userEngagementCouponWeights.dislikeDefaultWeight,i.$S.FeedbackDislike),r===this.flyoutData.dataLoader.GetLoadTimeDataValue(cy.e.feedbackMessages.feedbackTooFrequently.message,"")&&e.R.isExperimentActive(f.H.CouponsPersonalization)&&await this.autoOpenControllerUtilities.userEngagementStoreManager.addEngagement(q.w1.NEGATIVE,this.flyoutData.common.popupOrigination,this.stateManagement.getState(Ku.IY.topContextualModuleName),cy.e.feedbackMessages.feedbackTooFrequently.weight),r===this.flyoutData.dataLoader.GetLoadTimeDataValue(cy.e.feedbackMessages.feedbackCouponsDontWork.message,"")&&await this.autoOpenControllerUtilities.userEngagementStoreManager.increaseCouponExpectationWeight(this.flyoutData.common.popupOrigination,this.stateManagement.getState(Ku.IY.topContextualModuleName)),await this.microFeedbackLog("unlike"),n.preventDefault()})),o.append(r),o.append(a),this.flyoutData.common.isPane&&gn.SO.queueUpdate((()=>{const e=r.shadowRoot?.querySelector("fluent-button");e&&(e.style.backgroundColor="unset");const t=a.shadowRoot?.querySelector("fluent-button");t&&(t.style.backgroundColor="unset")})),this.isShortVersion||t.append(n),t.append(o)}createDislikeMenu(e,t){const i=this.createMenuElement();return this.addMenuEventListeners(i,e,t),this.addDocumentClickListener(t,e),this.addMenuItems(i),t.append(i),i}createMenuElement(){const e=(0,Y.Ux)("fluent-menu");return e.id="dislikeMenu",e.slot="menu",e.style.width="270px",e.style.height="80px",e.style.overflow="auto",e.setAttribute("aria-label",this.flyoutData.strings.feedbackAriaDislikeMenu),e}addMenuEventListeners(e,t,i){e.addEventListener("click",(e=>{this.dislikeMenuLog(t,!1,e)})),e.addEventListener("keydown",(e=>{"Enter"===e.key?this.dislikeMenuLog(t,!0,e):"Tab"!==e.key&&"Escape"!==e.key||this.handleMenuDismiss(i,t,!0)}))}addDocumentClickListener(e,t){document.addEventListener("click",(()=>{this.handleMenuDismiss(e,t,!1)}))}addMenuItems(e){this.options=this.moveToEnd(this.options,"Coupons do not work"),this.options=this.moveToEnd(this.options,"Other");for(const t of this.options)""!==t&&this.createMenuItem(t,e)}moveToEnd(e,t){const i=e.indexOf(t);if(i>-1){const t=e[i];e.splice(i,1),e.push(t)}return e}createMenuItem(e,t){const i=(0,Y.Ux)("fluent-menu-item");i.textContent=e,t.append(i)}createThankYouDialogue(e,t=!1){e.id="feedbackDivThanks",e.style.position="sticky",e.setAttribute("aria-labelledby","feedbackText"),this.utilities.applyStyles(e,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());const n=(0,Y.Ux)("img");n.src=this.flyoutData.common.resourcesEndpoint+"feedbackIcons/like_1.png",n.setAttribute("aria-hidden","true"),n.style.height="fit-content";const o=(0,Y.Ux)("p");o.className="txtSmall feedbackText",o.textContent=this.flyoutData.strings.feedbackThanks,this.flyoutData.common.isPane&&(this.flyoutData.common.isSharedHeader?(o.style.fontSize="12px",o.style.lineHeight="12px"):(o.style.fontSize="14px",o.style.lineHeight="20px")),this.isShortVersion&&(o.style.fontSize="12px",e.style.background="var(--fill-color)",e.style.padding="0px",e.parentElement&&(e.parentElement.style.gridTemplateColumns="calc(40% - 26px) calc(60% - 26px)"));const a=(0,Y.Ux)("div");a.innerHTML=this.commonAssets.getCloseButton(),a.setAttribute("aria-hidden","true"),a.style.height="16px",a.style.fill="var(--neutral-foreground-rest)";const s=(0,Y.Ux)("fluent-button");s.appendChild(a),s.id="closeButton",s.style.cursor="pointer",s.appearance="stealth",s.setAttribute("aria-label",this.flyoutData.strings.feedbackAriaClose),s.addEventListener("click",(t=>{const n=new W.Z(i.$S.FeedbackClose,this.telemetryUtilities.setContentViewed(this.GetModuleName()));n.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.logModule.LogInfoEvent(i.R.ButtonClick,"Closed out of feedback module",n);const o=this.flyoutData.common.shopping.querySelector(`#${r.z6.CLOSE}`),a=(0,T.pq)(t);if(o&&a&&o.focus(),this.isShortVersion)e.style.visibility="hidden";else{e.remove();const t=this.flyoutData.common.shopping.querySelectorAll("hr");let i;t&&t.length>0&&(i=t[t.length-1],i.remove())}})),e.append(n),e.append(o),e.append(s),t&&s&&s.focus()}toJSON(e){try{const t=JSON.stringify(e),i=JSON.parse(t);return i&&Array.isArray(i)&&0===i.length||"object"==typeof i&&0===Object.entries(i).length?void 0:i}catch{return}}getLogData(e,t=""){if(!this.flyoutData.dataLoader.GetLoadTimeDataValue("is_metrics_reporting_enabled",!1))return{};const i=this.flyoutData.dataStoreModule;let n;return"MicroFeedbackVote"===e?n={fullUrl:this.flyoutData.common.lastCommittedURL,isAutoShow:this.flyoutData.common.openedWith===r.Te.Auto}:"MicroFeedbackFollowUpVote"===e&&(n={answer:t,answerId:this.options.indexOf(t),clientFeedbackId:this.clientId,fullUrl:this.flyoutData.common.lastCommittedURL,isAutoShow:this.flyoutData.common.openedWith===r.Te.Auto,itemId:0,vote:"dislike"}),this.isBNPL||(t===this.options[0]?(n.couponData=this.toJSON(i.CouponData?.Coupons),n.dealsData=this.toJSON(i.CouponData?.Deals),n.socialCouponsData=this.toJSON(i.SocialCouponsData)):t===this.options[1]?n.orderTrackingData=this.toJSON(i.OrderTrackingData):t===this.options[2]?(n.priceComparisonData=this.toJSON(i.PriceComparisonData),n.priceHistoryData=this.toJSON(i.PriceHistoryData),n.priceHistoryData&&n.priceHistoryData.ProductDetails?.base64ProductImage&&(n.priceHistoryData.ProductDetails.base64ProductImage=void 0)):t===this.options[4]&&(n.cashbackData=this.toJSON(i.CashBackData),n.orderTrackingData=this.toJSON(i.OrderTrackingData),n.rewardsData=this.toJSON(i.RewardData),n.virtualCardData=this.toJSON(i.VirtualCardData),n.pinterestData=this.toJSON(i.PinterestData))),n}handleMenuDismiss(e,t,i){if(e.selected&&!e.menuVisible||i){for(;t.lastChild;)t.lastChild.remove();this.createThankYouDialogue(t,i)}}async microFeedbackLog(e){const t="like"===e?i.$S.FeedbackLike:i.$S.FeedbackDislike,n="like"===e?K.bS.FEEDBACK_THUMBS_UP:K.bS.FEEDBACK_THUMBS_DOWN,o=new W.Z(t,this.telemetryUtilities.setContentViewed(this.GetModuleName()));o.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination});const a=this.getLogData("MicroFeedbackVote");this.pageHandlerModule.RecordAsUserAction(n);const s=(0,h.hS)("NotificationContent");if((0,h.Ev)("NotificationContent",""),s&&!this.flyoutData.common.isPane){const t="like"===e;this.pageHandlerModule.RecordMicroFeedback(s,t)}if(this.logModule.LogInfoEvent(i.R.ButtonClick,"Vote: "+e,o),this.flyoutData.common.openedWith===r.Te.Auto&&this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_COUPONS_CHECKOUT&&"unlike"===e){const e=144e5;await this.autoOpenControllerUtilities.addNegativeEngagementForDomain(this.flyoutData.common.popupOrigination,1,e)}const l=await this.pageHandlerModule.SendMicroFeedbackVote(e,a,this.isBNPL);l?.clientFeedbackId&&(this.clientId=l.clientFeedbackId)}dislikeMenuLog(e,t,n){const o=n.target.textContent??"",r=this.options.indexOf(o);let a=Ey[r];a||(a=i.$S.Unknown);const s=new W.Z(a,this.telemetryUtilities.setContentViewed(this.GetModuleName())),l=this.getLogData("MicroFeedbackFollowUpVote",o);for(this.logModule.LogInfoEvent(i.R.ButtonClick,"Clicked follow up menu option for feedback: "+this.clientId,s),this.pageHandlerModule.SendMicroFeedbackFollowUpVote(this.clientId,r.toString(),o,l,this.isBNPL),"Other"===o&&0!==Object.entries(l).length&&this.pageHandlerModule.OpenMicroFeedback(JSON.stringify(l));e.lastChild;)e.lastChild.remove();this.createThankYouDialogue(e,t)}},Iy=o(93978);let Dy=function(e){return e.dailyDeals="dailyDeals",e.trendingOffers="trendingOffers",e.trendingCategoryDeals="trendingCategoryDeals",e.forumInfo="forumInfo",e}({});const _y=new Map([[Dy.dailyDeals,Iy.Jh],[Dy.trendingOffers,Iy.dV],[Dy.trendingCategoryDeals,Iy._X],[Dy.forumInfo,Iy.Zl]]);function Ny(e,t,i){if(!e||!t)return e;const n=e.filter((e=>!t.find((t=>e.name!==t.name))));i.sort(((e,t)=>e-t)).slice(0,t.length).forEach(((e,i)=>n.splice(e,0,t[i])));const o=t.slice(i.length,t.length);return n.push(...o),n}const Ry="https://assets.msn.com/service/news/feed/segments/shopping?apikey=xQDoKYnulweTMuWeKlSeDKcvt4qLSTAMQ53qodgVNO&",My="feature.prg-sh-brqstart";function Ly(e,t,i){const n=new URLSearchParams;return n.set("ocid","edgesidepane-startshop-feeds"),n.set("timeOut","10000"),n.set("user",`m-${t}`),n.set("market",e),n.set("activityid",i),n}function By(e,t=7500){const i=[e.scenario,e.catId?e.catId:"",e.offerId?e.offerId:"",e.lookupIds?e.lookupIds:"",e.impressionId,e.origin?e.origin:"",e.userAgent?e.userAgent:"",e.adUnitId?e.adUnitId:"",e.propertyId?e.propertyId:"",e.formCode?e.formCode:""];return e.variants&&e.tracingTag?i.push(`${e.variants},feature.${e.tracingTag}`):e.tracingTag?i.push(`feature.${e.tracingTag}`):i.push(e.variants?e.variants:""),`${i.join("|")}~${t}~`}let Fy=function(e){return e[e.BingHomepage=0]="BingHomepage",e[e.BingL2=1]="BingL2",e[e.MSN=2]="MSN",e}({});function Uy(e,t){let i=t.priceInfo?.price;const n=/[^0-9]/gi,o=(0,ne.Jl)(t.priceInfo?.priceCurrencySymbol);if(i){const r=(0,ne.K)(i,o),a=r.toFixed(2);i=(0,ne._B)(r,e);const s=a.match(n)?parseFloat(a.replace(n,""))/100:parseFloat(a);if(t.priceInfo.priceIntText=Math.floor(s).toLocaleString(e),t.priceInfo.priceHundredthText=(s-Math.floor(s)).toFixed(2).substring(2),t.priceInfo.originalPrice===t.priceInfo.price&&(t.priceInfo.originalPrice=void 0),t.priceInfo.originalPrice){const i=(parseFloat(t.priceInfo.originalPrice.replace(/[^0-9]/gi,""))/100).toLocaleString(e,{minimumFractionDigits:2});t.priceInfo.originalPrice=o+i}i.startsWith(t.priceInfo.priceCurrencySymbol)||(t.priceInfo.price=o+i)}}function Hy(e,t,i,n,o,r,a,s,l){return!t&&e.globalOfferId?ze.Z.IsMobile()?function(e,t,i,n){const o="https://www.bing."+("zh-cn"===e?"cn":"com"),r=new URLSearchParams;return r.set("pid",t),r.set("filters",`scenario:"17" gType:"12" gId:"${t}" gGlobalOfferIds:"${t}"`),r.set("form",i),r.set("productpage","true"),r.set("sdkhh","1"),r.set("sdkhnp","1"),n&&r.set("q",n),r.set("entryPoint","msn"),`${o}/shop/productpage?${r.toString()}`}(o,e.globalOfferId,s,e.brq?e.brq:e.title):l===Fy.BingL2?Zy(o,s,e.globalOfferId,e.title,e.brq?e.brq:e.title,i,n):l===Fy.BingHomepage?Zy(o,s,e.globalOfferId,e.title,void 0,i,n):function(e,t,i,n,o,r,a){const s="https://www.msn."+("zh-cn"===e?"cn":"com"),l=new URLSearchParams;return l.set("pid",t),l.set("click-source",i),l.set("ocid",n),o&&l.set("title",o),r&&a&&(l.set("modal-offer-ids",r.join(",")),l.set("modal-image-ids",a.join(","))),`${s}/${e}/shopping?${l.toString()}`}(o,e.globalOfferId,r,a,e.title,i,n):e.destination||e.destinationUrl||e.clickUrl||e.clickPingUrl}function $y(e,t,i,n){return Iy.z2.has(e)?`https://www.bing.${"zh-cn"===e?"cn":"com"}/shop/departments/${i}?filters=catid:"${t}"&FORM=${n}&${"fr-fr"!==e?"adunitId=378983&propertyId=316966":""}`:`https://www.msn.${"zh-cn"===e?"cn":"com"}/${e}/shopping/deals-category?catid=${t}&catname=${i}&FORM=${n}`}function Zy(e,t,i,n,o,r,a){const s="https://www.bing."+("zh-cn"===e?"cn":"com"),l=new URLSearchParams;return o&&l.set("q",o),i&&(l.set("overlayId",i),n&&l.set("overlayTitle",n),r&&a&&(l.set("overlayOfferIds",r.join(",")),l.set("overlayOfferImgIds",a.join(","))),l.set("entryPoint","msn")),l.set("form",t),"fr-fr"!==e&&(l.set("adunitId","378983"),l.set("propertyId","316966")),`${s}/shop?${l.toString()}`}function Vy(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}class Gy extends tc{static async fetchNativeAds(e,n,o,r){const a=function(e,t,i,n,o,r,a,s){const l=Ly(t,i,n);l.set("$select","mediationapi|search");const c={referer:"https://www.msn.com",userAgent:a,url:s,tracingTag:e,keywords:"",imageWidth:304,imageHeight:304};return l.set("$filter",`${JSON.stringify(c)}`),`${Ry}${l.toString()}`}(e,r,c.Z.uuidv4(),n.common.muid,0,0,navigator.userAgent,window.location.href),s=await this.fetchFrom1S(a,i.xu.StartShoppingAPINativeAdsError,o);if(s&&0!==s.length)return function(e){const t=[];return e?.length>0&&e.forEach((e=>{const i=e.decorations?.find((e=>"Ads/PaidSearchForNative/PAExtension"===e._type)),n=e.images?.find((e=>"ProductImage"===e.imageType)),o={title:e.title,description:e.description,seller:i?.sellerName,imageInfo:{sourceImageUrl:n?.imageUrl},clickUrl:e.targetUrl,destinationUrl:e.targetUrl,priceInfo:{originalPrice:i.dealPrice?i?.originalPrice:void 0,price:i?.dealPrice||i?.originalPrice,priceCurrencySymbol:"$"},adType:"Mediation"};o.imageInfo.sourceImageUrl&&t.push(o)})),{shoppingEntities:t}}(s);{const e=this.createErrorMessage("No native ads found",a);return o.LogErrorEvent(i.R.EdgeFlyoutStatus,e,new t.Z(i.xu.StartShoppingAPINoNativeAdsFound),Jl.g.EdgeImpressionId),{shoppingEntities:[]}}}static async fetchBaseAds(e,n,o,r,a,l=!1){if(this.responseCache.has(e))return this.responseCache.get(e);const d=function(e,t,i,n,o,r,a,s){const l=Ly(t,i,n),c=By({scenario:"TrendingOffers",lookupIds:e.replace(/[|]/g,""),impressionId:n,origin:a,userAgent:r,adUnitId:"378983",propertyId:"316966",variants:s?"feature.prg-sh-bsads":void 0,formCode:o});return l.set("$select","PersonalizedZI.Microservice.ProductAdsWorkflow"),l.set("$filter",c),`${Ry}${l.toString()}`}(e,a,n.common.muid,c.Z.uuidv4(),o,navigator.userAgent,window.location.origin,l),u=await this.fetchFrom1S(d,i.xu.StartShoppingAPIErrorBaseAdsWorkflow,r);if(!u?.shoppingEntities?.length){const e=this.createErrorMessage("No ads found from Base Ads",d,void 0);return r.LogErrorEvent(i.R.EdgeFlyoutStatus,e,new t.Z(i.xu.StartShoppingAPIEmptyBaseAdsWorkflow),Jl.g.EdgeImpressionId),{shoppingEntities:[]}}const h=function(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Vy(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Vy(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}({titleText:e,visibilityFeedbackUrl:u?.visibilityFeedbackUrl,includeAdSlug:!0},u);return this.responseCache.set(e,h),h}static async sendBaseAdsImpressions(e){const t=function(e){const t=[];return e.shoppingEntities.forEach((e=>{t.push(function(e){const t=e.position.split("-"),i=t[0].toUpperCase(),n=t[1];return`${i}_${e.impressionToken}-${n}`}(e))})),t.join("::")}(e),i=`https://www.bing.com/aes/c.gif?DI=0&GV=2&RG=${e.rguid}&DIS=${t}`;fetch(i)}}(0,s.Z)(Gy,"responseCache",new Map);class jy extends tc{static async fetchingAndCacheShoppingFeedModulesData(t,n,o,r){if(!this.hubPageDataPromise&&t.common.muid){const a=e.R.getServiceExperimentValue(f.H.BingL2BRQ)===Yu.dB.Treatment,s=function(e,t,i,n=!1){const o=Ly(e,t,i);Iy._X.has(e)?o.set("$select","PersonalizedZI.Microservice.HubPageWorkflowV2"):o.set("$select","PersonalizedZI.Microservice.HubPageWorkflow"),o.set("$top","24"),o.set("activityid",i);const r=By({scenario:"TrendingOffers",impressionId:i,variants:n?My:""});return o.set("$filter",r),`${Ry}${o.toString()}`}(r,t.common.muid,c.Z.uuidv4(),a),l=this.fetchFrom1S(s,i.xu.StartShoppingAPIErrorHubPageWorkflow,n);if(e.R.isExperimentActive(f.H.intersperseNativeAds)&&!e.R.isExperimentActive(f.H.startShoppingNativeAds)&&t.dataStoreModule.SANConsentData.PersonalizationDataConsent&&Iy.HX.has(r)){const e=await Gy.fetchNativeAds("prg-sh-medadspi",t,n,r),i=this.getStartShoppingNativeAdsIntersperseIndices();this.hubPageDataPromise=this.intersperseNativeAds(l,e?.shoppingEntities,i,o)}else this.hubPageDataPromise=l;const d=await this.hubPageDataPromise;return this.logAnyHubPageWorkflowEmptyKeys(n,d,s,r),this.logPersonalizedStatus(n,d,s),d}return this.hubPageDataPromise?await this.hubPageDataPromise:void 0}static async fetchTrendingCategoryOffers(e,n,o,r,a,s=!1){const l=function(e,t,i,n,o=!1){const r=Ly(e,t,n);r.set("activityid",n),r.set("$select","PersonalizedZI.Microservice.ZIWorkflowWrapper"),r.set("$top","24");const a=By({scenario:"TrendingOffersOfCategory",catId:i,impressionId:n,variants:o?My:""});return r.set("$filter",a),`${Ry}${r.toString()}`}(r,n.common.muid,e.id,c.Z.uuidv4(),s),d=await this.fetchFrom1S(l,i.xu.StartShoppingAPIErrorZIWorkflowWrapper,o);if(d?.shoppingEntities?.length>0)return{shoppingEntities:d.shoppingEntities,titleText:e.title,clickoutUrl:$y(r,e.id,e.title,a)};if(0===d?.shoppingEntities?.length){const e=this.createErrorMessage("ZIWorkflowWrapper empty reponse",l);o.LogErrorEvent(i.R.EdgeFlyoutStatus,e,new t.Z(i.xu.StartShoppingAPIEmptyResponseZIWorkflowWrapper),Jl.g.EdgeImpressionId)}return{shoppingEntities:[],titleText:""}}static async fetchArticleCashbackOffers(e,t,n,o){const r=function(e,t,i,n,o,r,a){const s=Ly(t,i,n),l=By({scenario:"TrendingOffers",lookupIds:e,impressionId:n,origin:a,userAgent:r,adUnitId:"378983",propertyId:"316966",variants:"",formCode:o});return s.set("$select","PersonalizedZI.Microservice.ArticleCashbackOffersWorkflow"),s.set("$filter",l),`${Ry}${s.toString()}`}(e,n,t,c.Z.uuidv4(),o,navigator.userAgent,window.origin),a=await this.fetchFrom1S(r,i.xu.StartShoppingAPIErrorZIWorkflowWrapper);return a?.shoppingEntities?.length>0?{shoppingEntities:a.shoppingEntities}:null}static async intersperseNativeAds(e,t,i,n){if(!t||!t.length)return await e;const o=await e;return(o?.trendingOffers||o?.dailyDeals)&&n.TriggerExperiment(f.H.intersperseNativeAds),function(e,t,i){const n=e?.trendingOffers,o=e?.dailyDeals;if(!t||!e||!n?.length&&!o?.length)return;let r=n,a=o;if(n&&o){const e=Math.floor(t.length/2),s=t.slice(0,Math.floor(e)),l=t.slice(e);r=Ny(n,s,i),a=Ny(o,l,i)}else n?r=Ny(n,t,i):a=Ny(o,t,i);e.trendingOffers=r,e.dailyDeals=a}(o,t,i),o}static getStartShoppingNativeAdsIntersperseIndices(){const t=e.R.getMultipleVariants(f.H.intersperseNativeAds).find((e=>"idx"===e.key&&!(0,p.TF)(e.value)));return t?JSON.parse(t?.value):[0,3]}static logAnyHubPageWorkflowEmptyKeys(e,n,o,r){if(!n)return;const a=[Dy.dailyDeals,Dy.trendingOffers,Dy.trendingCategoryDeals].filter((e=>function(e,t){if(!e||!t)return!1;const i=_y.get(e);return!!i&&i.has(t)}(e,r))),s=[];for(const e of a)n[e]&&0!==n[e].length||s.push(e);if(s.length>0){const n=a.length===s.length?"All":"Some",r=this.createErrorMessage(`${n} expected keys from HubPageWorkflow are empty`,o,s);e.LogErrorEvent(i.R.EdgeFlyoutStatus,r,new t.Z(i.xu.StartShoppingAPIEmptyResponseHubPageWorkflow),Jl.g.EdgeImpressionId)}}static logPersonalizedStatus(e,n,o){if(!n)return;const r=n.trendingOffersMetadata?.forYou?"1":"0",a=n.dailyDealsMetadata?.forYou?"1":"0",s=n.trendingCategoryDealsMetadata?.forYou?"1":"0",l=n.metadata?.xapTraceId,c={url:o,isTrendingOffersPersonalized:r,isDailyDealsPersonalized:a,isTrendingCategoryDealsPersonalized:s,xapTraceId:l};e.LogInfoEvent(i.R.EdgeFlyoutStatus,JSON.stringify(c),new t.Z(i.xu.StartShoppingAPIHubPagePersonalized),Jl.g.EdgeImpressionId)}}(0,s.Z)(jy,"hubPageDataPromise",void 0);const zy=Object.freeze({EdgeSidePane:"SSEG01",VisualSearch:"EDGSIM",EdgeSidePane2:"SSEG02",EdgeSidePane3:"SSEG03",EdgeSidePane4:"SSEG04",EdgeSidePane5:"SSEG05",EdgeSidePane6:"SSEG06",EdgeSidePane7:"SSEG07",EdgeSidePane8:"SSEG08",EdgeSidePane9:"SSEG09"}),Wy=Object.freeze({EdgeSidePane:"msedgsp",EdgeSidePane2:"msedgsp2",EdgeSidePane3:"msedgsp3",EdgeSidePane4:"msedgsp4",EdgeSidePane5:"msedgsp5"});function Ky(e,t){if(!e||!t)return"";const i="www.msn."+("zh-cn"===t?"cn":"com"),n=new URL(e.replace("{hostName}",i).replace("{localeCode}",t));return n.searchParams.set("ocid",Wy.EdgeSidePane),n.toString()}var qy=class extends Qu{constructor(e,t){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"component",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"intersectionObserver",void 0),(0,s.Z)(this,"cachedContainer",void 0),(0,s.Z)(this,"market",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"moduleSeen",!1),this.market=function(e,t,i){if(!t||0===t.length)return"en-us";let n;for(const i of t){if(i.indexOf("-")>=0)return i.toLowerCase();if(!n&&(n=i.toLowerCase(),e?.common?.afdMarket&&e.common.afdMarket.toLowerCase().startsWith(n)))return e.common.afdMarket}for(const e of i)if(e.startsWith(`${n}-`))return e}(e,navigator.languages,this.GetEnabledMarkets()),this.flyoutData=e,this.utilities=t.viewModulesUtilities,this.logModule=t.logModule,this.pageHandlerModule=t.pageHandlerModule,this.telemetryUtilities=t.telemetryHandler,this.initializeComponent()}ShouldRenderModule(){return Promise.resolve(this.featureTogglesAreActive()&&!!this.flyoutData.common.muid&&!!this.market&&this.GetEnabledMarkets().has(this.market)&&(this.flyoutData.common.isPane||ze.Z.IsMobile())&&(!this.SANConsentRequired()||this.flyoutData.dataStoreModule.SANConsentData.PersonalizationDataConsent))}renderModule(){this.cachedContainer||(this.cachedContainer=(0,Y.Ux)("DIV"),this.cachedContainer.id="feedModule",this.cachedContainer.appendChild(this.component),this.intersectionObserver=new IntersectionObserver(this.intersectionObserverCallback.bind(this),{rootMargin:"200px"}),this.intersectionObserver.observe(this.component));const e=this.CreateModule(this.cachedContainer,this.GetModulePriority(),this.GetModuleName(),this.GetModulePaneTab(),r.SV.SQUARES);return Promise.resolve(e)}populateMainHeader(){let t;t=e.R.isExperimentActive(f.H.singleScrollingShoreline)?this.flyoutData.common.shoppingExplore:this.flyoutData.common.shoppingPersistent;const i=t.querySelector("#feedModule");i&&(i.slot="header-content",i.style.width="100%",i.parentElement?.classList.add("no-padding-header"),i.children[0]&&(i.children[0].isPolePosition=!0))}GetModuleName(){return this.GetStartShoppingModuleName()}GetModulePaneTab(){return e.R.isExperimentActive(f.H.singleScrollingShoreline)?r.$k.EXPLORE:r.$k.HOME}featureTogglesAreActive(){return!0}intersectionObserverCallback(e,t){if(e&&!(e.length<1)&&e.find((e=>e.isIntersecting))&&(this.intersectionObserver.disconnect(),!this.moduleSeen)){if(this.moduleSeen=!0,!this.market)return void(this.component.style.display="none");this.moduleFirstVisible(this.market)}}},Yy=class extends qy{initializeComponent(){this.component=(0,Y.Ux)("msft-product-feed"),this.component.productsToShow=this.DefaultNumberOfProductsToShow(),this.component.showMoreButtonText=this.flyoutData.strings.showMore,this.component.seeAllButtonText=this.flyoutData.strings.commonSeeAll,this.component.adSlugText=this.flyoutData.strings.adSlug,this.component.productCardAdSlugText=this.flyoutData.strings.productCardAdSlugText,this.component.adSlugPolicyText=this.flyoutData.strings.adSlugPolicy,this.component.navigateToDestination=this.navigateToDestination.bind(this,this.GetCardClickTelemetry()),this.component.navigateToAdSlugDestination=this.navigateToAdSlugDestination.bind(this),this.component.handleClickPingUrl=this.handleBaseAdsClickPingUrl.bind(this),this.component.logShowMoreButtonClicked=this.logShowMoreButtonClicked.bind(this,this.GetShowMoreClickTelemtry()),e.R.getServiceExperimentValue(f.H.SeeAllClickout)===Yu.L0.Title?this.component.useClickableTitles=!0:e.R.getServiceExperimentValue(f.H.SeeAllClickout)===Yu.L0.OneClick?this.component.useShowMoreClickout=!0:e.R.getServiceExperimentValue(f.H.SeeAllClickout)===Yu.L0.TwoClick&&(this.component.useTwoClickShowMoreClickout=!0),this.component.clickoutUrl=this.GetClickoutUrl()}transformShoppingEntities(e,t){let i;return i=this.market&&Iy.e6.has(this.market)?Fy.BingL2:this.market&&Iy.H8.has(this.market)?Fy.BingHomepage:Fy.MSN,function(e,t,i,n,o,r,a){if(!e||0===e.length||!i)return[];const[s,l]=function(e){const t=[],i=[];return e?.forEach((e=>{const n=e.globalOfferId||function(e){if(!e)return"";const t=e.split("-");return 2!==t.length||["cdeals"].includes(t[0])?e:t[1]}(e.id);if(e&&n&&e?.imageInfo?.sourceImageUrl){let o;try{o=new URL(e.imageInfo.sourceImageUrl)}catch(e){}o?.searchParams.has("id")&&(t.push(n),i.push(o.searchParams.get("id")))}})),[t,i]}(e);for(const c of e){const e=!!(c.adType||c.clickUrl?.includes("www.bing.com/aclick")&&!c.affiliateHash);c.destination=Hy(c,e,s,l,i,t,o,r,a),Uy(i,c),c.dealPercentage&&c.priceInfo?.originalPrice?(c.dealPercentageLocalized=(0,T.fZ)("dealPercentage",n.percentageOff,c.dealPercentage),c.altText=(0,T.fZ)(e?"sponsoredDealOfferAltText":"dealOfferAltText",e?n.sponsoredDealOfferAltText:n.dealOfferAltText,c.title,c.seller,c.priceInfo?.price,c.priceInfo?.originalPrice,c.dealPercentage)):c.altText=(0,T.fZ)(e?"sponsoredOfferAltText":"offerAltText",e?n.sponsoredOfferAltText:n.offerAltText,c.title,c.seller,c.priceInfo?.price)}return e}(e,this.GetStartShoppingModuleName(),t,this.flyoutData.strings,this.getOcid(),this.getFormCode(),i)}getFormCode(){return zy.EdgeSidePane}getOcid(){return e.R.getServiceExperimentValue(f.H.BingL2BRQ)===Yu.dB.Treatment?Wy.EdgeSidePane4:e.R.getServiceExperimentValue(f.H.BingL2BRQ)===Yu.dB.Control?Wy.EdgeSidePane5:Wy.EdgeSidePane}GetClickoutUrl(){return this.market?Zy(this.market,this.getFormCode()):""}SANConsentRequired(){return!1}DefaultNumberOfProductsToShow(){return 6}navigateToDestination(e,t){const n=new W.Z(e.buttonName,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,`${e.buttonName} clicked in Start Shopping Feed Module: ${this.GetStartShoppingModuleName()}`,n),this.pageHandlerModule.RecordAsUserEngagement(e.engagement,this.flyoutData.common.popupOrigination),this.pageHandlerModule.NavigateToUrl(t)}navigateToAdSlugDestination(e){const t=new W.Z(i.$S.ShoppingAdSlug,this.telemetryUtilities.setContentViewed(this.GetModuleName())),n=`Ad slug clicked in Start Shopping Feed Module: ${this.GetStartShoppingModuleName()}`;this.logModule.LogInfoEvent(i.R.ButtonClick,n,t),this.pageHandlerModule.NavigateToUrl(e)}handleBaseAdsClickPingUrl(e){navigator.sendBeacon(e)}logShowMoreButtonClicked(e){const t=new W.Z(e.buttonName,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,`Show more button clicked for feed module: ${this.GetStartShoppingModuleName()}`,t),this.pageHandlerModule.RecordAsUserAction(e.action)}};function Xy(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Jy(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Xy(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Xy(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var Qy=class extends Yy{constructor(...e){super(...e),(0,s.Z)(this,"buyDirectCashbackPercentage",20)}async moduleFirstVisible(e){const t=await jy.fetchingAndCacheShoppingFeedModulesData(this.flyoutData,this.logModule,this.pageHandlerModule,e);t?.forumInfo?.forumCategories?.length>0?(this.component.navigateToTitleDestination=this.navigateToDestination.bind(this,this.GetTitleClickTelemetry()),this.component.titleText=this.flyoutData.strings.buyDirectTitle,this.component.shoppingEntities=this.transformForumShoppingEntities(t.forumInfo.forumCategories,e),this.component.clickoutUrl=this.GetClickoutUrl()):this.component.style.display="none"}GetStartShoppingModuleName(){return r.ModuleNames.BUY_DIRECT}GetModulePriority(){return r.H7.BUY_DIRECT}GetTitleClickTelemetry(){return{buttonName:i.$S.BuyDirectTitle,engagement:q.FV.FEED_BUY_DIRECT,engagementMojom:q.ZF.FEED_BUY_DIRECT}}GetCardClickTelemetry(){return{buttonName:i.$S.BuyDirectCard,engagement:q.FV.FEED_BUY_DIRECT,engagementMojom:q.ZF.FEED_BUY_DIRECT}}GetShowMoreClickTelemtry(){return{buttonName:i.$S.BuyDirectShowMore,action:K.bS.FEED_BUY_DIRECT_SHOW_MORE,actionMojom:K.R9.FEED_BUY_DIRECT_SHOW_MORE}}GetClickoutUrl(){return`https://www.msn.com/en-us/shopping/buydirect/home?FORM=${this.getFormCode()}`}GetEnabledMarkets(){return Iy.Zl}GetModuleViewed(){return bp.r.FEED_BUY_DIRECT}GetModuleViewedMojom(){return bp.L.FEED_BUY_DIRECT}transformForumShoppingEntities(e,t){if(!e||0===e.length)return[];let i=[];return e.forEach((e=>{if(e.forumProducts&&Array.isArray(e.forumProducts)&&e.forumProducts[0]){const n=e.forumProducts.filter((e=>e.imageInfo?.images&&Array.isArray(e.imageInfo.images)&&e.priceInfo?.price)).map((e=>this.refineForumShoppingEntitiesData(e,t,this.buyDirectCashbackPercentage)));i=i.concat(n)}})),i}refineForumShoppingEntitiesData(e,t,i){const n=e.imageInfo?.images?.map((e=>({sourceImageUrl:e.url})));return Uy(t,e),this.calculateDealPercentageFromPriceInfo(e),this.dealInfoAltTextForProduct(e),e.destination||(e.destination=this.generateForumShoppingPDPUrl(e.globalOfferId,e.title)),e.seller=i&&i>0?(0,T.fZ)("buyDirectCashback",this.flyoutData.strings.buyDirectCashback,`${i}%`):this.flyoutData.strings.buyDirectSeller,e.shipping=this.flyoutData.strings.buyDirectShipping,Jy(Jy({},e),{},{images:n,imageInfo:n[0]})}dealInfoAltTextForProduct(e){e.dealPercentage?(e.dealPercentageLocalized=(0,T.fZ)("dealPercentage",this.flyoutData.strings.percentageOff,e.dealPercentage),e.altText=(0,T.fZ)("buyDirectOfferAltText",this.flyoutData.strings.buyDirectOfferAltText,e.title,e.priceInfo?.price,e.priceInfo?.originalPrice,e.dealPercentage)):e.altText=(0,T.fZ)("buyDirectAltText",this.flyoutData.strings.buyDirectAltText,e.title,e.priceInfo?.price)}calculateDealPercentageFromPriceInfo(e){if(e?.priceInfo?.originalPrice&&e?.priceInfo?.price){const t=parseFloat(e.priceInfo.originalPrice.replace(/[^0-9]/gi,""))/100,i=parseFloat(e.priceInfo.price.replace(/[^0-9]/gi,""))/100,n=Math.round((t-i)/t*100);n>0&&(e.dealPercentage=`${n}%`)}}generateForumShoppingPDPUrl(e,t){const i=new URLSearchParams;i.set("pid",e),t&&i.set("q",t),i.set("browse","true"),i.set("productpage","true"),i.set("entrypoint","buydirect");const n="BDEDGSP";i.set("ocid",n),i.set("trafsrc",n);const o=`filters=scenario:"17"+gType:"12"+gId:"${e}"+gGlobalOfferIds:"${e}"`;return`https://www.bing.com/shop/productpage?${i.toString()}&${o}`}};class eC{static async fetchTopDeals(e,t,n){const o=function(e,t,i){return`https://api.msn.com/shopping/blackjack/getproductdeals?apikey=xQDoKYnulweTMuWeKlSeDKcvt4qLSTAMQ53qodgVNO&${Ly(e,t,i).toString()}`}(e,t.common.muid,c.Z.uuidv4());try{const e=await fetch(o,{method:"POST",body:'{"productDealsRequest":{"grid":[{"filterBy":"Category","values":["BlockbusterDeal"]}]},"skip":0,"take":24,"getProductDeals":true,"isDebug":false}',headers:{"Content-type":"application/json; charset=utf-8"}}),t=await e.json();if(!t.data)return void eC.logEmptyResponse(n,o);const i=JSON.parse(t.data),r=i?.response?.productDealsResponse?.grid?.deals;return r&&0!==r.length?r:void eC.logEmptyResponse(n,o,i?.response?.traceId)}catch(e){return void this.logError(n,"Request failed",o,i.xu.CampaignAPITopDealsError,e)}}static logEmptyResponse(e,t,n){eC.logError(e,"Request empty for Deal Days top deals",t,i.xu.CampaignAPITopDealsNoResultsFound,void 0,n)}static logError(e,n,o,r,a,s){const l=this.createErrorMessage(n,o,a,s);e.LogErrorEvent(i.R.EdgeFlyoutStatus,l,new t.Z(r),Jl.g.EdgeImpressionId)}static createErrorMessage(e,t,i,n){return JSON.stringify({message:i?`${e} | ${i}`:e,url:t,traceId:n})}}var tC=class extends Yy{async moduleFirstVisible(e){const t=function(e){const t=[];if(e?.length>0)for(const i of e)if(i.adData?.images?.length>0){const e=i.adData.currencySymbol,n=i.decorations?.miscDecorations?.priceAfterCashback||i.decorations?.miscDecorations?.priceAfterCoupon||i.decorations?.miscDecorations?.discountPrice,o=i.adData.originalPrice?.replace(e,""),r=i.decorations?.miscDecorations?.dealPercent;t.push({dealPercentage:r?`${r}%`:void 0,title:i.adData.title,seller:i.adData.seller,priceInfo:{price:n,originalPrice:o,priceCurrencySymbol:e},imageInfo:{sourceImageUrl:`https://th.bing.com${i.adData.images[0].imageUrl}`},destination:i.adData.destinationUrl})}return t}(await eC.fetchTopDeals(e,this.flyoutData,this.logModule));if(t?.length>0&&this.flyoutData.dataStoreModule.CampaignData?.expData.isCampaignActive()){const i=document.createElement("DIV");i.slot="product-feed-heading";const n=Vp(this.flyoutData.strings,this.flyoutData.common.resourcesEndpoint);n.style.marginTop="4px",i.appendChild(n);const o=this.flyoutData.dataStoreModule.CampaignData.expData.endTime;if(o){const e=document.createElement("DIV");e.style.display="inline-block",e.style.margin="16px 0 20px",e.appendChild(Gp(this.flyoutData.strings,o)),i.appendChild(e)}this.component.appendChild(i),this.component.shoppingEntities=this.transformShoppingEntities(t,e),this.cachedContainer.classList.add("campaign-feed-module")}else this.component.style.display="none"}initializeComponent(){super.initializeComponent(),this.component.className="campaign-module";const e=new Fp;this.utilities.applyStyles(this.component,e.getStyles(),void 0,e.getDarkModeStyles())}featureTogglesAreActive(){return super.featureTogglesAreActive()&&!!this.flyoutData.dataStoreModule.CampaignData?.expData.isCampaignActive()}GetStartShoppingModuleName(){return r.ModuleNames.FEED_CAMPAIGN}GetModulePriority(){return r.H7.FEED_CAMPAIGN}GetCardClickTelemetry(){return{buttonName:i.$S.TrendingOffersCard,engagement:q.FV.FEED_CAMPAIGN,engagementMojom:q.ZF.FEED_CAMPAIGN}}GetShowMoreClickTelemtry(){return{buttonName:i.$S.TrendingOffersShowMore,action:K.bS.FEED_CAMPAIGN_SHOW_MORE,actionMojom:K.R9.FEED_CAMPAIGN_SHOW_MORE}}GetEnabledMarkets(){return Iy.Kc}GetModuleViewed(){return bp.r.FEED_CAMPAIGN}GetModuleViewedMojom(){return bp.L.FEED_CAMPAIGN}},iC=class extends Yy{async moduleFirstVisible(e){const t=await jy.fetchingAndCacheShoppingFeedModulesData(this.flyoutData,this.logModule,this.pageHandlerModule,e);t?.dailyDeals?.length>0?(this.component.navigateToTitleDestination=this.navigateToDestination.bind(this,this.GetTitleClickTelemetry()),this.component.titleText=this.flyoutData.strings.dailyDealsTitle,this.component.shoppingEntities=this.transformShoppingEntities(t.dailyDeals,e)):this.component.style.display="none"}GetStartShoppingModuleName(){return r.ModuleNames.DAILY_DEALS}GetModulePriority(){return r.H7.DAILY_DEALS}GetTitleClickTelemetry(){return{buttonName:i.$S.DailyDealsTitle,engagement:q.FV.FEED_DAILY_DEALS,engagementMojom:q.ZF.FEED_DAILY_DEALS}}GetCardClickTelemetry(){return{buttonName:i.$S.DailyDealsCard,engagement:q.FV.FEED_DAILY_DEALS,engagementMojom:q.ZF.FEED_DAILY_DEALS}}GetShowMoreClickTelemtry(){return{buttonName:i.$S.DailyDealsShowMore,action:K.bS.FEED_DAILY_DEALS_SHOW_MORE,actionMojom:K.R9.FEED_DAILY_DEALS_SHOW_MORE}}GetEnabledMarkets(){return Iy.Jh}GetModuleViewed(){return bp.r.FEED_DAILY_DEALS}GetModuleViewedMojom(){return bp.L.FEED_DAILY_DEALS}},nC=class extends Yy{constructor(...e){super(...e),(0,s.Z)(this,"requestParamsList",void 0),(0,s.Z)(this,"initialFeedsCount",1)}initializeComponent(){this.component=(0,Y.Ux)("msft-infinite-product-feeds"),this.component.productsToShow=this.DefaultNumberOfProductsToShow(),this.component.showMoreButtonText=this.flyoutData.strings.showMore,this.component.seeAllButtonText=this.flyoutData.strings.commonSeeAll,this.component.adSlugText=this.flyoutData.strings.adSlug,this.component.adSlugPolicyText=this.flyoutData.strings.adSlugPolicy,this.component.navigateToTitleDestination=this.navigateToDestination.bind(this,this.GetTitleClickTelemetry()),this.component.navigateToDestination=this.navigateToDestination.bind(this,this.GetCardClickTelemetry()),this.component.navigateToAdSlugDestination=this.navigateToAdSlugDestination.bind(this),this.component.logShowMoreButtonClicked=this.logShowMoreButtonClicked.bind(this,this.GetShowMoreClickTelemtry()),this.component.navigateToTitleDestination=this.navigateToDestination.bind(this,this.GetTitleClickTelemetry()),this.component.navigateToAdDestination=this.navigateToDestination.bind(this,this.GetAdCardClickTelemetry()),this.component.logShowMoreAdButtonClicked=this.logShowMoreButtonClicked.bind(this,this.GetAdShowMoreClickTelemtry()),this.component.handleClickPingUrl=this.handleBaseAdsClickPingUrl.bind(this),this.component.includeSeparator=!e.R.isExperimentActive(f.H.singleScrollingShoreline),e.R.getServiceExperimentValue(f.H.SeeAllClickout)===Yu.L0.Title?this.component.useClickableTitles=!0:e.R.getServiceExperimentValue(f.H.SeeAllClickout)===Yu.L0.OneClick?this.component.useShowMoreClickout=!0:e.R.getServiceExperimentValue(f.H.SeeAllClickout)===Yu.L0.TwoClick&&(this.component.useTwoClickShowMoreClickout=!0)}async moduleFirstVisible(e){this.pageHandlerModule.TriggerExperiment(f.H.startShoppingCategoryAds);const t=await jy.fetchingAndCacheShoppingFeedModulesData(this.flyoutData,this.logModule,this.pageHandlerModule,e);if(!t)return void(this.component.style.display="none");this.requestParamsList=[];const i=new Set;if(t.trendingCategoryDeals?.length>0)for(const n of t.trendingCategoryDeals)n?.categoryInfo_2?.categoryId&&n.categoryInfo_2?.categoryName&&!i.has(n.categoryInfo_2.categoryName)&&(i.add(n.categoryInfo_2.categoryName),this.requestParamsList.push({id:n.categoryInfo_2.categoryId,title:n.categoryInfo_2.categoryName,market:e}));if(t.trendingOffers)for(const n of t.trendingOffers)n?.categoryInfo_2?.categoryId&&n?.categoryInfo_2?.categoryName&&!i.has(n.categoryInfo_2.categoryName)&&(i.add(n.categoryInfo_2.categoryName),this.requestParamsList.push({id:n.categoryInfo_2.categoryId,title:n.categoryInfo_2.categoryName,market:e}));if(t.popularCategories)for(const n of t.popularCategories)n?.id&&n?.title&&!i.has(n.title)&&(i.add(n.title),this.requestParamsList.push({id:n.id,title:n.title,market:e}));if(0===i.size)return void(this.component.style.display="none");const n=this.getStartShoppingCategoryAdsIndices(),o=[];if(0!==n.length&&Iy.Uo.has(e)&&this.flyoutData.dataStoreModule.SANConsentData.PersonalizationDataConsent)for(let e=0;e<n.length&&e<this.initialFeedsCount;e++)n[e]<this.requestParamsList.length&&o.push(this.getNextFeed(this.requestParamsList[n[e]],!0));const r=[];for(let e=0;this.requestParamsList.length>0&&e<this.initialFeedsCount;e++)r.push(this.getNextFeed(this.requestParamsList.shift(),!1));const a=await Promise.all(o),s=await Promise.all(r);if(n.forEach(((e,t)=>{a[t]?.shoppingEntities?.length&&e<s.length&&(s[e]=a[t])})),s?.length>0&&s[0].shoppingEntities?.length>0){if(this.component.infiniteProductFeedsData=s,this.component.setupPagination(this.getNextFeed.bind(this),this.requestParamsList),s[0].includeAdSlug){const e=s[0].shoppingEntities,t=s[0].visibilityFeedbackUrl;this.component.sendAdVisibilityFeedback=xl.bind(null,t),xl(t,e.slice(0,this.DefaultNumberOfProductsToShow()).map((e=>e.impressionToken)))}}else this.component.style.display="none"}SANConsentRequired(){return!1}GetStartShoppingModuleName(){return r.ModuleNames.INFINITE_CATEGORY_FEED}GetModulePriority(){return r.H7.MAX}GetTitleClickTelemetry(){return{buttonName:i.$S.InfiniteCategoryAdFeedTitle,engagement:q.FV.FEED_INFINITE_CATEGORY,engagementMojom:q.ZF.FEED_INFINITE_CATEGORY}}GetCardClickTelemetry(){return{buttonName:i.$S.InfiniteCategoryFeedCard,engagement:q.FV.FEED_INFINITE_CATEGORY,engagementMojom:q.ZF.FEED_INFINITE_CATEGORY}}GetShowMoreClickTelemtry(){return{buttonName:i.$S.InfiniteCategoryFeedShowMore,action:K.bS.FEED_INFINITE_CATEGORY_SHOW_MORE,actionMojom:K.R9.FEED_INFINITE_CATEGORY_SHOW_MORE}}GetEnabledMarkets(){return Iy._X}GetModuleViewed(){return bp.r.FEED_INFINITE_CATEGORY}GetModuleViewedMojom(){return bp.L.FEED_INFINITE_CATEGORY}GetAdCardClickTelemetry(){return{buttonName:i.$S.InfiniteCategoryFeedAdCard,engagement:q.FV.FEED_INFINITE_CATEGORY_AD,engagementMojom:q.ZF.FEED_INFINITE_CATEGORY_AD}}GetAdShowMoreClickTelemtry(){return{buttonName:i.$S.InfiniteCategoryAdFeedShowMore,action:K.bS.FEED_INFINITE_CATEGORY_AD_SHOW_MORE,actionMojom:K.R9.FEED_INFINITE_CATEGORY_AD_SHOW_MORE}}getStartShoppingCategoryAdsIndices(){if(!e.R.isExperimentActive(f.H.startShoppingCategoryAds))return[];const t=e.R.getMultipleVariants(f.H.startShoppingCategoryAds).find((e=>"idx"===e.key&&!(0,p.TF)(e.value)));return t?JSON.parse(t?.value):[0]}async getNextFeed(t,i){if(t){let n;if(i)n=await Gy.fetchBaseAds(t.title,this.flyoutData,this.getFormCode(),this.logModule,t.market);else{const i=e.R.getServiceExperimentValue(f.H.BingL2BRQ)===Yu.dB.Treatment;n=await jy.fetchTrendingCategoryOffers(t,this.flyoutData,this.logModule,t.market,this.getFormCode(),i)}return this.component.shoppingEntities=this.transformShoppingEntities(n.shoppingEntities,t.market),n}}},oC=class extends Yy{async moduleFirstVisible(e){const t=this.flyoutData.common.extractedEntity;let i=t?.entity?.name;if(i||(i=t?.title),!e||!i)return void(this.component.style.display="none");this.pageHandlerModule.TriggerExperiment(f.H.startShoppingRelatedProducts);const n=await Gy.fetchBaseAds(i,this.flyoutData,this.getFormCode(),this.logModule,e);n?.shoppingEntities?.length>0?(this.component.titleText=this.flyoutData.strings.relatedProductsModuleTitle,this.component.shoppingEntities=this.transformShoppingEntities(n.shoppingEntities,e),this.component.includeAdSlug=!0):this.component.style.display="none"}GetModulePaneTab(){return r.$k.CONTEXTUAL}GetStartShoppingModuleName(){return r.ModuleNames.RELATED_PRODUCTS}GetModulePriority(){return r.H7.RELATED_PRODUCTS}GetCardName(){return i.$S.RelatedProductsCard}GetCardClickTelemetry(){return{buttonName:i.$S.RelatedProductsCard,engagement:q.FV.FEED_RELATED_PRODUCTS,engagementMojom:q.ZF.FEED_RELATED_PRODUCTS}}GetShowMoreClickTelemtry(){return{buttonName:i.$S.NativeAdsShowMore,action:K.bS.FEED_RELATED_PRODUCTS_SHOW_MORE,actionMojom:K.R9.FEED_RELATED_PRODUCTS_SHOW_MORE}}GetEnabledMarkets(){return Iy.Uo}getFormCode(){return zy.EdgeSidePane5}featureTogglesAreActive(){return(!!this.flyoutData.common.extractedEntity?.entity?.name||!!this.flyoutData.common.extractedEntity?.title)&&super.featureTogglesAreActive()&&e.R.isExperimentActive(f.H.startShoppingRelatedProducts)}SANConsentRequired(){return!1}GetModuleViewed(){return bp.r.FEED_RELATED_PRODUCTS}GetModuleViewedMojom(){return bp.L.FEED_RELATED_PRODUCTS}};function rC(e,t){return e.ProductImageOriginalUrl&&""!==e.ProductImageOriginalUrl?e.ProductImageOriginalUrl.replace("edge://image?",""):e.ProductImageUrl&&""!==e.ProductImageUrl?e.ProductImageUrl:t.resourcesEndpoint+"common/defaultProduct.svg"}var aC=class extends Yy{async ShouldRenderModule(){if(!this.featureTogglesAreActive()||!this.flyoutData.common.isPane)return!1;const e=this.flyoutData.dataStoreModule.PriceComparisonData,t=e?.segment?.toLowerCase();return t!==r.VG.AUTOS&&t!==r.VG.EMPTYAUTOSSEGMENT&&!!e?.similarOffers?.length}async moduleFirstVisible(t){const i=this.flyoutData.dataStoreModule.PriceComparisonData;if(!i||!i.similarOffers||0===i.similarOffers.length)return void(this.component.style.display="none");e.R.isVariantActive(f.H.similarOffers,"Treatment")&&(this.component.useMasonryGrid=!0),this.pageHandlerModule.TriggerExperiment(f.H.similarOffers);const n=i.similarOffers.filter((e=>e.position===r.zE.SIMILAR_OFFERS));let o;if(n.length>0){this.component.includeAdSlug=!0;const e=n.slice(0,6).map((e=>e.ImpressionToken)),t=i.visibilityFeedbackUrl;this.component.sendAdVisibilityFeedback=xl.bind(null,t),xl(t,e),o=this.transformEntities(n)}else{const e=i.similarOffers.filter((e=>e.position===r.zE.SIMILAR_OFFERS_FREE));if(e.length<=0)return void(this.component.style.display="none");o=this.transformEntities(e)}o?.length>0?(o.forEach(((e,t)=>{e.tabOrder=t})),this.component.titleText=this.flyoutData.strings.similarOffersTitle,this.component.shoppingEntities=this.transformShoppingEntities(o,t)):this.component.style.display="none"}GetStartShoppingModuleName(){return r.ModuleNames.SIMILAR_OFFERS}GetModulePriority(){return r.H7.SIMILAR_OFFERS}GetCardClickTelemetry(){return{buttonName:i.$S.SimilarOffersCard,engagement:q.FV.FEED_SIMILAR_OFFERS,engagementMojom:q.ZF.FEED_SIMILAR_OFFERS}}GetShowMoreClickTelemtry(){return{buttonName:i.$S.SimilarOffersShowMore,action:K.bS.FEED_SIMILAR_OFFERS_SHOW_MORE,actionMojom:K.R9.FEED_SIMILAR_OFFERS_SHOW_MORE}}GetEnabledMarkets(){return Iy.eg}GetModulePaneTab(){return r.$k.CONTEXTUAL}featureTogglesAreActive(){return super.featureTogglesAreActive()&&e.R.isExperimentActive(f.H.similarOffers)}GetModuleViewed(){return bp.r.SIMILAR_OFFERS}GetModuleViewedMojom(){return bp.L.SIMILAR_OFFERS}transformEntities(e){return e.map((e=>function(e,t){return{title:e.Description,seller:e.SellerName,imageInfo:{sourceImageUrl:rC(e,t)},priceInfo:{price:e.Price.toString(),priceCurrencySymbol:e.CurrencySymbol},globalOfferId:e.globalOfferId,shippingPrice:e.shippingPrice,destination:e.Url,impressionToken:e.ImpressionToken,adType:"SimilarOffers"}}(e,this.flyoutData.common)))}},sC=class extends Yy{async moduleFirstVisible(e){const t=await jy.fetchingAndCacheShoppingFeedModulesData(this.flyoutData,this.logModule,this.pageHandlerModule,e);t?.trendingOffers?.length>0?(this.component.navigateToTitleDestination=this.navigateToDestination.bind(this,this.GetTitleClickTelemetry()),this.component.titleText=this.flyoutData.strings.trendingOffersTitle,this.component.shoppingEntities=this.transformShoppingEntities(t.trendingOffers,e)):this.component.style.display="none"}GetStartShoppingModuleName(){return r.ModuleNames.TRENDING_OFFERS}GetModulePriority(){return r.H7.TRENDING_OFFERS}GetTitleClickTelemetry(){return{buttonName:i.$S.TrendingOffersTitle,engagement:q.FV.FEED_TRENDING_OFFERS,engagementMojom:q.ZF.FEED_TRENDING_OFFERS}}GetCardClickTelemetry(){return{buttonName:i.$S.TrendingOffersCard,engagement:q.FV.FEED_TRENDING_OFFERS,engagementMojom:q.ZF.FEED_TRENDING_OFFERS}}GetShowMoreClickTelemtry(){return{buttonName:i.$S.TrendingOffersShowMore,action:K.bS.FEED_TRENDING_OFFERS_SHOW_MORE,actionMojom:K.R9.FEED_TRENDING_OFFERS_SHOW_MORE}}GetEnabledMarkets(){return Iy.dV}GetModuleViewed(){return bp.r.FEED_TRENDING_OFFERS}GetModuleViewedMojom(){return bp.L.FEED_TRENDING_OFFERS}},lC=class extends sC{featureTogglesAreActive(){return!!this.flyoutData.dataStoreModule.ApiData?.retailerData&&"true"!==(0,h.Mw)("isPDP")&&!e.R.isExperimentActive(f.H.singleScrollingShoreline)}GetModulePaneTab(){return r.$k.CONTEXTUAL}GetStartShoppingModuleName(){return r.ModuleNames.TRENDING_OFFERS_ON_CONTEXTUAL_TAB}GetModulePriority(){return r.H7.TRENDING_OFFERS_ON_CONTEXTUAL_TAB}GetCardClickTelemetry(){return{buttonName:i.$S.TrendingOffersOnContextualTabCard,engagement:q.FV.FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB,engagementMojom:q.ZF.FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB}}GetShowMoreClickTelemtry(){return{buttonName:i.$S.TrendingOffersOnContextualTabShowMore,action:K.bS.FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB_SHOW_MORE,actionMojom:K.R9.FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB_SHOW_MORE}}GetModuleViewed(){return bp.r.FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB}GetModuleViewedMojom(){return bp.L.FEED_TRENDING_OFFERS_ON_CONTEXTUAL_TAB}};class cC{static async searchWithImageUrl(e,t,i,n,o,r){return r?await this.searchWithUAPI(e,t,i,n,o):await this.searchWithKAPI(e,t,i,n,o)}static async searchWithUAPI(e,t,n,o,r){if(this.responseCache.has(e))return this.responseCache.get(e);const a=n.common.extractedEntity,s=a?.entity?.page_locale?a?.entity?.page_locale:t,l=cC.buildUAPIVisualSearchUrl(s);let c=n.common.currentUrl;c?.startsWith(this.httpsPrefix)&&(c=c.substring(this.httpsPrefix.length));const d={clientContext:{appname:"Edge",enabledfeatures:[{name:"msShoppingUapiExp39",params:[{key:"KAPI",value:"prod"}]}],formCode:r},item:{attributes:{price:a?.entity?.["offers/price"],priceCurrency:a?.entity?.price_currency,priceValue:a?.entity?.price_value},images:[{contenturl:e}],seller:{domain:n.common.domain},title:a?.title,url:c},sourceTypes:["comparableOffers"]},u=JSON.stringify(d);this.logCall(o);try{const t=await fetch(l,{method:"POST",body:u,headers:{"Content-type":"application/json; charset=utf-8"}}),n=await t.json(),r=this.getUAPIAdData(n);return r&&r.value&&0!==r.value.length?(this.responseCache.set(e,r),r):void this.logError(o,"Visual search return no results",l,u,i.xu.StartShoppingAPIVisualSearchNoResultsFound)}catch(e){return void this.logError(o,"Visual search failed",l,u,i.xu.StartShoppingAPIVisualSearchError,e)}}static async searchWithKAPI(e,t,n,o,r){const a=cC.buildKAPIVisualSearchUrl(t,r),s="boundary_ABC123DEF456",l="--"+s,c="--"+s+"--",d="\r\n",u={imageInfo:{url:e},knowledgeRequest:{subscriptionId:"Edge.Shopping.SideBar",invokedSkills:["ProductAds","ImageById","BestRepresentativeQuery"]},sourceContext:{pagetitle:n.common.extractedEntity?.title??void 0,imagealt:n.common.extractedEntity?.entity?.name??void 0,pageurl:n.common.currentUrl??void 0}};let h=l+d;h+='Content-Disposition: form-data; name="knowledgeRequest"\r\n\r\n',h+=JSON.stringify(u)+d+d,h+=c+d,this.logCall(o);try{const e=await fetch(a,{method:"POST",body:h,headers:{"Content-type":"multipart/form-data; boundary="+s}}),t=await e.json(),n=this.getKAPIAdData(t);return n&&n.value&&0!==n.value.length?n:void this.logError(o,"Visual search return no results",a,h,i.xu.StartShoppingAPIVisualSearchNoResultsFound)}catch(e){return void this.logError(o,"Visual search failed",a,h,i.xu.StartShoppingAPIVisualSearchError,e)}}static getUAPIAdData(e){if(e?.comparableOffers)return e.comparableOffers}static getKAPIAdData(e){if(e.tags)for(const t of e.tags){if(!t.actions)return;for(const e of t.actions)if("Ads"===e.actionType)return e.data}}static logCall(e){e.LogInfoEvent(i.R.EdgeFlyoutStatus,"",new t.Z(i.xu.StartShoppingAPIVisualSearchCalled),Jl.g.EdgeImpressionId)}static logError(e,n,o,r,a,s){const l=this.createErrorMessage(n,o,r,s);e.LogErrorEvent(i.R.EdgeFlyoutStatus,l,new t.Z(a),Jl.g.EdgeImpressionId)}static createErrorMessage(e,t,i,n){return JSON.stringify({message:n?`${e} | ${n}`:e,url:t,requestBody:i})}static buildKAPIVisualSearchUrl(e,t){return`https://www.bingapis.com/api/v7/images/visualsearch?appid=BF14F5620588840DEDADA74919C08698BF706967&mkt=${e}&FORM=${t}`}static buildUAPIVisualSearchUrl(e){return`https://www.bing.com/api/shopping/v1/item/search?appid=${this.AppId}&mkt=${e}`}}(0,s.Z)(cC,"responseCache",new Map),(0,s.Z)(cC,"AppId","45EBD043982A03A4CA6B8962005A06F2B1FED569"),(0,s.Z)(cC,"httpsPrefix","https://");var dC=class extends Yy{async moduleFirstVisible(t){const i=this.flyoutData.common.extractedEntity?.image_url||this.flyoutData.common.extractedEntity?.entity?.image;if(!i)return void(this.component.style.display="none");e.R.isVariantActive(f.H.startShoppingVisualSearch,"Treatment")&&(this.component.useMasonryGrid=!0),this.pageHandlerModule.TriggerExperiment(f.H.startShoppingVisualSearch);const n=e.R.isVariantActive(f.H.startShoppingVisualSearch,"UAPI"),o=await cC.searchWithImageUrl(i,t,this.flyoutData,this.logModule,this.getFormCode(),n),r=function(e){const t=[];if(e?.value?.length>0)for(const i of e.value)if((i?.position?.startsWith("VisuallySimilarPrefix")||"Ads/ProductAd"===i._type)&&i.offer){const e=i.offer.lowPrice||i.offer.price,n=i.offer.lowPrice?i.offer.price:void 0,o=n?Math.ceil((n-e)/n*100):void 0;t.push({dealPercentage:o?`${o}%`:void 0,title:i.offer.itemOffered?.name,seller:i.offer.seller?.name,priceInfo:{price:e.toFixed(2),originalPrice:n?.toFixed(2),priceCurrencySymbol:i.offer.priceCurrencySymbol},imageInfo:{sourceImageUrl:i.offer.itemOffered?.image?.contentUrl},adType:"VisuallySimilar",destination:i.offer.url,impressionToken:i.impressionToken})}return t}(o);r.length>0?(r.forEach(((e,t)=>{e.tabOrder=t})),this.component.includeAdSlug=!0,this.component.visibilityFeedbackUrl=o.visibilityFeedbackUrl,this.component.titleText=this.flyoutData.strings.visualSearchModuleTitle,this.component.shoppingEntities=this.transformShoppingEntities(r,t),this.component.sendAdVisibilityFeedback=xl.bind(null,o.visibilityFeedbackUrl),xl(o.visibilityFeedbackUrl,r.slice(0,this.DefaultNumberOfProductsToShow()).map((e=>e.impressionToken)))):this.component.style.display="none"}getFormCode(){return e.R.isVariantActive(f.H.startShoppingVisualSearch,"UAPI")?zy.EdgeSidePane3:e.R.isVariantActive(f.H.startShoppingVisualSearch,"Control")?zy.EdgeSidePane2:zy.VisualSearch}GetModulePaneTab(){return r.$k.CONTEXTUAL}GetStartShoppingModuleName(){return r.ModuleNames.VISUAL_SEARCH}GetModulePriority(){return r.H7.VISUAL_SEARCH}GetCardClickTelemetry(){return{buttonName:i.$S.VisualSearchCard,engagement:q.FV.FEED_VISUAL_SEARCH,engagementMojom:q.ZF.FEED_VISUAL_SEARCH}}GetShowMoreClickTelemtry(){return{buttonName:i.$S.VisualSearchShowMore,action:K.bS.FEED_VISUAL_SEARCH_SHOW_MORE,actionMojom:K.R9.FEED_VISUAL_SEARCH_SHOW_MORE}}GetEnabledMarkets(){return Iy.Uo}featureTogglesAreActive(){return super.featureTogglesAreActive()&&(!!this.flyoutData.common.extractedEntity?.image_url||!!this.flyoutData.common.extractedEntity?.entity?.image)&&e.R.isExperimentActive(f.H.startShoppingVisualSearch)&&!e.R.isExperimentActive(f.H.similarOffers)}GetModuleViewed(){return bp.r.FEED_VISUAL_SEARCH}GetModuleViewedMojom(){return bp.L.FEED_VISUAL_SEARCH}DefaultNumberOfProductsToShow(){return 6}},uC=o(39711);class hC{constructor(e,t){(0,s.Z)(this,"authToken",void 0),(0,s.Z)(this,"emails",void 0),this.emails=e,this.authToken=t}}class pC{constructor(e,t,i){(0,s.Z)(this,"id",void 0),(0,s.Z)(this,"emailProvider",void 0),(0,s.Z)(this,"active",void 0),this.id=e,this.emailProvider=t,this.active=i}}var gC=o(21650);let fC=function(e){return e.InboxCoupons="InboxCoupons",e.ActiveRetailerInboxCoupons="ActiveRetailerInboxCoupons",e}({}),mC=((vC={})[vC.InboxCoupons=r.ModuleNames.INBOX_COUPONS]="InboxCoupons",vC[vC.ActiveRetailerInboxCoupons=r.ModuleNames.ACTIVE_RETAILER_INBOX_COUPONS]="ActiveRetailerInboxCoupons",function(e){return e.InboxCoupons="inboxCouponSection",e.ActiveRetailerInboxCoupons="activeRetailerInboxCouponsSection",e}({}));var vC;const yC=async function(e){if(!e)return"";const t=(new TextEncoder).encode(e),i=await crypto.subtle.digest("SHA-256",t),n=Array.from(new Uint8Array(i)).map((e=>e.toString(16).padStart(2,"0"))).join("");return n};function CC(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function bC(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?CC(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):CC(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}class SC{constructor(){(0,s.Z)(this,"pageHandlerModuleInstance",void 0),(0,s.Z)(this,"logModuleInstance",void 0),(0,s.Z)(this,"flyoutDataInstance",void 0),(0,s.Z)(this,"telemetryUtilitiesInstance",void 0),(0,s.Z)(this,"getAuthInfoInstance",void 0),(0,s.Z)(this,"getModuleInfoHandlers",{}),(0,s.Z)(this,"environment",void 0);try{this.environment="production"}catch{this.environment="unknown"}}static get Instance(){return this.instance||(this.instance=new this)}set pageHandlerModule(e){this.pageHandlerModuleInstance=e}set logModule(e){this.logModuleInstance=e}set telemetryUtilities(e){this.telemetryUtilitiesInstance=e}set flyoutData(e){this.flyoutDataInstance=e}set getAuthInfo(e){this.getAuthInfoInstance=e}addModuleInfoHandler(e,t){this.getModuleInfoHandlers=bC(bC({},this.getModuleInfoHandlers),{},{[e]:t})}async sendActionTelemetry(e,t=!0){await this.trySendTelemetry((async()=>{this.pageHandlerModuleInstance.RecordAsUserAction(e)}),`Action:${e}`,t)}async sendEngagementTelemetry(e,t,i=!0){await this.trySendTelemetry((async()=>{this.pageHandlerModuleInstance.RecordAsUserEngagement(e,t)}),`Engagement:${e}`,i)}async logButtonClickTelemetry(e,t,n,o,a=!0,s){await this.trySendTelemetry((async()=>{const a=new W.Z(t,this.telemetryUtilitiesInstance.setContentViewed(s??r.ModuleNames.INBOX_COUPONS),void 0,JSON.stringify(bC(bC({},n??{}),await this.getCommonMetaData(e,s))));this.logModuleInstance.LogInfoEvent(i.R.ButtonClick,`${t} has been clicked.`+(o?` ${o}`:""),a),await new Promise((e=>{const t=setTimeout((()=>{e(),clearTimeout(t)}),100)}))}),`${i.R.ButtonClick}:${t}`,a)}async logClientErrorTelemetry(e,n,o,r=!0){await this.trySendTelemetry((async()=>{const r=new t.Z(e,void 0,void 0,void 0,JSON.stringify(bC(bC({},o??{}),await this.getCommonMetaData())));this.logModuleInstance.LogErrorEvent(i.R.EdgeFlyoutStatus,`[InboxCoupons][ERROR][${n.name}]: ${n.message}`,r)}),`${i.R.ClientError}: ${n.name}`,r)}async logClientInfoTelemetry(e,n,o,r=!0){await this.trySendTelemetry((async()=>{const r=new t.Z(e,void 0,void 0,void 0,JSON.stringify(bC(bC({},o??{}),await this.getCommonMetaData())));this.logModuleInstance.LogInfoEvent(i.R.EdgeFlyoutStatus,`[InboxCoupons][INFO]: ${n}`,r)}),`${i.R.EdgeFlyoutStatus}: ${n}`,r)}async getCommonMetaData(e,t){const i=this.getAuthInfoInstance?await this.getAuthInfoInstance():{},n=t??(e&&await(async e=>{for(const t of Object.keys(fC)){const i=document.getElementById(mC[t]);if(i?.contains(e))return t}})(e)),o=n&&this.getModuleInfoHandlers[n]?await this.getModuleInfoHandlers[n]():{},r=(await this.pageHandlerModuleInstance.GetEdgeAnid(!0)).anid;return bC({userIdentifier:r&&await yC(`anid:${r}`),email:i.email&&await yC(i.email),module:o.moduleName,shoppingTab:o.shoppingTab,route:o.route},this.getEnvMetadata())}getEnvMetadata(){const e=this.flyoutDataInstance.common.userCountryCode,t=this.flyoutDataInstance.common.browseMode,i=this.flyoutDataInstance.common.channel;return{environment:this.environment,language:$C.getBrowserLanguage(),userCountryCode:e,browseMode:t,channel:i}}async trySendTelemetry(e,t,n=!0){try{await e()}catch(e){n&&(e.message=`[InboxCoupons][ERROR] Error in recording a telemetry${t}\n${e.message}`,await this.logClientErrorTelemetry(i.xu.ErrorToRecordTelemetry,e,void 0,!1))}}}(0,s.Z)(SC,"instance",void 0);const xC=SC.Instance;let TC=function(e){return e.V1="v1",e.V2="v2",e.Unknown="vUnknown",e}({});class wC{static isRecentCoupon(e){return(Date.now()-e.messageReciptionDate.getTime())/864e5<=OC}static getRetailerSubtitleText(e,t){const n=e.length,o=e.filter(wC.isRecentCoupon).length;return o>0?1===o?(0,T.dK)(t.strings.recentCoupons,i.T4.One):(0,T.dK)(t.strings.recentCoupons,i.T4.Other,o):n>0?1===n?(0,T.dK)(t.strings.couponsCount,i.T4.One):(0,T.dK)(t.strings.couponsCount,i.T4.Other,n):t.strings.noCouponsFound}static getRetailerAriaLabelText(e,t,i){const n=t.length,o=t.filter(wC.isRecentCoupon).length;return o>0?1===o?(0,T.fZ)("retailerSentYouOneRecentCoupon",i.strings.retailerSentYouOneRecentCoupon,e):(0,T.fZ)("retailerSentYouNRecentCoupons",i.strings.retailerSentYouNRecentCoupons,e,`${o}`):n>0?1===n?(0,T.fZ)("retailerSentYouOneCoupon",i.strings.retailerSentYouOneCoupon,e):(0,T.fZ)("retailerSentYouNCoupons",i.strings.retailerSentYouNCoupons,e,`${n}`):(0,T.fZ)("retailerSentYouZeroCoupon",i.strings.retailerSentYouZeroCoupon,e)}constructor(e,t,i,n){(0,s.Z)(this,"couponCode",void 0),(0,s.Z)(this,"senderDomain",void 0),(0,s.Z)(this,"messageReciptionDate",void 0),(0,s.Z)(this,"new",void 0),this.couponCode=e,this.messageReciptionDate=new Date(t.toString()),this.senderDomain=i,this.new=n}}const OC=14;var PC=wC;class AC{constructor(e){(0,s.Z)(this,"errorCode",void 0),(0,s.Z)(this,"retailerId",void 0),(0,s.Z)(this,"retailerName",void 0),(0,s.Z)(this,"coupons",void 0),this.errorCode=e?.errorCode??"Failed",this.retailerId=e?.retailerId??"",this.retailerName=e?.retailerName??"",this.coupons=e?.coupons?.map((e=>new PC(e.couponCode,e.messageReciptionDate,e.senderDomain,e.new)))??[],this.filterOlderCoupons()}filterOlderCoupons(){this.coupons=this.coupons.filter(PC.isRecentCoupon)}}var EC=function(e){return e.OK="OK",e.NotSupportedDomain="NotSupportedDomain",e.Failed="Failed",e}(EC||{});class kC{constructor(){}static get Instance(){return this.instance||(this.instance=new this)}async getAllCoupons(e,t){try{if(!e)throw new Error("Empty userId!");const i=await fetch(new URL("allUserCoupons",kC.INBOX_COUPONS_SERVICE_BASE_URL).href,{method:"POST",headers:this.getCommonRequestHeaders(t,e)});if(200!==i.status)throw new Error(`Request failed with status code ${i.status}`);const n=await i.json();return new class{constructor(e){(0,s.Z)(this,"retailers",void 0),(0,s.Z)(this,"disabledRetailers",void 0),this.retailers=e?.retailers?.map((e=>new class{constructor(e,t,i){(0,s.Z)(this,"retailerId",void 0),(0,s.Z)(this,"retailerName",void 0),(0,s.Z)(this,"coupons",void 0),this.retailerId=e,this.retailerName=t,this.coupons=i.map((e=>new PC(e.couponCode,e.messageReciptionDate,e.senderDomain,e.new)))}}(e.retailerId,e.retailerName,e.coupons)))??[],this.disabledRetailers=e?.disabledRetailers?.map((e=>new class{constructor(e,t,i){(0,s.Z)(this,"id",void 0),(0,s.Z)(this,"name",void 0),(0,s.Z)(this,"senderDomains",void 0),this.id=e,this.name=t,this.senderDomains=i}getDisabledRetailerSendersKeys(e){return this.senderDomains||(this.senderDomains=e),this.senderDomains.map((e=>((e,t)=>`${e}|${t}`)(this.id,e)))}}(e.id,e.name,e.senderDomains)))??[]}}(n?.inboxCoupons)}catch(e){return e.message=`[InboxCoupons][AllCouponsAPICall] ${e.message}, can't retreive your coupons and we will show the cached coupons`,null}}async getUserEmailsStatus(e,t){try{if(!e)throw new Error("Empty userId!");const i=await fetch(new URL("emails/status",kC.INBOX_COUPONS_SERVICE_BASE_URL).href,{method:"GET",headers:this.getCommonRequestHeaders(t,e)});if(404===i.status)return{};if(200!==i.status)throw new Error(`Request failed with status code ${i.status}`);return await i.json()}catch(e){return e.message=`[InboxCoupons][UserEmailsStatusAPICall] ${e.message}, can't retreive your emails status`,{error:e}}}async deleteEmail(e,t,i){if(!e||!t)return!1;let n;try{return n=await fetch(new URL(`emailId/${t}`,kC.INBOX_COUPONS_SERVICE_BASE_URL).href,{method:"POST",headers:this.getCommonRequestHeaders(i,e)}),200===n.status}catch(e){return!1}}async getDomainCoupons(e,t,i){if(!e||!t)return null;const n={domain:t};let o;try{if(o=await fetch(new URL("coupons",kC.INBOX_COUPONS_SERVICE_BASE_URL).href,{method:"POST",headers:this.getCommonRequestHeaders(i,e),body:JSON.stringify(n)}),200!==o.status)return null;const t=await o.json(),r=new AC(t);return r.errorCode===EC.OK?r:null}catch(e){return null}}async updateUserDisabledRetailer(e,t,i,n,o){if(!(e&&t&&i&&n))return!1;const r={retailerId:t,senderEmails:i,status:n,deleteCoupons:!1};let a;try{return a=await fetch(new URL("users",kC.INBOX_COUPONS_SERVICE_BASE_URL).href,{method:"POST",headers:this.getCommonRequestHeaders(o,e),body:JSON.stringify(r)}),200===a.status}catch(e){return!1}}getCommonRequestHeaders(e,t){const i=new Headers;return i.append("Authorization",`Bearer ${e}`),i.append("userid",t),i.append("Content-Type","application/json"),i}}(0,s.Z)(kC,"instance",void 0),(0,s.Z)(kC,"INBOX_COUPONS_SERVICE_BASE_URL","https://www.bing.com/api/shopping/v1/savings/inboxcoupons/");const IC=kC.Instance;let DC=function(e){return e.Coupons="coupons",e}({});const _C=(0,ch.createContext)({commonAssets:{},flyoutData:{},inboxCouponsAssets:{},notificationText:"",pageHandlerModule:{},updateNotificationText:()=>{},utilities:{},logModule:{},stateManagement:{},isDarkMode:!1,moduleName:r.ModuleNames.INBOX_COUPONS}),NC=e=>{const{commonAssets:t,flyoutData:i,inboxCouponsAssets:n,pageHandlerModule:o,logModule:a,stateManagement:s,utilities:l,telemetryUtilities:c,moduleName:d}=e;(0,ch.useEffect)((()=>{xC.pageHandlerModule=o}),[o]),(0,ch.useEffect)((()=>{xC.logModule=a}),[a]),(0,ch.useEffect)((()=>{xC.flyoutData=i}),[i]),(0,ch.useEffect)((()=>{xC.telemetryUtilities=c}),[c]);const u=(0,ch.useMemo)((()=>i.common.currentTheme===r.Q2.Dark),[i]),[h,p]=(0,ch.useState)(""),g=(0,ch.useCallback)((e=>p(e)),[]);return ch.createElement(_C.Provider,{value:{commonAssets:t,flyoutData:i,inboxCouponsAssets:n,notificationText:h,pageHandlerModule:o,stateManagement:s,logModule:a,updateNotificationText:g,utilities:l,isDarkMode:u,moduleName:d}},e.children)};let RC=function(e){return e.Microsoft="Microsoft",e.Gmail="Gmail",e}({}),MC=function(e){return e.AuthenticationError="AuthenticationError",e.AuthorizationError="AuthorizationError",e.InvalidRequest="InvalidRequest",e.UnexpectedError="UnexpectedError",e.ReconnectingDifferentEmail="ReconnectingDifferentEmail",e.EmailConnectedToDifferentUser="EmailConnectedToDifferentUser",e.EmailBlocked="EmailBlocked",e}({});const LC=(0,ch.createContext)({edgeSignIn:void 0,anid:null,areAllEmailsActive:!0,authorizationError:null,clearAuthorizationError:void 0,deleteEmail:void 0,getEmailProvider:void 0,googleLogin:void 0,isActiveEmail:void 0,isDisconnectedEmail:void 0,isAuthorizationLoading:!0,isAuthorized:!1,isEdgeSignedInUser:!1,microsoftLogin:void 0,userData:null,userEmails:void 0,isConnectingEmail:!1,refreshUserEmails:void 0}),BC=({children:e})=>{const{flyoutData:t,pageHandlerModule:n,stateManagement:o,moduleName:a}=(0,ch.useContext)(_C),[s,l]=(0,ch.useState)(null),[c,d]=(0,ch.useState)(void 0),[u,p]=(0,ch.useState)(!0),[g,f]=(0,ch.useState)(null),m=(0,ch.useRef)(void 0),v=(0,ch.useMemo)((()=>{if(!s)return c?new hC(c.map((e=>e.id)),""):null;const e=FC(s);return new hC(e,s)}),[s,c,FC]);(0,ch.useEffect)((()=>{xC.getAuthInfo=()=>({email:v?.emails[0]})}),[v]),(0,ch.useEffect)((()=>{s||0!==(c?.length??0)?n.SetStorageValue(Ce.Q.InboxCouponsUserConsented,at.Z.CreateFromString(tt.oL)):n.SetStorageValue(Ce.Q.InboxCouponsUserConsented,at.Z.CreateFromString(""))}),[s,c]);const[y,C]=(0,ch.useState)(null),b=(0,ch.useMemo)((()=>null!==v&&v.emails.length>0),[v]),S=(0,ch.useMemo)((()=>null!==y),[y]);(0,ch.useEffect)((()=>{(async()=>{if(n.IsMessageAllowed("getEdgeAnid")){const e=(await n.GetEdgeAnid(!0)).anid;C((e?.length??0)>0?e:null)}else C(null)})()}),[n]);const x=(0,ch.useCallback)((async()=>{const e=await n.GetStorageValue(`${Ce.Q.InboxCouponsUserEmailsStatusCache}`);try{return(e?.value?.stringValue?.length??0)>0?JSON.parse(e.value.stringValue):null}catch{return null}}),[n]);(0,ch.useEffect)((()=>{(async()=>{p(!0);const e=await n.GetStorageValue(`${Ce.Q.InboxCouponsAuthTokenKeyPrefix}${y}`);(e?.value?.stringValue?.length??0)>0&&l(e.value.stringValue),p(!1)})()}),[y,n]);const T=(0,ch.useCallback)((()=>f(null)),[f]),w=(0,ch.useMemo)((()=>{const e=[DC.Coupons],i={userId:`anid:${y}`,market:t.common.userCountryCode,enabledScenarios:e};return JSON.stringify(i)}),[y,t]),O=(0,ch.useCallback)((e=>`https://accounts.google.com/o/oauth2/v2/auth?${new URLSearchParams({access_type:"offline",client_id:"39807376480-r6c0iggtqrol4jvdlq3p7uvma7glapqc.apps.googleusercontent.com",include_granted_scopes:"true",prompt:"select_account consent",redirect_uri:t.common.googleAuthRedirectUrl,response_type:"code",scope:["https://www.googleapis.com/auth/gmail.readonly"].join(" "),state:w})}`),[w]),P=(0,ch.useCallback)((e=>`https://login.microsoftonline.com/consumers/oauth2/v2.0/authorize?${new URLSearchParams({access_type:"offline",client_id:"d68e28a3-f122-463a-a4e2-e8d3d6427aee",include_granted_scopes:"true",prompt:e?"consent":"select_account",redirect_uri:t.common.microsoftAuthRedirectUrl,response_type:"code",scope:["https://graph.microsoft.com/user.read","https://graph.microsoft.com/mail.read","offline_access"].join(" "),state:w})}`),[w]),A=(0,ch.useCallback)((async(e=!0)=>{if(y){if(n.ClearStorageValue(Ce.Q.InboxCouponsUserEmailsStatus),e){const e=await x();if(e&&e.expirationTime>(new Date).getTime())return void d(e.value.emails)}const t=await IC.getUserEmailsStatus(y,"");if(t.error)d(void 0);else{d((t?.emails??[]).filter((e=>e)).map((e=>new pC(e.id,e.emailProvider,e.active))));const e=JSON.stringify({value:t,expirationTime:(new Date).getTime()+144e5});n.SetStorageValue(Ce.Q.InboxCouponsUserEmailsStatusCache,at.Z.CreateFromString(e))}}else d(void 0)}),[y,x,n]);(0,ch.useEffect)((()=>{A()}),[A]);const E=(0,ch.useCallback)((async e=>{if(t.common.authAllowedOrigins.has(e.origin)){I(!1),_(null);const r=e.data,a=((await n.GetStorageValue(`${Ce.Q.InboxCouponsAuthTokenKeyPrefix}${y}`)).value?.stringValue?.length??0)>0;switch(n.SetStorageValue(Ce.Q.InboxCouponsUserEmailsStatusCache,at.Z.CreateFromString("")),r.status){case"success":if(n.SetStorageValue(`${Ce.Q.InboxCouponsAuthTokenKeyPrefix}${y}`,at.Z.CreateFromString(r.payload.jwt)),(0,h.Xo)(HC.InboxCouponsUserLoginDateInMs,`${(new Date).getTime()}`),await A(!1),l(r.payload.jwt),f(null),xC.logClientInfoTelemetry(i.xu.InboxCouponsEmailConnected,"Inbox coupons email connected",{isReconnect:a,emailProvider:m.current}),a)xC.sendActionTelemetry(K.bS.INBOX_COUPONS_RECONNECT_INBOX),xC.sendEngagementTelemetry(q.FV.INBOX_COUPONS_RECONNECT_INBOX,t.common.popupOrigination);else switch(m.current){case RC.Gmail:xC.sendActionTelemetry(K.bS.INBOX_COUPONS_CONNECT_GMAIL_INBOX),xC.sendEngagementTelemetry(q.FV.INBOX_COUPONS_CONNECT_GMAIL_INBOX,t.common.popupOrigination);break;case RC.Microsoft:xC.sendActionTelemetry(K.bS.INBOX_COUPONS_CONNECT_OUTLOOK_INBOX),xC.sendEngagementTelemetry(q.FV.INBOX_COUPONS_CONNECT_OUTLOOK_INBOX,t.common.popupOrigination)}o.dispatchEvent(new CustomEvent(Ku.e1.InboxCouponUserLoggedIn));break;case"error":f(r?.payload?.errorType??MC.UnexpectedError)}p(!1)}}),[y,t.common.authAllowedOrigins,n,A]);(0,ch.useEffect)((()=>{null!==g&&xC.logClientErrorTelemetry(i.xu.InboxCouponsEmailConnectError,new Error(g))}),[g]);const[k,I]=(0,ch.useState)(!1),[D,_]=(0,ch.useState)(null),N=(0,ch.useCallback)((e=>{window.removeEventListener("message",E);const t=window.open(e,"loginWindow","toolbar=no, menubar=no, width=600, height=700, top=100, left=100");t?.focus(),I(!0),_(t),window.addEventListener("message",E,!1)}),[E]);(0,ch.useEffect)((()=>{const e=setInterval((()=>{null===D||D.closed?(I(!1),clearInterval(e)):I(!0)}),500);return()=>clearInterval(e)}),[D]);const R=(0,ch.useCallback)((e=>{const t=O(e);m.current=RC.Gmail,N(t)}),[O,N]),M=(0,ch.useCallback)((e=>{const t=P(e);m.current=RC.Microsoft,N(t)}),[P,N]),L=(0,ch.useCallback)((async()=>{if(n.IsMessageAllowed("getEdgeAnid")){const e=(await n.GetEdgeAnid(!0)).anid,t=(e?.length??0)>0;return C(t?e:null),t}return!1}),[n]),{edgeSignIn:B}=((e,t,n,o,a)=>{const s=(0,ch.useMemo)((()=>void 0!==n?n.IsMessageAllowed("signInToEdgeProfile"):void 0),[n]),l=(0,ch.useMemo)((()=>void 0===s?TC.Unknown:s?TC.V2:TC.V1),[s]),c=(0,ch.useCallback)((()=>""!==o.dataLoader.GetLoadTimeDataValue("aadEmail","")),[o]),d=(0,ch.useCallback)(((e,i)=>{let n=1;const o=()=>setTimeout((async()=>{const r=await t();n++,r&&e(r),!r&&n<=4&&o(),n>4&&i?.()}),1e3);o()}),[t,o,l]),u=(0,ch.useCallback)((async()=>{n.ClearStorageValue(Ce.Q.InboxCouponsEdgeSignInStarted),n.ClearStorageValue(Ce.Q.InboxCouponsEdgeSignInSuccess)}),[n]),h=(0,ch.useCallback)((()=>{xC.logClientInfoTelemetry(i.xu.InboxCouponsEdgeSignInSuccess,"User successfully logged in to Edge through Inbox coupons",{edgeSignInVersion:l}),xC.sendActionTelemetry(K.bS.INBOX_COUPONS_SIGN_IN_EDGE),xC.sendEngagementTelemetry(q.FV.INBOX_COUPONS_SIGN_IN_EDGE)}),[l]),p=(0,ch.useCallback)((()=>{xC.logClientInfoTelemetry(i.xu.InboxCouponsEdgeSignInSuccessWorkProfile,"User successfully logged in to Edge with work profile through Inbox coupons",{edgeSignInVersion:l})}),[l]),g=(0,ch.useCallback)((()=>{xC.logClientInfoTelemetry(i.xu.InboxCouponsEdgeSignInNotCompleted,"User didn't complete logging in to Edge through Inbox coupons",{edgeSignInVersion:l})}),[l]),f=(0,ch.useCallback)((e=>{xC.logClientErrorTelemetry(i.xu.InboxCouponsEdgeSignInError,e,{edgeSignInVersion:l})}),[l]),m=(0,ch.useCallback)(((e,t)=>{if(e){if(!t)return g(),void u();if(c())return p(),void u();d((()=>{a.dispatchEvent(new CustomEvent(Ku.e1.InboxCouponsEdgeUserSuccsefullySignedIn)),u()}),(()=>{u()}))}}),[g,p,d,a,u,c]);(0,ch.useEffect)((()=>{(async()=>{if(l===TC.Unknown)return;if(e!==r.ModuleNames.INBOX_COUPONS)return;const[t,i]=await Promise.all([n.GetStorageValue(Ce.Q.InboxCouponsEdgeSignInSuccess),n.GetStorageValue(Ce.Q.InboxCouponsEdgeSignInStarted)]),[o,a]=[t?.value?.boolValue??!1,i?.value?.boolValue??!1];l===TC.V1&&m(a,o)})()}),[e,n,l,m]);const v=(0,ch.useCallback)((()=>{d((e=>{e&&l!==TC.V2&&h(),u()}))}),[d,h,u,l]),y=(0,ch.useCallback)((async e=>{try{n.SetStorageValue(Ce.Q.InboxCouponsEdgeSignInStarted,gC.Z.CreateFromBool(!0)),(await n.SignIntoMSA(!0)).msaSignedIn&&(n.SetStorageValue(Ce.Q.InboxCouponsEdgeSignInSuccess,gC.Z.CreateFromBool(!0)),e?.(),v())}catch(e){f(e)}}),[n,v,o,l,f]),C=(0,ch.useCallback)((async e=>{try{n.SetStorageValue(Ce.Q.InboxCouponsEdgeSignInStarted,gC.Z.CreateFromBool(!0));const t=await n.SignInToEdgeProfile(!0),i=JSON.parse(t.result);i.canceled?g():i.error?f(new Error(i.error)):i.accountType&&("AAD"===i.accountType?(p(),a.dispatchEvent(new CustomEvent(Ku.e1.InboxCouponsEdgeUserWorkProfileSuccsefullySignedIn))):(h(),a.dispatchEvent(new CustomEvent(Ku.e1.InboxCouponsEdgeUserSuccsefullySignedIn))),e?.(),v())}catch(e){f(e)}}),[n,v,o,g,l,f,a]);return{edgeSignIn:(0,ch.useCallback)((async e=>(l===TC.V2?C(e):y(e),l)),[l,y,C])}})(a,L,n,t,o),F=(0,ch.useCallback)((()=>{l(null),d(void 0),n.SetStorageValue(`${Ce.Q.InboxCouponsAuthTokenKeyPrefix}${y}`,at.Z.CreateFromString("")),n.SetStorageValue(Ce.Q.InboxCouponsUserEmailsStatusCache,at.Z.CreateFromString("")),(0,h.TJ)(HC.InboxCouponsUserLoginDateInMs)}),[y,l,n]),U=(0,ch.useCallback)((e=>{if(void 0===c)return!1;const t=c?.filter((t=>t.id===e));return 0===t.length}),[c]),H=(0,ch.useCallback)((e=>{if(void 0===c)return!0;const t=c?.filter((t=>t.id===e));return 0===t.length&&F(),t[0]?.active??!1}),[c,F]),[$,Z]=(0,ch.useState)(!0);(0,ch.useEffect)((()=>{(async()=>{const e=v?.emails?.map((e=>H(e)))??[],t=(await Promise.all(e)).reduce(((e,t)=>e&&t),!0);Z(t)})()}),[v?.emails,H]);const V=(0,ch.useCallback)((async e=>{const n=await IC.deleteEmail(y||"",e,s||"");return n&&(xC.logClientInfoTelemetry(i.xu.InboxCouponsEmailDisconnected,"Email disconnected"),xC.sendActionTelemetry(K.bS.INBOX_COUPONS_DISCONNECT_INBOX),xC.sendEngagementTelemetry(q.FV.INBOX_COUPONS_DISCONNECT_INBOX,t.common.popupOrigination),F(),o.dispatchEvent(new CustomEvent(Ku.e1.InboxCouponUserDisconnected))),Promise.resolve(n)}),[s,y,F]),G=(0,ch.useCallback)((e=>{const t=c?.filter((t=>t.id===e))[0]?.emailProvider??void 0;if(void 0!==t&&t in RC)return RC[t]}),[c]),j=(0,ch.useCallback)((()=>{F()}),[F]);(0,ch.useEffect)((()=>(o.removeEventListener(Ku.e1.InboxCouponUserDisconnected,j),o.addEventListener(Ku.e1.InboxCouponUserDisconnected,j),()=>{o.removeEventListener(Ku.e1.InboxCouponUserDisconnected,j)})),[j]);const z=(0,ch.useCallback)((async()=>{if(y){const e=await n.GetStorageValue(`${Ce.Q.InboxCouponsAuthTokenKeyPrefix}${y}`);l((e?.value?.stringValue?.length??0)>0?e.value.stringValue:null)}}),[y,n]);return(0,ch.useEffect)((()=>(o.removeEventListener(Ku.e1.InboxCouponUserLoggedIn,z),o.addEventListener(Ku.e1.InboxCouponUserLoggedIn,z),()=>{o.removeEventListener(Ku.e1.InboxCouponUserLoggedIn,z)})),[z]),ch.createElement(LC.Provider,{value:{edgeSignIn:B,anid:y,areAllEmailsActive:$,authorizationError:g,clearAuthorizationError:T,deleteEmail:V,getEmailProvider:G,googleLogin:R,isActiveEmail:H,isDisconnectedEmail:U,isAuthorizationLoading:u,isAuthorized:b,isConnectingEmail:k,isEdgeSignedInUser:S,microsoftLogin:M,userData:v,userEmails:c,refreshUserEmails:A}},e)},FC=e=>{try{return JSON.parse(window.atob(e.split(".")[1])).emails??[]}catch{return[]}};class UC{static generateImgSrcFromSVGComponent(e){return`data:image/svg+xml;base64,${window.btoa(e)}`}static getEmailProviderFriendlyName(e,t){switch(e){case RC.Microsoft:return t.emailProviderMicrosoft;case RC.Gmail:return t.emailProviderGmail;default:return""}}static getBrowserLanguage(){return navigator.language?.split("-")?.[0]?.toLowerCase()??"Unknown"}static initStorageValues(e,t){this.SetHashedAnidStorageValue(e),this.SetPaneOpenStorageValue(e,t),this.SetInboxCouponsLogsMetadata(e,t)}static async SetHashedAnidStorageValue(e){let t="";e.IsMessageAllowed("getEdgeAnid")&&(t=(await e.GetEdgeAnid(!0)).anid);const i=await yC(`anid:${t}`);e.SetStorageValue(Ce.Q.InboxCouponsHashedUserId,at.Z.CreateFromString(`${i}`))}static SetPaneOpenStorageValue(e,t){const i=t.common.isPane;e.SetStorageValue(Ce.Q.InboxCouponsPaneOpen,at.Z.CreateFromString(`${i}`))}static SetInboxCouponsLogsMetadata(e,t){xC.flyoutData=t;const i=xC.getEnvMetadata();e.SetStorageValue(Ce.Q.InboxCouponsLogsMetadata,at.Z.CreateFromString(JSON.stringify(i)))}}(0,s.Z)(UC,"InboxCouponsVNextFlag","inboxCouponsVNext");let HC=function(e){return e.InboxCouponsUserLoginDateInMs="InboxCouponsUserLoginDateInMs",e}({});var $C=UC;let ZC=function(e){return e[e.JSXElement=0]="JSXElement",e[e.SVGString=1]="SVGString",e[e.ImgSrcString=2]="ImgSrcString",e}({});var VC=class{constructor(e){(0,s.Z)(this,"RootModuleWrapperHtmlId","inboxCouponSection"),(0,s.Z)(this,"resourcesEndpoint",void 0),this.resourcesEndpoint=e}getStyles(){return`\n html {\n --inbox-coupon-hyperlink-color: #036AC4;\n --inbox-coupon-card-background: #FFFFFF;\n --inbox-coupon-card-title-color: #1A1A1A;\n --inbox-coupon-card-description-color: #7A7A7A;\n --inbox-coupon-card-footer-border-color: rgba(0, 0, 0, 0.04);\n --inbox-coupon-selected-color: #036AC4;\n --inbox-coupon-selected-border-color: #036AC433;\n --inbox-coupon-new-badge-color: #C42B1C;\n --inbox-coupon-new-badge-background-color: #F6F5F5;\n --inbox-coupons-danger-color: #C42B1C;\n --inbox-coupons-one-dot-background-color: #D7180C;\n --inbox-coupons-one-dot-outline-color: transparent;\n --inbox-coupon-progress-bar-track: #E0E0E0;\n --inbox-coupon-button-border-color: #EFEFEF;\n --inbox-coupon-error-message-background-color: #F3F3F3;\n --inbox-coupons-scrollbar-color: #D5D5D5;\n --inbox-coupons-button-background-color: #FBFBFB;\n --inbox-coupons-button-border-color: #D6D6D6;\n --inbox-coupons-card-border-color: #00000014;\n --inbox-coupons-email-provider-container-background: #F3F4F6;\n --inbox-coupons-spinner-border-gradient-colors: rgb(0, 120, 212) rgb(199, 224, 244) rgb(199, 224, 244);\n --inbox-coupons-button-text-color: #1A1A1A;\n --inbox-coupons-unchecked-toggle-button-background-color: rgb(243, 243, 243);\n --inbox-coupons-checked-toggle-button-background-color: rgb(0, 120, 212);\n --inbox-coupons-unchecked-toggle-button-border-color: rgb(117, 117, 117);\n --inbox-coupons-checked-toggle-button-border-color: transparent;\n --inbox-coupons-hovered-unchecked-toggle-button-background-color: rgb(243, 243, 243);\n --inbox-coupons-hovered-unchecked-toggle-button-border-color: rgb(117, 117, 117);\n --inbox-coupons-hovered-checked-toggle-button-border-color: rgb(50, 49, 48);\n --inbox-coupons-hovered-checked-toggle-button-background-color: rgb(0, 90, 158);\n --inbox-coupons-disabled-unchecked-toggle-button-background-color: rgb(243, 243, 243);\n --inbox-coupons-disabled-unchecked-toggle-button-border-color: rgb(200, 198, 196);\n --inbox-coupons-disabled-checked-toggle-button-background-color: rgb(200, 198, 196);\n --inbox-coupons-disabled-checked-toggle-button-border-color: transparent;\n --inbox-coupons-unchecked-toggle-indicator-background-color: rgb(117, 117, 117);\n --inbox-coupons-hovered-unchecked-toggle-indicator-background-color: rgb(32, 31, 30);\n --inbox-coupons-checked-toggle-indicator-background-color: rgb(243, 243, 243);\n --inbox-coupons-hovered-checked-toggle-indicator-background-color: rgb(243, 243, 243);\n --inbox-coupons-disabled-unchecked-toggle-indicator-background-color: rgb(200, 198, 196);\n --inbox-coupons-disabled-checked-toggle-indicator-background-color: rgb(243, 242, 241);\n --inbox-coupons-card-settings-button-background-color: rgb(231, 231, 231);\n --inbox-coupons-card-settings-button-hover-background-color: rgba(231, 231, 231, 0.5);\n }\n #${this.RootModuleWrapperHtmlId} * {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n }\n `}getDarkModeStyles(){return"\n html {\n --inbox-coupon-hyperlink-color: #66CDFC;\n --inbox-coupon-card-background: #424242;\n --inbox-coupon-card-title-color: #FFFFFF;\n --inbox-coupon-card-description-color: #E0E0E0;\n --inbox-coupon-card-footer-border-color: #515151;\n --inbox-coupon-selected-color: #40B3D0;\n --inbox-coupon-selected-border-color: #40B3D033;\n --inbox-coupon-new-badge-color: #ED8E85;\n --inbox-coupon-new-badge-background-color: #333333;\n --inbox-coupons-danger-color: #ED8E85;\n --inbox-coupons-one-dot-background-color: #FAA69E;\n --inbox-coupons-one-dot-outline-color: #4A4A4A;\n --inbox-coupon-progress-bar-track: #595959;\n --inbox-coupon-button-border-color: #5A5A5A;\n --inbox-coupon-error-message-background-color: #333333;\n --inbox-coupons-scrollbar-color: #717171;\n --inbox-coupons-button-background-color: #424242;\n --inbox-coupons-button-border-color: #6C6C6C;\n --inbox-coupons-card-border-color: #00000014;\n --inbox-coupons-email-provider-container-background: #4C4C4C;\n --inbox-coupons-spinner-border-gradient-colors: rgb(65, 207, 242) rgb(199, 224, 244) rgb(199, 224, 244);\n --inbox-coupons-button-text-color: #FFFFFF;\n --inbox-coupons-unchecked-toggle-button-background-color: rgb(59, 59, 59);\n --inbox-coupons-checked-toggle-button-background-color: rgb(65, 207, 242);\n --inbox-coupons-unchecked-toggle-button-border-color: rgb(167, 167, 167);\n --inbox-coupons-checked-toggle-button-border-color: transparent;\n --inbox-coupons-hovered-unchecked-toggle-button-background-color: rgb(59, 59, 59);\n --inbox-coupons-hovered-unchecked-toggle-button-border-color: rgb(255, 255, 255);\n --inbox-coupons-hovered-checked-toggle-button-border-color: transparent;\n --inbox-coupons-hovered-checked-toggle-button-background-color: rgb(0, 90, 158);\n --inbox-coupons-disabled-unchecked-toggle-button-background-color: rgb(59, 59, 59);\n --inbox-coupons-disabled-unchecked-toggle-button-border-color: rgb(40, 39, 38);\n --inbox-coupons-disabled-checked-toggle-button-background-color: rgb(40, 39, 38);\n --inbox-coupons-disabled-checked-toggle-button-border-color: transparent;\n --inbox-coupons-unchecked-toggle-indicator-background-color: rgb(167, 167, 167);\n --inbox-coupons-hovered-unchecked-toggle-indicator-background-color: rgb(244, 244, 244);\n --inbox-coupons-checked-toggle-indicator-background-color: rgb(59, 59, 59);\n --inbox-coupons-hovered-checked-toggle-indicator-background-color: rgb(59, 59, 59);\n --inbox-coupons-disabled-unchecked-toggle-indicator-background-color: rgb(40, 39, 38);\n --inbox-coupons-disabled-checked-toggle-indicator-background-color: rgb(49, 48, 47);\n --inbox-coupons-card-settings-button-background-color: rgba(69, 69, 69, 0.7);\n --inbox-coupons-card-settings-button-hover-background-color: rgb(69, 69, 69);\n }\n "}getIcon(e,t={},i=ZC.ImgSrcString){if(e)try{if("string"==typeof e){if(i===ZC.ImgSrcString)return`${this.resourcesEndpoint}${e}`}else if("object"==typeof e){if(i===ZC.ImgSrcString)return`${this.resourcesEndpoint}${t.dark&&e.dark?e.dark:e.light}`}else{const n=ch.createElement(e,t);if(i===ZC.JSXElement)return n;if(i===ZC.SVGString)return uC.renderToStaticMarkup(n);if(i===ZC.ImgSrcString)return $C.generateImgSrcFromSVGComponent(uC.renderToStaticMarkup(n))}}catch(e){}return null}getRetailerLogoUrl(e){return`${this.resourcesEndpoint}inboxCoupons/retailers/${e}.png`}scrollInboxCouponsModuleIntoView(e=!1){const t=document.getElementById(this.RootModuleWrapperHtmlId);if(t?.scrollIntoView({behavior:"smooth"}),e){const e=t?.querySelectorAll('button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])'),i=e?.[0];i?.focus()}}},GC=class extends VC{constructor(...e){super(...e),(0,s.Z)(this,"RootModuleWrapperHtmlId","activeRetailerInboxCouponsSection")}getStyles(){return`\n #${this.RootModuleWrapperHtmlId} * {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n }\n `}};let jC=function(e){return e.Upsell="upsell",e.ActiveRetailer="active-retailer",e}({});const zC=(0,ch.createContext)({activeRetailerInboxCoupons:null,activeRetailerLoading:!0,activeRoute:null,updateActiveRoute:e=>{},navigateToInboxCouponsModule:()=>{}}),WC=({children:e})=>{const{flyoutData:t,stateManagement:i,utilities:n}=(0,ch.useContext)(_C),{anid:o,isAuthorized:a,userData:s}=(0,ch.useContext)(LC),l=(0,ch.useCallback)((()=>{n.switchShoppingTab(r.d$.Home)}),[document]),[c,d]=(0,ch.useState)(!0),[u,h]=(0,ch.useState)(null),[p,g]=(0,ch.useState)(null),f=(0,ch.useCallback)((e=>g(e)),[g]),m=(0,ch.useCallback)((()=>{(async()=>{if(a&&o){const e=await IC.getDomainCoupons(o,t.common.domain,s?.authToken??"");e&&e.errorCode===EC.OK?h(e):h(null),d(!1)}})()}),[o,a,t.common.domain,s]);(0,ch.useEffect)((()=>{m()}),[m]);const v=(0,ch.useCallback)((()=>{h(null)}),[]);(0,ch.useEffect)((()=>(i.removeEventListener(Ku.e1.InboxCouponUserDisconnected,v),i.addEventListener(Ku.e1.InboxCouponUserDisconnected,v),()=>{i.removeEventListener(Ku.e1.InboxCouponUserDisconnected,v)})),[v]);const y=(0,ch.useCallback)((()=>{m()}),[m]);return(0,ch.useEffect)((()=>(i.removeEventListener(Ku.e1.InboxCouponUserLoggedIn,y),i.addEventListener(Ku.e1.InboxCouponUserLoggedIn,y),()=>{i.removeEventListener(Ku.e1.InboxCouponUserLoggedIn,y)})),[y]),ch.createElement(zC.Provider,{value:{activeRetailerInboxCoupons:u,activeRetailerLoading:c,activeRoute:p,updateActiveRoute:f,navigateToInboxCouponsModule:l}},e)};function KC(){return KC=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},KC.apply(this,arguments)}const qC=e=>ch.createElement("svg",KC({width:"8",height:"11",viewBox:"0 0 8 11",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),ch.createElement("path",{d:"M0.7514 1.31352L0.75 2.375V7.6271C0.75 8.52455 1.47754 9.2521 2.375 9.2521L6.68315 9.25225C6.52865 9.6891 6.112 10.0021 5.6222 10.0021H2.375C1.06333 10.0021 0 8.9388 0 7.6271V2.375C0 1.88464 0.313725 1.46756 0.7514 1.31352ZM6.875 0C7.4963 0 8 0.50368 8 1.125V7.625C8 8.2463 7.4963 8.75 6.875 8.75H2.375C1.75368 8.75 1.25 8.2463 1.25 7.625V1.125C1.25 0.50368 1.75368 0 2.375 0H6.875ZM6.875 0.75H2.375C2.1679 0.75 2 0.917895 2 1.125V7.625C2 7.8321 2.1679 8 2.375 8H6.875C7.0821 8 7.25 7.8321 7.25 7.625V1.125C7.25 0.917895 7.0821 0.75 6.875 0.75Z"})),YC=e=>{const{couponCode:t,isNew:i,handleCopyCode:n,focused:o,onFocus:r,onBlur:a}=e,{flyoutData:s,inboxCouponsAssets:l,isDarkMode:c,updateNotificationText:d}=(0,ch.useContext)(_C),[u,h]=(0,ch.useState)(!1),[p,g]=(0,ch.useState)(!1),f=(0,ch.useCallback)((()=>{h(!0),r?.()}),[r]),m=(0,ch.useCallback)((()=>{h(!1),g(!1),a?.()}),[a]),v=(0,ch.useCallback)((e=>{n(t,e),d((0,T.fZ)("copiedInboxCoupon",s.strings.copiedInboxCoupon,t)),g(!0)}),[t,n]),y=(0,ch.useRef)(null);return(0,ch.useEffect)((()=>{o?y.current?.focus():y.current?.blur()}),[o]),ch.createElement(XC,{onMouseEnter:f,onFocus:f,onMouseLeave:m,onBlur:m,onClick:v,tabIndex:0,title:`${t} - ${i?s.strings.newInboxCouponFound:s.strings.inboxCouponDescription}`,ref:y},u&&ch.createElement(JC,{"aria-hidden":!0},p?s.strings.couponCopied.toLocaleUpperCase():s.strings.couponCopyLabelRefresh.toLocaleUpperCase()),ch.createElement(QC,{"aria-label":p?(0,T.fZ)("copiedInboxCoupon",s.strings.copiedInboxCoupon,t):(0,T.fZ)("copyInboxCoupon",s.strings.copyInboxCoupon,t)},t),l.getIcon(qC,{style:{fill:"var(--inbox-coupon-selected-color)",minWidth:"8px"},dark:c},ZC.JSXElement))},XC=bm.button`
position: relative;
border: 1px dashed var(--inbox-coupon-selected-border-color);
padding: 3px 5px;
font-size: 12px;
font-weight: 700;
margin: 0;
border-radius: 3px;
background: transparent;
font-family: inherit;
min-width: 50px;
max-width: 200px;
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
display: flex;
align-items: center;
gap: 5px;
justify-content: space-between;
`,JC=bm.div`
position: absolute;
cursor: pointer;
left: 0;
top: 0;
width: 100%;
height: 100%;
display: flex;
justify-content: center;
align-items: center;
--overlay-opacity: 0.9;
background: linear-gradient(to bottom, var(--neutral-fill-rest) calc((var(--overlay-opacity) - 1) * 10000%), transparent calc(var(--overlay-opacity) * 10000%));
color: var(--neutral-foreground-rest);
`,QC=bm.span`
color: var(--inbox-coupon-selected-color);
font-size: 12px;
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
`;const eb=["horizontal","horizontalAlign","verticalAlign","tokens","styles","children"],tb=e=>{const{horizontal:t,horizontalAlign:i,verticalAlign:n,tokens:o,styles:r,children:a}=e,s=function(e,t){if(null==e)return{};var i,n,o=function(e,t){if(null==e)return{};var i,n,o={},r=Object.keys(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||(o[i]=e[i]);return o}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(n=0;n<r.length;n++)i=r[n],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(o[i]=e[i])}return o}(e,eb);return ch.createElement(ib,KC({flexDirection:t?"row":"column",justifyContent:i,alignItems:n,padding:o?.padding,childrenGap:o?.childrenGap,styles:r?.root??{}},s),a)},ib=bm.div`
display: flex;
flex: 1 1 0;
flex-direction: ${e=>e.flexDirection};
justify-content: ${e=>e.justifyContent??"normal"};
align-items: ${e=>e.alignItems??"normal"};
padding: ${e=>e.padding??"0"};
> :not(:first-child) {
${e=>"column"===e.flexDirection||"column-reverse"===e.flexDirection?`margin-block-start: ${e.childrenGap??0}px`:""};
${e=>"column"!==e.flexDirection&&"column-reverse"!==e.flexDirection?`margin-inline-start: ${e.childrenGap??0}px`:""};
}
${({styles:e})=>e}
`,nb=e=>ch.createElement("svg",KC({viewBox:"0 0 2048 2048",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),ch.createElement("path",{d:"M1939 467l90 90-1005 1005L19 557l90-90 915 915 915-915z"})),ob=bm.a`
color: var(--inbox-coupon-hyperlink-color);
cursor: pointer;
text-decoration: underline;
`,rb=bm.button`
background: none;
border: none;
padding: 0;
color: var(--inbox-coupon-hyperlink-color);
cursor: pointer;
text-decoration: underline;
`,ab=bm.button`
display: flex;
justify-content: center;
align-items: center;
cursor: pointer;
border: calc(var(--stroke-width) * 1px) solid transparent;
border-radius: 8px;
margin-top: 8px !important;
padding: 8px;
font-family: inherit;
font-size: 14px;
color: var(--neutral-foreground-rest);
background: padding-box linear-gradient(var(--neutral-fill-rest), var(--neutral-fill-rest)), border-box var(--neutral-stroke-control-rest);
transition: box-shadow 500ms;
&:hover {
box-shadow: 0px 3px 6px rgba(0, 0, 0, 0.12);
}
`,sb=e=>{const{onClick:t,title:i,text:n,isDarkMode:o,className:r,inboxCouponsAssets:a}=e;return ch.createElement(ab,{onClick:t,title:i,className:r},n,a.getIcon(nb,{dark:o,style:{fill:"var(--neutral-foreground-rest)",margin:"2px 10px 0 10px",width:"10px",stroke:"var(--neutral-foreground-rest)",strokeWidth:"150"}},ZC.JSXElement))},lb=bm(sb)`
width: 100%;
margin: 0 !important;
padding: 12px 8px;
background-color: transparent;
color: var(--neutral-foreground-hint);
border: none;
background: none;
&:hover {
box-shadow: none;
}
`,cb=e=>{const{text:t,ariaLabel:i}=e;return ch.createElement(db,{"aria-label":i},ch.createElement(ub,null,t))},db=bm.div`
color: var(--inbox-coupon-new-badge-color);
background-color: var(--inbox-coupon-new-badge-background-color);
padding: 2px 4px;
box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.08);
border-radius: 2px;
width: 29px;
height: 14px;
display: flex;
justify-content: center;
align-items: center;
`,ub=bm.span`
height: 10px;
font-size: 10px;
line-height: 10px;
font-weight: 600;
`,hb=(bm.div`
font-weight: 600;
font-size: 14px;
line-height: 20px;
color: var(--neutral-foreground-hint);
`,e=>{const{coupon:t,handleCopyCode:i,focused:n,onBlur:o,onFocus:r}=e,{flyoutData:a}=(0,ch.useContext)(_C);return ch.createElement(pb,null,ch.createElement(tb,{horizontal:!0,tokens:{childrenGap:16},verticalAlign:"center"},ch.createElement(YC,{couponCode:t.couponCode,isNew:t.new,handleCopyCode:i,focused:n,onFocus:r,onBlur:o}),t.new&&ch.createElement(cb,{text:a.strings.newCoupon,ariaLabel:a.strings.newInboxCouponFound})),ch.createElement(gb,null,(0,T.fZ)("retailerSentYouThisCoupon",a.strings.retailerSentYouThisCoupon,t.senderDomain)))}),pb=bm(tb)``,gb=bm.p`
color: var(--neutral-foreground-hint);
margin: 0;
padding-top: 6px;
font-size: 12px;
line-height: 16px;
font-weight: 400;
`,fb={light:"common/infoIcon.svg",dark:"common/infoIcon.svg"},mb=bm.h2`
margin-top: 9px;
margin-bottom: 12px;
font-size: 18px;
line-height: 24px;
font-weight: 600;
color: var(--neutral-foreground-rest);
`,vb=bm.a`
display: flex;
margin-top: 1px;
`;var yb=e=>{const{heading:t,leftActions:n,rightActions:o,body:r,infoIcon:a}=e,{inboxCouponsAssets:s,isDarkMode:l}=(0,ch.useContext)(_C);return ch.createElement(tb,{tokens:{padding:"0px 20px 20px 20px"}},t||n||o?ch.createElement(tb,{horizontal:!0,horizontalAlign:o?"space-between":"start",verticalAlign:"center"},t||n?ch.createElement(ch.Fragment,null,ch.createElement(tb,{horizontal:!0,verticalAlign:"center",tokens:{childrenGap:9}},n??ch.createElement(ch.Fragment,null),ch.createElement(tb,{horizontal:!0,verticalAlign:"center",tokens:{childrenGap:6}},ch.createElement(mb,null,t),a&&ch.createElement(vb,{href:a.url,title:a.title,target:"_blank",onClick:async e=>{await xC.logButtonClickTelemetry(e.target,i.$S.InboxCouponsLearnMoreInfo,a.metadata)}},ch.createElement("img",{src:s.getIcon(fb,{dark:l})})))),o??ch.createElement(ch.Fragment,null)):ch.createElement(ch.Fragment,null)):ch.createElement(ch.Fragment,null),r)};const Cb=e=>ch.createElement("svg",KC({width:"40",height:"40",viewBox:"0 0 40 40",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),ch.createElement("rect",{width:"40",height:"40",rx:"4",fill:"#F5F5F5"}),ch.createElement("path",{d:"M24 17.5C24 18.3284 23.3284 19 22.5 19C21.6716 19 21 18.3284 21 17.5C21 16.6716 21.6716 16 22.5 16C23.3284 16 24 16.6716 24 17.5ZM23 17.5C23 17.2239 22.7761 17 22.5 17C22.2239 17 22 17.2239 22 17.5C22 17.7761 22.2239 18 22.5 18C22.7761 18 23 17.7761 23 17.5ZM13 16C13 14.3431 14.3431 13 16 13H24C25.6569 13 27 14.3431 27 16V24C27 25.6569 25.6569 27 24 27H16C14.3431 27 13 25.6569 13 24V16ZM16 14C14.8954 14 14 14.8954 14 16V24C14 24.3726 14.1019 24.7215 14.2794 25.0201L18.9487 20.432C19.5323 19.8586 20.4677 19.8586 21.0513 20.432L25.7206 25.0201C25.8981 24.7215 26 24.3726 26 24V16C26 14.8954 25.1046 14 24 14H16ZM16 26H24C24.3692 26 24.7149 25.9 25.0118 25.7256L20.3504 21.1453C20.1559 20.9542 19.8441 20.9542 19.6496 21.1453L14.9882 25.7256C15.2851 25.9 15.6308 26 16 26Z",fill:"#1A1A1A"})),bb=e=>ch.createElement("svg",KC({width:"12",height:"7",viewBox:"0 0 12 7",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),ch.createElement("path",{d:"M5.99998 2.05058L10.3914 6.44194C10.6354 6.68602 11.0312 6.68602 11.2753 6.44194C11.5193 6.19787 11.5193 5.80214 11.2753 5.55806L11.2753 5.55806L6.4419 0.724747C6.19782 0.480665 5.80214 0.480665 5.55806 0.724747L0.724726 5.55806C0.480641 5.80213 0.480641 6.19787 0.724726 6.44194C0.968807 6.68602 1.36448 6.68602 1.60857 6.44194L5.99998 2.05058Z","stroke-width":"0.25"}));function Sb(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function xb(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Sb(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Sb(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}const Tb=e=>{const{ariaLabel:t,title:i,titleTooltip:n,subtitle:o,collapsable:r,imageUrl:a,imageAlt:s,fallbackImageUrl:l,expanded:c,styles:d,onClick:u}=e,{isDarkMode:h,inboxCouponsAssets:p}=(0,ch.useContext)(_C);return ch.createElement(tb,{horizontal:!0,verticalAlign:"center",style:d?.root,"aria-label":t,onClick:u},(!!a||!!l)&&ch.createElement(wb,{style:d?.logoContainer,"aria-hidden":!0},ch.createElement(Ob,{src:a,onError:({currentTarget:e})=>{e.onerror=null,e.src=l??""},alt:s,style:d?.logo})),ch.createElement(tb,{horizontal:!0,horizontalAlign:"space-between",verticalAlign:"center",styles:{root:{flex:1}}},ch.createElement(Pb,{style:d?.details},ch.createElement(Ab,{style:d?.title,title:n??""},i),ch.createElement(Eb,{style:d?.subtitle},o)),r&&ch.createElement(kb,null,p.getIcon(bb,{dark:h,style:xb({fill:"var(--neutral-foreground-rest)",stroke:"var(--neutral-foreground-rest)",transition:"all 0.3s ease-in-out"},xb(c?{}:{transform:"rotate(180deg)"},d?.chevronIcon??{}))},ZC.JSXElement))))},wb=bm.div`
display: flex;
padding: 2px 0;
`,Ob=bm.img`
width: 40px;
height: 100%;
min-height: 40px;
border-radius: 3px;
`,Pb=bm(tb)`
flex: 1;
overflow: hidden;
`,Ab=bm.h4`
color: var(--neutral-foreground-rest);
margin: 0;
flex: 1;
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
font-size: 14px;
line-height: 20px;
font-weight: 600;
`,Eb=bm.p`
margin: 0;
color: var(--neutral-foreground-hint);
max-width: 85%;
font-size: 12px;
line-height: 16px;
font-weight: 400;
`,kb=bm.div`
width: 9px;
display: flex;
margin-inline-end: 8px;
`;function Ib(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Db(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Ib(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Ib(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}const _b=e=>{const{ariaLabel:t,retailer:i,subtitle:n,activeRetailerId:o,styles:r}=e,{flyoutData:a,inboxCouponsAssets:s,isDarkMode:l}=(0,ch.useContext)(_C);return ch.createElement(Tb,{ariaLabel:t,titleTooltip:t,collapsable:!0,expanded:o===i.id,fallbackImageUrl:s.getIcon(Cb,{dark:l}),imageAlt:(0,T.fZ)("commonAriaLogo",a.strings.commonAriaLogo,i.name),imageUrl:s.getRetailerLogoUrl(i.id),subtitle:n,title:i.name,styles:Db(Db({},r?.headerStyles??{}),Nb)})},Nb={logoContainer:{marginInlineEnd:"20px"}};var Rb=function(e){return e.Home="home",e.Login="login",e.Coupons="inbox-coupons",e.Settings="settings",e.NoCoupons="no-coupons",e.FindingOffers="finding-offers",e.RefreshingInboxCoupons="refreshing-inbox-coupons",e.AccessRevoked="access-revoked",e.ConnectingDifferentEmail="connecting-different-email",e}(Rb||{});const Mb=(0,ch.createContext)({activeRetailer:null,activeRoute:Rb.Home,activeSettingsEmailAddress:"",activeSettingsRetailer:null,disabledRetailerSenders:new Set,getOrderedRetailers:()=>[],handleUserDisconnection:()=>{},isInboxCouponsInitialized:!1,isInboxCouponsLoading:!1,isRetailerSendersSettingsLoading:new Set,retailersCoupons:[],showAllRetailers:!1,toggleRetailerSenderPrivacySetting:(e,t,i)=>{},updateActiveRetailer:(e,t)=>{},updateActiveRoute:e=>{},updateActiveSettingsEmailAddress:e=>{},updateActiveSettingsRetailer:(e,t)=>{},updateShowAllRetailers:e=>{},loadInboxCoupons:e=>{},calculateFirstRunExperiencePercentage:()=>0,isFRECompleted:!1,isLoginCardExpanded:!1,setIsLoginCardExpanded:e=>{},focusedCouponKey:"",setFocusedCouponKey:e=>{}}),Lb=e=>{const{onRenderSummary:t,onRenderContent:i,expanded:n,animationDuration:o,animationEasing:r,isAlwaysExpanded:a,onClick:s,onExpansionEnd:l,summaryAriaLabel:c,styles:d}=e,u=o??200,h=r??"ease-in-out",[p,g]=(0,ch.useState)(!1),[f,m]=(0,ch.useState)(!1),v=(0,ch.useRef)({}),y=(0,ch.useRef)({}),C=(0,ch.useRef)({}),[b,S]=(0,ch.useState)(null),x=(0,ch.useCallback)((e=>{v.current&&(v.current.open=e,S(null),m(!1),g(!1),v.current.style.height=v.current.style.overflow="")}),[v]),T=(0,ch.useCallback)((()=>{v.current&&(v.current.style.height=`${v.current.offsetHeight}px`,v.current.open=!0,requestAnimationFrame((()=>{g(!0);const e=`${y.current.offsetHeight}px`,t=`${Ub(y.current)+Ub(C.current)}px`;b&&b.cancel();let i=new Animation;i=v.current.animate({height:[e,t]},{duration:u,easing:h}),i.onfinish=()=>{x(!0),l?.(v.current)},i.oncancel=()=>g(!1),S(i)})))}),[v,y,C,b,u,h]),w=(0,ch.useCallback)((()=>{if(!v.current)return;m(!0);const e=`${Ub(v.current)}px`,t=`${Ub(y.current)}px`;b&&b.cancel();let i=new Animation;i=v.current.animate({height:[e,t]},{duration:u,easing:h}),i.onfinish=()=>x(!1),i.oncancel=()=>m(!1)}),[v,y,C,b,u,h,x]),O=(0,ch.useCallback)((e=>{a||(f||!v.current.open?T():(p||v.current.open)&&w(),s?.(e))}),[T,w,s,f,p,v]);(0,ch.useEffect)((()=>{n&&T()}),[]);const P=(0,ch.useMemo)((()=>a||n||p||f),[a,n,p,f]);return ch.createElement(Bb,{open:P,ref:v,onClick:e=>e.preventDefault(),"aria-expanded":n,style:d?.details},ch.createElement(Fb,{ref:y,onClick:O,role:"button","aria-label":c,style:d?.summary},t()),ch.createElement("div",{ref:C,onClick:e=>e.preventDefault(),style:{border:"1px solid transparent"}},i()))},Bb=bm.details`
&:not(:last-child) {
border-bottom: 1px solid var(--neutral-fill-rest);
}
overflow: hidden;
transition: all ease-in-out 200ms;
padding: 0px 16px;
`,Fb=bm.summary`
cursor: pointer;
&::-webkit-details-marker {
display:none;
}
list-style: none;
&:focus-visible {
outline: calc(var(--stroke-width) * 1px) auto var(--focus-stroke-outer);
box-shadow: 0 0 0 calc((var(--focus-stroke-width) - var(--stroke-width)) * 1px) var(--focus-stroke-outer);
}
`,Ub=e=>{const t=getComputedStyle(e);return e.scrollHeight-parseFloat(t.paddingTop)-parseFloat(t.paddingBottom)};bm.div`
display: flex;
align-items: center;
flex-direction: column;
width: 100%;
`,bm.button`
cursor: pointer;
transition: all 0.2s ease-in-out;
display: flex;
justify-content: center;
align-items: center;
font-size: 14px;
font-weight: 600;
line-height: 20px;
padding: 8px 0;
color: var(--neutral-foreground-rest);
border-radius: 0;
position: relative;
background-color: ${e=>e.checked?"var(--neutral-fill-hover)":"transparent"};
border: none;
width: 100%;
${({styles:e})=>e}
&:hover {
background-color: var(--neutral-fill-hover);
${({hoverStyles:e})=>e}
}
${e=>e.isDisabled?"\n\t pointer-events: none;\n cursor: not-allowed;\n background-color: transparent;\n opacity: 0.5;\n ":""})
`,bm.img`
width: 20px;
height: 20px;
margin-inline-end: 12px;
`,bm.div`
color: var(--inbox-coupons-button-text-color);
font-size: 14px;
line-height: 20px;
`;const Hb=Cm`
from {
transform: translateX(-25%);
opacity: 0;
}
to {
transform: translateX(0%);
opacity: 1;
}
`,$b=(bm.div`
animation: ${Hb} ${e=>e.slideAnimationdurationInSeconds}s ease-in-out;
`,Cm`
from {
transform: translateX(25%);
opacity: 0;
}
to {
transform: translateX(0%);
opacity: 1;
}
`);bm.div`
animation: ${$b} ${e=>e.slideAnimationdurationInSeconds}s ease-in-out;
`;const Zb=bm.div`
background-color: var(--inbox-coupon-card-background);
border: ${e=>e.hasOuterBorders?"1px solid var(--inbox-coupons-card-border-color)":"none"};
border-radius: 8px;
position: relative;
overflow-y: hidden;
max-height: ${e=>e.maxHeightInPx}px;
scrollbar-gutter: "auto";
padding: ${e=>e.padding?`${e.padding}px`:"0"};
-webkit-text-size-adjust: 100%;
-ms-text-size-adjust: 100%;
-ms-overflow-style: scrollbar;
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
&::-webkit-scrollbar {
width: 8px;
height: 12px;
}
&::-webkit-scrollbar-thumb {
border-radius: 8px;
border: solid 2px var(--inbox-coupon-card-background);
background: var(--inbox-coupons-scrollbar-color);
min-height: 40px;
}
::-webkit-scrollbar-track {
background: transparent;
}
`;function Vb(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Gb(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Vb(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Vb(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}bm(tb)`
display: flex;
justify-content: center;
align-items: center;
flex-direction: column;
text-align: center;
padding: 10px 20px;
color: var(--neutral-foreground-rest);
`,bm.div`
line-height: 0;
`,bm.div`
display: flex;
justify-content: center;
align-items: center;
width: 100px;
height: 100px;
background-color: var(--neutral-fill-rest);
border-radius: 50%;
line-height: 0;
`,bm.img`
width: 150px;
`,bm.img`
height: 50%;
`,bm.div`
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
margin: 0 auto;
width: 100%;
`,bm.h3`
color: var(--inbox-coupon-card-title-color);
margin: 0;
font-size: 16px;
font-weight: 600;
line-height: 24px;
`,bm.div`
color: var(--inbox-coupon-card-description-color);
margin: 8px 0 0 0;
font-size: 12px;
line-height: 16px;
width: 100%;
`,bm.div`
padding: 12px 16px 16px 16px;
border-top: 1px solid var(--neutral-fill-rest);
font-size: var(--type-ramp-minus-1-font-size);
color: var(--neutral-foreground-hint);
`,bm.div`
width: 100%;
text-align: center;
flex-grow: 1;
display: flex;
align-items: center;
justify-content: center;
`;const jb=e=>{const{groups:t,handleRenderRetailerHeader:n,handleRenderItem:o,handleRenderItemContentSeeMore:r,handleFilterRetailerItem:a,expandedGroupKey:s,showAll:l,useItemFilter:c,maxHeightInPx:d,isAlwaysExpanded:u,onSeeMoreClick:h,onSummaryClick:p,header:g,footer:f,wrapInNonStyledCard:m,styles:v}=e,[y,C]=(0,ch.useState)(!!l),[b,S]=(0,ch.useState)(!c),{setFocusedCouponKey:x}=(0,ch.useContext)(Mb),{flyoutData:w,isDarkMode:O,inboxCouponsAssets:P}=(0,ch.useContext)(_C),A=(0,ch.useRef)(null),E=(0,ch.useCallback)((async e=>{await(h?.(e)),C(!0),A.current?.focus()}),[C,h,A.current]),k=(0,ch.useCallback)((e=>{A.current?.scrollTo({top:e.offsetTop-parseFloat(window.getComputedStyle(A.current)?.["padding-top"]??"0"),behavior:"smooth"})}),[A.current]),I=(0,ch.useMemo)((()=>y?[...t]:[...t.slice(0,3)]),[y,t]),D=(0,ch.useCallback)((e=>{let t=e.items,l=ch.createElement(ch.Fragment,null);if(!b){t=t.filter((e=>a?.(e)??!0)),0===t.length&&(t=e.items);const n=Math.min(t.length,5);if(n<e.items.length){const o=t.length>5;l=ch.createElement(Kb,null,r?.(e.items.length-n,e.items.length,(async t=>{await xC.logButtonClickTelemetry(t.target,o?i.$S.InboxCouponsSeeMoreCoupons:i.$S.InboxCouponsSeeOlderCoupons,{retailerName:e.name,retailerId:e.id}),S(!0),x((e=>{const t=e.split("-");return t.length>0?(t[t.length-1]=`${parseInt(t[t.length-1],10)+1}`,t.join("-")):""}))}),o))}t=t.slice(0,5)}return ch.createElement(Lb,{summaryAriaLabel:e.ariaLabel,expanded:e.key===s,onRenderSummary:()=>n(e),onRenderContent:()=>ch.createElement(ch.Fragment,null,t.length>0&&ch.createElement(tb,{tokens:{padding:"0 0 10px 0"},styles:v?.itemsListWrapper},ch.createElement(zb,{style:v?.itemsList},t.map(((t,i)=>ch.createElement(Wb,{style:v?.item},o(t,i,e)))),l))),isAlwaysExpanded:u,onClick:t=>{p?.(e,t),S(!c)},onExpansionEnd:k,styles:v?.accordionItem})}),[b,a,r,S,n,o,p,k]);return ch.createElement(ch.Fragment,null,ch.createElement(Zb,{hasOuterBorders:!m,maxHeightInPx:d??315,ref:A,style:Gb(Gb({},v?.root??{}),{"overflow-y":"overlay"})},g,I.map((e=>D(e))),f),!y&&t.length>3&&ch.createElement(sb,{inboxCouponsAssets:P,onClick:E,text:(0,T.fZ)("sectionSeeMore",w.strings.sectionSeeMore,""+(t.length-3)),title:(0,T.fZ)("retailersTitleWithNum",w.strings.retailersTitleWithNum,`${t.length}`),isDarkMode:O}))},zb=bm.ul`
display: initial;
padding: 0 10px;
margin: 0;
-webkit-text-size-adjust: 100%;
-ms-text-size-adjust: 100%;
-ms-overflow-style: scrollbar;
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
border: 1px solid var(--inbox-coupons-card-border-color);
border-radius: 6px;
&::-webkit-scrollbar {
width: 8px;
height: 12px;
}
&::-webkit-scrollbar-thumb {
border-radius: 8px;
border: solid 2px var(--inbox-coupon-card-background);
background: var(--inbox-coupons-scrollbar-color);
min-height: 40px;
}
::-webkit-scrollbar-track {
background: transparent;
}
& > li:not(:first-child) {
border-top: 1px solid #00000008;
}
`,Wb=bm.li`
padding: 0;
margin: 0;
list-style: none;
&:not(:first-child) {
border-top: 1px solid var(--neutral-fill-rest);
}
`,Kb=bm.li`
border-top: 1px solid var(--neutral-fill-rest);
margin: 0;
list-style: none;
`;function qb(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Yb(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?qb(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):qb(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}const Xb=()=>{const{activeRetailerInboxCoupons:e,activeRetailerLoading:t,navigateToInboxCouponsModule:n}=(0,ch.useContext)(zC),{flyoutData:o,pageHandlerModule:a,inboxCouponsAssets:s}=(0,ch.useContext)(_C),{focusedCouponKey:l,setFocusedCouponKey:c}=(0,ch.useContext)(Mb);(0,ch.useEffect)((()=>{t||e&&0===e.coupons.length&&xC.logClientInfoTelemetry(i.xu.InboxCouponsNoCouponsFoundOnRetailerSite,`No Coupons found for ${e.retailerName}`,{retailerName:e.retailerName,retailerId:e.retailerId})}),[t,e]);const{retailersCoupons:d}=(0,ch.useContext)(Mb),u=(0,ch.useMemo)((()=>{const t=e?.coupons?.map((t=>Yb(Yb({},t),{},{key:`${e?.retailerId??""}|${t.couponCode}`,name:`${e?.retailerName??""}|${t.couponCode}`})))??[];return[{key:e?.retailerName??"",id:e?.retailerId??"",name:e?.retailerName??"",ariaLabel:e?.retailerName??"",items:t}]}),[e]),h=(0,ch.useCallback)((t=>{if(!e)return ch.createElement(ch.Fragment,null);const i=PC.getRetailerSubtitleText(t.items,o),n=PC.getRetailerAriaLabelText(t.name,t.items,o);return ch.createElement(_b,{ariaLabel:n,retailer:{ariaLabel:t.ariaLabel,items:t.items,key:t.key,id:t.id,name:t.name},subtitle:i,activeRetailerId:e?.retailerId??"",styles:{headerStyles:{root:{cursor:"default",padding:"12px 0"},chevronIcon:{display:"none"},title:{fontSize:"14px",lineHeight:"20px",fontWeight:"600"},subtitle:{fontSize:"14px",lineHeight:"20px",fontWeight:"600"}}}})}),[e,o.strings.couponsCount,o.strings.inboxRetailerHasCoupons,T.fZ,T.dK]),p=(0,ch.useCallback)((async(t,n)=>{await xC.logButtonClickTelemetry(n.target,i.$S.InboxCouponsCouponClip,{couponCode:t,retailerName:e?.retailerName,retailerId:e?.retailerId}),a.CopyCoupon(t),xC.sendActionTelemetry(K.bS.INBOX_COUPONS_COPY_COUPON),xC.sendEngagementTelemetry(q.FV.INBOX_COUPONS_COPY_COUPON,o.common.popupOrigination)}),[a.CopyCoupon,e]),g=(0,ch.useCallback)(((e,t,i)=>{const n=`${i.key}-${t}`;return ch.createElement(hb,{coupon:e,handleCopyCode:p,key:n,focused:n===l,onFocus:()=>c(n)})}),[o.strings.couponCopyLabelRefresh,o.strings.couponCopied,a.CopyCoupon,l]),f=(0,ch.useCallback)((async e=>{await xC.logButtonClickTelemetry(e.target,i.$S.InboxCouponsSeeOtherRetailers),n(),s.scrollInboxCouponsModuleIntoView()}),[n,s.scrollInboxCouponsModuleIntoView]),m=(0,ch.useCallback)(((e,t,n,a)=>ch.createElement(lb,{inboxCouponsAssets:s,onClick:n,text:(0,T.fZ)(a?"sectionSeeMoreCoupons":"sectionSeeOlderCoupons",a?o.strings.sectionSeeMoreCoupons:o.strings.sectionSeeOlderCoupons,`${e}`),title:1!==t?(0,T.dK)(o.strings.couponsCount,i.T4.Other,t):(0,T.dK)(o.strings.couponsCount,i.T4.One),isDarkMode:o.common.currentTheme===r.Q2.Dark})),[]),v=(0,ch.useCallback)((e=>PC.isRecentCoupon(e)),[]);return ch.createElement(ch.Fragment,null,e&&e.coupons.length>0&&ch.createElement(yb,{heading:"",body:ch.createElement(tb,null,ch.createElement(jb,{groups:u,expandedGroupKey:u?.[0]?.key??"",handleRenderRetailerHeader:h,handleRenderItem:g,handleRenderItemContentSeeMore:m,useItemFilter:!0,handleFilterRetailerItem:v,isAlwaysExpanded:!0,maxHeightInPx:350,styles:{itemsList:{overflowY:"auto",maxHeight:"250px",scrollbarGutter:"stable both-edges"},item:{padding:"12px 0"},accordionItem:{details:{padding:"0 16px"}}},wrapInNonStyledCard:!0}),0===(e?.coupons?.length??0)&&(d?.length??0)>0&&ch.createElement(Jb,{onClick:f},(0,T.fZ)("seeOtherRetailers",o.strings.seeOtherRetailers,`${d.length}`)))}))},Jb=bm(rb)`
color: var(--neutral-foreground-rest);
margin-top: 10px !important;
font-size: 12px;
text-align: left;
width: fit-content;
`,Qb={light:"inboxCoupons/common/Light/Inbox_Generic_Small_60X60_3X.png?02072023",dark:"inboxCoupons/common/Dark/Inbox_Generic_Small_60X60_3X_Dark.png?02072023"},eS=()=>{const{navigateToInboxCouponsModule:e}=(0,ch.useContext)(zC),{inboxCouponsAssets:t,flyoutData:n,stateManagement:o,isDarkMode:r}=(0,ch.useContext)(_C),a=(0,ch.useCallback)((async n=>{await xC.logButtonClickTelemetry(n.target,i.$S.InboxCouponsConnectYourEmail),e?.(),t.scrollInboxCouponsModuleIntoView(),o.dispatchEvent(new CustomEvent(Ku.e1.InboxCouponsUpsellTriggered))}),[e,t.scrollInboxCouponsModuleIntoView,o]),s=(0,ch.useMemo)((()=>ch.createElement(ob,null,n.strings.inboxCouponsConnect)),[n.strings.inboxCouponsConnect]),l=(0,ch.useRef)(null);(0,ch.useEffect)((()=>{if(!l.current)return;const e=(0,Y.Ux)("span");sp.render(s,e),(0,T.B7)(l.current,n.strings.inboxCouponsUpsellCard,e)}),[l,s,n.strings.inboxCouponsUpsellCard]);const c=(0,ch.useMemo)((()=>ch.createElement("div",{ref:l})),[l]);return ch.createElement(yb,{heading:"",body:ch.createElement(tS,{onClick:a},ch.createElement(Zb,{hasOuterBorders:!0,maxHeightInPx:200,style:{overflowY:"auto"}},ch.createElement(Tb,{title:"",imageUrl:t.getIcon(Qb,{dark:r}),subtitle:c,ariaLabel:n.strings.inboxCouponsTitle,collapsable:!1,styles:iS})))})},tS=bm.button`
cursor: pointer;
margin: 0;
border: 0;
padding: 0;
text-align: start;
cursor: pointer;
background-color: transparent;
`,iS={subtitle:{maxWidth:"100%",fontSize:"14px",fontWeight:"600",lineHeight:"20px",color:"var(--neutral-foreground-rest)"},root:{padding:"10px 18px",display:"flex"},logo:{margin:0,width:"60px",height:"60px"},logoContainer:{alignItems:"center",display:"flex",justifyContent:"center",marginInlineEnd:"19px"}},nS=e=>{const{flyoutData:t,commonAssets:i,activeRetailerInboxCouponsAssets:n,pageHandlerModule:o,logModule:r,stateManagement:a,utilities:s,telemetryUtilities:l,moduleName:c}=e,d=t.dataLoader.GetLoadTimeDataValue("is_rtl",!1);return ch.createElement(NC,{flyoutData:t,pageHandlerModule:o,stateManagement:a,commonAssets:i,logModule:r,utilities:s,inboxCouponsAssets:n,telemetryUtilities:l,moduleName:c},ch.createElement(BC,null,ch.createElement(WC,null,ch.createElement("div",{dir:d?"rtl":"ltr"},ch.createElement(oS,null)))))},oS=()=>{const{isAuthorized:t}=(0,ch.useContext)(LC),{activeRetailerInboxCoupons:i,activeRoute:n,updateActiveRoute:o}=(0,ch.useContext)(zC),{stateManagement:a,inboxCouponsAssets:s}=(0,ch.useContext)(_C);(0,ch.useEffect)((()=>{t&&!i&&a.dispatchEvent(new CustomEvent(Ku.e1.ActiveRetailerInboxCouponsEmpty))}),[t,i]),(0,ch.useEffect)((()=>{let e=null;t?i&&(e=jC.ActiveRetailer):e=jC.Upsell,e!==n&&o(e)}),[t,i,n,o]),(0,ch.useEffect)((()=>{xC.addModuleInfoHandler(fC.ActiveRetailerInboxCoupons,(()=>({moduleName:fC.ActiveRetailerInboxCoupons,shoppingTab:r.d$.Contextual,route:n})))}),[n]);const l=e.R.isExperimentActive(f.H.singleScrollingShoreline),c=(0,ch.useMemo)((()=>n===jC.Upsell&&l),[n,l]),d=(0,ch.useMemo)((()=>n===jC.ActiveRetailer&&0===(i?.coupons?.length??0)),[n,i]);return ch.createElement("div",{id:"activeRetailerInboxCouponsModuleContainer",title:""},n===jC.Upsell&&!l&&ch.createElement(eS,null),n===jC.ActiveRetailer&&!d&&ch.createElement(Xb,null),(null===n||c||d)&&ch.createElement("style",{className:"sectionSeparator"},"#",s.RootModuleWrapperHtmlId," ","{","display: none;","}","#",s.RootModuleWrapperHtmlId,"+ .sectionSeparator ","{","display: none;","}"))};var rS=class extends Qu{constructor(e,t,i,n){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"cartValue",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),this.logModule=t.logModule,this.pageHandlerModule=t.pageHandlerModule,this.flyoutData=e,this.utilities=t.viewModulesUtilities,this.commonAssets=i,this.assets=new GC(e.common.resourcesEndpoint),this.stateManagement=n,this.telemetryUtilities=t.telemetryHandler}GetModuleName(){return r.ModuleNames.ACTIVE_RETAILER_INBOX_COUPONS}async ShouldRenderModule(){const t=this.flyoutData.common.isPane,i=e.R.isExperimentActive(f.H.shorelineinboxcoupons),n=this.flyoutData.common.isDomainEligible;if(!t||!i||!n)return Promise.resolve(!1);let o;const r=this.flyoutData.dataLoader.GetLoadTimeDataValue("msaEmail",void 0);if(void 0===r)try{o=this.pageHandlerModule.IsMessageAllowed("getEdgeAnid")&&((await this.pageHandlerModule.GetEdgeAnid(!0))?.anid??"").length>0}catch(e){o=!1}else o=r.length>0;let a=!1,s=!1,l=!1;o||(a=""===this.flyoutData.dataLoader.GetLoadTimeDataValue("aadEmail",""),s=!a,l=this.flyoutData.dataLoader.GetLoadTimeDataValue("storage",void 0)?.[Ce.Q.InboxCouponsEdgeSignInSuccess]??!1);const c=this.flyoutData.common.browseMode,d=("normal"===c||""===c)&&(o||a||s&&l);return Promise.resolve(d)}async renderModule(){const t=(0,Y.Ux)("msft-edge-shopping-section");t.id=this.assets.RootModuleWrapperHtmlId;const i=e.R.isExperimentActive(f.H.singleScrollingShoreline);t.titleText=i?(0,T.fZ)("inboxCouponsFromRetailerTitle",this.flyoutData.strings.inboxCouponsFromRetailerTitle,this.flyoutData.common.domain):this.flyoutData.strings.inboxCouponsTitle,t.accordion=!0,t.truncateOverflowedHeader=!0,t.isPane=this.flyoutData.common.isPane,sp.render(ch.createElement(nS,{commonAssets:this.commonAssets,flyoutData:this.flyoutData,activeRetailerInboxCouponsAssets:this.assets,pageHandlerModule:this.pageHandlerModule,logModule:this.logModule,stateManagement:this.stateManagement,utilities:this.utilities,telemetryUtilities:this.telemetryUtilities,moduleName:this.GetModuleName()}),t),this.utilities.applyStyles(t,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());const n=this.CreateModule(t,r.H7.ACTIVE_RETAILER_INBOX_COUPONS,r.ModuleNames.ACTIVE_RETAILER_INBOX_COUPONS,r.$k.CONTEXTUAL,r.SV.SQUARES);return Promise.resolve(n)}async populateMainHeader(){}PostProcessing(e,t,i){}},aS=o(91897);function sS(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function lS(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?sS(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):sS(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}let cS=function(e){return e.BlackFriday="BlackFriday",e.CyberMonday="CyberMonday",e.Thanksgiving="Thanksgiving",e.Holidays="Holidays",e.NewYear="NewYear",e.Valentines="Valentines",e}({});const dS=new Map([[cS.BlackFriday,{title:"Black Friday Deals",link:"https://{hostName}/{localeCode}/shopping/deals",backgroundStyles:"--shopping-stripe-heading-color: #fff; --shopping-stripe-background: center/cover url(https://www.bing.com/th?id=OSC.TOOLEB2C6F2D9639486AB5DABEE8300303B490747725649BDF686DC37C48CCD52AA6);"}],[cS.CyberMonday,{title:"Cyber Monday Deals",link:"https://{hostName}/{localeCode}/shopping/deals",backgroundStyles:"--shopping-stripe-heading-color: #fff; --shopping-stripe-background: center/cover url(https://www.bing.com/th?id=OSC.TOOL1E2EB4CD021B33AAB89921B75925EFD713F8EEA442D266763643780F83049CF7);"}]]),uS=new Set(Object.values(cS));var hS=class extends qy{initializeComponent(){this.component=(0,Y.Ux)("msft-banner-card"),this.component.ctaText=this.flyoutData.strings.shopAllCTA,this.component.onCTAClick=this.logMITCardClickedAndNavigate.bind(this)}async moduleFirstVisible(t){const i=function(e,t){if(!e)return;const i=dS.get(e);return i?lS(lS({},i),{},{link:Ky(i.link,t)}):void 0}(function(){if(!e.R.isExperimentActive(f.H.startShoppingMomentInTimeModule))return;const t=e.R.getMultipleVariants(f.H.startShoppingMomentInTimeModule);if(3===t?.length)try{let e,i,n;for(const o of t)"startDate"===o.key?e=(0,aS.EA)(o.value):"endDate"===o.key?i=(0,aS.EA)(o.value):"event"!==o.key||(0,p.TF)(o.value)||(n=o.value?.split(","));e?.setHours(e.getHours()-7),i?.setHours(i.getHours()-8);const o=(0,aS.EA)();let r;for(const e of n)uS.has(e)&&(r=e);if(e&&i&&o>=e&&o<=i&&r)return r}catch(e){}}(),t);if(i)return this.component.titleText=i.title,this.component.backgroundStyles=i.backgroundStyles,this.component.ctaUrl=i.link,void this.focusComponentWhenOpenedByNotification();const n=await jy.fetchingAndCacheShoppingFeedModulesData(this.flyoutData,this.logModule,this.pageHandlerModule,t);n?.specialEventCarousel?.title&&n?.specialEventCarousel?.link?(this.component.titleText=n.specialEventCarousel.title,this.component.backgroundStyles=n.specialEventCarousel.background,this.component.ctaUrl=Ky(n.specialEventCarousel.link,t),this.focusComponentWhenOpenedByNotification()):this.component.style.display="none"}featureTogglesAreActive(){return super.featureTogglesAreActive()&&e.R.isExperimentActive(f.H.startShoppingMomentInTimeModule)}GetEnabledMarkets(){return Iy.T$}GetStartShoppingModuleName(){return r.ModuleNames.MOMENT_IN_TIME}GetModulePriority(){return r.H7.MOMENT_IN_TIME}GetModuleViewed(){return bp.r.FEED_MOMENT_IN_TIME}GetModuleViewedMojom(){return bp.L.FEED_MOMENT_IN_TIME}SANConsentRequired(){return!1}focusComponentWhenOpenedByNotification(){"trueTab"===(0,h.Mw)("mitOpen")&&gn.SO.queueUpdate((()=>{this.component.focus()})),(0,h.Xo)("mitOpen","false")}logMITCardClickedAndNavigate(e){const t=new W.Z(i.$S.MomentInTimeCard,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,`Show more button clicked for feed module: ${this.GetStartShoppingModuleName()}`,t),this.pageHandlerModule.RecordAsUserAction(K.bS.FEED_MOMENT_IN_TIME),this.pageHandlerModule.NavigateToUrl(e)}},pS=class extends Qu{constructor(t,n){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"populatePaymentOptionsList",((t,n,o)=>{let a;const s=this.flyoutData.dataStoreModule.PaymentOptionsData;if(s){s.length>0&&(a=s.length);let o=0;const l=e.R.isExperimentActive(f.H.showWalletFooter);let c=!1;if(n){const e=new W.Z(i.$S.SeeMorePaymentOptions,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"See more payment options",e),o=r.CS.PAYMENT_OPTIONS,c=l}else a>r.CS.PAYMENT_OPTIONS?a=r.CS.PAYMENT_OPTIONS:c=l;for(let e=o;e<a;e++){const i=(0,Y.Ux)("DIV");i.className="card lateralMargin";const n=(0,Y.Ux)("div");n.className="content";const o=(0,Y.Ux)("div");o.className="start-content";const r=(0,Y.Ux)("div");r.className=`bank-logo ${s[e].providerName}`,r.innerHTML=this.assets.getIcon(s[e].providerName),o.appendChild(r),n.appendChild(o);const a=(0,Y.Ux)("div");a.className="end-content";const l=(0,Y.Ux)("p");l.className="detail",l.textContent=s[e].projectedMonthlyPaymentDetails;const c=(0,Y.Ux)("p");c.className="suggestion",c.textContent=s[e].paymentSuggestion,a.appendChild(l),a.appendChild(c),n.appendChild(a),i.appendChild(n),t.appendChild(i)}if(c){const e=(0,Y.Ux)("div");e.className="footer";const i=(0,Y.Ux)("fluent-anchor");i.textContent=this.flyoutData.strings.microsoftWalletLinkText,i.className="wallet-link",i.appearance="lightweight",i.addEventListener("click",(()=>{this.pageHandlerModule.NavigateToWallet()})),(0,T.B7)(e,this.flyoutData.strings.microsoftWalletManage,i),t.appendChild(e)}}})),this.logModule=n.logModule,this.pageHandlerModule=n.pageHandlerModule,this.flyoutData=t,this.utilities=n.viewModulesUtilities,this.assets=new class{getStyles(){return"\n .payment-options .card {\n height: 88px;\n margin-bottom: 12px;\n overflow: hidden;\n border-radius: 8px;\n background-color: var(--fill-color);\n }\n .payment-options .content {\n display: flex;\n }\n .payment-options .bank-logo {\n width: 144px;\n height: 88px;\n box-sizing: border-box;\n\n }\n .payment-options .bank-logo.zipPay {\n padding: 26px 0 0 30px;\n -webkit-clip-path: polygon(96% 0, 100% 100%, 0 100%, 0 0);\n background: #1A0826;\n }\n .payment-options .end-content {\n margin-left: 14px;\n display: flex;\n flex-direction: column;\n justify-content: center;\n }\n .payment-options .end-content p {\n margin: 0;\n line-height: 16px;\n }\n .payment-options .footer {\n display: flex;\n line-height: 16px;\n }\n .payment-options .wallet-link {\n margin-left: 3px;\n line-height: 16px;\n height: 16px;\n }\n "}getDarkModeStyles(){return"\n .payment-options .bank-logo.zipPay {\n background: white;\n }\n .payment-options .bank-logo.zipPay svg path.lightTheme{\n fill: #1A0826;\n }\n .payment-options .card {\n background-color: rgb(65, 65, 65);\n }\n "}getIcon(e){return{zipPay:eh.Z.getTrustedHTML`<svg width="80" height="31" viewBox="0 0 80 31" fill="none" xmlns="http://www.w3.org/2000/svg">
<path class="lightTheme" fill-rule="evenodd" clip-rule="evenodd" d="M1.80142 24.8119L2.49982 30.793H26.9471L26.148 23.944H14.7478L14.6492 23.0943L25.1477 15.3817L24.4462 9.38779H0L0.800065 16.2379H12.2175L12.3182 17.094L1.80142 24.8119Z" fill="#FFFFFA"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M27.2871 9.38742L29.7869 30.7927H54.2535L51.7527 9.38742H27.2871Z" fill="#AA8FFF"/>
<path class="lightTheme" fill-rule="evenodd" clip-rule="evenodd" d="M29.6562 6.54705C31.2574 8.04447 33.5671 8.04447 34.8144 6.54705C36.0628 5.04964 35.7761 2.62128 34.175 1.12386C32.5749 -0.374621 30.2651 -0.374621 29.0168 1.12386C27.7694 2.62128 28.0551 5.04964 29.6562 6.54705Z" fill="#FFFFFA"/>
<path class="lightTheme" fill-rule="evenodd" clip-rule="evenodd" d="M70.8676 20.5106L63.2106 20.5191L62.6108 15.3824L70.3075 15.3888C72.117 15.4112 73.0442 16.4832 73.1936 17.9497C73.2892 18.8934 72.8784 20.5106 70.8676 20.5106ZM79.9113 17.0946C79.3461 12.2828 75.7514 9.36703 70.8656 9.38724H54.5918L57.0916 30.7937H64.4122L63.911 26.512H71.6585C77.7561 26.512 80.5467 22.5167 79.9113 17.0946Z" fill="#FFFFFA"/>
</svg>
`}[e]??eh.Z.getTrustedHTML``}},this.telemetryUtilities=n.telemetryHandler}GetModuleName(){return r.ModuleNames.PAYMENT_OPTIONS}ShouldRenderModule(){const t=this.flyoutData.dataStoreModule.PaymentOptionsData,i=(t&&t.length>0&&e.R.isExperimentActive(f.H.showPaymentOptionsOnProductPage))??!1;return Promise.resolve(i)}renderModule(){const e=(0,Y.Ux)("msft-edge-shopping-section");this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),e.className="payment-options",e.id="paymentOptionsSection",this.populatePaymentOptionsList(e,!1,!1),this.utilities.createCommonListStructure(e,this.flyoutData.strings.paymentOptionLabel,this.flyoutData.dataStoreModule.PaymentOptionsData,this.GetModuleName(),(function(e){return r.CS.PAYMENT_OPTIONS}),this.populatePaymentOptionsList);const t=this.CreateModule(e,r.H7.PAYMENT_OPTIONS,r.ModuleNames.PAYMENT_OPTIONS,r.$k.HOME,r.SV.LIST);e.addEventListener("click",(function t(){if(e){const t=e.shadowRoot;if(t){const e=t.querySelector("fluent-accordion-item");e&&(e.classList.contains("expanded")||n?o||(i.RecordAsUserAction(K.bS.PAYMENT_OPTIONS_COLLAPSE_SECTION),o=!0):(i.RecordAsUserAction(K.bS.PAYMENT_OPTIONS_EXPAND_SECTION),n=!0))}}n&&o&&e&&e.removeEventListener("click",t)}));const i=this.pageHandlerModule;let n=!1,o=!1;return Promise.resolve(t)}populateMainHeader(){}},gS=o(18549),fS=class{constructor(e){(0,s.Z)(this,"flyoutData",void 0),this.flyoutData=e}shouldRenderNotification(e){return!(!this.shouldRender()||this.flyoutData.common.openedWith!==r.Te.Auto||this.flyoutData.common.popupOrigination!==e||!this.flyoutData.dataStoreModule.PriceHistoryData?.ProductDetails)}shouldRender(){const e=this.flyoutData.dataStoreModule.PriceComparisonData,t=e?.segment?.toLowerCase(),i=((t===r.VG.AUTOS&&e?.CompetingPrices&&e?.CompetingPrices.length>0)??!1)||t===r.VG.EMPTYAUTOSSEGMENT,n=this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK&&this.flyoutData.common.openedWith===r.Te.Auto;if(i||n)return!1;const o=this.flyoutData.dataStoreModule.PriceHistoryData,a=this.flyoutData.dataStoreModule.CouponData?.isCheckoutPageWithAutoApply??!1,s=o?.DailyPrices;return(o&&s&&s.length>=2&&(!a||"amazon.com"===this.flyoutData.common.domain))??!1}},mS=class{getStyles(){return"\n #txtPCProductTitle {\n margin-top: 5px;\n overflow: hidden;\n overflow-wrap: break-word;\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n }\n .spanCommissionValueSmall {\n display: flex;\n height: 20px;\n line-height: 20px;\n font-size: 12px;\n background: #0078D4;\n color: #fff;\n font-weight: 400;\n float: left;\n }\n #divDisclaimer {\n display: flex;\n flex-direction: row;\n background-color: #F7F7F7;\n height: 48px;\n width: 100%;\n margin-top: 3px;\n }\n .disclaimer {\n display: flex;\n flex-direction: row;\n }\n .disclaimerIcon {\n margin: 11px 9px 11px 12px;\n }\n .disclaimerIconFlyout {\n margin: 9px 9px 0 0;\n }\n .disclaimerTextFlyout {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 10px;\n color: var(--text-neutral-foreground);\n line-height: 14px;\n margin: 10px 2px 3px;\n width: 272px;\n text-align: left;\n }\n .titletextV2 {\n font-size: 20px;\n line-height: 28px;\n color: rgba(19, 135, 87, 1);\n font-weight: 600;\n display: inline-block;\n }\n .disclaimerText {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 10px;\n color: var(--text-neutral-foreground);\n line-height: 14px;\n margin:10px 59px 10px 2px;\n text-align: left;\n }\n #priceComparisonSection {\n padding-bottom: 10px;\n }\n #priceComparisonSection msft-product-card:hover {\n background: inherit;\n }\n\n .newpc:hover{\n box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.2);\n background: #FFFFFF !important;\n }\n .newpc {\n background: #FFFFFF;\n border-radius: 8px;\n margin-bottom: 8px;\n\n .imgPCFavIcon {\n align-self: center;\n }\n }\n #priceComparisonTile {\n padding: 0px 3px;\n }\n #priceComparisonTile.firstTileRadius.newpc:first-of-type {\n border-radius: 0px 0px 8px 8px !important;\n }\n .newpc_ {\n --fill-color: #f3f3f3 !important;\n }\n .newpc::part(txtRetailer) {\n font-weight: 600;\n font-size: 16px !important;\n line-height: 22px !important;\n }\n .newpc::part(control) {\n border-top: none;\n }\n\n .revampedPriceComparison {\n background: #FFFFFF;\n border-radius: 8px 8px 0px 0px;\n border-bottom: none;\n margin-bottom: 0px;\n }\n @media (prefers-color-scheme: dark){\n .newpc:hover{\n box-shadow: 0 1px 2px 0 rgba(41, 41, 41, 1);\n background: #1e1e1e !important;\n }\n .newpc {\n background: #292929;\n border-radius: 8px;\n margin-bottom: 8px;\n }\n .newpc_ {\n --fill-color: #292929 !important;\n }\n .revampedPriceComparison {\n background: #292929 !important;\n border-radius: 8px 8px 0px 0px;\n border-bottom: none;\n margin-bottom: 0px;\n }\n .titletextV2 {\n color: var(--text-green-savings-color);\n }\n }\n #hero-image-clickable:focus {\n outline-color: #898989;\n outline-width: 2px;\n outline-style: solid;\n }\n .backfill-paragraph {\n font-size: 12px;\n font-weight: 400;\n color: var(--text-neutral-foreground);\n margin: 0px;\n padding-left: 10px;\n }\n .tooltip-container {\n align-self: end;\n margin-bottom: 5px;\n margin-left: auto;\n margin-right: 6px;\n }\n .divAdSlug {\n border: 1px solid var(--text-retailer-color);\n border-radius: 4px;\n padding: 0px 3px;\n align-self: center;\n display: flex;\n vertical-align: middle;\n justify-content: center;\n }\n .v3 {\n color: #242424;\n }\n .divAdSlug.v2 {\n padding: 0px 4px 0px 4px;\n border-radius: 4px;\n border: 0.5px solid #D1D1D1;\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 11px;\n font-weight: 400;\n color: var(--neutral-foreground-rest);\n display: flex;\n justify-content: center;\n align-items: center;\n }\n .pc_discoverPane .divPriceComparisonWrapper {\n max-width: 100vw;\n box-sizing: border-box;\n }\n .pc_discoverPane .divTextContentWrapper {\n word-wrap: break-word;\n overflow: hidden;\n }\n .pc_discoverPane .section-end-content {\n padding: 0 5px 0 5px;\n }\n .divPriceComparisonWrapper {\n display: grid;\n grid-template-columns: 80px auto;\n column-gap: 12px;\n margin-top: 16px;\n }\n .divPriceComparisonWrapper.isPane {\n width: calc(100% - 24px);\n padding: 12px;\n margin-top: 0px;\n box-sizing: border-box;\n overflow: hidden;\n }\n .divPriceComparisonWrapper.noImage {\n grid-template-columns: auto!important;\n width: auto;\n }\n .divTextContentWrapper {\n display: flex;\n flex-direction: column;\n justify-content: center;\n font-weight: 600;\n }\n .txtPCTitle {\n font-weight: 500;\n }\n .divTextContentWrapper.withSavings {\n margin-top: 0px;\n }\n .divTextContentWrapper.withImage {\n text-align: left;\n }\n .divTextContentWrapper.noImage {\n text-align: center;\n align-items: center;\n }\n .divPriceComparisonWrapper.withSavings {\n grid-template-columns: 80px auto;\n align-items: center;\n column-gap: 16px;\n }\n .txtPCTitle.withSavings {\n font-size: 20px;\n line-height: 26px;\n font-weight: 600;\n }\n .txtPCTitle.noImage {\n display: flex;\n align-items: center;\n column-gap: 3px;\n place-self: center;\n font-size: 24px;\n line-height: 32px;\n }\n .spanSavings.noImage {\n font-size: 40px;\n line-height: 47px;\n }\n .spanBigSavings {\n font-size: 22px;\n line-height: 22px;\n }\n .spanNormalSavings {\n font-size: 40px;\n line-height: 40px;\n }\n .spanSavings {\n font-weight: 600;\n color: var(--text-green-savings-color);\n }\n .txtBestPrice {\n color: var(--text-green-savings-color);\n font-size: 24px;\n line-height: 28px;\n font-weight: 600;\n display: inline-block;\n }\n .imgPCFavIcon {\n max-width: 16px;\n max-height: 16px;\n border-radius: 2px;\n vertical-align: middle;\n min-width: 0px;\n }\n .imgPCFavIcon.v2 {\n max-width: 18px !important;\n max-height: 18px !important;\n align-self: center;\n border: 0.5px lightgray solid;\n }\n .aPCMicrosoftPrivacy {\n color: rgb(22 111 245);\n }\n #txtPCTooltip {\n align-self: center;\n }\n .pc_discoverPane .divTextContent {\n max-width: 150px !important;\n }\n .pc_discoverPane msft-product-card::part(control) {\n max-width: 100vw;\n }\n @media (-ms-high-contrast: active) {\n #hero-image-clickable:focus {\n outline-color: ButtonText;\n }\n }\n #priceComparisonTile .annotation-padding {\n padding-left: 25px;\n }"}getDarkModeStyles(){return"\n .backfill-paragraph {\n color: #FFFFFF;\n }\n .attrBottomAnnotation {\n color: #FFFFFF;\n }\n .aPCMicrosoftPrivacy {\n color: rgb(94 196 254)\n }\n .v3 {\n color: #FFFFFF;\n }\n "}getSafariStyles(){return"\n .spanSavings {\n font-weight: 500;\n color: var(--text-green-savings-color);\n }\n .txtPCTitle.withSavings {\n font-size: 20px;\n line-height: 26px;\n font-weight: 500;\n }\n .tooltip-container {\n margin-left: 5px !important;\n margin-right: 0 !important;\n margin-bottom: 3px !important;\n }\n\n .backfill-paragraph {\n margin-top: -14px !important;\n }\n\n .spanSavings.noImage {\n color: var(--text-green-savings-color) !important;\n }\n "}getCjkStyles(){return""}getCjkDarkModeStyles(){return""}getCjkSectionNumberIconPath(e){return`${e}cjk/sectionnumber.svg`}getBuyDirectIcon(){return eh.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16" fill="none">
<path fill="#1B5AD4" d="M2.5 2C2.22386 2 2 2.22386 2 2.5C2 2.77614 2.22386 3 2.5 3H2.7457C2.96894 3 3.16513 3.14799 3.22646 3.36264L4.81202 8.91208C4.996 9.55603 5.58458 10 6.2543 10H10.823C11.4363 10 11.9879 9.62657 12.2157 9.05709L13.69 5.37139C13.9527 4.71453 13.4689 4 12.7615 4H4.44858L4.18798 3.08792C4.004 2.44397 3.41542 2 2.7457 2H2.5ZM6.5 14C7.32843 14 8 13.3284 8 12.5C8 11.6716 7.32843 11 6.5 11C5.67157 11 5 11.6716 5 12.5C5 13.3284 5.67157 14 6.5 14ZM10.5 14C11.3284 14 12 13.3284 12 12.5C12 11.6716 11.3284 11 10.5 11C9.67157 11 9 11.6716 9 12.5C9 13.3284 9.67157 14 10.5 14Z"/></svg>`}getCashbackAnnotationImage(){return eh.Z.getTrustedHTML`<svg fill="#205AF7" width="14" height="9" viewBox="0 0 14 9" xmlns="http://www.w3.org/2000/svg"><path d="M2.49507 6.16572e-06C1.39051 -0.00270725 0.497293 0.890516 0.500006 1.99507L0.511429 6.64502C0.514142 7.74958 1.41176 8.6472 2.51632 8.64991L9.10413 8.6661C9.62955 8.66739 10.1334 8.46186 10.5067 8.09394L12.9019 5.73317C13.693 4.95348 13.6918 3.67471 12.8993 2.88872L10.5912 0.599778C10.2157 0.227396 9.70907 0.0177279 9.18153 0.0164318L2.49507 6.16572e-06Z"></path></svg>`}getDefaultGlobeIcon(){return eh.Z.getTrustedHTML`<svg width="18" height="18" viewBox="0 0 18 18" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M9 17C13.4183 17 17 13.4183 17 9C17 4.58172 13.4183 1 9 1C4.58172 1 1 4.58172 1 9C1 13.4183 4.58172 17 9 17ZM9 2C9.65685 2 10.4068 2.59025 11.0218 3.90814C11.2393 4.37419 11.4283 4.90978 11.5806 5.5H6.41936C6.57172 4.90978 6.76073 4.37419 6.97822 3.90814C7.59323 2.59025 8.34315 2 9 2ZM6.07203 3.48526C5.79564 4.07753 5.56498 4.75696 5.38931 5.5H2.93648C3.77295 4.05399 5.11182 2.93497 6.71442 2.38163C6.47297 2.71222 6.25828 3.08617 6.07203 3.48526ZM5.19265 6.5C5.06723 7.28832 5 8.12934 5 9C5 9.87066 5.06723 10.7117 5.19265 11.5H2.45963C2.16268 10.7236 2 9.8808 2 9C2 8.1192 2.16268 7.2764 2.45963 6.5H5.19265ZM5.38931 12.5C5.56498 13.243 5.79564 13.9225 6.07203 14.5147C6.25828 14.9138 6.47297 15.2878 6.71442 15.6184C5.11182 15.065 3.77295 13.946 2.93648 12.5H5.38931ZM6.41936 12.5H11.5806C11.4283 13.0902 11.2393 13.6258 11.0218 14.0919C10.4068 15.4097 9.65685 16 9 16C8.34315 16 7.59323 15.4097 6.97822 14.0919C6.76073 13.6258 6.57172 13.0902 6.41936 12.5ZM11.7938 11.5H6.20617C6.07345 10.7253 6 9.88331 6 9C6 8.11669 6.07345 7.27472 6.20617 6.5H11.7938C11.9266 7.27472 12 8.11669 12 9C12 9.88331 11.9266 10.7253 11.7938 11.5ZM12.6107 12.5H15.0635C14.2271 13.946 12.8882 15.065 11.2856 15.6184C11.527 15.2878 11.7417 14.9138 11.928 14.5147C12.2044 13.9225 12.435 13.243 12.6107 12.5ZM15.5404 11.5H12.8074C12.9328 10.7117 13 9.87066 13 9C13 8.12934 12.9328 7.28832 12.8074 6.5H15.5404C15.8373 7.2764 16 8.1192 16 9C16 9.8808 15.8373 10.7236 15.5404 11.5ZM11.2856 2.38163C12.8882 2.93497 14.2271 4.05399 15.0635 5.5H12.6107C12.435 4.75696 12.2044 4.07753 11.928 3.48526C11.7417 3.08617 11.527 2.71222 11.2856 2.38163Z" fill="black" fill-opacity="0.56" style="fill:black;fill:black;fill-opacity:0.56;"/>
</svg>`}};const vS="PCBackfillData";class yS{static async getBuyingOptions(t,i,n){const o=Object.fromEntries(Object.entries(i).filter((([e,t])=>void 0!==t?.value)).map((([e,t])=>[e,t.value]))),r=e.R.GetRawEnabledServiceFeatures(),a=n;try{const e={};e.RequestContext={EnabledServiceFeaturesv2:r,CorrelationId:a},e.ProductId=t,e.UserFacingAttributes=o;const i=await fetch("https://www.bing.com/api/shopping/v1/BuyingOptions",{headers:{"Content-Type":"application/json"},method:"POST",body:JSON.stringify(e)});if(!i.ok)throw new Error(`HTTP error! status: ${i.status}`);const n=await i.json();return Promise.resolve(n)}catch(e){return Promise.reject(e)}}}class CS extends Qu{constructor(n,o,r){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"telemetryHandler",void 0),(0,s.Z)(this,"discoverTelemetryHandler",void 0),(0,s.Z)(this,"visibilityRequest",[]),(0,s.Z)(this,"autoOpenControllerUtilities",void 0),(0,s.Z)(this,"tooltipUtilities",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"dataValidationUtilities",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"priceComparisonUtilities",void 0),(0,s.Z)(this,"msBuyDirectSeller","Buy with Microsoft"),(0,s.Z)(this,"pcModuleUXConfig",void 0),(0,s.Z)(this,"buyingOptionsExp",Boolean(e.R.getServiceExperimentValue(f.H.buyingOptions))),(0,s.Z)(this,"buyingOptionsClientExp",Boolean(e.R.getServiceExperimentValue(f.H.buyingOptionsExperiment))),(0,s.Z)(this,"sectionId",this.buyingOptionsExp||this.buyingOptionsClientExp?"buyingOptionsSection":"priceComparisonSection"),(0,s.Z)(this,"firstCard",void 0),(0,s.Z)(this,"pcBackfillData",void 0),(0,s.Z)(this,"pcSection",void 0),(0,s.Z)(this,"isCjkEnabled",void 0),(0,s.Z)(this,"cjkDataVendor",void 0),(0,s.Z)(this,"filterGroup",void 0),(0,s.Z)(this,"isNewPCFeatureEnabled",e.R.isExperimentActive(f.H.revampedPriceComparison)),(0,s.Z)(this,"priceCompareV2",e.R.isExperimentActive(f.H.priceCompareV2)),(0,s.Z)(this,"phTelemetryData",new t.Z(i.xu.FavIconRenderStatus)),(0,s.Z)(this,"freeOffers",void 0),(0,s.Z)(this,"retailersTotalShown",3),(0,s.Z)(this,"numberOfRetailersPerClick",5),(0,s.Z)(this,"retailerList",void 0),(0,s.Z)(this,"edgeImpressionId",void 0),this.logModule=r.logModule,this.pageHandlerModule=r.pageHandlerModule,this.stateManagement=n,this.flyoutData=o,this.utilities=r.viewModulesUtilities,this.storageHandler=r.storageHandler,this.telemetryHandler=r.telemetryHandler,this.discoverTelemetryHandler=r.discoverTelemetryHandler,this.dataValidationUtilities=r.dataValidationUtilities,this.tooltipUtilities=r.tooltipUtilities,this.assets=new mS,this.pcModuleUXConfig=new class{constructor(){(0,s.Z)(this,"BannerExperimentActive",!1),this.BannerExperimentActive=e.R.isPCBannerUXExperimentActive()}UpdateTextOnLowestPriceTileBadge(){return this.BannerExperimentActive}},this.autoOpenControllerUtilities=r.autoOpenControllerUtilities,this.isCjkEnabled=o.common.isCJKEnabled,this.cjkDataVendor=o.common.cjkDataVendor,this.telemetryUtilities=r.telemetryHandler,this.priceComparisonUtilities=new gS.Z(this.flyoutData.common.openedWith,this.flyoutData.dataStoreModule.PriceComparisonData?.CompetingPrices,this.flyoutData.dataStoreModule.PriceComparisonData?.Price,this.flyoutData.common.popupOrigination,this.flyoutData.common.pageLocale)}GetModuleName(){return r.ModuleNames.PRICECOMPARISON}CalculateRanking(){return this.priceComparisonUtilities?.shouldBeInPolePosition?r.zz.SaveMoneyOtherSites:r.zz.InformOtherSites}ShouldRenderModule(){const e=this.flyoutData.dataStoreModule.PriceComparisonData,t=this.flyoutData.dataStoreModule.PriceComparisonData?.buyingOptions,i=e?.segment?.toLowerCase();if(i===r.VG.AUTOS||i===r.VG.EMPTYAUTOSSEGMENT)return Promise.resolve(!1);const n=(e&&e.CompetingPrices&&e.CompetingPrices.length>0)??!1,o=((this.buyingOptionsExp||this.buyingOptionsClientExp)&&n&&t)??!1;return n||o?Promise.resolve(!0):Promise.resolve(!1)}renderHtmlElement(){const t=this.flyoutData.dataStoreModule.PriceComparisonData;if(this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),this.isCjkEnabled&&this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getCjkStyles(),void 0,this.assets.getCjkDarkModeStyles()),(0,dt.tB)(this.flyoutData)&&this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getSafariStyles()),e.R.isExperimentActive(f.H.singleScrollingShoreline)){if(this.pcSection=document.createElement("msft-edge-shopping-section"),this.pcSection.id=this.sectionId,this.pcSection.seeMoreSeparate=!0,this.pcSection.style.overflow="unset",this.pcSection.titleText="Buying Options",this.flyoutData.common.isDiscoverPane){const e=()=>{this.discoverTelemetryHandler.LogEventTelemetry(i.xu.PriceComparisonDiscoverHover,"Price Comparison Discover Hover","",r.ModuleNames.PRICECOMPARISON),this.pcSection.removeEventListener("mouseover",e)};this.pcSection.addEventListener("mouseover",e)}}else if(this.pcSection=document.createElement("msft-edge-shopping-section"),this.pcSection.id=this.sectionId,this.pcSection.seeMoreSeparate=!0,this.pcSection.style.overflow="unset",this.pcSection.titleText="Buying Options",this.flyoutData.common.isDiscoverPane){const e=()=>{this.discoverTelemetryHandler.LogEventTelemetry(i.xu.PriceComparisonDiscoverHover,"Price Comparison Discover Hover","",r.ModuleNames.PRICECOMPARISON),this.pcSection.removeEventListener("mouseover",e)};this.pcSection.addEventListener("mouseover",e)}this.isNewPCFeatureEnabled&&this.pcSection.classList.add("newpc_"),this.pcSection.isCjk=this.isCjkEnabled,this.pcSection.isCjkNotification=this.isCjkEnabled&&this.flyoutData.common.openedWith===r.Te.Hover,this.pcSection.isCjkNotification&&(this.pcSection.countNumber=t?.CompetingPrices?.length??0,this.pcSection.cjkSectionNumberIcon=this.assets.getCjkSectionNumberIconPath(this.flyoutData.common.resourcesEndpoint)),this.isCjkEnabled||(this.pcSection.tabIndex=0),this.populatePriceList(this.pcSection,!1,!1);const n=this.priceCompareV2?this.flyoutData.strings.newpcPriceSectionTitle:this.flyoutData.strings.pcPriceSectionTitle;return this.utilities.createCommonListStructure(this.pcSection,n,this.flyoutData.dataStoreModule.PriceComparisonData?.CompetingPrices,this.GetModuleName(),this.numbersToRender.bind(this),this.populatePriceList.bind(this),void 0,void 0,this.isCjkEnabled),this.pcSection}async renderModule(){if(this.buyingOptionsClientExp&&this.pageHandlerModule.TriggerExperiment(f.H.buyingOptionsExperiment),(!0===this.buyingOptionsExp||!0===this.buyingOptionsClientExp)&&this.flyoutData.dataStoreModule.PriceComparisonData.CompetingPrices?.length>0){const e=await this.renderBuyingOptions(),n=this.CreateModule(e,this.isCjkEnabled?r.H7.CJK_PRICECOMPARISON:r.H7.PRICECOMPARISON,r.ModuleNames.PRICECOMPARISON,r.$k.CONTEXTUAL,this.isCjkEnabled?r.SV.SQUARES:r.SV.LIST),o=new t.Z(i.xu.BuyingOptionsRendered);return this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Buying options rendered",o),Promise.resolve(n)}{!1===this.buyingOptionsExp&&!1===this.buyingOptionsClientExp&&this.doCFLogging();const e=this.renderHtmlElement(),n=this.flyoutData.dataStoreModule.PriceComparisonData,o=this.CreateModule(e,this.isCjkEnabled?r.H7.CJK_PRICECOMPARISON:r.H7.PRICECOMPARISON,r.ModuleNames.PRICECOMPARISON,r.$k.CONTEXTUAL,this.isCjkEnabled?r.SV.SQUARES:r.SV.BLOCK),a=this.priceComparisonUtilities.lowestPrice,s=n.Price-a;if(a>0&&s>0){const e=new t.Z(i.xu.YouCanSave,n.CompetingPrices.length,parseFloat(s.toFixed(2)));n?.isCashbackOfferPresent&&(e.Metadata=JSON.stringify({IsCashbackOfferPresent:!0,AdsTraceId:n?.adsTraceId})),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Price comparison - user can save money",e)}else{const e=new t.Z(i.xu.BestPrice,n.CompetingPrices.length);n?.isCashbackOfferPresent&&(e.Metadata=JSON.stringify({IsCashbackOfferPresent:!0,AdsTraceId:n?.adsTraceId})),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Price comparison - user has the best price",e)}return this.pcModuleUXConfig.BannerExperimentActive&&this.disableNotificationHeader(),this.flyoutData.common.isDiscoverPane&&(this.pcSection.style.margin="0",this.pcSection.seeMoreSeparate=!1,this.pcSection.classList.add("pc_discoverPane")),n&&n.CompetingPrices?.length>0&&n.CompetingPrices[0].BillingType===r.YO.Backfill&&this.flyoutData.common.openedWith!==r.Te.Auto&&(this.isCjkEnabled||this.pcSection.appendChild(await this.getBackfillStatementElement())),this.isCjkEnabled&&(this.pageHandlerModule.RecordAsCjkScenario(Hg.SHOW,Ug.PRICE_COMPARISON),this.cjkDataVendor&&this.cjkDataVendor in $g&&this.pageHandlerModule.RecordAsCjkScenario(Hg.SHOW+$g[this.cjkDataVendor],Ug.PRICE_COMPARISON)),Promise.resolve(o)}}populateMainHeader(){if(this.buyingOptionsExp||this.buyingOptionsClientExp)this.pcSection=this.flyoutData.common.shopping.querySelector(`#${this.sectionId}`),this.pcSection&&(this.pcSection.slot="header-content",this.pcSection.isHeader=!0);else if(this.priceCompareV2){if(this.flyoutData.common.isPane&&this.pcSection){this.pcSection.slot="header-content",this.pcSection.isHeader=!0;const e=this.pcSection.querySelector(".btnSeeMore");e&&e.classList.add("btnSeeMoreSeparate")}}else{if(this.isCjkEnabled)return void gn.SO.queueUpdate((()=>{this.utilities.handleCjkSectionAsTopModuleStyle(this.pcSection)}));const e=this.flyoutData.dataStoreModule.PriceComparisonData,t=this.flyoutData.common.shopping;if(e?.CompetingPrices&&e.CompetingPrices.length>0){const i=(0,ne.Jl)(e.CompetingPrices[0].CurrencySymbol),n=(0,Y.Ux)("div");n.classList.add("divPriceComparisonWrapper"),this.isNewPCFeatureEnabled&&n.classList.add("revampedPriceComparison");const o=(0,Y.Ux)("div");o.classList.add("divTextContentWrapper");const r=(0,Y.Ux)("h2");let a;r.classList.add("txtLarge"),this.isNewPCFeatureEnabled?r.classList.add("titletextV2"):r.classList.add("txtPCTitle");const s=this.priceComparisonUtilities.lowestPrice,l=this.flyoutData?.dataStoreModule.PriceHistoryData?.PriceHistoryInsightType===de.MU.NoInsight,c=e?.CompetingPrices?.some((e=>e.InstallmentAmount)),d=l||c,u=e.Price-s;if(d)r.textContent=this.flyoutData.strings.newpcPriceSectionTitle;else if(s>0&&u>0)if(o.classList.add("withSavings"),n.classList.add("withSavings"),r.classList.add("withSavings"),u<=1||!this.isAboveThreshold(e.Price,s))r.textContent=this.flyoutData.strings.pcSmallSavingsHeader;else{a=(0,Y.Ux)("span"),this.isNewPCFeatureEnabled?a.classList.add("titletextV2"):(a.classList.add("spanSavings"),u>=1e5?a.classList.add("spanBigSavings"):a.classList.add("spanNormalSavings"));const t=this.utilities.formatPrice(u,e.CompetingPrices[0].PriceCurrency);a.textContent=i+t,(0,T.B7)(r,this.flyoutData.strings.savingsHeader,a)}else{r.textContent=this.flyoutData.strings.pcPriceSectionTitle;const t=(0,Y.Ux)("span");this.isNewPCFeatureEnabled?t.classList.add("titletextV2"):t.classList.add("txtBestPrice"),e.Price?-1!==s&&(t.textContent=this.flyoutData.strings.pcBestPriceTitle.toLowerCase(),(0,T.B7)(r,this.flyoutData.strings.pcBestPriceRefreshHeader,t)):t.textContent=this.flyoutData.strings.pcSmallSavingsHeader}if(o.appendChild(r),this.isNewPCFeatureEnabled)n.classList.add("noImage"),o.classList.add("noImage"),r.classList.add("noImage"),a?.classList.add("noImage");else if((0,p.TF)(e.currentImageUrl))(0,dt.tB)(this.flyoutData)&&(n.style.marginTop="0px"),n.classList.add("noImage"),o.classList.add("noImage"),r.classList.add("noImage"),a?.classList.add("noImage");else{const t=(0,Y.Ux)("img");this.utilities.setImageSrc(t,this.flyoutData.common.urlPrefix+e.currentImageUrl);const i=this.utilities.createProductImage(80,80,t,e.currentProductTitle);let s=!0;o.classList.add("withImage"),t.addEventListener("error",(()=>{s=!1,t.remove(),i.remove(),n.style.gridTemplateColumns="auto",o.classList.add("noImage"),r&&r.classList.add("noImage"),a&&a.classList.add("noImage")})),s?n.appendChild(i):((0,dt.tB)(this.flyoutData)&&(n.style.marginTop="0px"),n.classList.add("noImage"),r&&r.classList.add("noImage"),a&&a.classList.add("noImage"))}if(n.appendChild(o),this.pcSection=this.flyoutData.common.shopping.querySelector(`#${this.sectionId}`),this.flyoutData.common.isPane&&this.pcSection){n.classList.add("isPane"),this.pcSection.prepend(n),this.pcSection.slot="header-content",this.pcSection.isHeader=!0;const e=this.pcSection.querySelector(".btnSeeMore");e&&e.classList.add("btnSeeMoreSeparate")}else n.slot="header-content",n.classList.add("lateralMargin"),t.appendChild(n)}}}PostProcessing(e,t,n){0===t||this.flyoutData.common.isPane?this.visibilityRequest.length>0&&this.pageHandlerModule.SendBingVisibilityRequest(this.visibilityRequest):this.firstCard&&(this.firstCard.isFirst=!0),this.flyoutData.common.isDiscoverPane&&0===t&&this.discoverTelemetryHandler.LogEventTelemetry(this.buyingOptionsExp||this.buyingOptionsClientExp?i.xu.BuyingOptionsDiscoverView:i.xu.PriceComparisonDiscoverView,this.buyingOptionsExp||this.buyingOptionsClientExp?"Buying Options Discover View":"Price Comparison Discover View","",r.ModuleNames.PRICECOMPARISON,{},this.getShoppingContent()),x.ZP.scrollToModuleIfTargeted(n,this.GetModuleName())}populatePriceList(e,t,n){let o;const a=this.numbersToRender(),s=this.flyoutData.dataStoreModule.PriceComparisonData,l=s?.CompetingPrices;if(l){l.length>0&&(o=l.length);let c=0;if(t){const t=new W.Z(i.$S.SeeMoreRetailers,this.telemetryUtilities.setContentViewed(this.GetModuleName()));t.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.pageHandlerModule.RecordAsUserAction(K.bS.VIEW_MORE_RETAILERS),this.isCjkEnabled&&(this.pageHandlerModule.RecordAsUserAction(K.bS.CJK_CLICK_PRICE_COMPARISON_SEE_MORE),this.pageHandlerModule.RecordAsCjkScenario(Hg.ACTION,Ug.PRICE_COMPARISON_SEE_MORE),this.cjkDataVendor&&this.cjkDataVendor in $g&&this.pageHandlerModule.RecordAsCjkScenario(Hg.ACTION+$g[this.cjkDataVendor],Ug.PRICE_COMPARISON_SEE_MORE)),this.logModule.LogInfoEvent(i.R.ButtonClick,"Price comparison see more retailers",t),c=a;const n=new CustomEvent(Ku.e1.SeeMoreClick,{detail:{totalCards:l.length}});e.dispatchEvent(n)}else o>a&&(o=a);const d=this.priceComparisonUtilities.lowestPrice,u=this.stateManagement.getState(Ku.IY.pcLowestPriceImpression),h=this.stateManagement.getState(Ku.IY.multiPcImpressions)??[];this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Total Offers expected to render: "+o,this.phTelemetryData);for(let i=c;i<o;i++)l[i]?.promotionInformation?.rebateValue&&l[i]?.BillingType===r.YO.NoCharge||this.createPriceComparisonTile(l[i],d,c,t,n,i,s?.Price,u,h,l.length,e);this.visibilityRequest.length>0&&t&&this.pageHandlerModule.SendBingVisibilityRequest(this.visibilityRequest)}}navigateToRetailer(e,t,n){this.dataValidationUtilities.writeValidationDataToStorage(e.Price.toString(),e.Description,this.GetModuleName(),e.Url);const o=new W.Z(i.$S.NavigatedToAnotherRetailer,this.telemetryUtilities.setContentViewed(this.GetModuleName()),this.flyoutData.common.domain);o.Metadata=JSON.stringify({Position:t,BillingType:e.BillingType,popupOriginationEnum:this.flyoutData.common.popupOrigination,offerId:e.globalOfferId,price:e.LowPrice??e.Price,offerUrl:e.Url,seller:e.SellerName,currency:e.CurrencySymbol,offerDomain:e.Domain,installmentAmount:e.InstallmentAmount,installmentDescription:e.InstallmentDescription}),this.pageHandlerModule.RecordAsUserAction(K.bS.NAVIGATE_TO_RETAILER),this.pageHandlerModule.RecordAsUserEngagement(q.FV.NAVIGATE_TO_RETAILER,this.flyoutData.common.popupOrigination),this.isCjkEnabled&&(this.pageHandlerModule.RecordAsUserAction(K.bS.CJK_PRICE_COMPARISON_CLICK),this.pageHandlerModule.RecordAsCjkScenario(Hg.ACTION,Ug.PRICE_COMPARISON),this.cjkDataVendor&&this.cjkDataVendor in $g&&this.pageHandlerModule.RecordAsCjkScenario(Hg.ACTION+$g[this.cjkDataVendor],Ug.PRICE_COMPARISON)),this.logModule.LogInfoEvent(i.R.ButtonClick,"Navigation to another retailer from price comparison",o),this.pageHandlerModule.NavigateToRetailerSite(e.Url)}createCashbackTooltip(e){return this.tooltipUtilities.createPriceCompareCashbackTooltip(e,this.pageHandlerModule)}createPriceComparisonTile(t,i,n,o,a,s,l,c,d,u,h,p=!1){const g=document.createElement("msft-product-card"),m=new fS(this.flyoutData).shouldRender();g.id="priceComparisonTile",g.tabIndex=0,m&&!this.priceComparisonUtilities?.shouldBeInPolePosition||g.classList.add("firstTileRadius"),g.isCjk=this.isCjkEnabled,g.isInCjkFlyout=this.isCjkEnabled&&!this.flyoutData.common.isPane,g.addEventListener("click",(async()=>{e.R.isExperimentActive(f.H.CouponsPersonalization)&&await this.autoOpenControllerUtilities.userEngagementStoreManager.addEngagement(q.w1.POSITIVE,this.flyoutData.common.popupOrigination,r.ModuleNames.PRICECOMPARISON.toString(),cy.e.userEngagementPriceComparisonWeights.competingPricesWeight)})),g.isRevampExpActive=this.priceCompareV2,this.isNewPCFeatureEnabled&&g.classList.add("newpc"),0===s&&this.flyoutData.common.isPane&&(this.firstCard=g),t?.promotionInformation?.rebateValue&&t?.BillingType!==r.YO.NoCharge&&(g.isPCBOffer=!0);const v=t.IntendedPrice;t.InstallmentAmount?this.setProductCardPrice(g,t,t.Price):v&&this.setProductCardPrice(g,t,v),t.InstallmentAmount&&t.InstallmentDescription&&this.setInstallmentDescription(g,t);const y=!this.flyoutData.common.isShorelineOrigination||this.flyoutData.dataLoader.GetLoadTimeDataValue("price",void 0);if(l&&v&&!t.InstallmentAmount&&y){const e=l-v+Number(t?.BillingType!==r.YO.NoCharge&&t?.promotionInformation?.rebateValue?t.promotionInformation.rebateValue:0);if(e&&e>0&&this.isAboveThreshold(l,v)){const i=this.utilities.formatPrice(e,t.PriceCurrency);g.savings=(0,T.fZ)("pcVisitedBtn",this.flyoutData.strings.commonSave,`${t.CurrencySymbol}${i}`)}v!==i||t?.promotionInformation?.rebateValue||(g.lowest=this.flyoutData.strings.pcLowestUpdated)}return g.retailer=t.SellerName,g.ariaSetSize=u.toString(),g.ariaPosInSet=(s+1).toString(),h&&h.addEventListener(Ku.e1.SeeMoreClick,(e=>{e?.detail?.totalCards&&(g.ariaSetSize=e?.detail?.totalCards.toString(),this.isCjkEnabled&&0===s&&g.focus())})),this.createImage(g,t,!1,c,d,p),this.manageClickHandler(g,t,p),h&&h.appendChild(g),this.isCjkEnabled&&g.addEventListener("keydown",(e=>{"ArrowUp"===e.key?(e.preventDefault(),"MSFT-PRODUCT-CARD"===g.previousElementSibling?.nodeName.toUpperCase()&&g.previousElementSibling.focus()):"ArrowDown"===e.key&&(e.preventDefault(),"MSFT-PRODUCT-CARD"===g.nextElementSibling?.nodeName.toUpperCase()&&g.nextElementSibling.focus())})),s===n&&o&&a&&this.flyoutData.common.currentDevice===r.AS.Desktop&&g&&g.focus(),g}numbersToRender(){const e=this.flyoutData.dataStoreModule.PriceComparisonData,t=e?.CompetingPrices;if(t&&t?.length>0){const e=t.find((e=>e.ShouldOnTop));if(e)return Math.min(Math.max(r.CS.PRICECOMPARISON,t.length),CS.MAX_OFFERS_TO_RENDER)}return r.CS.PRICECOMPARISON}setInstallmentDescription(e,t){if(t.InstallmentAmount&&t.InstallmentDescription){const i=parseFloat(t.InstallmentAmount.replace(/[^0-9.]/g,"")),n=this.utilities.formatPrice(i,t.PriceCurrency),o=(0,ne.nR)(n),r=(0,ne.Jl)(t.CurrencySymbol);let a;a="object"==typeof o?`${r}${o.dollars}`+(o.cents?`.${o.cents}`:""):`${r}${o}`;const s=parseInt(t.InstallmentDescription.replace(/[^0-9]/g,""),10);if(s){const t=this.flyoutData.common.afdMarket?.startsWith("en-")?"mo":this.flyoutData.strings.commonMonth;e.installmentDescription=`${a}/${t} x ${s}`}e.priceDescriptor=this.flyoutData.strings.commonNow}return""}setProductCardPrice(e,t,i){const n=this.utilities.formatPrice(i,t.PriceCurrency),o=(0,ne.nR)(n);e.priceCurrency=(0,ne.Jl)(t.CurrencySymbol),"object"==typeof o?(e.price=o.dollars,e.priceHundredthText=o.cents):e.price=n,e.ariaLabel=e.priceCurrency+n}isAboveThreshold(e,t){const i=e-t;return i>0&&i>=Math.ceil(.05*e)}disableNotificationHeader(){gn.SO.queueUpdate((()=>{const e=this.flyoutData.common.shopping;if(e.shadowRoot){const t=e.shadowRoot.querySelector(".header");t&&(t.style.display="none")}}))}manageClickHandler(e,t,n=!1){const o=n?i.Wm.MultiPriceComparisonNotification:i.Wm.PriceComparisonModule;e.addEventListener("click",(()=>{t.BillingType===r.YO.Backfill&&this.pcBackfillData&&(this.pcBackfillData.didClickOnOffer=!0,this.storageHandler.setStorageString(vS,JSON.stringify(this.pcBackfillData))),this.flyoutData.common.isDiscoverPane&&this.discoverTelemetryHandler.LogClickTelemetry(i.xu.PriceComparisonDiscoverClick,"Price Comparison Discover Click - competingPrice","",r.ModuleNames.PRICECOMPARISON,{clickLocation:"competingPrice"}),this.navigateToRetailer(t,o)})),e.addEventListener("mousedown",(e=>{1===e.button&&this.navigateToRetailer(t,o)}))}createImage(t,n,o,a,s,l=!1){let c;"msn.com"===n.Domain&&n.SellerName===this.msBuyDirectSeller?(c=(0,Y.Ux)("div"),c.style.maxWidth=this.priceCompareV2?"18px":"16px",c.slot="icon",c.setAttribute("aria-hidden","true"),c.innerHTML=this.assets.getBuyDirectIcon(),t.appendChild(c)):l||(c=(0,Y.Ux)("img"),this.isCjkEnabled&&this.flyoutData.common.isCjkShouldGetSafeImage&&this.pageHandlerModule.IsMessageAllowed("getSafeImage")?this.utilities.addFavIconBase64(c,t,n.FavIcon,this.pageHandlerModule):e.R.isExperimentActive(f.H.sellerIconCovIncr)&&null!=n.sellerLogo?n.sellerLogo.trim().endsWith("R3yMUU9PYeyZgRJZhriJhw")||n.sellerLogo.trim().endsWith("qK1y6LUMeErvTiiybkRf-Q")?(this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Default Icon rendered for "+n.Domain+" "+n.sellerLogo.trim(),this.phTelemetryData),c=(0,Y.Ux)("div"),c.style.maxWidth=this.priceCompareV2?"18px":"16px",c.slot="icon",c.setAttribute("aria-hidden","true"),c.innerHTML=this.assets.getDefaultGlobeIcon(),t.appendChild(c)):this.utilities.addFavIconSrc(c,t,n.sellerLogo,!0,!0):this.utilities.addFavIconSrc(c,t,n.Domain,!1,!0)),c&&(c.classList.add("imgPCFavIcon"),this.priceCompareV2&&c.classList.add("v2"));const d=(0,Y.Ux)("img");if(d.tabIndex=-1,l?this.utilities.setImageSrc(d,this.utilities.getFavIconSrc(n.Domain,18)):n.ProductImageOriginalUrl&&""!==n.ProductImageOriginalUrl?""===this.flyoutData.common.urlPrefix&&this.utilities.setImageSrc(d,n.ProductImageOriginalUrl.replace("edge://image?","")):n.ProductImageUrl&&""!==n.ProductImageUrl?this.isCjkEnabled&&this.flyoutData.common.isCjkShouldGetSafeImage&&this.pageHandlerModule.IsMessageAllowed("getSafeImage")?this.utilities.setImageSrcAndConvertToBase64(d,n.ProductImageUrl,this.pageHandlerModule):this.utilities.setImageSrc(d,n.ProductImageUrl):this.utilities.setImageSrc(d,this.flyoutData.common.resourcesEndpoint+"common/defaultProduct.svg"),!this.isNewPCFeatureEnabled&&!this.priceCompareV2){let e;this.isCjkEnabled?(e=this.utilities.createProductImage(80,80,d),e.style.borderRadius="8px"):l?(e=(0,Y.Ux)("DIV"),d.style.maxWidth="100%",e.appendChild(d),e.style.maxWidth="18px",e.style.maxHeight="18px"):e=this.utilities.createProductImage(48,48,d),e.slot="image",d.addEventListener("error",(()=>{this.utilities.setImageSrc(d,this.flyoutData.common.resourcesEndpoint+"common/defaultProduct.svg")})),t.appendChild(e)}if(""===n.ImpressionToken||!this.visibilityRequest||o||a===n.ImpressionToken||s.includes(n.ImpressionToken)||this.visibilityRequest.push(n.ImpressionToken),n.BillingType===r.YO.Paid){t.isAd=!0;const e=(0,Y.Ux)("div");e.className="divAdSlug",e.slot="adslug",e.textContent=this.flyoutData.strings.productCardAdSlugText,e.setAttribute("aria-label","Ad"),this.priceCompareV2&&e.classList.add("v3"),t.appendChild(e)}else if(n.BillingType===r.YO.Affiliated){t.isAffiliate=!0;const e=this.createAffiliateTooltip(this.flyoutData,this.flyoutData.strings.pcTooltipText);t.appendChild(e)}this.addPCAnnotations(t,n.Extensions,n,l)}createAffiliateTooltip(e,t){const i=(0,Y.Ux)("IMG");i.src=e.common.resourcesEndpoint+"/common/infoIcon.svg",i.style.width="10px",i.setAttribute("aria-hidden","true");const n=(0,Y.Ux)("div");n.setAttribute("aria-label",e.strings.pcAffiliateTooltipLabel),n.slot="hover-anchor",n.append(i);const o=(0,Y.Ux)("msft-shopping-tooltip");return t&&(o.content=t),o.className="gcTooltip",o.slot="affiliateslug",o.setAttribute("aria-hidden","true"),o.setAttribute("aria-haspopup","true"),o.setAttribute("aria-expanded","false"),o.style.setProperty("--tooltip-width","150px"),o.style.setProperty("--carat-left-offset","12px"),o.style.setProperty("text-wrap","wrap"),o.addEventListener("click",(e=>{e.stopPropagation()})),o.append(n),o}createCashbackAttribution(e,t){const i=(0,Y.Ux)("msft-attribution");i.classList.add("attrBottomAnnotation"),this.priceCompareV2&&i.classList.add("annotation-padding"),i.slot="end";const n=(0,ne.Jl)(e),o=this.flyoutData.strings.priceCompareCashback;i.textContent=(0,T.fZ)("priceCompareCashback",o,`${n}${this.utilities.formatPrice(Number(t))}`);const r=(0,Y.Ux)("div");r.slot="image";const a=(0,Y.Ux)("div");return a.slot="hover-anchor",a.innerHTML=this.assets.getCashbackAnnotationImage(),r.appendChild(a),r.appendChild(this.createCashbackTooltip(a)),i.appendChild(r),i}addPCAnnotations(t,i,n,o){const a=n.originalAdsExtensions;if(e.R.isExperimentActive(f.H.udaPriceComparison)&&a&&(n.Extensions=new Array,a.forEach((e=>{const t=ee(e,this.flyoutData.strings);t&&n.Extensions.push(t)})),i=n.Extensions),n?.promotionInformation?.rebateValue&&n?.BillingType!==r.YO.NoCharge){const e=this.createCashbackAttribution(n.CurrencySymbol,n.promotionInformation.rebateValue);t.isNoAlign=o,t.appendChild(e)}if(i&&i.length>0){let e;for(const n of i)if(n.ExtensionText===r.vu.Used||n.ExtensionText===r.vu.New||n.ExtensionText===r.vu.Refurbished){const e=(0,Y.Ux)("msft-attribution");e.textContent=n.ExtensionText,e.slot="start",t.isNoAlign=o,t.appendChild(e)}else e||(e=n);if(e&&e.ExtensionText){const i=(0,Y.Ux)("msft-attribution");i.classList.add("attrBottomAnnotation"),this.priceCompareV2&&i.classList.add("annotation-padding"),i.textContent=e.ExtensionText;const n=(0,Y.Ux)("img");let a=!1;e.ExtensionText.toLowerCase().includes(r.vu.Shipping)&&(this.utilities.setImageSrc(n,this.isNewPCFeatureEnabled||this.priceCompareV2?this.flyoutData.common.resourcesEndpoint+"priceComparison/newShippingAnnotation.png":this.flyoutData.common.resourcesEndpoint+"priceComparison/shippingAnnotation.svg"),a=!0),a&&(n.slot="image",i.appendChild(n)),i.slot="end",t.isNoAlign=o,t.appendChild(i)}}}setUpMoreInfoButton(){const e=(0,Y.Ux)("DIV");e.style.position="relative";const n=this.tooltipUtilities.createInfoIconTooltip(this.flyoutData.strings.pcTooltipText,void 0,void 0,void 0,void 0,this.isCjkEnabled);n.style.alignSelf="center",n.content=this.flyoutData.strings.pcTooltipText,n.id="txtPCTooltip";let o=0,r=0,a=!0;n.addEventListener("mouseenter",(async()=>{c()})),n.addEventListener("mouseleave",(()=>{d()})),n.addEventListener("focus",(()=>{c()})),n.addEventListener("blur",(()=>{d()}));const s=this.logModule;let l=!0;const c=()=>{if(l){if(l=!1,!(Date.now()-r>200))return;a=!0,o=Date.now();const e=new t.Z(i.xu.PriceComparisonBackfillNoticeShowMoreInfoTooltip);s.LogInfoEvent(i.R.EdgeFlyoutStatus,"Price comparison Backfill offer Notice - show more info tooltip",e)}},d=()=>{r=Date.now(),l=!0,setTimeout((()=>{if(a){a=!1,this.sendPriceComparisonDwellTimeTelemery(o,i.xu.PriceComparisonBackfillNoticeDwellTimeHover,"Price comparison Backfill offer Notice - hover time over info button");const e=new t.Z(i.xu.PriceComparisonBackfillNoticeHideMoreInfoTooltip);s.LogInfoEvent(i.R.EdgeFlyoutStatus,"Price comparison Backfill offer Notice - hide more info tooltip",e)}}),200)};return n.addEventListener("hover",(async()=>{await this.tooltipUtilities.setupTooltip(n)})),n.addEventListener("focus",(async()=>{await this.tooltipUtilities.setupTooltip(n)})),e.appendChild(n),e}sendPriceComparisonDwellTimeTelemery(e,n,o){const r=Date.now()-e,a=new t.Z(n);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,`Price comparison - ${o} - ${r} ms`,a)}async getBackfillStatementElement(){const e=(0,Y.Ux)("DIV",{slot:"section-end-content",style:"display:flex;"});await this.shouldRenderBackfillNotice()&&((0,dt.tB)(this.flyoutData)?e.appendChild(this.createBackFillFreeOffersTextForSafari()):(e.appendChild(this.createBackFillFreeOffersText()),e.append(this.createTooltip())),this.pcBackfillData.PCBackfillFirstShownTime||(this.pcBackfillData.PCBackfillFirstShownTime=Date.now(),this.storageHandler.setStorageString(vS,JSON.stringify(this.pcBackfillData)))),this.pcSection.style.overflow="unset",this.pcSection.hasSectionEndContent=!0,this.pcSection.addEventListener("click",(()=>{this.flyoutData.common.isDiscoverPane&&this.discoverTelemetryHandler.LogClickTelemetry(i.xu.PriceComparisonDiscoverClick,"Price Comparison Discover Click","",r.ModuleNames.PRICECOMPARISON)}));const n=new t.Z(i.xu.PCBackfillNoticeViewed,void 0,void 0,(0,T.S8)());return this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Price comparison Backfill offers notice shown to the user",n),e}createTooltip(){const e=(0,Y.Ux)("DIV",{className:"tooltip-container"});this.isCjkEnabled&&(e.style.margin="0");const t=this.setUpMoreInfoButton();return e.appendChild(t),e}createBackFillFreeOffersText(){const e=(0,Y.Ux)("P",{className:"backfill-paragraph"}),t=(0,Y.Ux)("span");t.textContent=this.flyoutData.strings.thirdPartCookiesText;const i=(0,Y.Ux)("a",{className:"aPCMicrosoftPrivacy"});i.setAttribute("href","#"),i.textContent=this.flyoutData.strings.commonMicrosoftPolicy,i&&i.addEventListener("click",(()=>{this.pageHandlerModule.NavigateToPrivacyStatement()}));const n=(0,Y.Ux)("text");return(0,T.B7)(n,this.flyoutData.strings.privacyConsentProvider,t,i),e.appendChild(n),e}createBackFillFreeOffersTextForSafari(){const e=(0,Y.Ux)("P",{className:"backfill-paragraph"}),t=(0,Y.Ux)("span");t.textContent=this.flyoutData.strings.thirdPartCookiesText;const i=(0,Y.Ux)("div",{style:"display: flex;"}),n=(0,Y.Ux)("a",{className:"aPCMicrosoftPrivacy"});n.setAttribute("href","#"),n.textContent=this.flyoutData.strings.commonMicrosoftPolicy,n&&n.addEventListener("click",(()=>{this.pageHandlerModule.NavigateToPrivacyStatement()})),i.appendChild(n),i.append(this.createTooltip());const o=(0,Y.Ux)("text");return(0,T.B7)(o,this.flyoutData.strings.privacyConsentProvider,t,i),e.appendChild(o),e}async shouldRenderBackfillNotice(){if(!this.pcBackfillData){const e=await this.storageHandler.getStorageString(vS);e&&(this.pcBackfillData=JSON.parse(e)),this.pcBackfillData||(this.pcBackfillData=new class{constructor(){(0,s.Z)(this,"PCBackfillFirstShownTime",void 0),(0,s.Z)(this,"didClickOnOffer",void 0)}})}return Promise.resolve((!this.pcBackfillData?.PCBackfillFirstShownTime||Date.now()-this.pcBackfillData?.PCBackfillFirstShownTime<=15552e6)&&!this.pcBackfillData?.didClickOnOffer)}getShoppingContent(){return this.buyingOptionsExp||this.buyingOptionsClientExp?bp.r.BUYING_OPTIONS:this.priceComparisonUtilities?.shouldBeInPolePosition||this.flyoutData.common.openedWith===r.Te.Auto&&this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_LOWER_PRICE_FOUND?bp.r.PRICE_COMPARE_LOWER_PRICES:bp.r.PRICE_COMPARE_BEST_PRICE}numberOfBuyingOptionsToRender(){return this.flyoutData.dataStoreModule.PriceComparisonData?.CompetingPrices?.length}async renderBuyingOptions(){const e=await(async()=>await Promise.resolve().then(o.bind(o,45101)).then((e=>e.themes)))();return(await(async()=>await Promise.resolve().then(o.bind(o,32463)).then((e=>e.setTheme)))())(this.utilities.isDarkMode()?e.edge.dark:e.edge.light),this.pcSection=this.createEdgeShoppingSection(),await this.createBuyingOptionsSection(),this.utilities.createCommonListStructure(this.pcSection,this.flyoutData.strings.newpcPriceSectionTitle,this.flyoutData.dataStoreModule.PriceComparisonData?.CompetingPrices,this.GetModuleName(),this.numberOfBuyingOptionsToRender.bind(this),(()=>{}),void 0,void 0,this.isCjkEnabled),this.pcSection}createEdgeShoppingSection(){if(this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),this.pcSection=document.createElement("msft-edge-shopping-section"),this.pcSection.id=this.sectionId,this.pcSection.seeMoreSeparate=!1,this.pcSection.style.overflow="unset",this.pcSection.hasPadding=!0,this.pcSection.hideTitle=!1,this.pcSection.isBlock=!1,this.pcSection.titleText=this.flyoutData.strings.newpcPriceSectionTitle,this.flyoutData.common.isDiscoverPane){const e=()=>{this.discoverTelemetryHandler.LogEventTelemetry(i.xu.BuyingOptionsDiscoverHover,"Buying options Discover Hover","",r.ModuleNames.PRICECOMPARISON),this.pcSection.removeEventListener("mouseover",e)};this.pcSection.addEventListener("mouseover",e)}return this.pcSection}async createBuyingOptionsSection(){await(async()=>await Promise.resolve().then(o.bind(o,55646)))(),await(async()=>await Promise.resolve().then(o.bind(o,56263)).then((e=>e.BuyingOptions)))();const e=await(async()=>await Promise.resolve().then(o.bind(o,56263)).then((e=>e.BuyingOptionsLayout)))(),n=await(async()=>await Promise.resolve().then(o.bind(o,56263)).then((e=>e.BuyingOptionsAppearance)))(),a=document.createElement("div");a.style.paddingLeft="10px",a.style.paddingRight="10px";const s=await document.createElement("commerceui-buying-options");s.showMaxRetailers=this.retailersTotalShown,s.layout=e.compact,s.appearance=n.edge,s.autoHideOverflowSwatches=!1,s.locale=this.flyoutData.common.afdMarket,s.retailersListNoDataLabel=this.flyoutData.strings.filterNoDataErrorMessage,this.filterGroup=await this.getFilterGroupData(!1),this.retailerList=await this.getRetailerListData(!1),await this.logFilters(this.filterGroup),await this.logRetailers(this.retailerList),s.data={filterGroup:this.filterGroup,retailerList:this.retailerList};const l=this.flyoutData.dataStoreModule.PriceComparisonData?.buyingOptions;s&&(this.edgeImpressionId=this.flyoutData.dataLoader.GetLoadTimeDataValue("impressionId",""),s.onretailerclick=(e,t)=>{this.flyoutData.common.isDiscoverPane&&this.discoverTelemetryHandler.LogClickTelemetry(i.xu.BuyingOptionsDiscoverClick,"Buying Options Retailer Clicked","",r.ModuleNames.PRICECOMPARISON);const n=this.flyoutData.dataStoreModule.PriceComparisonData?.CompetingPrices[e];n&&this.dataValidationUtilities.writeValidationDataToStorage(n.Price.toString(),n.Description,this.GetModuleName(),n.Url);const o=new W.Z(i.$S.NavigatedToAnotherRetailer,this.telemetryUtilities.setContentViewed(this.GetModuleName()),this.flyoutData.common.domain);o.Metadata=JSON.stringify({BillingType:n?.BillingType,popupOriginationEnum:this.flyoutData.common.popupOrigination,offerId:n?.globalOfferId,price:n?.LowPrice??n?.Price,offerUrl:n?.Url,seller:n?.SellerName,currency:n?.CurrencySymbol,offerDomain:n?.Domain}),this.pageHandlerModule.RecordAsUserAction(K.bS.NAVIGATE_TO_RETAILER),this.pageHandlerModule.RecordAsUserEngagement(q.FV.NAVIGATE_TO_RETAILER,this.flyoutData.common.popupOrigination),this.logModule.LogInfoEvent(i.R.ButtonClick,"Price comparison see more retailers",o),s.handleNavigation=!0},s.onretailerhover=(e,n)=>{const o=new t.Z(i.xu.BuyingOptionsRetailerHover);o.Metadata=JSON.stringify({retailerIndex:e,domain:(0,T.S8)()}),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Buying Options Retailer Hover",o),this.pageHandlerModule.RecordAsUserAction(K.bS.BUYING_OPTIONS_RETAILER_HOVER),this.pageHandlerModule.RecordAsUserEngagement(q.FV.BUYING_OPTIONS_RETAILER_HOVER,this.flyoutData.common.popupOrigination),s.handleNavigation=!0},s.onfiltergroupselectionchange=async(e,n)=>{this.setSelectedIndex(e);const o=new W.Z(i.$S.BuyingOptionsFilterSelectionClicked,this.telemetryUtilities.setContentViewed(this.GetModuleName()));o.Metadata=JSON.stringify({productId:l?.productId,selectedFilters:e}),this.logModule.LogInfoEvent(i.R.ButtonClick,"Buying options filters selection changed",o),this.pageHandlerModule.RecordAsUserAction(K.bS.BUYING_OPTIONS_FILTERCHANGE),this.pageHandlerModule.RecordAsUserEngagement(q.FV.BUYING_OPTIONS_FILTERCHANGE,this.flyoutData.common.popupOrigination),this.retailersTotalShown=3,s.showMaxRetailers=this.retailersTotalShown,yS.getBuyingOptions(l?.productId,e,this.edgeImpressionId).then((async e=>{this.retailerList=await this.getRetailerListData(!0,this.getFreeOffers(e)),s.hideShowMoreRetailers=!(this.retailerList.retailers.length>this.retailersTotalShown);const t=await this.getFilterGroupData(!0,e.userFacingAttributes);t.filters.length>0&&(this.filterGroup=t),s.data={filterGroup:this.filterGroup,retailerList:this.retailerList}})).catch((n=>{const o=new t.Z(i.xu.OnErrorInvoked);o.Metadata=JSON.stringify({error:n,productId:l?.productId,selectedFilters:e}),this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,n,o)}))},s.onshowmoreretailersclick=e=>{if(this.retailerList&&this.retailerList.retailers){if(this.visibilityRequest.length>0&&this.retailersTotalShown<this.retailerList.retailers.length){let e=this.retailersTotalShown-1,t=this.retailersTotalShown+this.numberOfRetailersPerClick-1;this.pageHandlerModule.SendBingVisibilityRequest(this.visibilityRequest.slice(e,t))}this.retailersTotalShown+=this.numberOfRetailersPerClick,s.showMaxRetailers=this.retailersTotalShown<this.retailerList.retailers.length?this.retailersTotalShown:this.retailerList.retailers.length;const e=new W.Z(i.$S.SeeMoreRetailers,this.telemetryUtilities.setContentViewed(this.GetModuleName()));e.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.pageHandlerModule.RecordAsUserAction(K.bS.VIEW_MORE_RETAILERS),this.logModule.LogInfoEvent(i.R.ButtonClick,"Buying options see more retailers",e)}}),a.appendChild(s),this.pcSection&&this.pcSection.appendChild(a)}getFreeOffers(e){if(this.freeOffers=[],e&&e.freeOfferValue.length>0){for(const t of e.freeOfferValue){const e=new le.Z(t);e.IntendedPrice=ie(new le.Z(t)),this.freeOffers.push(e)}this.priceComparisonUtilities=new gS.Z(this.flyoutData.common.openedWith,this.freeOffers,this.flyoutData.dataStoreModule.PriceComparisonData?.Price,this.flyoutData.common.popupOrigination,this.flyoutData.common.pageLocale)}return this.freeOffers}getSelectedIndex(e){if(e)for(let t=0;t<e.length;t++)if(e[t].isSelected)return t;return-1}setSelectedIndex(e){if(e){const t="filters";for(let i=0;i<this.filterGroup[t]?.length;i++){const n=this.filterGroup[t][i]?.label?.toLowerCase(),o=e[n]?.value?.toLowerCase();if(o){let e=-1;for(let n=0;n<this.filterGroup[t][i]?.items.length;n++){const r=this.filterGroup[t][i]?.items[n]?.value?.toLowerCase();if(r&&r===o){this.filterGroup[t][i].items[n].selected=!0,e=n;break}this.filterGroup[t][i].items[n].selected=!1}this.filterGroup[t][i].selectedIndex=e}}}}async getFilterGroupData(e,n=void 0){const o=e?n?.attributes:this.flyoutData.dataStoreModule.PriceComparisonData?.buyingOptions?.userFacingAttributes?.attributes;if(void 0===o||0===o.length){const e=new t.Z(i.xu.BuyingOptionsNoFilter);return e.Metadata=JSON.stringify({filterAttributes:o,domain:(0,T.S8)()}),this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,"Buying Options No Filters",e),Promise.resolve({filters:[]})}return Promise.resolve({filters:o?.map((t=>({id:t.id,label:t.name,type:"Visual"===t.filterAttributeType?"swatches":"dropdown",selectedIndex:this.getSelectedIndex(t.filterValues),placeholderText:"Select",showLabelValue:"Visual"===t.filterAttributeType,rowMaxItems:"Visual"===t.filterAttributeType?8:0,items:t.filterValues.map((t=>({label:t.value,value:t.value,selected:t.isSelected,disabled:!(!0===t.isActive),imgSrc:e?this.getThumbnailUrl(t.imageThumbnailId):this.getThumbnailUrl(t.thumbnailId)})))})))})}getThumbnailUrl(e){return e?"https://www.bing.com/"+e:null}async getRetailerListData(e,n=void 0){const o=e?n:this.flyoutData.dataStoreModule.PriceComparisonData?.CompetingPrices;if(void 0===o||0===o.length){const o=new t.Z(i.xu.BuyingOptionsNoRetailer);return o.Metadata=JSON.stringify({isFilterChanged:e,buyingOptions:n,offers:this.flyoutData.dataStoreModule.PriceComparisonData?.CompetingPrices,domain:(0,T.S8)()}),this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,"Buying Options No Retailer",o),Promise.resolve({retailers:[]})}{const e=o?.map((async e=>(this.addVisibilityRequest(e),{item:{name:e.SellerName,title:e.Domain,imgUrl:e.sellerLogo?e.sellerLogo:null,description:e.Description,advertisement:e.BillingType===r.YO.Paid,url:e.Url,target:"_blank",aria:{label:e.Domain,description:e.Description},metadata:await this.getMetadata(e)},price:{currentPrice:this.getPrice(e),installmentsPrice:e.InstallmentAmount?this.extractNumberFromString(e.InstallmentAmount):null,installmentsPerItemLabel:e.InstallmentDescription?this.getInstallmentInfoDescription(e.InstallmentAmount,e.InstallmentDescription):null,isLowestPrice:this.isLowestPrice(e)?this.flyoutData.strings.pcLowestUpdated:null,saveLabel:this.getSaveLabel(e,e.CurrencySymbol)}})));return{retailers:await Promise.all(e)}}}getPrice(e){return e.InstallmentAmount?e.Price:e.IntendedPrice?e.IntendedPrice:e.Price}addVisibilityRequest(e){const t=this.stateManagement.getState(Ku.IY.pcLowestPriceImpression),i=this.stateManagement.getState(Ku.IY.multiPcImpressions)??[];""!==e.ImpressionToken&&this.visibilityRequest&&t!==e.ImpressionToken&&!i.includes(e.ImpressionToken)&&this.visibilityRequest.push(e.ImpressionToken)}extractNumberFromString(e){const t=e.match(/\d+(\.\d+)?/);return t?parseFloat(t[0]):null}getInstallmentInfoDescription(e,t){const i=parseInt(t.replace(/[^0-9]/g,""),10);if(i)return`${this.flyoutData.common.afdMarket?.startsWith("en-")?"mo":this.flyoutData.strings.commonMonth} x ${i}`}getSaveLabel(e,t){let i;const n=e.IntendedPrice,o=e.Price;if(o&&n&&!e.InstallmentAmount){const t=o-n+Number(e?.BillingType!==r.YO.NoCharge&&e?.promotionInformation?.rebateValue?e.promotionInformation.rebateValue:0);if(t&&t>0&&this.isAboveThreshold(o,n)){const n=this.utilities.formatPrice(t,e.PriceCurrency);i=(0,T.fZ)("pcVisitedBtn",this.flyoutData.strings.commonSave,`${e.CurrencySymbol}${n}`)}}return i}async getMetadata(e){const t=[],i=this.getExtensions(e),n=await this.getFreeShippingAnnotation(i);null!==n&&t.push(n);const o=await this.getCashbackAnnotation(e);return null!==o&&t.push(o),Promise.resolve(t)}getExtensions(t){const i=t.originalAdsExtensions;return e.R.isExperimentActive(f.H.udaPriceComparison)&&i&&(t.Extensions=new Array,i.forEach((e=>{const i=ee(e,this.flyoutData.strings);i&&t.Extensions.push(i)}))),t.Extensions}async getFreeShippingAnnotation(e){let t;if(e&&e.length>0){let i;for(const t of e)t.ExtensionText===r.vu.Used||t.ExtensionText===r.vu.New||t.ExtensionText===r.vu.Refurbished||i||(i=t);if(i&&i.ExtensionText&&(t=i.ExtensionText),t&&""!==t.trim()){const e={label:t,icon:"shipping"};return Promise.resolve(e)}}return Promise.resolve(null)}async getCashbackAnnotation(e){if(e?.promotionInformation?.rebateValue&&e?.BillingType!==r.YO.NoCharge){const t=(0,ne.Jl)(e.CurrencySymbol),i=this.flyoutData.strings.priceCompareCashback,n={label:(0,T.fZ)("priceCompareCashback",i,`${t}${this.utilities.formatPrice(Number(e.promotionInformation.rebateValue))}`),icon:"cashback"};return Promise.resolve(n)}return Promise.resolve(null)}isLowestPrice(e){if(e.IntendedPrice===this.priceComparisonUtilities.lowestPrice&&!e?.promotionInformation?.rebateValue)return!0}doCFLogging(){this.discoverTelemetryHandler.LogEventTelemetry(i.xu.BuyingOptionsCFLog,"Buying options CF logging","",r.ModuleNames.PRICECOMPARISON)}async logFilters(e){if(e&&e.filters&&e.filters.length>0){const e=new t.Z(i.xu.BuyingOptionsFilters);e.Metadata=JSON.stringify({domain:(0,T.S8)()}),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Buying Options Filters",e)}}async logRetailers(e){if(e&&e.retailers&&e.retailers.length>0){const e=new t.Z(i.xu.BuyingOptionsRetailers);e.Metadata=JSON.stringify({domain:(0,T.S8)()}),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Buying Options Retailers",e)}}}(0,s.Z)(CS,"MAX_OFFERS_TO_RENDER",8);var bS=CS,SS=o(11232),xS=class{constructor(e){(0,s.Z)(this,"flyoutData",void 0),this.flyoutData=e}shouldRenderNotification(e){const t=this.flyoutData.dataStoreModule.PriceComparisonData,i=new gS.Z(this.flyoutData.common.openedWith,this.flyoutData.dataStoreModule.PriceComparisonData?.CompetingPrices,this.flyoutData.dataStoreModule.PriceComparisonData?.Price,this.flyoutData.common.popupOrigination,this.flyoutData.common.pageLocale),n=t?.segment?.toLowerCase();if(n===r.VG.AUTOS||n===r.VG.EMPTYAUTOSSEGMENT)return Promise.resolve(!1);if(t&&!this.flyoutData.common.seeInfoFromPCNotification&&(e?i.shouldRenderCompositeNotification:i.shouldRenderPriceComparisonNotification))return Promise.resolve(!0);if(!e){let e=!1;try{e="3"===new URL(this.flyoutData.common.lastCommittedURL).searchParams.get("bing_shopping_campaign_guid")}catch(e){}if(this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_BING_CAMPAIGN&&e)return Promise.resolve(!0)}return Promise.resolve(!1)}};class TS{constructor(e,t,i){this.flyoutData=e,this.priceComprisonModule=t,this.utilities=i}RenderNotification(){const e=this.priceComprisonModule.renderHtmlElement(),t=this.utilities.createNotificationModule(e,this.GetNotificationName(),this);return Promise.resolve(t)}ShouldRenderNotification(){const e=this.flyoutData.dataStoreModule.PriceComparisonData,t=!(this.flyoutData.common.openedWith!==r.Te.Hover||this.flyoutData.common.popupOrigination!==u.sR.HOVER_BUTTON_SHOW_FLYOUT||!e?.CompetingPrices);return Promise.resolve(t)}GetNotificationName(){return r.sM.PRICECOMPARISON}PostProcessingNotification(e,t){"MSFT-EDGE-SHOPPING-SECTION"!==t.previousElementSibling?.tagName?.toUpperCase()&&(t.expanded=!0)}GetPopupOriginationList(){return[u.sR.HOVER_BUTTON_SHOW_FLYOUT]}}var wS=class extends bS{constructor(t,i,n){super(t,i,n),(0,s.Z)(this,"bestOffer",void 0),(0,s.Z)(this,"formattedSavings",void 0),(0,s.Z)(this,"productTrackingViewUtilities",void 0),(0,s.Z)(this,"priceComprisonCjkImpl",void 0),(0,s.Z)(this,"isPCCashbackV2",!1),this.flyoutData=i,this.utilities=n.viewModulesUtilities,this.logModule=n.logModule,this.pageHandlerModule=n.pageHandlerModule,this.stateManagement=t,this.assets=new mS,this.productTrackingViewUtilities=new Ju(n,i,t),i.common.isCJKEnabled&&(this.priceComprisonCjkImpl=new TS(i,this,this.utilities)),this.telemetryUtilities=n.telemetryHandler,this.isPCCashbackV2=Boolean(e.R.getServiceExperimentValue(f.H.pcNotificationCashbackV2))}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_LOWER_PRICE_FOUND,u.sR.HOVER_BUTTON_SHOW_FLYOUT]}PostProcessingNotification(e,t){if(this.bestOffer){const e=this.createNotificationFooter(t,this.bestOffer,this.formattedSavings);this.flyoutData.common.shopping.appendChild(e)}this.priceComprisonCjkImpl?.PostProcessingNotification(e,t)}RenderNotification(){if(this.priceComprisonCjkImpl)return this.priceComprisonCjkImpl.RenderNotification();const n=this.flyoutData.dataStoreModule.PriceComparisonData,o=n?.autoshowOffers;if(o&&o.length>=1&&this.pageHandlerModule.TriggerExperiment(f.H.pcAutoshowAvailable),o&&o.length>=2&&(this.pageHandlerModule.TriggerExperiment(f.H.PCDouble),e.R.isExperimentActive(f.H.PCDouble))){const e=this.RenderMultiPCNotification();if(e)return this.stateManagement.setState(Ku.IY.multiPcImpressions,[o[0].ImpressionToken,o[1].ImpressionToken]),this.pageHandlerModule.SendBingVisibilityRequest(this.visibilityRequest),Promise.resolve(e)}this.pageHandlerModule.TriggerExperiment(f.H.PCOutOfStock),this.flyoutData.common.shopping.classList.add("noSections"),this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());const a=this.flyoutData.common.lastCommittedURL,s=Ju.shouldRenderProductTrackingUtilities(a,this.flyoutData.dataStoreModule.ProductTrackingData,this.flyoutData.common.market);if(n&&s&&this.renderTrackingToggle(n).then((e=>{e&&this.flyoutData.common.shopping.appendChild(e)})),e.R.isExperimentActive(f.H.PCOutOfStock)){const e=this.flyoutData?.common?.extractedEntity,t=e?.entity?.out_of_stock;if(t){const t=e?.title,i=e?.image_url||e?.entity?.image,n=this.flyoutData?.dataStoreModule?.PriceComparisonData?.CompetingPrices,o=n&&n.length>0;if(t&&i&&o){const e=Q(n);if(e){const t=X(e,this.flyoutData.strings,this.utilities.getFavIconSrc(e.Domain,24),this.flyoutData.common.resourcesEndpoint+"priceComparison/adSlug.png",this.flyoutData.common.isPaneEnabled&&n.length>1,this.utilities.formatPrice.bind(this.utilities),J.bind(this,e),this.handleSeeMoreOffersClick.bind(this)),i=this.utilities.createNotificationModule(t,this.GetNotificationName(),this);return Promise.resolve(i)}}}}if(n&&n.Price&&n.CompetingPrices&&n.CompetingPrices.length>0){let o=this.priceComparisonUtilities.lowestPrice;if(this.bestOffer=this.priceComparisonUtilities.bestOffer,!this.bestOffer){o=n.Price;for(const e of n.CompetingPrices){const t=e.IntendedPrice;t&&t<o&&(o=t,this.bestOffer=e)}}const a=o;if(this.bestOffer&&a){const o=n.Price-a,s=this.utilities.formatPrice(o,this.bestOffer.PriceCurrency);if(o<=0||"0.00"===s||"0"===s)return this.pageHandlerModule.DismissPopup(),Promise.resolve(null);if(o>0){const l=(0,Y.Ux)("DIV",{style:"width: 100%;"});let c;const d=this.bestOffer?.promotionInformation?.rebateValue&&this.bestOffer?.BillingType!==r.YO.NoCharge;let u=!1;c=(0,Y.Ux)("msft-notification-header"),c.title=this.flyoutData.strings.commonSaveSimple,e.R.isExperimentActive(f.H.communityInsightsPC)&&(c.productInsights=this.flyoutData.dataStoreModule.ProductInsightsData?.TopInsight||"");let h="$";if(d){c.hasCashback=!0;const e=Number(this.bestOffer?.promotionInformation.rebateValue);this.isPCCashbackV2&&e<o&&(u=!0,c.isAdditionalCashback=u),this.isPCCashbackV2&&u&&(c.title=this.flyoutData.strings.totalSavings)}if(this.isPCCashbackV2&&(c.v2Design=!0),this.bestOffer.CurrencySymbol&&(h=this.bestOffer.CurrencySymbol),c.savings=`${h}${s}`,this.isPCCashbackV2&&d&&!u){c.useSlotTitle=!0;const e=this.createCashbackV2Title(this.bestOffer);c.append(e)}if(this.bestOffer.SellerName){let t;if(c.retailer=this.bestOffer.SellerName,this.isPCCashbackV2&&(c.retailer=(0,T.fZ)(this.flyoutData.strings.gcbOnMerchantName,this.flyoutData.strings.gcbOnMerchantName,this.bestOffer.SellerName)),"msn.com"===this.bestOffer.Domain&&this.bestOffer.SellerName===this.msBuyDirectSeller?(t=(0,Y.Ux)("div"),t.style.maxWidth="16px",t.slot="icon",t.setAttribute("aria-hidden","true"),t.innerHTML=this.assets.getBuyDirectIcon(),c.appendChild(t)):(t=(0,Y.Ux)("IMG"),t.slot="icon",e.R.isExperimentActive(f.H.sellerIconCovIncr)&&null!=this.bestOffer.sellerLogo?this.bestOffer.sellerLogo.trim().endsWith("R3yMUU9PYeyZgRJZhriJhw")?(t=(0,Y.Ux)("div"),t.style.maxWidth="16px",t.slot="icon",t.setAttribute("aria-hidden","true"),t.innerHTML=this.assets.getDefaultGlobeIcon(),c.appendChild(t)):this.utilities.addFavIconSrc(t,c,this.bestOffer.sellerLogo,!0,!0):this.utilities.addFavIconSrc(t,c,this.bestOffer.Domain,!1,!0)),this.bestOffer.BillingType===r.YO.Paid)if(c.isAd=!0,this.isPCCashbackV2){const e=(0,Y.Ux)("div");e.className="divAdSlug v2",e.slot="adslug",e.textContent=this.flyoutData.strings.productCardAdSlugText,e.style.marginLeft="6px",c.appendChild(e)}else{const e=this.createAdsSlug();e.slot="adslug",c.appendChild(e)}}if(d&&(!this.isPCCashbackV2||u)){const e=(0,Y.Ux)("msft-attribution");let t;e.slot="cbtext",t=this.flyoutData.strings.priceCompareCashBackShort;let i=(0,Y.Ux)("div");i.slot="cbicon",i.style.display="flex",i.style.alignItems="center";const n=(0,Y.Ux)("div");n.style.position="relative",n.style.display="flex";const o=`${this.bestOffer.CurrencySymbol}${this.utilities.formatPrice(Number(this.bestOffer.promotionInformation.rebateValue))}`,r=100*Number(this.bestOffer.promotionInformation.rebateValue)/this.bestOffer.IntendedPrice;let a=`${Math.round(r)}%`;0===r&&(a=o);const s=(0,T.fZ)("priceCompareCashBackShort",t,a),l=this.utilities.createCommissionArrow(this.isPCCashbackV2?o:s,!1,zu.h.Small);if(n.appendChild(l),i.appendChild(n),i.appendChild(this.createCashbackTooltip(n)),this.isPCCashbackV2&&u){const e=(0,Y.Ux)("div");e.slot="cbicon",e.style.display="flex",e.style.gap="6px",e.style.alignItems="center",(0,T.B7)(e,this.flyoutData.strings.productTrackingCashbackOfferValue,i),i=e}c.appendChild(e),c.appendChild(i),c.hasCashback=!0}const p=(0,Y.Ux)("IMG");let g;if(d){const e=this.isPCCashbackV2?88:61;g=this.utilities.createProductImage(e,e,p,this.bestOffer.Description),g.style.placeSelf="start"}else g=this.utilities.createProductImage(88,88,p,this.bestOffer.Description);g.style.position="relative";let m=this.bestOffer.ProductImageUrl?.replace("w=66&h=66","");""===this.flyoutData.common.urlPrefix&&m&&(m=m.replace("edge://image?","")),this.utilities.setImageSrc(p,m);const v=(0,Y.Ux)("DIV",{style:"position: absolute;\n bottom: 4px;\n left: 4px;\n display: flex;\n justify-content: center;\n align-items: center;\n background: rgba(255, 255, 255, 0.8);\n backdrop-filter: blur(10px);\n border-radius: 4px;\n padding: 4px;\n color: #000000"}),y=(0,Y.Ux)("SPAN");y.textContent=`${this.bestOffer.CurrencySymbol}${this.utilities.formatPrice(this.bestOffer.IntendedPrice,this.bestOffer.PriceCurrency)}`,v.appendChild(y),g.appendChild(v),g.slot="image",c.appendChild(g),l.appendChild(c),c.setAttribute("role","button"),e.R.isExperimentActive(f.H.pcClickoutReverse)?this.flyoutData.common.isPaneEnabled&&(c.setAttribute("role","button"),c.addEventListener("click",(()=>{const e=new W.Z(i.$S.HeroImageClick,this.telemetryUtilities.setContentViewed(this.GetModuleName()));e.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.logModule.LogInfoEvent(i.R.ButtonClick,"Price comparison hero image clicked",e),this.pageHandlerModule.OpenPane(this.flyoutData.common.popupOrigination)}))):c.addEventListener("click",(()=>{this.bestOffer&&this.flyoutData.common.currentDevice===r.AS.Desktop&&this.navigateToRetailer(this.bestOffer,i.Wm.PriceComparisonNotificationHeader,ju.$.NEW_FOREGROUND_TAB)})),l.slot="header-content",""!==this.bestOffer.ImpressionToken&&this.visibilityRequest&&(this.stateManagement.setState(Ku.IY.pcLowestPriceImpression,this.bestOffer.ImpressionToken),this.visibilityRequest.push(this.bestOffer.ImpressionToken),this.pageHandlerModule.SendBingVisibilityRequest(this.visibilityRequest));const C=this.utilities.createNotificationModule(l,this.GetNotificationName(),this),b=new t.Z(i.xu.YouCanSave,n.CompetingPrices.length,parseFloat(o.toFixed(2))),S={};return d&&(S.IsCashbackOfferPresent=!0,S.AdsTraceId=n.adsTraceId,S.CashbackAmount=Number(this.bestOffer?.promotionInformation?.rebateValue??0)),S.domain=this.flyoutData.common.domain,S.url=this.flyoutData.common.currentUrl,S.offerId=this.bestOffer?.globalOfferId,S.offerUrl=this.bestOffer?.Url,S.seller=this.bestOffer?.SellerName,S.currency=this.bestOffer?.CurrencySymbol,S.offerDomain=this.bestOffer?.Domain,S.billingType=this.bestOffer?.BillingType,S.bestOfferPrice=a,S.extractedPrice=n.Price,b.Metadata=JSON.stringify(S),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Price comparison Notificatoin - user can save money",b),Promise.resolve(C)}}}return Promise.resolve(null)}ShouldRenderNotification(){return this.priceComprisonCjkImpl?this.priceComprisonCjkImpl.ShouldRenderNotification():new xS(this.flyoutData).shouldRenderNotification(!1)}GetNotificationName(){return r.sM.PRICECOMPARISON}RenderMultiPCNotification(){const e=this.flyoutData?.dataStoreModule?.PriceComparisonData,t=e?.autoshowOffers;if(e&&t&&t.length>=2){const i=(0,Y.Ux)("DIV",{style:"width: 100%;"});i.slot="header-content";const n=(0,Y.Ux)("msft-multi-price-comparison");n.title=this.flyoutData.strings.pcBetterPriceFound,n.seeAllOffersText=this.flyoutData.strings.pcSeeAllOffers,n.openPaneSeeMoreOffers=this.handleSeeMoreOffersClick.bind(this);const o=this.createPriceComparisonTile(t[0],t[0].Price,0,!1,!1,0,e.Price,"",[],2,void 0,!0);o.isFirst=!0,o.isNotification=!0,o.slot="tile1";const r=this.createPriceComparisonTile(t[1],t[0].Price,0,!1,!1,1,e.Price,"",[],2,void 0,!0);return r.slot="tile2",r.isNotification=!0,n.appendChild(o),n.appendChild(r),i.appendChild(n),this.flyoutData.common.shopping.classList.add("noSections"),this.utilities.createNotificationModule(i,this.GetNotificationName(),this)}}createNotificationFooter(t,n,o){let a;a=(0,Y.Ux)("DIV",{style:"width: calc(100% - 32px); display: grid; grid-template-columns: 60% auto; grid-gap: 10px;"}),a.style.display="flex",a.style.flexDirection="column",a.style.marginTop="12px",a.style.gap="8px",a.classList.add("lateralMargin"),a.id="divNotificationActions",a.slot="actions";const s=(0,Y.lw)(this.utilities);s.style.width="100%",s.style.marginTop="0px",s.textContent=this.flyoutData.strings.pcNotificationVisitItem,e.R.getServiceExperimentValue(f.H.pcNotificationButtonText)===Yu.lA.ShopAt&&this.bestOffer?.SellerName&&(s.textContent=(0,T.fZ)(this.flyoutData.strings.pcNotificationShopAt,this.flyoutData.strings.pcNotificationShopAt,this.bestOffer.SellerName));const l=this.flyoutData.common.currentDevice;s.addEventListener("click",(()=>{l===r.AS.Desktop&&this.navigateToRetailer(n,i.Wm.PriceComparisonNotificationVisitItem,ju.$.NEW_FOREGROUND_TAB)})),a.appendChild(s);const c=(0,Y.Ux)("fluent-anchor",{style:"\n width: 100%;\n overflow: hidden;\n overflow-wrap: break-word;\n display: -webkit-box;\n -webkit-line-clamp: 1;\n -webkit-box-orient: vertical;\n display: flex;\n height: auto;\n justify-content: center;\n font-size: 14px;\n line-height: 20px;"});c.setAttribute("appearance","lightweight"),c.href="#",c.style.placeSelf="center",c.title=this.flyoutData.strings.pcNotificationSeeMoreInfo,c.textContent=this.flyoutData.strings.pcNotificationSeeMoreInfo,c.addEventListener("click",(()=>{this.handleSeeMoreInfoNotificationClick(t)}));const d=this.flyoutData.dataStoreModule.PriceComparisonData,u=this.flyoutData.common.lastCommittedURL,h=Ju.shouldRenderProductTrackingUtilities(u,this.flyoutData.dataStoreModule.ProductTrackingData,this.flyoutData.common.market),p=d&&d.Price&&(d.currentProductTitle||d.entityName);return!e.R.isExperimentActive(f.H.pcSeeMore)&&h&&p||a.appendChild(c),a}handleSeeMoreInfoNotificationClick(e){let t=!1;const n=new W.Z(i.$S.SeeMoreOffers,this.telemetryUtilities.setContentViewed(this.GetModuleName()));if(this.logModule.LogInfoEvent(i.R.ButtonClick,"Click on see more offers",n),this.flyoutData.common.isPaneEnabled&&(t=this.pageHandlerModule.OpenPane(this.flyoutData.common.popupOrigination)),!t){e.remove();const t=this.flyoutData.common.shopping.querySelector("#divNotificationActions");t&&t.remove();const i=this.flyoutData.common.shopping.querySelector("#divDisclaimer");i&&i.remove();const n=document.querySelectorAll("msft-edge-shopping");if(n&&n.length>0)for(const e of n)e.remove();const o=this.flyoutData.common.shopping.querySelector("#footerDiv");o&&o.remove(),this.flyoutData.common.seeInfoFromPCNotification=!0,gn.SO.queueUpdate((()=>{this.utilities.trapFlyoutFocusMac();const e=document.querySelector("#divContentWrapper");e&&(e.style.width="360px");const t=new CustomEvent(Ku.e1.CreateModules,{detail:{flyoutWrapper:e}});this.stateManagement.dispatchEvent(t)}))}}handleSeeMoreOffersClick(){const e=new W.Z(i.$S.SeeMoreOffers,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"Click on see more offers",e),this.pageHandlerModule.OpenPane(this.flyoutData.common.popupOrigination)}createAdsSlug(){const e=(0,Y.Ux)("IMG");return e.src=this.flyoutData.common.resourcesEndpoint+"priceComparison/adSlug.png",e.style.marginLeft="8px",e.style.width="22px",e.style.height="14px",e.setAttribute("aria-label","Ad"),e}async renderTrackingToggle(e){if(!e||!e.currentProductTitle&&!e.entityName||!e.Price)return;const t=this.flyoutData.common.lastCommittedURL,i=e.currentProductTitle||e.entityName,n=e.currentImageUrl,o=new SS.Z(i,n,"");o.ProductUrl=t,o.price=e?.Price.toString();const r=Boolean(this.flyoutData.common.extractedEntity?.entity?.out_of_stock)||await this.productTrackingViewUtilities.checkIsOutOfStock();return await this.productTrackingViewUtilities.createTrackingToggleSection(o,r,this.GetNotificationName(),!0)}createCashbackV2Title(e){const t=(0,Y.Ux)("div"),i=(0,Y.Ux)("div");i.textContent=this.flyoutData.strings.cbFeatureName;const n=(0,Y.Ux)("div"),o=(0,Y.Ux)("span");o.style.position="relative",o.style.display="flex";const r=e.promotionInformation.rebateValue,a=this.utilities.createCommissionArrow(r,!0,zu.h.Medium,void 0,e.CurrencySymbol);o.appendChild(a),n.appendChild(o),n.appendChild(this.createCashbackTooltip(o));const s=(0,Y.Ux)("div");return s.style.display="inline-flex",s.style.gap="6px",s.style.alignItems="center",(0,T.B7)(s,this.flyoutData.strings.gcGet,n),t.append(s),t.append(i),t.style.fontSize="18px",t.style.lineHeight="30px",t.slot="slotTitle",t}};function OS(e,t){return null==e||null==t?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function PS(e,t){return null==e||null==t?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function AS(e){let t,i,n;function o(e,n,o=0,r=e.length){if(o<r){if(0!==t(n,n))return r;do{const t=o+r>>>1;i(e[t],n)<0?o=t+1:r=t}while(o<r)}return o}return 2!==e.length?(t=OS,i=(t,i)=>OS(e(t),i),n=(t,i)=>e(t)-i):(t=e===OS||e===PS?e:ES,i=e,n=e),{left:o,center:function(e,t,i=0,r=e.length){const a=o(e,t,i,r-1);return a>i&&n(e[a-1],t)>-n(e[a],t)?a-1:a},right:function(e,n,o=0,r=e.length){if(o<r){if(0!==t(n,n))return r;do{const t=o+r>>>1;i(e[t],n)<=0?o=t+1:r=t}while(o<r)}return o}}}function ES(){return 0}function kS(e,t){let i;if(void 0===t)for(const t of e)null!=t&&(i<t||void 0===i&&t>=t)&&(i=t);else{let n=-1;for(let o of e)null!=(o=t(o,++n,e))&&(i<o||void 0===i&&o>=o)&&(i=o)}return i}function IS(e,t){let i;if(void 0===t)for(const t of e)null!=t&&(i>t||void 0===i&&t>=t)&&(i=t);else{let n=-1;for(let o of e)null!=(o=t(o,++n,e))&&(i>o||void 0===i&&o>=o)&&(i=o)}return i}function DS(){}function _S(e){return null==e?DS:function(){return this.querySelector(e)}}function NS(){return[]}function RS(e){return null==e?NS:function(){return this.querySelectorAll(e)}}function MS(e){return function(){return this.matches(e)}}function LS(e){return function(t){return t.matches(e)}}var BS=Array.prototype.find;function FS(){return this.firstElementChild}var US=Array.prototype.filter;function HS(){return Array.from(this.children)}function $S(e){return new Array(e.length)}function ZS(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}function VS(e,t,i,n,o,r){for(var a,s=0,l=t.length,c=r.length;s<c;++s)(a=t[s])?(a.__data__=r[s],n[s]=a):i[s]=new ZS(e,r[s]);for(;s<l;++s)(a=t[s])&&(o[s]=a)}function GS(e,t,i,n,o,r,a){var s,l,c,d=new Map,u=t.length,h=r.length,p=new Array(u);for(s=0;s<u;++s)(l=t[s])&&(p[s]=c=a.call(l,l.__data__,s,t)+"",d.has(c)?o[s]=l:d.set(c,l));for(s=0;s<h;++s)c=a.call(e,r[s],s,r)+"",(l=d.get(c))?(n[s]=l,l.__data__=r[s],d.delete(c)):i[s]=new ZS(e,r[s]);for(s=0;s<u;++s)(l=t[s])&&d.get(p[s])===l&&(o[s]=l)}function jS(e){return e.__data__}function zS(e){return"object"==typeof e&&"length"in e?e:Array.from(e)}function WS(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}ZS.prototype={constructor:ZS,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}};var KS="http://www.w3.org/1999/xhtml",qS={svg:"http://www.w3.org/2000/svg",xhtml:KS,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function YS(e){var t=e+="",i=t.indexOf(":");return i>=0&&"xmlns"!==(t=e.slice(0,i))&&(e=e.slice(i+1)),qS.hasOwnProperty(t)?{space:qS[t],local:e}:e}function XS(e){return function(){this.removeAttribute(e)}}function JS(e){return function(){this.removeAttributeNS(e.space,e.local)}}function QS(e,t){return function(){this.setAttribute(e,t)}}function ex(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function tx(e,t){return function(){var i=t.apply(this,arguments);null==i?this.removeAttribute(e):this.setAttribute(e,i)}}function ix(e,t){return function(){var i=t.apply(this,arguments);null==i?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,i)}}function nx(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function ox(e){return function(){this.style.removeProperty(e)}}function rx(e,t,i){return function(){this.style.setProperty(e,t,i)}}function ax(e,t,i){return function(){var n=t.apply(this,arguments);null==n?this.style.removeProperty(e):this.style.setProperty(e,n,i)}}function sx(e,t){return e.style.getPropertyValue(t)||nx(e).getComputedStyle(e,null).getPropertyValue(t)}function lx(e){return function(){delete this[e]}}function cx(e,t){return function(){this[e]=t}}function dx(e,t){return function(){var i=t.apply(this,arguments);null==i?delete this[e]:this[e]=i}}function ux(e){return e.trim().split(/^|\s+/)}function hx(e){return e.classList||new px(e)}function px(e){this._node=e,this._names=ux(e.getAttribute("class")||"")}function gx(e,t){for(var i=hx(e),n=-1,o=t.length;++n<o;)i.add(t[n])}function fx(e,t){for(var i=hx(e),n=-1,o=t.length;++n<o;)i.remove(t[n])}function mx(e){return function(){gx(this,e)}}function vx(e){return function(){fx(this,e)}}function yx(e,t){return function(){(t.apply(this,arguments)?gx:fx)(this,e)}}function Cx(){this.textContent=""}function bx(e){return function(){this.textContent=e}}function Sx(e){return function(){var t=e.apply(this,arguments);this.textContent=null==t?"":t}}function xx(){this.innerHTML=""}function Tx(e){return function(){this.innerHTML=e}}function wx(e){return function(){var t=e.apply(this,arguments);this.innerHTML=null==t?"":t}}function Ox(){this.nextSibling&&this.parentNode.appendChild(this)}function Px(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function Ax(e){return function(){var t=this.ownerDocument,i=this.namespaceURI;return i===KS&&t.documentElement.namespaceURI===KS?t.createElement(e):t.createElementNS(i,e)}}function Ex(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function kx(e){var t=YS(e);return(t.local?Ex:Ax)(t)}function Ix(){return null}function Dx(){var e=this.parentNode;e&&e.removeChild(this)}function _x(){var e=this.cloneNode(!1),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function Nx(){var e=this.cloneNode(!0),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function Rx(e){return function(){var t=this.__on;if(t){for(var i,n=0,o=-1,r=t.length;n<r;++n)i=t[n],e.type&&i.type!==e.type||i.name!==e.name?t[++o]=i:this.removeEventListener(i.type,i.listener,i.options);++o?t.length=o:delete this.__on}}}function Mx(e,t,i){return function(){var n,o=this.__on,r=function(e){return function(t){e.call(this,t,this.__data__)}}(t);if(o)for(var a=0,s=o.length;a<s;++a)if((n=o[a]).type===e.type&&n.name===e.name)return this.removeEventListener(n.type,n.listener,n.options),this.addEventListener(n.type,n.listener=r,n.options=i),void(n.value=t);this.addEventListener(e.type,r,i),n={type:e.type,name:e.name,value:t,listener:r,options:i},o?o.push(n):this.__on=[n]}}function Lx(e,t,i){var n=nx(e),o=n.CustomEvent;"function"==typeof o?o=new o(t,i):(o=n.document.createEvent("Event"),i?(o.initEvent(t,i.bubbles,i.cancelable),o.detail=i.detail):o.initEvent(t,!1,!1)),e.dispatchEvent(o)}function Bx(e,t){return function(){return Lx(this,e,t)}}function Fx(e,t){return function(){return Lx(this,e,t.apply(this,arguments))}}px.prototype={add:function(e){this._names.indexOf(e)<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var t=this._names.indexOf(e);t>=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};var Ux=[null];function Hx(e,t){this._groups=e,this._parents=t}function $x(){return new Hx([[document.documentElement]],Ux)}Hx.prototype=$x.prototype={constructor:Hx,select:function(e){"function"!=typeof e&&(e=_S(e));for(var t=this._groups,i=t.length,n=new Array(i),o=0;o<i;++o)for(var r,a,s=t[o],l=s.length,c=n[o]=new Array(l),d=0;d<l;++d)(r=s[d])&&(a=e.call(r,r.__data__,d,s))&&("__data__"in r&&(a.__data__=r.__data__),c[d]=a);return new Hx(n,this._parents)},selectAll:function(e){e="function"==typeof e?function(e){return function(){return function(e){return null==e?[]:Array.isArray(e)?e:Array.from(e)}(e.apply(this,arguments))}}(e):RS(e);for(var t=this._groups,i=t.length,n=[],o=[],r=0;r<i;++r)for(var a,s=t[r],l=s.length,c=0;c<l;++c)(a=s[c])&&(n.push(e.call(a,a.__data__,c,s)),o.push(a));return new Hx(n,o)},selectChild:function(e){return this.select(null==e?FS:function(e){return function(){return BS.call(this.children,e)}}("function"==typeof e?e:LS(e)))},selectChildren:function(e){return this.selectAll(null==e?HS:function(e){return function(){return US.call(this.children,e)}}("function"==typeof e?e:LS(e)))},filter:function(e){"function"!=typeof e&&(e=MS(e));for(var t=this._groups,i=t.length,n=new Array(i),o=0;o<i;++o)for(var r,a=t[o],s=a.length,l=n[o]=[],c=0;c<s;++c)(r=a[c])&&e.call(r,r.__data__,c,a)&&l.push(r);return new Hx(n,this._parents)},data:function(e,t){if(!arguments.length)return Array.from(this,jS);var i=t?GS:VS,n=this._parents,o=this._groups;"function"!=typeof e&&(e=function(e){return function(){return e}}(e));for(var r=o.length,a=new Array(r),s=new Array(r),l=new Array(r),c=0;c<r;++c){var d=n[c],u=o[c],h=u.length,p=zS(e.call(d,d&&d.__data__,c,n)),g=p.length,f=s[c]=new Array(g),m=a[c]=new Array(g);i(d,u,f,m,l[c]=new Array(h),p,t);for(var v,y,C=0,b=0;C<g;++C)if(v=f[C]){for(C>=b&&(b=C+1);!(y=m[b])&&++b<g;);v._next=y||null}}return(a=new Hx(a,n))._enter=s,a._exit=l,a},enter:function(){return new Hx(this._enter||this._groups.map($S),this._parents)},exit:function(){return new Hx(this._exit||this._groups.map($S),this._parents)},join:function(e,t,i){var n=this.enter(),o=this,r=this.exit();return"function"==typeof e?(n=e(n))&&(n=n.selection()):n=n.append(e+""),null!=t&&(o=t(o))&&(o=o.selection()),null==i?r.remove():i(r),n&&o?n.merge(o).order():o},merge:function(e){for(var t=e.selection?e.selection():e,i=this._groups,n=t._groups,o=i.length,r=n.length,a=Math.min(o,r),s=new Array(o),l=0;l<a;++l)for(var c,d=i[l],u=n[l],h=d.length,p=s[l]=new Array(h),g=0;g<h;++g)(c=d[g]||u[g])&&(p[g]=c);for(;l<o;++l)s[l]=i[l];return new Hx(s,this._parents)},selection:function(){return this},order:function(){for(var e=this._groups,t=-1,i=e.length;++t<i;)for(var n,o=e[t],r=o.length-1,a=o[r];--r>=0;)(n=o[r])&&(a&&4^n.compareDocumentPosition(a)&&a.parentNode.insertBefore(n,a),a=n);return this},sort:function(e){function t(t,i){return t&&i?e(t.__data__,i.__data__):!t-!i}e||(e=WS);for(var i=this._groups,n=i.length,o=new Array(n),r=0;r<n;++r){for(var a,s=i[r],l=s.length,c=o[r]=new Array(l),d=0;d<l;++d)(a=s[d])&&(c[d]=a);c.sort(t)}return new Hx(o,this._parents).order()},call:function(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this},nodes:function(){return Array.from(this)},node:function(){for(var e=this._groups,t=0,i=e.length;t<i;++t)for(var n=e[t],o=0,r=n.length;o<r;++o){var a=n[o];if(a)return a}return null},size:function(){let e=0;for(const t of this)++e;return e},empty:function(){return!this.node()},each:function(e){for(var t=this._groups,i=0,n=t.length;i<n;++i)for(var o,r=t[i],a=0,s=r.length;a<s;++a)(o=r[a])&&e.call(o,o.__data__,a,r);return this},attr:function(e,t){var i=YS(e);if(arguments.length<2){var n=this.node();return i.local?n.getAttributeNS(i.space,i.local):n.getAttribute(i)}return this.each((null==t?i.local?JS:XS:"function"==typeof t?i.local?ix:tx:i.local?ex:QS)(i,t))},style:function(e,t,i){return arguments.length>1?this.each((null==t?ox:"function"==typeof t?ax:rx)(e,t,null==i?"":i)):sx(this.node(),e)},property:function(e,t){return arguments.length>1?this.each((null==t?lx:"function"==typeof t?dx:cx)(e,t)):this.node()[e]},classed:function(e,t){var i=ux(e+"");if(arguments.length<2){for(var n=hx(this.node()),o=-1,r=i.length;++o<r;)if(!n.contains(i[o]))return!1;return!0}return this.each(("function"==typeof t?yx:t?mx:vx)(i,t))},text:function(e){return arguments.length?this.each(null==e?Cx:("function"==typeof e?Sx:bx)(e)):this.node().textContent},html:function(e){return arguments.length?this.each(null==e?xx:("function"==typeof e?wx:Tx)(e)):this.node().innerHTML},raise:function(){return this.each(Ox)},lower:function(){return this.each(Px)},append:function(e){var t="function"==typeof e?e:kx(e);return this.select((function(){return this.appendChild(t.apply(this,arguments))}))},insert:function(e,t){var i="function"==typeof e?e:kx(e),n=null==t?Ix:"function"==typeof t?t:_S(t);return this.select((function(){return this.insertBefore(i.apply(this,arguments),n.apply(this,arguments)||null)}))},remove:function(){return this.each(Dx)},clone:function(e){return this.select(e?Nx:_x)},datum:function(e){return arguments.length?this.property("__data__",e):this.node().__data__},on:function(e,t,i){var n,o,r=function(e){return e.trim().split(/^|\s+/).map((function(e){var t="",i=e.indexOf(".");return i>=0&&(t=e.slice(i+1),e=e.slice(0,i)),{type:e,name:t}}))}(e+""),a=r.length;if(!(arguments.length<2)){for(s=t?Mx:Rx,n=0;n<a;++n)this.each(s(r[n],t,i));return this}var s=this.node().__on;if(s)for(var l,c=0,d=s.length;c<d;++c)for(n=0,l=s[c];n<a;++n)if((o=r[n]).type===l.type&&o.name===l.name)return l.value},dispatch:function(e,t){return this.each(("function"==typeof t?Fx:Bx)(e,t))},[Symbol.iterator]:function*(){for(var e=this._groups,t=0,i=e.length;t<i;++t)for(var n,o=e[t],r=0,a=o.length;r<a;++r)(n=o[r])&&(yield n)}};var Zx=$x,Vx={value:()=>{}};function Gx(){for(var e,t=0,i=arguments.length,n={};t<i;++t){if(!(e=arguments[t]+"")||e in n||/[\s.]/.test(e))throw new Error("illegal type: "+e);n[e]=[]}return new jx(n)}function jx(e){this._=e}function zx(e,t){for(var i,n=0,o=e.length;n<o;++n)if((i=e[n]).name===t)return i.value}function Wx(e,t,i){for(var n=0,o=e.length;n<o;++n)if(e[n].name===t){e[n]=Vx,e=e.slice(0,n).concat(e.slice(n+1));break}return null!=i&&e.push({name:t,value:i}),e}jx.prototype=Gx.prototype={constructor:jx,on:function(e,t){var i,n,o=this._,r=(n=o,(e+"").trim().split(/^|\s+/).map((function(e){var t="",i=e.indexOf(".");if(i>=0&&(t=e.slice(i+1),e=e.slice(0,i)),e&&!n.hasOwnProperty(e))throw new Error("unknown type: "+e);return{type:e,name:t}}))),a=-1,s=r.length;if(!(arguments.length<2)){if(null!=t&&"function"!=typeof t)throw new Error("invalid callback: "+t);for(;++a<s;)if(i=(e=r[a]).type)o[i]=Wx(o[i],e.name,t);else if(null==t)for(i in o)o[i]=Wx(o[i],e.name,null);return this}for(;++a<s;)if((i=(e=r[a]).type)&&(i=zx(o[i],e.name)))return i},copy:function(){var e={},t=this._;for(var i in t)e[i]=t[i].slice();return new jx(e)},call:function(e,t){if((i=arguments.length-2)>0)for(var i,n,o=new Array(i),r=0;r<i;++r)o[r]=arguments[r+2];if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(r=0,i=(n=this._[e]).length;r<i;++r)n[r].value.apply(t,o)},apply:function(e,t,i){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(var n=this._[e],o=0,r=n.length;o<r;++o)n[o].value.apply(t,i)}};var Kx,qx,Yx=Gx,Xx=0,Jx=0,Qx=0,eT=1e3,tT=0,iT=0,nT=0,oT="object"==typeof performance&&performance.now?performance:Date,rT="object"==typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function aT(){return iT||(rT(sT),iT=oT.now()+nT)}function sT(){iT=0}function lT(){this._call=this._time=this._next=null}function cT(e,t,i){var n=new lT;return n.restart(e,t,i),n}function dT(){iT=(tT=oT.now())+nT,Xx=Jx=0;try{!function(){aT(),++Xx;for(var e,t=Kx;t;)(e=iT-t._time)>=0&&t._call.call(void 0,e),t=t._next;--Xx}()}finally{Xx=0,function(){for(var e,t,i=Kx,n=1/0;i;)i._call?(n>i._time&&(n=i._time),e=i,i=i._next):(t=i._next,i._next=null,i=e?e._next=t:Kx=t);qx=e,hT(n)}(),iT=0}}function uT(){var e=oT.now(),t=e-tT;t>eT&&(nT-=t,tT=e)}function hT(e){Xx||(Jx&&(Jx=clearTimeout(Jx)),e-iT>24?(e<1/0&&(Jx=setTimeout(dT,e-oT.now()-nT)),Qx&&(Qx=clearInterval(Qx))):(Qx||(tT=oT.now(),Qx=setInterval(uT,eT)),Xx=1,rT(dT)))}function pT(e,t,i){var n=new lT;return t=null==t?0:+t,n.restart((i=>{n.stop(),e(i+t)}),t,i),n}lT.prototype=cT.prototype={constructor:lT,restart:function(e,t,i){if("function"!=typeof e)throw new TypeError("callback is not a function");i=(null==i?aT():+i)+(null==t?0:+t),this._next||qx===this||(qx?qx._next=this:Kx=this,qx=this),this._call=e,this._time=i,hT()},stop:function(){this._call&&(this._call=null,this._time=1/0,hT())}};var gT=Yx("start","end","cancel","interrupt"),fT=[],mT=0,vT=3;function yT(e,t,i,n,o,r){var a=e.__transition;if(a){if(i in a)return}else e.__transition={};!function(e,t,i){var n,o=e.__transition;function r(l){var c,d,u,h;if(1!==i.state)return s();for(c in o)if((h=o[c]).name===i.name){if(h.state===vT)return pT(r);4===h.state?(h.state=6,h.timer.stop(),h.on.call("interrupt",e,e.__data__,h.index,h.group),delete o[c]):+c<t&&(h.state=6,h.timer.stop(),h.on.call("cancel",e,e.__data__,h.index,h.group),delete o[c])}if(pT((function(){i.state===vT&&(i.state=4,i.timer.restart(a,i.delay,i.time),a(l))})),i.state=2,i.on.call("start",e,e.__data__,i.index,i.group),2===i.state){for(i.state=vT,n=new Array(u=i.tween.length),c=0,d=-1;c<u;++c)(h=i.tween[c].value.call(e,e.__data__,i.index,i.group))&&(n[++d]=h);n.length=d+1}}function a(t){for(var o=t<i.duration?i.ease.call(null,t/i.duration):(i.timer.restart(s),i.state=5,1),r=-1,a=n.length;++r<a;)n[r].call(e,o);5===i.state&&(i.on.call("end",e,e.__data__,i.index,i.group),s())}function s(){for(var n in i.state=6,i.timer.stop(),delete o[t],o)return;delete e.__transition}o[t]=i,i.timer=cT((function(e){i.state=1,i.timer.restart(r,i.delay,i.time),i.delay<=e&&r(e-i.delay)}),0,i.time)}(e,i,{name:t,index:n,group:o,on:gT,tween:fT,time:r.time,delay:r.delay,duration:r.duration,ease:r.ease,timer:null,state:mT})}function CT(e,t){var i=ST(e,t);if(i.state>mT)throw new Error("too late; already scheduled");return i}function bT(e,t){var i=ST(e,t);if(i.state>vT)throw new Error("too late; already running");return i}function ST(e,t){var i=e.__transition;if(!i||!(i=i[t]))throw new Error("transition not found");return i}function xT(e,t){return e=+e,t=+t,function(i){return e*(1-i)+t*i}}var TT,wT=180/Math.PI,OT={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function PT(e,t,i,n,o,r){var a,s,l;return(a=Math.sqrt(e*e+t*t))&&(e/=a,t/=a),(l=e*i+t*n)&&(i-=e*l,n-=t*l),(s=Math.sqrt(i*i+n*n))&&(i/=s,n/=s,l/=s),e*n<t*i&&(e=-e,t=-t,l=-l,a=-a),{translateX:o,translateY:r,rotate:Math.atan2(t,e)*wT,skewX:Math.atan(l)*wT,scaleX:a,scaleY:s}}function AT(e,t,i,n){function o(e){return e.length?e.pop()+" ":""}return function(r,a){var s=[],l=[];return r=e(r),a=e(a),function(e,n,o,r,a,s){if(e!==o||n!==r){var l=a.push("translate(",null,t,null,i);s.push({i:l-4,x:xT(e,o)},{i:l-2,x:xT(n,r)})}else(o||r)&&a.push("translate("+o+t+r+i)}(r.translateX,r.translateY,a.translateX,a.translateY,s,l),function(e,t,i,r){e!==t?(e-t>180?t+=360:t-e>180&&(e+=360),r.push({i:i.push(o(i)+"rotate(",null,n)-2,x:xT(e,t)})):t&&i.push(o(i)+"rotate("+t+n)}(r.rotate,a.rotate,s,l),function(e,t,i,r){e!==t?r.push({i:i.push(o(i)+"skewX(",null,n)-2,x:xT(e,t)}):t&&i.push(o(i)+"skewX("+t+n)}(r.skewX,a.skewX,s,l),function(e,t,i,n,r,a){if(e!==i||t!==n){var s=r.push(o(r)+"scale(",null,",",null,")");a.push({i:s-4,x:xT(e,i)},{i:s-2,x:xT(t,n)})}else 1===i&&1===n||r.push(o(r)+"scale("+i+","+n+")")}(r.scaleX,r.scaleY,a.scaleX,a.scaleY,s,l),r=a=null,function(e){for(var t,i=-1,n=l.length;++i<n;)s[(t=l[i]).i]=t.x(e);return s.join("")}}}var ET=AT((function(e){const t=new("function"==typeof DOMMatrix?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?OT:PT(t.a,t.b,t.c,t.d,t.e,t.f)}),"px, ","px)","deg)"),kT=AT((function(e){return null==e?OT:(TT||(TT=document.createElementNS("http://www.w3.org/2000/svg","g")),TT.setAttribute("transform",e),(e=TT.transform.baseVal.consolidate())?PT((e=e.matrix).a,e.b,e.c,e.d,e.e,e.f):OT)}),", ",")",")");function IT(e,t){var i,n;return function(){var o=bT(this,e),r=o.tween;if(r!==i)for(var a=0,s=(n=i=r).length;a<s;++a)if(n[a].name===t){(n=n.slice()).splice(a,1);break}o.tween=n}}function DT(e,t,i){var n,o;if("function"!=typeof i)throw new Error;return function(){var r=bT(this,e),a=r.tween;if(a!==n){o=(n=a).slice();for(var s={name:t,value:i},l=0,c=o.length;l<c;++l)if(o[l].name===t){o[l]=s;break}l===c&&o.push(s)}r.tween=o}}function _T(e,t,i){var n=e._id;return e.each((function(){var e=bT(this,n);(e.value||(e.value={}))[t]=i.apply(this,arguments)})),function(e){return ST(e,n).value[t]}}function NT(e,t,i){e.prototype=t.prototype=i,i.constructor=e}function RT(e,t){var i=Object.create(e.prototype);for(var n in t)i[n]=t[n];return i}function MT(){}var LT=.7,BT=1/LT,FT="\\s*([+-]?\\d+)\\s*",UT="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",HT="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",$T=/^#([0-9a-f]{3,8})$/,ZT=new RegExp(`^rgb\\(${FT},${FT},${FT}\\)$`),VT=new RegExp(`^rgb\\(${HT},${HT},${HT}\\)$`),GT=new RegExp(`^rgba\\(${FT},${FT},${FT},${UT}\\)$`),jT=new RegExp(`^rgba\\(${HT},${HT},${HT},${UT}\\)$`),zT=new RegExp(`^hsl\\(${UT},${HT},${HT}\\)$`),WT=new RegExp(`^hsla\\(${UT},${HT},${HT},${UT}\\)$`),KT={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function qT(){return this.rgb().formatHex()}function YT(){return this.rgb().formatRgb()}function XT(e){var t,i;return e=(e+"").trim().toLowerCase(),(t=$T.exec(e))?(i=t[1].length,t=parseInt(t[1],16),6===i?JT(t):3===i?new tw(t>>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===i?QT(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===i?QT(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|240&t,((15&t)<<4|15&t)/255):null):(t=ZT.exec(e))?new tw(t[1],t[2],t[3],1):(t=VT.exec(e))?new tw(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=GT.exec(e))?QT(t[1],t[2],t[3],t[4]):(t=jT.exec(e))?QT(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=zT.exec(e))?sw(t[1],t[2]/100,t[3]/100,1):(t=WT.exec(e))?sw(t[1],t[2]/100,t[3]/100,t[4]):KT.hasOwnProperty(e)?JT(KT[e]):"transparent"===e?new tw(NaN,NaN,NaN,0):null}function JT(e){return new tw(e>>16&255,e>>8&255,255&e,1)}function QT(e,t,i,n){return n<=0&&(e=t=i=NaN),new tw(e,t,i,n)}function ew(e,t,i,n){return 1===arguments.length?((o=e)instanceof MT||(o=XT(o)),o?new tw((o=o.rgb()).r,o.g,o.b,o.opacity):new tw):new tw(e,t,i,null==n?1:n);var o}function tw(e,t,i,n){this.r=+e,this.g=+t,this.b=+i,this.opacity=+n}function iw(){return`#${aw(this.r)}${aw(this.g)}${aw(this.b)}`}function nw(){const e=ow(this.opacity);return`${1===e?"rgb(":"rgba("}${rw(this.r)}, ${rw(this.g)}, ${rw(this.b)}${1===e?")":`, ${e})`}`}function ow(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function rw(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function aw(e){return((e=rw(e))<16?"0":"")+e.toString(16)}function sw(e,t,i,n){return n<=0?e=t=i=NaN:i<=0||i>=1?e=t=NaN:t<=0&&(e=NaN),new cw(e,t,i,n)}function lw(e){if(e instanceof cw)return new cw(e.h,e.s,e.l,e.opacity);if(e instanceof MT||(e=XT(e)),!e)return new cw;if(e instanceof cw)return e;var t=(e=e.rgb()).r/255,i=e.g/255,n=e.b/255,o=Math.min(t,i,n),r=Math.max(t,i,n),a=NaN,s=r-o,l=(r+o)/2;return s?(a=t===r?(i-n)/s+6*(i<n):i===r?(n-t)/s+2:(t-i)/s+4,s/=l<.5?r+o:2-r-o,a*=60):s=l>0&&l<1?0:a,new cw(a,s,l,e.opacity)}function cw(e,t,i,n){this.h=+e,this.s=+t,this.l=+i,this.opacity=+n}function dw(e){return(e=(e||0)%360)<0?e+360:e}function uw(e){return Math.max(0,Math.min(1,e||0))}function hw(e,t,i){return 255*(e<60?t+(i-t)*e/60:e<180?i:e<240?t+(i-t)*(240-e)/60:t)}function pw(e,t,i,n,o){var r=e*e,a=r*e;return((1-3*e+3*r-a)*t+(4-6*r+3*a)*i+(1+3*e+3*r-3*a)*n+a*o)/6}NT(MT,XT,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:qT,formatHex:qT,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return lw(this).formatHsl()},formatRgb:YT,toString:YT}),NT(tw,ew,RT(MT,{brighter(e){return e=null==e?BT:Math.pow(BT,e),new tw(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=null==e?LT:Math.pow(LT,e),new tw(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new tw(rw(this.r),rw(this.g),rw(this.b),ow(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:iw,formatHex:iw,formatHex8:function(){return`#${aw(this.r)}${aw(this.g)}${aw(this.b)}${aw(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:nw,toString:nw})),NT(cw,(function(e,t,i,n){return 1===arguments.length?lw(e):new cw(e,t,i,null==n?1:n)}),RT(MT,{brighter(e){return e=null==e?BT:Math.pow(BT,e),new cw(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=null==e?LT:Math.pow(LT,e),new cw(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+360*(this.h<0),t=isNaN(e)||isNaN(this.s)?0:this.s,i=this.l,n=i+(i<.5?i:1-i)*t,o=2*i-n;return new tw(hw(e>=240?e-240:e+120,o,n),hw(e,o,n),hw(e<120?e+240:e-120,o,n),this.opacity)},clamp(){return new cw(dw(this.h),uw(this.s),uw(this.l),ow(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=ow(this.opacity);return`${1===e?"hsl(":"hsla("}${dw(this.h)}, ${100*uw(this.s)}%, ${100*uw(this.l)}%${1===e?")":`, ${e})`}`}}));var gw=e=>()=>e;function fw(e,t){var i=t-e;return i?function(e,t){return function(i){return e+i*t}}(e,i):gw(isNaN(e)?t:e)}var mw=function e(t){var i=function(e){return 1==(e=+e)?fw:function(t,i){return i-t?function(e,t,i){return e=Math.pow(e,i),t=Math.pow(t,i)-e,i=1/i,function(n){return Math.pow(e+n*t,i)}}(t,i,e):gw(isNaN(t)?i:t)}}(t);function n(e,t){var n=i((e=ew(e)).r,(t=ew(t)).r),o=i(e.g,t.g),r=i(e.b,t.b),a=fw(e.opacity,t.opacity);return function(t){return e.r=n(t),e.g=o(t),e.b=r(t),e.opacity=a(t),e+""}}return n.gamma=e,n}(1);function vw(e){return function(t){var i,n,o=t.length,r=new Array(o),a=new Array(o),s=new Array(o);for(i=0;i<o;++i)n=ew(t[i]),r[i]=n.r||0,a[i]=n.g||0,s[i]=n.b||0;return r=e(r),a=e(a),s=e(s),n.opacity=1,function(e){return n.r=r(e),n.g=a(e),n.b=s(e),n+""}}}vw((function(e){var t=e.length-1;return function(i){var n=i<=0?i=0:i>=1?(i=1,t-1):Math.floor(i*t),o=e[n],r=e[n+1],a=n>0?e[n-1]:2*o-r,s=n<t-1?e[n+2]:2*r-o;return pw((i-n/t)*t,a,o,r,s)}})),vw((function(e){var t=e.length;return function(i){var n=Math.floor(((i%=1)<0?++i:i)*t),o=e[(n+t-1)%t],r=e[n%t],a=e[(n+1)%t],s=e[(n+2)%t];return pw((i-n/t)*t,o,r,a,s)}}));var yw=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Cw=new RegExp(yw.source,"g");function bw(e,t){var i,n,o,r=yw.lastIndex=Cw.lastIndex=0,a=-1,s=[],l=[];for(e+="",t+="";(i=yw.exec(e))&&(n=Cw.exec(t));)(o=n.index)>r&&(o=t.slice(r,o),s[a]?s[a]+=o:s[++a]=o),(i=i[0])===(n=n[0])?s[a]?s[a]+=n:s[++a]=n:(s[++a]=null,l.push({i:a,x:xT(i,n)})),r=Cw.lastIndex;return r<t.length&&(o=t.slice(r),s[a]?s[a]+=o:s[++a]=o),s.length<2?l[0]?function(e){return function(t){return e(t)+""}}(l[0].x):function(e){return function(){return e}}(t):(t=l.length,function(e){for(var i,n=0;n<t;++n)s[(i=l[n]).i]=i.x(e);return s.join("")})}function Sw(e,t){var i;return("number"==typeof t?xT:t instanceof XT?mw:(i=XT(t))?(t=i,mw):bw)(e,t)}function xw(e){return function(){this.removeAttribute(e)}}function Tw(e){return function(){this.removeAttributeNS(e.space,e.local)}}function ww(e,t,i){var n,o,r=i+"";return function(){var a=this.getAttribute(e);return a===r?null:a===n?o:o=t(n=a,i)}}function Ow(e,t,i){var n,o,r=i+"";return function(){var a=this.getAttributeNS(e.space,e.local);return a===r?null:a===n?o:o=t(n=a,i)}}function Pw(e,t,i){var n,o,r;return function(){var a,s,l=i(this);if(null!=l)return(a=this.getAttribute(e))===(s=l+"")?null:a===n&&s===o?r:(o=s,r=t(n=a,l));this.removeAttribute(e)}}function Aw(e,t,i){var n,o,r;return function(){var a,s,l=i(this);if(null!=l)return(a=this.getAttributeNS(e.space,e.local))===(s=l+"")?null:a===n&&s===o?r:(o=s,r=t(n=a,l));this.removeAttributeNS(e.space,e.local)}}function Ew(e,t){var i,n;function o(){var o=t.apply(this,arguments);return o!==n&&(i=(n=o)&&function(e,t){return function(i){this.setAttributeNS(e.space,e.local,t.call(this,i))}}(e,o)),i}return o._value=t,o}function kw(e,t){var i,n;function o(){var o=t.apply(this,arguments);return o!==n&&(i=(n=o)&&function(e,t){return function(i){this.setAttribute(e,t.call(this,i))}}(e,o)),i}return o._value=t,o}function Iw(e,t){return function(){CT(this,e).delay=+t.apply(this,arguments)}}function Dw(e,t){return t=+t,function(){CT(this,e).delay=t}}function _w(e,t){return function(){bT(this,e).duration=+t.apply(this,arguments)}}function Nw(e,t){return t=+t,function(){bT(this,e).duration=t}}var Rw=Zx.prototype.constructor;function Mw(e){return function(){this.style.removeProperty(e)}}var Lw=0;function Bw(e,t,i,n){this._groups=e,this._parents=t,this._name=i,this._id=n}function Fw(){return++Lw}var Uw=Zx.prototype;Bw.prototype=function(e){return Zx().transition(e)}.prototype={constructor:Bw,select:function(e){var t=this._name,i=this._id;"function"!=typeof e&&(e=_S(e));for(var n=this._groups,o=n.length,r=new Array(o),a=0;a<o;++a)for(var s,l,c=n[a],d=c.length,u=r[a]=new Array(d),h=0;h<d;++h)(s=c[h])&&(l=e.call(s,s.__data__,h,c))&&("__data__"in s&&(l.__data__=s.__data__),u[h]=l,yT(u[h],t,i,h,u,ST(s,i)));return new Bw(r,this._parents,t,i)},selectAll:function(e){var t=this._name,i=this._id;"function"!=typeof e&&(e=RS(e));for(var n=this._groups,o=n.length,r=[],a=[],s=0;s<o;++s)for(var l,c=n[s],d=c.length,u=0;u<d;++u)if(l=c[u]){for(var h,p=e.call(l,l.__data__,u,c),g=ST(l,i),f=0,m=p.length;f<m;++f)(h=p[f])&&yT(h,t,i,f,p,g);r.push(p),a.push(l)}return new Bw(r,a,t,i)},selectChild:Uw.selectChild,selectChildren:Uw.selectChildren,filter:function(e){"function"!=typeof e&&(e=MS(e));for(var t=this._groups,i=t.length,n=new Array(i),o=0;o<i;++o)for(var r,a=t[o],s=a.length,l=n[o]=[],c=0;c<s;++c)(r=a[c])&&e.call(r,r.__data__,c,a)&&l.push(r);return new Bw(n,this._parents,this._name,this._id)},merge:function(e){if(e._id!==this._id)throw new Error;for(var t=this._groups,i=e._groups,n=t.length,o=i.length,r=Math.min(n,o),a=new Array(n),s=0;s<r;++s)for(var l,c=t[s],d=i[s],u=c.length,h=a[s]=new Array(u),p=0;p<u;++p)(l=c[p]||d[p])&&(h[p]=l);for(;s<n;++s)a[s]=t[s];return new Bw(a,this._parents,this._name,this._id)},selection:function(){return new Rw(this._groups,this._parents)},transition:function(){for(var e=this._name,t=this._id,i=Fw(),n=this._groups,o=n.length,r=0;r<o;++r)for(var a,s=n[r],l=s.length,c=0;c<l;++c)if(a=s[c]){var d=ST(a,t);yT(a,e,i,c,s,{time:d.time+d.delay+d.duration,delay:0,duration:d.duration,ease:d.ease})}return new Bw(n,this._parents,e,i)},call:Uw.call,nodes:Uw.nodes,node:Uw.node,size:Uw.size,empty:Uw.empty,each:Uw.each,on:function(e,t){var i=this._id;return arguments.length<2?ST(this.node(),i).on.on(e):this.each(function(e,t,i){var n,o,r=function(e){return(e+"").trim().split(/^|\s+/).every((function(e){var t=e.indexOf(".");return t>=0&&(e=e.slice(0,t)),!e||"start"===e}))}(t)?CT:bT;return function(){var a=r(this,e),s=a.on;s!==n&&(o=(n=s).copy()).on(t,i),a.on=o}}(i,e,t))},attr:function(e,t){var i=YS(e),n="transform"===i?kT:Sw;return this.attrTween(e,"function"==typeof t?(i.local?Aw:Pw)(i,n,_T(this,"attr."+e,t)):null==t?(i.local?Tw:xw)(i):(i.local?Ow:ww)(i,n,t))},attrTween:function(e,t){var i="attr."+e;if(arguments.length<2)return(i=this.tween(i))&&i._value;if(null==t)return this.tween(i,null);if("function"!=typeof t)throw new Error;var n=YS(e);return this.tween(i,(n.local?Ew:kw)(n,t))},style:function(e,t,i){var n="transform"==(e+="")?ET:Sw;return null==t?this.styleTween(e,function(e,t){var i,n,o;return function(){var r=sx(this,e),a=(this.style.removeProperty(e),sx(this,e));return r===a?null:r===i&&a===n?o:o=t(i=r,n=a)}}(e,n)).on("end.style."+e,Mw(e)):"function"==typeof t?this.styleTween(e,function(e,t,i){var n,o,r;return function(){var a=sx(this,e),s=i(this),l=s+"";return null==s&&(this.style.removeProperty(e),l=s=sx(this,e)),a===l?null:a===n&&l===o?r:(o=l,r=t(n=a,s))}}(e,n,_T(this,"style."+e,t))).each(function(e,t){var i,n,o,r,a="style."+t,s="end."+a;return function(){var l=bT(this,e),c=l.on,d=null==l.value[a]?r||(r=Mw(t)):void 0;c===i&&o===d||(n=(i=c).copy()).on(s,o=d),l.on=n}}(this._id,e)):this.styleTween(e,function(e,t,i){var n,o,r=i+"";return function(){var a=sx(this,e);return a===r?null:a===n?o:o=t(n=a,i)}}(e,n,t),i).on("end.style."+e,null)},styleTween:function(e,t,i){var n="style."+(e+="");if(arguments.length<2)return(n=this.tween(n))&&n._value;if(null==t)return this.tween(n,null);if("function"!=typeof t)throw new Error;return this.tween(n,function(e,t,i){var n,o;function r(){var r=t.apply(this,arguments);return r!==o&&(n=(o=r)&&function(e,t,i){return function(n){this.style.setProperty(e,t.call(this,n),i)}}(e,r,i)),n}return r._value=t,r}(e,t,null==i?"":i))},text:function(e){return this.tween("text","function"==typeof e?function(e){return function(){var t=e(this);this.textContent=null==t?"":t}}(_T(this,"text",e)):function(e){return function(){this.textContent=e}}(null==e?"":e+""))},textTween:function(e){var t="text";if(arguments.length<1)return(t=this.tween(t))&&t._value;if(null==e)return this.tween(t,null);if("function"!=typeof e)throw new Error;return this.tween(t,function(e){var t,i;function n(){var n=e.apply(this,arguments);return n!==i&&(t=(i=n)&&function(e){return function(t){this.textContent=e.call(this,t)}}(n)),t}return n._value=e,n}(e))},remove:function(){return this.on("end.remove",function(e){return function(){var t=this.parentNode;for(var i in this.__transition)if(+i!==e)return;t&&t.removeChild(this)}}(this._id))},tween:function(e,t){var i=this._id;if(e+="",arguments.length<2){for(var n,o=ST(this.node(),i).tween,r=0,a=o.length;r<a;++r)if((n=o[r]).name===e)return n.value;return null}return this.each((null==t?IT:DT)(i,e,t))},delay:function(e){var t=this._id;return arguments.length?this.each(("function"==typeof e?Iw:Dw)(t,e)):ST(this.node(),t).delay},duration:function(e){var t=this._id;return arguments.length?this.each(("function"==typeof e?_w:Nw)(t,e)):ST(this.node(),t).duration},ease:function(e){var t=this._id;return arguments.length?this.each(function(e,t){if("function"!=typeof t)throw new Error;return function(){bT(this,e).ease=t}}(t,e)):ST(this.node(),t).ease},easeVarying:function(e){if("function"!=typeof e)throw new Error;return this.each(function(e,t){return function(){var i=t.apply(this,arguments);if("function"!=typeof i)throw new Error;bT(this,e).ease=i}}(this._id,e))},end:function(){var e,t,i=this,n=i._id,o=i.size();return new Promise((function(r,a){var s={value:a},l={value:function(){0==--o&&r()}};i.each((function(){var i=bT(this,n),o=i.on;o!==e&&((t=(e=o).copy())._.cancel.push(s),t._.interrupt.push(s),t._.end.push(l)),i.on=t})),0===o&&r()}))},[Symbol.iterator]:Uw[Symbol.iterator]};var Hw={time:null,delay:0,duration:250,ease:function(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}};function $w(e,t){for(var i;!(i=e.__transition)||!(i=i[t]);)if(!(e=e.parentNode))throw new Error(`transition ${t} not found`);return i}Zx.prototype.interrupt=function(e){return this.each((function(){!function(e,t){var i,n,o,r=e.__transition,a=!0;if(r){for(o in t=null==t?null:t+"",r)(i=r[o]).name===t?(n=i.state>2&&i.state<5,i.state=6,i.timer.stop(),i.on.call(n?"interrupt":"cancel",e,e.__data__,i.index,i.group),delete r[o]):a=!1;a&&delete e.__transition}}(this,e)}))},Zx.prototype.transition=function(e){var t,i;e instanceof Bw?(t=e._id,e=e._name):(t=Fw(),(i=Hw).time=aT(),e=null==e?null:e+"");for(var n=this._groups,o=n.length,r=0;r<o;++r)for(var a,s=n[r],l=s.length,c=0;c<l;++c)(a=s[c])&&yT(a,e,t,c,s,i||$w(a,t));return new Bw(n,this._parents,e,t)};const{abs:Zw,max:Vw,min:Gw}=Math;function jw(e){return{type:e}}["w","e"].map(jw),["n","s"].map(jw),["n","w","e","s","nw","ne","sw","se"].map(jw);const zw=Math.sqrt(50),Ww=Math.sqrt(10),Kw=Math.sqrt(2);function qw(e,t,i){const n=(t-e)/Math.max(0,i),o=Math.floor(Math.log10(n)),r=n/Math.pow(10,o),a=r>=zw?10:r>=Ww?5:r>=Kw?2:1;let s,l,c;return o<0?(c=Math.pow(10,-o)/a,s=Math.round(e*c),l=Math.round(t*c),s/c<e&&++s,l/c>t&&--l,c=-c):(c=Math.pow(10,o)*a,s=Math.round(e/c),l=Math.round(t/c),s*c<e&&++s,l*c>t&&--l),l<s&&.5<=i&&i<2?qw(e,t,2*i):[s,l,c]}function Yw(e,t,i){return qw(e=+e,t=+t,i=+i)[2]}function Xw(e,t,i){i=+i;const n=(t=+t)<(e=+e),o=n?Yw(t,e,i):Yw(e,t,i);return(n?-1:1)*(o<0?1/-o:o)}const Jw=AS(OS),Qw=Jw.right;Jw.left,AS((function(e){return null===e?NaN:+e})).center;var eO=Qw;function tO(e,t){var i,n=t?t.length:0,o=e?Math.min(n,e.length):0,r=new Array(o),a=new Array(n);for(i=0;i<o;++i)r[i]=rO(e[i],t[i]);for(;i<n;++i)a[i]=t[i];return function(e){for(i=0;i<o;++i)a[i]=r[i](e);return a}}function iO(e,t){var i=new Date;return e=+e,t=+t,function(n){return i.setTime(e*(1-n)+t*n),i}}function nO(e,t){var i,n={},o={};for(i in null!==e&&"object"==typeof e||(e={}),null!==t&&"object"==typeof t||(t={}),t)i in e?n[i]=rO(e[i],t[i]):o[i]=t[i];return function(e){for(i in n)o[i]=n[i](e);return o}}function oO(e,t){t||(t=[]);var i,n=e?Math.min(t.length,e.length):0,o=t.slice();return function(r){for(i=0;i<n;++i)o[i]=e[i]*(1-r)+t[i]*r;return o}}function rO(e,t){var i,n=typeof t;return null==t||"boolean"===n?gw(t):("number"===n?xT:"string"===n?(i=XT(t))?(t=i,mw):bw:t instanceof XT?mw:t instanceof Date?iO:function(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}(t)?oO:Array.isArray(t)?tO:"function"!=typeof t.valueOf&&"function"!=typeof t.toString||isNaN(t)?nO:xT)(e,t)}function aO(e,t){return e=+e,t=+t,function(i){return Math.round(e*(1-i)+t*i)}}function sO(e){return+e}var lO=[0,1];function cO(e){return e}function dO(e,t){return(t-=e=+e)?function(i){return(i-e)/t}:function(e){return function(){return e}}(isNaN(t)?NaN:.5)}function uO(e,t,i){var n=e[0],o=e[1],r=t[0],a=t[1];return o<n?(n=dO(o,n),r=i(a,r)):(n=dO(n,o),r=i(r,a)),function(e){return r(n(e))}}function hO(e,t,i){var n=Math.min(e.length,t.length)-1,o=new Array(n),r=new Array(n),a=-1;for(e[n]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++a<n;)o[a]=dO(e[a],e[a+1]),r[a]=i(t[a],t[a+1]);return function(t){var i=eO(e,t,1,n)-1;return r[i](o[i](t))}}function pO(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function gO(){return function(){var e,t,i,n,o,r,a=lO,s=lO,l=rO,c=cO;function d(){var e=Math.min(a.length,s.length);return c!==cO&&(c=function(e,t){var i;return e>t&&(i=e,e=t,t=i),function(i){return Math.max(e,Math.min(t,i))}}(a[0],a[e-1])),n=e>2?hO:uO,o=r=null,u}function u(t){return null==t||isNaN(t=+t)?i:(o||(o=n(a.map(e),s,l)))(e(c(t)))}return u.invert=function(i){return c(t((r||(r=n(s,a.map(e),xT)))(i)))},u.domain=function(e){return arguments.length?(a=Array.from(e,sO),d()):a.slice()},u.range=function(e){return arguments.length?(s=Array.from(e),d()):s.slice()},u.rangeRound=function(e){return s=Array.from(e),l=aO,d()},u.clamp=function(e){return arguments.length?(c=!!e||cO,d()):c!==cO},u.interpolate=function(e){return arguments.length?(l=e,d()):l},u.unknown=function(e){return arguments.length?(i=e,u):i},function(i,n){return e=i,t=n,d()}}()(cO,cO)}function fO(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e)}return this}var mO,vO=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function yO(e){if(!(t=vO.exec(e)))throw new Error("invalid format: "+e);var t;return new CO({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}function CO(e){this.fill=void 0===e.fill?" ":e.fill+"",this.align=void 0===e.align?">":e.align+"",this.sign=void 0===e.sign?"-":e.sign+"",this.symbol=void 0===e.symbol?"":e.symbol+"",this.zero=!!e.zero,this.width=void 0===e.width?void 0:+e.width,this.comma=!!e.comma,this.precision=void 0===e.precision?void 0:+e.precision,this.trim=!!e.trim,this.type=void 0===e.type?"":e.type+""}function bO(e,t){if((i=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var i,n=e.slice(0,i);return[n.length>1?n[0]+n.slice(2):n,+e.slice(i+1)]}function SO(e){return(e=bO(Math.abs(e)))?e[1]:NaN}function xO(e,t){var i=bO(e,t);if(!i)return e+"";var n=i[0],o=i[1];return o<0?"0."+new Array(-o).join("0")+n:n.length>o+1?n.slice(0,o+1)+"."+n.slice(o+1):n+new Array(o-n.length+2).join("0")}yO.prototype=CO.prototype,CO.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};var TO={"%":(e,t)=>(100*e).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:function(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)},e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>xO(100*e,t),r:xO,s:function(e,t){var i=bO(e,t);if(!i)return e+"";var n=i[0],o=i[1],r=o-(mO=3*Math.max(-8,Math.min(8,Math.floor(o/3))))+1,a=n.length;return r===a?n:r>a?n+new Array(r-a+1).join("0"):r>0?n.slice(0,r)+"."+n.slice(r):"0."+new Array(1-r).join("0")+bO(e,Math.max(0,t+r-1))[0]},X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function wO(e){return e}var OO,PO,AO,EO=Array.prototype.map,kO=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function IO(e){var t=e.domain;return e.ticks=function(e){var i=t();return function(e,t,i){if(!((i=+i)>0))return[];if((e=+e)==(t=+t))return[e];const n=t<e,[o,r,a]=n?qw(t,e,i):qw(e,t,i);if(!(r>=o))return[];const s=r-o+1,l=new Array(s);if(n)if(a<0)for(let e=0;e<s;++e)l[e]=(r-e)/-a;else for(let e=0;e<s;++e)l[e]=(r-e)*a;else if(a<0)for(let e=0;e<s;++e)l[e]=(o+e)/-a;else for(let e=0;e<s;++e)l[e]=(o+e)*a;return l}(i[0],i[i.length-1],null==e?10:e)},e.tickFormat=function(e,i){var n=t();return function(e,t,i,n){var o,r=Xw(e,t,i);switch((n=yO(null==n?",f":n)).type){case"s":var a=Math.max(Math.abs(e),Math.abs(t));return null!=n.precision||isNaN(o=function(e,t){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(SO(t)/3)))-SO(Math.abs(e)))}(r,a))||(n.precision=o),AO(n,a);case"":case"e":case"g":case"p":case"r":null!=n.precision||isNaN(o=function(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,SO(t)-SO(e))+1}(r,Math.max(Math.abs(e),Math.abs(t))))||(n.precision=o-("e"===n.type));break;case"f":case"%":null!=n.precision||isNaN(o=function(e){return Math.max(0,-SO(Math.abs(e)))}(r))||(n.precision=o-2*("%"===n.type))}return PO(n)}(n[0],n[n.length-1],null==e?10:e,i)},e.nice=function(i){null==i&&(i=10);var n,o,r=t(),a=0,s=r.length-1,l=r[a],c=r[s],d=10;for(c<l&&(o=l,l=c,c=o,o=a,a=s,s=o);d-- >0;){if((o=Yw(l,c,i))===n)return r[a]=l,r[s]=c,t(r);if(o>0)l=Math.floor(l/o)*o,c=Math.ceil(c/o)*o;else{if(!(o<0))break;l=Math.ceil(l*o)/o,c=Math.floor(c*o)/o}n=o}return e},e}function DO(){var e=gO();return e.copy=function(){return pO(e,DO())},fO.apply(e,arguments),IO(e)}OO=function(e){var t,i,n=void 0===e.grouping||void 0===e.thousands?wO:(t=EO.call(e.grouping,Number),i=e.thousands+"",function(e,n){for(var o=e.length,r=[],a=0,s=t[0],l=0;o>0&&s>0&&(l+s+1>n&&(s=Math.max(1,n-l)),r.push(e.substring(o-=s,o+s)),!((l+=s+1)>n));)s=t[a=(a+1)%t.length];return r.reverse().join(i)}),o=void 0===e.currency?"":e.currency[0]+"",r=void 0===e.currency?"":e.currency[1]+"",a=void 0===e.decimal?".":e.decimal+"",s=void 0===e.numerals?wO:function(e){return function(t){return t.replace(/[0-9]/g,(function(t){return e[+t]}))}}(EO.call(e.numerals,String)),l=void 0===e.percent?"%":e.percent+"",c=void 0===e.minus?"−":e.minus+"",d=void 0===e.nan?"NaN":e.nan+"";function u(e){var t=(e=yO(e)).fill,i=e.align,u=e.sign,h=e.symbol,p=e.zero,g=e.width,f=e.comma,m=e.precision,v=e.trim,y=e.type;"n"===y?(f=!0,y="g"):TO[y]||(void 0===m&&(m=12),v=!0,y="g"),(p||"0"===t&&"="===i)&&(p=!0,t="0",i="=");var C="$"===h?o:"#"===h&&/[boxX]/.test(y)?"0"+y.toLowerCase():"",b="$"===h?r:/[%p]/.test(y)?l:"",S=TO[y],x=/[defgprs%]/.test(y);function T(e){var o,r,l,h=C,T=b;if("c"===y)T=S(e)+T,e="";else{var w=(e=+e)<0||1/e<0;if(e=isNaN(e)?d:S(Math.abs(e),m),v&&(e=function(e){e:for(var t,i=e.length,n=1,o=-1;n<i;++n)switch(e[n]){case".":o=t=n;break;case"0":0===o&&(o=n),t=n;break;default:if(!+e[n])break e;o>0&&(o=0)}return o>0?e.slice(0,o)+e.slice(t+1):e}(e)),w&&0==+e&&"+"!==u&&(w=!1),h=(w?"("===u?u:c:"-"===u||"("===u?"":u)+h,T=("s"===y?kO[8+mO/3]:"")+T+(w&&"("===u?")":""),x)for(o=-1,r=e.length;++o<r;)if(48>(l=e.charCodeAt(o))||l>57){T=(46===l?a+e.slice(o+1):e.slice(o))+T,e=e.slice(0,o);break}}f&&!p&&(e=n(e,1/0));var O=h.length+e.length+T.length,P=O<g?new Array(g-O+1).join(t):"";switch(f&&p&&(e=n(P+e,P.length?g-T.length:1/0),P=""),i){case"<":e=h+e+T+P;break;case"=":e=h+P+e+T;break;case"^":e=P.slice(0,O=P.length>>1)+h+e+T+P.slice(O);break;default:e=P+h+e+T}return s(e)}return m=void 0===m?6:/[gprs]/.test(y)?Math.max(1,Math.min(21,m)):Math.max(0,Math.min(20,m)),T.toString=function(){return e+""},T}return{format:u,formatPrefix:function(e,t){var i=u(((e=yO(e)).type="f",e)),n=3*Math.max(-8,Math.min(8,Math.floor(SO(t)/3))),o=Math.pow(10,-n),r=kO[8+n/3];return function(e){return i(o*e)+r}}}}({thousands:",",grouping:[3],currency:["$",""]}),PO=OO.format,AO=OO.formatPrefix;const _O=1e3,NO=6e4,RO=36e5,MO=864e5,LO=6048e5,BO=31536e6,FO=new Date,UO=new Date;function HO(e,t,i,n){function o(t){return e(t=0===arguments.length?new Date:new Date(+t)),t}return o.floor=t=>(e(t=new Date(+t)),t),o.ceil=i=>(e(i=new Date(i-1)),t(i,1),e(i),i),o.round=e=>{const t=o(e),i=o.ceil(e);return e-t<i-e?t:i},o.offset=(e,i)=>(t(e=new Date(+e),null==i?1:Math.floor(i)),e),o.range=(i,n,r)=>{const a=[];if(i=o.ceil(i),r=null==r?1:Math.floor(r),!(i<n&&r>0))return a;let s;do{a.push(s=new Date(+i)),t(i,r),e(i)}while(s<i&&i<n);return a},o.filter=i=>HO((t=>{if(t>=t)for(;e(t),!i(t);)t.setTime(t-1)}),((e,n)=>{if(e>=e)if(n<0)for(;++n<=0;)for(;t(e,-1),!i(e););else for(;--n>=0;)for(;t(e,1),!i(e););})),i&&(o.count=(t,n)=>(FO.setTime(+t),UO.setTime(+n),e(FO),e(UO),Math.floor(i(FO,UO))),o.every=e=>(e=Math.floor(e),isFinite(e)&&e>0?e>1?o.filter(n?t=>n(t)%e==0:t=>o.count(0,t)%e==0):o:null)),o}const $O=HO((()=>{}),((e,t)=>{e.setTime(+e+t)}),((e,t)=>t-e));$O.every=e=>(e=Math.floor(e),isFinite(e)&&e>0?e>1?HO((t=>{t.setTime(Math.floor(t/e)*e)}),((t,i)=>{t.setTime(+t+i*e)}),((t,i)=>(i-t)/e)):$O:null),$O.range;const ZO=HO((e=>{e.setTime(e-e.getMilliseconds())}),((e,t)=>{e.setTime(+e+t*_O)}),((e,t)=>(t-e)/_O),(e=>e.getUTCSeconds())),VO=(ZO.range,HO((e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*_O)}),((e,t)=>{e.setTime(+e+t*NO)}),((e,t)=>(t-e)/NO),(e=>e.getMinutes()))),GO=(VO.range,HO((e=>{e.setUTCSeconds(0,0)}),((e,t)=>{e.setTime(+e+t*NO)}),((e,t)=>(t-e)/NO),(e=>e.getUTCMinutes()))),jO=(GO.range,HO((e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*_O-e.getMinutes()*NO)}),((e,t)=>{e.setTime(+e+t*RO)}),((e,t)=>(t-e)/RO),(e=>e.getHours()))),zO=(jO.range,HO((e=>{e.setUTCMinutes(0,0,0)}),((e,t)=>{e.setTime(+e+t*RO)}),((e,t)=>(t-e)/RO),(e=>e.getUTCHours()))),WO=(zO.range,HO((e=>e.setHours(0,0,0,0)),((e,t)=>e.setDate(e.getDate()+t)),((e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*NO)/MO),(e=>e.getDate()-1))),KO=(WO.range,HO((e=>{e.setUTCHours(0,0,0,0)}),((e,t)=>{e.setUTCDate(e.getUTCDate()+t)}),((e,t)=>(t-e)/MO),(e=>e.getUTCDate()-1))),qO=(KO.range,HO((e=>{e.setUTCHours(0,0,0,0)}),((e,t)=>{e.setUTCDate(e.getUTCDate()+t)}),((e,t)=>(t-e)/MO),(e=>Math.floor(e/MO))));function YO(e){return HO((t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)}),((e,t)=>{e.setDate(e.getDate()+7*t)}),((e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*NO)/LO))}qO.range;const XO=YO(0),JO=YO(1),QO=YO(2),eP=YO(3),tP=YO(4),iP=YO(5),nP=YO(6);function oP(e){return HO((t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)}),((e,t)=>{e.setUTCDate(e.getUTCDate()+7*t)}),((e,t)=>(t-e)/LO))}XO.range,JO.range,QO.range,eP.range,tP.range,iP.range,nP.range;const rP=oP(0),aP=oP(1),sP=oP(2),lP=oP(3),cP=oP(4),dP=oP(5),uP=oP(6),hP=(rP.range,aP.range,sP.range,lP.range,cP.range,dP.range,uP.range,HO((e=>{e.setDate(1),e.setHours(0,0,0,0)}),((e,t)=>{e.setMonth(e.getMonth()+t)}),((e,t)=>t.getMonth()-e.getMonth()+12*(t.getFullYear()-e.getFullYear())),(e=>e.getMonth()))),pP=(hP.range,HO((e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)}),((e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)}),((e,t)=>t.getUTCMonth()-e.getUTCMonth()+12*(t.getUTCFullYear()-e.getUTCFullYear())),(e=>e.getUTCMonth()))),gP=(pP.range,HO((e=>{e.setMonth(0,1),e.setHours(0,0,0,0)}),((e,t)=>{e.setFullYear(e.getFullYear()+t)}),((e,t)=>t.getFullYear()-e.getFullYear()),(e=>e.getFullYear())));gP.every=e=>isFinite(e=Math.floor(e))&&e>0?HO((t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)}),((t,i)=>{t.setFullYear(t.getFullYear()+i*e)})):null,gP.range;const fP=HO((e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)}),((e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)}),((e,t)=>t.getUTCFullYear()-e.getUTCFullYear()),(e=>e.getUTCFullYear()));function mP(e,t,i,n,o,r){const a=[[ZO,1,_O],[ZO,5,5e3],[ZO,15,15e3],[ZO,30,3e4],[r,1,NO],[r,5,3e5],[r,15,9e5],[r,30,18e5],[o,1,RO],[o,3,108e5],[o,6,216e5],[o,12,432e5],[n,1,MO],[n,2,1728e5],[i,1,LO],[t,1,2592e6],[t,3,7776e6],[e,1,BO]];function s(t,i,n){const o=Math.abs(i-t)/n,r=AS((([,,e])=>e)).right(a,o);if(r===a.length)return e.every(Xw(t/BO,i/BO,n));if(0===r)return $O.every(Math.max(Xw(t,i,n),1));const[s,l]=a[o/a[r-1][2]<a[r][2]/o?r-1:r];return s.every(l)}return[function(e,t,i){const n=t<e;n&&([e,t]=[t,e]);const o=i&&"function"==typeof i.range?i:s(e,t,i),r=o?o.range(e,+t+1):[];return n?r.reverse():r},s]}fP.every=e=>isFinite(e=Math.floor(e))&&e>0?HO((t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)}),((t,i)=>{t.setUTCFullYear(t.getUTCFullYear()+i*e)})):null,fP.range;const[vP,yP]=mP(fP,pP,rP,qO,zO,GO),[CP,bP]=mP(gP,hP,XO,WO,jO,VO);function SP(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function xP(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function TP(e,t,i){return{y:e,m:t,d:i,H:0,M:0,S:0,L:0}}var wP,OP,PP={"-":"",_:" ",0:"0"},AP=/^\s*\d+/,EP=/^%/,kP=/[\\^$*+?|[\]().{}]/g;function IP(e,t,i){var n=e<0?"-":"",o=(n?-e:e)+"",r=o.length;return n+(r<i?new Array(i-r+1).join(t)+o:o)}function DP(e){return e.replace(kP,"\\$&")}function _P(e){return new RegExp("^(?:"+e.map(DP).join("|")+")","i")}function NP(e){return new Map(e.map(((e,t)=>[e.toLowerCase(),t])))}function RP(e,t,i){var n=AP.exec(t.slice(i,i+1));return n?(e.w=+n[0],i+n[0].length):-1}function MP(e,t,i){var n=AP.exec(t.slice(i,i+1));return n?(e.u=+n[0],i+n[0].length):-1}function LP(e,t,i){var n=AP.exec(t.slice(i,i+2));return n?(e.U=+n[0],i+n[0].length):-1}function BP(e,t,i){var n=AP.exec(t.slice(i,i+2));return n?(e.V=+n[0],i+n[0].length):-1}function FP(e,t,i){var n=AP.exec(t.slice(i,i+2));return n?(e.W=+n[0],i+n[0].length):-1}function UP(e,t,i){var n=AP.exec(t.slice(i,i+4));return n?(e.y=+n[0],i+n[0].length):-1}function HP(e,t,i){var n=AP.exec(t.slice(i,i+2));return n?(e.y=+n[0]+(+n[0]>68?1900:2e3),i+n[0].length):-1}function $P(e,t,i){var n=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(i,i+6));return n?(e.Z=n[1]?0:-(n[2]+(n[3]||"00")),i+n[0].length):-1}function ZP(e,t,i){var n=AP.exec(t.slice(i,i+1));return n?(e.q=3*n[0]-3,i+n[0].length):-1}function VP(e,t,i){var n=AP.exec(t.slice(i,i+2));return n?(e.m=n[0]-1,i+n[0].length):-1}function GP(e,t,i){var n=AP.exec(t.slice(i,i+2));return n?(e.d=+n[0],i+n[0].length):-1}function jP(e,t,i){var n=AP.exec(t.slice(i,i+3));return n?(e.m=0,e.d=+n[0],i+n[0].length):-1}function zP(e,t,i){var n=AP.exec(t.slice(i,i+2));return n?(e.H=+n[0],i+n[0].length):-1}function WP(e,t,i){var n=AP.exec(t.slice(i,i+2));return n?(e.M=+n[0],i+n[0].length):-1}function KP(e,t,i){var n=AP.exec(t.slice(i,i+2));return n?(e.S=+n[0],i+n[0].length):-1}function qP(e,t,i){var n=AP.exec(t.slice(i,i+3));return n?(e.L=+n[0],i+n[0].length):-1}function YP(e,t,i){var n=AP.exec(t.slice(i,i+6));return n?(e.L=Math.floor(n[0]/1e3),i+n[0].length):-1}function XP(e,t,i){var n=EP.exec(t.slice(i,i+1));return n?i+n[0].length:-1}function JP(e,t,i){var n=AP.exec(t.slice(i));return n?(e.Q=+n[0],i+n[0].length):-1}function QP(e,t,i){var n=AP.exec(t.slice(i));return n?(e.s=+n[0],i+n[0].length):-1}function eA(e,t){return IP(e.getDate(),t,2)}function tA(e,t){return IP(e.getHours(),t,2)}function iA(e,t){return IP(e.getHours()%12||12,t,2)}function nA(e,t){return IP(1+WO.count(gP(e),e),t,3)}function oA(e,t){return IP(e.getMilliseconds(),t,3)}function rA(e,t){return oA(e,t)+"000"}function aA(e,t){return IP(e.getMonth()+1,t,2)}function sA(e,t){return IP(e.getMinutes(),t,2)}function lA(e,t){return IP(e.getSeconds(),t,2)}function cA(e){var t=e.getDay();return 0===t?7:t}function dA(e,t){return IP(XO.count(gP(e)-1,e),t,2)}function uA(e){var t=e.getDay();return t>=4||0===t?tP(e):tP.ceil(e)}function hA(e,t){return e=uA(e),IP(tP.count(gP(e),e)+(4===gP(e).getDay()),t,2)}function pA(e){return e.getDay()}function gA(e,t){return IP(JO.count(gP(e)-1,e),t,2)}function fA(e,t){return IP(e.getFullYear()%100,t,2)}function mA(e,t){return IP((e=uA(e)).getFullYear()%100,t,2)}function vA(e,t){return IP(e.getFullYear()%1e4,t,4)}function yA(e,t){var i=e.getDay();return IP((e=i>=4||0===i?tP(e):tP.ceil(e)).getFullYear()%1e4,t,4)}function CA(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+IP(t/60|0,"0",2)+IP(t%60,"0",2)}function bA(e,t){return IP(e.getUTCDate(),t,2)}function SA(e,t){return IP(e.getUTCHours(),t,2)}function xA(e,t){return IP(e.getUTCHours()%12||12,t,2)}function TA(e,t){return IP(1+KO.count(fP(e),e),t,3)}function wA(e,t){return IP(e.getUTCMilliseconds(),t,3)}function OA(e,t){return wA(e,t)+"000"}function PA(e,t){return IP(e.getUTCMonth()+1,t,2)}function AA(e,t){return IP(e.getUTCMinutes(),t,2)}function EA(e,t){return IP(e.getUTCSeconds(),t,2)}function kA(e){var t=e.getUTCDay();return 0===t?7:t}function IA(e,t){return IP(rP.count(fP(e)-1,e),t,2)}function DA(e){var t=e.getUTCDay();return t>=4||0===t?cP(e):cP.ceil(e)}function _A(e,t){return e=DA(e),IP(cP.count(fP(e),e)+(4===fP(e).getUTCDay()),t,2)}function NA(e){return e.getUTCDay()}function RA(e,t){return IP(aP.count(fP(e)-1,e),t,2)}function MA(e,t){return IP(e.getUTCFullYear()%100,t,2)}function LA(e,t){return IP((e=DA(e)).getUTCFullYear()%100,t,2)}function BA(e,t){return IP(e.getUTCFullYear()%1e4,t,4)}function FA(e,t){var i=e.getUTCDay();return IP((e=i>=4||0===i?cP(e):cP.ceil(e)).getUTCFullYear()%1e4,t,4)}function UA(){return"+0000"}function HA(){return"%"}function $A(e){return+e}function ZA(e){return Math.floor(+e/1e3)}function VA(e){return new Date(e)}function GA(e){return e instanceof Date?+e:+new Date(+e)}function jA(e,t,i,n,o,r,a,s,l,c){var d=gO(),u=d.invert,h=d.domain,p=c(".%L"),g=c(":%S"),f=c("%I:%M"),m=c("%I %p"),v=c("%a %d"),y=c("%b %d"),C=c("%B"),b=c("%Y");function S(e){return(l(e)<e?p:s(e)<e?g:a(e)<e?f:r(e)<e?m:n(e)<e?o(e)<e?v:y:i(e)<e?C:b)(e)}return d.invert=function(e){return new Date(u(e))},d.domain=function(e){return arguments.length?h(Array.from(e,GA)):h().map(VA)},d.ticks=function(t){var i=h();return e(i[0],i[i.length-1],null==t?10:t)},d.tickFormat=function(e,t){return null==t?S:c(t)},d.nice=function(e){var i=h();return e&&"function"==typeof e.range||(e=t(i[0],i[i.length-1],null==e?10:e)),e?h(function(e,t){var i,n=0,o=(e=e.slice()).length-1,r=e[n],a=e[o];return a<r&&(i=n,n=o,o=i,i=r,r=a,a=i),e[n]=t.floor(r),e[o]=t.ceil(a),e}(i,e)):d},d.copy=function(){return pO(d,jA(e,t,i,n,o,r,a,s,l,c))},d}function zA(){return fO.apply(jA(CP,bP,gP,hP,XO,WO,jO,VO,ZO,OP).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}wP=function(e){var t=e.dateTime,i=e.date,n=e.time,o=e.periods,r=e.days,a=e.shortDays,s=e.months,l=e.shortMonths,c=_P(o),d=NP(o),u=_P(r),h=NP(r),p=_P(a),g=NP(a),f=_P(s),m=NP(s),v=_P(l),y=NP(l),C={a:function(e){return a[e.getDay()]},A:function(e){return r[e.getDay()]},b:function(e){return l[e.getMonth()]},B:function(e){return s[e.getMonth()]},c:null,d:eA,e:eA,f:rA,g:mA,G:yA,H:tA,I:iA,j:nA,L:oA,m:aA,M:sA,p:function(e){return o[+(e.getHours()>=12)]},q:function(e){return 1+~~(e.getMonth()/3)},Q:$A,s:ZA,S:lA,u:cA,U:dA,V:hA,w:pA,W:gA,x:null,X:null,y:fA,Y:vA,Z:CA,"%":HA},b={a:function(e){return a[e.getUTCDay()]},A:function(e){return r[e.getUTCDay()]},b:function(e){return l[e.getUTCMonth()]},B:function(e){return s[e.getUTCMonth()]},c:null,d:bA,e:bA,f:OA,g:LA,G:FA,H:SA,I:xA,j:TA,L:wA,m:PA,M:AA,p:function(e){return o[+(e.getUTCHours()>=12)]},q:function(e){return 1+~~(e.getUTCMonth()/3)},Q:$A,s:ZA,S:EA,u:kA,U:IA,V:_A,w:NA,W:RA,x:null,X:null,y:MA,Y:BA,Z:UA,"%":HA},S={a:function(e,t,i){var n=p.exec(t.slice(i));return n?(e.w=g.get(n[0].toLowerCase()),i+n[0].length):-1},A:function(e,t,i){var n=u.exec(t.slice(i));return n?(e.w=h.get(n[0].toLowerCase()),i+n[0].length):-1},b:function(e,t,i){var n=v.exec(t.slice(i));return n?(e.m=y.get(n[0].toLowerCase()),i+n[0].length):-1},B:function(e,t,i){var n=f.exec(t.slice(i));return n?(e.m=m.get(n[0].toLowerCase()),i+n[0].length):-1},c:function(e,i,n){return w(e,t,i,n)},d:GP,e:GP,f:YP,g:HP,G:UP,H:zP,I:zP,j:jP,L:qP,m:VP,M:WP,p:function(e,t,i){var n=c.exec(t.slice(i));return n?(e.p=d.get(n[0].toLowerCase()),i+n[0].length):-1},q:ZP,Q:JP,s:QP,S:KP,u:MP,U:LP,V:BP,w:RP,W:FP,x:function(e,t,n){return w(e,i,t,n)},X:function(e,t,i){return w(e,n,t,i)},y:HP,Y:UP,Z:$P,"%":XP};function x(e,t){return function(i){var n,o,r,a=[],s=-1,l=0,c=e.length;for(i instanceof Date||(i=new Date(+i));++s<c;)37===e.charCodeAt(s)&&(a.push(e.slice(l,s)),null!=(o=PP[n=e.charAt(++s)])?n=e.charAt(++s):o="e"===n?" ":"0",(r=t[n])&&(n=r(i,o)),a.push(n),l=s+1);return a.push(e.slice(l,s)),a.join("")}}function T(e,t){return function(i){var n,o,r=TP(1900,void 0,1);if(w(r,e,i+="",0)!=i.length)return null;if("Q"in r)return new Date(r.Q);if("s"in r)return new Date(1e3*r.s+("L"in r?r.L:0));if(t&&!("Z"in r)&&(r.Z=0),"p"in r&&(r.H=r.H%12+12*r.p),void 0===r.m&&(r.m="q"in r?r.q:0),"V"in r){if(r.V<1||r.V>53)return null;"w"in r||(r.w=1),"Z"in r?(o=(n=xP(TP(r.y,0,1))).getUTCDay(),n=o>4||0===o?aP.ceil(n):aP(n),n=KO.offset(n,7*(r.V-1)),r.y=n.getUTCFullYear(),r.m=n.getUTCMonth(),r.d=n.getUTCDate()+(r.w+6)%7):(o=(n=SP(TP(r.y,0,1))).getDay(),n=o>4||0===o?JO.ceil(n):JO(n),n=WO.offset(n,7*(r.V-1)),r.y=n.getFullYear(),r.m=n.getMonth(),r.d=n.getDate()+(r.w+6)%7)}else("W"in r||"U"in r)&&("w"in r||(r.w="u"in r?r.u%7:"W"in r?1:0),o="Z"in r?xP(TP(r.y,0,1)).getUTCDay():SP(TP(r.y,0,1)).getDay(),r.m=0,r.d="W"in r?(r.w+6)%7+7*r.W-(o+5)%7:r.w+7*r.U-(o+6)%7);return"Z"in r?(r.H+=r.Z/100|0,r.M+=r.Z%100,xP(r)):SP(r)}}function w(e,t,i,n){for(var o,r,a=0,s=t.length,l=i.length;a<s;){if(n>=l)return-1;if(37===(o=t.charCodeAt(a++))){if(o=t.charAt(a++),!(r=S[o in PP?t.charAt(a++):o])||(n=r(e,i,n))<0)return-1}else if(o!=i.charCodeAt(n++))return-1}return n}return C.x=x(i,C),C.X=x(n,C),C.c=x(t,C),b.x=x(i,b),b.X=x(n,b),b.c=x(t,b),{format:function(e){var t=x(e+="",C);return t.toString=function(){return e},t},parse:function(e){var t=T(e+="",!1);return t.toString=function(){return e},t},utcFormat:function(e){var t=x(e+="",b);return t.toString=function(){return e},t},utcParse:function(e){var t=T(e+="",!0);return t.toString=function(){return e},t}}}({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]}),OP=wP.format,wP.parse,wP.utcFormat,wP.utcParse;var WA=o(69634),KA=o(32439);function qA(e,t,i){this.k=e,this.x=t,this.y=i}qA.prototype={constructor:qA,scale:function(e){return 1===e?this:new qA(this.k*e,this.x,this.y)},translate:function(e,t){return 0===e&0===t?this:new qA(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}},new qA(1,0,0),qA.prototype;var YA=class{getStyles(){return"#divPriceHistory .x.axis line {\n stroke: none;\n }\n #divPriceHistory .x.axis path {\n stroke: #EDEBE9;\n }\n #divPriceHistory .x.axis text {\n fill: #767676;\n font-size: 13px;\n font-weight: 700;\n margin-top: 5px;\n }\n #divPriceHistory text.x.axis {\n fill: #767676;\n font-size: 13px;\n font-weight: 700;\n margin-top: 5px;\n }\n #divPriceHistory tspan.currPriceDrop {\n font-size: 15px;\n line-height: 20px;\n fill: #22865E;\n font-weight: 700;\n letter-spacing: 0.02em;\n }\n\n #divPriceHistory tspan.textBig {\n font-size: 24px !important;\n line-height: 44px !important;\n font-weight: 400 !important;\n }\n #divPriceHistory tspan.textWhite {\n fill: #FFFFFF!important;\n }\n #divPriceHistory tspan.textBold {\n font-weight: 500;\n fill: #000000!important;\n }\n #divPriceHistory tspan.currPriceIncrease {\n font-size: 15px;\n line-height: 20px;\n fill: #D54034;\n font-weight: 700;\n letter-spacing: 0.02em;\n }\n #divPriceHistory tspan.currFairPrice {\n font-size: 15px;\n line-height: 20px;\n fill: #166FF5;\n font-weight: 700;\n letter-spacing: 0.02em;\n }\n #divPriceHistory tspan.price {\n font-size: 1.25em;\n line-height: 26px;\n fill: #000000;\n font-weight: 600;\n }\n #divPriceHistory tspan.label {\n font-size: 1.1em;\n line-height: 16px;\n fill: #727575;\n font-weight: 700;\n }\n #divPriceHistory tspan.desc {\n font-size: 1.125em;\n line-height: 16px;\n font-weight: 400;\n fill: #0000008D;\n }\n #divPriceHistory tspan.median {\n fill: #727575;\n }\n #divPriceHistorySection svg.recharts-surface {\n overflow: visible;\n }\n #btnPHInfo {\n display: flex;\n justify-content: center;\n align-items: center;\n }\n .gotItBtn:focus-visible {\n outline: 3px solid #878787;\n }\n .illustrationPercentageText {\n background-clip: text;\n -webkit-background-clip: text;\n }\n #hero-image-clickable:focus {\n outline-color: #898989;\n outline-width: 2px;\n outline-style: solid;\n }\n .ph-discoverPane {\n box-sizing: border-box;\n }\n .ph-discoverPane .fui-FluentProvider {\n padding: 0 !important;\n }\n .ph-discoverPane .fui-FluentProvider > div:first-child {\n box-shadow: unset !important;\n border-radius: 0;\n background-color: transparent;\n }\n @media (-ms-high-contrast: active) {\n #hero-image-clickable:focus {\n outline-color: ButtonText;\n }\n }\n @media (forced-colors: active) {\n #divPriceHistory .ph_head {\n color: windowText;\n }\n #divPriceHistory tspan.currPriceDrop {\n fill: windowText;\n }\n #divPriceHistory tspan.currPriceIncrease {\n fill: windowText;\n }\n #divPriceHistory tspan.currFairPrice {\n fill: windowText;\n }\n #divPriceHistory tspan.price {\n fill: windowText;\n }\n #divPriceHistory tspan.label {\n fill: windowText;\n }\n #divPriceHistory tspan.desc {\n fill: windowText;\n }\n #divPriceHistory tspan.median {\n fill: windowText;\n }\n }"}getDarkModeStyles(){return"\n #divPriceHistory tspan.currPriceDrop {\n fill: #4BDBA2;\n }\n #divPriceHistory tspan.currPriceIncrease {\n fill: #FFCBC7;\n }\n #divPriceHistory tspan.currFairPrice {\n fill: #86E5F3;\n }\n #divPriceHistory tspan.price {\n fill: #FFFFFF;\n }\n #divPriceHistory tspan.label {\n fill: #FFFFFF;\n }\n #divPriceHistory tspan.desc {\n fill: #FFFFFF;\n }\n #divPriceHistory tspan.median {\n fill: #FFFFFF;\n }\n #divPriceHistory tspan.textBold {\n fill: #FFFFFF!important;\n }\n .gotItBtn:focus-visible {\n outline: 3px solid #FFFFFF;\n }\n "}getSafariStyles(){return"\n #divPriceHistory tspan.currPriceIncrease {\n font-size: 15px;\n line-height: 20px;\n fill: #D54034;\n font-weight: 500;\n letter-spacing: 0.02em;\n }\n #divPriceHistory tspan.currFairPrice {\n font-size: 15px;\n line-height: 20px;\n fill: #166FF5;\n font-weight: 500;\n letter-spacing: 0.02em;\n }\n #divPriceHistory .x.axis text {\n fill: #767676;\n font-size: 13px;\n font-weight: 500;\n margin-top: 5px;\n }\n #divPriceHistory text.x.axis {\n fill: #767676;\n font-size: 13px;\n font-weight: 500;\n margin-top: 5px;\n }\n #divPriceHistory tspan.currPriceDrop {\n font-size: 15px;\n line-height: 20px;\n fill: #22865E;\n font-weight: 500;\n letter-spacing: 0.02em;\n }\n\n #divPriceHistory tspan.price {\n font-size: 1.25em;\n line-height: 26px;\n fill: #000000;\n font-weight: 500;\n }\n "}};const XA=(e,t)=>{"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),t?.())},JA=e=>{const t=(0,ch.useRef)(null);return(0,ch.useEffect)((()=>{e.focus&&t.current?.focus()}),[e.focus,e.selected]),e.selected?ch.createElement(tE,{ref:t,onClick:e.onClick,onKeyDown:t=>XA(t,e.onClick),onBlur:e.onFocusOut,tabIndex:0,"aria-checked":!0,role:"radio"},ch.createElement(QA,null,e.content)):ch.createElement(iE,{onClick:e.onClick,ref:t,onKeyDown:t=>XA(t,e.onClick),tabIndex:0,"aria-checked":!1,role:"radio"},ch.createElement(eE,null,e.content))},QA=bm.div`
font-family: "Segoe UI", "Roboto", Helvetica, Verdana, sans-serif;;
font-style: normal;
font-weight: 600;
font-size: 12px;
line-height: 16px;
color: #FFFFFF;
`,eE=bm(QA)`
font-weight: 400;
color: rgba(0, 0, 0, 0.560784);
`,tE=bm.div`
box-sizing: border-box;
display: flex;
flex-direction: row;
align-items: center;
padding: 6px 12px;
gap: 4px;
height: 32px;
background: #2C62DB;
border: 1px solid rgba(0, 0, 0, 0.02);
border-radius: 20px;
margin-right: 5px;
:hover {
cursor: pointer;
}
`,iE=bm(tE)`
background: rgba(255, 255, 255, 0.85);
border: 1px solid rgba(0, 0, 0, 0.0588);
`,nE=e=>ch.createElement(CE,null,e.productCurrentPrice?ch.createElement(pE,null,e.currencySign,e.productCurrentPrice):null,e.productOrgPrice&&e.productCurrentPrice&&parseFloat(e.productOrgPrice)>parseFloat(e.productCurrentPrice)?ch.createElement(vE,null,ch.createElement("del",null,e.currencySign,e.productOrgPrice)):null),oE={drop:"cjk/pricedrop.svg",increase:"cjk/priceincrease.svg",stable:"cjk/pricestable.svg"},rE=e=>{let t=0;for(const i of[IE.THREE_MONTHS,IE.SIX_MONTHS,IE.ONE_MONTH]){const n=e.timeRangeEnumList.indexOf(i);if(n>=0){t=n;break}}const[i,n]=(0,ch.useState)(t),[o,r]=(0,ch.useState)(-1);return(0,ch.useEffect)((()=>{e.rangeButtonClickListener(3===e.timeDurationTitle?.length?1:0)}),[]),ch.createElement(gm,{theme:e.isDarkMode?Bm:Lm},ch.createElement(sE,{style:e.isNotification?{marginLeft:"12px",marginRight:"12px"}:{}},e.producTitle&&""!==e.producTitle.trim()&&ch.createElement(lE,null,e.productImgUrl&&""!==e.productImgUrl.trim()&&ch.createElement(Em,{safeFetchImg:e.safeFetchImg,pageHandler:e.pageHandler,productImgUrl:e.productImgUrl,defaultProductImgUrl:e.svgBasePath+"common/defaultProduct.svg",img:aE}),ch.createElement(dE,null,ch.createElement(hE,{title:e.producTitle},e.producTitle),ch.createElement(nE,{currencySign:e.currencySign,productCurrentPrice:e.productCurrentPrice,productOrgPrice:e.productOrgPrice}),ch.createElement(cE,null,ch.createElement(yE,null,ch.createElement("img",{"aria-hidden":!0,src:e.svgBasePath+oE[e.priceTrend]}),(a=e.priceTrend,s=e.priceHintContent,"drop"===a?ch.createElement(gE,null,s):"increase"===a?ch.createElement(fE,null,s):ch.createElement(mE,null,s))),function(e,t){const i=(0,ch.useRef)(null),n=e.createInfoIconTooltip(t),o=ch.createElement("div",{style:{display:"flex",justifyContent:"center",alignItems:"center",marginLeft:"8px"},ref:i});return(0,ch.useEffect)((()=>{i.current&&!i.current.hasChildNodes()&&i.current.appendChild(n)}),[n]),o}(e.tooltipUtilities,e.tooltipContent)))),ch.createElement(uE,{role:"radiogroup","arial-label":"Time Range"},e.timeDurationTitle.map(((t,a,s)=>ch.createElement(JA,{key:a,content:t,focus:o===a,selected:i===a,onFocusOut:()=>{a===o&&r(-1)},onClick:()=>{r(a),n(a),e.rangeButtonClickListener(a),e.pageHandler.RecordAsUserAction(K.bS.CJK_PRICE_HISTORY_SET_TIMERANGE),e.pageHandler.RecordAsCjkScenario(Hg.ACTION,Ug.PRICE_HISTORY_SET_TIMERANGE)}}))))));var a,s},aE=bm.img`
width: 119px;
height: 119px;
margin-left: 20px;
border-radius: 8px;
`,sE=bm.div`
display: flex;
flex-direction: column;
justify-content: space-around;
justify-items: flex-start;
column-gap: 12px;
border-bottom: 1px solid rgba(0, 0, 0, 0.03);
padding-top: 20px;
padding-bottom: 20px;
`,lE=bm.div`
display: flex;
flex-direction: row;
justify-content: flex-start;
margin-bottom: 20px;
`,cE=bm.div`
display: flex;
flex-direction: row;
margin-top: 20px;
`,dE=bm.div`
display: flex;
flex-direction: column;
margin-left: 20px;
`,uE=bm.div`
display: flex;
flex-direction: row;
margin-top: 20px;
margin-left: 20px;
`,hE=bm.div`
font-family: "Segoe UI", "Roboto", Helvetica, Verdana, sans-serif;
font-style: normal;
font-weight: 400;
font-size: 14px;
line-height: 20px;
text-align: left;
color: ${e=>e.theme.textColor};
margin-bottom: 8px;
display: -webkit-box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
overflow: hidden;
`,pE=bm.div`
font-family: "Roboto", "Segoe UI", Helvetica, Verdana, sans-serif;
font-style: normal;
font-weight: 700;
font-size: 16px;
line-height: 22px;
color: ${e=>e.theme.priceHistory.priceColor};
`,gE=bm.div`
font-family: "Segoe UI", "Roboto", Helvetica, Verdana, sans-serif;
font-style: normal;
font-weight: 600;
font-size: 14px;
line-height: 20px;
color: #0F7B0F;
flex: none;
order: 1;
flex-grow: 0;
margin-left: 10px;
`,fE=bm(gE)`
letter-spacing: -0.04em;
color: #C42B1C;
`,mE=bm(gE)`
letter-spacing: -0.04em;
color: ${e=>e.theme.priceHistory.priceStableColor};
`,vE=bm.div`
font-family: "Roboto", "Segoe UI", Helvetica, Verdana, sans-serif;
font-style: normal;
font-weight: 400;
font-size: 12px;
line-height: 16px;
text-decoration-line: line-through;
color: ${e=>e.theme.priceHistory.priceOriColor};
margin-left: 10px;
`,yE=bm.div`
display: flex;
flex-direction: row;
`,CE=bm.div`
display: flex;
flex-direction: row;
justify-content: flex-start;
align-items: center;
`,bE="divPriceHistoryCjkSection";class SE extends Qu{constructor(e,t,i,n){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"ignoreTimeRangeCheck",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandler",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"footerUtilities",void 0),(0,s.Z)(this,"tooltipUtilities",void 0),(0,s.Z)(this,"telemetryHandler",void 0),(0,s.Z)(this,"priceHistoryModule",void 0),(0,s.Z)(this,"wasPriceHistorySectionExpanded",void 0),(0,s.Z)(this,"uxUtilities",void 0),(0,s.Z)(this,"isNotification",void 0),(0,s.Z)(this,"priceHistoryTitle",void 0),(0,s.Z)(this,"cjkDataVendor",void 0),this.logModule=i.logModule,this.stateManagement=e,this.pageHandler=i.pageHandlerModule,this.flyoutData=t,this.utilities=i.viewModulesUtilities,this.storageHandler=i.storageHandler,this.footerUtilities=i.footerUtilities,this.tooltipUtilities=i.tooltipUtilities,this.telemetryHandler=i.telemetryHandler,this.wasPriceHistorySectionExpanded=!1,this.assets=new YA,this.priceHistoryModule=n,this.cjkDataVendor=t.common.cjkDataVendor,this.uxUtilities=i,this.isNotification=!1,this.ignoreTimeRangeCheck=!1}GetModuleName(){return r.ModuleNames.PRICEHISTORY}ShouldRenderModule(){return Promise.resolve(!0)}async renderModule(){const e=this.flyoutData?.dataStoreModule?.PriceHistoryData?.DailyPrices;if(!e||e.length<2)return Promise.resolve(null);const{common:t}=this.flyoutData;this.utilities.applyStyles(t.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());const i=document.createElement("msft-edge-shopping-section");i.id=bE,i.accordion=!0,i.expanded=!1,i.titleText=this.flyoutData.strings.phSectionTitle,i.isCjk=!0,await this.renderCjkPriceHistoryComponent(i);let n=this.wasPriceHistorySectionExpanded;const o=()=>{if(n&&(this.pageHandler.RecordAsUserAction(K.bS.HIDE_PRICE_HISTORY),this.pageHandler.RecordAsCjkScenario(Hg.ACTION,Ug.PRICE_HISTORY),this.cjkDataVendor&&this.cjkDataVendor in $g&&this.pageHandler.RecordAsCjkScenario(Hg.ACTION+$g[this.cjkDataVendor],Ug.PRICE_HISTORY),i&&i.removeEventListener("click",o)),n=!0,i){const e=i.shadowRoot;if(e){const t=e.querySelector("fluent-accordion-item");t&&(t.classList.contains("expanded")||(this.pageHandler.RecordAsUserAction(K.bS.VIEW_PRICE_HISTORY),this.pageHandler.RecordAsUserAction(K.bS.CJK_VIEW_PRICE_HISTORY),this.pageHandler.RecordAsUserEngagement(q.FV.VIEW_PRICE_HISTORY,this.flyoutData.common.popupOrigination),this.pageHandler.RecordAsCjkScenario(Hg.ACTION,Ug.PRICE_HISTORY),this.cjkDataVendor&&this.cjkDataVendor in $g&&this.pageHandler.RecordAsCjkScenario(Hg.ACTION+$g[this.cjkDataVendor],Ug.PRICE_HISTORY)))}}};i.addEventListener("click",o);const a=this.CreateModule(i,r.H7.PRICEHISTORY,r.ModuleNames.PRICEHISTORY,r.$k.CONTEXTUAL,r.SV.LIST);return this.pageHandler.RecordAsCjkScenario(Hg.SHOW,Ug.PRICE_HISTORY),this.cjkDataVendor&&this.cjkDataVendor in $g&&this.pageHandler.RecordAsCjkScenario(Hg.SHOW+$g[this.cjkDataVendor],Ug.PRICE_HISTORY),Promise.resolve(a)}setTimeRange(e){SE.timeRange=e}getTimeRange(){return SE.timeRange??IE.THREE_MONTHS}async renderCjkPriceHistoryComponent(e){const t=this.flyoutData.dataStoreModule.PriceHistoryData?.DailyPrices;let i="",n="drop",o=0;this.flyoutData.dataStoreModule.PriceHistoryData?.ProductDetails?.triggerPriceHistoryMinorDropAlert?(o=this.daysSinceLowestPrice(t),i=o>0?(0,T.fZ)("cjkPHDaysLowest",this.flyoutData.strings.cjkPHDaysLowest,o.toString()):this.flyoutData.strings.phNewPriceLower,n="drop",this.stateManagement.setState(Ku.IY.shouldChangeTitle,!0)):this.flyoutData.dataStoreModule.PriceHistoryData?.ProductDetails?.triggerPriceHistoryIncreasedAlert?(i=this.flyoutData.strings.phNewPriceHigher,n="increase",this.stateManagement.setState(Ku.IY.shouldChangeTitle,!0)):(i=this.flyoutData.strings.phPriceStable,n="stable",this.stateManagement.setState(Ku.IY.shouldChangeTitle,!1));let r=this.flyoutData.dataStoreModule.PriceHistoryData?.ProductDetails?.imageUrl;r&&0!==r.length||(r=""),r&&r.length>0&&(r=r.replace("http:","https:"));const a=[],s=[];this.shouldRenderPriceHistorySectionButton(t,IE.SIX_MONTHS,IE.THREE_MONTHS)&&(a.push(this.flyoutData.strings.cjkPHTimeDurSixMonth),s.push(IE.SIX_MONTHS)),this.shouldRenderPriceHistorySectionButton(t,IE.THREE_MONTHS,IE.ONE_MONTH)&&(a.push(this.flyoutData.strings.cjkPHTimeDurThreeMonth),s.push(IE.THREE_MONTHS)),this.shouldRenderPriceHistorySectionButton(t,IE.ONE_MONTH)&&(a.push(this.flyoutData.strings.cjkPHTimeDurOneMonth),s.push(IE.ONE_MONTH));const l=this.flyoutData.dataStoreModule.PriceHistoryData?.ProductDetails?.price,c=this.flyoutData.dataStoreModule.PriceHistoryData?.ProductDetails.originalPrice,d=this.flyoutData.dataStoreModule.PriceHistoryData?.ProductDetails?.currency||"$",u=this.flyoutData.dataStoreModule.PriceHistoryData?.MedianPrice?`${d}${this.utilities.toFixedSafe(this.flyoutData.dataStoreModule.PriceHistoryData?.MedianPrice,2)}`:"",h=(0,T.fZ)("phTooltipText",this.flyoutData.strings.phTooltipText,u);var p,g;p=ch.createElement(rE,{isDarkMode:this.utilities.isDarkMode(),productImgUrl:r,productCurrentPrice:l??"Unknown",productOrgPrice:c??"Unknown",producTitle:this.flyoutData.dataStoreModule.PriceHistoryData?.ProductDetails?.title||"",currencySign:"¥",timeDurationTitle:a,timeRangeEnumList:s,svgBasePath:this.flyoutData.common.resourcesEndpoint,priceTrend:n,priceHintContent:i,tooltipUtilities:this.tooltipUtilities,tooltipContent:h,rangeButtonClickListener:(async t=>{const i=s[t];this.setTimeRange(i),await this.priceHistoryModule.renderPriceHistoryGraphForCJKV2(e,!0)}).bind(this),isNotification:this.isNotification,pageHandler:this.pageHandler,safeFetchImg:this.flyoutData.common.isCjkShouldGetSafeImage&&this.pageHandler.IsMessageAllowed("getSafeImage")}),g=e,sp.render(p,g),this.flyoutData.dataStoreModule.PriceHistoryData&&await this.priceHistoryModule.renderPriceHistoryGraphForCJKV2(e),this.isNotification&&gn.SO.queueUpdate((()=>{const t=e.querySelector("#priceDropNotifChart");t&&(t.style.marginBottom="16px")}))}populateMainHeader(){const e=this.flyoutData.common.shopping.querySelector(`#${bE}`);e&&(e.style.marginTop="0px",e.style.textAlign="start",e.style.marginLeft="auto",e.style.width="100%",e.slot="header-content",this.priceHistoryTitle&&(this.priceHistoryTitle.style.display="block"),gn.SO.queueUpdate((()=>{this.uxUtilities.viewModulesUtilities.handleCjkSectionAsTopModuleStyle(e)})))}daysSinceLowestPrice(e){let t=0;const i=e[e.length-1];for(let n=e.length-2;n>=0;n--)e[n].price>=i.price&&t++;return t>=30?t:0}shouldRenderPriceHistorySectionButton(e,t,i){const n={[IE.SIX_MONTHS]:15552e6,[IE.THREE_MONTHS]:7776e6,[IE.ONE_MONTH]:2592e6},o=Date.now(),r=o-n[t],a=o-(i?n[i]:0);return(e?e.filter((e=>new Date(e.dtg).getTime()>r&&new Date(e.dtg).getTime()<=a)):[]).length>=2}}(0,s.Z)(SE,"timeRange",void 0);var xE=SE;function TE(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}const wE="#008847",OE="#DF352C",PE="#166FF5",AE="#4BDBA2",EE="#FFA39C",kE="#34D3EB";let IE=function(e){return e[e.SIX_MONTHS=0]="SIX_MONTHS",e[e.THREE_MONTHS=1]="THREE_MONTHS",e[e.ONE_MONTH=2]="ONE_MONTH",e}({});class DE extends Qu{constructor(e,t,i){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"refreshCount",0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"autoOpenControllerUtilities",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"footerUtilities",void 0),(0,s.Z)(this,"tooltipUtilities",void 0),(0,s.Z)(this,"telemetryHandler",void 0),(0,s.Z)(this,"discoverTelemetryHandler",void 0),(0,s.Z)(this,"dataValidationUtilities",void 0),(0,s.Z)(this,"todayString",void 0),(0,s.Z)(this,"lowString",void 0),(0,s.Z)(this,"highString",void 0),(0,s.Z)(this,"wasPriceHistorySectionExpanded",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"graphWidth",void 0),(0,s.Z)(this,"maxRefresh",100),(0,s.Z)(this,"sectionId","divPriceHistorySection"),(0,s.Z)(this,"priceHistoryTitle",void 0),(0,s.Z)(this,"useNewPriceHistory",!1),(0,s.Z)(this,"uxUutilities",void 0),(0,s.Z)(this,"isCjkEnabled",!1),(0,s.Z)(this,"bouncePeriodMs",200),this.logModule=i.logModule,this.stateManagement=e,this.pageHandlerModule=i.pageHandlerModule,this.flyoutData=t,this.todayString=this.flyoutData.strings.phToday,this.lowString=this.flyoutData.strings.phLow,this.highString=this.flyoutData.strings.phHigh,this.utilities=i.viewModulesUtilities,this.storageHandler=i.storageHandler,this.footerUtilities=i.footerUtilities,this.tooltipUtilities=i.tooltipUtilities,this.telemetryHandler=i.telemetryHandler,this.discoverTelemetryHandler=i.discoverTelemetryHandler,this.dataValidationUtilities=i.dataValidationUtilities,this.wasPriceHistorySectionExpanded=!1,this.autoOpenControllerUtilities=i.autoOpenControllerUtilities,this.assets=new YA,this.uxUutilities=i,this.isCjkEnabled=t.common.isCJKEnabled,this.telemetryUtilities=i.telemetryHandler,this.isCjkEnabled&&(DE.priceHistoryCjkImpl=new xE(this.stateManagement,this.flyoutData,this.uxUutilities,this))}GetModuleName(){return r.ModuleNames.PRICEHISTORY}CalculateRanking(){const e=this.flyoutData.dataStoreModule.PriceHistoryData;if(e){const t=e.getPriceHistoryType();if(t===de.sh.PRICEDROP)return r.zz.SaveMoneyPage;if(t===de.sh.FAIRPRICE)return r.zz.InformPage;if(t===de.sh.PRICEINCREASE)return r.zz.InformPage}return r.zz.Unknown}ShouldRenderModule(){this.useNewPriceHistory=!0;let e=new fS(this.flyoutData).shouldRender();if(this.stateManagement.addEventListener(Ku.e1.ModulesRendered,this.updatePriceGraph.bind(this)),this.stateManagement.addEventListener(Ku.e1.onFlyoutResize,this.updatePriceGraph.bind(this)),this.isCjkEnabled&&e){e=!1;for(const t of[IE.THREE_MONTHS,IE.SIX_MONTHS,IE.ONE_MONTH]){const i=this.filterByDateRange(this.flyoutData.dataStoreModule.PriceHistoryData?.DailyPrices,t);if(i&&i.length>=2){e=!0,DE.priceHistoryCjkImpl&&DE.priceHistoryCjkImpl.setTimeRange(t);break}}}return Promise.resolve(e)}async renderModule(){if(this.isCjkEnabled){const e=DE.priceHistoryCjkImpl?.renderModule();return e??null}const{common:e,dataStoreModule:t,strings:n}=this.flyoutData,o=t.PriceHistoryData,a=this.useNewPriceHistory?r.SV.LIST:r.SV.BLOCK;if(!o)return null;if(this.dataValidationUtilities.validatePriceWithEntityExtractionResults(e.extractedEntity,o.CurrentPrice?.toString(),this.GetModuleName()),this.utilities.applyStyles(e.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),(0,dt.tB)(this.flyoutData)){const t=new ly;this.utilities.applyStyles(e.shopping,t.getStyles()),this.utilities.applyStyles(e.shopping,this.assets.getSafariStyles())}const s=document.createElement("msft-edge-shopping-section");if(s.id=this.sectionId,s.accordion=!0,s.expanded=!1,s.titleText=n.phSectionTitle,this.flyoutData.common.isDiscoverPane){s.style.backgroundColor=this.utilities.isDarkMode()?"##424242":"#ffffff",s.classList.add("ph-discoverPane"),s.style.padding=this.useNewPriceHistory?"0":"6px 10px";const e=()=>{this.discoverTelemetryHandler.LogEventTelemetry(i.xu.PriceHistoryDiscoverHover,"Price History Discover Hover","",r.ModuleNames.PRICEHISTORY),s.removeEventListener("mouseover",e)};s.addEventListener("mouseover",e)}await this.populatePriceList(o,s);const l=this.pageHandlerModule;let c=this.wasPriceHistorySectionExpanded;const d=(0,dt.tB)(this.flyoutData);if(s.addEventListener("click",(function e(){if(c&&(l.RecordAsUserAction(K.bS.HIDE_PRICE_HISTORY),s&&s.removeEventListener("click",e)),c=!0,s){const e=s.shadowRoot;if(e){const t=e.querySelector("fluent-accordion-item");if(t){if(d){const e=t.shadowRoot?.querySelector(".region");e&&e.classList.add("safari-region")}t.classList.contains("expanded")||(l.RecordAsUserAction(K.bS.VIEW_PRICE_HISTORY),l.RecordAsUserEngagement(q.FV.VIEW_PRICE_HISTORY,this.flyoutData.common.popupOrigination))}}}})),s.children&&s.children.length>0){const e=this.CreateModule(s,r.H7.PRICEHISTORY,r.ModuleNames.PRICEHISTORY,r.$k.CONTEXTUAL,a);return Promise.resolve(e)}return Promise.resolve(null)}populateMainHeader(){if(this.isCjkEnabled)return void DE.priceHistoryCjkImpl?.populateMainHeader();const e=this.flyoutData.common.shopping.querySelector(`#${this.sectionId}`);e&&(e.style.marginTop="10px",e.style.textAlign="start",e.style.marginLeft="auto",e.style.width="100%",e.slot="header-content",this.priceHistoryTitle&&(this.priceHistoryTitle.style.display="block")),(0,dt.tB)(this.flyoutData)&&this.utilities.applyStyles(this.flyoutData.common.shopping,sy.GetNoHeaderBackgroundStyles())}PostProcessing(e,n,o){const a=0===n;this.flyoutData.common.isDiscoverPane&&a&&this.discoverTelemetryHandler.LogEventTelemetry(i.xu.FlyoutDiscoverPriceHistoryTrigger,"Price History Discover View","",r.ModuleNames.PRICEHISTORY,{},this.getShoppingContent());const s=this.flyoutData.dataStoreModule.PriceHistoryData;let l=!1;try{l="4"===new URL(this.flyoutData.common.lastCommittedURL).searchParams.get("auto_show_edge_shopping_flyout")}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,"Invalid lastCommittedURL",n)}if(this.flyoutData.common.openedWith&&this.flyoutData.common.openedWith===r.Te.Auto&&!l&&s&&s.TriggerPriceHistoryAlert&&this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_PRICE_HISTORY)if(a){const e=new t.Z(i.xu.FlyoutAutoPriceHistoryTrigger);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"",e)}else{const e=this.stateManagement.getState(Ku.IY.topModuleName),n=new t.Z(i.xu.ErrorWrongAutoTrigger);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,`Price History - Wrong module in pole position ${e}`,n)}this.stateManagement.addEventListener(Ku.e1.FocusProductTracking,(()=>{o?.scrollIntoView({behavior:"smooth"})})),x.ZP.scrollToModuleIfTargeted(o,this.GetModuleName())}getPriceDifference(e,t){const i=this.getStrikeoutPricePoint(e,t)?.minPrice,n=e.CurrentPrice;return i?Math.abs(n-i):void 0}createPriceHistoryTypeIllustration(e,t=!1){const i=(0,Y.Ux)("DIV");i.className="ph_ill",i.style.placeSelf="center";const n=(0,Y.Ux)("IMG",{style:"display: flex; place-self: end; border-radius: 2px; margin-bottom: 6px;"});n.setAttribute("aria-hidden","true"),e===de.sh.PRICEDROP?n.src=this.flyoutData.common.resourcesEndpoint+"priceHistory/decreaseTrend.svg":e===de.sh.PRICEINCREASE?n.src=this.flyoutData.common.resourcesEndpoint+"priceHistory/increaseTrend.svg":n.src=this.flyoutData.common.resourcesEndpoint+"priceHistory/stableTrend.svg";const o=this.utilities.isDarkMode()?"#FFFFFF":"rgba(0, 0, 0, 0.83)",r=(0,Y.Ux)("span",{style:`\n font-size: 44px;\n color: transparent;\n line-height: 44px;\n font-weight: 400;\n display: flex;\n flex-direction: row;\n column-gap: 8px;\n background-image: ${this.utilities.isDarkMode()?"linear-gradient(267.26deg, #5EC4FE 0%, #5EC4FE 100%)":"linear-gradient(267.26deg, #166FF5 0%, #166FF5 100%)"};\n background-clip: text;\n -webkit-background-clip: text;\n \n `});r.id="priceHistoryPercentage",r.className="illustrationPercentageText";const a=(0,dt.tB)(this.flyoutData)?(0,Y.Ux)("div",{style:`\n font-size: 20px;\n line-height: 27px;\n color: ${o};\n text-align: left;\n font-weight: 400;\n `}):(0,Y.Ux)("div",{style:`\n font-size: 20px;\n line-height: 27px;\n color: ${o};\n text-align: left;\n font-weight: 600;\n `});if(a.id="priceHistoryType",this.utilities.shouldRenderSmallNotification()&&(a.style.fontSize="12px",a.style.lineHeight="16px"),e===de.sh.PRICEDROP||e===de.sh.PRICEINCREASE)gn.SO.queueUpdate((()=>this.addPricePercentage(e,r,a,i,n)));else{i.style.fontSize="20px",i.style.lineHeight="34px",i.style.fontWeight="600",i.style.color=o,r.textContent=this.flyoutData.strings.phStableLabel,r.style.fontSize="32px",n.style.marginBottom="6px";const e=(0,Y.Ux)("DIV");e.appendChild(r),r.appendChild(n),(0,T.B7)(i,this.flyoutData.strings.phPriceStableRefresh,e)}return(0,dt.tB)(this.flyoutData)&&(i.style.fontWeight="500"),i}renderPriceHistoryGraph(e){const t=(0,Y.Ux)("DIV",{style:"display: none;"});t.id="priceDropNotifChart";const i=(0,Y.Ux)("DIV",{style:"margin-top: 16px;"});i.id="divPriceHistory",this.utilities.shouldRenderSmallNotification()&&(i.style.marginTop="4px"),t.appendChild(i);const n=document.getElementById("priceDropNotifChart")?document.getElementById("priceDropNotifChart"):t;if(n&&(this.flyoutData.common.isPane||(n.style.paddingLeft="12px",n.style.paddingRight="12px"),n.style.display="block"),"zh-cn"===this.flyoutData.common.afdMarket){const i=e.querySelector("#divIntDisclaimer");i?e.insertBefore(t,i):e.appendChild(t)}else e.appendChild(t)}async renderPriceHistoryGraphForCJKV2(t,n=!1){if(!this.flyoutData.dataStoreModule.PriceHistoryData)return;const o=function(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?TE(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):TE(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}({},this.flyoutData.dataStoreModule.PriceHistoryData),a=DE.priceHistoryCjkImpl?.getTimeRange(),l=this.filterByDateRange(o?.DailyPrices,a);if(l.length<2)return;o.DailyPrices=l;let c=0;const d=async()=>{0===c&&e.R.isExperimentActive(f.H.CouponsPersonalization)&&await this.autoOpenControllerUtilities.userEngagementStoreManager.addEngagement(q.w1.POSITIVE,this.flyoutData.common.popupOrigination,r.ModuleNames.PRICEHISTORY,cy.e.userEngagementPriceHistoryWeights.priceHistoryGraphHoverWeight),c=Date.now()},u=()=>{this.sendPriceHistoryDwellTimeTelemery(c,i.xu.PriceHistoryDwellTimeHover,"hover time over graph")};if(n){const e=document.getElementById("priceChartCjkV2");if(e){const t=await hp(o,this.utilities.isDarkMode(),this.flyoutData.strings,d,u);gp((()=>t),e)}return}const h=(0,Y.Ux)("DIV",{style:"display: none;"});h.id="priceChartCjkV2";const p=document.getElementById("priceChartCjkV2")?document.getElementById("priceChartCjkV2"):h;p&&(p.style.display="block"),t.appendChild(h);const g=await hp(o,this.utilities.isDarkMode(),this.flyoutData.strings,d,u);gp((()=>g),h)}updatePriceGraphForCjkV2(e=!1){this.updatePriceGraph(e)}updatePriceGraphForCjk(e=!1){this.updatePriceGraph(e)}filterByDateRange(e,t){const i={[IE.SIX_MONTHS]:15552e6,[IE.THREE_MONTHS]:7776e6,[IE.ONE_MONTH]:2592e6},n=Date.now(),o=n-i[t];return e?e.filter((e=>new Date(e.dtg).getTime()>=o&&new Date(e.dtg).getTime()<=n)):[]}addPricePercentage(e,t,i,n,o){if(e===de.sh.PRICEDROP){const e=this.flyoutData.dataStoreModule.PriceHistoryData?.DailyPriceDropPercentage;let r,a=!1;null!=e&&(r=this.utilities.toFixedSafe(Math.abs(e),0),a=!0),t.textContent=r+"% ",t.style.backgroundImage=this.utilities.isDarkMode()?"linear-gradient(267.48deg, #35D95B 0%, #35D95B 0%)":"linear-gradient(267.48deg, #008A21 0%, #008A21 0%)",t.style.fontWeight="600",i.textContent=this.flyoutData.strings.phPriceDrop.toLowerCase(),a&&(t.appendChild(o),n.appendChild(t)),n.appendChild(i)}else if(e===de.sh.PRICEINCREASE){const e=this.flyoutData.dataStoreModule.PriceHistoryData?.DailyPriceDropPercentage;let r,a=!1;null!=e&&(r=this.utilities.toFixedSafe(Math.abs(e),0),a=!0),t.textContent=r+"% ",t.style.backgroundImage=this.utilities.isDarkMode()?"linear-gradient(267.48deg, #F2364F 0%, #F2364F 0%)":"linear-gradient(267.48deg, #D64400 0%, #D64400 0%)",i.textContent=this.flyoutData.strings.phPriceIncrease.toLowerCase(),a&&(t.appendChild(o),n.appendChild(t)),n.appendChild(i)}}getGraphAriaLabel(e,t,i,n){if(!n)return"";if(!e||i===de.sh.FAIRPRICE)return(0,T.fZ)("phGraphLabel",this.flyoutData.strings.phGraphLabel,`${n}${t.minPrice}`);if(e&&n){let o="",r="";switch(i){case de.sh.PRICEDROP:o=this.highString,r="decreased";break;case de.sh.PRICEINCREASE:o=this.lowString,r="increased"}const a=this.isCjkEnabled?"%Y/%-m/%-d":"%B %d";return`The ${o} price was ${n}${e.minPrice} on ${OP(a)(e.dtg)}, and today it has ${r} to ${n}${t.minPrice}`}return""}drawPriceHistoryChart(t,n,o,a){let s;const l=t.DailyPrices;if(this.isCjkEnabled){const e=DE.priceHistoryCjkImpl?.getTimeRange();s=this.filterByDateRange(l,e)}else s=l;const c=s;if(c.length<2)return null;const d=this.isLastPriceDateToday(t);let u=this.isCjkEnabled?184:126,h=u+15;this.utilities.shouldRenderSmallNotification()&&(u=100,h=110);const p=zA().range([0,a]),g=DO().range([100,0]);p.domain(function(e,t){let i,n;if(void 0===t)for(const t of e)null!=t&&(void 0===i?t>=t&&(i=n=t):(i>t&&(i=t),n<t&&(n=t)));else{let o=-1;for(let r of e)null!=(r=t(r,++o))&&(void 0===i?r>=r&&(i=n=r):(i>r&&(i=r),n<r&&(n=r)))}return[i,n]}(c,(e=>e.dtg))),g.domain([IS(c,(e=>e.minPrice/1.2)),kS(c,(e=>1.2*e.minPrice))]);const m=c[0],v=c[c.length-1],y=this.getCriticalPoints(c),C=y.length>0?this.getMinCriticalPoint(y,v):null,b=y.length>0?this.getMaxCriticalPoint(y,c[c.length-1],C&&C.minPrice?C.minPrice:Number.NEGATIVE_INFINITY,p):null,S=this.getLowPoint(m,v,C),x=this.getHighPoint(m,v,b),w=t.MedianPrice,O={x:v.dtg,y:v.minPrice,text:this.todayString},P=S?{text:this.lowString,x:S.dtg,y:S.minPrice}:null,A=x?{text:this.highString,x:x.dtg,y:x.minPrice}:null,E=[...P?[P]:[],...A?[A]:[],O],k=this.getStrikeoutPricePoint(t,n),I=this.getGraphAriaLabel(k,v,n,o),D=WA.Z().x((e=>p(e.dtg))).y((e=>g(e.minPrice))).curve(KA.Z),_=document.createElementNS("http://www.w3.org/2000/svg","svg");P||(u-=30,h-=30);let N=0;const R=(0,dt.tB)(this.flyoutData),M=function(e){return"string"==typeof e?new Hx([[document.querySelector(e)]],[document.documentElement]):new Hx([[e]],Ux)}(_).attr("aria-label",I).attr("width",a).attr("height",h).attr("tabindex",R?"-1":"0").attr("viewBox",`0 0 ${a+50+50} ${u}`).on("mouseenter",(async()=>{0===N&&e.R.isExperimentActive(f.H.CouponsPersonalization)&&await this.autoOpenControllerUtilities.userEngagementStoreManager.addEngagement(q.w1.POSITIVE,this.flyoutData.common.popupOrigination,r.ModuleNames.PRICEHISTORY,cy.e.userEngagementPriceHistoryWeights.priceHistoryGraphHoverWeight),N=Date.now()})).on("mouseleave",(e=>{this.sendPriceHistoryDwellTimeTelemery(N,i.xu.PriceHistoryDwellTimeHover,"hover time over graph")})).append("g").attr("transform","translate(65, 10)"),L=M.append("defs"),B=M.append("g").style("opacity",1).style("transition-duration","0.4s").style("transition-property","opacity");this.setUpMedianLine(w,B,p,g,a,o,A,P);const F=L.append("linearGradient").attr("x1","319.56").attr("y1","38.583").attr("x2","-4.00001").attr("y2","38.583").attr("gradientUnits","userSpaceOnUse").attr("id","linear-gradient");F.append("stop").attr("stop-color",this.utilities.isDarkMode()?"#A8A8A8":"#000000"),F.append("stop").attr("offset","0.979167").attr("stop-color",this.utilities.isDarkMode()?"#A8A8A8":"#000000"),F.append("stop").attr("stop-color",this.utilities.isDarkMode()?"#A8A8A8":"#000000"),L.append("linearGradient").attr("x1","1.67776e-07").attr("y1","22").attr("x2","112.278").attr("y2","-6.73097").attr("gradientUnits","userSpaceOnUse").attr("id","linear-gradient-today-drop").append("stop").attr("offset","1").attr("stop-color","#810BE3"),M.append("path").data([c]).attr("d",D).style("fill","none").style("stroke","url(#linear-gradient)").style("stroke-width",2),B.append("line").attr("x1",p(O.x)).attr("y1",g(O.y)).attr("x2",p(O.x)).attr("y2",P?-25:10).style("stroke-width",1).style("stroke",(()=>{if(d)switch(n){case de.sh.PRICEDROP:return this.utilities.isDarkMode()?AE:wE;case de.sh.PRICEINCREASE:return this.utilities.isDarkMode()?EE:OE;case de.sh.FAIRPRICE:return this.utilities.isDarkMode()?kE:PE}return this.utilities.isDarkMode()?"#A8A8A8":"#767676"})).style("stroke-dasharray","2").style("fill","none"),B.selectAll(".dot").data(E).enter().append("circle").style("fill","var(--fill-color)").attr("cx",(e=>p(e.x))).attr("cy",(e=>g(e.y))).attr("r",(e=>e.text===this.todayString?12:8)),B.selectAll(".dot").data(E).enter().append("circle").attr("tabindex",R?"-1":"0").attr("aria-label",(e=>e.text===this.todayString&&v&&v.minPrice?(0,T.fZ)("todayLabel",this.flyoutData.strings.phTodayPriceAriaLabel,v.minPrice.toString()):e.text===this.lowString&&S&&S.minPrice&&S.dtg?(0,T.fZ)("lowLabel",this.flyoutData.strings.phLowPriceArialLabel,S.minPrice.toString(),S.dtg.toString()):e.text===this.highString&&x&&x.minPrice&&x.dtg?(0,T.fZ)("highLabel",this.flyoutData.strings.phHighPriceAriaLabel,x.minPrice.toString(),x.dtg.toString()):"")).style("fill",(e=>{if(e.text!==this.todayString)return this.utilities.isDarkMode()?"#FFFFFF":"#000000";switch(n){case de.sh.PRICEDROP:return this.utilities.isDarkMode()?AE:wE;case de.sh.PRICEINCREASE:return this.utilities.isDarkMode()?EE:OE;case de.sh.FAIRPRICE:return this.utilities.isDarkMode()?kE:PE}})).attr("cx",(e=>p(e.x))).attr("cy",(e=>g(e.y))).attr("r",(e=>e.text===this.todayString?8:4)),d&&B.selectAll(".node").data(E).enter().append("g").attr("transform",(e=>e.text===this.lowString?"translate(-10,-50)":P?"translate(-10,-20)":"translate(-10,0)")).append("rect").attr("height",(e=>e.text===this.todayString?"30px":"0px")).attr("width","0px").attr("fill",(e=>{if(e.text===this.todayString)switch(n){case de.sh.PRICEDROP:return this.utilities.isDarkMode()?"#008847":"#008A21";case de.sh.PRICEINCREASE:return this.utilities.isDarkMode()?"#C7274D":"#D64400";case de.sh.FAIRPRICE:return this.utilities.isDarkMode()?"#165AC2":"#166FF5"}})).attr("x",(e=>(e.text,this.todayString,p(e.x)))).attr("y",-9).attr("id",(e=>{if(e.text===this.todayString)return"todayTextRect"})).attr("rx",4);const U=B.selectAll(".node").data(E).enter().append("g").attr("transform",(e=>{if(e.text===this.todayString&&d)return P?"translate(-25, -20)":"translate(-25, 0)";let t=-10;return this.willCutOut(60,p(e.x))&&(t=60),this.utilities.shouldRenderSmallNotification()?`translate(${t},-25)`:e.text===this.lowString?`translate(${t},-35)`:`translate(${t},-25)`}));U.append("polygon").attr("points",(e=>{if(e.text===this.todayString&&d)switch(n){case de.sh.PRICEDROP:return"183,4 188,10 193,4";case de.sh.PRICEINCREASE:return"183,10 188,4 193,10";case de.sh.FAIRPRICE:return"183,4 183,10 190,7"}})).attr("style","fill: white;stroke: white;stroke-width:1").attr("id",(e=>{if(e.text===this.todayString&&d)return"todayPriceTriangleIcon"}));const H=U.append("text").attr("text-anchor","end").attr("x",(e=>(e.text,this.todayString,p(e.x)))).attr("y",(e=>e.text===this.lowString?u:0)).attr("id",(e=>{if(e.text===this.todayString)return"todayText"}));H.append("tspan").text((e=>e.text===this.todayString&&d?`${o}${this.utilities.toFixedSafe(Number(e.y),2)} ${e.text.toUpperCase()}`:`${o}${this.utilities.toFixedSafe(Number(e.y),2)}`)).attr("class",(e=>{if(e.text!==this.todayString||!d)return"price textBold";switch(n){case de.sh.PRICEDROP:return"currPriceDrop textWhite";case de.sh.PRICEINCREASE:return"currPriceIncrease textWhite";case de.sh.FAIRPRICE:return"currFairPrice textWhite"}})).attr("dx",(()=>"0.4em")).attr("dy","0.8em"),this.utilities.shouldRenderSmallNotification()||H.append("tspan").text((e=>e.text===this.todayString?"":e.text.charAt(0).toUpperCase()+e.text.slice(1))).attr("x",(e=>p(e.x))).attr("dx","0.4em").attr("dy","1.1em").attr("class","desc");const $=this.isCjkEnabled?"%Y/%-m/%-d":"%b %d";return H.append("tspan").text((e=>e.text===this.todayString&&d?"":OP($)(e.x))).attr("x",(e=>p(e.x))).attr("dx","0.4em").attr("dy","1.1em").attr("class","desc"),this.setUpInteractiveHover(c,65,_,M,a,u,p,g,o,B),_}willCutOut(e,t){return e-t>40}setUpMedianLine(e,t,i,n,o,r,a,s){const l=this.utilities.isDarkMode()??!1;e&&t.append("line").attr("x1",i(0)).attr("y1",n(e)).attr("x2",o+30).attr("y2",n(e)).style("stroke-width",1).style("stroke",l?"#FFFFFF":"#CCCCCC").style("stroke-dasharray","2, 7").style("fill","none").attr("pointer-events","none")}setUpInteractiveHover(e,t,i,n,o,r,a,s,l,c){const d=n.append("g").style("opacity",0).style("transition-duration","0.4s").style("transition-property","opacity");this.isCjkEnabled||d.selectAll(".dot").data(e).enter().append("circle").style("fill",this.utilities.isDarkMode()?"#A8A8A8":"#767676").attr("cx",(e=>a(e.dtg))).attr("cy",(e=>s(e.minPrice))).attr("r",4);const u=d.append("g").attr("transform","translate(-10,-25)").append("text").attr("aria-hidden","true").attr("text-anchor","end").style("fill",this.utilities.isDarkMode()?"#FFFFFF":"#444444"),h=u.append("tspan").attr("class","price").attr("dx","0.4em").attr("dy","0.8em"),p=u.append("tspan").attr("class","desc").attr("dx","0.4em").attr("dy","1.1em"),g=d.append("line").attr("y1",-25).attr("y2",r).style("stroke-width",1).style("stroke",(()=>this.utilities.isDarkMode()?"#A8A8A8":"#767676")).style("stroke-dasharray","2").style("fill","none"),f=d.append("circle").attr("class","hover-price").style("fill",this.utilities.isDarkMode()?"#FFFFFF":"#363636").style("stroke",this.utilities.isDarkMode()?"#FFFFFF":"#363636").attr("r",4);n.append("rect").attr("width",o).attr("height",r).style("fill","none").style("pointer-events","all").on("mouseout",(()=>{this.hideHoveredGroup(d,c)})).on("mousemove",(n=>{const o=i.createSVGPoint();o.x=n.clientX,o.y=n.clientY;const r=o.matrixTransform(i.getScreenCTM().inverse()).x-t,m=h.node()?.getBoundingClientRect()?.width;let v=r;this.willCutOut(m,r)&&(v=r+m+20);const y=this.getClosestDataPointToTheHoverLine(e,a,r);null!==y?(this.showHoveredGroup(d,c),f.attr("transform",`translate(${a(y.dtg)}, ${s(y.minPrice)})`),h.attr("x",v),p.attr("x",v),u.attr("x",v).attr("y",0),h.text(`${l}${this.utilities.toFixedSafe(y.minPrice,2)}`),p.text(`${OP(this.isCjkEnabled?"%Y/%-m/%-d":"%b %d")(y.dtg)}`),g.attr("x1",r).attr("x2",r)):this.hideHoveredGroup(d,c)}))}getClosestDataPointToTheHoverLine(e,t,i){const n=t.invert(i),o=AS((e=>e.dtg)).left(e,n),r=[e[o-1],e[o]];let a=Number.MAX_VALUE,s=null;for(const e of r){if(void 0===e)continue;const n=t(e.dtg),o=Math.abs(n-i);a>o&&(a=o,s=e)}return s}sendPriceHistoryDwellTimeTelemery(e,n,o){const r=Date.now()-e,a=new t.Z(n);if(this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,`Price history - ${o} - ${r} ms`,a),r>=1e3)try{this.pageHandlerModule.RecordAsUserEngagement(q.FV.VIEW_PRICE_HISTORY,this.flyoutData.common.popupOrigination)}catch(e){const n=new t.Z(i.xu.ErrorToRecordEngagement);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,e,n)}}hideHoveredGroup(e,t){e.style("opacity",0),t.style("opacity",1)}showHoveredGroup(e,t){e.style("opacity",1),t.style("opacity",0)}GetHeaderContent(e,t){return t&&""!==t?t:e===de.sh.PRICEDROP?this.flyoutData.strings.phTitlePriceDropped:e===de.sh.PRICEINCREASE?this.flyoutData.strings.phTitlePriceIncrease:this.flyoutData.strings.phTitleStable}isLastPriceDateToday(e){if(e.DailyPrices.length>0){const t=new Date,i=e.DailyPrices[e.DailyPrices.length-1].dtg;return 0===e.getDaysDifference(t,i)}return!1}renderPriceHistoryUXWithInsight(e,n){const o=n.DailyPrices;if(0===o.length||!n||!n?.ProductDetails)return null;const a=n.getPriceHistoryType();if(a===de.sh.PRICEDROP){const e=new t.Z(i.xu.PriceHistoryPriceDrop);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"",e)}else if(a===de.sh.PRICEINCREASE){const e=new t.Z(i.xu.PriceHistoryPriceIncrease);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"",e)}else{const e=new t.Z(i.xu.PriceHistoryPriceStable);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"",e)}const s=n?.ProductDetails?.currency||"$",l=`${s}${this.utilities.toFixedSafe(o[o.length-1].minPrice,2)}`,c=(0,Y.Ux)("DIV",{style:`display: flex; flex-direction: row; justify-content: flex-start; column-gap: 20px; padding: 6px 6px 16px; border-bottom: 1px solid ${this.utilities.isDarkMode()?"#555555":"rgba(0, 0, 0, 0.03)"} ;`});this.flyoutData.common.isPane||(c.style.paddingLeft="16px",c.style.paddingRight="16px");const d=this.utilities.getImageSrc(n);let u;if(d){const e=(0,Y.Ux)("IMG");e.style.maxWidth="100px",e.style.height="auto",e.style.maxHeight="100px",this.utilities.setImageSrc(e,d),this.utilities.shouldRenderSmallNotification()?(u=this.utilities.createProductImage(70,70,e,n?.ProductDetails.title),u.style.marginBottom="6px",c.style.justifyContent="space-between",c.style.alignItems="center"):(u=this.utilities.createProductImage(100,100,e,n?.ProductDetails.title),d.includes("defaultProduct")&&(e.style.maxHeight="unset",e.style.maxWidth="unset",e.style.width="100px",e.style.height="100px")),u.style.minWidth="100px",u.style.minHeight="100px"}const h=(0,Y.Ux)("DIV",{className:"ph_info",style:"display: flex;\n flex-direction: row;\n justify-content: space-between;\n column-gap: 12px;\n padding-top: 0px;\n width: 100%;"}),p=this.createPriceHistoryTypeIllustration(a),g=this.setUpMoreInfoButton(n,s,e.id);h.appendChild(p),this.utilities.shouldRenderSmallNotification()||h.appendChild(g);const f=(0,Y.Ux)("DIV",{className:"ph_head"});f.textContent=this.GetHeaderContent(a),f.style.fontSize="14px",f.style.lineHeight="20px",f.style.fontWeight="500",f.style.overflow="hidden",f.style.textOverflow="ellipsis",f.style.display="-webkit-box",f.style.webkitLineClamp="2",f.style.marginBottom="10px",f.style.marginTop="10px",f.style.marginRight="5px";const m=(0,Y.Ux)("DIV",{style:"\n display: flex;\n align-items: baseline;\n "}),v=this.getStrikeoutPricePoint(n,a)?.minPrice;if(v){const e=(0,Y.Ux)("S",{style:`\n margin-right: 5px;\n color: ${this.utilities.isDarkMode()?"#FFFFFF":"#757575"};\n font-size: 14px;\n `},`${s}${this.utilities.toFixedSafe(v,2)}`),t=(0,Y.Ux)("SPAN",{style:"\n position: absolute;\n clip: rect(0 0 0 0);\n "},this.flyoutData.strings.phOldPrice);e.appendChild(t),m.appendChild(e)}const y=this.utilities.isDarkMode()?"#FFFFFF":"#444444",C=(0,Y.Ux)("DIV",{style:`color: ${y};\n font-size: 18px;\n line-height: 20px;\n font-weight: 600;\n margin-bottom: 6px;`},l),b=(0,Y.Ux)("SPAN",{style:"\n position: absolute;\n clip: rect(0 0 0 0);\n "},this.flyoutData.strings.phNewPrice);C.appendChild(b),m.appendChild(C),this.utilities.shouldRenderSmallNotification()?(c.appendChild(h),u&&(this.flyoutData.common.isPaneEnabled&&this.flyoutData.common.openedWith===r.Te.Auto?this.productImageClickable(c,u):c.appendChild(u))):(u&&(this.flyoutData.common.isPaneEnabled&&this.flyoutData.common.openedWith===r.Te.Auto?this.productImageClickable(c,u):c.appendChild(u)),c.appendChild(h)),e.appendChild(c)}async populatePriceList(n,o){if(this.shouldShowNewPH())try{const a=this.getNewGraphPriceActivityLabel(n),s=n?.ProductDetails?.currency||"$",l=n.MedianPrice?`${s}${this.utilities.toFixedSafe(n.MedianPrice,2)}`:"";let c;c=n.UseV2Insights?(0,T.fZ)("phTooltipText",this.flyoutData.strings.phTooltipTextAvg,l):(0,T.fZ)("phTooltipText",this.flyoutData.strings.phTooltipText,l);let d=0;const u=async()=>{0===d&&e.R.isExperimentActive(f.H.CouponsPersonalization)&&await this.autoOpenControllerUtilities.userEngagementStoreManager.addEngagement(q.w1.POSITIVE,this.flyoutData.common.popupOrigination,r.ModuleNames.PRICEHISTORY,cy.e.userEngagementPriceHistoryWeights.priceHistoryGraphHoverWeight),d=Date.now()},h=()=>{this.sendPriceHistoryDwellTimeTelemery(d,i.xu.PriceHistoryDwellTimeHover,"hover time over graph")};let p=0,g=0,m=!0,v=!0;const y=async()=>{if(v){if(v=!1,!(Date.now()-g>this.bouncePeriodMs))return;m=!0,p=Date.now();const e=new t.Z(i.xu.PriceHistoryShowMoreInfoTooltip);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Price history - show more info tooltip",e)}e.R.isExperimentActive(f.H.CouponsPersonalization)&&await this.autoOpenControllerUtilities.userEngagementStoreManager.addEngagement(q.w1.POSITIVE,this.flyoutData.common.popupOrigination,r.ModuleNames.PRICEHISTORY,cy.e.userEngagementPriceHistoryWeights.priceHistoryMoreInfoWeight)},C=()=>{g=Date.now(),v=!0,setTimeout((()=>{if(m){m=!1,this.sendPriceHistoryDwellTimeTelemery(p,i.xu.PriceHistoryDwellTimeHover,"hover time over info button");const e=new t.Z(i.xu.PriceHistoryHideMoreInfoTooltip);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Price history - hide more info tooltip",e)}}),this.bouncePeriodMs)},b=await(async(e,t,i,n=!1,o,r,a,s,l,c)=>{const d=await ph(),u=n?d.dark:d.light,h=e.DailyPrices.filter((e=>!!e)).map((e=>({date:e.dtg.toISOString(),price:e.minPrice}))),p=e.ProductDetails.currency?e.ProductDetails.currency:"$",g=(0,ne.qm)(p)?p:(0,ne.Vv)(p),f=e.getPriceHistoryType(),{highestIndex:m,lowestIndex:v,medianIndex:y}=dp(e),C=up(o,e,v,m,y);let b;switch(f){case de.sh.FAIRPRICE:b="brand";break;case de.sh.PRICEINCREASE:b="red";break;case de.sh.PRICEDROP:b="green";break;default:b=void 0}let S,x=t;if(e.UseV2Insights)switch(x=e.getInsightString(o),f){case de.sh.PRICEINCREASE:S=-1;break;case de.sh.PRICEDROP:S=1;break;default:S=0}else e.DailyPriceDropPercentage&&(Math.abs(e.DailyPriceDropPercentage)<de.pD?(S=0,x=o.phNewPriceStable,b="brand"):S=e.DailyPriceDropPercentage);e.ShowPriceHistoryInsight||(S=0,x=o.phSectionTitle,b="brand");const T=e.UseV2Insights&&("secondlowestprice_in_x_months"===e.PriceHistoryInsightDisplayKey||"secondlowestprice_in_x_month"===e.PriceHistoryInsightDisplayKey);return ch.createElement(ap,{theme:u,style:{backgroundColor:"transparent",padding:"0px 20px 20px 20px"}},ch.createElement("div",{onMouseEnter:a,onMouseLeave:s},ch.createElement(ch.Suspense,null,ch.createElement(hh,{type:"surface"},ch.createElement(uh,{direction:"vertical",spacing:"large"},ch.createElement(gh,{priceChangePercentage:S,size:T?"medium":"large",label:x,infoLabel:i,infoLabelOnChange:(e,t)=>{"mouseenter"===e.type||"focus"===e.type?l():"mouseleave"===e.type&&c()},infoLabelWidth:150,hidePercent:e.UseV2Insights}),ch.createElement(fh,{ariaProps:cp({},C),lowestPriceIndex:v,highestPriceIndex:m,color:b,data:h,currency:g,lowestPriceLabel:o.newPhLow,highestPriceLabel:o.newPhHigh,disableAnimation:!0,locale:r||"en-US",localeCompact:r?"en-IN"===r?"en-US":r:"en-US"}))))))})(n,a,c,this.utilities.isDarkMode(),this.flyoutData.strings,this.flyoutData.common.afdMarket,u,h,y,C);gp((()=>b),o)}catch(e){const r=new t.Z(i.xu.NewPriceHistoryGraph);r.Metadata=JSON.stringify({error:e}),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"New Price history load failed",r),this.renderPriceHistoryUXWithInsight(o,n)}else n.ShowPriceHistoryInsight?this.renderPriceHistoryUXWithInsight(o,n):this.renderPriceHistoryUXWithoutInsight(o,n);if("zh-cn"===this.flyoutData.common.afdMarket){const e=(0,Y.Ux)("DIV",{style:"margin: 16px; text-align: center;"});e.id="divIntDisclaimer";const t=(0,Y.Ux)("SPAN");t.className="txtSmall",t.style.fontSize="12px",t.style.lineHeight="14px",t.style.color="var(--text-neutral-foreground-hint)",t.style.opacity=this.utilities.isDarkMode()?"0.83":"1.0",t.textContent=this.flyoutData.strings.commonInternationalDisclaimer,e.appendChild(t),o.appendChild(e)}this.shouldShowNewPH()||(this.isPHNotification()||this.renderPriceHistoryGraph(o),this.utilities.shouldRenderSmallNotification()?this.renderPriceHistoryGraph(o):o.addEventListener("mouseover",(()=>{this.renderPriceHistoryGraph(o)})))}shouldShowNewPH(){return!this.isPHNotification()&&this.useNewPriceHistory}isPHNotification(){const{common:e}=this.flyoutData;return e.popupOrigination===u.sR.AUTO_SHOW_PRICE_HISTORY&&e.openedWith===r.Te.Auto}getNewGraphPriceActivityLabel(e){const t=e.getPriceHistoryType(),{strings:i}=this.flyoutData;if(!e.ShowPriceHistoryInsight)return i.phSectionTitle;switch(t){case de.sh.PRICEINCREASE:return i.phNewPriceHigher;case de.sh.PRICEDROP:return i.phNewPriceLower;case de.sh.FAIRPRICE:default:return i.phNewPriceStable}}renderPriceHistoryUXWithoutInsight(e,t){const i=t?.ProductDetails?.title,n=(0,Y.Ux)("DIV",{style:"\n width: 100%;\n padding: 0 16px;\n display: grid;\n grid-template-columns: 100px auto;\n column-gap: 12px;\n align-items: center;\n box-sizing: border-box;\n "});this.flyoutData.common.isPane&&(n.style.padding="6px");const o=this.utilities.getImageSrc(t);if(o){const e=document.createElement("IMG");this.utilities.setImageSrc(e,o);const t=this.utilities.createProductImage(100,100,e,i);o.includes("defaultProduct")&&(e.style.maxHeight="unset",e.style.maxWidth="unset",e.style.width="100px",e.style.height="100px"),this.flyoutData.common.isPaneEnabled&&this.flyoutData.common.openedWith===r.Te.Auto?this.productImageClickable(n,t):n.appendChild(t)}const a=(0,Y.Ux)("DIV");if(this.priceHistoryTitle=(0,Y.Ux)("DIV",{style:"\n font-size: 20px;\n line-height: 24px;\n font-weight: 700;\n "},this.flyoutData.strings.phSectionTitle),this.priceHistoryTitle.style.display="none",a.appendChild(this.priceHistoryTitle),i&&""!==i){const e=(0,Y.Ux)("DIV",{style:"\n display: -webkit-box;\n font-size: 16px;\n line-height: 22px;\n overflow: hidden;\n text-overflow: ellipsis;\n margin-top: 12px;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n "},i);e.title=i,a.appendChild(e)}n.appendChild(a),e.appendChild(n)}setUpMoreInfoButton(n,o,a){const s=(0,Y.Ux)("DIV");s.style.position="relative";const l=n.MedianPrice,c=l?`${o}${this.utilities.toFixedSafe(l,2)}`:"",d=(0,T.fZ)("phTooltipText",this.flyoutData.strings.phTooltipText,c),h=this.tooltipUtilities.createInfoIconTooltip(d);h.style.alignSelf="center",h.id="header-tooltip",this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_PRICE_HISTORY&&(h.style.marginLeft="0px",h.style.marginTop="0px");let p=0,g=0,m=!0;h.addEventListener("mouseenter",(async()=>{C(),e.R.isExperimentActive(f.H.CouponsPersonalization)&&await this.autoOpenControllerUtilities.userEngagementStoreManager.addEngagement(q.w1.POSITIVE,this.flyoutData.common.popupOrigination,r.ModuleNames.PRICEHISTORY,cy.e.userEngagementPriceHistoryWeights.priceHistoryMoreInfoWeight)})),h.addEventListener("mouseleave",(()=>{b()})),h.addEventListener("focus",(()=>{C()})),h.addEventListener("blur",(()=>{b()}));const v=this.logModule;let y=!0;const C=()=>{if(y){if(y=!1,!(Date.now()-g>this.bouncePeriodMs))return;m=!0,p=Date.now();const e=new t.Z(i.xu.PriceHistoryShowMoreInfoTooltip);v.LogInfoEvent(i.R.EdgeFlyoutStatus,"Price history - show more info tooltip",e)}},b=()=>{g=Date.now(),y=!0,setTimeout((()=>{if(m){m=!1,this.sendPriceHistoryDwellTimeTelemery(p,i.xu.PriceHistoryDwellTimeHover,"hover time over info button");const e=new t.Z(i.xu.PriceHistoryHideMoreInfoTooltip);v.LogInfoEvent(i.R.EdgeFlyoutStatus,"Price history - hide more info tooltip",e)}}),this.bouncePeriodMs)},S=this.flyoutData.common.isDiscoverPane;return h.addEventListener("hover",(async()=>{await this.tooltipUtilities.setupTooltip(h),S&&(h.caratSide=gd.W.Top)})),h.addEventListener("focus",(async()=>{await this.tooltipUtilities.setupTooltip(h),S&&(h.caratSide=gd.W.Top)})),s.appendChild(h),s}getLowPoint(e,t,i){return!i&&e.minPrice>=t.minPrice||i&&i.dtg===t.dtg?null:i?e.minPrice!==t.minPrice&&e.minPrice<i.minPrice?e:i:e.minPrice<t.minPrice?e:null}getHighPoint(e,t,i){return!i&&e.minPrice<=t.minPrice||i&&i.dtg===t.dtg?null:i?e.minPrice!==t.minPrice&&e.minPrice>i.minPrice?e:i:e.minPrice>t.minPrice?e:null}getMinCriticalPoint(e,t){const i=e.reduce(((e,t)=>e.minPrice<t.minPrice?e:t));return 1===e.length&&e[0].minPrice>t.minPrice?null:i}getMaxCriticalPoint(e,t,i,n){let o;const r=e.sort(((e,t)=>t.minPrice-e.minPrice)).filter((e=>e.minPrice>i));if(this.isCjkEnabled)return r&&r.length>0?r[0]:o;let a=13*this.utilities.toFixedSafe(t.minPrice,2).length+7;a=13*this.utilities.toFixedSafe(t.minPrice,2).length+13*this.flyoutData.strings.phToday.length+7;for(const e of r)if(n(t.dtg)-n(e.dtg)>a){o=e;break}return o}getCriticalPoints(e){if(e.length<3)return[];const t=[];let i=e[1].minPrice-e[0].minPrice;for(let n=2;n<e.length;n++){const o=e[n].minPrice,r=e[n-1].minPrice;((r-o)*i>0||r-o!=0&&0===i)&&t.push(e[n-1]),i=o-r}return t}getStrikeoutPricePoint(e,t){const i=e.DailyPrices;if(i.length>1){if(t===de.sh.PRICEDROP){let e=i[0].minPrice,t=i[0].dtg;for(const n of i)n.minPrice>e&&(e=n.minPrice,t=n.dtg);return{dtg:t,minPrice:e}}if(t===de.sh.PRICEINCREASE){let e=i[0].minPrice,t=i[0].dtg;for(const n of i)n.minPrice<e&&(e=n.minPrice,t=n.dtg);return{dtg:t,minPrice:e}}}}reDrawGraph(e){const t=this.flyoutData.dataStoreModule.PriceHistoryData;if(t){const i=t.getPriceHistoryType(),n=t?.ProductDetails?.currency||"$",o=this.drawPriceHistoryChart(t,i,n,e),r=this.flyoutData.common.shopping.querySelector("#divPriceHistory");if(r){const t=r.querySelector("svg");t&&t.remove(),o&&(this.graphWidth=e,r.appendChild(o))}else{const e=document.querySelector(`#${this.sectionId}`);e&&this.renderPriceHistoryGraph(e)}}}updatePriceGraph(e=!1){if(this.refreshCount++,this.refreshCount<this.maxRefresh||this.isCjkEnabled&&!0===e){const t=this.flyoutData.common.shopping?.querySelector("#divPriceHistory");let i=t?.offsetWidth??0;0===i&&(i=(0,dt.tB)(this.flyoutData)?300:319),t&&(!t.querySelector("SVG")||t&&i>0&&(i!==this.graphWidth||this.isCjkEnabled&&!0===e))&&this.reDrawGraph(i);const n=document.getElementById("todayText"),o=document.getElementById("todayPriceTriangleIcon"),r=document.getElementById("todayTextRect"),a=r?.getAttribute("width");if(n&&r&&o&&"0px"===a){let e=n.getBoundingClientRect().width+50+o.getBoundingClientRect().width;n.textContent&&n.textContent.length>0&&(e=10*n.textContent.length+20+10);const t=e;r.setAttribute("width",t+"px");const i=r.getAttribute("x");let a=0;i&&(a=parseInt(i,10)-t+4,r.setAttribute("x",`${a}`));const s=a+30,l=this.flyoutData.dataStoreModule?.PriceHistoryData?.getPriceHistoryType();switch(l){case de.sh.PRICEDROP:o.setAttribute("points",`${s} 2, ${s+6} 10, ${s+12} 2`);break;case de.sh.PRICEINCREASE:o.setAttribute("points",`${s} 10, ${s+6} 2, ${s+12} 10`);break;case de.sh.FAIRPRICE:o.setAttribute("points",`${s} 0, ${s} 12, ${s+8} 6`)}}}}productImageClickable(e,t){const n=document.createElement("BUTTON");n.style.border="unset",n.style.cursor="pointer",n.style.backgroundColor="transparent",n.style.padding="0",n.id="hero-image-clickable",n.addEventListener("click",(()=>{const e=new W.Z(i.$S.HeroImageClick,this.telemetryUtilities.setContentViewed(this.GetModuleName()));e.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.logModule.LogInfoEvent(i.R.ButtonClick,"Price history hero image clicked",e),this.pageHandlerModule.OpenPane(this.flyoutData.common.popupOrigination)})),n.appendChild(t),e.appendChild(n)}getShoppingContent(){const e=this.flyoutData.dataStoreModule.PriceHistoryData?.getPriceHistoryType();return e===de.sh.NOINSIGHT?bp.r.PRICE_HISTORY_NO_INSIGHT:e===de.sh.PRICEDROP?bp.r.PRICE_HISTORY_DROP:e===de.sh.FAIRPRICE?bp.r.PRICE_HISTORY_STABLE:bp.r.PRICE_HISTORY_INCREASE}}(0,s.Z)(DE,"priceHistoryCjkImpl",void 0);var _E=DE;const NE=(0,Zg.Z)({container:{display:"flex",flexDirection:"column",alignItems:"center"},priceDropInfo:{width:"100%",display:"flex",flexDirection:"row",justifyContent:"space-between",marginBottom:"16px"},priceDropTexts:{display:"flex",flexDirection:"column",marginLeft:"16px",rowGap:"8px"},priceDropPercentage:{display:"flex",flexDirection:"row",alignItems:"end",columnGap:"8px"},priceGroup:{display:"flex",flexDirection:"row",columnGap:"8px"},image:{marginRight:"16px",display:"flex"}}),RE=e=>{const t=NE(),n=ch.useRef(null),o=ch.useRef(null),a=e.priceHistoryData,s=a.CurrentPrice,l=a.MedianPrice,c=Math.round((l-s)/l*100);return(0,ch.useEffect)((()=>{const t=(0,Y.lw)(e.utilities);t.textContent=e.flyoutData.strings.cjkSeePriceHistory,t.className+=" lateralMargin",t.onclick=t=>{if(e.flyoutData.common.isPaneEnabled){const t=new W.Z(i.$S.SeePHGraph,e.telemetryUtilities.setContentViewed(r.ModuleNames.PRICEHISTORY));e.logModule.LogInfoEvent(i.R.ButtonClick,"Click on CJK PH Notification to open pane",t),e.pageHandler.RecordAsUserAction(K.bS.CJK_VIEW_PRICE_HISTORY),e.pageHandler.RecordAsUserEngagement(q.FV.CJK_VIEW_PRICE_HISTORY,e.flyoutData.common.popupOrigination),e.pageHandler.OpenPane(e.flyoutData.common.popupOrigination)}},n.current?.appendChild(t);const a=(0,Y.Ux)("IMG"),s=e.priceHistoryData,l=s?.ProductDetails?.imageUrl,c=e.resourcesEndpoint+"common/defaultProduct.svg";l&&(e.safeFetchImg?e.pageHandler.GetSafeImage(l).then((e=>{e.succ&&""!==e.safeImgData?a.src=e.safeImgData:a.src=c})):(a.onerror=e=>{a.src!==c&&(a.src=c)},a.src=l));const d=e.utilities.createProductImage(88,88,a,s.ProductDetails.title);o.current?.appendChild(d)}),[]),ch.createElement(gm,{theme:e.isDarkMode?Bm:Lm},ch.createElement("div",{className:t.container,ref:n},ch.createElement("div",{className:t.priceDropInfo},ch.createElement("div",{className:t.priceDropTexts},ch.createElement(ME,null,e.flyoutData.strings.cjkPriceLowerThanUsual),ch.createElement("div",{className:t.priceDropPercentage},ch.createElement(LE,null,c,"%"),ch.createElement("img",{src:e.resourcesEndpoint+"cjk/decreaseTrend.svg"})),ch.createElement("div",{className:t.priceGroup},ch.createElement(FE,null,"¥",s),ch.createElement(BE,null,ch.createElement("del",null,"¥",l)))),ch.createElement("div",{className:t.image,ref:o}))))},ME=bm.div`
font-family: "Segoe UI", "Roboto", Helvetica, Verdana, sans-serif;
font-style: normal;
font-weight: 600;
font-size: 16px;
line-height: 22px;
color: ${e=>e.theme.priceNotification.titleColor};
`,LE=bm.div`
font-family: "Segoe UI", "Roboto", Helvetica, Verdana, sans-serif;
font-style: normal;
font-weight: 600;
font-size: 40px;
line-height: 40px;
color: #E8392C;
`,BE=bm.div`
font-family: "Segoe UI", "Roboto", Helvetica, Verdana, sans-serif;
font-size: 14px;
margin: 0px;
color: ${e=>e.theme.priceNotification.oriPriceColor};
`,FE=bm.div`
font-family: "Segoe UI", "Roboto", Helvetica, Verdana, sans-serif;
font-style: normal;
font-weight: 600;
font-size: 14px;
line-height: 20px;
color: #E8392C;
`;class UE extends xE{constructor(e,t,i,n){super(e,t,i,n),this.isNotification=!0,this.ignoreTimeRangeCheck=!0}RenderNotification(){const{common:e}=this.flyoutData,t=this.flyoutData.dataStoreModule.PriceHistoryData;if(t&&t.ProductDetails){this.utilities.applyStyles(e.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());const o=(0,Y.Ux)("div");i=ch.createElement(RE,{utilities:this.utilities,priceHistoryData:t,resourcesEndpoint:this.flyoutData.common.resourcesEndpoint,safeFetchImg:this.flyoutData.common.isCjkShouldGetSafeImage,pageHandler:this.pageHandler,flyoutData:this.flyoutData,logModule:this.logModule,telemetryUtilities:this.telemetryHandler,isDarkMode:this.utilities.isDarkMode()}),n=o,(0,sp.render)(i,n);const r=this.utilities.createNotificationModule(o,this.GetNotificationName(),this);return Promise.resolve(r)}var i,n;return Promise.resolve(null)}ShouldRenderNotification(){const e=!(this.flyoutData.common.openedWith!==r.Te.Auto||this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_CJK_PRICE_DROP||!this.flyoutData.dataStoreModule.PriceHistoryData?.ProductDetails);return Promise.resolve(e)}GetNotificationName(){return r.sM.PRICEHISTORY}PostProcessingNotification(e,t){}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_CJK_PRICE_DROP]}}class HE extends xE{constructor(e,t,i,n){super(e,t,i,n),this.isNotification=!0}async RenderNotification(){const{common:e}=this.flyoutData,t=this.flyoutData.dataStoreModule.PriceHistoryData;if(t&&t.ProductDetails){this.utilities.applyStyles(e.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());const t=(0,Y.Ux)("msft-edge-shopping-section");await this.renderCjkPriceHistoryComponent(t),this.uxUtilities.fixedHeaderUtilities.setFlyoutHeader(this.flyoutData,this.uxUtilities.viewModulesUtilities,new a.Z),this.flyoutData.common.shopping.classList.add("noSections"),t.accordion=!1,t.slot="header-content",t.hideTitle=!0;const i=this.utilities.createNotificationModule(t,this.GetNotificationName(),this);return Promise.resolve(i)}return Promise.resolve(null)}ShouldRenderNotification(){const e=!(this.flyoutData.common.openedWith!==r.Te.Hover||this.flyoutData.common.popupOrigination!==u.sR.HOVER_BUTTON_SHOW_FLYOUT||!this.flyoutData.dataStoreModule.PriceHistoryData?.ProductDetails);return Promise.resolve(e)}GetNotificationName(){return r.sM.PRICEHISTORY}PostProcessingNotification(e,t){}GetPopupOriginationList(){return[u.sR.HOVER_BUTTON_SHOW_FLYOUT]}}var $E=class extends _E{constructor(e,t,i){super(e,t,i),(0,s.Z)(this,"productTrackingUtilities",void 0),(0,s.Z)(this,"priceHistoryNotificationCjkImpl",void 0),this.productTrackingUtilities=new Ju(i,t,e),this.flyoutData.common.isCJKEnabled&&(this.flyoutData.common.openedWith===r.Te.Hover?this.priceHistoryNotificationCjkImpl=new HE(e,t,i,this):this.priceHistoryNotificationCjkImpl=new UE(e,t,i,this)),this.telemetryUtilities=i.telemetryHandler}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_PRICE_HISTORY,u.sR.AUTO_SHOW_CJK_PRICE_DROP,u.sR.HOVER_BUTTON_SHOW_FLYOUT]}PostProcessingNotification(e,t){this.PostProcessing(e,0,t)}async RenderNotification(){if(this.priceHistoryNotificationCjkImpl)return this.priceHistoryNotificationCjkImpl.RenderNotification();const t=this.flyoutData.dataStoreModule.PriceHistoryData,n=this.flyoutData.dataStoreModule.ProductInsightsData;if(t&&t.ProductDetails){this.dataValidationUtilities.validatePriceWithEntityExtractionResults(this.flyoutData.common.extractedEntity,t.CurrentPrice.toString(),this.GetModuleName()),this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles());const o=t.ProductDetails,r=(0,Y.Ux)("msft-notification-header");r.slot="header-content",r.style.marginBottom="2px";let a=o.currency||"$";a=(0,ne.qm)(a)?(0,ne.qk)(a):a;const s=`${a}${this.utilities.formatPrice(t.CurrentPrice,this.flyoutData.common.afdMarket)}`,l=`${a}${this.utilities.formatPrice(t.MedianPrice,this.flyoutData.common.afdMarket)}`,c=`${this.utilities.toFixedSafe(Math.abs(t.DailyPriceDropPercentage),0)}%`,d=t.getPriceHistoryType();r.savings=c,d===de.sh.PRICEDROP?(r.title=this.flyoutData.strings.phPriceDropped,r.oldPrice=l,r.currentPrice=s):d===de.sh.PRICEINCREASE?(r.title=this.flyoutData.strings.phPriceIncrease,r.oldPrice=l,r.currentPrice=s):(r.title=this.flyoutData.strings.phPriceStable,r.currentPrice=s,r.savings="0%");let u="display: flex; place-self: end; margin-bottom: 4px;";if(t.UseV2Insights){const i=d===de.sh.FAIRPRICE?this.flyoutData.strings.price_is_stable:this.flyoutData.strings[t.PriceHistoryInsightDisplayKey],o=this.createTitleElement(t.PriceHistoryInsightDisplayKey,i,t.PriceHistoryInsightDisplayValues[0]);r.append(o),r.useSlotTitle=!0,r.isNewPHInsights=!0,r.hasArrow=!1,r.savings="",r.title="",e.R.isExperimentActive(f.H.communityInsightsPH)&&(r.productInsights=n?.TopInsight||""),u=""}else r.hasArrow=!0;e.R.isExperimentActive(f.H.communityInsightsPH)&&(r.productInsights=n?.TopInsight||"");const h=(0,Y.Ux)("IMG",{style:u});h.setAttribute("aria-hidden","true"),d===de.sh.PRICEDROP?(h.src=this.flyoutData.common.resourcesEndpoint+"priceHistory/decreaseTrend.svg",r.priceHistoryType="decrease"):d===de.sh.PRICEINCREASE?(h.src=this.flyoutData.common.resourcesEndpoint+"priceHistory/increaseTrend.svg",r.priceHistoryType="increase"):(h.src=this.flyoutData.common.resourcesEndpoint+"priceHistory/stableTrend.svg",r.priceHistoryType="stable");const p=(0,Y.Ux)("IMG");p.src=this.utilities.getImageSrc(t);let g=88;t.UseV2Insights&&(g=60);const m=this.utilities.createProductImage(g,g,p,o.title);h.slot="arrow",m.slot="image",this.flyoutData.common.isPaneEnabled&&(r.setAttribute("role","button"),r.addEventListener("click",(()=>{const e=new W.Z(i.$S.HeroImageClick,this.telemetryUtilities.setContentViewed(this.GetModuleName()));e.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.logModule.LogInfoEvent(i.R.ButtonClick,"Price history hero image clicked",e),this.pageHandlerModule.OpenPane(this.flyoutData.common.popupOrigination)}))),r.appendChild(m),t.UseV2Insights||r.appendChild(h);const v=(0,Y.Ux)("div"),y=this.renderGraphButton(r,p,v);y.style.placeSelf="center",y.slot="actions",this.flyoutData.common.shopping.appendChild(y);const C=await this.renderTrackingToggle(t);this.flyoutData.common.shopping.appendChild(v),C&&this.flyoutData.common.shopping.appendChild(C),this.flyoutData.common.shopping.classList.add("noSections");const b=this.utilities.createNotificationModule(r,this.GetNotificationName(),this);return Promise.resolve(b)}return Promise.resolve(null)}async ShouldRenderNotification(){let e;if(this.priceHistoryNotificationCjkImpl){let t=!0;this.priceHistoryNotificationCjkImpl.ignoreTimeRangeCheck||(t=await this.ShouldRenderModule()),e=t&&await this.priceHistoryNotificationCjkImpl.ShouldRenderNotification()}else e=new fS(this.flyoutData).shouldRenderNotification(u.sR.AUTO_SHOW_PRICE_HISTORY);return Promise.resolve(e)}GetNotificationName(){return r.sM.PRICEHISTORY}async renderTrackingToggle(e){const t=e.ProductDetails;if(t.ProductUrl=this.flyoutData.common.lastCommittedURL,Ju.shouldRenderProductTrackingUtilities(t.ProductUrl,this.flyoutData.dataStoreModule.ProductTrackingData,this.flyoutData.common.market)){t.price=t.price??e?.CurrentPrice?.toString(),t.imageUrl=e.ProductDetails.extractedImage;const i=await this.productTrackingUtilities.checkIsOutOfStock();return await this.productTrackingUtilities.createTrackingToggleSection(t,i,this.GetNotificationName())}}renderGraphButton(e,t,n){const o=(0,Y.Ux)("div"),r=(0,Y.lw)(this.utilities);r.classList.add("lateralMargin");const a=(0,Y.Ux)("div");return a.style.marginBottom="8px",a.style.fontSize="14px",a.style.lineHeight="20px",a.style.color="var(--neutral-foreground-rest)",a.style.fontWeight="400",a.textContent=this.flyoutData.strings.phSeeTrend,o.appendChild(a),r.textContent=this.flyoutData.strings.productTrackingNotificationOk,r.addEventListener("click",(()=>{if(this.flyoutData.common.isPaneEnabled){const e=new W.Z(i.$S.SeePHGraph,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"Click on PH Notification to open pane",e),this.pageHandlerModule.RecordAsUserAction(K.bS.EXPAND_PRICE_HISTORY_GRAPH),this.pageHandlerModule.RecordAsUserEngagement(q.FV.EXPAND_GRAPH,this.flyoutData.common.popupOrigination),this.pageHandlerModule.OpenPane(this.flyoutData.common.popupOrigination)}else{e.currentPrice="",e.oldPrice="",e.hasGraph=!0,this.flyoutData.common.shopping.removeChild(o);const r=(0,Y.Ux)("div");n.appendChild(r),this.renderPriceHistoryGraph(r);const a=t.parentElement;null!==a&&(a.style.maxHeight="72px",a.style.maxWidth="72px",t.style.maxWidth="72px",t.style.maxHeight="72px");const s=new W.Z(i.$S.SeePHGraph,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.pageHandlerModule.RecordAsUserAction(K.bS.EXPAND_PRICE_HISTORY_GRAPH),this.pageHandlerModule.RecordAsUserEngagement(q.FV.EXPAND_GRAPH,this.flyoutData.common.popupOrigination),this.logModule.LogInfoEvent(i.R.ButtonClick,"Click on PH Notification to see full graph",s)}})),o.appendChild(r),o}createTitleElement(e,t,i){const n=(0,Y.Ux)("div");let o;n.slot="slotTitle",n.style.fontSize="16px",n.style.marginRight="8px",n.style.lineHeight="22px",o=e.indexOf("percent")>-1?`${i}%`:i;const r=(0,T.fZ)(t,t,o);return n.textContent=r,n}};let ZE=function(e){return e.Consent="Consent",e.SignIn="SignIn",e}({});var VE=class{getStyles(){return"\n .prodHAnnotation {\n color: #6E6E6E;\n }\n #pdhWrapper msft-product-card {\n transition: box-shadow 1s;\n }\n #pdhWrapper msft-product-card:hover {\n background: inherit;\n box-shadow: 0px 3px 6px rgba(0, 0, 0, 0.12);\n }\n @media (forced-colors: active) {\n .prodHAnnotation {\n color: highlightText;\n }\n }\n "}getDarkModeStyles(){return"\n .prodHAnnotation {\n color: #FFFFFF;\n }\n "}getPriceDropAnnotation(){return eh.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="13" height="12" viewBox="0 0 13 12" fill="none">
<path d="M10.0428 8.84145C9.78112 8.84145 9.569 9.05357 9.569 9.31523V11.5262C9.569 11.7879 9.78112 12 10.0428 12C10.3044 12 10.5166 11.7879 10.5166 11.5262V9.31523C10.5166 9.05357 10.3044 8.84145 10.0428 8.84145ZM6.41042 6.15922C6.41042 5.89756 6.62254 5.68544 6.88421 5.68544C7.14587 5.68544 7.35799 5.89756 7.35799 6.15922V11.5262C7.35799 11.7879 7.14587 12 6.88421 12C6.62254 12 6.41042 11.7879 6.41042 11.5262V6.15922ZM3.72562 7.1057C3.46396 7.1057 3.25184 7.31783 3.25184 7.57949V11.5262C3.25184 11.7879 3.46396 12 3.72562 12C3.98729 12 4.19941 11.7879 4.19941 11.5262V7.57949C4.19941 7.31783 3.98729 7.1057 3.72562 7.1057ZM0.0932617 3.7892C0.0932617 3.52753 0.305384 3.31541 0.567048 3.31541C0.828713 3.31541 1.04084 3.52753 1.04084 3.7892V11.5262C1.04084 11.7879 0.828713 12 0.567048 12C0.305384 12 0.0932617 11.7879 0.0932617 11.5262V3.7892Z" fill="#107C10"/>
<path d="M11.5621 7.57916L8.6854 7.57949L8.62112 7.57516C8.38986 7.54379 8.21162 7.34556 8.21162 7.1057L8.21595 7.04141C8.24732 6.81016 8.44554 6.63192 8.6854 6.63192H10.3841L6.65215 2.89926L4.73787 4.73788L4.68473 4.78375C4.49925 4.92137 4.23604 4.90608 4.06784 4.73787L0.138768 0.808805L0.0928953 0.755666C-0.0447267 0.570187 -0.0294364 0.306974 0.138768 0.138769C0.323793 -0.0462563 0.623784 -0.0462563 0.808809 0.138769L4.40287 3.73283L6.31716 1.89419L6.3703 1.84832C6.55578 1.7107 6.819 1.726 6.9872 1.89421L11.055 5.96293L11.0553 4.26053L11.0596 4.19624C11.091 3.96498 11.2892 3.78674 11.5291 3.78674C11.7908 3.78674 12.0029 3.99886 12.0029 4.26053L12.0026 7.12371L11.9967 7.18322L11.9881 7.22365L11.976 7.26412L11.9515 7.32118L11.9173 7.37811L11.8898 7.41373L11.8641 7.44155C11.8229 7.48274 11.776 7.51476 11.7259 7.53679L11.6879 7.55293L11.6254 7.57037L11.5621 7.57916Z" fill="#107C10"/>
</svg>`}getPriceIncreaseAnnotation(){return eh.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="12" height="12" viewBox="0 0 12 12" fill="none">
<path d="M8.25 0.5625C8.25 0.25184 8.50184 0 8.8125 0H10.6875C10.9982 0 11.25 0.25184 11.25 0.5625V2.4375C11.25 2.74816 10.9982 3 10.6875 3C10.3768 3 10.125 2.74816 10.125 2.4375V1.92049L6.77275 5.27275C6.55308 5.49242 6.19692 5.49242 5.97725 5.27275L4.125 3.4205L0.960248 6.58525C0.740578 6.80492 0.384422 6.80492 0.164752 6.58525C-0.0549174 6.36558 -0.0549174 6.00942 0.164752 5.78975L3.72725 2.22725C3.94692 2.00758 4.30308 2.00758 4.52275 2.22725L6.375 4.0795L9.3295 1.125H8.8125C8.50184 1.125 8.25 0.87316 8.25 0.5625ZM0.5625 9C0.87316 9 1.125 9.25184 1.125 9.5625V11.4375C1.125 11.7482 0.87316 12 0.5625 12C0.25184 12 0 11.7482 0 11.4375V9.5625C0 9.25184 0.25184 9 0.5625 9ZM4.125 7.3125C4.125 7.00184 3.87316 6.75 3.5625 6.75C3.25184 6.75 3 7.00184 3 7.3125V11.4375C3 11.7482 3.25184 12 3.5625 12C3.87316 12 4.125 11.7482 4.125 11.4375V7.3125ZM6.5625 8.25C6.87316 8.25 7.125 8.50184 7.125 8.8125V11.4375C7.125 11.7482 6.87316 12 6.5625 12C6.25184 12 6 11.7482 6 11.4375V8.8125C6 8.50184 6.25184 8.25 6.5625 8.25ZM10.125 5.8125C10.125 5.50184 9.87316 5.25 9.5625 5.25C9.25184 5.25 9 5.50184 9 5.8125V11.4375C9 11.7482 9.25184 12 9.5625 12C9.87316 12 10.125 11.7482 10.125 11.4375V5.8125Z" fill="#D83B01"/>
</svg>`}getPriceDecreaseTrendIcon(e){return e?eh.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="8" height="6" viewBox="0 0 8 6" fill="none">
<path d="M8 0L4 6L0 0H8Z" fill="#43E498"/>
</svg>`:eh.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="8" height="6" viewBox="0 0 8 6" fill="none">
<path d="M8 0L4 6L0 0H8Z" fill="#028948"/>
</svg>`}getPriceIncreaseTrendIcon(e){return e?eh.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="8" height="6" viewBox="0 0 8 6" fill="none">
<path d="M8 6L4 0L0 6H8Z" fill="#F9A1AC"/>
</svg>`:eh.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="8" height="6" viewBox="0 0 8 6" fill="none">
<path d="M8 6L4 0L0 6H8Z" fill="#C82B45"/>
</svg>`}},GE=class extends VE{getStyles(){return'\n #productCollections::part(title) {\n margin-top: 0px;\n }\n #productCollections fluent-button.btnSeeMore {\n width: -webkit-fill-available;\n }\n #productCollections #TRACKING {\n margin-left: 10px;\n }\n #productCollections msft-product-card {\n background-color: var(--fill-color);\n border-radius: 8px;\n }\n #productCollections msft-product-card:hover {\n background: #FFFFFF;\n box-shadow: 0px 3px 6px rgba(0, 0, 0, 0.12);\n }\n #productCollections msft-wishlist-card {\n background-color: var(--fill-color);\n border-radius: 8px;\n }\n #prodCollectionsTabs::part(tablist) {\n display: flex;\n margin: 4px 10px 12px 10px;\n }\n #prodCollectionsTabs li + li {\n margin-top: 12px;\n }\n #prodCollectionsTabs li:before {\n content: counter(item) " ";\n counter-increment: item;\n padding-right: 8px;\n }\n .emptyMessage {\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n font-weight: 600;\n font-size: 16px;\n line-height: 20px;\n text-align: center;\n margin: 5px 20px;\n }\n .emptyMessage fluent-anchor {\n margin-left: 5px;\n cursor: pointer;\n font-weight: inherit;\n font-size: inherit;\n line-height: inherit;\n }\n .viewStepsList {\n display: inline-block;\n padding: 0;\n counter-reset: item;\n list-style-type: none;\n }\n .viewStepsListElement {\n text-align: left;\n margin-left: 22px;\n text-indent: -22px;\n font-size: 16px;\n line-height: 22px;\n }\n .listWrapper {\n border-radius: 8px;\n display: flex;\n flex-direction: column;\n row-gap: 12px;\n margin: 0 20px 12px;\n }\n .imageWrapper {\n display: flex;\n justify-content: center;\n align-items: center;\n height: 160px;\n }\n .zeroStateImage {\n height: 100%;\n }\n .bellIconImg {\n margin-top: 6px;\n }\n #productCollections msft-product-card::part(divTextContent) {\n width: 195px;\n }\n #productCollections msft-product-card.noPrice::part(divTextContent) {\n width: 190px;\n }\n #productCollections msft-product-card::part(txtRetailer) {\n color: var(--text-neutral-foreground-hint);\n }\n fluent-button.recently-viewed-button::part(control) {\n padding: 4px;\n right: 0px;\n position: absolute;\n }\n .consentBanner {\n margin-bottom: 16px;\n border-radius: 8px;\n box-shadow: 0px 0px 2px 0px rgba(0, 0, 0, 0.12), 0px 1px 2px 0px rgba(0, 0, 0, 0.14);\n }\n #roamProductsContainer {\n display: flex;\n background-color: var(--fill-color);\n flex-direction: column;\n justify-content: center;\n align-items: flex-end;\n gap: 12px;\n align-self: stretch;\n }\n #roamProductsContainer .textContainer {\n padding: 0;\n }\n #roamProductsContainer .titleText {\n font-size: 14px;\n font-weight: 600;\n line-height: 20px;\n }\n #roamProductsContainer .consentText {\n font-size: 12px;\n }\n #roamProductsContainer .actionsContainer {\n display: flex;\n justify-content: flex-end;\n margin-top: 12px;\n gap: 8px;\n }\n #roamProductsContainer .actionsContainer > fluent-button {\n margin: 0px;\n border-radius: 4px;\n min-width: 104px;\n }\n #signInSection > div {\n display: flex;\n flex-wrap: nowrap;\n }\n #signInSection .iconContainer {\n width: 72px;\n height: 72px;\n }\n #signInSection .textContainer {\n padding-left: 16px;\n }\n #signInSection .actionsContainer {\n display: flex;\n justify-content: space-between;\n padding-top: 12px;\n gap: 8px;\n }\n #signInSection .actionsContainer > fluent-button {\n flex: 1;\n margin: 0px;\n border-radius: 4px;\n }\n .privacyContainer {\n padding: 0px 16px 16px;\n font-size: 12px;\n color: var(--text-neutral-foreground-hint);\n }\n .privacyContainer fluent-anchor::part(control) {\n text-decoration: none;\n }\n .privacyContainer fluent-anchor::part(control):hover {\n text-decoration: underline;\n }\n .privacyContainer fluent-anchor.privacySeeMore::part(control) {\n color: var(--text-neutral-foreground-hint);\n text-decoration: underline;\n }\n '}getDarkModeStyles(){return"\n #prodCollectionsTabs fluent-tab[aria-selected=true] {\n color: #63ADE5;\n border: 1px solid #63ADE5;\n }\n .listWrapper product-card::part(control) {\n border-top: 0px;\n }\n .listWrapper wishlist-card::part(control) {\n border-top: 0px;\n }\n #productCollections fluent-button.btnSeeMore {\n width: -webkit-fill-available;\n margin: 0px 20px 20px;\n }\n #productCollections msft-product-card {\n background-color: #424242;\n border-radius: 8px;\n }\n #productCollections msft-product-card:hover {\n background: #424242;\n }\n #productCollections msft-wishlist-card {\n background-color: #424242;\n border-radius: 8px;\n }\n #productCollections fluent-button {\n margin: 0px 10px 0px 5px;\n background-color: #4A4A4A;\n border-radius: 10px;\n }"}getCouponIconStyles(){return eh.Z.getTrustedHTML`<svg width="14" height="15" viewBox="0 0 14 15" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M8.97607 1.35214C8.42353 0.845623 7.57008 0.864166 7.04006 1.3942L0.424195 8.01027C-0.122524 8.557 -0.122517 9.44342 0.424211 9.99015L1.35036 10.9163C1.6975 11.2634 2.19693 11.1798 2.49108 10.9838C2.66528 10.8677 2.87418 10.8 3.1001 10.8C3.70761 10.8 4.2001 11.2925 4.2001 11.9C4.2001 12.1259 4.13242 12.3348 4.01631 12.509C3.82025 12.8032 3.73665 13.3026 4.0838 13.6497L4.98826 14.5542C5.54674 15.1127 6.45638 15.0989 6.99769 14.5238L13.5968 7.51219C14.1317 6.94391 14.0986 6.04802 13.5234 5.52068L12.637 4.70812C12.418 4.50741 12.1409 4.4695 11.9104 4.51063C11.6834 4.55113 11.4682 4.67127 11.3128 4.84145C11.1111 5.06245 10.822 5.2002 10.5001 5.2002C9.89258 5.2002 9.4001 4.70771 9.4001 4.1002C9.4001 3.81233 9.51015 3.55108 9.69119 3.35476C9.84743 3.18533 9.94851 2.9605 9.96917 2.73086C9.99015 2.49763 9.92826 2.22502 9.70942 2.02441L8.97607 1.35214Z" fill="#18AB6E"/>
</svg>
`}getCashbackIconStyles(){return eh.Z.getTrustedHTML`<svg width="14" height="9" viewBox="0 0 14 9" fill="none" xmlns="http://www.w3.org/2000/svg" style="transform: scale(2.2);margin: 0 2px;">
<path d="M2.49507 6.16572e-06C1.39051 -0.00270725 0.497293 0.890516 0.500006 1.99507L0.511429 6.64502C0.514142 7.74958 1.41176 8.6472 2.51632 8.64991L9.10413 8.6661C9.62955 8.66739 10.1334 8.46186 10.5067 8.09394L12.9019 5.73317C13.693 4.95348 13.6918 3.67471 12.8993 2.88872L10.5912 0.599778C10.2157 0.227396 9.70907 0.0177279 9.18153 0.0164318L2.49507 6.16572e-06Z" fill="#3267FA"></path>
</svg>`}},jE=class extends Qu{constructor(e,t,i,n){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"discoverTelemetryHandler",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"stateManagementModule",void 0),(0,s.Z)(this,"newPwiloData",void 0),(0,s.Z)(this,"sectionId","productCollections"),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"previousHistory",null),(0,s.Z)(this,"parent",void 0),(0,s.Z)(this,"showAllItems",!1),(0,s.Z)(this,"historyTelemetrySent",!1),(0,s.Z)(this,"productTrackingUtilities",void 0),(0,s.Z)(this,"productTrackingViewUtilities",void 0),(0,s.Z)(this,"shouldRenderProdHistory",void 0),(0,s.Z)(this,"recentsTabId",r._E.RecentlyViewed),(0,s.Z)(this,"wishlistTabId",r._E.Saved),(0,s.Z)(this,"trackedTabId",r._E.TrackedProducts),(0,s.Z)(this,"trackedProductTelemetrySent",!1),(0,s.Z)(this,"tabId","prodCollectionsTabs"),(0,s.Z)(this,"lastFocusedIndex",void 0),(0,s.Z)(this,"firedProductHistoryViewed",void 0),(0,s.Z)(this,"defaultLocale","en-us"),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"storageHandler",void 0),this.logModule=i.logModule,this.pageHandlerModule=i.pageHandlerModule,this.flyoutData=t,this.utilities=i.viewModulesUtilities,this.storageHandler=i.storageHandler,this.assets=new GE,this.stateManagementModule=e,this.commonAssets=n,this.parent=this.flyoutData.common.shoppingPersistent,this.discoverTelemetryHandler=i.discoverTelemetryHandler,this.productTrackingUtilities=new qu.ZP(i,this.flyoutData,this.stateManagementModule),this.shouldRenderProdHistory=this.shouldRenderProductHistory(),this.productTrackingViewUtilities=new Ju(i,this.flyoutData,this.stateManagementModule),this.lastFocusedIndex=null,this.telemetryUtilities=i.telemetryHandler}GetModuleName(){return r.ModuleNames.PRODUCT_COLLECTIONS}async ShouldRenderModule(){return e.R.isExperimentActive(f.H.discoverShopping)&&this.flyoutData.common.isDiscoverPane&&this.shouldRenderProdHistory?Promise.resolve(!0):await this.productTrackingUtilities.shouldRenderProductCollections(this.flyoutData.common.domain)}renderModule(){this.utilities.applyStyles(this.parent,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());let t=document.getElementById(this.sectionId);e.R.isExperimentActive(f.H.singleScrollingShoreline)&&t?t.replaceChildren():t=(0,Y.Ux)("msft-edge-shopping-section"),t.id=this.sectionId,t.titleText=this.flyoutData.strings.prodCollSectionTitle;const n=(0,Y.Ux)("fluent-tabs");n.id=this.tabId,n.classList.add("sectionTabList");const o=(0,Y.Qn)(n,this.trackedTabId,this.flyoutData.strings.prodCollTrackingTitle),a=e=>{const i=this.renderTrackedProducts(t,e);o.appendChild(i),!e?.length&&this.shouldRenderProdHistory&&(n.activeid=this.recentsTabId)};if(this.flyoutData.common.isDiscoverPane?(this.utilities.applyStyles(t,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),a([])):this.productTrackingUtilities.GetTrackedProductsBySource(ut.e7.Explicit).then((e=>{a(e)})),this.shouldRenderWishlist()){const e=this.renderWishlist();(0,Y.Qn)(n,this.wishlistTabId,this.flyoutData.strings.prodCollWishlistTitle,e)}if(this.flyoutData.dataStoreModule.SANConsentData?.PersonalizationDataConsent){const e=this.renderProductHistory();(0,Y.Qn)(n,this.recentsTabId,this.flyoutData.strings.prodCollProdHistoryTitle,e)}if(this.productTrackingUtilities.AnidTrackingAvailable()&&this.GetOverTheTopBanner().then((e=>{e&&t.prepend(e)})),t.appendChild(n),this.stateManagementModule.addEventListener(Ku.e1.ProductTrackingUpdate,(async()=>{const e=await this.productTrackingUtilities.GetTrackedProductsBySource(ut.e7.Explicit);this.renderTrackedProducts(t,e)})),this.stateManagementModule.addEventListener(Ku.e1.FocusProductCollections,(e=>{const i=e.detail?.tabId??r._E.TrackedProducts;let o=t;if(o||(o=this.parent.querySelector(this.sectionId)),o){o.scrollIntoView({behavior:"smooth"});let e=n;e||(e=this.parent.querySelector(this.tabId)),e&&(e.activeid=i)}})),this.flyoutData.common.isDiscoverPane){const e=()=>{this.discoverTelemetryHandler.LogEventTelemetry(i.xu.ProductCollectionsDiscoverHover,"Product Collections Hover","",r.ModuleNames.PRODUCT_COLLECTIONS),t.removeEventListener("mouseover",e)};t.addEventListener("mouseover",e)}return n.addEventListener("change",(e=>{const t=e?.detail?.id;if(t===this.recentsTabId){this.firedProductHistoryViewed||(this.pageHandlerModule.RecordAsContentViewed(bp.r.PRODUCT_HISTORY),this.firedProductHistoryViewed=!0);const e=new W.Z(i.$S.ProductCollectionsRecentsTab,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.LogClickInfoEvent(i.R.ButtonClick,"Recents tab clicked",e),this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKING_COLLECTIONS_TAB_SWITCH_1)}else if(t===this.trackedTabId){const e=new W.Z(i.$S.ProductCollectionsTrackingTab,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.LogClickInfoEvent(i.R.ButtonClick,"Tracking tab clicked",e),this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKING_COLLECTIONS_TAB_SWITCH_2)}})),Promise.resolve(this.CreateModule(t,r.H7.PRODUCT_COLLECTIONS,r.ModuleNames.PRODUCT_COLLECTIONS,r.$k.HOME,r.SV.LIST))}populateMainHeader(){if(this.flyoutData.common.shoppingPersistent){const e=this.flyoutData.common.shoppingPersistent.querySelector(`#${this.sectionId}`);e&&(e.style.marginTop="0px",e.slot="header-content",e.hideTitle=!1)}}PostProcessing(e,t,n){this.storageHandler.getStorageString(Ce.Q.PostPurchasePendingProducts).then((e=>{if(!e||"null"===e)return;const t=JSON.parse(e);this.storageHandler.getStorageBool(Ce.Q.PriceMatchConsent).then((i=>{e.length&&i&&this.sendPostPurchaseRequest(t)}))})),this.flyoutData.common.isDiscoverPane&&(this.discoverTelemetryHandler.LogEventTelemetry(i.xu.ProductCollectionsDiscoverRender,"Product Collections Render","",r.ModuleNames.PRODUCT_COLLECTIONS),this.pageHandlerModule.RecordAsContentViewed(bp.r.PRODUCT_HISTORY))}CreateRoamProductsSection(e){const{strings:t,common:{popupOrigination:n}}=this.flyoutData,o=(0,Y.Ux)("div",{id:"roamProductsContainer",className:"lateralMargin consentBanner"}),r=(0,Y.Ux)("div",{className:"textContainer"}),a=(0,Y.Ux)("div",{className:"actionsContainer"}),s=(0,Y.Ux)("div",{className:"titleText",textContent:t.prodCollConsentTitle}),l=(0,Y.Ux)("div",{className:"consentText",textContent:t.prodCollConsentText}),c=(0,Y.Ux)("fluent-button");c.setAttribute("appearance","accent"),c.textContent=t.prodCollConsentYes,c.addEventListener("click",(()=>{this.productTrackingUtilities.RoamProductsFromEndpoint(),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_TRACKING_COLLECTIONS_ROAM,n),this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKING_COLLECTIONS_ROAM);const e=new W.Z(i.$S.ProductTrackingCollectionsConsentRoam,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"Product collections consent roam",e),o.remove()}));const d=(0,Y.Ux)("fluent-button");d.textContent=t.prodCollConsentNoThanks,d.setAttribute("appearance","neutral"),d.addEventListener("click",(()=>{const t=new W.Z(i.$S.ProductTrackingCollectionsConsentRoamClose,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"Product collections consent roam closed",t),this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKING_COLLECTIONS_ROAM_CLOSE),o.remove(),e()}));const u=(0,Y.Ux)("div",{style:"padding: 16px"});return a.appendChild(c),a.appendChild(d),r.appendChild(s),r.appendChild(l),u.appendChild(r),u.appendChild(a),o.appendChild(u),o}CreateSignInSection(e){const{strings:t,common:{popupOrigination:n}}=this.flyoutData,o=(0,Y.Ux)("div",{id:"signInSection",className:"lateralMargin consentBanner"}),r=(0,Y.Ux)("div",{className:"iconContainer"}),a=(0,Y.Ux)("IMG",{className:"consentIcon"});a.src=this.flyoutData.common.resourcesEndpoint+"productTracking/productTrackingConsent.svg",a.setAttribute("aria-hidden","true"),r.appendChild(a);const s=(0,Y.Ux)("div",{className:"textContainer"}),l=(0,Y.Ux)("div",{className:"actionsContainer"}),c=(0,Y.Ux)("div",{className:"consentText",textContent:t.prodCollConsentSignInText}),d=(0,Y.Ux)("fluent-button");d.setAttribute("appearance","accent"),d.textContent=t.prodCollConsentSignIn,d.addEventListener("click",(async()=>{this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_TRACKING_COLLECTIONS_SIGN_IN,n),this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKING_COLLECTIONS_SIGN_IN);const e=new W.Z(i.$S.ProductTrackingCollectionsConsentSignIn,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"Product collections consent sign in",e),await this.pageHandlerModule.SignIntoMSA(!0),this.productTrackingUtilities.RoamProductsFromEndpoint(),o.remove()}));const u=(0,Y.Ux)("fluent-button");u.textContent=t.prodCollConsentNotNow,u.addEventListener("click",(()=>{const t=new W.Z(i.$S.ProductTrackingCollectionsConsentSignInClose,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"Product collections consent sign in closed",t),this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKING_COLLECTIONS_SIGN_IN_CLOSE),o.remove(),e()}));const h=(0,Y.Ux)("div",{className:"privacyContainer"}),p=(0,Y.Ux)("fluent-anchor",{href:T.Sk,target:"_blank",appearance:"hypertext",rel:"noopener noreferrer",textContent:t.commonMicrosoftTermsOfUse}),g=(0,Y.Ux)("fluent-anchor",{href:T.q,target:"_blank",appearance:"hypertext",rel:"noopener noreferrer",textContent:t.commonMicrosoftPolicy}),f=(0,Y.Ux)("span");(0,T.B7)(f,t.prodCollConsentSignInPrivacyText,p,g);const m=(0,Y.Ux)("fluent-anchor",{appearance:"hypertext",href:"javascript:void(0)",textContent:` ${t.commonSeeMore}`,className:"privacySeeMore"});f.appendChild(m),h.appendChild(f),m.addEventListener("click",(e=>{e.target.parentElement?.appendChild(document.createTextNode(` ${t.prodCollConsentSignInPrivacyTextSeeMore}`)),e.target.remove()})),l.appendChild(d),l.appendChild(u),s.appendChild(c),s.appendChild(l);const v=(0,Y.Ux)("div",{style:"padding: 16px"});return v.appendChild(r),v.appendChild(s),o.appendChild(v),o.appendChild(h),o}shouldRenderWishlist(){return!1}LogClickInfoEvent(e,t,n){try{this.flyoutData.common.isDiscoverPane&&e===i.R.ButtonClick&&this.discoverTelemetryHandler.LogClickTelemetry(i.xu.ProductCollectionsDiscoverClick,"","",r.ModuleNames.PRODUCT_COLLECTIONS,{buttonName:n.ButtonClicked??void 0,message:t}),this.logModule.LogInfoEvent(e,t,n)}catch(e){}}shouldRenderProductHistory(){const e=this.flyoutData.dataStoreModule.ProductHistoryData,t=(e&&e.length>0)??!1;return t&&(this.stateManagementModule.addEventListener(Ku.e1.PWILOPriceHistory,(e=>{if(e&&e.detail&&e.detail.data){const t=e.detail.data.webAssistEntities;if(t){this.newPwiloData=!0;const e=[];t&&t.length>0&&t.forEach((t=>{e.push(new wt(t))})),this.flyoutData.dataStoreModule.ProductHistoryData=e,document.querySelector("#RECENTS_SECTION")&&this.addProdHistoryAnnotation()}}})),this.stateManagementModule.addEventListener(Ku.e1.ModulesRendered,(()=>{this.newPwiloData&&gn.SO.queueUpdate((()=>{this.addProdHistoryAnnotation()}))}))),t}async GetOverTheTopBanner(){const e=(await this.pageHandlerModule.GetEdgeAnid(!0))?.anid;let t=null;if(e?await this.productTrackingUtilities.anidLoggedInHasTrackedProductsButNotExplicitlyConsented()&&(t=ZE.Consent):t=ZE.SignIn,!t)return null;if(await this.productTrackingUtilities.shownBannerRecently(t))return null;const i=()=>{this.productTrackingUtilities.setConsentLastShown(t)};return t===ZE.SignIn?this.CreateSignInSection(i):this.CreateRoamProductsSection(i)}renderTrackedProducts(e,t){let i=e.querySelector("#TRACKING_SECTION");if(i||(i=(0,Y.Ux)("div",{id:"TRACKING_SECTION"})),i.textContent="",t?.length){i.style.margin="0px";const e=[...t.reverse()];this.populateTrackedProductsList(i,!1,!1,e);const n=e=>r.CS.TRACKED_PRODUCTS;this.utilities.createCommonListStructure(i,"",e,this.GetModuleName(),n,this.populateTrackedProductsList.bind(this),void 0)}else{i.style.margin="0 20px";const{strings:e,common:t}=this.flyoutData,n=`productCollections/tracked${this.utilities.isDarkMode()?"DM":"LM"}.png`,o=Ju.isSupportedDomainForPrice(t.domain,this.flyoutData.dataStoreModule?.ProductTrackingData,t.market)?this.createEmptyCardWithHypertext(n):this.createEmptyCard(n,e.prodCollEmptyTrackingMessage);i.appendChild(o)}return i}renderWishlist(){const e=(0,Y.Ux)("div");e.id="WISHLIST_SECTION",e.style.margin="0 20px";const t=this.utilities.isDarkMode();return e.appendChild(this.createEmptyCard(`productCollections/saved${t?"DM":"LM"}.png`,this.flyoutData.strings.prodCollEmptyWishlistMessage)),e}renderProductHistory(){let e=document.getElementById("RECENTS_SECTION");e||(e=(0,Y.Ux)("div"),e.id="RECENTS_SECTION");const t=e=>r.CS.PRODUCTHISTORY;this.stateManagementModule.addEventListener(Ku.e1.PWILODeleted,(i=>{if(i&&i.detail&&void 0!==i.detail.index){if(this.flyoutData.dataStoreModule.ProductHistoryData=this.flyoutData.dataStoreModule.ProductHistoryData?.filter(((e,t)=>t!==i.detail.index)),this.flyoutData.dataStoreModule.ProductHistoryData&&this.flyoutData.dataStoreModule.ProductHistoryData.length>0){const i=document.querySelector("#productCollections #RECENTS_SECTION .listWrapper"),n=document.querySelector("#productCollections #RECENTS_SECTION .btnSeeMore");i&&(i.remove(),n&&n.remove(),e=document.getElementById("RECENTS_SECTION"),gn.SO.queueUpdate((()=>{this.populateProductHistoryList(e,this.showAllItems,!1).then((()=>{this.showAllItems||this.utilities.createCommonListStructure(e,"",this.flyoutData.dataStoreModule.ProductHistoryData,this.GetModuleName(),t,this.populateProductHistoryList.bind(this),void 0),gn.SO.queueUpdate((()=>{e.expanded=!0}))}))})))}else if(e){e.textContent="",e.style.margin="0 20px";const t=this.utilities.isDarkMode();e.appendChild(this.createEmptyCard(`productCollections/recent${t?"DM":"LM"}.png`,this.flyoutData.strings.prodCollEmptyRecentlyViewedMessage));const i=new CustomEvent(Ku.e1.PWILOEmpty);this.stateManagementModule.dispatchEvent(i)}if((0,T.pq)(i.detail.event)){const e=this.parent.querySelector(`#${r.z6.CLOSE}`);e&&e.focus()}}}));const i=this.flyoutData.dataStoreModule.ProductHistoryData;if(!i||i?.length>0)this.populateProductHistoryList(e,!1,!1).then((()=>{this.utilities.createCommonListStructure(e,"",this.flyoutData.dataStoreModule.ProductHistoryData,this.GetModuleName(),t,this.populateProductHistoryList.bind(this),void 0)}));else{e.textContent="",e.style.margin="0 20px";const t=this.utilities.isDarkMode();e.appendChild(this.createEmptyCard(`productCollections/recent${t?"DM":"LM"}.png`,this.flyoutData.strings.prodCollEmptyRecentlyViewedMessage))}e.addEventListener("click",(function t(){if(e){const t=e.shadowRoot;if(t){const e=t.querySelector("fluent-accordion-item");e&&(e.classList.contains("expanded")||o?a||(n.RecordAsUserAction(K.bS.PRODUCT_HISTORY_COLLAPSE_SECTION),a=!0):(n.RecordAsUserAction(K.bS.PRODUCT_HISTORY_EXPAND_SECTION),o=!0))}}o&&a&&e&&e.removeEventListener("click",t)}));const n=this.pageHandlerModule;let o=!1,a=!1;return e}async populateTrackedProductsList(e,n,o,a){e.textContent="";const s=(0,Y.Ux)("div",{className:"listWrapper"});e.appendChild(s);const l=a;if(!l||!Array.isArray(l))return;let c=r.CS.TRACKED_PRODUCTS;if(n){if(!this.trackedProductTelemetrySent){this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKING_COLLECTIONS_TRACKED_PRODUCT_SEE_MORE_CLICK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_TRACKING_COLLECTIONS_TRACKED_PRODUCT_SEE_MORE_CLICK,this.flyoutData.common.popupOrigination);const e=new W.Z(i.$S.ProductTrackingCollectionsSeeAll,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.LogClickInfoEvent(i.R.ButtonClick,"See more product tracking collections",e),this.trackedProductTelemetrySent=!0}c=l.length;const t=new CustomEvent(Ku.e1.SeeMoreClick,{detail:{totalCards:c}});e.dispatchEvent(t)}for(let n=0;n<c;n++){const o=l[n];if(!o)continue;const r=document.createElement("msft-product-card");r.inCollections=!0,r.isPWILOExpActive=!0,r.ariaSetSize=c.toString(),r.ariaPosInSet=(n+1).toString(),e.addEventListener(Ku.e1.SeeMoreClick,(e=>{e?.detail?.totalCards&&(r.ariaSetSize=e?.detail?.totalCards.toString())}));const a=o.CurrentPrice?.toString()||o.basePrice?.toString(),d=o.CurrencySymbol??"$";this.parsePrice(r,a||"",d,this.defaultLocale);const u=qu.ZP.getDomainFromUrl(o.ProductUrl);let h=`| ${u}`;a&&(h+=(0,T.fZ)("prodCollPrice",this.flyoutData.strings.prodCollPrice,a)),r.retailer=u,r.title=`${o.Title}, ${h}`,r.description=`${o.Title} | ${u}`;const p=(0,Y.Ux)("IMG");let g=o.imageUrl;g&&!g.startsWith("http")&&(g="https://"+g),this.utilities.setImageSrc(p,g||"").then((e=>{if(!e){const e=new t.Z(i.xu.ProductTrackingCollectionsStatus,void 0,void 0,this.flyoutData.common.domain,JSON.stringify(o));this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"NoImage",e),this.useImageFromProductHistory(p,o)}}));const f=this.utilities.createProductImage(76,76,p);f.slot="image",this.addTrackingIcon(r,o,n),this.createAnnotation(r,o.CurrentPrice,(o.basePrice||o.OlderPrice)?.toString(),o.CurrencySymbol,this.defaultLocale,o.highSuccessRateCoupon,o.cashbackCommission),r.addEventListener("click",(e=>{if(e.target&&"options"!==e.target.slot&&"trackingBell"!==e.target.slot){const e=new W.Z(i.$S.ProductCollectionsProduct,this.telemetryUtilities.setContentViewed(this.GetModuleName()),this.flyoutData.common.domain,JSON.stringify(o));this.LogClickInfoEvent(i.R.ButtonClick,"Tracked product click",e),this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKING_PRODUCT_COLLECTIONS_CLICK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_TRACKING_PRODUCT_COLLECTIONS_CLICK,this.flyoutData.common.popupOrigination),this.copyHighSuccessCouponToClipboard(o.highSuccessRateCoupon),this.pageHandlerModule.NavigateToRetailerSite(o.ProductUrl)}else if((e.target&&"options"===e.target.slot||"trackingBell"===e.target.slot)&&(0,T.pq)(e)){let e;e=n+1<l.length?document.querySelector(`.listWrapper msft-product-card:nth-child(${n+1})`):n&&n+1===l.length?document.querySelector(".listWrapper msft-product-card:nth-last-child(1)"):document.querySelector("#TRACKING"),e?.focus()}})),r.appendChild(f),s.appendChild(r)}}async copyHighSuccessCouponToClipboard(t){if(!e.R.isExperimentActive(f.H.ptCouponsCashbackNotification))return;if(!t)return;if(!t.couponCode.length)return;const i=document.createElement("textarea");i.value=t.couponCode,document.body.appendChild(i),i.focus(),i.select(),document.execCommand("copy"),document.body.removeChild(i),this.stateManagementModule.dispatchEvent((0,Ku.eT)({text:"Coupon Copied"}))}useImageFromProductHistory(e,n){const o=this.flyoutData.dataStoreModule.ProductHistoryData,r=o?.find((({url:e})=>qu.ZP.isSameUrlByPathName(e,n.ProductUrl)));if(!r)return;const a=r?.entity?.image;if(a){this.utilities.setImageSrc(e,a);const o=new t.Z(i.xu.ProductTrackingCollectionsStatus,void 0,void 0,this.flyoutData.common.domain,JSON.stringify(n));this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Used Product History Image",o)}}async populateProductHistoryList(t,n,o){let a;const s=(0,Y.Ux)("DIV",{className:"listWrapper"});s.style.borderRadius="8px",s.style.display="flex",s.style.flexDirection="column",s.style.rowGap="12px",s.style.margin="0 20px 12px";const l=this.flyoutData.dataStoreModule.ProductHistoryData;if(l){if(l.length>0&&(a=l.length),n){if(this.showAllItems=!0,!this.historyTelemetrySent){const e=new W.Z(i.$S.SeeMoreRetailers,this.telemetryUtilities.setContentViewed(this.GetModuleName())),t=new W.Z(i.$S.ProductTrackingCollectionsSeeAll,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.trackedProductTelemetrySent=!0,this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKING_COLLECTIONS_TRACKED_PRODUCT_SEE_MORE_CLICK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_TRACKING_COLLECTIONS_TRACKED_PRODUCT_SEE_MORE_CLICK,this.flyoutData.common.popupOrigination),this.LogClickInfoEvent(i.R.ButtonClick,"See more product history",e),this.LogClickInfoEvent(i.R.ButtonClick,"See more product history",t),this.historyTelemetrySent=!0}const e=new CustomEvent(Ku.e1.SeeMoreClick,{detail:{totalCards:l.length}});s.dispatchEvent(e)}else a>r.CS.PRODUCTHISTORY&&(a=r.CS.PRODUCTHISTORY);const c=[];for(let i=0;i<a;i++){const d=this.createProductHistoryItem(l[i],a,i,s);c.push(d),this.addProdHistoryAnnotation(d,i),e.R.isExperimentActive(f.H.PTRecentVwd)&&this.addRecentlyViewedTrackIcon(d,l[i],this.previousHistory,t),this.addDeleteButton(d,l[i],this.previousHistory,t,i),this.manageProductLinkEvents(d,l[i]),this.previousHistory=d,s.appendChild(d),(0===i&&n&&o&&this.flyoutData.common.currentDevice===r.AS.Desktop&&d||this.lastFocusedIndex===i)&&(gn.SO.queueUpdate((()=>{d.focus()})),this.lastFocusedIndex=null)}this.addSavingsAnnotation(l,c,0,a);const d=document.querySelector("#RECENTS_SECTION .listWrapper");d?t.replaceChild(s,d):t.appendChild(s)}}async addSavingsAnnotation(e,t,i,n){const o=await this.sendSavingsRequest(e);let r=0;if(Array.isArray(o))for(let e=i;e<n;e++){const i=o[e];i&&"0"!==i&&!isNaN(parseInt(i,10))&&t[r]&&(t[r].savings=i),r++}}getListOfDomain(e){const t=[];for(const i of e)t.push(i.domain);return t}async sendSavingsRequest(e){let n=[];try{const t={DomainNames:this.getListOfDomain(e)},i={body:JSON.stringify(t),headers:{"Content-Type":"application/json"},method:"POST"},o="https://www.bing.com/api/shopping/v1/savings/getSavings",r=await fetch(o,i),a=await r.json();a&&a.savingsPerDomain&&(n=a.savingsPerDomain)}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Product history getSavings error ${e}`,n)}return n}addTrackingIcon(e,t,n){const o=(0,Y.Ux)("fluent-button");o.slot="options",o.title=this.flyoutData.strings.prodCollDeleteTitle,o.ariaLabel=this.flyoutData.strings.prodCollDeleteTitle,o.appearance="stealth";const a=(0,Y.Ux)("IMG",{className:"bellIconImg"});a.src=this.flyoutData.common.resourcesEndpoint+"productTracking/trackProductActiveWhite.svg",a.setAttribute("aria-hidden","true");const s=(0,Y.Ux)("DIV",{style:"display: flex; place-self: center; font-size: 10px;"},this.flyoutData.strings.prodCollDeleteTitle);s.slot="start",s.classList.add("txtSmall"),o.addEventListener("blur",(()=>{const t=e.shadowRoot?.querySelector(".divTextContent");t?.classList.remove("divTextContentSmallWidth"),o.removeChild(s)})),o.addEventListener("focus",(()=>{const t=e.shadowRoot?.querySelector(".divTextContent");t?.classList.add("divTextContentSmallWidth"),o.setAttribute("aria-label",this.flyoutData.strings.prodCollDeleteTitle),o.appendChild(s)})),o.appendChild(a),o.addEventListener("click",(async o=>{const a=new W.Z(i.$S.ProductCollectionTrackedProductsUntrack,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.LogClickInfoEvent(i.R.ButtonClick,"Product untracked",a),e.remove(),this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKING_PRODUCT_COLLECTIONS_UNTRACK_CLICK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_TRACKING_PRODUCT_COLLECTIONS_CLICK,this.flyoutData.common.popupOrigination);const s=this.flyoutData.common.currentUrl;this.productTrackingUtilities.GetTrackedProduct(s).then((async e=>{this.productTrackingUtilities.UntrackProductLocal(t),qu.ZP.IsSameProduct(t,e)?this.productTrackingViewUtilities.switchToggleOff():await this.productTrackingUtilities.UntrackProduct(t)})).finally((()=>{if(n<r.CS.TRACKED_PRODUCTS){const e=new CustomEvent(Ku.e1.ProductTrackingUpdate);this.stateManagementModule.dispatchEvent(e)}}))})),e.appendChild(o)}addProdHistoryAnnotation(e,t){const i=this.flyoutData.dataStoreModule.ProductHistoryData;if(i&&i.length>0)if(this.newPwiloData){const n=document.querySelector("#RECENTS_SECTION"),o=n?.querySelectorAll("msft-product-card");if(o&&o.length===i.length)for(let e=0;e<i.length;e++)o[e].hasAnnotation||this.validateAndCreateAnnotation(o[e],i[e]);else if(o&&o.length>0&&n&&!e&&void 0===t){for(const e of o)e.remove();const e=document.querySelector("#productCollections #RECENTS_SECTION .listWrapper"),t=document.querySelector("#productCollections #RECENTS_SECTION .btnSeeMore");e&&e.remove(),t&&t.remove(),this.renderProductHistory()}}else e&&void 0!==t&&!e.hasAnnotation&&this.validateAndCreateAnnotation(e,i[t])}validateAndCreateAnnotation(e,t){if(t&&"No data found"!==t?.newTimestamp&&t.entity){const{latestPrice:i,priceValue:n,priceCurrency:o,pageLocale:r}=t.entity;this.createAnnotation(e,i,n,o??"$",r)}}createProductHistoryItem(e,t,i,n){const o=document.createElement("msft-product-card");o.inCollections=!0,this.parsePrice(o,e.entity.priceValue,e.entity.priceCurrency,e.entity.pageLocale);const r=`${e.entity.priceCurrency}${e.entity?.priceValue}`;return r&&(o.title=`${e.title} ${(0,T.fZ)("prodCollPrice",this.flyoutData.strings.prodCollPrice,r)}`),o.href="#",o.description=e.title,o.isPWILOExpActive=!0,o.ariaSetSize=t.toString(),o.ariaPosInSet=(i+1).toString(),n.addEventListener(Ku.e1.SeeMoreClick,(e=>{e?.detail?.totalCards&&(o.ariaSetSize=e?.detail?.totalCards.toString())})),e.domain&&(o.retailer=this.utilities.getDomainNameAndCapitalize(e.domain),this.createProductImages(o,e)),this.previousHistory=o,o}async addRecentlyViewedTrackIcon(e,t,n,o){const r=(0,Y.Ux)("fluent-button");r.slot="trackingBell",r.appearance="stealth",r.style.visibility="hidden",r.className="recently-viewed-button",r.style.width="20px",r.style.minWidth="0px";const a=new SS.Z(t.title,t.entity.image,t.entity.priceCurrency);a.ProductUrl=t.url,a.price=t.entity.price.toString();let s=await this.productTrackingViewUtilities.isTrackedProduct(qu.ZP.GetStrippedUrl(a.ProductUrl));this.stateManagementModule.addEventListener(Ku.e1.ProductTrackingUpdate,(async()=>{const e=await this.productTrackingViewUtilities.isTrackedProduct(qu.ZP.GetStrippedUrl(a.ProductUrl));if(s===e)return;s=e;const t=s?this.flyoutData.strings.prodCollDeleteTitle:this.flyoutData.strings.prodCollStartTracking,i=r.querySelector("img");i&&(i.src=s?this.flyoutData.common.resourcesEndpoint+"productTracking/trackProductActiveWhiteBlack.svg":this.flyoutData.common.resourcesEndpoint+"productTracking/trackProductInactiveWhiteBlack.svg"),r.setAttribute("aria-label",t),r.title=t,c.slot="start";const n=r.querySelector("DIV.txtSmall");n&&(n.textContent=t)})),r.addEventListener("click",(async e=>{const t=new W.Z(s?i.$S.ProductCollectionsRecentlyViewedUntrack:i.$S.ProductCollectionsTrack,this.telemetryUtilities.setContentViewed(this.GetModuleName()));t.Metadata=JSON.stringify(a),this.LogClickInfoEvent(i.R.ButtonClick,s?"Product untracked":"Product tracked",t),this.pageHandlerModule.RecordAsUserAction(s?K.bS.PRODUCT_TRACKING_PRODUCT_COLLECTIONS_UNTRACK_CLICK:K.bS.PRODUCT_TRACKING_COLLECTIONS_TRACK_CLICK),s||this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_TRACKING_COLLECTIONS_TRACK_CLICK,this.flyoutData.common.popupOrigination),this.productTrackingViewUtilities.sendTrackingData(a,!s,!1),s=!s;const n=s?this.flyoutData.strings.prodCollDeleteTitle:this.flyoutData.strings.prodCollStartTracking,o=r.querySelector("img");o&&(o.src=s?this.flyoutData.common.resourcesEndpoint+"productTracking/trackProductActiveWhiteBlack.svg":this.flyoutData.common.resourcesEndpoint+"productTracking/trackProductInactiveWhiteBlack.svg"),r.setAttribute("aria-label",n),r.title=n,c.slot="start";const l=r.querySelector("DIV.txtSmall");l&&(l.textContent=n)})),e.addEventListener("mouseover",(()=>{this.setButtonVisibility(r,!0)})),e.addEventListener("mouseout",(()=>{this.setButtonVisibility(r,!1)})),e.addEventListener("focus",(()=>{this.setButtonVisibility(r,!0)})),e.addEventListener("keydown",(e=>{e.shiftKey?this.setButtonVisibility(r,!1):this.setButtonVisibility(r,!0)})),document.addEventListener("keydown",(t=>{if(t.shiftKey)if(n&&document.activeElement===e){const e=n.querySelector("fluent-button");e&&gn.SO.queueUpdate((()=>{e.focus()}))}else{const e=o.querySelector(".btnSeeMore");e&&document.activeElement===e&&gn.SO.queueUpdate((()=>{r.focus()}))}}));const l=s?this.flyoutData.strings.prodCollDeleteTitle:this.flyoutData.strings.prodCollStartTracking,c=(0,Y.Ux)("DIV",{style:"display: flex; place-self: center; font-size: 10px;"},l);c.slot="start",c.classList.add("txtSmall"),r.addEventListener("blur",(()=>{this.setButtonVisibility(r,!1),r.removeChild(c);const t=e.shadowRoot?.querySelector(".divTextContent");t?.classList.remove("divTextContentSmallWidth")})),r.addEventListener("focus",(()=>{r.setAttribute("aria-label",l),r.appendChild(c);const t=e.shadowRoot?.querySelector(".divTextContent");t?.classList.add("divTextContentSmallWidth")})),r.title=l;const d=(0,Y.Ux)("IMG");d.setAttribute("aria-hidden","true"),d.src=s?this.flyoutData.common.resourcesEndpoint+"productTracking/trackProductActiveWhiteBlack.svg":this.flyoutData.common.resourcesEndpoint+"productTracking/trackProductInactiveWhiteBlack.svg",r.appendChild(d),e.appendChild(r)}addDeleteButton(e,t,i,n,o){const r=(0,Y.Ux)("fluent-button");r.className="recently-viewed-button",r.slot="options",r.appearance="stealth",r.style.visibility="hidden",r.style.width="20px",r.style.minWidth="0px",r.addEventListener("click",(i=>{(0,T.pq)(i)&&(this.lastFocusedIndex=this.utilities.setFocusAfterDeletion(n,o,".listWrapper","#TRACKING",".btnSeeMore")),e.remove(),t.url.startsWith("http")?this.pageHandlerModule.DeletePwiloEntry(t.url):(this.pageHandlerModule.DeletePwiloEntry("https://"+t.url),this.pageHandlerModule.DeletePwiloEntry("http://"+t.url));const r=new CustomEvent(Ku.e1.PWILODeleted,{detail:{event:i,index:o}});this.stateManagementModule.dispatchEvent(r)})),e.addEventListener("mouseover",(()=>{this.setButtonVisibility(r,!0)})),e.addEventListener("mouseout",(()=>{this.setButtonVisibility(r,!1)})),e.addEventListener("focus",(()=>{this.setButtonVisibility(r,!0)})),e.addEventListener("keydown",(e=>{e.shiftKey?this.setButtonVisibility(r,!1):this.setButtonVisibility(r,!0)})),document.addEventListener("keydown",(t=>{if(t.shiftKey)if(i&&document.activeElement===e){const e=i.querySelector("fluent-button");e&&gn.SO.queueUpdate((()=>{e.focus()}))}else{const e=n.querySelector(".btnSeeMore");e&&document.activeElement===e&&gn.SO.queueUpdate((()=>{r.focus()}))}}));const a=(0,Y.Ux)("DIV",{style:"display: flex; place-self: center; font-size: 10px;"},this.flyoutData.strings.prodHDeleteItem);a.slot="start",a.classList.add("txtSmall"),r.addEventListener("blur",(()=>{this.setButtonVisibility(r,!1),r.removeChild(a);const t=e.shadowRoot?.querySelector(".divTextContent");t?.classList.remove("divTextContentSmallWidth")})),r.addEventListener("focus",(()=>{r.setAttribute("aria-label",this.flyoutData.strings.prodHDeleteItem),r.appendChild(a);const t=e.shadowRoot?.querySelector(".divTextContent");t?.classList.add("divTextContentSmallWidth")})),r.title=this.flyoutData.strings.prodHDeleteItem;const s=(0,Y.Ux)("IMG");s.setAttribute("aria-hidden","true"),s.src=this.flyoutData.common.resourcesEndpoint+"productCollections/trashIcon.svg",r.appendChild(s),e.appendChild(r)}setButtonVisibility(e,t){t?e.style.visibility="visible":(e.style.visibility="hidden",e.ariaLabel="")}createAnnotation(t,i,n,o,a,s=null,l=null){if(t.querySelector(".prodHBottomAnnotation")||!n)return;const c=(0,ne.K)(n?.toString()??"");let d=null;c&&!isNaN(c)&&i&&-1!==i&&(i>c?d=r.lp.PRICEINCREASE:i<c&&(d=r.lp.PRICEDROP));let u="";if(!d)return;const h=(0,Y.Ux)("msft-attribution");h.className="prodHBottomAnnotation";const p=(0,Y.Ux)("DIV");let g=!1;const m=!!this.utilities.isDarkMode(),v=s&&s.couponCode,y=l&&l.value;let C=!1;if(d===r.lp.PRICEDROP){const e=(c-i)/c*100,n=this.utilities.toFixedSafe(e,0);h.textContent=(0,T.fZ)("prodHPriceDropRefresh",this.flyoutData.strings.prodHPriceDropRefresh,`${n}%`),h.className="prodHAnnotation",p.innerHTML=this.assets.getPriceDecreaseTrendIcon(m),g=!0,h.style.color=m?"#43E498":"#028948",u=(0,T.fZ)("prodCollPriceDecrease",this.flyoutData.strings.prodCollPriceDecrease,t.retailer,`${o}${c}`,`${o}${i}`)}else if(d!==r.lp.PRICEINCREASE||this.offersExist(v,y)){if(v&&e.R.isExperimentActive(f.H.ptCouponsCashbackNotification)){const e=s.discountRate;h.textContent=(0,T.fZ)("productTrackingCouponOfferPercentage",this.flyoutData.strings.productTrackingCouponOfferPercentage,e),h.className="prodHAnnotation",h.style.color=m?"#E0E0E0":"#717171",p.innerHTML=this.assets.getCouponIconStyles(),g=!0,p.style.color=m?"#43E498":"#028948",u=(0,T.fZ)("prodCollPriceDecrease",this.flyoutData.strings.prodCollPriceDecrease,t.retailer,`${o}${c}`),C=!0}else if(y&&e.R.isExperimentActive(f.H.ptCouponsCashbackNotification)){const e=l.value+l.type,i=(0,Y.Ux)("span");i.style.maxWidth="20px";const n=(0,Y.Ux)("span");n.innerHTML=this.assets.getCashbackIconStyles();const r=(0,Y.Ux)("span");r.innerText=e,r.style.position="relative",r.style.right="21px",r.style.color="white",i.appendChild(n),i.appendChild(r),(0,T.B7)(h,this.flyoutData.strings.productTrackingCashbackOfferValue,i),h.className="prodHAnnotation",h.style.color=m?"#E0E0E0":"#717171",g=!1,u=(0,T.fZ)("prodCollPriceDecrease",this.flyoutData.strings.prodCollPriceDecrease,t.retailer,`${o}${c}`),C=!0}}else{const e=(i-c)/c*100,n=this.utilities.toFixedSafe(e,0);h.textContent=(0,T.fZ)("prodHPriceIncreaseRefresh",this.flyoutData.strings.prodHPriceIncreaseRefresh,`${n}%`),h.className="prodHAnnotation",p.innerHTML=this.assets.getPriceIncreaseTrendIcon(m),g=!0,h.style.color=m?"#F9A1AC":"#C82B45",u=(0,T.fZ)("prodCollPriceIncrease",this.flyoutData.strings.prodCollPriceIncrease,t.retailer,`${o}${c}`,`${o}${i}`)}if(c&&!C){const e=(0,Y.Ux)("P");e.className="txtSmall prodHAnnotation",e.style.fontSize="10px",e.style.paddingLeft="4px",e.slot="tracked-previous-price";const n=this.utilities.formatPrice(c);e.textContent=`${o}${n}`,e.style.textAlign="end",t.appendChild(e),this.parsePrice(t,`${i}`,o,a)}g&&(p.slot="image",p.style.display="flex",h.appendChild(p)),h.slot="end",h.textContent&&(t.appendChild(h),t.style.height="100px",t.hasAnnotation=!0,t.title=`${t.description} ${u}`)}createProductImages(e,t){const i=document.createElement("IMG");this.utilities.addFavIconSrc(i,e,t.domain),i.style.width="16px",i.style.height="16px",i.style.marginRight="calc(var(--design-unit) * 2px)";const n=(0,Y.Ux)("IMG");t.entity.image&&""!==t.entity.image?this.utilities.setImageSrc(n,t.entity.image):this.utilities.setImageSrc(n,this.commonAssets.getDefaultProductImage());const o=this.utilities.createProductImage(76,76,n);o.slot="image",e.appendChild(o)}manageProductLinkEvents(e,t){e.addEventListener("click",(e=>{e.target&&"options"!==e.target.slot&&"trackingBell"!==e.target.slot&&this.navigateToRetailer(t)})),e.addEventListener("mousedown",(e=>{1===e.button&&this.navigateToRetailer(t)}))}navigateToRetailer(e){const t=new W.Z(i.$S.NavigatedToAnotherRetailer,this.telemetryUtilities.setContentViewed(this.GetModuleName()),this.flyoutData.common.domain),n=new W.Z(i.$S.ProductCollectionsProduct,this.telemetryUtilities.setContentViewed(this.GetModuleName()),this.flyoutData.common.domain,JSON.stringify(e.entity));this.LogClickInfoEvent(i.R.ButtonClick,"Recently viewed product click",n),this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_HISTORY_NAVIGATION),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_HISTORY_NAVIGATION,this.flyoutData.common.popupOrigination),this.LogClickInfoEvent(i.R.ButtonClick,"Navigation to another retailer from product history",t),this.pageHandlerModule.NavigateToRetailerSite(e.url)}offersExist(t,i){return!(!t||!e.R.isExperimentActive(f.H.ptCouponsCashbackNotification))||!(!i||!e.R.isExperimentActive(f.H.ptCouponsCashbackNotification))}createEmptyCardWithHypertext(e){const{common:t,strings:n}=this.flyoutData,o=!!t.extractedEntity,a=(0,Y.Ux)("div",{className:"emptyMessage"},n.prodCollEmptyTrackingMessage),s=this.createEmptyCard(e,void 0,a);if(o){const e=(0,Y.Ux)("fluent-anchor",{href:"#",title:n.prodCollStartTracking},n.prodCollStartTracking);e.appearance="hypertext",a.appendChild(e),e.addEventListener("click",(e=>{e.preventDefault();const o=new W.Z(i.$S.ProductCollectionsStartTracking,this.telemetryUtilities.setContentViewed(this.GetModuleName()),t.domain);this.LogClickInfoEvent(i.R.ButtonClick,n.prodCollStartTracking,o),this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKING_COLLECTIONS_TRACKED_PRODUCT_SEE_MORE_CLICK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_TRACKING_COLLECTIONS_TRACKED_PRODUCT_SEE_MORE_CLICK,this.flyoutData.common.popupOrigination),this.utilities.switchShoppingTab(r.d$.Contextual);const a=new CustomEvent(Ku.e1.FocusProductTracking);this.stateManagementModule.dispatchEvent(a)}))}else{const e=(0,Y.Ux)("fluent-anchor",{href:"#",title:n.prodCollViewSteps},n.prodCollViewSteps);e.appearance="hypertext",e.id="viewSteps",a.appendChild(e);const o=(0,Y.Ux)("div",{}),r=(0,Y.Ux)("ol",{className:"viewStepsList"});[n.prodCollStepOne,n.prodCollStepTwo,n.prodCollStepThree].forEach((e=>{const t=(0,Y.Ux)("li",{className:"viewStepsListElement"},e);r.appendChild(t)})),o.appendChild(r),o.slot="view-steps",s.appendChild(o);let l=!1;e.addEventListener("click",(e=>{e.preventDefault(),o.style.display=l?"none":"block",l=!l;const r=new W.Z(i.$S.ProductCollectionsViewSteps,this.telemetryUtilities.setContentViewed(this.GetModuleName()),t.domain);this.LogClickInfoEvent(i.R.ButtonClick,n.prodCollViewSteps,r),this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKING_COLLECTIONS_VIEW_STEPS),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_TRACKING_COLLECTIONS_VIEW_STEPS,this.flyoutData.common.popupOrigination)}))}return s}createEmptyCard(e,t,i){const n=(0,Y.Ux)("div",{className:"imageWrapper"}),o=(0,Y.Ux)("img",{className:"zeroStateImage"});this.utilities.setImageSrc(o,this.flyoutData.common.resourcesEndpoint+e),o.style.pointerEvents="none",o.setAttribute("aria-hidden","true"),n.appendChild(o),n.slot="empty-image";const r=(0,Y.Ux)("msft-wishlist-card",{id:"emptyCard"});return t&&(r.description=t),i&&(i.slot="empty-content",r.appendChild(i)),r.isEmpty=!0,r.style.minHeight="250px",r.style.height="min-content",r.style.maxHeight="372px",r.style.marginBottom="25px",r.appendChild(n),r}parsePrice(e,t,i,n){if(!t)return void e.classList.add("noPrice");const o=this.utilities.formatToParts(t,n);if(o){let t=o.find((e=>"integer"===e.type))?.value;const n=o.findIndex((e=>"group"===e.type));if(-1!==n&&n+1<o.length&&(t+=o[n+1].value),!t||!+t)return void e.classList.add("noPrice");e.price=t??"",e.priceHundredthText=o.find((e=>"fraction"===e.type))?.value??"",e.priceCurrency=(0,ne.Jl)(i)}}sendPostPurchaseRequest(e){const{timestamp:n,request:o}=e;if(this.isStale(n))this.storageHandler.clearStorage(Ce.Q.PostPurchasePendingProducts);else try{fetch("https://www.bing.com/api/shopping/v1/savings/product-tracking/track-batch-products",o).then((e=>{if(e.ok){const e=new t.Z(i.xu.PostPurchaseTrack,void 0,void 0,this.flyoutData.common.domain,JSON.stringify(o));this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"PostPurchaseTrack successful",e)}else{const e=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,"PostPurchaseTrack unsuccessful",e)}})).finally((()=>{this.storageHandler.clearStorage(Ce.Q.PostPurchasePendingProducts)}))}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`PostPurchaseTrack unsuccessful: ${e}`,n)}}isStale(e){if(!e)return!0;try{const t=new Date(e);return Date.now()-+t>864e5}catch(e){return!0}}},zE=class extends Qu{constructor(e,t,i){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"stateManagementModule",void 0),(0,s.Z)(this,"newPwiloData",void 0),(0,s.Z)(this,"sectionId","productHistorySection"),(0,s.Z)(this,"previousLink",null),(0,s.Z)(this,"parent",void 0),(0,s.Z)(this,"showAllItems",!1),(0,s.Z)(this,"telemetrySent",!1),(0,s.Z)(this,"lastFocusedIndex",void 0),(0,s.Z)(this,"productTrackingUtilities",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),this.logModule=i.logModule,this.pageHandlerModule=i.pageHandlerModule,this.flyoutData=t,this.utilities=i.viewModulesUtilities,this.assets=new VE,this.stateManagementModule=e,this.flyoutData.common.isPane?this.parent=this.flyoutData.common.shoppingPersistent:this.parent=this.flyoutData.common.shopping,this.productTrackingUtilities=new qu.ZP(i,this.flyoutData,this.stateManagementModule),this.lastFocusedIndex=null,this.telemetryUtilities=i.telemetryHandler}GetModuleName(){return r.ModuleNames.PRODUCTHISTORY}async ShouldRenderModule(){if(this.flyoutData.common.isCJKEnabled)return Promise.resolve(!0);const t=this.flyoutData.dataStoreModule.PriceComparisonData,i=t?.segment?.toLowerCase();if(i===r.VG.AUTOS&&t?.CompetingPrices&&t?.CompetingPrices.length>0||i===r.VG.EMPTYAUTOSSEGMENT)return Promise.resolve(!1);if(await this.productTrackingUtilities.shouldRenderProductCollections(this.flyoutData.common.domain))return Promise.resolve(!1);const n=this.flyoutData.dataStoreModule.ProductHistoryData,o=(n&&n.length>0&&this.flyoutData.dataLoader.IsServerData()&&e.R.isExperimentActive(f.H.showProductHistory))??!1;return o&&(this.stateManagementModule.addEventListener(Ku.e1.PWILOPriceHistory,(e=>{if(e&&e.detail&&e.detail.data){const t=e.detail.data.webAssistEntities;if(t){this.newPwiloData=!0;const e=[];t&&t.length>0&&t.forEach((t=>{e.push(new wt(t))})),this.flyoutData.dataStoreModule.ProductHistoryData=e,document.querySelector(`#${this.sectionId}`)&&this.addProdHistoryAnnotation()}}})),this.stateManagementModule.addEventListener(Ku.e1.ModulesRendered,(()=>{this.newPwiloData&&gn.SO.queueUpdate((()=>{this.addProdHistoryAnnotation()}))}))),Promise.resolve(o)}renderModule(){this.utilities.applyStyles(this.parent,this.assets.getStyles());const e=(0,Y.Ux)("msft-edge-shopping-section");function t(e){return r.CS.PRODUCTHISTORY}e.id=this.sectionId,this.stateManagementModule.addEventListener(Ku.e1.PWILODeleted,(i=>{if(i&&i.detail&&void 0!==i.detail.index){if(this.flyoutData.dataStoreModule.ProductHistoryData=this.flyoutData.dataStoreModule.ProductHistoryData?.filter(((e,t)=>t!==i.detail.index)),this.flyoutData.dataStoreModule.ProductHistoryData&&this.flyoutData.dataStoreModule.ProductHistoryData.length>0){let i;i=this.flyoutData.common.isPane?document.querySelector(`#${this.sectionId} .btnSeeMore`):document.querySelector(`#${this.sectionId} .divSeeMore`);const n=document.querySelector(`#${this.sectionId} #phdWrapper`);n&&(n.remove(),i&&i.remove(),gn.SO.queueUpdate((async()=>{await this.populateProductHistoryList(e,this.showAllItems,!1),this.showAllItems||this.utilities.createCommonListStructure(e,this.flyoutData.strings.prodHSectionTitle,this.flyoutData.dataStoreModule.ProductHistoryData,this.GetModuleName(),t,await this.populateProductHistoryList.bind(this),void 0),this.flyoutData.common.isPane&&gn.SO.queueUpdate((()=>{e.expanded=!0}))})))}else if(e){e.remove();const t=new CustomEvent(Ku.e1.PWILOEmpty);this.stateManagementModule.dispatchEvent(t)}if((0,T.pq)(i.detail.event)){const e=this.parent.querySelector(`#${r.z6.CLOSE}`);e&&e.focus()}}})),this.populateProductHistoryList(e,!1,!1),this.utilities.createCommonListStructure(e,this.flyoutData.strings.prodHSectionTitle,this.flyoutData.dataStoreModule.ProductHistoryData,this.GetModuleName(),t,this.populateProductHistoryList.bind(this),void 0);const i=this.CreateModule(e,r.H7.PRODUCTHISTORY,r.ModuleNames.PRODUCTHISTORY,r.$k.HOME,r.SV.LIST);e.addEventListener("click",(function t(){if(e){const t=e.shadowRoot;if(t){const e=t.querySelector("fluent-accordion-item");e&&(e.classList.contains("expanded")||o?a||(n.RecordAsUserAction(K.bS.PRODUCT_HISTORY_COLLAPSE_SECTION),a=!0):(n.RecordAsUserAction(K.bS.PRODUCT_HISTORY_EXPAND_SECTION),o=!0))}}o&&a&&e&&e.removeEventListener("click",t)}));const n=this.pageHandlerModule;let o=!1,a=!1;return Promise.resolve(i)}populateMainHeader(){if(this.flyoutData.common.shoppingPersistent){const e=this.flyoutData.common.shoppingPersistent.querySelector(`#${this.sectionId}`);if(e){e.style.marginTop="0px",e.slot="header-content";const t=e.querySelector("#pdhWrapper");t&&(t.style.margin="0px!important")}}}PostProcessing(e,t,i){gn.SO.queueUpdate((()=>{const e=i.shadowRoot?.querySelector("fluent-accordion-item");if(e){const t=e.shadowRoot?.querySelector(".region");t&&(t.style.marginBottom="0px")}}))}async addProdHistoryAnnotation(e,t){const i=this.flyoutData.dataStoreModule.ProductHistoryData;if(i&&i.length>0)if(this.newPwiloData){const n=document.querySelector(`#${this.sectionId}`),o=n?.querySelectorAll("msft-product-card");if(o&&o.length===i.length)for(let e=0;e<i.length;e++)o[e].hasAnnotation||this.createAnnotation(o[e],i[e]);else if(o&&o.length>0&&n&&!e&&void 0===t){for(const e of o)e.remove();await this.populateProductHistoryList(n,!1,!1)}}else e&&void 0!==t&&!e.hasAnnotation&&this.createAnnotation(e,i[t])}getListOfDomain(e){const t=[];for(const i of e)t.push(i.domain);return t}async sendSavingsRequest(e){let n=[];try{const t={DomainNames:this.getListOfDomain(e)},i={body:JSON.stringify(t),headers:{"Content-Type":"application/json"},method:"POST"},o="https://www.bing.com/api/shopping/v1/savings/getSavings",r=await fetch(o,i),a=await r.json();a&&a.savingsPerDomain&&(n=a.savingsPerDomain)}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Product history getSavings error ${e}`,n)}return n}populateProductHistoryList(e,t,n){let o,a=document.querySelector(`#${this.sectionId} #pdhWrapper`);a||(a=(0,Y.Ux)("DIV"),a.id="pdhWrapper",this.flyoutData.common.isPane&&(a.style.borderRadius="8px",a.style.display="flex",a.style.flexDirection="column",a.style.rowGap="12px",a.style.margin="0 20px 12px"));const s=this.flyoutData.dataStoreModule.ProductHistoryData;if(s){s.length>0&&(o=s.length);let l=0;if(t){if(this.showAllItems=!0,this.telemetrySent)l=0;else{const e=new W.Z(i.$S.SeeMoreRetailers,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"See more product history",e),l=r.CS.PRODUCTHISTORY,this.telemetrySent=!0}const e=new CustomEvent(Ku.e1.SeeMoreClick,{detail:{totalCards:s.length}});a.dispatchEvent(e)}else o>r.CS.PRODUCTHISTORY&&(o=r.CS.PRODUCTHISTORY);const c=[];for(let i=l;i<o;i++){const d=document.createElement("msft-product-card");c.push(d),d.priceCurrency=(0,ne.Jl)(s[i].entity.priceCurrency),d.price=s[i].entity.priceValue.split(".")[0],d.priceHundredthText=s[i].entity.priceValue.split(".")[1],d.description=s[i].title,d.href="#",d.isPWILOExpActive=!0,d.ariaSetSize=o.toString(),d.ariaPosInSet=(i+1).toString(),a.addEventListener(Ku.e1.SeeMoreClick,(e=>{e?.detail?.totalCards&&(d.ariaSetSize=e?.detail?.totalCards.toString())})),s[i].domain&&(d.retailer=this.utilities.getDomainNameAndCapitalize(s[i].domain),this.createProductImages(d,s[i])),this.flyoutData.common.isPane&&(d.style.backgroundColor="var(--fill-color)",d.style.borderRadius="8px"),this.addProdHistoryAnnotation(d,i),this.addDeleteButton(d,s[i],this.previousLink,e,i),this.manageProductLinkEvents(d,s[i]),a.appendChild(d),(i===l&&t&&n&&this.flyoutData.common.currentDevice===r.AS.Desktop&&d||this.lastFocusedIndex===i)&&(gn.SO.queueUpdate((()=>{d.focus()})),this.lastFocusedIndex=null),this.previousLink=d}this.addSavingsAnnotation(s,c,l,o),e.appendChild(a)}}async addSavingsAnnotation(e,t,i,n){const o=await this.sendSavingsRequest(e);let r=0;if(Array.isArray(o))for(let e=i;e<n;e++){const i=o[e];i&&"0"!==i&&!isNaN(parseInt(i,10))&&t[r]&&(t[r].savings=i),r++}}addDeleteButton(e,t,i,n,o){const r=(0,Y.Ux)("fluent-button");r.slot="delete",r.appearance="stealth",r.style.visibility="hidden",r.addEventListener("click",(i=>{(0,T.pq)(i)&&(this.lastFocusedIndex=this.utilities.setFocusAfterDeletion(n,o,"#phdWrapper","#tabHome",".btnSeeMore")),e.remove(),t.url.startsWith("http")?this.pageHandlerModule.DeletePwiloEntry(t.url):(this.pageHandlerModule.DeletePwiloEntry("https://"+t.url),this.pageHandlerModule.DeletePwiloEntry("http://"+t.url));const r=new CustomEvent(Ku.e1.PWILODeleted,{detail:{event:i,index:o}});this.stateManagementModule.dispatchEvent(r)})),e.addEventListener("mouseover",(()=>{this.setButtonVisibility(r,!0)})),e.addEventListener("mouseout",(()=>{this.setButtonVisibility(r,!1)})),e.addEventListener("focus",(()=>{this.setButtonVisibility(r,!0)})),e.addEventListener("keydown",(e=>{e.shiftKey?this.setButtonVisibility(r,!1):this.setButtonVisibility(r,!0)})),document.addEventListener("keydown",(t=>{if(t.shiftKey)if(i&&document.activeElement===e){const e=i.querySelector("fluent-button");e&&gn.SO.queueUpdate((()=>{e.focus()}))}else{const e=n.querySelector(".btnSeeMore");e&&document.activeElement===e&&gn.SO.queueUpdate((()=>{r.focus()}))}}));const a=(0,Y.Ux)("DIV",{style:"display: flex; place-self: center; font-size: 10px;"},this.flyoutData.strings.prodHDeleteItem);a.slot="start",a.classList.add("txtSmall"),r.addEventListener("blur",(()=>{this.setButtonVisibility(r,!1),r.removeChild(a)})),r.addEventListener("focus",(()=>{r.setAttribute("aria-label",this.flyoutData.strings.prodHDeleteItem),r.appendChild(a)})),r.title=this.flyoutData.strings.prodHDeleteItem;const s=(0,Y.Ux)("div");s.setAttribute("aria-hidden","true"),s.innerHTML=this.utilities.commonAssets.getCloseButton(),r.appendChild(s),e.appendChild(r)}setButtonVisibility(e,t){t?e.style.visibility="visible":(e.style.visibility="hidden",e.setAttribute("aria-label",""))}createAnnotation(e,t){if(!e.querySelector(".prodHBottomAnnotation")){const i=t.newTimestamp;if(i&&"No data found"!==i&&t.entity){const i=t.entity.latestPrice,n=t.entity.priceValue,o=t.entity.priceCurrency??"$",a=parseFloat(n.toString());let s=null;if(a&&!isNaN(a)&&i&&-1!==i&&(i>a?s=r.lp.PRICEINCREASE:i<a&&(s=r.lp.PRICEDROP)),s){const t=(0,Y.Ux)("msft-attribution");t.className="prodHBottomAnnotation";const n=(0,Y.Ux)("DIV");let l=!1;const c=!!this.utilities.isDarkMode();if(s===r.lp.PRICEDROP){let e,o=!1;if(void 0!==i&&void 0!==a&&a>0&&(e=(a-i)/a*100,o=!0),o){const i=this.utilities.toFixedSafe(e,0);t.textContent=(0,T.fZ)("prodHPriceDropRefresh",this.flyoutData.strings.prodHPriceDropRefresh,`${i}%`),t.className="prodHAnnotation",n.innerHTML=this.assets.getPriceDecreaseTrendIcon(c),l=!0,t.style.color=c?"#43E498":"#028948"}}else if(s===r.lp.PRICEINCREASE){let e,o=!1;if(void 0!==i&&void 0!==a&&i>0&&(e=(i-a)/i*100,o=!0),o){const i=this.utilities.toFixedSafe(e,0);t.textContent=(0,T.fZ)("prodHPriceIncreaseRefresh",this.flyoutData.strings.prodHPriceIncreaseRefresh,`${i}%`),t.className="prodHAnnotation",n.innerHTML=this.assets.getPriceIncreaseTrendIcon(c),l=!0,t.style.color=c?"#F9A1AC":"#C82B45"}}if(a){const t=(0,Y.Ux)("P");t.className="txtSmall prodHAnnotation",t.style.fontSize="12px",t.style.marginTop="4px",t.slot="previous-price";const n=this.utilities.formatPrice(a);t.textContent=(0,T.fZ)("prodHAnnotation",this.flyoutData.strings.prodHAnnotation,`${o}${n}`),t.style.textAlign="end",e.appendChild(t);const r=this.utilities.formatPrice(i);e.price=`${o}${r}`}l&&(n.slot="image",n.style.display="flex",t.appendChild(n)),t.slot="end",t.textContent&&(e.appendChild(t),e.style.height="115px",e.hasAnnotation=!0)}}}}createProductImages(e,t){const i=document.createElement("img");this.utilities.addFavIconSrc(i,e,t.domain),i.style.width="16px",i.style.height="16px",i.style.marginRight="calc(var(--design-unit) * 2px)";const n=(0,Y.Ux)("img"),o=this.utilities.createProductImage(64,64,n);t.entity.image&&""!==t.entity.image?this.utilities.setImageSrc(n,t.entity.image):(this.utilities.setImageSrc(n,this.flyoutData.common.resourcesEndpoint+"common/defaultProduct.svg"),n.style.maxWidth="unset",n.style.maxHeight="unset",n.style.width="64px",n.style.height="64px"),o.slot="image",o.style.minWidth="64px",e.appendChild(o)}manageProductLinkEvents(e,t){e.addEventListener("click",(e=>{e.target&&"delete"!==e.target.slot&&this.navigateToRetailer(t)})),e.addEventListener("mousedown",(e=>{1===e.button&&this.navigateToRetailer(t)}))}navigateToRetailer(e){const t=new W.Z(i.$S.NavigatedToAnotherRetailer,this.telemetryUtilities.setContentViewed(this.GetModuleName()),this.flyoutData.common.domain);this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_HISTORY_NAVIGATION),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_HISTORY_NAVIGATION,this.flyoutData.common.popupOrigination),this.logModule.LogInfoEvent(i.R.ButtonClick,"Navigation to another retailer from product history",t),this.pageHandlerModule.NavigateToUrl(e.url)}},WE=class{getStyles(){return"\n .sectionSeparator\n {\n display: none;\n }\n .dec-circ-mod {\n border-radius: 4px;\n justify-content: center;\n gap: 2px;\n display: flex;\n padding: 8px;\n align-items: center;\n }\n .dec-circ-mod:hover {\n background: rgba(0, 0, 0, 0.08);\n }\n\n #ps-section-separator\n {\n margin: unset;\n padding: 0 12px 0 12px;\n border: none;\n height: 1px;\n background: #F5F5F5;\n }\n #priceComparisonIllustrationSubdiv {\n display: grid;\n width: 70px;\n justify-items: center;\n }\n .spanCommissionValueSmall\n {\n background: #0076F8 !important;\n }\n .divCommissionValue {\n place-self: center;\n }\n #price-change-image {\n display: flex;\n position: relative;\n justify-content: center;\n height: 20px;\n gap: 2px;\n }\n @keyframes glow {\n 0% {\n box-shadow: 0 0 0 0px rgba(0, 0, 0, 0.7);\n width: 100%;\n height: 100%;\n display: inline;\n }\n 40% {\n display: block;\n margin: auto;\n box-shadow: 1px 1px 4px 2px lightyellow;\n width: 99%;\n height: 95%;\n }\n 100% {\n box-shadow: 0 0 0 0px rgba(0, 0, 0, 0.7);\n width: 100%;\n height: 100%;\n display: inline;\n }\n }\n .animation_ {\n animation-name: glow;\n animation-duration: 2s;\n animation-delay: 0s;\n animation-iteration-count: 1;\n }\n\n .fallback {\n background-color: #f0f0f0; /* Light background color for fallback */\n width: 100%;\n height: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n font-size: 26px;\n }\n .image-fb-container {\n width: 60px;\n height: 60px;\n border-radius: 4px;\n min-width: 60px;\n min-height: 60px;\n font-weight: 600;\n text-align: center;\n justify-content: center;\n align-items: center;\n overflow: hidden;\n }\n .letter-pink { background-color: #fde0ef; /* Light Pink */ }\n .text-dark-pink { color: #c2185b; /* Dark Pink */ }\n .letter-blue { background-color: #e0effd; /* Light Blue */ }\n .text-dark-blue { color: #1976d2; /* Dark Blue */ }\n .letter-green { background-color: #e0f2f1; /* Light Green */ }\n .text-dark-green { color: #00695c; /* Dark Green */ }\n .letter-yellow { background-color: #fffde7; /* Light Yellow */ }\n .text-dark-yellow { color: #f9a825; /* Dark Yellow */ }\n\n .hideDiv {\n display: none;\n transition: 0.5s;\n }\n .sticky #divProductSummaryInfoWrapper {\n align-items: center;\n position: fixed !important;\n top: 56px !important;\n left: 0px;\n padding: 12px 15px;\n width: calc(100% - 30px);\n z-index: 50;\n transition: top 0.1s ease;\n box-shadow: rgba(0, 0, 0, 0.12) 0px 0px 2px 0px, rgba(0, 0, 0, 0.14) 0px 1px 2px 0px;\n\n .divProductImageContainer{\n width: 36px !important;\n height: 36px !important;\n border-radius: 4px;\n min-width: 36px !important;\n min-height: 36px !important;\n }\n .imgProduct {\n max-width: 36px !important;\n max-height: 36px !important;\n }\n .divProductImageAlpha{\n width: 36px !important;\n height: 36px !important;\n }\n .productSummaryCardText {\n -webkit-line-clamp: 1;\n }\n .gcTooltipBody {\n top: 53px !important;\n }\n }\n #productSummaryParentContainer.stickyWrapped {\n min-height: 50px;\n }\n .stickyWrapped #divProductSummaryInfoWrapper {\n align-items: center;\n position: fixed !important;\n top: 56px !important;\n left: 0px;\n padding: 12px 15px 0 15px;\n width: calc(100% - 30px);\n z-index: 50;\n transition: top 0.1s ease;\n\n .divProductImageContainer{\n width: 36px !important;\n height: 36px !important;\n border-radius: 4px;\n min-width: 36px !important;\n min-height: 36px !important;\n }\n .imgProduct {\n max-width: 36px !important;\n max-height: 36px !important;\n }\n .divProductImageAlpha{\n width: 36px !important;\n height: 36px !important;\n }\n .productSummaryCardText {\n -webkit-line-clamp: 2;\n }\n .gcTooltipBody {\n top: 53px !important;\n }\n }\n #wishListMod {\n position: relative;\n }\n #wishListMod .gcTooltipBody {\n top: 40px !important;\n }\n .icon:hover {\n fill: #e0edff;\n }\n .aggregatedDiv {\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n flex-wrap: wrap;\n padding-top: 12px;\n background: white;\n gap: 10px;\n }\n .productSummaryParentContainer{\n padding: 12px 15px;\n background: #FFFFFF;\n }\n .bottomdeck_tile{\n flex: 1;\n flex-direction: column;\n background: #F5F5F5;\n height: 42px;\n align-items: center;\n border-radius: 4px;\n padding-top: 6px;\n }\n .bottomdeck_tile:hover{\n background: #EDEBE9;\n cursor: pointer;\n }\n .illustrationskel {\n display: grid;\n flex-direction: row;\n justify-content: center;\n flex-wrap: wrap;\n column-gap: 12px;\n width: 100%;\n background: transparent;\n }\n .illustrationText {\n display: flex;\n font-size: 10px;\n line-height: 14px;\n flex-direction: column;\n justify-content: center;\n flex-wrap: wrap;\n column-gap: 12px;\n padding-top: 0px;\n background: transparent;\n color: #000000;\n font-weight: 600;\n }\n .productSummaryCardText {\n font-size: 12px;\n line-height: 16px;\n color: #00000;\n text-align: left;\n font-weight: 600;\n margin-top: 0px;\n margin-bottom: 4px;\n max-width: 100%;\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n overflow: hidden;\n text-overflow: ellipsis;\n }\n .illustrationPercentageText {\n background-clip: text;\n -webkit-background-clip: text;\n }\n #hero-image-clickable:focus {\n outline-color: #898989;\n outline-width: 2px;\n outline-style: solid;\n }\n .ph-discoverPane {\n box-sizing: border-box;\n }\n .ph-discoverPane .fui-FluentProvider {\n padding: 0 !important;\n }\n .ph-discoverPane .fui-FluentProvider > div:first-child {\n box-shadow: unset !important;\n border-radius: 0;\n background-color: transparent;\n }\n @media (-ms-high-contrast: active) {\n #hero-image-clickable:focus {\n outline-color: ButtonText;\n }\n }"}getDarkModeStyles(){return"\n #ps-section-separator\n {\n background: rgba(0, 0, 0, 0.12) !important;\n }\n .productSummaryParentContainer{\n background: #242424;\n }\n .illustrationText {\n color: #FFF;\n }\n .dec-circ-mod {\n border-color: rgba(255, 255, 255, 0.28);\n }\n #product-tracking-annotation-image > div > svg > path {\n fill: #FFF;\n }\n #wishlistIcon > path {\n fill: #FFF !important;\n }\n .aggregatedDiv {\n background: #242424;\n }\n .bottomdeck_tile {\n background: #1E1E1E !important;\n }\n .bottomdeck_tile:hover{\n background: #2B2B2B !important;\n }\n .productSummaryCardText {\n color: #FFFFFF;\n }\n .gotItBtn:focus-visible {\n outline: 3px solid #FFFFFF;\n }\n .bottomdeck_tile{\n flex: 1;\n margin: 0 5px;\n flex-direction: column;\n background: rgba(58, 58, 58, 0.30) !important;\n height: 42px;\n align-items: center;\n border-radius: 4px;\n padding-top: 6px;\n }\n .bottomdeck_tile:hover{\n background: rgba(58, 58, 58, 0.70);\n }\n "}getCouponsAnnotationImage(){return eh.Z.getTrustedHTML`<svg width="21" height="20" viewBox="0 0 21 20" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M13.2372 2.53039C12.5538 1.84697 11.4458 1.84697 10.7624 2.53039L3.03014 10.2626C2.34672 10.946 2.34672 12.0541 3.03014 12.7375L3.8053 13.5127C4.21183 13.9192 4.79094 13.8495 5.1512 13.6524C5.32853 13.5554 5.53205 13.5 5.75 13.5C6.44036 13.5 7 14.0596 7 14.75C7 14.9679 6.94464 15.1715 6.84762 15.3488C6.65049 15.7091 6.58082 16.2882 6.98735 16.6947L7.76237 17.4697C8.44579 18.1531 9.55383 18.1531 10.2372 17.4697L17.9695 9.73749C18.6529 9.05407 18.6529 7.94604 17.9695 7.26262L17.1944 6.48752C16.7879 6.08106 16.2089 6.15065 15.8486 6.3477C15.6714 6.44468 15.4679 6.5 15.25 6.5C14.5596 6.5 14 5.94036 14 5.25C14 5.03212 14.0553 4.82865 14.1523 4.65136C14.3493 4.2911 14.4189 3.71208 14.0125 3.30561L13.2372 2.53039Z" fill="#2169EB"/>
</svg>
`}getTrackingBell(){return eh.Z.getTrustedHTML`<svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M9.99766 2C13.1466 2 15.7416 4.33488 15.9821 7.3554L15.9955 7.57762L16 7.80214L15.999 11.398L16.9244 13.6202C16.947 13.6743 16.9647 13.7302 16.9774 13.7871L16.9926 13.8733L17.0013 14.0046C17.0013 14.4526 16.7048 14.8387 16.2521 14.9677L16.1358 14.9945L16.0013 15.0046L12.4996 15.004L12.4946 15.1653C12.4095 16.469 11.3252 17.5 10 17.5C8.67453 17.5 7.58998 16.4685 7.50533 15.1644L7.49962 15.004L3.99891 15.0046C3.91096 15.0046 3.82358 14.993 3.73902 14.9702L3.61456 14.9277C3.20378 14.7567 2.96181 14.3392 3.01221 13.8757L3.0333 13.7483L3.07572 13.6202L3.99902 11.401L4.0001 7.79281L4.0044 7.56824C4.12702 4.45115 6.77104 2 9.99766 2ZM11.4996 15.004H8.49962L8.50697 15.1454C8.57552 15.8581 9.14275 16.425 9.85556 16.4931L10 16.5C10.7797 16.5 11.4205 15.9051 11.4931 15.1445L11.4996 15.004ZM9.99766 3C7.37511 3 5.22717 4.92372 5.01715 7.38498L5.00393 7.59723L5.00002 7.80214V11.5L4.96161 11.6922L3.9989 14.0046L15.9566 14.0066L16.0019 14.0045L15.0384 11.6922L15 11.5L15.0001 7.81241L14.996 7.60831C14.8909 5.0349 12.6947 3 9.99766 3Z" fill="#242424"/>
</svg>`}getWishlistIcon(){return eh.Z.getTrustedHTML`<svg id="wishlistIcon" width="20" height="20" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<path fill-rule="evenodd" clip-rule="evenodd" d="M1.08581 5.18294C0.728451 3.84928 1.51991 2.47844 2.85357 2.12108L6.71728 1.08581C8.05094 0.728451 9.42178 1.51991 9.77914 2.85357L10.3543 5H9.319L8.81321 3.11239C8.5988 2.31219 7.77629 1.83732 6.9761 2.05173L3.11239 3.08701C2.31219 3.30142 1.83732 4.12393 2.05173 4.92413L3.08701 8.78783C3.30142 9.58803 4.12393 10.0629 4.92413 9.84849L5 9.82816V10.8563C3.72612 11.0983 2.46211 10.3194 2.12108 9.04665L1.08581 5.18294ZM8 6C6.89543 6 6 6.89543 6 8V13C6 14.1046 6.89543 15 8 15H13C14.1046 15 15 14.1046 15 13V8C15 6.89543 14.1046 6 13 6H8ZM7 8C7 7.44772 7.44772 7 8 7H13C13.5523 7 14 7.44772 14 8V13C14 13.5523 13.5523 14 13 14H8C7.44772 14 7 13.5523 7 13V8ZM11 8.5C11 8.22386 10.7761 8 10.5 8C10.2239 8 10 8.22386 10 8.5V10H8.5C8.22386 10 8 10.2239 8 10.5C8 10.7761 8.22386 11 8.5 11H10V12.5C10 12.7761 10.2239 13 10.5 13C10.7761 13 11 12.7761 11 12.5V11H12.5C12.7761 11 13 10.7761 13 10.5C13 10.2239 12.7761 10 12.5 10H11V8.5Z" fill="#242424" style="fill:#242424;fill:color(display-p3 0.1412 0.1412 0.1412);fill-opacity:1;"/>
</svg>`}getWishlistSaved(){return eh.Z.getTrustedHTML`<svg id="wishlistIconSaved" width="20" height="20" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M3.7796 13.9187C3.44735 14.1406 3.00195 13.9024 3.00195 13.5029V4.01174C3.00195 2.90856 3.8952 2.01372 4.99837 2.01174L10.9984 2.00098C12.1029 1.99901 13 2.89284 13.002 3.9974V13.5029C13.002 13.9024 12.5566 14.1406 12.2243 13.9187L8.00195 11.0995L3.7796 13.9187Z" fill="#2169EB" style="fill:#2169EB;fill-opacity:1;"/>
</svg>
`}getTrackedBell(){return eh.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 16 16" fill="none">
<path d="M8.00001 2C5.51473 2 3.50001 4.01472 3.50001 6.5V8.9014L2.5357 11.3145C2.47415 11.4685 2.49299 11.643 2.58601 11.7804C2.67904 11.9177 2.83412 12 3 12H13C13.1659 12 13.321 11.9177 13.414 11.7804C13.507 11.643 13.5259 11.4685 13.4643 11.3145L12.5 8.9014V6.5C12.5 4.01472 10.4853 2 8.00001 2ZM7.99998 14.5C7.06806 14.5 6.28501 13.8626 6.06299 13H9.93697C9.71495 13.8626 8.9319 14.5 7.99998 14.5Z" fill="#2169EB" style="fill:#2169EB;fill:color(display-p3 0.1294 0.4118 0.9216);fill-opacity:1;"/>
<path d="M1 2.5L2.5 3.50011" stroke="#2169EB" style="stroke:#2169EB;stroke:color(display-p3 0.1294 0.4118 0.9216);stroke-opacity:1;" stroke-linecap="round"/>
<path d="M15 2.5L13.5 3.50011" stroke="#2169EB" style="stroke:#2169EB;stroke:color(display-p3 0.1294 0.4118 0.9216);stroke-opacity:1;" stroke-linecap="round"/>
<path d="M0.5 6.5H2" stroke="#2169EB" style="stroke:#2169EB;stroke:color(display-p3 0.1294 0.4118 0.9216);stroke-opacity:1;" stroke-linecap="round"/>
<path d="M15.5 6.5H14" stroke="#2169EB" style="stroke:#2169EB;stroke-opacity:1;" stroke-linecap="round"/>
</svg>
`}getChevron(){return eh.Z.getTrustedHTML`<svg width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
<g id="Chevron">
<path id="Shape" d="M2.14645 4.64645C2.34171 4.45118 2.65829 4.45118 2.85355 4.64645L6 7.79289L9.14645 4.64645C9.34171 4.45118 9.65829 4.45118 9.85355 4.64645C10.0488 4.84171 10.0488 5.15829 9.85355 5.35355L6.35355 8.85355C6.15829 9.04882 5.84171 9.04882 5.64645 8.85355L2.14645 5.35355C1.95118 5.15829 1.95118 4.84171 2.14645 4.64645Z" fill="#2169EB" style="fill:#2169EB;fill:color(display-p3 0.1294 0.4118 0.9216);fill-opacity:1;"/>
</g>
</svg>
`}getCashbackAnnotationImage(){return eh.Z.getTrustedHTML`<svg width="21" height="20" viewBox="0 0 21 20" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M5.49384 5.00001C4.11314 4.99662 2.99662 6.11314 3.00001 7.49384L3.01429 13.3063C3.01768 14.687 4.13971 15.809 5.5204 15.8124L13.7552 15.8326C14.4119 15.8342 15.0417 15.5773 15.5083 15.1174L18.5024 12.1665C19.4913 11.1919 19.4898 9.59338 18.4991 8.6109L15.614 5.74972C15.1447 5.28425 14.5113 5.02216 13.8519 5.02054L5.49384 5.00001Z" fill="#2169EB"/>
</svg>
`}getProductTrackingAnnotation(e){return e?eh.Z.getTrustedHTML`<svg width="36" height="36" viewBox="0 0 36 36" fill="none" xmlns="http://www.w3.org/2000/svg">
<rect class="icon" width="36" height="36" rx="18" fill="#c1d7ec"/>
<path d="M17.9977 10C21.1466 10 23.7416 12.3349 23.9821 15.3554L23.9955 15.5776L24 15.8021L23.999 19.398L24.9244 21.6202C24.947 21.6743 24.9647 21.7302 24.9774 21.7871L24.9926 21.8733L25.0013 22.0046C25.0013 22.4526 24.7048 22.8387 24.2521 22.9677L24.1358 22.9945L24.0013 23.0046L20.4996 23.004L20.4946 23.1653C20.4095 24.469 19.3252 25.5 18 25.5C16.6745 25.5 15.59 24.4685 15.5053 23.1644L15.4996 23.004L11.9989 23.0046C11.911 23.0046 11.8236 22.993 11.739 22.9702L11.6146 22.9277C11.2038 22.7567 10.9618 22.3392 11.0122 21.8757L11.0333 21.7483L11.0757 21.6202L11.999 19.401L12.0001 15.7928L12.0044 15.5682C12.127 12.4511 14.771 10 17.9977 10ZM19.4996 23.004H16.4996L16.507 23.1454C16.5755 23.8581 17.1428 24.425 17.8556 24.4931L18 24.5C18.7797 24.5 19.4205 23.9051 19.4931 23.1445L19.4996 23.004ZM17.9977 11C15.3751 11 13.2272 12.9237 13.0172 15.385L13.0039 15.5972L13 15.8021V19.5L12.9616 19.6922L11.9989 22.0046L23.9566 22.0066L24.0019 22.0045L23.0384 19.6922L23 19.5L23.0001 15.8124L22.996 15.6083C22.8909 13.0349 20.6947 11 17.9977 11Z" fill="#242424"/>
</svg>`:eh.Z.getTrustedHTML`<svg width="36" height="36" viewBox="0 0 36 36" fill="none" xmlns="http://www.w3.org/2000/svg">
<rect class="icon" width="36" height="36" rx="18" fill="#F5F5F5"/>
<path d="M17.9977 10C21.1466 10 23.7416 12.3349 23.9821 15.3554L23.9955 15.5776L24 15.8021L23.999 19.398L24.9244 21.6202C24.947 21.6743 24.9647 21.7302 24.9774 21.7871L24.9926 21.8733L25.0013 22.0046C25.0013 22.4526 24.7048 22.8387 24.2521 22.9677L24.1358 22.9945L24.0013 23.0046L20.4996 23.004L20.4946 23.1653C20.4095 24.469 19.3252 25.5 18 25.5C16.6745 25.5 15.59 24.4685 15.5053 23.1644L15.4996 23.004L11.9989 23.0046C11.911 23.0046 11.8236 22.993 11.739 22.9702L11.6146 22.9277C11.2038 22.7567 10.9618 22.3392 11.0122 21.8757L11.0333 21.7483L11.0757 21.6202L11.999 19.401L12.0001 15.7928L12.0044 15.5682C12.127 12.4511 14.771 10 17.9977 10ZM19.4996 23.004H16.4996L16.507 23.1454C16.5755 23.8581 17.1428 24.425 17.8556 24.4931L18 24.5C18.7797 24.5 19.4205 23.9051 19.4931 23.1445L19.4996 23.004ZM17.9977 11C15.3751 11 13.2272 12.9237 13.0172 15.385L13.0039 15.5972L13 15.8021V19.5L12.9616 19.6922L11.9989 22.0046L23.9566 22.0066L24.0019 22.0045L23.0384 19.6922L23 19.5L23.0001 15.8124L22.996 15.6083C22.8909 13.0349 20.6947 11 17.9977 11Z" fill="#242424"/>
</svg>`}getSafariStyles(){return"\n "}getPriceIncreaseTrendIcon(e){return e?eh.Z.getTrustedHTML`<svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M2 10C2 5.58172 5.58172 2 10 2C14.4183 2 18 5.58172 18 10C18 14.4183 14.4183 18 10 18C5.58172 18 2 14.4183 2 10ZM6.64645 9.14645C6.45118 9.34171 6.45118 9.65829 6.64645 9.85355C6.84171 10.0488 7.15829 10.0488 7.35355 9.85355L9.5 7.70711V13.5C9.5 13.7761 9.72386 14 10 14C10.2761 14 10.5 13.7761 10.5 13.5V7.70711L12.6464 9.85355C12.8417 10.0488 13.1583 10.0488 13.3536 9.85355C13.5488 9.65829 13.5488 9.34171 13.3536 9.14645L10.3536 6.14645C10.1583 5.95118 9.84171 5.95118 9.64645 6.14645L6.64645 9.14645Z" fill="#D63600"/>
</svg>`:eh.Z.getTrustedHTML`<svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M2 10C2 5.58172 5.58172 2 10 2C14.4183 2 18 5.58172 18 10C18 14.4183 14.4183 18 10 18C5.58172 18 2 14.4183 2 10ZM6.64645 9.14645C6.45118 9.34171 6.45118 9.65829 6.64645 9.85355C6.84171 10.0488 7.15829 10.0488 7.35355 9.85355L9.5 7.70711V13.5C9.5 13.7761 9.72386 14 10 14C10.2761 14 10.5 13.7761 10.5 13.5V7.70711L12.6464 9.85355C12.8417 10.0488 13.1583 10.0488 13.3536 9.85355C13.5488 9.65829 13.5488 9.34171 13.3536 9.14645L10.3536 6.14645C10.1583 5.95118 9.84171 5.95118 9.64645 6.14645L6.64645 9.14645Z" fill="#D63600"/>
</svg>
`}getPriceDecreaseTrendIcon(e){return eh.Z.getTrustedHTML`<svg width="21" height="20" viewBox="0 0 21 20" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M2.5 10C2.5 14.4183 6.08172 18 10.5 18C14.9183 18 18.5 14.4183 18.5 10C18.5 5.58172 14.9183 2 10.5 2C6.08172 2 2.5 5.58172 2.5 10ZM7.14645 10.8536C6.95118 10.6583 6.95118 10.3417 7.14645 10.1464C7.34171 9.95118 7.65829 9.95118 7.85355 10.1464L10 12.2929V6.5C10 6.22386 10.2239 6 10.5 6C10.7761 6 11 6.22386 11 6.5V12.2929L13.1464 10.1464C13.3417 9.95118 13.6583 9.95118 13.8536 10.1464C14.0488 10.3417 14.0488 10.6583 13.8536 10.8536L10.8536 13.8536C10.6583 14.0488 10.3417 14.0488 10.1464 13.8536L7.14645 10.8536Z" fill="#138757"/>
</svg>`}getPriceNoChangeTrendIcon(){return eh.Z.getTrustedHTML`<svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M10 2C14.4183 2 18 5.58172 18 10C18 14.4183 14.4183 18 10 18C5.58172 18 2 14.4183 2 10C2 5.58172 5.58172 2 10 2ZM10.8536 6.64645C10.6583 6.45118 10.3417 6.45118 10.1464 6.64645C9.95118 6.84171 9.95118 7.15829 10.1464 7.35355L12.2929 9.5H6.5C6.22386 9.5 6 9.72386 6 10C6 10.2761 6.22386 10.5 6.5 10.5H12.2929L10.1464 12.6464C9.95118 12.8417 9.95118 13.1583 10.1464 13.3536C10.3417 13.5488 10.6583 13.5488 10.8536 13.3536L13.8536 10.3536C14.0488 10.1583 14.0488 9.84171 13.8536 9.64645L10.8536 6.64645Z" fill="#2169EB"/>
</svg>
`}};const KE="wishlist-module-data",qE="wishlist-trigger";class YE{static setCollectionContainerMetadata(e,t){e.classList.add("isvctrl"),e.setAttribute("data-svcptid","WishlistModule"),e.setAttribute("data-sfmc","ESWLFL"),e.setAttribute("data-svitminfp",JSON.stringify({SourceAttr:"data-m",ItemTagPath:YE.ItemTagPath})),e.setAttribute("data-svptnk","Shopping"),e.setAttribute("data-svptnerinfo",JSON.stringify({Title:"Shopping Wishlist",ItemType:"generic",APIItemType:"product",CollectionTagPath:YE.CollectionTagPath})),e.setAttribute("data-svloc",KE),e.setAttribute("data-svattr","data-m"),e.setAttribute("data-svmdcmp","WishlistModuleSaveButton"),e.setAttribute("data-persbtncls",qE)}static async getCollectionItemData(e,n,o){try{if(!o)throw new Error("base64ProductImage was not given");if(!this.getMIMEType(o))throw e.LogInfoEvent(i.R.EdgeFlyoutStatus,"Could not parse image MIME type - "+o.substring(0,4),new t.Z(i.xu.CollectionsPackageEntityParsingError)),new Error("Could not parse image MIME type for base64ProductImage");const r=YE.scaleBase64Image(o,e),a=YE.GenerateContentIdForEntity(n),[s,l]=await Promise.all([r,a]);if(!s)throw new Error("image data could not be parsed");if(!l)throw new Error("contentId could not be produced for entity");return JSON.stringify({ContentId:l,Title:n.title,ClickThroughUrl:n.url,FriendlyDomainName:n.domain,ItemTagPath:YE.ItemTagPath,ThumbnailInfo:[{Thumbnail:s.base64,Width:s.width.toString(),Height:s.height.toString()}],CustomData:JSON.stringify({MediaUrl:n.image_url,PageUrl:n.url,GlobalOfferId:n.globalOfferId})})}catch(n){return void e.LogInfoEvent(i.R.EdgeFlyoutStatus,"Error creating collection item data - "+n,new t.Z(i.xu.CollectionsPackageEntityParsingError))}}static setCollectionItemDataAttribute(e,t){e.setAttribute("data-m",t)}static async GenerateContentIdForEntity(e){return e.productKey?await YE.hashText(e.productKey):e.url?await YE.hashText(e.url):Promise.resolve(void 0)}static getShoppingWishlistCollectionUrl(e){if(!e)return;const t=window?.SvCtrlV2?.localCollectionsMap;if(t)for(const[i,n]of Object.entries(t))if(n===e)return`${YE.CollectionHomepageUrl}&collId=${i}`}static async downloadCollectionPackage(e,n,o,r,a){if(YE.CollectionsDataRecieved?a():YE.collectionsDataRecievedHandlers.push(a),!YE.triedToDownloadPackage){YE.triedToDownloadPackage=!0;try{const e=await fetch(YE.collectionPackageUrl,{credentials:"include"}),t=await e.text(),i=document.createElement("DIV");i.innerHTML=eh.Z.getTrustedHTML(YE.createTemplateStringsArray(t)),await YE.inlineStyles(i);const n=document.createElement("DIV"),o=i.querySelectorAll("script");for(const e of o){const t=document.createElement("SCRIPT"),i=YE.createTemplateStringsArray(e.innerHTML);t.textContent=eh.Z.getTrustedScript(i),n.appendChild(t),e.remove()}document.body.appendChild(i),document.body.appendChild(n),YE.waitForCollectionsGet(3e3,YE.handleCollectionsGet,r)}catch(e){o.LogInfoEvent(i.R.EdgeFlyoutStatus,"Error when injecting collections package - "+e.toString(),new t.Z(i.xu.CollectionsPackageInjectionError)),r(e.toString())}}}static collectionOperationIsSuccessful(e){return!(!e||e.length<=1||!e[1].isSuccess&&!e[1].targetCollectionOperationStatus?.isSuccess)}static getMIMEType(e){switch(e?.substring(0,4)){case"iVBO":return"image/png";case"R0lG":return"image/gif";case"/9j/":return"image/jpeg";case"UklG":return"image/webp";default:return}}static getScaledDimensions(e,t,i){if(!e||!t||!i)return{height:0,width:0};const n=Math.min(1,(i/(t*e))**.5);return{height:Math.floor(t*n),width:Math.floor(e*n)}}static isFeatureSupported(e){return ze.Z.IsBuildVersionSupported("117.0.2004.0")&&!!e.common.extractedEntity&&!!e.common.extractedEntity.title&&!!e.common.extractedEntity.url&&(!!e.common.base64ProductImage||!!e.common.extractedEntity.entity?.image)}static createTemplateStringsArray(e){const t=[e];return t.raw=t,Object.freeze(t)}static async scaleBase64Image(e,n){return new Promise(((o,r)=>{const a=YE.getMIMEType(e);void 0===a&&(n.LogInfoEvent(i.R.EdgeFlyoutStatus,"Could not parse image MIME type - "+e?.substring(12),new t.Z(i.xu.CollectionsPackageEntityParsingError)),o(void 0));const s=`data:${a};base64,${e}`,l=new Image;l.onload=()=>{const e=document.createElement("CANVAS"),t=e.getContext("2d"),i=YE.getScaledDimensions(l.width,l.height,202500);e.height=i.height,e.width=i.width,t.drawImage(l,0,0,i.width,i.height);const n=e.toDataURL("image/jpeg",.95);o({base64:n,width:e.width,height:e.height})},l.onerror=r,l.src=s}))}static async hashText(e){const t=(new TextEncoder).encode(e),i=await crypto.subtle.digest("SHA-256",t),n=Array.from(new Uint8Array(i)).map((e=>e.toString(16).padStart(2,"0"))).join("");return n}static get collectionPackageUrl(){let e="https://www.bing.com/images/svctrlpack?mmasync=1&svext=1&ptn=shopping";return window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches&&(e+="&darkschemeovr=1"),e}static async inlineStyles(e){const t=e.querySelectorAll('link[rel="stylesheet"]'),i=[];for(const e of t){const t=e.getAttribute("href");t&&i.push(YE.downloadStyles(t)),e.remove()}let n="";for(const e of i)n=n+" "+await e;const o=document.createElement("STYLE");return o.setAttribute("type","text/css"),o.innerHTML=eh.Z.getTrustedHTML(YE.createTemplateStringsArray(n)),e.appendChild(o),e}static async downloadStyles(e){const t=await fetch(e);return await t.text()}}(0,s.Z)(YE,"CollectionsDataRecieved",!1),(0,s.Z)(YE,"CollectionHomepageUrl","https://www.bing.com/saves?FORM=ESWLPL"),(0,s.Z)(YE,"triedToDownloadPackage",!1),(0,s.Z)(YE,"CollectionTagPath","/Shopping"),(0,s.Z)(YE,"ItemTagPath","/shopping/edge/v1/product"),(0,s.Z)(YE,"collectionsDataRecievedHandlers",[]),(0,s.Z)(YE,"waitForCollectionsGet",((e,t,i)=>{let n=!1;const o=()=>{n=!0};let r=!1;window.sj_evt&&(r=!0,window.sj_evt?.bind("onSaveGet",o,!0));let a=!1;const s=Date.now(),l=setInterval((()=>{if(!a)return!r&&window.sj_evt&&(r=!0,window.sj_evt?.bind("onSaveGet",o,!0)),n?(clearInterval(l),a=!0,void t()):Date.now()-s>=e?(clearInterval(l),a=!0,void i("Failed to get collections within timeout. eventBound:"+r)):void 0}),100)})),(0,s.Z)(YE,"handleCollectionsGet",(()=>{for(YE.CollectionsDataRecieved=!0;YE.collectionsDataRecievedHandlers.length>0;){const e=YE.collectionsDataRecievedHandlers.pop();void 0!==e&&e()}}));var XE=class extends Qu{constructor(n,o,a){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"productSummaryCardData",void 0),(0,s.Z)(this,"productTrackingViewUtilities",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"refreshCount",0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"autoOpenControllerUtilities",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"footerUtilities",void 0),(0,s.Z)(this,"tooltipUtilities",void 0),(0,s.Z)(this,"telemetryHandler",void 0),(0,s.Z)(this,"discoverTelemetryHandler",void 0),(0,s.Z)(this,"dataValidationUtilities",void 0),(0,s.Z)(this,"todayString",void 0),(0,s.Z)(this,"wasPriceHistorySectionExpanded",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"buyingOptionsExp",Boolean(e.R.getServiceExperimentValue(f.H.buyingOptions))),(0,s.Z)(this,"buyingOptionsClientExp",Boolean(e.R.getServiceExperimentValue(f.H.buyingOptionsExperiment))),(0,s.Z)(this,"sectionId","divProductSummarySection"),(0,s.Z)(this,"productSummaryCardTitle",void 0),(0,s.Z)(this,"summaryUtilities",void 0),(0,s.Z)(this,"productSummaryHeaderOffset",e.R.isExperimentActive(f.H.productSummaryCardEnabledSticky)?100:0),(0,s.Z)(this,"isProductTracked",void 0),(0,s.Z)(this,"tileStatusLog",new t.Z(i.xu.ProductSummaryTileStatus)),this.logModule=a.logModule,this.stateManagement=n,this.pageHandlerModule=a.pageHandlerModule,this.flyoutData=o,this.todayString=this.flyoutData.strings.phToday,this.utilities=a.viewModulesUtilities,this.storageHandler=a.storageHandler,this.footerUtilities=a.footerUtilities,this.tooltipUtilities=a.tooltipUtilities,this.telemetryHandler=a.telemetryHandler,this.discoverTelemetryHandler=a.discoverTelemetryHandler,this.dataValidationUtilities=a.dataValidationUtilities,this.wasPriceHistorySectionExpanded=!1,this.autoOpenControllerUtilities=a.autoOpenControllerUtilities,this.assets=new WE,this.telemetryUtilities=a.telemetryHandler,this.productSummaryCardData=this.flyoutData.dataStoreModule.ProductSummaryCardData,this.summaryUtilities=new class{constructor(e,n,o){(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"collectionItemDataElement",void 0),(0,s.Z)(this,"saveButton",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"psAssets",void 0),(0,s.Z)(this,"handleCollectionPackageDownloadError",(e=>{this.saveButton.style.display="none"})),(0,s.Z)(this,"handleSaveInProgress",(()=>{const e=document.getElementById("wishListMod");if(e){e.setAttribute("disabled","true"),e.style.pointerEvents="none";const t=e.querySelector("#wishlistIcon > path");t&&(t.style.opacity="0.5")}})),(0,s.Z)(this,"handleSave",(e=>{if(!YE.collectionOperationIsSuccessful(e))return this.saveButton.setAttribute("disabled","false"),void this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Error saving collection item",new t.Z(i.xu.ProductSummaryCardCollectionsPackageAddError));this.updateSaveButtonInnerText();const n=new W.Z(i.$S.ProductSummarySaveWishlistButton,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"Item saved to wishlist",n),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_SUMMARY_CARD_SAVE_WL,this.flyoutData.common.popupOrigination)})),(0,s.Z)(this,"handleUnsave",(e=>{if(!YE.collectionOperationIsSuccessful(e))return this.saveButton.setAttribute("disabled","false"),void this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Error deleting collection item on Summary Card",new t.Z(i.xu.ProductSummaryCardCollectionsPackageDeleteError));this.updateSaveButtonInnerText();const n=new W.Z(i.$S.ProductSummaryUnsaveWishlistButton,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"Item removed from wishlist on Summary Card",n),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_SUMMARY_CARD_UNSAVE_WL,this.flyoutData.common.popupOrigination)})),(0,s.Z)(this,"handleCollectionsRetrieved",(()=>{window.sj_evt?.bind("onSaveAdd",this.handleSave),window.sj_evt?.bind("onSaveDel",this.handleUnsave),window.sj_evt?.bind("onSaveInProgress",this.handleSaveInProgress),this.updateSaveButtonInnerText()})),this.stateManagement=e,this.flyoutData=n,this.utilities=o.viewModulesUtilities,this.logModule=o.logModule,this.pageHandlerModule=o.pageHandlerModule,this.telemetryUtilities=o.telemetryHandler,this.psAssets=new WE}GetModuleName(){return r.ModuleNames.PRODUCTSUMMARYCARD}ShouldRenderWishlist(){const e=this.flyoutData.dataStoreModule.PriceComparisonData,t=e?.segment?.toLowerCase(),i=t===r.VG.AUTOS||t===r.VG.EMPTYAUTOSSEGMENT||!!this.flyoutData.dataStoreModule.AutosData?.isDetectedAutosDomain||!!this.flyoutData.dataStoreModule.AutosData?.isAutosSupportedDomain,n=YE.isFeatureSupported(this.flyoutData)&&!i;return Promise.resolve(n)}initDOMElements(e,t){this.saveButton=document.createElement("div"),this.saveButton.id="product-tracking-annotation-image",this.saveButton.style.width="20px",this.saveButton.style.height="20px",this.saveButton.style.alignSelf="center",this.saveButton.slot="image",this.saveButton.setAttribute("disabled","true");const i=(0,Y.Ux)("div");i.slot="hover-anchor",i.innerHTML=this.psAssets.getWishlistIcon(),this.saveButton.appendChild(i);const n=e.title;this.saveButton.ariaLabel=(0,T.fZ)("shoppingWishlistSaveButtonAltText",this.flyoutData.strings.wishlistSaveAltText,n),this.saveButton.classList.add(qE),this.saveButton.style.fontWeight="600",this.collectionItemDataElement=document.createElement("DIV"),this.collectionItemDataElement.id=KE,this.collectionItemDataElement.appendChild(this.saveButton),YE.setCollectionContainerMetadata(t,this.flyoutData.strings.wishlistCollectionTitle),t.appendChild(this.collectionItemDataElement)}async addCollectionDataToDOMElements(e,t){const i=await YE.getCollectionItemData(this.logModule,e,t);i?(YE.setCollectionItemDataAttribute(this.collectionItemDataElement,i),setTimeout((()=>{YE.downloadCollectionPackage(this.utilities,this.flyoutData.common.shopping,this.logModule,this.handleCollectionPackageDownloadError,this.handleCollectionsRetrieved)}),0)):this.hideWishlistButton()}hideWishlistButton(){const e=this.saveButton?.parentElement;e&&(e.style.display="none")}updateSaveButtonInnerText(){const e=window.SvCtrlV2?.localSavedItemsMap;e&&this.flyoutData.common.extractedEntity&&YE.GenerateContentIdForEntity(this.flyoutData.common.extractedEntity).then((t=>{const i=this.flyoutData.common.extractedEntity?.title;if(!t||!i)return;const n=document.getElementById("wishListMod");if(n){const o=n.querySelector("#gcTooltipTextSub"),r=n.querySelector("#product-tracking-annotation-image");if(r){const a=r.querySelector("div");e[t]?(n.setAttribute("disabled","true"),a.innerHTML=this.psAssets.getWishlistSaved(),this.saveButton.ariaLabel=(0,T.fZ)("shoppingWishlistUnsaveButtonAltText",this.flyoutData.strings.wishlistUnsaveAltText,i),o&&(o.textContent=this.flyoutData.strings.wishlistUnsave)):(n.setAttribute("disabled","false"),a.innerHTML=this.psAssets.getWishlistIcon(),this.saveButton.ariaLabel=(0,T.fZ)("shoppingWishlistSaveButtonAltText",this.flyoutData.strings.wishlistSaveAltText,i),o&&(o.textContent=this.flyoutData.strings.commonSaveSimple))}n.style.pointerEvents="unset"}}))}createToolTipV3(e){const t=(0,Y.Ux)("p",{style:`\n margin: 0;\n font-weight: 400;\n font-size: 12px;\n line-height: 16px;\n display: flex;\n align-items: center;\n color: ${this.utilities.isDarkMode()?"#666666":"#ffffff"};\n `},"");t.id="gcTooltipTextSub",t.className="gcTooltipText";const i=(0,Y.Ux)("div",{style:`\n position: absolute;\n top: 52px;\n right: 0px;\n width: fit-content;\n border: 1px solid rgba(0, 0, 0, 0.08);\n box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.08);\n border-radius: 8px;\n padding: 5px 12px 7px 12px;\n visibility: hidden;\n z-index: 5;\n background-color: ${this.utilities.isDarkMode()?"#ffffff":"#424242"};\n `});i.className="gcTooltipBody",i.id="gcTooltipTextId",i.setAttribute("aria-modal","true"),i.setAttribute("role","dialog"),i.setAttribute("aria-label","Wao");const n=t=>{i.style.visibility="hidden",e.setAttribute("aria-expanded","false"),document.removeEventListener("mouseover",n)};e.addEventListener("mouseover",(t=>{t.stopPropagation(),"visible"!==i.style.visibility&&(()=>{const t="visible"===i.style.visibility?"hidden":"visible";i.style.visibility=t,e.setAttribute("aria-expanded",`${"visible"===t}`),document.addEventListener("mouseover",n)})()})),i.appendChild(t),e.appendChild(i)}}(n,o,a),this.productTrackingViewUtilities=new Ju(a,this.flyoutData,n),this.isProductTracked=!1}GetModuleName(){return r.ModuleNames.PRODUCTSUMMARYCARD}CalculateRanking(){return r.zz.InformPage}ShouldRenderModule(){if(this.flyoutData.common.extractedEntity&&this.flyoutData.common.extractedEntity.title){const e=(0,fg.U)(this.flyoutData.dataStoreModule.ApiData?.retailerData,this.flyoutData.common.lastCommittedURL,this.flyoutData.common.extractedEntity)==i.GV.ProductPage;return Promise.resolve(e)}return Promise.resolve(!1)}async renderModule(){const{common:e,dataStoreModule:t,strings:i}=this.flyoutData,n=t.PriceHistoryData,o=r.SV.LIST;if(n&&this.dataValidationUtilities.validatePriceWithEntityExtractionResults(e.extractedEntity,n.CurrentPrice?.toString(),this.GetModuleName()),this.utilities.applyStyles(e.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),(0,dt.tB)(this.flyoutData)){const t=new ly;this.utilities.applyStyles(e.shopping,t.getStyles()),this.utilities.applyStyles(e.shopping,this.assets.getSafariStyles())}const a=document.createElement("msft-edge-shopping-section");a.id=this.sectionId,a.accordion=!1,a.isBlock=!1,a.hasPadding=!0,a.hideTitle=!0,a.expanded=!1,a.titleText=i.productSummaryCardSectionTitle;const s=(0,Y.Ux)("DIV");s.id="productSummaryParentContainer",s.classList.add("productSummaryParentContainer"),this.populateModule(n,s),a.appendChild(s);const l=this.pageHandlerModule,c=(0,dt.tB)(this.flyoutData);if(a.addEventListener("click",(function(){if(a){const e=a.shadowRoot;if(e){const t=e.querySelector("fluent-accordion-item");if(t){if(c){const e=t.shadowRoot?.querySelector(".region");e&&e.classList.add("safari-region")}t.classList.contains("expanded")||(l.RecordAsUserAction(K.bS.VIEW_PRODUCT_SUMMARY_CARD),l.RecordAsUserEngagement(q.FV.VIEW_PRODUCT_SUMMARY_CARD,this.flyoutData.common.popupOrigination))}}}})),a.children&&a.children.length>0){const e=this.CreateModule(a,r.H7.PRODUCTSUMMARYCARD,r.ModuleNames.PRODUCTSUMMARYCARD,r.$k.CONTEXTUAL,o);return Promise.resolve(e)}return Promise.resolve(null)}populateMainHeader(){const e=this.flyoutData.common.shopping.querySelector(`#${this.sectionId}`);e&&(e.style.marginTop="0px",e.style.textAlign="start",e.style.marginLeft="auto",e.style.width="100%",e.style.boxShadow="0px 0px 2px 0px rgba(0, 0, 0, 0.12), 0px 1px 2px 0px rgba(0, 0, 0, 0.14)",e.style.borderTop="1px solid #D9D9D9",e.slot="header-content",this.productSummaryCardTitle&&(this.productSummaryCardTitle.style.display="block"))}PostProcessing(e,n,o){if(0===n){const e=new t.Z(i.xu.FlyoutProductSummaryCardRightlyPlaced);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Product Summary Card - Placed in POLE position",e)}else{const e=this.stateManagement.getState(Ku.IY.topModuleName),n=new t.Z(i.xu.ErrorWrongAutoTrigger);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,`Product Summary - Wrong module in pole position ${e}`,n)}this.flyoutData.common.isStorybook||x.ZP.ObserveUntil((()=>this.contextualPaneIsReady()),(()=>this.startStickyHeaderObserver(o)))}contextualPaneIsReady(){return void 0!==document.querySelector("#panelContextual")}startStickyHeaderObserver(e){const t=document.getElementById("contextualShopping"),i=t?.offsetHeight,n=document.getElementById("aggregatedDivWrapper"),o=function(e,t){let i;return function(...t){const n=this;clearTimeout(i),i=setTimeout((()=>e.apply(n,t)),200)}}((e=>{!1===e[0].isIntersecting?(t?.classList.add("sticky"),n?.classList.add("hideDiv")):(t?.classList.remove("sticky"),n?.classList.remove("hideDiv"))}));let r=.5;i&&i>0&&(r=100/i);const a=new IntersectionObserver(o,{root:null,rootMargin:"",threshold:r});e&&a.observe(e),(0,x.A3)(e,(()=>{a.disconnect()}))}createProductSummaryCardText(){const e=(0,Y.Ux)("div",{style:"\n max-width: 100%;\n "}),t=(0,Y.Ux)("div");t.classList.add("productSummaryCardText"),t.id="productSummaryCardText";const i=(0,Y.Ux)("div",{style:`\n font-size: 12px;\n line-height: 16px;\n color: ${this.utilities.isDarkMode()?"rgba(255, 255, 255, 0.52)":"#616161"};\n text-align: left;\n font-weight: 400;\n margin-top: 0px;\n max-width: 100%;\n `});i.id="productSummaryCardSubText",i.innerText=this.flyoutData.common.domain;const n=this.flyoutData.common.extractedEntity?.title;return n?(t.innerText=n,e.appendChild(i),e.appendChild(t),t.setAttribute("tabIndex","0"),t.setAttribute("aria-label",n),t.setAttribute("title",n),e):(e.appendChild(i),e)}createPriceHistoryTypeIllustration(e,t=!1){const i=(0,Y.Ux)("DIV");i.id="priceHistoryIllustration",i.className="ph_ill",i.style.placeSelf="center",i.style.display="grid",i.style.alignItems="center";const n=(0,Y.Ux)("div");n.id="price-change-image",n.slot="image";const o=(0,Y.Ux)("div");o.slot="hover-anchor",e===de.sh.PRICEDROP?o.innerHTML=this.assets.getPriceDecreaseTrendIcon(this.utilities.isDarkMode()):e===de.sh.PRICEINCREASE?o.innerHTML=this.assets.getPriceIncreaseTrendIcon(this.utilities.isDarkMode()):o.innerHTML=this.assets.getPriceNoChangeTrendIcon(),n.appendChild(o);const r=this.utilities.isDarkMode()?"#FFFFFF":"#000000",a=(0,Y.Ux)("span",{style:`\n font-size: 12px;\n color: transparent;\n line-height: 16px;\n font-weight: 400;\n display: flex;\n flex-direction: row;\n column-gap: 8px;\n place-self: center;\n justify-content: center;\n background-image: ${this.utilities.isDarkMode()?"linear-gradient(267.26deg, #5EC4FE 0%, #5EC4FE 100%)":"linear-gradient(267.26deg, #166FF5 0%, #166FF5 100%)"};\n background-clip: text;\n -webkit-background-clip: text;\n \n `});a.id="priceHistoryPercentage",a.className="illustrationPercentageText";const s=(0,dt.tB)(this.flyoutData)?(0,Y.Ux)("div",{style:`\n font-size: 10px;\n line-height: 14px;\n color: ${r};\n text-align: left;\n font-weight: 400;\n `}):(0,Y.Ux)("div",{style:`\n font-size: 10px;\n line-height: 14px;\n color: ${r};\n text-align: center;\n font-weight: 600;\n `});s.id="priceHistoryType",this.utilities.shouldRenderSmallNotification()&&(s.style.fontSize="10px",s.style.lineHeight="14px");const l=this.flyoutData.dataStoreModule.PriceHistoryData?.DailyPriceDropPercentage;let c;null!=l&&(c=this.utilities.toFixedSafe(Math.abs(l),0));const d=(0,Y.Ux)("div",{style:`\n font-size: 14px;\n line-height: normal;\n color: ${r};\n text-align: center;\n font-weight: 600;\n `});d.innerText=c<1?"":c+"%";let u="";return e===de.sh.PRICEDROP?(u=c<1?this.flyoutData.strings.phPriceDropZero.toLowerCase():this.flyoutData.strings.phPriceDrop.toLowerCase(),n.appendChild(d)):e===de.sh.PRICEINCREASE?(u=c<1?this.flyoutData.strings.phPriceUpZero.toLowerCase():this.flyoutData.strings.phPriceUp.toLowerCase(),n.appendChild(d)):u=this.flyoutData.strings.phStableSummary.toLowerCase(),i.appendChild(n),s.textContent=u,i.appendChild(s),(0,dt.tB)(this.flyoutData)&&(i.style.fontWeight="500"),i.setAttribute("tabIndex","0"),i}async setUpUpperDeckModules(){const e=(0,Y.Ux)("DIV",{className:"ph_upperdeck",style:"justify-content: space-between;\n column-gap: 12px;\n padding-top: 0px;\n max-width: 100%;\n cursor: pointer;\n display: inline-flex;"});return this.renderUpperDeckTile(e),e}renderUpperDeckTile(e){let t;this.summaryUtilities.ShouldRenderWishlist().then((async i=>{i&&(t=await this.createWishlistIllustration(),t&&e.appendChild(t))})),x.ZP.ObserveUntil((()=>this.IsModuleRendered("product-tracking-section")),(async()=>{const t=await this.createProductTrackingIllustration(this.productSummaryCardData?.productTrackingData);t&&e.appendChild(t)}))}async createWishlistIllustration(){const e=(0,Y.Ux)("div");return e.style.display="-webkit-inline-box",e.classList.add("dec-circ-mod"),e.id="wishListMod",this.flyoutData.common.extractedEntity&&this.flyoutData.common.base64ProductImage?(this.summaryUtilities.initDOMElements(this.flyoutData.common.extractedEntity,e),this.summaryUtilities.addCollectionDataToDOMElements(this.flyoutData.common.extractedEntity,this.flyoutData.common.base64ProductImage),this.summaryUtilities.createToolTipV3(e),e.setAttribute("tabIndex","0"),e):null}async createProductTrackingIllustration(e){const t=(0,Y.Ux)("div");t.style.display="-webkit-inline-box",t.id="product-tracking-wrappper-div",t.classList.add("dec-circ-mod");const i=await this.productTrackingViewUtilities.checkIsOutOfStock(),n=this.productTrackingViewUtilities.extractExtractedEntityData(this.flyoutData.common.extractedEntity,i);n&&(this.isProductTracked=await this.productTrackingViewUtilities.isTrackedProduct(qu.ZP.GetStrippedUrl(n.ProductUrl)));const o=(0,Y.Ux)("div");o.id="product-tracking-annotation-image",o.style.width="20px",o.style.height="20px",o.style.alignSelf="center",o.slot="image";const r=(0,Y.Ux)("div");r.slot="hover-anchor",r.innerHTML=this.isProductTracked?this.assets.getTrackedBell():this.assets.getTrackingBell(),o.appendChild(r);const a=(0,Y.Ux)("div");a.id="product-tracking-annotation-image-chev",a.style.alignSelf="center",a.style.marginTop="2px",a.style.display=(this.isProductTracked,"none"),a.slot="image";const s=(0,Y.Ux)("div");s.slot="hover-anchor",s.innerHTML=this.assets.getChevron(),a.appendChild(s);const l=(0,Y.Ux)("div",{style:"\n font-size: 12px;\n font-weight: 600;\n color: "+(this.utilities.isDarkMode()?"darkturquoise":"black")});l.id="product-tracking-annotation-text",t.appendChild(o),t.appendChild(a),this.summaryUtilities.createToolTipV3(t);const c=t.querySelector("#gcTooltipTextSub");c&&(c.textContent=i?this.isProductTracked?this.flyoutData.strings.productTrackingTitleAvailabilityUnTrack:this.flyoutData.strings.productTrackingTitleAvailability:this.isProductTracked?this.flyoutData.strings.TrackingNow:this.flyoutData.strings.TrackMe),t.setAttribute("aria-label",l.innerText);const d=document.getElementById("product-tracking-section");return this.stateManagement.addEventListener(Ku.e1.ProductTrackingUpdate,(async()=>{const e=await this.productTrackingViewUtilities.isTrackedProduct(qu.ZP.GetStrippedUrl(n?.ProductUrl||""));e!==this.isProductTracked&&this.handleProductTrackingChange(e,t,i)})),t.addEventListener("click",(()=>{this.productTrackingToggleAction(n,i,t,d)})),t.addEventListener("keydown",(async e=>{"ArrowDown"===e.key&&document.getElementById("product-tracking-section")?.focus(),"Enter"===e.key&&this.productTrackingToggleAction(n,i,t,d)})),t.setAttribute("tabIndex","0"),t}async handleProductTrackingChange(e,t,i=!1){const n=t.querySelector("#product-tracking-annotation-image"),o=t.querySelector("#product-tracking-annotation-image-chev"),r=t.querySelector("#gcTooltipTextSub");if(n&&o&&r){const t=n.querySelector("div");e?(t.innerHTML=this.assets.getTrackedBell(),o.style.display="none",r.textContent=i?this.flyoutData.strings.productTrackingTitleAvailabilityUnTrack:this.flyoutData.strings.TrackingNow):(t.innerHTML=this.assets.getTrackingBell(),o.style.display="none",r.textContent=i?this.flyoutData.strings.productTrackingTitleAvailability:this.flyoutData.strings.TrackMe)}this.isProductTracked=!this.isProductTracked}productTrackingToggleAction(e,t,n,o){const r=new W.Z(i.$S.TrackButtonSummaryCard,this.telemetryUtilities.setContentViewed(this.GetModuleName()));r.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.logModule.LogInfoEvent(i.R.ButtonClick,"Product Summary tracker clicked",r),this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKING_SUMMARY_CARD),this.handleProductTrackingChange(!this.isProductTracked,n,t),this.isProductTracked?this.productTrackingViewUtilities.switchToggleOn():this.productTrackingViewUtilities.switchToggleOff(),setTimeout((()=>{this.scrollToElementSmooth(o,this.productSummaryHeaderOffset)}),500),o&&setTimeout((()=>{o.classList.remove("animation_")}),5500)}getBackgroundClass(e){return e>="A"&&e<="G"?"letter-pink":e>="H"&&e<="O"?"letter-blue":e>="P"&&e<="U"?"letter-green":e>="V"&&e<="Z"?"letter-yellow":"fallback"}getTextColorClass(e){return e>="A"&&e<="G"?"text-dark-pink":e>="H"&&e<="O"?"text-dark-blue":e>="P"&&e<="U"?"text-dark-green":e>="V"&&e<="Z"?"text-dark-yellow":"text-default"}async renderProductSummaryCard(e,t){const i=t?this.utilities.getImageSrc(t):this.flyoutData.common.extractedEntity?.image_url,n=(0,Y.Ux)("DIV",{style:`display: flex; flex-direction: row; justify-content: flex-start; column-gap: 20px; padding-bottom: 12px;\n background: ${this.utilities.isDarkMode()?"#242424":"#FFFFFF"};"\n } ;`});n.id="divProductSummaryInfoWrapper",n.style.position="relative",n.style.top="0px",this.flyoutData.common.isPane||(n.style.paddingLeft="16px",n.style.paddingRight="16px");const o=i,r=""!==this.flyoutData.common.domain?this.flyoutData.common.domain[0].toUpperCase():"";let a;if(o)if(o.includes("defaultProduct")&&""!==r)a=this.addFallbackImage(r);else{const e=(0,Y.Ux)("IMG");e.style.maxWidth="60px",e.style.height="auto",e.style.maxHeight="60px",this.utilities.setImageSrc(e,o),this.utilities.shouldRenderSmallNotification()?(a=this.utilities.createProductImage(60,60,e,this.flyoutData.common.extractedEntity?.title),a.style.marginBottom="6px",n.style.justifyContent="space-between",n.style.alignItems="center"):(a=this.utilities.createProductImage(60,60,e,this.flyoutData.common.extractedEntity?.title),o.includes("defaultProduct")&&(e.style.maxHeight="unset",e.style.maxWidth="unset",e.style.width="60px",e.style.height="60px")),a.style.minWidth="60px",a.style.minHeight="60px"}else a=""!==r?this.addFallbackImage(r):null;const s=(0,Y.Ux)("DIV",{className:"ph_info",style:"display: flex;\n flex-direction: row;\n justify-content: space-between;\n column-gap: 12px;\n width: 100%;\n align-items: center"}),l=this.createProductSummaryCardText();if(this.setUpUpperDeckModules().then((e=>{s.appendChild(l),s.appendChild(e)})),a&&n.appendChild(a),n.appendChild(s),e.appendChild(n),this.utilities.isValidScenarioForProductSummary()){const t=(0,Y.Ux)("hr");t.id="ps-section-separator",this.createAggregatedUX().then((i=>{e.appendChild(t),e.appendChild(i)}))}else e?.classList.add("stickyWrapped")}addFallbackImage(e){const t=(0,Y.Ux)("DIV");t.classList.add("image-fb-container");const i=(0,Y.Ux)("DIV");return i.classList.add("fallback",this.getBackgroundClass(e)),i.textContent=e,i.classList.add(this.getTextColorClass(e)),t?.appendChild(i),t}async createAggregatedDiv(){const e=(0,Y.Ux)("DIV");if(e.id="aggregatedDivWrapper",e.classList.add("aggregatedDiv"),this.flyoutData.dataStoreModule.PriceHistoryData&&this.flyoutData.dataStoreModule.PriceHistoryData.ShowPriceHistoryInsight){const t="divPriceHistorySection";if(this.flyoutData.common.isStorybook){const i=this.createPriceHistoryTypeIllustration(this.flyoutData.dataStoreModule.PriceHistoryData?.getPriceHistoryType());await this.renderTile(i,t,e)}else x.ZP.ObserveUntil((()=>this.IsModuleRendered(t)),(async()=>{const i=this.createPriceHistoryTypeIllustration(this.flyoutData.dataStoreModule.PriceHistoryData?.getPriceHistoryType());await this.renderTile(i,t,e)}))}if(await this.renderPriceComparisonTile(e),null!=this.flyoutData.dataStoreModule.CashBackData?.canRenderCashback){const t="cashBackSection";if(this.flyoutData.common.isStorybook){const i=this.createCashbackTypeIllustration();await this.renderTile(i,t,e)}else x.ZP.ObserveUntil((()=>this.IsModuleRendered(t)),(async()=>{const i=this.createCashbackTypeIllustration();await this.renderTile(i,t,e)}))}if(null!=this.flyoutData.dataStoreModule.CouponData?.Coupons&&this.flyoutData.dataStoreModule.CouponData?.Coupons.length>0){const t="couponSection";if(this.flyoutData.common.isStorybook){const i=this.createCouponsTypeIllustration();await this.renderTile(i,t,e)}else x.ZP.ObserveUntil((()=>this.IsModuleRendered(t)),(async()=>{const i=this.createCouponsTypeIllustration();await this.renderTile(i,t,e)}))}return Promise.resolve(e)}IsModuleRendered(e){const t=document.getElementById(e);return null!==t&&document.body.contains(t)}async renderTile(e,t,i){const n=await this.createTileUX(t);e&&(n.appendChild(e),i.appendChild(n),this.addEventListenerToTile(n,t))}addEventListenerToTile(e,t){e.addEventListener("click",(()=>{const e=new W.Z(i.$S.TileButtonSummaryCard,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"Product Summary Tile clicked: "+t,e);let n=document.getElementById(t);const o=n;if(n){if("couponSection"===t){n=o?.shadowRoot?.querySelector("#accordion-1")?.shadowRoot?.querySelector("div.heading")??o;const e=document.querySelector("#couponSection > fluent-button")?.shadowRoot?.querySelector("button");e&&e.click()}if(document.body.contains(o))try{setTimeout((()=>{this.scrollToElementWithRetries(n)}),500),n?.classList.add("animation_"),setTimeout((()=>{n?.classList.remove("animation_")}),2e3)}catch(e){}}}))}async createAggregatedUX(){return this.createAggregatedDiv()}async renderPriceComparisonTile(e){if(null!=this.flyoutData.dataStoreModule.PriceComparisonData?.CompetingPrices&&this.flyoutData.dataStoreModule.PriceComparisonData?.CompetingPrices.length>1){const t=this.buyingOptionsExp||this.buyingOptionsClientExp?"buyingOptionsSection":"priceComparisonSection";if(this.flyoutData.common.isStorybook){const i=this.createPriceComparisonTypeIllustration();await this.renderTile(i,t,e)}else x.ZP.ObserveUntil((()=>this.IsModuleRendered(t)),(async()=>{const i=this.createPriceComparisonTypeIllustration();await this.renderTile(i,t,e)}))}}async createTileUX(e){const t=(0,Y.Ux)("DIV");return t.classList.add("bottomdeck_tile"),t.id=e+"_rowTile",t}scrollToElementWithRetries(e,t=3,i=300,n=0){const o=e;o?this.scrollToElementSmooth(o,0,!1,this.productSummaryHeaderOffset):n<t&&setTimeout((()=>{this.scrollToElementWithRetries(e,t,i,n+1)}),i)}scrollToElementSmooth(e,t,i,n){if(e){try{e.style.scrollMarginTop=`${t}px`,0===t&&document?.documentElement?e.scrollIntoView({block:"center",behavior:"smooth"}):e.scrollIntoView({behavior:"smooth"})}catch(e){}try{i&&window.scrollBy({top:e.offsetHeight})}catch(e){}try{null!=n&&0!==n&&window.scrollBy({top:n})}catch(e){}}}createCouponsTypeIllustration(){const e=this.flyoutData.dataStoreModule.CouponData;if(e){const t=(0,Y.Ux)("DIV");t.id="couponIllustration",t.className="illustrationskel";const i=(0,Y.Ux)("DIV",{style:"display: flex;\n position: relative;\n justify-content: center;\n height: 20px;"}),n=(0,Y.Ux)("div");n.slot="image";const o=(0,Y.Ux)("div");o.slot="hover-anchor",o.innerHTML=this.assets.getCouponsAnnotationImage(),n.appendChild(o),i.appendChild(n);const r=(0,Y.Ux)("DIV");return r.classList.add("illustrationText"),r.textContent=e.Coupons.length.toString()+" coupons",t.appendChild(i),t.appendChild(r),t.setAttribute("tabIndex","0"),t}return null}createCashbackTypeIllustration(){const e=this.flyoutData.dataStoreModule?.CashBackData;if(e){const e=(0,Y.Ux)("DIV");e.id="cashbackIllustration",e.classList.add("illustrationskel");const t=this.utilities.retrieveCashBackAmount(!1);let i;const n=(0,Y.Ux)("DIV",{style:"display: flex;\n position: relative;\n justify-content: center;\n height: 20px;"}),o=(0,Y.Ux)("DIV");if(o.classList.add("illustrationText"),o.textContent="cash back",t.cashBackAmount)i=this.utilities.createCommissionArrow(t.cashBackAmount,!1,zu.h.Small);else{i=(0,Y.Ux)("div"),i.slot="image";const e=(0,Y.Ux)("div");e.slot="hover-anchor",e.innerHTML=this.assets.getCashbackAnnotationImage(),i.appendChild(e)}return n.appendChild(i),e.append(n),e.appendChild(o),e.setAttribute("tabIndex","0"),e}return null}createPriceComparisonTypeIllustration(){const e=this.flyoutData.dataStoreModule.PriceComparisonData,t=e?.CompetingPrices?.length;if(t){if(t<1)return this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Product Summary - Less than 1 Offer present, not PC tile",this.tileStatusLog),null;const n=(0,Y.Ux)("DIV",{style:"display: grid;\n flex-direction: row;\n justify-content: center;\n flex-wrap: wrap;\n column-gap: 12px;\n width: 100%;\n background: transparent;"});n.id="priceComparisonIllustration";const o=(0,Y.Ux)("DIV");o.id="priceComparisonIllustrationSubdiv",o.append(this.setupPriceComparisonIllustration(e)),n.appendChild(o);const r=(0,Y.Ux)("DIV",{style:`display: flex;\n font-size: 10px;\n line-height: 14px;\n flex-direction: column;\n justify-content: center;\n flex-wrap: wrap;\n column-gap: 12px;\n padding-top: 0px;\n background: transparent;\n color: ${this.utilities.isDarkMode()?"#FFFFFF":"#000000"};\n font-weight: 600;`});return r.textContent=t>4?"4+ stores":t+" stores",o.appendChild(r),n.appendChild(o),n.setAttribute("tabIndex","0"),n}return null}createImageCarouselIcon(e,t,i){const n=(0,Y.Ux)("DIV",{style:` border-radius: ${t};`}),o=(0,Y.Ux)("IMG");return o.style.width=`${e}px`,o.style.height=`${e}px`,"none"!==i?this.utilities.addFavIconSrc(o,n,i):(o.src=this.flyoutData.common.resourcesEndpoint+"productSummary/priceComparisonDefaultImg.png",n.appendChild(o)),n.innerHTML?n:null}setupPriceComparisonIllustration(e){const t=e.CompetingPrices?.length;(0,Y.Ux)("DIV",{style:"display: grid;\n flex-direction: row;\n justify-content: center;\n flex-wrap: wrap;\n column-gap: 12px;\n width: 100%;\n background: transparent;"}).id="priceComparisonIllustration";const i=(0,Y.Ux)("DIV",{style:"display: flex; flex-direction: row; column-gap: 1px; height: 20px; justify-content: center;"});let n=[];for(let i=0;i<Math.min(3,t);i++){const t=this.createImageCarouselIcon(16,"8px 12px",e.CompetingPrices[i]?.Domain);t&&n.push(t)}if(n.length<=1){n=[];const e=this.createImageCarouselIcon(21,"8px 12px","none");e&&n.push(e)}return n.forEach((e=>i.appendChild(e))),i}populateModule(e,t){this.renderProductSummaryCard(t,e)}};function JE(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}var QE=class extends Qu{constructor(e,t,i,n){super(),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"renderedPageType",void 0),(0,s.Z)(this,"telemetryHandler",void 0),(0,s.Z)(this,"uxUtils",void 0),(0,s.Z)(this,"moduleName",r.ModuleNames.PRODUCT_SUMMARY),(0,s.Z)(this,"productSummarySection",void 0),(0,s.Z)(this,"isDarkMode",!1),(0,s.Z)(this,"productSummary",void 0),(0,s.Z)(this,"logMetadata",{}),(0,s.Z)(this,"sectionId","product-summary-shopping-section"),this.flyoutData=e,this.uxUtils=t,this.utilities=t.viewModulesUtilities,this.telemetryHandler=t.discoverTelemetryHandler,this.pageHandlerModule=t.pageHandlerModule,this.logModule=t.logModule,this.storageHandler=t.storageHandler,this.commonAssets=i,this.stateManagement=n,this.isDarkMode=this.utilities.isDarkMode(),this.assets=new class{getStyles(){return"\n .product-summary__container {\n padding: 8px 8px;\n margin: 0px 8px 4px 8px;\n }\n\n .product-summary__containerPane {\n padding: 0px 12px 12px 12px !important;\n }\n\n .product-summary__card {\n background: rgba(255, 255, 255, 0.5);\n display: flex;\n flex-direction: column;\n justify-content: start;\n padding: 12px 16px;\n color: rgba(68, 68, 68, 1);\n margin-block-end: 8px;\n border-radius: 8px;\n box-shadow: 0px 1px 2px 0px rgba(0, 0, 0, 0.14);\n }\n .product-summary__card:last-child {\n margin-block-end: 0px;\n }\n\n .product-summary__cardPane {\n }\n\n .product-summary__section {\n display: flex;\n flex-direction: column;\n gap: 8px;\n }\n\n .product-summary__section-title-container {\n display: flex;\n align-items: center;\n gap: 4px;\n }\n\n .product-summary__section-title-icon {\n width: 20px;\n height: 20px;\n }\n\n .product-summary__section-title {\n margin-block: 0px;\n font-weight: 600;\n font-size: 16px;\n line-height: 22px;\n }\n\n .product-summary__summary {\n margin-block: 0px;\n font-style: normal;\n font-weight: 400;\n font-size: 14px;\n line-height: 20px;\n }\n\n .product-summary__opinions-list {\n display: flex;\n flex-wrap: wrap;\n gap: 8px 4px;\n }\n\n .product-summary__opinions-rating-val {\n margin: 0px 3px 0px 3px;\n }\n\n .product-summary__opinions-rating-val-accessibility, .product-summary__opinions-rating-count-accessibility {\n position: absolute;\n left: -999em;\n }\n\n .uiFeaturesContainer {\n font-weight: 600;\n font-size: 1.15em;\n }\n\n .uiFeaturesContainer.positive {\n color: #2DCF8B;\n }\n\n .uiFeaturesContainer.negative {\n color: #F76A3B;\n }\n\n .featureBulletList {\n margin: 8px 0px 8px 0px;\n padding: 0px;\n }\n\n .featureBulletList li {\n font-weight: 400;\n font-size: 0.85em;\n list-style-type: none;\n padding: 4px 0px 4px 0px;\n align-items: center;\n display: flex;\n flex-wrap: wrap;\n }\n\n .featureBulletList li div {\n display: flex;\n flex-direction: row;\n }\n\n .featureBulletList li span {\n display: flex;\n align-items: center;\n }\n\n .product-summary__opinions-name {\n margin: 0px 3px 0px 3px;\n }\n\n .product-summary__opinions-rating-val {\n font-weight: 600;\n }\n\n .product-summary__opinions-rating-icon {\n height: 12px;\n width: 12px;\n margin-left: 1px;\n }\n\n .product-summary__opinions-rating-count {\n margin-right: 2px;\n }\n\n .product-summary__opinions-badge {\n display: flex;\n justify-content: center;\n align-items: center;\n padding: 2px 6px;\n\n border-radius: 8px;\n border: 1px solid var(--light-mode-balanced-accent-fill-alt-primary, #D1DBFA);\n background: var(--light-mode-balanced-accent-fill-primary, rgba(255, 255, 255, 0.70));\n\n font-style: normal;\n font-weight: 400;\n font-size: 12px;\n line-height: 16px;\n height: 20px;\n }\n\n .product-summary__insights-list {\n display: flex;\n flex-wrap: wrap;\n gap: 8px 4px;\n }\n\n .product-summary__insights-badge.btn {\n border: unset;\n background-color: unset;\n border-bottom: 1.5px dashed rgba(0, 0, 0, 0.4);\n padding: 0;\n cursor: pointer;\n }\n .product-summary__insights-badge {\n font-style: normal;\n font-weight: 400;\n font-size: 14px;\n line-height: 20px;\n\n text-decoration: none;\n border-bottom: 1.5px dashed rgba(0, 0, 0, 0.4);\n color: currentColor;\n margin: 0;\n }\n "}getDarkModeStyles(){return"\n .product-summary__card {\n background: rgba(255, 255, 255, 0.052);\n color: rgba(255, 255, 255, 1);\n box-shadow: 0px 1px 2px 0px rgba(0, 0, 0, 0.28);\n }\n "}getPreviewLinkIcon(){return eh.Z.getTrustedHTML`<svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M2 7C2 5.34315 3.34315 4 5 4H15C16.6569 4 18 5.34315 18 7V13C18 14.6569 16.6569 16 15 16H5C3.34315 16 2 14.6569 2 13V7ZM5 5C3.89543 5 3 5.89543 3 7V13C3 14.1046 3.89543 15 5 15H15C16.1046 15 17 14.1046 17 13V7C17 5.89543 16.1046 5 15 5H5ZM4 7C4 6.44772 4.44772 6 5 6H15C15.5523 6 16 6.44772 16 7V9C16 9.55228 15.5523 10 15 10H5C4.44772 10 4 9.55229 4 9V7ZM15 7H5V9H15V7ZM12 11C11.4477 11 11 11.4477 11 12V13C11 13.5523 11.4477 14 12 14H15C15.5523 14 16 13.5523 16 13V12C16 11.4477 15.5523 11 15 11H12ZM12 12H15V13H12V12ZM4 11.5C4 11.2239 4.22386 11 4.5 11H9.5C9.77614 11 10 11.2239 10 11.5C10 11.7761 9.77614 12 9.5 12H4.5C4.22386 12 4 11.7761 4 11.5ZM4.5 13C4.22386 13 4 13.2239 4 13.5C4 13.7761 4.22386 14 4.5 14H9.5C9.77614 14 10 13.7761 10 13.5C10 13.2239 9.77614 13 9.5 13H4.5Z" fill="currentColor"/>
</svg>
`}getReceiptSparklesIcon(){return eh.Z.getTrustedHTML`<svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M15.226 1.35305L14.8777 0.282251C14.8486 0.19972 14.7946 0.128252 14.7231 0.0776997C14.6516 0.0271473 14.5662 0 14.4786 0C14.391 0 14.3056 0.0271473 14.2341 0.0776997C14.1626 0.128252 14.1085 0.19972 14.0794 0.282251L13.7311 1.35305C13.625 1.67631 13.4454 1.97065 13.2066 2.21307C12.9677 2.45549 12.6759 2.63941 12.3541 2.75044L11.2825 3.09845C11.1999 3.12757 11.1284 3.18157 11.0778 3.25301C11.0272 3.32445 11 3.40981 11 3.49733C11 3.58484 11.0272 3.6702 11.0778 3.74164C11.1284 3.81308 11.1999 3.86708 11.2825 3.8962L12.3541 4.24421C12.6292 4.33588 12.883 4.48064 13.1014 4.66973C13.1421 4.70496 13.1815 4.74173 13.2197 4.77999C13.4202 4.98116 13.5796 5.21872 13.6897 5.47932C13.7128 5.53422 13.7338 5.59014 13.7525 5.64696L14.1008 6.71775C14.1271 6.79215 14.1736 6.85755 14.2349 6.90675C14.2416 6.91213 14.2484 6.91732 14.2555 6.92231C14.327 6.97286 14.4124 7.00001 14.5 7.00001C14.5876 7.00001 14.673 6.97286 14.7445 6.92231C14.816 6.87175 14.87 6.80029 14.8992 6.71775L15.2475 5.64696C15.3558 5.32141 15.5385 5.0256 15.7813 4.78302C16.0241 4.54044 16.3201 4.35778 16.6459 4.24956L17.7175 3.90155C17.8001 3.87244 17.8716 3.81844 17.9222 3.747C17.9728 3.67556 18 3.5902 18 3.50268C18 3.41516 17.9728 3.3298 17.9222 3.25836C17.8716 3.18692 17.8001 3.13292 17.7175 3.10381L17.6961 3.09845L16.6245 2.75044C16.2987 2.64223 16.0026 2.45957 15.7599 2.21699C15.5171 1.97441 15.3343 1.67859 15.226 1.35305ZM19.0175 7.96461L19.7829 8.21319L19.7982 8.21701C19.8572 8.23781 19.9083 8.27638 19.9445 8.32741C19.9806 8.37844 20 8.43941 20 8.50192C20 8.56443 19.9806 8.62541 19.9445 8.67643C19.9083 8.72746 19.8572 8.76603 19.7982 8.78683L19.0328 9.03541C18.8001 9.11271 18.5886 9.24317 18.4152 9.41645C18.2418 9.58972 18.1113 9.80101 18.0339 10.0335L17.7851 10.7984C17.7643 10.8574 17.7257 10.9084 17.6746 10.9445C17.6236 10.9806 17.5626 11 17.5 11C17.4374 11 17.3764 10.9806 17.3254 10.9445C17.2743 10.9084 17.2357 10.8574 17.2149 10.7984L16.9661 10.0335C16.8893 9.80031 16.7589 9.58824 16.5855 9.41428C16.412 9.24032 16.2003 9.10926 15.9672 9.03158L15.2018 8.78301C15.1428 8.76221 15.0917 8.72364 15.0555 8.67261C15.0194 8.62158 15 8.56061 15 8.4981C15 8.43558 15.0194 8.37461 15.0555 8.32358C15.0917 8.27255 15.1428 8.23398 15.2018 8.21319L15.9672 7.96461C16.1971 7.8853 16.4055 7.75392 16.5761 7.58077C16.7467 7.40762 16.875 7.19737 16.9508 6.96647L17.1996 6.20161C17.2204 6.14266 17.259 6.09161 17.31 6.05551C17.3611 6.0194 17.4221 6.00001 17.4847 6.00001C17.5473 6.00001 17.6083 6.0194 17.6593 6.05551C17.7104 6.09161 17.749 6.14266 17.7698 6.20161L18.0186 6.96647C18.0959 7.199 18.2265 7.4103 18.3999 7.58357C18.5733 7.75684 18.7848 7.88731 19.0175 7.96461ZM14 8.50002C13.976 8.35706 13.9762 8.21158 14 8.06955V7.85604C13.8598 7.81374 13.7278 7.74745 13.61 7.66002C13.3991 7.48636 13.2399 7.25803 13.15 7.00002L13 6.48638V16H6C4.89543 16 4 15.1046 4 14V5C4 4.44772 4.44772 4 5 4H10.0972C10.0353 3.84151 10.002 3.67222 10 3.50002C10.0042 3.32724 10.0402 3.15785 10.1053 3H5C3.89543 3 3 3.89543 3 5V14C3 15.6569 4.34315 17 6 17H14C15.6569 17 17 15.6569 17 14V12.5C17 12.2239 16.7761 12 16.5 12H14V8.50002ZM14 13H16V14C16 15.1046 15.1046 16 14 16V13ZM6 6.5C6 6.22386 6.22386 6 6.5 6H10.5C10.7761 6 11 6.22386 11 6.5C11 6.77614 10.7761 7 10.5 7H6.5C6.22386 7 6 6.77614 6 6.5ZM6 9.5C6 9.22386 6.22386 9 6.5 9H10.5C10.7761 9 11 9.22386 11 9.5C11 9.77614 10.7761 10 10.5 10H6.5C6.22386 10 6 9.77614 6 9.5ZM6 12.5C6 12.2239 6.22386 12 6.5 12H8.5C8.77614 12 9 12.2239 9 12.5C9 12.7761 8.77614 13 8.5 13H6.5C6.22386 13 6 12.7761 6 12.5Z" fill="currentColor"/>
</svg>
`}getTagSearchIcon(){return eh.Z.getTrustedHTML`<svg width="20" height="20" viewBox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M15 6C15 6.55228 14.5523 7 14 7C13.4477 7 13 6.55228 13 6C13 5.44772 13.4477 5 14 5C14.5523 5 15 5.44772 15 6ZM9.7037 2.58399C10.0818 2.20681 10.5951 1.99654 11.1292 2.00004L16.0196 2.0321C17.1179 2.0393 18.0049 2.93081 18.0065 4.02911L18.0138 8.97917C18.0146 9.51063 17.8038 10.0205 17.428 10.3963L17.0675 10.7568C16.8634 10.4918 16.6305 10.2502 16.3734 10.0367L16.7209 9.68923C16.9088 9.50133 17.0142 9.24637 17.0138 8.98065L17.0065 4.03058C17.0057 3.48143 16.5622 3.03568 16.013 3.03208L11.1227 3.00002C10.8556 2.99827 10.599 3.1034 10.4099 3.29199L3.72836 9.95653C3.33699 10.3469 3.33659 10.9808 3.72746 11.3716L8.67586 16.32C9.04849 16.6927 9.64203 16.7097 10.0349 16.3713C10.2487 16.629 10.4907 16.8625 10.7562 17.067C9.97244 17.808 8.73628 17.7947 7.96875 17.0271L3.02036 12.0788C2.2386 11.297 2.23941 10.0293 3.02216 9.24852L9.7037 2.58399ZM16.3032 15.5961C16.7408 15.0118 17 14.2862 17 13.5C17 11.567 15.433 10 13.5 10C11.567 10 10 11.567 10 13.5C10 15.433 11.567 17 13.5 17C14.2862 17 15.0118 16.7408 15.5961 16.3032L18.1464 18.8536C18.3417 19.0489 18.6583 19.0489 18.8535 18.8536C19.0488 18.6584 19.0488 18.3418 18.8536 18.1465L16.3032 15.5961ZM16 13.5C16 14.8807 14.8807 16 13.5 16C12.1193 16 11 14.8807 11 13.5C11 12.1193 12.1193 11 13.5 11C14.8807 11 16 12.1193 16 13.5Z" fill="currentColor"/>
</svg>
`}}}GetModuleName(){return this.moduleName}async ShouldRenderModule(){const t=this.GetProductSummary();if(t){if(this.stateManagement.AddDiscoverRenderModule(r.ModuleNames.PRODUCT_SUMMARY),this.productSummary=t,e.R.isExperimentActive(f.H.discoverShopping)&&this.flyoutData.common.isDiscoverPane)return this.logMetadata={isProductSummary:!!t.summary,popularOpinionsCount:t.popularOpinions.length,topInsightsCount:t.topInsights.length},Promise.resolve(!0);if(!this.flyoutData.common.isDiscoverPane)return this.productSummary=t,new Promise(((e,t)=>{this.productSummary&&this.productSummary.summary?e(!0):e(!1)}));if(e.R.isTestFlagActive(Zt.t.msShoppingTestExp99))return Promise.resolve(!0)}return Promise.resolve(!1)}populateMainHeader(){const e=this.flyoutData.common.shopping.querySelector("#product-summary-shopping-section");e&&(e.slot="header-content")}async renderModule(){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());const e=(0,Y.Ux)("msft-edge-shopping-section",{id:this.sectionId,titleText:this.flyoutData.strings.userInsightsSectionTitle,accordion:this.flyoutData.common.currentDevice===r.AS.Desktop,expanded:!0,titleIcon:`${this.flyoutData.common.resourcesEndpoint}smartSuggestions/title-sparkle.svg`,aiSummryIndicator:this.flyoutData.strings.psAiSummaryIndicator,isAiHeading:!0});return this.CreateUx(e),this.CreateModule(e,r.H7.PRODUCT_SUMMARY,this.moduleName,r.$k.CONTEXTUAL,r.SV.LIST)}PostProcessing(e,t,n){const o=`position ${t}`;0===t&&this.flyoutData.common.isDiscoverPane&&this.telemetryHandler.LogEventTelemetry(i.xu.ProductSummary,o,this.renderedPageType,e,this.logMetadata)}GetProductSummary(){const e=this.flyoutData.dataStoreModule.DiscoverShoppingData?.ProductSummaryData;return e}CreateUx(e){const t=(0,Y.Ux)("div",{className:this.withClassNamePrefix("container")});if(t.tabIndex=0,this.flyoutData.common.isDiscoverPane||t.classList.add(this.withClassNamePrefix("containerPane")),this.productSummary?.summary?.length){const e=this.CreateProductSummaryCard(this.flyoutData.strings.psReviewSummary);if(e.appendChild(this.createProductSummarySection(this.productSummary.summary)),t.appendChild(e),this.productSummary?.prosOpinions?.length){const e=this.CreateProductSummaryCard(this.flyoutData.strings.psPros);e.appendChild(this.createOpinionsSection(this.productSummary.prosOpinions,!0)),t.appendChild(e)}if(this.productSummary?.consOpinions?.length){const e=this.CreateProductSummaryCard(this.flyoutData.strings.psCons);e.appendChild(this.createOpinionsSection(this.productSummary.consOpinions,!1)),t.appendChild(e)}}if(this.flyoutData.common.isDiscoverPane){const e=()=>{const n=function(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?JE(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):JE(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}({productSummaryData:this.productSummary},this.logMetadata);this.telemetryHandler.LogEventTelemetry(i.xu.ProductSummaryHover,"Product Summary Hover",this.renderedPageType,this.moduleName,n),t.removeEventListener("mouseover",e)};t.addEventListener("mouseover",e)}e.appendChild(t)}createOpinionsSection(e,t){const i=(0,Y.Ux)("div");i.classList.add("uiFeaturesContainer"),i.innerText=t?this.flyoutData.strings.psPros:this.flyoutData.strings.psCons;const n=(0,Y.Ux)("ul");n.classList.add("featureBulletList",t?"positive":"negative");for(let i=0;i<(e?.length??0);i++){const o=(0,Y.Ux)("li"),r=(0,Y.Ux)("div"),a=(0,Y.Ux)("span");a.innerHTML=t?this.commonAssets.getCheckmarkIcon():this.commonAssets.getCrossIcon();const s=(0,Y.Ux)("span");s.textContent=e[i]??"",s.style.paddingLeft="12px",r.appendChild(a),r.appendChild(s),o.appendChild(r),n.appendChild(o)}return i.append(n),i}CreateProductSummaryCard(e){const t=(0,Y.Ux)("div",{className:this.withClassNamePrefix("card"),title:e});return this.flyoutData.common.isDiscoverPane||t.classList.add(this.withClassNamePrefix("cardPane")),t}createProductSummarySection(e){const t=this.flyoutData.strings.psReviewSummary,i=(0,Y.Ux)("div",{className:this.withClassNamePrefix("section")}),n=this.createSectionTitle(t),o=(0,Y.Ux)("div",{className:this.withClassNamePrefix("section")}),r=(0,Y.Ux)("p",{className:this.withClassNamePrefix("summary")},e);return o.appendChild(r),i.appendChild(n),i.appendChild(o),i}createSectionTitle(e){const t=(0,Y.Ux)("div",{className:this.withClassNamePrefix("section-title-container")}),i=(0,Y.Ux)("h2",{className:this.withClassNamePrefix("section-title")},e);return t.appendChild(i),t}withClassNamePrefix(e){return`product-summary__${e}`}},ek=class extends Qu{constructor(t,i,n,o){super(),this.stateManagement=t,this.flyoutData=i,this.commonAssets=o,(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"modal",void 0),(0,s.Z)(this,"productTrackingSectionId","product-tracking-section"),(0,s.Z)(this,"isProductTracked",void 0),(0,s.Z)(this,"productDetails",void 0),(0,s.Z)(this,"isOutOfStock",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"productTrackingViewUtilities",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"isConciseExpActive",!1),(0,s.Z)(this,"durationOptions",[]),(0,s.Z)(this,"priceDropOptions",[]),(0,s.Z)(this,"durationValue",void 0),(0,s.Z)(this,"priceDropValue",void 0),(0,s.Z)(this,"section",void 0),(0,s.Z)(this,"isAlertExpActive",!1),this.assets=new class{getStyles(){return"\n .productTrackingContainer {\n padding: 6px;\n padding-bottom: 0;\n }\n .productTrackingContentContainer {\n display: flex;\n align-items: center;\n margin-bottom: 16px;\n }\n .productTrackingTextContainer {\n flex: 1;\n padding: 5px 10px 0 15px;\n text-align: left;\n align-self: flex-start;\n }\n .productTrackingText {\n font-weight: 600;\n line-height: 22px;\n }\n .productTrackingSubtitle {\n color: var(--neutral-foreground-hint);\n padding-right: 10px;\n }\n fluent-switch#trackingToggle {\n --design-unit: 4;\n --neutral-foreground-rest: #616161;\n }\n #trackingToggle::part(switch) {\n border: 1px solid #616161;\n }\n #trackingToggle.checked::part(switch) {\n border: 1px solid transparent;\n background: #0F6CBD;\n }\n #trackingToggle::part(checked-indicator) {\n --design-unit: 4;\n background: #616161;\n border: 2px solid transparent;\n top: 2px;\n left: 2px;\n }\n #trackingToggle.checked::part(checked-indicator) {\n background: #FFFFFF;\n left: 22px;\n }\n .productTrackingContainer hr {\n border: none;\n height: 1px;\n background: #F5F5F5;\n }\n .trackedStateIconContainer {\n position: absolute;\n display: flex;\n margin: 3px;\n justify-content: center;\n align-items: center;\n width: 22px;\n height: 22px;\n bottom: 0;\n right: 0;\n border-radius: 50%;\n background: var(--accent-fill-hover, #0473CE);\n box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.08);\n }\n .trackedStateIcon {\n max-width: 20px;\n }\n .alertSettingBtn {\n display: inline-flex;\n width: 100%;\n font-weight: 600;\n margin-bottom: 6px;\n font-size: 14px;\n border-color: #D6D6D6;\n }\n .trackedProductText {\n color: var(--accent-fill-rest);\n font-weight: 400;\n background: inherit;\n }\n .trackedProductText::part(control) {\n padding-left: 0\n }\n #trackingToggle::part(select-indicator) {\n min-width: unset;\n width: 10px;\n }\n @media (forced-colors: active) {\n ::part(checked-indicator) {\n background: fieldtext;\n }\n }\n "}getConciseStyles(){return"\n fluent-switch#trackingToggle {\n --design-unit: 4;\n --neutral-foreground-rest: #616161;\n }\n .productTrackingContainer {\n padding: 2px 6px;\n }\n .productTrackingContentContainer {\n display: flex;\n align-items: center;\n }\n .productTrackingTextContainer {\n flex: 1;\n padding: 0 10px 0 12px;\n text-align: left;\n align-self: flex-start;\n }\n .productTrackingText {\n font-weight: 600;\n font-size: 14px;\n line-height: 20px;\n }\n .productTrackingSubtitle {\n color: var(--neutral-foreground-hint);\n padding-right: 10px;\n font-size: 12px;\n line-height: 16px;\n }\n .trackedStateIconContainer {\n position: static;\n }\n #trackingToggle::part(switch) {\n border: 1px solid var(--neutral-foreground-rest);\n }\n #trackingToggle.checked::part(switch) {\n border: 1px solid transparent;\n background: #0F6CBD;\n }\n #trackingToggle::part(checked-indicator) {\n --design-unit: 4;\n background: var(--neutral-foreground-rest);\n border: 2px solid transparent;\n top: 2px;\n left: 2px;\n }\n #trackingToggle.checked::part(checked-indicator) {\n background: #FFFFFF;\n left: 22px;\n }\n .trackedStateIconContainer {\n display: flex;\n justify-content: center;\n align-items: center;\n width: 40px;\n height: 40px;\n border-radius: 50%;\n background: #E0EDFF;\n box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.08);\n max-height: 42px;\n }\n .alertSettingBtn {\n display: inline-flex;\n height: 24px;\n font-weight: 400;\n font-size: 14px;\n line-height: 22px;\n margin-top: 6px;\n margin-left: 52px;\n }\n .trackedProductText {\n color: var(--accent-fill-rest);\n font-weight: 400;\n background: inherit;\n }\n .trackedProductText::part(control) {\n padding-left: 0\n }\n .consentSection {\n padding: 0 2px;\n }\n .consentSection.hidden {\n display: none;\n }\n .consentSection .consentContainer {\n display: flex;\n padding: 8px 0;\n }\n .consentSection .consentContainer #consentText {\n padding-left: 8px;\n }\n .consentSection .privacyText {\n font-size: 12px;\n color: var(--text-neutral-foreground-hint);\n }\n .consentSection msft-shopping-tooltip {\n display: flex;\n justify-content: center;\n align-items: center;\n padding: 4px;\n }\n @media (forced-colors: active) {\n ::part(checked-indicator) {\n background: fieldtext;\n }\n }\n "}getNotificationStyles(){return"\n .productTrackingContainer {\n padding: 0 16px;\n }\n .productTrackingContentContainer {\n margin-bottom: 0px;\n }\n .oosNotification .productTrackingContentContainer {\n font-size: 13px;\n padding-bottom: 12px;\n }\n .productDetailsContainer {\n display: flex;\n padding-bottom: 14px;\n }\n .productTrackingText {\n font-weight: 600;\n font-size: 14px;\n line-height: 20px;\n }\n .productText {\n flex: 1;\n text-align: left;\n font-weight: 600;\n }\n .backInStockText {\n color: #008A21;\n font-size: 20px;\n line-height: 24px;\n }\n .productTrackingRetailerText {\n line-height: 24px;\n font-size: 20px;\n }\n .viewItemBtn {\n width: 100%;\n font-weight: 600;\n font-size: 14px;\n }\n .trackedProductContainer {\n display: flex;\n padding-top: 12px;\n }\n .productTrackingInStockContainer {\n width: 100%;\n padding: 0 16px;\n }\n .inStockTrackedStateIconContainer {\n position: static;\n display: flex;\n justify-content: center;\n align-items: center;\n width: 36px;\n height: 36px;\n border-radius: 50%;\n background: #F3F3F3;\n box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.08);\n }\n .trackedProductNotifTextContainer {\n flex: 1;\n text-align: left;\n padding-left: 8px;\n padding-right: 20px;\n }\n .trackedProductNotifText {\n font-weight: 600;\n }\n .trackingToggleContainer.hidden {\n visibility: hidden;\n width: 0;\n height: 0;\n }\n .ptTrackButton {\n width: 100%;\n }\n .alertsOnSubtitle {\n color: var(--neutral-foreground-hint);\n }\n .productTrackingInStockContainer .productTrackingViewContainer {\n margin: 0;\n width: 100% !important;\n }\n .consentSection {\n padding: 0 2px;\n }\n .consentSection.hidden {\n display: none;\n }\n .consentSection .consentContainer {\n display: flex;\n padding: 8px 0;\n }\n .consentSection .consentContainer #consentText {\n padding-left: 8px;\n }\n .consentSection .privacyText {\n font-size: 12px;\n color: var(--text-neutral-foreground-hint);\n }\n .consentSection msft-shopping-tooltip {\n display: flex;\n justify-content: center;\n align-items: center;\n padding: 4px;\n }\n\n "}getDarkModeStyles(){return"\n fluent-switch#trackingToggle {\n --foreground-on-accent-rest: #242424;\n --foreground-on-accent-hover: #242424;\n --neutral-foreground-rest: #ADADAD;\n }\n .productTrackingContainer hr {\n background: #555555;\n }\n .trackedProductText {\n color: #63ADE5;\n }\n #trackingToggle::part(switch) {\n border: 1px solid var(--neutral-foreground-rest);\n }\n #trackingToggle.checked::part(switch) {\n background: #479EF5;\n }\n #trackingToggle::part(checked-indicator) {\n background: var(--neutral-foreground-rest);\n }\n #trackingToggle.checked::part(checked-indicator) {\n background: #3B3B3B;\n }\n "}getDarkModeConciseStyles(){return"\n fluent-switch#trackingToggle {\n --foreground-on-accent-rest: #242424;\n --foreground-on-accent-hover: #242424;\n --neutral-foreground-rest: #ADADAD;\n }\n .trackedProductText {\n color: #479EF5;\n }\n #trackingToggle::part(switch) {\n border: 1px solid var(--neutral-foreground-rest);\n }\n #trackingToggle.checked::part(switch) {\n background: #479EF5;\n }\n #trackingToggle::part(checked-indicator) {\n background: var(--neutral-foreground-rest);\n }\n #trackingToggle.checked::part(checked-indicator) {\n background: #3B3B3B;\n }\n "}getModalStyles(){return'\n .modalContainer {\n width: 338px;\n }\n .modalHeading {\n display: flex;\n justify-content: space-between;\n align-items: center;\n padding: 8px 16px;\n border-bottom: 0.5px solid rgba(243, 243, 243);\n }\n .modalHeading .closeBtn {\n min-width: 24px;\n height: 24px;\n }\n .modalTitle {\n flex: 1;\n font-weight: 600;\n }\n .modalProductContainer {\n display: flex;\n padding: 16px;\n border-bottom: 0.5px solid rgba(243, 243, 243);\n }\n .modalProductDetailsContainer {\n flex: 1;\n text-align: left;\n padding-left: 12px;\n }\n .modalProductDetailsContainer .productTitle {\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n overflow: hidden;\n overflow-wrap: break-word;\n padding: 5px 0;\n }\n .modalProductDetailsContainer h1 {\n font-weight: 400;\n font-size: 20px;\n line-height: 26px;\n margin: 0;\n }\n .productRetailerContainer {\n display: flex;\n align-items: center;\n gap: 6px;\n }\n .retailerLogo {\n width: 16px;\n height: 16px;\n }\n .formContainer {\n padding: 16px 16px 20px 16px;\n }\n .durationLabel, .priceDropLabel {\n color: var(--text-neutral-foreground-hint);\n }\n fluent-button {\n font-size: 14px;\n }\n fluent-select {\n margin-bottom: 16px;\n max-width: 100%;\n min-width: 100%;\n box-sizing: border-box;\n background-clip: padding-box;\n border: solid 1px transparent;\n }\n fluent-select:before {\n content: "";\n position: absolute;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n z-index: -1;\n margin: -1px;\n border-radius: inherit;\n background: linear-gradient(180deg, #EFEFEF 90%, #D6D6D6 100%), linear-gradient(0deg, #FFFFFF, #FFFFFF);\n }\n fluent-select::part(control) {\n padding: 6px;\n background: #FFF;\n border-radius: 4px;\n }\n fluent-checkbox::part(checked-indicator) {\n background-color: #036AC4;\n fill: #FFFFFF;\n }\n .selectContainer {\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n }\n .priceDropContainer {\n width: 90%;\n padding-right: 6px;\n }\n .durationContainer {\n width: 90%;\n padding-left: 6px;\n }\n .notifyByEmailContainer {\n display: flex;\n align-items: center\n }\n .notifyByEmailContainer > div {\n padding-left: 8px;\n }\n .saveButton {\n width: 100%;\n font-weight: 600;\n margin-top: 16px;\n }\n fluent-dialog::part(control) {\n margin: auto 20px;\n height: auto;\n }\n fluent-dialog::part(positioning-region) {\n z-index: 200;\n }\n '}getDarkModeModalStyles(){return"\n .modalHeading, .modalProductContainer {\n border-bottom: 0.5px solid rgb(236, 236, 236, 0.08);\n }\n fluent-select::part(control) {\n background: #3B3B3B;\n }\n "}getShadowStyles(){return'\n slot[name="switch"] > svg { width: 18.75px; height: 18.75px; }\n slot[name="switch"] { top: -1px; }\n '}getDarkModeShadowStyles(){return"\n "}},this.utilities=n.viewModulesUtilities,this.pageHandlerModule=n.pageHandlerModule,this.logModule=n.logModule,this.productTrackingViewUtilities=new Ju(n,this.flyoutData,t),[4,12,20].forEach((e=>{this.durationOptions.push({textContent:(0,T.fZ)("productTrackingXWeeks",this.flyoutData.strings.productTrackingXWeeks,`${e}`),value:e})})),[5,10,20].forEach((e=>{this.priceDropOptions.push({textContent:(0,T.fZ)("productTrackingPriceDropXPercent",this.flyoutData.strings.productTrackingPriceDropXPercent,`${e}`),value:e})})),this.durationValue=20,this.priceDropValue=5,this.isAlertExpActive=e.R.isExperimentActive(f.H.alertSettings),this.isConciseExpActive=e.R.isExperimentActive(f.H.ptConciseUi),this.telemetryUtilities=n.telemetryHandler}GetModuleName(){return this.isOutOfStock?r.ModuleNames.PRODUCT_TRACKING_OUT_OF_STOCK:r.ModuleNames.PRODUCT_TRACKING_PRICE_DROP}async ShouldRenderModule(){const{common:t}=this.flyoutData,i=Ju.isSupportedDomainForPrice(t.domain,this.flyoutData?.dataStoreModule?.ProductTrackingData,this.flyoutData.common.market),n="true"===(0,h.Mw)("isPDP"),o=this.flyoutData.common.muid??"",r="incognito"===this.flyoutData.common.browseMode,a=this.flyoutData.common.extractedEntity;if(this.isOutOfStock=await this.productTrackingViewUtilities.checkIsOutOfStock(),this.isOutOfStock&&!e.R.isExperimentActive(f.H.ptOutOfStock))return!1;let s;if(this.flyoutData.common.isShorelineOrigination&&(s=this.flyoutData.dataLoader.GetLoadTimeDataValue("price",void 0)?.toString(),!s)){const e=this.flyoutData.dataStoreModule.PriceHistoryData?.DailyPrices;e&&e?.length>0&&(s=e[e.length-1]?.minPrice?.toString())}this.productDetails=this.productTrackingViewUtilities.extractExtractedEntityData(a,this.isOutOfStock,s),!this.productDetails&&this.isOutOfStock&&(this.productDetails=await this.extractOOSProductData());const l=!!a&&!!this.productDetails||this.isOutOfStock,c=this.stateManagement.getState(Ku.IY.isTrackingToggleRendered),d=i&&(l||n)&&!c&&""!==o&&!r;return this.productDetails&&this.setCurrentProduct(this.productDetails),d}PostProcessing(e,t,i){this.stateManagement.addEventListener(Ku.e1.FocusProductTracking,(()=>{i?.scrollIntoView({behavior:"smooth"})}));const n=i.querySelector("#trackingToggle")?.shadowRoot;this.utilities.applyStyles(n,this.assets.getShadowStyles(),void 0,this.assets.getDarkModeShadowStyles())}populateMainHeader(){let e=this.section;e||(e=this.flyoutData.common.shopping?.querySelector(`#${this.productTrackingSectionId}`)),e&&(e.slot="header-content",this.isConciseExpActive&&(e.accordion=!1),this.flyoutData.common.shopping.classList.remove("noPaddingBlock"))}async renderModule(){const{strings:e,common:t}=this.flyoutData,n=t.openedWith===r.Te.Auto;this.isOutOfStock=this.isOutOfStock||n;const o=(0,Y.Ux)("msft-edge-shopping-section",{id:this.productTrackingSectionId});this.section=o,o.accordion=!0,o.expanded=!0,o.titleText=this.isOutOfStock?e.productTrackingTitleAvailability:e.productTrackingTitlePrice;const a=(0,Y.Ux)("div",{className:"productTrackingContainer"+(this.flyoutData.common.isPane?"":" lateralMargin"),id:"price-tracking-section"});if(this.flyoutData.common.isDiscoverPane&&(a.style.backgroundColor=this.utilities.isDarkMode()?"#424242":"#ffffff",a.style.padding="12px 16px"),a.tabIndex=0,this.productDetails?.title){const t=(0,T.fZ)("ptTitle",this.isOutOfStock?e.productTrackingTitleAvailabilityFor:e.productTrackingTitlePriceFor,this.productDetails.title);a.setAttribute("aria-label",t)}const s=(0,Y.Ux)("div",{className:"productTrackingContentContainer"}),l=this.createTrackingText(!1,this.isOutOfStock),c=(0,Y.Ux)("div"),d=(0,Y.Ux)("fluent-switch",{id:"trackingToggle"});d.name=o.titleText,d.title=o.titleText;const u=this.productDetails?.ProductUrl,h=this.productTrackingViewUtilities.getAlertSettingsPrefs(),p=(0,Y.Ux)("div",{className:"trackedStateIconContainer"});p.setAttribute("aria-label","hidden");const g=(0,Y.Ux)("img",{className:"trackedStateIcon"});if(g.src=t.resourcesEndpoint+`productTracking/trackProductInactive${this.isConciseExpActive?"Blue":""}.svg`,g.setAttribute("aria-hidden","true"),this.isConciseExpActive)p.appendChild(g),c.appendChild(d),s.appendChild(p),s.appendChild(l),s.appendChild(c),a.appendChild(s);else{const e=(0,Y.Ux)("img");this.utilities.setImageSrc(e,this.productDetails?.imageUrl??"");const t=this.utilities.createProductImage(60,60,e);p.appendChild(g),t.appendChild(e),t.appendChild(p),c.appendChild(d),s.appendChild(t),s.appendChild(l),s.appendChild(c),a.appendChild(s)}let f;const m=this.productDetails?.currency&&this.productDetails?.price;return await this.productTrackingViewUtilities.GetTrackedProduct(u).then((i=>{d.checked=!!i,this.isOutOfStock?d.title=d.checked?e.productTrackingTitleAvailabilityUnTrack:e.productTrackingTitleAvailability:d.title=d.checked?e.productTrackingTitlePriceUnTrack:e.productTrackingTitlePrice,i&&(g.src=t.resourcesEndpoint+`productTracking/trackProductActive${this.isConciseExpActive?"Blue":""}.svg`),i?.notificationPercentageDrop&&i?.durationInWeeks?(this.priceDropValue=i?.notificationPercentageDrop,this.durationValue=i?.durationInWeeks):(this.priceDropValue=h.priceDropValue??this.priceDropValue,this.durationValue=h.durationValue??this.durationValue),f&&!d.checked&&(f.style.display="none")})).finally((()=>{d.addEventListener("change",(t=>{this.isProductTracked=t.target?.checked,this.isOutOfStock?d.title=this.isProductTracked?e.productTrackingTitleAvailabilityUnTrack:e.productTrackingTitleAvailability:d.title=this.isProductTracked?e.productTrackingTitlePriceUnTrack:e.productTrackingTitlePrice;const i=this.logButtonClickAndGetButtonName(this.isProductTracked);this.productTrackingViewUtilities.recordTrackingToggleChange(i,this.productDetails,this.isProductTracked,this.isOutOfStock,this.getLoggingSource(),this.durationValue,this.priceDropValue),this.productTrackingViewUtilities.sendTrackingData(this.productDetails,this.isProductTracked,this.isOutOfStock,this.durationValue,this.priceDropValue),this.handleProductTrackingChange(this.isProductTracked)}))})),this.isAlertExpActive&&(m||this.isOutOfStock)?(f=(0,Y.Ux)("fluent-button",{className:"alertSettingBtn",href:"#",textContent:e.productTrackingAlertBtnText,style:"border: calc(var(--stroke-width) * 1px) solid transparent; border-color: var(--neutral-stroke-rest);"}),this.createModal(f),f.appearance="outline",f.addEventListener("click",(()=>{let e=i.$S.ProductTrackingTrackPriceAlertSettings;this.isOutOfStock?(e=i.$S.ProductTrackingTrackStockAlertSettings,this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKED_STOCK_SETTINGS)):(e=i.$S.ProductTrackingTrackPriceAlertSettings,this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKED_PRICE_SETTINGS));const t=new W.Z(e,this.telemetryUtilities.setContentViewed(this.GetModuleName()),this.flyoutData.common.domain,JSON.stringify(this.productDetails));this.logModule.LogInfoEvent(i.R.ButtonClick,"Alert button clicked",t),this.modal&&(this.modal.hidden=!1)})),this.isConciseExpActive?(l.appendChild(this.productTrackingViewUtilities.createTrackedProductsText(this.GetModuleName(),this.isConciseExpActive)),a.appendChild(f)):(a.appendChild(f),a.appendChild(this.productTrackingViewUtilities.createTrackedProductsText(this.GetModuleName(),this.isConciseExpActive))),this.modal&&this.flyoutData.common.shopping.appendChild(this.modal)):this.isConciseExpActive?l.appendChild(this.productTrackingViewUtilities.createTrackedProductsText(this.GetModuleName(),this.isConciseExpActive)):a.appendChild(this.productTrackingViewUtilities.createTrackedProductsText(this.GetModuleName(),this.isConciseExpActive)),o.appendChild(a),this.stateManagement.addEventListener(Ku.e1.ProductTrackingUpdate,(async()=>{const e=await this.productTrackingViewUtilities.isTrackedProduct(qu.ZP.GetStrippedUrl(u||""));e!==d.checked&&this.handleProductTrackingChange(e)})),this.isConciseExpActive?this.utilities.applyStyles(o,this.assets.getConciseStyles(),void 0,this.assets.getDarkModeConciseStyles()):this.utilities.applyStyles(o,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),Promise.resolve(this.CreateModule(o,r.H7.PRODUCT_TRACKING,this.GetModuleName(),r.$k.CONTEXTUAL,r.SV.BLOCK))}setCurrentProduct(e){e&&(this.flyoutData.dataStoreModule.ProductTrackingData||(this.flyoutData.dataStoreModule.ProductTrackingData=new ue.Z(void 0)),this.flyoutData.dataStoreModule.ProductTrackingData._currentProduct=e)}async extractOOSProductData(){const e=await this.productTrackingViewUtilities.getOutOfStockData();if(!e)return null;const t=new SS.Z(e.productTitle??"",e.productImage??"",e.currency??"$");return t.price=e.productPrice,t.ProductUrl=this.flyoutData.common.lastCommittedURL,t}createTrackingText(e,t,i=!1){const{strings:n}=this.flyoutData,o=(0,Y.Ux)("div",{className:"productTrackingTextContainer"}),r=(0,Y.Ux)("div",{className:"txtMedium productTrackingText",textContent:this.getTrackingTextTitle(e,t)});return o.appendChild(r),e&&!i&&o.appendChild(this.createSubtitle(this.isConciseExpActive)),i&&this.updateTitle(r,n.productTrackingDescription),o}isOutOfStockNotification(){return this.flyoutData.common.popupOrigination===u.sR.AUTO_PRODUCT_TRACKING_OUT_OF_STOCK}handleProductTrackingChange(e){const t=document.getElementById(this.productTrackingSectionId),i=t?.querySelector(".trackedStateIcon"),n=t?.querySelector(".alertSettingBtn"),{resourcesEndpoint:o}=this.flyoutData.common;i&&(this.isConciseExpActive?i.src=e?o+"productTracking/trackProductActiveBlue.svg":o+"productTracking/trackProductInactiveBlue.svg":i.src=e?o+"productTracking/trackProductActive.svg":o+"productTracking/trackProductInactive.svg"),n&&(n.style.display=e?"inline-flex":"none")}logButtonClickAndGetButtonName(e){return e?this.isOutOfStock?(this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKED_STOCK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_TRACKED_STOCK,this.flyoutData.common.popupOrigination),i.$S.ProductTrackingTrackStock):(this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKED_PRICE),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_TRACKED_PRICE,this.flyoutData.common.popupOrigination),i.$S.ProductTrackingTrackPrice):this.isOutOfStock?(this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKED_STOCK_UNTRACK),i.$S.ProductTrackingUntrackStock):(this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKED_PRICE_UNTRACK),i.$S.ProductTrackingUntrackPrice)}createSubtitle(e){const{strings:t}=this.flyoutData,i=e?t.productTrackingAvailabilitySubtitleConcise:t.productTrackingDescription;return(0,Y.Ux)("div",{className:"productTrackingSubtitle",textContent:i})}updateTitle(e,t){e.textContent=t,e.style.fontSize="16px"}getLoggingSource(){return this.GetModuleName()}getTrackingTextTitle(e,t){const{strings:i}=this.flyoutData;return e?i.productTrackingTitleAvailability:this.isConciseExpActive?t?i.productTrackingDescriptionConcise:i.productTrackingPriceDropTextConcise:t?i.productTrackingDescription:i.productTrackingPriceDropText}createModal(e){const{common:t,strings:i}=this.flyoutData,n=(0,Y.Ux)("fluent-dialog",{className:"productTrackingModal"});n.modal=!0,n.hidden=!0,n.trapFocus=!0;const o=(0,Y.Ux)("div",{className:"modalContainer"});this.utilities.applyStyles(t.shopping,this.assets.getModalStyles(),void 0,this.assets.getDarkModeModalStyles());const a=(0,Y.Ux)("div",{className:"modalHeading"}),s=(0,Y.Ux)("div",{className:"modalTitle txtMedium",textContent:i.productTrackingAlertSetting});a.appendChild(s);const l=(0,Y.Ux)("fluent-button",{className:"closeBtn"});l.innerHTML=this.commonAssets.getCloseButton(),l.appearance="stealth",l.addEventListener("click",(()=>{n.hidden=!0})),a.appendChild(l);const c=(0,Y.Ux)("div",{className:"modalContent"}),d=(0,Y.Ux)("div",{className:"modalProductContainer"}),u=(0,Y.Ux)("div",{className:"modalProductDetailsContainer"}),h=(0,Y.Ux)("h1",{textContent:`${this.productDetails?.currency}${this.productDetails?.price}`}),p=(0,Y.Ux)("div",{className:"productTitle",textContent:this.productDetails?.title}),g=(0,Y.Ux)("div",{className:"productRetailerContainer"}),f=this.productDetails?.ProductUrl&&qu.ZP.getDomainFromUrl(this.productDetails?.ProductUrl),m=(0,Y.Ux)("div",{textContent:f}),v=(0,Y.Ux)("IMG",{className:"retailerLogo"});this.utilities.addFavIconSrc(v,g,this.flyoutData.common.domain),g.appendChild(m);const y=(0,Y.Ux)("div",{className:"formContainer"}),C=(0,Y.Ux)("div",{className:"selectContainer"}),b=(0,Y.Ux)("div",{className:"priceDropContainer"}),S=(0,Y.Ux)("div",{className:"priceDropLabel",textContent:this.flyoutData.strings.phPriceDrop}),x=(0,Y.Ux)("fluent-select");this.priceDropOptions.forEach((({textContent:e,value:t})=>{const i=(0,Y.Ux)("fluent-option",{textContent:e,value:t});t===this.priceDropValue&&i.setAttribute("selected",""),x.appendChild(i)}));const T=(0,Y.Ux)("div",{className:"durationContainer"}),w=(0,Y.Ux)("div",{className:"durationLabel",textContent:this.flyoutData.strings.productTrackingDuration}),O=(0,Y.Ux)("fluent-select");this.durationOptions.forEach((({textContent:e,value:t})=>{const i=(0,Y.Ux)("fluent-option",{textContent:e,value:t});t===this.durationValue&&i.setAttribute("selected",""),O.appendChild(i)}));const P=(0,Y.Ux)("fluent-button",{className:"saveButton",textContent:"Save"});P.appearance="accent",P.addEventListener("click",(()=>{const t=document.getElementById("trackingToggle"),i=t?.checked;if(this.isOutOfStock||(this.priceDropValue=Number(x.getAttribute("current-value"))||5),this.durationValue=Number(O.getAttribute("current-value"))||20,n.hidden=!0,i){this.handleProductTrackingChange(!0);const e=this.logButtonClickAndGetButtonName(i);this.productTrackingViewUtilities.recordTrackingToggleChange(e,this.productDetails,this.isProductTracked,this.isOutOfStock,r.ModuleNames.PRODUCT_TRACKING_ALERT,this.durationValue,this.priceDropValue),this.productTrackingViewUtilities.sendTrackingData(this.productDetails,!0,this.isOutOfStock,this.durationValue,this.priceDropValue)}else t.checked=!0;this.productTrackingViewUtilities.setAlertSettingsPrefs(this.priceDropValue,this.durationValue),e&&e.focus()})),b.appendChild(S),b.appendChild(x),T.appendChild(w),T.appendChild(O),this.isOutOfStock||(C.appendChild(b),u.appendChild(h)),C.appendChild(T),y.appendChild(C),y.appendChild(P),u.appendChild(p),u.appendChild(g),d.appendChild(this.CreateProductImage(80,80)),d.appendChild(u),c.appendChild(d),c.appendChild(y),o.appendChild(a),o.appendChild(c),n.appendChild(o),this.modal=n}CreateProductImage(e,t){const i=(0,Y.Ux)("img");return this.utilities.setImageSrc(i,this.productDetails?.imageUrl??""),this.utilities.createProductImage(e,t,i)}},tk=function(e){return e[e.ButtonWithToggle=1]="ButtonWithToggle",e[e.ButtonNoToggle=2]="ButtonNoToggle",e[e.ButtonNoToggleNoSubtitle=3]="ButtonNoToggleNoSubtitle",e}(tk||{}),ik=class extends ek{constructor(e,t,i,n){super(e,t,i,n),(0,s.Z)(this,"trackedProduct",void 0),(0,s.Z)(this,"flight",void 0),(0,s.Z)(this,"consentSection",void 0),(0,s.Z)(this,"isConsentChecked",!0),(0,s.Z)(this,"roamTimeout",void 0),this.telemetryUtilities=i.telemetryHandler}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION,u.sR.AUTO_PRODUCT_TRACKING_OUT_OF_STOCK]}GetNotificationName(){return this.isOutOfStockNotification()?r.sM.PRODUCT_TRACKING_OUT_OF_STOCK_NOTIFICATION:r.sM.PRODUCT_TRACKING_BACK_IN_STOCK_NOTIFICATION}async ShouldRenderNotification(){const{openedWith:t,popupOrigination:i}=this.flyoutData.common;if(t!==r.Te.Auto)return!1;if(i===u.sR.AUTO_PRODUCT_TRACKING_OUT_OF_STOCK&&!e.R.isExperimentActive(f.H.ptOutOfStock))return!1;if(this.isOutOfStockNotification())return this.productDetails=await this.extractOOSProductData(),!!this.productDetails&&(this.setCurrentProduct(this.productDetails),!0);{const{ProductTrackingNotificationData:e}=this.flyoutData.dataStoreModule,t=!!e&&e.BackInStockProducts?.length>0;return t&&this.setCurrentProduct(e?.BackInStockProducts[0]),i===u.sR.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION&&!!t}}PostProcessingNotification(e,t){e===r.sM.PRODUCT_TRACKING_BACK_IN_STOCK_NOTIFICATION&&(this.productTrackingViewUtilities.ResetOutOfFlowNotificationFrequency(),this.stateManagement.setState(Ku.IY.outOfFlow,u.W5.PRODUCT_TRACKING_BACK_IN_STOCK),this.pageHandlerModule.OnOpenNotification(u.W5.PRODUCT_TRACKING_BACK_IN_STOCK,"","")),this.isOutOfStockNotification()||this.productTrackingViewUtilities.LogProductNotification(this.flyoutData.common.muid,this.trackedProduct?.ProductUrl)}async RenderNotification(){if(this.flyoutData.common.shopping.classList.add("noSections"),this.pageHandlerModule.TriggerExperiment(f.H.PCOutOfStock),this.isOutOfStockNotification()){if(e.R.isExperimentActive(f.H.PCOutOfStock)){const e=this.flyoutData?.common?.extractedEntity,t=e?.title,i=e?.image_url||e?.entity?.image,n=this.flyoutData?.dataStoreModule?.PriceComparisonData?.CompetingPrices,o=n&&n.length>0;if(t&&i&&o){const e=Q(n);if(e){if(this.productDetails){const e=this.productDetails,t=new SS.Z(e.title,e.imageUrl??"",e.currency);t.ProductUrl=e?.ProductUrl,t.price=e?.price?.toString()??"";const i=await this.productTrackingViewUtilities.createTrackingToggleSection(t,!0,this.GetNotificationName(),!0);i&&this.flyoutData.common.shopping.appendChild(i)}const t=X(e,this.flyoutData.strings,this.utilities.getFavIconSrc(e.Domain,24),this.flyoutData.common.resourcesEndpoint+"priceComparison/adSlug.png",this.flyoutData.common.isPaneEnabled&&n.length>1,this.utilities.formatPrice.bind(this.utilities),J.bind(this,e),this.handleSeeMoreOffersClick.bind(this)),i=this.utilities.createNotificationModule(t,this.GetNotificationName(),this);return Promise.resolve(i)}}}const t=parseInt(e.R.getServiceExperimentValue(f.H.PTOutOfStockVariations)??"",10);Number.isNaN(t)||(this.flight=t);const i=await this.renderOOSNotification();return this.utilities.createNotificationModule(i,this.GetNotificationName(),this)}{const{ProductTrackingNotificationData:e}=this.flyoutData.dataStoreModule;if(!e||e.TrackedProducts?.length<=0)return null;if(this.trackedProduct=e.TrackedProducts[0],!this.trackedProduct)return null;const t=await this.renderBackInStockNotification();return t.classList.add("lateralMargin"),this.utilities.applyStyles(t,this.assets.getNotificationStyles(),void 0,this.assets.getDarkModeStyles()),t.slot="header-content",t.title=this.trackedProduct.Title,this.utilities.createNotificationModule(t,this.GetNotificationName(),this)}}async renderBackInStockNotification(){if(e.R.isExperimentActive(f.H.ptNotifications)&&e.R.getServiceExperimentValue(f.H.ptNotifications)==Yu.cO.NewDesign)return this.renderBackInStockNotificationV2();const{strings:t,common:n}=this.flyoutData,o=(0,Y.Ux)("div",{className:"productTrackingInStockContainer"}),r=(0,Y.Ux)("div",{className:"productDetailsContainer"}),a=(0,Y.Ux)("div",{className:"productText"}),s=(0,Y.Ux)("span",{className:"backInStockText",textContent:t.productTrackingBackInStockText}),l=(0,Y.Ux)("div",{className:"productTrackingRetailerText",textContent:qu.ZP.getDomainFromUrl(this.trackedProduct?.ProductUrl)}),c=(0,Y.Ux)("img");l.append(c);const d=(0,Y.Ux)("span",{className:"txtSmall",textContent:`${this.trackedProduct?.CurrencySymbol??"$"}${this.trackedProduct?.CurrentPrice}`}),u=(0,Y.Ux)("img"),h=this.flyoutData.common.resourcesEndpoint+"common/unknowProductImage.png";this.utilities.setImageSrc(u,this.trackedProduct?.ImageUrl,h),u.alt=this.trackedProduct.Title;const p=this.utilities.createProductImage(72,72,u),g=(0,Y.Ux)("fluent-button",{className:"viewItemBtn",textContent:t.productTrackingViewItem});g.title=t.productTrackingViewItem,g.appearance="accent",g.addEventListener("click",(()=>{const e=new W.Z(i.$S.ProductTrackingBackInStockVisitItem,this.telemetryUtilities.setContentViewed(this.GetModuleName()),n.domain,JSON.stringify(this.trackedProduct));if(this.logModule.LogInfoEvent(i.R.ButtonClick,this.trackedProduct?.ProductUrl,e),this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKING_PRODUCT_NOTIFICATION_CLICK),this.trackedProduct?.ProductUrl){const e=`${this.trackedProduct?.ProductUrl}?${qu.Jm}`;this.pageHandlerModule.NavigateToUrl(e)}}));const m=this.trackedProduct,v=new SS.Z(m.Title,m.imageUrl??"",m.CurrencySymbol);v.ProductUrl=m?.ProductUrl,v.price=m?.basePrice?.toString()??"";const y=await this.productTrackingViewUtilities.createTrackingToggleSection(v,!0,this.GetNotificationName());return r.appendChild(a),r.appendChild(p),a.appendChild(s),a.appendChild(l),a.appendChild(d),o.appendChild(r),o.appendChild(g),y&&o.appendChild(y),o}async renderBackInStockNotificationV2(){const{common:e}=this.flyoutData,t=(0,Y.Ux)("div",{className:"productTrackingInStockContainer"}),n=(0,Y.Ux)("div",{className:"productDetailsContainer"}),o=(0,Y.Ux)("div",{className:"productText"}),r=(0,Y.Ux)("span",{className:"backInStockText",textContent:"Back in stock",style:"font-size: 16px; color:#138757"}),a=(0,Y.Ux)("div",{className:"productTrackingRetailerText",textContent:qu.ZP.getDomainFromUrl(this.trackedProduct?.ProductUrl)}),s=(0,Y.Ux)("img");a.append(s);const l=this.trackedProduct.sellerName,c="Your tracked product is now\navailable at "+l+" ",d=(0,Y.Ux)("div",{className:"txtSmall",textContent:c,style:"font-weight: 400; margin-top: 5px; white-space: pre-wrap; font-size: 14px;line-height: 20px; text-align: left; color: var(--text-normal);"}),u=(0,Y.Ux)("img"),h=this.flyoutData.common.resourcesEndpoint+"common/unknowProductImage.png";this.utilities.setImageSrc(u,this.trackedProduct?.ImageUrl,h),u.alt=this.trackedProduct.Title;const p=this.utilities.createProductImage(62,62,u),g=(0,Y.Ux)("fluent-button",{className:"viewItemBtn",textContent:"Shop on "+l});g.title="Shop on "+l,g.appearance="accent",g.addEventListener("click",(()=>{const t=new W.Z(i.$S.ProductTrackingBackInStockVisitItem,this.telemetryUtilities.setContentViewed(this.GetModuleName()),e.domain,JSON.stringify(this.trackedProduct));if(this.logModule.LogInfoEvent(i.R.ButtonClick,this.trackedProduct?.ProductUrl,t),this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKING_PRODUCT_NOTIFICATION_CLICK),this.trackedProduct?.ProductUrl){const e=`${this.trackedProduct?.ProductUrl}?${qu.Jm}`;this.pageHandlerModule.NavigateToUrl(e)}}));const f=(0,Y.Ux)("img");f.className="retailerIconPrice",f.src=this.utilities.getFavIconSrc(this.trackedProduct.domain||"",18);const m=(0,Y.Ux)("div",{style:"display: inline-block; min-height: 18px; min-width: 18px; width: 18px; height: 18px; position: relative;top: 4px;"});m.appendChild(f),d.appendChild(m);const v=this.trackedProduct,y=new SS.Z(v.Title,v.imageUrl??"",v.CurrencySymbol);y.ProductUrl=v?.ProductUrl,y.price=v?.basePrice?.toString()??"";const C=await this.productTrackingViewUtilities.createTrackingToggleSection(y,!0,this.GetNotificationName());return n.appendChild(o),n.appendChild(p),o.appendChild(r),o.appendChild(d),t.appendChild(n),C&&t.appendChild(C),t.appendChild(g),t}handleSeeMoreOffersClick(){const e=new W.Z(i.$S.SeeMoreOffers,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"Click on see more offers",e),this.pageHandlerModule.OpenPane(this.flyoutData.common.popupOrigination)}async renderOOSNotification(){const{strings:e,common:t}=this.flyoutData,i=e.productTrackingTitleAvailability,n=(0,Y.Ux)("div",{className:"productTrackingContainer oosNotification",id:this.productTrackingSectionId});if(n.tabIndex=0,this.productDetails?.title){const t=(0,T.fZ)("ptTitle",e.productTrackingTitleAvailabilityFor,this.productDetails.title);n.setAttribute("aria-label",t)}const o=(0,Y.Ux)("div",{className:"productTrackingContentContainer"}),a=this.flight===tk.ButtonNoToggleNoSubtitle,s=this.createTrackingText(!0,this.isOutOfStock,a),l=(0,Y.Ux)("div",{className:"trackingToggleContainer"}),c=(0,Y.Ux)("fluent-switch",{id:"trackingToggle"});c.name=i,c.title=i,c.addEventListener("change",(e=>{this.isProductTracked=e.target?.checked,this.toggleConsentSection(this.isProductTracked);const t=this.logOOSButtonClickAndGetButtonName(this.isProductTracked);this.productTrackingViewUtilities.recordTrackingToggleChange(t,this.productDetails,this.isProductTracked,!0,r.sM.PRODUCT_TRACKING_OUT_OF_STOCK_NOTIFICATION),this.productTrackingViewUtilities.sendTrackingData(this.productDetails,this.isProductTracked,!0),this.handleProductTrackingChange(this.isProductTracked)}));const d=(0,Y.Ux)("div",{className:"trackedStateIconContainer"});d.setAttribute("aria-label","hidden");const u=(0,Y.Ux)("img",{className:"trackedStateIcon"});if(u.src=t.resourcesEndpoint+`productTracking/trackProductInactive${this.isConciseExpActive?"Blue":""}.svg`,u.setAttribute("aria-hidden","true"),this.isConciseExpActive)d.appendChild(u),l.appendChild(c),o.appendChild(d),o.appendChild(s),n.appendChild(o),o.appendChild(l);else{const t=(0,Y.Ux)("img");this.utilities.setImageSrc(t,this.productDetails?.imageUrl??"");const i=this.utilities.createProductImage(60,60,t);if(d.appendChild(u),i.appendChild(t),i.appendChild(d),o.appendChild(i),o.appendChild(s),l.appendChild(c),o.appendChild(l),[tk.ButtonNoToggle,tk.ButtonNoToggleNoSubtitle].includes(this.flight)&&l.classList.add("hidden"),n.appendChild(o),this.flight){const t=tk.ButtonNoToggleNoSubtitle?e.productTrackingNotificationTrackProduct:e.productTrackingNotificationOk,i=(0,Y.Ux)("fluent-button",{appearance:"accent",className:"ptTrackButton",textContent:t,title:t});i.setAttribute("aria-label",t),i.addEventListener("click",(()=>{this.isProductTracked=!0;const e=this.logOOSButtonClickAndGetButtonName(this.isProductTracked);this.productTrackingViewUtilities.recordTrackingToggleChange(e,this.productDetails,this.isProductTracked,!0,r.sM.PRODUCT_TRACKING_OUT_OF_STOCK_NOTIFICATION),this.handleProductTrackingChange(this.isProductTracked),c.checked=this.isProductTracked,this.pageHandlerModule.DismissPopup()})),n.appendChild(i)}}return this.shouldShowConsentBanner().then((e=>{if(!e)return;const t=this.createConsentSection();this.consentSection=t,n.appendChild(t)})),this.utilities.applyStyles(n,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),this.isConciseExpActive?this.utilities.applyStyles(n,this.assets.getConciseStyles(),void 0,this.assets.getDarkModeConciseStyles()):this.utilities.applyStyles(n,this.assets.getNotificationStyles(),void 0,this.assets.getDarkModeStyles()),Promise.resolve(n)}async shouldShowConsentBanner(){return this.productTrackingViewUtilities.AnidTrackingAvailable()?this.productTrackingViewUtilities.anidLoggedInHasTrackedProductsButNotExplicitlyConsented():Promise.resolve(!1)}toggleConsentSection(e){const t=this.consentSection??document.querySelector(".consentSection");t&&(e?(this.roamTimeout=setTimeout((()=>{this.isConsentChecked&&this.productTrackingViewUtilities.RoamProductsFromEndpoint()}),4e3),t?.classList.remove("hidden")):t?.classList.add("hidden"),this.resizeFlyout())}createConsentSection(){const{strings:e,common:t}=this.flyoutData,n=(0,Y.Ux)("div",{className:"consentSection hidden"}),o=(0,Y.Ux)("hr",{className:"divider"}),r=(0,Y.Ux)("div",{className:"consentContainer",style:"display"}),a=(0,Y.Ux)("fluent-checkbox",{className:"consentCheckbox"});a.name=e.productTrackingNotificationEmailText,a.title=e.productTrackingNotificationEmailText,a.checked=!0,a.setAttribute("aria-labelledby","consentText"),a.addEventListener("change",(e=>{const n=new W.Z(i.$S.ProductTrackingOutOfStockConsentClose,this.telemetryUtilities.setContentViewed(this.GetModuleName()),t.domain);this.logModule.LogInfoEvent(i.R.ButtonClick,this.trackedProduct?.ProductUrl,n),this.isConsentChecked=e.target?.checked,!this.isConsentChecked&&this.roamTimeout?clearTimeout(this.roamTimeout):this.productTrackingViewUtilities.RoamProductsFromEndpoint()}));const s=(0,Y.Ux)("span",{className:"consentText",id:"consentText",textContent:e.productTrackingNotificationEmailText}),l=(0,Y.Ux)("div",{className:"privacyText"}),c=(0,Y.Ux)("fluent-anchor",{href:T.Sk,target:"_blank",rel:"noopener noreferrer",appearance:"hypertext",textContent:e.productTrackingNotificationSeeTerms});return l.appendChild(c),(0,T.B7)(l,e.productTrackingNotificationTooltipText,c),r.appendChild(a),r.appendChild(s),n.appendChild(o),n.appendChild(l),n.appendChild(r),n}logOOSButtonClickAndGetButtonName(e){return e?(this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKED_STOCK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_TRACKED_STOCK,this.flyoutData.common.popupOrigination),i.$S.ProductTrackingTrackStock):(this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKED_STOCK_UNTRACK),i.$S.ProductTrackingUntrackStock)}resizeFlyout(){const e=document.querySelector("#divContentWrapper");this.pageHandlerModule.ResizeIframe({offsetHeight:e?.offsetHeight,scrollHeight:e?.scrollHeight})}},nk=class extends Qu{constructor(e,t){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"isChinaApi",void 0),(0,s.Z)(this,"isTrendingRec",void 0),(0,s.Z)(this,"searchSuggestions",void 0),(0,s.Z)(this,"isSearchBasedSuggestions",void 0),(0,s.Z)(this,"dataValidationUtilities",void 0),(0,s.Z)(this,"couponDataRecommendations",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),this.flyoutData=e,this.utilities=t.viewModulesUtilities,this.pageHandlerModule=t.pageHandlerModule,this.logModule=t.logModule,this.dataValidationUtilities=t.dataValidationUtilities,this.assets=new class{getStyles(){return"\n #recommendationsDiv img {\n width: auto;\n max-width: calc(100% - 10px);\n }\n #divRecommendationWrapper {\n display: grid;\n grid-template-columns: Calc(50% - 8px) Calc(50% - 8px);\n column-gap: 16px;\n row-gap: 12px;\n padding: 0 12px 0;\n }\n #seeAllBottom {\n margin-top: -10px;\n display: flex;\n color: #0078D4;\n font-size: 12px;\n font-weight: 500;\n }\n fluent-button#seeAllBottom::part(control) {\n background: transparent;\n }"}getDarkModeStyles(){return"\n #seeAllBottom {\n color: #6bbfff;\n }"}getNotificationStyles(){return"\n msft-edge-shopping::part(header) {\n margin-top: 0px;\n }\n #notification {\n display: flex;\n flex-direction: column;\n row-gap: 12px;\n }\n #header {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-style: normal;\n font-weight: 600;\n font-size: 18px;\n line-height: 26px;\n text-align: center;\n color: var(--text-normal);\n margin: 0px;\n }\n #subtitle {\n font-style: normal;\n font-weight: 400;\n font-size: 12px;\n line-height: 16px;\n text-align: center;\n margin: 0px;\n }\n "}getNotificationDarkModeStyles(){return"\n "}},this.isChinaApi=!1,this.isTrendingRec=this.isTrendingRecActive(),this.couponDataRecommendations=this.flyoutData?.dataStoreModule?.CouponData?.Recommendations?.filter((e=>e.imageUrl))??[],this.telemetryUtilities=t.telemetryHandler}GetModuleName(){return r.ModuleNames.RECOMMENDATIONS}async ShouldRenderModule(){const e=await this.hasRecommendations();return this.isChinaApi=["jd.com","cn.jd.com","global.jd.com","suning.com"].includes(this.flyoutData?.common?.domain),Promise.resolve(e)}populateMainHeader(){let e;if(e=this.flyoutData.common.isPane&&this.couponDataRecommendations.length>0&&this.couponDataRecommendations[0]?.isTrendingOffer?this.flyoutData.common.shoppingPersistent:this.flyoutData.common.shopping,e&&(this.flyoutData.dataStoreModule.CouponData&&this.couponDataRecommendations.length>0||this.isSearchBasedSuggestions)){const t=(0,Y.Ux)("H2");t.className="txtLarge",t.style.textAlign="center",t.style.fontWeight="500",t.style.marginBottom="12px";const i=this.isSearchBasedSuggestions?this.searchSuggestions:this.couponDataRecommendations;let n="recommendationsFriendlyDomainTitle",o=this.flyoutData.strings.recommendationsFriendlyDomainTitle;this.isSearchBasedSuggestions?(n="recommendationsSSATitle",o=this.flyoutData.strings.recommendationsSSATitle):i&&i.length>=5&&parseFloat(i[4].discountPercentage)>0&&(n="recommendationsFriendlyDomainTitlePriceDrops",o=this.flyoutData.strings.recommendationsFriendlyDomainTitlePriceDrops);const r=this.flyoutData.dataStoreModule.CouponData?.FriendlyDomainName?(0,T.fZ)(n,o,this.flyoutData.dataStoreModule.CouponData?.FriendlyDomainName):this.flyoutData.strings.recommendationsTitle;t.textContent=r,t.slot="header-content",e.appendChild(t)}}renderModule(){this.flyoutData.common.isPane&&this.couponDataRecommendations.length>0&&this.couponDataRecommendations[0]?.isTrendingOffer?this.utilities.applyStyles(this.flyoutData.common.shoppingPersistent,this.assets.getStyles()):this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());const e=(0,Y.Ux)("msft-edge-shopping-section");e.id="recommendationsDiv",this.isSearchBasedSuggestions&&(e.className="searchBasedSuggestions");const t=this.isSearchBasedSuggestions?this.searchSuggestions:this.couponDataRecommendations;if(t){let i="recommendationsFriendlyDomainTitle",n=this.flyoutData.strings.recommendationsFriendlyDomainTitle;this.isSearchBasedSuggestions?(i="recommendationsSSATitle",n=this.flyoutData.strings.recommendationsSSATitle):t.length>=5&&parseFloat(t[4].discountPercentage)>0&&(i="recommendationsFriendlyDomainTitlePriceDrops",n=this.flyoutData.strings.recommendationsFriendlyDomainTitlePriceDrops);const o=this.flyoutData.dataStoreModule.CouponData?.FriendlyDomainName?(0,T.fZ)(i,n,this.flyoutData.dataStoreModule.CouponData?.FriendlyDomainName):this.isTrendingRec?(0,T.fZ)("trendingRecSectionTitle",this.flyoutData.strings.trendingRecSectionTitle,this.flyoutData.dataStoreModule.CouponData?.FriendlyDomainName??this.flyoutData.common.domain):this.flyoutData.strings.recommendationsTitle;this.populateRecommendationsList(e,!1,!1);const a=this.flyoutData,s=this.isSearchBasedSuggestions?r.CS.SEARCH_SUGGESTIONS:r.CS.RECOMMENDATIONS;function l(e){let t=s;return e&&a.common.bannerContext===r.De.VIEWALL&&(t=e.length),t}this.utilities.createCommonListStructure(e,o,t,this.GetModuleName(),l,this.populateRecommendationsList.bind(this))}return Promise.resolve(this.CreateModule(e,r.H7.RECOMMENDATIONS,r.ModuleNames.RECOMMENDATIONS,r.$k.CONTEXTUAL,r.SV.SQUARES))}async hasRecommendations(){if(this.utilities.isSearchPage()&&e.R.isExperimentActive(f.H.searchFeature)&&this.flyoutData.dataStoreModule.IsSSAEnabled)try{const e={Url:this.flyoutData.common.lastCommittedURL},t={body:JSON.stringify(e),headers:{"Content-Type":"application/json"},method:"POST"},i="https://www.bing.com/api/shopping/v1/savings/productsearch",n=await fetch(i,t),o=await n.json();this.searchSuggestions=o.recommendations}catch{}return this.searchSuggestions?.length>0?(this.isSearchBasedSuggestions=!0,!0):this.couponDataRecommendations.length>0}populateRecommendationsList(e,t,n){const o=this.isSearchBasedSuggestions?this.searchSuggestions:this.couponDataRecommendations;if(o){let i=0;o.length>0&&(i=o.length);let a=0;const s=this.isSearchBasedSuggestions?r.CS.SEARCH_SUGGESTIONS:r.CS.RECOMMENDATIONS;t?a=s:i>s&&(i=s);let l=null;t?l=e.querySelector("#divRecommendationWrapper"):(l=(0,Y.Ux)("DIV"),l.id="divRecommendationWrapper"),this.flyoutData.common.isPane&&l&&(l.style.padding="0px 20px 12px");for(let s=a;s<i;s++){const i=o[s],c=this.createRecommendationTile(i);l?(l.appendChild(c),t||e.appendChild(l)):e.appendChild(c),s===a&&t&&n&&this.flyoutData.common.currentDevice===r.AS.Desktop&&c&&c.focus()}(l?.children.length??0)%2!=0&&this.isSearchBasedSuggestions&&l?.lastChild?.remove()}if(t&&(this.isChinaApi||this.isSearchBasedSuggestions)){const t=(0,Y.Ux)("fluent-button");let n,o;t.textContent=this.flyoutData.strings.commonSeeAll,t.id="seeAllBottom",t.appearance="lightweight",this.isChinaApi?(n=this.flyoutData.common.domain.includes("jd.com")?"https://miaosha.jd.com/":"https://qiang.suning.com/pc/brandBenefits.html",o="Clicked on see all trending deals"):this.isSearchBasedSuggestions&&(n="https://www.bing.com/shop",o="Clicked on see all search based suggestions"),t.addEventListener("click",(()=>{this.pageHandlerModule.RecordAsUserAction(K.bS.SEE_ALL_TRENDING_DEALS);const e=new W.Z(i.$S.SeeAllTrendingDeals,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,o,e),this.pageHandlerModule.NavigateToCouponPage(n)}));const r=e.children.length;e.insertBefore(t,e.children[r-1])}}createRecommendationTile(e){const t=(0,Y.Ux)("msft-shopping-recommendation");t.ariaRoledescription="button",t.titleText=e.title,t.currentPrice=e.newPrice,e.originalPrice&&e.originalPrice!==e.newPrice&&(t.originalPrice=e.originalPrice);let i="",n=e.discountPercentage??e.priceDropPercentage??"";n=n.includes("%")?n:n+"%",e.discountPercentage||e.priceDropPercentage?i=(0,T.fZ)("recommendationsDiscountPercent",this.flyoutData.strings.recommendationsDiscountPercent,n):e.shippingText&&(i="free shipping"===e?.shippingText?.toLocaleLowerCase()?e?.shippingText:""),""!==i&&(t.dealPercentage=i,t.ariaLabel=i),this.isChinaApi&&(t.useAltColors=!0);const o=(0,Y.Ux)("img");o.onerror=()=>{t.style.display="none"},o.src=this.isSearchBasedSuggestions?e.imageUrl:this.isChinaApi?(0,T.uf)(this.flyoutData.common.market,this.flyoutData.common.exclusiveMarket).includes("-cn")?"https://ts1.cn.mm.bing.net/th?id="+e.imageUrl:"https://th.bing.com/th?id="+e.imageUrl:this.flyoutData.common.urlPrefix+"https://www.bing.com"+e.imageUrl;const r=this.utilities.createProductImage(150,154,o,void 0,!0);return r.slot="image",t.append(r),this.manageRecommendationsLinkEvents(t,e?.id,e?.offerUrl),t.setAttribute("title",`${e.title} ${i}`),t}isTrendingRecActive(){if(this.pageHandlerModule.TriggerExperiment(f.H.trendingRecommendations),e.R.isExperimentActive(f.H.trendingRecommendations)){const t=e.R.getMultipleVariants(f.H.trendingRecommendations);if(2===t?.length)try{let e,i;for(const n of t)"startDate"===n.key?e=new Date(n.value):"endDate"===n.key&&(i=new Date(n.value));const n=new Date;return!!e&&!!i&&n>=e&&n<=i}catch(e){return!0}return!0}return!1}manageRecommendationsLinkEvents(e,t,i){e.addEventListener("click",(()=>{this.dataValidationUtilities.writeValidationDataToStorage(e.getAttribute("currentprice"),e.getAttribute("title"),this.GetModuleName(),i),this.navigateToOffer(t,i,ju.$.NEW_FOREGROUND_TAB)})),e.addEventListener("mousedown",(n=>{1===n.button&&(this.dataValidationUtilities.writeValidationDataToStorage(e.getAttribute("currentprice"),e.getAttribute("title"),this.GetModuleName(),i),this.navigateToOffer(t,i,ju.$.NEW_FOREGROUND_TAB))}))}navigateToOffer(e,t,n){let o=K.bS.NAVIGATE_TO_RECOMMENDATION_OFFER,r=q.FV.NAVIGATE_TO_RECOMMENDATION_OFFER,a="Clicked on recommended offer";this.isChinaApi?(o=K.bS.NAVIGATE_TO_TRENDING_DEAL,r=q.FV.NAVIGATE_TO_TRENDING_DEAL,a="Clicked on China deals recommended offer"):this.isSearchBasedSuggestions&&(a="Clicked on search based suggestion"),this.pageHandlerModule.RecordAsUserAction(o),this.pageHandlerModule.RecordAsUserEngagement(r,this.flyoutData.common.popupOrigination);const s=new W.Z(i.$S.NavigateToRecommendedDeal,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,a,s),this.pageHandlerModule.NavigateToRecommendationWithDisposition(e,t,n)}},ok=class extends nk{GetPopupOriginationList(){return[u.sR.AUTO_SHOW_RECOMMENDATIONS]}PostProcessingNotification(e,t){}async RenderNotification(){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getNotificationStyles(),void 0,this.assets.getNotificationDarkModeStyles());const e=this.createRecommendationsNotification();return Promise.resolve(this.utilities.createNotificationModule(e,this.GetNotificationName(),this))}async ShouldRenderNotification(){this.isTrendingRec=this.isTrendingRecActive();const e=await this.hasRecommendations(),t=this.flyoutData.common.openedWith===r.Te.Auto&&this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_RECOMMENDATIONS;return Promise.resolve(e&&t&&this.isTrendingRec)}GetNotificationName(){return r.sM.RECOMMENDATION}createRecommendationsNotification(){const e=(0,Y.Ux)("div");e.id="notification",e.className="lateralMargin";const t=(0,Y.Ux)("h2");t.id="header",t.setAttribute("role","heading");const n=this.flyoutData.dataStoreModule.CouponData?.FriendlyDomainName??this.flyoutData.common.domain;t.textContent=(0,T.fZ)("trendingRecHeader",this.flyoutData.strings.trendingRecHeader,n);const o=(0,Y.Ux)("p");o.id="subtitle",o.textContent=this.flyoutData.strings.trendingRecSubtitle;const r=(0,Y.lw)(this.utilities);return r.textContent=this.flyoutData.strings.trendingRecButton,r.addEventListener("click",(e=>{(0,T.pq)(e)&&(0,h.Xo)("trendingRecOpen","true"),(0,h.Xo)(tt.d1,"true"),this.pageHandlerModule.RecordAsUserAction(K.bS.SEE_ALL_TRENDING_DEALS);const t=new W.Z(i.$S.RecommendationsViewPriceDrop,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,`Clicked on view price drops for ${this.flyoutData.common.domain}`,t),this.pageHandlerModule.OpenPane(this.flyoutData.common.popupOrigination)})),e.append(t),e.append(o),e.append(r),e}},rk=class extends Qu{constructor(e,t,i){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"rewardApplied",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pointsToAllocate",void 0),(0,s.Z)(this,"maxSupportedDomains",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"localStorageKeyRewardMap","rewardMap"),(0,s.Z)(this,"localStorageKeyRewardPoints","rewardPoints"),(0,s.Z)(this,"localStorageKeyDomainCount","domainCount"),this.pageHandlerModule=t.pageHandlerModule,this.flyoutData=e,this.utilities=t.viewModulesUtilities,this.assets=new class{getStyles(){return`\n .divRewardWrapper {\n width: 336px;\n height: auto;\n background: rgba(0, 120, 212, 0.05);\n border: 1px solid rgba(250, 181, 39, 0.12);\n box-sizing: border-box;\n border-radius: 4px;\n }\n .divRewardsHeader {\n display: grid;\n grid-template-columns: auto auto;\n margin: 12px;\n }\n .divRewardTitle {\n width: 100%;\n height: auto;\n font-family: Segoe UI;\n font-size: 16px;\n font-weight: 600;\n line-height: 22px;\n display: flex;\n align-items: center;\n justify-content: flex-start;\n color: rgba(0, 0, 0, 0.83);\n }\n .divRewardPointSection {\n width: auto;\n height: auto;\n font-family: Segoe UI;\n font-size: 12px;\n font-weight: 600;\n line-height: 16px;\n display: flex;\n justify-content: flex-end;\n align-items: center;\n color: rgba(0, 0, 0, 0.83);\n }\n .divRewardPoint {\n width: auto;\n text-align: right;\n margin-right: 5px;\n }\n .divRewardPointIcon {\n width: 12px;\n height: 12px;\n float:right;\n place-self: center;\n }\n .divRewardDetailsSection {\n height: auto;\n margin: 12px;\n text-align: start;\n font-family: Segoe UI;\n font-size: 12px;\n line-height: 16px;\n color: #333333;\n }\n .divRewardAdditionalLink {\n margin-top: 5px;\n height: auto;\n width: auto;\n display: block;\n }\n .divRewardFailedSignIn {\n width: 100%;\n height: auto;\n font-family: Segoe UI;\n font-size: 16px;\n line-height: 20px;\n justify-content: center;\n display: grid;\n margin-bottom: 10px;\n grid-template-columns: auto auto;\n }\n .divRewardErrorIcon {\n place-self: center;\n margin-right: 5px;\n }\n .divRewardIconSet {\n display: grid;\n grid-template-columns: auto auto auto;\n width: 93%;\n height: auto;\n margin-left: 12px;\n font-family: Segoe UI;\n font-size: 14px;\n font-weight: 600;\n line-height: 25px;\n }\n .divIconSection {\n display: grid;\n grid-template-columns: auto auto;\n width: auto;\n height: auto;\n }\n .detailLink {\n vertical-align: super;\n height: auto;\n }\n .detailLink {\n vertical-align: super;\n height: auto;\n font-weight: 500;\n }\n .tailString {\n display: inline;\n }\n #rewardButtonLearnMore {\n margin-bottom: 12px;\n margin-left: 11px;\n width: 93%;\n height: 32px;\n }\n #accordionItem {\n margin-top: 0px;\n margin-bottom: 0px;\n }\n #titleRewardTwo {\n font-size: 20px;\n line-height: 28px;\n margin-left: 12px;\n }\n #detailRewardTwo {\n font-size: 14px;\n line-height: 20px;\n }\n @media (forced-colors: active) {\n .divRewardWrapper {\n background: ${Ns.Highlight};\n }\n .divRewardTitle,\n .divRewardPointSection {\n color: ${Ns.CanvasText};\n }\n .cupIcon {\n fill: ${Ns.CanvasText};\n }\n }`}getDarkModeStyles(){return"\n .divRewardDetailsSection {\n color: #FFFFFF;\n }\n .divRewardWrapper {\n background: linear-gradient(0deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.08)), rgba(0, 120, 212, 0.1);\n }\n .divRewardTitle,\n .divRewardPointSection {\n color: #FFFFFF;\n }\n .cupIcon {\n fill: #FFFFFF;\n }\n "}getCupIcon(){return eh.Z.getTrustedHTML`<svg class="cupIcon" width="12" height="12" viewBox="0 0 12 12" aria-hidden="true" fill="black" xmlns="http://www.w3.org/2000/svg">
<path d="M1.5 0C0.671573 0 0 0.671573 0 1.5V2.69253C0 3.21234 0.26912 3.6951 0.711267 3.96843L4.57713 6.35823C3.63807 6.86508 3 7.85803 3 9C3 10.6569 4.34315 12 6 12C7.65685 12 9 10.6569 9 9C9 7.85803 8.36193 6.86508 7.42287 6.35823L11.2887 3.96843C11.7309 3.6951 12 3.21234 12 2.69253V1.5C12 0.671573 11.3284 0 10.5 0H1.5ZM4 4.82581V1H8V4.82581L6.26291 5.89965C6.10179 5.99925 5.89821 5.99925 5.73709 5.89965L4 4.82581ZM6 7C7.10457 7 8 7.89543 8 9C8 10.1046 7.10457 11 6 11C4.89543 11 4 10.1046 4 9C4 7.89543 4.89543 7 6 7Z" fill-opacity="0.83"/>
</svg>`}getErrorCircleIcon(){return eh.Z.getTrustedHTML`<svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M8 0C12.4183 0 16 3.58172 16 8C16 12.4183 12.4183 16 8 16C3.58172 16 0 12.4183 0 8C0 3.58172 3.58172 0 8 0ZM8 1C4.13401 1 1 4.13401 1 8C1 11.866 4.13401 15 8 15C11.866 15 15 11.866 15 8C15 4.13401 11.866 1 8 1ZM8 10.5C8.41421 10.5 8.75 10.8358 8.75 11.25C8.75 11.6642 8.41421 12 8 12C7.58579 12 7.25 11.6642 7.25 11.25C7.25 10.8358 7.58579 10.5 8 10.5ZM8 4C8.24546 4 8.44961 4.17688 8.49194 4.41012L8.5 4.5V9C8.5 9.27614 8.27614 9.5 8 9.5C7.75454 9.5 7.55039 9.32312 7.50806 9.08988L7.5 9V4.5C7.5 4.22386 7.72386 4 8 4Z" fill="#C42B1C"/>
</svg>`}getCouponIcon(){return eh.Z.getTrustedHTML`<svg width="28" height="28" viewBox="0 0 28 28" fill="none" xmlns="http://www.w3.org/2000/svg">
<circle cx="14" cy="14" r="14" fill="#E0EFFA"/>
<path d="M16.6731 6.95142C16.0191 6.29744 14.9588 6.29744 14.3048 6.95142L6.95239 14.3038C6.29842 14.9578 6.29842 16.0181 6.95239 16.6721L7.82433 17.544C8.20443 17.9241 8.73798 17.8561 9.06037 17.6644C9.1988 17.5821 9.36033 17.5347 9.53463 17.5347C10.0484 17.5347 10.465 17.9513 10.465 18.465C10.465 18.6394 10.4176 18.8009 10.3353 18.9394C10.1436 19.2617 10.0756 19.7953 10.4557 20.1754L11.3277 21.0474C11.9817 21.7014 13.042 21.7014 13.696 21.0474L21.0483 13.695C21.7023 13.041 21.7023 11.9807 21.0483 11.3267L20.1764 10.4548C19.7963 10.0746 19.2626 10.1427 18.9402 10.3344C18.8018 10.4167 18.6402 10.4642 18.4659 10.4642C17.952 10.4642 17.5355 10.0476 17.5355 9.53383C17.5355 9.35949 17.5829 9.19793 17.6653 9.05947C17.857 8.73708 17.9251 8.20345 17.5449 7.82332L16.6731 6.95142Z" fill="#0078D4"/>
</svg>`}getCashbackIcon(){return eh.Z.getTrustedHTML`<svg width="28" height="28" viewBox="0 0 28 28" fill="none" xmlns="http://www.w3.org/2000/svg">
<circle cx="14" cy="14" r="14" fill="#E4EFE4"/>
<path d="M6.46191 10.1877C6.46191 9.32033 7.16506 8.61719 8.03243 8.61719H20.1478C21.0152 8.61719 21.7183 9.32033 21.7183 10.1877V17.8159C21.7183 18.6833 21.0152 19.3864 20.1478 19.3864H8.03243C7.16506 19.3864 6.46191 18.6833 6.46191 17.8159V10.1877ZM9.15422 9.73898V10.6364C9.15422 11.0081 8.85287 11.3095 8.48114 11.3095H7.58371V12.6556H8.48114C9.59633 12.6556 10.5004 11.7516 10.5004 10.6364V9.73898H9.15422ZM14.0901 16.2454C15.2053 16.2454 16.1093 15.3413 16.1093 14.2262C16.1093 13.111 15.2053 12.2069 14.0901 12.2069C12.9749 12.2069 12.0709 13.111 12.0709 14.2262C12.0709 15.3413 12.9749 16.2454 14.0901 16.2454ZM7.58371 16.6941H8.48114C8.85287 16.6941 9.15422 16.9955 9.15422 17.3672V18.2646H10.5004V17.3672C10.5004 16.252 9.59633 15.348 8.48114 15.348H7.58371V16.6941ZM19.026 17.3672C19.026 16.9955 19.3274 16.6941 19.6991 16.6941H20.5965V15.348H19.6991C18.5839 15.348 17.6799 16.252 17.6799 17.3672V18.2646H19.026V17.3672ZM19.026 10.6364V9.73898H17.6799V10.6364C17.6799 11.7516 18.5839 12.6556 19.6991 12.6556H20.5965V11.3095H19.6991C19.3274 11.3095 19.026 11.0081 19.026 10.6364Z" fill="#0F7B0F"/>
</svg>`}getRewardIcon(){return eh.Z.getTrustedHTML`<svg width="28" height="28" viewBox="0 0 28 28" fill="none" xmlns="http://www.w3.org/2000/svg">
<circle cx="14" cy="14" r="14" fill="#FFFBE9"/>
<path d="M9.15347 8.61719C8.26132 8.61719 7.53809 9.34042 7.53809 10.2326V11.5168C7.53809 12.0766 7.82791 12.5965 8.30407 12.8909L12.4673 15.4645C11.456 16.0104 10.7689 17.0797 10.7689 18.3095C10.7689 20.0938 12.2153 21.5403 13.9996 21.5403C15.7839 21.5403 17.2304 20.0938 17.2304 18.3095C17.2304 17.0797 16.5432 16.0104 15.5319 15.4645L19.6952 12.8909C20.1713 12.5965 20.4612 12.0766 20.4612 11.5168V10.2326C20.4612 9.34042 19.7379 8.61719 18.8458 8.61719H9.15347ZM11.8458 13.8142V9.69411H16.1535V13.8142L14.2828 14.9707C14.1092 15.0779 13.89 15.0779 13.7165 14.9707L11.8458 13.8142ZM13.9996 16.1556C15.1892 16.1556 16.1535 17.12 16.1535 18.3095C16.1535 19.499 15.1892 20.4633 13.9996 20.4633C12.8101 20.4633 11.8458 19.499 11.8458 18.3095C11.8458 17.12 12.8101 16.1556 13.9996 16.1556Z" fill="#D17D00"/>
</svg>`}},this.stateManagement=i,this.logModule=t.logModule,this.maxSupportedDomains=1,this.telemetryUtilities=t.telemetryHandler}GetModuleName(){return r.ModuleNames.REWARD}setInitialStatesAndListeners(){this.stateManagement.addEventListener(Ku.e1.onRewardsTelemetryFail,(e=>{if(e.detail&&e.detail.status){const n=new t.Z(i.xu.ErrorRewardSignIn);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Reward sign in error - ${e.detail.status}`,n,Jl.g.CouponImpressionId)}})),this.stateManagement.addEventListener(Ku.e1.onRewardsTelemetrySuccess,(()=>{const e=new t.Z(i.xu.RewardSignInSuccess);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Reward sign in success",e,Jl.g.CouponImpressionId)}))}ShouldRenderModule(){const n=this.flyoutData.dataStoreModule.CashBackData?.canRenderCashback??!1,o=this.flyoutData.dataStoreModule.RewardData;o&&(this.pageHandlerModule.TriggerExperiment(f.H.rewardFlyout),this.pageHandlerModule.TriggerExperiment(f.H.rewardNotification));const r=e.R.isExperimentActive(f.H.rewardFlyout),a=e.R.isExperimentActive(f.H.signinRebates),s=this.flyoutData.dataStoreModule.CashBackData,l=r&&null!=o&&o.IsRewardsActive&&n&&(a||s&&s.userRebatesResponse?.isRebatesUser),c=this.isRewardsAdded();if(l&&!c){e.R.isVariantActive(f.H.rewardFlyout,Yu.Az.Rewards_100)?this.pointsToAllocate=100:e.R.isVariantActive(f.H.rewardFlyout,Yu.Az.Rewards_50)?this.pointsToAllocate=50:(e.R.isVariantActive(f.H.rewardFlyout,Yu.Az.Rewards_200),this.pointsToAllocate=200),this.setInitialStatesAndListeners();const n=new t.Z(i.xu.RewardWillBeRendered);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Rendered reward module in flyout",n,Jl.g.CouponImpressionId)}return Promise.resolve(l&&!c)}renderModule(){if(this.isRewardsAdded())return Promise.resolve(null);const e=this.flyoutData.dataStoreModule.RewardData;if(this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),e){const t=document.createElement("msft-edge-shopping-section");t.id="rewardSection",t.accordion=!0,t.titleText=this.flyoutData.strings.rewardRewards,t.setAttribute("aria-labelledby","divRewardTitleId");const i=this.renderFailedSignInSection(),n=this.renderWrapper(e);return!e.IsSignedInUser&&e.ActivateRewardsStatus&&this.isFailedSignInState(e.ActivateRewardsStatus)&&t.appendChild(i),t.appendChild(n),Promise.resolve(this.CreateModule(t,r.H7.REWARD,r.ModuleNames.REWARD,r.$k.CONTEXTUAL,r.SV.BLOCK))}return Promise.resolve(null)}PostProcessing(e,t,i){0===t&&gn.SO.queueUpdate((()=>{const e=this.flyoutData.common.shopping.querySelector("#rewardSection");if(e&&e.shadowRoot){const t=e.shadowRoot.querySelector("fluent-accordion-item");t&&(t.style.marginTop="0px")}}));const n=this.flyoutData.dataStoreModule.CashBackData,o=this.flyoutData.dataStoreModule.CouponData;this.flyoutData.dataStoreModule.CouponData?.isCheckoutPageWithAutoApply&&n?.canRenderCashback&&n&&!n.isCashBackActivated&&o&&o.Coupons&&!this.flyoutData.dataStoreModule.CashBackData?.isPersonalizedCashback&&!this.isRewardsAdded()&&gn.SO.queueUpdate((()=>{const e=this.flyoutData.common.shopping.querySelector("#rewardSection");e&&e.shadowRoot&&(e.titleText="",e.style.marginTop="0px",e.slot="header-content",e.expanded=!0,e.accordion=!1,e.style.marginTop="0px")}))}populateMainHeader(){if(this.flyoutData.common.shopping){const e=this.flyoutData.common.shopping.querySelector("#rewardSection");e&&(e.style.marginTop="0px",e.slot="header-content")}}StringifyMap(){return JSON.stringify(Array.from(this.rewardApplied.entries()))}isRewardsAdded(){try{const e=(0,h.Mw)(this.localStorageKeyRewardMap);let t=!1;if(e){const i=new Map(JSON.parse(e));for(const[e,n]of i.entries())if(e){const e=n;e&&(t=Date.now()-e<=6048e5)}}if(t)return!0}catch(e){const n=new t.Z(i.xu.ErrorRewardsAdded);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`isRewardsAdded Exception: ${(0,dt.YU)(e)}`,n)}return!1}renderIconSetSection(){const e=(0,Y.Ux)("DIV");e.className="divRewardIconSet";const t=this.renderIconSection(this.assets.getCouponIcon(),this.flyoutData.strings.rewardCoupons),i=this.renderIconSection(this.assets.getCashbackIcon(),this.flyoutData.strings.rewardCashback),n=this.renderIconSection(this.assets.getRewardIcon(),this.flyoutData.strings.rewardRewards);return e.appendChild(t),e.appendChild(i),e.appendChild(n),e}renderIconSection(e,t){const i=(0,Y.Ux)("DIV");i.className+=" divIconSection";const n=(0,Y.Ux)("DIV");n.textContent=e;const o=(0,Y.Ux)("DIV");return o.textContent=t,i.append(n),i.append(o),i}renderWrapper(e){const t=(0,Y.Ux)("div");t.className="divRewardWrapper";const i=(0,Y.Ux)("div");i.className+=" divRewardsHeader";const n=this.renderTitle(e),o=this.renderPointSection(e);i.appendChild(n),i.appendChild(o);const r=this.renderDetails(e);return t.appendChild(i),t.appendChild(r),t}renderFailedSignInSection(){const e=(0,Y.Ux)("div");e.className="divRewardFailedSignIn";const t=(0,Y.Ux)("div");t.className="divRewardErrorIcon",t.innerHTML=this.assets.getErrorCircleIcon();const i=(0,Y.Ux)("div");return i.textContent=this.flyoutData.strings.rewardFailedSignin,e.append(t),e.append(i),e}isFailedSignInState(e){return e===r.aE.FAILED_SWITCH_TO_MSA_PROFILE||e===r.aE.FAILED_SWITCH_TO_MSA_DECLINED||e===r.aE.FAILED_SIGN_INTO_PROFILE}renderTitle(e){const t=(0,Y.Ux)("div");t.className="divRewardTitle",t.id="divRewardTitleId",t.setAttribute("aria-live","assertive");const i=this.getRewardPoints(e);if(this.isRewardsAdded()){const e=(0,T.fZ)("rewardTitleRewardsAdded",this.flyoutData.strings.rewardTitleRewardsAdded,this.pointsToAllocate.toString());t.textContent=e}else e.IsTrialUser&&i>=5e3?t.textContent=this.flyoutData.strings.rewardTitleEarnedMaximum:t.textContent=this.flyoutData.strings.rewardTitleDefault;return t}renderPointSection(e){const t=(0,Y.Ux)("div");t.className="divRewardPointSection";const n=(0,Y.Ux)("div");n.className="divRewardPointIcon",n.innerHTML=this.assets.getCupIcon();const o=(0,Y.Ux)("div");o.className="divRewardPoint";const r=this.getRewardPoints(e);return o.setAttribute("aria-label",r.toString()+"Microsoft Rewards"),e.IsSignedInUser||e.IsAssociatedUser?o.textContent=r.toString():o.textContent=r>=5e3?this.flyoutData.strings.rewardPointMax:r.toString()+this.flyoutData.strings.rewardPerMaxPoint,this.stateManagement.addEventListener(Ku.e1.onCashBackActivatedForRewards,(async()=>{this.pageHandlerModule.RecordAsUserAction(K.bS.ACTIVATE_REWARDS_NEW);let t=new W.Z(i.$S.RewardsClick,this.telemetryUtilities.setContentViewed(this.GetModuleName()));if(this.logModule.LogInfoEvent(i.R.ButtonClick,"Clicked on Rewards",t),e.IsTrialUser&&r>=5e3||e.IsAssociatedUser)return t=new W.Z(i.$S.ActivateCashbackToEarnRewardFail,this.telemetryUtilities.setContentViewed(this.GetModuleName())),void(e.IsTrialUser&&r>=5e3?this.logModule.LogInfoEvent(i.R.ButtonClick,"Trial user already earned maximum reward points (5000)",t,Jl.g.CouponImpressionId):this.logModule.LogInfoEvent(i.R.ButtonClick,"Associated user attempted to earn rewards",t,Jl.g.CouponImpressionId));const n=this.flyoutData.common.domain,a=(0,h.Mw)(this.localStorageKeyRewardMap),s=(0,h.Mw)(this.localStorageKeyDomainCount);let l=0;const c=s?.split("&")[0];null===c||isNaN(parseInt(c,10))||(l=parseInt(c,10));const d=s?.split("&")[1];if(null!==d&&!isNaN(parseInt(d,10))){const e=parseInt(d,10);Date.now()-e>6048e5&&(l=0)}this.rewardApplied=a?new Map(JSON.parse(a)):new Map;const u=this.rewardApplied.get(n);l<this.maxSupportedDomains?u?Date.now()-u>=6048e5?this.updatePoints(e,r,o,n,l+1):(t=new W.Z(i.$S.ActivateCashbackToEarnRewardFail,this.telemetryUtilities.setContentViewed(this.GetModuleName())),this.logModule.LogInfoEvent(i.R.ButtonClick,"User already earned rewards on "+n+" today",t,Jl.g.CouponImpressionId)):(this.updatePoints(e,r,o,n,l+1),t=new W.Z(i.$S.ActivateCashbackToEarnReward,this.telemetryUtilities.setContentViewed(this.GetModuleName())),this.logModule.LogInfoEvent(i.R.ButtonClick,`User earned ${this.pointsToAllocate} reward points on `+n,t,Jl.g.CouponImpressionId)):(t=new W.Z(i.$S.ActivateCashbackToEarnRewardFail,this.telemetryUtilities.setContentViewed(this.GetModuleName())),this.logModule.LogInfoEvent(i.R.ButtonClick,"User already earned rewards on 5 domains",t,Jl.g.CouponImpressionId));const p=this.StringifyMap();(0,h.Xo)(this.localStorageKeyRewardMap,p)})),t.append(o),t.append(n),t}getRewardPoints(e){const t=(0,h.Mw)(this.localStorageKeyRewardPoints);if(t){const e=t.split("&");if(e){const t=e[0],i=parseInt(e[1],10);if(Date.now()-i<36e5){if(null!==t&&!isNaN(parseInt(t,10)))return parseInt(t,10)}else(0,h.UZ)(this.localStorageKeyRewardPoints)}}return e.Points?e.Points:0}updatePoints(e,t,n,o,r){t+=this.pointsToAllocate;const a=document.querySelector("#divRewardTitleId"),s=(0,T.fZ)("rewardTitleRewardsAdded",this.flyoutData.strings.rewardTitleRewardsAdded,this.pointsToAllocate.toString());a.textContent=s,a.setAttribute("aria-live","off"),document.querySelector("#divContentWrapper").style.background=`url( "${this.flyoutData.common.resourcesEndpoint}confetti.png") no-repeat`,document.querySelector("#divDetailFirstLine").style.display="none";const l=document.querySelector("#divDetailSecondLine");l.style.float="none",l.style.position="relative",l.style.bottom="2px",l.style.display="block";const c=document.querySelector(".divRewardAdditionalLink");if(c){const e=(0,Y.Ux)("DIV");e.className="divRewardAdditionalLink",e.textContent=this.flyoutData.strings.rewardKeepExploringText,c.replaceWith(e)}if((0,h.Xo)(this.localStorageKeyRewardPoints,t.toString()+"&"+Date.now()),1===r)(0,h.Xo)(this.localStorageKeyDomainCount,r.toString()+"&"+Date.now());else{const e=(0,h.Mw)(this.localStorageKeyDomainCount)?.split("&")[1];(0,h.Xo)(this.localStorageKeyDomainCount,r.toString()+"&"+e)}e.IsTrialUser?n.textContent=t.toString()+this.flyoutData.strings.rewardPerMaxPoint:n.textContent=t.toString();const d=new Xp(this.pointsToAllocate,this.pointsToAllocate,o,this.pointsToAllocate);this.logModule.LogInfoEvent(i.R.RewardsActivity,"rewards points info",d,Jl.g.CouponImpressionId),this.rewardApplied.set(o,Date.now())}renderDetails(e){const t=(0,Y.Ux)("DIV");t.className="divRewardDetailsSection";const i=this.renderLinkForMoreDetails(),n=this.renderLinkToSignIn(),o=(0,Y.Ux)("div",{style:"\n display: inline-block;"}),r=(0,Y.Ux)("div",{style:"\n display: inline-block;"});if(o.id="divDetailFirstLine",r.id="divDetailSecondLine",e.IsSignedInUser)i.textContent=this.flyoutData.strings.rewardRedeem,r.append(i),this.renderRewardsBanner(r,o,i,t);else if(e.IsAssociatedUser)n.textContent=this.flyoutData.strings.rewardAssociateSignIn,r.append(n),this.renderRewardsBanner(r,o,i,t);else{if(n.textContent=this.flyoutData.strings.rewardSignIn,r.append(n),this.isRewardsAdded())r.style.display="block";else{o.textContent=this.flyoutData.strings.rewardDetailFirstLine;const e=(0,Y.Ux)("span",{style:"\n font-weight: 500;"});e.textContent=(0,T.fZ)("rewardDetailFirstLineBold",this.flyoutData.strings.rewardDetailFirstLineBold,this.pointsToAllocate.toString()),o.appendChild(e),t.appendChild(o),r.style.float="right",r.style.position="relative",r.style.bottom="3px"}r.style.display="none",t.appendChild(r)}if(!e.IsAssociatedUser){const e=this.renderLinkToLeanMore();t.appendChild(e)}return t}renderLinkToLeanMore(){const e=(0,Y.Ux)("fluent-anchor");return e.className+=" divRewardAdditionalLink",e.appearance="lightweight",e.href="#",e.textContent=this.flyoutData.strings.commonLearnMore,e.addEventListener("click",(()=>{this.pageHandlerModule.RecordAsUserAction(K.bS.REWARDS_REDEEM_CLICK),this.pageHandlerModule.NavigateToRewardsInfo();const e=new W.Z(i.$S.RewardAdditionalLink,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"User navigated to explore additional rebates sites",e,Jl.g.CouponImpressionId)})),e}renderLinkToSignIn(){const e=(0,Y.Ux)("fluent-anchor");return e.className+=" detailLink",e.appearance="lightweight",e.href="#",e.addEventListener("click",(async()=>{this.pageHandlerModule.ActivateRewards(!0);const e=new W.Z(i.$S.RewardSignIn,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"Rewards Sign In started",e,Jl.g.CouponImpressionId)})),e}renderLinkForMoreDetails(){const e=(0,Y.Ux)("fluent-anchor");return e.className+=" detailLink",e.appearance="lightweight",e.href="#",e.addEventListener("click",(()=>{this.pageHandlerModule.RecordAsUserAction(K.bS.REWARDS_REDEEM_CLICK),this.pageHandlerModule.NavigateToRedeemRewards();const e=new W.Z(i.$S.RewardRedeem,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"User navigated to redeem rewards",e,Jl.g.CouponImpressionId)})),e}renderRewardsBanner(e,t,i,n){if(this.isRewardsAdded())e.style.display="block";else{t.textContent=this.flyoutData.strings.rewardDetailFirstLine;const i=(0,Y.Ux)("span",{style:"\n font-weight: 500; font-size: 18px;"}),o=(0,T.fZ)("rewardDetailFirstLineBold",this.flyoutData.strings.rewardDetailFirstLineBold,this.pointsToAllocate.toString());i.textContent=o,t.appendChild(i),n.appendChild(t),e.style.float="right",e.style.position="relative",e.style.bottom="3px"}e.style.display="none",n.appendChild(e)}},ak=class extends rk{constructor(e,t,i){super(t,i,e)}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_SERVER_DRIVEN_REWARDS]}PostProcessingNotification(e,t){this.PostProcessing(this.GetModuleName(),0,t)}RenderNotification(){const e=(0,Y.Ux)("div",{style:"width: 100%;"}),n=(0,Y.Ux)("div");n.className="divRewardTitle",n.id="titleRewardTwo",n.textContent=this.flyoutData.strings.rewardTitleRewardTwo;const o=(0,Y.Ux)("div");o.className="divRewardDetailsSection",o.id="detailRewardTwo",o.textContent=this.flyoutData.strings.rewardDetailTwo;const r=this.renderIconSetSection(),a=this.renderLearnMoreButton();e.appendChild(n),e.appendChild(o),e.appendChild(r),e.appendChild(a);const s=this.utilities.createNotificationModule(e,this.GetNotificationName(),this);this.disableNotificationHeader();const l=new t.Z(i.xu.RewardNotification);return this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"User saw reward notification",l,Jl.g.CouponImpressionId),Promise.resolve(s)}ShouldRenderNotification(){const e=this.flyoutData.dataStoreModule.RewardData;return Promise.resolve(e?.shouldRenderRewardNotification??!1)}GetNotificationName(){return r.sM.REWARD}disableNotificationHeader(){gn.SO.queueUpdate((()=>{const e=this.flyoutData.common.shopping;e.shadowRoot&&(e.shadowRoot.querySelector(".header").style.display="none")}))}renderLearnMoreButton(){const e=(0,Y.Ux)("fluent-button");return e.classList.add(a.q.PrimarySmallNotification),e.id="rewardButtonLearnMore",e.textContent=this.flyoutData.strings.commonLearnMore,e.appearance="accent",e.addEventListener("click",(()=>{this.pageHandlerModule.NavigateToRewardsInfo();const e=new W.Z(i.$S.RewardInfo,this.telemetryUtilities.setContentViewed(this.GetNotificationName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"User navigated to learn more about rewards",e,Jl.g.CouponImpressionId)})),e}},sk=class{getStyles(){return"\n #sanConsentContainer {\n display: flex;\n height: auto;\n flex-direction: column;\n justify-content: center;\n background-color: white;\n border-radius: 8px;\n padding: 16px;\n margin: 0 20px;\n margin-bottom: 8px;\n }\n #sanConsentTopDiv {\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n align-items: center;\n }\n #sanConsentHorizontalLine {\n height: 0;\n width: 100%;\n border-top: 1px solid #EBEBEB;\n margin-top: 10px;\n margin-bottom: 10px;\n }\n #sanConsentHeader {\n display: flex;\n flex-direction: row;\n height: 75px;\n align-items: center;\n }\n #sanConsentHeaderContent {\n display: flex;\n flex-direction: row;\n width: 304px;\n align-items: center;\n }\n #sanConsentHeaderImg {\n height: 72px;\n width: 72px;\n margin-right: 16px;\n }\n #sanConsentHeaderTextDiv {\n display: flex;\n flex-direction: column;\n justify-content: center;\n }\n #sanConsentHeaderTopText {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 16px;\n font-weight: 400;\n line-height: 22px;\n letter-spacing: 0em;\n text-align: left;\n color: var(--text-normal);\n }\n #sanConsentHeaderBottomText {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 20px;\n font-weight: 600;\n line-height: 26px;\n letter-spacing: 0em;\n text-align: left;\n }\n #sanConsentBodyContainer {\n display: flex;\n justify-content: center;\n margin-top: 10px;\n text-align: left;\n }\n #sanConsentButtonContainer {\n text-align: center;\n margin-top: 15px;\n }\n #sanConsentEuButtonsContainer {\n display: flex;\n justify-content: space-between;\n gap: 10px;\n }\n .sanConsentBodyText {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 14px;\n font-weight: 400;\n line-height: 20px;\n letter-spacing: 0em;\n color: #484848;\n margin: 0;\n }\n .sanConsentBodyLink {\n color: #036AC4;\n text-decoration: none;\n }\n .sanConsentButton {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 14px;\n font-weight: 400;\n line-height: 20px;\n letter-spacing: 0em;\n text-align: center;\n height: 32px;\n width: 100% !important;\n }\n #sanConsentFooter {\n margin-top: 5px;\n }\n .sanConsentEuButton {\n width: 135px;\n height: 30px;\n border-radius: 4px;\n border: 1px solid #D6D6D6;\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 14px;\n font-weight: 400;\n line-height: 20px;\n letter-spacing: 0em;\n text-align: center;\n color: var(--text-normal);\n }\n @media (-ms-high-contrast: active) {\n .sanConsentEuButton {\n border-color: ButtonText!important;\n }\n }\n "}getDarkModeStyles(){return"\n #sanConsentContainer, #sanConsentCloseButton,\n .sanConsentEuButton {\n background: #424242;\n }\n #sanConsentHorizontalLine {\n border-top-color: #5A5A5A;\n }\n #sanConsentCloseButton:hover, .sanConsentEuButton:hover {\n background: #555555;\n }\n #sanConsentHeaderTopText {\n color: #EAEAEA;\n }\n .sanConsentBodyText {\n color: #D9D9D9;\n }\n .sanConsentBodyLink {\n color: #9EECFD;\n }\n .sanConsentButton {\n background: #82DDFD;\n color: #000000;\n }\n .sanConsentEuButton {\n border-color: #5A5A5A;\n }\n "}getNotificationStyles(){return"\n #divContentWrapper {\n width: 280px;\n }\n "}},lk=class{constructor(t,i,n){(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"telemetryHandler",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"assetsItemizedCashback",void 0),(0,s.Z)(this,"sanConsentAssets",void 0),(0,s.Z)(this,"isPaneBanner",void 0),(0,s.Z)(this,"isNotification",void 0),(0,s.Z)(this,"isSPBNotification",void 0),(0,s.Z)(this,"isEu",void 0),(0,s.Z)(this,"surface",void 0),(0,s.Z)(this,"isUpdatedStringsExpActive",void 0),(0,s.Z)(this,"paneBannerRootId","sanConsentContainer"),(0,s.Z)(this,"icRootId","icSanConsentRoot"),this.flyoutData=t,this.utilities=i.viewModulesUtilities,this.telemetryHandler=i.telemetryHandler,this.pageHandlerModule=i.pageHandlerModule,this.logModule=i.logModule,this.assetsItemizedCashback=new Qp,this.sanConsentAssets=new sk,this.isPaneBanner=n===r.P1.PaneBanner,this.isNotification=n===r.P1.SPBNotification||n===r.P1.OtherNotification,this.isSPBNotification=n===r.P1.SPBNotification,this.isEu=this.IsEu(),this.surface=n,this.isUpdatedStringsExpActive=e.R.isExperimentActive(f.H.sanConsentStringUpdate)}CreateSANConsentDiv(e,t){this.ApplySANConsentAssets(),this.isPaneBanner||(this.isNotification?(this.isSPBNotification||this.ApplySanConsentNotificationStyles(),this.ApplySanConsentIcNotificationStyles()):this.ApplySanConsentIcStyles());const i=(0,Y.Ux)("div");if(i.setAttribute("aria-labelledby","sanConsentHeaderTopText sanConsentHeaderBottomText"),this.isPaneBanner?i.id=this.paneBannerRootId:(this.pageHandlerModule.InContextSanConsentShown(),i.className="icSanConsentRootDiv",i.id=this.icRootId),!this.isNotification){const e=this.CreateSANConsentTopDiv(),t=(0,Y.Ux)("DIV",{id:"sanConsentHorizontalLine"});i.appendChild(e),i.appendChild(t)}const n=this.CreateSANConsentHeaderDiv(),o=this.CreateSANConsentBodyDiv(),r=this.CreateSANConsentButton();i.appendChild(n),i.appendChild(o),i.appendChild(r),e&&this.ChangeToSuccessView(i);const a=()=>{this.telemetryHandler.LogICSpecificTelemetry(t,"","",{isActivatedSanConsent:e}),i.removeEventListener("mouseover",a)};return i.addEventListener("mouseover",a),i}IsEu(){return!0===this.flyoutData.dataStoreModule.SANConsentData?.IsEu}CanPromptConsent(){return!1===this.flyoutData.dataStoreModule.SANConsentData.PersonalizationDataConsent&&!0===this.flyoutData.dataStoreModule.SANConsentData.PersonalizationInContextCanPrompt}ApplySANConsentAssets(){this.utilities.applyStyles(this.isPaneBanner?this.flyoutData.common.shoppingPersistent:this.flyoutData.common.shopping,this.sanConsentAssets.getStyles(),void 0,this.sanConsentAssets.getDarkModeStyles())}ApplySanConsentIcStyles(){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assetsItemizedCashback.getSanConsentPaneAssets(),void 0,this.assetsItemizedCashback.getSanConsentPaneAssetsDarkMode())}ApplySanConsentIcNotificationStyles(){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assetsItemizedCashback.getSanConsentNotificationAssets(),void 0,this.assetsItemizedCashback.getSanConsentPaneAssetsDarkMode())}ApplySanConsentNotificationStyles(){this.utilities.applyStyles(this.flyoutData.common.shopping,this.sanConsentAssets.getNotificationStyles(),void 0,this.assetsItemizedCashback.getSanConsentPaneAssetsDarkMode())}CreateSANConsentTopDiv(){const e=(0,Y.Ux)("div",{id:"sanConsentTopDiv"}),t=(0,Y.Ux)("div",{id:"sanConsentTopDivTextContainer"}),i=(0,Y.Ux)("span",{id:"sanConsentHeaderTopText"});if(this.isPaneBanner?i.textContent=this.flyoutData.strings.sanConsentHeaderTopText:i.textContent=this.flyoutData.strings.sanConsentSeeMoreOffers,t.appendChild(i),e.appendChild(t),!this.isUpdatedStringsExpActive){const t=this.CreateCloseButtonDiv();e.appendChild(t)}return e}CreateSANConsentHeaderDiv(){const e=(0,Y.Ux)("div",{id:"sanConsentHeader"}),t=this.CreateSANConsentHeaderContentDiv();return e.appendChild(t),e}CreateSANConsentHeaderContentDiv(){const e=this.CreateHeaderImage(),t=this.CreateHeaderTextDiv(),i=(0,Y.Ux)("div",{id:"sanConsentHeaderContent"});return i.appendChild(e),i.appendChild(t),i.setAttribute("role","heading"),i.setAttribute("aria-level","2"),i}CreateHeaderImage(e=!1){const t=(0,Y.Ux)("img",{id:"sanConsentHeaderImg"});return t.src=`${this.flyoutData.common.resourcesEndpoint}sanConsent/img${e?"Done":"Prompt"}${this.utilities.isDarkMode()?"Dark":""}.png`,t.setAttribute("aria-hidden","true"),t}CreateHeaderTextDiv(){const e=(0,Y.Ux)("div",{id:"sanConsentHeaderTextDiv"});if(this.isNotification){const t=(0,Y.Ux)("span",{id:"sanConsentHeaderTopText"});this.isSPBNotification?t.textContent=this.flyoutData.strings.sanConsentHeaderTopTextNotification:t.textContent=this.flyoutData.strings.sanConsentHeaderTopTextNotifPostPurchase,e.appendChild(t)}const t=(0,Y.Ux)("span",{id:"sanConsentHeaderBottomText"});return(0,T.B7)(t,this.isEu?this.flyoutData.strings.sanConsentHeaderBottomTextEU:this.flyoutData.strings.sanConsentHeaderBottomText),e.appendChild(t),e}CreateCloseButtonDiv(){const e=(0,Y.Ux)("div",{id:"sanConsentCloseContainer"}),t=this.utilities.createCloseButton();return t.id="sanConsentCloseButton",t.addEventListener("click",(()=>{this.CloseButtonCallback(!1)})),e.appendChild(t),e}CloseButtonCallback(e){if(this.pageHandlerModule.InContextSanConsentClosed(),this.LogCloseClick(e),this.isNotification)this.pageHandlerModule.DismissPopup();else{const e=this.isPaneBanner?this.flyoutData.common.shoppingPersistent.querySelector(`#${this.paneBannerRootId}`):this.flyoutData.common.shopping.querySelector(`#${this.icRootId}`);e&&e.remove();const t=this.flyoutData.common.shoppingPersistent.querySelector(".sectionSeparator");if(t&&t.remove(),this.isPaneBanner){const e=this.flyoutData.common.shoppingPersistent.querySelector('[tabIndex = "0"]');e&&e.focus()}}}LogCloseClick(e){const t=this.ConstructCloseMessage(e),i=this.GetCloseButtonName();this.LogClick(i,t)}ConstructCloseMessage(e){let t="User clicked on the SAN consent";return t+=e?" decline":" close",t+=" button",this.isNotification&&(t+=" in notification",this.isSPBNotification&&(t+=" for spb")),t}GetCloseButtonName(){return this.isNotification?i.$S.SANConsentNotificationCloseButton:this.isPaneBanner?i.$S.SANConsentCloseButton:i.$S.ICSANConsentCloseButton}CreateSANConsentBodyDiv(){const e=(0,Y.Ux)("div"),t=(0,Y.Ux)("p",{className:"sanConsentBodyText"});e.appendChild(t);const i=(0,Y.Ux)("a",{className:"sanConsentBodyText sanConsentBodyLink"});i.href="#",i.textContent=this.flyoutData.strings.commonLearnMore,i.addEventListener("click",(()=>{this.pageHandlerModule.NavigateToPersonalizationLearnMore()}));const n=(0,Y.Ux)("a",{className:"sanConsentBodyText sanConsentBodyLink"});n.href="#",n.textContent=this.flyoutData.strings.commonPrivacy,n.addEventListener("click",(()=>{this.pageHandlerModule.NavigateToPersonalizationPrivacyStatement()})),(0,T.B7)(t,this.flyoutData.strings.sanConsentBodyTopText,i,n);const o=(0,Y.Ux)("div",{id:"sanConsentBodyContainer"});return o.appendChild(e),o}CreateSANConsentButton(){const e=(0,Y.Ux)("div",{id:"sanConsentButtonContainer"});if(this.isEu){const t=(0,Y.Ux)("div",{id:"sanConsentEuButtonsContainer"}),i=this.CreateEuButton(this.flyoutData.strings.sanConsentAcceptButton,(()=>{this.buttonCallback()})),n=this.CreateEuButton(this.flyoutData.strings.sanConsentRejectButton,(()=>{this.CloseButtonCallback(!0),this.pageHandlerModule.SetSanConsent(!1)}));t.appendChild(i),t.appendChild(n),e.appendChild(t)}else{const t=(0,Y.lw)(this.utilities);t.classList.add("sanConsentButton"),t.textContent=this.isUpdatedStringsExpActive?this.flyoutData.strings.sanConsentButtonV2:this.flyoutData.strings.sanConsentButton,t.addEventListener("click",(()=>{this.buttonCallback()})),e.appendChild(t)}return e}CreateEuButton(e,t){const i=(0,Y.Ux)("fluent-button",{className:"sanConsentEuButton"});return i.setAttribute("appearance","stealth"),i.textContent=e,i.addEventListener("click",t),i}buttonCallback(){this.pageHandlerModule.SetSanConsent(!0),this.flyoutData.dataStoreModule.SANConsentData.PersonalizationDataConsent=!0,this.LogAcceptClick(),this.isNotification?this.isSPBNotification?this.pageHandlerModule.OpenPane(this.flyoutData.common.popupOrigination):this.pageHandlerModule.DismissPopup():this.ChangeToSuccessView()}LogAcceptClick(){const e=this.ConstructAcceptMessage(),t=this.GetAcceptButtonName();this.LogClick(t,e)}LogClick(e,t){if(this.surface===r.P1.SPBNotification)this.telemetryHandler.LogButtonClickICSpecificTelemetry(e,void 0,t,"",{isActivatedSanConsent:this.flyoutData.dataStoreModule.SANConsentData.PersonalizationDataConsent,isEu:this.isEu});else{const n=new W.Z(e,bp.r.SAN_CONSENT_NOTIFICATION);n.Metadata=JSON.stringify({isEu:this.isEu}),this.logModule.LogInfoEvent(i.R.ButtonClick,t,n)}}ConstructAcceptMessage(){let e="User clicked on the SAN consent";return this.isNotification?(e+=" button in notification",this.isSPBNotification&&(e+=" for spb")):(e+=" accept button",this.isPaneBanner||(e+=" in pane for spb")),e}GetAcceptButtonName(){return this.isNotification?i.$S.SANConsentNotificationButton:this.isPaneBanner?i.$S.SANConsentAcceptButton:i.$S.ICSANConsentPaneButton}ChangeToSuccessView(e){const t=this.isPaneBanner?this.paneBannerRootId:this.icRootId,i=e??document.querySelector(`#${t}`),n=i.querySelector("#sanConsentHeaderTopText");n&&(n.classList.add("sanConsentHeaderTopTextActivated"),n.textContent=this.isPaneBanner?this.flyoutData.strings.sanConsentSuccessString:this.flyoutData.strings.sanConsentActivatedText);const o=i.querySelector("#sanConsentTopDiv");if(o){const e=this.CreateHeaderImage(!0);o.prepend(e),o.style.alignItems="flex-start";const t=o.querySelector("#sanConsentTopDivTextContainer");if(t){const e=this.CreateSANConsentFooter();t.appendChild(e);const i=e.querySelector("#sanConsentFooterLink");i&&i.focus()}}const r=["sanConsentHorizontalLine","sanConsentHeader","sanConsentBodyContainer","sanConsentButtonContainer"];for(const e of r){const t=i.querySelector(`#${e}`);t&&(t.style.display="none")}}CreateSANConsentFooter(){const e=(0,Y.Ux)("A",{id:"sanConsentFooterLink",className:"sanConsentBodyText sanConsentBodyLink"}),t=(0,Y.Ux)("div",{id:"sanConsentFooter"});return e.href="#",e.textContent=this.flyoutData.strings.commonPersonalizationSettings,e.addEventListener("click",(()=>{this.pageHandlerModule.NavigateToPersonalizationSettings()})),t.appendChild(e),t}},ck=class extends Qu{constructor(e,t,i){super(),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"sanConsentUtils",void 0),(0,s.Z)(this,"closed",!1),(0,s.Z)(this,"shown",!1),this.flyoutData=e,this.utilities=t.viewModulesUtilities,this.logModule=t.logModule,this.pageHandlerModule=t.pageHandlerModule,this.stateManagement=i,this.sanConsentUtils=new lk(e,t,r.P1.PaneBanner),this.assets=new sk}GetModuleName(){return r.ModuleNames.SAN_CONSENT}ShouldRenderModule(){const t=this.flyoutData.common.isPane&&e.R.isExperimentActive(f.H.sanConsent)&&this.sanConsentUtils.CanPromptConsent();return Promise.resolve(t)}async renderModule(){const e=(0,Y.Ux)("msft-edge-shopping-section"),t=this.sanConsentUtils.CreateSANConsentDiv(!1,i.xu.SanConsentPaneBannerHover);return e.appendChild(t),Promise.resolve(this.CreateModule(e,r.H7.SAN_CONSENT,this.GetModuleName(),r.$k.HOME,r.SV.SQUARES))}populateMainHeader(){}PostProcessing(e,n,o){this.stateManagement.addEventListener(Ku.e1.OnFlyoutDismissed,(()=>{this.closed||this.pageHandlerModule.InContextSanConsentClosed()})),this.stateManagement.addEventListener(Ku.e1.HomeTabActive,(()=>{if(!this.shown){this.pageHandlerModule.InContextSanConsentShown(),this.shown=!0;const e=new t.Z(i.xu.SanConsentViewed);e.Metadata=JSON.stringify({isEu:this.sanConsentUtils.IsEu()}),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"SanConsent shown to user",e)}}))}},dk=o(25039);function uk(e,t){if(t.length<e)throw new TypeError(e+" argument"+(e>1?"s":"")+" required, but only "+t.length+" present")}function hk(e){uk(1,arguments);var t=Object.prototype.toString.call(e);return e instanceof Date||"object"===(0,dk.Z)(e)&&"[object Date]"===t?new Date(e.getTime()):"number"==typeof e||"[object Number]"===t?new Date(e):new Date(NaN)}function pk(e){if(null===e||!0===e||!1===e)return NaN;var t=Number(e);return isNaN(t)?t:t<0?Math.ceil(t):Math.floor(t)}function gk(e){uk(1,arguments);var t=hk(e),i=t.getUTCDay(),n=(i<1?7:0)+i-1;return t.setUTCDate(t.getUTCDate()-n),t.setUTCHours(0,0,0,0),t}function fk(e){uk(1,arguments);var t=hk(e),i=t.getUTCFullYear(),n=new Date(0);n.setUTCFullYear(i+1,0,4),n.setUTCHours(0,0,0,0);var o=gk(n),r=new Date(0);r.setUTCFullYear(i,0,4),r.setUTCHours(0,0,0,0);var a=gk(r);return t.getTime()>=o.getTime()?i+1:t.getTime()>=a.getTime()?i:i-1}var mk={};function vk(){return mk}function yk(e,t){var i,n,o,r,a,s,l,c;uk(1,arguments);var d=vk(),u=pk(null!==(i=null!==(n=null!==(o=null!==(r=null==t?void 0:t.weekStartsOn)&&void 0!==r?r:null==t||null===(a=t.locale)||void 0===a||null===(s=a.options)||void 0===s?void 0:s.weekStartsOn)&&void 0!==o?o:d.weekStartsOn)&&void 0!==n?n:null===(l=d.locale)||void 0===l||null===(c=l.options)||void 0===c?void 0:c.weekStartsOn)&&void 0!==i?i:0);if(!(u>=0&&u<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var h=hk(e),p=h.getUTCDay(),g=(p<u?7:0)+p-u;return h.setUTCDate(h.getUTCDate()-g),h.setUTCHours(0,0,0,0),h}function Ck(e,t){var i,n,o,r,a,s,l,c;uk(1,arguments);var d=hk(e),u=d.getUTCFullYear(),h=vk(),p=pk(null!==(i=null!==(n=null!==(o=null!==(r=null==t?void 0:t.firstWeekContainsDate)&&void 0!==r?r:null==t||null===(a=t.locale)||void 0===a||null===(s=a.options)||void 0===s?void 0:s.firstWeekContainsDate)&&void 0!==o?o:h.firstWeekContainsDate)&&void 0!==n?n:null===(l=h.locale)||void 0===l||null===(c=l.options)||void 0===c?void 0:c.firstWeekContainsDate)&&void 0!==i?i:1);if(!(p>=1&&p<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var g=new Date(0);g.setUTCFullYear(u+1,0,p),g.setUTCHours(0,0,0,0);var f=yk(g,t),m=new Date(0);m.setUTCFullYear(u,0,p),m.setUTCHours(0,0,0,0);var v=yk(m,t);return d.getTime()>=f.getTime()?u+1:d.getTime()>=v.getTime()?u:u-1}function bk(e,t){for(var i=e<0?"-":"",n=Math.abs(e).toString();n.length<t;)n="0"+n;return i+n}var Sk={y:function(e,t){var i=e.getUTCFullYear(),n=i>0?i:1-i;return bk("yy"===t?n%100:n,t.length)},M:function(e,t){var i=e.getUTCMonth();return"M"===t?String(i+1):bk(i+1,2)},d:function(e,t){return bk(e.getUTCDate(),t.length)},a:function(e,t){var i=e.getUTCHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return i.toUpperCase();case"aaa":return i;case"aaaaa":return i[0];default:return"am"===i?"a.m.":"p.m."}},h:function(e,t){return bk(e.getUTCHours()%12||12,t.length)},H:function(e,t){return bk(e.getUTCHours(),t.length)},m:function(e,t){return bk(e.getUTCMinutes(),t.length)},s:function(e,t){return bk(e.getUTCSeconds(),t.length)},S:function(e,t){var i=t.length,n=e.getUTCMilliseconds();return bk(Math.floor(n*Math.pow(10,i-3)),t.length)}},xk=Sk,Tk={G:function(e,t,i){var n=e.getUTCFullYear()>0?1:0;switch(t){case"G":case"GG":case"GGG":return i.era(n,{width:"abbreviated"});case"GGGGG":return i.era(n,{width:"narrow"});default:return i.era(n,{width:"wide"})}},y:function(e,t,i){if("yo"===t){var n=e.getUTCFullYear(),o=n>0?n:1-n;return i.ordinalNumber(o,{unit:"year"})}return xk.y(e,t)},Y:function(e,t,i,n){var o=Ck(e,n),r=o>0?o:1-o;return"YY"===t?bk(r%100,2):"Yo"===t?i.ordinalNumber(r,{unit:"year"}):bk(r,t.length)},R:function(e,t){return bk(fk(e),t.length)},u:function(e,t){return bk(e.getUTCFullYear(),t.length)},Q:function(e,t,i){var n=Math.ceil((e.getUTCMonth()+1)/3);switch(t){case"Q":return String(n);case"QQ":return bk(n,2);case"Qo":return i.ordinalNumber(n,{unit:"quarter"});case"QQQ":return i.quarter(n,{width:"abbreviated",context:"formatting"});case"QQQQQ":return i.quarter(n,{width:"narrow",context:"formatting"});default:return i.quarter(n,{width:"wide",context:"formatting"})}},q:function(e,t,i){var n=Math.ceil((e.getUTCMonth()+1)/3);switch(t){case"q":return String(n);case"qq":return bk(n,2);case"qo":return i.ordinalNumber(n,{unit:"quarter"});case"qqq":return i.quarter(n,{width:"abbreviated",context:"standalone"});case"qqqqq":return i.quarter(n,{width:"narrow",context:"standalone"});default:return i.quarter(n,{width:"wide",context:"standalone"})}},M:function(e,t,i){var n=e.getUTCMonth();switch(t){case"M":case"MM":return xk.M(e,t);case"Mo":return i.ordinalNumber(n+1,{unit:"month"});case"MMM":return i.month(n,{width:"abbreviated",context:"formatting"});case"MMMMM":return i.month(n,{width:"narrow",context:"formatting"});default:return i.month(n,{width:"wide",context:"formatting"})}},L:function(e,t,i){var n=e.getUTCMonth();switch(t){case"L":return String(n+1);case"LL":return bk(n+1,2);case"Lo":return i.ordinalNumber(n+1,{unit:"month"});case"LLL":return i.month(n,{width:"abbreviated",context:"standalone"});case"LLLLL":return i.month(n,{width:"narrow",context:"standalone"});default:return i.month(n,{width:"wide",context:"standalone"})}},w:function(e,t,i,n){var o=function(e,t){uk(1,arguments);var i=hk(e),n=yk(i,t).getTime()-function(e,t){var i,n,o,r,a,s,l,c;uk(1,arguments);var d=vk(),u=pk(null!==(i=null!==(n=null!==(o=null!==(r=null==t?void 0:t.firstWeekContainsDate)&&void 0!==r?r:null==t||null===(a=t.locale)||void 0===a||null===(s=a.options)||void 0===s?void 0:s.firstWeekContainsDate)&&void 0!==o?o:d.firstWeekContainsDate)&&void 0!==n?n:null===(l=d.locale)||void 0===l||null===(c=l.options)||void 0===c?void 0:c.firstWeekContainsDate)&&void 0!==i?i:1),h=Ck(e,t),p=new Date(0);return p.setUTCFullYear(h,0,u),p.setUTCHours(0,0,0,0),yk(p,t)}(i,t).getTime();return Math.round(n/6048e5)+1}(e,n);return"wo"===t?i.ordinalNumber(o,{unit:"week"}):bk(o,t.length)},I:function(e,t,i){var n=function(e){uk(1,arguments);var t=hk(e),i=gk(t).getTime()-function(e){uk(1,arguments);var t=fk(e),i=new Date(0);return i.setUTCFullYear(t,0,4),i.setUTCHours(0,0,0,0),gk(i)}(t).getTime();return Math.round(i/6048e5)+1}(e);return"Io"===t?i.ordinalNumber(n,{unit:"week"}):bk(n,t.length)},d:function(e,t,i){return"do"===t?i.ordinalNumber(e.getUTCDate(),{unit:"date"}):xk.d(e,t)},D:function(e,t,i){var n=function(e){uk(1,arguments);var t=hk(e),i=t.getTime();t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0);var n=i-t.getTime();return Math.floor(n/864e5)+1}(e);return"Do"===t?i.ordinalNumber(n,{unit:"dayOfYear"}):bk(n,t.length)},E:function(e,t,i){var n=e.getUTCDay();switch(t){case"E":case"EE":case"EEE":return i.day(n,{width:"abbreviated",context:"formatting"});case"EEEEE":return i.day(n,{width:"narrow",context:"formatting"});case"EEEEEE":return i.day(n,{width:"short",context:"formatting"});default:return i.day(n,{width:"wide",context:"formatting"})}},e:function(e,t,i,n){var o=e.getUTCDay(),r=(o-n.weekStartsOn+8)%7||7;switch(t){case"e":return String(r);case"ee":return bk(r,2);case"eo":return i.ordinalNumber(r,{unit:"day"});case"eee":return i.day(o,{width:"abbreviated",context:"formatting"});case"eeeee":return i.day(o,{width:"narrow",context:"formatting"});case"eeeeee":return i.day(o,{width:"short",context:"formatting"});default:return i.day(o,{width:"wide",context:"formatting"})}},c:function(e,t,i,n){var o=e.getUTCDay(),r=(o-n.weekStartsOn+8)%7||7;switch(t){case"c":return String(r);case"cc":return bk(r,t.length);case"co":return i.ordinalNumber(r,{unit:"day"});case"ccc":return i.day(o,{width:"abbreviated",context:"standalone"});case"ccccc":return i.day(o,{width:"narrow",context:"standalone"});case"cccccc":return i.day(o,{width:"short",context:"standalone"});default:return i.day(o,{width:"wide",context:"standalone"})}},i:function(e,t,i){var n=e.getUTCDay(),o=0===n?7:n;switch(t){case"i":return String(o);case"ii":return bk(o,t.length);case"io":return i.ordinalNumber(o,{unit:"day"});case"iii":return i.day(n,{width:"abbreviated",context:"formatting"});case"iiiii":return i.day(n,{width:"narrow",context:"formatting"});case"iiiiii":return i.day(n,{width:"short",context:"formatting"});default:return i.day(n,{width:"wide",context:"formatting"})}},a:function(e,t,i){var n=e.getUTCHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"});case"aaa":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return i.dayPeriod(n,{width:"narrow",context:"formatting"});default:return i.dayPeriod(n,{width:"wide",context:"formatting"})}},b:function(e,t,i){var n,o=e.getUTCHours();switch(n=12===o?"noon":0===o?"midnight":o/12>=1?"pm":"am",t){case"b":case"bb":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"});case"bbb":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return i.dayPeriod(n,{width:"narrow",context:"formatting"});default:return i.dayPeriod(n,{width:"wide",context:"formatting"})}},B:function(e,t,i){var n,o=e.getUTCHours();switch(n=o>=17?"evening":o>=12?"afternoon":o>=4?"morning":"night",t){case"B":case"BB":case"BBB":return i.dayPeriod(n,{width:"abbreviated",context:"formatting"});case"BBBBB":return i.dayPeriod(n,{width:"narrow",context:"formatting"});default:return i.dayPeriod(n,{width:"wide",context:"formatting"})}},h:function(e,t,i){if("ho"===t){var n=e.getUTCHours()%12;return 0===n&&(n=12),i.ordinalNumber(n,{unit:"hour"})}return xk.h(e,t)},H:function(e,t,i){return"Ho"===t?i.ordinalNumber(e.getUTCHours(),{unit:"hour"}):xk.H(e,t)},K:function(e,t,i){var n=e.getUTCHours()%12;return"Ko"===t?i.ordinalNumber(n,{unit:"hour"}):bk(n,t.length)},k:function(e,t,i){var n=e.getUTCHours();return 0===n&&(n=24),"ko"===t?i.ordinalNumber(n,{unit:"hour"}):bk(n,t.length)},m:function(e,t,i){return"mo"===t?i.ordinalNumber(e.getUTCMinutes(),{unit:"minute"}):xk.m(e,t)},s:function(e,t,i){return"so"===t?i.ordinalNumber(e.getUTCSeconds(),{unit:"second"}):xk.s(e,t)},S:function(e,t){return xk.S(e,t)},X:function(e,t,i,n){var o=(n._originalDate||e).getTimezoneOffset();if(0===o)return"Z";switch(t){case"X":return Ok(o);case"XXXX":case"XX":return Pk(o);default:return Pk(o,":")}},x:function(e,t,i,n){var o=(n._originalDate||e).getTimezoneOffset();switch(t){case"x":return Ok(o);case"xxxx":case"xx":return Pk(o);default:return Pk(o,":")}},O:function(e,t,i,n){var o=(n._originalDate||e).getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+wk(o,":");default:return"GMT"+Pk(o,":")}},z:function(e,t,i,n){var o=(n._originalDate||e).getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+wk(o,":");default:return"GMT"+Pk(o,":")}},t:function(e,t,i,n){var o=n._originalDate||e;return bk(Math.floor(o.getTime()/1e3),t.length)},T:function(e,t,i,n){return bk((n._originalDate||e).getTime(),t.length)}};function wk(e,t){var i=e>0?"-":"+",n=Math.abs(e),o=Math.floor(n/60),r=n%60;if(0===r)return i+String(o);var a=t||"";return i+String(o)+a+bk(r,2)}function Ok(e,t){return e%60==0?(e>0?"-":"+")+bk(Math.abs(e)/60,2):Pk(e,t)}function Pk(e,t){var i=t||"",n=e>0?"-":"+",o=Math.abs(e);return n+bk(Math.floor(o/60),2)+i+bk(o%60,2)}var Ak=Tk,Ek=function(e,t){switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});default:return t.date({width:"full"})}},kk=function(e,t){switch(e){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});default:return t.time({width:"full"})}},Ik={p:kk,P:function(e,t){var i,n=e.match(/(P+)(p+)?/)||[],o=n[1],r=n[2];if(!r)return Ek(e,t);switch(o){case"P":i=t.dateTime({width:"short"});break;case"PP":i=t.dateTime({width:"medium"});break;case"PPP":i=t.dateTime({width:"long"});break;default:i=t.dateTime({width:"full"})}return i.replace("{{date}}",Ek(o,t)).replace("{{time}}",kk(r,t))}},Dk=["D","DD"],_k=["YY","YYYY"];function Nk(e,t,i){if("YYYY"===e)throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(t,"`) for formatting years to the input `").concat(i,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("YY"===e)throw new RangeError("Use `yy` instead of `YY` (in `".concat(t,"`) for formatting years to the input `").concat(i,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("D"===e)throw new RangeError("Use `d` instead of `D` (in `".concat(t,"`) for formatting days of the month to the input `").concat(i,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if("DD"===e)throw new RangeError("Use `dd` instead of `DD` (in `".concat(t,"`) for formatting days of the month to the input `").concat(i,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"))}var Rk={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}};function Mk(e){return function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},i=t.width?String(t.width):e.defaultWidth;return e.formats[i]||e.formats[e.defaultWidth]}}var Lk={date:Mk({formats:{full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},defaultWidth:"full"}),time:Mk({formats:{full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},defaultWidth:"full"}),dateTime:Mk({formats:{full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},defaultWidth:"full"})},Bk={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"};function Fk(e){return function(t,i){var n;if("formatting"===(null!=i&&i.context?String(i.context):"standalone")&&e.formattingValues){var o=e.defaultFormattingWidth||e.defaultWidth,r=null!=i&&i.width?String(i.width):o;n=e.formattingValues[r]||e.formattingValues[o]}else{var a=e.defaultWidth,s=null!=i&&i.width?String(i.width):e.defaultWidth;n=e.values[s]||e.values[a]}return n[e.argumentCallback?e.argumentCallback(t):t]}}var Uk={ordinalNumber:function(e,t){var i=Number(e),n=i%100;if(n>20||n<10)switch(n%10){case 1:return i+"st";case 2:return i+"nd";case 3:return i+"rd"}return i+"th"},era:Fk({values:{narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},defaultWidth:"wide"}),quarter:Fk({values:{narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},defaultWidth:"wide",argumentCallback:function(e){return e-1}}),month:Fk({values:{narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},defaultWidth:"wide"}),day:Fk({values:{narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},defaultWidth:"wide"}),dayPeriod:Fk({values:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},defaultWidth:"wide",formattingValues:{narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},defaultFormattingWidth:"wide"})},Hk=Uk;function $k(e){return function(t){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=i.width,o=n&&e.matchPatterns[n]||e.matchPatterns[e.defaultMatchWidth],r=t.match(o);if(!r)return null;var a,s=r[0],l=n&&e.parsePatterns[n]||e.parsePatterns[e.defaultParseWidth],c=Array.isArray(l)?function(e,t){for(var i=0;i<e.length;i++)if(e[i].test(s))return i}(l):function(e,t){for(var i in e)if(e.hasOwnProperty(i)&&e[i].test(s))return i}(l);return a=e.valueCallback?e.valueCallback(c):c,{value:a=i.valueCallback?i.valueCallback(a):a,rest:t.slice(s.length)}}}var Zk,Vk={ordinalNumber:(Zk={matchPattern:/^(\d+)(th|st|nd|rd)?/i,parsePattern:/\d+/i,valueCallback:function(e){return parseInt(e,10)}},function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=e.match(Zk.matchPattern);if(!i)return null;var n=i[0],o=e.match(Zk.parsePattern);if(!o)return null;var r=Zk.valueCallback?Zk.valueCallback(o[0]):o[0];return{value:r=t.valueCallback?t.valueCallback(r):r,rest:e.slice(n.length)}}),era:$k({matchPatterns:{narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},defaultMatchWidth:"wide",parsePatterns:{any:[/^b/i,/^(a|c)/i]},defaultParseWidth:"any"}),quarter:$k({matchPatterns:{narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},defaultMatchWidth:"wide",parsePatterns:{any:[/1/i,/2/i,/3/i,/4/i]},defaultParseWidth:"any",valueCallback:function(e){return e+1}}),month:$k({matchPatterns:{narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},defaultParseWidth:"any"}),day:$k({matchPatterns:{narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},defaultMatchWidth:"wide",parsePatterns:{narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},defaultParseWidth:"any"}),dayPeriod:$k({matchPatterns:{narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},defaultMatchWidth:"any",parsePatterns:{any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},defaultParseWidth:"any"})},Gk={code:"en-US",formatDistance:function(e,t,i){var n,o=Rk[e];return n="string"==typeof o?o:1===t?o.one:o.other.replace("{{count}}",t.toString()),null!=i&&i.addSuffix?i.comparison&&i.comparison>0?"in "+n:n+" ago":n},formatLong:Lk,formatRelative:function(e,t,i,n){return Bk[e]},localize:Hk,match:Vk,options:{weekStartsOn:0,firstWeekContainsDate:1}},jk=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,zk=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Wk=/^'([^]*?)'?$/,Kk=/''/g,qk=/[a-zA-Z]/;function Yk(e,t,i){var n,o,r,a,s,l,c,d,u,h,p,g,f,m,v,y,C,b;uk(2,arguments);var S=String(t),x=vk(),T=null!==(n=null!==(o=null==i?void 0:i.locale)&&void 0!==o?o:x.locale)&&void 0!==n?n:Gk,w=pk(null!==(r=null!==(a=null!==(s=null!==(l=null==i?void 0:i.firstWeekContainsDate)&&void 0!==l?l:null==i||null===(c=i.locale)||void 0===c||null===(d=c.options)||void 0===d?void 0:d.firstWeekContainsDate)&&void 0!==s?s:x.firstWeekContainsDate)&&void 0!==a?a:null===(u=x.locale)||void 0===u||null===(h=u.options)||void 0===h?void 0:h.firstWeekContainsDate)&&void 0!==r?r:1);if(!(w>=1&&w<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var O=pk(null!==(p=null!==(g=null!==(f=null!==(m=null==i?void 0:i.weekStartsOn)&&void 0!==m?m:null==i||null===(v=i.locale)||void 0===v||null===(y=v.options)||void 0===y?void 0:y.weekStartsOn)&&void 0!==f?f:x.weekStartsOn)&&void 0!==g?g:null===(C=x.locale)||void 0===C||null===(b=C.options)||void 0===b?void 0:b.weekStartsOn)&&void 0!==p?p:0);if(!(O>=0&&O<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!T.localize)throw new RangeError("locale must contain localize property");if(!T.formatLong)throw new RangeError("locale must contain formatLong property");var P=hk(e);if(!function(e){if(uk(1,arguments),!function(e){return uk(1,arguments),e instanceof Date||"object"===(0,dk.Z)(e)&&"[object Date]"===Object.prototype.toString.call(e)}(e)&&"number"!=typeof e)return!1;var t=hk(e);return!isNaN(Number(t))}(P))throw new RangeError("Invalid time value");var A=function(e){var t=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));return t.setUTCFullYear(e.getFullYear()),e.getTime()-t.getTime()}(P),E=function(e,t){return uk(2,arguments),function(e,t){uk(2,arguments);var i=hk(e).getTime(),n=pk(t);return new Date(i+n)}(e,-pk(t))}(P,A),k={firstWeekContainsDate:w,weekStartsOn:O,locale:T,_originalDate:P};return S.match(zk).map((function(e){var t=e[0];return"p"===t||"P"===t?(0,Ik[t])(e,T.formatLong):e})).join("").match(jk).map((function(n){if("''"===n)return"'";var o,r,a=n[0];if("'"===a)return(r=(o=n).match(Wk))?r[1].replace(Kk,"'"):o;var s,l=Ak[a];if(l)return null!=i&&i.useAdditionalWeekYearTokens||(s=n,-1===_k.indexOf(s))||Nk(n,t,String(e)),null!=i&&i.useAdditionalDayOfYearTokens||!function(e){return-1!==Dk.indexOf(e)}(n)||Nk(n,t,String(e)),l(E,n,T.localize,k);if(a.match(qk))throw new RangeError("Format string contains an unescaped latin alphabet character `"+a+"`");return n})).join("")}const Xk=["com","net","org","edu","gov","mil","co","ac","biz","info","name","pro","aero","asia","cat","coop","int","jobs","mobi","museum","tel","travel","arpa","root","au","dz","br","ca","eu","in","uk","us","cn","de","fr","it","jp","kr","ru","com","me","sch","asn","id","csiro","tn","nz","za","es","nl","se","ch","no","fi","dk","be","pl","cz","gr","pt","hu","ro","ie","is","il","ae","sa","eg","ma"];function Jk(e){const t=e.split(".").filter((e=>!Xk.includes(e))),i=t[t.length-1].split("-").map((e=>function(e){return e.charAt(0).toUpperCase()+e.slice(1).toLowerCase()}(e))).join(" ");return"Macys"===i?"Macy's":"Kohls"===i?"Kohl's":"landsend"===i?"Land's End":i}var Qk=class extends Qu{constructor(e,t,i,n){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"stateManagementModule",void 0),(0,s.Z)(this,"sectionId","shoppingTrips"),(0,s.Z)(this,"parent",void 0),(0,s.Z)(this,"allPurchasesTab",r.fk.AllPurchases),(0,s.Z)(this,"activeTab",r.fk.Active),(0,s.Z)(this,"tabId","shoppingTripsSectionTabs"),(0,s.Z)(this,"lastFocusedIndex",void 0),(0,s.Z)(this,"commonAssets",void 0),this.pageHandlerModule=i.pageHandlerModule,this.flyoutData=t,this.utilities=i.viewModulesUtilities,this.assets=new class{getStyles(){return'\n #shoppingTrips::part(title) {\n margin-top: 14px;\n }\n #shoppingTrips fluent-button.btnSeeMore {\n width: -webkit-fill-available;\n }\n #shoppingTripsSectionTabs::part(tablist) {\n display: flex;\n margin: 4px 10px 12px 10px;\n }\n #shoppingTripsSectionTabs li + li {\n margin-top: 12px;\n }\n #shoppingTrips #ALLPURCHASES {\n margin-left: 10px;\n }\n #shoppingTripsSectionTabs li:before {\n content: counter(item) " ";\n counter-increment: item;\n padding-right: 8px;\n }\n #shoppingTrips msft-wishlist-card {\n background-color: var(--fill-color);\n border-radius: 8px;\n }\n .emptyMessage {\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n font-weight: 600;\n font-size: 16px;\n line-height: 20px;\n text-align: center;\n margin: 5px 20px;\n }\n .emptyMessage fluent-anchor {\n margin-left: 5px;\n cursor: pointer;\n font-weight: inherit;\n font-size: inherit;\n line-height: inherit;\n }\n .listWrapper {\n border-radius: 8px;\n display: flex;\n flex-direction: column;\n row-gap: 12px;\n margin: 0 20px 12px;\n }\n .imageWrapper {\n display: flex;\n justify-content: center;\n align-items: center;\n height: 160px;\n }\n .zeroStateImage {\n height: 100%;\n }\n fluent-button.recently-viewed-button::part(control) {\n padding: 4px;\n right: 0px;\n position: absolute;\n }\n .shoppingTripCardWrapper {\n display: flex;\n padding: 12px;\n align-items: flex-start;\n gap: 12px;\n border-radius: 8px;\n background: #FFF;\n }\n .shoppingTripStatusWrapper {\n display: flex;\n flex-direction: column;\n gap: 9px;\n align-items: flex-end;\n flex: 1 0 0;\n align-self: stretch;\n }\n .shoppingTripInfoWrapper {\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n gap: 9px;\n flex: 1 0 0;\n align-self: stretch;\n }\n .divMerchantInfo {\n display: flex;\n align-items: center;\n gap: 6px;\n }\n .divMerchantIcon {\n width: 16px;\n height: 16px;\n border-radius: 50%;\n }\n .imgMerchantIcon {\n border-radius: 50%;\n }\n .txtMerchantInfo {\n color: var(--light-foreground-foreground-1, var(--color-neutral-foreground-1-rest, #242424));\n font-size: 14px;\n font-style: normal;\n font-weight: 600;\n line-height: normal;\n margin: 0px!important;\n }\n .orderDateInfo {\n display: -webkit-box;\n overflow: hidden;\n color: var(--light-foreground-foreground-3, var(--color-neutral-foreground-3-rest, #616161));\n text-overflow: ellipsis;\n font-size: 12px;\n font-style: normal;\n font-weight: 400;\n line-height: 16px;\n margin: 0px!important;\n -webkit-box-orient: vertical;\n -webkit-line-clamp: 1;\n }\n .shoppingTripStatusInfoWrapper {\n display: flex;\n align-items: center;\n gap: 6px;\n color: var(--light-foreground-foreground-4, var(--color-neutral-foreground-4-rest, #707070));\n font-size: 12px;\n font-style: normal;\n font-weight: 400;\n line-height: 16px;\n }\n .shoppingTripStatusInfoWrapper p{\n margin: 0px!important;\n }\n .shoppingTripPriceWrapper p {\n margin: 0px!important;\n font-size: 14px;\n font-style: normal;\n font-weight: 400;\n line-height: normal;\n }\n .shoppingTripPriceWrapper {\n display: flex;\n justify-content: flex-end;\n align-items: center;\n gap: 4px;\n height: 19px;\n }\n #shoppingTrips .spanCommissionValue {\n display: flex;\n height: 24px;\n line-height: 24px;\n font-size: 12px;\n background: #036AC4;\n color: #fff;\n font-weight: 400;\n float: left;\n }\n .divCommissionValue {\n display: flex;\n justify-content: center;\n align-items: center;\n margin: 0px;\n }\n .shoppingTripsCompletePurchase {\n display: flex;\n align-items: flex-end;\n gap: 6px;\n }\n .completePurchaseLink {\n color: var(--foreground-brand-foreground-link, var(--brand-color-brand-foreground-link, #235CCF));\n font-size: 12px;\n font-style: normal;\n font-weight: 400;\n line-height: 16px;\n margin: 0px!important;\n height: fit-content;\n }\n .completePurchaseLink::part(control) {\n padding: 0px!important;\n }\n '}getDarkModeStyles(){return"\n #shoppingTripsSectionTabs fluent-tab[aria-selected=true] {\n color: #63ADE5;\n border: 1px solid #63ADE5;\n }\n .completePurchaseLink {\n color: #66CDFC !important;\n }\n .txtMerchantInfo, .shoppingTripPriceWrapper{\n color: var(--neutral-foreground-rest)!important;\n }\n .orderDateInfo {\n color: #EBEBEB!important;\n }\n .shoppingTripStatusInfoWrapper {\n color: #E0E0E0!important;\n }\n .shoppingTripStatusInfoWrapper svg path, .completePurchaseLink svg path {\n fill: #E0E0E0!important;\n }\n #shoppingTripPriceWrapper svg path {\n fill: #707070!important;\n }\n .completePurchaseLink::::part(control) {\n border-top: 0px;\n }\n #shoppingTrips fluent-button.btnSeeMore {\n width: -webkit-fill-available;\n margin: 0px 20px 20px;\n }\n #shoppingTrips .shoppingTripCardWrapper {\n background-color: #424242!important;\n border-radius: 8px;\n }\n #shoppingTrips msft-wishlist-card {\n background-color: #424242;\n border-radius: 8px;\n }\n #shoppingTrips fluent-button {\n margin: 0px 10px 0px 5px;\n background-color: #4A4A4A;\n border-radius: 10px;\n }"}},this.stateManagementModule=e,this.parent=this.flyoutData.common.shoppingPersistent,this.lastFocusedIndex=null,this.commonAssets=n,this.storageHandler=i.storageHandler,this.logModule=i.logModule,this.telemetryUtilities=i.telemetryHandler}GetModuleName(){return r.ModuleNames.SHOPPING_TRIPS}async ShouldRenderModule(){const t=e.R.isExperimentActive(f.H.ShoppingTrips);return Promise.resolve(t&&this.flyoutData.common.isPane)}async populateTabsSection(e){const t=(0,Y.Ux)("fluent-tabs");t.id=this.tabId,t.classList.add("sectionTabList"),t.activeid=this.allPurchasesTab;const i=await this.renderShoppingTripList(!1);(0,Y.Qn)(t,this.allPurchasesTab,this.flyoutData.strings.shopTripAllPurchase,i);const n=await this.renderShoppingTripList(!0);(0,Y.Qn)(t,this.activeTab,this.flyoutData.strings.shopTripActivePurchases,n),e.appendChild(t)}async renderModule(){this.utilities.applyStyles(this.parent,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());let t=document.getElementById(this.sectionId);return e.R.isExperimentActive(f.H.singleScrollingShoreline)&&t?t.replaceChildren():t=(0,Y.Ux)("msft-edge-shopping-section"),t.id=this.sectionId,t.titleText=this.flyoutData.strings.shoppingTripsTitle,this.populateTabsSection(t),this.stateManagementModule.addEventListener(Ku.e1.FocusshoppingTrips,(e=>{const t=e.detail?.tabId??r.fk.AllPurchases,i=this.parent.querySelector(this.sectionId);if(i){i.scrollIntoView({behavior:"smooth"});const e=this.parent.querySelector(this.tabId);e&&(e.activeid=t)}})),this.stateManagementModule.addEventListener(Ku.e1.onCashBackActivated,(()=>{const e=document.getElementById(this.tabId);e&&(e.remove(),gn.SO.queueUpdate((()=>{this.populateTabsSection(t)})))})),Promise.resolve(this.CreateModule(t,r.H7.SHOPPING_TRIPS,r.ModuleNames.SHOPPING_TRIPS,r.$k.HOME,r.SV.LIST))}populateMainHeader(){if(this.flyoutData.common.shoppingPersistent){const e=this.flyoutData.common.shoppingPersistent.querySelector(`#${this.sectionId}`);e&&(e.style.marginTop="0px",e.slot="header-content",e.hideTitle=!1)}}async renderShoppingTripList(e){const t=await this.storageHandler.getStorageString(Ce.Q.ShoppingTripsData),i=this.getShoppingTripsData(t,e),n=e?"ACTIVE_PURCHASES_SECTION":"ALLPURCHASES_SECTION";let o=document.getElementById(n);o||(o=(0,Y.Ux)("div"),o.id=n);const a=e=>r.CS.SHOPPING_TRIPS;if(!i||i?.length>0)this.populateShoppingTripsList(o,!1,!1,i).then((()=>{this.utilities.createCommonListStructure(o,"",i,this.GetModuleName(),a,this.populateShoppingTripsList.bind(this),void 0)}));else{o.textContent="",o.style.margin="0 20px";const e=this.utilities.isDarkMode();o.appendChild(this.createEmptyCard(`common/money_sparkles${e?"_dark":""}.png`,this.flyoutData.strings.shopTripEmptyMessage))}return o}async populateShoppingTripsList(e,t,n,o){let a;const s=(0,Y.Ux)("DIV",{className:"listWrapper"});if(s.style.borderRadius="8px",s.style.display="flex",s.style.flexDirection="column",s.style.rowGap="12px",s.style.margin="0 20px 12px",o){if(o.length>0&&(a=o.length),t){const e=new W.Z(i.$S.SeeMoreShoppingTrips,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"See more shopping trips",e);const t=new CustomEvent(Ku.e1.SeeMoreClick,{detail:{totalCards:o.length}});s.dispatchEvent(t)}else a>r.CS.SHOPPING_TRIPS&&(a=r.CS.SHOPPING_TRIPS);for(let e=0;e<a;e++){if(this.isShoppingTripsOlderThan15Days(o[e].startDate))continue;const i=this.createShoppingTripItem(o[e]);s.appendChild(i),(0===e&&t&&n&&this.flyoutData.common.currentDevice===r.AS.Desktop&&i||this.lastFocusedIndex===e)&&(gn.SO.queueUpdate((()=>{i.focus()})),this.lastFocusedIndex=null)}const l=document.querySelector(`#${e.id} .listWrapper`);l?e.replaceChild(s,l):e.appendChild(s)}}createShoppingTripItem(e){const t=(0,Y.Ux)("div",{className:"shoppingTripCardWrapper"}),i=(0,Y.Ux)("div",{className:"shoppingTripStatusWrapper"}),n=(0,Y.Ux)("div",{className:"shoppingTripInfoWrapper"}),o=(0,Y.Ux)("div",{className:"divMerchantInfo"}),a=this.getDomainName(e.merchantName),s=(0,Y.Ux)("p",{className:"txtMerchantInfo"});s.textContent=a;const l=(0,Y.Ux)("div",{className:"divMerchantIcon"}),c=(0,Y.Ux)("img",{className:"imgMerchantIcon"});this.utilities.addFavIconSrc(c,l,e.domain);const d=(0,Y.Ux)("p",{className:"orderDateInfo"});return d.textContent=isNaN(Date.parse(e.startDate))?"":Yk(new Date(e.startDate),"MM/dd/yyyy"),s.style.overflow="hidden",s.style.textOverflow="ellipsis",o.style.maxWidth="100%",o.setAttribute("title",a),o.appendChild(l),o.appendChild(s),n.style.maxWidth="50%",n.style.overflow="hidden",n.appendChild(o),n.appendChild(d),i.appendChild(this.renderShoppingTripCashbackAmount(e.cashbackAmount)),i.appendChild(this.renderShoppingTripStatusMessage(e,t)),e.status===r.Ex.OfferActivated&&i.appendChild(this.renderNavigateToRetailerURL(e.merchantHomepage,e.merchantName)),t.appendChild(n),t.appendChild(i),t}renderNavigateToRetailerURL(e,t){const n=(0,Y.Ux)("div",{className:"shoppingTripsCompletePurchase"}),o=(0,Y.Ux)("fluent-anchor",{className:"completePurchaseLink"});o.appearance="lightweight",o.href="#",o.textContent=this.flyoutData.strings.shopTripCashBackCompletePurchaseLink;const r=(0,Y.Ux)("DIV");r.style.display="flex",r.style.alignItems="center",r.setAttribute("aria-hidden","true"),r.innerHTML=this.commonAssets.getShoppingTripsOpenLinkIcon(),o.addEventListener("click",(()=>{this.storageHandler.setStorageString(Ce.Q.ShoppingTripsActivateRebateDomain,t),this.pageHandlerModule.NavigateToUrl(e)}));const a=new W.Z(i.$S.ShoppingTripsCompletePurchase,this.telemetryUtilities.setContentViewed(this.GetModuleName()));return this.logModule.LogInfoEvent(i.R.ButtonClick,"User clicked on complete purchase link on shopping trips module",a,Jl.g.DomainName),n.appendChild(o),n.appendChild(r),n}renderShoppingTripStatusMessage(e,t){const i=e.status,n=(0,Y.Ux)("div",{className:"shoppingTripStatusInfoWrapper"}),o=(0,Y.Ux)("p"),a=(0,Y.Ux)("DIV");switch(a.style.display="flex",a.style.alignItems="center",a.setAttribute("aria-hidden","true"),i){case r.Ex.CashBackReceived:o.textContent=this.flyoutData.strings.shopTripStatusCashbackReceived,a.innerHTML=this.commonAssets.getMoneyIcon(),t.setAttribute("aria-label",this.flyoutData.strings.shopTripStatusCashbackReceived+" at "+e.merchantName);break;case r.Ex.MerchantProcessing:o.textContent=this.flyoutData.strings.shopTripStatusMerchantProcessing,a.innerHTML=this.commonAssets.getHourglassHalfIcon(),t.setAttribute("aria-label",this.flyoutData.strings.shopTripStatusMerchantProcessing+"cashback at "+e.merchantName);break;case r.Ex.OfferActivated:o.textContent=this.flyoutData.strings.shopTripStatusOfferActivated,a.innerHTML=this.commonAssets.getCheckmarkCircleIcon(),t.setAttribute("aria-label",this.flyoutData.strings.shopTripStatusOfferActivated+" at "+e.merchantName)}return n.appendChild(a),n.appendChild(o),n}renderShoppingTripCashbackAmount(e){const t=(0,T.uf)(this.flyoutData.dataStoreModule.ApiData?.market,this.flyoutData.dataStoreModule.ApiData?.retailerData?.exclusiveMarket),i=(0,ne.N6)(t)??"$",n=(0,Y.Ux)("div",{className:"shoppingTripPriceWrapper"});if(e&&e>0){const t=this.utilities.createCommissionArrow(i+e,!1,zu.h.Medium);return n.appendChild(t),n}{const e=(0,Y.Ux)("DIV");e.style.display="flex",e.style.alignItems="center",e.innerHTML=this.commonAssets.getShoppingTripsCashbackIcon(),e.setAttribute("aria-hidden","true");const t=(0,Y.Ux)("p");return t.textContent=this.flyoutData.strings.shopTripCashBackAmountPending,n.appendChild(e),n.appendChild(t),n}}createEmptyCard(e,t,i){const n=(0,Y.Ux)("div",{className:"imageWrapper"}),o=(0,Y.Ux)("img",{className:"zeroStateImage"});this.utilities.setImageSrc(o,this.flyoutData.common.resourcesEndpoint+e),o.style.pointerEvents="none",o.setAttribute("aria-hidden","true"),n.appendChild(o),n.slot="empty-image",n.style.height="fit-content";const r=(0,Y.Ux)("msft-wishlist-card",{id:"emptyCard"});return t&&(r.description=t),i&&(i.slot="empty-content",r.appendChild(i)),r.isEmpty=!0,r.style.minHeight="150px",r.style.height="min-content",r.style.maxHeight="372px",r.style.marginBottom="25px",r.appendChild(n),r}getDomainName(e){if(!e)return"";try{return`${e[0].toUpperCase()}${e.substring(1)}`}catch(t){return e}}getShoppingTripsFromStorage(e){let t;if(e)try{t=JSON.parse(e)}catch{return}return t?.sort(((e,t)=>e.startDate>t.startDate?-1:1))}isShoppingTripsOlderThan15Days(e){const t=new Date,i=new Date(e);return(t.getTime()-i.getTime())/864e5>15}getShoppingTripsData(e,t){const i=this.getShoppingTripsFromStorage(e);let n=this.flyoutData.dataStoreModule.CashBackData?.shoppingTrips;if(n&&i&&i.length>0&&n.length>0?(n=n?.sort(((e,t)=>e.startDate>t.startDate?-1:1)),i[0].startDate>n[0].startDate&&(n=i)):n||(n=i??[]),this.flyoutData.dataStoreModule.CashBackData?.isCashBackActivated){let e=!1;for(const[t,i]of n.entries())if(i.domain===this.flyoutData.common.domain&&i.status===r.Ex.OfferActivated){e=!0,n[t].startDate=(new Date).toISOString();break}if(!e){const e={startDate:(new Date).toISOString(),domain:this.flyoutData.common.domain,orderNumber:"",cashbackAmount:0,status:r.Ex.OfferActivated,merchantName:Jk(this.flyoutData.common.domain),merchantHomepage:this.flyoutData.common.currentUrl};n.push(e)}}return n&&this.storageHandler.setStorageString(Ce.Q.ShoppingTripsData,JSON.stringify(n)),t&&n&&(n=n?.filter((e=>e.status===r.Ex.OfferActivated))),n?.sort(((e,t)=>e.startDate>t.startDate?-1:1))}},eI=o(15612);class tI extends Qu{constructor(e,t,i){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"flyoutUtilities",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"shouldRenderSimilarSellers",void 0),(0,s.Z)(this,"notRenderedReason",void 0),(0,s.Z)(this,"otherSellersData",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"similarSellersSection",void 0),(0,s.Z)(this,"similarSellersAddedToCartData",void 0),this.flyoutData=e,this.flyoutUtilities=t.autoOpenControllerUtilities,this.utilities=t.viewModulesUtilities,this.pageHandlerModule=t.pageHandlerModule,this.logModule=t.logModule,this.assets=new class{getStyles(){return"\n .divNotificationContent {\n text-align: center;\n overflow: hidden;\n margin-top: -10px;\n }\n msft-shopping-similar-seller {\n border-bottom: 1px solid rgba(0, 0, 0, 0.04);\n }\n msft-shopping-similar-seller:last-of-type {\n border-bottom: none;\n }\n msft-shopping-similar-seller::part(control) {\n box-shadow: none;\n }\n #similarSellerHeader {\n display: inline-block;\n font-size: 24px;\n font-weight: 600;\n line-height: 32px;\n text-align: center;\n padding: 24px;\n border-bottom: 1px solid rgba(0, 0, 0, 0.04);\n }\n #aShipping::part(control) {\n padding-left: 0px;\n }\n "}getDarkModeStyles(){return"\n msft-shopping-similar-seller {\n border-bottom: 1px solid rgba(255, 255, 255, 0.08);\n }\n "}},this.commonAssets=i,this.storageHandler=t.storageHandler,this.telemetryUtilities=t.telemetryHandler,this.setShouldShowOtherSellersModule()}GetModuleName(){return r.ModuleNames.SIMILARSELLERS}CalculateRanking(){return this.otherSellersData&&this.otherSellersData.otherSellers.length>0?(0,ne.K)(this.otherSellersData.productPrice)-(0,ne.K)(this.otherSellersData.otherSellers[0]?.price)>0?r.zz.SaveMoneyPage:r.zz.InformPage:r.zz.Unknown}setOtherSellersData(e){this.otherSellersData=e}async ShouldRenderModule(){return void 0!==this.shouldRenderSimilarSellers?this.shouldRenderSimilarSellers:(await this.setShouldShowOtherSellersModule(),!!this.shouldRenderSimilarSellers)}populateMainHeader(){if(this.utilities.shouldRenderSmallNotification())return;const e=this.flyoutData.common.shopping,t=this.flyoutData.common.domain.includes("amazon")?this.flyoutData.strings.similarSellerStringAmazon:this.flyoutData.strings.similarSellerString;if(e&&this.otherSellersData&&this.otherSellersData?.otherSellers?.length>0){let i=(0,T.fZ)("similarSellerString",t,"$$"),n="",o=0;try{o=this.calculateSavings(),n=`${this.otherSellersData.currency??"$"}${o.toFixed(2)}`,o>0&&(i=t.replace("$1",n))}catch(e){}if(""!==n&&o>0)this.CreateTitle(n);else{const t=(0,Y.Ux)("H2");t.innerText=i,t.className="txtLarge",t.style.textAlign="center",t.style.fontWeight="500";const n=i;t.textContent=n,t.slot="header-content",e.prepend(t)}}}async renderModule(){try{if(this.similarSellersSection=(0,Y.Ux)("msft-edge-shopping-section"),this.similarSellersSection.id="similarSellerDiv",this.similarSellersSection.seeMoreSeparate=!0,this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),this.otherSellersData&&this.otherSellersData.otherSellers?.length>0){const e=this.flyoutData.common.domain.includes("amazon")?this.flyoutData.strings.similarSellerStringCollapsedAmazon:this.flyoutData.strings.similarSellerStringCollapsed;this.populateOtherSellersList(this.similarSellersSection,!1,!1);const t=this.flyoutData;function i(e){let i=r.CS.SIMILARSELLERS;return e&&t.common.bannerContext===r.De.VIEWALL&&(i=e.length),i}return this.utilities.createCommonListStructure(this.similarSellersSection,e,this.otherSellersData.otherSellers,this.GetModuleName(),i,this.populateOtherSellersList.bind(this)),this.updateAutoShowCount(),this.flyoutData.common.openedWith===r.Te.Auto&&this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_OTHER_SELLERS&&this.flyoutData.common.shopping.classList.add("noSections"),Promise.resolve(this.CreateModule(this.similarSellersSection,r.H7.SIMILARSELLERS,r.ModuleNames.SIMILARSELLERS,r.$k.CONTEXTUAL,r.SV.BLOCK))}}catch(n){return Promise.resolve(null)}return Promise.resolve(null)}async updateAutoShowCount(){if(this.flyoutData.common.openedWith===r.Te.Auto&&this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_OTHER_SELLERS){const e=await this.storageHandler.getStorageInteger("OtherSellersAutoShowCount");let t=0;e&&!Number.isNaN(e)&&(t=e),t=t?t+1:1,this.storageHandler.setStorageInteger("OtherSellersAutoShowCount",t),this.storageHandler.setStorageString("OtherSellersLastAutoShowTime",(new Date).toUTCString())}}populateOtherSellersList(e,t,n){const o=this.otherSellersData?.otherSellers,a=this.otherSellersData?.productPrice;if(o){let s=0;o.length>0&&(s=o.length);let l=0;if(t){l=r.CS.SIMILARSELLERS,this.pageHandlerModule.RecordAsUserAction(K.bS.SHOW_MORE_SELLERS),this.pageHandlerModule.RecordAsUserEngagement(q.FV.SHOW_MORE_SELLERS,this.flyoutData.common.popupOrigination);const e=new W.Z(i.$S.SeeMoreSellers,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"Clicked on see more other seller",e)}else s>r.CS.SIMILARSELLERS&&(s=r.CS.SIMILARSELLERS);for(let i=l;i<s;i++){const s=o[i],c=this.createSellerTile(s,a??"",s.index);e.appendChild(c),i===l&&t&&n&&this.flyoutData.common.currentDevice===r.AS.Desktop&&c&&c.focus()}if(this.similarSellersAddedToCartData&&this.similarSellersAddedToCartData.length>0){const e=Date.now();this.similarSellersAddedToCartData=this.similarSellersAddedToCartData.filter((t=>e-t.timestamp<tI.ADDED_TO_CART_TTL));const t=new URL(this.flyoutData.common.lastCommittedURL),i=Jp.Q.OtherSellersAddedToCartDataKey+t.pathname;this.flyoutUtilities.writeSimilarSellers(i,JSON.stringify(this.similarSellersAddedToCartData))}}}createAddedToCartButton(){const e=(0,Y.Ux)("fluent-button"),t=(0,Y.Ux)("DIV");return t.innerHTML=this.commonAssets.getGreenCheck(),t.slot="start",t.style.display="flex",t.setAttribute("aria-hidden","true"),e.disabled=!0,e.slot="actions",e.textContent=this.flyoutData.strings.similarSellerAddedToCartTitle,e.appendChild(t),e.style.backgroundColor="transparent",e.style.boxSizing="border-box",e.style.borderRadius="4px",e.style.opacity="1",e.style.maxWidth="218px",e.style.width="100%",e.style.marginTop="10px",this.utilities.isDarkMode()?(e.style.color="#FFFFFF",e.style.borderColor="#FFFFFF"):e.style.color="#000000",e}async setShouldShowOtherSellersModule(){const e=this.flyoutData.common.domain;if(!e.includes("amazon")&&"walmart.com"!==e)return this.shouldRenderSimilarSellers=!1,void(this.notRenderedReason="not supported domain");if(this.otherSellersData=await this.getSimilarSellersData(),this.otherSellersData&&(this.flyoutData.dataStoreModule.SimilarSellerData=eI.Z.Create(this.otherSellersData),this.flyoutData.dataStoreModule.SimilarSellerData.otherSellers?.length>3)){const e=this.flyoutData.dataStoreModule.SimilarSellerData.otherSellers;this.flyoutData.dataStoreModule.SimilarSellerData.otherSellers=e.slice(0,3)}this.otherSellersData&&this.otherSellersData.otherSellers?.length>0?(this.shouldRenderSimilarSellers=!0,this.similarSellersAddedToCartData=await this.getSimilarSellersAddedToCartData()):this.otherSellersData&&(this.notRenderedReason="other sellers array is empty")}calculateSavings(){let e=0;if(this.otherSellersData&&this.otherSellersData.otherSellers&&this.otherSellersData.otherSellers.length>0){const t=(0,ne.K)(this.otherSellersData.productPrice),i=this.otherSellersData.otherSellers[0]?.totalPrice;if(i)e=t-i;else{e=t-(0,ne.K)(this.otherSellersData.otherSellers[0]?.price);const i=this.otherSellersData.otherSellers[0].delivery.split(" ");if(i?.length>0&&i[0]){const t=parseFloat(i[0].replace("$",""));isNaN(t)||(e-=t)}}}return e}createSellerTile(e,t,i){const n=(0,Y.Ux)("msft-shopping-similar-seller");try{if(n.actionButtonText=this.flyoutData.strings.similarSellerAddToCartTitle,n.pressedActionButtonText=this.flyoutData.strings.similarSellerInCartTitle,n.actionButtonAriaLabel=this.flyoutData.strings.similarSellerAddToCartAriaLable,n.onClickHandler=()=>{n.actionButtonPressed=!0,this.addToCartHandler(e,t,i)},this.similarSellersAddedToCartData){const t=this.similarSellersAddedToCartData.find((t=>t.index===e.index));t&&Date.now()-t.timestamp<tI.ADDED_TO_CART_TTL&&(n.actionButtonPressed=!0)}let o=e.heading.replace(/\s+/g," ");o=o.substring(0,Math.min(18,o.length)),n.itemTitle=o,n.itemTitleId=o;const r=(0,ne.nR)(e.price,!0);if("object"==typeof r?(n.itemCurrency=r.currency,n.itemPrice=r.dollars,n.itemPriceHundredths=r.cents):n.itemPrice=e.price,e.delivery&&this.flyoutData.common.domain.includes("amazon")){const t=e.delivery.replace(/ |\r\n|\n|\r/gm," ").replace("Delivery","delivery").trim();let i="delivery";t.includes(":")&&(i+=":");const o=t.split(i);let r="",a="";o.length>=2&&(r=o[0].trim()+" Delivery",a=o[1].trim()),a&&a.indexOf("Fastest")>=0&&(a=a.substring(0,a.indexOf("Fastest")).trim()),a&&a.indexOf("Order")>=0&&(a=a.substring(0,a.indexOf("Order")).trim()),a&&a.indexOf("Details")>=0&&(a=a.substring(0,a.indexOf("Details")).trim()),a&&(n.deliveryLabel=r+": ",n.deliveryLabelId=n.deliveryLabel,n.deliveryInfo=a,n.deliveryInfoId=a),r.includes(e.currency)&&(n.hasShippingCost=!0)}if(e.delivery&&"walmart.com"===this.flyoutData.common.domain){const t=e.delivery.split("+");t&&(n.deliveryInfo=t[0],n.deliveryInfo=n.deliveryInfo,t.length>1?(n.hasShippingCost=!0,n.deliveryLabel=t[1].trim()):n.deliveryLabel=this.flyoutData.strings.similarSellerFreeDelivery,n.deliveryLabel+=": ",n.deliveryLabelId=n.deliveryLabel,n.deliveryInfo=n.deliveryInfo)}if(e.soldBy){n.shipperLabel=`${this.flyoutData.strings.similarSellerShipFromString} `,n.shipperLabelId=`${this.flyoutData.strings.similarSellerShipFromString} `,n.shipperName=(0,Y.oZ)(e.soldBy.toString());const t=e.soldBy.split(" ");t?.length>=4&&(n.shipperName=t.slice(-2).join(" ")),n.shipperLinkId=n.shipperName,this.flyoutData.dataLoader.IsServerData()&&e.sellerUrl&&(n.shipperUrl=e.sellerUrl,n.shipperUrl.includes("https://www.")||(n.shipperUrl="https://www."+this.flyoutData.common.domain+"/"+e.sellerUrl),n.linkClickHandler=()=>{this.navigateToOtherSeller(e,n.shipperUrl,ju.$.NEW_FOREGROUND_TAB)})}return e.rating&&(n.ratingLabel=`${this.flyoutData.strings.similarSellerRatingLabel} `,n.ratingLabelId=`${this.flyoutData.strings.similarSellerRatingLabel} `,n.rating=e.rating.toString(),n.ratingId=n.rating),n}catch(e){}return new HTMLElement}navigateToOtherSeller(e,t,n){const o=new W.Z(i.$S.NavigateToOtherSeller,this.telemetryUtilities.setContentViewed(this.GetModuleName()),void 0,JSON.stringify(e));this.pageHandlerModule.RecordAsUserAction(K.bS.NAVIGATE_TO_OTHER_SELLER),this.pageHandlerModule.RecordAsUserEngagement(q.FV.NAVIGATE_TO_OTHER_SELLER,this.flyoutData.common.popupOrigination),this.logModule.LogInfoEvent(i.R.ButtonClick,"Clicked on other seller link",o),this.pageHandlerModule.NavigateToOtherSellerWithDisposition(t,n)}addToCartHandler(e,t,n){try{this.storageHandler.clearStorage("OtherSellersAutoShowCount");const o=new W.Z(i.$S.AddToCart,this.telemetryUtilities.setContentViewed(this.GetModuleName()),void 0,JSON.stringify(e));this.pageHandlerModule.RecordAsUserAction(K.bS.ADD_TO_CART_FROM_OTHER_SELLER),this.pageHandlerModule.RecordAsUserEngagement(q.FV.NAVIGATE_TO_OTHER_SELLER,this.flyoutData.common.popupOrigination),this.pageHandlerModule.AddItemFromOtherSeller(JSON.stringify({action:eg.v.OtherSellers,data:{OtherSeller:{Currency:e.currency,ItemIndex:n,ItemPrice:(0,ne.K)(e.price),OriginalItemPrice:(0,ne.K)(t)},SkipAutoApply:!0}}));const r=new URL(this.flyoutData.common.lastCommittedURL),a=Jp.Q.OtherSellersAddedToCartDataKey+r.pathname;if(this.otherSellersData){const t=this.otherSellersData?.otherSellers.find((t=>t.index===e.index));t&&(t.addedToCart=!0)}this.similarSellersAddedToCartData||(this.similarSellersAddedToCartData=[]),this.similarSellersAddedToCartData.push(new class{constructor(e){(0,s.Z)(this,"index",void 0),(0,s.Z)(this,"timestamp",void 0),this.index=e,this.timestamp=Date.now()}}(n)),this.flyoutUtilities.writeSimilarSellers(a,JSON.stringify(this.similarSellersAddedToCartData)),this.logModule.LogInfoEvent(i.R.ButtonClick,"Added to the cart",o,Jl.g.CouponImpressionId)}catch(e){}}async getSimilarSellersAddedToCartData(){const e=new t.Z(i.xu.OtherSeller);try{const t=new URL(this.flyoutData.common.lastCommittedURL),i=await this.storageHandler.getStorageString(Jp.Q.OtherSellersAddedToCartDataKey+t.pathname);if(e.Metadata=t.pathname,!(0,p.TF)(i))return JSON.parse(i)}catch(t){this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Failed to deserialize added to cart data",e,Jl.g.CouponImpressionId)}}async getSimilarSellersData(){const e=new t.Z(i.xu.OtherSeller);try{const t=new URL(this.flyoutData.common.lastCommittedURL),n=await this.storageHandler.getStorageString("OtherSellersData_"+t.pathname);if(e.Metadata=t.pathname,(0,p.TF)(n))this.notRenderedReason="data is null or has space error",this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Null or Space Error",e,Jl.g.CouponImpressionId);else{const o=JSON.parse(n);if(o&&o.otherSellers?.length>0){if(o.productUrl!==t.pathname)return this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"ProductURL error",e,Jl.g.CouponImpressionId),this.notRenderedReason="product url error",Promise.resolve(null);const n=Date.now();return void 0===o.dataCreationTime||n-o.dataCreationTime>eI.F?(this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Data expiration error",e,Jl.g.CouponImpressionId),this.notRenderedReason="data expiration error",Promise.resolve(null)):Promise.resolve(o)}this.notRenderedReason="other sellers array is empty"}}catch(t){this.notRenderedReason="failed to deserialize data",this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Failed to deserialize data",e,Jl.g.CouponImpressionId)}return Promise.resolve(null)}async CreateTitle(e){const t=this.flyoutData.common.domain;if(!e)return;const i=(0,Y.Ux)("div");i.id="similarSellerHeader";const n=t.includes("amazon")?this.flyoutData.strings.similarSellerTitleAmazon:this.flyoutData.strings.similarSellerTitle,o=(0,Y.Ux)("span",{style:"color: var(--text-green-savings-color);"});o.textContent=e,(0,T.B7)(i,n,o),this.similarSellersSection.prepend(i),this.similarSellersSection.isHeader=!0,this.similarSellersSection.slot="header-content";const r=this.similarSellersSection.querySelector(".btnSeeMore");r&&r.classList.add("btnSeeMoreSeparate")}}(0,s.Z)(tI,"ADDED_TO_CART_TTL",3e5);var iI=tI,nI=class{static async getOtherSellerConfirmationData(e,t){try{const i="OtherSellersConfirmationData_"+new URL(e.common.lastCommittedURL).pathname,n=await t.getStorageString(i);if(!(0,p.TF)(n))return t.clearStorage(i),Promise.resolve(JSON.parse(n))}catch(e){return Promise.resolve(null)}return Promise.resolve(null)}},oI=class extends iI{constructor(e,t,i){super(e,t,i),(0,s.Z)(this,"otherSellersNotificationData",void 0),(0,s.Z)(this,"offerToShow",void 0),(0,s.Z)(this,"CurrencyAnomalyThresholds",new Map([["$",1],["€",1],["CNY",7],["CHF",1],["KRW",1233],["TWD",31],["PHP",55],["DKK",7],["NZD",2],["EGP",25],["CZK",23],["AUD",1],["CAD",1],["GBP",1],["PLN",4],["NGN",416],["INR",70],["COP",4378],["CLP",873],["SEK",10],["TRY",19],["THB",35],["MXN",18],["ILS",3],["KES",116],["NOK",10],["AED",4],["HKD",8],["BGN",2],["BRL",5],["TTD",7],["IDR",15408],["NAD",17],["MYR",4],["JMD",154],["HUF",334],["JPY",133],["PEN",4],["RUB",82],["GHS",10],["KZT",449],["BBD",2],["MOP",8],["BMD",1],["VND",23236],["PYG",6855],["MAD",10],["TZS",2332],["BSD",1],["AZN",2],["BOB",7],["DOP",55],["PAB",1],["XCD",3]]))}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_ITEM_ADDED_TO_CART_FROM_OTHER_SELLER,u.sR.AUTO_SHOW_OTHER_SELLERS]}PostProcessingNotification(e,t){if(this.otherSellersNotificationData?.Success){const e=this.createAddedToCartButton();e&&this.flyoutData.common.shopping.appendChild(e)}}async RenderNotification(){let e;return this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_OTHER_SELLERS?this.otherSellersData&&this.offerToShow&&(e=this.renderSmallNotification(this.offerToShow,this.otherSellersData?.productPrice,0),this.updateAutoShowCount()):this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_ITEM_ADDED_TO_CART_FROM_OTHER_SELLER&&(e=await this.renderSimilarSellerConfirmation()),this.utilities.createNotificationModule(e,this.GetNotificationName(),this)}async ShouldRenderNotification(){if(e.R.getServiceExperimentValue(f.H.disableNotificationForSimilarSellers))return Promise.resolve(!1);const n=this.flyoutData.common.openedWith===r.Te.Auto&&this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_ITEM_ADDED_TO_CART_FROM_OTHER_SELLER;await this.setShouldShowOtherSellersModule();const o=this.flyoutData?.dataStoreModule?.SimilarSellerData?.otherSellers;if(this.otherSellersData&&o){for(const e of o)if(this.isAboveAnomalyThreshold(e.price,this.otherSellersData.productPrice,this.otherSellersData.currency)){this.offerToShow=e;break}this.offerToShow||(this.notRenderedReason="No seller is above anomaly threshold")}const a=this.flyoutData.common.openedWith===r.Te.Auto&&this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_OTHER_SELLERS&&this.shouldRenderSimilarSellers;if(!(this.flyoutData.common.openedWith!==r.Te.Auto||this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_OTHER_SELLERS||this.shouldRenderSimilarSellers&&this.offerToShow)){const e=new t.Z(i.xu.OtherSellerNotification);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,this.notRenderedReason,e)}return Promise.resolve(a||n)}GetNotificationName(){return this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_OTHER_SELLERS?r.sM.SIMILARSELLERS_NOTIFICATION:r.sM.SIMILARSELLERS_CONFIRMATION_NOTIFICATION}renderSmallNotification(e,t,i){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles()),this.flyoutData.common.shopping.classList.add("noSections");const n=(0,Y.Ux)("DIV",{style:"display: flex;\n flex-direction: column;\n text-align: left;\n width: 100%;"});n.slot="header-content";const o=(0,Y.Ux)("msft-notification-header"),r=this.flyoutData.common.market;r&&r.includes("jp")?o.title="お得なオプションが見つかりました!":o.title=this.flyoutData.strings.commonSaveOtherSellers;const a=this.calculateSavings();if(a>0&&this.otherSellersData?r&&r.includes("jp")?o.savings=`-${this.otherSellersData.currency??"$"}${this.utilities.formatPrice(a)}`:o.savings=`${this.otherSellersData.currency??"$"}${this.utilities.formatPrice(a)}`:o.title=this.flyoutData.strings.similarSellerStringSubtitleAmazon,this.otherSellersData?.productImage){const t=(0,Y.Ux)("IMG");t.src=this.flyoutData.common.urlPrefix+this.otherSellersData.productImage;const i=this.utilities.createProductImage(60,60,t,e.heading);i.slot="image",o.appendChild(i)}const s=(0,Y.Ux)("DIV",{style:"display: flex; flex-direction: column;\n font-size: 12px; line-height: 16px; font-weight: 400;\n margin-top: 8px;"});s.classList.add("lateralMargin");const l=this.createSellerTile(e,t,i);if(l.shipperName){const t=(0,Y.Ux)("SPAN"),i=(0,Y.Ux)("fluent-anchor",{style:"\n vertical-align: super;\n display: inline-block;\n margin-left: 3px;\n line-height: 16px;\n height: 16px;\n "});i.textContent=l.shipperName,i.href="#",i.id="aShipping",i.addEventListener("click",(()=>{this.navigateToOtherSeller(e,l.shipperUrl,ju.$.NEW_FOREGROUND_TAB)})),i.appearance="lightweight",t.textContent=this.flyoutData.strings.similarSellerShipFromString,t.appendChild(i),s.appendChild(t)}const c=(0,Y.Ux)("DIV",{style:"display: inline;"});if(l.deliveryInfo){const e=(0,Y.Ux)("SPAN");"."===l.deliveryInfo[l.deliveryInfo.length-1]&&(l.deliveryInfo=l.deliveryInfo.replace(".","")),e.textContent=l.deliveryLabel+l.deliveryInfo;const t=(0,Y.Ux)("SPAN",{style:"vertical-align: super;\n margin-left: 4px;\n margin-right: 2px;"});t.textContent=".",c.appendChild(e),c.appendChild(t)}const d=(0,Y.Ux)("SPAN");d.textContent=l.itemTitle,c.appendChild(d),s.appendChild(c),n.appendChild(o);const u=(0,Y.Ux)("HR",{style:"border: 1px solid #000000;\n opacity: 0.04;\n margin-bottom: 0px;\n margin-top: 0px;\n border-bottom: unset;\n width: 100%;"});n.appendChild(u),n.appendChild(s);const h=(0,Y.lw)(this.utilities);return h.slot="actions",h.textContent=(0,T.fZ)("similarSellerNewAddToCartTitle",this.flyoutData.strings.similarSellerNewAddToCartTitle,e.price),h.style.marginTop="12px",h.classList.add("lateralMargin"),h.addEventListener("click",(()=>{this.addToCartHandler(e,t,i)})),this.flyoutData.common.shopping.appendChild(h),n}async renderSimilarSellerConfirmation(){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles()),this.otherSellersNotificationData=await nI.getOtherSellerConfirmationData(this.flyoutData,this.storageHandler);const e=(0,Y.Ux)("DIV",{id:"productAddedPopup"});e.slot="header-content";const n=(0,Y.Ux)("DIV",{className:"txtMedium"});n.className="divNotificationContent";let o="";o=this.otherSellersNotificationData?.Success?(0,T.fZ)("similarSellerNotificationTitle",this.flyoutData.strings.similarSellerNotificationTitle,"$"+this.otherSellersNotificationData.Savings):this.flyoutData.strings.similarSellerNotificationError;const r=(0,Y.Ux)("H2",{style:"margin: 0px; font-weight: 500; font-size: 24px; line-height: 34px;"},o);n.appendChild(r),e.appendChild(n);const a=new t.Z(i.xu.AddedToCartNotification);return this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"User saw other seller added to cart notification",a,Jl.g.CouponImpressionId),e}isAboveAnomalyThreshold(e,t,i){try{const n=(0,ne.K)(e),o=(0,ne.K)(t),r=Math.abs(n-o),a=this.CurrencyAnomalyThresholds.get(i)??void 0;return!a||r>0&&r>=a}catch(e){return!1}}},rI=class extends Qu{constructor(e,t,i,n){super(),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"renderedPageType",void 0),(0,s.Z)(this,"telemetryHandler",void 0),(0,s.Z)(this,"uxUtils",void 0),(0,s.Z)(this,"similarProducts",[]),(0,s.Z)(this,"comparedAttributes",[]),(0,s.Z)(this,"moduleName",r.ModuleNames.SMART_COMPARE),(0,s.Z)(this,"cardCount",0),(0,s.Z)(this,"smartCompareSection",void 0),(0,s.Z)(this,"isDarkMode",!1),(0,s.Z)(this,"BaseImgUrl","https://th.bing.com"),(0,s.Z)(this,"sectionId","SimilarProductsSection"),this.flyoutData=e,this.uxUtils=t,this.utilities=t.viewModulesUtilities,this.telemetryHandler=t.discoverTelemetryHandler,this.pageHandlerModule=t.pageHandlerModule,this.logModule=t.logModule,this.storageHandler=t.storageHandler,this.commonAssets=i,this.stateManagement=n,this.isDarkMode=this.utilities.isDarkMode(),this.assets=new class{getStyles(){return"\n .spContent {\n display: flex;\n flex-direction: column;\n padding: 16px 0;\n }\n .spContentShoppingPane {\n border-radius: 12px;\n margin: 12px 16px;\n box-shadow: 0px 2px 4px rgba(0, 0, 0, 0.14), 0px 0px 2px rgba(0, 0, 0, 0.12);\n }\n .spContent.spDiscoverDisplay {\n padding: 4px 0 16px 0;\n }\n .spImgLabel {\n position: absolute;\n bottom: 8px;\n margin: 0;\n font-weight: 600;\n font-size: 10px;\n line-height: 13px;\n padding: 4px 8px;\n border-radius: 6px;\n background: #E6ECFF;\n color: #3267FA;\n white-space: nowrap;\n text-overflow: ellipsis;\n max-width: 90%;\n overflow: hidden;\n }\n .spImgLabelTrending {\n background: #E6ECFF;\n color: #3267FA;\n }\n .spImgLabelBestMatch {\n background: #DCFAED;\n color: #138757;\n }\n .spTitle {\n display: flex;\n color: #242424;\n font-style: normal;\n font-weight: 400;\n font-size: 12px;\n line-height: 16px;\n margin: 0;\n flex: 1;\n overflow: hidden;\n text-overflow: ellipsis;\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n }\n .spDiscoverDisplay .similarProductsCard {\n min-width: 93px;\n max-width: 93px;\n }\n .scRemoveOfferIconBtn {\n width: fit-content;\n align-self: flex-end;\n min-height: 22px;\n min-width: 22px;\n max-width: 22px;\n max-height: 22px;\n justify-content: center;\n align-items: center;\n margin-right: -8px;\n position: absolute;\n z-index: 2;\n }\n .similarProductsSuggestionsContainer {\n display: flex;\n gap: 8px;\n overflow-x: scroll;\n scroll-behavior: smooth;\n }\n .similarProductsSuggestionsContainer::-webkit-scrollbar {\n display: none;\n }\n .spFullSpecBtn {\n background: linear-gradient(129.58deg, #2870EA 20.88%, #2870EA 20.89%, #1B4AEF 77.37%);\n -webkit-background-clip: text;\n -webkit-text-fill-color: transparent;\n background-clip: text;\n text-fill-color: transparent;\n font-weight: 600;\n font-size: 13px;\n line-height: 20px;\n border: unset;\n cursor: pointer;\n margin-left: 16px;\n margin-top: 8px;\n margin-bottom: 10px;\n }\n .similarProductsCard {\n display: flex;\n flex-direction: column;\n flex: 1;\n background: #ffffff;\n padding: 8px 16px 16px 16px;\n border-radius: 8px;\n min-width: 105px;\n max-width: 105px;\n justify-content: space-between;\n cursor: pointer;\n position: relative;\n }\n .similarProductsCard:first-child {\n margin-left: 16px;\n }\n .similarProductsCard:last-child {\n margin-right: 16px;\n }\n .spImageContainer {\n border-radius: 6px;\n width: 100px;\n height: 100px;\n display: flex;\n justify-content: center;\n align-items: center;\n position: relative;\n }\n .spDiscoverDisplay .spImageContainer {\n width: 90px;\n height: 90px;\n }\n .spImage {\n max-width: 100%;\n max-height: 100%;\n }\n .scRetailerInfoContainer {\n display: flex;\n gap: 4px;\n }\n .retailerName {\n margin: 0;\n }\n .spRetailerImage {\n min-width: 10px;\n min-height: 10px;\n max-width: 10px;\n man-height: 10px;\n }\n .spPricesContainer {\n display: flex;\n gap: 4px;\n margin: 4px 0 4px 0;\n }\n .spPriceOld {\n display: flex;\n align-items: flex-end;\n color: #6C6C6C;\n text-decoration-line: line-through;\n font-weight: 400;\n font-size: 12px;\n line-height: 20px;\n margin: 0;\n }\n .spPriceNew {\n font-weight: 600;\n font-size: 18px;\n line-height: 22px;\n color: #D63600;\n margin: 0;\n }\n .spPrice {\n font-style: normal;\n font-weight: 600;\n font-size: 18px;\n line-height: 22px;\n display: flex;\n align-items: flex-end;\n color: #242424;\n margin: 0;\n }\n .spMoreBuyingOptions {\n border: unset;\n font-weight: 600;\n font-size: 12px;\n line-height: 20px;\n background: linear-gradient(129.58deg, #2870EA 20.88%, #2870EA 20.89%, #1B4AEF 77.37%);\n -webkit-background-clip: text;\n -webkit-text-fill-color: transparent;\n background-clip: text;\n text-fill-color: transparent;\n padding: 0;\n margin: 0;\n text-align: left;\n cursor: pointer;\n }\n .spRatingsContainer {\n display: inline-flex;\n margin: 4px 0 4px 0;\n align-items: center;\n }\n .spRaitingImage {\n margin: 0px 5px 0px 0px;\n height: 12px;\n width: 12px;\n }\n .spRatingText {\n font-size: 12px;\n margin: 0;\n font-weight: 400;\n }\n .spRatingValue {\n font-weight: 600;\n }\n .scChevron {\n position: absolute;\n margin-top: 110px;\n min-width: 28px;\n min-height: 28px;\n max-width: 28px;\n max-height: 28px;\n background: #FFFFFF;\n border-radius: 874.125px;\n z-index: 10;\n }\n .scChevron svg {\n fill: #1A1A1A;\n }\n .scChevronRight {\n right: 25px;\n transform: rotate(90deg) scaleY(-1);\n box-shadow: 7px 0px 14px rgba(0, 0, 0, 0.14);\n }\n .scChevronLeft {\n left: 25px;\n transform: rotate(90deg);\n box-shadow: 7px 0px 14px rgba(0, 0, 0, 0.14);\n }\n\n .scSpecColumnContainer {\n display: none;\n gap: 8px;\n overflow-x: scroll;\n scroll-behavior: smooth;\n }\n .scSpecColumnContainer::-webkit-scrollbar {\n display: none;\n }\n .scSpecColumn {\n display: flex;\n flex-direction: column;\n gap: 8px;\n width: 138px;\n }\n .spDiscoverDisplay .scSpecColumn {\n width: 127px;\n }\n .scSpecColumn:first-child {\n margin-left: 16px;\n }\n .scSpecColumn:last-child {\n margin-right: 16px;\n }\n .scSpecProductBasicsContainer {\n display: flex;\n box-sizing: border-box;\n padding: 16px 8px;\n gap: 8px;\n width: 100%;\n height: 79px;\n background: #FFFFFF;\n border: 1px solid #EEEEEE;\n border-radius: 8px;\n cursor: pointer;\n }\n .scSpecCardImage {\n display: flex;\n max-width: 47px;\n max-height: 47px;\n border-radius: 1.875px;\n }\n .spDiscoverDisplay .scSpecCardImage {\n max-width: 32px;\n }\n .scSpecTitlePriceContainer {\n display: flex;\n flex-direction: column;\n gap: 4px;\n }\n .scSpecCardProductTitle {\n font-style: normal;\n font-weight: 400;\n font-size: 14px;\n line-height: 20px;\n margin: 0;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n max-width: 70px;\n }\n .scSpecCardPrice {\n font-style: normal;\n font-weight: 600;\n font-size: 16px;\n line-height: 22px;\n display: flex;\n color: #242424;\n margin: 0;\n }\n .scSpecCardPriceDiscount {\n color: #D63600;\n }\n .scSpecAttributeCard {\n box-sizing: border-box;\n padding: 8px 16px;\n background: #FFFFFF;\n border: 1px solid #EEEEEE;\n border-radius: 8px;\n }\n .scSpecCardNameContainer {\n display: flex;\n gap: 4px;\n }\n .scSpecCardName {\n font-style: normal;\n font-weight: 600;\n font-size: 12px;\n line-height: 16px;\n color: #242424;\n margin: 0;\n }\n .scSpecCardValue {\n font-style: normal;\n font-weight: 400;\n font-size: 14px;\n line-height: 20px;\n color: #242424;\n margin: 0;\n margin-top: 4px;\n }\n .scBestSpec p {\n color: #138757;\n }\n .bestCheck {\n display: flex;\n height: 12px;\n width: 12px;\n }\n .bestCheck svg {\n fill: #138757;\n }\n .hidden {\n visibility: hidden;\n }\n "}getDarkModeStyles(){return"\n .spContentShoppingPane {\n border: 1px solid rgba(255, 255, 255, 0.1);\n box-shadow: 0px 2px 4px rgba(0, 0, 0, 0.14), 0px 0px 2px rgba(0, 0, 0, 0.12);\n }\n .spTitle {\n color: #FFFFFF;\n }\n .scIconBtn {\n background: #323130;\n border: 1px solid #484644;\n }\n .spFullSpecBtn {\n color: #A2B7F4;\n background: #424242;\n -webkit-text-fill-color: inherit;\n }\n .similarProductsCard {\n border: 1px solid #484644;\n background: #3B3A39;\n }\n .spImageContainer {\n border: 0.3125px solid rgba(0, 0, 0, 0.05);\n }\n .spPriceOld {\n color: #FFFFFF;\n }\n .spPriceNew {\n color: #F5460C\n }\n .spPrice {\n color: #FFFFFF\n }\n .scChevron {\n background: #323130;\n border: 1px solid #484644;\n }\n .scChevron svg {\n fill: #FFFFFF;\n }\n .scChevronRight {\n box-shadow: 0.6px 0px 1.8px rgba(0, 0, 0, 0.1), 3.2px 0px 7.2px rgba(0, 0, 0, 0.13)\n }\n .scChevronLeft {\n box-shadow: 0.6px 0px 1.8px rgba(0, 0, 0, 0.1), 3.2px 0px 7.2px rgba(0, 0, 0, 0.13)\n }\n .scSpecProductBasicsContainer {\n background: #3B3A39;\n border: 1px solid #484644;\n }\n .scSpecCardProductTitle {\n color: #EDEBE9;\n }\n .scSpecCardPrice {\n color: #EDEBE9;\n }\n .scSpecCardPriceDiscount {\n color: #D63600;\n }\n .scSpecAttributeCard {\n background: #3B3A39;\n border: 1px solid #484644;\n }\n .scSpecCardName {\n color: #EDEBE9;\n }\n .scSpecCardValue {\n color: #EDEBE9;\n }\n .scBestSpec p {\n color: #77E0B4;\n }\n .bestCheck svg {\n fill: #77E0B4;\n }\n "}}}GetModuleName(){return r.ModuleNames.SMART_COMPARE}async ShouldRenderModule(){if(this.comparedAttributes=this.GetComparedAttributes(),this.similarProducts=this.GetSimilarProducts(),this.similarProducts.length>0){if(this.stateManagement.AddDiscoverRenderModule(r.ModuleNames.SMART_COMPARE),e.R.isExperimentActive(f.H.discoverShopping)&&this.flyoutData.common.isDiscoverPane)return Promise.resolve(!0);if(e.R.isTestFlagActive(Zt.t.msShoppingTestExp99))return Promise.resolve(!0)}return Promise.resolve(!1)}populateMainHeader(){const e=this.flyoutData.common.shopping.querySelector("#SimilarProductsSection");e&&(e.slot="header-content")}async renderModule(){try{this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());const e=(0,Y.Ux)("msft-edge-shopping-section"),t=e;return t.id=this.sectionId,t.titleText=this.flyoutData.strings.scSectionTitle,t.accordion=this.flyoutData.common.currentDevice===r.AS.Desktop,t.expanded=!0,this.CreateUx(t),Promise.resolve(this.CreateModule(e,r.H7.SMART_COMPARE,r.ModuleNames.SMART_COMPARE,r.$k.CONTEXTUAL,r.SV.LIST))}catch(e){this.telemetryHandler.LogErrorTelemetry("Error in render SmartCompare. Unexpected error",this.renderedPageType,this.moduleName,e,{offersCount:this.similarProducts.length})}return Promise.resolve(null)}PostProcessing(e,t,n){const o=`position ${t}`;0===t&&this.flyoutData.common.isDiscoverPane&&this.telemetryHandler.LogEventTelemetry(i.xu.SmartCompare,o,this.renderedPageType,e,{offersCount:this.similarProducts.length},bp.r.SMART_COMPARE)}GetSimilarProducts(){const e=this.flyoutData.dataStoreModule.DiscoverShoppingData?.SmartCompareData;return e?.smartCompareOptions||[]}GetComparedAttributes(){return this.flyoutData.dataStoreModule.DiscoverShoppingData?.SmartCompareData?.comparedAttributes||[]}GetEmptyImage(){return this.flyoutData.common.resourcesEndpoint+"common/defaultProduct.svg"}CreateUx(e){const t=(0,Y.Ux)("div");t.className="spContent",this.flyoutData.common.isDiscoverPane?t.classList.add("spDiscoverDisplay"):t.classList.add("spContentShoppingPane");const n=(0,Y.Ux)("div");n.className="similarProductsContainer";const o=(0,Y.Ux)("div");o.className="scSpecColumnContainer";const r=[];this.similarProducts.forEach((e=>{const t=this.CreateSpecColumn(o,e);r.push(t)}));const a=(0,Y.Ux)("div");a.className="similarProductsSuggestionsContainer",this.similarProducts.length<=2&&a.classList.add("twoOrLess"),a.title=this.flyoutData.strings.scContainerTitle,this.cardCount=this.similarProducts.length,this.similarProducts.forEach(((e,t)=>{this.CreateSimilarProductCard(a,n,e,t,r)}));const s=this.MakeChevron(a,o,n),l=this.MakeChevron(a,o,n,!0);l.hidden=!0,this.similarProducts.length<3&&(s.hidden=!0),n.appendChild(s),n.appendChild(l),n.appendChild(a),n.appendChild(o);const c=this.MakeShowFullSpecBtn(a,o,n);if(this.similarProducts.find((e=>e.specs.length>0))&&n.appendChild(c),this.flyoutData.common.isDiscoverPane){const e=()=>{const n={similarProducts:this.similarProducts,offersCount:this.similarProducts.length};this.telemetryHandler.LogEventTelemetry(i.xu.SmartCompareHover,"Smart Compare Hover",this.renderedPageType,this.moduleName,n,void 0,q.FV.SMART_COMPARE),t.removeEventListener("mouseover",e)};t.addEventListener("mouseover",e)}t.appendChild(n),e.appendChild(t)}MakeChevron(e,t,i,n=!1){let o=this.flyoutData.strings.scChevronRightTitle,r="scChevronRight",a=145,s=0;this.flyoutData.common.isDiscoverPane&&(a=133),this.isDarkMode&&(s=2),n&&(o=this.flyoutData.strings.scChevronLeftTitle,r="scChevronLeft",a=0-a);const l=Dp(o,this.commonAssets.getChevronIcon);return l.className="scChevron",l.role="button",l.classList.add(r),l.addEventListener("click",(n=>{n.stopPropagation();let o=e,r=e.scrollLeft+a+s;"flex"===t.style.display&&(o=t,r=t.scrollLeft+a),e.scrollLeft=r,t.scrollLeft=r,Array.from(i.getElementsByClassName("scChevron")).forEach((e=>{this.ToggleChevronDisplay(o,e,r)}))})),l}CreateSimilarProductCard(e,t,n,o,r){const a=(0,Y.Ux)("a");a.className="similarProductsCard",a.id="icc_similarProducts_"+n.title,a.title=n.title,a.tabIndex=0,a.addEventListener("click",(()=>{a.classList.add("selected"),this.flyoutData.common.isDiscoverPane&&this.telemetryHandler.LogClickTelemetry(i.xu.SmartCompareClick,n.title,this.renderedPageType,this.moduleName,{offersCount:this.similarProducts.length},q.FV.SMART_COMPARE),window.open(n.url,"_blank")}));const s=(0,Y.Ux)("p",void 0,n.title);s.className="spTitle",(0,Y.Ux)("p",void 0,n.description).className="spDescription";const l=(0,Y.Ux)("div");l.className="spGroup";const c=this.MakeImageContainer(n);l.appendChild(c);const d=this.MakeRatingsContainer(n);d?l.appendChild(d):c.style.marginBottom="12px";const u=(0,Y.Ux)("div");u.className="spGroup",u.appendChild(this.MakePriceContainer(n));const h=Dp(this.flyoutData.strings.scRemoveOffer,Ip);h.role="button",h.className="scRemoveOfferIconBtn hidden",h.addEventListener("click",(i=>{i.stopPropagation(),this.cardCount>1&&(a.remove(),r.length>o&&r[o].remove(),Array.from(t.getElementsByClassName("scChevron")).forEach((t=>{this.ToggleChevronDisplay(e,t,e.scrollLeft)})),this.cardCount-=1)}));const p=()=>{h.classList.add("hidden")},g=()=>{this.cardCount>1&&h.classList.remove("hidden")};return a.addEventListener("mouseover",g),a.addEventListener("mouseout",p),a.addEventListener("focusin",g),h.addEventListener("focusout",p),a.appendChild(h),a.appendChild(l),a.appendChild(s),a.appendChild(u),a.appendChild(this.MakeRetailerInfoContainer(n)),e.appendChild(a),a}CreateSpecColumn(e,t){const n=(0,Y.Ux)("div");n.className="scSpecColumn",n.id="icc_scSpeccolumn_"+t.title,n.title=t.title,n.addEventListener("click",(()=>{n.classList.add("selected"),this.flyoutData.common.isDiscoverPane&&this.telemetryHandler.LogClickTelemetry(i.xu.SmartCompareSpecCardClick,t.title,this.renderedPageType,this.moduleName,{offersCount:this.similarProducts.length},q.FV.SMART_COMPARE)}));const o=(0,Y.Ux)("div");o.tabIndex=0,o.className="scSpecProductBasicsContainer";const r=this.MakeSpecCardImage(t);o.appendChild(r);const a=this.MakeSpecPriceTitleContainer(t);return o.appendChild(a),o.addEventListener("click",(e=>{e.stopPropagation(),this.flyoutData.common.isDiscoverPane&&this.telemetryHandler.LogClickTelemetry(i.xu.SmartCompareSpecCardBasicsClick,t.title,this.renderedPageType,this.moduleName,{offersCount:this.similarProducts.length},q.FV.SMART_COMPARE),window.open(t.url,"_blank")})),n.appendChild(o),t.specs.forEach((e=>{const t=(0,Y.Ux)("div");t.className="scSpecAttributeCard";const i=(0,Y.Ux)("div");i.className="scSpecCardNameContainer";const o=(0,Y.Ux)("p",void 0,e.name);if(o.className="scSpecCardName",o.role="heading",i.appendChild(o),e.best){t.classList.add("scBestSpec");const e=(0,Y.Ux)("div");e.className="bestCheck",e.innerHTML=this.commonAssets.getGreenCheckCircle(),i.appendChild(e)}t.appendChild(i);const r=(0,Y.Ux)("p",void 0,e.value);r.className="scSpecCardValue",t.appendChild(r),n.appendChild(t)})),e.appendChild(n),n}MakeShowFullSpecBtn(e,t,n){const o=(0,Y.Ux)("button",void 0,this.flyoutData.strings.scShowFullSpec);return o.className="spFullSpecBtn",o.addEventListener("click",(r=>{r.stopPropagation(),e.style.display="none",o.style.display="none",t.style.display="flex",Array.from(n.getElementsByClassName("scChevron")).forEach((e=>{e.style.marginTop="66px",this.ToggleChevronDisplay(t,e,t.scrollLeft)}));const a=Array.from(t.getElementsByClassName("scSpecColumn")),s=[];a.forEach((e=>{Array.from(e.getElementsByClassName("scSpecAttributeCard")).forEach(((e,t)=>{const i=e;(void 0===s[t]||i.offsetHeight>s[t])&&(s[t]=i.offsetHeight)}))})),a.forEach((e=>{Array.from(e.getElementsByClassName("scSpecAttributeCard")).forEach(((e,t)=>{e.style.height=`${s[t]}px`}))})),this.flyoutData.common.isDiscoverPane&&this.telemetryHandler.LogClickTelemetry(i.xu.SmartCompareFullSpecsButtonClick,"Smart Compare Full spec button clicked",this.renderedPageType,this.moduleName,{offersCount:this.similarProducts.length},q.FV.SMART_COMPARE)})),o}MakeRatingsContainer(e){if(!e.ratingReviews||!e.ratingReviews?.numberOfReviews||!e.ratingReviews.rating)return null;const t=(0,Y.Ux)("div",{});t.className="spRatingsContainer";const i=`${this.flyoutData.common.resourcesEndpoint}groceriesCashback/userRatings/star-yellow2.png`,n=(0,Y.Ux)("IMG",{});n.className="spRaitingImage",n.src=i;const o=(0,Y.Ux)("p");o.className="spRatingText";const r=(0,Y.Ux)("span",void 0,e.ratingReviews.rating.toFixed(1));r.title="Rating",r.className="spRatingValue";const a=(0,Y.Ux)("span",void 0," · "),s=(0,Y.Ux)("span",void 0,e.ratingReviews.numberOfReviews.toString());return s.title="Rating Count",o.appendChild(r),o.appendChild(a),o.appendChild(s),t.appendChild(n),t.appendChild(o),t}MakeRetailerInfoContainer(e){const t=(0,Y.Ux)("div");if(t.className="scRetailerInfoContainer",e.retailerLogoImg){const i=(0,Y.Ux)("img");i.src=e.retailerLogoImg||this.GetEmptyImage(),i.className="spRetailerImage",t.appendChild(i)}const i=(0,Y.Ux)("p",void 0,e.retailerName);return i.className="retailerName",t.appendChild(i),t}MakeImageUrl(e){return e?e.startsWith("/th?")?`${this.BaseImgUrl}${e}`:e:this.GetEmptyImage()}MakeImageContainer(e){const t=(0,Y.Ux)("div");t.className="spImageContainer",t.ariaHidden="true";const i=(0,Y.Ux)("img");if(i.src=this.MakeImageUrl(e.image),i.className="spImage",i.title=e.title,t.appendChild(i),e.iconText){"Free shipping"===e.iconText&&(e.iconText=this.flyoutData.strings.scFreeShipping);const i=(0,Y.Ux)("p",void 0,e.iconText);i.className="spImgLabel",i.title=e.iconText,"Best match for you"===e.iconText?i.classList.add("spImgLabelBestMatch"):i.classList.add("spImgLabelTrending"),t.appendChild(i)}return t}MakeSpecCardImage(e){const t=(0,Y.Ux)("img");return t.className="scSpecCardImage",t.title=e.title,t.src=this.MakeImageUrl(e.image)||this.GetEmptyImage(),t}MakePriceContainer(e){const t=(0,Y.Ux)("div");if(t.className="spPricesContainer",e.currentPrice!==e.originalPrice&&e.currentPrice){const i=(0,Y.Ux)("p",void 0,e.originalPrice),n=(0,Y.Ux)("p",void 0,e.currentPrice);i.className="spPriceOld",n.className="spPriceNew",t.appendChild(n),t.appendChild(i)}else{const i=(0,Y.Ux)("p",void 0,e.originalPrice);i.className="spPrice",t.appendChild(i)}return t}MakeSpecPriceTitleContainer(e){const t=(0,Y.Ux)("div");t.className="scSpecTitlePriceContainer";const i=(0,Y.Ux)("p",void 0,e.title);i.className="scSpecCardProductTitle";const n=(0,Y.Ux)("p");return n.className="scSpecCardPrice",n.innerText=e.originalPrice,e.currentPrice&&e.currentPrice!==e.originalPrice&&(n.classList.add("scSpecCardPriceDiscount"),n.innerText=e.currentPrice),t.appendChild(i),t.appendChild(n),t}ToggleChevronDisplay(e,t,i){t.classList.contains("scChevronLeft")?t.hidden=i<=0:t.classList.contains("scChevronRight")&&(i>=e.scrollWidth-e.clientWidth?t.hidden=!0:t.hidden=!1)}},aI=class extends Qu{constructor(e,t){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"travelCheaperFlightsData",void 0),(0,s.Z)(this,"travelCheaperFlightCard",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"sectionId","cheaper-flights-section"),this.flyoutData=e,this.utilities=t.viewModulesUtilities,this.storageHandler=t.storageHandler,this.logModule=t.logModule,this.telemetryUtilities=t.telemetryHandler,this.pageHandlerModule=t.pageHandlerModule}GetModuleName(){return r.ModuleNames.TRAVEL_CHEAPER_FLIGHT}GetNotificationName(){return r.sM.TRAVEL_CHEAPER_FLIGHT_NOTIFICATION}async ShouldRenderModule(){return e.R.isExperimentActive(f.H.travelCheaperFlightsModule)?(this.travelCheaperFlightsData=await this.GetStoredCheapFlightData(),this.travelCheaperFlightsData?Promise.resolve(!0):Promise.resolve(!1)):Promise.resolve(!1)}renderModule(){const e=(0,Y.Ux)("msft-edge-shopping-section",{id:this.sectionId,titleText:this.flyoutData.strings.bgSectionTitle,accordion:this.flyoutData.common.currentDevice===r.AS.Desktop,expanded:!0}),t=this.CreateUx(!1);return e.append(t),Promise.resolve(this.CreateModule(t,r.H7.TRAVEL_CHEAPER_FLIGHTS,r.ModuleNames.TRAVEL_CHEAPER_FLIGHT,r.$k.CONTEXTUAL,r.SV.LIST))}populateMainHeader(){}async GetStoredCheapFlightData(){try{const e=await this.storageHandler.getStorageString(Ce.Q.TravelCheaperFlightData),t=e?JSON.parse(e):void 0;return t?.currentDomain===this.flyoutData.common.domain?(t.strings={_1Stop:this.flyoutData?.strings?.travel1Stop,bookNow:this.flyoutData?.strings?.travelBookNow,bookOn:this.flyoutData?.strings?.travelBookOn,bookThisFlight:this.flyoutData?.strings?.travelBookThisFlight,cheaperDealsForYou:this.flyoutData?.strings?.travelCheaperDealsForYou,for1Adult:this.flyoutData?.strings?.travelFor1Adult,forNAdults:this.flyoutData?.strings?.travelForNAdults,nonStop:this.flyoutData?.strings?.travelNonStop,nStops:this.flyoutData?.strings?.travelNStops,oneWay:this.flyoutData?.strings?.travelOneWay,roundTrip:this.flyoutData?.strings?.travelRoundTrip,save:this.flyoutData?.strings?.travelSave,saveUpto:this.flyoutData?.strings?.travelSaveUpto,moreOptions:this.flyoutData?.strings?.travelMoreOptions,weFoundTheBestFlightForYou:this.flyoutData?.strings?.travelWeFoundTheBestFlightForYou,getSameFlightAtCheaperPrice:this.flyoutData?.strings?.travelGetSameFlightAtCheaperPrice,getDeal:this.flyoutData?.strings?.travelGetDeal},t):void 0}catch(e){return}}CreateUx(e){const t=(0,Y.Ux)("div"),n=(0,Y.Ux)("msft-travel-cheaper-flight-card");return this.travelCheaperFlightCard=n,this.travelCheaperFlightCard.data=this.travelCheaperFlightsData,this.travelCheaperFlightCard.addEventListener(Id,(t=>{let n=t?.detail;n||(n={ButtonName:i.$S.TravelCardClicked,Message:"",UrlToRedirect:""}),this.pageHandlerModule.RecordAsUserAction(K.bS.TRAVEL_CHEAPER_FLIGHTS_CLICK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.TRAVEL_CHEAPER_FLIGHTS_CLICK,this.flyoutData.common.popupOrigination);const o=new W.Z(n.ButtonName,this.telemetryUtilities.setContentViewed(e?this.GetNotificationName():this.GetModuleName()));n.Metadata&&(o.Metadata=JSON.stringify(n.Metadata)),this.logModule.LogInfoEvent(i.R.ButtonClick,n.Message,o),n.UrlToRedirect&&setTimeout((()=>{this.pageHandlerModule.NavigateToUrl(n.UrlToRedirect)}),1e3)})),t.append(n),t}},sI=class extends aI{constructor(e,t){super(e,t)}RenderNotification(e){const t=this.CreateUx(!0);this.utilities.applyStyles(this.flyoutData.common.shopping,"\n ::part(header-fixed) {\n border-bottom: 1px solid var(--notification-header-bottom-border);\n }\n "),this.flyoutData.common.shopping.classList.add("noSections"),t.style.width="100%",t.slot="header-content";const i=this.utilities.createNotificationModule(t,this.GetNotificationName(),this);return Promise.resolve(i)}async ShouldRenderNotification(){return this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_TRAVEL_NOTIFICATION_CHEAPER_FLIGHTS?Promise.resolve(!1):(this.travelCheaperFlightsData=await this.GetStoredCheapFlightData(),this.travelCheaperFlightsData?Promise.resolve(!0):Promise.resolve(!1))}PostProcessingNotification(e,t){this.flyoutData.common.shopping&&this.flyoutData.common.shopping.setAttribute("fixed-title",this.flyoutData.strings.travel)}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_TRAVEL_NOTIFICATION_CHEAPER_FLIGHTS]}};function lI(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}const cI=e=>{const{rawTrendingCouponData:t,utilities:n,renderItems:o,isDarkMode:r,pageHandler:a,LogInfoEvent:s,popupOrigination:l,telemetryUtilities:c,moduleName:d,trendingCouponsTopLine:u,domain:h}=e,p=r?Xv.shoppingTheme.dark:Xv.shoppingTheme.light,[g,f]=ch.useState(-1),m=dI(t,n,u);return ch.createElement(ap,{theme:p,style:{backgroundColor:"transparent"}},ch.createElement(Yv.Stack,{alignment:"center",spacing:"small",block:!0,direction:"vertical",gridColumns:1},m.slice(0,o).map(((e,t)=>ch.createElement("div",{className:"trendingCouponContainer"},ch.createElement(qv,{key:t,type:"regular",buttonLabel:"Copy",isCodeCopied:g===t,baseOnClick:()=>((e,t)=>{f(e);const o=new W.Z(i.$S.TrendingCouponTile,c.setContentViewed(d)),r=`From ${h} clicked on trending coupon: ${t.Domain}-${t.CouponCode}`;n.isPinterest()?(a.RecordAsUserAction(K.bS.PINTEREST_COUPON_COPIED),a.RecordAsUserEngagement(q.FV.PINTEREST_COUPON_COPIED,l)):(a.RecordAsUserAction(K.bS.CLICK_BEST_COUPON),a.RecordAsUserEngagement(q.FV.CLICK_BEST_COUPON,l)),s(i.R.ButtonClick,r,o),a.CopyCoupon(t.CouponCode)})(t,e),content:{top:e.Title,middle:e.ShouldDisplaySuccessRate?ch.createElement(ch.Fragment,null,e.Timestamp?`${e.Timestamp} `:"",e.ShouldDisplaySuccessRate?ch.createElement("span",null,ch.createElement("strong",null,e.SuccessRate,"%")," success"):""):void 0,bottom:e.CouponCode?ch.createElement(ch.Fragment,null,ch.createElement("strong",null,e.CouponCode),e.RetailerName?` • ${e.RetailerName}`:` • ${e.Domain}`):void 0},title:{middle:ch.createElement(ch.Fragment,null," ",e.DiscountRate?`${e.DiscountRate}%`:"Offer"," "),middleSuffix:e.DiscountRate?"off":void 0}}))))))},dI=(e,t,i)=>e.map((e=>{const n=function(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?lI(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):lI(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}({},e);if(void 0!==e.Timestamp){const i=t.timeAgo(e.Timestamp);void 0!==i&&(n.Timestamp=i)}return n.Title=uI(n,i),n.SuccessRate=e.SuccessRate,n.ShouldDisplaySuccessRate=parseInt(e.SuccessRate,10)>=60,n})),uI=(e,t)=>{const i=e.DiscountRate;return(0,T.fZ)("trendingCouponsTopLine",t,i)};var hI=class extends Qu{constructor(e,t){super(),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"data",void 0),(0,s.Z)(this,"trendingCouponsSection",void 0),(0,s.Z)(this,"sectionId","trendingCouponsSection"),(0,s.Z)(this,"listWrapperClass","trendingCouponsListWrapper"),(0,s.Z)(this,"renderedAsNullState",!1),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"discoverTelemetryHandler",void 0),this.flyoutData=e,this.utilities=t.viewModulesUtilities,this.pageHandlerModule=t.pageHandlerModule,this.logModule=t.logModule,this.assets=new class{getStyles(){return"\n #trendingCouponsSection::part(title){\n padding-top: 10px;\n }\n .trendingCouponsListWrapper {\n display: grid;\n grid-template-columns: 100%;\n row-gap: 5px;\n margin-bottom: 10px;\n }\n .trendingCouponRetailerImage {\n width: 18px;\n height: 18px;\n border-radius: 20px;\n margin-right: 5px;\n }\n .trendingCouponTextElement {\n width: 100%;\n display: flex;\n flex-direction: column;\n justify-content: center;\n align-items: flex-start;\n font-size: 12px;\n }\n .trendingCouponsNavigateButton {\n width: 100%;\n display: flex;\n align-items: flex-start;\n background: none;\n font-size: 12px;\n }\n .trendingCouponInfo {\n width: 100%;\n height: 35px;\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n }\n .trendingCouponTopText {\n font-weight: 400;\n height: 50%;\n display: flex;\n color: var(--text-normal);\n text-align: left;\n margin-top: 15px;\n }\n .trendingCouponBottomText {\n font-size: 12px;\n font-weight: 400;\n height: 50%;\n display: flex;\n flex-direction: row;\n color: var(--text-normal);\n max-width: 100px;\n }\n @media (-ms-high-contrast: active) {\n .trendingCouponTopText,.trendingCouponBottomText,.trendingCouponsNavigateButton {\n color: ButtonText!important;\n }\n }\n "}getDarkModeStyles(){return"\n .trendingCouponsNavigateButton {\n color: #FFFFFF;\n }\n "}getNotificationStyles(){return"\n #trendingCouponsSection::part(title){\n font-size: 16px;\n }\n #divContentWrapper {\n width: 280px;\n }\n #trendingCouponsSection {\n display: flex;\n flex-direction: column;\n justify-content: center;\n width: 100%;\n font-size: 12px;\n }\n .trendingCouponsNotificationHeader {\n margin: 0;\n font-size: 22px;\n line-height: 26px;\n font-weight: 600;\n }\n .trendingCouponsNotificationSeeMoreButton {\n font-size: 14px;\n font-weight: 400;\n margin-top: 0;\n }\n .trendingCouponTopText {\n margin-top: 35px;\n }\n .trendingCouponBottomText {\n display: none;\n }\n .trendingCouponRetailerImage {\n display: none;\n }\n "}getSafariStyles(){return"\n #trendingCouponsSection::part(title) {\n font-size: 16px;\n font-weight: 500;\n text-transform: capitalize;\n border-top: unset !important;\n margin-bottom: unset !important;\n }\n msft-edge-shopping::part(header) {\n display: none;\n }\n .trendingCouponsListWrapper {\n grid-template-columns: 100%;\n }\n "}},this.data=[],this.telemetryUtilities=t.telemetryHandler,this.discoverTelemetryHandler=t.discoverTelemetryHandler}GetModuleName(){return r.ModuleNames.TRENDING_COUPONS}IsZerostate(){return void 0===this.flyoutData.dataStoreModule.CouponData}ShouldRenderModule(){this.data=this.flyoutData.dataStoreModule.TrendingCouponsData??[];const t=!this.CanRenderCoupons()&&!this.CanRenderCashback()&&!e.R.isExperimentActive(f.H.singleScrollingShoreline);return Promise.resolve(t)}renderModule(){return this.ApplyAssets(),this.trendingCouponsSection=this.CreateTrendingCouponsSection(),Promise.resolve(this.CreateModule(this.trendingCouponsSection,this.flyoutData.dataStoreModule.ApiData?.retailerData?r.H7.TRENDING_COUPONS:r.H7.TRENDING_COUPONS_ON_HOME_TAB,this.GetModuleName(),this.flyoutData.dataStoreModule.ApiData?.retailerData?r.$k.CONTEXTUAL:r.$k.HOME,r.SV.LIST))}populateMainHeader(){}async PostProcessing(t,i,n){if(0===this.data.length){if((0,dt.tB)(this.flyoutData)){const e=[];this.flyoutData.common.trendingCoupons.forEach((t=>{e.push(new st(t))})),this.data=e}else this.data=await ct.LoadTrendingCouponsData(this.pageHandlerModule);if(!(this.data&&0!==this.data.length||(0,dt.tB)(this.flyoutData)))try{this.data=await ct.FetchAndCacheTrendingCoupons(this.pageHandlerModule)}catch(e){}}this.renderedAsNullState&&e.R.isExperimentActive(f.H.singleScrollingShoreline)||(gn.SO.queueUpdate((()=>{this.UpdateSectionWithData(i)})),this.renderedAsNullState=!0)}ApplyAssets(){this.flyoutData.common.isPane?this.utilities.applyStyles(this.flyoutData.common.shoppingPersistent,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()):this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),(0,dt.tB)(this.flyoutData)&&this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getSafariStyles())}PopulateTrendingCouponsSection(e){this.PopulateTrendingCouponsList(e,!1,!1)}CreateTrendingCouponsList(e){this.utilities.createCommonListStructure(e,this.flyoutData.strings.trendingCouponsTitle,this.data,this.GetModuleName(),(()=>this.flyoutData.common.isPane?r.CS.TRENDING_COUPONS_PANE:r.CS.TRENDING_COUPONS),this.PopulateTrendingCouponsList.bind(this),void 0)}sendSeemoreTelemetry(){this.pageHandlerModule.RecordAsUserAction(K.bS.SEE_MORE_TRENDING_COUPONS),this.pageHandlerModule.RecordAsUserEngagement(q.FV.SEE_MORE_TRENDING_COUPONS,this.flyoutData.common.popupOrigination);const e=new W.Z(i.$S.TrendingCouponTile,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,`From ${this.flyoutData.common.domain} clicked on see more trending coupons`,e)}UpdateSectionWithData(e){this.data&&this.data.length>0?(this.PopulateTrendingCouponsSection(this.trendingCouponsSection),this.CreateTrendingCouponsList(this.trendingCouponsSection),(0===e||this.flyoutData.common.isPane)&&(this.trendingCouponsSection.expanded=!0,0===e&&(this.trendingCouponsSection.accordion=!1))):this.trendingCouponsSection.style.display="none"}CreateTrendingCouponsSection(){return this.CreateBasicSectionElement()}CreateBasicSectionElement(){const e=(0,Y.Ux)("msft-edge-shopping-section");return e.id=this.sectionId,e.titleText=this.flyoutData.strings.trendingCouponsTitle,e}PopulateTrendingCouponsList(e,n,o){const a=this.GetListWrapper(),s=this.data;if(s){let o=0;s.length>0&&(o=s.length),n?this.sendSeemoreTelemetry():o=Math.min(o,this.flyoutData.common.isPane?r.CS.TRENDING_COUPONS_PANE:r.CS.TRENDING_COUPONS);try{l=cI,c={rawTrendingCouponData:s,utilities:this.utilities,renderItems:o,isDarkMode:this.utilities.isDarkMode(),pageHandler:this.pageHandlerModule,LogInfoEvent:this.LogInfoEvent.bind(this),popupOrigination:this.flyoutData.common.popupOrigination,telemetryUtilities:this.telemetryUtilities,moduleName:this.GetModuleName(),trendingCouponsTopLine:this.flyoutData.strings.trendingCouponsTopLine,domain:this.flyoutData.common.domain},d=a,sp.render(ch.createElement(l,c),d)}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);n.Metadata=JSON.stringify({error:e}),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Error rendering trending coupons",n)}e.appendChild(a);for(let e=0;e<o;e++){const t=document.getElementsByClassName("trendingCouponContainer")[e];t&&(t.style.display="contents",t.style.width="100%",this.AddMouseEventListeners(t,s[e]))}const u=new t.Z(i.xu.TrendingCouponsModuleRendered);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Trending coupons rendered",u)}var l,c,d}AddMouseEventListeners(e,t){const i=()=>{const e=`From ${this.flyoutData.common.domain} navigated to retailer: ${t.Domain}-${t.CouponCode}`;this.SendCouponClickTelemetry(e),this.VisitRetailer(t.Domain)};this.AddClickAndEnterListenersToElement(e,(()=>{this.AddClickAndEnterListenersToElement(e,i)}))}GetListWrapper(){let e=document.querySelector(`#${this.sectionId} .${this.listWrapperClass}`);return e||(e=(0,Y.Ux)("DIV",{className:this.listWrapperClass+" lateralMargin"})),e}AddClickAndEnterListenersToElement(e,t){e.addEventListener("click",t),e.addEventListener("keydown",(e=>{"Enter"===e.key&&t(e)}))}SendCouponClickTelemetry(e){const t=new W.Z(i.$S.TrendingCouponTile,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.utilities.isPinterest()?(this.pageHandlerModule.RecordAsUserAction(K.bS.PINTEREST_COUPON_COPIED),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PINTEREST_COUPON_COPIED,this.flyoutData.common.popupOrigination)):(this.pageHandlerModule.RecordAsUserAction(K.bS.CLICK_BEST_COUPON),this.pageHandlerModule.RecordAsUserEngagement(q.FV.CLICK_BEST_COUPON,this.flyoutData.common.popupOrigination)),this.LogInfoEvent(i.R.ButtonClick,e,t)}VisitRetailer(e){let t=e;t.startsWith("http")||(t="https://"+t),this.pageHandlerModule.NavigateToRetailerSite(t)}CanRenderCoupons(){if(this.flyoutData.dataStoreModule.CouponData){const e=this.flyoutData.dataStoreModule.CouponData.Coupons;if(e&&e.length>0)return!0}return!1}CanRenderCashback(){return!0===this.flyoutData.dataStoreModule.CashBackData?.canRenderCashback}LogInfoEvent(e,t,n){try{this.flyoutData.common.isDiscoverPane&&e===i.R.ButtonClick&&this.discoverTelemetryHandler.LogClickTelemetry(i.xu.TrendingCouponDiscoverButtonClick,"","",r.ModuleNames.TRENDING_COUPONS,{buttonName:n.ButtonClicked??void 0,message:t}),this.logModule.LogInfoEvent(e,t,n,Jl.g.CouponImpressionId)}catch(e){}}},pI=class extends hI{constructor(...e){super(...e),(0,s.Z)(this,"notificationContentId","trendingCouponsSection")}async ShouldRenderNotification(){return this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_TRENDING_COUPONS&&this.flyoutData.common.openedWith===r.Te.Auto&&await this.ShouldRenderModule()?Promise.resolve(!0):Promise.resolve(!1)}GetNotificationName(){return r.sM.TRENDING_COUPONS}PostProcessingNotification(e,t){this.populateMainHeader()}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_TRENDING_COUPONS]}async RenderNotification(){this.ApplyAssets(),this.RenderNotificationHeader();const e=this.RenderNotificationContent();return Promise.resolve(this.utilities.createNotificationModule(e,this.GetNotificationName(),this))}ApplyAssets(){super.ApplyAssets(),this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getNotificationStyles())}RenderNotificationHeader(){const e=(0,Y.Ux)("h1",{slot:"header-content",className:"trendingCouponsNotificationHeader",textContent:this.flyoutData.strings.trendingCouponsTitle});this.flyoutData.common.shopping.appendChild(e)}RenderNotificationContent(){const e=(0,Y.Ux)("div",{id:this.notificationContentId});return this.PopulateTrendingCouponsSection(e),this.flyoutData.common.isPaneEnabled?this.AddSeeMoreButton(e):this.CreateTrendingCouponsList(e),e}AddSeeMoreButton(e){const t=(0,Y.lw)(this.utilities);t.textContent=this.flyoutData.strings.trendingCouponsSeeMore,t.className+=" lateralMargin trendingCouponsNotificationSeeMoreButton",t.slot="actions",t.addEventListener("click",(()=>{this.pageHandlerModule.OpenPane(this.flyoutData.common.popupOrigination),this.sendSeemoreTelemetry()})),e.appendChild(t)}};function gI(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function fI(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?gI(Object(i),!0).forEach((function(t){(0,s.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):gI(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var mI=function(e){return e.On="1",e.Off="0",e}(mI||{}),vI=function(e){return e.Success="success",e.Error="error",e}(vI||{}),yI=class extends Qu{constructor(t,i){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"currentProviderType",void 0),(0,s.Z)(this,"strings",void 0),(0,s.Z)(this,"cardNumberLast4Digit",void 0),(0,s.Z)(this,"cardHolderName",void 0),(0,s.Z)(this,"cardExpires",void 0),(0,s.Z)(this,"GetModuleName",(()=>r.ModuleNames.VIRTUAL_CARD)),(0,s.Z)(this,"ShouldRenderModule",(async()=>!1===this.flyoutData.dataStoreModule?.VirtualCardData?.hasError)),(0,s.Z)(this,"populateMainHeader",(()=>{const t=this.flyoutData.common.shopping;if(this.flyoutData.dataStoreModule.VirtualCardData?.isLinking)if(this.flyoutData.dataStoreModule.VirtualCardData.isLinkingSuccess){const t=this.renderMessageBar((0,T.fZ)("virtualCardLinkSuccess",this.flyoutData.strings.virtualCardLinkSuccess,this.strings?.payment??""),vI.Success);e.R.isExperimentActive(f.H.incentiveCampaign)&&void 0!==this.flyoutData.dataStoreModule.IncentiveCampaignData&&!this.flyoutData.dataStoreModule.IncentiveCampaignData.isRewardClaimed||this.flyoutData.common.shopping.appendChild(t)}else{const t=this.renderMessageBar((0,T.fZ)("virtualCardLinkFail",this.flyoutData.strings.virtualCardLinkFail,this.strings?.payment??""),vI.Error);e.R.isExperimentActive(f.H.incentiveCampaign)&&void 0!==this.flyoutData.dataStoreModule.IncentiveCampaignData&&!this.flyoutData.dataStoreModule.IncentiveCampaignData.isRewardClaimed||this.flyoutData.common.shopping.appendChild(t)}const i=(0,Y.Ux)("h2");i.classList.add("txtLarge","mainTitle"),i.style.textAlign="center",i.style.fontWeight="500",i.id="vitual-card-title",i.textContent=this.strings?.title??"",i.slot="header-content",t.appendChild(i)})),(0,s.Z)(this,"renderModule",(async()=>{this.strings=this.GetStringForCurrentProvider(),this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());const e=document.createElement("msft-edge-shopping-section");e.id="virtual-card-section",e.accordion=!1;const t=document.createElement("p");t.classList.add("txtMedium","description"),t.id="vitual-card-description",t.textContent=this.flyoutData.dataStoreModule.VirtualCardData?.isAutofillSuccess?this.strings?.autofillSuccess??"":this.strings?.autofillFailed??"",e.appendChild(t);const i=this.renderVisualizedCard();e.appendChild(i);const n=document.createElement("div");n.classList.add("card-info");const o=this.renderCardInfoCard();if(this.flyoutData.dataStoreModule.VirtualCardData?.billingInfo){const e=this.cardHolderName?this.flyoutData.strings.virtualCardBillingInfoHeader:this.flyoutData.strings.virtualCardBillingAddressHeader,t=this.renderBillingInfoCard({contentText:this.flyoutData.dataStoreModule.VirtualCardData?.billingInfo,headerText:`${e} `,id:"billing-info"});n.appendChild(t)}else if(this.flyoutData.dataStoreModule.VirtualCardData?.cardHolderName){const e=this.renderBillingInfoCard({contentText:this.flyoutData.dataStoreModule.VirtualCardData?.cardHolderName,headerText:`${this.flyoutData.strings.virtualCardCardHolderNameHeader} `,id:"billing-info"});n.appendChild(e)}if(n.appendChild(o),e.appendChild(n),this.strings&&this.strings.disclaimerText){const t=document.createElement("div");t.className="bnpl-disclaimer",this.applyStyle(t,{fontSize:"10px",lineHeight:"normal",margin:"10px 20px 20px 20px",textAlign:"center"});const i=this.strings.disclaimerText;if(this.strings.disclaimerLinkUrl&&this.strings.disclaimerLinkText){const e=document.createElement("A");e.target="_blank",e.href=this.strings.disclaimerLinkUrl,e.textContent=this.strings.disclaimerLinkText,(0,T.B7)(t,i,e)}else t.textContent=i;e.appendChild(t)}return this.CreateModule(e,r.H7.VIRTUAL_CARD,r.ModuleNames.VIRTUAL_CARD,r.$k.CONTEXTUAL,r.SV.SQUARES)})),(0,s.Z)(this,"GetStringForCurrentProvider",(()=>{switch(this.currentProviderType){case r.M$.ZIP:return{autofillFailed:this.flyoutData.strings.zipPayVirtualCardHeaderAutofillFailedDescription,autofillSuccess:this.flyoutData.strings.zipPayVirtualCardHeaderDescription,cardDetails:(0,T.fZ)("VirtualCardDetails",this.flyoutData.strings.zipPayVisualizedCardDetails,this.cardNumberLast4Digit,this.cardHolderName,this.cardExpires),cardUrl:"https://zip.co/us",payment:this.flyoutData.strings.zipPayPayment,title:this.flyoutData.strings.zipPayVirtualCardHeaderTitle};case r.M$.AFFIRM:return{autofillFailed:this.flyoutData.strings.affirmVirtualCardHeaderAutofillFailedDescription,autofillSuccess:this.flyoutData.dataStoreModule.VirtualCardData?.billingInfo?this.flyoutData.strings.affirmVirtualCardHeaderDescription:this.flyoutData.strings.affirmVirtualCardHeaderNoBillingInfoDescription,cardDetails:(0,T.fZ)("VirtualCardDetails",this.flyoutData.strings.affirmVisualizedCardDetails,this.cardNumberLast4Digit,this.cardExpires),cardUrl:"https://www.affirm.com/user/signin",disclaimerLinkText:this.flyoutData.strings.affirmDisclaimerLinkText,disclaimerLinkUrl:"https://helpcenter.affirm.com/s/",disclaimerText:this.flyoutData.strings.affirmDisclaimerText,payment:this.flyoutData.strings.affirmPayment,title:this.flyoutData.strings.affirmVirtualCardHeaderTitle};case r.M$.KLARNA:return{autofillFailed:this.flyoutData.strings.klarnaVirtualCardHeaderAutofillFailedDescription,autofillSuccess:this.flyoutData.dataStoreModule.VirtualCardData?.billingInfo?this.flyoutData.strings.klarnaVirtualCardHeaderDescription:this.flyoutData.strings.klarnaVirtualCardHeaderNoBillingInfoDescription,cardDetails:(0,T.fZ)("VirtualCardDetails",this.flyoutData.strings.klarnaVisualizedCardDetails,this.cardNumberLast4Digit,this.cardExpires),cardUrl:"https://app.klarna.com/login",disclaimerText:(0,T.fZ)("klarnaDisclaimerText",this.flyoutData.strings.klarnaDisclaimerText,this.flyoutData.strings.klarnaCustomerServiceNumber),payment:this.flyoutData.strings.klarnaPayment,title:this.flyoutData.strings.klarnaVirtualCardHeaderTitle}}return null})),(0,s.Z)(this,"applyStyle",((e,t)=>{Object.keys(t).forEach((i=>{e.style[i]=t[i]}))})),(0,s.Z)(this,"renderMessageBar",((e,t)=>{const i=document.createElement("div");this.applyStyle(i,{boxSizing:"border-box",display:"flex"});const n=document.createElement("div");n.classList.add("message-bar",t),n.setAttribute("role","group"),n.setAttribute("aria-label",e);const o=document.createElement("span");o.setAttribute("aria-hidden","true"),o.classList.add("icon");const r=t===vI.Success?this.assets.getSuccessIcon():this.assets.getErrorIcon();o.innerHTML=r,n.appendChild(o);const a=document.createElement("div");a.classList.add("content"),a.textContent=e,n.appendChild(a);const s=document.createElement("fluent-button");return s.classList.add("cancel"),s.appearance="lightweight",s.style.color="#000",s.ariaLabel=this.flyoutData.strings.dismissMessageAriaLabel,s.innerHTML=this.assets.getCancelButton(),s.addEventListener("click",(()=>{n.remove(),this.resizeFlyout()})),n.appendChild(s),i.appendChild(n),i.slot="start-content",i})),(0,s.Z)(this,"appendZipCardInformation",(e=>{const t=document.createElement("span");this.applyStyle(t,{color:"#FFF",fontFamily:"monospace",fontSize:"18px",left:"164px",position:"absolute",top:"70px",userSelect:"none"}),t.textContent=this.cardNumberLast4Digit;const i=document.createElement("span");i.textContent=this.flyoutData.strings.visualizedCardHolderHeader,i.classList.add("card-title"),this.applyStyle(i,{left:"24px",top:"114px"}),e.appendChild(i);const n=document.createElement("span");n.textContent=this.flyoutData.strings.visualizedCardExpiresHeader,n.classList.add("card-title"),this.applyStyle(n,{left:"124px",top:"114px"}),e.appendChild(n);const o=document.createElement("span");o.textContent=this.cardHolderName,o.classList.add("card-text"),this.applyStyle(o,{left:"24px",top:"130px"}),e.appendChild(o);const r=document.createElement("span");r.textContent=this.cardExpires,r.classList.add("card-text"),this.applyStyle(r,{left:"124px",top:"130px"}),e.appendChild(r),e.appendChild(t)})),(0,s.Z)(this,"appendAffirmCardInformation",(e=>{const t=document.createElement("span");this.applyStyle(t,{color:"#FFF",fontFamily:"monospace",fontSize:"18px",left:"80px",position:"absolute",top:"96px",userSelect:"none"}),t.textContent=this.cardNumberLast4Digit;const i=document.createElement("span");i.textContent=`Exp. ${this.cardExpires}`,i.classList.add("card-title"),this.applyStyle(i,{color:"white",fontSize:"16px",left:"24px",opacity:"1",top:"127px"}),e.appendChild(i),e.appendChild(t)})),(0,s.Z)(this,"appendKlarnaCardInformation",(e=>{const t={color:"white",fontFamily:"monospace",fontWeight:"400",left:"20px",opacity:"1",position:"absolute",userSelect:"none"},i=fI(fI({},t),{},{fontSize:"12px",top:"90px"}),n=fI(fI({},t),{},{fontSize:"12px",top:"105px"}),o=document.createElement("span");this.applyStyle(o,fI(fI({},t),{},{fontSize:"16px",top:"65px",left:"155px"})),o.textContent=this.cardNumberLast4Digit;const r=document.createElement("span");r.textContent="MM YY",this.applyStyle(r,i);const a=document.createElement("span");a.textContent="CVV",this.applyStyle(a,fI(fI({},i),{},{left:"94px"}));const s=document.createElement("span");s.textContent=`${this.cardExpires}`,s.classList.add("card-title"),this.applyStyle(s,n);const l=document.createElement("span");l.textContent="Limited Use Virtual Card",this.applyStyle(l,fI(fI({},t),{},{fontSize:"12px",top:"135px"}));const c=document.createElement("span");c.textContent="Commercial",this.applyStyle(c,fI(fI({},t),{},{fontSize:"9px",top:"147px",left:"207px"})),e.appendChild(r),e.appendChild(a),e.appendChild(s),e.appendChild(l),e.appendChild(c),e.appendChild(o)})),(0,s.Z)(this,"renderVisualizedCard",(()=>{const e=document.createElement("div");switch(e.id="visualized-card",e.setAttribute("aria-label",this.strings?.cardDetails??""),e.setAttribute("role","img"),this.applyStyle(e,{backgroundImage:`url("data:image/svg+xml;utf8,${encodeURIComponent(this.GetBackgroundForCurrentProvider())}")`,backgroundRepeat:"no-repeat",backgroundSize:"cover",height:"170px",margin:"0 auto",position:"relative",width:"280px"}),this.currentProviderType){case r.M$.ZIP:this.appendZipCardInformation(e);break;case r.M$.AFFIRM:this.appendAffirmCardInformation(e);break;case r.M$.KLARNA:this.appendKlarnaCardInformation(e)}return e})),(0,s.Z)(this,"renderCardContent",(({headerText:e,contentText:t,id:i,sensitive:n,showContentToggleTooltip:o,hideContentToggleTooltip:r})=>{const a=document.createElement("h3");a.classList.add("card-header"),a.textContent=e;const s=`${i}-show-hide-content`,l=document.createElement("div");l.classList.add("card-content");const c=document.createElement("span");c.classList.add("content-text"),c.textContent=(n?t?.replace(/./g,"•"):t)??"",c.id=s,c.dataset.content=t,l.append(c);const d=document.createElement("div");if(d.setAttribute("role","group"),d.setAttribute("aria-label",this.flyoutData.strings.virtualCardDetailsActions),d.classList.add("content-controls"),n&&o&&r){c.setAttribute("aria-hidden","true");const e=document.createElement("fluent-button");e.id=`${i}-show-hide-toggle`,e.style.width="16px",e.style.minWidth="16px",e.style.height="16px",e.style.fill="currentcolor",e.title=o,e.dataset.isShowing=mI.Off,e.ariaLabel=o,e.innerHTML=this.assets.getShowIcon(),e.addEventListener("click",(e=>{const t=e.currentTarget,i=t?.dataset?.isShowing===mI.On,n=document.querySelector(`#${s}`);t&&(i?(t.dataset.isShowing=mI.Off,t.innerHTML=this.assets.getShowIcon(),t.title=o,t.ariaLabel=o,n&&(n.setAttribute("aria-hidden","true"),n.textContent=n.dataset?.content?.replace(/./g,"•")??"")):(t.dataset.isShowing=mI.On,t.innerHTML=this.assets.getHideIcon(),t.title=r,t.ariaLabel=r,n&&(n.setAttribute("aria-hidden","false"),n.textContent=n.dataset?.content??"")),t.focus())})),d.appendChild(e)}const u=document.createElement("span");u.id=`indicator-${i}`,u.setAttribute("aria-live","assertive"),u.setAttribute("aria-relevant","all"),u.setAttribute("aria-atomic","true"),u.style.position="absolute",u.style.left="-999em",u.textContent=this.flyoutData.strings.couponCopied;const h=document.createElement("fluent-button");h.id=`${i}-copy-button`,h.style.width="16px",h.style.minWidth="16px",h.style.height="16px",h.style.fill="currentcolor";const p=`${this.flyoutData.strings.copyButtonTooltip} ${e}`;return h.title=p,h.ariaLabel=p,h.innerHTML=this.assets.getCopyIcon(),h.addEventListener("click",(async()=>{l.appendChild(u),setTimeout((()=>{u.remove()}),3e3);const e=document.querySelector(`#${s}`);if(e?.dataset?.content){const t=document.createElement("textarea");t.value=e.dataset.content,document.body.appendChild(t),t.focus(),t.select(),document.execCommand("copy"),document.body.removeChild(t)}h.focus()})),d.appendChild(h),l.append(d),[a,l]})),(0,s.Z)(this,"renderBillingInfoCard",(e=>{const t=document.createElement("div");t.setAttribute("aria-label",e.headerText),t.classList.add("virtual-card-info-card","virtual-card-info-single-column");const[i,n]=this.renderCardContent(e);return t.appendChild(i),t.append(n),t})),(0,s.Z)(this,"GetBackgroundForCurrentProvider",(()=>{switch(this.currentProviderType){case r.M$.ZIP:return this.assets.getZipCardBackground();case r.M$.AFFIRM:return this.assets.getAffirmCardBackground();case r.M$.KLARNA:return this.assets.getKlarnaCardBackground();default:return null}})),(0,s.Z)(this,"renderCardInfoCard",(()=>{const e=document.createElement("div");e.classList.add("virtual-card-info-card");const t=document.createElement("div");this.applyStyle(t,{display:"flex",flexDirection:"column",rowGap:"8px"});const i={contentText:this.flyoutData.dataStoreModule.VirtualCardData?.cardNumber,headerText:this.flyoutData.strings.virtualCardNumberHeader,hideContentToggleTooltip:this.flyoutData.strings.hideContentToggleTooltipCardNumber,id:"card-number",sensitive:!0,showContentToggleTooltip:this.flyoutData.strings.showContentToggleTooltipCardNumber},n=document.createElement("div");n.setAttribute("aria-label",i.headerText);const[o,r]=this.renderCardContent(i);n.appendChild(o),n.appendChild(r),t.appendChild(n),this.applyStyle(n,{flex:"1"});const a=[{contentText:this.flyoutData.dataStoreModule.VirtualCardData?.expires,headerText:this.flyoutData.strings.virtualCardExpirationHeader,id:"card-expiration"},{contentText:this.flyoutData.dataStoreModule.VirtualCardData?.cardCVC,headerText:this.flyoutData.strings.virtualCardCVCHeader,hideContentToggleTooltip:this.flyoutData.strings.hideContentToggleTooltipCVC,id:"card-cvc",sensitive:!0,showContentToggleTooltip:this.flyoutData.strings.showContentToggleTooltipCVC}],s=document.createElement("div");return a.forEach((e=>{const[t,i]=this.renderCardContent(e),n=document.createElement("div");n.setAttribute("aria-label",e.headerText),n.appendChild(t),n.appendChild(i),s.append(n)})),t.appendChild(s),this.applyStyle(s,{display:"flex",gap:"24px"}),e.appendChild(t),e})),this.logModule=i.logModule,this.pageHandlerModule=i.pageHandlerModule,this.flyoutData=t,this.utilities=i.viewModulesUtilities,this.assets=new class{getStyles(){return"\n .message-bar {\n border-radius: 4px;\n display: flex;\n align-items: center;\n padding: 8px;\n width: 100%;\n text-align: left;\n box-sizing: border-box;\n color: #000000;\n font-size: 12px;\n margin: 0 12px;\n }\n\n .message-bar.success {\n background-color: #DFF6DD;\n }\n\n .message-bar .icon {\n fill: currentcolor;\n margin-right: 8px;\n }\n\n .message-bar.success .icon {\n color: #107C10;\n }\n\n .message-bar.error .icon {\n color: #A80000;\n }\n\n .message-bar .content {\n flex: 1;\n margin-right: 8px;\n }\n\n .message-bar.error {\n background-color: #FDE7E9;\n }\n\n .mainTitle {\n font-size: 20px;\n }\n\n .description {\n margin-top: 4px;\n margin-bottom: 12px;\n font-size: 12px;\n line-height: 16px;\n text-align: center;\n margin-left: 12px;\n margin-right: 12px;\n }\n\n .card-title {\n color: #FFF;\n opacity: 0.5;\n user-select: none;\n position: absolute;\n font-size: 10px;\n }\n\n .card-text {\n color: #FFF;\n font-size: 14px;\n user-select: none;\n position: absolute;\n font-size: 12px;\n max-width: 100px;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n\n .card-info {\n margin: 8px 0 12px 0;\n padding-bottom: 8px;\n }\n\n .virtual-card-info-card {\n margin: 4px 12px;\n line-height: 16px;\n font-size: 14px;\n display: block;\n padding: 8px 16px;\n box-sizing: border-box;\n white-space: nowrap;\n background: var(--virtual-card-info-background);\n border-radius: 8px;\n }\n\n .virtual-card-info-single-column .card-content {\n justify-content: space-between;\n }\n\n .virtual-card-info-card .card-header {\n font-weight: 600;\n margin: 0 0 8px;\n font-size: 12px;\n }\n\n .virtual-card-info-card .card-content {\n display: flex;\n align-items: center;\n }\n\n .virtual-card-info-card .card-content .content-controls {\n margin-left: 16px;\n }\n\n .virtual-card-info-card .card-content .content-text {\n white-space: pre-wrap;\n }\n\n :root {\n --virtual-card-info-background: linear-gradient(90deg, rgba(255, 249, 217, 0.6) 0%, rgba(233, 251, 255, 0.6) 53.13%, rgba(221, 235, 255, 0.6) 100%);\n }\n\n .virtual-card-info-card fluent-button {\n background-color: transparent;\n }\n\n .virtual-card-info-card fluent-button:active {\n background-color: var(--neutral-fill-active);\n }\n\n .virtual-card-info-card fluent-button:hover {\n background-color: var(--neutral-fill-hover);\n }\n\n .card-info .card-header, .bnpl-disclaimer {\n font-weight: 400;\n color: var(--text-neutral-foreground-hint);\n }\n\n @media (-ms-high-contrast: active) {\n .message-bar .icon {\n fill: ButtonText;\n }\n .message-bar .cancel {\n fill: ButtonText;\n }\n }"}getNotificationStyles(){return"\n #virtual-card-notification h2 {\n font-weight: 500;\n margin: 32px 0 16px 0;\n }\n\n #virtual-card-notification .description {\n line-height: 18px;\n }\n\n #virtual-card-notification .detail-link {\n margin: 16px 0;\n }\n\n #virtual-card-notification {\n padding-bottom: 12px;\n }\n\n #virtual-card-notification h2 {\n margin: 8px 0;\n }\n\n #virtual-card-notification .description {\n width: 330px;\n margin: auto;\n font-size: 12px;\n }\n\n #virtual-card-notification .detail-button {\n width: 240px;\n height: 48px;\n display: block;\n margin: 16px auto 0;\n border-radius: 8px;\n background: transparent;\n border: 1px solid #008076;\n outline: none;\n box-sizing: border-box;\n fill: inherit;\n text-align: center;\n cursor: pointer;\n font-weight: 600;\n color: #008076;\n }\n #virtual-card-notification .detail-button:hover {\n background: linear-gradient(267.73deg, #F0FEFF -9.53%, #DBFFFB 45.72%, #F8FDFF 97.76%);\n color: #008076;\n }"}getDarkModeStyles(){return"\n #virtual-card-notification .detail-button {\n background: rgba(255, 255, 255, 0.09);\n color: #FFFFFF;\n }\n :root {\n --virtual-card-info-background: linear-gradient(90deg, #4C544A 0%, #425559 47.4%, #544E5D 100%);\n }\n "}getCopyIcon(){return eh.Z.getTrustedHTML`
<svg role="img" style="width: 1em" viewBox="0 0 10 12" width="10" height="12" xmlns="http://www.w3.org/2000/svg" aria-hidden="true">
<path d="M1 2.085V8.5a2.5 2.5 0 002.336 2.495L3.5 11h4.414A1.5 1.5 0 016.5 12H3a3 3 0 01-3-3V3.5a1.5 1.5 0 011-1.415zM8.5 0A1.5 1.5 0 0110 1.5v7A1.5 1.5 0 018.5 10h-5A1.5 1.5 0 012 8.5v-7A1.5 1.5 0 013.5 0h5zm0 1h-5a.5.5 0 00-.5.5v7a.5.5 0 00.5.5h5a.5.5 0 00.5-.5v-7a.5.5 0 00-.5-.5z"/>
</svg>`}getShowIcon(){return eh.Z.getTrustedHTML`
<svg role="img" style="width: 1em" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 2048 2048" aria-hidden="true">
<path d="M1024 512q150 0 292 39t272 107 246 163 214 203q-98 110-213 203t-246 162-273 108-292 39q-150 0-292-39t-272-107-247-162T0 1024q97-109 213-203t246-162 273-108 292-39zm0 878q76 0 142-29t116-78 79-116 29-143q0-76-29-142t-78-116-116-79-143-29q-76 0-142 29t-116 78-79 116-29 143q0 76 29 142t78 116 116 79 143 29zm-375-54q-55-66-84-146t-29-166q0-86 29-166t84-146q-134 53-251 132t-221 180q103 100 220 179t252 133zm1222-312q-103-100-220-179t-252-133q55 66 84 146t29 166q0 86-29 166t-84 146q134-53 251-132t221-180zm-847-171q35 0 66 13t54 37 37 55 14 66q0 35-13 66t-37 55-55 36-66 14q-35 0-66-13t-55-37-36-54-14-67q0-35 13-66t37-54 54-37 67-14z" />
</svg>`}getHideIcon(){return eh.Z.getTrustedHTML`
<svg role="img" style="width: 1em" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 2048 2048" aria-hidden="true">
<path d="M1024 896q27 0 50 10t40 27 28 41 10 50q0 27-10 50t-27 40-41 28-50 10q-27 0-50-10t-40-27-28-41-10-50q0-27 10-50t27-40 41-28 50-10zm576 256q93 0 174 35t143 96 96 142 35 175q0 93-35 174t-96 143-142 96-175 35q-93 0-174-35t-143-96-96-142-35-175q0-93 35-174t96-143 142-96 175-35zm-320 448q0 66 25 124t68 102 102 69 125 25q47 0 92-13t84-40l-443-443q-26 39-39 84t-14 92zm587 176q26-39 39-84t14-92q0-66-25-124t-69-101-102-69-124-26q-47 0-92 13t-84 40l443 443zM640 1024q0 74 26 139t72 117 108 84 136 42q19 2 38 2t39 0q-22 63-29 128-152 0-294-38t-273-107-247-162T0 1024q97-109 213-203t246-162 273-108 292-39q153 0 296 36t272 104 245 161 211 211l-91 91-8-9q-108-126-232-224t-280-161q48 66 73 144t26 159v6q-65 7-128 29v-35q0-79-30-149t-83-122-122-82-149-31q-79 0-149 30t-122 83-82 122-31 149zm-37 291q-45-64-68-138t-23-153q0-78 23-152t68-139q-120 52-226 126t-200 165q94 91 200 165t226 126z" />
</svg>`}getSuccessIcon(){return eh.Z.getTrustedHTML`
<svg role="img" style="width: 1em" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 2048 2048">
<path d="M1491 595l90 90-749 749-365-365 90-90 275 275 659-659zM1024 0q141 0 272 36t245 103 207 160 160 208 103 245 37 272q0 141-36 272t-103 245-160 207-208 160-245 103-272 37q-141 0-272-36t-245-103-207-160-160-208-103-244-37-273q0-141 36-272t103-245 160-207 208-160T751 37t273-37zm0 1920q123 0 237-32t214-90 182-141 140-181 91-214 32-238q0-123-32-237t-90-214-141-182-181-140-214-91-238-32q-123 0-237 32t-214 90-182 141-140 181-91 214-32 238q0 123 32 237t90 214 141 182 181 140 214 91 238 32z" />
</svg>`}getErrorIcon(){return eh.Z.getTrustedHTML`
<svg role="img" style="width: 1em" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 2048 2048">
<path d="M960 0q133 0 255 34t230 96 194 150 150 195 97 229 34 256q0 133-34 255t-96 230-150 194-195 150-229 97-256 34q-133 0-255-34t-230-96-194-150-150-195-97-229T0 960q0-133 34-255t96-230 150-194 195-150 229-97T960 0zm0 1792q114 0 220-30t199-84 169-130 130-168 84-199 30-221q0-114-30-220t-84-199-130-169-168-130-199-84-221-30q-115 0-221 30t-198 84-169 130-130 168-84 199-30 221q0 114 30 220t84 199 130 169 168 130 199 84 221 30zM896 512h128v640H896V512zm0 768h128v128H896v-128z" />
</svg>`}getCancelButton(){return eh.Z.getTrustedHTML`
<svg aria-hidden="true" role="img" style="width: 1em" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 2048 2048">
<path d="M1115 1024l690 691-90 90-691-690-691 690-90-90 690-691-690-691 90-90 691 690 691-690 90 90-690 691z" />
</svg>`}getZipCardBackground(){return eh.Z.getTrustedHTML`
<svg width="280" height="170" viewBox="0 0 280 170" fill="none" xmlns="http://www.w3.org/2000/svg" style="border-radius: 8px; overflow: hidden;">
<path d="M280 0H0V170H280V0Z" fill="url(#zipCardBackground)"/>
<path opacity="0.3" d="M22.965 291.636C108.55 291.636 177.931 243.588 177.931 184.318C177.931 125.048 108.55 77 22.965 77C-62.6203 77 -132.001 125.048 -132.001 184.318C-132.001 243.588 -62.6203 291.636 22.965 291.636Z" fill="#411361"/>
<path opacity="0.3" d="M267.931 76.9269C353.516 76.9269 422.897 28.879 422.897 -30.3911C422.897 -89.6612 353.516 -137.709 267.931 -137.709C182.345 -137.709 112.965 -89.6612 112.965 -30.3911C112.965 28.879 182.345 76.9269 267.931 76.9269Z" fill="#411361"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M25.9503 34.2636L26.502 38.6662H45.8137L45.1825 33.6247H36.1771L36.0992 32.9993L44.3923 27.3222L43.8382 22.9101H24.5273L25.1593 27.9523H34.1783L34.2578 28.5825L25.9503 34.2636Z" fill="#FFFFFA"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M46.082 22.9099L48.0567 38.6659H67.3836L65.4081 22.9099H46.082Z" fill="#AA8FFF"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M47.9535 20.8192C49.2183 21.9214 51.0428 21.9214 52.0281 20.8192C53.0143 19.717 52.7878 17.9295 51.523 16.8273C50.259 15.7242 48.4345 15.7242 47.4484 16.8273C46.463 17.9295 46.6887 19.717 47.9535 20.8192Z" fill="#FFFFFA"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M80.508 31.0975L74.4596 31.1038L73.9858 27.3227L80.066 27.3274C81.495 27.3439 82.227 28.133 82.345 29.2124C82.421 29.9071 82.097 31.0975 80.508 31.0975ZM87.652 28.583C87.206 25.0411 84.366 22.8949 80.507 22.9098H67.6514L69.6261 38.6667H75.4088L75.0129 35.515H81.133C85.95 35.515 88.154 32.5742 87.652 28.583Z" fill="#FFFFFA"/>
<path opacity="0.49814" d="M30.6016 84.0156C29.9245 84.0156 29.3418 83.778 28.8535 83.3027C28.3653 82.8275 28.1211 82.2513 28.1211 81.5742C28.1211 80.9036 28.3653 80.3242 28.8535 79.8359C29.3418 79.3411 29.9245 79.0938 30.6016 79.0938C31.2787 79.0938 31.8548 79.3379 32.3301 79.8262C32.8054 80.3145 33.043 80.8971 33.043 81.5742C33.043 82.2513 32.8054 82.8275 32.3301 83.3027C31.8548 83.778 31.2787 84.0156 30.6016 84.0156ZM40.3868 84.0156C39.7097 84.0156 39.127 83.778 38.6388 83.3027C38.1505 82.8275 37.9063 82.2513 37.9063 81.5742C37.9063 80.9036 38.1505 80.3242 38.6388 79.8359C39.127 79.3411 39.7097 79.0938 40.3868 79.0938C41.0639 79.0938 41.6401 79.3379 42.1153 79.8262C42.5906 80.3145 42.8282 80.8971 42.8282 81.5742C42.8282 82.2513 42.5906 82.8275 42.1153 83.3027C41.6401 83.778 41.0639 84.0156 40.3868 84.0156ZM50.172 84.0156C49.4949 84.0156 48.9123 83.778 48.424 83.3027C47.9357 82.8275 47.6915 82.2513 47.6915 81.5742C47.6915 80.9036 47.9357 80.3242 48.424 79.8359C48.9123 79.3411 49.4949 79.0938 50.172 79.0938C50.8491 79.0938 51.4253 79.3379 51.9005 79.8262C52.3758 80.3145 52.6134 80.8971 52.6134 81.5742C52.6134 82.2513 52.3758 82.8275 51.9005 83.3027C51.4253 83.778 50.8491 84.0156 50.172 84.0156ZM59.9572 84.0156C59.2801 84.0156 58.6975 83.778 58.2092 83.3027C57.7209 82.8275 57.4768 82.2513 57.4768 81.5742C57.4768 80.9036 57.7209 80.3242 58.2092 79.8359C58.6975 79.3411 59.2801 79.0938 59.9572 79.0938C60.6343 79.0938 61.2105 79.3379 61.6857 79.8262C62.161 80.3145 62.3986 80.8971 62.3986 81.5742C62.3986 82.2513 62.161 82.8275 61.6857 83.3027C61.2105 83.778 60.6343 84.0156 59.9572 84.0156Z" fill="white"/>
<path opacity="0.49814" d="M75.9346 84.0156C75.2575 84.0156 74.6748 83.778 74.1865 83.3027C73.6983 82.8275 73.4541 82.2513 73.4541 81.5742C73.4541 80.9036 73.6983 80.3242 74.1865 79.8359C74.6748 79.3411 75.2575 79.0938 75.9346 79.0938C76.6117 79.0938 77.1879 79.3379 77.6631 79.8262C78.1384 80.3145 78.376 80.8971 78.376 81.5742C78.376 82.2513 78.1384 82.8275 77.6631 83.3027C77.1879 83.778 76.6117 84.0156 75.9346 84.0156ZM85.7202 84.0156C85.0432 84.0156 84.4602 83.778 83.9722 83.3027C83.4832 82.8275 83.2392 82.2513 83.2392 81.5742C83.2392 80.9036 83.4832 80.3242 83.9722 79.8359C84.4602 79.3411 85.0432 79.0938 85.7202 79.0938C86.3972 79.0938 86.9732 79.3379 87.4482 79.8262C87.9232 80.3145 88.1612 80.8971 88.1612 81.5742C88.1612 82.2513 87.9232 82.8275 87.4482 83.3027C86.9732 83.778 86.3972 84.0156 85.7202 84.0156ZM95.5052 84.0156C94.8282 84.0156 94.2452 83.778 93.7572 83.3027C93.2682 82.8275 93.0242 82.2513 93.0242 81.5742C93.0242 80.9036 93.2682 80.3242 93.7572 79.8359C94.2452 79.3411 94.8282 79.0938 95.5052 79.0938C96.1822 79.0938 96.7582 79.3379 97.2332 79.8262C97.7092 80.3145 97.9462 80.8971 97.9462 81.5742C97.9462 82.2513 97.7092 82.8275 97.2332 83.3027C96.7582 83.778 96.1822 84.0156 95.5052 84.0156ZM105.29 84.0156C104.613 84.0156 104.03 83.778 103.542 83.3027C103.054 82.8275 102.81 82.2513 102.81 81.5742C102.81 80.9036 103.054 80.3242 103.542 79.8359C104.03 79.3411 104.613 79.0938 105.29 79.0938C105.967 79.0938 106.543 79.3379 107.019 79.8262C107.494 80.3145 107.731 80.8971 107.731 81.5742C107.731 82.2513 107.494 82.8275 107.019 83.3027C106.543 83.778 105.967 84.0156 105.29 84.0156Z" fill="white"/>
<path opacity="0.49814" d="M121.268 84.0156C120.591 84.0156 120.009 83.778 119.52 83.3027C119.032 82.8275 118.788 82.2513 118.788 81.5742C118.788 80.9036 119.032 80.3242 119.52 79.8359C120.009 79.3411 120.591 79.0938 121.268 79.0938C121.945 79.0938 122.522 79.3379 122.997 79.8262C123.472 80.3145 123.71 80.8971 123.71 81.5742C123.71 82.2513 123.472 82.8275 122.997 83.3027C122.522 83.778 121.945 84.0156 121.268 84.0156ZM131.054 84.0156C130.377 84.0156 129.794 83.778 129.306 83.3027C128.817 82.8275 128.573 82.2513 128.573 81.5742C128.573 80.9036 128.817 80.3242 129.306 79.8359C129.794 79.3411 130.377 79.0938 131.054 79.0938C131.731 79.0938 132.307 79.3379 132.782 79.8262C133.257 80.3145 133.495 80.8971 133.495 81.5742C133.495 82.2513 133.257 82.8275 132.782 83.3027C132.307 83.778 131.731 84.0156 131.054 84.0156ZM140.839 84.0156C140.162 84.0156 139.579 83.778 139.091 83.3027C138.602 82.8275 138.358 82.2513 138.358 81.5742C138.358 80.9036 138.602 80.3242 139.091 79.8359C139.579 79.3411 140.162 79.0938 140.839 79.0938C141.516 79.0938 142.092 79.3379 142.567 79.8262C143.043 80.3145 143.28 80.8971 143.28 81.5742C143.28 82.2513 143.043 82.8275 142.567 83.3027C142.092 83.778 141.516 84.0156 140.839 84.0156ZM150.624 84.0156C149.947 84.0156 149.364 83.778 148.876 83.3027C148.388 82.8275 148.144 82.2513 148.144 81.5742C148.144 80.9036 148.388 80.3242 148.876 79.8359C149.364 79.3411 149.947 79.0938 150.624 79.0938C151.301 79.0938 151.877 79.3379 152.353 79.8262C152.828 80.3145 153.065 80.8971 153.065 81.5742C153.065 82.2513 152.828 82.8275 152.353 83.3027C151.877 83.778 151.301 84.0156 150.624 84.0156Z" fill="white"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M239.658 120.884C241.117 120.884 242.287 121.245 243.032 121.581L242.523 125.174L242.185 124.983C241.491 124.647 240.598 124.324 239.367 124.347C237.894 124.347 237.213 125.084 237.213 125.773C237.204 126.55 238.009 127.062 239.324 127.829C241.496 129.012 242.498 130.447 242.484 132.334C242.455 135.776 239.888 138 235.931 138C234.243 137.979 232.617 137.579 231.738 137.116L232.266 133.403L232.751 133.667C233.988 134.286 234.788 134.537 236.294 134.537C237.376 134.537 238.537 134.029 238.547 132.918C238.554 132.192 238.061 131.674 236.596 130.862C235.168 130.068 233.276 128.739 233.297 126.357C233.319 123.133 235.939 120.884 239.658 120.884ZM209.15 121.411H215.227C216.045 121.445 216.706 121.741 216.934 122.736L218.243 130.313C218.244 130.314 218.243 130.317 218.243 130.318L218.637 132.588L222.326 121.411H226.317L220.385 137.771L216.398 137.775L213.224 124.574C215.112 125.695 216.72 126.993 217.651 128.778C217.411 128.213 217.095 127.575 216.69 126.947C216.242 126.251 215.3 125.363 214.843 124.931L214.775 124.868C213.292 123.467 211.279 122.335 209.104 121.736L209.15 121.411ZM231.807 121.43H227.904L225.463 137.765H229.366L231.807 121.43ZM249.948 121.43H252.905L256 137.765H252.451C252.451 137.765 252.098 135.888 251.984 135.316C251.688 135.316 250.455 135.314 249.294 135.313C248.265 135.311 247.293 135.31 247.087 135.31C246.938 135.752 246.281 137.765 246.281 137.765H242.266L247.945 122.786C248.347 121.722 249.032 121.43 249.948 121.43ZM249.893 126.88C250 126.558 250.138 126.14 250.238 125.823L250.495 127.218C250.495 127.218 251.224 131.081 251.376 131.891L248.219 131.893C248.533 130.96 249.734 127.369 249.734 127.369C249.724 127.39 249.795 127.176 249.893 126.88Z" fill="white"/>
<defs>
<linearGradient id="zipCardBackground" x1="140.966" y1="-28.1842" x2="147.412" y2="191.269" gradientUnits="userSpaceOnUse">
<stop stop-color="#1B1323"/>
<stop offset="1" stop-color="#21182A"/>
</linearGradient>
</defs>
</svg>`}getAffirmCardBackground(){return eh.Z.getTrustedHTML`
<svg width="280" height="172" viewBox="0 0 280 172" fill="none" xmlns="http://www.w3.org/2000/svg">
<g id="Affirm Visa" filter="url(#filter0_ii_1_2)">
<rect width="280" height="171.902" rx="9.06191" fill="url(#paint0_linear_1_2)"/>
<g id="Frame 63343327" filter="url(#filter1_d_1_2)">
<g id="white_logo-solid_bg 1" clip-path="url(#clip0_1_2)">
<path id="Vector" fill-rule="evenodd" clip-rule="evenodd" d="M28.5899 45.4986C27.7242 45.4986 27.2832 45.0727 27.2832 44.3727C27.2832 43.0674 28.7402 42.6284 31.3977 42.3462C31.3977 44.0855 30.22 45.4986 28.5817 45.4986H28.5899ZM29.7333 35.7166C27.8336 35.7166 25.6498 36.6091 24.4639 37.5538L25.5468 39.8382C26.4975 38.9685 28.0345 38.2245 29.4213 38.2245C30.7395 38.2245 31.468 38.665 31.468 39.5527C31.468 40.1483 30.9861 40.4501 30.0747 40.5692C26.6674 41.0098 23.9967 41.9497 23.9967 44.5718C23.9967 46.6506 25.4782 47.9086 27.7928 47.9086C29.4458 47.9086 30.9159 46.9916 31.615 45.7874V47.5823H34.6956V40.0618C34.6956 36.9615 32.5411 35.71 29.7349 35.71L29.7333 35.7166Z" fill="white"/>
<path id="Vector_2" fill-rule="evenodd" clip-rule="evenodd" d="M60.6522 36.0543V47.5676H63.9484V42.0198C63.9484 39.3846 65.5459 38.6096 66.6583 38.6096C67.159 38.6057 67.6497 38.7505 68.0679 39.0256L68.6706 35.9825C68.2036 35.7958 67.7035 35.7053 67.2006 35.7166C65.5067 35.7166 64.4417 36.4655 63.7394 37.9895V36.0543H60.6522Z" fill="white"/>
<path id="Vector_3" fill-rule="evenodd" clip-rule="evenodd" d="M83.9463 35.7165C82.2035 35.7165 80.9 36.7445 80.2222 37.7366C79.5933 36.4557 78.2621 35.7165 76.6613 35.7165C74.9201 35.7165 73.713 36.6825 73.156 37.7953V36.0543H69.9774V47.5676H73.2769V41.6396C73.2769 39.5184 74.3925 38.4921 75.433 38.4921C76.3755 38.4921 77.2412 39.1007 77.2412 40.672V47.5676H80.5341V41.6396C80.5341 39.4874 81.622 38.4921 82.7115 38.4921C83.5837 38.4921 84.5082 39.1252 84.5082 40.6492V47.5676H87.8012V39.6082C87.8012 37.0219 86.0583 35.7165 83.9529 35.7165" fill="white"/>
<path id="Vector_4" fill-rule="evenodd" clip-rule="evenodd" d="M52.6305 36.0543H49.6446V34.8844C49.6446 33.3604 50.5152 32.9263 51.265 32.9263C51.7769 32.933 52.2802 33.0587 52.735 33.2935L53.751 30.9716C53.751 30.9716 52.7203 30.2993 50.8468 30.2993C48.7413 30.2993 46.3451 31.4855 46.3451 35.2075V36.0543H41.355V34.8844C41.355 33.3604 42.224 32.9263 42.9754 32.9263C43.4881 32.9263 43.993 33.0524 44.4455 33.2935L45.4614 30.9716C44.8554 30.6175 43.8803 30.2993 42.5589 30.2993C40.4534 30.2993 38.0572 31.4855 38.0572 35.2075V36.0543H36.1493V38.5932H38.0621V47.5676H41.355V38.5932H46.3516V47.5676H49.6446V38.5932H52.6305V36.0543Z" fill="white"/>
<path id="Vector_5" d="M57.8868 36.0543H54.5971V47.5627H57.8868V36.0543Z" fill="white"/>
<path id="Vector_6" fill-rule="evenodd" clip-rule="evenodd" d="M54.718 34.0979H57.9407C59.8208 28.1928 66.1993 23.0023 73.7849 23.0023C83.0104 23.0023 90.9831 30.0187 90.9831 40.9413C91.0112 43.1833 90.7028 45.4169 90.0684 47.5676H93.1964L93.2274 47.4599C93.7545 45.3307 94.0145 43.1443 94.0016 40.9511C94.0016 28.7704 85.1159 20.0033 73.7914 20.0033C64.8958 20.0033 56.9672 26.1711 54.7196 34.1012L54.718 34.0979Z" fill="white"/>
</g>
<g id="Frame 63343326">
<g id="Frame 63343197">
<g id="Frame 63343196">
<g id="Frame 63343325">
<circle id="Ellipse 1161" cx="27" cy="108.402" r="3" fill="white"/>
<circle id="Ellipse 1162" cx="39" cy="108.402" r="3" fill="white"/>
<circle id="Ellipse 1163" cx="51" cy="108.402" r="3" fill="white"/>
<circle id="Ellipse 1164" cx="63" cy="108.402" r="3" fill="white"/>
</g>
</g>
</g>
<path id="visa" fill-rule="evenodd" clip-rule="evenodd" d="M235.093 127.22C236.96 127.22 238.456 127.657 239.41 128.063L238.758 132.405L238.326 132.174C237.438 131.768 236.296 131.377 234.721 131.405C232.836 131.405 231.964 132.295 231.964 133.128C231.953 134.066 232.983 134.685 234.666 135.612C237.444 137.042 238.728 138.776 238.71 141.055C238.673 145.215 235.387 147.902 230.325 147.902C228.165 147.877 226.084 147.393 224.96 146.834L225.636 142.347L226.257 142.667C227.838 143.415 228.862 143.718 230.79 143.718C232.174 143.718 233.659 143.104 233.671 141.761C233.68 140.884 233.05 140.259 231.176 139.277C229.349 138.318 226.927 136.712 226.954 133.833C226.983 129.939 230.334 127.22 235.093 127.22ZM196.06 127.857H203.834C204.881 127.899 205.726 128.256 206.018 129.459L207.693 138.614C207.694 138.615 207.693 138.616 207.693 138.617C207.693 138.618 207.693 138.619 207.693 138.619L208.197 141.363L212.917 127.857H218.023L210.433 147.626L205.332 147.631L201.271 131.679C203.688 133.034 205.745 134.602 206.936 136.759C206.629 136.077 206.224 135.306 205.706 134.546C205.133 133.706 203.928 132.633 203.343 132.111L203.256 132.034C201.359 130.341 198.783 128.974 196 128.251L196.06 127.857ZM225.047 127.881H220.054L216.93 147.619H221.923L225.047 127.881ZM248.257 127.881H252.04L256 147.619H251.46C251.46 147.619 251.009 145.351 250.863 144.66C250.485 144.66 248.911 144.658 247.429 144.656L247.421 144.656L247.414 144.656C246.099 144.654 244.86 144.652 244.597 144.652C244.407 145.187 243.566 147.619 243.566 147.619H238.429L245.695 129.52C246.209 128.234 247.086 127.881 248.257 127.881ZM248.186 134.467C248.323 134.078 248.501 133.572 248.629 133.189V133.19L248.957 134.875C248.957 134.875 249.889 139.542 250.084 140.521L246.045 140.523C246.447 139.397 247.984 135.057 247.984 135.057C247.97 135.082 248.061 134.823 248.186 134.467Z" fill="white"/>
</g>
</g>
</g>
<defs>
<filter id="filter0_ii_1_2" x="0" y="0" width="280" height="171.902" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
<feFlood flood-opacity="0" result="BackgroundImageFix"/>
<feBlend mode="normal" in="SourceGraphic" in2="BackgroundImageFix" result="shape"/>
<feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"/>
<feOffset dy="-0.787992"/>
<feComposite in2="hardAlpha" operator="arithmetic" k2="-1" k3="1"/>
<feColorMatrix type="matrix" values="0 0 0 0 0.0288889 0 0 0 0 0.0296 0 0 0 0 0.0333333 0 0 0 0.2 0"/>
<feBlend mode="normal" in2="shape" result="effect1_innerShadow_1_2"/>
<feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"/>
<feOffset dy="0.393996"/>
<feComposite in2="hardAlpha" operator="arithmetic" k2="-1" k3="1"/>
<feColorMatrix type="matrix" values="0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.5 0"/>
<feBlend mode="normal" in2="effect1_innerShadow_1_2" result="effect2_innerShadow_1_2"/>
</filter>
<filter id="filter1_d_1_2" x="-4" y="0" width="288" height="179.902" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
<feFlood flood-opacity="0" result="BackgroundImageFix"/>
<feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"/>
<feOffset dy="4"/>
<feGaussianBlur stdDeviation="2"/>
<feComposite in2="hardAlpha" operator="out"/>
<feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.25 0"/>
<feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow_1_2"/>
<feBlend mode="normal" in="SourceGraphic" in2="effect1_dropShadow_1_2" result="shape"/>
</filter>
<linearGradient id="paint0_linear_1_2" x1="2.27207e-06" y1="4.75535" x2="234.857" y2="156.995" gradientUnits="userSpaceOnUse">
<stop stop-color="#4A4AF4"/>
<stop offset="1" stop-color="#3231C2"/>
</linearGradient>
<clipPath id="clip0_1_2">
<rect width="70" height="27.9021" fill="white" transform="translate(24 20)"/>
</clipPath>
</defs>
</svg>`}getKlarnaCardBackground(){return'\n <svg width="280" height="172" viewBox="0 0 280 172" fill="none" xmlns="http://www.w3.org/2000/svg">\n <g id="Klarna Visa" filter="url(#filter0_ii_1_2)">\n <rect width="280" height="171.902" rx="9.06191" fill="url(#klarna-card-background)"/>\n <g id="Frame 63343327" filter="url(#filter1_d_1_2)">\n <g id="white_logo-solid_bg 1" clip-path="url(#clip0_1_2)" transform="translate(168 13)">\n <rect class="cls-1" width="100" height="40.4494" rx="11.7384"/>\n <path d="M80.0772,17.7235a6.194,6.194,0,1,0,0,10.2373v.75h3.5145V16.9727H80.0772Zm-3.1964,8.1388a3.0243,3.0243,0,1,1,3.1849-3.02A3.1059,3.1059,0,0,1,76.8808,25.8623Z" fill="white"/>\n <rect x="28.2027" y="11.7416" width="3.678" height="16.9694" fill="white"/>\n <path d="M64.1542,16.6569a4.2694,4.2694,0,0,0-3.62,1.6383V16.9733h-3.5V28.711h3.5421V22.5424a2.4754,2.4754,0,0,1,2.6383-2.6591c1.5447,0,2.4325.9228,2.4325,2.6348V28.711h3.5107V21.2464C69.1577,18.5146,66.9857,16.6569,64.1542,16.6569Z" fill="white"/>\n <path d="M43,17.7235a6.194,6.194,0,1,0,0,10.2373v.75h3.5145V16.9727H43Zm-3.1965,8.1388a3.0243,3.0243,0,1,1,3.1845-3.02A3.1058,3.1058,0,0,1,39.8034,25.8623Z" fill="white"/>\n <path d="M51.9513,18.5017V16.9728H48.353V28.7111h3.606v-5.48c0-1.8491,2.0042-2.843,3.3949-2.843.014,0,.0276.0014.0417.0015V16.9735A4.3821,4.3821,0,0,0,51.9513,18.5017Z" fill="white"/>\n <path d="M87.323,24.5476a2.2059,2.2059,0,1,0,2.206,2.2059A2.2057,2.2057,0,0,0,87.323,24.5476Z" fill="white"/>\n <path d="M25.6675,11.7384H21.8558a9.7488,9.7488,0,0,1-3.9412,7.8678l-1.51,1.131,5.8513,7.9792h4.8106l-5.3837-7.342A13.5049,13.5049,0,0,0,25.6675,11.7384Z" fill="white"/>\n <rect x="12.1204" y="11.7384" width="3.8185" height="16.9773" fill="white"/>\n </g>\n <g id="Frame 63343197">\n <g id="Frame 63343325">\n <circle id="Ellipse 1161" cx="25" cy="75.402" r="2" fill="white"/>\n <circle id="Ellipse 1162" cx="34" cy="75.402" r="2" fill="white"/>\n <circle id="Ellipse 1163" cx="43" cy="75.402" r="2" fill="white"/>\n <circle id="Ellipse 1164" cx="52" cy="75.402" r="2" fill="white"/>\n </g>\n <g id="Frame 63343326">\n <circle id="Ellipse 1161" cx="70" cy="75.402" r="2" fill="white"/>\n <circle id="Ellipse 1162" cx="79" cy="75.402" r="2" fill="white"/>\n <circle id="Ellipse 1163" cx="88" cy="75.402" r="2" fill="white"/>\n <circle id="Ellipse 1164" cx="97" cy="75.402" r="2" fill="white"/>\n </g>\n <g id="Frame 63343327">\n <circle id="Ellipse 1161" cx="115" cy="75.402" r="2" fill="white"/>\n <circle id="Ellipse 1162" cx="124" cy="75.402" r="2" fill="white"/>\n <circle id="Ellipse 1163" cx="133" cy="75.402" r="2" fill="white"/>\n <circle id="Ellipse 1164" cx="142" cy="75.402" r="2" fill="white"/>\n </g>\n </g>\n <g id="Frame 63343197">\n <g id="Frame 63343327">\n <circle id="Ellipse 1161" cx="97" cy="115.402" r="2" fill="white"/>\n <circle id="Ellipse 1162" cx="104" cy="115.402" r="2" fill="white"/>\n <circle id="Ellipse 1163" cx="111" cy="115.402" r="2" fill="white"/>\n </g>\n </g>\n <g id="Frame 63343326">\n <path id="visa" fill-rule="evenodd" clip-rule="evenodd" d="M235.093 127.22C236.96 127.22 238.456 127.657 239.41 128.063L238.758 132.405L238.326 132.174C237.438 131.768 236.296 131.377 234.721 131.405C232.836 131.405 231.964 132.295 231.964 133.128C231.953 134.066 232.983 134.685 234.666 135.612C237.444 137.042 238.728 138.776 238.71 141.055C238.673 145.215 235.387 147.902 230.325 147.902C228.165 147.877 226.084 147.393 224.96 146.834L225.636 142.347L226.257 142.667C227.838 143.415 228.862 143.718 230.79 143.718C232.174 143.718 233.659 143.104 233.671 141.761C233.68 140.884 233.05 140.259 231.176 139.277C229.349 138.318 226.927 136.712 226.954 133.833C226.983 129.939 230.334 127.22 235.093 127.22ZM196.06 127.857H203.834C204.881 127.899 205.726 128.256 206.018 129.459L207.693 138.614C207.694 138.615 207.693 138.616 207.693 138.617C207.693 138.618 207.693 138.619 207.693 138.619L208.197 141.363L212.917 127.857H218.023L210.433 147.626L205.332 147.631L201.271 131.679C203.688 133.034 205.745 134.602 206.936 136.759C206.629 136.077 206.224 135.306 205.706 134.546C205.133 133.706 203.928 132.633 203.343 132.111L203.256 132.034C201.359 130.341 198.783 128.974 196 128.251L196.06 127.857ZM225.047 127.881H220.054L216.93 147.619H221.923L225.047 127.881ZM248.257 127.881H252.04L256 147.619H251.46C251.46 147.619 251.009 145.351 250.863 144.66C250.485 144.66 248.911 144.658 247.429 144.656L247.421 144.656L247.414 144.656C246.099 144.654 244.86 144.652 244.597 144.652C244.407 145.187 243.566 147.619 243.566 147.619H238.429L245.695 129.52C246.209 128.234 247.086 127.881 248.257 127.881ZM248.186 134.467C248.323 134.078 248.501 133.572 248.629 133.189V133.19L248.957 134.875C248.957 134.875 249.889 139.542 250.084 140.521L246.045 140.523C246.447 139.397 247.984 135.057 247.984 135.057C247.97 135.082 248.061 134.823 248.186 134.467Z" fill="white"/>\n </g>\n </g>\n </g>\n <defs>\n <filter id="filter0_ii_1_2" x="0" y="0" width="280" height="171.902" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">\n <feFlood flood-opacity="0" result="BackgroundImageFix"/>\n <feBlend mode="normal" in="SourceGraphic" in2="BackgroundImageFix" result="shape"/>\n <feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"/>\n <feOffset dy="-0.787992"/>\n <feComposite in2="hardAlpha" operator="arithmetic" k2="-1" k3="1"/>\n <feColorMatrix type="matrix" values="0 0 0 0 0.0288889 0 0 0 0 0.0296 0 0 0 0 0.0333333 0 0 0 0.2 0"/>\n <feBlend mode="normal" in2="shape" result="effect1_innerShadow_1_2"/>\n <feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"/>\n <feOffset dy="0.393996"/>\n <feComposite in2="hardAlpha" operator="arithmetic" k2="-1" k3="1"/>\n <feColorMatrix type="matrix" values="0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.5 0"/>\n <feBlend mode="normal" in2="effect1_innerShadow_1_2" result="effect2_innerShadow_1_2"/>\n </filter>\n <filter id="filter1_d_1_2" x="-4" y="0" width="288" height="179.902" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">\n <feFlood flood-opacity="0" result="BackgroundImageFix"/>\n <feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"/>\n <feOffset dy="4"/>\n <feGaussianBlur stdDeviation="2"/>\n <feComposite in2="hardAlpha" operator="out"/>\n <feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.25 0"/>\n <feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow_1_2"/>\n <feBlend mode="normal" in="SourceGraphic" in2="effect1_dropShadow_1_2" result="shape"/>\n </filter>\n <linearGradient id="klarna-card-background" x1="2.27207e-06" y1="4.75535" x2="234.857" y2="156.995" gradientUnits="userSpaceOnUse">\n <style>\n stop.klarna-background-base {\n stop-color: #363636;\n }\n @media (prefers-color-scheme: dark) {\n stop.klarna-background-base { stop-color: black; }\n }\n </style>\n <stop class="klarna-background-base" />\n <stop class="klarna-background-base" offset="1" />\n </linearGradient>\n <clipPath id="clip0_1_2">\n <rect width="100" height="37.9021" fill="black" transform="translate(1 1)"/>\n </clipPath>\n </defs>\n </svg>'}getErrorImage(){return"iVBORw0KGgoAAAANSUhEUgAAAPoAAAD6CAMAAAC/MqoPAAAC61BMVEUAAAC0qKY2MzrYzd/91zb/9kxTSV1FImHdz+eSfZ/ej0h1WJJFQZSQg5rcMX9dW1+WhqGYgabLxs69GGeKgJL9yTf652LppknbhkWmfk/pzV67gC/uKkranENwamxRT1LWxs3//WHtu0Tqv15VUVejcJf/6j7rxF7Qx9fONXSDeIvVMmJlX2tiVH/PLnfNxNTKwNHSydmETVi9KWfPN3nBs8i5rcCwnV5NTVuxqrVtYnnbyVTs0jq9J2fDuMrIIz3Hvc27scOwpLjGJkDyMVDaNnlnWm93aoVpYW6ekKddVmv042jBhC2OX3CFXVO3n1786WaUh25OPF1MO1tKOlhPPGBJOlVHOVNFOFD40UL7u0T7vkNCN0z5x0L5xEL6wkNANkdBNkr6zUNEN076tEP7ykNBOkb3zkL5z0L6tkL6y0L4s0P6sUP7x0P5ukL8t0T6uEL7wUP400FMLWNKKGP3v0T51UT3ykLazeL4rkEzMDhPOGHWx9+diqr7xEP/8FE9OEBNNGHPv9pWQV7Txdurl7hRQVtPP1a3pcONfZhYTWL+xUH/0kCvnbs6MESlaWtGREf+1j/Jt9TyqTylk7BYN3UwKTdINVv/5lHGkEm0oMFcU2ZNPlE6LUrSy9ejjrHSI3YrKTPIGG5KPUn82Ub/wELNv9XzxEPGttHArsyNalf+xDcEEkvgn0i7qMf/3kmacVb8z0JEMlT/uEI7MjleSlkkI0onImBAMFxHOkr0uEUtKFT/zEGJdZaDakn4x0c6K1Xvr0deT0qteTPvoEe+rMgVGVPomEjemTDTkC70qUbqojbHiC3Cr84fHlrHElTltUnnLWQkCmLlvEU2LD6PGyvTsUkPIEjLETrWG2D2LD/msUfiMnXaF0jWESrEs82BbI63jUnXrk1vWInmw0PnHTSkhlfmJ1b+4TvHvM4CCTqiYlRyWUHcKHC5k0UwPkSzhEzAnDxSNHLWsk2YOj/PnFI8MWu+tsOATnJvaunrAAAAUnRSTlMABv79/v3+/f7+/k1NWP7A/v1p/t/+o/7+28H+/v6l2yP8/sLZIP7BzmLfh6T93M7OzvuuPf7+/sVpOP7+1s7ezs7Ovqight5Vzpds/fTewYakAMEs9AAAFkhJREFUeNrs0jFuhDAQheHxBdzQbkthIbmBFqXYcM/VXgily0qhpuIOGYOIA3XMFPm/C7z3PBYAAAAAAAAAAAAAAAAAAAAA+K9c7cSeE1VfWSW0fXzEOHRizYU2pirNNVVCXz2fz0cS7cafq1xxh6bSuC3Pe9+IHdceqgQpTON+XtqrQay4PlfxJbfnmx+eOgU6sbAd4VClK1mlOy9XtZgIe5XcJDopp62S4/TB5ux9nq586R9Yr3H5qQ3P3lXJqUqUYkKVty/L8rUJYqD5NX1Zu3it0kkpmjeqV5KnNxY/vh3HXEWVvoLm5cCP3SAG+r3KoUu56fcxmcZJ0+Z5z3uX67m3rcpr0ia5SrkPeP9cTcmc3BKb6Ycqu2um3xLr6dOpy19Od+fp38Tb2+uLcRwH8Ai3rpDzMW5cuRLKjSSEWJttbMwYxthqll3gygppUiJciKUccho55ZyI3DiVC6WQfskh/gDvz+fzfL/f57B59myPvL/P92sjj+fl/X2eOb7nfKKMeieZ8x8ec6CbS0FGjXqH4aT36xdm6+9tPxzQiv4fMtsO15cS4u+mZsydOtiWab9fO/P72aNHj4ZN9GaKI4unD+4g0xeP6CRTvJci14IsMicbM3TognGovkv49Pq6uj3fv3+vVk+o9O/7OmFHKnX3bjqdvvuXXPpZ7yRvv22Lb/PNqfid7+pSTthT/Y7oy93/4OOFwzt3Dh3XnX1evX+1vyNNe3b1fS2ctZLidcjZIS2y72dff//s6vs5oDQAh1la5cusr3279KV4o072YNbkL5MnDxw4viv7jPqJ6qFD1XZpGjki8lY/AQNIXvVJ/ybk7QMyDh5f+5pVvzRZTvTx48d30/qk6qETJ4jepiWRu/QCt+t/9qELnzSp830DhgzA8ffcQed+2WXkyFDUHni74wYCvf+uVqm//Xpzb7JBKTbOFht79xb3tsrtn293+Wdd388D+xw5cACHO19Kd/rqvierX3sw6wuCe53o2PJBM38X00m+zhOSNxJJpEGjyLNYxMRPwQ4N3wH5Ov/Uz33bd8mZfTgk+BLqbQcOlA7k7pyr+56M5acuIBZ9QeDaB/dn+qtW8pNvv95vbE1Iko4U7dl7pBP5ScjXIhnOpUsZDDourafJg14cqHQmx7N92ylE0ZcEpk+vCn3/rlWr1uFwya9s2EopWP5CIplIulLuWH575cq1lI32ZDI4OOvXr7+UuwT5Sf+TQX6qhA9BopN94EDc7F095UBfJVlHYx29Ynl+wwbgWa+SSPBMJgvJMuAFS776b2PVuhuQb15pZS1mhdwVrBLxV1jOJciV6FeONyQ/ADmFat85sHe6iZG3whOf9eVkg+Tqp82s6iVfr8gJbfAI6Fqe28jy0ySXc3izWr7BkpdKvdH7ja3yfnfTcXot36ro7qB36VxdGq5sNXO5a7ynwrGwPJVa6U5lJWqvSP84lLx12K3l8RKlN7pqff9+rzwLOOPb8tG5qQhUWmQgrKc3LBd6yotnOFYfOcfIQ6KjdY98GHWet9kLBN+KoVIWOXTGrt6JXuDSOdO9gZzZSAB5rvSv6Dcg35JXcFN7AXZX56vFamI6t96pzr2tb8RkOfszAeTxUOm2S5fO8/kszeyGmxtwbMXBtbvkbQKxhOWbRY7DQQecBqI6t51AD8T8vFryeDxsunWtx0+SPEtsBO1T6ZAj7s5vtKE75HtTVhiectqZbnXuezKRCzweDp33u5Gf584RLHAjkBcAv0m9G/mNYHJu3WmHmo6AcgRySo90RNONHGp1s+d16fDbOl+xwu9aV9w498F0ruwO+sqN9GwPIGc0lpDpRs6F59nNt7o84aV007n4MOSFWvTXq851SO6527V8RYDOQ6O75YTnMF30CB52NvkKFSBbhTtPO+SIAy93OslxEnUW+TmQV7RgNXKBY2F5SK1r+Sah4yGXtR5xmOTmHa92O+Q+Mbu9feuwX2K5T5Qcdnyosz60DW/kmo7YPtcJD3cweVpKN7e6174xoByBmo6e6VWi2+UC1xs+T3TsePBRecfyNUqOQwVwGkHliCUHXaJKD4cu8u15E6jZTV8wHHIskK8JKG+/4dcGkdMw9tBaV/JNWbPhsd8tPeRWCkHksGPY6S777S46z8luD691kUO9CVNteJajcYrApfM1K9as4AMTC7/hKYuRg+1pPeXo/PGxFeoccjqZOmsgv0VyYXPdTMcIp/XVx0+OhlzRs1a4cy2/SfJruEAbHQNZwYMXLS9T5144Dod8jZcuU9FFTmosDOcRTuuvXq2CPAu55cZkN75Qcsaz3Dcihxvx4DEccnhxIOyXV+YN5MduPXi5L7deOpcJPc8e6f2Jvv8ayZFNedhZropXtd8EfEPyyLXlyzuTI2XgWc7LDsARsZvOTRTd+ROh5WLXkRte03d2S7+2avQmuCGngYBPavw5TVZKxyxsaHQiX07ychlyctM0lSu3kftF5EzPqUe8/nDvuXWWc+UI6FAzHmze71uUXeTG6ADLisM84fhA3a57Pbh8PdHFnCvl1G43H26wz5wKTWB69UTz6cGDQkfltEjrmNS6ROSg80DYKW8w6Q0vx5QctZPfEXfny9VAAOWVXzjkii6dIyKP69YhX9YNvXmi+fwZ07HfcUDNcKGTPK/lLSN0CeSy2yUpLz1l5K5zeF9ZctiZbuBqSuuHB86M7O6CDvnIJ6Dr1jERuBmucwVy34g87YiLbpP7RO12dI6+gde3utRuPtdnLt09qAt6tfnwKdMRorOf8YhqXeSxjuTpdNEr3yGL0FNB5LzdVes5Wkq6fKafOjxzENJN6w+fC53tEmLb6IHkRbccYtGzPKU794t6whEcM856k5J6xF+YOWjPnm7okx4utNHRudzrtqD1vEse0y9int1ONzpNrEw3esh5ijzWibwCOsfy0gsTkf9auudoV60PfzhS0zdZydr5VudA+iQm8nRRWvc+6eA3cldireWAqw2fi2Pa3TS2lU79ig06uqdHurZjswtc6Nm8Vx5rKy8iDrqosd2xbt68ObXZK0d85KAbd07LS/FTby7X9uwh+pgeW2d8lvCGruQxDAc+xhOHlifLSQU3dInYU265/u62m8gmp4GArt18lMQO+b3oILQeAh1Rt7vCs9w/xx5/aJTLyWSxXEy79LzTBS7ymE+0XJWOKW6eJUzJgTf3YrXdIdBh58iNbuS3YtFO5Njt6Bz2NA7vlqfe28nRuT2WPKNLp96pbsE75MfCoVulZxnfTr68tfxHI0kB3t26utNTTnl7/7F7JM9AS43raTPneIF8+bFobfeeUOjmORek86iWl4VedNDToCMir8X8Urt3leSZzPoMkXOykJ/IvCj55WPRMOh6u0OOaHk0gBzBvV703usiL3ciPyZyhLc5FgSrrW/TeUzoR8O61/l3ra7Ooxj+ndPAje6xp0R+BvK/7SFAlDwngypHZJXSbZ1DHhZ9k4qr86ihR+UFr1F5WxO5rh2xs1F6Om3k8p0MlYaOlm/k/a4ecTTi0rtHLvQ9YX24CVzJW9Kjiq7kBu7pnGoXuZzAQ5cTmvscf/XK8gx1rZonMIZDHi497+qcjXarbcWXarcXzFMuWXbi+YNtL8nFjUPO4KZHIVedw42QnAfSovOQ6YhNzjrzhTe1FyRPlInt+HTTerXbX9SiknZnjEUtuSRHU5Wei8O+3in/V/RNJPdP7dznRiIBO8sxvU94utf3GnkLsYqWb0S4dNQuekTUdnn4dNO5v/zxxQTYBaCVvMi1OyNyvxi5TPVxLnTYczn757kkEgmRjgSQ4y43+72MIc85+oTrRB7BcMip7gpvd17ANr+k0fKY7Wy12qAw6SyPdNZ5geAJLl0OyMltskPLvXCn/BLJYQcek/ggm97dcmk9TLq/PGLkcqNLqHMayF92e8S5Roz8dgVwyCUiB1q3rna7Qx7ZHSYd8kgtQqeVs9MLPjD5K/lL6ZztBb7VZRG6q/NIm0TVF5ac4GyviB0DZEsPuOk8fLqR+wXyQqKQQLh3cWMwvUz4opH7Re12+YfCpvWKwKV77vz6ZZd8We/04HL5LwEQ893O9iLpuXQ6Asvp0Pe6PObWZ4gtIfkf1u2YNYooigJwpX/DxtI+f0IEZ1zFlVWQLJJonIkQFhuDBFLEkMZiBUkXazFFIiimsNFGxJ9gYS0I1p53z957817ynNnZOTPMrEKG+XLuvEyRTOVqN3UEvfWdhVt/2lL+jfIQzLsvcwjsSJfOo4kHHIEdZjZPefK1ZW/0IC8bb3bb5Rh27FSv20t82CjfbiX/OAp/ETMWurXu7zRR53F6o7PzdvKhRuxSvNCxy7xvvGgr//5xMh6HaR/HSzzkSPjhnsj7bz037eWpj2WpctlADvboFZ5r/ExeYrMLlHos+SlcDHJ0Ln8SAD7HfZXruw484LnOy37oLi8Tb3TbUefC9sqt9fWNZyr3axncP2+/FzmCyhHCg5rh+uadp/SeWs8+52V22hGTOx5h55nvoMXlCOC0+8Rr65G8/9Yp5yjiwLZ0xnHgSeWR3eks3TuX8Hr2UacdH0R+QjhLj0O6yzlD/tQ4fWcR+iN2XjI86wcP5DXdGoV77yovm2Kd+7wTz2eddMh3/1Buj482gxQL002ejcvrIfPYW/dw2tvK2bnXrnyfd7zT7ErnWoR1j2Mv9Kec9tZyT1o65OtzdU642dOBh3w65dWSSYzpVzrSX7aVV1m5Dzzkx3PK5ce6l+7htGev5vTB9Y703x/CG3ErudZu8AS/EeRbbacdduUncmYSpj0vLwrSX/9Ywu/NdaB/+Xx0eLNRvhWmfaWGPU7SucuLInO71vlI2GtBz5mP3Q8g/8lpz2UbdMj/Ll3oRP8K+a3pefRCNuyUV8OVKpWn61zUeYEd0X/5RSlfQ8Zp7eB787t/KM8mtC7yzS70q5+P9g8PVV5Iwkn/wWOQVzV22m3qne3TrtfwE7S8HjOTw47eNWeWOeu8+N+8gw55N/qno33QVe43rJ8pP4Z8JciH3KxybK5/I50XUZQOQCyHG5HSJ4DrUpfKZ0UUVoTPkNzZzt+lzc1O9E9He3tGj7x+r6XKK0NXjvew8zR+MSq2KGdGY8w88RqVc9qJJbhIO0cuHkPeiX5tD3LSnZ0G8hWRY+SBxjl+iW+WM+m0Q20DL2h90K3zU9841m9t2K0tvXrVjX4pop9vt85ZOwqnXOnkb7x53CjXzu+ujYQOe7TOnVrjVZ4OoG0c9x+/3nalX57Rp5ygJnmA167mZs95e7lE5KKHOe7dO88sHCY/WJzeJKe9hj3RD7vLiWfzwPsrzarL86H84KAz3Qe+4TlHoK4rYVfps76+iNxD+6S1HL8e3PvAp9POCJr4iD6c6zlPEsmReeQ90KfTrHy5Wq402nadyO+IfIAvwGEwwBEHHOXE/zb5s/+VPtbOt1rJ+6Gr/PSdJ3LS6bfAzc4HDUk6J131tsTfX83JB2flT3qh3yCdRWGTmNwj7AgP+dDl+Vjn2HO931c5p2WAhGNKpxy/Hdxf6wNNLI/0XOAt7Ly9nO4MfRU75M/9aqT7WQeA8n5al9LPky9T7vA6Hvh55Pdm8nSNx2FCOzp/DnlTgvw2sih9n/SMXOzhx1stbzSAJ8vcPHLQw7Z2IuoR9hO+zOEU0l4Od1/0aU4OuhUP/VC3Tp3Tjl0r5w74nPJ3cPfY+ln5Q8AVXxOPDe66k5z5R8z5vLQNhnE8PYXUigqDevHSTU/z0pP0D1DnEHbxIMy5waCTHnQkrkioEEpBEZGBIsqGF0chUCxeVmShCkKhJ8k1l6LgZZfRUdhx3/d5Y1rr6pvWST/v877+IInvJ89raOB93+Iqkr6KvHv6bMgz+znf5t6M0Y7VwbO3/BPN7h1zWg1B4igY8O6YhzgNfJ53v+bOBpkTbyjrXtrnvLeYH77N+ewSN+0PVEfW9Vbmnj5YuikA729Lvs2Xoc4nyxZpojT+0VfnkP4i3Fm0Zx6vp/2QVnaOPCTrus7cUfENNyfeeyDtC3jgMRbdJ94CzOk0NPwLb1345VzzeYijQaHM86CHHa9FMmdnedW7iPuza86nUAJypxHfkfqYq24Yhk6QuckWdDeSoBVg3rJ25p9YTJC5gJlCGuYAc8qWEfOIfy15ZeYwFADzeDzJgDrdAagfjYBXbav3vfvK1evo383ySnmlGdqvpg5uhGnrhghdToe/nWBfPgEbl6oqvtqMfZ1MZpONfJg9PMIWwkcv21PH0eOvoX5aUOvotlkun1Pcx0oZ5qoIQ07nls5OGGhbEvlY0zRDFaHb+ewdkrOfsYnwp5jULsNfYH5a0DRNdbHN83sJI1hj2oYqRNaHEmdiTmqyrGrC+2jnI5GLCCqFSzYbxy7TT6X2mTqGuixrLqodLfngvBS1VU0EzGthAQ7q2R4zF6HaeaeZC+eC5H9PdqAeGDuGOty5vR0dDA4GEby0oBQUmwNZ3SsFc42FmmbCZC7ENnPNXOacnONEIrVxqRMCfYZcJzp4L0EWAOayCE1O7wX98Isd25qbEWQOtaB2DfPOmOzbqVZ3GNWdLeJnM1u3+YPDxVSnt3yBP9sKdAzjoVDYxTt83qX59OnnIalzhmOxHk6IM0pceUyEbtHjk5AQ8dXGrxoYBVOhW8QC0n9lolKpWJaiDDAUy3oidY3ehq4oilWp9EqPR0AKQN1SBlIHB5lMZjs1oHRNPcDULerLNutKv7Lei18+HlC31pXUQWZzf21tf3M79ULqGlCHOcTRF9aV/sfMOtT/klvHuA2FMBiAkd6ULa16iu48qUul9lxkQTyJDCzoTRkYLVi4QUfGnIGZE3QNGClDdnCk/BewPxksf2K5zegYQtJmJ6XjzLeLjimtxuxfbGSQftq3SwzZ56Q3WjpOofWS+bqa4fTz8bTXcldrfYjml1HlTtcp+9LsM+hYzoL1XFPS65LD9558qeGz6MEDgOUrLf0N/x72Usr/FDqWkxJyIqe3v9foMJ7+1+lXC0qC56T0c6PrmC3INvbh9MOx/q9aTioFhf8wsnR6XzuqNfPOHjKQLm0mpuPGxV7cFHpdLanT4Xnoyk2ki/bISOmHTveglHAOZtFBCfFa9A+8Y3WlS6R/M5I80kWlu1l0nLp8GvqyTKC3E/5OB1o6nvCh05fh9Bu7doybQBBDYXiQm0mZG6SJlC7JDXIsF6ZBEylpt0yRfhpuwp0YxEqsoIHm+WntdwI+/R4KxO+S3ojo/xD69/y+jID+h6/OQkcf/Lm6DvpXuX8rqc5AHz8SutB3gy40dEHTrTVXuuPBCwN973Pw1j4KfLf0XZNw9O1MB1c35aD/OFRXVWM5eFMYvY/qBPTzwU8Rq289vuaIqh8mD7pEpVcOeh90C1xd4dXtveB3Szcgvc/0xkFvBq6uHPSOPfhOdvAKpo+x0EUUXV0I6H3Qwx388+LgwdWrulZ/utAFTzcSuqlEpQueLm/lga3j4Ke49KzOQte4b33QwdVrXDpN9cBvHUyvRHSFV68al85SXRzon+WBrap60IOvYxqzeiWqLll9uaQnPelJT/oK6Ih/VZTX014WK27bXH+WTcnlcrlcLpfLHTcKRsEoGAWjYBQMcQAANMdXEG0K8Y8AAAAASUVORK5CYII="}},this.currentProviderType=this.flyoutData.dataStoreModule?.VirtualCardData?.cardProvider||r.M$.ZIP,this.cardNumberLast4Digit=this.flyoutData.dataStoreModule.VirtualCardData?.cardNumber?.slice(-4)??"",this.cardHolderName=this.flyoutData.dataStoreModule.VirtualCardData?.cardHolderName??"",this.cardExpires=this.flyoutData.dataStoreModule.VirtualCardData?.expires??""}resizeFlyout(){if(this.flyoutData.dataLoader.IsServerData()){const e=document.querySelector("#divContentWrapper");gn.SO.queueUpdate((()=>{this.pageHandlerModule.ResizeIframe({offsetHeight:e?.offsetHeight,scrollHeight:e?.scrollHeight})}))}}},CI=class extends yI{constructor(e,t,i){super(t,i),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"ShouldRenderNotification",(()=>Promise.resolve(!0===this.flyoutData.dataStoreModule.VirtualCardData?.hasError))),(0,s.Z)(this,"GetNotificationName",(()=>r.sM.VIRTUAL_CARD)),this.flyoutData=t,this.utilities=i.viewModulesUtilities,this.logModule=i.logModule,this.pageHandlerModule=i.pageHandlerModule,this.stateManagement=e}GetPopupOriginationList(){return[]}PostProcessingNotification(e,t){}RenderNotification(){this.strings=this.GetStringForCurrentProvider(),this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getNotificationStyles());const e=document.createElement("div");e.id="virtual-card-notification",this.applyStyle(e,{textAlign:"center"});const t=document.createElement("div");this.applyStyle(t,{backgroundImage:`url("data:image/png;base64,${this.assets.getErrorImage()}")`,backgroundRepeat:"no-repeat",backgroundSize:"cover",height:"90px",margin:"0 auto",position:"relative",width:"90px"}),e.appendChild(t);const i=document.createElement("h2");i.textContent=this.flyoutData.strings.virtualCardSystemFailureHeader,i.classList.add("txtLarge"),e.appendChild(i);const n=document.createElement("div");n.classList.add("description"),n.textContent=(0,T.fZ)("virtualCardSystemFailureDescription",this.flyoutData.strings.virtualCardSystemFailureDescription,this.strings?.payment??""),e.appendChild(n);const o=document.createElement("fluent-button");o.classList.add("detail-button"),o.textContent=(0,T.fZ)("virtualCardSystemFailurebutton",this.flyoutData.strings.virtualCardSystemFailureLink,this.strings?.payment??""),o.addEventListener("click",(()=>{this.pageHandlerModule.NavigateToUrl(this.strings?.cardUrl??"")})),gn.SO.queueUpdate((()=>{o.shadowRoot?.querySelector(".control")?.setAttribute("style","\n width: 100%;\n height: 100%;\n border: none;\n font-size: 16px;\n ")})),e.appendChild(o);const r=this.utilities.createNotificationModule(e,this.GetNotificationName(),this);return Promise.resolve(r)}},bI=class extends Qu{constructor(e,n,o){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"sectionWrapper",void 0),(0,s.Z)(this,"collectionItemDataElement",void 0),(0,s.Z)(this,"saveButton",void 0),(0,s.Z)(this,"saveButtonSeen",void 0),(0,s.Z)(this,"settingModule",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"handleCollectionPackageDownloadError",(e=>{this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Error when injecting collections package - "+e,new t.Z(i.xu.CollectionsPackageInjectionError)),this.sectionWrapper.style.display="none"})),(0,s.Z)(this,"handleSaveButtonIntersectionCallback",((e,n)=>{!e||e.length<1||e.find((e=>e.isIntersecting))&&(n.disconnect(),this.saveButtonSeen||(this.saveButtonSeen=!0,this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"WishlistModule save button is visible",new t.Z(i.xu.WishlistSaveButtonVisible))))})),(0,s.Z)(this,"handleSaveInProgress",(()=>{this.saveButton.disabled=!0})),(0,s.Z)(this,"handleSave",(e=>{if(!YE.collectionOperationIsSuccessful(e))return this.saveButton.disabled=!1,void this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Error saving collection item",new t.Z(i.xu.CollectionsPackageAddError));this.updateClickoutUrl(),this.updateSaveButtonInnerText();const n=new W.Z(i.$S.WishlistSaveButton,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"Item saved to wishlist",n),this.pageHandlerModule.RecordAsUserEngagement(q.FV.WISHLIST_SAVE,this.flyoutData.common.popupOrigination)})),(0,s.Z)(this,"handleUnsave",(e=>{if(!YE.collectionOperationIsSuccessful(e))return this.saveButton.disabled=!1,void this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Error deleting collection item",new t.Z(i.xu.CollectionsPackageDeleteError));this.updateSaveButtonInnerText();const n=new W.Z(i.$S.WishlistUnsaveButton,this.telemetryUtilities.setContentViewed(this.GetModuleName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"Item removed from wishlist",n),this.pageHandlerModule.RecordAsUserEngagement(q.FV.WISHLIST_UNSAVE,this.flyoutData.common.popupOrigination)})),(0,s.Z)(this,"handleCollectionsRetrieved",(()=>{window.sj_evt?.bind("onSaveAdd",this.handleSave),window.sj_evt?.bind("onSaveDel",this.handleUnsave),window.sj_evt?.bind("onSaveInProgress",this.handleSaveInProgress),this.updateClickoutUrl(),this.updateSaveButtonInnerText()})),(0,s.Z)(this,"handleLinkClick",((e,t)=>{e.preventDefault(),e.stopPropagation();const n=new W.Z(i.$S.WishlistSeeAllLink,this.telemetryUtilities.setContentViewed(this.GetModuleName()));return this.logModule.LogInfoEvent(i.R.ButtonClick,"Wishlist see all link clicked",n),this.pageHandlerModule.RecordAsUserEngagement(q.FV.WISHLIST_SEE_ALL,this.flyoutData.common.popupOrigination),this.pageHandlerModule.NavigateToUrl(t),!1})),this.stateManagement=e,this.flyoutData=n,this.utilities=o.viewModulesUtilities,this.logModule=o.logModule,this.pageHandlerModule=o.pageHandlerModule,this.telemetryUtilities=o.telemetryHandler}GetModuleName(){return r.ModuleNames.WISHLIST}ShouldRenderModule(){const t=this.flyoutData.dataStoreModule.PriceComparisonData,i=t?.segment?.toLowerCase(),n=i===r.VG.AUTOS||i===r.VG.EMPTYAUTOSSEGMENT||!!this.flyoutData.dataStoreModule.AutosData?.isDetectedAutosDomain||!!this.flyoutData.dataStoreModule.AutosData?.isAutosSupportedDomain,o=this.utilities.isValidScenarioForProductSummary(),a=e.R.isExperimentActive(f.H.wishlistModule)&&YE.isFeatureSupported(this.flyoutData)&&!n&&!o;return Promise.resolve(a)}async renderModule(){if(!this.flyoutData.common.extractedEntity||!this.flyoutData.common.base64ProductImage)return null;this.sectionWrapper||(this.initDOMElements(this.flyoutData.common.extractedEntity),this.addCollectionDataToDOMElements(this.flyoutData.common.extractedEntity,this.flyoutData.common.base64ProductImage));const e=this.CreateModule(this.sectionWrapper,r.H7.WISHLIST,r.ModuleNames.WISHLIST,r.$k.CONTEXTUAL,r.SV.SQUARES);return Promise.resolve(e)}populateMainHeader(){this.sectionWrapper&&(this.sectionWrapper.slot="header-content",this.sectionWrapper.style.marginTop="20px")}PostProcessing(e,t,i){}hideSection(){this.sectionWrapper&&(this.sectionWrapper.style.display="none")}initDOMElements(t){this.saveButton=document.createElement("fluent-button"),this.saveButton.innerText=this.flyoutData.strings.commonSaveSimple;const i=t.title;this.saveButton.ariaLabel=(0,T.fZ)("shoppingWishlistSaveButtonAltText",this.flyoutData.strings.wishlistSaveAltText,i),this.saveButton.disabled=!0,this.saveButton.classList.add(qE),this.saveButton.style.fontWeight="600",this.saveButton.slot="control",this.settingModule=document.createElement("msft-setting-module"),this.settingModule.text=t.title,this.settingModule.icon=xc.Wishlist,this.settingModule.linkHref=YE.CollectionHomepageUrl,this.settingModule.linkAria=this.flyoutData.strings.wishlistViewAll,this.settingModule.linkText=this.flyoutData.strings.wishlistViewAll,this.settingModule.linkClickCallback=this.handleLinkClick,this.settingModule.append(this.saveButton),this.collectionItemDataElement=document.createElement("DIV"),e.R.isExperimentActive(f.H.singleScrollingShoreline)||(this.collectionItemDataElement.style.margin="0 20px 20px 20px"),this.collectionItemDataElement.id=KE,this.collectionItemDataElement.appendChild(this.settingModule),this.sectionWrapper=document.createElement("msft-edge-shopping-section"),this.sectionWrapper.titleText=this.flyoutData.strings.wishlistTitle,this.sectionWrapper.isBlock=!0,YE.setCollectionContainerMetadata(this.sectionWrapper,this.flyoutData.strings.wishlistCollectionTitle),this.sectionWrapper.appendChild(this.collectionItemDataElement)}async addCollectionDataToDOMElements(e,t){const i=await YE.getCollectionItemData(this.logModule,e,t);i?(YE.setCollectionItemDataAttribute(this.collectionItemDataElement,i),setTimeout((()=>{YE.downloadCollectionPackage(this.utilities,this.flyoutData.common.shopping,this.logModule,this.handleCollectionPackageDownloadError,this.handleCollectionsRetrieved)}),0),new IntersectionObserver(this.handleSaveButtonIntersectionCallback).observe(this.saveButton)):this.hideSection()}updateClickoutUrl(){if(!this.settingModule||this.settingModule.linkHref!==YE.CollectionHomepageUrl)return;const e=YE.getShoppingWishlistCollectionUrl(this.flyoutData.strings.wishlistCollectionTitle);e&&this.settingModule&&(this.settingModule.linkHref=e)}updateSaveButtonInnerText(){this.saveButton.disabled=!1;const e=window.SvCtrlV2?.localSavedItemsMap;e&&this.flyoutData.common.extractedEntity&&YE.GenerateContentIdForEntity(this.flyoutData.common.extractedEntity).then((t=>{const i=this.flyoutData.common.extractedEntity?.title;t&&i&&(e[t]?(this.saveButton.innerText=this.flyoutData.strings.wishlistUnsave,this.saveButton.ariaLabel=(0,T.fZ)("shoppingWishlistUnsaveButtonAltText",this.flyoutData.strings.wishlistUnsaveAltText,i)):(this.saveButton.innerText=this.flyoutData.strings.commonSaveSimple,this.saveButton.ariaLabel=(0,T.fZ)("shoppingWishlistSaveButtonAltText",this.flyoutData.strings.wishlistSaveAltText,i)))}))}},SI=class{getStyles(){return`\n #divContentWrapper {\n width: 100vw!important;\n position: fixed;\n height:100vh !important;\n display: flex;\n flex-direction: column;\n }\n #divContentWrapperStorybook {\n width: 330px!important;\n height: auto;\n }\n #divContentCashbackWrapperStorybook {\n width: 385px;\n height: auto;\n box-shadow: inset 0px 0px 0px 10px #969696;\n outline: 20px solid #d9dbda;\n }\n #shoppingTab, #searchShopping {\n overflow: auto;\n flex-grow: 1;\n }\n ::part(tablist) {\n place-self: flex-start;\n margin-left: 4px;\n }\n ::part(header-fixed) {\n display: none;\n }\n msft-edge-shopping::part(start-content) {\n margin-top: 0px!important;\n }\n ::part(actions) {\n display: flex;\n justify-content: center;\n width: 100%;\n padding-left: 0px;\n padding-right: 0px;\n }\n ::part(sections) {\n margin-top: 0px;\n }\n .btnPrimary, .btnPrimaryColor {\n min-width: 280px;\n width: calc(100% - 20px)!important;\n }\n .lateralMargin {\n width: calc(100% - 40px)!important;\n margin: auto;\n }\n .actionBlock .btnPrimary, .btnPrimaryColor {\n width: calc(100% - 32px)!important;\n }\n [slot="actions"] .btnPrimary, .btnPrimaryColor {\n width: calc(100% - 12px)!important;\n }\n\n msft-edge-shopping {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n max-height: unset!important;\n }\n msft-edge-shopping::part(header) {\n margin: 0px!important;\n text-align: left;\n }\n msft-edge-shopping-section::part(title) {\n font-size: 18px;\n line-height: 24px;\n font-weight: 600;\n }\n .accordionPadding::part(title) {\n padding: 0 calc(var(--design-unit) * 5 * 1px);\n margin: 0px;\n display: flex;\n }\n .headerBlock.no-padding-header::part(header) {\n padding: 0;\n }\n fluent-tab-panel {\n padding: 0px;\n }\n fluent-design-system-provider {\n width: 100vw!important;\n }\n fluent-tabs {\n -webkit-user-select: none;\n -webkit-touch-callout: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n background-color: #F3F3F3;\n }\n fluent-tabs::part(tablist) {\n row-gap: 5px;\n display: grid;\n grid-template-columns: auto auto 1fr auto;\n width: -webkit-fill-available;\n }\n #shoppingTab {\n background-color: #FEFEFE;\n }\n .valentines {\n background: url(https://www.bing.com/api/shopping/v1/ux/images/momentInTime/valentinesRepeatBG.svg) repeat fixed -20px -30px!important;\n }\n .valentines msft-edge-shopping::part(content) {\n background-color: transparent!important;\n }\n .valentinesCanary {\n background: url(https://www.staging-bing-int.com/api/shopping/v1/ux/images/momentInTime/valentinesRepeatBG.svg) repeat fixed -20px -30px!important;\n }\n .valentinesCanary msft-edge-shopping::part(content) {\n background-color: transparent!important;\n }\n fluent-tab {\n padding: 0px;\n margin: 16px 8px 0px;\n height: 22px;\n display: block;\n }\n .paneTabText {\n font-style: normal;\n font-weight: inherit;\n font-size: 14px;\n line-height: 20px;\n color: inherit;\n margin: 0;\n }\n msft-edge-shopping::part(content) {\n height: 100%;\n background-color: #F3F3F3;\n }\n msft-edge-shopping:not(#settingsPane)::part(content) {\n overflow: hidden;\n }\n ::part(activeIndicator) {\n width: -webkit-fill-available;\n height: 2px;\n margin: 4px 8px 0px;\n }\n .tabIconActive path {\n fill: #417AFF;\n }\n .tabSeparator {\n width: 100%;\n justify-content: flex-end;\n border: 1px solid #F1F1F1;\n margin-bottom: 0px;\n margin-top: 0px;\n border-bottom: unset;\n left: 0px;\n right: 0px;\n }\n .sectionSeparator {\n width: 100vw!important;\n box-sizing: border-box;\n }\n #divMainHeader {\n height: 56px;\n padding-left: 20px;\n padding-right: 10px;\n display: grid;\n grid-template-columns: auto auto;\n align-items: center;\n border-bottom: 1px solid #DDDDDD;\n align-content: center;\n background-color: white;\n flex: none;\n }\n #divActions {\n display: flex;\n flex-direction: row;\n justify-content: flex-end;\n align-items: center;\n }\n .previousSection #previousCashBackSection {\n margin-left: 0px!important;\n margin-right: 0px!important;\n }\n .previousSection #divCashBackPopup {\n margin-top: 4px;\n }\n .regionBlock {\n margin: 0 20px 20px 20px;\n background-color: var(--fill-color);\n box-sizing: border-box;\n border-radius: 8px;\n }\n .headerBlock::part(header) {\n margin: 10px 16px 10px 16px!important;\n background-color: var(--fill-color)!important;\n box-sizing: border-box;\n border-radius: 8px;\n padding: 10px;\n }\n .blockLateralMargin {\n width: calc(100% - 12px)!important;\n }\n .headerBlockSeeMore::part(header) {\n margin: 10px 20px 10px 20px!important;\n box-sizing: border-box;\n }\n .noPaddingBlock::part(header) {\n padding: 0px!important;\n }\n #${r.Hp.MyShopping}, #${r.Hp.CouponsSavings}, #${r.Hp.Explore} {\n height: fit-content !important;\n }\n #${r.d$.MyShopping}, #${r.d$.CouponsSavings}, #${r.d$.Explore} {\n display: flex;\n flex-direction: column;\n }\n #searchBoxWrapper {\n flex-direction: column;\n z-index: 1000;\n position: relative;\n }\n #searchDiv {\n display: flex;\n flex-direction: row;\n padding: 0px 20px 10px 10px;\n border-bottom: 1px solid #DDDDDD;\n background-color: white;\n }\n #searchBox::part(root) {\n display: flex;\n width: 282px;\n height: 32px;\n background: #FFFFFF;\n border-radius: 99px;\n box-shadow: none;\n border: 1px solid #D6D6D6;\n padding-left: 2px;\n }\n #searchBox[resultsVisible=true]::part(root) {\n border-radius: 8px 8px 0px 0px;\n }\n #searchBox::part(control) {\n padding: 2px 20px 3px 15px;\n }\n #dismissBtn {\n min-width: auto;\n height: auto;\n background: none;\n }\n #dismissBtn::part(control) {\n padding: 0px;\n border: none;\n }\n #searchResultsMenu {\n position: absolute;\n width: 100%;\n box-sizing: border-box;\n padding: 0px 0px 8px;\n box-shadow: none;\n border: 1px solid #D6D6D6;\n border-top: none;\n border-radius: 0px 0px 8px 8px;\n background: #FFFFFF;\n }\n .searchMenuItem {\n border: none;\n margin: 0px;\n tabindex: 0 !important;\n }\n #noResultsDiv {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n padding: 20px 20px;\n }\n #noResultsMsg {\n font-size: 16px;\n font-weight: 400;\n line-height: 21px;\n text-align: center;\n }\n `}getDarkModeStyles(){return"\n msft-edge-shopping::part(header) {\n background-color: unset!important;\n }\n #searchDiv, #divMainHeader {\n border-bottom: 1px solid #DDDDDD4a;\n }\n fluent-tabs, msft-edge-shopping::part(content), #searchDiv, #divMainHeader {\n background-color: #3B3B3B;\n }\n #shoppingTab {\n background-color: #3B3B3B;\n }\n ::part(activeIndicator) {\n background-color: #63ADE5;\n }\n .regionBlock, .headerBlock::part(header){\n background-color: #424242!important;\n }\n #searchBox::part(root), #searchResultsMenu {\n background: #2B2B2B;\n border-color: transparent;\n }\n #searchBox::part(control)::placeholder {\n color: #9AA0A6;\n }\n "}getDiscoverPaneStyles(){return"\n #divContentWrapper {\n width: 100vw !important;\n height: fit-content !important;\n overflow: auto;\n position: relative;\n }\n fluent-design-system-provider {\n max-width: 100vw !important;\n }\n .sectionSeparator {\n max-width: 100vw !important;\n }\n ::part(activeIndicator) {\n display: none;\n }\n msft-edge-shopping-section {\n background-color: transparent !important;\n }\n ::part(sections) {\n margin: 0;\n }\n fluent-tabs, fluent-design-system-provider, msft-edge-shopping::part(content), #shoppingTab, #searchDiv, #divMainHeader {\n background-color: transparent !important;\n }\n "}getDiscoverBackgroundStyles(){return"\n .spContent, fluent-tabs, fluent-design-system-provider, msft-edge-shopping::part(content), #shoppingTab, #searchDiv, #divMainHeader {\n background-color: #fafafa;\n }\n "}getDiscoverBackgroundDarkModeStyles(){return"\n .spContent, fluent-tabs, fluent-design-system-provider, msft-edge-shopping::part(content), #shoppingTab, #searchDiv, #divMainHeader {\n background-color: #2e2e2e; // #414141;\n }\n "}getSettingsPaneStyles(){return"\n .settingsTitleContainer {\n padding-inline: 16px;\n padding-block-start: 16px;\n margin-block-start: 0;\n margin-block-end: 0;\n }\n .settingsTitle {\n text-transform: capitalize;\n font-weight: 600;\n font-size: 1.4em;\n margin-block-start: 0;\n margin-block-end: 0;\n }\n .settingsTitleDesc {\n margin-block-start: 1em !important;\n }\n .settingsSectionHeader {\n margin-left: 8px;\n text-transform: capitalize;\n font-weight: 600;\n padding: 8px;\n margin-block-start: 0;\n margin-block-end: 0;\n font-size: 1.15em;\n }\n .settingsSectionContainer {\n display: flex;\n flex-direction: column;\n width: 320px;\n border-radius: 8px;\n padding: 12px;\n margin-left: 12px;\n margin-bottom: 4px;\n background: var(--neutral-fill-active);\n box-shadow: 0px 1px 2px rgba(0, 0, 0, 0.14);\n }\n .settingsSingleFeatureContainer {\n display : flex;\n flex-direction : row;\n justify-content : space-between;\n margin-bottom : 8px;\n }\n .settingsSingleFeatureTextContainer {\n display : flex;\n flex-direction : column;\n width : 256px;\n }\n .settingsSingleFeatureLabel {\n font-size : 1.0em;\n font-weight : 600;\n text-transform: capitalize;\n padding-top: 4px;\n padding-bottom: 4px;\n margin-block-start: 0;\n margin-block-end: 0;\n }\n .settingsSingleFeatureDesc {\n font-size : 0.9em;\n color: var(--text-neutral-foreground-hint);\n margin-block-start: 0;\n margin-block-end: 0;\n }\n .settingSwitchContainer {\n height : 20px;\n padding: 8px;\n }\n "}},xI=class{constructor(e,t=!1){(0,s.Z)(this,"time",void 0),(0,s.Z)(this,"shouldRender",void 0),this.time=e,this.shouldRender=t}},TI=o(21908);let wI=function(e){return e.dollars="$5",e.points="5,000 pts",e}({});var OI=o(57549),PI=class{constructor(e,t,i,n){this.flyoutData=e,this.stateManagement=t,this.utilities=i,this.moduleName=n,(0,s.Z)(this,"cashbackEstimation",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),this.telemetryUtilities=i.telemetryHandler}getInfoIcon(e,t){const i=(0,Y.Ux)("DIV");return e===r.J_.COLUMN_COMPOSITE_NOTIFICATION||t?(i.appendChild(this.getCashbackTooltip()),i.style.marginLeft="-5px"):i.style.display="none",i}async isDataReady(){const e=new wg(this.flyoutData,this.stateManagement,this.utilities.storageHandler,this.utilities.logModule,this.utilities.pageHandlerModule,this.utilities.viewModulesUtilities,this.telemetryUtilities,r.ModuleNames.CASHBACK,!0);return!!await e.shouldRenderNotification()&&(this.cashbackEstimation=await e.getEstimatedCashbackData(),!0)}onComponentClick(){(0,h.Xo)(tt.uv,r.ModuleNames.CASHBACK);const e=new W.Z(i.$S.RebatesViewInPane,this.telemetryUtilities.setContentViewed(this.moduleName));e.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.utilities.logModule.LogInfoEvent(i.R.ButtonClick,"User navigated to pane to view rebates",e,Jl.g.CouponImpressionId),this.utilities.pageHandlerModule.RecordAsUserAction(K.bS.REBATES_VIEW_IN_PANE),this.utilities.pageHandlerModule.RecordAsUserEngagement(q.FV.REBATES_VIEW_IN_PANE,this.flyoutData.common.popupOrigination)}getGraphicsElement(e,t){return e===r.J_.COLUMN_COMPOSITE_NOTIFICATION||t?this.getColumnGraphicsElement():this.getRowGraphicsElement()}getTextBesideIcon(){return""}getTextContent(e){switch(e){case r.J_.ROW_COMPOSITE_NOTIFICATION:return this.cashbackEstimation?this.flyoutData.strings.estimatedCashbackComponentCompositeNotificationTitlePart1+"\n"+(0,T.fm)(this.flyoutData.strings.cbFeatureName):this.flyoutData.strings.cashbackUpToComponentCompositeNotificationTitle;case r.J_.COLUMN_COMPOSITE_NOTIFICATION:const e=this.flyoutData.dataStoreModule.CashBackData?.merchantName??"";return(0,T.fZ)("",this.flyoutData.strings.lpPlusCbPlusCouponsCompositeNotificationCashbackTitle,this.getCashbackValue(),e)}}isCashbackEstimationAvailable(){return!!this.cashbackEstimation}getRowTitleWrapper(){const e=(0,Y.Ux)("DIV"),t=(0,Y.Ux)("SPAN");return t.className="savingsSpan",t.textContent=this.getCashbackValue(),(0,T.B7)(e,this.flyoutData.strings.v2CompositeNotificationCashbackTitle,t),e}getSavings(){return this.flyoutData.dataStoreModule.CashBackData?.highestCashBackCategory?.commissionValue&&"%"===this.flyoutData.dataStoreModule.CashBackData?.highestCashBackCategory?.commissionType?this.flyoutData.dataStoreModule.CashBackData?.highestCashBackCategory?.commissionValue:0}getTitleAriaLabel(){return this.getRowTitleWrapper().textContent??""}getRowGraphicsElement(){const e=this.getCashbackValue(),t=Pp(`${e}`,"font-size: 16px !important;",!1,24),i=this.getCashbackTooltip();i.classList.add("tooltip-cashback");const n=(0,Y.Ux)("div");return n.classList.add("tooltip-cashback-container"),n.appendChild(t),n.appendChild(i),n.ariaLabel=e,n}getColumnGraphicsElement(){const e=(0,Y.Ux)("div");e.classList.add("columnCompositeNotificationCbGraphicsWrapper"),e.classList.add("componentGraphic");const t=Ep(this.flyoutData.common.resourcesEndpoint+"common/cashbackTag.svg",16,16);return t.ariaHidden="true",e.appendChild(t),e}getCashbackValue(){let e="";if(this.cashbackEstimation){const t=(0,T.uf)(this.flyoutData.dataStoreModule.ApiData?.market,this.flyoutData.dataStoreModule.ApiData?.retailerData?.exclusiveMarket);e=(0,ne.N6)(t)+this.cashbackEstimation.cashbackValue}else this.flyoutData.dataStoreModule.CashBackData?.highestCashBackCategory?.commissionValue&&(e=this.flyoutData.dataStoreModule.CashBackData?.highestCashBackCategory?.commissionValue+this.flyoutData.dataStoreModule.CashBackData?.highestCashBackCategory?.commissionType);return e}getCashbackTooltip(){const e=this.utilities.tooltipUtilities.createCashbackTooltip(this.utilities.pageHandlerModule,this.utilities.logModule),t=(0,Y.Ux)("div");return t.appendChild(e),t}};function AI(e){let t;return e.dataStoreModule.ProductBestCouponData?.coupon&&(t=e.dataStoreModule.ProductBestCouponData),t}var EI=class{constructor(e,t,i,n){this.moduleName=n,(0,s.Z)(this,"savings",void 0),(0,s.Z)(this,"renderChecker",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"numCoupons",0),(0,s.Z)(this,"shouldShowNumberOfCoupons",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"viewModuleUtilities",void 0),this.flyoutData=e,this.shouldShowNumberOfCoupons=t,this.logModule=i.logModule,this.pageHandlerModule=i.pageHandlerModule,this.telemetryUtilities=i.telemetryHandler,this.renderChecker=new oy(this.flyoutData),this.savings=this.getSavings(),this.viewModuleUtilities=i.viewModulesUtilities}getInfoIcon(){const e=(0,Y.Ux)("DIV");return e.style.display="none",e}async isDataReady(){const e=this.renderChecker.shouldRender();return e&&(this.numCoupons=this.renderChecker.numCoupons),e}onComponentClick(){(0,h.Xo)(tt.uv,r.ModuleNames.COUPON);const e=new W.Z(i.$S.SeeMoreCoupons,this.telemetryUtilities.setContentViewed(this.moduleName));e.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.logModule.LogInfoEvent(i.R.ButtonClick,"Click on coupons components in composite notification",e),this.pageHandlerModule.RecordAsUserAction(K.bS.VIEW_MORE_COUPONS),this.pageHandlerModule.RecordAsUserEngagement(q.FV.VIEW_COUPONS_FROM_NOTIFICATION,this.flyoutData.common.popupOrigination)}getGraphicsElement(e,t){let i=22;(e===r.J_.COLUMN_COMPOSITE_NOTIFICATION||t)&&(i=16);const n=Ep(this.flyoutData.common.resourcesEndpoint+"common/couponDiagonal.svg",i,i);return(e===r.J_.COLUMN_COMPOSITE_NOTIFICATION||t)&&(n.className="componentGraphic"),n.ariaHidden="true",n}getTextContent(e){if(e===r.J_.COLUMN_COMPOSITE_NOTIFICATION){const e=this.savings;if(e>0)return(0,T.fZ)("Up to x% off with coupons",this.flyoutData.strings.lpPlusCbPlusCouponsCompositeNotificationCouponsTitle,e.toString())}return this.shouldShowNumberOfCoupons?this.numCoupons+" "+this.flyoutData.strings.couponsComponentCompositeNotificationTitle:this.flyoutData.strings.couponsComponentCompositeNotificationTitle}setShouldShowNumberOfCoupons(e){this.shouldShowNumberOfCoupons=e}getCouponsSuccessRate(){const e=this.flyoutData.dataStoreModule.ApiData?.retailerData?.retailerTrivia?.SuccessRate;return e&&e>=50?this.flyoutData.strings.v2CompositeNotificationHighCouponSuccessRate:""}getRowTitleWrapper(e){const t=(0,Y.Ux)("DIV"),i=this.getMainTitleWrapper();t.append(i);const n=this.getBestCouponWrapper(e);if(n)t.appendChild(n);else{const e=this.getCouponsSuccessRateWrapper();e&&(e.id="successRateWrapper",t.appendChild(e),t.setAttribute("aria-describedby","successRateWrapper"))}return t}getSavings(){if(this.savings&&-1!==this.savings)return this.savings;this.savings=this.renderChecker.getInstantSavingsPercentage();const e=AI(this.flyoutData);return e&&(this.savings=e.coupon.discountPercent),this.savings}getTitleAriaLabel(){return this.getMainTitleWrapper().textContent??""}getMainTitleWrapper(){const e=(0,Y.Ux)("DIV");if(this.savings>0){const t=(0,Y.Ux)("SPAN");t.className="savingsSpan",t.textContent=`${this.savings}%`,(0,T.B7)(e,this.flyoutData.strings.lpPlusCbPlusCouponsCompositeNotificationCouponsTitleV2,t)}else e.textContent=this.getTextContent(r.J_.COLUMN_COMPOSITE_NOTIFICATION);return e}getBestCouponWrapper(e){const t=AI(this.flyoutData);if(!t)return;const i=(0,Y.Ux)("DIV");i.className="bestCouponSubTitle";const n=(0,Y.zM)(t,this.viewModuleUtilities.commonAssets,this.flyoutData.strings.bestCouponAriaLabel,this.flyoutData.strings.bestCouponCopiedAriaLabel,e,this.telemetryUtilities,this.pageHandlerModule,this.logModule);return i.appendChild(n),i}getCouponsSuccessRateWrapper(){const e=this.getCouponsSuccessRate();if(""===e)return;const t=(0,Y.Ux)("DIV");return t.className="successRateSubTitle",t.textContent=e,t}},kI=class{constructor(t,i){(0,s.Z)(this,"isCompositeNotificationV2",!1),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"title",void 0),(0,s.Z)(this,"divWrapper",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"shouldHaveAnimation",!1),this.utilities=i.viewModulesUtilities,this.storageHandler=i.storageHandler,this.assets=new class{getHighContrastStyles(){return"\n @media (-ms-high-contrast: active) {\n .compositeNotificationBodyContainer {\n border: solid 1px Highlight;\n }\n .compositeNotificationBodyContainer:hover {\n background: HighlightText;\n forced-color-adjust: none;\n }\n .arrowIcon {\n filter: brightness(2.5) hue-rotate(30deg);\n }\n #priceHistoryTextId {\n color: Highlight;\n }\n .savingsHeaderSpan {\n color: Highlight;\n }\n .savingsSpan {\n color: Highlight;\n }\n }\n "}getStyles(){return`\n .savingsHeaderSpan {\n font-size: 20px;\n line-height: 28px;\n font-weight: 600;\n color: #0F754B;\n }\n .bestCouponSubTitle {\n margin-top: 5px;\n }\n .successRateSubTitle {\n font-weight: 400;\n font-size: 12px;\n line-height: 16px;\n color: #7A7A7A;\n }\n .componentGraphic {\n display: flex;\n align-self: flex-start;\n margin-top: 2px;\n }\n .fullPhGraphWrapper {\n display: flex;\n padding: 5px 0px;\n flex-direction:row;\n gap: 5px;\n }\n .oldPrice {\n align-self: flex-start;\n text-decoration: line-through;\n color: #616161;\n }\n .currentPrice {\n align-self: flex-end;\n color: #000000DB;\n }\n .priceDropDot {\n display: flex;\n }\n .priceDropDotLeft {\n display: flex;\n align-self: flex-start;\n margin-top: -1px;\n }\n .priceDropDotRight {\n display: flex;\n align-self: flex-end;\n margin-left: -2px;\n margin-bottom: -1px;\n }\n .savingsSpan {\n font-weight: 600;\n font-size: 12px;\n line-height: 16px;\n color: #0F754B;\n }\n .adSlugWrapper {\n display: flex;\n padding: 1px 4px;\n align-items: center;\n gap: 10px;\n border-radius: 4px;\n border: 1px solid var(--app-layers-neutral-layer-4, #E0E0E0);\n color: var(--neutral-foreground-neutral-foreground-rest, #1A1A1A);\n text-align: center;\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-size: 10px;\n font-style: normal;\n font-weight: 400;\n line-height: 14px;\n }\n #divPrivacyMessage.smallStyles {\n margin-left: 0px !important;\n margin-right: 0px !important;\n text-align: left !important;\n }\n #compositeNotificationHeader {\n font-style: normal;\n font-weight: 600;\n font-size: 20px;\n line-height: 28px;\n margin: 0px;\n text-align: center;\n margin-bottom: 0px;\n z-index: 2;\n }\n #compositeNotificationRowSectionWrapper {\n display: flex;\n gap: 12px;\n justify-content: space-between;\n padding: 12px 1px;\n }\n #compositeNotificationColumnSectionWrapper {\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n gap: 4px;\n margin-top: 8px;\n margin-bottom: 12px;\n }\n .compositeNotificationBodyContainer {\n display: flex;\n background: #F5F5F5;\n border-radius: 8px;\n cursor: pointer;\n font-weight: 600;\n line-height: 16px;\n box-sizing: border-box;\n font-size: 12px;\n align-items: center;\n }\n .compositeNotificationComponentsColumnContainer {\n flex-direction: column;\n gap: 6px;\n width: 100%;\n min-height: 72px;\n align-items: center;\n justify-content: center;\n padding: 10px 12px;\n text-align: center;\n }\n .compositeNotificationComponentsColumnContainer:first-child:hover {\n z-index: 3;\n }\n .compositeNotificationComponentsRowContainer {\n display: flex;\n flex-direction: row;\n gap: 8px;\n width: 248px;\n min-height: 40px;\n padding: 10px 12px;\n text-align: left;\n }\n .columnCompositeNotificationCbGraphicsWrapper {\n display: flex;\n flex-direction: row;\n }\n .bounceInTop {\n animation: bounce-in-top 0.75s both;\n animation-delay: 0.575s;\n }\n .bounceInTop:nth-child(2) {\n animation: bounce-in-top 0.75s both;\n animation-delay: 1.025s;\n }\n .compositeNotificationBodyContainer:hover {\n background: #EDEDED;\n }\n .compositeNotificationBodyContainer:focus-visible {\n outline: calc(var(--stroke-width) * 1px) solid var(--focus-stroke-outer);\n }\n .compositeNotificationButton {\n margin-bottom: 4px;\n height: 32px;\n }\n #priceHistoryGraphicsElementContainer {\n display: flex;\n flex-direction: row;\n align-items: center;\n padding: 0px;\n gap: 6px;\n }\n #priceHistoryTextId {\n color: #138757;\n font-size: 20px;\n }\n .animatedHeader {\n display: flex;\n flex-direction: row;\n flex-wrap: wrap;\n justify-content: center;\n overflow: hidden;\n }\n .animatedWord {\n position: relative;\n transform: translateY(100%);\n opacity: 0;\n animation: slide-up 0.25s forwards;\n }\n .tooltip-cashback {\n position: absolute;\n right: -10px;\n top: 0px;\n }\n .tooltip-cashback-container {\n position: relative;\n }\n .animatedWord:nth-child(1) {\n animation-delay: 0.25s;\n }\n .animatedWord:nth-child(2) {\n animation-delay: 0.325s;\n }\n .animatedWord:nth-child(3) {\n animation-delay: 0.5s;\n }\n .animatedWord:nth-child(4) {\n animation-delay: 0.625s;\n }\n .animatedWord:nth-child(5) {\n animation-delay: 0.75s;\n }\n .animatedWord:nth-child(6) {\n animation-delay: 0.825s;\n }\n .animatedWord:nth-child(7) {\n animation-delay: 0.9s;\n }\n .animatedWord:nth-child(8) {\n animation-delay: 0.1025s;\n }\n .fadeIn {\n opacity: 0;\n animation: fade-in 0.6s cubic-bezier(0.390, 0.575, 0.565, 1.000) both;\n }\n .fadeInPrimaryButton {\n animation-delay: 1.75s;\n }\n .footerZIndex {\n z-index: 2;\n }\n .footerDelay {\n animation-delay: 1.875s;\n }\n @keyframes fade-in {\n 0% {\n opacity: 0;\n }\n 100% {\n opacity: 1;\n }\n }\n @keyframes slide-up {\n 0% {\n transform: translateY(100%);\n opacity: 0;\n }\n 100% {\n transform: translateY(-0%);\n opacity: 1;\n }\n }\n @keyframes bounce-in-top {\n 0% {\n transform: translateY(-100%);\n animation-timing-function: ease-in;\n opacity: 0;\n }\n 38% {\n transform: translateY(0);\n animation-timing-function: ease-out;\n opacity: 1;\n }\n 55% {\n transform: translateY(-40%);\n animation-timing-function: ease-in;\n }\n 72% {\n transform: translateY(0);\n animation-timing-function: ease-out;\n }\n 81% {\n transform: translateY(-10%);\n animation-timing-function: ease-in;\n }\n 90% {\n transform: translateY(0);\n animation-timing-function: ease-out;\n }\n 95% {\n transform: translateY(-5%);\n animation-timing-function: ease-in;\n }\n 100% {\n transform: translateY(0);\n animation-timing-function: ease-out;\n }\n }\n ${this.getHighContrastStyles()}\n `}getDarkModeStyles(){return`\n .compositeNotificationBodyContainer {\n background: #1F1F1F;\n }\n .compositeNotificationBodyContainer:hover {\n background: #282828;\n }\n .adSlugWrapper {\n border: 1px solid var(--dark-stroke-stroke-2, #525252);\n color: var(--dark-foreground-foreground-2, #D6D6D6);\n }\n .savingsHeaderSpan {\n color: #23C481;\n }\n .savingsSpan {\n color: #23C481;\n }\n .currentPrice {\n color: #FFFFFF;\n }\n .oldPrice {\n color: #ADADAD;\n }\n .successRateSubTitle {\n color: #D6D6D6;\n }\n #priceHistoryTextId {\n color: #44D498;\n }\n .arrowIcon {\n filter: brightness(1.53);\n }\n ${this.getHighContrastStyles()}\n `}},this.pageHandlerModule=i.pageHandlerModule,this.logModule=i.logModule,this.telemetryUtilities=i.telemetryHandler,this.flyoutData=t,this.shouldHaveAnimation=!1,this.getExperimentNames().some((t=>e.R?.getServiceExperimentValue(t)===Yu.AS.WithAnimation))&&(this.shouldHaveAnimation=!0);const n=this.getV2ExperimentName();n&&e.R.isExperimentActive(n)&&(this.isCompositeNotificationV2=!0)}GetPopupOriginationList(){return[this.getPopupOrigination()]}RenderNotification(){return Promise.resolve(this.createUx())}async ShouldRenderNotification(){const{popupOrigination:e}=this.flyoutData.common;if(e!==this.getPopupOrigination()||this.flyoutData.common.openedWith!==r.Te.Auto)return Promise.resolve(!1);const t=this.getChildrenComponents();for(const e of t)if(!await e.isDataReady())return Promise.resolve(!1);return Promise.resolve(!0)}GetNotificationName(){return this.getChildNotificationName()}createUx(){const e=(0,Y.Ux)("div");e.slot="header-content",this.flyoutData.common.shopping.classList.add("noSections"),e.className="lateralMargin",this.utilities.applyStyles(e,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());const t=(0,Y.Ux)("h2");t.id="compositeNotificationHeader",t.slot="description";const i=this.getHeader();t.appendChild(i),e.appendChild(t);const n=this.createChildComponentsUX();e.appendChild(n);const o=this.createPrimaryButtonUX();return e.appendChild(o),this.shouldHaveAnimation&&this.animateButton(o),this.utilities.createNotificationModule(e,this.GetNotificationName(),this)}createPrimaryButtonUX(){const e=(0,Y.lw)(this.utilities);return e.classList.add("compositeNotificationButton"),e.textContent=this.getButtonText(),e.addEventListener("click",(()=>this.onCTAButtonClick())),e}openPane(){const{popupOrigination:e}=this.flyoutData.common;this.pageHandlerModule.OpenPane(e)}getV2ExperimentName(){return null}getTotalSavings(){let e=0;const t=this.getChildrenComponents();for(const i of t){const t=i.getSavings();t>0&&(e+=+t)}return e=Math.min(e,100),e}createChildComponentsUX(){const e=this.getChildrenComponents(),t=this.getSectionWrapper();for(const i in e)if(e[i]){const n=this.createOneChildComponentUX(e[i]);t.appendChild(n)}return t}createOneChildComponentUX(e){const t=this.getOneComponentBodyContainer();t.role="button",t.tabIndex=0,this.shouldHaveAnimation&&this.animateComponent(t);const i=this.getCompositeNotificationType(),n=e.getGraphicsElement(i,this.isCompositeNotificationV2),o=(0,Y.Ux)("div");if(this.isCompositeNotificationV2){t.appendChild(n);const i=e.getRowTitleWrapper(this.GetNotificationName());t.appendChild(i);const o=i.getAttribute("aria-describedby");o&&t.setAttribute("aria-describedby",o),t.setAttribute("aria-label",e.getTitleAriaLabel())}else{const r=e.getTextContent(i);o.innerText=r,this.isTextAboveGraphicsElement()?(t.appendChild(o),t.appendChild(n)):(t.appendChild(n),t.appendChild(o)),t.setAttribute("aria-label",r)}const r=e.getInfoIcon(i,this.isCompositeNotificationV2);t.appendChild(r);const a=()=>{e.onComponentClick(),this.openPane()};return t.addEventListener("click",a),t.addEventListener("keypress",(e=>{"Enter"===e.key&&a()})),t}},II=class extends kI{constructor(e,t){super(e,t)}PostProcessingNotification(e,t){}getCompositeNotificationType(){return r.J_.COLUMN_COMPOSITE_NOTIFICATION}getSectionWrapper(){const e=(0,Y.Ux)("div");return e.id="compositeNotificationColumnSectionWrapper",e}getOneComponentBodyContainer(){const e=(0,Y.Ux)("div");return e.classList.add("compositeNotificationBodyContainer"),e.classList.add("compositeNotificationComponentsRowContainer"),e}getHeader(){const e=(0,Y.Ux)("DIV");return this.shouldHaveAnimation,e.textContent=this.getTitle(),e}animateButton(e){}animateComponent(e){}},DI=class extends II{static getAssociatedFeaturesNames(e){return[e.strings.pcFeatureName,e.strings.cbFeatureName,e.strings.couponFeatureName]}constructor(e,t,n){super(e,t),(0,s.Z)(this,"couponsComponent",void 0),(0,s.Z)(this,"cashbackComponent",void 0),(0,s.Z)(this,"priceComparisonComponent",void 0),this.couponsComponent=new EI(this.flyoutData,!0,t,this.GetNotificationName()),this.cashbackComponent=new PI(this.flyoutData,n,t,this.GetNotificationName()),this.priceComparisonComponent=new class{constructor(e,t,i){(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"moduleName",void 0),(0,s.Z)(this,"priceComparisonUtilities",void 0),this.flyoutData=e,this.logModule=t.logModule,this.pageHandlerModule=t.pageHandlerModule,this.telemetryUtilities=t.telemetryHandler,this.utilities=t.viewModulesUtilities,this.moduleName=i,this.priceComparisonUtilities=new gS.Z(this.flyoutData.common.openedWith,this.flyoutData.dataStoreModule.PriceComparisonData?.CompetingPrices,this.flyoutData.dataStoreModule.PriceComparisonData?.Price,this.flyoutData.common.popupOrigination,this.flyoutData.common.pageLocale)}getInfoIcon(e){let t=(0,Y.Ux)("DIV");return e===r.J_.COLUMN_COMPOSITE_NOTIFICATION&&this.priceComparisonUtilities?.bestOffer?.BillingType===r.YO.Paid?t=this.getAdsSlug():t.style.display="none",t}async isDataReady(){const e=new xS(this.flyoutData);return await e.shouldRenderNotification(!0)&&!!this.priceComparisonUtilities.bestOffer}onComponentClick(){(0,h.Xo)(tt.uv,r.ModuleNames.PRICECOMPARISON);const e=new W.Z(i.$S.CompositeNotificationsPriceComparisonComponent,this.telemetryUtilities.setContentViewed(this.moduleName));e.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.logModule.LogInfoEvent(i.R.ButtonClick,"Click on price comparison components in composite notification",e),this.pageHandlerModule.RecordAsUserAction(K.bS.PRICE_COMPARISON_COMPONENT_CLICK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.VIEW_PRICE_COMPARISON_FROM_NOTIFICATION,this.flyoutData.common.popupOrigination)}getGraphicsElement(e,t){const i=(0,Y.Ux)("img",{style:"\n height: 16px;\n width: 16px;\n "});i.className="componentGraphic",i.setAttribute("aria-hidden","true");const n=this.priceComparisonUtilities.bestOffer?.Domain;return n&&this.utilities.setImageSrc(i,this.utilities.getFavIconSrc(n)),i}getTextContent(e){let t=this.getTitleWithoutLowestPrice();if(this.priceComparisonUtilities.bestOffer){const e=this.getLowerPriceText();t=(0,T.fZ)("Column Composite Notification Price Comparison Title",t,e)}return t}getRowTitleWrapper(){const e=(0,Y.Ux)("DIV"),t=this.getTitleWithoutLowestPrice(),i=(0,Y.Ux)("SPAN");return i.className="savingsSpan",i.textContent=this.getLowerPriceText(),(0,T.B7)(e,t,i),e}getSavings(){return 0}getTitleAriaLabel(){return this.getRowTitleWrapper().textContent??""}getAdsSlug(){const e=(0,Y.Ux)("DIV");return e.className="adSlugWrapper",e.textContent=this.flyoutData.strings.gcAd,e.setAttribute("aria-label",this.flyoutData.strings.gcAd),e}getTitleWithoutLowestPrice(){let e="";if(this.priceComparisonUtilities.bestOffer){const t=this.priceComparisonUtilities.bestOffer.SellerName??this.priceComparisonUtilities.bestOffer.Domain??"";e=(0,T.fZ)("Column Composite Notification Price Comparison Title",this.flyoutData.strings.lpPlusCbPlusCouponsCompositeNotificationPriceComparisonTitle,t)}return e}getLowerPriceText(){let e="";return this.priceComparisonUtilities.bestOffer&&(e=`${this.priceComparisonUtilities.bestOffer.CurrencySymbol??"$"}${this.utilities.formatPrice(this.priceComparisonUtilities.bestOffer.IntendedPrice,this.priceComparisonUtilities.bestOffer.PriceCurrency)}`),e}}(this.flyoutData,t,this.GetNotificationName())}getPopupOrigination(){return u.sR.AUTO_SHOW_LOWER_PRICE_PLUS_CASHBACK_PLUS_COUPONS}getTitle(){return this.flyoutData.strings.lowerPricePlusCashbackPlusCouponsCompositeNotificationTitle}getButtonText(){return this.flyoutData.strings.commonSeeMore}onCTAButtonClick(){(0,h.Xo)(tt.uv,r.ModuleNames.CASHBACK),this.logClickingToOpenCashback(),this.openPane()}getChildNotificationName(){return r.sM.LOWER_PRICE_PLUS_CASHBACK_PLUS_COUPONS_COMPOSITE}getChildrenComponents(){return[this.priceComparisonComponent,this.cashbackComponent,this.couponsComponent]}isTextAboveGraphicsElement(){return!1}getV2ExperimentName(){return f.H.lowerPricePdpPlusCashbackPlusCouponsV2}getExperimentNames(){return[f.H.lowerPricePdpPlusCashbackPlusCoupons,f.H.lowerPricePdpPlusCashbackPlusCouponsV2]}logClickingToOpenCashback(){const e=new W.Z(i.$S.lowePriceCashbackCouponsCompositeSeeMore,this.telemetryUtilities.setContentViewed(this.GetNotificationName()));this.pageHandlerModule.RecordAsUserAction(K.bS.REBATES_VIEW_IN_PANE),e.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.pageHandlerModule.RecordAsUserEngagement(q.FV.REBATES_VIEW_IN_PANE,this.flyoutData.common.popupOrigination),this.logModule.LogInfoEvent(i.R.ButtonClick,"Click on see more in PC, cashback and coupons composite Notification to see cashback",e)}},_I=class extends kI{constructor(e,t){super(e,t)}PostProcessingNotification(e,t){const i=document.getElementById("footerDiv");i&&i.classList.add("footerZIndex"),this.shouldHaveAnimation&&i&&(i.classList.add("fadeIn"),i.classList.add("footerDelay"))}getCompositeNotificationType(){return r.J_.ROW_COMPOSITE_NOTIFICATION}getSectionWrapper(){const e=(0,Y.Ux)("div");return this.isCompositeNotificationV2?e.id="compositeNotificationColumnSectionWrapper":e.id="compositeNotificationRowSectionWrapper",e}getOneComponentBodyContainer(){const e=(0,Y.Ux)("div");return e.classList.add("compositeNotificationBodyContainer"),this.isCompositeNotificationV2?e.classList.add("compositeNotificationComponentsRowContainer"):e.classList.add("compositeNotificationComponentsColumnContainer"),e}getHeader(){const e=(0,Y.Ux)("DIV"),t=this.getTotalSavings();if(this.isCompositeNotificationV2&&this.GetNotificationName()===r.sM.CASHBACK_PLUS_COUPONS_COMPOSITE&&t>0){const i=(0,Y.Ux)("SPAN");i.classList.add("savingsHeaderSpan"),i.textContent=`${t}%`,(0,T.B7)(e,this.getTitle(),i)}else if(this.shouldHaveAnimation){e.classList.add("animatedHeader");for(const t of this.getTitle().split(" ")){const i=(0,Y.Ux)("span");i.classList.add("animatedWord"),i.textContent=t+" ",e.appendChild(i)}}else e.textContent=this.getTitle();return e}animateButton(e){e.classList.add("fadeIn"),e.classList.add("fadeInPrimaryButton")}animateComponent(e){e.classList.add("bounceInTop")}},NI=class extends _I{static getAssociatedFeaturesNames(e){return[e.strings.cbFeatureName,e.strings.couponFeatureName]}constructor(e,t,i,n){super(e,t),this.stateManagement=i,this.commonAssets=n,(0,s.Z)(this,"couponsComponent",void 0),(0,s.Z)(this,"cashbackComponent",void 0),(0,s.Z)(this,"activateCashbackButtonCreator",void 0),this.couponsComponent=new EI(this.flyoutData,!1,t,this.GetNotificationName()),this.cashbackComponent=new PI(this.flyoutData,this.stateManagement,t,this.GetNotificationName()),this.activateCashbackButtonCreator=new ag(this.stateManagement,this.flyoutData,t,this.commonAssets,this.logModule,this.GetNotificationName(),void 0,this.flyoutData.strings.cashbackPlusCouponsCompositeNotificationBtnText)}createPrimaryButtonUX(){this.activateCashbackButtonCreator.addCashbackStyles();const e=this.activateCashbackButtonCreator.createActivateButton();return e.style.marginTop="0px",e}getPopupOrigination(){return u.sR.AUTO_SHOW_CASHBACK_PDP_PLUS_COUPONS}getTitle(){if(this.isCompositeNotificationV2){let e="";return e=this.flyoutData.dataStoreModule.CouponData?.FriendlyDomainName?this.flyoutData.dataStoreModule.CouponData.FriendlyDomainName:Jk(this.flyoutData.common.domain),(0,T.fZ)("x% savings at domain name",this.flyoutData.strings.v2CompositeNotificationCashbackCouponsTitle,e)}return this.flyoutData.strings.cashbackPlusCouponsCompositeNotificationTitle}getButtonText(){return this.flyoutData.strings.cashbackPlusCouponsCompositeNotificationBtnText}onCTAButtonClick(){}getChildNotificationName(){return r.sM.CASHBACK_PLUS_COUPONS_COMPOSITE}getChildrenComponents(){return[this.cashbackComponent,this.couponsComponent]}isTextAboveGraphicsElement(){return!this.cashbackComponent.isCashbackEstimationAvailable()||(this.couponsComponent.setShouldShowNumberOfCoupons(!0),!1)}getV2ExperimentName(){return f.H.cashbackPdpPlusCouponsNotificationV2}getExperimentNames(){return[f.H.cashbackPdpPlusCouponsNotification,f.H.cashbackPdpPlusCouponsNotificationV2]}},RI=class extends _I{static getAssociatedFeaturesNames(e){return[e.strings.phFeatureName,e.strings.cbFeatureName]}constructor(e,t,n,o){super(e,t),this.stateManagement=n,this.commonAssets=o,(0,s.Z)(this,"priceDropComponent",void 0),(0,s.Z)(this,"cashbackComponent",void 0),(0,s.Z)(this,"activateCashbackButtonCreator",void 0),this.priceDropComponent=new class{constructor(e,t,i,n){this.moduleName=n,(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"viewModulesUtilities",void 0),(0,s.Z)(this,"dataValidationUtilities",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"popupOrigination",void 0),(0,s.Z)(this,"priceHistoryData",void 0),this.flyoutData=e,this.logModule=t.logModule,this.viewModulesUtilities=t.viewModulesUtilities,this.dataValidationUtilities=t.dataValidationUtilities,this.pageHandlerModule=t.pageHandlerModule,this.telemetryUtilities=t.telemetryHandler,this.popupOrigination=i,this.priceHistoryData=this.flyoutData.dataStoreModule.PriceHistoryData}getRowTitleWrapper(){const e=(0,Y.Ux)("DIV");return e.appendChild(this.getMainTitleWrapper()),e.appendChild(this.getPriceDropGraphWithData()),e}getInfoIcon(){const e=(0,Y.Ux)("DIV");return e.style.display="none",e}async isDataReady(){const e=new fS(this.flyoutData).shouldRenderNotification(this.popupOrigination),t=this.flyoutData.dataStoreModule.PriceHistoryData;return e&&!!t&&!!t?.ProductDetails}onComponentClick(){(0,h.Xo)(tt.uv,r.ModuleNames.PRICEHISTORY);const e=new W.Z(i.$S.SeePHGraph,this.telemetryUtilities.setContentViewed(this.moduleName));e.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.logModule.LogInfoEvent(i.R.ButtonClick,"Click on PH Notification to see full graph",e),this.pageHandlerModule.RecordAsUserAction(K.bS.EXPAND_PRICE_HISTORY_GRAPH),this.pageHandlerModule.RecordAsUserEngagement(q.FV.EXPAND_GRAPH,this.flyoutData.common.popupOrigination)}getGraphicsElement(e,t){return e===r.J_.COLUMN_COMPOSITE_NOTIFICATION||t?this.getColumnGraphicsElement():this.getRowGraphicsElement()}getTextBesideIcon(){return this.flyoutData.strings.priceHistoryComponentCompositeNotificationTitle}getTextContent(e){return this.flyoutData.strings.priceHistoryComponentCompositeNotificationTitle}getSavings(){return 0}getTitleAriaLabel(){const e=(0,T.fZ)("old price",this.flyoutData.strings.v2CompositeNotificationPHOldPriceAriaLAbel,this.getOldPrice()),t=(0,T.fZ)("old price",this.flyoutData.strings.v2CompositeNotificationPHCurrentPriceAriaLAbel,this.getCurrentPrice());return this.getMainTitleWrapper().textContent?this.getMainTitleWrapper().textContent+`. ${e} ${t}`:""}getMainTitleWrapper(){const e=(0,Y.Ux)("DIV"),t=(0,Y.Ux)("SPAN");return t.className="savingsSpan",t.textContent=this.getPHSavingsPercentage(),(0,T.B7)(e,this.flyoutData.strings.v2CompositeNotificationPriceHistoryTitle,t),e}getPriceDropGraph(){const e=(0,Y.Ux)("DIV",{style:"display: flex; padding: 5px 0px;"}),t=Ep(this.flyoutData.common.resourcesEndpoint+"common/priceHistoryDotCompositeNotification.svg",6,6);t.ariaHidden="true",t.classList.add("priceDropDotLeft"),e.appendChild(t);const i=Ep(this.flyoutData.common.resourcesEndpoint+"common/priceHistoryDroppedGraphCompositeNotification.svg",23,95);i.ariaHidden="true",e.appendChild(i);const n=Ep(this.flyoutData.common.resourcesEndpoint+"common/priceHistoryDotCompositeNotification.svg",6,6);return n.ariaHidden="true",n.classList.add("priceDropDotRight"),e.appendChild(n),e}getPHSavingsPercentage(){return this.dataValidationUtilities.validatePriceWithEntityExtractionResults(this.flyoutData.common.extractedEntity,this.priceHistoryData.CurrentPrice.toString(),r.ModuleNames.PRICEHISTORY),`${this.viewModulesUtilities.toFixedSafe(Math.abs(this.priceHistoryData.DailyPriceDropPercentage),0)}%`}getColumnGraphicsElement(){const e=(0,Y.Ux)("DIV");e.className="componentGraphic";const t=Ep(this.flyoutData.common.resourcesEndpoint+"common/priceHistoryArrowDownCompositeNotification.svg",16,16);return t.ariaHidden="true",e.appendChild(t),e}getRowGraphicsElement(){const e=Ep(this.flyoutData.common.resourcesEndpoint+"common/greenArrowDown.svg",22,22);e.classList.add("arrowIcon"),e.ariaHidden="true";const t=document.createElement("div");t.id="priceHistoryGraphicsElementContainer",t.appendChild(e);const i=document.createElement("div");return i.id="priceHistoryTextId",i.textContent=this.getPHSavingsPercentage(),t.appendChild(i),t}getPriceDropGraphWithData(){const e=this.getCurrentPrice(),t=this.getOldPrice(),i=(0,Y.Ux)("DIV");i.className="fullPhGraphWrapper";const n=(0,Y.Ux)("span");n.className="oldPrice",n.textContent=t,i.appendChild(n);const o=this.getPriceDropGraph();i.appendChild(o);const r=(0,Y.Ux)("span");return r.className="currentPrice",r.textContent=e,i.appendChild(r),i}getOldPrice(){return`${this.priceHistoryData.ProductDetails.currency||"$"}${this.viewModulesUtilities.formatPrice(this.priceHistoryData.MedianPrice)}`}getCurrentPrice(){return`${this.priceHistoryData.ProductDetails.currency||"$"}${this.viewModulesUtilities.formatPrice(this.priceHistoryData.CurrentPrice)}`}}(this.flyoutData,t,this.getPopupOrigination(),this.GetNotificationName()),this.cashbackComponent=new PI(this.flyoutData,this.stateManagement,t,this.GetNotificationName()),this.activateCashbackButtonCreator=new ag(this.stateManagement,this.flyoutData,t,this.commonAssets,this.logModule,this.GetNotificationName(),void 0,this.flyoutData.strings.cashbackPlusCouponsCompositeNotificationBtnText,(()=>this.onCTAButtonClick()))}createPrimaryButtonUX(){this.activateCashbackButtonCreator.addCashbackStyles();const e=this.activateCashbackButtonCreator.createActivateButton();return e.style.marginTop="0px",e}getPopupOrigination(){return u.sR.AUTO_SHOW_PRICE_DROP_PLUS_CASHBACK}getTitle(){if(this.isCompositeNotificationV2){let e="";return e=this.flyoutData.dataStoreModule.CouponData?.FriendlyDomainName?this.flyoutData.dataStoreModule.CouponData.FriendlyDomainName:Jk(this.flyoutData.common.domain),(0,T.fZ)("Best deal at domain name",this.flyoutData.strings.v2CompositeNotificationPhPlusTitle,e)}return function(e){let t="";return t=e.dataStoreModule.CouponData?.FriendlyDomainName?e.dataStoreModule.CouponData.FriendlyDomainName:Jk(e.common.domain),(0,T.fZ)("Great deal at domain name",e.strings.priceDropPlusCouponsCompositeNotificationTitle,t)}(this.flyoutData)}getButtonText(){return""}onCTAButtonClick(){(0,h.Xo)(tt.uv,r.ModuleNames.PRICEHISTORY),this.openPane()}getChildNotificationName(){return r.sM.PRICE_DROP_PLUS_CASHBACK}getChildrenComponents(){return[this.cashbackComponent,this.priceDropComponent]}isTextAboveGraphicsElement(){return!this.cashbackComponent.isCashbackEstimationAvailable()}getV2ExperimentName(){return f.H.cashbackPdpPlusPriceDropNotificationV2}getExperimentNames(){return[f.H.cashbackPdpPlusPriceDropNotification,f.H.cashbackPdpPlusPriceDropNotificationV2]}};const MI=()=>[u.sR.AUTO_SHOW_CASHBACK_PDP_PLUS_COUPONS,u.sR.AUTO_SHOW_PRICE_DROP_PLUS_CASHBACK,u.sR.AUTO_SHOW_LOWER_PRICE_PLUS_CASHBACK_PLUS_COUPONS],LI=(e,t)=>{let i=[];switch(t){case u.sR.AUTO_SHOW_PRICE_DROP_PLUS_CASHBACK:i=RI.getAssociatedFeaturesNames(e);break;case u.sR.AUTO_SHOW_CASHBACK_PDP_PLUS_COUPONS:i=NI.getAssociatedFeaturesNames(e);break;case u.sR.AUTO_SHOW_LOWER_PRICE_PLUS_CASHBACK_PLUS_COUPONS:i=DI.getAssociatedFeaturesNames(e)}return i};var BI=class{constructor(e,t,i,n,o,r,a){(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"autoOpenControllerUtilities",void 0),(0,s.Z)(this,"parentMenu",void 0),this.flyoutData=e,this.utilities=t,this.stateManagement=n,this.pageHandlerModule=o,this.logModule=r,this.commonAssets=t.commonAssets,this.autoOpenControllerUtilities=i,this.parentMenu=a}commonMenuStyles(){let e,t;return this.flyoutData.common.currentDirection===r.m5.RTL?(e="35px",t="40px"):this.flyoutData.common.openedWith===r.Te.Auto?(e="0px",t="45px"):(e="50px",t="40px"),`position: absolute; top: ${t}; left:${e}; z-index: 10000; width:100%; max-width:280px !important; outline: none;\n padding: 0px 0px 10px 0px !important; max-height:calc(100% - 45px); overflow: hidden auto;`}getLineSeprator(){const e=(0,Y.Ux)("HR",{style:"border: 1px solid #F1F1F1;\n margin: 4px auto;\n border-bottom: unset;\n width: 80%;",ariaHidden:"true"});return this.utilities.isDarkMode()&&(e.style.borderColor="#706c6c"),e}getDescriptionText(){const e=(0,Y.Ux)("DIV",{style:"max-width: 80%;\n margin-left: 47px;\n display: flex;\n text-align: start;\n font-size: 11px;\n font-weight: 400;\n line-height: 16px;\n font-style: normal;\n color: #7A7A7A;",class:"defaultFontFamily"});return e.classList.add("defaultFontFamily"),this.utilities.isDarkMode()&&(e.style.color="#c5c5c5"),e}enableSwitchToggle(e,t){t?(e.setAttribute("current-checked","true"),e.classList.add("checked"),e.setAttribute("aria-checked","true")):(e.setAttribute("current-checked","false"),e.classList.remove("checked"),e.setAttribute("aria-checked","false"))}getBackgroundOverlay(){const e=document.createElement("DIV");return e.id="menu-background-overlay",e.style.position="fixed",e}},FI=class extends BI{constructor(...e){super(...e),(0,s.Z)(this,"manageNotificationMenu",void 0)}renderMenuModule(){this.manageNotificationMenu=(0,Y.Ux)("fluent-menu",{id:"manage-notification-menu",slot:"menu",style:this.commonMenuStyles(),tabeIndex:-1,className:"hide",ariaLabel:"Notification Settings"}),this.flyoutData.common.openedWith!==r.Te.Auto&&(this.manageNotificationMenu.style.maxHeight="25%"),this.flyoutData.common.isPane&&this.flyoutData.common.isSharedHeader&&(this.manageNotificationMenu.style.top="0px",this.manageNotificationMenu.style.left="55px",this.manageNotificationMenu.style.width="230px");const t=this.createManageNotificationMenuHeader(),i=this.getLineSeprator(),n=i.cloneNode(!0);n.style.width="100%",this.manageNotificationMenu.append(t),this.manageNotificationMenu.append(n);const o=this.getListOfPopupOrignationsWithFeatureNames();let a;[f.H.cashbackPdpPlusCouponsNotification,f.H.cashbackPdpPlusCouponsNotificationV2,f.H.cashbackPdpPlusPriceDropNotification,f.H.cashbackPdpPlusPriceDropNotificationV2,f.H.lowerPricePdpPlusCashbackPlusCoupons,f.H.lowerPricePdpPlusCashbackPlusCouponsV2].some((t=>e.R?.isExperimentActive(t)))&&this.checkIfAnyCompositeNotificationsShouldBeDisabledOnStartup(o);for(const[e,t]of o){if("Auto Apply Coupons"===e){a=[e,t];continue}const n=this.createManageNotificationMenuItem(e,t,o);this.manageNotificationMenu.append(n),this.manageNotificationMenu.append(i.cloneNode(!0))}if(a){const e=this.createManageNotificationMenuItem(a[0],a[1],o);this.manageNotificationMenu.append(e)}return this.manageNotificationMenu.addEventListener("click",(e=>{e.stopPropagation()})),this.manageNotificationMenu}createManageNotificationMenuHeader(){const e=(0,Y.Ux)("fluent-menu-item",{style:"\n font-weight: 600;\n text-align: center;\n margin-top: 7px;\n margin-bottom: 11px;\n "}),t=(0,Y.Ux)("DIV",{style:"\n align-self: center;\n flex-grow: 0.5;\n justify-content: center;\n background: transparent;\n display: flex;\n "});t.style.display="flex",t.slot="start",t.setAttribute("aria-hidden","true"),e.title=this.flyoutData.strings.commonManageNotifications,e.textContent=this.flyoutData.strings.commonManageNotifications,e.tabIndex=0,e.id="manage-notification-header",e.className+="defaultFontFamily",this.flyoutData.common.isPane&&this.flyoutData.common.isSharedHeader&&(e.style.fontSize="12px",e.style.margin="5px 0px"),t.innerHTML=this.commonAssets.getLeftArrowIcon(),e.appendChild(t);const i=e=>{const t=document.querySelector(`#${r.z6.MENU_CONTENT}`);t&&(t.classList.remove("hide"),this.manageNotificationMenu.classList.toggle("hide")),e.stopPropagation()};e.addEventListener("click",i),this.utilities.makeHtmlElementKeyboardClickable(e,(e=>{i(e);const t=this.parentMenu.querySelectorAll("fluent-menu-item");t?.length&&t[0].focus()})),e.addEventListener("keydown",(e=>{"ArrowDown"!==e.key&&"ArrowUp"!==e.key||e.preventDefault()}));const n=(0,Y.Ux)("DIV",{ariaLabel:"Manage Notifications Header"});return n.appendChild(e),n}createManageNotificationMenuItem(t,n,o){const r=(0,dt.g7)(n[0],this.flyoutData,this.autoOpenControllerUtilities,this.logModule),a=document.createElement("fluent-menu-item");a.title=t,a.textContent=t,a.classList.add("defaultFontFamily","notification-manage-item"),this.flyoutData.common.isPane&&this.flyoutData.common.isSharedHeader&&(a.style.fontSize="12px");const s=document.createElement("DIV");s.style.display="flex",s.slot="start",s.id="notification-icon",s.setAttribute("aria-hidden","true"),s.classList.add("notification-icon");const l=(0,Y.Ux)("fluent-switch");l.style.setProperty("--accent-fill-rest","unset");const c=(0,Y.Ux)("DIV",{style:"position: relative; height : 20px;",slot:"end"});c.appendChild(l),r?(s.innerHTML=this.commonAssets.getNotificationIcon(),this.enableSwitchToggle(l,!0)):s.innerHTML=this.commonAssets.getDisabledNotificationIcon();const d=async r=>{const s=a.querySelector(".notification-icon"),l=a.querySelector("fluent-switch");if("true"===l.getAttribute("current-checked")){this.enableSwitchToggle(l,!1),s&&(s.innerHTML=this.commonAssets.getDisabledNotificationIcon());const r=this.getToBeToggledCompositePopupOriginations(t,!1,o),a=[...n,...r],c=new W.Z(i.$S.AutoShowTurnedOff,bp.r.MENU);this.pageHandlerModule.RecordAsUserAction(K.bS.TURN_OFF_AUTO_SHOW);const d="Auto Show turned off - Toggle switch off";c.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination,toggledPopupOriginations:a,featureName:t}),this.logModule.LogInfoEvent(i.R.ButtonClick,d,c),e.R.isExperimentActive(f.H.autoOpenControllerScript)&&await this.autoOpenControllerUtilities.setUserPreferenceBatch(!1,a,this.flyoutData.common.disabledNotifications),this.pageHandlerModule.AutoShowForAllFeatures(!1,n)}else{this.enableSwitchToggle(l,!0),s&&(s.innerHTML=this.commonAssets.getNotificationIcon());const r=this.getToBeToggledCompositePopupOriginations(t,!0,o),a=[...n,...r],c=new W.Z(i.$S.AutoShowTurnedOn,bp.r.MENU);this.pageHandlerModule.RecordAsUserAction(K.bS.TURN_ON_AUTO_SHOW);const d="Auto Show turned on - Toggle switch on";c.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination,toggledPopupOriginations:a,featureName:t}),this.logModule.LogInfoEvent(i.R.ButtonClick,d,c),e.R.isExperimentActive(f.H.autoOpenControllerScript)&&await this.autoOpenControllerUtilities.setUserPreferenceBatch(!0,a,this.flyoutData.common.disabledNotifications),this.pageHandlerModule.AutoShowForAllFeatures(!0,n)}r.stopPropagation()};return a.addEventListener("click",d),this.utilities.makeHtmlElementKeyboardClickable(a,d),a.appendChild(s),a.appendChild(c.cloneNode(!0)),a}getListOfPopupOrignationsWithFeatureNames(){const e=new Map,t=Object.keys(u.sR).filter((e=>!isNaN(Number(e)))),i=(0,dt.fr)(),n=(0,dt.Uy)(),o=MI(),r=this.isAOCEnabled();for(const a of t){const t=parseInt(a,10);if(t>=63&&!r)continue;if(i.includes(t)||n.includes(t)||o.includes(t))continue;if(t===u.sR.AA_CONSENT)continue;const s=(0,dt.VR)(this.flyoutData,this.utilities,this.stateManagement,t);if(s){let i=e.get(s);i||(i=[]),i.push(t),e.set(s,i)}}return e}isAOCEnabled(){return e.R.isExperimentActive(f.H.autoOpenControllerScript)}getToBeToggledCompositePopupOriginations(e,t,i){let n=[];if(this.isAOCEnabled()){const o=((e,t)=>{let i=[];return i=MI().filter((i=>LI(t,i).includes(e))),i})(e,this.flyoutData);if(t)for(const t of o){let o=this.getCompositeNotificationDisabledFeatures(t,i);o=o.filter((t=>t!==e)),0===o.length&&n.push(t)}else n=o}return n}getCompositeNotificationDisabledFeatures(e,t){const i=LI(this.flyoutData,e),n=[];for(const e of i){const i=t.get(e);i&&i.length&&((0,dt.gQ)(i[0],this.flyoutData,this.autoOpenControllerUtilities)||n.push(e))}return n}checkIfAnyCompositeNotificationsShouldBeDisabledOnStartup(t){const i=[];if(this.isAOCEnabled()){const n=(()=>{const t=[];return(e.R?.isExperimentActive(f.H.cashbackPdpPlusCouponsNotification)||e.R?.isExperimentActive(f.H.cashbackPdpPlusCouponsNotificationV2))&&t.push(u.sR.AUTO_SHOW_CASHBACK_PDP_PLUS_COUPONS),(e.R?.isExperimentActive(f.H.cashbackPdpPlusPriceDropNotification)||e.R?.isExperimentActive(f.H.cashbackPdpPlusPriceDropNotificationV2))&&t.push(u.sR.AUTO_SHOW_PRICE_DROP_PLUS_CASHBACK),(e.R?.isExperimentActive(f.H.lowerPricePdpPlusCashbackPlusCoupons)||e.R?.isExperimentActive(f.H.lowerPricePdpPlusCashbackPlusCouponsV2))&&t.push(u.sR.AUTO_SHOW_LOWER_PRICE_PLUS_CASHBACK_PLUS_COUPONS),t})();for(const e of n)this.getCompositeNotificationDisabledFeatures(e,t).length>0&&i.push(e)}return i}},UI=class extends BI{constructor(e,t,i,n,o,r,a,l){super(e,t,i,n,o,r,a),(0,s.Z)(this,"manageSettingsMenu",void 0),(0,s.Z)(this,"storageHandler",void 0),this.storageHandler=l}renderMenuModule(){this.manageSettingsMenu=(0,Y.Ux)("fluent-menu",{id:"manage-settings-menu",slot:"menu",style:this.commonMenuStyles(),tabeIndex:-1,className:"hide",ariaLabel:"Shopping Settings"}),this.flyoutData.common.openedWith!==r.Te.Auto&&(this.manageSettingsMenu.style.maxHeight="25%"),this.flyoutData.common.isPane&&this.flyoutData.common.isSharedHeader&&(this.manageSettingsMenu.style.top="0px",this.manageSettingsMenu.style.left="55px",this.manageSettingsMenu.style.width="230px");const e=this.createShoppingSettingsMenuHeader(),t=this.getLineSeprator(),i=t.cloneNode(!0);i.style.width="100%";const n=this.getDescriptionText();this.manageSettingsMenu.append(i),this.manageSettingsMenu.append(e),this.manageSettingsMenu.append(i),this.createCashbackMenuItem(n,t),this.createPersonalizedReminderMenuItem(n,t),this.createPackageTrackingMenuItem(n,t),this.createPriceMatchMenuItem(n,t);const o=this.createEdgeShoppingMenuItem(this.flyoutData.common.popupOrigination);return this.manageSettingsMenu.append(o),this.manageSettingsMenu.addEventListener("click",(e=>{e.stopPropagation()})),this.manageSettingsMenu}createShoppingSettingsMenuHeader(){const e=(0,Y.Ux)("fluent-menu-item",{style:"\n font-weight: 600;\n text-align: center;\n margin-top: 7px;\n margin-bottom: 11px;\n "}),t=(0,Y.Ux)("DIV",{style:"\n align-self: center;\n flex-grow: 0.5;\n justify-content: center;\n background: transparent;\n display: flex;\n "});t.style.display="flex",t.slot="start",t.setAttribute("aria-hidden","true"),e.title=this.flyoutData.strings.commonShoppingSettings,e.textContent=this.flyoutData.strings.commonShoppingSettings,e.tabIndex=0,e.className+="defaultFontFamily",e.id="manage-settings-header",this.flyoutData.common.isPane&&this.flyoutData.common.isSharedHeader&&(e.style.fontSize="12px",e.style.margin="5px 0px"),t.innerHTML=this.commonAssets.getLeftArrowIcon(),e.appendChild(t);const i=e=>{const t=document.querySelector(`#${r.z6.MENU_CONTENT}`);t&&(t.classList.remove("hide"),this.manageSettingsMenu.classList.toggle("hide")),e.stopPropagation()};e.addEventListener("click",i),this.utilities.makeHtmlElementKeyboardClickable(e,(e=>{i(e);const t=this.parentMenu.querySelectorAll("fluent-menu-item");t?.length&&t[0].focus()})),e.addEventListener("keydown",(e=>{"ArrowDown"!==e.key&&"ArrowUp"!==e.key||e.preventDefault()}));const n=(0,Y.Ux)("DIV",{ariaLabel:"Shopping Settings Header"});return n.appendChild(e),n}createCashbackMenuItem(e,t){if(void 0!==this.flyoutData.common.isOrganicFlowEnabled&&this.flyoutData.dataStoreModule.CashBackData?.canRenderCashback){const i=this.createShoppingSettingsMenuItem(this.flyoutData.strings.cbFeatureName,this.commonAssets.getShoppingTagIcon(),this.flyoutData.common.isOrganicFlowEnabled,this.onManageCashbackClick.bind(this)),n=e.cloneNode(!0);n.textContent=this.flyoutData.strings.cashbackSettingsText,this.manageSettingsMenu.append(i),this.manageSettingsMenu.append(n),this.manageSettingsMenu.append(t.cloneNode(!0))}}createPackageTrackingMenuItem(e,t){const i=this.flyoutData?.dataStoreModule?.OrderTrackingData?.shouldShowPackageTrackingNotification??!1,n=this.flyoutData?.dataStoreModule?.OrderTrackingData?.packageTrackingUserConsented??!1,o=this.createShoppingSettingsMenuItem(this.flyoutData.strings.packageTrackingFeatureName,this.commonAssets.getPackageTrackingIcon(),n,this.onManagePackageTrackingClick.bind(this));if(i&&n){const i=e.cloneNode(!0);i.textContent=this.flyoutData.strings.packageTrackingSettingsText,this.manageSettingsMenu.append(o),this.manageSettingsMenu.append(i),this.manageSettingsMenu.append(t.cloneNode(!0))}}createPriceMatchMenuItem(e,t){const i=this.flyoutData?.dataStoreModule?.OrderTrackingData?.priceMatchingUserConsented??!1,n=this.createShoppingSettingsMenuItem(this.flyoutData.strings.postPurchaseTrackingFeatureName,this.commonAssets.getPackageTrackingIcon(),i,this.onManagePriceMatchingClick.bind(this));if(i){const i=e.cloneNode(!0);i.textContent=this.flyoutData.strings.priceMatchSettingsText,this.manageSettingsMenu.append(n),this.manageSettingsMenu.append(i),this.manageSettingsMenu.append(t.cloneNode(!0))}}createPersonalizedReminderMenuItem(t,i){if(void 0!==this.flyoutData.common.isShoppingPersonalizationEnabled&&e.R.isExperimentActive(f.H.priceDropNotification)){const e=this.createShoppingSettingsMenuItem(this.flyoutData.strings.personalizedReminders,this.commonAssets.getPersonalizedReminddersIcon(),this.flyoutData.common.isShoppingPersonalizationEnabled,this.onManageRemindersClick.bind(this)),n=t.cloneNode(!0);n.textContent=this.flyoutData.strings.personalizedRemindersSettingsText,this.manageSettingsMenu.append(e),this.manageSettingsMenu.append(n),this.manageSettingsMenu.append(i.cloneNode(!0))}}createShoppingSettingsMenuItem(e,t,i,n){const o=document.createElement("fluent-menu-item");o.title=e,o.textContent=e,o.classList.add("defaultFontFamily","notification-manage-item"),this.flyoutData.common.isPane&&this.flyoutData.common.isSharedHeader&&(o.style.fontSize="12px");const r=document.createElement("DIV");r.style.display="flex",r.slot="start",r.id="cashback-icon",r.setAttribute("aria-hidden","true"),r.classList.add("notification-icon"),r.innerHTML=t;const a=(0,Y.Ux)("fluent-switch");a.style.setProperty("--accent-fill-rest","unset");const s=(0,Y.Ux)("DIV",{style:"position: relative; height : 20px;",slot:"end"});s.appendChild(a),i&&(this.enableSwitchToggle(a,!0),o.setAttribute("enabled","true"));const l=async e=>{if(i=o.hasAttribute("enabled")){const e=o.querySelector("fluent-switch");this.enableSwitchToggle(e,!1),n(i),o.removeAttribute("enabled")}else{const e=o.querySelector("fluent-switch");this.enableSwitchToggle(e,!0),n(i),o.setAttribute("enabled","true")}e.stopPropagation()};return o.addEventListener("click",l),this.utilities.makeHtmlElementKeyboardClickable(o,l),o.appendChild(r),o.appendChild(s.cloneNode(!0)),o}createEdgeShoppingMenuItem(e){const t=document.createElement("fluent-menu-item");t.title=this.flyoutData.strings.edgeShoppingSettings,t.textContent=this.flyoutData.strings.edgeShoppingSettings,t.classList.add("defaultFontFamily","notification-manage-item"),this.flyoutData.common.isPane&&this.flyoutData.common.isSharedHeader&&(t.style.fontSize="12px");const n=document.createElement("DIV");n.attachShadow({mode:"open"}).innerHTML=this.commonAssets.getHeaderIcon(),n.style.display="flex",n.slot="start",n.id="edge-icon",n.setAttribute("aria-hidden","true"),n.classList.add("notification-icon");const o=(0,Y.Ux)("DIV",{style:"position: relative;",slot:"end"}),r=(0,Y.Ux)("DIV",{ariaHidden:"true",className:"rounded-checkbox-icon"});return r.innerHTML=this.commonAssets.getOpenLinkIcon(),o.appendChild(r),t.addEventListener("click",(async t=>{this.pageHandlerModule.RecordAsUserAction(K.bS.MANAGE);const n=new W.Z(i.$S.FlyoutManage,bp.r.MENU);n.Metadata=JSON.stringify({popupOriginationEnum:e}),this.logModule.LogInfoEvent(i.R.ButtonClick,"Flyout Menu Manage",n),this.pageHandlerModule.NavigateToEdgeUrl("edge://settings/privacy#Shopping",ju.$.NEW_FOREGROUND_TAB)})),t.appendChild(n),t.appendChild(o.cloneNode(!0)),t}onManageCashbackClick(e){if(e){const e=new W.Z(i.$S.OrganicFlowTurnedOff,bp.r.MENU);this.logModule.LogInfoEvent(i.R.ButtonClick,"Organic flow turned off",e),this.pageHandlerModule.SetAllowOrganicRebates(!1)}else{const e=new W.Z(i.$S.OrganicFlowTurnedOn,bp.r.MENU);this.logModule.LogInfoEvent(i.R.ButtonClick,"Organic flow turned on",e),this.pageHandlerModule.SetAllowOrganicRebates(!0)}}onManageRemindersClick(e){if(e){const e=new W.Z(i.$S.PersonalizedRemindersTurnedOff,bp.r.MENU);e.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.logModule.LogInfoEvent(i.R.ButtonClick,"Personalizedd Reminders turned off",e),this.pageHandlerModule.SetIsPersonalizedShoppingEnabled(!1),this.pageHandlerModule.RecordAsUserAction(K.bS.PWILO_NOTIFICATION_PRICE_DROP_DISABLE_REMINDERS),this.pageHandlerModule.AllowServerDrivenNotifications(!1)}else{const e=new W.Z(i.$S.PersonalizedRemindersTurnedOn,bp.r.MENU);e.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.logModule.LogInfoEvent(i.R.ButtonClick,"Personalizedd Reminders turned on",e),this.pageHandlerModule.SetIsPersonalizedShoppingEnabled(!0),this.pageHandlerModule.AllowServerDrivenNotifications(!0)}}onManagePackageTrackingClick(e){if(e){this.pageHandlerModule.SetPackageTrackingUserConsent(!1),this.pageHandlerModule.RecordAsUserAction(K.bS.PACKAGE_TRACKING_OPT_OUT);const e=new W.Z(i.$S.PackageTrackingOptOut,bp.r.MENU);e.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.logModule.LogInfoEvent(i.R.ButtonClick,"User disabled package tracking from menu",e)}else{this.pageHandlerModule.SetPackageTrackingUserConsent(!0),this.pageHandlerModule.RecordAsUserAction(K.bS.PACKAGE_TRACKING_OPT_IN),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PACKAGE_TRACKING_OPT_IN,this.flyoutData.common.popupOrigination);const e=new W.Z(i.$S.PackageTrackingOptIn,bp.r.MENU);e.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.logModule.LogInfoEvent(i.R.ButtonClick,"User enabled package tracking from menu",e)}}onManagePriceMatchingClick(e){if(e){this.storageHandler.setStorageBool(Ce.Q.PriceMatchConsent,!1),this.pageHandlerModule.RecordAsUserAction(K.bS.PRICE_MATCH_OPT_OUT);const e=new W.Z(i.$S.PriceMatchOptOut,bp.r.MENU);e.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.logModule.LogInfoEvent(i.R.ButtonClick,"User disabled price matching from menu",e)}else{this.storageHandler.setStorageBool(Ce.Q.PriceMatchConsent,!0),this.pageHandlerModule.RecordAsUserAction(K.bS.PRICE_MATCH_OPT_IN),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRICE_MATCH_OPT_IN,this.flyoutData.common.popupOrigination);const e=new W.Z(i.$S.PriceMatchOptIn,bp.r.MENU);e.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.logModule.LogInfoEvent(i.R.ButtonClick,"User enabled price matching from menu",e)}}},HI=class extends BI{constructor(...e){super(...e),(0,s.Z)(this,"manageSettingsMenu",void 0)}renderMenuModule(){this.manageSettingsMenu=(0,Y.Ux)("fluent-menu",{id:"manage-settings-menu",slot:"menu",style:this.commonMenuStyles(),tabeIndex:-1,className:"hide",ariaLabel:"Shopping Settings"});const e=this.createShoppingSettingsMenuHeader(),t=this.getLineSeprator().cloneNode(!0);return t.style.width="100%",this.manageSettingsMenu.append(t),this.manageSettingsMenu.append(e),this.manageSettingsMenu.append(t),this.createCrossSiteTrackingIsEnabledMenuItem(),this.manageSettingsMenu.addEventListener("click",(e=>{e.stopPropagation()})),this.manageSettingsMenu}createShoppingSettingsMenuHeader(){const e=(0,Y.Ux)("fluent-menu-item",{style:"\n font-weight: 600;\n text-align: center;\n margin-top: 7px;\n margin-bottom: 11px;\n "}),t=(0,Y.Ux)("DIV",{style:"\n align-self: center;\n flex-grow: 0.5;\n justify-content: center;\n background: transparent;\n display: flex;\n "});t.style.display="flex",t.slot="start",t.setAttribute("aria-hidden","true"),e.title=this.flyoutData.strings.commonShoppingSettings,e.textContent=this.flyoutData.strings.commonShoppingSettings,e.tabIndex=0,e.className+="defaultFontFamily",e.id="manage-settings-header",t.innerHTML=this.commonAssets.getLeftArrowIcon(),e.appendChild(t);const i=e=>{const t=document.querySelector(`#${r.z6.MENU_CONTENT}`);t&&(t.classList.remove("hide"),this.manageSettingsMenu.classList.toggle("hide")),e.stopPropagation()};e.addEventListener("click",i),this.utilities.makeHtmlElementKeyboardClickable(e,(e=>{i(e);const t=this.parentMenu.querySelectorAll("fluent-menu-item");t?.length&&t[0].focus()})),e.addEventListener("keydown",(e=>{"ArrowDown"!==e.key&&"ArrowUp"!==e.key||e.preventDefault()}));const n=(0,Y.Ux)("DIV",{ariaLabel:"Shopping Settings Header"});return n.appendChild(e),n}createCrossSiteTrackingIsEnabledMenuItem(){const e=this.createShoppingSettingsMenuItem(this.flyoutData.strings.crossSiteTrackingIsEnabled,"",this.flyoutData.common.hasUserAgreedToPrivacyPolicy,this.onManageCrossSiteTrackingClick.bind(this));this.manageSettingsMenu.append(e)}createShoppingSettingsMenuItem(e,t,i,n){const o=(0,Y.Ux)("fluent-switch");return o.textContent=e,o.style.display="flex",o.style.justifyContent="space-evenly",o.style.setProperty("--accent-fill-rest","unset"),o.setAttribute("type","switch"),o.setAttribute("title","switch"),o.setAttribute("checked",i.toString()),o.addEventListener("change",(()=>{n(o.checked)})),o}onManageCrossSiteTrackingClick(e){if(e){const e=new W.Z(i.$S.SafariCrossSiteTrackingTurnedOn,bp.r.MENU);this.pageHandlerModule.SendAgreementStatus(!0),e.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.logModule.LogInfoEvent(i.R.ButtonClick,"Safari cross tracking turned on",e)}else{const e=new W.Z(i.$S.SafariCrossSiteTrackingTurnedOff,bp.r.MENU);e.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.logModule.LogInfoEvent(i.R.ButtonClick,"Safari cross tracking turned off",e),this.pageHandlerModule.SendAgreementStatus(!1)}}},$I=class{constructor(n,o,l,c,d){(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"telemetryHandler",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"footerUtilities",void 0),(0,s.Z)(this,"autoOpenControllerUtilities",void 0),(0,s.Z)(this,"manageNotificationMenu",void 0),(0,s.Z)(this,"manageSettingsMenu",void 0),(0,s.Z)(this,"backgroundOverlay",void 0),(0,s.Z)(this,"sidepaneCashback",void 0),(0,s.Z)(this,"storageHandler",void 0),this.flyoutData=n,this.utilities=o.viewModulesUtilities,this.pageHandlerModule=l,this.telemetryHandler=o.telemetryHandler,this.logModule=c,this.stateManagement=d,this.commonAssets=o.commonAssets,this.footerUtilities=o.footerUtilities,this.autoOpenControllerUtilities=o.autoOpenControllerUtilities,this.sidepaneCashback=new class{constructor(e,t){(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"storedCashbackData",void 0),this.commonAssets=new a.Z,this.flyoutData=e,this.pageHandlerModule=t.pageHandlerModule,this.logModule=t.logModule,this.utilities=t.viewModulesUtilities,this.telemetryUtilities=t.telemetryHandler,this.storageHandler=t.storageHandler}addSidepaneCashback(n,o,a,s=!1){s||(n?.userRebatesResponse&&(this.storedCashbackData=n),this.storedCashbackData||this.getStorageString().then((e=>{this.storedCashbackData=e?.cashBackData})));const l=e.R.isExperimentActive(f.H.sidepaneCashback),c=this.flyoutData.common.isPane,d=(0,T.uf)(this.flyoutData.common.market,this.flyoutData.dataStoreModule.ApiData?.retailerData?.exclusiveMarket),u=["en-us","en-ca","en-gb","ja-jp"].some((e=>e===d)),h=!!this.storedCashbackData?.userRebatesResponse;if(l&&c&&u&&h){const e=this.getSidepaneCashbackScenario(this.storedCashbackData);try{if(e){let t=o.querySelector(`#${r.z6.SIDEPANE_CASHBACK}`);if(!t){const e=this.createSidepaneCashbackButton(this.storedCashbackData,o);if(!e)return!1;t=e;const i=o.querySelector(`#${r.z6.MENU}`);i?o.insertBefore(t,i):o.prepend(t),gn.SO.queueUpdate((()=>{t&&t.control?.setAttribute("title",t.title)}))}let i=o.querySelector(`#${r.z6.SIDEPANE_CASHBACK_CONTENT}`);i||(i=this.createSidepaneCashbackCard(this.storedCashbackData,e,o),o.appendChild(i)),this.manageSidepaneCashbackMenuEvents(i,t,this.storedCashbackData,e),this.handleClickOutsideMenu(a,i,t);const n=!!t&&!!i;return n&&this.telemetryUtilities.recordContentViewed(r.ModuleNames.SIDEPANE_CASHBACK,Jl.g.EdgeImpressionId,!1,-1),n}}catch(o){const r=new t.Z(i.xu.SidepaneCashbackError);return r.Metadata=JSON.stringify({isExperimentActive:l,isPane:c,isCashbackEligibleMarket:u,hasUserRebatesResponse:h,scenario:e,err:o,cashBackData:n}),this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Error rendering sidepane cashback: ${o}`,r),!1}}return!1}setCacheOrAddSidepaneCashback(e,t,i){const n=e?.userRebatesResponse;return n?(this.setCashbackDataToCache(e),!1):this.addSidepaneCashback(e,t,i,!0)}getSidepaneCashbackScenario(e){const t=e?.userRebatesResponse;if(!t||void 0===t.isRebatesUser)return;let i=r.jB.NEW_USER;if(t&&t.isRebatesUser&&(i=r.jB.PASSIVE_USER,t.lifetimeBalance&&t.lifetimeBalance>0)){const e=t.cashbackAvailable,n=t.latestCashbackApproved,o=t.latestOrderDate;if(o){const t=new Date(o),a=new Date(Date.now()),s=Math.abs(Number(a)-Number(t)),l=Math.ceil(s/tt.Jg);l<=tt.dX&&n&&0!==n?i=r.jB.COMPLETED_PURCHASE_KNOWN_VALUE:e&&(e>5||l>tt.SY)?i=r.jB.PENDING_TO_AVAILABLE:e&&0!==e||(i=r.jB.CASHED_OUT)}}return i}async setCashbackDataToCache(e){const t=await this.getStorageString(),{lastUpdatedAt:i,cashBackData:n}=t,o=JSON.stringify(e?.userRebatesResponse)!==JSON.stringify(n?.userRebatesResponse);(this.isStaleStorage(i)||o)&&this.setStorageString(e)}handleClickOutsideMenu(e,t,i){e&&e.addEventListener("click",(e=>{"hide"!==t.className&&(t.className="hide",i.setAttribute("aria-expanded","undefined"))}))}manageSidepaneCashbackMenuEvents(t,n,o,a){t.addEventListener("keydown",(e=>{"Escape"===e.key?(t.className="hide",n.setAttribute("aria-expanded","undefined"),n.focus(),e.preventDefault()):"Tab"===e.key&&(n.focus(),e.shiftKey&&e.preventDefault())})),t.addEventListener("click",(e=>{e.stopPropagation(),"hide"===t.className&&n.setAttribute("aria-expanded","true")})),n.addEventListener("focus",(()=>{"hide"!==t.className&&(t.className="hide",n.setAttribute("aria-expanded","undefined"))})),n.addEventListener("keydown",(e=>{if("Escape"===e.key&&"hide"!==t.className)t.className="hide",n.setAttribute("aria-expanded","undefined"),e.preventDefault();else if("Tab"===e.key&&"hide"!==t.className)e.shiftKey?(t.className="hide",n.setAttribute("aria-expanded","undefined")):t.focus(),e.preventDefault();else if("Enter"===e.key){e.preventDefault(),t.classList.toggle("hide");const i=t.querySelector(".hyperlink");i&&i.focus()}})),this.pageHandlerModule.TriggerExperiment(f.H.sidepaneCashback);const s=e.R.isVariantActive(f.H.sidepaneCashback,Yu.$T.Hover);let l=!1;if(n.addEventListener(s?"mouseenter":"click",(e=>{const c=document.querySelectorAll("fluent-menu[slot='start-content'], msft-cashback-header-card");for(const e of c)e!==t&&e.classList.add("hide");t.classList.toggle("hide");const d=t.querySelector(".hyperlink");if(d&&!s&&d.focus(),"hide"===t.className)n.setAttribute("aria-expanded","undefined");else{if(!l){const e=i.$S.SidepaneCashbackButton,c=n.querySelector("#sidepaneCashbackButton"),d=t.querySelector("#sidepaneCashbackDescription"),u=JSON.stringify({variant:s?"hover":"click",btnText:c?.textContent,cardText:d?.textContent,urr:o?.userRebatesResponse,scenario:a}),h=new W.Z(e,this.telemetryUtilities.setContentViewed(r.ModuleNames.SIDEPANE_CASHBACK),this.flyoutData.common.domain,u);this.pageHandlerModule.RecordAsUserAction(K.bS.REBATES_ACCOUNT),this.pageHandlerModule.RecordAsUserEngagement(q.FV.REBATES_ACCOUNT,this.flyoutData.common.popupOrigination);const p="Sidepane Cashback "+(s?"hovered":"clicked");this.logModule.LogInfoEvent(i.R.ButtonClick,p,h),l=!0}n.setAttribute("aria-expanded","true")}e.stopPropagation()})),s){n.style.backgroundColor="var(--fill-color)",n.style.cursor="default";let e=!1;n.addEventListener("mouseleave",(()=>{t.addEventListener("mouseenter",(()=>{e=!0})),t.addEventListener("mouseleave",(()=>{e&&(t.classList.add("hide"),e=!1)})),setTimeout((()=>{e||t.classList.add("hide")}),0)}))}}createSidepaneCashbackButton(e,t){const i=t.querySelector(`#${r.z6.SIDEPANE_CASHBACK}`);let n;if(i)n=i;else{const t=e?.userRebatesResponse;if(void 0===t?.userCurrency)return;n=document.createElement("fluent-button"),n.slot="header-actions",n.ariaHaspopup="menu",n.appearance="stealth",n.id=r.z6.SIDEPANE_CASHBACK,n.ariaControls=r.z6.SIDEPANE_CASHBACK_CONTENT;const i=(0,Y.Ux)("div",{style:"display: flex; align-items: center; gap: 4px"}),o=(0,Y.Ux)("div",{style:"display: flex; align-content: center;"});o.setAttribute("aria-hidden","true"),o.innerHTML=this.commonAssets.getCashbackIcon();const a=(0,Y.Ux)("div",{id:"sidepaneCashbackButton",style:"display: flex; font-weight: 600; font-size: 14px; line-height: 16px"});a.style.color=this.utilities.isDarkMode()?"rgba(255, 255, 255, 0.8)":"rgba(0, 0, 0, 0.8)",a.classList.add("defaultFontFamily");const s=(0,ne.qk)(t.userCurrency);let l;if(t?.isRebatesUser&&t?.cashbackAvailable){const e=this.utilities.formatPrice(t.cashbackAvailable);a.textContent=`${s}${e}`,l=(0,T.fZ)("spcbCashbackBalance",this.flyoutData.strings.spcbCashbackBalance,`${s}${e}`)}else a.textContent=`${s}0`,l=(0,T.fZ)("spcbCashbackBalance",this.flyoutData.strings.spcbCashbackBalance,`${s}0`);a.ariaLabel=l,n.title=l,i.appendChild(a),i.appendChild(o),n.appendChild(i)}return n}createSidepaneCashbackCard(e,t,i){const n=i.querySelector(`#${r.z6.SIDEPANE_CASHBACK_CONTENT}`);let o;if(n)o=n;else{o=(0,Y.Ux)("msft-cashback-header-card"),o.id=r.z6.SIDEPANE_CASHBACK_CONTENT,o.title=this.flyoutData.strings.instantcbBingRebates,o.tabIndex=-1,o.setAttribute("aria-labelledby",r.z6.SIDEPANE_CASHBACK),o.setAttribute("role","menuitem"),o.style.appearance="outline",o.style.width="100%";const i=(0,Y.Ux)("img");this.utilities.setImageSrc(i,this.flyoutData.common.resourcesEndpoint+"sidepaneCashback/cash.png"),i.setAttribute("aria-hidden","true"),i.slot="image";const n=(0,Y.Ux)("fluent-anchor",{className:"hyperlink"});n.href="#",n.appearance="lightweight",n.style.fontWeight="400",n.style.fontSize="14px";const a=this.getCashbackHyperlinkString(t);n.textContent=a,n.slot="hyperlink",n.tabIndex=0,n.addEventListener("keydown",(e=>{"Enter"===e.key&&(e.preventDefault(),this.handleCashbackHyperlinkClick(t,a))})),n.addEventListener("click",(e=>{e.preventDefault(),this.handleCashbackHyperlinkClick(t,a)}));const s=(0,Y.Ux)("p",{id:"sidepaneCashbackDescription"}),l=this.getCashbackItemString(t,e);o.setAttribute("aria-label",l),s.textContent=l,s.slot="description",o.appendChild(s),o.appendChild(i),o.appendChild(n),o.setAttribute("style","position: absolute; top: 40px; left: 50px;"),o.className="hide",gn.SO.queueUpdate((()=>{o.setAttribute("slot","start-content"),n.shadowRoot?.querySelector(".control")?.setAttribute("style","padding: 0px;")}))}return o}handleCashbackHyperlinkClick(e,t){const n=i.$S.SidepaneCashbackAnchor,o=JSON.stringify({actionText:t,scenario:e}),a=new W.Z(n,this.telemetryUtilities.setContentViewed(r.ModuleNames.SIDEPANE_CASHBACK),this.flyoutData.common.domain,o);this.logModule.LogInfoEvent(i.R.ButtonClick,"Sidepane Cashback anchor button clicked",a),this.pageHandlerModule.RecordAsUserAction(K.bS.REBATES_HISTORY),this.pageHandlerModule.RecordAsUserEngagement(q.FV.REBATES_HISTORY,this.flyoutData.common.popupOrigination),this.nagivateToCashbackEndpoint(e)}nagivateToCashbackEndpoint(e){const t=this.pageHandlerModule;switch(e){case r.jB.NEW_USER:t.NavigateToBingRebates();break;case r.jB.COMPLETED_PURCHASE_UNKNOWN_VALUE:case r.jB.COMPLETED_PURCHASE_KNOWN_VALUE:t.NavigateToBingRebatesHistory();break;case r.jB.PENDING_TO_AVAILABLE:t.NavigateToBingRebatesPayouts();break;case r.jB.PASSIVE_USER:case r.jB.CASHED_OUT:t.NavigateToBingRebatesDeals()}}getCashbackHyperlinkString(e){switch(e){case r.jB.NEW_USER:return this.flyoutData.strings.spcbJoinNow;case r.jB.PASSIVE_USER:return this.flyoutData.strings.spcbViewTopDeals;case r.jB.COMPLETED_PURCHASE_UNKNOWN_VALUE:case r.jB.COMPLETED_PURCHASE_KNOWN_VALUE:return this.flyoutData.strings.spcbTrackCashback;case r.jB.PENDING_TO_AVAILABLE:return this.flyoutData.strings.spcbRedeemNow;case r.jB.CASHED_OUT:return this.flyoutData.strings.spcbCheckOffers}}getCashbackItemString(e,t){const i=t?.userRebatesResponse,n=i?.latestOrderMerchantName?`at ${i.latestOrderMerchantName}`:"",o=this.utilities.formatPrice(i?.latestCashbackApproved),a=i?.userCurrency,s=(0,ne.qk)(a),l=this.utilities.formatPrice(i?.cashbackAvailable),c=isNaN(i?.latestCashbackApproved)?"":`${s}${o}`,d=isNaN(i?.cashbackAvailable)?"cash":`${s}${l}`;switch(e){case r.jB.NEW_USER:return this.flyoutData.strings.spcbJoinNewUser;case r.jB.PASSIVE_USER:return this.flyoutData.strings.spcbPassiveUser;case r.jB.COMPLETED_PURCHASE_UNKNOWN_VALUE:return(0,T.fZ)("spcbUnknownValue",this.flyoutData.strings.spcbUnknownValue,n);case r.jB.COMPLETED_PURCHASE_KNOWN_VALUE:return(0,T.fZ)("spcbKnownValue",this.flyoutData.strings.spcbKnownValue,c,n);case r.jB.PENDING_TO_AVAILABLE:return(0,T.fZ)("spcbCashoutReady",this.flyoutData.strings.spcbCashoutReady,d);case r.jB.CASHED_OUT:return this.flyoutData.strings.spcbCashedOut}}async getStorageString(){const e=await this.storageHandler.getStorageString("SidepaneCashback");try{return JSON.parse(e)}catch(e){return{lastUpdatedAt:new Date}}}isStaleStorage(e){if(!e)return!0;try{const t=new Date(e);return Date.now()-+t>18e5}catch(e){return!0}}setStorageString(e){const t=e?.userRebatesResponse;if(t){const t={cashBackData:e,lastUpdatedAt:new Date};this.storageHandler.setStorageString("SidepaneCashback",JSON.stringify(t))}}}(n,o),this.storageHandler=o.storageHandler}getFriendlyFeatureName(e){return(0,dt.VR)(this.flyoutData,this.utilities,this.stateManagement,e)}async createFlyoutButtons(e,t,i){const n=this.flyoutData.dataStoreModule.CashBackData;let o=!1;i&&(t&&!this.isDisableOptOutMenuActive()&&(this.stateManagement.getState(Ku.IY.modulesRendered)&&this.createContextMenu(e,n?.canRenderCashback??!1,this.stateManagement.getState(Ku.IY.topModuleName),i).then((()=>{o||(o=this.sidepaneCashback.addSidepaneCashback(n,e,i))})),this.stateManagement.addEventListener(Ku.e1.ModulesRendered,(()=>{this.createContextMenu(e,n?.canRenderCashback??!1,this.stateManagement.getState(Ku.IY.topModuleName),i).then((()=>{o||(o=this.sidepaneCashback.addSidepaneCashback(n,e,i))}))}))),this.createCloseButton(e)),gn.SO.queueUpdate((()=>{o=this.sidepaneCashback.setCacheOrAddSidepaneCashback(n,e,i),this.addListenerMenuItemKeyboardClick(e)}))}addAutoShowItem(n,o,a){if(a&&e.R.isVariantActive(f.H.footerExperiments,Yu._K.RemoveDontShowFeatureAgain))return;let s=null;const l=document.createElement("DIV");let c;if(o&&(c=(0,dt.g7)(o,this.flyoutData,this.autoOpenControllerUtilities,this.logModule)),c&&this.flyoutData.common.openedWith===r.Te.Auto){s=document.createElement("fluent-menu-item"),a||(l.innerHTML=this.commonAssets.getDisableAutoOpen(),l.setAttribute("aria-hidden","true")),s.id="Enabled",s.className+=" defaultFontFamily",OI.Z.CloseFooterOverlay(n,s);let e=this.flyoutData.strings.commonCMAutoShowDisable;const r=this.getFriendlyFeatureName(o);if(""!==r)e=(0,T.fZ)("commonCMAutoShowDisableFeature",this.flyoutData.strings.commonCMAutoShowDisableFeature,r);else{const e=new t.Z(i.xu.ContextMenuInfo);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Friendly name missing for "+o,e)}s.textContent=e,s.title=e}else if(!c){s=document.createElement("fluent-menu-item"),l.innerHTML=this.commonAssets.getEnableAutoOpen(),l.setAttribute("aria-hidden","true"),s.id="Disabled",s.className+="defaultFontFamily";let e=this.flyoutData.strings.commonCMAutoShowEnable;const n=this.getFriendlyFeatureName(o);if(""===n){const e=new t.Z(i.xu.ContextMenuInfo);return void this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Friendly name missing for "+o,e)}e=(0,T.fZ)("commonCMAutoShowEnableFeature",this.flyoutData.strings.commonCMAutoShowEnableFeature,n),s.textContent=e,s.title=e}if(s){l.slot="start",s.appendChild(l);const t=this.pageHandlerModule,r=this.logModule;s.addEventListener("change",(async n=>{if(s&&"Enabled"===s.id){s.textContent=this.flyoutData.strings.commonCMAutoShowEnable,s.title=this.flyoutData.strings.commonCMAutoShowEnable,s.id="Disabled";const n=document.createElement("DIV");n.slot="start",n.innerHTML=this.commonAssets.getEnableAutoOpen(),n.setAttribute("aria-hidden","true"),s.appendChild(n);const l=new W.Z(i.$S.AutoShowTurnedOff,bp.r.MENU);t.RecordAsUserAction(K.bS.TURN_OFF_AUTO_SHOW);const c="Auto Show turned off";let d;if(o&&o===u.sR.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION&&(d=this.utilities.getPwiloPopupOrigination(this.stateManagement)),d?l.Metadata=JSON.stringify({popupOriginationEnum:d}):o&&(l.Metadata=JSON.stringify({popupOriginationEnum:o})),r.LogInfoEvent(i.R.ButtonClick,c,l,Jl.g.CouponImpressionId),o&&o===u.sR.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION)t.AllowServerDrivenNotifications(!1),a&&this.pageHandlerModule.DismissPopup();else if(o){let i=(0,dt.vW)(o);e.R.isExperimentActive(f.H.autoOpenControllerScript)&&await this.autoOpenControllerUtilities.setUserPreferenceBatch(!1,i,this.flyoutData.common.disabledNotifications),t.AutoShowForAllFeatures(!1,i),a&&this.pageHandlerModule.DismissPopup()}}else if(s){s.textContent=this.flyoutData.strings.commonCMAutoShowDisable,s.title=this.flyoutData.strings.commonCMAutoShowDisable,s.id="Enabled";const n=document.createElement("DIV");n.slot="start",n.innerHTML=this.commonAssets.getDisableAutoOpen(),n.setAttribute("aria-hidden","true"),s.appendChild(n);const l=new W.Z(i.$S.AutoShowTurnedOn,bp.r.MENU);t.RecordAsUserAction(K.bS.TURN_ON_AUTO_SHOW);const c="Auto Show turned on";let d;if(o&&o===u.sR.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION&&(d=this.utilities.getPwiloPopupOrigination(this.stateManagement)),d?l.Metadata=JSON.stringify({popupOriginationEnum:d}):o&&(l.Metadata=JSON.stringify({popupOriginationEnum:o})),r.LogInfoEvent(i.R.ButtonClick,c,l,Jl.g.CouponImpressionId),o&&o===u.sR.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION)t.AllowServerDrivenNotifications(!0),a&&this.pageHandlerModule.DismissPopup();else if(o){let i=(0,dt.vW)(o);e.R.isExperimentActive(f.H.autoOpenControllerScript)&&await this.autoOpenControllerUtilities.setUserPreferenceBatch(!0,i,this.flyoutData.common.disabledNotifications),t.AutoShowForAllFeatures(!0,i),a&&this.pageHandlerModule.DismissPopup()}}n.stopPropagation()})),s.addEventListener("click",(e=>{e.stopPropagation()})),n.appendChild(s)}}handleClickOutsideMenu(e,t,i){e.addEventListener("click",(e=>{e.target?.nodeName?.includes("FEEDBACK")||("hide"!==t.className&&(t.className="hide",i.setAttribute("aria-expanded","undefined")),this.backgroundOverlay?.classList.add("hide"))}))}manageMenuEvents(t,i,n){t.addEventListener("keydown",(e=>{"Escape"===e.key?(t.className="hide",this.backgroundOverlay?.classList.add("hide"),i.setAttribute("aria-expanded","undefined"),i.focus(),e.preventDefault()):"Tab"===e.key&&("btnFeedbackDislike"!==e.target?.id||e.shiftKey||e.preventDefault())})),i.addEventListener("focus",(()=>{"hide"!==t.className&&(t.className="hide",this.backgroundOverlay?.classList.add("hide"),i.setAttribute("aria-expanded","undefined"))})),i.addEventListener("keydown",(e=>{"Escape"!==e.key&&"Tab"!==e.key||"hide"===t.className||(t.className="hide",this.backgroundOverlay?.classList.add("hide"),i.setAttribute("aria-expanded","undefined"),i.focus(),e.preventDefault())}));let o=!1;i.addEventListener("click",(a=>{if(e.R.isExperimentActive(f.H.newNotificationManagementUI)){if(this.manageNotificationMenu&&"hide"!==this.manageNotificationMenu.className)return void this.manageNotificationMenu.classList.add("hide");if(this.manageSettingsMenu&&"hide"!==this.manageSettingsMenu.className)return void this.manageSettingsMenu.classList.add("hide");this.backgroundOverlay?.classList.toggle("hide")}const s=document.querySelectorAll("fluent-menu[slot='start-content'], msft-cashback-header-card");for(const e of s)e!==t&&e.classList.add("hide");if(t.classList.toggle("hide"),"hide"===t.className)i.setAttribute("aria-expanded","undefined");else{const e=t.querySelectorAll("*")[0];if(e&&(0,T.pq)(a))if("feedbackDiv"===e.id&&e.children&&e.children.length>1){const t=e.children[1]?.querySelectorAll("msft-micro-feedback-item");if(t&&t.length>0){const e=t[0].shadowRoot?.querySelector("fluent-button");e&&e.focus()}}else e.focus();n&&this.flyoutData.common.openedWith!==r.Te.Auto&&!o&&(this.telemetryHandler.recordContentViewed(r.ModuleNames.FEEDBACK,Jl.g.EdgeImpressionId,!1,-1),o=!0),i.setAttribute("aria-expanded","true")}a.stopPropagation()}))}getPopupOrigination(e){const t=(0,dt.Uy)(),i=this.flyoutData.common.popupOrigination;if(void 0!==i&&this.flyoutData.common.openedWith===r.Te.Auto&&!t.includes(i))return Object.values(u.sR).includes(i)?i:null;switch(e){case r.ModuleNames.CASHBACK:const e=this.flyoutData.dataStoreModule.CashBackData;return e?.isPersonalizedCashback?this.flyoutData.dataStoreModule.CashBackData?.isConfirmationPage?u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_CONFIRMATION:u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK:e?.isConfirmationPage?u.sR.AUTO_SHOW_REBATES_CONFIRMATION:e?.isTurnedOff?null:this.flyoutData.common.isCheckoutPage?u.sR.AUTO_SHOW_REBATES_CHECKOUT:e?.isCashBackActivated?u.sR.AUTO_SHOW_REBATES:u.sR.AUTO_SHOW_REBATES_ORGANIC;case r.ModuleNames.COUPON:return u.sR.AUTO_SHOW_COUPONS_CHECKOUT;case r.ModuleNames.PRICECOMPARISON:return u.sR.AUTO_SHOW_LOWER_PRICE_FOUND;case r.ModuleNames.PRICEHISTORY:return u.sR.AUTO_SHOW_PRICE_HISTORY;case r.ModuleNames.COUPONCLIPPING:return u.sR.AUTO_SHOW_COUPONS_CLIPPING;case r.ModuleNames.SIMILARSELLERS:return u.sR.AUTO_SHOW_OTHER_SELLERS;case r.ModuleNames.GROCERY_CASHBACK:return u.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK;case r.ModuleNames.AUTOSMARKETPLACE:return u.sR.AUTO_SHOW_LOWER_PRICE_FOUND;case r.ModuleNames.ABANDONED_CART:return u.sR.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION;case r.ModuleNames.BACKGROUND_AUTO_APPLY:return u.sR.AUTO_SHOW_COUPONS_BACKGROUND_AUTO_APPLY}return null}addListenerMenuItemKeyboardClick(e){const t=e.querySelectorAll("fluent-menu-item:not(#manage-notification-button, #manage-notification-header, #manage-settings-button, #manage-settings-header, #manage-notification-menu fluent-menu-item, #manage-settings-menu fluent-menu-item)"),i=e.querySelector(`#${r.z6.MENU_CONTENT}`),n=e.querySelector(`#${r.z6.MENU}`);t&&t.length>0&&i&&n&&t.forEach((e=>{this.utilities.makeHtmlElementKeyboardClickable(e,(()=>{this.handlerMenuItemKeyboardClick(i,n)}))}))}handlerMenuItemKeyboardClick(e,t){e.className="hide",t.setAttribute("aria-expanded","undefined"),t.focus()}createCloseButton(t){const n=t.querySelector(`#${r.z6.CLOSE}`);let o;if(n)o=n;else{o=document.createElement("fluent-button"),o.slot="header-actions",this.flyoutData.strings?.commonClose?o.ariaLabel=this.flyoutData.strings.commonClose:o.ariaLabel="close",o.id=r.z6.CLOSE,o.title=this.flyoutData.strings.commonClose,(0,dt.tB)(this.flyoutData)&&(o.autofocus=!0);const e=(0,Y.Ux)("DIV");e.style.display="flex",e.style.alignContent="center",e.setAttribute("aria-hidden","true"),e.innerHTML=this.commonAssets.getCloseButton(),o.appearance="stealth",o.appendChild(e),t.appendChild(o),gn.SO.queueUpdate((()=>{o.control?.setAttribute("title",o.title)}))}const a=this.pageHandlerModule,s=this.logModule;o.addEventListener("click",(async()=>{if(this.flyoutData.common.openedWith!==r.Te.Auto){const e=new W.Z(i.$S.FlyoutDismiss,bp.r.MENU,this.flyoutData.common.domain);a.RecordAsUserAction(K.bS.DISMISSED),s.LogInfoEvent(i.R.ButtonClick,"Flyout Dismissed",e)}else{const e=new W.Z(i.$S.NotificationDismiss,bp.r.MENU),t={popupOriginationEnum:this.flyoutData.common.popupOrigination,hasPositiveEngagements:!1};this.autoOpenControllerUtilities.userEngagementStoreManager.hasPositiveEngagements&&(t.hasPositiveEngagements=this.autoOpenControllerUtilities.userEngagementStoreManager.hasPositiveEngagements),e.Metadata=JSON.stringify(t),a.RecordAsUserAction(K.bS.DISMISSED),s.LogInfoEvent(i.R.ButtonClick,"Notification Dismissed",e)}if(this.flyoutData.common.popupOrigination&&this.shouldEnableCloseButtonSnoozeForDomain(this.flyoutData.common.popupOrigination)){let t,n=2;this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_LOWER_PRICE_FOUND||this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_PRICE_HISTORY?(t=288e5,n=1):this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_COUPONS_CLIPPING?e.R.getServiceExperimentValue(f.H.clipCloseSnooze)===Yu.sf.TwoClick?(t=1728e5,n=2):(t=288e5,n=1):this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_COUPONS_CHECKOUT?e.R.getServiceExperimentValue(f.H.aaCloseSnooze)!==Yu.sf.OneClick&&e.R.getServiceExperimentValue(f.H.aaCloseSnooze)!==Yu.sf.Combined||(t=288e5,n=1):(this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_TRAVEL_NOTIFICATION_CHEAPER_FLIGHTS||this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_TRAVEL_NOTIFICATION_CHEAPER_HOTEL_ROOM)&&(t=648e5,n=1),await this.autoOpenControllerUtilities.addNegativeEngagementForDomain(this.flyoutData.common.popupOrigination,n,t),e.R.isExperimentActive(f.H.CouponsPersonalization)&&await this.autoOpenControllerUtilities.userEngagementStoreManager.addEngagement(q.w1.NEGATIVE,this.flyoutData.common.popupOrigination,this.stateManagement.getState(Ku.IY.topContextualModuleName),cy.e.userEngagementCouponWeights.dismissWeight,i.$S.NotificationDismiss)}this.flyoutData.common.popupOrigination&&this.shouldEnableTwoClickSnoozeForAllDomains(this.flyoutData.common.popupOrigination)&&await this.autoOpenControllerUtilities.addTotalNegativeEngagement(this.flyoutData.common.popupOrigination,2,288e5),this.stateManagement.dispatchEvent(new CustomEvent(Ku.e1.OnFlyoutDismissed)),a.DismissPopup()}))}shouldEnableCloseButtonSnoozeForDomain(t){const i=[u.sR.AUTO_SHOW_COUPONS_CHECKOUT,u.sR.AUTO_SHOW_REBATES_ORGANIC,u.sR.AUTO_SHOW_REBATES_CHECKOUT,u.sR.AUTO_SHOW_TRAVEL_NOTIFICATION_CHEAPER_FLIGHTS,u.sR.AUTO_SHOW_TRAVEL_NOTIFICATION_CHEAPER_HOTEL_ROOM],n=(e.R.getServiceExperimentValue(f.H.pcCloseSnooze)===Yu.sf.OneClick||e.R.getServiceExperimentValue(f.H.pcCloseSnooze)===Yu.sf.Combined)&&t===u.sR.AUTO_SHOW_LOWER_PRICE_FOUND,o=(e.R.getServiceExperimentValue(f.H.phCloseSnooze)===Yu.sf.OneClick||e.R.getServiceExperimentValue(f.H.phCloseSnooze)===Yu.sf.Combined)&&t===u.sR.AUTO_SHOW_PRICE_HISTORY,a=(e.R.getServiceExperimentValue(f.H.clipCloseSnooze)===Yu.sf.OneClick||e.R.getServiceExperimentValue(f.H.clipCloseSnooze)===Yu.sf.Combined)&&t===u.sR.AUTO_SHOW_COUPONS_CLIPPING,s=t===u.sR.AUTO_SHOW_TRAVEL_NOTIFICATION_CHEAPER_FLIGHTS||t===u.sR.AUTO_SHOW_TRAVEL_NOTIFICATION_CHEAPER_HOTEL_ROOM;return this.flyoutData.common.openedWith===r.Te.Auto&&(i.indexOf(t)>=0||n||o||a||s)}shouldEnableTwoClickSnoozeForAllDomains(t){const i=(e.R.getServiceExperimentValue(f.H.pcCloseSnooze)===Yu.sf.TwoClick||e.R.getServiceExperimentValue(f.H.pcCloseSnooze)===Yu.sf.Combined)&&t===u.sR.AUTO_SHOW_LOWER_PRICE_FOUND,n=(t===u.sR.AUTO_SHOW_REBATES_CHECKOUT||t===u.sR.AUTO_SHOW_REBATES_ORGANIC)&&e.R.isExperimentActive(f.H.cashbackCloseSnooze),o=t==u.sR.AUTO_SHOW_SPB_CASHBACK_LANDING&&(e.R.isExperimentActive(f.H.spbCloseSnooze)||e.R.isExperimentActive(f.H.spbAutoSnoozeTreatment)),a=(e.R.getServiceExperimentValue(f.H.phCloseSnooze)===Yu.sf.TwoClick||e.R.getServiceExperimentValue(f.H.phCloseSnooze)===Yu.sf.Combined)&&t===u.sR.AUTO_SHOW_PRICE_HISTORY,s=(e.R.getServiceExperimentValue(f.H.clipCloseSnooze)===Yu.sf.TwoClick||e.R.getServiceExperimentValue(f.H.clipCloseSnooze)===Yu.sf.Combined)&&t===u.sR.AUTO_SHOW_COUPONS_CLIPPING,l=(e.R.getServiceExperimentValue(f.H.aaCloseSnooze)===Yu.sf.TwoClick||e.R.getServiceExperimentValue(f.H.aaCloseSnooze)===Yu.sf.Combined)&&t===u.sR.AUTO_SHOW_COUPONS_CHECKOUT,c=e.R.isExperimentActive(f.H.autosCloseSnooze)&&t===u.sR.AUTO_SHOW_AUTOS_MARKETPLACE;return this.flyoutData.common.openedWith===r.Te.Auto&&(i||a||s||l||n||c||o)}async createContextMenu(t,i,n,o){const a=t.querySelector(`#${r.z6.MENU}`),s=t.querySelector(`#${r.z6.MENU_CONTENT}`);let l,c;if(a)l=a,s&&s.remove(),t.prepend(l),c=await this.createContextMenuDiv(n,i,t);else{l=document.createElement("fluent-button"),l.slot="header-actions",l.id=r.z6.MENU,l.ariaHaspopup="menu",l.ariaControls=r.z6.MENU_CONTENT,l.ariaLabel=this.flyoutData.strings.commonMoreOptionsLabel,l.title=this.flyoutData.strings.commonAltSettings;const e=(0,Y.Ux)("DIV");e.style.display="flex",e.style.alignContent="center",e.setAttribute("aria-hidden","true"),e.innerHTML=this.commonAssets.getMenuIcon(),l.appearance="stealth",l.appendChild(e),t.prepend(l),c=await this.createContextMenuDiv(n,i,t)}if(this.manageMenuEvents(c,l,this.stateManagement),this.handleClickOutsideMenu(o,c,l),e.R.isExperimentActive(f.H.newNotificationManagementUI)){const e=t.querySelector("#manage-notification-button");this.manageNotificationMenu&&e&&this.handleClickOutsideMenu(o,this.manageNotificationMenu,e);const i=t.querySelector("#manage-settings-button");this.manageSettingsMenu&&i&&this.handleClickOutsideMenu(o,this.manageSettingsMenu,i),this.manageNotificationMenu&&this.manageNotificationMenu.addEventListener("keydown",(e=>{"Escape"===e.key&&(this.manageNotificationMenu.className="hide",e.preventDefault(),l.setAttribute("aria-expanded","undefined"),l.focus(),e.preventDefault())})),this.manageSettingsMenu.addEventListener("keydown",(e=>{"Escape"===e.key&&(this.manageSettingsMenu.className="hide",e.preventDefault(),l.setAttribute("aria-expanded","undefined"),l.focus(),e.preventDefault())}))}gn.SO.queueUpdate((()=>{l&&l.control?.setAttribute("title",l.title)}))}addManageNotificationItem(e,n){const o=document.createElement("DIV");o.innerHTML=this.commonAssets.getRightArrowIcon(),o.slot="end",o.style.display="flex",o.style.marginRight="0",o.setAttribute("aria-hidden","true");const r=document.createElement("fluent-menu-item"),a=document.createElement("DIV");a.innerHTML=this.commonAssets.getNotificationIcon(),a.style.display="flex",a.slot="start",a.setAttribute("aria-hidden","true"),r.title=this.flyoutData.strings.commonManageNotifications,r.textContent=this.flyoutData.strings.commonManageNotifications,r.id="manage-notification-button",r.className+="defaultFontFamily",r.appendChild(a),r.appendChild(o.cloneNode(!0));try{this.manageNotificationMenu||(this.manageNotificationMenu=new FI(this.flyoutData,this.utilities,this.autoOpenControllerUtilities,this.stateManagement,this.pageHandlerModule,this.logModule,e).renderMenuModule(),n.querySelector(`#${this.manageNotificationMenu.id}`)||(n.appendChild(this.manageNotificationMenu),gn.SO.queueUpdate((()=>{this.manageNotificationMenu.setAttribute("slot","start-content")}))))}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Error creating manage notifications menu ${(0,dt.YU)(e)}`,n)}const s=t=>{this.manageNotificationMenu.classList.remove("hide"),e.classList.add("hide"),t.stopPropagation();const n=new W.Z(i.$S.ManageNotification,bp.r.MENU);this.logModule.LogInfoEvent(i.R.ButtonClick,"Manage Notification button clicked",n)};r.addEventListener("click",s),this.utilities.makeHtmlElementKeyboardClickable(r,(e=>{s(e);const t=this.manageNotificationMenu.querySelectorAll("fluent-menu-item");t?.length&&t[0].focus()})),e.appendChild(r)}addShoppingSettingsItem(e,n){const o=document.createElement("DIV");o.innerHTML=this.commonAssets.getRightArrowIcon(),o.slot="end",o.style.display="flex",o.style.marginRight="0",o.setAttribute("aria-hidden","true");const r=document.createElement("DIV");r.innerHTML=this.commonAssets.getSettingsIcon(),r.slot="start",r.style.display="flex",r.setAttribute("aria-hidden","true");const a=document.createElement("fluent-menu-item");a.title=this.flyoutData.strings.commonShoppingSettings,a.textContent=this.flyoutData.strings.commonShoppingSettings,a.id="manage-settings-button",a.className+="defaultFontFamily",a.appendChild(r),a.appendChild(o);try{this.manageSettingsMenu||((0,dt.tB)(this.flyoutData)?this.manageSettingsMenu=new HI(this.flyoutData,this.utilities,this.autoOpenControllerUtilities,this.stateManagement,this.pageHandlerModule,this.logModule,e).renderMenuModule():this.manageSettingsMenu=new UI(this.flyoutData,this.utilities,this.autoOpenControllerUtilities,this.stateManagement,this.pageHandlerModule,this.logModule,e,this.storageHandler).renderMenuModule(),n.querySelector(`#${this.manageSettingsMenu.id}`)||(n.appendChild(this.manageSettingsMenu),gn.SO.queueUpdate((()=>{this.manageSettingsMenu.setAttribute("slot","start-content")}))))}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Error creating manage settings menu ${(0,dt.YU)(e)}`,n)}const s=t=>{this.manageSettingsMenu.classList.remove("hide"),e.classList.add("hide"),t.stopPropagation();const n=new W.Z(i.$S.ShoppingSettings,bp.r.MENU);this.logModule.LogInfoEvent(i.R.ButtonClick,"Manage Settings button clicked",n)};a.addEventListener("click",s),this.utilities.makeHtmlElementKeyboardClickable(a,(e=>{s(e);const t=this.manageSettingsMenu.querySelectorAll("fluent-menu-item");t?.length&&t[0].focus()})),e.appendChild(a)}async createContextMenuDiv(n,o,a){const s=document.createElement("fluent-menu");if(s.id=r.z6.MENU_CONTENT,s.setAttribute("aria-labelledby",r.z6.MENU),this.pageHandlerModule.TriggerExperiment(f.H.newNotificationManagementUI),!await this.footerUtilities.showFooter()||this.flyoutData.common.openedWith!==r.Te.Auto||e.R.isExperimentActive(f.H.newNotificationManagementUI)){const l=this.getPopupOrigination(n);if(e.R.isExperimentActive(f.H.newNotificationManagementUI))try{(0,dt.tB)(this.flyoutData)||this.addManageNotificationItem(s,a),this.addShoppingSettingsItem(s,a)}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Error creating menu buttons ${(0,dt.YU)(e)}`,n)}else{const e=(0,dt.fr)();if(!l||e.includes(l)||(0,dt.tB)(this.flyoutData)){if(this.flyoutData.common.openedWith===r.Te.Auto){const e=new t.Z(i.xu.ContextMenuInfo);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Popup origination not valid for "+n,e)}}else this.addAutoShowItem(s,l)}if(!e.R.isExperimentActive(f.H.newNotificationManagementUI)){void 0!==this.flyoutData.common.isOrganicFlowEnabled&&o&&this.addRebatesFlow(s,this.flyoutData.common.isOrganicFlowEnabled),void 0!==this.flyoutData.common.isShoppingPersonalizationEnabled&&e.R.isExperimentActive(f.H.priceDropNotification)&&this.addReminderFlow(s,this.flyoutData.common.isShoppingPersonalizationEnabled);const t=this.flyoutData?.dataStoreModule?.OrderTrackingData?.shouldShowPackageTrackingNotification??!1,n=this.flyoutData?.dataStoreModule?.OrderTrackingData?.packageTrackingUserConsented??!1;t&&n&&this.addPackageTrackingFlow(s);const r=document.createElement("fluent-menu-item"),a=document.createElement("DIV");a.innerHTML=this.commonAssets.getSettingsIcon(),a.slot="start",a.setAttribute("aria-hidden","true"),r.title=this.flyoutData.strings.commonCMManage,r.textContent=this.flyoutData.strings.commonCMManage,r.className+="defaultFontFamily",r.appendChild(a);const c=this.pageHandlerModule,d=this.logModule;r.addEventListener("change",(()=>{c.RecordAsUserAction(K.bS.MANAGE);const e=new W.Z(i.$S.FlyoutManage,bp.r.MENU);e.Metadata=JSON.stringify({popupOriginationEnum:l}),d.LogInfoEvent(i.R.ButtonClick,"Flyout Menu Manage",e),c.NavigateToEdgeUrl("edge://settings/privacy#Shopping",ju.$.NEW_FOREGROUND_TAB)})),s.appendChild(r)}}const l=new CustomEvent(Ku.e1.CreateFeedbackModule,{detail:{callback:e=>{if(e&&e.element){try{s.querySelector("#feedbackDiv")?.remove(),s.querySelector("#menuSettingsBingPrivacy")?.remove()}catch(e){}e.element.style.background="var(--neutral-layer-floating)",e.element.setAttribute("role","menuitem"),s.appendChild(e.element),this.createBingPrivacyMesageOnMenu(s)}},wrapperHeight:0}});let c,d;this.stateManagement.dispatchEvent(l),this.flyoutData.common.currentDirection===r.m5.RTL?(c="35px",d="40px"):this.flyoutData.common.openedWith===r.Te.Auto?(c="0px",d="45px"):(c="50px",d="40px");const u=e.R.isExperimentActive(f.H.newNotificationManagementUI)?"100%":"auto";return s.style.top=d,s.style.left=c,s.style.width=u,s.tabIndex=-1,s.className="hide",this.backgroundOverlay||(this.backgroundOverlay=document.createElement("DIV"),this.backgroundOverlay.id="main-background-overlay",this.backgroundOverlay.classList.add("hide"),a.appendChild(this.backgroundOverlay)),a.appendChild(s),gn.SO.queueUpdate((()=>{s.setAttribute("slot","start-content")})),s}createBingPrivacyMesageOnMenu(e){const t=document.createElement("DIV"),i=document.createElement("SPAN");i.id="menuMessage",t.className="txtSmall",t.id="menuSettingsBingPrivacy",t.appendChild(i),i.title=this.flyoutData.strings.bingPrivacyMessage,i.textContent=this.flyoutData.strings.bingPrivacyMessage,e.appendChild(t)}addReminderFlow(e,t){if(""!==this.flyoutData.strings.reminderDisabled&&""!==this.flyoutData.strings.reminderEnabled){const n=this.flyoutData.strings.reminderEnabled,o=this.flyoutData.strings.reminderDisabled,r=document.createElement("fluent-menu-item"),a=document.createElement("DIV");t?(a.innerHTML=this.commonAssets.getDisableAutoOpen(),a.setAttribute("aria-hidden","true"),r.id="Enabled",r.className+="defaultFontFamily",r.textContent=o,r.title=o):(a.innerHTML=this.commonAssets.getEnableAutoOpen(),a.setAttribute("aria-hidden","true"),r.id="Disabled",r.className+="defaultFontFamily",r.textContent=n,r.title=n),a.slot="start",r.appendChild(a);const s=this.pageHandlerModule,l=this.logModule;r.addEventListener("change",(e=>{if("Enabled"===r.id){r.textContent=n,r.title=n,r.id="Disabled";const e=document.createElement("DIV");e.slot="start",e.innerHTML=this.commonAssets.getEnableAutoOpen(),e.setAttribute("aria-hidden","true"),r.appendChild(e);const t=new W.Z(i.$S.OrganicFlowTurnedOff,bp.r.MENU);t.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),l.LogInfoEvent(i.R.ButtonClick,"Organic flow turned off",t),s.SetIsPersonalizedShoppingEnabled(!1),s.RecordAsUserAction(K.bS.PWILO_NOTIFICATION_PRICE_DROP_DISABLE_REMINDERS),s.AllowServerDrivenNotifications(!1)}else{r.textContent=o,r.title=o,r.id="Enabled";const e=document.createElement("DIV");e.slot="start",e.innerHTML=this.commonAssets.getDisableAutoOpen(),e.setAttribute("aria-hidden","true"),r.appendChild(e);const t=new W.Z(i.$S.OrganicFlowTurnedOn,bp.r.MENU);t.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),l.LogInfoEvent(i.R.ButtonClick,"Organic flow turned on",t),s.SetIsPersonalizedShoppingEnabled(!0),s.AllowServerDrivenNotifications(!0)}e.stopPropagation()})),r.addEventListener("click",(e=>{e.stopPropagation()})),e.appendChild(r)}}addRebatesFlow(e,t){if(""!==this.flyoutData.strings.cbFindAutomatically&&""!==this.flyoutData.strings.cbDontFindAutomatically){const n=this.flyoutData.strings.cbFindAutomatically,o=this.flyoutData.strings.cbDontFindAutomatically,r=document.createElement("fluent-menu-item"),a=document.createElement("DIV");t?(a.innerHTML=this.commonAssets.getDisableAutoOpen(),a.setAttribute("aria-hidden","true"),r.id="Enabled",r.className+="defaultFontFamily",r.textContent=o,r.title=o):(a.innerHTML=this.commonAssets.getEnableAutoOpen(),a.setAttribute("aria-hidden","true"),r.id="Disabled",r.className+="defaultFontFamily",r.textContent=n,r.title=n),a.slot="start",r.appendChild(a);const s=this.pageHandlerModule,l=this.logModule;r.addEventListener("change",(e=>{if("Enabled"===r.id){r.textContent=n,r.title=n,r.id="Disabled";const e=document.createElement("DIV");e.slot="start",e.innerHTML=this.commonAssets.getEnableAutoOpen(),e.setAttribute("aria-hidden","true"),r.appendChild(e);const t=new W.Z(i.$S.OrganicFlowTurnedOff,bp.r.MENU);t.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),l.LogInfoEvent(i.R.ButtonClick,"Organic flow turned off",t),s.SetAllowOrganicRebates(!1)}else{r.textContent=o,r.title=o,r.id="Enabled";const e=document.createElement("DIV");e.slot="start",e.innerHTML=this.commonAssets.getDisableAutoOpen(),e.setAttribute("aria-hidden","true"),r.appendChild(e);const t=new W.Z(i.$S.OrganicFlowTurnedOn,bp.r.MENU);t.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),l.LogInfoEvent(i.R.ButtonClick,"Organic flow turned on",t),s.SetAllowOrganicRebates(!0)}e.stopPropagation()})),r.addEventListener("click",(e=>{e.stopPropagation()})),e.appendChild(r)}}addPackageTrackingFlow(e){const t=this.flyoutData?.strings?.disablePackageTrackingFromMenuText,n=this.flyoutData?.strings?.enablePackageTrackingFromMenuText;if((0,p.TF)(t)||(0,p.TF)(n))return;const o=document.createElement("fluent-menu-item");o.className+="defaultFontFamily",o.textContent=t,o.title=t,o.id="Disabled";const r=document.createElement("DIV");r.innerHTML=this.commonAssets.getDisableAutoOpen(),r.setAttribute("aria-hidden","true"),r.slot="start",o.appendChild(r),o.addEventListener("change",(()=>{if("Enabled"===o.id){this.pageHandlerModule.SetPackageTrackingUserConsent(!0),this.pageHandlerModule.RecordAsUserAction(K.bS.PACKAGE_TRACKING_OPT_IN),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PACKAGE_TRACKING_OPT_IN,this.flyoutData.common.popupOrigination);const e=new W.Z(i.$S.PackageTrackingOptIn,bp.r.MENU);e.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.logModule.LogInfoEvent(i.R.ButtonClick,"User enabled package tracking from menu",e),o.id="Disabled",o.textContent=t,o.title=t;const n=document.createElement("DIV");n.slot="start",n.innerHTML=this.commonAssets.getDisableAutoOpen(),n.setAttribute("aria-hidden","true"),o.appendChild(n)}else{this.pageHandlerModule.SetPackageTrackingUserConsent(!1),this.pageHandlerModule.RecordAsUserAction(K.bS.PACKAGE_TRACKING_OPT_OUT);const e=new W.Z(i.$S.PackageTrackingOptOut,bp.r.MENU);e.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination}),this.logModule.LogInfoEvent(i.R.ButtonClick,"User disabled package tracking from menu",e),o.id="Enabled",o.textContent=n,o.title=n;const t=document.createElement("DIV");t.slot="start",t.innerHTML=this.commonAssets.getEnableAutoOpen(),t.setAttribute("aria-hidden","true"),o.appendChild(t)}})),o.addEventListener("click",(e=>{e.stopPropagation()})),e.appendChild(o)}isDisableOptOutMenuActive(){if((0,dt.tB)(this.flyoutData)&&!this.flyoutData.common.isUserHadFirstExperience)return!0;if("amazon.com"===this.flyoutData?.common?.domain){this.pageHandlerModule.TriggerExperiment(f.H.showAmazonOtherSellers);const t=e.R.isExperimentActive(f.H.showAmazonOtherSellers),i=e.R.isVariantActive(f.H.showAmazonOtherSellers,Yu.UD.AS_FeatureOpt);return t&&i}return!1}};class ZI{constructor(){this._dataLength=0,this._bufferLength=0,this._state=new Int32Array(4),this._buffer=new ArrayBuffer(68),this._buffer8=new Uint8Array(this._buffer,0,68),this._buffer32=new Uint32Array(this._buffer,0,17),this.start()}static hashStr(e,t=!1){return this.onePassHasher.start().appendStr(e).end(t)}static hashAsciiStr(e,t=!1){return this.onePassHasher.start().appendAsciiStr(e).end(t)}static _hex(e){const t=ZI.hexChars,i=ZI.hexOut;let n,o,r,a;for(a=0;a<4;a+=1)for(o=8*a,n=e[a],r=0;r<8;r+=2)i[o+1+r]=t.charAt(15&n),n>>>=4,i[o+0+r]=t.charAt(15&n),n>>>=4;return i.join("")}static _md5cycle(e,t){let i=e[0],n=e[1],o=e[2],r=e[3];i+=(n&o|~n&r)+t[0]-680876936|0,i=(i<<7|i>>>25)+n|0,r+=(i&n|~i&o)+t[1]-389564586|0,r=(r<<12|r>>>20)+i|0,o+=(r&i|~r&n)+t[2]+606105819|0,o=(o<<17|o>>>15)+r|0,n+=(o&r|~o&i)+t[3]-1044525330|0,n=(n<<22|n>>>10)+o|0,i+=(n&o|~n&r)+t[4]-176418897|0,i=(i<<7|i>>>25)+n|0,r+=(i&n|~i&o)+t[5]+1200080426|0,r=(r<<12|r>>>20)+i|0,o+=(r&i|~r&n)+t[6]-1473231341|0,o=(o<<17|o>>>15)+r|0,n+=(o&r|~o&i)+t[7]-45705983|0,n=(n<<22|n>>>10)+o|0,i+=(n&o|~n&r)+t[8]+1770035416|0,i=(i<<7|i>>>25)+n|0,r+=(i&n|~i&o)+t[9]-1958414417|0,r=(r<<12|r>>>20)+i|0,o+=(r&i|~r&n)+t[10]-42063|0,o=(o<<17|o>>>15)+r|0,n+=(o&r|~o&i)+t[11]-1990404162|0,n=(n<<22|n>>>10)+o|0,i+=(n&o|~n&r)+t[12]+1804603682|0,i=(i<<7|i>>>25)+n|0,r+=(i&n|~i&o)+t[13]-40341101|0,r=(r<<12|r>>>20)+i|0,o+=(r&i|~r&n)+t[14]-1502002290|0,o=(o<<17|o>>>15)+r|0,n+=(o&r|~o&i)+t[15]+1236535329|0,n=(n<<22|n>>>10)+o|0,i+=(n&r|o&~r)+t[1]-165796510|0,i=(i<<5|i>>>27)+n|0,r+=(i&o|n&~o)+t[6]-1069501632|0,r=(r<<9|r>>>23)+i|0,o+=(r&n|i&~n)+t[11]+643717713|0,o=(o<<14|o>>>18)+r|0,n+=(o&i|r&~i)+t[0]-373897302|0,n=(n<<20|n>>>12)+o|0,i+=(n&r|o&~r)+t[5]-701558691|0,i=(i<<5|i>>>27)+n|0,r+=(i&o|n&~o)+t[10]+38016083|0,r=(r<<9|r>>>23)+i|0,o+=(r&n|i&~n)+t[15]-660478335|0,o=(o<<14|o>>>18)+r|0,n+=(o&i|r&~i)+t[4]-405537848|0,n=(n<<20|n>>>12)+o|0,i+=(n&r|o&~r)+t[9]+568446438|0,i=(i<<5|i>>>27)+n|0,r+=(i&o|n&~o)+t[14]-1019803690|0,r=(r<<9|r>>>23)+i|0,o+=(r&n|i&~n)+t[3]-187363961|0,o=(o<<14|o>>>18)+r|0,n+=(o&i|r&~i)+t[8]+1163531501|0,n=(n<<20|n>>>12)+o|0,i+=(n&r|o&~r)+t[13]-1444681467|0,i=(i<<5|i>>>27)+n|0,r+=(i&o|n&~o)+t[2]-51403784|0,r=(r<<9|r>>>23)+i|0,o+=(r&n|i&~n)+t[7]+1735328473|0,o=(o<<14|o>>>18)+r|0,n+=(o&i|r&~i)+t[12]-1926607734|0,n=(n<<20|n>>>12)+o|0,i+=(n^o^r)+t[5]-378558|0,i=(i<<4|i>>>28)+n|0,r+=(i^n^o)+t[8]-2022574463|0,r=(r<<11|r>>>21)+i|0,o+=(r^i^n)+t[11]+1839030562|0,o=(o<<16|o>>>16)+r|0,n+=(o^r^i)+t[14]-35309556|0,n=(n<<23|n>>>9)+o|0,i+=(n^o^r)+t[1]-1530992060|0,i=(i<<4|i>>>28)+n|0,r+=(i^n^o)+t[4]+1272893353|0,r=(r<<11|r>>>21)+i|0,o+=(r^i^n)+t[7]-155497632|0,o=(o<<16|o>>>16)+r|0,n+=(o^r^i)+t[10]-1094730640|0,n=(n<<23|n>>>9)+o|0,i+=(n^o^r)+t[13]+681279174|0,i=(i<<4|i>>>28)+n|0,r+=(i^n^o)+t[0]-358537222|0,r=(r<<11|r>>>21)+i|0,o+=(r^i^n)+t[3]-722521979|0,o=(o<<16|o>>>16)+r|0,n+=(o^r^i)+t[6]+76029189|0,n=(n<<23|n>>>9)+o|0,i+=(n^o^r)+t[9]-640364487|0,i=(i<<4|i>>>28)+n|0,r+=(i^n^o)+t[12]-421815835|0,r=(r<<11|r>>>21)+i|0,o+=(r^i^n)+t[15]+530742520|0,o=(o<<16|o>>>16)+r|0,n+=(o^r^i)+t[2]-995338651|0,n=(n<<23|n>>>9)+o|0,i+=(o^(n|~r))+t[0]-198630844|0,i=(i<<6|i>>>26)+n|0,r+=(n^(i|~o))+t[7]+1126891415|0,r=(r<<10|r>>>22)+i|0,o+=(i^(r|~n))+t[14]-1416354905|0,o=(o<<15|o>>>17)+r|0,n+=(r^(o|~i))+t[5]-57434055|0,n=(n<<21|n>>>11)+o|0,i+=(o^(n|~r))+t[12]+1700485571|0,i=(i<<6|i>>>26)+n|0,r+=(n^(i|~o))+t[3]-1894986606|0,r=(r<<10|r>>>22)+i|0,o+=(i^(r|~n))+t[10]-1051523|0,o=(o<<15|o>>>17)+r|0,n+=(r^(o|~i))+t[1]-2054922799|0,n=(n<<21|n>>>11)+o|0,i+=(o^(n|~r))+t[8]+1873313359|0,i=(i<<6|i>>>26)+n|0,r+=(n^(i|~o))+t[15]-30611744|0,r=(r<<10|r>>>22)+i|0,o+=(i^(r|~n))+t[6]-1560198380|0,o=(o<<15|o>>>17)+r|0,n+=(r^(o|~i))+t[13]+1309151649|0,n=(n<<21|n>>>11)+o|0,i+=(o^(n|~r))+t[4]-145523070|0,i=(i<<6|i>>>26)+n|0,r+=(n^(i|~o))+t[11]-1120210379|0,r=(r<<10|r>>>22)+i|0,o+=(i^(r|~n))+t[2]+718787259|0,o=(o<<15|o>>>17)+r|0,n+=(r^(o|~i))+t[9]-343485551|0,n=(n<<21|n>>>11)+o|0,e[0]=i+e[0]|0,e[1]=n+e[1]|0,e[2]=o+e[2]|0,e[3]=r+e[3]|0}start(){return this._dataLength=0,this._bufferLength=0,this._state.set(ZI.stateIdentity),this}appendStr(e){const t=this._buffer8,i=this._buffer32;let n,o,r=this._bufferLength;for(o=0;o<e.length;o+=1){if(n=e.charCodeAt(o),n<128)t[r++]=n;else if(n<2048)t[r++]=192+(n>>>6),t[r++]=63&n|128;else if(n<55296||n>56319)t[r++]=224+(n>>>12),t[r++]=n>>>6&63|128,t[r++]=63&n|128;else{if(n=1024*(n-55296)+(e.charCodeAt(++o)-56320)+65536,n>1114111)throw new Error("Unicode standard supports code points up to U+10FFFF");t[r++]=240+(n>>>18),t[r++]=n>>>12&63|128,t[r++]=n>>>6&63|128,t[r++]=63&n|128}r>=64&&(this._dataLength+=64,ZI._md5cycle(this._state,i),r-=64,i[0]=i[16])}return this._bufferLength=r,this}appendAsciiStr(e){const t=this._buffer8,i=this._buffer32;let n,o=this._bufferLength,r=0;for(;;){for(n=Math.min(e.length-r,64-o);n--;)t[o++]=e.charCodeAt(r++);if(o<64)break;this._dataLength+=64,ZI._md5cycle(this._state,i),o=0}return this._bufferLength=o,this}appendByteArray(e){const t=this._buffer8,i=this._buffer32;let n,o=this._bufferLength,r=0;for(;;){for(n=Math.min(e.length-r,64-o);n--;)t[o++]=e[r++];if(o<64)break;this._dataLength+=64,ZI._md5cycle(this._state,i),o=0}return this._bufferLength=o,this}getState(){const e=this._state;return{buffer:String.fromCharCode.apply(null,Array.from(this._buffer8)),buflen:this._bufferLength,length:this._dataLength,state:[e[0],e[1],e[2],e[3]]}}setState(e){const t=e.buffer,i=e.state,n=this._state;let o;for(this._dataLength=e.length,this._bufferLength=e.buflen,n[0]=i[0],n[1]=i[1],n[2]=i[2],n[3]=i[3],o=0;o<t.length;o+=1)this._buffer8[o]=t.charCodeAt(o)}end(e=!1){const t=this._bufferLength,i=this._buffer8,n=this._buffer32,o=1+(t>>2);this._dataLength+=t;const r=8*this._dataLength;if(i[t]=128,i[t+1]=i[t+2]=i[t+3]=0,n.set(ZI.buffer32Identity.subarray(o),o),t>55&&(ZI._md5cycle(this._state,n),n.set(ZI.buffer32Identity)),r<=4294967295)n[14]=r;else{const e=r.toString(16).match(/(.*?)(.{0,8})$/);if(null===e)return;const t=parseInt(e[2],16),i=parseInt(e[1],16)||0;n[14]=t,n[15]=i}return ZI._md5cycle(this._state,n),e?this._state:ZI._hex(this._state)}}if(ZI.stateIdentity=new Int32Array([1732584193,-271733879,-1732584194,271733878]),ZI.buffer32Identity=new Int32Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),ZI.hexChars="0123456789abcdef",ZI.hexOut=[],ZI.onePassHasher=new ZI,"5d41402abc4b2a76b9719d911017c592"!==ZI.hashStr("hello"))throw new Error("Md5 self test failed.");var VI=class{static updateRankingSetWithProductSummaryCardOnTop(e){const t=e.findIndex((e=>e.name===r.ModuleNames.PRODUCTSUMMARYCARD));if(-1!==t){const i=e[t];i.priority=0,e.splice(t,1),e.unshift(i)}return e}constructor(e,t,i){(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"storageHandler",void 0),this.flyoutData=e,this.utilities=t,this.stateManagement=i,this.pageHandlerModule=t.pageHandlerModule,this.logModule=t.logModule,this.storageHandler=t.storageHandler}async GetFeaturesPriorities(t,i){const n=new gS.Z(this.flyoutData.common.openedWith,this.flyoutData.dataStoreModule.PriceComparisonData?.CompetingPrices,this.flyoutData.dataStoreModule.PriceComparisonData?.Price,this.flyoutData.common.popupOrigination,this.flyoutData.common.pageLocale),o=n?.shouldBeInPolePosition,a=i.get(r.ModuleNames.COUPONCLIPPING),s=i.get(r.ModuleNames.COUPON),l=i.get(r.ModuleNames.EMPTYCOUPON),c=i.get(r.ModuleNames.PRICEHISTORY),d=i.get(r.ModuleNames.PRODUCTSUMMARYCARD),u=i.get(r.ModuleNames.PRICECOMPARISON),p=i.get(r.ModuleNames.SIMILAR_OFFERS),g=i.get(r.ModuleNames.VISUAL_SEARCH),m=i.get(r.ModuleNames.RELATED_PRODUCTS),v=i.get(r.ModuleNames.CASHBACK),y=i.get(r.ModuleNames.CASHBACK_ACTIVATE),C=i.get(r.ModuleNames.CASHBACK_DELAYED_ENROLLMENT),b=i.get(r.ModuleNames.REWARD),S=i.get(r.ModuleNames.SIMILARSELLERS),x=i.get(r.ModuleNames.AUTOSMARKETPLACE),T=i.get(r.ModuleNames.AUTOSMYGARAGE),w=i.get(r.ModuleNames.GROCERY_CASHBACK),O=i.get(r.ModuleNames.ITEMIZED_CASHBACK),P=i.get(r.ModuleNames.GROCERY_CASHBACK_PENDING),A=i.get(r.ModuleNames.PRINTABLE_COUPON),E=i.get(r.ModuleNames.ORDERSTATUSTRACKING),k=i.get(r.ModuleNames.PRODUCTHISTORY),I=i.get(r.ModuleNames.PRODUCT_COLLECTIONS),D=i.get(r.ModuleNames.SHOPPING_TRIPS),_=i.get(r.ModuleNames.INBOX_COUPONS),N=i.get(r.ModuleNames.AUTOSREVIEWS),R=i.get(r.ModuleNames.PRODUCT_TRACKING_OUT_OF_STOCK),M=i.get(r.ModuleNames.PRODUCT_TRACKING_PRICE_DROP),L=i.get(r.ModuleNames.RECOMMENDATIONS),B=i.get(r.ModuleNames.SOCIALCOUPONS),F=i.get(r.ModuleNames.DISCOVER_CHAT_CHIPS),U=i.get(r.ModuleNames.SAN_CONSENT),H=i.get(r.ModuleNames.CAMPAIGN_PDP_CASHBACK),$=i.get(r.ModuleNames.CAMPAIGN_BANNER),Z=i.get(r.ModuleNames.FEED_CAMPAIGN);if(this.pageHandlerModule.TriggerExperiment(f.H.dynamicRanking),e.R.isExperimentActive(f.H.dynamicRanking)&&this.flyoutData.common.isPane&&("true"===(0,h.Mw)("isPDP")||void 0!==a||void 0!==c||void 0!==u||void 0!==d)&&this.setDynamicRanking(t,i))return;const V=void 0!==b&&t[b].moduleInterface.isRewardsAdded(),G=this.flyoutData.dataStoreModule.ApiData?.retailerData?.GetCurrentCheckoutPage(this.flyoutData.common.lastCommittedURL),j=!(!this.flyoutData.dataStoreModule.CouponData?.isCheckoutPageWithAutoApply||G?.isHomePageSameAsCheckout)||await this.isCheckoutPage(G),z=this.flyoutData.dataStoreModule.CashBackData?.isCashBackActivated??!1;if(void 0===$||this.flyoutData.dataStoreModule.CouponData?.isCheckoutPageWithAutoApply)if(void 0!==U)t[U].priority=0;else if(void 0!==s&&j&&void 0===l)t[s].priority=0;else if(void 0!==L&&"true"===(0,h.Mw)(tt.d1))t[L].priority=0,(0,h.TJ)(tt.d1);else if(void 0===b||void 0===y||z||V)if(void 0===b||void 0===C||z||V)if(void 0===b||void 0===v||z||V)if(void 0!==B)t[B].priority=0;else if(this.isPDP(i)){const i=this.flyoutData.dataStoreModule.SPBItemizedCashbackData?.SpbPDPData&&(this.flyoutData.dataStoreModule.SPBItemizedCashbackData.SpbPDPData.ItemizedCashbackExactMatch||this.flyoutData.dataStoreModule.SPBItemizedCashbackData.SpbPDPData.RelatedOffers.length>0);e.R.isExperimentActive(f.H.ptConciseUi)&&void 0!==R?t[R].priority=0:e.R.isExperimentActive(f.H.ptConciseUi)&&void 0!==M?t[M].priority=0:i&&void 0!==O?t[O].priority=0:void 0!==v&&(this.stateManagement.getState(Ku.IY.pdpForActivatedAd)||this.flyoutData.dataStoreModule.CashBackData?.estimatedCashbackData?.isPdp)?t[v].priority=0:this.stateManagement.getState(Ku.IY.icPdpAvailable)&&void 0!==w?t[w].priority=0:void 0!==a?(t[a].priority=0,void 0!==s&&(t[s].priority=r.H7.MAX),void 0!==l&&(t[l].priority=r.H7.MAX)):void 0===c||o||t[c].priority===r.H7.MAX?void 0===u||void 0!==c&&!o||t[u].priority===r.H7.MAX||t[u].priority===r.H7.CJK_PRICECOMPARISON||(t[u].priority=0):(t[c].priority=0,e.R.isExperimentActive(f.H.ptConciseUi)||void 0===R?e.R.isExperimentActive(f.H.ptConciseUi)||void 0===M||(t[M].priority=.01):t[R].priority=.01)}else if(void 0===y||z&&(!this.utilities.viewModulesUtilities.isPinterest()||z))if(void 0===C||z&&(!this.utilities.viewModulesUtilities.isPinterest()||z))if(void 0!==v&&(this.flyoutData.dataStoreModule.CashBackData?.activateRebatesStatus===r.FA.PENDING_SWITCH_TO_MSA_PROFILE||this.flyoutData.dataStoreModule.CashBackData?.isSignInSupportedDomainCashBack||!z||this.utilities.viewModulesUtilities.isPinterest()&&!z))t[v].priority=0;else if(void 0!==x||void 0!==T){const i=e.R.isExperimentActive(f.H.autosMyGarageEntryPoint)||e.R.isExperimentActive(f.H.autosMyGarageEntryPointV2)||e.R.isExperimentActive(f.H.autosMarketValueV2);this.flyoutData.dataStoreModule.AutosData?.isAutosSupportedDomain&&(i&&void 0!==T&&(t[T].priority=0),void 0!==x&&(t[x].priority=.05),void 0!==N&&(t[N].priority=.1))}else void 0!==O?t[O].priority=0:void 0!==L&&"searchBasedSuggestions"===t[L].element?.className?t[L].priority=0:z&&void 0!==v&&(t[v].priority=0);else t[C].priority=0;else t[y].priority=0;else t[b].priority=0,t[v].priority=.5;else t[b].priority=0,t[C].priority=.5;else t[b].priority=0,t[y].priority=.5;else void 0!==H&&void 0!==y&&this.flyoutData.dataStoreModule.CampaignData?.retailerData?(t[H].priority=0,t[y].priority=.1,t[$].priority=.2):void 0!==H&&void 0!==C&&this.flyoutData.dataStoreModule.CampaignData?.retailerData?(t[H].priority=0,t[C].priority=.1,t[$].priority=.2):void 0!==H&&void 0!==v&&this.flyoutData.dataStoreModule.CampaignData?.retailerData?(t[H].priority=0,t[v].priority=.1,t[$].priority=.2):void 0!==H?(t[H].priority=0,t[$].priority=.1):void 0!==y&&this.flyoutData.dataStoreModule.CampaignData?.retailerData?(t[y].priority=0,t[$].priority=.1):void 0!==C&&this.flyoutData.dataStoreModule.CampaignData?.retailerData?(t[C].priority=0,t[$].priority=.1):void 0!==v&&this.flyoutData.dataStoreModule.CampaignData?.retailerData?(t[v].priority=0,t[$].priority=.1):t[$].priority=0;this.flyoutData.common.isPane&&(void 0!==Z?t[Z].priority=0:void 0!==_&&e.R.isExperimentActive(f.H.shorelineinboxcoupons)&&this.pageHandlerModule.IsMessageAllowed("getEdgeAnid")?(await this.pageHandlerModule.GetEdgeAnid(!0))?.anid&&((await this.pageHandlerModule.GetStorageValue(Ce.Q.InboxCouponsUserConsented))?.value?.stringValue??"")===tt.oL||(void 0!==I?0===(this.flyoutData.dataStoreModule.ProductHistoryData?.length??0)?void 0!==D?(t[D].priority=0,t[_].priority=t[D].priority+.1):t[_].priority=0:t[_].priority=t[I].priority+.5:void 0!==D?(t[D].priority=0,t[_].priority=t[D].priority+.1):t[_].priority=0):void 0!==E?t[E].priority=0:void 0!==k&&void 0===B&&(t[k].priority=0));const W=w?t[w].priority:-1,K=P?t[P].priority:-1;if("target.com"===this.flyoutData.common.domain&&void 0!==A&&(W>0||K>0)&&(t[A].priority=r.H7.GROCERY_CASHBACK_PENDING+.1),this.stateManagement.getState(Ku.IY.nonICPDP)&&!this.stateManagement.getState(Ku.IY.ICRelatedOffersExist)&&void 0!==w&&(t[w].priority=r.H7.GROCERY_DIFFERENT_PRODUCT),void 0!==F){const i=t.filter((e=>e.name!==r.ModuleNames.DISCOVER_CHAT_CHIPS&&e.paneTab===r.$k.CONTEXTUAL)).map((e=>e.priority)).sort(((e,t)=>e-t));if(e.R.isExperimentActive(f.H.discoverChatChips)){const n=e.R.getServiceExperimentValue(f.H.discoverChatChips);i.length>0&&(n&&i[1]&&n===Yu.LR.third?t[F].priority=i[1]+.001:n===Yu.LR.second&&(t[F].priority=i[0]+.001))}}this.isPDP(i)&&(void 0!==C&&0!==t[C].priority&&(t[C].priority=.6),void 0!==y&&0!==t[y].priority&&(t[y].priority=.6),void 0!==v&&0!==t[v].priority&&(this.flyoutData.dataStoreModule.CashBackData?.isSpbActivated?t[v].priority=.1:t[v].priority=.6),void 0!==c&&0!==t[c].priority&&t[c].priority!==r.H7.MAX&&(this.flyoutData.dataStoreModule.PriceHistoryData?.getPriceHistoryType()===de.sh.PRICEDROP?t[c].priority=.2:t[c].priority=.7),e.R.isExperimentActive(f.H.ptConciseUi)||(void 0!==R&&(t[R].priority=.3),void 0!==M&&(t[M].priority=.3)),void 0!==u&&0!==t[u].priority&&t[u].priority!==r.H7.MAX&&(t[u].priority=.4),void 0!==S&&0!==t[S].priority&&(t[S].priority=.5),void 0!==g&&(t[g].priority=.6),void 0!==p&&(t[p].priority=.6),void 0!==m&&(t[m].priority=.7))}setDynamicRanking(e,n){try{let t=new ZI;const i=new Date,o=this.flyoutData.common.muid+i.getFullYear()+i.getMonth()+i.getDay();let a;const s=Object.getOwnPropertyNames(r.ModuleNames);for(let i=0;i<s.length;i++){t=new ZI,t.appendStr(o),t.appendStr(i.toString()),a=t.end(!1)?.toString();const l=n.get(s[i]);a&&void 0!==l&&e[l].paneTab===r.$k.CONTEXTUAL&&(e[l].priority=parseInt(a,16)%s.length/100)}return!0}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);return this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`error when creating dynamic ranking ${(0,dt.YU)(e)}`,n),!1}}isPDP(e){const t=e.get(r.ModuleNames.COUPONCLIPPING),i=e.get(r.ModuleNames.PRICEHISTORY),n=e.get(r.ModuleNames.PRICECOMPARISON),o=e.get(r.ModuleNames.SIMILAR_OFFERS),a=e.get(r.ModuleNames.GROCERY_CASHBACK),s=e.get(r.ModuleNames.ITEMIZED_CASHBACK),l=e.get(r.ModuleNames.SIMILARSELLERS);return!this.flyoutData.dataStoreModule.CouponData?.isCheckoutPageWithAutoApply&&(this.flyoutData.common.seeInfoFromPCNotification||"true"===(0,h.Mw)("isPDP")||this.stateManagement.getState(Ku.IY.pdpForActivatedAd)||void 0!==t||void 0!==i||void 0!==n||void 0!==o||void 0!==l||void 0!==a||void 0!==s)}async isCheckoutPage(e){if(!this.flyoutData.dataStoreModule.CouponData?.isCheckoutPageWithAutoApply||!e?.isHomePageSameAsCheckout)return!1;const t=await this.storageHandler.getStorageString("CartValues");let i=-1;if(!(0,p.TF)(t))try{const e=this.flyoutData.common.domain,n=JSON.parse(t),o=n?n[e]:void 0,r=o?.cartValue;i=r?.OrderTotal??-1}catch(e){}return i>0??!1}};class GI{static GetImpressionType(e){return GI.couponImpressionIdModules.has(e)?Jl.g.CouponImpressionId:Jl.g.EdgeImpressionId}static TrackVisibilityForNotification(e,t){const i=t.sendCTRLog.bind(t,e,0,this.GetImpressionType(e.name),!0,"");new IntersectionObserver(GI.HandleIntersection.bind(null,i)).observe(e.element)}static TrackVisibilityForModules(e,t,i){const n=new Map;for(const t of e)n.has(t.paneTab)||n.set(t.paneTab,[]),n.get(t.paneTab)?.push(t);for(const[e,o]of n)GI.TrackVisibilityForTab(o,e,t,i)}static TrackVisibilityForTab(e,t,i,n){this.paneObservers.get(t)?.forEach((e=>e.disconnect()));const o=e.map(((e,t)=>{const o=n.sendCTRLog.bind(n,e,t,this.GetImpressionType(e.name),!1,i),r=new IntersectionObserver(GI.HandleIntersection.bind(null,o));return r.observe(e.element),r}));this.paneObservers.set(t,o)}static HandleIntersection(e,t,i){!t||t.length<1||t.some((e=>e.isIntersecting))&&(i.disconnect(),e())}}(0,s.Z)(GI,"couponImpressionIdModules",new Set([r.ModuleNames.COUPON,r.ModuleNames.CASHBACK,r.ModuleNames.COUPONCLIPPING,r.ModuleNames.DEALS,r.ModuleNames.EMPTYCOUPON,r.ModuleNames.REWARD])),(0,s.Z)(GI,"paneObservers",new Map);const jI="AOPCooldownTimeStamp",zI="bngshp",WI="AOPDismissTimeStamp",KI="AOPTimerTimeStamp",qI="AOPTriggerTimeStamp",YI=[r.ModuleNames.COUPON,r.ModuleNames.CASHBACK,r.ModuleNames.PRICECOMPARISON,r.ModuleNames.PRICEHISTORY,r.ModuleNames.USER_INSIGHTS];function XI(n,o,r,a){if(!e.R.isExperimentActive(f.H.autoOpenPaneScenariosActive))return!1;const s=function(e){if(e?.length>0)for(const t of e)try{const e=new URL(t).searchParams.get(zI);if(null!==e)return e}catch(e){}return""}(function(e){return e.dataLoader.GetLoadTimeDataValue("bingRedirectChainForInitialDomainNavigation",[])}(n)),l=new Date;!function(e,n,o,r){const a=(0,h.Mw)(qI),s=(0,h.Mw)(KI);if(a&&null==s){const s=(0,h.Mw)(WI);if((0,h.TJ)(qI),(0,h.TJ)(KI),null==s){(0,h.Xo)(WI,a);const e={popupOrigination:n.common.popupOrigination,userScenario:o},s=new t.Z(i.xu.AOPUserDsat,void 0,void 0,n.common.domain,JSON.stringify(e));return void r.LogInfoEvent(i.R.EdgeFlyoutStatus,"AOP::User commited DSAT in previous session by closing pane within 10 seconds",s)}const l=new Date(s);(0,h.TJ)(WI),e.getTime()-l.getTime()<864e5&&function(e,n,o){(0,h.Xo)(jI,(new Date).toString());const r={popupOrigination:e.common.popupOrigination,userScenario:n},a=new t.Z(i.xu.AOPUserDsat,void 0,void 0,e.common.domain,JSON.stringify(r));o.LogInfoEvent(i.R.EdgeFlyoutStatus,"AOP::7 day cooldown set due to two consecutive DSATs within 24 hours",a)}(n,o,r)}}(l,n,s,a);const c=!!s&&!function(e){const t=(0,h.Mw)(jI);if(null==t)return!1;try{const i=6048e5,n=new Date(t);if(e.getTime()-n.getTime()<i)return!0}catch{return!1}return!1}(l)&&function(e,t){const i=!!e.common.extractedEntity,n=function(e){const t=e.filter((async e=>YI.includes(e.GetModuleName())&&await e.ShouldRenderModule()));return t}(t);return i&&n.length>1}(n,o);return!!c&&function(e,n,o,r,a){if(r.OpenPane(e.common.popupOrigination)){(0,h.Ev)("aopTriggered",{currentUrl:e.common.currentUrl,timestamp:n.toString()});const r={popupOrigination:e.common.popupOrigination,userScenario:o},s=new t.Z(i.xu.PaneAutoOpened,void 0,void 0,e.common.domain,JSON.stringify(r));return a.LogInfoEvent(i.R.EdgeFlyoutStatus,"AOP::Pane auto opened instead of notification",s),!0}return!1}(n,l,s,r,a)}var JI=class{constructor(e,t,i,n,o,a,l){(0,s.Z)(this,"availableModules",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"viewModules",void 0),(0,s.Z)(this,"bannerModule",void 0),(0,s.Z)(this,"notificationModules",void 0),(0,s.Z)(this,"bingShoppingCampaignGuid",void 0),(0,s.Z)(this,"discoverTelemetryHandler",void 0),(0,s.Z)(this,"modulesGroups",new Set([new Set([r.ModuleNames.VIRTUAL_CARD,r.ModuleNames.FEEDBACK])])),(0,s.Z)(this,"currentModulesGroup",new Set([])),(0,s.Z)(this,"isExclusiveModule",((e,t)=>t.has(e))),(0,s.Z)(this,"isInCurrentModuleGroup",(e=>!(this.currentModulesGroup.size>0)||this.currentModulesGroup.has(e))),(0,s.Z)(this,"updateModuleGroup",(e=>{if(!(this.currentModulesGroup.size>0))for(const t of this.modulesGroups)t?.values()?.next()?.value===e&&(this.currentModulesGroup=t)})),this.stateManagement=e,this.stateManagement.addEventListener(Ku.e1.CreateModules,(e=>{e&&e.detail&&e.detail.flyoutWrapper&&this.createModules(e.detail.flyoutWrapper)})),this.utilities=i,this.pageHandlerModule=i.pageHandlerModule,this.logModule=i.logModule,this.discoverTelemetryHandler=i.discoverTelemetryHandler,this.flyoutData=t,this.viewModules=o,this.bannerModule=l,this.notificationModules=a,this.commonAssets=n,this.stateManagement.addEventListener(Ku.e1.pdpEligibility,(e=>{e&&e.detail&&void 0!==e.detail.pdpElegibility&&(0,h.Xo)("isPDP",e.detail.pdpElegibility)}))}async createModules(e){if(e){this.addEventsListeners(e);let n,o=[],a=!1;if(this.notificationModules&&this.notificationModules.length>0&&(this.flyoutData.common.openedWith===r.Te.Auto||this.flyoutData.common.openedWith===r.Te.Hover)){const o=new Map,r=performance.now();for(const e of this.notificationModules)try{const r=performance.now();if(await e.ShouldRenderNotification()){let s;s=await e.RenderNotification(this.flyoutData.common.shopping),s&&GI.TrackVisibilityForNotification(s,this.utilities.telemetryHandler),a=!0,n=s||void 0,this.handleNotificationRendering(e,s,r,o);const l=s?.moduleInterface.GetPopupOriginationList();if(this.flyoutData.common.popupOrigination&&l&&-1===l.indexOf(this.flyoutData.common.popupOrigination)){const e={renderedModule:s?.name,popupOrigination:this.flyoutData.common.popupOrigination},n=new t.Z(i.xu.PopupMismatch,void 0,void 0,this.flyoutData.common.domain,JSON.stringify(e));this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"",n)}if(!this.flyoutData.common.isCJKEnabled)break}else{const t=performance.now();o.set(`${e.GetNotificationName()}`,new xI(t-r,!1))}}catch(n){const o=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Module Notification Exception: ${e.GetNotificationName()} ${(0,dt.YU)(n)}`,o)}const s=performance.now();if(this.logViewModulePerf(o,s-r),a){if(XI(this.flyoutData,this.viewModules,this.utilities.pageHandlerModule,this.logModule))return;try{new $I(this.flyoutData,this.utilities,this.pageHandlerModule,this.logModule,this.stateManagement).createFlyoutButtons(this.flyoutData.common.shopping,!0,e)}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Error creating flyout buttons ${(0,dt.YU)(e)}`,n)}}}const s=!(a&&n||this.flyoutData.common.openedWith!==r.Te.Auto||!this.flyoutData.common.popupOrigination);if(s){const o=this.flyoutData.dataLoader.GetLoadTimeDataValue(l.a.CouponsApiResponse,""),r={apiResponseLength:o?.length,pageUrl:this.flyoutData.common.lastCommittedURL,isNotification:a,renderedNotificationModule:!!n,popupOrigination:this.flyoutData.common.popupOrigination},s=new t.Z(i.xu.NotificationModuleRequired,void 0,void 0,void 0,JSON.stringify(r));this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,`${this.flyoutData.common.popupOrigination}`,s),this.utilities.viewModulesUtilities.applyStyles(e,this.commonAssets.getFallbackNotificationRequiredCssStyles())}let c="";if(!a){if(o=await this.GetRenderedModules(),o&&o.length>0){if(this.stateManagement.setState(Ku.IY.topModuleName,o[0].name),this.flyoutData.common.isDiscoverPane)o?.length>0&&(c=o[0]?.name);else{const e=o.filter((e=>e.paneTab===r.$k.CONTEXTUAL));e&&e.length>0&&(c=e[0]?.name)}this.stateManagement.setState(Ku.IY.topContextualModuleName,c),this.stateManagement.setState(Ku.IY.topModulePriority,o[0].priority)}if(this.flyoutData.common.shouldShowBanner)try{if(this.bannerModule)try{this.bannerModule.renderBanner()}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Banner Exception: ${(0,dt.YU)(e)}`,n)}}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Module Exception: Banner ${(0,dt.YU)(e)}`,n)}else this.renderModules(o,e)}if(this.utilities.viewModulesUtilities.isPinterest())try{const n=new t.Z(i.xu.PinterestEngagement);e.addEventListener(Ku.e1.ClientAction,(e=>{e?.detail&&e.detail.enum&&this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,`Sent client action ${e.detail.enum}`,n)})),e.addEventListener(Ku.e1.ClientEngagement,(e=>{e?.detail&&e.detail.enum&&this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,`Sent client engagement ${e.detail.enum}`,n)}))}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Failed to send Pinterest telemetry ${(0,dt.YU)(e)}`,n)}if(s?this.pageHandlerModule.DismissPopup():this.addingShoppingComponentToFlyout(e,o,n,a),n?.name===r.sM.PRICEHISTORY||c===r.ModuleNames.PRICEHISTORY||o[0]?.name===r.ModuleNames.PRICEHISTORY){const e=document.getElementById("incentiveCampaignBannerId");e&&(e.style.display="none")}try{$C.initStorageValues(this.pageHandlerModule,this.flyoutData)}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Failed to init IBX storage values ${(0,dt.YU)(e)}`,n)}}}appendContentToFlyout(e){try{e&&this.flyoutData.common.shopping&&e.appendChild(this.flyoutData.common.shopping)}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Error appending content to flyout ${e}`,n)}}async RenderModulesCommon(e,n=!0){let o=[];const r=new Map,a=new Map,s=performance.now();for(const n of e){let e=!1;try{const t=performance.now();if(await n.ShouldRenderModule()){e=!0;const t=await n.renderModule();t&&this.isInCurrentModuleGroup(t.name)&&(o.push(t),this.stateManagement.setState(Ku.IY.renderedViewModuleCount,this.stateManagement.getState(Ku.IY.renderedViewModuleCount)+1),r.set(t.name,o.length-1),this.updateModuleGroup(t.name))}const i=performance.now();a.set(`${n.GetModuleName()}`,new xI(i-t,e))}catch(e){const o=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Module Exception: ${n.GetModuleName()} ${(0,dt.YU)(e)}`,o,GI.GetImpressionType(n.GetModuleName()))}}const l=performance.now();return await new VI(this.flyoutData,this.utilities,this.stateManagement).GetFeaturesPriorities(o,r),o.sort(((e,t)=>e.priority-t.priority)),o=VI.updateRankingSetWithProductSummaryCardOnTop(o),this.stateManagement.setState(Ku.IY.renderedModules,o),n&&this.logViewModulePerf(a,l-s),o}async GetRenderedModules(e=!0,n){let o=[];this.stateManagement.setState(Ku.IY.renderedViewModuleCount,0);let r=this.viewModules;!e&&n&&(o=this.stateManagement.getState(Ku.IY.renderedModules).filter((e=>!n?.includes(e.name))),r=this.viewModules.filter((e=>n?.includes(e.GetModuleName())))),this.flyoutData.common.isDiscoverPane&&(r=this.viewModules.filter((e=>e?.GetModuleName()===this.flyoutData.common?.viewModulesInDiscoverPane?.[0]))),o=await this.RenderModulesCommon(r,e);const a=this.flyoutData.dataLoader.GetLoadTimeDataValue("url",void 0);try{this.bingShoppingCampaignGuid=new URL(a).searchParams.get("bing_shopping_campaign_guid")||""}catch(e){}if(this.flyoutData.common.isDiscoverPane&&o.length>0){const e=void 0;let n,r;if(this.flyoutData.common.viewModulesInDiscoverPane?.length>0&&(r=this.flyoutData.common.viewModulesInDiscoverPane[0]),r){const e=o.find((e=>e.name===r));e&&(n=e)}const a=n||e;if(n)this.discoverTelemetryHandler.LogRendeInfoTelemetry("Rendering module as iframe",r);else{let n="Requested module cannot be shown: unknown reason";if(n=0===this.flyoutData.common.viewModulesInDiscoverPane?.length?"Requested module cannot be shown: empty viewModules array":r?this.viewModules.find((e=>e.GetModuleName()===r))?"Requested module cannot be shown: requested module cannot render":"Requested module cannot be shown: requested module not supported":"Requested module cannot be shown: module name is undefined or empty",e){const e=new t.Z(i.xu.DiscoverPaneInfo);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Show default discover module",e)}else this.pageHandlerModule.ResizeIframe({offsetHeight:0,offsetWidth:0,scrollHeight:0});this.discoverTelemetryHandler.LogRenderErrorTelemetry(n,r)}return a?[a]:[]}return this.flyoutData.common.isDiscoverPane&&this.discoverTelemetryHandler.LogRenderErrorTelemetry("Requested module cannot be shown: no valid renderedViewModules",void 0),o}hideModule(e,t){return(this.flyoutData.common.openedWith===r.Te.Auto||this.flyoutData.common.openedWith===r.Te.Hover)&&e>0&&!this.flyoutData.common.seeInfoFromPCNotification&&!t.moduleInterface.ShowAlways()}isStoryBookSection(e){return e.classList.contains("isStoryBook")&&!e.classList.contains("isPolePositionStory")}handleFlyoutFocus(e,t,i,n){if(this.flyoutData.common.currentDevice===r.AS.Desktop)if("true"===(0,h.Mw)("trendingRecOpen")&&e&&e.length>0){(0,h.Xo)("trendingRecOpen","false");for(const t of e)if(t.name===r.ModuleNames.RECOMMENDATIONS){const e=t.element.querySelectorAll(TI.y);if(e&&e.length>0){e[0].focus();break}}}else if(i&&(this.flyoutData.common.openedWith===r.Te.Keyboard||n)){const o=i.querySelectorAll("[slot=actions]");if(o&&o.length>0)if("DIV"===o[0].nodeName){const e=o[0].querySelectorAll(TI.y);e&&e.length>0&&e[0].focus()}else o[0].focus();else if(t){let e=TI.y;n&&(e=e.replace("msft-shopping-tooltip, ",""));const i=t.element?.querySelectorAll(e);i&&i.length>0&&i[0].focus()}else if(e&&e.length>0)for(const t of e){const e=t.element.querySelectorAll(TI.y);if(e&&e.length>0){e[0].focus();break}}}}logViewModulePerf(e,n){try{const t=JSON.stringify(e,x.ZP.StringifyMap),o=new z(this.flyoutData.common.domain,n,this.flyoutData.common.isPane?"pane":"flyout",t,G.RenderTime);this.logModule.LogInfoEvent(i.R.RenderTimeBreakDown,"",o)}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`error logging module perf time ${e}`,n)}}setSectionExpandedState(e,t,i,n,o){const a=this.flyoutData.dataStoreModule.CashBackData,s=a?.isCashBackActivated??null;0===e?t.element.expanded=!0:t.name!==r.ModuleNames.PRICECOMPARISON||!this.flyoutData.common.foundLowerPrice&&this.flyoutData.common.bannerContext!==r.De.VIEWALLPC||i||n===r.Bl.PRICEHISTORY?t.name===r.ModuleNames.PRICEHISTORY&&this.flyoutData.common.bannerContext===r.De.VIEWPRICEHISTORY&&n!==r.Bl.PRICECOMPARISON||1===e&&t.name===r.ModuleNames.CASHBACK&&o[0].name===r.ModuleNames.REWARD&&!1===s?t.element.expanded=!0:t.element.expanded=!1:t.element.expanded=!0,t.element.expanded&&!(e>0)||"none"!==t.element?.style.display||this.hideModule(e,t)||this.utilities.viewModulesUtilities.addSectionSeparator(this.flyoutData.common.shopping)}getModuleByName(e){if(this.viewModules&&this.viewModules.length>0)for(const t of this.viewModules)if(t.GetModuleName()===e)return t;return null}setTitle(e){if(e){if(e.name===r.ModuleNames.EMPTYCOUPON)return;try{const t=this.flyoutData.common.shopping.querySelectorAll('[slot="header-content"]');(!t||t&&0===t.length)&&e.moduleInterface.populateMainHeader()}catch(n){const o=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Populate Header Exception: ${e.name} ${(0,dt.YU)(n)}`,o,GI.GetImpressionType(e.name))}}}calculateScrollBarWidth(){try{const e=document.createElement("div");e.style.visibility="hidden",e.style.overflow="scroll",document.body.appendChild(e);const t=document.createElement("div");e.appendChild(t);const i=e.offsetWidth-t.offsetWidth;return document.body.removeChild(e),i}catch(e){const n=new t.Z(i.xu.ScrollbarWidthError);return n.Metadata=e,this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,"Failed to calculate scrollbar width",n),17}}addingShoppingComponentToFlyout(n,o,a,l){if((!this.flyoutData.common.shouldShowBanner||!this.bannerModule)&&(o.length>0||l)){if(this.appendContentToFlyout(n),this.flyoutData.common.isPane||gn.SO.queueUpdate((()=>{this.handleFlyoutFocus(o,a,this.flyoutData.common.shopping,!1);let e=!1;window.addEventListener("message",(t=>{"setFocus"!==t?.data?.type||e||(e=!0,this.handleFlyoutFocus(o,a,this.flyoutData.common.shopping,!0))}))})),e.R.isExperimentActive(f.H.incentiveCampaign)){const n=new class{constructor(e,t,i,n){(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"incentiveCampaignData",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"landingPageUrl","https://www.microsoft.com/"),(0,s.Z)(this,"logModule",void 0),this.utilities=e.viewModulesUtilities,this.flyoutData=t,this.assets=new class{getStyles(){return`\n #actionDone {\n fill: url(#actionDoneFill);\n }\n #correctActionDone {\n stroke: #FFFFFF;\n stroke-width: 1.5px;\n fill: none;\n }\n #actionToDo {\n stroke: url(#actionToDoStroke);\n stroke-width: 2px;\n fill: none;\n }\n #pinkStar {\n fill : #EE7DD5;\n }\n #blueStar {\n fill : #54C6F3;\n }\n .spanCorrect {\n margin-left: -10px;\n margin-top: 3px;\n display: flex;\n }\n .spanActionDone {\n display: flex;\n }\n .iconPinkStar {\n margin-top: 12px;\n margin-right: 13px;\n }\n .iconBlueStarUp {\n margin-left: -1px;\n margin-top: -8px;\n }\n .iconBlueStarDown {\n margin-left: 16px;\n }\n .iconActionDone {\n width: 12px;\n height: 12px;\n display: flex;\n margin-left: 6px;\n }\n .iconActionToDo {\n width: 12px;\n height: 12px;\n display: flex;\n margin-left: 6px;\n align-items: center;\n }\n .spanRewardClaimText {\n width: auto;\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-style: normal;\n font-weight: 600;\n font-size: 12px;\n line-height: 16px;\n\n display: flex;\n align-items: center;\n\n color: var(--text-normal);\n }\n .spanRewardProgressText {\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-style: normal;\n font-weight: 600;\n font-size: 12px;\n line-height: 16px;\n\n margin-left: 15px;\n align-items: center;\n display: flex;\n box-sizing: border-box;\n\n color: var(--text-normal);\n }\n .spanProgressReward {\n display: flex;\n align-items: center;\n text-align: center;\n justify-content: center;\n width: 61px;\n height: 28px;\n margin-right: -2px;\n\n font-family: 'Segoe UI','Roboto', Helvetica, Verdana, sans-serif;\n font-style: italic;\n font-weight: 900;\n font-size: 14px;\n line-height: 14px;\n color: #FFFFFF;\n\n background: linear-gradient(100.25deg, #079E82 0%, #0264BC 100%);\n box-shadow: inset 0px 0px 1px 1px rgba(0, 0, 0, 0.1);\n border-radius: 20px;\n padding: 0px 7px 0px 7px;\n }\n .spanProgressIconsWrapper {\n margin-left: 0px;\n margin-right: 15px;\n display: flex;\n flex-direction: row;\n align-items: center;\n box-sizing: border-box;\n }\n .divProgress, .divProgressNotification, .divClaim, .divClaimNotification {\n margin-top: 10px;\n margin-bottom: 10px;\n height: 28px;\n width: 100%;\n flex: auto;\n box-sizing: border-box;\n\n display: flex;\n flex-direction: row;\n align-items: center;\n\n border-radius: 20px;\n border: 2px solid #EDEFED;\n }\n .divProgress:hover, .divProgressNotification:hover, .divClaim:hover, .divClaimNotification:hover {\n cursor: pointer;\n border: 2px solid #07978A;\n }\n .divProgress:focus, .divProgressNotification:focus, .divClaim:focus, .divClaimNotification:focus {\n outline: 2px solid transparent;\n border: 2px solid #878787;\n }\n .divProgress, .divClaim {\n margin-left: 20px;\n margin-right: 20px;\n background: linear-gradient(271.69deg, #EBF5F5 48.57%, #FFFFFF 100%);\n }\n .divProgressNotification, .divClaimNotification {\n margin-left: 16px;\n margin-right: 16px;\n background: linear-gradient(272.2deg, #EBF5F5 62.52%, #FFFFFF 147.61%);\n }\n .divClaim, .divClaimNotification {\n justify-content: center;\n text-align: center;\n justify-content: center;\n }\n @media (forced-colors: active) {\n .spanRewardClaimText, .spanRewardProgressText {\n color: ${Ns.Highlight} !important;\n }\n .divProgress, .divProgressNotification, .divClaim, .divClaimNotification {\n forced-color-adjust: none;\n background: ${Ns.HighlightText} !important;\n border: 2px solid ${Ns.HighlightText} !important;\n }\n .divProgress:hover, .divProgressNotification:hover, .divClaim:hover, .divClaimNotification:hover {\n border: 2px solid ${Ns.Highlight} !important;\n }\n .divProgress:focus, .divProgressNotification:focus, .divClaim:focus, .divClaimNotification:focus {\n border: 2px solid ${Ns.ButtonText} !important;\n }\n .spanProgressReward {\n background: ${Ns.Highlight};\n color: ${Ns.HighlightText};\n }\n #actionDone {\n fill: ${Ns.Highlight};\n }\n #correctActionDone {\n stroke: ${Ns.HighlightText};\n }\n #actionToDo {\n stroke: ${Ns.Highlight};\n }\n #pinkStar {\n fill: ${Ns.Highlight};\n }\n #blueStar {\n fill: ${Ns.Highlight};\n }\n }\n `}getDarkModeStyles(){return"\n .divProgress, .divProgressNotification, .divClaim, .divClaimNotification {\n background: linear-gradient(90deg, rgba(14, 14, 18, 0.4) 0%, rgba(14, 24, 40, 0.4) 30.73%, rgba(5, 29, 48, 0.4) 100%);\n border: 2px solid #24282E;\n }\n .divProgress:hover, .divProgressNotification:hover, .divClaim:hover, .divClaimNotification:hover {\n cursor: pointer;\n border: 2px solid #079188;\n }\n .divProgress:focus, .divProgressNotification:focus, .divClaim:focus, .divClaimNotification:focus {\n outline: 2px solid transparent;\n border: 2px solid #878787;\n }\n "}getPinkStarIcon(){return eh.Z.getTrustedHTML`<svg width="10" height="10" viewBox="0 0 10 10" fill="none" xmlns="http://www.w3.org/2000/svg">
<path id="pinkStar" d="M4.50513 0C4.50513 0 5.03612 2.70012 5.6731 3.3371C6.31008 3.97408 9.0102 4.50507 9.0102 4.50507C9.0102 4.50507 6.4164 4.92975 5.6731 5.67305C4.9298 6.41634 4.50513 9.01014 4.50513 9.01014C4.50513 9.01014 3.9742 6.31009 3.33715 5.67305C2.70011 5.036 5.61249e-05 4.50507 5.61249e-05 4.50507C5.61249e-05 4.50507 2.70011 3.97414 3.33715 3.3371C3.9742 2.70005 4.50513 0 4.50513 0Z" />
</svg>`}getBlueStarIcon(){return eh.Z.getTrustedHTML`<svg width="8" height="8" viewBox="0 0 8 8" fill="none" xmlns="http://www.w3.org/2000/svg">
<path id="blueStar" d="M3.84399 0C3.84399 0 4.29701 2.30361 4.84045 2.84705C5.38389 3.39049 7.6875 3.84351 7.6875 3.84351C7.6875 3.84351 5.4746 4.20582 4.84045 4.83996C4.20631 5.47411 3.84399 7.68701 3.84399 7.68701C3.84399 7.68701 3.39103 5.38346 2.84754 4.83996C2.30404 4.29647 0.000488221 3.84351 0.000488221 3.84351C0.000488221 3.84351 2.30404 3.39054 2.84754 2.84705C3.39103 2.30355 3.84399 0 3.84399 0Z" />
</svg>`}getActionDoneIcon(){return eh.Z.getTrustedHTML`<svg width="12" height="12" viewBox="0 0 12 12" xmlns="http://www.w3.org/2000/svg">
<circle id="actionDone" cx="6" cy="6" r="5.5"/>
<defs>
<linearGradient id="actionDoneFill" x1="6" y1="0" x2="13.6965" y2="10.3847" gradientUnits="userSpaceOnUse">
<stop stop-color="#09C887"/>
<stop offset="1" stop-color="#0177D8"/>
</linearGradient>
</defs>
</svg>`}getCorrectIcon(){return eh.Z.getTrustedHTML`<svg width="8" height="6" viewBox="0 0 8 6" xmlns="http://www.w3.org/2000/svg">
<path id="correctActionDone" d="M1.27856 2.96788L2.94965 4.63896L6.76928 0.819336"/>
</svg>`}getActionToDoIcon(){return eh.Z.getTrustedHTML`<svg width="12" height="12" viewBox="0 0 12 12" xmlns="http://www.w3.org/2000/svg">
<circle id="actionToDo" cx="6" cy="6" r="5"/>
<defs>
<linearGradient id="actionToDoStroke" x1="2" y1="2" x2="10.5" y2="10" gradientUnits="userSpaceOnUse">
<stop stop-color="#09C887"/>
<stop offset="1" stop-color="#0387C9"/>
</linearGradient>
</defs>
</svg>`}},this.pageHandlerModule=i,this.incentiveCampaignData=this.flyoutData.dataStoreModule.IncentiveCampaignData,this.logModule=n}RenderICBanner(){if(this.shouldRenderICBanner()&&this.incentiveCampaignData){const e=this.renderIncentiveCampaignBanner();if(e.id="incentiveCampaignBannerId",this.incentiveCampaignData.actionsCompletedCount===ge.N0.THREE_ACTIONS){const e=new t.Z(i.xu.IncentiveCampaignClaimBanner);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"User saw 3 actions Incentive Campaign claim Banner",e)}else{const e=new t.Z(i.xu.IncentiveCampaignProgressBanner);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"User saw 3 actions Incentive Campaign progress Banner",e)}e.slot="start-content",this.flyoutData.common.shopping?.prepend(e)}}RenderICNotificationBanner(){if(this.shouldRenderICBanner()&&this.incentiveCampaignData){const e=this.renderIncentiveCampaignBanner();if(e.id="incentiveCampaignBannerId",this.incentiveCampaignData.actionsCompletedCount===ge.N0.THREE_ACTIONS){e.className="divClaimNotification";const n=new t.Z(i.xu.IncentiveCampaignClaimNotification);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"User saw 3 actions Incentive Campaign claim notification",n)}else{e.className="divProgressNotification";const n=new t.Z(i.xu.IncentiveCampaignProgressNotification);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"User saw 3 actions Incentive Campaign progress notification",n)}e.slot="start-content",this.flyoutData.common.shopping?.prepend(e)}}shouldRenderICBanner(){return e.R.isExperimentActive(f.H.incentiveCampaign)&&void 0!==this.flyoutData.dataStoreModule.IncentiveCampaignData&&!this.flyoutData.dataStoreModule.IncentiveCampaignData.isRewardClaimed}renderRewardClaimText(){const e=(0,Y.Ux)("SPAN");e.className="spanRewardClaimText";const t=this.incentiveCampaignData?.treatment;let i="",n="";return t===ge.eH.RewardsPts?(i=(0,T.fZ)("icRewardClaimText",this.flyoutData.strings.icRewardClaimText,`${wI.points}`),n=(0,T.fZ)("icRewardClaimText",this.flyoutData.strings.icRewardClaimText,this.flyoutData.strings.icRewardPointsAriaLabel)):t===ge.eH.RewardsMoney&&(i=(0,T.fZ)("icRewardClaimText",this.flyoutData.strings.icRewardClaimText,`${wI.dollars}`),n=(0,T.fZ)("icRewardClaimText",this.flyoutData.strings.icRewardClaimText,this.flyoutData.strings.icRewardDollarsAriaLabel)),e.textContent=i,e.setAttribute("aria-label",n),e}renderPinkStarIcon(){const e=(0,Y.Ux)("SPAN");return e.className="iconPinkStar",e.setAttribute("aria-hidden","true"),e.innerHTML=this.assets.getPinkStarIcon(),e}renderBlueStarIcon(){const e=(0,Y.Ux)("SPAN");return e.setAttribute("aria-hidden","true"),e.innerHTML=this.assets.getBlueStarIcon(),e}renderIncentiveCampaignBanner(){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());let e=(0,Y.Ux)("DIV");return this.incentiveCampaignData&&(e=this.incentiveCampaignData.actionsCompletedCount===ge.N0.THREE_ACTIONS?this.renderClaimWrapper():this.renderProgressWrapper()),e}renderActionDoneIcon(){const e=(0,Y.Ux)("SPAN");e.className="iconActionDone",e.setAttribute("aria-hidden","true");const t=(0,Y.Ux)("SPAN");t.innerHTML=this.assets.getActionDoneIcon(),t.className="spanActionDone";const i=(0,Y.Ux)("SPAN");return i.className="spanCorrect",i.innerHTML=this.assets.getCorrectIcon(),e.appendChild(t),e.appendChild(i),e}renderActionToDoIcon(){const e=(0,Y.Ux)("SPAN");return e.className="iconActionToDo",e.setAttribute("aria-hidden","true"),e.innerHTML=this.assets.getActionToDoIcon(),e}renderRewardProgressText(){const e=this.flyoutData.strings.icRewardProgressText,t=(0,Y.Ux)("DIV",{style:"width: 100%;"}),i=(0,Y.Ux)("SPAN",{},e);return i.className="spanRewardProgressText",t.appendChild(i),t}renderProgressReward(){const e=this.incentiveCampaignData?.treatment,t=(0,Y.Ux)("SPAN");return t.className="spanProgressReward",t.setAttribute("aria-hidden","true"),t.textContent=wI.dollars,e===ge.eH.RewardsPts&&(t.textContent="+5000"),t}renderProgressIconsWrapper(){const e=this.incentiveCampaignData?.actionsCompletedCount;let t=this.flyoutData.strings.icRewardPointsAriaLabel;this.incentiveCampaignData?.treatment===ge.eH.RewardsMoney&&(t=this.flyoutData.strings.icRewardDollarsAriaLabel);let i=`${ge.N0.NO_ACTIONS}`;const n=(0,Y.Ux)("SPAN");n.className="spanProgressIconsWrapper";let o=this.renderActionToDoIcon(),r=this.renderActionToDoIcon();const a=this.renderActionToDoIcon();e===ge.N0.ONE_ACTION?(o=this.renderActionDoneIcon(),i=`${ge.N0.ONE_ACTION}`):e===ge.N0.TWO_ACTIONS&&(o=this.renderActionDoneIcon(),r=this.renderActionDoneIcon(),i=`${ge.N0.TWO_ACTIONS}`);const s=(0,T.fZ)("icRewardProgressAriaLabel",this.flyoutData.strings.icRewardProgressAriaLabel,i,t);return n.setAttribute("aria-label",s),n.appendChild(o),n.appendChild(r),n.appendChild(a),n}renderProgressWrapper(){const e=(0,Y.Ux)("DIV");e.className="divProgress",e.addEventListener("click",(()=>{this.onClickBanner(ge.B8.RewardProgress,i.$S.IncentiveCampaignProgress)})),e.addEventListener("keypress",(e=>{"Enter"!==e.key&&" "!==e.key||this.onClickBanner(ge.B8.RewardProgress,i.$S.IncentiveCampaignProgress)})),e.setAttribute("role","link"),e.setAttribute("tabindex","0");const t=this.renderRewardProgressText(),n=this.renderProgressIconsWrapper(),o=this.renderProgressReward();return e.appendChild(t),e.appendChild(n),e.appendChild(o),e}renderClaimWrapper(){const e=(0,Y.Ux)("DIV");e.className="divClaim",e.addEventListener("click",(()=>{this.onClickBanner(ge.B8.ClaimReward,i.$S.IncentiveCampaignClaim)})),e.addEventListener("keypress",(e=>{"Enter"!==e.key&&" "!==e.key||this.onClickBanner(ge.B8.ClaimReward,i.$S.IncentiveCampaignClaim)})),e.setAttribute("role","link"),e.setAttribute("tabindex","0");const t=this.renderRewardClaimText(),n=this.renderPinkStarIcon(),o=this.renderBlueStarIcon();o.className="iconBlueStarUp";const r=this.renderBlueStarIcon();return r.className="iconBlueStarDown",e.appendChild(n),e.appendChild(t),e.appendChild(r),e.appendChild(o),e}onClickBanner(e,t){const n=new W.Z(t,bp.r.CAMPAIGN_BANNER);this.logModule.LogInfoEvent(i.R.ButtonClick,`Incentive Campaign ${e} clicked`,n),this.pageHandlerModule.NavigateToUrl(this.landingPageUrl)}}(this.utilities,this.flyoutData,this.pageHandlerModule,this.logModule);l?n.RenderICNotificationBanner():n.RenderICBanner()}const c=new gg(this.utilities.viewModulesUtilities,this.flyoutData,this.pageHandlerModule,this.logModule);l?c.RenderCUCNotificationBanner():c.RenderCUCBanner();const d=new CustomEvent(Ku.e1.ModulesRendered,{detail:{modules:o}});this.stateManagement.dispatchEvent(d),this.stateManagement.setState(Ku.IY.modulesRendered,!0),this.flyoutData.common.channel===r.Ee.STABLE&&n.addEventListener("contextmenu",(e=>(e.preventDefault(),!1)))}}handleNotificationRendering(e,n,o,r){gn.SO.queueUpdate((()=>{try{n?(this.flyoutData.common.shopping.appendChild(n.element),e.PostProcessingNotification(n.name,n.element)):e.PostProcessingNotification(e.GetNotificationName(),this.flyoutData.common.shopping);const t=performance.now();r.set(e.GetNotificationName(),new xI(t-o,!0))}catch(n){const o=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Error while Post processing Module: ${e.GetNotificationName()} ${(0,dt.YU)(n)}`,o,GI.GetImpressionType(e.GetNotificationName()))}}))}},QI=class extends JI{constructor(e,t,i,n,o){super(e,t,i,n,o,[],null),(0,s.Z)(this,"assets",new SI),(0,s.Z)(this,"contextualShopping","contextualShopping"),(0,s.Z)(this,"contextualModules",void 0),(0,s.Z)(this,"shoppingContentElement",void 0)}renderModules(t,i){const n=!e.R.isTestFlagActive(Zt.t.msShoppingTestExp3),o=n?"":this.assets.getDiscoverBackgroundStyles(),r=n?"":this.assets.getDiscoverBackgroundDarkModeStyles();this.utilities.viewModulesUtilities.applyStyles(i,this.assets.getStyles()+this.assets.getDiscoverPaneStyles()+o,void 0,this.assets.getDarkModeStyles()+r),this.renderDiscoverModules(t,i),i.addEventListener(Ku.e1.ModulesRendered,(()=>{gn.SO.queueUpdate((()=>{const e=this.flyoutData.common.shopping,i=t?.sort(((e,t)=>e.priority-t.priority));this.handleFlyoutFocus(i,void 0,e,!1)}))}))}addEventsListeners(e){this.stateManagement.addEventListener(Ku.e1.onDataUpdate,(t=>{t&&t.detail&&t.detail.moduleType&&this.styleModulesInPane(t.detail.moduleType,e)})),this.stateManagement.addEventListener(Ku.e1.flyoutRefresh,(()=>{const t=document.querySelector("#divActions");t&&this.createActionButtons(t,e)})),this.stateManagement.addEventListener(Ku.e1.PWILODeleted,(t=>{if(t&&t.detail&&void 0!==t.detail.index&&(0,T.pq)(t.detail.event)){const t=e.querySelector(`#${r.z6.CLOSE}`);t&&t.focus()}}))}appendContentToFlyout(e){if(e){const n=new t.Z(i.xu.AppendNodeError);if(!this.flyoutData.common.isSharedHeader){const e=document.querySelector("#divMainHeader");e&&e.remove()}try{e.appendChild(this.shoppingContentElement)}catch(e){this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,"Failure when appending tabs to Pane",n)}}}createActionButtons(e,t){new $I(this.flyoutData,this.utilities,this.pageHandlerModule,this.logModule,this.stateManagement).createFlyoutButtons(e,!0,t)}renderDiscoverModules(e,t){this.contextualModules=e?.sort(((e,t)=>e.priority-t.priority)),this.renderModulesInTab(this.contextualModules,this.flyoutData.common.shopping,t),this.flyoutData.common.shopping.id=this.contextualShopping,this.flyoutData.common.shopping.fixedTitle=this.flyoutData.strings.commonContextualTab}renderModulesInTab(e,n,o){try{const r=n;if(e&&e.length>0&&this.canRenderContentInTab(e)){for(let n=0;n<e.length;n++){const a=e[n];a.element.expanded=!0,n>0&&this.utilities.viewModulesUtilities.addSectionSeparator(r),r.appendChild(a.element),this.isStoryBookSection(o)?this.utilities.viewModulesUtilities.styleModules(a,1,o):this.utilities.viewModulesUtilities.styleModules(a,n,o);try{a.moduleInterface.PostProcessing(a.name,n,a.element),this.isStoryBookSection(o)?this.styleModulesInPane(a,o,1):this.styleModulesInPane(a,o,n)}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Error while Post processing Module: ${a.name} ${(0,dt.YU)(e)}`,n,GI.GetImpressionType(a.name))}}this.isStoryBookSection(o)||this.setTitle(e[0]),this.shoppingContentElement=r}}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,`Error adding modules to tabs ${(0,dt.YU)(e)}`,n)}}canRenderContentInTab(e){return!!(e&&e.length>0)}styleModulesInPane(e,t,i){e.element.isPane=!0;const n="msft-edge-shopping-section"===e.element.nodeName.toLowerCase()??!1;if(e.moduleLayout===r.SV.BLOCK)if(0!==i||this.isStoryBookSection(t)?n?e.element.isBlock=!0:e.element.classList.add("regionBlock"):e.name===r.ModuleNames.CASHBACK&&this.flyoutData.common.shopping.classList.add("noPaddingBlock"),e.name===r.ModuleNames.CASHBACK){const t=this.flyoutData.dataStoreModule.CashBackData;t&&t.userRebatesResponse&&t.userRebatesResponse.isRebatesUser&&e&&t.userRebatesResponse.latestCashbackApproved?e.element.classList.add("previousSection"):0!==i&&(e.element.hasPadding=!0)}else e.name!==r.ModuleNames.PRICECOMPARISON&&e.name!==r.ModuleNames.SIMILARSELLERS&&n&&0!==i&&(e.element.hasPadding=!0)}},eD=class{constructor(e,t,i,n,o,r,a){(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"strings",void 0),(0,s.Z)(this,"currentTheme",void 0),(0,s.Z)(this,"currentDirection",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"isCjkScenario",void 0),this.logModule=e,this.pageHandlerModule=t,this.strings=i,this.currentTheme=n,this.currentDirection=o,this.commonAssets=r,this.isCjkScenario=a}renderErrorUI(e){const n=document.querySelector("#divContentWrapper");if(n){const o=document.createElement("msft-edge-shopping");this.addCommonStyles(o);const a=this.createElement("DIV",{id:"emptyCouponDiv",style:"display: flex; flex-direction: column; justify-content: center; align-items: center; margin-bottom: 12px;"}),s=this.createElement("DIV",{style:"margin: 20px;"});s.innerHTML=this.commonAssets.getErrorImage(),s.setAttribute("aria-hidden","true");const l=this.createElement("P",{style:"font-weight: 600; margin-top: 5px; color: #666666;"});let c;this.isCjkScenario?(l.className=r.aM.EmptyCouponCjk,l.textContent=this.strings.cjkPaneNullStateMessage):(l.className=r.aM.EmptyCoupon,l.textContent=this.strings.commonErrorTitle),this.isCjkScenario||(c=this.createElement("P",{style:"margin-top: 5px; color: #666666;"}),c.className=r.aM.Small,c.textContent=this.strings.commonErrorSubTitle),a.appendChild(s),a.appendChild(l),c&&a.appendChild(c),a.slot="header-content",o.appendChild(a),o.fixedTitle=this.GetFixedTitle();try{this.addHeaderIcon(o),this.createCloseButton(!1,o)}catch(e){}const d=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`User saw error page - ${e}`,d),n.appendChild(o),gn.SO.queueUpdate((()=>{this.pageHandlerModule.ResizeIframe({offsetHeight:n.offsetHeight,offsetWidth:n.offsetWidth,scrollHeight:n.scrollHeight})}))}}GetFixedTitle(){return"Shopping in Microsoft Edge"}createElement(e,t,i){const n=document.createElement(e);if(t)for(const e in t)t.hasOwnProperty(e)&&(n[e]=t[e]);return i&&(n.innerText=i),n}createCloseButton(e,t){const n=document.createElement("fluent-button");n.slot="header-actions",this.strings?.commonClose?n.ariaLabel=this.strings.commonClose:n.ariaLabel="close",n.id=r.z6.CLOSE;const o=this.createElement("DIV");o.setAttribute("aria-hidden","true"),o.innerHTML=this.commonAssets.getCloseButton(),n.appearance="stealth",n.appendChild(o);const a=this.pageHandlerModule,s=this.logModule;n.addEventListener("click",(()=>{if(e){if(e){const e=new W.Z(i.$S.NotificationDismiss,bp.r.MENU);a.RecordAsUserAction(K.bS.DISMISSED),s.LogInfoEvent(i.R.ButtonClick,"Notification Dismissed",e)}}else{const e=new W.Z(i.$S.FlyoutDismiss,bp.r.MENU);a.RecordAsUserAction(K.bS.DISMISSED),s.LogInfoEvent(i.R.ButtonClick,"Flyout Dismissed",e)}a.DismissPopup()})),t.appendChild(n)}addHeaderIcon(e){const t=document.createElement("DIV");t.innerHTML=this.commonAssets.getHeaderIcon(),t.slot="header-icon",e.appendChild(t)}addCommonStyles(e){if(e){const t=document.querySelector("fluent-design-system-provider");t&&(this.currentTheme===r.Q2.Dark?t.setAttribute("background-color","#4a4a4a"):t.setAttribute("background-color","#FFFFFF"),this.currentDirection===r.m5.RTL?t.style.direction="rtl":t.style.direction="ltr",this.strings?.commonFixedTitle?t.setAttribute("aria-label",this.strings.commonFixedTitle):t.setAttribute("aria-label","Shopping in Microsoft Edge"));let i=this.commonAssets.getStyles();const n=window.matchMedia("(prefers-color-scheme: dark)").matches;(this.currentTheme===r.Q2.Dark||n)&&(i+=this.commonAssets.getDarkModeStyles()),this.applyStyles(e,i)}}applyStyles(e,t){const i=this.createElement("STYLE");i.textContent=t,i.type="text/css",i.rel="stylesheet",e.appendChild(i)}};const tD=[r.ModuleNames.SAFARI_FIRST_RUN_EXPERIENCE,r.ModuleNames.SAFARI_NULL_STATE];var iD=class extends JI{async renderModules(n,o){o.style.setProperty("--scrollbar-width",`${this.calculateScrollBarWidth()}px`);const a=this.flyoutData.dataStoreModule.CouponData?.isCheckoutPageWithAutoApply??!1;if(n&&n.length>0){for(let e=0;e<n.length;e++){const s=n[e];if(s&&s.element){this.setSectionExpandedState(e,s,a,this.bingShoppingCampaignGuid,n),this.hideModule(e,s)||(this.flyoutData.common.shopping.appendChild(s.element),(0,dt.tB)(this.flyoutData)&&!tD.includes(s.name)&&this.utilities.viewModulesUtilities.addSectionSeparator(this.flyoutData.common.shopping)),this.isStoryBookSection(o)?this.utilities.viewModulesUtilities.styleModules(s,1,o):this.utilities.viewModulesUtilities.styleModules(s,e,o),(0,dt.tB)(this.flyoutData)&&"msft-edge-shopping-section"===s.element.nodeName.toLowerCase()&&s.moduleLayout===r.SV.BLOCK&&(s.element.isBlock=!0);try{s.moduleInterface.PostProcessing(s.name,e,s.element),gn.SO.queueUpdate((()=>{this.utilities.telemetryHandler.sendCTRLog(s,e,GI.GetImpressionType(s.name),!1)}))}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Error while Post processing Module: ${s.name} ${(0,dt.YU)(e)}`,n,GI.GetImpressionType(s.name))}}}e.R.isPCBannerUXExperimentActive()||this.isStoryBookSection(o)||this.setTitle(n[0]),this.flyoutData.common.currentDevice!==r.AS.Desktop&&null===this.flyoutData.dataLoader.mobileData.channel||new $I(this.flyoutData,this.utilities,this.pageHandlerModule,this.logModule,this.stateManagement).createFlyoutButtons(this.flyoutData.common.shopping,this.flyoutData.common.currentDevice===r.AS.Desktop&&!e.R.isPCBannerUXExperimentActive(),o)}else new eD(this.logModule,this.pageHandlerModule,this.flyoutData.strings,this.flyoutData.common.currentTheme,this.flyoutData.common.currentDirection,this.commonAssets,this.flyoutData.common.isCJKEnabled).renderErrorUI("no view module to render")}addEventsListeners(e){}},nD=class extends ah{constructor(e,t){super(e,t),(0,s.Z)(this,"autoShowCompetingOffer",void 0),this.flyoutData=e,this.utilities=t.viewModulesUtilities,this.logModule=t.logModule,this.pageHandlerModule=t.pageHandlerModule,this.assets=new rh,this.storageHandler=t.storageHandler,this.telemetryUtilities=t.telemetryHandler}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_LOWER_PRICE_FOUND,u.sR.AUTO_SHOW_AUTOS_MARKETPLACE]}PostProcessingNotification(e,t){if(this.autoShowCompetingOffer){const e=(0,Y.Ux)("DIV",{className:"btnActions"});e.id="divNotificationActions",e.slot="actions";const t=(0,Y.lw)(this.utilities);t.style.height="32px",t.textContent=this.flyoutData.strings.autosMarketplaceSeeMoreButtonV2,t.addEventListener("click",(()=>{this.pageHandlerModule.RecordAsUserAction(K.bS.AUTOS_MARKETPLACE_SEE_MORE_CLICK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.AUTOS_MARKETPLACE_SEE_MORE_CLICK,this.flyoutData.common.popupOrigination);const e=new W.Z(i.$S.NavigatedToAutosMarketplace,this.telemetryUtilities.setContentViewed(this.GetNotificationName()),void 0,this.constructTelemetryMetaData());this.logModule.LogInfoEvent(i.R.ButtonClick,"Navigate to Autos Marketplace from Autoshow - [AutosMarketplaceNotificationModule] - click on See more similar button",e),this.pageHandlerModule.OpenPane(this.flyoutData.common.popupOrigination)})),e.appendChild(t),this.flyoutData.common.shopping.appendChild(e)}}RenderNotification(){const e=this.autoShowCompetingOffer;if(e){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getNotificationStyles(),void 0,this.assets.getNotificationDarkModeStyles()),this.flyoutData.common.shopping.classList.add("noSections");let n=this.notificationRenderer(e);const o=this.utilities.createNotificationModule(n,this.GetNotificationName(),this),r=new t.Z(i.xu.AutosMarketplaceRenderNotification,void 0,void 0,void 0,this.constructTelemetryMetaData());return this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Autos Marketplace Notification",r),Promise.resolve(o)}return Promise.resolve(null)}notificationRenderer(e){const t=(0,Y.Ux)("DIV");t.classList.add("lateralMargin");const i=(0,Y.Ux)("A",{className:"upperContent"}),n=(0,Y.Ux)("DIV",{style:"margin-right: 10px;"}),o=(0,Y.Ux)("DIV",{className:"titleV2"});o.textContent=this.flyoutData.strings.autosMarketplaceNotificationSave;const a=(0,Y.Ux)("DIV",{className:"titleV2"});a.textContent=this.flyoutData.strings.autosMarketplaceNotificationHeaderPt2;const s=(0,Y.Ux)("DIV",{className:"vehiclePrice"}),l=(0,Y.Ux)("DIV",{className:"vehiclePriceIconV2"});l.textContent=e.CurrencySymbol;const c=e.PriceDifference,d=(0,Y.Ux)("DIV",{className:"vehiclePriceNumberV2"});if(d.textContent=this.utilities.formatPrice(c),s.appendChild(l),s.appendChild(d),n.appendChild(o),n.appendChild(s),n.appendChild(a),e.marketHint?.toLowerCase()===r.Jk.US&&e.listingAccidentText&&Object.values(r.Fh).includes(e.listingAccidentText.toLowerCase())){const e=(0,Y.Ux)("DIV",{className:"accidentsContainer"}),t=(0,Y.Ux)("DIV",{className:"accidentsIcon"});t.setAttribute("aria-hidden","true"),t.innerHTML=eh.Z.getTrustedHTML`<svg width="12" height="12" viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M2.8 0.4C1.47452 0.4 0.400002 1.47452 0.400002 2.8V9.2C0.400002 10.5255 1.47452 11.6 2.8 11.6H9.2C10.5255 11.6 11.6 10.5255 11.6 9.2V2.8C11.6 1.47452 10.5255 0.4 9.2 0.4H2.8ZM1.2 2.8C1.2 1.91634 1.91635 1.2 2.8 1.2H9.2C10.0837 1.2 10.8 1.91634 10.8 2.8V9.2C10.8 10.0837 10.0837 10.8 9.2 10.8H2.8C1.91635 10.8 1.2 10.0837 1.2 9.2V2.8ZM8.68284 4.68284C8.83905 4.52663 8.83905 4.27337 8.68284 4.11716C8.52663 3.96095 8.27337 3.96095 8.11716 4.11716L5.2 7.03431L3.88284 5.71716C3.72663 5.56095 3.47337 5.56095 3.31716 5.71716C3.16095 5.87337 3.16095 6.12663 3.31716 6.28284L4.91716 7.88284C5.07337 8.03905 5.32663 8.03905 5.48284 7.88284L8.68284 4.68284Z" fill="#484644"/>
</svg>`;const i=(0,Y.Ux)("DIV",{style:"margin-left: 8px; margin-right: 8px;"});i.textContent=this.flyoutData.strings.autosMarketplaceNotificationNoAccident,e.appendChild(t),e.appendChild(i),n.appendChild(e)}const u=(0,Y.Ux)("DIV",{className:"imageWrapperV2"}),h=(0,Y.Ux)("IMG",{className:"notifProductImage"}),p=e.ProductImageOriginalUrl.replace("edge://image?","");h.src=this.constructImageUrl(p,175),h.onerror=()=>{h.onerror=null,h.src="https://marketplaceassets.azureedge.net/publicassets/misc/imageplaceholderlight.webp"},h.setAttribute("aria-hidden","true");const g=(0,Y.Ux)("IMG",{className:"notifProductImageBg"});return g.src=this.constructImageUrl(p,175),g.onerror=()=>{g.onerror=null,g.src="https://marketplaceassets.azureedge.net/publicassets/misc/imageplaceholderlight.webp"},g.setAttribute("aria-hidden","true"),u.appendChild(h),u.appendChild(g),i.appendChild(n),i.appendChild(u),i.tabIndex=0,this.manageListingEvents(i,e),t.appendChild(i),t.slot="header-content",t}async ShouldRenderNotification(){if(!1==(this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_LOWER_PRICE_FOUND||this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_AUTOS_MARKETPLACE))return Promise.resolve(!1);const e=await this.storageHandler.getStorageString(Ce.Q.AutosMarketplaceNotification);if(e&&e!==r.yA.LISTING)return Promise.resolve(!1);const t=this.flyoutData.dataStoreModule.PriceComparisonData,i=this.getCompetingVehicle(t);return t&&t?.segment?.toLowerCase()===r.VG.AUTOS&&i&&this.flyoutData.common.openedWith===r.Te.Auto&&!this.flyoutData.common.seeInfoFromPCNotification?(this.scenario=r.tl.PDP,this.autoShowCompetingOffer=i,Promise.resolve(!0)):Promise.resolve(!1)}GetNotificationName(){return r.sM.AUTOSMARKETPLACE_NOTIFICATION}manageListingEvents(e,n){let o=0,r=0,a=!0;e.addEventListener("mouseenter",(()=>{l()})),e.addEventListener("mouseleave",(()=>{c()})),e.addEventListener("focus",(()=>{l()})),e.addEventListener("blur",(()=>{c()}));const s=this.logModule,l=()=>{if(!(Date.now()-r>200))return;a=!0,o=Date.now();const e=new t.Z(i.xu.AutosMarketplaceListingHovered,void 0,void 0,void 0,this.constructTelemetryMetaData());s.LogInfoEvent(i.R.EdgeFlyoutStatus,"Autos Marketplace Notification - listing hovered",e)},c=()=>{r=Date.now(),setTimeout((()=>{if(a){a=!1,this.sendAutosMarketplaceDwellTimeTelemery(o,i.xu.AutosMarketDwellTimeHover,"Autos Marketplace Notification - hover time over listing");const e=new t.Z(i.xu.AutosMarketDwellTimeHover,void 0,void 0,void 0,this.constructTelemetryMetaData());s.LogInfoEvent(i.R.EdgeFlyoutStatus,"Autos Marketplace Notification - listing exited hover",e)}}),200)};e.addEventListener("click",(()=>{this.openSidePane()})),e.addEventListener("mousedown",(e=>{1===e.button&&this.openSidePane()})),e.addEventListener("keydown",(e=>{e&&"Enter"===e.key&&this.openSidePane()}))}getCompetingVehicle(e){if(!e||!e.CompetingPrices)return null;for(const t of e.CompetingPrices)if(t.ShouldOnTop&&t.validAutosOffer)return t;return null}openSidePane(){const e=new W.Z(i.$S.NavigatedToAutosMarketplaceRecommendation,this.telemetryUtilities.setContentViewed(this.GetNotificationName()),void 0,this.constructTelemetryMetaData());this.pageHandlerModule.RecordAsUserAction(K.bS.AUTOS_MARKETPLACE_RECOMMENDATION_CLICK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.AUTOS_MARKETPLACE_RECOMMENDATION_CLICK,this.flyoutData.common.popupOrigination),this.logModule.LogInfoEvent(i.R.ButtonClick,"Navigate to Autos Marketplace from Autoshow - [AutosMarketplaceModuleNotification] - click on recommended",e),this.pageHandlerModule.OpenPane(this.flyoutData.common.popupOrigination)}},oD=class extends yp{constructor(e,t,i){super(e,t,i),(0,s.Z)(this,"storageHandler",void 0),this.flyoutData=t,this.utilities=i.viewModulesUtilities,this.logModule=i.logModule,this.pageHandlerModule=i.pageHandlerModule,this.stateManagement=e,this.assets=new mp,this.storageHandler=i.storageHandler,this.telemetryUtilities=i.telemetryHandler}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_AUTOS_MARKETPLACE]}PostProcessingNotification(e,t){const n=(0,Y.Ux)("DIV",{className:"btnActions"});n.id="divNotificationActions",n.slot="actions";const o=(0,Y.lw)(this.utilities);o.style.height="32px",o.textContent=this.flyoutData.strings.autosMarketplaceSeeMoreButtonV2,o.addEventListener("click",(()=>{this.pageHandlerModule.RecordAsUserAction(K.bS.AUTOS_REVIEWS_VIDEO_SEE_MORE_CLICK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.AUTOS_REVIEWS_VIDEO_SEE_MORE_CLICK,this.flyoutData.common.popupOrigination);const e=new W.Z(i.$S.NavigatedToAutosVideoReviewSeeNow,this.telemetryUtilities.setContentViewed(this.GetNotificationName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"Navigate to Autos Review see now - [AutosReviewsModuleNotification] - click on See now button",e),this.pageHandlerModule.OpenPane(this.flyoutData.common.popupOrigination)})),n.appendChild(o),this.flyoutData.common.shopping.appendChild(n)}RenderNotification(){this.reviewData=this.flyoutData.dataStoreModule.RatingsAndReviewsData;const e=!!this.reviewData&&!!this.reviewData.videos&&this.reviewData.videos[Math.floor(Math.random()*this.reviewData.videos.length)];return e&&e.thumbnailUrl?(this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getNotificationStyles(),void 0,this.assets.getNotificationDarkModeStyles()),this.flyoutData.common.shopping.classList.add("noSections"),this.NotificationRenderer(e,this.reviewData?.entityName||"")):Promise.resolve(null)}NotificationRenderer(e,n){const o=(0,Y.Ux)("DIV");o.classList.add("lateralMargin");const r=(0,Y.Ux)("DIV",{className:"title",style:"margin-right: 10px; -webkit-line-clamp: 2;"});r.textContent=n?(0,T.fZ)("autosTrendingVideosTitle",this.flyoutData.strings.autosMarketplaceTrendingVideosV3,n):this.flyoutData.strings.autosMarketplaceTrendingVideosV2;const a=(0,Y.Ux)("DIV",{className:"imageWrapper"}),s=(0,Y.Ux)("IMG",{className:"notifCoverImage"}),l=e.thumbnailUrl;s.src=this.constructImageUrl(l,300),s.onerror=()=>{s.onerror=null,s.src="https://marketplaceassets.azureedge.net/publicassets/misc/imageplaceholderlight.webp"},s.setAttribute("aria-hidden","true");const c=(0,Y.Ux)("DIV",{className:"videoPlayButton",style:"height: 32px;"});c.innerHTML=eh.Z.getTrustedHTML`<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_722_13504)">
<path opacity="0.6" d="M16.0001 0.666382C12.9674 0.666382 10.0028 1.56568 7.48122 3.25056C4.95962 4.93544 2.99428 7.33022 1.83371 10.1321C0.673148 12.9339 0.369491 16.017 0.961142 18.9914C1.55279 21.9658 3.01318 24.698 5.15762 26.8425C7.30206 28.9869 10.0342 30.4473 13.0087 31.039C15.9831 31.6306 19.0662 31.3269 21.868 30.1664C24.6699 29.0058 27.0647 27.0405 28.7495 24.5189C30.4344 21.9973 31.3337 19.0327 31.3337 16C31.3337 11.9333 29.7182 8.0331 26.8426 5.15749C23.967 2.28188 20.0668 0.666382 16.0001 0.666382V0.666382Z" fill="black"/>
<path d="M16 1.6C18.8481 1.6 21.6322 2.44455 24.0002 4.02684C26.3683 5.60913 28.214 7.8581 29.3039 10.4894C30.3938 13.1206 30.6789 16.016 30.1233 18.8093C29.5677 21.6026 28.1962 24.1685 26.1823 26.1823C24.1685 28.1962 21.6026 29.5677 18.8093 30.1233C16.016 30.6789 13.1206 30.3938 10.4894 29.3039C7.85811 28.214 5.60914 26.3683 4.02684 24.0002C2.44455 21.6321 1.60001 18.848 1.60001 16C1.60424 12.1822 3.12274 8.52195 5.82235 5.82234C8.52195 3.12273 12.1822 1.60423 16 1.6V1.6ZM16 0C12.8355 0 9.74207 0.938384 7.11088 2.69649C4.4797 4.45459 2.42894 6.95345 1.21793 9.87706C0.00693254 12.8007 -0.309921 16.0177 0.307443 19.1214C0.924806 22.2251 2.44866 25.0761 4.6863 27.3137C6.92394 29.5513 9.77487 31.0752 12.8786 31.6926C15.9823 32.3099 19.1993 31.9931 22.1229 30.7821C25.0466 29.5711 27.5454 27.5203 29.3035 24.8891C31.0616 22.2579 32 19.1645 32 16C32 11.7565 30.3143 7.68687 27.3137 4.68629C24.3131 1.68571 20.2435 0 16 0V0ZM22.4576 16.72C22.3525 16.8852 22.2124 17.0253 22.0472 17.1304L14.0552 22.216C13.8529 22.3449 13.6197 22.417 13.3799 22.4247C13.1402 22.4325 12.9027 22.3756 12.6926 22.26C12.4824 22.1444 12.3072 21.9743 12.1853 21.7677C12.0635 21.5611 11.9995 21.3255 12 21.0856V10.9136C11.9999 10.6739 12.0642 10.4386 12.1862 10.2323C12.3083 10.0261 12.4835 9.85638 12.6936 9.74106C12.9037 9.62575 13.141 9.56904 13.3805 9.57687C13.6201 9.58471 13.8531 9.6568 14.0552 9.7856L22.0472 14.872C22.1957 14.9662 22.3241 15.0888 22.4251 15.2328C22.5261 15.3767 22.5977 15.5392 22.6359 15.7108C22.674 15.8825 22.6779 16.06 22.6473 16.2332C22.6167 16.4063 22.5522 16.5718 22.4576 16.72V16.72Z" fill="white"/>
</g>
<defs>
<clipPath id="clip0_722_13504">
<rect width="32" height="32" fill="white"/>
</clipPath>
</defs>
</svg>`,c.setAttribute("aria-hidden","true"),a.appendChild(c),a.appendChild(s),a.tabIndex=0,this.manageReviewEvents(a,e);const d=(0,Y.Ux)("DIV",{className:"reviewTitleV2"});d.textContent=e.title,o.appendChild(r),o.appendChild(a),o.appendChild(d),o.slot="header-content";const u=this.utilities.createNotificationModule(o,this.GetNotificationName(),this),h=new t.Z(i.xu.AutosReviewsRenderNotification);return this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Autos Reviews Notification Rendered",h),Promise.resolve(u)}async ShouldRenderNotification(){if(!1==(this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_AUTOS_MARKETPLACE))return Promise.resolve(!1);if(this.reviewData=this.flyoutData.dataStoreModule.RatingsAndReviewsData,!this.reviewData)return Promise.resolve(!1);const e=await this.storageHandler.getStorageString(Ce.Q.AutosMarketplaceNotification);if(e&&e!==r.yA.REVIEW)return Promise.resolve(!1);const t=this.reviewData.hasVideos||this.reviewData.hasExpertReviews&&this.reviewData.metaData?.heroImage;return Promise.resolve(t)}GetNotificationName(){return r.sM.AUTOSREVIEW_NOTIFICATION}manageReviewEvents(e,n){let o=0,r=0,a=!0;e.addEventListener("mouseenter",(()=>{l()})),e.addEventListener("mouseleave",(()=>{c()})),e.addEventListener("focus",(()=>{l()})),e.addEventListener("blur",(()=>{c()}));const s=this.logModule,l=()=>{if(!(Date.now()-r>200))return;a=!0,o=Date.now();const e=new t.Z(i.xu.AutosMarketplaceRatingAndReviewHovered);s.LogInfoEvent(i.R.EdgeFlyoutStatus,"Autos Review Notification - review hovered",e)},c=()=>{r=Date.now(),setTimeout((()=>{if(a){a=!1,this.sendAutosMarketplaceDwellTimeTelemery(o,i.xu.AutosMarketDwellTimeHover,"Autos Review Notification - hover time over listing");const e=new t.Z(i.xu.AutosMarketDwellTimeHover);s.LogInfoEvent(i.R.EdgeFlyoutStatus,"Autos Review Notification - listing exited hover",e)}}),200)};e.addEventListener("click",(()=>{this.navigateToReview(n)})),e.addEventListener("mousedown",(e=>{1===e.button&&this.navigateToReview(n)})),e.addEventListener("keydown",(e=>{e&&"Enter"===e.key&&this.navigateToReview(n)}))}navigateToReview(e){const t=new W.Z(i.$S.NavigatedToAutosVideoReview,this.telemetryUtilities.setContentViewed(this.GetNotificationName()));this.pageHandlerModule.RecordAsUserAction(K.bS.AUTOS_REVIEWS_VIDEO_CLICK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.AUTOS_REVIEWS_VIDEO_CLICK,this.flyoutData.common.popupOrigination),this.logModule.LogInfoEvent(i.R.ButtonClick,"Navigate to Autos video review from Autoshow - [AutosReviewsModuleNotification] - click on video review",t);let n="";if(e instanceof _t)n=e.clickthroughUrl;else{if(!(e instanceof kt))return;n=e.url}this.flyoutData.dataLoader.IsServerData()||(this.flyoutData.common.currentDevice,r.AS.Mobile),this.pageHandlerModule.NavigateToRetailerSite(n,this.flyoutData.common.popupOrigination)}constructImageUrl(e,t,i){let n=-1!==e.indexOf("?")?e+`&w=${t}`:e+`?w=${t}`;return i&&(n+=`&h=${i}`),n}},rD=class extends Ag{constructor(e,t,i,n){super(e,t,i,n)}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_CAMPAIGN_PDP_NOTIFICATION]}async RenderNotification(e){const t=await this.renderModule();if(t){const e=this.utilities.createNotificationModule(t.element,this.GetNotificationName(),this);return Promise.resolve(e)}return Promise.resolve(null)}async ShouldRenderNotification(){const e=await this.ShouldRenderModule(),t=this.flyoutData.common.lastCommittedURL.includes("auto_show_edge_shopping_flyout=1");return e&&(this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_CAMPAIGN_PDP_NOTIFICATION||t)}GetNotificationName(){return r.sM.CAMPAIGN_PDP_CASHBACK_NOTIFICATION}PostProcessingNotification(e,t){}};let aD=function(e){return e[e.ProductTracking=0]="ProductTracking",e[e.Inbox=1]="Inbox",e}({});const sD=(0,Zg.Z)({container:{display:"flex",flexDirection:"column",alignItems:"center",marginTop:"156px"}}),lD=e=>{const t=sD(),{isDarkMode:i,resourceBasePath:n,nullStateDesc:o}=e;return ch.createElement("div",{className:t.container},ch.createElement(cD,{src:n+"cjk/nullstate.svg"}),i?ch.createElement(uD,null,o):ch.createElement(dD,null,o))},cD=bm.img`
width: 192px;
height: 192px;
`,dD=bm.span`
color: #000000;
font-family: 'Segoe UI Variable', 'Roboto', Helvetica, Verdana, sans-serif;
font-size: 14px;
font-weight: 400;
line-height: 20px;
letter-spacing: 0em;
text-align: left;
`,uD=bm(dD)`
color: #FFFFFF;
`;var hD=new class{GetModuleName(){return r.ModuleNames.AUTOSMARKETPLACE}async UpdateData(e,t,i,n){}},pD=new class{GetModuleName(){return r.ModuleNames.BUYING_GUIDES}UpdateData(t,i,n,o){if(e.R.isExperimentActive(f.H.discoverShopping)){let e,r=!1;if(t&&t.detail&&t.detail.data&&t.detail.data.shoppingDataContainer){const o=t.detail.data.shoppingDataContainer,a=Kt.Create(o,i,n.logModule,n.pageHandlerModule);e=a?.BuyingGuideData,e?.guides&&e?.guides.length>0&&(r=!0)}if(r&&e)i.dataStoreModule.DiscoverShoppingData||(i.dataStoreModule.DiscoverShoppingData=new Kt),i.dataStoreModule.DiscoverShoppingData.BuyingGuideData=e,o.AddDiscoverRenderModule(this.GetModuleName());else{const e=new CustomEvent(Ku.e1.PDPRemoved,{detail:{moduleName:this.GetModuleName()}});o.dispatchEvent(e)}}}},gD=new class{GetModuleName(){return r.ModuleNames.COUPONCLIPPING}UpdateData(e,t,i){}},fD=new class{GetModuleName(){return r.ModuleNames.DISCOVER_CHAT_CHIPS}UpdateData(t,i,n,o){let r=!0;if(e.R.isTestFlagActive(Zt.t.msShoppingTestExp2)&&(r=!1),!e.R.isExperimentActive(f.H.discoverShopping)||!r)return;let a=!1,s={},l=new Kt;if(t&&t.detail&&t.detail.data&&t.detail.data.shoppingDataContainer){const r=t.detail.data.shoppingDataContainer;l=Kt.Create(r,i,n.logModule,n.pageHandlerModule),e.R.getServiceExperimentValue(f.H.shorelineUAPIBackfill)===Yu.YR.Treatment&&(i.dataStoreModule.DiscoverShoppingData=l),i.common.shopping.querySelector("#discoverShoppingChatSection")||(s=l?.ChatChipsData?Ty.GetSuggestions(l.ChatChipsData,o):{},Object.keys(s).length>0&&(a=!0))}if(a&&l?.ChatChipsData&&Object.keys(s).length>0)this.waitForDiscoverModulesRender(l?.ChatChipsData,0,i,o);else{const e=new CustomEvent(Ku.e1.PDPRemoved,{detail:{moduleName:this.GetModuleName()}});o.dispatchEvent(e)}}waitForDiscoverModulesRender(e,t,i,n){const o=Ty.GetSuggestions(e,n),r=e?.ChatChips?Object.keys(e?.ChatChips).length:0;if(Object.keys(o).length===r||t>20&&Object.keys(o).length>0)i.dataStoreModule.DiscoverShoppingData||(i.dataStoreModule.DiscoverShoppingData=new Kt),i.dataStoreModule.DiscoverShoppingData.ChatChipsData=e;else if(t<35)window.setTimeout((()=>{this.waitForDiscoverModulesRender(e,t+1,i,n)}),100);else{const e=new CustomEvent(Ku.e1.PDPRemoved,{detail:{moduleName:this.GetModuleName()}});n.dispatchEvent(e)}}},mD=new class{GetModuleName(){return r.ModuleNames.PRICECOMPARISON}UpdateData(e,t,i){const n=e.detail?.data?.extracted_entity;i.dataValidationUtilities.checkExtractedDataForValidations(n);const o=e.detail?.data?.isShorelineOrigination;let r=!1;if(e&&e.detail&&e.detail.data&&e.detail.data.comparableOffers&&e.detail.data.comparableOffers.value&&e.detail.data.comparableOffers.value.length>0&&(e.detail.data.price||o)&&(r=!0),r){const i=e.detail.data;if(i)try{t.dataStoreModule.PriceComparisonData=new ce(i.comparableOffers,i.price,i.extracted_entity,i.page_locale),t.dataStoreModule.ProductSummaryCardData=new rt(t.dataStoreModule.CouponData,t.dataStoreModule.PriceComparisonData,t.dataStoreModule.PriceHistoryData,t.dataStoreModule.ProductTrackingData,t.dataStoreModule.CashBackData)}catch(e){}}}},vD=new class{GetModuleName(){return r.ModuleNames.PRICEHISTORY}UpdateData(e,t){const i=e.detail?.data?.isShorelineOrigination;if(e.detail?.data?.priceHistory?.priceHistoryData&&(e.detail.data.priceHistory.triggerInsight===de.MU.ShowInsight||i)){const n=e.detail.data;if(n){const e=n.extracted_entity?.image_url,o=n.extracted_entity?.entity?.image,r=n.extracted_entity?.entity?.price_currency,a=n.extracted_entity?.currency;t.dataStoreModule.PriceHistoryData=new de.ZP(n.priceHistory,n.price,n.base64ProductImage,o??e,t.common.domain,r??a,n.extracted_entity?.title,i),t.dataStoreModule.ProductSummaryCardData=new rt(t.dataStoreModule.CouponData,t.dataStoreModule.PriceComparisonData,t.dataStoreModule.PriceHistoryData,t.dataStoreModule.ProductTrackingData,t.dataStoreModule.CashBackData)}}i&&e.detail?.data?.extracted_entity&&!t.common.extractedEntity&&(t.common.extractedEntity=e.detail?.data?.extracted_entity)}},yD=new class{GetModuleName(){return r.ModuleNames.PRODUCTSUMMARYCARD}UpdateData(e,t){}},CD=new class{GetModuleName(){return r.ModuleNames.PRODUCT_SUMMARY}UpdateData(e,t){}},bD=new class{constructor(){(0,s.Z)(this,"isOutOfStock",void 0)}GetModuleName(){return this.isOutOfStock?r.ModuleNames.PRODUCT_TRACKING_OUT_OF_STOCK:r.ModuleNames.PRODUCT_TRACKING_PRICE_DROP}async UpdateData(e,t,i,n){const o=e.detail?.data?.isShorelineOrigination,r=e.detail?.data?.extracted_entity;let a;if(o&&(a=e.detail?.data?.price?.toString(),!a)){const t=e.detail?.data?.priceHistory?.priceHistoryData?.dailyPrice;t&&t?.length>0&&(a=t[t.length-1]?.priceData?.minPrice?.toString())}const s=new Ju(i,t,n);this.isOutOfStock=await s.checkIsOutOfStock();const l=s.extractExtractedEntityData(r,this.isOutOfStock,a);if(r&&(t.common.extractedEntity=r),!r||!l){const e=new CustomEvent(Ku.e1.PDPRemoved,{detail:this.GetModuleName()});n.dispatchEvent(e)}}},SD=new class{GetModuleName(){return r.ModuleNames.RELATED_PRODUCTS}UpdateData(e,t,i){}},xD=new class{GetModuleName(){return r.ModuleNames.SIMILARSELLERS}UpdateData(e,t,i){}},TD=new class{GetModuleName(){return r.ModuleNames.WISHLIST}async UpdateData(e,t,i,n){const o=e.detail?.data?.base64ProductImage,r=e.detail?.data?.extracted_entity;if(!o||!this.validateEntity(r)){const e=new CustomEvent(Ku.e1.PDPRemoved,{detail:this.GetModuleName()});return void n.dispatchEvent(e)}t.common.extractedEntity=r,t.common.base64ProductImage=o;const a=e.detail?.data?.priceHistory?.debug;a?.globalOfferIdList?.length>0&&(t.common.extractedEntity.globalOfferId=a.globalOfferIdList[0]),a?.productKey&&(t.common.extractedEntity.productKey=a?.productKey)}validateEntity(e){return!!(e&&e.title&&e.url&&e.image_url)}},wD=o(44092),OD=class extends Yy{constructor(...e){super(...e),(0,s.Z)(this,"visibilityFeedbackUrl",void 0)}createSearchShopping(t,i){const n=e.R.isExperimentActive(f.H.spbOffersSearch),o=document.getElementById("searchShopping");let r;o?r=o:(r=(0,Y.Ux)("msft-edge-shopping"),r.id="searchShopping"),n&&i&&r.appendChild(i);const a=this.createAndInitializeFeed(this.transformShoppingEntities(t,"en-us"),!i);return a&&r.appendChild(a),!n&&i&&r.appendChild(i),r}moduleFirstVisible(){}GetStartShoppingModuleName(){return r.ModuleNames.SEARCH_RESULTS}GetModulePriority(){return r.H7.MAX}GetCardClickTelemetry(){return{buttonName:i.$S.SearchResultsCard,engagement:q.FV.FEED_SEARCH_RESULTS,engagementMojom:q.ZF.FEED_SEARCH_RESULTS}}GetShowMoreClickTelemtry(){return{buttonName:i.$S.SearchResultsShowMore,action:K.bS.FEED_SEARCH_RESULTS_SHOW_MORE,actionMojom:K.R9.FEED_SEARCH_RESULTS_SHOW_MORE}}GetEnabledMarkets(){return new Set(["en-us"])}GetModuleViewed(){return bp.r.SEARCH_RESULTS}GetModuleViewedMojom(){return bp.L.SEARCH_RESULTS}createAndInitializeFeed(e,t=!0){if(document.getElementById("searchProductFeed")?.remove(),document.getElementById("noResultsDiv")?.remove(),e.length>0){const t=(0,Y.Ux)("msft-product-feed");return t.id="searchProductFeed",t.titleText="Search results",t.showMoreButtonText="Show more",t.adSlugText=this.flyoutData.strings.adSlug,t.includeAdSlug=!0,t.navigateToAdSlugDestination=this.navigateToAdSlugDestination.bind(this),t.logShowMoreButtonClicked=this.logShowMoreButtonClicked.bind(this,this.GetShowMoreClickTelemtry()),t.navigateToDestination=this.navigateToDestination.bind(this,this.GetCardClickTelemetry()),t.sendAdVisibilityFeedback=xl.bind(null,this.visibilityFeedbackUrl),xl(this.visibilityFeedbackUrl,e.slice(0,6).map((e=>e.impressionToken))),t.shoppingEntities=e,t}if(t)return this.createNoResultsDiv()}createNoResultsDiv(){const e=document.getElementById("searchBox").value,t=(0,Y.Ux)("DIV");t.id="noResultsDiv";const i=(0,Y.Ux)("img");i.id="noResultsImg",i.src=`${this.flyoutData.common.resourcesEndpoint}searchInPane/NoResultsImg.png`,i.setAttribute("aria-hidden","true");const n=(0,Y.Ux)("p");return n.id="noResultsMsg",n.textContent=`We didn't find any results for "${e}". Try another search or continue shopping.`,t.appendChild(i),t.appendChild(n),t}},PD=class{getStyles(){return`\n html {\n height: 100%;\n }\n .divContentWrapperLoading {\n margin: -8px;\n height: 100%;\n background-color: #F3F3F3;\n }\n .paneLoadingWrapper {\n display: flex;\n flex-direction: column;\n row-gap: 8px;\n background-color: #F3F3F3;\n }\n .loadingBlockWrapper {\n display: flex;\n padding: 20px;\n padding-bottom: 0px;\n margin-bottom: 5px;\n flex-direction: column;\n row-gap: 8px;\n background-color: #F3F3F3;\n }\n .largeBlock {\n width: 100%;\n height: 136px;\n border-radius: 8px;\n background-color: #FEFEFE;\n }\n .smallBlock {\n width: 120px;\n height: 24px;\n border-radius: 4px;\n background-color: #FEFEFE;\n }\n .shimmerBlock {\n display: inline-block;\n -webkit-mask: linear-gradient(-90deg,#000 30%,#0005,#000 70%) right/300% 100%;\n background-repeat: no-repeat;\n animation: shimmerBlock 2.5s infinite;\n }\n @keyframes shimmerBlock {\n 100% {-webkit-mask-position:left}\n }\n .loadingSpinnerIcon {\n width: 32px;\n height: 32px;\n animation: spin 2s linear infinite;\n }\n .loadingSpinnerWrapper {\n display: flex;\n flex-direction: row;\n gap: 10px;\n margin-top: 16px;\n margin-bottom: 24px;\n }\n .loadingSpinnerTitle {\n font-family: 'Segoe UI', 'Roboto', Helvetica, Verdana, sans-serif;\n color: #000000DB;\n font-weight: 400;\n font-size: 14px;\n align-self: center;\n }\n .spinningPart {\n fill: #2169EB;\n }\n .basePart {\n fill: #A7C9FC;\n }\n @keyframes spin {\n 0% { transform: rotate(0deg); }\n 100% { transform: rotate(360deg); }\n }\n msft-edge-shopping::part(start-content) {\n disply: flex !important;\n flex-direction: column !important;\n }\n @media (forced-colors: active) {\n .spinningPart {\n fill: ${Ns.Highlight} !important;\n }\n .basePart {\n fill: ${Ns.HighlightText} !important;\n }\n }\n `}getDarkModeStyles(){return"\n .divContentWrapperLoading {\n background-color: #3B3B3B;\n }\n .largeBlock {\n background-color: #424242;\n }\n .smallBlock {\n background-color: #424242;\n }\n .paneLoadingWrapper {\n background-color: #3B3B3B;\n }\n .loadingBlockWrapper {\n background-color: #3B3B3B;\n }\n .loadingSpinnerTitle {\n color: #FFFFFF;\n }\n "}getLoadingSpinner(){return eh.Z.getTrustedHTML`
<svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_3232_4425)">
<path class="basePart" d="M32 16C32 24.8366 24.8366 32 16 32C7.16344 32 0 24.8366 0 16C0 7.16344 7.16344 0 16 0C24.8366 0 32 7.16344 32 16ZM3.04 16C3.04 23.1576 8.84239 28.96 16 28.96C23.1576 28.96 28.96 23.1576 28.96 16C28.96 8.84239 23.1576 3.04 16 3.04C8.84239 3.04 3.04 8.84239 3.04 16Z"/>
<path class="spinningPart" d="M16 30.48C16 31.3195 16.682 32.0075 17.5177 31.9279C19.0984 31.7772 20.6508 31.3919 22.1229 30.7821C24.0641 29.978 25.828 28.7994 27.3137 27.3137C28.7994 25.828 29.978 24.0641 30.7821 22.1229C31.3919 20.6508 31.7772 19.0984 31.9279 17.5177C32.0075 16.682 31.3195 16 30.48 16C29.6405 16 28.9692 16.6828 28.871 17.5165C28.7318 18.6976 28.4304 19.8564 27.9735 20.9596C27.3222 22.532 26.3676 23.9607 25.1641 25.1641C23.9607 26.3676 22.532 27.3222 20.9596 27.9735C19.8564 28.4304 18.6976 28.7318 17.5165 28.871C16.6828 28.9692 16 29.6405 16 30.48Z"/>
</g>
<defs>
<clipPath id="clip0_3232_4425">
<rect width="32" height="32" rx="16" fill="white"/>
</clipPath>
</defs>
</svg>
`}};class AD{static getSpinnerTimeout(){let t=AD.defaultSpinnerTimeoutInMs;if(e.R.isExperimentActive(f.H.loadingSpinnerWithTimeout)){const i=e.R.getServiceExperimentValue(f.H.loadingSpinnerWithTimeout);t=i?parseInt(i):AD.defaultSpinnerTimeoutInMs}return t}static addPaneLoadingState(e){if(e){"divContentWrapper"===e.id&&e.classList.add("divContentWrapperLoading");const t=new PD;this.applyStyles(e,t.getStyles(),this.loadingStateStylesId,t.getDarkModeStyles());const i=this.createPaneLoadingState();e.appendChild(i)}}static addLoadingSpinnerWrapper(e,t){if(e){const i=new PD;this.applyStyles(e,i.getStyles(),this.loadingStateStylesId,i.getDarkModeStyles());const n=document.createElement("DIV");n.className="loadingSpinnerWrapper",n.slot="start-content";const o=AD.createLoadingSpinnerIcon(i);n.appendChild(o);const r=AD.createLoadingSpinnerTitle(t);n.appendChild(r),e.prepend(n)}}static removeLoadingSpinnerWrapper(){const e=document.querySelector(".loadingSpinnerWrapper");e&&e.remove();const t=document.querySelector("#contextualShopping");t&&this.removeStyles(t,this.loadingStateStylesId)}static removePaneLoadingState(){const e=document.querySelector(".paneLoadingWrapper");e&&e.parentNode&&e.parentNode.removeChild(e);const t=document.querySelector(".msft-edge-shopping-loading-state");t&&t.parentNode&&t.parentNode.removeChild(t);const i=document.querySelector("#divContentWrapper");i&&this.removeStyles(i,this.loadingStateStylesId)}static createLoadingSpinnerIcon(e){const t=document.createElement("DIV");return t.innerHTML=e.getLoadingSpinner(),t.className="loadingSpinnerIcon",t.setAttribute("aria-hidden","true"),t}static createLoadingSpinnerTitle(e){const t=document.createElement("DIV");return t.textContent=e,t.className="loadingSpinnerTitle",t}static createPaneLoadingState(){const e=this.getLoadingStateWrapper(),t=this.getLoadingBlock();return e.append(t),e.appendChild(t.cloneNode(!0)),e.appendChild(t.cloneNode(!0)),e.appendChild(t.cloneNode(!0)),e}static getLoadingStateWrapper(){const e=document.createElement("DIV");return e.className="paneLoadingWrapper",e}static getSmallLoadingBlock(){const e=document.createElement("DIV");return e.className="smallBlock shimmerBlock",e}static getLargeLoadingBlock(){const e=document.createElement("DIV");return e.className="largeBlock shimmerBlock",e}static getLoadingBlock(){const e=document.createElement("DIV");e.className="loadingBlockWrapper";const t=this.getSmallLoadingBlock(),i=this.getLargeLoadingBlock();return e.appendChild(t),e.appendChild(i),e}static applyStyles(e,t,i,n){if(e){const o=document.createElement("STYLE");let r=t;const a=window;!!(a&&a.matchMedia&&a.matchMedia("(prefers-color-scheme: dark)").matches)&&(r=`${r}\n${n}`),o.textContent=r,o.type="text/css",o.rel="stylesheet",i&&(o.id=i),e.appendChild(o)}}static removeStyles(e,t){if(e){e.classList.remove("divContentWrapperLoading");const i=e.querySelector(`#${t}`);i&&i.remove()}}}(0,s.Z)(AD,"loadingStateStylesId","loadingStateStyles"),(0,s.Z)(AD,"defaultSpinnerTimeoutInMs",3e3);var ED=AD;class kD{constructor(){(0,s.Z)(this,"CASHBACK_TRANSACTIONS_API_URL","https://www.bing.com/api/shopping/v1/savings/cashback/userTransactions"),(0,s.Z)(this,"API_CALL_TIMEOUT_MS",1e3),(0,s.Z)(this,"cache",void 0),this.cache=null}static getInstance(){return kD.instance||(kD.instance=new kD),kD.instance}async FetchCashbackTransactions(e,t,n){if(this.cache)return this.cache;try{const i=t.IsMessageAllowed("getEdgeAnid")?(await t.GetEdgeAnid(!0))?.anid??"":await(0,we.H)(t);if(!i)return e.dataStoreModule.UserInfo.isAadEmailPresent?null:{isSignedIn:!1};const n=e.common.muid,o=n?`&Muid=${n}`:"",r=`${this.CASHBACK_TRANSACTIONS_API_URL}?Anid=${i}${o}`,a=await fetch(r,{signal:AbortSignal.timeout(this.API_CALL_TIMEOUT_MS)}),s=await a.json();if(!a.ok)throw new Error(`${a.status} - ${a.statusText}: ${JSON.stringify(s,null,2)}`);if(s){const e={isSignedIn:!0,profile:s?.profile,enrolled:s?.enrolled,formattedTransactions:s?.formatted_Transactions,activatedOffers:s?.activatedOffers?.adsCashback,totalTransactions:s?.totalTransactions,topCashbackOffers:s?.topCashbackOffers};return this.cache=e,e}}catch(e){this.logError(n,"Visual search failed",this.CASHBACK_TRANSACTIONS_API_URL,"",i.xu.CashbackDataFetchError,e)}return null}logError(e,n,o,r,a,s){const l=this.createErrorMessage(n,o,r,s);e.LogErrorEvent(i.R.EdgeFlyoutStatus,l,new t.Z(a),Jl.g.EdgeImpressionId)}createErrorMessage(e,t,i,n){return JSON.stringify({message:n?`${e} | ${n}`:e,url:t,requestBody:i})}}(0,s.Z)(kD,"instance",void 0);var ID=class extends JI{constructor(n,o,a,l,c,d,u,h,p){super(n,o,a,l,c,d,u),(0,s.Z)(this,"tabs",void 0),(0,s.Z)(this,"assets",new SI),(0,s.Z)(this,"panelHomeId",r.UB.Home),(0,s.Z)(this,"tabHomeId",r.d$.Home),(0,s.Z)(this,"panelContextualId",r.UB.Contextual),(0,s.Z)(this,"tabContextualId",r.d$.Contextual),(0,s.Z)(this,"tabCashbackId",r.d$.Cashback),(0,s.Z)(this,"panelCashbackId",r.UB.Cashback),(0,s.Z)(this,"tabCashbackIndex",4),(0,s.Z)(this,"cashbackTabHeaderId","cashbackTabHeader"),(0,s.Z)(this,"contextualShopping","contextualShopping"),(0,s.Z)(this,"homeShopping","homeShopping"),(0,s.Z)(this,"cashbackShopping","cashbackShopping"),(0,s.Z)(this,"domainEligible",!1),(0,s.Z)(this,"homeModules",void 0),(0,s.Z)(this,"contextualModules",void 0),(0,s.Z)(this,"lastCommittedUrl",""),(0,s.Z)(this,"shoppingTabId","shoppingTab"),(0,s.Z)(this,"searchInPaneModule",void 0),(0,s.Z)(this,"settingsPane",void 0),(0,s.Z)(this,"settingsPaneId","settingsPane"),(0,s.Z)(this,"isNotificationEnabled",!0),(0,s.Z)(this,"flyoutWrapper",void 0),(0,s.Z)(this,"panelSingleScrollingId",r.UB.SingleScrolling),(0,s.Z)(this,"tabMyShoppingId",r.d$.MyShopping),(0,s.Z)(this,"tabCouponsSavingsId",r.d$.CouponsSavings),(0,s.Z)(this,"tabExploreId",r.d$.Explore),(0,s.Z)(this,"exploreModules",void 0),(0,s.Z)(this,"myShoppingShopping",r.Hp.MyShopping),(0,s.Z)(this,"couponsSavingsShopping",r.Hp.CouponsSavings),(0,s.Z)(this,"exploreShopping",r.Hp.Explore),(0,s.Z)(this,"singleScrollingShopping",r.Hp.SingleScrolling),(0,s.Z)(this,"singleScrollingPaneWrapper",void 0),(0,s.Z)(this,"isSingleScrollingPane",void 0),(0,s.Z)(this,"isMyShoppingZeroState",!1),(0,s.Z)(this,"isCouponsSavingsZeroState",!1),(0,s.Z)(this,"isExploreZeroState",!1),(0,s.Z)(this,"singleScrollingActiveTabId",void 0),(0,s.Z)(this,"singleScrollingIntersectionObserver",void 0),(0,s.Z)(this,"observeIntervalID",void 0),(0,s.Z)(this,"isCjkEnabled",!1),(0,s.Z)(this,"trendingCouponsModule",void 0),(0,s.Z)(this,"trendingCouponsModuleType",void 0),(0,s.Z)(this,"autoOpenControllerUtilities",void 0),(0,s.Z)(this,"deferredCashbackModules",void 0),h&&(this.deferredCashbackModules=h),(new class{constructor(){(0,s.Z)(this,"stateManagement",void 0)}init(n,o,r){this.stateManagement=n;const a=[mD,vD,bD,pD,fD,TD,hD,yD,SD,xD,gD];e.R.getServiceExperimentValue(f.H.shorelineUAPIBackfill)===Yu.YR.Treatment&&a.push(CD),this.stateManagement.addEventListener(Ku.e1.PDPUpdate,(async e=>{if(e.detail?.data?.isShorelineOrigination&&o.common.extractedEntity)return;const s=e?.detail?.perfTracker;s?.markEvent(Is.FlyoutInitializeModuleDataStart);for(const s of a)try{await s.UpdateData(e,o,r,n)}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);r.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Error while updating PDP modules: ${s.GetModuleName()} ${(0,dt.YU)(e)}`,n)}s?.markEvent(Is.FlyoutInitializeModuleDataEnd),s?.addFlyoutData(o),s?.addLogModule(r.logModule);const l=!o.common.isShorelineOrigination;if(e.detail.data.isShorelineOrigination&&(o.common.isShorelineOrigination=!0,globalThis.pdpUpdated=!0,e.detail.data.price&&o.dataLoader.SetLoadTimeDataValue("price",e.detail.data.price)),l){const t=new CustomEvent(Ku.e1.ReRankFlyout,{detail:{refreshType:Mg.PDP,moduleNames:a.map((e=>e.GetModuleName())),perfTracker:s,isShorelineOrigination:e.detail?.data?.isShorelineOrigination}});this.stateManagement.dispatchEvent(t)}}))}}).init(n,o,a),this.pageHandlerModule.TriggerExperiment(f.H.singleScrollingShoreline),this.isSingleScrollingPane=e.R.isExperimentActive(f.H.singleScrollingShoreline),this.isCjkEnabled=o.common.isCJKEnabled,this.autoOpenControllerUtilities=a.autoOpenControllerUtilities,this.isSingleScrollingPane&&(this.singleScrollingPaneWrapper=document.createElement("msft-edge-shopping"),this.singleScrollingPaneWrapper.id=this.singleScrollingShopping),this.domainEligible=this.flyoutData.common.isDomainEligible,this.isNotificationEnabled=this.flyoutData.common.isNotificationEnabled,p&&(this.trendingCouponsModule=p);const g=document.querySelector("fluent-tabs");if(g?this.tabs=g:(this.tabs=(0,Y.Ux)("fluent-tabs"),this.tabs.id=this.shoppingTabId,this.tabs.setAttribute("orientation","horizontal")),e.R.isExperimentActive(f.H.shoppingSettingsInPane)){const e=document.getElementById(this.settingsPaneId);e?this.settingsPane=e:(this.createSettingsPane(),this.utilities.viewModulesUtilities.applyStyles(this.settingsPane,this.assets.getSettingsPaneStyles()))}try{new class{constructor(e,t){this.stateMgmt=e,this.flyoutData=t,(0,s.Z)(this,"toastWrapper",void 0),(0,s.Z)(this,"pendingToasts",[]),(0,s.Z)(this,"MAX_TOASTS",3),(0,s.Z)(this,"currentToastsCount",0),(0,s.Z)(this,"removingToast",!1)}renderModule(){const e=document.querySelector("#divContentWrapper");if(!e)return;let t=e.querySelector("section#toastContainer");t||(t=this.createToastContainer(),this.toastWrapper=t.firstElementChild,e.appendChild(t)),this.subscribeToToastEvent()}subscribeToToastEvent(){this.stateMgmt.addEventListener(Ku.e1.ToastNotification,(e=>{const t=this.extractToast(e);t&&(this.pendingToasts.push(t),this.checkAndInsertToasts())}))}canAddToast(){return this.currentToastsCount<this.MAX_TOASTS&&!this.removingToast}createToastContainer(){const e=(0,Y.Ux)("section",{id:"toastContainer"}),t=(0,Y.Ux)("div",{id:"toastWrapper"});return e.appendChild(t),e}createToast(e){const t=(0,Y.Ux)("output",{className:"toast"}),i=(0,Y.Ux)("div",{className:"toastTextContainer"});e.title&&i.appendChild((0,Y.Ux)("h3",{className:"toastTitle"},e.title));const n=(0,Y.Ux)("p",{className:"toastText"+(e.title?" withTitle":"")},e.text);i.appendChild(n);const o=(0,Y.Ux)("fluent-button",{className:"toastClose"});return o.appendChild((0,Y.Ux)("p",{},String.fromCharCode(215))),o.setAttribute("aria-label",this.flyoutData.strings.commonClose),o.addEventListener("click",(()=>this.animateRemoveToast(t))),t.appendChild(i),t.appendChild(o),this.currentToastsCount++,this.animateInsertToast(t)?t:null}animateInsertToast(e){if(!this.toastWrapper)return!1;this.toastWrapper?.appendChild(e);const t=this.toastWrapper.offsetHeight+10;return this.toastWrapper.animate({transform:`translateY(-${t}px)`},{duration:200,fill:"forwards"}),!0}async animateRemoveToast(e){if(!this.toastWrapper||!e)return;const t=this.toastWrapper.offsetHeight-e.offsetHeight;this.removingToast=!0,e.animate({transform:"translateY(40%)",opacity:.3},{duration:250,fill:"forwards"}),await this.toastWrapper.animate({transform:`translateY(-${t}px)`},{duration:400,fill:"forwards",easing:"ease"}).finished,this.toastWrapper?.removeChild(e),this.removingToast=!1,this.currentToastsCount--,this.checkAndInsertToasts()}checkAndInsertToasts(){if(!this.pendingToasts.length||!this.canAddToast())return;const e=this.pendingToasts.shift();if(e){const t=this.createToast(e),i=Math.min(5e3,e.duration??2e3);window.setTimeout(this.animateRemoveToast.bind(this),i,t)}}extractToast(e){return e.detail&&e.detail.text?e.detail:null}}(this.stateManagement,this.flyoutData).renderModule()}catch(e){const n=new t.Z(i.xu.ToastNotificationError);n.Metadata=e,this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,"Failed to insert toast notification module",n)}}renderModules(t,i){this.utilities.viewModulesUtilities.applyStyles(i,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),i.style.setProperty("--scrollbar-width",`${this.calculateScrollBarWidth()}px`),this.stateManagement.addEventListener(Ku.e1.PWILOEmpty,(()=>{const e=t.filter((e=>e.paneTab===r.$k.HOME))?.sort(((e,t)=>e.priority-t.priority));if(e&&1===e.length&&e[0].name===r.ModuleNames.PRODUCTHISTORY){if(this.isSingleScrollingPane){const e=document.getElementById(`${this.myShoppingShopping}`);e&&e.remove();const t=this.tabs.querySelector(`#${this.tabMyShoppingId}`);if(t){const e=this.getZeroStateContainer(this.myShoppingShopping);this.isMyShoppingZeroState=!0,this.manageTabControls(t,!1,e)}}else{const e=document.querySelector(`#${this.homeShopping}`);e&&e.remove();const t=this.tabs.querySelector(`#${this.tabHomeId}`);t&&this.manageTabControls(t,!1,null)}this.domainEligible?this.switchTabs(!0):this.switchTabs(!1)}})),e.R.isExperimentActive(f.H.shorelineinboxcoupons)&&this.stateManagement.addEventListener(Ku.e1.ActiveRetailerInboxCouponsEmpty,(()=>{const e=t.filter((e=>e.paneTab===r.$k.CONTEXTUAL))?.filter((e=>e.name!==r.ModuleNames.ACTIVE_RETAILER_INBOX_COUPONS));if(!e||e&&0===e.length)if(this.isSingleScrollingPane){const e=document.getElementById(`${this.couponsSavingsShopping}`);e&&e.remove();const t=this.tabs.querySelector(`#${this.tabCouponsSavingsId}`);if(t){const e=this.getZeroStateContainer(this.couponsSavingsShopping);this.isCouponsSavingsZeroState=!0,this.manageTabControls(t,!1,e)}this.switchTabs(this.domainEligible)}else{const e=document.querySelector(`#${this.panelContextualId}`);this.createNullState(e);const t=document.querySelector(`#${this.tabHomeId}`),i=document.querySelector(`#${this.panelHomeId}`);t&&i&&(this.manageTabControls(t,!0,i),this.setActiveTabId(this.tabHomeId),this.updateTabItemsStyling(1))}}));const n=[];if(this.stateManagement.addEventListener(Ku.e1.PDPRemoved,(e=>{if(e&&e.detail&&e.detail.moduleName){n.push(e.detail.moduleName);const i=t.filter((e=>e.paneTab===r.$k.CONTEXTUAL&&-1===n.findIndex((t=>t===e.name))&&e.name!==r.ModuleNames.FEEDBACK&&e.name!==r.ModuleNames.EMPTYCOUPON))?.sort(((e,t)=>e.priority-t.priority));if(!i||i&&0===i.length)if((0,h.Xo)("isPDP","false"),this.isSingleScrollingPane){const e=document.getElementById(`${this.couponsSavingsShopping}`);e&&e.remove();const t=this.tabs.querySelector(`#${this.tabCouponsSavingsId}`);if(t){const e=this.getZeroStateContainer(this.couponsSavingsShopping);this.isCouponsSavingsZeroState=!0,this.manageTabControls(t,!1,e)}this.switchTabs(this.domainEligible)}else{const e=document.querySelector(`#${this.panelContextualId}`);this.createNullState(e);const t=document.querySelector(`#${this.tabHomeId}`),i=document.querySelector(`#${this.panelHomeId}`);t&&i&&(this.manageTabControls(t,!0,i),this.setActiveTabId(this.tabHomeId),this.updateTabItemsStyling(1))}}})),this.isSingleScrollingPane){const e=document.getElementById(`${this.panelSingleScrollingId}`);let n;e?n=e:(n=(0,Y.Ux)("fluent-tab-panel"),n.id=this.panelSingleScrollingId),n.appendChild(this.singleScrollingPaneWrapper),e||this.tabs.appendChild(n),this.renderMyShoppingSection(t,i),this.renderCouponsSavingsSection(t,i),this.renderExploreSection(t,i)}else this.renderHomeModules(t,i),this.renderContextualModules(t,i),this.flyoutWrapper=i;this.stateManagement.addEventListener(Ku.e1.ModulesRendered,(e=>{gn.SO.queueUpdate((async()=>{let e,i,n=this.tabs.getAttribute("activeid");this.isSingleScrollingPane&&(this.addSentinels(),this.setIntersectionObservers(),this.handleSingleScrollingTabsOnStartUp(),n=this.singleScrollingActiveTabId),n===this.tabContextualId||this.isSingleScrollingPane&&n===this.tabCouponsSavingsId?(e=r.$k.CONTEXTUAL,i=this.flyoutData.common.shopping,this.pageHandlerModule.TriggerExperiment(f.H.paneOpenWithTab2)):n===this.tabHomeId||this.isSingleScrollingPane&&n===this.tabMyShoppingId?(e=r.$k.HOME,i=this.flyoutData.common.shoppingPersistent,this.pageHandlerModule.TriggerExperiment(f.H.paneOpenWithTab1)):n===this.tabCashbackId?(e=r.$k.CASHBACK,i=this.flyoutData.common.shoppingCashback):this.isSingleScrollingPane&&n===this.tabExploreId&&(e=r.$k.EXPLORE,i=this.flyoutData.common.shoppingExplore);const o=t.filter((t=>t.paneTab===e))?.sort(((e,t)=>e.priority-t.priority));this.handleFlyoutFocus(o,void 0,i,!1),(!this.isCjkEnabled||this.isCjkEnabled&&!this.stateManagement.getState(Ku.IY.shouldChangeTitle))&&this.restoreTabName();const a=document.querySelectorAll(".settingsFeatureSwitch");this.isNotificationEnabled||a.forEach((e=>{e.disabled=!0}))}));const i=e?.detail?.perfTracker;i?.markEvent(Is.FlyoutRenderEnd),this.createCashbackTab()}));const o=this.getActiveTabId();GI.TrackVisibilityForModules(t,o,this.utilities.telemetryHandler),(0,h.TJ)(Jp._.InboxCouponsUpsellOpen)}appendContentToFlyout(n){if(n){const o=new t.Z(i.xu.AppendNodeError);let a;if(this.flyoutData.common.isSharedHeader){const e=(0,Y.Ux)("DIV");n.appendChild(e);try{this.createUnifedHeaderShoppingMenu(e,n)}catch(e){this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,"Failure when creating mainHeader on Pane - Unified header",o)}}else{const e=document.querySelector("#divMainHeader");e&&e.remove();try{a=this.createMainShoppingHeader(n),n.appendChild(a)}catch(e){this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,"Failure when creating mainHeader on Pane",o)}}if(e.R.isExperimentActive(f.H.searchInPane)&&!this.isCjkEnabled){try{a&&(a.style.borderBottom="none"),this.searchInPaneModule=new class{constructor(e,t,i,n,o,r){(0,s.Z)(this,"resultsHistory",void 0),(0,s.Z)(this,"currentResultIndex",void 0),(0,s.Z)(this,"searchResultsModule",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"tabs",void 0),(0,s.Z)(this,"flyOutWrapper",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"spbComponentUtils",void 0),(0,s.Z)(this,"groceryComponentUtils",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),this.flyoutData=n,this.commonAssets=e,this.tabs=t,this.flyOutWrapper=i,this.searchResultsModule=new OD(this.flyoutData,o),this.logModule=r,this.pageHandlerModule=o.pageHandlerModule,this.resultsHistory=JSON.parse((0,wD.Lt)("resultsHistory")??"[]");const a=(0,wD.Lt)("currentResultIndex");this.currentResultIndex=a?JSON.parse(a):this.resultsHistory.length-1,this.spbComponentUtils=new pg(n,o,this.commonAssets),this.groceryComponentUtils=new Rg(this.flyoutData,o,this.commonAssets),this.telemetryUtilities=o.telemetryHandler}createSearchDiv(){let e;const t=document.getElementById("searchDiv");return t?e=t:(e=(0,Y.Ux)("DIV"),e.id="searchDiv",this.flyoutData.common.isSharedHeader&&(e.style.paddingTop="10px")),this.createSearchArrows(e),this.createSearchBoxWrapper(e),e}createSearchArrows(e){const t=document.getElementById("leftArrowBtn");let n;if(t)n=t;else{n=(0,Y.Ux)("fluent-button"),n.id="leftArrowBtn",n.appearance="stealth",n.disabled=!0,n.setAttribute("aria-label","Previous search result");const t=(0,Y.Ux)("DIV");t.style.display="flex",t.style.alignContent="center",t.innerHTML=this.commonAssets.getLeftArrowIcon(),n.appendChild(t),e.appendChild(n)}const o=document.getElementById("rightArrowBtn");let a;if(o)a=o;else{a=(0,Y.Ux)("fluent-button"),a.id="rightArrowBtn",a.appearance="stealth",a.disabled=!0,a.setAttribute("aria-label","Next search result");const t=(0,Y.Ux)("DIV");t.style.display="flex",t.style.alignContent="center",t.innerHTML=this.commonAssets.getRightArrowIcon(),a.appendChild(t),e.appendChild(a)}n.addEventListener("click",(()=>{0===this.currentResultIndex?this.createPaneInitialState():this.currentResultIndex>0&&(this.currentResultIndex--,(0,wD.i8)("currentResultIndex",JSON.stringify(this.currentResultIndex)),document.getElementById("searchBox").value=this.resultsHistory[this.currentResultIndex].qry,document.getElementById("dismissBtn")?.setAttribute("style","display: flex"),this.searchResultsModule.createSearchShopping(this.resultsHistory[this.currentResultIndex].products)),a.disabled=!1;const e=new W.Z(i.$S.PreviousSearchResults,this.telemetryUtilities.setContentViewed(r.ModuleNames.SEARCH_IN_PANE));this.logModule.LogInfoEvent(i.R.ButtonClick,"Previous search results button clicked",e)})),a.addEventListener("click",(()=>{if(this.currentResultIndex<this.resultsHistory.length-1){this.currentResultIndex++,(0,wD.i8)("currentResultIndex",JSON.stringify(this.currentResultIndex)),document.getElementById("searchBox").value=this.resultsHistory[this.currentResultIndex].qry,document.getElementById("dismissBtn")?.setAttribute("style","display: flex");const e=this.searchResultsModule.createSearchShopping(this.resultsHistory[this.currentResultIndex].products);this.currentResultIndex===this.resultsHistory.length-1&&(a.disabled=!0),0===this.currentResultIndex&&(this.tabs.style.display="none",this.flyOutWrapper.appendChild(e))}n.disabled=!1;const e=new W.Z(i.$S.NextSearchResults,this.telemetryUtilities.setContentViewed(r.ModuleNames.SEARCH_IN_PANE));this.logModule.LogInfoEvent(i.R.ButtonClick,"Next search results button clicked",e)}))}createSearchBoxWrapper(e){const t=document.getElementById("searchBoxWrapper");let i;t?i=t:(i=(0,Y.Ux)("DIV"),i.id="searchBoxWrapper",e.appendChild(i)),this.createSearchBox(i)}createSearchBox(e){const t=document.getElementById("searchBox");let n;t?n=t:(n=(0,Y.Ux)("fluent-text-field"),n.id="searchBox",n.setAttribute("aria-label","Shopping search bar"),n.placeholder="Search and shop the web",this.createSearchIcon(n),e.appendChild(n)),window.addEventListener("click",(e=>{e.target!==n&&this.removeSearchResultsMenu()})),n.addEventListener("focus",(()=>{this.pageHandlerModule.RecordAsUserAction(K.bS.SEARCH_BOX_FOCUSED),this.pageHandlerModule.RecordAsUserEngagement(q.FV.SEARCH_BOX_FOCUSED,this.flyoutData.common.popupOrigination);const e=new W.Z(i.$S.SearchBoxInput,this.telemetryUtilities.setContentViewed(r.ModuleNames.SEARCH_IN_PANE));this.logModule.LogInfoEvent(i.R.ButtonClick,"Search box focused",e)})),n.addEventListener("input",this.debounce((()=>this.createSearchResultsMenu(e,n)),150)),n.addEventListener("keydown",(async e=>{"ArrowDown"===e.key&&document.getElementById("searchResultsMenu")?.focus(),"Escape"===e.key&&this.removeSearchResultsMenu(),"Enter"===e.key&&await this.displayProducts(n.value)})),this.createDismissBtn(n)}createDismissBtn(e){const t=document.getElementById("dismissBtn");let n;if(t)n=t;else{n=(0,Y.Ux)("fluent-button"),n.id="dismissBtn",n.appearance="stealth",n.setAttribute("tabindex","-1"),n.slot="end",n.style.display="none";const t=(0,Y.Ux)("DIV");t.style.display="flex",t.style.alignContent="center",t.innerHTML=this.commonAssets.getDismissIcon(),n.appendChild(t),e.appendChild(n)}n.addEventListener("click",(()=>{this.createPaneInitialState();const e=new W.Z(i.$S.SearchDismissButton,this.telemetryUtilities.setContentViewed(r.ModuleNames.SEARCH_IN_PANE));this.logModule.LogInfoEvent(i.R.ButtonClick,"Search dismiss button clicked",e)}))}async createSearchResultsMenu(e,t){const i=document.getElementById("searchResultsMenu");if(i&&i.remove(),t.value.length>0){document.getElementById("dismissBtn")?.setAttribute("style","display: flex");const i=await this.fetchSuggestions(t.value);if(i.suggestions?.length>0){t.setAttribute("resultsVisible","true");const n=(0,Y.Ux)("fluent-menu");n.id="searchResultsMenu",n.setAttribute("aria-label","Search results"),n.addEventListener("keydown",(e=>{"Escape"===e.key&&(this.removeSearchResultsMenu(),t.focus())})),i.suggestions.forEach(((e,o)=>{const r=(0,Y.Ux)("fluent-menu-item");r.id=`searchMenuItem${o}`,r.classList.add("searchMenuItem"),r.textContent=e,r.addEventListener("click",(async()=>{t.value=e,await this.displayProducts(e)})),r.addEventListener("keydown",(e=>{"Enter"===e.key&&r.click(),0===o&&("ArrowUp"===e.key||"Tab"===e.key&&e.shiftKey)?(document.getElementById("searchMenuItem"+(i.suggestions.length-1))?.focus(),e.preventDefault()):"Tab"===e.key&&e.shiftKey?(document.getElementById("searchMenuItem"+(o-1))?.focus(),e.preventDefault()):o!==i.suggestions.length-1||"ArrowDown"!==e.key&&"Tab"!==e.key?"Tab"===e.key&&(document.getElementById(`searchMenuItem${o+1}`)?.focus(),e.preventDefault()):(document.getElementById("searchMenuItem0")?.focus(),e.preventDefault())})),this.createSearchIcon(r),n.appendChild(r)})),e.appendChild(n)}else t.setAttribute("resultsVisible","false")}else document.getElementById("dismissBtn")?.setAttribute("style","display: none"),t.setAttribute("resultsVisible","false")}createSearchIcon(e){const t=(0,Y.Ux)("DIV");t.id="searchIcon",t.slot="start",t.setAttribute("aria-hidden","true"),t.style.display="flex",t.style.alignContent="center",t.innerHTML=this.commonAssets.getSearchIcon(),e.appendChild(t)}removeSearchResultsMenu(){document.getElementById("searchResultsMenu")?.remove(),document.getElementById("searchBox")?.setAttribute("resultsVisible","false")}debounce(e,t){let i;return(...n)=>{clearTimeout(i),i=setTimeout((()=>{e.apply(this,n)}),t)}}async fetchSuggestions(e){const t=await fetch(`https://www.bing.com/api/shopping/v1/savings/shoppingSuggestions?qry=${e}`);return await t.json()}async fetchProductsFromSyndication(e){const t={muid:this.flyoutData.common.muid},i={headers:{"Content-Type":"application/json"},method:"POST",body:JSON.stringify(t)},n=`https://www.bing.com/api/shopping/v1/savings/shoppingProducts?qry=${e}`,o=await fetch(n,i),r=await o.json();return this.searchResultsModule.visibilityFeedbackUrl=r.visibilityFeedbackUrl??"",this.transformSyndicationResponse(r.value)}transformSyndicationResponse(e){return e.map((e=>({adType:"SearchResults",title:e.offer.itemOffered.name,seller:e.offer.seller.name,imageInfo:{altText:e.offer.itemOffered.Description+" image",sourceImageUrl:e.offer.itemOffered.image.contentUrl},priceInfo:{price:e.offer?.price.toString()??0,priceCurrencySymbol:e.offer.priceCurrencySymbol},globalOfferId:e.globalOfferId,shippingPrice:e.shippingInfo?.price.toString()??0,destination:e.offer.url,impressionToken:e.impressionToken})))}async displayProducts(e){this.removeSearchResultsMenu(),document.getElementById("leftArrowBtn").disabled=!1,this.currentResultIndex++,(0,wD.i8)("currentResultIndex",JSON.stringify(this.currentResultIndex)),this.tabs.style.display="none";const t=this.fetchProductsFromSyndication(e),n=this.fetchSpbAndQtData(e),[o,{spbOffersWrapper:a,offersCount:s}]=await Promise.all([t,n]);this.resultsHistory.splice(this.currentResultIndex,0,{qry:e,products:o}),(0,wD.i8)("resultsHistory",JSON.stringify(this.resultsHistory));const l=this.searchResultsModule.createSearchShopping(o,a);this.flyOutWrapper.appendChild(l),this.pageHandlerModule.RecordAsUserAction(K.bS.FETCH_SEARCH_RESULTS),this.pageHandlerModule.RecordAsUserEngagement(q.FV.FETCH_SEARCH_RESULTS,this.flyoutData.common.popupOrigination);const c=`Searched for "${e}" and found ${o.length} products`,d=new W.Z(i.$S.FetchSearchResults,this.telemetryUtilities.setContentViewed(r.ModuleNames.SEARCH_IN_PANE));this.logModule.LogInfoEvent(i.R.ButtonClick,c,d);const u=`Searched for "${e}" and found ${s} products`,h=new W.Z(i.$S.FetchSearchResultsSpb,this.telemetryUtilities.setContentViewed(r.ModuleNames.SEARCH_IN_PANE));this.logModule.LogInfoEvent(i.R.ButtonClick,u,h)}createPaneInitialState(){document.getElementById("dismissBtn")?.setAttribute("style","display: none"),this.removeSearchResultsMenu(),document.getElementById("searchBox").value="",this.currentResultIndex>=0&&(document.getElementById("searchShopping")?.remove(),this.tabs.style.display="grid",document.getElementById("leftArrowBtn").disabled=!0,document.getElementById("rightArrowBtn").disabled=!1,this.currentResultIndex=-1,(0,wD.i8)("currentResultIndex",JSON.stringify(this.currentResultIndex)))}async fetchSpbAndQtData(e){const t=(new Date).getTime(),i=await this.spbComponentUtils.GetSearchResults(e,dg.x.SearchInPaneMain),n=(new Date).getTime();return await this.spbComponentUtils.OnNewSearchResultsSpbOrQt(i,t,n,e,this.groceryComponentUtils)}}(this.commonAssets,this.tabs,n,this.flyoutData,this.utilities,this.logModule);const e=this.searchInPaneModule.createSearchDiv();n.appendChild(e)}catch(e){this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,"Failure when creating searchDiV on Pane",o)}try{let e=document.getElementById("searchShopping");if(e){const t=this.searchInPaneModule.currentResultIndex,i=this.searchInPaneModule.resultsHistory[t].products;e=this.searchInPaneModule.searchResultsModule.createSearchShopping(i),n.appendChild(e)}}catch(e){this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,"Failure when creating search results module on Pane",o)}}try{n.appendChild(this.tabs),e.R.isExperimentActive(f.H.shoppingSettingsInPane)&&n.appendChild(this.settingsPane)}catch(e){this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,"Failure when appending tabs to Pane",o)}gn.SO.queueUpdate((()=>{if(this.tabs){const e=this.tabs.shadowRoot?.querySelector(".tablist");e&&(e.title=this.flyoutData.strings.commonFixedTitle);const t=this.tabs.shadowRoot?.querySelector(".tabpanel");t&&(t.style.overflow="auto",this.utilities.viewModulesUtilities.isDarkMode()?t.style.backgroundColor="rgb(59, 59, 59)":t.style.backgroundColor="rgb(243, 243, 243)")}}))}}addEventsListeners(n){this.isCjkEnabled&&this.stateManagement.addEventListener(Ku.e1.ChangeContextualTitle,(e=>{if(this.tabs){const t=this.tabs.querySelector(`#${this.tabContextualId}`);t&&(t.textContent=e.detail.title)}})),this.stateManagement.addEventListener(Ku.e1.ShoppingSettingsOpened,(async n=>{if(e.R.isExperimentActive(f.H.shoppingSettingsInPane))try{const e=document.getElementById(this.settingsPaneId),n=document.getElementById(this.shoppingTabId);if(e&&n)if("flex"===e.style.display)e.style.display="none",n.style.display="grid";else{n.style.display="none",e.style.display="flex";const o=new t.Z(i.xu.PaneSettingsView);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"",o)}}catch(n){}})),this.stateManagement.addEventListener(Ku.e1.ReRankFlyout,(async e=>{await this.ReRankPane(e,n)})),this.stateManagement.addEventListener(Ku.e1.onDataUpdate,(e=>{e&&e.detail&&e.detail.moduleType&&this.styleModulesInPane(e.detail.moduleType,n)})),this.stateManagement.addEventListener(Ku.e1.domainEligibility,(e=>{e&&e.detail&&(this.lastCommittedUrl=e.detail.lastCommittedUrl,e.detail.domainEligibility?(this.domainEligible=!0,this.switchTabs(!0)):(this.domainEligible=!1,this.switchTabs(!1))),this.isCjkEnabled&&gn.SO.queueUpdate((()=>{this.restoreTabName()}))})),this.stateManagement.addEventListener(Ku.e1.flyoutRefresh,(()=>{const e=document.querySelector("#divActions");e&&this.createActionButtons(e,n)})),this.stateManagement.addEventListener(Ku.e1.PWILODeleted,(e=>{if(e&&e.detail&&void 0!==e.detail.index&&(0,T.pq)(e.detail.event)){const e=n.querySelector(`#${r.z6.CLOSE}`);e&&e.focus()}}))}createSettingsPane(){this.settingsPane=this.flyoutData.common.shoppingSettings,this.settingsPane.id=this.settingsPaneId,this.settingsPane.style.overflowY="auto",this.settingsPane.style.display="none";const t={heading:this.flyoutData.strings.settingsPaneHdNotificationsTitle,featureList:[{name:this.flyoutData.strings.settingsPaneHdAllNotifications,desc:this.flyoutData.strings.settingsPaneAllNotificationsText,popupOriginations:[]}]},n=[{heading:this.flyoutData.strings.settingsPaneHdSavings,featureList:[{name:this.flyoutData.strings.rewardCoupons,desc:this.flyoutData.strings.settingsPaneCouponsText,popupOriginations:(0,dt.UO)()},{name:this.flyoutData.strings.rewardCashback,desc:this.flyoutData.strings.settingsPaneCashbackText,popupOriginations:(0,dt.et)()}]},{heading:this.flyoutData.strings.settingsPaneHdProductInsights,featureList:[{name:this.flyoutData.strings.pcSectionTitle,desc:this.flyoutData.strings.settingsPanePcText,popupOriginations:(0,dt.Hg)()},{name:this.flyoutData.strings.phSectionTitle,desc:this.flyoutData.strings.settingsPanePhText,popupOriginations:[u.sR.AUTO_SHOW_PRICE_HISTORY]}]},{heading:this.flyoutData.strings.settingsPaneHdReminders,featureList:[{name:this.flyoutData.strings.productTrackingFeatureName,desc:this.flyoutData.strings.settingsPaneProductTrackingText,popupOriginations:(0,dt.Wy)()}]},{heading:this.flyoutData.strings.settingsPaneHdRecommendations,featureList:[{name:this.flyoutData.strings.dealsFeatureName,desc:this.flyoutData.strings.settingsPaneDealsText,popupOriginations:(0,dt.y6)()},{name:this.flyoutData.strings.autosFeatureName,desc:this.flyoutData.strings.settingsPaneAutosText,popupOriginations:[u.sR.AUTO_SHOW_AUTOS_MARKETPLACE]},{name:this.flyoutData.strings.groceriesFeatureName,desc:this.flyoutData.strings.settingsPaneGroceriesText,popupOriginations:(0,dt.ws)()},{name:this.flyoutData.strings.other,desc:this.flyoutData.strings.settingsPaneOtherText,popupOriginations:[u.sR.AUTO_SHOW_GIFT_CARD]}]}];e.R.isExperimentActive(f.H.shoppingSettingsInPaneNotificationBottomToggle)?n.push(t):(t.heading="",n.unshift(t));const o=(0,Y.Ux)("DIV",{}),r=(0,Y.Ux)("h2",{},this.flyoutData.strings.settingsPaneHdNotificationsTitle);o.classList.add("settingsTitleContainer"),r.classList.add("settingsTitle");const a=(0,Y.Ux)("P",{},this.flyoutData.strings.settingsPaneHdNotificationsText);a.classList.add("settingsTitleDesc","settingsSingleFeatureDesc"),o.appendChild(r),o.appendChild(a),this.settingsPane.appendChild(o);for(const t of n){const n=(0,Y.Ux)("h3",{},t.heading);n.classList.add("settingsSectionHeader"),this.settingsPane.appendChild(n);const o=(0,Y.Ux)("DIV",{});o.classList.add("settingsSectionContainer");let r=0;for(const n of t.featureList){const t=(0,Y.Ux)("div",{});t.classList.add("settingsSingleFeatureContainer");const a=(0,Y.Ux)("div",{});a.classList.add("settingsSingleFeatureTextContainer");const s=(0,Y.Ux)("DIV",{},n.name);s.classList.add("settingsSingleFeatureLabel");const l=(0,Y.Ux)("p",{},n.desc);l.classList.add("settingsSingleFeatureDesc"),l.id="settingsSingleFeatureDesc"+r,a.appendChild(s),a.appendChild(l);let c=(0,dt.g7)(n.popupOriginations[0],this.flyoutData,this.autoOpenControllerUtilities,this.logModule,!0);const d=(0,Y.Ux)("fluent-switch");n.name===this.flyoutData.strings.settingsPaneHdAllNotifications?c=this.isNotificationEnabled:d.classList.add("settingsFeatureSwitch"),this.enableSwitchToggle(d,c),d.style.setProperty("--accent-fill-rest","unset"),d.setAttribute("aria-label",n.name),d.setAttribute("aria-describedby","settingsSingleFeatureDesc"+r);const u=(0,Y.Ux)("DIV",{slot:"end"});u.classList.add("settingSwitchContainer"),u.appendChild(d);const h=async o=>{const r="true"===t.querySelector("fluent-switch").getAttribute("current-checked"),a=r?i.$S.PaneSettingTurnedOff:i.$S.PaneSettingTurnedOn,s=new W.Z(a,bp.r.MENU);s.Metadata=JSON.stringify({toggledPopupOriginations:n.popupOriginations,featureName:n.name}),this.logModule.LogInfoEvent(i.R.ButtonClick,"",s),n.name===this.flyoutData.strings.settingsPaneHdAllNotifications?(this.isNotificationEnabled=!r,this.pageHandlerModule.SetIsNotificationEnabled(!r),document.querySelectorAll(".settingsFeatureSwitch").forEach((e=>{e.disabled=r}))):(e.R.isExperimentActive(f.H.autoOpenControllerScript)&&await this.autoOpenControllerUtilities.setUserPreferenceBatch(!r,n.popupOriginations,this.flyoutData.common.disabledNotifications),this.pageHandlerModule.AutoShowForAllFeatures(!r,n.popupOriginations)),o.stopPropagation()};t.appendChild(a);const p=u.cloneNode(!0),g=p.querySelector("fluent-switch");this.utilities.viewModulesUtilities.makeHtmlElementKeyboardClickable(g,h),g?.addEventListener("click",h),t.appendChild(p),o.appendChild(t),r++}this.settingsPane.appendChild(o)}}enableSwitchToggle(e,t){t?(e.setAttribute("current-checked","true"),e.classList.add("checked"),e.setAttribute("aria-checked","true")):(e.setAttribute("current-checked","false"),e.classList.remove("checked"),e.setAttribute("aria-checked","false"))}async ReRankPane(t,i){const n=t?.detail?.perfTracker;n?.markEvent(Is.FlyoutRenderStart);let o=(await this.GetRenderedModules(!1,t.detail.moduleNames)).filter((e=>e.paneTab===r.$k.CONTEXTUAL));this.stateManagement.setState(Ku.IY.topContextualModuleName,o[0].name),t.detail.refreshType===Mg.Clipping&&(globalThis.clippingUpdated=!0),e.R.isExperimentActive(f.H.singleScrollingShoreline)?this.renderReRankedContextualModulesInSinglePane(o,i):this.renderReRankedContextualModules(o,i);const a=new CustomEvent(Ku.e1.ModulesRendered,{detail:{modules:o,perfTracker:n}});this.stateManagement.dispatchEvent(a)}switchTabs(e){if(this.isSingleScrollingPane)return void this.switchSingleScrollingTabs(e);const t=this.tabs.querySelector(`#${this.tabContextualId}`),i=this.tabs.querySelector(`#${this.tabHomeId}`),n=document.querySelector(`#${this.panelContextualId}`);if(e)t&&(this.setActiveTabId(this.tabContextualId),this.updateTabItemsStyling(2),n&&(this.manageTabControls(t,!0,n),this.createLoadingState(this.contextualShopping,this.panelContextualId)));else{if(this.tabs.getAttribute("activeid")===this.tabCashbackId)return;const e=document.querySelector(`#${this.homeShopping}`);i&&e?(this.setActiveTabId(this.tabHomeId),this.updateTabItemsStyling(1),this.manageTabControls(i,!0,null),t&&this.manageTabControls(t,!1,n)):t&&n&&(this.setActiveTabId(this.tabContextualId),this.updateTabItemsStyling(2),this.manageTabControls(t,!0,n),this.manageTabControls(i,!1,null),this.createNullState(n))}}updateTabItemsStyling(e){const t=this.tabs.shadowRoot?.querySelector(".activeIndicator"),i=this.tabs.shadowRoot?.querySelector(".tablist");if(t&&t.style.gridColumn!==`${e}`&&(t.style.transform="translateX(0px)",t.style.gridColumn=`${e}`),i){i.style.paddingBottom="15px";const t=this.tabs.querySelector("msft-cb-tab-header");t&&(t.isActive=e===this.tabCashbackIndex)}}createMainShoppingHeader(e){const n=(0,Y.Ux)("DIV");n.id="divMainHeader";const o=(0,Y.Ux)("h1");o.className="txtMedium",o.style.fontWeight="500",o.style.fontSize="16px",o.textContent=this.flyoutData.strings.commonFixedTitleNew;const r=(0,Y.Ux)("DIV");return r.id="divActions",this.createActionButtons(r,e),n.appendChild(o),n.appendChild(r),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Creating main header",new t.Z(i.xu.PaneHeaderRendered)),n}createActionButtons(e,t){new $I(this.flyoutData,this.utilities,this.pageHandlerModule,this.logModule,this.stateManagement).createFlyoutButtons(e,!0,t)}createUnifedHeaderShoppingMenu(n,o){e.R.isExperimentActive(f.H.shoppingSettingsInPane)||new class{constructor(e,t,i,n,o){(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"telemetryHandler",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"autoOpenControllerUtilities",void 0),(0,s.Z)(this,"manageNotificationMenu",void 0),(0,s.Z)(this,"manageSettingsMenu",void 0),(0,s.Z)(this,"backgroundOverlay",void 0),(0,s.Z)(this,"storageHandler",void 0),this.flyoutData=e,this.utilities=t.viewModulesUtilities,this.pageHandlerModule=i,this.telemetryHandler=t.telemetryHandler,this.logModule=n,this.stateManagement=o,this.commonAssets=t.commonAssets,this.autoOpenControllerUtilities=t.autoOpenControllerUtilities,this.storageHandler=t.storageHandler}async createSettingsMenu(e,t){t&&(this.isDisableOptOutMenuActive()||(this.stateManagement.getState(Ku.IY.modulesRendered)&&this.createContextMenu(e,t),this.stateManagement.addEventListener(Ku.e1.ModulesRendered,(()=>{this.createContextMenu(e,t)})))),gn.SO.queueUpdate((()=>{this.addListenerMenuItemKeyboardClick(e)}))}handleClickOutsideMenu(e,t){e.addEventListener("click",(e=>{e.target.id?.includes("main-background-overlay")&&("hide"!==t.className&&(t.className="hide"),this.backgroundOverlay?.classList.add("hide"))}))}manageMenuEvents(t,i){t.addEventListener("keydown",(e=>{"Escape"===e.key?(t.className="hide",this.backgroundOverlay?.classList.add("hide"),e.preventDefault()):"Tab"===e.key&&("btnFeedbackDislike"!==e.target?.id||e.shiftKey||e.preventDefault())}));let n=!1;e.R.isExperimentActive(f.H.shoppingSettingsInPane)||this.stateManagement.addEventListener(Ku.e1.ShoppingSettingsOpened,(()=>{if(this.manageNotificationMenu&&"hide"!==this.manageNotificationMenu.className)return void this.manageNotificationMenu.classList.add("hide");if(this.manageSettingsMenu&&"hide"!==this.manageSettingsMenu.className)return void this.manageSettingsMenu.classList.add("hide");this.backgroundOverlay?.classList.toggle("hide");const e=document.querySelectorAll("fluent-menu[slot='start-content'], msft-cashback-header-card");for(const i of e)i!==t&&i.classList.add("hide");t.classList.toggle("hide"),"hide"!==t.className&&i&&this.flyoutData.common.openedWith!==r.Te.Auto&&!n&&(this.telemetryHandler.recordContentViewed(r.ModuleNames.FEEDBACK,Jl.g.EdgeImpressionId,!1,-1),n=!0)}))}addListenerMenuItemKeyboardClick(e){const t=e.querySelectorAll("fluent-menu-item:not(#manage-notification-button, #manage-notification-header, #manage-settings-button, #manage-settings-header, #manage-notification-menu fluent-menu-item, #manage-settings-menu fluent-menu-item)"),i=e.querySelector(`#${r.z6.MENU_CONTENT}`),n=e.querySelector(`#${r.z6.MENU}`);t&&t.length>0&&i&&n&&t.forEach((e=>{this.utilities.makeHtmlElementKeyboardClickable(e,(()=>{this.handlerMenuItemKeyboardClick(i,n)}))}))}handlerMenuItemKeyboardClick(e,t){e.className="hide",t.setAttribute("aria-expanded","undefined"),t.focus()}async createContextMenu(e,t){const i=e.querySelector(`#${r.z6.MENU_CONTENT}`);i&&i.remove();const n=await this.createContextMenuDiv(e);this.manageMenuEvents(n,this.stateManagement),this.handleClickOutsideMenu(t,n);const o=e.querySelector("#manage-notification-button");this.manageNotificationMenu&&o&&this.handleClickOutsideMenu(t,this.manageNotificationMenu);const a=e.querySelector("#manage-settings-button");this.manageSettingsMenu&&a&&this.handleClickOutsideMenu(t,this.manageSettingsMenu),this.manageNotificationMenu&&this.manageNotificationMenu.addEventListener("keydown",(e=>{"Escape"===e.key&&(this.manageNotificationMenu.className="hide",e.preventDefault())})),this.manageSettingsMenu.addEventListener("keydown",(e=>{"Escape"===e.key&&(this.manageSettingsMenu.className="hide",e.preventDefault())}))}addManageNotificationItem(e,n){const o=document.createElement("DIV");o.innerHTML=this.commonAssets.getRightArrowIcon(),o.slot="end",o.style.display="flex",o.style.marginRight="0",o.setAttribute("aria-hidden","true");const r=document.createElement("fluent-menu-item");r.style.fontSize="12px";const a=document.createElement("DIV");a.innerHTML=this.commonAssets.getNotificationIcon(),a.style.display="flex",a.slot="start",a.setAttribute("aria-hidden","true"),r.title=this.flyoutData.strings.commonManageNotifications,r.textContent=this.flyoutData.strings.commonManageNotifications,r.id="manage-notification-button",r.className+="defaultFontFamily",r.appendChild(a),r.appendChild(o.cloneNode(!0));try{this.manageNotificationMenu||(this.manageNotificationMenu=new FI(this.flyoutData,this.utilities,this.autoOpenControllerUtilities,this.stateManagement,this.pageHandlerModule,this.logModule,e).renderMenuModule(),n.querySelector(`#${this.manageNotificationMenu.id}`)||(n.appendChild(this.manageNotificationMenu),gn.SO.queueUpdate((()=>{this.manageNotificationMenu.setAttribute("slot","start-content")}))))}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Error creating manage notifications menu ${(0,dt.YU)(e)}`,n)}const s=t=>{this.manageNotificationMenu.classList.remove("hide"),e.classList.add("hide"),t.stopPropagation();const n=new W.Z(i.$S.ManageNotification,bp.r.MENU);this.logModule.LogInfoEvent(i.R.ButtonClick,"Manage Notification button clicked",n)};r.addEventListener("click",s),this.utilities.makeHtmlElementKeyboardClickable(r,(e=>{s(e);const t=this.manageNotificationMenu.querySelectorAll("fluent-menu-item");t?.length&&t[0].focus()})),e.appendChild(r)}addShoppingSettingsItem(e,n){const o=document.createElement("DIV");o.innerHTML=this.commonAssets.getRightArrowIcon(),o.slot="end",o.style.display="flex",o.style.marginRight="0",o.setAttribute("aria-hidden","true");const r=document.createElement("DIV");r.innerHTML=this.commonAssets.getSettingsIcon(),r.slot="start",r.style.display="flex",r.setAttribute("aria-hidden","true");const a=document.createElement("fluent-menu-item");a.style.fontSize="12px",a.title=this.flyoutData.strings.commonShoppingSettings,a.textContent=this.flyoutData.strings.commonShoppingSettings,a.id="manage-settings-button",a.className+="defaultFontFamily",a.appendChild(r),a.appendChild(o);try{this.manageSettingsMenu||((0,dt.tB)(this.flyoutData)?this.manageSettingsMenu=new HI(this.flyoutData,this.utilities,this.autoOpenControllerUtilities,this.stateManagement,this.pageHandlerModule,this.logModule,e).renderMenuModule():this.manageSettingsMenu=new UI(this.flyoutData,this.utilities,this.autoOpenControllerUtilities,this.stateManagement,this.pageHandlerModule,this.logModule,e,this.storageHandler).renderMenuModule(),n.querySelector(`#${this.manageSettingsMenu.id}`)||(n.appendChild(this.manageSettingsMenu),gn.SO.queueUpdate((()=>{this.manageSettingsMenu.setAttribute("slot","start-content")}))))}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Error creating manage settings menu ${(0,dt.YU)(e)}`,n)}const s=t=>{this.manageSettingsMenu.classList.remove("hide"),e.classList.add("hide"),t.stopPropagation();const n=new W.Z(i.$S.ShoppingSettings,bp.r.MENU);this.logModule.LogInfoEvent(i.R.ButtonClick,"Manage Settings button clicked",n)};a.addEventListener("click",s),this.utilities.makeHtmlElementKeyboardClickable(a,(e=>{s(e);const t=this.manageSettingsMenu.querySelectorAll("fluent-menu-item");t?.length&&t[0].focus()})),e.appendChild(a)}async createContextMenuDiv(e){const n=document.createElement("fluent-menu");n.id=r.z6.MENU_CONTENT,n.setAttribute("aria-labelledby",r.z6.MENU);try{(0,dt.tB)(this.flyoutData)||this.addManageNotificationItem(n,e),this.addShoppingSettingsItem(n,e)}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Error creating menu buttons ${(0,dt.YU)(e)}`,n)}const o=new CustomEvent(Ku.e1.CreateFeedbackModule,{detail:{callback:e=>{if(e&&e.element){try{n.querySelector("#feedbackDiv")?.remove(),n.querySelector("#menuSettingsBingPrivacy")?.remove()}catch(e){}e.element.style.background="var(--neutral-layer-floating)",e.element.setAttribute("role","menuitem"),n.appendChild(e.element),this.createBingPrivacyMesageOnMenu(n)}},wrapperHeight:0}});let a,s;return this.stateManagement.dispatchEvent(o),this.flyoutData.common.currentDirection===r.m5.RTL?(a="35px",s="40px"):this.flyoutData.common.openedWith===r.Te.Auto?(a="0px",s="45px"):(a="55px",s="0px"),n.style.top=s,n.style.left=a,n.style.width="230px",n.style.maxWidth="unset !important",n.tabIndex=-1,n.className="hide",this.backgroundOverlay||(this.backgroundOverlay=document.createElement("DIV"),this.backgroundOverlay.id="main-background-overlay",this.backgroundOverlay.classList.add("hide"),this.backgroundOverlay.style.top=s,e.appendChild(this.backgroundOverlay)),e.appendChild(n),gn.SO.queueUpdate((()=>{n.setAttribute("slot","start-content")})),n}createBingPrivacyMesageOnMenu(e){const t=document.createElement("DIV"),i=document.createElement("SPAN");i.id="menuMessage",t.className="txtSmall",t.id="menuSettingsBingPrivacy",t.appendChild(i),i.title=this.flyoutData.strings.bingPrivacyMessage,i.textContent=this.flyoutData.strings.bingPrivacyMessage,t.style.fontSize="12px",t.style.lineHeight="12px",e.appendChild(t)}isDisableOptOutMenuActive(){if((0,dt.tB)(this.flyoutData)&&!this.flyoutData.common.isUserHadFirstExperience)return!0;if("amazon.com"===this.flyoutData?.common?.domain){this.pageHandlerModule.TriggerExperiment(f.H.showAmazonOtherSellers);const t=e.R.isExperimentActive(f.H.showAmazonOtherSellers),i=e.R.isVariantActive(f.H.showAmazonOtherSellers,Yu.UD.AS_FeatureOpt);return t&&i}return!1}}(this.flyoutData,this.utilities,this.pageHandlerModule,this.logModule,this.stateManagement).createSettingsMenu(n,o)}renderContextualModules(e,n){this.contextualModules=e.filter((e=>e.paneTab===r.$k.CONTEXTUAL))?.sort(((e,t)=>e.priority-t.priority));const o=this.tabs.querySelector(`#${this.tabContextualId}`);let a;if(o)a=o;else{a=(0,Y.Ux)("fluent-tab"),a.id=this.tabContextualId,a.style.display="flex",a.style.flexDirection="column";const e=(0,Y.Ux)("P");e.className="paneTabText",e.style.color="inherit",e.textContent=this.flyoutData.strings.paneForYou,a.appendChild(e),this.tabs.appendChild(a),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Creating contextual tab",new t.Z(i.xu.PaneTabsRendered))}a.addEventListener("click",this.sendClickTelemetry.bind(this)),new MutationObserver((()=>{this.handleStyleTabSwitch(a)})).observe(a,{attributeFilter:["aria-selected"],attributes:!0}),this.tabs.querySelector(`#${this.contextualShopping}`)||(this.renderModulesInTab(this.contextualModules,this.flyoutData.common.shopping,this.panelContextualId,n),this.flyoutData.common.shopping.id=this.contextualShopping,this.flyoutData.common.shopping.fixedTitle=this.flyoutData.strings.commonContextualTab);const s=(0,h.Mw)("mitOpen");if(this.contextualModules&&this.contextualModules.length>0&&this.canRenderContentInTab(this.contextualModules,this.panelContextualId)&&!s?.includes("true")){this.setActiveTabId(this.tabContextualId),this.updateTabItemsStyling(2);const e=document.querySelector(`#${this.panelContextualId}`);this.manageTabControls(a,!0,e)}else a&&gn.SO.queueUpdate((()=>{const e=document.querySelector(`#${this.homeShopping}`),t=document.querySelector(`#${this.panelContextualId}`);if(e){const e=document.querySelector(`#${this.tabHomeId}`),i=document.querySelector(`#${this.panelHomeId}`);e&&i&&(this.manageTabControls(e,!0,i),this.setActiveTabId(this.tabHomeId),this.updateTabItemsStyling(1),s?.includes("true")||this.createNullState(t))}else t&&(this.manageTabControls(a,!0,t),this.setActiveTabId(this.tabContextualId),this.updateTabItemsStyling(2),s?.includes("true")||this.createNullState(t))}));this.checkIfShouldFocusInboxCoupons()}getActiveTabId(){return this.isSingleScrollingPane?this.singleScrollingActiveTabId||r.d$.Home:this.tabs.getAttribute("activeid")||r.d$.Home}setActiveTabId(e){this.isSingleScrollingPane?this.singleScrollingActiveTabId=e:this.tabs.getAttribute("activeid")!==e&&this.tabs.setAttribute("activeid",e),(e===this.tabHomeId||this.isSingleScrollingPane&&e===this.tabMyShoppingId)&&this.stateManagement.dispatchEvent(new CustomEvent(Ku.e1.HomeTabActive))}sendClickTelemetry(e){const n=e.currentTarget.id;let o,r,a;n===this.tabHomeId||this.isSingleScrollingPane&&n===this.tabMyShoppingId?(o=K.bS.SWITCH_TO_TAB1,r=K.bS.CJK_SWITCH_TO_TAB1,a=q.FV.SWITCH_TO_TAB1):n===this.tabContextualId||this.isSingleScrollingPane&&n===this.tabCouponsSavingsId?(o=K.bS.SWITCH_TO_TAB2,r=K.bS.CJK_SWITCH_TO_TAB2,a=q.FV.SWITCH_TO_TAB2):(o=K.bS.SWITCH_TO_TAB3,a=q.FV.SWITCH_TO_TAB3);const s=new t.Z(i.xu.PaneTabClick);s.Metadata=JSON.stringify({type:n}),this.pageHandlerModule.RecordAsUserAction(o),this.pageHandlerModule.RecordAsUserEngagement(a,this.flyoutData.common.popupOrigination),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"",s),this.isCjkEnabled&&r&&(this.pageHandlerModule.RecordAsUserAction(r),o in Ug&&this.pageHandlerModule.RecordAsCjkScenario(Hg.ACTION,Ug[o]))}sendScrollToTabTelemetry(e){let n,o;e===this.tabMyShoppingId?(n=K.bS.SCROLL_TO_TAB1,o=q.FV.SCROLL_TO_TAB1):e?(n=K.bS.SCROLL_TO_TAB2,o=q.FV.SCROLL_TO_TAB2):(n=K.bS.SCROLL_TO_TAB3,o=q.FV.SCROLL_TO_TAB3);const r=new t.Z(i.xu.PaneTabClick);r.Metadata=JSON.stringify({type:e}),this.pageHandlerModule.RecordAsUserAction(n),this.pageHandlerModule.RecordAsUserEngagement(o,this.flyoutData.common.popupOrigination),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"",r)}manageTabControls(e,t,i){if(t){if(i){const e=i.querySelector(".paneNullWrapper");e&&e.remove()}e.style.pointerEvents="unset",e.setAttribute("aria-disabled","false")}else i?i.id===this.couponsSavingsShopping?this.createTrendingCouponsAsNullState(i):this.createNullState(i):(e.style.pointerEvents="none",e.setAttribute("aria-disabled","true"))}renderHomeModules(e,n){let o;this.homeModules=e.filter((e=>e.paneTab===r.$k.HOME))?.sort(((e,t)=>e.priority-t.priority));const a=this.tabs.querySelector(`#${this.tabHomeId}`);if(a)o=a;else{o=(0,Y.Ux)("fluent-tab"),o.id=this.tabHomeId;const e=(0,Y.Ux)("P");e.className="paneTabText",e.style.color="inherit",e.textContent=this.flyoutData.strings.paneHome,o.appendChild(e),this.tabs.appendChild(o),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Creating home tab",new t.Z(i.xu.PaneTabsRendered))}o.addEventListener("click",this.sendClickTelemetry.bind(this)),o.addEventListener("click",(()=>{this.stateManagement.dispatchEvent(new CustomEvent(Ku.e1.HomeTabActive))})),new MutationObserver((()=>{this.handleStyleTabSwitch(o)})).observe(o,{attributeFilter:["aria-selected"],attributes:!0}),this.tabs.querySelector(`#${this.homeShopping}`)||(this.renderModulesInTab(this.homeModules,this.flyoutData.common.shoppingPersistent,this.panelHomeId,n),this.flyoutData.common.shoppingPersistent.id=this.homeShopping,this.flyoutData.common.shoppingPersistent.fixedTitle=this.flyoutData.strings.commonHomeTab,this.homeModules&&this.homeModules.length>0?this.manageTabControls(o,!0,null):this.flyoutData.common.isWebAssistPending?(this.createLoadingState(this.homeShopping,this.panelHomeId),this.manageTabControls(o,!0,null)):this.manageTabControls(o,!1,null))}renderModulesInTab(e,t,i,n,o=!1){try{const r=this.tabs.querySelector(`#${i}`);let a;r?a=r:(a=(0,Y.Ux)("fluent-tab-panel"),a.id=i);const s=t;if(e&&e.length>0&&this.canRenderContentInTab(e,i)){this.appendModulesToShoppingElement(e,s,n,o);const t=a.querySelector(".paneLoadingWrapper");t&&t.remove();const i=a.querySelector(".paneNullWrapper");i&&i.remove(),a.appendChild(s)}r||this.tabs.appendChild(a),this.scrollContentTo00(s)}catch(e){this.onAddingModulesInTabError(e)}}appendModulesToShoppingElement(n,o,a,s=!1){for(let l=0;l<n.length;l++){const c=n[l];if(c.element.expanded=!0,l>0&&c.priority!==r.H7.MAX&&(e.R.isExperimentActive(f.H.singleScrollingShoreline)||this.utilities.viewModulesUtilities.addSectionSeparator(o),this.flyoutData.common.isCJKEnabled&&l>1)){const e=o.getElementsByTagName("HR")[l-1];e?.setAttribute("style","height: 12px; position: relative;")}o.appendChild(c.element),this.isStoryBookSection(a)?this.utilities.viewModulesUtilities.styleModules(c,1,a):this.utilities.viewModulesUtilities.styleModules(c,l,a);try{s&&this.contextualModules.includes(c)||c.moduleInterface.PostProcessing(c.name,l,c.element),this.isStoryBookSection(a)?this.styleModulesInPane(c,a,1):this.styleModulesInPane(c,a,l)}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Error while Post processing Module: ${c.name} ${(0,dt.YU)(e)}`,n,GI.GetImpressionType(c.name))}}this.isStoryBookSection(a)||this.setTitle(n[0]);const l=(n[0].name===r.ModuleNames.COUPON&&this.flyoutData.common.isCheckoutPage&&this.flyoutData.dataStoreModule.CouponData?.isCheckoutPageWithAutoApply)??!1,c="msft-edge-shopping-section"!==n[0].element.nodeName.toLowerCase()&&n[0].moduleLayout===r.SV.BLOCK,d=n[0].name===r.ModuleNames.SOCIALCOUPONS&&"youtube.com"===this.flyoutData.common.domain;(l||c||d)&&(n[0].element.seeMoreSeparate?this.addClassToShopping(n[0].paneTab,"headerBlockSeeMore"):this.addClassToShopping(n[0].paneTab,"headerBlock"))}scrollContentTo00(e){gn.SO.queueUpdate((()=>{const t=e.shadowRoot?.querySelector(".content");t&&t.scrollTo(0,0),setTimeout((()=>{t&&t.scrollTo(0,0)}),200)}))}onAddingModulesInTabError(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,`Error adding modules to tabs ${(0,dt.YU)(e)}`,n)}canRenderContentInTab(e,t){let i=!0;if(t===this.panelHomeId||this.isSingleScrollingPane&&t===this.tabMyShoppingId){const t=e.filter((e=>e.paneTab===r.$k.HOME));i=t&&t.length>0,this.isSingleScrollingPane&&(this.isMyShoppingZeroState=!i)}else if(t===this.panelContextualId||this.isSingleScrollingPane&&t===this.tabCouponsSavingsId){const t=e.filter((e=>e.paneTab===r.$k.CONTEXTUAL&&e.name!==r.ModuleNames.EMPTYCOUPON&&e.name!==r.ModuleNames.FEEDBACK));i=t&&t.length>0,this.isSingleScrollingPane&&(this.isCouponsSavingsZeroState=!i)}else if(t===this.tabExploreId){const t=e.filter((e=>e.paneTab===r.$k.EXPLORE));i=t&&t.length>0,this.isSingleScrollingPane&&(this.isExploreZeroState=!i)}return i}handleStyleTabSwitch(e){"true"===e.getAttribute("aria-selected")?(e.style.fontWeight="600",e.id===this.tabContextualId||e.id===this.tabCouponsSavingsId?this.updateTabItemsStyling(2):e.id===this.tabHomeId||e.id===this.tabMyShoppingId?this.updateTabItemsStyling(1):e.id===this.tabCashbackId?this.updateTabItemsStyling(this.tabCashbackIndex):e.id===this.tabExploreId&&this.updateTabItemsStyling(3)):e.style.fontWeight="normal"}styleModulesInPane(e,t,i){e.element.isPane=!0,e.element.isSingleScroll=this.isSingleScrollingPane&&0!==i;const n="msft-edge-shopping-section"===e.element.nodeName.toLowerCase()??!1;if(e.moduleLayout===r.SV.BLOCK)if(0!==i||this.isStoryBookSection(t)||e.name===r.ModuleNames.AUTOSMYGARAGE?n?e.element.isBlock=!0:e.element.classList.add("regionBlock"):(e.element.seeMoreSeparate?this.addClassToShopping(e.paneTab,"headerBlockSeeMore"):this.addClassToShopping(e.paneTab,"headerBlock"),e.name===r.ModuleNames.CASHBACK&&this.flyoutData.common.shopping.classList.add("noPaddingBlock"),e.element.headerBlock=!0),e.name===r.ModuleNames.CASHBACK){const t=this.flyoutData.dataStoreModule.CashBackData;t&&t.userRebatesResponse&&t.userRebatesResponse.isRebatesUser&&e&&t.userRebatesResponse.latestCashbackApproved?e.element.classList.add("previousSection"):0!==i&&(e.element.hasPadding=!0),e.element.hasTransparentBackground=!0}else[r.ModuleNames.PRICECOMPARISON,r.ModuleNames.SIMILARSELLERS,r.ModuleNames.AUTOSMYGARAGE].includes(e.name)||n&&0!==i&&(e.element.hasPadding=!0)}addClassToShopping(e,t){e===r.$k.CONTEXTUAL?this.flyoutData.common.shopping.classList.add(t):e===r.$k.EXPLORE?this.flyoutData.common.shoppingExplore.classList.add(t):this.flyoutData.common.shoppingPersistent.classList.add(t)}createLoadingState(e,n){const o=document.querySelector(`#${n}`);if(o){let n=document.querySelector(`#${e}`);n&&n.remove(),n=document.createElement("msft-edge-shopping"),n.id=e,n.classList.add("msft-edge-shopping-loading-state"),ED.addPaneLoadingState(n),o.appendChild(n),setTimeout((()=>{gn.SO.queueUpdate((()=>{if(document.querySelector(".paneLoadingWrapper")){const e=new t.Z(i.xu.ErrorPaneStuckLoadingState);if(this.lastCommittedUrl){const t={url:this.lastCommittedUrl};e.Metadata=JSON.stringify(t)}this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,`Pane stuck on loading state, forcing refresh. Domain Elegible: ${this.domainEligible}`,e)}}))}),15e3)}}async createTrendingCouponsAsNullState(e){if(this.isSingleScrollingPane&&this.trendingCouponsModule)try{if(this.trendingCouponsModuleType||(this.trendingCouponsModuleType=await this.trendingCouponsModule.renderModule()),this.trendingCouponsModuleType){for(await this.trendingCouponsModule.PostProcessing(this.trendingCouponsModuleType?.name,0,this.trendingCouponsModuleType?.element);e&&e.lastChild;)e.lastChild.remove();return e.appendChild(this.trendingCouponsModuleType.element),void this.addSentinel(e,this.tabExploreId,this.tabCouponsSavingsId)}}catch(t){this.createNullState(e)}this.createNullState(e)}async createCashbackTab(){if(this.deferredCashbackModules?.length>0){const e=kD.getInstance(),n=await e.FetchCashbackTransactions(this.flyoutData,this.pageHandlerModule,this.logModule);if(!n)return;const o=n?.profile,r=await this.RenderModulesCommon(this.deferredCashbackModules,!0);let a;const s=this.tabs.querySelector(`#${this.tabCashbackId}`),l="cashbackTabSpacer";if(!this.tabs.querySelector(`#${l}`)){const e=(0,Y.Ux)("fluent-tab");e.id=l,e.style.display="none",this.tabs.appendChild(e);const t=[],i=(0,Y.Ux)("div");this.renderModulesInTab(t,i,"spacerPanel",this.flyoutWrapper),this.manageTabControls(e,!1,null)}if(s)a=s;else{a=(0,Y.Ux)("fluent-tab"),a.id=this.tabCashbackId;const e=(0,Y.Ux)("msft-cb-tab-header");e.id=this.cashbackTabHeaderId,e.balanceString=Kd(o?.availableBalance??0,this.flyoutData.common.afdMarket,o?.userCurrency),(new Date).getFullYear()<2025?setTimeout((()=>{e.hasVisitedCashbackTab="true"===(0,h.Mw)(Jp.Q.HasVisitedCashbackTab)}),0):e.hasVisitedCashbackTab=!0,e.onClick=()=>{(0,h.Xo)(Jp.Q.HasVisitedCashbackTab,"true"),e.hasVisitedCashbackTab=!0,this.sendClickTelemetry.bind(this),a.click()},a.appendChild(e),this.tabs.appendChild(a),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Creating cashback tab",new t.Z(i.xu.PaneTabsRendered))}a.addEventListener("click",this.sendClickTelemetry.bind(this)),new MutationObserver((()=>{this.handleStyleTabSwitch(a)})).observe(a,{attributeFilter:["aria-selected"],attributes:!0}),this.tabs.querySelector(`#${this.cashbackShopping}`)||(this.flyoutData.common.shoppingCashback.id=this.cashbackShopping,this.renderModulesInTab(r,this.flyoutData.common.shoppingCashback,this.panelCashbackId,this.flyoutWrapper),this.manageTabControls(a,!0,null))}}createNullState(e){if(this.isCjkEnabled&&this.isSingleScrollingPane)return;const t=e?.querySelector(".paneNullWrapper");if(!t&&e){for(;e&&e.lastChild;)e.lastChild.remove();const t=(0,Y.Ux)("DIV");let a;if(t.className="paneNullWrapper",t.style.display="flex",t.style.flexDirection="column",t.style.justifyContent="center",t.style.alignItems="center",t.style.textAlign="center",t.style.padding="0 45px",t.style.height="100%",t.style.height="calc(100vh - 300px)",this.isCjkEnabled)t.style.justifyContent="",i=this.flyoutData.common.resourcesEndpoint,n=this.flyoutData.strings.cjkNullSatateDescription,o=this.utilities.viewModulesUtilities.isDarkMode(),r=t,sp.render(ch.createElement(lD,{isDarkMode:o,resourceBasePath:i,nullStateDesc:n}),r);else{a=(0,Y.Ux)("DIV"),a.className="nullContentContainer";const e=(0,Y.Ux)("IMG");this.utilities.viewModulesUtilities.setImageSrc(e,this.flyoutData.common.resourcesEndpoint+"pane/nullState.png"),e.style.pointerEvents="none",e.setAttribute("aria-hidden","true");const i=(0,Y.Ux)("H2");i.className="txtLarge",i.style.fontSize="20px",i.textContent=this.flyoutData.common.isCJKEnabled?this.flyoutData.strings.cjkPaneNullStateMessage:this.flyoutData.strings.paneNullStateMessage,a.appendChild(e),a.appendChild(i),t.appendChild(a)}e.appendChild(t);const s=e.querySelector(".paneLoadingWrapper");s&&s.remove(),this.isSingleScrollingPane&&(t.style.height="fit-content",t.style.overflow="hidden",t.style.paddingBottom="15px")}var i,n,o,r}renderMyShoppingSection(e,t){this.homeModules=e.filter((e=>e.paneTab===r.$k.HOME))?.sort(((e,t)=>e.priority-t.priority));const i=this.tabs.querySelector(`#${this.tabMyShoppingId}`);let n;if(i)n=i;else{n=(0,Y.Ux)("fluent-tab"),n.id=this.tabMyShoppingId,n.style.gridColumn="1";const e=(0,Y.Ux)("P");e.className="paneTabText",e.textContent=this.flyoutData.strings.paneMyShopping,n.appendChild(e),this.tabs.appendChild(n)}this.addClickListenersToTab(n,this.tabMyShoppingId),this.addTabArrowKeysListeners(n,this.tabMyShoppingId),this.addTabFocusListeners(n,this.myShoppingShopping),new MutationObserver((()=>{this.handleStyleTabSwitch(n)})).observe(n,{attributeFilter:["aria-selected"],attributes:!0}),document.getElementById(`${this.myShoppingShopping}`)||(this.renderModulesInSingleScrollingTabs(this.homeModules,this.flyoutData.common.shoppingPersistent,this.tabMyShoppingId,t),this.flyoutData.common.shoppingPersistent.id=this.myShoppingShopping,this.flyoutData.common.shopping.fixedTitle=this.flyoutData.strings.commonMyShoppingTab),this.checkIfShouldFocusInboxCoupons(),this.focusHomeifRedirectedFromProductTrackingEmail()}checkIfShouldFocusInboxCoupons(){if("true"===(0,h.Mw)(Jp._.InboxCouponsUpsellOpen)){this.utilities.viewModulesUtilities.switchShoppingTab(this.tabHomeId),this.setActiveTabId(this.tabHomeId);const e=document.getElementById("inboxCouponSection");e?.scrollIntoView({behavior:"smooth"})}}renderCouponsSavingsSection(e,t){this.contextualModules=e.filter((e=>e.paneTab===r.$k.CONTEXTUAL))?.sort(((e,t)=>e.priority-t.priority));const i=this.tabs.querySelector(`#${this.tabCouponsSavingsId}`);let n;if(i)n=i;else{n=(0,Y.Ux)("fluent-tab"),n.id=this.tabCouponsSavingsId,n.style.gridColumn="2";const e=(0,Y.Ux)("P");e.className="paneTabText",e.textContent=this.flyoutData.strings.paneCouponsSavings,n.appendChild(e),this.tabs.appendChild(n)}this.addClickListenersToTab(n,this.tabCouponsSavingsId),this.addTabArrowKeysListeners(n,this.tabCouponsSavingsId),this.addTabFocusListeners(n,this.couponsSavingsShopping),new MutationObserver((()=>{this.handleStyleTabSwitch(n)})).observe(n,{attributeFilter:["aria-selected"],attributes:!0}),document.getElementById(`${this.couponsSavingsShopping}`)||(this.renderModulesInSingleScrollingTabs(this.contextualModules,this.flyoutData.common.shopping,this.tabCouponsSavingsId,t),this.flyoutData.common.shopping.id=this.couponsSavingsShopping,this.flyoutData.common.shopping.fixedTitle=this.flyoutData.strings.commonContextualTab)}renderExploreSection(e,t){if(this.exploreModules=e.filter((e=>e.paneTab===r.$k.EXPLORE))?.sort(((e,t)=>e.priority-t.priority)),!this.exploreModules||0===this.exploreModules?.length)return void(this.isExploreZeroState=!0);const i=this.tabs.querySelector(`#${this.tabExploreId}`);let n;if(i)n=i;else{n=(0,Y.Ux)("fluent-tab"),n.id=this.tabExploreId,n.style.gridColumn="3";const e=(0,Y.Ux)("P");e.className="paneTabText",e.textContent=this.flyoutData.strings.paneExplore,n.appendChild(e),this.tabs.appendChild(n)}this.addClickListenersToTab(n,this.tabExploreId),this.addTabArrowKeysListeners(n,this.tabExploreId),this.addTabFocusListeners(n,this.exploreShopping),new MutationObserver((()=>{this.handleStyleTabSwitch(n)})).observe(n,{attributeFilter:["aria-selected"],attributes:!0}),document.getElementById(`${this.exploreShopping}`)||(this.renderModulesInSingleScrollingTabs(this.exploreModules,this.flyoutData.common.shoppingExplore,this.tabExploreId,t),this.flyoutData.common.shoppingExplore.id=this.exploreShopping,this.flyoutData.common.shopping.fixedTitle=this.flyoutData.strings.commonExploreTab)}renderModulesInSingleScrollingTabs(e,t,i,n){try{const o=t;e&&e.length>0&&this.canRenderContentInTab(e,i)?this.appendModulesToShoppingElement(e,o,n):(i===r.d$.CouponsSavings?this.createTrendingCouponsAsNullState(o):this.createNullState(o),i===this.tabMyShoppingId?this.isMyShoppingZeroState=!0:i===this.tabCouponsSavingsId&&(this.isCouponsSavingsZeroState=!0)),this.scrollContentTo00(o),this.singleScrollingPaneWrapper.appendChild(o)}catch(e){this.onAddingModulesInTabError(e)}}switchSingleScrollingTabs(e){const t=this.tabs.querySelector(`#${this.tabMyShoppingId}`),i=this.tabs.querySelector(`#${this.tabCouponsSavingsId}`),n=this.tabs.querySelector(`#${this.tabExploreId}`),o=document.getElementById(`${this.myShoppingShopping}`),r=document.getElementById(`${this.couponsSavingsShopping}`),a=document.getElementById(`${this.exploreShopping}`),s=document.getElementById(this.panelSingleScrollingId);if(e)i&&r&&!this.isCouponsSavingsZeroState&&(this.scrollTabContentIntoView(r,""),this.onTabGetActivated(this.tabCouponsSavingsId),this.manageTabControls(i,!0,r));else if(t&&o&&!this.isMyShoppingZeroState){if(this.scrollTabContentIntoView(o,""),this.onTabGetActivated(this.tabMyShoppingId),this.manageTabControls(t,!0,null),i){const e=this.getZeroStateContainer(this.couponsSavingsShopping);this.isCouponsSavingsZeroState=!0,this.manageTabControls(i,!1,e)}}else if(n&&a&&!this.isExploreZeroState){if(this.onTabGetActivated(this.tabExploreId),this.manageTabControls(n,!0,null),t){const e=this.getZeroStateContainer(this.myShoppingShopping);this.isMyShoppingZeroState=!0,this.manageTabControls(t,!1,e)}if(i){const e=this.getZeroStateContainer(this.couponsSavingsShopping);this.isCouponsSavingsZeroState=!0,this.manageTabControls(i,!1,e)}this.scrollTabContentIntoView(a,"")}else i&&s&&(this.onTabGetActivated(this.tabCouponsSavingsId),this.manageTabControls(i,!0,s),this.isCouponsSavingsZeroState=!0,this.manageTabControls(t,!1,null),this.isMyShoppingZeroState=!0,n&&(this.manageTabControls(n,!1,null),this.isExploreZeroState=!0),this.createNullState(s))}updateSingleScrollTabItemsStyling(e){let t=0;e===this.tabMyShoppingId?t=1:e===this.tabCouponsSavingsId?t=2:e===this.tabExploreId&&(t=3),this.updateTabItemsStyling(t)}handleSingleScrollingTabControlsOnSelected(e){this.resetSingleScrollingTabs();const t=this.tabs.querySelector(`#${e}`),i=document.getElementById(`${this.panelSingleScrollingId}`);i?.setAttribute("aria-labelledby",`${e}`),t&&(t.setAttribute("aria-controls",`${this.panelSingleScrollingId}`),t.setAttribute("aria-selected","true"),t.tabIndex=0)}resetSingleScrollingTabs(){const e=this.tabs.querySelector(`#${this.tabMyShoppingId}`),t=this.tabs.querySelector(`#${this.tabCouponsSavingsId}`),i=this.tabs.querySelector(`#${this.tabExploreId}`);i&&(i.setAttribute("aria-selected","false"),i.setAttribute("aria-controls",""),i.tabIndex=-1),e&&(e.setAttribute("aria-selected","false"),e.setAttribute("aria-controls",""),e.tabIndex=-1),t&&(t.setAttribute("aria-selected","false"),t.setAttribute("aria-controls",""),t.tabIndex=-1),this.tabs.setAttribute("activeid","")}handleSingleScrollingTabsOnStartUp(){if(globalThis.singleScrollingActiveTab){const e=globalThis.singleScrollingActiveTab===r.d$.MyShopping?r.Hp.MyShopping:globalThis.singleScrollingActiveTab===r.d$.CouponsSavings?r.Hp.CouponsSavings:null,t=document.getElementById(`${e}`);e&&t&&(this.scrollTabContentIntoView(t,""),this.onTabGetActivated(globalThis.singleScrollingActiveTab))}else this.domainEligible||this.isCjkEnabled?this.switchTabs(!0):this.switchTabs(!1)}onTabGetActivated(e){this.handleSingleScrollingTabControlsOnSelected(e),this.setActiveTabId(e),this.updateSingleScrollTabItemsStyling(e)}addClickListenersToTab(e,t){let i=this.myShoppingShopping;t===this.tabCouponsSavingsId?i=this.couponsSavingsShopping:t===this.tabExploreId&&(i=this.exploreShopping),e.addEventListener("click",this.sendClickTelemetry.bind(this)),e.addEventListener("click",(()=>{const e=document.getElementById(`${i}`);this.scrollTabContentIntoView(e,"smooth"),this.onTabGetActivated(t)}))}getZeroStateContainer(e){let t=document.getElementById(`${e}`);if(!t){t=document.createElement("msft-edge-shopping"),t.id=e;const i=document.getElementById(`${this.singleScrollingShopping}`);if(i)if(e===this.myShoppingShopping){const e=i.firstChild;e?i.insertBefore(t,e):i.appendChild(t)}else if(e===this.couponsSavingsShopping){const e=document.getElementById(this.exploreShopping);e?i.insertBefore(t,e):i.appendChild(t)}}return gn.SO.queueUpdate((()=>{this.unobserveAll(),this.addSentinels(),this.setIntersectionObservers()})),t}scrollTabContentIntoView(e,t){const i=this.tabs.shadowRoot?.querySelector(".tabpanel"),n=document.getElementById(`${this.panelSingleScrollingId}`);if(e&&i&&n){let o={};"smooth"===t&&(o={behavior:"smooth"}),this.unobserveAll(),n.addEventListener("wheel",this.preventScrollingEvent),e.scrollIntoView(o),this.observeIntervalID||(this.observeIntervalID=setInterval((()=>{i&&e.getBoundingClientRect().top<=i.getBoundingClientRect().top+10&&e.getBoundingClientRect().top>=i.getBoundingClientRect().top-10&&(clearInterval(this.observeIntervalID),this.observeIntervalID=null,n.removeEventListener("wheel",this.preventScrollingEvent),this.observeAll())}),100),setTimeout((()=>{clearInterval(this.observeIntervalID),this.observeIntervalID=null,n.removeEventListener("wheel",this.preventScrollingEvent),this.observeAll()}),5e3))}else e&&e.scrollIntoView()}preventScrollingEvent(e){e.preventDefault()}onScrollToTab(e){if(this.tabs.querySelector(`#${e}`)&&e){const t=e;t!==this.singleScrollingActiveTabId&&(this.onTabGetActivated(t),this.sendScrollToTabTelemetry(t))}}observeAll(){document.querySelectorAll(".sentinel").forEach((e=>{this.singleScrollingIntersectionObserver?.observe(e)}))}unobserveAll(){document.querySelectorAll(".sentinel").forEach((e=>{this.singleScrollingIntersectionObserver?.unobserve(e)}))}addSentinel(e,t,i){const n=e?.getElementsByClassName("sentinel");if(!n||n&&0===n.length){const n=(0,Y.Ux)("DIV",{style:"\n position: absolute;\n left: 0;\n right: 0;\n height: 10px;\n bottom: 50px;\n z-index: -1;\n "});n.className="sentinel",n.setAttribute("data-select-tab-up",`${t}`),n.setAttribute("data-select-tab-down",`${i}`),e?.appendChild(n)}}addSentinels(){const e=document.getElementById(this.myShoppingShopping),t=document.getElementById(this.couponsSavingsShopping),i=document.getElementById(this.exploreShopping);e&&this.addSentinel(e,this.tabCouponsSavingsId,this.tabMyShoppingId),t&&i&&this.addSentinel(t,this.tabExploreId,this.tabCouponsSavingsId)}setIntersectionObservers(){const e={root:this.tabs.shadowRoot?.querySelector(".tabpanel"),rootMargin:"0px"};this.singleScrollingIntersectionObserver=new IntersectionObserver(this.intersectionObserverCallback.bind(this),e),this.observeAll()}intersectionObserverCallback(e){e.forEach((e=>{if(!e.isIntersecting&&e.rootBounds&&e.boundingClientRect.top<=e.rootBounds.top&&e.boundingClientRect.height*e.boundingClientRect.width>0){const t=e.target.getAttribute("data-select-tab-up");this.onScrollToTab(t)}else if(e.rootBounds&&e.boundingClientRect.top<e.rootBounds.top+100&&e.boundingClientRect.height*e.boundingClientRect.width>0){const t=e.target.getAttribute("data-select-tab-down");this.onScrollToTab(t)}}))}addTabArrowKeysListeners(e,t){let i=this.tabMyShoppingId,n=this.myShoppingShopping,o=this.tabCouponsSavingsId,r=this.couponsSavingsShopping;t===this.tabMyShoppingId?(i=this.tabCouponsSavingsId,n=this.couponsSavingsShopping,o=this.tabExploreId,r=this.exploreShopping):t===this.tabCouponsSavingsId&&(i=this.tabExploreId,n=this.exploreShopping,o=this.tabMyShoppingId,r=this.myShoppingShopping),e.addEventListener("keydown",(t=>{"ArrowRight"===t.key?this.arrowKeydownCallback(e,i,n):"ArrowLeft"===t.key&&this.arrowKeydownCallback(e,o,r)}))}arrowKeydownCallback(e,t,i){e.blur(),this.tabs.querySelector(`#${t}`).focus();const n=document.getElementById(i);this.scrollTabContentIntoView(n,""),this.onTabGetActivated(t)}addTabFocusListeners(e,t){e.addEventListener("keydown",(e=>{if("Tab"===e.key&&!e.shiftKey){const i=document.getElementById(t);if(i){e.preventDefault();const t=TI.Z.getFirstFocusableElementInParent(i);t&&t.focus()}}}))}renderReRankedContextualModules(t,i){if(!t||0===t.length||this.isSameModuleTypesArray(t))return;e.R.isExperimentActive(f.H.loadingSpinnerWithTimeout)&&ED.removeLoadingSpinnerWrapper();const n=this.tabs.querySelector(`#${this.contextualShopping}`);if(n){const e=n.getElementsByClassName("sectionSeparator");if(e&&e.length>0)for(let t=e.length-1;t>=0;--t)e[t].remove();if(this.contextualModules&&this.contextualModules.length>0)for(let e=this.contextualModules.length-1;e>=0;--e)this.contextualModules[e].element.remove();const o=this.flyoutData.common.shopping.querySelectorAll('[slot="header-content"]');for(const e of o)e.remove();this.updateHeader(n),this.renderModulesInTab(t,this.flyoutData.common.shopping,this.panelContextualId,i,!0),this.contextualModules=t}}renderReRankedContextualModulesInSinglePane(e,t){if(!e||0===e.length||this.isSameModuleTypesArray(e))return;const i=document.getElementById(`${this.couponsSavingsShopping}`);if(i){const n=i.getElementsByClassName("sectionSeparator");if(n&&n.length>0)for(let e=n.length-1;e>=0;--e)n[e].remove();if(this.contextualModules&&this.contextualModules.length>0)for(let e=this.contextualModules.length-1;e>=0;--e)this.contextualModules[e].element.remove();this.reRenderModulesInSingleScrollingTabs(e,i,this.tabCouponsSavingsId,t),this.contextualModules=e,this.updateHeader(i)}}reRenderModulesInSingleScrollingTabs(e,t,i,n){try{const o=t;e&&e.length>0&&this.canRenderContentInTab(e,i)?this.appendModulesToShoppingElement(e,o,n):(this.createNullState(o),i===this.tabMyShoppingId?this.isMyShoppingZeroState=!0:i===this.tabCouponsSavingsId&&(this.isCouponsSavingsZeroState=!0)),this.scrollContentTo00(o)}catch(e){this.onAddingModulesInTabError(e)}}updateHeader(e){e.classList.remove("headerBlock")}isSameModuleTypesArray(e){let t=!0;return e.forEach((e=>{const i=this.contextualModules.findIndex((t=>t.name===e.name));-1!==i&&this.contextualModules.at(i)?.priority===e.priority||(t=!1)})),t}restoreTabName(){const e=this.tabs.querySelector(`#${this.tabContextualId}`);e&&(e.textContent=this.flyoutData.strings.paneForYou);const t=this.tabs.querySelector(`#${this.tabCouponsSavingsId}`);t&&(t.textContent=this.flyoutData.strings.paneCouponsSavings)}focusHomeifRedirectedFromProductTrackingEmail(){try{const e=new URL(this.flyoutData.common.lastCommittedURL);return void("tracked-products"===new URLSearchParams(e.search).get("edge_shopping_source")&&this.setActiveTabId(this.tabHomeId))}catch{return}}};class DD{static getModuleOrCreate(e,t,i,n){if(this.cache.has(e))return this.cache.get(e);{const o=new t(i,n);return this.cache.set(e,o),o}}static getStartShoppingModuleOrCreate(e,t,i,n){return this.getModuleOrCreate(e,t,i,n)}}(0,s.Z)(DD,"cache",new Map);var _D=class extends Qu{constructor(e,t,i,n,o,r,a){super(),(0,s.Z)(this,"assets",null),(0,s.Z)(this,"loggerService",void 0),(0,s.Z)(this,"cashbacScenariousService",void 0),(0,s.Z)(this,"localString",void 0),(0,s.Z)(this,"cashbackUIService",void 0),(0,s.Z)(this,"cashbackContext",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"cashbackFastInitializer",void 0),this.localString=i,this.loggerService=e,this.cashbacScenariousService=t,this.cashbackUIService=n,this.cashbackContext=o,this.pageHandlerModule=r.pageHandlerModule,this.cashbackFastInitializer=a}GetAssets(){return null}GetModuleName(){return r.ModuleNames.UNIFIED_CASHBACK}populateMainHeader(){}CalculateRanking(){return r.zz.SaveMoneyRetailer}async ShouldRenderModule(){if(e.R.isExperimentActive(f.H.cashbackConsolidationExp)){const e=await this.cashbacScenariousService.anyCashbackScenarioAvailable();return this.loggerService.LogDebugInfo("Should render "+e),e}return Promise.resolve(!1)}async createCashbackComponent(){const e=(0,Y.Ux)("msft-cashback-block");e.visibleActivatedOffers=[],e.hiddenActivatedOffers=[],e.shouldExpandDetails=await this.cashbacScenariousService.getShouldExpandDetails(),e.storeWideCashback=this.cashbacScenariousService.getStoreWideOffer();const t=this.cashbacScenariousService.getAllActivatedOffers(),i=await this.cashbacScenariousService.getPersonalizedOfferHero();i&&i.cashbackType!==Cg.hB.PCBStorewide?e.pcbHero=i:t&&t.length>0&&(e.visibleActivatedOffers=t.slice(0,2),e.hiddenActivatedOffers=t.slice(2));const n=await this.cashbacScenariousService.getSpbSearchHeroForOffer();n&&(e.mainSpbSearchCashback=n),await this.cashbacScenariousService.isBlossomScenario(!0)&&e.storeWideCashback&&(e.storeWideCashback.isBlossom=!0);const o=this.cashbacScenariousService.is3xIncentiveCashback();o&&e.storeWideCashback&&(e.storeWideCashback.is3xIncentive=o);const r=this.cashbacScenariousService.getSPBPDPOffer();r&&(e.spbPpdCashback=r);const a=await this.cashbacScenariousService.getSearchSpbOffersForCurrentPage();return a&&(e.searchQuery=await this.cashbackContext.getSearchQuery(),e.visibleSpbOffers=a),e}async renderModule(){const e=await this.createCashbackComponent(),t=this.createModule(e);return this.addRebateStateListeners(),this.cashbackFastInitializer.initializeTokens(),Promise.resolve(t)}addRebateStateListeners(){}createModule(e){const t=(0,Y.Ux)("msft-edge-shopping-section"),i=t;return i.id="unifiedCashbackSection",i.titleText=this.localString.gcbSectionTitle,i.accordion=!1,i.expanded=!0,t.style.width="100%",t.appendChild(e),this.CreateModule(t,r.H7.CASHBACK,r.ModuleNames.CASHBACK,r.$k.CONTEXTUAL,r.SV.BLOCK)}},ND=o(17728),RD=class extends _D{constructor(e,t,i,n,o,r,a){super(e,t,i,n,o,a,r),(0,s.Z)(this,"STOREWIDE_NOTIFICATION_PX_SIZE",320),(0,s.Z)(this,"SMALL_NOTIFICATION_PX_SIZE",268),(0,s.Z)(this,"CONFIRMATION_PAGE_NOTIFICATION",280),(0,s.Z)(this,"DEFAULT_AUTO_CLOSE_AFTER_NOTIFICATION_SHOWN",4500),(0,s.Z)(this,"cashbackTypeShown",void 0),(0,s.Z)(this,"parentWrapper",void 0),(0,s.Z)(this,"cashbackFastInitializer",void 0),this.cashbackFastInitializer=r}async RenderNotification(t){const i=(0,Y.Ux)("msft-cashback-block");i.isNotification=!0;const n=this.cashbackUIService.getPopupOrigination();if(i.popupOrigination=n,this.cashbackFastInitializer.initializeTokens(),this.loggerService.LogDebugInfo(`Started rendering ${n}`),n===u.sR.AUTO_SHOW_REBATES_DEACTIVATED)i.viewName="cashbackTurnedOff";else if(n===u.sR.AUTO_SHOW_REBATES_CONFIRMATION||n===u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_CONFIRMATION)this.cashbacScenariousService.getAllActivatedOffers()&&this.cashbacScenariousService.getAllActivatedOffers().length>0?i.viewName="PCBconfirmationPage":i.viewName="confirmationPage";else if(n===u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK)if(e.R.isExperimentActive(f.H.pcbStorewideUXDesignChange)){const e=await this.cashbacScenariousService.getPersonalizedOfferHero();this.cashbackTypeShown=Cg.hB.SPBorPPCashback,e?.cashbackType===Cg.hB.PCBStorewide?(this.cashbackFastInitializer.init(),i.pcbHero=e,i.viewName="PCBStorewide"):(i.pcbHero=e,i.viewName="PCBOffer"),i.autoCloseAfterMS=this.DEFAULT_AUTO_CLOSE_AFTER_NOTIFICATION_SHOWN}else{const e=await this.cashbacScenariousService.getPersonalizedOfferHero();this.cashbackTypeShown=Cg.hB.SPBorPPCashback,e?.cashbackType===Cg.hB.PCBStorewide?(i.pcbHero=e,i.viewName="PCBStorewideLegacy"):(i.pcbHero=e,i.viewName="PCBOffer"),i.autoCloseAfterMS=this.DEFAULT_AUTO_CLOSE_AFTER_NOTIFICATION_SHOWN}else if(n===u.sR.AUTO_SHOW_SPB_CASHBACK_LANDING){const t=this.cashbacScenariousService.getSPBPDPOffer(),n=await this.cashbacScenariousService.getSpbSearchHeroForOffer();if(t)this.cashbackTypeShown=Cg.hB.SPBPDPCashback,i.viewName=e.R.isExperimentActive(f.H.spbPDPShortDesign)?"SpbPDPV2":"SpbPDP",i.spbPpdCashback=t;else{if(!n)return Promise.resolve(null);this.cashbackTypeShown=Cg.hB.SPBSearchCashback,i.mainSpbSearchCashback=await this.cashbacScenariousService.getSpbSearchHeroForOffer(),i.viewName=e.R.isExperimentActive(f.H.spbShortNotification)?"SPBSearchV2":"Recommened"}}else if(i.storeWideCashback=this.cashbacScenariousService.getStoreWideOffer(),i.storeWideCashback){await this.cashbacScenariousService.isBlossomScenario(!1)&&i.storeWideCashback&&(i.storeWideCashback.isBlossom=!0);const t=this.cashbacScenariousService.is3xIncentiveCashback();t&&i.storeWideCashback&&(i.storeWideCashback.is3xIncentive=t),i.autoCloseAfterMS=this.DEFAULT_AUTO_CLOSE_AFTER_NOTIFICATION_SHOWN,i.viewName=e.R.isExperimentActive(f.H.storewideRangeCashback)?"StorewideRange":e.R.isExperimentActive(f.H.enablePostPurchaseMessage)?"StorewideReceiveAfterPurchaseTitle":"Storewide"}const o=this.createModule(i);"confirmationPage"===i.viewName||"PCBStorewideLegacy"===i.viewName?this.setWidth(this.CONFIRMATION_PAGE_NOTIFICATION):i?.storeWideCashback?.cashbackType===Cg.hB.Storewide||i?.pcbHero?.cashbackType===Cg.hB.PCBStorewide||"SpbPDPV2"===i.viewName||"SPBSearchV2"===i.viewName?this.setWidth(this.STOREWIDE_NOTIFICATION_PX_SIZE):this.setWidth(this.SMALL_NOTIFICATION_PX_SIZE);const a=await this.cashbackUIService.createNotificationFromModule(o);if(a&&a.element){this.parentWrapper=t;const e=this.createNotificationModule(a.element,r.sM.CASHBACK,this);return Promise.resolve(e)}return Promise.resolve(null)}setWidth(e){const t=`\n #divContentWrapper {\n width: ${e}px;\n }\n #divContentCashbackWrapperStorybook {\n width: ${e}px;\n }\n `;this.cashbackUIService.applyStylesToShoppingSection(t)}createNotificationModule(e,t,i){const n=new ND.Z;return n.element=e,n.name=t,n.moduleInterface=i,n}async ShouldRenderNotification(){if(e.R.isExperimentActive(f.H.pcbStorewideUXDesignChange)){const e=await this.cashbacScenariousService.getPersonalizedOfferHero();if(e?.cashbackType===Cg.hB.PCBStorewide)return this.cashbacScenariousService.triggerExperiment(f.H.pcbStorewideUXDesignChange),!0}if(e.R.isExperimentActive(f.H.spbShortNotification)&&await this.cashbacScenariousService.getSpbSearchHeroForOffer())return this.cashbacScenariousService.triggerExperiment(f.H.spbShortNotification),!0;if(e.R.isExperimentActive(f.H.spbPDPShortDesign)&&this.cashbacScenariousService.getSPBPDPOffer())return this.cashbacScenariousService.triggerExperiment(f.H.spbPDPShortDesign),!0;if(e.R.isExperimentActive(f.H.cashbackConsolidationExp)){const e=await this.cashbacScenariousService.anyCashbackScenarioAvailable(),t=this.cashbackUIService.getPopupOrigination(),i=t===u.sR.AUTO_SHOW_REBATES_CONFIRMATION||t===u.sR.AUTO_SHOW_REBATES_DEACTIVATED;if(this.loggerService.LogDebugInfo(`Should render notification ${e} ${i}`),e||i)return this.cashbacScenariousService.triggerExperiment(f.H.cashbackConsolidationExp),!0}return!1}GetNotificationName(){return r.sM.UNIFIED_CASHBACK}PostProcessingNotification(e,t){const[i,n]=this.shouldDismissNotification();i&&this.parentWrapper&&this.setNotificationDismissTimeout(this.parentWrapper,n)}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_REBATES,u.sR.AUTO_SHOW_REBATES_CONFIRMATION,u.sR.AUTO_SHOW_REBATES_DEACTIVATED,u.sR.AUTO_SHOW_REBATES_ORGANIC,u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_CONFIRMATION,u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK,u.sR.AUTO_SHOW_REBATES_SWITCHED_TO_MSA,u.sR.AUTO_SHOW_REBATES_CHECKOUT,u.sR.AUTO_SHOW_REBATES_ORGANIC_NEW,u.sR.AUTO_SHOW_REBATES_PDP,u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_ADDRESSBAR,u.sR.AUTO_SHOW_SPB_CASHBACK_LANDING,u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK,u.sR.AUTO_SHOW_SPB_CHECK_OUT_PAGE_NOTIFICATION]}shouldDismissNotification(){if(this.cashbackTypeShown===Cg.hB.SPBSearchCashback){if(e.R.isExperimentActive(f.H.spbDismissTimeout)||e.R.isExperimentActive(f.H.spbAutoDismissTreatment))return[!0,5]}else if(this.cashbackTypeShown===Cg.hB.SPBorPPCashback)return e.R.isExperimentActive(f.H.cashbackDismissTimeout)?[!0,3]:[!0,10];return[!1,100]}setNotificationDismissTimeout(e,t){const i=t;let n=setTimeout((()=>{this.pageHandlerModule.DismissPopup()}),1e3*i);e.addEventListener("mouseenter",(()=>{clearTimeout(n)})),e.addEventListener("mouseleave",(()=>{n=setTimeout((()=>{this.pageHandlerModule.DismissPopup()}),1e3*i)}))}},MD=class extends _D{constructor(e,t,i,n,o,r,a){super(e,t,i,n,o,r,a)}},LD=class extends RD{constructor(e,t,i,n,o,r,a){super(e,t,i,n,o,r,a)}};class BD extends zi{constructor(){super(),this.autoCloseAfterMS=-1,this.cashbackContext=Og.Z.getFactory().getCasbackContext(),this.loggerService=Og.Z.getFactory().getCashbackLogger(),this.localString=Og.Z.getFactory().getLocalizedStringsData()}connectedCallback(){super.connectedCallback();const e={isNotification:this.isNotification,visibleActivatedOffers:this.visibleActivatedOffers,visibleSpbOffers:this.visibleSpbOffers,mainSpbSearchCashback:this.mainSpbSearchCashback,hiddenActivatedOffers:this.hiddenActivatedOffers,hiddenSpbOffers:this.hiddenSpbOffers,isVisibleSpbOffersExist:this.isVisibleSpbOffersExist(),isVisibleActivatedOffersExist:this.isVisibleActivatedOffersExist(),showFeaturedTab:this.showFeaturedTab(),showOffersTabs:this.showOffersTabs()};this.loggerService.LogDebugInfo("Unified cashback module rendered",e)}isVisibleSpbOffersExist(){let e=!1;return this.visibleSpbOffers&&this.visibleSpbOffers.length>0&&(e=!0),e}isVisibleActivatedOffersExist(){let e=!1;return this.visibleActivatedOffers&&this.visibleActivatedOffers.length>0&&(e=!0),e}showFeaturedTab(){let e=!1;return(this.storeWideCashback||this.mainSpbSearchCashback||this.pcbHero)&&(e=!0),e}showOffersTabs(){const e=this.isVisibleSpbOffersExist()||this.isVisibleActivatedOffersExist()||this.showFeaturedTab();return e||this.loggerService.LogError("Cashback module not shown, no data"),e}clickOnTab(e){const t={tab:e};this.loggerService.LogDebugInfo("Tab visible "+e,t)}showSearchQuery(){return x.ZP.IsValidDataField(this.searchQuery)}getSearchData(){return this.searchQuery}}(0,an.gn)([pn.Lj],BD.prototype,"isNotification",void 0),(0,an.gn)([pn.Lj],BD.prototype,"shouldExpandDetails",void 0),(0,an.gn)([pn.Lj],BD.prototype,"viewName",void 0),(0,an.gn)([pn.Lj],BD.prototype,"popupOrigination",void 0),(0,an.gn)([pn.Lj],BD.prototype,"autoCloseAfterMS",void 0),(0,an.gn)([oi.LO],BD.prototype,"visibleActivatedOffers",void 0),(0,an.gn)([oi.LO],BD.prototype,"visibleSpbOffers",void 0),(0,an.gn)([oi.LO],BD.prototype,"storeWideCashback",void 0),(0,an.gn)([oi.LO],BD.prototype,"mainSpbSearchCashback",void 0),(0,an.gn)([oi.LO],BD.prototype,"spbPpdCashback",void 0),(0,an.gn)([oi.LO],BD.prototype,"pcbHero",void 0),(0,an.gn)([oi.LO],BD.prototype,"hiddenActivatedOffers",void 0),(0,an.gn)([oi.LO],BD.prototype,"hiddenSpbOffers",void 0),(0,an.gn)([pn.Lj],BD.prototype,"searchQuery",void 0);const FD=dn`
.template-cashback-block {
display: flex;
flex-direction: column;
justify-content: center;
}
fluent-accordion-item.show-more-btn::part(heading-content) {
color: var(--text-price-color, rgba(0, 0, 0, 0.83));
}
fluent-accordion-item.show-more-btn::part(icon) {
color: var(--text-price-color, rgba(0, 0, 0, 0.83));
}
.cashback-cards {
margin-top: 12px;
display: flex;
flex-direction: column;
width: 100%;
gap: 12px;
}
.hidden-activated-cards {
margin: 0px;
}
.activatedCards {
gap: 0px;
margin-bottom: 12px;
}
.cashback-tab {
color: var(--Neutral-foreground-neutralForegroundHint, #717171);
font-family: Segoe UI Variable;
font-size: 12px;
font-style: normal;
font-weight: 400;
line-height: 16px; /* 133.333% */
}
.cashback-tab[aria-selected="true"] {
color: var(--Foreground-Brand-Foreground-1, var(--Brand-Color-Brand-Foreground-1, #2169eb));
font-family: Segoe UI Variable;
font-size: 12px;
font-style: normal;
font-weight: 400;
line-height: 16px; /* 133.333% */
border-radius: 100px;
border: 1px solid #2169eb;
background: #fff;
}
fluent-accordion-item.show-more-btn::part(heading) {
display: flex;
justify-content: center;
color: #202124;
text-align: right;
font-family: Segoe UI Variable;
font-size: 14px;
font: inherit;
font-weight: 400;
line-height: 20px; /* 142.857% */
}
fluent-accordion-item.showMoreActivatedOffer {
border-radius: 0px;
border: 0px;
margin-top: 8px;
}
.showMoreActivatedOffer {
padding-bottom: 0px;
border: calc(var(--stroke-width)* 1px) solid transparent;
}
fluent-accordion-item.show-more-btn::part(icon) {
margin: 0;
padding-left: 4px;
width: 0;
}
fluent-accordion-item.showMoreActivatedOffer::part(icon) {
padding-left: 0px;
width: 15px;
}
fluent-accordion-item.showMoreActivatedOffer::part(button) {
margin: 0px;
}
.footer {
display: none;
}
fluent-accordion-item[expanded] {
.header {
display: none;
}
.footer {
display: block;
}
}
fluent-accordion-item::part(region) {
padding: 0px !important;
margin: 0px !important;
border: 0px;
}
.icSubTitle {
margin: 8px 0 10px 0;
padding: 0px 20px 0px 2px;
}
.icSubtitleQuery {
font-weight: 700;
}
.gc-section-list {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 12px;
padding-bottom: 15px;
}
.shopping-tooltip-block-template-wrapper {
display: block;
}
.shopping-tooltip-block-template:hover {
display: block;
}
.isSponsoredIconContainer {
display: flex;
gap: 3px;
justify-content: flex-end;
margin-bottom: 10px;
margin-top: -10px;
}
.icSponsoredImage {
width: 10px;
}
.isSponsoredIconContainer::part(img) {
width: 10px;
}
.icSponsoredText {
font-weight: 400;
font-size: 10px;
line-height: 12px;
display: flex;
align-items: center;
color: var(--text-neutral-foreground);
margin: 0;
}
`,UD=($n`
<fluent-accordion>
<fluent-accordion-item class="show-more-btn">
<div slot="heading">${e=>e.localString.gcbSeeMore}</div>
<div class="cashback-cards">
${Sl((e=>e.hiddenSpbOffers),$n`
<div>
<msft-cashback-offer
viewName="Recommened"
cashbackModuleType=${Cg.hB.SPBSearchCashback}
:cashback=${e=>e}
>
</msft-cashback-offer>
</div>
`)}
</div>
</fluent-accordion-item>
</fluent-accordion>
`,$n`
<fluent-accordion>
<fluent-accordion-item class="show-more-btn showMoreActivatedOffer">
<div class="header" slot="heading">${e=>e.localString.gcbSeeMore}</div>
<div class="cashback-cards hidden-activated-cards">
${Sl((e=>e.hiddenActivatedOffers),$n`
<div>
<msft-cashback-offer
viewName="ActivatedList"
cashbackModuleType=${Cg.hB.SPBorPPCashback}
:cashback=${e=>e}
>
</msft-cashback-offer>
</div>
`)}
</div>
<div class="footer" slot="heading">${e=>e.localString.cbOfferSeeLessButtonTitle}</div>
</fluent-accordion-item>
</fluent-accordion>
`),HD=$n`
${Wr((e=>e.isVisibleSpbOffersExist()),$n`
${Wr((e=>e.showSearchQuery()),$n`
<p class="icSubTitle">
${e=>e.localString.gcbSearchSectionOffTitle}<span class="icSubtitleQuery"> "${e=>e.getSearchData()}"</span>
</p>`)}
<div class="isSponsoredIconContainer" slot="hover-anchor">
<p class="icSponsoredText">Ads</p>
<div class="shopping-tooltip-block-template-wrapper">
<msft-shopping-tooltip
class="shopping-tooltip-block-template"
content="${e=>e.localString.gcSponsoredTooltipNoLink}"
linktext="Find out"
slot="hover-anchor"
isTextHoverable="${!0}"
>
<img src="https://www.bing.com/api/shopping/v1/ux/images//common/infoIcon.svg" slot="hover-anchor" aria-label="Info icon" class="icSponsoredImage">
</msft-shopping-tooltip>
</div>
</div>
<div id="gcSectionList" class="gc-section-list">
${Sl((e=>e.visibleSpbOffers),$n`
<msft-cashback-offer
viewName="Recommened"
cashbackModuleType=${Cg.hB.SPBSearchCashback}
:cashback=${e=>e}
>
</msft-cashback-offer>
`)}
</div>
`)}
`,$D=$n`
${Wr((e=>null==e?void 0:e.storeWideCashback),$n`
<msft-cashback-offer
cashbackModuleType=${e=>{var t;return null===(t=null==e?void 0:e.storeWideCashback)||void 0===t?void 0:t.cashbackType}}
viewName="Storewide"
?shouldExpandDetails=${e=>e.shouldExpandDetails}
:cashback=${e=>e.storeWideCashback}
>
</msft-cashback-offer>
`)}
`,ZD=$n`
${Wr((e=>e.isVisibleActivatedOffersExist()),$n`
<div class="cashback-cards activatedCards">
${Sl((e=>e.visibleActivatedOffers),$n`
<msft-cashback-offer
cashbackModuleType=${Cg.hB.SPBorPPCashback}
viewName="ActivatedList"
:cashback=${e=>e}
>
</msft-cashback-offer>
`)}
${Wr((e=>e.hiddenActivatedOffers.length>0),UD)}
<div></div>
</div>
`)}
`,VD=$n`
${Wr((e=>e.pcbHero),$n`
<msft-cashback-offer
cashbackModuleType=${Cg.hB.SPBorPPCashback}
viewName="PCBOffer"
:cashback=${e=>e.pcbHero}
>
</msft-cashback-offer>
`)}
`,GD=$n`
${Wr((e=>e.spbPpdCashback),$n`
<msft-cashback-offer
cashbackModuleType=${Cg.hB.SPBPDPCashback}
viewName="SpbPDP"
:cashback=${e=>e.spbPpdCashback}>
</msft-cashback-offer>
`)}
`,jD=$n`
<template>
<div id="divCashBackPopup" style="margin-left: 15px; margin-right: 15px; border-radius: 8px;">
${Wr((e=>e.showOffersTabs()),$n`
${()=>GD}
${()=>HD}
${()=>ZD}
${()=>VD}
${()=>$D}
`)}
</div>
</template>
`,zD=$n`
<template>
${Wr((e=>e.viewName&&"PCBStorewide"!==e.viewName),$n`
<msft-cashback-offer
isNotification="true"
autoCloseAfterMs=${e=>e.autoCloseAfterMS}
popupOrigination=${e=>e.popupOrigination}
viewName="${e=>e.viewName}">
</msft-cashback-offer>
`)}
${Wr((e=>e.pcbHero),$n`
<msft-cashback-offer
cashbackModuleType=${Cg.hB.SPBorPPCashback}
isNotification="true"
autoCloseAfterMs=${e=>e.autoCloseAfterMS}
popupOrigination=${e=>e.popupOrigination}
viewName="${e=>e.viewName}"
:cashback=${e=>e.pcbHero}>
</msft-cashback-offer>
`)}
${Wr((e=>null==e?void 0:e.storeWideCashback),$n`
<msft-cashback-offer cashbackModuleType=${e=>{var t;return null===(t=null==e?void 0:e.storeWideCashback)||void 0===t?void 0:t.cashbackType}}
viewName=${e=>e.viewName}
popupOrigination=${e=>e.popupOrigination}
autoCloseAfterMs=${e=>e.autoCloseAfterMS}
isNotification="true"
shouldExpandDetails=${e=>e.shouldExpandDetails}
:cashback=${e=>e.storeWideCashback}>
</msft-cashback-offer>
`)}
${Wr((e=>null==e?void 0:e.mainSpbSearchCashback),$n`
<msft-cashback-offer
viewName=${e=>e.viewName} popupOrigination=${e=>e.popupOrigination}
autoCloseAfterMs=${e=>e.autoCloseAfterMS}
isNotification="true"
cashbackModuleType=${Cg.hB.SPBSearchCashback}
:cashback=${e=>e.mainSpbSearchCashback}>
</msft-cashback-offer>
`)}
${Wr((e=>null==e?void 0:e.spbPpdCashback),$n`
<msft-cashback-offer
viewName=${e=>e.viewName}
popupOrigination=${e=>e.popupOrigination}
autoCloseAfterMs=${e=>e.autoCloseAfterMS}
isNotification="true"
cashbackModuleType=${Cg.hB.SPBPDPCashback}
:cashback=${e=>e.spbPpdCashback}>
</msft-cashback-offer>
`)}
</template>
`,WD=$n`
${Wr((e=>e.isNotification),zD)}
${Wr((e=>!e.isNotification),jD)}
`,KD=BD.compose({baseName:"cashback-block",shadowOptions:{delegatesFocus:!0},styles:FD,template:WD});class qD extends zi{constructor(){super(),this.isNotification=!1,this.autoCloseAfterMs=-1,this.cashbackActivationService=Og.Z.getFactory().getActivationService(),this.cashbackScenarioService=Og.Z.getFactory().getCashbackAvailableScenarious(),this.cashbackUIService=Og.Z.getFactory().getCashbackUIService(),this.localString=Og.Z.getFactory().getLocalizedStringsData()}connectedCallback(){super.connectedCallback(),this.cashbackActivationService.sendVisibilityFeedbackUrl(this.cashback),this.cashbackScenarioService.LogUserShownModule(this.viewName,this.cashback),this.cashbackScenarioService.closeIfNotification(this.autoCloseAfterMs),ze.Z.IsMobile()&&this.cashbackActivationService.listenForCashbackStateChange(this.cashback,(()=>{oi.y$.notify(this,"cashback")}))}disconnectedCallback(){super.disconnectedCallback()}onCashbackButtonClickActivation(){this.getCashBackState()!==Cg.VS.Activated&&this.getCashBackState()!==Cg.VS.Activating&&(this.cashbackActivationService.activateCashback(this.viewName,this.cashback,this.popupOrigination),ze.Z.IsMobile()||oi.y$.notify(this,"cashback"),this.cashbackScenarioService.closeIfNotification(2e3))}navigateToRebateHistory(){this.cashbackScenarioService.navigateToRebateHistory()}openPane(e,t){this.cashbackScenarioService.openPane(this.viewName,e,t)}isCashbackActivated(){var e;return oi.y$.trackVolatile(),(null===(e=this.cashback)||void 0===e?void 0:e.cashbackState)===Cg.VS.Activated}getCashBackStateError(){return this.cashback.cashbackState===Cg.VS.Failed?this.localString.cbErrorMessage:this.cashback.cashbackState===Cg.VS.FetchUserInfoFailed?this.localString.cbFetchUserProfileErrorMessage:null}getCashBackState(){var e;return oi.y$.track(this.cashback,"cashbackState"),null===(e=this.cashback)||void 0===e?void 0:e.cashbackState}cashbackOffPrice(){return this.cashbackScenarioService.calcDiscount(this.cashback)}productPriceAfterCashback(){return this.cashbackScenarioService.getCashbackPriceAfterDiscount(this.cashback)}onSlotClick(){this.cashbackActivationService.navigateToOffer(this.cashback)}getActivateButtonClasses(){let e="";return e=this.isCashbackActivated()?"activated-cashback-btn-text":"activate-cashback-btn-text",e}getBlossomStyle(){return this.cashbackUIService.isDarkMode()?"background:#243966;":""}getDarkLinkStyles(){return this.cashbackUIService.isDarkMode()?"darkLink":""}get3XIncentiveTextClass(){return this.cashbackUIService.isDarkMode()?"microsoftCashbackTextDark":"microsoftCashbackText"}get3XIncentiveStyle(){return this.cashbackUIService.isDarkMode()?"background: linear-gradient(91.21deg, #274A50 0%, #292649 100%);":""}getActivateButtonAppearance(){let e="";return e=this.isCashbackActivated()?"neutral":"accent",e}getCashbackImageUrl(){return this.cashbackUIService.getCashbackImageUrl(this.cashback)}getRetailerImageUrl(){return this.cashbackUIService.getRetailerImageUrl()}getActivateButtonTextBaseOnScenario(){return this.isCashbackActivated(),this.cashbackActivationService.getActivateCashbackLocalizedText(this.cashback)}hasExpireTime(){return!!(this.cashback.expireTimeEpoch&&this.cashback.expireTimeEpoch>0)}getOfferExpireTime(){return this.cashback.expireTimeEpoch&&this.cashback.expireTimeEpoch>0?this.cashbackUIService.getExpireSoon(1e3*this.cashback.expireTimeEpoch):""}getMerchantFullName(){return this.cashbackUIService.getMerchantFullName()}showPrivacyMessage(){return this.cashbackScenarioService.showPrivacyText()}navigateToMicrosoftRewards(){this.cashbackScenarioService.navigateToMicrosoftRewards()}navigateToTermsStatementFlyout(){this.cashbackScenarioService.navigateToTermsStatementFlyout()}navigateToPrivacyCookiesStatement(){this.cashbackScenarioService.navigateToPrivacyCookiesStatement()}getDividedCashbackAmount(){return(this.cashback.cashbackAmount.price/3).toFixed(2)}}(0,an.gn)([pn.Lj],qD.prototype,"logMetadata",void 0),(0,an.gn)([pn.Lj],qD.prototype,"cashbackModuleType",void 0),(0,an.gn)([pn.Lj],qD.prototype,"popupOrigination",void 0),(0,an.gn)([pn.Lj],qD.prototype,"viewName",void 0),(0,an.gn)([pn.Lj],qD.prototype,"isNotification",void 0),(0,an.gn)([pn.Lj],qD.prototype,"shouldExpandDetails",void 0),(0,an.gn)([pn.Lj],qD.prototype,"autoCloseAfterMs",void 0),(0,an.gn)([oi.LO],qD.prototype,"cashback",void 0),(0,an.gn)([oi.LO],qD.prototype,"storeWideCashback",void 0),(0,an.gn)([oi.LO],qD.prototype,"cashbackCategoryData",void 0);var YD=o(69698);const XD=dn`
#divErrorCashbackActivation {
display: grid;
margin-bottom: 5px;
grid-template-columns: auto auto;
grid-gap: 10px;
justify-content: center;
background-color: var(--fill-color)!important;
width: 100%;
}
#divCashBackPopup {
display: flex;
flex-direction: column;
text-align: center;
justify-content: center;
}
#divCashBackCategoriesPopup {
display: flex;
flex-direction: column;
text-align: center;
justify-content: center;
background-color: var(--fill-color);
border-radius: 8px;
}
#cashBackSection.region {
background-color: unset!important;
}
#cbTooltip {
display: inline-block;
vertical-align: top;
white-space: initial;
margin-left: 1px;
}
#divCashBackTitle {
align-items: center;
display: flex;
flex-direction: column;
width: calc(100% - 20px);
}
#divMerchantInfo {
column-gap: 5px;
font-size: 14px;
display: inline-flex;
}
#txtMerchantInfo {
position: relative;
margin-top: 0px;
margin-bottom: 16px;
font-weight: 400;
}
#onTxtMerchantInfo {
position: relative;
margin-top: 0px;
margin-bottom: 0px;
}
#divMerchantIcon {
display: flex;
justify-content: flex-start;
align-items: flex-start;
}
#imgMerchantIcon {
max-height: 16px;
max-width: 16px;
}
#txtSubtitleCb {
font-weight: 400;
margin: 5px 27px;
font-size: 12px;
}
#divWrapperPcb {
width: -webkit-fill-available;
margin-bottom: 15px;
}
#divContentPcb {
display: grid;
grid-template-columns: 50% 50%;
height: 100px;
padding: 0px 20px 0px 8px;
}
#divInfoPcb {
display: flex;
flex-direction: column;
align-items: flex-start;
row-gap: 7px;
}
#txtTitlePcb {
font-size: 16px;
line-height: 22px;
font-weight: 600;
}
#divForYouPcb {
display: flex;
flex-direction: row;
justify-content: center;
align-items: center;
padding: 0px 6px 1px;
gap: 6px;
width: 43px;
background: #1A1A1A;
border-radius: 3px;
color: #FFFFFF;
}
#txtForYouPcb {
line-height: 16px;
font-size: 10px;
font-weight: 700;
display: flex;
align-items: center;
letter-spacing: -0.01em;
text-shadow: rgb(0 0 0 / 17%) 0px 0px 1px;
}
#divCIPcb {
border-radius: 4px;
border: 1px solid var(--stroke-neutral-1-rest, rgba(0, 0, 0, 0.18));
border: 1px solid var(--stroke-neutral-1-rest, color(display-p3 0 0 0 / 0.18));
background: var(--acrylic-light, rgba(255, 255, 255, 0.77));
background: var(--acrylic-light, color(display-p3 1 1 1 / 0.77));
display: flex;
padding: var(--Corner-Radius-Control-Regular, 4px) 8px 5px 6px;
align-items: center;
gap: var(--corner-radius-control-regular, 4px);
width: fit-content;
height: auto;
margin-bottom: 8px;
margin-top: -8px;
}
#txtCIPcb {
color: var(--foreground-neutral-2-rest, rgba(0, 0, 0, 0.74));
font-size: 12px;
font-style: normal;
font-weight: 600;
line-height: 14px;
}
#ciIcon{
display: flex;
}
#dividerPcb {
width: 100%;
height: 1px;
background: rgb(235, 235, 235);
}
#dividerHeader {
width: 100%;
height: 1px;
background: rgb(235, 235, 235);
margin-bottom: 30px;
margin-top: 2px;
}
#divExpWrapperPcb {
display: inline-flex;
font-weight: 400;
font-size: 14px;
line-height: 20px;
margin-top: 10px;
}
#divEnabledPcb {
display: inline-flex;
column-gap: 6px;
box-sizing: border-box;
border: 1px solid rgb(235, 235, 235);
border-radius: 4px;
height: 38px;
align-items: center;
justify-content: center;
margin-top: 8px;
}
#divPrivacyMessage {
font-size: 10px;
line-height: 14px;
margin-top: 12px;
}
#divPrivacyMessage.smallStyles {
margin-bottom: 5px;
margin-left: 16px;
margin-right: 16px;
margin-top: 16px;
text-align: center;
width: 95%;
}
.aLinkCb {
font-size: 10px;
line-height: 14px;
position: relative;
height: 14px;
vertical-align: bottom;
align-self: center;
}
.aLinkCb::part(control) {
padding: 2px 0px 2px 0px !important;
}
.aLinkCbenroll {
font-size: 14px;
line-height: 14px;
position: relative;
height: 10px;
align-self: center;
bottom: 4px;
}
.wrappedText {
white-space: nowrap;
}
.wrappedTextLong {
white-space: nowrap;
text-wrap: balance;
display: block;
max-width: 100%;
width: fit-content;
}
.h2RebatesTitlev2 {
display: flex !important;
flex-wrap: wrap;
column-gap: 4px;
justify-content: center;
align-items: center;
}
.btnWrapper {
max-width: 100%;
width: 100%;
box-sizing: border-box;
}
.btnWrapper .btnPrimary {
width: 100% !important;
min-width: 100%;
max-width: 100%;
}
.btnPrimary::part(control) {
height: 44px;
border-radius: 8px;
}
.btnPrimary::part(content) {
font-weight: 600;
font-size: 16px;
}
.btnWrapper .btnPrimary::part(control) {
width: 100% !important;
min-width: 100%;
max-width: 100%;
padding: 4px 16px;
}
.btnWrapper .btnPrimary::part(content) {
overflow: hidden;
text-overflow: ellipsis;
}
.btnSecondary::part(control) {
background: #C1C1C1 !important;
width: 100% !important;
height: 44px;
border-radius: 8px;
}
.btnSecondary::part(content) {
color: black !important;
}
#previousCashbackSection {
margin-top: 4px;
display: flex;
flex-direction: column;
}
#divPreviousCashBack {
display: grid;
box-sizing: border-box;
justify-content: center;
grid-template-columns: 55% 45%;
}
#btnPreviousCashBack {
min-height: 64px;
height: auto;
padding: 12px;
margin-bottom: 10px;
background: linear-gradient(90deg, rgba(221, 235, 255, 0.3) 0%, rgba(233, 251, 255, 0.3) 30.73%, rgba(255, 249, 217, 0.3) 100%);
cursor: pointer;
border: 1px solid rgba(0, 0, 0, 0.03);
border-radius: 8px;
box-sizing: border-box;
font-family: inherit;
}
#btnPreviousCashBack:focus {
border: 1px solid #000000;
box-shadow: 0 0 0px 2px #ffffff inset;
}
#btnPreviousCashBack.isPersonalized {
width: 100%;
min-height: 52px;
margin-bottom: 10px;
background: white;
}
#btnPreviousCashBack.isPane {
margin-bottom: 0px;
border-radius: 0px 0px 8px 8px;
border: 0px;
width: 100%;
}
#divLastCashbackInfo {
display: flex;
row-gap: 2px;
flex-direction: column;
justify-content: flex-start;
text-align: left;
}
#txtLastCashbackInfo {
text-align: start;
overflow-wrap: break-word;
font-weight: 600;
font-size: 12px;
line-height: 16px;
}
#btnPreviousTransactions {
font-weight: 400;
place-self: start;
font-size: 12px;
line-height: 16px;
margin-top: auto;
height: auto;
}
#btnPreviousTransactions::part(control) {
background: transparent;
padding: 0px;
}
#divCashbackBalances {
display: flex;
flex-direction: column;
text-align: right;
align-items: flex-end;
width: -webkit-fill-available;
}
#txtGreyBalance {
font-weight: 400;
font-size: 12px;
line-height: 16px;
text-align: right;
color: var(--text-neutral-foreground-hint);
}
#txtCashbackAmount {
font-size: 20px;
line-height: 26px;
}
#txtMyCashBack {
margin-left: 10px;
font-size: 12px;
font-weight: 600;
color: rgb(3, 106, 196);
align-self: center;
}
#divLifetimeEarned {
display: flex;
margin-left: auto;
margin-right: 10px;
column-gap: 8px;
align-items: center;
}
#txtLifetimeEarned {
font-size: 12px;
font-weight: 400;
color: var(--text-neutral-foreground-hint);
}
#txtPriceDecorative {
font-size: 10px;
line-height: 14px;
font-weight: 600;
margin-top: 2px;
color: var(--text-normal);
}
#txtPriceBalance {
font-size: 16px;
line-height: 22px;
font-weight: 600;
position: relative;
color: var(--text-normal);
}
.activated::part(control) {
border-color: transparent;
background: rgba(0, 0, 0, 0.07);
font-weight: 500;
box-sizing: border-box;
border-radius: 4px;
opacity: 1;
color: #000000;
pointer-events: none;
}
.activated:hover {
outline: 2px solid transparent;
background-color: ButtonFace;
color: ButtonText;
border-color: ButtonText;
}
.activated:focus {
border-color: #000000;
box-shadow: 0 0 0px 2px #ffffff inset;
}
.activatedText
{
overflow: hidden;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-line-clamp: 1;
-webkit-box-orient: vertical;
margin: 0;
white-space: break-spaces;
}
#aOfferDetails {
font-size: 12px;
font-weight: 400;
display: flex;
align-items: center;
line-height: 10px;
gap: 8px;
justify-content: center;
}
#aOfferDetailsText {
font-weight: 400;
}
#h2CashbackSectionTitle {
font-size: 18px;
font-style: normal;
font-weight: 600;
line-height: 24px;
margin-bottom: 8px!important
}
#divConfirmationCb {
width: 100%;
display: flex;
flex-direction: column;
flex-grow: 2;
justify-content: center;
}
#divConfirmationPcb {
display: flex;
flex-direction: column;
flex-grow: 2;
margin-left: 8px;
margin-right: 8px;
justify-content: center;
}
#divConfHeaderPcb {
display: flex;
flex-direction: column;
row-gap: 10px;
}
#divConfTitlePcb {
margin-left: 2px;
font-size: 16px;
line-height: 22px;
font-weight: 600;
}
#divEmailUpdatesPcb {
font-size: 12px;
line-height: 18px;
font-weight: 400;
text-align: left;
}
#divConfTitleCb {
margin: 0px;
font-weight: 500;
font-size: 24px;
line-height: 34px;
}
#divCashBackContent {
width: 100%;
display: flex;
flex-direction: column;
flex-grow: 2;
margin: 0px;
justify-content: center;
align-items: center;
box-sizing: border-box;
}
.storewide-cashback-exclusion-text {
color: var(--Light-Foreground-Foreground-4, var(--Color-Neutral-Foreground-4-Rest, #707070));
font: inherit;
font-size: 10px;
font-style: normal;
font-weight: 400;
line-height: 14px;
text-align: justify;
}
#divDelayedCashBackTitleWrapper {
display: flex;
padding: 16px 54px 0;
flex-direction: column;
align-items: center;
justify-content: center;
gap: var(--corner-radius-control-large, 8px);
}
#divDelayedCashBackActivatedMessageWrapper {
display: flex;
align-items: center;
gap: 6px;
}
#divDelayedCashBackBottomContent {
display: flex;
flex-direction: column;
align-items: center;
padding: 0px 16px 16px;
margin-top: 12px;
}
.divCommissionValue {
display: inline-block;
margin: 0px;
vertical-align: text-bottom;
}
.divCommissionWrapper {
display: flex;
align-self: center;
}
.spanCommissionValue,
.spanCommissionValueLarge {
display: flex;
height: 30px;
line-height: 28px;
font-size: 24px;
background: #0078D4;
color: #fff;
font-weight: 600;
float: left;
padding-left: 1px;
}
.spanCommissionValueSmall {
display: flex;
height: 20px;
line-height: 20px;
font-size: 12px;
background: #0078D4;
color: #fff;
font-weight: 400;
float: left;
}
.splitPrice {
font-size: 16px;
position: relative;
line-height: 25px;
align-self: flex-start;
}
.splitPriceSmall {
font-size: 14px;
position: relative;
line-height: 18px;
align-self: flex-start;
}
#h2RebatesTitle {
display: inline;
margin: 0px;
font-weight: 600;
font-size: 22px;
line-height: 32px;
vertical-align: middle;
text-align: center;
}
#h2RebatesTitle3x {
display: inline;
margin: 0px;
font-weight: 600;
font-size: 22px;
line-height: 32px;
text-align: justify;
}
#divCommissionValueStriked {
text-decoration:line-through;
margin-right: 5px;
}
#h2RebatesTitlejP {
margin: 0px;
font-weight: 600;
font-size: 24px;
line-height: 32px;
vertical-align: middle;
text-align: center;
display: flex;
gap: 3px;
align-items: center;
min-width: fit-content;
flex-wrap: wrap;
justify-content: center;
}
.pcbSeeMore {
margin: 0px !important;
}
#divBadge {
display: flex;
justify-content: left;
align-items: center;
}
#divBadgeContainer {
display: flex;
flex-direction: row;
align-items: center;
margin: 12px 0px;
border-radius: 4px;
color: #F3F3F3;
background-color: #017294;
}
#txtBadge {
font-size: 12px;
font-weight: 700;
text-align: center;
padding: 0px 6px;
margin: 0;
text-transform: uppercase;
}
.btnTooltip svg path {
fill: buttonText;
}
#divAutoApplyActions {
width: 100%;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
}
#h2TurnedOffCb {
margin: 0px;
font-weight: 500;
font-size: 20px;
line-height: 34px;
}
#spanTurnedOffCb {
line-height: 20px;
margin-top: 16px;
word-break: break-word;
}
#animatedWrapperA {
position: relative;
overflow: hidden;
height: 18px;
width: 100%;
display: flex;
flex-direction: row;
justify-content: center;
gap: 8px;
font-weight: 600;
line-height: 16px;
font-size: 12px;
margin: 16px 0 8px 0;
box-sizing: border-box;
}
.arrowAnimatedStep {
height: 18px;
width: fit-content;
opacity: 0;
animation: slidein 0.5s ease-out forwards;
}
.arrowActivatedStep {
color: #6D6D6D;
}
@keyframes slidein {
0% {
opacity: 0;
transform: translateX(-45px);
}
50% {
opacity: 0;
}
100% {
opacity: 1;
}
}
#animatedWrapperB {
position: relative;
width: min(100%, 248px);
height: 104px;
background-color: #FAFAFA;
border-radius: 4px;
margin: 8px 16px 0 16px;
display: flex;
flex-direction: row;
}
#downTextWrapper {
display: flex;
flex-direction: column;
align-items: flex-start;
padding: 0 16px 12px 16px;
gap: 8px;
}
#downVarTitle {
position: absolute;
margin: 0;
padding-bottom: 8px;
font-size: 14px;
font-weight: 600;
line-height: 16px;
animation: slidedown 0.5s linear forwards;
}
#downImageWrapper {
position: absolute;
width: 60px;
height: 35px;
right: 0px;
top: 0px;
}
.downStepWrapper {
display: flex;
flex-direction: row;
width: 100%;
height: 20px;
gap: 6px;
align-items: center;
font-weight: 400;
padding-bottom: 4px;
opacity: 0;
position: absolute;
animation: slidedown 0.5s ease-out forwards;
}
.microsoftLogo {
width: 20px;
height: 20px;
border: 0.5px solid rgba(0, 0, 0, 0.1);
border-radius: 22px;
}
#divExpirationStringPcb {
display: inline-flex;
margin-top: 8px;
gap: 6px;
font-size: 14px;
line-height: 20px;
}
.pcbButtonAddressbar {
margin-top: 16px;
width: auto;
}
#limitedOffer3xincentive{
font-size: 14px;
font-weight: 600;
line-height: 16px;
letter-spacing: 0em;
text-align: left;
margin: 0px;
margin-bottom: 5px;
}
.coloredBanner {
width: 100%;
height: 52px;
display: block;
background: linear-gradient(91.21deg, #E8E0FC 0%, #EAFEFC 100%);
}
#div3xIncentiveTitle{
display:flex;
}
#div3xMerchantInfo{
display:flex;
}
.infoIcon {
width: 10px;
height: 10px;
position: relative;
padding-left: 3px;
padding-bottom: 7px;
margin-top: 15px;
margin-right: 12px;
}
.microsoftExclusiveText{
font-size: 12px;
color: var(--fill-color);
font-weight: 600;
line-height: 16px;
letter-spacing: 0em;
text-align: center;
margin-left: auto;
margin-right: auto;
margin: 1px;
margin-top: 6px;
}
#onTxtMerchantInfo {
position: relative;
margin-top: 0px;
margin-bottom: 0px;
font-size: 14px;
font-weight: 400;
line-height: 16px;
letter-spacing: 0em;
text-align: center;
margin-right: 5px;
}
.microsoftCashbackText{
font-size: 18px;
font-weight: 700;
line-height: 24px;
letter-spacing: 0em;
margin: 1px;
text-align: center;
background: linear-gradient(180deg, #163398 27.46%, #4768DC 82.39%);
-webkit-background-clip: text;
background-clip: text;
-webkit-text-fill-color: transparent;
}
.microsoftCashbackTextDark{
font-size: 18px;
font-weight: 700;
line-height: 24px;
letter-spacing: 0em;
margin: 1px;
text-align: center;
font-color:white;
}
#cashbackBtn3xIncentive {
width: "80% !important";
height: 40px;
margin-bottom: 15px;
padding-left: 15px;
padding-right: 15px;
}
#cashbackTitle3xIncentive {
display: inline;
margin: 0px;
font-weight: 600;
font-size: 20px;
line-height: 32px;
vertical-align: middle;
text-align: center;
margin: 12px;
margin-right: 0px;
}
#div3xCashbackContent{
width: 100%;
display: flex;
flex-direction: column;
flex-grow: 2;
margin: 0px;
justify-content: center;
align-items: center;
background-color:white;
}
.spanCommissionValue3xIncentive {
display: flex;
height: 30px;
line-height: 28px;
font-size: 20px !important;
background: #0078D4;
color: #fff;
font-weight: 600;
float: left;
}
#divBadge {
display: flex;
justify-content: left;
align-items: center;
}
#divBadgeContainer {
display: flex;
flex-direction: row;
align-items: center;
margin: 12px 0px;
border-radius: 4px;
color: #F3F3F3;
background-color: #017294;
}
.downStepNumber {
border-radius: 50%;
width: 15px;
height: 15px;
border: 1px solid #3267FA;
color: #3267FA;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
font-size: 12px;
font-weight: 700;
}
.downStepText {
line-height: 16px;
font-size: 12px;
}
@keyframes slidedown {
100% {
opacity: 1;
transform: translateY(12px);
}
}
@media (forced-colors: active) {
.activated {
background-color: Highlight;
forced-color-adjust: none;
color: highlightText;
}
.activated: focus {
box-shadow: 0 0 0 2px HighlightText inset;
border-color: buttonText;
}
.imgCBTag {
display: none;
}
.cbtagBefore {
float: left;
margin-right: -1px;
height: 20px;
}
.cbtagAfter {
float: left;
height: 20px;
}
}
@media (prefers-reduced-motion: reduce) {
.arrowAnimatedStep {
animation: none;
opacity: 1;
}
#downVarTitle {
animation: none;
top: 12px;
}
.downStepWrapper {
animation: none;
opacity: 1;
margin-top: 12px;
}
}
.icTextContainer {
display: flex;
flex-direction: column;
width: 100%;
color: #222222;
gap: 2px;
margin-bottom: 16px;
margin-top: 12px;
}
.icPercentOff {
position: absolute;
}
#activatedIcon {
display: inline-flex;
column-gap: 6px;
box-sizing: border-box;
border: 1px solid rgb(235, 235, 235);
border-radius: 4px;
height: 38px;
align-items: center;
justify-content: center;
margin-top: 8px;
margin-left: auto;
margin-right: auto;
width: 100%;
}
.adsIconContainer {
display: flex;
gap: 6px;
}
.adsIcon {
border: 1px solid #737373;
margin: 0;
font-weight: 600;
font-size: 10px;
line-height: 14px;
color: #737373;
padding: 0 5px;
border-radius: 4px;
}
.adsSlugImg {
width: 22px;
height: 14px;
vertical-align:middle;
}
.icCashbackValueText {
font-weight: 700;
font-size: 32px;
line-height: 43px;
display: flex;
align-items: center;
color: #008A21;
margin: 0;
}
.icCashbackText {
font-weight: 700;
font-size: 18px;
line-height: 22px;
color: #008A21;
margin: 0;
}
.icCashbackContainer {
display: flex;
align-items: baseline;
gap: 7px;
}
.icImageContainer {
border-radius: 8px;
}
.icTextAndImageContainer {
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
}
.divider {
width: 100%;
border-top: 1px solid #EBEBEB;
padding-right: 16px;
padding-left: 16px;
}
.icActionButton {
border-radius: 4px;
height: 32px;
font-size: 14px;
font-weight: 400;
width: 100%;
}
.icSeeMoreOffersButton {
font-weight: 600;
font-size: 14px;
line-height: 20px;
color: #036AC4;
background-color: transparent;
display: flex;
width: fit-content;
margin: 8px auto 0 auto;
height: auto;
}
.asLink::part(control) {
border: unset;
}
.icDescriptionText {
margin: 0 !important;
color: #464646 !important;
}
.icDescriptionTextGridCard {
color: var(--text-neutral-foreground-hint) !important;
}
.icAfterText {
margin: 0;
font-weight: 400;
font-size: 12px;
line-height: 16px;
display: flex;
align-items: center;
}
.isSponsoredIconContainer {
display: flex;
gap: 3px;
justify-content: flex-end;
margin-bottom: 10px;
margin-top: -10px;
}
.icSponsoredContainer {
display: flex;
align-items: center;
justify-content: end;
gap: 6px;
margin-top: 9px;
width: 100%;
}
.icSponsoredText {
font-weight: 400;
font-size: 10px;
line-height: 12px;
display: flex;
align-items: center;
color: var(--text-neutral-foreground);
margin: 0;
}
.icPriceContainer {
display: flex;
position: relative;
width: fit-content;
gap: 6px;
margin: 5px 0 2px 0;
align-items: baseline;
}
.icPriceContainerMainPrice {
margin: 0;
font-weight: 700;
font-size: 16px;
line-height: 22px;
display: flex;
align-items: center;
color: #D63600;
}
.icPriceContainerCrossedPrice {
font-weight: 400;
font-size: 12px;
line-height: 16px;
display: flex;
align-items: center;
text-decoration-line: line-through;
color: var(--text-neutral-foreground-hint);
margin: 0;
}
.icSubTitle {
margin: 0 0 10px 0;
padding: 0 20px;
background-color: var(--fill-color);
}
.icSubtitleQuery {
font-weight: 700;
}
.searchTitleContainer {
display: flex;
flex-direction: row;
justify-content: space-between;
margin: 10px 0;
}
.searchTitleText {
font-size: 18px;
line-height: 24px;
font-weight: 600;
margin: 0;
}
.searchTitleContainer .isSponsoredIconContainer {
margin: 0;
}
.loader {
border: 6px solid #f3f3f3; /* Light grey */
border-top: 6px solid #3498db; /* Blue */
border-radius: 100%;
width: 30px;
height: 30px;
animation: spin 2s linear infinite;
}
@keyframes spin {
0% { transform: rotate(0deg); }
100% { transform: rotate(360deg); }
}
${zn("grid")} :host {
--content-max-lines: 2;
outline: none;
font-family: ${qn.SVJ};
font-size: ${qn.sNp};
font-weight: 600;
line-height: ${qn.vgC};
min-width: calc(${Lo} * 1px);
border-radius: calc(${qn.rSr} * 1px);
box-sizing: border-box;
color: ${qn.CHi};
fill: currentcolor;
cursor: pointer;
position: relative;
}
:host {
display: block;
box-sizing: border-box;
}
.control:${No} {
box-shadow: 0 0 0 calc(${qn.vxp} * 1px) ${qn.yGg};
}
.aCashbackCardWrapper {
display: grid;
height: 100px;
width: 100%;
align-items: center;
gap: 15px;
padding: 12px 12px;
box-sizing: border-box;
text-decoration: none;
background: transparent;
outline: none;
border: none;
color: inherit;
fill: inherit;
border-radius: 0px;
border-top: var(--product-wrapper-border, 1px solid rgb(236, 236, 236));
position: relative;
}
.aCashbackCardWrapperPane {
display: grid;
grid-template-columns: 66px 1fr;
height: 80px;
width: 100%;
align-items: center;
gap: 15px;
box-sizing: border-box;
text-decoration: none;
outline: none;
border: none;
color: inherit;
fill: inherit;
background-color: #FFFFFF;
border-radius: 0px;
padding: 0px 16px;
position: relative;
}
.productImgContainer {
width: 64px;
height: 64px;
border-radius: 4px;
}
.activatedImgProduct {
height: 100%;
width: 100%;
object-fit: contain;
top: 16px;
left: 16px;
min-width: 64px;
min-height: 64px;
}
.imgAlpha {
width: 64px;
height: 64px;
}
.minPurchaseValue {
color: var(--text-price-color, rgba(0, 0, 0, 0.83));
margin-left: 2px;
}
.favIconRow {
display: flex;
column-gap: 6px;
}
.isFirst {
border-top-left-radius: 8px;
border-top-right-radius: 8px;
}
.isLast {
border-bottom-left-radius: 8px;
border-bottom-right-radius: 8px;
}
.activatedCardWrapper {
border-bottom-left-radius: 0px;
border-bottom-right-radius: 0px;
padding-top: 8px;
border-radius: 8px;
padding-bottom: 8px;
}
.divPriceInfo {
display: flex;
flex-direction: row;
row-gap: 5px;
margin-left: auto;
}
.endsIn {
font-size: 10px;
white-space: nowrap;
line-height: 19px;
}
.divPrice {
display = inline-flex;
justify-content = center;
}
.divCommissionValue {
display: inline-flex;
margin: 0px;
vertical-align: middle;
}
.pcbSpanCommissionValueSmall {
background: #036AC4;
height: 18px;
box-sizing: border-box;
display: flex;
line-height: 12px;
font-size: 14px;
color: #fff;
font-weight: 600;
float: left;
align-items: center;
}
.pcbSpanCommissionValueLarge {
background: #036AC4;
height: 30px;
box-sizing: border-box;
display: flex;
line-height: 24px;
font-size: 24px;
color: #fff;
font-weight: 600;
float: left;
align-items: center;
}
.cashbackStr {
color: var(--text-price-color, rgba(0, 0, 0, 0.83));
}
.priceDiv {
display: inline-flex;
column-gap: 3px;
}
.txtPrice {
font-size: 16px;
line-height: 22px;
text-align: right;
color: var(--text-price-color, rgba(0, 0, 0, 0.83));
font-weight: 600;
}
.txtDescription {
display: -webkit-box;
-webkit-line-clamp: 1;
-webkit-box-orient: vertical;
overflow: hidden;
font-style: normal;
text-align: left;
max-width: 200px;
}
.txtDescriptionFirst {
font-weight: 600;
font-size: 16px;
line-height: 22px;
}
.txtDescriptionElse{
font-weight: 400;
font-size: 12px;
line-height: 16px;
}
.txtExpireTime {
font-size: 10px;
line-height: 17px;
text-align: right;
color: var(--text-red-savings-color, #DE3700);
font-weight: 400;
margin-left: 5px;
}
.txtCashbackFirst {
font-style: normal;
font-weight: 600;
font-size: 32px;
line-height: 40px;
color: #008A21;
}
.divTopAnnotation {
display: grid;
grid-template-columns: auto 1fr;
align-items: center;
}
.divAttribution {
display: grid;
grid-template-columns: auto minmax(0px, 1fr);
}
.divTextContent {
display: flex;
flex-direction: row;
margin-top: 9px;
min-width: 0;
align-item: center;
}
.divCashbackAmount{
font-size: 12px;
font-weight: 600;
line-height: 16px;
}
::slotted([slot="cashBack"]){
font-size: 12px;
line-height: 16px;
text-align: left;
align-self: center;
font-weight: 400;
color: var(--text-price-color, rgba(0, 0, 0, 0.83));
}
::slotted([slot="expireTime"]) {
font-size: 12px;
line-height: 16px;
text-align: right;
color: var(--text-price-color, rgba(0, 0, 0, 0.83));
font-weight: 400;
}
::slotted([slot="image"]) {
max-width: 66px;
max-height: 66px;
}
@media (prefers-color-scheme: dark) {
.txtPrice {
color: var(--text-price-color, #FFFFFF);
}
.::slotted([slot="expireTime"]) {
color: var(--text-price-color, #FFFFFF);
}
::slotted([slot="cashBack"]){
color: var(--text-retailer-color, #FFFFFF);
}
.aCashbackCardWrapperPane {
background-color: rgb(66, 66, 66);
}
.cashbackContent {
background-color: rgb(66, 66, 66) !important;
}
.productImgContainer{
background-color: #FFFFFF;
}
.icDescriptionText, .category-detail, .icAfterText, .adsIconContainer, .adsIcon, .icSeeMoreOffersButton, .storewide-cashback-exclusion-text {
color: #FFFFFF !important;
}
#gcMainContentSpbCard {
background-color: unset !important;
}
.icGridAndImageContainerClassName {
background: var(--fill-color) !important;
border: 1px solid var(--fill-color);
}
.icImageContainerWrapper {
border-radius: 8px;
}
}
.offerDetailsBtn {
padding-bottom: 0px;
border: calc(var(--stroke-width)* 1px) solid transparent;
}
.cashbackContent {
background-color: #FFFFFF;
border-radius: 8px;
padding: 10px;
}
.progressRing {
width: 17px;
height: 17px;
margin-right: 4px;
}
.progressRing::part(indeterminate-indicator-1) {
stroke: white;
}
.activated-cashback-btn {
width: 90%;
margin-top: 8px;
height: 40px;
font-weight: 500;
border-radius: 8px;
}
fluent-button.activated-cashback-btn::part(content) {
display: flex;
align-items: center;
}
.divCommissionValue .cashback-badge-before {
float: left;
margin-right: -1px;
height: 30px;
}
.divCommissionValue .cashback-badge-after {
float: left;
height: 30px;
}
.img-retailer-icon {
max-width: 16px;
}
.btn-full-width {
width: 100%
}
.mt-2{
margin-top: 16px;
}
.my-2 {
margin-top: 16px;
margin-bottom: 16px
}
.mr-2 {
margin-right: 8px;
}
.pl-2 {
padding-left: 1px;
}
.py-2 {
padding: 8px 0;
}
.notification-privacy {
width: 90%;
margin: 12px 0;
}
.activated-btn {
display: flex;
width: 100%;
align-items: center;
}
.activatedTxt {
font-weight: 600;
}
.privacy-message-content{
font-weight: 400;
font-size: 10px;
height: 70px;
text-align: justify;
overflow: hidden;
color: var(--text-price-color, rgba(0, 0, 0, 0.83));
text-overflow: ellipsis;
/* caption2 */
font-family: 'Segoe UI';
font-size: 10px;
font-style: normal;
font-weight: 400;
line-height: 14px; /* 140% */
}
.separator {
width: 90%;
border-top: var(--product-wrapper-border, 1px solid rgb(236, 236, 236));
}
.offer-details-content{
width: 90%;
margin: 10px 0;
font-size: 14px;
font-weight: 400;
}
.d-inline-block {
display: inline-block;
}
#gcMainContentSpbCard {
background-color: rgb(255, 255, 255);
position: relative;
}
.icGridAndImageContainerClassName{
background: white;
border-radius: 8px;
height: 200px;
padding: 12px;
}
.icImageContainerWrapper{
display: flex;
align-items: center;
justify-content: center;
background: #FFFFFF;
}
.icImageContainerWrapper img {
height: 120px;
width: 100%;
object-fit: contain;
}
.gcTextContainer {
color: rgb(34, 34, 34);
width: 100%;
}
.icPriceContainer {
display: flex;
gap: 5px;
}
.icPriceContainerMainPrice {
margin: 0;
font-weight: 700;
font-size: 16px;
line-height: 22px;
display: flex;
align-items: center;
color: #D63600;
}
.icPriceContainerCrossedPrice {
font-weight: 400;
font-size: 12px;
line-height: 16px;
display: flex;
align-items: center;
text-decoration-line: line-through;
color: var(--text-neutral-foreground-hint);
margin: 0;
}
.icAfterText {
margin: 0;
font-weight: 400;
font-size: 12px;
line-height: 16px;
display: flex;
align-items: center;
}
.gcCouponContainer {
display: flex;
position: relative;
width: fit-content;
}
.gcCouponContainer > div {
display: flex;
height: 100%;
border-radius: 6px 0px 0px 6px;
}
.gcCouponContainer> div > p {
color: rgb(255, 255, 255);
inset: 0px;
display: flex;
justify-content: center;
height: 20px;
margin: auto;
white-space: nowrap;
padding: 0px 5px;
border-radius: 6px 0px 0px 6px;
background-color: ${YD.BI};
font-weight: 400;
font-size: 12px;
line-height: 18px;
}
.cashbackAfterText {
margin-left: -3px;
height: 20px;
}
.icDescriptionTextGridCard {
margin: 2px 0px 0px;
color: rgb(26, 26, 26);
font-weight: 400;
font-size: 12px;
line-height: 16px;
overflow: hidden;
text-overflow: ellipsis;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
white-space: normal;
display: -webkit-box !important;
}
.recommended-badge {
display: flex;
gap: 5px
}
.category-container {
display: flex;
flex-direction: row;
margin-bottom: 12px;
}
.category-detail {
margin-left: 12px;
color: var(--Light-Foreground-Foreground-2, var(--Color-Neutral-Foreground-2-Rest, #424242));
font: inherit;
font-size: 12px;
font-style: normal;
font-weight: 400;
line-height: 16px;
text-align:justify;
text-justify:inter-word;
}
.offer-details-block {
padding-top: 12px;
border-radius: Global.Corner.Radius.None;
border-top: 1px solid var(--Stroke-Neutral-3-Rest, rgba(0, 0, 0, 0.06));
}
fluent-accordion-item.show-more-btn::part(heading) {
display: flex;
justify-content: center;
width: 100%
}
fluent-accordion-item::part(region) {
padding: 0px;
margin: 0px;
}
fluent-accordion-item.show-more-btn::part(button) {
margin: 0;
}
fluent-accordion-item.show-more-btn::part(icon) {
margin: 0;
padding-left: 4px;
width: 0;
}
.show-more-btn {
border-radius: 4px;
padding-bottom: 4px;
}
.storewide-cashback-exclusion-text {
color: var(--Light-Foreground-Foreground-4, var(--Color-Neutral-Foreground-4-Rest, #707070));
font: inherit;
font-size: 10px;
font-style: normal;
font-weight: 400;
line-height: 14px;
text-align: justify;
}
.btnPrimary {
width: calc(100% - 32px);
height: 44px;
font-weight: 600;
font-size: 16px;
line-height: 20px;
border-radius: 8px;
}
.btnPrimaryColor {
height: 48px;
font-weight: 600;
font-size: 16px;
line-height: 20px;
color: #FFFFFF;
background: linear-gradient(90.05deg, #8300D4 0.59%, #0048D4 67.54%, #00D4A1 104.11%);
}
.btnPrimaryColor:hover {
background: linear-gradient(90.05deg, #9E00FF 0.59%, #0048D4 67.54%, #00FFC2 104.11%);
}
#blossomBox {
background: #E0EDFF;
height: 54px;
width: 100%;
border-radius: 6px;
font-size: 14px;
line-height: 20px;
margin-top: 8px;
display: flex;
flex-direction: column;
text-align: center;
}
.blossomLink {
color: var(--text-price-color, rgba(0, 0, 0, 0.83));
text-decoration: none;
white-space: nowrap;
}
.darkLink {
color: #63ADE5;
}
.pcb-storewide-block {
display: flex;
flex-direction: column;
align-content: flex-start;
gap: var(--spacing-vertical-S, 8px);
background-color: var(--fill-color)!important;
padding: var(--spacing-vertical-sNudge, 6px) var(--Horizontal-L, 16px) 0px var(--Horizontal-L, 16px);
}
.spb-block-title {
color: var(--color-neutral-foreground-1, rgba(0, 0, 0, 0.86));
/* subtitle2 */
font-family: 'Segoe UI';
font-size: 16px;
font-style: normal;
font-weight: 600;
line-height: 22px; /* 137.5% */
display: flex;
flex-direction: row;
color: var(--text-price-color, rgba(0, 0, 0, 0.83));
align-content: baseline;
gap: var(--spacing-horizontal-sNudge, 6px);
}
.pcb-storewide-block-title {
color: var(--color-neutral-foreground-1, rgba(0, 0, 0, 0.86));
/* subtitle2 */
font-family: 'Segoe UI';
font-size: 16px;
font-style: normal;
font-weight: 600;
line-height: 22px; /* 137.5% */
display: flex;
flex-direction: row;
color: var(--text-price-color, rgba(0, 0, 0, 0.83));
align-content: baseline;
gap: var(--spacing-horizontal-sNudge, 6px);
justify-content: center;
}
.pcb-storewide-offer-ends-in {
display: flex;
padding: 4px;
justify-content: left;
display: flex;
flex-direction: row;
color: var(--text-price-color, rgba(0, 0, 0, 0.83));
align-content: baseline;
gap: var(--spacing-vertical-mNudge, 10px);
justify-content: center;
}
.align-icon-with-text {
display: flex;
align-items: center;
}
.pcb-storewide-block-subtext {
overflow: hidden;
color: var(--text-price-color, rgba(0, 0, 0, 0.83));
text-overflow: ellipsis;
font-family: 'Segoe UI';
font-size: 14px;
font-style: normal;
font-weight: 400;
line-height: 20px;
}
.pcb-ends-in {
color: var(--text-red-savings-color, #DE3700);
}
.spb-activate-btn {
width: 100%;
}
.spb-notification {
margin: 0px 16px 0px 16px;
background-color: var(--fill-color)!important;
font-color: var(--text-price-color, rgba(0, 0, 0, 0.83));
}
.spb-notification-image {
width: 64px;
height: 64px;
object-fit: contain;
border-radius: var(--borderRadius-medium, 4px);
border: 0.5px solid var(--color-neutral-stroke-3, rgba(0, 0, 0, 0.06));
}
.spb-item-description {
display: flex;
margin-left: 5px;
flex-direction: column;
align-items: flex-start;
}
.spb-notification-block {
display: flex;
flex-direction: row;
align-items: flex-start;
}
.spb-cashback-title-block {
display: grid;
grid-template-columns: auto auto;
}
.spb-view-more-offers {
height: 20px;
align-self: stretch;
overflow: hidden;
color: ${YD.rE};
text-overflow: ellipsis;
white-space: nowrap;
text-align: left;
/* body1 */
font-family: 'Segoe UI';
font-size: 14px;
font-style: normal;
font-weight: 400;
line-height: 20px; /* 142.857% */
}
.spb-cashback-title {
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 1;
text-align: left;
overflow: hidden;
text-overflow: ellipsis;
/* body1 */
font-color: var(--text-price-color, rgba(0, 0, 0, 0.83));
font-family: 'Segoe UI';
font-size: 14px;
font-style: normal;
font-weight: 400;
line-height: 20px; /* 142.857% */
}
`.withBehaviors(Gn(dn`
:host {
forced-color-adjust: auto;
}
:host .control:hover,
:host .control:${No} {
forced-color-adjust: none;
box-shadow: inset 0 0 0 calc((${qn.Han} * 1px)) ${Ns.ButtonText};
}
:host([href]),
:host([href]) .control {
color: ${Ns.LinkText};
border-color: ${Ns.LinkText};
}
:host([href]) .control:hover,
:host([href]) .control:${No} {
forced-color-adjust: none;
box-shadow: inset 0 0 0 calc((${qn.Han} * 1px)) ${Ns.LinkText};
}
::slotted([slot="image"]),
::slotted([slot="start"]),
::slotted([slot="end"]) {
color: ${Ns.ButtonText};
fill: currentcolor;
}
`));function JD(){return eh.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="7" height="30" viewBox="0 0 7 30" fill="none">
<path fill-rule="evenodd" clip-rule="evenodd" d="M7.0003 0H3.5C1.567 0 0 1.567 0 3.5V26.5C0 28.433 1.567 30 3.5 30H7.0003V0Z" fill="#0078D4"></path>
</svg>`}function QD(){return eh.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="15" height="30" viewBox="0 0 15 30" fill="none">
<path fill-rule="evenodd" clip-rule:"evenodd"="" d="M0,30h0.6c1,0,1.9-0.4,2.5-1.1L14,17.4c1.3-1.4,1.3-3.5,0-4.8L3.1,1.1C2.5,0.4,1.5,0,0.6,0H0V30z" fill="#0078D4"></path>
</svg>`}function e_(){return eh.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16" fill="none">
<path d="M10.3587 12.666L10.1649 13.505C10.0161 14.1472 9.46754 14.6123 8.81901 14.662L8.70361 14.6664H7.2958C6.63618 14.6664 6.05901 14.2365 5.86452 13.6155L5.83424 13.5039L5.64067 12.666H10.3587ZM8.00001 1.33398C10.6694 1.33398 12.8333 3.49794 12.8333 6.16732C12.8333 7.59166 12.2096 8.8962 10.9897 10.0611C10.9662 10.0836 10.9498 10.1125 10.9425 10.1441L10.5907 11.666H5.40934L5.05868 10.1443C5.05135 10.1125 5.0349 10.0837 5.01135 10.0611C3.79078 8.8962 3.16667 7.59166 3.16667 6.16732C3.16667 3.49794 5.33063 1.33398 8.00001 1.33398Z" fill="#E8AA00"></path>
</svg>`}function t_(){return eh.Z.getTrustedHTML`
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16" fill="none">
<path d="M7.6055 0H0V7.6055H7.6055V0Z" fill="#F26522"/>
<path d="M15.9998 0H8.39429V7.6055H15.9998V0Z" fill="#8DC63F"/>
<path d="M7.60526 8.39447H-0.000244141V16H7.60526V8.39447Z" fill="#00AEEF"/>
<path d="M15.9998 8.39447H8.39429V16H15.9998V8.39447Z" fill="#FFC20E"/>
</svg>`}function i_(){return eh.Z.getTrustedHTML`<svg
width="4"
height="18"
viewBox="0 0 4 18"
fill="none"
aria-hidden="true"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M0 3C0 1.34315 1.34315 0 3 0H4V18H3C1.34315 18 0 16.6569 0 15V3Z"
fill="#036AC4"
></path>
</svg>`}function n_(){return eh.Z.getTrustedHTML`<svg
width="8"
height="18"
viewBox="0 0 8 18"
fill="none"
aria-hidden="true"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M2.73963 16.6933C2.18051 17.511 1.25378 18 0.263187 18H-1.19209e-07V0H0.263187C1.25378 0 2.18051 0.488995 2.73963 1.30671L6.84219 7.30671C7.54027 8.32765 7.54027 9.67235 6.84219 10.6933L2.73963 16.6933Z"
fill="#036AC4"
></path>
</svg>`}const o_=$n`
<template>
<div class="divCommissionValue">
<div>${i_()}</div>
<div class="pcbSpanCommissionValueSmall">
${e=>e.cashback.cashbackAmount.currency}${e=>e.cashback.cashbackAmount.price}
</div>
<div aria-hidden="true">${n_()}</div>
</div>
</template>
`,r_=$n`
<div class="privacy-message-content ${e=>e.isNotification?"notification-privacy":""}">
<span class="txtSmall">${e=>e.localString.cbPrivacyMessageBeforeRewardsLink}</span>
<fluent-anchor
appearance="hypertext"
class="hypertext"
href="#"
@click="${e=>e.navigateToMicrosoftRewards()}"
>
${e=>e.localString.microsoftRewards}
</fluent-anchor>
<span class="txtSmall">${e=>e.localString.cbPrivacyMessageAfterRewardsLink}</span>
<fluent-anchor
appearance="hypertext"
class="hypertext"
href="#"
@click="${e=>e.navigateToTermsStatementFlyout()}"
>
${e=>e.localString.cbPrivacyMessageTerm}
</fluent-anchor>
<span class="txtSmall">${e=>e.localString.cbPrivacyMessageAfterTerm}</span>
<fluent-anchor
appearance="hypertext"
class="hypertext"
href="#"
@click="${e=>e.navigateToPrivacyCookiesStatement()}"
>
${e=>e.localString.cbPrivacyMessagePrivacyCookies}
</fluent-anchor>
</div>
`,a_=$n`
<div class="offer-details-content">
<span>Cash back categories and exclusions may apply. </span>
<fluent-anchor
appearance="hypertext"
class="hypertext"
href="#"
@click=${e=>e.openPane("offerDetails",!0)}
>
Offer details
</fluent-anchor>
</div>
`,s_=$n`
<div class="offer-details-content">
<span>Complete a purchase to receive cash back within a week. </span>
<fluent-anchor
appearance="hypertext"
class="hypertext"
href="#"
@click=${e=>e.openPane("offerDetails",!0)}
>
Offer details
</fluent-anchor>
</div>
`,l_=($n`
<fluent-button
class="icSeeMoreOffersButton asLink neutral"
@click=${e=>e.onCashbackButtonClickActivation()}
appearance="neutral"
>
${e=>e.localString.gcSeeCashbackDeals}
</fluent-button>
`,$n`
<svg
xmlns="http://www.w3.org/2000/svg"
class="cashback-icon"
width="24"
height="19"
viewBox="0 0 16 16"
fill="none"
>
<path
d="M8 2C11.3137 2 14 4.68629 14 8C14 11.3137 11.3137 14 8 14C4.68629 14 2 11.3137 2 8C2 4.68629 4.68629 2 8 2ZM10.1203 6.16398L7.24953 9.04242L5.85355 7.64645C5.65829 7.45118 5.34171 7.45118 5.14645 7.64645C4.95118 7.84171 4.95118 8.15829 5.14645 8.35355L6.89645 10.1036C7.09189 10.299 7.40884 10.2988 7.60403 10.1031L10.8283 6.87014C11.0233 6.67462 11.0229 6.35804 10.8274 6.16304C10.6319 5.96803 10.3153 5.96846 10.1203 6.16398Z"
fill="#138757"
/>
</svg>
`),c_=($n` <span class="cashback-ads-icon"> Ad </span> `,$n`
<fluent-progress-ring
class="progressRing">
</fluent-progress-ring>
`),d_=$n`
<fluent-button
appearance="${e=>e.getActivateButtonAppearance()}"
class="activated-cashback-btn"
@click=${e=>e.onCashbackButtonClickActivation()}>
<span class="align-icon-with-text ${e=>e.getActivateButtonClasses()}">
${Wr((e=>e.isCashbackActivated()),l_)}
${Wr((e=>e.getCashBackState()===Cg.VS.Activating),c_)}
${e=>e.getActivateButtonTextBaseOnScenario()}
</span>
</fluent-button>
`,u_=$n`
<div class="align-icon-with-text" style="gap: 4px;">
${(new tg).getErrorIcon()}
<span>
${e=>e.getCashBackStateError()}
</span>
</div>
`,h_=$n`
${Wr((e=>e.getCashBackStateError()),u_)}
`,p_=$n`
<template>
<a part="control" href="#" class="aCashbackCardWrapperPane control isLast activatedCardWrapper">
<div class="divProductImageContainer productImgContainer" slot="image">
<img id="productImage" src="${e=>e.getCashbackImageUrl()}" aria-label="${e=>e.cashback.cashbackProductTitle}" class="imgProduct activatedImgProduct" aria-hidden="true" />
<div class="divProductImageAlpha imgAlpha"></div>
</div>
<div class="divContent" part="divContent">
<div class="favIconRow">
${Wr((e=>e.cashback.cashbackType===Cg.hB.SPBorPPCashback),$n`
<span class="txtDescription txtDescriptionElse" title="${e=>e.cashback.cashbackProductTitle}">${e=>e.cashback.cashbackProductTitle}</span>
`)}
${Wr((e=>e.cashback.cashbackType===Cg.hB.PCBStorewide),$n`
<img id="imgMerchantIcon" class="img-retailer-icon" slot="icon" aria-hidden="true" src="${e=>e.getRetailerImageUrl()}" />
<div class="cashbackStr">${e=>e.localString.pcbStorewideCashback}</div>
`)}
</div>
<div class="divTextContent" part="divTextContent">
<div class="divTopAnnotation">
<msft-attribution class="divAttribution" part="divAttribution">
<div class="priceDiv">
<div class="divCommissionValue">
<div>${i_()}</div>
<div class="pcbSpanCommissionValueSmall">
${e=>e.cashback.cashbackAmount.currency}${e=>e.cashback.cashbackAmount.price}
</div>
<div aria-hidden="true">${n_()}</div>
</div>
${Wr((e=>e.cashback.cashbackType===Cg.hB.SPBorPPCashback),$n`
<div class="cashbackStr">${e=>e.localString.cbFeatureName}</div>
`)}
${Wr((e=>e.cashback.cashbackType===Cg.hB.PCBStorewide),$n`
<div class="cashbackStr">${e=>e.localString.pcbCommissionStoreWideOffTextOnly} ${e=>e.cashback.cashbackAmount.currency}${e=>e.cashback.minPurchaseValue}</div>
`)}
</div>
</msft-attribution>
</div>
<div class="divPriceInfo" part="divPriceInfo">
<slot name="expireTime" class="endsIn">${e=>e.localString.gcEndsIn}</slot>
<span class="txtExpireTime" name="end">${e=>e.getOfferExpireTime()}</span>
</div>
</div>
</div>
</a>
</template>
`,g_=$n`
<template>
<div id="divCashBackPopup">
<div class="txtMedium" id="divCashBackContent">
<div id="divWrapperPcb">
<div id="divContentPcb">
<div id="divInfoPcb">
<div id="txtTitlePcb" aria-label="${e=>e.cashback.cashbackProductTitle}">
${e=>e.localString.cbFeatureName}
</div>
<div class="divCommissionValue" aria-hidden="true">
<div class="imgCBTag" aria-hidden="true" style="float: left; margin-right: -1px; height: 30px;">
<svg xmlns="http://www.w3.org/2000/svg" width="7" height="30" viewBox="0 0 7 30" fill="none">
<path fill-rule="evenodd" clip-rule="evenodd" d="M7.0003 0H3.5C1.567 0 0 1.567 0 3.5V26.5C0 28.433 1.567 30 3.5 30H7.0003V0Z" fill="#0078D4"></path>
</svg>
</div>
<span class="spanCommissionValueLarge" style="padding-left: 1px;">
<div style="display: inline-flex; justify-content: center;">
<span class="splitPrice">${e=>e.cashback.cashbackAmount.currency}</span>
<span>${e=>e.cashback.cashbackAmount.price}</span>
<span class="splitPrice">00</span></div>
</span>
<div class="imgCBTag" aria-hidden="true" style="float: left; height: 30px;">
<svg xmlns="http://www.w3.org/2000/svg" width="15" height="30" viewBox="0 0 15 30" fill="none">
<path fill-rule="evenodd" clip-rule:"evenodd"="" d="M0,30h0.6c1,0,1.9-0.4,2.5-1.1L14,17.4c1.3-1.4,1.3-3.5,0-4.8L3.1,1.1C2.5,0.4,1.5,0,0.6,0H0V30z" fill="#0078D4"></path>
</svg>
</div>
</div>
<div id="divForYouPcb">
<div id="txtForYouPcb">${e=>e.localString.forYou}</div>
</div>
</div>
<div class="divProductImageContainer" slot="image" style="width: 88px; height: 88px; border-radius: 8px; margin-left: auto; margin-bottom: auto;">
<img id="productImage" src="${e=>e.getCashbackImageUrl()}"
aria-label="${e=>e.cashback.cashbackProductTitle}"
class="imgProduct" aria-hidden="true"
style="height: 100%; width: 100%; object-fit: contain; max-width: 78px; max-height: 78px;">
<div class="divProductImageAlpha" style="width: 88px; height: 88px;"></div>
</div>
</div>
<div id="dividerPcb">
</div>
${Wr((e=>e.hasExpireTime()),$n`
<div id="divExpirationStringPcb">
This
<div aria-hidden="true" class="microsoftLogo">
<svg version="1.1" id="MS-symbol" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 215.25 216" style="enable-background:new 0 0 215.25 216;" xml:space="preserve">
<style type="text/css">
.st0 {
fill: #F25022;
}
.st1 {
fill: #7FBA00;
}
.st2 {
fill: #00A4EF;
}
.st3 {
fill: #FFB900;
}
</style>
<g>
<rect x="72" y="72" class="st0" width="34.22" height="34.22"></rect>
<rect x="109.77" y="72" class="st1" width="34.22" height="34.22"></rect>
<rect x="72" y="109.77" class="st2" width="34.22" height="34.22"></rect>
<rect x="109.77" y="109.77" class="st3" width="34.22" height="34.22"></rect>
</g>
</svg>
</div>
Offer ends in
<span class="pcb-ends-in">
${e=>e.getOfferExpireTime()}
</span>
</div>
`)}
${h_}
${d_}
</div>
</div>
</div>
</template>
`,f_=$n`
<template>
<div class="pcb-storewide-block">
<div>
<div class="pcb-storewide-block-title">
<div>
${o_}
</div>
<div>
${e=>e.localString.gcbWhenYouSpend}
</div>
</div>
<div class="pcb-storewide-block-title">
${e=>e.cashback.cashbackAmount.currency}${e=>e.cashback.minPurchaseValue}
${e=>e.localString.gcbAt} ${e=>e.getMerchantFullName()}
</div>
</div>
<div class="pcb-storewide-block-subtext">
<div class="pcb-storewide-offer-ends-in">
${t_()}
<span>
${e=>e.localString.gcbThisOfferEndsIn}
</span>
<span class="pcb-ends-in">
${e=>null==e?void 0:e.getOfferExpireTime()}
</span>
</div>
</div>
<fluent-button
appearance="${e=>e.getActivateButtonAppearance()}"
@click=${e=>e.onCashbackButtonClickActivation()}>
<div class="align-icon-with-text">
${Wr((e=>e.isCashbackActivated()),l_)}
<span>${e=>e.getActivateButtonTextBaseOnScenario()}</span>
</div>
</fluent-button>
${Wr((e=>e.showPrivacyMessage()),$n`
<div>
${r_}
</div>
`)}
</div>
</template>
`,m_=$n`
<template>
<div class="txtMedium" id="divCashBackContent">
<div style="display: flex; flex-direction: column;">
<div id="txtTitlePcb">${e=>e.localString.cbFeatureName}</div>
<div class="divCommissionValue" style="margin-top: 8px; display: inline-flex; align-self: center;">
<div class="imgCBTag cashback-badge-before" aria-hidden="true">
${JD()}
</div>
<span class="spanCommissionValueLarge">${e=>e.cashback.cashbackAmount.price}%</span>
<div class="imgCBTag cashback-badge-after" aria-hidden="true">
${QD()}
</div>
</div>
<div id="divMinPurchasePcb" style="font-size: 12px; line-height: 16px; margin-top: 4px;">Minimum ${e=>e.cashback.cashbackAmount.currency}${e=>e.cashback.minPurchaseValue} purchase</div>
<div id="dividerPcb" style="margin-top: 10px; margin-left: 10px; margin-right: 10px; width: auto;"></div>
<div id="divExpirationStringPcb" style="align-self: center;">This
${t_()}
${e=>e.localString.gcbThisOfferEndsIn} <span class="pcb-ends-in">${e=>e.getOfferExpireTime()}</span></div>
<div id="divEnabledPcb" class="pcbButtonAddressbar">
<div slot="start" aria-hidden="true" style="height: 20px;"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 20 20" fill="none">
<path d="M10 0C15.5228 0 20 4.47715 20 10C20 15.5228 15.5228 20 10 20C4.47715 20 0 15.5228 0 10C0 4.47715 4.47715 0 10 0ZM13.2197 6.96967L8.75 11.4393L6.78033 9.46967C6.48744 9.17678 6.01256 9.17678 5.71967 9.46967C5.42678 9.76256 5.42678 10.2374 5.71967 10.5303L8.21967 13.0303C8.51256 13.3232 8.98744 13.3232 9.28033 13.0303L14.2803 8.03033C14.5732 7.73744 14.5732 7.26256 14.2803 6.96967C13.9874 6.67678 13.5126 6.67678 13.2197 6.96967Z" fill="#107C10"></path>
</svg></div><span style="font-size: 14px;">${e=>e.localString.pcbActivatedButton}</span>
</div>
</div>
</div>
</template>
`,v_=$n`
<template>
<div class="spb-notification">
<div class="spb-notification-block">
<div>
<img
@click=${e=>e.onCashbackButtonClickActivation()}
src="${e=>e.getCashbackImageUrl()}"
aria-label="${e=>e.cashback.cashbackProductTitle}"
class="spb-notification-image"/>
</div>
<div class="spb-item-description">
<div class="spb-block-title" @click=${e=>e.onCashbackButtonClickActivation()}>
<div>
${o_}
</div>
<div>
${e=>e.localString.cbFeatureName}
</div>
<div>
<img src="https://www.bing.com/api/shopping/v1/ux/images/priceComparison/adSlug.png"
aria-label="Ad"
class="adsSlugImg"/>
</div>
</div>
<div class="spb-cashback-title-block" @click=${e=>e.onCashbackButtonClickActivation()}>
<span title="${e=>e.cashback.cashbackProductTitle}" class="spb-cashback-title">
${e=>e.cashback.cashbackProductTitle}
</span>
</div>
<span class="spb-view-more-offers" @click=${e=>e.openPane("viewMoreOffers")}>
${e=>e.localString.gcbViewMoreOffers}
</span>
</div>
</div>
<div style="width:100%; margin-top: 16px;">
<fluent-button
appearance="accent"
class="spb-activate-btn"
@click=${e=>e.onCashbackButtonClickActivation()}>
<span class="${e=>e.getActivateButtonClasses()}">
${e=>e.getActivateButtonTextBaseOnScenario()}
</span>
</fluent-button>
</div>
${Wr((e=>e.showPrivacyMessage()),r_)}
</div>
</template>
`,y_=$n`
<template>
<fast-card @click=${e=>e.onCashbackButtonClickActivation()} style="background-color: var(--fill-color)">
<div class="icGridAndImageContainerClassName">
<div class="icImageContainerWrapper">
<img src="${e=>e.cashback.imageUrl}" />
</div>
<div class="gcTextContainer">
<div class="icPriceContainer">
<p class="icPriceContainerMainPrice">
${e=>e.productPriceAfterCashback()}
</p>
<p class="icPriceContainerCrossedPrice">
${e=>{var t;return null===(t=e.cashback.productPrice)||void 0===t?void 0:t.currency}}${e=>{var t;return null===(t=e.cashback.productPrice)||void 0===t?void 0:t.price}}
</p>
</div>
<div class="recommended-badge">
<p class="icAfterText">After</p>
<div class="gcCouponContainer">
<div title=${e=>{var t;return null===(t=e.cashback.cashbackAmount)||void 0===t?void 0:t.price}}>
<p>
${e=>{var t;return null===(t=e.cashback.cashbackAmount)||void 0===t?void 0:t.currency}}${e=>{var t;return null===(t=e.cashback.cashbackAmount)||void 0===t?void 0:t.price}}
back
</p>
</div>
<div class="cashbackAfterText">${eh.Z.getTrustedHTML`<svg
width="14"
height="20"
viewBox="0 0 14 30"
fill="none"
xmlns="http://www.w3.org/2000/svg"
>
<path fill-rule="evenodd" clip-rule:"evenodd"="" d="M0,30h0.6c1,0,1.9-0.4,2.5-1.1L14,17.4c1.3-1.4,1.3-3.5,0-4.8L3.1,1.1C2.5,0.4,1.5,0,0.6,0H0V30z" fill="#0078D4"></path>
</svg>`}</div>
</div>
</div>
<p title="${e=>e.cashback.cashbackProductTitle}" class="icDescriptionTextGridCard">
${e=>e.cashback.cashbackProductTitle}
</p>
</div>
</div>
</fast-card>
</template>
`,C_=$n`
<template>
<div id="gcMainRootSpbCard">
<div id="gcMainBodySpbCard" style="padding: 0px 16px; display: flex; flex-direction: column; margin: 0px auto;">
<div id="gcMainContentSpbCard">
<div class="icPercentOff" style="background: rgba(0, 0, 0, 0.7); background-blend-mode: luminosity; backdrop-filter: blur(2px); border-radius: 6px; width: fit-content; padding: 0px 6px; display: flex; gap: 4px; justify-content: center; align-items: center; height: 18px; box-sizing: border-box; text-transform: uppercase;">
<img src="https://www.bing.com/api/shopping/v1/ux/images/common/whiteCoupon.svg" width="12" height="12" style="object-fit: contain;" />
<p style="font-weight: 400; font-size: 12px; line-height: 12px; margin: 0px 0px 2px; color: rgb(255, 255, 255);">
${e=>e.cashbackOffPrice()} ${e=>e.localString.gcOff}
</p>
</div>
<div class="icTextAndImageContainer">
<div class="icImageContainerWrapper" title="${e=>e.cashback.cashbackProductTitle}" style="flex: 1 1 0%;">
<img src="${e=>e.getCashbackImageUrl()}" width="116" height="116" class="icImageContainer" style="object-fit: contain;" />
</div>
<div class="divider"></div>
<div class="icTextContainer">
<div class="adsIconContainer">
<p class="adsIcon">Ad</p>
<p style="font-weight: 700; font-size: 12px; line-height: 16px; display: flex; align-items: center; letter-spacing: -0.01em; margin: 0px; text-transform: unset;">
${e=>e.localString.gcTopDeal}
</p>
</div>
<p class="icCashbackText" style="font-size: 24px; padding: 5px 0px;">
${e=>e.localString.gcGetDeal}
<span>${e=>e.cashback.cashbackAmount.currency}${e=>e.cashback.cashbackAmount.price}</span>
${e=>e.localString.cbFeatureName}
</p>
<p title="${e=>e.cashback.cashbackProductTitle}" class="icDescriptionText" style="margin: 2px 0px 0px; color: rgb(26, 26, 26); font-weight: 400; font-size: 12px; line-height: 16px; overflow: hidden; text-overflow: ellipsis; -webkit-line-clamp: 2; -webkit-box-orient: vertical; white-space: normal; display: -webkit-box !important;">
${e=>e.cashback.cashbackProductTitle}
</p>
</div>
</div>
<div id="gcActivatedContainer" style="width: 100%;">
<div style="width: 100%; border-top: 1px solid rgb(235, 235, 235); padding-right: 16px; padding-left: 16px; margin-bottom: 6px;"></div>
${h_}
${d_}
</div>
<fluent-button class="icSeeMoreOffersButton asLink neutral" @click=${e=>e.openPane("seeMore")}
current-value=""
appearance="neutral">
${e=>e.localString.gcSeeCashbackDeals}
</fluent-button>
</div>
<div>
${Wr((e=>e.showPrivacyMessage()),r_)}
</div>
</div>
</div>
</template
`,b_=$n`
<template>
<div title="${e=>e.category}" class="category-container">
<div class="divCommissionValue divCommissionWrapper">
<div class="imgCBTag cbtagBefore" aria-hidden="true">${eh.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="4.5" height="20" viewBox="0 0 4.5 30" fill="none">
<path fill-rule="evenodd" clip-rule="evenodd" d="M7.0003 0H3.5C1.567 0 0 1.567 0 3.5V26.5C0 28.433 1.567 30 3.5 30H7.0003V0Z" fill="#0078D4"></path>
</svg>`}</div>
<span class="spanCommissionValueSmall pl-2">${e=>e.commissionValue}${e=>e.commissionType}</span>
<div class="imgCBTag cbtagAfter" aria-hidden="true">${eh.Z.getTrustedHTML`<svg xmlns="http://www.w3.org/2000/svg" width="10" height="20" viewBox="0 0 15 30" fill="none">
<path fill-rule="evenodd" clip-rule:"evenodd"="" d="M0,30h0.6c1,0,1.9-0.4,2.5-1.1L14,17.4c1.3-1.4,1.3-3.5,0-4.8L3.1,1.1C2.5,0.4,1.5,0,0.6,0H0V30z" fill="#0078D4"></path>
</svg>`}</div>
</div>
<div class="txtXSmall category-detail" id="divCatgoryDetail0">${e=>e.category}</div>
</div>
</template>
`,S_=$n`
<template>
<div
class="txtMedium"
id="divCashBackContent"
@click=${e=>e.onSlotClick()}
style="background-color: var(--fill-color);"
>
${Wr((e=>e.cashback.is3xIncentive),$n`
<div class="coloredBanner" style="${e=>e.get3XIncentiveStyle()}">
<p class="${e=>e.get3XIncentiveTextClass()}">Microsoft Shopping Exclusive</p>
<p class="${e=>e.get3XIncentiveTextClass()}">3x Cash Back</p>
</div>
<div id="divCashBackTitle" class="cashback-title-container" style="display: inline">
<h2 id="h2RebatesTitle3x">
${e=>e.localString.StorewideCashbackTitleBefore}
<span id="divCommissionValueStriked">
${e=>e.getDividedCashbackAmount()+"%"}
</span>
<div class="divCommissionValue">
<div class="imgCBTag cashback-badge-before" aria-hidden="true">
${JD()}
</div>
<span class="spanCommissionValueLarge">${e=>e.cashback.cashbackAmount.price}%</span>
<div class="imgCBTag cashback-badge-after" aria-hidden="true">
${QD()}
</div>
</div>
${e=>e.localString.StorewideCashbackTitleAfter}
</h2>
</div>
`)}
${Wr((e=>!e.cashback.is3xIncentive),$n`
<div id="divCashBackTitle" class="cashback-title-container">
<h2 id="h2RebatesTitle">
${e=>e.localString.StorewideCashbackTitleBefore}
<div class="divCommissionValue">
<div class="imgCBTag cashback-badge-before" aria-hidden="true">
${JD()}
</div>
<span class="spanCommissionValueLarge">${e=>e.cashback.cashbackAmount.price}%</span>
<div class="imgCBTag cashback-badge-after" aria-hidden="true">
${QD()}
</div>
</div>
${e=>e.localString.StorewideCashbackTitleAfter}
</h2>
</div>
`)}
<div id="divMerchantInfo">
<p id="txtMerchantInfo">${e=>null==e?void 0:e.getMerchantFullName()}</p>
<div id="divMerchantIcon">
<img
id="imgMerchantIcon"
class="img-retailer-icon"
slot="icon"
aria-hidden="true"
src="${e=>e.getRetailerImageUrl()}"
/>
</div>
</div>
${Wr((e=>e.cashback.is3xIncentive),$n` <p id="limitedOffer3xincentive">Offer expires today!</p> `)}
${Wr((e=>e.cashback.isBlossom),$n`
<div id="blossomBox" style="width: calc(100% - 16px);${e=>e.getBlossomStyle()}"">
<p style="margin: 0px;">
<span style="white-space: nowrap;">
<span>You're also getting </span>
<strong style="white-space: nowrap;">$5 bonus cash back </strong><span>for </span>
</span>
<br>
<span style="white-space: nowrap;">
<span>completing a purchase. </span>
<a href="/history" target="_blank" rel="noopener noreferrer" class="blossomLink ${e=>e.getDarkLinkStyles()}" @click=${e=>e.navigateToRebateHistory()}>Track cash back</a>
</span>
</p>
</div>
`)}
<div class="separator"></div>
${s_}
${h_} ${d_}
${Wr((e=>!e.isNotification),$n`
<div id="aOfferDetails" class="action" style="margin-top: 12px; margin-bottom: 12px;">
<div aria-hidden="true" class="d-inline-block">${e_()}</div>
<div id="cashBackInfoText">
<p class="txtSmall">${e=>e.localString.cbReceiveCashBackTitle}</p>
</div>
</div>
`)}
${Wr((e=>e.showPrivacyMessage()),r_)}
</div>
${Wr((e=>!e.isNotification),$n` <div class="offer-details-block">
<fluent-accordion class="show-more-storewide">
<fluent-accordion-item class="show-more-btn">
<div slot="heading">
<div>${e=>e.localString.cbOfferDetailsButtonTitle}</div>
</div>
<div id="divCashBackCategoriesPopup" style="padding: 16px; margin-top: 12px; display: flex;">
${Sl((e=>e.cashback.cashbackCategories),b_)}
<div class="storewide-cashback-exclusion-text">
${e=>e.localString.cashbackExclusionsText}
</div>
</div>
</fluent-accordion-item>
</fluent-accordion>
</div>`)}
</template>
`,x_=$n`
<template>
<div
class="txtMedium"
id="divCashBackContent"
@click=${e=>e.onSlotClick()}
style="background-color: var(--fill-color);"
>
${Wr((e=>e.cashback.is3xIncentive),$n`
<div class="coloredBanner" style="${e=>e.get3XIncentiveStyle()}">
<p class="${e=>e.get3XIncentiveTextClass()}">Microsoft Shopping Exclusive</p>
<p class="${e=>e.get3XIncentiveTextClass()}">3x Cash Back</p>
</div>
<div id="divCashBackTitle" class="cashback-title-container" style="display: inline">
<h2 id="h2RebatesTitle3x">
<span id="divCommissionValueStriked">${e=>e.getDividedCashbackAmount()+"%"} </span>
<div class="divCommissionValue">
<div class="imgCBTag cashback-badge-before" aria-hidden="true">
${JD()}
</div>
<span class="spanCommissionValueLarge">
1-${e=>e.cashback.cashbackAmount.price}%
</span>
<div class="imgCBTag cashback-badge-after" aria-hidden="true">
${QD()}
</div>
</div>
${e=>e.localString.StorewideCashbackTitleAfter}
</h2>
</div>
`)}
${Wr((e=>!e.cashback.is3xIncentive),$n`
<div id="divCashBackTitle" class="cashback-title-container">
<h2 id="h2RebatesTitle">
<div class="divCommissionValue">
<div class="imgCBTag cashback-badge-before" aria-hidden="true">
${JD()}
</div>
<span class="spanCommissionValueLarge">
1-${e=>e.cashback.cashbackAmount.price}%
</span>
<div class="imgCBTag cashback-badge-after" aria-hidden="true">
${QD()}
</div>
</div>
${e=>e.localString.StorewideCashbackTitleAfter}
</h2>
</div>
`)}
<div id="divMerchantInfo">
<p id="txtMerchantInfo">${e=>null==e?void 0:e.getMerchantFullName()}</p>
<div id="divMerchantIcon">
<img
id="imgMerchantIcon"
class="img-retailer-icon"
slot="icon"
aria-hidden="true"
src="${e=>e.getRetailerImageUrl()}"
/>
</div>
</div>
${Wr((e=>e.cashback.is3xIncentive),$n` <p id="limitedOffer3xincentive">Offer expires today!</p> `)}
${Wr((e=>e.cashback.isBlossom),$n`
<div id="blossomBox" style="width: calc(100% - 16px);${e=>e.getBlossomStyle()}"">
<p style="margin: 0px;">
<span style="white-space: nowrap;">
<span>You're also getting </span>
<strong style="white-space: nowrap;">$5 bonus cash back </strong><span>for </span>
</span>
<br>
<span style="white-space: nowrap;">
<span>completing a purchase. </span>
<a href="/history" target="_blank" rel="noopener noreferrer" class="blossomLink ${e=>e.getDarkLinkStyles()}" @click=${e=>e.navigateToRebateHistory()}>Track cash back</a>
</span>
</p>
</div>
`)}
<div class="separator"></div>
${a_}
${h_} ${d_}
${Wr((e=>!e.isNotification),$n`
<div id="aOfferDetails" class="action" style="margin-top: 12px; margin-bottom: 12px;">
<div aria-hidden="true" class="d-inline-block">${e_()}</div>
<div id="cashBackInfoText">
<p class="txtSmall">${e=>e.localString.cbReceiveCashBackTitle}</p>
</div>
</div>
`)}
${Wr((e=>e.showPrivacyMessage()),r_)}
</div>
${Wr((e=>!e.isNotification),$n` <div class="offer-details-block">
<fluent-accordion class="show-more-storewide">
<fluent-accordion-item class="show-more-btn">
<div slot="heading">
<div>${e=>e.localString.cbOfferDetailsButtonTitle}</div>
</div>
<div id="divCashBackCategoriesPopup" style="padding: 16px; margin-top: 12px; display: flex;">
${Sl((e=>e.cashback.cashbackCategories),b_)}
<div class="storewide-cashback-exclusion-text">
${e=>e.localString.cashbackExclusionsText}
</div>
</div>
</fluent-accordion-item>
</fluent-accordion>
</div>`)}
</template>
`,T_=$n`
<template>
<div class="txtMedium" id="divCashBackContent" @click=${e=>e.onSlotClick()} style="background-color: var(--fill-color);">
${Wr((e=>e.cashback.is3xIncentive),$n`
<div class="coloredBanner" style="${e=>e.get3XIncentiveStyle()}">
<p class="${e=>e.get3XIncentiveTextClass()}">Microsoft Shopping Exclusive</p>
<p class="${e=>e.get3XIncentiveTextClass()}">3x Cash Back</p>
</div>
<div id="divCashBackTitle" class="cashback-title-container" style="display: inline">
<h2 id="h2RebatesTitle3x">
${e=>e.localString.StorewideCashbackTitleBefore}
<span id="divCommissionValueStriked">
${e=>e.getDividedCashbackAmount()+"%"}
</span>
<div class="divCommissionValue">
<div class="imgCBTag cashback-badge-before" aria-hidden="true">
${JD()}
</div>
<span class="spanCommissionValueLarge">${e=>e.cashback.cashbackAmount.price}%</span>
<div class="imgCBTag cashback-badge-after" aria-hidden="true">
${QD()}
</div>
</div>
${e=>e.localString.StorewideCashbackTitleAfter}
</h2>
</div>
`)}
${Wr((e=>!e.cashback.is3xIncentive),$n`
<div id="divCashBackTitle" class="cashback-title-container">
<h2 id="h2RebatesTitle">
${e=>e.localString.StorewideCashbackTitleBefore}
<div class="divCommissionValue">
<div class="imgCBTag cashback-badge-before" aria-hidden="true">
${JD()}
</div>
<span class="spanCommissionValueLarge">${e=>e.cashback.cashbackAmount.price}%</span>
<div class="imgCBTag cashback-badge-after" aria-hidden="true">
${QD()}
</div>
</div>
${e=>e.localString.StorewideCashbackTitleAfter}
</h2>
</div>
`)}
<div id="divMerchantInfo">
<p id="txtMerchantInfo">${e=>null==e?void 0:e.getMerchantFullName()}</p>
<div id="divMerchantIcon">
<img id="imgMerchantIcon" class="img-retailer-icon" slot="icon" aria-hidden="true" src="${e=>e.getRetailerImageUrl()}" />
</div>
</div>
${Wr((e=>e.cashback.is3xIncentive),$n`
<p id="limitedOffer3xincentive">Offer expires today!</p>
`)}
${Wr((e=>e.cashback.isBlossom),$n`
<div id="blossomBox" style="width: calc(100% - 16px);${e=>e.getBlossomStyle()}"">
<p style="margin: 0px;">
<span style="white-space: nowrap;">
<span>You're also getting </span>
<strong style="white-space: nowrap;">$5 bonus cash back </strong><span>for </span>
</span>
<br>
<span style="white-space: nowrap;">
<span>completing a purchase. </span>
<a href="/history" target="_blank" rel="noopener noreferrer" class="blossomLink ${e=>e.getDarkLinkStyles()}" @click=${e=>e.navigateToRebateHistory()}>Track cash back</a>
</span>
</p>
</div>
`)}
${h_}
${d_}
${Wr((e=>!e.isNotification),$n`
<div id="aOfferDetails" class="action" style="margin-top: 12px; margin-bottom: 12px;">
<div aria-hidden="true" class="d-inline-block">${e_()}</div>
<div id="cashBackInfoText">
<p class="txtSmall">${e=>e.localString.cbReceiveCashBackTitle}</p>
</div>
</div>
`)}
${Wr((e=>e.showPrivacyMessage()),r_)}
</div>
${Wr((e=>!e.isNotification),$n`
<div class="offer-details-block">
<fluent-accordion class="show-more-storewide">
<fluent-accordion-item class="show-more-btn" expanded=${e=>e.shouldExpandDetails}>
<div slot="heading">
<div>${e=>e.localString.cbOfferDetailsButtonTitle}</div>
</div>
<div id="divCashBackCategoriesPopup" style="padding: 16px; margin-top: 12px; display: flex;">
${Sl((e=>e.cashback.cashbackCategories),b_)}
<div class="storewide-cashback-exclusion-text">
${e=>e.localString.cashbackExclusionsText}
</div>
</div>
</fluent-accordion-item>
</fluent-accordion>
</div>
`)}
</template>
`,w_=$n`
<div id="divCashBackPopup" class="lateralMargin" slot="header-content" style="flex-direction: column;">
<h2 id="h2TurnedOffCb">
<p style="margin: 0px; display: inline-block;">${e=>e.localString.cbTurnedOffTitleMsftCashback}</p><br aria-hidden="true">
<p style="margin: 0px; display: inline-block;">${e=>e.localString.cbTurnedOffDescription}</p>
</h2><span class="txtSmall" id="spanTurnedOffCb">${e=>e.localString.cbTurnedOffMessage}</span>
</div>
`,O_=$n`
<div id="divCashBackPopup" slot="header-content">
<div class="lateralMargin" id="divConfirmationCb">
<p class="txtSmall" style="line-height: 20px; margin-top: 16px;">${e=>e.localString.gcbNotifSubtitle}</p>
<div id="aOfferDetails" class="action" style="margin-top: 4px;">
<fluent-anchor id="aOfferDetailsText" class="lightweight" appearance="lightweight" href="#" style="align-self: center;">${e=>e.localString.cbLearnMore}</fluent-anchor>
</div>
</div>
</div>
`,P_=$n`
<template>
<div id="divCashBackPopup" >
<div class="divPcbNotificationContent" id="divConfirmationCb">
<div id="divConfHeaderPcb" class="lateralMargin">
<div id="divConfTitlePcb">${e=>e.localString.instantcbRefresh}</div>
<div style="display: flex; column-gap: 8px;">
<img src="https://www.bing.com/api/shopping/v1/ux/images/common/mail.png" aria-hidden="true" style="width: 40px; height: 40px;"/>
<div id="divEmailUpdatesPcb">${e=>e.localString.gcConfirmationTextSpb}</div>
</div>
</div>
<fluent-button appearance="accent" @click=${e=>e.navigateToRebateHistory()} class="accent btnPrimarySmallNotification" style="margin-top: 12px;">${e=>e.localString.gcTrackCashback}</fluent-button>
</div>
</div>
</template>
`,A_=$n`
${Wr((e=>"Storewide"===e.viewName),T_)}
${Wr((e=>"StorewideRange"===e.viewName),x_)}
${Wr((e=>"StorewideReceiveAfterPurchaseTitle"===e.viewName),S_)}
${Wr((e=>"ActivatedList"===e.viewName&&!e.isNotification),p_)}
${Wr((e=>"PCBOffer"===e.viewName),g_)}
${Wr((e=>"PCBStorewide"===e.viewName&&e.isNotification),f_)}
${Wr((e=>"PCBStorewideLegacy"===e.viewName&&e.isNotification),m_)}
${Wr((e=>"Recommened"===e.viewName&&!e.isNotification),y_)}
${Wr((e=>"Recommened"===e.viewName&&e.isNotification),C_)}
${Wr((e=>"SPBSearchV2"===e.viewName&&e.isNotification),v_)}
${Wr((e=>"SpbPDPV2"===e.viewName&&e.isNotification),v_)}
${Wr((e=>"SpbPDP"===e.viewName&&!e.isNotification),g_)}
${Wr((e=>"SpbPDP"===e.viewName&&e.isNotification),C_)}
${Wr((e=>"cashbackTurnedOff"===e.viewName&&e.isNotification),w_)}
${Wr((e=>"confirmationPage"===e.viewName&&e.isNotification),O_)}
${Wr((e=>"PCBconfirmationPage"===e.viewName&&e.isNotification),P_)}
`,E_=qD.compose({baseName:"cashback-offer",shadowOptions:{delegatesFocus:!0},styles:XD,template:A_}),k_=dn`
${FD}
`,I_=$n`
<template>
<div class="template-cashback-block">
${Wr((e=>e.showOffersTabs()),$n`
<fluent-tabs>
${()=>$D}
${()=>HD}
${()=>ZD}
</fluent-tabs>
`)}
</div>
</template>
`,D_=class extends BD{}.compose({baseName:"cashback-block",shadowOptions:{delegatesFocus:!0},styles:k_,template:I_}),__=dn`
${XD}
`,N_=$n`
`,R_=class extends qD{}.compose({baseName:"cashback-offer",shadowOptions:{delegatesFocus:!0},styles:__,template:N_});class M_ extends Og.Z{static isExperimentalFlight(){return!1}}var L_=M_,B_=class{getStyles(){return"\n #divRewardsMainContainer {\n width: 90%;\n }\n\n #imgRewardsBag {\n width: 213.34px; \n height: 134px;\n }\n\n #divRewardsTitle {\n font-family: 'Segoe UI Variable Static Display', 'Segoe UI'; \n font-size: 18px; \n font-weight: 600; \n line-height: 24px; \n letter-spacing: 0em;\n display: flex; \n justify-content: center; \n margin-top: -8%;\n }\n\n #pRewardsTitleContent {\n width: 65%;\n }\n\n #spanRewardsTitleMiddle {\n color: #138757;\n }\n\n #hrRewards {\n color: #EBEBEB; \n margin-top: 0;\n }\n\n #divRewardsSubTitle {\n font-family: 'Segoe UI'; \n font-size: 14px; \n line-height: 20px;\n }\n\n #imgRewards {\n vertical-align: middle; \n padding-bottom: 6px;\n width: 28px; \n height: 28px;\n }\n\n #spanRewardsSubTitlePrefix {\n font-weight: 600;\n }\n\n #spanRewardsSubTitleSuffix {\n font-weight: 400;\n }\n "}},F_=class extends Qu{constructor(e,t,i){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),this.flyoutData=t,this.utilities=i.viewModulesUtilities,this.assets=new B_,this.logModule=i.logModule,this.pageHandlerModule=i.pageHandlerModule}GetModuleName(){return r.ModuleNames.POST_PURCHASE_REWARDS}CalculateRanking(){return r.zz.AutoOpen}ShouldRenderModule(){return Promise.resolve(!1)}async renderModule(){return Promise.resolve(null)}populateMainHeader(){}PostProcessing(e,t,i){return Promise.resolve()}};class U_{constructor(){(0,s.Z)(this,"totalRewardsEarned",void 0),(0,s.Z)(this,"pointsEarned",void 0)}static Create(e){const t=new U_;return t.totalRewardsEarned=e?.balance,t.pointsEarned=e?.activity?.p,t}isValidData(){return!(!this.totalRewardsEarned||!this.pointsEarned)}}var H_=U_,$_=o(73765),Z_=class extends F_{constructor(e,t,i){super(e,t,i),(0,s.Z)(this,"postPurchaseRewardsData",void 0),this.flyoutData=t,this.utilities=i.viewModulesUtilities,this.logModule=i.logModule,this.pageHandlerModule=i.pageHandlerModule,this.assets=new B_;const n=this.flyoutData.common.autoOpenParams;if(n){const e=JSON.parse(n);this.postPurchaseRewardsData=new H_,this.postPurchaseRewardsData.pointsEarned=e?.postPurchaseRewardsData?.pointsEarned,this.postPurchaseRewardsData.totalRewardsEarned=e?.postPurchaseRewardsData?.totalRewardsEarned}}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_POST_PURCHASE_REWARDS_NOTIFICATION]}PostProcessingNotification(e,t){const i=this.createNotificationFooter(t);this.flyoutData.common.shopping.appendChild(i)}RenderNotification(){if(!this.postPurchaseRewardsData?.isValidData())return Promise.resolve(null);this.flyoutData.common.shopping.classList.add("noSections"),this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles());const e=(0,Y.Ux)("DIV",{id:"divRewardsMainContainer"}),t=(0,Y.Ux)("IMG",{id:"imgRewardsBag"});t.src="https://www.bing.com/api/shopping/v1/ux/images/autoApply/MS_Rewards_bags.png",e.appendChild(t);const n=(0,Y.Ux)("DIV",{id:"divRewardsTitle"});e.appendChild(n);const o=(0,Y.Ux)("P",{id:"pRewardsTitleContent"}),r=(0,Y.Ux)("SPAN",{id:"spanRewardsTitleMiddle"});r.textContent=this.postPurchaseRewardsData?.pointsEarned+" "+this.flyoutData.strings.postPurchaseRewardsTitleMiddle,n.appendChild(o),(0,T.B7)(o,this.flyoutData.strings.postPurchaseRewardsTitlePrefix,r);const a=(0,Y.Ux)("HR",{id:"hrRewards"});e.appendChild(a);const s=(0,Y.Ux)("DIV",{id:"divRewardsSubTitle"}),l=(0,Y.Ux)("IMG",{id:"imgRewards"});l.src="https://www.bing.com/api/shopping/v1/ux/images/autoApply/MS_Rewards.png",s.appendChild(l);const c=(0,Y.Ux)("SPAN",{id:"spanRewardsSubTitlePrefix"});c.textContent=" "+this.postPurchaseRewardsData?.totalRewardsEarned+" ",s.appendChild(c);const d=(0,Y.Ux)("SPAN",{id:"spanRewardsSubTitleSuffix"});d.textContent=this.flyoutData.strings.postPurchaseRewardsSubtitleSuffix,s.appendChild(d),e.appendChild(s),e.slot="header-content";const u=this.utilities.createNotificationModule(e,this.GetNotificationName(),this),h=new $_.Z(this.flyoutData.common.domain,i.oN.AARewards,location.pathname,i.zy.RewardsNotificationShown);return h.event_metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination,rewardsData:JSON.stringify(this.postPurchaseRewardsData)}),this.logModule.LogInfoEvent(i.R.ShoppingRewards,"Post Purchase Rewards Notification Shown",h),Promise.resolve(u)}ShouldRenderNotification(){return this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_POST_PURCHASE_REWARDS_NOTIFICATION?Promise.resolve(!1):Promise.resolve(!0)}GetNotificationName(){return r.sM.POST_PURCHASE_REWARDS_NOTIFICATION}createNotificationFooter(e){let t;t=(0,Y.Ux)("DIV",{style:"width: calc(100% - 32px); display: grid; grid-template-columns: 60% auto; grid-gap: 10px;"}),t.style.display="flex",t.style.flexDirection="column",t.style.marginTop="12px",t.style.gap="8px",t.classList.add("lateralMargin"),t.id="divNotificationActions",t.slot="actions";const n=(0,Y.lw)(this.utilities);return n.style.width="100%",n.style.marginTop="0px",n.style.fontWeight="400",n.textContent=this.flyoutData.strings.postPurchaseRewardsButtonText,n.addEventListener("click",(async e=>{e.stopPropagation();const t=new W.Z(i.$S.PostPurchaseViewRewards,bp.r.POST_PURCHASE_REWARDS_NOTIFICATION,this.flyoutData.common.domain);t.Metadata=JSON.stringify({popupOriginationEnum:this.flyoutData.common.popupOrigination,rewardsData:JSON.stringify(this.postPurchaseRewardsData)}),this.logModule.LogInfoEvent(i.R.ButtonClick,"View Rewards Button clicked",t),setTimeout((()=>{this.pageHandlerModule.NavigateToUrl("https://rewards.microsoft.com")}))})),t.appendChild(n),t}},V_=class extends Qu{constructor(e,t,i,n){super(),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"cashbackScenarioService",void 0),(0,s.Z)(this,"cashbackLogger",void 0),(0,s.Z)(this,"sectionId","cashbackDashboardSection"),this.assets=new class{getStyles(){return"\n #cashbackDashboardSection {\n padding: 12px 16px 12px 16px;\n }\n "}getDarkModeStyles(){return""}},this.flyoutData=e,this.utilities=t,this.cashbackScenarioService=i,this.cashbackLogger=n}GetModuleName(){return r.ModuleNames.CASHBACK_DASHBOARD}async ShouldRenderModule(){return e.R.isExperimentActive(f.H.CashbackDashboard)?Promise.resolve(!0):Promise.resolve(!1)}async renderModule(){const e=document.createElement("div");e.id=this.sectionId,this.utilities.viewModulesUtilities.applyStyles(e,this.assets.getStyles());const t=kD.getInstance(),i=await t.FetchCashbackTransactions(this.flyoutData,this.utilities.pageHandlerModule,this.utilities.logModule);new xg(this.flyoutData,this.utilities.viewModulesUtilities,this.utilities.pageHandlerModule,i,e,this.cashbackScenarioService,this.cashbackLogger).render();const n=this.CreateModule(e,r.H7.CASHBACK_DASHBOARD,r.ModuleNames.CASHBACK_DASHBOARD,r.$k.CASHBACK,r.SV.BLOCK);return Promise.resolve(n)}populateMainHeader(){}};class G_ extends V.Z{constructor(e,t){super(),(0,s.Z)(this,"ExperimentInfo",void 0),(0,s.Z)(this,"Domain",void 0),(0,s.Z)(this,"FlyoutId",void 0),this.Domain=e,this.ExperimentInfo=JSON.stringify(t)}}var j_=G_,z_=o(84830),W_=class{constructor(e,t,i,n,o,r){(0,s.Z)(this,"EventType",void 0),(0,s.Z)(this,"JsonData",void 0),(0,s.Z)(this,"LogLevel",void 0),(0,s.Z)(this,"Message",void 0),(0,s.Z)(this,"ClientContext",void 0),(0,s.Z)(this,"ImpressionId",void 0),(0,s.Z)(this,"EventTime",void 0),this.LogLevel=e,this.EventType=t,this.JsonData=i,this.Message=n,this.ClientContext=r,this.ImpressionId=o,this.EventTime=(new Date).getTime()}ToString(){return JSON.stringify(this)}},K_=class{LogInfoEvent(e,t,n,o){this.LogClientEvent(i.in.Information,e,t,n,o)}LogErrorEvent(e,t,n,o){this.LogClientEvent(i.in.Error,e,t,n,o)}},q_=class extends K_{constructor(e,t,i){super(),(0,s.Z)(this,"pagehandlerModule",void 0),(0,s.Z)(this,"jsVersion",void 0),(0,s.Z)(this,"appClientInfoIname",void 0),(0,s.Z)(this,"edgeImpressionId",void 0),(0,s.Z)(this,"couponImpressionId",void 0),(0,s.Z)(this,"domainName",void 0),(0,s.Z)(this,"buildVersion",void 0),(0,s.Z)(this,"flyoutId",void 0),(0,s.Z)(this,"channel",void 0),this.jsVersion=t,this.appClientInfoIname=ze.Z.GetClientName(),this.pagehandlerModule=e,this.buildVersion=ze.Z.GetBuildVersion(),this.channel=i}setData(e,t){e===Jl.g.EdgeImpressionId?this.edgeImpressionId=t:e===Jl.g.CouponImpressionId?this.couponImpressionId=t:e===Jl.g.DomainName?this.domainName=t:e===Jl.g.Client?this.appClientInfoIname=t:e===Jl.g.FlyoutId?this.flyoutId=t:e===Jl.g.EdgeChannel&&(this.channel=t)}LogClientEvent(e,t,i,n,o=Jl.g.EdgeImpressionId){this.domainName&&!n.Domain&&(n.Domain=this.domainName);let r="";switch(o){case Jl.g.CouponImpressionId:r=this.couponImpressionId||this.edgeImpressionId;break;case Jl.g.EdgeImpressionId:default:r=this.edgeImpressionId||this.couponImpressionId}this.addFlyoutIDToData(n);const a=new z_.Z(this.appClientInfoIname,this.jsVersion,this.buildVersion,this.pagehandlerModule.enabledServiceFlights,void 0,this.channel),s=new W_(e,t,JSON.stringify(n),i,r,a);this.pagehandlerModule.SendBingTelemetry(s.ToString())}addFlyoutIDToData(e){e instanceof t.Z&&this.flyoutId&&(e.FlyoutId=this.flyoutId),e instanceof W.Z&&this.flyoutId&&(e.FlyoutId=this.flyoutId),e instanceof j_&&this.flyoutId&&(e.FlyoutId=this.flyoutId),e instanceof qp&&this.flyoutId&&(e.FlyoutId=this.flyoutId)}};const Y_=new class{constructor(e){(0,s.Z)(this,"PopupOrigination",void 0),(0,s.Z)(this,"AutoShowFeature",void 0),(0,s.Z)(this,"PwiloType",void 0),(0,s.Z)(this,"ShoppingDataGroup",void 0),(0,s.Z)(this,"enabledServiceFlights",""),(0,s.Z)(this,"pageHandler",void 0),(0,s.Z)(this,"shoppingActions",void 0),(0,s.Z)(this,"shoppingContent",void 0),(0,s.Z)(this,"shoppingEngagement",void 0),(0,s.Z)(this,"shoppingWindowOpenDisposition",void 0),(0,s.Z)(this,"packageTrackingActions",void 0),(0,s.Z)(this,"shoppingCjkScenario",void 0),(0,s.Z)(this,"telemetryFunctionName","sendBingTelemetry"),(0,s.Z)(this,"autoShowList",[u.sR.AUTO_SHOW_LOWER_PRICE_FOUND,u.sR.AUTO_SHOW_REBATES,u.sR.AUTO_SHOW_REBATES_CONFIRMATION,u.sR.AUTO_SHOW_REBATES_ORGANIC,u.sR.AUTO_SHOW_PRICE_HISTORY,u.sR.AUTO_SHOW_REBATES_ORGANIC_NEW,u.sR.AUTO_SHOW_REBATES_CHECKOUT,u.sR.AUTO_SHOW_REBATES_PDP,u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK,u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_CONFIRMATION,u.sR.AUTO_SHOW_EXPRESS_CHECKOUT,u.sR.AUTO_SHOW_SERVER_DRIVEN_REWARDS,u.sR.AUTO_SHOW_COUPONS_CLIPPING,u.sR.AUTO_SHOW_OTHER_SELLERS,u.sR.AUTO_SHOW_RECOMMENDATIONS,u.sR.AUTO_SHOW_ATTAINABLE_COUPONS,u.sR.AUTO_SHOW_SUSTAINABILITY_PURCHASE,u.sR.AUTO_SHOW_GUEST_DOMAIN_COUPONS,u.sR.AUTO_SHOW_SOCIAL_COUPONS,u.sR.AUTO_SHOW_SUSTAINABILITY_LANDING,u.sR.AUTO_SHOW_PACKAGE_TRACKING,u.sR.AUTO_SHOW_VIRTUAL_CARD,u.sR.AUTO_SHOW_ITEM_ADDED_TO_CART_FROM_OTHER_SELLER,u.sR.AUTO_SHOW_PROFESSIONAL_REVIEWS,u.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK,u.sR.AUTO_SHOW_COUPONS_CHECKOUT]),e?this.pageHandler=e:(this.PopupOrigination=mojom.PopupOrigination,this.AutoShowFeature=mojom.AutoShowFeature,this.PwiloType=mojom.PwiloType,this.ShoppingDataGroup=mojom.ShoppingDataGroup,this.pageHandler=mojom&&mojom.ShoppingHandler.getRemote(),this.shoppingActions=mojom.ShoppingActions,this.shoppingContent=mojom.ShoppingContent,this.packageTrackingActions=mojom.PackageTrackingActions,this.shoppingEngagement=mojom.ShoppingEngagement,this.shoppingCjkScenario=mojom.shoppingCjkScenario,this.shoppingWindowOpenDisposition=mojom.ShoppingWindowOpenDisposition,this.InitiatePageInterface())}RetryFetchUserInfo(e){throw new Error("Method not implemented.")}ClearStorageValue(e){}IsMessageAllowed(e){return e&&"function"==typeof e}OpenContextMenu(e,t,i,n,o){}OpenPane(e,t){return!(!this.pageHandler.openPane||"function"!=typeof this.pageHandler.openPane||(this.CallPageHandlerFunction(this.pageHandler.openPane,"openPane"),0))}OpenChatPane(e,t){this.pageHandler.openChatPane&&"function"==typeof this.pageHandler.openChatPane&&this.CallPageHandlerFunction(this.pageHandler.openChatPane,"openChatPane",e,t)}onActivateRebatesStateChanged(e){if(e!==r.FA.ACTIVATED&&e!==r.FA.STARTED&&e!==r.FA.PENDING_ACTIVATION_IN_PROFILE&&e!==r.FA.PENDING_ENROLL_REBATES_USER&&e!==r.FA.PENDING_SIGN_INTO_PROFILE&&e!==r.FA.PENDING_SWITCH_TO_MSA_PROFILE){const t=document.querySelector("#divContentWrapper");if(t){const i=new CustomEvent(Ku.e1.onRebatesTelemetryFail,{detail:{status:e}});t.dispatchEvent(i)}}else if(e===r.FA.ACTIVATED){const e=document.querySelector("#divContentWrapper");if(e){const t=new CustomEvent(Ku.e1.onRebatesTelemetrySuccess);e.dispatchEvent(t)}}}onActivateRewardsStateChanged(e){if(e!==r.aE.ACTIVATED&&e!==r.aE.STARTED&&e!==r.aE.PENDING_ACTIVATION_IN_PROFILE&&e!==r.aE.PENDING_ENROLL_REWARDS_USER&&e!==r.aE.PENDING_SIGN_INTO_PROFILE&&e!==r.aE.PENDING_SWITCH_TO_MSA_PROFILE){const t=document.querySelector("#divContentWrapper");if(t){const i=new CustomEvent(Ku.e1.onRewardsTelemetryFail,{detail:{status:e}});t.dispatchEvent(i)}}else if(e===r.aE.ACTIVATED){const e=document.querySelector("#divContentWrapper");if(e){const t=new CustomEvent(Ku.e1.onRewardsTelemetrySuccess);e.dispatchEvent(t)}}}InitiatePageInterface(){if(mojom&&"function"==typeof mojom.PageCallbackRouter){const e=new mojom.PageCallbackRouter,t=e=>{this.onActivateRebatesStateChanged(e)},i=e=>{this.onActivateRewardsStateChanged(e)};this.CallPageHandlerFunction(this.pageHandler.registerPage,"registerPage",e.$.bindNewPipeAndPassRemote()),e.onActivateRebatesStateChanged&&e.onActivateRebatesStateChanged.addListener(t.bind(this));try{e.onActivateRewardsStateChanged&&e.onActivateRewardsStateChanged.addListener(i.bind(this))}catch(e){}}}NavigateToSettings(){this.CallPageHandlerFunction(this.pageHandler.navigateToSettings,"navigateToSettings")}NavigateToSettingsPane(){this.CallPageHandlerFunction(this.pageHandler.navigateToSettingsPane,"navigateToSettingsPane")}NavigateToEdgeUrl(e,t){this.CallPageHandlerFunction(this.pageHandler.navigateToEdgeUrl,"navigateToEdgeUrl",e,t)}NavigateToWallet(){this.CallPageHandlerFunction(this.pageHandler.navigateToWallet,"navigateToWallet")}NavigateToTurnOffZip(){this.NavigateToUrl("edge://settings/payments")}NavigateToPrivacyStatement(){this.CallPageHandlerFunction(this.pageHandler.navigateToPrivacyStatement,"navigateToPrivacyStatement")}NavigateToTermsStatement(){this.CallPageHandlerFunction(this.pageHandler.navigateToTermsStatement,"navigateToTermsStatement")}NavigateToCookieConsentStatement(){}NavigateToLearnMore(e){const t=this.shoppingWindowOpenDisposition[e];void 0!==t&&this.CallPageHandlerFunction(this.pageHandler.navigateToLearnMore,"navigateToLearnMore",t)}NavigateToRedeemRewards(){this.NavigateToUrl("https://rewards.microsoft.com/Signin?idru=%2Fredeem/")}NavigateToSustainabilityLearnMore(){this.NavigateToUrl("https://aka.ms/AAeuh78")}NavigateToShoppingLearnMore(){this.NavigateToUrl("https://docs.microsoft.com/en-us/microsoft-edge/privacy-whitepaper/#shopping")}NavigateToPcbProductPage(e){this.NavigateToUrl(e)}NavigateToPrivacyLearnMore(){this.NavigateToUrl("https://go.microsoft.com/fwlink/?linkid=2194724")}NavigateToMoreRebatesSites(){this.NavigateToUrl("https://www.bing.com/stores/edge/cashback")}NavigateToBingRebates(){this.NavigateToUrl("https://www.bing.com/rebates")}NavigateToMicrosoftRewards(){this.NavigateToUrl("https://www.microsoft.com/rewards")}NavigateToPrivacyCookiesStatement(){this.NavigateToUrl("https://go.microsoft.com/fwlink/?LinkID=521839")}NavigateToTermsStatementFlyout(){this.NavigateToUrl("https://www.microsoft.com/bing/rebates-terms")}NavigateToBingRebatesHistory(){this.NavigateToUrl("https://www.bing.com/rebates/history")}NavigateToBingRebatesPayouts(){this.NavigateToUrl("https://www.bing.com/rebates/payouts")}NavigateToBingRebatesDeals(){this.NavigateToUrl("https://www.bing.com/rebates/deals")}NavigateToRewardsInfo(){this.NavigateToUrl("https://bing.com/rewards")}NavigateToBNPLLearnMore(){this.NavigateToUrl("https://aka.ms/EdgeBNPL")}NavigateToRetailerSite(e,t,i){this.CallPageHandlerFunction(this.pageHandler.navigateToAlternateRetailer,"navigateToAlternateRetailer",e,void 0===i?ju.$.NEW_FOREGROUND_TAB:i)}NavigateToPersonalizationLearnMore(){this.NavigateToUrl("https://go.microsoft.com/fwlink/?linkid=2105403")}NavigateToPersonalizationSettings(){this.NavigateToEdgeUrl("edge://settings/privacy#Personalization",ju.$.NEW_FOREGROUND_TAB)}NavigateToPersonalizationPrivacyStatement(){this.NavigateToUrl("https://go.microsoft.com/fwlink/?LinkId=521839")}NavigateToCouponPage(e){}async GetStorageValue(e){return this.pageHandler.getStorageValue?await this.pageHandler.getStorageValue(e):Promise.resolve(null)}SetStorageValue(e,t){this.CallPageHandlerFunction(this.pageHandler.setStorageValue,"setStorageValue",e,t)}GetImageSrc(e){return Promise.resolve("")}async GetStorageValueByDottedPath(e){return this.pageHandler.getStorageValueByDottedPath?await this.pageHandler.GetStorageValueByDottedPath(e):Promise.resolve(null)}SetStorageValueByDottedPath(e,t){this.CallPageHandlerFunction(this.pageHandler.setStorageValueByDottedPath,"setStorageValueByDottedPath",e,t)}AddItemFromOtherSeller(e){this.CallPageHandlerFunction(this.pageHandler.addItemFromOtherSeller,"addItemFromOtherSeller",e)}StartEdgeDriver(e){this.CallPageHandlerFunction(this.pageHandler.startEdgeDriverScript,"startEdgeDriver","",e)}NavigateToRebatesPayouts(e){const t=this.shoppingWindowOpenDisposition[e];void 0!==t&&this.CallPageHandlerFunction(this.pageHandler.navigateToRebatesPayouts,"navigateToRebatesPayouts",t)}NavigateToDealWithDisposition(e,t,i){const n=this.shoppingWindowOpenDisposition[i];void 0!==n&&this.CallPageHandlerFunction(this.pageHandler.navigateToDealWithDisposition,"navigateToDealWithDisposition",e,n)}SetIsPersonalizedShoppingEnabled(e){this.pageHandler.setIsPersonalizedShoppingEnabled(e)}NavigateToRecommendationWithDisposition(e,t,i){const n=this.shoppingWindowOpenDisposition[i];void 0!==n&&this.CallPageHandlerFunction(this.pageHandler.navigateToRecommendationWithDisposition,"navigateToRecommendationWithDisposition",e,n)}NavigateToOrderWithDisposition(e,t){}NavigateToOtherSellerWithDisposition(e,t){const i=this.shoppingWindowOpenDisposition[t];void 0!==i&&this.CallPageHandlerFunction(this.pageHandler.navigateToOtherSellerWithDisposition,"navigateToOtherSellerWithDisposition",e,i)}NavigateToRebatesAccount(e){const t=this.shoppingWindowOpenDisposition[e];void 0!==t&&this.CallPageHandlerFunction(this.pageHandler.navigateToRebatesAccount,"navigateToRebatesAccount",t)}NavigateToProfessionalReviewWithDisposition(e,t,i){const n=this.shoppingWindowOpenDisposition[i];void 0!==n&&this.CallPageHandlerFunction(this.pageHandler.navigateToProfessionalReviewWithDisposition,"navigateToProfessionalReviewWithDisposition",e,n)}NavigateToVideoReviewWithDisposition(e,t,i){const n=this.shoppingWindowOpenDisposition[i];void 0!==n&&this.CallPageHandlerFunction(this.pageHandler.navigateToVideoReviewWithDisposition,"navigateToVideoReviewWithDisposition",e,n)}SendBingTelemetry(e){this.CallPageHandlerFunction(this.pageHandler.sendBingTelemetry,"sendBingTelemetry",e,"-1.0")}RecordAsUserAction(e){if(this.shoppingActions){const t=this.shoppingActions[e];void 0!==t&&this.CallPageHandlerFunction(this.pageHandler.recordAsUserAction,"recordAsUserAction",t)}}RecordPackageTrackingAction(e,t){if(this.packageTrackingActions){const i=this.packageTrackingActions[e];void 0!==i&&this.CallPageHandlerFunction(this.pageHandler.recordPackageTrackingAction,"recordPackageTrackingAction",i,t)}}RecordAsUserEngagement(e,t){if(this.shoppingEngagement){const i=this.shoppingEngagement[e];void 0!==i&&this.CallPageHandlerFunction(this.pageHandler.recordAsUserEngagement,"recordAsUserEngagement",i),this.SendWPOInteractionEvent(t,r.N.Clicked)}}RecordAsContentViewed(e){if(this.shoppingContent){const t=this.shoppingContent[e];void 0!==t&&this.CallPageHandlerFunction(this.pageHandler.recordAsContentViewed,"recordAsContentViewed",t)}}RecordMicroFeedback(e,t){}RecordAsCjkScenario(e,t){if(this.shoppingCjkScenario){const i=this.shoppingCjkScenario[t];void 0!==i&&this.CallPageHandlerFunction(this.pageHandler.recordAsCjkScenario,"recordAsCjkScenario",e,i)}}StartShopping(e,t){this.CallPageHandlerFunction(this.pageHandler.startShopping,"startShopping",e,t)}DismissPopup(){this.CallPageHandlerFunction(this.pageHandler.dismissPopup,"dismissPopup")}SnoozePopup(e,t){this.CallPageHandlerFunction(this.pageHandler.snoozePopup,"snoozePopup")}DismissBanner(){(0,h.Xo)("banneropen","false"),this.CallPageHandlerFunction(this.pageHandler.dismissBanner,"dismissBanner")}OnBannerLoad(){(0,h.Xo)("banneropen","true"),this.CallPageHandlerFunction(this.pageHandler.onBannerLoad,"onBannerLoad")}ShowFlyoutFromBanner(e){this.CallPageHandlerFunction(this.pageHandler.showFlyoutFromBanner,"showFlyoutFromBanner",e)}DeletePackageTrackerByGuid(e){this.CallPageHandlerFunction(this.pageHandler.deletePackageTrackerByGuid,"deletePackageTrackerByGuid",e)}SendVisibilityFeedbBackUrl(e){this.CallPageHandlerFunction(this.pageHandler.sendBingVisibilityRequestWithImpressions,"sendBingVisibilityRequestWithImpressions",e)}NavigateToUrlBackground(e,t,i){this.CallPageHandlerFunction(this.pageHandler.navigateToUrlBackground,"navigateToUrlBackground",e,t)}NavigateToURLWithExternalProtocol(e){this.CallPageHandlerFunction(this.pageHandler.navigateToUrlBackground,"handleExternalProtocol",e,e)}NavigateToUrlBackgroundWithResult(e,t,i){this.CallPageHandlerFunction(this.pageHandler.navigateToUrlBackground,"navigateToUrlBackgroundWithResult",e,t)}InitializeBackgroundAutoApplyNavigatorForBgaa(e,t){this.CallPageHandlerFunction(this.pageHandler.initializeBackgroundAutoApplyNavigatorForBgaa,"initializeBackgroundAutoApplyNavigatorForBgaa",e,t)}ResizeIframe(e){const t={height:e?.offsetHeight,width:e?.offsetWidth,type:"resize_iframe"};this.CallPageHandlerFunction(t,"resize_iframe")}QuerySydney(e){const t={text:e,type:"query_sydney"};this.CallPageHandlerFunction(t,"query_sydney")}AutoShowForAllFeatures(e,t){if(this.pageHandler.allowAutoShowForFeature&&"function"==typeof this.pageHandler.allowAutoShowForFeature)for(const t of this.autoShowList)this.AllowAutoShow(e,t)}AllowAutoShow(e,t){this.pageHandler.allowAutoShowForFeature&&"function"==typeof this.pageHandler.allowAutoShowForFeature&&t?(this.CallPageHandlerFunction(this.pageHandler.allowAutoShowForFeature,"allowAutoShowForFeature",e,t),e&&this.MuteFeatures([t],0)):this.CallPageHandlerFunction(this.pageHandler.allowAutoShow,"allowAutoShow",e)}MuteFeatures(e,t){this.pageHandler.muteFeatures&&"function"==typeof this.pageHandler.muteFeatures&&this.CallPageHandlerFunction(this.pageHandler.muteFeatures,"muteFeatures",e,t)}MuteAllFeatures(e){this.MuteFeatures(e,86400)}UnmuteAllFeatures(e){this.MuteFeatures(e,0)}SetAllowOrganicRebates(e){this.CallPageHandlerFunction(this.pageHandler.setAllowOrganicRebates,"setAllowOrganicRebates",e)}TriggerExperiment(e){this.CallPageHandlerFunction(this.pageHandler.triggerExperiment,"triggerExperiment",e)}TriggerSupportedExperiments(e){this.CallPageHandlerFunction(this.pageHandler.triggerSupportedExperiments,"triggerSupportedExperiments",[...e.values()])}SendBingVisibilityRequest(e){this.CallPageHandlerFunction(this.pageHandler.sendBingVisibilityRequest,"sendBingVisibilityRequest",e)}ApplyAllCoupons(){this.CallPageHandlerFunction(this.pageHandler.applyAllCoupons,"applyAllCoupons")}PrintCoupons(e){try{this.CallPageHandlerFunction(this.pageHandler.printCoupons,"printCoupons",e)}catch{}}ApplyAllCouponsWithExpressCheckout(e){this.CallPageHandlerFunction(this.pageHandler.applyAllCouponsWithExpressCheckout,"applyAllCouponsWithExpressCheckout",e.ToString())}async SignInToRebates(e){return e?await this.pageHandler.signInToRebates():(this.pageHandler.signInToRebates(),{activated:!0})}UpdateLoadTimeData(){return this.CallPageHandlerFunction(this.pageHandler.updateLoadTimeData,"updateLoadTimeData"),{success:!0}}async RefreshDealsResponse(e,t,i){return i?await this.CallPageHandlerFunction(this.pageHandler.refreshDealsResponse,"refreshDealsResponse",e,t):(this.CallPageHandlerFunction(this.pageHandler.refreshDealsResponse,"refreshDealsResponse",e,t),{success:!0})}async ActivateRebates(e){return e?await this.pageHandler.activateRebates():(this.pageHandler.activateRebates(),{activated:!0})}async ActivateRewards(e){return e?await this.pageHandler.activateRewards():(this.pageHandler.activateRewards(),{activated:!0})}async RunQuerySelectorOnBodyWithReponse(e){return await this.pageHandler.runQuerySelectorOnBody(e)}async RunQuerySelectorAllOnBodyWithReponse(e){return await this.pageHandler.runQuerySelectorOnBody(e)}async RunQuerySelectorOnBodyWithValues(e,t){return await this.pageHandler.runQuerySelectorOnBodyWithValues(e,t)}CopyCoupon(e){navigator.clipboard.writeText(e)}DeletePwiloEntry(e){return this.pageHandler.deletePwiloEntry(e)}OnOpenNotification(e,t,i){if(this.pageHandler.onOpenNotification)return this.pageHandler.onOpenNotification(e,t,i)}AllowServerDrivenNotifications(e){return this.pageHandler.allowServerDrivenNotifications(e)}async GetProfilesData(){return new Promise(((e,t)=>{if(!chrome||!chrome.autofillPrivate)return t("can not find profiles.");chrome.autofillPrivate.getAddressList((i=>{i?e(i):t("can not find profiles")}))}))}async GetPaymentsData(){return new Promise(((e,t)=>{if(!chrome||!chrome.autofillPrivate)return t("can not find payments.");chrome.autofillPrivate.getCreditCardList((i=>{i?e(i):t("can not find payments")}))}))}CancelAutoDismiss(){}RecordRenderTime(e){}SetIsNotificationEnabled(e){try{this.CallPageHandlerFunction(this.pageHandler.setIsNotificationEnabled,"setIsNotificationEnabled",e)}catch{}}SetPackageTrackingUserConsent(e){this.CallPageHandlerFunction(this.pageHandler.setPackageTrackingUserConsent,"setPackageTrackingUserConsent",e)}SetPackageTrackingFREShown(e){this.CallPageHandlerFunction(this.pageHandler.setPackageTrackingFREShown,"setPackageTrackingFREShown",e)}async SendMicroFeedbackVote(e,t,i){try{return await this.pageHandler.sendMicroFeedbackVote(e,t,i)}catch{}}SendMicroFeedbackFollowUpVote(e,t,i,n,o){try{this.CallPageHandlerFunction(this.pageHandler.sendMicroFeedbackFollowUpVote,"sendMicroFeedbackFollowUpVote",i,t,e,n,o)}catch{}}OpenMicroFeedback(e){try{this.CallPageHandlerFunction(this.pageHandler.openMicroFeedback,"openMicroFeedback",e)}catch{}}NavigateToUrl(e){e&&window.open(e,"_blank","noopener,noreferrer")}async GetPuid(e){return e?await this.pageHandler.getPuid():(this.pageHandler.getPuid(),{activated:!0})}async GetAnid(e){return e?await this.pageHandler.getAnid():(this.pageHandler.getAnid(),{activated:!0})}async GetEdgeAnid(e){return e?await this.pageHandler.getEdgeAnid():(this.pageHandler.getEdgeAnid(),{activated:!0})}async GetEmailForMSA(e){return e?await this.pageHandler.getEmailForMSA():(this.pageHandler.getEmailForMSA(),{activated:!0})}async SignIntoMSA(e){return e?await this.pageHandler.signIntoMSA():(this.pageHandler.signIntoMSA(),{activated:!0})}async SignInToEdgeProfile(e){return e?await this.pageHandler.signInToEdgeProfile():(this.pageHandler.signInToEdgeProfile(),{activated:!0})}SetSanConsent(e){this.pageHandler.setSanConsent(e)}InContextSanConsentShown(){this.pageHandler.inContextSanConsentShown()}InContextSanConsentClosed(){this.pageHandler.inContextSanConsentClosed()}DisablePopupForDomain(e){const t={popupOrigination:e,type:"disablePopupOriginationForDomain"};this.CallPageHandlerFunction(t,"disablePopupOriginationForDomain",!1)}SendBackgroundAAMetrics(e){}SendWPOInteractionEvent(e,t){try{this.CallPageHandlerFunction(this.pageHandler.sendWPOInteractionEvent,"sendWPOInteractionEvent",e,t)}catch{}}setShoppingNotificationFrequencyHours(e){this.CallPageHandlerFunction(this.pageHandler.setShoppingNotificationFrequencyHours,"setShoppingNotificationFrequencyHours",e)}GetSafeImage(e){return Promise.resolve({succ:!1,safeImgData:""})}CallPageHandlerFunction(e,t,...i){try{if(this.IsMessageAllowed(e))i&&i.length>0?e.apply(this.pageHandler,i):e.apply(this.pageHandler);else if(t!==this.telemetryFunctionName){const e=`${t} is not a function`;this.SendPageHandlerErrorTelemetry(e)}}catch(e){if(t!==this.telemetryFunctionName){const i=`Error calling function ${t} - ${e}`;this.SendPageHandlerErrorTelemetry(i)}}}SendPageHandlerErrorTelemetry(e){const o=new t.Z(i.xu.ErrorPageHandlerFunction),r=new z_.Z(ze.Z.GetClientName(),n.T_,void 0,this.enabledServiceFlights),a=new W_(i.in.Error,i.R.EdgeFlyoutStatus,JSON.stringify(o),e,"",r);this.SendBingTelemetry(a.ToString())}};function X_(e){const t=e.GetLoadTimeDataValue("bingRedirectChainForInitialDomainNavigation",null);let i="";return t&&t instanceof Array&&t.length>0&&(i=t.filter((e=>e.includes("bing.com")||e.includes("microsoft.com"))).join("||")),i}function J_(e,t,i,n,o){const a=new Jt(i);let s=r.m5.LTR,l=r.Q2.Light;try{a.Create(r.AS.Desktop),l=i.GetLoadTimeDataValue("dark_theme",!1)?r.Q2.Dark:r.Q2.Light,s=i.GetLoadTimeDataValue("is_rtl",!1)?r.m5.RTL:r.m5.LTR}catch{}new eD(e,Y_,a,l,s,t,!1).renderErrorUI(o)}window.onerror=(e,o,r,s,l)=>{const c=new t.Z(i.xu.OnErrorInvoked),d=new q_(Y_,n.T_);return d.setData(Jl.g.Client,i.BN.Edge),d.LogErrorEvent(i.R.EdgeFlyoutStatus,`v1 window on error - ${l?.message||JSON.stringify(e)}`,c),document.querySelector("msft-edge-shopping")||J_(d,new a.Z,new ei,0,`v1 window on error ${l?.message||JSON.stringify(e)}`),!0},document.addEventListener("DOMContentLoaded",(async function(){try{(new class{initializeComponents(){globalThis.fastInitialized||(globalThis.fastInitialized=!0,Ds.setGlobalMark(Is.FlyoutFastInitializeStart),rn().register(eo(),Io(),Ho(),er(),fr(),_r(),Vr(),Qr(),ta(),ia(),sa(),da(),ga(),Ea(),_a(),Ua(),Ha(),Ga(),za(),qa(),Ya(),Xa(),ss(),vs(),ys(),bs(),ta(),ia(),sa()),tn.getOrCreate().withPrefix("msft").register(Ys(),tl(),Rs(),rd(),ld(),Jc(),Tl(),ql(),jd(),lu(),Yd(),eu(),ou(),Lu(),Zs(),Us(),Hu(),Sc(),Ac(),Rc(),id(),El(),kl(),md(),pd(),Fl(),$l(),Dc(),$d(),Gl(),zl(),js(),Ks(),Fd(),Ad(),_l(),mu(),hu(),Gu(),bu(),wu(),Eu(),_u()),Ds.setGlobalMark(Is.FlyoutFastInitializeEnd))}initializeContentComponents(){globalThis.fastInitialized||(globalThis.fastInitialized=!0,customElements.define("fluent-switch",Ss),rn().register(eo(),Io(),Ho(),er(),_r(),Vr(),Qr(),ta(),ia(),sa(),Ea(),_a(),da(),Ua(),Ha(),Ga(),za(),qa(),Ya(),Xa(),ss(),vs(),ys(),bs(),ta(),ia(),sa()),tn.getOrCreate().withPrefix("msft").register(Ys(),tl(),Rs(),rd(),ld(),Jc(),Tl(),ql(),jd(),lu(),Yd(),eu(),ou(),Lu(),Zs(),Us(),Hu(),Sc(),Ac(),Rc(),id(),El(),kl(),md(),pd(),Fl(),$l(),Dc(),$d(),Gl(),zl(),js(),Ks(),Fd(),Ad(),mu(),hu(),bu(),wu(),Eu(),_u(),Gu()))}}).initializeComponents();const o=new ei,m=o.GetLoadTimeDataValue("channel",""),y=new q_(Y_,n.T_,m),C=new class{constructor(n,o,a){(0,s.Z)(this,"dataLoader",void 0),(0,s.Z)(this,"common",new class{constructor(){(0,s.Z)(this,"shopping",void 0),(0,s.Z)(this,"shoppingPersistent",void 0),(0,s.Z)(this,"shoppingExplore",void 0),(0,s.Z)(this,"shoppingSettings",void 0),(0,s.Z)(this,"shoppingCashback",void 0),(0,s.Z)(this,"openedWith",void 0),(0,s.Z)(this,"isOrganicFlowEnabled",void 0),(0,s.Z)(this,"isShoppingPersonalizationEnabled",void 0),(0,s.Z)(this,"shouldOpenSettingsPane",void 0),(0,s.Z)(this,"shouldShowCookieConsent",void 0),(0,s.Z)(this,"shouldShowBanner",void 0),(0,s.Z)(this,"bannerContext",void 0),(0,s.Z)(this,"domain",void 0),(0,s.Z)(this,"foundLowerPrice",void 0),(0,s.Z)(this,"showPCBannerUX",void 0),(0,s.Z)(this,"currentUrl",void 0),(0,s.Z)(this,"currentTheme",void 0),(0,s.Z)(this,"isCheckoutPage",void 0),(0,s.Z)(this,"isCheckoutPageUsingUrlMatch",void 0),(0,s.Z)(this,"currentDirection",void 0),(0,s.Z)(this,"lastCommittedURL",void 0),(0,s.Z)(this,"resourcesEndpoint",void 0),(0,s.Z)(this,"urlPrefix",void 0),(0,s.Z)(this,"popupOrigination",void 0),(0,s.Z)(this,"autoshowFeaturePref",void 0),(0,s.Z)(this,"currentDevice",void 0),(0,s.Z)(this,"seeInfoFromPCNotification",void 0),(0,s.Z)(this,"pageStatus",void 0),(0,s.Z)(this,"isPane",void 0),(0,s.Z)(this,"isPaneEnabled",void 0),(0,s.Z)(this,"isPanePinned",void 0),(0,s.Z)(this,"isRebatesEnabled",void 0),(0,s.Z)(this,"suppressRebatesScenarios",void 0),(0,s.Z)(this,"isEdgeProfile",void 0),(0,s.Z)(this,"edgeProfileData",void 0),(0,s.Z)(this,"edgeDriverDataForFlyout",void 0),(0,s.Z)(this,"pageLocale",void 0),(0,s.Z)(this,"channel",void 0),(0,s.Z)(this,"market",void 0),(0,s.Z)(this,"afdMarket",void 0),(0,s.Z)(this,"exclusiveMarket",void 0),(0,s.Z)(this,"muid",void 0),(0,s.Z)(this,"isWebAssistPending",void 0),(0,s.Z)(this,"lastClippingAutoApplyDetailsForCurrentUrl",void 0),(0,s.Z)(this,"flyoutId",void 0),(0,s.Z)(this,"googleAuthRedirectUrl",void 0),(0,s.Z)(this,"microsoftAuthRedirectUrl",void 0),(0,s.Z)(this,"authAllowedOrigins",void 0),(0,s.Z)(this,"extractedEntity",void 0),(0,s.Z)(this,"base64ProductImage",void 0),(0,s.Z)(this,"isDomainEligible",void 0),(0,s.Z)(this,"isSharedHeader",void 0),(0,s.Z)(this,"hasUserAgreedToPrivacyPolicy",void 0),(0,s.Z)(this,"isUserHadFirstExperience",void 0),(0,s.Z)(this,"isSupportedDomain",void 0),(0,s.Z)(this,"isSafariClient",void 0),(0,s.Z)(this,"safariCurrentVersion",void 0),(0,s.Z)(this,"safariLatestVersion",void 0),(0,s.Z)(this,"isDiscoverPane",void 0),(0,s.Z)(this,"journeyStage",void 0),(0,s.Z)(this,"viewModulesInDiscoverPane",void 0),(0,s.Z)(this,"autoOpenParams",void 0),(0,s.Z)(this,"isStorybook",!1),(0,s.Z)(this,"isCJKEnabled",void 0),(0,s.Z)(this,"cjkDataVendor",void 0),(0,s.Z)(this,"isCjkShouldGetSafeImage",void 0),(0,s.Z)(this,"userCountryCode",void 0),(0,s.Z)(this,"browseMode",void 0),(0,s.Z)(this,"trendingCoupons",void 0),(0,s.Z)(this,"chatConsentStatus",void 0),(0,s.Z)(this,"sessionId",void 0),(0,s.Z)(this,"retailerSessionId",void 0),(0,s.Z)(this,"pageVisitId",void 0),(0,s.Z)(this,"isNotificationEnabled",void 0),(0,s.Z)(this,"disabledNotifications",void 0),(0,s.Z)(this,"isShorelineOrigination",!1)}Create(e,n,o){const a=document.createElement("msft-edge-shopping"),s=document.createElement("msft-edge-shopping"),p=document.createElement("msft-edge-shopping"),g=document.createElement("msft-edge-shopping");this.currentDevice=e;const f=n.GetLoadTimeDataValue("dark_theme",!1);this.currentTheme=f?r.Q2.Dark:r.Q2.Light;const m=n.GetLoadTimeDataValue("is_rtl",!1);this.currentDirection=m?r.m5.RTL:r.m5.LTR,this.openedWith=n.GetLoadTimeDataValue("open_action",void 0),this.currentUrl=n.GetLoadTimeDataValue("url",void 0),this.shouldOpenSettingsPane=!1;const v=(0,h.Mw)(h.Oh);if(v&&"true"===v&&(this.shouldOpenSettingsPane=!0,(0,h.TJ)(h.Oh)),this.shouldShowBanner=n.GetLoadTimeDataValue("shouldShowBanner",!1),this.bannerContext=n.GetLoadTimeDataValue("bannerContext",""),this.shouldShowCookieConsent=n.GetLoadTimeDataValue("shouldShowCookieConsent",!1),this.foundLowerPrice=n.GetLoadTimeDataValue("foundLowerPrice",void 0),this.showPCBannerUX=n.GetLoadTimeDataValue("showPCBannerUX",!1),this.isOrganicFlowEnabled=n.GetLoadTimeDataValue("allowOrganicRebates",!1),this.isShoppingPersonalizationEnabled=n.GetLoadTimeDataValue("is_personalized_shopping_enabled",void 0),this.isCheckoutPage=n.GetLoadTimeDataValue("isCheckoutPage",!1),this.isCheckoutPageUsingUrlMatch=n.GetLoadTimeDataValue("isCheckoutPageUsingUrlMatch",!1),this.lastCommittedURL=n.GetLoadTimeDataValue("lastCommittedURL",void 0),this.popupOrigination=n.GetLoadTimeDataValue("popupOrigination",void 0),this.popupOrigination===u.sR.AUTO_SHOW_AOC)try{const e=n.GetLoadTimeDataValue("lastAutoOpenScenarioValue",void 0);if(e)this.popupOrigination=e;else{const e=n.GetLoadTimeDataValue("storage",void 0);if(e){const t=e[d.Nv];t&&(this.popupOrigination=parseInt(t,10))}}}catch(e){this.popupOrigination=n.GetLoadTimeDataValue("popupOrigination",void 0)}this.autoshowFeaturePref=n.GetLoadTimeDataValue("autoShowFeatureDisabledPref",void 0),this.autoOpenParams=n.GetLoadTimeDataValue("autoOpenParams",void 0),this.journeyStage=n.GetLoadTimeDataValue(l.a.JourneyStage,0),this.isDiscoverPane=n.GetLoadTimeDataValue(l.a.IsDiscoverPane,!1);const y=n.GetLoadTimeDataValue("viewModules",[]);if(this.viewModulesInDiscoverPane=y&&y.length>0?y:n.GetLoadTimeDataValue("viewDiscoverModules",[]),this.trendingCoupons=n.GetLoadTimeDataValue("trendingCoupons",[]),this.isPane=n.GetLoadTimeDataValue("is_hub",!1),this.isPaneEnabled=n.GetLoadTimeDataValue("is_hub_enabled",!1),this.isPanePinned=n.GetLoadTimeDataValue("is_hub_pinned",!1),this.isRebatesEnabled=n.GetLoadTimeDataValue("is_rebates_enabled",!1),this.suppressRebatesScenarios=n.GetLoadTimeDataValue("suppress_rebates_scenarios",!1),this.isEdgeProfile=n.GetLoadTimeDataValue("is_edge_profile",!1),this.pageLocale=n.GetLoadTimeDataValue("page_locale",void 0),this.channel=n.GetLoadTimeDataValue("channel",""),this.muid=n.GetLoadTimeDataValue("muid",void 0),this.isWebAssistPending=n.GetLoadTimeDataValue("is_web_assist_pending",!1),this.isDomainEligible=n.GetLoadTimeDataValue("isDomainEligible",!1),this.isSharedHeader=n.GetLoadTimeDataValue("is_shared_header",!1),this.extractedEntity=n.GetLoadTimeDataValue("extracted_entity",void 0),this.extractedEntity){const e=n.GetLoadTimeDataValue("priceHistory",void 0)?.debug;e?.globalOfferIdList?.length>0&&(this.extractedEntity.globalOfferId=e.globalOfferIdList[0]),e?.productKey&&(this.extractedEntity.productKey=e?.productKey)}if(this.base64ProductImage=n.GetLoadTimeDataValue("base64ProductImage",void 0),this.hasUserAgreedToPrivacyPolicy=n.GetLoadTimeDataValue("hasUserAgreedToPrivacyPolicy",!1),this.isUserHadFirstExperience=n.GetLoadTimeDataValue("isUserHadFirstExperience",!1),this.isSupportedDomain=n.GetLoadTimeDataValue("isSupportedDomain",!1),this.isSafariClient=n.GetLoadTimeDataValue("isSafariClient",!1),this.safariCurrentVersion=n.GetLoadTimeDataValue("safariCurrentVersion",void 0),this.safariLatestVersion=n.GetLoadTimeDataValue("safariLatestVersion",void 0),this.lastClippingAutoApplyDetailsForCurrentUrl=n.GetLoadTimeDataValue("lastAutoApplyDetailsForCurrentUrl",void 0),this.isCJKEnabled=n.GetLoadTimeDataValue(l.a.IsCJKEnabled,!1),this.cjkDataVendor=n.GetLoadTimeDataValue("cjk_data_vendor",void 0),this.isCjkShouldGetSafeImage=n.GetLoadTimeDataValue("cjk_get_safe_image",!1),this.chatConsentStatus=n.GetLoadTimeDataValue("chat_consent_status",r.lg.Accepted),this.sessionId=n.GetLoadTimeDataValue("sessionId",void 0),this.retailerSessionId=n.GetLoadTimeDataValue("retailerSessionId",void 0),this.pageVisitId=n.GetLoadTimeDataValue("pageVisitId",void 0),this.isNotificationEnabled=n.GetLoadTimeDataValue("is_notification_enabled",!0),this.UpdatePageStatus(n),this.UpdateEdgeDriverDataForFlyout(n),this.UpdateEdgeProfile(n),this.isSafariClient&&(globalThis.clippingUpdated=n.GetLoadTimeDataValue("clippingUpdated",!1)),!this.isCJKEnabled&&!this.isPane&&"true"===(0,h.Mw)("openPane")){this.isPane=!0,this.openedWith=r.Te.Mouse,this.popupOrigination=void 0;const e=new t.Z(i.xu.OnErrorInvoked);o.LogErrorEvent(i.R.EdgeFlyoutStatus,"Pane empty after opening from notification",e)}this.domain="",this.market="",this.afdMarket="",this.exclusiveMarket="",this.shopping=a,this.shoppingPersistent=s,this.shoppingExplore=p,this.shoppingSettings=g,this.shoppingCashback=document.createElement("msft-edge-shopping"),this.seeInfoFromPCNotification=!1,n.IsServerData()||e===r.AS.Mobile?this.urlPrefix="":this.urlPrefix="edge://image?",this.channel===r.Ee.CANARY||this.channel===r.Ee.DEV?this.resourcesEndpoint=this.urlPrefix+"https://www.staging-bing-int.com/api/shopping/v1/ux/images/":this.resourcesEndpoint=this.urlPrefix+"https://www.bing.com/api/shopping/v1/ux/images/",this.flyoutId=c.Z.uuidv4(),this.googleAuthRedirectUrl="https://horus.microsoft.com/api/callback/gmail",this.microsoftAuthRedirectUrl="https://horus.microsoft.com/api/callback/microsoft",this.authAllowedOrigins=new Set(["https://func-inboxcoupons-apigateway-eus.azurewebsites.net","https://horus.microsoft.com"].map((e=>new URL(e).origin))),this.userCountryCode=n.GetLoadTimeDataValue("countryCode","").toLocaleLowerCase(),this.browseMode=n.GetLoadTimeDataValue("browseMode",""),this.isShorelineOrigination=n.GetLoadTimeDataValue("isShorelineOrigination",!1)}UpdatePageStatus(e){const t=new class{constructor(){(0,s.Z)(this,"AutoApplyStatus",void 0),(0,s.Z)(this,"ExpressCheckoutStatus",void 0),(0,s.Z)(this,"PageValidations",void 0),(0,s.Z)(this,"personalizationAutoOpenTelemetryData",void 0),(0,s.Z)(this,"openMicroNotification",void 0)}},i=e.GetLoadTimeDataValue(l.a.PageStatus,void 0);if(i)try{const e=JSON.parse(i);t.AutoApplyStatus=e.auto_apply_status,t.ExpressCheckoutStatus=e.express_checkout_status,t.PageValidations=e.page_validations,t.personalizationAutoOpenTelemetryData=e.personalizationAutoOpenTelemetryData,t.openMicroNotification=e.open_micro_notifcation}catch(e){}this.pageStatus=t}UpdateEdgeDriverDataForFlyout(e){this.edgeDriverDataForFlyout=void 0;const t=e.GetLoadTimeDataValue(l.a.EdgeDriverDataForFlyout,void 0);if(t)try{this.edgeDriverDataForFlyout=JSON.parse(t)}catch(e){}}UpdateEdgeProfile(e){const t=new class{constructor(){(0,s.Z)(this,"isRebatesUser",void 0),(0,s.Z)(this,"isEligibleForCashbackEnroll",void 0)}};t.isRebatesUser=!1,t.isEligibleForCashbackEnroll=!1;const i=e.GetLoadTimeDataValue("edge_profile_data",void 0);if(i)try{const e=JSON.parse(i);t.isRebatesUser=e.isRebatesUser,t.isEligibleForCashbackEnroll=e.isEligibleForCashbackEnroll}catch(e){}this.edgeProfileData=t}}),(0,s.Z)(this,"strings",void 0),(0,s.Z)(this,"dataStoreModule",new class{constructor(){(0,s.Z)(this,"CouponData",void 0),(0,s.Z)(this,"PriceComparisonData",void 0),(0,s.Z)(this,"PriceHistoryData",void 0),(0,s.Z)(this,"CashBackData",void 0),(0,s.Z)(this,"ProductInsightsData",void 0),(0,s.Z)(this,"ApiData",void 0),(0,s.Z)(this,"RatingsAndReviewsData",void 0),(0,s.Z)(this,"ProductHistoryData",void 0),(0,s.Z)(this,"RewardData",void 0),(0,s.Z)(this,"PaymentOptionsData",void 0),(0,s.Z)(this,"SocialCouponsData",void 0),(0,s.Z)(this,"OrderTrackingData",void 0),(0,s.Z)(this,"VirtualCardData",void 0),(0,s.Z)(this,"ViewedProductListData",void 0),(0,s.Z)(this,"PinterestData",void 0),(0,s.Z)(this,"SimilarSellerData",void 0),(0,s.Z)(this,"IncentiveCampaignData",void 0),(0,s.Z)(this,"AbandonedCartData",void 0),(0,s.Z)(this,"isAwarenessExpansionEnabled",void 0),(0,s.Z)(this,"ProductTrackingData",void 0),(0,s.Z)(this,"ProductTrackingNotificationData",void 0),(0,s.Z)(this,"AbandonedCartCouponsData",void 0),(0,s.Z)(this,"CategoryDealsData",void 0),(0,s.Z)(this,"UserInfo",void 0),(0,s.Z)(this,"ClientInfo",void 0),(0,s.Z)(this,"GroceryCashbackData",void 0),(0,s.Z)(this,"SPBItemizedCashbackData",void 0),(0,s.Z)(this,"TrendingCouponsData",void 0),(0,s.Z)(this,"SANConsentData",void 0),(0,s.Z)(this,"IsSSAEnabled",void 0),(0,s.Z)(this,"ICVariations",void 0),(0,s.Z)(this,"DiscoverShoppingData",void 0),(0,s.Z)(this,"CjkSimilarProductsData",void 0),(0,s.Z)(this,"AutosData",void 0),(0,s.Z)(this,"CampaignData",void 0),(0,s.Z)(this,"ProductBestCouponData",void 0),(0,s.Z)(this,"UserInsightsData",void 0),(0,s.Z)(this,"ExpertInsightsData",void 0),(0,s.Z)(this,"ProductSummaryCardData",void 0),(0,s.Z)(this,"InboxBestPriceMatchProduct",void 0),this.UserInfo=new me.Z,this.ClientInfo=new $.Z}}),this.dataLoader=o,this.strings=new Jt(o),this.strings.Create(n);const p=o.GetLoadTimeDataValue(l.a.EnabledFeatures,void 0),g=this.GetEnabledServiceFeatures(o);(p||g)&&e.R.Create(p,g),this.common.Create(n,o,a)}async initializeModuleData(n,o,a,c){return await new class{constructor(e,t,i){(0,s.Z)(this,"apiResponse",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"apiResponseStr",void 0),(0,s.Z)(this,"perfDataCreation",new Map),this.logModule=e,this.pageHandlerModule=t,this.storageHandler=i}async InitializeData(n){const o=performance.now();try{this.flyoutData=n;const e=this.flyoutData.dataLoader.GetLoadTimeDataValue(l.a.GuestCouponsApiResponse,void 0);if(e&&this.flyoutData.common.lastCommittedURL&&this.flyoutData.common.lastCommittedURL.includes("pinterest.com/pin")?this.apiResponseStr=e:this.apiResponseStr=this.flyoutData.dataLoader.GetLoadTimeDataValue(l.a.CouponsApiResponse,void 0),this.apiResponseStr){this.apiResponse=JSON.parse(this.apiResponseStr);const e=U.Create(this.apiResponse);e&&(this.flyoutData.dataStoreModule.ApiData=e,this.flyoutData.dataStoreModule.ApiData.domainData=this.apiResponse?.itemLevelCashBack?.domainData?Z.Z.Create(this.apiResponse?.itemLevelCashBack.domainData):void 0,(0,h.UZ)("openPane"))}new class{constructor(e){this.logModule=e,(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"notificationsData",void 0)}async InitializeNotificationData(e){if(this.flyoutData=e,this.notificationsData=this.flyoutData.dataLoader.GetLoadTimeDataValue(l.a.NotificationData,void 0),this.notificationsData&&Array.isArray(this.notificationsData.notificationsList))try{this.GetAbandonedCartNotificationData(),this.GetCategoryDealsData(),this.GetProductTrackingNotificationData()}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`MUID Notification extraction error ${e}`,n)}}GetCategoryDealsData(){if(this.notificationsData)for(const e of this.notificationsData.notificationsList){if(e.notifications?.length<=0)return;for(const t of e.notifications)if(t?.notificationType===pt.CategoryDeals){this.flyoutData.dataStoreModule.CategoryDealsData=new ht(t.notificationMetadata);break}}}GetAbandonedCartNotificationData(){if(this.notificationsData&&this.notificationsData?.notificationsList?.length>0)for(const e of this.notificationsData.notificationsList){const t=e?.cartData;if(e.notifications?.length>0){const i=[];for(const n of e.notifications)(t||n.notificationType===pt.PersonalizedCashback)&&this.IsValidACNotification(n)&&i.push(n);if(i.length>0){this.sortNotifications(i);for(const e of i){this.ProcessMUIDNotification(e,t);break}}}break}}sortNotifications(e){e.sort(((e,t)=>this.GetNotificationPriority(t)-this.GetNotificationPriority(e)))}ProcessMUIDNotification(e,t){const i=e?.notificationMetadata;let n;t&&(n=t[i?.domain]);const o=new Map;e.notificationType!==pt.PersonalizedCashback||n||(n=new Ne(e.notificationMetadata.domain));const r=this.GetAbandonedCartFromNotification(n,e);o.set(e.notificationMetadata.domain,r),this.flyoutData.dataStoreModule.AbandonedCartCouponsData=o}IsValidACNotification(e){return e?.notificationType===pt.Coupons||e?.notificationType===pt.CategoryDeals?e?.notificationMetadata?.coupon?.couponCode&&e?.notificationMetadata?.coupon?.discountRate:e?.notificationType===pt.Cashback?e?.notificationMetadata?.type&&e?.notificationMetadata?.value:e?.notificationType===pt.PersonalizedCashback?e?.notificationMetadata?.commissionValue&&e?.notificationMetadata?.commissionType&&e?.notificationMetadata?.scope&&e?.notificationMetadata?.productUrl&&e?.notificationMetadata?.imageUrl&&e?.notificationMetadata?.domain:e?.notificationType===pt.ExclusiveCoupons&&null!==e?.notificationMetadata?.domain&&null!==e?.notificationMetadata?.exclusiveCouponCode&&null!==e?.notificationMetadata?.discountRate&&null!==e?.notificationMetadata?.retailerCartPage}GetAbandonedCartFromNotification(e,t){const i=new Ne(e);return t?.notificationType===pt.Coupons||t?.notificationType===pt.CategoryDeals?(i.CouponCode=t.notificationMetadata.coupon.couponCode,i.DiscountRate=t.notificationMetadata.coupon.discountRate):t?.notificationType===pt.Cashback?(i.CashbackCommissionType=t.notificationMetadata.type,i.CashbackCommissionValue=t.notificationMetadata.value):t?.notificationType===pt.PersonalizedCashback?(i.CashbackCommissionType=t.notificationMetadata.commissionType,i.CashbackCommissionValue=t.notificationMetadata.commissionValue,i.Scope=t.notificationMetadata.scope,i.ProductUrl=t.notificationMetadata.productUrl,i.ImageUrl=t.notificationMetadata.imageUrl,i.Domain=t.notificationMetadata.domain,i.VisibilityFeedbackUrl=t.notificationMetadata.visibilityFeedbackUrl,i.ImpressionToken=t.notificationMetadata.impressionToken):t?.notificationType===pt.ExclusiveCoupons&&(i.NotificationType=t?.notificationType,i.Domain=t.notificationMetadata.domain,i.ImageUrl=t.notificationMetadata.imageUrl,i.ExclusiveCouponCode=t.notificationMetadata.exclusiveCouponCode,i.DiscountRate=t.notificationMetadata.discountRate,i.RetailerCartPage=t.notificationMetadata.retailerCartPage),i.NotificationType=t.notificationType,i}GetNotificationPriority(e){let t=0;return e?.notificationType===pt.Coupons||e?.notificationType===pt.CategoryDeals?t=parseInt(e.notificationMetadata.coupon.discountRate,10):e?.notificationType===pt.Cashback?(t=parseInt(e.notificationMetadata.value,10),"flat"===e.notificationMetadata.type&&(t+=100)):e?.notificationType===pt.PersonalizedCashback?(t=parseInt(e.notificationMetadata.value,10),t+=101):e?.notificationType===pt.ExclusiveCoupons&&(t=parseInt(e.notificationMetadata.coupon.discountRate,10),t+=1002),t}GetProductTrackingNotificationData(){if(this.notificationsData){this.flyoutData.dataStoreModule.ProductTrackingNotificationData=new class{constructor(e){this.trackedProducts=e}get TrackedProducts(){return this.trackedProducts||[]}get BackInStockProducts(){return(this.trackedProducts||[]).filter((({trackingType:e})=>e===ut.$g.OutOfStock))}get PriceDropProducts(){return(this.trackedProducts||[]).filter((({trackingType:e})=>e===ut.$g.PriceDrop)).filter((({highSuccessRateCoupon:e,cashbackCommission:t})=>!e&&!t))}get PriceDropOffersProducts(){return(this.trackedProducts||[]).filter((({trackingType:e})=>e===ut.$g.PriceDrop)).filter((({highSuccessRateCoupon:e,cashbackCommission:t})=>e&&t))}addTrackedProduct(e){Array.isArray(this.trackedProducts)||(this.trackedProducts=[]),this.trackedProducts.push(e)}};for(const e of this.notificationsData.notificationsList)if(e.notifications?.length>0)for(const t of e.notifications)t?.notificationType===pt.ProductTracking&&this.flyoutData.dataStoreModule.ProductTrackingNotificationData.addTrackedProduct(new ut.ZP(t?.notificationMetadata?.updatedTrackedProduct))}}}(this.logModule).InitializeNotificationData(n)}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`InitializeData error ${e}`,n)}if(this.flyoutData.dataStoreModule.ApiData?.retailerData?.domainName)n.common.domain=this.flyoutData.dataStoreModule.ApiData?.retailerData?.domainName;else if(n.common.lastCommittedURL){const e=this.getDomainNameFromUrl(n.common.lastCommittedURL);e&&(n.common.domain=e)}this.flyoutData.common.domain=n.common.domain,this.flyoutData.dataStoreModule.ApiData?.market&&(n.common.market=this.flyoutData.dataStoreModule.ApiData?.market),this.flyoutData.dataStoreModule.ApiData?.retailerData?.exclusiveMarket&&(n.common.exclusiveMarket=this.flyoutData.dataStoreModule.ApiData?.retailerData?.exclusiveMarket),this.flyoutData.dataStoreModule.ApiData?.aFDMarket&&(n.common.afdMarket=this.flyoutData.dataStoreModule.ApiData?.aFDMarket),this.flyoutData.common.afdMarket=n.common.afdMarket,this.initUser(),this.flyoutData.dataStoreModule.ClientInfo=$.Z.Create(this.apiResponse),this.flyoutData.dataStoreModule.UserInfo.anonymousUserId=(0,we.fU)(),this.flyoutData.common.disabledNotifications=this.apiResponse?.disabledNotifications,await this.createDataWithErrorHandling(r.ModuleNames.COUPON),this.createDataWithErrorHandling(r.ModuleNames.CASHBACK),this.createDataWithErrorHandling(r.ModuleNames.SIDEPANE_CASHBACK),this.createDataWithErrorHandling(r.ModuleNames.PRICECOMPARISON),e.R.setShowPCBannerUX(this.flyoutData.common.showPCBannerUX,(0,h.WN)("banneropen")||this.flyoutData.common.shouldShowBanner,this.flyoutData.dataStoreModule.PriceComparisonData,this.flyoutData.common.foundLowerPrice),this.createDataWithErrorHandling(r.ModuleNames.PRICEHISTORY),await this.createDataWithErrorHandling(r.ModuleNames.AUTOSREVIEWS),this.createDataWithErrorHandling(r.ModuleNames.COUPONCLIPPING),this.createDataWithErrorHandling(r.ModuleNames.PRODUCTHISTORY),this.createDataWithErrorHandling(r.ModuleNames.REWARD),this.createDataWithErrorHandling(r.ModuleNames.PAYMENT_OPTIONS),await this.createDataWithErrorHandling(r.ModuleNames.SOCIALCOUPONS),this.createDataWithErrorHandling(r.ModuleNames.VIRTUAL_CARD),await this.createDataWithErrorHandling(r.ModuleNames.GROCERY_CASHBACK),await this.createDataWithErrorHandling(r.ModuleNames.ITEMIZED_CASHBACK),this.createDataWithErrorHandling(r.ModuleNames.ORDERSTATUSTRACKING),this.createDataWithErrorHandling(r.ModuleNames.ViewedProductPriceDrop),await this.createDataWithErrorHandling(r.ModuleNames.PINTEREST),await this.createIncentiveCampaignDataWithErrorHandling(),this.createDataWithErrorHandling(r.ModuleNames.ABANDONED_CART),this.createDataWithErrorHandling(r.ModuleNames.PRODUCT_COLLECTIONS),this.createDataWithErrorHandling(r.ModuleNames.TRENDING_COUPONS),this.createDataWithErrorHandling(r.ModuleNames.SAN_CONSENT),e.R.isExperimentActive(f.H.autosMyGarageEntryPoint)||this.createDataWithErrorHandling(r.ModuleNames.AUTOSMYGARAGE),this.createDataWithErrorHandling(r.ModuleNames.AUTOSMARKETPLACE),this.createDataWithErrorHandling(r.ModuleNames.USER_INSIGHTS),this.createDataWithErrorHandling(r.ModuleNames.EXPERT_INSIGHTS),this.createDataWithErrorHandling(r.ModuleNames.SMART_COMPARE),this.flyoutData.dataStoreModule.CampaignData=new class{constructor(t,i){if((0,s.Z)(this,"retailerData",void 0),(0,s.Z)(this,"product",void 0),(0,s.Z)(this,"topDeals",void 0),(0,s.Z)(this,"expData",void 0),this.expData=new class{constructor(){if((0,s.Z)(this,"startTime",void 0),(0,s.Z)(this,"endTime",void 0),(0,s.Z)(this,"variants",void 0),this.variants=this.parseCampaignVariants(),this.variants.startDateTime&&this.variants.endDateTime)try{this.startTime=new Date(this.variants.startDateTime),this.endTime=new Date(this.variants.endDateTime)}catch(e){}}isCampaignActive(){return void 0!==this.startTime&&void 0!==this.endTime&&Date.now()>=this.startTime.getTime()&&Date.now()<this.endTime.getTime()&&"true"===this.variants.uxEnabled}isCampaignAwarenessNotificationActive(){return this.isCampaignActive()&&e.R.isExperimentActive(f.H.campaignAwareness)}getExperimentVariants(){return e.R.getMultipleVariants(f.H.campaign)}parseCampaignVariants(){const e=this.getExperimentVariants(),t={};for(const i of e)"startDateTime"===i.key?t.startDateTime=i.value:"endDateTime"===i.key?t.endDateTime=i.value:"dataSourceEnv"===i.key?t.dataSourceEnv=i.value:"uxEnabled"===i.key&&(t.uxEnabled=i.value);return t}},this.expData.isCampaignActive()){this.retailerData={oldCashBack:t?.dealDaysRetailerData?.retailerOldCashback,currentCashBack:t?.dealDaysRetailerData?.retailerCurrentCashback,specialCashBackOffer:t?.dealDaysRetailerData?.specialCashBackOffer};const e=i.GetLoadTimeDataValue("dealDaysPDP",void 0);e?.dealDaysProduct&&(this.product=new v(e.dealDaysProduct)),"mock"===this.expData.variants.dataSourceEnv&&(this.product={globalOfferId:"117936252395",cashback:{commisionValue:"5.00",commisionType:"$"},coupon:{code:"MSFT123",discountType:"%",discountValue:"10"},title:"Surface Pro 9",seller:"Microsoft Store",originalPrice:"$1199.99",imageUrl:"https://th.bing.com/th?id=OP.15ZZVMtt%2fzbucw474C474&w=592&h=550&o=5&pid=21.1",discountPrice:"$999.99"},this.retailerData={oldCashBack:{commisionValue:"1",commisionType:"%"},currentCashBack:{commisionValue:"6",commisionType:"%"},specialCashBackOffer:{cashBackAmount:"$10 off",cashBackCondition:"on purchace of at leasts $100"}})}}}(this.apiResponse,this.flyoutData.dataLoader),this.createDataWithErrorHandling(r.ModuleNames.AX_SHOPPING_NAV),this.createDataWithErrorHandling(r.ModuleNames.CJK_SIMILAR_PRODUCTS),this.createDataWithErrorHandling(r.ModuleNames.PRODUCT_BEST_COUPON),this.createDataWithErrorHandling(r.ModuleNames.PRODUCTSUMMARYCARD);const a=performance.now(),c=new z(this.flyoutData.common.domain,a-o,this.flyoutData.common.isPane?"pane":"flyout",JSON.stringify(this.perfDataCreation,x.uy),G.DataExtraction);this.logModule.LogInfoEvent(i.R.RenderTimeBreakDown,"",c)}initUser(){const e=this.flyoutData.dataLoader.GetLoadTimeDataValue("is_edge_profile_rebates_user",void 0),t=this.flyoutData.dataLoader.GetLoadTimeDataValue("aadEmail",void 0),i=this.flyoutData.dataLoader.GetLoadTimeDataValue("isAADLinkedAccountValid",void 0),n=this.flyoutData.dataLoader.GetLoadTimeDataValue("isLinkingPolicyEnabled",void 0);this.flyoutData.dataStoreModule.UserInfo=me.Z.Create(this.apiResponse,!0===e||"true"===e,t,i,n)}async createDataWithErrorHandling(e){const n=performance.now();try{switch(e){case r.ModuleNames.CASHBACK:case r.ModuleNames.SIDEPANE_CASHBACK:case r.ModuleNames.UNIFIED_CASHBACK:this.flyoutData.dataStoreModule.CashBackData=await this.GetCashBackData(),this.flyoutData.dataStoreModule.ProductInsightsData=this.PopulateProductInsightData();break;case r.ModuleNames.COUPON:case r.ModuleNames.INBOX_COUPONS:this.flyoutData.dataStoreModule.CouponData=await this.GetCouponData(),this.flyoutData.dataStoreModule.isAwarenessExpansionEnabled=this.apiResponse?.isAwarenessExpansionEnabled,this.flyoutData.dataStoreModule.IsSSAEnabled=this.apiResponse?.isSSAEnabled;break;case r.ModuleNames.PRICECOMPARISON:case r.ModuleNames.SIMILAR_OFFERS:this.flyoutData.dataStoreModule.PriceComparisonData=this.GetPriceComparisonData(),this.flyoutData.dataStoreModule.ProductInsightsData=this.PopulateProductInsightData();break;case r.ModuleNames.PRICEHISTORY:this.flyoutData.dataStoreModule.PriceHistoryData=this.GetPriceHistoryData(),this.flyoutData.dataStoreModule.ProductInsightsData=this.PopulateProductInsightData();break;case r.ModuleNames.AUTOSREVIEWS:this.flyoutData.dataStoreModule.RatingsAndReviewsData=await this.GetRatingsAndReviewsData();break;case r.ModuleNames.PRODUCTHISTORY:this.flyoutData.dataStoreModule.ProductHistoryData=this.GetProductHistoryData();break;case r.ModuleNames.REWARD:this.flyoutData.dataStoreModule.RewardData=this.GetRewardData();break;case r.ModuleNames.PAYMENT_OPTIONS:this.flyoutData.dataStoreModule.PaymentOptionsData=this.GetPaymentOptionsData();break;case r.ModuleNames.SOCIALCOUPONS:this.flyoutData.dataStoreModule.SocialCouponsData=await this.GetExclusiveCouponData();break;case r.ModuleNames.VIRTUAL_CARD:this.flyoutData.dataStoreModule.VirtualCardData=this.GetVirtualCardData();break;case r.ModuleNames.GROCERY_CASHBACK:this.flyoutData.dataStoreModule.GroceryCashbackData=await this.GetGroceryCashbackData();break;case r.ModuleNames.ITEMIZED_CASHBACK:this.flyoutData.dataStoreModule.SPBItemizedCashbackData=await this.GetSPBItemizedCashbackData();break;case r.ModuleNames.ORDERSTATUSTRACKING:this.flyoutData.dataStoreModule.OrderTrackingData=await this.GetOrderTrackingData();break;case r.ModuleNames.ViewedProductPriceDrop:this.flyoutData.dataStoreModule.ViewedProductListData=this.GetViewedProductPriceDropData();case r.ModuleNames.PINTEREST:this.flyoutData.dataStoreModule.PinterestData=await this.GetPinterestData();break;case r.ModuleNames.ABANDONED_CART:this.flyoutData.dataStoreModule.AbandonedCartData=this.GetAbandonedCartData();break;case r.ModuleNames.PRODUCT_COLLECTIONS:this.flyoutData.dataStoreModule.ProductTrackingData=this.GetProductTrackingData();break;case r.ModuleNames.TRENDING_COUPONS:this.flyoutData.dataStoreModule.TrendingCouponsData=this.GetTrendingCouponsData();break;case r.ModuleNames.SAN_CONSENT:this.flyoutData.dataStoreModule.SANConsentData=this.GetSANConsentData();break;case r.ModuleNames.AUTOSMYGARAGE:case r.ModuleNames.AUTOSMARKETPLACE:this.flyoutData.dataStoreModule.AutosData=this.GetAutosData();break;case r.ModuleNames.SMART_COMPARE:this.flyoutData.dataStoreModule.DiscoverShoppingData=this.GetDiscoverData();break;case r.ModuleNames.USER_INSIGHTS:this.flyoutData.dataStoreModule.UserInsightsData=this.GetUserInsightsData();break;case r.ModuleNames.EXPERT_INSIGHTS:this.flyoutData.dataStoreModule.ExpertInsightsData=this.GetExpertInsightsData();break;case r.ModuleNames.CJK_SIMILAR_PRODUCTS:this.flyoutData.dataStoreModule.CjkSimilarProductsData=this.GetCjkSimilarProductsData();break;case r.ModuleNames.PRODUCT_BEST_COUPON:this.flyoutData.dataStoreModule.ProductBestCouponData=this.flyoutData.dataLoader.GetLoadTimeDataValue("productBestCoupon",void 0);break;case r.ModuleNames.PRODUCTSUMMARYCARD:this.flyoutData.dataStoreModule.ProductSummaryCardData=new rt(this.flyoutData.dataStoreModule.CouponData,this.flyoutData.dataStoreModule.PriceComparisonData,this.flyoutData.dataStoreModule.PriceHistoryData,this.flyoutData.dataStoreModule.ProductTrackingData,this.flyoutData.dataStoreModule.CashBackData)}}catch(n){const o=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Data creation Exception: ${e} ${(0,dt.YU)(n)}`,o)}finally{const t=performance.now();this.perfDataCreation.set(e,t-n)}}async createIncentiveCampaignDataWithErrorHandling(){if(this.pageHandlerModule.TriggerExperiment(f.H.incentiveCampaign),e.R.isExperimentActive(f.H.incentiveCampaign)){try{this.flyoutData.dataStoreModule.IncentiveCampaignData=await this.GetIncentiveCampaignData()}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Data creation Exception: Incentive Campaign, failed to fetch use Info, ${(0,dt.YU)(e)}`,n)}if(this.flyoutData.dataStoreModule.IncentiveCampaignData)try{await this.flyoutData.dataStoreModule.IncentiveCampaignData.reportUserProgress(this.storageHandler)}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Incentive Campaign: failed to update user progress, ${(0,dt.YU)(e)}`,n)}}}async GetCashBackData(){let n,o,a;this.apiResponse?(n=this.apiResponse.cashback,o=this.apiResponse.personalizedAdsResponse,a=this.apiResponse.isCashbackEstimationSupportedForDomain):(0,we.Jp)(!0,this.flyoutData,this.logModule,"apiResponse is empty");const l=this.flyoutData.dataLoader.GetLoadTimeDataValue("rebatesActive",!1);let c=this.flyoutData.dataLoader.GetLoadTimeDataValue("isConfirmationPage",!1);if(!c){const e=this.flyoutData.dataLoader.GetLoadTimeDataValue("couponsApiResponse",void 0);if(e)try{const t=JSON.parse(e),i=t?.retailerData?.orderConfirmationPageUrl;if(i){const e=new URL(this.flyoutData.common.lastCommittedURL).pathname;c=new RegExp(i).test(e)}}catch(e){}}const d=this.flyoutData.dataLoader.GetLoadTimeDataValue("rebatesDeactivating",!1),h=this.flyoutData.dataLoader.GetLoadTimeDataValue("activateRebatesStatus",null),p=await this.storageHandler.getStorageString(Ce.Q.PCBStorewideAddressBar,!1),g=this.flyoutData.dataStoreModule.UserInfo.isAADSignedIn,m=this.flyoutData.dataStoreModule.UserInfo.isAADLinkedAccountValid,v=this.flyoutData.dataStoreModule.UserInfo.isLinkingPolicyEnabled;let y=!0;this.apiResponse?.itemLevelCashBack?.variations?.spbLinkingEnabled&&(y=this.apiResponse.itemLevelCashBack.variations.spbLinkingEnabled);const C=this.flyoutData?.dataStoreModule?.UserInfo?.isRebatesUser||this.flyoutData.common.isRebatesEnabled;return new class{constructor(t,i,n,o,r,a,l,c,d,u,h,p,g,m,v,y,C,b,S,T){if((0,s.Z)(this,"highestCashBackCategory",void 0),(0,s.Z)(this,"userRebatesResponse",void 0),(0,s.Z)(this,"merchantName",void 0),(0,s.Z)(this,"image",void 0),(0,s.Z)(this,"merchantId",void 0),(0,s.Z)(this,"merchantFullName",void 0),(0,s.Z)(this,"merchantUri",void 0),(0,s.Z)(this,"affiliateNetwork",void 0),(0,s.Z)(this,"IsRebatesSupportedDomain",void 0),(0,s.Z)(this,"isSignInSupportedDomain",void 0),(0,s.Z)(this,"isCashBackActivated",void 0),(0,s.Z)(this,"isConfirmationPage",void 0),(0,s.Z)(this,"isTurnedOff",void 0),(0,s.Z)(this,"personalizedCashback",void 0),(0,s.Z)(this,"shouldRenderCashBackNotification",void 0),(0,s.Z)(this,"isPersonalizedCashback",void 0),(0,s.Z)(this,"isSpbActivated",void 0),(0,s.Z)(this,"isSignInSupportedDomainCashBack",void 0),(0,s.Z)(this,"popupOrigination",void 0),(0,s.Z)(this,"activateRebatesStatus",void 0),(0,s.Z)(this,"isEdgeSignedInMsa",void 0),(0,s.Z)(this,"canRenderCashback",void 0),(0,s.Z)(this,"isLinkYourMSAWorkflow",void 0),(0,s.Z)(this,"isLinkingEnabledForSPB",void 0),(0,s.Z)(this,"isCashbackEstimationSupportedForDomain",!1),(0,s.Z)(this,"isExclusiveOffer",void 0),(0,s.Z)(this,"isEdgeProfile",void 0),(0,s.Z)(this,"edgeProfileData",void 0),(0,s.Z)(this,"estimatedCashbackData",void 0),(0,s.Z)(this,"lastCommittedURL",void 0),(0,s.Z)(this,"categories",void 0),(0,s.Z)(this,"exclusions",void 0),(0,s.Z)(this,"shoppingTrips",void 0),(0,s.Z)(this,"isAddressBarPersonalizedCashback",void 0),(0,s.Z)(this,"productAd",void 0),(0,s.Z)(this,"isRebateUser",!1),(0,s.Z)(this,"pcbWireAddressData",void 0),(0,s.Z)(this,"isAADSignedIn",void 0),(0,s.Z)(this,"isAADLinkedAccountValid",void 0),(0,s.Z)(this,"isLinkingPolicyEnabled",void 0),this.isRebateUser=d,t){if(this.highestCashBackCategory=new Me.Z(t.highestCashbackCategory),this.userRebatesResponse={cashbackAvailable:t.userRebateResponse?.cashbackAvailable,isRebatesUser:t.userRebateResponse?.isRebatesUser??!1,latestCashbackApproved:t.userRebateResponse?.latestCashbackApproved,latestCashbackApprovedCurrency:t.userRebateResponse?.latestCashbackApprovedCurrency,latestOrderDate:t.userRebateResponse?.latestOrderDate,latestOrderMerchantName:t.userRebateResponse?.latestOrderMerchantName,latestOrderMerchantUrl:t.userRebateResponse?.latestOrderMerchantUrl,lifetimeBalance:t.userRebateResponse?.lifetimeBalance,isChromeUserCampaignEligible:t.userRebateResponse?.isChromeUserCampaignEligible,userCurrency:t.userRebateResponse?.userCurrency},this.isSignInSupportedDomain=t.isSignInSupportedDomain,this.merchantName=t.merchantName,this.image=t.image,this.merchantId=t.merchantId,this.merchantFullName=t.merchantFullName,this.merchantUri=t.merchantUri,this.affiliateNetwork=t.affiliateNetwork,this.IsRebatesSupportedDomain=t.isRebatesSupportedDomain??null,this.isCashbackEstimationSupportedForDomain=u,this.isExclusiveOffer=t.isExclusive,this.exclusions=t.exclusions,this.categories=[],t.categories)for(const e of t.categories)this.categories.push(new Me.Z(e));if(this.shoppingTrips=[],t.userRebateResponse?.shoppingTrips)for(const e of t.userRebateResponse.shoppingTrips)this.shoppingTrips.push(new Le(e))}i&&(this.personalizedCashback={commissionType:i.personalizedCashback?.commissionType,commissionValue:i.personalizedCashback?.commissionValue,imageUrl:i.personalizedCashback?.imageUrl,isAdClick:i.personalizedCashback?.isAdClick,offerId:i.personalizedCashback?.offerId,productUrl:i.personalizedCashback?.productUrl,rGuid:i.personalizedCashback?.rGuid,scope:i.personalizedCashback?.scope,destinationUrl:i.personalizedCashback?.destinationUrl,adsCashback:i.personalizedCashback?.adsCashback}),this.isCashBackActivated=n??!1,this.isConfirmationPage=o??!1,this.isTurnedOff=r??!1,this.popupOrigination=l,this.activateRebatesStatus=c,this.isEdgeProfile=h,this.lastCommittedURL=g,this.edgeProfileData=p,this.shouldRenderCashBackNotification=this.ShouldRenderCashBackNotification(this,a),this.isPersonalizedCashback=this.IsPersonalizedCashback(this),this.isSpbActivated=this.IsSpbActivated(v),this.pcbWireAddressData=y,this.isSignInSupportedDomainCashBack=this.IsSignInSupportedDomainCashBack(this,a),e.R.isExperimentActive(f.H.pcbAddressBar)&&y&&(this.isAddressBarPersonalizedCashback=this.IsAddressBarPersonalizedCashback(m,y,a)),this.isLinkYourMSAWorkflow=this.IsLinkYourMSAWorkflow((0,x.Nx)(C),(0,x.Nx)(b),(0,x.Nx)(S)),this.isLinkingEnabledForSPB=(0,x.Nx)(T),this.canRenderCashback=this.CanRenderCashback(d,m)}async getEstimatedCashbackData(n,o,r){if(!n.dataStoreModule.CashBackData?.isCashbackEstimationSupportedForDomain)return;const a=n.common.domain,s=n.dataStoreModule.CashBackData?.highestCashBackCategory.commissionValue,l=n.dataStoreModule.CashBackData?.highestCashBackCategory.commissionType;let c=0,d=!1;if(n.common.isCheckoutPageUsingUrlMatch){const e=a?"EstimatedCashback:CartData"+a:"EstimatedCashback:CartData",t=await(o?.getStorageString(e));if(!t)return;if(n.dataStoreModule.ApiData?.retailerData.isStorewideCashbackEstimationEnabled){const e=JSON.parse(t);if(!e)return;l===Ue.Percent||"%"===l?c=e.value*s/100:Ue.Cash}}else if(n.dataStoreModule.ApiData?.retailerData.isStorewideCashbackEstimationEnabled){const t=n.dataLoader.GetLoadTimeDataValue("price",void 0);if(!t)return;if(d=!0,!e.R.isExperimentActive(f.H.pdpStorewideCashbackEstimation)&&!e.R.isExperimentActive(f.H.cashbackPdpPlusCouponsNotification)&&!e.R.isExperimentActive(f.H.cashbackPdpPlusPriceDropNotification))return;l===Ue.Percent||"%"===l?c=t*s/100:Ue.Cash}const u=parseFloat(c.toFixed(2));return u&&u>=1?(this.estimatedCashbackData=new Re(a,c.toFixed(2),(0,ne.N6)((0,T.uf)(n.dataStoreModule.ApiData?.market,n.dataStoreModule.ApiData?.retailerData?.exclusiveMarket))??"$",d),r.LogInfoEvent(i.R.EstimatedCashback,"User saw Cashback of "+this.estimatedCashbackData.currency+this.estimatedCashbackData.cashbackValue,new t.Z(i.xu.EstimatedCashbackShown)),this.estimatedCashbackData):void 0}CreateLogMetadata(){return{isRebatesUser:this.IsRebatesUser(),isBingRebatesUser:this.IsBingRebatesUser(),isBingRebatesUserFromApiResponse:this.IsBingRebatesUserApiResponse(),isEdgeRebatesUser:this.IsEdgeRebatesUser(),isEdgeProfile:this.isEdgeProfile,canRenderCashback:this.canRenderCashback,isCashBackActivated:this.isCashBackActivated,isSignInSupportedDomainCashBack:this.isSignInSupportedDomainCashBack,isSignInSupportedDomain:this.isSignInSupportedDomain,activateRebatesStatus:this.activateRebatesStatus,estimatedCashback:this.estimatedCashbackData,cashbackCategories:this.highestCashBackCategory,isPersonalizedCashback:this.isPersonalizedCashback,shouldRenderCashbackNotification:this.shouldRenderCashBackNotification,isRebatesSupportedDomain:this.IsRebatesSupportedDomain,highestCashBackCategory:this.highestCashBackCategory,isConfirmationPage:this.isConfirmationPage,isTurnedOff:this.isTurnedOff,isSpbActivated:this.isSpbActivated,popupOrigination:this.popupOrigination,isEdgeSignedInMsa:this.isEdgeSignedInMsa,isLinkYourMSAWorkflow:this.isLinkYourMSAWorkflow,isCashbackEstimationSupportedForDomain:this.isCashbackEstimationSupportedForDomain,isExclusiveOffer:this.isExclusiveOffer,estimatedCashbackData:this.estimatedCashbackData,personalizedCashback:this.personalizedCashback}}CreatePersonalizedCashbackLogMetadata(){return this.personalizedCashback?.adsCashback&&this.personalizedCashback?.adsCashback.length>0?{commissionType:this.personalizedCashback?.adsCashback[0]?.commissionType,commissionValue:this.personalizedCashback?.adsCashback[0]?.commissionValue,scope:this.personalizedCashback?.adsCashback[0]?.scope}:{}}IsRebatesUser(){if(e.R.isExperimentActive(f.H.rebatesSsoFlow)){const e=this.edgeProfileData.isRebatesUser??!1,t=(this.userRebatesResponse&&this.userRebatesResponse.isRebatesUser)??!1;return this.isEdgeProfile?e:t}return!!this.isRebateUser||((this.userRebatesResponse&&this.userRebatesResponse.isRebatesUser)??!1)}IsBingRebatesUser(){return this.isRebateUser}IsBingRebatesUserApiResponse(){return this.userRebatesResponse&&this.userRebatesResponse.isRebatesUser}IsEdgeRebatesUser(){return this.edgeProfileData?.isRebatesUser}isAddressBarPersonalizedCashbackActive(){return e.R.isExperimentActive(f.H.pcbAddressBar)&&this.isAddressBarPersonalizedCashback}IsLinkYourMSAWorkflow(t,i,n){return e.R.isExperimentActive(f.H.edgeShoppingRebatesForAADAccounts)&&t&&!i&&n}CanRenderCashback(t,i){const n=new URL(this.lastCommittedURL);if(!t&&!this.isSignInSupportedDomainCashBack||!1===this.IsRebatesSupportedDomain&&!this.isAddressBarPersonalizedCashbackActive()||n?.pathname?.includes("shop.app"))return!1;const o=e.R.getServiceExperimentValue(f.H.cbMerchantAbTesting);return!(e.R.isExperimentActive(f.H.cbMerchantAbTesting)&&i===o&&!this.isPersonalizedCashback||!this.isLinkYourMSAWorkflow&&!(this.IsRebatesUser()&&this.highestCashBackCategory&&this.highestCashBackCategory.commissionValue&&this.highestCashBackCategory.commissionType&&this.highestCashBackCategory.category&&this.merchantFullName)&&!this.isPersonalizedCashback&&!this.isAddressBarPersonalizedCashbackActive()&&!this.isSignInSupportedDomainCashBack)}IsSignInSupportedDomainCashBack(t,i){return!(!(t&&t.isSignInSupportedDomain&&!this.IsRebatesUser()&&e.R.isExperimentActive(f.H.signinRebates)&&t.personalizedCashback?.commissionType&&t.personalizedCashback?.commissionValue&&t.personalizedCashback?.scope&&t.personalizedCashback?.offerId)||this.popupOrigination!==u.sR.AUTO_SHOW_REBATES_SWITCHED_TO_MSA&&this.popupOrigination!==u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_CONFIRMATION&&this.popupOrigination!==u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK&&i===r.Te.Auto)||!(!(t&&t.isSignInSupportedDomain&&!this.IsRebatesUser()&&e.R.isExperimentActive(f.H.signinRebates)&&e.R.isExperimentActive(f.H.pcbAddressBar)&&t?.productAd?.promotionInformation?.rebateValue&&t?.productAd?.promotionInformation?.minPurchaseValue)||this.popupOrigination!==u.sR.AUTO_SHOW_REBATES_SWITCHED_TO_MSA&&this.popupOrigination!==u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_ADDRESSBAR||i!==r.Te.Auto)||((t&&t.isSignInSupportedDomain&&!this.IsRebatesUser()&&e.R.isExperimentActive(f.H.signinRebates)&&t.highestCashBackCategory&&t.highestCashBackCategory.commissionValue&&t.highestCashBackCategory.commissionType&&t.highestCashBackCategory.category&&t.merchantFullName&&(!t.isCashBackActivated||this.popupOrigination===u.sR.AUTO_SHOW_REBATES_SWITCHED_TO_MSA))??!1)}IsPersonalizedCashback(e){return(e&&e.personalizedCashback&&e.personalizedCashback?.adsCashback&&e.personalizedCashback?.adsCashback?.length>0)??!1}IsAddressBarPersonalizedCashback(e,t,i){const n=(0,T.BQ)(t)??{};return!(!n[e]?.productAd?.promotionInformation?.rebateValue||this.popupOrigination!==u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_ADDRESSBAR||i!==r.Te.Auto||(this.productAd=n[e]?.productAd,0))}IsSpbActivated(e){return(e&&e.isSpbActivated)??!1}ShouldRenderCashBackNotification(e,t){return this.popupOrigination===u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK_ADDRESSBAR&&t===r.Te.Auto||!1!==e.IsRebatesSupportedDomain&&(!(!e.isConfirmationPage&&!e.isTurnedOff)||!!(e&&t===r.Te.Auto&&this.popupOrigination&&Fe.includes(this.popupOrigination)||this.popupOrigination===u.sR.AUTO_SHOW_PERSONALIZED_CASHBACK&&!e?.isSpbActivated))}}(n,o,l,c,d,this.flyoutData.common.openedWith,this.flyoutData.common.popupOrigination,h,C,!!a,this.flyoutData.common.isEdgeProfile,this.flyoutData.common.edgeProfileData,this.flyoutData.common.lastCommittedURL,this.flyoutData.common.domain,this.apiResponse?.itemLevelCashBack,p,g,m,v,y)}async GetCouponData(){const e=this.flyoutData.common.isCJKEnabled;if(this.apiResponse){if(e){const e=this.apiResponse;return new et(e,!1,this.flyoutData)}{const e=this.flyoutData.dataLoader.GetLoadTimeDataValue("isAutoApplyAvailable",!1),t=this.apiResponse;if(!this.flyoutData.common.isCheckoutPage&&this.flyoutData.common.openedWith===r.Te.Auto&&this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_REBATES_CHECKOUT&&e)try{await this.ExecuteAutoApplyAutoOpenRebatesHack()}catch(e){}return new et(t,e,this.flyoutData)}}if(e){const e=this.apiResponse;return new et(e,!1,this.flyoutData)}}async ExecuteAutoApplyAutoOpenRebatesHack(){const e="isCheckoutPage_"+this.flyoutData.common.lastCommittedURL,t=await this.storageHandler.getStorageString(e);if(!(0,p.TF)(t)){const i=JSON.parse(t);!0===i.isCheckoutPage&&Date.now()-i.validationTime<=18e5?this.flyoutData.common.isCheckoutPage=!0:this.storageHandler.clearStorage(e)}}async GetExclusiveCouponData(){if(e.R.isExperimentActive(f.H.socialCoupons)){const e=await this.storageHandler.getStorageBool("CanSaveYoutubeCoupons");if(null===e||!0===e){let t="socialCoupons";null===e&&(this.storageHandler.clearStorage(t),t=`${t}Temp`);const i=await this.storageHandler.getStorageString(t);if(i&&""!==i){const t=JSON.parse(i);if(t&&t.length>0){let i=this.flyoutData.common.domain;i||(i=this.flyoutData.common.lastCommittedURL,i&&(i=i.replace("http://www.",""),i=i.replace("https://www.",""),i=i.replace("https://",""),-1!==i.indexOf(".")&&(i=i.substring(0,i.indexOf("."))),-1!==i.indexOf("/")&&(i=i.substring(0,i.indexOf("/")))));const n=new class{constructor(e,t,i){(0,s.Z)(this,"socialCouponsForDomain",[]),(0,s.Z)(this,"youtubeCouponsData",void 0),(0,s.Z)(this,"permission",null),(0,s.Z)(this,"socialCouponsForDifferentDomain",[]),e&&e.length>0&&(this.youtubeCouponsData=e,this.youtubeCouponsData.forEach((e=>{const n=new he;n.followers=e.followers,n.imgSrc=e.imgSrc,n.influencerName=e.influencerName,n.channelId=e.channelId,n.userName=e.userName,n.coupons=[];const o=new he;o.followers=e.followers,o.imgSrc=e.imgSrc,o.influencerName=e.influencerName,o.channelId=e.channelId,o.userName=e.userName,o.coupons=[];const r=/(http|https):\/\/(www\.)?([A-Za-z0-9]*\.(com|net|org|info|coop|int|co\.uk|org\.uk|ac\.uk|uk))/;e.coupons?.forEach((e=>{const i=r.exec(e.retailerLink);let a;e.retailerDomain&&(a=e.retailerDomain.replace(/[^a-zA-Z0-9]/g,"")),t&&(t=t.replace("-","")),i&&5===i.length&&i[3]===t||a&&(a.includes(t)||t.includes(a))?n.coupons.push(e):o.coupons.push(e)})),n.coupons.length>0&&this.socialCouponsForDomain.push(n),o.coupons.length>0&&this.socialCouponsForDifferentDomain.push(o),this.permission=i})))}}(t,i,e);return Promise.resolve(n)}}}}return Promise.resolve(void 0)}async GetPinterestData(){const e=await this.storageHandler.getStorageString("pinterestProductLink");if(!(0,p.TF)(e)){const t=new class{constructor(e){(0,s.Z)(this,"productLink",void 0),this.productLink=e}}(e);return Promise.resolve(t)}return Promise.resolve(void 0)}GetPriceComparisonData(){const e=this.flyoutData.dataLoader.GetLoadTimeDataValue("comparableOffers",void 0),t=this.flyoutData.dataLoader.GetLoadTimeDataValue("price",void 0),i=this.flyoutData.dataLoader.GetLoadTimeDataValue("extracted_entity",void 0),n=this.flyoutData.dataLoader.GetLoadTimeDataValue("page_locale",void 0);return new ce(e,t,i,n)}PopulateProductInsightData(){if(e.R.isExperimentActive(f.H.communityInsightsPC)||e.R.isExperimentActive(f.H.communityInsightsPH)||e.R.isExperimentActive(f.H.communityInsightsCB))try{const e=this.flyoutData.dataLoader.GetLoadTimeDataValue("communityInsights",void 0);if(e){const t=e.response.topInsight;if(t&&Yt.insightsTemplate.includes(t.displayTextKey))return new class{constructor(e){(0,s.Z)(this,"TopInsight",void 0),this.TopInsight=e}}(this.getInsightString(this.flyoutData.strings,t.displayTextKey,t.displayValues))}}catch(e){return}}getInsightString(e,t,i){const n=e[t];let o;return o=i&&i.length<2?(0,T.fZ)(n,n,`${i[0]}`):(0,T.fZ)(n,n,`${i[0]}`,`${i[1]}`),o}GetPriceHistoryData(){const e=this.flyoutData.dataLoader.GetLoadTimeDataValue("priceHistory",void 0);let t;if(e&&e.priceHistoryData&&e.productDetails){const i=this.flyoutData.dataLoader.GetLoadTimeDataValue("price",void 0),n=this.flyoutData.dataLoader.GetLoadTimeDataValue("base64ProductImage",void 0),o=this.flyoutData.dataLoader.GetLoadTimeDataValue("extracted_entity",void 0),r=o?.image_url,a=o?.entity?.image,s=o?.entity?.price_currency,l=o?.currency,c=o?.title;t=new de.ZP(e,i,n,a??r,this.flyoutData.common.domain,s??l,c,this.flyoutData.dataLoader.GetLoadTimeDataValue("isShorelineOrigination",!1))}if(!(t&&t.DailyPrices.length<=1))return t}async GetRatingsAndReviewsData(){const e=this.getAutosRatingReview()||await this.getAutosSERPRatingReview(),t=this.getAutosMakeModel();if(e)return Promise.resolve((new Rt).Create(e,t));const i=this.flyoutData.dataLoader.GetLoadTimeDataValue("comparableOffers",void 0);return i?Promise.resolve((new Rt).Create(i?.ratingReviews,void 0)):Promise.resolve(void 0)}getAutosRatingReview(){const e=this.flyoutData.dataStoreModule.ApiData?.retailerData,t=this.getAutosDataSelector(e);if(t)try{const e=JSON.parse(t);return e?.ratingReview}catch(e){}return null}getAutosMakeModel(){const e=this.flyoutData.dataStoreModule.ApiData?.retailerData,t=this.getAutosDataSelector(e);if(t)try{const e=JSON.parse(t);if(e?.priceInsights?.make&&e?.priceInsights?.model)return{title:[e?.priceInsights?.make,e?.priceInsights?.model].join(" ")}}catch(e){}}getAutosDataSelector(e){if(!e)return null;const t=this.flyoutData.common.lastCommittedURL;let i=null;return e?.allCheckoutPages?.forEach((e=>{"/"!==e.checkoutPageUrl&&t?.indexOf(e.checkoutPageUrl)>-1&&(i=e.autosDataSelector)})),i}async getAutosSERPRatingReview(){const e=await this.storageHandler.getStorageString(Ce.Q.AutosMarketplace);if(e)try{const t=JSON.parse(e);return t?.currentUrl===this.flyoutData.common.lastCommittedURL?t?.autosData?.ratingReview:null}catch(e){}return null}GetProductHistoryData(){const e=this.flyoutData.dataLoader.GetLoadTimeDataValue("webAssistEntities",void 0),t=[];return e&&e.length>0&&e.forEach((e=>{const i=new wt(e);i.domain&&i.entity.price&&i.title&&t.push(i)})),t}GetRewardData(){try{if(this.apiResponse){const t=this.apiResponse.rewards,i=this.flyoutData.dataLoader.GetLoadTimeDataValue("activateRewardsStatus",null);if(t)return new class{constructor(e,t,i){(0,s.Z)(this,"Points",void 0),(0,s.Z)(this,"IsRewardsActive",void 0),(0,s.Z)(this,"IsSignedInUser",void 0),(0,s.Z)(this,"IsAssociatedUser",void 0),(0,s.Z)(this,"IsTrialUser",void 0),(0,s.Z)(this,"TrialUserExpiryInDays",void 0),(0,s.Z)(this,"ActivateRewardsStatus",void 0),(0,s.Z)(this,"shouldRenderRewardNotification",void 0),(0,s.Z)(this,"IsControlUser",void 0),this.Points=e.points,this.IsRewardsActive=e.isRewardsActive,this.IsAssociatedUser=e.isAssociatedUser,this.IsSignedInUser=e.isSignedInUser,this.IsTrialUser=e.isTrialUser,this.TrialUserExpiryInDays=e.trialUserExpiryInDays,this.IsControlUser=e.isControlUser,this.ActivateRewardsStatus=t,this.shouldRenderRewardNotification=this.ShouldRenderRewardNotification(this,i)}isUserDefined(){return this.IsSignedInUser||this.IsAssociatedUser||this.IsTrialUser}ShouldRenderRewardNotification(t,i){return t&&t.IsRewardsActive&&e.R.isExperimentActive(f.H.rewardNotification)&&i===r.Te.Auto}}(t,i,this.flyoutData.common.openedWith)}}catch(e){}}SetICVariationsData(){const e=this.apiResponse?.itemLevelCashBack?.variations?new Map(Object.entries(this.apiResponse?.itemLevelCashBack?.variations)):new Map;this.flyoutData.dataStoreModule.ICVariations=e}async GetSPBItemizedCashbackData(){if(!this.apiResponse?.itemLevelCashBack?.isSponsored)return;if(this.flyoutData.common.openedWith===r.Te.Auto&&this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_SPB_CASHBACK_LANDING&&this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_SPB_CHECK_OUT_PAGE_NOTIFICATION)return;const t=new class{constructor(){(0,s.Z)(this,"ItemizedCashback",void 0),(0,s.Z)(this,"AdsMetadata",void 0),(0,s.Z)(this,"SpbPDPData",void 0),(0,s.Z)(this,"PageInfoType",void 0),(0,s.Z)(this,"PageTitle",void 0),(0,s.Z)(this,"IsSpbFlightActive",void 0),(0,s.Z)(this,"searchNotificationVariation",void 0),(0,s.Z)(this,"pdpNotificationVariation",void 0),(0,s.Z)(this,"domainData",void 0),(0,s.Z)(this,"seenSpbOffers",void 0),(0,s.Z)(this,"matchedCartSpbOffers",void 0),(0,s.Z)(this,"totalMatchedOffer",void 0),(0,s.Z)(this,"homePageSpbOffers",void 0),(0,s.Z)(this,"isRecentlyViewedSpbEnabled",!1),(0,s.Z)(this,"isSpbAddToCartEnabled",!1),(0,s.Z)(this,"searchQuery",""),(0,s.Z)(this,"categoryName",""),this.IsSpbFlightActive=!1}SetData(e,t,i,n,o,r,a,s,l,c,d){this.ItemizedCashback=e,this.AdsMetadata=t,this.PageInfoType=i,this.PageTitle=n,this.domainData=a?Z.Z.Create(a):void 0,this.seenSpbOffers=s,this.matchedCartSpbOffers=l;const u=o||void 0,h=r||void 0;this.searchNotificationVariation=u??pe.b.variation1,this.pdpNotificationVariation=h??pe.b.variation1,this.isRecentlyViewedSpbEnabled=c,this.isSpbAddToCartEnabled=d}SetPdpData(e){this.SpbPDPData=e}};try{const{cashbackItems:i,adsMetadata:n,pageInfoType:o,pageTitle:r,isCategory:a,isSearch:s}=await this.GetSPBSearchAndCategoryData(),l=await this.storageHandler.getStorageString(Ce.Q.GroceryMatchedCartSpbOffers),c=e.R.isExperimentActive(f.H.spbCheckoutAutoActivation)&&"amazon.com"===this.flyoutData.common.domain;let d=[];c&&(d=(0,we.rm)(l)??[]),this.SetICVariationsData();const u=this.flyoutData.dataStoreModule.ICVariations,h=u?.get("autoShowSpbUX"),p=u?.get("autoShowSpbPdpUX"),g="enabled"===u?.get("recentlyViewedSpb"),m="enabled"===u.get("isAddToCartEnabled"),v=this.apiResponse?.itemLevelCashBack?.domainData,y=this.apiResponse?.personalizedAdsResponse?.personalizedCashback,C=(0,Ie.rP)([],y);t.SetData(i,n,o,r,h,p,v,C,d,g,m),t.searchQuery=s?r:"",t.categoryName=a?r:"";const b=u?.get("autoShowSpbHomePageUX")||pe.b.variation1,S=this.GetHomePageSpbOffers(b,C);t.homePageSpbOffers=S;const x=this.flyoutData.dataLoader.GetLoadTimeDataValue("comparableOffers",void 0)||void 0,T=await this.GetSPBPDPData(t.domainData,[],x);t.SetPdpData(T),void 0!==t.SpbPDPData&&(t.SpbPDPData?.RelatedOffers?.length>0||t.SpbPDPData.ItemizedCashbackExactMatch)&&(t.PageInfoType="pdpSPB"),t.IsSpbFlightActive=!0}catch(e){(0,we.F0)(this.flyoutData,this.logModule,"Error parsing spb itemized cashback data: ",e)}return t}GetHomePageSpbOffers(e,t){try{const i=this.apiResponse?.itemLevelCashBack?.spbHomePageOffers,n=i||[];if(0===n.length)return;const o={notificationOffer:void 0,homePageSpbOffers:[],autoShowVariation:e},r=n.find((e=>e.shouldAutoshow&&e.offersType===ve.h.SPB&&e.offers?.length>0));if(r){const e=r.offers[0];e.visibilityFeedbackUrlBase=r.adsMetadata.visibilityFeedbackUrl,o.notificationOffer=e}const a=[];return n.forEach((e=>{const t=e.adsMetadata?.visibilityFeedbackUrl||"",i=e.offers.map((e=>Ve.Create(e,t)));a.push(...i)})),t.forEach((e=>{e.id&&a.push(e)})),o.homePageSpbOffers=a,o}catch(e){(0,we.F0)(this.flyoutData,this.logModule,"Error in GetHomePageSpbOffers",e)}}async GetSPBPDPData(e,t,i){try{const n=this.flyoutData.dataLoader.GetLoadTimeDataValue(l.a.ProductItemizedCashBack,void 0),o=this.GetEntityData();let r;if((0,De.M)(i))r=je.CreateFromPCResponse(i);else if(n)r=je.Create(n);else{const e=await this.storageHandler.getStorageString(Ce.Q.ICCurrentPageInfo),t=this.flyoutData.common.lastCommittedURL;if(!(0,p.TF)(e))try{const i=JSON.parse(e);if(o.title=i.pageTitle||o.title,i&&i.currentUrl===t&&i.type===ke.c.PdpSPB){const e=i.cashbackData;r=je.Create(e)}}catch(e){(0,we.F0)(this.flyoutData,this.logModule,"Error parsing currentPageInfo in GetSPBPDPData",e)}}r?r.pdpData=o:r=new je;const a=this.apiResponse?.personalizedAdsResponse?.personalizedCashback,s=a||void 0,{activatedDestinationUrlPathnames:c}=(0,Ie.An)(s);if(r.ItemizedCashbackExactMatch){const e=r.ItemizedCashbackExactMatch.pathname||(0,Ie.en)(r.ItemizedCashbackExactMatch.adsOffer.destinationUrl)?.pathname||"";r.ItemizedCashbackExactMatch.isActivated=c.has(e)}if(e){const i=(0,Ie.FL)(this.flyoutData,this.logModule,e);if(r.pdpActivatedData=i,r.pdpActivatedData){const{adsCashbackItem:i,currentPageProductId:n}=r.pdpActivatedData;if(i){const e=Ve.CreateFromPersonalizedOffer(i);e.isActivated=!0;const n=t.find((t=>{const i=t.pathname||(0,Ie.en)(t.adsOffer.destinationUrl)?.pathname||"";return t.pathname=i,t.pathname&&t.pathname===e.pathname}));n&&(r.ItemizedCashbackExactMatch&&r.RelatedOffers.push(r.ItemizedCashbackExactMatch),r.ItemizedCashbackExactMatch=e)}let o;r.RelatedOffers=r.RelatedOffers.filter((t=>{const i=(0,Ie.ru)(t.adsOffer.destinationUrl),r=(0,Ie.xJ)(new URL(i),e).productId===n;return r&&(o=t),!r})),r.ItemizedCashbackExactMatch||(r.ItemizedCashbackExactMatch=o)}}return r.RelatedOffers.forEach((e=>{const t=e.pathname||(0,Ie.en)(e.adsOffer.destinationUrl)?.pathname||"";e.isActivated=c.has(t)})),r.RelatedOffers=r.RelatedOffers.filter((e=>!e.isActivated)),r}catch(e){(0,we.F0)(this.flyoutData,this.logModule,"Error in GetSPBPDPData",e)}}async GetQtPdpData(){let e;const t=this.GetEntityData();try{const i=this.flyoutData.dataLoader.GetLoadTimeDataValue(l.a.ProductItemizedCashBack,void 0);if(i)e=bt.Create(i);else{const i=await this.storageHandler.getStorageString(Ce.Q.ICCurrentPageInfo);if(!(0,p.TF)(i))try{const n=JSON.parse(i);if(t.title=n.pageTitle||t.title,n&&n.type===ke.c.PDP){const t=n.cashbackData;e=bt.Create(t)}}catch(e){(0,we.F0)(this.flyoutData,this.logModule,"Error parsing currentPageInfo in GetQtPdpData",e)}}}catch(e){(0,we.F0)(this.flyoutData,this.logModule,"Error in GetQtPdpData",e)}return e&&(e.pdpData=t),e}GetEntityData(){const e=this.flyoutData.dataLoader.GetLoadTimeDataValue(l.a.ExtractedEntity,void 0);if(e){const t=e;return{title:t.title||"",description:t.description||"",entityName:t.entity?.name||"",price:t.entity?.price_value||""}}return{title:""}}async GetSPBSearchAndCategoryData(){let e,t=[],i="",n="",o=!1,r=!1;const a=await this.storageHandler.getStorageString(Ce.Q.ICCurrentPageInfo),s={};if((0,p.TF)(a))s.currentPageInfoIsEmpty=!0;else try{s.currentPageInfoIsEmpty=!1;const l=(0,we.rm)(a);if(!l)throw s.parsingError=!0,new Error("Error parsing currentPageInfo");i=l.type,s.pageInfoType=i;const c=l.type===ke.c.Search||l.type===ke.c.SearchSPB||l.type===ke.c.Category;if(s.isSearchOrCategoryPage=c,c){const i=this.apiResponse?.personalizedAdsResponse?.personalizedCashback;if(c){const a=l.cashbackData;if(e=a?.itemizedCashBackResponse?.adsMetadata,a?.itemizedCashBackResponse?.offersType===ve.h.SPB){s.offersType=ve.h.SPB;const e=(0,Ie.Sq)(a);if(l)if("search"===l.type||"searchSPB"===l.type){const r=l.query;s.query=r,r&&(n=r),t=(0,Ie.rP)(e,i),o=!0}else"category"===l.type&&(l.categoryName&&(n=l.categoryName),t=(0,Ie.rP)(e,i),r=!0)}}}}catch(e){(0,we.F0)(this.flyoutData,this.logModule,"error in GetSearchAndCategoryData",e,"",s)}return{cashbackItems:t,adsMetadata:e??new ye,pageInfoType:i,pageTitle:n,isSearch:o,isCategory:r}}async GetGroceryCashbackData(){try{if(this.flyoutData.common.isDiscoverPane)return;const e=[],t=new class{constructor(){(0,s.Z)(this,"Cashback",void 0),(0,s.Z)(this,"isPendingCashbackExists",!1),(0,s.Z)(this,"isAnonymousFlowEnabled",!1),(0,s.Z)(this,"pendingCashbackDetails",void 0),(0,s.Z)(this,"activatedCashbackData",[]),(0,s.Z)(this,"lastTransactionData",void 0),(0,s.Z)(this,"searchCategoryData",void 0),(0,s.Z)(this,"relatedOffers",[]),(0,s.Z)(this,"pdpOffer",void 0),(0,s.Z)(this,"renderedPageType",i.e4.Unknown),(0,s.Z)(this,"shouldRenderPdp",!1),(0,s.Z)(this,"isRelatedPdp",!1),(0,s.Z)(this,"cashbackItems",[]),(0,s.Z)(this,"removeCashbackItemsCount",0),(0,s.Z)(this,"categories",void 0),(0,s.Z)(this,"filteredCashbackItems",void 0),(0,s.Z)(this,"selectedCategoryId",""),(0,s.Z)(this,"useCategoryFiltering",!1),(0,s.Z)(this,"searchRequestTraceId",""),(0,s.Z)(this,"cashBackOffersTypeTitle",""),(0,s.Z)(this,"cashbackItemsOnSearchOrCategoryFiltered",[]),(0,s.Z)(this,"cashbackItemsOnSearchOrCategory",[]),(0,s.Z)(this,"cashBackOffersType",""),(0,s.Z)(this,"isDefaultOffersView",!0),(0,s.Z)(this,"CartCashbackNotification",void 0),this.isAnonymousFlowEnabled=!1,this.relatedOffers=[],this.renderedPageType=i.e4.HomePage,this.shouldRenderPdp=!1,this.isRelatedPdp=!1,this.cashbackItems=[],this.cashbackItemsOnSearchOrCategoryFiltered=[],this.cashbackItemsOnSearchOrCategory=[]}async PreprocessingViewModuleData(e,t){const i=this.Cashback?.SubmittedOfferIds?[...this.Cashback.SubmittedOfferIds]:[],{activatedItems:n,activatedItemsList:o}=await(0,we.ut)(t.common.domain,e),r=new Set([...n,...i]);this.RelatedOffersSearchOrPdpStrategy(e,t,r),this.HandlePdpScenario(this,e,t,n,o),this.HandleRenderedPageType(),await this.HandleSearchCategoryScenario(e,t),this.CategoryCashBackItemsStrategy(t,r)}HandlePdpScenario(e,t,i,n,o){const r=i.common.lastCommittedURL;for(const t of e.activatedCashbackData){const e=t.cashbackProducts.find((e=>r?.includes(e.url)));if(e)return this.pdpOffer=t,void(this.shouldRenderPdp=!0)}this.Cashback&&this.Cashback.pdpCashBack&&(this.isRelatedPdp=ft.IsRelatedPdpScenario(this),this.pdpOffer=vt.SelectOffer(this,t,i,n,o),this.shouldRenderPdp=Boolean(this.pdpOffer))}async HandleSearchCategoryScenario(e,t){const n=this.searchCategoryData;if((n?.renderedPageType===i.e4.SearchPage||n?.renderedPageType===i.e4.CategorySearchPage)&&(this.searchRequestTraceId=n?.requestTraceId,this.cashBackOffersTypeTitle=n?.cashBackOffersTypeTitle,void 0!==n?.useCategoryFiltering&&(this.useCategoryFiltering=n?.useCategoryFiltering),n?.cashbackItemsFromSearchAndCategory&&n?.cashbackItemsFromSearchAndCategory.length>0)){const i=n?.cashbackItemsFromSearchAndCategory.filter((e=>!this.Cashback?.ActivatedOffers.find((t=>t.id===e.id))));if(this.cashbackItemsOnSearchOrCategory=n?.cashbackItemsFromSearchAndCategory,this.cashbackItemsOnSearchOrCategory.length>0){this.cashBackOffersType="search",this.cashbackItemsOnSearchOrCategoryFiltered=i;const n=this.cashbackItemsOnSearchOrCategory.filter((e=>this.Cashback?.ActivatedOffers.find((t=>t.id===e.id))));await(0,we.t8)(t.common.domain,n,t.dataStoreModule.ApiData?.impressionId??"",e)}i&&i.length>0&&(this.isDefaultOffersView=!1)}}RelatedOffersSearchOrPdpStrategy(e,t,i){this.Cashback&&this.Cashback?.pdpCashBack&&this.Cashback?.pdpCashBack.relatedOffers.length>0&&this.Cashback?.pdpCashBack.relatedOffers.forEach((e=>{(0,we.dh)(e)&&!i.has(e.id)&&this.relatedOffers.push(e)}))}HandleRenderedPageType(){this.shouldRenderPdp?this.renderedPageType=i.e4.PdpPage:this.searchCategoryData?.renderedPageType!==i.e4.SearchPage&&this.searchCategoryData?.renderedPageType!==i.e4.CategorySearchPage||(this.renderedPageType=this.searchCategoryData?.renderedPageType)}CategoryCashBackItemsStrategy(e,t){this.categories=this.Cashback&&this.Cashback.Categories.size>0?this.Cashback.Categories:new Map,this.filteredCashbackItems=(0,we.KG)(e)||new Map,this.useCategoryFiltering=Boolean(this.categories&&this.categories.size>1),this?.Cashback?.ItemizedCashback?.forEach((e=>{(0,we.dh)(e)&&!t.has(e.id)?this.cashbackItems.push(e):this.removeCashbackItemsCount+=1}))}};let n=!1;if(this.flyoutData.common.openedWith===r.Te.Auto){if(this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK&&this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_GROCERY_ITEMIZED_CASHBACK_LANDING)return;n=!0}if(this.apiResponse?.itemLevelCashBack?.isCashBackEnabled||n){try{const n=this.flyoutData.common.domain,o=this.apiResponse?.itemLevelCashBack,r=this.flyoutData.dataStoreModule.ApiData?.impressionId??"",a=(0,we.SI)(this.flyoutData),l=new URL(this.flyoutData.common.lastCommittedURL);this.SetICVariationsData(),(0,h.Xo)(we.xs,""),t.searchCategoryData=await(0,we.S3)(this.storageHandler,this.flyoutData,l,this.logModule,a),await this.HandleActivatedOffers(n),this.PurgeShownOffers(n,r),(0,h.Mw)(we.d5)!==r&&((0,h.Xo)(we.aI,""),(0,h.Xo)(we.L4,""),(0,we.mS)(),xe.deleteActivatedTransactions());const c=xe.isPendingTransactionPresent(this.flyoutData.common.domain),d=(0,h.hS)(we.L4);(d.rebatesAmount<=0||!d.isActivated&&!c)&&(0,h.Xo)(we.L4,"");const u=(0,we.kf)(this.flyoutData,this.apiResponse?.itemLevelCashBack);this.flyoutData.dataStoreModule.UserInfo.isRebatesUser=u,(0,h.Xo)(we.d5,r);const g=new class{constructor(e,t,i,n){(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"logModule",void 0),this.flyoutData=t,this.logModule=i,this.pageHandlerModule=e,this.storageHandler=n??new Oe.Z(e,t.dataLoader,i)}async submitDataIfPresent(e){try{if(!e)return;if(!await this.storageHandler.getStorageBool(Ce.Q.ICConfirmationPending))return;const t=(0,we.FV)(this.flyoutData);if(!t.isConfirmationPage)return;const i=await this.getParsedPendingTransactionFromPersistentStorage(this.flyoutData.common.domain),n=i?.groceryOrder;if(n){const{activatedItems:e,activationTimestamp:i}=await this.getActivatedItemsAndTimestamp();if(!n)return;const o=this.calculateRebates(n.Products,e);if(o>0){if(this.addLastGroceryTransaction(o,void 0,t.purchaseIdFromUrl,!1),"processing"===(0,h.Mw)(we.xs))return;const r=await this.getAnid();await this.sendActivationRequest(n,e,i,r)?(this.addLastGroceryTransaction(o,!0,t.purchaseIdFromUrl,!1),this.clearingPurchaseStorage()):this.addLastGroceryTransaction(o,!1,t.purchaseIdFromUrl,!0)}}}catch(e){(0,we.F0)(this.flyoutData,this.logModule,"error in submitDataIfPresent",e)}}async submitDataIfPresentInPendingTransaction(e,t=""){try{const i=this.flyoutData.common.domain,n=await this.getParsedPendingTransactionFromPersistentStorage(i),o=n?this.GetPendingTransactionsToAdd(n,i):void 0,r=t||await this.getAnid();if(o){const t=this.addPendingTransactionToLocal(o);if(t?.errorSubmittingCount&&t.errorSubmittingCount>=3)return(0,h.Xo)(we.L4,""),xe.DeletePendingTransaction(i),n&&this.clearingPurchaseStorage(),void(0,we.F0)(this.flyoutData,this.logModule,"Pending transaction submit failed too many times. Removing",void 0,"",{pendingTransaction:t});this.addLastGroceryTransaction(o.pendingCashback,!1,o.purchaseIdFromUrl,!1),await this.submitTransaction(r,e,o)&&this.clearingPurchaseStorage()}else await this.submitPending(r,e),n&&this.clearingPurchaseStorage()}catch(e){(0,we.F0)(this.flyoutData,this.logModule,"error in submitDataIfPresent",e)}}addLastGroceryTransaction(e,t,i,n,o){const r={rebatesAmount:e,isActivated:t,transactionId:i,isError:n,isDuplicateError:o};(0,h.Xo)(we.L4,JSON.stringify(r))}GetPendingTransactionsToAdd(e,t){let i;const n=this.makeTitleMapFromKeyMap(e.groceryActivatedData.fullItems),o=this.calculateRebates(e.groceryOrder.Products,n);return o>0&&(i=this.makePendingTransactionForBackend(e,o,Pe.Z.getQuotientDate())),i}addPendingTransactionToLocal(e){if(!e.purchaseIdFromUrl)return void this.storageHandler.setStorageBool(Ce.Q.ICIsPendingTransactionPresent,!1);let t={addedTimestamp:e.addedTimestamp,pendingCashback:e.pendingCashback,purchaseIdFromUrl:e.purchaseIdFromUrl,subId:""};const i=xe.getPendingTransaction(this.flyoutData.common.domain);return i&&i.purchaseIdFromUrl===e.purchaseIdFromUrl&&(t=Ee(Ee({},i),t)),xe.addPendingTransaction(this.flyoutData.common.domain,t),this.storageHandler.setStorageBool(Ce.Q.ICIsPendingTransactionPresent,!0),t}makePendingTransactionForBackend(e,t,i){return{addedTimestamp:(0,be.u3)(),groceryActivatedData:e.groceryActivatedData,groceryOrder:e.groceryOrder,impressionId:this.flyoutData.dataStoreModule.ApiData?.impressionId??"",isSigninBeforePurchase:e.isSigninBeforePurchase??!1,lastCouponActivatedDate:Pe.Z.getQuotientDate(i),numberOfRetries:0,orderPlacementDate:Pe.Z.getQuotientDate(),pendingCashback:t,purchaseIdFromUrl:e.purchaseIdFromUrl,transactionId:e.transactionId}}async getAnid(){return(0,we.H)(this.pageHandlerModule)}PurgeSubmittedData(e,t,i){if(e&&e[t]&&e[t].fullItems)for(const n of i)delete e[t].fullItems[n]}clearPersistentStorage(){Object.keys(Ce.Q).forEach((e=>{this.storageHandler.setStorageString(e,"")}))}async submitAndActivateBackend(e){try{const{isSuccess:t,subId:n,isDuplicateError:o}=await(0,we.eg)(e);return t?(0,we.Rv)(this.flyoutData,this.logModule,i.xu.GroceryCashbackSubmitSuccess,"submitAndActivateBackend returned true","",{actionType:e.type,subId:n,pendingTransactionsToSubmitIds:e.pendingTransactionsToSubmitId,purchaseIdFromUrl:e.pendingTransaction?.purchaseIdFromUrl||""}):(0,we.F0)(this.flyoutData,this.logModule,"submitAndActivateBackend returned false","","",{actionType:e.type,subId:e.subId||"",pendingTransactionsToSubmitIds:e.pendingTransactionsToSubmitId,purchaseIdFromUrl:e.pendingTransaction?.purchaseIdFromUrl||"",isDuplicateError:o},i.xu.GroceryCashbackSubmitError),{isSuccess:t,subId:n,isDuplicateError:o}}catch(t){return(0,we.F0)(this.flyoutData,this.logModule,"submitAndActivateBackend threw error",t,"",{actionType:e.type,subId:e.subId||"",pendingTransactionsToSubmitIds:e.pendingTransactionsToSubmitId,purchaseIdFromUrl:e.pendingTransaction?.purchaseIdFromUrl||""},i.xu.GroceryCashbackSubmitError),{isSuccess:!1,subId:"",isDuplicateError:!1}}}async submitTransaction(e,t,i){const{request:n,submittedOfferIds:o}=this.createCashbackAPIRequest(i.groceryOrder,this.makeTitleMapFromKeyMap(i.groceryActivatedData.fullItems),Pe.Z.getQuotientDate(),e),r=this.createSubmitAndActivateRequest(e,"submit",i,n);return t||(r.Anid=""),await this.submitAndActivate(r,o,Boolean(e&&t))}async submitPending(e,t){const n=xe.getPendingTransaction(this.flyoutData.common.domain);if(!n)return;if(!e||!t){const o=`No anid or not a rebates user: IsAnid - ${!!e}, isRebatesUser - ${t}`;return void(0,we.F0)(this.flyoutData,this.logModule,o,"","",{actionType:"submitPending",subId:n.subId||"",pendingTransactionsToSubmitIds:n.purchaseIdFromUrl||"",purchaseIdFromUrl:n.purchaseIdFromUrl||"",isDuplicateError:!1},i.xu.GroceryCashbackSubmitError)}const o=this.createSubmitAndActivateRequest(e,"submitPending",void 0,void 0,n.purchaseIdFromUrl,n.subId);return await this.submitAndActivate(o,[],!0)}async submitAndActivate(e,t,i){if("processing"===(0,h.Mw)(we.xs))return;(0,h.Xo)(we.xs,"processing");const{isSuccess:n,subId:o,isDuplicateError:r}=await this.submitAndActivateBackend(e);if((0,h.Xo)(we.xs,"true"),n){if(i){const e=xe.pendingTransactionToActivatedTransactions(this.flyoutData.common.domain,o);e&&this.addLastGroceryTransaction(e.cashbackAmount,!0,e.purchaseIdFromUrl,!1,r),this.storageHandler.setStorageBool(Ce.Q.ICIsPendingTransactionPresent,!1)}else{const e=xe.addSubIdToPendingTransaction(this.flyoutData.common.domain,o);e&&this.addLastGroceryTransaction(e.pendingCashback,!1,e.purchaseIdFromUrl,!1,r)}await this.onActivateSuccess(t)}else{const e=xe.PendingTransactionErrorIncrement(this.flyoutData.common.domain);e&&this.addLastGroceryTransaction(e.pendingCashback,!1,e.purchaseIdFromUrl,!0,r),r&&(xe.DeletePendingTransaction(this.flyoutData.common.domain),this.storageHandler.setStorageBool(Ce.Q.ICIsPendingTransactionPresent,!1))}return n}async getParsedPendingTransactionFromPersistentStorage(e){const t=await this.storageHandler.getStorageString(Ce.Q.ICPendingTransaction);return(t?JSON.parse(t):{})[e]||void 0}async getActivatedItemsAndTimestamp(){const e=this.flyoutData.common.domain,t=(await(0,we.ut)(e,this.storageHandler)).activatedItemsMap,i=t?t[e]:void 0;return{activatedItems:i?.fullItems?this.makeTitleMapFromKeyMap(i.fullItems):{},activationTimestamp:""}}calculateRebates(e,t){let i=0;const n=new Set;try{if(e.length>0)for(const o of e){let e;const r=this.findMatchingTitleById(o,t);if(e=!t[o.productTitle]&&r?r:o.productTitle,t[e]){const r=t[e];(r.minQty??1)<=this.getProductQuantity(o.productQuantity)&&!n.has(e)&&(i+=Number(r.offerValue),n.add(e))}}}catch(e){(0,we.F0)(this.flyoutData,this.logModule,"error in calculateRebates",e)}return i}findMatchingTitleById(e,t){const i=this.flyoutData.common.domain,n=Te.Z.GetProductIdsFromUrl(`https://${i}${e.productUrl}`),o=Object.values(t).flatMap((e=>e.cashbackProducts)).filter((e=>{const t=[e.productId],i=Te.Z.GetProductIdsFromUrl(e.url);return t.push(...i),t?.some((e=>n.includes(e)))??!1}));return 0===o.length?null:o[0].title}async sendActivationRequest(e,t,i,n){(0,h.Xo)(we.xs,"processing");const{request:o,submittedOfferIds:r}=this.createCashbackAPIRequest(e,t,i,n),a=await(0,we.IJ)(o,n);return(0,h.Xo)(we.xs,a.success?"true":"false"),a.success&&await this.onActivateSuccess(r),a.success}async onActivateSuccess(e){try{const t=this.flyoutData.dataStoreModule.ApiData?.impressionId??"",i=[...this.flyoutData.dataStoreModule.GroceryCashbackData?.Cashback?.SubmittedOfferIds??[],...e],n=this.flyoutData.common.domain;(0,we.WY)(n,i,t);const o=(await(0,we.ut)(n,this.storageHandler)).activatedItemsMap;this.PurgeSubmittedData(o,n,i);const r=JSON.stringify(o);this.storageHandler.setStorageString(Ce.Q.GroceryCashbackActivated,r),this.flyoutData.dataStoreModule.GroceryCashbackData?.Cashback?.SubmittedOfferIds&&(this.flyoutData.dataStoreModule.GroceryCashbackData.Cashback.SubmittedOfferIds=i)}catch(e){}}clearingPurchaseStorage(){try{this.storageHandler.setStorageBool(Ce.Q.ICConfirmationPending,!1),this.storageHandler.clearDomainMappedStringStorage(Ce.Q.ICPendingTransaction,this.flyoutData.common.domain)}catch(e){(0,we.F0)(this.flyoutData,this.logModule,"error in clearingPurchaseStorage",e)}}createSubmitAndActivateRequest(e,t,i,n,o,r){return{Anid:e,domain:this.flyoutData.common.domain,muid:this.flyoutData.dataStoreModule.UserInfo.anonymousUserId,muidFromDevice:this.flyoutData.common.muid??"",pendingRequest:n,pendingTransaction:i?{addedTimestamp:i.addedTimestamp,purchaseIdFromUrl:i.purchaseIdFromUrl,transactionId:i.transactionId}:void 0,pendingTransactionsToSubmitId:o,subId:r,type:t}}createCashbackAPIRequest(e,t,i,n){const o=[],r=[],a=[];for(const i of e.Products){let e=i.productTitle;const n=this.findMatchingTitleById(i,t);e=!t[i.productTitle]&&n?n:i.productTitle;const s=t[e]??void 0;if(!s||!s.cashbackProducts||0===s.cashbackProducts.length||(0,p.TF)(s.id))continue;const l=s.cashbackProducts.find((t=>t.title===e)),c=l??s.cashbackProducts[0],d=s.id,u=c.upc??"";if((0,p.TF)(u))continue;if(a.includes(d))continue;const h={count:this.getProductQuantity(i.productQuantity),offerId:d,price:i.productPrice||this.extractPrice(c.price),soldBy:i.productSeller,title:e,upc:u};r.push(h),a.push(h.offerId),o.push(d)}const s={activationDate:Pe.Z.getQuotientDate(i),offers:a},l=this.flyoutData.common.domain,c=this.flyoutData.dataStoreModule.ApiData?.impressionId??"";return{request:{activateOffersBody:s,anid:n,domainName:l,estimatedShippingDate:e.ShipmentDate??"",estimatedTax:e.CartEstimatedTax,impressionId:c,grandTotal:e.OrderTotal,items:r,placementDate:Pe.Z.getQuotientDate(),totalBeforeTax:e.CartPreTax},submittedOfferIds:o}}getProductQuantity(e){let t=e;return-1===e&&(t=1),t}makeTitleMapFromKeyMap(e){const t={};return Object.values(e).forEach((e=>{e.cashbackProducts.length>0&&e.cashbackProducts.forEach((i=>{const n=i.title??"";n&&(t[n]=e)}))})),t}extractPrice(e){const t=e.match("(\\d+(\\.\\d+)?)|(\\.\\d+)");return t&&t.length>0?parseFloat(t[0]):null}}(this.pageHandlerModule,this.flyoutData,this.logModule,this.storageHandler);xe.removeOldOrFailingPendingTransaction(n);const m=Boolean(this.apiResponse?.clientInfo?.isOffTheRecord),v=Boolean(!m&&(this.apiResponse?.itemLevelCashBack?.isAnonymousFlowEnabled??!1));if(t.isAnonymousFlowEnabled=v,v){(0,we.w3)(this.flyoutData)||(0,we.mS)();const t=g.submitDataIfPresentInPendingTransaction(u);e.push(t)}else{const t=g.submitDataIfPresent(u);e.push(t)}if(u){t.Cashback=Tt.Create(o,this.flyoutData.common.domain),t.Cashback.pdpCashBack=await this.GetQtPdpData(),await this.PurgeSubmittedOffers(n,r,t);const e=await this.storageHandler.getStorageString(Ce.Q.ICNotificationType,!0);if(e===ke.c.CartPageNotification){const e=await this.storageHandler.getStorageString(Ce.Q.CartPageCashbackNotification,!0),i=JSON.parse(e);t.CartCashbackNotification=i}else e!==ke.c.ActivatedOffers&&(await this.PurgeActivatedOffers(t,n,r),await this.MergeActivatedOffers(t,n,r));t.activatedCashbackData=await this.GetActivatedCashbackItems(n,[])}else if(this.pageHandlerModule.TriggerExperiment(f.H.groceryAnonymous),v)if(xe.isPendingTransactionPresent(this.flyoutData.common.domain))t.isPendingCashbackExists=!0,t.pendingCashbackDetails=xe.getPendingTransaction(n);else{t.Cashback=Tt.Create(o,n),t.Cashback.pdpCashBack=await this.GetQtPdpData(),await(0,we.Li)(n,this.storageHandler);const{activatedItems:e,activatedItemsList:i}=await(0,we.ut)(n,this.storageHandler);if(e&&e.length>0)for(const n of e){const e=i[n];t.Cashback.ActivatedOffers.push(e)}t.activatedCashbackData=await this.GetActivatedCashbackItems(n,[])}const y=(0,h.hS)(we.L4);y.rebatesAmount&&y.isActivated&&(t.lastTransactionData=y),await t.PreprocessingViewModuleData(this.storageHandler,this.flyoutData)}catch(e){(0,we.F0)(this.flyoutData,this.logModule,"Log Error parsing grocery cash back data",e)}return e.length>0&&await Promise.all(e),t}}catch(e){(0,we.F0)(this.flyoutData,this.logModule,"Log Error parsing grocery cashabck data",e)}}async GetActivatedCashbackItems(e,t){const{activatedItems:i,activatedItemsList:n}=await(0,we.ut)(e,this.storageHandler),o=[];for(const e of i){const t=n[e];o.push(t)}return o.filter((e=>(0,we.dh)(e)&&!t.includes(e.id)))}async PurgeActivatedOffers(e,t,i){try{const n=(await(0,we.ut)(t,this.storageHandler)).activatedItemsMap;let o=!1;if(n&&(n[t]&&n[t].impressionId!==i&&(delete n[t],o=!0),!o&&n[t]&&n[t].fullItems)){const i=Object.keys(n[t].fullItems);for(const o of i)e.Cashback?.ActivatedOffers.find((e=>e.id===o))||e.Cashback?.ActivatedOffers.push(n[t].fullItems[o])}this.storageHandler.setStorageString(Ce.Q.GroceryCashbackActivated,JSON.stringify(n))}catch(e){}}async PurgeSubmittedOffers(e,t,i){const n=(0,h.hS)(we.sS);if(n){if(n[e]&&n[e].impressionId!==t){delete n[e];const t=JSON.stringify(n);(0,h.Xo)(we.sS,t)}if(n[e]&&n[e].submittedIds&&n[e].submittedIds.length>0)for(const t of n[e].submittedIds)i?.Cashback?.SubmittedOfferIds.includes(t)||i?.Cashback?.SubmittedOfferIds.push(t);(0,we.WY)(e,i?.Cashback?.SubmittedOfferIds||[],t)}}async PurgeShownOffers(e,t){const i=await this.storageHandler.getStorageString(Ce.Q.ICAutoShownOffers);try{let n={};i&&(n=JSON.parse(i)),n&&n[e]&&n[e].ImpressionId!==t&&delete n[e],this.storageHandler.setStorageString(Ce.Q.ICAutoShownOffers,JSON.stringify(n))}catch(e){}}async MergeActivatedOffers(e,t,i){const n=await(0,we.ut)(t,this.storageHandler);e?.Cashback?.ActivatedOffers&&e.Cashback?.ActivatedOffers?.length>0&&e.Cashback?.ItemizedCashback?.forEach(((o,r)=>{e?.Cashback?.ActivatedOffers.find((e=>e.id===o.id))&&!n?.activatedItems?.includes(o.id)&&(0,we.zJ)(t,o,i,this.storageHandler,n.activatedItemsMap)}))}async HandleActivatedOffers(e){if(await this.storageHandler.getStorageBool(Ce.Q.ICActivationMigrationPending)&&await this.storageHandler.getStorageString(Ce.Q.ICNotificationType)===ke.c.ActivatedOffers){const t=await(0,we.ut)(e,this.storageHandler);(0,we.QU)(this.flyoutData,this.pageHandlerModule,t.activatedItems),this.storageHandler.setStorageBool(Ce.Q.ICActivationMigrationPending,!1)}}GetViewedProductPriceDropData(){try{const e=this.flyoutData.dataLoader.GetLoadTimeDataValue("notification_data",void 0);if(e)return new class{constructor(e){if((0,s.Z)(this,"productShowItem",void 0),(0,s.Z)(this,"highestDropPercentageApiResponse",void 0),(0,s.Z)(this,"maxDropPercent",void 0),e&&e.userDataResponseList){for(const t of e.userDataResponseList)t.priceHistory&&t.priceHistory.product&&t.priceHistory.product.priceDropPercent&&(void 0===this.maxDropPercent||t.priceHistory.product.priceDropPercent>this.maxDropPercent)&&(this.maxDropPercent=t.priceHistory.product.priceDropPercent,this.highestDropPercentageApiResponse=t);this.highestDropPercentageApiResponse&&this.highestDropPercentageApiResponse.priceHistory&&(this.productShowItem=new class{constructor(e){(0,s.Z)(this,"domain",void 0),(0,s.Z)(this,"title",void 0),(0,s.Z)(this,"currencySymbol",void 0),(0,s.Z)(this,"productUrl",void 0),(0,s.Z)(this,"imageUrl",void 0),(0,s.Z)(this,"currentPrice",void 0),(0,s.Z)(this,"olderPrice",void 0),(0,s.Z)(this,"priceDropPercent",void 0),e&&e.product&&(this.domain=e.product.domain,this.title=e.product.title,this.currencySymbol=e.product.currencySymbol,this.productUrl=e.product.productUrl,this.imageUrl=e.product.imageUrl,this.currentPrice=e.product.currentPrice,this.olderPrice=e.product.olderPrice,this.priceDropPercent=e.product.priceDropPercent)}}(this.highestDropPercentageApiResponse.priceHistory))}}}(e)}catch(e){}}GetAbandonedCartData(){if(this.apiResponse){const e=this.apiResponse.abandonedCarts;if(e&&Object.keys(e).length>0){const t=new Map;return Object.keys(e).forEach((i=>{t.set(i,new Ne(e[i]))})),t}}}GetProductTrackingData(){return new ue.Z(this.apiResponse?.productTracking)}async GetOrderTrackingData(){try{const e=this.flyoutData.dataLoader.GetLoadTimeDataValue(l.a.PackageTrackingFreShown,void 0),t=this.flyoutData.dataLoader.GetLoadTimeDataValue(l.a.PackageTrackingUserConsented,void 0),i=this.flyoutData.dataLoader.GetLoadTimeDataValue(l.a.PackageTrackerResponse,void 0),n=await this.storageHandler.getStorageBool(Ce.Q.PriceMatchConsent)??!1,o=this.flyoutData.dataLoader.GetLoadTimeDataValue(l.a.ShouldShowPackageTrackingNotification,void 0),r=await ot.getPackageTrackingOrders(this.pageHandlerModule,this.storageHandler,i);return new class{constructor(e,t,i,n,o){(0,s.Z)(this,"packageTrackingFreShown",void 0),(0,s.Z)(this,"packageTrackingUserConsented",void 0),(0,s.Z)(this,"priceMatchingUserConsented",void 0),(0,s.Z)(this,"orders",void 0),(0,s.Z)(this,"shouldShowPackageTrackingNotification",void 0),this.packageTrackingFreShown=e??!1,this.packageTrackingUserConsented=t??!1,this.priceMatchingUserConsented=i??!1,this.orders=n,this.shouldShowPackageTrackingNotification=o??!1}}(e,t,n,r,o)}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);this.logModule.LogErrorEvent(i.R.EdgeFlyoutStatus,`Error parsing OrderStatusTracking data ${e}`,n)}}getDomainNameFromUrl(e){try{const t=new URL(e);let i;return t&&t.hostname&&(i=(0,T.uE)(t.hostname)),i}catch(e){}return null}GetPaymentOptionsData(){const e=this.flyoutData.dataLoader.GetLoadTimeDataValue("paymentOptions",void 0),t=[];return e&&e.length>0&&e.forEach((e=>{t.push(new class{constructor(e){(0,s.Z)(this,"providerName",void 0),(0,s.Z)(this,"projectedMonthlyPaymentDetails",void 0),(0,s.Z)(this,"paymentSuggestion",void 0),(0,s.Z)(this,"period",void 0),(0,s.Z)(this,"lowerThreshold",void 0),(0,s.Z)(this,"upperThreshold",void 0),(0,s.Z)(this,"amount",void 0),(0,s.Z)(this,"helpInformation",void 0),(0,s.Z)(this,"managePaymentLabel",void 0),(0,s.Z)(this,"managePaymentLinkText",void 0),e&&(this.providerName=e.providerName,this.projectedMonthlyPaymentDetails=e.projectedMonthlyPaymentDetails,this.paymentSuggestion=e.paymentSuggestion,this.period=e.period,this.lowerThreshold=e.lowerThreshold,this.upperThreshold=e.upperThreshold,this.amount=e.amount,this.helpInformation=e.helpInformation,this.managePaymentLabel=e.managePaymentLabel,this.managePaymentLinkText=e.managePaymentLinkText)}}(e))})),t}GetVirtualCardData(){const e=this.flyoutData.dataLoader.GetLoadTimeDataValue("virtualCard",void 0);return new class{constructor(e){(0,s.Z)(this,"cardNumber",void 0),(0,s.Z)(this,"cardHolderName",void 0),(0,s.Z)(this,"cardCVC",void 0),(0,s.Z)(this,"expires",void 0),(0,s.Z)(this,"billingInfo",void 0),(0,s.Z)(this,"isLinking",void 0),(0,s.Z)(this,"isLinkingSuccess",void 0),(0,s.Z)(this,"isAutofillSuccess",void 0),(0,s.Z)(this,"hasError",void 0),(0,s.Z)(this,"cardProvider",void 0),this.cardNumber=e?.cardNumber,this.cardHolderName=e?.cardHolderName,this.cardCVC=e?.cardCVC,this.expires=e?.expires,this.billingInfo=e?.billingInfo,this.isLinking=e?.isLinking,this.isLinkingSuccess=e?.isLinkingSuccess,this.isAutofillSuccess=this.parseIsAutofillSuccessMessage(e?.isAutofillSuccess),this.hasError=e?.hasError??null,this.cardProvider=e?.cardProvider}parseIsAutofillSuccessMessage(e){return"null"===e?null:"true"===e}}(e)}async GetIncentiveCampaignData(){let e;const t=this.flyoutData.common.muid,i=ge.A8.readUserInfoEndPoint;if(t){const t=await fetch(i,{headers:{Accept:"application/json","Content-Type":"application/json"},method:"GET"});if(t.ok){const i=await t.json();e=new ge.ZP(i),e.progress||(e.progress=new fe.O)}}return e}GetTrendingCouponsData(){if(this.apiResponse&&this.apiResponse?.trendingCoupons?.length>0)return ct.ParseAndCacheTrendingCoupons(this.apiResponse.trendingCoupons,this.pageHandlerModule)}GetSANConsentData(){const e=this.flyoutData.dataLoader.GetLoadTimeDataValue("personalization_data_consent",void 0),t=this.flyoutData.dataLoader.GetLoadTimeDataValue("personalization_in_context_can_prompt",void 0),i=this.flyoutData.dataLoader.GetLoadTimeDataValue("is_eu",void 0);return new class{constructor(e,t,i){(0,s.Z)(this,"PersonalizationDataConsent",void 0),(0,s.Z)(this,"PersonalizationInContextCanPrompt",void 0),(0,s.Z)(this,"IsEu",void 0),this.PersonalizationDataConsent=e,this.PersonalizationInContextCanPrompt=t,this.IsEu=i}}(e,t,i)}GetAutosData(){return this.apiResponse?new g(this.apiResponse.autos?.isAutosSupportedDomain,this.apiResponse.autos?.includePaths):new g(!1)}GetDiscoverData(){try{const e=this.flyoutData.dataLoader.GetLoadTimeDataValue(l.a.ShoppingDataContainer,void 0)||void 0;return Kt.Create(e,this.flyoutData,this.logModule,this.pageHandlerModule)}catch(e){return void(0,we.F0)(this.flyoutData,this.logModule,"Error in GetDiscoverData",e)}}GetUserInsightsData(){try{const e=this.flyoutData.dataLoader.GetLoadTimeDataValue(l.a.UserInsights,void 0);return new class{constructor(e){(0,s.Z)(this,"userReviewsFound",void 0),(0,s.Z)(this,"percentagePositiveReviews",void 0),(0,s.Z)(this,"percentageNegativeReviews",void 0),(0,s.Z)(this,"percentageNeutralReviews",void 0),(0,s.Z)(this,"sources",void 0),(0,s.Z)(this,"positiveAspects",void 0),(0,s.Z)(this,"negativeAspects",void 0),(0,s.Z)(this,"overallSentiment",void 0),e&&e?.user_reviews_found?(this.userReviewsFound=e?.user_reviews_found,this.percentagePositiveReviews=e?.percentage_positive_reviews,this.percentageNegativeReviews=e?.percentage_negative_reviews,this.percentageNeutralReviews=e?.percentage_neutral_reviews,this.sources=e?.sources,this.positiveAspects=e?.summary_of_positive_aspects,this.negativeAspects=e?.summary_of_negative_aspects,this.overallSentiment=e?.summary_of_overall_sentiment):this.userReviewsFound=!1}}(e)}catch(e){return}}GetExpertInsightsData(){if(e.R.isExperimentActive(f.H.expertInsights))try{const e=this.flyoutData.dataLoader.GetLoadTimeDataValue(l.a.ExpertInsights,void 0);return new class{constructor(e){(0,s.Z)(this,"expertReviewsFound",void 0),(0,s.Z)(this,"recommendationScore",void 0),(0,s.Z)(this,"expertInsightsSummary",void 0),e&&e?.expert_reviews_found?(this.expertReviewsFound=e?.expert_reviews_found,this.recommendationScore=e?.recommendation_score,this.expertInsightsSummary=e?.summary):this.expertReviewsFound=!1}}(e)}catch(e){return}}GetCjkSimilarProductsData(){const e=this.flyoutData.dataLoader.GetLoadTimeDataValue("similarProducts",void 0);return new class{constructor(e){if((0,s.Z)(this,"ProductData",void 0),this.ProductData=[],e&&e.length>0)for(const t of e)this.ProductData.push(new H(t))}}(e)}}(n,o,c).InitializeData(a)}GetEnabledServiceFeatures(e){let t=e.GetLoadTimeDataValue(l.a.EnabledServiceFeatures,void 0);return t&&Object.keys(t).length>0||(t=e.GetLoadTimeDataValue(l.a.EnabledServiceFeaturesv2,void 0)),t}}(r.AS.Desktop,o,y),b=new a.Z,S=new dt.ZP(Y_,y,C,b),w=new class{constructor(e,t,i){(0,s.Z)(this,"articlesCashbackNotificationModule",void 0),(0,s.Z)(this,"cashBackModule",void 0),(0,s.Z)(this,"unifiedCashBackModule",void 0),(0,s.Z)(this,"cashBackActivateModule",void 0),(0,s.Z)(this,"cashBackDelayedEnrollmentModule",void 0),(0,s.Z)(this,"deferredCashbackModule",void 0),(0,s.Z)(this,"couponsModule",void 0),(0,s.Z)(this,"bgaaModule",void 0),(0,s.Z)(this,"dealsModule",void 0),(0,s.Z)(this,"recommendationsModule",void 0),(0,s.Z)(this,"recommendationsNotificationModule",void 0),(0,s.Z)(this,"clippingModule",void 0),(0,s.Z)(this,"priceComparisonModule",void 0),(0,s.Z)(this,"priceHistoryModule",void 0),(0,s.Z)(this,"productSummaryCardModule",void 0),(0,s.Z)(this,"bannerModule",void 0),(0,s.Z)(this,"flyoutRendererModule",void 0),(0,s.Z)(this,"paneRendererModule",void 0),(0,s.Z)(this,"discoverPaneRendererModule",void 0),(0,s.Z)(this,"stateManagementModule",void 0),(0,s.Z)(this,"productHistoryModule",void 0),(0,s.Z)(this,"similarSellerModule",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"rewardModule",void 0),(0,s.Z)(this,"cashBackNotificationModule",void 0),(0,s.Z)(this,"unifiedCashbackNotificationModule",void 0),(0,s.Z)(this,"similarSellersNotificationModule",void 0),(0,s.Z)(this,"rewardNotificationModule",void 0),(0,s.Z)(this,"priceComparisonNotificationModule",void 0),(0,s.Z)(this,"paymentOptionsModule",void 0),(0,s.Z)(this,"postPurchaseConsentNotificationModule",void 0),(0,s.Z)(this,"virtualCardModule",void 0),(0,s.Z)(this,"virtualCardNotificationModule",void 0),(0,s.Z)(this,"viewedProductPriceDropNotificationModule",void 0),(0,s.Z)(this,"productTrackingOffersNotificationModule",void 0),(0,s.Z)(this,"discoverNotificationModule",void 0),(0,s.Z)(this,"feedbackModule",void 0),(0,s.Z)(this,"itemizedCashBackModule",void 0),(0,s.Z)(this,"itemizedCashBackNotificationModule",void 0),(0,s.Z)(this,"autosMarketplaceModule",void 0),(0,s.Z)(this,"autosMyGarageModule",void 0),(0,s.Z)(this,"autosReviewsModule",void 0),(0,s.Z)(this,"autosMarketplaceNotificationModule",void 0),(0,s.Z)(this,"autosReviewsModuleNotificationModule",void 0),(0,s.Z)(this,"priceHistoryNotificationModule",void 0),(0,s.Z)(this,"momentInTimeModule",void 0),(0,s.Z)(this,"trendingOffersModule",void 0),(0,s.Z)(this,"similarOffersModule",void 0),(0,s.Z)(this,"trendingOffersOnContextualTabModule",void 0),(0,s.Z)(this,"wishlistModule",void 0),(0,s.Z)(this,"campaignBannerModule",void 0),(0,s.Z)(this,"campaignPDPCashbackModule",void 0),(0,s.Z)(this,"campaignPDPCashbacNotificationModule",void 0),(0,s.Z)(this,"campaignAwarenessNotificationModule",void 0),(0,s.Z)(this,"campaignFeedModule",void 0),(0,s.Z)(this,"dailyDealsModule",void 0),(0,s.Z)(this,"visualSearchModule",void 0),(0,s.Z)(this,"relatedProductsModule",void 0),(0,s.Z)(this,"buyDirectModule",void 0),(0,s.Z)(this,"couponsNotificationModule",void 0),(0,s.Z)(this,"bgaaNotificationModule",void 0),(0,s.Z)(this,"productBestCouponNotificationModule",void 0),(0,s.Z)(this,"infiniteCategoryFeedModule",void 0),(0,s.Z)(this,"productCollectionsModule",void 0),(0,s.Z)(this,"shoppingTripsModule",void 0),(0,s.Z)(this,"abandonedCartModule",void 0),(0,s.Z)(this,"abandonedCartNotificationModule",void 0),(0,s.Z)(this,"priceDropPlusCashbackCompositeNotificationModule",void 0),(0,s.Z)(this,"cashbackPlusCouponsCompositeNotificationModule",void 0),(0,s.Z)(this,"lowerPricePlusCashbackPlusCouponsCompositeNotificationModule",void 0),(0,s.Z)(this,"productTrackingModule",void 0),(0,s.Z)(this,"productTrackingNotificationModule",void 0),(0,s.Z)(this,"clippingNotificationModule",void 0),(0,s.Z)(this,"activeRetailerInboxCouponsModule",void 0),(0,s.Z)(this,"trendingCouponsModule",void 0),(0,s.Z)(this,"trendingCouponsNotificationModule",void 0),(0,s.Z)(this,"sanConsentModule",void 0),(0,s.Z)(this,"sanConsentNotificationModule",void 0),(0,s.Z)(this,"discoverChatChipsModule",void 0),(0,s.Z)(this,"smartCompareModule",void 0),(0,s.Z)(this,"expertInsightsModule",void 0),(0,s.Z)(this,"productSummaryModule",void 0),(0,s.Z)(this,"buyingGuidesModule",void 0),(0,s.Z)(this,"cjkSimilarProductsModule",void 0),(0,s.Z)(this,"enrollRebatesConfirmationNotificationModule",void 0),(0,s.Z)(this,"searchBoxNotificationModuleModule",void 0),(0,s.Z)(this,"travelCheaperFlightsNotificationModule",void 0),(0,s.Z)(this,"travelCheaperFlightsModule",void 0),(0,s.Z)(this,"travelCheaperHotelsNotificationModule",void 0),(0,s.Z)(this,"postPurchaseRewardsNotificationModule",void 0),(0,s.Z)(this,"postPurchaseRewardsModule",void 0),this.flyoutData=e,this.utilities=t,this.commonAssets=i}GetArticlesCashbackNotificationModule(){return this.articlesCashbackNotificationModule||(this.articlesCashbackNotificationModule=new class{constructor(e,t){(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"telemetryHandler",void 0),(0,s.Z)(this,"storageUtilities",void 0),(0,s.Z)(this,"cashbackOffer",void 0),this.flyoutData=e,this.utilities=t.viewModulesUtilities,this.storageUtilities=t.storageHandler,this.logModule=t.logModule,this.pageHandlerModule=t.pageHandlerModule}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_ARTICLES_CASHBACK_NOTIFICATION]}PostProcessingNotification(e,t){}RenderNotification(){if(!this.cashbackOffer)return Promise.resolve(null);const e=this.cashbackOffer.sellerDomain?this.utilities.getFavIconSrc(this.cashbackOffer.sellerDomain,16):void 0,t=function(e,t,i,n,o,r){const a=e.cashbackInfo?.cashbackAmount,s=e.cashbackInfo?.cashbackPercentage,l=(0,Y.Ux)("msft-notification-competing-price-header");if(l.navigateToDestination=o,l.VisitItemButtonText=t.productTrackingViewItem,l.TitleText=t.commonSaveSimple,l.Savings=`${e.priceInfo.priceCurrencySymbol}${n(a)}`,l.RetailerName=e.seller,e.imageInfo?.sourceImageUrl){const t=e.imageInfo.sourceImageUrl.replace("edge://image?","");l.ProductImageUrl=t.replace("w=66&h=66","")}return e.description&&(l.ProductTitle=e.description),e.destinationUrl&&(l.ProductUrl=e.destinationUrl),r&&(l.FavIconImageUrl=r),l.adSlugSrc=i,l.adSlugAriaLabel=t.gcAd,l.slot="header-content",l.seeMoreOffersText=t.pcNotificationSeeMoreInfo,l.IsCashback=!0,l.CashbackStr=(0,T.fZ)("priceCompareCashBackShort",t.priceCompareCashBackShort,`${s}%`),l.CompetingPriceInImage=`${e.priceInfo.priceCurrencySymbol}${n(e.priceInfo.price)}`,l}(this.cashbackOffer,this.flyoutData.strings,this.flyoutData.common.resourcesEndpoint+"priceComparison/adSlug.png",this.utilities.formatPrice.bind(this.utilities),J.bind(this,this.cashbackOffer),e),i=this.utilities.createNotificationModule(t,this.GetNotificationName(),this);return Promise.resolve(i)}async ShouldRenderNotification(){if(this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_ARTICLES_CASHBACK_NOTIFICATION)return Promise.resolve(!1);if(!e.R.isExperimentActive(f.H.articlesCashbackNotification))return Promise.resolve(!1);const t=await this.storageUtilities.getStorageString(Ce.Q.ArticlesCashback);if(!t)return Promise.resolve(!1);let i;try{i=JSON.parse(t)}catch(e){return Promise.resolve(!1)}return i?.shoppingEntities?.length>0?(this.cashbackOffer=i.shoppingEntities[0],Promise.resolve(!0)):Promise.resolve(!0)}GetNotificationName(){return r.sM.ARTICLES_CASHBACK_NOTIFICATION}}(this.flyoutData,this.utilities)),this.articlesCashbackNotificationModule}GetEnrollRebatesConfirmationNotificationModule(){return this.enrollRebatesConfirmationNotificationModule||(this.enrollRebatesConfirmationNotificationModule=new class{constructor(e,t,i){(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"stateManagement",void 0),this.utilities=t.viewModulesUtilities,this.assets=new tg,this.pageHandlerModule=t.pageHandlerModule,this.flyoutData=e,this.stateManagement=i}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_MOMENT_IN_TIME]}PostProcessingNotification(e,t){this.stateManagement.addEventListener(Ku.e1.rebatesSignInPendingSuccess,(async e=>{e.stopImmediatePropagation();const t=document.querySelector("#divCashBackPopup"),i=this.CreateSuccessMessage();i&&t&&t.replaceWith(i);const n=await(0,we.H)(this.pageHandlerModule);setTimeout((async()=>{try{const e={Anid:n,MerchantName:this.flyoutData.common.domain},t={body:JSON.stringify(e),headers:{"Content-Type":"application/json"},method:"POST"},i="https://www.bing.com/api/shopping/v1/savings/cashback/enrollbonus",o=await fetch(i,t);await o.json()}catch(e){}}),5e3)}))}GetNotificationName(){return r.sM.ENROLL_TO_CASHBACK_CONFIRMATION_NOTIFICATION}ShouldRenderNotification(){this.pageHandlerModule.TriggerExperiment(f.H.enrollToRebateBonus);const t=e.R.isExperimentActive(f.H.enrollToRebateBonus),i=this.flyoutData.common.popupOrigination;return Promise.resolve(i===u.sR.AUTO_SHOW_MOMENT_IN_TIME&&t)}async RenderNotification(){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles());const e=(0,Y.Ux)("div",{id:"divCashBackPopup"});e.slot="header-content";const t=(0,Y.Ux)("DIV",{className:"lateralMargin"});t.id="divConfirmationCb";const i=(0,Y.Ux)("div",{id:"divCashBackTitle"}),n=(0,Y.Ux)("h2",{id:"h2RebatesTitle"}),o=this.utilities.createCommissionArrow("$20",!1,zu.h.Large);this.CreateCashBackHeaderText(n,!0,!1,o),i.appendChild(n),t.appendChild(i);const r=(0,Y.Ux)("p",{className:"txtSmall",style:"line-height: 20px; margin-top: 16px;"});r.textContent=this.flyoutData.strings.cbConfirmationEnrollBonusMessage,t.appendChild(r);const a=(0,Y.lw)(this.utilities);a.style.marginTop="12px",a.classList.add("lateralMargin"),t.appendChild(a),a.textContent=this.flyoutData.strings.cbEnrollBonusButtonText,a.addEventListener("click",(async()=>{await this.pageHandlerModule.ActivateRebates(!1)}));const s=this.createPrivacyMessage();return s.style.marginTop="12px",t.appendChild(s),e.appendChild(t),Promise.resolve(this.utilities.createNotificationModule(e,this.GetNotificationName(),this))}CreateSuccessMessage(){this.utilities.applyStyles(this.flyoutData.common.shopping,this.assets.getStyles());const e=(0,Y.Ux)("div",{id:"divCashBackPopup"});e.slot="header-content";const t=(0,Y.Ux)("DIV",{className:"lateralMargin"});t.id="divConfirmationCb";const i=(0,Y.Ux)("div",{id:"divCashBackTitle"}),n=(0,Y.Ux)("h2",{id:"h2RebatesTitle"});n.textContent=this.flyoutData.strings.EnrollSuccessTitle,i.appendChild(n),t.appendChild(i);const o=(0,Y.Ux)("span",{className:"txtSmall",style:"line-height: 20px; margin-top: 16px;"}),r=(0,Y.Ux)("fluent-anchor",{className:"aLinkCbenroll"});r.appearance="lightweight",r.href="#",r.textContent=this.flyoutData.strings.commonMicrosoftCashback,r.addEventListener("click",(()=>{this.pageHandlerModule.NavigateToBingRebatesHistory()})),o.textContent=this.flyoutData.strings.cbConfirmationEnrollBonusSuccessMessage.split("$1")[0],o.appendChild(r);const a=document.createTextNode(this.flyoutData.strings.cbConfirmationEnrollBonusSuccessMessage.split("$1")[1]);return o.appendChild(a),t.appendChild(o),e.appendChild(t),e}CreateCashBackHeaderText(e,t,i,n){const o=this.flyoutData.strings.cbEnrollBonusTitle;this.PopulateCreateCashBackHeaderHtml(e,o,n,!1)}PopulateCreateCashBackHeaderHtml(e,t,i,n){this.flyoutData.strings.cbMainTitleOffWithPdpCashbackEstimate===t||this.flyoutData.strings.cbMainTitleOffWithCashbackEstimate,(0,T.B7)(e,t,i),this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_REBATES_ORGANIC&&this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_REBATES_ORGANIC_NEW&&this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_REBATES_CHECKOUT&&this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_REBATES||(e.style.fontSize="21px",e.style.lineHeight="32px",e.style.fontWeight="600",this.utilities.shouldRenderSmallNotification()&&(e.style.fontSize="20px",e.style.lineHeight="28px"))}createPrivacyMessage(e="lightweight"){const t=(0,Y.Ux)("span",{id:"divPrivacyMessage",className:"txtSmall"}),i=(0,Y.Ux)("fluent-anchor",{className:"aLinkCb"});i.appearance=e,i.href="#",i.textContent=this.flyoutData.strings.commonMicrosoftRewards,i.addEventListener("click",(()=>{this.pageHandlerModule.NavigateToMicrosoftRewards()}));const n=(0,Y.Ux)("fluent-anchor",{className:"aLinkCb"});n.appearance=e,n.href="#",n.textContent=this.flyoutData.strings.cbPrivacyMessageTerm,n.addEventListener("click",(()=>{this.pageHandlerModule.NavigateToTermsStatementFlyout()}));const o=(0,Y.Ux)("fluent-anchor",{className:"aLinkCb"});return o.appearance=e,o.href="#",o.textContent=this.flyoutData.strings.cbPrivacyMessagePrivacyCookies,o.addEventListener("click",(()=>{this.pageHandlerModule.NavigateToPrivacyCookiesStatement()})),(0,T.B7)(t,this.flyoutData.strings.cbEnrollPrivacyMessage,i,n,o),t}}(this.flyoutData,this.utilities,this.stateManagementModule)),this.enrollRebatesConfirmationNotificationModule}GetCouponModule(){return this.couponsModule||(this.couponsModule=new uy(this.GetStateManagementModule(),this.flyoutData,this.utilities,this.commonAssets)),this.couponsModule}GetBGAAModule(){return this.bgaaModule||(this.bgaaModule=new py(this.flyoutData,this.utilities)),this.bgaaModule}GetDealsModule(){return this.dealsModule||(this.dealsModule=new xy(this.flyoutData,this.utilities)),this.dealsModule}GetRecommendationsModule(){return this.recommendationsModule||(this.recommendationsModule=new nk(this.flyoutData,this.utilities)),this.recommendationsModule}GetRecommendationsNotificationModule(){return this.recommendationsNotificationModule||(this.recommendationsNotificationModule=new ok(this.flyoutData,this.utilities)),this.recommendationsNotificationModule}GetSimilarSellerModule(){return this.similarSellerModule||(this.similarSellerModule=new iI(this.flyoutData,this.utilities,this.commonAssets)),this.similarSellerModule}GetDeferredCashbackModule(){if(!this.deferredCashbackModule){const e=Og.Z.initFactory(this.GetStateManagementModule(),this.flyoutData,this.utilities);this.deferredCashbackModule=new V_(this.flyoutData,this.utilities,e.getCashbackAvailableScenarious(),e.getCashbackLogger())}return this.deferredCashbackModule}GetCashBackModule(){return this.cashBackModule||(this.cashBackModule=new Pg(this.GetStateManagementModule(),this.flyoutData,this.utilities,this.commonAssets)),this.cashBackModule}GetUnifiedCashBackModule(){if(!this.unifiedCashBackModule)if(L_.isExperimentalFlight()){const e=L_.initFactory(this.GetStateManagementModule(),this.flyoutData,this.utilities);tn.getOrCreate().withPrefix("msft").register(D_(),R_()),this.unifiedCashBackModule=new MD(e.getCashbackLogger(),e.getCashbackAvailableScenarious(),e.getLocalizedStringsData(),e.getCashbackUIService(),e.getCasbackContext(),this.utilities,e.getCashbackFastInitializer())}else{const e=Og.Z.initFactory(this.GetStateManagementModule(),this.flyoutData,this.utilities);tn.getOrCreate().withPrefix("msft").register(KD(),E_()),this.unifiedCashBackModule=new _D(e.getCashbackLogger(),e.getCashbackAvailableScenarious(),e.getLocalizedStringsData(),e.getCashbackUIService(),e.getCasbackContext(),this.utilities,e.getCashbackFastInitializer())}return this.unifiedCashBackModule}GetCashBackActivateModule(){return this.cashBackActivateModule||(this.cashBackActivateModule=new Eg(this.GetStateManagementModule(),this.flyoutData,this.utilities,this.commonAssets)),this.cashBackActivateModule}GetCashBackDelayedEnrollmentModule(){return this.cashBackDelayedEnrollmentModule||(this.cashBackDelayedEnrollmentModule=new kg(this.GetStateManagementModule(),this.flyoutData,this.utilities,this.commonAssets)),this.cashBackDelayedEnrollmentModule}GetPriceComparisonModule(){return this.priceComparisonModule||(this.priceComparisonModule=new bS(this.GetStateManagementModule(),this.flyoutData,this.utilities)),this.priceComparisonModule}GetPriceHistoryModule(){return this.priceHistoryModule||(this.priceHistoryModule=new _E(this.GetStateManagementModule(),this.flyoutData,this.utilities)),this.priceHistoryModule}GetProductSummaryCardModule(){return this.productSummaryModule||(this.productSummaryCardModule=new XE(this.GetStateManagementModule(),this.flyoutData,this.utilities)),this.productSummaryCardModule}GetClippingModule(){return this.clippingModule||(this.clippingModule=new Gm(this.flyoutData,this.utilities,this.GetStateManagementModule(),this.commonAssets)),this.clippingModule}GetAutosReviewsModule(){return this.autosReviewsModule||(this.autosReviewsModule=new yp(this.GetStateManagementModule(),this.flyoutData,this.utilities)),this.autosReviewsModule}GetMomentInTimeModule(){return this.momentInTimeModule||(this.momentInTimeModule=DD.getStartShoppingModuleOrCreate(r.ModuleNames.MOMENT_IN_TIME,hS,this.flyoutData,this.utilities)),this.momentInTimeModule}GetTrendingOffersModule(){return this.trendingOffersModule||(this.trendingOffersModule=DD.getStartShoppingModuleOrCreate(r.ModuleNames.TRENDING_OFFERS,sC,this.flyoutData,this.utilities)),this.trendingOffersModule}GetTrendingOffersOnContextualTabModule(){return this.trendingOffersOnContextualTabModule||(this.trendingOffersOnContextualTabModule=DD.getStartShoppingModuleOrCreate(r.ModuleNames.TRENDING_OFFERS_ON_CONTEXTUAL_TAB,lC,this.flyoutData,this.utilities)),this.trendingOffersOnContextualTabModule}GetSimilarOffersModule(){return this.similarOffersModule||(this.similarOffersModule=new aC(this.flyoutData,this.utilities)),this.similarOffersModule}GetWishlistModule(){return this.wishlistModule||(this.wishlistModule=new bI(this.stateManagementModule,this.flyoutData,this.utilities)),this.wishlistModule}GetCampaignBannerModule(){return this.campaignBannerModule||(this.campaignBannerModule=new Wp(this.flyoutData,this.utilities)),this.campaignBannerModule}GetCampaignPDPCashbackModule(){return this.campaignPDPCashbackModule||(this.campaignPDPCashbackModule=new Ag(this.GetStateManagementModule(),this.flyoutData,this.utilities,this.commonAssets)),this.campaignPDPCashbackModule}GetCampaignPDPCashbackNotificationModule(){return this.campaignPDPCashbacNotificationModule||(this.campaignPDPCashbacNotificationModule=new rD(this.GetStateManagementModule(),this.flyoutData,this.utilities,this.commonAssets)),this.campaignPDPCashbacNotificationModule}GetCampaignAwarenessNotificationModule(){return this.campaignAwarenessNotificationModule||(this.campaignAwarenessNotificationModule=new class{constructor(e,t){(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),this.flyoutData=e,this.logModule=t.logModule,this.pageHandlerModule=t.pageHandlerModule,this.utilities=t.viewModulesUtilities,this.telemetryUtilities=t.telemetryHandler}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_CAMPAIGN_AWARENESS_NOTIFICATION]}async RenderNotification(e){const t=document.createElement("DIV"),n=document.createElement("DIV");n.className="campaign-banner",n.style.marginTop="-22px";const o=Vp(this.flyoutData.strings,this.flyoutData.common.resourcesEndpoint);o.style.justifyContent="center",o.style.padding="10px 0 0";const r=document.createElement("DIV");r.style.fontSize="14px",r.style.lineHeight="20px",r.style.fontWeight="600",r.style.textAlign="center",r.style.padding="10px 26px 0px",r.innerText=this.flyoutData.strings.dealDaysAwarenessTitle;const a=document.createElement("DIV");a.style.fontSize="12px",a.style.lineHeight="16px",a.style.textAlign="center",a.style.padding="4px 26px 12px",a.innerText=this.flyoutData.strings.dealDaysAwarenessSubtitle,n.appendChild(o),n.appendChild(r),n.appendChild(a);const s=document.createElement("DIV");s.style.margin="12px 16px 0";const l=document.createElement("BUTTON");l.className="campaign-shop-now-button",l.style.width="100%",l.style.padding="5px 0 7px",l.style.border="none",l.style.borderRadius="4px",l.style.fontSize="14px",l.style.lineHeight="20px",l.style.fontWeight="600",l.innerText=this.flyoutData.strings.mitButton,l.addEventListener("click",(()=>{this.pageHandlerModule.NavigateToUrl(Up);const e=new W.Z(i.$S.CampaignAwarenessBannerButton,this.telemetryUtilities.setContentViewed(this.GetNotificationName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"Deal Days shop now button clicked in pane banner",e),this.pageHandlerModule.RecordAsUserEngagement(q.FV.CAMPAIGN_AWARENESS_BANNER_BUTTON_CLICK,this.flyoutData.common.popupOrigination)})),s.appendChild(l),t.appendChild(n),t.appendChild(s);const c=new Fp;this.utilities.applyStyles(t,c.getStyles(),void 0,c.getDarkModeStyles());const d=this.utilities.createNotificationModule(t,this.GetNotificationName(),this);return Promise.resolve(d)}async ShouldRenderNotification(){const e=this.flyoutData.common.popupOrigination;return Promise.resolve(e===u.sR.AUTO_SHOW_CAMPAIGN_AWARENESS_NOTIFICATION&&!!this.flyoutData.dataStoreModule.CampaignData?.expData.isCampaignActive())}GetNotificationName(){return r.sM.CAMPAIGN_AWARENESS_NOTIFICATION}PostProcessingNotification(e,t){}}(this.flyoutData,this.utilities)),this.campaignAwarenessNotificationModule}GetCampaignFeedModule(){return this.campaignFeedModule||(this.campaignFeedModule=DD.getStartShoppingModuleOrCreate(r.ModuleNames.FEED_CAMPAIGN,tC,this.flyoutData,this.utilities)),this.campaignFeedModule}GetDailyDealsModule(){return this.dailyDealsModule||(this.dailyDealsModule=DD.getStartShoppingModuleOrCreate(r.ModuleNames.DAILY_DEALS,iC,this.flyoutData,this.utilities)),this.dailyDealsModule}GetVisualSearchModule(){return this.visualSearchModule||(this.visualSearchModule=new dC(this.flyoutData,this.utilities)),this.visualSearchModule}GetRelatedProductsModule(){return this.relatedProductsModule||(this.relatedProductsModule=new oC(this.flyoutData,this.utilities)),this.relatedProductsModule}GetBuyDirectModule(){return this.buyDirectModule||(this.buyDirectModule=DD.getStartShoppingModuleOrCreate(r.ModuleNames.BUY_DIRECT,Qy,this.flyoutData,this.utilities)),this.buyDirectModule}GetInfiniteCategoryFeedModule(){return this.infiniteCategoryFeedModule||(this.infiniteCategoryFeedModule=DD.getStartShoppingModuleOrCreate(r.ModuleNames.INFINITE_CATEGORY_FEED,nC,this.flyoutData,this.utilities)),this.infiniteCategoryFeedModule}GetBannerModule(){return this.bannerModule||(this.bannerModule=new class{constructor(t,i,n,o,r,l,c){(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pagehandlerModule",void 0),(0,s.Z)(this,"data",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"classBtnBannerPrimary","btnBannerPrimary"),(0,s.Z)(this,"classSpanCouponCode","spanCouponCode"),(0,s.Z)(this,"classDivActionButtonWrapper","divActionButtonWrapper"),(0,s.Z)(this,"idMainDiv","mainDiv"),(0,s.Z)(this,"idContent","divContent"),(0,s.Z)(this,"classTitle","divTitle"),(0,s.Z)(this,"classBtnViewMorePrices","viewMorePricesButton"),(0,s.Z)(this,"classBtnBannerClose","btnBannerClose"),(0,s.Z)(this,"classTxtSmall","txtSmall"),(0,s.Z)(this,"classCopiedIndicator","copiedIndicator"),(0,s.Z)(this,"classActionsButton",a.q.Primary),(0,s.Z)(this,"cashBackModule",void 0),(0,s.Z)(this,"priceHistoryModule",void 0),(0,s.Z)(this,"priceComparisonModule",void 0),(0,s.Z)(this,"isCouponsExperimentActive",void 0),(0,s.Z)(this,"pcBannerUXConfig",void 0),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"commonAssets",void 0),this.logModule=l.logModule,this.pagehandlerModule=l.pageHandlerModule,this.cashBackModule=t,this.priceComparisonModule=i,this.priceHistoryModule=n,this.data=o,this.stateManagement=r,this.utilities=l.viewModulesUtilities,this.assets=new Cp,this.commonAssets=c,this.isCouponsExperimentActive=e.R.isExperimentActive(f.H.bannerShowCoupons),this.pcBannerUXConfig=new class{constructor(t,i,n,o){(0,s.Z)(this,"ExperimentActive",!1),(0,s.Z)(this,"ContentImageFile",void 0),(0,s.Z)(this,"ContentImageSize",void 0),(0,s.Z)(this,"TitleDivMarginLeft",void 0),(0,s.Z)(this,"ContentDivMarginRight",void 0),(0,s.Z)(this,"TitleDivSwapElementOrder",!1),(0,s.Z)(this,"AddConfetti",!1),(0,s.Z)(this,"UseSavingsTextGradient",!1),(0,s.Z)(this,"ShowTitleInWhite",!1),(0,s.Z)(this,"ClassName",void 0),(0,s.Z)(this,"UseWhiteCloseButton",!1),(0,s.Z)(this,"FlyoutData",void 0),(0,s.Z)(this,"PageHandlerModule",void 0),(0,s.Z)(this,"CommonAssets",void 0),this.FlyoutData=i,this.PageHandlerModule=t,this.CommonAssets=o,e.R.isPCBannerUXExperimentActive()&&(this.ExperimentActive=!0,e.R.isExperimentActive(f.H.pcBannerUXExperimentation1)?(this.ClassName="bannerBackground1",this.TitleDivMarginLeft=19,this.ContentDivMarginRight=58,this.ContentImageFile="Emoji.png",this.ContentImageSize=32,this.UseSavingsTextGradient=!0):e.R.isExperimentActive(f.H.pcBannerUXExperimentation2)?(this.ClassName="bannerBackground2",this.TitleDivMarginLeft=19,this.ContentDivMarginRight=58,this.AddConfetti=!0,this.UseSavingsTextGradient=!0):e.R.isExperimentActive(f.H.pcBannerUXExperimentation3)?(this.ClassName="bannerBackground3",this.TitleDivMarginLeft=375,this.ContentDivMarginRight=187,this.UseWhiteCloseButton=!0,this.ShowTitleInWhite=!0):e.R.isExperimentActive(f.H.pcBannerUXExperimentation4)?(this.ClassName="bannerBackground4",this.TitleDivMarginLeft=112,this.ContentDivMarginRight=58,this.TitleDivSwapElementOrder=!0,this.UseWhiteCloseButton=!0,this.ShowTitleInWhite=!0):e.R.isExperimentActive(f.H.pcBannerUXExperimentation5)?(this.ClassName="bannerBackground5",this.TitleDivMarginLeft=19,this.ContentDivMarginRight=58,this.ContentImageFile="ClappingHands.png",this.ContentImageSize=36,this.UseSavingsTextGradient=!0):e.R.isExperimentActive(f.H.pcBannerUXExperimentation6)&&(this.ExperimentActive=!0,this.ClassName="bannerBackground6"))}TriggerActiveExperiment(){this.ExperimentActive&&(e.R.isExperimentActive(f.H.pcBannerUXExperimentation1)?this.PageHandlerModule.TriggerExperiment(f.H.pcBannerUXExperimentation1):e.R.isExperimentActive(f.H.pcBannerUXExperimentation2)?this.PageHandlerModule.TriggerExperiment(f.H.pcBannerUXExperimentation2):e.R.isExperimentActive(f.H.pcBannerUXExperimentation3)?this.PageHandlerModule.TriggerExperiment(f.H.pcBannerUXExperimentation3):e.R.isExperimentActive(f.H.pcBannerUXExperimentation4)&&this.PageHandlerModule.TriggerExperiment(f.H.pcBannerUXExperimentation4))}RenderViewAllButton(t,i){function n(e,t){const i=e.querySelector("path");null!==i&&(i.style.fill=t)}let o=0;if(e.R.isExperimentActive(f.H.pcBannerUXExperimentation1)||e.R.isExperimentActive(f.H.pcBannerUXExperimentation2))o=20,t.innerHTML=this.CommonAssets.getArrowButtonIcon(),n(t,"#FA003C"),t.style.marginRight="-10px";else if(e.R.isExperimentActive(f.H.pcBannerUXExperimentation3))o=8,t.innerHTML=(new Cp).getWhiteTriangleButtonIcon();else if(e.R.isExperimentActive(f.H.pcBannerUXExperimentation4)){t.id="viewMorePricesButton",t.innerText=this.FlyoutData.strings.viewMorePricesButtonText,t.style.color="white";const e=(0,Y.Ux)("DIV");e.innerHTML=this.CommonAssets.getArrowButtonIcon(),n(e,"#FFFFFF"),e.style.float="right",e.style.marginLeft="14px",t.appendChild(e)}else e.R.isExperimentActive(f.H.pcBannerUXExperimentation5)&&(o=20,t.innerHTML=this.CommonAssets.getArrowButtonIcon(),n(t,"#FA003C"),t.style.marginRight="-10");if(t.style.backgroundColor="transparent",t.style.border="none",o>0){const e=t.querySelector("SVG");e&&(e.setAttribute("width",o.toString()),e.setAttribute("height",o.toString()))}}}(this.pagehandlerModule,o,this.utilities,this.commonAssets)}async renderBanner(){const e=document.querySelector("#divContentWrapper");if(e){this.utilities.applyStyles(e,this.assets.getStyles());const n=(0,Y.Ux)("fluent-design-system-provider");this.pcBannerUXConfig.ExperimentActive&&this.pcBannerUXConfig.ClassName?n.className=this.pcBannerUXConfig.ClassName:this.utilities.isDarkMode()?n.setAttribute("background-color","#4a4a4a"):n.setAttribute("background-color","#F7F7F7"),n.id=this.idMainDiv;const o=this.populateMainHeader(),a=await this.getModuleToRender(),s=(0,Y.Ux)("DIV");s.id=this.idContent,this.pcBannerUXConfig.ExperimentActive&&(s.style.display="flex");const l=(0,Y.Ux)("P",{style:"font-weight: 600"});let c;l.className=this.classTxtSmall,this.createBannerContent(a,s,l),this.createBannerMenu(s),n.appendChild(o),n.appendChild(s),e.appendChild(n),n.addEventListener("click",(()=>{this.pagehandlerModule.ShowFlyoutFromBanner(r.Te.Mouse)})),n.addEventListener("mouseover",(()=>{c=setTimeout((()=>{this.pagehandlerModule.ShowFlyoutFromBanner(r.Te.Mouse)}),500)})),n.addEventListener("mouseout",(()=>{c&&clearTimeout(c)}));const d=new t.Z(i.xu.BannerRendered);this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,`user saw banner with ${a}`,d),this.pagehandlerModule.OnBannerLoad();const u=document.querySelector("."+this.classBtnViewMorePrices);u&&u.addEventListener("keydown",(e=>{"Enter"===e.key&&this.pagehandlerModule.ShowFlyoutFromBanner(r.Te.Keyboard),e.stopPropagation()})),document.addEventListener("visibilitychange",(e=>{"hidden"===document.visibilityState?(0,h.Xo)("banneropen","false"):"visible"===document.visibilityState&&(0,h.Xo)("banneropen","true")}))}}populateMainHeader(){const e=(0,Y.Ux)("DIV",{style:"display:flex;"}),t=(0,Y.Ux)("DIV",{style:"float:left;"});t.className=this.classTitle,this.pcBannerUXConfig.ExperimentActive&&(t.style.marginLeft=this.pcBannerUXConfig.TitleDivMarginLeft.toString()+"px");const i=(0,Y.Ux)("DIV");i.setAttribute("aria-hidden","true"),i.innerHTML=this.commonAssets.getHeaderIcon();const n=i.querySelector("SVG");n&&(n.setAttribute("width","26px"),n.setAttribute("height","26px"));const o=(0,Y.Ux)("H1",{style:"font-weight: 600; color: #000000;"});if(o.className=this.classTxtSmall,o.textContent=this.data.strings.commonFixedTitle,this.pcBannerUXConfig.TitleDivSwapElementOrder?(t.appendChild(o),t.appendChild(i)):(t.appendChild(i),t.appendChild(o)),e.appendChild(t),this.pcBannerUXConfig.AddConfetti){const t=(0,Y.Ux)("DIV",{style:"float:left;"});t.setAttribute("aria-hidden","true"),t.innerHTML=this.assets.getBannerConfettiImage(),t.style.marginLeft="40",t.className=this.classTitle,e.appendChild(t)}return e}createBannerMenu(e){const t=this.pcBannerUXConfig.UseWhiteCloseButton?this.assets.getCloseButtonSeparatorCssWhite():this.assets.getCloseButtonSeparatorCss(),n=(0,Y.Ux)("DIV",{style:t});e.appendChild(n);const o=document.createElement("fluent-button");let a;o.setAttribute("aria-label",this.data.strings.commonClose),o.id=r.z6.CLOSE,o.className=this.classBtnBannerClose,o.style.marginLeft="-15px",o.style.color="#000000",this.pcBannerUXConfig.UseWhiteCloseButton?o.innerHTML=this.assets.getCloseButtonWhite():o.innerHTML=this.commonAssets.getCloseButton(),o.addEventListener("click",(()=>{a=new W.Z(i.$S.BannerDismiss,bp.r.BANNER),this.logModule.LogInfoEvent(i.R.ButtonClick,"Banner Dismissed",a),this.pagehandlerModule.DismissBanner()}));const s=o.querySelector("SVG");s&&s.setAttribute("aria-hidden","true"),e.appendChild(o)}async getModuleToRender(){return this.pcBannerUXConfig.TriggerActiveExperiment(),this.pagehandlerModule.TriggerExperiment(f.H.bannerShowCoupons),this.stateManagement.getState(Ku.IY.topModuleName)===r.ModuleNames.COUPON&&this.isCouponsExperimentActive,r.ModuleNames.COUPON}createBannerContent(e,t,i){switch(e){case r.ModuleNames.PRICECOMPARISON:this.renderPriceComparison(t,i);break;case r.ModuleNames.CASHBACK:this.renderCashBack(t,i);break;case r.ModuleNames.PRICEHISTORY:this.renderPriceHistory(t,i);break;case r.ModuleNames.COUPON:default:this.renderCoupons(t,i)}}createBannerTitle(e,t,i,n){if(t&&t.length>0){const o=window.trustedTypes.emptyHTML;if(e.innerHTML=o,e.textContent=t[0],this.pcBannerUXConfig.ExperimentActive&&(e.className="bannerMainTitleAlt"),t.length>1){const o=(0,Y.Ux)(i,n);o.textContent=t[1],e.appendChild(o)}if(t.length>2){const i=(0,Y.Ux)("P",{style:"display: inline;"});i.textContent=t[2],e.appendChild(i)}}}getCouponTextInfo(e,t){if(e.Coupons[0].successRate>=75)if(e.Coupons.length>1&&(e.Coupons[1].successRate<75||!e.Coupons[1].successRate)){let n=(0,T.dK)(this.data.strings.bannerCouponTitle,i.T4.One);n=(0,T.fZ)("bannerCouponTitle",n,e.Coupons[0].successRate.toString());const o=n.split("|");this.createBannerTitle(t,o,"B")}else{let n=e.Coupons[0].successRate;e.Coupons.length>1&&e.Coupons[0].successRate>e.Coupons[1].successRate&&(n=e.Coupons[1].successRate);let o=(0,T.dK)(this.data.strings.bannerCouponTitle,i.T4.Other);o=(0,T.fZ)("bannerCouponTitle",o,n.toString());const r=o.split("|");this.createBannerTitle(t,r,"B")}else if(1===e.Coupons.length){const e=(0,T.dK)(this.data.strings.bannerCouponHeadingLabel,i.T4.One).split("|");this.createBannerTitle(t,e,"P",{style:"display: inline; font-size:14px; font-weight:bold;"})}else{const n=(0,T.dK)(this.data.strings.bannerCouponHeadingLabel,i.T4.Other,e.Coupons.length).split("|");this.createBannerTitle(t,n,"P",{style:"display: inline; font-size:14px; font-weight:bold;"})}}renderCoupons(e,t){const n=this.data.dataStoreModule.CouponData;if(n&&n.Coupons&&n.Coupons.length>0){this.getCouponTextInfo(n,t),e.appendChild(t);let o=2;n.Coupons.length<o&&(o=n.Coupons.length);const a=this.data.strings.commonLearnMore,s=n.Coupons[0].successRate>=75??!1;for(let t=0;t<o;t++)s&&n.Coupons[t].successRate>=75?this.createCouponCodeButtons(n,a,t,e):s||this.createCouponCodeButtons(n,a,t,e);const l=document.createElement("fluent-button");n.Coupons.length>1?l.textContent=(0,T.dK)(this.data.strings.bannerViewAllCouponsStr,i.T4.Other,n.Coupons.length):l.textContent=(0,T.dK)(this.data.strings.bannerViewAllCouponsStr,i.T4.One),l.addEventListener("click",(()=>{this.pagehandlerModule.StartShopping(r.Te.Banner,"viewAll")})),e.appendChild(l)}}createCouponCodeButtons(e,t,i,n){const o=this.createBannerButtonWrapper(e.Coupons[i].couponCode+" "+this.data.strings.couponCopyLabel),a=(0,Y.Ux)("BUTTON");a.className=this.classBtnBannerPrimary;const s=(0,Y.Ux)("SPAN");if(s.className=this.classSpanCouponCode,s.textContent=e.Coupons[i].couponCode,s.style.display="none",t.length>e.Coupons[i].couponCode.length){a.textContent=t,o.appendChild(a);const n=this.createHoverDiv(e.Coupons[i].couponCode,!1);n&&o.appendChild(n)}else{a.textContent=e.Coupons[i].couponCode,o.appendChild(a);const n=this.createHoverDiv(t,!0);n&&o.appendChild(n)}o.appendChild(s),n.appendChild(o),this.manageBannerEvents(o,r.ModuleNames.COUPON)}renderPriceComparison(e,t){const i=this.data.dataStoreModule.PriceComparisonData;if(i&&i.CompetingPrices&&i.CompetingPrices.length>0){let n,o=i.CompetingPrices[0].IntendedPrice,a=i.CompetingPrices[0].SellerName,s=i.CompetingPrices[0];if(-1!==i.Price&&i.CompetingPrices.forEach((e=>{const t=e.IntendedPrice;t&&o&&t<o&&(o=t,a=e.SellerName,s=e)})),o&&(n=i.Price-o),n>1){if(this.pcBannerUXConfig.ExperimentActive&&this.pcBannerUXConfig.ContentImageFile){const t=(0,Y.Ux)("DIV");t.style.width=this.pcBannerUXConfig.ContentImageSize.toString()+"px",t.style.height=this.pcBannerUXConfig.ContentImageSize.toString()+"px",t.setAttribute("aria-hidden","true"),t.style.background=`url( "${this.data.common.resourcesEndpoint}banner/${this.pcBannerUXConfig.ContentImageFile}") no-repeat`,e.appendChild(t)}const i=(this.pcBannerUXConfig.ExperimentActive?this.data.strings.bannerFoundBestPriceAlt:this.data.strings.bannerFoundBestPrice).split("|");if(t.style.fontWeight="400",t.style.color="#000000",this.createBannerTitle(t,i,"P",{style:"display: inline; font-weight:bold; font-size:14px;"}),e.appendChild(t),this.pcBannerUXConfig.ExperimentActive){const i=(0,Y.Ux)("DIV",{style:"top: 0px; position: fixed; opacity: 0; pointer-events: none;"});i.setAttribute("aria-live","assertive"),e.appendChild(i),i.innerText=this.data.strings.pcNotificationNarratorIntro+this.data.strings.commonFixedTitle+". "+this.data.strings.bannerFoundBestPriceAlt+" "+(0,T.fZ)("pcNotificationTitle",this.data.strings.pcNotificationTitle,`${s.CurrencySymbol}${n.toFixed(2)}`);const o=(0,Y.Ux)("DIV",{style:"display:flex; grid-gap:5px;font-weight: 600;"}),r=this.pcBannerUXConfig.UseSavingsTextGradient?"background: linear-gradient(to right, #D0006A, #FF6B00);\n color: transparent;\n -webkit-background-clip: text;":"color: white;\n font-weight: 600;",a=(0,Y.Ux)("DIV",{style:r});a.innerText=this.data.strings.commonYouCanSave,a.className="bannerMainTitleAlt",o.appendChild(a);const l=`${s.CurrencySymbol}${n.toFixed(2)}`;if(this.pcBannerUXConfig.UseSavingsTextGradient)a.innerText+=" "+l;else{const e=(0,Y.Ux)("DIV",{style:"font-weight: bold; color: orange;"});e.textContent=l+"!",e.className="bannerMainTitleAlt",e.style.fontWeight="bold",o.appendChild(e)}this.pcBannerUXConfig.ShowTitleInWhite&&(t.style.color="white"),e.appendChild(o)}else{const t=this.data.strings.bannerVisitItem,i=(0,T.fZ)("bannerVisitItem",this.data.strings.bannerSave,`${s.CurrencySymbol}${n.toFixed(2)}`,a),o=this.createBannerButtonWrapper(i+" "+t),l=(0,Y.Ux)("BUTTON");if(l.className=this.classBtnBannerPrimary,t.length>i.length){l.textContent=t;const e=this.createHoverDiv(i,!1);o.appendChild(l),o.appendChild(e)}else{l.textContent=i;const e=this.createHoverDiv(t,!0);o.appendChild(l),o.appendChild(e)}e.appendChild(o),this.manageBannerEvents(o,r.ModuleNames.PRICECOMPARISON,s)}}else{const i=this.data.strings.bannerYouHaveBestPrice.split("|");this.createBannerTitle(t,i,"P",{style:"display: inline; font-weight:bold; font-size:14px;"}),e.appendChild(t)}this.renderPCBannerViewAllButton(e,n>0)}}renderPCBannerViewAllButton(e,t){let i;this.pcBannerUXConfig.ExperimentActive?(i=document.createElement("BUTTON"),i.setAttribute("aria-label","Find better prices"),i.classList.add(this.classBtnViewMorePrices),this.pcBannerUXConfig.RenderViewAllButton(i,this.data.common.resourcesEndpoint)):(i=document.createElement("fluent-button"),i.classList.add(this.classBtnViewMorePrices),i.textContent=t?this.data.strings.bannerViewAll:this.data.strings.pcPriceSectionTitle),e.appendChild(i)}renderCashBack(e,t){const n=this.utilities.retrieveCashBackAmount().cashBackAmount;if(n){let o=this.data.strings.bannerCashBackOffTitle;o=(0,T.fZ)("bannerCashBackOffTitle",o,n);let r=o.split("|");this.createBannerTitle(t,r,"B"),e.appendChild(t);const a=(0,Y.Ux)("fluent-button");this.styleDefaultState(a),a.textContent=this.data.strings.cbActivateButtonRefresh,a.addEventListener("click",(async e=>{await this.cashBackModule.handleActivateCashbackClick(a,e,"Cash back activated from banner")?(this.cashBackModule.cashbackStyles.styleActivatedState(a),o=this.data.strings.bannerCashBackOnTitle,o=(0,T.fZ)("bannerCashBackOnTitle",o,n),r=o.split("|"),this.createBannerTitle(t,r,"B")):this.styleDefaultState(a)})),e.appendChild(a);const s=document.createElement("fluent-button");s.textContent=this.data.strings.bannerSeeDetails,s.addEventListener("click",(()=>{const e=new W.Z(i.$S.RebatesLearnMore,bp.r.CASHBACK_RETAILER);this.pagehandlerModule.RecordAsUserAction(K.bS.REBATES_LEARN_MORE),this.logModule.LogInfoEvent(i.R.ButtonClick,"User navigated to rebates see details from banner",e,Jl.g.CouponImpressionId),this.pagehandlerModule.NavigateToLearnMore(ju.$.NEW_FOREGROUND_TAB)})),e.appendChild(s)}}renderPriceHistory(e,t){const i=this.data.dataStoreModule.PriceHistoryData;if(i&&i.CurrentPrice&&i.DailyPrices&&i.DailyPrices.length>1){const n=i.getPriceHistoryType(),o=this.priceHistoryModule.createPriceHistoryTypeIllustration(n,!0);e.appendChild(o);const a=i.ProductDetails&&i.ProductDetails.currency&&""!==i.ProductDetails.currency?i.ProductDetails.currency:"$",s=this.priceHistoryModule.getPriceDifference(i,n);let l;switch(n){case de.sh.PRICEDROP:s&&(l=this.data.strings.bannerPriceDropTitle,l=(0,T.fZ)("bannerPriceDropTitle",l,`${a}${s.toFixed(2)}`));break;case de.sh.PRICEINCREASE:s&&(l=this.data.strings.bannerPriceIncreaseTitle,l=(0,T.fZ)("bannerPriceIncreaseTitle",l,`${a}${s.toFixed(2)}`));break;case de.sh.FAIRPRICE:default:l=this.data.strings.bannerPriceStableTitle}const c=l.split("|");this.createBannerTitle(t,c,"B"),e.appendChild(t);const d=document.createElement("fluent-button");d.addEventListener("click",(()=>{this.pagehandlerModule.StartShopping(r.Te.Auto,"viewPriceHistory")})),e.appendChild(d)}}styleDefaultState(e){e.style.minWidth="175px",e.appearance="accent",e.style.fontSize="14px",e.style.borderRadius="2px",e.style.marginTop="0px",e.style.height="32px",e.className+=` ${this.classActionsButton}`,e.style.width="auto"}removeFocusBanner(e){const t=e.querySelector(`.${this.classCopiedIndicator}`),i=e.querySelector("BUTTON");t&&i&&("hidden"===t.style.visibility?t.style.visibility="visible":t.style.visibility="hidden")}createBannerButtonWrapper(e){const t=(0,Y.Ux)("DIV");return t.style.position="relative",t.className=this.classDivActionButtonWrapper,t.setAttribute("role","button"),t.setAttribute("aria-label",e),t}manageBannerEvents(e,t,n){e.addEventListener("mouseover",(()=>{this.addFocusBanner(e)})),e.addEventListener("mouseout",(()=>{this.removeFocusBanner(e)})),e.addEventListener("focusin",(()=>{this.addFocusBanner(e)})),e.addEventListener("focusout",(()=>{this.removeFocusBanner(e)})),e.addEventListener("click",(()=>{if(t===r.ModuleNames.COUPON){const t=e.querySelector(".spanCouponCode")?.textContent;t&&this.pagehandlerModule.StartShopping(r.Te.Auto,t)}else t===r.ModuleNames.PRICECOMPARISON&&n&&this.priceComparisonModule.navigateToRetailer(n,i.Wm.BannerPriceComparisonModule,ju.$.NEW_FOREGROUND_TAB)})),t===r.ModuleNames.PRICECOMPARISON&&n&&e.addEventListener("mousedown",(e=>{1===e.button&&this.priceComparisonModule.navigateToRetailer(n,i.Wm.BannerPriceComparisonModule,ju.$.NEW_FOREGROUND_TAB)}))}addFocusBanner(e){if(e.querySelector("BUTTON")){const t=e.querySelector(`.${this.classCopiedIndicator}`);t&&("hidden"===t.style.visibility?t.style.visibility="visible":t.style.visibility="hidden")}}createHoverDiv(e,t){const i=(0,Y.Ux)("DIV");i.className=`${this.classBtnBannerPrimary} ${this.classCopiedIndicator}`;const n=(0,Y.Ux)("SPAN");return n.textContent=e,i.style.visibility=t?"hidden":"visible",i.appendChild(n),i}}(this.GetCashBackModule(),this.GetPriceComparisonModule(),this.GetPriceHistoryModule(),this.flyoutData,this.GetStateManagementModule(),this.utilities,this.commonAssets)),this.bannerModule}GetFlyoutRendererModule(){if(!this.flyoutRendererModule){const e=this.flyoutData.common.lastCommittedURL?.includes("pinterest.com/pin")??!1;this.flyoutRendererModule=new iD(this.GetStateManagementModule(),this.flyoutData,this.utilities,this.commonAssets,e?this.GetAvailableGuestModules():this.GetAvailableModules(),this.GetAvailableNotificationModules(),this.GetBannerModule())}return this.flyoutRendererModule}GetPaneRendererModule(){return this.paneRendererModule||(this.paneRendererModule=new ID(this.GetStateManagementModule(),this.flyoutData,this.utilities,this.commonAssets,this.GetAvailableModules(),this.GetAvailableNotificationModules(),this.GetBannerModule(),this.GetDeferredCashbackModules(),this.GetTrendingCouponsModule())),this.paneRendererModule}GetDiscoverPaneRendererModule(){return this.discoverPaneRendererModule||(this.discoverPaneRendererModule=new QI(this.GetStateManagementModule(),this.flyoutData,this.utilities,this.commonAssets,this.GetDiscoverPaneAvailableModules())),this.discoverPaneRendererModule}GetStateManagementModule(e){if(!this.stateManagementModule){let t;t=e||document.querySelector("#divContentWrapper"),this.stateManagementModule=new Ku.ZP(this.utilities.logModule,t)}return this.stateManagementModule}GetProductHistoryModule(){return this.productHistoryModule||(this.productHistoryModule=new zE(this.GetStateManagementModule(),this.flyoutData,this.utilities)),this.productHistoryModule}GetRewardModule(){return this.rewardModule||(this.rewardModule=new rk(this.flyoutData,this.utilities,this.GetStateManagementModule())),this.rewardModule}GetPostPurchaseConsentNotificationModule(){return this.postPurchaseConsentNotificationModule||(this.postPurchaseConsentNotificationModule=new class{constructor(e,t,i,n){(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),this.utilities=t.viewModulesUtilities,this.flyoutData=e,this.storageHandler=t.storageHandler,this.pageHandlerModule=t.pageHandlerModule,this.logModule=t.logModule,this.telemetryUtilities=t.telemetryHandler}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_POST_PURCHASE_TRACKING]}PostProcessingNotification(e,t){t.classList.add("lateralMargin"),t.slot="header-content",this.createButtonContainer(this.flyoutData.common.shopping)}GetNotificationName(){return r.sM.POST_PURCHASE_CONSENT_NOTIFICATION}ShouldRenderNotification(){return this.flyoutData.common.openedWith!==r.Te.Auto||this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_POST_PURCHASE_TRACKING?Promise.resolve(!1):e.R.isExperimentActive(f.H.postPurchaseTracking)&&this.isConfirmationPage()&&tt.kH.includes(this.flyoutData.common.domain)?!0===this.flyoutData.dataStoreModule.OrderTrackingData?.priceMatchingUserConsented?Promise.resolve(!1):Promise.resolve(!0):Promise.resolve(!1)}RenderNotification(){const e=(0,Y.Ux)("DIV"),t=this.createConsentCard();e.appendChild(t);const i=this.utilities.createNotificationModule(e,this.GetNotificationName(),this);return Promise.resolve(i)}createConsentCard(){const e=(0,Y.Ux)("div",{className:"imageWrapper"}),t=(0,Y.Ux)("img",{className:"zeroStateImage"}),i=this.flyoutData.common.resourcesEndpoint+"packageTracking/priceMatch.png";this.utilities.setImageSrc(t,i),t.style.pointerEvents="none",t.style.width="150px",t.style.height="123px",t.setAttribute("aria-hidden","true"),e.appendChild(t),e.slot="image";const n=(0,Y.Ux)("msft-consent-card");return n.description=this.flyoutData.strings.postPurchaseTrackingNotificationTitle,n.subtitle=this.flyoutData.strings.postPurchaseTrackingNotificationSubtitle,n.style.minHeight="220px",n.style.height="min-content",n.style.maxHeight="220px",n.appendChild(e),n}createButtonContainer(e){if(e){const t=(0,Y.Ux)("div");t.id="trackingConfirmationButtonContainer";const i=(0,Y.Ux)("DIV",{id:"trackingOptInButtonContainer"});i.style.padding="0px 16px",i.style.display="flex",i.style.justifyContent="center",this.flyoutData.common.openedWith!==r.Te.Auto&&(i.style.marginTop="10px");const n=this.createOptInButton();i.appendChild(n),t.appendChild(i),e.appendChild(t)}}createOptInButton(){const e=(0,Y.lw)(this.utilities);e.id="trackingOptInButton";const t=this.flyoutData.strings.postPurchaseTrackingNotificationCTA;return e.textContent=t,e.setAttribute("aria-label",t),e.addEventListener("click",(()=>{this.storageHandler.setStorageBool(Ce.Q.PriceMatchConsent,!0),this.pageHandlerModule.RecordAsUserAction(K.bS.PRICE_MATCH_OPT_IN),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRICE_MATCH_OPT_IN,this.flyoutData.common.popupOrigination);const e=new W.Z(i.$S.PriceMatchOptIn,this.telemetryUtilities.setContentViewed(this.GetNotificationName()));this.logModule.LogInfoEvent(i.R.ButtonClick,"User opted in for price matching on notification",e),this.pageHandlerModule.DismissPopup()})),e}isConfirmationPage(){const{common:e,dataStoreModule:t}=this.flyoutData,i=this.getPurchaseId(e.lastCommittedURL,e.domain);return"macys.com"===e.domain?e.lastCommittedURL.includes("/my-checkout"):!!i||!0===t?.CashBackData?.isConfirmationPage}getPurchaseId(e,t){return"target.com"===t?this.getPurchaseIdFromUrl(e,"orderId"):""}getPurchaseIdFromUrl(e,t){const i=e.split("?"),n=i.length>1?i[1].split("&"):[];let o="";return n.forEach((e=>{const i=e.split("=");2===i.length&&i[0]===t&&(o=i[1])})),o}}(this.flyoutData,this.utilities,this.GetStateManagementModule(),this.commonAssets)),this.postPurchaseConsentNotificationModule}GetCashBackNotificationModule(){return this.cashBackNotificationModule||(this.cashBackNotificationModule=new Ig(this.GetStateManagementModule(),this.flyoutData,this.utilities,this.commonAssets)),this.cashBackNotificationModule}GetUnifiedCashBackNotificationModule(){if(!this.unifiedCashbackNotificationModule){const e=Og.Z.initFactory(this.GetStateManagementModule(),this.flyoutData,this.utilities);e.getCashbackAvailableScenarious().experimentalFlight()?this.unifiedCashbackNotificationModule=new LD(e.getCashbackLogger(),e.getCashbackAvailableScenarious(),e.getLocalizedStringsData(),e.getCashbackUIService(),e.getCasbackContext(),e.getCashbackFastInitializer(),this.utilities):this.unifiedCashbackNotificationModule=new RD(e.getCashbackLogger(),e.getCashbackAvailableScenarious(),e.getLocalizedStringsData(),e.getCashbackUIService(),e.getCasbackContext(),e.getCashbackFastInitializer(),this.utilities)}return this.unifiedCashbackNotificationModule}GetSimilarSellersNotificationModule(){return this.similarSellersNotificationModule||(this.similarSellersNotificationModule=new oI(this.flyoutData,this.utilities,this.commonAssets)),this.similarSellersNotificationModule}GetRewardNotificationModule(){return this.rewardNotificationModule||(this.rewardNotificationModule=new ak(this.GetStateManagementModule(),this.flyoutData,this.utilities)),this.rewardNotificationModule}GetPriceComparisonNotificationModule(){return this.priceComparisonNotificationModule||(this.priceComparisonNotificationModule=new wS(this.GetStateManagementModule(),this.flyoutData,this.utilities)),this.priceComparisonNotificationModule}GetPaymentOptionsModule(){return this.paymentOptionsModule||(this.paymentOptionsModule=new pS(this.flyoutData,this.utilities)),this.paymentOptionsModule}GetViewedProductPriceDropNotificationModule(){return this.viewedProductPriceDropNotificationModule||(this.viewedProductPriceDropNotificationModule=new class{constructor(e,t,i){(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"notificationType",void 0),(0,s.Z)(this,"productTrackingViewUtilities",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"storageHandler",void 0),this.utilities=i.viewModulesUtilities,this.pageHandlerModule=i.pageHandlerModule,this.flyoutData=t,this.logModule=i.logModule,this.productTrackingViewUtilities=new Ju(i,t,e),this.stateManagement=e,this.telemetryUtilities=i.telemetryHandler,this.storageHandler=i.storageHandler}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION,u.sR.AUTO_SHOW_INBOX_PRICE_MATCH_NOTIFICATION]}PostProcessingNotification(e,t){const i=this.getProductData();e===r.sM.PRODUCT_TRACKING_PRICE_DROP_NOTIFICATION?(this.productTrackingViewUtilities.ResetOutOfFlowNotificationFrequency(),this.stateManagement.setState(Ku.IY.outOfFlow,u.W5.PRODUCT_TRACKING_EXP_PRICE_DROP),this.pageHandlerModule.OnOpenNotification(u.W5.PRODUCT_TRACKING_EXP_PRICE_DROP,"","")):e===r.sM.ViewedProductPriceDrop&&(this.stateManagement.setState(Ku.IY.outOfFlow,u.W5.PRODUCT_TRACKING_IMP_PRICE_DROP),this.pageHandlerModule.OnOpenNotification(u.W5.PRODUCT_TRACKING_IMP_PRICE_DROP,i?.ProductUrl,i?.CurrentPrice?.toString())),"ProductTrackingData"===this.notificationType?this.productTrackingViewUtilities.LogProductNotification(this.flyoutData.common.muid,i?.ProductUrl):"PostPurchase"===this.notificationType&&this.productTrackingViewUtilities.LogProductNotification(this.flyoutData.common.muid,i?.ProductUrl,"Extension/UX/PostPurchase")}async RenderNotification(){if(e.R.isExperimentActive(f.H.ptNotifications)&&e.R.getServiceExperimentValue(f.H.ptNotifications)==Yu.cO.NewDesign)return this.RenderNotificationV2();const t=this.getProductData();if(t){const i=(0,Y.Ux)("msft-notification-header");i.slot="header-content";const n=t.CurrencySymbol||"$",o=`${n}${this.utilities.formatPrice(t.CurrentPrice)}`,r=`${n}${this.utilities.formatPrice(t.basePrice)}`,a=`${n}${this.utilities.formatPrice(t.basePrice-t.CurrentPrice)}`;if("PostPurchase"===this.notificationType||"InboxPostPurchase"===this.notificationType){const e=(0,Y.Ux)("span",{className:"priceMatchTitle"}),t=(0,Y.Ux)("span",{style:"color: #008A21",textContent:a});e.append(t),e.slot="priceMatchTitle",(0,T.B7)(e,this.flyoutData.strings.priceMatchNotificationTitle,t),i.appendChild(e),i.style.marginBottom="0px"}else i.title="Price dropped",i.savings=a;i.oldPrice=r,i.currentPrice=o;const s=(0,Y.Ux)("IMG"),l=this.flyoutData.common.resourcesEndpoint+"common/unknowProductImage.png";t.imageUrl=t.imageUrl??"",t.imageUrl&&""!==t.imageUrl&&(t.imageUrl.startsWith("http")||t.imageUrl.startsWith("data:image")||(t.imageUrl="https://"+t.imageUrl),s.src=t.imageUrl),this.utilities.setImageSrc(s,t.imageUrl,l);const c="PostPurchase"===this.notificationType||"InboxPostPurchase"===this.notificationType?64:88,d=this.utilities.createProductImage(c,c,s,t.Title);d.slot="image",i.appendChild(d);const u=this.renderShopButton(t.domain||"",t.ProductUrl);if(u.style.placeSelf="center",u.slot="actions",this.flyoutData.common.shopping.appendChild(u),"ProductTrackingData"===this.notificationType){const e=await this.renderTrackingToggle(t);e&&this.flyoutData.common.shopping.appendChild(e)}this.flyoutData.common.shopping.classList.add("noSections");const h=this.utilities.createNotificationModule(i,this.GetNotificationName(),this);return"PostPurchase"!==this.notificationType&&"InboxPostPurchase"!==this.notificationType||this.storePriceMatchOfferNotification(t),e.R.isExperimentActive(f.H.ptNotifications)&&e.R.getServiceExperimentValue(f.H.ptNotifications)==Yu.cO.DismissTimeout&&setTimeout((()=>{this.pageHandlerModule.DismissPopup()}),1e4),Promise.resolve(h)}return Promise.resolve(null)}async RenderNotificationV2(){const e=this.getProductData();if(e){const t=(0,Y.Ux)("msft-notification-header");t.slot="header-content";const i=e.CurrencySymbol||"$",n=`${i}${this.utilities.formatPrice(e.CurrentPrice)}`,o=`${i}${this.utilities.formatPrice(e.basePrice)}`,r=`${i}${this.utilities.formatPrice(e.basePrice-e.CurrentPrice)}`,a=e.sellerName,s="0"!==n&&e.basePrice?`${Math.round(100*(1-e.CurrentPrice/e.basePrice))}%`:"0%";if("PostPurchase"===this.notificationType||"InboxPostPurchase"===this.notificationType){const e=(0,Y.Ux)("span",{className:"priceMatchTitle"}),i=(0,Y.Ux)("span",{style:"color: #008A21",textContent:r});e.append(i),e.slot="priceMatchTitle",(0,T.B7)(e,this.flyoutData.strings.priceMatchNotificationTitle,i),t.appendChild(e),t.style.marginBottom="0px"}const l=(0,Y.Ux)("span",{className:"txtHeader",textContent:s+" price drop",style:"font-size:16px; margin: 3px 0px 0px 6px;line-height: 22px; "}),c=(0,Y.Ux)("div",{className:"divSavingsContent",style:"display: flex; flex-direction: row; margin-bottom: 2px; color: #138757; font-weight: 600;"}),d=(0,Y.Ux)("img");d.src=this.flyoutData.common.resourcesEndpoint+"productTracking/PriceDropV2.svg",c.appendChild(d),c.appendChild(l),c.slot="slotTitle",t.appendChild(c),t.useSlotTitle=!0;const u=(0,Y.Ux)("IMG"),h=this.flyoutData.common.resourcesEndpoint+"common/unknowProductImage.png";e.imageUrl=e.imageUrl??"",e.imageUrl&&""!==e.imageUrl&&(e.imageUrl.startsWith("http")||e.imageUrl.startsWith("data:image")||(e.imageUrl="https://"+e.imageUrl),u.src=e.imageUrl),this.utilities.setImageSrc(u,e.imageUrl,h);const p="PostPurchase"===this.notificationType||"InboxPostPurchase"===this.notificationType?64:82,g=this.utilities.createProductImage(p,p,u,e.Title);g.slot="image";const f=(e.trackingSource!==ut.e7.AbandonedCart?"You're tracking this \nproduct at ":"This product is in your\ncart at ")+a+" ",m=(0,Y.Ux)("div",{className:"notificationContent",textContent:f,style:"white-space: pre-wrap; font-size: 14px; font-weight: 400; line-height: 20px; text-align: left; color:var(--text-normal);"});m.slot="notificationDescription";const v=(0,Y.Ux)("img");v.className="retailerIconPrice",v.src=this.utilities.getFavIconSrc(e.domain||"",18);const y=(0,Y.Ux)("div",{style:"display: inline-block; min-height: 18px; min-width: 18px; width: 18px; height: 18px; position: relative;top: 4px;"});y.appendChild(v),t.appendChild(m),m.appendChild(y),t.appendChild(g);const C=(0,Y.Ux)("div",{className:"divPriceWrapper",style:"display: flex; flex-direction: row; align-items: center; margin-bottom: 4px;"}),b=(0,Y.Ux)("span",{className:"txtCurrentPrice",textContent:n,style:"font-size: 12px; font-weight: 600; color: var(--text-price-color);line-height: 16px;"}),S=(0,Y.Ux)("s",{className:"txtOlPrice",textContent:o,style:"font-size: 12px; font-weight: 400; margin-left: 8px; color: var(--neutral-foreground-hint); line-height: 16px;"});if(C.appendChild(b),C.appendChild(S),C.slot="PriceComparePT",t.appendChild(C),"ProductTrackingData"===this.notificationType&&e.trackingSource!==ut.e7.AbandonedCart){const t=await this.renderTrackingToggle(e);t&&this.flyoutData.common.shopping.appendChild(t)}const x=this.renderShopButton(a||e.domain||"",e.ProductUrl);x.style.placeSelf="center",this.flyoutData.common.shopping.appendChild(x),this.flyoutData.common.shopping.classList.add("noSections");const w=this.utilities.createNotificationModule(t,this.GetNotificationName(),this);return"PostPurchase"!==this.notificationType&&"InboxPostPurchase"!==this.notificationType||this.storePriceMatchOfferNotification(e),Promise.resolve(w)}return Promise.resolve(null)}async ShouldRenderNotification(){const{common:n,dataStoreModule:o}=this.flyoutData;if(n.popupOrigination!==u.sR.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION&&n.popupOrigination!==u.sR.AUTO_SHOW_INBOX_PRICE_MATCH_NOTIFICATION)return!1;const{ProductTrackingNotificationData:r}=o,{InboxBestPriceMatchProduct:a}=o;if(r&&r.PriceDropProducts?.length>0){o.ProductTrackingData||(o.ProductTrackingData=new ue.Z(void 0)),o.ProductTrackingData._currentProduct=r?.PriceDropProducts[0],"PostPurchase"===r.PriceDropProducts[0].trackingSource?this.notificationType="PostPurchase":this.notificationType="ProductTrackingData";const n=r.PriceDropProducts[0];if(!n.basePrice||0===n.basePrice){const e=new t.Z(i.xu.ProductTrackingDebug);return e.Metadata=JSON.stringify({product:n}),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Block notification due to base price not available",e),!1}const a=100*(n.basePrice-n.CurrentPrice)/n.basePrice;if(e.R.isExperimentActive(f.H.ptNotifications)&&e.R.getServiceExperimentValue(f.H.ptNotifications)==Yu.cO.BlockAccordingToPercentage&&(a<30||a>80)){const e=new t.Z(i.xu.ProductTrackingDebug);return e.Metadata=JSON.stringify({product:n,priceDropPercentage:a}),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Block notification due to price drop percentage not in range 30-80",e),!1}const s=Date.now()-new Date(n.Timestamp).getTime();if(n.trackingSource===ut.e7.Explicit&&e.R.isExperimentActive(f.H.ptNotifications)&&e.R.getServiceExperimentValue(f.H.ptNotifications)==Yu.cO.BlockAccordingToTrackTime&&s>19008e5){const e=new t.Z(i.xu.ProductTrackingDebug);return e.Metadata=JSON.stringify({product:n,trackingTime:s}),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Block notification due to tracking time exceeded 22 days",e),!1}return!0}if(a)return this.notificationType="InboxPostPurchase",!0;{const t=o.ViewedProductListData;if(this.pageHandlerModule.TriggerExperiment(f.H.priceDropNotification),t&&t?.productShowItem)return this.notificationType="ViewedProductData",e.R.isExperimentActive(f.H.priceDropNotification)}return!1}GetNotificationName(){return"ProductTrackingData"===this.notificationType?r.sM.PRODUCT_TRACKING_PRICE_DROP_NOTIFICATION:"PostPurchase"===this.notificationType?r.sM.PRICE_MATCH_PRICE_DROP_NOTIFICATION:"InboxPostPurchase"===this.notificationType?r.sM.INBOX_PRICE_MATCH_PRICE_DROP_NOTIFICATION:r.sM.ViewedProductPriceDrop}async renderTrackingToggle(t){if(t.trackingSource===ut.e7.AbandonedCart&&(this.productTrackingViewUtilities.abandonedCartNotificationTrackingEnabled=e.R.isExperimentActive(f.H.ptAbandonedCartNotificationToggle)&&this.flyoutData.common.openedWith===r.Te.Auto),Ju.shouldRenderProductTrackingUtilities(t.ProductUrl,this.flyoutData.dataStoreModule.ProductTrackingData,this.flyoutData.common.market)){const e=new SS.Z(t.Title,t.imageUrl||"",t.CurrencySymbol);return e.ProductUrl=t.ProductUrl,e.price=t.CurrentPrice.toString(),await this.productTrackingViewUtilities.createTrackingToggleSection(e,!1,this.GetNotificationName())}}getProductData(){const{ViewedProductListData:e,ProductTrackingNotificationData:t,InboxBestPriceMatchProduct:i}=this.flyoutData.dataStoreModule;if("ViewedProductData"===this.notificationType){const t=new ut.ZP(void 0),i=e?.productShowItem;if(!i)return;return t.domain=i.domain,t.Title=i.title,t.CurrencySymbol=i.currencySymbol,t.ProductUrl=i.productUrl,t.imageUrl=i.imageUrl,t.CurrentPrice=i.currentPrice,t.basePrice=i.olderPrice,t}if("InboxPostPurchase"===this.notificationType){const e=new ut.ZP(void 0),t=i;if(!(t&&t.productCurrency&&t.priceMatchAmount&&t.productURL))return;return e.domain=t.retailerId,e.Title=t.productName,e.CurrencySymbol=t.productCurrency,e.ProductUrl=t.productURL,e.imageUrl=t.productImageURL,e.CurrentPrice=t.priceMatchAmount,e.basePrice=t.productPrice,e}return t?.PriceDropProducts?.[0]}renderShopButton(n,o){const r=(0,Y.lw)(this.utilities);return r.classList.add("lateralMargin"),r.style.marginBottom="0px",r.style.display="flex","PostPurchase"===this.notificationType||"InboxPostPurchase"===this.notificationType?(r.textContent=this.flyoutData.strings.priceMatchViewText,r.title=this.flyoutData.strings.priceMatchViewText):e.R.isExperimentActive(f.H.ptNotifications)&&e.R.getServiceExperimentValue(f.H.ptNotifications)==Yu.cO.NewDesign?(r.textContent="Shop on "+n,r.title="Shop on "+n):(r.textContent=(0,T.fZ)("prodHPriceDropViewAt",this.flyoutData.strings.prodHPriceDropViewAt,n),r.title=(0,T.fZ)("prodHPriceDropViewAt",this.flyoutData.strings.prodHPriceDropViewAt,n)),r.addEventListener("click",(()=>{o.startsWith("http")||(o="https://"+o);try{const e=new URL(o),t=this.getProductData();e.searchParams.set(qu.JZ,btoa(encodeURIComponent(JSON.stringify({currentPrice:t?.CurrentPrice,basePrice:t?.basePrice,notificationType:this.getPriceDropValidationType(t,this.notificationType),productId:t?.ProductId})))),o=e.toString()}catch(e){const n=new t.Z(i.xu.ProductTrackingDebug);n.Metadata=JSON.stringify({url:o,error:e?.message}),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"Failed to set price drop ref on url",n)}if("ViewedProductData"===this.notificationType){this.pageHandlerModule.RecordAsUserAction(K.bS.PWILO_NOTIFICATION_PRICE_DROP),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PWILO_NOTIFICATION_PRICE_DROP,this.flyoutData.common.popupOrigination);const e=new W.Z(i.$S.PriceDropProductPage,this.telemetryUtilities.setContentViewed(this.GetNotificationName()),this.flyoutData.common.domain,n);this.logModule.LogInfoEvent(i.R.ButtonClick,"User navigated to retailer page with price drop product",e,Jl.g.CouponImpressionId)}else if("ProductTrackingData"===this.notificationType){this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKING_PRODUCT_NOTIFICATION_CLICK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_TRACKING_PRODUCT_NOTIFICATION_CLICK,this.flyoutData.common.popupOrigination);const e=new W.Z(i.$S.ProductTrackingPriceDropVisitItem,this.telemetryUtilities.setContentViewed(this.GetNotificationName()),this.flyoutData.common.domain,JSON.stringify(this.getProductData()));this.logModule.LogInfoEvent(i.R.ButtonClick,"User navigated to retailer page with price drop product",e,Jl.g.CouponImpressionId)}else{this.pageHandlerModule.RecordAsUserAction(K.bS.PRICE_MATCH_NOTIFICATION_CTA_CLICK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRICE_MATCH_NOTIFICATION_CTA_CLICK,this.flyoutData.common.popupOrigination);const e=new W.Z(i.$S.PriceMatchNotificationButton,this.telemetryUtilities.setContentViewed(this.GetNotificationName()),this.flyoutData.common.domain,JSON.stringify(this.getProductData()));this.logModule.LogInfoEvent(i.R.ButtonClick,"User navigated to retailer page with price match product",e,Jl.g.CouponImpressionId)}setTimeout((()=>{this.pageHandlerModule.NavigateToRetailerSite(o)}),10)})),r}getPriceDropValidationType(e,t){return"ViewedProductData"===t?e?.trackingType??"UnknownTrackingType":t}async getStoredPriceMatchNotification(){return JSON.parse(await this.storageHandler.getStorageString(Ce.Q.PriceMatchNotification))}async storePriceMatchOfferNotification(e){let t=await this.getStoredPriceMatchNotification();t=this.updateStoredPriceMatchNotifications(t);const i=new class{constructor(e,t,i,n,o,r,a,l,c){(0,s.Z)(this,"purchasePrice",void 0),(0,s.Z)(this,"updatedPrice",void 0),(0,s.Z)(this,"domain",void 0),(0,s.Z)(this,"productUrl",void 0),(0,s.Z)(this,"imageUrl",void 0),(0,s.Z)(this,"productId",void 0),(0,s.Z)(this,"timestamp",void 0),(0,s.Z)(this,"notificationTimestamp",void 0),(0,s.Z)(this,"currencySymbol",void 0),(0,s.Z)(this,"source",void 0),this.purchasePrice=e,this.updatedPrice=t,this.domain=i,this.productUrl=n,this.imageUrl=o,this.productId=r,this.timestamp=a,this.currencySymbol=l,this.source=c}}(e.OlderPrice,e.CurrentPrice,e.domain,e.ProductUrl,e.imageUrl,e.ProductId,e.Timestamp,e.CurrencySymbol,aD.Inbox);i.notificationTimestamp=Date.now().toString(),t.push(i),this.storageHandler.setStorageString(Ce.Q.PriceMatchNotification,JSON.stringify(t))}updateStoredPriceMatchNotifications(e){if(!e||0===e.length)return e;for(const t of e){const e=Date.now(),i=new Date(t.notificationTimestamp),n=Math.abs(Number(e)-Number(i));Math.ceil(n/864e5)>2&&(t.notificationTimestamp="-1")}return e.filter((e=>"-1"!==e.notificationTimestamp))}}(this.GetStateManagementModule(),this.flyoutData,this.utilities)),this.viewedProductPriceDropNotificationModule}GetProductTrackingOffersNotificationModule(){return this.productTrackingOffersNotificationModule||(this.productTrackingOffersNotificationModule=new class{constructor(e,t,i){(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"productTrackingViewUtilities",void 0),(0,s.Z)(this,"productTrackingUtilities",void 0),(0,s.Z)(this,"stateManagement",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"notificationType",void 0),this.utilities=i.viewModulesUtilities,this.pageHandlerModule=i.pageHandlerModule,this.flyoutData=t,this.logModule=i.logModule,this.productTrackingViewUtilities=new Ju(i,t,e),this.productTrackingUtilities=new qu.ZP(i,this.flyoutData,this.stateManagement),this.stateManagement=e,this.telemetryUtilities=i.telemetryHandler,this.assets=new class{getStyles(){return"\n #productTrackingOffersCouponNotifHeader {\n font-style: normal;\n font-size: 20px;\n font-weight: 600;\n line-height: 26px;\n margin: 0px;\n }\n .productTrackingOffersCouponIcon {\n height: 16px;\n }\n .trackedProductOffersCouponDiscountRateSpan {\n color: #008A21;\n }\n .noDeals::part(productList) {\n margin-top: 0px;\n }\n .productImage {\n height: 100%;\n width: 100%;\n objectFit: contain;\n }\n .productImageWrapper {\n height: 48px;\n width: 48px;\n marginTop: 15px;\n }\n .productNameDiv {\n font-size: 12px;\n line-height: 16px;\n color: #717171;\n display: -webkit-box;\n -webkit-box-orient: vertical;\n -webkit-line-clamp: 2; /* number of lines to show */\n overflow: hidden;\n height: 35px;\n align-self: center;\n }\n #trackingToggleSection {\n background: var(--fill-color);\n border-radius: 8px;\n border: none;\n margin: 0 20px 12px 20px;\n }\n #trackingToggleContainer {\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n align-items: center;\n box-sizing: border-box;\n height: 36px;\n padding: 8px 10px;\n }\n #leftContainer {\n display: flex;\n gap: 11px;\n }\n #trackingToggleIcon {\n display: flex;\n align-items: center;\n }\n #trackingToggleText {\n font-size: 14px;\n line-height: 20px;\n }\n .trackedProductOffersCashbackSpan {\n padding: 1px 5px 3px 0px;\n background: #036AC4;\n width: 18px;\n height: 12px;\n font-weight: 600;\n font-size: 12px;\n line-height: 12px;\n position: relative;\n color: #FFFFFF;\n bottom: 5px;\n border-radius: 3px 0px 0px 3px;\n }\n .trackedProductOffersValue {\n position: relative;\n left: 5px;\n font-family: 'Segoe UI Variable Static Small';\n font-style: normal;\n font-weight: 600;\n font-size: 12px;\n line-height: 12px;\n position: relative;\n color: #FFFFFF;\n bottom: 5px;\n border-radius: 3px 0px 0px 3px;\n }\n .trackedProductOffersValue {\n position: relative;\n left: 5px;\n }\n "}getDarkModeStyles(){return"\n @media (prefers-color-scheme: dark) {\n .productNameDiv {\n color: #FFFFFF;\n }\n .trackedProductOffersCouponDiscountRateSpan {\n color: #56df77;\n }\n #trackingToggleSection {\n background: #414141;\n }\n };\n "}getCashbackIconStyles(){return eh.Z.getTrustedHTML`<svg width="14" height="9" viewBox="0 0 14 9" fill="none" xmlns="http://www.w3.org/2000/svg" style="transform: scale(3);margin: 0 12px;">
<path d="M2.49507 6.16572e-06C1.39051 -0.00270725 0.497293 0.890516 0.500006 1.99507L0.511429 6.64502C0.514142 7.74958 1.41176 8.6472 2.51632 8.64991L9.10413 8.6661C9.62955 8.66739 10.1334 8.46186 10.5067 8.09394L12.9019 5.73317C13.693 4.95348 13.6918 3.67471 12.8993 2.88872L10.5912 0.599778C10.2157 0.227396 9.70907 0.0177279 9.18153 0.0164318L2.49507 6.16572e-06Z" fill="#3267FA"></path>
</svg>`}}}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_SERVER_DRIVEN_NOTIFICATION]}PostProcessingNotification(e,t){e===r.sM.PRODUCT_TRACKING_OFFERS_COUPON_NOTIFICATION&&(this.productTrackingUtilities.ResetOutOfFlowNotificationFrequency(),this.stateManagement.setState(Ku.IY.outOfFlow,u.W5.PRODUCT_TRACKING_OFFERS_COUPONS),this.pageHandlerModule.OnOpenNotification(u.W5.PRODUCT_TRACKING_OFFERS_COUPONS,"",""))}async RenderNotification(){const e=this.getProductData(),t=e?.highSuccessRateCoupon??e?.cashbackCommission,i=e?.highSuccessRateCoupon?.couponCode??"";if(e&&t){this.flyoutData.common.shopping.classList.add("noSections");const n=(0,Y.Ux)("div");n.id="productTrackingOffersCouponNotificationDiv",n.className="lateralMargin",this.utilities.applyStyles(n,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles());const o=(0,Y.Ux)("h2");o.id="productTrackingOffersCouponNotifHeader",o.slot="description";const r=this.GetSavingsElement(),a=(0,Y.Ux)("img");a.className="productTrackingOffersCouponIcon",a.src=this.utilities.getFavIconSrc(e.domain||""),a.setAttribute("aria-hidden","true");const s=(0,Y.Ux)("div");s.style.minHeight="16px",s.style.minWidth="16px",s.style.display="inline-block",s.style.marginLeft="5px",s.appendChild(a);const l=(0,Y.Ux)("span");l.innerText=t.sellerName??e.domain??"";const c=this.renderShopButton(e.domain||"",e.ProductUrl,i);"CouponOffer"===this.notificationType?(0,T.B7)(o,this.flyoutData.strings.productTrackingNotificationCouponOffers,r,l):"CashbackOffer"===this.notificationType&&(0,T.B7)(o,this.flyoutData.strings.productTrackingNotificationCashbackOffers,r,l),o.appendChild(s);const d=(0,Y.Ux)("div");d.style.display="flex",d.style.columnGap="16px",d.style.margin="10px 0";const u=(0,Y.Ux)("IMG");u.src=e.ImageUrl,u.setAttribute("aria-label",e.Title),u.classList.add("productImage");const h=(0,Y.Ux)("div");h.appendChild(this.utilities.createProductImage(48,48,u)),h.classList.add("productImageWrapper"),h.slot="image",d.append(h);const p=(0,Y.Ux)("div");p.textContent=e.Title,p.classList.add("productNameDiv"),d.append(p),n.append(o),n.append(d),n.append(c);const g=await this.renderTrackingToggle(e);g&&n.appendChild(g);const f=this.utilities.createNotificationModule(n,this.GetNotificationName(),this);return Promise.resolve(f)}return Promise.resolve(null)}async ShouldRenderNotification(){return!1}GetNotificationName(){return r.sM.PRODUCT_TRACKING_OFFERS_COUPON_NOTIFICATION}async renderTrackingToggle(e){if(Ju.shouldRenderProductTrackingUtilities(e.ProductUrl,this.flyoutData.dataStoreModule.ProductTrackingData,this.flyoutData.common.market)){const t=new SS.Z(e.Title,e.imageUrl||"",e.CurrencySymbol);return t.ProductUrl=e.ProductUrl,t.price=e.CurrentPrice.toString(),await this.productTrackingViewUtilities.createTrackingToggleSection(t,!1,this.GetNotificationName())}}getProductData(){const{ProductTrackingNotificationData:e}=this.flyoutData.dataStoreModule;return e?.PriceDropOffersProducts?.[0]}renderShopButton(e,t,n){const o=(0,Y.lw)(this.utilities);return"CouponOffer"===this.notificationType?o.textContent=this.flyoutData.strings.copyCouponAndViewProduct:o.textContent=this.flyoutData.strings.viewProductButton,o.addEventListener("click",(()=>{t.startsWith("http")||(t="https://"+t),this.pageHandlerModule.RecordAsUserAction(K.bS.PRODUCT_TRACKING_PRODUCT_NOTIFICATION_CLICK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.PRODUCT_TRACKING_PRODUCT_NOTIFICATION_CLICK,this.flyoutData.common.popupOrigination);let e=i.$S.ProductTrackingPriceDropWithCouponVisitItem;"CashbackOffer"===this.notificationType&&(e=i.$S.ProductTrackingPriceDropWithCashbackVisitItem);const r=new W.Z(e,this.telemetryUtilities.setContentViewed(this.GetNotificationName()),this.flyoutData.common.domain,JSON.stringify(this.getProductData()));this.logModule.LogInfoEvent(i.R.ButtonClick,"User navigated to retailer page with high success coupon offer product",r,Jl.g.CouponImpressionId),"CouponOffer"===this.notificationType?(this.copyCouponToClipboard(n),o.textContent="Coupon Copied",o.disabled=!0,setTimeout((()=>{this.pageHandlerModule.NavigateToUrl(t)}),1e3)):"CashbackOffer"===this.notificationType&&this.pageHandlerModule.NavigateToUrl(t)})),o}GetSavingsElement(){const e=this.getProductData();if("CouponOffer"===this.notificationType&&e?.highSuccessRateCoupon){const t=(0,Y.Ux)("span");return t.className="trackedProductOffersCouponDiscountRateSpan",t.textContent=(0,T.fZ)("trackedProductOffersCouponSpan",this.flyoutData.strings.commonSave,`${e?.highSuccessRateCoupon.discountRate}%`),t}{const t=(0,Y.Ux)("span");(0,Y.Ux)("span").className="trackedProductOffersCashbackSpan";const i=(0,Y.Ux)("span");i.innerHTML=this.assets.getCashbackIconStyles();const n=(0,Y.Ux)("span");return n.innerText=`${e?.cashbackCommission?.value}${e?.cashbackCommission?.type}`,n.style.position="absolute",n.style.left="73px",n.style.color="white",t.appendChild(i),t.appendChild(n),t}}copyCouponToClipboard(e){const t=document.createElement("textarea");t.value=e,document.body.appendChild(t),t.focus(),t.select(),document.execCommand("copy"),document.body.removeChild(t)}}(this.GetStateManagementModule(),this.flyoutData,this.utilities)),this.productTrackingOffersNotificationModule}GetDiscoverNotificationModule(){return this.discoverNotificationModule||(this.discoverNotificationModule=new class{constructor(e,t,i){(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"title",""),(0,s.Z)(this,"moduleNameToOpen",""),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"commonAssets",void 0),(0,s.Z)(this,"discoverTelemetryHandler",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"discoverModuleUtilities",void 0),this.flyoutData=e,this.discoverTelemetryHandler=t.discoverTelemetryHandler,this.utilities=t,this.commonAssets=i,this.pageHandlerModule=t.pageHandlerModule}async RenderNotification(e){this.discoverModuleUtilities=new class{constructor(e,t){(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"discoverTelemetryHandler",void 0),this.discoverTelemetryHandler=t.discoverTelemetryHandler,this.flyoutData=e}SetNotificationText(){const e=this.MakeTextForModulesMap(this.flyoutData)[this.flyoutData.common.journeyStage||Ut.v.UNDEFINED];if(!e)return void this.discoverTelemetryHandler.LogErrorTelemetry("No text for current journey stage. No discover notification text","",void 0,void 0,void 0,i.xu.DiscoverNotificationInfo);const t=this.GetIsEnMarket(),n=Object.keys(e);for(const o of n)if(this.IsDataForModulePresent(o)){const n=e[o];let r="";if(n){const e=this.GetTextForMarket(t,n.en||"",n.notEn);if(e)return this.discoverTelemetryHandler.LogEventTelemetry(i.xu.DiscoverNotificationInfo,"Text for discover notification found","pdp",o,{notificationText:e,moduleNameToOpen:o}),{notificationText:e,moduleName:o};r="No notificationText"}else r="No textsForModule";this.discoverTelemetryHandler.LogErrorTelemetry("Data is valid, but no text found","",o,void 0,{errorMessage:r},i.xu.DiscoverNotificationInfo)}}MakeTextForModulesMap(e){return{[Ut.v.UNDEFINED]:{[r.ModuleNames.BUYING_GUIDES]:{notEn:e.dataLoader.GetLoadTimeDataValue("shoppingAiProductCategoryMissing","")},[r.ModuleNames.PRODUCT_SUMMARY]:{notEn:e.dataLoader.GetLoadTimeDataValue("shoppingAiProductCategoryMissingLearn","")},[r.ModuleNames.SMART_COMPARE]:{notEn:e.dataLoader.GetLoadTimeDataValue("shoppingAiPdpFirstTimeCompare",""),en:e.dataLoader.GetLoadTimeDataValue("shoppingAiPdpFirstTimeCompareEn","")}},[Ut.v.DISCOVER]:{[r.ModuleNames.SMART_COMPARE]:{notEn:e.dataLoader.GetLoadTimeDataValue("shoppingAiPdpFirstTimeCompare",""),en:e.dataLoader.GetLoadTimeDataValue("shoppingAiPdpFirstTimeCompareEn","")},[r.ModuleNames.BUYING_GUIDES]:{notEn:e.dataLoader.GetLoadTimeDataValue("shoppingAiProductCategoryMissing","")},[r.ModuleNames.PRODUCT_SUMMARY]:{notEn:e.dataLoader.GetLoadTimeDataValue("shoppingAiProductCategoryMissingLearn","")}},[Ut.v.RESEARCH]:{[r.ModuleNames.SMART_COMPARE]:{notEn:e.dataLoader.GetLoadTimeDataValue("shoppingAiPdpFirstTimeCompare",""),en:e.dataLoader.GetLoadTimeDataValue("shoppingAiPdpFirstTimeCompareEn","")},[r.ModuleNames.BUYING_GUIDES]:{notEn:e.dataLoader.GetLoadTimeDataValue("shoppingAiPdpPrevViewed",""),en:e.dataLoader.GetLoadTimeDataValue("shoppingAiPdpPrevViewedEn","")},[r.ModuleNames.PRODUCT_SUMMARY]:{notEn:e.dataLoader.GetLoadTimeDataValue("shoppingAiPdpPrevViewedDetails",""),en:e.dataLoader.GetLoadTimeDataValue("shoppingAiPdpPrevViewedDetailsEn","")}},[Ut.v.DECISION]:{[r.ModuleNames.SMART_COMPARE]:{notEn:e.dataLoader.GetLoadTimeDataValue("shoppingAiPdpFirstTimeCompare",""),en:e.dataLoader.GetLoadTimeDataValue("shoppingAiPdpFirstTimeCompareEn","")},[r.ModuleNames.BUYING_GUIDES]:{notEn:e.dataLoader.GetLoadTimeDataValue("shoppingAiPdpPrevViewed",""),en:e.dataLoader.GetLoadTimeDataValue("shoppingAiPdpPrevViewedEn","")},[r.ModuleNames.PRODUCT_SUMMARY]:{notEn:e.dataLoader.GetLoadTimeDataValue("shoppingAiPdpPrevViewedDetails",""),en:e.dataLoader.GetLoadTimeDataValue("shoppingAiPdpPrevViewedDetailsEn","")}}}}GetIsEnMarket(){return this.flyoutData.common.afdMarket.startsWith("en-")}GetTextForMarket(e,t,i){return e&&t?t:i}IsDataForModulePresent(e){switch(e){case r.ModuleNames.SMART_COMPARE:{const e=this.flyoutData.dataStoreModule.DiscoverShoppingData;return!(!e||!e.SmartCompareData)}case r.ModuleNames.BUYING_GUIDES:{const e=this.flyoutData.dataStoreModule.DiscoverShoppingData;return!(!e||!e.BuyingGuideData)}case r.ModuleNames.PRODUCT_SUMMARY:{const e=this.flyoutData.dataStoreModule.DiscoverShoppingData;return!(!e||!e.ProductSummaryData)}case r.ModuleNames.SIMILAR_OFFERS:return!1}return!1}}(this.flyoutData,this.utilities);const t=this.discoverModuleUtilities.SetNotificationText();this.title=t?.notificationText||"",this.moduleNameToOpen=t?.moduleName||"";const n=(0,Y.Ux)("DIV",{className:"lateralMargin"});n.id="divDiscoverNotification";const o=(0,Y.Ux)("H2",{className:"txtMedium",style:"text-align: center;"});o.innerText=this.title,n.append(o);const a=(0,Y.lw)(this.utilities.viewModulesUtilities);return a.textContent=this.flyoutData.strings.chatNotificationButton,a.slot="actions",a.addEventListener("click",(()=>{const e={isShoppingPane:!1,isNotification:!0,text:this.title};this.utilities.pageHandlerModule.RecordAsUserAction(K.bS.DISCOVER_NOTIFICATION_CLICK),this.pageHandlerModule.OpenChatPane(JSON.stringify(e),"")})),n.appendChild(a),Promise.resolve(this.utilities.viewModulesUtilities.createNotificationModule(n,this.GetNotificationName(),this))}async ShouldRenderNotification(){const t=this.flyoutData.common.popupOrigination;return Promise.resolve(t===u.sR.AUTO_SHOW_DISCOVER_NOTIFICATION&&e.R.isExperimentActive(f.H.shoppingOnDiscover)&&e.R.isExperimentActive(f.H.temporalShoppingOnDiscover)&&e.R.isExperimentActive(f.H.discoverNotification))}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_DISCOVER_NOTIFICATION]}GetNotificationName(){return r.sM.DISCOVER_NOTIFICATION}PostProcessingNotification(e,t){}}(this.flyoutData,this.utilities,this.commonAssets)),this.discoverNotificationModule}GetVirtualCardModule(){return this.virtualCardModule||(this.virtualCardModule=new yI(this.flyoutData,this.utilities)),this.virtualCardModule}GetVirtualCardNotificationModule(){return this.virtualCardNotificationModule||(this.virtualCardNotificationModule=new CI(this.GetStateManagementModule(),this.flyoutData,this.utilities)),this.virtualCardNotificationModule}GetFeedbackModule(){return this.feedbackModule||(this.feedbackModule=new ky(this.flyoutData,this.utilities,this.GetStateManagementModule(),this.commonAssets)),this.feedbackModule}GetItemizedCashbackModule(){return this.itemizedCashBackModule||(this.itemizedCashBackModule=new Lg(this.flyoutData,this.utilities,this.commonAssets,this.stateManagementModule)),this.itemizedCashBackModule}GetItemizedCashbackNotificationModule(){return this.itemizedCashBackNotificationModule||(this.itemizedCashBackNotificationModule=new Fg(this.flyoutData,this.utilities,this.commonAssets,this.stateManagementModule)),this.itemizedCashBackNotificationModule}GetAutosMarketplaceModule(){return this.autosMarketplaceModule||(this.autosMarketplaceModule=new ah(this.flyoutData,this.utilities)),this.autosMarketplaceModule}GetAutosMyGarageModule(){return this.autosMyGarageModule||(this.autosMyGarageModule=new fp(this.flyoutData,this.utilities)),this.autosMyGarageModule}GetAutosMarketplaceNotificationModule(){return this.autosMarketplaceNotificationModule||(this.autosMarketplaceNotificationModule=new nD(this.flyoutData,this.utilities)),this.autosMarketplaceNotificationModule}GetAutosReviewsModuleNotificationModule(){return this.autosReviewsModuleNotificationModule||(this.autosReviewsModuleNotificationModule=new oD(this.GetStateManagementModule(),this.flyoutData,this.utilities)),this.autosReviewsModuleNotificationModule}GetPriceHistoryNotificationModule(){return this.priceHistoryNotificationModule||(this.priceHistoryNotificationModule=new $E(this.GetStateManagementModule(),this.flyoutData,this.utilities)),this.priceHistoryNotificationModule}GetCouponsNotificationModule(){return this.couponsNotificationModule||(this.couponsNotificationModule=new by(this.GetStateManagementModule(),this.flyoutData,this.utilities,this.commonAssets)),this.couponsNotificationModule}GetBGAANotificationModule(){return this.bgaaNotificationModule||(this.bgaaNotificationModule=new Sy(this.flyoutData,this.utilities)),this.bgaaNotificationModule}GetProductBestCouponNotificationModule(){return this.productBestCouponNotificationModule||(this.productBestCouponNotificationModule=new class{constructor(e,t){(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"productBestCoupon",void 0),(0,s.Z)(this,"productName",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),this.assets=new class{getStyles(){return"\n msft-edge-shopping::part(header) {\n margin-top: 0px !important;\n }\n #ProductBestCouponNotification {\n text-align: center;\n }\n #header {\n margin: 0px 0px 4px;\n font-size: 24px;\n font-weight: 600;\n line-height: 32px;\n }\n #productName {\n font-weight: 600;\n margin: 0px 30px 5px;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n width: 220px;\n }\n #applyOnCheckoutTag {\n font-size: 10px;\n font-weight: 400;\n line-height: 14px;\n margin: 2px 0px 12px;\n color: #707070;\n }\n "}getDarkModeStyles(){return"\n #applyOnCheckoutTag {\n color: #E0E0E0;\n }\n "}},this.flyoutData=e,this.logModule=t.logModule,this.storageHandler=t.storageHandler,this.utilities=t.viewModulesUtilities,this.pageHandlerModule=t.pageHandlerModule,this.telemetryUtilities=t.telemetryHandler}async RenderNotification(e){const t=AI(this.flyoutData);t?this.productBestCoupon=t:await this.storageHandler.getStorageString(Ce.Q.ProductBestCoupon).then((e=>{const t=e?JSON.parse(e):void 0;t&&(this.productName=t?.product,this.productBestCoupon=t,this.storageHandler.clearStorage(Ce.Q.ProductBestCoupon))}));const n=(0,Y.Ux)("DIV");if(n.id="ProductBestCouponNotification",this.utilities.applyStyles(n,this.assets.getStyles(),void 0,this.assets.getDarkModeStyles()),this.productBestCoupon.coupon.discountPercent){const e=(0,Y.Ux)("H2");e.id="header",e.textContent=`Up to ${this.productBestCoupon.coupon.discountPercent}% off`,e.classList.add("txtInstantSavings"),n.append(e)}const o=this.productName||this.flyoutData.dataStoreModule.PriceComparisonData?.entityName;if(o){const e=(0,Y.Ux)("P");e.id="productName",e.textContent=o,e.title=o,e.classList.add("txtSmall"),n.append(e)}const r=(0,Y.zM)(this.productBestCoupon,this.utilities.commonAssets,this.flyoutData.strings.bestCouponAriaLabel,this.flyoutData.strings.bestCouponCopiedAriaLabel,this.GetNotificationName(),this.telemetryUtilities,this.pageHandlerModule,this.logModule),a=(0,Y.Ux)("P");a.id="applyOnCheckoutTag",a.textContent=this.flyoutData.strings.pdpApplyBestCoupon,n.append(r),n.append(a);const s=(0,Y.lw)(this.utilities);s.setAttribute("aria-label","Ok"),s.textContent="Ok",s.className+=" lateralMargin",n.append(s);const l=await this.storageHandler.getStorageString(Ce.Q.ProductBestCouponConsent),c=(0,p.TF)(l)?{}:JSON.parse(l),d=this.flyoutData.common.domain??(0,T.S8)();s.addEventListener("click",(()=>{const e=new W.Z(i.$S.AutoApplyBestCouponConsent,this.telemetryUtilities.setContentViewed(this.GetNotificationName()));this.pageHandlerModule.RecordAsUserAction(K.bS.TRY_PRODUCT_BEST_COUPON),this.pageHandlerModule.RecordAsUserEngagement(q.FV.TRY_PRODUCT_BEST_COUPON,this.flyoutData.common.popupOrigination),this.logModule.LogInfoEvent(i.R.ButtonClick,this.productName?"User clicked ok for best coupon on search page":"User clicked ok for best coupon on PDPs",e);const t=new hy;t.timeStamp=(new Date).toUTCString(),t.allowed=!0,t.productBestCoupon=this.productBestCoupon.coupon,c[d]=t;try{this.storageHandler.setStorageString(Ce.Q.ProductBestCouponConsent,JSON.stringify(c))}catch(e){}this.pageHandlerModule.DismissPopup()}));const u=this.utilities.createNotificationModule(n,this.GetNotificationName(),this);return Promise.resolve(u)}async ShouldRenderNotification(){const e=this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_PRODUCT_BEST_COUPON_CONSENT;return Promise.resolve(this.flyoutData.common.openedWith===r.Te.Auto&&e)}GetNotificationName(){return r.sM.PRODUCT_BEST_COUPON}PostProcessingNotification(e,t){}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_PRODUCT_BEST_COUPON_CONSENT]}}(this.flyoutData,this.utilities)),this.productBestCouponNotificationModule}GetClippingNotificationModule(){return this.clippingNotificationModule||(this.clippingNotificationModule=new jm(this.flyoutData,this.utilities,this.GetStateManagementModule(),this.commonAssets)),this.clippingNotificationModule}GetShoppingTripsModule(){return this.shoppingTripsModule||(this.shoppingTripsModule=new Qk(this.GetStateManagementModule(),this.flyoutData,this.utilities,this.commonAssets)),this.shoppingTripsModule}GetProductCollectionsModule(){return this.productCollectionsModule||(this.productCollectionsModule=new jE(this.GetStateManagementModule(),this.flyoutData,this.utilities,this.commonAssets)),this.productCollectionsModule}GetAbandonedCartModule(){return this.abandonedCartModule||(this.abandonedCartModule=new ih(this.flyoutData,this.utilities,this.stateManagementModule)),this.abandonedCartModule}GetAbandonedCartNotificationModule(){return this.abandonedCartNotificationModule||(this.abandonedCartNotificationModule=new nh(this.flyoutData,this.utilities,this.stateManagementModule)),this.abandonedCartNotificationModule}GetPriceDropPlusCashbackCompositeNotificationModule(){return this.priceDropPlusCashbackCompositeNotificationModule||(this.priceDropPlusCashbackCompositeNotificationModule=new RI(this.flyoutData,this.utilities,this.stateManagementModule,this.commonAssets)),this.priceDropPlusCashbackCompositeNotificationModule}GetCashbackPlusCouponsCompositeNotificationModule(){return this.cashbackPlusCouponsCompositeNotificationModule||(this.cashbackPlusCouponsCompositeNotificationModule=new NI(this.flyoutData,this.utilities,this.stateManagementModule,this.commonAssets)),this.cashbackPlusCouponsCompositeNotificationModule}GetLowerPricePlusCashbackPlusCouponsCompositeNotificationModule(){return this.lowerPricePlusCashbackPlusCouponsCompositeNotificationModule||(this.lowerPricePlusCashbackPlusCouponsCompositeNotificationModule=new DI(this.flyoutData,this.utilities,this.stateManagementModule)),this.lowerPricePlusCashbackPlusCouponsCompositeNotificationModule}GetProductTrackingModule(){return this.productTrackingModule||(this.productTrackingModule=new ek(this.GetStateManagementModule(),this.flyoutData,this.utilities,this.commonAssets)),this.productTrackingModule}GetProductTrackingNotificationModule(){return this.productTrackingNotificationModule||(this.productTrackingNotificationModule=new ik(this.GetStateManagementModule(),this.flyoutData,this.utilities,this.commonAssets)),this.productTrackingNotificationModule}GetActiveRetailerInboxCouponsModule(){return this.activeRetailerInboxCouponsModule||(this.activeRetailerInboxCouponsModule=new rS(this.flyoutData,this.utilities,this.commonAssets,this.stateManagementModule)),this.activeRetailerInboxCouponsModule}GetTrendingCouponsModule(){return this.trendingCouponsModule||(this.trendingCouponsModule=new hI(this.flyoutData,this.utilities)),this.trendingCouponsModule}GetTrendingCouponsNotificationModule(){return this.trendingCouponsNotificationModule||(this.trendingCouponsNotificationModule=new pI(this.flyoutData,this.utilities)),this.trendingCouponsNotificationModule}GetSANConsentModule(){return this.sanConsentModule||(this.sanConsentModule=new ck(this.flyoutData,this.utilities,this.stateManagementModule)),this.sanConsentModule}GetSANConsentNotificationModule(){return this.sanConsentNotificationModule||(this.sanConsentNotificationModule=new class{constructor(e,t){(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"sanConsentUtils",void 0),this.flyoutData=e,this.utilities=t.viewModulesUtilities,this.logModule=t.logModule,this.sanConsentUtils=new lk(e,t,r.P1.OtherNotification)}ShouldRenderNotification(){const t=this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_SAN_CONSENT_CONFIRMATION&&this.flyoutData.common.openedWith===r.Te.Auto&&e.R.isExperimentActive(f.H.sanConsent)&&this.sanConsentUtils.CanPromptConsent();return Promise.resolve(t)}RenderNotification(e){const n=this.sanConsentUtils.CreateSANConsentDiv(!1,i.xu.ICSanConsentNotificationHover),o=new t.Z(i.xu.SanConsentViewed);o.Metadata=JSON.stringify({isEu:this.sanConsentUtils.IsEu()}),this.logModule.LogInfoEvent(i.R.EdgeFlyoutStatus,"SanConsent shown in notification to user",o);const r=this.utilities.createNotificationModule(n,this.GetNotificationName(),this);return Promise.resolve(r)}GetNotificationName(){return r.sM.SAN_CONSENT_NOTIFICATION}PostProcessingNotification(e,t){}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_SAN_CONSENT_CONFIRMATION]}}(this.flyoutData,this.utilities)),this.sanConsentNotificationModule}GetSearchBoxDemoNotificationModule(){return this.searchBoxNotificationModuleModule||(this.searchBoxNotificationModuleModule=new class{constructor(e,t){(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"utilities",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"storageHandler",void 0),this.flyoutData=e,this.utilities=t.viewModulesUtilities,this.pageHandlerModule=t.pageHandlerModule,this.storageHandler=t.storageHandler}async RenderNotification(e){const t=await this.getStoredPCBOfferData(),i=(0,Y.Ux)("DIV",{style:"width: 100%;"});i.style.display="flex",i.style.flexDirection="row",i.style.columnGap="10px",i.style.marginLeft="10px",i.style.marginRight="10px";const n=this.utilities.createNotificationModule(i,this.GetNotificationName(),this),o=(0,Y.Ux)("IMG",{id:"productImage"});o.src=t?.offerDetails?.value[0]?.offer?.itemOffered?.image?.contentUrl;const r=this.utilities.createProductImage(88,88,o);r.style.minWidth="80px",r.style.minHeight="80px",r.slot="image",i.appendChild(r);const a=(0,Y.Ux)("DIV",{style:"width: 100%;"});a.style.display="column",a.style.rowGap="2px",a.addEventListener("click",(async e=>{e.preventDefault(),this.pageHandlerModule.NavigateToUrl(t?.offerDetails?.value[0]?.offer?.url)}));const s=(0,Y.Ux)("DIV",{style:"width: 100%;"});s.textContent=t?.offerDetails?.value[0]?.offer?.seller?.name,a.appendChild(s);const l=(0,Y.Ux)("DIV",{style:"width: 100%;"});l.textContent=t?.offerDetails?.value[0]?.offer?.itemOffered?.name,a.appendChild(l);const c=(0,Y.Ux)("DIV",{style:"width: 100%;"});c.textContent=t?.offerDetails?.value[0]?.offer?.priceCurrencySymbol+t?.offerDetails?.value[0]?.offer?.price,a.appendChild(c);const d=(0,Y.Ux)("DIV",{style:"width: 100%;"}),u=this.flyoutData.strings.priceCompareCashback;return d.textContent=(0,T.fZ)("priceCompareCashback",u,t?.offerDetails?.value[0]?.offer?.priceCurrencySymbol+t?.offerDetails?.value[0]?.promotionInformation?.rebateValue),a.appendChild(d),i.appendChild(a),Promise.resolve(n)}ShouldRenderNotification(){return this.flyoutData.common.popupOrigination===u.sR.AUTO_SHOW_AMAZON_SEARCH_PC?Promise.resolve(!0):Promise.resolve(!1)}GetNotificationName(){return r.sM.SEARCHBOXDEMO_NOTIFICATION}PostProcessingNotification(e,t){}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_AMAZON_SEARCH_PC]}async getStoredPCBOfferData(){try{const e=await this.storageHandler.getStorageString(Ce.Q.AmazonSearchPCBOffer);return JSON.parse(e)}catch(e){return null}}}(this.flyoutData,this.utilities)),this.searchBoxNotificationModuleModule}GetProductSummaryModule(){return this.productSummaryModule||(this.productSummaryModule=new QE(this.flyoutData,this.utilities,this.commonAssets,this.stateManagementModule)),this.productSummaryModule}GetBuyingGuidesModule(){return this.buyingGuidesModule||(this.buyingGuidesModule=new Bp(this.flyoutData,this.utilities,this.commonAssets,this.stateManagementModule)),this.buyingGuidesModule}GetSmartCompareModule(){return this.smartCompareModule||(this.smartCompareModule=new rI(this.flyoutData,this.utilities,this.commonAssets,this.stateManagementModule)),this.smartCompareModule}GetExpertInsightsModule(){return this.expertInsightsModule||(this.expertInsightsModule=new Ay(this.flyoutData,this.utilities)),this.expertInsightsModule}GetDiscoverChatChipsModule(){return this.discoverChatChipsModule||(this.discoverChatChipsModule=new Py(this.flyoutData,this.utilities,this.commonAssets,this.stateManagementModule)),this.discoverChatChipsModule}GetTravelCheaperFlightsNotificationModule(){return this.travelCheaperFlightsNotificationModule||(this.travelCheaperFlightsNotificationModule=new sI(this.flyoutData,this.utilities)),this.travelCheaperFlightsNotificationModule}GetTravelCheaperHotelsNotificationModule(){return this.travelCheaperHotelsNotificationModule||(this.travelCheaperHotelsNotificationModule=new class{constructor(e,t){(0,s.Z)(this,"assets",void 0),(0,s.Z)(this,"storageHandler",void 0),(0,s.Z)(this,"flyoutData",void 0),(0,s.Z)(this,"travelCheaperHotelsData",void 0),(0,s.Z)(this,"travelCheaperHotelCard",void 0),(0,s.Z)(this,"logModule",void 0),(0,s.Z)(this,"pageHandlerModule",void 0),(0,s.Z)(this,"telemetryUtilities",void 0),(0,s.Z)(this,"utilities",void 0),this.flyoutData=e,this.utilities=t.viewModulesUtilities,this.storageHandler=t.storageHandler,this.logModule=t.logModule,this.telemetryUtilities=t.telemetryHandler,this.pageHandlerModule=t.pageHandlerModule}GetNotificationName(){return r.sM.TRAVEL_CHEAPER_HOTEL_NOTIFICATION}getDateString(e){if(!e)return"";try{const t={day:"numeric",month:"short"},i=Ed(),n=new Date(e);return n instanceof Date&&!isNaN(n.valueOf())?n.toLocaleString(i,t)??"":""}catch(e){return""}}getImageUrl(e,t,i){return e?e.ThumbnailId?`https://bing.com/th?id=${e.ThumbnailId}&w=${t??50}&h=${i??50}&c=1`:e.SourceUrl?e.SourceUrl:"":""}FormatPrice(e){return`${e?.CurrencySymbol??""}${e?.Value??""}`}AddDataToTravelCheaperHotelCard(e){if(!this.travelCheaperHotelCard||!e)return;this.travelCheaperHotelCard.data=e;const t=this.getDateString(e.hotelSearchResponse?.HotelQuery?.CheckInDate),i=this.getDateString(e.hotelSearchResponse?.HotelQuery?.CheckOutDate);this.travelCheaperHotelCard.stayDatesString=t+" - "+i;const n=e.hotelSearchResponse?.HotelQuery?.RoomCount??1,o=1===n?e.strings?._1Room:e.strings?.nRooms.replace("$1",n.toString())??"",r=e.hotelSearchResponse?.HotelQuery?.GuestCount??1,a=1===r?e.strings?._1Adult:e.strings?.nAdults.replace("$1",r.toString())??"";this.travelCheaperHotelCard.roomsGuestsString=" • "+o+" • "+a,this.travelCheaperHotelCard.cheapestProviderName=e.hotelSearchResponse?.HotelResults?.[0]?.BookingOptions?.[0]?.ProviderName??"",this.travelCheaperHotelCard.getDealNowString=e.strings?.getDealNow??"";const s=e.hotelSearchResponse?.HotelResults?.[0]?.BookingOptions?.[0]?.ProviderLogo;this.travelCheaperHotelCard.cheapestProviderLogo=this.getImageUrl(s,12,12),this.travelCheaperHotelCard.saveString=e.strings?.save??"";const l=Cd(e.hotelSearchResponse?.HotelQuery?.MaximumPrice,e.hotelSearchResponse?.HotelResults?.[0]?.BookingOptions?.[0]?.Price);this.travelCheaperHotelCard.maximumSavingsString=this.FormatPrice(l);const c=e.hotelSearchResponse?.HotelResults?.[0]?.BookingOptions?.[0]?.PropertyImage;this.travelCheaperHotelCard.propertyImage=this.getImageUrl(c,78,78),this.travelCheaperHotelCard.propertyName=e.hotelSearchResponse?.HotelResults?.[0]?.Name??"",this.travelCheaperHotelCard.cheapestPriceCurrencyString=e.hotelSearchResponse?.HotelResults?.[0]?.BookingOptions?.[0]?.Price?.CurrencySymbol??"",this.travelCheaperHotelCard.cheapestPriceValueString=e.hotelSearchResponse?.HotelResults?.[0]?.BookingOptions?.[0]?.Price?.Value?.toString()??"",this.travelCheaperHotelCard.originalPriceString=this.FormatPrice(e.hotelSearchResponse?.HotelQuery?.MaximumPrice),this.travelCheaperHotelCard.perRoomPerNightString=e.strings?.perRoomPerNight??"",this.travelCheaperHotelCard.providerBookNowUrl=e.hotelSearchResponse?.HotelResults?.[0]?.BookingOptions?.[0]?.Link??""}eventListener(e){e||(e={ButtonName:i.$S.TravelHotelCardClicked,Message:"",UrlToRedirect:""}),this.pageHandlerModule.RecordAsUserAction(K.bS.TRAVEL_CHEAPER_HOTEL_CLICK),this.pageHandlerModule.RecordAsUserEngagement(q.FV.TRAVEL_CHEAPER_HOTEL_CLICK,this.flyoutData.common.popupOrigination);const t=new W.Z(e.ButtonName,this.telemetryUtilities.setContentViewed(this.GetNotificationName()));e.Metadata&&(t.Metadata=JSON.stringify(e.Metadata)),this.logModule.LogInfoEvent(i.R.ButtonClick,e.Message,t),e.UrlToRedirect&&setTimeout((()=>{this.pageHandlerModule.NavigateToUrl(e.UrlToRedirect)}),1e3)}CreateUx(){const e=(0,Y.Ux)("div");this.utilities.applyStyles(this.flyoutData.common.shopping,"\n ::part(header-fixed) {\n border-bottom: 1px solid var(--notification-header-bottom-border);\n }\n "),this.flyoutData.common.shopping.classList.add("noSections"),e.style.width="100%",e.slot="header-content";const t=(0,Y.Ux)("msft-travel-cheaper-hotel-card");return this.travelCheaperHotelCard=t,this.AddDataToTravelCheaperHotelCard(this.travelCheaperHotelsData),this.travelCheaperHotelCard.eventListener=this.eventListener.bind(this),e.append(t),e}async GetStoredCheapHotelData(){try{const e=await this.storageHandler.getStorageString(Ce.Q.TravelCheaperHotelData),t=e?JSON.parse(e):void 0;return t?.currentDomain===this.flyoutData.common.domain?(t.strings={ad:this.flyoutData?.strings?.travelAd,_1Adult:this.flyoutData?.strings?.travel1Adult,nAdults:this.flyoutData?.strings?.travelNAdults,bookWith:this.flyoutData?.strings?.travelBookWith,for1Night:this.flyoutData?.strings?.travelFor1Night,forNNights:this.flyoutData?.strings?.travelForNNights,getBetterDealOn:this.flyoutData?.strings?.travelGetBetterDealOn,getDealNow:this.flyoutData?.strings?.travelGetDealNow,perRoomPerNight:this.flyoutData?.strings?.travelPerRoomPerNight,_1Room:this.flyoutData?.strings?.travel1Room,nRooms:this.flyoutData?.strings?.travelNRooms,save:this.flyoutData?.strings?.travelSave},t):void 0}catch(e){return}}RenderNotification(e){const t=this.CreateUx(),i=this.utilities.createNotificationModule(t,this.GetNotificationName(),this);return Promise.resolve(i)}async ShouldRenderNotification(){return this.flyoutData.common.popupOrigination!==u.sR.AUTO_SHOW_TRAVEL_NOTIFICATION_CHEAPER_HOTEL_ROOM?Promise.resolve(!1):(this.travelCheaperHotelsData=await this.GetStoredCheapHotelData(),this.travelCheaperHotelsData?Promise.resolve(!0):Promise.resolve(!1))}PostProcessingNotification(e,t){this.flyoutData.common.shopping&&this.flyoutData.common.shopping.setAttribute("fixed-title",this.flyoutData.strings.travel)}GetPopupOriginationList(){return[u.sR.AUTO_SHOW_TRAVEL_NOTIFICATION_CHEAPER_HOTEL_ROOM]}}(this.flyoutData,this.utilities)),this.travelCheaperHotelsNotificationModule}GetDiscoverPaneAvailableModules(){return[this.GetProductSummaryModule(),this.GetBuyingGuidesModule(),this.GetSmartCompareModule(),this.GetPriceHistoryModule(),this.GetPriceComparisonModule(),this.GetProductTrackingModule(),this.GetCouponModule(),this.GetCjkSimilarProductsModule(),this.GetTravelCheaperFlightsModule(),this.GetExpertInsightsModule(),this.GetProductCollectionsModule()]}GetTravelCheaperFlightsModule(){return this.travelCheaperFlightsModule||(this.travelCheaperFlightsModule=new aI(this.flyoutData,this.utilities)),this.travelCheaperFlightsModule}GetPostPurchaseRewardsModule(){return this.postPurchaseRewardsModule||(this.postPurchaseRewardsModule=new F_(this.GetStateManagementModule(),this.flyoutData,this.utilities)),this.postPurchaseRewardsModule}GetPostPurchaseRewardsNotificationModule(){return this.postPurchaseRewardsNotificationModule||(this.postPurchaseRewardsNotificationModule=new Z_(this.GetStateManagementModule(),this.flyoutData,this.utilities)),this.postPurchaseRewardsNotificationModule}GetCjkSimilarProductsModule(){return this.cjkSimilarProductsModule||(this.cjkSimilarProductsModule=new Hm(this.flyoutData,this.utilities,this.commonAssets,this.stateManagementModule)),this.cjkSimilarProductsModule}GetDeferredCashbackModules(){return e.R.isExperimentActive(f.H.CashbackDashboard)?[this.GetDeferredCashbackModule()]:[]}GetAvailableModules(){if(this.flyoutData.common.isCJKEnabled)return[this.GetPriceHistoryModule(),this.GetPriceComparisonModule(),this.GetCouponModule(),this.GetCjkSimilarProductsModule(),this.GetProductHistoryModule(),this.GetFeedbackModule()];if(e.R.isPCBannerUXExperimentActive())return[this.GetPriceComparisonModule()];{const e=[this.GetBGAAModule(),this.GetSANConsentModule(),this.GetVirtualCardModule(),this.GetUnifiedCashBackModule(),this.GetCashBackModule(),this.GetCashBackActivateModule(),this.GetCashBackDelayedEnrollmentModule(),this.GetPriceHistoryModule(),this.GetProductSummaryCardModule(),this.GetPriceComparisonModule(),this.GetWishlistModule(),this.GetCampaignBannerModule(),this.GetCampaignPDPCashbackModule(),this.GetCampaignFeedModule(),this.GetClippingModule(),this.GetCouponModule(),this.GetActiveRetailerInboxCouponsModule(),this.GetDealsModule(),this.GetAutosReviewsModule(),this.GetProductHistoryModule(),this.GetRewardModule(),this.GetSimilarSellerModule(),this.GetPaymentOptionsModule(),this.GetItemizedCashbackModule(),this.GetAutosMyGarageModule(),this.GetAutosMarketplaceModule(),this.GetMomentInTimeModule(),this.GetTrendingOffersModule(),this.GetSimilarOffersModule(),this.GetDailyDealsModule(),this.GetVisualSearchModule(),this.GetRelatedProductsModule(),this.GetBuyDirectModule(),this.GetInfiniteCategoryFeedModule(),this.GetProductTrackingModule(),this.GetProductCollectionsModule(),this.GetShoppingTripsModule(),this.GetFeedbackModule(),this.GetTrendingCouponsModule(),this.GetProductSummaryModule(),this.GetSmartCompareModule(),this.GetBuyingGuidesModule(),this.GetTravelCheaperFlightsModule(),this.GetPostPurchaseRewardsModule(),this.GetExpertInsightsModule(),this.GetDiscoverChatChipsModule()];return e.push(this.GetAbandonedCartModule()),e}}GetAvailableGuestModules(){return this.flyoutData.common.isCJKEnabled?[this.GetPriceHistoryModule(),this.GetPriceComparisonModule(),this.GetCouponModule(),this.GetCjkSimilarProductsModule(),this.GetProductHistoryModule(),this.GetFeedbackModule()]:[this.GetUnifiedCashBackModule(),this.GetCashBackModule(),this.GetCashBackActivateModule(),this.GetCashBackDelayedEnrollmentModule(),this.GetPriceHistoryModule(),this.GetProductSummaryCardModule(),this.GetPriceComparisonModule(),this.GetCouponModule(),this.GetActiveRetailerInboxCouponsModule(),this.GetDealsModule(),this.GetAutosReviewsModule(),this.GetProductHistoryModule(),this.GetRewardModule(),this.GetFeedbackModule(),this.GetAutosMyGarageModule(),this.GetAutosMarketplaceModule(),this.GetTrendingCouponsModule(),this.GetMomentInTimeModule()]}GetAvailableNotificationModules(){let e=[];return this.flyoutData.common.openedWith===r.Te.Auto?e=[this.GetCampaignAwarenessNotificationModule(),this.GetCampaignPDPCashbackNotificationModule(),this.GetCashbackPlusCouponsCompositeNotificationModule(),this.GetLowerPricePlusCashbackPlusCouponsCompositeNotificationModule(),this.GetPriceDropPlusCashbackCompositeNotificationModule(),this.GetCouponsNotificationModule(),this.GetBGAANotificationModule(),this.GetProductBestCouponNotificationModule(),this.GetSANConsentNotificationModule(),this.GetUnifiedCashBackNotificationModule(),this.GetItemizedCashbackNotificationModule(),this.GetCashBackNotificationModule(),this.GetPostPurchaseConsentNotificationModule(),this.GetSimilarSellersNotificationModule(),this.GetRewardNotificationModule(),this.GetPriceComparisonNotificationModule(),this.GetVirtualCardNotificationModule(),this.GetAutosMarketplaceNotificationModule(),this.GetAutosReviewsModuleNotificationModule(),this.GetPriceHistoryNotificationModule(),this.GetProductTrackingNotificationModule(),this.GetAbandonedCartNotificationModule(),this.GetViewedProductPriceDropNotificationModule(),this.GetClippingNotificationModule(),this.GetTrendingCouponsNotificationModule(),this.GetEnrollRebatesConfirmationNotificationModule(),this.GetSearchBoxDemoNotificationModule(),this.GetProductTrackingOffersNotificationModule(),this.GetTravelCheaperFlightsNotificationModule(),this.GetTravelCheaperHotelsNotificationModule(),this.GetDiscoverNotificationModule(),this.GetArticlesCashbackNotificationModule(),this.GetPostPurchaseRewardsNotificationModule()]:this.flyoutData.common.isCJKEnabled&&this.flyoutData.common.openedWith===r.Te.Hover&&(e=[this.GetPriceHistoryNotificationModule(),this.GetPriceComparisonNotificationModule(),this.GetCouponsNotificationModule()]),e}}(C,S,b);S.viewModulesUtilities.addCommonStyles(b),await C.initializeModuleData(y,Y_,C,S.storageHandler),function(t,i){const n=document.querySelector("head"),o=t.common.shopping;if(n){const r=n.querySelector("title"),a=t.strings;if(!r||r.innerText!==a.commonFixedTitle){const t=(0,Y.Ux)("title");t.innerText=a.commonFixedTitle,n.appendChild(t),function(e,t){const i=document.createElement("DIV");i.innerHTML=e.getHeaderIcon(),i.slot="header-icon",t.appendChild(i)}(i,o),e.R.isPCBannerUXExperimentActive()?o.fixedTitle=a.pcPriceSectionTitle:o.fixedTitle=a.commonFixedTitle}}}(C,b),e.R.GetEnabledFeaturesMap().size>0&&Y_.TriggerSupportedExperiments(e.R.GetEnabledFeaturesMap()),function(e,n,o,r){try{const t=r.GetLoadTimeDataValue("impressionId",""),a=e.ApiData?e.ApiData.impressionId:"",s=t??"";o.setData(Jl.g.CouponImpressionId,a),o.setData(Jl.g.EdgeImpressionId,s),o.setData(Jl.g.DomainName,n),o.setData(Jl.g.Client,i.BN.Edge)}catch(e){const n=new t.Z(i.xu.OnErrorInvoked);o.LogErrorEvent(i.R.EdgeFlyoutStatus,"Data creation Exception at InitializeCouponsApiData",n)}}(C.dataStoreModule,C.common.domain,y,o),S.viewModulesUtilities.trapFlyoutFocusMac();const O=document.querySelector("#divContentWrapper");await w.GetFlyoutRendererModule().createModules(O);const P=new class{HandleAdditionalBody(){const e=document.querySelectorAll("body");e&&e.length>1&&e[0].attributes[0].textContent&&(e[1].setAttribute("style",e[0].attributes[0].textContent),e[0].remove())}};new MutationObserver((()=>{P.HandleAdditionalBody()})).observe(document,{attributes:!0,childList:!0,subtree:!0}),async function(e,n,o,r){if(void 0!==e)try{let a=null;const s=o.PopupOrigination;if(e===s?.AUTO_SHOW_BING_SEARCH?a=await r.GetCouponModule().ShouldRenderModule():e===s?.AUTO_SHOW_URL_PARAM_REBATES?a=await r.GetCashBackModule().ShouldRenderModule():e===s?.AUTO_SHOW_URL_PARAM_PRICE_COMPARISON?a=await r.GetPriceComparisonModule().ShouldRenderModule():e===s?.AUTO_SHOW_URL_PARAM_PRICE_HISTORY&&(a=await r.GetPriceHistoryModule().ShouldRenderModule()),null!==a){const o=new t.Z(i.xu.AutoOpenUsingUrlParam);n.LogInfoEvent(i.R.EdgeFlyoutStatus,`Auto open using url param - ${e} - is succeeded: ${a}`,o)}}catch(e){}}(C.common.popupOrigination,y,Y_,w),function(e,n,o,a){const s=n&&n===r.Te.Auto?i.xu.AutoTrigger:i.xu.UserTrigger,l=new t.Z(s);if(a.LogInfoEvent(i.R.EdgeFlyoutStatus,function(e){const t={lastCommittedUrl:e.GetLoadTimeDataValue("lastCommittedURL",""),navChain:X_(e)};return JSON.stringify(t)}(e),l),o){const e=new t.Z(i.xu.OpenedInCheckout);a.LogInfoEvent(i.R.EdgeFlyoutStatus,"",e)}}(o,C.common.openedWith,C.common.isCheckoutPage,y)}catch(e){const o=new q_(Y_,n.T_),r=new t.Z(i.xu.OnErrorInvoked);o.setData(Jl.g.Client,i.BN.Edge),o.LogErrorEvent(i.R.EdgeFlyoutStatus,`V1 initialize error ${e?.message}`,r),document.querySelector("msft-edge-shopping")||J_(o,new a.Z,new ei,0,"V1 Initialize")}}))}()}();