mirror of
https://code.forgejo.org/actions/setup-node.git
synced 2025-05-21 05:24:45 +00:00
.
This commit is contained in:
parent
00c3b50fca
commit
ae5dcb46c8
7331 changed files with 1784502 additions and 0 deletions
28
node_modules/prompts/lib/dateparts/milliseconds.js
generated
vendored
Normal file
28
node_modules/prompts/lib/dateparts/milliseconds.js
generated
vendored
Normal file
|
@ -0,0 +1,28 @@
|
|||
'use strict';
|
||||
|
||||
const DatePart = require('./datepart');
|
||||
|
||||
class Milliseconds extends DatePart {
|
||||
constructor(opts={}) {
|
||||
super(opts);
|
||||
}
|
||||
|
||||
up() {
|
||||
this.date.setMilliseconds(this.date.getMilliseconds() + 1);
|
||||
}
|
||||
|
||||
down() {
|
||||
this.date.setMilliseconds(this.date.getMilliseconds() - 1);
|
||||
}
|
||||
|
||||
setTo(val) {
|
||||
this.date.setMilliseconds(parseInt(val.substr(-(this.token.length))));
|
||||
}
|
||||
|
||||
toString() {
|
||||
return String(this.date.getMilliseconds()).padStart(4, '0')
|
||||
.substr(0, this.token.length);
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = Milliseconds;
|
Loading…
Add table
Add a link
Reference in a new issue