PluginProbe
Elementor Website Builder – more than just a page builder / 3.21.3
Elementor Website Builder – more than just a page builder v3.21.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
← All changes | includes/elements/section.php +37 -103 4.2.43.21.3 View file →
@@ -91,12 +91,8 @@
91 91 public function get_icon() {
92 92 return 'eicon-columns';
93 93 }
94 94
95 - protected function is_dynamic_content(): bool {
96 - return false;
97 - }
98 -
99 95 /**
100 96 * Get presets.
101 97 *
102 98 * Retrieve a specific preset columns for a given columns count, or a list
@@ -232,9 +228,9 @@
232 228 'tab' => Controls_Manager::TAB_LAYOUT,
233 229 ]
234 230 );
235 231
236 - // Element Name for the Navigator.
232 + // Element Name for the Navigator
237 233 $this->add_control(
238 234 '_title',
239 235 [
240 236 'label' => esc_html__( 'Title', 'elementor' ),
@@ -436,9 +432,9 @@
436 432 ],
437 433 'selectors' => [
438 434 '{{WRAPPER}} > .elementor-container > .elementor-column > .elementor-widget-wrap' => 'align-content: {{VALUE}}; align-items: {{VALUE}};',
439 435 ],
440 - // TODO: The following line is for BC since 2.7.0.
436 + // TODO: The following line is for BC since 2.7.0
441 437 'prefix_class' => 'elementor-section-content-',
442 438 ]
443 439 );
444 440
@@ -503,9 +499,9 @@
503 499 );
504 500
505 501 $this->end_controls_section();
506 502
507 - // Section Structure.
503 + // Section Structure
508 504 $this->start_controls_section(
509 505 'section_structure',
510 506 [
511 507 'label' => esc_html__( 'Structure', 'elementor' ),
@@ -525,9 +521,9 @@
525 521 );
526 522
527 523 $this->end_controls_section();
528 524
529 - // Section background.
525 + // Section background
530 526 $this->start_controls_section(
531 527 'section_background',
532 528 [
533 529 'label' => esc_html__( 'Background', 'elementor' ),
@@ -556,45 +552,8 @@
556 552 ],
557 553 ]
558 554 );
559 555
560 - $this->add_control(
561 - 'handle_slideshow_asset_loading',
562 - [
563 - 'type' => Controls_Manager::HIDDEN,
564 - 'assets' => [
565 - 'styles' => [
566 - [
567 - 'name' => 'e-swiper',
568 - 'conditions' => [
569 - 'terms' => [
570 - [
571 - 'name' => 'background_background',
572 - 'operator' => '===',
573 - 'value' => 'slideshow',
574 - ],
575 - ],
576 - ],
577 - ],
578 - ],
579 - 'scripts' => [
580 - [
581 - 'name' => 'swiper',
582 - 'conditions' => [
583 - 'terms' => [
584 - [
585 - 'name' => 'background_background',
586 - 'operator' => '===',
587 - 'value' => 'slideshow',
588 - ],
589 - ],
590 - ],
591 - ],
592 - ],
593 - ],
594 - ]
595 - );
596 -
597 556 $this->end_controls_tab();
598 557
599 558 $this->start_controls_tab(
600 559 'tab_background_hover',
@@ -636,9 +595,9 @@
636 595 $this->end_controls_tabs();
637 596
638 597 $this->end_controls_section();
639 598
640 - // Background Overlay.
599 + // Background Overlay
641 600 $this->start_controls_section(
642 601 'section_background_overlay',
643 602 [
644 603 'label' => esc_html__( 'Background Overlay', 'elementor' ),
@@ -823,9 +782,9 @@
823 782 $this->end_controls_tabs();
824 783
825 784 $this->end_controls_section();
826 785
827 - // Section border.
786 + // Section border
828 787 $this->start_controls_section(
829 788 'section_border',
830 789 [
831 790 'label' => esc_html__( 'Border', 'elementor' ),
@@ -929,9 +888,9 @@
929 888 'operator' => '!==',
930 889 'value' => '',
931 890 ],
932 891 [
933 - 'name' => 'border_hover_border',
892 + 'name' => 'border_border',
934 893 'operator' => '!==',
935 894 'value' => '',
936 895 ],
937 896 ],
@@ -948,9 +907,9 @@
948 907 $this->end_controls_tabs();
949 908
950 909 $this->end_controls_section();
951 910
952 - // Section Shape Divider.
911 + // Section Shape Divider
953 912 $this->start_controls_section(
954 913 'section_shape_divider',
955 914 [
956 915 'label' => esc_html__( 'Shape Divider', 'elementor' ),
@@ -959,8 +918,16 @@
959 918 );
960 919
961 920 $this->start_controls_tabs( 'tabs_shape_dividers' );
962 921
922 + $shapes_options = [
923 + '' => esc_html__( 'None', 'elementor' ),
924 + ];
925 +
926 + foreach ( Shapes::get_shapes() as $shape_name => $shape_props ) {
927 + $shapes_options[ $shape_name ] = $shape_props['title'];
928 + }
929 +
963 930 foreach ( [
964 931 'top' => esc_html__( 'Top', 'elementor' ),
965 932 'bottom' => esc_html__( 'Bottom', 'elementor' ),
966 933 ] as $side => $side_label ) {
@@ -976,30 +943,12 @@
976 943 $this->add_control(
977 944 $base_control_key,
978 945 [
979 946 'label' => esc_html__( 'Type', 'elementor' ),
980 - 'type' => Controls_Manager::VISUAL_CHOICE,
981 - 'label_block' => true,
982 - 'columns' => 2,
983 - 'options' => Shapes::get_shapes(),
947 + 'type' => Controls_Manager::SELECT,
948 + 'options' => $shapes_options,
984 949 'render_type' => 'none',
985 950 'frontend_available' => true,
986 - 'assets' => [
987 - 'styles' => [
988 - [
989 - 'name' => 'e-shapes',
990 - 'conditions' => [
991 - 'terms' => [
992 - [
993 - 'name' => $base_control_key,
994 - 'operator' => '!==',
995 - 'value' => '',
996 - ],
997 - ],
998 - ],
999 - ],
1000 - ],
1001 - ],
1002 951 ]
1003 952 );
1004 953
1005 954 $this->add_control(
@@ -1123,9 +1072,9 @@
1123 1072 $this->end_controls_tabs();
1124 1073
1125 1074 $this->end_controls_section();
1126 1075
1127 - // Section Typography.
1076 + // Section Typography
1128 1077 $this->start_controls_section(
1129 1078 'section_typo',
1130 1079 [
1131 1080 'label' => esc_html__( 'Typography', 'elementor' ),
@@ -1186,10 +1135,10 @@
1186 1135 [
1187 1136 'label' => esc_html__( 'Text Align', 'elementor' ),
1188 1137 'type' => Controls_Manager::CHOOSE,
1189 1138 'options' => [
1190 - 'start' => [
1191 - 'title' => esc_html__( 'Start', 'elementor' ),
1139 + 'left' => [
1140 + 'title' => esc_html__( 'Left', 'elementor' ),
1192 1141 'icon' => 'eicon-text-align-left',
1193 1142 ],
1194 1143 'center' => [
1195 1144 'title' => esc_html__( 'Center', 'elementor' ),
@@ -1194,10 +1143,10 @@
1194 1143 'center' => [
1195 1144 'title' => esc_html__( 'Center', 'elementor' ),
1196 1145 'icon' => 'eicon-text-align-center',
1197 1146 ],
1198 - 'end' => [
1199 - 'title' => esc_html__( 'End', 'elementor' ),
1147 + 'right' => [
1148 + 'title' => esc_html__( 'Right', 'elementor' ),
1200 1149 'icon' => 'eicon-text-align-right',
1201 1150 ],
1202 1151 'justify' => [
1203 1152 'title' => esc_html__( 'Justified', 'elementor' ),
@@ -1203,13 +1152,8 @@
1203 1152 'title' => esc_html__( 'Justified', 'elementor' ),
1204 1153 'icon' => 'eicon-text-align-justify',
1205 1154 ],
1206 1155 ],
1207 - 'classes' => 'elementor-control-start-end',
1208 - 'selectors_dictionary' => [
1209 - 'left' => is_rtl() ? 'end' : 'start',
1210 - 'right' => is_rtl() ? 'start' : 'end',
1211 - ],
1212 1156 'selectors' => [
1213 1157 '{{WRAPPER}} > .elementor-container' => 'text-align: {{VALUE}};',
1214 1158 ],
1215 1159 ]
@@ -1216,9 +1160,9 @@
1216 1160 );
1217 1161
1218 1162 $this->end_controls_section();
1219 1163
1220 - // Section Advanced.
1164 + // Section Advanced
1221 1165 $this->start_controls_section(
1222 1166 'section_advanced',
1223 1167 [
1224 1168 'label' => esc_html__( 'Advanced', 'elementor' ),
@@ -1363,9 +1307,9 @@
1363 1307 );
1364 1308
1365 1309 $this->end_controls_section();
1366 1310
1367 - // Section Responsive.
1311 + // Section Responsive
1368 1312 $this->start_controls_section(
1369 1313 '_section_responsive',
1370 1314 [
1371 1315 'label' => esc_html__( 'Responsive', 'elementor' ),
@@ -1438,14 +1382,9 @@
1438 1382 if ( ! settings.background_play_once ) {
1439 1383 videoAttributes += ' loop';
1440 1384 }
1441 1385
1442 - view.addRenderAttribute(
1443 - 'background-video-container',
1444 - {
1445 - 'class': 'elementor-background-video-container',
1446 - }
1447 - );
1386 + view.addRenderAttribute( 'background-video-container', 'class', 'elementor-background-video-container' );
1448 1387
1449 1388 if ( ! settings.background_play_on_mobile ) {
1450 1389 view.addRenderAttribute( 'background-video-container', 'class', 'elementor-hidden-mobile' );
1451 1390 }
@@ -1450,15 +1389,15 @@
1450 1389 view.addRenderAttribute( 'background-video-container', 'class', 'elementor-hidden-mobile' );
1451 1390 }
1452 1391 #>
1453 1392 <div {{{ view.getRenderAttributeString( 'background-video-container' ) }}}>
1454 - <div class="elementor-background-video-embed" role="presentation"></div>
1455 - <video class="elementor-background-video-hosted" role="presentation" {{ videoAttributes }}></video>
1393 + <div class="elementor-background-video-embed"></div>
1394 + <video class="elementor-background-video-hosted elementor-html5-video" {{ videoAttributes }}></video>
1456 1395 </div>
1457 1396 <# } #>
1458 1397 <div class="elementor-background-overlay"></div>
1459 - <div class="elementor-shape elementor-shape-top" aria-hidden="true"></div>
1460 - <div class="elementor-shape elementor-shape-bottom" aria-hidden="true"></div>
1398 + <div class="elementor-shape elementor-shape-top"></div>
1399 + <div class="elementor-shape elementor-shape-bottom"></div>
1461 1400 <div class="elementor-container elementor-column-gap-{{ settings.gap }}"></div>
1462 1401 <?php
1463 1402 }
1464 1403
@@ -1479,24 +1418,19 @@
1479 1418 ?> <?php $this->print_render_attribute_string( '_wrapper' ); ?>>
1480 1419 <?php
1481 1420 if ( 'video' === $settings['background_background'] ) :
1482 1421 if ( $settings['background_video_link'] ) :
1483 - $is_embed_video = Embed::is_embed_video( $settings['background_video_link'] );
1422 + $video_properties = Embed::get_video_properties( $settings['background_video_link'] );
1484 1423
1485 - $this->add_render_attribute(
1486 - 'background-video-container',
1487 - [
1488 - 'class' => 'elementor-background-video-container',
1489 - ]
1490 - );
1424 + $this->add_render_attribute( 'background-video-container', 'class', 'elementor-background-video-container' );
1491 1425
1492 1426 if ( ! $settings['background_play_on_mobile'] ) {
1493 - $this->add_render_attribute( 'background-video-container', 'class', 'elementor-hidden-mobile' );
1427 + $this->add_render_attribute( 'background-video-container', 'class', 'elementor-hidden-phone' );
1494 1428 }
1495 1429 ?>
1496 1430 <div <?php $this->print_render_attribute_string( 'background-video-container' ); ?>>
1497 - <?php if ( $is_embed_video ) : ?>
1498 - <div class="elementor-background-video-embed" role="presentation"></div>
1431 + <?php if ( $video_properties ) : ?>
1432 + <div class="elementor-background-video-embed"></div>
1499 1433 <?php
1500 1434 else :
1501 1435 $video_tag_attributes = 'autoplay muted playsinline';
1502 1436 if ( 'yes' !== $settings['background_play_once'] ) :
@@ -1502,9 +1436,9 @@
1502 1436 if ( 'yes' !== $settings['background_play_once'] ) :
1503 1437 $video_tag_attributes .= ' loop';
1504 1438 endif;
1505 1439 ?>
1506 - <video class="elementor-background-video-hosted" role="presentation" <?php
1440 + <video class="elementor-background-video-hosted elementor-html5-video" <?php
1507 1441 // PHPCS - the variable $video_tag_attributes is a plain string.
1508 1442 echo $video_tag_attributes; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
1509 1443 ?>></video>
1510 1444 <?php endif; ?>
@@ -1632,9 +1566,9 @@
1632 1566 return;
1633 1567 }
1634 1568
1635 1569 ?>
1636 - <div class="elementor-shape elementor-shape-<?php echo esc_attr( $side ); ?>" aria-hidden="true" data-negative="<?php
1570 + <div class="elementor-shape elementor-shape-<?php echo esc_attr( $side ); ?>" data-negative="<?php
1637 1571 Utils::print_unescaped_internal_string( $negative ? 'true' : 'false' );
1638 1572 ?>">
1639 1573 <?php
1640 1574 // PHPCS - The file content is being read from a strict file path structure.