@selfcommunity/react-core 0.6.7-payments.187 → 0.6.7-payments.189

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.
@@ -36,21 +36,27 @@ function useSCJoinedCoursesManager(user) {
36
36
  Preferences_1.CONFIGURATIONS_COURSES_ENABLED in preferences &&
37
37
  preferences[Preferences_1.CONFIGURATIONS_COURSES_ENABLED].value, [preferences, features]);
38
38
  const notificationInvitedToJoinCourse = (0, react_1.useRef)(null);
39
- const notificationRequestedToJoinCourse = (0, react_1.useRef)(null);
40
- const notificationAcceptedToJoinCourse = (0, react_1.useRef)(null);
39
+ // const notificationRequestedToJoinCourse = useRef(null);
40
+ // const notificationAcceptedToJoinCourse = useRef(null);
41
41
  const notificationAddedToCourse = (0, react_1.useRef)(null);
42
42
  /**
43
43
  * Subscribe to notification types user_follow, user_unfollow
44
44
  */
45
45
  (0, use_deep_compare_effect_1.useDeepCompareEffectNoCheck)(() => {
46
46
  notificationInvitedToJoinCourse.current = pubsub_js_1.default.subscribe(`${types_1.SCNotificationTopicType.INTERACTION}.${types_1.SCNotificationTypologyType.USER_INVITED_TO_JOIN_COURSE}`, notificationSubscriber);
47
- notificationRequestedToJoinCourse.current = pubsub_js_1.default.subscribe(`${types_1.SCNotificationTopicType.INTERACTION}.${types_1.SCNotificationTypologyType.USER_REQUESTED_TO_JOIN_COURSE}`, notificationSubscriber);
48
- notificationAcceptedToJoinCourse.current = pubsub_js_1.default.subscribe(`${types_1.SCNotificationTopicType.INTERACTION}.${types_1.SCNotificationTypologyType.USER_ACCEPTED_TO_JOIN_COURSE}`, notificationSubscriber);
47
+ /* notificationRequestedToJoinCourse.current = PubSub.subscribe(
48
+ `${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_REQUESTED_TO_JOIN_COURSE}`,
49
+ notificationSubscriber
50
+ );
51
+ notificationAcceptedToJoinCourse.current = PubSub.subscribe(
52
+ `${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_ACCEPTED_TO_JOIN_COURSE}`,
53
+ notificationSubscriber
54
+ ); */
49
55
  notificationAddedToCourse.current = pubsub_js_1.default.subscribe(`${types_1.SCNotificationTopicType.INTERACTION}.${types_1.SCNotificationTypologyType.USER_ADDED_TO_COURSE}`, notificationSubscriber);
50
56
  return () => {
51
57
  pubsub_js_1.default.unsubscribe(notificationInvitedToJoinCourse.current);
52
- pubsub_js_1.default.unsubscribe(notificationRequestedToJoinCourse.current);
53
- pubsub_js_1.default.unsubscribe(notificationAcceptedToJoinCourse.current);
58
+ // PubSub.unsubscribe(notificationRequestedToJoinCourse.current);
59
+ // PubSub.unsubscribe(notificationAcceptedToJoinCourse.current);
54
60
  pubsub_js_1.default.unsubscribe(notificationAddedToCourse.current);
55
61
  };
56
62
  }, [data]);
@@ -37,21 +37,28 @@ function useSCSubscribedEventsManager(user) {
37
37
  Preferences_1.CONFIGURATIONS_EVENTS_ENABLED in preferences &&
38
38
  preferences[Preferences_1.CONFIGURATIONS_EVENTS_ENABLED].value, [preferences, features]);
39
39
  const notificationInvitedToJoinEvent = (0, react_1.useRef)(null);
40
- const notificationRequestedToJoinEvent = (0, react_1.useRef)(null);
41
- const notificationAcceptedToJoinEvent = (0, react_1.useRef)(null);
40
+ // const notificationRequestedToJoinEvent = useRef(null);
41
+ // const notificationAcceptedToJoinEvent = useRef(null);
42
42
  const notificationAddedToEvent = (0, react_1.useRef)(null);
43
43
  /**
44
44
  * Subscribe to notification types user_follow, user_unfollow
45
45
  */
46
46
  (0, use_deep_compare_effect_1.useDeepCompareEffectNoCheck)(() => {
47
47
  notificationInvitedToJoinEvent.current = pubsub_js_1.default.subscribe(`${types_1.SCNotificationTopicType.INTERACTION}.${types_1.SCNotificationTypologyType.USER_INVITED_TO_JOIN_EVENT}`, notificationSubscriber);
48
- notificationRequestedToJoinEvent.current = pubsub_js_1.default.subscribe(`${types_1.SCNotificationTopicType.INTERACTION}.${types_1.SCNotificationTypologyType.USER_REQUESTED_TO_JOIN_EVENT}`, notificationSubscriber);
49
- notificationAcceptedToJoinEvent.current = pubsub_js_1.default.subscribe(`${types_1.SCNotificationTopicType.INTERACTION}.${types_1.SCNotificationTypologyType.USER_ACCEPTED_TO_JOIN_EVENT}`, notificationSubscriber);
48
+ /* notificationRequestedToJoinEvent.current = PubSub.subscribe(
49
+ `${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_REQUESTED_TO_JOIN_EVENT}`,
50
+ notificationSubscriber
51
+ );
52
+ notificationAcceptedToJoinEvent.current = PubSub.subscribe(
53
+ `${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_ACCEPTED_TO_JOIN_EVENT}`,
54
+ notificationSubscriber
55
+ );
56
+ */
50
57
  notificationAddedToEvent.current = pubsub_js_1.default.subscribe(`${types_1.SCNotificationTopicType.INTERACTION}.${types_1.SCNotificationTypologyType.USER_ADDED_TO_EVENT}`, notificationSubscriber);
51
58
  return () => {
52
59
  pubsub_js_1.default.unsubscribe(notificationInvitedToJoinEvent.current);
53
- pubsub_js_1.default.unsubscribe(notificationRequestedToJoinEvent.current);
54
- pubsub_js_1.default.unsubscribe(notificationAcceptedToJoinEvent.current);
60
+ // PubSub.unsubscribe(notificationRequestedToJoinEvent.current);
61
+ // PubSub.unsubscribe(notificationAcceptedToJoinEvent.current);
55
62
  pubsub_js_1.default.unsubscribe(notificationAddedToEvent.current);
56
63
  };
57
64
  }, [data]);
@@ -37,21 +37,29 @@ function useSCSubscribedGroupsManager(user) {
37
37
  Preferences_1.CONFIGURATIONS_GROUPS_ENABLED in preferences &&
38
38
  preferences[Preferences_1.CONFIGURATIONS_GROUPS_ENABLED].value, [preferences, features]);
39
39
  const notificationInvitedToJoinGroup = (0, react_1.useRef)(null);
40
- const notificationRequestedToJoinGroup = (0, react_1.useRef)(null);
41
- const notificationAcceptedToJoinGroup = (0, react_1.useRef)(null);
40
+ // const notificationRequestedToJoinGroup = useRef(null);
41
+ // const notificationAcceptedToJoinGroup = useRef(null);
42
42
  const notificationAddedToGroup = (0, react_1.useRef)(null);
43
43
  /**
44
44
  * Subscribe to notification types user_follow, user_unfollow
45
45
  */
46
46
  (0, use_deep_compare_effect_1.useDeepCompareEffectNoCheck)(() => {
47
47
  notificationInvitedToJoinGroup.current = pubsub_js_1.default.subscribe(`${types_1.SCNotificationTopicType.INTERACTION}.${types_1.SCNotificationTypologyType.USER_INVITED_TO_JOIN_GROUP}`, notificationSubscriber);
48
- notificationRequestedToJoinGroup.current = pubsub_js_1.default.subscribe(`${types_1.SCNotificationTopicType.INTERACTION}.${types_1.SCNotificationTypologyType.USER_REQUESTED_TO_JOIN_GROUP}`, notificationSubscriber);
49
- notificationAcceptedToJoinGroup.current = pubsub_js_1.default.subscribe(`${types_1.SCNotificationTopicType.INTERACTION}.${types_1.SCNotificationTypologyType.USER_ACCEPTED_TO_JOIN_GROUP}`, notificationSubscriber);
48
+ /*
49
+ notificationRequestedToJoinGroup.current = PubSub.subscribe(
50
+ `${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_REQUESTED_TO_JOIN_GROUP}`,
51
+ notificationSubscriber
52
+ );
53
+ notificationAcceptedToJoinGroup.current = PubSub.subscribe(
54
+ `${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_ACCEPTED_TO_JOIN_GROUP}`,
55
+ notificationSubscriber
56
+ );
57
+ */
50
58
  notificationAddedToGroup.current = pubsub_js_1.default.subscribe(`${types_1.SCNotificationTopicType.INTERACTION}.${types_1.SCNotificationTypologyType.USER_ADDED_TO_GROUP}`, notificationSubscriber);
51
59
  return () => {
52
60
  pubsub_js_1.default.unsubscribe(notificationInvitedToJoinGroup.current);
53
- pubsub_js_1.default.unsubscribe(notificationRequestedToJoinGroup.current);
54
- pubsub_js_1.default.unsubscribe(notificationAcceptedToJoinGroup.current);
61
+ // PubSub.unsubscribe(notificationRequestedToJoinGroup.current);
62
+ // PubSub.unsubscribe(notificationAcceptedToJoinGroup.current);
55
63
  pubsub_js_1.default.unsubscribe(notificationAddedToGroup.current);
56
64
  };
57
65
  }, [data]);
@@ -33,21 +33,27 @@ export default function useSCJoinedCoursesManager(user) {
33
33
  CONFIGURATIONS_COURSES_ENABLED in preferences &&
34
34
  preferences[CONFIGURATIONS_COURSES_ENABLED].value, [preferences, features]);
35
35
  const notificationInvitedToJoinCourse = useRef(null);
36
- const notificationRequestedToJoinCourse = useRef(null);
37
- const notificationAcceptedToJoinCourse = useRef(null);
36
+ // const notificationRequestedToJoinCourse = useRef(null);
37
+ // const notificationAcceptedToJoinCourse = useRef(null);
38
38
  const notificationAddedToCourse = useRef(null);
39
39
  /**
40
40
  * Subscribe to notification types user_follow, user_unfollow
41
41
  */
42
42
  useDeepCompareEffectNoCheck(() => {
43
43
  notificationInvitedToJoinCourse.current = PubSub.subscribe(`${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_INVITED_TO_JOIN_COURSE}`, notificationSubscriber);
44
- notificationRequestedToJoinCourse.current = PubSub.subscribe(`${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_REQUESTED_TO_JOIN_COURSE}`, notificationSubscriber);
45
- notificationAcceptedToJoinCourse.current = PubSub.subscribe(`${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_ACCEPTED_TO_JOIN_COURSE}`, notificationSubscriber);
44
+ /* notificationRequestedToJoinCourse.current = PubSub.subscribe(
45
+ `${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_REQUESTED_TO_JOIN_COURSE}`,
46
+ notificationSubscriber
47
+ );
48
+ notificationAcceptedToJoinCourse.current = PubSub.subscribe(
49
+ `${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_ACCEPTED_TO_JOIN_COURSE}`,
50
+ notificationSubscriber
51
+ ); */
46
52
  notificationAddedToCourse.current = PubSub.subscribe(`${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_ADDED_TO_COURSE}`, notificationSubscriber);
47
53
  return () => {
48
54
  PubSub.unsubscribe(notificationInvitedToJoinCourse.current);
49
- PubSub.unsubscribe(notificationRequestedToJoinCourse.current);
50
- PubSub.unsubscribe(notificationAcceptedToJoinCourse.current);
55
+ // PubSub.unsubscribe(notificationRequestedToJoinCourse.current);
56
+ // PubSub.unsubscribe(notificationAcceptedToJoinCourse.current);
51
57
  PubSub.unsubscribe(notificationAddedToCourse.current);
52
58
  };
53
59
  }, [data]);
@@ -34,21 +34,28 @@ export default function useSCSubscribedEventsManager(user) {
34
34
  CONFIGURATIONS_EVENTS_ENABLED in preferences &&
35
35
  preferences[CONFIGURATIONS_EVENTS_ENABLED].value, [preferences, features]);
36
36
  const notificationInvitedToJoinEvent = useRef(null);
37
- const notificationRequestedToJoinEvent = useRef(null);
38
- const notificationAcceptedToJoinEvent = useRef(null);
37
+ // const notificationRequestedToJoinEvent = useRef(null);
38
+ // const notificationAcceptedToJoinEvent = useRef(null);
39
39
  const notificationAddedToEvent = useRef(null);
40
40
  /**
41
41
  * Subscribe to notification types user_follow, user_unfollow
42
42
  */
43
43
  useDeepCompareEffectNoCheck(() => {
44
44
  notificationInvitedToJoinEvent.current = PubSub.subscribe(`${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_INVITED_TO_JOIN_EVENT}`, notificationSubscriber);
45
- notificationRequestedToJoinEvent.current = PubSub.subscribe(`${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_REQUESTED_TO_JOIN_EVENT}`, notificationSubscriber);
46
- notificationAcceptedToJoinEvent.current = PubSub.subscribe(`${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_ACCEPTED_TO_JOIN_EVENT}`, notificationSubscriber);
45
+ /* notificationRequestedToJoinEvent.current = PubSub.subscribe(
46
+ `${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_REQUESTED_TO_JOIN_EVENT}`,
47
+ notificationSubscriber
48
+ );
49
+ notificationAcceptedToJoinEvent.current = PubSub.subscribe(
50
+ `${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_ACCEPTED_TO_JOIN_EVENT}`,
51
+ notificationSubscriber
52
+ );
53
+ */
47
54
  notificationAddedToEvent.current = PubSub.subscribe(`${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_ADDED_TO_EVENT}`, notificationSubscriber);
48
55
  return () => {
49
56
  PubSub.unsubscribe(notificationInvitedToJoinEvent.current);
50
- PubSub.unsubscribe(notificationRequestedToJoinEvent.current);
51
- PubSub.unsubscribe(notificationAcceptedToJoinEvent.current);
57
+ // PubSub.unsubscribe(notificationRequestedToJoinEvent.current);
58
+ // PubSub.unsubscribe(notificationAcceptedToJoinEvent.current);
52
59
  PubSub.unsubscribe(notificationAddedToEvent.current);
53
60
  };
54
61
  }, [data]);
@@ -34,21 +34,29 @@ export default function useSCSubscribedGroupsManager(user) {
34
34
  CONFIGURATIONS_GROUPS_ENABLED in preferences &&
35
35
  preferences[CONFIGURATIONS_GROUPS_ENABLED].value, [preferences, features]);
36
36
  const notificationInvitedToJoinGroup = useRef(null);
37
- const notificationRequestedToJoinGroup = useRef(null);
38
- const notificationAcceptedToJoinGroup = useRef(null);
37
+ // const notificationRequestedToJoinGroup = useRef(null);
38
+ // const notificationAcceptedToJoinGroup = useRef(null);
39
39
  const notificationAddedToGroup = useRef(null);
40
40
  /**
41
41
  * Subscribe to notification types user_follow, user_unfollow
42
42
  */
43
43
  useDeepCompareEffectNoCheck(() => {
44
44
  notificationInvitedToJoinGroup.current = PubSub.subscribe(`${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_INVITED_TO_JOIN_GROUP}`, notificationSubscriber);
45
- notificationRequestedToJoinGroup.current = PubSub.subscribe(`${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_REQUESTED_TO_JOIN_GROUP}`, notificationSubscriber);
46
- notificationAcceptedToJoinGroup.current = PubSub.subscribe(`${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_ACCEPTED_TO_JOIN_GROUP}`, notificationSubscriber);
45
+ /*
46
+ notificationRequestedToJoinGroup.current = PubSub.subscribe(
47
+ `${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_REQUESTED_TO_JOIN_GROUP}`,
48
+ notificationSubscriber
49
+ );
50
+ notificationAcceptedToJoinGroup.current = PubSub.subscribe(
51
+ `${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_ACCEPTED_TO_JOIN_GROUP}`,
52
+ notificationSubscriber
53
+ );
54
+ */
47
55
  notificationAddedToGroup.current = PubSub.subscribe(`${SCNotificationTopicType.INTERACTION}.${SCNotificationTypologyType.USER_ADDED_TO_GROUP}`, notificationSubscriber);
48
56
  return () => {
49
57
  PubSub.unsubscribe(notificationInvitedToJoinGroup.current);
50
- PubSub.unsubscribe(notificationRequestedToJoinGroup.current);
51
- PubSub.unsubscribe(notificationAcceptedToJoinGroup.current);
58
+ // PubSub.unsubscribe(notificationRequestedToJoinGroup.current);
59
+ // PubSub.unsubscribe(notificationAcceptedToJoinGroup.current);
52
60
  PubSub.unsubscribe(notificationAddedToGroup.current);
53
61
  };
54
62
  }, [data]);