croco-html 4.9.1 → 4.9.2

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.
@@ -33,6 +33,8 @@ export declare class AudioEditorComponent implements OnInit, OnDestroy {
33
33
  constructor(_publicFileService: PublicFilesQueryService, _privateFileService: PrivateFilesQueryService, _htmlSettingsService: CrocoHtmlFileOptionsService, _commonFileInfoService: CommonFileInfoQueryService);
34
34
  get fileId(): string;
35
35
  set fileId(value: string);
36
+ get title(): string;
37
+ set title(value: string);
36
38
  hasFileId(): boolean;
37
39
  private get audioElement();
38
40
  onErrorHandler(): void;
@@ -20,6 +20,7 @@ export declare class AudioPlayerTagViewComponent implements OnInit, OnDestroy, O
20
20
  data: InterfaceBlock;
21
21
  constructor(_options: CrocoHtmlOptions, _commonFileInfoService: CommonFileInfoQueryService);
22
22
  get fileId(): string;
23
+ get title(): string;
23
24
  private get audioElement();
24
25
  hasFileId(): boolean;
25
26
  onErrorHandler(): void;
@@ -2,13 +2,14 @@ import { OnDestroy, OnInit } from '@angular/core';
2
2
  import { InterfaceBlock } from '../../../models/InterfaceBlock';
3
3
  import { ScreenWidthService } from "../../../services/screen-width.service";
4
4
  import { CrocoHtmlOptions } from '../../../options';
5
- import { IImageMediaRequest } from '../../../models';
5
+ import { FileImageTagData, IImageMediaRequest } from '../../../models';
6
6
  import * as i0 from "@angular/core";
7
7
  export declare class FileImageTagViewComponent implements OnInit, OnDestroy {
8
8
  private readonly screenWidthService;
9
9
  private readonly _options;
10
10
  set item(item: InterfaceBlock);
11
11
  imageSrc: string;
12
+ imageData: FileImageTagData | null;
12
13
  requests: IImageMediaRequest[];
13
14
  private unsubscribe;
14
15
  imageMaxHeight: number;
@@ -17,6 +18,7 @@ export declare class FileImageTagViewComponent implements OnInit, OnDestroy {
17
18
  getMediaRequests(screenMediaRequest: string): IImageMediaRequest[];
18
19
  ngOnInit(): void;
19
20
  ngOnDestroy(): void;
21
+ onImageClick(): void;
20
22
  static ɵfac: i0.ɵɵFactoryDeclaration<FileImageTagViewComponent, never>;
21
23
  static ɵcmp: i0.ɵɵComponentDeclaration<FileImageTagViewComponent, "croco-html-file-image-tag-view", never, { "item": { "alias": "item"; "required": false; }; }, {}, never, never, true, never>;
22
24
  }
@@ -1,6 +1,7 @@
1
1
  export declare class FileAudioTagDataConsts {
2
2
  static readonly TagName = "audio-player";
3
3
  static readonly FileIdAttrName = "file-id";
4
+ static readonly TitleAttrName = "title";
4
5
  }
5
6
  export declare class AudioMethods {
6
7
  static buildUrl(fileId: string, fileName: string): string;
package/lib/index.d.ts CHANGED
@@ -11,13 +11,13 @@ import { VisualEditorComponent } from './components';
11
11
  import { AddFilesBtnComponent } from './components';
12
12
  import { XmlTagExternalVideoComponent } from "./components";
13
13
  import { HtmlRawEditorComponent } from "./components";
14
- import { MatCardModule } from '@angular/material/card';
14
+ import { MatTabsModule } from '@angular/material/tabs';
15
15
  import { TagToSpanPipe, ToHtmlBodyTagsPipe, ToPreviewHtmlPipe, ToPreviewPipe } from "./pipes";
16
16
  import { FileImageTagViewComponent, AudioPlayerTagViewComponent, UploadFilesBtnComponent } from "./components";
17
17
  import { HtmlRawViewComponent } from "./components";
18
18
  import { XmlTagCustomWidgetComponent } from "./components";
19
- export declare const EditorComponents: (typeof TextEditorComponent | typeof ImageEditorComponent | typeof HtmlRawEditorComponent | typeof CustomWidgetEditorComponent | typeof DefinedCustomEditorBlockComponent | typeof MainEditorBlockComponent | typeof AddFilesBtnComponent | typeof FileIdSelectComponent | typeof CustomWidgetIconComponent | typeof VisualEditorComponent | typeof MainEditorComponent)[];
20
- export declare const XmlComponents: (typeof AudioPlayerTagViewComponent | typeof XmlTagTextViewComponent | typeof HtmlRawViewComponent | typeof FileImageTagViewComponent | typeof XmlTagHtmlViewComponent | typeof XmlTagExternalVideoComponent | typeof XmlTagCustomWidgetComponent | typeof DefinedCustomTagViewComponent | typeof XmlTagViewComponent)[];
21
- export declare const CrocoPipes: (typeof ToPreviewPipe | typeof TagToSpanPipe | typeof ToHtmlBodyTagsPipe | typeof ToPreviewHtmlPipe)[];
22
- export declare const CrocoHtmlDeclarations: (typeof AudioPlayerTagViewComponent | typeof XmlTagTextViewComponent | typeof HtmlRawViewComponent | typeof FileImageTagViewComponent | typeof XmlTagHtmlViewComponent | typeof XmlTagExternalVideoComponent | typeof XmlTagCustomWidgetComponent | typeof DefinedCustomTagViewComponent | typeof XmlTagViewComponent | typeof UploadFilesBtnComponent | typeof TextEditorComponent | typeof ImageEditorComponent | typeof HtmlRawEditorComponent | typeof CustomWidgetEditorComponent | typeof DefinedCustomEditorBlockComponent | typeof MainEditorBlockComponent | typeof AddFilesBtnComponent | typeof FileIdSelectComponent | typeof CustomWidgetIconComponent | typeof VisualEditorComponent | typeof ToPreviewPipe | typeof MainEditorComponent | typeof TagToSpanPipe | typeof ToHtmlBodyTagsPipe | typeof ToPreviewHtmlPipe)[];
23
- export declare const MaterialModules: (typeof MatCardModule)[];
19
+ export declare const EditorComponents: (typeof VisualEditorComponent | typeof MainEditorComponent | typeof AddFilesBtnComponent | typeof MainEditorBlockComponent | typeof CustomWidgetIconComponent | typeof TextEditorComponent | typeof ImageEditorComponent | typeof HtmlRawEditorComponent | typeof CustomWidgetEditorComponent | typeof DefinedCustomEditorBlockComponent | typeof FileIdSelectComponent)[];
20
+ export declare const XmlComponents: (typeof XmlTagTextViewComponent | typeof HtmlRawViewComponent | typeof FileImageTagViewComponent | typeof AudioPlayerTagViewComponent | typeof XmlTagHtmlViewComponent | typeof XmlTagExternalVideoComponent | typeof XmlTagCustomWidgetComponent | typeof DefinedCustomTagViewComponent | typeof XmlTagViewComponent)[];
21
+ export declare const CrocoPipes: (typeof ToPreviewHtmlPipe | typeof ToHtmlBodyTagsPipe | typeof ToPreviewPipe | typeof TagToSpanPipe)[];
22
+ export declare const CrocoHtmlDeclarations: (typeof ToPreviewHtmlPipe | typeof ToHtmlBodyTagsPipe | typeof VisualEditorComponent | typeof MainEditorComponent | typeof ToPreviewPipe | typeof AddFilesBtnComponent | typeof MainEditorBlockComponent | typeof CustomWidgetIconComponent | typeof TextEditorComponent | typeof ImageEditorComponent | typeof HtmlRawEditorComponent | typeof CustomWidgetEditorComponent | typeof DefinedCustomEditorBlockComponent | typeof FileIdSelectComponent | typeof XmlTagTextViewComponent | typeof HtmlRawViewComponent | typeof FileImageTagViewComponent | typeof AudioPlayerTagViewComponent | typeof XmlTagHtmlViewComponent | typeof XmlTagExternalVideoComponent | typeof XmlTagCustomWidgetComponent | typeof DefinedCustomTagViewComponent | typeof XmlTagViewComponent | typeof UploadFilesBtnComponent | typeof TagToSpanPipe)[];
23
+ export declare const MaterialModules: (typeof MatTabsModule)[];
@@ -1,5 +1,6 @@
1
1
  export interface FileAudioTagData {
2
2
  fileId: string;
3
+ title?: string;
3
4
  }
4
5
  export interface FileAudioTag {
5
6
  tagName: string;
@@ -1,5 +1,5 @@
1
1
  import { Type } from "@angular/core";
2
- import { IImageMediaRequest } from "../models";
2
+ import { IImageMediaRequest, FileImageTagData } from "../models";
3
3
  import { VisualEditorComponent } from "../components";
4
4
  import { IMarkUpTagService } from "../tag-services";
5
5
  export interface CrocoHtmlOptions {
@@ -68,6 +68,11 @@ export interface CrocoHtmlImageOptions {
68
68
  * Медиа запросы для изображений.
69
69
  */
70
70
  globalMediaRequests?: IImageMediaRequest[];
71
+ /**
72
+ * Обработчик клика на изображение в теге file-image.
73
+ * @param imageData - данные изображения
74
+ */
75
+ onImageClick?: (imageData: FileImageTagData) => void;
71
76
  }
72
77
  /**
73
78
  * Опции для работы с файлами в редакторе разметки
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "croco-html",
3
- "version": "4.9.1",
3
+ "version": "4.9.2",
4
4
  "peerDependencies": {
5
5
  "@angular/common": "^19.2.14",
6
6
  "@angular/core": "^19.2.14",