import { HttpClient } from '@angular/common/http'; import { EventEmitter } from '@angular/core'; import { Observable, Subject } from 'rxjs'; import { Page } from '../classes/page'; import { Collection, PredictiveSearchProductItem, Product } from '../classes/product'; import { Drawer, Menu, Modal } from '../classes/utility'; import { LifeCycleService } from './lifecycle.service'; import { XHRHTTPService } from './xhrhttp.service'; import * as i0 from "@angular/core"; export declare class TemplateService { private config; private lifecycleService; private xhrhttpService; private http; drawer: EventEmitter; modal: EventEmitter; lightbox: EventEmitter; menu: EventEmitter; search: EventEmitter; frontpageSubject: Subject; frontpage: Observable; templateVariables: any; store: any; predictiveSearch: any; constructor(config: any, lifecycleService: LifeCycleService, xhrhttpService: XHRHTTPService, http: HttpClient); jsonParser(x: any): any; /** * * @emits TemplateService.drawer.emit(Drawer) * @memberof TemplateService */ showDrawer(drawer: Drawer): void; /** * * @emits TemplateService.drawer.emit({ type: 'close' }) * @memberof TemplateService */ hideDrawer(): void; /** * * @emits TemplateService.modal.emit(modal) * @memberof TemplateService */ showModal(modal: Modal): void; /** * * @emits TemplateService.modal.emit({ type: 'close' }) * @memberof TemplateService */ hideModal(): void; /** * * @description open the lightbox to the nth image * @memberof TemplateService */ showLightbox(number?: number): void; /** * * @description close the lightbox * @memberof TemplateService */ hideLightbox(): void; /** * * @description emit the menu to whatever state true or false * @memberof TemplateService */ toggleMenu(state: boolean): void; getHeader(): Observable; getFrontPage(): Observable; quickParse(url: any): any; getPage(page: string, title?: boolean): Observable; getPagePage(page: string, title?: boolean): Observable; /** * * * @description returns a product object, or navigates to the 404 page if the product cannot be found, * @file templates/product.liquid -> json-product.liquid * @memberof TemplateService */ getProductPage(handle: string, title?: boolean): Observable; /** * * * @description returns a product object, does not navigate to 404 page if the product cannot be found * @file templates/product.liquid -> json-product.liquid * @memberof TemplateService */ getProduct(handle: string, title?: boolean): Observable; /** * * * @description returns a collection object, or navigates to the 404 page if the collection cannot be found, * @file templates/collection.liquid * @memberof TemplateService */ getCollectionsPage(page?: string, title?: boolean): Observable; /** * * * @description returns a collection object, does not navigate to 404 page if the collection cannot be found * @file templates/collection.liquid * @memberof TemplateService */ getCollections(page?: string, title?: boolean): Observable; getBlogPage(blog?: string, title?: boolean): Observable; getBlogsPage(category: string, page?: string, title?: boolean): Observable; getCollectionPage(collection: string, page?: string, title?: boolean): Observable; getCollection(collection: string, page?: string, title?: boolean): Observable; getVendorCollectionPage(vendor: string, page?: string, title?: boolean): Observable; getProductTypeCollectionPage(type: string, page?: string, title?: boolean): Observable; getSearchResults(search: any, resources?: string[], limit?: number, fields?: string[], title?: boolean): Observable; getInstagramFeed(accessToken: string, posts?: string): Observable; getInstagramFeedSearchEndpoint(context: 'blended' | 'user' | 'place' | 'hashtag', query: any): Observable; getCachedProduct(productHandle: any, title?: boolean): Promise; addToRecentlyViewedProducts(handle: string): boolean; getRecentlyViewedProducts(numberOfResults?: number, handle?: string): Promise; removeFromRecentlyViewedProducts(handle: string): boolean; getRecommendationsByProductId(productId: number | string, limit: number | string): Observable; submitForm(form: any, formId?: string): Observable; escapedQueryStringToJSON(entry: any): any; createRouterlinkFromString(routerLink: any): { params: string; baseUrl: string; }; createRouterLinkFromLinkList(linkList: any): any; /** * * * @description parses a link_list object and splits the corresponding url into a URL & a Params Object, * this allows shopify to set query strings in the menu links if so required in a routerlink [router] * @example [routerLink]="[ baseUrl, params ] * @memberof TemplateService */ processMenu(menu: any): Menu; unescapeHtml(unsafe: any): any; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵprov: i0.ɵɵInjectableDeclaration; } //# sourceMappingURL=template.service.d.ts.map