@gen3/frontend 0.11.26 → 0.11.28

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.
Files changed (149) hide show
  1. package/dist/cjs/index.js +44 -6
  2. package/dist/cjs/index.js.map +1 -1
  3. package/dist/dts/components/Providers/Gen3Provider.d.ts +6 -6
  4. package/dist/dts/components/SegmentedControl.stories.d.ts +374 -0
  5. package/dist/dts/components/SegmentedControl.stories.d.ts.map +1 -0
  6. package/dist/dts/components/SegmentedControl.stories.js +28 -0
  7. package/dist/dts/components/SegmentedControl.stories.js.map +1 -0
  8. package/dist/dts/features/Analysis/AnalysisCardCompact.stories.d.ts +4 -4
  9. package/dist/dts/features/CohortBuilder/ExplorerTable/AccessCellRenderers.d.ts +3 -0
  10. package/dist/dts/features/CohortBuilder/ExplorerTable/AccessCellRenderers.d.ts.map +1 -0
  11. package/dist/dts/features/CohortBuilder/ExplorerTable/AccessCellRenderers.js +46 -0
  12. package/dist/dts/features/CohortBuilder/ExplorerTable/AccessCellRenderers.js.map +1 -0
  13. package/dist/dts/features/CohortBuilder/Repository/Repository.d.ts +4 -0
  14. package/dist/dts/features/CohortBuilder/Repository/Repository.d.ts.map +1 -0
  15. package/dist/dts/features/CohortBuilder/Repository/Repository.js +8 -0
  16. package/dist/dts/features/CohortBuilder/Repository/Repository.js.map +1 -0
  17. package/dist/dts/features/CohortBuilder/Repository/index.d.ts +4 -0
  18. package/dist/dts/features/CohortBuilder/Repository/index.d.ts.map +1 -0
  19. package/dist/dts/features/CohortBuilder/Repository/index.js +3 -0
  20. package/dist/dts/features/CohortBuilder/Repository/index.js.map +1 -0
  21. package/dist/dts/features/CohortBuilder/Repository/types.d.ts +12 -0
  22. package/dist/dts/features/CohortBuilder/Repository/types.d.ts.map +1 -0
  23. package/dist/dts/features/CohortBuilder/Repository/types.js.map +1 -0
  24. package/dist/dts/lib/session/session.d.ts.map +1 -1
  25. package/dist/dts/lib/session/session.js +36 -1
  26. package/dist/dts/lib/session/session.js.map +1 -1
  27. package/dist/dts/pages/Repository/Repository.d.ts +4 -0
  28. package/dist/dts/pages/Repository/Repository.d.ts.map +1 -0
  29. package/dist/dts/pages/Repository/Repository.js +24 -0
  30. package/dist/dts/pages/Repository/Repository.js.map +1 -0
  31. package/dist/dts/pages/Repository/data.d.ts +4 -0
  32. package/dist/dts/pages/Repository/data.d.ts.map +1 -0
  33. package/dist/dts/{features/CohortBuilder/CohortManager/cohortActionHooks.js → pages/Repository/data.js} +55 -42
  34. package/dist/dts/pages/Repository/data.js.map +1 -0
  35. package/dist/dts/pages/Repository/index.d.ts +4 -0
  36. package/dist/dts/pages/Repository/index.d.ts.map +1 -0
  37. package/dist/dts/pages/Repository/index.js +4 -0
  38. package/dist/dts/pages/Repository/index.js.map +1 -0
  39. package/dist/dts/pages/Repository/types.d.ts +6 -0
  40. package/dist/dts/pages/Repository/types.d.ts.map +1 -0
  41. package/dist/dts/pages/Repository/types.js +2 -0
  42. package/dist/dts/pages/Repository/types.js.map +1 -0
  43. package/dist/dts/pages/TabbedCohortBuilder/TabbedCohortBuilderPage.d.ts.map +1 -1
  44. package/dist/dts/pages/TabbedCohortBuilder/TabbedCohortBuilderPage.js +3 -2
  45. package/dist/dts/pages/TabbedCohortBuilder/TabbedCohortBuilderPage.js.map +1 -1
  46. package/dist/dts/types/icons.d.ts +2 -2
  47. package/dist/dts/types/icons.d.ts.map +1 -1
  48. package/dist/dts/types/icons.js +2 -2
  49. package/dist/dts/types/icons.js.map +1 -1
  50. package/dist/esm/index.js +45 -7
  51. package/dist/esm/index.js.map +1 -1
  52. package/dist/index.d.ts +6 -6
  53. package/dist/tsconfig.tsbuildinfo +1 -1
  54. package/package.json +3 -3
  55. package/dist/dts/components/DropdownMenu/DropdownMenu.d.ts +0 -64
  56. package/dist/dts/components/DropdownMenu/DropdownMenu.d.ts.map +0 -1
  57. package/dist/dts/components/DropdownMenu/DropdownMenu.js +0 -38
  58. package/dist/dts/components/DropdownMenu/DropdownMenu.js.map +0 -1
  59. package/dist/dts/components/DropdownMenu/DropdownMenu.unit.test.d.ts +0 -2
  60. package/dist/dts/components/DropdownMenu/DropdownMenu.unit.test.d.ts.map +0 -1
  61. package/dist/dts/components/DropdownMenu/DropdownMenu.unit.test.js +0 -141
  62. package/dist/dts/components/DropdownMenu/DropdownMenu.unit.test.js.map +0 -1
  63. package/dist/dts/components/DropdownMenu/index.d.ts +0 -3
  64. package/dist/dts/components/DropdownMenu/index.d.ts.map +0 -1
  65. package/dist/dts/components/DropdownMenu/index.js +0 -3
  66. package/dist/dts/components/DropdownMenu/index.js.map +0 -1
  67. package/dist/dts/components/MessageCards/ErrorMessage.d.ts +0 -7
  68. package/dist/dts/components/MessageCards/ErrorMessage.d.ts.map +0 -1
  69. package/dist/dts/components/MessageCards/ErrorMessage.js +0 -8
  70. package/dist/dts/components/MessageCards/ErrorMessage.js.map +0 -1
  71. package/dist/dts/features/CohortBuilder/CohortManager/CohortActions.d.ts +0 -20
  72. package/dist/dts/features/CohortBuilder/CohortManager/CohortActions.d.ts.map +0 -1
  73. package/dist/dts/features/CohortBuilder/CohortManager/CohortActions.js +0 -37
  74. package/dist/dts/features/CohortBuilder/CohortManager/CohortActions.js.map +0 -1
  75. package/dist/dts/features/CohortBuilder/CohortManager/CohortNotificationProvider.d.ts +0 -9
  76. package/dist/dts/features/CohortBuilder/CohortManager/CohortNotificationProvider.d.ts.map +0 -1
  77. package/dist/dts/features/CohortBuilder/CohortManager/CohortNotificationProvider.js +0 -122
  78. package/dist/dts/features/CohortBuilder/CohortManager/CohortNotificationProvider.js.map +0 -1
  79. package/dist/dts/features/CohortBuilder/CohortManager/CohortNotifications.d.ts +0 -19
  80. package/dist/dts/features/CohortBuilder/CohortManager/CohortNotifications.d.ts.map +0 -1
  81. package/dist/dts/features/CohortBuilder/CohortManager/CohortNotifications.js +0 -52
  82. package/dist/dts/features/CohortBuilder/CohortManager/CohortNotifications.js.map +0 -1
  83. package/dist/dts/features/CohortBuilder/CohortManager/CohortSelector.d.ts +0 -10
  84. package/dist/dts/features/CohortBuilder/CohortManager/CohortSelector.d.ts.map +0 -1
  85. package/dist/dts/features/CohortBuilder/CohortManager/CohortSelector.js +0 -37
  86. package/dist/dts/features/CohortBuilder/CohortManager/CohortSelector.js.map +0 -1
  87. package/dist/dts/features/CohortBuilder/CohortManager/CustomCohortSelectItem.d.ts +0 -13
  88. package/dist/dts/features/CohortBuilder/CohortManager/CustomCohortSelectItem.d.ts.map +0 -1
  89. package/dist/dts/features/CohortBuilder/CohortManager/CustomCohortSelectItem.js +0 -33
  90. package/dist/dts/features/CohortBuilder/CohortManager/CustomCohortSelectItem.js.map +0 -1
  91. package/dist/dts/features/CohortBuilder/CohortManager/cohortActionHooks.d.ts +0 -7
  92. package/dist/dts/features/CohortBuilder/CohortManager/cohortActionHooks.d.ts.map +0 -1
  93. package/dist/dts/features/CohortBuilder/CohortManager/cohortActionHooks.js.map +0 -1
  94. package/dist/dts/features/CohortBuilder/CohortManager/commonIcons.d.ts +0 -5
  95. package/dist/dts/features/CohortBuilder/CohortManager/commonIcons.d.ts.map +0 -1
  96. package/dist/dts/features/CohortBuilder/CohortManager/commonIcons.js +0 -5
  97. package/dist/dts/features/CohortBuilder/CohortManager/commonIcons.js.map +0 -1
  98. package/dist/dts/features/CohortBuilder/CohortManager/index.d.ts +0 -5
  99. package/dist/dts/features/CohortBuilder/CohortManager/index.d.ts.map +0 -1
  100. package/dist/dts/features/CohortBuilder/CohortManager/index.js +0 -4
  101. package/dist/dts/features/CohortBuilder/CohortManager/index.js.map +0 -1
  102. package/dist/dts/features/CohortBuilder/CohortManager/modals/GenericCohortModal.d.ts +0 -13
  103. package/dist/dts/features/CohortBuilder/CohortManager/modals/GenericCohortModal.d.ts.map +0 -1
  104. package/dist/dts/features/CohortBuilder/CohortManager/modals/GenericCohortModal.js +0 -15
  105. package/dist/dts/features/CohortBuilder/CohortManager/modals/GenericCohortModal.js.map +0 -1
  106. package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortErrorModal.d.ts +0 -4
  107. package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortErrorModal.d.ts.map +0 -1
  108. package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortErrorModal.js +0 -8
  109. package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortErrorModal.js.map +0 -1
  110. package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.d.ts +0 -32
  111. package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.d.ts.map +0 -1
  112. package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.js +0 -190
  113. package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.js.map +0 -1
  114. package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.unit.test.d.ts +0 -2
  115. package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.unit.test.d.ts.map +0 -1
  116. package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.unit.test.js +0 -145
  117. package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.unit.test.js.map +0 -1
  118. package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveOrCreateEntityModal.d.ts +0 -29
  119. package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveOrCreateEntityModal.d.ts.map +0 -1
  120. package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveOrCreateEntityModal.js +0 -79
  121. package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveOrCreateEntityModal.js.map +0 -1
  122. package/dist/dts/features/CohortBuilder/CohortManager/style.d.ts +0 -5
  123. package/dist/dts/features/CohortBuilder/CohortManager/style.d.ts.map +0 -1
  124. package/dist/dts/features/CohortBuilder/CohortManager/style.js +0 -21
  125. package/dist/dts/features/CohortBuilder/CohortManager/style.js.map +0 -1
  126. package/dist/dts/features/CohortBuilder/CohortManager/types.d.ts +0 -49
  127. package/dist/dts/features/CohortBuilder/CohortManager/types.d.ts.map +0 -1
  128. package/dist/dts/features/CohortBuilder/CohortManager/types.js.map +0 -1
  129. package/dist/dts/features/CohortBuilder/CohortManager.d.ts +0 -6
  130. package/dist/dts/features/CohortBuilder/CohortManager.d.ts.map +0 -1
  131. package/dist/dts/features/CohortBuilder/CohortManager.js +0 -8
  132. package/dist/dts/features/CohortBuilder/CohortManager.js.map +0 -1
  133. package/dist/dts/features/CohortDiscovery/CohortManagment/CohortStorage.d.ts +0 -64
  134. package/dist/dts/features/CohortDiscovery/CohortManagment/CohortStorage.d.ts.map +0 -1
  135. package/dist/dts/features/CohortDiscovery/CohortManagment/CohortStorage.js +0 -572
  136. package/dist/dts/features/CohortDiscovery/CohortManagment/CohortStorage.js.map +0 -1
  137. package/dist/dts/features/CohortDiscovery/CohortSelectors.d.ts +0 -1
  138. package/dist/dts/features/CohortDiscovery/CohortSelectors.d.ts.map +0 -1
  139. package/dist/dts/features/CohortDiscovery/CohortSelectors.js +0 -41
  140. package/dist/dts/features/CohortDiscovery/CohortSelectors.js.map +0 -1
  141. package/dist/dts/features/CohortDiscovery/CohortSlice.d.ts +0 -1
  142. package/dist/dts/features/CohortDiscovery/CohortSlice.d.ts.map +0 -1
  143. package/dist/dts/features/CohortDiscovery/CohortSlice.js +0 -162
  144. package/dist/dts/features/CohortDiscovery/CohortSlice.js.map +0 -1
  145. package/dist/dts/features/CohortDiscovery/SavedCohortManagerSlice.d.ts +0 -1
  146. package/dist/dts/features/CohortDiscovery/SavedCohortManagerSlice.d.ts.map +0 -1
  147. package/dist/dts/features/CohortDiscovery/SavedCohortManagerSlice.js +0 -284
  148. package/dist/dts/features/CohortDiscovery/SavedCohortManagerSlice.js.map +0 -1
  149. /package/dist/dts/features/CohortBuilder/{CohortManager → Repository}/types.js +0 -0
package/dist/cjs/index.js CHANGED
@@ -880,6 +880,7 @@ const workspaceShutdownAlertLimit = 30000; // 5 minutes: 5 * 60 * 1000 TODO Figu
880
880
  }
881
881
  };
882
882
 
883
+ const ACTIVITY_CHANNEL = 'gen3-user-activity';
883
884
  const logoutSession = async ()=>{
884
885
  // logged in using credentials then execute credentials logout first
885
886
  const accessToken = cookiesNext.getCookie('credentials_token');
@@ -963,6 +964,27 @@ const UPDATE_SESSION_LIMIT = MinutesToMilliseconds(5);
963
964
  const [getUserDetails] = core.useLazyFetchUserDetailsQuery(); // Fetch user details
964
965
  const userStatus = core.useCoreSelector((state)=>core.selectUserAuthStatus(state));
965
966
  const [mostRecentActivityTimestamp, setMostRecentActivityTimestamp] = React.useState(Date.now());
967
+ const broadcastChannelRef = React.useRef(null);
968
+ // Initialize BroadcastChannel for cross-tab communication
969
+ // any user event on one tab or window will update mostRecentActivityTimestamp
970
+ React.useEffect(()=>{
971
+ if (typeof window !== 'undefined') {
972
+ broadcastChannelRef.current = new BroadcastChannel(ACTIVITY_CHANNEL);
973
+ // Listen for activity updates from other tabs
974
+ const handleActivityMessage = (event)=>{
975
+ if (event.data.type === 'activity-update') {
976
+ setMostRecentActivityTimestamp(event.data.timestamp);
977
+ }
978
+ };
979
+ broadcastChannelRef.current.addEventListener('message', handleActivityMessage);
980
+ return ()=>{
981
+ if (broadcastChannelRef.current) {
982
+ broadcastChannelRef.current.removeEventListener('message', handleActivityMessage);
983
+ broadcastChannelRef.current.close();
984
+ }
985
+ };
986
+ }
987
+ }, []);
966
988
  const [mostRecentSessionRefreshTimestamp, setMostRecentSessionRefreshTimestamp] = React.useState(Date.now());
967
989
  const inactiveTimeLimitMilliseconds = MinutesToMilliseconds(inactiveTimeLimit);
968
990
  const workspaceInactivityTimeLimitMilliseconds = MinutesToMilliseconds(workspaceInactivityTimeLimit);
@@ -999,15 +1021,28 @@ const UPDATE_SESSION_LIMIT = MinutesToMilliseconds(5);
999
1021
  updateSession();
1000
1022
  if (updateSessionIntervalMilliseconds <= 0) return; // do not poll if updateSessionInterval is 0
1001
1023
  const updateUserActivity = ()=>{
1002
- setMostRecentActivityTimestamp(Date.now());
1024
+ const timestamp = Date.now();
1025
+ setMostRecentActivityTimestamp(timestamp);
1026
+ if (broadcastChannelRef.current) {
1027
+ broadcastChannelRef.current.postMessage({
1028
+ type: 'activity-update',
1029
+ timestamp
1030
+ });
1031
+ }
1003
1032
  };
1004
1033
  window.addEventListener('mousedown', updateUserActivity);
1005
1034
  window.addEventListener('keypress', updateUserActivity);
1006
1035
  window.addEventListener('updateUserActivity', updateUserActivity);
1036
+ window.addEventListener('scroll', updateUserActivity);
1037
+ window.addEventListener('click', updateUserActivity);
1038
+ window.addEventListener('touchstart', updateUserActivity);
1007
1039
  return ()=>{
1008
1040
  window.removeEventListener('mousedown', updateUserActivity);
1009
1041
  window.removeEventListener('keypress', updateUserActivity);
1010
1042
  window.removeEventListener('updateUserActivity', updateUserActivity);
1043
+ window.removeEventListener('scroll', updateUserActivity);
1044
+ window.removeEventListener('click', updateUserActivity);
1045
+ window.removeEventListener('touchstart', updateUserActivity);
1011
1046
  };
1012
1047
  }, []); // only call on mount/dismount
1013
1048
  useInterval(()=>{
@@ -25859,14 +25894,17 @@ const TabbedCohortBuilderPage = ({ headerProps, footerProps, configuration })=>{
25859
25894
  root: 'w-full'
25860
25895
  },
25861
25896
  children: [
25862
- /*#__PURE__*/ jsxRuntime.jsx("div", {
25897
+ /*#__PURE__*/ jsxRuntime.jsxs("div", {
25863
25898
  className: "w-full flex-col flex gap-4 fixed bg-white z-10",
25864
- children: /*#__PURE__*/ jsxRuntime.jsx(CohortManagerAndExpression, {
25865
- index: configuration.index
25866
- })
25899
+ children: [
25900
+ /*#__PURE__*/ jsxRuntime.jsx(CohortManager$1, {}),
25901
+ /*#__PURE__*/ jsxRuntime.jsx(QueryExpression, {
25902
+ index: configuration.index
25903
+ })
25904
+ ]
25867
25905
  }),
25868
25906
  /*#__PURE__*/ jsxRuntime.jsx("div", {
25869
- className: "w-full mt-40 mr-4",
25907
+ className: "w-full mt-60 mr-4",
25870
25908
  children: /*#__PURE__*/ jsxRuntime.jsx(TabbedCohortBuilder, {
25871
25909
  ...configuration
25872
25910
  })