@sendbird/uikit-react 3.4.7 → 3.4.8-rc.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/App.js +46 -46
- package/App.js.map +1 -1
- package/CHANGELOG.md +26 -0
- package/Channel/components/ChannelHeader.js +18 -22
- package/Channel/components/ChannelHeader.js.map +1 -1
- package/Channel/components/ChannelUI.js +43 -43
- package/Channel/components/ChannelUI.js.map +1 -1
- package/Channel/components/FileViewer.js +14 -17
- package/Channel/components/FileViewer.js.map +1 -1
- package/Channel/components/FrozenNotification.js +4 -4
- package/Channel/components/FrozenNotification.js.map +1 -1
- package/Channel/components/Message.js +38 -38
- package/Channel/components/Message.js.map +1 -1
- package/Channel/components/MessageInput.js +30 -33
- package/Channel/components/MessageInput.js.map +1 -1
- package/Channel/components/MessageList.js +51 -44
- package/Channel/components/MessageList.js.map +1 -1
- package/Channel/components/RemoveMessageModal.js +16 -20
- package/Channel/components/RemoveMessageModal.js.map +1 -1
- package/Channel/components/SuggestedMentionList.js +18 -24
- package/Channel/components/SuggestedMentionList.js.map +1 -1
- package/Channel/components/TypingIndicator.js +14 -20
- package/Channel/components/TypingIndicator.js.map +1 -1
- package/Channel/components/UnreadCount.js +4 -4
- package/Channel/components/UnreadCount.js.map +1 -1
- package/Channel/context.js +11 -19
- package/Channel/context.js.map +1 -1
- package/Channel.js +43 -43
- package/Channel.js.map +1 -1
- package/ChannelList/components/AddChannel.js +14 -14
- package/ChannelList/components/AddChannel.js.map +1 -1
- package/ChannelList/components/ChannelListHeader.js +8 -8
- package/ChannelList/components/ChannelListHeader.js.map +1 -1
- package/ChannelList/components/ChannelListUI.js +29 -30
- package/ChannelList/components/ChannelListUI.js.map +1 -1
- package/ChannelList/components/ChannelPreview.js +25 -28
- package/ChannelList/components/ChannelPreview.js.map +1 -1
- package/ChannelList/components/ChannelPreviewAction.js +17 -15
- package/ChannelList/components/ChannelPreviewAction.js.map +1 -1
- package/ChannelList/context.js +7 -7
- package/ChannelList.js +29 -30
- package/ChannelList.js.map +1 -1
- package/{ChannelListProvider-8be91a05.js → ChannelListProvider-e8ad86b6.js} +15 -19
- package/ChannelListProvider-e8ad86b6.js.map +1 -0
- package/{ChannelProvider-d643e6d9.js → ChannelProvider-6de56b36.js} +13 -97
- package/ChannelProvider-6de56b36.js.map +1 -0
- package/ChannelSettings/components/ChannelProfile.js +11 -11
- package/ChannelSettings/components/ChannelProfile.js.map +1 -1
- package/ChannelSettings/components/ChannelSettingsUI.js +17 -17
- package/ChannelSettings/components/ChannelSettingsUI.js.map +1 -1
- package/ChannelSettings/components/EditDetailsModal.js +11 -11
- package/ChannelSettings/components/EditDetailsModal.js.map +1 -1
- package/ChannelSettings/components/LeaveChannel.js +11 -11
- package/ChannelSettings/components/LeaveChannel.js.map +1 -1
- package/ChannelSettings/components/ModerationPanel.js +14 -14
- package/ChannelSettings/components/ModerationPanel.js.map +1 -1
- package/ChannelSettings/components/UserListItem.js +10 -10
- package/ChannelSettings/components/UserListItem.js.map +1 -1
- package/ChannelSettings/components/UserPanel.js +13 -13
- package/ChannelSettings/components/UserPanel.js.map +1 -1
- package/ChannelSettings/context.js +3 -3
- package/ChannelSettings/context.js.map +1 -1
- package/ChannelSettings.js +18 -18
- package/ChannelSettings.js.map +1 -1
- package/CreateChannel/components/CreateChannelUI.js +13 -13
- package/CreateChannel/components/CreateChannelUI.js.map +1 -1
- package/CreateChannel/components/InviteUsers.js +14 -14
- package/CreateChannel/components/InviteUsers.js.map +1 -1
- package/CreateChannel/components/SelectChannelType.js +10 -10
- package/CreateChannel/components/SelectChannelType.js.map +1 -1
- package/CreateChannel/context.js +4 -4
- package/CreateChannel.js +13 -13
- package/CreateChannel.js.map +1 -1
- package/{CreateChannelProvider-5674e81b.js → CreateChannelProvider-64578d2a.js} +1 -1
- package/{CreateChannelProvider-5674e81b.js.map → CreateChannelProvider-64578d2a.js.map} +1 -1
- package/CreateOpenChannel/components/CreateOpenChannelUI.js +9 -9
- package/CreateOpenChannel/components/CreateOpenChannelUI.js.map +1 -1
- package/CreateOpenChannel/context.js +1 -1
- package/CreateOpenChannel/context.js.map +1 -1
- package/CreateOpenChannel.js +9 -9
- package/CreateOpenChannel.js.map +1 -1
- package/EditUserProfile/components/EditUserProfileUI.js +12 -12
- package/EditUserProfile/context.js.map +1 -1
- package/EditUserProfile.js +12 -12
- package/EditUserProfile.js.map +1 -1
- package/{LocalizationContext-ad70364c.js → LocalizationContext-7ae12588.js} +3 -3
- package/{LocalizationContext-ad70364c.js.map → LocalizationContext-7ae12588.js.map} +1 -1
- package/{MediaQueryContext-4e555ef5.js → MediaQueryContext-05d4db73.js} +1 -1
- package/MediaQueryContext-05d4db73.js.map +1 -0
- package/{MemberList-24b818f8.js → MemberList-9634fee8.js} +5 -5
- package/MemberList-9634fee8.js.map +1 -0
- package/Message/context.js.map +1 -1
- package/MessageSearch/components/MessageSearchUI.js +11 -11
- package/MessageSearch/components/MessageSearchUI.js.map +1 -1
- package/MessageSearch/context.js +1 -1
- package/MessageSearch/context.js.map +1 -1
- package/MessageSearch.js +11 -11
- package/MessageSearch.js.map +1 -1
- package/OpenChannel/components/FrozenChannelNotification.js +4 -4
- package/OpenChannel/components/FrozenChannelNotification.js.map +1 -1
- package/OpenChannel/components/OpenChannelHeader.js +12 -12
- package/OpenChannel/components/OpenChannelHeader.js.map +1 -1
- package/OpenChannel/components/OpenChannelInput.js +18 -18
- package/OpenChannel/components/OpenChannelInput.js.map +1 -1
- package/OpenChannel/components/OpenChannelMessage.js +27 -32
- package/OpenChannel/components/OpenChannelMessage.js.map +1 -1
- package/OpenChannel/components/OpenChannelMessageList.js +31 -31
- package/OpenChannel/components/OpenChannelMessageList.js.map +1 -1
- package/OpenChannel/components/OpenChannelUI.js +31 -31
- package/OpenChannel/components/OpenChannelUI.js.map +1 -1
- package/OpenChannel/context.js +8 -8
- package/OpenChannel.js +31 -31
- package/OpenChannel.js.map +1 -1
- package/OpenChannelList/components/OpenChannelListUI.js +13 -13
- package/OpenChannelList/components/OpenChannelListUI.js.map +1 -1
- package/OpenChannelList/components/OpenChannelPreview.js +3 -3
- package/OpenChannelList/components/OpenChannelPreview.js.map +1 -1
- package/OpenChannelList/context.js +3 -3
- package/OpenChannelList.js +13 -13
- package/OpenChannelList.js.map +1 -1
- package/{OpenChannelListProvider-27822936.js → OpenChannelListProvider-f6a88782.js} +3 -3
- package/{OpenChannelListProvider-27822936.js.map → OpenChannelListProvider-f6a88782.js.map} +1 -1
- package/{OpenChannelProvider-5148963b.js → OpenChannelProvider-f1a4b4fa.js} +9 -7
- package/OpenChannelProvider-f1a4b4fa.js.map +1 -0
- package/OpenChannelSettings/components/EditDetailsModal.js +13 -13
- package/OpenChannelSettings/components/EditDetailsModal.js.map +1 -1
- package/OpenChannelSettings/components/OpenChannelProfile.js +12 -12
- package/OpenChannelSettings/components/OpenChannelProfile.js.map +1 -1
- package/OpenChannelSettings/components/OpenChannelSettingsUI.js +17 -17
- package/OpenChannelSettings/components/OpenChannelSettingsUI.js.map +1 -1
- package/OpenChannelSettings/components/OperatorUI.js +16 -16
- package/OpenChannelSettings/components/OperatorUI.js.map +1 -1
- package/OpenChannelSettings/components/ParticipantUI.js +14 -14
- package/OpenChannelSettings/context.js +3 -3
- package/OpenChannelSettings/context.js.map +1 -1
- package/OpenChannelSettings.js +17 -17
- package/OpenChannelSettings.js.map +1 -1
- package/README.md +28 -8
- package/{RemoveMessageModal-54d1b0a4.js → RemoveMessageModal-2b9bdeed.js} +3 -3
- package/{RemoveMessageModal-54d1b0a4.js.map → RemoveMessageModal-2b9bdeed.js.map} +1 -1
- package/SendbirdProvider.js +13 -13
- package/SendbirdProvider.js.map +1 -1
- package/Thread/components/ParentMessageInfo.js +32 -32
- package/Thread/components/ParentMessageInfo.js.map +1 -1
- package/Thread/components/ParentMessageInfoItem.js +18 -18
- package/Thread/components/ParentMessageInfoItem.js.map +1 -1
- package/Thread/components/ThreadHeader.js +6 -6
- package/Thread/components/ThreadHeader.js.map +1 -1
- package/Thread/components/ThreadList.js +35 -35
- package/Thread/components/ThreadList.js.map +1 -1
- package/Thread/components/ThreadListItem.js +34 -34
- package/Thread/components/ThreadListItem.js.map +1 -1
- package/Thread/components/ThreadMessageInput.js +28 -31
- package/Thread/components/ThreadMessageInput.js.map +1 -1
- package/Thread/components/ThreadUI.js +36 -36
- package/Thread/components/ThreadUI.js.map +1 -1
- package/Thread/context.js +8 -8
- package/Thread.js +36 -36
- package/Thread.js.map +1 -1
- package/{ThreadProvider-96a5e77e.js → ThreadProvider-5a216f9d.js} +7 -7
- package/ThreadProvider-5a216f9d.js.map +1 -0
- package/{UserProfileContext-b68f33fc.js → UserProfileContext-e8124c47.js} +1 -1
- package/{UserProfileContext-b68f33fc.js.map → UserProfileContext-e8124c47.js.map} +1 -1
- package/{VoiceMessageInputWrapper-07631f8d.js → VoiceMessageInputWrapper-ce56172a.js} +8 -8
- package/VoiceMessageInputWrapper-ce56172a.js.map +1 -0
- package/VoicePlayer/context.js +3 -3
- package/VoicePlayer/useVoicePlayer.js +6 -6
- package/VoicePlayer/useVoicePlayer.js.map +1 -1
- package/VoiceRecorder/context.js +6 -6
- package/VoiceRecorder/context.js.map +1 -1
- package/VoiceRecorder/useVoiceRecorder.js +3 -2
- package/VoiceRecorder/useVoiceRecorder.js.map +1 -1
- package/{WebAudioUtils-3fb13b51.js → WebAudioUtils-6229e96a.js} +1 -1
- package/{WebAudioUtils-3fb13b51.js.map → WebAudioUtils-6229e96a.js.map} +1 -1
- package/{_rollupPluginBabelHelpers-5d0c716a.js → _rollupPluginBabelHelpers-96062e23.js} +1 -1
- package/_rollupPluginBabelHelpers-96062e23.js.map +1 -0
- package/{actionTypes-b270327e.js → actionTypes-423a1fac.js} +1 -1
- package/{actionTypes-b270327e.js.map → actionTypes-423a1fac.js.map} +1 -1
- package/cjs/App.js +46 -46
- package/cjs/App.js.map +1 -1
- package/cjs/Channel/components/ChannelHeader.js +18 -22
- package/cjs/Channel/components/ChannelHeader.js.map +1 -1
- package/cjs/Channel/components/ChannelUI.js +43 -43
- package/cjs/Channel/components/ChannelUI.js.map +1 -1
- package/cjs/Channel/components/FileViewer.js +14 -17
- package/cjs/Channel/components/FileViewer.js.map +1 -1
- package/cjs/Channel/components/FrozenNotification.js +4 -4
- package/cjs/Channel/components/FrozenNotification.js.map +1 -1
- package/cjs/Channel/components/Message.js +38 -38
- package/cjs/Channel/components/Message.js.map +1 -1
- package/cjs/Channel/components/MessageInput.js +30 -33
- package/cjs/Channel/components/MessageInput.js.map +1 -1
- package/cjs/Channel/components/MessageList.js +51 -44
- package/cjs/Channel/components/MessageList.js.map +1 -1
- package/cjs/Channel/components/RemoveMessageModal.js +16 -20
- package/cjs/Channel/components/RemoveMessageModal.js.map +1 -1
- package/cjs/Channel/components/SuggestedMentionList.js +18 -24
- package/cjs/Channel/components/SuggestedMentionList.js.map +1 -1
- package/cjs/Channel/components/TypingIndicator.js +14 -20
- package/cjs/Channel/components/TypingIndicator.js.map +1 -1
- package/cjs/Channel/components/UnreadCount.js +4 -4
- package/cjs/Channel/components/UnreadCount.js.map +1 -1
- package/cjs/Channel/context.js +11 -19
- package/cjs/Channel/context.js.map +1 -1
- package/cjs/Channel.js +43 -43
- package/cjs/Channel.js.map +1 -1
- package/cjs/ChannelList/components/AddChannel.js +14 -14
- package/cjs/ChannelList/components/AddChannel.js.map +1 -1
- package/cjs/ChannelList/components/ChannelListHeader.js +8 -8
- package/cjs/ChannelList/components/ChannelListHeader.js.map +1 -1
- package/cjs/ChannelList/components/ChannelListUI.js +29 -30
- package/cjs/ChannelList/components/ChannelListUI.js.map +1 -1
- package/cjs/ChannelList/components/ChannelPreview.js +25 -28
- package/cjs/ChannelList/components/ChannelPreview.js.map +1 -1
- package/cjs/ChannelList/components/ChannelPreviewAction.js +17 -15
- package/cjs/ChannelList/components/ChannelPreviewAction.js.map +1 -1
- package/cjs/ChannelList/context.js +7 -7
- package/cjs/ChannelList.js +29 -30
- package/cjs/ChannelList.js.map +1 -1
- package/cjs/{ChannelListProvider-6b61a484.js → ChannelListProvider-2bcdc671.js} +15 -19
- package/cjs/ChannelListProvider-2bcdc671.js.map +1 -0
- package/cjs/{ChannelProvider-12a12f31.js → ChannelProvider-2a01302b.js} +12 -96
- package/cjs/ChannelProvider-2a01302b.js.map +1 -0
- package/cjs/ChannelSettings/components/ChannelProfile.js +11 -11
- package/cjs/ChannelSettings/components/ChannelProfile.js.map +1 -1
- package/cjs/ChannelSettings/components/ChannelSettingsUI.js +17 -17
- package/cjs/ChannelSettings/components/ChannelSettingsUI.js.map +1 -1
- package/cjs/ChannelSettings/components/EditDetailsModal.js +11 -11
- package/cjs/ChannelSettings/components/EditDetailsModal.js.map +1 -1
- package/cjs/ChannelSettings/components/LeaveChannel.js +11 -11
- package/cjs/ChannelSettings/components/LeaveChannel.js.map +1 -1
- package/cjs/ChannelSettings/components/ModerationPanel.js +14 -14
- package/cjs/ChannelSettings/components/ModerationPanel.js.map +1 -1
- package/cjs/ChannelSettings/components/UserListItem.js +10 -10
- package/cjs/ChannelSettings/components/UserListItem.js.map +1 -1
- package/cjs/ChannelSettings/components/UserPanel.js +13 -13
- package/cjs/ChannelSettings/components/UserPanel.js.map +1 -1
- package/cjs/ChannelSettings/context.js +3 -3
- package/cjs/ChannelSettings/context.js.map +1 -1
- package/cjs/ChannelSettings.js +18 -18
- package/cjs/ChannelSettings.js.map +1 -1
- package/cjs/CreateChannel/components/CreateChannelUI.js +13 -13
- package/cjs/CreateChannel/components/CreateChannelUI.js.map +1 -1
- package/cjs/CreateChannel/components/InviteUsers.js +14 -14
- package/cjs/CreateChannel/components/InviteUsers.js.map +1 -1
- package/cjs/CreateChannel/components/SelectChannelType.js +10 -10
- package/cjs/CreateChannel/components/SelectChannelType.js.map +1 -1
- package/cjs/CreateChannel/context.js +4 -4
- package/cjs/CreateChannel.js +13 -13
- package/cjs/CreateChannel.js.map +1 -1
- package/cjs/{CreateChannelProvider-2beb2415.js → CreateChannelProvider-8f7d9505.js} +1 -1
- package/cjs/{CreateChannelProvider-2beb2415.js.map → CreateChannelProvider-8f7d9505.js.map} +1 -1
- package/cjs/CreateOpenChannel/components/CreateOpenChannelUI.js +9 -9
- package/cjs/CreateOpenChannel/components/CreateOpenChannelUI.js.map +1 -1
- package/cjs/CreateOpenChannel/context.js +1 -1
- package/cjs/CreateOpenChannel/context.js.map +1 -1
- package/cjs/CreateOpenChannel.js +9 -9
- package/cjs/CreateOpenChannel.js.map +1 -1
- package/cjs/EditUserProfile/components/EditUserProfileUI.js +12 -12
- package/cjs/EditUserProfile/context.js.map +1 -1
- package/cjs/EditUserProfile.js +12 -12
- package/cjs/EditUserProfile.js.map +1 -1
- package/cjs/{LocalizationContext-30772f4a.js → LocalizationContext-975ffc10.js} +3 -3
- package/cjs/{LocalizationContext-30772f4a.js.map → LocalizationContext-975ffc10.js.map} +1 -1
- package/cjs/{MediaQueryContext-3b09499c.js → MediaQueryContext-302f1c4f.js} +1 -1
- package/cjs/MediaQueryContext-302f1c4f.js.map +1 -0
- package/cjs/{MemberList-f0c4e234.js → MemberList-0c0c303c.js} +5 -5
- package/cjs/MemberList-0c0c303c.js.map +1 -0
- package/cjs/Message/context.js.map +1 -1
- package/cjs/MessageSearch/components/MessageSearchUI.js +11 -11
- package/cjs/MessageSearch/components/MessageSearchUI.js.map +1 -1
- package/cjs/MessageSearch/context.js +1 -1
- package/cjs/MessageSearch/context.js.map +1 -1
- package/cjs/MessageSearch.js +11 -11
- package/cjs/MessageSearch.js.map +1 -1
- package/cjs/OpenChannel/components/FrozenChannelNotification.js +4 -4
- package/cjs/OpenChannel/components/FrozenChannelNotification.js.map +1 -1
- package/cjs/OpenChannel/components/OpenChannelHeader.js +12 -12
- package/cjs/OpenChannel/components/OpenChannelHeader.js.map +1 -1
- package/cjs/OpenChannel/components/OpenChannelInput.js +18 -18
- package/cjs/OpenChannel/components/OpenChannelInput.js.map +1 -1
- package/cjs/OpenChannel/components/OpenChannelMessage.js +27 -32
- package/cjs/OpenChannel/components/OpenChannelMessage.js.map +1 -1
- package/cjs/OpenChannel/components/OpenChannelMessageList.js +31 -31
- package/cjs/OpenChannel/components/OpenChannelMessageList.js.map +1 -1
- package/cjs/OpenChannel/components/OpenChannelUI.js +31 -31
- package/cjs/OpenChannel/components/OpenChannelUI.js.map +1 -1
- package/cjs/OpenChannel/context.js +8 -8
- package/cjs/OpenChannel.js +31 -31
- package/cjs/OpenChannel.js.map +1 -1
- package/cjs/OpenChannelList/components/OpenChannelListUI.js +13 -13
- package/cjs/OpenChannelList/components/OpenChannelListUI.js.map +1 -1
- package/cjs/OpenChannelList/components/OpenChannelPreview.js +3 -3
- package/cjs/OpenChannelList/components/OpenChannelPreview.js.map +1 -1
- package/cjs/OpenChannelList/context.js +3 -3
- package/cjs/OpenChannelList.js +13 -13
- package/cjs/OpenChannelList.js.map +1 -1
- package/cjs/{OpenChannelListProvider-d48bd733.js → OpenChannelListProvider-ef3655ce.js} +3 -3
- package/cjs/{OpenChannelListProvider-d48bd733.js.map → OpenChannelListProvider-ef3655ce.js.map} +1 -1
- package/cjs/{OpenChannelProvider-56846c0c.js → OpenChannelProvider-c500275a.js} +9 -7
- package/cjs/OpenChannelProvider-c500275a.js.map +1 -0
- package/cjs/OpenChannelSettings/components/EditDetailsModal.js +13 -13
- package/cjs/OpenChannelSettings/components/EditDetailsModal.js.map +1 -1
- package/cjs/OpenChannelSettings/components/OpenChannelProfile.js +12 -12
- package/cjs/OpenChannelSettings/components/OpenChannelProfile.js.map +1 -1
- package/cjs/OpenChannelSettings/components/OpenChannelSettingsUI.js +17 -17
- package/cjs/OpenChannelSettings/components/OpenChannelSettingsUI.js.map +1 -1
- package/cjs/OpenChannelSettings/components/OperatorUI.js +16 -16
- package/cjs/OpenChannelSettings/components/OperatorUI.js.map +1 -1
- package/cjs/OpenChannelSettings/components/ParticipantUI.js +14 -14
- package/cjs/OpenChannelSettings/context.js +3 -3
- package/cjs/OpenChannelSettings/context.js.map +1 -1
- package/cjs/OpenChannelSettings.js +17 -17
- package/cjs/OpenChannelSettings.js.map +1 -1
- package/cjs/{RemoveMessageModal-e0480b7c.js → RemoveMessageModal-f8277edf.js} +3 -3
- package/cjs/{RemoveMessageModal-e0480b7c.js.map → RemoveMessageModal-f8277edf.js.map} +1 -1
- package/cjs/SendbirdProvider.js +13 -13
- package/cjs/SendbirdProvider.js.map +1 -1
- package/cjs/Thread/components/ParentMessageInfo.js +32 -32
- package/cjs/Thread/components/ParentMessageInfo.js.map +1 -1
- package/cjs/Thread/components/ParentMessageInfoItem.js +18 -18
- package/cjs/Thread/components/ParentMessageInfoItem.js.map +1 -1
- package/cjs/Thread/components/ThreadHeader.js +6 -6
- package/cjs/Thread/components/ThreadHeader.js.map +1 -1
- package/cjs/Thread/components/ThreadList.js +35 -35
- package/cjs/Thread/components/ThreadList.js.map +1 -1
- package/cjs/Thread/components/ThreadListItem.js +34 -34
- package/cjs/Thread/components/ThreadListItem.js.map +1 -1
- package/cjs/Thread/components/ThreadMessageInput.js +28 -31
- package/cjs/Thread/components/ThreadMessageInput.js.map +1 -1
- package/cjs/Thread/components/ThreadUI.js +36 -36
- package/cjs/Thread/components/ThreadUI.js.map +1 -1
- package/cjs/Thread/context.js +8 -8
- package/cjs/Thread.js +36 -36
- package/cjs/Thread.js.map +1 -1
- package/cjs/{ThreadProvider-1ebd5bc0.js → ThreadProvider-e8f49239.js} +7 -7
- package/cjs/ThreadProvider-e8f49239.js.map +1 -0
- package/cjs/{UserProfileContext-eb5a10d6.js → UserProfileContext-8b19c6c3.js} +1 -1
- package/cjs/{UserProfileContext-eb5a10d6.js.map → UserProfileContext-8b19c6c3.js.map} +1 -1
- package/cjs/{VoiceMessageInputWrapper-044427b2.js → VoiceMessageInputWrapper-5dfaba8f.js} +8 -8
- package/cjs/VoiceMessageInputWrapper-5dfaba8f.js.map +1 -0
- package/cjs/VoicePlayer/context.js +3 -3
- package/cjs/VoicePlayer/useVoicePlayer.js +6 -6
- package/cjs/VoicePlayer/useVoicePlayer.js.map +1 -1
- package/cjs/VoiceRecorder/context.js +6 -6
- package/cjs/VoiceRecorder/context.js.map +1 -1
- package/cjs/VoiceRecorder/useVoiceRecorder.js +3 -2
- package/cjs/VoiceRecorder/useVoiceRecorder.js.map +1 -1
- package/cjs/{WebAudioUtils-57d7e366.js → WebAudioUtils-2bd92ed1.js} +1 -1
- package/cjs/{WebAudioUtils-57d7e366.js.map → WebAudioUtils-2bd92ed1.js.map} +1 -1
- package/cjs/{_rollupPluginBabelHelpers-4b6406c2.js → _rollupPluginBabelHelpers-596e2aef.js} +1 -1
- package/cjs/_rollupPluginBabelHelpers-596e2aef.js.map +1 -0
- package/cjs/{actionTypes-f66e00c2.js → actionTypes-29997777.js} +1 -1
- package/cjs/{actionTypes-f66e00c2.js.map → actionTypes-29997777.js.map} +1 -1
- package/cjs/{color-4904d01e.js → color-ac868fc0.js} +1 -1
- package/cjs/{color-4904d01e.js.map → color-ac868fc0.js.map} +1 -1
- package/cjs/{compareIds-de8d3b96.js → compareIds-3c9472b4.js} +2 -2
- package/cjs/compareIds-3c9472b4.js.map +1 -0
- package/cjs/{const-97ad0ae2.js → const-7b049118.js} +1 -1
- package/cjs/{const-97ad0ae2.js.map → const-7b049118.js.map} +1 -1
- package/cjs/{const-bba9510b.js → const-7d011d30.js} +1 -1
- package/cjs/{const-bba9510b.js.map → const-7d011d30.js.map} +1 -1
- package/cjs/{consts-6acebb51.js → consts-6cf0ec85.js} +1 -1
- package/cjs/{consts-6acebb51.js.map → consts-6cf0ec85.js.map} +1 -1
- package/cjs/{consts-cafff484.js → consts-9cbf147c.js} +1 -1
- package/cjs/{consts-cafff484.js.map → consts-9cbf147c.js.map} +1 -1
- package/cjs/{consts-a235ce0a.js → consts-d9ff7fec.js} +1 -1
- package/cjs/{consts-a235ce0a.js.map → consts-d9ff7fec.js.map} +1 -1
- package/cjs/{consts-cb169c09.js → consts-df222988.js} +1 -1
- package/cjs/{consts-cb169c09.js.map → consts-df222988.js.map} +1 -1
- package/cjs/{context-e6181d31.js → context-1d31dbec.js} +2 -2
- package/cjs/{context-e6181d31.js.map → context-1d31dbec.js.map} +1 -1
- package/cjs/dist/index.css +164 -163
- package/cjs/dist/index.css.map +1 -1
- package/cjs/{index-df637378.js → index-0b24e87b.js} +5 -5
- package/cjs/index-0b24e87b.js.map +1 -0
- package/cjs/{index-0514e373.js → index-0d2fba98.js} +7 -6
- package/cjs/index-0d2fba98.js.map +1 -0
- package/cjs/{index-43612435.js → index-1a324d07.js} +4 -4
- package/cjs/{index-43612435.js.map → index-1a324d07.js.map} +1 -1
- package/cjs/{index-34cc612a.js → index-263d9317.js} +5 -4
- package/cjs/index-263d9317.js.map +1 -0
- package/cjs/{index-d2bd7dc5.js → index-334b239a.js} +2 -2
- package/cjs/index-334b239a.js.map +1 -0
- package/cjs/{index-2a770f35.js → index-46b412dc.js} +37 -7
- package/cjs/index-46b412dc.js.map +1 -0
- package/cjs/{index-9f6f371b.js → index-50655872.js} +6 -6
- package/cjs/index-50655872.js.map +1 -0
- package/cjs/{index-4de6caed.js → index-551be60f.js} +16 -8
- package/cjs/index-551be60f.js.map +1 -0
- package/cjs/{index-986b886d.js → index-7ffe6f27.js} +12 -3
- package/cjs/index-7ffe6f27.js.map +1 -0
- package/cjs/{index-223d453c.js → index-8d2c0bda.js} +4 -2
- package/cjs/index-8d2c0bda.js.map +1 -0
- package/cjs/{index-b2886b93.js → index-8fc4c8ed.js} +12 -12
- package/cjs/index-8fc4c8ed.js.map +1 -0
- package/cjs/{index-ca85a10a.js → index-9dd778ed.js} +193 -56
- package/cjs/index-9dd778ed.js.map +1 -0
- package/cjs/{index-80b17a7f.js → index-bb91f996.js} +2 -2
- package/cjs/{index-80b17a7f.js.map → index-bb91f996.js.map} +1 -1
- package/cjs/{index-5fd03280.js → index-e36db682.js} +1 -1
- package/cjs/index-e36db682.js.map +1 -0
- package/cjs/{index-6d3fe482.js → index-f0938824.js} +30 -10
- package/cjs/index-f0938824.js.map +1 -0
- package/cjs/{index-2c8ca1d6.js → index-f4cf9eb5.js} +3 -3
- package/cjs/{index-2c8ca1d6.js.map → index-f4cf9eb5.js.map} +1 -1
- package/cjs/index.js +49 -49
- package/cjs/{index.module-f4ff21b1.js → index.module-2d344ee2.js} +1 -1
- package/cjs/{index.module-f4ff21b1.js.map → index.module-2d344ee2.js.map} +1 -1
- package/cjs/lame.all.js.map +1 -1
- package/cjs/sendbirdSelectors.js +3 -3
- package/cjs/sendbirdSelectors.js.map +1 -1
- package/cjs/{stringSet-2b481a03.js → stringSet-ac04b7c1.js} +1 -1
- package/cjs/{stringSet-2b481a03.js.map → stringSet-ac04b7c1.js.map} +1 -1
- package/cjs/{tokenize-07747f4c.js → tokenize-10b9c2ca.js} +27 -7
- package/cjs/tokenize-10b9c2ca.js.map +1 -0
- package/cjs/{topics-f9cf559a.js → topics-89c25bd7.js} +1 -1
- package/cjs/{topics-f9cf559a.js.map → topics-89c25bd7.js.map} +1 -1
- package/cjs/{types-3dcd9651.js → types-53455550.js} +1 -1
- package/cjs/types-53455550.js.map +1 -0
- package/cjs/ui/Accordion.js +2 -2
- package/cjs/ui/Accordion.js.map +1 -1
- package/cjs/ui/AccordionGroup.js +2 -2
- package/cjs/ui/AccordionGroup.js.map +1 -1
- package/cjs/ui/AdminMessage.js +2 -2
- package/cjs/ui/AdminMessage.js.map +1 -1
- package/cjs/ui/Avatar.js +1 -1
- package/cjs/ui/Avatar.js.map +1 -1
- package/cjs/ui/Badge.js +4 -4
- package/cjs/ui/Badge.js.map +1 -1
- package/cjs/ui/BottomSheet.js +1 -1
- package/cjs/ui/BottomSheet.js.map +1 -1
- package/cjs/ui/Button.js +2 -2
- package/cjs/ui/Button.js.map +1 -1
- package/cjs/ui/ChannelAvatar.js +2 -2
- package/cjs/ui/ChannelAvatar.js.map +1 -1
- package/cjs/ui/Checkbox.js.map +1 -1
- package/cjs/ui/ConnectionStatus.js +4 -4
- package/cjs/ui/ConnectionStatus.js.map +1 -1
- package/cjs/ui/ContextMenu.js +5 -5
- package/cjs/ui/ContextMenu.js.map +1 -1
- package/cjs/ui/DateSeparator.js +3 -3
- package/cjs/ui/DateSeparator.js.map +1 -1
- package/cjs/ui/EmojiReactions.js +7 -7
- package/cjs/ui/EmojiReactions.js.map +1 -1
- package/cjs/ui/FileMessageItemBody.js +6 -6
- package/cjs/ui/FileMessageItemBody.js.map +1 -1
- package/cjs/ui/FileViewer.js +8 -8
- package/cjs/ui/FileViewer.js.map +1 -1
- package/cjs/ui/Icon.js +2 -0
- package/cjs/ui/Icon.js.map +1 -1
- package/cjs/ui/IconButton.js +1 -1
- package/cjs/ui/IconButton.js.map +1 -1
- package/cjs/ui/ImageRenderer.js.map +1 -1
- package/cjs/ui/Input.js +2 -2
- package/cjs/ui/Input.js.map +1 -1
- package/cjs/ui/Label.js +2 -2
- package/cjs/ui/LinkLabel.js +2 -2
- package/cjs/ui/LinkLabel.js.map +1 -1
- package/cjs/ui/Loader.js.map +1 -1
- package/cjs/ui/MentionLabel.js +10 -10
- package/cjs/ui/MentionLabel.js.map +1 -1
- package/cjs/ui/MentionUserLabel.js +1 -1
- package/cjs/ui/MentionUserLabel.js.map +1 -1
- package/cjs/ui/MessageContent.js +34 -34
- package/cjs/ui/MessageContent.js.map +1 -1
- package/cjs/ui/MessageInput.js +63 -37
- package/cjs/ui/MessageInput.js.map +1 -1
- package/cjs/ui/MessageItemMenu.js +8 -8
- package/cjs/ui/MessageItemMenu.js.map +1 -1
- package/cjs/ui/MessageItemReactionMenu.js +5 -5
- package/cjs/ui/MessageItemReactionMenu.js.map +1 -1
- package/cjs/ui/MessageSearchFileItem.js +10 -10
- package/cjs/ui/MessageSearchFileItem.js.map +1 -1
- package/cjs/ui/MessageSearchItem.js +8 -8
- package/cjs/ui/MessageSearchItem.js.map +1 -1
- package/cjs/ui/MessageStatus.js +10 -10
- package/cjs/ui/Modal.js +7 -7
- package/cjs/ui/Modal.js.map +1 -1
- package/cjs/ui/MutedAvatarOverlay.js.map +1 -1
- package/cjs/ui/OGMessageItemBody.js +14 -14
- package/cjs/ui/OGMessageItemBody.js.map +1 -1
- package/cjs/ui/OpenChannelAdminMessage.js +2 -2
- package/cjs/ui/OpenChannelAdminMessage.js.map +1 -1
- package/cjs/ui/OpenChannelAvatar.js +5 -5
- package/cjs/ui/OpenChannelAvatar.js.map +1 -1
- package/cjs/ui/OpenchannelConversationHeader.js +6 -6
- package/cjs/ui/OpenchannelConversationHeader.js.map +1 -1
- package/cjs/ui/OpenchannelFileMessage.js +15 -15
- package/cjs/ui/OpenchannelFileMessage.js.map +1 -1
- package/cjs/ui/OpenchannelOGMessage.js +18 -18
- package/cjs/ui/OpenchannelOGMessage.js.map +1 -1
- package/cjs/ui/OpenchannelThumbnailMessage.js +16 -16
- package/cjs/ui/OpenchannelThumbnailMessage.js.map +1 -1
- package/cjs/ui/OpenchannelUserMessage.js +15 -15
- package/cjs/ui/OpenchannelUserMessage.js.map +1 -1
- package/cjs/ui/PlaceHolder.js +5 -5
- package/cjs/ui/PlaybackTime.js +2 -2
- package/cjs/ui/PlaybackTime.js.map +1 -1
- package/cjs/ui/ProgressBar.js +1 -0
- package/cjs/ui/ProgressBar.js.map +1 -1
- package/cjs/ui/QuoteMessage.js +6 -6
- package/cjs/ui/QuoteMessage.js.map +1 -1
- package/cjs/ui/QuoteMessageInput.js +6 -6
- package/cjs/ui/QuoteMessageInput.js.map +1 -1
- package/cjs/ui/ReactionBadge.js +2 -2
- package/cjs/ui/ReactionBadge.js.map +1 -1
- package/cjs/ui/ReactionButton.js.map +1 -1
- package/cjs/ui/SortByRow.js +1 -1
- package/cjs/ui/SortByRow.js.map +1 -1
- package/cjs/ui/TextButton.js +1 -1
- package/cjs/ui/TextButton.js.map +1 -1
- package/cjs/ui/TextMessageItemBody.js +15 -15
- package/cjs/ui/TextMessageItemBody.js.map +1 -1
- package/cjs/ui/ThreadReplies.js +5 -5
- package/cjs/ui/ThreadReplies.js.map +1 -1
- package/cjs/ui/ThumbnailMessageItemBody.js +2 -2
- package/cjs/ui/ThumbnailMessageItemBody.js.map +1 -1
- package/cjs/ui/Toggle.js +1 -1
- package/cjs/ui/Toggle.js.map +1 -1
- package/cjs/ui/Tooltip.js +2 -2
- package/cjs/ui/Tooltip.js.map +1 -1
- package/cjs/ui/TooltipWrapper.js.map +1 -1
- package/cjs/ui/UnknownMessageItemBody.js +6 -6
- package/cjs/ui/UnknownMessageItemBody.js.map +1 -1
- package/cjs/ui/UserListItem.js +10 -10
- package/cjs/ui/UserListItem.js.map +1 -1
- package/cjs/ui/UserProfile.js +9 -9
- package/cjs/ui/UserProfile.js.map +1 -1
- package/cjs/ui/VoiceMessageItemBody.js +9 -9
- package/cjs/ui/VoiceMessageItemBody.js.map +1 -1
- package/cjs/ui/VoiceMessgeInput.js +7 -7
- package/cjs/ui/Word.js +13 -13
- package/cjs/ui/Word.js.map +1 -1
- package/cjs/{useLongPress-ab63a990.js → useLongPress-472493f7.js} +3 -3
- package/cjs/useLongPress-472493f7.js.map +1 -0
- package/cjs/useSendbirdStateContext.js +1 -1
- package/cjs/utils/message/getOutgoingMessageState.js.map +1 -1
- package/cjs/utils/message/isVoiceMessage.js +2 -2
- package/cjs/{utils-1fd1fe8c.js → utils-40b8c201.js} +1 -1
- package/cjs/utils-40b8c201.js.map +1 -0
- package/cjs/{utils-7e52a10a.js → utils-76562fb5.js} +2 -2
- package/cjs/{utils-7e52a10a.js.map → utils-76562fb5.js.map} +1 -1
- package/cjs/{utils-f6f55335.js → utils-eadc245c.js} +1 -1
- package/cjs/{utils-f6f55335.js.map → utils-eadc245c.js.map} +1 -1
- package/cjs/{utils-f6c4e216.js → utils-fdce7855.js} +1 -1
- package/cjs/{utils-f6c4e216.js.map → utils-fdce7855.js.map} +1 -1
- package/cjs/{uuid-d0dd45eb.js → uuid-d5eb7040.js} +1 -1
- package/cjs/{uuid-d0dd45eb.js.map → uuid-d5eb7040.js.map} +1 -1
- package/cjs/withSendbird.js +1 -1
- package/cjs/withSendbird.js.map +1 -1
- package/{color-c30f00bf.js → color-d6b38e25.js} +1 -1
- package/{color-c30f00bf.js.map → color-d6b38e25.js.map} +1 -1
- package/{compareIds-90440dc5.js → compareIds-f38c2ef0.js} +2 -2
- package/compareIds-f38c2ef0.js.map +1 -0
- package/{const-5e916a50.js → const-051188d1.js} +1 -1
- package/{const-5e916a50.js.map → const-051188d1.js.map} +1 -1
- package/{const-582ca435.js → const-f6d56818.js} +1 -1
- package/{const-582ca435.js.map → const-f6d56818.js.map} +1 -1
- package/{consts-ee90b622.js → consts-04eece0c.js} +1 -1
- package/{consts-ee90b622.js.map → consts-04eece0c.js.map} +1 -1
- package/{consts-6e63357c.js → consts-a6286ca6.js} +1 -1
- package/{consts-6e63357c.js.map → consts-a6286ca6.js.map} +1 -1
- package/{consts-35dda142.js → consts-da8a20c9.js} +1 -1
- package/{consts-35dda142.js.map → consts-da8a20c9.js.map} +1 -1
- package/{consts-a7fe5f4a.js → consts-dd1513d3.js} +1 -1
- package/{consts-a7fe5f4a.js.map → consts-dd1513d3.js.map} +1 -1
- package/{context-8a77d287.js → context-0e43d2e6.js} +2 -2
- package/{context-8a77d287.js.map → context-0e43d2e6.js.map} +1 -1
- package/dist/index.css +164 -163
- package/dist/index.css.map +1 -1
- package/{index-2bcc4298.js → index-01ac0ba4.js} +7 -6
- package/index-01ac0ba4.js.map +1 -0
- package/{index-8f5c7f74.js → index-0533e5e9.js} +2 -2
- package/index-0533e5e9.js.map +1 -0
- package/{index-1e1cb669.js → index-06784b87.js} +1 -1
- package/index-06784b87.js.map +1 -0
- package/{index-8e3a9e8c.js → index-2857db82.js} +12 -12
- package/index-2857db82.js.map +1 -0
- package/{index-062a4eeb.js → index-3f4521c1.js} +2 -2
- package/{index-062a4eeb.js.map → index-3f4521c1.js.map} +1 -1
- package/{index-4d66cb77.js → index-46f6d854.js} +38 -8
- package/index-46f6d854.js.map +1 -0
- package/{index-303eca35.js → index-5807e969.js} +16 -8
- package/index-5807e969.js.map +1 -0
- package/{index-c50c6fa2.js → index-63631dc4.js} +5 -4
- package/index-63631dc4.js.map +1 -0
- package/{index-052724d9.js → index-64473ea3.js} +12 -3
- package/index-64473ea3.js.map +1 -0
- package/{index-4668028f.js → index-74a99dc5.js} +4 -2
- package/index-74a99dc5.js.map +1 -0
- package/{index-eebbce1c.js → index-7f172012.js} +5 -5
- package/index-7f172012.js.map +1 -0
- package/{index-794e37e5.js → index-82009149.js} +30 -10
- package/index-82009149.js.map +1 -0
- package/{index-8fea9d09.js → index-8abe5fb2.js} +3 -3
- package/{index-8fea9d09.js.map → index-8abe5fb2.js.map} +1 -1
- package/{index-365a1d88.js → index-f23e2550.js} +4 -4
- package/{index-365a1d88.js.map → index-f23e2550.js.map} +1 -1
- package/{index-0cc2c241.js → index-f78cd01e.js} +6 -6
- package/index-f78cd01e.js.map +1 -0
- package/{index-6908bdd4.js → index-feffd01d.js} +193 -56
- package/index-feffd01d.js.map +1 -0
- package/index.d.ts +15 -5
- package/index.js +49 -49
- package/{index.module-3d14ef05.js → index.module-6a96cbff.js} +1 -1
- package/{index.module-3d14ef05.js.map → index.module-6a96cbff.js.map} +1 -1
- package/lame.all.js.map +1 -1
- package/package.json +15 -13
- package/sendbirdSelectors.js +3 -3
- package/sendbirdSelectors.js.map +1 -1
- package/{stringSet-da68ecef.js → stringSet-6c589018.js} +1 -1
- package/{stringSet-da68ecef.js.map → stringSet-6c589018.js.map} +1 -1
- package/{tokenize-eeb42e72.js → tokenize-b7be6252.js} +27 -7
- package/tokenize-b7be6252.js.map +1 -0
- package/{topics-0354b385.js → topics-969deff5.js} +1 -1
- package/{topics-0354b385.js.map → topics-969deff5.js.map} +1 -1
- package/{types-12d853e9.js → types-230dc5c2.js} +1 -1
- package/types-230dc5c2.js.map +1 -0
- package/ui/Accordion.js +2 -2
- package/ui/Accordion.js.map +1 -1
- package/ui/AccordionGroup.js +2 -2
- package/ui/AccordionGroup.js.map +1 -1
- package/ui/AdminMessage.js +2 -2
- package/ui/AdminMessage.js.map +1 -1
- package/ui/Avatar.js +1 -1
- package/ui/Avatar.js.map +1 -1
- package/ui/Badge.js +4 -4
- package/ui/Badge.js.map +1 -1
- package/ui/BottomSheet.js +1 -1
- package/ui/BottomSheet.js.map +1 -1
- package/ui/Button.js +2 -2
- package/ui/Button.js.map +1 -1
- package/ui/ChannelAvatar.js +2 -2
- package/ui/ChannelAvatar.js.map +1 -1
- package/ui/Checkbox.js.map +1 -1
- package/ui/ConnectionStatus.js +4 -4
- package/ui/ConnectionStatus.js.map +1 -1
- package/ui/ContextMenu.js +5 -5
- package/ui/ContextMenu.js.map +1 -1
- package/ui/DateSeparator.js +3 -3
- package/ui/DateSeparator.js.map +1 -1
- package/ui/EmojiReactions.js +7 -7
- package/ui/EmojiReactions.js.map +1 -1
- package/ui/FileMessageItemBody.js +6 -6
- package/ui/FileMessageItemBody.js.map +1 -1
- package/ui/FileViewer.js +8 -8
- package/ui/FileViewer.js.map +1 -1
- package/ui/Icon.js +2 -0
- package/ui/Icon.js.map +1 -1
- package/ui/IconButton.js +1 -1
- package/ui/IconButton.js.map +1 -1
- package/ui/ImageRenderer.js.map +1 -1
- package/ui/Input.js +2 -2
- package/ui/Input.js.map +1 -1
- package/ui/Label.js +2 -2
- package/ui/LinkLabel.js +2 -2
- package/ui/LinkLabel.js.map +1 -1
- package/ui/Loader.js.map +1 -1
- package/ui/MentionLabel.js +10 -10
- package/ui/MentionLabel.js.map +1 -1
- package/ui/MentionUserLabel.js +1 -1
- package/ui/MentionUserLabel.js.map +1 -1
- package/ui/MessageContent.js +34 -34
- package/ui/MessageContent.js.map +1 -1
- package/ui/MessageInput.js +63 -37
- package/ui/MessageInput.js.map +1 -1
- package/ui/MessageItemMenu.js +8 -8
- package/ui/MessageItemMenu.js.map +1 -1
- package/ui/MessageItemReactionMenu.js +5 -5
- package/ui/MessageItemReactionMenu.js.map +1 -1
- package/ui/MessageSearchFileItem.js +10 -10
- package/ui/MessageSearchFileItem.js.map +1 -1
- package/ui/MessageSearchItem.js +8 -8
- package/ui/MessageSearchItem.js.map +1 -1
- package/ui/MessageStatus.js +10 -10
- package/ui/Modal.js +7 -7
- package/ui/Modal.js.map +1 -1
- package/ui/MutedAvatarOverlay.js.map +1 -1
- package/ui/OGMessageItemBody.js +14 -14
- package/ui/OGMessageItemBody.js.map +1 -1
- package/ui/OpenChannelAdminMessage.js +2 -2
- package/ui/OpenChannelAdminMessage.js.map +1 -1
- package/ui/OpenChannelAvatar.js +5 -5
- package/ui/OpenChannelAvatar.js.map +1 -1
- package/ui/OpenchannelConversationHeader.js +6 -6
- package/ui/OpenchannelConversationHeader.js.map +1 -1
- package/ui/OpenchannelFileMessage.js +15 -15
- package/ui/OpenchannelFileMessage.js.map +1 -1
- package/ui/OpenchannelOGMessage.js +18 -18
- package/ui/OpenchannelOGMessage.js.map +1 -1
- package/ui/OpenchannelThumbnailMessage.js +16 -16
- package/ui/OpenchannelThumbnailMessage.js.map +1 -1
- package/ui/OpenchannelUserMessage.js +15 -15
- package/ui/OpenchannelUserMessage.js.map +1 -1
- package/ui/PlaceHolder.js +5 -5
- package/ui/PlaybackTime.js +2 -2
- package/ui/PlaybackTime.js.map +1 -1
- package/ui/ProgressBar.js +1 -0
- package/ui/ProgressBar.js.map +1 -1
- package/ui/QuoteMessage.js +6 -6
- package/ui/QuoteMessage.js.map +1 -1
- package/ui/QuoteMessageInput.js +6 -6
- package/ui/QuoteMessageInput.js.map +1 -1
- package/ui/ReactionBadge.js +2 -2
- package/ui/ReactionBadge.js.map +1 -1
- package/ui/ReactionButton.js.map +1 -1
- package/ui/SortByRow.js +1 -1
- package/ui/SortByRow.js.map +1 -1
- package/ui/TextButton.js +1 -1
- package/ui/TextButton.js.map +1 -1
- package/ui/TextMessageItemBody.js +15 -15
- package/ui/TextMessageItemBody.js.map +1 -1
- package/ui/ThreadReplies.js +5 -5
- package/ui/ThreadReplies.js.map +1 -1
- package/ui/ThumbnailMessageItemBody.js +2 -2
- package/ui/ThumbnailMessageItemBody.js.map +1 -1
- package/ui/Toggle.js +1 -1
- package/ui/Toggle.js.map +1 -1
- package/ui/Tooltip.js +2 -2
- package/ui/Tooltip.js.map +1 -1
- package/ui/TooltipWrapper.js.map +1 -1
- package/ui/UnknownMessageItemBody.js +6 -6
- package/ui/UnknownMessageItemBody.js.map +1 -1
- package/ui/UserListItem.js +10 -10
- package/ui/UserListItem.js.map +1 -1
- package/ui/UserProfile.js +9 -9
- package/ui/UserProfile.js.map +1 -1
- package/ui/VoiceMessageItemBody.js +9 -9
- package/ui/VoiceMessageItemBody.js.map +1 -1
- package/ui/VoiceMessgeInput.js +7 -7
- package/ui/Word.js +13 -13
- package/ui/Word.js.map +1 -1
- package/{useLongPress-a8d92cab.js → useLongPress-b678c2b7.js} +3 -3
- package/useLongPress-b678c2b7.js.map +1 -0
- package/useSendbirdStateContext.js +1 -1
- package/utils/message/getOutgoingMessageState.js.map +1 -1
- package/utils/message/isVoiceMessage.js +2 -2
- package/{utils-670974e1.js → utils-3245985d.js} +1 -1
- package/utils-3245985d.js.map +1 -0
- package/{utils-63790b1a.js → utils-c29e587a.js} +2 -2
- package/{utils-63790b1a.js.map → utils-c29e587a.js.map} +1 -1
- package/{utils-c9c2364c.js → utils-d8dfc953.js} +1 -1
- package/{utils-c9c2364c.js.map → utils-d8dfc953.js.map} +1 -1
- package/{utils-2b05a56b.js → utils-f57a5756.js} +1 -1
- package/{utils-2b05a56b.js.map → utils-f57a5756.js.map} +1 -1
- package/{uuid-5c7f30bd.js → uuid-abddae2d.js} +1 -1
- package/{uuid-5c7f30bd.js.map → uuid-abddae2d.js.map} +1 -1
- package/withSendbird.js +1 -1
- package/withSendbird.js.map +1 -1
- package/ChannelListProvider-8be91a05.js.map +0 -1
- package/ChannelProvider-d643e6d9.js.map +0 -1
- package/MediaQueryContext-4e555ef5.js.map +0 -1
- package/MemberList-24b818f8.js.map +0 -1
- package/OpenChannelProvider-5148963b.js.map +0 -1
- package/ThreadProvider-96a5e77e.js.map +0 -1
- package/VoiceMessageInputWrapper-07631f8d.js.map +0 -1
- package/_rollupPluginBabelHelpers-5d0c716a.js.map +0 -1
- package/cjs/ChannelListProvider-6b61a484.js.map +0 -1
- package/cjs/ChannelProvider-12a12f31.js.map +0 -1
- package/cjs/MediaQueryContext-3b09499c.js.map +0 -1
- package/cjs/MemberList-f0c4e234.js.map +0 -1
- package/cjs/OpenChannelProvider-56846c0c.js.map +0 -1
- package/cjs/ThreadProvider-1ebd5bc0.js.map +0 -1
- package/cjs/VoiceMessageInputWrapper-044427b2.js.map +0 -1
- package/cjs/_rollupPluginBabelHelpers-4b6406c2.js.map +0 -1
- package/cjs/compareIds-de8d3b96.js.map +0 -1
- package/cjs/index-0514e373.js.map +0 -1
- package/cjs/index-223d453c.js.map +0 -1
- package/cjs/index-2a770f35.js.map +0 -1
- package/cjs/index-34cc612a.js.map +0 -1
- package/cjs/index-4de6caed.js.map +0 -1
- package/cjs/index-5fd03280.js.map +0 -1
- package/cjs/index-6d3fe482.js.map +0 -1
- package/cjs/index-986b886d.js.map +0 -1
- package/cjs/index-9f6f371b.js.map +0 -1
- package/cjs/index-b2886b93.js.map +0 -1
- package/cjs/index-ca85a10a.js.map +0 -1
- package/cjs/index-d2bd7dc5.js.map +0 -1
- package/cjs/index-df637378.js.map +0 -1
- package/cjs/tokenize-07747f4c.js.map +0 -1
- package/cjs/types-3dcd9651.js.map +0 -1
- package/cjs/useLongPress-ab63a990.js.map +0 -1
- package/cjs/utils-1fd1fe8c.js.map +0 -1
- package/compareIds-90440dc5.js.map +0 -1
- package/index-052724d9.js.map +0 -1
- package/index-0cc2c241.js.map +0 -1
- package/index-1e1cb669.js.map +0 -1
- package/index-2bcc4298.js.map +0 -1
- package/index-303eca35.js.map +0 -1
- package/index-4668028f.js.map +0 -1
- package/index-4d66cb77.js.map +0 -1
- package/index-6908bdd4.js.map +0 -1
- package/index-794e37e5.js.map +0 -1
- package/index-8e3a9e8c.js.map +0 -1
- package/index-8f5c7f74.js.map +0 -1
- package/index-c50c6fa2.js.map +0 -1
- package/index-eebbce1c.js.map +0 -1
- package/tokenize-eeb42e72.js.map +0 -1
- package/types-12d853e9.js.map +0 -1
- package/useLongPress-a8d92cab.js.map +0 -1
- package/utils-670974e1.js.map +0 -1
|
@@ -1,16 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var index = require('./index-
|
|
4
|
-
|
|
5
|
-
function _typeof(obj) {
|
|
6
|
-
"@babel/helpers - typeof";
|
|
7
|
-
|
|
8
|
-
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) {
|
|
9
|
-
return typeof obj;
|
|
10
|
-
} : function (obj) {
|
|
11
|
-
return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
12
|
-
}, _typeof(obj);
|
|
13
|
-
}
|
|
3
|
+
var index = require('./index-f0938824.js');
|
|
14
4
|
|
|
15
5
|
function requiredArgs(required, args) {
|
|
16
6
|
if (args.length < required) {
|
|
@@ -18,6 +8,7 @@ function requiredArgs(required, args) {
|
|
|
18
8
|
}
|
|
19
9
|
}
|
|
20
10
|
|
|
11
|
+
function _typeof$1(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof$1 = function _typeof(obj) { return typeof obj; }; } else { _typeof$1 = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof$1(obj); }
|
|
21
12
|
/**
|
|
22
13
|
* @name toDate
|
|
23
14
|
* @category Common Helpers
|
|
@@ -48,12 +39,12 @@ function requiredArgs(required, args) {
|
|
|
48
39
|
* const result = toDate(1392098430000)
|
|
49
40
|
* //=> Tue Feb 11 2014 11:30:30
|
|
50
41
|
*/
|
|
42
|
+
|
|
51
43
|
function toDate(argument) {
|
|
52
44
|
requiredArgs(1, arguments);
|
|
53
|
-
var argStr = Object.prototype.toString.call(argument);
|
|
45
|
+
var argStr = Object.prototype.toString.call(argument); // Clone the date
|
|
54
46
|
|
|
55
|
-
|
|
56
|
-
if (argument instanceof Date || _typeof(argument) === 'object' && argStr === '[object Date]') {
|
|
47
|
+
if (argument instanceof Date || _typeof$1(argument) === 'object' && argStr === '[object Date]') {
|
|
57
48
|
// Prevent the date to lose the milliseconds when passed to new Date() in IE10
|
|
58
49
|
return new Date(argument.getTime());
|
|
59
50
|
} else if (typeof argument === 'number' || argStr === '[object Number]') {
|
|
@@ -61,14 +52,16 @@ function toDate(argument) {
|
|
|
61
52
|
} else {
|
|
62
53
|
if ((typeof argument === 'string' || argStr === '[object String]') && typeof console !== 'undefined') {
|
|
63
54
|
// eslint-disable-next-line no-console
|
|
64
|
-
console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments");
|
|
65
|
-
|
|
55
|
+
console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"); // eslint-disable-next-line no-console
|
|
56
|
+
|
|
66
57
|
console.warn(new Error().stack);
|
|
67
58
|
}
|
|
59
|
+
|
|
68
60
|
return new Date(NaN);
|
|
69
61
|
}
|
|
70
62
|
}
|
|
71
63
|
|
|
64
|
+
function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); }
|
|
72
65
|
/**
|
|
73
66
|
* @name isDate
|
|
74
67
|
* @category Common Helpers
|
|
@@ -101,6 +94,7 @@ function toDate(argument) {
|
|
|
101
94
|
* const result = isDate({})
|
|
102
95
|
* //=> false
|
|
103
96
|
*/
|
|
97
|
+
|
|
104
98
|
function isDate(value) {
|
|
105
99
|
requiredArgs(1, arguments);
|
|
106
100
|
return value instanceof Date || _typeof(value) === 'object' && Object.prototype.toString.call(value) === '[object Date]';
|
|
@@ -137,11 +131,14 @@ function isDate(value) {
|
|
|
137
131
|
* const result = isValid(new Date(''))
|
|
138
132
|
* //=> false
|
|
139
133
|
*/
|
|
134
|
+
|
|
140
135
|
function isValid(dirtyDate) {
|
|
141
136
|
requiredArgs(1, arguments);
|
|
137
|
+
|
|
142
138
|
if (!isDate(dirtyDate) && typeof dirtyDate !== 'number') {
|
|
143
139
|
return false;
|
|
144
140
|
}
|
|
141
|
+
|
|
145
142
|
var date = toDate(dirtyDate);
|
|
146
143
|
return !isNaN(Number(date));
|
|
147
144
|
}
|
|
@@ -150,10 +147,13 @@ function toInteger(dirtyNumber) {
|
|
|
150
147
|
if (dirtyNumber === null || dirtyNumber === true || dirtyNumber === false) {
|
|
151
148
|
return NaN;
|
|
152
149
|
}
|
|
150
|
+
|
|
153
151
|
var number = Number(dirtyNumber);
|
|
152
|
+
|
|
154
153
|
if (isNaN(number)) {
|
|
155
154
|
return number;
|
|
156
155
|
}
|
|
156
|
+
|
|
157
157
|
return number < 0 ? Math.ceil(number) : Math.floor(number);
|
|
158
158
|
}
|
|
159
159
|
|
|
@@ -175,6 +175,7 @@ function toInteger(dirtyNumber) {
|
|
|
175
175
|
* const result = addMilliseconds(new Date(2014, 6, 10, 12, 45, 30, 0), 750)
|
|
176
176
|
* //=> Thu Jul 10 2014 12:45:30.750
|
|
177
177
|
*/
|
|
178
|
+
|
|
178
179
|
function addMilliseconds(dirtyDate, dirtyAmount) {
|
|
179
180
|
requiredArgs(2, arguments);
|
|
180
181
|
var timestamp = toDate(dirtyDate).getTime();
|
|
@@ -200,6 +201,7 @@ function addMilliseconds(dirtyDate, dirtyAmount) {
|
|
|
200
201
|
* const result = subMilliseconds(new Date(2014, 6, 10, 12, 45, 30, 0), 750)
|
|
201
202
|
* //=> Thu Jul 10 2014 12:45:29.250
|
|
202
203
|
*/
|
|
204
|
+
|
|
203
205
|
function subMilliseconds(dirtyDate, dirtyAmount) {
|
|
204
206
|
requiredArgs(2, arguments);
|
|
205
207
|
var amount = toInteger(dirtyAmount);
|
|
@@ -241,6 +243,7 @@ function getUTCISOWeekYear(dirtyDate) {
|
|
|
241
243
|
fourthOfJanuaryOfThisYear.setUTCFullYear(year, 0, 4);
|
|
242
244
|
fourthOfJanuaryOfThisYear.setUTCHours(0, 0, 0, 0);
|
|
243
245
|
var startOfThisYear = startOfUTCISOWeek(fourthOfJanuaryOfThisYear);
|
|
246
|
+
|
|
244
247
|
if (date.getTime() >= startOfNextYear.getTime()) {
|
|
245
248
|
return year + 1;
|
|
246
249
|
} else if (date.getTime() >= startOfThisYear.getTime()) {
|
|
@@ -264,11 +267,10 @@ var MILLISECONDS_IN_WEEK$1 = 604800000;
|
|
|
264
267
|
function getUTCISOWeek(dirtyDate) {
|
|
265
268
|
requiredArgs(1, arguments);
|
|
266
269
|
var date = toDate(dirtyDate);
|
|
267
|
-
var diff = startOfUTCISOWeek(date).getTime() - startOfUTCISOWeekYear(date).getTime();
|
|
268
|
-
|
|
269
|
-
// Round the number of days to the nearest integer
|
|
270
|
+
var diff = startOfUTCISOWeek(date).getTime() - startOfUTCISOWeekYear(date).getTime(); // Round the number of days to the nearest integer
|
|
270
271
|
// because the number of milliseconds in a week is not constant
|
|
271
272
|
// (e.g. it's different in the week of the daylight saving time clock shift)
|
|
273
|
+
|
|
272
274
|
return Math.round(diff / MILLISECONDS_IN_WEEK$1) + 1;
|
|
273
275
|
}
|
|
274
276
|
|
|
@@ -279,14 +281,15 @@ function getDefaultOptions() {
|
|
|
279
281
|
|
|
280
282
|
function startOfUTCWeek(dirtyDate, options) {
|
|
281
283
|
var _ref, _ref2, _ref3, _options$weekStartsOn, _options$locale, _options$locale$optio, _defaultOptions$local, _defaultOptions$local2;
|
|
284
|
+
|
|
282
285
|
requiredArgs(1, arguments);
|
|
283
286
|
var defaultOptions = getDefaultOptions();
|
|
284
|
-
var weekStartsOn = toInteger((_ref = (_ref2 = (_ref3 = (_options$weekStartsOn = options === null || options === void 0 ? void 0 : options.weekStartsOn) !== null && _options$weekStartsOn !== void 0 ? _options$weekStartsOn : options === null || options === void 0 ? void 0 : (_options$locale = options.locale) === null || _options$locale === void 0 ? void 0 : (_options$locale$optio = _options$locale.options) === null || _options$locale$optio === void 0 ? void 0 : _options$locale$optio.weekStartsOn) !== null && _ref3 !== void 0 ? _ref3 : defaultOptions.weekStartsOn) !== null && _ref2 !== void 0 ? _ref2 : (_defaultOptions$local = defaultOptions.locale) === null || _defaultOptions$local === void 0 ? void 0 : (_defaultOptions$local2 = _defaultOptions$local.options) === null || _defaultOptions$local2 === void 0 ? void 0 : _defaultOptions$local2.weekStartsOn) !== null && _ref !== void 0 ? _ref : 0);
|
|
287
|
+
var weekStartsOn = toInteger((_ref = (_ref2 = (_ref3 = (_options$weekStartsOn = options === null || options === void 0 ? void 0 : options.weekStartsOn) !== null && _options$weekStartsOn !== void 0 ? _options$weekStartsOn : options === null || options === void 0 ? void 0 : (_options$locale = options.locale) === null || _options$locale === void 0 ? void 0 : (_options$locale$optio = _options$locale.options) === null || _options$locale$optio === void 0 ? void 0 : _options$locale$optio.weekStartsOn) !== null && _ref3 !== void 0 ? _ref3 : defaultOptions.weekStartsOn) !== null && _ref2 !== void 0 ? _ref2 : (_defaultOptions$local = defaultOptions.locale) === null || _defaultOptions$local === void 0 ? void 0 : (_defaultOptions$local2 = _defaultOptions$local.options) === null || _defaultOptions$local2 === void 0 ? void 0 : _defaultOptions$local2.weekStartsOn) !== null && _ref !== void 0 ? _ref : 0); // Test if weekStartsOn is between 0 and 6 _and_ is not NaN
|
|
285
288
|
|
|
286
|
-
// Test if weekStartsOn is between 0 and 6 _and_ is not NaN
|
|
287
289
|
if (!(weekStartsOn >= 0 && weekStartsOn <= 6)) {
|
|
288
290
|
throw new RangeError('weekStartsOn must be between 0 and 6 inclusively');
|
|
289
291
|
}
|
|
292
|
+
|
|
290
293
|
var date = toDate(dirtyDate);
|
|
291
294
|
var day = date.getUTCDay();
|
|
292
295
|
var diff = (day < weekStartsOn ? 7 : 0) + day - weekStartsOn;
|
|
@@ -297,16 +300,17 @@ function startOfUTCWeek(dirtyDate, options) {
|
|
|
297
300
|
|
|
298
301
|
function getUTCWeekYear(dirtyDate, options) {
|
|
299
302
|
var _ref, _ref2, _ref3, _options$firstWeekCon, _options$locale, _options$locale$optio, _defaultOptions$local, _defaultOptions$local2;
|
|
303
|
+
|
|
300
304
|
requiredArgs(1, arguments);
|
|
301
305
|
var date = toDate(dirtyDate);
|
|
302
306
|
var year = date.getUTCFullYear();
|
|
303
307
|
var defaultOptions = getDefaultOptions();
|
|
304
|
-
var firstWeekContainsDate = toInteger((_ref = (_ref2 = (_ref3 = (_options$firstWeekCon = options === null || options === void 0 ? void 0 : options.firstWeekContainsDate) !== null && _options$firstWeekCon !== void 0 ? _options$firstWeekCon : options === null || options === void 0 ? void 0 : (_options$locale = options.locale) === null || _options$locale === void 0 ? void 0 : (_options$locale$optio = _options$locale.options) === null || _options$locale$optio === void 0 ? void 0 : _options$locale$optio.firstWeekContainsDate) !== null && _ref3 !== void 0 ? _ref3 : defaultOptions.firstWeekContainsDate) !== null && _ref2 !== void 0 ? _ref2 : (_defaultOptions$local = defaultOptions.locale) === null || _defaultOptions$local === void 0 ? void 0 : (_defaultOptions$local2 = _defaultOptions$local.options) === null || _defaultOptions$local2 === void 0 ? void 0 : _defaultOptions$local2.firstWeekContainsDate) !== null && _ref !== void 0 ? _ref : 1);
|
|
308
|
+
var firstWeekContainsDate = toInteger((_ref = (_ref2 = (_ref3 = (_options$firstWeekCon = options === null || options === void 0 ? void 0 : options.firstWeekContainsDate) !== null && _options$firstWeekCon !== void 0 ? _options$firstWeekCon : options === null || options === void 0 ? void 0 : (_options$locale = options.locale) === null || _options$locale === void 0 ? void 0 : (_options$locale$optio = _options$locale.options) === null || _options$locale$optio === void 0 ? void 0 : _options$locale$optio.firstWeekContainsDate) !== null && _ref3 !== void 0 ? _ref3 : defaultOptions.firstWeekContainsDate) !== null && _ref2 !== void 0 ? _ref2 : (_defaultOptions$local = defaultOptions.locale) === null || _defaultOptions$local === void 0 ? void 0 : (_defaultOptions$local2 = _defaultOptions$local.options) === null || _defaultOptions$local2 === void 0 ? void 0 : _defaultOptions$local2.firstWeekContainsDate) !== null && _ref !== void 0 ? _ref : 1); // Test if weekStartsOn is between 1 and 7 _and_ is not NaN
|
|
305
309
|
|
|
306
|
-
// Test if weekStartsOn is between 1 and 7 _and_ is not NaN
|
|
307
310
|
if (!(firstWeekContainsDate >= 1 && firstWeekContainsDate <= 7)) {
|
|
308
311
|
throw new RangeError('firstWeekContainsDate must be between 1 and 7 inclusively');
|
|
309
312
|
}
|
|
313
|
+
|
|
310
314
|
var firstWeekOfNextYear = new Date(0);
|
|
311
315
|
firstWeekOfNextYear.setUTCFullYear(year + 1, 0, firstWeekContainsDate);
|
|
312
316
|
firstWeekOfNextYear.setUTCHours(0, 0, 0, 0);
|
|
@@ -315,6 +319,7 @@ function getUTCWeekYear(dirtyDate, options) {
|
|
|
315
319
|
firstWeekOfThisYear.setUTCFullYear(year, 0, firstWeekContainsDate);
|
|
316
320
|
firstWeekOfThisYear.setUTCHours(0, 0, 0, 0);
|
|
317
321
|
var startOfThisYear = startOfUTCWeek(firstWeekOfThisYear, options);
|
|
322
|
+
|
|
318
323
|
if (date.getTime() >= startOfNextYear.getTime()) {
|
|
319
324
|
return year + 1;
|
|
320
325
|
} else if (date.getTime() >= startOfThisYear.getTime()) {
|
|
@@ -326,6 +331,7 @@ function getUTCWeekYear(dirtyDate, options) {
|
|
|
326
331
|
|
|
327
332
|
function startOfUTCWeekYear(dirtyDate, options) {
|
|
328
333
|
var _ref, _ref2, _ref3, _options$firstWeekCon, _options$locale, _options$locale$optio, _defaultOptions$local, _defaultOptions$local2;
|
|
334
|
+
|
|
329
335
|
requiredArgs(1, arguments);
|
|
330
336
|
var defaultOptions = getDefaultOptions();
|
|
331
337
|
var firstWeekContainsDate = toInteger((_ref = (_ref2 = (_ref3 = (_options$firstWeekCon = options === null || options === void 0 ? void 0 : options.firstWeekContainsDate) !== null && _options$firstWeekCon !== void 0 ? _options$firstWeekCon : options === null || options === void 0 ? void 0 : (_options$locale = options.locale) === null || _options$locale === void 0 ? void 0 : (_options$locale$optio = _options$locale.options) === null || _options$locale$optio === void 0 ? void 0 : _options$locale$optio.firstWeekContainsDate) !== null && _ref3 !== void 0 ? _ref3 : defaultOptions.firstWeekContainsDate) !== null && _ref2 !== void 0 ? _ref2 : (_defaultOptions$local = defaultOptions.locale) === null || _defaultOptions$local === void 0 ? void 0 : (_defaultOptions$local2 = _defaultOptions$local.options) === null || _defaultOptions$local2 === void 0 ? void 0 : _defaultOptions$local2.firstWeekContainsDate) !== null && _ref !== void 0 ? _ref : 1);
|
|
@@ -341,20 +347,21 @@ var MILLISECONDS_IN_WEEK = 604800000;
|
|
|
341
347
|
function getUTCWeek(dirtyDate, options) {
|
|
342
348
|
requiredArgs(1, arguments);
|
|
343
349
|
var date = toDate(dirtyDate);
|
|
344
|
-
var diff = startOfUTCWeek(date, options).getTime() - startOfUTCWeekYear(date, options).getTime();
|
|
345
|
-
|
|
346
|
-
// Round the number of days to the nearest integer
|
|
350
|
+
var diff = startOfUTCWeek(date, options).getTime() - startOfUTCWeekYear(date, options).getTime(); // Round the number of days to the nearest integer
|
|
347
351
|
// because the number of milliseconds in a week is not constant
|
|
348
352
|
// (e.g. it's different in the week of the daylight saving time clock shift)
|
|
353
|
+
|
|
349
354
|
return Math.round(diff / MILLISECONDS_IN_WEEK) + 1;
|
|
350
355
|
}
|
|
351
356
|
|
|
352
357
|
function addLeadingZeros(number, targetLength) {
|
|
353
358
|
var sign = number < 0 ? '-' : '';
|
|
354
359
|
var output = Math.abs(number).toString();
|
|
360
|
+
|
|
355
361
|
while (output.length < targetLength) {
|
|
356
362
|
output = '0' + output;
|
|
357
363
|
}
|
|
364
|
+
|
|
358
365
|
return sign + output;
|
|
359
366
|
}
|
|
360
367
|
|
|
@@ -370,6 +377,7 @@ function addLeadingZeros(number, targetLength) {
|
|
|
370
377
|
*
|
|
371
378
|
* Letters marked by * are not implemented but reserved by Unicode standard.
|
|
372
379
|
*/
|
|
380
|
+
|
|
373
381
|
var formatters$2 = {
|
|
374
382
|
// Year
|
|
375
383
|
y: function y(date, token) {
|
|
@@ -381,9 +389,8 @@ var formatters$2 = {
|
|
|
381
389
|
// | AD 123 | 123 | 23 | 123 | 0123 | 00123 |
|
|
382
390
|
// | AD 1234 | 1234 | 34 | 1234 | 1234 | 01234 |
|
|
383
391
|
// | AD 12345 | 12345 | 45 | 12345 | 12345 | 12345 |
|
|
392
|
+
var signedYear = date.getUTCFullYear(); // Returns 1 for 1 BC (which is year 0 in JavaScript)
|
|
384
393
|
|
|
385
|
-
var signedYear = date.getUTCFullYear();
|
|
386
|
-
// Returns 1 for 1 BC (which is year 0 in JavaScript)
|
|
387
394
|
var year = signedYear > 0 ? signedYear : 1 - signedYear;
|
|
388
395
|
return addLeadingZeros(token === 'yy' ? year % 100 : year, token.length);
|
|
389
396
|
},
|
|
@@ -399,14 +406,18 @@ var formatters$2 = {
|
|
|
399
406
|
// AM or PM
|
|
400
407
|
a: function a(date, token) {
|
|
401
408
|
var dayPeriodEnumValue = date.getUTCHours() / 12 >= 1 ? 'pm' : 'am';
|
|
409
|
+
|
|
402
410
|
switch (token) {
|
|
403
411
|
case 'a':
|
|
404
412
|
case 'aa':
|
|
405
413
|
return dayPeriodEnumValue.toUpperCase();
|
|
414
|
+
|
|
406
415
|
case 'aaa':
|
|
407
416
|
return dayPeriodEnumValue;
|
|
417
|
+
|
|
408
418
|
case 'aaaaa':
|
|
409
419
|
return dayPeriodEnumValue[0];
|
|
420
|
+
|
|
410
421
|
case 'aaaa':
|
|
411
422
|
default:
|
|
412
423
|
return dayPeriodEnumValue === 'am' ? 'a.m.' : 'p.m.';
|
|
@@ -447,6 +458,7 @@ var dayPeriodEnum = {
|
|
|
447
458
|
evening: 'evening',
|
|
448
459
|
night: 'night'
|
|
449
460
|
};
|
|
461
|
+
|
|
450
462
|
/*
|
|
451
463
|
* | | Unit | | Unit |
|
|
452
464
|
* |-----|--------------------------------|-----|--------------------------------|
|
|
@@ -492,11 +504,11 @@ var dayPeriodEnum = {
|
|
|
492
504
|
* - `P` is long localized date format
|
|
493
505
|
* - `p` is long localized time format
|
|
494
506
|
*/
|
|
495
|
-
|
|
496
507
|
var formatters = {
|
|
497
508
|
// Era
|
|
498
509
|
G: function G(date, token, localize) {
|
|
499
510
|
var era = date.getUTCFullYear() > 0 ? 1 : 0;
|
|
511
|
+
|
|
500
512
|
switch (token) {
|
|
501
513
|
// AD, BC
|
|
502
514
|
case 'G':
|
|
@@ -506,11 +518,13 @@ var formatters = {
|
|
|
506
518
|
width: 'abbreviated'
|
|
507
519
|
});
|
|
508
520
|
// A, B
|
|
521
|
+
|
|
509
522
|
case 'GGGGG':
|
|
510
523
|
return localize.era(era, {
|
|
511
524
|
width: 'narrow'
|
|
512
525
|
});
|
|
513
526
|
// Anno Domini, Before Christ
|
|
527
|
+
|
|
514
528
|
case 'GGGG':
|
|
515
529
|
default:
|
|
516
530
|
return localize.era(era, {
|
|
@@ -522,42 +536,41 @@ var formatters = {
|
|
|
522
536
|
y: function y(date, token, localize) {
|
|
523
537
|
// Ordinal number
|
|
524
538
|
if (token === 'yo') {
|
|
525
|
-
var signedYear = date.getUTCFullYear();
|
|
526
|
-
|
|
539
|
+
var signedYear = date.getUTCFullYear(); // Returns 1 for 1 BC (which is year 0 in JavaScript)
|
|
540
|
+
|
|
527
541
|
var year = signedYear > 0 ? signedYear : 1 - signedYear;
|
|
528
542
|
return localize.ordinalNumber(year, {
|
|
529
543
|
unit: 'year'
|
|
530
544
|
});
|
|
531
545
|
}
|
|
546
|
+
|
|
532
547
|
return formatters$2.y(date, token);
|
|
533
548
|
},
|
|
534
549
|
// Local week-numbering year
|
|
535
550
|
Y: function Y(date, token, localize, options) {
|
|
536
|
-
var signedWeekYear = getUTCWeekYear(date, options);
|
|
537
|
-
|
|
538
|
-
var weekYear = signedWeekYear > 0 ? signedWeekYear : 1 - signedWeekYear;
|
|
551
|
+
var signedWeekYear = getUTCWeekYear(date, options); // Returns 1 for 1 BC (which is year 0 in JavaScript)
|
|
552
|
+
|
|
553
|
+
var weekYear = signedWeekYear > 0 ? signedWeekYear : 1 - signedWeekYear; // Two digit year
|
|
539
554
|
|
|
540
|
-
// Two digit year
|
|
541
555
|
if (token === 'YY') {
|
|
542
556
|
var twoDigitYear = weekYear % 100;
|
|
543
557
|
return addLeadingZeros(twoDigitYear, 2);
|
|
544
|
-
}
|
|
558
|
+
} // Ordinal number
|
|
559
|
+
|
|
545
560
|
|
|
546
|
-
// Ordinal number
|
|
547
561
|
if (token === 'Yo') {
|
|
548
562
|
return localize.ordinalNumber(weekYear, {
|
|
549
563
|
unit: 'year'
|
|
550
564
|
});
|
|
551
|
-
}
|
|
565
|
+
} // Padding
|
|
566
|
+
|
|
552
567
|
|
|
553
|
-
// Padding
|
|
554
568
|
return addLeadingZeros(weekYear, token.length);
|
|
555
569
|
},
|
|
556
570
|
// ISO week-numbering year
|
|
557
571
|
R: function R(date, token) {
|
|
558
|
-
var isoWeekYear = getUTCISOWeekYear(date);
|
|
572
|
+
var isoWeekYear = getUTCISOWeekYear(date); // Padding
|
|
559
573
|
|
|
560
|
-
// Padding
|
|
561
574
|
return addLeadingZeros(isoWeekYear, token.length);
|
|
562
575
|
},
|
|
563
576
|
// Extended year. This is a single number designating the year of this calendar system.
|
|
@@ -576,31 +589,37 @@ var formatters = {
|
|
|
576
589
|
// Quarter
|
|
577
590
|
Q: function Q(date, token, localize) {
|
|
578
591
|
var quarter = Math.ceil((date.getUTCMonth() + 1) / 3);
|
|
592
|
+
|
|
579
593
|
switch (token) {
|
|
580
594
|
// 1, 2, 3, 4
|
|
581
595
|
case 'Q':
|
|
582
596
|
return String(quarter);
|
|
583
597
|
// 01, 02, 03, 04
|
|
598
|
+
|
|
584
599
|
case 'QQ':
|
|
585
600
|
return addLeadingZeros(quarter, 2);
|
|
586
601
|
// 1st, 2nd, 3rd, 4th
|
|
602
|
+
|
|
587
603
|
case 'Qo':
|
|
588
604
|
return localize.ordinalNumber(quarter, {
|
|
589
605
|
unit: 'quarter'
|
|
590
606
|
});
|
|
591
607
|
// Q1, Q2, Q3, Q4
|
|
608
|
+
|
|
592
609
|
case 'QQQ':
|
|
593
610
|
return localize.quarter(quarter, {
|
|
594
611
|
width: 'abbreviated',
|
|
595
612
|
context: 'formatting'
|
|
596
613
|
});
|
|
597
614
|
// 1, 2, 3, 4 (narrow quarter; could be not numerical)
|
|
615
|
+
|
|
598
616
|
case 'QQQQQ':
|
|
599
617
|
return localize.quarter(quarter, {
|
|
600
618
|
width: 'narrow',
|
|
601
619
|
context: 'formatting'
|
|
602
620
|
});
|
|
603
621
|
// 1st quarter, 2nd quarter, ...
|
|
622
|
+
|
|
604
623
|
case 'QQQQ':
|
|
605
624
|
default:
|
|
606
625
|
return localize.quarter(quarter, {
|
|
@@ -612,31 +631,37 @@ var formatters = {
|
|
|
612
631
|
// Stand-alone quarter
|
|
613
632
|
q: function q(date, token, localize) {
|
|
614
633
|
var quarter = Math.ceil((date.getUTCMonth() + 1) / 3);
|
|
634
|
+
|
|
615
635
|
switch (token) {
|
|
616
636
|
// 1, 2, 3, 4
|
|
617
637
|
case 'q':
|
|
618
638
|
return String(quarter);
|
|
619
639
|
// 01, 02, 03, 04
|
|
640
|
+
|
|
620
641
|
case 'qq':
|
|
621
642
|
return addLeadingZeros(quarter, 2);
|
|
622
643
|
// 1st, 2nd, 3rd, 4th
|
|
644
|
+
|
|
623
645
|
case 'qo':
|
|
624
646
|
return localize.ordinalNumber(quarter, {
|
|
625
647
|
unit: 'quarter'
|
|
626
648
|
});
|
|
627
649
|
// Q1, Q2, Q3, Q4
|
|
650
|
+
|
|
628
651
|
case 'qqq':
|
|
629
652
|
return localize.quarter(quarter, {
|
|
630
653
|
width: 'abbreviated',
|
|
631
654
|
context: 'standalone'
|
|
632
655
|
});
|
|
633
656
|
// 1, 2, 3, 4 (narrow quarter; could be not numerical)
|
|
657
|
+
|
|
634
658
|
case 'qqqqq':
|
|
635
659
|
return localize.quarter(quarter, {
|
|
636
660
|
width: 'narrow',
|
|
637
661
|
context: 'standalone'
|
|
638
662
|
});
|
|
639
663
|
// 1st quarter, 2nd quarter, ...
|
|
664
|
+
|
|
640
665
|
case 'qqqq':
|
|
641
666
|
default:
|
|
642
667
|
return localize.quarter(quarter, {
|
|
@@ -648,28 +673,33 @@ var formatters = {
|
|
|
648
673
|
// Month
|
|
649
674
|
M: function M(date, token, localize) {
|
|
650
675
|
var month = date.getUTCMonth();
|
|
676
|
+
|
|
651
677
|
switch (token) {
|
|
652
678
|
case 'M':
|
|
653
679
|
case 'MM':
|
|
654
680
|
return formatters$2.M(date, token);
|
|
655
681
|
// 1st, 2nd, ..., 12th
|
|
682
|
+
|
|
656
683
|
case 'Mo':
|
|
657
684
|
return localize.ordinalNumber(month + 1, {
|
|
658
685
|
unit: 'month'
|
|
659
686
|
});
|
|
660
687
|
// Jan, Feb, ..., Dec
|
|
688
|
+
|
|
661
689
|
case 'MMM':
|
|
662
690
|
return localize.month(month, {
|
|
663
691
|
width: 'abbreviated',
|
|
664
692
|
context: 'formatting'
|
|
665
693
|
});
|
|
666
694
|
// J, F, ..., D
|
|
695
|
+
|
|
667
696
|
case 'MMMMM':
|
|
668
697
|
return localize.month(month, {
|
|
669
698
|
width: 'narrow',
|
|
670
699
|
context: 'formatting'
|
|
671
700
|
});
|
|
672
701
|
// January, February, ..., December
|
|
702
|
+
|
|
673
703
|
case 'MMMM':
|
|
674
704
|
default:
|
|
675
705
|
return localize.month(month, {
|
|
@@ -681,31 +711,37 @@ var formatters = {
|
|
|
681
711
|
// Stand-alone month
|
|
682
712
|
L: function L(date, token, localize) {
|
|
683
713
|
var month = date.getUTCMonth();
|
|
714
|
+
|
|
684
715
|
switch (token) {
|
|
685
716
|
// 1, 2, ..., 12
|
|
686
717
|
case 'L':
|
|
687
718
|
return String(month + 1);
|
|
688
719
|
// 01, 02, ..., 12
|
|
720
|
+
|
|
689
721
|
case 'LL':
|
|
690
722
|
return addLeadingZeros(month + 1, 2);
|
|
691
723
|
// 1st, 2nd, ..., 12th
|
|
724
|
+
|
|
692
725
|
case 'Lo':
|
|
693
726
|
return localize.ordinalNumber(month + 1, {
|
|
694
727
|
unit: 'month'
|
|
695
728
|
});
|
|
696
729
|
// Jan, Feb, ..., Dec
|
|
730
|
+
|
|
697
731
|
case 'LLL':
|
|
698
732
|
return localize.month(month, {
|
|
699
733
|
width: 'abbreviated',
|
|
700
734
|
context: 'standalone'
|
|
701
735
|
});
|
|
702
736
|
// J, F, ..., D
|
|
737
|
+
|
|
703
738
|
case 'LLLLL':
|
|
704
739
|
return localize.month(month, {
|
|
705
740
|
width: 'narrow',
|
|
706
741
|
context: 'standalone'
|
|
707
742
|
});
|
|
708
743
|
// January, February, ..., December
|
|
744
|
+
|
|
709
745
|
case 'LLLL':
|
|
710
746
|
default:
|
|
711
747
|
return localize.month(month, {
|
|
@@ -717,21 +753,25 @@ var formatters = {
|
|
|
717
753
|
// Local week of year
|
|
718
754
|
w: function w(date, token, localize, options) {
|
|
719
755
|
var week = getUTCWeek(date, options);
|
|
756
|
+
|
|
720
757
|
if (token === 'wo') {
|
|
721
758
|
return localize.ordinalNumber(week, {
|
|
722
759
|
unit: 'week'
|
|
723
760
|
});
|
|
724
761
|
}
|
|
762
|
+
|
|
725
763
|
return addLeadingZeros(week, token.length);
|
|
726
764
|
},
|
|
727
765
|
// ISO week of year
|
|
728
766
|
I: function I(date, token, localize) {
|
|
729
767
|
var isoWeek = getUTCISOWeek(date);
|
|
768
|
+
|
|
730
769
|
if (token === 'Io') {
|
|
731
770
|
return localize.ordinalNumber(isoWeek, {
|
|
732
771
|
unit: 'week'
|
|
733
772
|
});
|
|
734
773
|
}
|
|
774
|
+
|
|
735
775
|
return addLeadingZeros(isoWeek, token.length);
|
|
736
776
|
},
|
|
737
777
|
// Day of the month
|
|
@@ -741,21 +781,25 @@ var formatters = {
|
|
|
741
781
|
unit: 'date'
|
|
742
782
|
});
|
|
743
783
|
}
|
|
784
|
+
|
|
744
785
|
return formatters$2.d(date, token);
|
|
745
786
|
},
|
|
746
787
|
// Day of year
|
|
747
788
|
D: function D(date, token, localize) {
|
|
748
789
|
var dayOfYear = getUTCDayOfYear(date);
|
|
790
|
+
|
|
749
791
|
if (token === 'Do') {
|
|
750
792
|
return localize.ordinalNumber(dayOfYear, {
|
|
751
793
|
unit: 'dayOfYear'
|
|
752
794
|
});
|
|
753
795
|
}
|
|
796
|
+
|
|
754
797
|
return addLeadingZeros(dayOfYear, token.length);
|
|
755
798
|
},
|
|
756
799
|
// Day of week
|
|
757
800
|
E: function E(date, token, localize) {
|
|
758
801
|
var dayOfWeek = date.getUTCDay();
|
|
802
|
+
|
|
759
803
|
switch (token) {
|
|
760
804
|
// Tue
|
|
761
805
|
case 'E':
|
|
@@ -766,18 +810,21 @@ var formatters = {
|
|
|
766
810
|
context: 'formatting'
|
|
767
811
|
});
|
|
768
812
|
// T
|
|
813
|
+
|
|
769
814
|
case 'EEEEE':
|
|
770
815
|
return localize.day(dayOfWeek, {
|
|
771
816
|
width: 'narrow',
|
|
772
817
|
context: 'formatting'
|
|
773
818
|
});
|
|
774
819
|
// Tu
|
|
820
|
+
|
|
775
821
|
case 'EEEEEE':
|
|
776
822
|
return localize.day(dayOfWeek, {
|
|
777
823
|
width: 'short',
|
|
778
824
|
context: 'formatting'
|
|
779
825
|
});
|
|
780
826
|
// Tuesday
|
|
827
|
+
|
|
781
828
|
case 'EEEE':
|
|
782
829
|
default:
|
|
783
830
|
return localize.day(dayOfWeek, {
|
|
@@ -790,36 +837,43 @@ var formatters = {
|
|
|
790
837
|
e: function e(date, token, localize, options) {
|
|
791
838
|
var dayOfWeek = date.getUTCDay();
|
|
792
839
|
var localDayOfWeek = (dayOfWeek - options.weekStartsOn + 8) % 7 || 7;
|
|
840
|
+
|
|
793
841
|
switch (token) {
|
|
794
842
|
// Numerical value (Nth day of week with current locale or weekStartsOn)
|
|
795
843
|
case 'e':
|
|
796
844
|
return String(localDayOfWeek);
|
|
797
845
|
// Padded numerical value
|
|
846
|
+
|
|
798
847
|
case 'ee':
|
|
799
848
|
return addLeadingZeros(localDayOfWeek, 2);
|
|
800
849
|
// 1st, 2nd, ..., 7th
|
|
850
|
+
|
|
801
851
|
case 'eo':
|
|
802
852
|
return localize.ordinalNumber(localDayOfWeek, {
|
|
803
853
|
unit: 'day'
|
|
804
854
|
});
|
|
855
|
+
|
|
805
856
|
case 'eee':
|
|
806
857
|
return localize.day(dayOfWeek, {
|
|
807
858
|
width: 'abbreviated',
|
|
808
859
|
context: 'formatting'
|
|
809
860
|
});
|
|
810
861
|
// T
|
|
862
|
+
|
|
811
863
|
case 'eeeee':
|
|
812
864
|
return localize.day(dayOfWeek, {
|
|
813
865
|
width: 'narrow',
|
|
814
866
|
context: 'formatting'
|
|
815
867
|
});
|
|
816
868
|
// Tu
|
|
869
|
+
|
|
817
870
|
case 'eeeeee':
|
|
818
871
|
return localize.day(dayOfWeek, {
|
|
819
872
|
width: 'short',
|
|
820
873
|
context: 'formatting'
|
|
821
874
|
});
|
|
822
875
|
// Tuesday
|
|
876
|
+
|
|
823
877
|
case 'eeee':
|
|
824
878
|
default:
|
|
825
879
|
return localize.day(dayOfWeek, {
|
|
@@ -832,36 +886,43 @@ var formatters = {
|
|
|
832
886
|
c: function c(date, token, localize, options) {
|
|
833
887
|
var dayOfWeek = date.getUTCDay();
|
|
834
888
|
var localDayOfWeek = (dayOfWeek - options.weekStartsOn + 8) % 7 || 7;
|
|
889
|
+
|
|
835
890
|
switch (token) {
|
|
836
891
|
// Numerical value (same as in `e`)
|
|
837
892
|
case 'c':
|
|
838
893
|
return String(localDayOfWeek);
|
|
839
894
|
// Padded numerical value
|
|
895
|
+
|
|
840
896
|
case 'cc':
|
|
841
897
|
return addLeadingZeros(localDayOfWeek, token.length);
|
|
842
898
|
// 1st, 2nd, ..., 7th
|
|
899
|
+
|
|
843
900
|
case 'co':
|
|
844
901
|
return localize.ordinalNumber(localDayOfWeek, {
|
|
845
902
|
unit: 'day'
|
|
846
903
|
});
|
|
904
|
+
|
|
847
905
|
case 'ccc':
|
|
848
906
|
return localize.day(dayOfWeek, {
|
|
849
907
|
width: 'abbreviated',
|
|
850
908
|
context: 'standalone'
|
|
851
909
|
});
|
|
852
910
|
// T
|
|
911
|
+
|
|
853
912
|
case 'ccccc':
|
|
854
913
|
return localize.day(dayOfWeek, {
|
|
855
914
|
width: 'narrow',
|
|
856
915
|
context: 'standalone'
|
|
857
916
|
});
|
|
858
917
|
// Tu
|
|
918
|
+
|
|
859
919
|
case 'cccccc':
|
|
860
920
|
return localize.day(dayOfWeek, {
|
|
861
921
|
width: 'short',
|
|
862
922
|
context: 'standalone'
|
|
863
923
|
});
|
|
864
924
|
// Tuesday
|
|
925
|
+
|
|
865
926
|
case 'cccc':
|
|
866
927
|
default:
|
|
867
928
|
return localize.day(dayOfWeek, {
|
|
@@ -874,37 +935,44 @@ var formatters = {
|
|
|
874
935
|
i: function i(date, token, localize) {
|
|
875
936
|
var dayOfWeek = date.getUTCDay();
|
|
876
937
|
var isoDayOfWeek = dayOfWeek === 0 ? 7 : dayOfWeek;
|
|
938
|
+
|
|
877
939
|
switch (token) {
|
|
878
940
|
// 2
|
|
879
941
|
case 'i':
|
|
880
942
|
return String(isoDayOfWeek);
|
|
881
943
|
// 02
|
|
944
|
+
|
|
882
945
|
case 'ii':
|
|
883
946
|
return addLeadingZeros(isoDayOfWeek, token.length);
|
|
884
947
|
// 2nd
|
|
948
|
+
|
|
885
949
|
case 'io':
|
|
886
950
|
return localize.ordinalNumber(isoDayOfWeek, {
|
|
887
951
|
unit: 'day'
|
|
888
952
|
});
|
|
889
953
|
// Tue
|
|
954
|
+
|
|
890
955
|
case 'iii':
|
|
891
956
|
return localize.day(dayOfWeek, {
|
|
892
957
|
width: 'abbreviated',
|
|
893
958
|
context: 'formatting'
|
|
894
959
|
});
|
|
895
960
|
// T
|
|
961
|
+
|
|
896
962
|
case 'iiiii':
|
|
897
963
|
return localize.day(dayOfWeek, {
|
|
898
964
|
width: 'narrow',
|
|
899
965
|
context: 'formatting'
|
|
900
966
|
});
|
|
901
967
|
// Tu
|
|
968
|
+
|
|
902
969
|
case 'iiiiii':
|
|
903
970
|
return localize.day(dayOfWeek, {
|
|
904
971
|
width: 'short',
|
|
905
972
|
context: 'formatting'
|
|
906
973
|
});
|
|
907
974
|
// Tuesday
|
|
975
|
+
|
|
908
976
|
case 'iiii':
|
|
909
977
|
default:
|
|
910
978
|
return localize.day(dayOfWeek, {
|
|
@@ -917,6 +985,7 @@ var formatters = {
|
|
|
917
985
|
a: function a(date, token, localize) {
|
|
918
986
|
var hours = date.getUTCHours();
|
|
919
987
|
var dayPeriodEnumValue = hours / 12 >= 1 ? 'pm' : 'am';
|
|
988
|
+
|
|
920
989
|
switch (token) {
|
|
921
990
|
case 'a':
|
|
922
991
|
case 'aa':
|
|
@@ -924,16 +993,19 @@ var formatters = {
|
|
|
924
993
|
width: 'abbreviated',
|
|
925
994
|
context: 'formatting'
|
|
926
995
|
});
|
|
996
|
+
|
|
927
997
|
case 'aaa':
|
|
928
998
|
return localize.dayPeriod(dayPeriodEnumValue, {
|
|
929
999
|
width: 'abbreviated',
|
|
930
1000
|
context: 'formatting'
|
|
931
1001
|
}).toLowerCase();
|
|
1002
|
+
|
|
932
1003
|
case 'aaaaa':
|
|
933
1004
|
return localize.dayPeriod(dayPeriodEnumValue, {
|
|
934
1005
|
width: 'narrow',
|
|
935
1006
|
context: 'formatting'
|
|
936
1007
|
});
|
|
1008
|
+
|
|
937
1009
|
case 'aaaa':
|
|
938
1010
|
default:
|
|
939
1011
|
return localize.dayPeriod(dayPeriodEnumValue, {
|
|
@@ -946,6 +1018,7 @@ var formatters = {
|
|
|
946
1018
|
b: function b(date, token, localize) {
|
|
947
1019
|
var hours = date.getUTCHours();
|
|
948
1020
|
var dayPeriodEnumValue;
|
|
1021
|
+
|
|
949
1022
|
if (hours === 12) {
|
|
950
1023
|
dayPeriodEnumValue = dayPeriodEnum.noon;
|
|
951
1024
|
} else if (hours === 0) {
|
|
@@ -953,6 +1026,7 @@ var formatters = {
|
|
|
953
1026
|
} else {
|
|
954
1027
|
dayPeriodEnumValue = hours / 12 >= 1 ? 'pm' : 'am';
|
|
955
1028
|
}
|
|
1029
|
+
|
|
956
1030
|
switch (token) {
|
|
957
1031
|
case 'b':
|
|
958
1032
|
case 'bb':
|
|
@@ -960,16 +1034,19 @@ var formatters = {
|
|
|
960
1034
|
width: 'abbreviated',
|
|
961
1035
|
context: 'formatting'
|
|
962
1036
|
});
|
|
1037
|
+
|
|
963
1038
|
case 'bbb':
|
|
964
1039
|
return localize.dayPeriod(dayPeriodEnumValue, {
|
|
965
1040
|
width: 'abbreviated',
|
|
966
1041
|
context: 'formatting'
|
|
967
1042
|
}).toLowerCase();
|
|
1043
|
+
|
|
968
1044
|
case 'bbbbb':
|
|
969
1045
|
return localize.dayPeriod(dayPeriodEnumValue, {
|
|
970
1046
|
width: 'narrow',
|
|
971
1047
|
context: 'formatting'
|
|
972
1048
|
});
|
|
1049
|
+
|
|
973
1050
|
case 'bbbb':
|
|
974
1051
|
default:
|
|
975
1052
|
return localize.dayPeriod(dayPeriodEnumValue, {
|
|
@@ -982,6 +1059,7 @@ var formatters = {
|
|
|
982
1059
|
B: function B(date, token, localize) {
|
|
983
1060
|
var hours = date.getUTCHours();
|
|
984
1061
|
var dayPeriodEnumValue;
|
|
1062
|
+
|
|
985
1063
|
if (hours >= 17) {
|
|
986
1064
|
dayPeriodEnumValue = dayPeriodEnum.evening;
|
|
987
1065
|
} else if (hours >= 12) {
|
|
@@ -991,6 +1069,7 @@ var formatters = {
|
|
|
991
1069
|
} else {
|
|
992
1070
|
dayPeriodEnumValue = dayPeriodEnum.night;
|
|
993
1071
|
}
|
|
1072
|
+
|
|
994
1073
|
switch (token) {
|
|
995
1074
|
case 'B':
|
|
996
1075
|
case 'BB':
|
|
@@ -999,11 +1078,13 @@ var formatters = {
|
|
|
999
1078
|
width: 'abbreviated',
|
|
1000
1079
|
context: 'formatting'
|
|
1001
1080
|
});
|
|
1081
|
+
|
|
1002
1082
|
case 'BBBBB':
|
|
1003
1083
|
return localize.dayPeriod(dayPeriodEnumValue, {
|
|
1004
1084
|
width: 'narrow',
|
|
1005
1085
|
context: 'formatting'
|
|
1006
1086
|
});
|
|
1087
|
+
|
|
1007
1088
|
case 'BBBB':
|
|
1008
1089
|
default:
|
|
1009
1090
|
return localize.dayPeriod(dayPeriodEnumValue, {
|
|
@@ -1021,6 +1102,7 @@ var formatters = {
|
|
|
1021
1102
|
unit: 'hour'
|
|
1022
1103
|
});
|
|
1023
1104
|
}
|
|
1105
|
+
|
|
1024
1106
|
return formatters$2.h(date, token);
|
|
1025
1107
|
},
|
|
1026
1108
|
// Hour [0-23]
|
|
@@ -1030,27 +1112,32 @@ var formatters = {
|
|
|
1030
1112
|
unit: 'hour'
|
|
1031
1113
|
});
|
|
1032
1114
|
}
|
|
1115
|
+
|
|
1033
1116
|
return formatters$2.H(date, token);
|
|
1034
1117
|
},
|
|
1035
1118
|
// Hour [0-11]
|
|
1036
1119
|
K: function K(date, token, localize) {
|
|
1037
1120
|
var hours = date.getUTCHours() % 12;
|
|
1121
|
+
|
|
1038
1122
|
if (token === 'Ko') {
|
|
1039
1123
|
return localize.ordinalNumber(hours, {
|
|
1040
1124
|
unit: 'hour'
|
|
1041
1125
|
});
|
|
1042
1126
|
}
|
|
1127
|
+
|
|
1043
1128
|
return addLeadingZeros(hours, token.length);
|
|
1044
1129
|
},
|
|
1045
1130
|
// Hour [1-24]
|
|
1046
1131
|
k: function k(date, token, localize) {
|
|
1047
1132
|
var hours = date.getUTCHours();
|
|
1048
1133
|
if (hours === 0) hours = 24;
|
|
1134
|
+
|
|
1049
1135
|
if (token === 'ko') {
|
|
1050
1136
|
return localize.ordinalNumber(hours, {
|
|
1051
1137
|
unit: 'hour'
|
|
1052
1138
|
});
|
|
1053
1139
|
}
|
|
1140
|
+
|
|
1054
1141
|
return addLeadingZeros(hours, token.length);
|
|
1055
1142
|
},
|
|
1056
1143
|
// Minute
|
|
@@ -1060,6 +1147,7 @@ var formatters = {
|
|
|
1060
1147
|
unit: 'minute'
|
|
1061
1148
|
});
|
|
1062
1149
|
}
|
|
1150
|
+
|
|
1063
1151
|
return formatters$2.m(date, token);
|
|
1064
1152
|
},
|
|
1065
1153
|
// Second
|
|
@@ -1069,6 +1157,7 @@ var formatters = {
|
|
|
1069
1157
|
unit: 'second'
|
|
1070
1158
|
});
|
|
1071
1159
|
}
|
|
1160
|
+
|
|
1072
1161
|
return formatters$2.s(date, token);
|
|
1073
1162
|
},
|
|
1074
1163
|
// Fraction of second
|
|
@@ -1079,27 +1168,30 @@ var formatters = {
|
|
|
1079
1168
|
X: function X(date, token, _localize, options) {
|
|
1080
1169
|
var originalDate = options._originalDate || date;
|
|
1081
1170
|
var timezoneOffset = originalDate.getTimezoneOffset();
|
|
1171
|
+
|
|
1082
1172
|
if (timezoneOffset === 0) {
|
|
1083
1173
|
return 'Z';
|
|
1084
1174
|
}
|
|
1175
|
+
|
|
1085
1176
|
switch (token) {
|
|
1086
1177
|
// Hours and optional minutes
|
|
1087
1178
|
case 'X':
|
|
1088
1179
|
return formatTimezoneWithOptionalMinutes(timezoneOffset);
|
|
1089
|
-
|
|
1090
1180
|
// Hours, minutes and optional seconds without `:` delimiter
|
|
1091
1181
|
// Note: neither ISO-8601 nor JavaScript supports seconds in timezone offsets
|
|
1092
1182
|
// so this token always has the same output as `XX`
|
|
1183
|
+
|
|
1093
1184
|
case 'XXXX':
|
|
1094
1185
|
case 'XX':
|
|
1095
1186
|
// Hours and minutes without `:` delimiter
|
|
1096
1187
|
return formatTimezone(timezoneOffset);
|
|
1097
|
-
|
|
1098
1188
|
// Hours, minutes and optional seconds with `:` delimiter
|
|
1099
1189
|
// Note: neither ISO-8601 nor JavaScript supports seconds in timezone offsets
|
|
1100
1190
|
// so this token always has the same output as `XXX`
|
|
1191
|
+
|
|
1101
1192
|
case 'XXXXX':
|
|
1102
1193
|
case 'XXX': // Hours and minutes with `:` delimiter
|
|
1194
|
+
|
|
1103
1195
|
default:
|
|
1104
1196
|
return formatTimezone(timezoneOffset, ':');
|
|
1105
1197
|
}
|
|
@@ -1108,24 +1200,26 @@ var formatters = {
|
|
|
1108
1200
|
x: function x(date, token, _localize, options) {
|
|
1109
1201
|
var originalDate = options._originalDate || date;
|
|
1110
1202
|
var timezoneOffset = originalDate.getTimezoneOffset();
|
|
1203
|
+
|
|
1111
1204
|
switch (token) {
|
|
1112
1205
|
// Hours and optional minutes
|
|
1113
1206
|
case 'x':
|
|
1114
1207
|
return formatTimezoneWithOptionalMinutes(timezoneOffset);
|
|
1115
|
-
|
|
1116
1208
|
// Hours, minutes and optional seconds without `:` delimiter
|
|
1117
1209
|
// Note: neither ISO-8601 nor JavaScript supports seconds in timezone offsets
|
|
1118
1210
|
// so this token always has the same output as `xx`
|
|
1211
|
+
|
|
1119
1212
|
case 'xxxx':
|
|
1120
1213
|
case 'xx':
|
|
1121
1214
|
// Hours and minutes without `:` delimiter
|
|
1122
1215
|
return formatTimezone(timezoneOffset);
|
|
1123
|
-
|
|
1124
1216
|
// Hours, minutes and optional seconds with `:` delimiter
|
|
1125
1217
|
// Note: neither ISO-8601 nor JavaScript supports seconds in timezone offsets
|
|
1126
1218
|
// so this token always has the same output as `xxx`
|
|
1219
|
+
|
|
1127
1220
|
case 'xxxxx':
|
|
1128
1221
|
case 'xxx': // Hours and minutes with `:` delimiter
|
|
1222
|
+
|
|
1129
1223
|
default:
|
|
1130
1224
|
return formatTimezone(timezoneOffset, ':');
|
|
1131
1225
|
}
|
|
@@ -1134,6 +1228,7 @@ var formatters = {
|
|
|
1134
1228
|
O: function O(date, token, _localize, options) {
|
|
1135
1229
|
var originalDate = options._originalDate || date;
|
|
1136
1230
|
var timezoneOffset = originalDate.getTimezoneOffset();
|
|
1231
|
+
|
|
1137
1232
|
switch (token) {
|
|
1138
1233
|
// Short
|
|
1139
1234
|
case 'O':
|
|
@@ -1141,6 +1236,7 @@ var formatters = {
|
|
|
1141
1236
|
case 'OOO':
|
|
1142
1237
|
return 'GMT' + formatTimezoneShort(timezoneOffset, ':');
|
|
1143
1238
|
// Long
|
|
1239
|
+
|
|
1144
1240
|
case 'OOOO':
|
|
1145
1241
|
default:
|
|
1146
1242
|
return 'GMT' + formatTimezone(timezoneOffset, ':');
|
|
@@ -1150,6 +1246,7 @@ var formatters = {
|
|
|
1150
1246
|
z: function z(date, token, _localize, options) {
|
|
1151
1247
|
var originalDate = options._originalDate || date;
|
|
1152
1248
|
var timezoneOffset = originalDate.getTimezoneOffset();
|
|
1249
|
+
|
|
1153
1250
|
switch (token) {
|
|
1154
1251
|
// Short
|
|
1155
1252
|
case 'z':
|
|
@@ -1157,6 +1254,7 @@ var formatters = {
|
|
|
1157
1254
|
case 'zzz':
|
|
1158
1255
|
return 'GMT' + formatTimezoneShort(timezoneOffset, ':');
|
|
1159
1256
|
// Long
|
|
1257
|
+
|
|
1160
1258
|
case 'zzzz':
|
|
1161
1259
|
default:
|
|
1162
1260
|
return 'GMT' + formatTimezone(timezoneOffset, ':');
|
|
@@ -1175,24 +1273,30 @@ var formatters = {
|
|
|
1175
1273
|
return addLeadingZeros(timestamp, token.length);
|
|
1176
1274
|
}
|
|
1177
1275
|
};
|
|
1276
|
+
|
|
1178
1277
|
function formatTimezoneShort(offset, dirtyDelimiter) {
|
|
1179
1278
|
var sign = offset > 0 ? '-' : '+';
|
|
1180
1279
|
var absOffset = Math.abs(offset);
|
|
1181
1280
|
var hours = Math.floor(absOffset / 60);
|
|
1182
1281
|
var minutes = absOffset % 60;
|
|
1282
|
+
|
|
1183
1283
|
if (minutes === 0) {
|
|
1184
1284
|
return sign + String(hours);
|
|
1185
1285
|
}
|
|
1286
|
+
|
|
1186
1287
|
var delimiter = dirtyDelimiter || '';
|
|
1187
1288
|
return sign + String(hours) + delimiter + addLeadingZeros(minutes, 2);
|
|
1188
1289
|
}
|
|
1290
|
+
|
|
1189
1291
|
function formatTimezoneWithOptionalMinutes(offset, dirtyDelimiter) {
|
|
1190
1292
|
if (offset % 60 === 0) {
|
|
1191
1293
|
var sign = offset > 0 ? '-' : '+';
|
|
1192
1294
|
return sign + addLeadingZeros(Math.abs(offset) / 60, 2);
|
|
1193
1295
|
}
|
|
1296
|
+
|
|
1194
1297
|
return formatTimezone(offset, dirtyDelimiter);
|
|
1195
1298
|
}
|
|
1299
|
+
|
|
1196
1300
|
function formatTimezone(offset, dirtyDelimiter) {
|
|
1197
1301
|
var delimiter = dirtyDelimiter || '';
|
|
1198
1302
|
var sign = offset > 0 ? '-' : '+';
|
|
@@ -1201,6 +1305,7 @@ function formatTimezone(offset, dirtyDelimiter) {
|
|
|
1201
1305
|
var minutes = addLeadingZeros(absOffset % 60, 2);
|
|
1202
1306
|
return sign + hours + delimiter + minutes;
|
|
1203
1307
|
}
|
|
1308
|
+
|
|
1204
1309
|
var formatters$1 = formatters;
|
|
1205
1310
|
|
|
1206
1311
|
var dateLongFormatter = function dateLongFormatter(pattern, formatLong) {
|
|
@@ -1209,14 +1314,17 @@ var dateLongFormatter = function dateLongFormatter(pattern, formatLong) {
|
|
|
1209
1314
|
return formatLong.date({
|
|
1210
1315
|
width: 'short'
|
|
1211
1316
|
});
|
|
1317
|
+
|
|
1212
1318
|
case 'PP':
|
|
1213
1319
|
return formatLong.date({
|
|
1214
1320
|
width: 'medium'
|
|
1215
1321
|
});
|
|
1322
|
+
|
|
1216
1323
|
case 'PPP':
|
|
1217
1324
|
return formatLong.date({
|
|
1218
1325
|
width: 'long'
|
|
1219
1326
|
});
|
|
1327
|
+
|
|
1220
1328
|
case 'PPPP':
|
|
1221
1329
|
default:
|
|
1222
1330
|
return formatLong.date({
|
|
@@ -1224,20 +1332,24 @@ var dateLongFormatter = function dateLongFormatter(pattern, formatLong) {
|
|
|
1224
1332
|
});
|
|
1225
1333
|
}
|
|
1226
1334
|
};
|
|
1335
|
+
|
|
1227
1336
|
var timeLongFormatter = function timeLongFormatter(pattern, formatLong) {
|
|
1228
1337
|
switch (pattern) {
|
|
1229
1338
|
case 'p':
|
|
1230
1339
|
return formatLong.time({
|
|
1231
1340
|
width: 'short'
|
|
1232
1341
|
});
|
|
1342
|
+
|
|
1233
1343
|
case 'pp':
|
|
1234
1344
|
return formatLong.time({
|
|
1235
1345
|
width: 'medium'
|
|
1236
1346
|
});
|
|
1347
|
+
|
|
1237
1348
|
case 'ppp':
|
|
1238
1349
|
return formatLong.time({
|
|
1239
1350
|
width: 'long'
|
|
1240
1351
|
});
|
|
1352
|
+
|
|
1241
1353
|
case 'pppp':
|
|
1242
1354
|
default:
|
|
1243
1355
|
return formatLong.time({
|
|
@@ -1245,30 +1357,37 @@ var timeLongFormatter = function timeLongFormatter(pattern, formatLong) {
|
|
|
1245
1357
|
});
|
|
1246
1358
|
}
|
|
1247
1359
|
};
|
|
1360
|
+
|
|
1248
1361
|
var dateTimeLongFormatter = function dateTimeLongFormatter(pattern, formatLong) {
|
|
1249
1362
|
var matchResult = pattern.match(/(P+)(p+)?/) || [];
|
|
1250
1363
|
var datePattern = matchResult[1];
|
|
1251
1364
|
var timePattern = matchResult[2];
|
|
1365
|
+
|
|
1252
1366
|
if (!timePattern) {
|
|
1253
1367
|
return dateLongFormatter(pattern, formatLong);
|
|
1254
1368
|
}
|
|
1369
|
+
|
|
1255
1370
|
var dateTimeFormat;
|
|
1371
|
+
|
|
1256
1372
|
switch (datePattern) {
|
|
1257
1373
|
case 'P':
|
|
1258
1374
|
dateTimeFormat = formatLong.dateTime({
|
|
1259
1375
|
width: 'short'
|
|
1260
1376
|
});
|
|
1261
1377
|
break;
|
|
1378
|
+
|
|
1262
1379
|
case 'PP':
|
|
1263
1380
|
dateTimeFormat = formatLong.dateTime({
|
|
1264
1381
|
width: 'medium'
|
|
1265
1382
|
});
|
|
1266
1383
|
break;
|
|
1384
|
+
|
|
1267
1385
|
case 'PPP':
|
|
1268
1386
|
dateTimeFormat = formatLong.dateTime({
|
|
1269
1387
|
width: 'long'
|
|
1270
1388
|
});
|
|
1271
1389
|
break;
|
|
1390
|
+
|
|
1272
1391
|
case 'PPPP':
|
|
1273
1392
|
default:
|
|
1274
1393
|
dateTimeFormat = formatLong.dateTime({
|
|
@@ -1276,8 +1395,10 @@ var dateTimeLongFormatter = function dateTimeLongFormatter(pattern, formatLong)
|
|
|
1276
1395
|
});
|
|
1277
1396
|
break;
|
|
1278
1397
|
}
|
|
1398
|
+
|
|
1279
1399
|
return dateTimeFormat.replace('{{date}}', dateLongFormatter(datePattern, formatLong)).replace('{{time}}', timeLongFormatter(timePattern, formatLong));
|
|
1280
1400
|
};
|
|
1401
|
+
|
|
1281
1402
|
var longFormatters = {
|
|
1282
1403
|
p: timeLongFormatter,
|
|
1283
1404
|
P: dateTimeLongFormatter
|
|
@@ -1331,15 +1452,14 @@ function throwProtectedError(token, format, input) {
|
|
|
1331
1452
|
// If there is no matching single quote
|
|
1332
1453
|
// then the sequence will continue until the end of the string.
|
|
1333
1454
|
// - . matches any single character unmatched by previous parts of the RegExps
|
|
1334
|
-
var formattingTokensRegExp = /[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g;
|
|
1335
1455
|
|
|
1336
|
-
// This RegExp catches symbols escaped by quotes, and also
|
|
1456
|
+
var formattingTokensRegExp = /[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g; // This RegExp catches symbols escaped by quotes, and also
|
|
1337
1457
|
// sequences of symbols P, p, and the combinations like `PPPPPPPppppp`
|
|
1458
|
+
|
|
1338
1459
|
var longFormattingTokensRegExp = /P+p+|P+|p+|''|'(''|[^'])+('|$)|./g;
|
|
1339
1460
|
var escapedStringRegExp = /^'([^]*?)'?$/;
|
|
1340
1461
|
var doubleQuoteRegExp = /''/g;
|
|
1341
1462
|
var unescapedLatinCharacterRegExp = /[a-zA-Z]/;
|
|
1342
|
-
|
|
1343
1463
|
/**
|
|
1344
1464
|
* @name format
|
|
1345
1465
|
* @category Common Helpers
|
|
@@ -1634,36 +1754,40 @@ var unescapedLatinCharacterRegExp = /[a-zA-Z]/;
|
|
|
1634
1754
|
|
|
1635
1755
|
function format(dirtyDate, dirtyFormatStr, options) {
|
|
1636
1756
|
var _ref, _options$locale, _ref2, _ref3, _ref4, _options$firstWeekCon, _options$locale2, _options$locale2$opti, _defaultOptions$local, _defaultOptions$local2, _ref5, _ref6, _ref7, _options$weekStartsOn, _options$locale3, _options$locale3$opti, _defaultOptions$local3, _defaultOptions$local4;
|
|
1757
|
+
|
|
1637
1758
|
requiredArgs(2, arguments);
|
|
1638
1759
|
var formatStr = String(dirtyFormatStr);
|
|
1639
1760
|
var defaultOptions = getDefaultOptions();
|
|
1640
1761
|
var locale = (_ref = (_options$locale = options === null || options === void 0 ? void 0 : options.locale) !== null && _options$locale !== void 0 ? _options$locale : defaultOptions.locale) !== null && _ref !== void 0 ? _ref : index.defaultLocale;
|
|
1641
|
-
var firstWeekContainsDate = toInteger((_ref2 = (_ref3 = (_ref4 = (_options$firstWeekCon = options === null || options === void 0 ? void 0 : options.firstWeekContainsDate) !== null && _options$firstWeekCon !== void 0 ? _options$firstWeekCon : options === null || options === void 0 ? void 0 : (_options$locale2 = options.locale) === null || _options$locale2 === void 0 ? void 0 : (_options$locale2$opti = _options$locale2.options) === null || _options$locale2$opti === void 0 ? void 0 : _options$locale2$opti.firstWeekContainsDate) !== null && _ref4 !== void 0 ? _ref4 : defaultOptions.firstWeekContainsDate) !== null && _ref3 !== void 0 ? _ref3 : (_defaultOptions$local = defaultOptions.locale) === null || _defaultOptions$local === void 0 ? void 0 : (_defaultOptions$local2 = _defaultOptions$local.options) === null || _defaultOptions$local2 === void 0 ? void 0 : _defaultOptions$local2.firstWeekContainsDate) !== null && _ref2 !== void 0 ? _ref2 : 1);
|
|
1762
|
+
var firstWeekContainsDate = toInteger((_ref2 = (_ref3 = (_ref4 = (_options$firstWeekCon = options === null || options === void 0 ? void 0 : options.firstWeekContainsDate) !== null && _options$firstWeekCon !== void 0 ? _options$firstWeekCon : options === null || options === void 0 ? void 0 : (_options$locale2 = options.locale) === null || _options$locale2 === void 0 ? void 0 : (_options$locale2$opti = _options$locale2.options) === null || _options$locale2$opti === void 0 ? void 0 : _options$locale2$opti.firstWeekContainsDate) !== null && _ref4 !== void 0 ? _ref4 : defaultOptions.firstWeekContainsDate) !== null && _ref3 !== void 0 ? _ref3 : (_defaultOptions$local = defaultOptions.locale) === null || _defaultOptions$local === void 0 ? void 0 : (_defaultOptions$local2 = _defaultOptions$local.options) === null || _defaultOptions$local2 === void 0 ? void 0 : _defaultOptions$local2.firstWeekContainsDate) !== null && _ref2 !== void 0 ? _ref2 : 1); // Test if weekStartsOn is between 1 and 7 _and_ is not NaN
|
|
1642
1763
|
|
|
1643
|
-
// Test if weekStartsOn is between 1 and 7 _and_ is not NaN
|
|
1644
1764
|
if (!(firstWeekContainsDate >= 1 && firstWeekContainsDate <= 7)) {
|
|
1645
1765
|
throw new RangeError('firstWeekContainsDate must be between 1 and 7 inclusively');
|
|
1646
1766
|
}
|
|
1647
|
-
var weekStartsOn = toInteger((_ref5 = (_ref6 = (_ref7 = (_options$weekStartsOn = options === null || options === void 0 ? void 0 : options.weekStartsOn) !== null && _options$weekStartsOn !== void 0 ? _options$weekStartsOn : options === null || options === void 0 ? void 0 : (_options$locale3 = options.locale) === null || _options$locale3 === void 0 ? void 0 : (_options$locale3$opti = _options$locale3.options) === null || _options$locale3$opti === void 0 ? void 0 : _options$locale3$opti.weekStartsOn) !== null && _ref7 !== void 0 ? _ref7 : defaultOptions.weekStartsOn) !== null && _ref6 !== void 0 ? _ref6 : (_defaultOptions$local3 = defaultOptions.locale) === null || _defaultOptions$local3 === void 0 ? void 0 : (_defaultOptions$local4 = _defaultOptions$local3.options) === null || _defaultOptions$local4 === void 0 ? void 0 : _defaultOptions$local4.weekStartsOn) !== null && _ref5 !== void 0 ? _ref5 : 0);
|
|
1648
1767
|
|
|
1649
|
-
// Test if weekStartsOn is between 0 and 6 _and_ is not NaN
|
|
1768
|
+
var weekStartsOn = toInteger((_ref5 = (_ref6 = (_ref7 = (_options$weekStartsOn = options === null || options === void 0 ? void 0 : options.weekStartsOn) !== null && _options$weekStartsOn !== void 0 ? _options$weekStartsOn : options === null || options === void 0 ? void 0 : (_options$locale3 = options.locale) === null || _options$locale3 === void 0 ? void 0 : (_options$locale3$opti = _options$locale3.options) === null || _options$locale3$opti === void 0 ? void 0 : _options$locale3$opti.weekStartsOn) !== null && _ref7 !== void 0 ? _ref7 : defaultOptions.weekStartsOn) !== null && _ref6 !== void 0 ? _ref6 : (_defaultOptions$local3 = defaultOptions.locale) === null || _defaultOptions$local3 === void 0 ? void 0 : (_defaultOptions$local4 = _defaultOptions$local3.options) === null || _defaultOptions$local4 === void 0 ? void 0 : _defaultOptions$local4.weekStartsOn) !== null && _ref5 !== void 0 ? _ref5 : 0); // Test if weekStartsOn is between 0 and 6 _and_ is not NaN
|
|
1769
|
+
|
|
1650
1770
|
if (!(weekStartsOn >= 0 && weekStartsOn <= 6)) {
|
|
1651
1771
|
throw new RangeError('weekStartsOn must be between 0 and 6 inclusively');
|
|
1652
1772
|
}
|
|
1773
|
+
|
|
1653
1774
|
if (!locale.localize) {
|
|
1654
1775
|
throw new RangeError('locale must contain localize property');
|
|
1655
1776
|
}
|
|
1777
|
+
|
|
1656
1778
|
if (!locale.formatLong) {
|
|
1657
1779
|
throw new RangeError('locale must contain formatLong property');
|
|
1658
1780
|
}
|
|
1781
|
+
|
|
1659
1782
|
var originalDate = toDate(dirtyDate);
|
|
1783
|
+
|
|
1660
1784
|
if (!isValid(originalDate)) {
|
|
1661
1785
|
throw new RangeError('Invalid time value');
|
|
1662
|
-
}
|
|
1663
|
-
|
|
1664
|
-
// Convert the date in system timezone to the same date in UTC+00:00 timezone.
|
|
1786
|
+
} // Convert the date in system timezone to the same date in UTC+00:00 timezone.
|
|
1665
1787
|
// This ensures that when UTC functions will be implemented, locales will be compatible with them.
|
|
1666
1788
|
// See an issue about UTC functions: https://github.com/date-fns/date-fns/issues/376
|
|
1789
|
+
|
|
1790
|
+
|
|
1667
1791
|
var timezoneOffset = getTimezoneOffsetInMilliseconds(originalDate);
|
|
1668
1792
|
var utcDate = subMilliseconds(originalDate, timezoneOffset);
|
|
1669
1793
|
var formatterOptions = {
|
|
@@ -1674,42 +1798,55 @@ function format(dirtyDate, dirtyFormatStr, options) {
|
|
|
1674
1798
|
};
|
|
1675
1799
|
var result = formatStr.match(longFormattingTokensRegExp).map(function (substring) {
|
|
1676
1800
|
var firstCharacter = substring[0];
|
|
1801
|
+
|
|
1677
1802
|
if (firstCharacter === 'p' || firstCharacter === 'P') {
|
|
1678
1803
|
var longFormatter = longFormatters$1[firstCharacter];
|
|
1679
1804
|
return longFormatter(substring, locale.formatLong);
|
|
1680
1805
|
}
|
|
1806
|
+
|
|
1681
1807
|
return substring;
|
|
1682
1808
|
}).join('').match(formattingTokensRegExp).map(function (substring) {
|
|
1683
1809
|
// Replace two single quote characters with one single quote character
|
|
1684
1810
|
if (substring === "''") {
|
|
1685
1811
|
return "'";
|
|
1686
1812
|
}
|
|
1813
|
+
|
|
1687
1814
|
var firstCharacter = substring[0];
|
|
1815
|
+
|
|
1688
1816
|
if (firstCharacter === "'") {
|
|
1689
1817
|
return cleanEscapedString(substring);
|
|
1690
1818
|
}
|
|
1819
|
+
|
|
1691
1820
|
var formatter = formatters$1[firstCharacter];
|
|
1821
|
+
|
|
1692
1822
|
if (formatter) {
|
|
1693
1823
|
if (!(options !== null && options !== void 0 && options.useAdditionalWeekYearTokens) && isProtectedWeekYearToken(substring)) {
|
|
1694
1824
|
throwProtectedError(substring, dirtyFormatStr, String(dirtyDate));
|
|
1695
1825
|
}
|
|
1826
|
+
|
|
1696
1827
|
if (!(options !== null && options !== void 0 && options.useAdditionalDayOfYearTokens) && isProtectedDayOfYearToken(substring)) {
|
|
1697
1828
|
throwProtectedError(substring, dirtyFormatStr, String(dirtyDate));
|
|
1698
1829
|
}
|
|
1830
|
+
|
|
1699
1831
|
return formatter(utcDate, substring, locale.localize, formatterOptions);
|
|
1700
1832
|
}
|
|
1833
|
+
|
|
1701
1834
|
if (firstCharacter.match(unescapedLatinCharacterRegExp)) {
|
|
1702
1835
|
throw new RangeError('Format string contains an unescaped latin alphabet character `' + firstCharacter + '`');
|
|
1703
1836
|
}
|
|
1837
|
+
|
|
1704
1838
|
return substring;
|
|
1705
1839
|
}).join('');
|
|
1706
1840
|
return result;
|
|
1707
1841
|
}
|
|
1842
|
+
|
|
1708
1843
|
function cleanEscapedString(input) {
|
|
1709
1844
|
var matched = input.match(escapedStringRegExp);
|
|
1845
|
+
|
|
1710
1846
|
if (!matched) {
|
|
1711
1847
|
return input;
|
|
1712
1848
|
}
|
|
1849
|
+
|
|
1713
1850
|
return matched[1].replace(doubleQuoteRegExp, "'");
|
|
1714
1851
|
}
|
|
1715
1852
|
|
|
@@ -1717,4 +1854,4 @@ exports.format = format;
|
|
|
1717
1854
|
exports.requiredArgs = requiredArgs;
|
|
1718
1855
|
exports.toDate = toDate;
|
|
1719
1856
|
exports.toInteger = toInteger;
|
|
1720
|
-
//# sourceMappingURL=index-
|
|
1857
|
+
//# sourceMappingURL=index-9dd778ed.js.map
|