Fix issue with underscore in status

Signed-off-by: Benny Samir Hierl <bennysamir@posteo.de>
This commit is contained in:
Benny Samir Hierl 2020-11-14 11:39:02 +01:00
parent 340a79107a
commit 3da3865dd0
No known key found for this signature in database
GPG key ID: 69DE3C3C097DB7F7
2 changed files with 6 additions and 4 deletions

View file

@ -302,9 +302,9 @@ if (!orderDetails) {
progressStack.spacing = 3 progressStack.spacing = 3
if (itemStatusTracker['d']['currentStatus']) { if (itemStatusTracker['d']['currentStatus']) {
const statusText = progressStack.addText(`STATUS: ${itemStatusTracker['d']['currentStatus']}`) const statusText = progressStack.addText(`${itemStatusTracker['d']['currentStatus'].replace(/_/g, ' ')}`)
statusText.textColor = Color.black() statusText.textColor = Color.black()
statusText.font = Font.thinSystemFont(8) statusText.font = Font.regularSystemFont(8)
} }
progressStack.addImage(creatProgress(total, daysGone)) progressStack.addImage(creatProgress(total, daysGone))
@ -314,14 +314,14 @@ if (!orderDetails) {
const orderDateText = footerStack.addText(orderDate.toLocaleDateString()) const orderDateText = footerStack.addText(orderDate.toLocaleDateString())
orderDateText.textColor = Color.black() orderDateText.textColor = Color.black()
orderDateText.font = Font.thinSystemFont(8) orderDateText.font = Font.regularSystemFont(8)
orderDateText.lineLimit = 1 orderDateText.lineLimit = 1
footerStack.addSpacer() footerStack.addSpacer()
const deliveryDateText = footerStack.addText(deliveryDate.toLocaleDateString()) const deliveryDateText = footerStack.addText(deliveryDate.toLocaleDateString())
deliveryDateText.textColor = Color.black() deliveryDateText.textColor = Color.black()
deliveryDateText.font = Font.thinSystemFont(8) deliveryDateText.font = Font.regularSystemFont(8)
deliveryDateText.lineLimit = 1 deliveryDateText.lineLimit = 1
} else { } else {
widget.addSpacer() widget.addSpacer()

View file

@ -1,3 +1,5 @@
1.0.7
- Fix issue with underscore in status
1.0.6 1.0.6
- Show status - Show status
1.0.5 1.0.5