PluginProbe
WP Directory Kit / 1.5.9
WP Directory Kit v1.5.9
1.5.9 1.5.7 1.5.6 1.5.5 1.5.4 1.5.3 trunk 1.1.0 1.1.6 1.1.8 1.2.3 1.2.4 1.2.5 1.2.6 1.2.7 1.2.8 1.2.9 1.3.0 1.3.1 1.3.2 1.3.3 1.3.4 1.3.5 1.3.6 1.3.8 All 37 releases
← All changes | elementor-elements/classes/wdk-locations-tree.php +28 -22 1.3.4 → 1.5.9 View file →
@@ -29,8 +29,9 @@
29 29 \Elementor\Controls_Manager::add_tab(
30 30 'tab_conf',
31 31 esc_html__('Settings', 'wpdirectorykit')
32 32 );
33 +
33 34
34 35 \Elementor\Controls_Manager::add_tab(
35 36 'tab_layout',
36 37 esc_html__('Layout', 'wpdirectorykit')
@@ -133,9 +134,9 @@
133 134 $this->data['is_edit_mode']= false;
134 135 if(Plugin::$instance->editor->is_edit_mode())
135 136 $this->data['is_edit_mode']= true;
136 137
137 - echo $this->view('wdk-locations-tree', $this->data);
138 + $this->view('wdk-locations-tree', $this->data, true);
138 139 }
139 140
140 141
141 142 private function generate_controls_conf() {
@@ -215,8 +216,9 @@
215 216 'important_note',
216 217 [
217 218 'label' => '',
218 219 'type' => \Elementor\Controls_Manager::RAW_HTML,
220 + /* translators: 1: URL. */
219 221 'raw' => wdk_sprintf(__( 'Manage Locations <a href="%1$s" target="_blank"> open </a>', 'wpdirectorykit' ), admin_url('admin.php?page=wdk_location')),
220 222 'content_classes' => 'wdk_elementor_hint',
221 223 ]
222 224 );
@@ -338,13 +340,27 @@
338 340 'key'=>'title',
339 341 'label'=> esc_html__('Title', 'wpdirectorykit'),
340 342 'selector'=>'.title',
341 343 'selector_hover'=>'.title%1$s',
342 - 'options'=>['color','background','border','border_radius','padding','shadow','transition','margin','padding'],
344 + 'options'=>['typo','color','background','border','border_radius','padding','shadow','transition','margin','padding'],
343 345 ],
344 346 [
347 + 'key'=>'location_image',
348 + 'label'=> esc_html__('Location Image', 'wpdirectorykit'),
349 + 'selector'=>'.title .wdk-image',
350 + 'selector_hover'=>'.title%1$s .wdk-image',
351 + 'options'=>['margin','background','border','border_radius','padding','shadow','transition','image_size_control', 'css_filters','image_fit_control'],
352 + ],
353 + [
354 + 'key'=>'location_icon',
355 + 'label'=> esc_html__('Location Icon', 'wpdirectorykit'),
356 + 'selector'=>'.title .wdk-icon',
357 + 'selector_hover'=>'.title%1$s .wdk-icon',
358 + 'options'=>['margin','color','background','border','border_radius','padding','shadow','image_size_control','image_fit_control'],
359 + ],
360 + [
345 361 'key'=>'item_button',
346 - 'label'=> esc_html__('Item Box', 'wpdirectorykit'),
362 + 'label'=> esc_html__('Sub Location List Item', 'wpdirectorykit'),
347 363 'selector'=>'.wdk-locations .wdk-link',
348 364 'selector_hover'=>'.wdk-locations .wdk-link%1$s',
349 365 'options'=>['color','background','border','border_radius','padding','shadow','transition'],
350 366 ],
@@ -349,30 +365,16 @@
349 365 'options'=>['color','background','border','border_radius','padding','shadow','transition'],
350 366 ],
351 367 [
352 368 'key'=>'item_icon',
353 - 'label'=> esc_html__('Item Icon', 'wpdirectorykit'),
369 + 'label'=> esc_html__('Sub Location List item Icon', 'wpdirectorykit'),
354 370 'selector'=>'.wdk-locations .wdk-link i',
355 371 'selector_hover'=>'.wdk-locations .wdk-link%1$s i',
356 372 'options'=>['margin','color','background','border','border_radius','padding','shadow'],
357 373 ],
358 374 [
359 - 'key'=>'location_icon',
360 - 'label'=> esc_html__('Location Icon', 'wpdirectorykit'),
361 - 'selector'=>'.title .wdk-icon',
362 - 'selector_hover'=>'.title%1$s .wdk-icon',
363 - 'options'=>['margin','color','background','border','border_radius','padding','shadow','image_size_control','image_fit_control'],
364 - ],
365 - [
366 - 'key'=>'location_image',
367 - 'label'=> esc_html__('Location Image', 'wpdirectorykit'),
368 - 'selector'=>'.title .wdk-image',
369 - 'selector_hover'=>'.title%1$s .wdk-image',
370 - 'options'=>['margin','background','border','border_radius','padding','shadow','transition','image_size_control', 'css_filters','image_fit_control'],
371 - ],
372 - [
373 375 'key'=>'item_title',
374 - 'label'=> esc_html__('Item Title', 'wpdirectorykit'),
376 + 'label'=> esc_html__('Sub Location List Item Title', 'wpdirectorykit'),
375 377 'selector'=>'.wdk-locations .wdk-link .wdk-title',
376 378 'selector_hover'=>'.wdk-locations .wdk-link%1$s .wdk-title',
377 379 'options'=>['margin','typo','color','background','border','border_radius','padding'],
378 380 ],
@@ -377,9 +379,9 @@
377 379 'options'=>['margin','typo','color','background','border','border_radius','padding'],
378 380 ],
379 381 [
380 382 'key'=>'item_count',
381 - 'label'=> esc_html__('Item Count', 'wpdirectorykit'),
383 + 'label'=> esc_html__('Sub Location List Item Count', 'wpdirectorykit'),
382 384 'selector'=>'.wdk-locations .wdk-link .wdk-count',
383 385 'selector_hover'=>'.wdk-locations .wdk-link%1$s .wdk-count',
384 386 'options'=>['margin','typo','color','background','border','border_radius','padding'],
385 387 ],
@@ -439,8 +441,12 @@
439 441 ]
440 442 );
441 443 }
442 444
445 + if(empty($item['selector_hide'])) {
446 + $item['selector_hide'] = $item['selector'];
447 + }
448 +
443 449 $this->add_responsive_control(
444 450 $item['key'].'_hide',
445 451 [
446 452 'label' => esc_html__( 'Hide Element', 'wpdirectorykit' ),
@@ -449,9 +455,9 @@
449 455 'block' => esc_html__( 'Show', 'wpdirectorykit' ),
450 456 'return_value' => 'none',
451 457 'default' => '',
452 458 'selectors' => [
453 - '{{WRAPPER}} '.$item['selector'] => 'display: {{VALUE}};',
459 + '{{WRAPPER}} '.$item['selector_hide'] => 'display: {{VALUE}};',
454 460 ],
455 461 ]
456 462 );
457 463 $selectors = array(
@@ -478,9 +484,9 @@
478 484 $item['key'].'_size',
479 485 [
480 486 'label' => __( 'Size', 'wpdirectorykit' ),
481 487 'type' => Controls_Manager::SLIDER,
482 - 'size_units' => [ 'px'],
488 + 'size_units' => [ 'px','em', 'vw', '%', 'custom' ],
483 489 'range' => [
484 490 'px' => [
485 491 'min' => 1,
486 492 'max' => 60,