@kizmann/pico-js 0.4.7 → 0.4.8

Sign up to get free protection for your applications and to get access to all the features.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kizmann/pico-js",
3
- "version": "0.4.7",
3
+ "version": "0.4.8",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "private": false,
@@ -5,7 +5,7 @@ export class Now
5
5
  initialDate = null;
6
6
  moment = null;
7
7
 
8
- constructor(date = null, format = 'YYYY-MM-DD hh:mm:ss')
8
+ constructor(date = null, format = 'YYYY-MM-DD HH:mm:ss')
9
9
  {
10
10
  if ( ! global.moment ) {
11
11
  throw new Error('Moment.js is required for pi.Now');
@@ -79,7 +79,7 @@ export class Now
79
79
  return this;
80
80
  }
81
81
 
82
- static make(date = null, format = 'YYYY-MM-DD hh:mm:ss')
82
+ static make(date = null, format = 'YYYY-MM-DD HH:mm:ss')
83
83
  {
84
84
  return new Now(date, format);
85
85
  }
@@ -105,7 +105,7 @@ export class Now
105
105
  return Num.int(this.format(format, true));
106
106
  }
107
107
 
108
- format(format = 'YYYY-MM-DD hh:mm:ss', force = false)
108
+ format(format = 'YYYY-MM-DD HH:mm:ss', force = false)
109
109
  {
110
110
  if ( ! this.valid() && ! force ) {
111
111
  return '';
@@ -127,8 +127,8 @@ export class Now
127
127
 
128
128
  beforeTime(before = null)
129
129
  {
130
- return this.code('hhmmss') <
131
- Now.make(before).code('hhmmss');
130
+ return this.code('HHmmss') <
131
+ Now.make(before).code('HHmmss');
132
132
  }
133
133
 
134
134
  after(after = null)
@@ -144,8 +144,8 @@ export class Now
144
144
 
145
145
  afterTime(after = null)
146
146
  {
147
- return this.code('hhmmss') >
148
- Now.make(after).code('hhmmss');
147
+ return this.code('HHmmss') >
148
+ Now.make(after).code('HHmmss');
149
149
  }
150
150
 
151
151
  equal(equal = null, format = 'X')
@@ -159,7 +159,7 @@ export class Now
159
159
  return this.equal(equal, format);
160
160
  }
161
161
 
162
- equalTime(equal = null, format = 'hhmmss')
162
+ equalTime(equal = null, format = 'HHmmss')
163
163
  {
164
164
  return this.equal(equal, format);
165
165
  }
@@ -519,7 +519,7 @@ export class Now
519
519
  return this;
520
520
  }
521
521
 
522
- applyDate(now, format = 'YYYY-MM-DD hh:mm:ss')
522
+ applyDate(now, format = 'YYYY-MM-DD HH:mm:ss')
523
523
  {
524
524
  now = Now.make(now, format);
525
525
 
@@ -528,7 +528,7 @@ export class Now
528
528
  this.date(now.date());
529
529
  }
530
530
 
531
- applyTime(now, format = 'YYYY-MM-DD hh:mm:ss')
531
+ applyTime(now, format = 'YYYY-MM-DD HH:mm:ss')
532
532
  {
533
533
  now = Now.make(now, format);
534
534