react-crud-mobile 1.3.45 → 1.3.47

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.
@@ -504,7 +504,7 @@ var MobileUtils = /*#__PURE__*/function () {
504
504
  }();
505
505
 
506
506
  function UISelect(props) {
507
- var _theme$styles, _theme$colors, _scope$original, _scope$original2;
507
+ var _theme$styles, _theme$colors, _scope$original, _scope$original2, _scope$original3, _scope$original4;
508
508
  var _useState = React.useState(false),
509
509
  modalVisible = _useState[0],
510
510
  setModalVisible = _useState[1];
@@ -518,6 +518,7 @@ function UISelect(props) {
518
518
  var handlePress = function handlePress() {
519
519
  setModalVisible(!modalVisible);
520
520
  };
521
+ var scrollRef = React.useRef(null);
521
522
  var iconColor = reactCrudUtils.Utils.nvl((_theme$colors = theme.colors) == null ? void 0 : _theme$colors.text, '#100e0e');
522
523
  var modalColor = reactCrudUtils.Utils.nvl(headerStyle.color, 'white');
523
524
  var defaults = {
@@ -569,6 +570,53 @@ function UISelect(props) {
569
570
  },
570
571
  children: [/*#__PURE__*/jsxRuntime.jsx(reactNative.SafeAreaView, {
571
572
  style: style('modalTop')
573
+ }), /*#__PURE__*/jsxRuntime.jsxs(reactNative.SafeAreaView, {
574
+ style: style('modalSafe'),
575
+ children: [/*#__PURE__*/jsxRuntime.jsxs(reactNative.View, {
576
+ style: scope.getStyle('header', headerStyle),
577
+ children: [/*#__PURE__*/jsxRuntime.jsx(reactNative.TouchableOpacity, {
578
+ onPress: handlePress,
579
+ style: style('modalCloseButton'),
580
+ children: /*#__PURE__*/jsxRuntime.jsx(vectorIcons.Ionicons, {
581
+ name: "close",
582
+ size: 24,
583
+ color: modalColor,
584
+ style: style('modalCloseText', defaults)
585
+ })
586
+ }), /*#__PURE__*/jsxRuntime.jsx(reactNative.Text, {
587
+ style: style('modalTitle', defaults),
588
+ children: placeholder
589
+ })]
590
+ }), /*#__PURE__*/jsxRuntime.jsx(reactNative.ScrollView, {
591
+ contentContainerStyle: {
592
+ flexGrow: 1,
593
+ paddingBottom: 50
594
+ },
595
+ style: style('modalContent'),
596
+ nestedScrollEnabled: true,
597
+ ref: scrollRef,
598
+ children: /*#__PURE__*/jsxRuntime.jsx(reactNative.View, {
599
+ style: {
600
+ flex: 1
601
+ },
602
+ children: /*#__PURE__*/jsxRuntime.jsx(UI.List, _extends({
603
+ data: items,
604
+ name: scope.getName('list'),
605
+ layout: "card",
606
+ click: onClick,
607
+ rowStyle: _extends({
608
+ paddingLeft: 15,
609
+ paddinRight: 15
610
+ }, (_scope$original = scope.original) == null ? void 0 : _scope$original.rowStyle)
611
+ }, (_scope$original2 = scope.original) == null ? void 0 : _scope$original2.listProps, {
612
+ children: /*#__PURE__*/jsxRuntime.jsx(UI.Value, {
613
+ value: "#{@this.label}"
614
+ })
615
+ }))
616
+ })
617
+ })]
618
+ }), /*#__PURE__*/jsxRuntime.jsx(reactNative.SafeAreaView, {
619
+ style: style('modalTop')
572
620
  }), /*#__PURE__*/jsxRuntime.jsxs(reactNative.SafeAreaView, {
573
621
  style: style('modalSafe'),
574
622
  children: [/*#__PURE__*/jsxRuntime.jsxs(reactNative.View, {
@@ -598,8 +646,8 @@ function UISelect(props) {
598
646
  rowStyle: _extends({
599
647
  paddingLeft: 15,
600
648
  paddinRight: 15
601
- }, (_scope$original = scope.original) == null ? void 0 : _scope$original.rowStyle)
602
- }, (_scope$original2 = scope.original) == null ? void 0 : _scope$original2.listProps, {
649
+ }, (_scope$original3 = scope.original) == null ? void 0 : _scope$original3.rowStyle)
650
+ }, (_scope$original4 = scope.original) == null ? void 0 : _scope$original4.listProps, {
603
651
  children: /*#__PURE__*/jsxRuntime.jsx(UI.Value, {
604
652
  value: "#{@this.label}"
605
653
  })
@@ -1411,9 +1459,6 @@ function UIModal(props) {
1411
1459
  }
1412
1460
  scope.update();
1413
1461
  };
1414
- React.useEffect(function () {
1415
- MobileUtils.syncTheme();
1416
- }, [modalVisible]);
1417
1462
  var curr = scope.currentDialog;
1418
1463
  if (!curr) {
1419
1464
  return /*#__PURE__*/jsxRuntime.jsx(jsxRuntime.Fragment, {});