@naturalcycles/time-lib
Advanced tools
Comparing version 1.8.0 to 1.9.0
@@ -0,1 +1,8 @@ | ||
# [1.9.0](https://github.com/NaturalCycles/time-lib/compare/v1.8.0...v1.9.0) (2020-02-24) | ||
### Features | ||
* ms() to round hours after 24h ([4716cc3](https://github.com/NaturalCycles/time-lib/commit/4716cc3c4b5e937bee77367de5b116bacbfbfd0d)) | ||
# [1.8.0](https://github.com/NaturalCycles/time-lib/compare/v1.7.0...v1.8.0) (2020-02-10) | ||
@@ -2,0 +9,0 @@ |
@@ -34,5 +34,8 @@ export const TS_2018_06_21 = 1529539200; | ||
} | ||
// >= 1hr | ||
return `${hrs}h${min}m${sec}s`; | ||
if (hrs < 24) { | ||
return `${hrs}h${min}m`; | ||
} | ||
// >= 24h | ||
return `${Math.round(hrs + min / 60)}h`; | ||
} | ||
//# sourceMappingURL=time.util.js.map |
@@ -37,6 +37,9 @@ "use strict"; | ||
} | ||
// >= 1hr | ||
return `${hrs}h${min}m${sec}s`; | ||
if (hrs < 24) { | ||
return `${hrs}h${min}m`; | ||
} | ||
// >= 24h | ||
return `${Math.round(hrs + min / 60)}h`; | ||
} | ||
exports.ms = ms; | ||
//# sourceMappingURL=time.util.js.map |
@@ -10,3 +10,3 @@ { | ||
"devDependencies": { | ||
"@naturalcycles/dev-lib": "^9.0.2", | ||
"@naturalcycles/dev-lib": "^10.2.0", | ||
"@naturalcycles/js-lib": "^8.2.1", | ||
@@ -43,3 +43,3 @@ "@naturalcycles/test-lib": "^1.0.0", | ||
}, | ||
"version": "1.8.0", | ||
"version": "1.9.0", | ||
"description": "Date/time related API, based on DayJS", | ||
@@ -46,0 +46,0 @@ "keywords": [ |
@@ -38,4 +38,8 @@ export const TS_2018_06_21 = 1529539200 | ||
// >= 1hr | ||
return `${hrs}h${min}m${sec}s` | ||
if (hrs < 24) { | ||
return `${hrs}h${min}m` | ||
} | ||
// >= 24h | ||
return `${Math.round(hrs + min / 60)}h` | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
40892
661