aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2026-06-15 11:38:08 -0700
committerAdam Soltys <[email protected]>2026-06-15 11:38:08 -0700
commit13d72fa27c709ed3511365e070ee1b8c86a961a9 (patch)
tree7c33219c5671c727ac1c4c3a522eba69fe27e485 /src
parentae82b671afc9304ad6bf33f34d344dcc52c6caac (diff)
downloadcoinosv3-13d72fa27c709ed3511365e070ee1b8c86a961a9.tar.gz
coinosv3-13d72fa27c709ed3511365e070ee1b8c86a961a9.zip
Default to sats unit for first-time users
Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
Diffstat (limited to 'src')
-rw-r--r--src/app.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/app.js b/src/app.js
index a298fad..5f1f412 100644
--- a/src/app.js
+++ b/src/app.js
@@ -125,10 +125,11 @@ function copyBtn(text, label = 'Copy') {
// logouts. Every unit label on the site is clickable to toggle it.
const UNIT_KEY = 'btc-wallet-unit';
let unit = (() => {
+ // Default to sats for first-time users; only an explicit 'btc' choice sticks.
try {
- return localStorage.getItem(UNIT_KEY) === 'sats' ? 'sats' : 'btc';
+ return localStorage.getItem(UNIT_KEY) === 'btc' ? 'btc' : 'sats';
} catch {
- return 'btc';
+ return 'sats';
}
})();