@panneau/action-upload 4.0.1 → 4.0.3

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.
Files changed (2) hide show
  1. package/es/index.js +5 -6
  2. package/package.json +6 -6
package/es/index.js CHANGED
@@ -1,12 +1,11 @@
1
+ import _objectSpread from '@babel/runtime/helpers/objectSpread2';
1
2
  import _objectWithoutProperties from '@babel/runtime/helpers/objectWithoutProperties';
2
- import React, { useCallback } from 'react';
3
+ import { useCallback } from 'react';
3
4
  import { FormattedMessage } from 'react-intl';
4
5
  import { useFieldsComponentsManager } from '@panneau/core/contexts';
6
+ import { jsx } from 'react/jsx-runtime';
5
7
 
6
8
  var _excluded = ["endpoint", "action", "label", "value", "icon", "theme", "disabled", "onConfirmed", "fieldComponent", "className"];
7
-
8
- // TODO: figure out what happens when an item / multiple items are selected
9
-
10
9
  function UploadAction(_ref) {
11
10
  _ref.endpoint;
12
11
  _ref.action;
@@ -33,12 +32,12 @@ function UploadAction(_ref) {
33
32
  onConfirmed(data);
34
33
  }
35
34
  }, [onConfirmed]);
36
- return /*#__PURE__*/React.createElement(FieldComponent, Object.assign({
35
+ return /*#__PURE__*/jsx(FieldComponent, _objectSpread({
37
36
  withButton: true,
38
37
  outline: false,
39
38
  theme: theme,
40
39
  addButtonIcon: icon,
41
- addButtonLabel: label || /*#__PURE__*/React.createElement(FormattedMessage, {
40
+ addButtonLabel: label || /*#__PURE__*/jsx(FormattedMessage, {
42
41
  id: "eL+nIp",
43
42
  defaultMessage: [{
44
43
  "type": 0,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@panneau/action-upload",
3
- "version": "4.0.1",
3
+ "version": "4.0.3",
4
4
  "description": "Upload action",
5
5
  "keywords": [
6
6
  "javascript"
@@ -49,10 +49,10 @@
49
49
  },
50
50
  "dependencies": {
51
51
  "@babel/runtime": "^7.12.5",
52
- "@panneau/core": "^4.0.1",
53
- "@panneau/element-button": "^4.0.1",
54
- "@panneau/field-upload": "^4.0.1",
55
- "@panneau/themes": "^4.0.1",
52
+ "@panneau/core": "^4.0.2",
53
+ "@panneau/element-button": "^4.0.2",
54
+ "@panneau/field-upload": "^4.0.3",
55
+ "@panneau/themes": "^4.0.2",
56
56
  "classnames": "^2.5.1",
57
57
  "prop-types": "^15.7.2",
58
58
  "react-intl": "^5.15.8 || ^6.0.0 || ^7.0.0"
@@ -60,5 +60,5 @@
60
60
  "publishConfig": {
61
61
  "access": "public"
62
62
  },
63
- "gitHead": "dbdf65640625c027ecd56cf2b816b80a5c38cb8d"
63
+ "gitHead": "26b5ab7536b0e8c3197d40d302fc2681e7c7122e"
64
64
  }