@acorex/components 22.4.6 → 22.4.7

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.
@@ -1,19 +1,11 @@
1
1
  import { AXComponent, MXInputBaseValueComponent, MXLookComponent, AXFocusableComponent, AXValuableComponent } from '@acorex/cdk/common';
2
2
  import { AXButtonComponent, AXButtonItemListComponent, AXButtonItemComponent } from '@acorex/components/button';
3
3
  import { AXDecoratorIconComponent, AXDecoratorGenericComponent } from '@acorex/components/decorators';
4
+ import { AXTranslatorPipe, AXTranslationService } from '@acorex/core/translation';
5
+ import { AsyncPipe, isPlatformBrowser } from '@angular/common';
4
6
  import * as i0 from '@angular/core';
5
7
  import { signal, computed, Injectable, inject, input, ViewEncapsulation, ChangeDetectionStrategy, Component, ElementRef, PLATFORM_ID, afterNextRender, effect, DestroyRef, contentChild, forwardRef, model, viewChild, NgModule } from '@angular/core';
6
- import { isPlatformBrowser } from '@angular/common';
7
- import { Mark, mergeAttributes, Extension, Editor } from '@tiptap/core';
8
8
  import { isEqual } from 'lodash-es';
9
- import { Highlight } from '@tiptap/extension-highlight';
10
- import { TableKit } from '@tiptap/extension-table/kit';
11
- import { TextAlign } from '@tiptap/extension-text-align';
12
- import { TextStyle, Color } from '@tiptap/extension-text-style';
13
- import { Placeholder } from '@tiptap/extensions';
14
- import { StarterKit } from '@tiptap/starter-kit';
15
- import { PluginKey, Plugin } from '@tiptap/pm/state';
16
- import { DecorationSet, Decoration } from '@tiptap/pm/view';
17
9
  import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
18
10
  import * as i1 from '@angular/forms';
19
11
  import { NG_VALUE_ACCESSOR, FormsModule } from '@angular/forms';
@@ -22,30 +14,8 @@ import { AXHorizontalScrollDirective } from '@acorex/cdk/horizontal-scroll';
22
14
  import { AXDropdownButtonComponent } from '@acorex/components/dropdown-button';
23
15
  import { AXBadgeComponent } from '@acorex/components/badge';
24
16
  import { AXColorPaletteComponent, AXColorPalettePickerComponent, AXColorPaletteSwatchesComponent, AXColorPaletteInputComponent } from '@acorex/components/color-palette';
25
-
26
- const AX_TEXT_EDITOR_ZOOM_PRESETS = [40, 50, 75, 90, 100, 125, 150, 175, 200];
27
- const AX_TEXT_EDITOR_ZOOM_MIN = 40;
28
- const AX_TEXT_EDITOR_ZOOM_MAX = 200;
29
- const AX_TEXT_EDITOR_DEFAULT_TEXT_COLORS = [
30
- '#f59e0b',
31
- '#eab308',
32
- '#22c55e',
33
- '#06b6d4',
34
- '#3b82f6',
35
- '#a855f7',
36
- '#ec4899',
37
- '#ef4444',
38
- ];
39
- const AX_TEXT_EDITOR_DEFAULT_BACKGROUND_COLORS = [
40
- '#ffffff',
41
- '#f5e6c8',
42
- '#fde68a',
43
- '#f9a8d4',
44
- '#bbf7d0',
45
- '#ddd6fe',
46
- '#fbcfe8',
47
- '#fdba74',
48
- ];
17
+ import { AXToastService } from '@acorex/components/toast';
18
+ import { AXFileService, AXFileTypeRegistryService, AX_IMAGE_FILE_TYPE, AX_VIDEO_FILE_TYPE } from '@acorex/core/file';
49
19
 
50
20
  function escapeHtml(value) {
51
21
  return value.replaceAll('&', '&amp;').replaceAll('<', '&lt;').replaceAll('>', '&gt;').replaceAll('"', '&quot;');
@@ -76,6 +46,12 @@ function isTextEditorCommandActive(editor, command, attrs) {
76
46
  return editor.isActive({ dir: attrs?.['direction'] });
77
47
  case 'link':
78
48
  return editor.isActive('link');
49
+ case 'image':
50
+ return editor.isActive('image');
51
+ case 'video':
52
+ return editor.isActive('video');
53
+ case 'fontSize':
54
+ return Boolean(editor.getAttributes('textStyle')?.['fontSize']);
79
55
  case 'insertTable':
80
56
  return editor.isActive('table');
81
57
  case 'unlink':
@@ -111,10 +87,15 @@ function canRunTextEditorCommand(editor, command, attrs) {
111
87
  return attrs?.['color']
112
88
  ? editor.can().setHighlight({ color: String(attrs['color']) })
113
89
  : editor.can().unsetHighlight();
90
+ case 'fontSize':
91
+ return editor.isEditable;
114
92
  case 'link':
115
93
  return editor.isEditable;
116
94
  case 'unlink':
117
95
  return editor.isEditable && editor.can().unsetLink();
96
+ case 'image':
97
+ case 'video':
98
+ return editor.isEditable;
118
99
  case 'insertTable':
119
100
  return editor.can().insertTable({
120
101
  rows: Number(attrs?.['rows'] ?? 3),
@@ -193,6 +174,8 @@ function runTextEditorCommand(editor, command, attrs) {
193
174
  return attrs?.['color']
194
175
  ? chain.setHighlight({ color: String(attrs['color']) }).run()
195
176
  : chain.unsetHighlight().run();
177
+ case 'fontSize':
178
+ return chain.setFontSize(attrs?.['size'] ? String(attrs['size']) : null).run();
196
179
  case 'link': {
197
180
  const href = normalizeHref(String(attrs?.['href'] ?? ''));
198
181
  if (!href) {
@@ -206,6 +189,18 @@ function runTextEditorCommand(editor, command, attrs) {
206
189
  }
207
190
  case 'unlink':
208
191
  return chain.extendMarkRange('link').unsetLink().run();
192
+ case 'image': {
193
+ const src = String(attrs?.['src'] ?? '').trim();
194
+ if (!src)
195
+ return false;
196
+ return chain.setImage({ src, alt: String(attrs?.['alt'] ?? '') }).run();
197
+ }
198
+ case 'video': {
199
+ const src = String(attrs?.['src'] ?? '').trim();
200
+ if (!src)
201
+ return false;
202
+ return chain.setVideo({ src }).run();
203
+ }
209
204
  case 'insertTable':
210
205
  return chain
211
206
  .insertTable({
@@ -259,6 +254,31 @@ function runTextEditorCommand(editor, command, attrs) {
259
254
  }
260
255
  }
261
256
 
257
+ const AX_TEXT_EDITOR_ZOOM_PRESETS = [40, 50, 75, 90, 100, 125, 150, 175, 200];
258
+ const AX_TEXT_EDITOR_ZOOM_MIN = 40;
259
+ const AX_TEXT_EDITOR_ZOOM_MAX = 200;
260
+ const AX_TEXT_EDITOR_FONT_SIZES = [8, 9, 10, 11, 12, 14, 16, 18, 20, 24, 28, 32, 36, 48, 72];
261
+ const AX_TEXT_EDITOR_DEFAULT_TEXT_COLORS = [
262
+ '#f59e0b',
263
+ '#eab308',
264
+ '#22c55e',
265
+ '#06b6d4',
266
+ '#3b82f6',
267
+ '#a855f7',
268
+ '#ec4899',
269
+ '#ef4444',
270
+ ];
271
+ const AX_TEXT_EDITOR_DEFAULT_BACKGROUND_COLORS = [
272
+ '#ffffff',
273
+ '#f5e6c8',
274
+ '#fde68a',
275
+ '#f9a8d4',
276
+ '#bbf7d0',
277
+ '#ddd6fe',
278
+ '#fbcfe8',
279
+ '#fdba74',
280
+ ];
281
+
262
282
  /**
263
283
  * Per-editor Tiptap facade. Provided on `ax-text-editor`, so projected tools and
264
284
  * custom toolbar children can `inject(AXTextEditorService)` and use either the
@@ -283,6 +303,8 @@ class AXTextEditorService {
283
303
  ...(ngDevMode ? [{ debugName: "textColor" }] : /* istanbul ignore next */ []));
284
304
  this.highlightColor = signal(null, /* @ts-ignore */
285
305
  ...(ngDevMode ? [{ debugName: "highlightColor" }] : /* istanbul ignore next */ []));
306
+ this.fontSize = signal(null, /* @ts-ignore */
307
+ ...(ngDevMode ? [{ debugName: "fontSize" }] : /* istanbul ignore next */ []));
286
308
  this.zoom = signal(100, /* @ts-ignore */
287
309
  ...(ngDevMode ? [{ debugName: "zoom" }] : /* istanbul ignore next */ []));
288
310
  this.zoomFactor = computed(() => this.zoom() / 100, /* @ts-ignore */
@@ -310,10 +332,12 @@ class AXTextEditorService {
310
332
  if (!editor) {
311
333
  this.textColor.set(null);
312
334
  this.highlightColor.set(null);
335
+ this.fontSize.set(null);
313
336
  return;
314
337
  }
315
338
  this.textColor.set(editor.getAttributes('textStyle')?.['color'] ?? null);
316
339
  this.highlightColor.set(editor.getAttributes('highlight')?.['color'] ?? null);
340
+ this.fontSize.set(editor.getAttributes('textStyle')?.['fontSize'] ?? null);
317
341
  }
318
342
  chain() {
319
343
  return this._editor()?.chain() ?? null;
@@ -486,7 +510,7 @@ class AXTextEditorCommandComponent extends AXTextEditorSlot {
486
510
  this.editorService.run(this.command(), this.attrs());
487
511
  }
488
512
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorCommandComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
489
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.6", type: AXTextEditorCommandComponent, isStandalone: true, selector: "ax-text-editor-command", inputs: { command: { classPropertyName: "command", publicName: "command", isSignal: true, isRequired: true, transformFunction: null }, attrs: { classPropertyName: "attrs", publicName: "attrs", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "attr.title": "label()" } }, providers: [
513
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.6", type: AXTextEditorCommandComponent, isStandalone: true, selector: "ax-text-editor-command", inputs: { command: { classPropertyName: "command", publicName: "command", isSignal: true, isRequired: true, transformFunction: null }, attrs: { classPropertyName: "attrs", publicName: "attrs", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null } }, providers: [
490
514
  { provide: AXComponent, useExisting: AXTextEditorCommandComponent },
491
515
  { provide: AXTextEditorSlot, useExisting: AXTextEditorCommandComponent },
492
516
  ], usesInheritance: true, ngImport: i0, template: `
@@ -498,13 +522,14 @@ class AXTextEditorCommandComponent extends AXTextEditorSlot {
498
522
  [toggleable]="toggleable()"
499
523
  [selected]="active()"
500
524
  [disabled]="!enabled()"
525
+ [attr.title]="label() | translate | async"
501
526
  (onClick)="execute()"
502
527
  >
503
528
  @if (icon()) {
504
529
  <ax-icon class="ax-icon {{ icon() }}"></ax-icon>
505
530
  }
506
531
  </ax-button>
507
- `, isInline: true, dependencies: [{ kind: "component", type: AXButtonComponent, selector: "ax-button", inputs: ["disabled", "tabIndex", "color", "look", "text", "toggleable", "selected", "iconOnly", "type", "loadingText"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange", "loadingTextChange"] }, { kind: "component", type: AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
532
+ `, isInline: true, dependencies: [{ kind: "component", type: AXButtonComponent, selector: "ax-button", inputs: ["disabled", "tabIndex", "color", "look", "text", "toggleable", "selected", "iconOnly", "type", "loadingText"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange", "loadingTextChange"] }, { kind: "component", type: AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "pipe", type: AXTranslatorPipe, name: "translate" }, { kind: "pipe", type: AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
508
533
  }
509
534
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorCommandComponent, decorators: [{
510
535
  type: Component,
@@ -519,6 +544,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
519
544
  [toggleable]="toggleable()"
520
545
  [selected]="active()"
521
546
  [disabled]="!enabled()"
547
+ [attr.title]="label() | translate | async"
522
548
  (onClick)="execute()"
523
549
  >
524
550
  @if (icon()) {
@@ -528,10 +554,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
528
554
  `,
529
555
  changeDetection: ChangeDetectionStrategy.OnPush,
530
556
  encapsulation: ViewEncapsulation.None,
531
- host: {
532
- '[attr.title]': 'label()',
533
- },
534
- imports: [AXButtonComponent, AXDecoratorIconComponent],
557
+ imports: [AXButtonComponent, AXDecoratorIconComponent, AXTranslatorPipe, AsyncPipe],
535
558
  providers: [
536
559
  { provide: AXComponent, useExisting: AXTextEditorCommandComponent },
537
560
  { provide: AXTextEditorSlot, useExisting: AXTextEditorCommandComponent },
@@ -539,170 +562,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
539
562
  }]
540
563
  }], propDecorators: { command: [{ type: i0.Input, args: [{ isSignal: true, alias: "command", required: true }] }], attrs: [{ type: i0.Input, args: [{ isSignal: true, alias: "attrs", required: false }] }], icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }], label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }] } });
541
564
 
542
- const Superscript = Mark.create({
543
- name: 'superscript',
544
- excludes: 'subscript',
545
- parseHTML() {
546
- return [{ tag: 'sup' }];
547
- },
548
- renderHTML({ HTMLAttributes }) {
549
- return ['sup', mergeAttributes(HTMLAttributes), 0];
550
- },
551
- addCommands() {
552
- return {
553
- toggleSuperscript: () => ({ commands }) => commands.toggleMark(this.name),
554
- };
555
- },
556
- });
557
- const Subscript = Mark.create({
558
- name: 'subscript',
559
- excludes: 'superscript',
560
- parseHTML() {
561
- return [{ tag: 'sub' }];
562
- },
563
- renderHTML({ HTMLAttributes }) {
564
- return ['sub', mergeAttributes(HTMLAttributes), 0];
565
- },
566
- addCommands() {
567
- return {
568
- toggleSubscript: () => ({ commands }) => commands.toggleMark(this.name),
569
- };
570
- },
571
- });
572
- const keepSelectionKey = new PluginKey('axKeepSelection');
573
- const KeepSelection = Extension.create({
574
- name: 'keepSelection',
575
- addProseMirrorPlugins() {
576
- return [
577
- new Plugin({
578
- key: keepSelectionKey,
579
- state: {
580
- init() {
581
- return DecorationSet.empty;
582
- },
583
- apply(tr, set) {
584
- const meta = tr.getMeta(keepSelectionKey);
585
- if (meta === 'clear')
586
- return DecorationSet.empty;
587
- if (meta && meta.from !== meta.to) {
588
- return DecorationSet.create(tr.doc, [
589
- Decoration.inline(meta.from, meta.to, { class: 'ax-text-editor-kept-selection' }),
590
- ]);
591
- }
592
- return set.map(tr.mapping, tr.doc);
593
- },
594
- },
595
- props: {
596
- decorations(state) {
597
- return keepSelectionKey.getState(state);
598
- },
599
- handleDOMEvents: {
600
- blur(view) {
601
- const { from, to } = view.state.selection;
602
- if (from !== to) {
603
- view.dispatch(view.state.tr.setMeta(keepSelectionKey, { from, to }));
604
- }
605
- return false;
606
- },
607
- focus(view) {
608
- const decorations = keepSelectionKey.getState(view.state);
609
- if (decorations?.find().length) {
610
- view.dispatch(view.state.tr.setMeta(keepSelectionKey, 'clear'));
611
- }
612
- return false;
613
- },
614
- },
615
- },
616
- }),
617
- ];
618
- },
619
- });
620
- const TextDirection = Extension.create({
621
- name: 'textDirection',
622
- addGlobalAttributes() {
623
- return [
624
- {
625
- types: ['paragraph', 'heading'],
626
- attributes: {
627
- dir: {
628
- default: null,
629
- parseHTML: (element) => element.getAttribute('dir'),
630
- renderHTML: (attributes) => (attributes['dir'] ? { dir: attributes['dir'] } : {}),
631
- },
632
- },
633
- },
634
- ];
635
- },
636
- });
637
- function createTextEditorExtensions(placeholder = '') {
638
- const placeholderFn = typeof placeholder === 'function' ? placeholder : () => placeholder;
639
- return [
640
- StarterKit.configure({
641
- heading: {
642
- levels: [1, 2, 3],
643
- HTMLAttributes: {
644
- class: 'ax-text-editor-heading',
645
- },
646
- },
647
- link: {
648
- openOnClick: false,
649
- HTMLAttributes: {
650
- class: 'ax-text-editor-link',
651
- },
652
- },
653
- code: {
654
- HTMLAttributes: {
655
- class: 'ax-text-editor-code',
656
- },
657
- },
658
- codeBlock: {
659
- HTMLAttributes: {
660
- class: 'ax-text-editor-code-block',
661
- },
662
- },
663
- bulletList: {
664
- HTMLAttributes: {
665
- class: 'ax-text-editor-bullet-list',
666
- },
667
- },
668
- orderedList: {
669
- HTMLAttributes: {
670
- class: 'ax-text-editor-ordered-list',
671
- },
672
- },
673
- listItem: {
674
- HTMLAttributes: {
675
- class: 'ax-text-editor-list-item',
676
- },
677
- },
678
- }),
679
- Superscript,
680
- Subscript,
681
- TextStyle,
682
- Color,
683
- Highlight.configure({ multicolor: true }),
684
- TextAlign.configure({
685
- types: ['heading', 'paragraph'],
686
- }),
687
- TextDirection,
688
- KeepSelection,
689
- TableKit.configure({
690
- table: {
691
- resizable: true,
692
- lastColumnResizable: true,
693
- cellMinWidth: 64,
694
- HTMLAttributes: {
695
- class: 'ax-text-editor-table',
696
- },
697
- },
698
- }),
699
- Placeholder.configure({
700
- placeholder: placeholderFn,
701
- showOnlyCurrent: true,
702
- }),
703
- ];
704
- }
705
-
706
565
  class AXTextEditorContentComponent extends AXTextEditorSlot {
707
566
  constructor() {
708
567
  super();
@@ -710,7 +569,7 @@ class AXTextEditorContentComponent extends AXTextEditorSlot {
710
569
  this.elementRef = inject((ElementRef));
711
570
  this.platformId = inject(PLATFORM_ID);
712
571
  this.editor = null;
713
- afterNextRender(() => this.createEditor());
572
+ afterNextRender(() => void this.createEditor());
714
573
  effect(() => {
715
574
  if (!this.editorService.editor())
716
575
  return;
@@ -725,16 +584,21 @@ class AXTextEditorContentComponent extends AXTextEditorSlot {
725
584
  this.editor = null;
726
585
  this.editorService.setEditor(null);
727
586
  }
728
- createEditor() {
587
+ async createEditor() {
729
588
  if (!isPlatformBrowser(this.platformId) || this.editor)
730
589
  return;
731
590
  const host = this.host();
732
591
  const element = this.elementRef.nativeElement.querySelector('.ax-text-editor-surface');
733
592
  if (!host || !element)
734
593
  return;
594
+ const [{ Editor }, { createTextEditorExtensions }] = await Promise.all([
595
+ import('@tiptap/core'),
596
+ Promise.resolve().then(function () { return textEditor_extensions; }),
597
+ ]);
598
+ const extensions = await createTextEditorExtensions(() => this.host()?.placeHolder() ?? '');
735
599
  this.editor = new Editor({
736
600
  element,
737
- extensions: createTextEditorExtensions(() => this.host()?.placeHolder() ?? ''),
601
+ extensions,
738
602
  content: this.toContent(host.value()),
739
603
  editable: this.editorService.editable(),
740
604
  editorProps: {
@@ -780,21 +644,86 @@ class AXTextEditorContentComponent extends AXTextEditorSlot {
780
644
  static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.1.6", type: AXTextEditorContentComponent, isStandalone: true, selector: "ax-text-editor-content", providers: [
781
645
  { provide: AXComponent, useExisting: AXTextEditorContentComponent },
782
646
  { provide: AXTextEditorSlot, useExisting: AXTextEditorContentComponent },
783
- ], usesInheritance: true, ngImport: i0, template: `<div class="ax-text-editor-surface" #surface></div>`, isInline: true, styles: ["@layer properties;@layer components{ax-text-editor-content{position:relative;display:block;width:100%;max-width:100%;min-width:calc(var(--spacing, .25rem) * 0)}.ax-text-editor-surface{width:100%;min-width:calc(var(--spacing, .25rem) * 0)}.ax-text-editor-prose{width:100%;min-width:calc(var(--spacing, .25rem) * 0);padding-inline:calc(var(--spacing, .25rem) * 4);padding-block:calc(var(--spacing, .25rem) * 2);--tw-outline-style: none;outline-style:none;min-height:var( --ax-comp-text-editor-min-height, calc(var(--ax-comp-text-editor-initial-line, 6) * 1.5em + 1.5rem) );color:var(--ax-comp-text-editor-text-color, var(--ax-sys-color-on-surface, inherit));zoom:var(--ax-comp-text-editor-zoom, 1)}.ax-text-editor-prose a{color:rgba(var(--ax-sys-color-primary-600));text-decoration-line:underline;text-underline-offset:2px;text-decoration-thickness:1px}.ax-text-editor-prose a:hover{color:rgba(var(--ax-sys-color-primary-700));text-decoration-thickness:2px}.ax-text-editor-prose blockquote{margin-block:calc(var(--spacing, .25rem) * 2);padding-inline:calc(var(--spacing, .25rem) * 4);padding-block:calc(var(--spacing, .25rem) * 1);border-inline-start:3px solid var(--ax-sys-color-primary, #3b82f6);color:var(--ax-comp-text-editor-text-color, currentColor)}@supports (color: color-mix(in lab,red,red)){.ax-text-editor-prose blockquote{color:color-mix(in oklab,var(--ax-comp-text-editor-text-color, currentColor) 72%,transparent)}}.ax-text-editor-prose blockquote p{margin:0}.ax-text-editor-prose pre,.ax-text-editor-prose pre.ax-text-editor-code-block{margin-block:calc(var(--spacing, .25rem) * 2);display:block;width:100%;overflow-x:auto;border-radius:var(--radius-xl, .75rem);padding-inline:calc(var(--spacing, .25rem) * 4);padding-block:calc(var(--spacing, .25rem) * 3);background-color:var(--ax-comp-text-editor-code-bg-color, rgba(var(--ax-sys-color-surface)));border:0;color:inherit;font-family:inherit;white-space:pre-wrap}.ax-text-editor-prose pre code{display:block;border-radius:0;border-style:var(--tw-border-style);border-width:0px;background-color:transparent;padding:calc(var(--spacing, .25rem) * 0);color:inherit;font-family:inherit;font-size:inherit}.ax-text-editor-prose p.is-empty:first-child:before,.ax-text-editor-prose p.is-editor-empty:first-child:before{pointer-events:none;float:left;height:calc(var(--spacing, .25rem) * 0);content:attr(data-placeholder);color:var(--ax-comp-text-editor-placeholder-color, currentColor)}@supports (color: color-mix(in lab,red,red)){.ax-text-editor-prose p.is-empty:first-child:before,.ax-text-editor-prose p.is-editor-empty:first-child:before{color:var(--ax-comp-text-editor-placeholder-color, color-mix(in oklab, currentColor 45%, transparent))}}.ax-text-editor-prose sup{font-size:.75em;line-height:0;position:relative;top:-.4em;vertical-align:baseline}.ax-text-editor-prose sub{font-size:.75em;line-height:0;position:relative;bottom:-.2em;vertical-align:baseline}.ax-text-editor-prose table{width:100%;border-collapse:collapse;border:1px solid var(--ax-comp-text-editor-table-border-color, var(--ax-sys-color-border-lightest, #e5e7eb))}.ax-text-editor-prose th,.ax-text-editor-prose td{position:relative;min-width:calc(var(--spacing, .25rem) * 16);padding-inline:calc(var(--spacing, .25rem) * 2);padding-block:calc(var(--spacing, .25rem) * 1);vertical-align:top;border:1px solid var(--ax-comp-text-editor-table-border-color, var(--ax-sys-color-border-lightest, #e5e7eb))}.ax-text-editor-prose .selectedCell{background:var(--ax-sys-color-primary, #3b82f6)}@supports (color: color-mix(in lab,red,red)){.ax-text-editor-prose .selectedCell{background:color-mix(in oklab,var(--ax-sys-color-primary, #3b82f6) 16%,transparent)}}.ax-text-editor-prose .column-resize-handle{pointer-events:none;position:absolute;inset-inline-end:calc(var(--spacing, .25rem) * -.5);top:calc(var(--spacing, .25rem) * 0);bottom:calc(var(--spacing, .25rem) * 0);width:calc(var(--spacing, .25rem) * 1);background:var(--ax-sys-color-primary, #3b82f6)}.ax-text-editor-prose .tableWrapper{margin-block:calc(var(--spacing, .25rem) * 2);overflow-x:auto}.resize-cursor{cursor:col-resize}}ax-text-editor .ax-text-editor-prose :not(pre)>code,ax-text-editor .ax-text-editor-prose code.ax-text-editor-code{display:inline;border-radius:.5rem;padding:.25rem .625rem;background-color:var(--ax-comp-text-editor-code-bg-color, rgba(var(--ax-sys-color-surface)));border:1px solid var(--ax-comp-text-editor-code-border-color, rgba(var(--ax-sys-color-border-surface)));color:inherit;font-family:inherit;font-size:.875em}ax-text-editor .ax-text-editor-prose pre code{display:block;border:0;border-radius:0;padding:0;background-color:transparent;color:inherit;font-family:inherit;font-size:inherit}ax-text-editor .ax-text-editor-prose ul,ax-text-editor .ax-text-editor-prose ul.ax-text-editor-bullet-list{list-style-type:disc!important;list-style-position:outside;margin-block:.5em;padding-inline-start:1.75rem}ax-text-editor .ax-text-editor-prose ol,ax-text-editor .ax-text-editor-prose ol.ax-text-editor-ordered-list{list-style-type:decimal!important;list-style-position:outside;margin-block:.5em;padding-inline-start:1.75rem}ax-text-editor .ax-text-editor-prose ul ul{list-style-type:circle!important}ax-text-editor .ax-text-editor-prose ol ol{list-style-type:lower-alpha!important}ax-text-editor .ax-text-editor-prose li{display:list-item!important}ax-text-editor .ax-text-editor-prose li p{margin:0}ax-text-editor .ax-text-editor-prose .ax-text-editor-kept-selection{background-color:var(--ax-sys-color-primary, #3b82f6)}@supports (color: color-mix(in lab,red,red)){ax-text-editor .ax-text-editor-prose .ax-text-editor-kept-selection{background-color:color-mix(in oklab,var(--ax-sys-color-primary, #3b82f6) 28%,transparent)}}ax-text-editor .ax-text-editor-prose p{margin-block:.35em;font-size:1em;font-weight:400}ax-text-editor .ax-text-editor-prose h1,ax-text-editor .ax-text-editor-prose h2,ax-text-editor .ax-text-editor-prose h3{margin-block:.6em .35em;letter-spacing:-.02em;color:inherit}ax-text-editor .ax-text-editor-prose h1{font-size:2.5rem!important;font-weight:600!important;line-height:1.2}ax-text-editor .ax-text-editor-prose h2{font-size:2rem!important;font-weight:600!important;line-height:1.25}ax-text-editor .ax-text-editor-prose h3{font-size:1.5rem!important;font-weight:600!important;line-height:1.3}ax-text-editor .ax-text-editor-prose>:first-child{margin-top:0}@property --tw-border-style{syntax: \"*\"; inherits: false; initial-value: solid;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style: solid}}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
647
+ ], usesInheritance: true, ngImport: i0, template: `<div class="ax-text-editor-surface" #surface></div>`, isInline: true, styles: ["@layer properties;@layer components{ax-text-editor-content{position:relative;display:block;width:100%;max-width:100%;min-width:calc(var(--spacing, .25rem) * 0)}.ax-text-editor-surface{width:100%;min-width:calc(var(--spacing, .25rem) * 0)}.ax-text-editor-prose{width:100%;min-width:calc(var(--spacing, .25rem) * 0);padding-inline:calc(var(--spacing, .25rem) * 4);padding-block:calc(var(--spacing, .25rem) * 2);--tw-outline-style: none;outline-style:none;min-height:var( --ax-comp-text-editor-min-height, calc(var(--ax-comp-text-editor-initial-line, 6) * 1.5em + 1.5rem) );color:var(--ax-comp-text-editor-text-color, var(--ax-sys-color-on-surface, inherit));zoom:var(--ax-comp-text-editor-zoom, 1)}.ax-text-editor-prose a{color:rgba(var(--ax-sys-color-primary-600));text-decoration-line:underline;text-underline-offset:2px;text-decoration-thickness:1px}.ax-text-editor-prose a:hover{color:rgba(var(--ax-sys-color-primary-700));text-decoration-thickness:2px}.ax-text-editor-prose blockquote{margin-block:calc(var(--spacing, .25rem) * 2);padding-inline:calc(var(--spacing, .25rem) * 4);padding-block:calc(var(--spacing, .25rem) * 1);border-inline-start:3px solid var(--ax-sys-color-primary, #3b82f6);color:var(--ax-comp-text-editor-text-color, currentColor)}@supports (color: color-mix(in lab,red,red)){.ax-text-editor-prose blockquote{color:color-mix(in oklab,var(--ax-comp-text-editor-text-color, currentColor) 72%,transparent)}}.ax-text-editor-prose blockquote p{margin:0}.ax-text-editor-prose pre,.ax-text-editor-prose pre.ax-text-editor-code-block{margin-block:calc(var(--spacing, .25rem) * 2);display:block;width:100%;overflow-x:auto;border-radius:var(--radius-xl, .75rem);padding-inline:calc(var(--spacing, .25rem) * 4);padding-block:calc(var(--spacing, .25rem) * 3);background-color:var(--ax-comp-text-editor-code-bg-color, rgba(var(--ax-sys-color-surface)));border:0;color:inherit;font-family:inherit;white-space:pre-wrap}.ax-text-editor-prose pre code{display:block;border-radius:0;border-style:var(--tw-border-style);border-width:0px;background-color:transparent;padding:calc(var(--spacing, .25rem) * 0);color:inherit;font-family:inherit;font-size:inherit}.ax-text-editor-prose p.is-empty:first-child:before,.ax-text-editor-prose p.is-editor-empty:first-child:before{pointer-events:none;float:left;height:calc(var(--spacing, .25rem) * 0);content:attr(data-placeholder);color:var(--ax-comp-text-editor-placeholder-color, currentColor)}@supports (color: color-mix(in lab,red,red)){.ax-text-editor-prose p.is-empty:first-child:before,.ax-text-editor-prose p.is-editor-empty:first-child:before{color:var(--ax-comp-text-editor-placeholder-color, color-mix(in oklab, currentColor 45%, transparent))}}.ax-text-editor-prose sup{font-size:.75em;line-height:0;position:relative;top:-.4em;vertical-align:baseline}.ax-text-editor-prose sub{font-size:.75em;line-height:0;position:relative;bottom:-.2em;vertical-align:baseline}.ax-text-editor-prose table{width:100%;border-collapse:collapse;border:1px solid var(--ax-comp-text-editor-table-border-color, var(--ax-sys-color-border-lightest, #e5e7eb))}.ax-text-editor-prose th,.ax-text-editor-prose td{position:relative;min-width:calc(var(--spacing, .25rem) * 16);padding-inline:calc(var(--spacing, .25rem) * 2);padding-block:calc(var(--spacing, .25rem) * 1);vertical-align:top;border:1px solid var(--ax-comp-text-editor-table-border-color, var(--ax-sys-color-border-lightest, #e5e7eb))}.ax-text-editor-prose .selectedCell{background:var(--ax-sys-color-primary, #3b82f6)}@supports (color: color-mix(in lab,red,red)){.ax-text-editor-prose .selectedCell{background:color-mix(in oklab,var(--ax-sys-color-primary, #3b82f6) 16%,transparent)}}.ax-text-editor-prose .column-resize-handle{pointer-events:none;position:absolute;inset-inline-end:calc(var(--spacing, .25rem) * -.5);top:calc(var(--spacing, .25rem) * 0);bottom:calc(var(--spacing, .25rem) * 0);width:calc(var(--spacing, .25rem) * 1);background:var(--ax-sys-color-primary, #3b82f6)}.ax-text-editor-prose .tableWrapper{margin-block:calc(var(--spacing, .25rem) * 2);overflow-x:auto}.ax-text-editor-prose img.ax-text-editor-image,.ax-text-editor-prose img{margin-block:calc(var(--spacing, .25rem) * 2);height:auto;max-width:100%;border-radius:var(--ax-sys-border-radius)}.ax-text-editor-prose video.ax-text-editor-video,.ax-text-editor-prose video,.ax-text-editor-prose [data-text-editor-video] iframe,.ax-text-editor-prose [data-wysiwyg-video] iframe{margin-block:calc(var(--spacing, .25rem) * 2);max-width:100%;border-radius:var(--ax-sys-border-radius);width:100%;aspect-ratio:16 / 9}.resize-cursor{cursor:col-resize}}ax-text-editor .ax-text-editor-prose :not(pre)>code,ax-text-editor .ax-text-editor-prose code.ax-text-editor-code{display:inline;border-radius:.5rem;padding:.25rem .625rem;background-color:var(--ax-comp-text-editor-code-bg-color, rgba(var(--ax-sys-color-surface)));border:1px solid var(--ax-comp-text-editor-code-border-color, rgba(var(--ax-sys-color-border-surface)));color:inherit;font-family:inherit;font-size:.875em}ax-text-editor .ax-text-editor-prose pre code{display:block;border:0;border-radius:0;padding:0;background-color:transparent;color:inherit;font-family:inherit;font-size:inherit}ax-text-editor .ax-text-editor-prose ul,ax-text-editor .ax-text-editor-prose ul.ax-text-editor-bullet-list{list-style-type:disc!important;list-style-position:outside;margin-block:.5em;padding-inline-start:1.75rem}ax-text-editor .ax-text-editor-prose ol,ax-text-editor .ax-text-editor-prose ol.ax-text-editor-ordered-list{list-style-type:decimal!important;list-style-position:outside;margin-block:.5em;padding-inline-start:1.75rem}ax-text-editor .ax-text-editor-prose ul ul{list-style-type:circle!important}ax-text-editor .ax-text-editor-prose ol ol{list-style-type:lower-alpha!important}ax-text-editor .ax-text-editor-prose li{display:list-item!important}ax-text-editor .ax-text-editor-prose li p{margin:0}ax-text-editor .ax-text-editor-prose .ax-text-editor-kept-selection{background-color:var(--ax-sys-color-primary, #3b82f6)}@supports (color: color-mix(in lab,red,red)){ax-text-editor .ax-text-editor-prose .ax-text-editor-kept-selection{background-color:color-mix(in oklab,var(--ax-sys-color-primary, #3b82f6) 28%,transparent)}}ax-text-editor .ax-text-editor-prose p{margin-block:.35em;font-size:1em;font-weight:400}ax-text-editor .ax-text-editor-prose h1,ax-text-editor .ax-text-editor-prose h2,ax-text-editor .ax-text-editor-prose h3{margin-block:.6em .35em;letter-spacing:-.02em;color:inherit}ax-text-editor .ax-text-editor-prose h1{font-size:2.5rem!important;font-weight:600!important;line-height:1.2}ax-text-editor .ax-text-editor-prose h2{font-size:2rem!important;font-weight:600!important;line-height:1.25}ax-text-editor .ax-text-editor-prose h3{font-size:1.5rem!important;font-weight:600!important;line-height:1.3}ax-text-editor .ax-text-editor-prose>:first-child{margin-top:0}@property --tw-border-style{syntax: \"*\"; inherits: false; initial-value: solid;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style: solid}}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
784
648
  }
785
649
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorContentComponent, decorators: [{
786
650
  type: Component,
787
651
  args: [{ selector: 'ax-text-editor-content', template: `<div class="ax-text-editor-surface" #surface></div>`, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, providers: [
788
652
  { provide: AXComponent, useExisting: AXTextEditorContentComponent },
789
653
  { provide: AXTextEditorSlot, useExisting: AXTextEditorContentComponent },
790
- ], styles: ["@layer properties;@layer components{ax-text-editor-content{position:relative;display:block;width:100%;max-width:100%;min-width:calc(var(--spacing, .25rem) * 0)}.ax-text-editor-surface{width:100%;min-width:calc(var(--spacing, .25rem) * 0)}.ax-text-editor-prose{width:100%;min-width:calc(var(--spacing, .25rem) * 0);padding-inline:calc(var(--spacing, .25rem) * 4);padding-block:calc(var(--spacing, .25rem) * 2);--tw-outline-style: none;outline-style:none;min-height:var( --ax-comp-text-editor-min-height, calc(var(--ax-comp-text-editor-initial-line, 6) * 1.5em + 1.5rem) );color:var(--ax-comp-text-editor-text-color, var(--ax-sys-color-on-surface, inherit));zoom:var(--ax-comp-text-editor-zoom, 1)}.ax-text-editor-prose a{color:rgba(var(--ax-sys-color-primary-600));text-decoration-line:underline;text-underline-offset:2px;text-decoration-thickness:1px}.ax-text-editor-prose a:hover{color:rgba(var(--ax-sys-color-primary-700));text-decoration-thickness:2px}.ax-text-editor-prose blockquote{margin-block:calc(var(--spacing, .25rem) * 2);padding-inline:calc(var(--spacing, .25rem) * 4);padding-block:calc(var(--spacing, .25rem) * 1);border-inline-start:3px solid var(--ax-sys-color-primary, #3b82f6);color:var(--ax-comp-text-editor-text-color, currentColor)}@supports (color: color-mix(in lab,red,red)){.ax-text-editor-prose blockquote{color:color-mix(in oklab,var(--ax-comp-text-editor-text-color, currentColor) 72%,transparent)}}.ax-text-editor-prose blockquote p{margin:0}.ax-text-editor-prose pre,.ax-text-editor-prose pre.ax-text-editor-code-block{margin-block:calc(var(--spacing, .25rem) * 2);display:block;width:100%;overflow-x:auto;border-radius:var(--radius-xl, .75rem);padding-inline:calc(var(--spacing, .25rem) * 4);padding-block:calc(var(--spacing, .25rem) * 3);background-color:var(--ax-comp-text-editor-code-bg-color, rgba(var(--ax-sys-color-surface)));border:0;color:inherit;font-family:inherit;white-space:pre-wrap}.ax-text-editor-prose pre code{display:block;border-radius:0;border-style:var(--tw-border-style);border-width:0px;background-color:transparent;padding:calc(var(--spacing, .25rem) * 0);color:inherit;font-family:inherit;font-size:inherit}.ax-text-editor-prose p.is-empty:first-child:before,.ax-text-editor-prose p.is-editor-empty:first-child:before{pointer-events:none;float:left;height:calc(var(--spacing, .25rem) * 0);content:attr(data-placeholder);color:var(--ax-comp-text-editor-placeholder-color, currentColor)}@supports (color: color-mix(in lab,red,red)){.ax-text-editor-prose p.is-empty:first-child:before,.ax-text-editor-prose p.is-editor-empty:first-child:before{color:var(--ax-comp-text-editor-placeholder-color, color-mix(in oklab, currentColor 45%, transparent))}}.ax-text-editor-prose sup{font-size:.75em;line-height:0;position:relative;top:-.4em;vertical-align:baseline}.ax-text-editor-prose sub{font-size:.75em;line-height:0;position:relative;bottom:-.2em;vertical-align:baseline}.ax-text-editor-prose table{width:100%;border-collapse:collapse;border:1px solid var(--ax-comp-text-editor-table-border-color, var(--ax-sys-color-border-lightest, #e5e7eb))}.ax-text-editor-prose th,.ax-text-editor-prose td{position:relative;min-width:calc(var(--spacing, .25rem) * 16);padding-inline:calc(var(--spacing, .25rem) * 2);padding-block:calc(var(--spacing, .25rem) * 1);vertical-align:top;border:1px solid var(--ax-comp-text-editor-table-border-color, var(--ax-sys-color-border-lightest, #e5e7eb))}.ax-text-editor-prose .selectedCell{background:var(--ax-sys-color-primary, #3b82f6)}@supports (color: color-mix(in lab,red,red)){.ax-text-editor-prose .selectedCell{background:color-mix(in oklab,var(--ax-sys-color-primary, #3b82f6) 16%,transparent)}}.ax-text-editor-prose .column-resize-handle{pointer-events:none;position:absolute;inset-inline-end:calc(var(--spacing, .25rem) * -.5);top:calc(var(--spacing, .25rem) * 0);bottom:calc(var(--spacing, .25rem) * 0);width:calc(var(--spacing, .25rem) * 1);background:var(--ax-sys-color-primary, #3b82f6)}.ax-text-editor-prose .tableWrapper{margin-block:calc(var(--spacing, .25rem) * 2);overflow-x:auto}.resize-cursor{cursor:col-resize}}ax-text-editor .ax-text-editor-prose :not(pre)>code,ax-text-editor .ax-text-editor-prose code.ax-text-editor-code{display:inline;border-radius:.5rem;padding:.25rem .625rem;background-color:var(--ax-comp-text-editor-code-bg-color, rgba(var(--ax-sys-color-surface)));border:1px solid var(--ax-comp-text-editor-code-border-color, rgba(var(--ax-sys-color-border-surface)));color:inherit;font-family:inherit;font-size:.875em}ax-text-editor .ax-text-editor-prose pre code{display:block;border:0;border-radius:0;padding:0;background-color:transparent;color:inherit;font-family:inherit;font-size:inherit}ax-text-editor .ax-text-editor-prose ul,ax-text-editor .ax-text-editor-prose ul.ax-text-editor-bullet-list{list-style-type:disc!important;list-style-position:outside;margin-block:.5em;padding-inline-start:1.75rem}ax-text-editor .ax-text-editor-prose ol,ax-text-editor .ax-text-editor-prose ol.ax-text-editor-ordered-list{list-style-type:decimal!important;list-style-position:outside;margin-block:.5em;padding-inline-start:1.75rem}ax-text-editor .ax-text-editor-prose ul ul{list-style-type:circle!important}ax-text-editor .ax-text-editor-prose ol ol{list-style-type:lower-alpha!important}ax-text-editor .ax-text-editor-prose li{display:list-item!important}ax-text-editor .ax-text-editor-prose li p{margin:0}ax-text-editor .ax-text-editor-prose .ax-text-editor-kept-selection{background-color:var(--ax-sys-color-primary, #3b82f6)}@supports (color: color-mix(in lab,red,red)){ax-text-editor .ax-text-editor-prose .ax-text-editor-kept-selection{background-color:color-mix(in oklab,var(--ax-sys-color-primary, #3b82f6) 28%,transparent)}}ax-text-editor .ax-text-editor-prose p{margin-block:.35em;font-size:1em;font-weight:400}ax-text-editor .ax-text-editor-prose h1,ax-text-editor .ax-text-editor-prose h2,ax-text-editor .ax-text-editor-prose h3{margin-block:.6em .35em;letter-spacing:-.02em;color:inherit}ax-text-editor .ax-text-editor-prose h1{font-size:2.5rem!important;font-weight:600!important;line-height:1.2}ax-text-editor .ax-text-editor-prose h2{font-size:2rem!important;font-weight:600!important;line-height:1.25}ax-text-editor .ax-text-editor-prose h3{font-size:1.5rem!important;font-weight:600!important;line-height:1.3}ax-text-editor .ax-text-editor-prose>:first-child{margin-top:0}@property --tw-border-style{syntax: \"*\"; inherits: false; initial-value: solid;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style: solid}}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"] }]
654
+ ], styles: ["@layer properties;@layer components{ax-text-editor-content{position:relative;display:block;width:100%;max-width:100%;min-width:calc(var(--spacing, .25rem) * 0)}.ax-text-editor-surface{width:100%;min-width:calc(var(--spacing, .25rem) * 0)}.ax-text-editor-prose{width:100%;min-width:calc(var(--spacing, .25rem) * 0);padding-inline:calc(var(--spacing, .25rem) * 4);padding-block:calc(var(--spacing, .25rem) * 2);--tw-outline-style: none;outline-style:none;min-height:var( --ax-comp-text-editor-min-height, calc(var(--ax-comp-text-editor-initial-line, 6) * 1.5em + 1.5rem) );color:var(--ax-comp-text-editor-text-color, var(--ax-sys-color-on-surface, inherit));zoom:var(--ax-comp-text-editor-zoom, 1)}.ax-text-editor-prose a{color:rgba(var(--ax-sys-color-primary-600));text-decoration-line:underline;text-underline-offset:2px;text-decoration-thickness:1px}.ax-text-editor-prose a:hover{color:rgba(var(--ax-sys-color-primary-700));text-decoration-thickness:2px}.ax-text-editor-prose blockquote{margin-block:calc(var(--spacing, .25rem) * 2);padding-inline:calc(var(--spacing, .25rem) * 4);padding-block:calc(var(--spacing, .25rem) * 1);border-inline-start:3px solid var(--ax-sys-color-primary, #3b82f6);color:var(--ax-comp-text-editor-text-color, currentColor)}@supports (color: color-mix(in lab,red,red)){.ax-text-editor-prose blockquote{color:color-mix(in oklab,var(--ax-comp-text-editor-text-color, currentColor) 72%,transparent)}}.ax-text-editor-prose blockquote p{margin:0}.ax-text-editor-prose pre,.ax-text-editor-prose pre.ax-text-editor-code-block{margin-block:calc(var(--spacing, .25rem) * 2);display:block;width:100%;overflow-x:auto;border-radius:var(--radius-xl, .75rem);padding-inline:calc(var(--spacing, .25rem) * 4);padding-block:calc(var(--spacing, .25rem) * 3);background-color:var(--ax-comp-text-editor-code-bg-color, rgba(var(--ax-sys-color-surface)));border:0;color:inherit;font-family:inherit;white-space:pre-wrap}.ax-text-editor-prose pre code{display:block;border-radius:0;border-style:var(--tw-border-style);border-width:0px;background-color:transparent;padding:calc(var(--spacing, .25rem) * 0);color:inherit;font-family:inherit;font-size:inherit}.ax-text-editor-prose p.is-empty:first-child:before,.ax-text-editor-prose p.is-editor-empty:first-child:before{pointer-events:none;float:left;height:calc(var(--spacing, .25rem) * 0);content:attr(data-placeholder);color:var(--ax-comp-text-editor-placeholder-color, currentColor)}@supports (color: color-mix(in lab,red,red)){.ax-text-editor-prose p.is-empty:first-child:before,.ax-text-editor-prose p.is-editor-empty:first-child:before{color:var(--ax-comp-text-editor-placeholder-color, color-mix(in oklab, currentColor 45%, transparent))}}.ax-text-editor-prose sup{font-size:.75em;line-height:0;position:relative;top:-.4em;vertical-align:baseline}.ax-text-editor-prose sub{font-size:.75em;line-height:0;position:relative;bottom:-.2em;vertical-align:baseline}.ax-text-editor-prose table{width:100%;border-collapse:collapse;border:1px solid var(--ax-comp-text-editor-table-border-color, var(--ax-sys-color-border-lightest, #e5e7eb))}.ax-text-editor-prose th,.ax-text-editor-prose td{position:relative;min-width:calc(var(--spacing, .25rem) * 16);padding-inline:calc(var(--spacing, .25rem) * 2);padding-block:calc(var(--spacing, .25rem) * 1);vertical-align:top;border:1px solid var(--ax-comp-text-editor-table-border-color, var(--ax-sys-color-border-lightest, #e5e7eb))}.ax-text-editor-prose .selectedCell{background:var(--ax-sys-color-primary, #3b82f6)}@supports (color: color-mix(in lab,red,red)){.ax-text-editor-prose .selectedCell{background:color-mix(in oklab,var(--ax-sys-color-primary, #3b82f6) 16%,transparent)}}.ax-text-editor-prose .column-resize-handle{pointer-events:none;position:absolute;inset-inline-end:calc(var(--spacing, .25rem) * -.5);top:calc(var(--spacing, .25rem) * 0);bottom:calc(var(--spacing, .25rem) * 0);width:calc(var(--spacing, .25rem) * 1);background:var(--ax-sys-color-primary, #3b82f6)}.ax-text-editor-prose .tableWrapper{margin-block:calc(var(--spacing, .25rem) * 2);overflow-x:auto}.ax-text-editor-prose img.ax-text-editor-image,.ax-text-editor-prose img{margin-block:calc(var(--spacing, .25rem) * 2);height:auto;max-width:100%;border-radius:var(--ax-sys-border-radius)}.ax-text-editor-prose video.ax-text-editor-video,.ax-text-editor-prose video,.ax-text-editor-prose [data-text-editor-video] iframe,.ax-text-editor-prose [data-wysiwyg-video] iframe{margin-block:calc(var(--spacing, .25rem) * 2);max-width:100%;border-radius:var(--ax-sys-border-radius);width:100%;aspect-ratio:16 / 9}.resize-cursor{cursor:col-resize}}ax-text-editor .ax-text-editor-prose :not(pre)>code,ax-text-editor .ax-text-editor-prose code.ax-text-editor-code{display:inline;border-radius:.5rem;padding:.25rem .625rem;background-color:var(--ax-comp-text-editor-code-bg-color, rgba(var(--ax-sys-color-surface)));border:1px solid var(--ax-comp-text-editor-code-border-color, rgba(var(--ax-sys-color-border-surface)));color:inherit;font-family:inherit;font-size:.875em}ax-text-editor .ax-text-editor-prose pre code{display:block;border:0;border-radius:0;padding:0;background-color:transparent;color:inherit;font-family:inherit;font-size:inherit}ax-text-editor .ax-text-editor-prose ul,ax-text-editor .ax-text-editor-prose ul.ax-text-editor-bullet-list{list-style-type:disc!important;list-style-position:outside;margin-block:.5em;padding-inline-start:1.75rem}ax-text-editor .ax-text-editor-prose ol,ax-text-editor .ax-text-editor-prose ol.ax-text-editor-ordered-list{list-style-type:decimal!important;list-style-position:outside;margin-block:.5em;padding-inline-start:1.75rem}ax-text-editor .ax-text-editor-prose ul ul{list-style-type:circle!important}ax-text-editor .ax-text-editor-prose ol ol{list-style-type:lower-alpha!important}ax-text-editor .ax-text-editor-prose li{display:list-item!important}ax-text-editor .ax-text-editor-prose li p{margin:0}ax-text-editor .ax-text-editor-prose .ax-text-editor-kept-selection{background-color:var(--ax-sys-color-primary, #3b82f6)}@supports (color: color-mix(in lab,red,red)){ax-text-editor .ax-text-editor-prose .ax-text-editor-kept-selection{background-color:color-mix(in oklab,var(--ax-sys-color-primary, #3b82f6) 28%,transparent)}}ax-text-editor .ax-text-editor-prose p{margin-block:.35em;font-size:1em;font-weight:400}ax-text-editor .ax-text-editor-prose h1,ax-text-editor .ax-text-editor-prose h2,ax-text-editor .ax-text-editor-prose h3{margin-block:.6em .35em;letter-spacing:-.02em;color:inherit}ax-text-editor .ax-text-editor-prose h1{font-size:2.5rem!important;font-weight:600!important;line-height:1.2}ax-text-editor .ax-text-editor-prose h2{font-size:2rem!important;font-weight:600!important;line-height:1.25}ax-text-editor .ax-text-editor-prose h3{font-size:1.5rem!important;font-weight:600!important;line-height:1.3}ax-text-editor .ax-text-editor-prose>:first-child{margin-top:0}@property --tw-border-style{syntax: \"*\"; inherits: false; initial-value: solid;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style: solid}}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"] }]
791
655
  }], ctorParameters: () => [] });
792
656
 
657
+ const SCOPE = '@acorex:text-editor';
658
+ const AX_TEXT_EDITOR_I18N = {
659
+ placeholder: `${SCOPE}.placeholder`,
660
+ tools: {
661
+ undo: `${SCOPE}.tools.undo`,
662
+ redo: `${SCOPE}.tools.redo`,
663
+ bold: `${SCOPE}.tools.bold`,
664
+ italic: `${SCOPE}.tools.italic`,
665
+ underline: `${SCOPE}.tools.underline`,
666
+ strike: `${SCOPE}.tools.strike`,
667
+ code: `${SCOPE}.tools.code`,
668
+ codeBlock: `${SCOPE}.tools.code-block`,
669
+ link: `${SCOPE}.tools.link`,
670
+ image: `${SCOPE}.tools.image`,
671
+ video: `${SCOPE}.tools.video`,
672
+ bulletList: `${SCOPE}.tools.bullet-list`,
673
+ orderedList: `${SCOPE}.tools.ordered-list`,
674
+ ltr: `${SCOPE}.tools.ltr`,
675
+ rtl: `${SCOPE}.tools.rtl`,
676
+ textColor: `${SCOPE}.tools.text-color`,
677
+ highlight: `${SCOPE}.tools.highlight`,
678
+ colors: `${SCOPE}.tools.colors`,
679
+ paragraph: `${SCOPE}.tools.paragraph`,
680
+ alignLeft: `${SCOPE}.tools.align-left`,
681
+ alignCenter: `${SCOPE}.tools.align-center`,
682
+ alignRight: `${SCOPE}.tools.align-right`,
683
+ alignJustify: `${SCOPE}.tools.align-justify`,
684
+ superscript: `${SCOPE}.tools.superscript`,
685
+ subscript: `${SCOPE}.tools.subscript`,
686
+ blockquote: `${SCOPE}.tools.blockquote`,
687
+ horizontalRule: `${SCOPE}.tools.horizontal-rule`,
688
+ zoomIn: `${SCOPE}.tools.zoom-in`,
689
+ zoomOut: `${SCOPE}.tools.zoom-out`,
690
+ },
691
+ blocks: {
692
+ paragraph: `${SCOPE}.blocks.paragraph`,
693
+ heading1: `${SCOPE}.blocks.heading1`,
694
+ heading2: `${SCOPE}.blocks.heading2`,
695
+ heading3: `${SCOPE}.blocks.heading3`,
696
+ blockquote: `${SCOPE}.blocks.blockquote`,
697
+ codeBlock: `${SCOPE}.blocks.code-block`,
698
+ },
699
+ fontSize: {
700
+ label: `${SCOPE}.font-size.label`,
701
+ default: `${SCOPE}.font-size.default`,
702
+ },
703
+ insert: {
704
+ apply: `${SCOPE}.insert.apply`,
705
+ remove: `${SCOPE}.insert.remove`,
706
+ failed: `${SCOPE}.insert.failed`,
707
+ },
708
+ swatches: {
709
+ recent: `${SCOPE}.swatches.recent`,
710
+ text: `${SCOPE}.swatches.text`,
711
+ highlight: `${SCOPE}.swatches.highlight`,
712
+ },
713
+ zoom: {
714
+ fit: `${SCOPE}.zoom.fit`,
715
+ },
716
+ table: {
717
+ insert: `${SCOPE}.table.insert`,
718
+ },
719
+ };
720
+
793
721
  class AXTextEditorComponent extends classes((MXInputBaseValueComponent), MXLookComponent) {
794
722
  constructor() {
795
723
  super();
796
724
  this.editorService = inject(AXTextEditorService);
797
725
  this.destroyRef = inject(DestroyRef);
726
+ this.translation = inject(AXTranslationService);
798
727
  this.projected = contentChild(AXTextEditorContentComponent, /* @ts-ignore */
799
728
  ...(ngDevMode ? [{ debugName: "projected" }] : /* istanbul ignore next */ []));
800
729
  this.syncingFromEditor = false;
@@ -809,7 +738,8 @@ class AXTextEditorComponent extends classes((MXInputBaseValueComponent), MXLookC
809
738
  this.projectedContent = computed(() => this.projected() != null, /* @ts-ignore */
810
739
  ...(ngDevMode ? [{ debugName: "projectedContent" }] : /* istanbul ignore next */ []));
811
740
  this.editorService.bindHost({
812
- placeHolder: () => this.placeHolder(),
741
+ placeHolder: () => this.placeHolder() ||
742
+ this.translation.translateSync(AX_TEXT_EDITOR_I18N.placeholder, { waitForLoad: true }),
813
743
  outputFormat: () => this.outputFormat(),
814
744
  value: () => this.value,
815
745
  disabled: () => this.disabled,
@@ -827,6 +757,12 @@ class AXTextEditorComponent extends classes((MXInputBaseValueComponent), MXLookC
827
757
  getEditorService() {
828
758
  return this.editorService;
829
759
  }
760
+ focus() {
761
+ this.editorService.focus();
762
+ }
763
+ blur() {
764
+ this.editorService.blur();
765
+ }
830
766
  /** @ignore */
831
767
  notifyEditorFocus(event) {
832
768
  this.emitOnFocusEvent(event);
@@ -838,7 +774,7 @@ class AXTextEditorComponent extends classes((MXInputBaseValueComponent), MXLookC
838
774
  /** @ignore */
839
775
  notifyEditorValue(value) {
840
776
  this.syncingFromEditor = true;
841
- this.value = value;
777
+ this.commitValue(value, true);
842
778
  this.syncingFromEditor = false;
843
779
  }
844
780
  internalValueChanged(value) {
@@ -852,7 +788,7 @@ class AXTextEditorComponent extends classes((MXInputBaseValueComponent), MXLookC
852
788
  this.editorService.setContent(value == null ? '' : value, false);
853
789
  }
854
790
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
855
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.6", type: AXTextEditorComponent, isStandalone: true, selector: "ax-text-editor", inputs: { disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: false, isRequired: false, transformFunction: null }, tabIndex: { classPropertyName: "tabIndex", publicName: "tabIndex", isSignal: false, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: false, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: false, isRequired: false, transformFunction: null }, state: { classPropertyName: "state", publicName: "state", isSignal: false, isRequired: false, transformFunction: null }, name: { classPropertyName: "name", publicName: "name", isSignal: false, isRequired: false, transformFunction: null }, look: { classPropertyName: "look", publicName: "look", isSignal: false, isRequired: false, transformFunction: null }, placeHolder: { classPropertyName: "placeHolder", publicName: "placeHolder", isSignal: true, isRequired: false, transformFunction: null }, outputFormat: { classPropertyName: "outputFormat", publicName: "outputFormat", isSignal: true, isRequired: false, transformFunction: null }, initialLine: { classPropertyName: "initialLine", publicName: "initialLine", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { onBlur: "onBlur", onFocus: "onFocus", valueChange: "valueChange", stateChange: "stateChange", onValueChanged: "onValueChanged", readonlyChange: "readonlyChange", disabledChange: "disabledChange" }, host: { properties: { "style.--ax-comp-text-editor-initial-line": "initialLine()", "style.--ax-comp-text-editor-zoom": "zoomFactor()", "class.ax-state-disabled": "disabled", "class.ax-state-readonly": "readonly && !disabled" }, classAttribute: "ax-text-editor" }, providers: [
791
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.6", type: AXTextEditorComponent, isStandalone: true, selector: "ax-text-editor", inputs: { disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: false, isRequired: false, transformFunction: null }, tabIndex: { classPropertyName: "tabIndex", publicName: "tabIndex", isSignal: false, isRequired: false, transformFunction: null }, readonly: { classPropertyName: "readonly", publicName: "readonly", isSignal: false, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: false, isRequired: false, transformFunction: null }, state: { classPropertyName: "state", publicName: "state", isSignal: false, isRequired: false, transformFunction: null }, name: { classPropertyName: "name", publicName: "name", isSignal: false, isRequired: false, transformFunction: null }, look: { classPropertyName: "look", publicName: "look", isSignal: false, isRequired: false, transformFunction: null }, placeHolder: { classPropertyName: "placeHolder", publicName: "placeHolder", isSignal: true, isRequired: false, transformFunction: null }, outputFormat: { classPropertyName: "outputFormat", publicName: "outputFormat", isSignal: true, isRequired: false, transformFunction: null }, initialLine: { classPropertyName: "initialLine", publicName: "initialLine", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { onBlur: "onBlur", onFocus: "onFocus", valueChange: "valueChange", stateChange: "stateChange", onValueChanged: "onValueChanged", readonlyChange: "readonlyChange", disabledChange: "disabledChange" }, host: { attributes: { "ngSkipHydration": "true" }, properties: { "style.--ax-comp-text-editor-initial-line": "initialLine()", "style.--ax-comp-text-editor-zoom": "zoomFactor()", "class.ax-state-disabled": "disabled", "class.ax-state-readonly": "readonly && !disabled" }, classAttribute: "ax-text-editor" }, providers: [
856
792
  AXTextEditorService,
857
793
  { provide: AXComponent, useExisting: AXTextEditorComponent },
858
794
  { provide: AXFocusableComponent, useExisting: AXTextEditorComponent },
@@ -862,7 +798,7 @@ class AXTextEditorComponent extends classes((MXInputBaseValueComponent), MXLookC
862
798
  useExisting: forwardRef(() => AXTextEditorComponent),
863
799
  multi: true,
864
800
  },
865
- ], queries: [{ propertyName: "projected", first: true, predicate: AXTextEditorContentComponent, descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<div class=\"ax-editor-container ax-default {{ look }}\">\n <ng-content></ng-content>\n @if (!projectedContent()) {\n <ax-text-editor-content></ax-text-editor-content>\n }\n</div>\n", styles: ["@layer components{ax-text-editor{position:relative;display:block;width:100%;max-width:100%;min-width:calc(var(--spacing, .25rem) * 0);overflow:visible;border-radius:var(--ax-sys-border-radius)}ax-text-editor:focus-within{box-shadow:0 0 0 2px var(--ax-sys-color-primary-light, rgb(147 197 253))}ax-text-editor>.ax-editor-container{position:relative;display:flex;max-width:100%;min-width:calc(var(--spacing, .25rem) * 0);flex-direction:column;display:flex!important;flex-direction:column!important;align-items:stretch!important;justify-content:flex-start!important;height:auto!important;min-height:var(--ax-sys-size-default, 2.5rem);padding:0!important;overflow:visible!important}ax-text-editor ax-text-editor-toolbar{width:100%;flex-shrink:0}ax-text-editor ax-text-editor-content{min-width:calc(var(--spacing, .25rem) * 0);flex:1;overflow:auto}ax-text-editor:has(ax-text-editor-toolbar.ax-orientation-vertical)>.ax-editor-container{flex-direction:row!important;align-items:stretch!important}ax-text-editor:has(ax-text-editor-toolbar.ax-orientation-vertical) ax-text-editor-toolbar.ax-orientation-vertical{width:auto;max-width:none;flex-shrink:0;align-self:flex-start;overflow:hidden;max-height:var( --ax-comp-text-editor-min-height, calc(var(--ax-comp-text-editor-initial-line, 6) * 1.5em + 1.5rem) )}:dir(rtl) ax-text-editor:has(ax-text-editor-toolbar.ax-orientation-vertical)>.ax-editor-container{flex-direction:row-reverse!important}:is(ax-text-editor.ax-state-disabled,ax-text-editor.ax-state-readonly) ax-text-editor-toolbar{pointer-events:none;opacity:60%}ax-text-editor.ax-state-readonly:not(.ax-state-disabled) ax-text-editor-content{cursor:default}ax-text-editor.ax-state-disabled{cursor:not-allowed}ax-text-editor.ax-state-disabled ax-text-editor-content{pointer-events:none;cursor:not-allowed;opacity:60%}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "component", type: AXTextEditorContentComponent, selector: "ax-text-editor-content" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
801
+ ], queries: [{ propertyName: "projected", first: true, predicate: AXTextEditorContentComponent, descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<div class=\"ax-editor-container ax-default {{ look }}\">\n <ng-content></ng-content>\n @if (!projectedContent()) {\n <ax-text-editor-content></ax-text-editor-content>\n }\n <ng-content select=\"ax-validation-rule\"></ng-content>\n</div>\n<div class=\"ax-error-container\"></div>\n", styles: ["@layer components{ax-text-editor{position:relative;display:block;width:100%;max-width:100%;min-width:calc(var(--spacing, .25rem) * 0);overflow:visible;border-radius:var(--ax-sys-border-radius)}ax-text-editor:focus-within{box-shadow:0 0 0 2px var(--ax-sys-color-primary-light, rgb(147 197 253))}ax-text-editor>.ax-editor-container{position:relative;display:flex;max-width:100%;min-width:calc(var(--spacing, .25rem) * 0);flex-direction:column;display:flex!important;flex-direction:column!important;align-items:stretch!important;justify-content:flex-start!important;height:auto!important;min-height:var(--ax-sys-size-default, 2.5rem);padding:0!important;overflow:visible!important}ax-text-editor ax-text-editor-toolbar{width:100%;flex-shrink:0}ax-text-editor ax-text-editor-content{min-width:calc(var(--spacing, .25rem) * 0);flex:1;overflow:auto}ax-text-editor:has(ax-text-editor-toolbar.ax-orientation-vertical)>.ax-editor-container{flex-direction:row!important;align-items:stretch!important}ax-text-editor:has(ax-text-editor-toolbar.ax-orientation-vertical) ax-text-editor-toolbar.ax-orientation-vertical{width:auto;max-width:none;flex-shrink:0;align-self:flex-start;overflow:hidden;max-height:var( --ax-comp-text-editor-min-height, calc(var(--ax-comp-text-editor-initial-line, 6) * 1.5em + 1.5rem) )}:dir(rtl) ax-text-editor:has(ax-text-editor-toolbar.ax-orientation-vertical)>.ax-editor-container{flex-direction:row-reverse!important}:is(ax-text-editor.ax-state-disabled,ax-text-editor.ax-state-readonly) ax-text-editor-toolbar{pointer-events:none;opacity:60%}ax-text-editor.ax-state-readonly:not(.ax-state-disabled) ax-text-editor-content{cursor:default}ax-text-editor.ax-state-disabled{cursor:not-allowed}ax-text-editor.ax-state-disabled ax-text-editor-content{pointer-events:none;cursor:not-allowed;opacity:60%}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "component", type: AXTextEditorContentComponent, selector: "ax-text-editor-content" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
866
802
  }
867
803
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorComponent, decorators: [{
868
804
  type: Component,
@@ -880,6 +816,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
880
816
  '[class.ax-state-disabled]': 'disabled',
881
817
  '[class.ax-state-readonly]': 'readonly && !disabled',
882
818
  class: 'ax-text-editor',
819
+ ngSkipHydration: 'true',
883
820
  }, providers: [
884
821
  AXTextEditorService,
885
822
  { provide: AXComponent, useExisting: AXTextEditorComponent },
@@ -890,9 +827,318 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
890
827
  useExisting: forwardRef(() => AXTextEditorComponent),
891
828
  multi: true,
892
829
  },
893
- ], imports: [AXTextEditorContentComponent], template: "<div class=\"ax-editor-container ax-default {{ look }}\">\n <ng-content></ng-content>\n @if (!projectedContent()) {\n <ax-text-editor-content></ax-text-editor-content>\n }\n</div>\n", styles: ["@layer components{ax-text-editor{position:relative;display:block;width:100%;max-width:100%;min-width:calc(var(--spacing, .25rem) * 0);overflow:visible;border-radius:var(--ax-sys-border-radius)}ax-text-editor:focus-within{box-shadow:0 0 0 2px var(--ax-sys-color-primary-light, rgb(147 197 253))}ax-text-editor>.ax-editor-container{position:relative;display:flex;max-width:100%;min-width:calc(var(--spacing, .25rem) * 0);flex-direction:column;display:flex!important;flex-direction:column!important;align-items:stretch!important;justify-content:flex-start!important;height:auto!important;min-height:var(--ax-sys-size-default, 2.5rem);padding:0!important;overflow:visible!important}ax-text-editor ax-text-editor-toolbar{width:100%;flex-shrink:0}ax-text-editor ax-text-editor-content{min-width:calc(var(--spacing, .25rem) * 0);flex:1;overflow:auto}ax-text-editor:has(ax-text-editor-toolbar.ax-orientation-vertical)>.ax-editor-container{flex-direction:row!important;align-items:stretch!important}ax-text-editor:has(ax-text-editor-toolbar.ax-orientation-vertical) ax-text-editor-toolbar.ax-orientation-vertical{width:auto;max-width:none;flex-shrink:0;align-self:flex-start;overflow:hidden;max-height:var( --ax-comp-text-editor-min-height, calc(var(--ax-comp-text-editor-initial-line, 6) * 1.5em + 1.5rem) )}:dir(rtl) ax-text-editor:has(ax-text-editor-toolbar.ax-orientation-vertical)>.ax-editor-container{flex-direction:row-reverse!important}:is(ax-text-editor.ax-state-disabled,ax-text-editor.ax-state-readonly) ax-text-editor-toolbar{pointer-events:none;opacity:60%}ax-text-editor.ax-state-readonly:not(.ax-state-disabled) ax-text-editor-content{cursor:default}ax-text-editor.ax-state-disabled{cursor:not-allowed}ax-text-editor.ax-state-disabled ax-text-editor-content{pointer-events:none;cursor:not-allowed;opacity:60%}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"] }]
830
+ ], imports: [AXTextEditorContentComponent], template: "<div class=\"ax-editor-container ax-default {{ look }}\">\n <ng-content></ng-content>\n @if (!projectedContent()) {\n <ax-text-editor-content></ax-text-editor-content>\n }\n <ng-content select=\"ax-validation-rule\"></ng-content>\n</div>\n<div class=\"ax-error-container\"></div>\n", styles: ["@layer components{ax-text-editor{position:relative;display:block;width:100%;max-width:100%;min-width:calc(var(--spacing, .25rem) * 0);overflow:visible;border-radius:var(--ax-sys-border-radius)}ax-text-editor:focus-within{box-shadow:0 0 0 2px var(--ax-sys-color-primary-light, rgb(147 197 253))}ax-text-editor>.ax-editor-container{position:relative;display:flex;max-width:100%;min-width:calc(var(--spacing, .25rem) * 0);flex-direction:column;display:flex!important;flex-direction:column!important;align-items:stretch!important;justify-content:flex-start!important;height:auto!important;min-height:var(--ax-sys-size-default, 2.5rem);padding:0!important;overflow:visible!important}ax-text-editor ax-text-editor-toolbar{width:100%;flex-shrink:0}ax-text-editor ax-text-editor-content{min-width:calc(var(--spacing, .25rem) * 0);flex:1;overflow:auto}ax-text-editor:has(ax-text-editor-toolbar.ax-orientation-vertical)>.ax-editor-container{flex-direction:row!important;align-items:stretch!important}ax-text-editor:has(ax-text-editor-toolbar.ax-orientation-vertical) ax-text-editor-toolbar.ax-orientation-vertical{width:auto;max-width:none;flex-shrink:0;align-self:flex-start;overflow:hidden;max-height:var( --ax-comp-text-editor-min-height, calc(var(--ax-comp-text-editor-initial-line, 6) * 1.5em + 1.5rem) )}:dir(rtl) ax-text-editor:has(ax-text-editor-toolbar.ax-orientation-vertical)>.ax-editor-container{flex-direction:row-reverse!important}:is(ax-text-editor.ax-state-disabled,ax-text-editor.ax-state-readonly) ax-text-editor-toolbar{pointer-events:none;opacity:60%}ax-text-editor.ax-state-readonly:not(.ax-state-disabled) ax-text-editor-content{cursor:default}ax-text-editor.ax-state-disabled{cursor:not-allowed}ax-text-editor.ax-state-disabled ax-text-editor-content{pointer-events:none;cursor:not-allowed;opacity:60%}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"] }]
894
831
  }], ctorParameters: () => [], propDecorators: { projected: [{ type: i0.ContentChild, args: [i0.forwardRef(() => AXTextEditorContentComponent), { isSignal: true }] }], placeHolder: [{ type: i0.Input, args: [{ isSignal: true, alias: "placeHolder", required: false }] }], outputFormat: [{ type: i0.Input, args: [{ isSignal: true, alias: "outputFormat", required: false }] }], initialLine: [{ type: i0.Input, args: [{ isSignal: true, alias: "initialLine", required: false }] }] } });
895
832
 
833
+ function createSuperscript(core) {
834
+ return core.Mark.create({
835
+ name: 'superscript',
836
+ excludes: 'subscript',
837
+ parseHTML() {
838
+ return [{ tag: 'sup' }];
839
+ },
840
+ renderHTML({ HTMLAttributes }) {
841
+ return ['sup', core.mergeAttributes(HTMLAttributes), 0];
842
+ },
843
+ addCommands() {
844
+ return {
845
+ toggleSuperscript: () => ({ commands }) => commands.toggleMark(this.name),
846
+ };
847
+ },
848
+ });
849
+ }
850
+ function createSubscript(core) {
851
+ return core.Mark.create({
852
+ name: 'subscript',
853
+ excludes: 'superscript',
854
+ parseHTML() {
855
+ return [{ tag: 'sub' }];
856
+ },
857
+ renderHTML({ HTMLAttributes }) {
858
+ return ['sub', core.mergeAttributes(HTMLAttributes), 0];
859
+ },
860
+ addCommands() {
861
+ return {
862
+ toggleSubscript: () => ({ commands }) => commands.toggleMark(this.name),
863
+ };
864
+ },
865
+ });
866
+ }
867
+ function createKeepSelection(core, pmState, pmView) {
868
+ const keepSelectionKey = new pmState.PluginKey('axKeepSelection');
869
+ return core.Extension.create({
870
+ name: 'keepSelection',
871
+ addProseMirrorPlugins() {
872
+ return [
873
+ new pmState.Plugin({
874
+ key: keepSelectionKey,
875
+ state: {
876
+ init() {
877
+ return pmView.DecorationSet.empty;
878
+ },
879
+ apply(tr, set) {
880
+ const meta = tr.getMeta(keepSelectionKey);
881
+ if (meta === 'clear')
882
+ return pmView.DecorationSet.empty;
883
+ if (meta && meta.from !== meta.to) {
884
+ return pmView.DecorationSet.create(tr.doc, [
885
+ pmView.Decoration.inline(meta.from, meta.to, { class: 'ax-text-editor-kept-selection' }),
886
+ ]);
887
+ }
888
+ return set.map(tr.mapping, tr.doc);
889
+ },
890
+ },
891
+ props: {
892
+ decorations(state) {
893
+ return keepSelectionKey.getState(state);
894
+ },
895
+ handleDOMEvents: {
896
+ blur(view) {
897
+ const { from, to } = view.state.selection;
898
+ if (from !== to) {
899
+ view.dispatch(view.state.tr.setMeta(keepSelectionKey, { from, to }));
900
+ }
901
+ return false;
902
+ },
903
+ focus(view) {
904
+ const decorations = keepSelectionKey.getState(view.state);
905
+ if (decorations?.find().length) {
906
+ view.dispatch(view.state.tr.setMeta(keepSelectionKey, 'clear'));
907
+ }
908
+ return false;
909
+ },
910
+ },
911
+ },
912
+ }),
913
+ ];
914
+ },
915
+ });
916
+ }
917
+ function createTextDirection(core) {
918
+ return core.Extension.create({
919
+ name: 'textDirection',
920
+ addGlobalAttributes() {
921
+ return [
922
+ {
923
+ types: ['paragraph', 'heading'],
924
+ attributes: {
925
+ dir: {
926
+ default: null,
927
+ parseHTML: (element) => element.getAttribute('dir'),
928
+ renderHTML: (attributes) => (attributes['dir'] ? { dir: attributes['dir'] } : {}),
929
+ },
930
+ },
931
+ },
932
+ ];
933
+ },
934
+ });
935
+ }
936
+ function createFontSize(core) {
937
+ return core.Extension.create({
938
+ name: 'axTextEditorFontSize',
939
+ addGlobalAttributes() {
940
+ return [
941
+ {
942
+ types: ['textStyle'],
943
+ attributes: {
944
+ fontSize: {
945
+ default: null,
946
+ parseHTML: (element) => element.style.fontSize?.replace(/['"]+/g, '') || null,
947
+ renderHTML: (attributes) => attributes['fontSize'] ? { style: `font-size: ${attributes['fontSize']}` } : {},
948
+ },
949
+ },
950
+ },
951
+ ];
952
+ },
953
+ addCommands() {
954
+ return {
955
+ setFontSize: (size) => ({ chain }) => {
956
+ if (!size) {
957
+ return chain().focus().setMark('textStyle', { fontSize: null }).removeEmptyTextStyle().run();
958
+ }
959
+ return chain().focus().setMark('textStyle', { fontSize: size }).run();
960
+ },
961
+ };
962
+ },
963
+ });
964
+ }
965
+ function createVideo(core) {
966
+ return core.Node.create({
967
+ name: 'video',
968
+ group: 'block',
969
+ atom: true,
970
+ addOptions() {
971
+ return {
972
+ HTMLAttributes: {},
973
+ };
974
+ },
975
+ addAttributes() {
976
+ return {
977
+ src: {
978
+ default: null,
979
+ },
980
+ };
981
+ },
982
+ parseHTML() {
983
+ return [
984
+ { tag: 'video[src]' },
985
+ { tag: 'div[data-text-editor-video] video' },
986
+ { tag: 'div[data-wysiwyg-video] iframe' },
987
+ { tag: 'iframe[src]' },
988
+ ];
989
+ },
990
+ renderHTML({ HTMLAttributes }) {
991
+ const src = String(HTMLAttributes['src'] ?? '');
992
+ if (isEmbedSrc(src)) {
993
+ return [
994
+ 'div',
995
+ core.mergeAttributes(this.options.HTMLAttributes, { 'data-text-editor-video': '' }),
996
+ [
997
+ 'iframe',
998
+ core.mergeAttributes({
999
+ src,
1000
+ frameborder: '0',
1001
+ allowfullscreen: 'true',
1002
+ allow: 'accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture',
1003
+ }),
1004
+ ],
1005
+ ];
1006
+ }
1007
+ return [
1008
+ 'video',
1009
+ core.mergeAttributes(this.options.HTMLAttributes, HTMLAttributes, {
1010
+ class: 'ax-text-editor-video',
1011
+ controls: 'true',
1012
+ }),
1013
+ ];
1014
+ },
1015
+ addCommands() {
1016
+ return {
1017
+ setVideo: ({ src }) => ({ commands }) => commands.insertContent({
1018
+ type: this.name,
1019
+ attrs: { src: toVideoSrc(src) },
1020
+ }),
1021
+ };
1022
+ },
1023
+ });
1024
+ }
1025
+ function isEmbedSrc(src) {
1026
+ return /youtube\.com\/embed\/|youtu\.be\//i.test(src);
1027
+ }
1028
+ function toVideoSrc(src) {
1029
+ const trimmed = src.trim();
1030
+ if (!trimmed)
1031
+ return trimmed;
1032
+ try {
1033
+ const url = new URL(trimmed);
1034
+ if (url.hostname.includes('youtube.com') && url.searchParams.get('v')) {
1035
+ return `https://www.youtube.com/embed/${url.searchParams.get('v')}`;
1036
+ }
1037
+ if (url.hostname === 'youtu.be') {
1038
+ return `https://www.youtube.com/embed/${url.pathname.slice(1)}`;
1039
+ }
1040
+ }
1041
+ catch {
1042
+ return trimmed;
1043
+ }
1044
+ return trimmed;
1045
+ }
1046
+ async function createTextEditorExtensions(placeholder = '') {
1047
+ const placeholderFn = typeof placeholder === 'function' ? placeholder : () => placeholder;
1048
+ const [core, pmState, pmView, starterKitMod, textStyleMod, highlightMod, textAlignMod, extensionsMod, tableMod, imageMod] = await Promise.all([
1049
+ import('@tiptap/core'),
1050
+ import('@tiptap/pm/state'),
1051
+ import('@tiptap/pm/view'),
1052
+ import('@tiptap/starter-kit'),
1053
+ import('@tiptap/extension-text-style'),
1054
+ import('@tiptap/extension-highlight'),
1055
+ import('@tiptap/extension-text-align'),
1056
+ import('@tiptap/extensions'),
1057
+ import('@tiptap/extension-table/kit'),
1058
+ import('@tiptap/extension-image'),
1059
+ ]);
1060
+ const Image = imageMod.default ?? imageMod.Image;
1061
+ return [
1062
+ starterKitMod.StarterKit.configure({
1063
+ heading: {
1064
+ levels: [1, 2, 3],
1065
+ HTMLAttributes: {
1066
+ class: 'ax-text-editor-heading',
1067
+ },
1068
+ },
1069
+ link: {
1070
+ openOnClick: false,
1071
+ HTMLAttributes: {
1072
+ class: 'ax-text-editor-link',
1073
+ },
1074
+ },
1075
+ code: {
1076
+ HTMLAttributes: {
1077
+ class: 'ax-text-editor-code',
1078
+ },
1079
+ },
1080
+ codeBlock: {
1081
+ HTMLAttributes: {
1082
+ class: 'ax-text-editor-code-block',
1083
+ },
1084
+ },
1085
+ bulletList: {
1086
+ HTMLAttributes: {
1087
+ class: 'ax-text-editor-bullet-list',
1088
+ },
1089
+ },
1090
+ orderedList: {
1091
+ HTMLAttributes: {
1092
+ class: 'ax-text-editor-ordered-list',
1093
+ },
1094
+ },
1095
+ listItem: {
1096
+ HTMLAttributes: {
1097
+ class: 'ax-text-editor-list-item',
1098
+ },
1099
+ },
1100
+ }),
1101
+ createSuperscript(core),
1102
+ createSubscript(core),
1103
+ textStyleMod.TextStyle,
1104
+ textStyleMod.Color,
1105
+ createFontSize(core),
1106
+ highlightMod.Highlight.configure({ multicolor: true }),
1107
+ textAlignMod.TextAlign.configure({
1108
+ types: ['heading', 'paragraph'],
1109
+ }),
1110
+ createTextDirection(core),
1111
+ createKeepSelection(core, pmState, pmView),
1112
+ tableMod.TableKit.configure({
1113
+ table: {
1114
+ resizable: true,
1115
+ lastColumnResizable: true,
1116
+ cellMinWidth: 64,
1117
+ HTMLAttributes: {
1118
+ class: 'ax-text-editor-table',
1119
+ },
1120
+ },
1121
+ }),
1122
+ Image.configure({
1123
+ inline: true,
1124
+ allowBase64: true,
1125
+ HTMLAttributes: {
1126
+ class: 'ax-text-editor-image',
1127
+ },
1128
+ }),
1129
+ createVideo(core),
1130
+ extensionsMod.Placeholder.configure({
1131
+ placeholder: placeholderFn,
1132
+ showOnlyCurrent: true,
1133
+ }),
1134
+ ];
1135
+ }
1136
+
1137
+ var textEditor_extensions = /*#__PURE__*/Object.freeze({
1138
+ __proto__: null,
1139
+ createTextEditorExtensions: createTextEditorExtensions
1140
+ });
1141
+
896
1142
  class AXTextEditorToolbarComponent extends AXTextEditorSlot {
897
1143
  constructor() {
898
1144
  super(...arguments);
@@ -913,23 +1159,31 @@ class AXTextEditorToolbarComponent extends AXTextEditorSlot {
913
1159
  { provide: AXTextEditorSlot, useExisting: AXTextEditorToolbarComponent },
914
1160
  ], usesInheritance: true, ngImport: i0, template: `
915
1161
  <div class="ax-text-editor-toolbar-content">
916
- <ng-content select="ax-prefix"></ng-content>
1162
+ <div class="ax-text-editor-toolbar-prefix">
1163
+ <ng-content select="ax-prefix"></ng-content>
1164
+ </div>
917
1165
  <div class="ax-text-editor-toolbar-tools" axHorizontalScroll [orientation]="orientation()">
918
1166
  <ng-content></ng-content>
919
1167
  </div>
920
- <ng-content select="ax-suffix"></ng-content>
1168
+ <div class="ax-text-editor-toolbar-suffix">
1169
+ <ng-content select="ax-suffix"></ng-content>
1170
+ </div>
921
1171
  </div>
922
- `, isInline: true, styles: ["@layer properties;@layer components{ax-text-editor-toolbar{position:relative;display:block;width:100%;max-width:100%;min-width:calc(var(--spacing, .25rem) * 0);overflow-x:hidden;overflow-y:visible}ax-text-editor-toolbar>.ax-text-editor-toolbar-content{display:flex;width:100%;max-width:100%;min-width:calc(var(--spacing, .25rem) * 0);flex-wrap:nowrap;align-items:center;gap:calc(var(--spacing, .25rem) * 1);border-bottom-style:var(--tw-border-style);border-bottom-width:1px;border-color:rgba(var(--ax-sys-color-border-lightest-surface));padding-inline:calc(var(--spacing, .25rem) * 1);padding-block:calc(var(--spacing, .25rem) * .5)}ax-text-editor-toolbar>.ax-text-editor-toolbar-content ax-prefix{display:flex;flex-shrink:0;align-items:center;gap:calc(var(--spacing, .25rem) * 1);padding-inline:calc(var(--spacing, .25rem) * 1)}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools{display:flex;min-width:calc(var(--spacing, .25rem) * 0);flex:1;flex-wrap:nowrap;align-items:center;gap:calc(var(--spacing, .25rem) * 1);overflow-x:auto;overflow-y:hidden;padding:calc(var(--spacing, .25rem) * 1);overscroll-behavior-x:contain;scrollbar-width:none;-ms-overflow-style:none}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools::-webkit-scrollbar{display:none}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools>*{display:flex;flex-shrink:0;align-items:center;gap:calc(var(--spacing, .25rem) * 1)}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools ax-dropdown-button{width:auto}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools>ax-divider{margin-inline:calc(var(--spacing, .25rem) * 1);display:block;min-height:calc(var(--spacing, .25rem) * 6);width:1px;align-self:stretch;background-color:rgba(var(--ax-sys-color-border-lightest-surface))}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools ax-button button.ax-state-selected{background-color:var(--ax-comp-bg-lighter, var(--color-surface));color:var(--ax-comp-text-lighter, var(--color-on-surface))}ax-text-editor-toolbar>.ax-text-editor-toolbar-content ax-suffix{margin-inline-start:auto;display:flex;flex-shrink:0;align-items:center;gap:calc(var(--spacing, .25rem) * 1);padding-inline:calc(var(--spacing, .25rem) * 1)}ax-text-editor-toolbar.ax-orientation-vertical{display:flex;width:auto;max-width:none;flex-direction:column;overflow:hidden}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content{min-height:calc(var(--spacing, .25rem) * 0);flex:1;flex-direction:column;align-items:stretch;gap:calc(var(--spacing, .25rem) * 1);border-inline-end-style:var(--tw-border-style);border-inline-end-width:1px;border-bottom-style:var(--tw-border-style);border-bottom-width:0px;padding-inline:calc(var(--spacing, .25rem) * .5);padding-block:calc(var(--spacing, .25rem) * 1)}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content ax-prefix,ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content ax-suffix{flex-direction:column;align-items:center;gap:calc(var(--spacing, .25rem) * 1);padding-inline:calc(var(--spacing, .25rem) * 0)}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content ax-suffix{margin-inline-start:calc(var(--spacing, .25rem) * 0);margin-top:auto}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools{min-height:calc(var(--spacing, .25rem) * 0);flex:1;flex-direction:column;align-items:center;gap:calc(var(--spacing, .25rem) * 1);overflow-x:hidden;overflow-y:auto;padding:calc(var(--spacing, .25rem) * 1);overscroll-behavior-y:contain}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools>*{flex-direction:column;align-items:center;justify-content:center;gap:calc(var(--spacing, .25rem) * 1)}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools>ax-divider{margin-inline:calc(var(--spacing, .25rem) * 0);margin-block:calc(var(--spacing, .25rem) * 1);height:1px;min-height:1px;width:calc(var(--spacing, .25rem) * 6);min-width:calc(var(--spacing, .25rem) * 6);align-self:center}ax-text-editor-toolbar.ax-orientation-vertical .ax-text-editor-zoom-value{min-width:calc(var(--spacing, .25rem) * 0)}}@property --tw-border-style{syntax: \"*\"; inherits: false; initial-value: solid;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style: solid}}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "directive", type: AXHorizontalScrollDirective, selector: "[axHorizontalScroll]", inputs: ["disabled", "orientation", "speed"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
1172
+ `, isInline: true, styles: ["@layer properties;@layer components{ax-text-editor-toolbar{position:relative;display:block;width:100%;max-width:100%;min-width:calc(var(--spacing, .25rem) * 0);overflow-x:hidden;overflow-y:visible}ax-text-editor-toolbar>.ax-text-editor-toolbar-content{display:flex;width:100%;max-width:100%;min-width:calc(var(--spacing, .25rem) * 0);flex-wrap:nowrap;align-items:center;gap:calc(var(--spacing, .25rem) * 1);border-bottom-style:var(--tw-border-style);border-bottom-width:1px;border-color:rgba(var(--ax-sys-color-border-lightest-surface));padding-inline:calc(var(--spacing, .25rem) * 1);padding-block:calc(var(--spacing, .25rem) * .5)}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-prefix:not(:has(ax-prefix)),ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-suffix:not(:has(ax-suffix)){display:none}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-prefix:has(ax-prefix){display:flex;flex-shrink:0;align-items:center;gap:calc(var(--spacing, .25rem) * 1);align-self:stretch;padding-inline:calc(var(--spacing, .25rem) * 1);border-inline-end:1px solid var(--ax-sys-color-border-lightest, var(--color-border-lightest, #e5e7eb))}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-suffix:has(ax-suffix){margin-inline-start:auto;display:flex;flex-shrink:0;align-items:center;gap:calc(var(--spacing, .25rem) * 1);align-self:stretch;padding-inline:calc(var(--spacing, .25rem) * 1);border-inline-start:1px solid var(--ax-sys-color-border-lightest, var(--color-border-lightest, #e5e7eb))}ax-text-editor-toolbar>.ax-text-editor-toolbar-content ax-prefix,ax-text-editor-toolbar>.ax-text-editor-toolbar-content ax-suffix{display:flex;align-items:center;gap:calc(var(--spacing, .25rem) * 1)}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools{display:flex;min-width:calc(var(--spacing, .25rem) * 0);flex:1;flex-wrap:nowrap;align-items:center;gap:calc(var(--spacing, .25rem) * 1);overflow-x:auto;overflow-y:hidden;padding:calc(var(--spacing, .25rem) * 1);overscroll-behavior-x:contain;scrollbar-width:none;-ms-overflow-style:none}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools::-webkit-scrollbar{display:none}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools>*{display:flex;flex-shrink:0;align-items:center;gap:calc(var(--spacing, .25rem) * 1)}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools ax-dropdown-button{width:auto}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools>ax-divider{margin-inline:calc(var(--spacing, .25rem) * 1);display:block;min-height:calc(var(--spacing, .25rem) * 6);width:1px;align-self:stretch;background-color:rgba(var(--ax-sys-color-border-lightest-surface))}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools ax-button button.ax-state-selected{background-color:var(--ax-comp-bg-lighter, var(--color-surface));color:var(--ax-comp-text-lighter, var(--color-on-surface))}ax-text-editor-toolbar.ax-orientation-vertical{display:flex;width:auto;max-width:none;flex-direction:column;overflow:hidden}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content{min-height:calc(var(--spacing, .25rem) * 0);flex:1;flex-direction:column;align-items:stretch;gap:calc(var(--spacing, .25rem) * 1);border-inline-end-style:var(--tw-border-style);border-inline-end-width:1px;border-bottom-style:var(--tw-border-style);border-bottom-width:0px;padding-inline:calc(var(--spacing, .25rem) * .5);padding-block:calc(var(--spacing, .25rem) * 1)}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-prefix:has(ax-prefix){flex-direction:column;align-items:center;padding-inline:calc(var(--spacing, .25rem) * 0);padding-block:calc(var(--spacing, .25rem) * 1);border-inline-end:0;border-block-end:1px solid var(--ax-sys-color-border-lightest, var(--color-border-lightest, #e5e7eb))}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-suffix:has(ax-suffix){margin-inline-start:calc(var(--spacing, .25rem) * 0);margin-top:auto;flex-direction:column;align-items:center;padding-inline:calc(var(--spacing, .25rem) * 0);padding-block:calc(var(--spacing, .25rem) * 1);border-inline-start:0;border-block-start:1px solid var(--ax-sys-color-border-lightest, var(--color-border-lightest, #e5e7eb))}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content ax-prefix,ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content ax-suffix{flex-direction:column;align-items:center;gap:calc(var(--spacing, .25rem) * 1)}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools{min-height:calc(var(--spacing, .25rem) * 0);flex:1;flex-direction:column;align-items:center;gap:calc(var(--spacing, .25rem) * 1);overflow-x:hidden;overflow-y:auto;padding:calc(var(--spacing, .25rem) * 1);overscroll-behavior-y:contain}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools>*{flex-direction:column;align-items:center;justify-content:center;gap:calc(var(--spacing, .25rem) * 1)}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools>ax-divider{margin-inline:calc(var(--spacing, .25rem) * 0);margin-block:calc(var(--spacing, .25rem) * 1);height:1px;min-height:1px;width:calc(var(--spacing, .25rem) * 6);min-width:calc(var(--spacing, .25rem) * 6);align-self:center}ax-text-editor-toolbar.ax-orientation-vertical .ax-text-editor-zoom-value{min-width:calc(var(--spacing, .25rem) * 0)}}@property --tw-border-style{syntax: \"*\"; inherits: false; initial-value: solid;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style: solid}}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "directive", type: AXHorizontalScrollDirective, selector: "[axHorizontalScroll]", inputs: ["disabled", "orientation", "speed"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
923
1173
  }
924
1174
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorToolbarComponent, decorators: [{
925
1175
  type: Component,
926
1176
  args: [{ selector: 'ax-text-editor-toolbar', template: `
927
1177
  <div class="ax-text-editor-toolbar-content">
928
- <ng-content select="ax-prefix"></ng-content>
1178
+ <div class="ax-text-editor-toolbar-prefix">
1179
+ <ng-content select="ax-prefix"></ng-content>
1180
+ </div>
929
1181
  <div class="ax-text-editor-toolbar-tools" axHorizontalScroll [orientation]="orientation()">
930
1182
  <ng-content></ng-content>
931
1183
  </div>
932
- <ng-content select="ax-suffix"></ng-content>
1184
+ <div class="ax-text-editor-toolbar-suffix">
1185
+ <ng-content select="ax-suffix"></ng-content>
1186
+ </div>
933
1187
  </div>
934
1188
  `, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, host: {
935
1189
  class: 'ax-text-editor-toolbar',
@@ -939,24 +1193,43 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
939
1193
  }, imports: [AXHorizontalScrollDirective], providers: [
940
1194
  { provide: AXComponent, useExisting: AXTextEditorToolbarComponent },
941
1195
  { provide: AXTextEditorSlot, useExisting: AXTextEditorToolbarComponent },
942
- ], styles: ["@layer properties;@layer components{ax-text-editor-toolbar{position:relative;display:block;width:100%;max-width:100%;min-width:calc(var(--spacing, .25rem) * 0);overflow-x:hidden;overflow-y:visible}ax-text-editor-toolbar>.ax-text-editor-toolbar-content{display:flex;width:100%;max-width:100%;min-width:calc(var(--spacing, .25rem) * 0);flex-wrap:nowrap;align-items:center;gap:calc(var(--spacing, .25rem) * 1);border-bottom-style:var(--tw-border-style);border-bottom-width:1px;border-color:rgba(var(--ax-sys-color-border-lightest-surface));padding-inline:calc(var(--spacing, .25rem) * 1);padding-block:calc(var(--spacing, .25rem) * .5)}ax-text-editor-toolbar>.ax-text-editor-toolbar-content ax-prefix{display:flex;flex-shrink:0;align-items:center;gap:calc(var(--spacing, .25rem) * 1);padding-inline:calc(var(--spacing, .25rem) * 1)}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools{display:flex;min-width:calc(var(--spacing, .25rem) * 0);flex:1;flex-wrap:nowrap;align-items:center;gap:calc(var(--spacing, .25rem) * 1);overflow-x:auto;overflow-y:hidden;padding:calc(var(--spacing, .25rem) * 1);overscroll-behavior-x:contain;scrollbar-width:none;-ms-overflow-style:none}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools::-webkit-scrollbar{display:none}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools>*{display:flex;flex-shrink:0;align-items:center;gap:calc(var(--spacing, .25rem) * 1)}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools ax-dropdown-button{width:auto}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools>ax-divider{margin-inline:calc(var(--spacing, .25rem) * 1);display:block;min-height:calc(var(--spacing, .25rem) * 6);width:1px;align-self:stretch;background-color:rgba(var(--ax-sys-color-border-lightest-surface))}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools ax-button button.ax-state-selected{background-color:var(--ax-comp-bg-lighter, var(--color-surface));color:var(--ax-comp-text-lighter, var(--color-on-surface))}ax-text-editor-toolbar>.ax-text-editor-toolbar-content ax-suffix{margin-inline-start:auto;display:flex;flex-shrink:0;align-items:center;gap:calc(var(--spacing, .25rem) * 1);padding-inline:calc(var(--spacing, .25rem) * 1)}ax-text-editor-toolbar.ax-orientation-vertical{display:flex;width:auto;max-width:none;flex-direction:column;overflow:hidden}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content{min-height:calc(var(--spacing, .25rem) * 0);flex:1;flex-direction:column;align-items:stretch;gap:calc(var(--spacing, .25rem) * 1);border-inline-end-style:var(--tw-border-style);border-inline-end-width:1px;border-bottom-style:var(--tw-border-style);border-bottom-width:0px;padding-inline:calc(var(--spacing, .25rem) * .5);padding-block:calc(var(--spacing, .25rem) * 1)}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content ax-prefix,ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content ax-suffix{flex-direction:column;align-items:center;gap:calc(var(--spacing, .25rem) * 1);padding-inline:calc(var(--spacing, .25rem) * 0)}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content ax-suffix{margin-inline-start:calc(var(--spacing, .25rem) * 0);margin-top:auto}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools{min-height:calc(var(--spacing, .25rem) * 0);flex:1;flex-direction:column;align-items:center;gap:calc(var(--spacing, .25rem) * 1);overflow-x:hidden;overflow-y:auto;padding:calc(var(--spacing, .25rem) * 1);overscroll-behavior-y:contain}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools>*{flex-direction:column;align-items:center;justify-content:center;gap:calc(var(--spacing, .25rem) * 1)}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools>ax-divider{margin-inline:calc(var(--spacing, .25rem) * 0);margin-block:calc(var(--spacing, .25rem) * 1);height:1px;min-height:1px;width:calc(var(--spacing, .25rem) * 6);min-width:calc(var(--spacing, .25rem) * 6);align-self:center}ax-text-editor-toolbar.ax-orientation-vertical .ax-text-editor-zoom-value{min-width:calc(var(--spacing, .25rem) * 0)}}@property --tw-border-style{syntax: \"*\"; inherits: false; initial-value: solid;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style: solid}}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"] }]
1196
+ ], styles: ["@layer properties;@layer components{ax-text-editor-toolbar{position:relative;display:block;width:100%;max-width:100%;min-width:calc(var(--spacing, .25rem) * 0);overflow-x:hidden;overflow-y:visible}ax-text-editor-toolbar>.ax-text-editor-toolbar-content{display:flex;width:100%;max-width:100%;min-width:calc(var(--spacing, .25rem) * 0);flex-wrap:nowrap;align-items:center;gap:calc(var(--spacing, .25rem) * 1);border-bottom-style:var(--tw-border-style);border-bottom-width:1px;border-color:rgba(var(--ax-sys-color-border-lightest-surface));padding-inline:calc(var(--spacing, .25rem) * 1);padding-block:calc(var(--spacing, .25rem) * .5)}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-prefix:not(:has(ax-prefix)),ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-suffix:not(:has(ax-suffix)){display:none}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-prefix:has(ax-prefix){display:flex;flex-shrink:0;align-items:center;gap:calc(var(--spacing, .25rem) * 1);align-self:stretch;padding-inline:calc(var(--spacing, .25rem) * 1);border-inline-end:1px solid var(--ax-sys-color-border-lightest, var(--color-border-lightest, #e5e7eb))}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-suffix:has(ax-suffix){margin-inline-start:auto;display:flex;flex-shrink:0;align-items:center;gap:calc(var(--spacing, .25rem) * 1);align-self:stretch;padding-inline:calc(var(--spacing, .25rem) * 1);border-inline-start:1px solid var(--ax-sys-color-border-lightest, var(--color-border-lightest, #e5e7eb))}ax-text-editor-toolbar>.ax-text-editor-toolbar-content ax-prefix,ax-text-editor-toolbar>.ax-text-editor-toolbar-content ax-suffix{display:flex;align-items:center;gap:calc(var(--spacing, .25rem) * 1)}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools{display:flex;min-width:calc(var(--spacing, .25rem) * 0);flex:1;flex-wrap:nowrap;align-items:center;gap:calc(var(--spacing, .25rem) * 1);overflow-x:auto;overflow-y:hidden;padding:calc(var(--spacing, .25rem) * 1);overscroll-behavior-x:contain;scrollbar-width:none;-ms-overflow-style:none}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools::-webkit-scrollbar{display:none}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools>*{display:flex;flex-shrink:0;align-items:center;gap:calc(var(--spacing, .25rem) * 1)}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools ax-dropdown-button{width:auto}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools>ax-divider{margin-inline:calc(var(--spacing, .25rem) * 1);display:block;min-height:calc(var(--spacing, .25rem) * 6);width:1px;align-self:stretch;background-color:rgba(var(--ax-sys-color-border-lightest-surface))}ax-text-editor-toolbar>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools ax-button button.ax-state-selected{background-color:var(--ax-comp-bg-lighter, var(--color-surface));color:var(--ax-comp-text-lighter, var(--color-on-surface))}ax-text-editor-toolbar.ax-orientation-vertical{display:flex;width:auto;max-width:none;flex-direction:column;overflow:hidden}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content{min-height:calc(var(--spacing, .25rem) * 0);flex:1;flex-direction:column;align-items:stretch;gap:calc(var(--spacing, .25rem) * 1);border-inline-end-style:var(--tw-border-style);border-inline-end-width:1px;border-bottom-style:var(--tw-border-style);border-bottom-width:0px;padding-inline:calc(var(--spacing, .25rem) * .5);padding-block:calc(var(--spacing, .25rem) * 1)}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-prefix:has(ax-prefix){flex-direction:column;align-items:center;padding-inline:calc(var(--spacing, .25rem) * 0);padding-block:calc(var(--spacing, .25rem) * 1);border-inline-end:0;border-block-end:1px solid var(--ax-sys-color-border-lightest, var(--color-border-lightest, #e5e7eb))}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-suffix:has(ax-suffix){margin-inline-start:calc(var(--spacing, .25rem) * 0);margin-top:auto;flex-direction:column;align-items:center;padding-inline:calc(var(--spacing, .25rem) * 0);padding-block:calc(var(--spacing, .25rem) * 1);border-inline-start:0;border-block-start:1px solid var(--ax-sys-color-border-lightest, var(--color-border-lightest, #e5e7eb))}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content ax-prefix,ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content ax-suffix{flex-direction:column;align-items:center;gap:calc(var(--spacing, .25rem) * 1)}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools{min-height:calc(var(--spacing, .25rem) * 0);flex:1;flex-direction:column;align-items:center;gap:calc(var(--spacing, .25rem) * 1);overflow-x:hidden;overflow-y:auto;padding:calc(var(--spacing, .25rem) * 1);overscroll-behavior-y:contain}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools>*{flex-direction:column;align-items:center;justify-content:center;gap:calc(var(--spacing, .25rem) * 1)}ax-text-editor-toolbar.ax-orientation-vertical>.ax-text-editor-toolbar-content .ax-text-editor-toolbar-tools>ax-divider{margin-inline:calc(var(--spacing, .25rem) * 0);margin-block:calc(var(--spacing, .25rem) * 1);height:1px;min-height:1px;width:calc(var(--spacing, .25rem) * 6);min-width:calc(var(--spacing, .25rem) * 6);align-self:center}ax-text-editor-toolbar.ax-orientation-vertical .ax-text-editor-zoom-value{min-width:calc(var(--spacing, .25rem) * 0)}}@property --tw-border-style{syntax: \"*\"; inherits: false; initial-value: solid;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style: solid}}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"] }]
943
1197
  }], propDecorators: { orientation: [{ type: i0.Input, args: [{ isSignal: true, alias: "orientation", required: false }] }] } });
944
1198
 
945
1199
  class AXTextEditorAlignmentComponent extends AXTextEditorSlot {
1200
+ constructor() {
1201
+ super(...arguments);
1202
+ this.i18n = AX_TEXT_EDITOR_I18N;
1203
+ }
946
1204
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorAlignmentComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
947
1205
  static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.1.6", type: AXTextEditorAlignmentComponent, isStandalone: true, selector: "ax-text-editor-alignment", providers: [
948
1206
  { provide: AXComponent, useExisting: AXTextEditorAlignmentComponent },
949
1207
  { provide: AXTextEditorSlot, useExisting: AXTextEditorAlignmentComponent },
950
1208
  ], usesInheritance: true, ngImport: i0, template: `
951
- <ax-text-editor-command command="align" [attrs]="{ align: 'left' }" icon="ax-icon-align-left" label="Align left" />
1209
+ <ax-text-editor-command
1210
+ command="align"
1211
+ [attrs]="{ align: 'left' }"
1212
+ icon="ax-icon-align-left"
1213
+ [label]="i18n.tools.alignLeft"
1214
+ />
952
1215
  <ax-text-editor-command
953
1216
  command="align"
954
1217
  [attrs]="{ align: 'center' }"
955
1218
  icon="ax-icon-align-center"
956
- label="Align center"
1219
+ [label]="i18n.tools.alignCenter"
1220
+ />
1221
+ <ax-text-editor-command
1222
+ command="align"
1223
+ [attrs]="{ align: 'right' }"
1224
+ icon="ax-icon-align-right"
1225
+ [label]="i18n.tools.alignRight"
1226
+ />
1227
+ <ax-text-editor-command
1228
+ command="align"
1229
+ [attrs]="{ align: 'justify' }"
1230
+ icon="ax-icon-align-justify"
1231
+ [label]="i18n.tools.alignJustify"
957
1232
  />
958
- <ax-text-editor-command command="align" [attrs]="{ align: 'right' }" icon="ax-icon-align-right" label="Align right" />
959
- <ax-text-editor-command command="align" [attrs]="{ align: 'justify' }" icon="ax-icon-align-justify" label="Justify" />
960
1233
  `, isInline: true, dependencies: [{ kind: "component", type: AXTextEditorCommandComponent, selector: "ax-text-editor-command", inputs: ["command", "attrs", "icon", "label"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
961
1234
  }
962
1235
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorAlignmentComponent, decorators: [{
@@ -964,15 +1237,30 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
964
1237
  args: [{
965
1238
  selector: 'ax-text-editor-alignment',
966
1239
  template: `
967
- <ax-text-editor-command command="align" [attrs]="{ align: 'left' }" icon="ax-icon-align-left" label="Align left" />
1240
+ <ax-text-editor-command
1241
+ command="align"
1242
+ [attrs]="{ align: 'left' }"
1243
+ icon="ax-icon-align-left"
1244
+ [label]="i18n.tools.alignLeft"
1245
+ />
968
1246
  <ax-text-editor-command
969
1247
  command="align"
970
1248
  [attrs]="{ align: 'center' }"
971
1249
  icon="ax-icon-align-center"
972
- label="Align center"
1250
+ [label]="i18n.tools.alignCenter"
1251
+ />
1252
+ <ax-text-editor-command
1253
+ command="align"
1254
+ [attrs]="{ align: 'right' }"
1255
+ icon="ax-icon-align-right"
1256
+ [label]="i18n.tools.alignRight"
1257
+ />
1258
+ <ax-text-editor-command
1259
+ command="align"
1260
+ [attrs]="{ align: 'justify' }"
1261
+ icon="ax-icon-align-justify"
1262
+ [label]="i18n.tools.alignJustify"
973
1263
  />
974
- <ax-text-editor-command command="align" [attrs]="{ align: 'right' }" icon="ax-icon-align-right" label="Align right" />
975
- <ax-text-editor-command command="align" [attrs]="{ align: 'justify' }" icon="ax-icon-align-justify" label="Justify" />
976
1264
  `,
977
1265
  changeDetection: ChangeDetectionStrategy.OnPush,
978
1266
  encapsulation: ViewEncapsulation.None,
@@ -985,13 +1273,17 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
985
1273
  }] });
986
1274
 
987
1275
  class AXTextEditorBlocksComponent extends AXTextEditorSlot {
1276
+ constructor() {
1277
+ super(...arguments);
1278
+ this.i18n = AX_TEXT_EDITOR_I18N;
1279
+ }
988
1280
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorBlocksComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
989
1281
  static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.1.6", type: AXTextEditorBlocksComponent, isStandalone: true, selector: "ax-text-editor-blocks", providers: [
990
1282
  { provide: AXComponent, useExisting: AXTextEditorBlocksComponent },
991
1283
  { provide: AXTextEditorSlot, useExisting: AXTextEditorBlocksComponent },
992
1284
  ], usesInheritance: true, ngImport: i0, template: `
993
- <ax-text-editor-command command="codeBlock" icon="ax-icon-code-block" label="Code block" />
994
- <ax-text-editor-command command="horizontalRule" icon="ax-icon-horizontal-rule" label="Horizontal rule" />
1285
+ <ax-text-editor-command command="codeBlock" icon="ax-icon-code-block" [label]="i18n.tools.codeBlock" />
1286
+ <ax-text-editor-command command="horizontalRule" icon="ax-icon-horizontal-rule" [label]="i18n.tools.horizontalRule" />
995
1287
  `, isInline: true, dependencies: [{ kind: "component", type: AXTextEditorCommandComponent, selector: "ax-text-editor-command", inputs: ["command", "attrs", "icon", "label"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
996
1288
  }
997
1289
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorBlocksComponent, decorators: [{
@@ -999,8 +1291,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
999
1291
  args: [{
1000
1292
  selector: 'ax-text-editor-blocks',
1001
1293
  template: `
1002
- <ax-text-editor-command command="codeBlock" icon="ax-icon-code-block" label="Code block" />
1003
- <ax-text-editor-command command="horizontalRule" icon="ax-icon-horizontal-rule" label="Horizontal rule" />
1294
+ <ax-text-editor-command command="codeBlock" icon="ax-icon-code-block" [label]="i18n.tools.codeBlock" />
1295
+ <ax-text-editor-command command="horizontalRule" icon="ax-icon-horizontal-rule" [label]="i18n.tools.horizontalRule" />
1004
1296
  `,
1005
1297
  changeDetection: ChangeDetectionStrategy.OnPush,
1006
1298
  encapsulation: ViewEncapsulation.None,
@@ -1016,6 +1308,7 @@ class AXTextEditorColorSwatchesComponent extends AXTextEditorSlot {
1016
1308
  constructor() {
1017
1309
  super(...arguments);
1018
1310
  this.editorService = inject(AXTextEditorService);
1311
+ this.i18n = AX_TEXT_EDITOR_I18N;
1019
1312
  this.textColors = input([], /* @ts-ignore */
1020
1313
  ...(ngDevMode ? [{ debugName: "textColors" }] : /* istanbul ignore next */ []));
1021
1314
  this.backgroundColors = input([], /* @ts-ignore */
@@ -1056,7 +1349,7 @@ class AXTextEditorColorSwatchesComponent extends AXTextEditorSlot {
1056
1349
  { provide: AXComponent, useExisting: AXTextEditorColorSwatchesComponent },
1057
1350
  { provide: AXTextEditorSlot, useExisting: AXTextEditorColorSwatchesComponent },
1058
1351
  ], usesInheritance: true, ngImport: i0, template: `
1059
- <ax-dropdown-button class="ax-sm" look="blank" mode="dropdown" [iconOnly]="true" text="Colors">
1352
+ <ax-dropdown-button class="ax-sm" look="blank" mode="dropdown" [iconOnly]="true" [text]="i18n.tools.colors">
1060
1353
  <ax-prefix>
1061
1354
  <span
1062
1355
  class="ax-text-editor-swatches-trigger"
@@ -1069,7 +1362,7 @@ class AXTextEditorColorSwatchesComponent extends AXTextEditorSlot {
1069
1362
  <div class="ax-text-editor-swatches-panel" (click)="$event.stopPropagation()" (mousedown)="$event.stopPropagation()">
1070
1363
  @if (recentColors().length) {
1071
1364
  <div class="ax-text-editor-swatches-section">
1072
- <div class="ax-text-editor-swatches-title">Recently Used</div>
1365
+ <div class="ax-text-editor-swatches-title">{{ i18n.swatches.recent | translate | async }}</div>
1073
1366
  <div class="ax-text-editor-swatches-row">
1074
1367
  @for (item of recentColors(); track item.kind + item.color) {
1075
1368
  <button
@@ -1090,7 +1383,7 @@ class AXTextEditorColorSwatchesComponent extends AXTextEditorSlot {
1090
1383
  </div>
1091
1384
  }
1092
1385
  <div class="ax-text-editor-swatches-section">
1093
- <div class="ax-text-editor-swatches-title">Text Color</div>
1386
+ <div class="ax-text-editor-swatches-title">{{ i18n.swatches.text | translate | async }}</div>
1094
1387
  <div class="ax-text-editor-swatches-row">
1095
1388
  @for (color of resolvedTextColors(); track color) {
1096
1389
  <button
@@ -1106,7 +1399,7 @@ class AXTextEditorColorSwatchesComponent extends AXTextEditorSlot {
1106
1399
  </div>
1107
1400
  </div>
1108
1401
  <div class="ax-text-editor-swatches-section">
1109
- <div class="ax-text-editor-swatches-title">Highlight Color</div>
1402
+ <div class="ax-text-editor-swatches-title">{{ i18n.swatches.highlight | translate | async }}</div>
1110
1403
  <div class="ax-text-editor-swatches-row">
1111
1404
  @for (color of resolvedBackgroundColors(); track color) {
1112
1405
  <button
@@ -1122,12 +1415,12 @@ class AXTextEditorColorSwatchesComponent extends AXTextEditorSlot {
1122
1415
  </div>
1123
1416
  </div>
1124
1417
  </ax-dropdown-button>
1125
- `, isInline: true, styles: ["@layer properties;@layer components{ax-text-editor-color-swatches{position:relative;z-index:20;display:inline-flex;align-items:center}.ax-text-editor-swatches-trigger{display:inline-flex;height:calc(var(--spacing, .25rem) * 6);width:calc(var(--spacing, .25rem) * 6);align-items:center;justify-content:center;border-radius:var(--radius-sm, .25rem);font-size:var(--text-sm, .875rem);line-height:var(--tw-leading, var(--text-sm--line-height, calc(1.25 / .875)));--tw-font-weight: var(--font-weight-semibold, 600);font-weight:var(--font-weight-semibold, 600)}ax-text-editor-color-swatches ax-dropdown-button ax-suffix{display:none}.ax-overlay-pane:has(.ax-text-editor-swatches-panel){width:max-content;min-width:0}.ax-text-editor-swatches-panel{display:flex;width:max-content;flex-direction:column;gap:12px;padding:12px}.ax-text-editor-swatches-section{display:flex;flex-direction:column;gap:8px}.ax-text-editor-swatches-title{font-size:13px;font-weight:500;line-height:1.25;color:#374151}.ax-text-editor-swatches-row{display:grid;grid-template-columns:repeat(4,28px);gap:8px 10px}.ax-text-editor-swatch{display:inline-flex;width:28px;height:28px;flex-shrink:0;cursor:pointer;align-items:center;justify-content:center;padding:0;border:1px solid transparent;border-radius:9999px;background:transparent}.ax-text-editor-swatch-letter{border-color:#d1d5db;background:#fff;font-size:13px;font-weight:600;line-height:1}.ax-text-editor-swatch-dot{border-color:#e5e7eb}.ax-text-editor-swatch.ax-state-selected{box-shadow:0 0 0 2px var(--ax-sys-color-primary, #8b5cf6)}}@property --tw-font-weight{syntax: \"*\"; inherits: false;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-font-weight: initial}}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "component", type: AXDropdownButtonComponent, selector: "ax-dropdown-button", inputs: ["disabled", "size", "text", "selected", "color", "look", "type", "mode", "iconOnly"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "lookChange", "colorChange", "disabledChange"] }, { kind: "component", type: AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title, ax-subtitle, ax-placeholder, ax-overlay" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
1418
+ `, isInline: true, styles: ["@layer properties;@layer components{ax-text-editor-color-swatches{position:relative;z-index:20;display:inline-flex;align-items:center}.ax-text-editor-swatches-trigger{display:inline-flex;height:calc(var(--spacing, .25rem) * 6);width:calc(var(--spacing, .25rem) * 6);align-items:center;justify-content:center;border-radius:var(--radius-sm, .25rem);font-size:var(--text-sm, .875rem);line-height:var(--tw-leading, var(--text-sm--line-height, calc(1.25 / .875)));--tw-font-weight: var(--font-weight-semibold, 600);font-weight:var(--font-weight-semibold, 600)}ax-text-editor-color-swatches ax-dropdown-button ax-suffix{display:none}.ax-overlay-pane:has(.ax-text-editor-swatches-panel){width:max-content;min-width:0}.ax-text-editor-swatches-panel{display:flex;width:max-content;flex-direction:column;gap:12px;padding:12px}.ax-text-editor-swatches-section{display:flex;flex-direction:column;gap:8px}.ax-text-editor-swatches-title{font-size:13px;font-weight:500;line-height:1.25;color:#374151}.ax-text-editor-swatches-row{display:grid;grid-template-columns:repeat(4,28px);gap:8px 10px}.ax-text-editor-swatch{display:inline-flex;width:28px;height:28px;flex-shrink:0;cursor:pointer;align-items:center;justify-content:center;padding:0;border:1px solid transparent;border-radius:9999px;background:transparent}.ax-text-editor-swatch-letter{border-color:#d1d5db;background:#fff;font-size:13px;font-weight:600;line-height:1}.ax-text-editor-swatch-dot{border-color:#e5e7eb}.ax-text-editor-swatch.ax-state-selected{box-shadow:0 0 0 2px var(--ax-sys-color-primary, #8b5cf6)}}@property --tw-font-weight{syntax: \"*\"; inherits: false;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-font-weight: initial}}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "component", type: AXDropdownButtonComponent, selector: "ax-dropdown-button", inputs: ["disabled", "size", "text", "selected", "color", "look", "type", "mode", "iconOnly"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "lookChange", "colorChange", "disabledChange"] }, { kind: "component", type: AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title, ax-subtitle, ax-placeholder, ax-overlay" }, { kind: "pipe", type: AXTranslatorPipe, name: "translate" }, { kind: "pipe", type: AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
1126
1419
  }
1127
1420
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorColorSwatchesComponent, decorators: [{
1128
1421
  type: Component,
1129
1422
  args: [{ selector: 'ax-text-editor-color-swatches', template: `
1130
- <ax-dropdown-button class="ax-sm" look="blank" mode="dropdown" [iconOnly]="true" text="Colors">
1423
+ <ax-dropdown-button class="ax-sm" look="blank" mode="dropdown" [iconOnly]="true" [text]="i18n.tools.colors">
1131
1424
  <ax-prefix>
1132
1425
  <span
1133
1426
  class="ax-text-editor-swatches-trigger"
@@ -1140,7 +1433,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1140
1433
  <div class="ax-text-editor-swatches-panel" (click)="$event.stopPropagation()" (mousedown)="$event.stopPropagation()">
1141
1434
  @if (recentColors().length) {
1142
1435
  <div class="ax-text-editor-swatches-section">
1143
- <div class="ax-text-editor-swatches-title">Recently Used</div>
1436
+ <div class="ax-text-editor-swatches-title">{{ i18n.swatches.recent | translate | async }}</div>
1144
1437
  <div class="ax-text-editor-swatches-row">
1145
1438
  @for (item of recentColors(); track item.kind + item.color) {
1146
1439
  <button
@@ -1161,7 +1454,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1161
1454
  </div>
1162
1455
  }
1163
1456
  <div class="ax-text-editor-swatches-section">
1164
- <div class="ax-text-editor-swatches-title">Text Color</div>
1457
+ <div class="ax-text-editor-swatches-title">{{ i18n.swatches.text | translate | async }}</div>
1165
1458
  <div class="ax-text-editor-swatches-row">
1166
1459
  @for (color of resolvedTextColors(); track color) {
1167
1460
  <button
@@ -1177,7 +1470,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1177
1470
  </div>
1178
1471
  </div>
1179
1472
  <div class="ax-text-editor-swatches-section">
1180
- <div class="ax-text-editor-swatches-title">Highlight Color</div>
1473
+ <div class="ax-text-editor-swatches-title">{{ i18n.swatches.highlight | translate | async }}</div>
1181
1474
  <div class="ax-text-editor-swatches-row">
1182
1475
  @for (color of resolvedBackgroundColors(); track color) {
1183
1476
  <button
@@ -1193,7 +1486,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1193
1486
  </div>
1194
1487
  </div>
1195
1488
  </ax-dropdown-button>
1196
- `, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, imports: [AXDropdownButtonComponent, AXDecoratorGenericComponent], providers: [
1489
+ `, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, imports: [AXDropdownButtonComponent, AXDecoratorGenericComponent, AXTranslatorPipe, AsyncPipe], providers: [
1197
1490
  { provide: AXComponent, useExisting: AXTextEditorColorSwatchesComponent },
1198
1491
  { provide: AXTextEditorSlot, useExisting: AXTextEditorColorSwatchesComponent },
1199
1492
  ], styles: ["@layer properties;@layer components{ax-text-editor-color-swatches{position:relative;z-index:20;display:inline-flex;align-items:center}.ax-text-editor-swatches-trigger{display:inline-flex;height:calc(var(--spacing, .25rem) * 6);width:calc(var(--spacing, .25rem) * 6);align-items:center;justify-content:center;border-radius:var(--radius-sm, .25rem);font-size:var(--text-sm, .875rem);line-height:var(--tw-leading, var(--text-sm--line-height, calc(1.25 / .875)));--tw-font-weight: var(--font-weight-semibold, 600);font-weight:var(--font-weight-semibold, 600)}ax-text-editor-color-swatches ax-dropdown-button ax-suffix{display:none}.ax-overlay-pane:has(.ax-text-editor-swatches-panel){width:max-content;min-width:0}.ax-text-editor-swatches-panel{display:flex;width:max-content;flex-direction:column;gap:12px;padding:12px}.ax-text-editor-swatches-section{display:flex;flex-direction:column;gap:8px}.ax-text-editor-swatches-title{font-size:13px;font-weight:500;line-height:1.25;color:#374151}.ax-text-editor-swatches-row{display:grid;grid-template-columns:repeat(4,28px);gap:8px 10px}.ax-text-editor-swatch{display:inline-flex;width:28px;height:28px;flex-shrink:0;cursor:pointer;align-items:center;justify-content:center;padding:0;border:1px solid transparent;border-radius:9999px;background:transparent}.ax-text-editor-swatch-letter{border-color:#d1d5db;background:#fff;font-size:13px;font-weight:600;line-height:1}.ax-text-editor-swatch-dot{border-color:#e5e7eb}.ax-text-editor-swatch.ax-state-selected{box-shadow:0 0 0 2px var(--ax-sys-color-primary, #8b5cf6)}}@property --tw-font-weight{syntax: \"*\"; inherits: false;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-font-weight: initial}}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"] }]
@@ -1206,6 +1499,7 @@ class AXTextEditorColorsComponent extends AXTextEditorSlot {
1206
1499
  constructor() {
1207
1500
  super(...arguments);
1208
1501
  this.editorService = inject(AXTextEditorService);
1502
+ this.i18n = AX_TEXT_EDITOR_I18N;
1209
1503
  }
1210
1504
  setColor(color) {
1211
1505
  if (color)
@@ -1224,7 +1518,7 @@ class AXTextEditorColorsComponent extends AXTextEditorSlot {
1224
1518
  { provide: AXComponent, useExisting: AXTextEditorColorsComponent },
1225
1519
  { provide: AXTextEditorSlot, useExisting: AXTextEditorColorsComponent },
1226
1520
  ], usesInheritance: true, ngImport: i0, template: `
1227
- <ax-dropdown-button class="ax-sm" look="blank" mode="dropdown" [iconOnly]="true" text="Text color">
1521
+ <ax-dropdown-button class="ax-sm" look="blank" mode="dropdown" [iconOnly]="true" [text]="i18n.tools.textColor">
1228
1522
  <ax-prefix class="ax-text-editor-color-trigger">
1229
1523
  <ax-icon class="ax-icon ax-icon-color-palette"></ax-icon>
1230
1524
  <ax-badge
@@ -1245,7 +1539,7 @@ class AXTextEditorColorsComponent extends AXTextEditorSlot {
1245
1539
  </ax-color-palette>
1246
1540
  </ax-dropdown-button>
1247
1541
 
1248
- <ax-dropdown-button class="ax-sm" look="blank" mode="dropdown" [iconOnly]="true" text="Highlight">
1542
+ <ax-dropdown-button class="ax-sm" look="blank" mode="dropdown" [iconOnly]="true" [text]="i18n.tools.highlight">
1249
1543
  <ax-prefix class="ax-text-editor-color-trigger">
1250
1544
  <ax-icon class="ax-icon ax-icon-highlight"></ax-icon>
1251
1545
  <ax-badge
@@ -1270,7 +1564,7 @@ class AXTextEditorColorsComponent extends AXTextEditorSlot {
1270
1564
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorColorsComponent, decorators: [{
1271
1565
  type: Component,
1272
1566
  args: [{ selector: 'ax-text-editor-colors', template: `
1273
- <ax-dropdown-button class="ax-sm" look="blank" mode="dropdown" [iconOnly]="true" text="Text color">
1567
+ <ax-dropdown-button class="ax-sm" look="blank" mode="dropdown" [iconOnly]="true" [text]="i18n.tools.textColor">
1274
1568
  <ax-prefix class="ax-text-editor-color-trigger">
1275
1569
  <ax-icon class="ax-icon ax-icon-color-palette"></ax-icon>
1276
1570
  <ax-badge
@@ -1291,7 +1585,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1291
1585
  </ax-color-palette>
1292
1586
  </ax-dropdown-button>
1293
1587
 
1294
- <ax-dropdown-button class="ax-sm" look="blank" mode="dropdown" [iconOnly]="true" text="Highlight">
1588
+ <ax-dropdown-button class="ax-sm" look="blank" mode="dropdown" [iconOnly]="true" [text]="i18n.tools.highlight">
1295
1589
  <ax-prefix class="ax-text-editor-color-trigger">
1296
1590
  <ax-icon class="ax-icon ax-icon-highlight"></ax-icon>
1297
1591
  <ax-badge
@@ -1328,16 +1622,20 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1328
1622
  }] });
1329
1623
 
1330
1624
  class AXTextEditorFontStyleComponent extends AXTextEditorSlot {
1625
+ constructor() {
1626
+ super(...arguments);
1627
+ this.i18n = AX_TEXT_EDITOR_I18N;
1628
+ }
1331
1629
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorFontStyleComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
1332
1630
  static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.1.6", type: AXTextEditorFontStyleComponent, isStandalone: true, selector: "ax-text-editor-font-style", providers: [
1333
1631
  { provide: AXComponent, useExisting: AXTextEditorFontStyleComponent },
1334
1632
  { provide: AXTextEditorSlot, useExisting: AXTextEditorFontStyleComponent },
1335
1633
  ], usesInheritance: true, ngImport: i0, template: `
1336
- <ax-text-editor-command command="bold" icon="ax-icon-bold" label="Bold" />
1337
- <ax-text-editor-command command="italic" icon="ax-icon-italic" label="Italic" />
1338
- <ax-text-editor-command command="underline" icon="ax-icon-under-line" label="Underline" />
1339
- <ax-text-editor-command command="strike" icon="ax-icon-strike" label="Strikethrough" />
1340
- <ax-text-editor-command command="code" icon="ax-icon-code" label="Code" />
1634
+ <ax-text-editor-command command="bold" icon="ax-icon-bold" [label]="i18n.tools.bold" />
1635
+ <ax-text-editor-command command="italic" icon="ax-icon-italic" [label]="i18n.tools.italic" />
1636
+ <ax-text-editor-command command="underline" icon="ax-icon-under-line" [label]="i18n.tools.underline" />
1637
+ <ax-text-editor-command command="strike" icon="ax-icon-strike" [label]="i18n.tools.strike" />
1638
+ <ax-text-editor-command command="code" icon="ax-icon-code" [label]="i18n.tools.code" />
1341
1639
  `, isInline: true, dependencies: [{ kind: "component", type: AXTextEditorCommandComponent, selector: "ax-text-editor-command", inputs: ["command", "attrs", "icon", "label"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
1342
1640
  }
1343
1641
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorFontStyleComponent, decorators: [{
@@ -1345,11 +1643,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1345
1643
  args: [{
1346
1644
  selector: 'ax-text-editor-font-style',
1347
1645
  template: `
1348
- <ax-text-editor-command command="bold" icon="ax-icon-bold" label="Bold" />
1349
- <ax-text-editor-command command="italic" icon="ax-icon-italic" label="Italic" />
1350
- <ax-text-editor-command command="underline" icon="ax-icon-under-line" label="Underline" />
1351
- <ax-text-editor-command command="strike" icon="ax-icon-strike" label="Strikethrough" />
1352
- <ax-text-editor-command command="code" icon="ax-icon-code" label="Code" />
1646
+ <ax-text-editor-command command="bold" icon="ax-icon-bold" [label]="i18n.tools.bold" />
1647
+ <ax-text-editor-command command="italic" icon="ax-icon-italic" [label]="i18n.tools.italic" />
1648
+ <ax-text-editor-command command="underline" icon="ax-icon-under-line" [label]="i18n.tools.underline" />
1649
+ <ax-text-editor-command command="strike" icon="ax-icon-strike" [label]="i18n.tools.strike" />
1650
+ <ax-text-editor-command command="code" icon="ax-icon-code" [label]="i18n.tools.code" />
1353
1651
  `,
1354
1652
  changeDetection: ChangeDetectionStrategy.OnPush,
1355
1653
  encapsulation: ViewEncapsulation.None,
@@ -1365,6 +1663,7 @@ class AXTextEditorHeadingComponent extends AXTextEditorSlot {
1365
1663
  constructor() {
1366
1664
  super(...arguments);
1367
1665
  this.editorService = inject(AXTextEditorService);
1666
+ this.i18n = AX_TEXT_EDITOR_I18N;
1368
1667
  this.editorReady = computed(() => this.editorService.editor() != null, /* @ts-ignore */
1369
1668
  ...(ngDevMode ? [{ debugName: "editorReady" }] : /* istanbul ignore next */ []));
1370
1669
  this.isParagraphSelected = computed(() => this.editorService.isActive('paragraph'), /* @ts-ignore */
@@ -1377,12 +1676,12 @@ class AXTextEditorHeadingComponent extends AXTextEditorSlot {
1377
1676
  ...(ngDevMode ? [{ debugName: "isH3" }] : /* istanbul ignore next */ []));
1378
1677
  this.currentLabel = computed(() => {
1379
1678
  if (this.isH1())
1380
- return 'H1';
1679
+ return this.i18n.blocks.heading1;
1381
1680
  if (this.isH2())
1382
- return 'H2';
1681
+ return this.i18n.blocks.heading2;
1383
1682
  if (this.isH3())
1384
- return 'H3';
1385
- return 'Paragraph';
1683
+ return this.i18n.blocks.heading3;
1684
+ return this.i18n.blocks.paragraph;
1386
1685
  }, /* @ts-ignore */
1387
1686
  ...(ngDevMode ? [{ debugName: "currentLabel" }] : /* istanbul ignore next */ []));
1388
1687
  }
@@ -1407,23 +1706,23 @@ class AXTextEditorHeadingComponent extends AXTextEditorSlot {
1407
1706
  look="blank"
1408
1707
  mode="dropdown"
1409
1708
  [iconOnly]="true"
1410
- text="Paragraph"
1709
+ [text]="i18n.blocks.paragraph"
1411
1710
  [disabled]="!editorReady()"
1412
- [attr.title]="currentLabel()"
1711
+ [attr.title]="currentLabel() | translate | async"
1413
1712
  >
1414
1713
  <ax-prefix>
1415
1714
  <ax-icon class="ax-icon ax-icon-paragraph"></ax-icon>
1416
1715
  </ax-prefix>
1417
1716
  <ax-button-item-list (mousedown)="$event.preventDefault()" (onItemClick)="onSelect($event)">
1418
- <ax-button-item text="Paragraph" [data]="{ level: null }" [selected]="isParagraphSelected()"></ax-button-item>
1419
- <ax-button-item text="Heading 1" [data]="{ level: 1 }" [selected]="isH1()"></ax-button-item>
1420
- <ax-button-item text="Heading 2" [data]="{ level: 2 }" [selected]="isH2()"></ax-button-item>
1421
- <ax-button-item text="Heading 3" [data]="{ level: 3 }" [selected]="isH3()"></ax-button-item>
1717
+ <ax-button-item [text]="i18n.blocks.paragraph" [data]="{ level: null }" [selected]="isParagraphSelected()"></ax-button-item>
1718
+ <ax-button-item [text]="i18n.blocks.heading1" [data]="{ level: 1 }" [selected]="isH1()"></ax-button-item>
1719
+ <ax-button-item [text]="i18n.blocks.heading2" [data]="{ level: 2 }" [selected]="isH2()"></ax-button-item>
1720
+ <ax-button-item [text]="i18n.blocks.heading3" [data]="{ level: 3 }" [selected]="isH3()"></ax-button-item>
1422
1721
  </ax-button-item-list>
1423
1722
  </ax-dropdown-button>
1424
- <ax-text-editor-command command="direction" [attrs]="{ direction: 'ltr' }" icon="ax-icon-ltr" label="LTR" />
1425
- <ax-text-editor-command command="direction" [attrs]="{ direction: 'rtl' }" icon="ax-icon-rtl" label="RTL" />
1426
- `, isInline: true, styles: ["ax-text-editor-heading .ax-icon-rtl{transform:scaleX(-1)}\n"], dependencies: [{ kind: "component", type: AXDropdownButtonComponent, selector: "ax-dropdown-button", inputs: ["disabled", "size", "text", "selected", "color", "look", "type", "mode", "iconOnly"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "lookChange", "colorChange", "disabledChange"] }, { kind: "component", type: AXButtonItemListComponent, selector: "ax-button-item-list", inputs: ["items", "closeParentOnClick", "lockOnLoading"], outputs: ["onItemClick"] }, { kind: "component", type: AXButtonItemComponent, selector: "ax-button-item", inputs: ["color", "disabled", "text", "selected", "divided", "data", "name"], outputs: ["onClick", "onFocus", "onBlur", "disabledChange"] }, { kind: "component", type: AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title, ax-subtitle, ax-placeholder, ax-overlay" }, { kind: "component", type: AXTextEditorCommandComponent, selector: "ax-text-editor-command", inputs: ["command", "attrs", "icon", "label"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
1723
+ <ax-text-editor-command command="direction" [attrs]="{ direction: 'ltr' }" icon="ax-icon-ltr" [label]="i18n.tools.ltr" />
1724
+ <ax-text-editor-command command="direction" [attrs]="{ direction: 'rtl' }" icon="ax-icon-rtl" [label]="i18n.tools.rtl" />
1725
+ `, isInline: true, styles: ["ax-text-editor-heading .ax-icon-rtl{transform:scaleX(-1)}\n"], dependencies: [{ kind: "component", type: AXDropdownButtonComponent, selector: "ax-dropdown-button", inputs: ["disabled", "size", "text", "selected", "color", "look", "type", "mode", "iconOnly"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "lookChange", "colorChange", "disabledChange"] }, { kind: "component", type: AXButtonItemListComponent, selector: "ax-button-item-list", inputs: ["items", "closeParentOnClick", "lockOnLoading"], outputs: ["onItemClick"] }, { kind: "component", type: AXButtonItemComponent, selector: "ax-button-item", inputs: ["color", "disabled", "text", "selected", "divided", "data", "name"], outputs: ["onClick", "onFocus", "onBlur", "disabledChange"] }, { kind: "component", type: AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title, ax-subtitle, ax-placeholder, ax-overlay" }, { kind: "component", type: AXTextEditorCommandComponent, selector: "ax-text-editor-command", inputs: ["command", "attrs", "icon", "label"] }, { kind: "pipe", type: AXTranslatorPipe, name: "translate" }, { kind: "pipe", type: AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
1427
1726
  }
1428
1727
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorHeadingComponent, decorators: [{
1429
1728
  type: Component,
@@ -1433,22 +1732,22 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1433
1732
  look="blank"
1434
1733
  mode="dropdown"
1435
1734
  [iconOnly]="true"
1436
- text="Paragraph"
1735
+ [text]="i18n.blocks.paragraph"
1437
1736
  [disabled]="!editorReady()"
1438
- [attr.title]="currentLabel()"
1737
+ [attr.title]="currentLabel() | translate | async"
1439
1738
  >
1440
1739
  <ax-prefix>
1441
1740
  <ax-icon class="ax-icon ax-icon-paragraph"></ax-icon>
1442
1741
  </ax-prefix>
1443
1742
  <ax-button-item-list (mousedown)="$event.preventDefault()" (onItemClick)="onSelect($event)">
1444
- <ax-button-item text="Paragraph" [data]="{ level: null }" [selected]="isParagraphSelected()"></ax-button-item>
1445
- <ax-button-item text="Heading 1" [data]="{ level: 1 }" [selected]="isH1()"></ax-button-item>
1446
- <ax-button-item text="Heading 2" [data]="{ level: 2 }" [selected]="isH2()"></ax-button-item>
1447
- <ax-button-item text="Heading 3" [data]="{ level: 3 }" [selected]="isH3()"></ax-button-item>
1743
+ <ax-button-item [text]="i18n.blocks.paragraph" [data]="{ level: null }" [selected]="isParagraphSelected()"></ax-button-item>
1744
+ <ax-button-item [text]="i18n.blocks.heading1" [data]="{ level: 1 }" [selected]="isH1()"></ax-button-item>
1745
+ <ax-button-item [text]="i18n.blocks.heading2" [data]="{ level: 2 }" [selected]="isH2()"></ax-button-item>
1746
+ <ax-button-item [text]="i18n.blocks.heading3" [data]="{ level: 3 }" [selected]="isH3()"></ax-button-item>
1448
1747
  </ax-button-item-list>
1449
1748
  </ax-dropdown-button>
1450
- <ax-text-editor-command command="direction" [attrs]="{ direction: 'ltr' }" icon="ax-icon-ltr" label="LTR" />
1451
- <ax-text-editor-command command="direction" [attrs]="{ direction: 'rtl' }" icon="ax-icon-rtl" label="RTL" />
1749
+ <ax-text-editor-command command="direction" [attrs]="{ direction: 'ltr' }" icon="ax-icon-ltr" [label]="i18n.tools.ltr" />
1750
+ <ax-text-editor-command command="direction" [attrs]="{ direction: 'rtl' }" icon="ax-icon-rtl" [label]="i18n.tools.rtl" />
1452
1751
  `, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, imports: [
1453
1752
  AXDropdownButtonComponent,
1454
1753
  AXButtonItemListComponent,
@@ -1456,6 +1755,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1456
1755
  AXDecoratorIconComponent,
1457
1756
  AXDecoratorGenericComponent,
1458
1757
  AXTextEditorCommandComponent,
1758
+ AXTranslatorPipe,
1759
+ AsyncPipe,
1459
1760
  ], providers: [
1460
1761
  { provide: AXComponent, useExisting: AXTextEditorHeadingComponent },
1461
1762
  { provide: AXTextEditorSlot, useExisting: AXTextEditorHeadingComponent },
@@ -1463,13 +1764,17 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1463
1764
  }] });
1464
1765
 
1465
1766
  class AXTextEditorHistoryComponent extends AXTextEditorSlot {
1767
+ constructor() {
1768
+ super(...arguments);
1769
+ this.i18n = AX_TEXT_EDITOR_I18N;
1770
+ }
1466
1771
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorHistoryComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
1467
1772
  static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.1.6", type: AXTextEditorHistoryComponent, isStandalone: true, selector: "ax-text-editor-history", providers: [
1468
1773
  { provide: AXComponent, useExisting: AXTextEditorHistoryComponent },
1469
1774
  { provide: AXTextEditorSlot, useExisting: AXTextEditorHistoryComponent },
1470
1775
  ], usesInheritance: true, ngImport: i0, template: `
1471
- <ax-text-editor-command command="undo" icon="ax-icon-undo" label="Undo" />
1472
- <ax-text-editor-command command="redo" icon="ax-icon-redo" label="Redo" />
1776
+ <ax-text-editor-command command="undo" icon="ax-icon-undo" [label]="i18n.tools.undo" />
1777
+ <ax-text-editor-command command="redo" icon="ax-icon-redo" [label]="i18n.tools.redo" />
1473
1778
  `, isInline: true, dependencies: [{ kind: "component", type: AXTextEditorCommandComponent, selector: "ax-text-editor-command", inputs: ["command", "attrs", "icon", "label"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
1474
1779
  }
1475
1780
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorHistoryComponent, decorators: [{
@@ -1477,8 +1782,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1477
1782
  args: [{
1478
1783
  selector: 'ax-text-editor-history',
1479
1784
  template: `
1480
- <ax-text-editor-command command="undo" icon="ax-icon-undo" label="Undo" />
1481
- <ax-text-editor-command command="redo" icon="ax-icon-redo" label="Redo" />
1785
+ <ax-text-editor-command command="undo" icon="ax-icon-undo" [label]="i18n.tools.undo" />
1786
+ <ax-text-editor-command command="redo" icon="ax-icon-redo" [label]="i18n.tools.redo" />
1482
1787
  `,
1483
1788
  changeDetection: ChangeDetectionStrategy.OnPush,
1484
1789
  encapsulation: ViewEncapsulation.None,
@@ -1494,6 +1799,7 @@ class AXTextEditorLinkComponent extends AXTextEditorSlot {
1494
1799
  constructor() {
1495
1800
  super(...arguments);
1496
1801
  this.editorService = inject(AXTextEditorService);
1802
+ this.i18n = AX_TEXT_EDITOR_I18N;
1497
1803
  this.dropdown = viewChild('dropdown', /* @ts-ignore */
1498
1804
  ...(ngDevMode ? [{ debugName: "dropdown" }] : /* istanbul ignore next */ []));
1499
1805
  this.href = signal('', /* @ts-ignore */
@@ -1538,9 +1844,9 @@ class AXTextEditorLinkComponent extends AXTextEditorSlot {
1538
1844
  look="blank"
1539
1845
  mode="dropdown"
1540
1846
  [iconOnly]="true"
1541
- text="Link"
1847
+ [text]="i18n.tools.link"
1542
1848
  [selected]="active()"
1543
- [attr.title]="'Link'"
1849
+ [attr.title]="i18n.tools.link"
1544
1850
  (onClick)="syncHref()"
1545
1851
  >
1546
1852
  <ax-prefix>
@@ -1555,8 +1861,8 @@ class AXTextEditorLinkComponent extends AXTextEditorSlot {
1555
1861
  (ngModelChange)="href.set($event)"
1556
1862
  (keydown.enter)="apply(); $event.preventDefault()"
1557
1863
  />
1558
- <ax-button class="ax-xs" look="solid" color="primary" text="Apply" (onClick)="apply()"></ax-button>
1559
- <ax-button class="ax-xs" look="blank" text="Remove" (onClick)="remove()"></ax-button>
1864
+ <ax-button class="ax-xs" look="solid" color="primary" [text]="i18n.insert.apply" (onClick)="apply()"></ax-button>
1865
+ <ax-button class="ax-xs" look="blank" [text]="i18n.insert.remove" (onClick)="remove()"></ax-button>
1560
1866
  </div>
1561
1867
  </ax-dropdown-button>
1562
1868
  `, isInline: true, styles: ["@layer properties;@layer components{.ax-text-editor-link-panel{display:flex;align-items:center;gap:calc(var(--spacing, .25rem) * 1);border-radius:var(--ax-sys-border-radius);background-color:rgba(var(--ax-sys-color-lightest-surface));padding:calc(var(--spacing, .25rem) * 2);--tw-shadow: 0 10px 15px -3px var(--tw-shadow-color, rgb(0 0 0 / .1)), 0 4px 6px -4px var(--tw-shadow-color, rgb(0 0 0 / .1));box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.ax-text-editor-link-input{min-width:calc(var(--spacing, .25rem) * 40);border-radius:var(--ax-sys-border-radius);border-style:var(--tw-border-style);border-width:1px;border-color:rgba(var(--ax-sys-color-border-lightest-surface));background-color:transparent;padding-inline:calc(var(--spacing, .25rem) * 2);padding-block:calc(var(--spacing, .25rem) * 1);font-size:var(--text-sm, .875rem);line-height:var(--tw-leading, var(--text-sm--line-height, calc(1.25 / .875)));--tw-outline-style: none;outline-style:none}}@property --tw-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-shadow-color{syntax: \"*\"; inherits: false;}@property --tw-shadow-alpha{syntax: \"<percentage>\"; inherits: false; initial-value: 100%;}@property --tw-inset-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-inset-shadow-color{syntax: \"*\"; inherits: false;}@property --tw-inset-shadow-alpha{syntax: \"<percentage>\"; inherits: false; initial-value: 100%;}@property --tw-ring-color{syntax: \"*\"; inherits: false;}@property --tw-ring-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-inset-ring-color{syntax: \"*\"; inherits: false;}@property --tw-inset-ring-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-ring-inset{syntax: \"*\"; inherits: false;}@property --tw-ring-offset-width{syntax: \"<length>\"; inherits: false; initial-value: 0px;}@property --tw-ring-offset-color{syntax: \"*\"; inherits: false; initial-value: #fff;}@property --tw-ring-offset-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-border-style{syntax: \"*\"; inherits: false; initial-value: solid;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-shadow: 0 0 #0000;--tw-shadow-color: initial;--tw-shadow-alpha: 100%;--tw-inset-shadow: 0 0 #0000;--tw-inset-shadow-color: initial;--tw-inset-shadow-alpha: 100%;--tw-ring-color: initial;--tw-ring-shadow: 0 0 #0000;--tw-inset-ring-color: initial;--tw-inset-ring-shadow: 0 0 #0000;--tw-ring-inset: initial;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-offset-shadow: 0 0 #0000;--tw-border-style: solid}}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "component", type: AXDropdownButtonComponent, selector: "ax-dropdown-button", inputs: ["disabled", "size", "text", "selected", "color", "look", "type", "mode", "iconOnly"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "lookChange", "colorChange", "disabledChange"] }, { kind: "component", type: AXButtonComponent, selector: "ax-button", inputs: ["disabled", "tabIndex", "color", "look", "text", "toggleable", "selected", "iconOnly", "type", "loadingText"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange", "loadingTextChange"] }, { kind: "component", type: AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title, ax-subtitle, ax-placeholder, ax-overlay" }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox]):not([ngNoCva])[formControlName],textarea:not([ngNoCva])[formControlName],input:not([type=checkbox]):not([ngNoCva])[formControl],textarea:not([ngNoCva])[formControl],input:not([type=checkbox]):not([ngNoCva])[ngModel],textarea:not([ngNoCva])[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
@@ -1570,9 +1876,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1570
1876
  look="blank"
1571
1877
  mode="dropdown"
1572
1878
  [iconOnly]="true"
1573
- text="Link"
1879
+ [text]="i18n.tools.link"
1574
1880
  [selected]="active()"
1575
- [attr.title]="'Link'"
1881
+ [attr.title]="i18n.tools.link"
1576
1882
  (onClick)="syncHref()"
1577
1883
  >
1578
1884
  <ax-prefix>
@@ -1587,8 +1893,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1587
1893
  (ngModelChange)="href.set($event)"
1588
1894
  (keydown.enter)="apply(); $event.preventDefault()"
1589
1895
  />
1590
- <ax-button class="ax-xs" look="solid" color="primary" text="Apply" (onClick)="apply()"></ax-button>
1591
- <ax-button class="ax-xs" look="blank" text="Remove" (onClick)="remove()"></ax-button>
1896
+ <ax-button class="ax-xs" look="solid" color="primary" [text]="i18n.insert.apply" (onClick)="apply()"></ax-button>
1897
+ <ax-button class="ax-xs" look="blank" [text]="i18n.insert.remove" (onClick)="remove()"></ax-button>
1592
1898
  </div>
1593
1899
  </ax-dropdown-button>
1594
1900
  `, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, imports: [
@@ -1604,13 +1910,17 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1604
1910
  }], propDecorators: { dropdown: [{ type: i0.ViewChild, args: ['dropdown', { isSignal: true }] }] } });
1605
1911
 
1606
1912
  class AXTextEditorListComponent extends AXTextEditorSlot {
1913
+ constructor() {
1914
+ super(...arguments);
1915
+ this.i18n = AX_TEXT_EDITOR_I18N;
1916
+ }
1607
1917
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorListComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
1608
1918
  static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.1.6", type: AXTextEditorListComponent, isStandalone: true, selector: "ax-text-editor-list", providers: [
1609
1919
  { provide: AXComponent, useExisting: AXTextEditorListComponent },
1610
1920
  { provide: AXTextEditorSlot, useExisting: AXTextEditorListComponent },
1611
1921
  ], usesInheritance: true, ngImport: i0, template: `
1612
- <ax-text-editor-command command="bulletList" icon="ax-icon-un-order-list" label="Bullet list" />
1613
- <ax-text-editor-command command="orderedList" icon="ax-icon-order-list" label="Ordered list" />
1922
+ <ax-text-editor-command command="bulletList" icon="ax-icon-un-order-list" [label]="i18n.tools.bulletList" />
1923
+ <ax-text-editor-command command="orderedList" icon="ax-icon-order-list" [label]="i18n.tools.orderedList" />
1614
1924
  `, isInline: true, dependencies: [{ kind: "component", type: AXTextEditorCommandComponent, selector: "ax-text-editor-command", inputs: ["command", "attrs", "icon", "label"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
1615
1925
  }
1616
1926
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorListComponent, decorators: [{
@@ -1618,8 +1928,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1618
1928
  args: [{
1619
1929
  selector: 'ax-text-editor-list',
1620
1930
  template: `
1621
- <ax-text-editor-command command="bulletList" icon="ax-icon-un-order-list" label="Bullet list" />
1622
- <ax-text-editor-command command="orderedList" icon="ax-icon-order-list" label="Ordered list" />
1931
+ <ax-text-editor-command command="bulletList" icon="ax-icon-un-order-list" [label]="i18n.tools.bulletList" />
1932
+ <ax-text-editor-command command="orderedList" icon="ax-icon-order-list" [label]="i18n.tools.orderedList" />
1623
1933
  `,
1624
1934
  changeDetection: ChangeDetectionStrategy.OnPush,
1625
1935
  encapsulation: ViewEncapsulation.None,
@@ -1637,12 +1947,13 @@ class AXTextEditorTableComponent extends AXTextEditorSlot {
1637
1947
  this.editorService = inject(AXTextEditorService);
1638
1948
  this.dropdown = viewChild('dropdown', /* @ts-ignore */
1639
1949
  ...(ngDevMode ? [{ debugName: "dropdown" }] : /* istanbul ignore next */ []));
1950
+ this.i18n = AX_TEXT_EDITOR_I18N;
1640
1951
  this.cells = [1, 2, 3, 4, 5, 6, 7, 8];
1641
1952
  this.hover = signal({ rows: 0, cols: 0 }, /* @ts-ignore */
1642
1953
  ...(ngDevMode ? [{ debugName: "hover" }] : /* istanbul ignore next */ []));
1643
1954
  this.sizeLabel = computed(() => {
1644
1955
  const { rows, cols } = this.hover();
1645
- return rows && cols ? `${rows} × ${cols}` : 'Insert table';
1956
+ return rows && cols ? `${rows} × ${cols}` : this.i18n.table.insert;
1646
1957
  }, /* @ts-ignore */
1647
1958
  ...(ngDevMode ? [{ debugName: "sizeLabel" }] : /* istanbul ignore next */ []));
1648
1959
  }
@@ -1659,7 +1970,7 @@ class AXTextEditorTableComponent extends AXTextEditorSlot {
1659
1970
  { provide: AXComponent, useExisting: AXTextEditorTableComponent },
1660
1971
  { provide: AXTextEditorSlot, useExisting: AXTextEditorTableComponent },
1661
1972
  ], viewQueries: [{ propertyName: "dropdown", first: true, predicate: ["dropdown"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: `
1662
- <ax-dropdown-button #dropdown class="ax-sm" look="blank" mode="dropdown" [iconOnly]="true" text="Insert table">
1973
+ <ax-dropdown-button #dropdown class="ax-sm" look="blank" mode="dropdown" [iconOnly]="true" [text]="i18n.table.insert">
1663
1974
  <ax-prefix>
1664
1975
  <ax-icon class="ax-icon ax-icon-table"></ax-icon>
1665
1976
  </ax-prefix>
@@ -1677,15 +1988,15 @@ class AXTextEditorTableComponent extends AXTextEditorSlot {
1677
1988
  }
1678
1989
  }
1679
1990
  </div>
1680
- <div class="ax-text-editor-table-size">{{ sizeLabel() }}</div>
1991
+ <div class="ax-text-editor-table-size">{{ sizeLabel() | translate | async }}</div>
1681
1992
  </div>
1682
1993
  </ax-dropdown-button>
1683
- `, isInline: true, styles: ["@layer properties;@layer components{.ax-text-editor-table-picker{min-width:calc(var(--spacing, .25rem) * 44);padding:calc(var(--spacing, .25rem) * 2)}.ax-text-editor-table-grid{display:grid;grid-template-columns:repeat(8,1.125rem);gap:.25rem}.ax-text-editor-table-cell{width:calc(var(--spacing, .25rem) * 4);height:calc(var(--spacing, .25rem) * 4);border-radius:var(--radius-sm, .25rem);border-style:var(--tw-border-style);border-width:1px;border-color:rgba(var(--ax-sys-color-border-lightest-surface));background-color:rgba(var(--ax-sys-color-lightest-surface));padding:calc(var(--spacing, .25rem) * 0)}.ax-text-editor-table-cell.ax-state-active{border-color:var(--ax-sys-color-primary, #3b82f6);background:var(--ax-sys-color-primary, #3b82f6)}@supports (color: color-mix(in lab,red,red)){.ax-text-editor-table-cell.ax-state-active{background:color-mix(in oklab,var(--ax-sys-color-primary, #3b82f6) 18%,white)}}.ax-text-editor-table-size{margin-top:calc(var(--spacing, .25rem) * 2);text-align:center;font-size:var(--text-xs, .75rem);line-height:var(--tw-leading, var(--text-xs--line-height, calc(1 / .75)));color:currentColor}@supports (color: color-mix(in lab,red,red)){.ax-text-editor-table-size{color:color-mix(in oklab,currentColor 70%,transparent)}}}@property --tw-border-style{syntax: \"*\"; inherits: false; initial-value: solid;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style: solid}}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "component", type: AXDropdownButtonComponent, selector: "ax-dropdown-button", inputs: ["disabled", "size", "text", "selected", "color", "look", "type", "mode", "iconOnly"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "lookChange", "colorChange", "disabledChange"] }, { kind: "component", type: AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title, ax-subtitle, ax-placeholder, ax-overlay" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
1994
+ `, isInline: true, styles: ["@layer properties;@layer components{.ax-text-editor-table-picker{min-width:calc(var(--spacing, .25rem) * 44);padding:calc(var(--spacing, .25rem) * 2)}.ax-text-editor-table-grid{display:grid;grid-template-columns:repeat(8,1.125rem);gap:.25rem}.ax-text-editor-table-cell{width:calc(var(--spacing, .25rem) * 4);height:calc(var(--spacing, .25rem) * 4);border-radius:var(--radius-sm, .25rem);border-style:var(--tw-border-style);border-width:1px;border-color:rgba(var(--ax-sys-color-border-lightest-surface));background-color:rgba(var(--ax-sys-color-lightest-surface));padding:calc(var(--spacing, .25rem) * 0)}.ax-text-editor-table-cell.ax-state-active{border-color:var(--ax-sys-color-primary, #3b82f6);background:var(--ax-sys-color-primary, #3b82f6)}@supports (color: color-mix(in lab,red,red)){.ax-text-editor-table-cell.ax-state-active{background:color-mix(in oklab,var(--ax-sys-color-primary, #3b82f6) 18%,white)}}.ax-text-editor-table-size{margin-top:calc(var(--spacing, .25rem) * 2);text-align:center;font-size:var(--text-xs, .75rem);line-height:var(--tw-leading, var(--text-xs--line-height, calc(1 / .75)));color:currentColor}@supports (color: color-mix(in lab,red,red)){.ax-text-editor-table-size{color:color-mix(in oklab,currentColor 70%,transparent)}}}@property --tw-border-style{syntax: \"*\"; inherits: false; initial-value: solid;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style: solid}}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "component", type: AXDropdownButtonComponent, selector: "ax-dropdown-button", inputs: ["disabled", "size", "text", "selected", "color", "look", "type", "mode", "iconOnly"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "lookChange", "colorChange", "disabledChange"] }, { kind: "component", type: AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title, ax-subtitle, ax-placeholder, ax-overlay" }, { kind: "pipe", type: AXTranslatorPipe, name: "translate" }, { kind: "pipe", type: AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
1684
1995
  }
1685
1996
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorTableComponent, decorators: [{
1686
1997
  type: Component,
1687
1998
  args: [{ selector: 'ax-text-editor-table', template: `
1688
- <ax-dropdown-button #dropdown class="ax-sm" look="blank" mode="dropdown" [iconOnly]="true" text="Insert table">
1999
+ <ax-dropdown-button #dropdown class="ax-sm" look="blank" mode="dropdown" [iconOnly]="true" [text]="i18n.table.insert">
1689
2000
  <ax-prefix>
1690
2001
  <ax-icon class="ax-icon ax-icon-table"></ax-icon>
1691
2002
  </ax-prefix>
@@ -1703,23 +2014,27 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1703
2014
  }
1704
2015
  }
1705
2016
  </div>
1706
- <div class="ax-text-editor-table-size">{{ sizeLabel() }}</div>
2017
+ <div class="ax-text-editor-table-size">{{ sizeLabel() | translate | async }}</div>
1707
2018
  </div>
1708
2019
  </ax-dropdown-button>
1709
- `, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, imports: [AXDropdownButtonComponent, AXDecoratorIconComponent, AXDecoratorGenericComponent], providers: [
2020
+ `, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, imports: [AXDropdownButtonComponent, AXDecoratorIconComponent, AXDecoratorGenericComponent, AXTranslatorPipe, AsyncPipe], providers: [
1710
2021
  { provide: AXComponent, useExisting: AXTextEditorTableComponent },
1711
2022
  { provide: AXTextEditorSlot, useExisting: AXTextEditorTableComponent },
1712
2023
  ], styles: ["@layer properties;@layer components{.ax-text-editor-table-picker{min-width:calc(var(--spacing, .25rem) * 44);padding:calc(var(--spacing, .25rem) * 2)}.ax-text-editor-table-grid{display:grid;grid-template-columns:repeat(8,1.125rem);gap:.25rem}.ax-text-editor-table-cell{width:calc(var(--spacing, .25rem) * 4);height:calc(var(--spacing, .25rem) * 4);border-radius:var(--radius-sm, .25rem);border-style:var(--tw-border-style);border-width:1px;border-color:rgba(var(--ax-sys-color-border-lightest-surface));background-color:rgba(var(--ax-sys-color-lightest-surface));padding:calc(var(--spacing, .25rem) * 0)}.ax-text-editor-table-cell.ax-state-active{border-color:var(--ax-sys-color-primary, #3b82f6);background:var(--ax-sys-color-primary, #3b82f6)}@supports (color: color-mix(in lab,red,red)){.ax-text-editor-table-cell.ax-state-active{background:color-mix(in oklab,var(--ax-sys-color-primary, #3b82f6) 18%,white)}}.ax-text-editor-table-size{margin-top:calc(var(--spacing, .25rem) * 2);text-align:center;font-size:var(--text-xs, .75rem);line-height:var(--tw-leading, var(--text-xs--line-height, calc(1 / .75)));color:currentColor}@supports (color: color-mix(in lab,red,red)){.ax-text-editor-table-size{color:color-mix(in oklab,currentColor 70%,transparent)}}}@property --tw-border-style{syntax: \"*\"; inherits: false; initial-value: solid;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-border-style: solid}}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"] }]
1713
2024
  }], propDecorators: { dropdown: [{ type: i0.ViewChild, args: ['dropdown', { isSignal: true }] }] } });
1714
2025
 
1715
2026
  class AXTextEditorScriptComponent extends AXTextEditorSlot {
2027
+ constructor() {
2028
+ super(...arguments);
2029
+ this.i18n = AX_TEXT_EDITOR_I18N;
2030
+ }
1716
2031
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorScriptComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
1717
2032
  static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.1.6", type: AXTextEditorScriptComponent, isStandalone: true, selector: "ax-text-editor-script", providers: [
1718
2033
  { provide: AXComponent, useExisting: AXTextEditorScriptComponent },
1719
2034
  { provide: AXTextEditorSlot, useExisting: AXTextEditorScriptComponent },
1720
2035
  ], usesInheritance: true, ngImport: i0, template: `
1721
- <ax-text-editor-command command="superscript" icon="ax-icon-superscript" label="Superscript" />
1722
- <ax-text-editor-command command="subscript" icon="ax-icon-subscript" label="Subscript" />
2036
+ <ax-text-editor-command command="superscript" icon="ax-icon-superscript" [label]="i18n.tools.superscript" />
2037
+ <ax-text-editor-command command="subscript" icon="ax-icon-subscript" [label]="i18n.tools.subscript" />
1723
2038
  `, isInline: true, dependencies: [{ kind: "component", type: AXTextEditorCommandComponent, selector: "ax-text-editor-command", inputs: ["command", "attrs", "icon", "label"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
1724
2039
  }
1725
2040
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorScriptComponent, decorators: [{
@@ -1727,8 +2042,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1727
2042
  args: [{
1728
2043
  selector: 'ax-text-editor-script',
1729
2044
  template: `
1730
- <ax-text-editor-command command="superscript" icon="ax-icon-superscript" label="Superscript" />
1731
- <ax-text-editor-command command="subscript" icon="ax-icon-subscript" label="Subscript" />
2045
+ <ax-text-editor-command command="superscript" icon="ax-icon-superscript" [label]="i18n.tools.superscript" />
2046
+ <ax-text-editor-command command="subscript" icon="ax-icon-subscript" [label]="i18n.tools.subscript" />
1732
2047
  `,
1733
2048
  changeDetection: ChangeDetectionStrategy.OnPush,
1734
2049
  encapsulation: ViewEncapsulation.None,
@@ -1744,6 +2059,7 @@ class AXTextEditorZoomComponent extends AXTextEditorSlot {
1744
2059
  constructor() {
1745
2060
  super(...arguments);
1746
2061
  this.editorService = inject(AXTextEditorService);
2062
+ this.i18n = AX_TEXT_EDITOR_I18N;
1747
2063
  this.dropdown = viewChild('dropdown', /* @ts-ignore */
1748
2064
  ...(ngDevMode ? [{ debugName: "dropdown" }] : /* istanbul ignore next */ []));
1749
2065
  this.presets = AX_TEXT_EDITOR_ZOOM_PRESETS;
@@ -1785,7 +2101,7 @@ class AXTextEditorZoomComponent extends AXTextEditorSlot {
1785
2101
  class="ax-sm"
1786
2102
  look="blank"
1787
2103
  [iconOnly]="true"
1788
- text="Zoom out"
2104
+ [text]="i18n.tools.zoomOut"
1789
2105
  [disabled]="!canZoomOut()"
1790
2106
  (onClick)="editorService.zoomOut()"
1791
2107
  >
@@ -1809,7 +2125,7 @@ class AXTextEditorZoomComponent extends AXTextEditorSlot {
1809
2125
  (keydown.enter)="commitDraft(); $event.preventDefault()"
1810
2126
  />
1811
2127
  <ax-button-item-list>
1812
- <ax-button-item text="Fit to page" (onClick)="fitToPage()">
2128
+ <ax-button-item [text]="i18n.zoom.fit" (onClick)="fitToPage()">
1813
2129
  <ax-prefix>
1814
2130
  <ax-icon class="fa-regular fa-expand"></ax-icon>
1815
2131
  </ax-prefix>
@@ -1828,7 +2144,7 @@ class AXTextEditorZoomComponent extends AXTextEditorSlot {
1828
2144
  class="ax-sm"
1829
2145
  look="blank"
1830
2146
  [iconOnly]="true"
1831
- text="Zoom in"
2147
+ [text]="i18n.tools.zoomIn"
1832
2148
  [disabled]="!canZoomIn()"
1833
2149
  (onClick)="editorService.zoomIn()"
1834
2150
  >
@@ -1843,7 +2159,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1843
2159
  class="ax-sm"
1844
2160
  look="blank"
1845
2161
  [iconOnly]="true"
1846
- text="Zoom out"
2162
+ [text]="i18n.tools.zoomOut"
1847
2163
  [disabled]="!canZoomOut()"
1848
2164
  (onClick)="editorService.zoomOut()"
1849
2165
  >
@@ -1867,7 +2183,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1867
2183
  (keydown.enter)="commitDraft(); $event.preventDefault()"
1868
2184
  />
1869
2185
  <ax-button-item-list>
1870
- <ax-button-item text="Fit to page" (onClick)="fitToPage()">
2186
+ <ax-button-item [text]="i18n.zoom.fit" (onClick)="fitToPage()">
1871
2187
  <ax-prefix>
1872
2188
  <ax-icon class="fa-regular fa-expand"></ax-icon>
1873
2189
  </ax-prefix>
@@ -1886,7 +2202,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1886
2202
  class="ax-sm"
1887
2203
  look="blank"
1888
2204
  [iconOnly]="true"
1889
- text="Zoom in"
2205
+ [text]="i18n.tools.zoomIn"
1890
2206
  [disabled]="!canZoomIn()"
1891
2207
  (onClick)="editorService.zoomIn()"
1892
2208
  >
@@ -1907,6 +2223,193 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1907
2223
  ], styles: ["@layer properties;@layer components{ax-text-editor-zoom{display:inline-flex;align-items:center}.ax-text-editor-zoom-value{min-width:calc(var(--spacing, .25rem) * 16)}.ax-text-editor-zoom-value ax-suffix,ax-text-editor-zoom ax-dropdown-button ax-suffix{display:none!important}.ax-text-editor-zoom-panel{display:flex;min-width:calc(var(--spacing, .25rem) * 44);flex-direction:column;gap:calc(var(--spacing, .25rem) * 1);border-radius:var(--ax-sys-border-radius);background-color:rgba(var(--ax-sys-color-lightest-surface));padding:calc(var(--spacing, .25rem) * 2);--tw-shadow: 0 10px 15px -3px var(--tw-shadow-color, rgb(0 0 0 / .1)), 0 4px 6px -4px var(--tw-shadow-color, rgb(0 0 0 / .1));box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.ax-text-editor-zoom-input{width:100%;border-radius:var(--ax-sys-border-radius);border-style:var(--tw-border-style);border-width:1px;border-color:rgba(var(--ax-sys-color-border-lightest-surface));background-color:transparent;padding-inline:calc(var(--spacing, .25rem) * 2);padding-block:calc(var(--spacing, .25rem) * 1);text-align:center;font-size:var(--text-sm, .875rem);line-height:var(--tw-leading, var(--text-sm--line-height, calc(1.25 / .875)));--tw-outline-style: none;outline-style:none}.ax-text-editor-zoom-input:focus{border-color:var(--ax-sys-color-primary, #8b5cf6);box-shadow:0 0 0 2px var(--ax-sys-color-primary, #8b5cf6)}@supports (color: color-mix(in lab,red,red)){.ax-text-editor-zoom-input:focus{box-shadow:0 0 0 2px color-mix(in oklab,var(--ax-sys-color-primary, #8b5cf6) 35%,transparent)}}}@property --tw-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-shadow-color{syntax: \"*\"; inherits: false;}@property --tw-shadow-alpha{syntax: \"<percentage>\"; inherits: false; initial-value: 100%;}@property --tw-inset-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-inset-shadow-color{syntax: \"*\"; inherits: false;}@property --tw-inset-shadow-alpha{syntax: \"<percentage>\"; inherits: false; initial-value: 100%;}@property --tw-ring-color{syntax: \"*\"; inherits: false;}@property --tw-ring-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-inset-ring-color{syntax: \"*\"; inherits: false;}@property --tw-inset-ring-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-ring-inset{syntax: \"*\"; inherits: false;}@property --tw-ring-offset-width{syntax: \"<length>\"; inherits: false; initial-value: 0px;}@property --tw-ring-offset-color{syntax: \"*\"; inherits: false; initial-value: #fff;}@property --tw-ring-offset-shadow{syntax: \"*\"; inherits: false; initial-value: 0 0 #0000;}@property --tw-border-style{syntax: \"*\"; inherits: false; initial-value: solid;}@layer properties{@supports ((-webkit-hyphens: none) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-shadow: 0 0 #0000;--tw-shadow-color: initial;--tw-shadow-alpha: 100%;--tw-inset-shadow: 0 0 #0000;--tw-inset-shadow-color: initial;--tw-inset-shadow-alpha: 100%;--tw-ring-color: initial;--tw-ring-shadow: 0 0 #0000;--tw-inset-ring-color: initial;--tw-inset-ring-shadow: 0 0 #0000;--tw-ring-inset: initial;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-offset-shadow: 0 0 #0000;--tw-border-style: solid}}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"] }]
1908
2224
  }], propDecorators: { dropdown: [{ type: i0.ViewChild, args: ['dropdown', { isSignal: true }] }] } });
1909
2225
 
2226
+ class AXTextEditorFontSizeComponent extends AXTextEditorSlot {
2227
+ constructor() {
2228
+ super(...arguments);
2229
+ this.editorService = inject(AXTextEditorService);
2230
+ this.translation = inject(AXTranslationService);
2231
+ this.i18n = AX_TEXT_EDITOR_I18N;
2232
+ this.sizes = AX_TEXT_EDITOR_FONT_SIZES;
2233
+ this.dropdown = viewChild('dropdown', /* @ts-ignore */
2234
+ ...(ngDevMode ? [{ debugName: "dropdown" }] : /* istanbul ignore next */ []));
2235
+ this.currentSize = computed(() => {
2236
+ const raw = this.editorService.fontSize();
2237
+ if (!raw)
2238
+ return null;
2239
+ const parsed = Number.parseInt(raw, 10);
2240
+ return Number.isFinite(parsed) ? parsed : null;
2241
+ }, /* @ts-ignore */
2242
+ ...(ngDevMode ? [{ debugName: "currentSize" }] : /* istanbul ignore next */ []));
2243
+ this.sizeLabel = computed(() => {
2244
+ const size = this.currentSize();
2245
+ return size == null ? this.translation.translateSync(this.i18n.fontSize.default) : String(size);
2246
+ }, /* @ts-ignore */
2247
+ ...(ngDevMode ? [{ debugName: "sizeLabel" }] : /* istanbul ignore next */ []));
2248
+ }
2249
+ apply(size) {
2250
+ this.editorService.run('fontSize', size == null ? undefined : { size: `${size}px` });
2251
+ this.dropdown()?.close();
2252
+ }
2253
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorFontSizeComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
2254
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.6", type: AXTextEditorFontSizeComponent, isStandalone: true, selector: "ax-text-editor-font-size", providers: [
2255
+ { provide: AXComponent, useExisting: AXTextEditorFontSizeComponent },
2256
+ { provide: AXTextEditorSlot, useExisting: AXTextEditorFontSizeComponent },
2257
+ ], viewQueries: [{ propertyName: "dropdown", first: true, predicate: ["dropdown"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: `
2258
+ <ax-dropdown-button
2259
+ #dropdown
2260
+ class="ax-sm ax-text-editor-font-size"
2261
+ look="blank"
2262
+ mode="dropdown"
2263
+ [text]="sizeLabel()"
2264
+ [attr.title]="i18n.fontSize.label | translate | async"
2265
+ [disabled]="!editorService.can('fontSize')"
2266
+ >
2267
+ <ax-button-item-list (mousedown)="$event.preventDefault()">
2268
+ <ax-button-item
2269
+ [text]="i18n.fontSize.default"
2270
+ [selected]="currentSize() == null"
2271
+ (onClick)="apply(null)"
2272
+ ></ax-button-item>
2273
+ @for (size of sizes; track size) {
2274
+ <ax-button-item [text]="'' + size" [selected]="currentSize() === size" (onClick)="apply(size)"></ax-button-item>
2275
+ }
2276
+ </ax-button-item-list>
2277
+ </ax-dropdown-button>
2278
+ `, isInline: true, styles: ["@layer components{ax-text-editor-font-size{display:inline-flex;align-items:center}ax-text-editor-font-size ax-dropdown-button{min-width:calc(var(--spacing, .25rem) * 16)}ax-text-editor-font-size ax-dropdown-button ax-suffix{display:none!important}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"], dependencies: [{ kind: "component", type: AXDropdownButtonComponent, selector: "ax-dropdown-button", inputs: ["disabled", "size", "text", "selected", "color", "look", "type", "mode", "iconOnly"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "lookChange", "colorChange", "disabledChange"] }, { kind: "component", type: AXButtonItemListComponent, selector: "ax-button-item-list", inputs: ["items", "closeParentOnClick", "lockOnLoading"], outputs: ["onItemClick"] }, { kind: "component", type: AXButtonItemComponent, selector: "ax-button-item", inputs: ["color", "disabled", "text", "selected", "divided", "data", "name"], outputs: ["onClick", "onFocus", "onBlur", "disabledChange"] }, { kind: "pipe", type: AXTranslatorPipe, name: "translate" }, { kind: "pipe", type: AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
2279
+ }
2280
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorFontSizeComponent, decorators: [{
2281
+ type: Component,
2282
+ args: [{ selector: 'ax-text-editor-font-size', template: `
2283
+ <ax-dropdown-button
2284
+ #dropdown
2285
+ class="ax-sm ax-text-editor-font-size"
2286
+ look="blank"
2287
+ mode="dropdown"
2288
+ [text]="sizeLabel()"
2289
+ [attr.title]="i18n.fontSize.label | translate | async"
2290
+ [disabled]="!editorService.can('fontSize')"
2291
+ >
2292
+ <ax-button-item-list (mousedown)="$event.preventDefault()">
2293
+ <ax-button-item
2294
+ [text]="i18n.fontSize.default"
2295
+ [selected]="currentSize() == null"
2296
+ (onClick)="apply(null)"
2297
+ ></ax-button-item>
2298
+ @for (size of sizes; track size) {
2299
+ <ax-button-item [text]="'' + size" [selected]="currentSize() === size" (onClick)="apply(size)"></ax-button-item>
2300
+ }
2301
+ </ax-button-item-list>
2302
+ </ax-dropdown-button>
2303
+ `, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, imports: [
2304
+ AXDropdownButtonComponent,
2305
+ AXButtonItemListComponent,
2306
+ AXButtonItemComponent,
2307
+ AXTranslatorPipe,
2308
+ AsyncPipe,
2309
+ ], providers: [
2310
+ { provide: AXComponent, useExisting: AXTextEditorFontSizeComponent },
2311
+ { provide: AXTextEditorSlot, useExisting: AXTextEditorFontSizeComponent },
2312
+ ], styles: ["@layer components{ax-text-editor-font-size{display:inline-flex;align-items:center}ax-text-editor-font-size ax-dropdown-button{min-width:calc(var(--spacing, .25rem) * 16)}ax-text-editor-font-size ax-dropdown-button ax-suffix{display:none!important}}\n/*! tailwindcss v4.1.16 | MIT License | https://tailwindcss.com */\n"] }]
2313
+ }], propDecorators: { dropdown: [{ type: i0.ViewChild, args: ['dropdown', { isSignal: true }] }] } });
2314
+
2315
+ class AXTextEditorMediaComponent extends AXTextEditorSlot {
2316
+ constructor() {
2317
+ super();
2318
+ this.editorService = inject(AXTextEditorService);
2319
+ this.i18n = AX_TEXT_EDITOR_I18N;
2320
+ this.fileService = inject(AXFileService);
2321
+ this.fileTypes = inject(AXFileTypeRegistryService);
2322
+ this.toast = inject(AXToastService);
2323
+ this.translation = inject(AXTranslationService);
2324
+ this.fileTypes.registerTypes([AX_IMAGE_FILE_TYPE, AX_VIDEO_FILE_TYPE]);
2325
+ }
2326
+ async pick(kind) {
2327
+ if (!this.editorService.can(kind))
2328
+ return;
2329
+ const { accepted, rejected } = await this.fileService.chooseValidated({
2330
+ fileType: kind,
2331
+ multiple: false,
2332
+ });
2333
+ if (rejected[0]?.errors[0]?.message) {
2334
+ this.toast.danger(rejected[0].errors[0].message);
2335
+ }
2336
+ else if (rejected.length) {
2337
+ this.toast.danger(this.translation.translateSync(this.i18n.insert.failed));
2338
+ }
2339
+ const file = accepted[0];
2340
+ if (!file)
2341
+ return;
2342
+ try {
2343
+ const src = await this.fileService.blobToBase64(file);
2344
+ this.editorService.run(kind, { src, alt: file.name });
2345
+ }
2346
+ catch {
2347
+ this.toast.danger(this.translation.translateSync(this.i18n.insert.failed));
2348
+ }
2349
+ }
2350
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorMediaComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
2351
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.1.6", type: AXTextEditorMediaComponent, isStandalone: true, selector: "ax-text-editor-media", providers: [
2352
+ { provide: AXComponent, useExisting: AXTextEditorMediaComponent },
2353
+ { provide: AXTextEditorSlot, useExisting: AXTextEditorMediaComponent },
2354
+ ], usesInheritance: true, ngImport: i0, template: `
2355
+ <ax-button
2356
+ class="ax-sm"
2357
+ look="blank"
2358
+ [iconOnly]="true"
2359
+ [text]="i18n.tools.image"
2360
+ [disabled]="!editorService.can('image')"
2361
+ (onClick)="pick('image')"
2362
+ >
2363
+ <ax-icon class="ax-icon ax-icon-image"></ax-icon>
2364
+ </ax-button>
2365
+ <ax-button
2366
+ class="ax-sm"
2367
+ look="blank"
2368
+ [iconOnly]="true"
2369
+ [text]="i18n.tools.video"
2370
+ [disabled]="!editorService.can('video')"
2371
+ (onClick)="pick('video')"
2372
+ >
2373
+ <ax-icon class="ax-icon ax-icon-play"></ax-icon>
2374
+ </ax-button>
2375
+ `, isInline: true, dependencies: [{ kind: "component", type: AXButtonComponent, selector: "ax-button", inputs: ["disabled", "tabIndex", "color", "look", "text", "toggleable", "selected", "iconOnly", "type", "loadingText"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange", "loadingTextChange"] }, { kind: "component", type: AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
2376
+ }
2377
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: AXTextEditorMediaComponent, decorators: [{
2378
+ type: Component,
2379
+ args: [{
2380
+ selector: 'ax-text-editor-media',
2381
+ template: `
2382
+ <ax-button
2383
+ class="ax-sm"
2384
+ look="blank"
2385
+ [iconOnly]="true"
2386
+ [text]="i18n.tools.image"
2387
+ [disabled]="!editorService.can('image')"
2388
+ (onClick)="pick('image')"
2389
+ >
2390
+ <ax-icon class="ax-icon ax-icon-image"></ax-icon>
2391
+ </ax-button>
2392
+ <ax-button
2393
+ class="ax-sm"
2394
+ look="blank"
2395
+ [iconOnly]="true"
2396
+ [text]="i18n.tools.video"
2397
+ [disabled]="!editorService.can('video')"
2398
+ (onClick)="pick('video')"
2399
+ >
2400
+ <ax-icon class="ax-icon ax-icon-play"></ax-icon>
2401
+ </ax-button>
2402
+ `,
2403
+ changeDetection: ChangeDetectionStrategy.OnPush,
2404
+ encapsulation: ViewEncapsulation.None,
2405
+ imports: [AXButtonComponent, AXDecoratorIconComponent],
2406
+ providers: [
2407
+ { provide: AXComponent, useExisting: AXTextEditorMediaComponent },
2408
+ { provide: AXTextEditorSlot, useExisting: AXTextEditorMediaComponent },
2409
+ ],
2410
+ }]
2411
+ }], ctorParameters: () => [] });
2412
+
1910
2413
  const COMPONENTS = [
1911
2414
  AXTextEditorComponent,
1912
2415
  AXTextEditorToolbarComponent,
@@ -1915,11 +2418,13 @@ const COMPONENTS = [
1915
2418
  AXTextEditorHistoryComponent,
1916
2419
  AXTextEditorHeadingComponent,
1917
2420
  AXTextEditorFontStyleComponent,
2421
+ AXTextEditorFontSizeComponent,
1918
2422
  AXTextEditorAlignmentComponent,
1919
2423
  AXTextEditorColorsComponent,
1920
2424
  AXTextEditorColorSwatchesComponent,
1921
2425
  AXTextEditorListComponent,
1922
2426
  AXTextEditorLinkComponent,
2427
+ AXTextEditorMediaComponent,
1923
2428
  AXTextEditorBlocksComponent,
1924
2429
  AXTextEditorTableComponent,
1925
2430
  AXTextEditorScriptComponent,
@@ -1934,11 +2439,13 @@ class AXTextEditorModule {
1934
2439
  AXTextEditorHistoryComponent,
1935
2440
  AXTextEditorHeadingComponent,
1936
2441
  AXTextEditorFontStyleComponent,
2442
+ AXTextEditorFontSizeComponent,
1937
2443
  AXTextEditorAlignmentComponent,
1938
2444
  AXTextEditorColorsComponent,
1939
2445
  AXTextEditorColorSwatchesComponent,
1940
2446
  AXTextEditorListComponent,
1941
2447
  AXTextEditorLinkComponent,
2448
+ AXTextEditorMediaComponent,
1942
2449
  AXTextEditorBlocksComponent,
1943
2450
  AXTextEditorTableComponent,
1944
2451
  AXTextEditorScriptComponent,
@@ -1949,11 +2456,13 @@ class AXTextEditorModule {
1949
2456
  AXTextEditorHistoryComponent,
1950
2457
  AXTextEditorHeadingComponent,
1951
2458
  AXTextEditorFontStyleComponent,
2459
+ AXTextEditorFontSizeComponent,
1952
2460
  AXTextEditorAlignmentComponent,
1953
2461
  AXTextEditorColorsComponent,
1954
2462
  AXTextEditorColorSwatchesComponent,
1955
2463
  AXTextEditorListComponent,
1956
2464
  AXTextEditorLinkComponent,
2465
+ AXTextEditorMediaComponent,
1957
2466
  AXTextEditorBlocksComponent,
1958
2467
  AXTextEditorTableComponent,
1959
2468
  AXTextEditorScriptComponent,
@@ -1962,11 +2471,13 @@ class AXTextEditorModule {
1962
2471
  AXTextEditorHistoryComponent,
1963
2472
  AXTextEditorHeadingComponent,
1964
2473
  AXTextEditorFontStyleComponent,
2474
+ AXTextEditorFontSizeComponent,
1965
2475
  AXTextEditorAlignmentComponent,
1966
2476
  AXTextEditorColorsComponent,
1967
2477
  AXTextEditorColorSwatchesComponent,
1968
2478
  AXTextEditorListComponent,
1969
2479
  AXTextEditorLinkComponent,
2480
+ AXTextEditorMediaComponent,
1970
2481
  AXTextEditorBlocksComponent,
1971
2482
  AXTextEditorTableComponent,
1972
2483
  AXTextEditorScriptComponent,
@@ -1984,5 +2495,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImpor
1984
2495
  * Generated bundle index. Do not edit.
1985
2496
  */
1986
2497
 
1987
- export { AXTextEditorAlignmentComponent, AXTextEditorBlocksComponent, AXTextEditorColorSwatchesComponent, AXTextEditorColorsComponent, AXTextEditorCommandComponent, AXTextEditorComponent, AXTextEditorContentComponent, AXTextEditorFontStyleComponent, AXTextEditorHeadingComponent, AXTextEditorHistoryComponent, AXTextEditorLinkComponent, AXTextEditorListComponent, AXTextEditorModule, AXTextEditorScriptComponent, AXTextEditorService, AXTextEditorSlot, AXTextEditorTableComponent, AXTextEditorToolbarComponent, AXTextEditorZoomComponent, AX_TEXT_EDITOR_DEFAULT_BACKGROUND_COLORS, AX_TEXT_EDITOR_DEFAULT_TEXT_COLORS, AX_TEXT_EDITOR_ZOOM_MAX, AX_TEXT_EDITOR_ZOOM_MIN, AX_TEXT_EDITOR_ZOOM_PRESETS, canRunTextEditorCommand, createTextEditorExtensions, isTextEditorCommandActive, runTextEditorCommand };
2498
+ export { AXTextEditorAlignmentComponent, AXTextEditorBlocksComponent, AXTextEditorColorSwatchesComponent, AXTextEditorColorsComponent, AXTextEditorCommandComponent, AXTextEditorComponent, AXTextEditorContentComponent, AXTextEditorFontSizeComponent, AXTextEditorFontStyleComponent, AXTextEditorHeadingComponent, AXTextEditorHistoryComponent, AXTextEditorLinkComponent, AXTextEditorListComponent, AXTextEditorMediaComponent, AXTextEditorModule, AXTextEditorScriptComponent, AXTextEditorService, AXTextEditorSlot, AXTextEditorTableComponent, AXTextEditorToolbarComponent, AXTextEditorZoomComponent, AX_TEXT_EDITOR_DEFAULT_BACKGROUND_COLORS, AX_TEXT_EDITOR_DEFAULT_TEXT_COLORS, AX_TEXT_EDITOR_FONT_SIZES, AX_TEXT_EDITOR_I18N, AX_TEXT_EDITOR_ZOOM_MAX, AX_TEXT_EDITOR_ZOOM_MIN, AX_TEXT_EDITOR_ZOOM_PRESETS, canRunTextEditorCommand, createTextEditorExtensions, isTextEditorCommandActive, runTextEditorCommand };
1988
2499
  //# sourceMappingURL=acorex-components-text-editor.mjs.map