@micromag/element-share-incentive 0.3.832 → 0.4.6
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.
- package/es/index.d.ts +11 -0
- package/es/index.js +8 -19
- package/es/styles.css +1 -0
- package/package.json +13 -12
package/es/index.d.ts
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import { TextElement, BoxStyle } from '@micromag/core';
|
|
3
|
+
|
|
4
|
+
interface ShareIncentiveProps {
|
|
5
|
+
className?: string | null;
|
|
6
|
+
label?: TextElement | null;
|
|
7
|
+
boxStyle?: BoxStyle | null;
|
|
8
|
+
}
|
|
9
|
+
declare function ShareIncentive({ className, label, boxStyle }: ShareIncentiveProps): react_jsx_runtime.JSX.Element;
|
|
10
|
+
|
|
11
|
+
export { ShareIncentive as default };
|
package/es/index.js
CHANGED
|
@@ -1,28 +1,19 @@
|
|
|
1
1
|
import _objectSpread from '@babel/runtime/helpers/objectSpread2';
|
|
2
2
|
import _defineProperty from '@babel/runtime/helpers/defineProperty';
|
|
3
3
|
import classNames from 'classnames';
|
|
4
|
-
import PropTypes$1 from 'prop-types';
|
|
5
4
|
import React from 'react';
|
|
6
|
-
import { PropTypes } from '@micromag/core';
|
|
7
5
|
import { getColorAsString, getStyleFromBox } from '@micromag/core/utils';
|
|
8
6
|
import Text from '@micromag/element-text';
|
|
9
7
|
|
|
10
8
|
var styles = {"box":"micromag-element-share-incentive-box","tip":"micromag-element-share-incentive-tip"};
|
|
11
9
|
|
|
12
|
-
|
|
13
|
-
className
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
label: null,
|
|
20
|
-
boxStyle: null
|
|
21
|
-
};
|
|
22
|
-
var ShareIncentive = function ShareIncentive(_ref) {
|
|
23
|
-
var className = _ref.className,
|
|
24
|
-
label = _ref.label,
|
|
25
|
-
boxStyle = _ref.boxStyle;
|
|
10
|
+
function ShareIncentive(_ref) {
|
|
11
|
+
var _ref$className = _ref.className,
|
|
12
|
+
className = _ref$className === void 0 ? null : _ref$className,
|
|
13
|
+
_ref$label = _ref.label,
|
|
14
|
+
label = _ref$label === void 0 ? null : _ref$label,
|
|
15
|
+
_ref$boxStyle = _ref.boxStyle,
|
|
16
|
+
boxStyle = _ref$boxStyle === void 0 ? null : _ref$boxStyle;
|
|
26
17
|
var _ref2 = boxStyle || {},
|
|
27
18
|
_ref2$backgroundColor = _ref2.backgroundColor,
|
|
28
19
|
backgroundColor = _ref2$backgroundColor === void 0 ? null : _ref2$backgroundColor;
|
|
@@ -42,8 +33,6 @@ var ShareIncentive = function ShareIncentive(_ref) {
|
|
|
42
33
|
})), /*#__PURE__*/React.createElement(Text, Object.assign({
|
|
43
34
|
className: styles.text
|
|
44
35
|
}, label))));
|
|
45
|
-
}
|
|
46
|
-
ShareIncentive.propTypes = propTypes;
|
|
47
|
-
ShareIncentive.defaultProps = defaultProps;
|
|
36
|
+
}
|
|
48
37
|
|
|
49
38
|
export { ShareIncentive as default };
|
package/es/styles.css
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.micromag-element-share-incentive-box{display:inline-block;position:relative}.micromag-element-share-incentive-tip{bottom:100%;height:auto;left:20px;position:absolute;width:30px}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@micromag/element-share-incentive",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.4.6",
|
|
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": "^
|
|
54
|
-
"react-dom": "^
|
|
54
|
+
"react": "^19.2.0",
|
|
55
|
+
"react-dom": "^18.3.0 || ^19.0.0"
|
|
55
56
|
},
|
|
56
57
|
"peerDependencies": {
|
|
57
|
-
"react": "^
|
|
58
|
-
"react-dom": "^
|
|
58
|
+
"react": "^19.2.0",
|
|
59
|
+
"react-dom": "^18.3.0 || ^19.0.0"
|
|
59
60
|
},
|
|
60
61
|
"dependencies": {
|
|
61
|
-
"@babel/runtime": "^7.
|
|
62
|
-
"@micromag/core": "^0.
|
|
63
|
-
"@micromag/element-text": "^0.
|
|
62
|
+
"@babel/runtime": "^7.28.6",
|
|
63
|
+
"@micromag/core": "^0.4.6",
|
|
64
|
+
"@micromag/element-text": "^0.4.6",
|
|
64
65
|
"classnames": "^2.2.6",
|
|
65
|
-
"
|
|
66
|
-
"react-intl": "^6.6.4",
|
|
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": "
|
|
73
|
+
"gitHead": "cf8440c2851b864167a1f545aa56551d55473263",
|
|
74
|
+
"types": "es/index.d.ts"
|
|
74
75
|
}
|