From a6e863d4d2068c46c80e1223a06f4ace2bcc4c8b Mon Sep 17 00:00:00 2001 From: TehBrian Date: Sat, 2 Nov 2024 15:51:26 -0400 Subject: [PATCH] switch to currency.js for money --- package-lock.json | 17 +++++++----- package.json | 2 +- src/lib/Stage1.svelte | 60 +++++++++++++++++++++---------------------- src/lib/format.ts | 8 +++--- 4 files changed, 45 insertions(+), 42 deletions(-) diff --git a/package-lock.json b/package-lock.json index 0db3085..e69b288 100644 --- a/package-lock.json +++ b/package-lock.json @@ -11,7 +11,7 @@ "@sveltejs/adapter-static": "^3.0.6", "@sveltejs/kit": "^2.0.0", "@sveltejs/vite-plugin-svelte": "^4.0.0", - "decimal.js": "^10.4.3", + "currency.js": "^2.0.4", "lz-string": "^1.5.0", "sass": "^1.77.8", "svelte": "^5.0.0-next.191", @@ -1737,6 +1737,15 @@ "node": ">=4" } }, + "node_modules/currency.js": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/currency.js/-/currency.js-2.0.4.tgz", + "integrity": "sha512-6/OplJYgJ0RUlli74d93HJ/OsKVBi8lB1+Z6eJYS1YZzBuIp4qKKHpJ7ad+GvTlWmLR/hLJOWTykN5Nm8NJ7+w==", + "license": "MIT", + "engines": { + "node": ">=4" + } + }, "node_modules/debug": { "version": "4.3.7", "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.7.tgz", @@ -1754,12 +1763,6 @@ } } }, - "node_modules/decimal.js": { - "version": "10.4.3", - "resolved": "https://registry.npmjs.org/decimal.js/-/decimal.js-10.4.3.tgz", - "integrity": "sha512-VBBaLc1MgL5XpzgIP7ny5Z6Nx3UrRkIViUkPUdtl9aya5amy3De1gsUUSB1g3+3sExYNjCAsAznmukyxCb1GRA==", - "license": "MIT" - }, "node_modules/deep-is": { "version": "0.1.4", "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz", diff --git a/package.json b/package.json index fb1e9d1..0ab42cf 100644 --- a/package.json +++ b/package.json @@ -15,7 +15,7 @@ "@sveltejs/adapter-static": "^3.0.6", "@sveltejs/kit": "^2.0.0", "@sveltejs/vite-plugin-svelte": "^4.0.0", - "decimal.js": "^10.4.3", + "currency.js": "^2.0.4", "lz-string": "^1.5.0", "sass": "^1.77.8", "svelte": "^5.0.0-next.191", diff --git a/src/lib/Stage1.svelte b/src/lib/Stage1.svelte index aa0061b..ebed266 100644 --- a/src/lib/Stage1.svelte +++ b/src/lib/Stage1.svelte @@ -1,13 +1,13 @@