@banta/sdk 4.0.4 → 4.0.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.
- package/bundles/banta-sdk.umd.js +154 -19
- package/bundles/banta-sdk.umd.js.map +1 -1
- package/bundles/banta-sdk.umd.min.js +1 -1
- package/bundles/banta-sdk.umd.min.js.map +1 -1
- package/esm2015/lib/comments/attachment-button/attachment-button.component.js +58 -0
- package/esm2015/lib/comments/banta-comments/banta-comments.component.js +5 -3
- package/esm2015/lib/comments/comment/comment.component.js +12 -5
- package/esm2015/lib/comments/comment-field/comment-field.component.js +27 -6
- package/esm2015/lib/comments/comment-sort/comment-sort.component.js +3 -3
- package/esm2015/lib/comments/comments.module.js +4 -2
- package/esm2015/lib/comments/index.js +2 -1
- package/esm2015/lib/common/common.module.js +7 -3
- package/esm2015/lib/common/index.js +2 -1
- package/esm2015/lib/common/lightbox/lightbox.component.js +28 -0
- package/fesm2015/banta-sdk.js +132 -19
- package/fesm2015/banta-sdk.js.map +1 -1
- package/lib/comments/attachment-button/attachment-button.component.d.ts +12 -0
- package/lib/comments/banta-comments/banta-comments.component.d.ts +1 -0
- package/lib/comments/comment/comment.component.d.ts +4 -1
- package/lib/comments/comment-field/comment-field.component.d.ts +6 -1
- package/lib/comments/index.d.ts +1 -0
- package/lib/common/index.d.ts +1 -0
- package/lib/common/lightbox/lightbox.component.d.ts +11 -0
- package/package.json +1 -1
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ElementRef } from '@angular/core';
|
|
2
|
+
import { CDNProvider, ChatMessageAttachment } from '@banta/common';
|
|
3
|
+
import { Subject } from 'rxjs';
|
|
4
|
+
export declare class AttachmentButtonComponent {
|
|
5
|
+
private cdnProvider;
|
|
6
|
+
constructor(cdnProvider: CDNProvider);
|
|
7
|
+
fileInput: ElementRef;
|
|
8
|
+
_addedAttachment: Subject<ChatMessageAttachment>;
|
|
9
|
+
get addedAttachment(): import("rxjs").Observable<ChatMessageAttachment>;
|
|
10
|
+
show(): void;
|
|
11
|
+
fileChange(event: Event): Promise<void>;
|
|
12
|
+
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { ChatMessage, ChatPermissions, User } from '@banta/common';
|
|
1
|
+
import { ChatMessage, ChatMessageAttachment, ChatPermissions, User } from '@banta/common';
|
|
2
|
+
import { LightboxComponent } from "../../common/lightbox/lightbox.component";
|
|
2
3
|
export declare class CommentComponent {
|
|
3
4
|
private _reported;
|
|
4
5
|
private _selected;
|
|
@@ -47,5 +48,7 @@ export declare class CommentComponent {
|
|
|
47
48
|
selectUser(): void;
|
|
48
49
|
selectUsername(user: User): void;
|
|
49
50
|
selectAvatar(user: User): void;
|
|
51
|
+
lightbox: LightboxComponent;
|
|
52
|
+
showLightbox(image: ChatMessageAttachment): void;
|
|
50
53
|
avatarForUser(user: User): string;
|
|
51
54
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ElementRef } from "@angular/core";
|
|
2
|
-
import { ChatMessage, User } from "@banta/common";
|
|
2
|
+
import { ChatMessage, ChatMessageAttachment, User } from "@banta/common";
|
|
3
3
|
import { Observable, Subject } from "rxjs";
|
|
4
4
|
import { ChatSourceBase } from "../../chat-source-base";
|
|
5
5
|
export interface AutoCompleteOption {
|
|
@@ -14,6 +14,7 @@ export declare class CommentFieldComponent {
|
|
|
14
14
|
source: ChatSourceBase;
|
|
15
15
|
user: User;
|
|
16
16
|
canComment: boolean;
|
|
17
|
+
allowAttachments: boolean;
|
|
17
18
|
signInSelected: Subject<void>;
|
|
18
19
|
editAvatarSelected: Subject<void>;
|
|
19
20
|
sending: boolean;
|
|
@@ -57,4 +58,8 @@ export declare class CommentFieldComponent {
|
|
|
57
58
|
showEditAvatar(): void;
|
|
58
59
|
submit: (message: ChatMessage) => boolean;
|
|
59
60
|
sendMessage(): Promise<void>;
|
|
61
|
+
chatMessageAttachments: ChatMessageAttachment[];
|
|
62
|
+
addedAttachment(file: ChatMessageAttachment): void;
|
|
63
|
+
removeAttachment(index: number): void;
|
|
64
|
+
alertError(): void;
|
|
60
65
|
}
|
package/lib/comments/index.d.ts
CHANGED
|
@@ -4,4 +4,5 @@ export * from './banta-comments/banta-comments.component';
|
|
|
4
4
|
export * from './live-comment.component';
|
|
5
5
|
export * from './comment-field/comment-field.component';
|
|
6
6
|
export * from './comment-sort/comment-sort.component';
|
|
7
|
+
export * from './attachment-button/attachment-button.component';
|
|
7
8
|
export * from './comments.module';
|
package/lib/common/index.d.ts
CHANGED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ElementRef } from "@angular/core";
|
|
2
|
+
export declare class LightboxComponent {
|
|
3
|
+
containerElement: ElementRef<HTMLDivElement>;
|
|
4
|
+
ngAfterViewInit(): void;
|
|
5
|
+
ngOnDestroy(): void;
|
|
6
|
+
images: string[];
|
|
7
|
+
currentImage: string;
|
|
8
|
+
isOpen: boolean;
|
|
9
|
+
close(): void;
|
|
10
|
+
open(currentImage: string, images: string[]): void;
|
|
11
|
+
}
|