react-crud-mobile 1.3.241 → 1.3.243

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.
@@ -1403,6 +1403,7 @@ function UIModal(_ref) {
1403
1403
  };
1404
1404
  var curr = (_scope$currentDialog2 = scope.currentDialog) == null ? void 0 : _scope$currentDialog2.crud;
1405
1405
  var main = ViewUtils.getCrud('view');
1406
+ if (dialog != null && dialog.debug) console.log(curr);
1406
1407
  if (!curr) {
1407
1408
  return /*#__PURE__*/jsx(Fragment, {});
1408
1409
  }
@@ -1808,7 +1809,9 @@ var styles$a = /*#__PURE__*/StyleSheet.create({
1808
1809
 
1809
1810
  var CrudContext = /*#__PURE__*/createContext({});
1810
1811
  function UIElement(props) {
1811
- var _original$list, _original$load;
1812
+ var _original$list,
1813
+ _original$load,
1814
+ _this = this;
1812
1815
  var ctx = useContext(CrudContext);
1813
1816
  var theme = Utils.nvl(props.theme, ctx == null ? void 0 : ctx.theme);
1814
1817
  var crud = Utils.nvl(props.crud, ctx == null ? void 0 : ctx.crud);
@@ -2249,10 +2252,14 @@ function UIElement(props) {
2249
2252
  def.search = crud;
2250
2253
  }
2251
2254
  var crudData = crud.data;
2255
+ var eventData = Utils.nvl(event.data, event.send);
2256
+ if (typeof eventData === 'function') {
2257
+ eventData = eventData.call(_this, args);
2258
+ }
2252
2259
  if (event.send === false || event.data === false) {
2253
2260
  crudData = {};
2254
2261
  }
2255
- var data = Utils.nvl(args.item, rowItem, event.data, crudData, {});
2262
+ var data = Utils.nvl(eventData, args.item, rowItem, crudData, {});
2256
2263
  var d = CrudUtils.create('dialog', _extends({
2257
2264
  parent: crud,
2258
2265
  root: crud,
@@ -2286,7 +2293,8 @@ function UIElement(props) {
2286
2293
  component: component,
2287
2294
  scope: dialogScope,
2288
2295
  close: close,
2289
- props: event.props
2296
+ props: event.props,
2297
+ debug: event.debug
2290
2298
  };
2291
2299
  main.dialog = dialog;
2292
2300
  scope.toggleDialog(true);