From faae0430586bb72f7d16868beb87bb3a558849da Mon Sep 17 00:00:00 2001 From: DCoded <dicoded@email.com> Date: Sat, 4 Dec 2021 11:15:16 -0500 Subject: [PATCH] Minor note tweak --- src/js/Purchase.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/js/Purchase.js b/src/js/Purchase.js index 5fd892896fd..7a703288b40 100644 --- a/src/js/Purchase.js +++ b/src/js/Purchase.js @@ -24,6 +24,8 @@ globalThis.Purchase = class Purchase { const button = App.UI.DOM.makeElement("button", capFirstChar(price), ['purchase-button']); if (V.purchaseStyle === 'button') { + const note = this.note.substring(0, 5) === ' and ' ? this.note.replace(' and ', '') : this.note; + button.onclick = () => { cashX(forceNeg(this.cost), this.what); @@ -34,7 +36,7 @@ globalThis.Purchase = class Purchase { if (this.note) { tippy(button, { - content: this.note, + content: capFirstChar(note), }); } -- GitLab