mirror of
https://github.com/mailcow/mailcow-dockerized.git
synced 2026-10-29 20:53:30 +00:00
[Web] Update composer libraries
This commit is contained in:
1297 files changed
+71585
-24460
No files matched your search
@@ -0,0 +1,7 @@
|
||||
# Security Policy
|
||||
|
||||
## Reporting a Vulnerability
|
||||
|
||||
To report a security vulnerability, please use the
|
||||
[Tidelift security contact](https://tidelift.com/security).
|
||||
Tidelift will coordinate the fix and disclosure.
|
||||
+24
-25
@@ -19,11 +19,11 @@
|
||||
"homepage": "https://github.com/kylekatarnls"
|
||||
}
|
||||
],
|
||||
"homepage": "https://carbon.nesbot.com",
|
||||
"homepage": "https://carbonphp.github.io/carbon/",
|
||||
"support": {
|
||||
"issues": "https://github.com/briannesbitt/Carbon/issues",
|
||||
"source": "https://github.com/briannesbitt/Carbon",
|
||||
"docs": "https://carbon.nesbot.com/docs"
|
||||
"issues": "https://github.com/CarbonPHP/carbon/issues",
|
||||
"source": "https://github.com/CarbonPHP/carbon",
|
||||
"docs": "https://carbonphp.github.io/carbon/guide/getting-started/introduction.html"
|
||||
},
|
||||
"funding": [
|
||||
{
|
||||
@@ -40,26 +40,25 @@
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"php": "^7.1.8 || ^8.0",
|
||||
"php": "^8.1",
|
||||
"ext-json": "*",
|
||||
"carbonphp/carbon-doctrine-types": "*",
|
||||
"carbonphp/carbon-doctrine-types": "<100.0",
|
||||
"psr/clock": "^1.0",
|
||||
"symfony/clock": "^6.3.12 || ^7.0 || ^8.0",
|
||||
"symfony/polyfill-mbstring": "^1.0",
|
||||
"symfony/polyfill-php80": "^1.16",
|
||||
"symfony/translation": "^3.4 || ^4.0 || ^5.0 || ^6.0"
|
||||
"symfony/polyfill-time": "^1.0",
|
||||
"symfony/translation": "^4.4.18 || ^5.2.1 || ^6.0 || ^7.0 || ^8.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"doctrine/dbal": "^2.0 || ^3.1.4 || ^4.0",
|
||||
"doctrine/orm": "^2.7 || ^3.0",
|
||||
"friendsofphp/php-cs-fixer": "^3.0",
|
||||
"kylekatarnls/multi-tester": "^2.0",
|
||||
"ondrejmirtes/better-reflection": "*",
|
||||
"phpmd/phpmd": "^2.9",
|
||||
"phpstan/extension-installer": "^1.0",
|
||||
"phpstan/phpstan": "^0.12.99 || ^1.7.14",
|
||||
"phpunit/php-file-iterator": "^2.0.5 || ^3.0.6",
|
||||
"phpunit/phpunit": "^7.5.20 || ^8.5.26 || ^9.5.20",
|
||||
"squizlabs/php_codesniffer": "^3.4"
|
||||
"doctrine/dbal": "^3.6.3 || ^4.0",
|
||||
"doctrine/orm": "^2.15.2 || ^3.0",
|
||||
"friendsofphp/php-cs-fixer": "^v3.87.1",
|
||||
"kylekatarnls/multi-tester": "^2.5.3",
|
||||
"phpmd/phpmd": "^3.0@dev",
|
||||
"phpstan/extension-installer": "^1.4.3",
|
||||
"phpstan/phpstan": "^2.1.22",
|
||||
"phpunit/phpunit": "^10.5.53",
|
||||
"squizlabs/php_codesniffer": "^3.13.4 || ^4.0.0"
|
||||
},
|
||||
"provide": {
|
||||
"psr/clock-implementation": "1.0"
|
||||
@@ -92,8 +91,8 @@
|
||||
},
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-3.x": "3.x-dev",
|
||||
"dev-master": "2.x-dev"
|
||||
"dev-master": "3.x-dev",
|
||||
"dev-2.x": "2.x-dev"
|
||||
},
|
||||
"laravel": {
|
||||
"providers": [
|
||||
@@ -109,10 +108,10 @@
|
||||
"scripts": {
|
||||
"phpcs": "php-cs-fixer fix -v --diff --dry-run",
|
||||
"phpdoc": "php phpdoc.php",
|
||||
"phpmd": "phpmd src text /phpmd.xml",
|
||||
"phpmd-test": "phpmd tests text /tests/phpmd-test.xml",
|
||||
"phpstan": "phpstan analyse --configuration phpstan.neon",
|
||||
"phpunit": "phpunit --verbose",
|
||||
"phpmd": "phpmd analyze src --format=text --ruleset=/phpmd.yml",
|
||||
"phpmd-test": "phpmd analyze tests --format=text --ruleset=/tests/phpmd-test.yml",
|
||||
"phpstan": "phpstan analyse --configuration phpstan.neon --memory-limit 1024M",
|
||||
"phpunit": "phpunit",
|
||||
"style-check": [
|
||||
"@phpcs",
|
||||
"@phpstan",
|
||||
|
||||
@@ -1,3 +1,7 @@
|
||||
parameters:
|
||||
bootstrapFiles:
|
||||
- lazy/Carbon/UnprotectedDatePeriod.php
|
||||
|
||||
services:
|
||||
-
|
||||
class: Carbon\PHPStan\MacroExtension
|
||||
|
||||
-36
@@ -1,36 +0,0 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
* (c) Brian Nesbitt <brian@nesbot.com>
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Carbon\PHPStan;
|
||||
|
||||
use PHPStan\BetterReflection\Reflection;
|
||||
use ReflectionMethod;
|
||||
|
||||
if (!class_exists(AbstractReflectionMacro::class, false)) {
|
||||
abstract class AbstractReflectionMacro extends AbstractMacro
|
||||
{
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function getReflection(): ?ReflectionMethod
|
||||
{
|
||||
if ($this->reflectionFunction instanceof Reflection\ReflectionMethod) {
|
||||
return new Reflection\Adapter\ReflectionMethod($this->reflectionFunction);
|
||||
}
|
||||
|
||||
return $this->reflectionFunction instanceof ReflectionMethod
|
||||
? $this->reflectionFunction
|
||||
: null;
|
||||
}
|
||||
}
|
||||
}
|
||||
-45
@@ -1,45 +0,0 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
* (c) Brian Nesbitt <brian@nesbot.com>
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Carbon\PHPStan;
|
||||
|
||||
use PHPStan\BetterReflection\Reflection;
|
||||
use ReflectionMethod;
|
||||
|
||||
if (!class_exists(AbstractReflectionMacro::class, false)) {
|
||||
abstract class AbstractReflectionMacro extends AbstractMacro
|
||||
{
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function getReflection(): ?Reflection\Adapter\ReflectionMethod
|
||||
{
|
||||
if ($this->reflectionFunction instanceof Reflection\Adapter\ReflectionMethod) {
|
||||
return $this->reflectionFunction;
|
||||
}
|
||||
|
||||
if ($this->reflectionFunction instanceof Reflection\ReflectionMethod) {
|
||||
return new Reflection\Adapter\ReflectionMethod($this->reflectionFunction);
|
||||
}
|
||||
|
||||
return $this->reflectionFunction instanceof ReflectionMethod
|
||||
? new Reflection\Adapter\ReflectionMethod(
|
||||
Reflection\ReflectionMethod::createFromName(
|
||||
$this->reflectionFunction->getDeclaringClass()->getName(),
|
||||
$this->reflectionFunction->getName()
|
||||
)
|
||||
)
|
||||
: null;
|
||||
}
|
||||
}
|
||||
}
|
||||
-45
@@ -1,45 +0,0 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
* (c) Brian Nesbitt <brian@nesbot.com>
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Carbon\PHPStan;
|
||||
|
||||
if (!class_exists(LazyMacro::class, false)) {
|
||||
abstract class LazyMacro extends AbstractReflectionMacro
|
||||
{
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function getFileName(): ?string
|
||||
{
|
||||
$file = $this->reflectionFunction->getFileName();
|
||||
|
||||
return (($file ? realpath($file) : null) ?: $file) ?: null;
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function getStartLine(): ?int
|
||||
{
|
||||
return $this->reflectionFunction->getStartLine();
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function getEndLine(): ?int
|
||||
{
|
||||
return $this->reflectionFunction->getEndLine();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,51 +0,0 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
* (c) Brian Nesbitt <brian@nesbot.com>
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Carbon\PHPStan;
|
||||
|
||||
if (!class_exists(LazyMacro::class, false)) {
|
||||
abstract class LazyMacro extends AbstractReflectionMacro
|
||||
{
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*
|
||||
* @return string|false
|
||||
*/
|
||||
public function getFileName()
|
||||
{
|
||||
$file = $this->reflectionFunction->getFileName();
|
||||
|
||||
return (($file ? realpath($file) : null) ?: $file) ?: null;
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*
|
||||
* @return int|false
|
||||
*/
|
||||
public function getStartLine()
|
||||
{
|
||||
return $this->reflectionFunction->getStartLine();
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*
|
||||
* @return int|false
|
||||
*/
|
||||
public function getEndLine()
|
||||
{
|
||||
return $this->reflectionFunction->getEndLine();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,73 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
* (c) Brian Nesbitt <brian@nesbot.com>
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Carbon;
|
||||
|
||||
use DatePeriod;
|
||||
|
||||
if (!class_exists(DatePeriodBase::class, false)) {
|
||||
class DatePeriodBase extends DatePeriod
|
||||
{
|
||||
/**
|
||||
* Period start in PHP < 8.2.
|
||||
*
|
||||
* @var CarbonInterface
|
||||
*
|
||||
* @deprecated PHP 8.2 this property is no longer in sync with the actual period start.
|
||||
*/
|
||||
protected $start;
|
||||
|
||||
/**
|
||||
* Period end in PHP < 8.2.
|
||||
*
|
||||
* @var CarbonInterface|null
|
||||
*
|
||||
* @deprecated PHP 8.2 this property is no longer in sync with the actual period end.
|
||||
*/
|
||||
protected $end;
|
||||
|
||||
/**
|
||||
* Period current iterated date in PHP < 8.2.
|
||||
*
|
||||
* @var CarbonInterface|null
|
||||
*
|
||||
* @deprecated PHP 8.2 this property is no longer in sync with the actual period current iterated date.
|
||||
*/
|
||||
protected $current;
|
||||
|
||||
/**
|
||||
* Period interval in PHP < 8.2.
|
||||
*
|
||||
* @var CarbonInterval|null
|
||||
*
|
||||
* @deprecated PHP 8.2 this property is no longer in sync with the actual period interval.
|
||||
*/
|
||||
protected $interval;
|
||||
|
||||
/**
|
||||
* Period recurrences in PHP < 8.2.
|
||||
*
|
||||
* @var int|float|null
|
||||
*
|
||||
* @deprecated PHP 8.2 this property is no longer in sync with the actual period recurrences.
|
||||
*/
|
||||
protected $recurrences;
|
||||
|
||||
/**
|
||||
* Period start included option in PHP < 8.2.
|
||||
*
|
||||
* @var bool
|
||||
*
|
||||
* @deprecated PHP 8.2 this property is no longer in sync with the actual period start included option.
|
||||
*/
|
||||
protected $include_start_date;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
* (c) Brian Nesbitt <brian@nesbot.com>
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Carbon;
|
||||
|
||||
use DatePeriod;
|
||||
|
||||
if (!class_exists(DatePeriodBase::class, false)) {
|
||||
class DatePeriodBase extends DatePeriod
|
||||
{
|
||||
}
|
||||
}
|
||||
+46
@@ -0,0 +1,46 @@
|
||||
# PHPMD configuration, see https://phpmd.org/documentation/creating-a-ruleset.html
|
||||
name: 'Mess detection rules for Carbon'
|
||||
description: 'Mess detection rules for Carbon'
|
||||
rules:
|
||||
- ref: rulesets/codesize.xml
|
||||
exclude:
|
||||
- CyclomaticComplexity
|
||||
- NPathComplexity
|
||||
- ExcessiveMethodLength
|
||||
- ExcessiveClassLength
|
||||
- ExcessivePublicCount
|
||||
- TooManyMethods
|
||||
- TooManyPublicMethods
|
||||
- ExcessiveClassComplexity
|
||||
- ref: rulesets/cleancode.xml
|
||||
exclude:
|
||||
- BooleanArgumentFlag
|
||||
- StaticAccess
|
||||
- IfStatementAssignment
|
||||
- UndefinedVariable
|
||||
- ErrorControlOperator
|
||||
- ref: rulesets/controversial.xml
|
||||
- ref: rulesets/design.xml
|
||||
exclude:
|
||||
- EvalExpression
|
||||
- CouplingBetweenObjects
|
||||
- CountInLoopExpression
|
||||
- DevelopmentCodeFragment
|
||||
- ref: rulesets/design.xml/DevelopmentCodeFragment
|
||||
properties:
|
||||
ignore-namespaces: 'true'
|
||||
- ref: rulesets/naming.xml
|
||||
exclude:
|
||||
- ShortVariable
|
||||
- LongVariable
|
||||
- ShortMethodName
|
||||
- ref: rulesets/naming.xml/ShortVariable
|
||||
properties:
|
||||
exceptions: 'ci,id,to,tz'
|
||||
- ref: rulesets/naming.xml/LongVariable
|
||||
properties:
|
||||
subtract-suffixes: 'Enabled,Function,Factory,Timezone,FloorEnd,DiffOptions,FromTestNow'
|
||||
- ref: rulesets/naming.xml/ShortMethodName
|
||||
properties:
|
||||
exceptions: 'eq,gt,is,lt,ne,to,tz'
|
||||
- ref: rulesets/unusedcode.xml
|
||||
+99
-51
@@ -2,11 +2,14 @@
|
||||
|
||||
[](https://packagist.org/packages/nesbot/carbon)
|
||||
[](https://packagist.org/packages/nesbot/carbon)
|
||||
[](https://github.com/briannesbitt/Carbon/actions)
|
||||
[](https://codecov.io/github/briannesbitt/Carbon?branch=master)
|
||||
[](https://tidelift.com/subscription/pkg/packagist-nesbot-carbon?utm_source=packagist-nesbot-carbon&utm_medium=referral&utm_campaign=readme)
|
||||
[](https://github.com/CarbonPHP/carbon/actions)
|
||||
[](https://codecov.io/github/CarbonPHP/carbon/actions?branch=master)
|
||||
|
||||
An international PHP extension for DateTime. [https://carbon.nesbot.com](https://carbon.nesbot.com)
|
||||
An international PHP extension for DateTime. [Documentation](https://carbonphp.github.io/carbon/)
|
||||
|
||||
> [!NOTE]
|
||||
> We're migrating the repository from [briannesbitt/Carbon](https://github.com/briannesbitt/Carbon) to [CarbonPHP/carbon](https://github.com/CarbonPHP/carbon),
|
||||
> which means if you're looking specific issues/pull-requests, you may have to search both. No other impact as code on both will be kept up to date.
|
||||
|
||||
```php
|
||||
<?php
|
||||
@@ -17,7 +20,6 @@ printf("Right now is %s", Carbon::now()->toDateTimeString());
|
||||
printf("Right now in Vancouver is %s", Carbon::now('America/Vancouver')); //implicit __toString()
|
||||
$tomorrow = Carbon::now()->addDay();
|
||||
$lastWeek = Carbon::now()->subWeek();
|
||||
$nextSummerOlympics = Carbon::createFromDate(2016)->addYears(4);
|
||||
|
||||
$officialDate = Carbon::now()->toRfc2822String();
|
||||
|
||||
@@ -50,10 +52,15 @@ echo Carbon::parse('2019-07-23 14:51')->locale('fr_FR')->isoFormat('LLLL'); // '
|
||||
// ... but also does 'from now', 'after' and 'before'
|
||||
// rolling up to seconds, minutes, hours, days, months, years
|
||||
|
||||
$daysSinceEpoch = Carbon::createFromTimestamp(0)->diffInDays();
|
||||
```
|
||||
$daysSinceEpoch = Carbon::createFromTimestamp(0)->diffInDays(); // something such as:
|
||||
// 19817.6771
|
||||
$daysUntilInternetBlowUp = $internetWillBlowUpOn->diffInDays(); // Negative value since it's in the future:
|
||||
// -5037.4560
|
||||
|
||||
[Get supported nesbot/carbon with the Tidelift Subscription](https://tidelift.com/subscription/pkg/packagist-nesbot-carbon?utm_source=packagist-nesbot-carbon&utm_medium=referral&utm_campaign=readme)
|
||||
// Without parameter, difference is calculated from now, but doing $a->diff($b)
|
||||
// it will count time from $a to $b.
|
||||
Carbon::createFromTimestamp(0)->diffInDays($internetWillBlowUpOn); // 24855.1348
|
||||
```
|
||||
|
||||
## Installation
|
||||
|
||||
@@ -66,7 +73,7 @@ $ composer require nesbot/carbon
|
||||
```json
|
||||
{
|
||||
"require": {
|
||||
"nesbot/carbon": "^2.16"
|
||||
"nesbot/carbon": "^3"
|
||||
}
|
||||
}
|
||||
```
|
||||
@@ -82,7 +89,7 @@ printf("Now: %s", Carbon::now());
|
||||
|
||||
### Without Composer
|
||||
|
||||
Why are you not using [composer](https://getcomposer.org/)? Download the Carbon [latest release](https://github.com/briannesbitt/Carbon/releases) and put the contents of the ZIP archive into a directory in your project. Then require the file `autoload.php` to get all classes and dependencies loaded on need.
|
||||
Why are you not using [composer](https://getcomposer.org/)? Download the Carbon [latest release](https://github.com/CarbonPHP/carbon/releases) and put the contents of the ZIP archive into a directory in your project. Then require the file `autoload.php` to get all classes and dependencies loaded on need.
|
||||
|
||||
```php
|
||||
<?php
|
||||
@@ -93,9 +100,9 @@ use Carbon\Carbon;
|
||||
printf("Now: %s", Carbon::now());
|
||||
```
|
||||
|
||||
## Docs
|
||||
## Documentation
|
||||
|
||||
[https://carbon.nesbot.com/docs](https://carbon.nesbot.com/docs)
|
||||
[https://carbonphp.github.io/carbon/](https://carbonphp.github.io/carbon/)
|
||||
|
||||
## Security contact information
|
||||
|
||||
@@ -109,56 +116,97 @@ Tidelift will coordinate the fix and disclosure.
|
||||
|
||||
This project exists thanks to all the people who contribute.
|
||||
|
||||
<a href="https://github.com/briannesbitt/Carbon/graphs/contributors" target="_blank"><img src="https://opencollective.com/Carbon/contributors.svg?width=890&button=false" /></a>
|
||||
<a href="https://github.com/CarbonPHP/carbon/graphs/contributors" target="_blank"><img src="https://opencollective.com/Carbon/contributors.svg?width=890&button=false" /></a>
|
||||
|
||||
### Translators
|
||||
|
||||
[Thanks to people helping us to translate Carbon in so many languages](https://carbon.nesbot.com/contribute/translators/)
|
||||
[Thanks to people helping us to translate Carbon in so many languages](https://carbonphp.github.io/carbon/develop/translations/translators.html)
|
||||
|
||||
### Sponsors
|
||||
|
||||
Support this project by becoming a sponsor. Your logo will show up here with a link to your website.
|
||||
|
||||
<a href="https://tidelift.com/subscription/pkg/packagist-nesbot-carbon?utm_source=packagist-nesbot-carbon&utm_medium=referral&utm_campaign=readme" target="_blank"><img src="https://carbon.nesbot.com/tidelift-brand.png" width="256" height="64"></a><!-- <open-collective-sponsors> -->
|
||||
<a title="Онлайн казино 777 Україна" href="https://777.ua/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Онлайн казино" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/7e572d50-1ce8-4d69-ae12-86cc80371373/ok-ua-777.png" width="64" height="64"></a>
|
||||
<a title="#1 Guide To Online Gambling In Canada" href="https://casinohex.org/canada/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="CasinoHex Canada" src="https://opencollective-production.s3.us-west-1.amazonaws.com/79fdbcc0-a997-11eb-abbc-25e48b63c6dc.jpg" width="85" height="64"></a>
|
||||
<a title="Znajdź najlepsze zakłady bukmacherskie w Polsce w 2023 roku. Probukmacher.pl to Twoje kompendium wiedzy na temat bukmacherów!" href="https://www.probukmacher.pl?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Probukmacher" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/caf50271-4560-4ffe-a434-ea15239168db/Screenshot_1.png" width="89" height="64"></a>
|
||||
<a title="Gives a fun for our users" href="https://slotoking.ua/games/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Игровые автоматы" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/94601d07-3205-4c60-9c2d-9b8194dbefb7/skg-blue.png" width="64" height="64"></a>
|
||||
<a title="Casino-portugal.pt" href="https://casino-portugal.pt/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Casino-portugal.pt" src="https://logo.clearbit.com/casino-portugal.pt" width="64" height="64"></a>
|
||||
<a title="Slots City® ➢ Лучшее лицензионно казино онлайн и оффлайн на гривны в Украине. 【 Более1500 игровых автоматов и слотов】✅ Официально и Безопасно" href="https://slotscity.ua/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Slots City" src="https://opencollective-production.s3.us-west-1.amazonaws.com/d7e298c0-7abe-11ed-8553-230872f5e54d.png" width="90" height="64"></a>
|
||||
<a title="inkedin" href="https://inkedin.com?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="inkedin" src="https://logo.clearbit.com/inkedin.com" width="64" height="64"></a>
|
||||
<a title="Актуальний та повносправний рейтинг онлайн казино України, ґрунтований на відгуках реальних гравців." href="https://uk.onlinecasino.in.ua/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Онлайн казино України" src="https://opencollective-production.s3.us-west-1.amazonaws.com/c0b4b090-eef8-11ec-9cb7-0527a205b226.png" width="64" height="64"></a>
|
||||
<a title="OnlineCasinosSpelen" href="https://onlinecasinosspelen.com?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="OnlineCasinosSpelen" src="https://logo.clearbit.com/onlinecasinosspelen.com" width="64" height="64"></a>
|
||||
<a title="Best non Gamstop sites in the UK" href="https://nongamstopcasinos.net/gb/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Best non Gamstop sites in the UK" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/34e340b8-e1de-4932-8a76-1b3ce2ec7ee8/logo_white%20bg%20(8).png" width="64" height="64"></a>
|
||||
<a title="Real Money Pokies" href="https://www.nzfirst.org.nz/real-money-pokies/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Real Money Pokies" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/30d38232-a9d6-4e95-a48c-641fdc4d96fd/NZ_logo%20(6)%20(1)%20(1).jpg" width="64" height="64"></a>
|
||||
<a title="Non GamStop Bookies UK" href="https://nongamstopbookies.com/uk/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Non GamStop Bookies UK" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/43c5561c-8907-4ef7-a4ee-c6da054788b8/logo-site%20(3).jpg" width="64" height="64"></a>
|
||||
<a title="Актуальний топ-рейтинг українських онлайн казино на гривні! Щоденне оновлення топу та унікальна система ранжування, основана на відгуках гравців!" href="https://onlinecasino.in.ua/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Онлайн Казино Украины" src="https://opencollective-production.s3.us-west-1.amazonaws.com/8fdd8aa0-e273-11ec-a95e-d38fd331cabf.png" width="64" height="64"></a>
|
||||
<a title="Twitter Video Downloader HD Tool allows you to store tweets on your device (mobile or PC) for free." href="https://ssstwitter.online/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="SSSTwitter" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/ba0d1daf-a894-4d98-95f7-a44d321364b3/Screenshot%202024-01-16%20at%2011.43.22.png" width="76" height="64"></a>
|
||||
<a title="Entertainment" href="https://www.nongamstopbets.com/casinos-not-on-gamstop/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Non-GamStop Bets UK" src="https://logo.clearbit.com/nongamstopbets.com" width="64" height="64"></a>
|
||||
<a title="Chudovo - international software development company with representative offices in Kyiv, Cologne, New York, Tallinn and London. It has been working on the market since 2006. Company has domain expertise in video security, logistics, medicine, finance and" href="https://chudovo.com/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Chudovo" src="https://opencollective-production.s3.us-west-1.amazonaws.com/326c19a0-2e87-11eb-a13a-c99a2a201d11.png" width="84" height="42"></a>
|
||||
<a title="Entertainment" href="https://casinogap.org/uk/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="UK Casino Gap" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/143f9301-beec-4118-89d5-9a07a01345f3/casinogap-uk.png" width="42" height="42"></a>
|
||||
<a title="NZ Gaming Portal" href="https://casinodeps.co.nz?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="NZ Casino Deps" src="https://logo.clearbit.com/casinodeps.co.nz" width="42" height="42"></a>
|
||||
<a title="NonStop Sites" href="https://uk.nonstopcasino.org/non-gamstop-casinos/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="NonStopCasino.org" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/fd7ad905-8752-468f-ad20-582a24cca9d9/non-stop-casino.png" width="42" height="42"></a>
|
||||
<a title="Siti Non AAMS" href="https://www.outlookindia.com/outlook-spotlight/migliori-siti-non-aams-siti-scommesse-senza-licenza-sicuri-news-294715?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Migliori Siti Non AAMS" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/392810da-6cb6-4938-a3cb-38bd0e1eb7de/migliori-siti-non-aams.png" width="42" height="42"></a>
|
||||
<a title="List of trusted non GamStop casino reviews" href="https://nongamstopcasinos.org?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="UK NonGamStopCasinos" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/cbda0ee1-26ea-4252-9580-f1f9b317b1f7/nongamstopcasinos-uk.png" width="42" height="42"></a>
|
||||
<a title="Online TikTok Video Download Tool" href="https://snaptik.pro?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="SnapTik" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/546bcd53-6615-457d-ab21-1db1c52b3af5/logo.jpg" width="42" height="42"></a>
|
||||
<a title="IG Downloader is an Instagram Downloader service that offers a variety of tools to download Instagram content for free. Listed below are all the tools" href="https://indownloader.app/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="IG Downloader" src="https://logo.clearbit.com/indownloader.app" width="42" height="42"></a>
|
||||
<a title="Proxidize is a mobile proxy creation and management platform that provides all needed components from hardware to cloud software and SIM cards." href="https://proxidize.com/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Proxidize" src="https://logo.clearbit.com/proxidize.com" width="42" height="42"></a>
|
||||
<a title="Blastup offers Instagram growth services like buying likes, views, and followers, emphasizing real user engagement and instant delivery." href="https://blastup.com/buy-instagram-likes?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Blastup" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/955a0beb-9fe8-4753-ad92-fae8ef5382fc/favicon--dark.jpg" width="42" height="42"></a>
|
||||
<a title="A self-hosted web radio management suite, including turnkey installer tools and an easy-to-use web app to manage your stations." href="https://azuracast.com?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="AzuraCast" src="https://opencollective-production.s3.us-west-1.amazonaws.com/3c12ea10-cdfb-11eb-9cf4-3760b386b76d.png" width="42" height="42"></a>
|
||||
<a title="Triplebyte is the first software engineering job platform that is on the developer's side. Take our coding quiz!" href="https://triplebyte.com/os/opencollective?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Triplebyte" src="https://opencollective-production.s3.us-west-1.amazonaws.com/43e4f9d0-30cd-11ea-9c6b-e1142996e8b2.png" width="42" height="42"></a>
|
||||
<a title="Connect your Collective to GitHub Sponsors: https://docs.opencollective.com/help/collectives/github-sponsors" href="https://github.com/sponsors/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="GitHub Sponsors" src="https://opencollective-production.s3.us-west-1.amazonaws.com/87b1d240-f617-11ea-9960-fd7e8ab20fe4.png" width="48" height="42"></a>
|
||||
<a title="Salesforce" href="https://engineering.salesforce.com?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Salesforce" src="https://opencollective-production.s3.us-west-1.amazonaws.com/24d34880-df8d-11e9-949c-6bc2037b6bd5.png" width="42" height="42"></a>
|
||||
<!-- </open-collective-sponsors> -->
|
||||
<!-- <open-collective-sponsors> -->
|
||||
<table>
|
||||
<tr>
|
||||
<td><a title="Онлайн казино 777 Україна" href="https://777ua.com.ua/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Онлайн казино 777" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/7e572d50-1ce8-4d69-ae12-86cc80371373/ok-ua-777.png" width="96" height="96"></a></td>
|
||||
<td><a title="Non GamStop Bookies UK" href="https://netto.co.uk/betting-sites-not-on-gamstop/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Non GamStop Bookies UK" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/51bfaa05-02b3-4cd9-b1a4-9d0d8f34cbae/%D0%97%D0%BD%D1%96%D0%BC%D0%BE%D0%BA%20%D0%B5%D0%BA%D1%80%D0%B0%D0%BD%D0%B0%202025-07-04%20%D0%BE%2015.21.16%20(1)%20(1)%20(1).jpg" width="126" height="96"></a></td>
|
||||
<td><a title="Trusted last mile route planning and route optimization" href="https://route4me.com/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Route4Me Route Planner" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/237386c3-48a2-47c6-97ac-5f888cdb4cda/Route4MeIconLogo.png" width="96" height="96"></a></td>
|
||||
<td><a title="Bei Releaf erhalten Sie schnell und diskret Ihr Cannabis Rezept online. Unsere Ärzte prüfen Ihre Angaben und stellen bei Eignung das Rezept aus. Anschließend können Sie legal und sicher medizinisches Cannabis über unsere Partnerapotheken kaufen." href="https://releaf.com/de?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Releaf – Medizinischer Cannabis Shop" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/b686d646-5029-4b4c-8cab-9645ab2679de/9da596d1-f48a-41ec-947d-a64dd8e7529c.png" width="96" height="96"></a></td>
|
||||
<td><a title="We specialize in the online gambling industry, helping players access reliable and verified information about the best online casinos and pokies in Australia. Our team tests casinos and games, collects user reviews from Trustpilot, and organizes them in o" href="https://au.trustpilot.com/review/bestpayidpokies.net?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="PayID Pokies" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/985a0ae7-54c3-4680-8816-bc8d656f7562/payidpokies.png" width="96" height="96"></a></td>
|
||||
<td><a title="Нова українська букмекерська контора" href="https://betking.com.ua/sports-book/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Ставки на спорт" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/c56d2fe2-f9fb-4d63-947c-77575f4b15c6/stavki.jpg" width="96" height="96"></a></td>
|
||||
<td><a title="Best non Gamstop sites in the UK" href="https://www.pieria.co.uk/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Best non Gamstop sites in the UK" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/34e340b8-e1de-4932-8a76-1b3ce2ec7ee8/logo_white%20bg%20(8).png" width="96" height="96"></a></td>
|
||||
<td><a title="#1 Guide To Online Gambling In Canada" href="https://casinohex.org/canada/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="CasinoHex Canada" src="https://opencollective-production.s3.us-west-1.amazonaws.com/79fdbcc0-a997-11eb-abbc-25e48b63c6dc.jpg" width="127.5" height="96"></a></td>
|
||||
</tr>
|
||||
</table>
|
||||
<details><summary>See more</summary>
|
||||
<table>
|
||||
<tr>
|
||||
<td><a title="OnlineCasinosSpelen" href="https://onlinecasinosspelen.com?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="OnlineCasinosSpelen" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/47e87426-6a55-4f69-9fb5-4e5032dc35a8/5d10dd22-320e-47d4-84e6-d144874f1f5f.png" width="64" height="64"></a></td>
|
||||
<td><a title="Top 10 Online Casino Australia Eu Com" href="https://au.trustpilot.com/review/top-10-online-casino-australia.eu.com?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Top 10 Online Casino Australia Eu Com" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/c87ba708-3f1c-4062-82a8-797c713646b2/trustpilot_logo%20(4).png" width="64" height="64"></a></td>
|
||||
<td><a title="We collect all reviews about the best online pokies." href="https://au.trustpilot.com/review/aussiepokies.net?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Online Pokies in Australia" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/44d84116-8762-4167-9433-a9e5da542e29/pokies.png" width="64" height="64"></a></td>
|
||||
<td><a title="marketing in germany" href="https://de.trustpilot.com/review/paysafecardcasinos.org?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Paysafecard Casino" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/1b2f45ea-02bc-4a78-a84a-355f68c8a293/paysafe.png" width="64" height="64"></a></td>
|
||||
<td><a title="Games" href="https://au.trustpilot.com/review/bestaustraliaonlinepokies.com?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Australian Online Pokies" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/7ca6ca2e-6542-4736-8952-b9adb7f4c9cf/39aac4bc53ff11f198d9ce36ed903bf5_1.jpg" width="64" height="64"></a></td>
|
||||
<td><a title="We test dozens of casinos every month and select the coolest ones for Australian players." href="https://au.trustpilot.com/review/payid-casino.net?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="PayID Pokies Sites" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/ecd8a5f4-fd86-4903-a512-cbfaff35e7ef/payidpokiessites.png" width="69" height="64"></a></td>
|
||||
<td><a title="Porównanie kasyn online w Polsce. Darmowe automaty online." href="https://onlinekasyno-polis.pl/" target="_blank"><img alt="Online Kasyno Polis" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/12fe53d4-b2e4-4601-b9ea-7b652c414a38/274px%20274px-2.png" width="64" height="64"></a></td>
|
||||
<td><a title="Uudet Nettikasinot" href="https://fi.parhaatuudetkasinot.com/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="parhaatuudetkasinot.com" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/09e109d6-8ad2-4ade-ab24-4427028c8e38/260bfa9d-6a5c-494d-9ec0-a624327429ae.png" width="64" height="64"></a></td>
|
||||
<td><a title="New Casino Bonuses" href="https://linkly.link/2pN2F?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="New Casino Bonuses" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/38e356d8-3597-406a-a263-1c348723aa17/new_casino_bonuses_logo.png" width="64" height="64"></a></td>
|
||||
<td><a title="Best online sports betting and casino company." href="https://global.fun88.com/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Fun88" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/1688ebca-4984-4b9b-a24d-8fdd1233892f/fun88-logo.png" width="64" height="64"></a></td>
|
||||
<td><a title="Top 50 Online Casinos UK" href="https://eastvillafc.co.uk?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="East Villa FC" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/2560f1b5-20d6-4cf4-83cd-2457bf111fc3/trophy-fav-blue.png" width="64" height="64"></a></td>
|
||||
<td><a title="บริษัทรับแทงบอลออนไลน์ที่ดีที่สุดในประเทศไทย" href="https://www.fun88tho.com/th/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Fun88" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/bbf7174c-fc01-4ce6-86b5-f621e350969d/fun88-logo.png" width="64" height="64"></a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><a title="Nhà cái cá cược thể thao trực tuyến tốt nhất tại Việt Nam" href="https://www.fun88va.com/vn/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Fun88" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/ed704e1d-3894-48bb-83e3-6094b2c68a5c/fun88-logo.png" width="64" height="64"></a></td>
|
||||
<td><a title="WNB Casino Bewertung" href="https://wnb-casino.de/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="WNB Casino Bewertung" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/1adcf96c-dba5-40c0-aa5f-cc352e98b376/WNB%20Casino%20Bewertung.png" width="64" height="64"></a></td>
|
||||
<td><a title="casino en ligne avec Girandières" href="https://www.girandieres.com/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="casino en ligne avec Girandières" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/62161b95-62bd-4feb-af7e-48a807508286/girandieres_logo_5.png" width="64" height="64"></a></td>
|
||||
<td><a title="JBO Thailand คือแพลตฟอร์มความบันเทิงออนไลน์ครบวงจร ให้บริการการเดิมพันกีฬา อีสปอร์ต คาสิโนสด และเกมยอดนิยม ผ่านระบบทันสมัย ใช้งานง่าย รองรับทุกอุปกรณ์ พร้อมมอบประสบการณ์ที่มีคุณภาพ ปลอดภัย และน่าเชื่อถือสำหรับผู้ใช้งานชาวไทย." href="https://www.jbo579.com/th/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="JBO" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/8b5789f1-7bab-4f9e-ae06-98d809114757/header-logo-TH-Picsart-BackgroundChanger.png" width="122" height="64"></a></td>
|
||||
<td><a title="JBO Vietnam là thương hiệu giải trí trực tuyến nổi bật tại Việt Nam, cung cấp cá cược thể thao, esports, casino trực tuyến và nhiều trò chơi hấp dẫn khác." href="https://www.jbo88vk.com/vn/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="JBO" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/382d0a06-2e32-43cc-8e91-b61bad5568b7/newLogo-Picsart-BackgroundChanger.png" width="122" height="64"></a></td>
|
||||
<td><a title="gaia-wines.gr" href="https://www.gaia-wines.gr/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="gaia-wines.gr" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/a9b971ee-db5f-4400-8c4b-76cf9bc35015/IMAGE%202024-06-14%2013%3A54%3A14.jpg" width="64" height="64"></a></td>
|
||||
<td><a title="Najlepsi Bukmacherzy" href="https://najlepsibukmacherzy.pl/ranking-legalnych-bukmacherow/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Najlepsi Bukmacherzy" src="https://opencollective-production.s3.us-west-1.amazonaws.com/81588eb0-608a-11eb-ad1c-b119533ac7bb.png" width="42" height="42"></a></td>
|
||||
<td><a title="TopRating.casino ➢ Гід по онлайн-казино в Україні" href="https://toprating.casino/ua/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Top Rating casino" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/fec14fc4-85b1-4fdc-971e-e8aabfc60926/toprating%20logo.jpg" width="42" height="42"></a></td>
|
||||
<td><a title="Get professional support for Carbon" href="https://tidelift.com/subscription/pkg/packagist-nesbot-carbon?utm_source=packagist-nesbot-carbon&utm_medium=referral&utm_campaign=docs" target="_blank"><img alt="Tidelift" src="https://carbonphp.github.io/carbon/sponsors/tidelift-brand.png" width="84" height="42"></a></td>
|
||||
<td><a title="luckygans-casino" href="https://nl.trustpilot.com/review/luckygans-casino.net?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="luckygans-casino" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/eece0542-bfa8-4bab-9cac-0c789d78ea1f/images.jpg" width="42" height="42"></a></td>
|
||||
<td><a title="Real Money Pokies" href="https://onlinecasinoskiwi.co.nz/real-money-pokies/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Real Money Pokies" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/d0f7382e-32ea-4425-a8c4-3019f9ed501c/NZ_logo%20(6)%20(2).jpg" width="42" height="42"></a></td>
|
||||
<td><a title="Mi misión es la educación y transparencia en el mundo de los casinos online" href="https://www.educatransparencia.cl/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Transparencia en Casinos Online" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/c034fdcb-1d17-4c83-8105-f3cfa4f874d6/educalogocito.png" width="84" height="42"></a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><a title="Casino ohne oasis" href="https://de.trustpilot.com/review/onlinecasinoohneoasis.me?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Casino ohne oasis" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/f59e1e3a-6378-4aa7-91f5-6934a58bc21d/oasis.png" width="42" height="42"></a></td>
|
||||
<td><a title="Plinko Game" href="https://www.trustpilot.com/review/plinkoplay.top?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Plinko Game" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/5e953df9-1876-45b6-9ffc-f2009804935b/plinkoo.png" width="42" height="42"></a></td>
|
||||
<td><a title="Casino-portugal.pt" href="https://casino-portugal.pt/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Casino-portugal.pt" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/870b4bd0-b6aa-4129-9827-e8ac02cfde56/167bdc1d-0a19-414d-a288-cfc3278b388f.png" width="42" height="42"></a></td>
|
||||
<td><a title="Offshore bookmakers review site." href="https://www.sportsbookreviewsonline.com/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Sportsbook Reviews Online" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/6d499f24-d669-4fc6-bb5f-b87184aa7963/sportsbookreviewsonline_com.png" width="42" height="42"></a></td>
|
||||
<td><a title="Casinos ohne OASIS" href="https://de.trustpilot.com/review/ohneoasis.de?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Casinos ohne OASIS" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/49904abe-0786-4b30-a9c8-6c508441f7c7/ohneoasis.de.png" width="43" height="42"></a></td>
|
||||
<td><a title="Paysafecard Casino" href="https://de.trustpilot.com/review/onlinecasinospaysafecard.com?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Paysafecard Casino" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/641d34bb-f65f-4df5-a6ec-ad5ab35df1e0/paysafe.png" width="42" height="42"></a></td>
|
||||
<td><a title="Betwinner is an online bookmaker offering sports betting, casino games, and more." href="https://guidebook.betwinner.com/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Guidebook.BetWinner" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/82cab29a-7002-4924-83bf-2eecb03d07c4/0x0.png" width="42" height="42"></a></td>
|
||||
<td><a title="Buitenlandse Online Casino" href="https://nl.trustpilot.com/review/buitenlandsecasino.vip?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Buitenlandse Online Casino" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/9465308a-8e44-4606-af5d-5a81a3c6567b/ChatGPT%20Image%20Nov%2015%2C%202025%2C%2002_53_25%20PM.png" width="42" height="42"></a></td>
|
||||
<td><a title="Znajdź najlepsze zakłady bukmacherskie w Polsce w 2023 roku. Probukmacher.pl to Twoje kompendium wiedzy na temat bukmacherów!" href="https://www.probukmacher.pl?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Probukmacher" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/caf50271-4560-4ffe-a434-ea15239168db/Screenshot_1.png" width="58" height="42"></a></td>
|
||||
<td><a title="Ставки на спорт Favbet" href="https://www.favbet.ua/uk/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Ставки на спорт Favbet" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/d86d313e-7b17-42fa-8b76-3f17fbf681a2/favbet-logo.jpg" width="42" height="42"></a></td>
|
||||
<td><a title="Онлайн казино casino.ua" href="https://casino.ua/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Онлайн казино casino.ua" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/32790ee6-245b-45bd-acf7-7a661fe2cf9f/logo.png" width="42" height="42"></a></td>
|
||||
<td><a title="inkedin" href="https://inkedin.com?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="inkedin" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/6cb31863-b725-49c5-820c-2c2be7d54adf/cc930e12-04de-4574-9cca-171e07d277c3.png" width="42" height="42"></a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><a title="Post-production resource scheduling app" href="https://freispace.com/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="freispace" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/7d553b00-78ff-4442-91dd-33c220e82ac4/freispace-icon-inverted.png" width="42" height="42"></a></td>
|
||||
<td><a title="bestecasinozondercruks" href="https://nl.trustpilot.com/review/bestecasinozondercruks.online?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="bestecasinozondercruks" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/4948eca9-abd5-49ea-bb70-1ea6053f8663/ChatGPT%20Image%20Dec%2027%2C%202025%2C%2010_22_47%20PM-min.png" width="42" height="42"></a></td>
|
||||
<td><a title="Run Weekly" href="https://www.runweekly.com/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="Run Weekly" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/4d7e1fad-f160-4b64-ab41-d493023f9369/2de8e56c-e9fa-497c-8882-3736ec946664.png" width="42" height="42"></a></td>
|
||||
<td><a title="Are you looking for the latest online casino sites to play in the UK? How about ones that actually deliver on their promises? Every year new online casinos pops up, but are they worth your time? Check out https://helpdirect.org.uk" href="https://linkly.link/2pN29?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="New Casino Sites UK (2025) Help Direct" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/d5e8c98f-7df3-40e8-bfe1-3c1583222eab/help-direct-logo-white-trans.png" width="42" height="42"></a></td>
|
||||
<td><a title="TopKasynoOnline PL" href="https://pl.topkasynoonline.com/?utm_source=opencollective&utm_medium=github&utm_campaign=Carbon" target="_blank"><img alt="TopKasynoOnline PL" src="https://opencollective-production.s3.us-west-1.amazonaws.com/account-avatar/6cdee969-d731-44d6-b8ff-fc4f6d4dab9c/TKOlogo.png" width="42" height="42"></a></td>
|
||||
<td><a title="ssddanbrown" href="https://github.com/ssddanbrown" target="_blank"><img alt="ssddanbrown" src="https://avatars.githubusercontent.com/u/8343178?s=128&v=4" width="42" height="42"></a></td>
|
||||
<td></td>
|
||||
<td></td>
|
||||
<td></td>
|
||||
<td></td>
|
||||
<td></td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
</details><!-- </open-collective-sponsors> -->
|
||||
|
||||
[[Become a sponsor via OpenCollective](https://opencollective.com/Carbon#sponsor)]
|
||||
[[See all](https://carbonphp.github.io/carbon/#sponsors)]
|
||||
|
||||
<a href="https://github.com/johnrsimeone" target="_blank"><img src="https://avatars.githubusercontent.com/u/22871068?s=70&v=4" width="64" height="64"></a>
|
||||
<a href="https://github.com/taylorotwell" target="_blank"><img src="https://avatars.githubusercontent.com/u/463230?s=128&v=4" width="64" height="64"></a>
|
||||
<a href="https://github.com/getsentry" target="_blank"><img src="https://avatars.githubusercontent.com/u/1396951?s=128&v=4" width="64" height="64"></a>
|
||||
<a href="https://github.com/codecov" target="_blank"><img src="https://avatars.githubusercontent.com/u/8226205?s=128&v=4" width="64" height="64"></a>
|
||||
[[Become a sponsor via OpenCollective*](https://opencollective.com/Carbon#sponsor)]
|
||||
|
||||
[[Become a sponsor via GitHub](https://github.com/sponsors/kylekatarnls)]
|
||||
[[Become a sponsor via GitHub*](https://github.com/sponsors/kylekatarnls)]
|
||||
|
||||
<small>* This is a donation. No goods or services are expected in return. Any requests for refunds for those purposes will be rejected.</small>
|
||||
|
||||
### Backers
|
||||
|
||||
|
||||
-129
@@ -1,129 +0,0 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
* (c) Brian Nesbitt <brian@nesbot.com>
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
use Carbon\CarbonImmutable;
|
||||
|
||||
require_once __DIR__.'/vendor/autoload.php';
|
||||
|
||||
function getMaxHistoryMonthsByAmount($amount): int
|
||||
{
|
||||
if ($amount >= 50) {
|
||||
return 6;
|
||||
}
|
||||
|
||||
if ($amount >= 20) {
|
||||
return 4;
|
||||
}
|
||||
|
||||
return 2;
|
||||
}
|
||||
|
||||
function getHtmlAttribute($rawValue): string
|
||||
{
|
||||
return str_replace(
|
||||
['', "\r"],
|
||||
'',
|
||||
trim(htmlspecialchars((string) $rawValue), " \n\r\t\v\0"),
|
||||
);
|
||||
}
|
||||
|
||||
function getOpenCollectiveSponsors(): string
|
||||
{
|
||||
$customSponsorImages = [
|
||||
// For consistency and equity among sponsors, as of now, we kindly ask our sponsors
|
||||
// to provide an image having a width/height ratio between 1/1 and 2/1.
|
||||
// By default, we'll show the member picture from OpenCollective, and will resize it if bigger
|
||||
// int(OpenCollective.MemberId) => ImageURL
|
||||
];
|
||||
|
||||
$members = json_decode(file_get_contents('https://opencollective.com/carbon/members/all.json'), true);
|
||||
|
||||
$list = array_filter($members, static function ($member): bool {
|
||||
return ($member['lastTransactionAmount'] > 3 || $member['isActive']) &&
|
||||
$member['role'] === 'BACKER' &&
|
||||
$member['type'] !== 'USER' &&
|
||||
(
|
||||
$member['totalAmountDonated'] > 100 ||
|
||||
$member['lastTransactionAt'] > CarbonImmutable::now()
|
||||
->subMonthsNoOverflow(getMaxHistoryMonthsByAmount($member['lastTransactionAmount']))
|
||||
->format('Y-m-d h:i') ||
|
||||
$member['isActive'] && $member['lastTransactionAmount'] >= 30
|
||||
);
|
||||
});
|
||||
|
||||
$list = array_map(static function (array $member): array {
|
||||
$createdAt = CarbonImmutable::parse($member['createdAt']);
|
||||
$lastTransactionAt = CarbonImmutable::parse($member['lastTransactionAt']);
|
||||
|
||||
if ($createdAt->format('d H:i:s.u') > $lastTransactionAt->format('d H:i:s.u')) {
|
||||
$createdAt = $createdAt
|
||||
->setDay($lastTransactionAt->day)
|
||||
->modify($lastTransactionAt->format('H:i:s.u'));
|
||||
}
|
||||
|
||||
$monthlyContribution = (float) ($member['totalAmountDonated'] / ceil($createdAt->floatDiffInMonths()));
|
||||
|
||||
if (
|
||||
$lastTransactionAt->isAfter('last month') &&
|
||||
$member['lastTransactionAmount'] > $monthlyContribution
|
||||
) {
|
||||
$monthlyContribution = (float) $member['lastTransactionAmount'];
|
||||
}
|
||||
|
||||
$yearlyContribution = (float) ($member['totalAmountDonated'] / max(1, $createdAt->floatDiffInYears()));
|
||||
$status = null;
|
||||
|
||||
if ($monthlyContribution > 29) {
|
||||
$status = 'sponsor';
|
||||
} elseif ($monthlyContribution > 4.5 || $yearlyContribution > 29) {
|
||||
$status = 'backer';
|
||||
} elseif ($member['totalAmountDonated'] > 0) {
|
||||
$status = 'helper';
|
||||
}
|
||||
|
||||
return array_merge($member, [
|
||||
'star' => ($monthlyContribution > 98 || $yearlyContribution > 500),
|
||||
'status' => $status,
|
||||
'monthlyContribution' => $monthlyContribution,
|
||||
'yearlyContribution' => $yearlyContribution,
|
||||
]);
|
||||
}, $list);
|
||||
|
||||
usort($list, static function (array $a, array $b): int {
|
||||
return ($b['monthlyContribution'] <=> $a['monthlyContribution'])
|
||||
?: ($b['totalAmountDonated'] <=> $a['totalAmountDonated']);
|
||||
});
|
||||
|
||||
return implode('', array_map(static function (array $member) use ($customSponsorImages): string {
|
||||
$href = htmlspecialchars($member['website'] ?? $member['profile']);
|
||||
$src = $customSponsorImages[$member['MemberId'] ?? ''] ?? $member['image'] ?? (strtr($member['profile'], ['https://opencollective.com/' => 'https://images.opencollective.com/']).'/avatar/256.png');
|
||||
[$x, $y] = @getimagesize($src) ?: [0, 0];
|
||||
$validImage = ($x && $y);
|
||||
$src = $validImage ? htmlspecialchars($src) : 'https://opencollective.com/static/images/default-guest-logo.svg';
|
||||
$height = $member['status'] === 'sponsor' ? 64 : 42;
|
||||
$width = min($height * 2, $validImage ? round($x * $height / $y) : $height);
|
||||
$href .= (strpos($href, '?') === false ? '?' : '&').'utm_source=opencollective&utm_medium=github&utm_campaign=Carbon';
|
||||
$title = getHtmlAttribute(($member['description'] ?? null) ?: $member['name']);
|
||||
$alt = getHtmlAttribute($member['name']);
|
||||
|
||||
return "\n".'<a title="'.$title.'" href="'.$href.'" target="_blank">'.
|
||||
'<img alt="'.$alt.'" src="'.$src.'" width="'.$width.'" height="'.$height.'">'.
|
||||
'</a>';
|
||||
}, $list))."\n";
|
||||
}
|
||||
|
||||
file_put_contents('readme.md', preg_replace_callback(
|
||||
'/(<!-- <open-collective-sponsors> -->)[\s\S]+(<!-- <\/open-collective-sponsors> -->)/',
|
||||
static function (array $match): string {
|
||||
return $match[1].getOpenCollectiveSponsors().$match[2];
|
||||
},
|
||||
file_get_contents('readme.md')
|
||||
));
|
||||
File diff suppressed because it is too large.
Load diff
@@ -0,0 +1,134 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
* (c) Brian Nesbitt <brian@nesbot.com>
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Carbon;
|
||||
|
||||
use Closure;
|
||||
use DateInterval;
|
||||
use DatePeriod;
|
||||
use DateTime;
|
||||
use DateTimeInterface;
|
||||
use DateTimeZone;
|
||||
use ReflectionFunction;
|
||||
use ReflectionNamedType;
|
||||
use ReflectionType;
|
||||
use Time\Duration;
|
||||
|
||||
final class Callback
|
||||
{
|
||||
private ?ReflectionFunction $function;
|
||||
|
||||
private function __construct(private readonly Closure $closure)
|
||||
{
|
||||
}
|
||||
|
||||
public static function fromClosure(Closure $closure): self
|
||||
{
|
||||
return new self($closure);
|
||||
}
|
||||
|
||||
public static function parameter(mixed $closure, mixed $value, string|int $index = 0): mixed
|
||||
{
|
||||
if ($closure instanceof Closure) {
|
||||
return self::fromClosure($closure)->prepareParameter($value, $index);
|
||||
}
|
||||
|
||||
return $value;
|
||||
}
|
||||
|
||||
public function getReflectionFunction(): ReflectionFunction
|
||||
{
|
||||
return $this->function ??= new ReflectionFunction($this->closure);
|
||||
}
|
||||
|
||||
public function prepareParameter(mixed $value, string|int $index = 0): mixed
|
||||
{
|
||||
$type = $this->getParameterType($index);
|
||||
|
||||
if (!($type instanceof ReflectionNamedType)) {
|
||||
return $value;
|
||||
}
|
||||
|
||||
$name = $type->getName();
|
||||
|
||||
if ($name === CarbonInterface::class) {
|
||||
$name = $value instanceof DateTime ? Carbon::class : CarbonImmutable::class;
|
||||
}
|
||||
|
||||
if (!class_exists($name) || is_a($value, $name)) {
|
||||
return $value;
|
||||
}
|
||||
|
||||
$class = $this->getPromotedClass($value);
|
||||
|
||||
if ($class && is_a($name, $class, true)) {
|
||||
return $name::instance($value);
|
||||
}
|
||||
|
||||
if ($name === Duration::class && $value instanceof DateInterval) {
|
||||
return DurationConverter::createDurationFromInterval($value);
|
||||
}
|
||||
|
||||
return $value;
|
||||
}
|
||||
|
||||
public function call(mixed ...$arguments): mixed
|
||||
{
|
||||
foreach ($arguments as $index => &$value) {
|
||||
if ($this->getPromotedClass($value)) {
|
||||
$value = $this->prepareParameter($value, $index);
|
||||
}
|
||||
}
|
||||
|
||||
return ($this->closure)(...$arguments);
|
||||
}
|
||||
|
||||
private function getParameterType(string|int $index): ?ReflectionType
|
||||
{
|
||||
$parameters = $this->getReflectionFunction()->getParameters();
|
||||
|
||||
if (\is_int($index)) {
|
||||
return ($parameters[$index] ?? null)?->getType();
|
||||
}
|
||||
|
||||
foreach ($parameters as $parameter) {
|
||||
if ($parameter->getName() === $index) {
|
||||
return $parameter->getType();
|
||||
}
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
/** @return class-string|null */
|
||||
private function getPromotedClass(mixed $value): ?string
|
||||
{
|
||||
if ($value instanceof DateTimeInterface) {
|
||||
return CarbonInterface::class;
|
||||
}
|
||||
|
||||
if ($value instanceof DateInterval) {
|
||||
return CarbonInterval::class;
|
||||
}
|
||||
|
||||
if ($value instanceof DatePeriod) {
|
||||
return CarbonPeriod::class;
|
||||
}
|
||||
|
||||
if ($value instanceof DateTimeZone) {
|
||||
return CarbonTimeZone::class;
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
}
|
||||
+812
-486
File diff suppressed because it is too large.
Load diff
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
|
||||
+954
-505
File diff suppressed because it is too large.
Load diff
+1690
-1920
File diff suppressed because it is too large.
Load diff
+1190
-504
File diff suppressed because it is too large.
Load diff
+838
-659
File diff suppressed because it is too large.
Load diff
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
@@ -22,18 +24,14 @@ class CarbonPeriodImmutable extends CarbonPeriod
|
||||
|
||||
/**
|
||||
* Date class of iteration items.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $dateClass = CarbonImmutable::class;
|
||||
protected string $dateClass = CarbonImmutable::class;
|
||||
|
||||
/**
|
||||
* Prepare the instance to be set (self if mutable to be mutated,
|
||||
* copy if immutable to generate a new instance).
|
||||
*
|
||||
* @return static
|
||||
*/
|
||||
protected function copyIfImmutable()
|
||||
protected function copyIfImmutable(): static
|
||||
{
|
||||
return $this->constructed ? clone $this : $this;
|
||||
}
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
@@ -11,34 +13,43 @@
|
||||
|
||||
namespace Carbon;
|
||||
|
||||
use Carbon\Constants\UnitValue;
|
||||
use Carbon\Exceptions\InvalidCastException;
|
||||
use Carbon\Exceptions\InvalidTimeZoneException;
|
||||
use Carbon\Traits\LocalFactory;
|
||||
use DateTimeImmutable;
|
||||
use DateTimeInterface;
|
||||
use DateTimeZone;
|
||||
use Exception;
|
||||
use Throwable;
|
||||
|
||||
class CarbonTimeZone extends DateTimeZone
|
||||
{
|
||||
public function __construct($timezone = null)
|
||||
use LocalFactory;
|
||||
|
||||
public const MAXIMUM_TIMEZONE_OFFSET = 99;
|
||||
|
||||
public function __construct(string|int|float $timezone)
|
||||
{
|
||||
$this->initLocalFactory();
|
||||
|
||||
parent::__construct(static::getDateTimeZoneNameFromMixed($timezone));
|
||||
}
|
||||
|
||||
protected static function parseNumericTimezone($timezone)
|
||||
protected static function parseNumericTimezone(string|int|float $timezone): string
|
||||
{
|
||||
if ($timezone <= -100 || $timezone >= 100) {
|
||||
throw new InvalidTimeZoneException('Absolute timezone offset cannot be greater than 100.');
|
||||
if (abs((float) $timezone) > static::MAXIMUM_TIMEZONE_OFFSET) {
|
||||
throw new InvalidTimeZoneException(
|
||||
'Absolute timezone offset cannot be greater than '.
|
||||
static::MAXIMUM_TIMEZONE_OFFSET.'.',
|
||||
);
|
||||
}
|
||||
|
||||
return ($timezone >= 0 ? '+' : '').ltrim($timezone, '+').':00';
|
||||
return ($timezone >= 0 ? '+' : '').ltrim((string) $timezone, '+').':00';
|
||||
}
|
||||
|
||||
protected static function getDateTimeZoneNameFromMixed($timezone)
|
||||
protected static function getDateTimeZoneNameFromMixed(string|int|float $timezone): string
|
||||
{
|
||||
if ($timezone === null) {
|
||||
return date_default_timezone_get();
|
||||
}
|
||||
|
||||
if (\is_string($timezone)) {
|
||||
$timezone = preg_replace('/^\s*([+-]\d+)(\d{2})\s*$/', '$1:$2', $timezone);
|
||||
}
|
||||
@@ -50,19 +61,14 @@ class CarbonTimeZone extends DateTimeZone
|
||||
return $timezone;
|
||||
}
|
||||
|
||||
protected static function getDateTimeZoneFromName(&$name)
|
||||
{
|
||||
return @timezone_open($name = (string) static::getDateTimeZoneNameFromMixed($name));
|
||||
}
|
||||
|
||||
/**
|
||||
* Cast the current instance into the given class.
|
||||
*
|
||||
* @param string $className The $className::instance() method will be called to cast the current object.
|
||||
* @param class-string<DateTimeZone> $className The $className::instance() method will be called to cast the current object.
|
||||
*
|
||||
* @return DateTimeZone
|
||||
* @return DateTimeZone|mixed
|
||||
*/
|
||||
public function cast(string $className)
|
||||
public function cast(string $className): mixed
|
||||
{
|
||||
if (!method_exists($className, 'instance')) {
|
||||
if (is_a($className, DateTimeZone::class, true)) {
|
||||
@@ -78,38 +84,40 @@ class CarbonTimeZone extends DateTimeZone
|
||||
/**
|
||||
* Create a CarbonTimeZone from mixed input.
|
||||
*
|
||||
* @param DateTimeZone|string|int|null $object original value to get CarbonTimeZone from it.
|
||||
* @param DateTimeZone|string|int|null $objectDump dump of the object for error messages.
|
||||
* @param DateTimeZone|string|int|false|null $object original value to get CarbonTimeZone from it.
|
||||
* @param DateTimeZone|string|int|false|null $objectDump dump of the object for error messages.
|
||||
*
|
||||
* @throws InvalidTimeZoneException
|
||||
*
|
||||
* @return false|static
|
||||
* @return static|null
|
||||
*/
|
||||
public static function instance($object = null, $objectDump = null)
|
||||
{
|
||||
$tz = $object;
|
||||
public static function instance(
|
||||
DateTimeZone|string|int|false|null $object,
|
||||
DateTimeZone|string|int|false|null $objectDump = null,
|
||||
): ?self {
|
||||
$timezone = $object;
|
||||
|
||||
if ($tz instanceof static) {
|
||||
return $tz;
|
||||
if ($timezone instanceof static) {
|
||||
return $timezone;
|
||||
}
|
||||
|
||||
if ($tz === null) {
|
||||
return new static();
|
||||
if ($timezone === null || $timezone === false) {
|
||||
return null;
|
||||
}
|
||||
|
||||
if (!$tz instanceof DateTimeZone) {
|
||||
$tz = static::getDateTimeZoneFromName($object);
|
||||
}
|
||||
try {
|
||||
if (!($timezone instanceof DateTimeZone)) {
|
||||
$name = static::getDateTimeZoneNameFromMixed($object);
|
||||
$timezone = new static($name);
|
||||
}
|
||||
|
||||
if ($tz !== false) {
|
||||
return new static($tz->getName());
|
||||
return $timezone instanceof static ? $timezone : new static($timezone->getName());
|
||||
} catch (Exception $exception) {
|
||||
throw new InvalidTimeZoneException(
|
||||
'Unknown or bad timezone ('.($objectDump ?: $object).')',
|
||||
previous: $exception,
|
||||
);
|
||||
}
|
||||
|
||||
if (Carbon::isStrictModeEnabled()) {
|
||||
throw new InvalidTimeZoneException('Unknown or bad timezone ('.($objectDump ?: $object).')');
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -119,14 +127,27 @@ class CarbonTimeZone extends DateTimeZone
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getAbbreviatedName($dst = false)
|
||||
public function getAbbreviatedName(bool $dst = false): string
|
||||
{
|
||||
$name = $this->getName();
|
||||
|
||||
foreach ($this->listAbbreviations() as $abbreviation => $zones) {
|
||||
$date = new DateTimeImmutable($dst ? 'July 1' : 'January 1', $this);
|
||||
$timezone = $date->format('T');
|
||||
$abbreviations = $this->listAbbreviations();
|
||||
$matchingZones = array_merge($abbreviations[$timezone] ?? [], $abbreviations[strtolower($timezone)] ?? []);
|
||||
|
||||
if ($matchingZones !== []) {
|
||||
foreach ($matchingZones as $zone) {
|
||||
if ($zone['timezone_id'] === $name && $zone['dst'] == $dst) {
|
||||
return $timezone;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
foreach ($abbreviations as $abbreviation => $zones) {
|
||||
foreach ($zones as $zone) {
|
||||
if ($zone['timezone_id'] === $name && $zone['dst'] == $dst) {
|
||||
return $abbreviation;
|
||||
return strtoupper($abbreviation);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -143,33 +164,25 @@ class CarbonTimeZone extends DateTimeZone
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getAbbr($dst = false)
|
||||
public function getAbbr(bool $dst = false): string
|
||||
{
|
||||
return $this->getAbbreviatedName($dst);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the offset as string "sHH:MM" (such as "+00:00" or "-12:30").
|
||||
*
|
||||
* @param DateTimeInterface|null $date
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function toOffsetName(DateTimeInterface $date = null)
|
||||
public function toOffsetName(?DateTimeInterface $date = null): string
|
||||
{
|
||||
return static::getOffsetNameFromMinuteOffset(
|
||||
$this->getOffset($date ?: Carbon::now($this)) / 60
|
||||
$this->getOffset($this->resolveCarbon($date)) / 60,
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns a new CarbonTimeZone object using the offset string instead of region string.
|
||||
*
|
||||
* @param DateTimeInterface|null $date
|
||||
*
|
||||
* @return CarbonTimeZone
|
||||
*/
|
||||
public function toOffsetTimeZone(DateTimeInterface $date = null)
|
||||
public function toOffsetTimeZone(?DateTimeInterface $date = null): static
|
||||
{
|
||||
return new static($this->toOffsetName($date));
|
||||
}
|
||||
@@ -179,13 +192,8 @@ class CarbonTimeZone extends DateTimeZone
|
||||
* false if no match is found.
|
||||
*
|
||||
* @see timezone_name_from_abbr native PHP function.
|
||||
*
|
||||
* @param DateTimeInterface|null $date
|
||||
* @param int $isDst
|
||||
*
|
||||
* @return string|false
|
||||
*/
|
||||
public function toRegionName(DateTimeInterface $date = null, $isDst = 1)
|
||||
public function toRegionName(?DateTimeInterface $date = null, int $isDST = 1): ?string
|
||||
{
|
||||
$name = $this->getName();
|
||||
$firstChar = substr($name, 0, 1);
|
||||
@@ -194,52 +202,48 @@ class CarbonTimeZone extends DateTimeZone
|
||||
return $name;
|
||||
}
|
||||
|
||||
$date = $date ?: Carbon::now($this);
|
||||
$date = $this->resolveCarbon($date);
|
||||
|
||||
// Integer construction no longer supported since PHP 8
|
||||
// @codeCoverageIgnoreStart
|
||||
try {
|
||||
$offset = @$this->getOffset($date) ?: 0;
|
||||
} catch (Throwable $e) {
|
||||
} catch (Throwable) {
|
||||
$offset = 0;
|
||||
}
|
||||
// @codeCoverageIgnoreEnd
|
||||
|
||||
$name = @timezone_name_from_abbr('', $offset, $isDst);
|
||||
$name = @timezone_name_from_abbr('', $offset, $isDST);
|
||||
|
||||
if ($name) {
|
||||
return $name;
|
||||
}
|
||||
|
||||
foreach (timezone_identifiers_list() as $timezone) {
|
||||
if (Carbon::instance($date)->tz($timezone)->getOffset() === $offset) {
|
||||
if (Carbon::instance($date)->setTimezone($timezone)->getOffset() === $offset) {
|
||||
return $timezone;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns a new CarbonTimeZone object using the region string instead of offset string.
|
||||
*
|
||||
* @param DateTimeInterface|null $date
|
||||
*
|
||||
* @return CarbonTimeZone|false
|
||||
*/
|
||||
public function toRegionTimeZone(DateTimeInterface $date = null)
|
||||
public function toRegionTimeZone(?DateTimeInterface $date = null): ?self
|
||||
{
|
||||
$tz = $this->toRegionName($date);
|
||||
$timezone = $this->toRegionName($date);
|
||||
|
||||
if ($tz !== false) {
|
||||
return new static($tz);
|
||||
if ($timezone !== null) {
|
||||
return new static($timezone);
|
||||
}
|
||||
|
||||
if (Carbon::isStrictModeEnabled()) {
|
||||
throw new InvalidTimeZoneException('Unknown timezone for offset '.$this->getOffset($date ?: Carbon::now($this)).' seconds.');
|
||||
throw new InvalidTimeZoneException('Unknown timezone for offset '.$this->getOffset($this->resolveCarbon($date)).' seconds.');
|
||||
}
|
||||
|
||||
return false;
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -285,7 +289,7 @@ class CarbonTimeZone extends DateTimeZone
|
||||
*/
|
||||
public static function createFromHourOffset(float $hourOffset)
|
||||
{
|
||||
return static::createFromMinuteOffset($hourOffset * Carbon::MINUTES_PER_HOUR);
|
||||
return static::createFromMinuteOffset($hourOffset * UnitValue::MINUTES_PER_HOUR);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -317,4 +321,17 @@ class CarbonTimeZone extends DateTimeZone
|
||||
':'.
|
||||
str_pad((string) ($unsignedMinutes % 60), 2, '0', STR_PAD_LEFT);
|
||||
}
|
||||
|
||||
private function resolveCarbon(?DateTimeInterface $date): DateTimeInterface
|
||||
{
|
||||
if ($date) {
|
||||
return $date;
|
||||
}
|
||||
|
||||
if (isset($this->clock)) {
|
||||
return $this->clock->now()->setTimezone($this);
|
||||
}
|
||||
|
||||
return Carbon::now($this);
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
|
||||
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
* (c) Brian Nesbitt <brian@nesbot.com>
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Carbon\Constants;
|
||||
|
||||
interface DiffOptions
|
||||
{
|
||||
/**
|
||||
* Diff wording options(expressed in octal).
|
||||
*/
|
||||
public const NO_ZERO_DIFF = 01;
|
||||
public const JUST_NOW = 02;
|
||||
public const ONE_DAY_WORDS = 04;
|
||||
public const TWO_DAY_WORDS = 010;
|
||||
public const SEQUENTIAL_PARTS_ONLY = 020;
|
||||
public const ROUND = 040;
|
||||
public const FLOOR = 0100;
|
||||
public const CEIL = 0200;
|
||||
|
||||
/**
|
||||
* Diff syntax options.
|
||||
*/
|
||||
public const DIFF_ABSOLUTE = 1; // backward compatibility with true
|
||||
public const DIFF_RELATIVE_AUTO = 0; // backward compatibility with false
|
||||
public const DIFF_RELATIVE_TO_NOW = 2;
|
||||
public const DIFF_RELATIVE_TO_OTHER = 3;
|
||||
}
|
||||
@@ -0,0 +1,45 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
* (c) Brian Nesbitt <brian@nesbot.com>
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Carbon\Constants;
|
||||
|
||||
interface Format
|
||||
{
|
||||
/**
|
||||
* RFC7231 DateTime format.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
public const RFC7231_FORMAT = 'D, d M Y H:i:s \G\M\T';
|
||||
|
||||
/**
|
||||
* Default format to use for __toString method when type juggling occurs.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
public const DEFAULT_TO_STRING_FORMAT = 'Y-m-d H:i:s';
|
||||
|
||||
/**
|
||||
* Format for converting mocked time, includes microseconds.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
public const MOCK_DATETIME_FORMAT = 'Y-m-d H:i:s.u';
|
||||
|
||||
/**
|
||||
* Pattern detection for ->isoFormat and ::createFromIsoFormat.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
public const ISO_FORMAT_REGEXP = '(O[YMDHhms]|[Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|YYYYYY|YYYYY|YYYY|YY?|N{1,5}|yo|y{1,4}|g{1,5}|G{1,5}|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?)';
|
||||
}
|
||||
+39
@@ -0,0 +1,39 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
* (c) Brian Nesbitt <brian@nesbot.com>
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Carbon\Constants;
|
||||
|
||||
interface TranslationOptions
|
||||
{
|
||||
/**
|
||||
* Translate string options.
|
||||
*/
|
||||
public const TRANSLATE_MONTHS = 1;
|
||||
public const TRANSLATE_DAYS = 2;
|
||||
public const TRANSLATE_UNITS = 4;
|
||||
public const TRANSLATE_MERIDIEM = 8;
|
||||
public const TRANSLATE_DIFF = 0x10;
|
||||
public const TRANSLATE_ALL = self::TRANSLATE_MONTHS | self::TRANSLATE_DAYS | self::TRANSLATE_UNITS | self::TRANSLATE_MERIDIEM | self::TRANSLATE_DIFF;
|
||||
|
||||
/**
|
||||
* Special settings to get the start of week from current locale culture.
|
||||
*/
|
||||
public const WEEK_DAY_AUTO = 'auto';
|
||||
|
||||
/**
|
||||
* Default locale (language and region).
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
public const DEFAULT_LOCALE = 'en';
|
||||
}
|
||||
@@ -0,0 +1,66 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
* (c) Brian Nesbitt <brian@nesbot.com>
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Carbon\Constants;
|
||||
|
||||
interface UnitValue
|
||||
{
|
||||
/**
|
||||
* The day constants.
|
||||
*/
|
||||
public const SUNDAY = 0;
|
||||
public const MONDAY = 1;
|
||||
public const TUESDAY = 2;
|
||||
public const WEDNESDAY = 3;
|
||||
public const THURSDAY = 4;
|
||||
public const FRIDAY = 5;
|
||||
public const SATURDAY = 6;
|
||||
|
||||
/**
|
||||
* The month constants.
|
||||
* These aren't used by Carbon itself but exist for
|
||||
* convenience's sake alone.
|
||||
*/
|
||||
public const JANUARY = 1;
|
||||
public const FEBRUARY = 2;
|
||||
public const MARCH = 3;
|
||||
public const APRIL = 4;
|
||||
public const MAY = 5;
|
||||
public const JUNE = 6;
|
||||
public const JULY = 7;
|
||||
public const AUGUST = 8;
|
||||
public const SEPTEMBER = 9;
|
||||
public const OCTOBER = 10;
|
||||
public const NOVEMBER = 11;
|
||||
public const DECEMBER = 12;
|
||||
|
||||
/**
|
||||
* Number of X in Y.
|
||||
*/
|
||||
public const YEARS_PER_MILLENNIUM = 1_000;
|
||||
public const YEARS_PER_CENTURY = 100;
|
||||
public const YEARS_PER_DECADE = 10;
|
||||
public const MONTHS_PER_YEAR = 12;
|
||||
public const MONTHS_PER_QUARTER = 3;
|
||||
public const QUARTERS_PER_YEAR = 4;
|
||||
public const WEEKS_PER_YEAR = 52;
|
||||
public const WEEKS_PER_MONTH = 4;
|
||||
public const DAYS_PER_YEAR = 365;
|
||||
public const DAYS_PER_WEEK = 7;
|
||||
public const HOURS_PER_DAY = 24;
|
||||
public const MINUTES_PER_HOUR = 60;
|
||||
public const SECONDS_PER_MINUTE = 60;
|
||||
public const MILLISECONDS_PER_SECOND = 1_000;
|
||||
public const MICROSECONDS_PER_MILLISECOND = 1_000;
|
||||
public const MICROSECONDS_PER_SECOND = 1_000_000;
|
||||
}
|
||||
@@ -0,0 +1,87 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
* (c) Brian Nesbitt <brian@nesbot.com>
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Carbon;
|
||||
|
||||
use Carbon\Constants\UnitValue;
|
||||
use Carbon\Exceptions\InvalidIntervalException;
|
||||
use DateInterval;
|
||||
use Time\Duration;
|
||||
|
||||
/** @internal */
|
||||
final class DurationConverter
|
||||
{
|
||||
public static function getDurationUnits(Duration $duration): array
|
||||
{
|
||||
$microseconds = intdiv($duration->nanoseconds, 1000);
|
||||
$seconds = $duration->seconds;
|
||||
$minutes = intdiv($seconds, UnitValue::SECONDS_PER_MINUTE);
|
||||
$seconds %= UnitValue::SECONDS_PER_MINUTE;
|
||||
$hours = intdiv($minutes, UnitValue::MINUTES_PER_HOUR);
|
||||
$minutes %= UnitValue::MINUTES_PER_HOUR;
|
||||
|
||||
return [$hours, $minutes, $seconds, $microseconds];
|
||||
}
|
||||
|
||||
public static function getDurationIsoSpec(Duration $duration): string
|
||||
{
|
||||
[$hours, $minutes, $seconds] = self::getDurationUnits($duration);
|
||||
|
||||
return "PT{$hours}H{$minutes}M{$seconds}S";
|
||||
}
|
||||
|
||||
public static function createDurationFromInterval(DateInterval|Duration $interval): Duration
|
||||
{
|
||||
if ($interval instanceof Duration) {
|
||||
return clone $interval;
|
||||
}
|
||||
|
||||
if ($interval->y || $interval->m || $interval->days || $interval->d) {
|
||||
throw new InvalidIntervalException(
|
||||
'Date units (years, months, weeks and days) cannot be converted to '.Duration::class.
|
||||
' because they cannot be unambiguously converted to elapsed time.'
|
||||
);
|
||||
}
|
||||
|
||||
if (abs($interval->f) >= 1) {
|
||||
throw new InvalidIntervalException(
|
||||
"Interval with number of microseconds higher than 999'999 cannot be converted to ".
|
||||
Duration::class,
|
||||
);
|
||||
}
|
||||
|
||||
return self::createDurationFromSeconds(
|
||||
(($interval->h * UnitValue::MINUTES_PER_HOUR) + $interval->i) * UnitValue::SECONDS_PER_MINUTE + $interval->s,
|
||||
(int) ($interval->f * 1_000_000_000),
|
||||
(bool) $interval->invert,
|
||||
);
|
||||
}
|
||||
|
||||
public static function createDurationFromSeconds(int $seconds, int $nanoseconds = 0, bool $inverted = false): Duration
|
||||
{
|
||||
if ($seconds < 0) {
|
||||
$seconds = abs($seconds);
|
||||
$inverted = !$inverted;
|
||||
$nanoseconds *= -1;
|
||||
}
|
||||
|
||||
if ($nanoseconds < 0) {
|
||||
$seconds--;
|
||||
$nanoseconds += 1_000_000_000;
|
||||
}
|
||||
|
||||
$duration = Duration::fromSeconds($seconds, $nanoseconds);
|
||||
|
||||
return $inverted ? $duration->negate() : $duration;
|
||||
}
|
||||
}
|
||||
+3
-1
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
@@ -29,7 +31,7 @@ class BadComparisonUnitException extends UnitException
|
||||
* @param int $code
|
||||
* @param Throwable|null $previous
|
||||
*/
|
||||
public function __construct($unit, $code = 0, Throwable $previous = null)
|
||||
public function __construct($unit, $code = 0, ?Throwable $previous = null)
|
||||
{
|
||||
$this->unit = $unit;
|
||||
|
||||
|
||||
Vendored
+4
-2
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
@@ -30,11 +32,11 @@ class BadFluentConstructorException extends BaseBadMethodCallException implement
|
||||
* @param int $code
|
||||
* @param Throwable|null $previous
|
||||
*/
|
||||
public function __construct($method, $code = 0, Throwable $previous = null)
|
||||
public function __construct($method, $code = 0, ?Throwable $previous = null)
|
||||
{
|
||||
$this->method = $method;
|
||||
|
||||
parent::__construct(sprintf("Unknown fluent constructor '%s'.", $method), $code, $previous);
|
||||
parent::__construct(\sprintf("Unknown fluent constructor '%s'.", $method), $code, $previous);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
+4
-2
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
@@ -30,11 +32,11 @@ class BadFluentSetterException extends BaseBadMethodCallException implements Bad
|
||||
* @param int $code
|
||||
* @param Throwable|null $previous
|
||||
*/
|
||||
public function __construct($setter, $code = 0, Throwable $previous = null)
|
||||
public function __construct($setter, $code = 0, ?Throwable $previous = null)
|
||||
{
|
||||
$this->setter = $setter;
|
||||
|
||||
parent::__construct(sprintf("Unknown fluent setter '%s'", $setter), $code, $previous);
|
||||
parent::__construct(\sprintf("Unknown fluent setter '%s'", $setter), $code, $previous);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
+2
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
|
||||
+2
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
|
||||
+24
-15
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
@@ -14,33 +16,40 @@ namespace Carbon\Exceptions;
|
||||
use RuntimeException as BaseRuntimeException;
|
||||
use Throwable;
|
||||
|
||||
/**
|
||||
* @final
|
||||
*/
|
||||
class ImmutableException extends BaseRuntimeException implements RuntimeException
|
||||
{
|
||||
/**
|
||||
* The value.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $value;
|
||||
protected string $value;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param string $value the immutable type/value
|
||||
* @param string $value the immutable message
|
||||
* @param int $code
|
||||
* @param Throwable|null $previous
|
||||
*
|
||||
* @deprecated Use ImmutableException::fromClass() or ImmutableException::fromMethod() to construct an
|
||||
* ImmutableException instance.
|
||||
*/
|
||||
public function __construct($value, $code = 0, Throwable $previous = null)
|
||||
public function __construct($message, int $code = 0, ?Throwable $previous = null, ?string $value = null)
|
||||
{
|
||||
$this->value = $value;
|
||||
parent::__construct("$value is immutable.", $code, $previous);
|
||||
$this->value ??= $value ?? $message;
|
||||
|
||||
parent::__construct($message, $code, $previous);
|
||||
}
|
||||
|
||||
public static function fromClass(string $class, int $code = 0, ?Throwable $previous = null): self
|
||||
{
|
||||
return new self("$class class is immutable.", $code, $previous, "$class class");
|
||||
}
|
||||
|
||||
public static function fromMethod(string $class, string $method, int $code = 0, ?Throwable $previous = null): self
|
||||
{
|
||||
return new self("$method not allowed on $class.", $code, $previous, "$class::$method method");
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the value.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getValue(): string
|
||||
{
|
||||
return $this->value;
|
||||
|
||||
+2
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
|
||||
+2
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
|
||||
+3
-1
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
@@ -38,7 +40,7 @@ class InvalidDateException extends BaseInvalidArgumentException implements Inval
|
||||
* @param int $code
|
||||
* @param Throwable|null $previous
|
||||
*/
|
||||
public function __construct($field, $value, $code = 0, Throwable $previous = null)
|
||||
public function __construct($field, $value, $code = 0, ?Throwable $previous = null)
|
||||
{
|
||||
$this->field = $field;
|
||||
$this->value = $value;
|
||||
|
||||
+2
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
|
||||
+2
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
|
||||
+2
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
|
||||
Vendored
+2
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
|
||||
+2
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
|
||||
+2
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
|
||||
+33
-2
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
@@ -12,11 +14,14 @@
|
||||
namespace Carbon\Exceptions;
|
||||
|
||||
use Carbon\CarbonInterface;
|
||||
use Carbon\Traits\TogglableDetection;
|
||||
use InvalidArgumentException as BaseInvalidArgumentException;
|
||||
use Throwable;
|
||||
|
||||
class NotACarbonClassException extends BaseInvalidArgumentException implements InvalidArgumentException
|
||||
{
|
||||
use TogglableDetection;
|
||||
|
||||
/**
|
||||
* The className.
|
||||
*
|
||||
@@ -31,11 +36,37 @@ class NotACarbonClassException extends BaseInvalidArgumentException implements I
|
||||
* @param int $code
|
||||
* @param Throwable|null $previous
|
||||
*/
|
||||
public function __construct($className, $code = 0, Throwable $previous = null)
|
||||
public function __construct($className, $code = 0, ?Throwable $previous = null)
|
||||
{
|
||||
$this->className = $className;
|
||||
|
||||
parent::__construct(sprintf('Given class does not implement %s: %s', CarbonInterface::class, $className), $code, $previous);
|
||||
parent::__construct(
|
||||
\sprintf(
|
||||
'Given class does not implement %s: %s',
|
||||
CarbonInterface::class,
|
||||
$className,
|
||||
)."\nBehavior can be unpredictable and unsecure ".
|
||||
"(in particular if you are unserializing data from a source you can't fully trust)\n".
|
||||
"But if you're sure you want to allow it use \$result = ".
|
||||
'NotACarbonClassException::allow(static fn () => ...)',
|
||||
$code,
|
||||
$previous,
|
||||
);
|
||||
}
|
||||
|
||||
public static function expectCarbonInterface(mixed $className): void
|
||||
{
|
||||
if (!self::$detectionEnabled) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (!\is_string($className)) {
|
||||
throw new self(\gettype($className));
|
||||
}
|
||||
|
||||
if (!is_a($className, CarbonInterface::class, true)) {
|
||||
throw new self($className);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
+2
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
|
||||
+3
-1
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
@@ -23,7 +25,7 @@ class NotLocaleAwareException extends BaseInvalidArgumentException implements In
|
||||
* @param int $code
|
||||
* @param Throwable|null $previous
|
||||
*/
|
||||
public function __construct($object, $code = 0, Throwable $previous = null)
|
||||
public function __construct($object, $code = 0, ?Throwable $previous = null)
|
||||
{
|
||||
$dump = \is_object($object) ? \get_class($object) : \gettype($object);
|
||||
|
||||
|
||||
+3
-1
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
@@ -57,7 +59,7 @@ class OutOfRangeException extends BaseInvalidArgumentException implements Invali
|
||||
* @param int $code
|
||||
* @param Throwable|null $previous
|
||||
*/
|
||||
public function __construct($unit, $min, $max, $value, $code = 0, Throwable $previous = null)
|
||||
public function __construct($unit, $min, $max, $value, $code = 0, ?Throwable $previous = null)
|
||||
{
|
||||
$this->unit = $unit;
|
||||
$this->min = $min;
|
||||
|
||||
+3
-1
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
@@ -45,7 +47,7 @@ class ParseErrorException extends BaseInvalidArgumentException implements Invali
|
||||
* @param int $code
|
||||
* @param Throwable|null $previous
|
||||
*/
|
||||
public function __construct($expected, $actual, $help = '', $code = 0, Throwable $previous = null)
|
||||
public function __construct($expected, $actual, $help = '', $code = 0, ?Throwable $previous = null)
|
||||
{
|
||||
$this->expected = $expected;
|
||||
$this->actual = $actual;
|
||||
|
||||
Vendored
+37
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
* (c) Brian Nesbitt <brian@nesbot.com>
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Carbon\Exceptions;
|
||||
|
||||
use Carbon\Traits\TogglableDetection;
|
||||
use RuntimeException as BaseRuntimeException;
|
||||
use Throwable;
|
||||
|
||||
final class PeriodFilterSafetyException extends BaseRuntimeException implements RuntimeException
|
||||
{
|
||||
use TogglableDetection;
|
||||
|
||||
public function __construct(
|
||||
public string $disallowedFilter,
|
||||
int $code = 0,
|
||||
?Throwable $previous = null,
|
||||
) {
|
||||
parent::__construct(
|
||||
"For safety reason, unserializing CarbonPeriod objects with $disallowedFilter is disallowed.\n".
|
||||
"If your serialized string is fully safe and you're sure you want to allow them, wrap the unseritalization".
|
||||
' into $result = PeriodFilterSafetyException::allow(static fn () => unserialize($data))',
|
||||
$code,
|
||||
$previous,
|
||||
);
|
||||
}
|
||||
}
|
||||
+2
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
|
||||
+3
-1
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
@@ -29,7 +31,7 @@ class UnitNotConfiguredException extends UnitException
|
||||
* @param int $code
|
||||
* @param Throwable|null $previous
|
||||
*/
|
||||
public function __construct($unit, $code = 0, Throwable $previous = null)
|
||||
public function __construct($unit, $code = 0, ?Throwable $previous = null)
|
||||
{
|
||||
$this->unit = $unit;
|
||||
|
||||
|
||||
+3
-1
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
@@ -30,7 +32,7 @@ class UnknownGetterException extends BaseInvalidArgumentException implements Inv
|
||||
* @param int $code
|
||||
* @param Throwable|null $previous
|
||||
*/
|
||||
public function __construct($getter, $code = 0, Throwable $previous = null)
|
||||
public function __construct($getter, $code = 0, ?Throwable $previous = null)
|
||||
{
|
||||
$this->getter = $getter;
|
||||
|
||||
|
||||
+3
-1
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
@@ -30,7 +32,7 @@ class UnknownMethodException extends BaseBadMethodCallException implements BadMe
|
||||
* @param int $code
|
||||
* @param Throwable|null $previous
|
||||
*/
|
||||
public function __construct($method, $code = 0, Throwable $previous = null)
|
||||
public function __construct($method, $code = 0, ?Throwable $previous = null)
|
||||
{
|
||||
$this->method = $method;
|
||||
|
||||
|
||||
+3
-1
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
@@ -30,7 +32,7 @@ class UnknownSetterException extends BaseInvalidArgumentException implements Bad
|
||||
* @param int $code
|
||||
* @param Throwable|null $previous
|
||||
*/
|
||||
public function __construct($setter, $code = 0, Throwable $previous = null)
|
||||
public function __construct($setter, $code = 0, ?Throwable $previous = null)
|
||||
{
|
||||
$this->setter = $setter;
|
||||
|
||||
|
||||
+3
-1
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
@@ -29,7 +31,7 @@ class UnknownUnitException extends UnitException
|
||||
* @param int $code
|
||||
* @param Throwable|null $previous
|
||||
*/
|
||||
public function __construct($unit, $code = 0, Throwable $previous = null)
|
||||
public function __construct($unit, $code = 0, ?Throwable $previous = null)
|
||||
{
|
||||
$this->unit = $unit;
|
||||
|
||||
|
||||
+2
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
|
||||
+27
@@ -0,0 +1,27 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
* (c) Brian Nesbitt <brian@nesbot.com>
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Carbon\Exceptions;
|
||||
|
||||
use Exception;
|
||||
|
||||
/**
|
||||
* @codeCoverageIgnore
|
||||
*/
|
||||
class UnsupportedUnitException extends UnitException
|
||||
{
|
||||
public function __construct(string $unit, int $code = 0, ?Exception $previous = null)
|
||||
{
|
||||
parent::__construct("Unsupported unit '$unit'", $code, $previous);
|
||||
}
|
||||
}
|
||||
+795
-230
File diff suppressed because it is too large.
Load diff
+171
-225
@@ -1,5 +1,7 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
@@ -12,248 +14,192 @@
|
||||
namespace Carbon;
|
||||
|
||||
use Closure;
|
||||
use DateTimeImmutable;
|
||||
use DateTimeInterface;
|
||||
use DateTimeZone;
|
||||
use Psr\Clock\ClockInterface;
|
||||
use Symfony\Component\Clock\ClockInterface;
|
||||
use Symfony\Component\Clock\NativeClock;
|
||||
use Symfony\Contracts\Translation\TranslatorInterface;
|
||||
|
||||
/**
|
||||
* A factory to generate CarbonImmutable instances with common settings.
|
||||
*
|
||||
* <autodoc generated by `composer phpdoc`>
|
||||
*
|
||||
* @method bool canBeCreatedFromFormat($date, $format) Checks if the (date)time string is in a given format and valid to create a
|
||||
* new instance.
|
||||
* @method CarbonImmutable|false create($year = 0, $month = 1, $day = 1, $hour = 0, $minute = 0, $second = 0, $tz = null) Create a new Carbon instance from a specific date and time.
|
||||
* If any of $year, $month or $day are set to null their now() values will
|
||||
* be used.
|
||||
* If $hour is null it will be set to its now() value and the default
|
||||
* values for $minute and $second will be their now() values.
|
||||
* If $hour is not null then the default values for $minute and $second
|
||||
* will be 0.
|
||||
* @method CarbonImmutable createFromDate($year = null, $month = null, $day = null, $tz = null) Create a Carbon instance from just a date. The time portion is set to now.
|
||||
* @method CarbonImmutable|false createFromFormat($format, $time, $tz = null) Create a Carbon instance from a specific format.
|
||||
* @method CarbonImmutable|false createFromIsoFormat($format, $time, $tz = null, $locale = 'en', $translator = null) Create a Carbon instance from a specific ISO format (same replacements as ->isoFormat()).
|
||||
* @method CarbonImmutable|false createFromLocaleFormat($format, $locale, $time, $tz = null) Create a Carbon instance from a specific format and a string in a given language.
|
||||
* @method CarbonImmutable|false createFromLocaleIsoFormat($format, $locale, $time, $tz = null) Create a Carbon instance from a specific ISO format and a string in a given language.
|
||||
* @method CarbonImmutable createFromTime($hour = 0, $minute = 0, $second = 0, $tz = null) Create a Carbon instance from just a time. The date portion is set to today.
|
||||
* @method CarbonImmutable createFromTimeString($time, $tz = null) Create a Carbon instance from a time string. The date portion is set to today.
|
||||
* @method CarbonImmutable createFromTimestamp($timestamp, $tz = null) Create a Carbon instance from a timestamp and set the timezone (use default one if not specified).
|
||||
* Timestamp input can be given as int, float or a string containing one or more numbers.
|
||||
* @method CarbonImmutable createFromTimestampMs($timestamp, $tz = null) Create a Carbon instance from a timestamp in milliseconds.
|
||||
* Timestamp input can be given as int, float or a string containing one or more numbers.
|
||||
* @method CarbonImmutable createFromTimestampMsUTC($timestamp) Create a Carbon instance from a timestamp in milliseconds.
|
||||
* Timestamp input can be given as int, float or a string containing one or more numbers.
|
||||
* @method CarbonImmutable createFromTimestampUTC($timestamp) Create a Carbon instance from an timestamp keeping the timezone to UTC.
|
||||
* Timestamp input can be given as int, float or a string containing one or more numbers.
|
||||
* @method CarbonImmutable createMidnightDate($year = null, $month = null, $day = null, $tz = null) Create a Carbon instance from just a date. The time portion is set to midnight.
|
||||
* @method CarbonImmutable|false createSafe($year = null, $month = null, $day = null, $hour = null, $minute = null, $second = null, $tz = null) Create a new safe Carbon instance from a specific date and time.
|
||||
* If any of $year, $month or $day are set to null their now() values will
|
||||
* be used.
|
||||
* If $hour is null it will be set to its now() value and the default
|
||||
* values for $minute and $second will be their now() values.
|
||||
* If $hour is not null then the default values for $minute and $second
|
||||
* will be 0.
|
||||
* If one of the set values is not valid, an InvalidDateException
|
||||
* will be thrown.
|
||||
* @method CarbonInterface createStrict(?int $year = 0, ?int $month = 1, ?int $day = 1, ?int $hour = 0, ?int $minute = 0, ?int $second = 0, $tz = null) Create a new Carbon instance from a specific date and time using strict validation.
|
||||
* @method CarbonImmutable disableHumanDiffOption($humanDiffOption) @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
|
||||
* You should rather use the ->settings() method.
|
||||
* @method CarbonImmutable enableHumanDiffOption($humanDiffOption) @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
|
||||
* You should rather use the ->settings() method.
|
||||
* @method mixed executeWithLocale($locale, $func) Set the current locale to the given, execute the passed function, reset the locale to previous one,
|
||||
* then return the result of the closure (or null if the closure was void).
|
||||
* @method CarbonImmutable fromSerialized($value) Create an instance from a serialized string.
|
||||
* @method void genericMacro($macro, $priority = 0) Register a custom macro.
|
||||
* @method array getAvailableLocales() Returns the list of internally available locales and already loaded custom locales.
|
||||
* (It will ignore custom translator dynamic loading.)
|
||||
* @method Language[] getAvailableLocalesInfo() Returns list of Language object for each available locale. This object allow you to get the ISO name, native
|
||||
* name, region and variant of the locale.
|
||||
* @method array getDays() Get the days of the week
|
||||
* @method string|null getFallbackLocale() Get the fallback locale.
|
||||
* @method array getFormatsToIsoReplacements() List of replacements from date() format to isoFormat().
|
||||
* @method int getHumanDiffOptions() Return default humanDiff() options (merged flags as integer).
|
||||
* @method array getIsoUnits() Returns list of locale units for ISO formatting.
|
||||
* @method array getLastErrors() {@inheritdoc}
|
||||
* @method string getLocale() Get the current translator locale.
|
||||
* @method callable|null getMacro($name) Get the raw callable macro registered globally for a given name.
|
||||
* @method int getMidDayAt() get midday/noon hour
|
||||
* @method Closure|CarbonImmutable getTestNow() Get the Carbon instance (real or mock) to be returned when a "now"
|
||||
* instance is created.
|
||||
* @method string getTimeFormatByPrecision($unitPrecision) Return a format from H:i to H:i:s.u according to given unit precision.
|
||||
* @method string getTranslationMessageWith($translator, string $key, ?string $locale = null, ?string $default = null) Returns raw translation message for a given key.
|
||||
* @method \Symfony\Component\Translation\TranslatorInterface getTranslator() Get the default translator instance in use.
|
||||
* @method int getWeekEndsAt() Get the last day of week
|
||||
* @method int getWeekStartsAt() Get the first day of week
|
||||
* @method array getWeekendDays() Get weekend days
|
||||
* @method bool hasFormat($date, $format) Checks if the (date)time string is in a given format.
|
||||
* @method bool hasFormatWithModifiers($date, $format) Checks if the (date)time string is in a given format.
|
||||
* @method bool hasMacro($name) Checks if macro is registered globally.
|
||||
* @method bool hasRelativeKeywords($time) Determine if a time string will produce a relative date.
|
||||
* @method bool hasTestNow() Determine if there is a valid test instance set. A valid test instance
|
||||
* is anything that is not null.
|
||||
* @method CarbonImmutable instance($date) Create a Carbon instance from a DateTime one.
|
||||
* @method bool isImmutable() Returns true if the current class/instance is immutable.
|
||||
* @method bool isModifiableUnit($unit) Returns true if a property can be changed via setter.
|
||||
* @method bool isMutable() Returns true if the current class/instance is mutable.
|
||||
* @method bool isStrictModeEnabled() Returns true if the strict mode is globally in use, false else.
|
||||
* (It can be overridden in specific instances.)
|
||||
* @method bool localeHasDiffOneDayWords($locale) Returns true if the given locale is internally supported and has words for 1-day diff (just now, yesterday, tomorrow).
|
||||
* Support is considered enabled if the 3 words are translated in the given locale.
|
||||
* @method bool localeHasDiffSyntax($locale) Returns true if the given locale is internally supported and has diff syntax support (ago, from now, before, after).
|
||||
* Support is considered enabled if the 4 sentences are translated in the given locale.
|
||||
* @method bool localeHasDiffTwoDayWords($locale) Returns true if the given locale is internally supported and has words for 2-days diff (before yesterday, after tomorrow).
|
||||
* Support is considered enabled if the 2 words are translated in the given locale.
|
||||
* @method bool localeHasPeriodSyntax($locale) Returns true if the given locale is internally supported and has period syntax support (X times, every X, from X, to X).
|
||||
* Support is considered enabled if the 4 sentences are translated in the given locale.
|
||||
* @method bool localeHasShortUnits($locale) Returns true if the given locale is internally supported and has short-units support.
|
||||
* Support is considered enabled if either year, day or hour has a short variant translated.
|
||||
* @method void macro($name, $macro) Register a custom macro.
|
||||
* @method CarbonImmutable|null make($var) Make a Carbon instance from given variable if possible.
|
||||
* Always return a new instance. Parse only strings and only these likely to be dates (skip intervals
|
||||
* and recurrences). Throw an exception for invalid format, but otherwise return null.
|
||||
* @method CarbonImmutable maxValue() Create a Carbon instance for the greatest supported date.
|
||||
* @method CarbonImmutable minValue() Create a Carbon instance for the lowest supported date.
|
||||
* @method void mixin($mixin) Mix another object into the class.
|
||||
* @method CarbonImmutable parse($time = null, $tz = null) Create a carbon instance from a string.
|
||||
* This is an alias for the constructor that allows better fluent syntax
|
||||
* as it allows you to do Carbon::parse('Monday next week')->fn() rather
|
||||
* than (new Carbon('Monday next week'))->fn().
|
||||
* @method CarbonImmutable parseFromLocale($time, $locale = null, $tz = null) Create a carbon instance from a localized string (in French, Japanese, Arabic, etc.).
|
||||
* @method string pluralUnit(string $unit) Returns standardized plural of a given singular/plural unit name (in English).
|
||||
* @method CarbonImmutable|false rawCreateFromFormat($format, $time, $tz = null) Create a Carbon instance from a specific format.
|
||||
* @method CarbonImmutable rawParse($time = null, $tz = null) Create a carbon instance from a string.
|
||||
* This is an alias for the constructor that allows better fluent syntax
|
||||
* as it allows you to do Carbon::parse('Monday next week')->fn() rather
|
||||
* than (new Carbon('Monday next week'))->fn().
|
||||
* @method CarbonImmutable resetMacros() Remove all macros and generic macros.
|
||||
* @method void resetMonthsOverflow() @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
|
||||
* You should rather use the ->settings() method.
|
||||
* Or you can use method variants: addMonthsWithOverflow/addMonthsNoOverflow, same variants
|
||||
* are available for quarters, years, decade, centuries, millennia (singular and plural forms).
|
||||
* @method void resetToStringFormat() Reset the format used to the default when type juggling a Carbon instance to a string
|
||||
* @method void resetYearsOverflow() @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
|
||||
* You should rather use the ->settings() method.
|
||||
* Or you can use method variants: addYearsWithOverflow/addYearsNoOverflow, same variants
|
||||
* are available for quarters, years, decade, centuries, millennia (singular and plural forms).
|
||||
* @method void serializeUsing($callback) @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
|
||||
* You should rather transform Carbon object before the serialization.
|
||||
* JSON serialize all Carbon instances using the given callback.
|
||||
* @method CarbonImmutable setFallbackLocale($locale) Set the fallback locale.
|
||||
* @method CarbonImmutable setHumanDiffOptions($humanDiffOptions) @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
|
||||
* You should rather use the ->settings() method.
|
||||
* @method bool setLocale($locale) Set the current translator locale and indicate if the source locale file exists.
|
||||
* Pass 'auto' as locale to use closest language from the current LC_TIME locale.
|
||||
* @method void setMidDayAt($hour) @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
|
||||
* You should rather consider mid-day is always 12pm, then if you need to test if it's an other
|
||||
* hour, test it explicitly:
|
||||
* $date->format('G') == 13
|
||||
* or to set explicitly to a given hour:
|
||||
* $date->setTime(13, 0, 0, 0)
|
||||
* Set midday/noon hour
|
||||
* @method CarbonImmutable setTestNow($testNow = null) Set a Carbon instance (real or mock) to be returned when a "now"
|
||||
* instance is created. The provided instance will be returned
|
||||
* specifically under the following conditions:
|
||||
* - A call to the static now() method, ex. Carbon::now()
|
||||
* - When a null (or blank string) is passed to the constructor or parse(), ex. new Carbon(null)
|
||||
* - When the string "now" is passed to the constructor or parse(), ex. new Carbon('now')
|
||||
* - When a string containing the desired time is passed to Carbon::parse().
|
||||
* Note the timezone parameter was left out of the examples above and
|
||||
* has no affect as the mock value will be returned regardless of its value.
|
||||
* Only the moment is mocked with setTestNow(), the timezone will still be the one passed
|
||||
* as parameter of date_default_timezone_get() as a fallback (see setTestNowAndTimezone()).
|
||||
* To clear the test instance call this method using the default
|
||||
* parameter of null.
|
||||
* /!\ Use this method for unit tests only.
|
||||
* @method CarbonImmutable setTestNowAndTimezone($testNow = null, $tz = null) Set a Carbon instance (real or mock) to be returned when a "now"
|
||||
* instance is created. The provided instance will be returned
|
||||
* specifically under the following conditions:
|
||||
* - A call to the static now() method, ex. Carbon::now()
|
||||
* - When a null (or blank string) is passed to the constructor or parse(), ex. new Carbon(null)
|
||||
* - When the string "now" is passed to the constructor or parse(), ex. new Carbon('now')
|
||||
* - When a string containing the desired time is passed to Carbon::parse().
|
||||
* It will also align default timezone (e.g. call date_default_timezone_set()) with
|
||||
* the second argument or if null, with the timezone of the given date object.
|
||||
* To clear the test instance call this method using the default
|
||||
* parameter of null.
|
||||
* /!\ Use this method for unit tests only.
|
||||
* @method void setToStringFormat($format) @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
|
||||
* You should rather let Carbon object being cast to string with DEFAULT_TO_STRING_FORMAT, and
|
||||
* use other method or custom format passed to format() method if you need to dump another string
|
||||
* format.
|
||||
* Set the default format used when type juggling a Carbon instance to a string.
|
||||
* @method void setTranslator(TranslatorInterface $translator) Set the default translator instance to use.
|
||||
* @method CarbonImmutable setUtf8($utf8) @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
|
||||
* You should rather use UTF-8 language packages on every machine.
|
||||
* Set if UTF8 will be used for localized date/time.
|
||||
* @method void setWeekEndsAt($day) @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
|
||||
* Use $weekStartsAt optional parameter instead when using startOfWeek, floorWeek, ceilWeek
|
||||
* or roundWeek method. You can also use the 'first_day_of_week' locale setting to change the
|
||||
* start of week according to current locale selected and implicitly the end of week.
|
||||
* Set the last day of week
|
||||
* @method void setWeekStartsAt($day) @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
|
||||
* Use $weekEndsAt optional parameter instead when using endOfWeek method. You can also use the
|
||||
* 'first_day_of_week' locale setting to change the start of week according to current locale
|
||||
* selected and implicitly the end of week.
|
||||
* Set the first day of week
|
||||
* @method void setWeekendDays($days) @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
|
||||
* You should rather consider week-end is always saturday and sunday, and if you have some custom
|
||||
* week-end days to handle, give to those days an other name and create a macro for them:
|
||||
* ```
|
||||
* Carbon::macro('isDayOff', function ($date) {
|
||||
* return $date->isSunday() || $date->isMonday();
|
||||
* });
|
||||
* Carbon::macro('isNotDayOff', function ($date) {
|
||||
* return !$date->isDayOff();
|
||||
* });
|
||||
* if ($someDate->isDayOff()) ...
|
||||
* if ($someDate->isNotDayOff()) ...
|
||||
* // Add 5 not-off days
|
||||
* $count = 5;
|
||||
* while ($someDate->isDayOff() || ($count-- > 0)) {
|
||||
* $someDate->addDay();
|
||||
* }
|
||||
* ```
|
||||
* Set weekend days
|
||||
* @method bool shouldOverflowMonths() Get the month overflow global behavior (can be overridden in specific instances).
|
||||
* @method bool shouldOverflowYears() Get the month overflow global behavior (can be overridden in specific instances).
|
||||
* @method string singularUnit(string $unit) Returns standardized singular of a given singular/plural unit name (in English).
|
||||
* @method CarbonImmutable today($tz = null) Create a Carbon instance for today.
|
||||
* @method CarbonImmutable tomorrow($tz = null) Create a Carbon instance for tomorrow.
|
||||
* @method string translateTimeString($timeString, $from = null, $to = null, $mode = CarbonInterface::TRANSLATE_ALL) Translate a time string from a locale to an other.
|
||||
* @method string translateWith(TranslatorInterface $translator, string $key, array $parameters = [], $number = null) Translate using translation string or callback available.
|
||||
* @method void useMonthsOverflow($monthsOverflow = true) @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
|
||||
* You should rather use the ->settings() method.
|
||||
* Or you can use method variants: addMonthsWithOverflow/addMonthsNoOverflow, same variants
|
||||
* are available for quarters, years, decade, centuries, millennia (singular and plural forms).
|
||||
* @method CarbonImmutable useStrictMode($strictModeEnabled = true) @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
|
||||
* You should rather use the ->settings() method.
|
||||
* @method void useYearsOverflow($yearsOverflow = true) @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
|
||||
* You should rather use the ->settings() method.
|
||||
* Or you can use method variants: addYearsWithOverflow/addYearsNoOverflow, same variants
|
||||
* are available for quarters, years, decade, centuries, millennia (singular and plural forms).
|
||||
* @method mixed withTestNow($testNow, $callback) Temporarily sets a static date to be used within the callback.
|
||||
* Using setTestNow to set the date, executing the callback, then
|
||||
* clearing the test instance.
|
||||
* /!\ Use this method for unit tests only.
|
||||
* @method CarbonImmutable yesterday($tz = null) Create a Carbon instance for yesterday.
|
||||
* @method bool canBeCreatedFromFormat(?string $date, string $format) Checks if the (date)time string is in a given format and valid to create a
|
||||
* new instance.
|
||||
* @method ?CarbonImmutable create($year = 0, $month = 1, $day = 1, $hour = 0, $minute = 0, $second = 0, $timezone = null) Create a new Carbon instance from a specific date and time.
|
||||
* If any of $year, $month or $day are set to null their now() values will
|
||||
* be used.
|
||||
* If $hour is null it will be set to its now() value and the default
|
||||
* values for $minute and $second will be their now() values.
|
||||
* If $hour is not null then the default values for $minute and $second
|
||||
* will be 0.
|
||||
* @method CarbonImmutable createFromDate($year = null, $month = null, $day = null, $timezone = null) Create a Carbon instance from just a date. The time portion is set to now.
|
||||
* @method ?CarbonImmutable createFromFormat($format, $time, $timezone = null) Create a Carbon instance from a specific format.
|
||||
* @method ?CarbonImmutable createFromIsoFormat(string $format, string $time, $timezone = null, ?string $locale = 'en', ?TranslatorInterface $translator = null) Create a Carbon instance from a specific ISO format (same replacements as ->isoFormat()).
|
||||
* Era tokens (N to NNNNN, y, yy, yyy, yyyy, yo) are read with the "eras" of $locale: the era name gives the
|
||||
* era and the year is the year of this era, so 'D MMMM N y' with 'th' reads '29 กุมภาพันธ์ พ.ศ. 2567' as
|
||||
* 2024-02-29. Without any N token, the era of today's date in this locale is used.
|
||||
* @method ?CarbonImmutable createFromLocaleFormat(string $format, string $locale, string $time, $timezone = null) Create a Carbon instance from a specific format and a string in a given language.
|
||||
* @method ?CarbonImmutable createFromLocaleIsoFormat(string $format, string $locale, string $time, $timezone = null) Create a Carbon instance from a specific ISO format and a string in a given language.
|
||||
* @method CarbonImmutable createFromTime($hour = 0, $minute = 0, $second = 0, $timezone = null) Create a Carbon instance from just a time. The date portion is set to today.
|
||||
* @method CarbonImmutable createFromTimeString(string $time, DateTimeZone|string|int|null $timezone = null) Create a Carbon instance from a time string. The date portion is set to today.
|
||||
* @method CarbonImmutable createFromTimestamp(string|int|float $timestamp, DateTimeZone|string|int|null $timezone = null) Create a Carbon instance from a timestamp and set the timezone (UTC by default).
|
||||
* Timestamp input can be given as int, float or a string containing one or more numbers.
|
||||
* @method CarbonImmutable createFromTimestampMs(string|int|float $timestamp, DateTimeZone|string|int|null $timezone = null) Create a Carbon instance from a timestamp in milliseconds.
|
||||
* Timestamp input can be given as int, float or a string containing one or more numbers.
|
||||
* @method CarbonImmutable createFromTimestampMsUTC($timestamp) Create a Carbon instance from a timestamp in milliseconds.
|
||||
* Timestamp input can be given as int, float or a string containing one or more numbers.
|
||||
* @method CarbonImmutable createFromTimestampUTC(string|int|float $timestamp) Create a Carbon instance from a timestamp keeping the timezone to UTC.
|
||||
* Timestamp input can be given as int, float or a string containing one or more numbers.
|
||||
* @method CarbonImmutable createMidnightDate($year = null, $month = null, $day = null, $timezone = null) Create a Carbon instance from just a date. The time portion is set to midnight.
|
||||
* @method ?CarbonImmutable createSafe($year = null, $month = null, $day = null, $hour = null, $minute = null, $second = null, $timezone = null) Create a new safe Carbon instance from a specific date and time.
|
||||
* If any of $year, $month or $day are set to null their now() values will
|
||||
* be used.
|
||||
* If $hour is null it will be set to its now() value and the default
|
||||
* values for $minute and $second will be their now() values.
|
||||
* If $hour is not null then the default values for $minute and $second
|
||||
* will be 0.
|
||||
* If one of the set values is not valid, an InvalidDateException
|
||||
* will be thrown.
|
||||
* @method CarbonImmutable createStrict(?int $year = 0, ?int $month = 1, ?int $day = 1, ?int $hour = 0, ?int $minute = 0, ?int $second = 0, $timezone = null) Create a new Carbon instance from a specific date and time using strict validation.
|
||||
* @method mixed executeWithLocale(string $locale, callable $func) Set the current locale to the given, execute the passed function, reset the locale to previous one,
|
||||
* then return the result of the closure (or null if the closure was void).
|
||||
* @method CarbonImmutable fromSerialized($value, array $options = []) Create an instance from a serialized string.
|
||||
* Unserializing object can lead to arbitrary execution of period filters, and assignation
|
||||
* of unvalidated values to properties.
|
||||
* You should never unserialize a value from not from a trusted source. Ensure you unserialize
|
||||
* only strings coming from storage no unauthorized party can read nor write, prefer to exchange
|
||||
* data with other systems via static formats such as JSON.
|
||||
* If the data has to transit via untrusted systems before unserialization, then you should
|
||||
* sign it cryptographically (with HMAC or OpenSSL for example), and verify the signature
|
||||
* before unserializing it.
|
||||
* If the content of $value is unknown, consider using the allowed_classes option to limit
|
||||
* the types of objects that can be built, for instance:
|
||||
* @method array getAvailableLocales() Returns the list of internally available locales and already loaded custom locales.
|
||||
* (It will ignore custom translator dynamic loading.)
|
||||
* @method array getAvailableLocalesInfo() Returns list of Language object for each available locale. This object allow you to get the ISO name, native
|
||||
* name, region and variant of the locale.
|
||||
* @method array getDays() Get the days of the week.
|
||||
* @method ?string getFallbackLocale() Get the fallback locale.
|
||||
* @method array getFormatsToIsoReplacements() List of replacements from date() format to isoFormat().
|
||||
* @method array getIsoUnits() Returns list of locale units for ISO formatting.
|
||||
* @method array|false getLastErrors() {@inheritdoc}
|
||||
* @method string getLocale() Get the current translator locale.
|
||||
* @method int getMidDayAt() get midday/noon hour
|
||||
* @method string getTimeFormatByPrecision(string $unitPrecision) Return a format from H:i to H:i:s.u according to given unit precision.
|
||||
* @method string|Closure|null getTranslationMessageWith($translator, string $key, ?string $locale = null, ?string $default = null) Returns raw translation message for a given key.
|
||||
* @method int getWeekEndsAt(?string $locale = null) Get the last day of week.
|
||||
* @method int getWeekStartsAt(?string $locale = null) Get the first day of week.
|
||||
* @method bool hasRelativeKeywords(?string $time) Determine if a time string will produce a relative date.
|
||||
* @method CarbonImmutable instance(DateTimeInterface $date) Create a Carbon instance from a DateTime one.
|
||||
* @method bool isImmutable() Returns true if the current class/instance is immutable.
|
||||
* @method bool isModifiableUnit($unit) Returns true if a property can be changed via setter.
|
||||
* @method bool isMutable() Returns true if the current class/instance is mutable.
|
||||
* @method bool localeHasDiffOneDayWords(string $locale) Returns true if the given locale is internally supported and has words for 1-day diff (just now, yesterday, tomorrow).
|
||||
* Support is considered enabled if the 3 words are translated in the given locale.
|
||||
* @method bool localeHasDiffSyntax(string $locale) Returns true if the given locale is internally supported and has diff syntax support (ago, from now, before, after).
|
||||
* Support is considered enabled if the 4 sentences are translated in the given locale.
|
||||
* @method bool localeHasDiffTwoDayWords(string $locale) Returns true if the given locale is internally supported and has words for 2-days diff (before yesterday, after tomorrow).
|
||||
* Support is considered enabled if the 2 words are translated in the given locale.
|
||||
* @method bool localeHasPeriodSyntax($locale) Returns true if the given locale is internally supported and has period syntax support (X times, every X, from X, to X).
|
||||
* Support is considered enabled if the 4 sentences are translated in the given locale.
|
||||
* @method bool localeHasShortUnits(string $locale) Returns true if the given locale is internally supported and has short-units support.
|
||||
* Support is considered enabled if either year, day or hour has a short variant translated.
|
||||
* @method ?CarbonImmutable make($var, DateTimeZone|string|null $timezone = null) Make a Carbon instance from given variable if possible.
|
||||
* Always return a new instance. Parse only strings and only these likely to be dates (skip intervals
|
||||
* and recurrences). Throw an exception for invalid format, but otherwise return null.
|
||||
* @method void mixin(object|string $mixin) Mix another object into the class.
|
||||
* @method CarbonImmutable parse(DateTimeInterface|WeekDay|Month|string|int|float|null $time, DateTimeZone|string|int|null $timezone = null) Create a carbon instance from a string.
|
||||
* This is an alias for the constructor that allows better fluent syntax
|
||||
* as it allows you to do Carbon::parse('Monday next week')->fn() rather
|
||||
* than (new Carbon('Monday next week'))->fn().
|
||||
* @method CarbonImmutable parseFromLocale(string $time, ?string $locale = null, DateTimeZone|string|int|null $timezone = null) Create a carbon instance from a localized string (in French, Japanese, Arabic, etc.).
|
||||
* @method string pluralUnit(string $unit) Returns standardized plural of a given singular/plural unit name (in English).
|
||||
* @method ?CarbonImmutable rawCreateFromFormat(string $format, string $time, $timezone = null) Create a Carbon instance from a specific format.
|
||||
* @method CarbonImmutable rawParse(DateTimeInterface|WeekDay|Month|string|int|float|null $time, DateTimeZone|string|int|null $timezone = null) Create a carbon instance from a string.
|
||||
* This is an alias for the constructor that allows better fluent syntax
|
||||
* as it allows you to do Carbon::parse('Monday next week')->fn() rather
|
||||
* than (new Carbon('Monday next week'))->fn().
|
||||
* @method void setFallbackLocale(string $locale) Set the fallback locale.
|
||||
* @method void setLocale(string $locale) Set the current translator locale and indicate if the source locale file exists.
|
||||
* Pass 'auto' as locale to use the closest language to the current LC_TIME locale.
|
||||
* @method void setMidDayAt($hour) @deprecated To avoid conflict between different third-party libraries, static setters should not be used.
|
||||
* You should rather consider mid-day is always 12pm, then if you need to test if it's an other
|
||||
* hour, test it explicitly:
|
||||
* $date->format('G') == 13
|
||||
* or to set explicitly to a given hour:
|
||||
* $date->setTime(13, 0, 0, 0)
|
||||
* Set midday/noon hour
|
||||
* @method string singularUnit(string $unit) Returns standardized singular of a given singular/plural unit name (in English).
|
||||
* @method CarbonImmutable today(DateTimeZone|string|int|null $timezone = null) Create a Carbon instance for today.
|
||||
* @method CarbonImmutable tomorrow(DateTimeZone|string|int|null $timezone = null) Create a Carbon instance for tomorrow.
|
||||
* @method string translateTimeString(string $timeString, ?string $from = null, ?string $to = null, int $mode = CarbonInterface::TRANSLATE_ALL) Translate a time string from a locale to an other.
|
||||
* @method string translateWith(TranslatorInterface $translator, string $key, array $parameters = [], $number = null) Translate using translation string or callback available.
|
||||
* @method CarbonImmutable yesterday(DateTimeZone|string|int|null $timezone = null) Create a Carbon instance for yesterday.
|
||||
*
|
||||
* </autodoc>
|
||||
*/
|
||||
class FactoryImmutable extends Factory implements ClockInterface
|
||||
{
|
||||
protected $className = CarbonImmutable::class;
|
||||
protected string $className = CarbonImmutable::class;
|
||||
|
||||
private static ?self $defaultInstance = null;
|
||||
|
||||
private static ?WrapperClock $currentClock = null;
|
||||
|
||||
/**
|
||||
* @internal Instance used for static calls, such as Carbon::getTranslator(), CarbonImmutable::setTestNow(), etc.
|
||||
*/
|
||||
public static function getDefaultInstance(): self
|
||||
{
|
||||
return self::$defaultInstance ??= new self();
|
||||
}
|
||||
|
||||
/**
|
||||
* @internal Instance used for static calls possibly called by non-static methods.
|
||||
*/
|
||||
public static function getInstance(): Factory
|
||||
{
|
||||
return self::$currentClock?->getFactory() ?? self::getDefaultInstance();
|
||||
}
|
||||
|
||||
/**
|
||||
* @internal Set instance before creating new dates.
|
||||
*/
|
||||
public static function setCurrentClock(ClockInterface|Factory|DateTimeInterface|null $currentClock): void
|
||||
{
|
||||
if ($currentClock && !($currentClock instanceof WrapperClock)) {
|
||||
$currentClock = new WrapperClock($currentClock);
|
||||
}
|
||||
|
||||
self::$currentClock = $currentClock;
|
||||
}
|
||||
|
||||
/**
|
||||
* @internal Instance used to link new object to their factory creator.
|
||||
*/
|
||||
public static function getCurrentClock(): ?WrapperClock
|
||||
{
|
||||
return self::$currentClock;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get a Carbon instance for the current date and time.
|
||||
*
|
||||
* @param DateTimeZone|string|int|null $tz
|
||||
*
|
||||
* @return CarbonImmutable
|
||||
*/
|
||||
public function now($tz = null): DateTimeImmutable
|
||||
public function now(DateTimeZone|string|int|null $timezone = null): CarbonImmutable
|
||||
{
|
||||
$className = $this->className;
|
||||
return $this->__call('now', [$timezone]);
|
||||
}
|
||||
|
||||
return new $className(null, $tz);
|
||||
public function sleep(int|float $seconds): void
|
||||
{
|
||||
if ($this->hasTestNow()) {
|
||||
$this->setTestNow($this->getTestNow()->avoidMutation()->addSeconds($seconds));
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
(new NativeClock('UTC'))->sleep($seconds);
|
||||
}
|
||||
}
|
||||
@@ -22,6 +22,7 @@ return array_replace_recursive(require __DIR__.'/en.php', [
|
||||
'weekdays' => ['Acaada', 'Etleeni', 'Talaata', 'Arbaqa', 'Kamiisi', 'Gumqata', 'Sabti'],
|
||||
'weekdays_short' => ['Aca', 'Etl', 'Tal', 'Arb', 'Kam', 'Gum', 'Sab'],
|
||||
'weekdays_min' => ['Aca', 'Etl', 'Tal', 'Arb', 'Kam', 'Gum', 'Sab'],
|
||||
'first_day_of_week' => 0,
|
||||
'day_of_first_week_of_year' => 1,
|
||||
'meridiem' => ['saaku', 'carra'],
|
||||
]);
|
||||
@@ -64,9 +64,7 @@ return [
|
||||
'lastWeek' => '[Laas] dddd [om] LT',
|
||||
'sameElse' => 'L',
|
||||
],
|
||||
'ordinal' => function ($number) {
|
||||
return $number.(($number === 1 || $number === 8 || $number >= 20) ? 'ste' : 'de');
|
||||
},
|
||||
'ordinal' => static fn ($number) => $number.(($number === 1 || $number === 8 || $number >= 20) ? 'ste' : 'de'),
|
||||
'meridiem' => ['VM', 'NM'],
|
||||
'months' => ['Januarie', 'Februarie', 'Maart', 'April', 'Mei', 'Junie', 'Julie', 'Augustus', 'September', 'Oktober', 'November', 'Desember'],
|
||||
'months_short' => ['Jan', 'Feb', 'Mrt', 'Apr', 'Mei', 'Jun', 'Jul', 'Aug', 'Sep', 'Okt', 'Nov', 'Des'],
|
||||
|
||||
@@ -22,6 +22,7 @@ return array_replace_recursive(require __DIR__.'/en.php', [
|
||||
'weekdays' => ['እሑድ', 'ሰኞ', 'ማክሰኞ', 'ረቡዕ', 'ሐሙስ', 'ዓርብ', 'ቅዳሜ'],
|
||||
'weekdays_short' => ['እሑድ', 'ሰኞ ', 'ማክሰ', 'ረቡዕ', 'ሐሙስ', 'ዓርብ', 'ቅዳሜ'],
|
||||
'weekdays_min' => ['እሑድ', 'ሰኞ ', 'ማክሰ', 'ረቡዕ', 'ሐሙስ', 'ዓርብ', 'ቅዳሜ'],
|
||||
'first_day_of_week' => 0,
|
||||
'day_of_first_week_of_year' => 1,
|
||||
'meridiem' => ['ጡዋት', 'ከሰዓት'],
|
||||
|
||||
|
||||
@@ -22,6 +22,7 @@ return array_replace_recursive(require __DIR__.'/en.php', [
|
||||
'weekdays' => ['रविवार', 'सोमवार', 'मंगलवार', 'बुधवार', 'बृहस्पतिवार', 'शुक्रवार', 'शनिवार'],
|
||||
'weekdays_short' => ['रवि', 'सोम', 'मंगल', 'बुध', 'बृहस्पति', 'शुक्र', 'शनि'],
|
||||
'weekdays_min' => ['रवि', 'सोम', 'मंगल', 'बुध', 'बृहस्पति', 'शुक्र', 'शनि'],
|
||||
'first_day_of_week' => 0,
|
||||
'day_of_first_week_of_year' => 1,
|
||||
'meridiem' => ['पूर्वाह्न', 'अपराह्न'],
|
||||
]);
|
||||
+17
-16
@@ -16,6 +16,7 @@
|
||||
* - MLTDev
|
||||
* - Mohamed Sabil (mohamedsabil83)
|
||||
* - Yazan Alnugnugh (yazan-alnugnugh)
|
||||
* - Mousab Salah (123mousab)
|
||||
*/
|
||||
$months = [
|
||||
'يناير',
|
||||
@@ -33,20 +34,20 @@ $months = [
|
||||
];
|
||||
|
||||
return [
|
||||
'year' => implode('|', ['{0}:count سنة', '{1}سنة', '{2}سنتين', ']2,11[:count سنوات', ']10,Inf[:count سنة']),
|
||||
'a_year' => implode('|', ['{0}:count سنة', '{1}سنة', '{2}سنتين', ']2,11[:count سنوات', ']10,Inf[:count سنة']),
|
||||
'month' => implode('|', ['{0}:count شهر', '{1}شهر', '{2}شهرين', ']2,11[:count أشهر', ']10,Inf[:count شهر']),
|
||||
'a_month' => implode('|', ['{0}:count شهر', '{1}شهر', '{2}شهرين', ']2,11[:count أشهر', ']10,Inf[:count شهر']),
|
||||
'week' => implode('|', ['{0}:count أسبوع', '{1}أسبوع', '{2}أسبوعين', ']2,11[:count أسابيع', ']10,Inf[:count أسبوع']),
|
||||
'a_week' => implode('|', ['{0}:count أسبوع', '{1}أسبوع', '{2}أسبوعين', ']2,11[:count أسابيع', ']10,Inf[:count أسبوع']),
|
||||
'day' => implode('|', ['{0}:count يوم', '{1}يوم', '{2}يومين', ']2,11[:count أيام', ']10,Inf[:count يوم']),
|
||||
'a_day' => implode('|', ['{0}:count يوم', '{1}يوم', '{2}يومين', ']2,11[:count أيام', ']10,Inf[:count يوم']),
|
||||
'hour' => implode('|', ['{0}:count ساعة', '{1}ساعة', '{2}ساعتين', ']2,11[:count ساعات', ']10,Inf[:count ساعة']),
|
||||
'a_hour' => implode('|', ['{0}:count ساعة', '{1}ساعة', '{2}ساعتين', ']2,11[:count ساعات', ']10,Inf[:count ساعة']),
|
||||
'minute' => implode('|', ['{0}:count دقيقة', '{1}دقيقة', '{2}دقيقتين', ']2,11[:count دقائق', ']10,Inf[:count دقيقة']),
|
||||
'a_minute' => implode('|', ['{0}:count دقيقة', '{1}دقيقة', '{2}دقيقتين', ']2,11[:count دقائق', ']10,Inf[:count دقيقة']),
|
||||
'second' => implode('|', ['{0}:count ثانية', '{1}ثانية', '{2}ثانيتين', ']2,11[:count ثواني', ']10,Inf[:count ثانية']),
|
||||
'a_second' => implode('|', ['{0}:count ثانية', '{1}ثانية', '{2}ثانيتين', ']2,11[:count ثواني', ']10,Inf[:count ثانية']),
|
||||
'year' => implode('|', [':count سنة', 'سنة', 'سنتين', ':count سنوات', ':count سنة', ':count سنة']),
|
||||
'a_year' => implode('|', [':count سنة', 'سنة', 'سنتين', ':count سنوات', ':count سنة', ':count سنة']),
|
||||
'month' => implode('|', [':count شهر', 'شهر', 'شهرين', ':count أشهر', ':count شهر', ':count شهر']),
|
||||
'a_month' => implode('|', [':count شهر', 'شهر', 'شهرين', ':count أشهر', ':count شهر', ':count شهر']),
|
||||
'week' => implode('|', [':count أسبوع', 'أسبوع', 'أسبوعين', ':count أسابيع', ':count أسبوع', ':count أسبوع']),
|
||||
'a_week' => implode('|', [':count أسبوع', 'أسبوع', 'أسبوعين', ':count أسابيع', ':count أسبوع', ':count أسبوع']),
|
||||
'day' => implode('|', [':count يوم', 'يوم', 'يومين', ':count أيام', ':count يوم', ':count يوم']),
|
||||
'a_day' => implode('|', [':count يوم', 'يوم', 'يومين', ':count أيام', ':count يوم', ':count يوم']),
|
||||
'hour' => implode('|', [':count ساعة', 'ساعة', 'ساعتين', ':count ساعات', ':count ساعة', ':count ساعة']),
|
||||
'a_hour' => implode('|', [':count ساعة', 'ساعة', 'ساعتين', ':count ساعات', ':count ساعة', ':count ساعة']),
|
||||
'minute' => implode('|', [':count دقيقة', 'دقيقة', 'دقيقتين', ':count دقائق', ':count دقيقة', ':count دقيقة']),
|
||||
'a_minute' => implode('|', [':count دقيقة', 'دقيقة', 'دقيقتين', ':count دقائق', ':count دقيقة', ':count دقيقة']),
|
||||
'second' => implode('|', [':count ثانية', 'ثانية', 'ثانيتين', ':count ثواني', ':count ثانية', ':count ثانية']),
|
||||
'a_second' => implode('|', [':count ثانية', 'ثانية', 'ثانيتين', ':count ثواني', ':count ثانية', ':count ثانية']),
|
||||
'ago' => 'منذ :time',
|
||||
'from_now' => ':time من الآن',
|
||||
'after' => 'بعد :time',
|
||||
@@ -57,10 +58,10 @@ return [
|
||||
'diff_yesterday' => 'أمس',
|
||||
'diff_yesterday_regexp' => 'أمس(?:\\s+عند)?(?:\\s+الساعة)?',
|
||||
'diff_tomorrow' => 'غداً',
|
||||
'diff_tomorrow_regexp' => 'غدًا(?:\\s+عند)?(?:\\s+الساعة)?',
|
||||
'diff_tomorrow_regexp' => 'غدً?اً?(?:\\s+عند)?(?:\\s+الساعة)?',
|
||||
'diff_before_yesterday' => 'قبل الأمس',
|
||||
'diff_after_tomorrow' => 'بعد غد',
|
||||
'period_recurrences' => implode('|', ['{0}مرة', '{1}مرة', '{2}:count مرتين', ']2,11[:count مرات', ']10,Inf[:count مرة']),
|
||||
'period_recurrences' => implode('|', [':count مرة', 'مرة', 'مرتين', ':count مرات', ':count مرة', ':count مرة']),
|
||||
'period_interval' => 'كل :interval',
|
||||
'period_start_date' => 'من :date',
|
||||
'period_end_date' => 'إلى :date',
|
||||
|
||||
@@ -20,7 +20,7 @@ return array_replace_recursive(require __DIR__.'/ar.php', [
|
||||
],
|
||||
'months' => ['يناير', 'فبراير', 'مارس', 'أبريل', 'مايو', 'يونيو', 'يوليو', 'أغسطس', 'سبتمبر', 'أكتوبر', 'نوفمبر', 'ديسمبر'],
|
||||
'months_short' => ['ينا', 'فبر', 'مار', 'أبر', 'ماي', 'يون', 'يول', 'أغس', 'سبت', 'أكت', 'نوف', 'ديس'],
|
||||
'weekdays' => ['الأحد', 'الاثنين', 'الثلاثاء', 'الأربعاء', 'الخميس', 'الجمعة', 'السبت '],
|
||||
'weekdays' => ['الأحد', 'الاثنين', 'الثلاثاء', 'الأربعاء', 'الخميس', 'الجمعة', 'السبت'],
|
||||
'weekdays_short' => ['ح', 'ن', 'ث', 'ر', 'خ', 'ج', 'س'],
|
||||
'weekdays_min' => ['ح', 'ن', 'ث', 'ر', 'خ', 'ج', 'س'],
|
||||
'first_day_of_week' => 6,
|
||||
|
||||
+17
-16
@@ -16,6 +16,7 @@
|
||||
* - JD Isaacks
|
||||
* - Atef Ben Ali (atefBB)
|
||||
* - Mohamed Sabil (mohamedsabil83)
|
||||
* - Mousab Salah (123mousab)
|
||||
*/
|
||||
$months = [
|
||||
'جانفي',
|
||||
@@ -33,20 +34,20 @@ $months = [
|
||||
];
|
||||
|
||||
return [
|
||||
'year' => implode('|', ['{0}:count سنة', '{1}سنة', '{2}سنتين', ']2,11[:count سنوات', ']10,Inf[:count سنة']),
|
||||
'a_year' => implode('|', ['{0}:count سنة', '{1}سنة', '{2}سنتين', ']2,11[:count سنوات', ']10,Inf[:count سنة']),
|
||||
'month' => implode('|', ['{0}:count شهر', '{1}شهر', '{2}شهرين', ']2,11[:count أشهر', ']10,Inf[:count شهر']),
|
||||
'a_month' => implode('|', ['{0}:count شهر', '{1}شهر', '{2}شهرين', ']2,11[:count أشهر', ']10,Inf[:count شهر']),
|
||||
'week' => implode('|', ['{0}:count أسبوع', '{1}أسبوع', '{2}أسبوعين', ']2,11[:count أسابيع', ']10,Inf[:count أسبوع']),
|
||||
'a_week' => implode('|', ['{0}:count أسبوع', '{1}أسبوع', '{2}أسبوعين', ']2,11[:count أسابيع', ']10,Inf[:count أسبوع']),
|
||||
'day' => implode('|', ['{0}:count يوم', '{1}يوم', '{2}يومين', ']2,11[:count أيام', ']10,Inf[:count يوم']),
|
||||
'a_day' => implode('|', ['{0}:count يوم', '{1}يوم', '{2}يومين', ']2,11[:count أيام', ']10,Inf[:count يوم']),
|
||||
'hour' => implode('|', ['{0}:count ساعة', '{1}ساعة', '{2}ساعتين', ']2,11[:count ساعات', ']10,Inf[:count ساعة']),
|
||||
'a_hour' => implode('|', ['{0}:count ساعة', '{1}ساعة', '{2}ساعتين', ']2,11[:count ساعات', ']10,Inf[:count ساعة']),
|
||||
'minute' => implode('|', ['{0}:count دقيقة', '{1}دقيقة', '{2}دقيقتين', ']2,11[:count دقائق', ']10,Inf[:count دقيقة']),
|
||||
'a_minute' => implode('|', ['{0}:count دقيقة', '{1}دقيقة', '{2}دقيقتين', ']2,11[:count دقائق', ']10,Inf[:count دقيقة']),
|
||||
'second' => implode('|', ['{0}:count ثانية', '{1}ثانية', '{2}ثانيتين', ']2,11[:count ثواني', ']10,Inf[:count ثانية']),
|
||||
'a_second' => implode('|', ['{0}:count ثانية', '{1}ثانية', '{2}ثانيتين', ']2,11[:count ثواني', ']10,Inf[:count ثانية']),
|
||||
'year' => implode('|', [':count سنة', 'سنة', 'سنتين', ':count سنوات', ':count سنة', ':count سنة']),
|
||||
'a_year' => implode('|', [':count سنة', 'سنة', 'سنتين', ':count سنوات', ':count سنة', ':count سنة']),
|
||||
'month' => implode('|', [':count شهر', 'شهر', 'شهرين', ':count أشهر', ':count شهر', ':count شهر']),
|
||||
'a_month' => implode('|', [':count شهر', 'شهر', 'شهرين', ':count أشهر', ':count شهر', ':count شهر']),
|
||||
'week' => implode('|', [':count أسبوع', 'أسبوع', 'أسبوعين', ':count أسابيع', ':count أسبوع', ':count أسبوع']),
|
||||
'a_week' => implode('|', [':count أسبوع', 'أسبوع', 'أسبوعين', ':count أسابيع', ':count أسبوع', ':count أسبوع']),
|
||||
'day' => implode('|', [':count يوم', 'يوم', 'يومين', ':count أيام', ':count يوم', ':count يوم']),
|
||||
'a_day' => implode('|', [':count يوم', 'يوم', 'يومين', ':count أيام', ':count يوم', ':count يوم']),
|
||||
'hour' => implode('|', [':count ساعة', 'ساعة', 'ساعتين', ':count ساعات', ':count ساعة', ':count ساعة']),
|
||||
'a_hour' => implode('|', [':count ساعة', 'ساعة', 'ساعتين', ':count ساعات', ':count ساعة', ':count ساعة']),
|
||||
'minute' => implode('|', [':count دقيقة', 'دقيقة', 'دقيقتين', ':count دقائق', ':count دقيقة', ':count دقيقة']),
|
||||
'a_minute' => implode('|', [':count دقيقة', 'دقيقة', 'دقيقتين', ':count دقائق', ':count دقيقة', ':count دقيقة']),
|
||||
'second' => implode('|', [':count ثانية', 'ثانية', 'ثانيتين', ':count ثواني', ':count ثانية', ':count ثانية']),
|
||||
'a_second' => implode('|', [':count ثانية', 'ثانية', 'ثانيتين', ':count ثواني', ':count ثانية', ':count ثانية']),
|
||||
'ago' => 'منذ :time',
|
||||
'from_now' => 'في :time',
|
||||
'after' => 'بعد :time',
|
||||
@@ -57,10 +58,10 @@ return [
|
||||
'diff_yesterday' => 'أمس',
|
||||
'diff_yesterday_regexp' => 'أمس(?:\\s+على)?(?:\\s+الساعة)?',
|
||||
'diff_tomorrow' => 'غداً',
|
||||
'diff_tomorrow_regexp' => 'غدا(?:\\s+على)?(?:\\s+الساعة)?',
|
||||
'diff_tomorrow_regexp' => 'غدً?اً?(?:\\s+على)?(?:\\s+الساعة)?',
|
||||
'diff_before_yesterday' => 'قبل الأمس',
|
||||
'diff_after_tomorrow' => 'بعد غد',
|
||||
'period_recurrences' => implode('|', ['{0}مرة', '{1}مرة', '{2}:count مرتين', ']2,11[:count مرات', ']10,Inf[:count مرة']),
|
||||
'period_recurrences' => implode('|', [':count مرة', 'مرة', 'مرتين', ':count مرات', ':count مرة', ':count مرة']),
|
||||
'period_interval' => 'كل :interval',
|
||||
'period_start_date' => 'من :date',
|
||||
'period_end_date' => 'إلى :date',
|
||||
|
||||
+23
-22
@@ -17,37 +17,38 @@
|
||||
* - Atef Ben Ali (atefBB)
|
||||
* - Mohamed Sabil (mohamedsabil83)
|
||||
* - Abdullah-Alhariri
|
||||
* - Mousab Salah (123mousab)
|
||||
*/
|
||||
$months = [
|
||||
'يناير',
|
||||
'فبراير',
|
||||
'مارس',
|
||||
'أبريل',
|
||||
'ماي',
|
||||
'مايو',
|
||||
'يونيو',
|
||||
'يوليوز',
|
||||
'غشت',
|
||||
'شتنبر',
|
||||
'يوليو',
|
||||
'أغسطس',
|
||||
'سبتمبر',
|
||||
'أكتوبر',
|
||||
'نونبر',
|
||||
'دجنبر',
|
||||
'نوفمبر',
|
||||
'ديسمبر',
|
||||
];
|
||||
|
||||
return [
|
||||
'year' => implode('|', ['{0}:count سنة', '{1}سنة', '{2}سنتين', ']2,11[:count سنوات', ']10,Inf[:count سنة']),
|
||||
'a_year' => implode('|', ['{0}:count سنة', '{1}سنة', '{2}سنتين', ']2,11[:count سنوات', ']10,Inf[:count سنة']),
|
||||
'month' => implode('|', ['{0}:count شهر', '{1}شهر', '{2}شهرين', ']2,11[:count أشهر', ']10,Inf[:count شهر']),
|
||||
'a_month' => implode('|', ['{0}:count شهر', '{1}شهر', '{2}شهرين', ']2,11[:count أشهر', ']10,Inf[:count شهر']),
|
||||
'week' => implode('|', ['{0}:count أسبوع', '{1}أسبوع', '{2}أسبوعين', ']2,11[:count أسابيع', ']10,Inf[:count أسبوع']),
|
||||
'a_week' => implode('|', ['{0}:count أسبوع', '{1}أسبوع', '{2}أسبوعين', ']2,11[:count أسابيع', ']10,Inf[:count أسبوع']),
|
||||
'day' => implode('|', ['{0}:count يوم', '{1}يوم', '{2}يومين', ']2,11[:count أيام', ']10,Inf[:count يوم']),
|
||||
'a_day' => implode('|', ['{0}:count يوم', '{1}يوم', '{2}يومين', ']2,11[:count أيام', ']10,Inf[:count يوم']),
|
||||
'hour' => implode('|', ['{0}:count ساعة', '{1}ساعة', '{2}ساعتين', ']2,11[:count ساعات', ']10,Inf[:count ساعة']),
|
||||
'a_hour' => implode('|', ['{0}:count ساعة', '{1}ساعة', '{2}ساعتين', ']2,11[:count ساعات', ']10,Inf[:count ساعة']),
|
||||
'minute' => implode('|', ['{0}:count دقيقة', '{1}دقيقة', '{2}دقيقتين', ']2,11[:count دقائق', ']10,Inf[:count دقيقة']),
|
||||
'a_minute' => implode('|', ['{0}:count دقيقة', '{1}دقيقة', '{2}دقيقتين', ']2,11[:count دقائق', ']10,Inf[:count دقيقة']),
|
||||
'second' => implode('|', ['{0}:count ثانية', '{1}ثانية', '{2}ثانيتين', ']2,11[:count ثواني', ']10,Inf[:count ثانية']),
|
||||
'a_second' => implode('|', ['{0}:count ثانية', '{1}ثانية', '{2}ثانيتين', ']2,11[:count ثواني', ']10,Inf[:count ثانية']),
|
||||
'year' => implode('|', [':count سنة', 'سنة', 'سنتين', ':count سنوات', ':count سنة', ':count سنة']),
|
||||
'a_year' => implode('|', [':count سنة', 'سنة', 'سنتين', ':count سنوات', ':count سنة', ':count سنة']),
|
||||
'month' => implode('|', [':count شهر', 'شهر', 'شهرين', ':count أشهر', ':count شهر', ':count شهر']),
|
||||
'a_month' => implode('|', [':count شهر', 'شهر', 'شهرين', ':count أشهر', ':count شهر', ':count شهر']),
|
||||
'week' => implode('|', [':count أسبوع', 'أسبوع', 'أسبوعين', ':count أسابيع', ':count أسبوع', ':count أسبوع']),
|
||||
'a_week' => implode('|', [':count أسبوع', 'أسبوع', 'أسبوعين', ':count أسابيع', ':count أسبوع', ':count أسبوع']),
|
||||
'day' => implode('|', [':count يوم', 'يوم', 'يومين', ':count أيام', ':count يوم', ':count يوم']),
|
||||
'a_day' => implode('|', [':count يوم', 'يوم', 'يومين', ':count أيام', ':count يوم', ':count يوم']),
|
||||
'hour' => implode('|', [':count ساعة', 'ساعة', 'ساعتين', ':count ساعات', ':count ساعة', ':count ساعة']),
|
||||
'a_hour' => implode('|', [':count ساعة', 'ساعة', 'ساعتين', ':count ساعات', ':count ساعة', ':count ساعة']),
|
||||
'minute' => implode('|', [':count دقيقة', 'دقيقة', 'دقيقتين', ':count دقائق', ':count دقيقة', ':count دقيقة']),
|
||||
'a_minute' => implode('|', [':count دقيقة', 'دقيقة', 'دقيقتين', ':count دقائق', ':count دقيقة', ':count دقيقة']),
|
||||
'second' => implode('|', [':count ثانية', 'ثانية', 'ثانيتين', ':count ثواني', ':count ثانية', ':count ثانية']),
|
||||
'a_second' => implode('|', [':count ثانية', 'ثانية', 'ثانيتين', ':count ثواني', ':count ثانية', ':count ثانية']),
|
||||
'ago' => 'منذ :time',
|
||||
'from_now' => 'في :time',
|
||||
'after' => 'بعد :time',
|
||||
@@ -58,10 +59,10 @@ return [
|
||||
'diff_yesterday' => 'أمس',
|
||||
'diff_yesterday_regexp' => 'أمس(?:\\s+على)?(?:\\s+الساعة)?',
|
||||
'diff_tomorrow' => 'غداً',
|
||||
'diff_tomorrow_regexp' => 'غدا(?:\\s+على)?(?:\\s+الساعة)?',
|
||||
'diff_tomorrow_regexp' => 'غدً?اً?(?:\\s+على)?(?:\\s+الساعة)?',
|
||||
'diff_before_yesterday' => 'قبل الأمس',
|
||||
'diff_after_tomorrow' => 'بعد غد',
|
||||
'period_recurrences' => implode('|', ['{0}مرة', '{1}مرة', '{2}:count مرتين', ']2,11[:count مرات', ']10,Inf[:count مرة']),
|
||||
'period_recurrences' => implode('|', [':count مرة', 'مرة', 'مرتين', ':count مرات', ':count مرة', ':count مرة']),
|
||||
'period_interval' => 'كل :interval',
|
||||
'period_start_date' => 'من :date',
|
||||
'period_end_date' => 'إلى :date',
|
||||
|
||||
+17
-16
@@ -14,6 +14,7 @@
|
||||
* - Atef Ben Ali (atefBB)
|
||||
* - Ibrahim AshShohail
|
||||
* - MLTDev
|
||||
* - Mousab Salah (123mousab)
|
||||
*/
|
||||
|
||||
$months = [
|
||||
@@ -32,20 +33,20 @@ $months = [
|
||||
];
|
||||
|
||||
return [
|
||||
'year' => implode('|', [':count سنة', 'سنة', 'سنتين', ':count سنوات', ':count سنة']),
|
||||
'a_year' => implode('|', [':count سنة', 'سنة', 'سنتين', ':count سنوات', ':count سنة']),
|
||||
'month' => implode('|', [':count شهر', 'شهر', 'شهرين', ':count أشهر', ':count شهر']),
|
||||
'a_month' => implode('|', [':count شهر', 'شهر', 'شهرين', ':count أشهر', ':count شهر']),
|
||||
'week' => implode('|', [':count أسبوع', 'أسبوع', 'أسبوعين', ':count أسابيع', ':count أسبوع']),
|
||||
'a_week' => implode('|', [':count أسبوع', 'أسبوع', 'أسبوعين', ':count أسابيع', ':count أسبوع']),
|
||||
'day' => implode('|', [':count يوم', 'يوم', 'يومين', ':count أيام', ':count يوم']),
|
||||
'a_day' => implode('|', [':count يوم', 'يوم', 'يومين', ':count أيام', ':count يوم']),
|
||||
'hour' => implode('|', [':count ساعة', 'ساعة', 'ساعتين', ':count ساعات', ':count ساعة']),
|
||||
'a_hour' => implode('|', [':count ساعة', 'ساعة', 'ساعتين', ':count ساعات', ':count ساعة']),
|
||||
'minute' => implode('|', [':count دقيقة', 'دقيقة', 'دقيقتين', ':count دقائق', ':count دقيقة']),
|
||||
'a_minute' => implode('|', [':count دقيقة', 'دقيقة', 'دقيقتين', ':count دقائق', ':count دقيقة']),
|
||||
'second' => implode('|', [':count ثانية', 'ثانية', 'ثانيتين', ':count ثواني', ':count ثانية']),
|
||||
'a_second' => implode('|', [':count ثانية', 'ثانية', 'ثانيتين', ':count ثواني', ':count ثانية']),
|
||||
'year' => implode('|', [':count سنة', 'سنة', 'سنتين', ':count سنوات', ':count سنة', ':count سنة']),
|
||||
'a_year' => implode('|', [':count سنة', 'سنة', 'سنتين', ':count سنوات', ':count سنة', ':count سنة']),
|
||||
'month' => implode('|', [':count شهر', 'شهر', 'شهرين', ':count أشهر', ':count شهر', ':count شهر']),
|
||||
'a_month' => implode('|', [':count شهر', 'شهر', 'شهرين', ':count أشهر', ':count شهر', ':count شهر']),
|
||||
'week' => implode('|', [':count أسبوع', 'أسبوع', 'أسبوعين', ':count أسابيع', ':count أسبوع', ':count أسبوع']),
|
||||
'a_week' => implode('|', [':count أسبوع', 'أسبوع', 'أسبوعين', ':count أسابيع', ':count أسبوع', ':count أسبوع']),
|
||||
'day' => implode('|', [':count يوم', 'يوم', 'يومين', ':count أيام', ':count يوم', ':count يوم']),
|
||||
'a_day' => implode('|', [':count يوم', 'يوم', 'يومين', ':count أيام', ':count يوم', ':count يوم']),
|
||||
'hour' => implode('|', [':count ساعة', 'ساعة', 'ساعتين', ':count ساعات', ':count ساعة', ':count ساعة']),
|
||||
'a_hour' => implode('|', [':count ساعة', 'ساعة', 'ساعتين', ':count ساعات', ':count ساعة', ':count ساعة']),
|
||||
'minute' => implode('|', [':count دقيقة', 'دقيقة', 'دقيقتين', ':count دقائق', ':count دقيقة', ':count دقيقة']),
|
||||
'a_minute' => implode('|', [':count دقيقة', 'دقيقة', 'دقيقتين', ':count دقائق', ':count دقيقة', ':count دقيقة']),
|
||||
'second' => implode('|', [':count ثانية', 'ثانية', 'ثانيتين', ':count ثواني', ':count ثانية', ':count ثانية']),
|
||||
'a_second' => implode('|', [':count ثانية', 'ثانية', 'ثانيتين', ':count ثواني', ':count ثانية', ':count ثانية']),
|
||||
'ago' => 'منذ :time',
|
||||
'from_now' => ':time من الآن',
|
||||
'after' => 'بعد :time',
|
||||
@@ -56,10 +57,10 @@ return [
|
||||
'diff_yesterday' => 'أمس',
|
||||
'diff_yesterday_regexp' => 'أمس(?:\\s+عند)?(?:\\s+الساعة)?',
|
||||
'diff_tomorrow' => 'غداً',
|
||||
'diff_tomorrow_regexp' => 'غدًا(?:\\s+عند)?(?:\\s+الساعة)?',
|
||||
'diff_tomorrow_regexp' => 'غدً?اً?(?:\\s+عند)?(?:\\s+الساعة)?',
|
||||
'diff_before_yesterday' => 'قبل الأمس',
|
||||
'diff_after_tomorrow' => 'بعد غد',
|
||||
'period_recurrences' => implode('|', ['مرة', 'مرة', ':count مرتين', ':count مرات', ':count مرة']),
|
||||
'period_recurrences' => implode('|', [':count مرة', 'مرة', 'مرتين', ':count مرات', ':count مرة', ':count مرة']),
|
||||
'period_interval' => 'كل :interval',
|
||||
'period_start_date' => 'من :date',
|
||||
'period_end_date' => 'إلى :date',
|
||||
|
||||
+17
-16
@@ -15,6 +15,7 @@
|
||||
* - JD Isaacks
|
||||
* - Atef Ben Ali (atefBB)
|
||||
* - Mohamed Sabil (mohamedsabil83)
|
||||
* - Mousab Salah (123mousab)
|
||||
*/
|
||||
$months = [
|
||||
'يناير',
|
||||
@@ -32,20 +33,20 @@ $months = [
|
||||
];
|
||||
|
||||
return [
|
||||
'year' => implode('|', ['{0}:count سنة', '{1}سنة', '{2}سنتين', ']2,11[:count سنوات', ']10,Inf[:count سنة']),
|
||||
'a_year' => implode('|', ['{0}:count سنة', '{1}سنة', '{2}سنتين', ']2,11[:count سنوات', ']10,Inf[:count سنة']),
|
||||
'month' => implode('|', ['{0}:count شهر', '{1}شهر', '{2}شهرين', ']2,11[:count أشهر', ']10,Inf[:count شهر']),
|
||||
'a_month' => implode('|', ['{0}:count شهر', '{1}شهر', '{2}شهرين', ']2,11[:count أشهر', ']10,Inf[:count شهر']),
|
||||
'week' => implode('|', ['{0}:count أسبوع', '{1}أسبوع', '{2}أسبوعين', ']2,11[:count أسابيع', ']10,Inf[:count أسبوع']),
|
||||
'a_week' => implode('|', ['{0}:count أسبوع', '{1}أسبوع', '{2}أسبوعين', ']2,11[:count أسابيع', ']10,Inf[:count أسبوع']),
|
||||
'day' => implode('|', ['{0}:count يوم', '{1}يوم', '{2}يومين', ']2,11[:count أيام', ']10,Inf[:count يوم']),
|
||||
'a_day' => implode('|', ['{0}:count يوم', '{1}يوم', '{2}يومين', ']2,11[:count أيام', ']10,Inf[:count يوم']),
|
||||
'hour' => implode('|', ['{0}:count ساعة', '{1}ساعة', '{2}ساعتين', ']2,11[:count ساعات', ']10,Inf[:count ساعة']),
|
||||
'a_hour' => implode('|', ['{0}:count ساعة', '{1}ساعة', '{2}ساعتين', ']2,11[:count ساعات', ']10,Inf[:count ساعة']),
|
||||
'minute' => implode('|', ['{0}:count دقيقة', '{1}دقيقة', '{2}دقيقتين', ']2,11[:count دقائق', ']10,Inf[:count دقيقة']),
|
||||
'a_minute' => implode('|', ['{0}:count دقيقة', '{1}دقيقة', '{2}دقيقتين', ']2,11[:count دقائق', ']10,Inf[:count دقيقة']),
|
||||
'second' => implode('|', ['{0}:count ثانية', '{1}ثانية', '{2}ثانيتين', ']2,11[:count ثواني', ']10,Inf[:count ثانية']),
|
||||
'a_second' => implode('|', ['{0}:count ثانية', '{1}ثانية', '{2}ثانيتين', ']2,11[:count ثواني', ']10,Inf[:count ثانية']),
|
||||
'year' => implode('|', [':count سنة', 'سنة', 'سنتين', ':count سنوات', ':count سنة', ':count سنة']),
|
||||
'a_year' => implode('|', [':count سنة', 'سنة', 'سنتين', ':count سنوات', ':count سنة', ':count سنة']),
|
||||
'month' => implode('|', [':count شهر', 'شهر', 'شهرين', ':count أشهر', ':count شهر', ':count شهر']),
|
||||
'a_month' => implode('|', [':count شهر', 'شهر', 'شهرين', ':count أشهر', ':count شهر', ':count شهر']),
|
||||
'week' => implode('|', [':count أسبوع', 'أسبوع', 'أسبوعين', ':count أسابيع', ':count أسبوع', ':count أسبوع']),
|
||||
'a_week' => implode('|', [':count أسبوع', 'أسبوع', 'أسبوعين', ':count أسابيع', ':count أسبوع', ':count أسبوع']),
|
||||
'day' => implode('|', [':count يوم', 'يوم', 'يومين', ':count أيام', ':count يوم', ':count يوم']),
|
||||
'a_day' => implode('|', [':count يوم', 'يوم', 'يومين', ':count أيام', ':count يوم', ':count يوم']),
|
||||
'hour' => implode('|', [':count ساعة', 'ساعة', 'ساعتين', ':count ساعات', ':count ساعة', ':count ساعة']),
|
||||
'a_hour' => implode('|', [':count ساعة', 'ساعة', 'ساعتين', ':count ساعات', ':count ساعة', ':count ساعة']),
|
||||
'minute' => implode('|', [':count دقيقة', 'دقيقة', 'دقيقتين', ':count دقائق', ':count دقيقة', ':count دقيقة']),
|
||||
'a_minute' => implode('|', [':count دقيقة', 'دقيقة', 'دقيقتين', ':count دقائق', ':count دقيقة', ':count دقيقة']),
|
||||
'second' => implode('|', [':count ثانية', 'ثانية', 'ثانيتين', ':count ثواني', ':count ثانية', ':count ثانية']),
|
||||
'a_second' => implode('|', [':count ثانية', 'ثانية', 'ثانيتين', ':count ثواني', ':count ثانية', ':count ثانية']),
|
||||
'ago' => 'منذ :time',
|
||||
'from_now' => 'في :time',
|
||||
'after' => 'بعد :time',
|
||||
@@ -56,10 +57,10 @@ return [
|
||||
'diff_yesterday' => 'أمس',
|
||||
'diff_yesterday_regexp' => 'أمس(?:\\s+على)?(?:\\s+الساعة)?',
|
||||
'diff_tomorrow' => 'غداً',
|
||||
'diff_tomorrow_regexp' => 'غدا(?:\\s+على)?(?:\\s+الساعة)?',
|
||||
'diff_tomorrow_regexp' => 'غدً?اً?(?:\\s+على)?(?:\\s+الساعة)?',
|
||||
'diff_before_yesterday' => 'قبل الأمس',
|
||||
'diff_after_tomorrow' => 'بعد غد',
|
||||
'period_recurrences' => implode('|', ['{0}مرة', '{1}مرة', '{2}:count مرتين', ']2,11[:count مرات', ']10,Inf[:count مرة']),
|
||||
'period_recurrences' => implode('|', [':count مرة', 'مرة', 'مرتين', ':count مرات', ':count مرة', ':count مرة']),
|
||||
'period_interval' => 'كل :interval',
|
||||
'period_start_date' => 'من :date',
|
||||
'period_end_date' => 'إلى :date',
|
||||
|
||||
+17
-16
@@ -16,6 +16,7 @@
|
||||
* - Atef Ben Ali (atefBB)
|
||||
* - Mohamed Sabil (mohamedsabil83)
|
||||
* - Abdullah-Alhariri
|
||||
* - Mousab Salah (123mousab)
|
||||
*/
|
||||
$months = [
|
||||
'يناير',
|
||||
@@ -33,20 +34,20 @@ $months = [
|
||||
];
|
||||
|
||||
return [
|
||||
'year' => implode('|', ['{0}:count سنة', '{1}سنة', '{2}سنتين', ']2,11[:count سنوات', ']10,Inf[:count سنة']),
|
||||
'a_year' => implode('|', ['{0}:count سنة', '{1}سنة', '{2}سنتين', ']2,11[:count سنوات', ']10,Inf[:count سنة']),
|
||||
'month' => implode('|', ['{0}:count شهر', '{1}شهر', '{2}شهرين', ']2,11[:count أشهر', ']10,Inf[:count شهر']),
|
||||
'a_month' => implode('|', ['{0}:count شهر', '{1}شهر', '{2}شهرين', ']2,11[:count أشهر', ']10,Inf[:count شهر']),
|
||||
'week' => implode('|', ['{0}:count أسبوع', '{1}أسبوع', '{2}أسبوعين', ']2,11[:count أسابيع', ']10,Inf[:count أسبوع']),
|
||||
'a_week' => implode('|', ['{0}:count أسبوع', '{1}أسبوع', '{2}أسبوعين', ']2,11[:count أسابيع', ']10,Inf[:count أسبوع']),
|
||||
'day' => implode('|', ['{0}:count يوم', '{1}يوم', '{2}يومين', ']2,11[:count أيام', ']10,Inf[:count يوم']),
|
||||
'a_day' => implode('|', ['{0}:count يوم', '{1}يوم', '{2}يومين', ']2,11[:count أيام', ']10,Inf[:count يوم']),
|
||||
'hour' => implode('|', ['{0}:count ساعة', '{1}ساعة', '{2}ساعتين', ']2,11[:count ساعات', ']10,Inf[:count ساعة']),
|
||||
'a_hour' => implode('|', ['{0}:count ساعة', '{1}ساعة', '{2}ساعتين', ']2,11[:count ساعات', ']10,Inf[:count ساعة']),
|
||||
'minute' => implode('|', ['{0}:count دقيقة', '{1}دقيقة', '{2}دقيقتين', ']2,11[:count دقائق', ']10,Inf[:count دقيقة']),
|
||||
'a_minute' => implode('|', ['{0}:count دقيقة', '{1}دقيقة', '{2}دقيقتين', ']2,11[:count دقائق', ']10,Inf[:count دقيقة']),
|
||||
'second' => implode('|', ['{0}:count ثانية', '{1}ثانية', '{2}ثانيتين', ']2,11[:count ثواني', ']10,Inf[:count ثانية']),
|
||||
'a_second' => implode('|', ['{0}:count ثانية', '{1}ثانية', '{2}ثانيتين', ']2,11[:count ثواني', ']10,Inf[:count ثانية']),
|
||||
'year' => implode('|', [':count سنة', 'سنة', 'سنتين', ':count سنوات', ':count سنة', ':count سنة']),
|
||||
'a_year' => implode('|', [':count سنة', 'سنة', 'سنتين', ':count سنوات', ':count سنة', ':count سنة']),
|
||||
'month' => implode('|', [':count شهر', 'شهر', 'شهرين', ':count أشهر', ':count شهر', ':count شهر']),
|
||||
'a_month' => implode('|', [':count شهر', 'شهر', 'شهرين', ':count أشهر', ':count شهر', ':count شهر']),
|
||||
'week' => implode('|', [':count أسبوع', 'أسبوع', 'أسبوعين', ':count أسابيع', ':count أسبوع', ':count أسبوع']),
|
||||
'a_week' => implode('|', [':count أسبوع', 'أسبوع', 'أسبوعين', ':count أسابيع', ':count أسبوع', ':count أسبوع']),
|
||||
'day' => implode('|', [':count يوم', 'يوم', 'يومين', ':count أيام', ':count يوم', ':count يوم']),
|
||||
'a_day' => implode('|', [':count يوم', 'يوم', 'يومين', ':count أيام', ':count يوم', ':count يوم']),
|
||||
'hour' => implode('|', [':count ساعة', 'ساعة', 'ساعتين', ':count ساعات', ':count ساعة', ':count ساعة']),
|
||||
'a_hour' => implode('|', [':count ساعة', 'ساعة', 'ساعتين', ':count ساعات', ':count ساعة', ':count ساعة']),
|
||||
'minute' => implode('|', [':count دقيقة', 'دقيقة', 'دقيقتين', ':count دقائق', ':count دقيقة', ':count دقيقة']),
|
||||
'a_minute' => implode('|', [':count دقيقة', 'دقيقة', 'دقيقتين', ':count دقائق', ':count دقيقة', ':count دقيقة']),
|
||||
'second' => implode('|', [':count ثانية', 'ثانية', 'ثانيتين', ':count ثواني', ':count ثانية', ':count ثانية']),
|
||||
'a_second' => implode('|', [':count ثانية', 'ثانية', 'ثانيتين', ':count ثواني', ':count ثانية', ':count ثانية']),
|
||||
'ago' => 'منذ :time',
|
||||
'from_now' => 'في :time',
|
||||
'after' => 'بعد :time',
|
||||
@@ -57,10 +58,10 @@ return [
|
||||
'diff_yesterday' => 'أمس',
|
||||
'diff_yesterday_regexp' => 'أمس(?:\\s+على)?(?:\\s+الساعة)?',
|
||||
'diff_tomorrow' => 'غداً',
|
||||
'diff_tomorrow_regexp' => 'غدا(?:\\s+على)?(?:\\s+الساعة)?',
|
||||
'diff_tomorrow_regexp' => 'غدً?اً?(?:\\s+على)?(?:\\s+الساعة)?',
|
||||
'diff_before_yesterday' => 'قبل الأمس',
|
||||
'diff_after_tomorrow' => 'بعد غد',
|
||||
'period_recurrences' => implode('|', ['{0}مرة', '{1}مرة', '{2}:count مرتين', ']2,11[:count مرات', ']10,Inf[:count مرة']),
|
||||
'period_recurrences' => implode('|', [':count مرة', 'مرة', 'مرتين', ':count مرات', ':count مرة', ':count مرة']),
|
||||
'period_interval' => 'كل :interval',
|
||||
'period_start_date' => 'من :date',
|
||||
'period_end_date' => 'إلى :date',
|
||||
|
||||
@@ -14,6 +14,7 @@
|
||||
* - Abdellah Chadidi
|
||||
* - Atef Ben Ali (atefBB)
|
||||
* - Mohamed Sabil (mohamedsabil83)
|
||||
* - Mousab Salah (123mousab)
|
||||
*/
|
||||
// Same for long and short
|
||||
$months = [
|
||||
@@ -33,20 +34,20 @@ $months = [
|
||||
];
|
||||
|
||||
return [
|
||||
'year' => implode('|', ['{0}:count سَنَة', '{1}سَنَة', '{2}سَنَتَيْن', ']2,11[:count سَنَوَات', ']10,Inf[:count سَنَة']),
|
||||
'a_year' => implode('|', ['{0}:count سَنَة', '{1}سَنَة', '{2}سَنَتَيْن', ']2,11[:count سَنَوَات', ']10,Inf[:count سَنَة']),
|
||||
'month' => implode('|', ['{0}:count شَهْرَ', '{1}شَهْرَ', '{2}شَهْرَيْن', ']2,11[:count أَشْهُر', ']10,Inf[:count شَهْرَ']),
|
||||
'a_month' => implode('|', ['{0}:count شَهْرَ', '{1}شَهْرَ', '{2}شَهْرَيْن', ']2,11[:count أَشْهُر', ']10,Inf[:count شَهْرَ']),
|
||||
'week' => implode('|', ['{0}:count أُسْبُوع', '{1}أُسْبُوع', '{2}أُسْبُوعَيْن', ']2,11[:count أَسَابِيع', ']10,Inf[:count أُسْبُوع']),
|
||||
'a_week' => implode('|', ['{0}:count أُسْبُوع', '{1}أُسْبُوع', '{2}أُسْبُوعَيْن', ']2,11[:count أَسَابِيع', ']10,Inf[:count أُسْبُوع']),
|
||||
'day' => implode('|', ['{0}:count يَوْم', '{1}يَوْم', '{2}يَوْمَيْن', ']2,11[:count أَيَّام', ']10,Inf[:count يَوْم']),
|
||||
'a_day' => implode('|', ['{0}:count يَوْم', '{1}يَوْم', '{2}يَوْمَيْن', ']2,11[:count أَيَّام', ']10,Inf[:count يَوْم']),
|
||||
'hour' => implode('|', ['{0}:count سَاعَة', '{1}سَاعَة', '{2}سَاعَتَيْن', ']2,11[:count سَاعَات', ']10,Inf[:count سَاعَة']),
|
||||
'a_hour' => implode('|', ['{0}:count سَاعَة', '{1}سَاعَة', '{2}سَاعَتَيْن', ']2,11[:count سَاعَات', ']10,Inf[:count سَاعَة']),
|
||||
'minute' => implode('|', ['{0}:count دَقِيقَة', '{1}دَقِيقَة', '{2}دَقِيقَتَيْن', ']2,11[:count دَقَائِق', ']10,Inf[:count دَقِيقَة']),
|
||||
'a_minute' => implode('|', ['{0}:count دَقِيقَة', '{1}دَقِيقَة', '{2}دَقِيقَتَيْن', ']2,11[:count دَقَائِق', ']10,Inf[:count دَقِيقَة']),
|
||||
'second' => implode('|', ['{0}:count ثَانِيَة', '{1}ثَانِيَة', '{2}ثَانِيَتَيْن', ']2,11[:count ثَوَان', ']10,Inf[:count ثَانِيَة']),
|
||||
'a_second' => implode('|', ['{0}:count ثَانِيَة', '{1}ثَانِيَة', '{2}ثَانِيَتَيْن', ']2,11[:count ثَوَان', ']10,Inf[:count ثَانِيَة']),
|
||||
'year' => implode('|', [':count سَنَة', 'سَنَة', 'سَنَتَيْن', ':count سَنَوَات', ':count سَنَة', ':count سَنَة']),
|
||||
'a_year' => implode('|', [':count سَنَة', 'سَنَة', 'سَنَتَيْن', ':count سَنَوَات', ':count سَنَة', ':count سَنَة']),
|
||||
'month' => implode('|', [':count شَهْرَ', 'شَهْرَ', 'شَهْرَيْن', ':count أَشْهُر', ':count شَهْرَ', ':count شَهْرَ']),
|
||||
'a_month' => implode('|', [':count شَهْرَ', 'شَهْرَ', 'شَهْرَيْن', ':count أَشْهُر', ':count شَهْرَ', ':count شَهْرَ']),
|
||||
'week' => implode('|', [':count أُسْبُوع', 'أُسْبُوع', 'أُسْبُوعَيْن', ':count أَسَابِيع', ':count أُسْبُوع', ':count أُسْبُوع']),
|
||||
'a_week' => implode('|', [':count أُسْبُوع', 'أُسْبُوع', 'أُسْبُوعَيْن', ':count أَسَابِيع', ':count أُسْبُوع', ':count أُسْبُوع']),
|
||||
'day' => implode('|', [':count يَوْم', 'يَوْم', 'يَوْمَيْن', ':count أَيَّام', ':count يَوْم', ':count يَوْم']),
|
||||
'a_day' => implode('|', [':count يَوْم', 'يَوْم', 'يَوْمَيْن', ':count أَيَّام', ':count يَوْم', ':count يَوْم']),
|
||||
'hour' => implode('|', [':count سَاعَة', 'سَاعَة', 'سَاعَتَيْن', ':count سَاعَات', ':count سَاعَة', ':count سَاعَة']),
|
||||
'a_hour' => implode('|', [':count سَاعَة', 'سَاعَة', 'سَاعَتَيْن', ':count سَاعَات', ':count سَاعَة', ':count سَاعَة']),
|
||||
'minute' => implode('|', [':count دَقِيقَة', 'دَقِيقَة', 'دَقِيقَتَيْن', ':count دَقَائِق', ':count دَقِيقَة', ':count دَقِيقَة']),
|
||||
'a_minute' => implode('|', [':count دَقِيقَة', 'دَقِيقَة', 'دَقِيقَتَيْن', ':count دَقَائِق', ':count دَقِيقَة', ':count دَقِيقَة']),
|
||||
'second' => implode('|', [':count ثَانِيَة', 'ثَانِيَة', 'ثَانِيَتَيْن', ':count ثَوَان', ':count ثَانِيَة', ':count ثَانِيَة']),
|
||||
'a_second' => implode('|', [':count ثَانِيَة', 'ثَانِيَة', 'ثَانِيَتَيْن', ':count ثَوَان', ':count ثَانِيَة', ':count ثَانِيَة']),
|
||||
'ago' => 'مُنْذُ :time',
|
||||
'from_now' => 'مِنَ الْآن :time',
|
||||
'after' => 'بَعْدَ :time',
|
||||
@@ -59,10 +60,10 @@ return [
|
||||
'diff_yesterday' => 'أمس',
|
||||
'diff_yesterday_regexp' => 'أمس(?:\\s+عند)?(?:\\s+الساعة)?',
|
||||
'diff_tomorrow' => 'غداً',
|
||||
'diff_tomorrow_regexp' => 'غدًا(?:\\s+عند)?(?:\\s+الساعة)?',
|
||||
'diff_tomorrow_regexp' => 'غدً?اً?(?:\\s+عند)?(?:\\s+الساعة)?',
|
||||
'diff_before_yesterday' => 'قبل الأمس',
|
||||
'diff_after_tomorrow' => 'بعد غد',
|
||||
'period_recurrences' => implode('|', ['{0}مرة', '{1}مرة', '{2}:count مرتين', ']2,11[:count مرات', ']10,Inf[:count مرة']),
|
||||
'period_recurrences' => implode('|', [':count مرة', 'مرة', 'مرتين', ':count مرات', ':count مرة', ':count مرة']),
|
||||
'period_interval' => 'كل :interval',
|
||||
'period_start_date' => 'من :date',
|
||||
'period_end_date' => 'إلى :date',
|
||||
|
||||
+17
-16
@@ -14,6 +14,7 @@
|
||||
* - JD Isaacks
|
||||
* - Atef Ben Ali (atefBB)
|
||||
* - Mohamed Sabil (mohamedsabil83)
|
||||
* - Mousab Salah (123mousab)
|
||||
*/
|
||||
$months = [
|
||||
'جانفي',
|
||||
@@ -31,20 +32,20 @@ $months = [
|
||||
];
|
||||
|
||||
return [
|
||||
'year' => implode('|', ['{0}:count سنة', '{1}سنة', '{2}سنتين', ']2,11[:count سنوات', ']10,Inf[:count سنة']),
|
||||
'a_year' => implode('|', ['{0}:count سنة', '{1}سنة', '{2}سنتين', ']2,11[:count سنوات', ']10,Inf[:count سنة']),
|
||||
'month' => implode('|', ['{0}:count شهر', '{1}شهر', '{2}شهرين', ']2,11[:count أشهر', ']10,Inf[:count شهر']),
|
||||
'a_month' => implode('|', ['{0}:count شهر', '{1}شهر', '{2}شهرين', ']2,11[:count أشهر', ']10,Inf[:count شهر']),
|
||||
'week' => implode('|', ['{0}:count أسبوع', '{1}أسبوع', '{2}أسبوعين', ']2,11[:count أسابيع', ']10,Inf[:count أسبوع']),
|
||||
'a_week' => implode('|', ['{0}:count أسبوع', '{1}أسبوع', '{2}أسبوعين', ']2,11[:count أسابيع', ']10,Inf[:count أسبوع']),
|
||||
'day' => implode('|', ['{0}:count يوم', '{1}يوم', '{2}يومين', ']2,11[:count أيام', ']10,Inf[:count يوم']),
|
||||
'a_day' => implode('|', ['{0}:count يوم', '{1}يوم', '{2}يومين', ']2,11[:count أيام', ']10,Inf[:count يوم']),
|
||||
'hour' => implode('|', ['{0}:count ساعة', '{1}ساعة', '{2}ساعتين', ']2,11[:count ساعات', ']10,Inf[:count ساعة']),
|
||||
'a_hour' => implode('|', ['{0}:count ساعة', '{1}ساعة', '{2}ساعتين', ']2,11[:count ساعات', ']10,Inf[:count ساعة']),
|
||||
'minute' => implode('|', ['{0}:count دقيقة', '{1}دقيقة', '{2}دقيقتين', ']2,11[:count دقائق', ']10,Inf[:count دقيقة']),
|
||||
'a_minute' => implode('|', ['{0}:count دقيقة', '{1}دقيقة', '{2}دقيقتين', ']2,11[:count دقائق', ']10,Inf[:count دقيقة']),
|
||||
'second' => implode('|', ['{0}:count ثانية', '{1}ثانية', '{2}ثانيتين', ']2,11[:count ثواني', ']10,Inf[:count ثانية']),
|
||||
'a_second' => implode('|', ['{0}:count ثانية', '{1}ثانية', '{2}ثانيتين', ']2,11[:count ثواني', ']10,Inf[:count ثانية']),
|
||||
'year' => implode('|', [':count سنة', 'سنة', 'سنتين', ':count سنوات', ':count سنة', ':count سنة']),
|
||||
'a_year' => implode('|', [':count سنة', 'سنة', 'سنتين', ':count سنوات', ':count سنة', ':count سنة']),
|
||||
'month' => implode('|', [':count شهر', 'شهر', 'شهرين', ':count أشهر', ':count شهر', ':count شهر']),
|
||||
'a_month' => implode('|', [':count شهر', 'شهر', 'شهرين', ':count أشهر', ':count شهر', ':count شهر']),
|
||||
'week' => implode('|', [':count أسبوع', 'أسبوع', 'أسبوعين', ':count أسابيع', ':count أسبوع', ':count أسبوع']),
|
||||
'a_week' => implode('|', [':count أسبوع', 'أسبوع', 'أسبوعين', ':count أسابيع', ':count أسبوع', ':count أسبوع']),
|
||||
'day' => implode('|', [':count يوم', 'يوم', 'يومين', ':count أيام', ':count يوم', ':count يوم']),
|
||||
'a_day' => implode('|', [':count يوم', 'يوم', 'يومين', ':count أيام', ':count يوم', ':count يوم']),
|
||||
'hour' => implode('|', [':count ساعة', 'ساعة', 'ساعتين', ':count ساعات', ':count ساعة', ':count ساعة']),
|
||||
'a_hour' => implode('|', [':count ساعة', 'ساعة', 'ساعتين', ':count ساعات', ':count ساعة', ':count ساعة']),
|
||||
'minute' => implode('|', [':count دقيقة', 'دقيقة', 'دقيقتين', ':count دقائق', ':count دقيقة', ':count دقيقة']),
|
||||
'a_minute' => implode('|', [':count دقيقة', 'دقيقة', 'دقيقتين', ':count دقائق', ':count دقيقة', ':count دقيقة']),
|
||||
'second' => implode('|', [':count ثانية', 'ثانية', 'ثانيتين', ':count ثواني', ':count ثانية', ':count ثانية']),
|
||||
'a_second' => implode('|', [':count ثانية', 'ثانية', 'ثانيتين', ':count ثواني', ':count ثانية', ':count ثانية']),
|
||||
'ago' => 'منذ :time',
|
||||
'from_now' => 'في :time',
|
||||
'after' => 'بعد :time',
|
||||
@@ -55,10 +56,10 @@ return [
|
||||
'diff_yesterday' => 'أمس',
|
||||
'diff_yesterday_regexp' => 'أمس(?:\\s+على)?(?:\\s+الساعة)?',
|
||||
'diff_tomorrow' => 'غداً',
|
||||
'diff_tomorrow_regexp' => 'غدا(?:\\s+على)?(?:\\s+الساعة)?',
|
||||
'diff_tomorrow_regexp' => 'غدً?اً?(?:\\s+على)?(?:\\s+الساعة)?',
|
||||
'diff_before_yesterday' => 'قبل الأمس',
|
||||
'diff_after_tomorrow' => 'بعد غد',
|
||||
'period_recurrences' => implode('|', ['{0}مرة', '{1}مرة', '{2}:count مرتين', ']2,11[:count مرات', ']10,Inf[:count مرة']),
|
||||
'period_recurrences' => implode('|', [':count مرة', 'مرة', 'مرتين', ':count مرات', ':count مرة', ':count مرة']),
|
||||
'period_interval' => 'كل :interval',
|
||||
'period_start_date' => 'من :date',
|
||||
'period_end_date' => 'إلى :date',
|
||||
|
||||
@@ -22,6 +22,7 @@ return array_replace_recursive(require __DIR__.'/en.php', [
|
||||
'weekdays' => ['দেওবাৰ', 'সোমবাৰ', 'মঙ্গলবাৰ', 'বুধবাৰ', 'বৃহষ্পতিবাৰ', 'শুক্ৰবাৰ', 'শনিবাৰ'],
|
||||
'weekdays_short' => ['দেও', 'সোম', 'মঙ্গল', 'বুধ', 'বৃহষ্পতি', 'শুক্ৰ', 'শনি'],
|
||||
'weekdays_min' => ['দেও', 'সোম', 'মঙ্গল', 'বুধ', 'বৃহষ্পতি', 'শুক্ৰ', 'শনি'],
|
||||
'first_day_of_week' => 0,
|
||||
'day_of_first_week_of_year' => 1,
|
||||
'meridiem' => ['পূৰ্ব্বাহ্ন', 'অপৰাহ্ন'],
|
||||
|
||||
|
||||
@@ -22,6 +22,7 @@ return array_replace_recursive(require __DIR__.'/en.php', [
|
||||
'weekdays' => ['tuminku', 'lunisa', 'martisa', 'mirkulisa', 'juywisa', 'wirnisa', 'sawäru'],
|
||||
'weekdays_short' => ['tum', 'lun', 'mar', 'mir', 'juy', 'wir', 'saw'],
|
||||
'weekdays_min' => ['tum', 'lun', 'mar', 'mir', 'juy', 'wir', 'saw'],
|
||||
'first_day_of_week' => 0,
|
||||
'day_of_first_week_of_year' => 1,
|
||||
'meridiem' => ['VM', 'NM'],
|
||||
]);
|
||||
+15
-15
@@ -18,29 +18,30 @@
|
||||
* - Orxan
|
||||
* - Şəhriyar İmanov
|
||||
* - Baran Şengül
|
||||
* - Novruz Rahimov
|
||||
*/
|
||||
return [
|
||||
'year' => ':count il',
|
||||
'a_year' => '{1}bir il|]1,Inf[:count il',
|
||||
'a_year' => '{1}bir il|[-Inf,Inf]:count il',
|
||||
'y' => ':count il',
|
||||
'month' => ':count ay',
|
||||
'a_month' => '{1}bir ay|]1,Inf[:count ay',
|
||||
'a_month' => '{1}bir ay|[-Inf,Inf]:count ay',
|
||||
'm' => ':count ay',
|
||||
'week' => ':count həftə',
|
||||
'a_week' => '{1}bir həftə|]1,Inf[:count həftə',
|
||||
'a_week' => '{1}bir həftə|[-Inf,Inf]:count həftə',
|
||||
'w' => ':count h.',
|
||||
'day' => ':count gün',
|
||||
'a_day' => '{1}bir gün|]1,Inf[:count gün',
|
||||
'a_day' => '{1}bir gün|[-Inf,Inf]:count gün',
|
||||
'd' => ':count g.',
|
||||
'hour' => ':count saat',
|
||||
'a_hour' => '{1}bir saat|]1,Inf[:count saat',
|
||||
'h' => ':count saat',
|
||||
'minute' => ':count d.',
|
||||
'a_minute' => '{1}bir dəqiqə|]1,Inf[:count dəqiqə',
|
||||
'min' => ':count dəqiqə',
|
||||
'second' => ':count san.',
|
||||
'a_second' => '{1}birneçə saniyə|]1,Inf[:count saniyə',
|
||||
's' => ':count saniyə',
|
||||
'a_hour' => '{1}bir saat|[-Inf,Inf]:count saat',
|
||||
'h' => ':count s.',
|
||||
'minute' => ':count dəqiqə',
|
||||
'a_minute' => '{1}bir dəqiqə|[-Inf,Inf]:count dəqiqə',
|
||||
'min' => ':count d.',
|
||||
'second' => ':count saniyə',
|
||||
'a_second' => '{1}birneçə saniyə|[-Inf,Inf]:count saniyə',
|
||||
's' => ':count san.',
|
||||
'ago' => ':time əvvəl',
|
||||
'from_now' => ':time sonra',
|
||||
'after' => ':time sonra',
|
||||
@@ -73,7 +74,7 @@ return [
|
||||
'lastWeek' => '[keçən həftə] dddd [saat] LT',
|
||||
'sameElse' => 'L',
|
||||
],
|
||||
'ordinal' => function ($number) {
|
||||
'ordinal' => static function ($number) {
|
||||
if ($number === 0) { // special case for zero
|
||||
return "$number-ıncı";
|
||||
}
|
||||
@@ -103,7 +104,7 @@ return [
|
||||
|
||||
return $number.($suffixes[$lastDigit] ?? $suffixes[$number % 100 - $lastDigit] ?? $suffixes[$number >= 100 ? 100 : -1] ?? '');
|
||||
},
|
||||
'meridiem' => function ($hour) {
|
||||
'meridiem' => static function ($hour) {
|
||||
if ($hour < 4) {
|
||||
return 'gecə';
|
||||
}
|
||||
@@ -118,7 +119,6 @@ return [
|
||||
},
|
||||
'months' => ['yanvar', 'fevral', 'mart', 'aprel', 'may', 'iyun', 'iyul', 'avqust', 'sentyabr', 'oktyabr', 'noyabr', 'dekabr'],
|
||||
'months_short' => ['yan', 'fev', 'mar', 'apr', 'may', 'iyn', 'iyl', 'avq', 'sen', 'okt', 'noy', 'dek'],
|
||||
'months_standalone' => ['Yanvar', 'Fevral', 'Mart', 'Aprel', 'May', 'İyun', 'İyul', 'Avqust', 'Sentyabr', 'Oktyabr', 'Noyabr', 'Dekabr'],
|
||||
'weekdays' => ['bazar', 'bazar ertəsi', 'çərşənbə axşamı', 'çərşənbə', 'cümə axşamı', 'cümə', 'şənbə'],
|
||||
'weekdays_short' => ['baz', 'bze', 'çax', 'çər', 'cax', 'cüm', 'şən'],
|
||||
'weekdays_min' => ['bz', 'be', 'ça', 'çə', 'ca', 'cü', 'şə'],
|
||||
|
||||
@@ -0,0 +1,27 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* This file is part of the Carbon package.
|
||||
*
|
||||
* (c) Brian Nesbitt <brian@nesbot.com>
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
/*
|
||||
* Authors:
|
||||
* - Mousa Moradi mousamk@gmail.com
|
||||
*/
|
||||
return array_replace_recursive(require __DIR__.'/en.php', [
|
||||
'formats' => [
|
||||
'L' => 'OY/OM/OD',
|
||||
],
|
||||
'months' => ['ژانویه', 'فوریه', 'مارس', 'آوریل', 'مئی', 'ژوئن', 'جولای', 'آقۇست', 'سپتامبر', 'اوْکتوْبر', 'نوْوامبر', 'دسامبر'],
|
||||
'months_short' => ['ژانویه', 'فوریه', 'مارس', 'آوریل', 'مئی', 'ژوئن', 'جولای', 'آقۇست', 'سپتامبر', 'اوْکتوْبر', 'نوْوامبر', 'دسامبر'],
|
||||
'weekdays' => ['یکشنبه', 'دوشنبه', 'سهشنبه', 'چارشنبه', 'جۆمعه آخشامی', 'جۆمعه', 'شنبه'],
|
||||
'weekdays_short' => ['یکشنبه', 'دوشنبه', 'سهشنبه', 'چارشنبه', 'جۆمعه آخشامی', 'جۆمعه', 'شنبه'],
|
||||
'weekdays_min' => ['یکشنبه', 'دوشنبه', 'سهشنبه', 'چارشنبه', 'جۆمعه آخشامی', 'جۆمعه', 'شنبه'],
|
||||
'first_day_of_week' => 6,
|
||||
'alt_numbers' => ['۰۰', '۰۱', '۰۲', '۰۳', '۰۴', '۰۵', '۰۶', '۰۷', '۰۸', '۰۹', '۱۰', '۱۱', '۱۲', '۱۳', '۱۴', '۱۵', '۱۶', '۱۷', '۱۸', '۱۹', '۲۰', '۲۱', '۲۲', '۲۳', '۲۴', '۲۵', '۲۶', '۲۷', '۲۸', '۲۹', '۳۰', '۳۱', '۳۲', '۳۳', '۳۴', '۳۵', '۳۶', '۳۷', '۳۸', '۳۹', '۴۰', '۴۱', '۴۲', '۴۳', '۴۴', '۴۵', '۴۶', '۴۷', '۴۸', '۴۹', '۵۰', '۵۱', '۵۲', '۵۳', '۵۴', '۵۵', '۵۶', '۵۷', '۵۸', '۵۹', '۶۰', '۶۱', '۶۲', '۶۳', '۶۴', '۶۵', '۶۶', '۶۷', '۶۸', '۶۹', '۷۰', '۷۱', '۷۲', '۷۳', '۷۴', '۷۵', '۷۶', '۷۷', '۷۸', '۷۹', '۸۰', '۸۱', '۸۲', '۸۳', '۸۴', '۸۵', '۸۶', '۸۷', '۸۸', '۸۹', '۹۰', '۹۱', '۹۲', '۹۳', '۹۴', '۹۵', '۹۶', '۹۷', '۹۸', '۹۹'],
|
||||
]);
|
||||
@@ -15,6 +15,5 @@ return array_replace_recursive(require __DIR__.'/az.php', [
|
||||
'weekdays_min' => ['Б.', 'Б.Е.', 'Ч.А.', 'Ч.', 'Ҹ.А.', 'Ҹ.', 'Ш.'],
|
||||
'months' => ['јанвар', 'феврал', 'март', 'апрел', 'май', 'ијун', 'ијул', 'август', 'сентјабр', 'октјабр', 'нојабр', 'декабр'],
|
||||
'months_short' => ['јан', 'фев', 'мар', 'апр', 'май', 'ијн', 'ијл', 'авг', 'сен', 'окт', 'ној', 'дек'],
|
||||
'months_standalone' => ['Јанвар', 'Феврал', 'Март', 'Апрел', 'Май', 'Ијун', 'Ијул', 'Август', 'Сентјабр', 'Октјабр', 'Нојабр', 'Декабр'],
|
||||
'meridiem' => ['а', 'п'],
|
||||
]);
|
||||
@@ -9,10 +9,6 @@
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
/*
|
||||
* Authors:
|
||||
* - Mousa Moradi mousamk@gmail.com
|
||||
*/
|
||||
return array_replace_recursive(require __DIR__.'/en.php', [
|
||||
'formats' => [
|
||||
'L' => 'OY/OM/OD',
|
||||
|
||||
@@ -16,7 +16,6 @@ return array_replace_recursive(require __DIR__.'/az.php', [
|
||||
'weekdays_min' => ['B.', 'B.E.', 'Ç.A.', 'Ç.', 'C.A.', 'C.', 'Ş.'],
|
||||
'months' => ['yanvar', 'fevral', 'mart', 'aprel', 'may', 'iyun', 'iyul', 'avqust', 'sentyabr', 'oktyabr', 'noyabr', 'dekabr'],
|
||||
'months_short' => ['yan', 'fev', 'mar', 'apr', 'may', 'iyn', 'iyl', 'avq', 'sen', 'okt', 'noy', 'dek'],
|
||||
'months_standalone' => ['Yanvar', 'Fevral', 'Mart', 'Aprel', 'May', 'İyun', 'İyul', 'Avqust', 'Sentyabr', 'Oktyabr', 'Noyabr', 'Dekabr'],
|
||||
'first_day_of_week' => 1,
|
||||
'formats' => [
|
||||
'LT' => 'HH:mm',
|
||||
|
||||
+11
-23
@@ -117,39 +117,27 @@ return [
|
||||
'nextDay' => '[Заўтра ў] LT',
|
||||
'nextWeek' => '[У] dddd [ў] LT',
|
||||
'lastDay' => '[Учора ў] LT',
|
||||
'lastWeek' => function (CarbonInterface $current) {
|
||||
switch ($current->dayOfWeek) {
|
||||
case 1:
|
||||
case 2:
|
||||
case 4:
|
||||
return '[У мінулы] dddd [ў] LT';
|
||||
default:
|
||||
return '[У мінулую] dddd [ў] LT';
|
||||
}
|
||||
'lastWeek' => static fn (CarbonInterface $current) => match ($current->dayOfWeek) {
|
||||
1, 2, 4 => '[У мінулы] dddd [ў] LT',
|
||||
default => '[У мінулую] dddd [ў] LT',
|
||||
},
|
||||
'sameElse' => 'L',
|
||||
],
|
||||
'ordinal' => function ($number, $period) {
|
||||
switch ($period) {
|
||||
case 'M':
|
||||
case 'd':
|
||||
case 'DDD':
|
||||
case 'w':
|
||||
case 'W':
|
||||
return ($number % 10 === 2 || $number % 10 === 3) && ($number % 100 !== 12 && $number % 100 !== 13) ? $number.'-і' : $number.'-ы';
|
||||
case 'D':
|
||||
return $number.'-га';
|
||||
default:
|
||||
return $number;
|
||||
}
|
||||
'ordinal' => static fn ($number, $period) => match ($period) {
|
||||
'M', 'd', 'DDD', 'w', 'W' => ($number % 10 === 2 || $number % 10 === 3) &&
|
||||
($number % 100 !== 12 && $number % 100 !== 13) ? $number.'-і' : $number.'-ы',
|
||||
'D' => $number.'-га',
|
||||
default => $number,
|
||||
},
|
||||
'meridiem' => function ($hour) {
|
||||
'meridiem' => static function ($hour) {
|
||||
if ($hour < 4) {
|
||||
return 'ночы';
|
||||
}
|
||||
|
||||
if ($hour < 12) {
|
||||
return 'раніцы';
|
||||
}
|
||||
|
||||
if ($hour < 17) {
|
||||
return 'дня';
|
||||
}
|
||||
|
||||
@@ -66,19 +66,13 @@ return [
|
||||
'nextDay' => '[Утре в] LT',
|
||||
'nextWeek' => 'dddd [в] LT',
|
||||
'lastDay' => '[Вчера в] LT',
|
||||
'lastWeek' => function (CarbonInterface $current) {
|
||||
switch ($current->dayOfWeek) {
|
||||
case 0:
|
||||
case 3:
|
||||
case 6:
|
||||
return '[В изминалата] dddd [в] LT';
|
||||
default:
|
||||
return '[В изминалия] dddd [в] LT';
|
||||
}
|
||||
'lastWeek' => static fn (CarbonInterface $current) => match ($current->dayOfWeek) {
|
||||
0, 3, 6 => '[В изминалата] dddd [в] LT',
|
||||
default => '[В изминалия] dddd [в] LT',
|
||||
},
|
||||
'sameElse' => 'L',
|
||||
],
|
||||
'ordinal' => function ($number) {
|
||||
'ordinal' => static function ($number) {
|
||||
$lastDigit = $number % 10;
|
||||
$last2Digits = $number % 100;
|
||||
if ($number === 0) {
|
||||
|
||||
@@ -22,5 +22,6 @@ return array_replace_recursive(require __DIR__.'/en.php', [
|
||||
'weekdays' => ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'],
|
||||
'weekdays_short' => ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'],
|
||||
'weekdays_min' => ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'],
|
||||
'first_day_of_week' => 0,
|
||||
'day_of_first_week_of_year' => 1,
|
||||
]);
|
||||
@@ -22,6 +22,7 @@ return array_replace_recursive(require __DIR__.'/en.php', [
|
||||
'weekdays' => ['रविवार', 'सोमवार', 'मंगलवार', 'बुधवार', 'गुरुवार', 'शुक्रवार', 'शनिवार'],
|
||||
'weekdays_short' => ['रवि', 'सोम', 'मंगल', 'बुध', 'गुरु', 'शुक्र', 'शनि'],
|
||||
'weekdays_min' => ['रवि', 'सोम', 'मंगल', 'बुध', 'गुरु', 'शुक्र', 'शनि'],
|
||||
'first_day_of_week' => 0,
|
||||
'day_of_first_week_of_year' => 1,
|
||||
'meridiem' => ['पूर्वाह्न', 'अपराह्न'],
|
||||
|
||||
|
||||
@@ -14,6 +14,7 @@
|
||||
* - Samsung Electronics Co., Ltd. akhilesh.k@samsung.com & maninder1.s@samsung.com
|
||||
*/
|
||||
return array_replace_recursive(require __DIR__.'/en.php', [
|
||||
'first_day_of_week' => 0,
|
||||
'formats' => [
|
||||
'L' => 'dddd DD MMM YYYY',
|
||||
],
|
||||
|
||||
@@ -9,6 +9,8 @@
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
$bengaliNumbers = ['০', '১', '২', '৩', '৪', '৫', '৬', '৭', '৮', '৯'];
|
||||
|
||||
/*
|
||||
* Authors:
|
||||
* - Josh Soref
|
||||
@@ -18,6 +20,7 @@
|
||||
* - JD Isaacks
|
||||
* - Saiful Islam
|
||||
* - Faisal Islam
|
||||
* - Hayatunnabi Nabil
|
||||
*/
|
||||
return [
|
||||
'year' => ':count বছর',
|
||||
@@ -41,6 +44,12 @@ return [
|
||||
'second' => ':count সেকেন্ড',
|
||||
'a_second' => 'কয়েক সেকেন্ড|:count সেকেন্ড',
|
||||
's' => '১ সেকেন্ড|:count সেকেন্ড',
|
||||
'millisecond' => ':count মিলিসেকেন্ড',
|
||||
'a_millisecond' => 'এক মিলিসেকেন্ড|:count মিলিসেকেন্ড',
|
||||
'ms' => '১ মিলিসেকেন্ড|:count মিলিসেকেন্ড',
|
||||
'microsecond' => ':count মাইক্রোসেকেন্ড',
|
||||
'a_microsecond' => 'এক মাইক্রোসেকেন্ড|:count মাইক্রোসেকেন্ড',
|
||||
'µs' => '১ মাইক্রোসেকেন্ড|:count মাইক্রোসেকেন্ড',
|
||||
'ago' => ':time আগে',
|
||||
'from_now' => ':time পরে',
|
||||
'after' => ':time পরে',
|
||||
@@ -49,6 +58,8 @@ return [
|
||||
'diff_today' => 'আজ',
|
||||
'diff_yesterday' => 'গতকাল',
|
||||
'diff_tomorrow' => 'আগামীকাল',
|
||||
'diff_before_yesterday' => 'গত পরশু',
|
||||
'diff_after_tomorrow' => 'আগামী পরশু',
|
||||
'period_recurrences' => ':count বার|:count বার',
|
||||
'period_interval' => 'প্রতি :interval',
|
||||
'period_start_date' => ':date থেকে',
|
||||
@@ -69,7 +80,7 @@ return [
|
||||
'lastWeek' => '[গত] dddd, LT',
|
||||
'sameElse' => 'L',
|
||||
],
|
||||
'meridiem' => function ($hour) {
|
||||
'meridiem' => static function ($hour) {
|
||||
if ($hour < 4) {
|
||||
return 'রাত';
|
||||
}
|
||||
@@ -90,11 +101,53 @@ return [
|
||||
'weekdays' => ['রবিবার', 'সোমবার', 'মঙ্গলবার', 'বুধবার', 'বৃহস্পতিবার', 'শুক্রবার', 'শনিবার'],
|
||||
'weekdays_short' => ['রবি', 'সোম', 'মঙ্গল', 'বুধ', 'বৃহস্পতি', 'শুক্র', 'শনি'],
|
||||
'weekdays_min' => ['রবি', 'সোম', 'মঙ্গ', 'বুধ', 'বৃহঃ', 'শুক্র', 'শনি'],
|
||||
'ordinal' => static function ($number) use ($bengaliNumbers) {
|
||||
// Convert to Bengali numerals
|
||||
$bengaliNumber = str_replace(
|
||||
['0', '1', '2', '3', '4', '5', '6', '7', '8', '9'],
|
||||
$bengaliNumbers,
|
||||
(string) $number
|
||||
);
|
||||
|
||||
// Apply Bengali ordinal rules
|
||||
$lastDigit = $number % 10;
|
||||
$lastTwoDigits = $number % 100;
|
||||
|
||||
// Special cases for teens (11-19) always use তম
|
||||
if ($lastTwoDigits >= 11 && $lastTwoDigits <= 19) {
|
||||
return $bengaliNumber.'তম';
|
||||
}
|
||||
|
||||
// For numbers 1-10, use specific rules
|
||||
if ($number <= 10) {
|
||||
switch ($number) {
|
||||
case 1:
|
||||
case 5:
|
||||
case 7:
|
||||
case 8:
|
||||
case 9:
|
||||
case 10:
|
||||
return $bengaliNumber.'ম';
|
||||
case 2:
|
||||
case 3:
|
||||
return $bengaliNumber.'য়';
|
||||
case 4:
|
||||
return $bengaliNumber.'র্থ';
|
||||
case 6:
|
||||
return $bengaliNumber.'ষ্ঠ';
|
||||
default:
|
||||
return $bengaliNumber.'তম';
|
||||
}
|
||||
}
|
||||
|
||||
// For numbers > 20, all use তম
|
||||
return $bengaliNumber.'তম';
|
||||
},
|
||||
'list' => [', ', ' এবং '],
|
||||
'first_day_of_week' => 0,
|
||||
'day_of_first_week_of_year' => 1,
|
||||
'weekdays_standalone' => ['রবিবার', 'সোমবার', 'মঙ্গলবার', 'বুধবার', 'বৃহষ্পতিবার', 'শুক্রবার', 'শনিবার'],
|
||||
'weekdays_min_standalone' => ['রঃ', 'সোঃ', 'মঃ', 'বুঃ', 'বৃঃ', 'শুঃ', 'শনি'],
|
||||
'months_short_standalone' => ['জানুয়ারী', 'ফেব্রুয়ারী', 'মার্চ', 'এপ্রিল', 'মে', 'জুন', 'জুলাই', 'আগস্ট', 'সেপ্টেম্বর', 'অক্টোবর', 'নভেম্বর', 'ডিসেম্বর'],
|
||||
'alt_numbers' => ['০', '১', '২', '৩', '৪', '৫', '৬', '৭', '৮', '৯'],
|
||||
'alt_numbers' => $bengaliNumbers,
|
||||
];
|
||||
@@ -15,13 +15,20 @@
|
||||
* - JD Isaacks
|
||||
*/
|
||||
return [
|
||||
'year' => '{1}ལོ་གཅིག|]1,Inf[:count ལོ',
|
||||
'month' => '{1}ཟླ་བ་གཅིག|]1,Inf[:count ཟླ་བ',
|
||||
'week' => ':count བདུན་ཕྲག',
|
||||
'day' => '{1}ཉིན་གཅིག|]1,Inf[:count ཉིན་',
|
||||
'hour' => '{1}ཆུ་ཚོད་གཅིག|]1,Inf[:count ཆུ་ཚོད',
|
||||
'minute' => '{1}སྐར་མ་གཅིག|]1,Inf[:count སྐར་མ',
|
||||
'second' => '{1}ལམ་སང|]1,Inf[:count སྐར་ཆ།',
|
||||
'year' => 'ལོ:count',
|
||||
'a_year' => '{1}ལོ་གཅིག|[-Inf,Inf]ལོ:count',
|
||||
'month' => 'ཟླ་བ:count',
|
||||
'a_month' => '{1}ཟླ་བ་གཅིག|[-Inf,Inf]ཟླ་བ:count',
|
||||
'week' => 'གཟའ་འཁོར་:count',
|
||||
'a_week' => 'གཟའ་འཁོར་གཅིག',
|
||||
'day' => 'ཉིན:count་',
|
||||
'a_day' => '{1}ཉིན་གཅིག|[-Inf,Inf]ཉིན:count',
|
||||
'hour' => 'ཆུ་ཚོད:count',
|
||||
'a_hour' => '{1}ཆུ་ཚོད་གཅིག|[-Inf,Inf]ཆུ་ཚོད:count',
|
||||
'minute' => 'སྐར་མ་:count',
|
||||
'a_minute' => '{1}སྐར་མ་གཅིག|[-Inf,Inf]སྐར་མ་:count',
|
||||
'second' => 'སྐར་ཆ:count',
|
||||
'a_second' => '{01}ལམ་སང|[-Inf,Inf]སྐར་ཆ:count',
|
||||
'ago' => ':time སྔན་ལ',
|
||||
'from_now' => ':time ལ་',
|
||||
'diff_yesterday' => 'ཁ་སང',
|
||||
@@ -43,7 +50,7 @@ return [
|
||||
'lastWeek' => '[བདུན་ཕྲག་མཐའ་མ] dddd, LT',
|
||||
'sameElse' => 'L',
|
||||
],
|
||||
'meridiem' => function ($hour) {
|
||||
'meridiem' => static function ($hour) {
|
||||
if ($hour < 4) {
|
||||
return 'མཚན་མོ';
|
||||
}
|
||||
|
||||
@@ -55,9 +55,7 @@ return [
|
||||
'lastWeek' => 'dddd [paset da] LT',
|
||||
'sameElse' => 'L',
|
||||
],
|
||||
'ordinal' => function ($number) {
|
||||
return $number.($number === 1 ? 'añ' : 'vet');
|
||||
},
|
||||
'ordinal' => static fn ($number) => $number.($number === 1 ? 'añ' : 'vet'),
|
||||
'months' => ['Genver', 'C\'hwevrer', 'Meurzh', 'Ebrel', 'Mae', 'Mezheven', 'Gouere', 'Eost', 'Gwengolo', 'Here', 'Du', 'Kerzu'],
|
||||
'months_short' => ['Gen', 'C\'hwe', 'Meu', 'Ebr', 'Mae', 'Eve', 'Gou', 'Eos', 'Gwe', 'Her', 'Du', 'Ker'],
|
||||
'weekdays' => ['Sul', 'Lun', 'Meurzh', 'Merc\'her', 'Yaou', 'Gwener', 'Sadorn'],
|
||||
|
||||
@@ -22,6 +22,7 @@ return array_replace_recursive(require __DIR__.'/en.php', [
|
||||
'weekdays' => ['रबिबार', 'सोबार', 'मंगलबार', 'बुदबार', 'बिसथिबार', 'सुखुरबार', 'सुनिबार'],
|
||||
'weekdays_short' => ['रबि', 'सम', 'मंगल', 'बुद', 'बिसथि', 'सुखुर', 'सुनि'],
|
||||
'weekdays_min' => ['रबि', 'सम', 'मंगल', 'बुद', 'बिसथि', 'सुखुर', 'सुनि'],
|
||||
'first_day_of_week' => 0,
|
||||
'day_of_first_week_of_year' => 1,
|
||||
'meridiem' => ['फुं.', 'बेलासे.'],
|
||||
]);
|
||||
+19
-23
@@ -17,6 +17,7 @@
|
||||
* - shaishavgandhi05
|
||||
* - Serhan Apaydın
|
||||
* - JD Isaacks
|
||||
* - Ademir Šehić
|
||||
*/
|
||||
|
||||
use Carbon\CarbonInterface;
|
||||
@@ -26,8 +27,8 @@ return [
|
||||
'y' => ':count godina|:count godine|:count godina',
|
||||
'month' => ':count mjesec|:count mjeseca|:count mjeseci',
|
||||
'm' => ':count mjesec|:count mjeseca|:count mjeseci',
|
||||
'week' => ':count sedmice|:count sedmicu|:count sedmica',
|
||||
'w' => ':count sedmice|:count sedmicu|:count sedmica',
|
||||
'week' => ':count sedmica|:count sedmice|:count sedmica',
|
||||
'w' => ':count sedmica|:count sedmice|:count sedmica',
|
||||
'day' => ':count dan|:count dana|:count dana',
|
||||
'd' => ':count dan|:count dana|:count dana',
|
||||
'hour' => ':count sat|:count sata|:count sati',
|
||||
@@ -36,10 +37,17 @@ return [
|
||||
'min' => ':count minut|:count minuta|:count minuta',
|
||||
'second' => ':count sekund|:count sekunda|:count sekundi',
|
||||
's' => ':count sekund|:count sekunda|:count sekundi',
|
||||
|
||||
'ago' => 'prije :time',
|
||||
'from_now' => 'za :time',
|
||||
'after' => 'nakon :time',
|
||||
'before' => ':time ranije',
|
||||
|
||||
'year_ago' => ':count godinu|:count godine|:count godina',
|
||||
'year_from_now' => ':count godinu|:count godine|:count godina',
|
||||
'week_ago' => ':count sedmicu|:count sedmice|:count sedmica',
|
||||
'week_from_now' => ':count sedmicu|:count sedmice|:count sedmica',
|
||||
|
||||
'diff_now' => 'sada',
|
||||
'diff_today' => 'danas',
|
||||
'diff_today_regexp' => 'danas(?:\\s+u)?',
|
||||
@@ -58,29 +66,17 @@ return [
|
||||
'calendar' => [
|
||||
'sameDay' => '[danas u] LT',
|
||||
'nextDay' => '[sutra u] LT',
|
||||
'nextWeek' => function (CarbonInterface $current) {
|
||||
switch ($current->dayOfWeek) {
|
||||
case 0:
|
||||
return '[u] [nedjelju] [u] LT';
|
||||
case 3:
|
||||
return '[u] [srijedu] [u] LT';
|
||||
case 6:
|
||||
return '[u] [subotu] [u] LT';
|
||||
default:
|
||||
return '[u] dddd [u] LT';
|
||||
}
|
||||
'nextWeek' => static fn (CarbonInterface $current) => match ($current->dayOfWeek) {
|
||||
0 => '[u] [nedjelju] [u] LT',
|
||||
3 => '[u] [srijedu] [u] LT',
|
||||
6 => '[u] [subotu] [u] LT',
|
||||
default => '[u] dddd [u] LT',
|
||||
},
|
||||
'lastDay' => '[jučer u] LT',
|
||||
'lastWeek' => function (CarbonInterface $current) {
|
||||
switch ($current->dayOfWeek) {
|
||||
case 0:
|
||||
case 3:
|
||||
return '[prošlu] dddd [u] LT';
|
||||
case 6:
|
||||
return '[prošle] [subote] [u] LT';
|
||||
default:
|
||||
return '[prošli] dddd [u] LT';
|
||||
}
|
||||
'lastWeek' => static fn (CarbonInterface $current) => match ($current->dayOfWeek) {
|
||||
0, 3 => '[prošlu] dddd [u] LT',
|
||||
6 => '[prošle] [subote] [u] LT',
|
||||
default => '[prošli] dddd [u] LT',
|
||||
},
|
||||
'sameElse' => 'L',
|
||||
],
|
||||
|
||||
@@ -72,24 +72,24 @@ return [
|
||||
'LLLL' => 'dddd D MMMM [de] YYYY [a les] H:mm',
|
||||
],
|
||||
'calendar' => [
|
||||
'sameDay' => function (CarbonInterface $current) {
|
||||
'sameDay' => static function (CarbonInterface $current) {
|
||||
return '[avui a '.($current->hour !== 1 ? 'les' : 'la').'] LT';
|
||||
},
|
||||
'nextDay' => function (CarbonInterface $current) {
|
||||
'nextDay' => static function (CarbonInterface $current) {
|
||||
return '[demà a '.($current->hour !== 1 ? 'les' : 'la').'] LT';
|
||||
},
|
||||
'nextWeek' => function (CarbonInterface $current) {
|
||||
'nextWeek' => static function (CarbonInterface $current) {
|
||||
return 'dddd [a '.($current->hour !== 1 ? 'les' : 'la').'] LT';
|
||||
},
|
||||
'lastDay' => function (CarbonInterface $current) {
|
||||
'lastDay' => static function (CarbonInterface $current) {
|
||||
return '[ahir a '.($current->hour !== 1 ? 'les' : 'la').'] LT';
|
||||
},
|
||||
'lastWeek' => function (CarbonInterface $current) {
|
||||
'lastWeek' => static function (CarbonInterface $current) {
|
||||
return '[el] dddd [passat a '.($current->hour !== 1 ? 'les' : 'la').'] LT';
|
||||
},
|
||||
'sameElse' => 'L',
|
||||
],
|
||||
'ordinal' => function ($number, $period) {
|
||||
'ordinal' => static function ($number, $period) {
|
||||
return $number.(
|
||||
($period === 'w' || $period === 'W') ? 'a' : (
|
||||
($number === 1) ? 'r' : (
|
||||
|
||||
@@ -24,4 +24,5 @@ return array_replace_recursive(require __DIR__.'/en.php', [
|
||||
'LLL' => 'D MMMM, YYYY h:mm a',
|
||||
'LLLL' => 'dddd, D MMMM, YYYY h:mm a',
|
||||
],
|
||||
'first_day_of_week' => 0,
|
||||
]);
|
||||
@@ -22,6 +22,7 @@ return array_replace_recursive(require __DIR__.'/en.php', [
|
||||
'weekdays' => ['ᎤᎾᏙᏓᏆᏍᎬ', 'ᎤᎾᏙᏓᏉᏅᎯ', 'ᏔᎵᏁᎢᎦ', 'ᏦᎢᏁᎢᎦ', 'ᏅᎩᏁᎢᎦ', 'ᏧᎾᎩᎶᏍᏗ', 'ᎤᎾᏙᏓᏈᏕᎾ'],
|
||||
'weekdays_short' => ['ᏆᏍᎬ', 'ᏉᏅᎯ', 'ᏔᎵᏁ', 'ᏦᎢᏁ', 'ᏅᎩᏁ', 'ᏧᎾᎩ', 'ᏈᏕᎾ'],
|
||||
'weekdays_min' => ['ᏆᏍᎬ', 'ᏉᏅᎯ', 'ᏔᎵᏁ', 'ᏦᎢᏁ', 'ᏅᎩᏁ', 'ᏧᎾᎩ', 'ᏈᏕᎾ'],
|
||||
'first_day_of_week' => 0,
|
||||
'day_of_first_week_of_year' => 1,
|
||||
'meridiem' => ['ᏌᎾᎴ', 'ᏒᎯᏱᎢᏗᏢ', 'ꮜꮎꮄ', 'ꮢꭿᏹꭲꮧꮲ'],
|
||||
|
||||
|
||||
+13
-12
@@ -12,20 +12,21 @@
|
||||
/*
|
||||
* Authors:
|
||||
* - Swara Mohammed
|
||||
* - Kawan Pshtiwan
|
||||
*/
|
||||
$months = [
|
||||
'ڕێبەندان',
|
||||
'ڕەشەمە',
|
||||
'نەورۆز',
|
||||
'گوڵان',
|
||||
'جۆزەردان',
|
||||
'پوشپەڕ',
|
||||
'گەلاوێژ',
|
||||
'خەرمانان',
|
||||
'ڕەزبەر',
|
||||
'گەڵاڕێزان',
|
||||
'سەرماوەرز',
|
||||
'بەفرانبار',
|
||||
'کانونی دووەم',
|
||||
'شوبات',
|
||||
'ئازار',
|
||||
'نیسان',
|
||||
'ئایار',
|
||||
'حوزەیران',
|
||||
'تەمموز',
|
||||
'ئاب',
|
||||
'ئەیلوول',
|
||||
'تشرینی یەکەم',
|
||||
'تشرینی دووەم',
|
||||
'کانونی یەکەم',
|
||||
];
|
||||
|
||||
return [
|
||||
|
||||
@@ -14,6 +14,7 @@
|
||||
* - bug-glibc-locales@gnu.org
|
||||
*/
|
||||
return array_replace_recursive(require __DIR__.'/en.php', [
|
||||
'first_day_of_week' => 0,
|
||||
'formats' => [
|
||||
'L' => 'YYYY年MM月DD號',
|
||||
],
|
||||
|
||||
@@ -104,6 +104,7 @@ return [
|
||||
'months' => ['ledna', 'února', 'března', 'dubna', 'května', 'června', 'července', 'srpna', 'září', 'října', 'listopadu', 'prosince'],
|
||||
'months_standalone' => ['leden', 'únor', 'březen', 'duben', 'květen', 'červen', 'červenec', 'srpen', 'září', 'říjen', 'listopad', 'prosinec'],
|
||||
'months_short' => ['led', 'úno', 'bře', 'dub', 'kvě', 'čvn', 'čvc', 'srp', 'zář', 'říj', 'lis', 'pro'],
|
||||
'months_regexp' => '/(DD?o?\.?(\[[^\[\]]*\]|\s)+MMMM?|L{2,4}|l{2,4})/',
|
||||
'weekdays' => ['neděle', 'pondělí', 'úterý', 'středa', 'čtvrtek', 'pátek', 'sobota'],
|
||||
'weekdays_short' => ['ned', 'pon', 'úte', 'stř', 'čtv', 'pát', 'sob'],
|
||||
'weekdays_min' => ['ne', 'po', 'út', 'st', 'čt', 'pá', 'so'],
|
||||
|
||||
@@ -31,8 +31,8 @@ return [
|
||||
'second' => ':count ҫеккунт',
|
||||
'a_second' => '{1}пӗр-ик ҫеккунт|:count ҫеккунт',
|
||||
'ago' => ':time каялла',
|
||||
'from_now' => function ($time) {
|
||||
return $time.(preg_match('/сехет$/u', $time) ? 'рен' : (preg_match('/ҫул/u', $time) ? 'тан' : 'ран'));
|
||||
'from_now' => static function ($time) {
|
||||
return $time.(preg_match('/сехет$/u', $time) ? 'рен' : (preg_match('/ҫул/', $time) ? 'тан' : 'ран'));
|
||||
},
|
||||
'diff_yesterday' => 'Ӗнер',
|
||||
'diff_today' => 'Паян',
|
||||
|
||||
@@ -16,19 +16,26 @@
|
||||
* - Daniel Monaghan
|
||||
*/
|
||||
return [
|
||||
'year' => '{1}blwyddyn|]1,Inf[:count flynedd',
|
||||
'year' => '{1}:count flwyddyn|[-Inf,Inf]:count flynedd',
|
||||
'a_year' => '{1}blwyddyn|[-Inf,Inf]:count flynedd',
|
||||
'y' => ':countbl',
|
||||
'month' => '{1}mis|]1,Inf[:count mis',
|
||||
'month' => ':count mis',
|
||||
'a_month' => '{1}mis|[-Inf,Inf]:count mis',
|
||||
'm' => ':countmi',
|
||||
'week' => ':count wythnos',
|
||||
'a_week' => '{1}wythnos|[-Inf,Inf]:count wythnos',
|
||||
'w' => ':countw',
|
||||
'day' => '{1}diwrnod|]1,Inf[:count diwrnod',
|
||||
'day' => ':count diwrnod',
|
||||
'a_day' => '{1}diwrnod|[-Inf,Inf]:count diwrnod',
|
||||
'd' => ':countd',
|
||||
'hour' => '{1}awr|]1,Inf[:count awr',
|
||||
'hour' => ':count awr',
|
||||
'a_hour' => '{1}awr|[-Inf,Inf]:count awr',
|
||||
'h' => ':counth',
|
||||
'minute' => '{1}munud|]1,Inf[:count munud',
|
||||
'minute' => ':count munud',
|
||||
'a_minute' => '{1}munud|[-Inf,Inf]:count munud',
|
||||
'min' => ':countm',
|
||||
'second' => '{1}ychydig eiliadau|]1,Inf[:count eiliad',
|
||||
'second' => ':count eiliad',
|
||||
'a_second' => '{0,1}ychydig eiliadau|[-Inf,Inf]:count eiliad',
|
||||
's' => ':counts',
|
||||
'ago' => ':time yn ôl',
|
||||
'from_now' => 'mewn :time',
|
||||
@@ -57,7 +64,7 @@ return [
|
||||
'lastWeek' => 'dddd [diwethaf am] LT',
|
||||
'sameElse' => 'L',
|
||||
],
|
||||
'ordinal' => function ($number) {
|
||||
'ordinal' => static function ($number) {
|
||||
return $number.(
|
||||
$number > 20
|
||||
? (\in_array((int) $number, [40, 50, 60, 80, 100], true) ? 'fed' : 'ain')
|
||||
|
||||
@@ -71,10 +71,10 @@ return [
|
||||
],
|
||||
'ordinal' => ':number.',
|
||||
'months' => ['januar', 'februar', 'marts', 'april', 'maj', 'juni', 'juli', 'august', 'september', 'oktober', 'november', 'december'],
|
||||
'months_short' => ['jan.', 'feb.', 'mar.', 'apr.', 'maj.', 'jun.', 'jul.', 'aug.', 'sep.', 'okt.', 'nov.', 'dec.'],
|
||||
'months_short' => ['jan.', 'feb.', 'mar.', 'apr.', 'maj', 'jun.', 'jul.', 'aug.', 'sep.', 'okt.', 'nov.', 'dec.'],
|
||||
'weekdays' => ['søndag', 'mandag', 'tirsdag', 'onsdag', 'torsdag', 'fredag', 'lørdag'],
|
||||
'weekdays_short' => ['søn.', 'man.', 'tir.', 'ons.', 'tor.', 'fre.', 'lør.'],
|
||||
'weekdays_min' => ['sø', 'ma', 'ti', 'on', 'to', 'fr', 'lø'],
|
||||
'weekdays_min' => ['sø.', 'ma.', 'ti.', 'on.', 'to.', 'fr.', 'lø.'],
|
||||
'first_day_of_week' => 1,
|
||||
'day_of_first_week_of_year' => 4,
|
||||
'list' => [', ', ' og '],
|
||||
|
||||
Loaded 100 of 1297 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user