import * as i0 from '@angular/core'; import { AfterViewInit, OnDestroy, TemplateRef, ElementRef, OnInit } from '@angular/core'; import { SafeHtml } from '@angular/platform-browser'; import { ControlValueAccessor, NgControl } from '@angular/forms'; import * as i1 from '@skyux/forms'; import { SkyRequiredStateDirective } from '@skyux/forms'; import { Subject } from 'rxjs'; import { SkyDropdownMessage } from '@skyux/popovers'; import { SkyColorpickerMessage, SkyColorpickerOutput } from '@skyux/colorpicker'; import { SkyTabIndex } from '@skyux/tabs'; declare class SkyRichTextDisplayComponent { #private; /** * The rich text to display. */ set richText(value: string | undefined); sanitizedText: SafeHtml; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } declare class SkyRichTextDisplayModule { static ɵfac: i0.ɵɵFactoryDeclaration; static ɵmod: i0.ɵɵNgModuleDeclaration; static ɵinj: i0.ɵɵInjectorDeclaration; } interface SkyTextEditorFont { /** * The display name of the font. */ name: string; /** * The CSS `font-family` value for the font. */ value: string; } type SkyTextEditorLinkWindowOptionsType = 'new' | 'existing'; type SkyTextEditorMenuType = 'edit' | 'format' | 'merge-field'; interface SkyTextEditorStyleState { /** * The background color. Accepts any CSS color value. */ backColor: string; /** * The font color. Accepts any CSS color value. */ fontColor: string; /** * The font size in pixels. */ fontSize: number; /** * The font family. Available values: `"Blackbaud Sans"`, * `"Arial"`, `"sans-serif"`, `"Arial Black"`, `"Courier New"`, and `"Times New Roman"`. */ font: string; /** * Whether to make text bold. */ boldState: boolean; /** * Whether to italicize text. */ italicState: boolean; /** * Whether to underline text. */ underlineState: boolean; /** * Whether to format text as a link. */ linkState: boolean; } interface SkyTextEditorMergeField { /** * The identifier for the merge field. */ id: string; /** * Display text for the merge field. If it is more than 18 characters, the component truncates to 15 characters. */ name: string; /** * The `src` attribute for a preview image to represent the merge field * in the text editor. By default, the `name` value appears in a blue rectangle. */ previewImageUrl?: string; } type SkyTextEditorToolbarActionType = 'font-family' | 'font-size' | 'font-style' | 'color' | 'list' | 'alignment' | 'indentation' | 'undo-redo' | 'link'; /** * The text editor component lets users format and manipulate text. */ declare class SkyTextEditorComponent implements AfterViewInit, OnDestroy, ControlValueAccessor { #private; /** * Whether to put focus on the editor after it renders. */ autofocus: boolean | undefined; /** * Whether to disable the text editor on template-driven forms. Don't use this input on reactive forms because they may overwrite the input or leave the control out of sync. * To set the disabled state on reactive forms, use the `FormControl` instead. * @default false */ set disabled(value: boolean); get disabled(): boolean; /** * The fonts to include in the font picker. * @default [{name: 'Blackbaud Sans', value: '"Blackbaud Sans", Arial, sans-serif'}, {name: 'Arial', value: 'Arial'}, {name: 'Arial Black', value: '"Arial Black"'}, {name: 'Courier New', value: '"Courier New"'}, {name: 'Georgia', value: 'Georgia, serif'}, {name: 'Tahoma', value: 'Tahoma, Geneva, sans-serif'}, {name: 'Times New Roman', value: '"Times New Roman"'}, {name: 'Trebuchet MS', value: '"Trebuchet MS", sans-serif'}, {name: 'Verdana', value: 'Verdana, Geneva, sans-serif'}] */ set fontList(value: SkyTextEditorFont[] | undefined); get fontList(): SkyTextEditorFont[]; /** * The font sizes to include in the font size picker. * @default [6, 8, 9, 10, 11, 12, 13, 14, 15, 16, 18, 20, 22, 24, 26, 28, 36, 48] */ set fontSizeList(value: number[] | undefined); get fontSizeList(): number[]; /** * The content of the help popover. When specified along with `labelText`, a [help inline](https://developer.blackbaud.com/skyux/components/help-inline) * button is added to the text editor. The help inline button displays a [popover](https://developer.blackbaud.com/skyux/components/popover) * when clicked using the specified content and optional title. This property only applies when `labelText` is also specified. */ helpPopoverContent: string | TemplateRef | undefined; /** * The title of the help popover. This property only applies when `helpPopoverContent` is * also specified. */ helpPopoverTitle: string | undefined; /** * [Persistent inline help text](https://developer.blackbaud.com/skyux/design/guidelines/user-assistance#inline-help) that provides * additional context to the user. */ hintText: string | undefined; /** * The unique ID attribute for the text editor. * By default, the component generates a random ID. */ set id(value: string | undefined); get id(): string; /** * The initial styles for all content, including background color, font size, and link state. */ set initialStyleState(state: SkyTextEditorStyleState | undefined); get initialStyleState(): SkyTextEditorStyleState; /** * The text to display as the text editor's label. */ set labelText(value: string | undefined); get labelText(): string | undefined; /** * The menus to include in the menu bar. * @default [ 'edit', 'format' ] */ set menus(value: SkyTextEditorMenuType[] | undefined); get menus(): SkyTextEditorMenuType[]; /** * The merge fields to include in the merge field menu. */ set mergeFields(value: SkyTextEditorMergeField[] | undefined); get mergeFields(): SkyTextEditorMergeField[]; /** * Placeholder text to display when the text entry area is empty. */ set placeholder(value: string | undefined); get placeholder(): string; /** * Whether the text editor is stacked on another form component. When specified, * the appropriate vertical spacing is automatically added to the text editor. */ stacked: boolean; /** * The actions to include in the toolbar in the specified order. * @default [ 'font-family', 'font-size', 'font-style', 'color', 'list', 'link ] */ set toolbarActions(value: SkyTextEditorToolbarActionType[] | undefined); get toolbarActions(): SkyTextEditorToolbarActionType[]; /** * The target window options for adding a hyperlink. * @default [ 'new', 'existing' ] */ set linkWindowOptions(value: SkyTextEditorLinkWindowOptionsType[] | undefined); get linkWindowOptions(): SkyTextEditorLinkWindowOptionsType[]; /** * A help key that identifies the global help content to display. When specified along with `labelText`, a [help inline](https://developer.blackbaud.com/skyux/components/help-inline) * button is placed beside the text editor label. Clicking the button invokes [global help](https://developer.blackbaud.com/skyux/learn/develop/global-help) * as configured by the application. This property only applies when `labelText` is also specified. */ helpKey: string | undefined; iframeRef: ElementRef | undefined; /** * The internal value of the control. */ set value(value: string | undefined); get value(): string; inputTemplateRef: TemplateRef | undefined; editorFocusStream: Subject; formControlClass: boolean; protected editorFocused: boolean; protected readonly errorId: string; protected readonly ngControl: NgControl; protected readonly requiredState: SkyRequiredStateDirective; constructor(); ngAfterViewInit(): void; ngOnDestroy(): void; onIframeLoad(): void; /** * Implemented as part of ControlValueAccessor. */ writeValue(value: string): void; /** * Implemented as part of ControlValueAccessor. */ registerOnChange(fn: (value: any) => void): void; /** * Implemented as part of ControlValueAccessor. */ registerOnTouched(fn: () => void): void; /** * Implemented as part of ControlValueAccessor. */ setDisabledState(isDisabled: boolean): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; static ngAcceptInputType_disabled: unknown; static ngAcceptInputType_stacked: unknown; } declare class SkyTextEditorModule { static ɵfac: i0.ɵɵFactoryDeclaration; static ɵmod: i0.ɵɵNgModuleDeclaration; static ɵinj: i0.ɵɵInjectorDeclaration; } /** * @internal */ declare class SkyTextEditorMenubarComponent implements OnDestroy, OnInit { #private; editorFocusStream: Subject; menus: SkyTextEditorMenuType[]; mergeFields: SkyTextEditorMergeField[]; disabled: boolean; editDropdownStream: Subject; editItems: { function?: () => void; isDivider?: boolean; label?: string; keyShortcut?: string; }[] | undefined; formatDropdownStream: Subject; formatItems: { function?: () => void; isDivider?: boolean; label?: string; keyShortcut?: string; }[] | undefined; mergeFieldDropdownStream: Subject; ngOnInit(): void; ngOnDestroy(): void; execCommand(command: string, value?: string): void; insertMergeField(field: SkyTextEditorMergeField): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; static ngAcceptInputType_disabled: unknown; } /** * @internal */ declare class SkyTextEditorToolbarComponent implements OnInit { #private; set editorFocusStream(value: Subject); get editorFocusStream(): Subject; fontList: SkyTextEditorFont[]; fontSizeList: number[]; toolbarActions: SkyTextEditorToolbarActionType[]; linkWindowOptions: SkyTextEditorLinkWindowOptionsType[]; set styleState(value: SkyTextEditorStyleState); get styleState(): SkyTextEditorStyleState; disabled: boolean; backColorpickerStream: Subject; colorpickerStream: Subject; fontPickerStream: Subject; fontSizeStream: Subject; styleStateFontName: string | undefined; ngOnInit(): void; execCommand(command: string, value?: string): void; toggleFontStyle(currentState: boolean, newState: boolean, command: string): void; link(): void; unlink(): void; changeFontSize(size: number): void; onColorpickerColorChanged(color: SkyColorpickerOutput, isBackground?: boolean): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; static ngAcceptInputType_disabled: unknown; } /** * @internal */ declare class SkyTextEditorUrlModalComponent { #private; set activeTab(value: number); get activeTab(): number; set emailAddress(value: string); get emailAddress(): string; set url(value: string); get url(): string; emailAddressValid: boolean; allowAllOpenLinkOptions: boolean; openLinksInNewWindowOnly: boolean; subject: string; target: number | string; valid: boolean; constructor(); activeTabChanged(value: SkyTabIndex): void; save(): void; cancel(): void; static ɵfac: i0.ɵɵFactoryDeclaration; static ɵcmp: i0.ɵɵComponentDeclaration; } export { SkyRichTextDisplayModule, SkyTextEditorModule, SkyRichTextDisplayComponent as λ1, SkyTextEditorMenubarComponent as λ2, SkyTextEditorUrlModalComponent as λ3, SkyTextEditorToolbarComponent as λ4, SkyTextEditorComponent as λ5 }; export type { SkyTextEditorFont, SkyTextEditorLinkWindowOptionsType, SkyTextEditorMenuType, SkyTextEditorMergeField, SkyTextEditorStyleState, SkyTextEditorToolbarActionType };