quidproquo-web-react 0.0.254 → 0.0.255
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/commonjs/api/hooks/index.d.ts +2 -2
- package/lib/commonjs/api/hooks/index.js +18 -18
- package/lib/commonjs/api/hooks/useAuthenticatedNetworkRequest.d.ts +2 -2
- package/lib/commonjs/api/hooks/useAuthenticatedNetworkRequest.js +14 -14
- package/lib/commonjs/api/hooks/useNetworkRequest.d.ts +2 -2
- package/lib/commonjs/api/hooks/useNetworkRequest.js +10 -10
- package/lib/commonjs/api/index.d.ts +1 -1
- package/lib/commonjs/api/index.js +17 -17
- package/lib/commonjs/auth/RefreshAuthTokensProvider.d.ts +7 -8
- package/lib/commonjs/auth/RefreshAuthTokensProvider.js +12 -12
- package/lib/commonjs/auth/authContext.d.ts +2 -3
- package/lib/commonjs/auth/authContext.js +8 -8
- package/lib/commonjs/auth/hooks/index.d.ts +3 -3
- package/lib/commonjs/auth/hooks/index.js +19 -19
- package/lib/commonjs/auth/hooks/useAuthAccessToken.d.ts +1 -1
- package/lib/commonjs/auth/hooks/useAuthAccessToken.js +12 -12
- package/lib/commonjs/auth/hooks/useIsLoggedIn.d.ts +1 -1
- package/lib/commonjs/auth/hooks/useIsLoggedIn.js +9 -9
- package/lib/commonjs/auth/hooks/useRefreshTokens.d.ts +2 -2
- package/lib/commonjs/auth/hooks/useRefreshTokens.js +35 -35
- package/lib/commonjs/auth/index.d.ts +4 -4
- package/lib/commonjs/auth/index.js +20 -20
- package/lib/commonjs/auth/types/AuthState.d.ts +8 -8
- package/lib/commonjs/auth/types/AuthState.js +2 -2
- package/lib/commonjs/auth/types/index.d.ts +1 -1
- package/lib/commonjs/auth/types/index.js +17 -17
- package/lib/commonjs/baseUrl/BaseUrlContext.d.ts +2 -3
- package/lib/commonjs/baseUrl/BaseUrlContext.js +9 -9
- package/lib/commonjs/baseUrl/BaseUrlProvider.d.ts +6 -7
- package/lib/commonjs/baseUrl/BaseUrlProvider.js +9 -9
- package/lib/commonjs/baseUrl/hooks/index.d.ts +1 -1
- package/lib/commonjs/baseUrl/hooks/index.js +17 -17
- package/lib/commonjs/baseUrl/hooks/useBaseUrlResolvers.d.ts +2 -2
- package/lib/commonjs/baseUrl/hooks/useBaseUrlResolvers.js +10 -10
- package/lib/commonjs/baseUrl/index.d.ts +3 -3
- package/lib/commonjs/baseUrl/index.js +19 -19
- package/lib/commonjs/baseUrl/types/BaseUrlResolver.d.ts +6 -6
- package/lib/commonjs/baseUrl/types/BaseUrlResolver.js +2 -2
- package/lib/commonjs/baseUrl/types/index.d.ts +1 -1
- package/lib/commonjs/baseUrl/types/index.js +17 -17
- package/lib/commonjs/hooks/asmj/QpqContextProvider.d.ts +10 -10
- package/lib/commonjs/hooks/asmj/QpqContextProvider.js +20 -20
- package/lib/commonjs/hooks/asmj/QpqMappedApi.d.ts +6 -6
- package/lib/commonjs/hooks/asmj/QpqMappedApi.js +2 -2
- package/lib/commonjs/hooks/asmj/QpqRuntimeEffectCatcher.d.ts +16 -16
- package/lib/commonjs/hooks/asmj/QpqRuntimeEffectCatcher.js +35 -35
- package/lib/commonjs/hooks/asmj/actionProcessor/getStateDispatchActionProcessor.d.ts +3 -3
- package/lib/commonjs/hooks/asmj/actionProcessor/getStateDispatchActionProcessor.js +23 -23
- package/lib/commonjs/hooks/asmj/actionProcessor/getStateReadActionProcessor.d.ts +2 -2
- package/lib/commonjs/hooks/asmj/actionProcessor/getStateReadActionProcessor.js +22 -22
- package/lib/commonjs/hooks/asmj/actionProcessor/index.d.ts +3 -3
- package/lib/commonjs/hooks/asmj/actionProcessor/index.js +18 -18
- package/lib/commonjs/hooks/asmj/createQpqRuntimeDefinition.d.ts +22 -22
- package/lib/commonjs/hooks/asmj/createQpqRuntimeDefinition.js +52 -53
- package/lib/commonjs/hooks/asmj/index.d.ts +6 -6
- package/lib/commonjs/hooks/asmj/index.js +22 -22
- package/lib/commonjs/hooks/asmj/useQpqRuntime.d.ts +4 -4
- package/lib/commonjs/hooks/asmj/useQpqRuntime.js +35 -36
- package/lib/commonjs/hooks/index.d.ts +8 -8
- package/lib/commonjs/hooks/index.js +24 -24
- package/lib/commonjs/hooks/useAsyncEffect.d.ts +2 -2
- package/lib/commonjs/hooks/useAsyncEffect.js +36 -36
- package/lib/commonjs/hooks/useFastCallback.d.ts +2 -2
- package/lib/commonjs/hooks/useFastCallback.js +19 -20
- package/lib/commonjs/hooks/useMetadata/index.d.ts +1 -1
- package/lib/commonjs/hooks/useMetadata/index.js +17 -17
- package/lib/commonjs/hooks/useMetadata/useMetadata.d.ts +5 -5
- package/lib/commonjs/hooks/useMetadata/useMetadata.js +14 -15
- package/lib/commonjs/hooks/useOnKeyDownEffect.d.ts +1 -1
- package/lib/commonjs/hooks/useOnKeyDownEffect.js +22 -23
- package/lib/commonjs/hooks/useQpq.d.ts +2 -2
- package/lib/commonjs/hooks/useQpq.js +45 -46
- package/lib/commonjs/hooks/useRunEvery.d.ts +1 -1
- package/lib/commonjs/hooks/useRunEvery.js +21 -22
- package/lib/commonjs/hooks/useThrottledMemo.d.ts +1 -1
- package/lib/commonjs/hooks/useThrottledMemo.js +31 -32
- package/lib/commonjs/index.d.ts +10 -10
- package/lib/commonjs/index.js +26 -26
- package/lib/commonjs/state/index.d.ts +1 -1
- package/lib/commonjs/state/index.js +17 -17
- package/lib/commonjs/state/useStateUpdater.d.ts +3 -4
- package/lib/commonjs/state/useStateUpdater.js +12 -12
- package/lib/commonjs/useFieldBinding/index.d.ts +1 -1
- package/lib/commonjs/useFieldBinding/index.js +17 -17
- package/lib/commonjs/useFieldBinding/useFieldBinding.d.ts +2 -2
- package/lib/commonjs/useFieldBinding/useFieldBinding.js +21 -21
- package/lib/commonjs/useSharedQueryParams/index.d.ts +2 -2
- package/lib/commonjs/useSharedQueryParams/index.js +18 -18
- package/lib/commonjs/useSharedQueryParams/logic/index.d.ts +4 -4
- package/lib/commonjs/useSharedQueryParams/logic/index.js +20 -20
- package/lib/commonjs/useSharedQueryParams/logic/runtime/askSetParam.d.ts +2 -2
- package/lib/commonjs/useSharedQueryParams/logic/runtime/askSetParam.js +9 -10
- package/lib/commonjs/useSharedQueryParams/logic/runtime/askSyncParams.d.ts +2 -2
- package/lib/commonjs/useSharedQueryParams/logic/runtime/askSyncParams.js +11 -12
- package/lib/commonjs/useSharedQueryParams/logic/runtime/index.d.ts +2 -2
- package/lib/commonjs/useSharedQueryParams/logic/runtime/index.js +18 -18
- package/lib/commonjs/useSharedQueryParams/logic/runtime/sharedQueryParamsLogic.d.ts +4 -4
- package/lib/commonjs/useSharedQueryParams/logic/runtime/sharedQueryParamsLogic.js +7 -7
- package/lib/commonjs/useSharedQueryParams/logic/sharedQueryParamsActionCreator.d.ts +2 -2
- package/lib/commonjs/useSharedQueryParams/logic/sharedQueryParamsActionCreator.js +11 -12
- package/lib/commonjs/useSharedQueryParams/logic/sharedQueryParamsReducer.d.ts +3 -3
- package/lib/commonjs/useSharedQueryParams/logic/sharedQueryParamsReducer.js +13 -13
- package/lib/commonjs/useSharedQueryParams/logic/sharedQueryParamsTypes.d.ts +10 -10
- package/lib/commonjs/useSharedQueryParams/logic/sharedQueryParamsTypes.js +7 -7
- package/lib/commonjs/useSharedQueryParams/sharedQueryParamsRuntime.d.ts +3 -3
- package/lib/commonjs/useSharedQueryParams/sharedQueryParamsRuntime.js +7 -7
- package/lib/commonjs/webSocketQueue/hooks/index.d.ts +2 -2
- package/lib/commonjs/webSocketQueue/hooks/index.js +18 -18
- package/lib/commonjs/webSocketQueue/hooks/useSubscribeToWebSocketQueueEvent.d.ts +3 -3
- package/lib/commonjs/webSocketQueue/hooks/useSubscribeToWebSocketQueueEvent.js +8 -8
- package/lib/commonjs/webSocketQueue/hooks/useWebsocketQueueSendEvent.d.ts +2 -2
- package/lib/commonjs/webSocketQueue/hooks/useWebsocketQueueSendEvent.js +9 -9
- package/lib/commonjs/webSocketQueue/index.d.ts +1 -1
- package/lib/commonjs/webSocketQueue/index.js +17 -17
- package/lib/commonjs/websocket/WebSocketAuthSync/WebSocketAuthSync.d.ts +6 -7
- package/lib/commonjs/websocket/WebSocketAuthSync/WebSocketAuthSync.js +14 -14
- package/lib/commonjs/websocket/WebSocketAuthSync/hooks/index.d.ts +2 -2
- package/lib/commonjs/websocket/WebSocketAuthSync/hooks/index.js +18 -18
- package/lib/commonjs/websocket/WebSocketAuthSync/hooks/useWebsocketAuthSync.d.ts +2 -2
- package/lib/commonjs/websocket/WebSocketAuthSync/hooks/useWebsocketAuthSync.js +37 -37
- package/lib/commonjs/websocket/WebSocketAuthSync/hooks/useWebsocketPingPong.d.ts +1 -1
- package/lib/commonjs/websocket/WebSocketAuthSync/hooks/useWebsocketPingPong.js +16 -16
- package/lib/commonjs/websocket/WebSocketAuthSync/index.d.ts +1 -1
- package/lib/commonjs/websocket/WebSocketAuthSync/index.js +17 -17
- package/lib/commonjs/websocket/WebsocketContext.d.ts +2 -3
- package/lib/commonjs/websocket/WebsocketContext.js +5 -5
- package/lib/commonjs/websocket/WebsocketProvider.d.ts +5 -6
- package/lib/commonjs/websocket/WebsocketProvider.js +11 -11
- package/lib/commonjs/websocket/hooks/index.d.ts +5 -5
- package/lib/commonjs/websocket/hooks/index.js +21 -21
- package/lib/commonjs/websocket/hooks/useSubscribeToWebSocketEvent.d.ts +3 -3
- package/lib/commonjs/websocket/hooks/useSubscribeToWebSocketEvent.js +17 -17
- package/lib/commonjs/websocket/hooks/useSubscribeToWebsocket.d.ts +2 -2
- package/lib/commonjs/websocket/hooks/useSubscribeToWebsocket.js +17 -17
- package/lib/commonjs/websocket/hooks/useWebsocketApi.d.ts +1 -1
- package/lib/commonjs/websocket/hooks/useWebsocketApi.js +10 -10
- package/lib/commonjs/websocket/hooks/useWebsocketManagement.d.ts +2 -2
- package/lib/commonjs/websocket/hooks/useWebsocketManagement.js +17 -17
- package/lib/commonjs/websocket/hooks/useWebsocketSendEvent.d.ts +2 -2
- package/lib/commonjs/websocket/hooks/useWebsocketSendEvent.js +15 -15
- package/lib/commonjs/websocket/index.d.ts +3 -3
- package/lib/commonjs/websocket/index.js +19 -19
- package/lib/esm/api/hooks/index.d.ts +2 -2
- package/lib/esm/api/hooks/index.js +2 -2
- package/lib/esm/api/hooks/useAuthenticatedNetworkRequest.d.ts +2 -2
- package/lib/esm/api/hooks/useAuthenticatedNetworkRequest.js +17 -17
- package/lib/esm/api/hooks/useNetworkRequest.d.ts +2 -2
- package/lib/esm/api/hooks/useNetworkRequest.js +6 -6
- package/lib/esm/api/index.d.ts +1 -1
- package/lib/esm/api/index.js +1 -1
- package/lib/esm/auth/RefreshAuthTokensProvider.d.ts +7 -8
- package/lib/esm/auth/RefreshAuthTokensProvider.js +9 -9
- package/lib/esm/auth/authContext.d.ts +2 -3
- package/lib/esm/auth/authContext.js +5 -5
- package/lib/esm/auth/hooks/index.d.ts +3 -3
- package/lib/esm/auth/hooks/index.js +3 -3
- package/lib/esm/auth/hooks/useAuthAccessToken.d.ts +1 -1
- package/lib/esm/auth/hooks/useAuthAccessToken.js +7 -7
- package/lib/esm/auth/hooks/useIsLoggedIn.d.ts +1 -1
- package/lib/esm/auth/hooks/useIsLoggedIn.js +5 -5
- package/lib/esm/auth/hooks/useRefreshTokens.d.ts +2 -2
- package/lib/esm/auth/hooks/useRefreshTokens.js +31 -31
- package/lib/esm/auth/index.d.ts +4 -4
- package/lib/esm/auth/index.js +4 -4
- package/lib/esm/auth/types/AuthState.d.ts +8 -8
- package/lib/esm/auth/types/AuthState.js +1 -1
- package/lib/esm/auth/types/index.d.ts +1 -1
- package/lib/esm/auth/types/index.js +1 -1
- package/lib/esm/baseUrl/BaseUrlContext.d.ts +2 -3
- package/lib/esm/baseUrl/BaseUrlContext.js +6 -6
- package/lib/esm/baseUrl/BaseUrlProvider.d.ts +6 -7
- package/lib/esm/baseUrl/BaseUrlProvider.js +5 -5
- package/lib/esm/baseUrl/hooks/index.d.ts +1 -1
- package/lib/esm/baseUrl/hooks/index.js +1 -1
- package/lib/esm/baseUrl/hooks/useBaseUrlResolvers.d.ts +2 -2
- package/lib/esm/baseUrl/hooks/useBaseUrlResolvers.js +6 -6
- package/lib/esm/baseUrl/index.d.ts +3 -3
- package/lib/esm/baseUrl/index.js +3 -3
- package/lib/esm/baseUrl/types/BaseUrlResolver.d.ts +6 -6
- package/lib/esm/baseUrl/types/BaseUrlResolver.js +1 -1
- package/lib/esm/baseUrl/types/index.d.ts +1 -1
- package/lib/esm/baseUrl/types/index.js +1 -1
- package/lib/esm/hooks/asmj/QpqContextProvider.d.ts +10 -10
- package/lib/esm/hooks/asmj/QpqContextProvider.js +15 -15
- package/lib/esm/hooks/asmj/QpqMappedApi.d.ts +6 -6
- package/lib/esm/hooks/asmj/QpqMappedApi.js +1 -1
- package/lib/esm/hooks/asmj/QpqRuntimeEffectCatcher.d.ts +16 -16
- package/lib/esm/hooks/asmj/QpqRuntimeEffectCatcher.js +30 -30
- package/lib/esm/hooks/asmj/actionProcessor/getStateDispatchActionProcessor.d.ts +3 -3
- package/lib/esm/hooks/asmj/actionProcessor/getStateDispatchActionProcessor.js +8 -8
- package/lib/esm/hooks/asmj/actionProcessor/getStateReadActionProcessor.d.ts +2 -2
- package/lib/esm/hooks/asmj/actionProcessor/getStateReadActionProcessor.js +7 -7
- package/lib/esm/hooks/asmj/actionProcessor/index.d.ts +3 -3
- package/lib/esm/hooks/asmj/actionProcessor/index.js +6 -6
- package/lib/esm/hooks/asmj/createQpqRuntimeDefinition.d.ts +22 -22
- package/lib/esm/hooks/asmj/createQpqRuntimeDefinition.js +46 -46
- package/lib/esm/hooks/asmj/index.d.ts +6 -6
- package/lib/esm/hooks/asmj/index.js +6 -6
- package/lib/esm/hooks/asmj/useQpqRuntime.d.ts +4 -4
- package/lib/esm/hooks/asmj/useQpqRuntime.js +32 -32
- package/lib/esm/hooks/index.d.ts +8 -8
- package/lib/esm/hooks/index.js +8 -8
- package/lib/esm/hooks/useAsyncEffect.d.ts +2 -2
- package/lib/esm/hooks/useAsyncEffect.js +23 -23
- package/lib/esm/hooks/useFastCallback.d.ts +2 -2
- package/lib/esm/hooks/useFastCallback.js +16 -16
- package/lib/esm/hooks/useMetadata/index.d.ts +1 -1
- package/lib/esm/hooks/useMetadata/index.js +1 -1
- package/lib/esm/hooks/useMetadata/useMetadata.d.ts +5 -5
- package/lib/esm/hooks/useMetadata/useMetadata.js +11 -11
- package/lib/esm/hooks/useOnKeyDownEffect.d.ts +1 -1
- package/lib/esm/hooks/useOnKeyDownEffect.js +19 -19
- package/lib/esm/hooks/useQpq.d.ts +2 -2
- package/lib/esm/hooks/useQpq.js +34 -34
- package/lib/esm/hooks/useRunEvery.d.ts +1 -1
- package/lib/esm/hooks/useRunEvery.js +18 -18
- package/lib/esm/hooks/useThrottledMemo.d.ts +1 -1
- package/lib/esm/hooks/useThrottledMemo.js +28 -28
- package/lib/esm/index.d.ts +10 -10
- package/lib/esm/index.js +10 -10
- package/lib/esm/state/index.d.ts +1 -1
- package/lib/esm/state/index.js +1 -1
- package/lib/esm/state/useStateUpdater.d.ts +3 -4
- package/lib/esm/state/useStateUpdater.js +11 -11
- package/lib/esm/useFieldBinding/index.d.ts +1 -1
- package/lib/esm/useFieldBinding/index.js +1 -1
- package/lib/esm/useFieldBinding/useFieldBinding.d.ts +2 -2
- package/lib/esm/useFieldBinding/useFieldBinding.js +17 -17
- package/lib/esm/useSharedQueryParams/index.d.ts +2 -2
- package/lib/esm/useSharedQueryParams/index.js +2 -2
- package/lib/esm/useSharedQueryParams/logic/index.d.ts +4 -4
- package/lib/esm/useSharedQueryParams/logic/index.js +4 -4
- package/lib/esm/useSharedQueryParams/logic/runtime/askSetParam.d.ts +2 -2
- package/lib/esm/useSharedQueryParams/logic/runtime/askSetParam.js +6 -6
- package/lib/esm/useSharedQueryParams/logic/runtime/askSyncParams.d.ts +2 -2
- package/lib/esm/useSharedQueryParams/logic/runtime/askSyncParams.js +8 -8
- package/lib/esm/useSharedQueryParams/logic/runtime/index.d.ts +2 -2
- package/lib/esm/useSharedQueryParams/logic/runtime/index.js +2 -2
- package/lib/esm/useSharedQueryParams/logic/runtime/sharedQueryParamsLogic.d.ts +4 -4
- package/lib/esm/useSharedQueryParams/logic/runtime/sharedQueryParamsLogic.js +4 -4
- package/lib/esm/useSharedQueryParams/logic/sharedQueryParamsActionCreator.d.ts +2 -2
- package/lib/esm/useSharedQueryParams/logic/sharedQueryParamsActionCreator.js +8 -8
- package/lib/esm/useSharedQueryParams/logic/sharedQueryParamsReducer.d.ts +3 -3
- package/lib/esm/useSharedQueryParams/logic/sharedQueryParamsReducer.js +10 -10
- package/lib/esm/useSharedQueryParams/logic/sharedQueryParamsTypes.d.ts +10 -10
- package/lib/esm/useSharedQueryParams/logic/sharedQueryParamsTypes.js +4 -4
- package/lib/esm/useSharedQueryParams/sharedQueryParamsRuntime.d.ts +3 -3
- package/lib/esm/useSharedQueryParams/sharedQueryParamsRuntime.js +4 -4
- package/lib/esm/webSocketQueue/hooks/index.d.ts +2 -2
- package/lib/esm/webSocketQueue/hooks/index.js +2 -2
- package/lib/esm/webSocketQueue/hooks/useSubscribeToWebSocketQueueEvent.d.ts +3 -3
- package/lib/esm/webSocketQueue/hooks/useSubscribeToWebSocketQueueEvent.js +4 -4
- package/lib/esm/webSocketQueue/hooks/useWebsocketQueueSendEvent.d.ts +2 -2
- package/lib/esm/webSocketQueue/hooks/useWebsocketQueueSendEvent.js +5 -5
- package/lib/esm/webSocketQueue/index.d.ts +1 -1
- package/lib/esm/webSocketQueue/index.js +1 -1
- package/lib/esm/websocket/WebSocketAuthSync/WebSocketAuthSync.d.ts +6 -7
- package/lib/esm/websocket/WebSocketAuthSync/WebSocketAuthSync.js +11 -11
- package/lib/esm/websocket/WebSocketAuthSync/hooks/index.d.ts +2 -2
- package/lib/esm/websocket/WebSocketAuthSync/hooks/index.js +2 -2
- package/lib/esm/websocket/WebSocketAuthSync/hooks/useWebsocketAuthSync.d.ts +2 -2
- package/lib/esm/websocket/WebSocketAuthSync/hooks/useWebsocketAuthSync.js +33 -33
- package/lib/esm/websocket/WebSocketAuthSync/hooks/useWebsocketPingPong.d.ts +1 -1
- package/lib/esm/websocket/WebSocketAuthSync/hooks/useWebsocketPingPong.js +12 -12
- package/lib/esm/websocket/WebSocketAuthSync/index.d.ts +1 -1
- package/lib/esm/websocket/WebSocketAuthSync/index.js +1 -1
- package/lib/esm/websocket/WebsocketContext.d.ts +2 -3
- package/lib/esm/websocket/WebsocketContext.js +2 -2
- package/lib/esm/websocket/WebsocketProvider.d.ts +5 -6
- package/lib/esm/websocket/WebsocketProvider.js +7 -7
- package/lib/esm/websocket/hooks/index.d.ts +5 -5
- package/lib/esm/websocket/hooks/index.js +5 -5
- package/lib/esm/websocket/hooks/useSubscribeToWebSocketEvent.d.ts +3 -3
- package/lib/esm/websocket/hooks/useSubscribeToWebSocketEvent.js +13 -13
- package/lib/esm/websocket/hooks/useSubscribeToWebsocket.d.ts +2 -2
- package/lib/esm/websocket/hooks/useSubscribeToWebsocket.js +13 -13
- package/lib/esm/websocket/hooks/useWebsocketApi.d.ts +1 -1
- package/lib/esm/websocket/hooks/useWebsocketApi.js +6 -6
- package/lib/esm/websocket/hooks/useWebsocketManagement.d.ts +2 -2
- package/lib/esm/websocket/hooks/useWebsocketManagement.js +13 -13
- package/lib/esm/websocket/hooks/useWebsocketSendEvent.d.ts +2 -2
- package/lib/esm/websocket/hooks/useWebsocketSendEvent.js +11 -11
- package/lib/esm/websocket/index.d.ts +3 -3
- package/lib/esm/websocket/index.js +3 -3
- package/package.json +8 -8
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { askSetParam } from './askSetParam';
|
|
2
|
-
export declare const sharedQueryParamsLogic: {
|
|
3
|
-
askSetParam: typeof askSetParam;
|
|
4
|
-
};
|
|
1
|
+
import { askSetParam } from './askSetParam';
|
|
2
|
+
export declare const sharedQueryParamsLogic: {
|
|
3
|
+
askSetParam: typeof askSetParam;
|
|
4
|
+
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { askSetParam } from './askSetParam';
|
|
2
|
-
export const sharedQueryParamsLogic = {
|
|
3
|
-
askSetParam,
|
|
4
|
-
};
|
|
1
|
+
import { askSetParam } from './askSetParam';
|
|
2
|
+
export const sharedQueryParamsLogic = {
|
|
3
|
+
askSetParam,
|
|
4
|
+
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { AskResponse } from 'quidproquo-core';
|
|
2
|
-
export declare function askSharedQueryParamsUISetParam(key: string, values: string[]): AskResponse<void>;
|
|
1
|
+
import { AskResponse } from 'quidproquo-core';
|
|
2
|
+
export declare function askSharedQueryParamsUISetParam(key: string, values: string[]): AskResponse<void>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { askStateDispatchEffect } from 'quidproquo-core';
|
|
2
|
-
import { SharedQueryParamsEffect } from './sharedQueryParamsTypes';
|
|
3
|
-
export function* askSharedQueryParamsUISetParam(key, values) {
|
|
4
|
-
yield* askStateDispatchEffect(SharedQueryParamsEffect.SetParam, {
|
|
5
|
-
key,
|
|
6
|
-
values,
|
|
7
|
-
});
|
|
8
|
-
}
|
|
1
|
+
import { askStateDispatchEffect } from 'quidproquo-core';
|
|
2
|
+
import { SharedQueryParamsEffect } from './sharedQueryParamsTypes';
|
|
3
|
+
export function* askSharedQueryParamsUISetParam(key, values) {
|
|
4
|
+
yield* askStateDispatchEffect(SharedQueryParamsEffect.SetParam, {
|
|
5
|
+
key,
|
|
6
|
+
values,
|
|
7
|
+
});
|
|
8
|
+
}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { SharedQueryParamsState } from './sharedQueryParamsTypes';
|
|
2
|
-
export declare const sharedQueryParamsInitalState: SharedQueryParamsState;
|
|
3
|
-
export declare const sharedQueryParamsReducer: (state: SharedQueryParamsState, effect: import("./sharedQueryParamsTypes").SharedQueryParamsSetParamEffect) => [SharedQueryParamsState, boolean];
|
|
1
|
+
import { SharedQueryParamsState } from './sharedQueryParamsTypes';
|
|
2
|
+
export declare const sharedQueryParamsInitalState: SharedQueryParamsState;
|
|
3
|
+
export declare const sharedQueryParamsReducer: (state: SharedQueryParamsState, effect: import("./sharedQueryParamsTypes").SharedQueryParamsSetParamEffect) => [SharedQueryParamsState, boolean];
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { buildMutableEffectReducer } from 'quidproquo-core';
|
|
2
|
-
import { SharedQueryParamsEffect } from './sharedQueryParamsTypes';
|
|
3
|
-
export const sharedQueryParamsInitalState = {
|
|
4
|
-
// No initial state
|
|
5
|
-
};
|
|
6
|
-
export const sharedQueryParamsReducer = buildMutableEffectReducer({
|
|
7
|
-
[SharedQueryParamsEffect.SetParam]: (state, { key, values }) => {
|
|
8
|
-
state[key] = values;
|
|
9
|
-
},
|
|
10
|
-
});
|
|
1
|
+
import { buildMutableEffectReducer } from 'quidproquo-core';
|
|
2
|
+
import { SharedQueryParamsEffect } from './sharedQueryParamsTypes';
|
|
3
|
+
export const sharedQueryParamsInitalState = {
|
|
4
|
+
// No initial state
|
|
5
|
+
};
|
|
6
|
+
export const sharedQueryParamsReducer = buildMutableEffectReducer({
|
|
7
|
+
[SharedQueryParamsEffect.SetParam]: (state, { key, values }) => {
|
|
8
|
+
state[key] = values;
|
|
9
|
+
},
|
|
10
|
+
});
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { Effect } from 'quidproquo-core';
|
|
2
|
-
export type SharedQueryParamsState = Record<string, string[] | undefined>;
|
|
3
|
-
export declare enum SharedQueryParamsEffect {
|
|
4
|
-
SetParam = "Qpq/SharedQueryParams/SetParam"
|
|
5
|
-
}
|
|
6
|
-
export type SharedQueryParamsSetParamEffect = Effect<SharedQueryParamsEffect.SetParam, {
|
|
7
|
-
key: string;
|
|
8
|
-
values: string[];
|
|
9
|
-
}>;
|
|
10
|
-
export type SharedQueryParamsEffects = SharedQueryParamsSetParamEffect;
|
|
1
|
+
import { Effect } from 'quidproquo-core';
|
|
2
|
+
export type SharedQueryParamsState = Record<string, string[] | undefined>;
|
|
3
|
+
export declare enum SharedQueryParamsEffect {
|
|
4
|
+
SetParam = "Qpq/SharedQueryParams/SetParam"
|
|
5
|
+
}
|
|
6
|
+
export type SharedQueryParamsSetParamEffect = Effect<SharedQueryParamsEffect.SetParam, {
|
|
7
|
+
key: string;
|
|
8
|
+
values: string[];
|
|
9
|
+
}>;
|
|
10
|
+
export type SharedQueryParamsEffects = SharedQueryParamsSetParamEffect;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export var SharedQueryParamsEffect;
|
|
2
|
-
(function (SharedQueryParamsEffect) {
|
|
3
|
-
SharedQueryParamsEffect["SetParam"] = "Qpq/SharedQueryParams/SetParam";
|
|
4
|
-
})(SharedQueryParamsEffect || (SharedQueryParamsEffect = {}));
|
|
1
|
+
export var SharedQueryParamsEffect;
|
|
2
|
+
(function (SharedQueryParamsEffect) {
|
|
3
|
+
SharedQueryParamsEffect["SetParam"] = "Qpq/SharedQueryParams/SetParam";
|
|
4
|
+
})(SharedQueryParamsEffect || (SharedQueryParamsEffect = {}));
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export declare const sharedQueryParamsRuntime: import("../hooks").QpqRuntimeDefinition<import("./logic").SharedQueryParamsState, import("./logic").SharedQueryParamsSetParamEffect, {
|
|
2
|
-
askSetParam: typeof import("./logic/runtime/askSetParam").askSetParam;
|
|
3
|
-
}>;
|
|
1
|
+
export declare const sharedQueryParamsRuntime: import("../hooks").QpqRuntimeDefinition<import("./logic").SharedQueryParamsState, import("./logic").SharedQueryParamsSetParamEffect, {
|
|
2
|
+
askSetParam: typeof import("./logic/runtime/askSetParam").askSetParam;
|
|
3
|
+
}>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { createQpqRuntimeDefinition } from '../hooks';
|
|
2
|
-
import { sharedQueryParamsLogic } from './logic/runtime';
|
|
3
|
-
import { sharedQueryParamsInitalState, sharedQueryParamsReducer } from './logic';
|
|
4
|
-
export const sharedQueryParamsRuntime = createQpqRuntimeDefinition(sharedQueryParamsLogic, sharedQueryParamsInitalState, sharedQueryParamsReducer);
|
|
1
|
+
import { createQpqRuntimeDefinition } from '../hooks';
|
|
2
|
+
import { sharedQueryParamsLogic } from './logic/runtime';
|
|
3
|
+
import { sharedQueryParamsInitalState, sharedQueryParamsReducer } from './logic';
|
|
4
|
+
export const sharedQueryParamsRuntime = createQpqRuntimeDefinition(sharedQueryParamsLogic, sharedQueryParamsInitalState, sharedQueryParamsReducer);
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * from './useSubscribeToWebSocketQueueEvent';
|
|
2
|
-
export * from './useWebsocketQueueSendEvent';
|
|
1
|
+
export * from './useSubscribeToWebSocketQueueEvent';
|
|
2
|
+
export * from './useWebsocketQueueSendEvent';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * from './useSubscribeToWebSocketQueueEvent';
|
|
2
|
-
export * from './useWebsocketQueueSendEvent';
|
|
1
|
+
export * from './useSubscribeToWebSocketQueueEvent';
|
|
2
|
+
export * from './useWebsocketQueueSendEvent';
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { WebSocketServiceEventSubscriptionFunction } from 'quidproquo-web';
|
|
2
|
-
import { AnyWebSocketQueueEventMessageWithCorrelation } from 'quidproquo-webserver';
|
|
3
|
-
export declare const useSubscribeToWebSocketQueueEvent: <E extends AnyWebSocketQueueEventMessageWithCorrelation>(subscriptionType: E["type"], callback: WebSocketServiceEventSubscriptionFunction<E>) => void;
|
|
1
|
+
import { WebSocketServiceEventSubscriptionFunction } from 'quidproquo-web';
|
|
2
|
+
import { AnyWebSocketQueueEventMessageWithCorrelation } from 'quidproquo-webserver';
|
|
3
|
+
export declare const useSubscribeToWebSocketQueueEvent: <E extends AnyWebSocketQueueEventMessageWithCorrelation>(subscriptionType: E["type"], callback: WebSocketServiceEventSubscriptionFunction<E>) => void;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { useSubscribeToWebSocketEvent } from '../../websocket';
|
|
2
|
-
export const useSubscribeToWebSocketQueueEvent = (subscriptionType, callback) => {
|
|
3
|
-
useSubscribeToWebSocketEvent(subscriptionType, callback);
|
|
4
|
-
};
|
|
1
|
+
import { useSubscribeToWebSocketEvent } from '../../websocket';
|
|
2
|
+
export const useSubscribeToWebSocketQueueEvent = (subscriptionType, callback) => {
|
|
3
|
+
useSubscribeToWebSocketEvent(subscriptionType, callback);
|
|
4
|
+
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { AnyWebSocketQueueEventMessageWithCorrelation } from 'quidproquo-webserver';
|
|
2
|
-
export declare const useWebsocketQueueSendEvent: <E extends AnyWebSocketQueueEventMessageWithCorrelation>() => (event: E) => void;
|
|
1
|
+
import { AnyWebSocketQueueEventMessageWithCorrelation } from 'quidproquo-webserver';
|
|
2
|
+
export declare const useWebsocketQueueSendEvent: <E extends AnyWebSocketQueueEventMessageWithCorrelation>() => (event: E) => void;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { useWebsocketSendEvent } from '../../websocket';
|
|
2
|
-
export const useWebsocketQueueSendEvent = () => {
|
|
3
|
-
const sendMessage = useWebsocketSendEvent();
|
|
4
|
-
return sendMessage;
|
|
5
|
-
};
|
|
1
|
+
import { useWebsocketSendEvent } from '../../websocket';
|
|
2
|
+
export const useWebsocketQueueSendEvent = () => {
|
|
3
|
+
const sendMessage = useWebsocketSendEvent();
|
|
4
|
+
return sendMessage;
|
|
5
|
+
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from './hooks';
|
|
1
|
+
export * from './hooks';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from './hooks';
|
|
1
|
+
export * from './hooks';
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
export declare const WebSocketAuthSync: import("react").NamedExoticComponent<WebSocketAuthSyncProps>;
|
|
1
|
+
import { AuthenticationInfo } from 'quidproquo-core';
|
|
2
|
+
export type WebSocketAuthSyncProps = {
|
|
3
|
+
children: React.ReactNode;
|
|
4
|
+
accessToken: AuthenticationInfo['accessToken'];
|
|
5
|
+
};
|
|
6
|
+
export declare const WebSocketAuthSync: import("react").NamedExoticComponent<WebSocketAuthSyncProps>;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { Fragment as _Fragment, jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { memo } from 'react';
|
|
3
|
-
import { useWebsocketAuthSync, useWebsocketPingPong } from './hooks';
|
|
4
|
-
const component = ({ children, accessToken }) => {
|
|
5
|
-
useWebsocketAuthSync(accessToken);
|
|
6
|
-
// Keep the active websocket alive
|
|
7
|
-
useWebsocketPingPong();
|
|
8
|
-
// This fragment is not useless!
|
|
9
|
-
return _jsx(_Fragment, { children: children });
|
|
10
|
-
};
|
|
11
|
-
export const WebSocketAuthSync = memo(component);
|
|
1
|
+
import { Fragment as _Fragment, jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { memo } from 'react';
|
|
3
|
+
import { useWebsocketAuthSync, useWebsocketPingPong } from './hooks';
|
|
4
|
+
const component = ({ children, accessToken }) => {
|
|
5
|
+
useWebsocketAuthSync(accessToken);
|
|
6
|
+
// Keep the active websocket alive
|
|
7
|
+
useWebsocketPingPong();
|
|
8
|
+
// This fragment is not useless!
|
|
9
|
+
return _jsx(_Fragment, { children: children });
|
|
10
|
+
};
|
|
11
|
+
export const WebSocketAuthSync = memo(component);
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * from './useWebsocketAuthSync';
|
|
2
|
-
export * from './useWebsocketPingPong';
|
|
1
|
+
export * from './useWebsocketAuthSync';
|
|
2
|
+
export * from './useWebsocketPingPong';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * from './useWebsocketAuthSync';
|
|
2
|
-
export * from './useWebsocketPingPong';
|
|
1
|
+
export * from './useWebsocketAuthSync';
|
|
2
|
+
export * from './useWebsocketPingPong';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { AuthenticationInfo } from 'quidproquo-core';
|
|
2
|
-
export declare const useWebsocketAuthSync: (accessToken: AuthenticationInfo[
|
|
1
|
+
import { AuthenticationInfo } from 'quidproquo-core';
|
|
2
|
+
export declare const useWebsocketAuthSync: (accessToken: AuthenticationInfo["accessToken"]) => void;
|
|
@@ -1,33 +1,33 @@
|
|
|
1
|
-
import { WebsocketServiceEvent } from 'quidproquo-web';
|
|
2
|
-
import { WebSocketQueueClientMessageEventType, } from 'quidproquo-webserver';
|
|
3
|
-
import { useEffect } from 'react';
|
|
4
|
-
import { useFastCallback } from '../../../hooks';
|
|
5
|
-
import { useSubscribeToWebsocket, useWebsocketApi, useWebsocketSendEvent } from '../../hooks';
|
|
6
|
-
export const useWebsocketAuthSync = (accessToken) => {
|
|
7
|
-
const sendMessage = useWebsocketSendEvent();
|
|
8
|
-
const websocketApi = useWebsocketApi();
|
|
9
|
-
const updateAuthTokens = useFastCallback(() => {
|
|
10
|
-
if (!websocketApi?.isConnected()) {
|
|
11
|
-
return;
|
|
12
|
-
}
|
|
13
|
-
if (accessToken) {
|
|
14
|
-
const authMessage = {
|
|
15
|
-
type: WebSocketQueueClientMessageEventType.Authenticate,
|
|
16
|
-
payload: {
|
|
17
|
-
accessToken: accessToken,
|
|
18
|
-
},
|
|
19
|
-
};
|
|
20
|
-
sendMessage(authMessage);
|
|
21
|
-
}
|
|
22
|
-
else {
|
|
23
|
-
const authMessage = {
|
|
24
|
-
type: WebSocketQueueClientMessageEventType.Unauthenticate,
|
|
25
|
-
};
|
|
26
|
-
sendMessage(authMessage);
|
|
27
|
-
}
|
|
28
|
-
});
|
|
29
|
-
// Sync the tokens in on open
|
|
30
|
-
useSubscribeToWebsocket(WebsocketServiceEvent.OPEN, updateAuthTokens);
|
|
31
|
-
// Sync the tokens when they change
|
|
32
|
-
useEffect(updateAuthTokens, [accessToken, websocketApi]);
|
|
33
|
-
};
|
|
1
|
+
import { WebsocketServiceEvent } from 'quidproquo-web';
|
|
2
|
+
import { WebSocketQueueClientMessageEventType, } from 'quidproquo-webserver';
|
|
3
|
+
import { useEffect } from 'react';
|
|
4
|
+
import { useFastCallback } from '../../../hooks';
|
|
5
|
+
import { useSubscribeToWebsocket, useWebsocketApi, useWebsocketSendEvent } from '../../hooks';
|
|
6
|
+
export const useWebsocketAuthSync = (accessToken) => {
|
|
7
|
+
const sendMessage = useWebsocketSendEvent();
|
|
8
|
+
const websocketApi = useWebsocketApi();
|
|
9
|
+
const updateAuthTokens = useFastCallback(() => {
|
|
10
|
+
if (!websocketApi?.isConnected()) {
|
|
11
|
+
return;
|
|
12
|
+
}
|
|
13
|
+
if (accessToken) {
|
|
14
|
+
const authMessage = {
|
|
15
|
+
type: WebSocketQueueClientMessageEventType.Authenticate,
|
|
16
|
+
payload: {
|
|
17
|
+
accessToken: accessToken,
|
|
18
|
+
},
|
|
19
|
+
};
|
|
20
|
+
sendMessage(authMessage);
|
|
21
|
+
}
|
|
22
|
+
else {
|
|
23
|
+
const authMessage = {
|
|
24
|
+
type: WebSocketQueueClientMessageEventType.Unauthenticate,
|
|
25
|
+
};
|
|
26
|
+
sendMessage(authMessage);
|
|
27
|
+
}
|
|
28
|
+
});
|
|
29
|
+
// Sync the tokens in on open
|
|
30
|
+
useSubscribeToWebsocket(WebsocketServiceEvent.OPEN, updateAuthTokens);
|
|
31
|
+
// Sync the tokens when they change
|
|
32
|
+
useEffect(updateAuthTokens, [accessToken, websocketApi]);
|
|
33
|
+
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const useWebsocketPingPong: () => void;
|
|
1
|
+
export declare const useWebsocketPingPong: () => void;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { WebSocketQueueClientMessageEventType } from 'quidproquo-webserver';
|
|
2
|
-
import { useRunEvery } from '../../../hooks';
|
|
3
|
-
import { useWebsocketSendEvent } from '../../hooks';
|
|
4
|
-
export const useWebsocketPingPong = () => {
|
|
5
|
-
const sendMessage = useWebsocketSendEvent();
|
|
6
|
-
useRunEvery(() => {
|
|
7
|
-
const pingEvent = {
|
|
8
|
-
type: WebSocketQueueClientMessageEventType.Ping,
|
|
9
|
-
};
|
|
10
|
-
sendMessage(pingEvent);
|
|
11
|
-
}, 8 * 60);
|
|
12
|
-
};
|
|
1
|
+
import { WebSocketQueueClientMessageEventType } from 'quidproquo-webserver';
|
|
2
|
+
import { useRunEvery } from '../../../hooks';
|
|
3
|
+
import { useWebsocketSendEvent } from '../../hooks';
|
|
4
|
+
export const useWebsocketPingPong = () => {
|
|
5
|
+
const sendMessage = useWebsocketSendEvent();
|
|
6
|
+
useRunEvery(() => {
|
|
7
|
+
const pingEvent = {
|
|
8
|
+
type: WebSocketQueueClientMessageEventType.Ping,
|
|
9
|
+
};
|
|
10
|
+
sendMessage(pingEvent);
|
|
11
|
+
}, 8 * 60);
|
|
12
|
+
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from './WebSocketAuthSync';
|
|
1
|
+
export * from './WebSocketAuthSync';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from './WebSocketAuthSync';
|
|
1
|
+
export * from './WebSocketAuthSync';
|
|
@@ -1,3 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
export declare const WebSocketContext: import("react").Context<WebsocketService | null>;
|
|
1
|
+
import { WebsocketService } from 'quidproquo-web';
|
|
2
|
+
export declare const WebSocketContext: import("react").Context<WebsocketService | null>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { createContext } from 'react';
|
|
2
|
-
export const WebSocketContext = createContext(null);
|
|
1
|
+
import { createContext } from 'react';
|
|
2
|
+
export const WebSocketContext = createContext(null);
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
export declare const WebsocketProvider: React.FC<WebSocketContextProps>;
|
|
1
|
+
export type WebSocketContextProps = {
|
|
2
|
+
children: React.ReactNode;
|
|
3
|
+
wsUrl: string;
|
|
4
|
+
};
|
|
5
|
+
export declare const WebsocketProvider: React.FC<WebSocketContextProps>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
-
import { useWebsocketManagement } from './hooks';
|
|
3
|
-
import { WebSocketContext } from './WebsocketContext';
|
|
4
|
-
export const WebsocketProvider = ({ children, wsUrl }) => {
|
|
5
|
-
const websocketManagement = useWebsocketManagement(wsUrl);
|
|
6
|
-
return _jsx(WebSocketContext.Provider, { value: websocketManagement, children: children });
|
|
7
|
-
};
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { useWebsocketManagement } from './hooks';
|
|
3
|
+
import { WebSocketContext } from './WebsocketContext';
|
|
4
|
+
export const WebsocketProvider = ({ children, wsUrl }) => {
|
|
5
|
+
const websocketManagement = useWebsocketManagement(wsUrl);
|
|
6
|
+
return _jsx(WebSocketContext.Provider, { value: websocketManagement, children: children });
|
|
7
|
+
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export * from './useSubscribeToWebsocket';
|
|
2
|
-
export * from './useSubscribeToWebSocketEvent';
|
|
3
|
-
export * from './useWebsocketApi';
|
|
4
|
-
export * from './useWebsocketManagement';
|
|
5
|
-
export * from './useWebsocketSendEvent';
|
|
1
|
+
export * from './useSubscribeToWebsocket';
|
|
2
|
+
export * from './useSubscribeToWebSocketEvent';
|
|
3
|
+
export * from './useWebsocketApi';
|
|
4
|
+
export * from './useWebsocketManagement';
|
|
5
|
+
export * from './useWebsocketSendEvent';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export * from './useSubscribeToWebsocket';
|
|
2
|
-
export * from './useSubscribeToWebSocketEvent';
|
|
3
|
-
export * from './useWebsocketApi';
|
|
4
|
-
export * from './useWebsocketManagement';
|
|
5
|
-
export * from './useWebsocketSendEvent';
|
|
1
|
+
export * from './useSubscribeToWebsocket';
|
|
2
|
+
export * from './useSubscribeToWebSocketEvent';
|
|
3
|
+
export * from './useWebsocketApi';
|
|
4
|
+
export * from './useWebsocketManagement';
|
|
5
|
+
export * from './useWebsocketSendEvent';
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { AnyEventMessage } from 'quidproquo-core';
|
|
2
|
-
import { WebSocketServiceEventSubscriptionFunction } from 'quidproquo-web';
|
|
3
|
-
export declare const useSubscribeToWebSocketEvent: <E extends AnyEventMessage>(subscriptionType: E["type"], callback: WebSocketServiceEventSubscriptionFunction<E>) => void;
|
|
1
|
+
import { AnyEventMessage } from 'quidproquo-core';
|
|
2
|
+
import { WebSocketServiceEventSubscriptionFunction } from 'quidproquo-web';
|
|
3
|
+
export declare const useSubscribeToWebSocketEvent: <E extends AnyEventMessage>(subscriptionType: E["type"], callback: WebSocketServiceEventSubscriptionFunction<E>) => void;
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { useEffect } from 'react';
|
|
2
|
-
import { useWebsocketApi } from './useWebsocketApi';
|
|
3
|
-
export const useSubscribeToWebSocketEvent = (subscriptionType, callback) => {
|
|
4
|
-
const websocketService = useWebsocketApi();
|
|
5
|
-
useEffect(() => {
|
|
6
|
-
const subscriptionHandle = websocketService?.subscribeToEvent(subscriptionType, callback);
|
|
7
|
-
return () => {
|
|
8
|
-
if (subscriptionHandle) {
|
|
9
|
-
websocketService?.unsubscribe(subscriptionHandle);
|
|
10
|
-
}
|
|
11
|
-
};
|
|
12
|
-
}, [websocketService, subscriptionType, callback]);
|
|
13
|
-
};
|
|
1
|
+
import { useEffect } from 'react';
|
|
2
|
+
import { useWebsocketApi } from './useWebsocketApi';
|
|
3
|
+
export const useSubscribeToWebSocketEvent = (subscriptionType, callback) => {
|
|
4
|
+
const websocketService = useWebsocketApi();
|
|
5
|
+
useEffect(() => {
|
|
6
|
+
const subscriptionHandle = websocketService?.subscribeToEvent(subscriptionType, callback);
|
|
7
|
+
return () => {
|
|
8
|
+
if (subscriptionHandle) {
|
|
9
|
+
websocketService?.unsubscribe(subscriptionHandle);
|
|
10
|
+
}
|
|
11
|
+
};
|
|
12
|
+
}, [websocketService, subscriptionType, callback]);
|
|
13
|
+
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { WebsocketServiceEvent, WebSocketServiceSubscriptionFunction } from 'quidproquo-web';
|
|
2
|
-
export declare const useSubscribeToWebsocket: (subscriptionType: WebsocketServiceEvent, callback: WebSocketServiceSubscriptionFunction) => void;
|
|
1
|
+
import { WebsocketServiceEvent, WebSocketServiceSubscriptionFunction } from 'quidproquo-web';
|
|
2
|
+
export declare const useSubscribeToWebsocket: (subscriptionType: WebsocketServiceEvent, callback: WebSocketServiceSubscriptionFunction) => void;
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { useEffect } from 'react';
|
|
2
|
-
import { useWebsocketApi } from './useWebsocketApi';
|
|
3
|
-
export const useSubscribeToWebsocket = (subscriptionType, callback) => {
|
|
4
|
-
const websocketService = useWebsocketApi();
|
|
5
|
-
useEffect(() => {
|
|
6
|
-
const handle = websocketService?.subscribe(subscriptionType, callback);
|
|
7
|
-
return () => {
|
|
8
|
-
if (handle) {
|
|
9
|
-
websocketService?.unsubscribe(handle);
|
|
10
|
-
}
|
|
11
|
-
};
|
|
12
|
-
}, [websocketService, subscriptionType, callback]);
|
|
13
|
-
};
|
|
1
|
+
import { useEffect } from 'react';
|
|
2
|
+
import { useWebsocketApi } from './useWebsocketApi';
|
|
3
|
+
export const useSubscribeToWebsocket = (subscriptionType, callback) => {
|
|
4
|
+
const websocketService = useWebsocketApi();
|
|
5
|
+
useEffect(() => {
|
|
6
|
+
const handle = websocketService?.subscribe(subscriptionType, callback);
|
|
7
|
+
return () => {
|
|
8
|
+
if (handle) {
|
|
9
|
+
websocketService?.unsubscribe(handle);
|
|
10
|
+
}
|
|
11
|
+
};
|
|
12
|
+
}, [websocketService, subscriptionType, callback]);
|
|
13
|
+
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const useWebsocketApi: () => import("quidproquo-web").WebsocketService | null;
|
|
1
|
+
export declare const useWebsocketApi: () => import("quidproquo-web").WebsocketService | null;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { useContext } from 'react';
|
|
2
|
-
import { WebSocketContext } from '../WebsocketContext';
|
|
3
|
-
export const useWebsocketApi = () => {
|
|
4
|
-
const websocketService = useContext(WebSocketContext);
|
|
5
|
-
return websocketService;
|
|
6
|
-
};
|
|
1
|
+
import { useContext } from 'react';
|
|
2
|
+
import { WebSocketContext } from '../WebsocketContext';
|
|
3
|
+
export const useWebsocketApi = () => {
|
|
4
|
+
const websocketService = useContext(WebSocketContext);
|
|
5
|
+
return websocketService;
|
|
6
|
+
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { WebsocketService } from 'quidproquo-web';
|
|
2
|
-
export declare const useWebsocketManagement: (wsUrl: string) => WebsocketService | null;
|
|
1
|
+
import { WebsocketService } from 'quidproquo-web';
|
|
2
|
+
export declare const useWebsocketManagement: (wsUrl: string) => WebsocketService | null;
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { WebsocketService } from 'quidproquo-web';
|
|
2
|
-
import { useEffect, useState } from 'react';
|
|
3
|
-
export const useWebsocketManagement = (wsUrl) => {
|
|
4
|
-
const [websocketApi, setWebsocketApi] = useState(null);
|
|
5
|
-
useEffect(() => {
|
|
6
|
-
const wsService = new WebsocketService(wsUrl);
|
|
7
|
-
setWebsocketApi(wsService);
|
|
8
|
-
return () => {
|
|
9
|
-
wsService.destroy();
|
|
10
|
-
};
|
|
11
|
-
}, [wsUrl]);
|
|
12
|
-
return websocketApi;
|
|
13
|
-
};
|
|
1
|
+
import { WebsocketService } from 'quidproquo-web';
|
|
2
|
+
import { useEffect, useState } from 'react';
|
|
3
|
+
export const useWebsocketManagement = (wsUrl) => {
|
|
4
|
+
const [websocketApi, setWebsocketApi] = useState(null);
|
|
5
|
+
useEffect(() => {
|
|
6
|
+
const wsService = new WebsocketService(wsUrl);
|
|
7
|
+
setWebsocketApi(wsService);
|
|
8
|
+
return () => {
|
|
9
|
+
wsService.destroy();
|
|
10
|
+
};
|
|
11
|
+
}, [wsUrl]);
|
|
12
|
+
return websocketApi;
|
|
13
|
+
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { AnyEventMessage } from 'quidproquo-core';
|
|
2
|
-
export declare const useWebsocketSendEvent: <E extends AnyEventMessage = AnyEventMessage>() => (event: E) => void;
|
|
1
|
+
import { AnyEventMessage } from 'quidproquo-core';
|
|
2
|
+
export declare const useWebsocketSendEvent: <E extends AnyEventMessage = AnyEventMessage>() => (event: E) => void;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { useFastCallback } from '../../hooks';
|
|
2
|
-
import { useWebsocketApi } from './useWebsocketApi';
|
|
3
|
-
export const useWebsocketSendEvent = () => {
|
|
4
|
-
const websocketApi = useWebsocketApi();
|
|
5
|
-
const sendMessage = useFastCallback((event) => {
|
|
6
|
-
if (websocketApi) {
|
|
7
|
-
websocketApi.sendEvent(event);
|
|
8
|
-
}
|
|
9
|
-
});
|
|
10
|
-
return sendMessage;
|
|
11
|
-
};
|
|
1
|
+
import { useFastCallback } from '../../hooks';
|
|
2
|
+
import { useWebsocketApi } from './useWebsocketApi';
|
|
3
|
+
export const useWebsocketSendEvent = () => {
|
|
4
|
+
const websocketApi = useWebsocketApi();
|
|
5
|
+
const sendMessage = useFastCallback((event) => {
|
|
6
|
+
if (websocketApi) {
|
|
7
|
+
websocketApi.sendEvent(event);
|
|
8
|
+
}
|
|
9
|
+
});
|
|
10
|
+
return sendMessage;
|
|
11
|
+
};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export * from './hooks';
|
|
2
|
-
export * from './WebSocketAuthSync';
|
|
3
|
-
export * from './WebsocketProvider';
|
|
1
|
+
export * from './hooks';
|
|
2
|
+
export * from './WebSocketAuthSync';
|
|
3
|
+
export * from './WebsocketProvider';
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export * from './hooks';
|
|
2
|
-
export * from './WebSocketAuthSync';
|
|
3
|
-
export * from './WebsocketProvider';
|
|
1
|
+
export * from './hooks';
|
|
2
|
+
export * from './WebSocketAuthSync';
|
|
3
|
+
export * from './WebsocketProvider';
|