_t('AB_advanced_action_textsearch_label_label'), 'type' => "text", 'default' => _t('WHAT_YOU_SEARCH')." : ", ]; $data['action_groups']['advanced-actions']['actions']['newtextsearch']['properties']['size'] = [ 'label' => _t('AB_advanced_action_textsearch_size_label'), 'type' => "number", 'default' => "40", 'min' => '1', ]; $data['action_groups']['advanced-actions']['actions']['newtextsearch']['properties']['button'] = [ 'label' => _t('AB_advanced_action_textsearch_button_label'), 'type' => "text", 'default' => _t('SEARCH'), ]; $data['action_groups']['advanced-actions']['actions']['newtextsearch']['properties']['template'] = [ 'label' => _t('AB_advanced_action_newtextsearch_template_label'), 'type' => "list", 'default' => "newtextsearch-by-category.twig", 'options' => [ "newtextsearch.twig" => _t('AB_advanced_action_newtextsearch_template_standard'), "newtextsearch-by-category.twig" => _t('AB_advanced_action_newtextsearch_template_by_form'), ], ]; $data['action_groups']['advanced-actions']['actions']['newtextsearch']['properties']['viewtype'] = [ 'label' => _t('AB_advanced_action_newtextsearch_viewtype_label'), 'type' => "list", 'default' => "modal", 'options' => [ "modal" => _t('AB_advanced_action_newtextsearch_viewtype_modal'), "link" => _t('AB_advanced_action_newtextsearch_viewtype_link'), "newtab" => _t('AB_advanced_action_newtextsearch_viewtype_newtab'), ] ]; $params = $this->wiki->services->get(\Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface::class); $data['action_groups']['advanced-actions']['actions']['newtextsearch']['properties']['displayorder'] = [ 'btn-label-add' => _t('AB_advanced_action_newtextsearch_displayorder_label'), 'type' => "display-order", 'showif' => [ 'template' => "^$|^newtextsearch-by-category\.twig$", ], //'default' => "", 'subproperties' => [ 'type' => [ 'label' => _t('AB_advanced_action_newtextsearch_displayorder_type'), 'type' => 'list', 'options' => [ 'pages' => _t('AB_advanced_action_newtextsearch_displayorder_type_pages'), 'logpages' => _t('AB_advanced_action_newtextsearch_displayorder_type_logpages'), 'form' => _t('AB_advanced_action_newtextsearch_displayorder_type_form'), 'tag' => _t('AB_advanced_action_newtextsearch_displayorder_type_tag') ] ], 'value' => [ 'label' => _t('AB_advanced_action_newtextsearch_displayorder_value'), 'type' => "value-for-display-order", 'default' => "", ], 'title' => [ 'label' => _t('AB_advanced_action_newtextsearch_displayorder_title'), 'type' => "text", 'default' => "", ], ] ]; $data['action_groups']['advanced-actions']['actions']['newtextsearch']['properties']['phrase'] = [ 'label' => _t('AB_advanced_action_textsearch_phrase_label'), 'type' => "text", 'default' => "", 'advanced' => true, ]; $data['action_groups']['advanced-actions']['actions']['newtextsearch']['properties']['separator'] = [ 'label' => _t('AB_advanced_action_textsearch_separator_label'), 'type' => "text", 'default' => "", 'advanced' => true, ]; $data['action_groups']['advanced-actions']['actions']['newtextsearch']['properties']['displaytext'] = [ 'label' => _t('AB_advanced_action_newtextsearch_displaytext_label'), 'type' => "list", 'default' => "", 'advanced' => true, "options" => [ "" => _t('AB_advanced_action_newtextsearch_displaytext_only_std'), "true" => _t('YES'), "false" => _t('NO'), ] ]; $data['action_groups']['advanced-actions']['actions']['newtextsearch']['properties']['limit'] = [ 'label' => _t('AB_advanced_action_newtextsearch_limit_label'), 'type' => "number", 'default' => 10, 'advanced' => true, 'min' => 1, ]; $data['action_groups']['advanced-actions']['actions']['newtextsearch']['properties']['onlytags'] = [ 'label' => _t('AB_advanced_action_textsearch_onlytags_label'), 'hint' => _t('AB_advanced_action_textsearch_onlytags_hint'), 'type' => "text", 'default' => "", 'advanced' => true, ]; $data['action_groups']['advanced-actions']['actions']['newtextsearch']['properties']['nbcols'] = [ 'label' => _t('AB_advanced_action_textsearch_nbcols_label'), 'hint' => _t('AB_advanced_action_textsearch_nbcols_hint'), 'type' => "number", 'default' => 2, 'min' => 0, 'max' => 3, 'advanced' => true, 'showif' => [ 'template' => "^$|^newtextsearch-by-category\.twig$", ], ]; if (isset($data['action_groups']['advanced-actions']['actions']['newtextsearch']['properties']['phrase']) && isset($data['action_groups']['advanced-actions']['actions']['newtextsearch']['properties']['phrase']['label'])){ $data['action_groups']['advanced-actions']['actions']['newtextsearch']['properties']['phrase']['label'] = _t('AB_advanced_action_textsearch_phrase_label_forced'); $data['action_groups']['advanced-actions']['actions']['newtextsearch']['properties']['phrase']['hint'] = _t('AB_advanced_action_textsearch_phrase_hint'); } if (isset($data['action_groups']['advanced-actions']['actions']['newtextsearch']['properties']['separator'])){ $data['action_groups']['advanced-actions']['actions']['newtextsearch']['properties']['separator']['showif'] = [ 'template' => "^$|^newtextsearch\.twig$", ]; $data['action_groups']['advanced-actions']['actions']['newtextsearch']['properties']['separator']['hint'] = _t('AB_advanced_action_textsearch_separator_hint') ; } if (isset($data['action_groups']['advanced-actions']['actions']['newtextsearch']['properties']['size'])){ $data['action_groups']['advanced-actions']['actions']['newtextsearch']['properties']['size']['hint'] = _t('AB_advanced_action_textsearch_size_hint') ; $data['action_groups']['advanced-actions']['actions']['newtextsearch']['properties']['size']['advanced'] = true ; } } $paths = $this->twigLoader->getPaths("aceditor"); $curExtDirName = basename(dirname(dirname(dirname(__FILE__)))); $curDir = "tools/$curExtDirName/templates/aceditor"; // render next following custom actions-builder.tpl.html $curPos = array_search($curDir,$paths); if ($curPos !== false) { for ($i=($curPos+1); $i < count($paths); $i++) { if ($paths[$i] != $curDir && $this->hasTemplate("{$paths[$i]}/actions-builder.tpl.html")){ echo $this->render("{$paths[$i]}/actions-builder.tpl.html",compact(['data'])); break; } } }