mg-library 1.0.404 → 1.0.406

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.
Files changed (2) hide show
  1. package/blocks.js +12 -6
  2. package/package.json +1 -1
package/blocks.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { useCallback, useState, useEffect } from 'react';
2
2
  import { useForm, Controller } from 'react-hook-form';
3
- import { View, ActivityIndicator, Pressable, Image, FlatList, Keyboard } from 'react-native';
3
+ import { View, ActivityIndicator, Pressable, Image, FlatList, Keyboard, Dimensions } from 'react-native';
4
4
  import { Text, Divider, Button, Popover, Card, Layout, Input } from '@ui-kitten/components';
5
5
  import MaterialCommunityIcons from 'react-native-vector-icons/MaterialCommunityIcons';
6
6
  import * as ImageManipulator from 'expo-image-manipulator';
@@ -143,9 +143,9 @@ export function MGLogin(props) {
143
143
  source={require('./assets/clubonline.png')}
144
144
  style={{ width: 300, height: 150 }} />
145
145
  {!isKeyboardVisible &&
146
- <View>
147
- <Text style={{alignSelf: center}} category='h6'>{props.appDescription}</Text>
148
- <Text style={{alignSelf: center}} category='p2'>{props.appVersion}</Text>
146
+ <View style={{ flexDirection: 'column', alignItems: 'center' }}>
147
+ <Text style={{alignSelf: 'center'}} category='h6'>{props.appDescription}</Text>
148
+ <Text style={{alignSelf: 'center'}} category='p2'>{props.appVersion}</Text>
149
149
  </View>
150
150
  }
151
151
  </View>
@@ -247,6 +247,12 @@ export function MGCurrentAccount(props) {
247
247
 
248
248
  export function MGCamera(props) {
249
249
  let camera;
250
+
251
+ //205
252
+ //275
253
+ let captureWidth = Dimensions.get('window').width * 0.60;
254
+ let captureHeight = Dimensions.get('window').height * 0.60;
255
+
250
256
  const __takePicture = async () => {
251
257
  if (!camera)
252
258
  return;
@@ -254,7 +260,7 @@ export function MGCamera(props) {
254
260
  props.dispatch(props.actions.startProcessing());
255
261
  photo = await ImageManipulator.manipulateAsync(
256
262
  photo.uri,
257
- [{ resize: { width: 205, height: 275 } }],
263
+ [{ resize: { width: captureWidth, height: captureHeight } }],
258
264
  { compress: 1, format: ImageManipulator.SaveFormat.JPEG }
259
265
  );
260
266
  photo = await ImageManipulator.manipulateAsync(
@@ -318,7 +324,7 @@ export function MGCamera(props) {
318
324
  <Card header={cardHeader} footer={cardFooter}>
319
325
  <View style={{ alignItems: 'center' }}>
320
326
  <Camera
321
- style={{ width: 205, height: 275 }}
327
+ style={{ width: captureWidth, height: captureHeight }}
322
328
  type={type}
323
329
  ref={(r) => {
324
330
  camera = r
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mg-library",
3
- "version": "1.0.404",
3
+ "version": "1.0.406",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {