UNPKG

@dotcms/angular

Version:

Official Angular Components library to render a dotCMS page.

49 lines 1.61 kB
import { Observable } from 'rxjs'; import { DotCMSPageComponent, DotCMSPageContext } from '../../models'; import { DotCMSPageAsset } from '../../models/dotcms.model'; import * as i0 from "@angular/core"; /** * @author dotCMS * @description This service is responsible for managing the page context. * @export * @class PageContextService */ export declare class PageContextService { private context$; /** * @description Get the context * @readonly * @type {DotCMSPageContext} * @memberof PageContextService */ get context(): DotCMSPageContext; /** * @description Get the context as an observable * @readonly * @memberof PageContextService */ get contextObs$(): Observable<DotCMSPageContext | null>; /** * @description Get the current page asset * @readonly * @type {(Observable<DotCMSPageAsset | null>)} * @memberof PageContextService */ get currentPage$(): Observable<DotCMSPageAsset | null>; /** * * @description Set the context * @param {DotCMSPageAsset} value * @memberof DotcmsContextService */ setContext(pageAsset: DotCMSPageAsset, components: DotCMSPageComponent): void; /** * @description Set the page asset in the context * @param {DotCMSPageAsset} pageAsset * @memberof PageContextService */ setPageAsset(pageAsset: DotCMSPageAsset): void; static ɵfac: i0.ɵɵFactoryDeclaration<PageContextService, never>; static ɵprov: i0.ɵɵInjectableDeclaration<PageContextService>; } //# sourceMappingURL=page-context.service.d.ts.map