From 1bcc5022c27fff2c28c38b3db12ac353cc7d3481 Mon Sep 17 00:00:00 2001 From: Florian Dold Date: Tue, 12 Dec 2017 15:38:03 +0100 Subject: show tip in history --- src/webex/pages/popup.tsx | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'src/webex') diff --git a/src/webex/pages/popup.tsx b/src/webex/pages/popup.tsx index 82f3eddaa..389be3b5c 100644 --- a/src/webex/pages/popup.tsx +++ b/src/webex/pages/popup.tsx @@ -401,6 +401,18 @@ function formatHistoryItem(historyItem: HistoryRecord) { ); } + case "tip": { + const tipPageUrl = new URI(chrome.extension.getURL("/src/webex/pages/tip.html")); + const params = { tip_id: d.tipId, merchant_domain: d.merchantDomain }; + const url = tipPageUrl.query(params).href(); + return ( + + Merchant {d.merchantDomain} gave a tip of {renderAmount(d.amount)}. + + {d.accepted ? null : You did not accepted the tip yet. } + + ); + } default: return (

{i18n.str`Unknown event (${historyItem.type})`}

); } -- cgit v1.2.3