PluginProbe
Elementor Website Builder – more than just a page builder / 3.25.3
Elementor Website Builder – more than just a page builder v3.25.3
4.3.0-beta2 4.3.0-beta1 4.2.4 4.2.3 4.2.2 4.2.1 4.2.0 4.1.5 4.2.0-beta2 4.2.0-dev2 4.2.0-beta1 4.1.4 4.1.3 4.1.2 4.1.1 4.1.0 4.1.0-beta3 4.1.0-dev3 4.0.9 4.1.0-beta2 4.1.0-dev2 4.0.8 4.1.0-beta1 4.1.0-dev1 4.0.7 All 451 releases
elementor / core / kits / controls / repeater.php

repeater.php in Elementor Website Builder – more than just a page builder 3.25.3, at core/kits/controls/repeater.php

71 lines 1.6 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 namespace Elementor\Core\Kits\Controls;
3
4 use Elementor\Control_Repeater;
5
6 if ( ! defined( 'ABSPATH' ) ) {
7 exit; // Exit if accessed directly
8 }
9
10 class Repeater extends Control_Repeater {
11
12 const CONTROL_TYPE = 'global-style-repeater';
13
14 /**
15 * Get control type.
16 *
17 * Retrieve the control type, in this case `global-style-repeater`.
18 *
19 * @since 3.0.0
20 * @access public
21 *
22 * @return string Control type.
23 */
24 public function get_type() {
25 return self::CONTROL_TYPE;
26 }
27
28 /**
29 * Get repeater control default settings.
30 *
31 * Retrieve the default settings of the repeater control. Used to return the
32 * default settings while initializing the repeater control.
33 *
34 * @since 3.0.0
35 * @access protected
36 *
37 * @return array Control default settings.
38 */
39 protected function get_default_settings() {
40 $settings = parent::get_default_settings();
41
42 $settings['item_actions']['duplicate'] = false;
43
44 return $settings;
45 }
46
47 /**
48 * Render repeater control output in the editor.
49 *
50 * Used to generate the control HTML in the editor using Underscore JS
51 * template. The variables for the class are available using `data` JS
52 * object.
53 *
54 * @since 3.0.0
55 * @access public
56 */
57 public function content_template() {
58 ?>
59 <div class="elementor-repeater-fields-wrapper"></div>
60 <# if ( itemActions.add ) { #>
61 <div class="elementor-button-wrapper">
62 <button class="elementor-button elementor-repeater-add" type="button">
63 <i class="eicon-plus" aria-hidden="true"></i>
64 <span class="elementor-repeater__add-button__text">{{{ addButtonText }}}</span>
65 </button>
66 </div>
67 <# } #>
68 <?php
69 }
70 }
71