react-admin-base-bootstrap 0.9.21 → 0.9.23

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.
@@ -35,6 +35,8 @@ function EditOrAddIndicator(props) {
35
35
  e.stopPropagation();
36
36
  e.preventDefault();
37
37
  props.selectProps.onAddOrEdit();
38
+ }, onTouchEnd: e => {
39
+ props.selectProps.onAddOrEdit();
38
40
  }, children: _jsx("i", { className: "fas " + (props.hasValue && !isMulti ? 'fa-pencil-alt' : 'fa-plus') }) })));
39
41
  }
40
42
  function IndicatorsContainer(props) {
@@ -121,7 +121,7 @@ export default function CRUD(props) {
121
121
  const reload = useCallback(function () {
122
122
  return __awaiter(this, void 0, void 0, function* () {
123
123
  if (ref.current) {
124
- ref.current(params => (Object.assign({}, params)));
124
+ ref.current({});
125
125
  }
126
126
  });
127
127
  }, [ref]);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-admin-base-bootstrap",
3
- "version": "0.9.21",
3
+ "version": "0.9.23",
4
4
  "description": "",
5
5
  "scripts": {
6
6
  "test": "echo \"Error: no test specified\" && exit 1",
@@ -1,6 +1,6 @@
1
1
  /** @jsxImportSource @emotion/react */
2
2
  import { css } from "@emotion/react"
3
- import React, {Fragment, useCallback, useMemo, useState} from 'react';
3
+ import React, {Fragment, useCallback, useMemo, useRef, useState} from 'react';
4
4
  import {RefreshScope, useFetch, useRefresh} from 'react-admin-base';
5
5
  import { FormattedMessage, useIntl } from 'react-intl';
6
6
  import Select, { components } from "react-select";
@@ -42,6 +42,7 @@ function MultiValue(props) {
42
42
 
43
43
  function EditOrAddIndicator(props) {
44
44
  const { className, cx, getStyles, innerProps, isMulti } = props;
45
+
45
46
  return (
46
47
  <div
47
48
  {...innerProps}
@@ -58,6 +59,9 @@ function EditOrAddIndicator(props) {
58
59
  e.preventDefault();
59
60
  props.selectProps.onAddOrEdit();
60
61
  }}
62
+ onTouchEnd={e => {
63
+ props.selectProps.onAddOrEdit();
64
+ }}
61
65
  >
62
66
  <i className={"fas " + (props.hasValue && !isMulti ? 'fa-pencil-alt' : 'fa-plus')} />
63
67
  </div>);
@@ -145,7 +145,7 @@ export default function CRUD(props: CRUDProps) {
145
145
 
146
146
  const reload = useCallback(async function() {
147
147
  if (ref.current) {
148
- ref.current(params => ({ ...params }));
148
+ ref.current({});
149
149
  }
150
150
  }, [ref]);
151
151