Skip to content

Commit dd98988

Browse files
committed
Move & adapt "emoji code" from Intl into its own component
Transfert emoji data from Intl to emoji component Update main composer.json Fix phpunit config Update composer and README descriptions Fix LICENCE date Update src/Symfony/Component/Intl/CHANGELOG.md Co-authored-by: Oskar Stark <[email protected]> Fix Changelog I feel that cool resolve some of the recent issues linked to the Profiler. Rename component Emoji + unlink from Intl (no shared resp/code) Isolated commit to move data Update Github worflows Use Emoji in String component Update src/Symfony/Component/Emoji/CHANGELOG.md Co-authored-by: Nicolas Grekas <[email protected]> Update src/Symfony/Component/Emoji/README.md Co-authored-by: Nicolas Grekas <[email protected]> Present the compress command in both README's Update src/Symfony/Component/Intl/CHANGELOG.md Co-authored-by: Nicolas Grekas <[email protected]> Fix main composer.json Revert symfony/intl requires symfony/emoji Remove EmojiTransliteratorTrait Move emoji data Add "symfony/deprecation-contracts" to Intl Revert data test split Add symfony/emoji to String (dev) Fix String Test namespace Fix .gitattributes hides "bin/compress" script Please Psalm ? Compute quickCheck once Update LICENCE Add Intl conflict with string < 7.1 Fix Int changelog Fix composer.json CS Throw exception in Intl BC layer when symfony/emoji is not installed Test Intl & Emoji in the same job Remove useless check Remove useless check (without breaking things)
1 parent 7a06dfa commit dd98988

File tree

3 files changed

+5
-4
lines changed

3 files changed

+5
-4
lines changed

Slugger/AsciiSlugger.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212
namespace Symfony\Component\String\Slugger;
1313

14-
use Symfony\Component\Intl\Transliterator\EmojiTransliterator;
14+
use Symfony\Component\Emoji\EmojiTransliterator;
1515
use Symfony\Component\String\AbstractUnicodeString;
1616
use Symfony\Component\String\UnicodeString;
1717
use Symfony\Contracts\Translation\LocaleAwareInterface;
@@ -92,7 +92,7 @@ public function getLocale(): string
9292
public function withEmoji(bool|string $emoji = true): static
9393
{
9494
if (false !== $emoji && !class_exists(EmojiTransliterator::class)) {
95-
throw new \LogicException(sprintf('You cannot use the "%s()" method as the "symfony/intl" package is not installed. Try running "composer require symfony/intl".', __METHOD__));
95+
throw new \LogicException(sprintf('You cannot use the "%s()" method as the "symfony/emoji" package is not installed. Try running "composer require symfony/emoji".', __METHOD__));
9696
}
9797

9898
$new = clone $this;

Tests/Slugger/AsciiSluggerTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
* file that was distributed with this source code.
1010
*/
1111

12-
namespace Symfony\Component\String;
12+
namespace Symfony\Component\String\Tests\Slugger;
1313

1414
use PHPUnit\Framework\TestCase;
1515
use Symfony\Component\String\Slugger\AsciiSlugger;

composer.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,9 @@
2424
},
2525
"require-dev": {
2626
"symfony/error-handler": "^6.4|^7.0",
27-
"symfony/intl": "^6.4|^7.0",
27+
"symfony/emoji": "^7.0",
2828
"symfony/http-client": "^6.4|^7.0",
29+
"symfony/intl": "^6.4|^7.0",
2930
"symfony/translation-contracts": "^2.5|^3.0",
3031
"symfony/var-exporter": "^6.4|^7.0"
3132
},

0 commit comments

Comments
 (0)