@ohos-ports/stream-chat-angular 0.0.0-stage → 7.2.0-beta.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/README.md +139 -2
- package/assets/i18n/en.d.ts +157 -0
- package/assets/version.d.ts +1 -0
- package/esm2022/assets/i18n/en.mjs +158 -0
- package/esm2022/assets/version.mjs +2 -0
- package/esm2022/lib/attachment-configuration.service.mjs +182 -0
- package/esm2022/lib/attachment-list/attachment-list.component.mjs +232 -0
- package/esm2022/lib/attachment-preview-list/attachment-preview-list.component.mjs +55 -0
- package/esm2022/lib/attachment.service.mjs +481 -0
- package/esm2022/lib/avatar/avatar.component.mjs +160 -0
- package/esm2022/lib/avatar-placeholder/avatar-placeholder.component.mjs +66 -0
- package/esm2022/lib/channel/channel.component.mjs +45 -0
- package/esm2022/lib/channel-header/channel-header.component.mjs +72 -0
- package/esm2022/lib/channel-list/channel-list.component.mjs +47 -0
- package/esm2022/lib/channel-preview/channel-preview.component.mjs +158 -0
- package/esm2022/lib/channel-query.mjs +77 -0
- package/esm2022/lib/channel.service.mjs +1576 -0
- package/esm2022/lib/chat-client.service.mjs +233 -0
- package/esm2022/lib/custom-templates.service.mjs +258 -0
- package/esm2022/lib/date-parser.service.mjs +51 -0
- package/esm2022/lib/file-utils.mjs +35 -0
- package/esm2022/lib/format-duration.mjs +16 -0
- package/esm2022/lib/get-channel-display-text.mjs +14 -0
- package/esm2022/lib/get-message-translation.mjs +12 -0
- package/esm2022/lib/icon/icon-placeholder/icon-placeholder.component.mjs +28 -0
- package/esm2022/lib/icon/icon.component.mjs +17 -0
- package/esm2022/lib/icon/icon.module.mjs +37 -0
- package/esm2022/lib/icon/loading-indicator/loading-indicator.component.mjs +15 -0
- package/esm2022/lib/icon/loading-indicator-placeholder/loading-indicator-placeholder.component.mjs +20 -0
- package/esm2022/lib/injection-tokens.mjs +3 -0
- package/esm2022/lib/is-image-attachment.mjs +6 -0
- package/esm2022/lib/is-on-separate-date.mjs +11 -0
- package/esm2022/lib/is-safari.mjs +2 -0
- package/esm2022/lib/list-users.mjs +12 -0
- package/esm2022/lib/message/message.component.mjs +501 -0
- package/esm2022/lib/message-actions-box/message-actions-box.component.mjs +123 -0
- package/esm2022/lib/message-actions.service.mjs +191 -0
- package/esm2022/lib/message-blocked/message-blocked.component.mjs +25 -0
- package/esm2022/lib/message-bounce-prompt/message-bounce-prompt.component.mjs +71 -0
- package/esm2022/lib/message-input/autocomplete-textarea/autocomplete-textarea.component.mjs +333 -0
- package/esm2022/lib/message-input/emoji-input.service.mjs +23 -0
- package/esm2022/lib/message-input/message-input-config.service.mjs +50 -0
- package/esm2022/lib/message-input/message-input.component.mjs +626 -0
- package/esm2022/lib/message-input/textarea/textarea.component.mjs +113 -0
- package/esm2022/lib/message-input/textarea.directive.mjs +93 -0
- package/esm2022/lib/message-input/textarea.interface.mjs +2 -0
- package/esm2022/lib/message-input/voice-recorder.service.mjs +27 -0
- package/esm2022/lib/message-list/group-styles.mjs +52 -0
- package/esm2022/lib/message-list/message-list.component.mjs +717 -0
- package/esm2022/lib/message-preview.mjs +22 -0
- package/esm2022/lib/message-reactions/message-reactions.component.mjs +168 -0
- package/esm2022/lib/message-reactions-selector/message-reactions-selector.component.mjs +61 -0
- package/esm2022/lib/message-reactions.service.mjs +70 -0
- package/esm2022/lib/message-text/message-text.component.mjs +141 -0
- package/esm2022/lib/message.service.mjs +43 -0
- package/esm2022/lib/modal/modal.component.mjs +69 -0
- package/esm2022/lib/modal/stream-modal.module.mjs +19 -0
- package/esm2022/lib/notification/notification.component.mjs +20 -0
- package/esm2022/lib/notification-list/notification-list.component.mjs +36 -0
- package/esm2022/lib/notification-list/stream-notification.module.mjs +20 -0
- package/esm2022/lib/notification.service.mjs +79 -0
- package/esm2022/lib/paginated-list/paginated-list.component.mjs +94 -0
- package/esm2022/lib/paginated-list/stream-paginated-list.module.mjs +20 -0
- package/esm2022/lib/parse-date.mjs +27 -0
- package/esm2022/lib/polls/base-poll.component.mjs +87 -0
- package/esm2022/lib/polls/poll/poll.component.mjs +34 -0
- package/esm2022/lib/polls/poll-actions/add-option/add-option.component.mjs +67 -0
- package/esm2022/lib/polls/poll-actions/poll-actions.component.mjs +137 -0
- package/esm2022/lib/polls/poll-actions/poll-answers-list/poll-answers-list.component.mjs +82 -0
- package/esm2022/lib/polls/poll-actions/poll-results/poll-results-list/poll-results-list.component.mjs +63 -0
- package/esm2022/lib/polls/poll-actions/poll-results/poll-vote/poll-vote.component.mjs +33 -0
- package/esm2022/lib/polls/poll-actions/poll-results/poll-vote-results-list/poll-vote-results-list.component.mjs +82 -0
- package/esm2022/lib/polls/poll-actions/upsert-answer/upsert-answer.component.mjs +60 -0
- package/esm2022/lib/polls/poll-composer/poll-composer.component.mjs +134 -0
- package/esm2022/lib/polls/poll-composer/validators.mjs +18 -0
- package/esm2022/lib/polls/poll-header/poll-header.component.mjs +80 -0
- package/esm2022/lib/polls/poll-option-selector/poll-option-selector.component.mjs +137 -0
- package/esm2022/lib/polls/poll-options-list/poll-options-list.component.mjs +39 -0
- package/esm2022/lib/polls/poll-preview/poll-preview.component.mjs +31 -0
- package/esm2022/lib/polls/stream-polls.module.mjs +107 -0
- package/esm2022/lib/polls/unique.validator.mjs +13 -0
- package/esm2022/lib/read-by.mjs +13 -0
- package/esm2022/lib/stream-autocomplete-textarea.module.mjs +33 -0
- package/esm2022/lib/stream-avatar.module.mjs +20 -0
- package/esm2022/lib/stream-chat.module.mjs +163 -0
- package/esm2022/lib/stream-i18n.service.mjs +34 -0
- package/esm2022/lib/stream-textarea.module.mjs +31 -0
- package/esm2022/lib/theme.service.mjs +23 -0
- package/esm2022/lib/thread/thread.component.mjs +51 -0
- package/esm2022/lib/transliteration.service.mjs +24 -0
- package/esm2022/lib/types-custom.mjs +2 -0
- package/esm2022/lib/types.mjs +2 -0
- package/esm2022/lib/user-list/user-list.component.mjs +47 -0
- package/esm2022/lib/virtualized-list.service.mjs +271 -0
- package/esm2022/lib/virtualized-message-list.service.mjs +73 -0
- package/esm2022/lib/voice-recorder/amplitude-recorder.service.mjs +119 -0
- package/esm2022/lib/voice-recorder/audio-recorder.service.mjs +79 -0
- package/esm2022/lib/voice-recorder/media-recorder.mjs +190 -0
- package/esm2022/lib/voice-recorder/mp3-transcoder.mjs +61 -0
- package/esm2022/lib/voice-recorder/transcoder.service.mjs +121 -0
- package/esm2022/lib/voice-recorder/voice-recorder-wavebar/voice-recorder-wavebar.component.mjs +35 -0
- package/esm2022/lib/voice-recorder/voice-recorder.component.mjs +80 -0
- package/esm2022/lib/voice-recorder/voice-recorder.module.mjs +34 -0
- package/esm2022/lib/voice-recording/voice-recording-wavebar/voice-recording-wavebar.component.mjs +112 -0
- package/esm2022/lib/voice-recording/voice-recording.component.mjs +91 -0
- package/esm2022/lib/voice-recording/voice-recording.module.mjs +21 -0
- package/esm2022/lib/wave-form-sampler.mjs +72 -0
- package/esm2022/public-api.mjs +104 -0
- package/esm2022/stream-chat-angular.mjs +5 -0
- package/esm2022/stream-chat.mjs +2 -0
- package/fesm2022/stream-chat-angular.mjs +10363 -0
- package/fesm2022/stream-chat-angular.mjs.map +1 -0
- package/index.d.ts +5 -0
- package/lib/attachment-configuration.service.d.ts +58 -0
- package/lib/attachment-list/attachment-list.component.d.ts +76 -0
- package/lib/attachment-preview-list/attachment-preview-list.component.d.ts +37 -0
- package/lib/attachment.service.d.ts +104 -0
- package/lib/avatar/avatar.component.d.ts +64 -0
- package/lib/avatar-placeholder/avatar-placeholder.component.d.ts +48 -0
- package/lib/channel/channel.component.d.ts +22 -0
- package/lib/channel-header/channel-header.component.d.ts +36 -0
- package/lib/channel-list/channel-list.component.d.ts +30 -0
- package/lib/channel-preview/channel-preview.component.d.ts +46 -0
- package/lib/channel-query.d.ts +26 -0
- package/lib/channel.service.d.ts +482 -0
- package/lib/chat-client.service.d.ts +91 -0
- package/lib/custom-templates.service.d.ts +258 -0
- package/lib/date-parser.service.d.ts +39 -0
- package/lib/file-utils.d.ts +9 -0
- package/lib/format-duration.d.ts +1 -0
- package/lib/get-channel-display-text.d.ts +2 -0
- package/lib/get-message-translation.d.ts +3 -0
- package/lib/icon/icon-placeholder/icon-placeholder.component.d.ts +20 -0
- package/lib/icon/icon.component.d.ts +14 -0
- package/lib/icon/icon.module.d.ts +11 -0
- package/lib/icon/loading-indicator/loading-indicator.component.d.ts +9 -0
- package/lib/icon/loading-indicator-placeholder/loading-indicator-placeholder.component.d.ts +11 -0
- package/lib/injection-tokens.d.ts +3 -0
- package/lib/is-image-attachment.d.ts +2 -0
- package/lib/is-on-separate-date.d.ts +1 -0
- package/lib/is-safari.d.ts +1 -0
- package/lib/list-users.d.ts +2 -0
- package/lib/message/message.component.d.ts +126 -0
- package/lib/message-actions-box/message-actions-box.component.d.ts +49 -0
- package/lib/message-actions.service.d.ts +49 -0
- package/lib/message-blocked/message-blocked.component.d.ts +17 -0
- package/lib/message-bounce-prompt/message-bounce-prompt.component.d.ts +28 -0
- package/lib/message-input/autocomplete-textarea/autocomplete-textarea.component.d.ts +98 -0
- package/lib/message-input/emoji-input.service.d.ts +14 -0
- package/lib/message-input/message-input-config.service.d.ts +54 -0
- package/lib/message-input/message-input.component.d.ts +189 -0
- package/lib/message-input/textarea/textarea.component.d.ts +55 -0
- package/lib/message-input/textarea.directive.d.ts +24 -0
- package/lib/message-input/textarea.interface.d.ts +14 -0
- package/lib/message-input/voice-recorder.service.d.ts +19 -0
- package/lib/message-list/group-styles.d.ts +3 -0
- package/lib/message-list/message-list.component.d.ts +146 -0
- package/lib/message-preview.d.ts +2 -0
- package/lib/message-reactions/message-reactions.component.d.ts +69 -0
- package/lib/message-reactions-selector/message-reactions-selector.component.d.ts +35 -0
- package/lib/message-reactions.service.d.ts +50 -0
- package/lib/message-text/message-text.component.d.ts +45 -0
- package/lib/message.service.d.ts +38 -0
- package/lib/modal/modal.component.d.ts +29 -0
- package/lib/modal/stream-modal.module.d.ts +9 -0
- package/lib/notification/notification.component.d.ts +19 -0
- package/lib/notification-list/notification-list.component.d.ts +23 -0
- package/lib/notification-list/stream-notification.module.d.ts +10 -0
- package/lib/notification.service.d.ts +38 -0
- package/lib/paginated-list/paginated-list.component.d.ts +45 -0
- package/lib/paginated-list/stream-paginated-list.module.d.ts +10 -0
- package/lib/parse-date.d.ts +1 -0
- package/lib/polls/base-poll.component.d.ts +43 -0
- package/lib/polls/poll/poll.component.d.ts +12 -0
- package/lib/polls/poll-actions/add-option/add-option.component.d.ts +22 -0
- package/lib/polls/poll-actions/poll-actions.component.d.ts +50 -0
- package/lib/polls/poll-actions/poll-answers-list/poll-answers-list.component.d.ts +25 -0
- package/lib/polls/poll-actions/poll-results/poll-results-list/poll-results-list.component.d.ts +22 -0
- package/lib/polls/poll-actions/poll-results/poll-vote/poll-vote.component.d.ts +20 -0
- package/lib/polls/poll-actions/poll-results/poll-vote-results-list/poll-vote-results-list.component.d.ts +24 -0
- package/lib/polls/poll-actions/upsert-answer/upsert-answer.component.d.ts +27 -0
- package/lib/polls/poll-composer/poll-composer.component.d.ts +43 -0
- package/lib/polls/poll-composer/validators.d.ts +3 -0
- package/lib/polls/poll-header/poll-header.component.d.ts +19 -0
- package/lib/polls/poll-option-selector/poll-option-selector.component.d.ts +27 -0
- package/lib/polls/poll-options-list/poll-options-list.component.d.ts +17 -0
- package/lib/polls/poll-preview/poll-preview.component.d.ts +13 -0
- package/lib/polls/stream-polls.module.d.ts +26 -0
- package/lib/polls/unique.validator.d.ts +2 -0
- package/lib/read-by.d.ts +2 -0
- package/lib/stream-autocomplete-textarea.module.d.ts +11 -0
- package/lib/stream-avatar.module.d.ts +10 -0
- package/lib/stream-chat.module.d.ts +35 -0
- package/lib/stream-i18n.service.d.ts +19 -0
- package/lib/stream-textarea.module.d.ts +9 -0
- package/lib/theme.service.d.ts +14 -0
- package/lib/thread/thread.component.d.ts +26 -0
- package/lib/transliteration.service.d.ts +15 -0
- package/lib/types-custom.d.ts +16 -0
- package/lib/types.d.ts +365 -0
- package/lib/user-list/user-list.component.d.ts +29 -0
- package/lib/virtualized-list.service.d.ts +58 -0
- package/lib/virtualized-message-list.service.d.ts +15 -0
- package/lib/voice-recorder/amplitude-recorder.service.d.ts +71 -0
- package/lib/voice-recorder/audio-recorder.service.d.ts +46 -0
- package/lib/voice-recorder/media-recorder.d.ts +46 -0
- package/lib/voice-recorder/mp3-transcoder.d.ts +1 -0
- package/lib/voice-recorder/transcoder.service.d.ts +40 -0
- package/lib/voice-recorder/voice-recorder-wavebar/voice-recorder-wavebar.component.d.ts +21 -0
- package/lib/voice-recorder/voice-recorder.component.d.ts +30 -0
- package/lib/voice-recorder/voice-recorder.module.d.ts +12 -0
- package/lib/voice-recording/voice-recording-wavebar/voice-recording-wavebar.component.d.ts +36 -0
- package/lib/voice-recording/voice-recording.component.d.ts +29 -0
- package/lib/voice-recording/voice-recording.module.d.ts +11 -0
- package/lib/wave-form-sampler.d.ts +1 -0
- package/package.json +62 -4
- package/public-api.d.ts +99 -0
- package/src/assets/assets/EmojiOneColor.woff2 +0 -0
- package/src/assets/assets/NotoColorEmoji-flags.woff2 +0 -0
- package/src/assets/assets/icons/stream-chat-icons.eot +0 -0
- package/src/assets/assets/icons/stream-chat-icons.svg +50 -0
- package/src/assets/assets/icons/stream-chat-icons.ttf +0 -0
- package/src/assets/assets/icons/stream-chat-icons.woff +0 -0
- package/src/assets/assets/icons/stream-chat-icons.woff2 +0 -0
- package/src/assets/i18n/en.ts +184 -0
- package/src/assets/styles/css/emoji-mart.css +1 -0
- package/src/assets/styles/css/emoji-replacement.css +1 -0
- package/src/assets/styles/css/index.css +1 -0
- package/src/assets/styles/css/index.layout.css +1 -0
- package/src/assets/styles/scss/AIStateIndicator/AIStateIndicator-layout.scss +3 -0
- package/src/assets/styles/scss/AIStateIndicator/AIStateIndicator-theme.scss +7 -0
- package/src/assets/styles/scss/AttachmentList/AttachmentList-layout.scss +701 -0
- package/src/assets/styles/scss/AttachmentList/AttachmentList-theme.scss +605 -0
- package/src/assets/styles/scss/AttachmentPreviewList/AttachmentPreviewList-layout.scss +141 -0
- package/src/assets/styles/scss/AttachmentPreviewList/AttachmentPreviewList-theme.scss +190 -0
- package/src/assets/styles/scss/AudioRecorder/AudioRecorder-layout.scss +139 -0
- package/src/assets/styles/scss/AudioRecorder/AudioRecorder-theme.scss +61 -0
- package/src/assets/styles/scss/Autocomplete/Autocomplete-layout.scss +94 -0
- package/src/assets/styles/scss/Autocomplete/Autocomplete-theme.scss +220 -0
- package/src/assets/styles/scss/Avatar/Avatar-layout.scss +137 -0
- package/src/assets/styles/scss/Avatar/Avatar-theme.scss +64 -0
- package/src/assets/styles/scss/BaseImage/BaseImage-layout.scss +21 -0
- package/src/assets/styles/scss/BaseImage/BaseImage-theme.scss +35 -0
- package/src/assets/styles/scss/BaseImage/index.scss +2 -0
- package/src/assets/styles/scss/Channel/Channel-layout.scss +141 -0
- package/src/assets/styles/scss/Channel/Channel-theme.scss +100 -0
- package/src/assets/styles/scss/ChannelHeader/ChannelHeader-layout.scss +27 -0
- package/src/assets/styles/scss/ChannelHeader/ChannelHeader-theme.scss +43 -0
- package/src/assets/styles/scss/ChannelList/ChannelList-layout.scss +65 -0
- package/src/assets/styles/scss/ChannelList/ChannelList-theme.scss +89 -0
- package/src/assets/styles/scss/ChannelPreview/ChannelPreview-layout.scss +126 -0
- package/src/assets/styles/scss/ChannelPreview/ChannelPreview-theme.scss +148 -0
- package/src/assets/styles/scss/ChannelSearch/ChannelSearch-layout.scss +122 -0
- package/src/assets/styles/scss/ChannelSearch/ChannelSearch-theme.scss +238 -0
- package/src/assets/styles/scss/ChatView/ChatView-layout.scss +43 -0
- package/src/assets/styles/scss/ChatView/ChatView-theme.scss +32 -0
- package/src/assets/styles/scss/Dialog/Dialog-layout.scss +70 -0
- package/src/assets/styles/scss/Dialog/Dialog-theme.scss +103 -0
- package/src/assets/styles/scss/DragAndDropContainer/DragAndDropContainer-layout.scss +5 -0
- package/src/assets/styles/scss/DragAndDropContainer/DragAndDropContainer-theme.scss +47 -0
- package/src/assets/styles/scss/DropzoneContainer/DropzoneContainer-layout.scss +14 -0
- package/src/assets/styles/scss/DropzoneContainer/DropzoneContainer-theme.scss +17 -0
- package/src/assets/styles/scss/EditMessageForm/EditMessageForm-layout.scss +51 -0
- package/src/assets/styles/scss/EditMessageForm/EditMessageForm-theme.scss +50 -0
- package/src/assets/styles/scss/Form/Form-layout.scss +49 -0
- package/src/assets/styles/scss/Form/Form-theme.scss +82 -0
- package/src/assets/styles/scss/Icon/Icon-layout.scss +98 -0
- package/src/assets/styles/scss/Icon/Icon-theme.scss +17 -0
- package/src/assets/styles/scss/ImageCarousel/ImageCarousel-layout.scss +51 -0
- package/src/assets/styles/scss/ImageCarousel/ImageCarousel-theme.scss +30 -0
- package/src/assets/styles/scss/InfiniteScrollPaginator/InfiniteScrollPaginator-layout.scss +4 -0
- package/src/assets/styles/scss/LinkPreview/LinkPreview-layout.scss +67 -0
- package/src/assets/styles/scss/LinkPreview/LinkPreview-theme.scss +32 -0
- package/src/assets/styles/scss/LinkPreview/index.scss +2 -0
- package/src/assets/styles/scss/LoadingIndicator/LoadingIndicator-layout.scss +64 -0
- package/src/assets/styles/scss/LoadingIndicator/LoadingIndicator-theme.scss +14 -0
- package/src/assets/styles/scss/Location/Location-layout.scss +52 -0
- package/src/assets/styles/scss/Location/Location-theme.scss +32 -0
- package/src/assets/styles/scss/Message/Message-layout.scss +605 -0
- package/src/assets/styles/scss/Message/Message-theme.scss +483 -0
- package/src/assets/styles/scss/MessageActionsBox/MessageActionsBox-layout.scss +20 -0
- package/src/assets/styles/scss/MessageActionsBox/MessageActionsBox-theme.scss +85 -0
- package/src/assets/styles/scss/MessageBouncePrompt/MessageBouncePrompt-layout.scss +19 -0
- package/src/assets/styles/scss/MessageBouncePrompt/MessageBouncePrompt-theme.scss +51 -0
- package/src/assets/styles/scss/MessageInput/MessageInput-layout.scss +268 -0
- package/src/assets/styles/scss/MessageInput/MessageInput-theme.scss +359 -0
- package/src/assets/styles/scss/MessageList/MessageList-layout.scss +65 -0
- package/src/assets/styles/scss/MessageList/MessageList-theme.scss +107 -0
- package/src/assets/styles/scss/MessageList/VirtualizedMessageList-layout.scss +57 -0
- package/src/assets/styles/scss/MessageList/VirtualizedMessageList-theme.scss +41 -0
- package/src/assets/styles/scss/MessageReactions/MessageReactions-layout.scss +143 -0
- package/src/assets/styles/scss/MessageReactions/MessageReactions-theme.scss +92 -0
- package/src/assets/styles/scss/MessageReactions/MessageReactionsSelector-layout.scss +86 -0
- package/src/assets/styles/scss/MessageReactions/MessageReactionsSelector-theme.scss +94 -0
- package/src/assets/styles/scss/Modal/Modal-layout.scss +74 -0
- package/src/assets/styles/scss/Modal/Modal-theme.scss +109 -0
- package/src/assets/styles/scss/Notification/MessageNotification-layout.scss +12 -0
- package/src/assets/styles/scss/Notification/MessageNotification-theme.scss +34 -0
- package/src/assets/styles/scss/Notification/Notification-layout.scss +7 -0
- package/src/assets/styles/scss/Notification/Notification-theme.scss +32 -0
- package/src/assets/styles/scss/Notification/NotificationList-layout.scss +11 -0
- package/src/assets/styles/scss/Notification/NotificationList-theme.scss +31 -0
- package/src/assets/styles/scss/Poll/Poll-layout.scss +489 -0
- package/src/assets/styles/scss/Poll/Poll-theme.scss +178 -0
- package/src/assets/styles/scss/Search/Search-layout.scss +148 -0
- package/src/assets/styles/scss/Search/Search-theme.scss +222 -0
- package/src/assets/styles/scss/Thread/Thread-layout.scss +65 -0
- package/src/assets/styles/scss/Thread/Thread-theme.scss +82 -0
- package/src/assets/styles/scss/ThreadList/ThreadList-layout.scss +152 -0
- package/src/assets/styles/scss/ThreadList/ThreadList-theme.scss +75 -0
- package/src/assets/styles/scss/Tooltip/Tooltip-layout.scss +10 -0
- package/src/assets/styles/scss/Tooltip/Tooltip-theme.scss +36 -0
- package/src/assets/styles/scss/TypingIndicator/TypingIndicator-layout.scss +31 -0
- package/src/assets/styles/scss/TypingIndicator/TypingIndicator-theme.scss +68 -0
- package/src/assets/styles/scss/UnreadCountBadge/UnreadCountBadge-layout.scss +49 -0
- package/src/assets/styles/scss/UnreadCountBadge/UnreadCountBadge-theme.scss +11 -0
- package/src/assets/styles/scss/_base.scss +65 -0
- package/src/assets/styles/scss/_emoji-replacement.scss +45 -0
- package/src/assets/styles/scss/_global-layout-variables.scss +65 -0
- package/src/assets/styles/scss/_global-theme-variables.scss +173 -0
- package/src/assets/styles/scss/_icons.scss +36 -0
- package/src/assets/styles/scss/_palette-variables.scss +55 -0
- package/src/assets/styles/scss/_utils.scss +212 -0
- package/src/assets/styles/scss/_variables.scss +2 -0
- package/src/assets/styles/scss/common/CTAButton/CTAButton-layout.scss +4 -0
- package/src/assets/styles/scss/common/CTAButton/CTAButton-theme.scss +42 -0
- package/src/assets/styles/scss/common/CircleFAButton/CircleFAButton-layout.scss +14 -0
- package/src/assets/styles/scss/common/CircleFAButton/CircleFAButton-theme.scss +35 -0
- package/src/assets/styles/scss/index.layout.scss +49 -0
- package/src/assets/styles/scss/index.scss +50 -0
- package/src/assets/styles/scss/vendor/emoji-mart.scss +514 -0
- package/src/assets/styles/scss/vendor/react-image-gallery.scss +258 -0
- package/src/assets/version.ts +1 -0
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
import { AfterViewChecked, AfterViewInit, ChangeDetectorRef, NgZone, OnChanges, OnDestroy, OnInit, SimpleChanges, TemplateRef } from '@angular/core';
|
|
2
|
+
import { ChannelService } from '../channel.service';
|
|
3
|
+
import { Observable, Subject } from 'rxjs';
|
|
4
|
+
import { MessageContext, StreamMessage, TypingIndicatorContext, DateSeparatorContext, UnreadMessagesNotificationContext, UnreadMessagesIndicatorContext } from '../types';
|
|
5
|
+
import { ChatClientService } from '../chat-client.service';
|
|
6
|
+
import { GroupStyle } from './group-styles';
|
|
7
|
+
import { UserResponse } from 'stream-chat';
|
|
8
|
+
import { CustomTemplatesService } from '../custom-templates.service';
|
|
9
|
+
import { DateParserService } from '../date-parser.service';
|
|
10
|
+
import * as i0 from "@angular/core";
|
|
11
|
+
/**
|
|
12
|
+
* The `MessageList` component renders a scrollable list of messages.
|
|
13
|
+
*/
|
|
14
|
+
export declare class MessageListComponent implements AfterViewChecked, OnChanges, OnInit, OnDestroy, AfterViewInit {
|
|
15
|
+
private channelService;
|
|
16
|
+
private chatClientService;
|
|
17
|
+
private customTemplatesService;
|
|
18
|
+
private dateParser;
|
|
19
|
+
private ngZone;
|
|
20
|
+
private cdRef;
|
|
21
|
+
/**
|
|
22
|
+
* Determines if the message list should display channel messages or [thread messages](/chat/docs/javascript/threads/).
|
|
23
|
+
*/
|
|
24
|
+
mode: 'main' | 'thread';
|
|
25
|
+
/**
|
|
26
|
+
* The direction of the messages in the list, `bottom-to-top` means newest message is at the bottom of the message list and users scroll upwards to load older messages
|
|
27
|
+
*/
|
|
28
|
+
direction: 'bottom-to-top' | 'top-to-bottom';
|
|
29
|
+
/**
|
|
30
|
+
* You can hide the "jump to latest" button while scrolling. A potential use-case for this input would be to [workaround a known issue on iOS Safar webview](https://github.com/GetStream/stream-chat-angular/issues/418)
|
|
31
|
+
*
|
|
32
|
+
*/
|
|
33
|
+
hideJumpToLatestButtonDuringScroll: boolean;
|
|
34
|
+
/**
|
|
35
|
+
* If `true` date separators will be displayed
|
|
36
|
+
*/
|
|
37
|
+
displayDateSeparator: boolean;
|
|
38
|
+
/**
|
|
39
|
+
* If `true` unread indicator will be displayed
|
|
40
|
+
*/
|
|
41
|
+
displayUnreadSeparator: boolean;
|
|
42
|
+
/**
|
|
43
|
+
* If date separators are displayed, you can set the horizontal position of the date text.
|
|
44
|
+
*/
|
|
45
|
+
dateSeparatorTextPos: 'center' | 'right' | 'left';
|
|
46
|
+
/**
|
|
47
|
+
* `last-message` option will open the message list at the last message, `last-read-message` will open the list at the last unread message. This option only works if mode is `main`.
|
|
48
|
+
*/
|
|
49
|
+
openMessageListAt: 'last-message' | 'last-read-message';
|
|
50
|
+
/**
|
|
51
|
+
* If the user has unread messages when they open the channel the UI shows the unread indicator / notification which features the unread count by default. This count will be increased every time a user receives a new message. If you don't want to show the unread count, you can turn that off.
|
|
52
|
+
*
|
|
53
|
+
* This is only applicable for `main` mode, as threads doesn't have read infromation.
|
|
54
|
+
*/
|
|
55
|
+
hideUnreadCountForNotificationAndIndicator: boolean;
|
|
56
|
+
/**
|
|
57
|
+
* You can turn on and off the loading indicator that signals to users that more messages are being loaded to the message list
|
|
58
|
+
*/
|
|
59
|
+
displayLoadingIndicator: boolean;
|
|
60
|
+
typingIndicatorTemplate: TemplateRef<TypingIndicatorContext> | undefined;
|
|
61
|
+
messageTemplate: TemplateRef<MessageContext> | undefined;
|
|
62
|
+
customDateSeparatorTemplate: TemplateRef<DateSeparatorContext> | undefined;
|
|
63
|
+
customnewMessagesIndicatorTemplate: TemplateRef<UnreadMessagesIndicatorContext> | undefined;
|
|
64
|
+
customnewMessagesNotificationTemplate: TemplateRef<UnreadMessagesNotificationContext> | undefined;
|
|
65
|
+
emptyMainMessageListTemplate: TemplateRef<void> | null;
|
|
66
|
+
emptyThreadMessageListTemplate: TemplateRef<void> | null;
|
|
67
|
+
messages$: Observable<StreamMessage[]>;
|
|
68
|
+
enabledMessageActions: string[];
|
|
69
|
+
isEmpty: boolean;
|
|
70
|
+
newMessageCountWhileBeingScrolled: number;
|
|
71
|
+
isUserScrolled: boolean | undefined;
|
|
72
|
+
groupStyles: GroupStyle[];
|
|
73
|
+
isNextMessageOnSeparateDate: boolean[];
|
|
74
|
+
lastSentMessageId: string | undefined;
|
|
75
|
+
parentMessage: StreamMessage | undefined;
|
|
76
|
+
highlightedMessageId: string | undefined;
|
|
77
|
+
loadingState: 'idle' | 'loading-top' | 'loading-bottom';
|
|
78
|
+
scrollEndTimeout?: ReturnType<typeof setTimeout>;
|
|
79
|
+
lastReadMessageId?: string;
|
|
80
|
+
isUnreadNotificationVisible: boolean;
|
|
81
|
+
firstUnreadMessageId?: string;
|
|
82
|
+
unreadCount?: number;
|
|
83
|
+
isJumpingToLatestUnreadMessage: boolean;
|
|
84
|
+
isJumpToLatestButtonVisible: boolean;
|
|
85
|
+
isJumpingToMessage: boolean;
|
|
86
|
+
scroll$: Subject<void>;
|
|
87
|
+
private scrollContainer;
|
|
88
|
+
private parentMessageElement;
|
|
89
|
+
private isNewMessageSentByUser;
|
|
90
|
+
private subscriptions;
|
|
91
|
+
private newMessageSubscription;
|
|
92
|
+
private usersTypingInChannel$;
|
|
93
|
+
private usersTypingInThread$;
|
|
94
|
+
private isLatestMessageInList;
|
|
95
|
+
private channelId?;
|
|
96
|
+
private parsedDates;
|
|
97
|
+
private isViewInited;
|
|
98
|
+
private checkIfUnreadNotificationIsVisibleTimeout?;
|
|
99
|
+
private jumpToMessageTimeouts;
|
|
100
|
+
private jumpToLatestButtonVisibilityTimeout?;
|
|
101
|
+
private forceRepaintSubject;
|
|
102
|
+
private messageIdToAnchorTo?;
|
|
103
|
+
private anchorMessageTopOffset?;
|
|
104
|
+
private isSafari;
|
|
105
|
+
private get class();
|
|
106
|
+
private virtualizedList?;
|
|
107
|
+
private scrollPosition$;
|
|
108
|
+
private jumpToItemSubscription?;
|
|
109
|
+
private queryStateSubscription?;
|
|
110
|
+
constructor(channelService: ChannelService, chatClientService: ChatClientService, customTemplatesService: CustomTemplatesService, dateParser: DateParserService, ngZone: NgZone, cdRef: ChangeDetectorRef);
|
|
111
|
+
messageNotificationJumpClicked: () => void;
|
|
112
|
+
messageNotificationDismissClicked: () => void;
|
|
113
|
+
ngOnInit(): void;
|
|
114
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
115
|
+
ngAfterViewInit(): void;
|
|
116
|
+
ngAfterViewChecked(): void;
|
|
117
|
+
ngOnDestroy(): void;
|
|
118
|
+
trackByMessageId(_: number, item: StreamMessage): string;
|
|
119
|
+
trackByUserId(_: number, user: UserResponse): string;
|
|
120
|
+
jumpToLatestMessage(): void;
|
|
121
|
+
scrollToBottom(): void;
|
|
122
|
+
scrollToTop(): void;
|
|
123
|
+
scrolled(): void;
|
|
124
|
+
jumpToFirstUnreadMessage(): void;
|
|
125
|
+
getTypingIndicatorContext(): TypingIndicatorContext;
|
|
126
|
+
getTypingIndicatorText(users: UserResponse[]): string;
|
|
127
|
+
isSentByCurrentUser(message?: StreamMessage): boolean;
|
|
128
|
+
parseDate(date: Date): string | undefined;
|
|
129
|
+
get replyCountParam(): {
|
|
130
|
+
replyCount: number | undefined;
|
|
131
|
+
};
|
|
132
|
+
get emptyListTemplate(): TemplateRef<void> | null;
|
|
133
|
+
private checkIfUserScrolled;
|
|
134
|
+
private preserveScrollbarPosition;
|
|
135
|
+
private forceRepaint;
|
|
136
|
+
private getScrollPosition;
|
|
137
|
+
private setMessages$;
|
|
138
|
+
private resetScrollState;
|
|
139
|
+
private disposeVirtualizedList;
|
|
140
|
+
private get usersTyping$();
|
|
141
|
+
private scrollMessageIntoView;
|
|
142
|
+
private newMessageReceived;
|
|
143
|
+
private checkIfOnSeparateDates;
|
|
144
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<MessageListComponent, never>;
|
|
145
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<MessageListComponent, "stream-message-list", never, { "mode": { "alias": "mode"; "required": false; }; "direction": { "alias": "direction"; "required": false; }; "hideJumpToLatestButtonDuringScroll": { "alias": "hideJumpToLatestButtonDuringScroll"; "required": false; }; "displayDateSeparator": { "alias": "displayDateSeparator"; "required": false; }; "displayUnreadSeparator": { "alias": "displayUnreadSeparator"; "required": false; }; "dateSeparatorTextPos": { "alias": "dateSeparatorTextPos"; "required": false; }; "openMessageListAt": { "alias": "openMessageListAt"; "required": false; }; "hideUnreadCountForNotificationAndIndicator": { "alias": "hideUnreadCountForNotificationAndIndicator"; "required": false; }; "displayLoadingIndicator": { "alias": "displayLoadingIndicator"; "required": false; }; }, {}, never, never, false, never>;
|
|
146
|
+
}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import { Attachment, CustomMessageData, MessageResponse, UserResponse } from 'stream-chat';
|
|
2
|
+
export declare const createMessagePreview: (user: UserResponse, text: string, attachments: Attachment[] | undefined, mentionedUsers: UserResponse[] | undefined, parentId: undefined | string, quotedMessageId: undefined | string, customData: undefined | CustomMessageData, pollId?: undefined | string) => MessageResponse;
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import { AfterViewInit, ChangeDetectorRef, OnChanges, OnDestroy, OnInit, SimpleChanges } from '@angular/core';
|
|
2
|
+
import { ReactionGroupResponse, ReactionResponse, UserResponse } from 'stream-chat';
|
|
3
|
+
import { MessageReactionType } from '../types';
|
|
4
|
+
import { MessageReactionsService } from '../message-reactions.service';
|
|
5
|
+
import { CustomTemplatesService } from '../custom-templates.service';
|
|
6
|
+
import * as i0 from "@angular/core";
|
|
7
|
+
/**
|
|
8
|
+
* The `MessageReactions` component displays the reactions of a message. You can read more about [message reactions](/chat/docs/javascript/send_reaction/) in the platform documentation.
|
|
9
|
+
*/
|
|
10
|
+
export declare class MessageReactionsComponent implements OnChanges, OnInit, AfterViewInit, OnDestroy {
|
|
11
|
+
private cdRef;
|
|
12
|
+
private messageReactionsService;
|
|
13
|
+
customTemplatesService: CustomTemplatesService;
|
|
14
|
+
/**
|
|
15
|
+
* The id of the message the reactions belong to
|
|
16
|
+
*/
|
|
17
|
+
messageId: string | undefined;
|
|
18
|
+
/**
|
|
19
|
+
* The number of reactions grouped by [reaction types](https://github.com/GetStream/stream-chat-angular/tree/master/projects/stream-chat-angular/src/lib/message-reactions/message-reactions.component.ts)
|
|
20
|
+
*/
|
|
21
|
+
messageReactionGroups: {
|
|
22
|
+
[key: string]: ReactionGroupResponse;
|
|
23
|
+
} | undefined;
|
|
24
|
+
/**
|
|
25
|
+
* The number of reactions grouped by [reaction types](https://github.com/GetStream/stream-chat-angular/tree/master/projects/stream-chat-angular/src/lib/message-reactions/message-reactions.component.ts)
|
|
26
|
+
* @deprecated use `messageReactionGroups`
|
|
27
|
+
*/
|
|
28
|
+
messageReactionCounts: {
|
|
29
|
+
[key in MessageReactionType]?: number;
|
|
30
|
+
};
|
|
31
|
+
/**
|
|
32
|
+
* List of reactions of a [message](/chat/docs/sdk/angular/types/stream-message/), used to display the users of a reaction type.
|
|
33
|
+
* @deprecated you can fetch the reactions using [`messageReactionsService.queryReactions()`](/chat/docs/sdk/angular/services/MessageReactionsService/#queryreactions)
|
|
34
|
+
*/
|
|
35
|
+
latestReactions: ReactionResponse[];
|
|
36
|
+
/**
|
|
37
|
+
* List of the user's own reactions of a [message](/chat/docs/sdk/angular/types/stream-message/), used to display the users of a reaction type.
|
|
38
|
+
*/
|
|
39
|
+
ownReactions: ReactionResponse[];
|
|
40
|
+
private selectorContainer;
|
|
41
|
+
selectedReactionType: string | undefined;
|
|
42
|
+
isLoading: boolean;
|
|
43
|
+
reactions: ReactionResponse[];
|
|
44
|
+
shouldHandleReactionClick: boolean;
|
|
45
|
+
existingReactions: string[];
|
|
46
|
+
reactionOptions: string[];
|
|
47
|
+
usersByReactions: {
|
|
48
|
+
[key: string]: {
|
|
49
|
+
users: UserResponse[];
|
|
50
|
+
next?: string;
|
|
51
|
+
};
|
|
52
|
+
};
|
|
53
|
+
private subscriptions;
|
|
54
|
+
private isViewInited;
|
|
55
|
+
constructor(cdRef: ChangeDetectorRef, messageReactionsService: MessageReactionsService, customTemplatesService: CustomTemplatesService);
|
|
56
|
+
ngOnInit(): void;
|
|
57
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
58
|
+
ngAfterViewInit(): void;
|
|
59
|
+
ngOnDestroy(): void;
|
|
60
|
+
getEmojiByReaction(reactionType: MessageReactionType): string;
|
|
61
|
+
reactionSelected(reactionType: string): Promise<void>;
|
|
62
|
+
loadNextPageOfReactions(): Promise<void>;
|
|
63
|
+
trackByMessageReaction(_: number, item: MessageReactionType): string;
|
|
64
|
+
isOwnReaction(reactionType: MessageReactionType): boolean;
|
|
65
|
+
isOpenChange: (isOpen: boolean) => void;
|
|
66
|
+
private setExistingReactions;
|
|
67
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<MessageReactionsComponent, never>;
|
|
68
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<MessageReactionsComponent, "stream-message-reactions", never, { "messageId": { "alias": "messageId"; "required": false; }; "messageReactionGroups": { "alias": "messageReactionGroups"; "required": false; }; "messageReactionCounts": { "alias": "messageReactionCounts"; "required": false; }; "latestReactions": { "alias": "latestReactions"; "required": false; }; "ownReactions": { "alias": "ownReactions"; "required": false; }; }, {}, never, never, false, never>;
|
|
69
|
+
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { AfterViewInit, ChangeDetectorRef, OnDestroy, OnInit } from '@angular/core';
|
|
2
|
+
import { MessageReactionType } from '../types';
|
|
3
|
+
import { ReactionResponse } from 'stream-chat';
|
|
4
|
+
import { ChannelService } from '../channel.service';
|
|
5
|
+
import { MessageReactionsService } from '../message-reactions.service';
|
|
6
|
+
import * as i0 from "@angular/core";
|
|
7
|
+
/**
|
|
8
|
+
* The `MessageReactionsSelectorComponent` makes it possible for users to react to a message, the reaction options can be set using the [`MessageReactionsService`](/chat/docs/sdk/angular/services/MessageReactionsService/). You can read more about [message reactions](/chat/docs/javascript/send_reaction/) in the platform documentation.
|
|
9
|
+
*/
|
|
10
|
+
export declare class MessageReactionsSelectorComponent implements OnInit, OnDestroy, AfterViewInit {
|
|
11
|
+
private channelService;
|
|
12
|
+
private messageReactionsService;
|
|
13
|
+
private cdRef;
|
|
14
|
+
/**
|
|
15
|
+
* List of the user's own reactions of a [message](/chat/docs/sdk/angular/types/stream-message/), used to display the users of a reaction type.
|
|
16
|
+
*/
|
|
17
|
+
ownReactions: ReactionResponse[];
|
|
18
|
+
/**
|
|
19
|
+
* The id of the message the reactions belong to
|
|
20
|
+
*/
|
|
21
|
+
messageId: string | undefined;
|
|
22
|
+
reactionOptions: string[];
|
|
23
|
+
private subscriptions;
|
|
24
|
+
private isViewInited;
|
|
25
|
+
constructor(channelService: ChannelService, messageReactionsService: MessageReactionsService, cdRef: ChangeDetectorRef);
|
|
26
|
+
ngOnInit(): void;
|
|
27
|
+
ngAfterViewInit(): void;
|
|
28
|
+
ngOnDestroy(): void;
|
|
29
|
+
trackByMessageReaction(_: number, item: MessageReactionType): string;
|
|
30
|
+
isOwnReaction(reactionType: MessageReactionType): boolean;
|
|
31
|
+
getEmojiByReaction(reactionType: MessageReactionType): string;
|
|
32
|
+
react(type: MessageReactionType): Promise<void>;
|
|
33
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<MessageReactionsSelectorComponent, never>;
|
|
34
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<MessageReactionsSelectorComponent, "stream-message-reactions-selector", never, { "ownReactions": { "alias": "ownReactions"; "required": false; }; "messageId": { "alias": "messageId"; "required": false; }; }, {}, never, never, false, never>;
|
|
35
|
+
}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import { MessageReactionClickDetails, MessageReactionType } from './types';
|
|
2
|
+
import { BehaviorSubject } from 'rxjs';
|
|
3
|
+
import { ChatClientService } from './chat-client.service';
|
|
4
|
+
import { NotificationService } from './notification.service';
|
|
5
|
+
import * as i0 from "@angular/core";
|
|
6
|
+
/**
|
|
7
|
+
* The `MessageReactionsService` provides customization options to message [reactions](/chat/docs/javascript/send_reaction/).
|
|
8
|
+
*
|
|
9
|
+
*/
|
|
10
|
+
export declare class MessageReactionsService {
|
|
11
|
+
private chatClientService;
|
|
12
|
+
private notificationService;
|
|
13
|
+
/**
|
|
14
|
+
* The enabled [reactions](/chat/docs/javascript/send_reaction/) and the associated emoji
|
|
15
|
+
*
|
|
16
|
+
* You can provide any string as a reaction. The emoji can be provided as a string, if you want to use custom images for reactions you have to provide a [custom reactions UI](/chat/docs/sdk/angular/services/CustomTemplatesService/#messagereactionstemplate/)
|
|
17
|
+
*/
|
|
18
|
+
reactions$: BehaviorSubject<{
|
|
19
|
+
[x: string]: string;
|
|
20
|
+
}>;
|
|
21
|
+
/**
|
|
22
|
+
* By default the [`MessageReactionsComponent`](/chat/docs/sdk/angular/components/MessageReactionsComponent/) will display the reacting users when a reaction is clicked. You can override this with your own UI by providing a custom event handler.
|
|
23
|
+
*
|
|
24
|
+
* The event handler can retrieve all reactions of a message using the [`messageReactionsService.queryReactions()`](/chat/docs/sdk/angular/services/MessageReactionsService/#queryreactions)
|
|
25
|
+
*/
|
|
26
|
+
customReactionClickHandler?: (details: MessageReactionClickDetails) => void;
|
|
27
|
+
constructor(chatClientService: ChatClientService, notificationService: NotificationService);
|
|
28
|
+
/**
|
|
29
|
+
* Sets the enabled reactions
|
|
30
|
+
*/
|
|
31
|
+
set reactions(reactions: {
|
|
32
|
+
[key in MessageReactionType]: string;
|
|
33
|
+
});
|
|
34
|
+
/**
|
|
35
|
+
* Get the currently enabled reactions
|
|
36
|
+
*/
|
|
37
|
+
get reactions(): {
|
|
38
|
+
[key in MessageReactionType]: string;
|
|
39
|
+
};
|
|
40
|
+
/**
|
|
41
|
+
* Query reactions of a specific message, more info in the [API documentation](/chat/docs/javascript/send_reaction/#query-reactions)
|
|
42
|
+
* @param messageId
|
|
43
|
+
* @param type
|
|
44
|
+
* @param next
|
|
45
|
+
* @returns the reactions and the cursor for the next/prev pages
|
|
46
|
+
*/
|
|
47
|
+
queryReactions(messageId: string, type: string, next?: string): Promise<import("stream-chat").QueryReactionsAPIResponse>;
|
|
48
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<MessageReactionsService, never>;
|
|
49
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<MessageReactionsService>;
|
|
50
|
+
}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { OnChanges, SimpleChanges } from '@angular/core';
|
|
2
|
+
import { MentionTemplateContext, StreamMessage } from '../types';
|
|
3
|
+
import { UserResponse } from 'stream-chat';
|
|
4
|
+
import { MessageService } from '../message.service';
|
|
5
|
+
import { CustomTemplatesService } from '../custom-templates.service';
|
|
6
|
+
import * as i0 from "@angular/core";
|
|
7
|
+
type MessagePart = {
|
|
8
|
+
content: string;
|
|
9
|
+
type: 'text' | 'mention';
|
|
10
|
+
user?: UserResponse;
|
|
11
|
+
};
|
|
12
|
+
/**
|
|
13
|
+
* The `MessageTextComponent` displays the text content of a message.
|
|
14
|
+
*/
|
|
15
|
+
export declare class MessageTextComponent implements OnChanges {
|
|
16
|
+
private messageService;
|
|
17
|
+
readonly customTemplatesService: CustomTemplatesService;
|
|
18
|
+
/**
|
|
19
|
+
* The message which text should be displayed
|
|
20
|
+
*/
|
|
21
|
+
message: StreamMessage | undefined | StreamMessage['quoted_message'];
|
|
22
|
+
/**
|
|
23
|
+
* `true` if the component displayes a message quote
|
|
24
|
+
*/
|
|
25
|
+
isQuoted: boolean;
|
|
26
|
+
/**
|
|
27
|
+
* `true` if the
|
|
28
|
+
*/
|
|
29
|
+
shouldTranslate: boolean;
|
|
30
|
+
messageTextParts: MessagePart[] | undefined;
|
|
31
|
+
messageText?: string;
|
|
32
|
+
displayAs: 'text' | 'html';
|
|
33
|
+
private readonly urlRegexp;
|
|
34
|
+
private emojiRegexp;
|
|
35
|
+
constructor(messageService: MessageService, customTemplatesService: CustomTemplatesService);
|
|
36
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
37
|
+
getMentionContext(messagePart: MessagePart): MentionTemplateContext;
|
|
38
|
+
private createMessageParts;
|
|
39
|
+
private getMessageContent;
|
|
40
|
+
private fixEmojiDisplay;
|
|
41
|
+
private wrapLinksWithAnchorTag;
|
|
42
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<MessageTextComponent, never>;
|
|
43
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<MessageTextComponent, "stream-message-text", never, { "message": { "alias": "message"; "required": false; }; "isQuoted": { "alias": "isQuoted"; "required": false; }; "shouldTranslate": { "alias": "shouldTranslate"; "required": false; }; }, {}, never, never, false, never>;
|
|
44
|
+
}
|
|
45
|
+
export {};
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { Attachment } from 'stream-chat';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
/**
|
|
4
|
+
* The message service contains configuration options related to displaying the message content
|
|
5
|
+
*/
|
|
6
|
+
export declare class MessageService {
|
|
7
|
+
/**
|
|
8
|
+
* Decides if the message content should be formatted as text or HTML
|
|
9
|
+
*
|
|
10
|
+
* If you display messages as text the following parts are still be displayed as HTML:
|
|
11
|
+
* - user mentions -> you can customize this with your own template using the [`customTemplatesService.mentionTemplate$`](/chat/docs/sdk/angular/services/CustomTemplatesService/#mentiontemplate)
|
|
12
|
+
* - links -> you can customize this by providing you own [`customLinkRenderer`](#customlinkrenderer) method
|
|
13
|
+
*/
|
|
14
|
+
displayAs: 'text' | 'html';
|
|
15
|
+
/**
|
|
16
|
+
* You can provide a custom method to display links
|
|
17
|
+
* @param url the url the link should refer to
|
|
18
|
+
* @returns the HTML markup as a string for the link
|
|
19
|
+
*/
|
|
20
|
+
customLinkRenderer?: (url: string) => string;
|
|
21
|
+
/**
|
|
22
|
+
* The SDK supports the following attachment types: `image`, `file`, `giphy`, `video` and `voiceRecording` attachments.
|
|
23
|
+
*
|
|
24
|
+
* All other types are treated as custom attachments, however it's possible to override this logic, and provide a custom filtering method which can be used to treat some built-in attachments as custom.
|
|
25
|
+
*
|
|
26
|
+
* Provide a method which retruns `true` if an attachment should be considered as custom.
|
|
27
|
+
*/
|
|
28
|
+
filterCustomAttachment?: (attachment: Attachment) => boolean;
|
|
29
|
+
constructor();
|
|
30
|
+
/**
|
|
31
|
+
* Tells if an attachment is custom (you need to provide your own template to display them) or built-in (the SDK supports it out-of-the-box)
|
|
32
|
+
* @param attachment
|
|
33
|
+
* @returns `true` if the attachment is custom
|
|
34
|
+
*/
|
|
35
|
+
isCustomAttachment(attachment: Attachment): boolean;
|
|
36
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<MessageService, never>;
|
|
37
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<MessageService>;
|
|
38
|
+
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { EventEmitter, OnChanges, SimpleChanges, TemplateRef } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
/**
|
|
4
|
+
* The `Modal` component displays its content in an overlay. The modal can be closed with a close button, if the user clicks outside of the modal content, or if the escape button is pressed. The modal can also be closed from outside.
|
|
5
|
+
*/
|
|
6
|
+
export declare class ModalComponent implements OnChanges {
|
|
7
|
+
/**
|
|
8
|
+
* If `true` the modal will be displayed, if `false` the modal will be hidden
|
|
9
|
+
*/
|
|
10
|
+
isOpen: boolean;
|
|
11
|
+
/**
|
|
12
|
+
* The content of the modal (can also be provided using `ng-content`)
|
|
13
|
+
*/
|
|
14
|
+
content: TemplateRef<void> | undefined;
|
|
15
|
+
/**
|
|
16
|
+
* Emits `true` if the modal becomes visible, and `false` if the modal is closed.
|
|
17
|
+
*/
|
|
18
|
+
readonly isOpenChange: EventEmitter<boolean>;
|
|
19
|
+
private innerContainer;
|
|
20
|
+
constructor();
|
|
21
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
22
|
+
close(): void;
|
|
23
|
+
private watchForEscPress;
|
|
24
|
+
private stopWatchForEscPress;
|
|
25
|
+
private watchForOutsideClicks;
|
|
26
|
+
private stopWatchForOutsideClicks;
|
|
27
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ModalComponent, never>;
|
|
28
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ModalComponent, "stream-modal", never, { "isOpen": { "alias": "isOpen"; "required": false; }; "content": { "alias": "content"; "required": false; }; }, { "isOpenChange": "isOpenChange"; }, never, ["*"], false, never>;
|
|
29
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
import * as i1 from "./modal.component";
|
|
3
|
+
import * as i2 from "@angular/common";
|
|
4
|
+
import * as i3 from "../icon/icon.module";
|
|
5
|
+
export declare class StreamModalModule {
|
|
6
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<StreamModalModule, never>;
|
|
7
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<StreamModalModule, [typeof i1.ModalComponent], [typeof i2.CommonModule, typeof i3.IconModule], [typeof i1.ModalComponent]>;
|
|
8
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<StreamModalModule>;
|
|
9
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { TemplateRef } from '@angular/core';
|
|
2
|
+
import { NotificationType } from '../types';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
/**
|
|
5
|
+
* The `Notification` component displays a notification within the [`NotificationList`](/chat/docs/sdk/angular/components/NotificationListComponent/)
|
|
6
|
+
*/
|
|
7
|
+
export declare class NotificationComponent {
|
|
8
|
+
/**
|
|
9
|
+
* The type of the notification
|
|
10
|
+
*/
|
|
11
|
+
type: NotificationType | undefined;
|
|
12
|
+
/**
|
|
13
|
+
* The content of the notification (can also be provided using `ng-content`)
|
|
14
|
+
*/
|
|
15
|
+
content: TemplateRef<void> | undefined;
|
|
16
|
+
constructor();
|
|
17
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NotificationComponent, never>;
|
|
18
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<NotificationComponent, "stream-notification", never, { "type": { "alias": "type"; "required": false; }; "content": { "alias": "content"; "required": false; }; }, {}, never, ["*"], false, never>;
|
|
19
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { Observable } from 'rxjs';
|
|
2
|
+
import { CustomTemplatesService } from '../custom-templates.service';
|
|
3
|
+
import { NotificationService } from '../notification.service';
|
|
4
|
+
import { ThemeService } from '../theme.service';
|
|
5
|
+
import { NotificationPayload } from '../types';
|
|
6
|
+
import * as i0 from "@angular/core";
|
|
7
|
+
/**
|
|
8
|
+
* The `NotificationList` component displays the list of active notifications.
|
|
9
|
+
*/
|
|
10
|
+
export declare class NotificationListComponent {
|
|
11
|
+
readonly customTemplatesService: CustomTemplatesService;
|
|
12
|
+
private notificationService;
|
|
13
|
+
private themeService;
|
|
14
|
+
notifications$: Observable<NotificationPayload[]>;
|
|
15
|
+
theme$: Observable<string>;
|
|
16
|
+
constructor(customTemplatesService: CustomTemplatesService, notificationService: NotificationService, themeService: ThemeService);
|
|
17
|
+
trackById(_: number, item: NotificationPayload): string;
|
|
18
|
+
getNotificationContentContext(notification: NotificationPayload): {
|
|
19
|
+
dismissFn: () => void;
|
|
20
|
+
};
|
|
21
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NotificationListComponent, never>;
|
|
22
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<NotificationListComponent, "stream-notification-list", never, {}, {}, never, never, false, never>;
|
|
23
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
import * as i1 from "../notification/notification.component";
|
|
3
|
+
import * as i2 from "./notification-list.component";
|
|
4
|
+
import * as i3 from "@angular/common";
|
|
5
|
+
import * as i4 from "@ngx-translate/core";
|
|
6
|
+
export declare class StreamNotificationModule {
|
|
7
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<StreamNotificationModule, never>;
|
|
8
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<StreamNotificationModule, [typeof i1.NotificationComponent, typeof i2.NotificationListComponent], [typeof i3.CommonModule, typeof i4.TranslatePipe], [typeof i1.NotificationComponent, typeof i2.NotificationListComponent]>;
|
|
9
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<StreamNotificationModule>;
|
|
10
|
+
}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { TemplateRef } from '@angular/core';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import { NotificationPayload, NotificationType } from './types';
|
|
4
|
+
import * as i0 from "@angular/core";
|
|
5
|
+
/**
|
|
6
|
+
* The `NotificationService` can be used to add or remove notifications. By default the [`NotificationList`](/chat/docs/sdk/angular/components/NotificationListComponent/) component displays the currently active notifications.
|
|
7
|
+
*/
|
|
8
|
+
export declare class NotificationService {
|
|
9
|
+
/**
|
|
10
|
+
* Emits the currently active [notifications](https://github.com/GetStream/stream-chat-angular/blob/master/projects/stream-chat-angular/src/lib/notification.service.ts).
|
|
11
|
+
*/
|
|
12
|
+
notifications$: Observable<NotificationPayload[]>;
|
|
13
|
+
private notificationsSubject;
|
|
14
|
+
constructor();
|
|
15
|
+
/**
|
|
16
|
+
* Displays a notification for the given amount of time.
|
|
17
|
+
* @param content The text of the notification or the HTML template for the notification
|
|
18
|
+
* @param type The type of the notification
|
|
19
|
+
* @param timeout The number of milliseconds while the notification should be visible
|
|
20
|
+
* @param translateParams Translation parameters for the `content` (for text notifications)
|
|
21
|
+
* @param templateContext The input of the notification template (for HTML notifications)
|
|
22
|
+
* @returns A method to clear the notification (before the timeout).
|
|
23
|
+
*/
|
|
24
|
+
addTemporaryNotification<T>(content: string | TemplateRef<T>, type?: NotificationType, timeout?: number, translateParams?: object, templateContext?: T): () => void;
|
|
25
|
+
/**
|
|
26
|
+
* Displays a notification, that will be visible until it's removed.
|
|
27
|
+
* @param content The text of the notification or the HTML template for the notification
|
|
28
|
+
* @param type The type of the notification
|
|
29
|
+
* @param translateParams Translation parameters for the `content` (for text notifications)
|
|
30
|
+
* @param templateContext The input of the notification template (for HTML notifications)
|
|
31
|
+
* @returns A method to clear the notification.
|
|
32
|
+
*/
|
|
33
|
+
addPermanentNotification<T = object>(content: string | TemplateRef<T>, type?: NotificationType, translateParams?: object, templateContext?: T): () => void;
|
|
34
|
+
private createNotification;
|
|
35
|
+
private removeNotification;
|
|
36
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<NotificationService, never>;
|
|
37
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<NotificationService>;
|
|
38
|
+
}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { AfterViewInit, ChangeDetectorRef, EventEmitter, NgZone, TemplateRef, TrackByFunction } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
/**
|
|
4
|
+
* The `PaginatedListComponent` is a utility element that can display a list of any items. It uses infinite scrolls to load more elements. Providing the data to display, is the responsibility of the parent component.
|
|
5
|
+
*/
|
|
6
|
+
export declare class PaginatedListComponent<T> implements AfterViewInit {
|
|
7
|
+
private ngZone;
|
|
8
|
+
private cdRef;
|
|
9
|
+
/**
|
|
10
|
+
* The items to display
|
|
11
|
+
*/
|
|
12
|
+
items: T[];
|
|
13
|
+
/**
|
|
14
|
+
* If `true`, the loading indicator will be displayed
|
|
15
|
+
*/
|
|
16
|
+
isLoading: boolean;
|
|
17
|
+
/**
|
|
18
|
+
* If `false` the component won't ask for more data vua the `loadMore` output
|
|
19
|
+
*/
|
|
20
|
+
hasMore: boolean;
|
|
21
|
+
/**
|
|
22
|
+
* The `trackBy` to use with the `NgFor` directive
|
|
23
|
+
* @param i
|
|
24
|
+
* @returns the track by id
|
|
25
|
+
*/
|
|
26
|
+
trackBy: TrackByFunction<T>;
|
|
27
|
+
itemTempalteRef: TemplateRef<{
|
|
28
|
+
item: T;
|
|
29
|
+
index: number;
|
|
30
|
+
}> | undefined;
|
|
31
|
+
/**
|
|
32
|
+
* The component will signal via this output when more items should be fetched
|
|
33
|
+
*
|
|
34
|
+
* The new items should be appended to the `items` array
|
|
35
|
+
*/
|
|
36
|
+
readonly loadMore: EventEmitter<void>;
|
|
37
|
+
isScrollable: boolean;
|
|
38
|
+
isAtBottom: boolean;
|
|
39
|
+
private scrollContainer;
|
|
40
|
+
constructor(ngZone: NgZone, cdRef: ChangeDetectorRef);
|
|
41
|
+
ngAfterViewInit(): void;
|
|
42
|
+
private scrolled;
|
|
43
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<PaginatedListComponent<any>, never>;
|
|
44
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<PaginatedListComponent<any>, "stream-paginated-list", never, { "items": { "alias": "items"; "required": false; }; "isLoading": { "alias": "isLoading"; "required": false; }; "hasMore": { "alias": "hasMore"; "required": false; }; "trackBy": { "alias": "trackBy"; "required": false; }; }, { "loadMore": "loadMore"; }, ["itemTempalteRef"], never, false, never>;
|
|
45
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as i0 from "@angular/core";
|
|
2
|
+
import * as i1 from "./paginated-list.component";
|
|
3
|
+
import * as i2 from "@angular/common";
|
|
4
|
+
import * as i3 from "@ngx-translate/core";
|
|
5
|
+
import * as i4 from "../icon/icon.module";
|
|
6
|
+
export declare class StreamPaginatedListModule {
|
|
7
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<StreamPaginatedListModule, never>;
|
|
8
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<StreamPaginatedListModule, [typeof i1.PaginatedListComponent], [typeof i2.CommonModule, typeof i3.TranslatePipe, typeof i4.IconModule], [typeof i1.PaginatedListComponent]>;
|
|
9
|
+
static ɵinj: i0.ɵɵInjectorDeclaration<StreamPaginatedListModule>;
|
|
10
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const parseDate: (date: Date, format?: 'date' | 'date-time' | 'time') => string;
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { AfterViewInit, ChangeDetectorRef, OnChanges, OnDestroy, SimpleChanges } from '@angular/core';
|
|
2
|
+
import { ChatClientService } from '../chat-client.service';
|
|
3
|
+
import { Poll, User } from 'stream-chat';
|
|
4
|
+
import { ChannelService } from '../channel.service';
|
|
5
|
+
import { CustomTemplatesService } from '../custom-templates.service';
|
|
6
|
+
import { NotificationService } from '../notification.service';
|
|
7
|
+
import * as i0 from "@angular/core";
|
|
8
|
+
/**
|
|
9
|
+
* @internal
|
|
10
|
+
*/
|
|
11
|
+
export declare abstract class BasePollComponent implements OnChanges, AfterViewInit, OnDestroy {
|
|
12
|
+
customTemplatesService: CustomTemplatesService;
|
|
13
|
+
private chatClientService;
|
|
14
|
+
private cdRef;
|
|
15
|
+
private channelService;
|
|
16
|
+
protected notificationService: NotificationService;
|
|
17
|
+
/**
|
|
18
|
+
* The poll id to display
|
|
19
|
+
*/
|
|
20
|
+
pollId: string | undefined;
|
|
21
|
+
/**
|
|
22
|
+
* The message id the poll is attached to
|
|
23
|
+
*/
|
|
24
|
+
messageId: string | undefined;
|
|
25
|
+
canVote: boolean;
|
|
26
|
+
canQueryVotes: boolean;
|
|
27
|
+
private pollStateUnsubscribe?;
|
|
28
|
+
private isViewInited;
|
|
29
|
+
private capabilitySubscription?;
|
|
30
|
+
protected dismissNotificationFn: (() => void) | undefined;
|
|
31
|
+
constructor(customTemplatesService: CustomTemplatesService, chatClientService: ChatClientService, cdRef: ChangeDetectorRef, channelService: ChannelService, notificationService: NotificationService);
|
|
32
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
33
|
+
ngAfterViewInit(): void;
|
|
34
|
+
ngOnDestroy(): void;
|
|
35
|
+
protected get poll(): Poll | undefined;
|
|
36
|
+
protected setupStateStoreSelector(): void;
|
|
37
|
+
protected addNotification(...args: Parameters<typeof this.notificationService.addTemporaryNotification>): void;
|
|
38
|
+
protected abstract stateStoreSelector(poll: Poll, markForCheck: () => void): () => void;
|
|
39
|
+
protected get currentUser(): User | undefined;
|
|
40
|
+
protected markForCheck(): void;
|
|
41
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<BasePollComponent, never>;
|
|
42
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<BasePollComponent, "stream-base-poll", never, { "pollId": { "alias": "pollId"; "required": false; }; "messageId": { "alias": "messageId"; "required": false; }; }, {}, never, never, false, never>;
|
|
43
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { BasePollComponent } from '../base-poll.component';
|
|
2
|
+
import { Poll } from 'stream-chat';
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
/**
|
|
5
|
+
*
|
|
6
|
+
*/
|
|
7
|
+
export declare class PollComponent extends BasePollComponent {
|
|
8
|
+
isClosed: boolean;
|
|
9
|
+
protected stateStoreSelector(poll: Poll, markForCheck: () => void): () => void;
|
|
10
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<PollComponent, never>;
|
|
11
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<PollComponent, "stream-poll", never, {}, {}, never, ["[poll-header]", "[poll-options-list]", "[poll-actions]"], false, never>;
|
|
12
|
+
}
|