stream-chat-react 8.1.3-beta.1 → 8.1.3
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/dist/browser.full-bundle.js +35110 -34070
- package/dist/browser.full-bundle.js.map +1 -1
- package/dist/browser.full-bundle.min.js +5 -6
- package/dist/browser.full-bundle.min.js.map +1 -1
- package/dist/components/Attachment/Card.d.ts +2 -2
- package/dist/components/Attachment/Card.d.ts.map +1 -1
- package/dist/components/Attachment/utils.d.ts.map +1 -1
- package/dist/components/Attachment/utils.js +1 -2
- package/dist/components/AutoCompleteTextarea/Header.d.ts +2 -1
- package/dist/components/AutoCompleteTextarea/Header.d.ts.map +1 -1
- package/dist/components/AutoCompleteTextarea/List.d.ts.map +1 -1
- package/dist/components/AutoCompleteTextarea/List.js +5 -3
- package/dist/components/AutoCompleteTextarea/Textarea.d.ts +3 -1
- package/dist/components/AutoCompleteTextarea/Textarea.d.ts.map +1 -1
- package/dist/components/AutoCompleteTextarea/Textarea.js +37 -9
- package/dist/components/AutoCompleteTextarea/index.d.ts +1 -0
- package/dist/components/AutoCompleteTextarea/index.d.ts.map +1 -1
- package/dist/components/AutoCompleteTextarea/index.js +1 -0
- package/dist/components/AutoCompleteTextarea/listener.d.ts +22 -0
- package/dist/components/AutoCompleteTextarea/listener.d.ts.map +1 -0
- package/dist/components/AutoCompleteTextarea/listener.js +77 -0
- package/dist/components/Channel/Channel.d.ts.map +1 -1
- package/dist/components/Channel/Channel.js +5 -1
- package/dist/components/Channel/hooks/useCreateChannelStateContext.js +2 -2
- package/dist/components/Channel/hooks/useIsMounted.js +4 -7
- package/dist/components/ChannelHeader/ChannelHeader.d.ts.map +1 -1
- package/dist/components/ChannelHeader/ChannelHeader.js +1 -1
- package/dist/components/ChannelPreview/ChannelPreview.d.ts.map +1 -1
- package/dist/components/ChannelPreview/ChannelPreview.js +20 -4
- package/dist/components/ChannelSearch/SearchResults.d.ts.map +1 -1
- package/dist/components/Chat/hooks/useChat.d.ts.map +1 -1
- package/dist/components/Chat/hooks/useChat.js +3 -2
- package/dist/components/CommandItem/CommandItem.d.ts +2 -2
- package/dist/components/CommandItem/CommandItem.d.ts.map +1 -1
- package/dist/components/DateSeparator/DateSeparator.d.ts +1 -1
- package/dist/components/DateSeparator/DateSeparator.d.ts.map +1 -1
- package/dist/components/DateSeparator/DateSeparator.js +10 -9
- package/dist/components/EmoticonItem/EmoticonItem.d.ts +2 -1
- package/dist/components/EmoticonItem/EmoticonItem.d.ts.map +1 -1
- package/dist/components/EmptyStateIndicator/EmptyStateIndicator.d.ts +2 -1
- package/dist/components/EmptyStateIndicator/EmptyStateIndicator.d.ts.map +1 -1
- package/dist/components/EventComponent/EventComponent.d.ts.map +1 -1
- package/dist/components/EventComponent/EventComponent.js +9 -17
- package/dist/components/Gallery/Image.d.ts +2 -1
- package/dist/components/Gallery/Image.d.ts.map +1 -1
- package/dist/components/Gallery/ModalWrapper.d.ts +1 -1
- package/dist/components/Gallery/ModalWrapper.d.ts.map +1 -1
- package/dist/components/InfiniteScrollPaginator/InfiniteScroll.d.ts +2 -2
- package/dist/components/InfiniteScrollPaginator/InfiniteScroll.d.ts.map +1 -1
- package/dist/components/LoadMore/LoadMoreButton.d.ts +2 -2
- package/dist/components/LoadMore/LoadMoreButton.d.ts.map +1 -1
- package/dist/components/LoadMore/LoadMorePaginator.d.ts +3 -3
- package/dist/components/LoadMore/LoadMorePaginator.d.ts.map +1 -1
- package/dist/components/Loading/LoadingChannels.d.ts +1 -1
- package/dist/components/Loading/LoadingChannels.d.ts.map +1 -1
- package/dist/components/Loading/LoadingErrorIndicator.d.ts +2 -1
- package/dist/components/Loading/LoadingErrorIndicator.d.ts.map +1 -1
- package/dist/components/Loading/LoadingErrorIndicator.js +1 -1
- package/dist/components/Loading/LoadingIndicator.d.ts +2 -1
- package/dist/components/Loading/LoadingIndicator.d.ts.map +1 -1
- package/dist/components/MML/MML.d.ts +2 -1
- package/dist/components/MML/MML.d.ts.map +1 -1
- package/dist/components/Message/MessageDeleted.d.ts.map +1 -1
- package/dist/components/Message/MessageRepliesCountButton.d.ts +4 -3
- package/dist/components/Message/MessageRepliesCountButton.d.ts.map +1 -1
- package/dist/components/Message/MessageText.d.ts.map +1 -1
- package/dist/components/Message/MessageTimestamp.d.ts +2 -0
- package/dist/components/Message/MessageTimestamp.d.ts.map +1 -1
- package/dist/components/Message/MessageTimestamp.js +34 -7
- package/dist/components/Message/hooks/usePinHandler.d.ts +1 -1
- package/dist/components/Message/hooks/usePinHandler.d.ts.map +1 -1
- package/dist/components/Message/hooks/usePinHandler.js +3 -3
- package/dist/components/Message/utils.d.ts.map +1 -1
- package/dist/components/Message/utils.js +5 -10
- package/dist/components/MessageActions/MessageActions.d.ts.map +1 -1
- package/dist/components/MessageInput/EditMessageForm.d.ts.map +1 -1
- package/dist/components/MessageInput/EditMessageForm.js +2 -1
- package/dist/components/MessageInput/MessageInput.d.ts +2 -1
- package/dist/components/MessageInput/MessageInput.d.ts.map +1 -1
- package/dist/components/MessageInput/MessageInput.js +5 -1
- package/dist/components/MessageInput/MessageInputFlat.d.ts.map +1 -1
- package/dist/components/MessageInput/MessageInputFlat.js +1 -3
- package/dist/components/MessageInput/MessageInputSmall.d.ts.map +1 -1
- package/dist/components/MessageInput/MessageInputSmall.js +1 -3
- package/dist/components/MessageInput/QuotedMessagePreview.d.ts.map +1 -1
- package/dist/components/MessageInput/QuotedMessagePreview.js +6 -4
- package/dist/components/MessageInput/hooks/useAttachments.d.ts +4 -4
- package/dist/components/MessageInput/hooks/useCooldownTimer.d.ts +1 -1
- package/dist/components/MessageInput/hooks/useCooldownTimer.d.ts.map +1 -1
- package/dist/components/MessageInput/hooks/useFileUploads.d.ts +2 -2
- package/dist/components/MessageInput/hooks/useFileUploads.d.ts.map +1 -1
- package/dist/components/MessageInput/hooks/useImageUploads.d.ts +2 -2
- package/dist/components/MessageInput/hooks/useImageUploads.d.ts.map +1 -1
- package/dist/components/MessageInput/hooks/useMessageInputState.d.ts +1 -1
- package/dist/components/MessageInput/hooks/useMessageInputState.d.ts.map +1 -1
- package/dist/components/MessageInput/hooks/useSubmitHandler.d.ts.map +1 -1
- package/dist/components/MessageInput/hooks/useSubmitHandler.js +17 -15
- package/dist/components/MessageInput/icons.d.ts +4 -4
- package/dist/components/MessageInput/icons.d.ts.map +1 -1
- package/dist/components/MessageList/Center.d.ts +4 -2
- package/dist/components/MessageList/Center.d.ts.map +1 -1
- package/dist/components/MessageList/ConnectionStatus.d.ts +1 -2
- package/dist/components/MessageList/ConnectionStatus.d.ts.map +1 -1
- package/dist/components/MessageList/CustomNotification.d.ts +2 -2
- package/dist/components/MessageList/CustomNotification.d.ts.map +1 -1
- package/dist/components/MessageList/MessageNotification.d.ts +1 -2
- package/dist/components/MessageList/MessageNotification.d.ts.map +1 -1
- package/dist/components/Modal/Modal.d.ts +2 -2
- package/dist/components/Modal/Modal.d.ts.map +1 -1
- package/dist/components/Reactions/ReactionSelector.d.ts.map +1 -1
- package/dist/components/Reactions/ReactionSelector.js +1 -1
- package/dist/components/SafeAnchor/SafeAnchor.d.ts +2 -2
- package/dist/components/SafeAnchor/SafeAnchor.d.ts.map +1 -1
- package/dist/components/Thread/Thread.js +50 -10
- package/dist/components/Tooltip/Tooltip.d.ts +2 -2
- package/dist/components/Tooltip/Tooltip.d.ts.map +1 -1
- package/dist/components/UserItem/UserItem.d.ts +1 -1
- package/dist/components/UserItem/UserItem.d.ts.map +1 -1
- package/dist/context/ChannelActionContext.d.ts +1 -4
- package/dist/context/ChannelActionContext.d.ts.map +1 -1
- package/dist/context/ChannelStateContext.d.ts +1 -4
- package/dist/context/ChannelStateContext.d.ts.map +1 -1
- package/dist/context/ChatContext.d.ts +1 -4
- package/dist/context/ChatContext.d.ts.map +1 -1
- package/dist/context/ComponentContext.d.ts +1 -4
- package/dist/context/ComponentContext.d.ts.map +1 -1
- package/dist/context/EmojiContext.d.ts +1 -4
- package/dist/context/EmojiContext.d.ts.map +1 -1
- package/dist/context/MessageContext.d.ts +1 -4
- package/dist/context/MessageContext.d.ts.map +1 -1
- package/dist/context/TranslationContext.d.ts +5 -9
- package/dist/context/TranslationContext.d.ts.map +1 -1
- package/dist/context/TranslationContext.js +8 -6
- package/dist/context/TypingContext.d.ts +1 -4
- package/dist/context/TypingContext.d.ts.map +1 -1
- package/dist/i18n/Streami18n.d.ts +0 -1
- package/dist/i18n/Streami18n.d.ts.map +1 -1
- package/dist/i18n/Streami18n.js +2 -3
- package/dist/index.cjs.js +2045 -1884
- package/dist/index.cjs.js.map +1 -1
- package/dist/stories/{connected-user.stories.d.ts → add-message.stories.d.ts} +1 -1
- package/dist/stories/add-message.stories.d.ts.map +1 -0
- package/dist/stories/{connected-user.stories.js → add-message.stories.js} +4 -3
- package/dist/stories/jump-to-message.stories.d.ts.map +1 -1
- package/dist/stories/jump-to-message.stories.js +0 -3
- package/dist/stories/mark-read.stories.d.ts.map +1 -1
- package/dist/stories/mark-read.stories.js +2 -23
- package/dist/stories/navigate-long-message-lists.stories.d.ts +4 -0
- package/dist/stories/navigate-long-message-lists.stories.d.ts.map +1 -0
- package/dist/stories/navigate-long-message-lists.stories.js +167 -0
- package/dist/types/types.d.ts +0 -2
- package/dist/types/types.d.ts.map +1 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.d.ts.map +1 -1
- package/dist/version.js +1 -1
- package/package.json +21 -20
- package/dist/i18n/utils.d.ts +0 -13
- package/dist/i18n/utils.d.ts.map +0 -1
- package/dist/i18n/utils.js +0 -33
- package/dist/stories/connected-user.stories.d.ts.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MessageContext.d.ts","sourceRoot":"","sources":["../../src/context/MessageContext.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,iBAAiB,EAAc,MAAM,OAAO,CAAC;AAE7D,OAAO,KAAK,EAAE,IAAI,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAEtD,OAAO,KAAK,EAAE,yBAAy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AAO,CAAC;CACtB,CAAC;AAEF,eAAO,MAAM,cAAc,2EAAkE,CAAC;AAE9F,eAAO,MAAM,eAAe;;kBAW3B,CAAC;AAEF,eAAO,MAAM,iBAAiB,mKAgB7B,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,kBAAkB,kNAqB9B,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import React
|
|
1
|
+
import React from 'react';
|
|
2
2
|
import Dayjs from 'dayjs';
|
|
3
3
|
import type { TFunction } from 'i18next';
|
|
4
4
|
import type { Moment } from 'moment';
|
|
@@ -13,18 +13,14 @@ export declare type TDateTimeParserInput = string | number | Date;
|
|
|
13
13
|
export declare type TDateTimeParserOutput = string | number | Date | Dayjs.Dayjs | Moment;
|
|
14
14
|
export declare type TDateTimeParser = (input?: TDateTimeParserInput) => TDateTimeParserOutput;
|
|
15
15
|
export declare type TranslationContextValue = {
|
|
16
|
-
t: TFunction;
|
|
16
|
+
t: TFunction | ((key: string) => string);
|
|
17
17
|
tDateTimeParser: TDateTimeParser;
|
|
18
18
|
userLanguage: TranslationLanguages;
|
|
19
19
|
};
|
|
20
|
-
export declare const defaultDateTimeParser: (input?: TDateTimeParserInput | undefined) => Dayjs.Dayjs;
|
|
21
20
|
export declare const TranslationContext: React.Context<TranslationContextValue>;
|
|
22
|
-
export declare const TranslationProvider:
|
|
21
|
+
export declare const TranslationProvider: React.FC<{
|
|
23
22
|
value: TranslationContextValue;
|
|
24
|
-
}
|
|
23
|
+
}>;
|
|
25
24
|
export declare const useTranslationContext: (componentName?: string | undefined) => TranslationContextValue;
|
|
26
|
-
export declare const withTranslationContext: <P extends UnknownType>(Component: React.ComponentType<P>) =>
|
|
27
|
-
(props: Omit<P, keyof TranslationContextValue>): JSX.Element;
|
|
28
|
-
displayName: string;
|
|
29
|
-
};
|
|
25
|
+
export declare const withTranslationContext: <P extends UnknownType>(Component: React.ComponentType<P>) => React.FC<Omit<P, keyof TranslationContextValue>>;
|
|
30
26
|
//# sourceMappingURL=TranslationContext.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TranslationContext.d.ts","sourceRoot":"","sources":["../../src/context/TranslationContext.tsx"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"TranslationContext.d.ts","sourceRoot":"","sources":["../../src/context/TranslationContext.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAqB,MAAM,OAAO,CAAC;AAC1C,OAAO,KAAK,MAAM,OAAO,CAAC;AAM1B,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AACzC,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AACrC,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAC;AAExD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAKlD,oBAAY,qBAAqB,GAC7B,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,GACJ,IAAI,CAAC;AAET,eAAO,MAAM,mBAAmB,aAAc,MAAM,sCAGnD,CAAC;AAEF,eAAO,MAAM,aAAa,WAAY,qBAAqB,mCACV,CAAC;AAElD,eAAO,MAAM,MAAM,WAAY,qBAAqB,mBACjB,CAAC;AAEpC,eAAO,MAAM,gBAAgB,WAAY,qBAAqB,8BACJ,CAAC;AAE3D,oBAAY,oBAAoB,GAAG,MAAM,GAAG,MAAM,GAAG,IAAI,CAAC;AAE1D,oBAAY,qBAAqB,GAAG,MAAM,GAAG,MAAM,GAAG,IAAI,GAAG,KAAK,CAAC,KAAK,GAAG,MAAM,CAAC;AAElF,oBAAY,eAAe,GAAG,CAAC,KAAK,CAAC,EAAE,oBAAoB,KAAK,qBAAqB,CAAC;AAEtF,oBAAY,uBAAuB,GAAG;IACpC,CAAC,EAAE,SAAS,GAAG,CAAC,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC,CAAC;IACzC,eAAe,EAAE,eAAe,CAAC;IACjC,YAAY,EAAE,oBAAoB,CAAC;CACpC,CAAC;AAEF,eAAO,MAAM,kBAAkB,wCAI7B,CAAC;AAEH,eAAO,MAAM,mBAAmB,EAAE,KAAK,CAAC,EAAE,CAAC;IACzC,KAAK,EAAE,uBAAuB,CAAC;CAChC,CAEA,CAAC;AAEF,eAAO,MAAM,qBAAqB,iEAYjC,CAAC;AAEF,eAAO,MAAM,sBAAsB,gHAclC,CAAC"}
|
|
@@ -14,22 +14,24 @@ import Dayjs from 'dayjs';
|
|
|
14
14
|
import calendar from 'dayjs/plugin/calendar';
|
|
15
15
|
import localizedFormat from 'dayjs/plugin/localizedFormat';
|
|
16
16
|
import { getDisplayName } from './utils/getDisplayName';
|
|
17
|
-
import { defaultTranslatorFunction } from '../i18n';
|
|
18
17
|
Dayjs.extend(calendar);
|
|
19
18
|
Dayjs.extend(localizedFormat);
|
|
20
19
|
export var isLanguageSupported = function (language) {
|
|
21
20
|
var translations = ['de', 'en', 'es', 'fr', 'hi', 'it', 'ja', 'ko', 'nl', 'pt', 'ru', 'tr'];
|
|
22
21
|
return translations.some(function (translation) { return language === translation; });
|
|
23
22
|
};
|
|
24
|
-
export var isDayOrMoment = function (output) {
|
|
25
|
-
|
|
23
|
+
export var isDayOrMoment = function (output) {
|
|
24
|
+
return output.isSame != null;
|
|
25
|
+
};
|
|
26
|
+
export var isDate = function (output) {
|
|
27
|
+
return output.getMonth != null;
|
|
28
|
+
};
|
|
26
29
|
export var isNumberOrString = function (output) {
|
|
27
30
|
return typeof output === 'string' || typeof output === 'number';
|
|
28
31
|
};
|
|
29
|
-
export var defaultDateTimeParser = function (input) { return Dayjs(input); };
|
|
30
32
|
export var TranslationContext = React.createContext({
|
|
31
|
-
t:
|
|
32
|
-
tDateTimeParser:
|
|
33
|
+
t: function (key) { return key; },
|
|
34
|
+
tDateTimeParser: function (input) { return Dayjs(input); },
|
|
33
35
|
userLanguage: 'en',
|
|
34
36
|
});
|
|
35
37
|
export var TranslationProvider = function (_a) {
|
|
@@ -14,8 +14,5 @@ export declare const useTypingContext: <StreamChatGenerics extends DefaultStream
|
|
|
14
14
|
* typing is desired while using the HOC withTypingContext, the Props for the
|
|
15
15
|
* wrapped component must be provided as the first generic.
|
|
16
16
|
*/
|
|
17
|
-
export declare const withTypingContext: <P extends UnknownType, StreamChatGenerics extends DefaultStreamChatGenerics = DefaultStreamChatGenerics>(Component: React.ComponentType<P>) =>
|
|
18
|
-
(props: Omit<P, "typing">): JSX.Element;
|
|
19
|
-
displayName: string;
|
|
20
|
-
};
|
|
17
|
+
export declare const withTypingContext: <P extends UnknownType, StreamChatGenerics extends DefaultStreamChatGenerics = DefaultStreamChatGenerics>(Component: React.ComponentType<P>) => React.FC<Omit<P, "typing">>;
|
|
21
18
|
//# sourceMappingURL=TypingContext.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TypingContext.d.ts","sourceRoot":"","sources":["../../src/context/TypingContext.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,iBAAiB,EAAc,MAAM,OAAO,CAAC;AAE7D,OAAO,KAAK,EAAE,YAAY,IAAI,kBAAkB,EAAE,MAAM,aAAa,CAAC;AAEtE,OAAO,KAAK,EAAE,yBAAyB,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7E,oBAAY,kBAAkB,CAC5B,kBAAkB,SAAS,yBAAyB,GAAG,yBAAyB,IAC9E;IACF,MAAM,CAAC,EAAE,kBAAkB,CAAC,kBAAkB,CAAC,CAAC,QAAQ,CAAC,CAAC;CAC3D,CAAC;AAEF,eAAO,MAAM,aAAa,0EAAiE,CAAC;AAE5F,eAAO,MAAM,cAAc;;kBAW1B,CAAC;AAEF,eAAO,MAAM,gBAAgB,kKAgB5B,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,iBAAiB
|
|
1
|
+
{"version":3,"file":"TypingContext.d.ts","sourceRoot":"","sources":["../../src/context/TypingContext.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,iBAAiB,EAAc,MAAM,OAAO,CAAC;AAE7D,OAAO,KAAK,EAAE,YAAY,IAAI,kBAAkB,EAAE,MAAM,aAAa,CAAC;AAEtE,OAAO,KAAK,EAAE,yBAAyB,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7E,oBAAY,kBAAkB,CAC5B,kBAAkB,SAAS,yBAAyB,GAAG,yBAAyB,IAC9E;IACF,MAAM,CAAC,EAAE,kBAAkB,CAAC,kBAAkB,CAAC,CAAC,QAAQ,CAAC,CAAC;CAC3D,CAAC;AAEF,eAAO,MAAM,aAAa,0EAAiE,CAAC;AAE5F,eAAO,MAAM,cAAc;;kBAW1B,CAAC;AAEF,eAAO,MAAM,gBAAgB,kKAgB5B,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,iBAAiB,6KAqB7B,CAAC"}
|
|
@@ -26,7 +26,6 @@ declare type Options = {
|
|
|
26
26
|
logger?: (message?: string) => void;
|
|
27
27
|
translationsForLanguage?: Partial<typeof enTranslations>;
|
|
28
28
|
};
|
|
29
|
-
export declare const defaultTranslatorFunction: TFunction;
|
|
30
29
|
export declare class Streami18n {
|
|
31
30
|
i18nInstance: import("i18next").i18n;
|
|
32
31
|
Dayjs: null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Streami18n.d.ts","sourceRoot":"","sources":["../../src/i18n/Streami18n.ts"],"names":[],"mappings":"AAAA,OAAa,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAC1C,OAAO,KAAK,MAAM,OAAO,CAAC;AAO1B,OAAO,KAAK,MAAM,MAAM,QAAQ,CAAC;AACjC,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,aAAa,CAAC;AAExD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,+BAA+B,CAAC;AAErE,OAAO,K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|
@@ -388,7 +388,7 @@ var isDayJs = function (dateTimeParser) {
|
|
|
388
388
|
* DateTimeParser: Dayjs
|
|
389
389
|
* })
|
|
390
390
|
* ```
|
|
391
|
-
* If you would like to stick with english language for datetimes in Stream
|
|
391
|
+
* If you would like to stick with english language for datetimes in Stream compoments, you can set `disableDateTimeTranslations` to true.
|
|
392
392
|
*
|
|
393
393
|
*/
|
|
394
394
|
var defaultStreami18nOptions = {
|
|
@@ -399,7 +399,6 @@ var defaultStreami18nOptions = {
|
|
|
399
399
|
language: 'en',
|
|
400
400
|
logger: function (message) { return console.warn(message); },
|
|
401
401
|
};
|
|
402
|
-
export var defaultTranslatorFunction = function (key) { return key; };
|
|
403
402
|
var Streami18n = /** @class */ (function () {
|
|
404
403
|
/**
|
|
405
404
|
* Constructor accepts following options:
|
|
@@ -435,7 +434,7 @@ var Streami18n = /** @class */ (function () {
|
|
|
435
434
|
this.Dayjs = null;
|
|
436
435
|
this.setLanguageCallback = function () { return null; };
|
|
437
436
|
this.initialized = false;
|
|
438
|
-
this.t =
|
|
437
|
+
this.t = function (key) { return key; };
|
|
439
438
|
this.translations = {
|
|
440
439
|
de: (_a = {}, _a[defaultNS] = deTranslations, _a),
|
|
441
440
|
en: (_b = {}, _b[defaultNS] = enTranslations, _b),
|