{"version":3,"file":"src_modules_destination-search-lazy_index_ts.5977848b1c7a2d60.js","mappings":"knCAYO,MAAMA,MAAgCC,MAC3C,6DACAC,SAEWC,MAAoBF,MAC/B,iDACAC,SAEWE,MAAeH,MAC1B,4CACAC,SAEWG,MAAcJ,MACzB,2CACAC,SAEWI,MAAiBL,MAC5B,8CACAC,SAEWK,MAA0BN,MACrC,uDACAC,SAEWM,MAAsBP,MACjC,mDACAC,SAEWO,MAA4BR,MACvC,mDACAC,SAGWQ,MAAcT,MACzB,2CACAC,SAGWS,MAA2BV,MACtC,wDACAC,SAGWU,MAAiCX,MAC5C,8DACAC,SAGWW,MAAqBZ,MAChC,kDACAC,SClDWY,IDqDPC,EAAMC,MAAM,CAChBhB,iCACAG,qBACAC,gBACAC,eACAC,kBACAC,2BACAC,uBACAC,6BACAC,eACAC,4BACAC,kCACAC,wBCjEsD,CACtDI,qBAAsB,GACtBC,UAAW,CACTC,mBAAeC,EACfC,gBAAYD,GAEdE,YAAaC,MAAyBC,QACtCC,SAAUC,KAASC,SAOfC,GAAyBC,GACtBA,GAAcC,OAAO,CAACf,EAA8BgB,IACxChB,EAAIiB,MAAOC,GAAMA,EAAEC,KAAOH,EAAQG,IACjC,IAAInB,EAAKgB,GAAWhB,EACrC,IAGQoB,MAAiCC,MAXA,CAC5CC,QAASvB,IAWTwB,EACAC,MAAGC,GAA8D,CAACC,EAAOC,SAElED,EACH,CAACC,EAAOC,MAAMT,IAAK,IACdO,EAAMC,EAAOC,MAAMT,OACnBQ,EAAOE,eAGf,EACDL,MAAGC,GAAkD,CAACC,EAAOC,SAEtDD,EACH,CAACC,EAAOC,MAAMT,IAAK,IACdO,EAAMC,EAAOC,MAAMT,IACtBW,iBAAiB,OAGtB,EACDN,MAAGC,GAA6C,CAACC,EAAOC,SAEjDD,EACH,CAACC,EAAOC,MAAMT,IAAK,IACdO,EAAMC,EAAOC,MAAMT,IACtBhB,UAAWwB,EAAOxB,eAGvB,EACDqB,MAAGC,GAA4C,CAAC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A,EAAAD,IDtDzCnF,MADF,UACEA,CADyB,SAEvBA,MAAA,qCACFA,QACAA,MAAA,EAAAy2B,GAAA,sDASAz2B,MAAA,WACEA,MAAA,EAAA02B,GAAA,yDAWJ12B,iBAxBOA,cAAA,cAAAoF,EAAA0tB,oBAC4B9yB,cAAA,wBAAAoF,EAAAitB,uBAG9BryB,cAAA,OAAAA,MAAA,IAAAoF,EAAAsqB,sCAAAtqB,EAAA0tB,oBAUE9yB,MAAA,GAAAA,MAAA,OAAAA,MAAA,IAAAoF,EAAAsqB,kGCwCM+C,CAA8B","names":["setDestinationSearchSelection","createAction","props","removeRouteUpdate","setTripDates","setTripType","setTravelClass","setSelectedDestinations","setFromLocationCode","setRestrictToDestinations","setMaxPrice","setShowDirectFlightsOnly","setDestinationsBeforeFiltering","setRoundTripPrices","defaultFilters","all","union","selectedDestinations","tripDates","departureDate","undefined","returnDate","travelClass","GlobalBookingTravelClass","ECONOMY","tripType","TripType","RETURN","getUniqueDestinations","destinations","reduce","current","every","d","id","destinationSearchFilterReducer","createReducer","default","initialStates","on","DestinationSearchFilterActions","state","action","meta","selection","skipRouteUpdate","fromLocationCode","restrictToDestinations","maxPrice","showDirectFlightsOnly","destinationsBeforeFiltering","roundTripPrices","_selectDestinationSearchFilterStates","createFeatureSelector","DESTINATION_SEARCH_FILTER_STATE_FEATURE_NAME","_filterState","createSelector","allFilterStates","safeSelect","_allFilterStates","filterState","selectedDestinationsState","_selectSelectedDesinations","restrictToDestinationsState","_selectRestrictToDestinationsState","Continent","EUROPE","MIDDLE_EAST","AMERICA","ASIA_PACIFIC","AFRICA","DestinationSearchOffersService","constructor","configService","instantsearchService","cheapestPriceForAllDestinationsService","destinationSearchService","store$","cmsDataService","languageService","amDestinationService","this","status$","Subject","loaderStatus$","pipe","startWith","PriceLoadingState","INITIAL","campaigns$","getOngoingCampaigns","langValue","localeValue","getDestinationsWithOffers","restrictions","identifier","content","selectedOriginLocationCode","selectedTripDates$","bothDatesArePresent","isPresent","bothDatesAreUndefined","oneWayWithOneDatePresent","ONEWAY","_selectTripDates","tripDatesState","selectedTripType$","_selectTripType","tripTypeState","selectedTravelClass$","_selectTravelClass","travelClassState","filteredDestinations$","combineLatest","destinationSearch","distinctUntilChanged","map","destinationFilters","allDestinations","flattenDestinations","filter","type","DestinationSearchItemType","DESTINATION","matchingDestinations","destination","destinationMatchesFilters","isNotEmpty","offersWithDates$","getOffersWithDates","allOffers$","getAllOffers","amDestinationList$","includes","amDestinationList","of","offers","campaigns","offersMap","allOffers","offer","amDestination","find","dest","airportCode","mapToAmDestinationOffer","mapToBlockOffer","locationCode","item","localSettings","showDestinationsWithoutPrice","price","forceLoadingScreen","duration","snapshot","LOADING","next","setTimeout","LOADED","selectedDates$","tripType$","selectedDates","switchMap","locationCodes","params","departureLocationCodes","destinationLocationCodes","numberOfDays","travelClasses","toLowerCase","ECOPREMIUM","BUSINESS","isReturnWithBothDates","isOnewayWithOneDate","toString","Object","assign","lengthOfStay","diff","Date","TimeUnit","day","tripTypes","locale","getPricesForFlights","cfg","instantSearchUrl","catchError","mapToMarketingOffers","tap","finShare","merge","NON_EUROPE_SITES","oneWayOffers","bothWayOffers","selectedTravelClass","matchingOffer","matchingEconomyOffer","prices","t","toUpperCase","matchingPremiumEconomyOffer","matchingBusinessOffer","showAllOffers","MIXED","showPremiumEconomyOffer","showBusinessOffer","marketingOffer","title","origin","getOfferPrice","onewayPrice","getPriceByTripTypeAndTravelClass","returnPrice","link","url","imageData","picture","amount","Math","ceil","Number","flag","countryCode","countryName","country","currency","titleMaster","length","continent","continentMaster","badgeIcon","badgeLabel","campaign","some","destinationsByOrigin","campaignTravelClass","campaignLabel","enableBlackTeaser","getDestinationInCampaign","directFlight","isShortHaul","showOffer","currencyCode","filters","f","textMatch","COUNTRY","CONTINENT","static","__ngFactoryType__","i0","i1","i2","i3","i4","i5","i6","i7","fesm2022_core","jDH","factory","ɵfac","DestinationSearchLazyModule","$C","G2t","OndMarketingDataService","imports","StoreModule","forFeature","CommonModule","UiTranslateModule","PipesModule","ComponentsModule","FormsModule","DirectiveModule","ContentComponentsModule","UiComponentsModule","GtmModule","FinFormsModule","DestinationSearchModule","calendarDates_r3","_r4","ctx_r1","openDatepicker","DestinationSearchDateFieldComponent_ng_container_0_button_10_ng_container_5_Template","DestinationSearchDateFieldComponent_ng_container_0_button_10_ng_container_6_Template","SvgLibraryIcon","MINUS","$event","_r5","updateCalendarDates","closeDatepicker","_c0","showReturnField$","selectableDatesRange","_c1","_r1","DestinationSearchDateFieldComponent_ng_container_0_ng_container_8_Template","DestinationSearchDateFieldComponent_ng_container_0_ng_container_9_Template","DestinationSearchDateFieldComponent_ng_container_0_button_10_Template","DestinationSearchDateFieldComponent_ng_container_0_div_12_Template","datepickerOpen","ngIf","updateTravelDates","DestinationSearchDateFieldComponent_ng_container_0_fcom_datepicker_15_Template","DestinationSearchDateFieldComponent","cd","dateChange","EventEmitter","calendarDates$","BehaviorSubject","currentDate","LocalDate","now","subscription","Subscription","ngOnInit","plusDays","add","subscribe","detectChanges","ngOnDestroy","unsubscribe","calendarDates","emit","VBU","selectors","inputs","outputs","decls","vars","consts","template","rf","ctx","DestinationSearchDateFieldComponent_ng_container_0_Template","item_r2","$implicit","ctx_r2","removeChip","isMobile$","_c2","cmsStylesOverride","CLOSE_DELETE","TagTheme","ACTIVE","removeAll","DestinationSearchFilterChipsComponent_ul_4_li_2_Template","DestinationSearchFilterChipsComponent_ul_4_li_3_Template","trackByFn","DestinationSearchFilterChipsComponent","mediaQueryService","TestVariant","tagRemove","isBreakpoint$","FilterAction","REMOVE_ALL","_index","REMOVE","buttons","tagsList","nativeElement","querySelectorAll","focus","a11yHeading","viewQuery","DestinationSearchFilterChipsComponent_ul_4_Template","SEARCH","CHECKMARK","destination_r4","_r3","toggleDestinationSelection","DestinationSearchFilterToFieldComponent_li_34_fcom_icon_4_Template","destinationIsHighlighted","i_r5","DESTINATION_TYPE","destinationIsSelected","item_r7","_r6","removeTag","DestinationSearchFilterToFieldComponent_div_42_li_6_Template","DestinationSearchFilterToFieldComponent","document","platform","elementRef","ButtonSize","ButtonTheme","valueChange","matchingDestinations$","optionsListVisible$","highlightedItem$","destinationInput","UntypedFormControl","subscriptions","valueChanges","debounceTime","allDestinations$","Boolean","query","updated","mapQueryMatches","matchesQuery","updateDestinationOptionsList","ngAfterViewInit","index","highlightedElement","optionsListbox","querySelector","isScrolledIntoView","scrollTop","offsetTop","inputHasFocus","activeElement","inputField","handleComponentFocusOut","event","el","contains","relatedTarget","stopPropagation","closeOptionsList","onClickInputArea","inputFieldButton","target","getValue","openOptionsList","fromBottom","maxHighlightIndex","handleFocus","reset","showButton","showResultsButton","buttonElement","tags","tagList","remainingTags","Array","from","c","lastTag","onDestinationInputKeydown","optionsListOpen","getKeyCodeFromEvent","KeyCodes","ESC","UP","highlightPreviousItem","DOWN","highlightNextItem","ENTER","highlightIndex","isSelected","selected","ADD","destinationIndex","element","isPlatformServer","getBoundingClientRect","top","height","itemParent","parentNode","itemParentRect","bottom","documentElement","clientHeight","destinationMatchesQuery","normalizedTitle","normalizedTitleMaster","countryMaster","recursiveMatchCheck","selfMatch","items","childMatch","child","isBlank","value","selectedItem","findIndex","isNotBlank","DOCUMENT","PLATFORM_ID","DestinationSearchFilterToFieldComponent_fcom_icon_26_Template","DestinationSearchFilterToFieldComponent_fcom_icon_28_Template","DestinationSearchFilterToFieldComponent_li_34_Template","DestinationSearchFilterToFieldComponent_li_36_Template","DestinationSearchFilterToFieldComponent_div_42_Template","_c5","tmp_5_0","inputField_r8","tmp_19_0","LIGHT_PRIMARY_CTA_HEATHER","title_r1","detailText","iconName","DestinationSearchHeroComponent_section_3_header_1_fcom_icon_3_Template","campaignText","aspectRatio$","DestinationSearchHeroComponent_section_3_header_1_Template","DestinationSearchHeroComponent_section_3_section_2_Template","DestinationSearchHeroComponent","campaignBannerService","media","related","teaserText","AIRCRAFT_TILTED","setCampaignBannerVisibility","DestinationSearchHeroComponent_h1_1_Template","DestinationSearchHeroComponent_div_2_Template","DestinationSearchHeroComponent_section_3_Template","teaserTitle","DestinationSearchResultsItemComponent","isAmContinueModalOpen","destinationClicked","flightHotelClicked","calendarClicked","showRoundTripPrices$","emitClick","emitCalendarClick","openAmContinueModal","amLink","flightHotelUrl","closeAmContinueModal","viewStyle","enableTeaser","DestinationSearchCampaignRibbonComponent","gtmService","CmsTaxonomyGeneral","onLinkClick","trackElement","GaContext","LANDING_PAGE","ElementTypes","LINK","ElementActions","CLICK","accordionButton","getElementsByTagName","getAttribute","click","bookByText","travelPeriodText","termsAndConditionText","termsAndConditionLink","theme","BLACK_FRIDAY","HEATHER_BG","CLOCK","TIMETABLE","ORIGIN_SELECTOR_CONFIG","DE","CH","AT","EE","LV","LT","PL","HU","FR","IT","ES","PT","US","JP","SE","NO","GB","DK","option_r3","label","optionChange","SortOptionsComponent_div_0_option_3_Template","fieldName","selected$","options_r4","SortOptionsComponent","sortOptions","SortOptionsComponent_div_0_Template","selectOrigin","originOptions$","selectedOriginLocationName$","DestinationSearchOriginSelectorComponent","locationRouteCffService","originSelected","countryCode$","customOrigins","keys","origins$","hasSelector$","disableOriginSelector","origins","getLocaleCityName","cityName","options","option","bestGuessFor","locationData","originLocationCode","DestinationSearchOriginSelectorComponent_div_0_Template","DestinationSearchOriginSelectorComponent_p_2_Template","_r2","onOriginSelected","selectedOriginLocationCode$","ribbon_r4","termsAndConditionLink$","clearAllFilters","LoaderTheme","INLINE","isContinentPromo_r7","promoItem_r6","contentType","CmsContentType","CMArticle","CMPicture","segment","NEVER","subjectTaxonomyTags","PromoTheme","BLACK","NORDIC_BLUE_900_BG","BLUE","WHITE","aspectRatioForPromo$","DestinationSearchResultsComponent_ng_container_19_ng_container_1_Template","promoItems_r9","promoItem_r8","DestinationSearchResultsComponent_ng_container_21_ng_container_1_ng_container_1_ng_container_1_Template","categorizedDestinationItems_r11","categorizedDestinations_r12","category_r10","categoryLabel","promo$","categoryLabel_r13","DestinationSearchResultsComponent_ng_container_21_ng_container_1_ng_template_2_ng_container_1_ng_container_1_ng_container_1_Template","promoItem_r14","DestinationSearchResultsComponent_ng_container_21_ng_container_1_ng_template_2_ng_container_1_ng_container_1_Template","promoItem$_r15","_r16","destinationClick","flightHotelClick","selectedOriginLocationCode_r17","destination_r18","DestinationSearchResultsComponent_ng_container_21_ng_container_1_ng_template_2_div_0_Template","DestinationSearchResultsComponent_ng_container_21_ng_container_1_ng_template_2_ng_container_1_Template","DestinationSearchResultsComponent_ng_container_21_ng_container_1_ng_template_2_fin_destination_search_results_item_3_Template","disableSectionHeadings","isFilterApplied$","destinationItems_r19","DestinationSearchResultsComponent_ng_container_21_ng_container_1_ng_container_1_Template","DestinationSearchResultsComponent_ng_container_21_ng_container_1_ng_template_2_Template","DestinationSearchResultsComponent_ng_container_21_ng_container_1_Template","categoryList$","DestinationSearchResultsComponent_ng_container_23_ng_container_1_Template","promoItem_r20","DestinationSearchResultsComponent","appStore$","destinationSearchOffersService","priceCalendarService","DestinationSearchViewStyle","TILES","CmsTripTypeMap","SORTING","SortBehavior","calendarOpen$","sortByValidPriceFirst","i","concat","_selectRoundTripPrices","roundTripPricesState","profile$","loginStatus","memberLoginStatus","LoginStatus","PENDING","LOGGED_IN","profile","topPromoItems$","topPromoItems","jsonUrl","fetchPromoItems","bottomPromoItems$","bottomPromoItems","updatingPricesLoader$","isMobile","customContinents","customDestinations$","sortByValues","ALPHABETICAL","PRICE","sortOrder$","selectedSortBy","ribbon","ribbon$","getFragmentJson","tag","sortedDestinations$","filteredDestinationsWithOffers$","customDestinations","targetCountry","withLatestFrom","sorting","sort","sortByAlphabetical","sortByPrice","CUSTOM","continents","toCamelCase","continentPromoItems","init","s","fetchContinentPromoItem","categorizedDestinations$","categoryList","key","push","fromEntries","k","entries","_","v","memberProfile","tier","urls","getCollectionItems","isCmsArticle","getArticleButton","targets","firstMedia","mediaContent","destinationItem","openPriceCalendar","priceCalendarCTAClicked","closePriceCalendar","destinationBlockOffer","offerTripType","take","selectedTripType","prefillBookingWidget","replace","DESTINATION_MAIN_PAGE","LIST_ITEM","dispatch","SELECT_BOX","trackByCmsContent","contentId","a","b","Infinity","nestingDepth","duplicates","article","data","openInNewTab","DestinationSearchResultsComponent_section_0_Template","DestinationSearchResultsComponent_div_4_Template","DestinationSearchResultsComponent_fcom_notification_9_Template","DestinationSearchResultsComponent_div_13_Template","DestinationSearchResultsComponent_ng_template_15_Template","DestinationSearchResultsComponent_ng_template_17_Template","DestinationSearchResultsComponent_ng_container_19_Template","DestinationSearchResultsComponent_ng_container_21_Template","DestinationSearchResultsComponent_ng_container_23_Template","DestinationSearchResultsComponent_div_25_Template","loadingDestinations_r21","travelClass_r2","selectTravelClass","DestinationSearchTravelClassSelectionComponent_div_12_div_1_fcom_icon_5_Template","travelClasses_r5","i_r4","COMMON_BOOKING_TRAVEL_CLASSES","translationKey","DestinationSearchTravelClassSelectionComponent_div_12_div_1_Template","DestinationSearchTravelClassSelectionComponent","cdr","modalOpen","selectedTravelClassChange","splice","initialTravelClass$","markForCheck","closeModal","openModal","DestinationSearchTravelClassSelectionComponent_div_12_Template","CHEVRON_DOWN","continent_r5","selectedContinent$","last_r6","count","tmp_16_0","DEFAULT","DestinationSearchBarComponent_section_0_div_7_div_13_div_1_fcom_tag_button_1_Template","continents$","DestinationSearchBarComponent_section_0_div_7_div_13_div_1_Template","DestinationSearchBarComponent_section_0_div_7_div_13_ng_container_2_Template","searchBarContent_r7","DestinationSearchBarComponent_section_0_div_7_footer_15_ng_container_1_Template","searchBarSelections_r8","DestinationSearchBarComponent_section_0_div_7_ng_container_12_Template","DestinationSearchBarComponent_section_0_div_7_div_13_Template","DestinationSearchBarComponent_section_0_div_7_footer_15_Template","searchBar_r10","isMobile_r9","DestinationSearchBarComponent_section_0_div_7_Template","isVisible$","continent_r13","_r12","last_r14","tmp_13_0","DestinationSearchBarComponent_section_2_div_6_fcom_tag_button_1_Template","DestinationSearchBarComponent_section_2_div_8_ng_container_1_Template","_r11","DestinationSearchBarComponent_section_2_ng_container_2_Template","DestinationSearchBarComponent_section_2_div_6_Template","DestinationSearchBarComponent_section_2_ng_container_7_Template","DestinationSearchBarComponent_section_2_div_8_Template","_c6","isMobile_r16","TRASH","_r15","DestinationSearchBarComponent_ng_template_4_fcom_icon_9_Template","DestinationSearchBarComponent_ng_template_4_fcom_icon_11_Template","inputField_r17","isStartTyping$","DestinationSearchBarComponent_ng_template_6_ng_container_2_ng_container_1_ng_container_1_ng_container_12_Template","country_r18","expand_r19","isOpen$","destinationTemplate_r20","_c7","DestinationSearchBarComponent_ng_template_6_ng_container_2_ng_container_1_ng_container_1_Template","destination_r21","DestinationSearchBarComponent_ng_template_6_ng_container_2_ng_container_2_ng_container_1_Template","_c8","i_r23","DestinationSearchBarComponent_ng_template_6_ng_container_2_ng_container_1_Template","DestinationSearchBarComponent_ng_template_6_ng_container_2_ng_container_2_Template","DestinationSearchBarComponent_ng_template_6_ng_container_2_Template","DestinationSearchBarComponent_ng_template_6_li_4_Template","tmp_8_0","_r24","destination_r25","toggleDestinationByKeyboard","_c9","dest_r27","_r26","last_r28","DestinationSearchBarComponent_ng_template_8_ng_container_0_li_1_Template","DestinationSearchBarComponent_ng_template_8_ng_container_0_ng_container_2_Template","_r29","index_r31","DestinationSearchBarComponent_ng_template_8_ng_container_0_Template","DestinationSearchBarComponent_ng_template_8_ng_container_1_Template","_r33","item_r35","_r34","DestinationSearchBarComponent_ng_template_10_ng_container_9_li_3_Template","_r32","DestinationSearchBarComponent_ng_template_10_ng_container_8_Template","DestinationSearchBarComponent_ng_template_10_ng_container_9_Template","_c10","MODAL_OPEN_CLASS_NAME","FILTERS_ORDER","DestinationSearchBarComponent","renderer","IconLibrary","IconPosition","inputFocusState","optionsListVisibilityChanged","mainFilters","recursiveMapDestinationCount","isVisible","shouldSetOverlay","addClass","body","removeClass","searchString","array","closeOptionsList$","resetInputValue","preventDefault","className","countrySelectedDestinations","shouldSelectAll","filteredDestinationByCountry","filteredDestinationByDestination","SPACE","mapDestinations","acc","result","finland","unshift","indexOf","DestinationSearchBarComponent_section_0_Template","DestinationSearchBarComponent_section_2_Template","DestinationSearchBarComponent_ng_template_4_Template","DestinationSearchBarComponent_ng_template_6_Template","DestinationSearchBarComponent_ng_template_8_Template","DestinationSearchBarComponent_ng_template_10_Template","filterDestinations","showRoundTripPrice","parseInt","selectedDestinations$","join","DestinationSearchFiltersComponent_Conditional_0_Conditional_13_Conditional_4_Template","DestinationSearchFiltersComponent_Conditional_0_Conditional_13_Conditional_6_Template","DestinationSearchFiltersComponent_Conditional_0_Conditional_15_ng_container_3_Template","stopsFilter_r3","showModal","resetAllFilters","DestinationSearchFiltersComponent_Conditional_0_Conditional_13_Template","DestinationSearchFiltersComponent_Conditional_0_Conditional_15_Template","DestinationSearchFiltersComponent_Conditional_0_ng_container_19_Template","isModalOpen","activeFilters$","numberOfFilteredDestinations$","tmp_14_0","showStopFilters","priceFilter_r4","closeFilters","resetStops","stopsFilterOpened","DestinationSearchFiltersComponent_Conditional_2_Conditional_15_ng_container_8_Template","priceInputForm","controls","stops","Stops","DIRECT_FLIGHTS","popoverOptions$","_r7","LEFT","LIGHT_TERTIARY_GHOST","resetPriceFilters","priceFilterOpened","DestinationSearchFiltersComponent_Conditional_2_ng_container_14_Template","DestinationSearchFiltersComponent_Conditional_2_Conditional_15_Template","DestinationSearchFiltersComponent_Conditional_2_Conditional_16_Template","priceFilteringActive$","priceButtonLabelKey$","_c4","String","priceInputValue$","_c3","_r8","roundTripOnly$","InputType","NUMBER","DESTINATION_FILTER_POPOVER_CONTEXT","DEFAULT_POPOVER_OPTIONS","context","zIndex","ALL_FLIGHTS","DestinationSearchFiltersComponent","popoverService","mobileFiltersOpened","stopsInputvalue$","FormGroup","priceInput","FormControl","roundTripOnly","sticky$","sticky","useFixedPosition","FINNISH_SITES","destinationsBeforeFiltering$","_selectDestinationsBeforeFiltering","destinationsBeforeFilteringState","prev","hasShortHaulFlights$","hasShortHaulFlights","closeByContext","searchBarVisible$","clearFilters$","RADIO","FORM","SUBMIT","skip","CHECKBOX","BUTTON","OPEN","setValue","DestinationSearchFiltersComponent_Conditional_0_Template","DestinationSearchFiltersComponent_Conditional_2_Template","DestinationSearchFiltersComponent_ng_template_3_Template","DestinationSearchFiltersComponent_ng_template_5_Template","onFilterToValueChange","onInputFilter","onOptionsListVisibilityChanged","closeSearchBarOptionsList$","DestinationSearchFormComponent_ng_container_8_fin_destination_search_bar_3_Template","onMobileFiltersOpened","DestinationSearchFormComponent_ng_container_8_fin_destination_search_filter_chips_9_Template","tmp_2_0","stickyEnabled$","state$","ANIMATION_STATE","VISIBLE","STICKY_NAV_HEIGHT","ScrollState","SCROLLING_DOWN_BELOW_SEARCH_BAR","SCROLLING_UP_BELOW_SEARCH_BAR","SCROLLED_TO_SEARCH_BAR_TOP","SCROLLED_PAST_SEARCH_BAR_TOP","HIDDEN","TRANSFORM_VALUES","DestinationSearchFormComponent","windowRef","scrollService","showFilters","ButtonMode","backdropElement","searchBarOptionListVisible$","isStickyNavTest$","initialSelection$","initialDestinationSearchSelection$","currentScrollPosition","nativeWindow","scrollY","originSearchBarPosition","container","offsetHeight","addBackdrop","removeBackdrop","listen","abs","scrollState","getScrollState","updateScrollStateAndSticky","newSelectedDestinations","getSelectedDestinationsOnFilterChange","selectedDestinationsTrackingString","selectedDestinationsToTrackingString","scrollTo","behavior","scrollingDown","createElement","position","left","width","background","forEach","setStyle","appendChild","removeChild","selectedDestination","visible","isOpen","DestinationSearchFormComponent_Conditional_6_Template","DestinationSearchFormComponent_ng_container_8_Template","trigger","style","opacity","transform","transition","animate","changeDetection","ctx_r0","destinationTeaserText","DestinationSearchHeaderComponent","DestinationSearchHeaderComponent_div_1_Template","showFilters$","DestinationSearchPageComponent","ALLOWED_DESTINATIONS_COUNT","activatedRoute","router","ReplaySubject","isSearchBarPresent","modificationDate","defaultOrigin$","getDefaultOriginLocationCode","restrictionsFromLocalSettings$","defaultOrigin","getRestrictionParamsFromLocalSettings","restrictionParams$","equals","restrictionsFromLocalSettings","restrictionParams","content$","states","queryParams","disableQueryParamsAndState","hasLocalSettingsSelections","filteredDestinations","supportedParams","enumValues","DestinationSearchQueryParams","getQueryParamsSelection","getLocalSettingsSelection","getCurrentNavigation","extras","skipFilterSet","rest","updateQueryParamsFromSelectedDestinations","_selectFromLocationCode","fromLocationCodeState","destinationsWithOffers$","destinationSearchFilters$","headerItem","header","viewTypeName","PageViewType","NO_GRID_FULL_WIDTH_PAGE_WITH_TITLE","getSupportedQueryParamValues","selections","split","p","decodeURI","originFromQuery","defaultOriginLocationCode","prefillTravelClass","cabin","prefillTripType","prefillSelectedDestinations","findDestinationsForQueryParams","directFlights","restrictToDestinationsRequest","isEmptyObjectOrHasEmptyValues","isArray","destinationsAsQueryParams","entrySet","allParams","param","paramString","navigate","replaceUrl","DestinationSearchPageComponent_fin_destination_search_form_3_Template","DestinationSearchPageComponent_fin_destination_search_results_6_Template"],"ignoreList":[],"sourceRoot":"webpack:///","sources":["./src/modules/destination-search-lazy/store/actions/destination-search-filter.actions.ts","./src/modules/destination-search-lazy/store/reducers/destination-search-filter.reducer.ts","./src/modules/destination-search-lazy/store/selectors/destination-search-filter.selector.ts","./src/modules/destination-search-lazy/interfaces/low-fare-finder-offers.interface.ts","./src/modules/destination-search-lazy/services/destination-search-offers.service.ts","./src/modules/destination-search-lazy/destination-search-lazy.module.ts","./src/modules/destination-search-lazy/components/destination-search-date-field/destination-search-date-field.component.html","./src/modules/destination-search-lazy/components/destination-search-date-field/destination-search-date-field.component.ts","./src/modules/destination-search-lazy/components/destination-search-filter-chips/destination-search-filter-chips.component.html","./src/modules/destination-search-lazy/components/destination-search-filter-chips/destination-search-filter-chips.component.ts","./src/modules/destination-search-lazy/components/destination-search-filter-to-field/destination-search-filter-to-field.component.html","./src/modules/destination-search-lazy/components/destination-search-filter-to-field/destination-search-filter-to-field.component.ts","./src/modules/destination-search-lazy/components/destination-search-hero/destination-search-hero.component.html","./src/modules/destination-search-lazy/components/destination-search-hero/destination-search-hero.component.ts","./src/modules/destination-search-lazy/components/destination-search-results-item/destination-search-results-item.component.ts","./src/modules/destination-search-lazy/components/destination-search-results-item/destination-search-results-item.component.html","./src/modules/destination-search-lazy/components/destination-search-campaign-ribbon/destination-search-campaign-ribbon.component.ts","./src/modules/destination-search-lazy/components/destination-search-campaign-ribbon/destination-search-campaign-ribbon.component.html","./src/modules/destination-search-lazy/constants.ts","./src/modules/destination-search-lazy/components/sort-options/sort-options.component.html","./src/modules/destination-search-lazy/components/sort-options/sort-options.component.ts","./src/modules/destination-search-lazy/components/destination-search-origin-selector/destination-search-origin-selector.component.html","./src/modules/destination-search-lazy/components/destination-search-origin-selector/destination-search-origin-selector.component.ts","./src/modules/destination-search-lazy/components/destination-search-results/destination-search-results.component.html","./src/modules/destination-search-lazy/components/destination-search-results/destination-search-results.component.ts","./src/modules/destination-search-lazy/components/destination-search-travel-class-selection/destination-search-travel-class-selection.component.html","./src/modules/destination-search-lazy/components/destination-search-travel-class-selection/destination-search-travel-class-selection.component.ts","./src/modules/destination-search-lazy/components/destination-search-bar/destination-search-bar.component.html","./src/modules/destination-search-lazy/components/destination-search-bar/destination-search-bar.component.ts","./src/modules/destination-search-lazy/utils/filters.ts","./src/modules/destination-search-lazy/components/destination-search-filters/destination-search-filters.component.html","./src/modules/destination-search-lazy/components/destination-search-filters/destination-search-filters.component.ts","./src/modules/destination-search-lazy/components/destination-search-form/destination-search-form.component.html","./src/modules/destination-search-lazy/components/destination-search-form/destination-search-form.component.ts","./src/modules/destination-search-lazy/components/destination-search-header/destination-search-header.component.html","./src/modules/destination-search-lazy/components/destination-search-header/destination-search-header.component.ts","./src/modules/destination-search-lazy/components/layouts/destination-search/destination-search.component.html","./src/modules/destination-search-lazy/components/layouts/destination-search/destination-search.component.ts"],"sourcesContent":["import { createAction, props, union } from '@ngrx/store';\n\nimport { GlobalBookingTravelClass } from '@fcom/core';\nimport { TripType } from '@fcom/core/interfaces';\nimport {\n DestinationSearchItem,\n DestinationSearchTripDates,\n DestinationSearchFilters,\n DestinationSearchFilterStateMeta,\n} from '@fcom/destination-search/interfaces';\nimport { DestinationSearchBlockOffer } from '@fcom/cms';\n\nexport const setDestinationSearchSelection = createAction(\n '[DestinationSearchFilter] SetDestinationSearchSelection',\n props<{ selection: DestinationSearchFilters; meta: DestinationSearchFilterStateMeta }>()\n);\nexport const removeRouteUpdate = createAction(\n '[DestinationSearchFilter] removeRouteUpdate',\n props<{ meta: DestinationSearchFilterStateMeta }>()\n);\nexport const setTripDates = createAction(\n '[DestinationSearchFilter] SetTripDates',\n props<{ tripDates: DestinationSearchTripDates; meta: DestinationSearchFilterStateMeta }>()\n);\nexport const setTripType = createAction(\n '[DestinationSearchFilter] SetTripType',\n props<{ tripType: TripType; meta: DestinationSearchFilterStateMeta }>()\n);\nexport const setTravelClass = createAction(\n '[DestinationSearchFilter] SetTravelClass',\n props<{ travelClass: GlobalBookingTravelClass; meta: DestinationSearchFilterStateMeta }>()\n);\nexport const setSelectedDestinations = createAction(\n '[DestinationSearchFilter] SetSelectedDestinations',\n props<{ selectedDestinations: DestinationSearchItem[]; meta: DestinationSearchFilterStateMeta }>()\n);\nexport const setFromLocationCode = createAction(\n '[DestinationSearchFilter] SetFromLocationCode',\n props<{ fromLocationCode: string; meta: DestinationSearchFilterStateMeta }>()\n);\nexport const setRestrictToDestinations = createAction(\n '[DestinationSearchFilter] SetFromLocationCode',\n props<{ restrictToDestinations: string[]; meta: DestinationSearchFilterStateMeta }>()\n);\n\nexport const setMaxPrice = createAction(\n '[DestinationSearchFilter] SetMaxPrice',\n props<{ maxPrice: number; meta: DestinationSearchFilterStateMeta }>()\n);\n\nexport const setShowDirectFlightsOnly = createAction(\n '[DestinationSearchFilter] SetShowDirectFlightsOnly',\n props<{ showDirectFlightsOnly: boolean; meta: DestinationSearchFilterStateMeta }>()\n);\n\nexport const setDestinationsBeforeFiltering = createAction(\n '[DestinationSearchFilter] SetDestinationsBeforeFiltering',\n props<{ destinationsBeforeFiltering: DestinationSearchBlockOffer[]; meta: DestinationSearchFilterStateMeta }>()\n);\n\nexport const setRoundTripPrices = createAction(\n '[DestinationSearchFilter] SetRoundTripPrices',\n props<{ roundTripPrices: boolean; meta: DestinationSearchFilterStateMeta }>()\n);\n\nconst all = union({\n setDestinationSearchSelection,\n removeRouteUpdate,\n setTripDates,\n setTripType,\n setTravelClass,\n setSelectedDestinations,\n setFromLocationCode,\n setRestrictToDestinations,\n setMaxPrice,\n setShowDirectFlightsOnly,\n setDestinationsBeforeFiltering,\n setRoundTripPrices,\n});\nexport type ActionsUnion = typeof all;\n","import { createReducer, on } from '@ngrx/store';\n\nimport { GlobalBookingTravelClass } from '@fcom/core';\nimport { TripType } from '@fcom/core/interfaces';\nimport {\n DestinationSearchFilters,\n DestinationSearchItem,\n DestinationSearchState,\n} from '@fcom/destination-search/interfaces';\n\nimport { DestinationSearchFilterActions } from '../actions';\n\nexport const defaultFilters: DestinationSearchFilters = {\n selectedDestinations: [],\n tripDates: {\n departureDate: undefined,\n returnDate: undefined,\n },\n travelClass: GlobalBookingTravelClass.ECONOMY,\n tripType: TripType.RETURN,\n};\n\nconst initialStates: DestinationSearchState = {\n default: defaultFilters,\n};\n\nconst getUniqueDestinations = (destinations: DestinationSearchItem[]): DestinationSearchItem[] => {\n return destinations?.reduce((all: DestinationSearchItem[], current) => {\n const isUnique = all.every((d) => d.id !== current.id);\n return isUnique ? [...all, current] : all;\n }, []);\n};\n\nexport const destinationSearchFilterReducer = createReducer(\n initialStates,\n on(DestinationSearchFilterActions.setDestinationSearchSelection, (state, action) => {\n return {\n ...state,\n [action.meta?.id]: {\n ...state[action.meta?.id],\n ...action.selection,\n },\n };\n }),\n on(DestinationSearchFilterActions.removeRouteUpdate, (state, action) => {\n return {\n ...state,\n [action.meta?.id]: {\n ...state[action.meta?.id],\n skipRouteUpdate: false,\n },\n };\n }),\n on(DestinationSearchFilterActions.setTripDates, (state, action) => {\n return {\n ...state,\n [action.meta?.id]: {\n ...state[action.meta?.id],\n tripDates: action.tripDates,\n },\n };\n }),\n on(DestinationSearchFilterActions.setTripType, (state, action) => {\n return {\n ...state,\n [action.meta?.id]: {\n ...state[action.meta?.id],\n tripType: action.tripType,\n },\n };\n }),\n on(DestinationSearchFilterActions.setTravelClass, (state, action) => {\n return {\n ...state,\n [action.meta?.id]: {\n ...state[action.meta?.id],\n travelClass: action.travelClass,\n },\n };\n }),\n on(DestinationSearchFilterActions.setFromLocationCode, (state, action) => {\n return {\n ...state,\n [action.meta?.id]: {\n ...state[action.meta?.id],\n fromLocationCode: action.fromLocationCode,\n },\n };\n }),\n on(DestinationSearchFilterActions.setSelectedDestinations, (state, action) => {\n return {\n ...state,\n [action.meta?.id]: {\n ...state[action.meta?.id],\n selectedDestinations: getUniqueDestinations(action.selectedDestinations),\n },\n };\n }),\n on(DestinationSearchFilterActions.setRestrictToDestinations, (state, action) => {\n return {\n ...state,\n [action.meta?.id]: {\n ...state[action.meta?.id],\n restrictToDestinations: action.restrictToDestinations,\n },\n };\n }),\n on(DestinationSearchFilterActions.setMaxPrice, (state, { meta, maxPrice }) => {\n return {\n ...state,\n [meta?.id]: {\n ...state[meta?.id],\n maxPrice,\n },\n };\n }),\n on(DestinationSearchFilterActions.setShowDirectFlightsOnly, (state, { meta, showDirectFlightsOnly }) => {\n return {\n ...state,\n [meta?.id]: {\n ...state[meta?.id],\n showDirectFlightsOnly,\n },\n };\n }),\n on(DestinationSearchFilterActions.setDestinationsBeforeFiltering, (state, { meta, destinationsBeforeFiltering }) => {\n return {\n ...state,\n [meta?.id]: {\n ...state[meta?.id],\n destinationsBeforeFiltering,\n },\n };\n }),\n on(DestinationSearchFilterActions.setRoundTripPrices, (state, { meta, roundTripPrices }) => {\n return {\n ...state,\n [meta?.id]: {\n ...state[meta?.id],\n roundTripPrices,\n },\n };\n })\n);\n","/* eslint-disable no-underscore-dangle */\nimport { createFeatureSelector, createSelector } from '@ngrx/store';\nimport { DestinationSearchBlockOffer } from 'src/modules/cms';\n\nimport { safeSelect, StateSelector } from '@fcom/core/selectors/selector-utils';\nimport { isPresent } from '@fcom/core/utils';\nimport { GlobalBookingTravelClass } from '@fcom/core';\nimport { TripType } from '@fcom/core/interfaces';\nimport {\n DestinationSearchTripDates,\n DestinationSearchItem,\n DestinationSearchFeatureState,\n DESTINATION_SEARCH_FILTER_STATE_FEATURE_NAME,\n DestinationSearchFilters,\n DestinationSearchState,\n} from '@fcom/destination-search/interfaces';\n\nimport { defaultFilters } from '../reducers';\n\nconst _selectDestinationSearchFilterStates = createFeatureSelector<\n DestinationSearchFeatureState,\n DestinationSearchState\n>(DESTINATION_SEARCH_FILTER_STATE_FEATURE_NAME);\n\nconst _selectTripDates = (id) =>\n createSelector(_filterState(id), (state: DestinationSearchFilters) => {\n const { departureDate, returnDate } = state.tripDates;\n const bothDatesArePresent = isPresent(departureDate) && isPresent(returnDate);\n const bothDatesAreUndefined = !isPresent(departureDate) && !isPresent(returnDate);\n const oneWayWithOneDatePresent = state.tripType === TripType.ONEWAY && isPresent(departureDate);\n\n return bothDatesArePresent || bothDatesAreUndefined || oneWayWithOneDatePresent\n ? state.tripDates\n : defaultFilters.tripDates;\n });\n\nconst _selectTripType = (id) => createSelector(_filterState(id), (state: DestinationSearchFilters) => state.tripType);\n\nconst _selectTravelClass = (id) =>\n createSelector(_filterState(id), (state: DestinationSearchFilters) => state.travelClass);\n\nconst _selectSelectedDesinations = (id) =>\n createSelector(_filterState(id), (state: DestinationSearchFilters) => state.selectedDestinations);\n\nconst _selectFromLocationCode = (id) =>\n createSelector(_filterState(id), (state: DestinationSearchFilters) => state.fromLocationCode);\n\nconst _selectRestrictToDestinationsState = (id) =>\n createSelector(_filterState(id), (state: DestinationSearchFilters) => state.restrictToDestinations);\n\nconst _filterState = (id) =>\n createSelector(\n _selectDestinationSearchFilterStates,\n (state: DestinationSearchState) => state?.[id] ?? defaultFilters\n );\n\nconst _allFilterStates = () =>\n createSelector(_selectDestinationSearchFilterStates, (state: DestinationSearchState) => state);\n\nconst _selectDestinationsBeforeFiltering = (id: string) =>\n createSelector(_filterState(id), (state: DestinationSearchFilters) => state.destinationsBeforeFiltering);\n\nconst _selectRoundTripPrices = (id: string) =>\n createSelector(_filterState(id), (state: DestinationSearchFilters) => state.roundTripPrices);\n\nexport const allFilterStates = (): StateSelector =>\n safeSelect(_allFilterStates());\n\nexport const filterState = (id: string): StateSelector =>\n safeSelect(_filterState(id));\n\nexport const tripDatesState = (id: string): StateSelector =>\n safeSelect(_selectTripDates(id));\n\nexport const tripTypeState = (id: string): StateSelector =>\n safeSelect(_selectTripType(id));\n\nexport const travelClassState = (id: string): StateSelector =>\n safeSelect(_selectTravelClass(id));\n\nexport const fromLocationCodeState = (id: string): StateSelector =>\n safeSelect(_selectFromLocationCode(id));\n\nexport const selectedDestinationsState = (\n id: string\n): StateSelector => safeSelect(_selectSelectedDesinations(id));\n\nexport const restrictToDestinationsState = (id: string): StateSelector =>\n safeSelect(_selectRestrictToDestinationsState(id));\n\nexport const destinationsBeforeFilteringState = (\n id: string\n): StateSelector =>\n safeSelect(_selectDestinationsBeforeFiltering(id));\n\nexport const roundTripPricesState = (id: string): StateSelector =>\n safeSelect(_selectRoundTripPrices(id));\n","import { DestinationSearchBlockOffer } from '@fcom/cms/interfaces';\n\nexport interface FetchOffersResponseData {\n destinationPrices: { [destination: string]: OfferDestination };\n}\n\nexport interface OfferDestination {\n origin: string;\n currency: string;\n prices: OfferPrice[];\n locationData?: LocationData;\n}\n\nexport interface LocationData {\n continentCode: string;\n country: string;\n countryCode: string;\n cityName: string;\n picture: string;\n}\n\nexport interface OfferPrice {\n departure: string;\n return: string;\n price: string;\n}\n\nexport enum Continent {\n EUROPE = 'Europe',\n MIDDLE_EAST = 'Middle East',\n AMERICA = 'Americas',\n ASIA_PACIFIC = 'Asia-Pacific',\n AFRICA = 'Africa',\n}\n\nexport interface CategorizedDestination {\n [key: string]: DestinationSearchBlockOffer[];\n}\n","import { Injectable } from '@angular/core';\n\nimport { combineLatest, merge, Observable, of, Subject } from 'rxjs';\nimport { map, catchError, filter, switchMap, startWith, tap, distinctUntilChanged } from 'rxjs/operators';\nimport { Store } from '@ngrx/store';\n\nimport { getDestinationInCampaign } from '@fcom/core/utils/cms-data-utils';\nimport { LanguageService } from '@fcom/ui-translate';\nimport { CmsCampaign, CmsDataService, ConfigService, GlobalBookingTravelClass } from '@fcom/core';\nimport { CmsPlaceholder } from '@fcom/core-api';\nimport { MarketingOffer, DestinationSearchBlockOffer, MarketingOfferPrices } from '@fcom/cms/interfaces';\nimport { diff, textMatch, isNotEmpty, isPresent, TimeUnit } from '@fcom/core/utils';\nimport { NON_EUROPE_SITES } from '@fcom/core/constants';\nimport { TripType } from '@fcom/core/interfaces';\nimport { mapToMarketingOffers } from '@fcom/cms/utils';\nimport { mapToAmDestinationOffer } from '@fcom/common/utils';\nimport { InstantsearchService } from '@fcom/dapi/api/services';\nimport { CheapestPriceForAllDestinationsService } from '@fcom/cms/services';\nimport { finShare, snapshot } from '@fcom/rx';\nimport { DestinationSearchService } from '@fcom/destination-search/services/destination-search.service';\nimport { flattenDestinations } from '@fcom/destination-search/utils/flatten';\nimport {\n DestinationSearchFeatureState,\n DestinationSearchItem,\n PriceLoadingState,\n DestinationSearchTripDates,\n DestinationSearchItemType,\n DestinationSearchQueryParamNames,\n} from '@fcom/destination-search/interfaces';\nimport { AmDestinationService } from '@fcom/destination-search/services/am-destination.service';\n\nimport { travelClassState, tripDatesState, tripTypeState, selectedDestinationsState } from '../store';\nimport { Continent } from '../interfaces';\n\n@Injectable()\nexport class DestinationSearchOffersService {\n public readonly loaderStatus$: Observable;\n private status$: Subject = new Subject();\n private campaigns$: Observable;\n\n constructor(\n private configService: ConfigService,\n private instantsearchService: InstantsearchService,\n private cheapestPriceForAllDestinationsService: CheapestPriceForAllDestinationsService,\n private destinationSearchService: DestinationSearchService,\n private store$: Store,\n private cmsDataService: CmsDataService,\n private languageService: LanguageService,\n private amDestinationService: AmDestinationService\n ) {\n this.loaderStatus$ = this.status$.pipe(startWith(PriceLoadingState.INITIAL));\n this.campaigns$ = this.cmsDataService.getOngoingCampaigns(\n this.languageService.langValue,\n this.languageService.localeValue\n );\n }\n\n /**\n * Map prices to destination information\n */\n public getDestinationsWithOffers(\n restrictions: DestinationSearchQueryParamNames,\n identifier: string,\n content: CmsPlaceholder,\n selectedOriginLocationCode: string\n ): Observable {\n const selectedTripDates$ = this.store$.pipe(tripDatesState(identifier));\n const selectedTripType$ = this.store$.pipe(tripTypeState(identifier));\n const selectedTravelClass$ = this.store$.pipe(travelClassState(identifier));\n const filteredDestinations$ = combineLatest([\n this.destinationSearchService.destinationSearch(restrictions),\n this.store$.pipe(selectedDestinationsState(identifier)),\n ]).pipe(\n distinctUntilChanged(),\n map(([destinations, destinationFilters]) => {\n const allDestinations = flattenDestinations(destinations).filter(\n (d) => d.type === DestinationSearchItemType.DESTINATION\n );\n const matchingDestinations = allDestinations.filter((destination: DestinationSearchItem) =>\n this.destinationMatchesFilters(destinationFilters, destination)\n );\n return isNotEmpty(matchingDestinations) ? matchingDestinations : allDestinations;\n })\n );\n\n const offersWithDates$ = this.getOffersWithDates(\n selectedTripDates$,\n selectedTripType$,\n filteredDestinations$,\n selectedOriginLocationCode\n );\n\n const allOffers$ = this.getAllOffers(\n selectedTripDates$,\n selectedTripType$,\n offersWithDates$,\n selectedOriginLocationCode\n );\n\n // enable flight+hotel on finnish market\n const amDestinationList$ = this.languageService.localeValue.includes('FI')\n ? this.amDestinationService.amDestinationList()\n : of([]);\n\n return combineLatest([\n filteredDestinations$,\n allOffers$,\n selectedTravelClass$,\n this.campaigns$,\n amDestinationList$,\n selectedTripType$,\n ]).pipe(\n map(([destinations, offers, travelClass, campaigns, amDestinationList]) => {\n const offersMap: { [locationCode: string]: MarketingOffer } = offers.reduce((allOffers, offer) => {\n const amDestination = amDestinationList.find(({ dest }) => dest === offer.airportCode);\n return {\n ...allOffers,\n [offer.destination]: {\n ...offer,\n amDestination: amDestination ? mapToAmDestinationOffer(amDestination) : null,\n },\n };\n }, {});\n\n return destinations\n .map((destination: DestinationSearchItem): DestinationSearchBlockOffer => {\n const matchingOffer: MarketingOffer = offersMap[destination.locationCode];\n return this.mapToBlockOffer(destination, travelClass, matchingOffer, campaigns, selectedOriginLocationCode);\n })\n .filter((item) => content?.localSettings?.showDestinationsWithoutPrice || item.price);\n })\n );\n }\n\n public forceLoadingScreen(duration: number): void {\n if (snapshot(this.status$) === PriceLoadingState.LOADING) {\n return;\n }\n this.status$.next(PriceLoadingState.LOADING);\n setTimeout(() => {\n this.status$.next(PriceLoadingState.LOADED);\n }, duration);\n }\n\n /**\n * Fetch prices in case dates are selected\n */\n private getOffersWithDates(\n selectedDates$: Observable,\n tripType$: Observable,\n filteredDestinations$: Observable,\n selectedOriginLocationCode: string\n ): Observable {\n return combineLatest([selectedDates$, tripType$, filteredDestinations$]).pipe(\n filter(\n ([selectedDates, tripType]) =>\n (tripType === TripType.RETURN &&\n isPresent(selectedDates?.departureDate) &&\n isPresent(selectedDates?.returnDate)) ||\n (tripType === TripType.ONEWAY && isPresent(selectedDates?.departureDate))\n ),\n switchMap(([selectedDates, tripType, destinations]) => {\n const locationCodes = destinations\n .filter((destination) => destination.locationCode)\n .map((destination) => destination.locationCode);\n\n let params = {\n departureLocationCodes: [selectedOriginLocationCode],\n destinationLocationCodes: locationCodes,\n numberOfDays: 0,\n travelClasses: [\n GlobalBookingTravelClass.ECONOMY.toLowerCase(),\n GlobalBookingTravelClass.ECOPREMIUM.toLowerCase(),\n GlobalBookingTravelClass.BUSINESS.toLowerCase(),\n ],\n };\n\n const isReturnWithBothDates =\n tripType === TripType.RETURN &&\n isPresent(selectedDates?.departureDate) &&\n isPresent(selectedDates?.returnDate);\n const isOnewayWithOneDate = tripType === TripType.ONEWAY && isPresent(selectedDates?.departureDate);\n if (isReturnWithBothDates || isOnewayWithOneDate) {\n const departureDate = selectedDates.departureDate.toString();\n const returnDate = selectedDates.returnDate?.toString();\n\n params = Object.assign({}, params, {\n departureDate,\n lengthOfStay: isOnewayWithOneDate ? 1 : diff(new Date(departureDate), new Date(returnDate), TimeUnit.day),\n tripTypes: [tripType],\n locale: this.languageService.langValue,\n });\n }\n\n this.status$.next(PriceLoadingState.LOADING);\n\n return this.instantsearchService\n .getPricesForFlights(this.configService.cfg.instantSearchUrl, params)\n .pipe(catchError(() => of([])));\n }),\n map(mapToMarketingOffers),\n tap(() => this.status$.next(PriceLoadingState.LOADED)),\n finShare()\n );\n }\n\n private getAllOffers(\n selectedDates$: Observable,\n tripType$: Observable,\n offersWithDates$: Observable,\n selectedOriginLocationCode: string\n ): Observable {\n return merge(\n combineLatest([selectedDates$, tripType$]).pipe(\n filter(\n ([selectedDates, tripType]) =>\n (tripType === TripType.RETURN &&\n !isPresent(selectedDates?.departureDate) &&\n !isPresent(selectedDates?.returnDate)) ||\n (tripType === TripType.ONEWAY && !isPresent(selectedDates?.departureDate))\n ),\n switchMap(([, tripType]) => {\n this.status$.next(PriceLoadingState.LOADING);\n if (!NON_EUROPE_SITES.includes(this.languageService.langValue)) {\n return this.cheapestPriceForAllDestinationsService.bothWayOffers(selectedOriginLocationCode);\n }\n return tripType === TripType.ONEWAY\n ? //oneway\n this.cheapestPriceForAllDestinationsService.oneWayOffers(selectedOriginLocationCode)\n : //return\n this.cheapestPriceForAllDestinationsService.bothWayOffers(selectedOriginLocationCode);\n }),\n tap(() => this.status$.next(PriceLoadingState.LOADED))\n ),\n offersWithDates$\n );\n }\n\n private mapToBlockOffer(\n destination: DestinationSearchItem,\n selectedTravelClass: GlobalBookingTravelClass,\n matchingOffer?: MarketingOffer,\n campaigns?: CmsCampaign[],\n selectedOriginLocationCode?: string\n ): DestinationSearchBlockOffer {\n const matchingEconomyOffer = matchingOffer?.prices.find(\n (t) => t.travelClass.toUpperCase() === GlobalBookingTravelClass.ECONOMY\n );\n const matchingPremiumEconomyOffer = matchingOffer?.prices.find(\n (t) => t.travelClass.toUpperCase() === GlobalBookingTravelClass.ECOPREMIUM\n );\n const matchingBusinessOffer = matchingOffer?.prices.find(\n (t) => t.travelClass.toUpperCase() === GlobalBookingTravelClass.BUSINESS\n );\n\n const showAllOffers = selectedTravelClass === GlobalBookingTravelClass.MIXED;\n const showEconomyOffer = selectedTravelClass === GlobalBookingTravelClass.ECONOMY;\n const showPremiumEconomyOffer = selectedTravelClass === GlobalBookingTravelClass.ECOPREMIUM;\n const showBusinessOffer = selectedTravelClass === GlobalBookingTravelClass.BUSINESS;\n\n const marketingOffer = {\n destination: destination.title,\n origin: destination.origin,\n prices: [\n ...this.getOfferPrice(\n matchingEconomyOffer,\n showAllOffers || showEconomyOffer,\n GlobalBookingTravelClass.ECONOMY\n ),\n ...this.getOfferPrice(\n matchingPremiumEconomyOffer,\n showAllOffers || showPremiumEconomyOffer,\n GlobalBookingTravelClass.ECOPREMIUM\n ),\n ...this.getOfferPrice(\n matchingBusinessOffer,\n showAllOffers || showBusinessOffer,\n GlobalBookingTravelClass.BUSINESS\n ),\n ],\n };\n\n const onewayPrice = this.getPriceByTripTypeAndTravelClass(matchingOffer, TripType.ONEWAY, selectedTravelClass);\n const returnPrice = this.getPriceByTripTypeAndTravelClass(matchingOffer, TripType.RETURN, selectedTravelClass);\n\n return {\n title: destination.title,\n link: destination.url,\n imageData: destination.picture,\n destination: destination.title,\n // TODO: check which price is actually the lowest instead of relying on it being the first...\n price: marketingOffer.prices[0]?.price?.amount\n ? Math.ceil(Number(marketingOffer.prices[0].price.amount))\n : undefined,\n onewayPrice,\n returnPrice,\n origin: matchingOffer ? matchingOffer.origin : undefined,\n flag: destination.countryCode ? destination.countryCode.toLowerCase() : undefined,\n countryName: destination.country || undefined,\n currency: destination.currency,\n titleMaster: destination.titleMaster,\n marketingOffer: marketingOffer.prices.length ? marketingOffer : undefined,\n continent: destination.continentMaster,\n badgeIcon: undefined,\n badgeLabel: campaigns.find(\n (campaign) =>\n (campaign?.destinations?.some((dest: string) => dest === destination.locationCode) ||\n campaign?.destinationsByOrigin?.[selectedOriginLocationCode]?.some(\n (dest: string) => dest === destination.locationCode\n )) &&\n campaign?.campaignTravelClass === selectedTravelClass\n )?.campaignLabel,\n enableBlackTeaser: getDestinationInCampaign(campaigns, destination.locationCode)?.enableBlackTeaser,\n amDestination: matchingOffer?.amDestination,\n locationCode: destination.locationCode,\n directFlight: destination.directFlight,\n isShortHaul: NON_EUROPE_SITES.includes(this.languageService.langValue)\n ? false\n : destination.continentMaster === Continent.EUROPE,\n };\n }\n\n private getPriceByTripTypeAndTravelClass(\n marketingOffer: MarketingOffer,\n tripType: TripType,\n travelClass: GlobalBookingTravelClass\n ): MarketingOfferPrices | undefined {\n return marketingOffer?.prices.find(\n (price) =>\n (travelClass === GlobalBookingTravelClass.MIXED || price.travelClass.toUpperCase() === travelClass) &&\n price.price?.tripType === tripType\n );\n }\n\n private getOfferPrice(\n offer: MarketingOfferPrices,\n showOffer: boolean,\n travelClass: GlobalBookingTravelClass\n ): MarketingOfferPrices[] {\n return offer && showOffer\n ? [\n {\n travelClass,\n price: {\n currencyCode: offer.price.currencyCode,\n amount: `${Math.ceil(Number(offer.price.amount))}`,\n },\n },\n ]\n : [];\n }\n\n private destinationMatchesFilters(filters: DestinationSearchItem[], destination: DestinationSearchItem): boolean {\n return filters?.some(\n (f) =>\n (f.type === DestinationSearchItemType.DESTINATION && textMatch(f.locationCode, destination?.locationCode)) ||\n (f.type === DestinationSearchItemType.COUNTRY && textMatch(f.countryCode, destination?.countryCode)) ||\n (f.type === DestinationSearchItemType.CONTINENT && textMatch(f.titleMaster, destination?.continentMaster))\n );\n }\n}\n","import { CommonModule } from '@angular/common';\nimport { FormsModule } from '@angular/forms';\nimport { NgModule } from '@angular/core';\n\nimport { StoreModule } from '@ngrx/store';\n\nimport { UiTranslateModule } from '@fcom/ui-translate';\nimport { UiComponentsModule } from '@fcom/ui-components';\nimport { ComponentsModule } from '@fcom/common/components';\nimport { PipesModule } from '@fcom/common/pipes/pipes.module';\nimport { GtmModule } from '@fcom/common/gtm/gtm.module';\nimport { DirectiveModule, FinFormsModule } from '@fcom/common';\nimport { ContentComponentsModule } from '@fcom/cms/components/content-components.module';\nimport { DestinationSearchModule } from '@fcom/destination-search/destination-search.module';\nimport { DESTINATION_SEARCH_FILTER_STATE_FEATURE_NAME } from '@fcom/destination-search/interfaces';\n// DestinationSearchPageComponent is the page that incorporates other Components, they should be\n// named with pattern DestinationSeachXXXComponent\nimport { OndMarketingDataService } from '@fcom/ond-marketing-landing-core/services';\n\nimport {\n DestinationSearchPageComponent,\n DestinationSearchFilterChipsComponent,\n DestinationSearchFilterToFieldComponent,\n DestinationSearchDateFieldComponent,\n DestinationSearchResultsComponent,\n DestinationSearchResultsItemComponent,\n DestinationSearchHeroComponent,\n DestinationSearchTravelClassSelectionComponent,\n SortOptionsComponent,\n DestinationSearchFormComponent,\n DestinationSearchOriginSelectorComponent,\n DestinationSearchFiltersComponent,\n} from './components';\nimport { DestinationSearchOffersService } from './services/destination-search-offers.service';\nimport { destinationSearchFilterReducer } from './store';\nimport { DestinationSearchCampaignRibbonComponent } from './components/destination-search-campaign-ribbon/destination-search-campaign-ribbon.component';\nimport { DestinationSearchBarComponent } from './components/destination-search-bar/destination-search-bar.component';\nimport { DestinationSearchHeaderComponent } from './components/destination-search-header/destination-search-header.component';\n\n@NgModule({\n imports: [\n StoreModule.forFeature(DESTINATION_SEARCH_FILTER_STATE_FEATURE_NAME, destinationSearchFilterReducer),\n CommonModule,\n UiTranslateModule,\n PipesModule,\n ComponentsModule,\n FormsModule,\n DirectiveModule,\n ContentComponentsModule,\n UiComponentsModule,\n GtmModule,\n FinFormsModule,\n DestinationSearchModule,\n ],\n declarations: [\n DestinationSearchPageComponent,\n DestinationSearchFilterChipsComponent,\n DestinationSearchFilterToFieldComponent,\n DestinationSearchFormComponent,\n DestinationSearchDateFieldComponent,\n DestinationSearchResultsComponent,\n DestinationSearchResultsItemComponent,\n DestinationSearchHeroComponent,\n DestinationSearchTravelClassSelectionComponent,\n SortOptionsComponent,\n DestinationSearchCampaignRibbonComponent,\n DestinationSearchBarComponent,\n DestinationSearchHeaderComponent,\n DestinationSearchOriginSelectorComponent,\n DestinationSearchFiltersComponent,\n ],\n exports: [DestinationSearchPageComponent, DestinationSearchHeroComponent],\n providers: [DestinationSearchOffersService, OndMarketingDataService],\n})\nexport class DestinationSearchLazyModule {}\n","\n \n \n
\n {{ 'destinationSearch.datepicker.departureDate' | finLocalization }}\n
\n
\n {{\n calendarDates.departureDate | finDateFormat: 'DATE'\n }}\n {{\n 'destinationSearch.datepicker.allDates' | finLocalization\n }}\n
\n \n \n
\n {{ 'destinationSearch.datepicker.returnDate' | finLocalization }}\n
\n
\n {{\n calendarDates.returnDate | finDateFormat: 'DATE'\n }}\n {{\n 'destinationSearch.datepicker.allDates' | finLocalization\n }}\n
\n \n
\n \n
\n \n\n \n \n \n
\n","import {\n Component,\n EventEmitter,\n Output,\n ChangeDetectionStrategy,\n OnInit,\n Input,\n OnDestroy,\n ChangeDetectorRef,\n} from '@angular/core';\n\nimport { SvgLibraryIcon } from '@finnairoyj/fcom-ui-styles/enums';\nimport { BehaviorSubject, Observable, Subscription } from 'rxjs';\n\nimport { LocalDate, unsubscribe } from '@fcom/core/utils';\nimport { DestinationSearchTripDates } from '@fcom/destination-search/interfaces';\nimport { DateRange } from '@fcom/ui-components';\n\nconst DAYS_AMOUNT = 360; // Default calendar size\n\n@Component({\n selector: 'fin-destination-search-date-field',\n templateUrl: 'destination-search-date-field.component.html',\n styleUrls: ['destination-search-date-field.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class DestinationSearchDateFieldComponent implements OnInit, OnDestroy {\n @Input() selectedDates$: Observable;\n\n @Input() showReturnField$: Observable;\n\n /**\n * Emits selected dates\n */\n @Output() dateChange = new EventEmitter();\n\n datepickerOpen = false;\n selectableDatesRange: DateRange;\n calendarDates$ = new BehaviorSubject(undefined);\n\n private currentDate: LocalDate = LocalDate.now();\n private subscription = new Subscription();\n\n readonly SvgLibraryIcon = SvgLibraryIcon;\n\n constructor(private cd: ChangeDetectorRef) {}\n\n ngOnInit(): void {\n // TODO: check if earliest day can now be today instead of tomorrow\n this.selectableDatesRange = [this.currentDate.plusDays(1), this.currentDate.plusDays(DAYS_AMOUNT)];\n this.subscription.add(\n this.selectedDates$.subscribe((tripDates: DestinationSearchTripDates) => {\n this.calendarDates$.next(tripDates);\n this.cd.detectChanges();\n })\n );\n }\n\n ngOnDestroy(): void {\n this.subscription = unsubscribe(this.subscription);\n }\n\n openDatepicker(): void {\n this.datepickerOpen = true;\n }\n\n closeDatepicker(): void {\n this.datepickerOpen = false;\n }\n\n updateTravelDates(calendarDates: DestinationSearchTripDates): void {\n this.dateChange.emit(calendarDates);\n }\n\n updateCalendarDates([departureDate, returnDate]:\n | [string | undefined, string | undefined]\n | [string | undefined]): void {\n this.calendarDates$.next({\n departureDate: departureDate ? new LocalDate(departureDate) : undefined,\n returnDate: returnDate ? new LocalDate(returnDate) : undefined,\n });\n }\n}\n","
\n {{\n 'destinationSearch.selectedDestination.' + (selectedDestinations.length === 1 ? 'singular' : 'plural')\n | finLocalization\n }}\n
\n\n \n \n \n \n
  • = 2\" [style]=\"(isMobile$ | async) === true ? {} : cmsStylesOverride\">\n \n {{ 'destinationSearch.chip.action.removeAll' | finLocalization }}\n \n
  • \n\n","import { Component, Input, Output, EventEmitter, ViewChild, ElementRef } from '@angular/core';\n\nimport { Observable } from 'rxjs';\nimport { SvgLibraryIcon } from '@finnairoyj/fcom-ui-styles/enums';\n\nimport { MediaQueryService, TestVariant } from '@fcom/common';\nimport { TagTheme } from '@fcom/ui-components';\nimport {\n DestinationSearchItem,\n DestinationSearchItemFilterSelection,\n FilterAction,\n} from '@fcom/destination-search/interfaces';\n\n@Component({\n selector: 'fin-destination-search-filter-chips',\n templateUrl: 'destination-search-filter-chips.component.html',\n})\nexport class DestinationSearchFilterChipsComponent {\n readonly SvgLibraryIcon = SvgLibraryIcon;\n readonly TagTheme = TagTheme;\n readonly TestVariant = TestVariant;\n readonly cmsStylesOverride = {\n 'padding-bottom': '0',\n };\n\n isMobile$: Observable;\n\n @Input()\n selectedDestinations: DestinationSearchItem[];\n\n @ViewChild('tagsList', { static: false })\n tagsList: ElementRef;\n\n @ViewChild('a11yHeading', { static: false })\n a11yHeading: ElementRef;\n\n @Output()\n tagRemove = new EventEmitter();\n\n constructor(private mediaQueryService: MediaQueryService) {\n this.isMobile$ = this.mediaQueryService.isBreakpoint$('mobile');\n }\n\n removeAll(): void {\n this.tagRemove.emit({\n action: FilterAction.REMOVE_ALL,\n destination: undefined,\n selectedDestinations: this.selectedDestinations,\n });\n }\n\n trackByFn(_index: number, item: DestinationSearchItem): string {\n return item.id;\n }\n\n removeChip(destination: DestinationSearchItem): void {\n this.tagRemove.emit({\n action: FilterAction.REMOVE,\n destination,\n selectedDestinations: this.selectedDestinations,\n });\n\n // setTimeout due to DOM operation\n setTimeout(() => {\n const buttons = this.tagsList.nativeElement.querySelectorAll('button');\n if (buttons.length) {\n buttons[buttons.length - 1].focus();\n } else {\n this.a11yHeading.nativeElement.focus();\n }\n }, 0);\n }\n}\n","
    \n \n {{\n 'destinationSearch.selectableDestinations' | finLocalization: { amount: (matchingDestinations$ | async)?.length }\n }}\n \n \n \n \n {{\n selectedDestinations?.length\n ? ('destinationSearch.toInputLabelMoreDestinations' | finLocalization)\n : ('destinationSearch.toInputLabel' | finLocalization)\n }}\n \n \n -1 ? 'to-field-option-' + (highlightedItem$ | async) : null\n \"\n aria-autocomplete=\"list\"\n aria-controls=\"to-field-listbox\"\n aria-owns=\"to-field-listbox\"\n aria-haspopup=\"listbox\"\n autocomplete=\"off\"\n [formControl]=\"destinationInput\"\n class=\"fill no-outline absolute block border-none rounded-medium ps-small-l font-body-1 regular-type\"\n (keydown)=\"onDestinationInputKeydown($event)\"\n #inputField\n />\n \n {{\n (optionsListVisible$ | async)\n ? ('destinationSearch.hideSelectableDestinations' | finLocalization)\n : ('destinationSearch.showSelectableDestinations' | finLocalization)\n }}\n \n \n \n \n\n \n \n \n \n \n {{ destination.title }}\n \n \n \n \n
  • \n
    \n \n {{ 'destinationSearch.noMatches' | finLocalization }}\n \n
    \n
  • \n \n\n
    \n \n
    \n
    {{ 'destinationSearch.flightsTo' | finLocalization }}
    \n
      \n
    • \n \n \n
    • \n
    \n
    \n
    \n \n\n
    \n
    \n","import {\n AfterViewInit,\n Component,\n ElementRef,\n EventEmitter,\n Inject,\n Input,\n OnDestroy,\n OnInit,\n Output,\n PLATFORM_ID,\n ViewChild,\n} from '@angular/core';\nimport { UntypedFormControl } from '@angular/forms';\nimport { DOCUMENT, isPlatformServer } from '@angular/common';\n\nimport { SvgLibraryIcon } from '@finnairoyj/fcom-ui-styles/enums';\nimport { BehaviorSubject, combineLatest, Observable, Subscription } from 'rxjs';\nimport { debounceTime, distinctUntilChanged, filter, map, startWith } from 'rxjs/operators';\n\nimport { TestVariant } from '@fcom/common';\nimport { ButtonComponent, ButtonSize, ButtonTheme, TagTheme } from '@fcom/ui-components';\nimport { getKeyCodeFromEvent, isBlank, isNotBlank, isNotEmpty, KeyCodes, unsubscribe } from '@fcom/core/utils';\nimport { flattenDestinations } from '@fcom/destination-search/utils/flatten';\nimport {\n DestinationSearchItem,\n DestinationSearchItemFilterSelection,\n DestinationSearchItemType,\n FilterAction,\n} from '@fcom/destination-search/interfaces';\n\n@Component({\n selector: 'fin-destination-search-filter-to-field',\n templateUrl: 'destination-search-filter-to-field.component.html',\n styleUrls: ['destination-search-filter-to-field.component.scss'],\n})\nexport class DestinationSearchFilterToFieldComponent implements OnInit, OnDestroy, AfterViewInit {\n readonly ButtonSize = ButtonSize;\n readonly ButtonTheme = ButtonTheme;\n readonly SvgLibraryIcon = SvgLibraryIcon;\n readonly TagTheme = TagTheme;\n readonly TestVariant = TestVariant;\n\n @Input()\n selectedDestinations: DestinationSearchItem[] = [];\n\n /**\n * Destinations that the user can choose from, also contains countries and continents\n */\n @Input()\n allDestinations$: Observable;\n\n /**\n * Emits this.selectedDestinationIds\n */\n @Output() valueChange = new EventEmitter();\n\n @ViewChild('inputField')\n inputField: ElementRef;\n\n @ViewChild('inputFieldButton', { static: false })\n inputFieldButton: ElementRef;\n\n @ViewChild('optionsListbox', { static: false })\n optionsListbox: ElementRef;\n\n @ViewChild('showResultsButton', { static: false })\n showResultsButton: ButtonComponent;\n\n @ViewChild('tagList', { static: false })\n tagList: ElementRef;\n\n /**\n * Destinations that match the given query\n */\n matchingDestinations$: BehaviorSubject = new BehaviorSubject(undefined);\n\n /**\n * Destination options list visibility\n */\n optionsListVisible$: BehaviorSubject = new BehaviorSubject(false); // Options hidden by default\n\n /**\n * Highlighted result for keyboard navigation\n */\n highlightedItem$: BehaviorSubject = new BehaviorSubject(-1);\n\n destinationInput = new UntypedFormControl();\n DESTINATION_TYPE = DestinationSearchItemType;\n\n private subscriptions: Subscription = new Subscription();\n\n constructor(\n @Inject(DOCUMENT) private document: Document,\n @Inject(PLATFORM_ID) private platform: Record,\n private elementRef: ElementRef\n ) {}\n\n ngOnInit(): void {\n this.subscriptions.add(\n combineLatest([\n this.destinationInput.valueChanges.pipe(debounceTime(200), distinctUntilChanged(), startWith('')),\n this.allDestinations$.pipe(filter(Boolean), distinctUntilChanged()),\n ])\n .pipe(\n map(([query, destinations]: [string, DestinationSearchItem[]]) => {\n const updated = this.mapQueryMatches(destinations, query);\n return flattenDestinations(updated).filter((d: DestinationSearchItem) => d.matchesQuery);\n })\n )\n .subscribe((destinations) => {\n this.updateDestinationOptionsList(destinations);\n })\n );\n }\n\n ngAfterViewInit(): void {\n this.subscriptions.add(\n this.highlightedItem$.subscribe((index) => {\n if (index >= 0) {\n const highlightedElement = this.optionsListbox?.nativeElement.querySelector(`#to-field-option-${index}`);\n if (!highlightedElement) {\n return;\n }\n\n if (!this.isScrolledIntoView(highlightedElement)) {\n // Because the list is still hidden when this is evaluated the offsetTop will be 0 for all items\n // when opening the list. With timeout we'll skip one event cycle and it'll be calculated correctly\n setTimeout(() => {\n this.optionsListbox.nativeElement.scrollTop = highlightedElement.offsetTop;\n }, 0);\n }\n }\n })\n );\n }\n\n ngOnDestroy(): void {\n this.subscriptions = unsubscribe(this.subscriptions);\n }\n\n get inputHasFocus(): boolean {\n return this.document.activeElement === this.inputField?.nativeElement;\n }\n\n handleComponentFocusOut(event: FocusEvent): void {\n const el: HTMLElement = this.elementRef?.nativeElement;\n\n if (!!el && !el.contains(event.relatedTarget as HTMLElement)) {\n event.stopPropagation();\n this.closeOptionsList(false);\n }\n }\n\n onClickInputArea(event: MouseEvent): void {\n // Distinguish between button area and input field clicks\n if (this.inputFieldButton?.nativeElement.contains(event.target)) {\n // eslint-disable-next-line rxjs/no-subject-value\n if (!this.optionsListVisible$.getValue()) {\n this.openOptionsList();\n } else {\n this.closeOptionsList(false);\n }\n } else {\n this.openOptionsList();\n }\n }\n\n openOptionsList(fromBottom = false): void {\n this.optionsListVisible$.next(true);\n this.highlightedItem$.next(fromBottom ? this.maxHighlightIndex : 0);\n }\n\n closeOptionsList(handleFocus = true): void {\n if (handleFocus) {\n this.inputFieldButton?.nativeElement?.focus();\n }\n\n this.highlightedItem$.next(-1);\n this.destinationInput.reset();\n this.optionsListVisible$.next(false);\n }\n\n removeTag(destination: DestinationSearchItem): void {\n const showButton: HTMLElement = this.showResultsButton?.buttonElement?.nativeElement;\n const tags: NodeListOf = this.tagList?.nativeElement.querySelectorAll('fcom-tag-button');\n const remainingTags = Array.from(tags).filter((c: HTMLElement) => c.id !== destination.id);\n const lastTag = remainingTags[remainingTags?.length - 1];\n\n if (lastTag) {\n lastTag.querySelector('button').focus();\n } else {\n showButton.focus();\n }\n this.valueChange.emit({\n action: FilterAction.REMOVE,\n destination,\n selectedDestinations: this.selectedDestinations,\n });\n }\n\n /**\n * Keyboard navigation according to https://www.w3.org/TR/wai-aria-practices/examples/combobox/aria1.1pattern/listbox-combo.html\n */\n onDestinationInputKeydown(event: KeyboardEvent): void {\n // eslint-disable-next-line rxjs/no-subject-value\n const optionsListOpen = this.optionsListVisible$.getValue();\n\n switch (getKeyCodeFromEvent(event)) {\n case KeyCodes.ESC:\n this.closeOptionsList();\n break;\n case KeyCodes.UP:\n if (!optionsListOpen) {\n this.openOptionsList(true);\n } else {\n this.highlightPreviousItem();\n }\n break;\n case KeyCodes.DOWN:\n if (!optionsListOpen) {\n this.openOptionsList();\n } else {\n this.highlightNextItem();\n }\n break;\n case KeyCodes.ENTER:\n if (this.highlightIndex > -1) {\n // eslint-disable-next-line rxjs/no-subject-value\n const highlightedElement = this.matchingDestinations$.getValue()[this.highlightIndex];\n this.toggleDestinationSelection(highlightedElement);\n } else {\n this.closeOptionsList();\n }\n break;\n default:\n break;\n }\n /* eslint-enable rxjs/no-subject-value */\n }\n\n toggleDestinationSelection(destination: DestinationSearchItem): void {\n const isSelected = Boolean(this.selectedDestinations?.find((selected) => selected.id === destination.id));\n this.valueChange.emit({\n action: isSelected ? FilterAction.REMOVE : FilterAction.ADD,\n destination,\n selectedDestinations: this.selectedDestinations,\n });\n }\n\n destinationIsSelected(destination: DestinationSearchItem): boolean {\n // eslint-disable-next-line rxjs/no-subject-value\n return Boolean(this.selectedDestinations?.find((d) => d.id === destination.id));\n }\n\n destinationIsHighlighted(destinationIndex: number): boolean {\n return this.inputHasFocus && this.highlightIndex === destinationIndex;\n }\n\n private get highlightIndex(): number {\n // eslint-disable-next-line rxjs/no-subject-value\n return this.highlightedItem$.getValue();\n }\n\n private get maxHighlightIndex(): number {\n // eslint-disable-next-line rxjs/no-subject-value\n return this.matchingDestinations$.getValue().length - 1;\n }\n\n private highlightNextItem(): void {\n const nextIndex = this.highlightIndex < this.maxHighlightIndex ? this.highlightIndex + 1 : 0;\n this.highlightedItem$.next(nextIndex);\n }\n\n private highlightPreviousItem(): void {\n const nextIndex = this.highlightIndex > 0 ? this.highlightIndex - 1 : this.maxHighlightIndex;\n this.highlightedItem$.next(nextIndex);\n }\n\n private isScrolledIntoView(element: HTMLElement): boolean {\n if (isPlatformServer(this.platform)) {\n return true;\n }\n const item = element?.getBoundingClientRect(),\n top = item.top,\n height = item.height,\n itemParent = element.parentNode as HTMLElement,\n itemParentRect = itemParent?.getBoundingClientRect();\n\n if (item.bottom < 0) {\n return false;\n }\n if (top > document.documentElement.clientHeight) {\n return false;\n }\n if (top <= itemParentRect.bottom === false) {\n return false;\n }\n if (top + height <= itemParentRect.top) {\n return false;\n }\n return true;\n }\n\n /**\n * test if destination's attributes contain words that start with the given query\n */\n private destinationMatchesQuery(destination: DestinationSearchItem, query: string): boolean {\n // title that we test if it contains any of the queries.\n // Mark each word start with a space so that search “sin” doesn’t match “Helsinki”,\n // but we can match on every word start, including “Palma De Mallorca’s” Mallorca\n const t =\n ` ${destination.title} ${destination.normalizedTitle} ${destination.titleMaster} ${destination.normalizedTitleMaster} ${destination.country} ${destination.countryMaster} ${destination.continentMaster} ${destination.continent}`.toLowerCase();\n\n return t.includes(` ${query?.toLowerCase()}`);\n }\n\n private recursiveMatchCheck(destination: DestinationSearchItem, query: string): boolean {\n const selfMatch = this.destinationMatchesQuery(destination, query);\n\n if (isNotEmpty(destination.items)) {\n const childMatch = destination.items.some((child) => this.recursiveMatchCheck(child, query));\n return selfMatch || childMatch;\n }\n\n return selfMatch;\n }\n\n private mapQueryMatches(destinations: DestinationSearchItem[], query: string): DestinationSearchItem[] {\n return destinations?.map((destination) => ({\n ...destination,\n items: this.mapQueryMatches(destination.items, query),\n matchesQuery: isBlank(query) || this.recursiveMatchCheck(destination, query),\n }));\n }\n\n private updateDestinationOptionsList(destinations: DestinationSearchItem[]): void {\n const query = this.destinationInput.value;\n const selectedItem = destinations.findIndex((d) => this.destinationMatchesQuery(d, query));\n\n this.matchingDestinations$.next(destinations);\n this.highlightedItem$.next(selectedItem);\n\n // eslint-disable-next-line rxjs/no-subject-value\n if (isNotBlank(query) && !this.optionsListVisible$.getValue()) {\n this.openOptionsList();\n }\n }\n}\n","
    \n \n {{ title }}\n \n \n
    \n\n
    \n \n
    \n
    \n \n
    \n
    \n
    \n \n
    \n \n \n
    \n
    \n","import { Component, ChangeDetectionStrategy, Input, OnInit, OnDestroy } from '@angular/core';\n\nimport { SvgLibraryIcon } from '@finnairoyj/fcom-ui-styles/enums';\nimport { Observable, of } from 'rxjs';\n\nimport { CampaignBannerService } from '@fcom/common/services/campaign-banner/campaign-banner.service';\nimport { AspectRatios } from '@fcom/ui-components';\nimport { CmsArticle, CmsMedia } from '@fcom/core-api';\n\n@Component({\n selector: 'fin-destination-search-hero',\n templateUrl: 'destination-search-hero.component.html',\n styleUrls: ['destination-search-hero.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class DestinationSearchHeroComponent implements OnInit, OnDestroy {\n aspectRatio$: Observable = of('21x9');\n picture: CmsMedia;\n campaignText: string;\n iconName: SvgLibraryIcon;\n enableBlackTeaser: boolean;\n\n @Input()\n content: CmsArticle;\n\n constructor(private campaignBannerService: CampaignBannerService) {}\n\n ngOnInit(): void {\n this.picture = this.content.media?.[0] ?? null;\n this.campaignText = this.content.related?.[0]?.teaserText ?? null;\n this.iconName = this.content.related?.[0]?.localSettings?.iconName ?? SvgLibraryIcon.AIRCRAFT_TILTED;\n this.enableBlackTeaser = !!this.content.related?.[0]?.localSettings?.enableBlackTeaser;\n\n if (this.campaignText) {\n this.campaignBannerService.setCampaignBannerVisibility(false);\n }\n }\n\n ngOnDestroy(): void {\n this.campaignBannerService.setCampaignBannerVisibility(true);\n }\n}\n","import { Component, Input, ChangeDetectionStrategy, Output, EventEmitter } from '@angular/core';\n\nimport { Observable, of } from 'rxjs';\n\nimport { GlobalBookingTravelClass } from '@fcom/core';\nimport { TripType } from '@fcom/core/interfaces';\nimport { DestinationSearchViewStyle } from '@fcom/destination-search/interfaces/destination-search.interface';\n\nimport { DestinationSearchBlockOffer } from '../../../cms/interfaces/destination-promo.interface';\n\n@Component({\n selector: 'fin-destination-search-results-item',\n templateUrl: 'destination-search-results-item.component.html',\n styleUrls: ['destination-search-results-item.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class DestinationSearchResultsItemComponent {\n isAmContinueModalOpen = false;\n flightHotelUrl: string;\n\n @Output()\n destinationClicked: EventEmitter<[DestinationSearchBlockOffer, GlobalBookingTravelClass, TripType]> =\n new EventEmitter();\n\n @Output()\n flightHotelClicked: EventEmitter = new EventEmitter();\n\n @Output()\n calendarClicked: EventEmitter<[Event, DestinationSearchBlockOffer, GlobalBookingTravelClass, TripType]> =\n new EventEmitter();\n\n @Input()\n offer: DestinationSearchBlockOffer;\n\n @Input()\n viewStyle: DestinationSearchViewStyle;\n\n @Input()\n enableTeaser: boolean;\n\n @Input()\n showRoundTripPrices$: Observable = of(false);\n\n emitClick([travelClass, tripType]: [GlobalBookingTravelClass, TripType]): void {\n this.destinationClicked.emit([this.offer, travelClass, tripType]);\n }\n\n emitCalendarClick([event, travelClass, tripType]: [Event, GlobalBookingTravelClass, TripType]): void {\n this.calendarClicked.emit([event, this.offer, travelClass, tripType]);\n }\n\n openAmContinueModal({ amLink }: { amLink: string }): void {\n this.isAmContinueModalOpen = true;\n this.flightHotelUrl = amLink;\n this.flightHotelClicked.emit(this.offer);\n }\n\n closeAmContinueModal(): void {\n this.isAmContinueModalOpen = false;\n }\n}\n","\n\n\n","import { Component, Input } from '@angular/core';\n\nimport { SvgLibraryIcon } from '@finnairoyj/fcom-ui-styles/enums';\n\nimport { CmsTaxonomyGeneral } from '@fcom/core-api';\nimport { GtmService } from '@fcom/common/gtm';\nimport { ElementActions, ElementTypes, GaContext } from '@fcom/common/interfaces';\n\nimport { type RibbonTheme } from '../../interfaces/destination-search.interface';\n\n@Component({\n selector: 'fin-destination-search-campaign-ribbon',\n templateUrl: './destination-search-campaign-ribbon.component.html',\n styleUrls: ['./destination-search-campaign-ribbon.component.scss'],\n})\nexport class DestinationSearchCampaignRibbonComponent {\n @Input()\n bookByText: string;\n\n @Input()\n travelPeriodText: string;\n\n @Input()\n termsAndConditionText: string;\n\n @Input()\n termsAndConditionLink: string;\n\n @Input()\n theme: RibbonTheme;\n\n readonly CmsTaxonomyGeneral = CmsTaxonomyGeneral;\n readonly SvgLibraryIcon = SvgLibraryIcon;\n\n constructor(private gtmService: GtmService) {}\n\n onLinkClick(event: Event): void {\n event.stopPropagation();\n\n // send the gtm track events\n this.gtmService.trackElement(\n 'terms-and-conditions',\n GaContext.LANDING_PAGE,\n ElementTypes.LINK,\n null,\n ElementActions.CLICK\n );\n // open the accordion\n const elem = document.getElementsByTagName('cms-accordion')[0];\n const accordionButton = elem?.getElementsByTagName('button')[0];\n if (accordionButton && accordionButton.getAttribute('aria-expanded') === 'false') {\n accordionButton.click();\n }\n }\n}\n","\n
    \n \n
    \n

    \n {{ bookByText }}\n

    \n
    \n
    \n
    \n \n
    \n

    \n {{ travelPeriodText }}\n

    \n
    \n
    \n
    \n \n
    \n\n","export const ORIGIN_SELECTOR_CONFIG: { [site: string]: string[] } = {\n DE: ['BER', 'DUS', 'HAM', 'FRA', 'MUC', 'STR', 'HAJ'],\n CH: ['ZRH', 'GVA'],\n AT: ['VIE', 'INN', 'SZG'],\n EE: ['TLL', 'TAY'],\n LV: ['RIX'],\n LT: ['VNO'],\n PL: ['WAW', 'GDN', 'KRK', 'WRO'],\n HU: ['BUD'],\n FR: ['PAR', 'NCE', 'BOD', 'LYS', 'MRS', 'TLS'],\n IT: ['MIL', 'ROM', 'VCE', 'VRN', 'BLQ', 'NAP'],\n ES: ['MAD', 'BCN', 'AGP', 'ALC', 'BIO', 'VLC', 'LCG', 'TCI', 'LPA'],\n PT: ['LIS', 'OPO', 'FAO', 'FNC'],\n US: ['NYC', 'LAX', 'CHI', 'DFW', 'SEA', 'MIA'],\n JP: ['TYO', 'OSA', 'FUK', 'NGO', 'CTS'],\n SE: ['STO', 'GOT'],\n NO: ['OSL', 'BGO', 'TRD', 'BOO', 'TOS', 'KKN'],\n GB: ['LON', 'EDI', 'MAN'],\n DK: ['CPH', 'BLL'],\n};\n","
    \n \n \n \n
    \n","import { ChangeDetectionStrategy, Component, EventEmitter, Input, Output } from '@angular/core';\n\nimport { Observable } from 'rxjs';\n\nimport { SortOption } from '@fcom/destination-search/interfaces';\n\n/**\n * @todo: To be moved to ui-components\n */\n\n@Component({\n selector: 'fin-sort-options',\n styleUrls: ['./sort-options.component.scss'],\n templateUrl: './sort-options.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class SortOptionsComponent {\n @Output()\n optionChange: EventEmitter = new EventEmitter();\n\n @Input()\n fieldName: string;\n\n @Input()\n selected$: Observable;\n\n @Input()\n sortOptions: SortOption[];\n}\n","
    \n {{\n 'destinationSearch.originSelectorLabel' | finLocalization\n }}\n \n
    \n\n

    \n","import { Component, ChangeDetectionStrategy, Input, OnInit, Output, EventEmitter } from '@angular/core';\n\nimport { combineLatest, distinctUntilChanged, map, Observable, of, switchMap, filter } from 'rxjs';\n\nimport { finShare } from '@fcom/rx';\nimport { CmsPlaceholder } from '@fcom/core-api';\nimport { LanguageService } from '@fcom/ui-translate';\nimport { SortOption } from '@fcom/destination-search/interfaces';\nimport { LocationRouteCffService } from '@fcom/core';\n\nimport { ORIGIN_SELECTOR_CONFIG } from '../../constants';\n\nexport interface OriginSelectedEvent {\n origin: string;\n destinations?: string[];\n}\n\n@Component({\n selector: 'fin-destination-search-origin-selector',\n templateUrl: 'destination-search-origin-selector.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class DestinationSearchOriginSelectorComponent implements OnInit {\n @Input()\n content: CmsPlaceholder;\n\n @Input()\n selectedOriginLocationCode: string;\n\n @Output()\n originSelected: EventEmitter = new EventEmitter();\n\n countryCode$: Observable;\n selected$: Observable;\n selectedOriginLocationName$: Observable;\n hasSelector$: Observable;\n\n originOptions$: Observable;\n\n constructor(\n private languageService: LanguageService,\n private locationRouteCffService: LocationRouteCffService\n ) {}\n\n ngOnInit(): void {\n this.countryCode$ = this.languageService.countryCode;\n\n const customOrigins = Object.keys(this.content?.localSettings?.restrictToDestinations?.destinationsByOrigin || {});\n\n const origins$: Observable =\n customOrigins.length > 0\n ? of(customOrigins)\n : this.languageService.countryCode.pipe(map((countryCode) => ORIGIN_SELECTOR_CONFIG[countryCode]));\n\n this.hasSelector$ = this.content?.localSettings?.disableOriginSelector\n ? of(false)\n : origins$.pipe(map((origins) => !!origins?.length));\n\n this.originOptions$ = origins$.pipe(\n switchMap(\n (origins) =>\n combineLatest(\n origins.map((origin) =>\n this.locationRouteCffService\n .getLocaleCityName(origin, this.languageService.localeValue)\n .pipe(map((cityName) => ({ value: origin, label: cityName })))\n )\n ) as Observable\n )\n );\n\n this.selected$ = this.hasSelector$.pipe(\n filter(Boolean),\n switchMap(() =>\n this.originOptions$.pipe(\n map(\n (options) =>\n options.find((option) => option.value === this.selectedOriginLocationCode)?.value || options[0].value\n )\n )\n )\n );\n\n this.selectedOriginLocationName$ = this.locationRouteCffService\n .bestGuessFor(this.selectedOriginLocationCode, this.languageService.localeValue)\n .pipe(\n distinctUntilChanged(),\n map((locationData) => locationData.cityName ?? this.selectedOriginLocationCode),\n finShare()\n );\n }\n\n selectOrigin(originLocationCode: string): void {\n this.originSelected.emit({\n origin: originLocationCode,\n destinations: this.content?.localSettings?.restrictToDestinations?.destinationsByOrigin?.[originLocationCode],\n });\n }\n}\n","
    \n
    \n
    \n \n \n
    \n
    \n
    \n
    \n \n
    \n \n
    \n

    {{ 'destinationSearch.filteredDestinations' | finLocalization }}

    \n \n
    \n {{ 'destinationSearch.noResultsFound' | finLocalization }}\n \n
    \n \n\n \n \n {{\n 'destinationSearch.loadingPrices' | finLocalization\n }}\n \n
    \n\n \n
    \n {{\n 'destinationSearch.loadingDestinations' | finLocalization\n }}\n \n
    \n
    \n\n \n \n \n \n\n \n \n \n\n \n \n \n \n \n \n
    \n

    \n {{ categoryLabel | finLocalization }}\n

    \n
    \n \n \n \n \n
    \n\n \n \n \n \n\n \n \n \n\n
    \n {{ 'destinationSearch.pricesLoaded' | finLocalization }}\n
    \n \n \n
    \n\n\n \n\n","import { ChangeDetectionStrategy, Component, EventEmitter, Input, OnDestroy, OnInit, Output } from '@angular/core';\n\nimport { Store } from '@ngrx/store';\nimport { BehaviorSubject, combineLatest, filter, NEVER, Observable, of, Subscription, withLatestFrom } from 'rxjs';\nimport { distinctUntilChanged, map, startWith, switchMap, take } from 'rxjs/operators';\n\nimport {\n CmsCollection,\n CmsContent,\n CmsContentType,\n CmsPlaceholder,\n CmsTarget,\n CmsTaxonomyGeneral,\n isCmsArticle,\n} from '@fcom/core-api';\nimport { CmsLink, CmsTeaser } from '@fcom/core-api/interfaces';\nimport {\n AspectRatioString,\n MediaQueryService,\n PriceCalendarCTAParams,\n PriceCalendarService,\n TestVariant,\n TripType,\n} from '@fcom/common';\nimport { NON_EUROPE_SITES } from '@fcom/core/constants';\nimport { LoaderTheme, PromoTheme, toCamelCase } from '@fcom/ui-components';\nimport { LanguageService } from '@fcom/ui-translate';\nimport { stopPropagation, unsubscribe } from '@fcom/core/utils';\nimport { DestinationSearchBlockOffer } from '@fcom/cms/interfaces';\nimport { AppState, CmsDataService, GlobalBookingTravelClass } from '@fcom/core';\nimport { ElementActions, ElementTypes, GaContext, PriceCalendarParams } from '@fcom/common/interfaces';\nimport { GtmService } from '@fcom/common/gtm';\nimport { finShare } from '@fcom/rx';\nimport { CampaignBannerService } from '@fcom/common/services/campaign-banner/campaign-banner.service';\nimport {\n DestinationSearchFeatureState,\n DestinationSearchFilterStateMeta,\n DestinationSearchViewStyle,\n PriceLoadingState,\n SortBehavior,\n} from '@fcom/destination-search/interfaces';\nimport { CmsTripTypeMap } from '@fcom/core/utils/tripType.utils';\nimport { LoginStatus, Profile } from '@fcom/core-api/login';\nimport { loginStatus, profile } from '@fcom/core/selectors';\n\nimport { CampaignRibbon, Continent, RibbonTheme } from '../../interfaces';\nimport { filterState, roundTripPricesState } from '../../store';\nimport { DestinationSearchOffersService } from '../../services/destination-search-offers.service';\nimport { setFromLocationCode, setRestrictToDestinations } from '../../store/actions/destination-search-filter.actions';\nimport { OriginSelectedEvent } from '../destination-search-origin-selector/destination-search-origin-selector.component';\n\nexport interface CategorizedDestination {\n [key: string]: {\n destinations: DestinationSearchBlockOffer[];\n categoryLabel: string;\n promo$?: Observable;\n };\n}\n\n@Component({\n selector: 'fin-destination-search-results',\n templateUrl: 'destination-search-results.component.html',\n styleUrls: ['destination-search-results.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class DestinationSearchResultsComponent implements OnInit, OnDestroy {\n @Input()\n content: CmsPlaceholder;\n\n @Input()\n meta: DestinationSearchFilterStateMeta;\n\n @Input()\n filteredDestinationsWithOffers$: Observable;\n\n @Input()\n viewStyle: DestinationSearchViewStyle = DestinationSearchViewStyle.TILES; // default and only one until next iteration\n\n @Input()\n selectedOriginLocationCode$: Observable;\n\n @Input()\n isFilterApplied$: Observable;\n\n @Output()\n clearAllFilters = new EventEmitter();\n\n readonly PriceLoadingState = PriceLoadingState;\n readonly LoaderTheme = LoaderTheme;\n readonly PromoTheme = PromoTheme;\n readonly CmsTaxonomyGeneral = CmsTaxonomyGeneral;\n readonly CmsContentType = CmsContentType;\n readonly NEVER = NEVER;\n readonly CmsTripTypeMap = CmsTripTypeMap;\n readonly TestVariant = TestVariant;\n\n SORTING = SortBehavior;\n\n sortedDestinations$: Observable;\n sortOrder$: BehaviorSubject;\n subscriptions: Subscription = new Subscription();\n sortByValues: string[];\n updatingPricesLoader$: Observable;\n\n isMobile$: Observable;\n identifier: string;\n\n ribbon$: Observable;\n\n topPromoItems$: Observable;\n bottomPromoItems$: Observable;\n categorizedDestinations$: Observable;\n categoryList$: Observable<(Continent | string)[]>;\n aspectRatioForPromo$: Observable = NEVER;\n customDestinations$: Observable;\n customContinents: string[];\n disableSectionHeadings = false;\n profile$: Observable;\n showRoundTripPrices$: Observable = of(false);\n calendarOpen$: Observable = NEVER;\n\n constructor(\n private languageService: LanguageService,\n private store$: Store,\n private appStore$: Store,\n private gtmService: GtmService,\n private destinationSearchOffersService: DestinationSearchOffersService,\n private mediaQueryService: MediaQueryService,\n private cmsDataService: CmsDataService,\n private campaignBannerService: CampaignBannerService,\n private priceCalendarService: PriceCalendarService\n ) {\n this.calendarOpen$ = this.priceCalendarService.calendarOpen$;\n }\n\n ngOnInit(): void {\n this.showRoundTripPrices$ = this.store$.pipe(roundTripPricesState(this.meta.id), startWith(false), finShare());\n\n this.profile$ = this.appStore$.pipe(\n loginStatus(),\n filter(\n (memberLoginStatus) => memberLoginStatus !== LoginStatus.INITIAL && memberLoginStatus !== LoginStatus.PENDING\n ),\n switchMap((memberLoginStatus) =>\n memberLoginStatus === LoginStatus.LOGGED_IN ? this.appStore$.pipe(profile()) : of(undefined)\n ),\n finShare()\n );\n\n this.topPromoItems$ = this.content?.localSettings?.topPromoItems?.jsonUrl\n ? this.fetchPromoItems(this.content?.localSettings?.topPromoItems?.jsonUrl)\n : NEVER;\n\n this.bottomPromoItems$ = this.content?.localSettings?.bottomPromoItems?.jsonUrl\n ? this.fetchPromoItems(this.content?.localSettings?.bottomPromoItems?.jsonUrl)\n : NEVER;\n\n this.identifier = this.meta.id;\n this.updatingPricesLoader$ = this.destinationSearchOffersService.loaderStatus$;\n this.isMobile$ = this.mediaQueryService.isBreakpoint$('mobile');\n this.aspectRatioForPromo$ = this.isMobile$.pipe(map((isMobile) => (isMobile ? '4x3' : '21x9')));\n this.disableSectionHeadings = this.content?.localSettings?.disableSectionHeadings;\n this.customContinents = this.content?.localSettings?.restrictToDestinations?.continent;\n\n this.customDestinations$ = this.selectedOriginLocationCode$.pipe(\n map(\n (selectedOriginLocationCode) =>\n this.content?.localSettings?.restrictToDestinations?.destination ??\n this.content?.localSettings?.restrictToDestinations?.destinationsByOrigin[selectedOriginLocationCode]\n )\n );\n\n this.sortByValues = [SortBehavior.ALPHABETICAL, SortBehavior.PRICE];\n const sortBehavior: SortBehavior =\n SortBehavior[this.content?.localSettings?.selectedSortBy] ?? SortBehavior.ALPHABETICAL;\n this.sortOrder$ = new BehaviorSubject(sortBehavior);\n\n if (this.content?.localSettings?.ribbon?.jsonUrl) {\n this.campaignBannerService.setCampaignBannerVisibility(false);\n this.ribbon$ = this.cmsDataService.getFragmentJson(this.content.localSettings.ribbon.jsonUrl).pipe(\n filter(Boolean),\n map((content: CmsTeaser) => ({\n bookByText: content?.localSettings?.bookByText,\n travelPeriodText: content?.localSettings?.travelPeriodText,\n termsAndConditionText: content?.teaserText,\n termsAndConditionLink$: this.cmsDataService\n .getFragmentJson(content?.target?.jsonUrl)\n .pipe(map((target: CmsTeaser) => target?.url)),\n theme: content?.subjectTaxonomyTags?.find(\n (tag) => tag === CmsTaxonomyGeneral.BLACK_FRIDAY || tag === CmsTaxonomyGeneral.HEATHER_BG\n ) as RibbonTheme,\n }))\n );\n } else {\n this.ribbon$ = NEVER;\n }\n\n /* Sort destinations, alphabetical order by default. Custom order only works when disableSectionHeadings is true\n If restrictToDestinations is set, then use the list instead of normal offer destination list*/\n this.sortedDestinations$ = combineLatest([this.filteredDestinationsWithOffers$, this.customDestinations$]).pipe(\n map(([destinations, customDestinations]) =>\n customDestinations\n ? customDestinations\n .map((countryCode) => destinations.find((destination) => destination.locationCode === countryCode))\n .filter(Boolean)\n : destinations\n ),\n switchMap((destinations) =>\n this.languageService.countryCode.pipe(\n map((countryCode) => {\n const targetCountry = destinations.find((destination) => destination.flag === countryCode.toLowerCase());\n return targetCountry && targetCountry.continent !== Continent.EUROPE\n ? destinations.filter((destination) => destination.continent !== targetCountry.continent)\n : destinations;\n })\n )\n ),\n withLatestFrom(this.sortOrder$.pipe(distinctUntilChanged())),\n map(([destinations, sorting]) => {\n if (sorting === SortBehavior.ALPHABETICAL) {\n return destinations.sort(this.sortByAlphabetical);\n }\n if (sorting === SortBehavior.PRICE) {\n return destinations.sort(this.sortByPrice);\n }\n if (sorting === SortBehavior.CUSTOM && this.disableSectionHeadings) {\n return destinations;\n }\n return destinations.sort(this.sortByAlphabetical);\n }),\n map((destinations) => this.sortByValidPriceFirst(destinations))\n );\n /*\n if disableSectionHeadings is true, then no need to group the destination by continents\n if restrictToDestinations.continent is set, then use the list\n */\n this.categoryList$ = this.languageService.countryCode.pipe(\n switchMap((countryCode) =>\n this.disableSectionHeadings\n ? of(['mixed'])\n : !this.customContinents\n ? of(\n [\n countryCode === 'FI' ? 'finland' : undefined,\n Continent.EUROPE,\n Continent.MIDDLE_EAST,\n Continent.AMERICA,\n Continent.ASIA_PACIFIC,\n Continent.AFRICA,\n ].filter(Boolean)\n )\n : of(this.customContinents)\n ),\n map((continents) => continents.map((continent) => toCamelCase(continent)))\n );\n\n const continentPromoItems = this.content?.localSettings?.continentPromoItems\n ? Object.keys(this.content.localSettings.continentPromoItems).reduce(\n (init, continent) => ({\n ...init,\n [continent]: this.content?.localSettings?.continentPromoItems[continent]?.jsonUrl\n ? this.fetchContinentPromoItem(this.content?.localSettings?.continentPromoItems[continent]?.jsonUrl)\n : NEVER,\n }),\n {}\n )\n : null;\n\n this.categorizedDestinations$ = combineLatest([\n this.sortedDestinations$,\n this.languageService.countryCode,\n this.categoryList$,\n ]).pipe(\n map(\n ([destinations, countryCode, categoryList]: [DestinationSearchBlockOffer[], string, (Continent | string)[]]) =>\n destinations\n .filter(Boolean)\n .map((destination) => ({\n ...destination,\n isShortHaul: NON_EUROPE_SITES.includes(this.languageService.langValue)\n ? false\n : destination.continent === Continent.EUROPE,\n }))\n .reduce(\n (init, destination) => {\n const key = this.disableSectionHeadings\n ? 'mixed'\n : countryCode === 'FI' && destination.flag === 'fi'\n ? 'finland'\n : toCamelCase(destination.continent);\n init[key]?.destinations?.push(destination);\n return init;\n },\n Object.fromEntries(\n categoryList.map((k) => [\n k,\n {\n destinations: [],\n categoryLabel: `destinationSearch.continentTitle.${toCamelCase(k)}`,\n promo$: continentPromoItems?.[k],\n },\n ])\n ) as CategorizedDestination\n )\n ),\n map((destinations) =>\n //filter out continent has empty destination list\n Object.fromEntries(Object.entries(destinations).filter(([_, v]) => v.destinations?.length > 0))\n )\n );\n }\n\n ngOnDestroy(): void {\n if (this.subscriptions) {\n this.subscriptions = unsubscribe(this.subscriptions);\n }\n this.campaignBannerService.setCampaignBannerVisibility(true);\n }\n\n trackByFn(_index: number, item: DestinationSearchBlockOffer): string {\n return item.destination;\n }\n\n fetchPromoItems(url: string): Observable {\n return this.profile$.pipe(\n switchMap((memberProfile) =>\n this.cmsDataService.getFragmentJson(url, { tier: memberProfile?.tier || '' }).pipe(\n map((content: CmsCollection) => content?.items.map((item) => item.jsonUrl)),\n switchMap((urls: string[]) => this.getCollectionItems(urls)),\n switchMap((items: CmsContent[]) =>\n combineLatest(\n items.map((item: CmsContent) =>\n isCmsArticle(item)\n ? this.getArticleButton(item).pipe(\n map((targets) => ({ ...item, target: targets?.length ? targets[0] : undefined }))\n )\n : of(item)\n )\n )\n )\n )\n ),\n finShare()\n );\n }\n\n fetchContinentPromoItem(url: string): Observable {\n return this.cmsDataService.getFragmentJson(url).pipe(\n switchMap((item: CmsContent) =>\n isCmsArticle(item)\n ? this.getArticleButton(item).pipe(\n map((targets) => ({ ...item, target: targets?.length ? targets[0] : undefined }))\n )\n : of(item)\n ),\n switchMap((item: CmsContent) =>\n item?.firstMedia?.jsonUrl\n ? this.cmsDataService\n .getFragmentJson(item.firstMedia.jsonUrl)\n .pipe(map((mediaContent) => ({ ...item, media: [mediaContent] })))\n : of({ ...item, media: [] })\n )\n );\n }\n\n calendarClicked(\n selectedOriginLocationCode: string,\n [event, destinationItem, travelClass, tripType]: [\n Event,\n DestinationSearchBlockOffer,\n GlobalBookingTravelClass,\n TripType,\n ]\n ): void {\n stopPropagation(event);\n this.priceCalendarService.openPriceCalendar(\n selectedOriginLocationCode,\n destinationItem.locationCode,\n tripType,\n travelClass,\n destinationItem.titleMaster\n );\n }\n\n priceCalendarCTAClicked(params: PriceCalendarCTAParams): void {\n this.priceCalendarService.priceCalendarCTAClicked(params);\n }\n\n closePriceCalendar(): void {\n this.priceCalendarService.closePriceCalendar();\n }\n\n destinationClick([destinationBlockOffer, travelClass, offerTripType]: [\n DestinationSearchBlockOffer,\n GlobalBookingTravelClass,\n TripType,\n ]): void {\n this.subscriptions.add(\n this.store$\n .pipe(filterState(this.identifier), take(1), withLatestFrom(this.selectedOriginLocationCode$))\n .subscribe(([{ tripType, tripDates }, selectedOriginLocationCode]) => {\n const selectedTripType = offerTripType || tripType;\n this.priceCalendarService.prefillBookingWidget(\n travelClass,\n tripDates,\n selectedTripType,\n destinationBlockOffer.locationCode,\n selectedOriginLocationCode\n );\n this.gtmService.trackElement(\n `tile-${destinationBlockOffer.titleMaster.replace(/ /g, '_')}-${travelClass}-${this.CmsTripTypeMap[selectedTripType]}`,\n GaContext.DESTINATION_MAIN_PAGE,\n ElementTypes.LIST_ITEM,\n undefined,\n ElementActions.CLICK\n );\n })\n );\n }\n\n flightHotelClick(destinationItem): void {\n this.gtmService.trackElement(\n `tile-${destinationItem.titleMaster.replace(/ /g, '_')}-flightHotel`,\n GaContext.DESTINATION_MAIN_PAGE,\n ElementTypes.LIST_ITEM,\n undefined,\n ElementActions.CLICK\n );\n }\n\n onOriginSelected(event: OriginSelectedEvent): void {\n if (event.destinations?.length) {\n this.store$.dispatch(setRestrictToDestinations({ restrictToDestinations: event.destinations, meta: this.meta }));\n }\n this.store$.dispatch(setFromLocationCode({ fromLocationCode: event.origin, meta: this.meta }));\n\n this.gtmService.trackElement(\n 'origin-selector',\n GaContext.LANDING_PAGE,\n ElementTypes.SELECT_BOX,\n event.origin,\n ElementActions.CLICK\n );\n }\n\n trackByCmsContent(index: number, content: CmsContent): number {\n return content.contentId ?? index;\n }\n\n private sortByAlphabetical(a: DestinationSearchBlockOffer, b: DestinationSearchBlockOffer) {\n return a.title > b.title ? 1 : -1;\n }\n\n private sortByPrice(a: DestinationSearchBlockOffer, b: DestinationSearchBlockOffer) {\n const compare = a.price ? a.price : Infinity;\n const newPrice = b.price ? b.price : Infinity;\n\n return compare > newPrice ? 1 : -1;\n }\n\n private sortByValidPriceFirst = (destinations: DestinationSearchBlockOffer[]): DestinationSearchBlockOffer[] =>\n destinations\n .filter((i) => i.onewayPrice || i.returnPrice || i.price)\n .concat(destinations.filter((i) => !i.onewayPrice && !i.returnPrice && !i.price));\n\n private getCollectionItems(urls: string[]): Observable {\n return combineLatest(\n urls.map((url) => this.cmsDataService.getFragmentJson(url, { nestingDepth: '1', duplicates: 'true' }))\n );\n }\n\n private getArticleButton(article: CmsContent): Observable {\n if (!article.related?.length) {\n return of([]);\n }\n\n const data = article.related.map(\n (item: CmsTeaser) =>\n ({\n title: item.teaserTitle,\n openInNewTab: item.openInNewTab,\n url: (item.target as any as CmsLink).jsonUrl,\n }) as CmsTarget\n );\n\n return combineLatest(\n data.map((items) => this.cmsDataService.getFragmentJson(items.url))\n ).pipe(\n map((targets) =>\n data.map((item, index) => ({\n ...item,\n url: targets[index].url,\n openInNewTab:\n (targets[index] as CmsTeaser).openInNewTab !== undefined\n ? (targets[index] as CmsTeaser).openInNewTab\n : item.openInNewTab,\n }))\n )\n );\n }\n}\n","
    \n \n
    \n \n {{ 'travelClasses' | finLocalization }}\n \n \n {{ COMMON_BOOKING_TRAVEL_CLASSES[selectedTravelClass].translationKey | finLocalization }}\n \n
    \n \n \n
    \n\n\n \n \n \n \n {{ COMMON_BOOKING_TRAVEL_CLASSES[travelClass].translationKey | finLocalization }}\n \n \n \n \n\n","import {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n EventEmitter,\n Input,\n OnDestroy,\n OnInit,\n Output,\n} from '@angular/core';\n\nimport { SvgLibraryIcon } from '@finnairoyj/fcom-ui-styles/enums';\nimport { Observable, Subscription } from 'rxjs';\n\nimport { COMMON_BOOKING_TRAVEL_CLASSES, GlobalBookingTravelClass } from '@fcom/core';\nimport { unsubscribe } from '@fcom/core/utils';\n\n@Component({\n selector: 'fin-destination-search-travel-class-selection',\n templateUrl: 'destination-search-travel-class-selection.component.html',\n styleUrls: ['destination-search-travel-class-selection.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class DestinationSearchTravelClassSelectionComponent implements OnInit, OnDestroy {\n readonly COMMON_BOOKING_TRAVEL_CLASSES = COMMON_BOOKING_TRAVEL_CLASSES;\n readonly SvgLibraryIcon = SvgLibraryIcon;\n\n modalOpen = false;\n\n @Input()\n travelClasses: GlobalBookingTravelClass[] = [\n GlobalBookingTravelClass.MIXED,\n GlobalBookingTravelClass.ECONOMY,\n GlobalBookingTravelClass.BUSINESS,\n ];\n\n @Input()\n initialTravelClass$: Observable;\n\n @Output()\n selectedTravelClassChange = new EventEmitter();\n\n selectedTravelClass: GlobalBookingTravelClass = GlobalBookingTravelClass.MIXED;\n\n private subscriptions = new Subscription();\n\n constructor(private cdr: ChangeDetectorRef) {}\n\n ngOnInit(): void {\n this.travelClasses.splice(2, 0, GlobalBookingTravelClass.ECOPREMIUM);\n\n this.subscriptions.add(\n this.initialTravelClass$.subscribe((travelClass) => {\n this.selectedTravelClass = travelClass;\n this.cdr.markForCheck();\n })\n );\n }\n\n ngOnDestroy(): void {\n unsubscribe(this.subscriptions);\n }\n\n closeModal(): void {\n this.modalOpen = false;\n }\n\n openModal(): void {\n this.modalOpen = true;\n }\n\n selectTravelClass(travelClass: GlobalBookingTravelClass): void {\n this.selectedTravelClass = travelClass;\n this.selectedTravelClassChange.emit(this.selectedTravelClass);\n this.closeModal();\n }\n}\n","\n\n\n \n \n \n
    \n
    \n \n \n
    \n\n \n
    \n\n \n \n \n \n \n\n\n\n \n \n \n \n \n \n \n\n\n\n \n \n \n \n
  • \n \n \n {{ country.title }} ({{ country.count }}) \n \n \n
    \n
      \n \n
    \n
    \n \n
  • \n
    \n
    \n \n \n
    \n \n \n
    \n \n {{ 'destinationSearch.noMatches' | finLocalization }}\n \n
    \n \n \n
    \n\n\n \n 1\"\n class=\"flex flex--column ps-small all\"\n [id]=\"'to-field-option-all'\"\n role=\"option\"\n (click)=\"toggleDestinationSelection(destination)\"\n (keydown)=\"toggleDestinationByKeyboard($event, destination)\"\n >\n \n {{\n 'destinationSearch.selectAll' | finLocalization: { country: destination.title }\n }}\n \n \n \n 1\"\n [class.border-bottom]=\"!last\"\n [id]=\"'to-field-option-' + dest.locationCode\"\n [attr.data-testid]=\"'to-field-option-' + dest.locationCode\"\n role=\"option\"\n (click)=\"toggleDestinationSelection(dest, destination)\"\n (keydown)=\"toggleDestinationByKeyboard($event, dest, destination)\"\n >\n \n {{ dest.title }}\n \n \n \n \n \n \n \n {{ destination.title }},\n {{ destination.type === DESTINATION_TYPE.COUNTRY ? destination.continent : destination.country }}\n \n \n \n\n\n\n \n
    \n
    \n \n {{\n 'destinationSearch.selectedDestination.' + (selectedDestinations.length === 1 ? 'singular' : 'plural')\n | finLocalization: { total: selectedDestinations.length }\n }}\n = 3\">\n \n {{ 'destinationSearch.chip.action.removeAll' | finLocalization }}\n \n \n
    \n \n
      \n
    • \n \n \n
    • \n
    \n
    \n
    \n
    \n","import {\n ChangeDetectionStrategy,\n Component,\n ElementRef,\n EventEmitter,\n Inject,\n Input,\n OnDestroy,\n OnInit,\n Output,\n Renderer2,\n ViewChild,\n} from '@angular/core';\nimport { UntypedFormControl } from '@angular/forms';\nimport { DOCUMENT } from '@angular/common';\n\nimport { IconLibrary, SvgLibraryIcon } from '@finnairoyj/fcom-ui-styles/enums';\nimport { BehaviorSubject, combineLatest, Observable, Subject, Subscription } from 'rxjs';\nimport { debounceTime, distinctUntilChanged, filter, map, startWith, take, tap } from 'rxjs/operators';\n\nimport { flattenDestinations } from '@fcom/destination-search/utils/flatten';\nimport { finShare } from '@fcom/rx';\nimport { MediaQueryService } from '@fcom/common';\nimport { ButtonComponent, ButtonSize, ButtonTheme, TagTheme, IconPosition } from '@fcom/ui-components';\nimport {\n isBlank,\n isNotBlank,\n isNotEmpty,\n unsubscribe,\n KeyCodes,\n getKeyCodeFromEvent,\n stopPropagation,\n} from '@fcom/core/utils';\nimport {\n DestinationSearchItem,\n DestinationSearchItemFilterSelection,\n DestinationSearchItemType,\n FilterAction,\n} from '@fcom/destination-search/interfaces';\n\nconst MODAL_OPEN_CLASS_NAME = 'modal-open';\n\nconst FILTERS_ORDER = ['Finland', 'Europe', 'Middle East', 'Americas', 'Asia-Pacific', 'Africa'];\n\n@Component({\n selector: 'fin-destination-search-bar',\n templateUrl: 'destination-search-bar.component.html',\n styleUrls: ['destination-search-bar.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class DestinationSearchBarComponent implements OnInit, OnDestroy {\n readonly ButtonSize = ButtonSize;\n readonly ButtonTheme = ButtonTheme;\n readonly DESTINATION_TYPE = DestinationSearchItemType;\n readonly IconLibrary = IconLibrary;\n readonly IconPosition = IconPosition;\n readonly SvgLibraryIcon = SvgLibraryIcon;\n readonly TagTheme = TagTheme;\n\n @Input()\n selectedDestinations: DestinationSearchItem[] = [];\n\n /**\n * Destinations that the user can choose from, also contains countries and continents\n */\n @Input()\n allDestinations$: Observable;\n\n @Input()\n closeOptionsList$: Observable;\n\n /**\n * Emits this.selectedDestinationIds\n */\n @Output()\n valueChange = new EventEmitter();\n\n @Output() inputFocusState = new EventEmitter();\n\n @Output() optionsListVisibilityChanged = new EventEmitter();\n\n @ViewChild('inputField')\n inputField: ElementRef;\n\n @ViewChild('inputFieldButton', { static: false })\n inputFieldButton: ElementRef;\n\n @ViewChild('showResultsButton', { static: false })\n showResultsButton: ButtonComponent;\n\n @ViewChild('tagList', { static: false })\n tagList: ElementRef;\n\n /**\n * Destinations that match the given query\n */\n matchingDestinations$: BehaviorSubject = new BehaviorSubject(undefined);\n\n /**\n * Destination options list visibility\n */\n optionsListVisible$: BehaviorSubject = new BehaviorSubject(false);\n\n continents$: Observable;\n selectedContinent$: BehaviorSubject = new BehaviorSubject(undefined);\n isStartTyping$: BehaviorSubject = new BehaviorSubject(false);\n isVisible$: Subject = new Subject();\n\n destinationInput = new UntypedFormControl();\n isMobile$: Observable;\n\n private subscriptions: Subscription = new Subscription();\n\n constructor(\n @Inject(DOCUMENT) private document: Document,\n private mediaQueryService: MediaQueryService,\n private readonly renderer: Renderer2,\n private elementRef: ElementRef\n ) {}\n\n ngOnInit(): void {\n this.continents$ = this.allDestinations$.pipe(\n take(1),\n map((allDestinations: DestinationSearchItem[]) => this.mainFilters(allDestinations)),\n map((allDestinations: DestinationSearchItem[]) => this.recursiveMapDestinationCount(allDestinations)),\n distinctUntilChanged(),\n finShare()\n );\n\n this.isMobile$ = this.mediaQueryService.isBreakpoint$('mobile');\n\n this.subscriptions.add(\n combineLatest([this.isMobile$, this.isVisible$])\n .pipe(\n map(([isMobile, isVisible]: [boolean, boolean]) => isMobile && isVisible),\n distinctUntilChanged()\n )\n .subscribe((shouldSetOverlay: boolean) => {\n if (shouldSetOverlay) {\n this.renderer.addClass(this.document.body, MODAL_OPEN_CLASS_NAME);\n } else {\n this.renderer.removeClass(this.document.body, MODAL_OPEN_CLASS_NAME);\n }\n })\n );\n\n // search by writing\n this.subscriptions.add(\n combineLatest([\n this.destinationInput.valueChanges.pipe(\n debounceTime(200),\n distinctUntilChanged(),\n startWith(''),\n tap((searchString: string) => this.isStartTyping$.next(searchString?.length > 0))\n ),\n this.continents$.pipe(filter(Boolean), distinctUntilChanged()),\n ])\n .pipe(\n tap(() => this.matchingDestinations$.next(undefined)),\n filter(([query]) => isNotBlank(query)),\n map(([query, destinations]: [string, DestinationSearchItem[]]) => {\n const updated = this.mapQueryMatches(destinations, query);\n return flattenDestinations(updated)\n .filter((d: DestinationSearchItem) => d.matchesQuery)\n .filter(\n (tag, index, array) =>\n array.findIndex((t) => `${t.title}-${t.countryCode}` === `${tag.title}-${tag.countryCode}`) === index\n );\n })\n )\n .subscribe((destinations: DestinationSearchItem[]) => {\n this.updateDestinationOptionsList(destinations);\n })\n );\n\n // get destination list by continent\n this.subscriptions.add(\n combineLatest([this.selectedContinent$, this.continents$.pipe(filter(Boolean), distinctUntilChanged())])\n .pipe(\n map(([continent, destinations]: [DestinationSearchItem, DestinationSearchItem[]]) =>\n destinations.filter((destination: DestinationSearchItem) => destination?.id === continent?.id)\n )\n )\n .subscribe((destinations: DestinationSearchItem[]) => {\n /* TODO: timeout is added to defer heavy operations to the next tick\n * We want to close the modal immediately to give the user feedback and improve SEO score\n * Slow update of destinations should still be investigated and fixed\n */\n setTimeout(() => {\n this.updateDestinationOptionsList(destinations);\n }, 0);\n })\n );\n\n this.subscriptions.add(\n this.optionsListVisible$.pipe(distinctUntilChanged()).subscribe((isVisible: boolean) => {\n this.optionsListVisibilityChanged.emit(isVisible);\n })\n );\n\n this.subscriptions.add(\n this.closeOptionsList$.subscribe(() => {\n this.closeOptionsList();\n })\n );\n }\n\n ngOnDestroy(): void {\n this.subscriptions = unsubscribe(this.subscriptions);\n }\n\n get inputHasFocus(): boolean {\n return this.document.activeElement === this.inputField?.nativeElement;\n }\n\n openModal(event: Event): void {\n stopPropagation(event);\n\n this.isVisible$.next(true);\n this.openOptionsList(true);\n setTimeout(() => {\n // wait a bit before the input field is rendered\n this.inputField?.nativeElement.focus();\n }, 100);\n }\n\n resetInputValue(isMobile: boolean): void {\n if (this.inputField && this.inputField?.nativeElement) {\n this.inputField.nativeElement.value = '';\n this.isStartTyping$.next(false);\n this.openOptionsList(isMobile);\n this.inputField.nativeElement.focus();\n }\n }\n\n handleComponentFocusOut(event: FocusEvent): void {\n event.preventDefault();\n\n const el: HTMLElement = this.elementRef?.nativeElement;\n const target = event.relatedTarget as Element;\n if (!!el && !el.contains(event.target as HTMLElement) && !target?.className.includes('tag-button')) {\n event.stopPropagation();\n this.closeOptionsList();\n }\n }\n\n onClickInputArea(event: MouseEvent, isMobile: boolean): void {\n // Distinguish between button area and input field clicks\n if (this.inputFieldButton?.nativeElement.contains(event.target)) {\n if (!this.optionsListVisible$.getValue()) {\n this.openOptionsList(isMobile);\n } else if (isMobile) {\n this.resetInputValue(isMobile);\n } else {\n this.closeOptionsList();\n }\n } else {\n this.openOptionsList(isMobile);\n }\n }\n\n openOptionsList(isMobile = false): void {\n this.inputFocusState.emit(!isMobile);\n this.optionsListVisible$.next(true);\n this.selectedContinent$.next(undefined);\n this.matchingDestinations$.next(undefined);\n }\n\n closeOptionsList(): void {\n this.inputFocusState.emit(false);\n this.destinationInput.reset();\n this.optionsListVisible$.next(false);\n this.isVisible$.next(false);\n }\n\n removeTag(destination: DestinationSearchItem): void {\n const showButton: HTMLElement = this.showResultsButton?.buttonElement?.nativeElement;\n const tags: NodeListOf = this.tagList?.nativeElement.querySelectorAll('fcom-tag-button');\n const remainingTags = Array.from(tags).filter((c: HTMLElement) => c.id !== destination.id);\n const lastTag = remainingTags[remainingTags?.length - 1];\n\n if (!lastTag) {\n showButton.focus();\n }\n\n this.valueChange.emit({\n action: FilterAction.REMOVE,\n destination,\n selectedDestinations: this.selectedDestinations,\n });\n }\n\n removeAll(): void {\n this.closeOptionsList();\n /* TODO: timeout is added to defer heavy operations to the next tick\n * We want to close the modal immediately to give the user feedback and improve SEO score\n * Slow update of destinations should still be investigated and fixed\n */\n setTimeout(() => {\n this.valueChange.emit({\n action: FilterAction.REMOVE_ALL,\n destination: undefined,\n selectedDestinations: this.selectedDestinations,\n });\n }, 0);\n }\n\n toggleDestinationSelection(destination: DestinationSearchItem, country: DestinationSearchItem = undefined): void {\n const isSelected = Boolean(this.selectedDestinations?.find((selected) => selected.id === destination.id));\n\n const countrySelectedDestinations = this.destinationIsSelected(destination)\n ? [...(country && country?.items ? [...country.items.filter((dest) => dest.id !== destination.id)] : [])]\n : [\n ...this.selectedDestinations.filter(\n (selection) =>\n selection.type === DestinationSearchItemType.DESTINATION && selection.countryCode === country?.countryCode\n ),\n ...(!isSelected && destination.type === DestinationSearchItemType.DESTINATION ? [destination] : []),\n ];\n const shouldSelectAll = country?.items?.every((item) => countrySelectedDestinations.includes(item));\n\n if (\n (country && !isSelected && shouldSelectAll) ||\n (!isSelected && destination.type === DestinationSearchItemType.COUNTRY)\n ) {\n // special case 1.\n // when all destination selected from country one by one\n // remove the destinations and select country\n\n // special case 2.\n // when all destinations selected by button\n // remove all destinations from country and select country\n setTimeout(() => {\n this.valueChange.emit({\n action: FilterAction.CUSTOM,\n destination: undefined,\n selectedDestinations: [\n ...this.selectedDestinations.filter((selected) => selected.countryCode !== destination.countryCode),\n country ? { ...country } : { ...destination },\n ],\n });\n }, 100);\n } else if (\n country &&\n !isSelected &&\n !shouldSelectAll &&\n destination.type === DestinationSearchItemType.DESTINATION\n ) {\n // special case 3.\n // when all destinations selected by button and then unselect one destination\n // remove country selection and add all destinations from country without the deselected one\n\n const filteredDestinationByCountry = this.selectedDestinations.filter(\n (selected) =>\n selected.type === DestinationSearchItemType.COUNTRY && selected.countryCode !== destination.countryCode\n );\n\n // special case 4.\n // when some destinations selected from different country\n // should merge it with selectors from different country or with another destination\n const filteredDestinationByDestination = this.selectedDestinations.filter(\n (selected) =>\n selected.type === DestinationSearchItemType.DESTINATION && selected.countryCode !== destination.countryCode\n );\n\n setTimeout(() => {\n this.valueChange.emit({\n action: FilterAction.CUSTOM,\n destination: undefined,\n selectedDestinations: [\n ...filteredDestinationByCountry,\n ...filteredDestinationByDestination,\n ...countrySelectedDestinations,\n ],\n });\n }, 100);\n } else {\n setTimeout(() => {\n // add/remove single destination\n this.valueChange.emit({\n action: isSelected ? FilterAction.REMOVE : FilterAction.ADD,\n destination,\n selectedDestinations: this.selectedDestinations,\n });\n }, 100);\n }\n }\n\n toggleDestinationByKeyboard(\n $event: KeyboardEvent,\n destination: DestinationSearchItem,\n country: DestinationSearchItem = undefined\n ): void {\n setTimeout(() => {\n if (getKeyCodeFromEvent($event) === KeyCodes.SPACE) {\n this.toggleDestinationSelection(destination, country);\n }\n }, 100);\n }\n\n destinationIsSelected(destination: DestinationSearchItem): boolean {\n return Boolean(\n this.selectedDestinations?.find(\n (d) =>\n d.id === destination.id ||\n (d.type === DestinationSearchItemType.COUNTRY && d.countryCode === destination.countryCode)\n )\n );\n }\n\n trackByFn(_index: number, item: DestinationSearchItem): string {\n return item.id;\n }\n\n /**\n * test if destination's attributes contain words that start with the given query\n */\n private destinationMatchesQuery(destination: DestinationSearchItem, query: string): boolean {\n // title that we test if it contains any of the queries.\n // Mark each word start with a space so that search “sin” doesn’t match “Helsinki”,\n // but we can match on every word start, including “Palma De Mallorca’s” Mallorca\n const t =\n ` ${destination.title} ${destination.normalizedTitle} ${destination.titleMaster} ${destination.normalizedTitleMaster}`.toLowerCase();\n\n return t.includes(` ${query?.toLowerCase()}`);\n }\n\n private recursiveMatchCheck(destination: DestinationSearchItem, query: string): boolean {\n const selfMatch = this.destinationMatchesQuery(destination, query);\n if (isNotEmpty(destination.items)) {\n destination.items.some((child) => this.recursiveMatchCheck(child, query));\n }\n\n return selfMatch;\n }\n\n private mapQueryMatches(destinations: DestinationSearchItem[], query: string): DestinationSearchItem[] {\n return destinations?.map((destination) => ({\n ...destination,\n items: this.mapQueryMatches(destination.items, query),\n matchesQuery: isBlank(query) || this.recursiveMatchCheck(destination, query),\n }));\n }\n\n private updateDestinationOptionsList(destinations: DestinationSearchItem[]): void {\n const query = this.destinationInput.value;\n this.matchingDestinations$.next(destinations);\n\n if (isNotBlank(query) && !this.optionsListVisible$.getValue()) {\n this.openOptionsList();\n }\n }\n\n private recursiveMapDestinationCount(destinations: DestinationSearchItem[]) {\n return destinations?.map((destination: DestinationSearchItem) => {\n if (isNotEmpty(destination.items)) {\n return {\n ...destination,\n items: [...this.recursiveMapDestinationCount(destination.items).sort(this.sortByAlphabetical)],\n count: this.mapDestinations(destination.items),\n };\n } else {\n return {\n ...destination,\n };\n }\n });\n }\n\n private mapDestinations(destinations: DestinationSearchItem[]): number {\n return destinations\n .map((value) => (isNotEmpty(value.items) ? this.mapDestinations(value.items) : 1))\n .reduce((acc, value) => acc + value, 0);\n }\n\n private sortByAlphabetical(a: DestinationSearchItem, b: DestinationSearchItem) {\n return a.title > b.title ? 1 : -1;\n }\n\n private mainFilters(destinations: DestinationSearchItem[]): DestinationSearchItem[] {\n const result: DestinationSearchItem[] = [];\n\n for (const destination of destinations) {\n if (destination.type === DestinationSearchItemType.CONTINENT && destination.titleMaster === 'Europe') {\n const finland = destination.items.find((item) => item.titleMaster === 'Finland');\n if (finland) {\n result.unshift(finland);\n }\n result.push({ ...destination, items: [...destination.items.filter((item) => item.titleMaster !== 'Finland')] });\n } else if (isNotEmpty(destination?.items)) {\n result.push(destination);\n }\n }\n\n return result.sort((a, b) => FILTERS_ORDER.indexOf(a.titleMaster) - FILTERS_ORDER.indexOf(b.titleMaster));\n }\n}\n","import { DestinationSearchBlockOffer } from 'src/modules/cms';\n\nexport const filterDestinations = (\n destinations: DestinationSearchBlockOffer[],\n showRoundTripPrice: boolean,\n maxPrice: number | undefined,\n showDirectFlightsOnly: boolean\n): DestinationSearchBlockOffer[] => {\n return (destinations ?? []).filter((destination) => {\n if (showDirectFlightsOnly && !destination.directFlight) {\n return false;\n }\n\n if (maxPrice !== undefined && maxPrice > 0) {\n return (\n parseInt(\n showRoundTripPrice\n ? destination.returnPrice?.price.amount\n : destination.isShortHaul\n ? destination.onewayPrice?.price.amount\n : destination.returnPrice?.price.amount,\n 10\n ) <= maxPrice\n );\n }\n return true;\n });\n};\n","@if (isMobile$ | async) {\n 0\"\n [buttonText]=\"'flightFilters.title' | finLocalization\"\n [notificationContent]=\"'flightFilters.modalNotification' | finLocalization\"\n [numberToShowWhenFiltered]=\"activeFilters$ | async\"\n [displayNotification]=\"(numberOfFilteredDestinations$ | async) === 0\"\n (showModal)=\"showModal()\"\n (closeModal)=\"closeModal()\"\n [modalTitle]=\"'destinationSearch.filters.title' | finLocalization\"\n (primaryFooterButtonClick)=\"closeModal()\"\n [primaryFooterButtonTitle]=\"\n 'destinationSearch.filters.showResults' | finLocalization: { results: (numberOfFilteredDestinations$ | async) }\n \"\n [secondaryFooterButtonTitle]=\"'destinationSearch.filters.clear' | finLocalization\"\n (secondaryFooterButtonClick)=\"resetAllFilters()\"\n [attr.data-testid]=\"'destination-search-filters-mobile'\"\n >\n \n
    \n
    \n @if ((selectedDestinations$ | async)?.length > 0) {\n \n
    \n
    \n \n @if ((selectedDestinations$ | async)?.length < 3) {\n {{\n 'destinationSearch.selectedDestination.' +\n ((selectedDestinations$ | async).length === 1 ? 'singular' : 'plural')\n | finLocalization: { total: (selectedDestinations$ | async).length }\n }}:\n {{ (selectedDestinations$ | async).join(', ') }}\n } @else {\n {{\n 'destinationSearch.selectedDestination.' +\n ((selectedDestinations$ | async).length === 1 ? 'singular' : 'plural')\n | finLocalization: { total: (selectedDestinations$ | async).length }\n }}\n }\n \n
    \n
    \n
    \n }\n @if (showStopFilters) {\n

    \n {{ 'destinationSearch.filters.stopsLabel' | finLocalization }}\n

    \n \n
    \n }\n

    \n {{ 'destinationSearch.filters.priceLabel' | finLocalization }}\n

    \n \n
    \n
    \n
    \n \n} @else {\n
    \n \n
    \n \n
    \n \n\n @if (showStopFilters) {\n \n
    \n \n
    \n \n }\n\n @if ((activeFilters$ | async) > 0) {\n
    \n \n \n
    \n }\n
    \n}\n\n\n
    \n {{ 'destinationSearch.filters.roundTrip' | finLocalization }}\n \n
    \n \n
    \n\n\n
    \n \n \n
    \n
    \n","import { ChangeDetectionStrategy, Component, EventEmitter, Input, OnDestroy, OnInit, Output } from '@angular/core';\nimport { FormControl, FormGroup } from '@angular/forms';\n\nimport { BehaviorSubject, combineLatest, map, Observable, of, startWith, Subscription } from 'rxjs';\nimport { Store } from '@ngrx/store';\nimport { SvgLibraryIcon } from '@finnairoyj/fcom-ui-styles/enums';\nimport { debounceTime, distinctUntilChanged, skip, take } from 'rxjs/operators';\n\nimport { ButtonTheme, IconPosition, InputType, PopoverOptions, PopoverService } from '@fcom/ui-components';\nimport { DestinationSearchFeatureState, DestinationSearchFilterStateMeta } from '@fcom/destination-search/interfaces';\nimport { FINNISH_SITES } from '@fcom/core';\nimport { ElementActions, ElementTypes, GaContext, MediaQueryService } from '@fcom/common';\nimport { DestinationSearchBlockOffer } from '@fcom/cms';\nimport { finShare } from '@fcom/rx';\nimport { GtmService } from '@fcom/common/gtm';\nimport { LanguageService } from '@fcom/ui-translate';\n\nimport {\n setMaxPrice,\n setShowDirectFlightsOnly,\n setRoundTripPrices,\n} from '../../store/actions/destination-search-filter.actions';\nimport { destinationsBeforeFilteringState, filterState, selectedDestinationsState } from '../../store';\nimport { filterDestinations } from '../../utils/filters';\n\nconst DESTINATION_FILTER_POPOVER_CONTEXT = 'destination-search-filters';\n\nconst DEFAULT_POPOVER_OPTIONS: PopoverOptions = {\n context: DESTINATION_FILTER_POPOVER_CONTEXT,\n zIndex: 20,\n};\n\nexport enum Stops {\n ALL_FLIGHTS = 'allFlights',\n DIRECT_FLIGHTS = 'directFlightsOnly',\n}\n\n@Component({\n selector: 'fin-destination-search-filters',\n templateUrl: 'destination-search-filters.component.html',\n styleUrls: ['destination-search-filters.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class DestinationSearchFiltersComponent implements OnInit, OnDestroy {\n readonly InputType = InputType;\n readonly IconPosition = IconPosition;\n readonly ButtonTheme = ButtonTheme;\n readonly SvgLibraryIcon = SvgLibraryIcon;\n readonly String = String;\n readonly Stops = Stops;\n\n @Input()\n sticky$: Observable;\n\n @Input()\n searchBarVisible$: Observable;\n\n @Input()\n meta: DestinationSearchFilterStateMeta;\n\n @Input()\n clearFilters$: Observable;\n\n @Output()\n mobileFiltersOpened = new EventEmitter();\n\n activeFilters$: Observable;\n priceInputForm: FormGroup<{ priceInput: FormControl; stops: FormControl }>;\n roundTripOnly$: BehaviorSubject = new BehaviorSubject(false);\n numberOfFilteredDestinations$: Observable;\n isMobile$: Observable;\n priceInputValue$: Observable = of(null);\n stopsInputvalue$: Observable = of(Stops.ALL_FLIGHTS);\n\n priceButtonLabelKey$: Observable;\n priceFilteringActive$: Observable;\n\n filteredDestinations$: Observable;\n hasShortHaulFlights$: Observable;\n\n selectedDestinations$: Observable;\n\n popoverOptions$: Observable = of(DEFAULT_POPOVER_OPTIONS);\n\n showStopFilters: boolean;\n\n isModalOpen: boolean;\n\n subscription = new Subscription();\n\n constructor(\n private store$: Store,\n private popoverService: PopoverService,\n private mediaQueryService: MediaQueryService,\n private gtmService: GtmService,\n private languageService: LanguageService\n ) {}\n\n ngOnInit(): void {\n this.isMobile$ = this.mediaQueryService.isBreakpoint$('mobile');\n\n this.subscription.add(\n this.store$\n .pipe(filterState(this.meta.id), take(1))\n .subscribe(({ maxPrice, roundTripPrices, showDirectFlightsOnly }) => {\n this.priceInputForm = new FormGroup({\n priceInput: new FormControl(maxPrice ? String(maxPrice) : null),\n stops: new FormControl(showDirectFlightsOnly ? Stops.DIRECT_FLIGHTS : Stops.ALL_FLIGHTS),\n });\n this.roundTripOnly$.next(roundTripPrices);\n })\n );\n\n this.stopsInputvalue$ = this.priceInputForm.controls.stops.valueChanges.pipe(\n startWith(this.priceInputForm.controls.stops.value)\n );\n\n this.priceInputValue$ = this.priceInputForm.controls.priceInput.valueChanges.pipe(\n startWith(this.priceInputForm.controls.priceInput.value),\n map((value) => (value ? parseInt(value, 10) : null))\n );\n\n this.priceFilteringActive$ = combineLatest([this.priceInputValue$, this.roundTripOnly$]).pipe(\n map(([maxPrice, roundTripOnly]) => maxPrice !== null || roundTripOnly)\n );\n\n this.priceButtonLabelKey$ = combineLatest([this.roundTripOnly$, this.priceInputValue$]).pipe(\n map(([roundTripOnly, maxPrice]) => {\n if (roundTripOnly && maxPrice !== null) {\n return 'destinationSearch.filters.priceFilterLabelRoundTripAndMaxPrice';\n }\n if (roundTripOnly) {\n return 'destinationSearch.filters.priceFilterRoundTrip';\n }\n if (maxPrice !== null) {\n return 'destinationSearch.filters.priceFilterMaxPrice';\n }\n return 'destinationSearch.filters.priceLabel';\n })\n );\n\n this.popoverOptions$ = this.sticky$.pipe(\n map((sticky) => ({\n ...DEFAULT_POPOVER_OPTIONS,\n useFixedPosition: sticky,\n }))\n );\n\n this.showStopFilters = FINNISH_SITES.includes(this.languageService.langValue);\n\n const destinationsBeforeFiltering$ = this.store$.pipe(\n destinationsBeforeFilteringState(this.meta.id),\n distinctUntilChanged(\n (prev, next) => next.length === prev.length && next.every((d, i) => d.locationCode === prev[i].locationCode)\n ),\n finShare()\n );\n\n this.filteredDestinations$ = combineLatest([\n destinationsBeforeFiltering$,\n this.priceInputValue$,\n this.stopsInputvalue$,\n this.roundTripOnly$,\n ]).pipe(\n map(([destinationsBeforeFiltering, maxPrice, stops, roundTripOnly]) =>\n filterDestinations(destinationsBeforeFiltering, roundTripOnly, maxPrice, stops === Stops.DIRECT_FLIGHTS)\n ),\n finShare()\n );\n\n this.numberOfFilteredDestinations$ = this.filteredDestinations$.pipe(\n map((destinations) => destinations.length ?? 0)\n );\n\n this.hasShortHaulFlights$ = destinationsBeforeFiltering$.pipe(\n map((destinations) => destinations.some((d) => d.isShortHaul))\n );\n\n this.activeFilters$ = combineLatest([this.priceInputValue$, this.roundTripOnly$, this.stopsInputvalue$]).pipe(\n map(\n ([maxPrice, roundTripOnly, stops]) =>\n [maxPrice !== null, roundTripOnly, stops === Stops.DIRECT_FLIGHTS].filter(Boolean).length\n )\n );\n\n this.selectedDestinations$ = this.store$.pipe(\n selectedDestinationsState(this.meta.id),\n map((destinations) => destinations.map((destination) => destination.title))\n );\n\n this.subscription.add(\n combineLatest([this.roundTripOnly$, this.hasShortHaulFlights$]).subscribe(\n ([roundTripOnly, hasShortHaulFlights]) => {\n this.store$.dispatch(\n setRoundTripPrices({ meta: this.meta, roundTripPrices: roundTripOnly || !hasShortHaulFlights })\n );\n }\n )\n );\n\n this.subscription.add(\n this.stopsInputvalue$.subscribe((stops) => {\n this.store$.dispatch(\n setShowDirectFlightsOnly({\n showDirectFlightsOnly: stops === Stops.DIRECT_FLIGHTS,\n meta: this.meta,\n })\n );\n })\n );\n\n this.subscription.add(\n this.priceInputValue$.pipe(debounceTime(500)).subscribe((value) => {\n this.store$.dispatch(setMaxPrice({ maxPrice: value, meta: this.meta }));\n })\n );\n\n this.subscription.add(\n this.isMobile$.subscribe((isMobile) => {\n if (!isMobile) {\n this.popoverService.closeByContext(DESTINATION_FILTER_POPOVER_CONTEXT);\n }\n })\n );\n\n this.subscription.add(\n this.sticky$.subscribe(() => {\n this.popoverService.closeByContext(DESTINATION_FILTER_POPOVER_CONTEXT);\n })\n );\n\n this.subscription.add(\n this.searchBarVisible$.subscribe((isVisible) => {\n if (!isVisible) {\n this.popoverService.closeByContext(DESTINATION_FILTER_POPOVER_CONTEXT);\n }\n })\n );\n\n this.subscription.add(\n this.clearFilters$.subscribe(() => {\n this.resetAllFilters();\n })\n );\n\n this.subscription.add(\n this.priceInputForm.controls.stops.valueChanges.pipe(debounceTime(1000)).subscribe((value) => {\n if (value === Stops.DIRECT_FLIGHTS) {\n this.gtmService.trackElement(\n 'custom-filter-select-direct-flights',\n GaContext.DESTINATION_MAIN_PAGE,\n ElementTypes.RADIO,\n 'select-filter-settings',\n ElementActions.CLICK\n );\n }\n })\n );\n\n this.subscription.add(\n this.priceInputForm.controls.priceInput.valueChanges.pipe(debounceTime(1000)).subscribe((value) => {\n const parsedValue = parseInt(value, 10);\n if (parsedValue > 0) {\n this.gtmService.trackElement(\n 'custom-filter-price-limit',\n GaContext.DESTINATION_MAIN_PAGE,\n ElementTypes.FORM,\n value,\n ElementActions.SUBMIT\n );\n }\n })\n );\n\n this.subscription.add(\n this.roundTripOnly$.pipe(skip(1), debounceTime(1000)).subscribe((value) => {\n if (value) {\n this.gtmService.trackElement(\n 'custom-filter-select-price-round-trip',\n GaContext.DESTINATION_MAIN_PAGE,\n ElementTypes.CHECKBOX,\n 'select-filter-settings',\n ElementActions.CLICK\n );\n }\n })\n );\n }\n\n ngOnDestroy(): void {\n this.subscription.unsubscribe();\n }\n\n showModal(): void {\n this.isModalOpen = true;\n this.mobileFiltersOpened.emit(true);\n this.gtmService.trackElement(\n 'custom-filters-open-all',\n GaContext.DESTINATION_MAIN_PAGE,\n ElementTypes.BUTTON,\n 'open-filter-settings',\n ElementActions.OPEN\n );\n }\n\n closeModal(): void {\n this.isModalOpen = false;\n this.mobileFiltersOpened.emit(false);\n }\n\n resetPriceFilters(): void {\n this.priceInputForm.controls.priceInput.setValue(null);\n this.roundTripOnly$.next(false);\n\n this.store$.dispatch(setMaxPrice({ maxPrice: null, meta: this.meta }));\n }\n\n resetStops(): void {\n this.priceInputForm.controls.stops.setValue(Stops.ALL_FLIGHTS);\n }\n\n resetAllFilters(): void {\n this.resetPriceFilters();\n this.resetStops();\n }\n\n closeFilters(): void {\n this.popoverService.closeByContext(DESTINATION_FILTER_POPOVER_CONTEXT);\n }\n\n priceFilterOpened(): void {\n this.gtmService.trackElement(\n 'custom-filter-open-price',\n GaContext.DESTINATION_MAIN_PAGE,\n ElementTypes.BUTTON,\n 'open-filter-settings',\n ElementActions.OPEN\n );\n }\n\n stopsFilterOpened(): void {\n this.gtmService.trackElement(\n 'custom-filter-open-direct-flights',\n GaContext.DESTINATION_MAIN_PAGE,\n ElementTypes.BUTTON,\n 'open-filter-settings',\n ElementActions.OPEN\n );\n }\n}\n","\n @if (backdropElement && (stickyEnabled$ | async)) {\n
    \n }\n \n 0,\n }\"\n >\n \n \n \n \n \n\n","import {\n Component,\n Input,\n OnDestroy,\n OnInit,\n PLATFORM_ID,\n Inject,\n ViewChild,\n ElementRef,\n AfterViewInit,\n Renderer2,\n ChangeDetectionStrategy,\n} from '@angular/core';\nimport { DOCUMENT, isPlatformServer } from '@angular/common';\nimport { animate, state, style, transition, trigger } from '@angular/animations';\n\nimport { BehaviorSubject, Observable, of, Subscription } from 'rxjs';\nimport { Store } from '@ngrx/store';\nimport { distinctUntilChanged, filter } from 'rxjs/operators';\n\nimport { unsubscribe, WindowRef } from '@fcom/core';\nimport { ButtonMode, ButtonSize, ButtonTheme, IconPosition } from '@fcom/ui-components';\nimport { ElementActions, ElementTypes, TestVariant, GaContext, ScrollService } from '@fcom/common';\nimport { GtmService } from '@fcom/common/gtm';\nimport { isPresent } from '@fcom/core/utils';\nimport {\n DestinationSearchFeatureState,\n DestinationSearchItem,\n DestinationSearchItemFilterSelection,\n FilterAction,\n DestinationSearchFilters,\n DestinationSearchFilterStateMeta,\n} from '@fcom/destination-search/interfaces';\nimport { TripType } from '@fcom/core/interfaces';\n\nimport { setSelectedDestinations } from '../../store/actions/destination-search-filter.actions';\n\nexport const STICKY_NAV_HEIGHT = 122;\nconst FINNAIR_EASE_IN = 'cubic-bezier(0.10, 0.25, 0.55, 1.00)';\nconst FINNAIR_EASE_OUT = 'cubic-bezier(0.55, 0.25, 0.55, 1.00)';\n\nenum ScrollState {\n SCROLLING_DOWN_BELOW_SEARCH_BAR,\n SCROLLING_UP_BELOW_SEARCH_BAR,\n SCROLLED_TO_SEARCH_BAR_TOP,\n SCROLLED_PAST_SEARCH_BAR_TOP,\n}\n\nexport enum ANIMATION_STATE {\n DEFAULT = 'default',\n HIDDEN = 'hidden',\n VISIBLE = 'visible',\n}\n\nconst TRANSFORM_VALUES = {\n [ANIMATION_STATE.DEFAULT]: 'translateY(0)',\n [ANIMATION_STATE.VISIBLE]: 'translateY(0)',\n [ANIMATION_STATE.HIDDEN]: 'translateY(-100%)',\n} as const;\n\n@Component({\n selector: 'fin-destination-search-form',\n templateUrl: 'destination-search-form.component.html',\n styleUrls: ['destination-search-form.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n animations: [\n trigger('scrollAnimation', [\n state(\n ANIMATION_STATE.HIDDEN,\n style({\n opacity: 0,\n transform: TRANSFORM_VALUES[ANIMATION_STATE.HIDDEN],\n })\n ),\n state(\n ANIMATION_STATE.VISIBLE,\n style({\n opacity: 1,\n transform: TRANSFORM_VALUES[ANIMATION_STATE.VISIBLE],\n })\n ),\n state(\n ANIMATION_STATE.DEFAULT,\n style({\n opacity: 1,\n transform: TRANSFORM_VALUES[ANIMATION_STATE.DEFAULT],\n })\n ),\n transition(`${ANIMATION_STATE.HIDDEN} => ${ANIMATION_STATE.VISIBLE}`, [animate(`0.5s ${FINNAIR_EASE_IN}`)]),\n transition(`${ANIMATION_STATE.VISIBLE} => ${ANIMATION_STATE.HIDDEN}`, [animate(`0.5s ${FINNAIR_EASE_OUT}`)]),\n transition(`${ANIMATION_STATE.DEFAULT} => ${ANIMATION_STATE.HIDDEN}`, [animate('0s')]),\n ]),\n ],\n})\nexport class DestinationSearchFormComponent implements OnInit, OnDestroy, AfterViewInit {\n readonly ANIMATION_STATE = ANIMATION_STATE;\n\n @Input()\n meta: DestinationSearchFilterStateMeta;\n\n @Input()\n initialDestinationSearchSelection$: Observable;\n\n @Input()\n allDestinations$: Observable;\n\n @Input()\n showFilters = true;\n\n @Input()\n clearFilters$: Observable;\n\n readonly IconPosition = IconPosition;\n readonly ButtonTheme = ButtonTheme;\n readonly ButtonMode = ButtonMode;\n readonly ButtonSize = ButtonSize;\n readonly TripType = TripType;\n readonly TestVariant = TestVariant;\n\n selectedTripType$: BehaviorSubject = new BehaviorSubject(undefined);\n selectedDestinations$: BehaviorSubject = new BehaviorSubject(undefined);\n subscription: Subscription = new Subscription();\n initialSelection$: Observable;\n currentScrollPosition: number;\n originSearchBarPosition: { top: number; bottom: number };\n stickyEnabled$: BehaviorSubject = new BehaviorSubject(false);\n\n backdropElement: HTMLElement | null = null;\n searchBarOptionListVisible$: BehaviorSubject = new BehaviorSubject(false);\n closeSearchBarOptionsList$: BehaviorSubject = new BehaviorSubject(undefined);\n isStickyNavTest$: Observable = of(false);\n state$: BehaviorSubject = new BehaviorSubject(ANIMATION_STATE.DEFAULT);\n @ViewChild('container')\n container: ElementRef;\n\n constructor(\n private gtmService: GtmService,\n private store$: Store,\n @Inject(PLATFORM_ID) private platform: object,\n private readonly renderer: Renderer2,\n private readonly windowRef: WindowRef,\n private scrollService: ScrollService,\n @Inject(DOCUMENT) private document: Document\n ) {}\n\n ngOnInit(): void {\n if (isPlatformServer(this.platform)) {\n return;\n }\n\n this.initialSelection$ = this.initialDestinationSearchSelection$;\n\n // Take initial tripType value\n this.subscription.add(\n this.initialSelection$.pipe(filter((state) => isPresent(state?.tripType))).subscribe((state) => {\n this.selectedTripType$.next(state.tripType);\n this.selectedDestinations$.next(state.selectedDestinations);\n })\n );\n\n this.currentScrollPosition = this.windowRef.nativeWindow.scrollY;\n }\n\n ngAfterViewInit(): void {\n if (this.showFilters) {\n this.originSearchBarPosition = {\n top: this.container.nativeElement.offsetTop - STICKY_NAV_HEIGHT,\n bottom: this.container.nativeElement.offsetTop - STICKY_NAV_HEIGHT + this.container.nativeElement.offsetHeight,\n };\n\n this.subscription.add(\n this.searchBarOptionListVisible$.subscribe((isVisible) => {\n if (isVisible) {\n this.addBackdrop();\n } else {\n this.removeBackdrop();\n }\n })\n );\n\n this.subscription.add(\n this.scrollService\n .listen(this.document.body)\n .pipe(filter(Boolean), distinctUntilChanged())\n .subscribe((event) => {\n const scrollTop = Math.abs(event.top);\n const scrollState = this.getScrollState(scrollTop);\n this.currentScrollPosition = scrollTop;\n this.updateScrollStateAndSticky(scrollState);\n })\n );\n }\n }\n\n ngOnDestroy(): void {\n this.subscription = unsubscribe(this.subscription);\n this.removeBackdrop();\n }\n\n /**\n * Called when the destinations are added or removed to/from filters\n */\n onFilterToValueChange({ action, destination, selectedDestinations }: DestinationSearchItemFilterSelection): void {\n const newSelectedDestinations = this.getSelectedDestinationsOnFilterChange({\n action,\n destination,\n selectedDestinations,\n });\n this.selectedDestinations$.next(newSelectedDestinations);\n this.store$.dispatch(setSelectedDestinations({ selectedDestinations: newSelectedDestinations, meta: this.meta }));\n\n const selectedDestinationsTrackingString = this.selectedDestinationsToTrackingString(newSelectedDestinations);\n this.gtmService.trackElement(\n selectedDestinationsTrackingString,\n GaContext.DESTINATION_MAIN_PAGE,\n ElementTypes.SEARCH,\n selectedDestinationsTrackingString,\n ElementActions.SEARCH\n );\n\n this.windowRef.nativeWindow.scrollTo({ top: this.originSearchBarPosition.top, behavior: 'smooth' });\n\n this.gtmService.trackElement(\n `${action}-filter`,\n GaContext.DESTINATION_MAIN_PAGE,\n ElementTypes.BUTTON,\n action === FilterAction.REMOVE_ALL || action === FilterAction.CUSTOM\n ? action\n : `${action}-${destination.titleMaster.replace(/ /g, '_')}`,\n ElementActions.CLICK\n );\n }\n\n onInputFilter($event: boolean): void {\n if ($event && this.currentScrollPosition < this.originSearchBarPosition?.bottom) {\n this.windowRef?.nativeWindow.scrollTo({ top: this.originSearchBarPosition?.top, behavior: 'smooth' });\n }\n }\n\n private getScrollState(scrollTop: number): ScrollState {\n const scrollingDown = scrollTop > this.currentScrollPosition;\n const belowSearchBarBottom = scrollTop > this.originSearchBarPosition.bottom;\n const currentScrollBelowSearchBarTop = this.currentScrollPosition > this.originSearchBarPosition.top;\n\n if (scrollingDown && belowSearchBarBottom) {\n return ScrollState.SCROLLING_DOWN_BELOW_SEARCH_BAR;\n }\n if (scrollingDown && scrollTop > this.originSearchBarPosition.top) {\n return ScrollState.SCROLLED_PAST_SEARCH_BAR_TOP;\n }\n if (!scrollingDown && scrollTop > this.originSearchBarPosition.top) {\n return ScrollState.SCROLLING_UP_BELOW_SEARCH_BAR;\n }\n if (!scrollingDown && scrollTop <= this.originSearchBarPosition.top && currentScrollBelowSearchBarTop) {\n return ScrollState.SCROLLED_TO_SEARCH_BAR_TOP;\n }\n }\n\n private updateScrollStateAndSticky(scrollState: ScrollState): void {\n switch (scrollState) {\n case ScrollState.SCROLLING_DOWN_BELOW_SEARCH_BAR:\n this.state$.next(ANIMATION_STATE.HIDDEN);\n this.closeSearchBarOptionsList$.next();\n break;\n case ScrollState.SCROLLED_PAST_SEARCH_BAR_TOP:\n this.closeSearchBarOptionsList$.next();\n this.stickyEnabled$.next(false);\n this.state$.next(ANIMATION_STATE.DEFAULT);\n break;\n case ScrollState.SCROLLING_UP_BELOW_SEARCH_BAR:\n if (this.stickyEnabled$.getValue() === false) {\n this.stickyEnabled$.next(true);\n }\n this.state$.next(ANIMATION_STATE.VISIBLE);\n break;\n case ScrollState.SCROLLED_TO_SEARCH_BAR_TOP:\n this.stickyEnabled$.next(false);\n this.state$.next(ANIMATION_STATE.DEFAULT);\n break;\n }\n }\n\n private addBackdrop(): void {\n if (this.backdropElement) {\n return;\n }\n\n const styles = {\n position: 'fixed',\n top: '0',\n left: '0',\n width: '100%',\n height: '100%',\n background: '#12121233',\n 'z-index': '4',\n };\n\n this.backdropElement = this.renderer.createElement('div');\n Object.entries(styles).forEach(([key, value]) => {\n this.renderer.setStyle(this.backdropElement, key, value);\n });\n\n this.renderer.appendChild(this.document.body, this.backdropElement);\n }\n\n private removeBackdrop(): void {\n if (this.backdropElement) {\n this.renderer.removeChild(this.document.body, this.backdropElement);\n this.backdropElement = null;\n }\n }\n\n private getSelectedDestinationsOnFilterChange({\n action,\n destination,\n selectedDestinations,\n }: DestinationSearchItemFilterSelection): DestinationSearchItem[] {\n if (action === FilterAction.ADD) {\n const alreadySelected = selectedDestinations.find((selected) => selected.id === destination.id);\n return alreadySelected ? selectedDestinations : [...selectedDestinations, destination];\n }\n if (action === FilterAction.REMOVE) {\n return selectedDestinations?.filter((selectedDestination) => selectedDestination.id !== destination.id);\n }\n if (action === FilterAction.REMOVE_ALL) {\n return [];\n }\n if (action === FilterAction.CUSTOM) {\n return selectedDestinations;\n }\n }\n\n private selectedDestinationsToTrackingString(selectedDestinations: DestinationSearchItem[]): string {\n return selectedDestinations?.length > 0\n ? selectedDestinations\n .map((destination: DestinationSearchItem) => {\n return `type:${destination.type}-title:${destination.titleMaster}`;\n })\n .join(',')\n : 'no-filters';\n }\n\n onOptionsListVisibilityChanged(visible: boolean): void {\n this.searchBarOptionListVisible$.next(visible);\n }\n\n // There is a bug where position: fixed wont work when the component that has the property\n // is inside an element with a transform property. In this case the modal has the fixed position\n onMobileFiltersOpened(isOpen: boolean): void {\n this.renderer.setStyle(\n this.container.nativeElement,\n 'transform',\n isOpen ? 'unset' : TRANSFORM_VALUES[this.state$.getValue()]\n );\n this.renderer.setStyle(this.container.nativeElement, 'z-index', isOpen ? '10' : '1');\n }\n}\n","
    \n \n
    \n","import { Component, Input } from '@angular/core';\n\n@Component({\n selector: 'fin-destination-search-header',\n templateUrl: './destination-search-header.component.html',\n})\nexport class DestinationSearchHeaderComponent {\n @Input()\n destinationTeaserText?: string;\n}\n","
    \n
    \n \n
    \n \n \n
    \n \n
    \n
    \n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\nimport { ActivatedRoute, Params, Router } from '@angular/router';\n\nimport { combineLatest, Observable, ReplaySubject, Subscription, Subject, of } from 'rxjs';\nimport { distinctUntilChanged, filter, map, skip, startWith, switchMap, take } from 'rxjs/operators';\nimport { Store } from '@ngrx/store';\n\nimport { LanguageService } from '@fcom/ui-translate';\nimport { CmsPage, CmsPlaceholder, CmsTemplate, PageViewType } from '@fcom/core-api';\nimport { GlobalBookingTravelClass } from '@fcom/core';\nimport { TripType } from '@fcom/core/interfaces';\nimport {\n entrySet,\n enumValues,\n equals,\n isEmptyObjectOrHasEmptyValues,\n isNotBlank,\n isPresent,\n unsubscribe,\n} from '@fcom/core/utils';\nimport { DestinationSearchBlockOffer } from '@fcom/cms/interfaces';\nimport { finShare } from '@fcom/rx';\nimport { DestinationSearchService } from '@fcom/destination-search/services/destination-search.service';\nimport {\n DestinationSearchFeatureState,\n DestinationSearchItem,\n DestinationSearchItemType,\n DestinationSearchQueryParamNames,\n DestinationSearchQueryParams,\n DestinationSearchViewStyle,\n DestinationSearchFilters,\n DestinationSearchFilterStateMeta,\n} from '@fcom/destination-search/interfaces';\nimport { findDestinationsForQueryParams, flattenDestinations } from '@fcom/destination-search/utils/flatten';\n\nimport {\n allFilterStates,\n defaultFilters,\n filterState,\n fromLocationCodeState,\n restrictToDestinationsState,\n} from '../../../store';\nimport { DestinationSearchOffersService } from '../../../services/destination-search-offers.service';\nimport {\n removeRouteUpdate,\n setDestinationsBeforeFiltering,\n setDestinationSearchSelection,\n} from '../../../store/actions/destination-search-filter.actions';\nimport { ORIGIN_SELECTOR_CONFIG } from '../../../constants';\nimport { filterDestinations } from '../../../utils/filters';\n\n@Component({\n selector: 'fin-destination-search',\n templateUrl: './destination-search.component.html',\n})\nexport class DestinationSearchPageComponent implements OnInit, OnDestroy {\n @Input()\n content: CmsPlaceholder;\n\n @Input()\n content$: Observable;\n\n @Input()\n template: CmsTemplate;\n\n viewStyle: DestinationSearchViewStyle = DestinationSearchViewStyle.TILES;\n\n /*\n * All possible destinations in a nested format\n */\n allDestinations$: Observable;\n subscription: Subscription = new Subscription();\n selectedOriginLocationCode$: Observable;\n identifier: string;\n meta: DestinationSearchFilterStateMeta;\n initialDestinationSearchSelection$: ReplaySubject = new ReplaySubject(1);\n filteredDestinations$: Observable;\n showFilters$: Observable;\n isFilterApplied$: Observable = of(false);\n static readonly ALLOWED_DESTINATIONS_COUNT = 6;\n isSearchBarPresent = false;\n destinationTeaserText: string;\n destinationSearchFilters$: Observable;\n clearFilters$: Subject = new Subject();\n\n constructor(\n private destinationSearchService: DestinationSearchService,\n private activatedRoute: ActivatedRoute,\n private destinationSearchOffersService: DestinationSearchOffersService,\n private store$: Store,\n private router: Router,\n private languageService: LanguageService\n ) {}\n\n ngOnInit(): void {\n this.identifier =\n this.content.contentId.toString() + this.content.modificationDate.toString() ??\n (Math.random() * 1000000000).toString();\n this.meta = { id: this.identifier };\n\n this.isFilterApplied$ = this.store$.pipe(\n filterState(this.meta.id),\n map(\n ({ selectedDestinations, maxPrice, showDirectFlightsOnly, roundTripPrices }) =>\n selectedDestinations?.length > 0 || maxPrice > 0 || showDirectFlightsOnly || roundTripPrices\n )\n );\n\n this.isSearchBarPresent = isPresent(this.content?.localSettings?.restrictToDestinations);\n\n const defaultOrigin$ = this.getDefaultOriginLocationCode();\n\n const restrictionsFromLocalSettings$ = defaultOrigin$.pipe(\n map((defaultOrigin) => this.getRestrictionParamsFromLocalSettings(this.content, defaultOrigin))\n );\n\n const restrictionParams$ = combineLatest([\n this.store$.pipe(\n restrictToDestinationsState(this.meta.id),\n distinctUntilChanged((prev, next) => equals(prev, next)),\n startWith([])\n ),\n restrictionsFromLocalSettings$,\n ]).pipe(\n map(([restrictToDestinations, restrictionsFromLocalSettings]) => ({\n ...restrictionsFromLocalSettings,\n destination:\n restrictToDestinations?.length > 0 ? restrictToDestinations : restrictionsFromLocalSettings.destination,\n }))\n );\n\n this.allDestinations$ = restrictionParams$.pipe(\n switchMap((restrictionParams) =>\n this.destinationSearchService.destinationSearch(restrictionParams).pipe(take(1), finShare())\n )\n );\n\n // Make initial selection on startup\n this.subscription.add(\n combineLatest([\n this.content$.pipe(map((content) => content?.localSettings)),\n this.store$.pipe(allFilterStates()).pipe(switchMap((states) => of(states[this.identifier]))),\n this.allDestinations$,\n this.activatedRoute.queryParams,\n ])\n .pipe(\n take(1),\n map(([localSettings, state, allDestinations, queryParams]): DestinationSearchFilters => {\n // TODO: Disable query parameters on campaign page where multiple destinations search components are used in the same page\n const disableQueryParamsAndState = !!localSettings?.restrictToDestinations?.destinationsByOrigin;\n const hasLocalSettingsSelections =\n localSettings?.selectedTravelClass || localSettings?.tripType || localSettings?.filteredDestinations;\n const supportedParams = Object.keys(queryParams).filter((key) =>\n enumValues(DestinationSearchQueryParams).includes(key as DestinationSearchQueryParams)\n );\n if (!disableQueryParamsAndState && supportedParams.length > 0) {\n return this.getQueryParamsSelection(allDestinations, state, queryParams);\n }\n\n if (!disableQueryParamsAndState && state) {\n return state;\n }\n\n if (hasLocalSettingsSelections) {\n return this.getLocalSettingsSelection(allDestinations, localSettings);\n }\n\n return defaultFilters;\n })\n )\n .subscribe((selection) => {\n this.store$.dispatch(setDestinationSearchSelection({ selection, meta: this.meta }));\n this.initialDestinationSearchSelection$.next(selection);\n })\n );\n\n // Track query param changes outside of this component\n this.subscription.add(\n combineLatest([this.allDestinations$, this.activatedRoute.queryParams.pipe(skip(1))])\n .pipe(\n filter(() => !this.router.getCurrentNavigation()?.extras?.state?.skipFilterSet),\n map(\n ([allDestinations, queryParams]): DestinationSearchFilters =>\n this.getQueryParamsSelection(allDestinations, undefined, queryParams)\n )\n )\n .subscribe((selection) => {\n this.store$.dispatch(\n setDestinationSearchSelection({ selection: { ...selection, skipRouteUpdate: true }, meta: this.meta })\n );\n this.initialDestinationSearchSelection$.next(selection);\n })\n );\n\n // Update query params when filters are updated after the initial render\n this.subscription.add(\n this.initialDestinationSearchSelection$\n .pipe(\n take(1),\n switchMap(() =>\n this.store$.pipe(\n filterState(this.meta.id),\n map((state) => {\n const { destinationsBeforeFiltering: _, ...rest } = state;\n return rest;\n }),\n distinctUntilChanged((prev, next) => equals(prev, next)),\n skip(1)\n )\n ),\n distinctUntilChanged(\n (prev, next) =>\n equals(prev.selectedDestinations, next.selectedDestinations) &&\n prev.tripType === next.tripType &&\n prev.travelClass === next.travelClass &&\n prev.maxPrice === next.maxPrice &&\n prev.showDirectFlightsOnly === next.showDirectFlightsOnly &&\n prev.roundTripPrices === next.roundTripPrices\n )\n )\n .subscribe((state: DestinationSearchFilters) => {\n if (!state.skipRouteUpdate) {\n this.updateQueryParamsFromSelectedDestinations(state);\n } else {\n this.store$.dispatch(removeRouteUpdate({ meta: this.meta }));\n }\n })\n );\n\n this.selectedOriginLocationCode$ = defaultOrigin$.pipe(\n switchMap((defaultOrigin) =>\n this.store$.pipe(\n fromLocationCodeState(this.meta.id),\n distinctUntilChanged((prev, next) => equals(prev, next)),\n startWith(defaultOrigin)\n )\n )\n );\n\n const destinationsWithOffers$ = combineLatest([this.selectedOriginLocationCode$, restrictionParams$]).pipe(\n distinctUntilChanged(),\n switchMap(([selectedOriginLocationCode, restrictionParams]) =>\n this.destinationSearchOffersService.getDestinationsWithOffers(\n restrictionParams,\n this.identifier,\n this.content,\n selectedOriginLocationCode\n )\n ),\n finShare()\n );\n\n this.destinationSearchFilters$ = this.store$.pipe(\n allFilterStates(),\n map((states) => states[this.identifier]),\n distinctUntilChanged(),\n finShare()\n );\n\n this.filteredDestinations$ = combineLatest([this.destinationSearchFilters$, destinationsWithOffers$]).pipe(\n map(([filters, destinations]) =>\n filterDestinations(destinations, filters.roundTripPrices, filters.maxPrice, filters.showDirectFlightsOnly)\n ),\n finShare()\n );\n\n this.showFilters$ = this.allDestinations$.pipe(\n distinctUntilChanged(),\n map(\n (destinations) =>\n flattenDestinations(destinations).filter((d) => d.type === DestinationSearchItemType.DESTINATION)?.length >\n DestinationSearchPageComponent.ALLOWED_DESTINATIONS_COUNT\n )\n );\n const headerItem = this.template?.header?.find(\n (header) => header?.viewTypeName === PageViewType.NO_GRID_FULL_WIDTH_PAGE_WITH_TITLE\n );\n this.destinationTeaserText = headerItem?.teaserText;\n\n this.subscription.add(\n destinationsWithOffers$.subscribe((destinations) => {\n this.store$.dispatch(\n setDestinationsBeforeFiltering({\n meta: this.meta,\n destinationsBeforeFiltering: destinations,\n })\n );\n })\n );\n }\n\n ngOnDestroy(): void {\n this.subscription = unsubscribe(this.subscription);\n }\n\n clearAllFilters(): void {\n this.clearFilters$.next();\n }\n\n private getSupportedQueryParamValues(queryParams: Params): DestinationSearchQueryParamNames {\n const paramKeys = enumValues(DestinationSearchQueryParams);\n return paramKeys.reduce((selections, key) => {\n const params: string | undefined = queryParams[key];\n return {\n ...selections,\n ...(isPresent(params) && { [key]: params.split(',').map((p) => decodeURI(p)) }), // Don't add a prop if missing from params\n };\n }, {});\n }\n\n private getDefaultOriginLocationCode(): Observable {\n return combineLatest([this.languageService.countryCode, this.activatedRoute.queryParams]).pipe(\n map(([countryCode, queryParams]) => {\n const originFromQuery = queryParams.origin?.toUpperCase();\n\n const customOrigins = Object.keys(\n this.content?.localSettings?.restrictToDestinations?.destinationsByOrigin || {}\n );\n\n if (customOrigins.length) {\n return originFromQuery && customOrigins.includes(originFromQuery) ? originFromQuery : customOrigins[0];\n }\n\n if (ORIGIN_SELECTOR_CONFIG[countryCode]?.length) {\n return originFromQuery && ORIGIN_SELECTOR_CONFIG[countryCode].includes(originFromQuery)\n ? originFromQuery\n : ORIGIN_SELECTOR_CONFIG[countryCode][0];\n }\n\n const cmsPageNode = this.template?.header?.[0];\n return (cmsPageNode as CmsPage)?.defaultOriginLocationCode ?? 'HEL';\n })\n );\n }\n\n private getQueryParamsSelection(\n destinations: DestinationSearchItem[],\n state: DestinationSearchFilters,\n params: Params\n ): DestinationSearchFilters {\n const queryParams = this.getSupportedQueryParamValues(params);\n const prefillTravelClass = GlobalBookingTravelClass[queryParams.cabin?.[0]?.toUpperCase()] ?? state?.travelClass;\n const prefillTripType = TripType[queryParams.type?.[0]?.toUpperCase()] ?? state?.tripType;\n const prefillSelectedDestinations = findDestinationsForQueryParams(destinations, {\n continent: queryParams.continent,\n country: queryParams.country,\n destination: queryParams.destination,\n });\n\n return {\n ...defaultFilters,\n ...(prefillTripType && { tripType: prefillTripType }),\n ...(prefillTravelClass && { travelClass: prefillTravelClass }),\n ...(prefillSelectedDestinations && { selectedDestinations: prefillSelectedDestinations }),\n ...(state?.tripDates && { tripDates: state?.tripDates }),\n ...(queryParams.maxPrice && { maxPrice: parseInt(queryParams.maxPrice[0], 10) }),\n ...(queryParams.directFlights && { showDirectFlightsOnly: queryParams.directFlights[0] === 'true' }),\n ...(queryParams.roundTripPrices && { roundTripPrices: queryParams.roundTripPrices[0] === 'true' }),\n };\n }\n\n private getLocalSettingsSelection(\n destinations: DestinationSearchItem[],\n localSettings: any\n ): DestinationSearchFilters {\n const prefillTravelClass = localSettings.selectedTravelClass\n ? GlobalBookingTravelClass[localSettings.selectedTravelClass.toUpperCase()]\n : undefined;\n const prefillTripType = localSettings.selectedTripType\n ? TripType[localSettings.selectedTripType.toUpperCase()]\n : undefined;\n const prefillSelectedDestinations = localSettings.filteredDestinations\n ? findDestinationsForQueryParams(destinations, localSettings.filteredDestinations)\n : undefined;\n\n return {\n ...defaultFilters,\n ...(prefillTripType && { tripType: prefillTripType }),\n ...(prefillTravelClass && { travelClass: prefillTravelClass }),\n ...(prefillSelectedDestinations && { selectedDestinations: prefillSelectedDestinations }),\n };\n }\n\n private getRestrictionParamsFromLocalSettings(\n content: CmsPlaceholder,\n defaultOrigin: string\n ): DestinationSearchQueryParamNames {\n const restrictToDestinationsRequest = content?.localSettings?.restrictToDestinations;\n const requestIsInSupportedFormat =\n restrictToDestinationsRequest &&\n !isEmptyObjectOrHasEmptyValues(restrictToDestinationsRequest) &&\n Object.keys(restrictToDestinationsRequest).every((key) => key.toUpperCase() in DestinationSearchItemType) &&\n (restrictToDestinationsRequest.continent ? Array.isArray(restrictToDestinationsRequest.continent) : true) &&\n (restrictToDestinationsRequest.destination ? Array.isArray(restrictToDestinationsRequest.destination) : true);\n return requestIsInSupportedFormat\n ? {\n continent: restrictToDestinationsRequest.continent,\n country: restrictToDestinationsRequest.country,\n destination:\n restrictToDestinationsRequest.destinationsByOrigin?.[defaultOrigin] ??\n restrictToDestinationsRequest.destination,\n }\n : {};\n }\n\n private updateQueryParamsFromSelectedDestinations(state: DestinationSearchFilters): void {\n const destinationsAsQueryParams = state.selectedDestinations?.reduce(\n (params: DestinationSearchQueryParamNames, destination) => {\n switch (destination.type) {\n case DestinationSearchItemType.DESTINATION:\n return {\n ...params,\n destination: [...params.destination, destination.locationCode],\n };\n case DestinationSearchItemType.COUNTRY:\n return {\n ...params,\n country: [...params.country, destination.countryCode],\n };\n case DestinationSearchItemType.CONTINENT:\n return {\n ...params,\n continent: [...params.continent, destination.titleMaster],\n };\n default:\n return params;\n }\n },\n {\n destination: [],\n country: [],\n continent: [],\n }\n );\n\n const destinationQueryParams: DestinationSearchQueryParamNames = entrySet(destinationsAsQueryParams).reduce(\n (allParams, param: { key: DestinationSearchQueryParams; value: string[] }) => {\n const paramString = param.value.join(',');\n return {\n ...allParams,\n // only add params for the types of destinations that are selected\n ...(isNotBlank(paramString) && { [param.key]: paramString }),\n };\n },\n\n {}\n );\n\n const queryParams: Params = {\n ...destinationQueryParams,\n type: state.tripType.toLowerCase(),\n cabin: state.travelClass.toLowerCase(),\n ...(state.maxPrice && { maxPrice: state.maxPrice }),\n ...(state.showDirectFlightsOnly && { directFlights: 'true' }),\n ...(state.roundTripPrices && { roundTripPrices: 'true' }),\n };\n\n if (!equals(queryParams, this.activatedRoute.snapshot.queryParams)) {\n this.router.navigate([], {\n queryParams,\n replaceUrl: true,\n state: { skipFilterSet: true },\n });\n }\n }\n}\n"],"x_google_ignoreList":[]}