mirror of
https://github.com/aljazceru/satshkd-vercel.git
synced 2025-12-16 20:54:23 +01:00
Change date format to European (DD/MM/YYYY) and add explanation for sats
- Updated date formatting in calculate.js to use 'en-GB' locale for European date format (DD/MM/YYYY) - Added explanatory text "(smallest unit of Bitcoin)" next to "sats" in the main heading
This commit is contained in:
@@ -80,7 +80,7 @@ module.exports = {
|
||||
year = date.getFullYear();
|
||||
rawsat = hist_entries[v]['sateur_rate']
|
||||
percentage = (-100 * ((rawsat - today_sats) / rawsat)).toFixed(3)
|
||||
final_list.push({ "year": date.toLocaleDateString(), "sats": rawsat.toLocaleString("en-US"), "percent": percentage });
|
||||
final_list.push({ "year": date.toLocaleDateString('en-GB'), "sats": rawsat.toLocaleString("en-US"), "percent": percentage });
|
||||
}
|
||||
return final_list
|
||||
} catch (error) {
|
||||
|
||||
@@ -46,7 +46,7 @@
|
||||
<div class="container" style="margin-top: 20px;">
|
||||
<div class="row">
|
||||
<center>
|
||||
<h3> {{ Title }} <span id="current"></span> sats</h3>
|
||||
<h3> {{ Title }} <span id="current"></span> sats <small>(smallest unit of Bitcoin)</small></h3>
|
||||
</center>
|
||||
<script>
|
||||
var currentPrice = 0;
|
||||
|
||||
Reference in New Issue
Block a user