@amityco/react-native-social-uikit 4.0.0-dc7783d.0 → 4.0.0-e78f8151.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +14 -14
- package/lib/commonjs/components/Toast/Toast.js +2 -1
- package/lib/commonjs/components/Toast/Toast.js.map +1 -1
- package/lib/commonjs/providers/file-provider.js +38 -19
- package/lib/commonjs/providers/file-provider.js.map +1 -1
- package/lib/commonjs/screens/CategorytList/index.js.map +1 -1
- package/lib/commonjs/snippet/AmityCommunitySearchResultComponent.js +3 -3
- package/lib/commonjs/snippet/AmityCommunitySearchResultComponent.js.map +1 -1
- package/lib/commonjs/snippet/AmityCreatePostMenuComponent.js +3 -3
- package/lib/commonjs/snippet/AmityCreatePostMenuComponent.js.map +1 -1
- package/lib/commonjs/snippet/AmityDetailedMediaAttachmentComponent.js +4 -4
- package/lib/commonjs/snippet/AmityDetailedMediaAttachmentComponent.js.map +1 -1
- package/lib/commonjs/snippet/AmityEmptyNewsFeedComponent.js +3 -3
- package/lib/commonjs/snippet/AmityEmptyNewsFeedComponent.js.map +1 -1
- package/lib/commonjs/snippet/AmityGlobalFeedComponent.js +3 -3
- package/lib/commonjs/snippet/AmityGlobalFeedComponent.js.map +1 -1
- package/lib/commonjs/snippet/AmityMediaAttachmentComponent.js +4 -4
- package/lib/commonjs/snippet/AmityMediaAttachmentComponent.js.map +1 -1
- package/lib/commonjs/snippet/AmityMyCommunitiesComponent.js +3 -3
- package/lib/commonjs/snippet/AmityMyCommunitiesComponent.js.map +1 -1
- package/lib/commonjs/snippet/AmityMyCommunitiesSearchPage.js +3 -3
- package/lib/commonjs/snippet/AmityMyCommunitiesSearchPage.js.map +1 -1
- package/lib/commonjs/snippet/AmityNewsFeedComponent.js +3 -3
- package/lib/commonjs/snippet/AmityNewsFeedComponent.js.map +1 -1
- package/lib/commonjs/snippet/AmityPostComposerPage.js +4 -4
- package/lib/commonjs/snippet/AmityPostComposerPage.js.map +1 -1
- package/lib/commonjs/snippet/AmityPostContentComponent.js +3 -3
- package/lib/commonjs/snippet/AmityPostContentComponent.js.map +1 -1
- package/lib/commonjs/snippet/AmityPostDetailPage.js +3 -3
- package/lib/commonjs/snippet/AmityPostDetailPage.js.map +1 -1
- package/lib/commonjs/snippet/AmityPostTargetSelectionPage.js +4 -4
- package/lib/commonjs/snippet/AmityPostTargetSelectionPage.js.map +1 -1
- package/lib/commonjs/snippet/AmityReactionListComponent.js +3 -3
- package/lib/commonjs/snippet/AmityReactionListComponent.js.map +1 -1
- package/lib/commonjs/snippet/AmitySocialGlobalSearchPage.js +3 -3
- package/lib/commonjs/snippet/AmitySocialGlobalSearchPage.js.map +1 -1
- package/lib/commonjs/snippet/AmitySocialHomePage.js +3 -3
- package/lib/commonjs/snippet/AmitySocialHomePage.js.map +1 -1
- package/lib/commonjs/snippet/AmitySocialHomeTopNavigationComponent.js +3 -3
- package/lib/commonjs/snippet/AmitySocialHomeTopNavigationComponent.js.map +1 -1
- package/lib/commonjs/snippet/AmityStoryTargetSelectionPage.js +3 -3
- package/lib/commonjs/snippet/AmityStoryTargetSelectionPage.js.map +1 -1
- package/lib/commonjs/snippet/AmityTopSearchBarComponent.js +3 -3
- package/lib/commonjs/snippet/AmityTopSearchBarComponent.js.map +1 -1
- package/lib/commonjs/snippet/AmityUserSearchResultComponent.js +3 -3
- package/lib/commonjs/snippet/AmityUserSearchResultComponent.js.map +1 -1
- package/lib/commonjs/svg/svg-xml-list.js +6 -1
- package/lib/commonjs/svg/svg-xml-list.js.map +1 -1
- package/lib/commonjs/v4/PublicApi/Components/AmityCommunityFeedComponent/AmityCommunityFeedComponent.js.map +1 -1
- package/lib/commonjs/v4/PublicApi/Components/AmityCommunityProfileTabComponent/AmityCommunityProfileTabComponent.js.map +1 -1
- package/lib/commonjs/v4/PublicApi/Components/AmityGlobalFeedComponent/AmityGlobalFeedComponent.js +4 -3
- package/lib/commonjs/v4/PublicApi/Components/AmityGlobalFeedComponent/AmityGlobalFeedComponent.js.map +1 -1
- package/lib/commonjs/v4/PublicApi/Components/AmityPostContentComponent/AmityPostContentComponent.js +0 -1
- package/lib/commonjs/v4/PublicApi/Components/AmityPostContentComponent/AmityPostContentComponent.js.map +1 -1
- package/lib/commonjs/v4/PublicApi/Components/AmityReactionListComponent/AmityReactionListComponent.js.map +1 -1
- package/lib/commonjs/v4/PublicApi/Pages/AmityLivestreamPostTargetSelectionPage/AmityLivestreamPostTargetSelectionPage.js +7 -1
- package/lib/commonjs/v4/PublicApi/Pages/AmityLivestreamPostTargetSelectionPage/AmityLivestreamPostTargetSelectionPage.js.map +1 -1
- package/lib/commonjs/v4/PublicApi/Pages/AmityPollTargetSelectionPage/AmityPollTargetSelectionPage.js +7 -1
- package/lib/commonjs/v4/PublicApi/Pages/AmityPollTargetSelectionPage/AmityPollTargetSelectionPage.js.map +1 -1
- package/lib/commonjs/v4/PublicApi/Pages/AmityPostComposerPage/AmityPostComposerPage.js +46 -3
- package/lib/commonjs/v4/PublicApi/Pages/AmityPostComposerPage/AmityPostComposerPage.js.map +1 -1
- package/lib/commonjs/v4/PublicApi/Pages/AmityPostTargetSelectionPage/AmityPostTargetSelectionPage.js +7 -1
- package/lib/commonjs/v4/PublicApi/Pages/AmityPostTargetSelectionPage/AmityPostTargetSelectionPage.js.map +1 -1
- package/lib/commonjs/v4/PublicApi/Pages/AmitySocialHomePage/AmitySocialHomePage.js.map +1 -1
- package/lib/commonjs/v4/PublicApi/Pages/AmityStoryTargetSelectionPage/AmityStoryTargetSelectionPage.js +7 -1
- package/lib/commonjs/v4/PublicApi/Pages/AmityStoryTargetSelectionPage/AmityStoryTargetSelectionPage.js.map +1 -1
- package/lib/commonjs/v4/PublicApi/Pages/AmityViewStoryPage/Components/AmityViewStoryItem.js +54 -21
- package/lib/commonjs/v4/PublicApi/Pages/AmityViewStoryPage/Components/AmityViewStoryItem.js.map +1 -1
- package/lib/commonjs/v4/PublicApi/Pages/AmityViewStoryPage/styles.js +24 -2
- package/lib/commonjs/v4/PublicApi/Pages/AmityViewStoryPage/styles.js.map +1 -1
- package/lib/commonjs/v4/assets/icons/toast.js +6 -6
- package/lib/commonjs/v4/assets/icons/toast.js.map +1 -1
- package/lib/commonjs/v4/component/CommunityStories/index.js +9 -4
- package/lib/commonjs/v4/component/CommunityStories/index.js.map +1 -1
- package/lib/commonjs/v4/component/CommunityStories/styles.js +7 -2
- package/lib/commonjs/v4/component/CommunityStories/styles.js.map +1 -1
- package/lib/commonjs/v4/component/LoadingImage/index.js +21 -22
- package/lib/commonjs/v4/component/LoadingImage/index.js.map +1 -1
- package/lib/commonjs/v4/component/LoadingImage/styles.js +19 -2
- package/lib/commonjs/v4/component/LoadingImage/styles.js.map +1 -1
- package/lib/commonjs/v4/component/LoadingVideo/index.js +11 -3
- package/lib/commonjs/v4/component/LoadingVideo/index.js.map +1 -1
- package/lib/commonjs/v4/component/MyStories/StoryCircleItem.js +11 -4
- package/lib/commonjs/v4/component/MyStories/StoryCircleItem.js.map +1 -1
- package/lib/commonjs/v4/component/MyStories/styles.js +5 -0
- package/lib/commonjs/v4/component/MyStories/styles.js.map +1 -1
- package/lib/commonjs/v4/component/PreviewLink/LinkPreview.js +3 -3
- package/lib/commonjs/v4/component/PreviewLink/LinkPreview.js.map +1 -1
- package/lib/commonjs/v4/component/PreviewLink/utils.js +9 -73
- package/lib/commonjs/v4/component/PreviewLink/utils.js.map +1 -1
- package/lib/commonjs/v4/component/TargetSelectionPage/TargetSelectionPage.js +10 -4
- package/lib/commonjs/v4/component/TargetSelectionPage/TargetSelectionPage.js.map +1 -1
- package/lib/commonjs/v4/elements/ActionButton/ActionButton.js.map +1 -1
- package/lib/commonjs/v4/elements/ImageViewer/ImageViewer.js.map +1 -1
- package/lib/commonjs/v4/elements/VideoViewer/VideoViewer.js.map +1 -1
- package/lib/commonjs/v4/features/community/Membership/components/MemberItem/MemberItem.js.map +1 -1
- package/lib/commonjs/v4/features/community/shared/components/Privacy/index.js.map +1 -1
- package/lib/commonjs/v4/hook/useImagePicker.js.map +1 -1
- package/lib/commonjs/v4/providers/BehaviourProvider.js +2 -1
- package/lib/commonjs/v4/providers/BehaviourProvider.js.map +1 -1
- package/lib/module/components/Toast/Toast.js +2 -1
- package/lib/module/components/Toast/Toast.js.map +1 -1
- package/lib/module/providers/file-provider.js +38 -19
- package/lib/module/providers/file-provider.js.map +1 -1
- package/lib/module/screens/CategorytList/index.js.map +1 -1
- package/lib/module/snippet/AmityCommunitySearchResultComponent.js +1 -1
- package/lib/module/snippet/AmityCommunitySearchResultComponent.js.map +1 -1
- package/lib/module/snippet/AmityCreatePostMenuComponent.js +1 -1
- package/lib/module/snippet/AmityCreatePostMenuComponent.js.map +1 -1
- package/lib/module/snippet/AmityDetailedMediaAttachmentComponent.js +1 -1
- package/lib/module/snippet/AmityDetailedMediaAttachmentComponent.js.map +1 -1
- package/lib/module/snippet/AmityEmptyNewsFeedComponent.js +1 -1
- package/lib/module/snippet/AmityEmptyNewsFeedComponent.js.map +1 -1
- package/lib/module/snippet/AmityGlobalFeedComponent.js +1 -1
- package/lib/module/snippet/AmityGlobalFeedComponent.js.map +1 -1
- package/lib/module/snippet/AmityMediaAttachmentComponent.js +1 -1
- package/lib/module/snippet/AmityMediaAttachmentComponent.js.map +1 -1
- package/lib/module/snippet/AmityMyCommunitiesComponent.js +1 -1
- package/lib/module/snippet/AmityMyCommunitiesComponent.js.map +1 -1
- package/lib/module/snippet/AmityMyCommunitiesSearchPage.js +1 -1
- package/lib/module/snippet/AmityMyCommunitiesSearchPage.js.map +1 -1
- package/lib/module/snippet/AmityNewsFeedComponent.js +1 -1
- package/lib/module/snippet/AmityNewsFeedComponent.js.map +1 -1
- package/lib/module/snippet/AmityPostComposerPage.js +1 -1
- package/lib/module/snippet/AmityPostComposerPage.js.map +1 -1
- package/lib/module/snippet/AmityPostContentComponent.js +1 -1
- package/lib/module/snippet/AmityPostContentComponent.js.map +1 -1
- package/lib/module/snippet/AmityPostDetailPage.js +1 -1
- package/lib/module/snippet/AmityPostDetailPage.js.map +1 -1
- package/lib/module/snippet/AmityPostTargetSelectionPage.js +1 -1
- package/lib/module/snippet/AmityPostTargetSelectionPage.js.map +1 -1
- package/lib/module/snippet/AmityReactionListComponent.js +1 -1
- package/lib/module/snippet/AmityReactionListComponent.js.map +1 -1
- package/lib/module/snippet/AmitySocialGlobalSearchPage.js +1 -1
- package/lib/module/snippet/AmitySocialGlobalSearchPage.js.map +1 -1
- package/lib/module/snippet/AmitySocialHomePage.js +1 -1
- package/lib/module/snippet/AmitySocialHomePage.js.map +1 -1
- package/lib/module/snippet/AmitySocialHomeTopNavigationComponent.js +1 -1
- package/lib/module/snippet/AmitySocialHomeTopNavigationComponent.js.map +1 -1
- package/lib/module/snippet/AmityStoryTargetSelectionPage.js +1 -1
- package/lib/module/snippet/AmityStoryTargetSelectionPage.js.map +1 -1
- package/lib/module/snippet/AmityTopSearchBarComponent.js +1 -1
- package/lib/module/snippet/AmityTopSearchBarComponent.js.map +1 -1
- package/lib/module/snippet/AmityUserSearchResultComponent.js +1 -1
- package/lib/module/snippet/AmityUserSearchResultComponent.js.map +1 -1
- package/lib/module/svg/svg-xml-list.js +4 -0
- package/lib/module/svg/svg-xml-list.js.map +1 -1
- package/lib/module/v4/PublicApi/Components/AmityCommunityFeedComponent/AmityCommunityFeedComponent.js.map +1 -1
- package/lib/module/v4/PublicApi/Components/AmityCommunityProfileTabComponent/AmityCommunityProfileTabComponent.js.map +1 -1
- package/lib/module/v4/PublicApi/Components/AmityGlobalFeedComponent/AmityGlobalFeedComponent.js +5 -4
- package/lib/module/v4/PublicApi/Components/AmityGlobalFeedComponent/AmityGlobalFeedComponent.js.map +1 -1
- package/lib/module/v4/PublicApi/Components/AmityPostContentComponent/AmityPostContentComponent.js +0 -1
- package/lib/module/v4/PublicApi/Components/AmityPostContentComponent/AmityPostContentComponent.js.map +1 -1
- package/lib/module/v4/PublicApi/Components/AmityReactionListComponent/AmityReactionListComponent.js.map +1 -1
- package/lib/module/v4/PublicApi/Pages/AmityLivestreamPostTargetSelectionPage/AmityLivestreamPostTargetSelectionPage.js +7 -1
- package/lib/module/v4/PublicApi/Pages/AmityLivestreamPostTargetSelectionPage/AmityLivestreamPostTargetSelectionPage.js.map +1 -1
- package/lib/module/v4/PublicApi/Pages/AmityPollTargetSelectionPage/AmityPollTargetSelectionPage.js +7 -1
- package/lib/module/v4/PublicApi/Pages/AmityPollTargetSelectionPage/AmityPollTargetSelectionPage.js.map +1 -1
- package/lib/module/v4/PublicApi/Pages/AmityPostComposerPage/AmityPostComposerPage.js +46 -3
- package/lib/module/v4/PublicApi/Pages/AmityPostComposerPage/AmityPostComposerPage.js.map +1 -1
- package/lib/module/v4/PublicApi/Pages/AmityPostTargetSelectionPage/AmityPostTargetSelectionPage.js +7 -1
- package/lib/module/v4/PublicApi/Pages/AmityPostTargetSelectionPage/AmityPostTargetSelectionPage.js.map +1 -1
- package/lib/module/v4/PublicApi/Pages/AmitySocialHomePage/AmitySocialHomePage.js.map +1 -1
- package/lib/module/v4/PublicApi/Pages/AmityStoryTargetSelectionPage/AmityStoryTargetSelectionPage.js +7 -1
- package/lib/module/v4/PublicApi/Pages/AmityStoryTargetSelectionPage/AmityStoryTargetSelectionPage.js.map +1 -1
- package/lib/module/v4/PublicApi/Pages/AmityViewStoryPage/Components/AmityViewStoryItem.js +54 -21
- package/lib/module/v4/PublicApi/Pages/AmityViewStoryPage/Components/AmityViewStoryItem.js.map +1 -1
- package/lib/module/v4/PublicApi/Pages/AmityViewStoryPage/styles.js +24 -2
- package/lib/module/v4/PublicApi/Pages/AmityViewStoryPage/styles.js.map +1 -1
- package/lib/module/v4/assets/icons/toast.js +6 -6
- package/lib/module/v4/assets/icons/toast.js.map +1 -1
- package/lib/module/v4/component/CommunityStories/index.js +10 -5
- package/lib/module/v4/component/CommunityStories/index.js.map +1 -1
- package/lib/module/v4/component/CommunityStories/styles.js +7 -2
- package/lib/module/v4/component/CommunityStories/styles.js.map +1 -1
- package/lib/module/v4/component/LoadingImage/index.js +21 -21
- package/lib/module/v4/component/LoadingImage/index.js.map +1 -1
- package/lib/module/v4/component/LoadingImage/styles.js +19 -2
- package/lib/module/v4/component/LoadingImage/styles.js.map +1 -1
- package/lib/module/v4/component/LoadingVideo/index.js +11 -3
- package/lib/module/v4/component/LoadingVideo/index.js.map +1 -1
- package/lib/module/v4/component/MyStories/StoryCircleItem.js +13 -6
- package/lib/module/v4/component/MyStories/StoryCircleItem.js.map +1 -1
- package/lib/module/v4/component/MyStories/styles.js +5 -0
- package/lib/module/v4/component/MyStories/styles.js.map +1 -1
- package/lib/module/v4/component/PreviewLink/LinkPreview.js +3 -3
- package/lib/module/v4/component/PreviewLink/LinkPreview.js.map +1 -1
- package/lib/module/v4/component/PreviewLink/utils.js +9 -73
- package/lib/module/v4/component/PreviewLink/utils.js.map +1 -1
- package/lib/module/v4/component/TargetSelectionPage/TargetSelectionPage.js +10 -4
- package/lib/module/v4/component/TargetSelectionPage/TargetSelectionPage.js.map +1 -1
- package/lib/module/v4/elements/ActionButton/ActionButton.js.map +1 -1
- package/lib/module/v4/elements/ImageViewer/ImageViewer.js.map +1 -1
- package/lib/module/v4/elements/VideoViewer/VideoViewer.js.map +1 -1
- package/lib/module/v4/features/community/Membership/components/MemberItem/MemberItem.js.map +1 -1
- package/lib/module/v4/features/community/shared/components/Privacy/index.js.map +1 -1
- package/lib/module/v4/hook/useImagePicker.js.map +1 -1
- package/lib/module/v4/providers/BehaviourProvider.js +2 -1
- package/lib/module/v4/providers/BehaviourProvider.js.map +1 -1
- package/lib/typescript/src/components/Toast/Toast.d.ts.map +1 -1
- package/lib/typescript/src/providers/file-provider.d.ts.map +1 -1
- package/lib/typescript/src/screens/CategorytList/index.d.ts.map +1 -1
- package/lib/typescript/src/svg/svg-xml-list.d.ts +1 -0
- package/lib/typescript/src/svg/svg-xml-list.d.ts.map +1 -1
- package/lib/typescript/src/v4/PublicApi/Components/AmityGlobalFeedComponent/AmityGlobalFeedComponent.d.ts +1 -0
- package/lib/typescript/src/v4/PublicApi/Components/AmityGlobalFeedComponent/AmityGlobalFeedComponent.d.ts.map +1 -1
- package/lib/typescript/src/v4/PublicApi/Components/AmityPostContentComponent/AmityPostContentComponent.d.ts.map +1 -1
- package/lib/typescript/src/v4/PublicApi/Pages/AmityLivestreamPostTargetSelectionPage/AmityLivestreamPostTargetSelectionPage.d.ts.map +1 -1
- package/lib/typescript/src/v4/PublicApi/Pages/AmityPollTargetSelectionPage/AmityPollTargetSelectionPage.d.ts.map +1 -1
- package/lib/typescript/src/v4/PublicApi/Pages/AmityPostComposerPage/AmityPostComposerPage.d.ts.map +1 -1
- package/lib/typescript/src/v4/PublicApi/Pages/AmityPostTargetSelectionPage/AmityPostTargetSelectionPage.d.ts.map +1 -1
- package/lib/typescript/src/v4/PublicApi/Pages/AmitySocialHomePage/AmitySocialHomePage.d.ts.map +1 -1
- package/lib/typescript/src/v4/PublicApi/Pages/AmityStoryTargetSelectionPage/AmityStoryTargetSelectionPage.d.ts.map +1 -1
- package/lib/typescript/src/v4/PublicApi/Pages/AmityViewStoryPage/Components/AmityViewStoryItem.d.ts.map +1 -1
- package/lib/typescript/src/v4/PublicApi/Pages/AmityViewStoryPage/styles.d.ts +22 -0
- package/lib/typescript/src/v4/PublicApi/Pages/AmityViewStoryPage/styles.d.ts.map +1 -1
- package/lib/typescript/src/v4/assets/icons/toast.d.ts +3 -3
- package/lib/typescript/src/v4/assets/icons/toast.d.ts.map +1 -1
- package/lib/typescript/src/v4/component/CommunityStories/index.d.ts.map +1 -1
- package/lib/typescript/src/v4/component/CommunityStories/styles.d.ts +5 -0
- package/lib/typescript/src/v4/component/CommunityStories/styles.d.ts.map +1 -1
- package/lib/typescript/src/v4/component/LoadingImage/index.d.ts +2 -1
- package/lib/typescript/src/v4/component/LoadingImage/index.d.ts.map +1 -1
- package/lib/typescript/src/v4/component/LoadingImage/styles.d.ts +21 -0
- package/lib/typescript/src/v4/component/LoadingImage/styles.d.ts.map +1 -1
- package/lib/typescript/src/v4/component/LoadingVideo/index.d.ts +2 -1
- package/lib/typescript/src/v4/component/LoadingVideo/index.d.ts.map +1 -1
- package/lib/typescript/src/v4/component/MyStories/StoryCircleItem.d.ts.map +1 -1
- package/lib/typescript/src/v4/component/MyStories/styles.d.ts +5 -0
- package/lib/typescript/src/v4/component/MyStories/styles.d.ts.map +1 -1
- package/lib/typescript/src/v4/component/PreviewLink/utils.d.ts +6 -1
- package/lib/typescript/src/v4/component/PreviewLink/utils.d.ts.map +1 -1
- package/lib/typescript/src/v4/component/TargetSelectionPage/TargetSelectionPage.d.ts +2 -1
- package/lib/typescript/src/v4/component/TargetSelectionPage/TargetSelectionPage.d.ts.map +1 -1
- package/lib/typescript/src/v4/elements/ActionButton/ActionButton.d.ts.map +1 -1
- package/lib/typescript/src/v4/features/community/Membership/components/MemberItem/MemberItem.d.ts.map +1 -1
- package/lib/typescript/src/v4/features/community/shared/components/Privacy/index.d.ts.map +1 -1
- package/lib/typescript/src/v4/hook/useImagePicker.d.ts.map +1 -1
- package/lib/typescript/src/v4/providers/BehaviourProvider.d.ts.map +1 -1
- package/lib/typescript/src/v4/types/behaviour.interface.d.ts +7 -0
- package/lib/typescript/src/v4/types/behaviour.interface.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/components/Toast/Toast.tsx +1 -0
- package/src/providers/file-provider.tsx +42 -20
- package/src/screens/CategorytList/index.tsx +7 -14
- package/src/snippet/AmityCommunitySearchResultComponent.tsx +1 -1
- package/src/snippet/AmityCreatePostMenuComponent.tsx +1 -1
- package/src/snippet/AmityDetailedMediaAttachmentComponent.tsx +1 -1
- package/src/snippet/AmityEmptyNewsFeedComponent.tsx +1 -1
- package/src/snippet/AmityGlobalFeedComponent.tsx +1 -1
- package/src/snippet/AmityMediaAttachmentComponent.tsx +1 -1
- package/src/snippet/AmityMyCommunitiesComponent.tsx +1 -1
- package/src/snippet/AmityMyCommunitiesSearchPage.tsx +1 -1
- package/src/snippet/AmityNewsFeedComponent.tsx +1 -1
- package/src/snippet/AmityPostComposerPage.tsx +1 -1
- package/src/snippet/AmityPostContentComponent.tsx +1 -1
- package/src/snippet/AmityPostDetailPage.tsx +1 -1
- package/src/snippet/AmityPostTargetSelectionPage.tsx +1 -1
- package/src/snippet/AmityReactionListComponent.tsx +1 -1
- package/src/snippet/AmitySocialGlobalSearchPage.tsx +1 -1
- package/src/snippet/AmitySocialHomePage.tsx +1 -1
- package/src/snippet/AmitySocialHomeTopNavigationComponent.tsx +1 -1
- package/src/snippet/AmityStoryTargetSelectionPage.tsx +1 -1
- package/src/snippet/AmityTopSearchBarComponent.tsx +1 -1
- package/src/snippet/AmityUserSearchResultComponent.tsx +1 -1
- package/src/svg/svg-xml-list.ts +6 -0
- package/src/v4/PublicApi/Components/AmityCommunityFeedComponent/AmityCommunityFeedComponent.tsx +2 -2
- package/src/v4/PublicApi/Components/AmityCommunityProfileTabComponent/AmityCommunityProfileTabComponent.tsx +97 -97
- package/src/v4/PublicApi/Components/AmityGlobalFeedComponent/AmityGlobalFeedComponent.tsx +12 -7
- package/src/v4/PublicApi/Components/AmityPostContentComponent/AmityPostContentComponent.tsx +0 -2
- package/src/v4/PublicApi/Components/AmityReactionListComponent/AmityReactionListComponent.tsx +9 -9
- package/src/v4/PublicApi/Pages/AmityLivestreamPostTargetSelectionPage/AmityLivestreamPostTargetSelectionPage.tsx +6 -0
- package/src/v4/PublicApi/Pages/AmityPollTargetSelectionPage/AmityPollTargetSelectionPage.tsx +6 -1
- package/src/v4/PublicApi/Pages/AmityPostComposerPage/AmityPostComposerPage.tsx +53 -2
- package/src/v4/PublicApi/Pages/AmityPostTargetSelectionPage/AmityPostTargetSelectionPage.tsx +7 -0
- package/src/v4/PublicApi/Pages/AmitySocialHomePage/AmitySocialHomePage.tsx +5 -1
- package/src/v4/PublicApi/Pages/AmityStoryTargetSelectionPage/AmityStoryTargetSelectionPage.tsx +7 -0
- package/src/v4/PublicApi/Pages/AmityViewStoryPage/Components/AmityViewStoryItem.tsx +122 -57
- package/src/v4/PublicApi/Pages/AmityViewStoryPage/styles.ts +23 -1
- package/src/v4/assets/icons/toast.tsx +12 -9
- package/src/v4/component/CommunityStories/index.tsx +26 -17
- package/src/v4/component/CommunityStories/styles.ts +7 -2
- package/src/v4/component/LoadingImage/index.tsx +28 -22
- package/src/v4/component/LoadingImage/styles.ts +17 -0
- package/src/v4/component/LoadingVideo/index.tsx +12 -3
- package/src/v4/component/MyStories/StoryCircleItem.tsx +19 -12
- package/src/v4/component/MyStories/styles.ts +5 -0
- package/src/v4/component/PreviewLink/LinkPreview.tsx +3 -3
- package/src/v4/component/PreviewLink/utils.ts +9 -108
- package/src/v4/component/TargetSelectionPage/TargetSelectionPage.tsx +12 -4
- package/src/v4/elements/ActionButton/ActionButton.tsx +4 -1
- package/src/v4/elements/ImageViewer/ImageViewer.tsx +1 -1
- package/src/v4/elements/VideoViewer/VideoViewer.tsx +1 -1
- package/src/v4/features/community/Membership/components/MemberItem/MemberItem.tsx +11 -2
- package/src/v4/features/community/shared/components/Privacy/index.tsx +4 -1
- package/src/v4/hook/useImagePicker.ts +4 -1
- package/src/v4/providers/BehaviourProvider.tsx +1 -0
- package/src/v4/types/behaviour.interface.ts +7 -0
|
@@ -60,6 +60,7 @@ import { getPostErrorMessage } from '../../../utils/errors';
|
|
|
60
60
|
import { MAXIMUM_POST_CHARACTERS } from '../../../constants';
|
|
61
61
|
import { replaceTriggerValues } from 'react-native-controlled-mentions';
|
|
62
62
|
import { useUIKitDispatch } from '../../../../redux/store';
|
|
63
|
+
import { useBehaviour } from '../../../../v4/providers/BehaviourProvider';
|
|
63
64
|
|
|
64
65
|
const AmityPostComposerPage: FC<AmityPostComposerPageType> = ({
|
|
65
66
|
mode,
|
|
@@ -75,6 +76,7 @@ const AmityPostComposerPage: FC<AmityPostComposerPageType> = ({
|
|
|
75
76
|
shouldCall: true,
|
|
76
77
|
});
|
|
77
78
|
const pageId = PageID.post_composer_page;
|
|
79
|
+
const { AmityPostComposerPageBehavior } = useBehaviour();
|
|
78
80
|
const { isExcluded, themeStyles, accessibilityId } = useAmityPage({ pageId });
|
|
79
81
|
const styles = useStyles(themeStyles);
|
|
80
82
|
const { getImage } = useFile();
|
|
@@ -105,12 +107,16 @@ const AmityPostComposerPage: FC<AmityPostComposerPageType> = ({
|
|
|
105
107
|
const [deletedPostIds, setDeletedPostIds] = useState<string[]>([]);
|
|
106
108
|
const [isUploading, setIsUploading] = useState(false);
|
|
107
109
|
const [hasChangedAttachment, setHasChangedAttachment] = useState(false);
|
|
110
|
+
const [imageErrors, setImageErrors] = useState<Set<string>>(new Set());
|
|
111
|
+
const [videoErrors, setVideoErrors] = useState<Set<string>>(new Set());
|
|
108
112
|
const privateCommunityId = !community?.isPublic && community?.communityId;
|
|
109
113
|
const title = isEditMode
|
|
110
114
|
? 'Edit Post'
|
|
111
115
|
: community?.displayName ?? 'My Timeline';
|
|
112
116
|
const isInputValid =
|
|
113
117
|
!isUploading &&
|
|
118
|
+
imageErrors.size === 0 &&
|
|
119
|
+
videoErrors.size === 0 &&
|
|
114
120
|
inputMessage.trim().length <= MAXIMUM_POST_CHARACTERS &&
|
|
115
121
|
(inputMessage.trim().length > 0 ||
|
|
116
122
|
displayImages.length > 0 ||
|
|
@@ -286,17 +292,20 @@ const AmityPostComposerPage: FC<AmityPostComposerPageType> = ({
|
|
|
286
292
|
|
|
287
293
|
const onPressClose = useCallback(() => {
|
|
288
294
|
const routes = navigation.getState().routes;
|
|
295
|
+
if (AmityPostComposerPageBehavior?.onPressPost) {
|
|
296
|
+
AmityPostComposerPageBehavior.onPressPost();
|
|
297
|
+
}
|
|
289
298
|
if (routes[routes.length - 2].name === 'PostTargetSelection') {
|
|
290
299
|
navigation.pop(2);
|
|
291
300
|
} else navigation.pop();
|
|
292
|
-
}, [navigation]);
|
|
301
|
+
}, [navigation, AmityPostComposerPageBehavior]);
|
|
293
302
|
|
|
294
303
|
const onClose = useCallback(() => {
|
|
295
304
|
Alert.alert(
|
|
296
305
|
'Discard this post',
|
|
297
306
|
'The post will be permanently deleted. It cannot be undone',
|
|
298
307
|
[
|
|
299
|
-
{ text: '
|
|
308
|
+
{ text: 'Keep Editing', style: 'cancel' },
|
|
300
309
|
{
|
|
301
310
|
text: 'Discard',
|
|
302
311
|
style: 'destructive',
|
|
@@ -593,10 +602,45 @@ const AmityPostComposerPage: FC<AmityPostComposerPageType> = ({
|
|
|
593
602
|
}
|
|
594
603
|
}, [displayVideos.length, processMedia]);
|
|
595
604
|
|
|
605
|
+
const handleImageUploadError = useCallback(
|
|
606
|
+
(hasError: boolean, source: string) => {
|
|
607
|
+
setImageErrors((prev) => {
|
|
608
|
+
const newSet = new Set(prev);
|
|
609
|
+
if (hasError) {
|
|
610
|
+
newSet.add(source);
|
|
611
|
+
} else {
|
|
612
|
+
newSet.delete(source);
|
|
613
|
+
}
|
|
614
|
+
return newSet;
|
|
615
|
+
});
|
|
616
|
+
},
|
|
617
|
+
[]
|
|
618
|
+
);
|
|
619
|
+
|
|
620
|
+
const handleVideoUploadError = useCallback(
|
|
621
|
+
(hasError: boolean, source: string) => {
|
|
622
|
+
setVideoErrors((prev) => {
|
|
623
|
+
const newSet = new Set(prev);
|
|
624
|
+
if (hasError) {
|
|
625
|
+
newSet.add(source);
|
|
626
|
+
} else {
|
|
627
|
+
newSet.delete(source);
|
|
628
|
+
}
|
|
629
|
+
return newSet;
|
|
630
|
+
});
|
|
631
|
+
},
|
|
632
|
+
[]
|
|
633
|
+
);
|
|
634
|
+
|
|
596
635
|
const handleOnCloseImage = useCallback(
|
|
597
636
|
(originalPath: string, _, postId: string) => {
|
|
598
637
|
setHasChangedAttachment(true);
|
|
599
638
|
setDeletedPostIds((prev) => [...prev, postId]);
|
|
639
|
+
setImageErrors((prev) => {
|
|
640
|
+
const newSet = new Set(prev);
|
|
641
|
+
newSet.delete(originalPath);
|
|
642
|
+
return newSet;
|
|
643
|
+
});
|
|
600
644
|
setDisplayImages((prevData) => {
|
|
601
645
|
const newData = prevData.filter(
|
|
602
646
|
(item: IDisplayImage) => item.url !== originalPath
|
|
@@ -610,6 +654,11 @@ const AmityPostComposerPage: FC<AmityPostComposerPageType> = ({
|
|
|
610
654
|
(originalPath: string, _, postId: string) => {
|
|
611
655
|
setHasChangedAttachment(true);
|
|
612
656
|
setDeletedPostIds((prev) => [...prev, postId]);
|
|
657
|
+
setVideoErrors((prev) => {
|
|
658
|
+
const newSet = new Set(prev);
|
|
659
|
+
newSet.delete(originalPath);
|
|
660
|
+
return newSet;
|
|
661
|
+
});
|
|
613
662
|
setDisplayVideos((prevData) => {
|
|
614
663
|
const newData = prevData.filter(
|
|
615
664
|
(item: IDisplayImage) => item.url !== originalPath
|
|
@@ -755,6 +804,7 @@ const AmityPostComposerPage: FC<AmityPostComposerPageType> = ({
|
|
|
755
804
|
onClose={handleOnCloseImage}
|
|
756
805
|
index={index} //TODO: Fix this without index
|
|
757
806
|
onLoadFinish={handleOnFinishImage}
|
|
807
|
+
onUploadError={handleImageUploadError}
|
|
758
808
|
isUploaded={item.isUploaded}
|
|
759
809
|
fileId={item.fileId}
|
|
760
810
|
fileCount={displayImages.length}
|
|
@@ -778,6 +828,7 @@ const AmityPostComposerPage: FC<AmityPostComposerPageType> = ({
|
|
|
778
828
|
onClose={handleOnCloseVideo}
|
|
779
829
|
index={index} //TODO: Fix this without index
|
|
780
830
|
onLoadFinish={handleOnFinishVideo}
|
|
831
|
+
onUploadError={handleVideoUploadError}
|
|
781
832
|
isUploaded={item.isUploaded}
|
|
782
833
|
fileId={item.fileId}
|
|
783
834
|
thumbNail={item.thumbNail as string}
|
package/src/v4/PublicApi/Pages/AmityPostTargetSelectionPage/AmityPostTargetSelectionPage.tsx
CHANGED
|
@@ -81,10 +81,17 @@ const AmityPostTargetSelectionPage = ({
|
|
|
81
81
|
}
|
|
82
82
|
};
|
|
83
83
|
|
|
84
|
+
const onClickClose = () => {
|
|
85
|
+
if (AmityPostTargetSelectionPageBehavior?.onClickClose) {
|
|
86
|
+
AmityPostTargetSelectionPageBehavior.onClickClose();
|
|
87
|
+
}
|
|
88
|
+
};
|
|
89
|
+
|
|
84
90
|
return (
|
|
85
91
|
<TargetSelectionPage
|
|
86
92
|
pageId={PageID.select_post_target_page}
|
|
87
93
|
onSelectFeed={onSelectFeed}
|
|
94
|
+
onClickClose={onClickClose}
|
|
88
95
|
/>
|
|
89
96
|
);
|
|
90
97
|
};
|
|
@@ -3,7 +3,11 @@ import { useCallback, useState } from 'react';
|
|
|
3
3
|
import { LogBox, SafeAreaView, StyleSheet } from 'react-native';
|
|
4
4
|
import CustomSocialTab from '../../../../v4/component/CustomSocialTab/CustomSocialTab';
|
|
5
5
|
import { useUiKitConfig } from '../../../../v4/hook';
|
|
6
|
-
import {
|
|
6
|
+
import {
|
|
7
|
+
ComponentID,
|
|
8
|
+
ElementID,
|
|
9
|
+
PageID,
|
|
10
|
+
} from '../../../../v4/enum/enumUIKitID';
|
|
7
11
|
|
|
8
12
|
import { useTheme } from 'react-native-paper';
|
|
9
13
|
import { useBehaviour } from '../../../../v4/providers/BehaviourProvider';
|
package/src/v4/PublicApi/Pages/AmityStoryTargetSelectionPage/AmityStoryTargetSelectionPage.tsx
CHANGED
|
@@ -24,11 +24,18 @@ const AmityStoryTargetSelectionPage = () => {
|
|
|
24
24
|
});
|
|
25
25
|
};
|
|
26
26
|
|
|
27
|
+
const onClickClose = () => {
|
|
28
|
+
if (AmityStoryTargetSelectionPageBehavior?.onClickClose) {
|
|
29
|
+
AmityStoryTargetSelectionPageBehavior.onClickClose();
|
|
30
|
+
}
|
|
31
|
+
};
|
|
32
|
+
|
|
27
33
|
return (
|
|
28
34
|
<TargetSelectionPage
|
|
29
35
|
pageId={PageID.select_story_target_page}
|
|
30
36
|
onSelectFeed={onSelectFeed}
|
|
31
37
|
hideMyTimelineTarget={true}
|
|
38
|
+
onClickClose={onClickClose}
|
|
32
39
|
/>
|
|
33
40
|
);
|
|
34
41
|
};
|
|
@@ -43,6 +43,8 @@ import { Typography } from '../../../../component/Typography/Typography';
|
|
|
43
43
|
import { useTheme } from 'react-native-paper';
|
|
44
44
|
import { MyMD3Theme } from '../../../../../providers/amity-ui-kit-provider';
|
|
45
45
|
import { useUIKitDispatch } from '../../../../../redux/store';
|
|
46
|
+
import { informative } from '~/v4/assets/icons/toast';
|
|
47
|
+
import { close as closeIcon } from '../../../../assets/icons';
|
|
46
48
|
|
|
47
49
|
interface IAmityViewStoryItem {
|
|
48
50
|
communityData: Amity.Community;
|
|
@@ -96,7 +98,6 @@ const AmityViewStoryItem: FC<IAmityViewStoryItem> = ({
|
|
|
96
98
|
const [isLiked, setIsLiked] = useState<boolean>(myReactions?.length > 0);
|
|
97
99
|
const [openCommentSheet, setOpenCommentSheet] = useState(false);
|
|
98
100
|
const [load, setLoad] = useState(true);
|
|
99
|
-
const [error, setError] = useState(false);
|
|
100
101
|
const [loading, setLoading] = useState(false);
|
|
101
102
|
const dispatch = useUIKitDispatch();
|
|
102
103
|
const { showToastMessage } = uiSlice.actions;
|
|
@@ -248,10 +249,20 @@ const AmityViewStoryItem: FC<IAmityViewStoryItem> = ({
|
|
|
248
249
|
);
|
|
249
250
|
if (deleted) {
|
|
250
251
|
current === 0 && previous();
|
|
251
|
-
dispatch(
|
|
252
|
+
dispatch(
|
|
253
|
+
showToastMessage({
|
|
254
|
+
toastMessage: 'Story deleted',
|
|
255
|
+
isSuccessToast: true,
|
|
256
|
+
})
|
|
257
|
+
);
|
|
252
258
|
}
|
|
253
259
|
} catch (err) {
|
|
254
|
-
dispatch(
|
|
260
|
+
dispatch(
|
|
261
|
+
showToastMessage({
|
|
262
|
+
toastMessage: 'Failed to delete story. Please try again.',
|
|
263
|
+
isSuccessToast: false,
|
|
264
|
+
})
|
|
265
|
+
);
|
|
255
266
|
} finally {
|
|
256
267
|
setLoading(false);
|
|
257
268
|
sheetRef?.current?.close();
|
|
@@ -288,6 +299,30 @@ const AmityViewStoryItem: FC<IAmityViewStoryItem> = ({
|
|
|
288
299
|
sheetRef.current?.open();
|
|
289
300
|
}, [progress]);
|
|
290
301
|
|
|
302
|
+
const onPressMenuButtonFailed = useCallback(() => {
|
|
303
|
+
progress.stopAnimation(() => setPressed(true));
|
|
304
|
+
Alert.alert(
|
|
305
|
+
'Failed to upload story',
|
|
306
|
+
'Would you like to discard uploading?',
|
|
307
|
+
[
|
|
308
|
+
{ text: 'Cancel', onPress: () => sheetRef?.current?.close() },
|
|
309
|
+
{ text: 'Delete', style: 'destructive', onPress: deleteStory },
|
|
310
|
+
]
|
|
311
|
+
);
|
|
312
|
+
}, [deleteStory, progress]);
|
|
313
|
+
|
|
314
|
+
const isFailedImageUpload =
|
|
315
|
+
currentStory?.dataType === 'image' &&
|
|
316
|
+
(currentStory?.syncState === 'error' ||
|
|
317
|
+
currentStory?.syncState === 'syncing' ||
|
|
318
|
+
!currentStory?.imageData?.fileUrl);
|
|
319
|
+
|
|
320
|
+
const isFailedVideoUpload =
|
|
321
|
+
currentStory?.dataType === 'video' &&
|
|
322
|
+
(currentStory?.syncState === 'error' ||
|
|
323
|
+
currentStory?.syncState === 'syncing' ||
|
|
324
|
+
!currentStory?.videoData?.fileUrl);
|
|
325
|
+
|
|
291
326
|
return (
|
|
292
327
|
<View style={[styles.container]}>
|
|
293
328
|
<SafeAreaView>
|
|
@@ -296,7 +331,13 @@ const AmityViewStoryItem: FC<IAmityViewStoryItem> = ({
|
|
|
296
331
|
<Video
|
|
297
332
|
onLoadStart={() => setLoad(true)}
|
|
298
333
|
onProgress={({ currentTime }) => setCurrentSeek(currentTime)}
|
|
299
|
-
source={{
|
|
334
|
+
source={{
|
|
335
|
+
uri:
|
|
336
|
+
currentStory?.videoData?.fileUrl ||
|
|
337
|
+
(typeof currentStory?.data?.fileData === 'string'
|
|
338
|
+
? currentStory?.data?.fileData
|
|
339
|
+
: ''),
|
|
340
|
+
}}
|
|
300
341
|
style={styles.video}
|
|
301
342
|
resizeMode="contain"
|
|
302
343
|
controls={false}
|
|
@@ -308,12 +349,15 @@ const AmityViewStoryItem: FC<IAmityViewStoryItem> = ({
|
|
|
308
349
|
) : currentStory?.dataType === 'image' ? (
|
|
309
350
|
<Image
|
|
310
351
|
onLoadStart={() => setLoad(true)}
|
|
311
|
-
onError={({ nativeEvent: { error: err } }) =>
|
|
312
|
-
err && setError(true)
|
|
313
|
-
}
|
|
314
352
|
onLoadEnd={() => start()}
|
|
315
|
-
source={{
|
|
316
|
-
|
|
353
|
+
source={{
|
|
354
|
+
uri:
|
|
355
|
+
currentStory?.imageData?.fileUrl ||
|
|
356
|
+
(typeof currentStory?.data?.fileData === 'string'
|
|
357
|
+
? currentStory?.data?.fileData
|
|
358
|
+
: ''),
|
|
359
|
+
}}
|
|
360
|
+
style={[styles.image, isFailedImageUpload && { opacity: 0.6 }]}
|
|
317
361
|
resizeMode="contain"
|
|
318
362
|
/>
|
|
319
363
|
) : null}
|
|
@@ -322,11 +366,6 @@ const AmityViewStoryItem: FC<IAmityViewStoryItem> = ({
|
|
|
322
366
|
<ActivityIndicator size="large" color={'white'} />
|
|
323
367
|
</View>
|
|
324
368
|
)}
|
|
325
|
-
{error && (
|
|
326
|
-
<View style={styles.spinnerContainer}>
|
|
327
|
-
<Text style={styles.error}>Story load error</Text>
|
|
328
|
-
</View>
|
|
329
|
-
)}
|
|
330
369
|
</View>
|
|
331
370
|
</SafeAreaView>
|
|
332
371
|
<GestureRecognizer onSwipeUp={onPressComment} style={styles.flexCol}>
|
|
@@ -399,7 +438,12 @@ const AmityViewStoryItem: FC<IAmityViewStoryItem> = ({
|
|
|
399
438
|
</TouchableOpacity>
|
|
400
439
|
)}
|
|
401
440
|
<TouchableOpacity hitSlop={5} onPress={() => onClose()}>
|
|
402
|
-
<
|
|
441
|
+
<SvgXml
|
|
442
|
+
xml={closeIcon()}
|
|
443
|
+
width="28"
|
|
444
|
+
height="28"
|
|
445
|
+
color="white"
|
|
446
|
+
/>
|
|
403
447
|
</TouchableOpacity>
|
|
404
448
|
</View>
|
|
405
449
|
</View>
|
|
@@ -465,49 +509,70 @@ const AmityViewStoryItem: FC<IAmityViewStoryItem> = ({
|
|
|
465
509
|
</TouchableOpacity>
|
|
466
510
|
)}
|
|
467
511
|
</GestureRecognizer>
|
|
468
|
-
|
|
469
|
-
{
|
|
470
|
-
<
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
>
|
|
476
|
-
|
|
477
|
-
<
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
styles.iconContainer,
|
|
486
|
-
{ backgroundColor: storyCommentBgColor },
|
|
487
|
-
]}
|
|
488
|
-
onPress={onPressComment}
|
|
489
|
-
>
|
|
490
|
-
<SvgXml xml={storyCommentIcon()} width="25" height="25" />
|
|
491
|
-
<Text style={styles.seen}>{commentsCounts}</Text>
|
|
492
|
-
</TouchableOpacity>
|
|
493
|
-
<TouchableOpacity
|
|
494
|
-
style={[
|
|
495
|
-
styles.iconContainer,
|
|
496
|
-
{
|
|
497
|
-
backgroundColor: storyReactionBgColor,
|
|
498
|
-
},
|
|
499
|
-
]}
|
|
500
|
-
onPress={onPressReaction}
|
|
501
|
-
>
|
|
502
|
-
<SvgXml
|
|
503
|
-
xml={isLiked ? storyLikedIcon : storyLikeIcon}
|
|
504
|
-
width="25"
|
|
505
|
-
height="25"
|
|
506
|
-
/>
|
|
507
|
-
<Text style={styles.seen}>{totalReaction}</Text>
|
|
508
|
-
</TouchableOpacity>
|
|
512
|
+
{(isFailedImageUpload || isFailedVideoUpload) && hasStoryPermission ? (
|
|
513
|
+
<View style={styles.errorContainer}>
|
|
514
|
+
<View style={styles.errorContainerLeft}>
|
|
515
|
+
<SvgXml xml={informative('white')} width="20" height="20" />
|
|
516
|
+
<Typography.Body style={styles.errorText}>
|
|
517
|
+
Failed to upload story
|
|
518
|
+
</Typography.Body>
|
|
519
|
+
</View>
|
|
520
|
+
{
|
|
521
|
+
<TouchableOpacity
|
|
522
|
+
hitSlop={5}
|
|
523
|
+
style={styles.threeDotsMenu}
|
|
524
|
+
onPress={onPressMenuButtonFailed}
|
|
525
|
+
>
|
|
526
|
+
<SvgXml xml={storyThreedotsMenu()} width="20" height="20" />
|
|
527
|
+
</TouchableOpacity>
|
|
528
|
+
}
|
|
509
529
|
</View>
|
|
510
|
-
|
|
530
|
+
) : (
|
|
531
|
+
<View style={styles.footer}>
|
|
532
|
+
{hasStoryImpressionPermission ? (
|
|
533
|
+
<TouchableOpacity
|
|
534
|
+
style={[
|
|
535
|
+
styles.seenContainer,
|
|
536
|
+
{ backgroundColor: storyViewerBgColor },
|
|
537
|
+
]}
|
|
538
|
+
>
|
|
539
|
+
<SvgXml xml={seenIcon()} width="25" height="25" />
|
|
540
|
+
<Text style={styles.seen}>{reachCount}</Text>
|
|
541
|
+
</TouchableOpacity>
|
|
542
|
+
) : (
|
|
543
|
+
<View style={styles.seenContainer} />
|
|
544
|
+
)}
|
|
545
|
+
<View style={styles.seenContainer}>
|
|
546
|
+
<TouchableOpacity
|
|
547
|
+
style={[
|
|
548
|
+
styles.iconContainer,
|
|
549
|
+
{ backgroundColor: storyCommentBgColor },
|
|
550
|
+
]}
|
|
551
|
+
onPress={onPressComment}
|
|
552
|
+
>
|
|
553
|
+
<SvgXml xml={storyCommentIcon()} width="25" height="25" />
|
|
554
|
+
<Text style={styles.seen}>{commentsCounts}</Text>
|
|
555
|
+
</TouchableOpacity>
|
|
556
|
+
<TouchableOpacity
|
|
557
|
+
style={[
|
|
558
|
+
styles.iconContainer,
|
|
559
|
+
{
|
|
560
|
+
backgroundColor: storyReactionBgColor,
|
|
561
|
+
},
|
|
562
|
+
]}
|
|
563
|
+
onPress={onPressReaction}
|
|
564
|
+
>
|
|
565
|
+
<SvgXml
|
|
566
|
+
xml={isLiked ? storyLikedIcon : storyLikeIcon}
|
|
567
|
+
width="25"
|
|
568
|
+
height="25"
|
|
569
|
+
/>
|
|
570
|
+
<Text style={styles.seen}>{totalReaction}</Text>
|
|
571
|
+
</TouchableOpacity>
|
|
572
|
+
</View>
|
|
573
|
+
</View>
|
|
574
|
+
)}
|
|
575
|
+
|
|
511
576
|
{openCommentSheet && (
|
|
512
577
|
<Modal
|
|
513
578
|
style={styles.bottomSheet}
|
|
@@ -14,6 +14,7 @@ export const useStyles = () => {
|
|
|
14
14
|
flex: 1,
|
|
15
15
|
width: width,
|
|
16
16
|
backgroundColor: '#000',
|
|
17
|
+
position: 'relative',
|
|
17
18
|
},
|
|
18
19
|
flex: {
|
|
19
20
|
flex: 1,
|
|
@@ -73,7 +74,7 @@ export const useStyles = () => {
|
|
|
73
74
|
fontSize: 14,
|
|
74
75
|
},
|
|
75
76
|
avatarSubText: {
|
|
76
|
-
color:
|
|
77
|
+
color: 'white',
|
|
77
78
|
fontSize: 12,
|
|
78
79
|
},
|
|
79
80
|
closeIconContainer: {
|
|
@@ -219,6 +220,27 @@ export const useStyles = () => {
|
|
|
219
220
|
color: theme.colors.base,
|
|
220
221
|
fontSize: 14,
|
|
221
222
|
},
|
|
223
|
+
errorContainer: {
|
|
224
|
+
width: '100%',
|
|
225
|
+
position: 'absolute',
|
|
226
|
+
bottom: 120,
|
|
227
|
+
left: 0,
|
|
228
|
+
backgroundColor: theme.colors.alert,
|
|
229
|
+
flexDirection: 'row',
|
|
230
|
+
alignItems: 'center',
|
|
231
|
+
justifyContent: 'space-between',
|
|
232
|
+
paddingVertical: 12,
|
|
233
|
+
paddingHorizontal: 16,
|
|
234
|
+
},
|
|
235
|
+
errorContainerLeft: {
|
|
236
|
+
display: 'flex',
|
|
237
|
+
flexDirection: 'row',
|
|
238
|
+
alignItems: 'center',
|
|
239
|
+
gap: 4,
|
|
240
|
+
},
|
|
241
|
+
errorText: {
|
|
242
|
+
color: 'white',
|
|
243
|
+
},
|
|
222
244
|
});
|
|
223
245
|
|
|
224
246
|
return styles;
|
|
@@ -1,18 +1,21 @@
|
|
|
1
|
-
export const failed =
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
export const failed = (
|
|
2
|
+
color: string = 'currentColor'
|
|
3
|
+
) => `<svg width="100%" height="100%" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
4
|
+
<path d="M12 3.53125C16.7812 3.53125 20.7188 7.46875 20.7188 12.25C20.7188 17.0664 16.7812 20.9688 12 20.9688C7.18359 20.9688 3.28125 17.0664 3.28125 12.25C3.28125 7.46875 7.18359 3.53125 12 3.53125ZM12 19.2812C15.8672 19.2812 19.0312 16.1523 19.0312 12.25C19.0312 8.38281 15.8672 5.21875 12 5.21875C8.09766 5.21875 4.96875 8.38281 4.96875 12.25C4.96875 16.1523 8.09766 19.2812 12 19.2812ZM13.4766 15.625C13.4766 16.4688 12.8086 17.1016 12 17.1016C11.1562 17.1016 10.5234 16.4688 10.5234 15.625C10.5234 14.8164 11.1562 14.1484 12 14.1484C12.8086 14.1484 13.4766 14.8164 13.4766 15.625ZM10.5938 8.20703C10.5938 7.96094 10.7695 7.75 11.0156 7.75H12.9492C13.1953 7.75 13.3711 7.96094 13.3711 8.20703L13.125 12.9883C13.125 13.1992 12.9141 13.375 12.7031 13.375H11.2617C11.0508 13.375 10.8398 13.1992 10.8398 12.9883L10.5938 8.20703Z" fill=${color}/>
|
|
4
5
|
</svg>
|
|
5
6
|
|
|
6
7
|
`;
|
|
7
8
|
|
|
8
|
-
export const success =
|
|
9
|
-
|
|
10
|
-
|
|
9
|
+
export const success = (
|
|
10
|
+
color: string = 'currentColor'
|
|
11
|
+
) => `<svg width="100%" height="100%" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
12
|
+
<path d="M12 3.53125C16.7812 3.53125 20.7188 7.46875 20.7188 12.25C20.7188 17.0664 16.7812 20.9688 12 20.9688C7.18359 20.9688 3.28125 17.0664 3.28125 12.25C3.28125 7.46875 7.18359 3.53125 12 3.53125ZM12 5.21875C8.09766 5.21875 4.96875 8.38281 4.96875 12.25C4.96875 16.1523 8.09766 19.2812 12 19.2812C15.8672 19.2812 19.0312 16.1523 19.0312 12.25C19.0312 8.38281 15.8672 5.21875 12 5.21875ZM16.9219 9.82422C17.0625 9.96484 17.0625 10.2461 16.9219 10.4219L10.8398 16.4336C10.6641 16.6094 10.418 16.6094 10.2422 16.4336L7.04297 13.1992C6.90234 13.0586 6.90234 12.7773 7.04297 12.6016L7.85156 11.8281C8.02734 11.6523 8.27344 11.6523 8.44922 11.8281L10.5586 13.9375L15.5156 9.01562C15.6914 8.83984 15.9727 8.83984 16.1133 9.01562L16.9219 9.82422Z" fill=${color}/>
|
|
11
13
|
</svg>
|
|
12
14
|
`;
|
|
13
15
|
|
|
14
|
-
export const informative =
|
|
15
|
-
|
|
16
|
-
|
|
16
|
+
export const informative = (
|
|
17
|
+
color: string = 'currentColor'
|
|
18
|
+
) => `<svg width="100%" height="100%" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
19
|
+
<path d="M12 3.53125C16.7812 3.53125 20.7188 7.46875 20.7188 12.25C20.7188 17.0664 16.7812 20.9688 12 20.9688C7.18359 20.9688 3.28125 17.0664 3.28125 12.25C3.28125 7.46875 7.18359 3.53125 12 3.53125ZM12 19.2812C15.8672 19.2812 19.0312 16.1523 19.0312 12.25C19.0312 8.38281 15.8672 5.21875 12 5.21875C8.09766 5.21875 4.96875 8.38281 4.96875 12.25C4.96875 16.1523 8.09766 19.2812 12 19.2812ZM12 7.39844C12.8086 7.39844 13.4766 8.06641 13.4766 8.875C13.4766 9.71875 12.8086 10.3516 12 10.3516C11.1562 10.3516 10.5234 9.71875 10.5234 8.875C10.5234 8.06641 11.1562 7.39844 12 7.39844ZM13.9688 16.3281C13.9688 16.5742 13.7578 16.75 13.5469 16.75H10.4531C10.207 16.75 10.0312 16.5742 10.0312 16.3281V15.4844C10.0312 15.2734 10.207 15.0625 10.4531 15.0625H10.875V12.8125H10.4531C10.207 12.8125 10.0312 12.6367 10.0312 12.3906V11.5469C10.0312 11.3359 10.207 11.125 10.4531 11.125H12.7031C12.9141 11.125 13.125 11.3359 13.125 11.5469V15.0625H13.5469C13.7578 15.0625 13.9688 15.2734 13.9688 15.4844V16.3281Z" fill=${color}/>
|
|
17
20
|
</svg>
|
|
18
21
|
`;
|
|
@@ -5,6 +5,7 @@ import { useStory } from '../../hook/useStory';
|
|
|
5
5
|
import { useFocusEffect, useNavigation } from '@react-navigation/native';
|
|
6
6
|
import { SvgXml } from 'react-native-svg';
|
|
7
7
|
import {
|
|
8
|
+
errorIcon,
|
|
8
9
|
storyCircleCreatePlusIcon,
|
|
9
10
|
storyRing,
|
|
10
11
|
} from '../../../svg/svg-xml-list';
|
|
@@ -34,17 +35,18 @@ const CommunityStories = ({ communityId, community }: ICommunityStories) => {
|
|
|
34
35
|
const { getImage } = useFile();
|
|
35
36
|
const [avatarUrl, setAvatarUrl] = useState(undefined);
|
|
36
37
|
const [viewStory, setViewStory] = useState(false);
|
|
37
|
-
const storyRingColor: string[] =
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
38
|
+
const storyRingColor: string[] =
|
|
39
|
+
hasStoryPermission && storyTarget?.failedStoriesCount > 0
|
|
40
|
+
? ['#DE1029', '#DE1029']
|
|
41
|
+
: storyTarget?.hasUnseen
|
|
42
|
+
? (getUiKitConfig({
|
|
43
|
+
page: PageID.StoryPage,
|
|
44
|
+
component: ComponentID.StoryTab,
|
|
45
|
+
element: ElementID.StoryRing,
|
|
46
|
+
})?.progress_color as string[]) ?? ['#e2e2e2', '#e2e2e2']
|
|
47
|
+
: stories.length > 0
|
|
48
|
+
? ['#e2e2e2', '#ffffff']
|
|
49
|
+
: ['#ffffff', '#ffffff'];
|
|
48
50
|
|
|
49
51
|
useEffect(() => {
|
|
50
52
|
(async () => {
|
|
@@ -86,6 +88,7 @@ const CommunityStories = ({ communityId, community }: ICommunityStories) => {
|
|
|
86
88
|
setViewStory(false);
|
|
87
89
|
onPressCreateStory();
|
|
88
90
|
}, [onPressCreateStory]);
|
|
91
|
+
|
|
89
92
|
const onPressCommunityName = useCallback(() => {
|
|
90
93
|
setViewStory(false);
|
|
91
94
|
navigation.navigate('CommunityProfilePage', {
|
|
@@ -121,12 +124,18 @@ const CommunityStories = ({ communityId, community }: ICommunityStories) => {
|
|
|
121
124
|
height={48}
|
|
122
125
|
xml={storyRing(storyRingColor[0], storyRingColor[1])}
|
|
123
126
|
/>
|
|
124
|
-
{hasStoryPermission
|
|
125
|
-
|
|
126
|
-
style={styles.
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
127
|
+
{hasStoryPermission ? (
|
|
128
|
+
storyTarget?.failedStoriesCount > 0 ? (
|
|
129
|
+
<SvgXml style={styles.errorIcon} xml={errorIcon()} />
|
|
130
|
+
) : (
|
|
131
|
+
<TouchableOpacity onPress={() => onPressCreateStory()}>
|
|
132
|
+
<SvgXml
|
|
133
|
+
style={styles.storyCreateIcon}
|
|
134
|
+
xml={storyCircleCreatePlusIcon()}
|
|
135
|
+
/>
|
|
136
|
+
</TouchableOpacity>
|
|
137
|
+
)
|
|
138
|
+
) : null}
|
|
130
139
|
</TouchableOpacity>
|
|
131
140
|
<Typography.Caption style={styles.base}>Story</Typography.Caption>
|
|
132
141
|
</>
|
|
@@ -91,10 +91,15 @@ export const useStyles = () => {
|
|
|
91
91
|
alignItems: 'center',
|
|
92
92
|
width: 68,
|
|
93
93
|
},
|
|
94
|
+
errorIcon: {
|
|
95
|
+
position: 'absolute',
|
|
96
|
+
right: 8,
|
|
97
|
+
bottom: 0,
|
|
98
|
+
},
|
|
94
99
|
storyCreateIcon: {
|
|
95
100
|
position: 'absolute',
|
|
96
|
-
left:
|
|
97
|
-
top:
|
|
101
|
+
left: 8,
|
|
102
|
+
top: -16,
|
|
98
103
|
},
|
|
99
104
|
base: {
|
|
100
105
|
color: theme.colors.base,
|