From d82b22547d26613a3b102ff727846610dc3eaeed Mon Sep 17 00:00:00 2001 From: tomiir Date: Mon, 12 Feb 2024 16:20:40 -0600 Subject: [PATCH] fix: use short date instead of time from current date --- package-lock.json | 23 +++++++++++-------- .../views/w3m-onramp-activity-view/index.ts | 3 ++- .../wui-onramp-activity-item/index.ts | 1 + 3 files changed, 16 insertions(+), 11 deletions(-) diff --git a/package-lock.json b/package-lock.json index 4cd38664a0..e96d3154bf 100644 --- a/package-lock.json +++ b/package-lock.json @@ -16762,17 +16762,20 @@ } }, "node_modules/define-data-property": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.2.tgz", - "integrity": "sha512-SRtsSqsDbgpJBbW3pABMCOt6rQyeM8s8RiyeSN8jYG8sYmt/kGJejbydttUsnDs1tadr19tvhT4ShwMyoqAm4g==", + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.3.tgz", + "integrity": "sha512-h3GBouC+RPtNX2N0hHVLo2ZwPYurq8mLmXpOLTsw71gr7lHt5VaI4vVkDUNOfiWmm48JEXe3VM7PmLX45AMmmg==", "dependencies": { "es-errors": "^1.3.0", - "get-intrinsic": "^1.2.2", + "get-intrinsic": "^1.2.4", "gopd": "^1.0.1", "has-property-descriptors": "^1.0.1" }, "engines": { "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, "node_modules/define-lazy-prop": { @@ -17098,9 +17101,9 @@ } }, "node_modules/electron-to-chromium": { - "version": "1.4.665", - "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.665.tgz", - "integrity": "sha512-UpyCWObBoD+nSZgOC2ToaIdZB0r9GhqT2WahPKiSki6ckkSuKhQNso8V2PrFcHBMleI/eqbKgVQgVC4Wni4ilw==" + "version": "1.4.666", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.666.tgz", + "integrity": "sha512-q4lkcbQrUdlzWCUOxk6fwEza6bNCfV12oi4AJph5UibguD1aTfL4uD0nuzFv9hbPANXQMuUS0MxPSHQ1gqq5dg==" }, "node_modules/elliptic": { "version": "6.5.4", @@ -21757,9 +21760,9 @@ } }, "node_modules/lazy-universal-dotenv/node_modules/dotenv": { - "version": "16.4.2", - "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-16.4.2.tgz", - "integrity": "sha512-rZSSFxke7d9nYQ5NeMIwp5PP+f8wXgKNljpOb7KtH6SKW1cEqcXAz9VSJYVLKe7Jhup/gUYOkaeSVyK8GJ+nBg==", + "version": "16.4.3", + "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-16.4.3.tgz", + "integrity": "sha512-II98GFrje5psQTSve0E7bnwMFybNLqT8Vu8JIFWRjsE3khyNUm/loZupuy5DVzG2IXf/ysxvrixYOQnM6mjD3A==", "engines": { "node": ">=12" }, diff --git a/packages/scaffold/src/views/w3m-onramp-activity-view/index.ts b/packages/scaffold/src/views/w3m-onramp-activity-view/index.ts index fb9ebfb5df..103ae79387 100644 --- a/packages/scaffold/src/views/w3m-onramp-activity-view/index.ts +++ b/packages/scaffold/src/views/w3m-onramp-activity-view/index.ts @@ -21,6 +21,7 @@ export class W3mOnRampActivityView extends LitElement { // -- Members ------------------------------------------- // private unsubscribe: (() => void)[] = [] + private refetchTimeout: NodeJS.Timeout | undefined = undefined // -- State & Properties -------------------------------- // @@ -63,7 +64,7 @@ export class W3mOnRampActivityView extends LitElement { // -- Private ------------------------------------------- // private templateTransactions(transactions: Transaction[]) { return transactions?.map(transaction => { - const date = DateUtil.getRelativeDateFromNow(transaction.metadata.minedAt) + const date = DateUtil.formatDate(transaction?.metadata?.minedAt) const transfer = transaction.transfers[0] const fungibleInfo = transfer?.fungible_info diff --git a/packages/ui/src/composites/wui-onramp-activity-item/index.ts b/packages/ui/src/composites/wui-onramp-activity-item/index.ts index cba18d9da6..3e5bbb0f26 100644 --- a/packages/ui/src/composites/wui-onramp-activity-item/index.ts +++ b/packages/ui/src/composites/wui-onramp-activity-item/index.ts @@ -68,6 +68,7 @@ export class WuiOnRampActivityItem extends LitElement { private async fetchTokenImage() { await ApiController._fetchTokenImage(this.purchaseCurrency) } + private statusIconTemplate() { if (this.inProgress) { return null