pricing.php
2696 lines
| 1 | <?php |
| 2 | namespace Elementor; |
| 3 | |
| 4 | use \Elementor\ElementsKit_Widget_Pricing_Handler as Handler; |
| 5 | use \ElementsKit_Lite\Modules\Controls\Controls_Manager as ElementsKit_Controls_Manager; |
| 6 | |
| 7 | if (! defined( 'ABSPATH' ) ) exit; |
| 8 | |
| 9 | class ElementsKit_Widget_Pricing extends Widget_Base { |
| 10 | use \ElementsKit_Lite\Widgets\Widget_Notice; |
| 11 | |
| 12 | public $base; |
| 13 | |
| 14 | public function get_script_depends() { |
| 15 | return ['ekit-info-tip']; |
| 16 | } |
| 17 | |
| 18 | public function get_style_depends() { |
| 19 | return ['ekit-pricing']; |
| 20 | } |
| 21 | |
| 22 | public function get_name() { |
| 23 | return Handler::get_name(); |
| 24 | } |
| 25 | |
| 26 | public function get_title() { |
| 27 | return Handler::get_title(); |
| 28 | } |
| 29 | |
| 30 | public function get_icon() { |
| 31 | return Handler::get_icon(); |
| 32 | } |
| 33 | |
| 34 | public function get_categories() { |
| 35 | return Handler::get_categories(); |
| 36 | } |
| 37 | |
| 38 | public function get_keywords() { |
| 39 | return Handler::get_keywords(); |
| 40 | } |
| 41 | |
| 42 | public function get_help_url() { |
| 43 | return 'https://wpmet.com/doc/pricing-table/'; |
| 44 | } |
| 45 | protected function is_dynamic_content(): bool { |
| 46 | return false; |
| 47 | } |
| 48 | |
| 49 | protected function register_controls() { |
| 50 | |
| 51 | $this->start_controls_section( |
| 52 | 'ekit_pricing_pricing_plan', |
| 53 | [ |
| 54 | 'label' => esc_html__('Header', 'elementskit-lite'), |
| 55 | ] |
| 56 | ); |
| 57 | |
| 58 | |
| 59 | $this->add_control( |
| 60 | 'ekit_pricing_table_title', [ |
| 61 | 'type' => Controls_Manager::TEXT, |
| 62 | 'dynamic' => [ |
| 63 | 'active' => true, |
| 64 | ], |
| 65 | 'label' => esc_html__('Table Title', 'elementskit-lite'), |
| 66 | 'default' => esc_html__('Starter','elementskit-lite'), |
| 67 | 'label_block' => true, |
| 68 | ] |
| 69 | ); |
| 70 | $this->add_control( |
| 71 | 'ekit_pricing_title_size', |
| 72 | [ |
| 73 | 'label' => esc_html__( 'Title HTML Tag', 'elementskit-lite' ), |
| 74 | 'type' => Controls_Manager::SELECT, |
| 75 | 'options' => [ |
| 76 | 'h1' => 'H1', |
| 77 | 'h2' => 'H2', |
| 78 | 'h3' => 'H3', |
| 79 | 'h4' => 'H4', |
| 80 | 'h5' => 'H5', |
| 81 | 'h6' => 'H6', |
| 82 | 'div' => 'div', |
| 83 | 'span' => 'span', |
| 84 | 'p' => 'p', |
| 85 | ], |
| 86 | 'default' => 'h3', |
| 87 | 'separator' => 'after', |
| 88 | ] |
| 89 | ); |
| 90 | $this->add_control( |
| 91 | 'ekit_pricing_table_subtitle', [ |
| 92 | 'type' => Controls_Manager::TEXT, |
| 93 | 'dynamic' => [ |
| 94 | 'active' => true, |
| 95 | ], |
| 96 | 'label' => esc_html__('Table Subtitle', 'elementskit-lite'), |
| 97 | 'default' => esc_html__('A small river named Duden flows by their place and supplies','elementskit-lite'), |
| 98 | 'label_block' => true, |
| 99 | ] |
| 100 | ); |
| 101 | $this->add_control( |
| 102 | 'ekit_pricing_icon_type', |
| 103 | [ |
| 104 | 'label' => esc_html__( 'Header Icon or Image? ', 'elementskit-lite' ), |
| 105 | 'type' => Controls_Manager::CHOOSE, |
| 106 | 'options' => [ |
| 107 | 'none' => [ |
| 108 | 'title' => esc_html__( 'None', 'elementskit-lite' ), |
| 109 | 'icon' => 'fa fa-stop-circle', |
| 110 | ], |
| 111 | 'icon' => [ |
| 112 | 'title' => esc_html__( 'Icon', 'elementskit-lite' ), |
| 113 | 'icon' => 'fa fa-star', |
| 114 | ], |
| 115 | 'image' => [ |
| 116 | 'title' => esc_html__( 'Image', 'elementskit-lite' ), |
| 117 | 'icon' => 'fa fa-image', |
| 118 | ], |
| 119 | ], |
| 120 | 'default' => 'none', |
| 121 | 'separator' => 'before', |
| 122 | 'toggle' => true, |
| 123 | ] |
| 124 | ); |
| 125 | |
| 126 | $this->add_control( |
| 127 | 'ekit_pricing_icons__switch', |
| 128 | [ |
| 129 | 'label' => esc_html__('Add icon? ', 'elementskit-lite'), |
| 130 | 'type' => Controls_Manager::SWITCHER, |
| 131 | 'default' => 'yes', |
| 132 | 'label_on' =>esc_html__( 'Yes', 'elementskit-lite' ), |
| 133 | 'label_off' =>esc_html__( 'No', 'elementskit-lite' ), |
| 134 | 'condition' => [ |
| 135 | 'ekit_pricing_icon_type' => 'icon', |
| 136 | ] |
| 137 | ] |
| 138 | ); |
| 139 | |
| 140 | $this->add_control( |
| 141 | 'ekit_pricing_icons', |
| 142 | [ |
| 143 | 'label' => esc_html__( 'Icon', 'elementskit-lite' ), |
| 144 | 'type' => Controls_Manager::ICONS, |
| 145 | 'fa4compatibility' => 'ekit_pricing_icon', |
| 146 | 'default' => [ |
| 147 | 'value' => 'fab fa-amazon', |
| 148 | 'library' => 'fa-brands', |
| 149 | ], |
| 150 | 'condition' => [ |
| 151 | 'ekit_pricing_icon_type' => 'icon', |
| 152 | 'ekit_pricing_icons__switch' => 'yes' |
| 153 | ] |
| 154 | ] |
| 155 | ); |
| 156 | |
| 157 | $this->add_control( |
| 158 | 'ekit_pricing_image', |
| 159 | [ |
| 160 | 'label' => esc_html__( 'Choose Image', 'elementskit-lite' ), |
| 161 | 'type' => Controls_Manager::MEDIA, |
| 162 | 'dynamic' => [ |
| 163 | 'active' => true, |
| 164 | ], |
| 165 | 'default' => [ |
| 166 | 'url' => Utils::get_placeholder_image_src(), |
| 167 | 'id' => -1 |
| 168 | ], |
| 169 | 'condition' => [ |
| 170 | 'ekit_pricing_icon_type' => 'image', |
| 171 | ], |
| 172 | ] |
| 173 | ); |
| 174 | |
| 175 | $this->add_group_control( |
| 176 | Group_Control_Image_Size::get_type(), |
| 177 | [ |
| 178 | 'name' => 'ekit_pricing_thumbnail', |
| 179 | 'default' => 'thumbnail', |
| 180 | 'separator' => 'none', |
| 181 | 'condition' => [ |
| 182 | 'ekit_pricing_icon_type' => 'image', |
| 183 | ] |
| 184 | ] |
| 185 | ); |
| 186 | $this->end_controls_section(); |
| 187 | $this->start_controls_section( |
| 188 | 'ekit_pricing_pricing_tag', |
| 189 | [ |
| 190 | 'label' => esc_html__('Price Tag', 'elementskit-lite'), |
| 191 | ] |
| 192 | ); |
| 193 | |
| 194 | $this->add_control( |
| 195 | 'ekit_pricing_currency_icon', [ |
| 196 | 'type' => Controls_Manager::TEXT, |
| 197 | 'dynamic' => [ |
| 198 | 'active' => true, |
| 199 | ], |
| 200 | 'label' => esc_html__('Currency', 'elementskit-lite'), |
| 201 | 'default' => '$', |
| 202 | ] |
| 203 | ); |
| 204 | $this->add_control( |
| 205 | 'ekit_pricing_table_price', [ |
| 206 | 'type' => Controls_Manager::TEXT, |
| 207 | 'dynamic' => [ |
| 208 | 'active' => true, |
| 209 | ], |
| 210 | 'label' => esc_html__('Price', 'elementskit-lite'), |
| 211 | 'default' => esc_html__('5.99', 'elementskit-lite'), |
| 212 | ] |
| 213 | ); |
| 214 | $this->add_control( |
| 215 | 'ekit_pricing_table_duration', [ |
| 216 | 'type' => Controls_Manager::TEXT, |
| 217 | 'dynamic' => [ |
| 218 | 'active' => true, |
| 219 | ], |
| 220 | 'label' => esc_html__('Duration', 'elementskit-lite'), |
| 221 | 'default' => esc_html__('Month', 'elementskit-lite'), |
| 222 | ] |
| 223 | ); |
| 224 | $this->end_controls_section(); |
| 225 | $this->start_controls_section( |
| 226 | 'ekit_pricing_features_tab', |
| 227 | [ |
| 228 | 'label' =>esc_html__('Features', 'elementskit-lite'), |
| 229 | ] |
| 230 | ); |
| 231 | $this->add_control( |
| 232 | 'ekit_pricing_content_style', |
| 233 | [ |
| 234 | 'label' => esc_html__( 'Features style', 'elementskit-lite' ), |
| 235 | 'type' => Controls_Manager::SELECT, |
| 236 | 'default' => 'paragraph', |
| 237 | 'options' => [ |
| 238 | 'paragraph' => esc_html__( 'Paragraph', 'elementskit-lite' ), |
| 239 | 'list' => esc_html__( 'List', 'elementskit-lite' ), |
| 240 | ], |
| 241 | ] |
| 242 | ); |
| 243 | |
| 244 | $this->add_control( |
| 245 | 'ekit_pricing_table_content', [ |
| 246 | 'type' => Controls_Manager::TEXTAREA, |
| 247 | 'dynamic' => [ |
| 248 | 'active' => true, |
| 249 | ], |
| 250 | 'label' => esc_html__('Table Content', 'elementskit-lite'), |
| 251 | 'label_block' => true, |
| 252 | 'default' => esc_html__('Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam','elementskit-lite'), |
| 253 | 'condition' => [ |
| 254 | 'ekit_pricing_content_style' => 'paragraph', |
| 255 | ], |
| 256 | ] |
| 257 | ); |
| 258 | $repeater = new Repeater(); |
| 259 | |
| 260 | $repeater->add_control( |
| 261 | 'ekit_pricing_list', [ |
| 262 | 'label' => esc_html__('List text', 'elementskit-lite'), |
| 263 | 'type' => Controls_Manager::TEXT, |
| 264 | 'dynamic' => [ |
| 265 | 'active' => true, |
| 266 | ], |
| 267 | 'default' => esc_html__( '15 Email Account' , 'elementskit-lite' ), |
| 268 | 'label_block' => true, |
| 269 | ] |
| 270 | ); |
| 271 | |
| 272 | $repeater->add_control( |
| 273 | 'ekit_pricing_check_icons', [ |
| 274 | 'label' =>esc_html__( 'Icon', 'elementskit-lite' ), |
| 275 | 'type' => Controls_Manager::ICONS, |
| 276 | 'default' => [ |
| 277 | 'value' => '', |
| 278 | ], |
| 279 | 'label_block' => true, |
| 280 | ] |
| 281 | ); |
| 282 | |
| 283 | $repeater->add_control( |
| 284 | 'ekit_pricing_list_icon_color', [ |
| 285 | 'label' =>esc_html__( 'Icon Color', 'elementskit-lite' ), |
| 286 | 'type' => Controls_Manager::COLOR, |
| 287 | 'default' => '', |
| 288 | 'selectors' => [ |
| 289 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-lists {{CURRENT_ITEM}} > i' => 'color: {{VALUE}}', |
| 290 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-lists {{CURRENT_ITEM}} > svg' => 'fill: {{VALUE}}', |
| 291 | ], |
| 292 | ] |
| 293 | ); |
| 294 | |
| 295 | $repeater->add_responsive_control( |
| 296 | 'ekit_pricing_list_content_typography_group', |
| 297 | [ |
| 298 | 'label' => esc_html__( 'Icon Size', 'elementskit-lite' ), |
| 299 | 'type' => Controls_Manager::SLIDER, |
| 300 | 'size_units' => [ 'px', '%' ], |
| 301 | 'range' => [ |
| 302 | 'px' => [ |
| 303 | 'min' => 1, |
| 304 | 'max' => 100, |
| 305 | 'step' => 5, |
| 306 | ], |
| 307 | '%' => [ |
| 308 | 'min' => 1, |
| 309 | 'max' => 100, |
| 310 | ], |
| 311 | ], |
| 312 | 'selectors' => [ |
| 313 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-lists {{CURRENT_ITEM}} > :is(i, svg)' => 'font-size: {{SIZE}}{{UNIT}};', |
| 314 | ], |
| 315 | ] |
| 316 | ); |
| 317 | |
| 318 | $repeater->add_control( |
| 319 | 'ekit_pricing_list_info', |
| 320 | [ |
| 321 | 'label' => esc_html__( 'Info Text', 'elementskit-lite' ), |
| 322 | 'type' => Controls_Manager::TEXT, |
| 323 | 'dynamic' => [ |
| 324 | 'active' => true, |
| 325 | ], |
| 326 | ] |
| 327 | ); |
| 328 | |
| 329 | $repeater->add_control( |
| 330 | 'ekit_pricing_list_info_icon_color', |
| 331 | [ |
| 332 | 'label' =>esc_html__( 'Info Icon Color', 'elementskit-lite' ), |
| 333 | 'type' => Controls_Manager::COLOR, |
| 334 | 'selectors' => [ |
| 335 | '{{WRAPPER}} {{CURRENT_ITEM}} .ekit-pricing-list-info i' => 'color: {{VALUE}}', |
| 336 | '{{WRAPPER}} {{CURRENT_ITEM}} .ekit-pricing-list-info svg' => 'fill: {{VALUE}}', |
| 337 | ], |
| 338 | 'condition' => [ |
| 339 | 'ekit_pricing_list_info!' => '', |
| 340 | ], |
| 341 | ] |
| 342 | ); |
| 343 | |
| 344 | $this->add_control( |
| 345 | 'ekit_pricing_table_content_repeater', |
| 346 | [ |
| 347 | 'label' => esc_html__( 'Pricing Content List', 'elementskit-lite' ), |
| 348 | 'type' => Controls_Manager::REPEATER, |
| 349 | 'fields' => $repeater->get_controls(), |
| 350 | 'title_field' => '{{ekit_pricing_list}}', |
| 351 | 'default' => [ |
| 352 | [ |
| 353 | 'item' => esc_html__( '15 Email Account', 'elementskit-lite' ), |
| 354 | 'check_icon' => 'icon icon-tick', |
| 355 | ], |
| 356 | [ |
| 357 | 'item' => esc_html__( '100 GB Space', 'elementskit-lite' ), |
| 358 | 'check_icon' => 'icon icon-tick', |
| 359 | ], |
| 360 | [ |
| 361 | 'item' => esc_html__( '1 Domain Name', 'elementskit-lite' ), |
| 362 | 'check_icon' => 'icon icon-tick', |
| 363 | ], |
| 364 | ], |
| 365 | 'title_field' => '{{{ ekit_pricing_list }}}', |
| 366 | 'condition' => [ |
| 367 | 'ekit_pricing_content_style' => 'list', |
| 368 | ], |
| 369 | ] |
| 370 | ); |
| 371 | |
| 372 | $this->end_controls_section(); |
| 373 | $this->start_controls_section( |
| 374 | 'ekit_pricing_button_style_tab', |
| 375 | [ |
| 376 | 'label' =>esc_html__('Button', 'elementskit-lite'), |
| 377 | ] |
| 378 | ); |
| 379 | $this->add_control( |
| 380 | 'ekit_pricing_btn_text', |
| 381 | [ |
| 382 | 'label' =>esc_html__( 'Label', 'elementskit-lite' ), |
| 383 | 'type' => Controls_Manager::TEXT, |
| 384 | 'dynamic' => [ |
| 385 | 'active' => true, |
| 386 | ], |
| 387 | 'default' =>esc_html__( 'Learn more ', 'elementskit-lite' ), |
| 388 | 'placeholder' =>esc_html__( 'Learn more ', 'elementskit-lite' ), |
| 389 | ] |
| 390 | ); |
| 391 | |
| 392 | $this->add_control( |
| 393 | 'ekit_pricing_btn_link', |
| 394 | [ |
| 395 | 'label' =>esc_html__( 'Link', 'elementskit-lite' ), |
| 396 | 'type' => Controls_Manager::URL, |
| 397 | 'dynamic' => [ |
| 398 | 'active' => true, |
| 399 | ], |
| 400 | 'placeholder' =>esc_url('https://wpmet.com'), |
| 401 | 'default' => [ |
| 402 | 'url' => '#', |
| 403 | ], |
| 404 | ] |
| 405 | ); |
| 406 | |
| 407 | $this->add_control( |
| 408 | 'ekit_pricing_btn_icons__switch', |
| 409 | [ |
| 410 | 'label' => esc_html__('Add icon? ', 'elementskit-lite'), |
| 411 | 'type' => Controls_Manager::SWITCHER, |
| 412 | 'default' => 'yes', |
| 413 | 'label_on' =>esc_html__( 'Yes', 'elementskit-lite' ), |
| 414 | 'label_off' =>esc_html__( 'No', 'elementskit-lite' ), |
| 415 | ] |
| 416 | ); |
| 417 | |
| 418 | $this->add_control( |
| 419 | 'ekit_pricing_btn_icons', |
| 420 | [ |
| 421 | 'label' =>esc_html__( 'Icon', 'elementskit-lite' ), |
| 422 | 'type' => Controls_Manager::ICONS, |
| 423 | 'fa4compatibility' => 'ekit_pricing_btn_icon', |
| 424 | 'default' => [ |
| 425 | 'value' => '', |
| 426 | ], |
| 427 | 'label_block' => true, |
| 428 | 'condition' => [ |
| 429 | 'ekit_pricing_btn_icons__switch' => 'yes' |
| 430 | ] |
| 431 | ] |
| 432 | ); |
| 433 | |
| 434 | $this->add_control( |
| 435 | 'ekit_pricing_icon_align', |
| 436 | [ |
| 437 | 'label' =>esc_html__( 'Icon Position', 'elementskit-lite' ), |
| 438 | 'type' => Controls_Manager::SELECT, |
| 439 | 'default' => 'left', |
| 440 | 'options' => [ |
| 441 | 'left' =>esc_html__( 'Before', 'elementskit-lite' ), |
| 442 | 'right' =>esc_html__( 'After', 'elementskit-lite' ), |
| 443 | ], |
| 444 | 'condition' => [ |
| 445 | 'ekit_pricing_btn_icons__switch' => 'yes' |
| 446 | ], |
| 447 | ] |
| 448 | ); |
| 449 | |
| 450 | $this->add_responsive_control( |
| 451 | 'ekit_pricing_icon_spacing', |
| 452 | [ |
| 453 | 'label' => esc_html__( 'Icon Spacing', 'elementskit-lite' ), |
| 454 | 'type' => Controls_Manager::SLIDER, |
| 455 | 'size_units' => ['px', '%'], |
| 456 | 'default' => [ |
| 457 | 'size' => 10, |
| 458 | 'unit' => 'px', |
| 459 | ], |
| 460 | 'range' => [ |
| 461 | '%' => [ |
| 462 | 'min' => 0, |
| 463 | 'max' => 100, |
| 464 | ], |
| 465 | ], |
| 466 | 'selectors' => [ |
| 467 | '{{WRAPPER}} .elementskit-single-pricing a.ekit-pricing-btn-icon-pos-left i' => 'margin-right: {{SIZE}}{{UNIT}};', |
| 468 | '{{WRAPPER}} .elementskit-single-pricing a.ekit-pricing-btn-icon-pos-right i' => 'margin-left: {{SIZE}}{{UNIT}};', |
| 469 | '{{WRAPPER}} .elementskit-single-pricing a.ekit-pricing-btn-icon-pos-left svg' => 'margin-right: {{SIZE}}{{UNIT}};', |
| 470 | '{{WRAPPER}} .elementskit-single-pricing a.ekit-pricing-btn-icon-pos-right svg' => 'margin-left: {{SIZE}}{{UNIT}};', |
| 471 | ], |
| 472 | 'condition' => [ |
| 473 | 'ekit_pricing_btn_icons__switch' => 'yes' |
| 474 | ], |
| 475 | ] |
| 476 | ); |
| 477 | |
| 478 | $this->add_control( |
| 479 | 'ekit_pricing_button_class', |
| 480 | [ |
| 481 | 'label' => esc_html__( 'Class', 'elementskit-lite' ), |
| 482 | 'type' => Controls_Manager::TEXT, |
| 483 | 'dynamic' => [ |
| 484 | 'active' => true, |
| 485 | ], |
| 486 | 'placeholder' => esc_html__( 'Class Name', 'elementskit-lite' ), |
| 487 | ] |
| 488 | ); |
| 489 | |
| 490 | $this->add_control( |
| 491 | 'ekit_pricing_button_id', |
| 492 | [ |
| 493 | 'label' => esc_html__( 'id', 'elementskit-lite' ), |
| 494 | 'type' => Controls_Manager::TEXT, |
| 495 | 'dynamic' => [ |
| 496 | 'active' => true, |
| 497 | ], |
| 498 | 'placeholder' => esc_html__( 'ID', 'elementskit-lite' ), |
| 499 | ] |
| 500 | ); |
| 501 | |
| 502 | |
| 503 | $this->end_controls_section(); |
| 504 | |
| 505 | |
| 506 | //Body style start |
| 507 | $this->start_controls_section( |
| 508 | 'ekit_pricing_section_body_style', |
| 509 | [ |
| 510 | 'label' =>esc_html__( 'Pricing Body', 'elementskit-lite' ), |
| 511 | 'tab' => Controls_Manager::TAB_STYLE, |
| 512 | ] |
| 513 | ); |
| 514 | |
| 515 | $this->add_control( |
| 516 | 'ekit_pricing_pricing_body_bg_sp', [ |
| 517 | 'type' => Controls_Manager::COLOR, |
| 518 | 'label' => esc_html__('Background Color', 'elementskit-lite'), |
| 519 | 'default' => '', |
| 520 | 'selectors' => [ |
| 521 | '{{WRAPPER}} .elementskit-single-pricing' => 'background-color: {{VALUE}};', |
| 522 | ], |
| 523 | ] |
| 524 | ); |
| 525 | |
| 526 | $this->add_responsive_control( |
| 527 | 'ekit_pricing_pricing_content_align', |
| 528 | [ |
| 529 | 'label' =>esc_html__( 'Alignment', 'elementskit-lite' ), |
| 530 | 'type' => Controls_Manager::CHOOSE, |
| 531 | 'options' => [ |
| 532 | 'left' => [ |
| 533 | 'title' =>esc_html__( 'Left', 'elementskit-lite' ), |
| 534 | 'icon' => 'eicon-text-align-left', |
| 535 | ], |
| 536 | 'center' => [ |
| 537 | 'title' =>esc_html__( 'Center', 'elementskit-lite' ), |
| 538 | 'icon' => 'eicon-text-align-center', |
| 539 | ], |
| 540 | 'right' => [ |
| 541 | 'title' =>esc_html__( 'Right', 'elementskit-lite' ), |
| 542 | 'icon' => 'eicon-text-align-right', |
| 543 | ], |
| 544 | ], |
| 545 | 'selectors' => [ |
| 546 | '{{WRAPPER}} .elementskit-single-pricing' => 'text-align: {{VALUE}};' |
| 547 | ], |
| 548 | 'default' => 'center', |
| 549 | ] |
| 550 | ); |
| 551 | |
| 552 | $this->end_controls_section(); |
| 553 | |
| 554 | |
| 555 | |
| 556 | //Price Title style start |
| 557 | $this->start_controls_section( |
| 558 | 'sekit_pricing_ection_title_style', |
| 559 | [ |
| 560 | 'label' =>esc_html__( 'Table Title', 'elementskit-lite' ), |
| 561 | 'tab' => Controls_Manager::TAB_STYLE, |
| 562 | ] |
| 563 | ); |
| 564 | $this->add_responsive_control( |
| 565 | 'ekit_pricing_title_align', |
| 566 | [ |
| 567 | 'label' =>esc_html__( 'Alignment', 'elementskit-lite' ), |
| 568 | 'type' => Controls_Manager::CHOOSE, |
| 569 | 'options' => [ |
| 570 | 'left' => [ |
| 571 | 'title' =>esc_html__( 'Left', 'elementskit-lite' ), |
| 572 | 'icon' => 'eicon-text-align-left', |
| 573 | ], |
| 574 | 'center' => [ |
| 575 | 'title' =>esc_html__( 'Center', 'elementskit-lite' ), |
| 576 | 'icon' => 'eicon-text-align-center', |
| 577 | ], |
| 578 | 'right' => [ |
| 579 | 'title' =>esc_html__( 'Right', 'elementskit-lite' ), |
| 580 | 'icon' => 'eicon-text-align-right', |
| 581 | ], |
| 582 | ], |
| 583 | 'selectors' => [ |
| 584 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-header .elementskit-pricing-title' => 'text-align: {{VALUE}};' |
| 585 | ], |
| 586 | 'default' => '', |
| 587 | ] |
| 588 | ); |
| 589 | $this->start_controls_tabs( 'ekit_pricing_tabs_title_style' ); |
| 590 | |
| 591 | $this->start_controls_tab( |
| 592 | 'ekit_pricing_tab_title_normal', |
| 593 | [ |
| 594 | 'label' =>esc_html__( 'Normal', 'elementskit-lite' ), |
| 595 | ] |
| 596 | ); |
| 597 | $this->add_control( |
| 598 | 'ekit_pricing_title_text_color', |
| 599 | [ |
| 600 | 'label' =>esc_html__( 'Title Color', 'elementskit-lite' ), |
| 601 | 'type' => Controls_Manager::COLOR, |
| 602 | 'default' => '', |
| 603 | 'selectors' => [ |
| 604 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-header .elementskit-pricing-title' => 'color: {{VALUE}};', |
| 605 | ], |
| 606 | ] |
| 607 | ); |
| 608 | $this->end_controls_tab(); |
| 609 | $this->start_controls_tab( |
| 610 | 'ekit_pricing_tab_title_hover', |
| 611 | [ |
| 612 | 'label' =>esc_html__( 'Hover', 'elementskit-lite' ), |
| 613 | ] |
| 614 | ); |
| 615 | $this->add_control( |
| 616 | 'ekit_pricing_title_hover_color', |
| 617 | [ |
| 618 | 'label' =>esc_html__( 'Color', 'elementskit-lite' ), |
| 619 | 'type' => Controls_Manager::COLOR, |
| 620 | 'selectors' => [ |
| 621 | '{{WRAPPER}}:hover .elementskit-pricing-header .elementskit-pricing-title' => 'color: {{VALUE}};', |
| 622 | ], |
| 623 | ] |
| 624 | ); |
| 625 | $this->end_controls_tab(); |
| 626 | $this->end_controls_tabs(); |
| 627 | $this->add_group_control( |
| 628 | Group_Control_Typography::get_type(), |
| 629 | [ |
| 630 | 'name' => 'ekit_pricing_title_typography_group', |
| 631 | 'label' =>esc_html__( 'Title Typography', 'elementskit-lite' ), |
| 632 | 'selector' => '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-header .elementskit-pricing-title', |
| 633 | ] |
| 634 | ); |
| 635 | $this->add_responsive_control( |
| 636 | 'ekit_pricing_title_text_padding', |
| 637 | [ |
| 638 | 'label' =>esc_html__( 'Padding', 'elementskit-lite' ), |
| 639 | 'type' => Controls_Manager::DIMENSIONS, |
| 640 | 'size_units' => [ 'px', 'em', '%' ], |
| 641 | 'selectors' => [ |
| 642 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-header .elementskit-pricing-title' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 643 | ], |
| 644 | ] |
| 645 | ); |
| 646 | |
| 647 | $this->add_responsive_control( |
| 648 | 'ekit_pricing_title_wraper_margin', |
| 649 | [ |
| 650 | 'label' =>esc_html__( 'Margin', 'elementskit-lite' ), |
| 651 | 'type' => Controls_Manager::DIMENSIONS, |
| 652 | 'size_units' => [ 'px', 'em', '%' ], |
| 653 | 'selectors' => [ |
| 654 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-header' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 655 | ], |
| 656 | ] |
| 657 | ); |
| 658 | $this->add_control( |
| 659 | 'ekit_pricing_titlehr12', |
| 660 | [ |
| 661 | 'type' => Controls_Manager::DIVIDER, |
| 662 | 'style' => 'thick', |
| 663 | ] |
| 664 | ); |
| 665 | |
| 666 | $this->add_responsive_control( |
| 667 | 'ekit_pricing_title_border_style', |
| 668 | [ |
| 669 | 'label' => esc_html_x( 'Border Type', 'Border Control', 'elementskit-lite' ), |
| 670 | 'type' => Controls_Manager::SELECT, |
| 671 | 'options' => [ |
| 672 | '' => esc_html__( 'None', 'elementskit-lite' ), |
| 673 | 'solid' => esc_html_x( 'Solid', 'Border Control', 'elementskit-lite' ), |
| 674 | 'double' => esc_html_x( 'Double', 'Border Control', 'elementskit-lite' ), |
| 675 | 'dotted' => esc_html_x( 'Dotted', 'Border Control', 'elementskit-lite' ), |
| 676 | 'dashed' => esc_html_x( 'Dashed', 'Border Control', 'elementskit-lite' ), |
| 677 | 'groove' => esc_html_x( 'Groove', 'Border Control', 'elementskit-lite' ), |
| 678 | ], |
| 679 | 'selectors' => [ |
| 680 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-header .elementskit-pricing-title' => 'border-style: {{VALUE}};', |
| 681 | ], |
| 682 | ] |
| 683 | ); |
| 684 | $this->add_responsive_control( |
| 685 | 'ekit_pricing_title_border_dimensions', |
| 686 | [ |
| 687 | 'label' => esc_html_x( 'Border Width', 'Border Control', 'elementskit-lite' ), |
| 688 | 'type' => Controls_Manager::DIMENSIONS, |
| 689 | 'selectors' => [ |
| 690 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-header .elementskit-pricing-title' => 'border-width: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 691 | ], |
| 692 | 'condition' => [ |
| 693 | 'ekit_pricing_title_border_style!' => '', |
| 694 | ], |
| 695 | |
| 696 | ] |
| 697 | ); |
| 698 | $this->start_controls_tabs( 'ekit_pricing_tabs_title_border_style' ); |
| 699 | $this->start_controls_tab( |
| 700 | 'ekit_pricing_title_border_normal', |
| 701 | [ |
| 702 | 'label' =>esc_html__( 'Normal', 'elementskit-lite' ), |
| 703 | 'condition' => [ |
| 704 | 'ekit_pricing_title_border_style!' => '', |
| 705 | ], |
| 706 | |
| 707 | ] |
| 708 | ); |
| 709 | $this->add_control( |
| 710 | 'ekit_pricing_title_border_color', |
| 711 | [ |
| 712 | 'label' => esc_html_x( 'Border Color', 'Border Control', 'elementskit-lite' ), |
| 713 | 'type' => Controls_Manager::COLOR, |
| 714 | 'default' => '', |
| 715 | 'selectors' => [ |
| 716 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-header .elementskit-pricing-title' => 'border-color: {{VALUE}};', |
| 717 | ], |
| 718 | 'condition' => [ |
| 719 | 'ekit_pricing_title_border_style!' => '', |
| 720 | ], |
| 721 | |
| 722 | ] |
| 723 | ); |
| 724 | $this->end_controls_tab(); |
| 725 | |
| 726 | $this->start_controls_tab( |
| 727 | 'ekit_pricing_title_tab_border_hover', |
| 728 | [ |
| 729 | 'label' =>esc_html__( 'Hover', 'elementskit-lite' ), |
| 730 | 'condition' => [ |
| 731 | 'ekit_pricing_title_border_style!' => '', |
| 732 | ], |
| 733 | |
| 734 | ] |
| 735 | ); |
| 736 | $this->add_control( |
| 737 | 'ekit_pricing_title_hover_border_color', |
| 738 | [ |
| 739 | 'label' => esc_html_x( 'Border Color', 'Border Control', 'elementskit-lite' ), |
| 740 | 'type' => Controls_Manager::COLOR, |
| 741 | 'default' => '', |
| 742 | 'selectors' => [ |
| 743 | '{{WRAPPER}}:hover .elementskit-single-pricing .elementskit-pricing-header .elementskit-pricing-title' => 'border-color: {{VALUE}};', |
| 744 | ], |
| 745 | 'condition' => [ |
| 746 | 'ekit_pricing_title_border_style!' => '', |
| 747 | ], |
| 748 | ] |
| 749 | ); |
| 750 | $this->end_controls_tab(); |
| 751 | $this->end_controls_tabs(); |
| 752 | |
| 753 | $this->add_responsive_control( |
| 754 | 'ekit_pricing_title_border_radius', |
| 755 | [ |
| 756 | 'label' =>esc_html__( 'Border Radius', 'elementskit-lite' ), |
| 757 | 'type' => Controls_Manager::DIMENSIONS, |
| 758 | 'size_units' => [ 'px'], |
| 759 | 'default' => [ |
| 760 | 'top' => '', |
| 761 | 'right' => '', |
| 762 | 'bottom' => '' , |
| 763 | 'left' => '', |
| 764 | ], |
| 765 | 'selectors' => [ |
| 766 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-header .elementskit-pricing-title' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 767 | ], |
| 768 | |
| 769 | ] |
| 770 | ); |
| 771 | |
| 772 | $this->add_group_control( |
| 773 | Group_Control_Box_Shadow::get_type(), |
| 774 | [ |
| 775 | 'name' => 'ekit_pricing_title_box_shadow_group', |
| 776 | 'selector' => '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-header .elementskit-pricing-title', |
| 777 | ] |
| 778 | ); |
| 779 | $this->end_controls_section(); |
| 780 | |
| 781 | //Price Subtitle style start |
| 782 | $this->start_controls_section( |
| 783 | 'ekit_pricing_section_subtitle_style', |
| 784 | [ |
| 785 | 'label' =>esc_html__( 'Table Subtitle', 'elementskit-lite' ), |
| 786 | 'tab' => Controls_Manager::TAB_STYLE, |
| 787 | 'condition' => [ |
| 788 | 'ekit_pricing_table_subtitle!' => '', |
| 789 | ] |
| 790 | ] |
| 791 | ); |
| 792 | $this->add_responsive_control( |
| 793 | 'ekit_pricing_subtitle_align', |
| 794 | [ |
| 795 | 'label' =>esc_html__( 'Alignment', 'elementskit-lite' ), |
| 796 | 'type' => Controls_Manager::CHOOSE, |
| 797 | 'options' => [ |
| 798 | 'left' => [ |
| 799 | 'title' =>esc_html__( 'Left', 'elementskit-lite' ), |
| 800 | 'icon' => 'eicon-text-align-left', |
| 801 | ], |
| 802 | 'center' => [ |
| 803 | 'title' =>esc_html__( 'Center', 'elementskit-lite' ), |
| 804 | 'icon' => 'eicon-text-align-center', |
| 805 | ], |
| 806 | 'right' => [ |
| 807 | 'title' =>esc_html__( 'Right', 'elementskit-lite' ), |
| 808 | 'icon' => 'eicon-text-align-right', |
| 809 | ], |
| 810 | ], |
| 811 | 'selectors' => [ |
| 812 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-header .elementskit-pricing-subtitle' => 'text-align: {{VALUE}};' |
| 813 | ], |
| 814 | 'conditions' => [ |
| 815 | 'terms' => [ |
| 816 | [ |
| 817 | 'name' => 'ekit_pricing_table_subtitle', |
| 818 | 'operator' => '!in', |
| 819 | 'value' => [''], |
| 820 | ], |
| 821 | ], |
| 822 | ], |
| 823 | 'default' => '', |
| 824 | ] |
| 825 | ); |
| 826 | $this->start_controls_tabs( 'ekit_pricing_tabs_subtitle_style' ); |
| 827 | |
| 828 | $this->start_controls_tab( |
| 829 | 'ekit_pricing_tab_subtitle_normal', |
| 830 | [ |
| 831 | 'label' =>esc_html__( 'Normal', 'elementskit-lite' ), |
| 832 | ] |
| 833 | ); |
| 834 | $this->add_control( |
| 835 | 'ekit_pricing_subtitle_text_color', |
| 836 | [ |
| 837 | 'label' =>esc_html__( 'Color', 'elementskit-lite' ), |
| 838 | 'type' => Controls_Manager::COLOR, |
| 839 | 'default' => '', |
| 840 | 'selectors' => [ |
| 841 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-header .elementskit-pricing-subtitle' => 'color: {{VALUE}};', |
| 842 | ], |
| 843 | ] |
| 844 | ); |
| 845 | $this->end_controls_tab(); |
| 846 | $this->start_controls_tab( |
| 847 | 'ekit_pricing_tab_subtitle_hover', |
| 848 | [ |
| 849 | 'label' =>esc_html__( 'Hover', 'elementskit-lite' ), |
| 850 | ] |
| 851 | ); |
| 852 | $this->add_control( |
| 853 | 'ekit_pricing_subtitle_hover_color', |
| 854 | [ |
| 855 | 'label' =>esc_html__( 'Color', 'elementskit-lite' ), |
| 856 | 'type' => Controls_Manager::COLOR, |
| 857 | 'selectors' => [ |
| 858 | '{{WRAPPER}}:hover .elementskit-single-pricing .elementskit-pricing-header .elementskit-pricing-subtitle' => 'color: {{VALUE}};', |
| 859 | ], |
| 860 | ] |
| 861 | ); |
| 862 | $this->end_controls_tab(); |
| 863 | $this->end_controls_tabs(); |
| 864 | $this->add_group_control( |
| 865 | Group_Control_Typography::get_type(), |
| 866 | [ |
| 867 | 'name' => 'ekit_pricing_subtitle_typography_group', |
| 868 | 'label' =>esc_html__( 'Typography', 'elementskit-lite' ), |
| 869 | 'selector' => '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-header .elementskit-pricing-subtitle', |
| 870 | ] |
| 871 | ); |
| 872 | $this->add_responsive_control( |
| 873 | 'ekit_pricing_subtitle_text_padding', |
| 874 | [ |
| 875 | 'label' =>esc_html__( 'Padding', 'elementskit-lite' ), |
| 876 | 'type' => Controls_Manager::DIMENSIONS, |
| 877 | 'size_units' => [ 'px', 'em', '%' ], |
| 878 | 'selectors' => [ |
| 879 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-header .elementskit-pricing-subtitle' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 880 | ], |
| 881 | ] |
| 882 | ); |
| 883 | |
| 884 | |
| 885 | $this->add_responsive_control( |
| 886 | 'ekit_pricing_subtitlehr12', |
| 887 | [ |
| 888 | 'type' => Controls_Manager::DIVIDER, |
| 889 | 'style' => 'thick', |
| 890 | ] |
| 891 | ); |
| 892 | |
| 893 | $this->add_responsive_control( |
| 894 | 'ekit_pricing_subtitle_border_style', |
| 895 | [ |
| 896 | 'label' => esc_html_x( 'Border Type', 'Border Control', 'elementskit-lite' ), |
| 897 | 'type' => Controls_Manager::SELECT, |
| 898 | 'options' => [ |
| 899 | '' => esc_html__( 'None', 'elementskit-lite' ), |
| 900 | 'solid' => esc_html_x( 'Solid', 'Border Control', 'elementskit-lite' ), |
| 901 | 'double' => esc_html_x( 'Double', 'Border Control', 'elementskit-lite' ), |
| 902 | 'dotted' => esc_html_x( 'Dotted', 'Border Control', 'elementskit-lite' ), |
| 903 | 'dashed' => esc_html_x( 'Dashed', 'Border Control', 'elementskit-lite' ), |
| 904 | 'groove' => esc_html_x( 'Groove', 'Border Control', 'elementskit-lite' ), |
| 905 | ], |
| 906 | 'selectors' => [ |
| 907 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-header .elementskit-pricing-subtitle' => 'border-style: {{VALUE}};', |
| 908 | ], |
| 909 | ] |
| 910 | ); |
| 911 | $this->add_responsive_control( |
| 912 | 'ekit_pricing_subtitle_border_dimensions', |
| 913 | [ |
| 914 | 'label' => esc_html_x( 'Width', 'Border Control', 'elementskit-lite' ), |
| 915 | 'type' => Controls_Manager::DIMENSIONS, |
| 916 | 'selectors' => [ |
| 917 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-header .elementskit-pricing-subtitle' => 'border-width: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 918 | ], |
| 919 | 'condition' => [ |
| 920 | 'ekit_pricing_subtitle_border_style!' => '', |
| 921 | ], |
| 922 | ] |
| 923 | ); |
| 924 | $this->start_controls_tabs( 'ekit_pricing_tabs_subtitle_border_style' ); |
| 925 | $this->start_controls_tab( |
| 926 | 'ekit_pricing_subtitle_border_normal', |
| 927 | [ |
| 928 | 'label' =>esc_html__( 'Normal', 'elementskit-lite' ), |
| 929 | 'condition' => [ |
| 930 | 'ekit_pricing_subtitle_border_style!' => '', |
| 931 | ], |
| 932 | ] |
| 933 | ); |
| 934 | |
| 935 | $this->add_control( |
| 936 | 'ekit_pricing_subtitle_border_color', |
| 937 | [ |
| 938 | 'label' => esc_html_x( 'Color', 'Border Control', 'elementskit-lite' ), |
| 939 | 'type' => Controls_Manager::COLOR, |
| 940 | 'default' => '', |
| 941 | 'selectors' => [ |
| 942 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-header .elementskit-pricing-subtitle' => 'border-color: {{VALUE}};', |
| 943 | ], |
| 944 | 'condition' => [ |
| 945 | 'ekit_pricing_subtitle_border_style!' => '', |
| 946 | ], |
| 947 | ] |
| 948 | ); |
| 949 | $this->end_controls_tab(); |
| 950 | |
| 951 | $this->start_controls_tab( |
| 952 | 'ekit_pricing_subtitle_tab_border_hover', |
| 953 | [ |
| 954 | 'label' =>esc_html__( 'Hover', 'elementskit-lite' ), |
| 955 | 'condition' => [ |
| 956 | 'ekit_pricing_subtitle_border_style!' => '', |
| 957 | ], |
| 958 | ] |
| 959 | ); |
| 960 | $this->add_control( |
| 961 | 'ekit_pricing_subtitle_hover_border_color', |
| 962 | [ |
| 963 | 'label' => esc_html_x( 'Color', 'Border Control', 'elementskit-lite' ), |
| 964 | 'type' => Controls_Manager::COLOR, |
| 965 | 'default' => '', |
| 966 | 'selectors' => [ |
| 967 | '{{WRAPPER}}:hover .elementskit-pricing-header .elementskit-pricing-subtitle' => 'border-color: {{VALUE}};', |
| 968 | ], |
| 969 | 'condition' => [ |
| 970 | 'ekit_pricing_subtitle_border_style!' => '', |
| 971 | ], |
| 972 | ] |
| 973 | ); |
| 974 | $this->end_controls_tab(); |
| 975 | $this->end_controls_tabs(); |
| 976 | |
| 977 | |
| 978 | |
| 979 | $this->add_control( |
| 980 | 'ekit_pricing_subtitlehr13', |
| 981 | [ |
| 982 | 'type' => Controls_Manager::DIVIDER, |
| 983 | 'style' => 'thick', |
| 984 | ] |
| 985 | ); |
| 986 | $this->add_responsive_control( |
| 987 | 'ekit_pricing_subtitle_border_radius', |
| 988 | [ |
| 989 | 'label' =>esc_html__( 'Border Radius', 'elementskit-lite' ), |
| 990 | 'type' => Controls_Manager::DIMENSIONS, |
| 991 | 'size_units' => [ 'px'], |
| 992 | 'default' => [ |
| 993 | 'top' => '', |
| 994 | 'right' => '', |
| 995 | 'bottom' => '' , |
| 996 | 'left' => '', |
| 997 | ], |
| 998 | 'selectors' => [ |
| 999 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-header .elementskit-pricing-subtitle' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 1000 | ], |
| 1001 | ] |
| 1002 | ); |
| 1003 | $this->add_group_control( |
| 1004 | Group_Control_Box_Shadow::get_type(), |
| 1005 | [ |
| 1006 | 'name' => 'ekit_pricing_subtitle_box_shadow_group', |
| 1007 | 'selector' => '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-header .elementskit-pricing-subtitle', |
| 1008 | ] |
| 1009 | ); |
| 1010 | $this->end_controls_section(); |
| 1011 | |
| 1012 | //Image Style Start |
| 1013 | $this->start_controls_section( |
| 1014 | 'ekit_pricing_style_image', |
| 1015 | [ |
| 1016 | 'label' => esc_html__( 'Header Image', 'elementskit-lite' ), |
| 1017 | 'tab' => Controls_Manager::TAB_STYLE, |
| 1018 | 'condition' => [ |
| 1019 | 'ekit_pricing_icon_type' => 'image', |
| 1020 | |
| 1021 | ], |
| 1022 | ] |
| 1023 | ); |
| 1024 | $this->add_responsive_control( |
| 1025 | 'ekit_pricing_image_space', |
| 1026 | [ |
| 1027 | 'label' => esc_html__( 'Margin Bottom', 'elementskit-lite' ), |
| 1028 | 'type' => Controls_Manager::SLIDER, |
| 1029 | 'range' => [ |
| 1030 | 'px' => [ |
| 1031 | 'min' => 0, |
| 1032 | 'max' => 100, |
| 1033 | ], |
| 1034 | ], |
| 1035 | 'default' => [ |
| 1036 | 'size' => 10, |
| 1037 | 'unit' => 'px', |
| 1038 | ], |
| 1039 | 'selectors' => [ |
| 1040 | '{{WRAPPER}} .elementskit-single-pricing .elementor-pricing-img img' => 'margin-bottom: {{SIZE}}{{UNIT}};', |
| 1041 | ], |
| 1042 | ] |
| 1043 | ); |
| 1044 | $this->start_controls_tabs( |
| 1045 | 'ekit_pricing_style_tabs_image' |
| 1046 | ); |
| 1047 | |
| 1048 | $this->start_controls_tab( |
| 1049 | 'ekit_pricing_style_img_normal_tab', |
| 1050 | [ |
| 1051 | 'label' => esc_html__( 'Normal', 'elementskit-lite' ), |
| 1052 | ] |
| 1053 | ); |
| 1054 | $this->add_group_control( |
| 1055 | Group_Control_Border::get_type(), |
| 1056 | [ |
| 1057 | 'name' => 'ekit_pricing_imge_border_group', |
| 1058 | 'label' => esc_html__( 'Border', 'elementskit-lite' ), |
| 1059 | 'selector' => '{{WRAPPER}} .elementskit-single-pricing .elementor-pricing-img img', |
| 1060 | ] |
| 1061 | ); |
| 1062 | $this->add_responsive_control( |
| 1063 | 'ekit_pricing_image_border_radius', |
| 1064 | [ |
| 1065 | 'label' => esc_html__( 'Border Radius', 'elementskit-lite' ), |
| 1066 | 'type' => Controls_Manager::DIMENSIONS, |
| 1067 | 'size_units' => [ 'px', '%' ], |
| 1068 | 'selectors' => [ |
| 1069 | '{{WRAPPER}} .elementskit-single-pricing .elementor-pricing-img img' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 1070 | ], |
| 1071 | ] |
| 1072 | ); |
| 1073 | $this->add_group_control( |
| 1074 | Group_Control_Box_Shadow::get_type(), |
| 1075 | [ |
| 1076 | 'name' => 'ekit_pricing_iamge_box_shadow_group', |
| 1077 | 'label' => esc_html__( 'Box Shadow', 'elementskit-lite' ), |
| 1078 | 'selector' => '{{WRAPPER}} .elementskit-single-pricing .elementor-pricing-img img', |
| 1079 | ] |
| 1080 | ); |
| 1081 | |
| 1082 | $this->end_controls_tab(); |
| 1083 | |
| 1084 | $this->start_controls_tab( |
| 1085 | 'ekit_pricing_style_img_hover_tab', |
| 1086 | [ |
| 1087 | 'label' => esc_html__( 'Hover', 'elementskit-lite' ), |
| 1088 | ] |
| 1089 | ); |
| 1090 | |
| 1091 | $this->add_group_control( |
| 1092 | Group_Control_Border::get_type(), |
| 1093 | [ |
| 1094 | 'name' => 'ekit_pricing_imge_border_hover_group', |
| 1095 | 'label' => esc_html__( 'Border', 'elementskit-lite' ), |
| 1096 | 'selector' => '{{WRAPPER}}:hover .elementor-pricing-img img', |
| 1097 | ] |
| 1098 | ); |
| 1099 | $this->add_responsive_control( |
| 1100 | 'ekit_pricing_image_hover_border_radius', |
| 1101 | [ |
| 1102 | 'label' => esc_html__( 'Border Radius', 'elementskit-lite' ), |
| 1103 | 'type' => Controls_Manager::DIMENSIONS, |
| 1104 | 'size_units' => [ 'px', '%' ], |
| 1105 | 'selectors' => [ |
| 1106 | '{{WRAPPER}} .elementskit-single-pricing .elementor-pricing-img img' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 1107 | ], |
| 1108 | ] |
| 1109 | ); |
| 1110 | $this->add_group_control( |
| 1111 | Group_Control_Box_Shadow::get_type(), |
| 1112 | [ |
| 1113 | 'name' => 'ekit_pricing_iamge_box_shadow_hv_group', |
| 1114 | 'label' => esc_html__( 'Box Shadow', 'elementskit-lite' ), |
| 1115 | 'selector' => '{{WRAPPER}}:hover .elementor-pricing-img img', |
| 1116 | ] |
| 1117 | ); |
| 1118 | |
| 1119 | $this->add_control( |
| 1120 | 'ekit_pricing_image_hover_animation', |
| 1121 | [ |
| 1122 | 'label' => esc_html__( 'Animation', 'elementskit-lite' ), |
| 1123 | 'type' => Controls_Manager::HOVER_ANIMATION, |
| 1124 | ] |
| 1125 | ); |
| 1126 | |
| 1127 | |
| 1128 | $this->end_controls_tab(); |
| 1129 | |
| 1130 | $this->end_controls_tabs(); |
| 1131 | |
| 1132 | $this->end_controls_section(); |
| 1133 | |
| 1134 | //Icon Style Start |
| 1135 | $this->start_controls_section( |
| 1136 | 'ekit_pricing_section_style_icon', |
| 1137 | [ |
| 1138 | 'label' => esc_html__( 'Header Icon', 'elementskit-lite' ), |
| 1139 | 'tab' => Controls_Manager::TAB_STYLE, |
| 1140 | 'condition' => [ |
| 1141 | 'ekit_pricing_icons__switch' => 'yes', |
| 1142 | 'ekit_pricing_icon_type' => 'icon', |
| 1143 | |
| 1144 | ], |
| 1145 | ] |
| 1146 | ); |
| 1147 | |
| 1148 | $this->start_controls_tabs( 'icon_colors' ); |
| 1149 | |
| 1150 | $this->start_controls_tab( |
| 1151 | 'ekit_pricing_icon_colors_normal', |
| 1152 | [ |
| 1153 | 'label' => esc_html__( 'Normal', 'elementskit-lite' ), |
| 1154 | ] |
| 1155 | ); |
| 1156 | |
| 1157 | $this->add_control( |
| 1158 | 'ekit_pricing_icon_primary_color', |
| 1159 | [ |
| 1160 | 'label' => esc_html__( 'Color', 'elementskit-lite' ), |
| 1161 | 'type' => Controls_Manager::COLOR, |
| 1162 | 'default' => '', |
| 1163 | 'selectors' => [ |
| 1164 | '{{WRAPPER}} .elementskit-single-pricing .elementkit-pricing-icon' => 'color: {{VALUE}};', |
| 1165 | '{{WRAPPER}} .elementskit-pricing-header svg' => 'fill: {{VALUE}};', |
| 1166 | ], |
| 1167 | ] |
| 1168 | ); |
| 1169 | |
| 1170 | $this->add_control( |
| 1171 | 'ekit_pricing_icon_secondary_color_normal', |
| 1172 | [ |
| 1173 | 'label' => esc_html__( 'BG Color', 'elementskit-lite' ), |
| 1174 | 'type' => Controls_Manager::COLOR, |
| 1175 | 'default' => '', |
| 1176 | 'selectors' => [ |
| 1177 | '{{WRAPPER}} .elementskit-single-pricing .elementkit-pricing-icon, {{WRAPPER}} .elementskit-pricing-header svg' => 'background-color: {{VALUE}};', |
| 1178 | ], |
| 1179 | ] |
| 1180 | ); |
| 1181 | |
| 1182 | $this->add_group_control( |
| 1183 | Group_Control_Border::get_type(), |
| 1184 | [ |
| 1185 | 'name' => 'ekit_pricing_border_group', |
| 1186 | 'label' => esc_html__( 'Border', 'elementskit-lite' ), |
| 1187 | 'selector' => '{{WRAPPER}} .elementkit-pricing-icon, {{WRAPPER}} .elementskit-pricing-header svg', |
| 1188 | ] |
| 1189 | ); |
| 1190 | |
| 1191 | $this->add_responsive_control( |
| 1192 | 'ekit_pricing_icon_border_radius', |
| 1193 | [ |
| 1194 | 'label' => esc_html__( 'Border Radius', 'elementskit-lite' ), |
| 1195 | 'type' => Controls_Manager::DIMENSIONS, |
| 1196 | 'size_units' => [ 'px', '%' ], |
| 1197 | 'selectors' => [ |
| 1198 | '{{WRAPPER}} .elementskit-single-pricing .elementkit-pricing-icon, {{WRAPPER}} .elementskit-pricing-header svg' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 1199 | ], |
| 1200 | ] |
| 1201 | ); |
| 1202 | |
| 1203 | $this->end_controls_tab(); |
| 1204 | |
| 1205 | $this->start_controls_tab( |
| 1206 | 'ekit_pricing_icon_colors_hover', |
| 1207 | [ |
| 1208 | 'label' => esc_html__( 'Hover', 'elementskit-lite' ), |
| 1209 | ] |
| 1210 | ); |
| 1211 | |
| 1212 | $this->add_control( |
| 1213 | 'ekit_pricing_hover_primary_color', |
| 1214 | [ |
| 1215 | 'label' => esc_html__( 'Primary Color', 'elementskit-lite' ), |
| 1216 | 'type' => Controls_Manager::COLOR, |
| 1217 | 'default' => '', |
| 1218 | 'selectors' => [ |
| 1219 | '{{WRAPPER}}:hover .elementkit-pricing-icon' => 'color: {{VALUE}};', |
| 1220 | '{{WRAPPER}}:hover .elementskit-pricing-header svg' => 'fill: {{VALUE}};', |
| 1221 | ], |
| 1222 | ] |
| 1223 | ); |
| 1224 | |
| 1225 | $this->add_control( |
| 1226 | 'ekit_pricing_hover_secondary_color', |
| 1227 | [ |
| 1228 | 'label' => esc_html__( 'Secondary Color', 'elementskit-lite' ), |
| 1229 | 'type' => Controls_Manager::COLOR, |
| 1230 | 'default' => '', |
| 1231 | 'selectors' => [ |
| 1232 | '{{WRAPPER}}:hover .elementkit-pricing-icon, {{WRAPPER}}:hover .elementskit-pricing-header svg' => 'background-color: {{VALUE}};', |
| 1233 | ], |
| 1234 | ] |
| 1235 | ); |
| 1236 | |
| 1237 | $this->add_group_control( |
| 1238 | Group_Control_Border::get_type(), |
| 1239 | [ |
| 1240 | 'name' => 'ekit_pricing_border_icon_group', |
| 1241 | 'label' => esc_html__( 'Border', 'elementskit-lite' ), |
| 1242 | 'selector' => '{{WRAPPER}}:hover .elementkit-pricing-icon, {{WRAPPER}}:hover .elementskit-pricing-header svg', |
| 1243 | 'condition' => [ |
| 1244 | 'view!' => 'Stacked', |
| 1245 | ], |
| 1246 | ] |
| 1247 | ); |
| 1248 | $this->add_responsive_control( |
| 1249 | 'ekit_pricing_icon_hover_border_radius', |
| 1250 | [ |
| 1251 | 'label' => esc_html__( 'Border Radius', 'elementskit-lite' ), |
| 1252 | 'type' => Controls_Manager::DIMENSIONS, |
| 1253 | 'size_units' => [ 'px', '%' ], |
| 1254 | 'selectors' => [ |
| 1255 | '{{WRAPPER}}:hover .elementkit-pricing-icon, {{WRAPPER}}:hover .elementskit-pricing-header svg' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 1256 | ], |
| 1257 | ] |
| 1258 | ); |
| 1259 | $this->add_control( |
| 1260 | 'ekit_pricing_icons_hover_animation', |
| 1261 | [ |
| 1262 | 'label' => esc_html__( 'Hover Animation', 'elementskit-lite' ), |
| 1263 | 'type' => Controls_Manager::HOVER_ANIMATION, |
| 1264 | ] |
| 1265 | ); |
| 1266 | |
| 1267 | $this->end_controls_tab(); |
| 1268 | |
| 1269 | $this->end_controls_tabs(); |
| 1270 | $this->add_responsive_control( |
| 1271 | 'ekit_pricing_icon_size', |
| 1272 | [ |
| 1273 | 'label' => esc_html__( 'Size', 'elementskit-lite' ), |
| 1274 | 'type' => Controls_Manager::SLIDER, |
| 1275 | 'range' => [ |
| 1276 | 'px' => [ |
| 1277 | 'min' => 6, |
| 1278 | 'max' => 300, |
| 1279 | ], |
| 1280 | ], |
| 1281 | 'default' => [ |
| 1282 | 'size' => 40, |
| 1283 | 'unit' => 'px', |
| 1284 | ], |
| 1285 | 'selectors' => [ |
| 1286 | '{{WRAPPER}} .elementkit-pricing-icon' => 'font-size: {{SIZE}}{{UNIT}};', |
| 1287 | '{{WRAPPER}} .elementskit-pricing-header svg' => 'max-width: {{SIZE}}{{UNIT}};', |
| 1288 | ], |
| 1289 | 'separator' => 'before', |
| 1290 | ] |
| 1291 | ); |
| 1292 | $this->add_responsive_control( |
| 1293 | 'ekit_pricing_icon_space', |
| 1294 | [ |
| 1295 | 'label' => esc_html__( 'Margin Bottom', 'elementskit-lite' ), |
| 1296 | 'type' => Controls_Manager::SLIDER, |
| 1297 | 'range' => [ |
| 1298 | 'px' => [ |
| 1299 | 'min' => -20, |
| 1300 | 'max' => 100, |
| 1301 | ], |
| 1302 | ], |
| 1303 | 'default' => [ |
| 1304 | 'size' => 15, |
| 1305 | 'unit' => 'px', |
| 1306 | ], |
| 1307 | 'selectors' => [ |
| 1308 | '{{WRAPPER}} .elementkit-pricing-icon, {{WRAPPER}} .elementskit-pricing-header svg' => 'margin-bottom: {{SIZE}}{{UNIT}};', |
| 1309 | ], |
| 1310 | ] |
| 1311 | ); |
| 1312 | |
| 1313 | $this->add_responsive_control( |
| 1314 | 'ekit_pricing_icon_padding', |
| 1315 | [ |
| 1316 | 'label' => esc_html__( 'Padding', 'elementskit-lite' ), |
| 1317 | 'type' => Controls_Manager::SLIDER, |
| 1318 | 'range' => [ |
| 1319 | 'px' => [ |
| 1320 | 'min' => 0, |
| 1321 | 'max' => 100, |
| 1322 | ], |
| 1323 | ], |
| 1324 | // 'default' => [ |
| 1325 | // 'size' => 15, |
| 1326 | // 'unit' => 'px', |
| 1327 | // ], |
| 1328 | 'selectors' => [ |
| 1329 | '{{WRAPPER}} .elementkit-pricing-icon' => 'padding: {{SIZE}}{{UNIT}};', |
| 1330 | ], |
| 1331 | ] |
| 1332 | ); |
| 1333 | $this->add_responsive_control( |
| 1334 | 'ekit_pricing_rotate', |
| 1335 | [ |
| 1336 | 'label' => esc_html__( 'Rotate', 'elementskit-lite' ), |
| 1337 | 'type' => Controls_Manager::SLIDER, |
| 1338 | 'default' => [ |
| 1339 | 'size' => 0, |
| 1340 | 'unit' => 'deg', |
| 1341 | ], |
| 1342 | 'selectors' => [ |
| 1343 | '{{WRAPPER}} .elementkit-pricing-icon, {{WRAPPER}} .elementskit-pricing-header svg' => 'transform: rotate({{SIZE}}{{UNIT}});', |
| 1344 | ], |
| 1345 | ] |
| 1346 | ); |
| 1347 | |
| 1348 | $this->add_group_control( |
| 1349 | Group_Control_Box_Shadow::get_type(), |
| 1350 | [ |
| 1351 | 'name' => 'ekit_pricing_icon_box_shadow_group', |
| 1352 | 'selector' => '{{WRAPPER}} .elementkit-pricing-icon, {{WRAPPER}} .elementskit-pricing-header svg', |
| 1353 | ] |
| 1354 | ); |
| 1355 | |
| 1356 | $this->end_controls_section(); |
| 1357 | |
| 1358 | //Price Tag style start |
| 1359 | $this->start_controls_section( |
| 1360 | 'ekit_pricing_section_tag_style', |
| 1361 | [ |
| 1362 | 'label' =>esc_html__( 'Price Tag', 'elementskit-lite' ), |
| 1363 | 'tab' => Controls_Manager::TAB_STYLE, |
| 1364 | ] |
| 1365 | ); |
| 1366 | |
| 1367 | $this->add_responsive_control( |
| 1368 | 'ekit_pricing_tag_right', |
| 1369 | [ |
| 1370 | 'label' => esc_html__( 'Right', 'elementskit-lite' ), |
| 1371 | 'type' => Controls_Manager::SLIDER, |
| 1372 | 'size_units' => [ 'px', '%' ], |
| 1373 | 'range' => [ |
| 1374 | 'px' => [ |
| 1375 | 'min' => -200, |
| 1376 | 'max' => 200, |
| 1377 | 'step' => 1, |
| 1378 | ], |
| 1379 | '%' => [ |
| 1380 | 'min' => -100, |
| 1381 | 'max' => 100, |
| 1382 | ], |
| 1383 | ], |
| 1384 | // 'default' => [ |
| 1385 | // 'unit' => 'px', |
| 1386 | // 'size' => 0, |
| 1387 | // ], |
| 1388 | 'selectors' => [ |
| 1389 | '{{WRAPPER}} .elementskit-pricing-tag' => 'right: {{SIZE}}{{UNIT}};', |
| 1390 | ], |
| 1391 | ] |
| 1392 | ); |
| 1393 | |
| 1394 | $this->add_responsive_control( |
| 1395 | 'ekit_pricing_tag_width_width', |
| 1396 | [ |
| 1397 | 'label' => esc_html__( 'Width', 'elementskit-lite' ), |
| 1398 | 'type' => Controls_Manager::SLIDER, |
| 1399 | 'size_units' => [ 'px', '%' ], |
| 1400 | 'range' => [ |
| 1401 | 'px' => [ |
| 1402 | 'min' => 0, |
| 1403 | 'max' => 500, |
| 1404 | 'step' => 1, |
| 1405 | ], |
| 1406 | '%' => [ |
| 1407 | 'min' => 0, |
| 1408 | 'max' => 200, |
| 1409 | ], |
| 1410 | ], |
| 1411 | 'selectors' => [ |
| 1412 | '{{WRAPPER}} .elementskit-pricing-tag' => 'width: {{SIZE}}{{UNIT}};', |
| 1413 | ], |
| 1414 | ] |
| 1415 | ); |
| 1416 | |
| 1417 | $this->add_responsive_control( |
| 1418 | 'ekit_pricing_tag_text_padding', |
| 1419 | [ |
| 1420 | 'label' =>esc_html__( 'Padding', 'elementskit-lite' ), |
| 1421 | 'type' => Controls_Manager::DIMENSIONS, |
| 1422 | 'size_units' => [ 'px', 'em', '%' ], |
| 1423 | 'default' => [ |
| 1424 | 'top' => '8', |
| 1425 | 'right' => '0', |
| 1426 | 'bottom' => '8', |
| 1427 | 'left' => '0', |
| 1428 | 'unit' => 'px', |
| 1429 | ], |
| 1430 | 'selectors' => [ |
| 1431 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-price-wraper.has-tag' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 1432 | ], |
| 1433 | ] |
| 1434 | ); |
| 1435 | $this->add_responsive_control( |
| 1436 | 'ekit_pricing_tag_text_margin', |
| 1437 | [ |
| 1438 | 'label' =>esc_html__( 'Margin', 'elementskit-lite' ), |
| 1439 | 'type' => Controls_Manager::DIMENSIONS, |
| 1440 | 'size_units' => [ 'px', 'em', '%' ], |
| 1441 | 'default' => [ |
| 1442 | 'top' => '0', |
| 1443 | 'right' => '0', |
| 1444 | 'bottom' => '50', |
| 1445 | 'left' => '0', |
| 1446 | 'unit' => 'px', |
| 1447 | ], |
| 1448 | 'selectors' => [ |
| 1449 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-price-wraper.has-tag' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 1450 | ], |
| 1451 | ] |
| 1452 | ); |
| 1453 | |
| 1454 | $this->add_group_control( |
| 1455 | Group_Control_Typography::get_type(), |
| 1456 | [ |
| 1457 | 'name' => 'ekit_pricing_price_typography_group', |
| 1458 | 'label' =>esc_html__( 'Typography', 'elementskit-lite' ), |
| 1459 | 'selector' => '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-price-wraper.has-tag .elementskit-pricing-price span', |
| 1460 | ] |
| 1461 | ); |
| 1462 | $this->add_control( |
| 1463 | 'ekit_pricing_heading_period_style', |
| 1464 | [ |
| 1465 | 'label' => esc_html__( 'Duration', 'elementskit-lite' ), |
| 1466 | 'type' => Controls_Manager::HEADING, |
| 1467 | 'separator' => 'before', |
| 1468 | ] |
| 1469 | ); |
| 1470 | $this->add_control( |
| 1471 | 'ekit_pricing_period_text_color', |
| 1472 | [ |
| 1473 | 'label' =>esc_html__( 'Text Color', 'elementskit-lite' ), |
| 1474 | 'type' => Controls_Manager::COLOR, |
| 1475 | 'default' => '', |
| 1476 | 'selectors' => [ |
| 1477 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-price-wraper.has-tag .elementskit-pricing-price .period' => 'color: {{VALUE}};', |
| 1478 | ], |
| 1479 | ] |
| 1480 | ); |
| 1481 | $this->add_control( |
| 1482 | 'ekit_pricing_period_text_color_hover', |
| 1483 | [ |
| 1484 | 'label' =>esc_html__( 'Text Hover Color', 'elementskit-lite' ), |
| 1485 | 'type' => Controls_Manager::COLOR, |
| 1486 | 'default' => '', |
| 1487 | 'selectors' => [ |
| 1488 | '{{WRAPPER}}:hover .elementskit-pricing-price-wraper.has-tag .elementskit-pricing-price .period' => 'color: {{VALUE}};', |
| 1489 | ], |
| 1490 | ] |
| 1491 | ); |
| 1492 | |
| 1493 | $this->add_group_control( |
| 1494 | Group_Control_Typography::get_type(), |
| 1495 | [ |
| 1496 | 'name' => 'ekit_pricing_period_typography_group', |
| 1497 | 'label' =>esc_html__( 'Typography', 'elementskit-lite' ), |
| 1498 | 'selector' => '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-price-wraper.has-tag .elementskit-pricing-price sub.period', |
| 1499 | ] |
| 1500 | ); |
| 1501 | $this->add_responsive_control( |
| 1502 | 'ekit_pricing_period_vertical_position', |
| 1503 | [ |
| 1504 | 'label' => esc_html__( 'Vertical Position', 'elementskit-lite' ), |
| 1505 | 'type' => Controls_Manager::CHOOSE, |
| 1506 | 'label_block' => false, |
| 1507 | 'options' => [ |
| 1508 | 'top' => [ |
| 1509 | 'title' => esc_html__( 'Top', 'elementskit-lite' ), |
| 1510 | 'icon' => 'eicon-v-align-top', |
| 1511 | ], |
| 1512 | 'middle' => [ |
| 1513 | 'title' => esc_html__( 'Middle', 'elementskit-lite' ), |
| 1514 | 'icon' => 'eicon-v-align-middle', |
| 1515 | ], |
| 1516 | 'bottom' => [ |
| 1517 | 'title' => esc_html__( 'Bottom', 'elementskit-lite' ), |
| 1518 | 'icon' => 'eicon-v-align-bottom', |
| 1519 | ], |
| 1520 | ], |
| 1521 | 'default' => 'top', |
| 1522 | 'selectors_dictionary' => [ |
| 1523 | 'top' => 'super', |
| 1524 | 'middle' => 'baseline', |
| 1525 | 'bottom' => 'sub', |
| 1526 | ], |
| 1527 | 'selectors' => [ |
| 1528 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-price-wraper.has-tag .elementskit-pricing-price sub.period' => 'vertical-align: {{VALUE}}', |
| 1529 | ], |
| 1530 | ] |
| 1531 | ); |
| 1532 | |
| 1533 | $this->add_control( |
| 1534 | 'ekit_pricing_heading_currency_style', |
| 1535 | [ |
| 1536 | 'label' => esc_html__( 'Currency Symbol', 'elementskit-lite' ), |
| 1537 | 'type' => Controls_Manager::HEADING, |
| 1538 | 'separator' => 'before', |
| 1539 | ] |
| 1540 | ); |
| 1541 | |
| 1542 | $this->add_group_control( |
| 1543 | Group_Control_Typography::get_type(), |
| 1544 | [ |
| 1545 | 'name' => 'ekit_pricing_currency_size', |
| 1546 | 'label' =>esc_html__( 'Typography', 'elementskit-lite' ), |
| 1547 | 'selector' => '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-price-wraper.has-tag .elementskit-pricing-price sup.currency', |
| 1548 | ] |
| 1549 | ); |
| 1550 | |
| 1551 | $this->add_control( |
| 1552 | 'ekit_pricing_currency_position', |
| 1553 | [ |
| 1554 | 'label' => esc_html__( 'Position', 'elementskit-lite' ), |
| 1555 | 'type' => Controls_Manager::CHOOSE, |
| 1556 | 'label_block' => false, |
| 1557 | 'default' => 'before', |
| 1558 | 'options' => [ |
| 1559 | 'before' => [ |
| 1560 | 'title' => esc_html__( 'Before', 'elementskit-lite' ), |
| 1561 | 'icon' => 'eicon-h-align-left', |
| 1562 | ], |
| 1563 | 'after' => [ |
| 1564 | 'title' => esc_html__( 'After', 'elementskit-lite' ), |
| 1565 | 'icon' => 'eicon-h-align-right', |
| 1566 | ], |
| 1567 | ], |
| 1568 | ] |
| 1569 | ); |
| 1570 | |
| 1571 | $this->add_responsive_control( |
| 1572 | 'ekit_pricing_currency_vertical_position', |
| 1573 | [ |
| 1574 | 'label' => esc_html__( 'Vertical Position', 'elementskit-lite' ), |
| 1575 | 'type' => Controls_Manager::CHOOSE, |
| 1576 | 'label_block' => false, |
| 1577 | 'options' => [ |
| 1578 | 'top' => [ |
| 1579 | 'title' => esc_html__( 'Top', 'elementskit-lite' ), |
| 1580 | 'icon' => 'eicon-v-align-top', |
| 1581 | ], |
| 1582 | 'middle' => [ |
| 1583 | 'title' => esc_html__( 'Middle', 'elementskit-lite' ), |
| 1584 | 'icon' => 'eicon-v-align-middle', |
| 1585 | ], |
| 1586 | 'bottom' => [ |
| 1587 | 'title' => esc_html__( 'Bottom', 'elementskit-lite' ), |
| 1588 | 'icon' => 'eicon-v-align-bottom', |
| 1589 | ], |
| 1590 | ], |
| 1591 | 'default' => 'top', |
| 1592 | 'selectors_dictionary' => [ |
| 1593 | 'top' => 'super', |
| 1594 | 'middle' => 'baseline', |
| 1595 | 'bottom' => 'sub', |
| 1596 | ], |
| 1597 | 'selectors' => [ |
| 1598 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-price-wraper.has-tag .elementskit-pricing-price sup.currency' => 'vertical-align: {{VALUE}}', |
| 1599 | ], |
| 1600 | ] |
| 1601 | ); |
| 1602 | |
| 1603 | $this->add_control( |
| 1604 | 'ekit_pricing_taghr1', |
| 1605 | [ |
| 1606 | 'type' => Controls_Manager::DIVIDER, |
| 1607 | 'style' => 'thick', |
| 1608 | ] |
| 1609 | ); |
| 1610 | $this->start_controls_tabs( 'ekit_pricing_tabs_price_style' ); |
| 1611 | |
| 1612 | $this->start_controls_tab( |
| 1613 | 'ekit_pricing_tab_tag_normal', |
| 1614 | [ |
| 1615 | 'label' =>esc_html__( 'Normal', 'elementskit-lite' ), |
| 1616 | ] |
| 1617 | ); |
| 1618 | |
| 1619 | $this->add_control( |
| 1620 | 'ekit_pricing_tag_text_color', |
| 1621 | [ |
| 1622 | 'label' =>esc_html__( 'Color', 'elementskit-lite' ), |
| 1623 | 'type' => Controls_Manager::COLOR, |
| 1624 | 'default' => '', |
| 1625 | 'selectors' => [ |
| 1626 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-price-wraper.has-tag .elementskit-pricing-price' => 'color: {{VALUE}};', |
| 1627 | ], |
| 1628 | ] |
| 1629 | ); |
| 1630 | $this->add_group_control( |
| 1631 | Group_Control_Background::get_type(), |
| 1632 | array( |
| 1633 | 'name' => 'ekit_pricing_tag_bg_color', |
| 1634 | 'selector' => '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-price-wraper.has-tag .elementskit-pricing-tag', |
| 1635 | ) |
| 1636 | ); |
| 1637 | |
| 1638 | $this->end_controls_tab(); |
| 1639 | |
| 1640 | $this->start_controls_tab( |
| 1641 | 'ekit_pricing_tag_tab_hover', |
| 1642 | [ |
| 1643 | 'label' =>esc_html__( 'Hover', 'elementskit-lite' ), |
| 1644 | ] |
| 1645 | ); |
| 1646 | |
| 1647 | $this->add_control( |
| 1648 | 'ekit_pricing_tag_hover_color', |
| 1649 | [ |
| 1650 | 'label' =>esc_html__( 'Color', 'elementskit-lite' ), |
| 1651 | 'type' => Controls_Manager::COLOR, |
| 1652 | 'selectors' => [ |
| 1653 | '{{WRAPPER}}:hover .elementskit-pricing-price-wraper.has-tag .elementskit-pricing-price' => 'color: {{VALUE}};', |
| 1654 | ], |
| 1655 | ] |
| 1656 | ); |
| 1657 | |
| 1658 | $this->add_group_control( |
| 1659 | Group_Control_Background::get_type(), |
| 1660 | array( |
| 1661 | 'name' => 'ekit_pricing_tag_bg_hover_color_group', |
| 1662 | 'selector' => '{{WRAPPER}}:hover .elementskit-pricing-price-wraper.has-tag .elementskit-pricing-tag', |
| 1663 | ) |
| 1664 | ); |
| 1665 | |
| 1666 | $this->end_controls_tab(); |
| 1667 | $this->end_controls_tabs(); |
| 1668 | |
| 1669 | |
| 1670 | $this->add_control( |
| 1671 | 'ekit_pricing_taghr2', |
| 1672 | [ |
| 1673 | 'type' => Controls_Manager::DIVIDER, |
| 1674 | 'style' => 'thick', |
| 1675 | ] |
| 1676 | ); |
| 1677 | |
| 1678 | $this->add_responsive_control( |
| 1679 | 'ekit_pricing_tag_border_style', |
| 1680 | [ |
| 1681 | 'label' => esc_html_x( 'Border Type', 'Border Control', 'elementskit-lite' ), |
| 1682 | 'type' => Controls_Manager::SELECT, |
| 1683 | 'options' => [ |
| 1684 | '' => esc_html__( 'None', 'elementskit-lite' ), |
| 1685 | 'solid' => esc_html_x( 'Solid', 'Border Control', 'elementskit-lite' ), |
| 1686 | 'double' => esc_html_x( 'Double', 'Border Control', 'elementskit-lite' ), |
| 1687 | 'dotted' => esc_html_x( 'Dotted', 'Border Control', 'elementskit-lite' ), |
| 1688 | 'dashed' => esc_html_x( 'Dashed', 'Border Control', 'elementskit-lite' ), |
| 1689 | 'groove' => esc_html_x( 'Groove', 'Border Control', 'elementskit-lite' ), |
| 1690 | ], |
| 1691 | 'selectors' => [ |
| 1692 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-price-wraper.has-tag .elementskit-pricing-tag' => 'border-style: {{VALUE}};', |
| 1693 | ], |
| 1694 | ] |
| 1695 | ); |
| 1696 | $this->add_responsive_control( |
| 1697 | 'ekit_pricing_tag_border_dimensions', |
| 1698 | [ |
| 1699 | 'label' => esc_html_x( 'Width', 'Border Control', 'elementskit-lite' ), |
| 1700 | 'type' => Controls_Manager::DIMENSIONS, |
| 1701 | 'selectors' => [ |
| 1702 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-price-wraper.has-tag .elementskit-pricing-tag' => 'border-width: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 1703 | ], |
| 1704 | ] |
| 1705 | ); |
| 1706 | $this->start_controls_tabs( 'ekit_pricing_tabs_tag_border_style' ); |
| 1707 | $this->start_controls_tab( |
| 1708 | 'ekit_pricing_tag_border_normal', |
| 1709 | [ |
| 1710 | 'label' =>esc_html__( 'Normal', 'elementskit-lite' ), |
| 1711 | ] |
| 1712 | ); |
| 1713 | |
| 1714 | $this->add_control( |
| 1715 | 'ekit_pricing_tag_border_color', |
| 1716 | [ |
| 1717 | 'label' => esc_html_x( 'Color', 'Border Control', 'elementskit-lite' ), |
| 1718 | 'type' => Controls_Manager::COLOR, |
| 1719 | 'default' => '', |
| 1720 | 'selectors' => [ |
| 1721 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-price-wraper.has-tag .elementskit-pricing-tag' => 'border-color: {{VALUE}};', |
| 1722 | ], |
| 1723 | ] |
| 1724 | ); |
| 1725 | $this->end_controls_tab(); |
| 1726 | |
| 1727 | $this->start_controls_tab( |
| 1728 | 'ekit_pricing_tag_tab_border_hover', |
| 1729 | [ |
| 1730 | 'label' =>esc_html__( 'Hover', 'elementskit-lite' ), |
| 1731 | ] |
| 1732 | ); |
| 1733 | $this->add_control( |
| 1734 | 'ekit_pricing_tag_hover_border_color', |
| 1735 | [ |
| 1736 | 'label' => esc_html_x( 'Color', 'Border Control', 'elementskit-lite' ), |
| 1737 | 'type' => Controls_Manager::COLOR, |
| 1738 | 'default' => '', |
| 1739 | 'selectors' => [ |
| 1740 | '{{WRAPPER}}:hover .elementskit-pricing-price-wraper.has-tag .elementskit-pricing-tag' => 'border-color: {{VALUE}};', |
| 1741 | ], |
| 1742 | ] |
| 1743 | ); |
| 1744 | $this->end_controls_tab(); |
| 1745 | $this->end_controls_tabs(); |
| 1746 | |
| 1747 | |
| 1748 | |
| 1749 | $this->add_control( |
| 1750 | 'ekit_pricing_taghr3', |
| 1751 | [ |
| 1752 | 'type' => Controls_Manager::DIVIDER, |
| 1753 | 'style' => 'thick', |
| 1754 | ] |
| 1755 | ); |
| 1756 | $this->add_responsive_control( |
| 1757 | 'ekit_pricing_tag_border_radius', |
| 1758 | [ |
| 1759 | 'label' =>esc_html__( 'Border Radius', 'elementskit-lite' ), |
| 1760 | 'type' => Controls_Manager::DIMENSIONS, |
| 1761 | 'size_units' => [ 'px'], |
| 1762 | 'default' => [ |
| 1763 | 'top' => '', |
| 1764 | 'right' => '', |
| 1765 | 'bottom' => '' , |
| 1766 | 'left' => '', |
| 1767 | ], |
| 1768 | 'selectors' => [ |
| 1769 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-price-wraper.has-tag .elementskit-pricing-tag' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 1770 | ], |
| 1771 | ] |
| 1772 | ); |
| 1773 | $this->add_group_control( |
| 1774 | Group_Control_Box_Shadow::get_type(), |
| 1775 | [ |
| 1776 | 'name' => 'ekit_pricing_tag_box_shadow_group', |
| 1777 | 'selector' => '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-price-wraper.has-tag .elementskit-pricing-tag', |
| 1778 | ] |
| 1779 | ); |
| 1780 | |
| 1781 | $this->end_controls_section(); |
| 1782 | |
| 1783 | |
| 1784 | |
| 1785 | |
| 1786 | //Price Features style start |
| 1787 | $this->start_controls_section( |
| 1788 | 'ekit_pricing_section_content_style', |
| 1789 | [ |
| 1790 | 'label' =>esc_html__( 'Features', 'elementskit-lite' ), |
| 1791 | 'tab' => Controls_Manager::TAB_STYLE, |
| 1792 | ] |
| 1793 | ); |
| 1794 | |
| 1795 | $this->add_responsive_control( |
| 1796 | 'ekit_pricing_btn_align', |
| 1797 | [ |
| 1798 | 'label' =>esc_html__( 'Content Alignment', 'elementskit-lite' ), |
| 1799 | 'type' => Controls_Manager::CHOOSE, |
| 1800 | 'options' => [ |
| 1801 | 'left' => [ |
| 1802 | 'title' =>esc_html__( 'Left', 'elementskit-lite' ), |
| 1803 | 'icon' => 'eicon-text-align-left', |
| 1804 | ], |
| 1805 | 'center' => [ |
| 1806 | 'title' =>esc_html__( 'Center', 'elementskit-lite' ), |
| 1807 | 'icon' => 'eicon-text-align-center', |
| 1808 | ], |
| 1809 | 'right' => [ |
| 1810 | 'title' =>esc_html__( 'Right', 'elementskit-lite' ), |
| 1811 | 'icon' => 'eicon-text-align-right', |
| 1812 | ], |
| 1813 | ], |
| 1814 | 'selectors' => [ |
| 1815 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-content' => 'text-align: {{VALUE}};', |
| 1816 | ], |
| 1817 | 'default' => '', |
| 1818 | |
| 1819 | ] |
| 1820 | ); |
| 1821 | $this->add_group_control( |
| 1822 | Group_Control_Typography::get_type(), |
| 1823 | [ |
| 1824 | 'name' => 'ekit_pricing_content_typography_group', |
| 1825 | 'label' =>esc_html__( 'List Typography', 'elementskit-lite' ), |
| 1826 | 'selector' => '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-content p, {{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-lists > li', |
| 1827 | ] |
| 1828 | ); |
| 1829 | |
| 1830 | $this->add_control( |
| 1831 | 'ekit_pricing_content_li_type', |
| 1832 | [ |
| 1833 | 'label' => esc_html__( 'List Type', 'elementskit-lite' ), |
| 1834 | 'type' => \Elementor\Controls_Manager::SELECT, |
| 1835 | 'default' => 'none', |
| 1836 | 'options' => [ |
| 1837 | 'none' => esc_html__( 'None', 'elementskit-lite' ), |
| 1838 | 'disc' => esc_html__( 'Disc', 'elementskit-lite' ), |
| 1839 | 'decimal' => esc_html__( 'Number', 'elementskit-lite' ), |
| 1840 | 'lower-alpha' => esc_html__( 'Alphabet', 'elementskit-lite' ), |
| 1841 | 'lower-roman' => esc_html__( 'Roman', 'elementskit-lite' ), |
| 1842 | ], |
| 1843 | 'selectors' => [ |
| 1844 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-lists > li' => 'list-style: {{VALUE}};', |
| 1845 | ], |
| 1846 | 'condition' => [ |
| 1847 | 'ekit_pricing_content_style' => 'list', |
| 1848 | ], |
| 1849 | ] |
| 1850 | ); |
| 1851 | |
| 1852 | $this->add_control( |
| 1853 | 'ekit_pricing_fhr1', |
| 1854 | [ |
| 1855 | 'type' => Controls_Manager::DIVIDER, |
| 1856 | 'style' => 'thick', |
| 1857 | ] |
| 1858 | ); |
| 1859 | $this->start_controls_tabs( 'ekit_pricing_tabs_content_style' ); |
| 1860 | |
| 1861 | $this->start_controls_tab( |
| 1862 | 'ekit_pricing_content_tab', |
| 1863 | [ |
| 1864 | 'label' =>esc_html__( 'Normal', 'elementskit-lite' ), |
| 1865 | ] |
| 1866 | ); |
| 1867 | $this->add_control( |
| 1868 | 'ekit_pricing_content_text_color', |
| 1869 | [ |
| 1870 | 'label' =>esc_html__( 'Color', 'elementskit-lite' ), |
| 1871 | 'type' => Controls_Manager::COLOR, |
| 1872 | 'default' => '', |
| 1873 | 'selectors' => [ |
| 1874 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-content p' => 'color: {{VALUE}};', |
| 1875 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-lists > li' => 'color: {{VALUE}};', |
| 1876 | ], |
| 1877 | ] |
| 1878 | ); |
| 1879 | $this->add_group_control( |
| 1880 | Group_Control_Border::get_type(), |
| 1881 | [ |
| 1882 | 'name' => 'ekit_pricing_features_n_bd', |
| 1883 | 'selector' => '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-content', |
| 1884 | ] |
| 1885 | ); |
| 1886 | $this->end_controls_tab(); |
| 1887 | $this->start_controls_tab( |
| 1888 | 'ekit_pricing_content_tab_hover', |
| 1889 | [ |
| 1890 | 'label' =>esc_html__( 'Hover', 'elementskit-lite' ), |
| 1891 | ] |
| 1892 | ); |
| 1893 | $this->add_control( |
| 1894 | 'ekit_pricing_content_hover_color', |
| 1895 | [ |
| 1896 | 'label' =>esc_html__( 'Color', 'elementskit-lite' ), |
| 1897 | 'type' => Controls_Manager::COLOR, |
| 1898 | 'selectors' => [ |
| 1899 | '{{WRAPPER}}:hover .elementskit-pricing-content p' => 'color: {{VALUE}};', |
| 1900 | '{{WRAPPER}}:hover .elementskit-pricing-lists li' => 'color: {{VALUE}};', |
| 1901 | ], |
| 1902 | ] |
| 1903 | ); |
| 1904 | $this->add_group_control( |
| 1905 | Group_Control_Border::get_type(), |
| 1906 | [ |
| 1907 | 'name' => 'ekit_pricing_features_h_bd', |
| 1908 | 'selector' => '{{WRAPPER}}:hover .elementskit-single-pricing .elementskit-pricing-content', |
| 1909 | ] |
| 1910 | ); |
| 1911 | $this->end_controls_tab(); |
| 1912 | $this->end_controls_tabs(); |
| 1913 | |
| 1914 | |
| 1915 | $this->add_control( |
| 1916 | 'ekit_pricing_list_divider', |
| 1917 | [ |
| 1918 | 'label' => esc_html__( 'Divider', 'elementskit-lite' ), |
| 1919 | 'type' => Controls_Manager::SWITCHER, |
| 1920 | 'default' => 'no', |
| 1921 | 'separator' => 'before', |
| 1922 | 'condition' => [ |
| 1923 | 'ekit_pricing_content_style' => 'list', |
| 1924 | ] |
| 1925 | ] |
| 1926 | ); |
| 1927 | |
| 1928 | $this->add_responsive_control( |
| 1929 | 'ekit_pricing_divider_style', |
| 1930 | [ |
| 1931 | 'label' => esc_html__( 'Style', 'elementskit-lite' ), |
| 1932 | 'type' => Controls_Manager::SELECT, |
| 1933 | 'options' => [ |
| 1934 | 'solid' => esc_html__( 'Solid', 'elementskit-lite' ), |
| 1935 | 'double' => esc_html__( 'Double', 'elementskit-lite' ), |
| 1936 | 'dotted' => esc_html__( 'Dotted', 'elementskit-lite' ), |
| 1937 | 'dashed' => esc_html__( 'Dashed', 'elementskit-lite' ), |
| 1938 | ], |
| 1939 | 'default' => 'solid', |
| 1940 | 'condition' => [ |
| 1941 | 'ekit_pricing_list_divider' => 'yes', |
| 1942 | ], |
| 1943 | 'selectors' => [ |
| 1944 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-lists li' => 'border-top-style: {{VALUE}};', |
| 1945 | ], |
| 1946 | ] |
| 1947 | ); |
| 1948 | |
| 1949 | $this->add_control( |
| 1950 | 'ekit_pricing_divider_color', |
| 1951 | [ |
| 1952 | 'label' => esc_html__( 'Color', 'elementskit-lite' ), |
| 1953 | 'type' => Controls_Manager::COLOR, |
| 1954 | 'default' => '#ddd', |
| 1955 | 'condition' => [ |
| 1956 | 'ekit_pricing_list_divider' => 'yes', |
| 1957 | ], |
| 1958 | 'selectors' => [ |
| 1959 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-lists li' => 'border-top-color: {{VALUE}};', |
| 1960 | ], |
| 1961 | ] |
| 1962 | ); |
| 1963 | |
| 1964 | $this->add_responsive_control( |
| 1965 | 'ekit_pricing_divider_weight', |
| 1966 | [ |
| 1967 | 'label' => esc_html__( 'Weight', 'elementskit-lite' ), |
| 1968 | 'type' => Controls_Manager::SLIDER, |
| 1969 | 'default' => [ |
| 1970 | 'size' => 2, |
| 1971 | 'unit' => 'px', |
| 1972 | ], |
| 1973 | 'range' => [ |
| 1974 | 'px' => [ |
| 1975 | 'min' => 1, |
| 1976 | 'max' => 10, |
| 1977 | ], |
| 1978 | ], |
| 1979 | 'condition' => [ |
| 1980 | 'ekit_pricing_list_divider' => 'yes', |
| 1981 | ], |
| 1982 | 'selectors' => [ |
| 1983 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-lists li' => 'border-top-width: {{SIZE}}{{UNIT}};', |
| 1984 | ], |
| 1985 | ] |
| 1986 | ); |
| 1987 | |
| 1988 | $this->add_responsive_control( |
| 1989 | 'ekit_pricing_divider_width', |
| 1990 | [ |
| 1991 | 'label' => esc_html__( 'Width', 'elementskit-lite' ), |
| 1992 | 'type' => Controls_Manager::SLIDER, |
| 1993 | 'condition' => [ |
| 1994 | 'ekit_pricing_list_divider' => 'yes', |
| 1995 | ], |
| 1996 | 'selectors' => [ |
| 1997 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-lists li:before' => 'margin-left: calc((100% - {{SIZE}}%)/2); margin-right: calc((100% - {{SIZE}}%)/2)', |
| 1998 | ], |
| 1999 | ] |
| 2000 | ); |
| 2001 | |
| 2002 | $this->add_responsive_control( |
| 2003 | 'ekit_pricing_divider_gap', |
| 2004 | [ |
| 2005 | 'label' => esc_html__( 'List Gap', 'elementskit-lite' ), |
| 2006 | 'type' => Controls_Manager::SLIDER, |
| 2007 | 'default' => [ |
| 2008 | 'size' => 15, |
| 2009 | 'unit' => 'px', |
| 2010 | ], |
| 2011 | 'range' => [ |
| 2012 | 'px' => [ |
| 2013 | 'min' => 1, |
| 2014 | 'max' => 50, |
| 2015 | ], |
| 2016 | ], |
| 2017 | 'selectors' => [ |
| 2018 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-lists li:before' => 'margin-top: {{SIZE}}{{UNIT}}; margin-bottom: {{SIZE}}{{UNIT}}', |
| 2019 | ], |
| 2020 | 'condition' => [ |
| 2021 | 'ekit_pricing_content_style' => 'list', |
| 2022 | ] |
| 2023 | ] |
| 2024 | ); |
| 2025 | |
| 2026 | $this->add_control( |
| 2027 | 'ekit_pricing_fhr5', |
| 2028 | [ |
| 2029 | 'type' => Controls_Manager::DIVIDER, |
| 2030 | 'style' => 'thick', |
| 2031 | ] |
| 2032 | ); |
| 2033 | $this->add_responsive_control( |
| 2034 | 'ekit_pricing_features_body_margin', |
| 2035 | [ |
| 2036 | 'label' =>esc_html__( 'Margin', 'elementskit-lite' ), |
| 2037 | 'type' => Controls_Manager::DIMENSIONS, |
| 2038 | 'size_units' => [ 'px', 'em', '%' ], |
| 2039 | 'default' => [ |
| 2040 | 'top' => 0, |
| 2041 | 'left' => 0, |
| 2042 | 'right' => 0, |
| 2043 | 'bottom' => 50, |
| 2044 | 'unit' => 'px', |
| 2045 | ], |
| 2046 | 'selectors' => [ |
| 2047 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-content' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 2048 | ], |
| 2049 | ] |
| 2050 | ); |
| 2051 | $this->add_responsive_control( |
| 2052 | 'ekit_pricing_features_body_padding', |
| 2053 | [ |
| 2054 | 'label' =>esc_html__( 'Padding', 'elementskit-lite' ), |
| 2055 | 'type' => Controls_Manager::DIMENSIONS, |
| 2056 | 'size_units' => [ 'px', 'em', '%' ], |
| 2057 | 'selectors' => [ |
| 2058 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-content' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 2059 | ], |
| 2060 | ] |
| 2061 | ); |
| 2062 | |
| 2063 | $this->add_control( |
| 2064 | 'features_icon_heading', |
| 2065 | [ |
| 2066 | 'label' => esc_html__( 'Icon', 'elementskit-lite' ), |
| 2067 | 'type' => Controls_Manager::HEADING, |
| 2068 | 'separator' => 'before', |
| 2069 | 'condition' => [ |
| 2070 | 'ekit_pricing_content_style!' => 'paragraph', |
| 2071 | ] |
| 2072 | ] |
| 2073 | ); |
| 2074 | |
| 2075 | $this->add_responsive_control( |
| 2076 | 'features_icon_spacing', |
| 2077 | [ |
| 2078 | 'label' => esc_html__( 'Spacing', 'elementskit-lite' ), |
| 2079 | 'type' => Controls_Manager::SLIDER, |
| 2080 | 'condition' => [ |
| 2081 | 'ekit_pricing_content_style!' => 'paragraph', |
| 2082 | ], |
| 2083 | 'default' => [ |
| 2084 | 'size' => 10, |
| 2085 | 'unit' => 'px', |
| 2086 | ], |
| 2087 | 'selectors' => [ |
| 2088 | '{{WRAPPER}} .elementskit-pricing-lists > li > i' => 'padding-right: {{SIZE}}{{UNIT}};', |
| 2089 | '{{WRAPPER}} .elementskit-pricing-lists > li > svg' => 'margin-right: {{SIZE}}{{UNIT}};', |
| 2090 | ] |
| 2091 | ] |
| 2092 | ); |
| 2093 | |
| 2094 | $this->add_responsive_control( |
| 2095 | 'features_icon_align', |
| 2096 | [ |
| 2097 | 'label' => esc_html__( 'Vertical Align', 'elementskit-lite' ), |
| 2098 | 'type' => Controls_Manager::NUMBER, |
| 2099 | 'condition' => [ |
| 2100 | 'ekit_pricing_content_style!' => 'paragraph', |
| 2101 | ], |
| 2102 | 'selectors' => [ |
| 2103 | '{{WRAPPER}} .elementskit-pricing-lists > li > i, {{WRAPPER}} .elementskit-pricing-lists > li > svg' => 'vertical-align: {{SIZE}}px;', |
| 2104 | ] |
| 2105 | ] |
| 2106 | ); |
| 2107 | |
| 2108 | $this->end_controls_section(); |
| 2109 | |
| 2110 | |
| 2111 | //Button style start |
| 2112 | $this->start_controls_section( |
| 2113 | 'ekit_pricing_section_btn_style', |
| 2114 | [ |
| 2115 | 'label' =>esc_html__( 'Button', 'elementskit-lite' ), |
| 2116 | 'tab' => Controls_Manager::TAB_STYLE, |
| 2117 | ] |
| 2118 | ); |
| 2119 | |
| 2120 | $this->add_group_control( |
| 2121 | Group_Control_Typography::get_type(), |
| 2122 | [ |
| 2123 | 'name' => 'ekit_pricing_btn_typography_group', |
| 2124 | 'label' =>esc_html__( 'Typography', 'elementskit-lite' ), |
| 2125 | 'selector' => '{{WRAPPER}} .elementskit-single-pricing a.elementskit-pricing-btn', |
| 2126 | ] |
| 2127 | ); |
| 2128 | $this->add_responsive_control( |
| 2129 | 'ekit_pricing_btn_icon_size', |
| 2130 | [ |
| 2131 | 'label' => esc_html__( 'Icon Size', 'elementskit-lite' ), |
| 2132 | 'type' => Controls_Manager::SLIDER, |
| 2133 | 'size_units' => [ 'px', '%' ], |
| 2134 | 'range' => [ |
| 2135 | 'px' => [ |
| 2136 | 'min' => 1, |
| 2137 | 'max' => 100, |
| 2138 | 'step' => 5, |
| 2139 | ], |
| 2140 | '%' => [ |
| 2141 | 'min' => 1, |
| 2142 | 'max' => 100, |
| 2143 | ], |
| 2144 | ], |
| 2145 | 'selectors' => [ |
| 2146 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-btn i' => 'font-size: {{SIZE}}{{UNIT}};', |
| 2147 | '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-btn svg' => 'font-size: {{SIZE}}{{UNIT}};', |
| 2148 | ], |
| 2149 | ] |
| 2150 | ); |
| 2151 | |
| 2152 | $this->add_responsive_control( |
| 2153 | 'pricing_btn_width', |
| 2154 | [ |
| 2155 | 'label' => __( 'Width (%)', 'elementskit-lite' ), |
| 2156 | 'type' => Controls_Manager::SLIDER, |
| 2157 | 'selectors' => [ |
| 2158 | '{{WRAPPER}} .elementskit-pricing-btn' => 'width: {{SIZE}}%;', |
| 2159 | ], |
| 2160 | ] |
| 2161 | ); |
| 2162 | |
| 2163 | $this->add_responsive_control( |
| 2164 | 'pricing_btn_align', |
| 2165 | [ |
| 2166 | 'label' => __( 'Alignment', 'elementskit-lite' ), |
| 2167 | 'type' => Controls_Manager::CHOOSE, |
| 2168 | 'options' => [ |
| 2169 | 'left' => [ |
| 2170 | 'title' => __( 'Left', 'elementskit-lite' ), |
| 2171 | 'icon' => 'eicon-text-align-left', |
| 2172 | ], |
| 2173 | 'center' => [ |
| 2174 | 'title' => __( 'Center', 'elementskit-lite' ), |
| 2175 | 'icon' => 'eicon-text-align-center', |
| 2176 | ], |
| 2177 | 'right' => [ |
| 2178 | 'title' => __( 'Right', 'elementskit-lite' ), |
| 2179 | 'icon' => 'eicon-text-align-right', |
| 2180 | ], |
| 2181 | ], |
| 2182 | 'selectors' => [ |
| 2183 | '{{WRAPPER}} .elementskit-pricing-btn-wraper' => 'text-align: {{VALUE}};', |
| 2184 | ], |
| 2185 | ] |
| 2186 | ); |
| 2187 | |
| 2188 | $this->add_responsive_control( |
| 2189 | 'ekit_pricing_text_padding', |
| 2190 | [ |
| 2191 | 'label' =>esc_html__( 'Padding', 'elementskit-lite' ), |
| 2192 | 'type' => Controls_Manager::DIMENSIONS, |
| 2193 | 'size_units' => [ 'px', 'em', '%' ], |
| 2194 | 'selectors' => [ |
| 2195 | '{{WRAPPER}} .elementskit-single-pricing a.elementskit-pricing-btn' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 2196 | ], |
| 2197 | ] |
| 2198 | ); |
| 2199 | |
| 2200 | $this->add_control( |
| 2201 | 'ekit_pricing_hr1', |
| 2202 | [ |
| 2203 | 'type' => Controls_Manager::DIVIDER, |
| 2204 | 'style' => 'thick', |
| 2205 | ] |
| 2206 | ); |
| 2207 | |
| 2208 | $this->start_controls_tabs( 'ekit_pricing_tabs_button_style' ); |
| 2209 | |
| 2210 | $this->start_controls_tab( |
| 2211 | 'ekit_pricing_tab_button_normal', |
| 2212 | [ |
| 2213 | 'label' =>esc_html__( 'Normal', 'elementskit-lite' ), |
| 2214 | ] |
| 2215 | ); |
| 2216 | |
| 2217 | $this->add_control( |
| 2218 | 'ekit_pricing_btn_text_color', |
| 2219 | [ |
| 2220 | 'label' =>esc_html__( 'Text Color', 'elementskit-lite' ), |
| 2221 | 'type' => Controls_Manager::COLOR, |
| 2222 | 'selectors' => [ |
| 2223 | '{{WRAPPER}} .elementskit-single-pricing a.elementskit-pricing-btn' => 'color: {{VALUE}};', |
| 2224 | '{{WRAPPER}} .elementskit-single-pricing a.elementskit-pricing-btn svg ' => 'fill: {{VALUE}};', |
| 2225 | ], |
| 2226 | ] |
| 2227 | ); |
| 2228 | $this->add_group_control( |
| 2229 | Group_Control_Background::get_type(), |
| 2230 | array( |
| 2231 | 'name' => 'ekit_pricing_btn_bg_color_group', |
| 2232 | 'exclude' => ['image'], // PHPCS:ignore WordPressVIPMinimum.Performance.WPQueryParams.PostNotIn_exclude |
| 2233 | 'selector' => '{{WRAPPER}} .elementskit-single-pricing a.elementskit-pricing-btn', |
| 2234 | ) |
| 2235 | ); |
| 2236 | |
| 2237 | $this->add_responsive_control( |
| 2238 | 'ekit_pricing_btn_border_style', |
| 2239 | [ |
| 2240 | 'label' => esc_html_x( 'Border Type', 'Border Control', 'elementskit-lite' ), |
| 2241 | 'type' => Controls_Manager::SELECT, |
| 2242 | 'options' => [ |
| 2243 | '' => esc_html__( 'None', 'elementskit-lite' ), |
| 2244 | 'solid' => esc_html_x( 'Solid', 'Border Control', 'elementskit-lite' ), |
| 2245 | 'double' => esc_html_x( 'Double', 'Border Control', 'elementskit-lite' ), |
| 2246 | 'dotted' => esc_html_x( 'Dotted', 'Border Control', 'elementskit-lite' ), |
| 2247 | 'dashed' => esc_html_x( 'Dashed', 'Border Control', 'elementskit-lite' ), |
| 2248 | 'groove' => esc_html_x( 'Groove', 'Border Control', 'elementskit-lite' ), |
| 2249 | ], |
| 2250 | 'selectors' => [ |
| 2251 | '{{WRAPPER}} .elementskit-single-pricing a.elementskit-pricing-btn' => 'border-style: {{VALUE}};', |
| 2252 | ], |
| 2253 | ] |
| 2254 | ); |
| 2255 | |
| 2256 | $this->add_responsive_control( |
| 2257 | 'ekit_pricing_btn_border_dimensions', |
| 2258 | [ |
| 2259 | 'label' => esc_html_x( 'Width', 'Border Control', 'elementskit-lite' ), |
| 2260 | 'type' => Controls_Manager::DIMENSIONS, |
| 2261 | 'selectors' => [ |
| 2262 | '{{WRAPPER}} .elementskit-single-pricing a.elementskit-pricing-btn' => 'border-width: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 2263 | ], |
| 2264 | 'condition' => [ |
| 2265 | 'ekit_pricing_btn_border_style!' => '', |
| 2266 | ] |
| 2267 | ] |
| 2268 | ); |
| 2269 | |
| 2270 | $this->add_control( |
| 2271 | 'ekit_pricing_btn_border_color', |
| 2272 | [ |
| 2273 | 'label' => esc_html_x( 'Border Color', 'Border Control', 'elementskit-lite' ), |
| 2274 | 'type' => Controls_Manager::COLOR, |
| 2275 | 'default' => '', |
| 2276 | 'selectors' => [ |
| 2277 | '{{WRAPPER}} .elementskit-single-pricing a.elementskit-pricing-btn' => 'border-color: {{VALUE}};', |
| 2278 | ], |
| 2279 | 'condition' => [ |
| 2280 | 'ekit_pricing_btn_border_style!' => '', |
| 2281 | ] |
| 2282 | ] |
| 2283 | ); |
| 2284 | |
| 2285 | $this->add_responsive_control( |
| 2286 | 'ekit_pricing_btn_border_radius', |
| 2287 | [ |
| 2288 | 'label' =>esc_html__( 'Border Radius', 'elementskit-lite' ), |
| 2289 | 'type' => Controls_Manager::DIMENSIONS, |
| 2290 | 'size_units' => [ 'px'], |
| 2291 | 'default' => [ |
| 2292 | 'top' => '', |
| 2293 | 'right' => '', |
| 2294 | 'bottom' => '' , |
| 2295 | 'left' => '', |
| 2296 | ], |
| 2297 | 'selectors' => [ |
| 2298 | '{{WRAPPER}} .elementskit-single-pricing a.elementskit-pricing-btn' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 2299 | ], |
| 2300 | ] |
| 2301 | ); |
| 2302 | |
| 2303 | $this->add_group_control( |
| 2304 | Group_Control_Box_Shadow::get_type(), |
| 2305 | [ |
| 2306 | 'name' => 'ekit_pricing_button_box_shadow_group', |
| 2307 | 'selector' => '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-btn', |
| 2308 | ] |
| 2309 | ); |
| 2310 | |
| 2311 | $this->end_controls_tab(); |
| 2312 | |
| 2313 | $this->start_controls_tab( |
| 2314 | 'ekit_pricing_btn_tab_button_hover', |
| 2315 | [ |
| 2316 | 'label' =>esc_html__( 'Hover', 'elementskit-lite' ), |
| 2317 | ] |
| 2318 | ); |
| 2319 | |
| 2320 | $this->add_control( |
| 2321 | 'ekit_pricing_btn_hover_color', |
| 2322 | [ |
| 2323 | 'label' =>esc_html__( 'Text Color', 'elementskit-lite' ), |
| 2324 | 'type' => Controls_Manager::COLOR, |
| 2325 | 'selectors' => [ |
| 2326 | '{{WRAPPER}} .elementskit-single-pricing a.elementskit-pricing-btn:hover' => 'color: {{VALUE}};', |
| 2327 | '{{WRAPPER}} .elementskit-single-pricing a.elementskit-pricing-btn:hover svg' => 'fill: {{VALUE}};', |
| 2328 | ], |
| 2329 | ] |
| 2330 | ); |
| 2331 | |
| 2332 | $this->add_group_control( |
| 2333 | Group_Control_Background::get_type(), |
| 2334 | array( |
| 2335 | 'name' => 'ekit_pricing_btn_bg_hover_color_group', |
| 2336 | 'exclude' => ['image'], // PHPCS:ignore WordPressVIPMinimum.Performance.WPQueryParams.PostNotIn_exclude |
| 2337 | 'selector' => '{{WRAPPER}} .elementskit-single-pricing a.elementskit-pricing-btn:hover', |
| 2338 | ) |
| 2339 | ); |
| 2340 | |
| 2341 | $this->add_responsive_control( |
| 2342 | 'ekit_pricing_btn_hover_border_style', |
| 2343 | [ |
| 2344 | 'label' => esc_html_x( 'Border Type', 'Border Control', 'elementskit-lite' ), |
| 2345 | 'type' => Controls_Manager::SELECT, |
| 2346 | 'options' => [ |
| 2347 | '' => esc_html__( 'None', 'elementskit-lite' ), |
| 2348 | 'solid' => esc_html_x( 'Solid', 'Border Control', 'elementskit-lite' ), |
| 2349 | 'double' => esc_html_x( 'Double', 'Border Control', 'elementskit-lite' ), |
| 2350 | 'dotted' => esc_html_x( 'Dotted', 'Border Control', 'elementskit-lite' ), |
| 2351 | 'dashed' => esc_html_x( 'Dashed', 'Border Control', 'elementskit-lite' ), |
| 2352 | 'groove' => esc_html_x( 'Groove', 'Border Control', 'elementskit-lite' ), |
| 2353 | ], |
| 2354 | 'selectors' => [ |
| 2355 | '{{WRAPPER}} .elementskit-single-pricing a.elementskit-pricing-btn:hover' => 'border-style: {{VALUE}};', |
| 2356 | ], |
| 2357 | ] |
| 2358 | ); |
| 2359 | |
| 2360 | $this->add_responsive_control( |
| 2361 | 'ekit_pricing_btn_hover_border_dimensions', |
| 2362 | [ |
| 2363 | 'label' => esc_html_x( 'Width', 'Border Control', 'elementskit-lite' ), |
| 2364 | 'type' => Controls_Manager::DIMENSIONS, |
| 2365 | 'selectors' => [ |
| 2366 | '{{WRAPPER}} .elementskit-single-pricing a.elementskit-pricing-btn:hover' => 'border-width: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 2367 | ], |
| 2368 | 'condition' => [ |
| 2369 | 'ekit_pricing_btn_hover_border_style!' => '', |
| 2370 | ] |
| 2371 | ] |
| 2372 | ); |
| 2373 | |
| 2374 | $this->add_control( |
| 2375 | 'ekit_pricing_btn_hover_border_color', |
| 2376 | [ |
| 2377 | 'label' => esc_html_x( 'Border Color', 'Border Control', 'elementskit-lite' ), |
| 2378 | 'type' => Controls_Manager::COLOR, |
| 2379 | 'default' => '', |
| 2380 | 'selectors' => [ |
| 2381 | '{{WRAPPER}} a.elementskit-pricing-btn:hover' => 'border-color: {{VALUE}};', |
| 2382 | ], |
| 2383 | 'condition' => [ |
| 2384 | 'ekit_pricing_btn_hover_border_style!' => '', |
| 2385 | ] |
| 2386 | ] |
| 2387 | ); |
| 2388 | |
| 2389 | $this->add_responsive_control( |
| 2390 | 'ekit_pricing_btn_hover_border_radius', |
| 2391 | [ |
| 2392 | 'label' =>esc_html__( 'Border Radius', 'elementskit-lite' ), |
| 2393 | 'type' => Controls_Manager::DIMENSIONS, |
| 2394 | 'size_units' => [ 'px'], |
| 2395 | 'default' => [ |
| 2396 | 'top' => '', |
| 2397 | 'right' => '', |
| 2398 | 'bottom' => '' , |
| 2399 | 'left' => '', |
| 2400 | ], |
| 2401 | 'selectors' => [ |
| 2402 | '{{WRAPPER}} .elementskit-single-pricing a.elementskit-pricing-btn:hover' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};', |
| 2403 | ], |
| 2404 | ] |
| 2405 | ); |
| 2406 | |
| 2407 | $this->add_group_control( |
| 2408 | Group_Control_Box_Shadow::get_type(), |
| 2409 | [ |
| 2410 | 'name' => 'ekit_pricing_button_box_shadow_hover_group', |
| 2411 | 'selector' => '{{WRAPPER}} .elementskit-single-pricing .elementskit-pricing-btn:hover', |
| 2412 | ] |
| 2413 | ); |
| 2414 | |
| 2415 | $this->end_controls_tab(); |
| 2416 | $this->end_controls_tabs(); |
| 2417 | |
| 2418 | $this->end_controls_section(); |
| 2419 | |
| 2420 | // Custom Order Style Start |
| 2421 | $this->start_controls_section( |
| 2422 | 'ekit_pricing_order', |
| 2423 | [ |
| 2424 | 'label' =>esc_html__( 'Custom Ordering', 'elementskit-lite' ), |
| 2425 | 'tab' => Controls_Manager::TAB_STYLE, |
| 2426 | ] |
| 2427 | ); |
| 2428 | $this->add_control( |
| 2429 | 'ekit_pricing_order_enable', |
| 2430 | [ |
| 2431 | 'label' => esc_html__( 'Enable Ordering', 'elementskit-lite' ), |
| 2432 | 'type' => Controls_Manager::SWITCHER, |
| 2433 | 'label_block' => false, |
| 2434 | 'return_value' => 'yes', |
| 2435 | 'default' => 'no', |
| 2436 | ] |
| 2437 | ); |
| 2438 | |
| 2439 | $this->add_control( |
| 2440 | 'ekit_pricing_order_header', |
| 2441 | [ |
| 2442 | 'label' => esc_html__( 'Header', 'elementskit-lite' ), |
| 2443 | 'type' => Controls_Manager::SLIDER, |
| 2444 | 'size_units' => [ 'px'], |
| 2445 | 'range' => [ |
| 2446 | 'px' => [ |
| 2447 | 'min' => 0, |
| 2448 | 'max' => 4, |
| 2449 | 'step' => 1, |
| 2450 | ], |
| 2451 | ], |
| 2452 | 'condition' => [ |
| 2453 | 'ekit_pricing_order_enable' => 'yes', |
| 2454 | ] |
| 2455 | ] |
| 2456 | ); |
| 2457 | |
| 2458 | $this->add_control( |
| 2459 | 'ekit_pricing_order_price', |
| 2460 | [ |
| 2461 | 'label' => esc_html__( 'Price Tag', 'elementskit-lite' ), |
| 2462 | 'type' => Controls_Manager::SLIDER, |
| 2463 | 'size_units' => [ 'px'], |
| 2464 | 'range' => [ |
| 2465 | 'px' => [ |
| 2466 | 'min' => 0, |
| 2467 | 'max' => 4, |
| 2468 | 'step' => 1, |
| 2469 | ], |
| 2470 | ], |
| 2471 | 'condition' => [ |
| 2472 | 'ekit_pricing_order_enable' => 'yes', |
| 2473 | ] |
| 2474 | ] |
| 2475 | ); |
| 2476 | |
| 2477 | $this->add_control( |
| 2478 | 'ekit_pricing_order_features', |
| 2479 | [ |
| 2480 | 'label' => esc_html__( 'Features', 'elementskit-lite' ), |
| 2481 | 'type' => Controls_Manager::SLIDER, |
| 2482 | 'size_units' => [ 'px'], |
| 2483 | 'range' => [ |
| 2484 | 'px' => [ |
| 2485 | 'min' => 0, |
| 2486 | 'max' => 4, |
| 2487 | 'step' => 1, |
| 2488 | ], |
| 2489 | ], |
| 2490 | 'condition' => [ |
| 2491 | 'ekit_pricing_order_enable' => 'yes', |
| 2492 | ] |
| 2493 | ] |
| 2494 | ); |
| 2495 | |
| 2496 | $this->add_control( |
| 2497 | 'ekit_pricing_order_button', |
| 2498 | [ |
| 2499 | 'label' => esc_html__( 'Button', 'elementskit-lite' ), |
| 2500 | 'type' => Controls_Manager::SLIDER, |
| 2501 | 'size_units' => [ 'px'], |
| 2502 | 'range' => [ |
| 2503 | 'px' => [ |
| 2504 | 'min' => 0, |
| 2505 | 'max' => 4, |
| 2506 | 'step' => 1, |
| 2507 | ], |
| 2508 | ], |
| 2509 | 'condition' => [ |
| 2510 | 'ekit_pricing_order_enable' => 'yes', |
| 2511 | ] |
| 2512 | ] |
| 2513 | ); |
| 2514 | $this->end_controls_section(); |
| 2515 | |
| 2516 | $this->insert_pro_message(); |
| 2517 | } |
| 2518 | |
| 2519 | protected function render( ) { |
| 2520 | echo '<div class="ekit-wid-con" >'; |
| 2521 | $this->render_raw(); |
| 2522 | echo '</div>'; |
| 2523 | } |
| 2524 | |
| 2525 | protected function render_raw( ) { |
| 2526 | |
| 2527 | $settings = $this->get_settings_for_display(); |
| 2528 | extract($settings); |
| 2529 | |
| 2530 | $ekit_pricing_title_size_validate = \Elementor\Utils::validate_html_tag( $ekit_pricing_title_size ); |
| 2531 | $table_title = $settings[ 'ekit_pricing_table_title' ]; |
| 2532 | $table_subtitle = $settings[ 'ekit_pricing_table_subtitle' ]; |
| 2533 | $table_content = $settings[ 'ekit_pricing_table_content' ]; |
| 2534 | $currency_icon = $settings[ 'ekit_pricing_currency_icon' ]; |
| 2535 | $table_price = $settings[ 'ekit_pricing_table_price' ]; |
| 2536 | $table_duration = $settings[ 'ekit_pricing_table_duration' ]; |
| 2537 | $table_content_repeater = $settings[ 'ekit_pricing_table_content_repeater' ]; |
| 2538 | $content_style = $settings[ 'ekit_pricing_content_style' ]; |
| 2539 | |
| 2540 | //For button |
| 2541 | $btn_text = $settings['ekit_pricing_btn_text']; |
| 2542 | $btn_class = ($settings['ekit_pricing_button_class'] != '') ? $settings['ekit_pricing_button_class'] : ''; |
| 2543 | $btn_id = ($settings['ekit_pricing_button_id'] != '') ? $settings['ekit_pricing_button_id'] : ''; |
| 2544 | $icon_align = $settings['ekit_pricing_icon_align']; |
| 2545 | |
| 2546 | if ( ! empty( $settings['ekit_pricing_btn_link']['url'] ) ) { |
| 2547 | $this->add_link_attributes( 'button', $settings['ekit_pricing_btn_link'] ); |
| 2548 | } |
| 2549 | |
| 2550 | |
| 2551 | // $tag_align = $settings['ekit_pricing_tag_align']; |
| 2552 | $currency_position = $settings['ekit_pricing_currency_position']; |
| 2553 | $this->add_render_attribute( 'icon-align', 'class', 'xs-button-icon xs-align-icon-' . $settings['ekit_pricing_icon_align'] ); |
| 2554 | |
| 2555 | $image = ''; |
| 2556 | if ( ! empty( $settings['ekit_pricing_image']['url'] ) ) { |
| 2557 | $this->add_render_attribute( 'image', 'src', $settings['ekit_pricing_image']['url'] ); |
| 2558 | $this->add_render_attribute( 'image', 'alt', Control_Media::get_image_alt( $settings['ekit_pricing_image'] ) ); |
| 2559 | |
| 2560 | $image_html = Group_Control_Image_Size::get_attachment_image_html( $settings, 'ekit_pricing_thumbnail', 'ekit_pricing_image' ); |
| 2561 | |
| 2562 | |
| 2563 | $image = '<figure class="elementor-pricing-img">' . $image_html . '</figure>'; |
| 2564 | } |
| 2565 | |
| 2566 | |
| 2567 | // Custom Orders |
| 2568 | $header_order = !empty($ekit_pricing_order_header) ? $ekit_pricing_order_header['size'] : ''; |
| 2569 | $price_order = !empty($ekit_pricing_order_price) ? $ekit_pricing_order_price['size']: ''; |
| 2570 | $features_order = !empty($ekit_pricing_order_features) ? $ekit_pricing_order_features['size'] : ''; |
| 2571 | $button_order = !empty($ekit_pricing_order_button) ? $ekit_pricing_order_button['size'] : ''; |
| 2572 | ?> |
| 2573 | |
| 2574 | |
| 2575 | <div class="elementskit-single-pricing <?php echo esc_attr($settings['ekit_pricing_order_enable'] == 'yes' ? 'd-flex flex-column' : ''); ?>" > |
| 2576 | <div class="elementskit-pricing-header <?php echo esc_attr($header_order ? 'order-'. $header_order : ''); ?>"> |
| 2577 | <?php if($settings['ekit_pricing_icon_type'] == 'image') : ?> |
| 2578 | <?php echo wp_kses($image, \ElementsKit_Lite\Utils::get_kses_array());?> |
| 2579 | <?php endif; ?> |
| 2580 | <?php if($settings['ekit_pricing_icon_type'] == 'icon') : ?> |
| 2581 | <?php |
| 2582 | // new icon |
| 2583 | $migrated = isset( $settings['__fa4_migrated']['ekit_pricing_icons'] ); |
| 2584 | // Check if its a new widget without previously selected icon using the old Icon control |
| 2585 | $is_new = empty( $settings['ekit_pricing_icon'] ); |
| 2586 | if ( $is_new || $migrated ) { |
| 2587 | // new icon |
| 2588 | Icons_Manager::render_icon( $settings['ekit_pricing_icons'], [ 'aria-hidden' => 'true', 'class' => [ |
| 2589 | 'elementkit-pricing-icon', |
| 2590 | 'elementor-animation-'. esc_attr($settings['ekit_pricing_icons_hover_animation']) |
| 2591 | ] ] ); |
| 2592 | } else { |
| 2593 | ?> |
| 2594 | <i class="<?php echo esc_attr($settings['ekit_pricing_icon']); ?> elementkit-pricing-icon <?php echo 'elementor-animation-'. esc_attr($settings['ekit_pricing_icons_hover_animation']); ?>" aria-hidden="true"></i> |
| 2595 | <?php |
| 2596 | } |
| 2597 | ?> |
| 2598 | |
| 2599 | <?php endif; ?> |
| 2600 | |
| 2601 | <?php if($table_title != ''): ?> |
| 2602 | <<?php echo wp_kses($ekit_pricing_title_size_validate, \ElementsKit_Lite\Utils::get_kses_array());?> |
| 2603 | class=" elementskit-pricing-title"><?php echo esc_html($table_title); ?> |
| 2604 | </<?php echo wp_kses($ekit_pricing_title_size_validate, \ElementsKit_Lite\Utils::get_kses_array()); ?>> |
| 2605 | <?php endif; ?> |
| 2606 | <?php if($table_subtitle != ''): ?> |
| 2607 | <p class=" elementskit-pricing-subtitle"><?php echo esc_html($table_subtitle); ?></p> |
| 2608 | <?php endif; ?> |
| 2609 | </div> |
| 2610 | <?php if ($currency_icon != '' && $table_price !== '') { ?> |
| 2611 | <div class=" elementskit-pricing-price-wraper has-tag <?php echo esc_attr($price_order ? 'order-'. $price_order : ''); ?>"> |
| 2612 | <div class="elementskit-pricing-tag"></div> |
| 2613 | <span class="elementskit-pricing-price"> |
| 2614 | <?php if($currency_position == 'before'): ?> |
| 2615 | <sup class="currency"><?php echo esc_html($currency_icon); ?></sup> |
| 2616 | <?php endif; ?> |
| 2617 | <span><?php echo esc_html($table_price); ?></span> |
| 2618 | <?php if($currency_position == 'after'): ?> |
| 2619 | <sup class="currency"><?php echo esc_html($currency_icon); ?></sup> |
| 2620 | <?php endif; ?> |
| 2621 | |
| 2622 | <?php if ( $table_duration !== '' ): ?> |
| 2623 | <sub class="period"><?php echo esc_html($table_duration); ?></sub> |
| 2624 | <?php endif; ?> |
| 2625 | </span> |
| 2626 | </div> |
| 2627 | <?php } ?> |
| 2628 | <div class="elementskit-pricing-content <?php echo esc_attr($features_order ? 'order-'. $features_order : ''); ?>"> |
| 2629 | |
| 2630 | <?php if($content_style == 'paragraph'){ ?> |
| 2631 | <p> <?php echo wp_kses($table_content, \ElementsKit_Lite\Utils::get_kses_array()); ?></p> |
| 2632 | <?php } ?> |
| 2633 | <?php if($content_style == 'list'){ ?> |
| 2634 | <ul class="elementskit-pricing-lists"> |
| 2635 | <?php foreach($table_content_repeater as $repeat){ ?> |
| 2636 | <li class="elementor-repeater-item-<?php echo esc_attr( $repeat[ '_id' ] ); ?>"> |
| 2637 | <?php Icons_Manager::render_icon( $repeat['ekit_pricing_check_icons'], [ 'aria-hidden' => 'true' ] ); ?> |
| 2638 | <?php // echo esc_html($repeat['ekit_pricing_list']); ?> |
| 2639 | |
| 2640 | <?php echo esc_html($repeat['ekit_pricing_list']); ?> |
| 2641 | |
| 2642 | <?php if ( !empty( $repeat[ 'ekit_pricing_list_info' ] ) ): ?> |
| 2643 | <div class="ekit-pricing-list-info" data-info-tip="true"> |
| 2644 | <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16"><path d="M8 16A8 8 0 1 0 8 0a8 8 0 0 0 0 16m.93-9.412-1 4.705c-.07.34.029.533.304.533.194 0 .487-.07.686-.246l-.088.416c-.287.346-.92.598-1.465.598-.703 0-1.002-.422-.808-1.319l.738-3.468c.064-.293.006-.399-.287-.47l-.451-.081.082-.381 2.29-.287zM8 5.5a1 1 0 1 1 0-2 1 1 0 0 1 0 2"/></svg> |
| 2645 | <span></span> |
| 2646 | <p class="ekit-pricing-list-info-content ekit-pricing-<?php echo esc_attr( $this->get_ID() ); ?> ekit-pricing-list-info-<?php echo esc_attr( $repeat[ '_id' ] ); ?>" data-info-tip-content="true"><?php echo esc_attr( $repeat[ 'ekit_pricing_list_info' ] ); ?></p> |
| 2647 | </div> |
| 2648 | <?php endif; ?> |
| 2649 | </li> |
| 2650 | <?php } ?> |
| 2651 | </ul> |
| 2652 | <?php } ?> |
| 2653 | </div> |
| 2654 | <div class="elementskit-pricing-btn-wraper <?php echo esc_attr($button_order ? 'order-'. $button_order : ''); ?>"> |
| 2655 | <a <?php echo $this->get_render_attribute_string( 'button' ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- Already escaped by elementor ?> class="elementskit-pricing-btn <?php echo esc_attr( $btn_class ); ?> ekit-pricing-btn-icon-pos-<?php echo esc_attr($icon_align); ?>" <?php if($settings['ekit_pricing_button_id'] != '') { ?> id="<?php echo esc_attr( $btn_id ); ?>" <?php } ?>> |
| 2656 | <?php |
| 2657 | if ( $settings['ekit_pricing_btn_icons'] != '' && $icon_align == 'left' ): |
| 2658 | // new icon |
| 2659 | $migrated = isset( $settings['__fa4_migrated']['ekit_pricing_btn_icons'] ); |
| 2660 | // Check if its a new widget without previously selected icon using the old Icon control |
| 2661 | $is_new = empty( $settings['ekit_pricing_btn_icon'] ); |
| 2662 | if ( $is_new || $migrated ) { |
| 2663 | // new icon |
| 2664 | Icons_Manager::render_icon( $settings['ekit_pricing_btn_icons'], [ 'aria-hidden' => 'true' ] ); |
| 2665 | } else { |
| 2666 | ?> |
| 2667 | <i class="<?php echo esc_attr($settings['ekit_pricing_btn_icon']); ?>" aria-hidden="true"></i> |
| 2668 | <?php |
| 2669 | } |
| 2670 | endif; |
| 2671 | |
| 2672 | echo esc_html( $btn_text ); |
| 2673 | |
| 2674 | if ( $settings['ekit_pricing_btn_icons'] != '' && $icon_align == 'right' ): |
| 2675 | // new icon |
| 2676 | $migrated = isset( $settings['__fa4_migrated']['ekit_pricing_btn_icons'] ); |
| 2677 | // Check if its a new widget without previously selected icon using the old Icon control |
| 2678 | $is_new = empty( $settings['ekit_pricing_btn_icon'] ); |
| 2679 | if ( $is_new || $migrated ) { |
| 2680 | // new icon |
| 2681 | Icons_Manager::render_icon( $settings['ekit_pricing_btn_icons'], [ 'aria-hidden' => 'true' ] ); |
| 2682 | } else { |
| 2683 | ?> |
| 2684 | <i class="<?php echo esc_attr($settings['ekit_pricing_btn_icon']); ?>" aria-hidden="true"></i> |
| 2685 | <?php |
| 2686 | } |
| 2687 | endif; |
| 2688 | ?> |
| 2689 | </a> |
| 2690 | </div> |
| 2691 | </div> |
| 2692 | |
| 2693 | <?php |
| 2694 | } |
| 2695 | } |
| 2696 |