var/cache/dev/twig/f5/f543ca0e9742d1a35995e7112c0e3b4c.php line 57

  1. <?php
  2. use Twig\Environment;
  3. use Twig\Error\LoaderError;
  4. use Twig\Error\RuntimeError;
  5. use Twig\Extension\SandboxExtension;
  6. use Twig\Markup;
  7. use Twig\Sandbox\SecurityError;
  8. use Twig\Sandbox\SecurityNotAllowedTagError;
  9. use Twig\Sandbox\SecurityNotAllowedFilterError;
  10. use Twig\Sandbox\SecurityNotAllowedFunctionError;
  11. use Twig\Source;
  12. use Twig\Template;
  13. /* @WebProfiler/Collector/translation.html.twig */
  14. class __TwigTemplate_157bca84f66949400e77b3efa10b3fff extends Template
  15. {
  16.     private $source;
  17.     private $macros = [];
  18.     public function __construct(Environment $env)
  19.     {
  20.         parent::__construct($env);
  21.         $this->source $this->getSourceContext();
  22.         $this->blocks = [
  23.             'toolbar' => [$this'block_toolbar'],
  24.             'menu' => [$this'block_menu'],
  25.             'panel' => [$this'block_panel'],
  26.             'messages' => [$this'block_messages'],
  27.             'defined_messages' => [$this'block_defined_messages'],
  28.             'fallback_messages' => [$this'block_fallback_messages'],
  29.             'missing_messages' => [$this'block_missing_messages'],
  30.         ];
  31.     }
  32.     protected function doGetParent(array $context)
  33.     {
  34.         // line 1
  35.         return "@WebProfiler/Profiler/layout.html.twig";
  36.     }
  37.     protected function doDisplay(array $context, array $blocks = [])
  38.     {
  39.         $macros $this->macros;
  40.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  41.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""@WebProfiler/Collector/translation.html.twig"));
  42.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  43.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""@WebProfiler/Collector/translation.html.twig"));
  44.         // line 3
  45.         $macros["helper"] = $this->macros["helper"] = $this;
  46.         // line 1
  47.         $this->parent $this->loadTemplate("@WebProfiler/Profiler/layout.html.twig""@WebProfiler/Collector/translation.html.twig"1);
  48.         $this->parent->display($contextarray_merge($this->blocks$blocks));
  49.         
  50.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  51.         
  52.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  53.     }
  54.     // line 5
  55.     public function block_toolbar($context, array $blocks = [])
  56.     {
  57.         $macros $this->macros;
  58.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  59.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""toolbar"));
  60.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  61.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""toolbar"));
  62.         // line 6
  63.         echo "    ";
  64.         if (twig_length_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'6$this->source); })()), "messages", [], "any"falsefalsefalse6))) {
  65.             // line 7
  66.             echo "        ";
  67.             ob_start();
  68.             // line 8
  69.             echo "            ";
  70.             echo twig_source($this->env"@WebProfiler/Icon/translation.svg");
  71.             echo "
  72.             ";
  73.             // line 9
  74.             $context["status_color"] = ((twig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'9$this->source); })()), "countMissings", [], "any"falsefalsefalse9)) ? ("red") : (((twig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'9$this->source); })()), "countFallbacks", [], "any"falsefalsefalse9)) ? ("yellow") : (""))));
  75.             // line 10
  76.             echo "            ";
  77.             $context["error_count"] = (twig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'10$this->source); })()), "countMissings", [], "any"falsefalsefalse10) + twig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'10$this->source); })()), "countFallbacks", [], "any"falsefalsefalse10));
  78.             // line 11
  79.             echo "            <span class=\"sf-toolbar-value\">";
  80.             echo twig_escape_filter($this->env, (((isset($context["error_count"]) || array_key_exists("error_count"$context) ? $context["error_count"] : (function () { throw new RuntimeError('Variable "error_count" does not exist.'11$this->source); })())) ? ((isset($context["error_count"]) || array_key_exists("error_count"$context) ? $context["error_count"] : (function () { throw new RuntimeError('Variable "error_count" does not exist.'11$this->source); })())) : (twig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'11$this->source); })()), "countDefines", [], "any"falsefalsefalse11))), "html"nulltrue);
  81.             echo "</span>
  82.         ";
  83.             $context["icon"] = ('' === $tmp ob_get_clean()) ? '' : new Markup($tmp$this->env->getCharset());
  84.             // line 13
  85.             echo "
  86.         ";
  87.             // line 14
  88.             ob_start();
  89.             // line 15
  90.             echo "            <div class=\"sf-toolbar-info-piece\">
  91.                 <b>Default locale</b>
  92.                 <span class=\"sf-toolbar-status\">
  93.                     ";
  94.             // line 18
  95.             echo twig_escape_filter($this->env, ((twig_get_attribute($this->env$this->source, ($context["collector"] ?? null), "locale", [], "any"truetruefalse18)) ? (_twig_default_filter(twig_get_attribute($this->env$this->source, ($context["collector"] ?? null), "locale", [], "any"falsefalsefalse18), "-")) : ("-")), "html"nulltrue);
  96.             echo "
  97.                 </span>
  98.             </div>
  99.             <div class=\"sf-toolbar-info-piece\">
  100.                 <b>Missing messages</b>
  101.                 <span class=\"sf-toolbar-status sf-toolbar-status-";
  102.             // line 23
  103.             echo ((twig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'23$this->source); })()), "countMissings", [], "any"falsefalsefalse23)) ? ("red") : (""));
  104.             echo "\">
  105.                     ";
  106.             // line 24
  107.             echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'24$this->source); })()), "countMissings", [], "any"falsefalsefalse24), "html"nulltrue);
  108.             echo "
  109.                 </span>
  110.             </div>
  111.             <div class=\"sf-toolbar-info-piece\">
  112.                 <b>Fallback messages</b>
  113.                 <span class=\"sf-toolbar-status sf-toolbar-status-";
  114.             // line 30
  115.             echo ((twig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'30$this->source); })()), "countFallbacks", [], "any"falsefalsefalse30)) ? ("yellow") : (""));
  116.             echo "\">
  117.                     ";
  118.             // line 31
  119.             echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'31$this->source); })()), "countFallbacks", [], "any"falsefalsefalse31), "html"nulltrue);
  120.             echo "
  121.                 </span>
  122.             </div>
  123.             <div class=\"sf-toolbar-info-piece\">
  124.                 <b>Defined messages</b>
  125.                 <span class=\"sf-toolbar-status\">";
  126.             // line 37
  127.             echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'37$this->source); })()), "countDefines", [], "any"falsefalsefalse37), "html"nulltrue);
  128.             echo "</span>
  129.             </div>
  130.         ";
  131.             $context["text"] = ('' === $tmp ob_get_clean()) ? '' : new Markup($tmp$this->env->getCharset());
  132.             // line 40
  133.             echo "
  134.         ";
  135.             // line 41
  136.             echo twig_include($this->env$context"@WebProfiler/Profiler/toolbar_item.html.twig", ["link" => (isset($context["profiler_url"]) || array_key_exists("profiler_url"$context) ? $context["profiler_url"] : (function () { throw new RuntimeError('Variable "profiler_url" does not exist.'41$this->source); })()), "status" => (isset($context["status_color"]) || array_key_exists("status_color"$context) ? $context["status_color"] : (function () { throw new RuntimeError('Variable "status_color" does not exist.'41$this->source); })())]);
  137.             echo "
  138.     ";
  139.         }
  140.         
  141.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  142.         
  143.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  144.     }
  145.     // line 45
  146.     public function block_menu($context, array $blocks = [])
  147.     {
  148.         $macros $this->macros;
  149.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  150.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""menu"));
  151.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  152.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""menu"));
  153.         // line 46
  154.         echo "    <span class=\"label label-status-";
  155.         echo ((twig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'46$this->source); })()), "countMissings", [], "any"falsefalsefalse46)) ? ("error") : (((twig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'46$this->source); })()), "countFallbacks", [], "any"falsefalsefalse46)) ? ("warning") : (""))));
  156.         echo " ";
  157.         echo ((twig_test_empty(twig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'46$this->source); })()), "messages", [], "any"falsefalsefalse46))) ? ("disabled") : (""));
  158.         echo "\">
  159.         <span class=\"icon\">";
  160.         // line 47
  161.         echo twig_source($this->env"@WebProfiler/Icon/translation.svg");
  162.         echo "</span>
  163.         <strong>Translation</strong>
  164.         ";
  165.         // line 49
  166.         if ((twig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'49$this->source); })()), "countMissings", [], "any"falsefalsefalse49) || twig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'49$this->source); })()), "countFallbacks", [], "any"falsefalsefalse49))) {
  167.             // line 50
  168.             echo "            ";
  169.             $context["error_count"] = (twig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'50$this->source); })()), "countMissings", [], "any"falsefalsefalse50) + twig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'50$this->source); })()), "countFallbacks", [], "any"falsefalsefalse50));
  170.             // line 51
  171.             echo "            <span class=\"count\">
  172.                 <span>";
  173.             // line 52
  174.             echo twig_escape_filter($this->env, (isset($context["error_count"]) || array_key_exists("error_count"$context) ? $context["error_count"] : (function () { throw new RuntimeError('Variable "error_count" does not exist.'52$this->source); })()), "html"nulltrue);
  175.             echo "</span>
  176.             </span>
  177.         ";
  178.         }
  179.         // line 55
  180.         echo "    </span>
  181. ";
  182.         
  183.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  184.         
  185.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  186.     }
  187.     // line 58
  188.     public function block_panel($context, array $blocks = [])
  189.     {
  190.         $macros $this->macros;
  191.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  192.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""panel"));
  193.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  194.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""panel"));
  195.         // line 59
  196.         echo "    <h2>Translation</h2>
  197.     <div class=\"metrics\">
  198.         <div class=\"metric\">
  199.             <span class=\"value\">";
  200.         // line 63
  201.         echo twig_escape_filter($this->env, ((twig_get_attribute($this->env$this->source, ($context["collector"] ?? null), "locale", [], "any"truetruefalse63)) ? (_twig_default_filter(twig_get_attribute($this->env$this->source, ($context["collector"] ?? null), "locale", [], "any"falsefalsefalse63), "-")) : ("-")), "html"nulltrue);
  202.         echo "</span>
  203.             <span class=\"label\">Default locale</span>
  204.         </div>
  205.         <div class=\"metric\">
  206.             <span class=\"value\">";
  207.         // line 67
  208.         echo twig_escape_filter($this->env_twig_default_filter(twig_join_filter(twig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'67$this->source); })()), "fallbackLocales", [], "any"falsefalsefalse67), ", "), "-"), "html"nulltrue);
  209.         echo "</span>
  210.             <span class=\"label\">Fallback locale";
  211.         // line 68
  212.         echo (((twig_length_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'68$this->source); })()), "fallbackLocales", [], "any"falsefalsefalse68)) != 1)) ? ("s") : (""));
  213.         echo "</span>
  214.         </div>
  215.     </div>
  216.     <h2>Messages</h2>
  217.     ";
  218.         // line 74
  219.         if (twig_test_empty(twig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'74$this->source); })()), "messages", [], "any"falsefalsefalse74))) {
  220.             // line 75
  221.             echo "        <div class=\"empty empty-panel\">
  222.             <p>No translations have been called.</p>
  223.         </div>
  224.     ";
  225.         } else {
  226.             // line 79
  227.             echo "        ";
  228.             $this->displayBlock('messages'$context$blocks);
  229.             // line 161
  230.             echo "    ";
  231.         }
  232.         // line 162
  233.         echo "
  234. ";
  235.         
  236.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  237.         
  238.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  239.     }
  240.     // line 79
  241.     public function block_messages($context, array $blocks = [])
  242.     {
  243.         $macros $this->macros;
  244.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  245.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""messages"));
  246.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  247.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""messages"));
  248.         // line 80
  249.         echo "
  250.         ";
  251.         // line 82
  252.         echo "        ";
  253.         list($context["messages_defined"], $context["messages_missing"], $context["messages_fallback"]) =         [[], [], []];
  254.         // line 83
  255.         echo "        ";
  256.         $context['_parent'] = $context;
  257.         $context['_seq'] = twig_ensure_traversable(twig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'83$this->source); })()), "messages", [], "any"falsefalsefalse83));
  258.         foreach ($context['_seq'] as $context["_key"] => $context["message"]) {
  259.             // line 84
  260.             echo "            ";
  261.             if ((twig_get_attribute($this->env$this->source$context["message"], "state", [], "any"falsefalsefalse84) == twig_constant("Symfony\\Component\\Translation\\DataCollectorTranslator::MESSAGE_DEFINED"))) {
  262.                 // line 85
  263.                 echo "                ";
  264.                 $context["messages_defined"] = twig_array_merge((isset($context["messages_defined"]) || array_key_exists("messages_defined"$context) ? $context["messages_defined"] : (function () { throw new RuntimeError('Variable "messages_defined" does not exist.'85$this->source); })()), [=> $context["message"]]);
  265.                 // line 86
  266.                 echo "            ";
  267.             } elseif ((twig_get_attribute($this->env$this->source$context["message"], "state", [], "any"falsefalsefalse86) == twig_constant("Symfony\\Component\\Translation\\DataCollectorTranslator::MESSAGE_MISSING"))) {
  268.                 // line 87
  269.                 echo "                ";
  270.                 $context["messages_missing"] = twig_array_merge((isset($context["messages_missing"]) || array_key_exists("messages_missing"$context) ? $context["messages_missing"] : (function () { throw new RuntimeError('Variable "messages_missing" does not exist.'87$this->source); })()), [=> $context["message"]]);
  271.                 // line 88
  272.                 echo "            ";
  273.             } elseif ((twig_get_attribute($this->env$this->source$context["message"], "state", [], "any"falsefalsefalse88) == twig_constant("Symfony\\Component\\Translation\\DataCollectorTranslator::MESSAGE_EQUALS_FALLBACK"))) {
  274.                 // line 89
  275.                 echo "                ";
  276.                 $context["messages_fallback"] = twig_array_merge((isset($context["messages_fallback"]) || array_key_exists("messages_fallback"$context) ? $context["messages_fallback"] : (function () { throw new RuntimeError('Variable "messages_fallback" does not exist.'89$this->source); })()), [=> $context["message"]]);
  277.                 // line 90
  278.                 echo "            ";
  279.             }
  280.             // line 91
  281.             echo "        ";
  282.         }
  283.         $_parent $context['_parent'];
  284.         unset($context['_seq'], $context['_iterated'], $context['_key'], $context['message'], $context['_parent'], $context['loop']);
  285.         $context array_intersect_key($context$_parent) + $_parent;
  286.         // line 92
  287.         echo "
  288.         <div class=\"sf-tabs\">
  289.             <div class=\"tab ";
  290.         // line 94
  291.         echo (((twig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'94$this->source); })()), "countMissings", [], "any"falsefalsefalse94) == 0)) ? ("active") : (""));
  292.         echo "\">
  293.                 <h3 class=\"tab-title\">Defined <span class=\"badge\">";
  294.         // line 95
  295.         echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'95$this->source); })()), "countDefines", [], "any"falsefalsefalse95), "html"nulltrue);
  296.         echo "</span></h3>
  297.                 <div class=\"tab-content\">
  298.                     <p class=\"help\">
  299.                         These messages are correctly translated into the given locale.
  300.                     </p>
  301.                     ";
  302.         // line 102
  303.         if (twig_test_empty((isset($context["messages_defined"]) || array_key_exists("messages_defined"$context) ? $context["messages_defined"] : (function () { throw new RuntimeError('Variable "messages_defined" does not exist.'102$this->source); })()))) {
  304.             // line 103
  305.             echo "                        <div class=\"empty\">
  306.                             <p>None of the used translation messages are defined for the given locale.</p>
  307.                         </div>
  308.                     ";
  309.         } else {
  310.             // line 107
  311.             echo "                        ";
  312.             $this->displayBlock('defined_messages'$context$blocks);
  313.             // line 110
  314.             echo "                    ";
  315.         }
  316.         // line 111
  317.         echo "                </div>
  318.             </div>
  319.             <div class=\"tab\">
  320.                 <h3 class=\"tab-title\">Fallback <span class=\"badge ";
  321.         // line 115
  322.         echo ((twig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'115$this->source); })()), "countFallbacks", [], "any"falsefalsefalse115)) ? ("status-warning") : (""));
  323.         echo "\">";
  324.         echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'115$this->source); })()), "countFallbacks", [], "any"falsefalsefalse115), "html"nulltrue);
  325.         echo "</span></h3>
  326.                 <div class=\"tab-content\">
  327.                     <p class=\"help\">
  328.                         These messages are not available for the given locale
  329.                         but Symfony found them in the fallback locale catalog.
  330.                     </p>
  331.                     ";
  332.         // line 123
  333.         if (twig_test_empty((isset($context["messages_fallback"]) || array_key_exists("messages_fallback"$context) ? $context["messages_fallback"] : (function () { throw new RuntimeError('Variable "messages_fallback" does not exist.'123$this->source); })()))) {
  334.             // line 124
  335.             echo "                        <div class=\"empty\">
  336.                             <p>No fallback translation messages were used.</p>
  337.                         </div>
  338.                     ";
  339.         } else {
  340.             // line 128
  341.             echo "                        ";
  342.             $this->displayBlock('fallback_messages'$context$blocks);
  343.             // line 131
  344.             echo "                    ";
  345.         }
  346.         // line 132
  347.         echo "                </div>
  348.             </div>
  349.             <div class=\"tab ";
  350.         // line 135
  351.         echo (((twig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'135$this->source); })()), "countMissings", [], "any"falsefalsefalse135) > 0)) ? ("active") : (""));
  352.         echo "\">
  353.                 <h3 class=\"tab-title\">Missing <span class=\"badge ";
  354.         // line 136
  355.         echo ((twig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'136$this->source); })()), "countMissings", [], "any"falsefalsefalse136)) ? ("status-error") : (""));
  356.         echo "\">";
  357.         echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["collector"]) || array_key_exists("collector"$context) ? $context["collector"] : (function () { throw new RuntimeError('Variable "collector" does not exist.'136$this->source); })()), "countMissings", [], "any"falsefalsefalse136), "html"nulltrue);
  358.         echo "</span></h3>
  359.                 <div class=\"tab-content\">
  360.                     <p class=\"help\">
  361.                         These messages are not available for the given locale and cannot
  362.                         be found in the fallback locales. Add them to the translation
  363.                         catalogue to avoid Symfony outputting untranslated contents.
  364.                     </p>
  365.                     ";
  366.         // line 145
  367.         if (twig_test_empty((isset($context["messages_missing"]) || array_key_exists("messages_missing"$context) ? $context["messages_missing"] : (function () { throw new RuntimeError('Variable "messages_missing" does not exist.'145$this->source); })()))) {
  368.             // line 146
  369.             echo "                        <div class=\"empty\">
  370.                             <p>There are no messages of this category.</p>
  371.                         </div>
  372.                     ";
  373.         } else {
  374.             // line 150
  375.             echo "                        ";
  376.             $this->displayBlock('missing_messages'$context$blocks);
  377.             // line 153
  378.             echo "                    ";
  379.         }
  380.         // line 154
  381.         echo "                </div>
  382.             </div>
  383.         </div>
  384.         <script>Sfjs.createFilters();</script>
  385.         ";
  386.         
  387.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  388.         
  389.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  390.     }
  391.     // line 107
  392.     public function block_defined_messages($context, array $blocks = [])
  393.     {
  394.         $macros $this->macros;
  395.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  396.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""defined_messages"));
  397.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  398.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""defined_messages"));
  399.         // line 108
  400.         echo "                            ";
  401.         echo twig_call_macro($macros["helper"], "macro_render_table", [(isset($context["messages_defined"]) || array_key_exists("messages_defined"$context) ? $context["messages_defined"] : (function () { throw new RuntimeError('Variable "messages_defined" does not exist.'108$this->source); })())], 108$context$this->getSourceContext());
  402.         echo "
  403.                         ";
  404.         
  405.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  406.         
  407.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  408.     }
  409.     // line 128
  410.     public function block_fallback_messages($context, array $blocks = [])
  411.     {
  412.         $macros $this->macros;
  413.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  414.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""fallback_messages"));
  415.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  416.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""fallback_messages"));
  417.         // line 129
  418.         echo "                            ";
  419.         echo twig_call_macro($macros["helper"], "macro_render_table", [(isset($context["messages_fallback"]) || array_key_exists("messages_fallback"$context) ? $context["messages_fallback"] : (function () { throw new RuntimeError('Variable "messages_fallback" does not exist.'129$this->source); })()), true], 129$context$this->getSourceContext());
  420.         echo "
  421.                         ";
  422.         
  423.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  424.         
  425.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  426.     }
  427.     // line 150
  428.     public function block_missing_messages($context, array $blocks = [])
  429.     {
  430.         $macros $this->macros;
  431.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  432.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""missing_messages"));
  433.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  434.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""missing_messages"));
  435.         // line 151
  436.         echo "                            ";
  437.         echo twig_call_macro($macros["helper"], "macro_render_table", [(isset($context["messages_missing"]) || array_key_exists("messages_missing"$context) ? $context["messages_missing"] : (function () { throw new RuntimeError('Variable "messages_missing" does not exist.'151$this->source); })())], 151$context$this->getSourceContext());
  438.         echo "
  439.                         ";
  440.         
  441.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  442.         
  443.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  444.     }
  445.     // line 165
  446.     public function macro_render_table($__messages__ null$__is_fallback__ null, ...$__varargs__)
  447.     {
  448.         $macros $this->macros;
  449.         $context $this->env->mergeGlobals([
  450.             "messages" => $__messages__,
  451.             "is_fallback" => $__is_fallback__,
  452.             "varargs" => $__varargs__,
  453.         ]);
  454.         $blocks = [];
  455.         ob_start();
  456.         try {
  457.             $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  458.             $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "macro""render_table"));
  459.             $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  460.             $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "macro""render_table"));
  461.             // line 166
  462.             echo "    <table data-filters>
  463.         <thead>
  464.             <tr>
  465.                 <th data-filter=\"locale\">Locale</th>
  466.                 ";
  467.             // line 170
  468.             if ((isset($context["is_fallback"]) || array_key_exists("is_fallback"$context) ? $context["is_fallback"] : (function () { throw new RuntimeError('Variable "is_fallback" does not exist.'170$this->source); })())) {
  469.                 // line 171
  470.                 echo "                    <th>Fallback locale</th>
  471.                 ";
  472.             }
  473.             // line 173
  474.             echo "                <th data-filter=\"domain\">Domain</th>
  475.                 <th>Times used</th>
  476.                 <th>Message ID</th>
  477.                 <th>Message Preview</th>
  478.             </tr>
  479.         </thead>
  480.         <tbody>
  481.         ";
  482.             // line 180
  483.             $context['_parent'] = $context;
  484.             $context['_seq'] = twig_ensure_traversable((isset($context["messages"]) || array_key_exists("messages"$context) ? $context["messages"] : (function () { throw new RuntimeError('Variable "messages" does not exist.'180$this->source); })()));
  485.             $context['loop'] = [
  486.               'parent' => $context['_parent'],
  487.               'index0' => 0,
  488.               'index'  => 1,
  489.               'first'  => true,
  490.             ];
  491.             if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  492.                 $length count($context['_seq']);
  493.                 $context['loop']['revindex0'] = $length 1;
  494.                 $context['loop']['revindex'] = $length;
  495.                 $context['loop']['length'] = $length;
  496.                 $context['loop']['last'] = === $length;
  497.             }
  498.             foreach ($context['_seq'] as $context["_key"] => $context["message"]) {
  499.                 // line 181
  500.                 echo "            <tr data-filter-locale=\"";
  501.                 echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["message"], "locale", [], "any"falsefalsefalse181), "html"nulltrue);
  502.                 echo "\" data-filter-domain=\"";
  503.                 echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["message"], "domain", [], "any"falsefalsefalse181), "html"nulltrue);
  504.                 echo "\">
  505.                 <td class=\"font-normal text-small nowrap\">";
  506.                 // line 182
  507.                 echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["message"], "locale", [], "any"falsefalsefalse182), "html"nulltrue);
  508.                 echo "</td>
  509.                 ";
  510.                 // line 183
  511.                 if ((isset($context["is_fallback"]) || array_key_exists("is_fallback"$context) ? $context["is_fallback"] : (function () { throw new RuntimeError('Variable "is_fallback" does not exist.'183$this->source); })())) {
  512.                     // line 184
  513.                     echo "                    <td class=\"font-normal text-small nowrap\">";
  514.                     echo twig_escape_filter($this->env, ((twig_get_attribute($this->env$this->source$context["message"], "fallbackLocale", [], "any"truetruefalse184)) ? (_twig_default_filter(twig_get_attribute($this->env$this->source$context["message"], "fallbackLocale", [], "any"falsefalsefalse184), "-")) : ("-")), "html"nulltrue);
  515.                     echo "</td>
  516.                 ";
  517.                 }
  518.                 // line 186
  519.                 echo "                <td class=\"font-normal text-small text-bold nowrap\">";
  520.                 echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["message"], "domain", [], "any"falsefalsefalse186), "html"nulltrue);
  521.                 echo "</td>
  522.                 <td class=\"font-normal text-small nowrap\">";
  523.                 // line 187
  524.                 echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["message"], "count", [], "any"falsefalsefalse187), "html"nulltrue);
  525.                 echo "</td>
  526.                 <td>
  527.                     <span class=\"";
  528.                 // line 189
  529.                 echo (((twig_length_filter($this->envtwig_get_attribute($this->env$this->source$context["message"], "id", [], "any"falsefalsefalse189)) < 64)) ? ("nowrap") : (""));
  530.                 echo "\">";
  531.                 echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["message"], "id", [], "any"falsefalsefalse189), "html"nulltrue);
  532.                 echo "</span>
  533.                     ";
  534.                 // line 191
  535.                 if ( !(null === twig_get_attribute($this->env$this->source$context["message"], "transChoiceNumber", [], "any"falsefalsefalse191))) {
  536.                     // line 192
  537.                     echo "                        <small class=\"newline\">(pluralization is used)</small>
  538.                     ";
  539.                 }
  540.                 // line 194
  541.                 echo "
  542.                     ";
  543.                 // line 195
  544.                 if ((twig_length_filter($this->envtwig_get_attribute($this->env$this->source$context["message"], "parameters", [], "any"falsefalsefalse195)) > 0)) {
  545.                     // line 196
  546.                     echo "                        <button class=\"btn-link newline text-small sf-toggle\" data-toggle-selector=\"#parameters-";
  547.                     echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["loop"], "index", [], "any"falsefalsefalse196), "html"nulltrue);
  548.                     echo "\" data-toggle-alt-content=\"Hide parameters\">Show parameters</button>
  549.                         <div id=\"parameters-";
  550.                     // line 198
  551.                     echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["loop"], "index", [], "any"falsefalsefalse198), "html"nulltrue);
  552.                     echo "\" class=\"hidden\">
  553.                             ";
  554.                     // line 199
  555.                     $context['_parent'] = $context;
  556.                     $context['_seq'] = twig_ensure_traversable(twig_get_attribute($this->env$this->source$context["message"], "parameters", [], "any"falsefalsefalse199));
  557.                     foreach ($context['_seq'] as $context["_key"] => $context["parameters"]) {
  558.                         // line 200
  559.                         echo "                                ";
  560.                         echo $this->extensions['Symfony\Bundle\WebProfilerBundle\Twig\WebProfilerExtension']->dumpData($this->env$context["parameters"], 1);
  561.                         echo "
  562.                             ";
  563.                     }
  564.                     $_parent $context['_parent'];
  565.                     unset($context['_seq'], $context['_iterated'], $context['_key'], $context['parameters'], $context['_parent'], $context['loop']);
  566.                     $context array_intersect_key($context$_parent) + $_parent;
  567.                     // line 202
  568.                     echo "                        </div>
  569.                     ";
  570.                 }
  571.                 // line 204
  572.                 echo "                </td>
  573.                 <td class=\"prewrap\">";
  574.                 // line 205
  575.                 echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["message"], "translation", [], "any"falsefalsefalse205), "html"nulltrue);
  576.                 echo "</td>
  577.             </tr>
  578.         ";
  579.                 ++$context['loop']['index0'];
  580.                 ++$context['loop']['index'];
  581.                 $context['loop']['first'] = false;
  582.                 if (isset($context['loop']['length'])) {
  583.                     --$context['loop']['revindex0'];
  584.                     --$context['loop']['revindex'];
  585.                     $context['loop']['last'] = === $context['loop']['revindex0'];
  586.                 }
  587.             }
  588.             $_parent $context['_parent'];
  589.             unset($context['_seq'], $context['_iterated'], $context['_key'], $context['message'], $context['_parent'], $context['loop']);
  590.             $context array_intersect_key($context$_parent) + $_parent;
  591.             // line 208
  592.             echo "        </tbody>
  593.     </table>
  594. ";
  595.             
  596.             $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  597.             
  598.             $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  599.             return ('' === $tmp ob_get_contents()) ? '' : new Markup($tmp$this->env->getCharset());
  600.         } finally {
  601.             ob_end_clean();
  602.         }
  603.     }
  604.     public function getTemplateName()
  605.     {
  606.         return "@WebProfiler/Collector/translation.html.twig";
  607.     }
  608.     public function isTraitable()
  609.     {
  610.         return false;
  611.     }
  612.     public function getDebugInfo()
  613.     {
  614.         return array (  660 => 208,  643 => 205,  640 => 204,  636 => 202,  627 => 200,  623 => 199,  619 => 198,  613 => 196,  611 => 195,  608 => 194,  604 => 192,  602 => 191,  595 => 189,  590 => 187,  585 => 186,  579 => 184,  577 => 183,  573 => 182,  566 => 181,  549 => 180,  540 => 173,  536 => 171,  534 => 170,  528 => 166,  508 => 165,  495 => 151,  485 => 150,  472 => 129,  462 => 128,  449 => 108,  439 => 107,  423 => 154,  420 => 153,  417 => 150,  411 => 146,  409 => 145,  395 => 136,  391 => 135,  386 => 132,  383 => 131,  380 => 128,  374 => 124,  372 => 123,  359 => 115,  353 => 111,  350 => 110,  347 => 107,  341 => 103,  339 => 102,  329 => 95,  325 => 94,  321 => 92,  315 => 91,  312 => 90,  309 => 89,  306 => 88,  303 => 87,  300 => 86,  297 => 85,  294 => 84,  289 => 83,  286 => 82,  283 => 80,  273 => 79,  262 => 162,  259 => 161,  256 => 79,  250 => 75,  248 => 74,  239 => 68,  235 => 67,  228 => 63,  222 => 59,  212 => 58,  201 => 55,  195 => 52,  192 => 51,  189 => 50,  187 => 49,  182 => 47,  175 => 46,  165 => 45,  152 => 41,  149 => 40,  143 => 37,  134 => 31,  130 => 30,  121 => 24,  117 => 23,  109 => 18,  104 => 15,  102 => 14,  99 => 13,  93 => 11,  90 => 10,  88 => 9,  83 => 8,  80 => 7,  77 => 6,  67 => 5,  56 => 1,  54 => 3,  41 => 1,);
  615.     }
  616.     public function getSourceContext()
  617.     {
  618.         return new Source("{% extends '@WebProfiler/Profiler/layout.html.twig' %}
  619. {% import _self as helper %}
  620. {% block toolbar %}
  621.     {% if collector.messages|length %}
  622.         {% set icon %}
  623.             {{ source('@WebProfiler/Icon/translation.svg') }}
  624.             {% set status_color = collector.countMissings ? 'red' : collector.countFallbacks ? 'yellow' %}
  625.             {% set error_count = collector.countMissings + collector.countFallbacks %}
  626.             <span class=\"sf-toolbar-value\">{{ error_count ?: collector.countDefines }}</span>
  627.         {% endset %}
  628.         {% set text %}
  629.             <div class=\"sf-toolbar-info-piece\">
  630.                 <b>Default locale</b>
  631.                 <span class=\"sf-toolbar-status\">
  632.                     {{ collector.locale|default('-') }}
  633.                 </span>
  634.             </div>
  635.             <div class=\"sf-toolbar-info-piece\">
  636.                 <b>Missing messages</b>
  637.                 <span class=\"sf-toolbar-status sf-toolbar-status-{{ collector.countMissings ? 'red' }}\">
  638.                     {{ collector.countMissings }}
  639.                 </span>
  640.             </div>
  641.             <div class=\"sf-toolbar-info-piece\">
  642.                 <b>Fallback messages</b>
  643.                 <span class=\"sf-toolbar-status sf-toolbar-status-{{ collector.countFallbacks ? 'yellow' }}\">
  644.                     {{ collector.countFallbacks }}
  645.                 </span>
  646.             </div>
  647.             <div class=\"sf-toolbar-info-piece\">
  648.                 <b>Defined messages</b>
  649.                 <span class=\"sf-toolbar-status\">{{ collector.countDefines }}</span>
  650.             </div>
  651.         {% endset %}
  652.         {{ include('@WebProfiler/Profiler/toolbar_item.html.twig', { link: profiler_url, status: status_color }) }}
  653.     {% endif %}
  654. {% endblock %}
  655. {% block menu %}
  656.     <span class=\"label label-status-{{ collector.countMissings ? 'error' : collector.countFallbacks ? 'warning' }} {{ collector.messages is empty ? 'disabled' }}\">
  657.         <span class=\"icon\">{{ source('@WebProfiler/Icon/translation.svg') }}</span>
  658.         <strong>Translation</strong>
  659.         {% if collector.countMissings or collector.countFallbacks %}
  660.             {% set error_count = collector.countMissings + collector.countFallbacks %}
  661.             <span class=\"count\">
  662.                 <span>{{ error_count }}</span>
  663.             </span>
  664.         {% endif %}
  665.     </span>
  666. {% endblock %}
  667. {% block panel %}
  668.     <h2>Translation</h2>
  669.     <div class=\"metrics\">
  670.         <div class=\"metric\">
  671.             <span class=\"value\">{{ collector.locale|default('-') }}</span>
  672.             <span class=\"label\">Default locale</span>
  673.         </div>
  674.         <div class=\"metric\">
  675.             <span class=\"value\">{{ collector.fallbackLocales|join(', ')|default('-') }}</span>
  676.             <span class=\"label\">Fallback locale{{ collector.fallbackLocales|length != 1 ? 's' }}</span>
  677.         </div>
  678.     </div>
  679.     <h2>Messages</h2>
  680.     {% if collector.messages is empty %}
  681.         <div class=\"empty empty-panel\">
  682.             <p>No translations have been called.</p>
  683.         </div>
  684.     {% else %}
  685.         {% block messages %}
  686.         {# sort translation messages in groups #}
  687.         {% set messages_defined, messages_missing, messages_fallback = [], [], [] %}
  688.         {% for message in collector.messages %}
  689.             {% if message.state == constant('Symfony\\\\Component\\\\Translation\\\\DataCollectorTranslator::MESSAGE_DEFINED') %}
  690.                 {% set messages_defined = messages_defined|merge([message]) %}
  691.             {% elseif message.state == constant('Symfony\\\\Component\\\\Translation\\\\DataCollectorTranslator::MESSAGE_MISSING') %}
  692.                 {% set messages_missing = messages_missing|merge([message]) %}
  693.             {% elseif message.state == constant('Symfony\\\\Component\\\\Translation\\\\DataCollectorTranslator::MESSAGE_EQUALS_FALLBACK') %}
  694.                 {% set messages_fallback = messages_fallback|merge([message]) %}
  695.             {% endif %}
  696.         {% endfor %}
  697.         <div class=\"sf-tabs\">
  698.             <div class=\"tab {{ collector.countMissings == 0 ? 'active' }}\">
  699.                 <h3 class=\"tab-title\">Defined <span class=\"badge\">{{ collector.countDefines }}</span></h3>
  700.                 <div class=\"tab-content\">
  701.                     <p class=\"help\">
  702.                         These messages are correctly translated into the given locale.
  703.                     </p>
  704.                     {% if messages_defined is empty %}
  705.                         <div class=\"empty\">
  706.                             <p>None of the used translation messages are defined for the given locale.</p>
  707.                         </div>
  708.                     {% else %}
  709.                         {% block defined_messages %}
  710.                             {{ helper.render_table(messages_defined) }}
  711.                         {% endblock %}
  712.                     {% endif %}
  713.                 </div>
  714.             </div>
  715.             <div class=\"tab\">
  716.                 <h3 class=\"tab-title\">Fallback <span class=\"badge {{ collector.countFallbacks ? 'status-warning' }}\">{{ collector.countFallbacks }}</span></h3>
  717.                 <div class=\"tab-content\">
  718.                     <p class=\"help\">
  719.                         These messages are not available for the given locale
  720.                         but Symfony found them in the fallback locale catalog.
  721.                     </p>
  722.                     {% if messages_fallback is empty %}
  723.                         <div class=\"empty\">
  724.                             <p>No fallback translation messages were used.</p>
  725.                         </div>
  726.                     {% else %}
  727.                         {% block fallback_messages %}
  728.                             {{ helper.render_table(messages_fallback, true) }}
  729.                         {% endblock %}
  730.                     {% endif %}
  731.                 </div>
  732.             </div>
  733.             <div class=\"tab {{ collector.countMissings > 0 ? 'active' }}\">
  734.                 <h3 class=\"tab-title\">Missing <span class=\"badge {{ collector.countMissings ? 'status-error' }}\">{{ collector.countMissings }}</span></h3>
  735.                 <div class=\"tab-content\">
  736.                     <p class=\"help\">
  737.                         These messages are not available for the given locale and cannot
  738.                         be found in the fallback locales. Add them to the translation
  739.                         catalogue to avoid Symfony outputting untranslated contents.
  740.                     </p>
  741.                     {% if messages_missing is empty %}
  742.                         <div class=\"empty\">
  743.                             <p>There are no messages of this category.</p>
  744.                         </div>
  745.                     {% else %}
  746.                         {% block missing_messages %}
  747.                             {{ helper.render_table(messages_missing) }}
  748.                         {% endblock %}
  749.                     {% endif %}
  750.                 </div>
  751.             </div>
  752.         </div>
  753.         <script>Sfjs.createFilters();</script>
  754.         {% endblock messages %}
  755.     {% endif %}
  756. {% endblock %}
  757. {% macro render_table(messages, is_fallback) %}
  758.     <table data-filters>
  759.         <thead>
  760.             <tr>
  761.                 <th data-filter=\"locale\">Locale</th>
  762.                 {% if is_fallback %}
  763.                     <th>Fallback locale</th>
  764.                 {% endif %}
  765.                 <th data-filter=\"domain\">Domain</th>
  766.                 <th>Times used</th>
  767.                 <th>Message ID</th>
  768.                 <th>Message Preview</th>
  769.             </tr>
  770.         </thead>
  771.         <tbody>
  772.         {% for message in messages %}
  773.             <tr data-filter-locale=\"{{ message.locale }}\" data-filter-domain=\"{{ message.domain }}\">
  774.                 <td class=\"font-normal text-small nowrap\">{{ message.locale }}</td>
  775.                 {% if is_fallback %}
  776.                     <td class=\"font-normal text-small nowrap\">{{ message.fallbackLocale|default('-') }}</td>
  777.                 {% endif %}
  778.                 <td class=\"font-normal text-small text-bold nowrap\">{{ message.domain }}</td>
  779.                 <td class=\"font-normal text-small nowrap\">{{ message.count }}</td>
  780.                 <td>
  781.                     <span class=\"{{ message.id|length < 64 ? 'nowrap' }}\">{{ message.id }}</span>
  782.                     {% if message.transChoiceNumber is not null %}
  783.                         <small class=\"newline\">(pluralization is used)</small>
  784.                     {% endif %}
  785.                     {% if message.parameters|length > 0 %}
  786.                         <button class=\"btn-link newline text-small sf-toggle\" data-toggle-selector=\"#parameters-{{ loop.index }}\" data-toggle-alt-content=\"Hide parameters\">Show parameters</button>
  787.                         <div id=\"parameters-{{ loop.index }}\" class=\"hidden\">
  788.                             {% for parameters in message.parameters %}
  789.                                 {{ profiler_dump(parameters, maxDepth=1) }}
  790.                             {% endfor %}
  791.                         </div>
  792.                     {% endif %}
  793.                 </td>
  794.                 <td class=\"prewrap\">{{ message.translation }}</td>
  795.             </tr>
  796.         {% endfor %}
  797.         </tbody>
  798.     </table>
  799. {% endmacro %}
  800. ""@WebProfiler/Collector/translation.html.twig""/home/bestofi/bestof/vendor/symfony/web-profiler-bundle/Resources/views/Collector/translation.html.twig");
  801.     }
  802. }