PluginProbe
Elementor Website Builder – more than just a page builder / 4.3.0-beta3
Elementor Website Builder – more than just a page builder v4.3.0-beta3
4.3.0-beta3 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 All 452 releases
← All changes | modules/atomic-widgets/elements/grid/grid.php +9 -2 4.2.14.3.0-beta3 View file →
@@ -3,8 +3,9 @@
3 3
4 4 use Elementor\Core\Breakpoints\Manager as Breakpoints_Manager;
5 5 use Elementor\Modules\AtomicWidgets\Elements\Base\Atomic_Element_Base;
6 6 use Elementor\Modules\AtomicWidgets\Elements\Base\Has_Element_Template;
7 +use Elementor\Modules\AtomicWidgets\Elements\Base\Html_Tag_Computer;
7 8 use Elementor\Modules\AtomicWidgets\PropDependencies\Manager as Dependency_Manager;
8 9 use Elementor\Modules\AtomicWidgets\PropTypes\Grid_Track_Size_Prop_Type;
9 10 use Elementor\Modules\AtomicWidgets\PropTypes\Layout_Direction_Prop_Type;
10 11 use Elementor\Modules\AtomicWidgets\PropTypes\Primitives\Boolean_Prop_Type;
@@ -29,8 +30,10 @@
29 30 use Has_Element_Template;
30 31
31 32 const BASE_STYLE_KEY = 'base';
32 33
34 + public static $widget_description = 'CSS grid layout. Always set grid-template-rows to match the actual number of rows the children fill. Empty fr row tracks do not collapse and render as an equal-height empty band below the content.';
35 +
33 36 public function __construct( $data = [], $args = null ) {
34 37 parent::__construct( $data, $args );
35 38 $this->meta( 'is_container', true );
36 39 }
@@ -47,9 +50,9 @@
47 50 return esc_html__( 'Grid', 'elementor' );
48 51 }
49 52
50 53 public function get_keywords() {
51 - return [ 'ato', 'atom', 'atoms', 'atomic', 'grid', 'layout' ];
54 + return [ 'ato', 'atom', 'atoms', 'atomic', 'container', 'wrapper', 'section', 'row', 'column', 'grid', 'columns', 'gallery', 'layout' ];
52 55 }
53 56
54 57 public function get_icon() {
55 58 return 'eicon-library-grid';
@@ -54,8 +57,12 @@
54 57 public function get_icon() {
55 58 return 'eicon-library-grid';
56 59 }
57 60
61 + public static function get_computed_html_tag( array $settings ): string {
62 + return Html_Tag_Computer::compute( $settings, 'div' );
63 + }
64 +
58 65 protected static function define_props_schema(): array {
59 66 $tag_dependencies = Dependency_Manager::make( Dependency_Manager::RELATION_AND )
60 67 ->where( [
61 68 'operator' => 'ne',
@@ -80,9 +87,9 @@
80 87 ->default( [] ),
81 88 'tag' => String_Prop_Type::make()
82 89 ->enum( [ 'div', 'header', 'section', 'article', 'aside', 'footer', 'a', 'button' ] )
83 90 ->default( 'div' )
84 - ->description( 'The HTML tag for the grid container. Could be div, header, section, article, aside, footer, or a (link).' )
91 + ->description( 'The HTML tag for the grid container. One of: div, header, section, article, aside, footer, a (link), or button.' )
85 92 ->set_dependencies( $tag_dependencies ),
86 93 'link' => Link_Prop_Type::make(),
87 94 'attributes' => Attributes_Prop_Type::make()->meta( Overridable_Prop_Type::ignore() ),
88 95 ];