esoftplay 0.0.119-b → 0.0.119-e
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/bin/router.js +77 -49
- package/global.ts +0 -2
- package/import_migrator.mjs +44 -0
- package/{modules/lib → libs}/worker.tsx +63 -75
- package/modules/lib/carrousel.tsx +4 -1
- package/modules/lib/carrousel_snap.tsx +3 -1
- package/modules/lib/collaps.tsx +2 -1
- package/modules/lib/{component.ts → component.tsx} +0 -0
- package/modules/lib/crypt.js +3 -1
- package/modules/lib/curl.ts +9 -1
- package/modules/lib/datepicker.tsx +6 -1
- package/modules/lib/dialog.tsx +8 -1
- package/modules/lib/direct_image.tsx +3 -1
- package/modules/lib/direct_text.tsx +3 -1
- package/modules/lib/document.ts +4 -1
- package/modules/lib/effect.tsx +3 -1
- package/modules/lib/gallery.tsx +5 -1
- package/modules/lib/icon.tsx +27 -22
- package/modules/lib/image.tsx +7 -1
- package/modules/lib/image_crop.tsx +8 -1
- package/modules/lib/image_multi.tsx +11 -2
- package/modules/lib/image_shadow.tsx +2 -1
- package/modules/lib/infinite.tsx +12 -2
- package/modules/lib/input.tsx +6 -1
- package/modules/lib/input_base.tsx +3 -1
- package/modules/lib/lazy.tsx +1 -1
- package/modules/lib/list.tsx +6 -2
- package/modules/lib/loading.tsx +3 -1
- package/modules/lib/locale.ts +2 -1
- package/modules/lib/navigation.ts +8 -2
- package/modules/lib/net_status.tsx +2 -2
- package/modules/lib/notification.ts +9 -1
- package/modules/lib/notify.ts +3 -1
- package/modules/lib/picture.tsx +5 -2
- package/modules/lib/progress.tsx +5 -1
- package/modules/lib/roll.tsx +6 -1
- package/modules/lib/scroll.tsx +2 -1
- package/modules/lib/scrollpicker.tsx +2 -1
- package/modules/lib/skeleton.tsx +3 -2
- package/modules/lib/slidingup.tsx +5 -1
- package/modules/lib/sociallogin.tsx +4 -2
- package/modules/lib/tabs.tsx +4 -1
- package/modules/lib/textstyle.tsx +2 -1
- package/modules/lib/theme.tsx +3 -2
- package/modules/lib/timepicker.tsx +3 -1
- package/modules/lib/toast.tsx +2 -1
- package/modules/lib/updater.tsx +8 -5
- package/modules/lib/utils.ts +2 -1
- package/modules/lib/version.tsx +9 -1
- package/modules/lib/video.tsx +3 -1
- package/modules/lib/webview.tsx +2 -1
- package/modules/lib/workloop.tsx +4 -1
- package/modules/use/connect.ts +2 -1
- package/modules/use/curl.ts +3 -1
- package/modules/use/deeplink.ts +4 -1
- package/modules/use/form.ts +1 -1
- package/modules/use/form_persist.ts +1 -2
- package/modules/user/class.ts +6 -2
- package/modules/user/data.ts +1 -2
- package/modules/user/hook.tsx +2 -1
- package/modules/user/index.tsx +20 -8
- package/modules/user/loading.tsx +1 -1
- package/modules/user/login.tsx +8 -5
- package/modules/user/notifbadge.tsx +3 -2
- package/modules/user/notification.tsx +8 -1
- package/modules/user/notification_item.tsx +3 -1
- package/modules/user/routes.ts +1 -1
- package/package.json +1 -1
- package/modules/lib/workview.tsx +0 -33
package/modules/lib/workloop.tsx
CHANGED
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
// noPage
|
|
2
|
+
import { esp } from 'esoftplay';
|
|
3
|
+
import { LibComponent } from 'esoftplay/cache/lib/component.import';
|
|
4
|
+
import { LibNotification } from 'esoftplay/cache/lib/notification.import';
|
|
5
|
+
import { UserClass } from 'esoftplay/cache/user/class.import';
|
|
2
6
|
|
|
3
|
-
import { esp, LibComponent, LibNotification, UserClass } from 'esoftplay';
|
|
4
7
|
import React from 'react';
|
|
5
8
|
import { InteractionManager, View } from 'react-native';
|
|
6
9
|
import { WebView } from 'react-native-webview';
|
package/modules/use/connect.ts
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
// useLibs
|
|
2
2
|
// noPage
|
|
3
|
+
import { } from 'esoftplay';
|
|
4
|
+
import { UseDataProperty } from 'esoftplay/cache/use/data.import';
|
|
3
5
|
|
|
4
|
-
import { UseDataProperty } from 'esoftplay';
|
|
5
6
|
import { useEffect, useState } from 'react';
|
|
6
7
|
const isEqual = require('react-fast-compare');
|
|
7
8
|
|
package/modules/use/curl.ts
CHANGED
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
// useLibs
|
|
2
2
|
// noPage
|
|
3
|
+
import { useSafeState } from 'esoftplay';
|
|
4
|
+
import { LibCurl } from 'esoftplay/cache/lib/curl.import';
|
|
5
|
+
import { LibProgress } from 'esoftplay/cache/lib/progress.import';
|
|
3
6
|
|
|
4
|
-
import { LibCurl, LibProgress, useSafeState } from 'esoftplay';
|
|
5
7
|
|
|
6
8
|
export default function m(initialWithLoading?: boolean, withProgressText?: string): [(uri: string, post: any, onDone: (res: any, msg: string) => void, debug?: 0 | 1) => void, boolean, string] {
|
|
7
9
|
const [loading, setLoading] = useSafeState(initialWithLoading)
|
package/modules/use/deeplink.ts
CHANGED
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
// useLibs
|
|
2
2
|
// noPage
|
|
3
|
+
import { esp } from 'esoftplay';
|
|
4
|
+
import { LibCurl } from 'esoftplay/cache/lib/curl.import';
|
|
5
|
+
import { LibNavigation } from 'esoftplay/cache/lib/navigation.import';
|
|
6
|
+
import { LibUtils } from 'esoftplay/cache/lib/utils.import';
|
|
3
7
|
|
|
4
|
-
import { esp, LibCurl, LibNavigation, LibUtils, _global } from 'esoftplay';
|
|
5
8
|
import { useCallback, useEffect } from 'react';
|
|
6
9
|
import { Alert, Linking } from 'react-native';
|
|
7
10
|
|
package/modules/use/form.ts
CHANGED
package/modules/user/class.ts
CHANGED
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
// noPage
|
|
2
|
+
import { esp, useGlobalReturn } from 'esoftplay';
|
|
3
|
+
import { LibCrypt } from 'esoftplay/cache/lib/crypt.import';
|
|
4
|
+
import { LibCurl } from 'esoftplay/cache/lib/curl.import';
|
|
5
|
+
import { LibNotification } from 'esoftplay/cache/lib/notification.import';
|
|
6
|
+
import { UserClass } from 'esoftplay/cache/user/class.import';
|
|
7
|
+
import { UserData } from 'esoftplay/cache/user/data.import';
|
|
2
8
|
|
|
3
|
-
import AsyncStorage from '@react-native-async-storage/async-storage';
|
|
4
|
-
import { esp, LibCrypt, LibCurl, LibNotification, useGlobalReturn, UserClass, UserData } from 'esoftplay';
|
|
5
9
|
import Constants from 'expo-constants';
|
|
6
10
|
import * as Notifications from 'expo-notifications';
|
|
7
11
|
import { Platform } from 'react-native';
|
package/modules/user/data.ts
CHANGED
package/modules/user/hook.tsx
CHANGED
package/modules/user/index.tsx
CHANGED
|
@@ -1,7 +1,22 @@
|
|
|
1
1
|
// withHooks
|
|
2
2
|
// noPage
|
|
3
|
-
|
|
4
|
-
import {
|
|
3
|
+
import { esp, useSafeState } from 'esoftplay';
|
|
4
|
+
import { LibDialog } from 'esoftplay/cache/lib/dialog.import';
|
|
5
|
+
import { LibImage } from 'esoftplay/cache/lib/image.import';
|
|
6
|
+
import { LibNet_status } from 'esoftplay/cache/lib/net_status.import';
|
|
7
|
+
import { LibProgress } from 'esoftplay/cache/lib/progress.import';
|
|
8
|
+
import { LibStyle } from 'esoftplay/cache/lib/style.import';
|
|
9
|
+
import { LibToast } from 'esoftplay/cache/lib/toast.import';
|
|
10
|
+
import { LibUpdaterProperty } from 'esoftplay/cache/lib/updater.import';
|
|
11
|
+
import { LibVersion } from 'esoftplay/cache/lib/version.import';
|
|
12
|
+
import { LibWorkloop } from 'esoftplay/cache/lib/workloop.import';
|
|
13
|
+
import { UseDeeplink } from 'esoftplay/cache/use/deeplink.import';
|
|
14
|
+
import { UserClass } from 'esoftplay/cache/user/class.import';
|
|
15
|
+
import { UserHook } from 'esoftplay/cache/user/hook.import';
|
|
16
|
+
import { UserLoading } from 'esoftplay/cache/user/loading.import';
|
|
17
|
+
import { UserRoutes } from 'esoftplay/cache/user/routes.import';
|
|
18
|
+
|
|
19
|
+
import Worker from 'esoftplay/libs/worker';
|
|
5
20
|
import * as Font from "expo-font";
|
|
6
21
|
import React, { useEffect, useLayoutEffect } from "react";
|
|
7
22
|
import { Platform, View } from "react-native";
|
|
@@ -31,7 +46,7 @@ function setFonts(): Promise<void> {
|
|
|
31
46
|
|
|
32
47
|
|
|
33
48
|
function isWorkerReady(onReady: () => void): void {
|
|
34
|
-
if (_global.
|
|
49
|
+
if (_global.WorkerReady < 1) {
|
|
35
50
|
setTimeout(() => isWorkerReady(onReady), 10)
|
|
36
51
|
} else {
|
|
37
52
|
onReady()
|
|
@@ -103,9 +118,7 @@ export default function m(props: UserIndexProps): any {
|
|
|
103
118
|
|
|
104
119
|
}
|
|
105
120
|
}
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
LibUpdaterProperty.check((isNew) => { })
|
|
121
|
+
LibUpdaterProperty.check()
|
|
109
122
|
}, [])
|
|
110
123
|
|
|
111
124
|
useEffect(() => {
|
|
@@ -119,8 +132,7 @@ export default function m(props: UserIndexProps): any {
|
|
|
119
132
|
return (
|
|
120
133
|
<GestureHandlerRootView style={{ flex: 1 }}>
|
|
121
134
|
<View style={{ flex: 1 }}>
|
|
122
|
-
<
|
|
123
|
-
<LibWorkview />
|
|
135
|
+
<Worker.View />
|
|
124
136
|
{
|
|
125
137
|
loading ?
|
|
126
138
|
<UserLoading />
|
package/modules/user/loading.tsx
CHANGED
package/modules/user/login.tsx
CHANGED
|
@@ -1,8 +1,11 @@
|
|
|
1
|
-
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
} from
|
|
1
|
+
|
|
2
|
+
import { } from 'esoftplay';
|
|
3
|
+
import { LibComponent } from 'esoftplay/cache/lib/component.import';
|
|
4
|
+
import { LibCrypt } from 'esoftplay/cache/lib/crypt.import';
|
|
5
|
+
import { LibCurl } from 'esoftplay/cache/lib/curl.import';
|
|
6
|
+
import { LibStyle } from 'esoftplay/cache/lib/style.import';
|
|
7
|
+
import { UserClass } from 'esoftplay/cache/user/class.import';
|
|
8
|
+
|
|
6
9
|
import { StatusBar } from 'expo-status-bar';
|
|
7
10
|
import React from "react";
|
|
8
11
|
import { Image, KeyboardAvoidingView, Pressable, ScrollView, Text, TextInput, TouchableOpacity, View } from "react-native";
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
// noPage
|
|
2
|
+
import { } from 'esoftplay';
|
|
3
|
+
import { LibComponent } from 'esoftplay/cache/lib/component.import';
|
|
4
|
+
import { LibStyle } from 'esoftplay/cache/lib/style.import';
|
|
2
5
|
|
|
3
|
-
|
|
4
|
-
import { LibComponent, LibStyle } from "esoftplay";
|
|
5
6
|
import { Text, TouchableOpacity, View } from "react-native";
|
|
6
7
|
|
|
7
8
|
export interface UserNotifbadgeProps {
|
|
@@ -1,6 +1,13 @@
|
|
|
1
1
|
//
|
|
2
|
+
import { useGlobalReturn, useGlobalState } from 'esoftplay';
|
|
3
|
+
import { LibComponent } from 'esoftplay/cache/lib/component.import';
|
|
4
|
+
import { LibIcon } from 'esoftplay/cache/lib/icon.import';
|
|
5
|
+
import { LibList } from 'esoftplay/cache/lib/list.import';
|
|
6
|
+
import { LibNotification } from 'esoftplay/cache/lib/notification.import';
|
|
7
|
+
import { LibStatusbar } from 'esoftplay/cache/lib/statusbar.import';
|
|
8
|
+
import { LibStyle } from 'esoftplay/cache/lib/style.import';
|
|
9
|
+
import { UserNotification_item } from 'esoftplay/cache/user/notification_item.import';
|
|
2
10
|
|
|
3
|
-
import { LibComponent, LibIcon, LibList, LibNotification, LibStatusbar, LibStyle, useGlobalReturn, useGlobalState, UserNotification_item } from "esoftplay";
|
|
4
11
|
import { Pressable, Text, TouchableOpacity, View } from "react-native";
|
|
5
12
|
//@ts-ignore
|
|
6
13
|
export interface UserNotificationProps {
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
// noPage
|
|
2
|
+
import { } from 'esoftplay';
|
|
3
|
+
import { LibStyle } from 'esoftplay/cache/lib/style.import';
|
|
4
|
+
import { LibUtils } from 'esoftplay/cache/lib/utils.import';
|
|
2
5
|
|
|
3
|
-
import { LibStyle, LibUtils } from 'esoftplay';
|
|
4
6
|
import { Text, View } from 'react-native';
|
|
5
7
|
|
|
6
8
|
|
package/modules/user/routes.ts
CHANGED
package/package.json
CHANGED
package/modules/lib/workview.tsx
DELETED
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
// withHooks
|
|
2
|
-
// noPage
|
|
3
|
-
|
|
4
|
-
import { esp, LibWorker, _global } from 'esoftplay';
|
|
5
|
-
import React from 'react';
|
|
6
|
-
import { Platform, View } from 'react-native';
|
|
7
|
-
import WebView from 'react-native-webview';
|
|
8
|
-
|
|
9
|
-
export interface LibWorkviewArgs {
|
|
10
|
-
|
|
11
|
-
}
|
|
12
|
-
export interface LibWorkviewProps {
|
|
13
|
-
|
|
14
|
-
}
|
|
15
|
-
export default function m(props: LibWorkviewProps): any {
|
|
16
|
-
if (Platform.OS == 'android')
|
|
17
|
-
if (Platform.Version <= 22) {
|
|
18
|
-
return null
|
|
19
|
-
}
|
|
20
|
-
return (
|
|
21
|
-
<View style={{ height: 0, width: 0 }} >
|
|
22
|
-
<WebView
|
|
23
|
-
ref={_global.LibWorkerBase}
|
|
24
|
-
style={{ width: 0, height: 0 }}
|
|
25
|
-
javaScriptEnabled={true}
|
|
26
|
-
injectedJavaScript={`\nwindow.ReactNativeWebView.postMessage("BaseWorkerIsReady")\n` + _global.injectedJavaScripts.join('\n') + '\ntrue;'}
|
|
27
|
-
originWhitelist={["*"]}
|
|
28
|
-
source={{ uri: esp.config("protocol") + "://" + esp.config("domain") + esp.config("uri") + "dummyPageToBypassCORS" }}
|
|
29
|
-
onMessage={LibWorker.onMessage('BaseWorkerIsReady')}
|
|
30
|
-
/>
|
|
31
|
-
</View>
|
|
32
|
-
)
|
|
33
|
-
}
|