'@istanbuljs/schema': 0.1.3
find-up: 5.0.0
foreground-child: 2.0.0
- istanbul-lib-coverage: 3.2.1
+ istanbul-lib-coverage: 3.2.2
istanbul-lib-report: 3.0.1
istanbul-reports: 3.1.6
rimraf: 3.0.2
lodash.uniqby: 4.7.0
dev: true
- /istanbul-lib-coverage@3.2.1:
- resolution: {integrity: sha512-opCrKqbthmq3SKZ10mFMQG9dk3fTa3quaOLD35kJa5ejwZHd9xAr+kLuziiZz2cG32s4lMZxNdmdcEQnTDP4+g==}
+ /istanbul-lib-coverage@3.2.2:
+ resolution: {integrity: sha512-O8dpsF+r0WV/8MNRKfnmrtCWhuKjxrq2w+jpzBL5UZKTi2LeVWnWOmWRxFlesJONmc+wLAGvKQZEOanko0LFTg==}
engines: {node: '>=8'}
dev: true
resolution: {integrity: sha512-GCfE1mtsHGOELCU8e/Z7YWzpmybrx/+dSTfLrvY8qRmaY6zXTKWn6WQIjaAFw069icm6GVMNkgu0NzI4iPZUNw==}
engines: {node: '>=10'}
dependencies:
- istanbul-lib-coverage: 3.2.1
+ istanbul-lib-coverage: 3.2.2
make-dir: 4.0.0
supports-color: 7.2.0
dev: true
export const formatDurationMilliSeconds = (duration: number): string => {
duration = convertToInt(duration);
+ if (duration < 0) {
+ throw new RangeError('Duration cannot be negative');
+ }
const days = Math.floor(duration / (24 * 3600 * 1000));
const hours = Math.floor(millisecondsToHours(duration) - days * 24);
const minutes = Math.floor(
hoursToSeconds(hours) -
minutesToSeconds(minutes),
);
- return formatDuration({
- days,
- hours,
- minutes,
- seconds,
- });
+ return formatDuration(
+ {
+ days,
+ hours,
+ minutes,
+ seconds,
+ },
+ { zero: true },
+ );
};
export const formatDurationSeconds = (duration: number): string => {
"@types/node": "^20.9.0",
"@typescript-eslint/eslint-plugin": "^6.10.0",
"@typescript-eslint/parser": "^6.10.0",
- "@vitejs/plugin-vue": "^4.4.0",
+ "@vitejs/plugin-vue": "^4.4.1",
"@vitejs/plugin-vue-jsx": "^3.0.2",
"@vitest/coverage-v8": "^0.34.6",
"@vue/eslint-config-prettier": "^8.0.0",
specifier: ^6.10.0
version: 6.10.0(eslint@8.53.0)(typescript@5.2.2)
'@vitejs/plugin-vue':
- specifier: ^4.4.0
- version: 4.4.0(vite@4.5.0)(vue@3.3.8)
+ specifier: ^4.4.1
+ version: 4.4.1(vite@4.5.0)(vue@3.3.8)
'@vitejs/plugin-vue-jsx':
specifier: ^3.0.2
version: 3.0.2(vite@4.5.0)(vue@3.3.8)
- supports-color
dev: true
- /@vitejs/plugin-vue@4.4.0(vite@4.5.0)(vue@3.3.8):
- resolution: {integrity: sha512-xdguqb+VUwiRpSg+nsc2HtbAUSGak25DXYvpQQi4RVU1Xq1uworyoH/md9Rfd8zMmPR/pSghr309QNcftUVseg==}
+ /@vitejs/plugin-vue@4.4.1(vite@4.5.0)(vue@3.3.8):
+ resolution: {integrity: sha512-HCQG8VDFDM7YDAdcj5QI5DvUi+r6xvo9LgvYdk7LSkUNwdpempdB5horkMSZsbdey9Ywsf5aaU8kEPw9M5kREA==}
engines: {node: ^14.18.0 || >=16.0.0}
peerDependencies:
vite: ^4.0.0
dependencies:
'@ampproject/remapping': 2.2.1
'@bcoe/v8-coverage': 0.2.3
- istanbul-lib-coverage: 3.2.1
+ istanbul-lib-coverage: 3.2.2
istanbul-lib-report: 3.0.1
istanbul-lib-source-maps: 4.0.1
istanbul-reports: 3.1.6
resolution: {integrity: sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==}
dev: true
- /istanbul-lib-coverage@3.2.1:
- resolution: {integrity: sha512-opCrKqbthmq3SKZ10mFMQG9dk3fTa3quaOLD35kJa5ejwZHd9xAr+kLuziiZz2cG32s4lMZxNdmdcEQnTDP4+g==}
+ /istanbul-lib-coverage@3.2.2:
+ resolution: {integrity: sha512-O8dpsF+r0WV/8MNRKfnmrtCWhuKjxrq2w+jpzBL5UZKTi2LeVWnWOmWRxFlesJONmc+wLAGvKQZEOanko0LFTg==}
engines: {node: '>=8'}
dev: true
resolution: {integrity: sha512-GCfE1mtsHGOELCU8e/Z7YWzpmybrx/+dSTfLrvY8qRmaY6zXTKWn6WQIjaAFw069icm6GVMNkgu0NzI4iPZUNw==}
engines: {node: '>=10'}
dependencies:
- istanbul-lib-coverage: 3.2.1
+ istanbul-lib-coverage: 3.2.2
make-dir: 4.0.0
supports-color: 7.2.0
dev: true
engines: {node: '>=10'}
dependencies:
debug: 4.3.4
- istanbul-lib-coverage: 3.2.1
+ istanbul-lib-coverage: 3.2.2
source-map: 0.6.1
transitivePeerDependencies:
- supports-color