mg-library 1.0.449 → 1.0.451

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 (3) hide show
  1. package/blocks.js +7 -2
  2. package/login.js +0 -3
  3. package/package.json +1 -1
package/blocks.js CHANGED
@@ -310,7 +310,11 @@ export function MGCamera(props) {
310
310
  props.process.goForward(props.nextStep);
311
311
  props.dispatch(props.actions.endProcessing());
312
312
  }
313
- const [type, setType] = useState(Camera.Constants.Type.front);
313
+
314
+ //const [type, setType] = useState(Camera.Constants.Type.front);
315
+
316
+ const [type, setType] = useState<CameraType>('front');
317
+
314
318
  const FlipIcon = () => (
315
319
  <MaterialCommunityIcons
316
320
  name='camera-flip-outline'
@@ -339,7 +343,8 @@ export function MGCamera(props) {
339
343
  accessoryLeft={FlipIcon}
340
344
  onPress={() => {
341
345
  setType(
342
- type === Camera.Constants.Type.back ? Camera.Constants.Type.front : Camera.Constants.Type.back
346
+ // type === Camera.Constants.Type.back ? Camera.Constants.Type.front : Camera.Constants.Type.back
347
+ type === 'back' ? 'front' : 'back'
343
348
  )
344
349
  }}>
345
350
  <Text>{mgFunctionsLib.i18nString('doInvertCamera', props.language)}</Text>
package/login.js CHANGED
@@ -15,9 +15,6 @@ export function onPressLogin(dispatch, actions, app, apiUrl, language, data) {
15
15
  axios.post(apiUrl + '/Login', requestData, mgFunctionsLib.getRequestHeader())
16
16
  .then(response => {
17
17
  let appSession = response.data;
18
-
19
- console.log(appSession);
20
-
21
18
  dispatch(actions.login(appSession));
22
19
  mgFunctionsLib.writeToLocalStorage(mgConstantsLib.ACCESS_TOKEN, appSession.accessToken);
23
20
  dispatch(actions.apiSuccess());
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mg-library",
3
- "version": "1.0.449",
3
+ "version": "1.0.451",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {