@fto-consult/expo-ui 6.24.2 → 6.25.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/app.config.json +1 -1
- package/babel.config.alias.js +2 -1
- package/babel.config.js +1 -1
- package/electron/utils/env.js +80 -0
- package/expo-ui-path.js +2 -2
- package/index.js +14 -13
- package/is-local-dev.js +5 -0
- package/metro.config.js +3 -2
- package/package.json +6 -3
- package/src/App.js +3 -3
- package/src/components/Datagrid/Accordion/Row.js +74 -100
- package/src/components/Datagrid/Accordion/ToogleRow.js +9 -0
- package/src/components/Datagrid/Accordion/index.js +30 -35
- package/src/components/Datagrid/Actions/index.js +12 -44
- package/src/components/Datagrid/Checkbox.js +4 -7
- package/src/components/Datagrid/Common/Common.js +112 -148
- package/src/components/Datagrid/Dashboard/index.js +2 -2
- package/src/components/Datagrid/IndexComponent.js +8 -13
- package/src/components/Datagrid/Table/index.js +53 -51
- package/src/components/Datagrid/Test/index.js +10 -3
- package/src/components/Datagrid/events/evx.js +7 -0
- package/src/components/Datagrid/events/index.js +11 -0
- package/src/components/Datagrid/hooks/Provider.js +6 -0
- package/src/components/Datagrid/hooks/context.js +5 -0
- package/src/components/Datagrid/hooks/index.js +104 -0
- package/src/components/Datagrid/utils.js +6 -4
- package/src/components/Dialog/Dialog.js +13 -12
- package/src/components/Dialog/DialogContent.js +11 -0
- package/src/components/KeyboardAvoidingView/index.js +7 -3
- package/src/components/List/Common.js +5 -3
- package/src/components/List/FlashList.js +13 -13
- package/src/components/List/Virtuoso/index.js +29 -8
- package/src/components/List/Virtuoso/index.native.js +6 -1
- package/src/components/Table/FiltersOrFooters.js +11 -3
- package/src/components/Table/Header/Cell/index.js +10 -0
- package/src/components/Table/Header/Cell/index.native.js +7 -0
- package/src/components/Table/{Header.js → Header/Component.js} +0 -4
- package/src/components/Table/{Row.js → Header/Component.native.js} +3 -3
- package/src/components/Table/Header/index.js +12 -0
- package/src/components/Table/List/index.js +3 -1
- package/src/components/Table/List/index.native.js +2 -1
- package/src/components/Table/Row/Cell/Content.js +17 -0
- package/src/components/Table/Row/Cell/Content.native.js +15 -0
- package/src/components/Table/Row/Cell/index.js +29 -0
- package/src/components/Table/Row/RowWrapper.js +7 -0
- package/src/components/Table/Row/RowWrapper.native.js +10 -0
- package/src/components/Table/Row/index.js +38 -0
- package/src/components/Table/RowTemplate/index.js +10 -0
- package/src/components/Table/RowTemplate/index.web.js +9 -0
- package/src/components/Table/ScrollNative/index.js +7 -0
- package/src/components/Table/ScrollNative/index.native.js +8 -0
- package/src/components/Table/VirtuosoTable/index.js +5 -0
- package/src/components/Table/VirtuosoTable/index.native.js +3 -0
- package/src/components/Table/hooks.js +84 -0
- package/src/components/Table/index.js +88 -247
- package/src/components/Table/styles.js +88 -0
- package/src/components/Table/utils.js +1 -0
- package/src/layouts/AppBar/index.js +11 -10
- package/src/layouts/Screen/ScreenWithoutAuthContainer.js +14 -6
- package/src/navigation/Drawer/items/index.js +2 -1
- package/src/navigation/index.js +11 -3
- package/src/screens/Help/About.js +1 -1
- package/src/screens/Help/openLibraries.js +1 -1
- package/src/test-screens/Home.js +4 -1
- package/webpack.config.js +4 -2
- package/src/components/Table/Cell.js +0 -24
package/src/navigation/index.js
CHANGED
|
@@ -5,6 +5,7 @@ import React from "$react";
|
|
|
5
5
|
import DrawerNavigator from "./Drawer";
|
|
6
6
|
import useContext from "$econtext/hooks";
|
|
7
7
|
import { MainNavigationProvider } from "./hooks";
|
|
8
|
+
import {isWeb,isAndroid} from "$cplatform";
|
|
8
9
|
|
|
9
10
|
export * from "./hooks";
|
|
10
11
|
|
|
@@ -29,13 +30,19 @@ export default function NavigationComponent (props){
|
|
|
29
30
|
const opts = {
|
|
30
31
|
headerShown : false,
|
|
31
32
|
header : ()=> null,
|
|
33
|
+
presentation : isAndroid()? "card":"default",
|
|
34
|
+
animationEnabled : true,
|
|
35
|
+
}
|
|
36
|
+
const cardStyle = { backgroundColor: 'transparent' };
|
|
37
|
+
if(isWeb()){
|
|
38
|
+
cardStyle.flex = 1;
|
|
32
39
|
}
|
|
33
40
|
return <MainNavigationProvider {...rest} onGetStart={onGetStart} state={state} initialRouteName={initialRouteName}>
|
|
34
41
|
<DrawerNavigator {...props}>
|
|
35
42
|
{<Stack.Navigator
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
43
|
+
initialRouteName={initialRouteName}
|
|
44
|
+
screenOptions={opts}
|
|
45
|
+
>
|
|
39
46
|
{<Stack.Group screenOptions={{...opts}}>
|
|
40
47
|
{drawerScreens}
|
|
41
48
|
</Stack.Group>}
|
|
@@ -44,6 +51,7 @@ export default function NavigationComponent (props){
|
|
|
44
51
|
screenOptions={{
|
|
45
52
|
...opts,
|
|
46
53
|
presentation: 'transparentModal',
|
|
54
|
+
cardStyle
|
|
47
55
|
}}
|
|
48
56
|
>
|
|
49
57
|
{stackScreens}
|
|
@@ -63,7 +63,7 @@ export default function HelpScreen(props){
|
|
|
63
63
|
const borderStyle = {borderColor:theme.colors.divider,borderWidth:1,justifyContent:'space-between'};
|
|
64
64
|
const testID = defaultStr(props.testID,"RN_HelpAboutScreenComponent")
|
|
65
65
|
return <Screen withScrollView title={title} {...props} testID={testID+"_Screen"} contentContainerStyle={[{flex:1},theme.styles.alignItemsCenter,theme.styles.justifyContentCenter]}>
|
|
66
|
-
<View testID={testID+"_Container"} style={[theme.styles.alignItemsCenter,theme.styles.justifyContentCenter,theme.styles.
|
|
66
|
+
<View testID={testID+"_Container"} style={[theme.styles.alignItemsCenter,theme.styles.justifyContentCenter,theme.styles.w100,theme.styles.p1]}>
|
|
67
67
|
<Logo testID={testID+"_Logo"} style={{marginRight:10}}/>
|
|
68
68
|
{getReleaseText()}
|
|
69
69
|
<Divider testID={testID+"_Divider1"} style={[theme.styles.mv1]}/>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
module.exports = {"@
|
|
1
|
+
module.exports = {"@fto-consult/expo-ui":{"name":"@fto-consult/expo-ui","version":"6.24.2","repository":{"type":"git","url":"git+https://github.com/borispipo/expo-ui.git"},"homepage":"https://github.com/borispipo/expo-ui#readme"}};
|
package/src/test-screens/Home.js
CHANGED
|
@@ -1,8 +1,11 @@
|
|
|
1
1
|
import Screen from "$eScreen";
|
|
2
2
|
import Test from "$ecomponents/Datagrid/Test";
|
|
3
|
+
import React from "$react";
|
|
3
4
|
|
|
4
5
|
export default function HomeScreen(props){
|
|
5
|
-
|
|
6
|
+
React.useEffect(()=>{
|
|
7
|
+
},[])
|
|
8
|
+
return <Screen{...props} contentContainerStyle={[{flex:1}]}>
|
|
6
9
|
<Test/>
|
|
7
10
|
</Screen>
|
|
8
11
|
};
|
package/webpack.config.js
CHANGED
|
@@ -8,8 +8,10 @@ const path = require("path");
|
|
|
8
8
|
|
|
9
9
|
// Expo CLI will await this method so you can optionally return a promise.
|
|
10
10
|
module.exports = async function(env, argv,opts) {
|
|
11
|
-
const
|
|
12
|
-
const
|
|
11
|
+
const isLocalDev = require("./is-local-dev")();//si l'application est en developpement local
|
|
12
|
+
const nodeModulePath = path.resolve(`${process.cwd()}`,"node_modules");
|
|
13
|
+
const localNodeEuiP = path.resolve(nodeModulePath,"@expo/webpack-config");
|
|
14
|
+
const wConfigPath = fs.existsSync(localNodeEuiP) && localNodeEuiP || "@expo/webpack-config";
|
|
13
15
|
const createExpoWebpackConfigAsync = require(wConfigPath);
|
|
14
16
|
env = env || {};
|
|
15
17
|
opts = typeof opts =="object" && opts ? opts : {};
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
// Copyright 2023 @fto-consult/Boris Fouomene. All rights reserved.
|
|
2
|
-
// Use of this source code is governed by a BSD-style
|
|
3
|
-
// license that can be found in the LICENSE file.
|
|
4
|
-
import React from "react";
|
|
5
|
-
import { View } from "react-native";
|
|
6
|
-
import {defaultObj} from "$cutils";
|
|
7
|
-
import Label from "$ecomponents/Label";
|
|
8
|
-
|
|
9
|
-
function TableCellComponent({cellArgs,rowArgs,children,renderCell,rowIndex,style,...rest}){
|
|
10
|
-
const {content,containerProps} = React.useMemo(()=>{
|
|
11
|
-
const rArgs = {...cellArgs,...rowArgs,containerProps : {}};
|
|
12
|
-
const r = typeof renderCell =='function' && renderCell (rArgs) || children;
|
|
13
|
-
return {
|
|
14
|
-
content : typeof r =='string' || typeof r =='number'? <Label children={r}/> : React.isValidElement(r)? r : null,
|
|
15
|
-
containerProps : defaultObj(rArgs.containerProps)
|
|
16
|
-
}
|
|
17
|
-
},[children]);
|
|
18
|
-
return (<View {...containerProps} {...rest} style={[style,containerProps.style]} >
|
|
19
|
-
{content}
|
|
20
|
-
</View>);
|
|
21
|
-
}
|
|
22
|
-
//const TableCellComponent = React.memo(TableCellComponent);;
|
|
23
|
-
export default TableCellComponent;
|
|
24
|
-
TableCellComponent.displayName = "TableCellComponent";
|