@js-joda/core 5.6.4 → 5.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/js-joda.cjs.js +15 -3
- package/dist/js-joda.cjs.js.map +1 -1
- package/dist/js-joda.esm.js +15 -3
- package/dist/js-joda.esm.js.map +1 -1
- package/dist/js-joda.js +15 -3
- package/dist/js-joda.js.map +1 -1
- package/dist/js-joda.min.js +2 -2
- package/package.json +3 -2
- package/src/Duration.js +63 -0
- package/src/zone/ZoneRulesProvider.js +5 -3
- package/typings/js-joda.d.ts +5 -1
- package/typings/js-joda.flow.js +5 -1
package/dist/js-joda.esm.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
//! @version @js-joda/core - 5.
|
|
1
|
+
//! @version @js-joda/core - 5.7.0
|
|
2
2
|
//! @copyright (c) 2015-present, Philipp Thürwächter, Pattrick Hüper & js-joda contributors
|
|
3
3
|
//! @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
|
|
4
4
|
//! @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
|
|
@@ -731,6 +731,18 @@ var Duration = function (_TemporalAmount) {
|
|
|
731
731
|
totalNanos = MathUtil.safeAdd(totalNanos, this._nanos);
|
|
732
732
|
return totalNanos;
|
|
733
733
|
};
|
|
734
|
+
_proto.toHoursPart = function toHoursPart() {
|
|
735
|
+
return MathUtil.intMod(this.toHours(), LocalTime.HOURS_PER_DAY);
|
|
736
|
+
};
|
|
737
|
+
_proto.toMinutesPart = function toMinutesPart() {
|
|
738
|
+
return MathUtil.intMod(this.toMinutes(), LocalTime.MINUTES_PER_HOUR);
|
|
739
|
+
};
|
|
740
|
+
_proto.toSecondsPart = function toSecondsPart() {
|
|
741
|
+
return MathUtil.intMod(this._seconds, LocalTime.SECONDS_PER_MINUTE);
|
|
742
|
+
};
|
|
743
|
+
_proto.toMillisPart = function toMillisPart() {
|
|
744
|
+
return MathUtil.intDiv(this._nanos, 1000000);
|
|
745
|
+
};
|
|
734
746
|
_proto.compareTo = function compareTo(otherDuration) {
|
|
735
747
|
requireNonNull(otherDuration, 'otherDuration');
|
|
736
748
|
requireInstance(otherDuration, Duration, 'otherDuration');
|
|
@@ -4402,8 +4414,8 @@ var StringLiteralPrinterParser = function () {
|
|
|
4402
4414
|
|
|
4403
4415
|
var ZoneRulesProvider = function () {
|
|
4404
4416
|
function ZoneRulesProvider() {}
|
|
4405
|
-
ZoneRulesProvider.getRules = function getRules(
|
|
4406
|
-
throw new DateTimeException(
|
|
4417
|
+
ZoneRulesProvider.getRules = function getRules(_zoneId) {
|
|
4418
|
+
throw new DateTimeException('@js-joda/timezone not imported');
|
|
4407
4419
|
};
|
|
4408
4420
|
ZoneRulesProvider.getAvailableZoneIds = function getAvailableZoneIds() {
|
|
4409
4421
|
return [];
|