Skip to content

Releases: briannesbitt/Carbon

1.28.0

22 May 08:04
00149d9
Compare
Choose a tag to compare

Complete commits list: 1.27.0...1.28.0

Summary:

  • Added isStartOfDay, isEndOfDay, isMidnight, isMidday methods
  • Added locales bs_BA, hi, is, ne, oc, sh, sw
  • Added diff translations for ca, es, nl, no, pl, sl, sr*
  • Fixed ko, pl translations
  • Fixed createFromFormat with partial format and mock now instance
  • Added make methods to Carbon and CarbonInterval
  • Added getCascadeFactors, setCascadeFactors, getFactor, getDaysPerWeek, getHoursPerDay, - getMinutesPerHours, getSecondsPerMinutes, cascade, total methods and total getters to CarbonInterval
  • Added $short argument to CarbonInterval::forHumans to display short formats

1.27.0

23 Apr 10:08
ef81c39
Compare
Choose a tag to compare

Complete commits list: 1.26.4...1.27.0

Summary:

  • Added isSameQuarter, isCurrentQuarter, isNextQuarter and isLastQuarter methods
  • Added isSameHour, isSameMinute, isSameSecond, isCurrentHour, isCurrentMinute and isCurrentSecond methods
  • Added CarbonInterval::times method
  • Added italian translation for diff words

1.26.4

17 Apr 17:24
e3d9014
Compare
Choose a tag to compare

Always pass $self at its position even if previous arguments miss

1.26.3...1.26.4

1.26.3

16 Apr 14:54
b63c0d8
Compare
Choose a tag to compare

Macro: restrict $self (PHP 5.3 helper) to this explicit name only

1.26.2...1.26.3

1.26.2

16 Apr 14:07
c0ae201
Compare
Choose a tag to compare

Change macros variable name to coexist with Laravel's one

1.26.1...1.26.2

1.26.1

16 Apr 13:30
bab61b2
Compare
Choose a tag to compare

Change macros variable name to coexist with Laravel's one

1.26.0...1.26.1

1.26.0

16 Apr 11:37
bab61b2
Compare
Choose a tag to compare

Complete commits list: 1.25.0...1.26.0

Summary:

  • Added setDateFrom and setTimeFrom methods
  • Allowed DateTimeInterface in instance method
  • Added macro, hasMacro and mixin methods
  • Added welsh language
  • Added CarbonInterval::getDateIntervalSpec (similar to CarbonInterval::spec but static and able to take any DateInterval instance as argument)
  • Added options for diffForHumans to support now/yesterday/tomorrow (#1240)

1.25.0

20 Mar 14:45
cbcf13d
Compare
Choose a tag to compare

Complete commits list: 1.24.2...1.25.0

Summary:

  • Allowed date/time strings in diffIn* and diffForHumans methods
  • Added addRealHours()/addRealHour()/subRealHours()/subRealHour() method
  • Added addRealMinutes()/addRealMinute()/subRealMinutes()/subRealMinute() method
  • Added addRealSeconds()/addRealSecond()/subRealSeconds()/subRealSecond() method
  • Added diffInRealHours() method
  • Added diffInRealMinutes() method
  • Added diffInRealSeconds() method
  • Added Carbon::createFromTimeString() method
  • Added CarbonInterval::fromString() method
  • Allowed spec string as CarbonInterval constructor and in CarbonInterval::parse()
  • Added Carbon::useMicrosecondsFallback() and Carbon::isMicrosecondsFallbackEnabled() to handle microseconds work-around in PHP < 7.1
  • Added dayOfWeekIso property
  • Allowed editing/adding languages and translations

1.24.2

12 Mar 08:01
bba6c6e
Compare
Choose a tag to compare

Prevent from negative values in microtime

Complete commits list: 1.24.1...1.24.2

1.24.1

09 Mar 15:50
ef12cbd
Compare
Choose a tag to compare

Re-align __set_state on DateTime method to ease Laravel compatibility

Complete commits list: 1.24.0...1.24.1