<?php

namespace App\Twig;

use Twig\Extension\AbstractExtension;
use Twig\TwigFunction;
use App\Controller\AdminController;

class TagEmojiExtension extends AbstractExtension
{
    public function getFunctions(): array
    {
        return [
            new TwigFunction('tag_emoji', [self::class, 'getTagEmoji']),
        ];
    }

    public static function getTagEmoji(?string $mainTag): string
    {
        return AdminController::getTagEmoji($mainTag);
    }
} 