install gulp + reset

This commit is contained in:
2018-07-02 10:20:38 +02:00
parent 967f6c0e3e
commit 5dd9b69860
8369 changed files with 795362 additions and 210 deletions
@@ -0,0 +1,842 @@
<?php
/* forms/fields/list/list.html.twig */
class __TwigTemplate_2c5e0d204ff879a907326b7b33785dbeea7606bacd52cebe4bcab6546177060a extends Twig_Template
{
public function __construct(Twig_Environment $env)
{
parent::__construct($env);
// line 1
$this->parent = $this->loadTemplate("forms/field.html.twig", "forms/fields/list/list.html.twig", 1);
$this->blocks = array(
'contents' => array($this, 'block_contents'),
'global_attributes' => array($this, 'block_global_attributes'),
'__internal_e408f6e41354bae6411f4fb2bf2e9ca816e0821165964d2e30246de2e260224d' => array($this, 'block___internal_e408f6e41354bae6411f4fb2bf2e9ca816e0821165964d2e30246de2e260224d'),
);
}
protected function doGetParent(array $context)
{
return "forms/field.html.twig";
}
protected function doDisplay(array $context, array $blocks = array())
{
// line 3
$context["value"] = (((null === ($context["value"] ?? null))) ? ($this->getAttribute(($context["field"] ?? null), "default", array())) : (($context["value"] ?? null)));
// line 4
$context["name"] = $this->getAttribute(($context["field"] ?? null), "name", array());
// line 5
$context["btnLabel"] = (($this->getAttribute(($context["field"] ?? null), "btnLabel", array(), "any", true, true)) ? ($this->getAttribute(($context["field"] ?? null), "btnLabel", array())) : ("PLUGIN_ADMIN.ADD_ITEM"));
// line 6
$context["btnSortLabel"] = (($this->getAttribute(($context["field"] ?? null), "btnSortLabel", array(), "any", true, true)) ? ($this->getAttribute(($context["field"] ?? null), "btnSortLabel", array())) : ("PLUGIN_ADMIN.SORT_BY"));
// line 7
$context["fieldControls"] = (($this->getAttribute(($context["field"] ?? null), "controls", array(), "any", true, true)) ? (_twig_default_filter($this->getAttribute(($context["field"] ?? null), "controls", array()), "bottom")) : ("bottom"));
// line 1
$this->parent->display($context, array_merge($this->blocks, $blocks));
}
// line 9
public function block_contents($context, array $blocks = array())
{
// line 10
echo " <div class=\"form-label";
if ( !($context["vertical"] ?? null)) {
echo " block size-1-3 pure-u-1-3";
}
echo "\">
";
// line 11
if ($this->getAttribute(($context["field"] ?? null), "toggleable", array())) {
// line 12
echo " <span class=\"checkboxes toggleable\" data-grav-field=\"toggleable\" data-grav-field-name=\"";
echo twig_escape_filter($this->env, $this->env->getExtension('Grav\Common\Twig\TwigExtension')->fieldNameFilter((($context["scope"] ?? null) . $this->getAttribute(($context["field"] ?? null), "name", array()))), "html", null, true);
echo "\">
<input type=\"checkbox\"
id=\"toggleable_";
// line 14
echo twig_escape_filter($this->env, $this->getAttribute(($context["field"] ?? null), "name", array()), "html", null, true);
echo "\"
";
// line 15
if (($context["toggleableChecked"] ?? null)) {
echo "value=\"1\"";
}
// line 16
echo " name=\"toggleable_";
echo twig_escape_filter($this->env, $this->env->getExtension('Grav\Common\Twig\TwigExtension')->fieldNameFilter((($context["scope"] ?? null) . $this->getAttribute(($context["field"] ?? null), "name", array()))), "html", null, true);
echo "\"
";
// line 17
if (($context["toggleableChecked"] ?? null)) {
echo "checked=\"checked\"";
}
// line 18
echo " >
<label for=\"toggleable_";
// line 19
echo twig_escape_filter($this->env, $this->getAttribute(($context["field"] ?? null), "name", array()), "html", null, true);
echo "\"></label>
</span>
";
}
// line 22
echo " <label";
echo (($this->getAttribute(($context["field"] ?? null), "toggleable", array())) ? (((" class=\"toggleable\" for=\"toggleable_" . $this->getAttribute(($context["field"] ?? null), "name", array())) . "\"")) : (""));
echo ">
";
// line 23
if ($this->getAttribute(($context["field"] ?? null), "help", array())) {
// line 24
echo " <span class=\"hint--bottom\" data-hint=\"";
echo twig_escape_filter($this->env, $this->env->getExtension('Grav\Plugin\Admin\Twig\AdminTwigExtension')->tuFilter(twig_escape_filter($this->env, $this->getAttribute(($context["field"] ?? null), "help", array()))), "html", null, true);
echo "\">";
echo twig_escape_filter($this->env, $this->env->getExtension('Grav\Plugin\Admin\Twig\AdminTwigExtension')->tuFilter($this->getAttribute(($context["field"] ?? null), "label", array())), "html", null, true);
echo "</span>
";
} else {
// line 26
echo " ";
echo twig_escape_filter($this->env, $this->env->getExtension('Grav\Plugin\Admin\Twig\AdminTwigExtension')->tuFilter($this->getAttribute(($context["field"] ?? null), "label", array())), "html", null, true);
echo "
";
}
// line 28
echo " ";
echo ((twig_in_filter($this->getAttribute($this->getAttribute(($context["field"] ?? null), "validate", array()), "required", array()), array(0 => "on", 1 => "true", 2 => 1))) ? ("<span class=\"required\">*</span>") : (""));
echo "
</label>
</div>
<div class=\"form-data";
// line 31
if ( !($context["vertical"] ?? null)) {
echo " block size-2-3 pure-u-2-3";
}
echo "\"
";
// line 32
$this->displayBlock('global_attributes', $context, $blocks);
// line 37
echo " >
<div class=\"form-list-wrapper ";
// line 39
echo twig_escape_filter($this->env, $this->getAttribute(($context["field"] ?? null), "size", array()), "html", null, true);
echo "\" data-type=\"collection\"
";
// line 40
if ($this->getAttribute(($context["field"] ?? null), "selectunique", array())) {
// line 41
echo " data-select-unique=\"";
echo twig_escape_filter($this->env, twig_jsonencode_filter($this->getAttribute(($context["field"] ?? null), "selectunique", array())), "html_attr");
echo "\"
data-max=\"";
// line 42
echo twig_escape_filter($this->env, twig_length_filter($this->env, $this->getAttribute(($context["field"] ?? null), "selectunique", array())), "html", null, true);
echo "\"
";
}
// line 44
echo " ";
if ($this->getAttribute(($context["field"] ?? null), "min", array(), "any", true, true)) {
echo "data-min=\"";
echo twig_escape_filter($this->env, $this->getAttribute(($context["field"] ?? null), "min", array()), "html", null, true);
echo "\"";
}
// line 45
echo " ";
if (($this->getAttribute(($context["field"] ?? null), "max", array(), "any", true, true) && !$this->getAttribute(($context["field"] ?? null), "selectunique", array()))) {
echo "data-max=\"";
echo twig_escape_filter($this->env, $this->getAttribute(($context["field"] ?? null), "max", array()), "html", null, true);
echo "\"";
}
// line 46
echo " >
";
// line 47
if (twig_in_filter(($context["fieldControls"] ?? null), array(0 => "top", 1 => "both"))) {
// line 48
echo " <div class=\"collection-actions\">
";
// line 49
if (($context["collapsible"] ?? null)) {
// line 50
echo " <button class=\"button\" type=\"button\" data-action=\"expand_all\"
";
// line 51
if (($this->getAttribute(($context["field"] ?? null), "disabled", array()) || ($context["isDisabledToggleable"] ?? null))) {
echo "disabled=\"disabled\"";
}
echo "><i class=\"fa fa-chevron-circle-down\"></i> ";
echo twig_escape_filter($this->env, $this->env->getExtension('Grav\Plugin\Admin\Twig\AdminTwigExtension')->tuFilter(twig_escape_filter($this->env, "PLUGIN_ADMIN.EXPAND_ALL")), "html", null, true);
echo "</button>
<button class=\"button\" type=\"button\" data-action=\"collapse_all\"
";
// line 53
if (($this->getAttribute(($context["field"] ?? null), "disabled", array()) || ($context["isDisabledToggleable"] ?? null))) {
echo "disabled=\"disabled\"";
}
echo "><i class=\"fa fa-chevron-circle-right\"></i> ";
echo twig_escape_filter($this->env, $this->env->getExtension('Grav\Plugin\Admin\Twig\AdminTwigExtension')->tuFilter(twig_escape_filter($this->env, "PLUGIN_ADMIN.COLLAPSE_ALL")), "html", null, true);
echo "</button>
";
}
// line 55
echo " ";
if ($this->getAttribute(($context["field"] ?? null), "sortby", array())) {
// line 56
echo " <button class=\"button";
echo (( !twig_length_filter($this->env, ($context["value"] ?? null))) ? (" hidden") : (""));
echo "\" type=\"button\" data-action=\"sort\" data-action-sort=\"";
echo twig_escape_filter($this->env, $this->getAttribute(($context["field"] ?? null), "sortby", array()), "html", null, true);
echo "\" data-action-sort-dir=\"";
echo twig_escape_filter($this->env, (($this->getAttribute(($context["field"] ?? null), "sortby_dir", array(), "any", true, true)) ? (_twig_default_filter($this->getAttribute(($context["field"] ?? null), "sortby_dir", array()), "asc")) : ("asc")), "html", null, true);
echo "\"
";
// line 57
if (($this->getAttribute(($context["field"] ?? null), "disabled", array()) || ($context["isDisabledToggleable"] ?? null))) {
echo "disabled=\"disabled\"";
}
echo "><i class=\"fa fa-sort-amount-";
echo twig_escape_filter($this->env, (($this->getAttribute(($context["field"] ?? null), "sortby_dir", array(), "any", true, true)) ? (_twig_default_filter($this->getAttribute(($context["field"] ?? null), "sortby_dir", array()), "asc")) : ("asc")), "html", null, true);
echo "\"></i> ";
echo twig_escape_filter($this->env, $this->env->getExtension('Grav\Plugin\Admin\Twig\AdminTwigExtension')->tuFilter(twig_escape_filter($this->env, ($context["btnSortLabel"] ?? null))), "html", null, true);
echo " '";
echo twig_escape_filter($this->env, $this->getAttribute(($context["field"] ?? null), "sortby", array()), "html", null, true);
echo "'</button>
";
}
// line 59
echo " <button class=\"button\" type=\"button\" data-action=\"add\" data-action-add=\"bottom\"
";
// line 60
if (($this->getAttribute(($context["field"] ?? null), "disabled", array()) || ($context["isDisabledToggleable"] ?? null))) {
echo "disabled=\"disabled\"";
}
echo "><i class=\"fa fa-plus\"></i> ";
echo twig_escape_filter($this->env, $this->env->getExtension('Grav\Plugin\Admin\Twig\AdminTwigExtension')->tuFilter(twig_escape_filter($this->env, ($context["btnLabel"] ?? null))), "html", null, true);
echo "</button>
</div>
";
}
// line 63
echo " <ul ";
if ($this->getAttribute(($context["field"] ?? null), "classes", array(), "any", true, true)) {
echo "class=\"";
echo twig_escape_filter($this->env, $this->getAttribute(($context["field"] ?? null), "classes", array()), "html", null, true);
echo "\"";
}
echo " data-collection-holder=\"";
echo twig_escape_filter($this->env, ($context["name"] ?? null), "html", null, true);
echo "\"
";
// line 64
if (($this->getAttribute(($context["field"] ?? null), "sort", array()) === false)) {
// line 65
echo " data-collection-nosort
";
}
// line 66
echo ">
";
// line 67
if ($this->getAttribute(($context["field"] ?? null), "fields", array())) {
// line 68
echo " ";
$context["collapsible"] = ((twig_length_filter($this->env, $this->getAttribute(($context["field"] ?? null), "fields", array())) > 1) && ( !$this->getAttribute(($context["field"] ?? null), "collapsible", array(), "any", true, true) || $this->getAttribute(($context["field"] ?? null), "collapsible", array())));
// line 69
echo " ";
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable(($context["value"] ?? null));
$context['loop'] = array(
'parent' => $context['_parent'],
'index0' => 0,
'index' => 1,
'first' => true,
);
if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof Countable)) {
$length = count($context['_seq']);
$context['loop']['revindex0'] = $length - 1;
$context['loop']['revindex'] = $length;
$context['loop']['length'] = $length;
$context['loop']['last'] = 1 === $length;
}
foreach ($context['_seq'] as $context["key"] => $context["val"]) {
// line 70
echo " ";
$context["itemName"] = ((($context["name"] ?? null)) ? (((($context["name"] ?? null) . ".") . $context["key"])) : ($context["key"]));
// line 71
echo " <li data-collection-item=\"";
echo twig_escape_filter($this->env, ($context["itemName"] ?? null), "html", null, true);
echo "\" data-collection-key=\"";
echo twig_escape_filter($this->env, $context["key"], "html", null, true);
echo "\" class=\"";
echo (((($context["collapsible"] ?? null) && $this->getAttribute(($context["field"] ?? null), "collapsed", array()))) ? ("collection-collapsed") : (""));
echo "\">
<div class=\"collection-sort\"><i class=\"fa fa-fw fa-bars\"></i></div>
";
// line 73
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable($this->getAttribute(($context["field"] ?? null), "fields", array()));
$context['loop'] = array(
'parent' => $context['_parent'],
'index0' => 0,
'index' => 1,
'first' => true,
);
if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof Countable)) {
$length = count($context['_seq']);
$context['loop']['revindex0'] = $length - 1;
$context['loop']['revindex'] = $length;
$context['loop']['length'] = $length;
$context['loop']['last'] = 1 === $length;
}
foreach ($context['_seq'] as $context["childName"] => $context["child"]) {
// line 74
if (($context["childName"] == "value")) {
// line 75
$context["childKey"] = "";
// line 76
echo " ";
$context["childValue"] = $context["val"];
// line 77
echo " ";
$context["childName"] = ($context["itemName"] ?? null);
} elseif ((is_string($__internal_7cd7461123377b8c9c1b6a01f46c7bbd94bd12e59266005df5e93029ddbc0ec5 = // line 78
$context["childName"]) && is_string($__internal_3e28b7f596c58d7729642bcf2acc6efc894803703bf5fa7e74cd8d2aa1f8c68a = ".") && ('' === $__internal_3e28b7f596c58d7729642bcf2acc6efc894803703bf5fa7e74cd8d2aa1f8c68a || 0 === strpos($__internal_7cd7461123377b8c9c1b6a01f46c7bbd94bd12e59266005df5e93029ddbc0ec5, $__internal_3e28b7f596c58d7729642bcf2acc6efc894803703bf5fa7e74cd8d2aa1f8c68a)))) {
// line 79
$context["childKey"] = twig_trim_filter($context["childName"], ".");
// line 80
echo " ";
$context["childValue"] = $this->getAttribute($context["val"], twig_slice($this->env, $context["childName"], 1, null), array(), "array");
// line 81
echo " ";
$context["childName"] = (($context["itemName"] ?? null) . $context["childName"]);
// line 82
echo " ";
} else {
// line 83
echo " ";
$context["childKey"] = $context["childName"];
// line 84
echo " ";
$context["childValue"] = $this->getAttribute(($context["data"] ?? null), "value", array(0 => (($context["scope"] ?? null) . $context["childName"])), "method");
// line 85
echo " ";
$context["childName"] = twig_replace_filter($context["childName"], array("*" => $context["key"]));
// line 86
echo " ";
}
// line 87
echo " ";
$context["child"] = twig_array_merge($context["child"], array("name" => $context["childName"]));
// line 88
echo "
";
// line 89
if (($this->getAttribute($context["child"], "type", array()) == "key")) {
// line 90
echo " ";
// line 91
$this->loadTemplate("forms/fields/key/key.html.twig", "forms/fields/list/list.html.twig", 91)->display(array_merge($context, array("field" => // line 92
$context["child"], "value" => $context["key"])));
// line 94
echo " ";
} elseif (($this->getAttribute($context["child"], "key", array()) == true)) {
// line 95
echo " ";
$this->loadTemplate(array(0 => (((("forms/fields/" . $this->getAttribute( // line 96
$context["child"], "type", array())) . "/") . $this->getAttribute($context["child"], "type", array())) . ".html.twig"), 1 => "forms/fields/key/key.html.twig"), "forms/fields/list/list.html.twig", 95)->display(array_merge($context, array("field" => // line 98
$context["child"], "value" => $context["key"])));
// line 100
echo " ";
} elseif ($this->getAttribute($context["child"], "type", array())) {
// line 101
echo " ";
$context["originalValue"] = ($context["childValue"] ?? null);
// line 102
echo " ";
// line 103
$this->loadTemplate(array(0 => (((("forms/fields/" . $this->getAttribute( // line 104
$context["child"], "type", array())) . "/") . $this->getAttribute($context["child"], "type", array())) . ".html.twig"), 1 => "forms/fields/text/text.html.twig"), "forms/fields/list/list.html.twig", 103)->display(array_merge($context, array("field" => // line 106
$context["child"], "value" => ($context["childValue"] ?? null))));
// line 108
echo " ";
}
// line 109
echo " ";
++$context['loop']['index0'];
++$context['loop']['index'];
$context['loop']['first'] = false;
if (isset($context['loop']['length'])) {
--$context['loop']['revindex0'];
--$context['loop']['revindex'];
$context['loop']['last'] = 0 === $context['loop']['revindex0'];
}
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['childName'], $context['child'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 110
echo " <div class=\"item-actions\">
";
// line 111
if (($context["collapsible"] ?? null)) {
// line 112
echo " <i class=\"fa fa-chevron-circle-";
echo (($this->getAttribute(($context["field"] ?? null), "collapsed", array())) ? ("right") : ("down"));
echo "\" data-action=\"";
echo (($this->getAttribute(($context["field"] ?? null), "collapsed", array())) ? ("expand") : ("collapse"));
echo "\"></i>
<br />
";
}
// line 115
echo " <i class=\"fa fa-trash-o\" data-action=\"delete\"></i>
</div>
</li>
";
++$context['loop']['index0'];
++$context['loop']['index'];
$context['loop']['first'] = false;
if (isset($context['loop']['length'])) {
--$context['loop']['revindex0'];
--$context['loop']['revindex'];
$context['loop']['last'] = 0 === $context['loop']['revindex0'];
}
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['key'], $context['val'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 119
echo " ";
}
// line 120
echo " </ul>
";
// line 121
if (twig_in_filter(($context["fieldControls"] ?? null), array(0 => "bottom", 1 => "both"))) {
// line 122
echo " <div class=\"collection-actions\">
";
// line 123
if (($context["collapsible"] ?? null)) {
// line 124
echo " <button class=\"button\" type=\"button\" data-action=\"expand_all\"
";
// line 125
if (($this->getAttribute(($context["field"] ?? null), "disabled", array()) || ($context["isDisabledToggleable"] ?? null))) {
echo "disabled=\"disabled\"";
}
echo "><i class=\"fa fa-chevron-circle-down\"></i> ";
echo twig_escape_filter($this->env, $this->env->getExtension('Grav\Plugin\Admin\Twig\AdminTwigExtension')->tuFilter(twig_escape_filter($this->env, "PLUGIN_ADMIN.EXPAND_ALL")), "html", null, true);
echo "</button>
<button class=\"button\" type=\"button\" data-action=\"collapse_all\"
";
// line 127
if (($this->getAttribute(($context["field"] ?? null), "disabled", array()) || ($context["isDisabledToggleable"] ?? null))) {
echo "disabled=\"disabled\"";
}
echo "><i class=\"fa fa-chevron-circle-right\"></i> ";
echo twig_escape_filter($this->env, $this->env->getExtension('Grav\Plugin\Admin\Twig\AdminTwigExtension')->tuFilter(twig_escape_filter($this->env, "PLUGIN_ADMIN.COLLAPSE_ALL")), "html", null, true);
echo "</button>
";
}
// line 129
echo " ";
if ($this->getAttribute(($context["field"] ?? null), "sortby", array())) {
// line 130
echo " <button class=\"button";
echo (( !twig_length_filter($this->env, ($context["value"] ?? null))) ? (" hidden") : (""));
echo "\" type=\"button\" data-action=\"sort\" data-action-sort=\"";
echo twig_escape_filter($this->env, $this->getAttribute(($context["field"] ?? null), "sortby", array()), "html", null, true);
echo "\" data-action-sort-dir=\"";
echo twig_escape_filter($this->env, (($this->getAttribute(($context["field"] ?? null), "sortby_dir", array(), "any", true, true)) ? (_twig_default_filter($this->getAttribute(($context["field"] ?? null), "sortby_dir", array()), "asc")) : ("asc")), "html", null, true);
echo "\"
";
// line 131
if (($this->getAttribute(($context["field"] ?? null), "disabled", array()) || ($context["isDisabledToggleable"] ?? null))) {
echo "disabled=\"disabled\"";
}
echo "><i class=\"fa fa-sort-amount-";
echo twig_escape_filter($this->env, (($this->getAttribute(($context["field"] ?? null), "sortby_dir", array(), "any", true, true)) ? (_twig_default_filter($this->getAttribute(($context["field"] ?? null), "sortby_dir", array()), "asc")) : ("asc")), "html", null, true);
echo "\"></i> ";
echo twig_escape_filter($this->env, $this->env->getExtension('Grav\Plugin\Admin\Twig\AdminTwigExtension')->tuFilter(twig_escape_filter($this->env, ($context["btnSortLabel"] ?? null))), "html", null, true);
echo " '";
echo twig_escape_filter($this->env, $this->getAttribute(($context["field"] ?? null), "sortby", array()), "html", null, true);
echo "'</button>
";
}
// line 133
echo " <button class=\"button\" type=\"button\" data-action=\"add\" data-action-add=\"bottom\"
";
// line 134
if (($this->getAttribute(($context["field"] ?? null), "disabled", array()) || ($context["isDisabledToggleable"] ?? null))) {
echo "disabled=\"disabled\"";
}
echo "><i class=\"fa fa-plus\"></i> ";
echo twig_escape_filter($this->env, $this->env->getExtension('Grav\Plugin\Admin\Twig\AdminTwigExtension')->tuFilter(twig_escape_filter($this->env, ($context["btnLabel"] ?? null))), "html", null, true);
echo "</button>
</div>
";
}
// line 138
$context["itemName"] = ((($context["name"] ?? null)) ? ((($context["name"] ?? null) . ".*")) : ("*"));
// line 139
echo "<div style=\"display: none;\" data-collection-template=\"new\" data-collection-template-html=\"";
echo twig_escape_filter($this->env, twig_replace_filter( $this->renderBlock("__internal_e408f6e41354bae6411f4fb2bf2e9ca816e0821165964d2e30246de2e260224d", $context, $blocks), array(" " => " ", "
" => " ")), "html_attr");
// line 188
echo "\"></div>
<div style=\"display: none;\" data-collection-config=\"";
// line 190
echo twig_escape_filter($this->env, ($context["name"] ?? null), "html", null, true);
echo "\"></div>
</div>
</div>
";
}
// line 32
public function block_global_attributes($context, array $blocks = array())
{
// line 33
echo " data-grav-field=\"";
echo twig_escape_filter($this->env, $this->getAttribute(($context["field"] ?? null), "type", array()), "html", null, true);
echo "\"
data-grav-disabled=\"";
// line 34
echo twig_escape_filter($this->env, ($context["toggleableChecked"] ?? null), "html", null, true);
echo "\"
data-grav-default=\"";
// line 35
echo twig_escape_filter($this->env, twig_jsonencode_filter($this->getAttribute(($context["field"] ?? null), "default", array())), "html_attr");
echo "\"
";
}
// line 139
public function block___internal_e408f6e41354bae6411f4fb2bf2e9ca816e0821165964d2e30246de2e260224d($context, array $blocks = array())
{
// line 140
echo "<li data-collection-item=\"";
echo twig_escape_filter($this->env, ($context["itemName"] ?? null), "html", null, true);
echo "\">
";
// line 141
if ( !($this->getAttribute(($context["field"] ?? null), "sort", array()) === false)) {
// line 142
echo " <div class=\"collection-sort\"><i class=\"fa fa-fw fa-bars\"></i></div>
";
}
// line 144
if ($this->getAttribute(($context["field"] ?? null), "fields", array())) {
// line 145
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable($this->getAttribute(($context["field"] ?? null), "fields", array()));
$context['loop'] = array(
'parent' => $context['_parent'],
'index0' => 0,
'index' => 1,
'first' => true,
);
if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof Countable)) {
$length = count($context['_seq']);
$context['loop']['revindex0'] = $length - 1;
$context['loop']['revindex'] = $length;
$context['loop']['length'] = $length;
$context['loop']['last'] = 1 === $length;
}
foreach ($context['_seq'] as $context["childName"] => $context["child"]) {
// line 146
if (($context["childName"] == "value")) {
// line 147
$context["childKey"] = "";
// line 148
$context["childName"] = ($context["itemName"] ?? null);
} elseif ((is_string($__internal_b0b3d6199cdf4d15a08b3fb98fe017ecb01164300193d18d78027218d843fc57 = // line 149
$context["childName"]) && is_string($__internal_81ccf322d0988ca0aa9ae9943d772c435c5ff01fb50b956278e245e40ae66ab9 = ".") && ('' === $__internal_81ccf322d0988ca0aa9ae9943d772c435c5ff01fb50b956278e245e40ae66ab9 || 0 === strpos($__internal_b0b3d6199cdf4d15a08b3fb98fe017ecb01164300193d18d78027218d843fc57, $__internal_81ccf322d0988ca0aa9ae9943d772c435c5ff01fb50b956278e245e40ae66ab9)))) {
// line 150
$context["childKey"] = twig_trim_filter($context["childName"], ".");
// line 151
$context["childName"] = (($context["itemName"] ?? null) . $context["childName"]);
} else {
// line 153
$context["childKey"] = $context["childName"];
// line 154
$context["childName"] = twig_replace_filter($context["childName"], array("*" => ($context["key"] ?? null)));
}
// line 156
$context["child"] = twig_array_merge($context["child"], array("name" => $context["childName"]));
// line 158
if (($this->getAttribute($context["child"], "type", array()) == "key")) {
// line 160
$this->loadTemplate("forms/fields/key/key.html.twig", "forms/fields/list/list.html.twig", 160)->display(array_merge($context, array("field" => // line 161
$context["child"], "value" => null)));
} elseif (($this->getAttribute( // line 163
$context["child"], "key", array()) == true)) {
// line 165
$this->loadTemplate(array(0 => (((("forms/fields/" . $this->getAttribute( // line 166
$context["child"], "type", array())) . "/") . $this->getAttribute($context["child"], "type", array())) . ".html.twig"), 1 => "forms/fields/key/key.html.twig"), "forms/fields/list/list.html.twig", 165)->display(array_merge($context, array("field" => // line 168
$context["child"], "value" => null)));
} elseif ($this->getAttribute( // line 170
$context["child"], "type", array())) {
// line 172
$this->loadTemplate(array(0 => (((("forms/fields/" . $this->getAttribute( // line 173
$context["child"], "type", array())) . "/") . $this->getAttribute($context["child"], "type", array())) . ".html.twig"), 1 => "forms/fields/text/text.html.twig"), "forms/fields/list/list.html.twig", 172)->display(array_merge($context, array("field" => // line 175
$context["child"], "value" => null)));
}
++$context['loop']['index0'];
++$context['loop']['index'];
$context['loop']['first'] = false;
if (isset($context['loop']['length'])) {
--$context['loop']['revindex0'];
--$context['loop']['revindex'];
$context['loop']['last'] = 0 === $context['loop']['revindex0'];
}
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['childName'], $context['child'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 179
echo " <div class=\"item-actions\">
";
// line 180
if (($context["collapsible"] ?? null)) {
// line 181
echo " <i class=\"fa fa-chevron-circle-down\" data-action=\"collapse\"></i>
<br />
";
}
// line 184
echo " <i class=\"fa fa-trash-o\" data-action=\"delete\"></i>
</div>";
}
// line 187
echo "</li>";
}
public function getTemplateName()
{
return "forms/fields/list/list.html.twig";
}
public function isTraitable()
{
return false;
}
public function getDebugInfo()
{
return array ( 618 => 187, 614 => 184, 609 => 181, 607 => 180, 604 => 179, 589 => 175, 588 => 173, 587 => 172, 585 => 170, 583 => 168, 582 => 166, 581 => 165, 579 => 163, 577 => 161, 576 => 160, 574 => 158, 572 => 156, 569 => 154, 567 => 153, 564 => 151, 562 => 150, 560 => 149, 558 => 148, 556 => 147, 554 => 146, 537 => 145, 535 => 144, 531 => 142, 529 => 141, 524 => 140, 521 => 139, 515 => 35, 511 => 34, 506 => 33, 503 => 32, 495 => 190, 491 => 188, 487 => 139, 485 => 138, 475 => 134, 472 => 133, 459 => 131, 450 => 130, 447 => 129, 438 => 127, 429 => 125, 426 => 124, 424 => 123, 421 => 122, 419 => 121, 416 => 120, 413 => 119, 396 => 115, 387 => 112, 385 => 111, 382 => 110, 368 => 109, 365 => 108, 363 => 106, 362 => 104, 361 => 103, 359 => 102, 356 => 101, 353 => 100, 351 => 98, 350 => 96, 348 => 95, 345 => 94, 343 => 92, 342 => 91, 340 => 90, 338 => 89, 335 => 88, 332 => 87, 329 => 86, 326 => 85, 323 => 84, 320 => 83, 317 => 82, 314 => 81, 311 => 80, 309 => 79, 307 => 78, 304 => 77, 301 => 76, 299 => 75, 297 => 74, 280 => 73, 270 => 71, 267 => 70, 249 => 69, 246 => 68, 244 => 67, 241 => 66, 237 => 65, 235 => 64, 224 => 63, 214 => 60, 211 => 59, 198 => 57, 189 => 56, 186 => 55, 177 => 53, 168 => 51, 165 => 50, 163 => 49, 160 => 48, 158 => 47, 155 => 46, 148 => 45, 141 => 44, 136 => 42, 131 => 41, 129 => 40, 125 => 39, 121 => 37, 119 => 32, 113 => 31, 106 => 28, 100 => 26, 92 => 24, 90 => 23, 85 => 22, 79 => 19, 76 => 18, 72 => 17, 67 => 16, 63 => 15, 59 => 14, 53 => 12, 51 => 11, 44 => 10, 41 => 9, 37 => 1, 35 => 7, 33 => 6, 31 => 5, 29 => 4, 27 => 3, 11 => 1,);
}
/** @deprecated since 1.27 (to be removed in 2.0). Use getSourceContext() instead */
public function getSource()
{
@trigger_error('The '.__METHOD__.' method is deprecated since version 1.27 and will be removed in 2.0. Use getSourceContext() instead.', E_USER_DEPRECATED);
return $this->getSourceContext()->getCode();
}
public function getSourceContext()
{
return new Twig_Source("{% extends \"forms/field.html.twig\" %}
{% set value = (value is null ? field.default : value) %}
{% set name = field.name %}
{% set btnLabel = field.btnLabel is defined ? field.btnLabel : \"PLUGIN_ADMIN.ADD_ITEM\" %}
{% set btnSortLabel = field.btnSortLabel is defined ? field.btnSortLabel : \"PLUGIN_ADMIN.SORT_BY\" %}
{% set fieldControls = field.controls|default('bottom') %}
{% block contents %}
<div class=\"form-label{% if not vertical %} block size-1-3 pure-u-1-3{% endif %}\">
{% if field.toggleable %}
<span class=\"checkboxes toggleable\" data-grav-field=\"toggleable\" data-grav-field-name=\"{{ (scope ~ field.name)|fieldName }}\">
<input type=\"checkbox\"
id=\"toggleable_{{ field.name }}\"
{% if toggleableChecked %}value=\"1\"{% endif %}
name=\"toggleable_{{ (scope ~ field.name)|fieldName }}\"
{% if toggleableChecked %}checked=\"checked\"{% endif %}
>
<label for=\"toggleable_{{ field.name }}\"></label>
</span>
{% endif %}
<label{{ (field.toggleable ? ' class=\"toggleable\" for=\"toggleable_' ~ field.name ~ '\"')|raw }}>
{% if field.help %}
<span class=\"hint--bottom\" data-hint=\"{{ field.help|e|tu }}\">{{ field.label|tu }}</span>
{% else %}
{{ field.label|tu }}
{% endif %}
{{ field.validate.required in ['on', 'true', 1] ? '<span class=\"required\">*</span>' }}
</label>
</div>
<div class=\"form-data{% if not vertical %} block size-2-3 pure-u-2-3{% endif %}\"
{% block global_attributes %}
data-grav-field=\"{{ field.type }}\"
data-grav-disabled=\"{{ toggleableChecked }}\"
data-grav-default=\"{{ field.default|json_encode|e('html_attr') }}\"
{% endblock %}
>
<div class=\"form-list-wrapper {{ field.size }}\" data-type=\"collection\"
{% if field.selectunique %}
data-select-unique=\"{{ field.selectunique|json_encode|e('html_attr') }}\"
data-max=\"{{ field.selectunique|length }}\"
{% endif %}
{% if field.min is defined %}data-min=\"{{ field.min }}\"{% endif %}
{% if field.max is defined and not field.selectunique %}data-max=\"{{ field.max }}\"{% endif %}
>
{% if fieldControls in ['top', 'both'] %}
<div class=\"collection-actions\">
{% if collapsible %}
<button class=\"button\" type=\"button\" data-action=\"expand_all\"
{% if field.disabled or isDisabledToggleable %}disabled=\"disabled\"{% endif %}><i class=\"fa fa-chevron-circle-down\"></i> {{ \"PLUGIN_ADMIN.EXPAND_ALL\"|e|tu }}</button>
<button class=\"button\" type=\"button\" data-action=\"collapse_all\"
{% if field.disabled or isDisabledToggleable %}disabled=\"disabled\"{% endif %}><i class=\"fa fa-chevron-circle-right\"></i> {{ \"PLUGIN_ADMIN.COLLAPSE_ALL\"|e|tu }}</button>
{% endif %}
{% if field.sortby %}
<button class=\"button{{ not value|length ? ' hidden' : '' }}\" type=\"button\" data-action=\"sort\" data-action-sort=\"{{ field.sortby }}\" data-action-sort-dir=\"{{ field.sortby_dir|default('asc') }}\"
{% if field.disabled or isDisabledToggleable %}disabled=\"disabled\"{% endif %}><i class=\"fa fa-sort-amount-{{ field.sortby_dir|default('asc') }}\"></i> {{ btnSortLabel|e|tu }} '{{ field.sortby }}'</button>
{% endif %}
<button class=\"button\" type=\"button\" data-action=\"add\" data-action-add=\"bottom\"
{% if field.disabled or isDisabledToggleable %}disabled=\"disabled\"{% endif %}><i class=\"fa fa-plus\"></i> {{ btnLabel|e|tu }}</button>
</div>
{% endif %}
<ul {% if field.classes is defined %}class=\"{{ field.classes }}\"{% endif %} data-collection-holder=\"{{ name }}\"
{% if field.sort is same as(false) %}
data-collection-nosort
{% endif %}>
{% if field.fields %}
{% set collapsible = field.fields|length > 1 and (field.collapsible is not defined or field.collapsible) %}
{% for key, val in value %}
{% set itemName = name ? name ~ '.' ~ key : key %}
<li data-collection-item=\"{{ itemName }}\" data-collection-key=\"{{ key }}\" class=\"{{ collapsible and field.collapsed ? 'collection-collapsed' : '' }}\">
<div class=\"collection-sort\"><i class=\"fa fa-fw fa-bars\"></i></div>
{% for childName, child in field.fields %}
{%- if childName == 'value' -%}
{% set childKey = '' %}
{% set childValue = val %}
{% set childName = itemName -%}
{%- elseif childName starts with '.' -%}
{% set childKey = childName|trim('.') %}
{% set childValue = val[childName[1:]] %}
{% set childName = itemName ~ childName %}
{% else %}
{% set childKey = childName %}
{% set childValue = data.value(scope ~ childName) %}
{% set childName = childName|replace({'*': key}) %}
{% endif %}
{% set child = child|merge({ name: childName }) %}
{% if child.type == 'key' %}
{%
include 'forms/fields/key/key.html.twig'
with { field: child, value: key }
%}
{% elseif child.key == true %}
{% include [
\"forms/fields/#{child.type}/#{child.type}.html.twig\",
'forms/fields/key/key.html.twig'
] with { field: child, value: key }
%}
{% elseif child.type %}
{% set originalValue = childValue %}
{%
include [
\"forms/fields/#{child.type}/#{child.type}.html.twig\",
'forms/fields/text/text.html.twig'
] with { field: child, value: childValue }
%}
{% endif %}
{% endfor %}
<div class=\"item-actions\">
{% if collapsible %}
<i class=\"fa fa-chevron-circle-{{ field.collapsed ? 'right' : 'down' }}\" data-action=\"{{ field.collapsed ? 'expand' : 'collapse' }}\"></i>
<br />
{% endif %}
<i class=\"fa fa-trash-o\" data-action=\"delete\"></i>
</div>
</li>
{% endfor %}
{% endif %}
</ul>
{% if fieldControls in ['bottom', 'both'] %}
<div class=\"collection-actions\">
{% if collapsible %}
<button class=\"button\" type=\"button\" data-action=\"expand_all\"
{% if field.disabled or isDisabledToggleable %}disabled=\"disabled\"{% endif %}><i class=\"fa fa-chevron-circle-down\"></i> {{ \"PLUGIN_ADMIN.EXPAND_ALL\"|e|tu }}</button>
<button class=\"button\" type=\"button\" data-action=\"collapse_all\"
{% if field.disabled or isDisabledToggleable %}disabled=\"disabled\"{% endif %}><i class=\"fa fa-chevron-circle-right\"></i> {{ \"PLUGIN_ADMIN.COLLAPSE_ALL\"|e|tu }}</button>
{% endif %}
{% if field.sortby %}
<button class=\"button{{ not value|length ? ' hidden' : '' }}\" type=\"button\" data-action=\"sort\" data-action-sort=\"{{ field.sortby }}\" data-action-sort-dir=\"{{ field.sortby_dir|default('asc') }}\"
{% if field.disabled or isDisabledToggleable %}disabled=\"disabled\"{% endif %}><i class=\"fa fa-sort-amount-{{ field.sortby_dir|default('asc') }}\"></i> {{ btnSortLabel|e|tu }} '{{ field.sortby }}'</button>
{% endif %}
<button class=\"button\" type=\"button\" data-action=\"add\" data-action-add=\"bottom\"
{% if field.disabled or isDisabledToggleable %}disabled=\"disabled\"{% endif %}><i class=\"fa fa-plus\"></i> {{ btnLabel|e|tu }}</button>
</div>
{% endif %}
{%- set itemName = name ? name ~ '.*' : '*' -%}
<div style=\"display: none;\" data-collection-template=\"new\" data-collection-template-html=\"{%- filter replace({' ': ' ', '\\n': ' '})|e('html_attr') -%}
<li data-collection-item=\"{{ itemName }}\">
{% if field.sort is not same as(false) %}
<div class=\"collection-sort\"><i class=\"fa fa-fw fa-bars\"></i></div>
{% endif %}
{%- if field.fields -%}
{%- for childName, child in field.fields -%}
{%- if childName == 'value' -%}
{%- set childKey = '' -%}
{%- set childName = itemName -%}
{%- elseif childName starts with '.' -%}
{%- set childKey = childName|trim('.') -%}
{%- set childName = itemName ~ childName -%}
{%- else %}
{%- set childKey = childName -%}
{%- set childName = childName|replace({'*': key}) -%}
{%- endif %}
{%- set child = child|merge({ name: childName }) -%}
{%- if child.type == 'key' -%}
{%-
include 'forms/fields/key/key.html.twig'
with { field: child, value: null }
-%}
{%- elseif child.key == true -%}
{%-
include [
\"forms/fields/#{child.type}/#{child.type}.html.twig\",
'forms/fields/key/key.html.twig'
] with { field: child, value: null }
-%}
{%- elseif child.type -%}
{%-
include [
\"forms/fields/#{child.type}/#{child.type}.html.twig\",
'forms/fields/text/text.html.twig'
] with { field: child, value: null }
-%}
{%- endif -%}
{%- endfor %}
<div class=\"item-actions\">
{% if collapsible %}
<i class=\"fa fa-chevron-circle-down\" data-action=\"collapse\"></i>
<br />
{% endif %}
<i class=\"fa fa-trash-o\" data-action=\"delete\"></i>
</div>
{%- endif -%}
</li>
{%- endfilter -%}\"></div>
<div style=\"display: none;\" data-collection-config=\"{{ name }}\"></div>
</div>
</div>
{% endblock %}
", "forms/fields/list/list.html.twig", "/mnt/data/Sites/r2c.net/user/plugins/admin/themes/grav/templates/forms/fields/list/list.html.twig");
}
}