chayns-api 2.1.3-3 → 2.1.5
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/.babelrc +31 -30
- package/.eslintrc +17 -17
- package/.github/workflows/deploy_docs.yml +28 -28
- package/.github/workflows/publish.yml +21 -21
- package/LICENSE +21 -21
- package/README.md +67 -67
- package/dist/cjs/calls/dialogs/chaynsDialog.js +0 -2
- package/dist/cjs/calls/dialogs/communication.js +0 -2
- package/dist/cjs/calls/dialogs/confirm.js +0 -1
- package/dist/cjs/calls/dialogs/date.js +0 -50
- package/dist/cjs/calls/dialogs/iFrame.js +1 -1
- package/dist/cjs/calls/index.js +1 -162
- package/dist/cjs/calls/sendMessage.js +0 -12
- package/dist/cjs/calls/visibilityChangeListener.js +0 -7
- package/dist/cjs/components/AppDialogWrapper.js +3 -3
- package/dist/cjs/components/ChaynsContext.js +1 -1
- package/dist/cjs/components/ChaynsProvider.js +6 -10
- package/dist/cjs/components/ErrorBoundary.js +1 -1
- package/dist/cjs/components/WaitUntil.js +0 -2
- package/dist/cjs/components/withCompatMode.js +9 -13
- package/dist/cjs/components/withHydrationBoundary.js +2 -2
- package/dist/cjs/constants/hydrationContext.js +1 -3
- package/dist/cjs/constants/languages.js +1 -1
- package/dist/cjs/handler/DialogHandler.js +0 -4
- package/dist/cjs/hooks/geoLocationListener.js +0 -7
- package/dist/cjs/hooks/scrollListener.js +0 -14
- package/dist/cjs/hooks/useAccessToken.js +0 -4
- package/dist/cjs/hooks/useCurrentPage.js +0 -3
- package/dist/cjs/hooks/useCustomCallbackFunction.js +0 -4
- package/dist/cjs/hooks/useCustomData.js +0 -3
- package/dist/cjs/hooks/useDevice.js +0 -3
- package/dist/cjs/hooks/useDialogState.js +0 -7
- package/dist/cjs/hooks/useEnvironment.js +0 -3
- package/dist/cjs/hooks/useFunctions.js +0 -3
- package/dist/cjs/hooks/useIsAdminMode.js +0 -3
- package/dist/cjs/hooks/useLanguage.js +0 -3
- package/dist/cjs/hooks/usePages.js +0 -6
- package/dist/cjs/hooks/useParameters.js +0 -3
- package/dist/cjs/hooks/useSite.js +0 -3
- package/dist/cjs/hooks/useUser.js +0 -3
- package/dist/cjs/hooks/useValues.js +0 -3
- package/dist/cjs/hooks/windowMetricsListener.js +0 -7
- package/dist/cjs/host/ChaynsHost.js +3 -4
- package/dist/cjs/host/iframe/HostIframe.js +4 -23
- package/dist/cjs/host/module/ModuleHost.js +5 -9
- package/dist/cjs/host/module/utils/loadComponent.js +4 -5
- package/dist/cjs/index.js +1 -1
- package/dist/cjs/types/IChaynsReact.js +39 -46
- package/dist/cjs/util/appCall.js +0 -2
- package/dist/cjs/util/deviceHelper.js +0 -4
- package/dist/cjs/util/heightHelper.js +1 -1
- package/dist/cjs/util/initModuleFederationSharing.js +2 -6
- package/dist/cjs/util/postIframeForm.js +0 -1
- package/dist/cjs/util/transferNestedFunctions.js +0 -3
- package/dist/cjs/wrapper/AppWrapper.js +6 -20
- package/dist/cjs/wrapper/FrameWrapper.js +2 -7
- package/dist/cjs/wrapper/ModuleFederationWrapper.js +1 -3
- package/dist/cjs/wrapper/StaticChaynsApi.js +1 -1
- package/dist/esm/calls/dialogs/chaynsDialog.js +0 -2
- package/dist/esm/calls/dialogs/communication.js +0 -2
- package/dist/esm/calls/dialogs/confirm.js +0 -1
- package/dist/esm/calls/dialogs/date.js +0 -51
- package/dist/esm/calls/dialogs/iFrame.js +1 -1
- package/dist/esm/calls/index.js +1 -162
- package/dist/esm/calls/sendMessage.js +0 -12
- package/dist/esm/calls/visibilityChangeListener.js +0 -7
- package/dist/esm/components/AppDialogWrapper.js +2 -2
- package/dist/esm/components/ChaynsContext.js +1 -1
- package/dist/esm/components/ChaynsProvider.js +5 -10
- package/dist/esm/components/WaitUntil.js +0 -2
- package/dist/esm/components/withCompatMode.js +8 -14
- package/dist/esm/components/withHydrationBoundary.js +2 -2
- package/dist/esm/constants/hydrationContext.js +1 -3
- package/dist/esm/constants/languages.js +1 -1
- package/dist/esm/handler/DialogHandler.js +1 -5
- package/dist/esm/hooks/geoLocationListener.js +0 -7
- package/dist/esm/hooks/scrollListener.js +0 -14
- package/dist/esm/hooks/useAccessToken.js +0 -5
- package/dist/esm/hooks/useCurrentPage.js +0 -4
- package/dist/esm/hooks/useCustomCallbackFunction.js +0 -5
- package/dist/esm/hooks/useCustomData.js +0 -4
- package/dist/esm/hooks/useDevice.js +0 -3
- package/dist/esm/hooks/useDialogState.js +0 -8
- package/dist/esm/hooks/useEnvironment.js +0 -3
- package/dist/esm/hooks/useFunctions.js +0 -4
- package/dist/esm/hooks/useIsAdminMode.js +0 -3
- package/dist/esm/hooks/useLanguage.js +0 -3
- package/dist/esm/hooks/usePages.js +0 -6
- package/dist/esm/hooks/useParameters.js +0 -3
- package/dist/esm/hooks/useSite.js +0 -3
- package/dist/esm/hooks/useUser.js +0 -3
- package/dist/esm/hooks/useValues.js +0 -4
- package/dist/esm/hooks/windowMetricsListener.js +0 -7
- package/dist/esm/host/ChaynsHost.js +2 -3
- package/dist/esm/host/iframe/HostIframe.js +3 -22
- package/dist/esm/host/module/ModuleHost.js +4 -8
- package/dist/esm/host/module/utils/loadComponent.js +3 -4
- package/dist/esm/types/IChaynsReact.js +39 -49
- package/dist/esm/util/appCall.js +0 -2
- package/dist/esm/util/deviceHelper.js +0 -4
- package/dist/esm/util/initModuleFederationSharing.js +1 -5
- package/dist/esm/util/postIframeForm.js +0 -1
- package/dist/esm/util/transferNestedFunctions.js +0 -2
- package/dist/esm/wrapper/AppWrapper.js +6 -20
- package/dist/esm/wrapper/FrameWrapper.js +2 -6
- package/dist/esm/wrapper/ModuleFederationWrapper.js +1 -3
- package/dist/esm/wrapper/SsrWrapper.js +1 -1
- package/dist/esm/wrapper/StaticChaynsApi.js +1 -1
- package/dist/types/calls/dialogs/alert.d.ts +1 -1
- package/dist/types/calls/dialogs/chaynsDialog.d.ts +24 -24
- package/dist/types/calls/dialogs/close.d.ts +1 -1
- package/dist/types/calls/dialogs/communication.d.ts +3 -3
- package/dist/types/calls/dialogs/confirm.d.ts +13 -13
- package/dist/types/calls/dialogs/date.d.ts +96 -96
- package/dist/types/calls/dialogs/dropUpAlert.d.ts +5 -5
- package/dist/types/calls/dialogs/fileSelect.d.ts +16 -16
- package/dist/types/calls/dialogs/iFrame.d.ts +10 -10
- package/dist/types/calls/dialogs/index.d.ts +14 -14
- package/dist/types/calls/dialogs/input.d.ts +15 -15
- package/dist/types/calls/dialogs/mediaSelect.d.ts +8 -8
- package/dist/types/calls/dialogs/open.d.ts +1 -1
- package/dist/types/calls/dialogs/select.d.ts +6 -6
- package/dist/types/calls/dialogs/signature.d.ts +7 -7
- package/dist/types/calls/dialogs/toast.d.ts +1 -1
- package/dist/types/calls/dialogs/utils/callback.d.ts +1 -1
- package/dist/types/calls/dialogs/utils/is.d.ts +4 -4
- package/dist/types/calls/getUserInfo.d.ts +9 -9
- package/dist/types/calls/index.d.ts +255 -255
- package/dist/types/calls/sendMessage.d.ts +13 -13
- package/dist/types/calls/visibilityChangeListener.d.ts +9 -9
- package/dist/types/components/AppDialogWrapper.d.ts +5 -5
- package/dist/types/components/ChaynsContext.d.ts +3 -3
- package/dist/types/components/ChaynsProvider.d.ts +11 -11
- package/dist/types/components/ErrorBoundary.d.ts +13 -13
- package/dist/types/components/WaitUntil.d.ts +7 -7
- package/dist/types/components/moduleWrapper.d.ts +4 -4
- package/dist/types/components/withCompatMode.d.ts +43 -43
- package/dist/types/components/withHydrationBoundary.d.ts +24 -24
- package/dist/types/constants/hydrationContext.d.ts +6 -6
- package/dist/types/constants/index.d.ts +1 -1
- package/dist/types/constants/languages.d.ts +12 -12
- package/dist/types/handler/DialogHandler.d.ts +24 -24
- package/dist/types/helper/apiListenerHelper.d.ts +6 -6
- package/dist/types/hooks/context.d.ts +3 -3
- package/dist/types/hooks/geoLocationListener.d.ts +18 -18
- package/dist/types/hooks/index.d.ts +18 -18
- package/dist/types/hooks/scrollListener.d.ts +28 -28
- package/dist/types/hooks/useAccessToken.d.ts +6 -6
- package/dist/types/hooks/useCurrentPage.d.ts +5 -5
- package/dist/types/hooks/useCustomCallbackFunction.d.ts +5 -5
- package/dist/types/hooks/useCustomData.d.ts +4 -4
- package/dist/types/hooks/useDevice.d.ts +5 -5
- package/dist/types/hooks/useDialogState.d.ts +9 -9
- package/dist/types/hooks/useEnvironment.d.ts +5 -5
- package/dist/types/hooks/useFunctions.d.ts +4 -4
- package/dist/types/hooks/useIsAdminMode.d.ts +4 -4
- package/dist/types/hooks/useLanguage.d.ts +5 -5
- package/dist/types/hooks/usePages.d.ts +18 -18
- package/dist/types/hooks/useParameters.d.ts +5 -5
- package/dist/types/hooks/useSite.d.ts +5 -5
- package/dist/types/hooks/useUser.d.ts +5 -5
- package/dist/types/hooks/useValues.d.ts +4 -4
- package/dist/types/hooks/windowMetricsListener.d.ts +11 -11
- package/dist/types/host/ChaynsHost.d.ts +29 -29
- package/dist/types/host/iframe/HostIframe.d.ts +26 -26
- package/dist/types/host/iframe/utils/useUpdateData.d.ts +3 -3
- package/dist/types/host/module/ModuleHost.d.ts +28 -28
- package/dist/types/host/module/utils/loadComponent.d.ts +3 -3
- package/dist/types/index.d.ts +20 -20
- package/dist/types/types/IChaynsReact.d.ts +898 -899
- package/dist/types/types/dialog.d.ts +41 -41
- package/dist/types/util/appCall.d.ts +2 -2
- package/dist/types/util/bindChaynsApi.d.ts +1 -1
- package/dist/types/util/deviceHelper.d.ts +9 -9
- package/dist/types/util/heightHelper.d.ts +1 -1
- package/dist/types/util/initModuleFederationSharing.d.ts +3 -3
- package/dist/types/util/is.d.ts +5 -5
- package/dist/types/util/postIframeForm.d.ts +1 -1
- package/dist/types/util/transferNestedFunctions.d.ts +1 -1
- package/dist/types/util/url.d.ts +1 -1
- package/dist/types/wrapper/AppWrapper.d.ts +22 -22
- package/dist/types/wrapper/FrameWrapper.d.ts +18 -18
- package/dist/types/wrapper/ModuleFederationWrapper.d.ts +13 -13
- package/dist/types/wrapper/SsrWrapper.d.ts +14 -14
- package/dist/types/wrapper/StaticChaynsApi.d.ts +16 -16
- package/package.json +88 -88
- package/toolkit.config.js +20 -20
- package/tsconfig.json +56 -56
|
@@ -1,255 +1,255 @@
|
|
|
1
|
-
import { ChaynsApiDevice, ChaynsApiSite, ChaynsReactFunctions, UserInfo } from '../types/IChaynsReact';
|
|
2
|
-
/**
|
|
3
|
-
* This adds a listener to determine your location.
|
|
4
|
-
* @category Event listener
|
|
5
|
-
*/
|
|
6
|
-
export declare const addGeoLocationListener: (value: {
|
|
7
|
-
timeout?: number | undefined;
|
|
8
|
-
silent?: boolean | undefined;
|
|
9
|
-
}, callback: (geoLocation: import("../types/IChaynsReact").GeoLocation) => void) => Promise<number>;
|
|
10
|
-
/**
|
|
11
|
-
* Adds a listener for scroll event by user.
|
|
12
|
-
* @category Event listener
|
|
13
|
-
*/
|
|
14
|
-
export declare const addScrollListener: (value: {
|
|
15
|
-
throttle?: number | undefined;
|
|
16
|
-
}, callback: (result: import("../types/IChaynsReact").ScrollListenerResult) => void) => Promise<number>;
|
|
17
|
-
/**
|
|
18
|
-
* This method will be executed when the page gets displayed or hidden.
|
|
19
|
-
* @category Event listener
|
|
20
|
-
*/
|
|
21
|
-
export declare const addVisibilityChangeListener: (callback: (result: import("../types/IChaynsReact").VisibilityChangeListenerResult) => void) => Promise<number>;
|
|
22
|
-
/**
|
|
23
|
-
* This method will be executed when the toolbar gets displayed or hidden.
|
|
24
|
-
* @category Event listener
|
|
25
|
-
*/
|
|
26
|
-
export declare const addToolbarChangeListener: (callback: (result: import("../types/IChaynsReact").ToolbarChangeListenerResult) => void) => Promise<number>;
|
|
27
|
-
/**
|
|
28
|
-
* This adds a listener to get the actual height of the page.
|
|
29
|
-
* @category Event listener
|
|
30
|
-
*/
|
|
31
|
-
export declare const addWindowMetricsListener: (callback: (result: import("../types/IChaynsReact").WindowMetricsListenerResult) => void) => Promise<number>; /**
|
|
32
|
-
* Allows a custom callback function to be defined
|
|
33
|
-
*/
|
|
34
|
-
export declare const customCallbackFunction: (type: string, data: unknown) => Promise<unknown>;
|
|
35
|
-
/**
|
|
36
|
-
* Get the accessToken from the user.
|
|
37
|
-
*/
|
|
38
|
-
export declare const getAccessToken: (value?: import("../types/IChaynsReact").AccessToken | undefined) => Promise<import("../types/IChaynsReact").AccessTokenResult>;
|
|
39
|
-
/**
|
|
40
|
-
* This method returns a list of installed share/social media apps.
|
|
41
|
-
*/
|
|
42
|
-
export declare const getAvailableSharingServices: () => Promise<import("../types/IChaynsReact").AvailableSharingServices>;
|
|
43
|
-
/**
|
|
44
|
-
* This method determines your location. If you want to track a route, use addGeoLocationListener.
|
|
45
|
-
*/
|
|
46
|
-
export declare const getGeoLocation: (value: {
|
|
47
|
-
timeout?: number | undefined;
|
|
48
|
-
silent?: boolean | undefined;
|
|
49
|
-
}) => Promise<import("../types/IChaynsReact").GeoLocation>;
|
|
50
|
-
/**
|
|
51
|
-
* This method returns user information for a specific user.
|
|
52
|
-
* @category User functions
|
|
53
|
-
*/
|
|
54
|
-
export declare const getUserInfo: (value: import("../types/IChaynsReact").UserInfoQuery) => Promise<UserInfo | null>;
|
|
55
|
-
/**
|
|
56
|
-
* Return the current scroll position of the top frame
|
|
57
|
-
*/
|
|
58
|
-
export declare const getScrollPosition: () => Promise<import("../types/IChaynsReact").ScrollListenerResult>;
|
|
59
|
-
/**
|
|
60
|
-
* Returns the window metrics.
|
|
61
|
-
*/
|
|
62
|
-
export declare const getWindowMetrics: () => Promise<import("../types/IChaynsReact").WindowMetricsListenerResult>;
|
|
63
|
-
/** @internal */
|
|
64
|
-
export declare const invokeCall: (value: import("../types/IChaynsReact").InvokeCall, callback?: ((result: any) => void) | undefined) => Promise<any>;
|
|
65
|
-
/** @internal */
|
|
66
|
-
export declare const invokeDialogCall: (value: import("../types/IChaynsReact").InvokeCall, callback?: ((result: any) => void) | undefined) => Promise<any>;
|
|
67
|
-
/**
|
|
68
|
-
* This method will show a login dialog where the user has the opportunity to log in.
|
|
69
|
-
*/
|
|
70
|
-
export declare const login: (value?: import("../types/IChaynsReact").Login | undefined, callback?: ((result: boolean) => void) | undefined, closeCallback?: (() => void) | undefined) => Promise<import("../types/IChaynsReact").LoginResult>;
|
|
71
|
-
/**
|
|
72
|
-
* This method will logout the user
|
|
73
|
-
*/
|
|
74
|
-
export declare const logout: () => Promise<void>;
|
|
75
|
-
/**
|
|
76
|
-
* This function navigates you to the previous site.
|
|
77
|
-
*/
|
|
78
|
-
export declare const navigateBack: () => Promise<void>;
|
|
79
|
-
/**
|
|
80
|
-
* The images specified in the url array is shown in gallery mode.
|
|
81
|
-
*/
|
|
82
|
-
export declare const openImage: (value: import("../types/IChaynsReact").OpenImage) => Promise<void>;
|
|
83
|
-
/**
|
|
84
|
-
* The images and videos specified in the items array is shown in gallery mode.
|
|
85
|
-
*/
|
|
86
|
-
export declare const openMedia: (value: import("../types/IChaynsReact").OpenMedia) => Promise<void>;
|
|
87
|
-
/**
|
|
88
|
-
* Opens an URL in the chayns environment.
|
|
89
|
-
*/
|
|
90
|
-
export declare const openUrl: (value: import("../types/IChaynsReact").OpenUrl) => Promise<void>;
|
|
91
|
-
/**
|
|
92
|
-
* The video specified in the URL is shown in video mode.
|
|
93
|
-
*/
|
|
94
|
-
export declare const openVideo: (value: import("../types/IChaynsReact").OpenVideo) => Promise<void>;
|
|
95
|
-
/**
|
|
96
|
-
* Refresh badge count in navigation, user information and pages
|
|
97
|
-
*/
|
|
98
|
-
export declare const refreshData: (value: import("../types/IChaynsReact").RefreshData) => Promise<void>;
|
|
99
|
-
/**
|
|
100
|
-
* Refresh accesstoken, should only be used when user object changes, not when token is invalid
|
|
101
|
-
*/
|
|
102
|
-
export declare const refreshAccessToken: () => Promise<void>;
|
|
103
|
-
/**
|
|
104
|
-
* This removes a listener to determine your location.
|
|
105
|
-
* @category Event listener
|
|
106
|
-
*/
|
|
107
|
-
export declare const removeGeoLocationListener: (value: number) => Promise<void>;
|
|
108
|
-
/**
|
|
109
|
-
* This removes a listener for changing toolbar visibility
|
|
110
|
-
* @category Event listener
|
|
111
|
-
*/
|
|
112
|
-
export declare const removeToolbarChangeListener: (value: number) => Promise<void>;
|
|
113
|
-
/**
|
|
114
|
-
* Removes scroll listener.
|
|
115
|
-
* @category Event listener
|
|
116
|
-
*/
|
|
117
|
-
export declare const removeScrollListener: (value: number) => Promise<void>;
|
|
118
|
-
/**
|
|
119
|
-
* Removes visibility change listener.
|
|
120
|
-
* @category Event listener
|
|
121
|
-
*/
|
|
122
|
-
export declare const removeVisibilityChangeListener: (value: number) => Promise<void>;
|
|
123
|
-
/**
|
|
124
|
-
* Removes window metrics listener.
|
|
125
|
-
* @category Event listener
|
|
126
|
-
*/
|
|
127
|
-
export declare const removeWindowMetricsListener: (value: number) => Promise<void>;
|
|
128
|
-
/**
|
|
129
|
-
* Select other page on chayns site.
|
|
130
|
-
*/
|
|
131
|
-
export declare const selectPage: (value: import("../types/IChaynsReact").SelectPage) => Promise<void>;
|
|
132
|
-
/**
|
|
133
|
-
* Scrolls by specific amount.
|
|
134
|
-
*/
|
|
135
|
-
export declare const scrollByY: (position: number, duration?: number | undefined) => Promise<void>;
|
|
136
|
-
/**
|
|
137
|
-
* Scrolls to specific position.
|
|
138
|
-
*/
|
|
139
|
-
export declare const scrollToY: (position: number, duration: number) => Promise<void>;
|
|
140
|
-
/**
|
|
141
|
-
* Sends intercom message to group.
|
|
142
|
-
*/
|
|
143
|
-
export declare const sendMessageToGroup: (groupId: number, message: import("../types/IChaynsReact").IntercomMessage) => Promise<Response>;
|
|
144
|
-
/**
|
|
145
|
-
* Sends intercom message to page.
|
|
146
|
-
*/
|
|
147
|
-
export declare const sendMessageToPage: (message: import("../types/IChaynsReact").IntercomMessage) => Promise<Response>;
|
|
148
|
-
/**
|
|
149
|
-
* Sends intercom message to an user.
|
|
150
|
-
*/
|
|
151
|
-
export declare const sendMessageToUser: (userId: number, message: import("../types/IChaynsReact").IntercomMessage) => Promise<Response>;
|
|
152
|
-
/**
|
|
153
|
-
* Switches admin mode, also toggles admin switch in top frame.
|
|
154
|
-
*/
|
|
155
|
-
export declare const setAdminMode: (enabled: boolean) => Promise<void>;
|
|
156
|
-
/**
|
|
157
|
-
* Sets the display timeout, only works in chayns App.
|
|
158
|
-
*/
|
|
159
|
-
export declare const setDisplayTimeout: (enabled: boolean) => Promise<import("../types/IChaynsReact").DisplayTimeout>;
|
|
160
|
-
/**
|
|
161
|
-
* Enables or disables a button which floats over the page.
|
|
162
|
-
*/
|
|
163
|
-
export declare const setFloatingButton: (value: import("../types/IChaynsReact").FloatingButton, callback: () => void) => Promise<void>;
|
|
164
|
-
/**
|
|
165
|
-
* Sets the height of the page.
|
|
166
|
-
*/
|
|
167
|
-
export declare const setHeight: (height: number) => Promise<void>;
|
|
168
|
-
/**
|
|
169
|
-
* Enables or disables the ability to refresh a page
|
|
170
|
-
*/
|
|
171
|
-
export declare const setRefreshScrollEnabled: (enabled: boolean) => Promise<import("../types/IChaynsReact").RefreshScrollEnabled>;
|
|
172
|
-
/**
|
|
173
|
-
* Scans a qr-code and returns the result
|
|
174
|
-
*/
|
|
175
|
-
export declare const setScanQrCode: (value: import("../types/IChaynsReact").ScanQrCodeRequest) => Promise<import("../types/IChaynsReact").ScanQrCodeResult>;
|
|
176
|
-
/**
|
|
177
|
-
* Temporarily change design settings in top frame
|
|
178
|
-
*/
|
|
179
|
-
export declare const setTempDesignSettings: (value: import("../types/IChaynsReact").DesignSettings) => Promise<void>;
|
|
180
|
-
/**
|
|
181
|
-
* Shows or hide a waitcursor
|
|
182
|
-
*/
|
|
183
|
-
export declare const setWaitCursor: (value: import("../types/IChaynsReact").WaitCursor) => Promise<void>;
|
|
184
|
-
/**
|
|
185
|
-
* Retrieves the value that is assigned to the key from a storage outside the frame
|
|
186
|
-
*/
|
|
187
|
-
export declare const storageGetItem: <T extends string | number | object>(key: string, accessMode?: import("../types/IChaynsReact").AccessMode | undefined) => Promise<T | undefined>;
|
|
188
|
-
/**
|
|
189
|
-
* Removes the value that is assigned to the key from a storage outside the frame
|
|
190
|
-
*/
|
|
191
|
-
export declare const storageRemoveItem: (key: string, accessMode?: import("../types/IChaynsReact").AccessMode | undefined) => Promise<void>;
|
|
192
|
-
/**
|
|
193
|
-
* Sets the value that is assigned to the key from a storage outside the frame
|
|
194
|
-
*/
|
|
195
|
-
export declare const storageSetItem: ChaynsReactFunctions["storageSetItem"];
|
|
196
|
-
/**
|
|
197
|
-
* This method lets a smartphone vibrate for the given time.
|
|
198
|
-
*/
|
|
199
|
-
export declare const vibrate: (value: import("../types/IChaynsReact").Vibrate) => Promise<void>;
|
|
200
|
-
/**
|
|
201
|
-
* This method creates a dialog
|
|
202
|
-
*/
|
|
203
|
-
export declare const createDialog: ChaynsReactFunctions["createDialog"];
|
|
204
|
-
/**
|
|
205
|
-
* Displays an overlay
|
|
206
|
-
*/
|
|
207
|
-
export declare const setOverlay: (value: import("../types/IChaynsReact").ShowOverlay, callback: () => void) => Promise<void>;
|
|
208
|
-
/**
|
|
209
|
-
* Generates a temp accesstoken, only valid for short period of time (~3 days), works only when no user is logged in
|
|
210
|
-
*/
|
|
211
|
-
export declare const addAnonymousAccount: () => Promise<import("../types/IChaynsReact").AnonymousAccountResult>;
|
|
212
|
-
/**
|
|
213
|
-
* Returns user information, only when user is logged in
|
|
214
|
-
* @category User functions
|
|
215
|
-
*/
|
|
216
|
-
export declare const getUser: () => import("../types/IChaynsReact").ChaynsApiUser | undefined;
|
|
217
|
-
export declare const getSite: () => ChaynsApiSite;
|
|
218
|
-
export declare const getCurrentPage: () => {
|
|
219
|
-
id: number;
|
|
220
|
-
siteId: string;
|
|
221
|
-
};
|
|
222
|
-
export declare const getDevice: () => ChaynsApiDevice;
|
|
223
|
-
export declare const getLanguage: () => {
|
|
224
|
-
site: import("../types/IChaynsReact").Language;
|
|
225
|
-
translation: import("../types/IChaynsReact").Language | null;
|
|
226
|
-
device: import("../types/IChaynsReact").Language;
|
|
227
|
-
active: import("../types/IChaynsReact").Language;
|
|
228
|
-
};
|
|
229
|
-
export declare const getParameters: () => {
|
|
230
|
-
[key: string]: string | string[];
|
|
231
|
-
[key: symbol]: string | string[];
|
|
232
|
-
};
|
|
233
|
-
export declare const getPages: () => import("../types/IChaynsReact").Page[];
|
|
234
|
-
export declare const getEnvironment: () => {
|
|
235
|
-
buildEnvironment: import("../types/IChaynsReact").Environment;
|
|
236
|
-
runtimeEnvironment: string | import("../types/IChaynsReact").RuntimeEnviroment;
|
|
237
|
-
};
|
|
238
|
-
export declare const user: UserInfo;
|
|
239
|
-
export declare const site: ChaynsApiSite;
|
|
240
|
-
export declare const device: ChaynsApiDevice;
|
|
241
|
-
export declare const language: {
|
|
242
|
-
site: import("../types/IChaynsReact").Language;
|
|
243
|
-
translation: import("../types/IChaynsReact").Language | null;
|
|
244
|
-
device: import("../types/IChaynsReact").Language;
|
|
245
|
-
active: import("../types/IChaynsReact").Language;
|
|
246
|
-
};
|
|
247
|
-
export declare const parameters: {
|
|
248
|
-
[key: string]: string | string[];
|
|
249
|
-
[key: symbol]: string | string[];
|
|
250
|
-
};
|
|
251
|
-
export declare const pages: import("../types/IChaynsReact").Page[];
|
|
252
|
-
export declare const environment: {
|
|
253
|
-
buildEnvironment: import("../types/IChaynsReact").Environment;
|
|
254
|
-
runtimeEnvironment: string | import("../types/IChaynsReact").RuntimeEnviroment;
|
|
255
|
-
};
|
|
1
|
+
import { ChaynsApiDevice, ChaynsApiSite, ChaynsReactFunctions, UserInfo } from '../types/IChaynsReact';
|
|
2
|
+
/**
|
|
3
|
+
* This adds a listener to determine your location.
|
|
4
|
+
* @category Event listener
|
|
5
|
+
*/
|
|
6
|
+
export declare const addGeoLocationListener: (value: {
|
|
7
|
+
timeout?: number | undefined;
|
|
8
|
+
silent?: boolean | undefined;
|
|
9
|
+
}, callback: (geoLocation: import("../types/IChaynsReact").GeoLocation) => void) => Promise<number>;
|
|
10
|
+
/**
|
|
11
|
+
* Adds a listener for scroll event by user.
|
|
12
|
+
* @category Event listener
|
|
13
|
+
*/
|
|
14
|
+
export declare const addScrollListener: (value: {
|
|
15
|
+
throttle?: number | undefined;
|
|
16
|
+
}, callback: (result: import("../types/IChaynsReact").ScrollListenerResult) => void) => Promise<number>;
|
|
17
|
+
/**
|
|
18
|
+
* This method will be executed when the page gets displayed or hidden.
|
|
19
|
+
* @category Event listener
|
|
20
|
+
*/
|
|
21
|
+
export declare const addVisibilityChangeListener: (callback: (result: import("../types/IChaynsReact").VisibilityChangeListenerResult) => void) => Promise<number>;
|
|
22
|
+
/**
|
|
23
|
+
* This method will be executed when the toolbar gets displayed or hidden.
|
|
24
|
+
* @category Event listener
|
|
25
|
+
*/
|
|
26
|
+
export declare const addToolbarChangeListener: (callback: (result: import("../types/IChaynsReact").ToolbarChangeListenerResult) => void) => Promise<number>;
|
|
27
|
+
/**
|
|
28
|
+
* This adds a listener to get the actual height of the page.
|
|
29
|
+
* @category Event listener
|
|
30
|
+
*/
|
|
31
|
+
export declare const addWindowMetricsListener: (callback: (result: import("../types/IChaynsReact").WindowMetricsListenerResult) => void) => Promise<number>; /**
|
|
32
|
+
* Allows a custom callback function to be defined
|
|
33
|
+
*/
|
|
34
|
+
export declare const customCallbackFunction: (type: string, data: unknown) => Promise<unknown>;
|
|
35
|
+
/**
|
|
36
|
+
* Get the accessToken from the user.
|
|
37
|
+
*/
|
|
38
|
+
export declare const getAccessToken: (value?: import("../types/IChaynsReact").AccessToken | undefined) => Promise<import("../types/IChaynsReact").AccessTokenResult>;
|
|
39
|
+
/**
|
|
40
|
+
* This method returns a list of installed share/social media apps.
|
|
41
|
+
*/
|
|
42
|
+
export declare const getAvailableSharingServices: () => Promise<import("../types/IChaynsReact").AvailableSharingServices>;
|
|
43
|
+
/**
|
|
44
|
+
* This method determines your location. If you want to track a route, use addGeoLocationListener.
|
|
45
|
+
*/
|
|
46
|
+
export declare const getGeoLocation: (value: {
|
|
47
|
+
timeout?: number | undefined;
|
|
48
|
+
silent?: boolean | undefined;
|
|
49
|
+
}) => Promise<import("../types/IChaynsReact").GeoLocation>;
|
|
50
|
+
/**
|
|
51
|
+
* This method returns user information for a specific user.
|
|
52
|
+
* @category User functions
|
|
53
|
+
*/
|
|
54
|
+
export declare const getUserInfo: (value: import("../types/IChaynsReact").UserInfoQuery) => Promise<UserInfo | null>;
|
|
55
|
+
/**
|
|
56
|
+
* Return the current scroll position of the top frame
|
|
57
|
+
*/
|
|
58
|
+
export declare const getScrollPosition: () => Promise<import("../types/IChaynsReact").ScrollListenerResult>;
|
|
59
|
+
/**
|
|
60
|
+
* Returns the window metrics.
|
|
61
|
+
*/
|
|
62
|
+
export declare const getWindowMetrics: () => Promise<import("../types/IChaynsReact").WindowMetricsListenerResult>;
|
|
63
|
+
/** @internal */
|
|
64
|
+
export declare const invokeCall: (value: import("../types/IChaynsReact").InvokeCall, callback?: ((result: any) => void) | undefined) => Promise<any>;
|
|
65
|
+
/** @internal */
|
|
66
|
+
export declare const invokeDialogCall: (value: import("../types/IChaynsReact").InvokeCall, callback?: ((result: any) => void) | undefined) => Promise<any>;
|
|
67
|
+
/**
|
|
68
|
+
* This method will show a login dialog where the user has the opportunity to log in.
|
|
69
|
+
*/
|
|
70
|
+
export declare const login: (value?: import("../types/IChaynsReact").Login | undefined, callback?: ((result: boolean) => void) | undefined, closeCallback?: (() => void) | undefined) => Promise<import("../types/IChaynsReact").LoginResult>;
|
|
71
|
+
/**
|
|
72
|
+
* This method will logout the user
|
|
73
|
+
*/
|
|
74
|
+
export declare const logout: () => Promise<void>;
|
|
75
|
+
/**
|
|
76
|
+
* This function navigates you to the previous site.
|
|
77
|
+
*/
|
|
78
|
+
export declare const navigateBack: () => Promise<void>;
|
|
79
|
+
/**
|
|
80
|
+
* The images specified in the url array is shown in gallery mode.
|
|
81
|
+
*/
|
|
82
|
+
export declare const openImage: (value: import("../types/IChaynsReact").OpenImage) => Promise<void>;
|
|
83
|
+
/**
|
|
84
|
+
* The images and videos specified in the items array is shown in gallery mode.
|
|
85
|
+
*/
|
|
86
|
+
export declare const openMedia: (value: import("../types/IChaynsReact").OpenMedia) => Promise<void>;
|
|
87
|
+
/**
|
|
88
|
+
* Opens an URL in the chayns environment.
|
|
89
|
+
*/
|
|
90
|
+
export declare const openUrl: (value: import("../types/IChaynsReact").OpenUrl) => Promise<void>;
|
|
91
|
+
/**
|
|
92
|
+
* The video specified in the URL is shown in video mode.
|
|
93
|
+
*/
|
|
94
|
+
export declare const openVideo: (value: import("../types/IChaynsReact").OpenVideo) => Promise<void>;
|
|
95
|
+
/**
|
|
96
|
+
* Refresh badge count in navigation, user information and pages
|
|
97
|
+
*/
|
|
98
|
+
export declare const refreshData: (value: import("../types/IChaynsReact").RefreshData) => Promise<void>;
|
|
99
|
+
/**
|
|
100
|
+
* Refresh accesstoken, should only be used when user object changes, not when token is invalid
|
|
101
|
+
*/
|
|
102
|
+
export declare const refreshAccessToken: () => Promise<void>;
|
|
103
|
+
/**
|
|
104
|
+
* This removes a listener to determine your location.
|
|
105
|
+
* @category Event listener
|
|
106
|
+
*/
|
|
107
|
+
export declare const removeGeoLocationListener: (value: number) => Promise<void>;
|
|
108
|
+
/**
|
|
109
|
+
* This removes a listener for changing toolbar visibility
|
|
110
|
+
* @category Event listener
|
|
111
|
+
*/
|
|
112
|
+
export declare const removeToolbarChangeListener: (value: number) => Promise<void>;
|
|
113
|
+
/**
|
|
114
|
+
* Removes scroll listener.
|
|
115
|
+
* @category Event listener
|
|
116
|
+
*/
|
|
117
|
+
export declare const removeScrollListener: (value: number) => Promise<void>;
|
|
118
|
+
/**
|
|
119
|
+
* Removes visibility change listener.
|
|
120
|
+
* @category Event listener
|
|
121
|
+
*/
|
|
122
|
+
export declare const removeVisibilityChangeListener: (value: number) => Promise<void>;
|
|
123
|
+
/**
|
|
124
|
+
* Removes window metrics listener.
|
|
125
|
+
* @category Event listener
|
|
126
|
+
*/
|
|
127
|
+
export declare const removeWindowMetricsListener: (value: number) => Promise<void>;
|
|
128
|
+
/**
|
|
129
|
+
* Select other page on chayns site.
|
|
130
|
+
*/
|
|
131
|
+
export declare const selectPage: (value: import("../types/IChaynsReact").SelectPage) => Promise<void>;
|
|
132
|
+
/**
|
|
133
|
+
* Scrolls by specific amount.
|
|
134
|
+
*/
|
|
135
|
+
export declare const scrollByY: (position: number, duration?: number | undefined) => Promise<void>;
|
|
136
|
+
/**
|
|
137
|
+
* Scrolls to specific position.
|
|
138
|
+
*/
|
|
139
|
+
export declare const scrollToY: (position: number, duration: number) => Promise<void>;
|
|
140
|
+
/**
|
|
141
|
+
* Sends intercom message to group.
|
|
142
|
+
*/
|
|
143
|
+
export declare const sendMessageToGroup: (groupId: number, message: import("../types/IChaynsReact").IntercomMessage) => Promise<Response>;
|
|
144
|
+
/**
|
|
145
|
+
* Sends intercom message to page.
|
|
146
|
+
*/
|
|
147
|
+
export declare const sendMessageToPage: (message: import("../types/IChaynsReact").IntercomMessage) => Promise<Response>;
|
|
148
|
+
/**
|
|
149
|
+
* Sends intercom message to an user.
|
|
150
|
+
*/
|
|
151
|
+
export declare const sendMessageToUser: (userId: number, message: import("../types/IChaynsReact").IntercomMessage) => Promise<Response>;
|
|
152
|
+
/**
|
|
153
|
+
* Switches admin mode, also toggles admin switch in top frame.
|
|
154
|
+
*/
|
|
155
|
+
export declare const setAdminMode: (enabled: boolean) => Promise<void>;
|
|
156
|
+
/**
|
|
157
|
+
* Sets the display timeout, only works in chayns App.
|
|
158
|
+
*/
|
|
159
|
+
export declare const setDisplayTimeout: (enabled: boolean) => Promise<import("../types/IChaynsReact").DisplayTimeout>;
|
|
160
|
+
/**
|
|
161
|
+
* Enables or disables a button which floats over the page.
|
|
162
|
+
*/
|
|
163
|
+
export declare const setFloatingButton: (value: import("../types/IChaynsReact").FloatingButton, callback: () => void) => Promise<void>;
|
|
164
|
+
/**
|
|
165
|
+
* Sets the height of the page.
|
|
166
|
+
*/
|
|
167
|
+
export declare const setHeight: (height: number) => Promise<void>;
|
|
168
|
+
/**
|
|
169
|
+
* Enables or disables the ability to refresh a page
|
|
170
|
+
*/
|
|
171
|
+
export declare const setRefreshScrollEnabled: (enabled: boolean) => Promise<import("../types/IChaynsReact").RefreshScrollEnabled>;
|
|
172
|
+
/**
|
|
173
|
+
* Scans a qr-code and returns the result
|
|
174
|
+
*/
|
|
175
|
+
export declare const setScanQrCode: (value: import("../types/IChaynsReact").ScanQrCodeRequest) => Promise<import("../types/IChaynsReact").ScanQrCodeResult>;
|
|
176
|
+
/**
|
|
177
|
+
* Temporarily change design settings in top frame
|
|
178
|
+
*/
|
|
179
|
+
export declare const setTempDesignSettings: (value: import("../types/IChaynsReact").DesignSettings) => Promise<void>;
|
|
180
|
+
/**
|
|
181
|
+
* Shows or hide a waitcursor
|
|
182
|
+
*/
|
|
183
|
+
export declare const setWaitCursor: (value: import("../types/IChaynsReact").WaitCursor) => Promise<void>;
|
|
184
|
+
/**
|
|
185
|
+
* Retrieves the value that is assigned to the key from a storage outside the frame
|
|
186
|
+
*/
|
|
187
|
+
export declare const storageGetItem: <T extends string | number | object>(key: string, accessMode?: import("../types/IChaynsReact").AccessMode | undefined) => Promise<T | undefined>;
|
|
188
|
+
/**
|
|
189
|
+
* Removes the value that is assigned to the key from a storage outside the frame
|
|
190
|
+
*/
|
|
191
|
+
export declare const storageRemoveItem: (key: string, accessMode?: import("../types/IChaynsReact").AccessMode | undefined) => Promise<void>;
|
|
192
|
+
/**
|
|
193
|
+
* Sets the value that is assigned to the key from a storage outside the frame
|
|
194
|
+
*/
|
|
195
|
+
export declare const storageSetItem: ChaynsReactFunctions["storageSetItem"];
|
|
196
|
+
/**
|
|
197
|
+
* This method lets a smartphone vibrate for the given time.
|
|
198
|
+
*/
|
|
199
|
+
export declare const vibrate: (value: import("../types/IChaynsReact").Vibrate) => Promise<void>;
|
|
200
|
+
/**
|
|
201
|
+
* This method creates a dialog
|
|
202
|
+
*/
|
|
203
|
+
export declare const createDialog: ChaynsReactFunctions["createDialog"];
|
|
204
|
+
/**
|
|
205
|
+
* Displays an overlay
|
|
206
|
+
*/
|
|
207
|
+
export declare const setOverlay: (value: import("../types/IChaynsReact").ShowOverlay, callback: () => void) => Promise<void>;
|
|
208
|
+
/**
|
|
209
|
+
* Generates a temp accesstoken, only valid for short period of time (~3 days), works only when no user is logged in
|
|
210
|
+
*/
|
|
211
|
+
export declare const addAnonymousAccount: () => Promise<import("../types/IChaynsReact").AnonymousAccountResult>;
|
|
212
|
+
/**
|
|
213
|
+
* Returns user information, only when user is logged in
|
|
214
|
+
* @category User functions
|
|
215
|
+
*/
|
|
216
|
+
export declare const getUser: () => import("../types/IChaynsReact").ChaynsApiUser | undefined;
|
|
217
|
+
export declare const getSite: () => ChaynsApiSite;
|
|
218
|
+
export declare const getCurrentPage: () => {
|
|
219
|
+
id: number;
|
|
220
|
+
siteId: string;
|
|
221
|
+
};
|
|
222
|
+
export declare const getDevice: () => ChaynsApiDevice;
|
|
223
|
+
export declare const getLanguage: () => {
|
|
224
|
+
site: import("../types/IChaynsReact").Language;
|
|
225
|
+
translation: import("../types/IChaynsReact").Language | null;
|
|
226
|
+
device: import("../types/IChaynsReact").Language;
|
|
227
|
+
active: import("../types/IChaynsReact").Language;
|
|
228
|
+
};
|
|
229
|
+
export declare const getParameters: () => {
|
|
230
|
+
[key: string]: string | string[];
|
|
231
|
+
[key: symbol]: string | string[];
|
|
232
|
+
};
|
|
233
|
+
export declare const getPages: () => import("../types/IChaynsReact").Page[];
|
|
234
|
+
export declare const getEnvironment: () => {
|
|
235
|
+
buildEnvironment: import("../types/IChaynsReact").Environment;
|
|
236
|
+
runtimeEnvironment: string | import("../types/IChaynsReact").RuntimeEnviroment;
|
|
237
|
+
};
|
|
238
|
+
export declare const user: UserInfo;
|
|
239
|
+
export declare const site: ChaynsApiSite;
|
|
240
|
+
export declare const device: ChaynsApiDevice;
|
|
241
|
+
export declare const language: {
|
|
242
|
+
site: import("../types/IChaynsReact").Language;
|
|
243
|
+
translation: import("../types/IChaynsReact").Language | null;
|
|
244
|
+
device: import("../types/IChaynsReact").Language;
|
|
245
|
+
active: import("../types/IChaynsReact").Language;
|
|
246
|
+
};
|
|
247
|
+
export declare const parameters: {
|
|
248
|
+
[key: string]: string | string[];
|
|
249
|
+
[key: symbol]: string | string[];
|
|
250
|
+
};
|
|
251
|
+
export declare const pages: import("../types/IChaynsReact").Page[];
|
|
252
|
+
export declare const environment: {
|
|
253
|
+
buildEnvironment: import("../types/IChaynsReact").Environment;
|
|
254
|
+
runtimeEnvironment: string | import("../types/IChaynsReact").RuntimeEnviroment;
|
|
255
|
+
};
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import type { IChaynsReact, IntercomMessage } from '../types/IChaynsReact';
|
|
2
|
-
/**
|
|
3
|
-
* @category Intercom functions
|
|
4
|
-
*/
|
|
5
|
-
export declare const sendMessageToUser: (api: IChaynsReact, object: IntercomMessage, receiverUserId: number) => Promise<Response>;
|
|
6
|
-
/**
|
|
7
|
-
* @category Intercom functions
|
|
8
|
-
*/
|
|
9
|
-
export declare const sendMessageToPage: (api: IChaynsReact, object: IntercomMessage) => Promise<Response>;
|
|
10
|
-
/**
|
|
11
|
-
* @category Intercom functions
|
|
12
|
-
*/
|
|
13
|
-
export declare const sendMessageToGroup: (api: IChaynsReact, object: IntercomMessage, groupId: number) => Promise<Response>;
|
|
1
|
+
import type { IChaynsReact, IntercomMessage } from '../types/IChaynsReact';
|
|
2
|
+
/**
|
|
3
|
+
* @category Intercom functions
|
|
4
|
+
*/
|
|
5
|
+
export declare const sendMessageToUser: (api: IChaynsReact, object: IntercomMessage, receiverUserId: number) => Promise<Response>;
|
|
6
|
+
/**
|
|
7
|
+
* @category Intercom functions
|
|
8
|
+
*/
|
|
9
|
+
export declare const sendMessageToPage: (api: IChaynsReact, object: IntercomMessage) => Promise<Response>;
|
|
10
|
+
/**
|
|
11
|
+
* @category Intercom functions
|
|
12
|
+
*/
|
|
13
|
+
export declare const sendMessageToGroup: (api: IChaynsReact, object: IntercomMessage, groupId: number) => Promise<Response>;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { VisibilityChangeListenerResult } from '../types/IChaynsReact';
|
|
2
|
-
/**
|
|
3
|
-
* @category Event listener
|
|
4
|
-
*/
|
|
5
|
-
export declare const addVisibilityChangeListener: (callback: (result: VisibilityChangeListenerResult) => void) => number;
|
|
6
|
-
/**
|
|
7
|
-
* @category Event listener
|
|
8
|
-
*/
|
|
9
|
-
export declare const removeVisibilityChangeListener: (id: number) => void;
|
|
1
|
+
import { VisibilityChangeListenerResult } from '../types/IChaynsReact';
|
|
2
|
+
/**
|
|
3
|
+
* @category Event listener
|
|
4
|
+
*/
|
|
5
|
+
export declare const addVisibilityChangeListener: (callback: (result: VisibilityChangeListenerResult) => void) => number;
|
|
6
|
+
/**
|
|
7
|
+
* @category Event listener
|
|
8
|
+
*/
|
|
9
|
+
export declare const removeVisibilityChangeListener: (id: number) => void;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
declare const AppDialogWrapper: ({ dialogEventTarget }: {
|
|
3
|
-
dialogEventTarget: any;
|
|
4
|
-
}) => React.JSX.Element;
|
|
5
|
-
export default AppDialogWrapper;
|
|
1
|
+
import React from 'react';
|
|
2
|
+
declare const AppDialogWrapper: ({ dialogEventTarget }: {
|
|
3
|
+
dialogEventTarget: any;
|
|
4
|
+
}) => React.JSX.Element;
|
|
5
|
+
export default AppDialogWrapper;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { IChaynsReact } from '../types/IChaynsReact';
|
|
3
|
-
export declare const ChaynsContext: import("react").Context<IChaynsReact | null>;
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { IChaynsReact } from '../types/IChaynsReact';
|
|
3
|
+
export declare const ChaynsContext: import("react").Context<IChaynsReact | null>;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import React, { ReactNode } from 'react';
|
|
2
|
-
import { ChaynsReactFunctions, ChaynsReactValues } from '../types/IChaynsReact';
|
|
3
|
-
type ChaynsProviderProps = {
|
|
4
|
-
data?: ChaynsReactValues;
|
|
5
|
-
functions?: ChaynsReactFunctions;
|
|
6
|
-
renderedByServer?: boolean;
|
|
7
|
-
isModule?: boolean;
|
|
8
|
-
children?: ReactNode;
|
|
9
|
-
};
|
|
10
|
-
declare const ChaynsProvider: React.FC<ChaynsProviderProps>;
|
|
11
|
-
export default ChaynsProvider;
|
|
1
|
+
import React, { ReactNode } from 'react';
|
|
2
|
+
import { ChaynsReactFunctions, ChaynsReactValues } from '../types/IChaynsReact';
|
|
3
|
+
type ChaynsProviderProps = {
|
|
4
|
+
data?: ChaynsReactValues;
|
|
5
|
+
functions?: ChaynsReactFunctions;
|
|
6
|
+
renderedByServer?: boolean;
|
|
7
|
+
isModule?: boolean;
|
|
8
|
+
children?: ReactNode;
|
|
9
|
+
};
|
|
10
|
+
declare const ChaynsProvider: React.FC<ChaynsProviderProps>;
|
|
11
|
+
export default ChaynsProvider;
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import React from "react";
|
|
2
|
-
export default class ErrorBoundary extends React.Component<{
|
|
3
|
-
children: React.ReactNode;
|
|
4
|
-
}, {
|
|
5
|
-
hasError: boolean;
|
|
6
|
-
}> {
|
|
7
|
-
constructor(props: any);
|
|
8
|
-
static getDerivedStateFromError(): {
|
|
9
|
-
hasError: boolean;
|
|
10
|
-
};
|
|
11
|
-
componentDidCatch(error: any, errorInfo: any): void;
|
|
12
|
-
render(): React.ReactNode;
|
|
13
|
-
}
|
|
1
|
+
import React from "react";
|
|
2
|
+
export default class ErrorBoundary extends React.Component<{
|
|
3
|
+
children: React.ReactNode;
|
|
4
|
+
}, {
|
|
5
|
+
hasError: boolean;
|
|
6
|
+
}> {
|
|
7
|
+
constructor(props: any);
|
|
8
|
+
static getDerivedStateFromError(): {
|
|
9
|
+
hasError: boolean;
|
|
10
|
+
};
|
|
11
|
+
componentDidCatch(error: any, errorInfo: any): void;
|
|
12
|
+
render(): React.ReactNode;
|
|
13
|
+
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { FC, ReactNode } from "react";
|
|
2
|
-
export type TaskList = (TaskList | Promise<unknown> | (() => Promise<unknown>))[];
|
|
3
|
-
export declare const WaitUntil: FC<{
|
|
4
|
-
tasks: TaskList;
|
|
5
|
-
children?: ReactNode;
|
|
6
|
-
loadingComponent?: ReactNode;
|
|
7
|
-
}>;
|
|
1
|
+
import { FC, ReactNode } from "react";
|
|
2
|
+
export type TaskList = (TaskList | Promise<unknown> | (() => Promise<unknown>))[];
|
|
3
|
+
export declare const WaitUntil: FC<{
|
|
4
|
+
tasks: TaskList;
|
|
5
|
+
children?: ReactNode;
|
|
6
|
+
loadingComponent?: ReactNode;
|
|
7
|
+
}>;
|