@flogeez/angular-tiptap-editor 3.4.0 → 3.4.1
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 +16 -0
- package/esm2022/lib/components/editor/angular-tiptap-editor.component.mjs +3 -1
- package/esm2022/lib/components/table-of-contents/ate-table-of-contents.component.mjs +8 -4
- package/esm2022/lib/components/table-of-contents/ate-toc-node.component.mjs +59 -0
- package/esm2022/lib/config/ate-slash-commands.config.mjs +10 -1
- package/esm2022/lib/i18n/ateTranslationsModel.mjs +1 -1
- package/esm2022/lib/i18n/de_ateTranslations.mjs +6 -1
- package/esm2022/lib/i18n/en_ateTranslations.mjs +6 -1
- package/esm2022/lib/i18n/fr_ateTranslations.mjs +6 -1
- package/esm2022/lib/node-view/ate-angular-node-view.mjs +8 -2
- package/esm2022/lib/node-view/ate-node-view.renderer.mjs +11 -6
- package/esm2022/public-api.mjs +2 -1
- package/fesm2022/flogeez-angular-tiptap-editor.mjs +8380 -8286
- package/fesm2022/flogeez-angular-tiptap-editor.mjs.map +1 -1
- package/lib/components/table-of-contents/ate-toc-node.component.d.ts +19 -0
- package/lib/config/ate-slash-commands.config.d.ts +1 -1
- package/lib/i18n/ateTranslationsModel.d.ts +5 -0
- package/lib/node-view/ate-angular-node-view.d.ts +4 -0
- package/lib/services/ate-i18n.service.d.ts +9 -0
- package/package.json +1 -1
- package/public-api.d.ts +1 -0
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { Injector } from "@angular/core";
|
|
2
|
+
import { AteAngularNodeView } from "../../node-view/ate-angular-node-view";
|
|
3
|
+
import { RegisterAngularComponentOptions } from "../../node-view/ate-node-view.models";
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
/**
|
|
6
|
+
* Custom Angular NodeView wrapper for displaying Table of Contents directly inside the editor content.
|
|
7
|
+
*/
|
|
8
|
+
export declare class AteTocNodeComponent extends AteAngularNodeView {
|
|
9
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<AteTocNodeComponent, never>;
|
|
10
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<AteTocNodeComponent, "ate-toc-node", never, {}, {}, never, never, true, never>;
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* Registration options for the Table of Contents Angular NodeView
|
|
14
|
+
*/
|
|
15
|
+
export declare const AteTocNodeOptions: RegisterAngularComponentOptions<AteTocNodeComponent>;
|
|
16
|
+
/**
|
|
17
|
+
* Creates the Table of Contents TipTap Node Extension instance.
|
|
18
|
+
*/
|
|
19
|
+
export declare function getAteTocNodeExtension(injector?: Injector): import("@tiptap/core").Node<any, any>;
|
|
@@ -4,7 +4,7 @@ import { AteEditorCommandsService } from "../services/ate-editor-commands.servic
|
|
|
4
4
|
/**
|
|
5
5
|
* Clés des commandes natives dans l'ordre d'affichage
|
|
6
6
|
*/
|
|
7
|
-
export declare const ATE_SLASH_COMMAND_KEYS: readonly ["heading1", "heading2", "heading3", "bulletList", "orderedList", "blockquote", "code", "image", "horizontalRule", "table"];
|
|
7
|
+
export declare const ATE_SLASH_COMMAND_KEYS: readonly ["heading1", "heading2", "heading3", "bulletList", "orderedList", "blockquote", "code", "image", "horizontalRule", "table", "tableOfContents"];
|
|
8
8
|
export type AteSlashCommandKey = (typeof ATE_SLASH_COMMAND_KEYS)[number];
|
|
9
9
|
/**
|
|
10
10
|
* Configuration simplifiée pour activer/désactiver les slash commands natives.
|
|
@@ -49,6 +49,10 @@ export declare abstract class AteAngularNodeView {
|
|
|
49
49
|
* The ProseMirror node
|
|
50
50
|
*/
|
|
51
51
|
node: Signal<ProseMirrorNode>;
|
|
52
|
+
/**
|
|
53
|
+
* Helper signal to directly access node attributes
|
|
54
|
+
*/
|
|
55
|
+
attributes: Signal<Record<string, unknown>>;
|
|
52
56
|
/**
|
|
53
57
|
* Decorations applied to this node
|
|
54
58
|
*/
|
|
@@ -113,6 +113,11 @@ export declare class AteI18nService {
|
|
|
113
113
|
description: string;
|
|
114
114
|
keywords: string[];
|
|
115
115
|
};
|
|
116
|
+
tableOfContents: {
|
|
117
|
+
title: string;
|
|
118
|
+
description: string;
|
|
119
|
+
keywords: string[];
|
|
120
|
+
};
|
|
116
121
|
}>;
|
|
117
122
|
readonly table: import("@angular/core").Signal<{
|
|
118
123
|
addRowBefore: string;
|
|
@@ -244,6 +249,10 @@ export declare class AteI18nService {
|
|
|
244
249
|
title: string;
|
|
245
250
|
description: string;
|
|
246
251
|
keywords: string[];
|
|
252
|
+
} | {
|
|
253
|
+
title: string;
|
|
254
|
+
description: string;
|
|
255
|
+
keywords: string[];
|
|
247
256
|
};
|
|
248
257
|
static ɵfac: i0.ɵɵFactoryDeclaration<AteI18nService, never>;
|
|
249
258
|
static ɵprov: i0.ɵɵInjectableDeclaration<AteI18nService>;
|
package/package.json
CHANGED
package/public-api.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export * from "./lib/components/editor/angular-tiptap-editor.component";
|
|
2
2
|
export { AteTableOfContentsComponent, type AteTocItem, type AteTocVariant } from "./lib/components/table-of-contents/ate-table-of-contents.component";
|
|
3
|
+
export { AteTocNodeComponent, AteTocNodeOptions, getAteTocNodeExtension } from "./lib/components/table-of-contents/ate-toc-node.component";
|
|
3
4
|
export * from "./lib/ate-editor.provider";
|
|
4
5
|
export * from "./lib/directives/ate-noop-value-accessor.directive";
|
|
5
6
|
export * from "./lib/directives/ate-tooltip.directive";
|