@micromag/screen-survey 0.3.134 → 0.3.138
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.js +14 -1
- package/lib/index.js +14 -1
- package/package.json +13 -13
package/es/index.js
CHANGED
|
@@ -29,6 +29,7 @@ var propTypes = {
|
|
|
29
29
|
answers: PropTypes$1.answers,
|
|
30
30
|
buttonsStyle: PropTypes$1.boxStyle,
|
|
31
31
|
buttonsTextStyle: PropTypes$1.textStyle,
|
|
32
|
+
percentageResultTextStyle: PropTypes$1.textStyle,
|
|
32
33
|
resultsStyle: PropTypes.shape({
|
|
33
34
|
barColor: PropTypes$1.color,
|
|
34
35
|
textColor: PropTypes$1.color
|
|
@@ -56,6 +57,7 @@ var defaultProps = {
|
|
|
56
57
|
buttonsStyle: null,
|
|
57
58
|
buttonsTextStyle: null,
|
|
58
59
|
resultsStyle: null,
|
|
60
|
+
percentageResultTextStyle: null,
|
|
59
61
|
spacing: 20,
|
|
60
62
|
background: null,
|
|
61
63
|
callToAction: null,
|
|
@@ -82,6 +84,7 @@ var SurveyScreen = function SurveyScreen(_ref) {
|
|
|
82
84
|
buttonsStyle = _ref.buttonsStyle,
|
|
83
85
|
buttonsTextStyle = _ref.buttonsTextStyle,
|
|
84
86
|
resultsStyle = _ref.resultsStyle,
|
|
87
|
+
percentageResultTextStyle = _ref.percentageResultTextStyle,
|
|
85
88
|
spacing = _ref.spacing,
|
|
86
89
|
background = _ref.background,
|
|
87
90
|
callToAction = _ref.callToAction,
|
|
@@ -368,7 +371,7 @@ var SurveyScreen = function SurveyScreen(_ref) {
|
|
|
368
371
|
opacity: 0
|
|
369
372
|
})
|
|
370
373
|
}, /*#__PURE__*/React.createElement(Text, Object.assign({}, label, {
|
|
371
|
-
textStyle: _objectSpread(_objectSpread(_objectSpread(_objectSpread({}, textStyle), buttonsTextStyle), resultsTextColor), answerResultTextColor),
|
|
374
|
+
textStyle: _objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread({}, textStyle), buttonsTextStyle), resultsTextColor), answerResultTextColor), percentageResultTextStyle),
|
|
372
375
|
inline: true,
|
|
373
376
|
className: styles.resultText,
|
|
374
377
|
body: "".concat(percent, "%")
|
|
@@ -571,6 +574,16 @@ var definition = {
|
|
|
571
574
|
field: {
|
|
572
575
|
type: 'graph-bar-style'
|
|
573
576
|
}
|
|
577
|
+
}, {
|
|
578
|
+
name: 'percentageResultTextStyle',
|
|
579
|
+
type: 'text-style-form',
|
|
580
|
+
label: defineMessage({
|
|
581
|
+
id: "4y3gAI",
|
|
582
|
+
defaultMessage: [{
|
|
583
|
+
"type": 0,
|
|
584
|
+
"value": "Result percentage text"
|
|
585
|
+
}]
|
|
586
|
+
})
|
|
574
587
|
}]
|
|
575
588
|
}, {
|
|
576
589
|
name: 'background',
|
package/lib/index.js
CHANGED
|
@@ -50,6 +50,7 @@ var propTypes = {
|
|
|
50
50
|
answers: core.PropTypes.answers,
|
|
51
51
|
buttonsStyle: core.PropTypes.boxStyle,
|
|
52
52
|
buttonsTextStyle: core.PropTypes.textStyle,
|
|
53
|
+
percentageResultTextStyle: core.PropTypes.textStyle,
|
|
53
54
|
resultsStyle: PropTypes__default["default"].shape({
|
|
54
55
|
barColor: core.PropTypes.color,
|
|
55
56
|
textColor: core.PropTypes.color
|
|
@@ -77,6 +78,7 @@ var defaultProps = {
|
|
|
77
78
|
buttonsStyle: null,
|
|
78
79
|
buttonsTextStyle: null,
|
|
79
80
|
resultsStyle: null,
|
|
81
|
+
percentageResultTextStyle: null,
|
|
80
82
|
spacing: 20,
|
|
81
83
|
background: null,
|
|
82
84
|
callToAction: null,
|
|
@@ -103,6 +105,7 @@ var SurveyScreen = function SurveyScreen(_ref) {
|
|
|
103
105
|
buttonsStyle = _ref.buttonsStyle,
|
|
104
106
|
buttonsTextStyle = _ref.buttonsTextStyle,
|
|
105
107
|
resultsStyle = _ref.resultsStyle,
|
|
108
|
+
percentageResultTextStyle = _ref.percentageResultTextStyle,
|
|
106
109
|
spacing = _ref.spacing,
|
|
107
110
|
background = _ref.background,
|
|
108
111
|
callToAction = _ref.callToAction,
|
|
@@ -389,7 +392,7 @@ var SurveyScreen = function SurveyScreen(_ref) {
|
|
|
389
392
|
opacity: 0
|
|
390
393
|
})
|
|
391
394
|
}, /*#__PURE__*/React__default["default"].createElement(Text__default["default"], Object.assign({}, label, {
|
|
392
|
-
textStyle: _objectSpread__default["default"](_objectSpread__default["default"](_objectSpread__default["default"](_objectSpread__default["default"]({}, textStyle), buttonsTextStyle), resultsTextColor), answerResultTextColor),
|
|
395
|
+
textStyle: _objectSpread__default["default"](_objectSpread__default["default"](_objectSpread__default["default"](_objectSpread__default["default"](_objectSpread__default["default"]({}, textStyle), buttonsTextStyle), resultsTextColor), answerResultTextColor), percentageResultTextStyle),
|
|
393
396
|
inline: true,
|
|
394
397
|
className: styles.resultText,
|
|
395
398
|
body: "".concat(percent, "%")
|
|
@@ -592,6 +595,16 @@ var definition = {
|
|
|
592
595
|
field: {
|
|
593
596
|
type: 'graph-bar-style'
|
|
594
597
|
}
|
|
598
|
+
}, {
|
|
599
|
+
name: 'percentageResultTextStyle',
|
|
600
|
+
type: 'text-style-form',
|
|
601
|
+
label: reactIntl.defineMessage({
|
|
602
|
+
id: "4y3gAI",
|
|
603
|
+
defaultMessage: [{
|
|
604
|
+
"type": 0,
|
|
605
|
+
"value": "Result percentage text"
|
|
606
|
+
}]
|
|
607
|
+
})
|
|
595
608
|
}]
|
|
596
609
|
}, {
|
|
597
610
|
name: 'background',
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@micromag/screen-survey",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.138",
|
|
4
4
|
"description": "",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"javascript"
|
|
@@ -49,17 +49,17 @@
|
|
|
49
49
|
},
|
|
50
50
|
"dependencies": {
|
|
51
51
|
"@babel/runtime": "^7.13.10",
|
|
52
|
-
"@micromag/core": "^0.3.
|
|
53
|
-
"@micromag/data": "^0.3.
|
|
54
|
-
"@micromag/element-background": "^0.3.
|
|
55
|
-
"@micromag/element-button": "^0.3.
|
|
56
|
-
"@micromag/element-call-to-action": "^0.3.
|
|
57
|
-
"@micromag/element-container": "^0.3.
|
|
58
|
-
"@micromag/element-heading": "^0.3.
|
|
59
|
-
"@micromag/element-layout": "^0.3.
|
|
60
|
-
"@micromag/element-scroll": "^0.3.
|
|
61
|
-
"@micromag/element-text": "^0.3.
|
|
62
|
-
"@micromag/transforms": "^0.3.
|
|
52
|
+
"@micromag/core": "^0.3.138",
|
|
53
|
+
"@micromag/data": "^0.3.138",
|
|
54
|
+
"@micromag/element-background": "^0.3.138",
|
|
55
|
+
"@micromag/element-button": "^0.3.138",
|
|
56
|
+
"@micromag/element-call-to-action": "^0.3.138",
|
|
57
|
+
"@micromag/element-container": "^0.3.138",
|
|
58
|
+
"@micromag/element-heading": "^0.3.138",
|
|
59
|
+
"@micromag/element-layout": "^0.3.138",
|
|
60
|
+
"@micromag/element-scroll": "^0.3.138",
|
|
61
|
+
"@micromag/element-text": "^0.3.138",
|
|
62
|
+
"@micromag/transforms": "^0.3.138",
|
|
63
63
|
"classnames": "^2.2.6",
|
|
64
64
|
"lodash": "^4.17.21",
|
|
65
65
|
"prop-types": "^15.7.2",
|
|
@@ -69,5 +69,5 @@
|
|
|
69
69
|
"publishConfig": {
|
|
70
70
|
"access": "public"
|
|
71
71
|
},
|
|
72
|
-
"gitHead": "
|
|
72
|
+
"gitHead": "6460d58f8b915076249a11089a5f662ac11830fa"
|
|
73
73
|
}
|