react-crud-mobile 1.3.257 → 1.3.259

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.
@@ -1369,12 +1369,12 @@ function UIModal(_ref) {
1369
1369
  var _theme$styles, _main$dialog;
1370
1370
  var scope = _ref.scope,
1371
1371
  props = _objectWithoutPropertiesLoose(_ref, _excluded);
1372
- var _useState = useState(false),
1373
- modalVisible = _useState[0],
1374
- setModalVisible = _useState[1];
1375
- var _useState2 = useState(0),
1376
- index = _useState2[0];
1372
+ var _useState = useState(0),
1373
+ index = _useState[0];
1377
1374
  var dialog = scope.currentDialog;
1375
+ var _useState2 = useState(!Utils.isEmpty(dialog)),
1376
+ modalVisible = _useState2[0],
1377
+ setModalVisible = _useState2[1];
1378
1378
  //v1
1379
1379
  var label = scope.getLabel();
1380
1380
  var theme = scope.getTheme();
@@ -1397,9 +1397,10 @@ function UIModal(_ref) {
1397
1397
  };
1398
1398
  var curr = dialog == null ? void 0 : dialog.crud;
1399
1399
  var main = ViewUtils.getCrud('view');
1400
- if (!curr || !dialog) {
1400
+ if (!dialog) {
1401
1401
  return /*#__PURE__*/jsx(Fragment, {});
1402
1402
  }
1403
+ if (dialog.debug) console.log(dialog);
1403
1404
  if (curr.uuid !== ((_main$dialog = main.dialog) == null || (_main$dialog = _main$dialog.crud) == null ? void 0 : _main$dialog.uuid)) {
1404
1405
  return /*#__PURE__*/jsx(Fragment, {});
1405
1406
  }