PluginProbe
Elementor Website Builder – more than just a page builder / 3.22.2
Elementor Website Builder – more than just a page builder v3.22.2
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/managers/controls.php +29 -41 4.1.43.22.2 View file →
@@ -158,13 +158,8 @@
158 158 */
159 159 const CHOOSE = 'choose';
160 160
161 161 /**
162 - * Visual_Choice control.
163 - */
164 - const VISUAL_CHOICE = 'visual_choice';
165 -
166 - /**
167 162 * WYSIWYG control.
168 163 */
169 164 const WYSIWYG = 'wysiwyg';
170 165
@@ -425,9 +420,8 @@
425 420 self::MEDIA,
426 421 self::SLIDER,
427 422 self::DIMENSIONS,
428 423 self::CHOOSE,
429 - self::VISUAL_CHOICE,
430 424 self::WYSIWYG,
431 425 self::CODE,
432 426 self::FONT,
433 427 self::IMAGE_DIMENSIONS,
@@ -494,14 +488,14 @@
494 488 *
495 489 * @param Controls_Manager $this The controls manager.
496 490 */
497 491 // TODO: Uncomment when Pro uses the new hook.
498 - // Plugin::$instance->modules_manager->get_modules( 'dev-tools' )->deprecation->do_deprecated_action(
499 - // 'elementor/controls/controls_registered',
500 - // [ $this ],
501 - // '3.5.0',
502 - // 'elementor/controls/register'
503 - // );
492 + //Plugin::$instance->modules_manager->get_modules( 'dev-tools' )->deprecation->do_deprecated_action(
493 + // 'elementor/controls/controls_registered',
494 + // [ $this ],
495 + // '3.5.0',
496 + // 'elementor/controls/register'
497 + //);
504 498
505 499 do_action( 'elementor/controls/controls_registered', $this );
506 500
507 501 /**
@@ -531,13 +525,13 @@
531 525 * current instance.
532 526 */
533 527 public function register_control( $control_id, Base_Control $control_instance ) {
534 528 // TODO: Uncomment when Pro uses the new hook.
535 - // Plugin::$instance->modules_manager->get_modules( 'dev-tools' )->deprecation->deprecated_function(
536 - // __METHOD__,
537 - // '3.5.0',
538 - // 'register()'
539 - // );
529 + //Plugin::$instance->modules_manager->get_modules( 'dev-tools' )->deprecation->deprecated_function(
530 + // __METHOD__,
531 + // '3.5.0',
532 + // 'register()'
533 + //);
540 534
541 535 $this->register( $control_instance, $control_id );
542 536 }
543 537
@@ -807,9 +801,13 @@
807 801 'index' => null,
808 802 ];
809 803
810 804 $control_type = 'controls';
811 - if ( Performance::should_optimize_controls() && $this->is_style_control( $control_data ) ) {
805 + if (
806 + Performance::is_optimized_control_loading_feature_enabled()
807 + && Performance::should_optimize_controls()
808 + && $this->is_style_control( $control_data )
809 + ) {
812 810 $control_type = 'style_controls';
813 811 }
814 812
815 813 $options = array_merge( $default_options, $options );
@@ -829,17 +827,8 @@
829 827 _doing_it_wrong( sprintf( '%1$s::%2$s', __CLASS__, __FUNCTION__ ), sprintf( 'Control type "%s" not found.', esc_html( $control_data['type'] ) ), '1.0.0' );
830 828 return false;
831 829 }
832 830
833 - if ( $control_type_instance instanceof Has_Validation ) {
834 - try {
835 - $control_type_instance->validate( $control_data );
836 - } catch ( \Exception $e ) {
837 - _doing_it_wrong( sprintf( '%1$s::%2$s', __CLASS__, __FUNCTION__ ), esc_html( $e->getMessage() ), '3.23.0' );
838 - return false;
839 - }
840 - }
841 -
842 831 if ( $control_type_instance instanceof Base_Data_Control ) {
843 832 $control_default_value = $control_type_instance->get_default_value();
844 833
845 834 if ( is_array( $control_default_value ) ) {
@@ -887,9 +876,9 @@
887 876 *
888 877 * @since 1.0.0
889 878 * @access public
890 879 *
891 - * @param string $stack_id Stack ID.
880 + * @param string $stack_id Stack ID.
892 881 * @param array|string $control_id The ID of the control to remove.
893 882 *
894 883 * @return bool|\WP_Error True if the stack was removed, False otherwise.
895 884 */
@@ -912,9 +901,8 @@
912 901 }
913 902
914 903 /**
915 904 * Has Stacks Cache Been Cleared.
916 - *
917 905 * @since 3.13.0
918 906 * @access public
919 907 * @return bool True if the CSS requires to clear the controls stack cache, False otherwise.
920 908 */
@@ -924,9 +912,8 @@
924 912
925 913 /**
926 914 * Clear stack.
927 915 * This method clears the stack.
928 - *
929 916 * @since 3.13.0
930 917 * @access public
931 918 */
932 919 public function clear_stack_cache() {
@@ -1064,10 +1051,11 @@
1064 1051 * @since 1.0.0
1065 1052 * @access public
1066 1053 *
1067 1054 * @param Controls_Stack $controls_stack .
1068 - * @param string $tab
1069 - * @param array $additional_messages
1055 + * @param string $tab
1056 + * @param array $additional_messages
1057 + *
1070 1058 */
1071 1059 public function add_custom_css_controls( Controls_Stack $controls_stack, $tab = self::TAB_ADVANCED, $additional_messages = [] ) {
1072 1060 $controls_stack->start_controls_section(
1073 1061 'section_custom_css_pro',
@@ -1107,10 +1095,10 @@
1107 1095 * version of elementor uses this method to display an upgrade message to
1108 1096 * Elementor Pro.
1109 1097 *
1110 1098 * @param Controls_Stack $controls_stack .
1111 - * @param string $tab
1112 - * @param array $additional_messages
1099 + * @param string $tab
1100 + * @param array $additional_messages
1113 1101 *
1114 1102 * @return void
1115 1103 */
1116 1104 public function add_page_transitions_controls( Controls_Stack $controls_stack, $tab = self::TAB_ADVANCED, $additional_messages = [] ) {
@@ -1191,12 +1179,12 @@
1191 1179 * This method adds a new control for the "Custom Attributes" feature. The free
1192 1180 * version of elementor uses this method to display an upgrade message to
1193 1181 * Elementor Pro.
1194 1182 *
1195 - * @param Controls_Stack $controls_stack .
1196 - * @param string $tab
1197 1183 * @since 2.8.3
1198 1184 * @access public
1185 + *
1186 + * @param Controls_Stack $controls_stack.
1199 1187 */
1200 1188 public function add_custom_attributes_controls( Controls_Stack $controls_stack, string $tab = self::TAB_ADVANCED ) {
1201 1189 $controls_stack->start_controls_section(
1202 1190 'section_custom_attributes_pro',
@@ -1225,9 +1213,9 @@
1225 1213
1226 1214 /**
1227 1215 * Check if a stack should be cleaned by the current responsive control duplication mode.
1228 1216 *
1229 - * @param array $stack
1217 + * @param $stack
1230 1218 * @return bool
1231 1219 */
1232 1220 private function should_clean_stack( $stack ): bool {
1233 1221 if ( ! isset( $stack['responsive_control_duplication_mode'] ) ) {
@@ -1269,9 +1257,9 @@
1269 1257 <span class="e-control-display-conditions-promotion__text">
1270 1258 <?php echo esc_html__( 'Display Conditions', 'elementor' ); ?>
1271 1259 </span>
1272 1260 <span class="e-control-display-conditions-promotion__lock-wrapper">
1273 - <i class="eicon-upgrade-crown-full e-control-display-conditions-promotion"></i>
1261 + <i class="eicon-lock e-control-display-conditions-promotion"></i>
1274 1262 </span>
1275 1263 </div>
1276 1264 <i class="eicon-flow e-control-display-conditions-promotion"></i>
1277 1265 </div>
@@ -1335,9 +1323,9 @@
1335 1323 <label>
1336 1324 ' . $title . '
1337 1325 </label>
1338 1326 <span class="e-control-motion-effects-promotion__lock-wrapper">
1339 - <i class="eicon-upgrade-crown-full"></i>
1327 + <i class="eicon-lock"></i>
1340 1328 </span>
1341 1329 <div class="elementor-control-input-wrapper">
1342 1330 <label class="elementor-switch elementor-control-unit-2 e-control-' . $id . '-promotion">
1343 1331 <input type="checkbox" class="elementor-switch-input" disabled>
@@ -1357,12 +1345,12 @@
1357 1345 <label for="sticky-motion-effect-pro">
1358 1346 ' . $title . '
1359 1347 </label>
1360 1348 <span class="e-control-motion-effects-promotion__lock-wrapper">
1361 - <i class="eicon-upgrade-crown-full"></i>
1349 + <i class="eicon-lock"></i>
1362 1350 </span>
1363 1351 <div class="elementor-control-input-wrapper elementor-control-unit-5 e-control-' . $id . '-promotion">
1364 - <div class="select-promotion elementor-control-unit-5">' . esc_html__( 'None', 'elementor' ) . '</div>
1352 + <div class="select-promotion elementor-control-unit-5">None</div>
1365 1353 </div>
1366 1354 </div>
1367 1355 </div>
1368 1356 </div>';