UNPKG

ngx-fastcomments

Version:

This is an Angular library for FastComments, a live embedded commenting library.

33 lines (32 loc) 1.2 kB
import { ElementRef, OnChanges, OnInit } from '@angular/core'; import { FastCommentsCommentWidgetConfig } from 'fastcomments-typescript'; import * as i0 from "@angular/core"; declare enum LoadStatus { Started = 0, ScriptLoaded = 1, Done = 2, Error = 3 } interface FastCommentsState { status: LoadStatus; } interface WidgetInstance { destroy: () => void; update: (FastCommentsCommentWidgetConfig: any) => void; } export declare class FastCommentsComponent implements OnInit, OnChanges { config: FastCommentsCommentWidgetConfig; fastCommentsElement: ElementRef; lastWidgetInstance: WidgetInstance | null; state: FastCommentsState; constructor(); ngOnInit(): void | Promise<void>; ngOnChanges(): void; insertScript(src: string, id: string, parentElement: Element): Promise<unknown>; loadInstance(): Promise<void>; reset(): void; instantiateWidget(): void; static ɵfac: i0.ɵɵFactoryDeclaration<FastCommentsComponent, never>; static ɵcmp: i0.ɵɵComponentDeclaration<FastCommentsComponent, "lib-fastcomments", never, { "config": { "alias": "config"; "required": false; }; }, {}, never, never, false, never>; } export {};