@acorex/components 20.8.32 → 20.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/conversation/README.md +462 -2
- package/conversation/index.d.ts +5400 -485
- package/fesm2022/acorex-components-calendar.mjs +3 -2
- package/fesm2022/acorex-components-calendar.mjs.map +1 -1
- package/fesm2022/acorex-components-conversation-acorex-components-conversation-CjVDCoJw.mjs +13711 -0
- package/fesm2022/acorex-components-conversation-acorex-components-conversation-CjVDCoJw.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-audio-attachment.component-Ri-Jx210.mjs +119 -0
- package/fesm2022/acorex-components-conversation-audio-attachment.component-Ri-Jx210.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-audio-composer.payload-DiMDlVl9.mjs +59 -0
- package/fesm2022/acorex-components-conversation-audio-composer.payload-DiMDlVl9.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-audio-picker.component-CqrKBDIF.mjs +432 -0
- package/fesm2022/acorex-components-conversation-audio-picker.component-CqrKBDIF.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-audio-renderer.component-CO8owVrA.mjs +177 -0
- package/fesm2022/acorex-components-conversation-audio-renderer.component-CO8owVrA.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-audio.payload-CLnYjmYY.mjs +54 -0
- package/fesm2022/acorex-components-conversation-audio.payload-CLnYjmYY.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-composer-action-choice-dialog.component-CYutyq7i.mjs +101 -0
- package/fesm2022/acorex-components-conversation-composer-action-choice-dialog.component-CYutyq7i.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-conversation-audio.file-type-D-hIBwQ2.mjs +100 -0
- package/fesm2022/acorex-components-conversation-conversation-audio.file-type-D-hIBwQ2.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-conversation-file.file-type-DQUy3C64.mjs +121 -0
- package/fesm2022/acorex-components-conversation-conversation-file.file-type-DQUy3C64.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-conversation-image.file-type-Bd_SkwR0.mjs +84 -0
- package/fesm2022/acorex-components-conversation-conversation-image.file-type-Bd_SkwR0.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-conversation-info-media-view.component-BalIIAFB.mjs +238 -0
- package/fesm2022/acorex-components-conversation-conversation-info-media-view.component-BalIIAFB.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-conversation-info-panel.component-BJMo9bDd.mjs +1080 -0
- package/fesm2022/acorex-components-conversation-conversation-info-panel.component-BJMo9bDd.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-conversation-video.file-type-DyK0bLE5.mjs +102 -0
- package/fesm2022/acorex-components-conversation-conversation-video.file-type-DyK0bLE5.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-conversation-voice.file-type-v3rFWDv6.mjs +90 -0
- package/fesm2022/acorex-components-conversation-conversation-voice.file-type-v3rFWDv6.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-emoji-categories-C7Gm95V0.mjs +1840 -0
- package/fesm2022/acorex-components-conversation-emoji-categories-C7Gm95V0.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-fallback-renderer.component-DOQkZWwP.mjs +44 -0
- package/fesm2022/acorex-components-conversation-fallback-renderer.component-DOQkZWwP.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-file-composer.payload-azPSH99m.mjs +64 -0
- package/fesm2022/acorex-components-conversation-file-composer.payload-azPSH99m.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-file-picker.component-cmUkgSF3.mjs +468 -0
- package/fesm2022/acorex-components-conversation-file-picker.component-cmUkgSF3.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-file-renderer.component-CpUgRTR4.mjs +125 -0
- package/fesm2022/acorex-components-conversation-file-renderer.component-CpUgRTR4.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-file.payload-DXwzNWxT.mjs +50 -0
- package/fesm2022/acorex-components-conversation-file.payload-DXwzNWxT.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-format-media-DUD4vA6F.mjs +21 -0
- package/fesm2022/acorex-components-conversation-format-media-DUD4vA6F.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-image-attachment.component-BZto5LFo.mjs +77 -0
- package/fesm2022/acorex-components-conversation-image-attachment.component-BZto5LFo.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-image-picker.component-G9EEOyDg.mjs +407 -0
- package/fesm2022/acorex-components-conversation-image-picker.component-G9EEOyDg.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-image-renderer.component-Bwa6rG6C.mjs +83 -0
- package/fesm2022/acorex-components-conversation-image-renderer.component-Bwa6rG6C.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-index-BbrYsQ84.mjs +180 -0
- package/fesm2022/acorex-components-conversation-index-BbrYsQ84.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-index-DtGEWeKN.mjs +266 -0
- package/fesm2022/acorex-components-conversation-index-DtGEWeKN.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-location-picker.component-Cx993j_c.mjs +149 -0
- package/fesm2022/acorex-components-conversation-location-picker.component-Cx993j_c.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-location-renderer.component-BiynmAJw.mjs +118 -0
- package/fesm2022/acorex-components-conversation-location-renderer.component-BiynmAJw.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-media-formatters-DV3wEEno.mjs +17 -0
- package/fesm2022/acorex-components-conversation-media-formatters-DV3wEEno.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-media-playback-info-bar-banner.component-a7OSpfB1.mjs +140 -0
- package/fesm2022/acorex-components-conversation-media-playback-info-bar-banner.component-a7OSpfB1.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-message-renderer-copy-host.component-D_eAnM6v.mjs +33 -0
- package/fesm2022/acorex-components-conversation-message-renderer-copy-host.component-D_eAnM6v.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-message-renderer-state.component-DSnNoz1N.mjs +172 -0
- package/fesm2022/acorex-components-conversation-message-renderer-state.component-DSnNoz1N.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-open-composer-picker-for-files-CbNyy2Ws.mjs +224 -0
- package/fesm2022/acorex-components-conversation-open-composer-picker-for-files-CbNyy2Ws.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-pagination-demo-data-DRr9PXjJ.mjs +81 -0
- package/fesm2022/acorex-components-conversation-pagination-demo-data-DRr9PXjJ.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-picker-header.component-BhTzlufI.mjs +91 -0
- package/fesm2022/acorex-components-conversation-picker-header.component-BhTzlufI.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-picker-toolbar.component-CpyS0j6P.mjs +537 -0
- package/fesm2022/acorex-components-conversation-picker-toolbar.component-CpyS0j6P.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-picker-upload-C-PlKPaU.mjs +163 -0
- package/fesm2022/acorex-components-conversation-picker-upload-C-PlKPaU.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-playback-banner-sync-BMsx6Fuy.mjs +68 -0
- package/fesm2022/acorex-components-conversation-playback-banner-sync-BMsx6Fuy.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-renderer-shared.styles-Digah3Zn.mjs +95 -0
- package/fesm2022/acorex-components-conversation-renderer-shared.styles-Digah3Zn.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-search.component-96NI2ERG.mjs +187 -0
- package/fesm2022/acorex-components-conversation-search.component-96NI2ERG.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-send-message-media--Rbrne7k.mjs +170 -0
- package/fesm2022/acorex-components-conversation-send-message-media--Rbrne7k.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-shared-storage.seed-zFjNXfKF.mjs +750 -0
- package/fesm2022/acorex-components-conversation-shared-storage.seed-zFjNXfKF.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-sticker-renderer.component-BZgx_Ylk.mjs +103 -0
- package/fesm2022/acorex-components-conversation-sticker-renderer.component-BZgx_Ylk.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-system-renderer.component-D1Aj-LuF.mjs +55 -0
- package/fesm2022/acorex-components-conversation-system-renderer.component-D1Aj-LuF.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-text-renderer.component-Cxvwjr2p.mjs +109 -0
- package/fesm2022/acorex-components-conversation-text-renderer.component-Cxvwjr2p.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-video-attachment.component-DBY_4Ri2.mjs +105 -0
- package/fesm2022/acorex-components-conversation-video-attachment.component-DBY_4Ri2.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-video-composer.payload-CWGxsPg5.mjs +62 -0
- package/fesm2022/acorex-components-conversation-video-composer.payload-CWGxsPg5.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-video-picker.component-D1JYwEm_.mjs +446 -0
- package/fesm2022/acorex-components-conversation-video-picker.component-D1JYwEm_.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-video-renderer.component-iwf2bU29.mjs +181 -0
- package/fesm2022/acorex-components-conversation-video-renderer.component-iwf2bU29.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-video.payload-DfBEjqQ4.mjs +54 -0
- package/fesm2022/acorex-components-conversation-video.payload-DfBEjqQ4.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-voice-composer.payload-DLVow7ex.mjs +17 -0
- package/fesm2022/acorex-components-conversation-voice-composer.payload-DLVow7ex.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-voice-recorder.component-P8J_5OH0.mjs +328 -0
- package/fesm2022/acorex-components-conversation-voice-recorder.component-P8J_5OH0.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation-voice-renderer.component-CZpEqbXL.mjs +270 -0
- package/fesm2022/acorex-components-conversation-voice-renderer.component-CZpEqbXL.mjs.map +1 -0
- package/fesm2022/acorex-components-conversation.mjs +1 -1402
- package/fesm2022/acorex-components-conversation.mjs.map +1 -1
- package/fesm2022/acorex-components-data-table.mjs +2 -2
- package/fesm2022/acorex-components-data-table.mjs.map +1 -1
- package/fesm2022/acorex-components-rest-api-generator.mjs +2 -2
- package/fesm2022/acorex-components-rest-api-generator.mjs.map +1 -1
- package/fesm2022/acorex-components-scheduler-picker.mjs +22 -14
- package/fesm2022/acorex-components-scheduler-picker.mjs.map +1 -1
- package/fesm2022/acorex-components-step-wizard.mjs +2 -2
- package/fesm2022/acorex-components-step-wizard.mjs.map +1 -1
- package/fesm2022/acorex-components-tree-view-legacy.mjs +2 -2
- package/fesm2022/acorex-components-tree-view-legacy.mjs.map +1 -1
- package/package.json +35 -39
- package/scheduler-picker/index.d.ts +2 -0
- package/conversation2/README.md +0 -463
- package/conversation2/index.d.ts +0 -6410
- package/fesm2022/acorex-components-conversation2.mjs +0 -22331
- package/fesm2022/acorex-components-conversation2.mjs.map +0 -1
package/fesm2022/acorex-components-conversation-conversation-info-media-view.component-BalIIAFB.mjs
ADDED
|
@@ -0,0 +1,238 @@
|
|
|
1
|
+
import { AXDecoratorModule } from '@acorex/components/decorators';
|
|
2
|
+
import * as i3 from '@acorex/core/translation';
|
|
3
|
+
import { AXTranslationService, AXTranslationModule } from '@acorex/core/translation';
|
|
4
|
+
import * as i2 from '@angular/common';
|
|
5
|
+
import { CommonModule } from '@angular/common';
|
|
6
|
+
import * as i0 from '@angular/core';
|
|
7
|
+
import { inject, Injector, input, output, computed, ChangeDetectionStrategy, Component } from '@angular/core';
|
|
8
|
+
import { A as AXConversationService, h as AXConversationRegistryComponentOutletComponent } from './acorex-components-conversation-acorex-components-conversation-CjVDCoJw.mjs';
|
|
9
|
+
import { A as AXConversationAudioAttachmentComponent } from './acorex-components-conversation-audio-attachment.component-Ri-Jx210.mjs';
|
|
10
|
+
import { A as AXConversationImageAttachmentComponent } from './acorex-components-conversation-image-attachment.component-BZto5LFo.mjs';
|
|
11
|
+
import { A as AXConversationVideoAttachmentComponent } from './acorex-components-conversation-video-attachment.component-DBY_4Ri2.mjs';
|
|
12
|
+
import { f as filterMessagesByMediaCategory, i as isGridMediaCategory, a as isAttachmentListCategory, b as buildMediaGalleryTiles, g as getMessageVideoItems, c as getMessageAudioItems } from './acorex-components-conversation-conversation-info-panel.component-BJMo9bDd.mjs';
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* Shared media browser inside the conversation info panel.
|
|
16
|
+
*/
|
|
17
|
+
class AXConversationInfoMediaViewComponent {
|
|
18
|
+
constructor() {
|
|
19
|
+
this.translation = inject(AXTranslationService);
|
|
20
|
+
this.parentInjector = inject(Injector);
|
|
21
|
+
this.category = input.required(...(ngDevMode ? [{ debugName: "category" }] : []));
|
|
22
|
+
this.messages = input.required(...(ngDevMode ? [{ debugName: "messages" }] : []));
|
|
23
|
+
this.conversation = input.required(...(ngDevMode ? [{ debugName: "conversation" }] : []));
|
|
24
|
+
this.conversationServiceInput = input.required(...(ngDevMode ? [{ debugName: "conversationServiceInput", alias: 'conversationService' }] : [{ alias: 'conversationService' }]));
|
|
25
|
+
/** Callback for lazy outlet wiring (alternative to the `back` output). */
|
|
26
|
+
this.onBack = input(undefined, ...(ngDevMode ? [{ debugName: "onBack" }] : []));
|
|
27
|
+
this.back = output();
|
|
28
|
+
this.items = computed(() => filterMessagesByMediaCategory(this.messages(), this.category().id), ...(ngDevMode ? [{ debugName: "items" }] : []));
|
|
29
|
+
this.isGrid = computed(() => isGridMediaCategory(this.category().id), ...(ngDevMode ? [{ debugName: "isGrid" }] : []));
|
|
30
|
+
this.isAttachmentList = computed(() => isAttachmentListCategory(this.category().id), ...(ngDevMode ? [{ debugName: "isAttachmentList" }] : []));
|
|
31
|
+
this.galleryTiles = computed(() => buildMediaGalleryTiles(this.messages(), this.category().id), ...(ngDevMode ? [{ debugName: "galleryTiles" }] : []));
|
|
32
|
+
this.rendererInjector = computed(() => Injector.create({
|
|
33
|
+
providers: [{ provide: AXConversationService, useValue: this.conversationServiceInput() }],
|
|
34
|
+
parent: this.parentInjector,
|
|
35
|
+
}), ...(ngDevMode ? [{ debugName: "rendererInjector" }] : []));
|
|
36
|
+
this.titleLabel = computed(() => this.translation.translateSync(this.category().countLabelKey, {
|
|
37
|
+
params: { count: this.category().count },
|
|
38
|
+
}), ...(ngDevMode ? [{ debugName: "titleLabel" }] : []));
|
|
39
|
+
this.getMessageVideoItems = getMessageVideoItems;
|
|
40
|
+
this.getMessageAudioItems = getMessageAudioItems;
|
|
41
|
+
}
|
|
42
|
+
getRendererComponent(message) {
|
|
43
|
+
const renderer = this.conversationServiceInput().registry.messageRenderers.getRenderer(message);
|
|
44
|
+
return renderer?.component;
|
|
45
|
+
}
|
|
46
|
+
getRendererComponentLoader(message) {
|
|
47
|
+
const renderer = this.conversationServiceInput().registry.messageRenderers.getRenderer(message);
|
|
48
|
+
if (renderer?.componentLoader) {
|
|
49
|
+
return renderer.componentLoader;
|
|
50
|
+
}
|
|
51
|
+
if (!renderer?.component) {
|
|
52
|
+
return () => import('./acorex-components-conversation-fallback-renderer.component-DOQkZWwP.mjs').then((m) => m.AXConversationFallbackRendererComponent);
|
|
53
|
+
}
|
|
54
|
+
return undefined;
|
|
55
|
+
}
|
|
56
|
+
getRendererInputs(message) {
|
|
57
|
+
return { message };
|
|
58
|
+
}
|
|
59
|
+
formatTimestamp(message) {
|
|
60
|
+
return new Intl.DateTimeFormat(undefined, {
|
|
61
|
+
dateStyle: 'medium',
|
|
62
|
+
timeStyle: 'short',
|
|
63
|
+
}).format(message.timestamp);
|
|
64
|
+
}
|
|
65
|
+
handleBack() {
|
|
66
|
+
this.onBack()?.();
|
|
67
|
+
this.back.emit();
|
|
68
|
+
}
|
|
69
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.3", ngImport: i0, type: AXConversationInfoMediaViewComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
70
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.3", type: AXConversationInfoMediaViewComponent, isStandalone: true, selector: "ax-conversation-info-media-view", inputs: { category: { classPropertyName: "category", publicName: "category", isSignal: true, isRequired: true, transformFunction: null }, messages: { classPropertyName: "messages", publicName: "messages", isSignal: true, isRequired: true, transformFunction: null }, conversation: { classPropertyName: "conversation", publicName: "conversation", isSignal: true, isRequired: true, transformFunction: null }, conversationServiceInput: { classPropertyName: "conversationServiceInput", publicName: "conversationService", isSignal: true, isRequired: true, transformFunction: null }, onBack: { classPropertyName: "onBack", publicName: "onBack", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { back: "back" }, ngImport: i0, template: `
|
|
71
|
+
<div class="tg-media-view">
|
|
72
|
+
<header class="tg-media-view__header">
|
|
73
|
+
<button type="button" class="tg-media-view__back" (click)="handleBack()" [attr.aria-label]="'Back'">
|
|
74
|
+
<i class="fa-light fa-arrow-left"></i>
|
|
75
|
+
</button>
|
|
76
|
+
<h3 class="tg-media-view__title">{{ titleLabel() }}</h3>
|
|
77
|
+
</header>
|
|
78
|
+
|
|
79
|
+
@if (items().length === 0) {
|
|
80
|
+
<div class="tg-media-view__empty">
|
|
81
|
+
{{ '@acorex:chat.info-panel.media.empty' | translate | async }}
|
|
82
|
+
</div>
|
|
83
|
+
} @else if (isGrid()) {
|
|
84
|
+
<div class="tg-media-view__grid">
|
|
85
|
+
@for (tile of galleryTiles(); track tile.key) {
|
|
86
|
+
<article
|
|
87
|
+
class="tg-media-view__grid-cell"
|
|
88
|
+
[class.tg-media-view__grid-cell--sticker]="tile.kind === 'sticker'"
|
|
89
|
+
>
|
|
90
|
+
@switch (tile.kind) {
|
|
91
|
+
@case ('image') {
|
|
92
|
+
@if (tile.image; as image) {
|
|
93
|
+
<ax-conversation-image-attachment [item]="image" [alt]="'Photo'" />
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
@case ('sticker') {
|
|
97
|
+
@if (tile.stickerUrl) {
|
|
98
|
+
<img
|
|
99
|
+
class="tg-media-view__sticker"
|
|
100
|
+
[src]="tile.stickerUrl"
|
|
101
|
+
[alt]="tile.stickerAlt ?? 'Sticker'"
|
|
102
|
+
loading="lazy"
|
|
103
|
+
/>
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
</article>
|
|
108
|
+
}
|
|
109
|
+
</div>
|
|
110
|
+
} @else if (isAttachmentList()) {
|
|
111
|
+
<div class="tg-media-view__list">
|
|
112
|
+
@for (message of items(); track message.id) {
|
|
113
|
+
<article class="tg-media-view__list-item">
|
|
114
|
+
<div class="tg-media-view__list-body">
|
|
115
|
+
@if (category().id === 'video') {
|
|
116
|
+
@for (video of getMessageVideoItems(message); track video.mediaId ?? video.url) {
|
|
117
|
+
<ax-conversation-video-attachment [item]="video" />
|
|
118
|
+
}
|
|
119
|
+
} @else {
|
|
120
|
+
@for (audio of getMessageAudioItems(message); track audio.mediaId ?? audio.url) {
|
|
121
|
+
<ax-conversation-audio-attachment [item]="audio" />
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
</div>
|
|
125
|
+
<time class="tg-media-view__list-meta">{{ formatTimestamp(message) }}</time>
|
|
126
|
+
</article>
|
|
127
|
+
}
|
|
128
|
+
</div>
|
|
129
|
+
} @else {
|
|
130
|
+
<div class="tg-media-view__list">
|
|
131
|
+
@for (message of items(); track message.id) {
|
|
132
|
+
<article class="tg-media-view__list-item">
|
|
133
|
+
<div class="tg-media-view__list-body">
|
|
134
|
+
<ax-conversation-registry-component-outlet
|
|
135
|
+
[component]="getRendererComponent(message)"
|
|
136
|
+
[componentLoader]="getRendererComponentLoader(message)"
|
|
137
|
+
[inputs]="getRendererInputs(message)"
|
|
138
|
+
/>
|
|
139
|
+
</div>
|
|
140
|
+
<time class="tg-media-view__list-meta">{{ formatTimestamp(message) }}</time>
|
|
141
|
+
</article>
|
|
142
|
+
}
|
|
143
|
+
</div>
|
|
144
|
+
}
|
|
145
|
+
</div>
|
|
146
|
+
`, isInline: true, styles: [":host{display:block;width:100%}.tg-media-view{display:flex;flex-direction:column;min-height:12rem;max-height:min(85vh,40rem)}.tg-media-view__header{display:flex;align-items:center;gap:.5rem;padding:.65rem .75rem;border-bottom:1px solid rgb(var(--ax-sys-color-border-light-surface));flex-shrink:0}.tg-media-view__back{display:inline-flex;align-items:center;justify-content:center;width:2rem;height:2rem;border:none;border-radius:999px;background:transparent;color:rgb(var(--ax-sys-color-primary-500));cursor:pointer}.tg-media-view__back:hover{background:rgb(var(--ax-sys-color-lighter-surface))}.tg-media-view__title{margin:0;font-size:1rem;font-weight:600;color:rgb(var(--ax-sys-color-on-surface))}.tg-media-view__empty{padding:2rem 1rem;text-align:center;font-size:.875rem;color:rgb(var(--ax-sys-color-on-surface));opacity:.65}.tg-media-view__grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:2px;padding:2px;overflow-y:auto;overscroll-behavior:contain;background:rgb(var(--ax-sys-color-border-light-surface))}.tg-media-view__grid-cell{position:relative;aspect-ratio:1;overflow:hidden;background:rgb(var(--ax-sys-color-lighter-surface))}.tg-media-view__grid-cell--sticker{display:flex;align-items:center;justify-content:center;padding:.35rem}.tg-media-view__grid-cell ::ng-deep ax-conversation-image-attachment,.tg-media-view__grid-cell ::ng-deep .ax-conversation-image-attachment{width:100%;height:100%;min-height:0;border-radius:0}.tg-media-view__grid-cell ::ng-deep img{width:100%;height:100%;object-fit:cover}.tg-media-view__sticker{max-width:100%;max-height:100%;object-fit:contain}.tg-media-view__list{display:flex;flex-direction:column;overflow-y:auto;overscroll-behavior:contain}.tg-media-view__list-item{display:flex;flex-direction:column;gap:.35rem;padding:.75rem 1rem;border-bottom:1px solid rgb(var(--ax-sys-color-border-light-surface))}.tg-media-view__list-item:last-child{border-bottom:none}.tg-media-view__list-body{min-width:0;display:flex;flex-direction:column;gap:.5rem}.tg-media-view__list-body ::ng-deep .ax-conversation-msg{max-width:100%}.tg-media-view__list-body ::ng-deep ax-conversation-message-renderer-state{display:none}.tg-media-view__list-body ::ng-deep .ax-conversation-video__player{max-height:min(50vh,16rem)}.tg-media-view__list-meta{font-size:.75rem;color:rgb(var(--ax-sys-color-on-surface));opacity:.55}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "component", type: AXConversationRegistryComponentOutletComponent, selector: "ax-conversation-registry-component-outlet", inputs: ["component", "componentLoader", "inputs"] }, { kind: "ngmodule", type: AXDecoratorModule }, { kind: "ngmodule", type: AXTranslationModule }, { kind: "component", type: AXConversationImageAttachmentComponent, selector: "ax-conversation-image-attachment", inputs: ["item", "alt"] }, { kind: "component", type: AXConversationVideoAttachmentComponent, selector: "ax-conversation-video-attachment", inputs: ["item"], outputs: ["playingChange", "timeUpdate", "durationChange", "playbackEnded", "playbackError"] }, { kind: "component", type: AXConversationAudioAttachmentComponent, selector: "ax-conversation-audio-attachment", inputs: ["item"], outputs: ["playingChange", "timeUpdate", "durationChange", "playbackEnded", "playbackError"] }, { kind: "pipe", type: i2.AsyncPipe, name: "async" }, { kind: "pipe", type: i3.AXTranslatorPipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
147
|
+
}
|
|
148
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.3", ngImport: i0, type: AXConversationInfoMediaViewComponent, decorators: [{
|
|
149
|
+
type: Component,
|
|
150
|
+
args: [{ selector: 'ax-conversation-info-media-view', changeDetection: ChangeDetectionStrategy.OnPush, imports: [
|
|
151
|
+
CommonModule,
|
|
152
|
+
AXConversationRegistryComponentOutletComponent,
|
|
153
|
+
AXDecoratorModule,
|
|
154
|
+
AXTranslationModule,
|
|
155
|
+
AXConversationImageAttachmentComponent,
|
|
156
|
+
AXConversationVideoAttachmentComponent,
|
|
157
|
+
AXConversationAudioAttachmentComponent,
|
|
158
|
+
], template: `
|
|
159
|
+
<div class="tg-media-view">
|
|
160
|
+
<header class="tg-media-view__header">
|
|
161
|
+
<button type="button" class="tg-media-view__back" (click)="handleBack()" [attr.aria-label]="'Back'">
|
|
162
|
+
<i class="fa-light fa-arrow-left"></i>
|
|
163
|
+
</button>
|
|
164
|
+
<h3 class="tg-media-view__title">{{ titleLabel() }}</h3>
|
|
165
|
+
</header>
|
|
166
|
+
|
|
167
|
+
@if (items().length === 0) {
|
|
168
|
+
<div class="tg-media-view__empty">
|
|
169
|
+
{{ '@acorex:chat.info-panel.media.empty' | translate | async }}
|
|
170
|
+
</div>
|
|
171
|
+
} @else if (isGrid()) {
|
|
172
|
+
<div class="tg-media-view__grid">
|
|
173
|
+
@for (tile of galleryTiles(); track tile.key) {
|
|
174
|
+
<article
|
|
175
|
+
class="tg-media-view__grid-cell"
|
|
176
|
+
[class.tg-media-view__grid-cell--sticker]="tile.kind === 'sticker'"
|
|
177
|
+
>
|
|
178
|
+
@switch (tile.kind) {
|
|
179
|
+
@case ('image') {
|
|
180
|
+
@if (tile.image; as image) {
|
|
181
|
+
<ax-conversation-image-attachment [item]="image" [alt]="'Photo'" />
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
|
+
@case ('sticker') {
|
|
185
|
+
@if (tile.stickerUrl) {
|
|
186
|
+
<img
|
|
187
|
+
class="tg-media-view__sticker"
|
|
188
|
+
[src]="tile.stickerUrl"
|
|
189
|
+
[alt]="tile.stickerAlt ?? 'Sticker'"
|
|
190
|
+
loading="lazy"
|
|
191
|
+
/>
|
|
192
|
+
}
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
</article>
|
|
196
|
+
}
|
|
197
|
+
</div>
|
|
198
|
+
} @else if (isAttachmentList()) {
|
|
199
|
+
<div class="tg-media-view__list">
|
|
200
|
+
@for (message of items(); track message.id) {
|
|
201
|
+
<article class="tg-media-view__list-item">
|
|
202
|
+
<div class="tg-media-view__list-body">
|
|
203
|
+
@if (category().id === 'video') {
|
|
204
|
+
@for (video of getMessageVideoItems(message); track video.mediaId ?? video.url) {
|
|
205
|
+
<ax-conversation-video-attachment [item]="video" />
|
|
206
|
+
}
|
|
207
|
+
} @else {
|
|
208
|
+
@for (audio of getMessageAudioItems(message); track audio.mediaId ?? audio.url) {
|
|
209
|
+
<ax-conversation-audio-attachment [item]="audio" />
|
|
210
|
+
}
|
|
211
|
+
}
|
|
212
|
+
</div>
|
|
213
|
+
<time class="tg-media-view__list-meta">{{ formatTimestamp(message) }}</time>
|
|
214
|
+
</article>
|
|
215
|
+
}
|
|
216
|
+
</div>
|
|
217
|
+
} @else {
|
|
218
|
+
<div class="tg-media-view__list">
|
|
219
|
+
@for (message of items(); track message.id) {
|
|
220
|
+
<article class="tg-media-view__list-item">
|
|
221
|
+
<div class="tg-media-view__list-body">
|
|
222
|
+
<ax-conversation-registry-component-outlet
|
|
223
|
+
[component]="getRendererComponent(message)"
|
|
224
|
+
[componentLoader]="getRendererComponentLoader(message)"
|
|
225
|
+
[inputs]="getRendererInputs(message)"
|
|
226
|
+
/>
|
|
227
|
+
</div>
|
|
228
|
+
<time class="tg-media-view__list-meta">{{ formatTimestamp(message) }}</time>
|
|
229
|
+
</article>
|
|
230
|
+
}
|
|
231
|
+
</div>
|
|
232
|
+
}
|
|
233
|
+
</div>
|
|
234
|
+
`, styles: [":host{display:block;width:100%}.tg-media-view{display:flex;flex-direction:column;min-height:12rem;max-height:min(85vh,40rem)}.tg-media-view__header{display:flex;align-items:center;gap:.5rem;padding:.65rem .75rem;border-bottom:1px solid rgb(var(--ax-sys-color-border-light-surface));flex-shrink:0}.tg-media-view__back{display:inline-flex;align-items:center;justify-content:center;width:2rem;height:2rem;border:none;border-radius:999px;background:transparent;color:rgb(var(--ax-sys-color-primary-500));cursor:pointer}.tg-media-view__back:hover{background:rgb(var(--ax-sys-color-lighter-surface))}.tg-media-view__title{margin:0;font-size:1rem;font-weight:600;color:rgb(var(--ax-sys-color-on-surface))}.tg-media-view__empty{padding:2rem 1rem;text-align:center;font-size:.875rem;color:rgb(var(--ax-sys-color-on-surface));opacity:.65}.tg-media-view__grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:2px;padding:2px;overflow-y:auto;overscroll-behavior:contain;background:rgb(var(--ax-sys-color-border-light-surface))}.tg-media-view__grid-cell{position:relative;aspect-ratio:1;overflow:hidden;background:rgb(var(--ax-sys-color-lighter-surface))}.tg-media-view__grid-cell--sticker{display:flex;align-items:center;justify-content:center;padding:.35rem}.tg-media-view__grid-cell ::ng-deep ax-conversation-image-attachment,.tg-media-view__grid-cell ::ng-deep .ax-conversation-image-attachment{width:100%;height:100%;min-height:0;border-radius:0}.tg-media-view__grid-cell ::ng-deep img{width:100%;height:100%;object-fit:cover}.tg-media-view__sticker{max-width:100%;max-height:100%;object-fit:contain}.tg-media-view__list{display:flex;flex-direction:column;overflow-y:auto;overscroll-behavior:contain}.tg-media-view__list-item{display:flex;flex-direction:column;gap:.35rem;padding:.75rem 1rem;border-bottom:1px solid rgb(var(--ax-sys-color-border-light-surface))}.tg-media-view__list-item:last-child{border-bottom:none}.tg-media-view__list-body{min-width:0;display:flex;flex-direction:column;gap:.5rem}.tg-media-view__list-body ::ng-deep .ax-conversation-msg{max-width:100%}.tg-media-view__list-body ::ng-deep ax-conversation-message-renderer-state{display:none}.tg-media-view__list-body ::ng-deep .ax-conversation-video__player{max-height:min(50vh,16rem)}.tg-media-view__list-meta{font-size:.75rem;color:rgb(var(--ax-sys-color-on-surface));opacity:.55}\n"] }]
|
|
235
|
+
}] });
|
|
236
|
+
|
|
237
|
+
export { AXConversationInfoMediaViewComponent };
|
|
238
|
+
//# sourceMappingURL=acorex-components-conversation-conversation-info-media-view.component-BalIIAFB.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"acorex-components-conversation-conversation-info-media-view.component-BalIIAFB.mjs","sources":["../tmp-esm2022/conversation/lib/plugins/info-bar/components/conversation-info-media-view.component.js"],"sourcesContent":["/**\n * Shared media browser inside the conversation info panel.\n */\nimport { AXDecoratorModule } from '@acorex/components/decorators';\nimport { AXTranslationModule, AXTranslationService } from '@acorex/core/translation';\nimport { CommonModule } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, computed, inject, Injector, input, output } from '@angular/core';\nimport { AXConversationRegistryComponentOutletComponent } from '../../../components/shared/registry-component-outlet.component';\nimport { AXConversationService } from '../../../services';\nimport { AXConversationAudioAttachmentComponent } from '../../message-list/components/shared/audio-attachment.component';\nimport { AXConversationImageAttachmentComponent } from '../../message-list/components/shared/image-attachment.component';\nimport { AXConversationVideoAttachmentComponent } from '../../message-list/components/shared/video-attachment.component';\nimport { buildMediaGalleryTiles, filterMessagesByMediaCategory, getMessageAudioItems, getMessageVideoItems, isAttachmentListCategory, isGridMediaCategory, } from './conversation-info-panel.utils';\nimport * as i0 from \"@angular/core\";\nimport * as i1 from \"@angular/common\";\nimport * as i2 from \"@acorex/core/translation\";\nexport class AXConversationInfoMediaViewComponent {\n constructor() {\n this.translation = inject(AXTranslationService);\n this.parentInjector = inject(Injector);\n this.category = input.required(...(ngDevMode ? [{ debugName: \"category\" }] : []));\n this.messages = input.required(...(ngDevMode ? [{ debugName: \"messages\" }] : []));\n this.conversation = input.required(...(ngDevMode ? [{ debugName: \"conversation\" }] : []));\n this.conversationServiceInput = input.required(...(ngDevMode ? [{ debugName: \"conversationServiceInput\", alias: 'conversationService' }] : [{ alias: 'conversationService' }]));\n /** Callback for lazy outlet wiring (alternative to the `back` output). */\n this.onBack = input(undefined, ...(ngDevMode ? [{ debugName: \"onBack\" }] : []));\n this.back = output();\n this.items = computed(() => filterMessagesByMediaCategory(this.messages(), this.category().id), ...(ngDevMode ? [{ debugName: \"items\" }] : []));\n this.isGrid = computed(() => isGridMediaCategory(this.category().id), ...(ngDevMode ? [{ debugName: \"isGrid\" }] : []));\n this.isAttachmentList = computed(() => isAttachmentListCategory(this.category().id), ...(ngDevMode ? [{ debugName: \"isAttachmentList\" }] : []));\n this.galleryTiles = computed(() => buildMediaGalleryTiles(this.messages(), this.category().id), ...(ngDevMode ? [{ debugName: \"galleryTiles\" }] : []));\n this.rendererInjector = computed(() => Injector.create({\n providers: [{ provide: AXConversationService, useValue: this.conversationServiceInput() }],\n parent: this.parentInjector,\n }), ...(ngDevMode ? [{ debugName: \"rendererInjector\" }] : []));\n this.titleLabel = computed(() => this.translation.translateSync(this.category().countLabelKey, {\n params: { count: this.category().count },\n }), ...(ngDevMode ? [{ debugName: \"titleLabel\" }] : []));\n this.getMessageVideoItems = getMessageVideoItems;\n this.getMessageAudioItems = getMessageAudioItems;\n }\n getRendererComponent(message) {\n const renderer = this.conversationServiceInput().registry.messageRenderers.getRenderer(message);\n return renderer?.component;\n }\n getRendererComponentLoader(message) {\n const renderer = this.conversationServiceInput().registry.messageRenderers.getRenderer(message);\n if (renderer?.componentLoader) {\n return renderer.componentLoader;\n }\n if (!renderer?.component) {\n return () => import('../../message-list/components/fallback-renderer/fallback-renderer.component').then((m) => m.AXConversationFallbackRendererComponent);\n }\n return undefined;\n }\n getRendererInputs(message) {\n return { message };\n }\n formatTimestamp(message) {\n return new Intl.DateTimeFormat(undefined, {\n dateStyle: 'medium',\n timeStyle: 'short',\n }).format(message.timestamp);\n }\n handleBack() {\n this.onBack()?.();\n this.back.emit();\n }\n static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: \"12.0.0\", version: \"20.3.3\", ngImport: i0, type: AXConversationInfoMediaViewComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }\n static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: \"17.0.0\", version: \"20.3.3\", type: AXConversationInfoMediaViewComponent, isStandalone: true, selector: \"ax-conversation-info-media-view\", inputs: { category: { classPropertyName: \"category\", publicName: \"category\", isSignal: true, isRequired: true, transformFunction: null }, messages: { classPropertyName: \"messages\", publicName: \"messages\", isSignal: true, isRequired: true, transformFunction: null }, conversation: { classPropertyName: \"conversation\", publicName: \"conversation\", isSignal: true, isRequired: true, transformFunction: null }, conversationServiceInput: { classPropertyName: \"conversationServiceInput\", publicName: \"conversationService\", isSignal: true, isRequired: true, transformFunction: null }, onBack: { classPropertyName: \"onBack\", publicName: \"onBack\", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { back: \"back\" }, ngImport: i0, template: `\n <div class=\"tg-media-view\">\n <header class=\"tg-media-view__header\">\n <button type=\"button\" class=\"tg-media-view__back\" (click)=\"handleBack()\" [attr.aria-label]=\"'Back'\">\n <i class=\"fa-light fa-arrow-left\"></i>\n </button>\n <h3 class=\"tg-media-view__title\">{{ titleLabel() }}</h3>\n </header>\n\n @if (items().length === 0) {\n <div class=\"tg-media-view__empty\">\n {{ '@acorex:chat.info-panel.media.empty' | translate | async }}\n </div>\n } @else if (isGrid()) {\n <div class=\"tg-media-view__grid\">\n @for (tile of galleryTiles(); track tile.key) {\n <article\n class=\"tg-media-view__grid-cell\"\n [class.tg-media-view__grid-cell--sticker]=\"tile.kind === 'sticker'\"\n >\n @switch (tile.kind) {\n @case ('image') {\n @if (tile.image; as image) {\n <ax-conversation-image-attachment [item]=\"image\" [alt]=\"'Photo'\" />\n }\n }\n @case ('sticker') {\n @if (tile.stickerUrl) {\n <img\n class=\"tg-media-view__sticker\"\n [src]=\"tile.stickerUrl\"\n [alt]=\"tile.stickerAlt ?? 'Sticker'\"\n loading=\"lazy\"\n />\n }\n }\n }\n </article>\n }\n </div>\n } @else if (isAttachmentList()) {\n <div class=\"tg-media-view__list\">\n @for (message of items(); track message.id) {\n <article class=\"tg-media-view__list-item\">\n <div class=\"tg-media-view__list-body\">\n @if (category().id === 'video') {\n @for (video of getMessageVideoItems(message); track video.mediaId ?? video.url) {\n <ax-conversation-video-attachment [item]=\"video\" />\n }\n } @else {\n @for (audio of getMessageAudioItems(message); track audio.mediaId ?? audio.url) {\n <ax-conversation-audio-attachment [item]=\"audio\" />\n }\n }\n </div>\n <time class=\"tg-media-view__list-meta\">{{ formatTimestamp(message) }}</time>\n </article>\n }\n </div>\n } @else {\n <div class=\"tg-media-view__list\">\n @for (message of items(); track message.id) {\n <article class=\"tg-media-view__list-item\">\n <div class=\"tg-media-view__list-body\">\n <ax-conversation-registry-component-outlet\n [component]=\"getRendererComponent(message)\"\n [componentLoader]=\"getRendererComponentLoader(message)\"\n [inputs]=\"getRendererInputs(message)\"\n />\n </div>\n <time class=\"tg-media-view__list-meta\">{{ formatTimestamp(message) }}</time>\n </article>\n }\n </div>\n }\n </div>\n `, isInline: true, styles: [\":host{display:block;width:100%}.tg-media-view{display:flex;flex-direction:column;min-height:12rem;max-height:min(85vh,40rem)}.tg-media-view__header{display:flex;align-items:center;gap:.5rem;padding:.65rem .75rem;border-bottom:1px solid rgb(var(--ax-sys-color-border-light-surface));flex-shrink:0}.tg-media-view__back{display:inline-flex;align-items:center;justify-content:center;width:2rem;height:2rem;border:none;border-radius:999px;background:transparent;color:rgb(var(--ax-sys-color-primary-500));cursor:pointer}.tg-media-view__back:hover{background:rgb(var(--ax-sys-color-lighter-surface))}.tg-media-view__title{margin:0;font-size:1rem;font-weight:600;color:rgb(var(--ax-sys-color-on-surface))}.tg-media-view__empty{padding:2rem 1rem;text-align:center;font-size:.875rem;color:rgb(var(--ax-sys-color-on-surface));opacity:.65}.tg-media-view__grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:2px;padding:2px;overflow-y:auto;overscroll-behavior:contain;background:rgb(var(--ax-sys-color-border-light-surface))}.tg-media-view__grid-cell{position:relative;aspect-ratio:1;overflow:hidden;background:rgb(var(--ax-sys-color-lighter-surface))}.tg-media-view__grid-cell--sticker{display:flex;align-items:center;justify-content:center;padding:.35rem}.tg-media-view__grid-cell ::ng-deep ax-conversation-image-attachment,.tg-media-view__grid-cell ::ng-deep .ax-conversation-image-attachment{width:100%;height:100%;min-height:0;border-radius:0}.tg-media-view__grid-cell ::ng-deep img{width:100%;height:100%;object-fit:cover}.tg-media-view__sticker{max-width:100%;max-height:100%;object-fit:contain}.tg-media-view__list{display:flex;flex-direction:column;overflow-y:auto;overscroll-behavior:contain}.tg-media-view__list-item{display:flex;flex-direction:column;gap:.35rem;padding:.75rem 1rem;border-bottom:1px solid rgb(var(--ax-sys-color-border-light-surface))}.tg-media-view__list-item:last-child{border-bottom:none}.tg-media-view__list-body{min-width:0;display:flex;flex-direction:column;gap:.5rem}.tg-media-view__list-body ::ng-deep .ax-conversation-msg{max-width:100%}.tg-media-view__list-body ::ng-deep ax-conversation-message-renderer-state{display:none}.tg-media-view__list-body ::ng-deep .ax-conversation-video__player{max-height:min(50vh,16rem)}.tg-media-view__list-meta{font-size:.75rem;color:rgb(var(--ax-sys-color-on-surface));opacity:.55}\\n\"], dependencies: [{ kind: \"ngmodule\", type: CommonModule }, { kind: \"component\", type: AXConversationRegistryComponentOutletComponent, selector: \"ax-conversation-registry-component-outlet\", inputs: [\"component\", \"componentLoader\", \"inputs\"] }, { kind: \"ngmodule\", type: AXDecoratorModule }, { kind: \"ngmodule\", type: AXTranslationModule }, { kind: \"component\", type: AXConversationImageAttachmentComponent, selector: \"ax-conversation-image-attachment\", inputs: [\"item\", \"alt\"] }, { kind: \"component\", type: AXConversationVideoAttachmentComponent, selector: \"ax-conversation-video-attachment\", inputs: [\"item\"], outputs: [\"playingChange\", \"timeUpdate\", \"durationChange\", \"playbackEnded\", \"playbackError\"] }, { kind: \"component\", type: AXConversationAudioAttachmentComponent, selector: \"ax-conversation-audio-attachment\", inputs: [\"item\"], outputs: [\"playingChange\", \"timeUpdate\", \"durationChange\", \"playbackEnded\", \"playbackError\"] }, { kind: \"pipe\", type: i1.AsyncPipe, name: \"async\" }, { kind: \"pipe\", type: i2.AXTranslatorPipe, name: \"translate\" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }\n}\ni0.ɵɵngDeclareClassMetadata({ minVersion: \"12.0.0\", version: \"20.3.3\", ngImport: i0, type: AXConversationInfoMediaViewComponent, decorators: [{\n type: Component,\n args: [{ selector: 'ax-conversation-info-media-view', changeDetection: ChangeDetectionStrategy.OnPush, imports: [\n CommonModule,\n AXConversationRegistryComponentOutletComponent,\n AXDecoratorModule,\n AXTranslationModule,\n AXConversationImageAttachmentComponent,\n AXConversationVideoAttachmentComponent,\n AXConversationAudioAttachmentComponent,\n ], template: `\n <div class=\"tg-media-view\">\n <header class=\"tg-media-view__header\">\n <button type=\"button\" class=\"tg-media-view__back\" (click)=\"handleBack()\" [attr.aria-label]=\"'Back'\">\n <i class=\"fa-light fa-arrow-left\"></i>\n </button>\n <h3 class=\"tg-media-view__title\">{{ titleLabel() }}</h3>\n </header>\n\n @if (items().length === 0) {\n <div class=\"tg-media-view__empty\">\n {{ '@acorex:chat.info-panel.media.empty' | translate | async }}\n </div>\n } @else if (isGrid()) {\n <div class=\"tg-media-view__grid\">\n @for (tile of galleryTiles(); track tile.key) {\n <article\n class=\"tg-media-view__grid-cell\"\n [class.tg-media-view__grid-cell--sticker]=\"tile.kind === 'sticker'\"\n >\n @switch (tile.kind) {\n @case ('image') {\n @if (tile.image; as image) {\n <ax-conversation-image-attachment [item]=\"image\" [alt]=\"'Photo'\" />\n }\n }\n @case ('sticker') {\n @if (tile.stickerUrl) {\n <img\n class=\"tg-media-view__sticker\"\n [src]=\"tile.stickerUrl\"\n [alt]=\"tile.stickerAlt ?? 'Sticker'\"\n loading=\"lazy\"\n />\n }\n }\n }\n </article>\n }\n </div>\n } @else if (isAttachmentList()) {\n <div class=\"tg-media-view__list\">\n @for (message of items(); track message.id) {\n <article class=\"tg-media-view__list-item\">\n <div class=\"tg-media-view__list-body\">\n @if (category().id === 'video') {\n @for (video of getMessageVideoItems(message); track video.mediaId ?? video.url) {\n <ax-conversation-video-attachment [item]=\"video\" />\n }\n } @else {\n @for (audio of getMessageAudioItems(message); track audio.mediaId ?? audio.url) {\n <ax-conversation-audio-attachment [item]=\"audio\" />\n }\n }\n </div>\n <time class=\"tg-media-view__list-meta\">{{ formatTimestamp(message) }}</time>\n </article>\n }\n </div>\n } @else {\n <div class=\"tg-media-view__list\">\n @for (message of items(); track message.id) {\n <article class=\"tg-media-view__list-item\">\n <div class=\"tg-media-view__list-body\">\n <ax-conversation-registry-component-outlet\n [component]=\"getRendererComponent(message)\"\n [componentLoader]=\"getRendererComponentLoader(message)\"\n [inputs]=\"getRendererInputs(message)\"\n />\n </div>\n <time class=\"tg-media-view__list-meta\">{{ formatTimestamp(message) }}</time>\n </article>\n }\n </div>\n }\n </div>\n `, styles: [\":host{display:block;width:100%}.tg-media-view{display:flex;flex-direction:column;min-height:12rem;max-height:min(85vh,40rem)}.tg-media-view__header{display:flex;align-items:center;gap:.5rem;padding:.65rem .75rem;border-bottom:1px solid rgb(var(--ax-sys-color-border-light-surface));flex-shrink:0}.tg-media-view__back{display:inline-flex;align-items:center;justify-content:center;width:2rem;height:2rem;border:none;border-radius:999px;background:transparent;color:rgb(var(--ax-sys-color-primary-500));cursor:pointer}.tg-media-view__back:hover{background:rgb(var(--ax-sys-color-lighter-surface))}.tg-media-view__title{margin:0;font-size:1rem;font-weight:600;color:rgb(var(--ax-sys-color-on-surface))}.tg-media-view__empty{padding:2rem 1rem;text-align:center;font-size:.875rem;color:rgb(var(--ax-sys-color-on-surface));opacity:.65}.tg-media-view__grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:2px;padding:2px;overflow-y:auto;overscroll-behavior:contain;background:rgb(var(--ax-sys-color-border-light-surface))}.tg-media-view__grid-cell{position:relative;aspect-ratio:1;overflow:hidden;background:rgb(var(--ax-sys-color-lighter-surface))}.tg-media-view__grid-cell--sticker{display:flex;align-items:center;justify-content:center;padding:.35rem}.tg-media-view__grid-cell ::ng-deep ax-conversation-image-attachment,.tg-media-view__grid-cell ::ng-deep .ax-conversation-image-attachment{width:100%;height:100%;min-height:0;border-radius:0}.tg-media-view__grid-cell ::ng-deep img{width:100%;height:100%;object-fit:cover}.tg-media-view__sticker{max-width:100%;max-height:100%;object-fit:contain}.tg-media-view__list{display:flex;flex-direction:column;overflow-y:auto;overscroll-behavior:contain}.tg-media-view__list-item{display:flex;flex-direction:column;gap:.35rem;padding:.75rem 1rem;border-bottom:1px solid rgb(var(--ax-sys-color-border-light-surface))}.tg-media-view__list-item:last-child{border-bottom:none}.tg-media-view__list-body{min-width:0;display:flex;flex-direction:column;gap:.5rem}.tg-media-view__list-body ::ng-deep .ax-conversation-msg{max-width:100%}.tg-media-view__list-body ::ng-deep ax-conversation-message-renderer-state{display:none}.tg-media-view__list-body ::ng-deep .ax-conversation-video__player{max-height:min(50vh,16rem)}.tg-media-view__list-meta{font-size:.75rem;color:rgb(var(--ax-sys-color-on-surface));opacity:.55}\\n\"] }]\n }] });\n//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29udmVyc2F0aW9uLWluZm8tbWVkaWEtdmlldy5jb21wb25lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi8uLi8uLi8uLi9wYWNrYWdlcy9jb21wb25lbnRzL2NvbnZlcnNhdGlvbi9zcmMvbGliL3BsdWdpbnMvaW5mby1iYXIvY29tcG9uZW50cy9jb252ZXJzYXRpb24taW5mby1tZWRpYS12aWV3LmNvbXBvbmVudC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQTs7R0FFRztBQUVILE9BQU8sRUFBRSxpQkFBaUIsRUFBRSxNQUFNLCtCQUErQixDQUFDO0FBQ2xFLE9BQU8sRUFBRSxtQkFBbUIsRUFBRSxvQkFBb0IsRUFBRSxNQUFNLDBCQUEwQixDQUFDO0FBQ3JGLE9BQU8sRUFBRSxZQUFZLEVBQUUsTUFBTSxpQkFBaUIsQ0FBQztBQUMvQyxPQUFPLEVBQUUsdUJBQXVCLEVBQUUsU0FBUyxFQUFFLFFBQVEsRUFBRSxNQUFNLEVBQUUsUUFBUSxFQUFFLEtBQUssRUFBRSxNQUFNLEVBQUUsTUFBTSxlQUFlLENBQUM7QUFDOUcsT0FBTyxFQUFFLDhDQUE4QyxFQUFFLE1BQU0sZ0VBQWdFLENBQUM7QUFFaEksT0FBTyxFQUFFLHFCQUFxQixFQUFFLE1BQU0sbUJBQW1CLENBQUM7QUFDMUQsT0FBTyxFQUFFLHNDQUFz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ZCkge1xuICAgICAgICAgICAgICAgIEBjYXNlICgnaW1hZ2UnKSB7XG4gICAgICAgICAgICAgICAgICBAaWYgKHRpbGUuaW1hZ2U7IGFzIGltYWdlKSB7XG4gICAgICAgICAgICAgICAgICAgIDxheC1jb252ZXJzYXRpb24taW1hZ2UtYXR0YWNobWVudCBbaXRlbV09XCJpbWFnZVwiIFthbHRdPVwiJ1Bob3RvJ1wiIC8+XG4gICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIEBjYXNlICgnc3RpY2tlcicpIHtcbiAgICAgICAgICAgICAgICAgIEBpZiAodGlsZS5zdGlja2VyVXJsKSB7XG4gICAgICAgICAgICAgICAgICAgIDxpbWdcbiAgICAgICAgICAgICAgICAgICAgICBjbGFzcz1cInRnLW1lZGlhLXZpZXdfX3N0aWNrZXJcIlxuICAgICAgICAgICAgICAgICAgICAgIFtzcmNdPVwidGlsZS5zdGlja2VyVXJsXCJcbiAgICAgICAgICAgICAgICAgICAgICBbYWx0XT1cInRpbGUuc3RpY2tlckFsdCA/PyAnU3RpY2tlcidcIlxuICAgICAgICAgICAgICAgICAgICAgIGxvYWRpbmc9XCJsYXp5XCJcbiAgICAgICAgICAgICAgICAgICAgLz5cbiAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgIH1cbiAgICAgICAgICAgIDwvYXJ0aWNsZT5cbiAgICAgICAgICB9XG4gICAgICAgIDwvZGl2PlxuICAgICAgfSBAZWxzZSBpZiAoaXNBdHRhY2htZW50TGlzdCgpKSB7XG4gICAgICAgIDxkaXYgY2xhc3M9XCJ0Zy1tZWRpYS12aWV3X19saXN0XCI+XG4gICAgICAgICAgQGZvciAobWVzc2FnZSBvZiBpdGVtcygpOyB0cmFjayBtZXNzYWdlLmlkKSB7XG4gICAgICAgICAgICA8YXJ0aWNsZSBjbGFzcz1cInRnLW1lZGlhLXZpZXdfX2xpc3QtaXRlbVwiPlxuICAgICAgICAgICAgICA8ZGl2IGNsYXNzPVwidGctbWVkaWEtdmlld19fbGlzdC1ib2R5XCI+XG4gICAgICAgICAgICAgICAgQGlmIChjYXRlZ29yeSgpLmlkID09PSAndmlkZW8nKSB7XG4gICAgICAgICAgICAgICAgICBAZm9yICh2aWRlbyBvZiBnZXRNZXNzYWdlVmlkZW9JdGVtcyhtZXNzYWdlKTsgdHJhY2sgdmlkZW8ubWVkaWFJZCA/PyB2aWRlby51cmwpIHtcbiAgICAgICAgICAgICAgICAgICAgPGF4LWNvbnZlcnNhdGlvbi12aWRlby1hdHRhY2htZW50IFtpdGVtXT1cInZpZGVvXCIgLz5cbiAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICB9IEBlbHNlIHtcbiAgICAgICAgICAgICAgICAgIEBmb3IgKGF1ZGlvIG9mIGdldE1lc3NhZ2VBdWRpb0l0ZW1zKG1lc3NhZ2UpOyB0cmFjayBhdWRpby5tZWRpYUlkID8/IGF1ZGlvLnVybCkge1xuICAgICAgICAgICAgICAgICAgICA8YXgtY29udmVyc2F0aW9uLWF1ZGlvLWF0dGFjaG1lbnQgW2l0ZW1dPVwiYXVkaW9cIiAvPlxuICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgPC9kaXY+XG4gICAgICAgICAgICAgIDx0aW1lIGNsYXNzPVwidGctbWVkaWEtdmlld19fbGlzdC1tZXRhXCI+e3sgZm9ybWF0VGltZXN0YW1wKG1lc3NhZ2UpIH19PC90aW1lPlxuICAgICAgICAgICAgPC9hcnRpY2xlPlxuICAgICAgICAgIH1cbiAgICAgICAgPC9kaXY+XG4gICAgICB9IEBlbHNlIHtcbiAgICAgICAgPGRpdiBjbGFzcz1cInRnLW1lZGlhLXZpZXdfX2xpc3RcIj5cbiAgICAgICAgICBAZm9yIChtZXNzYWdlIG9mIGl0ZW1zKCk7IHRyYWNrIG1lc3NhZ2UuaWQpIHtcbiAgICAgICAgICAgIDxhcnRpY2xlIGNsYXNzPVwidGctbWVkaWEtdmlld19fbGlzdC1pdGVtXCI+XG4gICAgICAgICAgICAgIDxkaXYgY2xhc3M9XCJ0Zy1tZWRpYS12aWV3X19saXN0LWJvZHlcIj5cbiAgICAgICAgICAgICAgICA8YXgtY29udmVyc2F0aW9uLXJlZ2lzdHJ5LWNvbXBvbmVudC1vdXRsZXRcbiAgICAgICAgICAgICAgICAgIFtjb21wb25lbnRdPVwiZ2V0UmVuZGVyZXJDb21wb25lbnQobWVzc2FnZSlcIlxuICAgICAgICAgICAgICAgICAgW2NvbXBvbmVudExvYWRlcl09XCJnZXRSZW5kZXJlckNvbXBvbmVudExvYWRlcihtZXNzYWdlKVwiXG4gICAgICAgICAgICAgICAgICBbaW5wdXRzXT1cImdldFJlbmRlcmVySW5wdXRzKG1lc3NhZ2UpXCJcbiAgICAgICAgICAgICAgICAvPlxuICAgICAgICAgICAgICA8L2Rpdj5cbiAgICAgICAgICAgICAgPHRpbWUgY2xhc3M9XCJ0Zy1tZWRpYS12aWV3X19saXN0LW1ldGFcIj57eyBmb3JtYXRUaW1lc3RhbXAobWVzc2FnZSkgfX08L3RpbWU+XG4gICAgICAgICAgICA8L2FydGljbGU+XG4gICAgICAgICAgfVxuICAgICAgICA8L2Rpdj5cbiAgICAgIH1cbiAgICA8L2Rpdj5cbiAgYCxcbiAgc3R5bGVzOiBbXG4gICAgYFxuICAgICAgOmhvc3Qge1xuICAgICAgICBkaXNwbGF5OiBibG9jaztcbiAgICAgICAgd2lkdGg6IDEwMCU7XG4gICAgICB9XG5cbiAgICAgIC50Zy1tZWRpYS12aWV3IHtcbiAgICAgICAgZGlzcGxheTogZmxleDtcbiAgICAgICAgZmxleC1kaXJlY3Rpb246IGNvbHVtbjtcbiAgICAgICAgbWluLWhlaWdodDogMTJyZW07XG4gICAgICAgIG1heC1oZWlnaHQ6IG1pbig4NXZoLCA0MHJlbSk7XG4gICAgICB9XG5cbiAgICAgIC50Zy1tZWRpYS12aWV3X19oZWFkZXIge1xuICAgICAgICBkaXNwbGF5OiBmbGV4O1xuICAgICAgICBhbGlnbi1pdGVtczogY2VudGVyO1xuICAgICAgICBnYXA6IDAuNXJlbTtcbiAgICAgICAgcGFkZGluZzogMC42NXJlbSAwLjc1cmVtO1xuICAgICAgICBib3JkZXItYm90dG9tOiAxcHggc29saWQgcmdiKHZhcigtLWF4LXN5cy1jb2xvci1ib3JkZXItbGlnaHQtc3VyZmFjZSkpO1xuICAgICAgICBmbGV4LXNocmluazogMDtcbiAgICAgIH1cblxuICAgICAgLnRnLW1lZGlhLXZpZXdfX2JhY2sge1xuICAgICAgICBkaXNwbGF5OiBpbmxpbmUtZmxleDtcbiAgICAgICAgYWxpZ24taXRlbXM6IGNlbnRlcjtcbiAgICAgICAganVzdGlmeS1jb250ZW50OiBjZW50ZXI7XG4gICAgICAgIHdpZHRoOiAycmVtO1xuICAgICAgICBoZWlnaHQ6IDJyZW07XG4gICAgICAgIGJvcmRlcjogbm9uZTtcbiAgICAgICAgYm9yZGVyLXJhZGl1czogOTk5cHg7XG4gICAgICAgIGJhY2tncm91bmQ6IHRyYW5zcGFyZW50O1xuICAgICAgICBjb2xvcjogcmdiKHZhcigtLWF4LXN5cy1jb2xvci1wcmltYXJ5LTUwMCkpO1xuICAgICAgICBjdXJzb3I6IHBvaW50ZXI7XG4gICAgICB9XG5cbiAgICAgIC50Zy1tZWRpYS12aWV3X19iYWNrOmhvdmVyIHtcbiAgICAgICAgYmFja2dyb3VuZDogcmdiKHZhcigtLWF4LXN5cy1jb2xvci1saWdodGVyLXN1cmZhY2UpKTtcbiAgICAgIH1cblxuICAgICAgLnRnLW1lZGlhLXZpZXdfX3RpdGxlIHtcbiAgICAgICAgbWFyZ2luOiAwO1xuICAgICAgICBmb250LXNpemU6IDFyZW07XG4gICAgICAgIGZvbnQtd2VpZ2h0OiA2MDA7XG4gICAgICAgIGNvbG9yOiByZ2IodmFyKC0tYXgtc3lzLWNvbG9yLW9uLXN1cmZ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