Skip to content

Releases: smartemailing/types

Version 2.0.0

25 Nov 08:42
Compare
Choose a tag to compare
  • drop support for PHP 7.4 and 8.0 (bc break)
  • PHP Stan improvements

Version 1.2.0

12 Oct 08:51
c932676
Compare
Choose a tag to compare
  • drop support for PHP 7.2 and 7.3 (bc break)
  • support form PHP 8.0 and 8.1
  • new type \SmartEmailing\Types\ContentType

Version 1.1.0

25 May 18:37
0399cb4
Compare
Choose a tag to compare

Dependencies:

  • Dropped support for PHP 7.1
  • Removed consistence/consistence
  • Added egulias/email-validator

Classes:

  • Added class NonEmptyString, HostName, DomainName
  • Added primitive type extractors IntType, FloatType, StringType, BoolType, IntArray, FloatArray, StringArray, BoolArray
  • Improved UrlType
  • Improved Emailaddress and PhoneNumber validation
  • Unified extracting API using ExtractableTypeInterface
  • Added missing countries in CountryCode enum

Helpers:

  • Added StringHelpers::sanitizeUtf8Mb4 and StringHelpers::sanitizeUtf8Mb4OrNull
  • Added CountryCodeToPhoneCodeTable

Deprecations:

  • PrimitiveTypes
  • Domain

Updated code style.

Thanks to @mstrouhal, @cezam, @slischka, @aleswita 🎉

Version 1.0.12

31 Jan 18:32
ffac25b
Compare
Choose a tag to compare

Fixes:

  • JsonString throws correct exception on failure

Improvements:

  • bool can now be extracted from 'true' and 'false' strings

Worth mentioning:

  • added tests for multiple PHP versions
  • tests migrated to GitHub Actions

Thanks @aleswita

Version 1.0.11

07 Nov 09:48
df8a03b
Compare
Choose a tag to compare

Fixes:

  • Fixed Dates and DateTimes validation

Added value objects:

  • UnsignedFloat

Added extractors:

  • Arrays::getFloatArray
  • Arrays::getFloatArrayOrNull
  • Arrays::extractFloatArray
  • Arrays::extractFloatArrayOrNull

Improvements:

  • Duration API allows extract from array or string
  • Improved API consistency for extracting arrays

Version 1.0.10

16 Aug 13:26
3968759
Compare
Choose a tag to compare

New Minor version here, thanks @aleswita @slischka @cezam @kotmic

Features

  • DateTime features can now work with microseconds
  • HttpMethod enum added
  • KeyValuePair composite-type added
  • ...and other minor tweaks and bugfixes

Version 1.0.9

13 Jan 16:27
Compare
Choose a tag to compare

Bump, new minor release here!

Bugfixes

  • Fixed error when only 1 array is sent to intersect array methods

Dependencies

  • consistence/consistence dependency version constraint changed to ^1.0 || ^2.0

Minor changes

  • added Arrays::getIntArray(), Arrays::getStringArray(), Arrays::extractIntArrayOrNull(), Arrays::extractStringArrayOrNull() methods
  • PrimitiveTypes::extractStringArray() and PrimitiveTypes::extractStringArray() moved to Arrays class (with backwards compatibility)

Country code:

  • Added country code for Norway

Version 1.0.8

06 Aug 11:41
Compare
Choose a tag to compare

Bump, new minor release here! Thanks @slischka for big help.

Country code:

  • Added country code for Russia

Phone number:

  • Added IL phone number support, added US EIN support

UrlType:

  • added UrlType::withHost() method
  • added UrlType::withScheme() method
  • added UrlType::withPath() method

Primitive types

  • comma supported as decimal point in PrimitiveTypes

new meta-type: ScalarLeavesArray

  • support for multidimensional array with scalar leaves

new type extractors: Dates and DatesImmutable

new type: HexColor

Array types

  • union() and intersect() methods added to UniqueIntArray and UniqueToStringArray

Version 1.0.7

04 Dec 10:46
7d81b82
Compare
Choose a tag to compare
  • added soft-hyphen support for StringHelpers::removeWhitespace
  • nette 3.0 support
  • added Quantity type
  • added get<Type>OrNull methods to PrimitiveTypes class

Version 1.0.6

16 Oct 19:07
d331899
Compare
Choose a tag to compare
  • All ToStringTrait usages now implement ToStringInterface
  • Polish company registration number support
  • minor bugfixes