@barchart/portfolio-api-common 1.0.154 → 1.0.155
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.
|
@@ -170,8 +170,11 @@ module.exports = (() => {
|
|
|
170
170
|
this._dataFormat.quoteTime = this._dataActual.quoteTime;
|
|
171
171
|
this._dataFormat.quoteVolume = formatNumber(this._dataActual.quoteVolume, 0);
|
|
172
172
|
|
|
173
|
-
|
|
174
|
-
this.
|
|
173
|
+
const quoteChangePositive = is.number(this._dataActual.quoteChange) && this._dataActual.quoteChange.getIsPositive() > 0;
|
|
174
|
+
const quoteChangeNegative = is.number(this._dataActual.quoteChange) && this._dataActual.quoteChange.getIsPositive() < 0;
|
|
175
|
+
|
|
176
|
+
setTimeout(() => this._dataFormat.quoteChangeDirection = { up: quoteChangePositive, down: quoteChangeNegative }, 0);
|
|
177
|
+
this._dataFormat.quoteChangeNegative = quoteChangeNegative;
|
|
175
178
|
} else {
|
|
176
179
|
this._dataActual.currentPrice = null;
|
|
177
180
|
this._dataFormat.currentPrice = null;
|
package/package.json
CHANGED
package/test/SpecRunner.js
CHANGED
|
@@ -1415,8 +1415,11 @@ module.exports = (() => {
|
|
|
1415
1415
|
this._dataFormat.quoteTime = this._dataActual.quoteTime;
|
|
1416
1416
|
this._dataFormat.quoteVolume = formatNumber(this._dataActual.quoteVolume, 0);
|
|
1417
1417
|
|
|
1418
|
-
|
|
1419
|
-
this.
|
|
1418
|
+
const quoteChangePositive = is.number(this._dataActual.quoteChange) && this._dataActual.quoteChange.getIsPositive() > 0;
|
|
1419
|
+
const quoteChangeNegative = is.number(this._dataActual.quoteChange) && this._dataActual.quoteChange.getIsPositive() < 0;
|
|
1420
|
+
|
|
1421
|
+
setTimeout(() => this._dataFormat.quoteChangeDirection = { up: quoteChangePositive, down: quoteChangeNegative }, 0);
|
|
1422
|
+
this._dataFormat.quoteChangeNegative = quoteChangeNegative;
|
|
1420
1423
|
} else {
|
|
1421
1424
|
this._dataActual.currentPrice = null;
|
|
1422
1425
|
this._dataFormat.currentPrice = null;
|