mirror of
https://github.com/yiisoft/yii2.git
synced 2025-08-18 17:21:26 +08:00

- Added protected `\yii\Inflector::transliterate()` that could be replaced with custom translit implementation. - Added proper tests for both intl-based slug and PHP fallback. - Removed character maps for non-latin languages. - Improved overall slug results. - Added note about the fact that intl is required for non-latin languages to requirements checker.
21 lines
308 B
PHP
21 lines
308 B
PHP
<?php
|
|
|
|
|
|
namespace yiiunit\framework\helpers;
|
|
|
|
|
|
use yii\helpers\BaseInflector;
|
|
|
|
/**
|
|
* Forces Inflector::slug to use PHP even if intl is available
|
|
*/
|
|
class FallbackInflector extends BaseInflector
|
|
{
|
|
/**
|
|
* @inheritdoc
|
|
*/
|
|
protected static function hasIntl()
|
|
{
|
|
return false;
|
|
}
|
|
} |