@fonixtree/magic-design 2.0.35 → 2.0.36
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/assets/fonts/Trueno-Light.otf +0 -0
- package/es/assets/fonts/Trueno-Regular.otf +0 -0
- package/es/assets/fonts/TruenoBd.otf +0 -0
- package/es/assets/less/font.less +22 -0
- package/es/composite-comp/common/components/AffiliateProductItem/index.js +2 -2
- package/es/utils/currencyUtil.js +9 -2
- package/lib/assets/fonts/Trueno-Light.otf +0 -0
- package/lib/assets/fonts/Trueno-Regular.otf +0 -0
- package/lib/assets/fonts/TruenoBd.otf +0 -0
- package/lib/assets/less/font.less +22 -0
- package/lib/composite-comp/common/components/AffiliateProductItem/index.js +2 -2
- package/lib/utils/currencyUtil.js +9 -2
- package/package.json +1 -1
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/es/assets/less/font.less
CHANGED
|
@@ -45,4 +45,26 @@
|
|
|
45
45
|
src: url(../fonts/Montserrat-Bold.ttf);
|
|
46
46
|
font-weight: 700;
|
|
47
47
|
font-style: normal;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
@font-face {
|
|
51
|
+
font-family: 'Trueno';
|
|
52
|
+
src: url('../fonts/Trueno-Light.otf');
|
|
53
|
+
font-weight: 300;
|
|
54
|
+
font-style: normal;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
@font-face {
|
|
58
|
+
font-family: 'Trueno';
|
|
59
|
+
src: url('../fonts/Trueno-Regular.otf');
|
|
60
|
+
font-weight: 400;
|
|
61
|
+
font-style: normal;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
@font-face {
|
|
65
|
+
font-family: 'Trueno';
|
|
66
|
+
src: url(../fonts/TruenoBd.otf);
|
|
67
|
+
font-weight: 600;
|
|
68
|
+
font-style: normal;
|
|
69
|
+
font-display: swap;
|
|
48
70
|
}
|
|
@@ -143,7 +143,7 @@ function (_super) {
|
|
|
143
143
|
src: _iconBalance["default"]
|
|
144
144
|
}), /*#__PURE__*/_react["default"].createElement("div", {
|
|
145
145
|
className: "cashBackBox_text"
|
|
146
|
-
}, "Cashback Saldo", /*#__PURE__*/_react["default"].createElement("span", null, (0, _currencyUtil.
|
|
146
|
+
}, "Cashback Saldo", /*#__PURE__*/_react["default"].createElement("span", null, (0, _currencyUtil.formatCurrencyWithSymbolNotSpace)(data.buyCommission || 0)))), /*#__PURE__*/_react["default"].createElement("div", {
|
|
147
147
|
className: "cashBackBox_koin"
|
|
148
148
|
}, /*#__PURE__*/_react["default"].createElement("img", {
|
|
149
149
|
alt: "",
|
|
@@ -153,7 +153,7 @@ function (_super) {
|
|
|
153
153
|
}, "Cashback", /*#__PURE__*/_react["default"].createElement("span", null, (0, _currencyUtil.formatCurrency)(data.giftCommission || 0)), "Koin"))), panelProps.salesPrice.open && /*#__PURE__*/_react["default"].createElement(_components.MetaText, {
|
|
154
154
|
className: "producItemPrice",
|
|
155
155
|
data: __assign(__assign({}, panelProps.salesPrice), {
|
|
156
|
-
text: (0, _currencyUtil.
|
|
156
|
+
text: (0, _currencyUtil.formatCurrencyWithSymbolNotSpace)(data.productPrice || 0)
|
|
157
157
|
}),
|
|
158
158
|
readonly: true,
|
|
159
159
|
style: {
|
package/es/utils/currencyUtil.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.numberToFixed = exports.getPricePrefix = exports.getPrecision = exports.formatCurrencyWithSymbol = exports.formatCurrency = exports.formatBackendCurrency = exports.currencyToFont = exports.calcFloatCount = exports.addSeparators = void 0;
|
|
6
|
+
exports.numberToFixed = exports.getPricePrefix = exports.getPrecision = exports.formatCurrencyWithSymbolNotSpace = exports.formatCurrencyWithSymbol = exports.formatCurrency = exports.formatBackendCurrency = exports.currencyToFont = exports.calcFloatCount = exports.addSeparators = void 0;
|
|
7
7
|
|
|
8
8
|
var _divide = _interopRequireDefault(require("lodash/divide"));
|
|
9
9
|
|
|
@@ -105,6 +105,13 @@ var formatCurrencyWithSymbol = function formatCurrencyWithSymbol(num) {
|
|
|
105
105
|
var ret = formatCurrency(num);
|
|
106
106
|
return getPricePrefix() + " " + ret;
|
|
107
107
|
};
|
|
108
|
+
|
|
109
|
+
exports.formatCurrencyWithSymbol = formatCurrencyWithSymbol;
|
|
110
|
+
|
|
111
|
+
var formatCurrencyWithSymbolNotSpace = function formatCurrencyWithSymbolNotSpace(num) {
|
|
112
|
+
var ret = formatCurrency(num);
|
|
113
|
+
return "" + getPricePrefix() + ret;
|
|
114
|
+
};
|
|
108
115
|
/**
|
|
109
116
|
* TODO 未兼容科学计数法(小数点后7位)
|
|
110
117
|
* 计算浮点位数
|
|
@@ -113,7 +120,7 @@ var formatCurrencyWithSymbol = function formatCurrencyWithSymbol(num) {
|
|
|
113
120
|
*/
|
|
114
121
|
|
|
115
122
|
|
|
116
|
-
exports.
|
|
123
|
+
exports.formatCurrencyWithSymbolNotSpace = formatCurrencyWithSymbolNotSpace;
|
|
117
124
|
|
|
118
125
|
var calcFloatCount = function calcFloatCount(number) {
|
|
119
126
|
var numbString = String(number);
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -45,4 +45,26 @@
|
|
|
45
45
|
src: url(../fonts/Montserrat-Bold.ttf);
|
|
46
46
|
font-weight: 700;
|
|
47
47
|
font-style: normal;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
@font-face {
|
|
51
|
+
font-family: 'Trueno';
|
|
52
|
+
src: url('../fonts/Trueno-Light.otf');
|
|
53
|
+
font-weight: 300;
|
|
54
|
+
font-style: normal;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
@font-face {
|
|
58
|
+
font-family: 'Trueno';
|
|
59
|
+
src: url('../fonts/Trueno-Regular.otf');
|
|
60
|
+
font-weight: 400;
|
|
61
|
+
font-style: normal;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
@font-face {
|
|
65
|
+
font-family: 'Trueno';
|
|
66
|
+
src: url(../fonts/TruenoBd.otf);
|
|
67
|
+
font-weight: 600;
|
|
68
|
+
font-style: normal;
|
|
69
|
+
font-display: swap;
|
|
48
70
|
}
|
|
@@ -143,7 +143,7 @@ function (_super) {
|
|
|
143
143
|
src: _iconBalance["default"]
|
|
144
144
|
}), /*#__PURE__*/_react["default"].createElement("div", {
|
|
145
145
|
className: "cashBackBox_text"
|
|
146
|
-
}, "Cashback Saldo", /*#__PURE__*/_react["default"].createElement("span", null, (0, _currencyUtil.
|
|
146
|
+
}, "Cashback Saldo", /*#__PURE__*/_react["default"].createElement("span", null, (0, _currencyUtil.formatCurrencyWithSymbolNotSpace)(data.buyCommission || 0)))), /*#__PURE__*/_react["default"].createElement("div", {
|
|
147
147
|
className: "cashBackBox_koin"
|
|
148
148
|
}, /*#__PURE__*/_react["default"].createElement("img", {
|
|
149
149
|
alt: "",
|
|
@@ -153,7 +153,7 @@ function (_super) {
|
|
|
153
153
|
}, "Cashback", /*#__PURE__*/_react["default"].createElement("span", null, (0, _currencyUtil.formatCurrency)(data.giftCommission || 0)), "Koin"))), panelProps.salesPrice.open && /*#__PURE__*/_react["default"].createElement(_components.MetaText, {
|
|
154
154
|
className: "producItemPrice",
|
|
155
155
|
data: __assign(__assign({}, panelProps.salesPrice), {
|
|
156
|
-
text: (0, _currencyUtil.
|
|
156
|
+
text: (0, _currencyUtil.formatCurrencyWithSymbolNotSpace)(data.productPrice || 0)
|
|
157
157
|
}),
|
|
158
158
|
readonly: true,
|
|
159
159
|
style: {
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.numberToFixed = exports.getPricePrefix = exports.getPrecision = exports.formatCurrencyWithSymbol = exports.formatCurrency = exports.formatBackendCurrency = exports.currencyToFont = exports.calcFloatCount = exports.addSeparators = void 0;
|
|
6
|
+
exports.numberToFixed = exports.getPricePrefix = exports.getPrecision = exports.formatCurrencyWithSymbolNotSpace = exports.formatCurrencyWithSymbol = exports.formatCurrency = exports.formatBackendCurrency = exports.currencyToFont = exports.calcFloatCount = exports.addSeparators = void 0;
|
|
7
7
|
|
|
8
8
|
var _divide = _interopRequireDefault(require("lodash/divide"));
|
|
9
9
|
|
|
@@ -105,6 +105,13 @@ var formatCurrencyWithSymbol = function formatCurrencyWithSymbol(num) {
|
|
|
105
105
|
var ret = formatCurrency(num);
|
|
106
106
|
return getPricePrefix() + " " + ret;
|
|
107
107
|
};
|
|
108
|
+
|
|
109
|
+
exports.formatCurrencyWithSymbol = formatCurrencyWithSymbol;
|
|
110
|
+
|
|
111
|
+
var formatCurrencyWithSymbolNotSpace = function formatCurrencyWithSymbolNotSpace(num) {
|
|
112
|
+
var ret = formatCurrency(num);
|
|
113
|
+
return "" + getPricePrefix() + ret;
|
|
114
|
+
};
|
|
108
115
|
/**
|
|
109
116
|
* TODO 未兼容科学计数法(小数点后7位)
|
|
110
117
|
* 计算浮点位数
|
|
@@ -113,7 +120,7 @@ var formatCurrencyWithSymbol = function formatCurrencyWithSymbol(num) {
|
|
|
113
120
|
*/
|
|
114
121
|
|
|
115
122
|
|
|
116
|
-
exports.
|
|
123
|
+
exports.formatCurrencyWithSymbolNotSpace = formatCurrencyWithSymbolNotSpace;
|
|
117
124
|
|
|
118
125
|
var calcFloatCount = function calcFloatCount(number) {
|
|
119
126
|
var numbString = String(number);
|