stream-chat-angular 4.37.0 → 4.38.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/assets/version.d.ts +1 -1
- package/bundles/stream-chat-angular.umd.js +54 -11
- package/bundles/stream-chat-angular.umd.js.map +1 -1
- package/esm2015/assets/version.js +2 -2
- package/esm2015/lib/avatar-placeholder/avatar-placeholder.component.js +51 -8
- package/esm2015/lib/channel-header/channel-header.component.js +1 -1
- package/esm2015/lib/channel-preview/channel-preview.component.js +1 -1
- package/esm2015/lib/message/message.component.js +1 -1
- package/esm2015/lib/message-input/autocomplete-textarea/autocomplete-textarea.component.js +1 -1
- package/esm2015/lib/message-input/message-input.component.js +1 -1
- package/esm2015/lib/message-reactions/message-reactions.component.js +1 -1
- package/esm2015/lib/types.js +1 -1
- package/fesm2015/stream-chat-angular.js +53 -11
- package/fesm2015/stream-chat-angular.js.map +1 -1
- package/lib/avatar-placeholder/avatar-placeholder.component.d.ts +17 -4
- package/lib/types.d.ts +1 -0
- package/package.json +1 -1
- package/src/assets/version.ts +1 -1
|
@@ -1,13 +1,17 @@
|
|
|
1
|
-
import { OnChanges } from '@angular/core';
|
|
1
|
+
import { AfterViewInit, ChangeDetectorRef, ElementRef, OnChanges, OnDestroy } from '@angular/core';
|
|
2
2
|
import { Channel, User } from 'stream-chat';
|
|
3
3
|
import { CustomTemplatesService } from '../custom-templates.service';
|
|
4
4
|
import { AvatarContext, AvatarLocation, AvatarType, DefaultStreamChatGenerics } from '../types';
|
|
5
|
+
import { ThemeService } from '../theme.service';
|
|
5
6
|
import * as i0 from "@angular/core";
|
|
6
7
|
/**
|
|
7
8
|
* The `AvatarPlaceholder` component displays the [default avatar](./AvatarComponent.mdx) unless a [custom template](../services/CustomTemplatesService.mdx) is provided. This component is used by the SDK internally, you likely won't need to use it.
|
|
8
9
|
*/
|
|
9
|
-
export declare class AvatarPlaceholderComponent implements OnChanges {
|
|
10
|
+
export declare class AvatarPlaceholderComponent implements OnChanges, AfterViewInit, OnDestroy {
|
|
10
11
|
customTemplatesService: CustomTemplatesService;
|
|
12
|
+
private hostElement;
|
|
13
|
+
private cdRef;
|
|
14
|
+
private themeService;
|
|
11
15
|
/**
|
|
12
16
|
* An optional name of the image, used for fallback image or image title (if `imageUrl` is provided)
|
|
13
17
|
*/
|
|
@@ -40,9 +44,18 @@ export declare class AvatarPlaceholderComponent implements OnChanges {
|
|
|
40
44
|
* If channel/user image isn't provided the initials of the name of the channel/user is shown instead, you can choose how the initals should be computed
|
|
41
45
|
*/
|
|
42
46
|
initialsType: 'first-letter-of-first-word' | 'first-letter-of-each-word';
|
|
47
|
+
/**
|
|
48
|
+
* If a channel avatar is displayed, and if the channel has exactly two members a green dot is displayed if the other member is online. Set this flag to `false` to turn off this behavior.
|
|
49
|
+
*/
|
|
50
|
+
showOnlineIndicator: boolean;
|
|
43
51
|
context: AvatarContext;
|
|
44
|
-
|
|
52
|
+
isVisible: boolean;
|
|
53
|
+
private mutationObserver?;
|
|
54
|
+
constructor(customTemplatesService: CustomTemplatesService, hostElement: ElementRef<HTMLElement>, cdRef: ChangeDetectorRef, themeService: ThemeService);
|
|
55
|
+
ngAfterViewInit(): void;
|
|
45
56
|
ngOnChanges(): void;
|
|
57
|
+
ngOnDestroy(): void;
|
|
58
|
+
private checkIfVisible;
|
|
46
59
|
static ɵfac: i0.ɵɵFactoryDeclaration<AvatarPlaceholderComponent, never>;
|
|
47
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<AvatarPlaceholderComponent, "stream-avatar-placeholder", never, { "name": "name"; "imageUrl": "imageUrl"; "size": "size"; "location": "location"; "channel": "channel"; "user": "user"; "type": "type"; "initialsType": "initialsType"; }, {}, never, never>;
|
|
60
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<AvatarPlaceholderComponent, "stream-avatar-placeholder", never, { "name": "name"; "imageUrl": "imageUrl"; "size": "size"; "location": "location"; "channel": "channel"; "user": "user"; "type": "type"; "initialsType": "initialsType"; "showOnlineIndicator": "showOnlineIndicator"; }, {}, never, never>;
|
|
48
61
|
}
|
package/lib/types.d.ts
CHANGED
|
@@ -132,6 +132,7 @@ export declare type AvatarContext = {
|
|
|
132
132
|
channel?: Channel<DefaultStreamChatGenerics>;
|
|
133
133
|
user?: User<DefaultStreamChatGenerics>;
|
|
134
134
|
initialsType?: 'first-letter-of-first-word' | 'first-letter-of-each-word';
|
|
135
|
+
showOnlineIndicator?: boolean;
|
|
135
136
|
};
|
|
136
137
|
export declare type AttachmentPreviewListContext = {
|
|
137
138
|
attachmentUploads$: Observable<AttachmentUpload[]> | undefined;
|
package/package.json
CHANGED
package/src/assets/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const version = '4.
|
|
1
|
+
export const version = '4.38.1';
|