UNPKG

raonkeditor-angular

Version:

Angular component for RAON K Editor.

127 lines (126 loc) 4.68 kB
/** * @license Copyright (c) 2003-2022, RAONWIZ DevTeam. All rights reserved. */ import { NgZone, EventEmitter, ElementRef, AfterViewInit, OnDestroy } from '@angular/core'; import { ControlValueAccessor } from '@angular/forms'; import { RaonkEditor } from './raonkeditor'; export declare class RaonkEditorComponent implements AfterViewInit, OnDestroy, ControlValueAccessor { private elementRef; private ngZone; /** * The id of the component */ id: string; /** * The configuration of the component. */ config?: RaonkEditor.Config; /** * The component type */ componentType: string; /** * RAON K Editor script url address. Script will be loaded only if RAONKEDITOR namespace is missing. */ componentUrl: string; /** * Tag name of the component. * * The default tag is `div`. */ tagName: string; /** * The runtimes of the component interface. */ runtimes: RaonkEditor.Runtimes; /** * Keeps track of the component's data. * * It's also decorated as an input which is useful when not using the ngModel. * * See https://angular.io/api/forms/NgModel to learn more. */ set data(data: string); get data(): string; /** * When set to `true`, the editor becomes readonly mode. */ set readOnly(isReadOnly: boolean); get readOnly(): boolean; /** * When set to `true`, the editor becomes view mode. */ set viewMode(isViewMode: boolean); get viewMode(): boolean; /** * Fired when the component namespace * is loaded. It only triggers once, no matter how many components are initialised. */ namespaceLoaded: EventEmitter<RaonkEditor.EventInfo>; change: EventEmitter<RaonkEditor.EventInfo>; /** * event. */ creationComplete: EventEmitter<RaonkEditor.EventInfo>; afterChangeMode: EventEmitter<RaonkEditor.EventInfo>; onError: EventEmitter<RaonkEditor.EventInfo>; onLanguageDefinition: EventEmitter<RaonkEditor.EventInfo>; afterPopupShow: EventEmitter<RaonkEditor.EventInfo>; agentInstall: EventEmitter<RaonkEditor.EventInfo>; beforeInsertUrl: EventEmitter<RaonkEditor.EventInfo>; mouse: EventEmitter<RaonkEditor.EventInfo>; command: EventEmitter<RaonkEditor.EventInfo>; key: EventEmitter<RaonkEditor.EventInfo>; resized: EventEmitter<RaonkEditor.EventInfo>; documentEditComplete: EventEmitter<RaonkEditor.EventInfo>; pasteImage: EventEmitter<RaonkEditor.EventInfo>; wordCount: EventEmitter<RaonkEditor.EventInfo>; beforePaste: EventEmitter<RaonkEditor.EventInfo>; customAction: EventEmitter<RaonkEditor.EventInfo>; fullScreen: EventEmitter<RaonkEditor.EventInfo>; setComplete: EventEmitter<RaonkEditor.EventInfo>; setInsertComplete: EventEmitter<RaonkEditor.EventInfo>; closeInstallPopup: EventEmitter<RaonkEditor.EventInfo>; setForbiddenWordComplete: EventEmitter<RaonkEditor.EventInfo>; drag: EventEmitter<RaonkEditor.EventInfo>; focus: EventEmitter<RaonkEditor.EventInfo>; dialogLoaded: EventEmitter<RaonkEditor.EventInfo>; beforeInsertHyperlink: EventEmitter<RaonkEditor.EventInfo>; /** * A callback executed when the content of the component changes. Part of the * `ControlValueAccessor` (https://angular.io/api/forms/ControlValueAccessor) interface. * * Note: Unset unless the component uses the `ngModel`. */ onChange?: (data: string) => void; /** * A callback executed when the component has been blurred. Part of the * `ControlValueAccessor` (https://angular.io/api/forms/ControlValueAccessor) interface. * * Note: Unset unless the component uses the `ngModel`. */ onTouched?: () => void; /** * The instance of the component created. */ instance: any; /** * If the component is view-mode before the component instance is created, it remembers that state, * so the component can become view-mode once it is ready. */ private _readOnly; private _viewMode; private _data; private _destroyed; constructor(elementRef: ElementRef, ngZone: NgZone); ngAfterViewInit(): void; ngOnDestroy(): void; writeValue(value: string): void; registerOnChange(callback: (data: string) => void): void; registerOnTouched(callback: () => void): void; private getComponentUniqueName; private createComponent; private subscribe; private capitalize; private propagateChange; }