@selfcommunity/react-ui 0.11.0-mui7.22 → 0.11.0-mui7.23
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/lib/cjs/components/AccountDataPortability/AccountDataPortability.js +2 -2
- package/lib/cjs/components/AccountDelete/AccountDelete.js +3 -3
- package/lib/cjs/components/AccountRecover/AccountRecover.js +2 -4
- package/lib/cjs/components/BroadcastMessages/Message.js +1 -1
- package/lib/cjs/components/Categories/prefetchedCategories.js +115 -115
- package/lib/cjs/components/ChangeCover/ChangeCover.js +2 -6
- package/lib/cjs/components/ChangePicture/ChangePictureDialog/ChangePictureDialog.js +4 -8
- package/lib/cjs/components/CheckoutReturnDialog/CheckoutReturnDialog.js +5 -5
- package/lib/cjs/components/CommentsFeedObject/CommentsFeedObject.js +1 -1
- package/lib/cjs/components/ConsentSolution/ConsentSolution.js +9 -3
- package/lib/cjs/components/ConsentSolution/Skeleton.js +1 -1
- package/lib/cjs/components/CourseCompletedDialog/CourseCompletedDialog.js +1 -1
- package/lib/cjs/components/CourseForm/Edit.js +6 -2
- package/lib/cjs/components/Courses/Courses.js +1 -1
- package/lib/cjs/components/CreateLiveStreamDialog/LiveStreamSelector/LiveStreamSelector.js +1 -1
- package/lib/cjs/components/CustomAdv/Skeleton.js +1 -1
- package/lib/cjs/components/EditCourse/Status.js +1 -1
- package/lib/cjs/components/EventForm/EventForm.js +2 -2
- package/lib/cjs/components/EventLocationWidget/Skeleton.js +1 -1
- package/lib/cjs/components/Events/LocationEventsFilter.js +1 -1
- package/lib/cjs/components/FeedObject/Actions/Comment/Comment.js +2 -2
- package/lib/cjs/components/FeedObject/Activities/ActivitiesMenu/ActivitiesMenu.js +1 -1
- package/lib/cjs/components/FeedObject/Activities/RelevantActivities/CommentActivity/CommentActivity.js +1 -1
- package/lib/cjs/components/FeedObject/Activities/RelevantActivities/RelevantActivities.js +1 -1
- package/lib/cjs/components/FeedObject/Contributors/Contributors.js +1 -1
- package/lib/cjs/components/FeedObject/Contributors/Skeleton.js +1 -1
- package/lib/cjs/components/GroupForm/GroupForm.js +7 -7
- package/lib/cjs/components/GroupInfoWidget/GroupInfoWidget.js +5 -15
- package/lib/cjs/components/GroupSettingsIconButton/GroupSettingsIconButton.js +1 -1
- package/lib/cjs/components/Incubator/Incubator.js +2 -2
- package/lib/cjs/components/IncubatorDetail/IncubatorDetail.js +2 -2
- package/lib/cjs/components/IncubatorListWidget/CreateIncubatorDialog/CreateIncubatorDialog.js +2 -2
- package/lib/cjs/components/IncubatorListWidget/IncubatorListWidget.js +5 -5
- package/lib/cjs/components/IncubatorSuggestionWidget/IncubatorSuggestionWidget.js +1 -1
- package/lib/cjs/components/LessonCommentObjects/LessonCommentObjects.js +1 -1
- package/lib/cjs/components/LiveStreamForm/LiveStreamForm.js +1 -1
- package/lib/cjs/components/LiveStreamRoom/LiveStreamRoom.js +10 -8
- package/lib/cjs/components/LiveStreamRoom/LiveStreamVideoConference/LiveStreamVideoConference.js +3 -3
- package/lib/cjs/components/LiveStreamRoom/LiveStreamVideoConference/ParticipantTile.js +1 -1
- package/lib/cjs/components/LiveStreamRoom/LiveStreamVideoConference/ParticipantTileActions.js +1 -1
- package/lib/cjs/components/LoyaltyProgramWidget/LoyaltyProgramWidget.js +1 -1
- package/lib/cjs/components/LoyaltyProgramWidget/Skeleton.js +1 -1
- package/lib/cjs/components/Notification/CollapsedFor/CollapsedFor.js +3 -1
- package/lib/cjs/components/Notification/Comment/Comment.js +3 -3
- package/lib/cjs/components/Notification/Contribution/Contribution.js +1 -1
- package/lib/cjs/components/Notification/ContributionFollow/ContributionFollow.js +2 -2
- package/lib/cjs/components/Notification/Course/Course.js +4 -4
- package/lib/cjs/components/Notification/DeletedFor/DeletedFor.js +4 -2
- package/lib/cjs/components/Notification/Event/Event.js +4 -4
- package/lib/cjs/components/Notification/Group/Group.js +2 -2
- package/lib/cjs/components/Notification/IncubatorApproved/IncubatorApproved.js +3 -3
- package/lib/cjs/components/Notification/KindlyNoticeFlag/KindlyNoticeFlag.js +3 -1
- package/lib/cjs/components/Notification/KindlyNoticeFor/KindlyNoticeFor.js +5 -3
- package/lib/cjs/components/Notification/LiveStream/LiveStream.js +3 -3
- package/lib/cjs/components/Notification/Mention/Mention.js +2 -2
- package/lib/cjs/components/Notification/Notification.js +5 -5
- package/lib/cjs/components/Notification/PrivateMessage/PrivateMessage.js +3 -3
- package/lib/cjs/components/Notification/UndeletedFor/UndeletedFor.js +1 -1
- package/lib/cjs/components/Notification/UserBlocked/UserBlocked.js +6 -2
- package/lib/cjs/components/Notification/UserConnection/UserConnection.js +6 -2
- package/lib/cjs/components/Notification/UserFollow/UserFollow.js +2 -2
- package/lib/cjs/components/Notification/VoteUp/VoteUp.js +2 -2
- package/lib/cjs/components/OnBoardingWidget/OnBoardingWidget.js +10 -7
- package/lib/cjs/components/OnBoardingWidget/Skeleton.js +1 -1
- package/lib/cjs/components/OnBoardingWidget/Steps/App/App.js +9 -25
- package/lib/cjs/components/OnBoardingWidget/Steps/Category/Category.js +3 -9
- package/lib/cjs/components/PaymentOrder/PaymentOrder.js +1 -1
- package/lib/cjs/components/PaymentOrders/PaymentOrders.js +1 -1
- package/lib/cjs/components/PaywallsDialog/PaywallsDialog.js +1 -1
- package/lib/cjs/components/PlatformWidget/PlatformWidget.js +1 -1
- package/lib/cjs/components/PrivateMessageEditor/MessageMediaUploader/index.js +2 -2
- package/lib/cjs/components/PrivateMessageSnippets/Skeleton.js +1 -1
- package/lib/cjs/components/PrivateMessageThread/PrivateMessageThread.js +1 -1
- package/lib/cjs/components/PrivateMessageThread/Skeleton.js +1 -1
- package/lib/cjs/components/SnippetNotifications/SnippetNotifications.js +5 -5
- package/lib/cjs/components/UserAddPaymentMethodForm/UserAddPaymentMethodForm.js +3 -3
- package/lib/cjs/components/UserAutocomplete/UserAutocomplete.js +1 -1
- package/lib/cjs/components/UserBillingInfo/UserBillingInfo.js +1 -1
- package/lib/cjs/components/UserChangeAddressDialog/UserChangeAddressDialog.js +1 -1
- package/lib/cjs/components/UserCounters/UserCounters.js +5 -13
- package/lib/cjs/components/UserInfo/UserInfo.js +1 -1
- package/lib/cjs/components/UserPaymentMethods/UserPaymentMethods.js +6 -7
- package/lib/cjs/components/UserProfileEdit/Section/AccountCredentials.js +1 -1
- package/lib/cjs/components/UserProfileEdit/Section/PublicInfo.js +1 -1
- package/lib/cjs/shared/ContributionActionsMenu/index.js +3 -9
- package/lib/cjs/shared/DateTimeAgo/index.js +1 -1
- package/lib/cjs/shared/EmojiPicker/EmojiPicker.d.ts +1 -2
- package/lib/cjs/shared/InfiniteScroll/stories/ScrolleableTop.js +1 -1
- package/lib/cjs/shared/LessonCommentActionsMenu/index.js +2 -8
- package/lib/cjs/shared/Lightbox/BaseLightbox.js +1 -1
- package/lib/cjs/shared/MessageChunkUploader/index.js +1 -1
- package/lib/cjs/shared/Tags/index.js +1 -1
- package/lib/cjs/shared/UpScalingTierBadge/UpScalingTierBadge.d.ts +2 -2
- package/lib/esm/components/AccountDataPortability/AccountDataPortability.js +2 -2
- package/lib/esm/components/AccountDelete/AccountDelete.js +3 -3
- package/lib/esm/components/AccountRecover/AccountRecover.js +2 -4
- package/lib/esm/components/BroadcastMessages/Message.js +1 -1
- package/lib/esm/components/Categories/prefetchedCategories.js +115 -115
- package/lib/esm/components/ChangeCover/ChangeCover.js +2 -6
- package/lib/esm/components/ChangePicture/ChangePictureDialog/ChangePictureDialog.js +4 -8
- package/lib/esm/components/CheckoutReturnDialog/CheckoutReturnDialog.js +5 -5
- package/lib/esm/components/CommentsFeedObject/CommentsFeedObject.js +1 -1
- package/lib/esm/components/ConsentSolution/ConsentSolution.js +9 -3
- package/lib/esm/components/ConsentSolution/Skeleton.js +1 -1
- package/lib/esm/components/CourseCompletedDialog/CourseCompletedDialog.js +1 -1
- package/lib/esm/components/CourseForm/Edit.js +6 -2
- package/lib/esm/components/Courses/Courses.js +1 -1
- package/lib/esm/components/CreateLiveStreamDialog/LiveStreamSelector/LiveStreamSelector.js +1 -1
- package/lib/esm/components/CustomAdv/Skeleton.js +1 -1
- package/lib/esm/components/EditCourse/Status.js +1 -1
- package/lib/esm/components/EventForm/EventForm.js +2 -2
- package/lib/esm/components/EventLocationWidget/Skeleton.js +1 -1
- package/lib/esm/components/Events/LocationEventsFilter.js +1 -1
- package/lib/esm/components/FeedObject/Actions/Comment/Comment.js +2 -2
- package/lib/esm/components/FeedObject/Activities/ActivitiesMenu/ActivitiesMenu.js +1 -1
- package/lib/esm/components/FeedObject/Activities/RelevantActivities/CommentActivity/CommentActivity.js +1 -1
- package/lib/esm/components/FeedObject/Activities/RelevantActivities/RelevantActivities.js +1 -1
- package/lib/esm/components/FeedObject/Contributors/Contributors.js +1 -1
- package/lib/esm/components/FeedObject/Contributors/Skeleton.js +1 -1
- package/lib/esm/components/GroupForm/GroupForm.js +7 -7
- package/lib/esm/components/GroupInfoWidget/GroupInfoWidget.js +5 -15
- package/lib/esm/components/GroupSettingsIconButton/GroupSettingsIconButton.js +1 -1
- package/lib/esm/components/Incubator/Incubator.js +2 -2
- package/lib/esm/components/IncubatorDetail/IncubatorDetail.js +2 -2
- package/lib/esm/components/IncubatorListWidget/CreateIncubatorDialog/CreateIncubatorDialog.js +2 -2
- package/lib/esm/components/IncubatorListWidget/IncubatorListWidget.js +5 -5
- package/lib/esm/components/IncubatorSuggestionWidget/IncubatorSuggestionWidget.js +1 -1
- package/lib/esm/components/LessonCommentObjects/LessonCommentObjects.js +1 -1
- package/lib/esm/components/LiveStreamForm/LiveStreamForm.js +1 -1
- package/lib/esm/components/LiveStreamRoom/LiveStreamRoom.js +10 -8
- package/lib/esm/components/LiveStreamRoom/LiveStreamVideoConference/LiveStreamVideoConference.js +3 -3
- package/lib/esm/components/LiveStreamRoom/LiveStreamVideoConference/ParticipantTile.js +1 -1
- package/lib/esm/components/LiveStreamRoom/LiveStreamVideoConference/ParticipantTileActions.js +1 -1
- package/lib/esm/components/LoyaltyProgramWidget/LoyaltyProgramWidget.js +1 -1
- package/lib/esm/components/LoyaltyProgramWidget/Skeleton.js +1 -1
- package/lib/esm/components/Notification/CollapsedFor/CollapsedFor.js +3 -1
- package/lib/esm/components/Notification/Comment/Comment.js +3 -3
- package/lib/esm/components/Notification/Contribution/Contribution.js +1 -1
- package/lib/esm/components/Notification/ContributionFollow/ContributionFollow.js +2 -2
- package/lib/esm/components/Notification/Course/Course.js +4 -4
- package/lib/esm/components/Notification/DeletedFor/DeletedFor.js +4 -2
- package/lib/esm/components/Notification/Event/Event.js +4 -4
- package/lib/esm/components/Notification/Group/Group.js +2 -2
- package/lib/esm/components/Notification/IncubatorApproved/IncubatorApproved.js +3 -3
- package/lib/esm/components/Notification/KindlyNoticeFlag/KindlyNoticeFlag.js +3 -1
- package/lib/esm/components/Notification/KindlyNoticeFor/KindlyNoticeFor.js +5 -3
- package/lib/esm/components/Notification/LiveStream/LiveStream.js +3 -3
- package/lib/esm/components/Notification/Mention/Mention.js +2 -2
- package/lib/esm/components/Notification/Notification.js +5 -5
- package/lib/esm/components/Notification/PrivateMessage/PrivateMessage.js +3 -3
- package/lib/esm/components/Notification/UndeletedFor/UndeletedFor.js +1 -1
- package/lib/esm/components/Notification/UserBlocked/UserBlocked.js +6 -2
- package/lib/esm/components/Notification/UserConnection/UserConnection.js +6 -2
- package/lib/esm/components/Notification/UserFollow/UserFollow.js +2 -2
- package/lib/esm/components/Notification/VoteUp/VoteUp.js +2 -2
- package/lib/esm/components/OnBoardingWidget/OnBoardingWidget.js +11 -8
- package/lib/esm/components/OnBoardingWidget/Skeleton.js +1 -1
- package/lib/esm/components/OnBoardingWidget/Steps/App/App.js +9 -25
- package/lib/esm/components/OnBoardingWidget/Steps/Category/Category.js +3 -9
- package/lib/esm/components/PaymentOrder/PaymentOrder.js +1 -1
- package/lib/esm/components/PaymentOrders/PaymentOrders.js +1 -1
- package/lib/esm/components/PaywallsDialog/PaywallsDialog.js +1 -1
- package/lib/esm/components/PlatformWidget/PlatformWidget.js +1 -1
- package/lib/esm/components/PrivateMessageEditor/MessageMediaUploader/index.js +2 -2
- package/lib/esm/components/PrivateMessageSnippets/Skeleton.js +1 -1
- package/lib/esm/components/PrivateMessageThread/PrivateMessageThread.js +1 -1
- package/lib/esm/components/PrivateMessageThread/Skeleton.js +1 -1
- package/lib/esm/components/SnippetNotifications/SnippetNotifications.js +5 -5
- package/lib/esm/components/UserAddPaymentMethodForm/UserAddPaymentMethodForm.js +4 -4
- package/lib/esm/components/UserAutocomplete/UserAutocomplete.js +1 -1
- package/lib/esm/components/UserBillingInfo/UserBillingInfo.js +1 -1
- package/lib/esm/components/UserChangeAddressDialog/UserChangeAddressDialog.js +1 -1
- package/lib/esm/components/UserCounters/UserCounters.js +5 -13
- package/lib/esm/components/UserInfo/UserInfo.js +1 -1
- package/lib/esm/components/UserPaymentMethods/UserPaymentMethods.js +8 -9
- package/lib/esm/components/UserProfileEdit/Section/AccountCredentials.js +1 -1
- package/lib/esm/components/UserProfileEdit/Section/PublicInfo.js +1 -1
- package/lib/esm/shared/ContributionActionsMenu/index.js +3 -9
- package/lib/esm/shared/DateTimeAgo/index.js +1 -1
- package/lib/esm/shared/EmojiPicker/EmojiPicker.d.ts +1 -2
- package/lib/esm/shared/InfiniteScroll/stories/ScrolleableTop.js +1 -1
- package/lib/esm/shared/LessonCommentActionsMenu/index.js +2 -8
- package/lib/esm/shared/Lightbox/BaseLightbox.js +1 -1
- package/lib/esm/shared/MessageChunkUploader/index.js +1 -1
- package/lib/esm/shared/Tags/index.js +1 -1
- package/lib/esm/shared/UpScalingTierBadge/UpScalingTierBadge.d.ts +2 -2
- package/lib/umd/484.js +1 -1
- package/lib/umd/484.js.LICENSE.txt +1 -1
- package/lib/umd/react-ui.js +1 -1
- package/package.json +10 -10
|
@@ -47,8 +47,8 @@ function UserFollowNotification(props) {
|
|
|
47
47
|
/**
|
|
48
48
|
* Renders root object
|
|
49
49
|
*/
|
|
50
|
-
return ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(Root, Object.assign({ id: id, className: (0, classnames_1.default)(classes.root, className, `${constants_1.PREFIX}-${template}`), template: template, isNew: notificationObject.is_new, disableTypography: true, image: (0, jsx_runtime_1.jsx)(react_core_1.Link, Object.assign({}, (!notificationObject.follower.deleted && { to: scRoutingContext.url(react_core_1.SCRoutes.USER_PROFILE_ROUTE_NAME, notificationObject.follower) }), { onClick: notificationObject.follower.deleted ? () => setOpenAlert(true) : null }, { children: (0, jsx_runtime_1.jsx)(UserAvatar_1.default, Object.assign({ hide: !notificationObject.follower.community_badge, smaller: true }, { children: (0, jsx_runtime_1.jsx)(material_1.Avatar, { alt: notificationObject.follower.username, variant: "circular", src: notificationObject.follower.avatar, classes: { root: classes.avatar } }) })) })), primary: (0, jsx_runtime_1.jsxs)(material_1.Typography, Object.assign({ component: "div", color: "inherit", className: classes.followText }, { children: [(0, jsx_runtime_1.jsx)(react_core_1.Link, Object.assign({}, (!notificationObject.follower.deleted && { to: scRoutingContext.url(react_core_1.SCRoutes.USER_PROFILE_ROUTE_NAME, notificationObject.follower) }), { onClick: notificationObject.follower.deleted ? () => setOpenAlert(true) : null, className: classes.username }, { children: notificationObject.follower.username })), ' ', intl.formatMessage(messages.followUser, { b: (
|
|
50
|
+
return ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(Root, Object.assign({ id: id, className: (0, classnames_1.default)(classes.root, className, `${constants_1.PREFIX}-${template}`), template: template, isNew: notificationObject.is_new, disableTypography: true, image: (0, jsx_runtime_1.jsx)(react_core_1.Link, Object.assign({}, (!notificationObject.follower.deleted && { to: scRoutingContext.url(react_core_1.SCRoutes.USER_PROFILE_ROUTE_NAME, notificationObject.follower) }), { onClick: notificationObject.follower.deleted ? () => setOpenAlert(true) : null }, { children: (0, jsx_runtime_1.jsx)(UserAvatar_1.default, Object.assign({ hide: !notificationObject.follower.community_badge, smaller: true }, { children: (0, jsx_runtime_1.jsx)(material_1.Avatar, { alt: notificationObject.follower.username, variant: "circular", src: notificationObject.follower.avatar, classes: { root: classes.avatar } }) })) })), primary: (0, jsx_runtime_1.jsxs)(material_1.Typography, Object.assign({ component: "div", color: "inherit", className: classes.followText }, { children: [(0, jsx_runtime_1.jsx)(react_core_1.Link, Object.assign({}, (!notificationObject.follower.deleted && { to: scRoutingContext.url(react_core_1.SCRoutes.USER_PROFILE_ROUTE_NAME, notificationObject.follower) }), { onClick: notificationObject.follower.deleted ? () => setOpenAlert(true) : null, className: classes.username }, { children: notificationObject.follower.username })), ' ', intl.formatMessage(messages.followUser, { b: (chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks }, "ui.notification.userFollow.followUser.b") })] })), secondary: (template === types_1.SCNotificationObjectTemplateType.DETAIL || template === types_1.SCNotificationObjectTemplateType.SNIPPET) && ((0, jsx_runtime_1.jsx)(DateTimeAgo_1.default, { date: notificationObject.active_at, className: classes.activeAt })), footer: template === types_1.SCNotificationObjectTemplateType.TOAST && ((0, jsx_runtime_1.jsxs)(material_1.Stack, Object.assign({ direction: "row", justifyContent: "space-between", alignItems: "center", spacing: 2 }, { children: [(0, jsx_runtime_1.jsx)(DateTimeAgo_1.default, { date: notificationObject.active_at }), (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ color: "primary", component: "div" }, { children: (0, jsx_runtime_1.jsx)(react_core_1.Link, Object.assign({}, (!notificationObject.follower.deleted && {
|
|
51
51
|
to: scRoutingContext.url(react_core_1.SCRoutes.USER_PROFILE_ROUTE_NAME, notificationObject.follower)
|
|
52
|
-
}), { onClick: notificationObject.follower.deleted ? () => setOpenAlert(true) : null }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.userToastNotifications.goToProfile", defaultMessage:
|
|
52
|
+
}), { onClick: notificationObject.follower.deleted ? () => setOpenAlert(true) : null }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.userToastNotifications.goToProfile", defaultMessage: "ui.userToastNotifications.goToProfile" }) })) }))] }))) }, rest)), openAlert && (0, jsx_runtime_1.jsx)(UserDeletedSnackBar_1.default, { open: openAlert, handleClose: () => setOpenAlert(false) })] }));
|
|
53
53
|
}
|
|
54
54
|
exports.default = UserFollowNotification;
|
|
@@ -54,7 +54,7 @@ function VoteUpNotification(props) {
|
|
|
54
54
|
*/
|
|
55
55
|
return ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(Root, Object.assign({ id: id, className: (0, classnames_1.default)(classes.root, className, `${constants_1.PREFIX}-${template}`), template: template, isNew: notificationObject.is_new, disableTypography: true, image: (0, jsx_runtime_1.jsx)(react_core_1.Link, Object.assign({}, (!notificationObject.user.deleted && { to: scRoutingContext.url(react_core_1.SCRoutes.USER_PROFILE_ROUTE_NAME, notificationObject.user) }), { onClick: notificationObject.user.deleted ? () => setOpenAlert(true) : null }, { children: (0, jsx_runtime_1.jsx)(UserAvatar_1.default, Object.assign({ hide: !notificationObject.user.community_badge, smaller: true }, { children: (0, jsx_runtime_1.jsx)(material_1.Avatar, { alt: notificationObject.user.username, variant: "circular", src: notificationObject.user.avatar, classes: { root: classes.avatar } }) })) })), primary: (0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(react_core_1.Link, Object.assign({}, (!notificationObject.user.deleted && { to: scRoutingContext.url(react_core_1.SCRoutes.USER_PROFILE_ROUTE_NAME, notificationObject.user) }), { onClick: notificationObject.user.deleted ? () => setOpenAlert(true) : null, className: classes.username }, { children: notificationObject.user.username })), ' ', intl.formatMessage(messages.appreciated, {
|
|
56
56
|
username: notificationObject.user.username,
|
|
57
|
-
b: (
|
|
58
|
-
})] }), secondary: (0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(react_core_1.Link, Object.assign({ to: scRoutingContext.url(react_core_1.SCRoutes[`${contributionType.toUpperCase()}_ROUTE_NAME`], (0, contribution_1.getRouteData)(notificationObject[contributionType])) }, { children: (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ variant: "body2", className: classes.contributionText, component:
|
|
57
|
+
b: (chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks }, "ui.notification.voteUp.appreciated.b")
|
|
58
|
+
})] }), secondary: (0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(react_core_1.Link, Object.assign({ to: scRoutingContext.url(react_core_1.SCRoutes[`${contributionType.toUpperCase()}_ROUTE_NAME`], (0, contribution_1.getRouteData)(notificationObject[contributionType])) }, { children: (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ variant: "body2", className: classes.contributionText, component: "div" }, { children: (0, contribution_1.getContributionSnippet)(notificationObject[contributionType]) })) })), (template === notification_1.SCNotificationObjectTemplateType.DETAIL || template === notification_1.SCNotificationObjectTemplateType.SNIPPET) && ((0, jsx_runtime_1.jsx)(DateTimeAgo_1.default, { date: notificationObject.active_at, className: classes.activeAt }))] }), footer: template === notification_1.SCNotificationObjectTemplateType.TOAST && ((0, jsx_runtime_1.jsxs)(material_1.Stack, Object.assign({ direction: "row", justifyContent: "space-between", alignItems: "center", spacing: 2 }, { children: [(0, jsx_runtime_1.jsx)(DateTimeAgo_1.default, { date: notificationObject.active_at }), (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ color: "primary", component: "div" }, { children: (0, jsx_runtime_1.jsx)(react_core_1.Link, Object.assign({ to: scRoutingContext.url((0, contribution_1.getContributionRouteName)(contribution), (0, contribution_1.getRouteData)(contribution)) }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.userToastNotifications.viewContribution", defaultMessage: "ui.userToastNotifications.viewContribution" }) })) }))] }))) }, rest)), openAlert && (0, jsx_runtime_1.jsx)(UserDeletedSnackBar_1.default, { open: openAlert, handleClose: () => setOpenAlert(false) })] }));
|
|
59
59
|
}
|
|
60
60
|
exports.default = VoteUpNotification;
|
|
@@ -299,23 +299,26 @@ const OnBoardingWidget = (inProps) => {
|
|
|
299
299
|
}
|
|
300
300
|
return content;
|
|
301
301
|
};
|
|
302
|
+
const handleAccordionChange = (0, react_1.useCallback)(() => {
|
|
303
|
+
setExpanded((prev) => !prev);
|
|
304
|
+
}, [setExpanded]);
|
|
302
305
|
if (!isAdmin || !showOnBoarding) {
|
|
303
306
|
return (0, jsx_runtime_1.jsx)(HiddenPlaceholder_1.default, {});
|
|
304
307
|
}
|
|
305
|
-
return ((0, jsx_runtime_1.jsx)(Root, Object.assign({ className: (0, classnames_1.default)(classes.root, className) }, rest, { children: (0, jsx_runtime_1.jsxs)(AccordionRoot, Object.assign({ defaultExpanded: true, className: classes.accordionRoot, expanded: expanded }, { children: [(0, jsx_runtime_1.jsx)(material_1.AccordionSummary, Object.assign({ expandIcon: (0, jsx_runtime_1.jsx)(ActionsButton_1.default, { isExpanded: expanded, onExpandChange: handleExpand, onHideOnBoarding: handlePreferencesUpdate }), "aria-controls": "accordion", id: "onBoarding-accordion" }, { children: (0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: expanded ? ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [!isMobile ? ((0, jsx_runtime_1.jsx)(material_1.CardMedia, { className: classes.logo, component: "img", src: header_1.default })) : ((0, jsx_runtime_1.jsxs)(material_1.Typography, Object.assign({ variant: "h4" }, { children: [(0, jsx_runtime_1.jsx)(material_1.Icon, Object.assign({ color: "secondary", fontSize: "medium" }, { children: "ai_stars" })), (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.accordion.expanded.title.mobile", defaultMessage: "ui.onBoardingWidget.accordion.expanded.title.mobile", values: {
|
|
306
|
-
b: (chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks })
|
|
308
|
+
return ((0, jsx_runtime_1.jsx)(Root, Object.assign({ className: (0, classnames_1.default)(classes.root, className) }, rest, { children: (0, jsx_runtime_1.jsxs)(AccordionRoot, Object.assign({ defaultExpanded: true, className: classes.accordionRoot, expanded: expanded, onChange: handleAccordionChange }, { children: [(0, jsx_runtime_1.jsx)(material_1.AccordionSummary, Object.assign({ expandIcon: (0, jsx_runtime_1.jsx)(ActionsButton_1.default, { isExpanded: expanded, onExpandChange: handleExpand, onHideOnBoarding: handlePreferencesUpdate }), "aria-controls": "accordion", id: "onBoarding-accordion", component: "div" }, { children: (0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: expanded ? ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [!isMobile ? ((0, jsx_runtime_1.jsx)(material_1.CardMedia, { className: classes.logo, component: "img", src: header_1.default })) : ((0, jsx_runtime_1.jsxs)(material_1.Typography, Object.assign({ variant: "h4" }, { children: [(0, jsx_runtime_1.jsx)(material_1.Icon, Object.assign({ color: "secondary", fontSize: "medium" }, { children: "ai_stars" })), (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.accordion.expanded.title.mobile", defaultMessage: "ui.onBoardingWidget.accordion.expanded.title.mobile", values: {
|
|
309
|
+
b: (chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks }, "ui.onBoardingWidget.accordion.expanded.title.mobile.b")
|
|
307
310
|
} })] }))), (0, jsx_runtime_1.jsxs)(material_1.Box, Object.assign({ className: classes.intro }, { children: [!isMobile && ((0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ variant: "h4" }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.accordion.expanded.title", defaultMessage: "ui.onBoardingWidget.accordion.expanded.title" }) }))), (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ variant: "h5" }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.accordion.expanded.subtitle", defaultMessage: "ui.onBoardingWidget.accordion.expanded.subtitle" }) })), (0, jsx_runtime_1.jsx)(material_1.Typography, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.accordion.expanded.summary", defaultMessage: "ui.onBoardingWidget.accordion.expanded.summary", values: {
|
|
308
|
-
b: (chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks }),
|
|
309
|
-
icon: (
|
|
311
|
+
b: (chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks }, "ui.onBoardingWidget.accordion.expanded.summary.b"),
|
|
312
|
+
icon: (chunks) => (0, jsx_runtime_1.jsx)(material_1.Icon, { children: chunks }, "ui.onBoardingWidget.accordion.expanded.summary.icon")
|
|
310
313
|
} }) })] }))] })) : ((0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ variant: "body1" }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.accordion.collapsed", defaultMessage: "ui.onBoardingWidget.accordion.collapsed", values: {
|
|
311
|
-
b: (chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks }),
|
|
312
|
-
icon: (
|
|
314
|
+
b: (chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks }, "ui.onBoardingWidget.accordion.collapsed.b"),
|
|
315
|
+
icon: (chunks) => ((0, jsx_runtime_1.jsx)(material_1.Icon, Object.assign({ color: "secondary", fontSize: "medium" }, { children: chunks }), "ui.onBoardingWidget.accordion.collapsed.icon"))
|
|
313
316
|
} }) }))) }) })), (0, jsx_runtime_1.jsx)(material_1.AccordionDetails, { children: (0, jsx_runtime_1.jsx)(Widget_1.default, Object.assign({ className: classes.content, elevation: 0 }, { children: loading ? ((0, jsx_runtime_1.jsx)(Skeleton_1.default, {})) : ((0, jsx_runtime_1.jsxs)(material_1.CardContent, { children: [(0, jsx_runtime_1.jsx)(material_1.List, Object.assign({ className: isMobile ? classes.stepsMobile : classes.steps }, { children: steps === null || steps === void 0 ? void 0 : steps.map((step) => ((0, jsx_runtime_1.jsx)(material_1.ListItem, { children: isMobile ? ((0, jsx_runtime_1.jsx)(material_1.Chip, { size: "small", label: (0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: `ui.onBoardingWidget.${step.step}`, defaultMessage: `ui.onBoardingWidget.${step.step}` }), ' ', step.status === types_1.SCOnBoardingStepStatusType.COMPLETED && ((0, jsx_runtime_1.jsx)(material_1.Icon, Object.assign({ color: (step === null || step === void 0 ? void 0 : step.status) === types_1.SCOnBoardingStepStatusType.COMPLETED && (step === null || step === void 0 ? void 0 : step.step) !== (_step === null || _step === void 0 ? void 0 : _step.step) ? 'success' : 'inherit' }, { children: "check" })))] }), onClick: () => handleChange(step), variant: step.step === (_step === null || _step === void 0 ? void 0 : _step.step) ? 'filled' : 'outlined', color: step.status === types_1.SCOnBoardingStepStatusType.COMPLETED ? 'success' : 'default' })) : ((0, jsx_runtime_1.jsxs)(material_1.ListItemButton, Object.assign({ onClick: () => handleChange(step), selected: (step === null || step === void 0 ? void 0 : step.step) === (_step === null || _step === void 0 ? void 0 : _step.step) }, { children: [(0, jsx_runtime_1.jsx)(material_1.ListItemIcon, { children: (0, jsx_runtime_1.jsx)(material_1.Checkbox, { edge: "start", checked: step.status === types_1.SCOnBoardingStepStatusType.COMPLETED, tabIndex: -1, disableRipple: true, slotProps: {
|
|
314
317
|
input: {
|
|
315
318
|
'aria-labelledby': `${step.step}`
|
|
316
319
|
}
|
|
317
320
|
}, size: "small" }) }), (0, jsx_runtime_1.jsx)(material_1.ListItemText, { primary: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: `ui.onBoardingWidget.${step.step}`, defaultMessage: `ui.onBoardingWidget.${step.step}` }) })] }))) }, step.id))) })), (0, jsx_runtime_1.jsxs)(material_1.Box, Object.assign({ className: classes.stepContent }, { children: [(0, jsx_runtime_1.jsx)(material_1.Fade, Object.assign({ in: true, timeout: 2400 }, { children: (0, jsx_runtime_1.jsx)(material_1.Box, { children: getStepContent() }) })), showNoCategoriesModal && ((0, jsx_runtime_1.jsx)(BaseDialog_1.default, Object.assign({ title: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.ai.no.categories", defaultMessage: "ui.onBoardingWidget.ai.no.categories" }), DialogContentProps: { dividers: false }, open: showNoCategoriesModal, onClose: () => setShowNoCategoriesModal(false), actions: (0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ color: "secondary", onClick: () => setShowNoCategoriesModal(false) }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.ai.no.categories.cancel", defaultMessage: "ui.onBoardingWidget.ai.no.categories.cancel" }) })) }, { children: (0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ color: "primary", onClick: handleCategoriesClick, startIcon: (0, jsx_runtime_1.jsx)(material_1.Icon, Object.assign({ fontSize: "small" }, { children: "edit" })) }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.ai.no.categories.link", defaultMessage: "ui.onBoardingWidget.ai.no.categories.link" }) })) }))), showCategoriesWarningModal && ((0, jsx_runtime_1.jsx)(DialogRoot, Object.assign({ className: classes.dialogRoot, title: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.ai.categories.warning.title", defaultMessage: "ui.onBoardingWidget.ai.categories.warning.title" }), DialogContentProps: { dividers: false }, open: showCategoriesWarningModal, onClose: () => setShowWarningCategoriesModal(false), actions: (0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ size: "small", variant: "outlined", color: "primary", onClick: () => setShowWarningCategoriesModal(false) }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.ai.categories.warning.button.close", defaultMessage: "ui.onBoardingWidget.ai.categories.warning.button.close" }) })), (0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ size: "small", variant: "contained", color: "secondary", onClick: () => startStep(types_1.SCOnBoardingStepIdType.CATEGORIES), endIcon: (0, jsx_runtime_1.jsx)(material_1.Icon, Object.assign({ fontSize: "small" }, { children: "magic_wand" })) }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.ai.categories.warning.button.generate", defaultMessage: "ui.onBoardingWidget.ai.categories.warning.button.generate" }) }))] }) }, { children: (0, jsx_runtime_1.jsxs)(material_1.Typography, Object.assign({ className: classes.dialogContent }, { children: [(0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.ai.categories.warning.info", defaultMessage: "ui.onBoardingWidget.ai.categories.warning.info" }), (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.ai.categories.warning.confirm", defaultMessage: "ui.onBoardingWidget.ai.categories.warning.confirm", values: {
|
|
318
|
-
b: (chunks) => (0, jsx_runtime_1.jsx)("b", { children: chunks })
|
|
321
|
+
b: (chunks) => (0, jsx_runtime_1.jsx)("b", { children: chunks }, "ui.onBoardingWidget.ai.categories.warning.confirm.b")
|
|
319
322
|
} })] })) })))] }))] })) })) })] })) })));
|
|
320
323
|
};
|
|
321
324
|
exports.default = OnBoardingWidget;
|
|
@@ -16,6 +16,6 @@ function OnBoardingWidgetSkeleton() {
|
|
|
16
16
|
const theme = (0, material_1.useTheme)();
|
|
17
17
|
const isMobile = (0, material_1.useMediaQuery)(theme.breakpoints.down('md'));
|
|
18
18
|
const steps = Array(isMobile ? 3 : 5).fill(null);
|
|
19
|
-
return ((0, jsx_runtime_1.jsxs)(Root, Object.assign({ className: classes.root }, { children: [(0, jsx_runtime_1.jsx)(material_1.Box, Object.assign({ className: classes.menu }, { children: isMobile ? ((0, jsx_runtime_1.jsx)(material_1.Box, Object.assign({ sx: { display: 'flex', justifyContent: 'space-evenly' } }, { children: steps.map((_, index) => ((0, jsx_runtime_1.jsx)(material_1.Chip, { label: (0, jsx_runtime_1.jsx)(material_1.Skeleton, { variant: "text", width: 80 }), variant: "outlined" }, index))) }))) : ((0, jsx_runtime_1.jsx)(material_1.List, { children: steps.map((_, index) => ((0, jsx_runtime_1.jsx)(material_1.ListItem, { children: (0, jsx_runtime_1.jsxs)(material_1.ListItemButton, { children: [(0, jsx_runtime_1.jsx)(material_1.ListItemIcon, { children: (0, jsx_runtime_1.jsx)(material_1.Skeleton, { variant: "rectangular", width: 20, height: 20 }) }), (0, jsx_runtime_1.jsx)(material_1.ListItemText, { primary: (0, jsx_runtime_1.jsx)(material_1.Skeleton, { variant: "text", width: 100 }) })] }) }, index))) })) })), (0, jsx_runtime_1.jsxs)(material_1.Box, Object.assign({ className: classes.content }, { children: [(0, jsx_runtime_1.jsx)(material_1.Skeleton, { variant: "text", width:
|
|
19
|
+
return ((0, jsx_runtime_1.jsxs)(Root, Object.assign({ className: classes.root }, { children: [(0, jsx_runtime_1.jsx)(material_1.Box, Object.assign({ className: classes.menu }, { children: isMobile ? ((0, jsx_runtime_1.jsx)(material_1.Box, Object.assign({ sx: { display: 'flex', justifyContent: 'space-evenly' } }, { children: steps.map((_, index) => ((0, jsx_runtime_1.jsx)(material_1.Chip, { label: (0, jsx_runtime_1.jsx)(material_1.Skeleton, { variant: "text", width: 80 }), variant: "outlined" }, index))) }))) : ((0, jsx_runtime_1.jsx)(material_1.List, { children: steps.map((_, index) => ((0, jsx_runtime_1.jsx)(material_1.ListItem, { children: (0, jsx_runtime_1.jsxs)(material_1.ListItemButton, { children: [(0, jsx_runtime_1.jsx)(material_1.ListItemIcon, { children: (0, jsx_runtime_1.jsx)(material_1.Skeleton, { variant: "rectangular", width: 20, height: 20 }) }), (0, jsx_runtime_1.jsx)(material_1.ListItemText, { primary: (0, jsx_runtime_1.jsx)(material_1.Skeleton, { variant: "text", width: 100 }) })] }) }, index))) })) })), (0, jsx_runtime_1.jsxs)(material_1.Box, Object.assign({ className: classes.content }, { children: [(0, jsx_runtime_1.jsx)(material_1.Skeleton, { variant: "text", width: "20%", height: 40 }), (0, jsx_runtime_1.jsx)(material_1.Skeleton, { variant: "text", width: "80%", height: 20 }), (0, jsx_runtime_1.jsx)(material_1.Skeleton, { variant: "text", width: "70%", height: 20 }), (0, jsx_runtime_1.jsx)(material_1.Skeleton, { variant: "text", width: "60%", height: 20 }), (0, jsx_runtime_1.jsx)(material_1.Skeleton, { variant: "rectangular", width: 100, height: 36, style: { borderRadius: '20px', alignSelf: 'center', marginTop: 24 } })] }))] })));
|
|
20
20
|
}
|
|
21
21
|
exports.default = OnBoardingWidgetSkeleton;
|
|
@@ -38,37 +38,21 @@ function App(inProps) {
|
|
|
38
38
|
// STATE
|
|
39
39
|
const [tab, setTab] = (0, react_1.useState)(0);
|
|
40
40
|
// HANDLERS
|
|
41
|
-
const handleChange = (
|
|
41
|
+
const handleChange = (_event, newValue) => {
|
|
42
42
|
setTab(newValue);
|
|
43
43
|
};
|
|
44
44
|
return ((0, jsx_runtime_1.jsxs)(Root, Object.assign({ className: (0, classnames_1.default)(classes.root, className) }, { children: [(0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ variant: "h4", className: classes.title }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.step.app.title", defaultMessage: "ui.onBoardingWidget.step.app.title" }) })), (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ className: classes.summary }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.step.app.summary", defaultMessage: "ui.onBoardingWidget.step.app.summary" }) })), (0, jsx_runtime_1.jsxs)(material_1.Tabs, Object.assign({ className: classes.tabs, value: tab, onChange: handleChange, centered: true, variant: "fullWidth", indicatorColor: "primary" }, { children: [(0, jsx_runtime_1.jsx)(material_1.Tab, { label: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.step.app.tab.android", defaultMessage: "ui.onBoardingWidget.step.app.tab.android" }) }), (0, jsx_runtime_1.jsx)(material_1.Tab, { label: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.step.app.tab.ios", defaultMessage: "ui.onBoardingWidget.step.app.tab.ios" }) })] })), (0, jsx_runtime_1.jsxs)(material_1.Box, Object.assign({ className: classes.tabContent }, { children: [tab === 0 && ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ className: classes.summary }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.step.app.android", defaultMessage: "ui.onBoardingWidget.step.app.android" }) })), (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ className: classes.step }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.step.app.android.a", defaultMessage: "ui.onBoardingWidget.step.app.android.a", values: {
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
icon: (...chunks) => (0, jsx_runtime_1.jsx)(material_1.Icon, Object.assign({ fontSize: "medium" }, { children: chunks })),
|
|
48
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-ignore
|
|
49
|
-
// @ts-ignore
|
|
50
|
-
b: (...chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks })
|
|
45
|
+
icon: (chunks) => ((0, jsx_runtime_1.jsx)(material_1.Icon, Object.assign({ fontSize: "medium" }, { children: chunks }), "ui.onBoardingWidget.step.app.android.a.icon")),
|
|
46
|
+
b: (chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks }, "ui.onBoardingWidget.step.app.android.a.b")
|
|
51
47
|
} }) })), (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ className: classes.step }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.step.app.android.b", defaultMessage: "ui.onBoardingWidget.step.app.android.b", values: {
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
icon: (...chunks) => (0, jsx_runtime_1.jsx)(material_1.Icon, Object.assign({ fontSize: "medium" }, { children: chunks })),
|
|
55
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-ignore
|
|
56
|
-
// @ts-ignore
|
|
57
|
-
b: (...chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks })
|
|
48
|
+
icon: (chunks) => ((0, jsx_runtime_1.jsx)(material_1.Icon, Object.assign({ fontSize: "medium" }, { children: chunks }), "ui.onBoardingWidget.step.app.android.b.icon")),
|
|
49
|
+
b: (chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks }, "ui.onBoardingWidget.step.app.android.b.b")
|
|
58
50
|
} }) })), (0, jsx_runtime_1.jsx)(material_1.CardMedia, { className: classes.imageAndroid, component: "img", src: android_1.default })] })), tab === 1 && ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ className: classes.summary }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.step.app.ios", defaultMessage: "ui.onBoardingWidget.step.app.ios" }) })), (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ className: classes.step }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.step.app.ios.a", defaultMessage: "ui.onBoardingWidget.step.app.ios.a", values: {
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
icon: (...chunks) => (0, jsx_runtime_1.jsx)(material_1.Icon, Object.assign({ fontSize: "medium" }, { children: chunks })),
|
|
62
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-ignore
|
|
63
|
-
// @ts-ignore
|
|
64
|
-
b: (...chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks })
|
|
51
|
+
icon: (chunks) => ((0, jsx_runtime_1.jsx)(material_1.Icon, Object.assign({ fontSize: "medium" }, { children: chunks }), "ui.onBoardingWidget.step.app.ios.a.icon")),
|
|
52
|
+
b: (chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks }, "ui.onBoardingWidget.step.app.ios.a.b")
|
|
65
53
|
} }) })), (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ className: classes.step }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.step.app.ios.b", defaultMessage: "ui.onBoardingWidget.step.app.ios.b", values: {
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
icon: (...chunks) => (0, jsx_runtime_1.jsx)(material_1.Icon, Object.assign({ fontSize: "medium" }, { children: chunks })),
|
|
69
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-ignore
|
|
70
|
-
// @ts-ignore
|
|
71
|
-
b: (...chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks })
|
|
54
|
+
icon: (chunks) => ((0, jsx_runtime_1.jsx)(material_1.Icon, Object.assign({ fontSize: "medium" }, { children: chunks }), "ui.onBoardingWidget.step.app.ios.b.icon")),
|
|
55
|
+
b: (chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks }, "ui.onBoardingWidget.step.app.ios.b.b")
|
|
72
56
|
} }) })), (0, jsx_runtime_1.jsx)(material_1.CardMedia, { className: classes.image, component: "img", src: ios_1.default })] })), (0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ className: classes.button, size: "small", variant: "outlined", color: "secondary", onClick: onCompleteAction, disabled: (step === null || step === void 0 ? void 0 : step.status) === types_1.SCOnBoardingStepStatusType.COMPLETED || (step === null || step === void 0 ? void 0 : step.status) === types_1.SCOnBoardingStepStatusType.IN_PROGRESS }, { children: "Ok!" }))] }))] })));
|
|
73
57
|
}
|
|
74
58
|
exports.default = App;
|
|
@@ -90,15 +90,9 @@ function Category(inProps) {
|
|
|
90
90
|
return message;
|
|
91
91
|
}, [progress]);
|
|
92
92
|
return ((0, jsx_runtime_1.jsxs)(Root, Object.assign({ className: (0, classnames_1.default)(classes.root, className) }, { children: [(0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ variant: "h4", className: classes.title }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.categories", defaultMessage: "ui.onBoardingWidget.categories" }) })), (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ className: classes.summary }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.step.category.summary", defaultMessage: "ui.onBoardingWidget.step.category.summary" }) })), (step === null || step === void 0 ? void 0 : step.status) !== types_1.SCOnBoardingStepStatusType.IN_PROGRESS && ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(material_1.Typography, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.step.category.generation.steps", defaultMessage: "ui.onBoardingWidget.step.category.generation.steps", values: {
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-ignore
|
|
97
|
-
// @ts-ignore
|
|
98
|
-
iconB: (...chunks) => (0, jsx_runtime_1.jsx)(CircledLetter, { letter: "b", statement: chunks }),
|
|
99
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-ignore
|
|
100
|
-
// @ts-ignore
|
|
101
|
-
iconC: (...chunks) => (0, jsx_runtime_1.jsx)(CircledLetter, { letter: "c", statement: chunks })
|
|
93
|
+
iconA: (chunks) => (0, jsx_runtime_1.jsx)(CircledLetter, { letter: "a", statement: chunks }, "ui.onBoardingWidget.step.category.generation.steps.iconA"),
|
|
94
|
+
iconB: (chunks) => (0, jsx_runtime_1.jsx)(CircledLetter, { letter: "b", statement: chunks }, "ui.onBoardingWidget.step.category.generation.steps.iconB"),
|
|
95
|
+
iconC: (chunks) => (0, jsx_runtime_1.jsx)(CircledLetter, { letter: "c", statement: chunks }, "ui.onBoardingWidget.step.category.generation.steps.iconC")
|
|
102
96
|
} }) }), (0, jsx_runtime_1.jsx)(material_1.CardMedia, { className: classes.image, component: "img", src: categoryA_1.default }), (0, jsx_runtime_1.jsx)(material_1.CardMedia, { className: classes.image, component: "img", src: categoryB_1.default })] })), (0, jsx_runtime_1.jsx)(material_1.Box, Object.assign({ component: "span", className: classes.action }, { children: (step === null || step === void 0 ? void 0 : step.status) === types_1.SCOnBoardingStepStatusType.COMPLETED ? ((0, jsx_runtime_1.jsx)(material_1.Alert, Object.assign({ severity: "success" }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.onBoardingWidget.step.categories.success", defaultMessage: "ui.onBoardingWidget.step.categories.success" }) }))) : (step === null || step === void 0 ? void 0 : step.status) === types_1.SCOnBoardingStepStatusType.IN_PROGRESS ? ((0, jsx_runtime_1.jsxs)(material_1.Box, Object.assign({ className: classes.progress }, { children: [(0, jsx_runtime_1.jsx)(react_lottie_player_1.Player, { autoplay: true, loop: true, src: category_progress_json_1.default, className: classes.animationProgress, controls: false }), (0, jsx_runtime_1.jsx)(ProgressBar_1.default, { value: progress, hideBar: true, loadingMessage: (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ variant: "h4" }, { children: getLoadingMessage })) })] }))) : ((0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ size: "small", variant: "contained", color: "secondary", onClick: handleCategoriesCreation, endIcon: (0, jsx_runtime_1.jsx)(material_1.Icon, { children: hover ? 'ai_stars' : 'magic_wand' }), onMouseEnter: () => setHover(true), onMouseLeave: () => setHover(false) }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { defaultMessage: "ui.onBoardingWidget.step.category.button", id: "ui.onBoardingWidget.step.category.button" }) }))) }))] })));
|
|
103
97
|
}
|
|
104
98
|
exports.default = Category;
|
|
@@ -75,6 +75,6 @@ function PaymentOrder(inProps) {
|
|
|
75
75
|
hour: 'numeric',
|
|
76
76
|
minute: 'numeric'
|
|
77
77
|
})
|
|
78
|
-
} }) })), (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ variant: "body2", color: "textSecondary" }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.paymentOrder.price", defaultMessage: "ui.paymentOrder.price", values: { price: (0, payment_1.getConvertedAmount)(scPaymentOrder.payment_price) } }) })), (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ variant: "body2", color: "textSecondary", component: "span" }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.paymentOrder.status", defaultMessage: "ui.paymentOrder.status" }) })), (0, jsx_runtime_1.jsx)(material_1.Chip, { className: classes.status, variant:
|
|
78
|
+
} }) })), (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ variant: "body2", color: "textSecondary" }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.paymentOrder.price", defaultMessage: "ui.paymentOrder.price", values: { price: (0, payment_1.getConvertedAmount)(scPaymentOrder.payment_price) } }) })), (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ variant: "body2", color: "textSecondary", component: "span" }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.paymentOrder.status", defaultMessage: "ui.paymentOrder.status" }) })), (0, jsx_runtime_1.jsx)(material_1.Chip, { className: classes.status, variant: "outlined", label: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.paymentOrder.status.paid", defaultMessage: "ui.paymentOrder.status.paid" }), color: "success", size: "small" }), (0, jsx_runtime_1.jsx)("br", {}), scPaymentOrder && !hidePaymentOrderPdfButton && ((0, jsx_runtime_1.jsx)(PaymentOrderPdfButton_1.default, Object.assign({ paymentOrder: scPaymentOrder, label: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.paymentOrder.ticket.view", defaultMessage: "ui.paymentOrder.ticket.view" }) }, PaymentOrderPdfButtonComponentProps)))] }))] })));
|
|
79
79
|
}
|
|
80
80
|
exports.default = PaymentOrder;
|
|
@@ -270,6 +270,6 @@ function PaymentOrders(inProps) {
|
|
|
270
270
|
hour: 'numeric',
|
|
271
271
|
minute: 'numeric'
|
|
272
272
|
})
|
|
273
|
-
: '-' })), (0, jsx_runtime_1.jsx)(material_1.TableCell, Object.assign({ scope: "row" }, { children: (0, jsx_runtime_1.jsx)(material_1.Chip, { variant:
|
|
273
|
+
: '-' })), (0, jsx_runtime_1.jsx)(material_1.TableCell, Object.assign({ scope: "row" }, { children: (0, jsx_runtime_1.jsx)(material_1.Chip, { variant: "outlined", label: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.paymentOrders.status.paid", defaultMessage: "ui.paymentOrders.status.paid" }), color: "success", size: "small" }) })), (0, jsx_runtime_1.jsx)(material_1.TableCell, Object.assign({ scope: "row" }, { children: (0, jsx_runtime_1.jsxs)(material_1.Stack, Object.assign({ direction: "row", justifyContent: "left", alignItems: "center", spacing: 2 }, { children: [order.content_type === types_1.SCContentType.EVENT && (0, jsx_runtime_1.jsx)(PaymentOrderPdfButton_1.default, { paymentOrder: order }), Boolean(!order.paid && order.billing_reason === 'subscription_create') && ((0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ size: "small", variant: "contained", disabled: true }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.paymentOrders.pay", defaultMessage: "ui.paymentOrders.pay" }) })))] })) }))] }, index))), orders.length < 1 && ((0, jsx_runtime_1.jsx)(material_1.TableRow, { children: (0, jsx_runtime_1.jsx)(material_1.TableCell, Object.assign({ align: "left", colSpan: 6 }, { children: (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ variant: "body2" }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.paymentOrders.noOrders", defaultMessage: "ui.paymentOrders.noOrders" }) })) })) })), hasMore && (0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: skeleton() })] })] })) }))) : ((0, jsx_runtime_1.jsx)(material_1.CircularProgress, {})) }))] })));
|
|
274
274
|
}
|
|
275
275
|
exports.default = PaymentOrders;
|
|
@@ -38,7 +38,7 @@ function PaywallsDialog(inProps) {
|
|
|
38
38
|
return null;
|
|
39
39
|
}
|
|
40
40
|
return ((0, jsx_runtime_1.jsx)(Root, Object.assign({ maxWidth: "sm", fullWidth: true, title: (PaywallsComponentProps && ((_a = PaywallsComponentProps.prefetchedPaymentContentStatus) === null || _a === void 0 ? void 0 : _a.payment_order)) ||
|
|
41
|
-
(PaywallsComponentProps.content && PaywallsComponentProps.content.payment_order) ? ((0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.paywallsDialog.title.purchased", defaultMessage: "ui.paywallsDialog.title.purchased" })) : ((0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.paywallsDialog.title", defaultMessage: "ui.paywallsDialog.title" })), scroll:
|
|
41
|
+
(PaywallsComponentProps.content && PaywallsComponentProps.content.payment_order) ? ((0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.paywallsDialog.title.purchased", defaultMessage: "ui.paywallsDialog.title.purchased" })) : ((0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.paywallsDialog.title", defaultMessage: "ui.paywallsDialog.title" })), scroll: "paper", open: true }, (disableInitialTransition ? { TransitionComponent: NoTransition } : { TransitionComponent: Transition }), { className: (0, classnames_1.default)(classes.root, className), slots: {
|
|
42
42
|
transition: Transition
|
|
43
43
|
}, DialogContentProps: { dividers: false } }, rest, { children: (0, jsx_runtime_1.jsx)(Paywalls_1.default, Object.assign({}, PaywallsComponentProps)) })));
|
|
44
44
|
}
|
|
@@ -293,7 +293,7 @@ function PlatformWidget(inProps) {
|
|
|
293
293
|
/**
|
|
294
294
|
* Render tutorial
|
|
295
295
|
*/
|
|
296
|
-
const tutorial = ((0, jsx_runtime_1.jsxs)(material_1.Grid, Object.assign({ container: true, width: "100%", spacing: isAdmin ? 1 : 3, justifyContent: "center", className: classes.tutorial }, { children: [!isTutorialOpen && ((0, jsx_runtime_1.jsx)(material_1.Grid, Object.assign({ size: "auto", alignItems: "center", justifyContent: "center" }, { children: (0, jsx_runtime_1.jsx)(material_1.IconButton, Object.assign({ size: "medium", onClick: handleOpenTutorial }, { children: (0, jsx_runtime_1.jsx)(material_1.Icon, { children: "info" }) })) }))), (0, jsx_runtime_1.jsx)(material_1.Collapse, Object.assign({ in: isTutorialOpen, className: classes.tutorialContent }, { children: isTutorialOpen && ((0, jsx_runtime_1.jsxs)(material_1.Grid, Object.assign({ size: "auto" }, { children: [(0, jsx_runtime_1.jsxs)(material_1.Typography, Object.assign({ variant:
|
|
296
|
+
const tutorial = ((0, jsx_runtime_1.jsxs)(material_1.Grid, Object.assign({ container: true, width: "100%", spacing: isAdmin ? 1 : 3, justifyContent: "center", className: classes.tutorial }, { children: [!isTutorialOpen && ((0, jsx_runtime_1.jsx)(material_1.Grid, Object.assign({ size: "auto", alignItems: "center", justifyContent: "center" }, { children: (0, jsx_runtime_1.jsx)(material_1.IconButton, Object.assign({ size: "medium", onClick: handleOpenTutorial }, { children: (0, jsx_runtime_1.jsx)(material_1.Icon, { children: "info" }) })) }))), (0, jsx_runtime_1.jsx)(material_1.Collapse, Object.assign({ in: isTutorialOpen, className: classes.tutorialContent }, { children: isTutorialOpen && ((0, jsx_runtime_1.jsxs)(material_1.Grid, Object.assign({ size: "auto" }, { children: [(0, jsx_runtime_1.jsxs)(material_1.Typography, Object.assign({ variant: "body2", className: classes.tutorialTitle, component: "div" }, { children: [(0, jsx_runtime_1.jsx)(material_1.Grow, Object.assign({ in: true, timeout: 1000 }, { children: (0, jsx_runtime_1.jsx)("span", { children: actions[tutorialIndex].title }) })), (0, jsx_runtime_1.jsx)(material_1.IconButton, Object.assign({ size: "small", className: classes.tutorialTitleClose, onClick: handleCloseTutorial }, { children: (0, jsx_runtime_1.jsx)(material_1.Icon, { children: "close" }) }))] })), (0, jsx_runtime_1.jsx)(material_1.Grow, Object.assign({ in: true, timeout: 1200 }, { children: (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ variant: "body2", className: classes.tutorialDesc }, { children: actions[tutorialIndex].content })) })), (0, jsx_runtime_1.jsx)(material_1.Divider, { className: classes.divider }), (0, jsx_runtime_1.jsxs)(material_1.Stack, Object.assign({ direction: "row", justifyContent: "space-between", alignItems: "center", spacing: 2, className: classes.tutorialControls }, { children: [(0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ variant: "text", size: "small", onClick: handlePrevious, className: (0, classnames_1.default)(classes.btnStep, classes.btnPreviousStep) }, { children: tutorialIndex === 0 ? ((0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.platformWidget.tutorial.skip", defaultMessage: "ui.platformWidget.tutorial.skip" })) : ((0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.platformWidget.tutorial.previous", defaultMessage: "ui.platformWidget.tutorial.previous" })) })), (0, jsx_runtime_1.jsxs)(material_1.Typography, Object.assign({ component: "div" }, { children: [tutorialIndex + 1, "/", actions.length] })), (0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ variant: "contained", size: "small", color: "primary", onClick: handleNext, className: (0, classnames_1.default)(classes.btnStep, classes.btnNextStep) }, { children: tutorialIndex === actions.length - 1 ? ((0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.platformWidget.tutorial.close", defaultMessage: "ui.platformWidget.tutorial.close" })) : ((0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.platformWidget.tutorial.next", defaultMessage: "ui.platformWidget.tutorial.next" })) }))] }))] }))) }))] })));
|
|
297
297
|
/**
|
|
298
298
|
* Renders platform card
|
|
299
299
|
*/
|
|
@@ -109,7 +109,7 @@ function MessageMediaUploader(props) {
|
|
|
109
109
|
url: `${scContext.settings.portal}${api_services_1.Endpoints.PrivateMessageUploadMediaInChunks.url()}`,
|
|
110
110
|
headers: { Authorization: `Bearer ${scContext.settings.session.authToken.accessToken}` },
|
|
111
111
|
method: api_services_1.Endpoints.PrivateMessageUploadMediaInChunks.method
|
|
112
|
-
}, chunkSize: 204800, multiple: true, chunked: true, maxConcurrent: 2, fileFilter: filterBySizeAndType }, { children: [(0, jsx_runtime_1.jsx)(MessageChunkUploader_1.default, { onSuccess: handleSuccess, onProgress: handleProgress, onError: handleError }), !files.length && Object.keys(uploading).length === 0 && Object.keys(errors).length === 0 && ((0, jsx_runtime_1.jsxs)(upload_drop_zone_1.default, Object.assign({ className: classes.uploadSection }, { children: [(0, jsx_runtime_1.jsx)(UploadButton, { inputFieldName: "file", className: classes.uploadButton }), (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ textAlign:
|
|
112
|
+
}, chunkSize: 204800, multiple: true, chunked: true, maxConcurrent: 2, fileFilter: filterBySizeAndType }, { children: [(0, jsx_runtime_1.jsx)(MessageChunkUploader_1.default, { onSuccess: handleSuccess, onProgress: handleProgress, onError: handleError }), !files.length && Object.keys(uploading).length === 0 && Object.keys(errors).length === 0 && ((0, jsx_runtime_1.jsxs)(upload_drop_zone_1.default, Object.assign({ className: classes.uploadSection }, { children: [(0, jsx_runtime_1.jsx)(UploadButton, { inputFieldName: "file", className: classes.uploadButton }), (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ textAlign: "center", fontWeight: "medium" }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.privateMessage.editor.media.uploader.msg", defaultMessage: "ui.privateMessage.editor.media.uploader.msg" }) }))] }))), (0, jsx_runtime_1.jsxs)(material_1.List, Object.assign({ className: classes.previewContent }, { children: [previews.length !== 0 &&
|
|
113
113
|
previews.map((item, index) => {
|
|
114
114
|
var _a;
|
|
115
115
|
return ((0, jsx_runtime_1.jsx)(react_1.default.Fragment, { children: 'file' in item && ((0, jsx_runtime_1.jsxs)(material_1.ListItem, Object.assign({ className: classes.previewItem }, getMouseEvents(() => handleMouseEnter(item.file_uuid), () => handleMouseLeave(item.file_uuid)), { children: ['video_url' in item ? ((0, jsx_runtime_1.jsx)("video", { src: item.video_url })) : ((0, jsx_runtime_1.jsx)("img", { src: item.file.type.startsWith(types_1.SCMessageFileType.PDF) && !item.file_url
|
|
@@ -117,7 +117,7 @@ function MessageMediaUploader(props) {
|
|
|
117
117
|
: !item.file_url
|
|
118
118
|
? thumbnailCoverter_1.documentPlaceholder
|
|
119
119
|
: item.file_url })), (0, jsx_runtime_1.jsx)(material_1.ImageListItemBar, { className: (0, classnames_1.default)(classes.previewActions, { [classes.progress]: item.completed }), title: typeof item.completed !== 'undefined' &&
|
|
120
|
-
item.completed !== 0 && (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ textAlign: "center" }, { children: `${Math.round(item.completed)}%` })), actionIcon: (0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: isHovered[item.file_uuid] && Object.keys(uploading).length === 0 && ((0, jsx_runtime_1.jsx)(material_1.IconButton, Object.assign({ onClick: () => handleClear(item.file_uuid), size: "small" }, { children: (0, jsx_runtime_1.jsx)(material_1.Icon, { children: "delete" }) }))) }) }), isHovered[item.file_uuid] && ((0, jsx_runtime_1.jsxs)(material_1.Box, Object.assign({ component:
|
|
120
|
+
item.completed !== 0 && (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ textAlign: "center" }, { children: `${Math.round(item.completed)}%` })), actionIcon: (0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: isHovered[item.file_uuid] && Object.keys(uploading).length === 0 && ((0, jsx_runtime_1.jsx)(material_1.IconButton, Object.assign({ onClick: () => handleClear(item.file_uuid), size: "small" }, { children: (0, jsx_runtime_1.jsx)(material_1.Icon, { children: "delete" }) }))) }) }), isHovered[item.file_uuid] && ((0, jsx_runtime_1.jsxs)(material_1.Box, Object.assign({ component: "span", className: classes.previewInfo }, { children: [(0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ noWrap: true, textAlign: "center" }, { children: item.file.name })), (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ textAlign: "center", fontWeight: "light" }, { children: (0, sizeCoverter_1.bytesToSize)(item.file.size) }))] })))] }), (_a = item.id) !== null && _a !== void 0 ? _a : item.file_uuid)) }, index));
|
|
121
121
|
}), previews.length !== 0 && action] }))] })) })] })));
|
|
122
122
|
}
|
|
123
123
|
exports.default = MessageMediaUploader;
|
|
@@ -39,6 +39,6 @@ const Root = (0, material_1.styled)(material_1.Card, {
|
|
|
39
39
|
*
|
|
40
40
|
*/
|
|
41
41
|
function PrivateMessageSnippetsSkeleton(props) {
|
|
42
|
-
return ((0, jsx_runtime_1.jsx)(Root, Object.assign({ className: classes.root }, props, { children: (0, jsx_runtime_1.jsxs)(material_1.CardContent, { children: [(0, jsx_runtime_1.jsxs)(material_1.Stack, Object.assign({ direction: "column", justifyContent: "center", spacing: 1, alignItems: "center" }, { children: [(0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ variant: "outlined", size: "medium", disabled: true, className: classes.button }, { children: (0, jsx_runtime_1.jsx)(material_1.Skeleton, { height: 20, width: 100, variant:
|
|
42
|
+
return ((0, jsx_runtime_1.jsx)(Root, Object.assign({ className: classes.root }, props, { children: (0, jsx_runtime_1.jsxs)(material_1.CardContent, { children: [(0, jsx_runtime_1.jsxs)(material_1.Stack, Object.assign({ direction: "column", justifyContent: "center", spacing: 1, alignItems: "center" }, { children: [(0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ variant: "outlined", size: "medium", disabled: true, className: classes.button }, { children: (0, jsx_runtime_1.jsx)(material_1.Skeleton, { height: 20, width: 100, variant: "rectangular" }) })), (0, jsx_runtime_1.jsx)(material_1.Skeleton, { height: 25, width: "100%", variant: "rounded", className: classes.searchBar })] })), (0, jsx_runtime_1.jsx)(material_1.List, Object.assign({ className: classes.list }, { children: [...Array(6)].map((category, index) => ((0, jsx_runtime_1.jsx)(Skeleton_1.default, { elevation: 0 }, index))) }))] }) })));
|
|
43
43
|
}
|
|
44
44
|
exports.default = PrivateMessageSnippetsSkeleton;
|
|
@@ -460,7 +460,7 @@ function PrivateMessageThread(inProps) {
|
|
|
460
460
|
if (loadingMessageObjs) {
|
|
461
461
|
return (0, jsx_runtime_1.jsx)(Skeleton_1.default, {});
|
|
462
462
|
}
|
|
463
|
-
return ((0, jsx_runtime_1.jsxs)(material_1.CardContent, { children: [(0, jsx_runtime_1.jsx)(InfiniteScroll_1.default, Object.assign({ height:
|
|
463
|
+
return ((0, jsx_runtime_1.jsxs)(material_1.CardContent, { children: [(0, jsx_runtime_1.jsx)(InfiniteScroll_1.default, Object.assign({ height: "100%", dataLength: messageObjs.length, previous: handlePrevious, inverse: true, hasMorePrevious: Boolean(previous), loaderPrevious: (0, jsx_runtime_1.jsx)(PrivateMessageThreadItem_1.PrivateMessageThreadItemSkeleton, {}) }, { children: (0, jsx_runtime_1.jsx)(material_1.List, Object.assign({ ref: messagesEndRef }, { children: Object.keys(formattedMessages).map((key) => ((0, jsx_runtime_1.jsx)("li", Object.assign({ className: classes.section }, { children: (0, jsx_runtime_1.jsxs)("ul", { children: [(0, jsx_runtime_1.jsx)(material_1.ListSubheader, { children: (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ align: "center", className: classes.subHeader }, { children: key })) }), formattedMessages[key].map((msg) => {
|
|
464
464
|
var _a;
|
|
465
465
|
return ((0, jsx_runtime_1.jsxs)(material_1.Box, Object.assign({ className: classes.item }, { children: [msg.group && ((_a = scUserContext === null || scUserContext === void 0 ? void 0 : scUserContext.user) === null || _a === void 0 ? void 0 : _a.username) !== msg.sender.username && ((0, jsx_runtime_1.jsx)(material_1.ListItemAvatar, { children: (0, jsx_runtime_1.jsx)(material_1.Avatar, { alt: msg.sender.username, src: msg.sender.avatar, className: classes.avatar }) })), (0, jsx_runtime_1.jsx)(PrivateMessageThreadItem_1.default, { className: authUserId === msg.sender.id ? classes.sender : classes.receiver, message: msg, mouseEvents: {
|
|
466
466
|
onMouseEnter: () => handleMouseEnter(msg.id),
|
|
@@ -38,6 +38,6 @@ const Root = (0, material_1.styled)(material_1.Card, {
|
|
|
38
38
|
function PrivateMessageThreadSkeleton(props) {
|
|
39
39
|
const theme = (0, material_1.useTheme)();
|
|
40
40
|
const isMobile = (0, material_1.useMediaQuery)(theme.breakpoints.down('sm'));
|
|
41
|
-
return ((0, jsx_runtime_1.jsx)(Root, Object.assign({ className: classes.root }, props, { children: (0, jsx_runtime_1.jsxs)(material_1.CardContent, { children: [(0, jsx_runtime_1.jsxs)(material_1.List, Object.assign({ className: classes.list }, { children: [(0, jsx_runtime_1.jsx)(material_1.ListSubheader, Object.assign({ sx: { display: 'flex', justifyContent: 'center' } }, { children: (0, jsx_runtime_1.jsx)(material_1.Skeleton, { animation: "wave", height: 30, width: 120, style: { borderRadius: 20 } }) })), [...Array(isMobile ? 6 : 8)].map((item, index) => ((0, jsx_runtime_1.jsx)(Skeleton_1.default, { index: index }, index)))] })), (0, jsx_runtime_1.jsx)(material_1.Box, Object.assign({ className: classes.editor }, { children: (0, jsx_runtime_1.jsx)(material_1.Skeleton, { animation: "wave", height: 55, width:
|
|
41
|
+
return ((0, jsx_runtime_1.jsx)(Root, Object.assign({ className: classes.root }, props, { children: (0, jsx_runtime_1.jsxs)(material_1.CardContent, { children: [(0, jsx_runtime_1.jsxs)(material_1.List, Object.assign({ className: classes.list }, { children: [(0, jsx_runtime_1.jsx)(material_1.ListSubheader, Object.assign({ sx: { display: 'flex', justifyContent: 'center' } }, { children: (0, jsx_runtime_1.jsx)(material_1.Skeleton, { animation: "wave", height: 30, width: 120, style: { borderRadius: 20 } }) })), [...Array(isMobile ? 6 : 8)].map((item, index) => ((0, jsx_runtime_1.jsx)(Skeleton_1.default, { index: index }, index)))] })), (0, jsx_runtime_1.jsx)(material_1.Box, Object.assign({ className: classes.editor }, { children: (0, jsx_runtime_1.jsx)(material_1.Skeleton, { animation: "wave", height: 55, width: "100%", variant: "rectangular" }) }))] }) })));
|
|
42
42
|
}
|
|
43
43
|
exports.default = PrivateMessageThreadSkeleton;
|
|
@@ -156,10 +156,10 @@ function SnippetNotifications(inProps) {
|
|
|
156
156
|
}, [scUserContext.user, initialized]);
|
|
157
157
|
/**
|
|
158
158
|
* Notification subscriber
|
|
159
|
-
* @param
|
|
159
|
+
* @param _msg
|
|
160
160
|
* @param data
|
|
161
161
|
*/
|
|
162
|
-
const notificationSubscriber = (
|
|
162
|
+
const notificationSubscriber = (_msg, data) => {
|
|
163
163
|
/**
|
|
164
164
|
* Ignore notifications of type: notification_banner
|
|
165
165
|
* (data.data.activity_type === SCNotificationTypologyType.NOTIFICATION_BANNER)
|
|
@@ -290,10 +290,10 @@ function SnippetNotifications(inProps) {
|
|
|
290
290
|
/**
|
|
291
291
|
* Renders root object
|
|
292
292
|
*/
|
|
293
|
-
return ((0, jsx_runtime_1.jsx)(Root, Object.assign({ id: id, className: (0, classnames_1.default)(classes.root, className) }, rest, { children: (0, jsx_runtime_1.jsx)(material_1.Box, Object.assign({ className: classes.notificationsWrap }, { children: !initialized || loading ? ((0, jsx_runtime_1.jsx)(Skeleton_1.default, { elevation: 0 })) : ((0, jsx_runtime_1.jsx)(ScrollContainer_1.default, Object.assign({}, ScrollContainerProps, { children: (0, jsx_runtime_1.jsxs)(material_1.MenuList, Object.assign({ className: classes.list, disabledItemsFocusable: true, disableListWrap: true }, { children: [scUserContext.user.unseen_notification_banners_counter ? ((0, jsx_runtime_1.jsx)(material_1.MenuItem, Object.assign({ className: (0, classnames_1.default)(classes.item, classes.broadcastMessagesBanner), component: react_core_1.Link, to: scRoutingContext.url(react_core_1.SCRoutes.USER_NOTIFICATIONS_ROUTE_NAME, {}) }, { children: (0, jsx_runtime_1.jsx)(NotificationItem_1.default, { template: types_1.SCNotificationObjectTemplateType.SNIPPET, isNew: true, disableTypography: true, image: (0, jsx_runtime_1.jsx)(material_1.Avatar, { alt: preferences[react_core_1.SCPreferences.TEXT_APPLICATION_NAME], src: preferences[react_core_1.SCPreferences.LOGO_NAVBAR_LOGO_MOBILE] }), primary: (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ component:
|
|
293
|
+
return ((0, jsx_runtime_1.jsx)(Root, Object.assign({ id: id, className: (0, classnames_1.default)(classes.root, className) }, rest, { children: (0, jsx_runtime_1.jsx)(material_1.Box, Object.assign({ className: classes.notificationsWrap }, { children: !initialized || loading ? ((0, jsx_runtime_1.jsx)(Skeleton_1.default, { elevation: 0 })) : ((0, jsx_runtime_1.jsx)(ScrollContainer_1.default, Object.assign({}, ScrollContainerProps, { children: (0, jsx_runtime_1.jsxs)(material_1.MenuList, Object.assign({ className: classes.list, disabledItemsFocusable: true, disableListWrap: true }, { children: [scUserContext.user.unseen_notification_banners_counter ? ((0, jsx_runtime_1.jsx)(material_1.MenuItem, Object.assign({ className: (0, classnames_1.default)(classes.item, classes.broadcastMessagesBanner), component: react_core_1.Link, to: scRoutingContext.url(react_core_1.SCRoutes.USER_NOTIFICATIONS_ROUTE_NAME, {}) }, { children: (0, jsx_runtime_1.jsx)(NotificationItem_1.default, { template: types_1.SCNotificationObjectTemplateType.SNIPPET, isNew: true, disableTypography: true, image: (0, jsx_runtime_1.jsx)(material_1.Avatar, { alt: preferences[react_core_1.SCPreferences.TEXT_APPLICATION_NAME], src: preferences[react_core_1.SCPreferences.LOGO_NAVBAR_LOGO_MOBILE] }), primary: (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ component: "div" }, { children: intl.formatMessage({ id: 'ui.snippetNotifications.broadcastMessages', defaultMessage: 'ui.snippetNotifications.broadcastMessages' }, {
|
|
294
294
|
count: scUserContext.user.unseen_notification_banners_counter,
|
|
295
|
-
b: (
|
|
296
|
-
link: (
|
|
295
|
+
b: (chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks }, "ui.snippetNotifications.broadcastMessages.b"),
|
|
296
|
+
link: (chunks) => ((0, jsx_runtime_1.jsx)(react_core_1.Link, Object.assign({ to: scRoutingContext.url(react_core_1.SCRoutes.USER_NOTIFICATIONS_ROUTE_NAME, {}) }, { children: chunks }), "ui.snippetNotifications.broadcastMessages.link"))
|
|
297
297
|
}) })) }) }), "banner")) : null, notifications.length === 0 ? ((0, jsx_runtime_1.jsx)(material_1.MenuItem, Object.assign({ className: classes.emptyBoxNotifications }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.snippetNotifications.noNotifications", defaultMessage: "ui.snippetNotifications.noNotifications" }) }))) : (notifications.slice(0, showMax).map((notificationObject, i) => notificationObject.aggregated.map((n, k) => ((0, jsx_runtime_1.jsx)(material_1.MenuItem, Object.assign({ className: classes.item, onClick: (e) => handleSingleNotificationClick(e, n), disableRipple: true, disableTouchRipple: true }, { children: renderAggregatedItem(n, i) }), k)))))] })) }))) })) })));
|
|
298
298
|
}
|
|
299
299
|
exports.default = SnippetNotifications;
|
|
@@ -55,7 +55,7 @@ function UserAddPaymentMethodForm(inProps) {
|
|
|
55
55
|
props: inProps,
|
|
56
56
|
name: constants_1.PREFIX
|
|
57
57
|
});
|
|
58
|
-
const { className = null, customer, collectBillingAddress = false, handleSuccess, handleClose } = props
|
|
58
|
+
const { className = null, customer, collectBillingAddress = false, handleSuccess, handleClose } = props;
|
|
59
59
|
// CONTEXT
|
|
60
60
|
const scUserContext = (0, react_core_1.useSCUser)();
|
|
61
61
|
// STATE
|
|
@@ -131,11 +131,11 @@ function UserAddPaymentMethodForm(inProps) {
|
|
|
131
131
|
if (!isPaymentsEnabled || !scUserContext.user) {
|
|
132
132
|
return null;
|
|
133
133
|
}
|
|
134
|
-
return ((0, jsx_runtime_1.jsx)(Root, Object.assign({ className: classes.root }, { children: (0, jsx_runtime_1.jsxs)("form", Object.assign({ onSubmit: handleSubmit }, { children: [(0, jsx_runtime_1.jsx)(react_stripe_js_1.PaymentElement, { id: "payment-element", options: paymentElementOptions, onReady: () => setReady(true) }), collectBillingAddress && ((0, jsx_runtime_1.jsx)(material_1.Paper, Object.assign({ variant: "outlined", className: classes.address }, { children: Object.keys(addressState).length && !isEditingBillingAddress ? ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ variant:
|
|
134
|
+
return ((0, jsx_runtime_1.jsx)(Root, Object.assign({ className: classes.root }, { children: (0, jsx_runtime_1.jsxs)("form", Object.assign({ onSubmit: handleSubmit }, { children: [(0, jsx_runtime_1.jsx)(react_stripe_js_1.PaymentElement, { id: "payment-element", options: paymentElementOptions, onReady: () => setReady(true) }), collectBillingAddress && ((0, jsx_runtime_1.jsx)(material_1.Paper, Object.assign({ variant: "outlined", className: classes.address }, { children: Object.keys(addressState).length && !isEditingBillingAddress ? ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ variant: "body1" }, { children: addressState.name })), (0, jsx_runtime_1.jsxs)(material_1.Typography, Object.assign({ variant: "body1" }, { children: [addressState.address.line1, (0, jsx_runtime_1.jsx)("br", {}), addressState.address.line2] })), (0, jsx_runtime_1.jsxs)(material_1.Typography, Object.assign({ variant: "body1" }, { children: [addressState.address.postal_code, " - ", addressState.address.city, " - ", addressState.address.country] })), (0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ sx: { mt: 1 }, variant: "contained", disabled: !elements, onClick: () => setIsEditingBillingAddress(!isEditingBillingAddress) }, { children: "Change" }))] })) : ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(react_stripe_js_1.AddressElement, { onChange: (event) => {
|
|
135
135
|
setAddressState(event.value);
|
|
136
136
|
}, options: {
|
|
137
137
|
mode: 'billing',
|
|
138
138
|
defaultValues: addressState
|
|
139
|
-
} }), (0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ sx: { mt: 1 }, variant:
|
|
139
|
+
} }), (0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ sx: { mt: 1 }, variant: "contained", disabled: !elements || loading || !ready, onClick: () => setIsEditingBillingAddress(!isEditingBillingAddress) }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.userAddPaymentMethodForm.useDefaultMethod", defaultMessage: "ui.userAddPaymentMethodForm.useDefaultMethod" }) }))] })) }))), (0, jsx_runtime_1.jsxs)(material_1.Stack, Object.assign({ direction: "row", justifyContent: "flex-end", alignItems: "center", spacing: 2, mt: 3 }, { children: [(0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ onClick: onHandleClose, variant: "outlined" }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.userAddPaymentMethodForm.cancelButton", defaultMessage: "ui.userAddPaymentMethodForm.cancelButton" }) })), (0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ disabled: !ready, loading: loading, type: "submit", variant: "contained" }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.userAddPaymentMethodForm.addButton", defaultMessage: "ui.userAddPaymentMethodForm.addButton" }) }))] })), errorMessage && (0, jsx_runtime_1.jsx)("div", { children: errorMessage })] })) })));
|
|
140
140
|
}
|
|
141
141
|
exports.default = UserAddPaymentMethodForm;
|
|
@@ -111,7 +111,7 @@ const UserAutocomplete = (inProps) => {
|
|
|
111
111
|
}, renderInput: (params) => ((0, jsx_runtime_1.jsx)(material_1.TextField, Object.assign({}, params, TextFieldProps, { margin: "dense", slotProps: {
|
|
112
112
|
input: Object.assign(Object.assign({}, params.InputProps), { autoComplete: 'off', endAdornment: filteredUsers.length > 0 ? ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [isLoading && (0, jsx_runtime_1.jsx)(material_1.CircularProgress, { color: "inherit", size: 20 }), params.InputProps.endAdornment] })) : null })
|
|
113
113
|
} }))) }, rest)), (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ variant: "body2", color: "primary", className: classes.info }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.userAutocomplete.textarea.info", defaultMessage: "ui.userAutocomplete.textarea.info", values: {
|
|
114
|
-
icon: (
|
|
114
|
+
icon: (chunks) => (0, jsx_runtime_1.jsx)(material_1.Icon, { children: chunks }, "ui.userAutocomplete.textarea.info.icon")
|
|
115
115
|
} }) })), (0, jsx_runtime_1.jsx)(material_1.TextField, { label: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.userAutocomplete.textarea.label", defaultMessage: "ui.userAutocomplete.textarea.label" }), multiline: true, minRows: 4, fullWidth: true, margin: "normal", value: textAreaValue, onChange: handleTextAreaChange })] })));
|
|
116
116
|
};
|
|
117
117
|
exports.default = UserAutocomplete;
|
|
@@ -445,7 +445,7 @@ const UserBillingInfo = (inProps, ref) => {
|
|
|
445
445
|
if (!isPaymentsEnabled || !scUserContext.user) {
|
|
446
446
|
return null;
|
|
447
447
|
}
|
|
448
|
-
return ((0, jsx_runtime_1.jsx)(Root, Object.assign({ className: (0, classnames_1.default)(classes.root, className), id: id }, rest, { ref: componentRef }, { children: (0, jsx_runtime_1.jsx)(react_1.Fragment, { children: state.isLoading ? ((0, jsx_runtime_1.jsx)(Skeleton_1.default, { mode: mode })) : ((0, jsx_runtime_1.jsx)(react_1.Fragment, { children: state.mode === Billing_1.UserBillingInfoMode.READ ? ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [state.name ? ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ variant:
|
|
448
|
+
return ((0, jsx_runtime_1.jsx)(Root, Object.assign({ className: (0, classnames_1.default)(classes.root, className), id: id }, rest, { ref: componentRef }, { children: (0, jsx_runtime_1.jsx)(react_1.Fragment, { children: state.isLoading ? ((0, jsx_runtime_1.jsx)(Skeleton_1.default, { mode: mode })) : ((0, jsx_runtime_1.jsx)(react_1.Fragment, { children: state.mode === Billing_1.UserBillingInfoMode.READ ? ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [state.name ? ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ variant: "body1" }, { children: state.name })), (0, jsx_runtime_1.jsxs)(material_1.Typography, Object.assign({ variant: "body1" }, { children: [state.address_line1, (0, jsx_runtime_1.jsx)("br", {}), state.address_line2] })), (0, jsx_runtime_1.jsxs)(material_1.Typography, Object.assign({ variant: "body1" }, { children: [state.address_postal_code, " - ", state.address_city, " - ", state.address_country && state.address_country.label] })), Boolean(state.tax_code && !state.isBusiness) && (0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ variant: "body1" }, { children: state.tax_code })), state.isBusiness && ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [state.tax_id_data && (0, jsx_runtime_1.jsxs)(material_1.Typography, Object.assign({ variant: "body1" }, { children: ["VAT: ", state.tax_id_data.value] })), state.sdi && (0, jsx_runtime_1.jsxs)(material_1.Typography, Object.assign({ variant: "body1" }, { children: ["SDI: ", state.sdi] })), state.pec && (0, jsx_runtime_1.jsxs)(material_1.Typography, Object.assign({ variant: "body1" }, { children: ["PEC: ", state.pec] }))] }))] })) : ((0, jsx_runtime_1.jsx)(material_1.Typography, Object.assign({ variant: "body1" }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.userBillingInfo.noInfo", defaultMessage: "ui.userBillingInfo.noInfo" }) }))), state.initialDataCompleted && ((0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ sx: { mt: 1 }, variant: "contained", size: "small", disabled: Boolean(disableButtons), onClick: handleChangeViewMode }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "component.CheckoutForm.billingInfoChangeButton", defaultMessage: "component.CheckoutForm.billingInfoChangeButton" }) })))] })) : ((0, jsx_runtime_1.jsx)(material_1.Box, { children: (0, jsx_runtime_1.jsxs)(material_1.Grid, Object.assign({ container: true, width: "100%", spacing: 3 }, { children: [(0, jsx_runtime_1.jsx)(material_1.Grid, Object.assign({ size: { xs: 12, sm: inlineDisplay ? 12 : 6 } }, { children: (0, jsx_runtime_1.jsx)(material_1.TextField, { variant: "outlined", id: "name", name: "name", label: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.userBillingInfo.name", defaultMessage: "ui.userBillingInfo.name" }), onChange: handleChange('name'), value: state.name, error: Boolean(state.nameError), helperText: state.nameError, fullWidth: true }) })), (0, jsx_runtime_1.jsx)(material_1.Grid, Object.assign({ size: { xs: 12, sm: inlineDisplay ? 12 : 6 } }, { children: (0, jsx_runtime_1.jsx)(material_1.TextField, { variant: "outlined", id: "address_line1", name: "address_line1", label: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.userBillingInfo.address1", defaultMessage: "ui.userBillingInfo.address1" }), onChange: handleChange('address_line1'), value: state.address_line1, error: Boolean(state.addressLine1Error), helperText: state.addressLine1Error, fullWidth: true }) })), (0, jsx_runtime_1.jsx)(material_1.Grid, Object.assign({ size: { xs: 12, sm: inlineDisplay ? 12 : 6 } }, { children: (0, jsx_runtime_1.jsx)(material_1.TextField, { variant: "outlined", id: "address_line2", name: "address_line2", label: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.userBillingInfo.address2", defaultMessage: "ui.userBillingInfo.address2" }), onChange: handleChange('address_line2'), value: state.address_line2, error: Boolean(state.addressLine2Error), helperText: state.addressLine2Error, fullWidth: true }) })), (0, jsx_runtime_1.jsx)(material_1.Grid, Object.assign({ size: { xs: 12, sm: inlineDisplay ? 12 : 6 } }, { children: (0, jsx_runtime_1.jsx)(material_1.Autocomplete, { id: "country-select-demo", options: Country_1.countries, value: state.address_country, fullWidth: true, onChange: handleChange('address_country'), getOptionLabel: (option) => option.label, renderOption: (props, option) => {
|
|
449
449
|
const { key } = props, rest = tslib_1.__rest(props, ["key"]);
|
|
450
450
|
return ((0, jsx_runtime_1.jsxs)(material_1.Box, Object.assign({ component: "li", sx: { '& > img': { mr: 2, flexShrink: 0 } } }, rest, { children: [(0, jsx_runtime_1.jsx)("img", { loading: "lazy", width: "20", srcSet: `https://flagcdn.com/w40/${option.code.toLowerCase()}.png 2x`, src: `https://flagcdn.com/w20/${option.code.toLowerCase()}.png`, alt: "" }), option.label, " (", option.code, ")"] }), key));
|
|
451
451
|
}, renderInput: (params) => ((0, jsx_runtime_1.jsx)(material_1.TextField, Object.assign({}, params, { label: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.userBillingInfo.country", defaultMessage: "ui.userBillingInfo.country" }), fullWidth: true, id: "address_country", name: "address_country", error: Boolean(state.addressCountryError), slotProps: {
|
|
@@ -76,7 +76,7 @@ function UserChangeAddressDialog(inProps) {
|
|
|
76
76
|
if (!isPaymentsEnabled || !scUserContext.user) {
|
|
77
77
|
return null;
|
|
78
78
|
}
|
|
79
|
-
return ((0, jsx_runtime_1.jsx)(Root, Object.assign({ className: (0, classnames_1.default)(classes.root, className), title: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { defaultMessage: "ui.userChangeAddressDialog.title", id: "component.userChangeAddressDialog.title" }), open: open, actions: (0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ variant:
|
|
79
|
+
return ((0, jsx_runtime_1.jsx)(Root, Object.assign({ className: (0, classnames_1.default)(classes.root, className), title: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { defaultMessage: "ui.userChangeAddressDialog.title", id: "component.userChangeAddressDialog.title" }), open: open, actions: (0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ variant: "outlined", onClick: handleClose }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { defaultMessage: "ui.userChangeAddressDialog.btnClose", id: "component.userChangeAddressDialog.btnClose" }) })), (0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ loading: loading, disabled: loading, variant: "contained", onClick: handleSave }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { defaultMessage: "ui.userChangeAddressDialog.btnSave", id: "component.userChangeAddressDialog.btnSave" }) }))] }) }, rest, { children: (0, jsx_runtime_1.jsx)(react_stripe_js_1.Elements, Object.assign({ stripe: stripePromise, options: elementsOptions }, { children: (0, jsx_runtime_1.jsx)(react_stripe_js_1.AddressElement, { onChange: handleChangeAddress, options: {
|
|
80
80
|
mode: 'billing',
|
|
81
81
|
defaultValues: addressState
|
|
82
82
|
} }) })) })));
|
|
@@ -18,7 +18,7 @@ const classes = {
|
|
|
18
18
|
const Root = (0, material_1.styled)(material_1.Box, {
|
|
19
19
|
name: PREFIX,
|
|
20
20
|
slot: 'Root',
|
|
21
|
-
overridesResolver: (
|
|
21
|
+
overridesResolver: (_props, styles) => styles.root
|
|
22
22
|
})(() => ({}));
|
|
23
23
|
/**
|
|
24
24
|
* > API documentation for the Community-JS User Counters component. Learn about the available props and the CSS API.
|
|
@@ -93,24 +93,16 @@ function UserCounters(inProps) {
|
|
|
93
93
|
return ((0, jsx_runtime_1.jsxs)(Root, Object.assign({ className: (0, classnames_1.default)(classes.root, className) }, rest, { children: [(0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: (followEnabled || connectionEnabled) &&
|
|
94
94
|
(followEnabled ? ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ className: classes.button, variant: "text", component: react_core_1.Link, to: scRoutingContext.url(react_core_1.SCRoutes.USER_PROFILE_FOLLOWINGS_ROUTE_NAME, scUser) }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.userCounters.followings", defaultMessage: "ui.userCounters.followings", values: {
|
|
95
95
|
count: scUser === null || scUser === void 0 ? void 0 : scUser.followings_counter,
|
|
96
|
-
|
|
97
|
-
// @ts-ignore
|
|
98
|
-
b: (chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks })
|
|
96
|
+
b: (chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks }, "ui.userCounters.followings.b")
|
|
99
97
|
} }) })), (0, jsx_runtime_1.jsx)(Bullet_1.default, {}), (0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ className: classes.button, variant: "text", component: react_core_1.Link, to: scRoutingContext.url(react_core_1.SCRoutes.USER_PROFILE_FOLLOWERS_ROUTE_NAME, scUser) }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.userCounters.followers", defaultMessage: "ui.userCounters.followers", values: {
|
|
100
98
|
count: scUser === null || scUser === void 0 ? void 0 : scUser.followers_counter,
|
|
101
|
-
|
|
102
|
-
// @ts-ignore
|
|
103
|
-
b: (chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks })
|
|
99
|
+
b: (chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks }, "ui.userCounters.followers.b")
|
|
104
100
|
} }) }))] })) : ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ className: classes.button, variant: "text", component: react_core_1.Link, to: scRoutingContext.url(react_core_1.SCRoutes.USER_PROFILE_CONNECTIONS_ROUTE_NAME, scUser) }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.userCounters.connections", defaultMessage: "ui.userCounters.connections", values: {
|
|
105
101
|
count: scUser === null || scUser === void 0 ? void 0 : scUser.connections_counter,
|
|
106
|
-
|
|
107
|
-
// @ts-ignore
|
|
108
|
-
b: (chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks })
|
|
102
|
+
b: (chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks }, "ui.userCounters.connections.b")
|
|
109
103
|
} }) })), (0, jsx_runtime_1.jsx)(Bullet_1.default, {})] }))) }), categoryFollowEnabled && ((0, jsx_runtime_1.jsx)(material_1.Button, Object.assign({ className: classes.button, variant: "text", component: react_core_1.Link, to: scRoutingContext.url(react_core_1.SCRoutes.USER_PROFILE_CATEGORIES_ROUTE_NAME, scUser) }, { children: (0, jsx_runtime_1.jsx)(react_intl_1.FormattedMessage, { id: "ui.userCounters.categories", defaultMessage: "ui.userCounters.categories", values: {
|
|
110
104
|
count: scUser === null || scUser === void 0 ? void 0 : scUser.categories_counter,
|
|
111
|
-
|
|
112
|
-
// @ts-ignore
|
|
113
|
-
b: (chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks })
|
|
105
|
+
b: (chunks) => (0, jsx_runtime_1.jsx)("strong", { children: chunks }, "ui.userCounters.categories.b")
|
|
114
106
|
} }) })))] })));
|
|
115
107
|
}
|
|
116
108
|
exports.default = UserCounters;
|
|
@@ -122,7 +122,7 @@ function UserInfo(inProps) {
|
|
|
122
122
|
case types_1.SCUserProfileFields.DATE_OF_BIRTH:
|
|
123
123
|
return `${intl.formatDate(user[field], { year: 'numeric', month: 'numeric', day: 'numeric' })}`;
|
|
124
124
|
case types_1.SCUserProfileFields.TAGS:
|
|
125
|
-
return ((0, jsx_runtime_1.jsx)(Tags_1.default, { tags: user.tags.filter((t) => t.visible), type: Tags_1.TagsComponentType.LIST, direction:
|
|
125
|
+
return ((0, jsx_runtime_1.jsx)(Tags_1.default, { tags: user.tags.filter((t) => t.visible), type: Tags_1.TagsComponentType.LIST, direction: "row", TagChipProps: { clickable: false, disposable: false } }));
|
|
126
126
|
case types_1.SCUserProfileFields.WEBSITE:
|
|
127
127
|
return ((0, jsx_runtime_1.jsx)("a", Object.assign({ href: user[field], target: '_blank' }, { children: user[field] })));
|
|
128
128
|
default:
|