react-crud-mobile 1.3.19 → 1.3.20
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/dist/react-crud-mobile.cjs.development.js +22 -21
- package/dist/react-crud-mobile.cjs.development.js.map +1 -1
- package/dist/react-crud-mobile.cjs.production.min.js +1 -1
- package/dist/react-crud-mobile.cjs.production.min.js.map +1 -1
- package/dist/react-crud-mobile.esm.js +23 -22
- package/dist/react-crud-mobile.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/elements/core/UISelect.tsx +10 -14
|
@@ -489,6 +489,20 @@ function UIButton(props) {
|
|
|
489
489
|
});
|
|
490
490
|
}
|
|
491
491
|
|
|
492
|
+
//import { ThemeUtils, Utils } from 'react-crud-utils';
|
|
493
|
+
//import { StatusBar } from 'react-native';
|
|
494
|
+
var MobileUtils = /*#__PURE__*/function () {
|
|
495
|
+
function MobileUtils() {}
|
|
496
|
+
MobileUtils.syncTheme = function syncTheme() {
|
|
497
|
+
// let current = ThemeUtils.getCurrentTheme();
|
|
498
|
+
//let dec: any = { light: 'light-content', dark: 'dark-content' };
|
|
499
|
+
//let name = Utils.nvl(dec[current?.theme], dec.light);
|
|
500
|
+
//StatusBar.setBarStyle?.(name);
|
|
501
|
+
//StatusBar.setBackgroundColor?.(current?.colors?.theme);
|
|
502
|
+
};
|
|
503
|
+
return MobileUtils;
|
|
504
|
+
}();
|
|
505
|
+
|
|
492
506
|
function UISelect(props) {
|
|
493
507
|
var _theme$colors;
|
|
494
508
|
var _useState = React.useState(false),
|
|
@@ -520,12 +534,16 @@ function UISelect(props) {
|
|
|
520
534
|
handlePress();
|
|
521
535
|
};
|
|
522
536
|
var style = function style(part, extra) {
|
|
523
|
-
|
|
537
|
+
var all = _extends({}, styles$3[part], extra);
|
|
538
|
+
return scope.getStyle(part, all);
|
|
524
539
|
};
|
|
525
540
|
var isModalVisible = function isModalVisible() {
|
|
526
541
|
return modalVisible;
|
|
527
542
|
};
|
|
528
543
|
//v1
|
|
544
|
+
React.useEffect(function () {
|
|
545
|
+
MobileUtils.syncTheme();
|
|
546
|
+
}, [modalVisible]);
|
|
529
547
|
return /*#__PURE__*/jsxRuntime.jsxs(reactNative.View, {
|
|
530
548
|
style: style('selectRoot'),
|
|
531
549
|
children: [/*#__PURE__*/jsxRuntime.jsxs(reactNative.TouchableOpacity, {
|
|
@@ -540,17 +558,14 @@ function UISelect(props) {
|
|
|
540
558
|
color: scope.getPart('iconColor', null, iconColor),
|
|
541
559
|
style: style('iconStyle', {})
|
|
542
560
|
})]
|
|
543
|
-
}), /*#__PURE__*/jsxRuntime.
|
|
561
|
+
}), /*#__PURE__*/jsxRuntime.jsx(reactNative.Modal, {
|
|
544
562
|
animationType: "slide",
|
|
545
563
|
transparent: true,
|
|
546
564
|
visible: isModalVisible(),
|
|
547
565
|
onRequestClose: function onRequestClose() {
|
|
548
566
|
return setModalVisible(false);
|
|
549
567
|
},
|
|
550
|
-
children:
|
|
551
|
-
barStyle: "dark-content",
|
|
552
|
-
backgroundColor: theme.colors.primary
|
|
553
|
-
}), /*#__PURE__*/jsxRuntime.jsxs(reactNative.SafeAreaView, {
|
|
568
|
+
children: /*#__PURE__*/jsxRuntime.jsxs(reactNative.SafeAreaView, {
|
|
554
569
|
style: style('modalSafe'),
|
|
555
570
|
children: [/*#__PURE__*/jsxRuntime.jsxs(reactNative.View, {
|
|
556
571
|
style: style('modalHeader'),
|
|
@@ -578,7 +593,7 @@ function UISelect(props) {
|
|
|
578
593
|
})
|
|
579
594
|
})
|
|
580
595
|
})]
|
|
581
|
-
})
|
|
596
|
+
})
|
|
582
597
|
})]
|
|
583
598
|
});
|
|
584
599
|
}
|
|
@@ -1315,20 +1330,6 @@ function UIToast() {
|
|
|
1315
1330
|
});
|
|
1316
1331
|
}
|
|
1317
1332
|
|
|
1318
|
-
//import { ThemeUtils, Utils } from 'react-crud-utils';
|
|
1319
|
-
//import { StatusBar } from 'react-native';
|
|
1320
|
-
var MobileUtils = /*#__PURE__*/function () {
|
|
1321
|
-
function MobileUtils() {}
|
|
1322
|
-
MobileUtils.syncTheme = function syncTheme() {
|
|
1323
|
-
// let current = ThemeUtils.getCurrentTheme();
|
|
1324
|
-
//let dec: any = { light: 'light-content', dark: 'dark-content' };
|
|
1325
|
-
//let name = Utils.nvl(dec[current?.theme], dec.light);
|
|
1326
|
-
//StatusBar.setBarStyle?.(name);
|
|
1327
|
-
//StatusBar.setBackgroundColor?.(current?.colors?.theme);
|
|
1328
|
-
};
|
|
1329
|
-
return MobileUtils;
|
|
1330
|
-
}();
|
|
1331
|
-
|
|
1332
1333
|
function UIModal(props) {
|
|
1333
1334
|
var _theme$styles, _main$dialog2;
|
|
1334
1335
|
var _useState = React.useState(false),
|