@fto-consult/expo-ui 6.67.12 → 6.67.13
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/metro.config.js
CHANGED
@@ -52,8 +52,15 @@ module.exports = function(opts){
|
|
52
52
|
'jsx', 'js','tsx',
|
53
53
|
]
|
54
54
|
|
55
|
+
// 3. Force Metro to resolve (sub)dependencies only from the `nodeModulesPaths`
|
56
|
+
config.resolver.disableHierarchicalLookup = true;
|
57
|
+
|
55
58
|
// Remove all console logs in production...
|
56
59
|
config.transformer.minifierConfig.compress.drop_console = false;
|
60
|
+
|
61
|
+
// 3. Force Metro to resolve (sub)dependencies only from the `nodeModulesPaths`, @see : https://docs.expo.dev/guides/monorepos/
|
62
|
+
config.resolver.disableHierarchicalLookup = true;
|
63
|
+
|
57
64
|
/*config.platforms = Array.isArray(config.platforms) && config.platforms || [];
|
58
65
|
['ios', 'android', 'windows', 'web',"electron"].map(p=>{
|
59
66
|
if(!config.platforms.includes(p)){
|
@@ -61,6 +68,6 @@ module.exports = function(opts){
|
|
61
68
|
}
|
62
69
|
});*/
|
63
70
|
///on génère les librairies open sources utilisées par l'application
|
64
|
-
require("./find-licenses");
|
71
|
+
//require("./find-licenses");
|
65
72
|
return config;
|
66
73
|
}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@fto-consult/expo-ui",
|
3
|
-
"version": "6.67.
|
3
|
+
"version": "6.67.13",
|
4
4
|
"description": "Bibliothèque de composants UI Expo,react-native",
|
5
5
|
"main": "main",
|
6
6
|
"scripts": {
|
@@ -71,7 +71,7 @@
|
|
71
71
|
"@expo/html-elements": "^0.5.1",
|
72
72
|
"@expo/vector-icons": "^13.0.0",
|
73
73
|
"@faker-js/faker": "^8.0.2",
|
74
|
-
"@fto-consult/common": "^3.57.
|
74
|
+
"@fto-consult/common": "^3.57.9",
|
75
75
|
"@pchmn/expo-material3-theme": "^1.3.1",
|
76
76
|
"@react-native-async-storage/async-storage": "1.18.2",
|
77
77
|
"@react-native-community/datetimepicker": "7.2.0",
|
@@ -7,6 +7,7 @@ import View from "$ecomponents/View";
|
|
7
7
|
import {isNativeMobile} from "$cplatform";
|
8
8
|
import {defaultDecimal} from "$cutils";
|
9
9
|
import {LogoProgress} from "$ecomponents/Logo";
|
10
|
+
import { Portal } from "react-native-paper";
|
10
11
|
import {defaultStr} from "$cutils";
|
11
12
|
import styles, {
|
12
13
|
_solidBackground,
|
@@ -17,29 +18,28 @@ import styles, {
|
|
17
18
|
_dynamicBackgroundOpacity,
|
18
19
|
} from "./styles"
|
19
20
|
import {useAppComponent} from "$econtext/hooks";
|
21
|
+
import theme from "$theme";
|
20
22
|
|
21
23
|
const SplashScreenComponent = ({isLoaded,children , duration, delay,logoWidth,logoHeight,backgroundColor,imageBackgroundSource,imageBackgroundResizeMode,
|
22
24
|
testID})=>{
|
23
25
|
const [state,setState] = React.useState({
|
24
26
|
animationDone: false,
|
25
|
-
loadingProgress: new Animated.Value(0)
|
27
|
+
loadingProgress: new Animated.Value(0),
|
26
28
|
});
|
27
|
-
const { loadingProgress, animationDone
|
28
|
-
const prevIsLoaded = React.usePrevious(isLoaded);
|
29
|
+
const { loadingProgress, animationDone} = state;
|
29
30
|
React.useEffect(()=>{
|
30
|
-
if(
|
31
|
-
|
32
|
-
setState({...state,animationDone:true});
|
31
|
+
if(!isLoaded){
|
32
|
+
setState({...state,loadingProgress : new Animated.Value(0),animationDone:false});
|
33
33
|
} else {
|
34
34
|
Animated.timing(loadingProgress, {
|
35
35
|
toValue: 100,
|
36
|
-
duration: duration ||
|
36
|
+
duration: duration || 5000,
|
37
37
|
delay: delay || 0,
|
38
|
-
useNativeDriver:
|
38
|
+
useNativeDriver: isNativeMobile(),
|
39
39
|
}).start(() => {
|
40
40
|
setState({
|
41
41
|
...state,
|
42
|
-
animationDone:
|
42
|
+
animationDone:true,
|
43
43
|
})
|
44
44
|
})
|
45
45
|
}
|
@@ -67,34 +67,37 @@ const SplashScreenComponent = ({isLoaded,children , duration, delay,logoWidth,lo
|
|
67
67
|
extrapolate: "clamp",
|
68
68
|
}),
|
69
69
|
}
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
70
|
+
if(animationDone && isLoaded){
|
71
|
+
return React.isValidElement(children)?children:null;
|
72
|
+
}
|
73
|
+
return <Portal>
|
74
|
+
<View style={[styles.container,{backgroundColor}]} testID={testID} id={testID}>
|
75
|
+
{<View style={[StyleSheet.absoluteFill,{backgroundColor}]} testID={testID+"_Animation"}/>}
|
74
76
|
<View style={styles.containerGlue} testID={testID+"_ContainerGlue"}>
|
75
|
-
{
|
77
|
+
{(
|
76
78
|
<Animated.View
|
77
79
|
style={_staticBackground(logoOpacity, backgroundColor)}
|
78
80
|
testID={testID+"_AnimationDone"}
|
79
81
|
/>
|
80
82
|
)}
|
81
|
-
{
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
83
|
+
{(
|
84
|
+
React.isComponent(Component)? <Component testID={testID+"_CustomSplashComponent"}/> :
|
85
|
+
<View testID={testID+"_LogoContainer"} style={[StyleSheet.absoluteFill,{backgroundColor}, styles.logoStyle]}>
|
86
|
+
<Animated.View
|
87
|
+
testID={testID+"_Logo"}
|
88
|
+
style={_dynamicCustomComponentStyle(
|
89
|
+
logoScale,
|
90
|
+
logoOpacity,
|
91
|
+
logoWidth,
|
92
|
+
logoHeight
|
93
|
+
)}>
|
94
|
+
{<LogoProgress />}
|
95
|
+
</Animated.View>
|
96
|
+
</View>
|
95
97
|
)}
|
96
98
|
</View>
|
97
99
|
</View>
|
100
|
+
</Portal>
|
98
101
|
}
|
99
102
|
|
100
103
|
|
@@ -571,7 +571,7 @@ export default class TableDataScreenComponent extends FormDataScreen{
|
|
571
571
|
if(typeof this.props.clone ==='function' && this.props.clone(data,this) === false) return data;
|
572
572
|
this.showPreloader();
|
573
573
|
delete data.approved;
|
574
|
-
Object.map(['_rev',...generatedColumnsProperties,...Object.keys(this.primaryKeyFields),'_id','code','updateBy','updatedDate','createBy','updatedHour','createdHour','createdDate'],(idx)=>{
|
574
|
+
Object.map(['_rev',...generatedColumnsProperties,...Object.keys(this.primaryKeyFields),'_id','code','updateBy',"created_at","updated_at",'updatedDate','createBy','updatedHour','createdHour','createdDate'],(idx)=>{
|
575
575
|
data[idx] = undefined;
|
576
576
|
delete data[idx];
|
577
577
|
});
|