@fto-consult/expo-ui 6.6.9 → 6.7.1

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fto-consult/expo-ui",
3
- "version": "6.6.9",
3
+ "version": "6.7.1",
4
4
  "description": "Bibliothèque de composants UI Expo,react-native",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -41,7 +41,7 @@
41
41
  "fix-dependencies": "expo-cli doctor --fix-dependencies",
42
42
  "delete-node-modules": "rimraf ./**/node_modules",
43
43
  "modifier-url-remote-git": "git remote set-url origin 'https://borispipo@github.com/borispipo/smart-eneo.git'",
44
- "update": "npm i @emotion/native@latest apexcharts@latest file-saver@latest fs-extra@latest google-libphonenumber@latest @pchmn/expo-material3-theme@latest @gorhom/portal@latest @emotion/native@latest @fto-consult/common@latest react-native-blob-util react-native-gesture-handler@latest react-native-iphone-x-helper@latest react-native-mime-types@latest react-native-paper@latest react-native-paper-dates@latest @react-navigation/native@latest @react-navigation/native-stack@latest react-virtuoso@latest sharp-cli@latest tippy.js@latest websql@latest xlsx@latest && npx expo install --fix"
44
+ "update": "npm i expo @emotion/native@latest apexcharts@latest file-saver@latest fs-extra@latest google-libphonenumber@latest @pchmn/expo-material3-theme@latest @gorhom/portal@latest @emotion/native@latest @fto-consult/common@latest react-native-blob-util react-native-gesture-handler@latest react-native-iphone-x-helper@latest react-native-mime-types@latest react-native-paper@latest react-native-paper-dates@latest @react-navigation/native@latest @react-navigation/native-stack@latest react-virtuoso@latest sharp-cli@latest tippy.js@latest websql@latest xlsx@latest && npx expo install --fix"
45
45
  },
46
46
  "bin": "./bin/index.js",
47
47
  "repository": {
@@ -73,7 +73,7 @@
73
73
  "@react-navigation/native-stack": "^6.9.13",
74
74
  "@shopify/flash-list": "1.4.3",
75
75
  "apexcharts": "^3.41.0",
76
- "expo": "^49.0.3",
76
+ "expo": "^49.0.4",
77
77
  "expo-camera": "~13.4.2",
78
78
  "expo-clipboard": "~4.3.0",
79
79
  "expo-font": "~11.4.0",
@@ -106,7 +106,7 @@
106
106
  "react-native-svg": "13.9.0",
107
107
  "react-native-web": "~0.19.6",
108
108
  "react-native-webview": "13.2.2",
109
- "react-virtuoso": "^4.4.0",
109
+ "react-virtuoso": "^4.4.1",
110
110
  "sharp-cli": "^4.1.1",
111
111
  "tippy.js": "^6.3.7",
112
112
  "websql": "^2.0.3",
@@ -286,7 +286,7 @@ class SwiperComponent extends React.Component {
286
286
  childrenProps = Array.isArray(childrenProps)? childrenProps : [];
287
287
  const isReady = customHeight > 40 ? true : false;
288
288
  const autoHeight = !!this.props.autoHeight;
289
- const height = autoHeight ? "100%" : !isReady ? WIDTH_HEIGHT : customHeight;
289
+ const height = autoHeight ? undefined : !isReady ? WIDTH_HEIGHT : customHeight;
290
290
  if(withScrollView){
291
291
  wrapperProps.nestedScrollEnabled = typeof wrapperProps.nestedScrollEnabled ==="boolean"? wrapperProps.nestedScrollEnabled : isNative;
292
292
  if(typeof wrapperProps.showsVerticalScrollIndicator !=='boolean'){
@@ -440,7 +440,7 @@ const styles = {
440
440
  backgroundColor: 'transparent',
441
441
  },
442
442
  // Fix web vertical scaling (like expo v33-34)
443
- container: (positionFixed, x, y, width, height,autoHeight) => ({
443
+ container: (positionFixed, x, y, width, height,autoHeight) => addAutoHeight(({
444
444
  backgroundColor: 'transparent',
445
445
  // Fix safari vertical bounces
446
446
  position: positionFixed ? 'fixed' : 'relative',
@@ -449,18 +449,16 @@ const styles = {
449
449
  top: positionFixed ? y : 0,
450
450
  left: positionFixed ? x : 0,
451
451
  width,
452
- height:!autoHeight ? undefined : height,
453
452
  justifyContent: 'flex-start',
454
453
  alignItems : 'flex-start',
455
- }),
456
- swipeArea: (vertical, count, width, height,autoHeight) => ({
454
+ }),height,autoHeight),
455
+ swipeArea: (vertical, count, width, height,autoHeight) => addAutoHeight(({
457
456
  position: 'relative',
458
457
  top: 0,
459
458
  left: 0,
460
459
  width:vertical ? width : width * count,
461
- height:!autoHeight ? undefined : vertical ? height * count : height,
462
460
  flexDirection: vertical ? 'column' : 'row',
463
- }),
461
+ }),typeof height ==='number'? (vertical ? height * count : height) : undefiend,autoHeight),
464
462
  scrollViewContentContainer : {
465
463
  paddingBottom : 40,
466
464
  flex : 1,
@@ -473,4 +471,11 @@ const styles = {
473
471
  }
474
472
  };
475
473
 
474
+ const addAutoHeight = (style,height,autoHeight)=>{
475
+ if(height !== undefined && autoHeight){
476
+ style.height = height;
477
+ }
478
+ return style;
479
+ }
480
+
476
481
  export default SwiperComponent;