@gen3/frontend 0.11.26 → 0.11.27
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/dist/cjs/index.js +36 -1
- package/dist/cjs/index.js.map +1 -1
- package/dist/dts/components/Providers/Gen3Provider.d.ts +6 -6
- package/dist/dts/components/SegmentedControl.stories.d.ts +374 -0
- package/dist/dts/components/SegmentedControl.stories.d.ts.map +1 -0
- package/dist/dts/components/SegmentedControl.stories.js +28 -0
- package/dist/dts/components/SegmentedControl.stories.js.map +1 -0
- package/dist/dts/features/Analysis/AnalysisCardCompact.stories.d.ts +4 -4
- package/dist/dts/features/CohortBuilder/ExplorerTable/AccessCellRenderers.d.ts +3 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/AccessCellRenderers.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/AccessCellRenderers.js +46 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/AccessCellRenderers.js.map +1 -0
- package/dist/dts/features/CohortBuilder/ExplorerTable/ArrayCellRenderer.d.ts +1 -1
- package/dist/dts/features/CohortBuilder/Repository/Repository.d.ts +4 -0
- package/dist/dts/features/CohortBuilder/Repository/Repository.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/Repository/Repository.js +8 -0
- package/dist/dts/features/CohortBuilder/Repository/Repository.js.map +1 -0
- package/dist/dts/features/CohortBuilder/Repository/index.d.ts +4 -0
- package/dist/dts/features/CohortBuilder/Repository/index.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/Repository/index.js +3 -0
- package/dist/dts/features/CohortBuilder/Repository/index.js.map +1 -0
- package/dist/dts/features/CohortBuilder/Repository/types.d.ts +12 -0
- package/dist/dts/features/CohortBuilder/Repository/types.d.ts.map +1 -0
- package/dist/dts/features/CohortBuilder/Repository/types.js.map +1 -0
- package/dist/dts/lib/session/session.d.ts.map +1 -1
- package/dist/dts/lib/session/session.js +36 -1
- package/dist/dts/lib/session/session.js.map +1 -1
- package/dist/dts/pages/Repository/Repository.d.ts +4 -0
- package/dist/dts/pages/Repository/Repository.d.ts.map +1 -0
- package/dist/dts/pages/Repository/Repository.js +24 -0
- package/dist/dts/pages/Repository/Repository.js.map +1 -0
- package/dist/dts/pages/Repository/data.d.ts +4 -0
- package/dist/dts/pages/Repository/data.d.ts.map +1 -0
- package/dist/dts/{features/CohortBuilder/CohortManager/cohortActionHooks.js → pages/Repository/data.js} +55 -42
- package/dist/dts/pages/Repository/data.js.map +1 -0
- package/dist/dts/pages/Repository/index.d.ts +4 -0
- package/dist/dts/pages/Repository/index.d.ts.map +1 -0
- package/dist/dts/pages/Repository/index.js +4 -0
- package/dist/dts/pages/Repository/index.js.map +1 -0
- package/dist/dts/pages/Repository/types.d.ts +6 -0
- package/dist/dts/pages/Repository/types.d.ts.map +1 -0
- package/dist/dts/pages/Repository/types.js +2 -0
- package/dist/dts/pages/Repository/types.js.map +1 -0
- package/dist/dts/types/icons.d.ts +2 -2
- package/dist/dts/types/icons.d.ts.map +1 -1
- package/dist/dts/types/icons.js +2 -2
- package/dist/dts/types/icons.js.map +1 -1
- package/dist/esm/index.js +37 -2
- package/dist/esm/index.js.map +1 -1
- package/dist/index.d.ts +6 -6
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +3 -3
- package/dist/dts/components/DropdownMenu/DropdownMenu.d.ts +0 -64
- package/dist/dts/components/DropdownMenu/DropdownMenu.d.ts.map +0 -1
- package/dist/dts/components/DropdownMenu/DropdownMenu.js +0 -38
- package/dist/dts/components/DropdownMenu/DropdownMenu.js.map +0 -1
- package/dist/dts/components/DropdownMenu/DropdownMenu.unit.test.d.ts +0 -2
- package/dist/dts/components/DropdownMenu/DropdownMenu.unit.test.d.ts.map +0 -1
- package/dist/dts/components/DropdownMenu/DropdownMenu.unit.test.js +0 -141
- package/dist/dts/components/DropdownMenu/DropdownMenu.unit.test.js.map +0 -1
- package/dist/dts/components/DropdownMenu/index.d.ts +0 -3
- package/dist/dts/components/DropdownMenu/index.d.ts.map +0 -1
- package/dist/dts/components/DropdownMenu/index.js +0 -3
- package/dist/dts/components/DropdownMenu/index.js.map +0 -1
- package/dist/dts/components/MessageCards/ErrorMessage.d.ts +0 -7
- package/dist/dts/components/MessageCards/ErrorMessage.d.ts.map +0 -1
- package/dist/dts/components/MessageCards/ErrorMessage.js +0 -8
- package/dist/dts/components/MessageCards/ErrorMessage.js.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/CohortActions.d.ts +0 -20
- package/dist/dts/features/CohortBuilder/CohortManager/CohortActions.d.ts.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/CohortActions.js +0 -37
- package/dist/dts/features/CohortBuilder/CohortManager/CohortActions.js.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/CohortNotificationProvider.d.ts +0 -9
- package/dist/dts/features/CohortBuilder/CohortManager/CohortNotificationProvider.d.ts.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/CohortNotificationProvider.js +0 -122
- package/dist/dts/features/CohortBuilder/CohortManager/CohortNotificationProvider.js.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/CohortNotifications.d.ts +0 -19
- package/dist/dts/features/CohortBuilder/CohortManager/CohortNotifications.d.ts.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/CohortNotifications.js +0 -52
- package/dist/dts/features/CohortBuilder/CohortManager/CohortNotifications.js.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/CohortSelector.d.ts +0 -10
- package/dist/dts/features/CohortBuilder/CohortManager/CohortSelector.d.ts.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/CohortSelector.js +0 -37
- package/dist/dts/features/CohortBuilder/CohortManager/CohortSelector.js.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/CustomCohortSelectItem.d.ts +0 -13
- package/dist/dts/features/CohortBuilder/CohortManager/CustomCohortSelectItem.d.ts.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/CustomCohortSelectItem.js +0 -33
- package/dist/dts/features/CohortBuilder/CohortManager/CustomCohortSelectItem.js.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/cohortActionHooks.d.ts +0 -7
- package/dist/dts/features/CohortBuilder/CohortManager/cohortActionHooks.d.ts.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/cohortActionHooks.js.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/commonIcons.d.ts +0 -5
- package/dist/dts/features/CohortBuilder/CohortManager/commonIcons.d.ts.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/commonIcons.js +0 -5
- package/dist/dts/features/CohortBuilder/CohortManager/commonIcons.js.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/index.d.ts +0 -5
- package/dist/dts/features/CohortBuilder/CohortManager/index.d.ts.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/index.js +0 -4
- package/dist/dts/features/CohortBuilder/CohortManager/index.js.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/modals/GenericCohortModal.d.ts +0 -13
- package/dist/dts/features/CohortBuilder/CohortManager/modals/GenericCohortModal.d.ts.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/modals/GenericCohortModal.js +0 -15
- package/dist/dts/features/CohortBuilder/CohortManager/modals/GenericCohortModal.js.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortErrorModal.d.ts +0 -4
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortErrorModal.d.ts.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortErrorModal.js +0 -8
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortErrorModal.js.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.d.ts +0 -32
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.d.ts.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.js +0 -190
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.js.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.unit.test.d.ts +0 -2
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.unit.test.d.ts.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.unit.test.js +0 -145
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveCohortModal.unit.test.js.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveOrCreateEntityModal.d.ts +0 -29
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveOrCreateEntityModal.d.ts.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveOrCreateEntityModal.js +0 -79
- package/dist/dts/features/CohortBuilder/CohortManager/modals/SaveOrCreateEntityModal.js.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/style.d.ts +0 -5
- package/dist/dts/features/CohortBuilder/CohortManager/style.d.ts.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/style.js +0 -21
- package/dist/dts/features/CohortBuilder/CohortManager/style.js.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/types.d.ts +0 -49
- package/dist/dts/features/CohortBuilder/CohortManager/types.d.ts.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager/types.js.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager.d.ts +0 -6
- package/dist/dts/features/CohortBuilder/CohortManager.d.ts.map +0 -1
- package/dist/dts/features/CohortBuilder/CohortManager.js +0 -8
- package/dist/dts/features/CohortBuilder/CohortManager.js.map +0 -1
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortStorage.d.ts +0 -64
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortStorage.d.ts.map +0 -1
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortStorage.js +0 -572
- package/dist/dts/features/CohortDiscovery/CohortManagment/CohortStorage.js.map +0 -1
- package/dist/dts/features/CohortDiscovery/CohortSelectors.d.ts +0 -1
- package/dist/dts/features/CohortDiscovery/CohortSelectors.d.ts.map +0 -1
- package/dist/dts/features/CohortDiscovery/CohortSelectors.js +0 -41
- package/dist/dts/features/CohortDiscovery/CohortSelectors.js.map +0 -1
- package/dist/dts/features/CohortDiscovery/CohortSlice.d.ts +0 -1
- package/dist/dts/features/CohortDiscovery/CohortSlice.d.ts.map +0 -1
- package/dist/dts/features/CohortDiscovery/CohortSlice.js +0 -162
- package/dist/dts/features/CohortDiscovery/CohortSlice.js.map +0 -1
- package/dist/dts/features/CohortDiscovery/SavedCohortManagerSlice.d.ts +0 -1
- package/dist/dts/features/CohortDiscovery/SavedCohortManagerSlice.d.ts.map +0 -1
- package/dist/dts/features/CohortDiscovery/SavedCohortManagerSlice.js +0 -284
- package/dist/dts/features/CohortDiscovery/SavedCohortManagerSlice.js.map +0 -1
- /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
|
-
|
|
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(()=>{
|