mirror of
https://code.forgejo.org/actions/setup-node.git
synced 2025-05-20 21:14: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/seconds.js
generated
vendored
Normal file
28
node_modules/prompts/lib/dateparts/seconds.js
generated
vendored
Normal file
|
@ -0,0 +1,28 @@
|
|||
'use strict';
|
||||
|
||||
const DatePart = require('./datepart');
|
||||
|
||||
class Seconds extends DatePart {
|
||||
constructor(opts={}) {
|
||||
super(opts);
|
||||
}
|
||||
|
||||
up() {
|
||||
this.date.setSeconds(this.date.getSeconds() + 1);
|
||||
}
|
||||
|
||||
down() {
|
||||
this.date.setSeconds(this.date.getSeconds() - 1);
|
||||
}
|
||||
|
||||
setTo(val) {
|
||||
this.date.setSeconds(parseInt(val.substr(-2)));
|
||||
}
|
||||
|
||||
toString() {
|
||||
let s = this.date.getSeconds();
|
||||
return this.token.length > 1 ? String(s).padStart(2, '0') : s;
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = Seconds;
|
Loading…
Add table
Add a link
Reference in a new issue