@flogeez/angular-tiptap-editor 2.1.1 → 2.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +17 -0
- package/README.md +16 -53
- package/fesm2022/flogeez-angular-tiptap-editor.mjs +1719 -1739
- package/fesm2022/flogeez-angular-tiptap-editor.mjs.map +1 -1
- package/index.d.ts +12 -11
- package/package.json +1 -1
- package/src/lib/styles/bubble-menu.global.css +0 -1
- package/src/lib/styles/material-symbols.css +5 -1
package/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as _flogeez_angular_tiptap_editor from '@flogeez/angular-tiptap-editor';
|
|
2
2
|
import * as _angular_core from '@angular/core';
|
|
3
3
|
import { AfterViewInit, OnDestroy, ElementRef } from '@angular/core';
|
|
4
|
-
import { Editor, Node, Mark, Extension, EditorOptions } from '@tiptap/core';
|
|
4
|
+
import { Editor, Node, Mark, Extension, EditorOptions, JSONContent } from '@tiptap/core';
|
|
5
5
|
import { Observable } from 'rxjs';
|
|
6
6
|
import { ControlValueAccessor } from '@angular/forms';
|
|
7
7
|
|
|
@@ -421,7 +421,7 @@ interface EditorStateSnapshot {
|
|
|
421
421
|
* Detailed selection information to avoid overlap between menus
|
|
422
422
|
*/
|
|
423
423
|
selection: {
|
|
424
|
-
type:
|
|
424
|
+
type: "text" | "node" | "cell" | "none";
|
|
425
425
|
from: number;
|
|
426
426
|
to: number;
|
|
427
427
|
empty: boolean;
|
|
@@ -515,7 +515,7 @@ interface EditorStateSnapshot {
|
|
|
515
515
|
activeNodeName: string | null;
|
|
516
516
|
};
|
|
517
517
|
/** Placeholder for custom extension states */
|
|
518
|
-
custom: Record<string,
|
|
518
|
+
custom: Record<string, unknown>;
|
|
519
519
|
}
|
|
520
520
|
declare const INITIAL_EDITOR_STATE: EditorStateSnapshot;
|
|
521
521
|
|
|
@@ -650,7 +650,7 @@ declare class EditorCommandsService {
|
|
|
650
650
|
/** Reference to the element that triggered the color menu (for anchoring) */
|
|
651
651
|
readonly colorMenuTrigger: _angular_core.Signal<HTMLElement | null>;
|
|
652
652
|
/** Generic method to execute any command by name */
|
|
653
|
-
execute(editor: Editor, command: string, ...args:
|
|
653
|
+
execute(editor: Editor, command: string, ...args: unknown[]): void;
|
|
654
654
|
toggleBold(editor: Editor): void;
|
|
655
655
|
toggleItalic(editor: Editor): void;
|
|
656
656
|
toggleStrike(editor: Editor): void;
|
|
@@ -875,9 +875,9 @@ interface AteEditorConfig {
|
|
|
875
875
|
}
|
|
876
876
|
|
|
877
877
|
declare class NoopValueAccessorDirective implements ControlValueAccessor {
|
|
878
|
-
writeValue(
|
|
879
|
-
registerOnChange(
|
|
880
|
-
registerOnTouched(
|
|
878
|
+
writeValue(_obj: unknown): void;
|
|
879
|
+
registerOnChange(_fn: unknown): void;
|
|
880
|
+
registerOnTouched(_fn: unknown): void;
|
|
881
881
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<NoopValueAccessorDirective, never>;
|
|
882
882
|
static ɵdir: _angular_core.ɵɵDirectiveDeclaration<NoopValueAccessorDirective, never, never, {}, {}, never, never, true, never>;
|
|
883
883
|
}
|
|
@@ -948,7 +948,7 @@ declare class AngularTiptapEditorComponent implements AfterViewInit, OnDestroy {
|
|
|
948
948
|
editorCreated: _angular_core.OutputEmitterRef<Editor>;
|
|
949
949
|
editorUpdate: _angular_core.OutputEmitterRef<{
|
|
950
950
|
editor: Editor;
|
|
951
|
-
transaction:
|
|
951
|
+
transaction: unknown;
|
|
952
952
|
}>;
|
|
953
953
|
editorFocus: _angular_core.OutputEmitterRef<{
|
|
954
954
|
editor: Editor;
|
|
@@ -978,6 +978,7 @@ declare class AngularTiptapEditorComponent implements AfterViewInit, OnDestroy {
|
|
|
978
978
|
readonly mergedDisabled: _angular_core.Signal<boolean>;
|
|
979
979
|
isEditorReady: _angular_core.Signal<boolean>;
|
|
980
980
|
readonly finalSeamless: _angular_core.Signal<boolean>;
|
|
981
|
+
readonly finalEditable: _angular_core.Signal<boolean>;
|
|
981
982
|
readonly finalPlaceholder: _angular_core.Signal<string>;
|
|
982
983
|
readonly finalFillContainer: _angular_core.Signal<boolean>;
|
|
983
984
|
readonly finalShowFooter: _angular_core.Signal<boolean>;
|
|
@@ -1034,7 +1035,7 @@ declare class AngularTiptapEditorComponent implements AfterViewInit, OnDestroy {
|
|
|
1034
1035
|
onDrop(event: DragEvent): void;
|
|
1035
1036
|
private insertImageFromFile;
|
|
1036
1037
|
getHTML(): string;
|
|
1037
|
-
getJSON():
|
|
1038
|
+
getJSON(): JSONContent | undefined;
|
|
1038
1039
|
getText(): string;
|
|
1039
1040
|
setContent(content: string, emitUpdate?: boolean): void;
|
|
1040
1041
|
focus(): void;
|
|
@@ -1042,7 +1043,7 @@ declare class AngularTiptapEditorComponent implements AfterViewInit, OnDestroy {
|
|
|
1042
1043
|
clearContent(): void;
|
|
1043
1044
|
getEditor(): Editor | null;
|
|
1044
1045
|
private setupFormControlSubscription;
|
|
1045
|
-
onEditorClick(event:
|
|
1046
|
+
onEditorClick(event: Event): void;
|
|
1046
1047
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<AngularTiptapEditorComponent, never>;
|
|
1047
1048
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<AngularTiptapEditorComponent, "angular-tiptap-editor", never, { "config": { "alias": "config"; "required": false; "isSignal": true; }; "content": { "alias": "content"; "required": false; "isSignal": true; }; "placeholder": { "alias": "placeholder"; "required": false; "isSignal": true; }; "editable": { "alias": "editable"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "minHeight": { "alias": "minHeight"; "required": false; "isSignal": true; }; "height": { "alias": "height"; "required": false; "isSignal": true; }; "maxHeight": { "alias": "maxHeight"; "required": false; "isSignal": true; }; "fillContainer": { "alias": "fillContainer"; "required": false; "isSignal": true; }; "showToolbar": { "alias": "showToolbar"; "required": false; "isSignal": true; }; "showFooter": { "alias": "showFooter"; "required": false; "isSignal": true; }; "showCharacterCount": { "alias": "showCharacterCount"; "required": false; "isSignal": true; }; "showWordCount": { "alias": "showWordCount"; "required": false; "isSignal": true; }; "maxCharacters": { "alias": "maxCharacters"; "required": false; "isSignal": true; }; "enableOfficePaste": { "alias": "enableOfficePaste"; "required": false; "isSignal": true; }; "enableSlashCommands": { "alias": "enableSlashCommands"; "required": false; "isSignal": true; }; "slashCommands": { "alias": "slashCommands"; "required": false; "isSignal": true; }; "customSlashCommands": { "alias": "customSlashCommands"; "required": false; "isSignal": true; }; "locale": { "alias": "locale"; "required": false; "isSignal": true; }; "autofocus": { "alias": "autofocus"; "required": false; "isSignal": true; }; "seamless": { "alias": "seamless"; "required": false; "isSignal": true; }; "floatingToolbar": { "alias": "floatingToolbar"; "required": false; "isSignal": true; }; "showEditToggle": { "alias": "showEditToggle"; "required": false; "isSignal": true; }; "spellcheck": { "alias": "spellcheck"; "required": false; "isSignal": true; }; "tiptapExtensions": { "alias": "tiptapExtensions"; "required": false; "isSignal": true; }; "tiptapOptions": { "alias": "tiptapOptions"; "required": false; "isSignal": true; }; "showBubbleMenu": { "alias": "showBubbleMenu"; "required": false; "isSignal": true; }; "bubbleMenu": { "alias": "bubbleMenu"; "required": false; "isSignal": true; }; "showImageBubbleMenu": { "alias": "showImageBubbleMenu"; "required": false; "isSignal": true; }; "imageBubbleMenu": { "alias": "imageBubbleMenu"; "required": false; "isSignal": true; }; "toolbar": { "alias": "toolbar"; "required": false; "isSignal": true; }; "showTableBubbleMenu": { "alias": "showTableBubbleMenu"; "required": false; "isSignal": true; }; "tableBubbleMenu": { "alias": "tableBubbleMenu"; "required": false; "isSignal": true; }; "showCellBubbleMenu": { "alias": "showCellBubbleMenu"; "required": false; "isSignal": true; }; "cellBubbleMenu": { "alias": "cellBubbleMenu"; "required": false; "isSignal": true; }; "stateCalculators": { "alias": "stateCalculators"; "required": false; "isSignal": true; }; "imageUpload": { "alias": "imageUpload"; "required": false; "isSignal": true; }; "imageUploadHandler": { "alias": "imageUploadHandler"; "required": false; "isSignal": true; }; }, { "contentChange": "contentChange"; "editorCreated": "editorCreated"; "editorUpdate": "editorUpdate"; "editorFocus": "editorFocus"; "editorBlur": "editorBlur"; "editableChange": "editableChange"; }, never, never, true, [{ directive: typeof NoopValueAccessorDirective; inputs: {}; outputs: {}; }]>;
|
|
1048
1049
|
}
|
|
@@ -1120,7 +1121,7 @@ interface ColorPickerSelection {
|
|
|
1120
1121
|
from: number;
|
|
1121
1122
|
to: number;
|
|
1122
1123
|
}
|
|
1123
|
-
type ColorEditMode =
|
|
1124
|
+
type ColorEditMode = "text" | "highlight";
|
|
1124
1125
|
declare class ColorPickerService {
|
|
1125
1126
|
private storedSelection;
|
|
1126
1127
|
/** Current edit mode: null when closed, 'text' or 'highlight' when open */
|
package/package.json
CHANGED
|
@@ -13,5 +13,9 @@
|
|
|
13
13
|
font-feature-settings: "liga";
|
|
14
14
|
-webkit-font-feature-settings: "liga";
|
|
15
15
|
-webkit-font-smoothing: antialiased;
|
|
16
|
-
font-variation-settings:
|
|
16
|
+
font-variation-settings:
|
|
17
|
+
"FILL" 0,
|
|
18
|
+
"wght" 400,
|
|
19
|
+
"GRAD" 0,
|
|
20
|
+
"opsz" 24;
|
|
17
21
|
}
|