react-native-xenon 0.1.0
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/LICENSE +20 -0
- package/README.md +62 -0
- package/lib/commonjs/assets/code.png +0 -0
- package/lib/commonjs/assets/delete.png +0 -0
- package/lib/commonjs/assets/hide.png +0 -0
- package/lib/commonjs/assets/move.png +0 -0
- package/lib/commonjs/assets/record.png +0 -0
- package/lib/commonjs/constants.js +8 -0
- package/lib/commonjs/constants.js.map +1 -0
- package/lib/commonjs/contexts/MainContext.js +10 -0
- package/lib/commonjs/contexts/MainContext.js.map +1 -0
- package/lib/commonjs/contexts/index.js +14 -0
- package/lib/commonjs/contexts/index.js.map +1 -0
- package/lib/commonjs/global.d.js +2 -0
- package/lib/commonjs/global.d.js.map +1 -0
- package/lib/commonjs/hooks/index.js +28 -0
- package/lib/commonjs/hooks/index.js.map +1 -0
- package/lib/commonjs/hooks/useConsoleInterceptor.js +49 -0
- package/lib/commonjs/hooks/useConsoleInterceptor.js.map +1 -0
- package/lib/commonjs/hooks/useNetworkInterceptor.js +162 -0
- package/lib/commonjs/hooks/useNetworkInterceptor.js.map +1 -0
- package/lib/commonjs/hooks/useScrollToBottom.js +23 -0
- package/lib/commonjs/hooks/useScrollToBottom.js.map +1 -0
- package/lib/commonjs/index.js +14 -0
- package/lib/commonjs/index.js.map +1 -0
- package/lib/commonjs/interceptors/ConsoleInterceptor.js +93 -0
- package/lib/commonjs/interceptors/ConsoleInterceptor.js.map +1 -0
- package/lib/commonjs/interceptors/FetchInterceptor.js +114 -0
- package/lib/commonjs/interceptors/FetchInterceptor.js.map +1 -0
- package/lib/commonjs/interceptors/HttpInterceptor.js +57 -0
- package/lib/commonjs/interceptors/HttpInterceptor.js.map +1 -0
- package/lib/commonjs/interceptors/Interceptor.js +11 -0
- package/lib/commonjs/interceptors/Interceptor.js.map +1 -0
- package/lib/commonjs/interceptors/NetworkInterceptor.js +11 -0
- package/lib/commonjs/interceptors/NetworkInterceptor.js.map +1 -0
- package/lib/commonjs/interceptors/WebSocketInterceptor.js +150 -0
- package/lib/commonjs/interceptors/WebSocketInterceptor.js.map +1 -0
- package/lib/commonjs/interceptors/XHRInterceptor.js +69 -0
- package/lib/commonjs/interceptors/XHRInterceptor.js.map +1 -0
- package/lib/commonjs/interceptors/index.js +35 -0
- package/lib/commonjs/interceptors/index.js.map +1 -0
- package/lib/commonjs/types/common.js +18 -0
- package/lib/commonjs/types/common.js.map +1 -0
- package/lib/commonjs/types/console.js +2 -0
- package/lib/commonjs/types/console.js.map +1 -0
- package/lib/commonjs/types/http.js +6 -0
- package/lib/commonjs/types/http.js.map +1 -0
- package/lib/commonjs/types/index.js +50 -0
- package/lib/commonjs/types/index.js.map +1 -0
- package/lib/commonjs/types/websocket.js +6 -0
- package/lib/commonjs/types/websocket.js.map +1 -0
- package/lib/commonjs/ui/Xenon.js +117 -0
- package/lib/commonjs/ui/Xenon.js.map +1 -0
- package/lib/commonjs/ui/components/bubble/Bubble.js +82 -0
- package/lib/commonjs/ui/components/bubble/Bubble.js.map +1 -0
- package/lib/commonjs/ui/components/details/DetailsViewer.js +33 -0
- package/lib/commonjs/ui/components/details/DetailsViewer.js.map +1 -0
- package/lib/commonjs/ui/components/details/LogMessageDetails.js +30 -0
- package/lib/commonjs/ui/components/details/LogMessageDetails.js.map +1 -0
- package/lib/commonjs/ui/components/details/NetworkRequestDetails.js +130 -0
- package/lib/commonjs/ui/components/details/NetworkRequestDetails.js.map +1 -0
- package/lib/commonjs/ui/components/headers/DebuggerHeader.js +94 -0
- package/lib/commonjs/ui/components/headers/DebuggerHeader.js.map +1 -0
- package/lib/commonjs/ui/components/headers/NetworkPanelHeader.js +68 -0
- package/lib/commonjs/ui/components/headers/NetworkPanelHeader.js.map +1 -0
- package/lib/commonjs/ui/components/headers/NetworkRequestDetailsHeader.js +65 -0
- package/lib/commonjs/ui/components/headers/NetworkRequestDetailsHeader.js.map +1 -0
- package/lib/commonjs/ui/components/index.js +42 -0
- package/lib/commonjs/ui/components/index.js.map +1 -0
- package/lib/commonjs/ui/components/items/ConsolePanelItem.js +35 -0
- package/lib/commonjs/ui/components/items/ConsolePanelItem.js.map +1 -0
- package/lib/commonjs/ui/components/items/DebuggerHeaderItem.js +54 -0
- package/lib/commonjs/ui/components/items/DebuggerHeaderItem.js.map +1 -0
- package/lib/commonjs/ui/components/items/NetworkPanelItem.js +76 -0
- package/lib/commonjs/ui/components/items/NetworkPanelItem.js.map +1 -0
- package/lib/commonjs/ui/components/items/NetworkRequestDetailsHeaderItem.js +47 -0
- package/lib/commonjs/ui/components/items/NetworkRequestDetailsHeaderItem.js.map +1 -0
- package/lib/commonjs/ui/components/items/NetworkRequestDetailsItem.js +41 -0
- package/lib/commonjs/ui/components/items/NetworkRequestDetailsItem.js.map +1 -0
- package/lib/commonjs/ui/components/panels/ConsolePanel.js +58 -0
- package/lib/commonjs/ui/components/panels/ConsolePanel.js.map +1 -0
- package/lib/commonjs/ui/components/panels/NetworkPanel.js +66 -0
- package/lib/commonjs/ui/components/panels/NetworkPanel.js.map +1 -0
- package/lib/commonjs/utils.js +46 -0
- package/lib/commonjs/utils.js.map +1 -0
- package/lib/module/assets/code.png +0 -0
- package/lib/module/assets/delete.png +0 -0
- package/lib/module/assets/hide.png +0 -0
- package/lib/module/assets/move.png +0 -0
- package/lib/module/assets/record.png +0 -0
- package/lib/module/constants.js +4 -0
- package/lib/module/constants.js.map +1 -0
- package/lib/module/contexts/MainContext.js +6 -0
- package/lib/module/contexts/MainContext.js.map +1 -0
- package/lib/module/contexts/index.js +4 -0
- package/lib/module/contexts/index.js.map +1 -0
- package/lib/module/global.d.js +2 -0
- package/lib/module/global.d.js.map +1 -0
- package/lib/module/hooks/index.js +6 -0
- package/lib/module/hooks/index.js.map +1 -0
- package/lib/module/hooks/useConsoleInterceptor.js +45 -0
- package/lib/module/hooks/useConsoleInterceptor.js.map +1 -0
- package/lib/module/hooks/useNetworkInterceptor.js +158 -0
- package/lib/module/hooks/useNetworkInterceptor.js.map +1 -0
- package/lib/module/hooks/useScrollToBottom.js +19 -0
- package/lib/module/hooks/useScrollToBottom.js.map +1 -0
- package/lib/module/index.js +4 -0
- package/lib/module/index.js.map +1 -0
- package/lib/module/interceptors/ConsoleInterceptor.js +86 -0
- package/lib/module/interceptors/ConsoleInterceptor.js.map +1 -0
- package/lib/module/interceptors/FetchInterceptor.js +108 -0
- package/lib/module/interceptors/FetchInterceptor.js.map +1 -0
- package/lib/module/interceptors/HttpInterceptor.js +52 -0
- package/lib/module/interceptors/HttpInterceptor.js.map +1 -0
- package/lib/module/interceptors/Interceptor.js +6 -0
- package/lib/module/interceptors/Interceptor.js.map +1 -0
- package/lib/module/interceptors/NetworkInterceptor.js +5 -0
- package/lib/module/interceptors/NetworkInterceptor.js.map +1 -0
- package/lib/module/interceptors/WebSocketInterceptor.js +144 -0
- package/lib/module/interceptors/WebSocketInterceptor.js.map +1 -0
- package/lib/module/interceptors/XHRInterceptor.js +63 -0
- package/lib/module/interceptors/XHRInterceptor.js.map +1 -0
- package/lib/module/interceptors/index.js +7 -0
- package/lib/module/interceptors/index.js.map +1 -0
- package/lib/module/types/common.js +14 -0
- package/lib/module/types/common.js.map +1 -0
- package/lib/module/types/console.js +2 -0
- package/lib/module/types/console.js.map +1 -0
- package/lib/module/types/http.js +4 -0
- package/lib/module/types/http.js.map +1 -0
- package/lib/module/types/index.js +7 -0
- package/lib/module/types/index.js.map +1 -0
- package/lib/module/types/websocket.js +4 -0
- package/lib/module/types/websocket.js.map +1 -0
- package/lib/module/ui/Xenon.js +112 -0
- package/lib/module/ui/Xenon.js.map +1 -0
- package/lib/module/ui/components/bubble/Bubble.js +78 -0
- package/lib/module/ui/components/bubble/Bubble.js.map +1 -0
- package/lib/module/ui/components/details/DetailsViewer.js +28 -0
- package/lib/module/ui/components/details/DetailsViewer.js.map +1 -0
- package/lib/module/ui/components/details/LogMessageDetails.js +26 -0
- package/lib/module/ui/components/details/LogMessageDetails.js.map +1 -0
- package/lib/module/ui/components/details/NetworkRequestDetails.js +125 -0
- package/lib/module/ui/components/details/NetworkRequestDetails.js.map +1 -0
- package/lib/module/ui/components/headers/DebuggerHeader.js +89 -0
- package/lib/module/ui/components/headers/DebuggerHeader.js.map +1 -0
- package/lib/module/ui/components/headers/NetworkPanelHeader.js +64 -0
- package/lib/module/ui/components/headers/NetworkPanelHeader.js.map +1 -0
- package/lib/module/ui/components/headers/NetworkRequestDetailsHeader.js +60 -0
- package/lib/module/ui/components/headers/NetworkRequestDetailsHeader.js.map +1 -0
- package/lib/module/ui/components/index.js +8 -0
- package/lib/module/ui/components/index.js.map +1 -0
- package/lib/module/ui/components/items/ConsolePanelItem.js +31 -0
- package/lib/module/ui/components/items/ConsolePanelItem.js.map +1 -0
- package/lib/module/ui/components/items/DebuggerHeaderItem.js +50 -0
- package/lib/module/ui/components/items/DebuggerHeaderItem.js.map +1 -0
- package/lib/module/ui/components/items/NetworkPanelItem.js +72 -0
- package/lib/module/ui/components/items/NetworkPanelItem.js.map +1 -0
- package/lib/module/ui/components/items/NetworkRequestDetailsHeaderItem.js +43 -0
- package/lib/module/ui/components/items/NetworkRequestDetailsHeaderItem.js.map +1 -0
- package/lib/module/ui/components/items/NetworkRequestDetailsItem.js +37 -0
- package/lib/module/ui/components/items/NetworkRequestDetailsItem.js.map +1 -0
- package/lib/module/ui/components/panels/ConsolePanel.js +53 -0
- package/lib/module/ui/components/panels/ConsolePanel.js.map +1 -0
- package/lib/module/ui/components/panels/NetworkPanel.js +61 -0
- package/lib/module/ui/components/panels/NetworkPanel.js.map +1 -0
- package/lib/module/utils.js +35 -0
- package/lib/module/utils.js.map +1 -0
- package/lib/typescript/commonjs/package.json +1 -0
- package/lib/typescript/commonjs/src/constants.d.ts +2 -0
- package/lib/typescript/commonjs/src/constants.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/contexts/MainContext.d.ts +24 -0
- package/lib/typescript/commonjs/src/contexts/MainContext.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/contexts/index.d.ts +2 -0
- package/lib/typescript/commonjs/src/contexts/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/hooks/index.d.ts +4 -0
- package/lib/typescript/commonjs/src/hooks/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/hooks/useConsoleInterceptor.d.ts +13 -0
- package/lib/typescript/commonjs/src/hooks/useConsoleInterceptor.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/hooks/useNetworkInterceptor.d.ts +12 -0
- package/lib/typescript/commonjs/src/hooks/useNetworkInterceptor.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/hooks/useScrollToBottom.d.ts +3 -0
- package/lib/typescript/commonjs/src/hooks/useScrollToBottom.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/index.d.ts +2 -0
- package/lib/typescript/commonjs/src/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/interceptors/ConsoleInterceptor.d.ts +10 -0
- package/lib/typescript/commonjs/src/interceptors/ConsoleInterceptor.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/interceptors/FetchInterceptor.d.ts +8 -0
- package/lib/typescript/commonjs/src/interceptors/FetchInterceptor.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/interceptors/HttpInterceptor.d.ts +23 -0
- package/lib/typescript/commonjs/src/interceptors/HttpInterceptor.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/interceptors/Interceptor.d.ts +6 -0
- package/lib/typescript/commonjs/src/interceptors/Interceptor.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/interceptors/NetworkInterceptor.d.ts +6 -0
- package/lib/typescript/commonjs/src/interceptors/NetworkInterceptor.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/interceptors/WebSocketInterceptor.d.ts +34 -0
- package/lib/typescript/commonjs/src/interceptors/WebSocketInterceptor.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/interceptors/XHRInterceptor.d.ts +8 -0
- package/lib/typescript/commonjs/src/interceptors/XHRInterceptor.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/interceptors/index.d.ts +5 -0
- package/lib/typescript/commonjs/src/interceptors/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/common.d.ts +19 -0
- package/lib/typescript/commonjs/src/types/common.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/console.d.ts +5 -0
- package/lib/typescript/commonjs/src/types/console.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/http.d.ts +21 -0
- package/lib/typescript/commonjs/src/types/http.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/index.d.ts +5 -0
- package/lib/typescript/commonjs/src/types/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/websocket.d.ts +29 -0
- package/lib/typescript/commonjs/src/types/websocket.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/Xenon.d.ts +16 -0
- package/lib/typescript/commonjs/src/ui/Xenon.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/bubble/Bubble.d.ts +9 -0
- package/lib/typescript/commonjs/src/ui/components/bubble/Bubble.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/details/DetailsViewer.d.ts +2 -0
- package/lib/typescript/commonjs/src/ui/components/details/DetailsViewer.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/details/LogMessageDetails.d.ts +7 -0
- package/lib/typescript/commonjs/src/ui/components/details/LogMessageDetails.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/details/NetworkRequestDetails.d.ts +7 -0
- package/lib/typescript/commonjs/src/ui/components/details/NetworkRequestDetails.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/headers/DebuggerHeader.d.ts +2 -0
- package/lib/typescript/commonjs/src/ui/components/headers/DebuggerHeader.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/headers/NetworkPanelHeader.d.ts +2 -0
- package/lib/typescript/commonjs/src/ui/components/headers/NetworkPanelHeader.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/headers/NetworkRequestDetailsHeader.d.ts +13 -0
- package/lib/typescript/commonjs/src/ui/components/headers/NetworkRequestDetailsHeader.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/index.d.ts +6 -0
- package/lib/typescript/commonjs/src/ui/components/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/items/ConsolePanelItem.d.ts +7 -0
- package/lib/typescript/commonjs/src/ui/components/items/ConsolePanelItem.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/items/DebuggerHeaderItem.d.ts +10 -0
- package/lib/typescript/commonjs/src/ui/components/items/DebuggerHeaderItem.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/items/NetworkPanelItem.d.ts +10 -0
- package/lib/typescript/commonjs/src/ui/components/items/NetworkPanelItem.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/items/NetworkRequestDetailsHeaderItem.d.ts +11 -0
- package/lib/typescript/commonjs/src/ui/components/items/NetworkRequestDetailsHeaderItem.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/items/NetworkRequestDetailsItem.d.ts +8 -0
- package/lib/typescript/commonjs/src/ui/components/items/NetworkRequestDetailsItem.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/panels/ConsolePanel.d.ts +2 -0
- package/lib/typescript/commonjs/src/ui/components/panels/ConsolePanel.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/ui/components/panels/NetworkPanel.d.ts +2 -0
- package/lib/typescript/commonjs/src/ui/components/panels/NetworkPanel.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/utils.d.ts +9 -0
- package/lib/typescript/commonjs/src/utils.d.ts.map +1 -0
- package/lib/typescript/module/package.json +1 -0
- package/lib/typescript/module/src/constants.d.ts +2 -0
- package/lib/typescript/module/src/constants.d.ts.map +1 -0
- package/lib/typescript/module/src/contexts/MainContext.d.ts +24 -0
- package/lib/typescript/module/src/contexts/MainContext.d.ts.map +1 -0
- package/lib/typescript/module/src/contexts/index.d.ts +2 -0
- package/lib/typescript/module/src/contexts/index.d.ts.map +1 -0
- package/lib/typescript/module/src/hooks/index.d.ts +4 -0
- package/lib/typescript/module/src/hooks/index.d.ts.map +1 -0
- package/lib/typescript/module/src/hooks/useConsoleInterceptor.d.ts +13 -0
- package/lib/typescript/module/src/hooks/useConsoleInterceptor.d.ts.map +1 -0
- package/lib/typescript/module/src/hooks/useNetworkInterceptor.d.ts +12 -0
- package/lib/typescript/module/src/hooks/useNetworkInterceptor.d.ts.map +1 -0
- package/lib/typescript/module/src/hooks/useScrollToBottom.d.ts +3 -0
- package/lib/typescript/module/src/hooks/useScrollToBottom.d.ts.map +1 -0
- package/lib/typescript/module/src/index.d.ts +2 -0
- package/lib/typescript/module/src/index.d.ts.map +1 -0
- package/lib/typescript/module/src/interceptors/ConsoleInterceptor.d.ts +10 -0
- package/lib/typescript/module/src/interceptors/ConsoleInterceptor.d.ts.map +1 -0
- package/lib/typescript/module/src/interceptors/FetchInterceptor.d.ts +8 -0
- package/lib/typescript/module/src/interceptors/FetchInterceptor.d.ts.map +1 -0
- package/lib/typescript/module/src/interceptors/HttpInterceptor.d.ts +23 -0
- package/lib/typescript/module/src/interceptors/HttpInterceptor.d.ts.map +1 -0
- package/lib/typescript/module/src/interceptors/Interceptor.d.ts +6 -0
- package/lib/typescript/module/src/interceptors/Interceptor.d.ts.map +1 -0
- package/lib/typescript/module/src/interceptors/NetworkInterceptor.d.ts +6 -0
- package/lib/typescript/module/src/interceptors/NetworkInterceptor.d.ts.map +1 -0
- package/lib/typescript/module/src/interceptors/WebSocketInterceptor.d.ts +34 -0
- package/lib/typescript/module/src/interceptors/WebSocketInterceptor.d.ts.map +1 -0
- package/lib/typescript/module/src/interceptors/XHRInterceptor.d.ts +8 -0
- package/lib/typescript/module/src/interceptors/XHRInterceptor.d.ts.map +1 -0
- package/lib/typescript/module/src/interceptors/index.d.ts +5 -0
- package/lib/typescript/module/src/interceptors/index.d.ts.map +1 -0
- package/lib/typescript/module/src/types/common.d.ts +19 -0
- package/lib/typescript/module/src/types/common.d.ts.map +1 -0
- package/lib/typescript/module/src/types/console.d.ts +5 -0
- package/lib/typescript/module/src/types/console.d.ts.map +1 -0
- package/lib/typescript/module/src/types/http.d.ts +21 -0
- package/lib/typescript/module/src/types/http.d.ts.map +1 -0
- package/lib/typescript/module/src/types/index.d.ts +5 -0
- package/lib/typescript/module/src/types/index.d.ts.map +1 -0
- package/lib/typescript/module/src/types/websocket.d.ts +29 -0
- package/lib/typescript/module/src/types/websocket.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/Xenon.d.ts +16 -0
- package/lib/typescript/module/src/ui/Xenon.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/bubble/Bubble.d.ts +9 -0
- package/lib/typescript/module/src/ui/components/bubble/Bubble.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/details/DetailsViewer.d.ts +2 -0
- package/lib/typescript/module/src/ui/components/details/DetailsViewer.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/details/LogMessageDetails.d.ts +7 -0
- package/lib/typescript/module/src/ui/components/details/LogMessageDetails.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/details/NetworkRequestDetails.d.ts +7 -0
- package/lib/typescript/module/src/ui/components/details/NetworkRequestDetails.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/headers/DebuggerHeader.d.ts +2 -0
- package/lib/typescript/module/src/ui/components/headers/DebuggerHeader.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/headers/NetworkPanelHeader.d.ts +2 -0
- package/lib/typescript/module/src/ui/components/headers/NetworkPanelHeader.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/headers/NetworkRequestDetailsHeader.d.ts +13 -0
- package/lib/typescript/module/src/ui/components/headers/NetworkRequestDetailsHeader.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/index.d.ts +6 -0
- package/lib/typescript/module/src/ui/components/index.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/items/ConsolePanelItem.d.ts +7 -0
- package/lib/typescript/module/src/ui/components/items/ConsolePanelItem.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/items/DebuggerHeaderItem.d.ts +10 -0
- package/lib/typescript/module/src/ui/components/items/DebuggerHeaderItem.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/items/NetworkPanelItem.d.ts +10 -0
- package/lib/typescript/module/src/ui/components/items/NetworkPanelItem.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/items/NetworkRequestDetailsHeaderItem.d.ts +11 -0
- package/lib/typescript/module/src/ui/components/items/NetworkRequestDetailsHeaderItem.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/items/NetworkRequestDetailsItem.d.ts +8 -0
- package/lib/typescript/module/src/ui/components/items/NetworkRequestDetailsItem.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/panels/ConsolePanel.d.ts +2 -0
- package/lib/typescript/module/src/ui/components/panels/ConsolePanel.d.ts.map +1 -0
- package/lib/typescript/module/src/ui/components/panels/NetworkPanel.d.ts +2 -0
- package/lib/typescript/module/src/ui/components/panels/NetworkPanel.d.ts.map +1 -0
- package/lib/typescript/module/src/utils.d.ts +9 -0
- package/lib/typescript/module/src/utils.d.ts.map +1 -0
- package/package.json +219 -0
- package/src/assets/code.png +0 -0
- package/src/assets/delete.png +0 -0
- package/src/assets/hide.png +0 -0
- package/src/assets/move.png +0 -0
- package/src/assets/record.png +0 -0
- package/src/constants.ts +1 -0
- package/src/contexts/MainContext.ts +34 -0
- package/src/contexts/index.ts +1 -0
- package/src/global.d.ts +29 -0
- package/src/hooks/index.ts +3 -0
- package/src/hooks/useConsoleInterceptor.ts +58 -0
- package/src/hooks/useNetworkInterceptor.ts +263 -0
- package/src/hooks/useScrollToBottom.ts +23 -0
- package/src/index.ts +1 -0
- package/src/interceptors/ConsoleInterceptor.ts +115 -0
- package/src/interceptors/FetchInterceptor.ts +134 -0
- package/src/interceptors/HttpInterceptor.ts +65 -0
- package/src/interceptors/Interceptor.ts +6 -0
- package/src/interceptors/NetworkInterceptor.ts +6 -0
- package/src/interceptors/WebSocketInterceptor.ts +189 -0
- package/src/interceptors/XHRInterceptor.ts +97 -0
- package/src/interceptors/index.ts +4 -0
- package/src/types/common.ts +26 -0
- package/src/types/console.ts +4 -0
- package/src/types/http.ts +44 -0
- package/src/types/index.ts +4 -0
- package/src/types/websocket.ts +46 -0
- package/src/ui/Xenon.tsx +149 -0
- package/src/ui/components/bubble/Bubble.tsx +93 -0
- package/src/ui/components/details/DetailsViewer.tsx +20 -0
- package/src/ui/components/details/LogMessageDetails.tsx +26 -0
- package/src/ui/components/details/NetworkRequestDetails.tsx +140 -0
- package/src/ui/components/headers/DebuggerHeader.tsx +112 -0
- package/src/ui/components/headers/NetworkPanelHeader.tsx +58 -0
- package/src/ui/components/headers/NetworkRequestDetailsHeader.tsx +91 -0
- package/src/ui/components/index.ts +5 -0
- package/src/ui/components/items/ConsolePanelItem.tsx +28 -0
- package/src/ui/components/items/DebuggerHeaderItem.tsx +65 -0
- package/src/ui/components/items/NetworkPanelItem.tsx +71 -0
- package/src/ui/components/items/NetworkRequestDetailsHeaderItem.tsx +52 -0
- package/src/ui/components/items/NetworkRequestDetailsItem.tsx +43 -0
- package/src/ui/components/panels/ConsolePanel.tsx +55 -0
- package/src/ui/components/panels/NetworkPanel.tsx +64 -0
- package/src/utils.ts +54 -0
@@ -0,0 +1,65 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.default = NetworkDetailsHeader;
|
7
|
+
var _react = require("react");
|
8
|
+
var _reactNative = require("react-native");
|
9
|
+
var _NetworkRequestDetailsHeaderItem = _interopRequireDefault(require("../items/NetworkRequestDetailsHeaderItem.js"));
|
10
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
11
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
12
|
+
function NetworkDetailsHeader({
|
13
|
+
selectedTab,
|
14
|
+
onChangeTab,
|
15
|
+
headersShown = true,
|
16
|
+
queryStringParametersShown = true,
|
17
|
+
bodyShown = true,
|
18
|
+
responseShown = true,
|
19
|
+
messagesShown = true
|
20
|
+
}) {
|
21
|
+
const data = (0, _react.useMemo)(() => [{
|
22
|
+
visible: headersShown,
|
23
|
+
name: 'headers',
|
24
|
+
label: 'Headers'
|
25
|
+
}, {
|
26
|
+
visible: queryStringParametersShown,
|
27
|
+
name: 'queryStringParameters',
|
28
|
+
label: 'Query String Parameters'
|
29
|
+
}, {
|
30
|
+
visible: bodyShown,
|
31
|
+
name: 'body',
|
32
|
+
label: 'Body'
|
33
|
+
}, {
|
34
|
+
visible: responseShown,
|
35
|
+
name: 'response',
|
36
|
+
label: 'Response'
|
37
|
+
}, {
|
38
|
+
visible: messagesShown,
|
39
|
+
name: 'messages',
|
40
|
+
label: 'Messages'
|
41
|
+
}], [bodyShown, headersShown, messagesShown, queryStringParametersShown, responseShown]);
|
42
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.ScrollView, {
|
43
|
+
horizontal: true,
|
44
|
+
style: styles.container,
|
45
|
+
contentContainerStyle: styles.contentContainer,
|
46
|
+
showsHorizontalScrollIndicator: false,
|
47
|
+
children: data.map(item => /*#__PURE__*/(0, _jsxRuntime.jsx)(_NetworkRequestDetailsHeaderItem.default, {
|
48
|
+
onPress: () => onChangeTab(item.name),
|
49
|
+
isSelected: item.name === selectedTab,
|
50
|
+
visible: item.visible,
|
51
|
+
name: item.name,
|
52
|
+
label: item.label
|
53
|
+
}, item.name))
|
54
|
+
});
|
55
|
+
}
|
56
|
+
const styles = _reactNative.StyleSheet.create({
|
57
|
+
container: {
|
58
|
+
flexGrow: 0
|
59
|
+
},
|
60
|
+
contentContainer: {
|
61
|
+
paddingHorizontal: 8,
|
62
|
+
columnGap: 8
|
63
|
+
}
|
64
|
+
});
|
65
|
+
//# sourceMappingURL=NetworkRequestDetailsHeader.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"names":["_react","require","_reactNative","_NetworkRequestDetailsHeaderItem","_interopRequireDefault","_jsxRuntime","e","__esModule","default","NetworkDetailsHeader","selectedTab","onChangeTab","headersShown","queryStringParametersShown","bodyShown","responseShown","messagesShown","data","useMemo","visible","name","label","jsx","ScrollView","horizontal","style","styles","container","contentContainerStyle","contentContainer","showsHorizontalScrollIndicator","children","map","item","onPress","isSelected","StyleSheet","create","flexGrow","paddingHorizontal","columnGap"],"sourceRoot":"../../../../../src","sources":["ui/components/headers/NetworkRequestDetailsHeader.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAEA,IAAAE,gCAAA,GAAAC,sBAAA,CAAAH,OAAA;AAAuF,IAAAI,WAAA,GAAAJ,OAAA;AAAA,SAAAG,uBAAAE,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAkBxE,SAASG,oBAAoBA,CAAC;EAC3CC,WAAW;EACXC,WAAW;EACXC,YAAY,GAAG,IAAI;EACnBC,0BAA0B,GAAG,IAAI;EACjCC,SAAS,GAAG,IAAI;EAChBC,aAAa,GAAG,IAAI;EACpBC,aAAa,GAAG;AACS,CAAC,EAAE;EAC5B,MAAMC,IAAI,GAAG,IAAAC,cAAO,EAClB,MAAM,CACJ;IACEC,OAAO,EAAEP,YAAY;IACrBQ,IAAI,EAAE,SAAS;IACfC,KAAK,EAAE;EACT,CAAC,EACD;IACEF,OAAO,EAAEN,0BAA0B;IACnCO,IAAI,EAAE,uBAAuB;IAC7BC,KAAK,EAAE;EACT,CAAC,EACD;IACEF,OAAO,EAAEL,SAAS;IAClBM,IAAI,EAAE,MAAM;IACZC,KAAK,EAAE;EACT,CAAC,EACD;IACEF,OAAO,EAAEJ,aAAa;IACtBK,IAAI,EAAE,UAAU;IAChBC,KAAK,EAAE;EACT,CAAC,EACD;IACEF,OAAO,EAAEH,aAAa;IACtBI,IAAI,EAAE,UAAU;IAChBC,KAAK,EAAE;EACT,CAAC,CACF,EACD,CAACP,SAAS,EAAEF,YAAY,EAAEI,aAAa,EAAEH,0BAA0B,EAAEE,aAAa,CACpF,CAAC;EAED,oBACE,IAAAV,WAAA,CAAAiB,GAAA,EAACpB,YAAA,CAAAqB,UAAU;IACTC,UAAU;IACVC,KAAK,EAAEC,MAAM,CAACC,SAAU;IACxBC,qBAAqB,EAAEF,MAAM,CAACG,gBAAiB;IAC/CC,8BAA8B,EAAE,KAAM;IAAAC,QAAA,EAErCd,IAAI,CAACe,GAAG,CAACC,IAAI,iBACZ,IAAA5B,WAAA,CAAAiB,GAAA,EAACnB,gCAAA,CAAAK,OAA+B;MAE9B0B,OAAO,EAAEA,CAAA,KAAMvB,WAAW,CAACsB,IAAI,CAACb,IAAI,CAAE;MACtCe,UAAU,EAAEF,IAAI,CAACb,IAAI,KAAKV,WAAY;MACtCS,OAAO,EAAEc,IAAI,CAACd,OAAQ;MACtBC,IAAI,EAAEa,IAAI,CAACb,IAAK;MAChBC,KAAK,EAAEY,IAAI,CAACZ;IAAM,GALbY,IAAI,CAACb,IAMX,CACF;EAAC,CACQ,CAAC;AAEjB;AAEA,MAAMM,MAAM,GAAGU,uBAAU,CAACC,MAAM,CAAC;EAC/BV,SAAS,EAAE;IACTW,QAAQ,EAAE;EACZ,CAAC;EACDT,gBAAgB,EAAE;IAChBU,iBAAiB,EAAE,CAAC;IACpBC,SAAS,EAAE;EACb;AACF,CAAC,CAAC","ignoreList":[]}
|
@@ -0,0 +1,42 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
Object.defineProperty(exports, "Bubble", {
|
7
|
+
enumerable: true,
|
8
|
+
get: function () {
|
9
|
+
return _Bubble.default;
|
10
|
+
}
|
11
|
+
});
|
12
|
+
Object.defineProperty(exports, "ConsolePanel", {
|
13
|
+
enumerable: true,
|
14
|
+
get: function () {
|
15
|
+
return _ConsolePanel.default;
|
16
|
+
}
|
17
|
+
});
|
18
|
+
Object.defineProperty(exports, "DebuggerHeader", {
|
19
|
+
enumerable: true,
|
20
|
+
get: function () {
|
21
|
+
return _DebuggerHeader.default;
|
22
|
+
}
|
23
|
+
});
|
24
|
+
Object.defineProperty(exports, "DetailsViewer", {
|
25
|
+
enumerable: true,
|
26
|
+
get: function () {
|
27
|
+
return _DetailsViewer.default;
|
28
|
+
}
|
29
|
+
});
|
30
|
+
Object.defineProperty(exports, "NetworkPanel", {
|
31
|
+
enumerable: true,
|
32
|
+
get: function () {
|
33
|
+
return _NetworkPanel.default;
|
34
|
+
}
|
35
|
+
});
|
36
|
+
var _Bubble = _interopRequireDefault(require("./bubble/Bubble.js"));
|
37
|
+
var _DebuggerHeader = _interopRequireDefault(require("./headers/DebuggerHeader.js"));
|
38
|
+
var _NetworkPanel = _interopRequireDefault(require("./panels/NetworkPanel.js"));
|
39
|
+
var _ConsolePanel = _interopRequireDefault(require("./panels/ConsolePanel.js"));
|
40
|
+
var _DetailsViewer = _interopRequireDefault(require("./details/DetailsViewer.js"));
|
41
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
42
|
+
//# sourceMappingURL=index.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"names":["_Bubble","_interopRequireDefault","require","_DebuggerHeader","_NetworkPanel","_ConsolePanel","_DetailsViewer","e","__esModule","default"],"sourceRoot":"../../../../src","sources":["ui/components/index.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,OAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,eAAA,GAAAF,sBAAA,CAAAC,OAAA;AACA,IAAAE,aAAA,GAAAH,sBAAA,CAAAC,OAAA;AACA,IAAAG,aAAA,GAAAJ,sBAAA,CAAAC,OAAA;AACA,IAAAI,cAAA,GAAAL,sBAAA,CAAAC,OAAA;AAAmE,SAAAD,uBAAAM,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA","ignoreList":[]}
|
@@ -0,0 +1,35 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.default = ConsolePanelItem;
|
7
|
+
var _reactNative = require("react-native");
|
8
|
+
var _utils = require("../../../utils.js");
|
9
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
10
|
+
function ConsolePanelItem({
|
11
|
+
type,
|
12
|
+
values,
|
13
|
+
onPress
|
14
|
+
}) {
|
15
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.TouchableOpacity, {
|
16
|
+
onPress: onPress,
|
17
|
+
style: styles.container,
|
18
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
|
19
|
+
numberOfLines: 1,
|
20
|
+
style: styles.text,
|
21
|
+
children: (0, _utils.formatLogMessage)(type, values)
|
22
|
+
})
|
23
|
+
});
|
24
|
+
}
|
25
|
+
const styles = _reactNative.StyleSheet.create({
|
26
|
+
container: {
|
27
|
+
flex: 1,
|
28
|
+
padding: 8
|
29
|
+
},
|
30
|
+
text: {
|
31
|
+
color: '#000000',
|
32
|
+
fontSize: 14
|
33
|
+
}
|
34
|
+
});
|
35
|
+
//# sourceMappingURL=ConsolePanelItem.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"names":["_reactNative","require","_utils","_jsxRuntime","ConsolePanelItem","type","values","onPress","jsx","TouchableOpacity","style","styles","container","children","Text","numberOfLines","text","formatLogMessage","StyleSheet","create","flex","padding","color","fontSize"],"sourceRoot":"../../../../../src","sources":["ui/components/items/ConsolePanelItem.tsx"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AAEA,IAAAC,MAAA,GAAAD,OAAA;AAAkD,IAAAE,WAAA,GAAAF,OAAA;AAMnC,SAASG,gBAAgBA,CAAC;EAAEC,IAAI;EAAEC,MAAM;EAAEC;AAA+B,CAAC,EAAE;EACzF,oBACE,IAAAJ,WAAA,CAAAK,GAAA,EAACR,YAAA,CAAAS,gBAAgB;IAACF,OAAO,EAAEA,OAAQ;IAACG,KAAK,EAAEC,MAAM,CAACC,SAAU;IAAAC,QAAA,eAC1D,IAAAV,WAAA,CAAAK,GAAA,EAACR,YAAA,CAAAc,IAAI;MAACC,aAAa,EAAE,CAAE;MAACL,KAAK,EAAEC,MAAM,CAACK,IAAK;MAAAH,QAAA,EACxC,IAAAI,uBAAgB,EAACZ,IAAI,EAAEC,MAAM;IAAC,CAC3B;EAAC,CACS,CAAC;AAEvB;AAEA,MAAMK,MAAM,GAAGO,uBAAU,CAACC,MAAM,CAAC;EAC/BP,SAAS,EAAE;IACTQ,IAAI,EAAE,CAAC;IACPC,OAAO,EAAE;EACX,CAAC;EACDL,IAAI,EAAE;IACJM,KAAK,EAAE,SAAS;IAChBC,QAAQ,EAAE;EACZ;AACF,CAAC,CAAC","ignoreList":[]}
|
@@ -0,0 +1,54 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.default = DebuggerHeaderItem;
|
7
|
+
var _reactNative = require("react-native");
|
8
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
9
|
+
function DebuggerHeaderItem(props) {
|
10
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.TouchableOpacity, {
|
11
|
+
onPress: props.onPress,
|
12
|
+
activeOpacity: 0.8,
|
13
|
+
style: [styles.container, props.isLabel ? props.isActive ? styles.activeLabelContainer : styles.labelContainer : props.isActive ? styles.activeContainer : undefined],
|
14
|
+
children: typeof props.content === 'string' ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
|
15
|
+
style: styles.title,
|
16
|
+
children: props.content
|
17
|
+
}) : /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Image, {
|
18
|
+
source: props.content,
|
19
|
+
style: styles.icon
|
20
|
+
})
|
21
|
+
});
|
22
|
+
}
|
23
|
+
const styles = _reactNative.StyleSheet.create({
|
24
|
+
container: {
|
25
|
+
paddingVertical: 4,
|
26
|
+
paddingHorizontal: 8,
|
27
|
+
borderRadius: 4,
|
28
|
+
backgroundColor: '#888888',
|
29
|
+
borderWidth: 1,
|
30
|
+
borderColor: 'transparent'
|
31
|
+
},
|
32
|
+
labelContainer: {
|
33
|
+
backgroundColor: 'transparent'
|
34
|
+
},
|
35
|
+
activeLabelContainer: {
|
36
|
+
backgroundColor: 'transparent',
|
37
|
+
borderWidth: 1,
|
38
|
+
borderColor: '#000000'
|
39
|
+
},
|
40
|
+
activeContainer: {
|
41
|
+
backgroundColor: '#ef4444'
|
42
|
+
},
|
43
|
+
title: {
|
44
|
+
fontSize: 14,
|
45
|
+
lineHeight: 17,
|
46
|
+
fontWeight: '500',
|
47
|
+
color: '#000000'
|
48
|
+
},
|
49
|
+
icon: {
|
50
|
+
width: 17,
|
51
|
+
height: 17
|
52
|
+
}
|
53
|
+
});
|
54
|
+
//# sourceMappingURL=DebuggerHeaderItem.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"names":["_reactNative","require","_jsxRuntime","DebuggerHeaderItem","props","jsx","TouchableOpacity","onPress","activeOpacity","style","styles","container","isLabel","isActive","activeLabelContainer","labelContainer","activeContainer","undefined","children","content","Text","title","Image","source","icon","StyleSheet","create","paddingVertical","paddingHorizontal","borderRadius","backgroundColor","borderWidth","borderColor","fontSize","lineHeight","fontWeight","color","width","height"],"sourceRoot":"../../../../../src","sources":["ui/components/items/DebuggerHeaderItem.tsx"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AAAkG,IAAAC,WAAA,GAAAD,OAAA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E,EAAE;IACZC,UAAU,EAAE,EAAE;IACdC,UAAU,EAAE,KAAK;IACjBC,KAAK,EAAE;EACT,CAAC;EACDZ,IAAI,EAAE;IACJa,KAAK,EAAE,EAAE;IACTC,MAAM,EAAE;EACV;AACF,CAAC,CAAC","ignoreList":[]}
|
@@ -0,0 +1,76 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.default = NetworkPanelItem;
|
7
|
+
var _react = require("react");
|
8
|
+
var _reactNative = require("react-native");
|
9
|
+
var _reactNativeUrlPolyfill = require("react-native-url-polyfill");
|
10
|
+
var _utils = require("../../../utils.js");
|
11
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
12
|
+
function NetworkPanelItem({
|
13
|
+
name,
|
14
|
+
status,
|
15
|
+
method,
|
16
|
+
onPress
|
17
|
+
}) {
|
18
|
+
const requestName = (0, _react.useMemo)(() => {
|
19
|
+
if (!name) return '[failed]';
|
20
|
+
try {
|
21
|
+
const url = new _reactNativeUrlPolyfill.URL(name);
|
22
|
+
const suffixUrl = url.pathname + url.search;
|
23
|
+
if (suffixUrl === '/') return url.host;
|
24
|
+
return suffixUrl;
|
25
|
+
} catch (error) {
|
26
|
+
return name;
|
27
|
+
}
|
28
|
+
}, [name]);
|
29
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.TouchableOpacity, {
|
30
|
+
onPress: onPress,
|
31
|
+
style: styles.container,
|
32
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
33
|
+
style: [styles.column, styles.mainColumn],
|
34
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
|
35
|
+
numberOfLines: 1,
|
36
|
+
style: styles.text,
|
37
|
+
children: requestName
|
38
|
+
})
|
39
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
40
|
+
style: styles.column,
|
41
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
|
42
|
+
numberOfLines: 1,
|
43
|
+
style: styles.text,
|
44
|
+
children: (0, _utils.formatMethod)(method)
|
45
|
+
})
|
46
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
47
|
+
style: styles.column,
|
48
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
|
49
|
+
numberOfLines: 1,
|
50
|
+
style: styles.text,
|
51
|
+
children: (0, _utils.formatStatusCode)(status)
|
52
|
+
})
|
53
|
+
})]
|
54
|
+
});
|
55
|
+
}
|
56
|
+
const styles = _reactNative.StyleSheet.create({
|
57
|
+
container: {
|
58
|
+
flex: 1,
|
59
|
+
flexDirection: 'row'
|
60
|
+
},
|
61
|
+
mainColumn: {
|
62
|
+
flex: 7,
|
63
|
+
flexShrink: 1
|
64
|
+
},
|
65
|
+
column: {
|
66
|
+
flex: 1.5,
|
67
|
+
flexShrink: 1,
|
68
|
+
padding: 8,
|
69
|
+
paddingRight: 0
|
70
|
+
},
|
71
|
+
text: {
|
72
|
+
color: '#000000',
|
73
|
+
fontSize: 14
|
74
|
+
}
|
75
|
+
});
|
76
|
+
//# sourceMappingURL=NetworkPanelItem.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"names":["_react","require","_reactNative","_reactNativeUrlPolyfill","_utils","_jsxRuntime","NetworkPanelItem","name","status","method","onPress","requestName","useMemo","url","URL","suffixUrl","pathname","search","host","error","jsxs","TouchableOpacity","style","styles","container","children","jsx","View","column","mainColumn","Text","numberOfLines","text","formatMethod","formatStatusCode","StyleSheet","create","flex","flexDirection","flexShrink","padding","paddingRight","color","fontSize"],"sourceRoot":"../../../../../src","sources":["ui/components/items/NetworkPanelItem.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,uBAAA,GAAAF,OA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,aAAa,EAAE,CAAE;QAACT,KAAK,EAAEC,MAAM,CAACS,IAAK;QAAAP,QAAA,EACxC,IAAAQ,mBAAY,EAACxB,MAAM;MAAC,CACjB;IAAC,CACH,CAAC,eAEP,IAAAJ,WAAA,CAAAqB,GAAA,EAACxB,YAAA,CAAAyB,IAAI;MAACL,KAAK,EAAEC,MAAM,CAACK,MAAO;MAAAH,QAAA,eACzB,IAAApB,WAAA,CAAAqB,GAAA,EAACxB,YAAA,CAAA4B,IAAI;QAACC,aAAa,EAAE,CAAE;QAACT,KAAK,EAAEC,MAAM,CAACS,IAAK;QAAAP,QAAA,EACxC,IAAAS,uBAAgB,EAAC1B,MAAM;MAAC,CACrB;IAAC,CACH,CAAC;EAAA,CACS,CAAC;AAEvB;AAEA,MAAMe,MAAM,GAAGY,uBAAU,CAACC,MAAM,CAAC;EAC/BZ,SAAS,EAAE;IACTa,IAAI,EAAE,CAAC;IACPC,aAAa,EAAE;EACjB,CAAC;EACDT,UAAU,EAAE;IACVQ,IAAI,EAAE,CAAC;IACPE,UAAU,EAAE;EACd,CAAC;EACDX,MAAM,EAAE;IACNS,IAAI,EAAE,GAAG;IACTE,UAAU,EAAE,CAAC;IACbC,OAAO,EAAE,CAAC;IACVC,YAAY,EAAE;EAChB,CAAC;EACDT,IAAI,EAAE;IACJU,KAAK,EAAE,SAAS;IAChBC,QAAQ,EAAE;EACZ;AACF,CAAC,CAAC","ignoreList":[]}
|
@@ -0,0 +1,47 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.default = NetworkRequestDetailsHeaderItem;
|
7
|
+
var _reactNative = require("react-native");
|
8
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
9
|
+
function NetworkRequestDetailsHeaderItem({
|
10
|
+
visible,
|
11
|
+
name,
|
12
|
+
isSelected,
|
13
|
+
label,
|
14
|
+
onPress
|
15
|
+
}) {
|
16
|
+
if (!visible) return null;
|
17
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.TouchableOpacity, {
|
18
|
+
activeOpacity: 0.8,
|
19
|
+
onPress: onPress,
|
20
|
+
style: [styles.item, isSelected && styles.activeItem],
|
21
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
|
22
|
+
style: styles.itemText,
|
23
|
+
children: label
|
24
|
+
})
|
25
|
+
}, name);
|
26
|
+
}
|
27
|
+
const styles = _reactNative.StyleSheet.create({
|
28
|
+
item: {
|
29
|
+
flex: 1,
|
30
|
+
paddingHorizontal: 8,
|
31
|
+
paddingVertical: 4,
|
32
|
+
borderRadius: 4,
|
33
|
+
backgroundColor: 'transparent',
|
34
|
+
borderWidth: 1,
|
35
|
+
borderColor: 'transparent'
|
36
|
+
},
|
37
|
+
activeItem: {
|
38
|
+
backgroundColor: 'transparent',
|
39
|
+
borderWidth: 1,
|
40
|
+
borderColor: '#000000'
|
41
|
+
},
|
42
|
+
itemText: {
|
43
|
+
fontSize: 14,
|
44
|
+
color: '#000000'
|
45
|
+
}
|
46
|
+
});
|
47
|
+
//# sourceMappingURL=NetworkRequestDetailsHeaderItem.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"names":["_reactNative","require","_jsxRuntime","NetworkRequestDetailsHeaderItem","visible","name","isSelected","label","onPress","jsx","TouchableOpacity","activeOpacity","style","styles","item","activeItem","children","Text","itemText","StyleSheet","create","flex","paddingHorizontal","paddingVertical","borderRadius","backgroundColor","borderWidth","borderColor","fontSize","color"],"sourceRoot":"../../../../../src","sources":["ui/components/items/NetworkRequestDetailsHeaderItem.tsx"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AAAkE,IAAAC,WAAA,GAAAD,OAAA;AAWnD,SAASE,+BAA+BA,CAAC;EACtDC,OAAO;EACPC,IAAI;EACJC,UAAU;EACVC,KAAK;EACLC;AACoC,CAAC,EAAE;EACvC,IAAI,CAACJ,OAAO,EAAE,OAAO,IAAI;EAEzB,oBACE,IAAAF,WAAA,CAAAO,GAAA,EAACT,YAAA,CAAAU,gBAAgB;IAEfC,aAAa,EAAE,GAAI;IACnBH,OAAO,EAAEA,OAAQ;IACjBI,KAAK,EAAE,CAACC,MAAM,CAACC,IAAI,EAAER,UAAU,IAAIO,MAAM,CAACE,UAAU,CAAE;IAAAC,QAAA,eAEtD,IAAAd,WAAA,CAAAO,GAAA,EAACT,YAAA,CAAAiB,IAAI;MAACL,KAAK,EAAEC,MAAM,CAACK,QAAS;MAAAF,QAAA,EAAET;IAAK,CAAO;EAAC,GALvCF,IAMW,CAAC;AAEvB;AAEA,MAAMQ,MAAM,GAAGM,uBAAU,CAACC,MAAM,CAAC;EAC/BN,IAAI,EAAE;IACJO,IAAI,EAAE,CAAC;IACPC,iBAAiB,EAAE,CAAC;IACpBC,eAAe,EAAE,CAAC;IAClBC,YAAY,EAAE,CAAC;IACfC,eAAe,EAAE,aAAa;IAC9BC,WAAW,EAAE,CAAC;IACdC,WAAW,EAAE;EACf,CAAC;EACDZ,UAAU,EAAE;IACVU,eAAe,EAAE,aAAa;IAC9BC,WAAW,EAAE,CAAC;IACdC,WAAW,EAAE;EACf,CAAC;EACDT,QAAQ,EAAE;IACRU,QAAQ,EAAE,EAAE;IACZC,KAAK,EAAE;EACT;AACF,CAAC,CAAC","ignoreList":[]}
|
@@ -0,0 +1,41 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.default = NetworkRequestDetailsItem;
|
7
|
+
var _reactNative = require("react-native");
|
8
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
9
|
+
function NetworkRequestDetailsItem({
|
10
|
+
label,
|
11
|
+
content,
|
12
|
+
selectable
|
13
|
+
}) {
|
14
|
+
if (label) {
|
15
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.Text, {
|
16
|
+
style: styles.text,
|
17
|
+
selectable: selectable,
|
18
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.Text, {
|
19
|
+
style: styles.label,
|
20
|
+
children: [label, ': ']
|
21
|
+
}), content]
|
22
|
+
});
|
23
|
+
}
|
24
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Text, {
|
25
|
+
style: styles.text,
|
26
|
+
selectable: selectable,
|
27
|
+
children: content
|
28
|
+
});
|
29
|
+
}
|
30
|
+
const styles = _reactNative.StyleSheet.create({
|
31
|
+
text: {
|
32
|
+
fontSize: 14,
|
33
|
+
color: '#000000'
|
34
|
+
},
|
35
|
+
label: {
|
36
|
+
fontSize: 14,
|
37
|
+
fontWeight: 'bold',
|
38
|
+
color: '#000000'
|
39
|
+
}
|
40
|
+
});
|
41
|
+
//# sourceMappingURL=NetworkRequestDetailsItem.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"names":["_reactNative","require","_jsxRuntime","NetworkRequestDetailsItem","label","content","selectable","jsxs","Text","style","styles","text","children","jsx","StyleSheet","create","fontSize","color","fontWeight"],"sourceRoot":"../../../../../src","sources":["ui/components/items/NetworkRequestDetailsItem.tsx"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AAAgD,IAAAC,WAAA,GAAAD,OAAA;AAQjC,SAASE,yBAAyBA,CAAC;EAChDC,KAAK;EACLC,OAAO;EACPC;AAC8B,CAAC,EAAE;EACjC,IAAIF,KAAK,EAAE;IACT,oBACE,IAAAF,WAAA,CAAAK,IAAA,EAACP,YAAA,CAAAQ,IAAI;MAACC,KAAK,EAAEC,MAAM,CAACC,IAAK;MAACL,UAAU,EAAEA,UAAW;MAAAM,QAAA,gBAC/C,IAAAV,WAAA,CAAAK,IAAA,EAACP,YAAA,CAAAQ,IAAI;QAACC,KAAK,EAAEC,MAAM,CAACN,KAAM;QAAAQ,QAAA,GACvBR,KAAK,EACL,IAAI;MAAA,CACD,CAAC,EACNC,OAAO;IAAA,CACJ,CAAC;EAEX;EAEA,oBACE,IAAAH,WAAA,CAAAW,GAAA,EAACb,YAAA,CAAAQ,IAAI;IAACC,KAAK,EAAEC,MAAM,CAACC,IAAK;IAACL,UAAU,EAAEA,UAAW;IAAAM,QAAA,EAC9CP;EAAO,CACJ,CAAC;AAEX;AAEA,MAAMK,MAAM,GAAGI,uBAAU,CAACC,MAAM,CAAC;EAC/BJ,IAAI,EAAE;IACJK,QAAQ,EAAE,EAAE;IACZC,KAAK,EAAE;EACT,CAAC;EACDb,KAAK,EAAE;IACLY,QAAQ,EAAE,EAAE;IACZE,UAAU,EAAE,MAAM;IAClBD,KAAK,EAAE;EACT;AACF,CAAC,CAAC","ignoreList":[]}
|
@@ -0,0 +1,58 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.default = ConsolePanel;
|
7
|
+
var _react = require("react");
|
8
|
+
var _reactNative = require("react-native");
|
9
|
+
var _index = require("../../../contexts/index.js");
|
10
|
+
var _index2 = require("../../../hooks/index.js");
|
11
|
+
var _ConsolePanelItem = _interopRequireDefault(require("../items/ConsolePanelItem.js"));
|
12
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
13
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
14
|
+
const Separator = () => /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
15
|
+
style: styles.divider
|
16
|
+
});
|
17
|
+
function ConsolePanel() {
|
18
|
+
const {
|
19
|
+
logInterceptor: {
|
20
|
+
logMessages
|
21
|
+
},
|
22
|
+
setPanelSelected,
|
23
|
+
detailsData
|
24
|
+
} = (0, _react.useContext)(_index.MainContext);
|
25
|
+
const listRef = (0, _index2.useScrollToBottom)(logMessages.length);
|
26
|
+
const renderItem = (0, _react.useCallback)(({
|
27
|
+
item
|
28
|
+
}) => {
|
29
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_ConsolePanelItem.default, {
|
30
|
+
...item,
|
31
|
+
onPress: () => {
|
32
|
+
detailsData.current = {
|
33
|
+
console: item
|
34
|
+
};
|
35
|
+
setPanelSelected(null);
|
36
|
+
}
|
37
|
+
});
|
38
|
+
}, [detailsData, setPanelSelected]);
|
39
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.FlatList, {
|
40
|
+
ref: listRef,
|
41
|
+
style: styles.container,
|
42
|
+
data: logMessages,
|
43
|
+
renderItem: renderItem,
|
44
|
+
ItemSeparatorComponent: Separator,
|
45
|
+
keyExtractor: (_, index) => index.toString()
|
46
|
+
});
|
47
|
+
}
|
48
|
+
const styles = _reactNative.StyleSheet.create({
|
49
|
+
container: {
|
50
|
+
flex: 1,
|
51
|
+
paddingHorizontal: 8
|
52
|
+
},
|
53
|
+
divider: {
|
54
|
+
height: 1,
|
55
|
+
backgroundColor: '#888888'
|
56
|
+
}
|
57
|
+
});
|
58
|
+
//# sourceMappingURL=ConsolePanel.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"names":["_react","require","_reactNative","_index","_index2","_ConsolePanelItem","_interopRequireDefault","_jsxRuntime","e","__esModule","default","Separator","jsx","View","style","styles","divider","ConsolePanel","logInterceptor","logMessages","setPanelSelected","detailsData","useContext","MainContext","listRef","useScrollToBottom","length","renderItem","useCallback","item","onPress","current","console","FlatList","ref","container","data","ItemSeparatorComponent","keyExtractor","_","index","toString","StyleSheet","create","flex","paddingHorizontal","height","backgroundColor"],"sourceRoot":"../../../../../src","sources":["ui/components/panels/ConsolePanel.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,MAAA,GAAAF,OAAA;AACA,IAAAG,OAAA,GAAAH,OAAA;AAEA,IAAAI,iBAAA,GAAAC,sBAAA,CAAAL,OAAA;AAAyD,IAAAM,WAAA,GAAAN,OAAA;AAAA,SAAAK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IACTS,IAAI,EAAE,CAAC;IACPC,iBAAiB,EAAE;EACrB,CAAC;EACD7B,OAAO,EAAE;IACP8B,MAAM,EAAE,CAAC;IACTC,eAAe,EAAE;EACnB;AACF,CAAC,CAAC","ignoreList":[]}
|
@@ -0,0 +1,66 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.default = NetworkPanel;
|
7
|
+
var _react = require("react");
|
8
|
+
var _reactNative = require("react-native");
|
9
|
+
var _index = require("../../../contexts/index.js");
|
10
|
+
var _index2 = require("../../../hooks/index.js");
|
11
|
+
var _index3 = require("../../../types/index.js");
|
12
|
+
var _NetworkPanelHeader = _interopRequireDefault(require("../headers/NetworkPanelHeader.js"));
|
13
|
+
var _NetworkPanelItem = _interopRequireDefault(require("../items/NetworkPanelItem.js"));
|
14
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
15
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
16
|
+
const Separator = () => /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
|
17
|
+
style: styles.divider
|
18
|
+
});
|
19
|
+
function NetworkPanel() {
|
20
|
+
const {
|
21
|
+
networkInterceptor: {
|
22
|
+
networkRequests
|
23
|
+
},
|
24
|
+
setPanelSelected,
|
25
|
+
detailsData
|
26
|
+
} = (0, _react.useContext)(_index.MainContext);
|
27
|
+
const listRef = (0, _index2.useScrollToBottom)(networkRequests.size);
|
28
|
+
const renderItem = (0, _react.useCallback)(({
|
29
|
+
item: [_, item]
|
30
|
+
}) => {
|
31
|
+
const isWebSocket = item.type === _index3.NetworkType.WS;
|
32
|
+
const onPress = () => {
|
33
|
+
detailsData.current = {
|
34
|
+
network: item
|
35
|
+
};
|
36
|
+
setPanelSelected(null);
|
37
|
+
};
|
38
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_NetworkPanelItem.default, {
|
39
|
+
name: isWebSocket ? item.uri : item.url,
|
40
|
+
method: isWebSocket ? undefined : item.method,
|
41
|
+
status: item.status,
|
42
|
+
onPress: onPress
|
43
|
+
});
|
44
|
+
}, [detailsData, setPanelSelected]);
|
45
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.FlatList, {
|
46
|
+
ref: listRef,
|
47
|
+
data: Array.from(networkRequests),
|
48
|
+
style: styles.container,
|
49
|
+
ListHeaderComponent: _NetworkPanelHeader.default,
|
50
|
+
stickyHeaderIndices: [0],
|
51
|
+
ItemSeparatorComponent: Separator,
|
52
|
+
keyExtractor: ([key]) => key,
|
53
|
+
renderItem: renderItem
|
54
|
+
});
|
55
|
+
}
|
56
|
+
const styles = _reactNative.StyleSheet.create({
|
57
|
+
container: {
|
58
|
+
flex: 1,
|
59
|
+
paddingHorizontal: 8
|
60
|
+
},
|
61
|
+
divider: {
|
62
|
+
height: 1,
|
63
|
+
backgroundColor: '#888888'
|
64
|
+
}
|
65
|
+
});
|
66
|
+
//# sourceMappingURL=NetworkPanel.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"names":["_react","require","_reactNative","_index","_index2","_index3","_NetworkPanelHeader","_interopRequireDefault","_NetworkPanelItem","_jsxRuntime","e","__esModule","default","Separator","jsx","View","style","styles","divider","NetworkPanel","networkInterceptor","networkRequests","setPanelSelected","detailsData","useContext","MainContext","listRef","useScrollToBottom","size","renderItem","useCallback","item","_","isWebSocket","type","NetworkType","WS","onPress","current","network","name","uri","url","method","undefined","status","FlatList","ref","data","Array","from","container","ListHeaderComponent","NetworkPanelHeader","stickyHeaderIndices","ItemSeparatorComponent","keyExtractor","key","StyleSheet","create","flex","paddingHorizontal","height","backgroundColor"],"sourceRoot":"../../../../../src","sources":["ui/components/panels/NetworkPanel.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,MAAA,GAAAF,OAAA;AACA,IAAAG,O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ACc,MAAO;MACpBR,OAAO,EAAEA;IAAQ,CAClB,CAAC;EAEN,CAAC,EACD,CAACd,WAAW,EAAED,gBAAgB,CAChC,CAAC;EAED,oBACE,IAAAb,WAAA,CAAAK,GAAA,EAACZ,YAAA,CAAA4C,QAAQ;IACPC,GAAG,EAAErB,OAAQ;IACbsB,IAAI,EAAEC,KAAK,CAACC,IAAI,CAAC7B,eAAe,CAAE;IAClCL,KAAK,EAAEC,MAAM,CAACkC,SAAU;IACxBC,mBAAmB,EAAEC,2BAAmB;IACxCC,mBAAmB,EAAE,CAAC,CAAC,CAAE;IACzBC,sBAAsB,EAAE1C,SAAU;IAClC2C,YAAY,EAAEA,CAAC,CAACC,GAAG,CAAC,KAAKA,GAAI;IAC7B5B,UAAU,EAAEA;EAAW,CACxB,CAAC;AAEN;AAEA,MAAMZ,MAAM,GAAGyC,uBAAU,CAACC,MAAM,CAAC;EAC/BR,SAAS,EAAE;IACTS,IAAI,EAAE,CAAC;IACPC,iBAAiB,EAAE;EACrB,CAAC;EACD3C,OAAO,EAAE;IACP4C,MAAM,EAAE,CAAC;IACTC,eAAe,EAAE;EACnB;AACF,CAAC,CAAC","ignoreList":[]}
|
@@ -0,0 +1,46 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.limitChar = exports.keyValueToString = exports.getHttpInterceptorId = exports.formatStatusCode = exports.formatMethod = exports.formatLogMessage = exports.convertToCurl = void 0;
|
7
|
+
const limitChar = (value, limit = 5000) => {
|
8
|
+
const stringValue = typeof value === 'string' ? value : JSON.stringify(value ?? '');
|
9
|
+
return stringValue.length > limit ? `${stringValue.slice(0, limit)}\n---LIMITED TO ${limit} CHARACTERS---` : stringValue;
|
10
|
+
};
|
11
|
+
exports.limitChar = limitChar;
|
12
|
+
const getHttpInterceptorId = () => {
|
13
|
+
const timestamp = Date.now().toString(36);
|
14
|
+
const randomNum = Math.random().toString(36).substring(2, 10);
|
15
|
+
return timestamp + randomNum;
|
16
|
+
};
|
17
|
+
exports.getHttpInterceptorId = getHttpInterceptorId;
|
18
|
+
const keyValueToString = (key, value) => `${key}: ${limitChar(value)}\n`;
|
19
|
+
exports.keyValueToString = keyValueToString;
|
20
|
+
const formatMethod = method => method ?? 'GET';
|
21
|
+
exports.formatMethod = formatMethod;
|
22
|
+
const formatStatusCode = statusCode => `${statusCode ?? 'pending'}`;
|
23
|
+
exports.formatStatusCode = formatStatusCode;
|
24
|
+
const formatLogMessage = (type, values) => {
|
25
|
+
const message = values.reduce((pre, cur, index, array) => {
|
26
|
+
const isLastItem = index === array.length - 1;
|
27
|
+
return pre + limitChar(cur) + (isLastItem ? '' : ', ');
|
28
|
+
}, '');
|
29
|
+
return `${type.toUpperCase()}: ${message}`;
|
30
|
+
};
|
31
|
+
exports.formatLogMessage = formatLogMessage;
|
32
|
+
const convertToCurl = (method, url, headers, body) => {
|
33
|
+
let curlCommand = `curl -X ${method.toUpperCase()} "${url}"`;
|
34
|
+
if (headers) {
|
35
|
+
for (const [key, value] of Object.entries(headers)) {
|
36
|
+
curlCommand += ` -H "${key}: ${value}"`;
|
37
|
+
}
|
38
|
+
}
|
39
|
+
if (body) {
|
40
|
+
const bodyString = typeof body === 'string' ? body : JSON.stringify(body);
|
41
|
+
curlCommand += ` -d '${bodyString}'`;
|
42
|
+
}
|
43
|
+
return curlCommand;
|
44
|
+
};
|
45
|
+
exports.convertToCurl = convertToCurl;
|
46
|
+
//# sourceMappingURL=utils.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"names":["limitChar","value","limit","stringValue","JSON","stringify","length","slice","exports","getHttpInterceptorId","timestamp","Date","now","toString","randomNum","Math","random","substring","keyValueToString","key","formatMethod","method","formatStatusCode","statusCode","formatLogMessage","type","values","message","reduce","pre","cur","index","array","isLastItem","toUpperCase","convertToCurl","url","headers","body","curlCommand","Object","entries","bodyString"],"sourceRoot":"../../src","sources":["utils.ts"],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GAAG,EAAEC,GAAG,EAAEC,KAAK,EAAEC,KAAK,KAAK;IAChE,MAAMC,UAAU,GAAGF,KAAK,KAAKC,KAAK,CAAC1B,MAAM,GAAG,CAAC;IAE7C,OAAOuB,GAAG,GAAG7B,SAAS,CAAC8B,GAAG,CAAC,IAAIG,UAAU,GAAG,EAAE,GAAG,IAAI,CAAC;EACxD,CAAC,EAAE,EAAE,CAAC;EAEN,OAAO,GAAGR,IAAI,CAACS,WAAW,CAAC,CAAC,KAAKP,OAAO,EAAE;AAC5C,CAAC;AAACnB,OAAA,CAAAgB,gBAAA,GAAAA,gBAAA;AAEK,MAAMW,aAAa,GAAGA,CAC3Bd,MAA6B,EAC7Be,GAAuB,EACvBC,OAAsC,EACtCC,IAAyB,KACtB;EACH,IAAIC,WAAW,GAAG,WAAWlB,MAAM,CAACa,WAAW,CAAC,CAAC,KAAKE,GAAG,GAAG;EAE5D,IAAIC,OAAO,EAAE;IACX,KAAK,MAAM,CAAClB,GAAG,EAAElB,KAAK,CAAC,IAAIuC,MAAM,CAACC,OAAO,CAACJ,OAAO,CAAC,EAAE;MAClDE,WAAW,IAAI,QAAQpB,GAAG,KAAKlB,KAAK,GAAG;IACzC;EACF;EAEA,IAAIqC,IAAI,EAAE;IACR,MAAMI,UAAU,GAAG,OAAOJ,IAAI,KAAK,QAAQ,GAAGA,IAAI,GAAGlC,IAAI,CAACC,SAAS,CAACiC,IAAI,CAAC;IACzEC,WAAW,IAAI,QAAQG,UAAU,GAAG;EACtC;EAEA,OAAOH,WAAW;AACpB,CAAC;AAAC/B,OAAA,CAAA2B,aAAA,GAAAA,aAAA","ignoreList":[]}
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"names":["NETWORK_REQUEST_HEADER"],"sourceRoot":"../../src","sources":["constants.ts"],"mappings":";;AAAA,OAAO,MAAMA,sBAAsB,GAAG,sBAAsB","ignoreList":[]}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"names":["createContext","MainContext"],"sourceRoot":"../../../src","sources":["contexts/MainContext.ts"],"mappings":";;AAAA,SAASA,aAAa,QAA+B,OAAO;AA+B5D,MAAMC,WAAW,gBAAGD,aAAa,CAA0B,IAAI,CAAC;AAEhE,eAAeC,WAAW","ignoreList":[]}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"names":["default","MainContext"],"sourceRoot":"../../../src","sources":["contexts/index.ts"],"mappings":";;AAAA,SAASA,OAAO,IAAIC,WAAW,QAAQ,kBAAe","ignoreList":[]}
|