@micromag/element-container 0.3.824 → 0.4.4

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.
@@ -1 +1 @@
1
- .micromag-element-container-container{overflow:hidden;position:relative}
1
+ .container{overflow:hidden;position:relative}
package/es/index.d.ts ADDED
@@ -0,0 +1,3 @@
1
+ declare const _default: any;
2
+
3
+ export { _default as default };
package/es/index.js CHANGED
@@ -1,34 +1,21 @@
1
1
  import _defineProperty from '@babel/runtime/helpers/defineProperty';
2
2
  import _objectSpread from '@babel/runtime/helpers/objectSpread2';
3
3
  import classNames from 'classnames';
4
- import PropTypes from 'prop-types';
5
4
  import React from 'react';
6
5
 
7
- var styles = {"container":"micromag-element-container-container"};
6
+ var styles = {"container":"container"};
8
7
 
9
- var propTypes = {
10
- containerRef: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({
11
- current: PropTypes.any
12
- })]),
13
- width: PropTypes.number.isRequired,
14
- height: PropTypes.number.isRequired,
15
- style: PropTypes.shape({}),
16
- className: PropTypes.string,
17
- children: PropTypes.node
18
- };
19
- var defaultProps = {
20
- containerRef: null,
21
- className: null,
22
- style: null,
23
- children: null
24
- };
25
8
  function Container(_ref) {
26
- var containerRef = _ref.containerRef,
9
+ var _ref$containerRef = _ref.containerRef,
10
+ containerRef = _ref$containerRef === void 0 ? null : _ref$containerRef,
27
11
  width = _ref.width,
28
12
  height = _ref.height,
29
- style = _ref.style,
30
- className = _ref.className,
31
- children = _ref.children;
13
+ _ref$style = _ref.style,
14
+ style = _ref$style === void 0 ? null : _ref$style,
15
+ _ref$className = _ref.className,
16
+ className = _ref$className === void 0 ? null : _ref$className,
17
+ _ref$children = _ref.children,
18
+ children = _ref$children === void 0 ? null : _ref$children;
32
19
  var hasSize = width > 0 && height > 0;
33
20
  var containerStyle = hasSize ? _objectSpread({
34
21
  width: width,
@@ -40,8 +27,6 @@ function Container(_ref) {
40
27
  style: containerStyle
41
28
  }, children);
42
29
  }
43
- Container.propTypes = propTypes;
44
- Container.defaultProps = defaultProps;
45
30
  var Container_default = /*#__PURE__*/React.forwardRef(function (props, ref) {
46
31
  return /*#__PURE__*/React.createElement(Container, Object.assign({
47
32
  containerRef: ref
package/es/styles.css ADDED
@@ -0,0 +1 @@
1
+ .container{overflow:hidden;position:relative}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@micromag/element-container",
3
- "version": "0.3.824",
3
+ "version": "0.4.4",
4
4
  "private": false,
5
5
  "description": "",
6
6
  "keywords": [
@@ -34,6 +34,7 @@
34
34
  "module": "es/index.js",
35
35
  "exports": {
36
36
  ".": {
37
+ "types": "./es/index.d.ts",
37
38
  "import": "./es/index.js"
38
39
  },
39
40
  "./assets/css/styles": "./assets/css/styles.css",
@@ -47,28 +48,28 @@
47
48
  "scripts": {
48
49
  "clean": "rm -rf es && rm -rf lib && rm -rf assets",
49
50
  "prepublishOnly": "npm run build",
50
- "build": "../../scripts/prepare-package.sh"
51
+ "build": "../../scripts/prepare-package.sh --types"
51
52
  },
52
53
  "devDependencies": {
53
- "react": "^16.8.0 || ^17.0.0 || ^18.0.0",
54
- "react-dom": "^16.8.0 || ^17.0.0 || ^18.0.0"
54
+ "react": "^19.2.0",
55
+ "react-dom": "^18.3.0 || ^19.0.0"
55
56
  },
56
57
  "peerDependencies": {
57
- "react": "^16.8.0 || ^17.0.0 || ^18.0.0",
58
- "react-dom": "^16.8.0 || ^17.0.0 || ^18.0.0"
58
+ "react": "^19.2.0",
59
+ "react-dom": "^18.3.0 || ^19.0.0"
59
60
  },
60
61
  "dependencies": {
61
62
  "@babel/runtime": "^7.13.10",
62
- "@micromag/core": "^0.3.824",
63
+ "@micromag/core": "^0.4.4",
63
64
  "classnames": "^2.2.6",
64
- "lodash": "^4.17.21",
65
- "prop-types": "^15.7.2",
66
- "react-intl": "^6.6.4",
65
+ "lodash": "^4.17.23",
66
+ "react-intl": "^8.1.3",
67
67
  "uuid": "^9.0.0"
68
68
  },
69
69
  "publishConfig": {
70
70
  "access": "public",
71
71
  "registry": "https://registry.npmjs.org/"
72
72
  },
73
- "gitHead": "e266e480cdc5741c73160840affee2eac7e7c9de"
73
+ "gitHead": "04b8519c3a3ddace5a21497e22faa11865d57f6d",
74
+ "types": "es/index.d.ts"
74
75
  }