| @@ -1,10 +1,8 @@ | ||
| 1 | 1 | <?php |
| 2 | 2 | |
| 3 | 3 | namespace RadiusTheme\SB\Models; |
| 4 | 4 | |
| 5 | -// use RadiusTheme\SB\Helpers\Fns; | |
| 6 | -use RadiusTheme\SB\Elementor\Helper\ControlHelper; | |
| 7 | 5 | use RadiusTheme\SB\Helpers\Fns; |
| 8 | 6 | use RadiusTheme\SB\Models\Base\ListModel; |
| 9 | 7 | use RadiusTheme\SB\Traits\SingletonTrait; |
| 10 | 8 | |
| @@ -51,8 +49,73 @@ | ||
| 51 | 49 | * @return array |
| 52 | 50 | */ |
| 53 | 51 | protected function raw_list() { |
| 54 | 52 | $list = [ |
| 53 | + 'optimization' => apply_filters( | |
| 54 | + 'rtsb/settings/optimization/options', | |
| 55 | + [ | |
| 56 | + 'id' => 'optimization', | |
| 57 | + 'category' => 'general', | |
| 58 | + 'title' => esc_html__( 'Advanced Optimizations', 'shopbuilder' ), | |
| 59 | + 'package' => $this->pro_version_checker(), | |
| 60 | + 'badge' => 'new', | |
| 61 | + 'active_field' => [ | |
| 62 | + 'disable' => true, | |
| 63 | + ], | |
| 64 | + 'fields' => [ | |
| 65 | + 'optimization_intro' => [ | |
| 66 | + 'id' => 'optimization_intro', | |
| 67 | + 'type' => 'description', | |
| 68 | + 'text' => __( 'Optimize your website for maximum performance from these advanced options. <br /> <span style="color: #dc3545; display: block; margin-top: 10px;">⚠️ Note: After enabling or disabling any of these settings, clear the ShopBuilder cache to ensure changes are applied correctly.</span>', 'shopbuilder' ), | |
| 69 | + ], | |
| 70 | + 'enable_optimization' => [ | |
| 71 | + 'id' => 'enable', | |
| 72 | + 'type' => 'switch', | |
| 73 | + 'label' => esc_html__( 'Enable Asset Optimization?', 'shopbuilder' ), | |
| 74 | + 'help' => esc_html__( 'Enable this option to dynamically load assets (styles, scripts) only when needed, helping to optimize your website’s performance', 'shopbuilder' ), | |
| 75 | + ], | |
| 76 | + 'load_elementor_scripts' => [ | |
| 77 | + 'id' => 'enable', | |
| 78 | + 'type' => 'switch', | |
| 79 | + 'label' => esc_html__( 'Load Elementor Assets?', 'shopbuilder' ), | |
| 80 | + 'help' => __( 'Enable this option to load necessary Elementor assets on your website. <br /> <span style="color: #dc3545;">Turn this off if you are not using Elementor widgets to optimize site performance.</span>', 'shopbuilder' ), | |
| 81 | + 'value' => 'on', | |
| 82 | + 'dependency' => [ | |
| 83 | + 'rules' => [ | |
| 84 | + [ | |
| 85 | + 'item' => 'general.optimization.enable_optimization', | |
| 86 | + 'value' => 'on', | |
| 87 | + 'operator' => '==', | |
| 88 | + ], | |
| 89 | + ], | |
| 90 | + ], | |
| 91 | + ], | |
| 92 | + 'context_asset_loading' => [ | |
| 93 | + 'id' => 'enable', | |
| 94 | + 'type' => 'switch', | |
| 95 | + 'label' => esc_html__( 'Context-Aware Asset Loading?', 'shopbuilder' ), | |
| 96 | + 'help' => esc_html__( 'Enable this option to dynamically Load only the necessary CSS and JS for each page type (e.g., product, cart, checkout). Disabling this option will include all assets globally on every page.', 'shopbuilder' ), | |
| 97 | + 'dependency' => [ | |
| 98 | + 'rules' => [ | |
| 99 | + [ | |
| 100 | + 'item' => 'general.optimization.enable_optimization', | |
| 101 | + 'value' => 'on', | |
| 102 | + 'operator' => '==', | |
| 103 | + ], | |
| 104 | + ], | |
| 105 | + ], | |
| 106 | + ], | |
| 107 | + /** | |
| 108 | + 'load_gutenberg_scripts' => [ | |
| 109 | + 'id' => 'enable', | |
| 110 | + 'type' => 'switch', | |
| 111 | + 'label' => esc_html__( 'Load Gutenberg Scripts?', 'shopbuilder' ), | |
| 112 | + 'help' => esc_html__( 'Switch on to load elementor scripts by dynamically loading scripts', 'shopbuilder' ), | |
| 113 | + ], | |
| 114 | + */ | |
| 115 | + ], | |
| 116 | + ], | |
| 117 | + ), | |
| 55 | 118 | 'notification' => apply_filters( |
| 56 | 119 | 'rtsb/settings/notification/options', |
| 57 | 120 | [ |
| 58 | 121 | 'id' => 'notification', |
| @@ -139,25 +202,8 @@ | ||
| 139 | 202 | 'type' => 'switch', |
| 140 | 203 | 'label' => esc_html__( 'Sharing Button in Single Product Page', 'shopbuilder' ), |
| 141 | 204 | 'help' => esc_html__( 'Enable this option to allow share a product from product page. Woocommerce Supported Sharing plugins added to Hook: woocommerce_share', 'shopbuilder' ), |
| 142 | 205 | ], |
| 143 | - /* | |
| 144 | - * TODO : Implement later. | |
| 145 | - 'share_icon_show_to_product_page' => array( | |
| 146 | - 'id' => 'share_icon_show_to_product_page', | |
| 147 | - 'type' => 'switch', | |
| 148 | - 'label' => esc_html__( 'Sharing Icon in Single Product Page', 'shopbuilder' ), | |
| 149 | - 'dependency' => [ | |
| 150 | - 'rules' => [ | |
| 151 | - [ | |
| 152 | - 'item' => 'general.social_share.share_platforms_to_product_page', | |
| 153 | - 'value' => 'on', | |
| 154 | - 'operator' => '==', // 'operator' => 'any','in', !in' only valid for multiple value // | |
| 155 | - ], | |
| 156 | - ], | |
| 157 | - ], | |
| 158 | - ), | |
| 159 | - */ | |
| 160 | 206 | 'share_icon_layout' => [ |
| 161 | 207 | 'type' => 'select', |
| 162 | 208 | 'value' => 'share-layout1', |
| 163 | 209 | 'label' => esc_html__( 'Share Button Layout', 'shopbuilder' ), |
| @@ -213,13 +259,18 @@ | ||
| 213 | 259 | 'label' => esc_html__( 'Customize Billing Form Fields?', 'shopbuilder' ), |
| 214 | 260 | 'help' => esc_html__( 'Switch on to customize billing form fields.', 'shopbuilder' ), |
| 215 | 261 | ], |
| 216 | 262 | 'fields' => [ |
| 263 | + 'checkout_billing_info' => [ | |
| 264 | + 'id' => 'checkout_billing_info', | |
| 265 | + 'type' => 'title', | |
| 266 | + 'label' => __( 'The below form fields customization will be disabled when the <strong><u>Checkout Fields Editor</u></strong> module is activated.', 'shopbuilder' ), | |
| 267 | + 'customClass' => 'checkout-notice', | |
| 268 | + ], | |
| 217 | 269 | 'billing_first_name_heading' => [ |
| 218 | 270 | 'id' => 'billing_first_name_heading', |
| 219 | 271 | 'type' => 'title', |
| 220 | 272 | 'label' => esc_html__( 'First Name', 'shopbuilder' ), |
| 221 | - // 'tab' => 'name', | |
| 222 | 273 | ], |
| 223 | 274 | 'billing_first_name' => [ |
| 224 | 275 | 'id' => 'billing_first_name', |
| 225 | 276 | 'label' => esc_html__( 'First name', 'shopbuilder' ), |
| @@ -235,9 +286,8 @@ | ||
| 235 | 286 | 'value' => 'required', |
| 236 | 287 | 'label' => 'Required Field', |
| 237 | 288 | ], |
| 238 | 289 | ], |
| 239 | - // 'tab' => 'name', | |
| 240 | 290 | ], |
| 241 | 291 | 'billing_first_name_label' => [ |
| 242 | 292 | 'id' => 'billing_first_name_label', |
| 243 | 293 | 'label' => esc_html__( 'First name Label', 'shopbuilder' ), |
| @@ -242,15 +292,14 @@ | ||
| 242 | 292 | 'id' => 'billing_first_name_label', |
| 243 | 293 | 'label' => esc_html__( 'First name Label', 'shopbuilder' ), |
| 244 | 294 | 'type' => 'text', |
| 245 | 295 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 246 | - // 'tab' => 'name', | |
| 247 | 296 | 'dependency' => [ |
| 248 | 297 | 'rules' => [ |
| 249 | 298 | [ |
| 250 | 299 | 'item' => 'general.billing_form.billing_first_name', |
| 251 | 300 | 'value' => 'show', |
| 252 | - 'operator' => '==', // 'operator' => 'any','in', !in' only valid for multiple value // | |
| 301 | + 'operator' => '==', | |
| 253 | 302 | ], |
| 254 | 303 | ], |
| 255 | 304 | ], |
| 256 | 305 | ], |
| @@ -258,15 +307,14 @@ | ||
| 258 | 307 | 'id' => 'billing_first_name_placeholder', |
| 259 | 308 | 'label' => esc_html__( 'First name Placeholder', 'shopbuilder' ), |
| 260 | 309 | 'type' => 'text', |
| 261 | 310 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 262 | - // 'tab' => 'name', | |
| 263 | 311 | 'dependency' => [ |
| 264 | 312 | 'rules' => [ |
| 265 | 313 | [ |
| 266 | 314 | 'item' => 'general.billing_form.billing_first_name', |
| 267 | 315 | 'value' => 'show', |
| 268 | - 'operator' => '==', // 'operator' => 'any','in', !in' only valid for multiple value // | |
| 316 | + 'operator' => '==', | |
| 269 | 317 | ], |
| 270 | 318 | ], |
| 271 | 319 | ], |
| 272 | 320 | ], |
| @@ -274,9 +322,8 @@ | ||
| 274 | 322 | 'billing_last_name_heading' => [ |
| 275 | 323 | 'id' => 'billing_last_name_heading', |
| 276 | 324 | 'type' => 'title', |
| 277 | 325 | 'label' => esc_html__( 'Last Name', 'shopbuilder' ), |
| 278 | - // 'tab' => 'name', | |
| 279 | 326 | ], |
| 280 | 327 | 'billing_last_name' => [ |
| 281 | 328 | 'id' => 'billing_last_name', |
| 282 | 329 | 'label' => esc_html__( 'Last name', 'shopbuilder' ), |
| @@ -292,9 +339,8 @@ | ||
| 292 | 339 | 'value' => 'required', |
| 293 | 340 | 'label' => 'Required Field', |
| 294 | 341 | ], |
| 295 | 342 | ], |
| 296 | - // 'tab' => 'name', | |
| 297 | 343 | ], |
| 298 | 344 | |
| 299 | 345 | 'billing_last_name_label' => [ |
| 300 | 346 | 'id' => 'billing_last_name_label', |
| @@ -300,9 +346,8 @@ | ||
| 300 | 346 | 'id' => 'billing_last_name_label', |
| 301 | 347 | 'label' => esc_html__( 'Last name label', 'shopbuilder' ), |
| 302 | 348 | 'type' => 'text', |
| 303 | 349 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 304 | - // 'tab' => 'name', | |
| 305 | 350 | 'dependency' => [ |
| 306 | 351 | 'rules' => [ |
| 307 | 352 | [ |
| 308 | 353 | 'item' => 'general.billing_form.billing_last_name', |
| @@ -316,9 +361,8 @@ | ||
| 316 | 361 | 'id' => 'billing_last_name_placeholder', |
| 317 | 362 | 'label' => esc_html__( 'Last name Placeholder', 'shopbuilder' ), |
| 318 | 363 | 'type' => 'text', |
| 319 | 364 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 320 | - // 'tab' => 'name', | |
| 321 | 365 | 'dependency' => [ |
| 322 | 366 | 'rules' => [ |
| 323 | 367 | [ |
| 324 | 368 | 'item' => 'general.billing_form.billing_last_name', |
| @@ -332,9 +376,8 @@ | ||
| 332 | 376 | 'billing_company_heading' => [ |
| 333 | 377 | 'id' => 'billing_company_heading', |
| 334 | 378 | 'type' => 'title', |
| 335 | 379 | 'label' => esc_html__( 'Company', 'shopbuilder' ), |
| 336 | - // 'tab' => 'company', | |
| 337 | 380 | ], |
| 338 | 381 | 'billing_company' => [ |
| 339 | 382 | 'id' => 'billing_company', |
| 340 | 383 | 'label' => esc_html__( 'Company name', 'shopbuilder' ), |
| @@ -353,9 +396,8 @@ | ||
| 353 | 396 | 'value' => 'required', |
| 354 | 397 | 'label' => 'Required Field', |
| 355 | 398 | ], |
| 356 | 399 | ], |
| 357 | - // 'tab' => 'company', | |
| 358 | 400 | ], |
| 359 | 401 | |
| 360 | 402 | 'billing_company_label' => [ |
| 361 | 403 | 'id' => 'billing_company_label', |
| @@ -361,9 +403,8 @@ | ||
| 361 | 403 | 'id' => 'billing_company_label', |
| 362 | 404 | 'label' => esc_html__( 'Company label', 'shopbuilder' ), |
| 363 | 405 | 'type' => 'text', |
| 364 | 406 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 365 | - // 'tab' => 'company', | |
| 366 | 407 | 'dependency' => [ |
| 367 | 408 | 'rules' => [ |
| 368 | 409 | [ |
| 369 | 410 | 'item' => 'general.billing_form.billing_company', |
| @@ -377,9 +418,8 @@ | ||
| 377 | 418 | 'id' => 'billing_company_placeholder', |
| 378 | 419 | 'label' => esc_html__( 'Company Placeholder', 'shopbuilder' ), |
| 379 | 420 | 'type' => 'text', |
| 380 | 421 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 381 | - // 'tab' => 'company', | |
| 382 | 422 | 'dependency' => [ |
| 383 | 423 | 'rules' => [ |
| 384 | 424 | [ |
| 385 | 425 | 'item' => 'general.billing_form.billing_company', |
| @@ -393,9 +433,8 @@ | ||
| 393 | 433 | 'billing_country_heading' => [ |
| 394 | 434 | 'id' => 'billing_country_heading', |
| 395 | 435 | 'type' => 'title', |
| 396 | 436 | 'label' => esc_html__( 'Country', 'shopbuilder' ), |
| 397 | - // 'tab' => 'country', | |
| 398 | 437 | ], |
| 399 | 438 | 'billing_country' => [ |
| 400 | 439 | 'id' => 'billing_country', |
| 401 | 440 | 'label' => esc_html__( 'Country', 'shopbuilder' ), |
| @@ -401,22 +440,18 @@ | ||
| 401 | 440 | 'label' => esc_html__( 'Country', 'shopbuilder' ), |
| 402 | 441 | 'type' => 'checkbox', |
| 403 | 442 | 'orientation' => 'vertical', |
| 404 | 443 | 'value' => [ 'show', 'required' ], |
| 405 | - // 'help' => esc_html__( 'If the Shipping Form is enabled, the Country field is mandatory.', 'shopbuilder' ), | |
| 406 | 444 | 'options' => [ |
| 407 | 445 | [ |
| 408 | 446 | 'value' => 'show', |
| 409 | 447 | 'label' => 'Show Country?', |
| 410 | - // 'disabled' => true, | |
| 411 | 448 | ], |
| 412 | 449 | [ |
| 413 | 450 | 'value' => 'required', |
| 414 | 451 | 'label' => 'Required Field', |
| 415 | - // 'disabled' => true, | |
| 416 | 452 | ], |
| 417 | 453 | ], |
| 418 | - // 'tab' => 'country', | |
| 419 | 454 | ], |
| 420 | 455 | |
| 421 | 456 | 'billing_country_label' => [ |
| 422 | 457 | 'id' => 'billing_country_label', |
| @@ -422,9 +457,8 @@ | ||
| 422 | 457 | 'id' => 'billing_country_label', |
| 423 | 458 | 'label' => esc_html__( 'Country label', 'shopbuilder' ), |
| 424 | 459 | 'type' => 'text', |
| 425 | 460 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 426 | - // 'tab' => 'country', | |
| 427 | 461 | 'dependency' => [ |
| 428 | 462 | 'rules' => [ |
| 429 | 463 | [ |
| 430 | 464 | 'item' => 'general.billing_form.billing_country', |
| @@ -437,9 +471,8 @@ | ||
| 437 | 471 | 'billing_address_1_heading' => [ |
| 438 | 472 | 'id' => 'billing_address_1_heading', |
| 439 | 473 | 'type' => 'title', |
| 440 | 474 | 'label' => esc_html__( 'Address 1', 'shopbuilder' ), |
| 441 | - // 'tab' => 'address', | |
| 442 | 475 | ], |
| 443 | 476 | 'billing_address_1' => [ |
| 444 | 477 | 'id' => 'billing_address_1', |
| 445 | 478 | 'label' => esc_html__( 'Address 1', 'shopbuilder' ), |
| @@ -455,9 +488,8 @@ | ||
| 455 | 488 | 'value' => 'required', |
| 456 | 489 | 'label' => 'Required Field', |
| 457 | 490 | ], |
| 458 | 491 | ], |
| 459 | - // 'tab' => 'address', | |
| 460 | 492 | ], |
| 461 | 493 | |
| 462 | 494 | 'billing_address_1_label' => [ |
| 463 | 495 | 'id' => 'billing_address_1_label', |
| @@ -463,9 +495,8 @@ | ||
| 463 | 495 | 'id' => 'billing_address_1_label', |
| 464 | 496 | 'label' => esc_html__( 'Address 1 label', 'shopbuilder' ), |
| 465 | 497 | 'type' => 'text', |
| 466 | 498 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 467 | - // 'tab' => 'address', | |
| 468 | 499 | 'dependency' => [ |
| 469 | 500 | 'rules' => [ |
| 470 | 501 | [ |
| 471 | 502 | 'item' => 'general.billing_form.billing_address_1', |
| @@ -479,9 +510,8 @@ | ||
| 479 | 510 | 'id' => 'billing_address_1_placeholder', |
| 480 | 511 | 'label' => esc_html__( 'Address 1 Placeholder', 'shopbuilder' ), |
| 481 | 512 | 'type' => 'text', |
| 482 | 513 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 483 | - // 'tab' => 'address', | |
| 484 | 514 | 'dependency' => [ |
| 485 | 515 | 'rules' => [ |
| 486 | 516 | [ |
| 487 | 517 | 'item' => 'general.billing_form.billing_address_1', |
| @@ -494,9 +524,8 @@ | ||
| 494 | 524 | 'billing_address_2_heading' => [ |
| 495 | 525 | 'id' => 'billing_address_2_heading', |
| 496 | 526 | 'type' => 'title', |
| 497 | 527 | 'label' => esc_html__( 'Address 2', 'shopbuilder' ), |
| 498 | - // 'tab' => 'address', | |
| 499 | 528 | 'dependency' => [ |
| 500 | 529 | 'rules' => [ |
| 501 | 530 | [ |
| 502 | 531 | 'item' => 'general.billing_form.billing_address_1', |
| @@ -510,9 +539,8 @@ | ||
| 510 | 539 | 'id' => 'billing_address_2', |
| 511 | 540 | 'label' => esc_html__( 'Address 2', 'shopbuilder' ), |
| 512 | 541 | 'type' => 'checkbox', |
| 513 | 542 | 'orientation' => 'vertical', |
| 514 | - // 'tab' => 'address', | |
| 515 | 543 | 'value' => [ |
| 516 | 544 | 'show', |
| 517 | 545 | 'required' === get_option( 'woocommerce_checkout_address_2_field', 'optional' ) ? 'required' : 'optional', |
| 518 | 546 | ], |
| @@ -538,9 +566,8 @@ | ||
| 538 | 566 | 'id' => 'billing_address_2_label', |
| 539 | 567 | 'label' => esc_html__( 'Address 2 label', 'shopbuilder' ), |
| 540 | 568 | 'type' => 'text', |
| 541 | 569 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 542 | - // 'tab' => 'address', | |
| 543 | 570 | 'dependency' => [ |
| 544 | 571 | 'rules' => [ |
| 545 | 572 | [ |
| 546 | 573 | 'item' => 'general.billing_form.billing_address_1', |
| @@ -559,9 +586,8 @@ | ||
| 559 | 586 | 'id' => 'billing_address_2_placeholder', |
| 560 | 587 | 'label' => esc_html__( 'Address 2 Placeholder', 'shopbuilder' ), |
| 561 | 588 | 'type' => 'text', |
| 562 | 589 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 563 | - // 'tab' => 'address', | |
| 564 | 590 | 'dependency' => [ |
| 565 | 591 | 'rules' => [ |
| 566 | 592 | [ |
| 567 | 593 | 'item' => 'general.billing_form.billing_address_1', |
| @@ -579,9 +605,8 @@ | ||
| 579 | 605 | 'billing_city_heading' => [ |
| 580 | 606 | 'id' => 'billing_city_heading', |
| 581 | 607 | 'type' => 'title', |
| 582 | 608 | 'label' => esc_html__( 'Town / City', 'shopbuilder' ), |
| 583 | - // 'tab' => 'city', | |
| 584 | 609 | ], |
| 585 | 610 | 'billing_city' => [ |
| 586 | 611 | 'id' => 'billing_city', |
| 587 | 612 | 'label' => esc_html__( 'Town / City', 'shopbuilder' ), |
| @@ -587,9 +612,8 @@ | ||
| 587 | 612 | 'label' => esc_html__( 'Town / City', 'shopbuilder' ), |
| 588 | 613 | 'type' => 'checkbox', |
| 589 | 614 | 'orientation' => 'vertical', |
| 590 | 615 | 'value' => [ 'show', 'required' ], |
| 591 | - // 'tab' => 'city', | |
| 592 | 616 | 'options' => [ |
| 593 | 617 | [ |
| 594 | 618 | 'value' => 'show', |
| 595 | 619 | 'label' => 'Show Town / City?', |
| @@ -605,9 +629,8 @@ | ||
| 605 | 629 | 'id' => 'billing_city_label', |
| 606 | 630 | 'label' => esc_html__( 'Town / City label', 'shopbuilder' ), |
| 607 | 631 | 'type' => 'text', |
| 608 | 632 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 609 | - // 'tab' => 'city', | |
| 610 | 633 | 'dependency' => [ |
| 611 | 634 | 'rules' => [ |
| 612 | 635 | [ |
| 613 | 636 | 'item' => 'general.billing_form.billing_city', |
| @@ -621,9 +644,8 @@ | ||
| 621 | 644 | 'id' => 'billing_city_placeholder', |
| 622 | 645 | 'label' => esc_html__( 'City placeholder', 'shopbuilder' ), |
| 623 | 646 | 'type' => 'text', |
| 624 | 647 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 625 | - // 'tab' => 'city', | |
| 626 | 648 | 'dependency' => [ |
| 627 | 649 | 'rules' => [ |
| 628 | 650 | [ |
| 629 | 651 | 'item' => 'general.billing_form.billing_city', |
| @@ -636,9 +658,8 @@ | ||
| 636 | 658 | 'billing_state_heading' => [ |
| 637 | 659 | 'id' => 'billing_city_heading', |
| 638 | 660 | 'type' => 'title', |
| 639 | 661 | 'label' => esc_html__( 'State', 'shopbuilder' ), |
| 640 | - // 'tab' => 'state', | |
| 641 | 662 | ], |
| 642 | 663 | 'billing_state' => [ |
| 643 | 664 | 'id' => 'billing_state', |
| 644 | 665 | 'label' => esc_html__( 'State', 'shopbuilder' ), |
| @@ -654,9 +675,8 @@ | ||
| 654 | 675 | 'value' => 'required', |
| 655 | 676 | 'label' => 'Required Field', |
| 656 | 677 | ], |
| 657 | 678 | ], |
| 658 | - // 'tab' => 'state', | |
| 659 | 679 | ], |
| 660 | 680 | |
| 661 | 681 | 'billing_state_label' => [ |
| 662 | 682 | 'id' => 'billing_state_label', |
| @@ -662,10 +682,8 @@ | ||
| 662 | 682 | 'id' => 'billing_state_label', |
| 663 | 683 | 'label' => esc_html__( 'State label', 'shopbuilder' ), |
| 664 | 684 | 'type' => 'text', |
| 665 | 685 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 666 | - // 'help' => esc_html__( 'Leave empty to set default. If the Shipping Form is enabled, the State field is mandatory.', 'shopbuilder' ), | |
| 667 | - // 'tab' => 'state', | |
| 668 | 686 | 'dependency' => [ |
| 669 | 687 | 'rules' => [ |
| 670 | 688 | [ |
| 671 | 689 | 'item' => 'general.billing_form.billing_state', |
| @@ -678,9 +696,8 @@ | ||
| 678 | 696 | 'billing_postcode_heading' => [ |
| 679 | 697 | 'id' => 'billing_postcode_heading', |
| 680 | 698 | 'type' => 'title', |
| 681 | 699 | 'label' => esc_html__( 'Postcode / ZIP', 'shopbuilder' ), |
| 682 | - // 'tab' => 'postcode', | |
| 683 | 700 | ], |
| 684 | 701 | 'billing_postcode' => [ |
| 685 | 702 | 'id' => 'billing_postcode', |
| 686 | 703 | 'label' => esc_html__( 'Postcode / ZIP', 'shopbuilder' ), |
| @@ -696,9 +713,8 @@ | ||
| 696 | 713 | 'value' => 'required', |
| 697 | 714 | 'label' => 'Required Field', |
| 698 | 715 | ], |
| 699 | 716 | ], |
| 700 | - // 'tab' => 'postcode', | |
| 701 | 717 | ], |
| 702 | 718 | 'billing_postcode_label' => [ |
| 703 | 719 | 'id' => 'billing_postcode_label', |
| 704 | 720 | 'label' => esc_html__( 'Postcode / ZIP label', 'shopbuilder' ), |
| @@ -703,9 +719,8 @@ | ||
| 703 | 719 | 'id' => 'billing_postcode_label', |
| 704 | 720 | 'label' => esc_html__( 'Postcode / ZIP label', 'shopbuilder' ), |
| 705 | 721 | 'type' => 'text', |
| 706 | 722 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 707 | - // 'tab' => 'postcode', | |
| 708 | 723 | 'dependency' => [ |
| 709 | 724 | 'rules' => [ |
| 710 | 725 | [ |
| 711 | 726 | 'item' => 'general.billing_form.billing_postcode', |
| @@ -719,9 +734,8 @@ | ||
| 719 | 734 | 'id' => 'billing_postcode_placeholder', |
| 720 | 735 | 'label' => esc_html__( 'Postcode / ZIP placeholder', 'shopbuilder' ), |
| 721 | 736 | 'type' => 'text', |
| 722 | 737 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 723 | - // 'tab' => 'postcode', | |
| 724 | 738 | 'dependency' => [ |
| 725 | 739 | 'rules' => [ |
| 726 | 740 | [ |
| 727 | 741 | 'item' => 'general.billing_form.billing_postcode', |
| @@ -734,9 +748,8 @@ | ||
| 734 | 748 | 'billing_phone_heading' => [ |
| 735 | 749 | 'id' => 'billing_phone_heading', |
| 736 | 750 | 'type' => 'title', |
| 737 | 751 | 'label' => esc_html__( 'Phone', 'shopbuilder' ), |
| 738 | - // 'tab' => 'phone', | |
| 739 | 752 | ], |
| 740 | 753 | 'billing_phone' => [ |
| 741 | 754 | 'id' => 'billing_phone', |
| 742 | 755 | 'label' => esc_html__( 'Phone', 'shopbuilder' ), |
| @@ -741,9 +754,8 @@ | ||
| 741 | 754 | 'id' => 'billing_phone', |
| 742 | 755 | 'label' => esc_html__( 'Phone', 'shopbuilder' ), |
| 743 | 756 | 'type' => 'checkbox', |
| 744 | 757 | 'orientation' => 'vertical', |
| 745 | - // 'tab' => 'phone', | |
| 746 | 758 | 'value' => [ |
| 747 | 759 | 'show', |
| 748 | 760 | 'required' === get_option( 'woocommerce_checkout_phone_field', 'required' ) ? 'required' : 'optional', |
| 749 | 761 | ], |
| @@ -763,9 +775,8 @@ | ||
| 763 | 775 | 'id' => 'billing_phone_label', |
| 764 | 776 | 'label' => esc_html__( 'Phone field label', 'shopbuilder' ), |
| 765 | 777 | 'type' => 'text', |
| 766 | 778 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 767 | - // 'tab' => 'phone', | |
| 768 | 779 | 'dependency' => [ |
| 769 | 780 | 'rules' => [ |
| 770 | 781 | [ |
| 771 | 782 | 'item' => 'general.billing_form.billing_phone', |
| @@ -779,9 +790,8 @@ | ||
| 779 | 790 | 'id' => 'billing_phone_placeholder', |
| 780 | 791 | 'label' => esc_html__( 'Phone field placeholder', 'shopbuilder' ), |
| 781 | 792 | 'type' => 'text', |
| 782 | 793 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 783 | - // 'tab' => 'phone', | |
| 784 | 794 | 'dependency' => [ |
| 785 | 795 | 'rules' => [ |
| 786 | 796 | [ |
| 787 | 797 | 'item' => 'general.billing_form.billing_phone', |
| @@ -794,9 +804,8 @@ | ||
| 794 | 804 | 'billing_email_heading' => [ |
| 795 | 805 | 'id' => 'billing_email_heading', |
| 796 | 806 | 'type' => 'title', |
| 797 | 807 | 'label' => esc_html__( 'Email', 'shopbuilder' ), |
| 798 | - // 'tab' => 'email', | |
| 799 | 808 | ], |
| 800 | 809 | 'billing_email' => [ |
| 801 | 810 | 'id' => 'billing_email', |
| 802 | 811 | 'label' => esc_html__( 'Email address', 'shopbuilder' ), |
| @@ -801,9 +810,8 @@ | ||
| 801 | 810 | 'id' => 'billing_email', |
| 802 | 811 | 'label' => esc_html__( 'Email address', 'shopbuilder' ), |
| 803 | 812 | 'type' => 'checkbox', |
| 804 | 813 | 'orientation' => 'vertical', |
| 805 | - // 'tab' => 'email', | |
| 806 | 814 | 'value' => [ 'show', 'required' ], |
| 807 | 815 | 'options' => [ |
| 808 | 816 | [ |
| 809 | 817 | 'value' => 'show', |
| @@ -819,9 +827,8 @@ | ||
| 819 | 827 | 'id' => 'billing_email_label', |
| 820 | 828 | 'label' => esc_html__( 'Email address field label', 'shopbuilder' ), |
| 821 | 829 | 'type' => 'text', |
| 822 | 830 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 823 | - // 'tab' => 'email', | |
| 824 | 831 | 'dependency' => [ |
| 825 | 832 | 'rules' => [ |
| 826 | 833 | [ |
| 827 | 834 | 'item' => 'general.billing_form.billing_email', |
| @@ -835,9 +842,8 @@ | ||
| 835 | 842 | 'id' => 'billing_email_placeholder', |
| 836 | 843 | 'label' => esc_html__( 'Email address field placeholder', 'shopbuilder' ), |
| 837 | 844 | 'type' => 'text', |
| 838 | 845 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 839 | - // 'tab' => 'email', | |
| 840 | 846 | 'dependency' => [ |
| 841 | 847 | 'rules' => [ |
| 842 | 848 | [ |
| 843 | 849 | 'item' => 'general.billing_form.billing_email', |
| @@ -862,13 +868,18 @@ | ||
| 862 | 868 | 'label' => esc_html__( 'Customize Shipping form Fields?', 'shopbuilder' ), |
| 863 | 869 | 'help' => esc_html__( 'Switch on to customize shipping form fields.', 'shopbuilder' ), |
| 864 | 870 | ], |
| 865 | 871 | 'fields' => [ |
| 872 | + 'checkout_shipping_info' => [ | |
| 873 | + 'id' => 'checkout_shipping_info', | |
| 874 | + 'type' => 'title', | |
| 875 | + 'label' => __( 'The below form fields customization will be disabled when the <strong><u>Checkout Fields Editor</u></strong> module is activated.', 'shopbuilder' ), | |
| 876 | + 'customClass' => 'checkout-notice', | |
| 877 | + ], | |
| 866 | 878 | 'shipping_first_name_heading' => [ |
| 867 | 879 | 'id' => 'shipping_first_name_heading', |
| 868 | 880 | 'type' => 'title', |
| 869 | 881 | 'label' => esc_html__( 'First Name', 'shopbuilder' ), |
| 870 | - // 'tab' => 'name', | |
| 871 | 882 | ], |
| 872 | 883 | 'shipping_first_name' => [ |
| 873 | 884 | 'id' => 'shipping_first_name', |
| 874 | 885 | 'label' => esc_html__( 'First name', 'shopbuilder' ), |
| @@ -884,9 +895,8 @@ | ||
| 884 | 895 | 'value' => 'required', |
| 885 | 896 | 'label' => 'Required Field', |
| 886 | 897 | ], |
| 887 | 898 | ], |
| 888 | - // 'tab' => 'name', | |
| 889 | 899 | ], |
| 890 | 900 | 'shipping_first_name_label' => [ |
| 891 | 901 | 'id' => 'shipping_first_name_label', |
| 892 | 902 | 'label' => esc_html__( 'First name Label', 'shopbuilder' ), |
| @@ -891,9 +901,8 @@ | ||
| 891 | 901 | 'id' => 'shipping_first_name_label', |
| 892 | 902 | 'label' => esc_html__( 'First name Label', 'shopbuilder' ), |
| 893 | 903 | 'type' => 'text', |
| 894 | 904 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 895 | - // 'tab' => 'name', | |
| 896 | 905 | 'dependency' => [ |
| 897 | 906 | 'rules' => [ |
| 898 | 907 | [ |
| 899 | 908 | 'item' => 'general.shipping_form.shipping_first_name', |
| @@ -907,9 +916,8 @@ | ||
| 907 | 916 | 'id' => 'shipping_first_name_placeholder', |
| 908 | 917 | 'label' => esc_html__( 'First name Placeholder', 'shopbuilder' ), |
| 909 | 918 | 'type' => 'text', |
| 910 | 919 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 911 | - // 'tab' => 'country', | |
| 912 | 920 | 'dependency' => [ |
| 913 | 921 | 'rules' => [ |
| 914 | 922 | [ |
| 915 | 923 | 'item' => 'general.shipping_form.shipping_first_name', |
| @@ -922,9 +930,8 @@ | ||
| 922 | 930 | 'shipping_first_last_heading' => [ |
| 923 | 931 | 'id' => 'shipping_first_last_heading', |
| 924 | 932 | 'type' => 'title', |
| 925 | 933 | 'label' => esc_html__( 'Last Name', 'shopbuilder' ), |
| 926 | - // 'tab' => 'name', | |
| 927 | 934 | ], |
| 928 | 935 | 'shipping_last_name' => [ |
| 929 | 936 | 'id' => 'shipping_last_name', |
| 930 | 937 | 'label' => esc_html__( 'Last name', 'shopbuilder' ), |
| @@ -940,9 +947,8 @@ | ||
| 940 | 947 | 'value' => 'required', |
| 941 | 948 | 'label' => 'Required Field', |
| 942 | 949 | ], |
| 943 | 950 | ], |
| 944 | - // 'tab' => 'name', | |
| 945 | 951 | ], |
| 946 | 952 | |
| 947 | 953 | 'shipping_last_name_label' => [ |
| 948 | 954 | 'id' => 'shipping_last_name_label', |
| @@ -948,9 +954,8 @@ | ||
| 948 | 954 | 'id' => 'shipping_last_name_label', |
| 949 | 955 | 'label' => esc_html__( 'Last name label', 'shopbuilder' ), |
| 950 | 956 | 'type' => 'text', |
| 951 | 957 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 952 | - // 'tab' => 'name', | |
| 953 | 958 | 'dependency' => [ |
| 954 | 959 | 'rules' => [ |
| 955 | 960 | [ |
| 956 | 961 | 'item' => 'general.shipping_form.shipping_last_name', |
| @@ -964,9 +969,8 @@ | ||
| 964 | 969 | 'id' => 'shipping_last_name_placeholder', |
| 965 | 970 | 'label' => esc_html__( 'Last name Placeholder', 'shopbuilder' ), |
| 966 | 971 | 'type' => 'text', |
| 967 | 972 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 968 | - // 'tab' => 'country', | |
| 969 | 973 | 'dependency' => [ |
| 970 | 974 | 'rules' => [ |
| 971 | 975 | [ |
| 972 | 976 | 'item' => 'general.shipping_form.shipping_last_name', |
| @@ -979,9 +983,8 @@ | ||
| 979 | 983 | 'shipping_company_heading' => [ |
| 980 | 984 | 'id' => 'shipping_company_heading', |
| 981 | 985 | 'type' => 'title', |
| 982 | 986 | 'label' => esc_html__( 'Company', 'shopbuilder' ), |
| 983 | - // 'tab' => 'name', | |
| 984 | 987 | ], |
| 985 | 988 | 'shipping_company' => [ |
| 986 | 989 | 'id' => 'shipping_company', |
| 987 | 990 | 'label' => esc_html__( 'Company name', 'shopbuilder' ), |
| @@ -997,9 +1000,8 @@ | ||
| 997 | 1000 | 'value' => 'required', |
| 998 | 1001 | 'label' => 'Required Field', |
| 999 | 1002 | ], |
| 1000 | 1003 | ], |
| 1001 | - // 'tab' => 'company', | |
| 1002 | 1004 | ], |
| 1003 | 1005 | |
| 1004 | 1006 | 'shipping_company_label' => [ |
| 1005 | 1007 | 'id' => 'shipping_company_label', |
| @@ -1005,9 +1007,8 @@ | ||
| 1005 | 1007 | 'id' => 'shipping_company_label', |
| 1006 | 1008 | 'label' => esc_html__( 'Company label', 'shopbuilder' ), |
| 1007 | 1009 | 'type' => 'text', |
| 1008 | 1010 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 1009 | - // 'tab' => 'company', | |
| 1010 | 1011 | 'dependency' => [ |
| 1011 | 1012 | 'rules' => [ |
| 1012 | 1013 | [ |
| 1013 | 1014 | 'item' => 'general.shipping_form.shipping_company', |
| @@ -1021,9 +1022,8 @@ | ||
| 1021 | 1022 | 'id' => 'shipping_company_placeholder', |
| 1022 | 1023 | 'label' => esc_html__( 'Shipping company Placeholder', 'shopbuilder' ), |
| 1023 | 1024 | 'type' => 'text', |
| 1024 | 1025 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 1025 | - // 'tab' => 'country', | |
| 1026 | 1026 | 'dependency' => [ |
| 1027 | 1027 | 'rules' => [ |
| 1028 | 1028 | [ |
| 1029 | 1029 | 'item' => 'general.shipping_form.shipping_company', |
| @@ -1036,9 +1036,8 @@ | ||
| 1036 | 1036 | 'shipping_country_heading' => [ |
| 1037 | 1037 | 'id' => 'shipping_country_heading', |
| 1038 | 1038 | 'type' => 'title', |
| 1039 | 1039 | 'label' => esc_html__( 'Country', 'shopbuilder' ), |
| 1040 | - // 'tab' => 'name', | |
| 1041 | 1040 | ], |
| 1042 | 1041 | 'shipping_country' => [ |
| 1043 | 1042 | 'id' => 'shipping_country', |
| 1044 | 1043 | 'label' => esc_html__( 'Country', 'shopbuilder' ), |
| @@ -1048,17 +1047,14 @@ | ||
| 1048 | 1047 | 'options' => [ |
| 1049 | 1048 | [ |
| 1050 | 1049 | 'value' => 'show', |
| 1051 | 1050 | 'label' => 'Show Country?', |
| 1052 | - // 'disabled' => true, | |
| 1053 | 1051 | ], |
| 1054 | 1052 | [ |
| 1055 | 1053 | 'value' => 'required', |
| 1056 | 1054 | 'label' => 'Required Field', |
| 1057 | - // 'disabled' => true, | |
| 1058 | 1055 | ], |
| 1059 | 1056 | ], |
| 1060 | - // 'tab' => 'country', | |
| 1061 | 1057 | ], |
| 1062 | 1058 | |
| 1063 | 1059 | 'shipping_country_label' => [ |
| 1064 | 1060 | 'id' => 'shipping_country_label', |
| @@ -1078,9 +1074,8 @@ | ||
| 1078 | 1074 | 'shipping_address_1_heading' => [ |
| 1079 | 1075 | 'id' => 'shipping_address_1_heading', |
| 1080 | 1076 | 'type' => 'title', |
| 1081 | 1077 | 'label' => esc_html__( 'Address 1', 'shopbuilder' ), |
| 1082 | - // 'tab' => 'name', | |
| 1083 | 1078 | ], |
| 1084 | 1079 | 'shipping_address_1' => [ |
| 1085 | 1080 | 'id' => 'shipping_address_1', |
| 1086 | 1081 | 'label' => esc_html__( 'Address 1', 'shopbuilder' ), |
| @@ -1096,9 +1091,8 @@ | ||
| 1096 | 1091 | 'value' => 'required', |
| 1097 | 1092 | 'label' => 'Required Field', |
| 1098 | 1093 | ], |
| 1099 | 1094 | ], |
| 1100 | - // 'tab' => 'country', | |
| 1101 | 1095 | ], |
| 1102 | 1096 | |
| 1103 | 1097 | 'shipping_address_1_label' => [ |
| 1104 | 1098 | 'id' => 'shipping_address_1_label', |
| @@ -1104,9 +1098,8 @@ | ||
| 1104 | 1098 | 'id' => 'shipping_address_1_label', |
| 1105 | 1099 | 'label' => esc_html__( 'Address 1 label', 'shopbuilder' ), |
| 1106 | 1100 | 'type' => 'text', |
| 1107 | 1101 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 1108 | - // 'tab' => 'country', | |
| 1109 | 1102 | 'dependency' => [ |
| 1110 | 1103 | 'rules' => [ |
| 1111 | 1104 | [ |
| 1112 | 1105 | 'item' => 'general.shipping_form.shipping_address_1', |
| @@ -1120,9 +1113,8 @@ | ||
| 1120 | 1113 | 'id' => 'shipping_address_1_placeholder', |
| 1121 | 1114 | 'label' => esc_html__( 'Address 1 Placeholder', 'shopbuilder' ), |
| 1122 | 1115 | 'type' => 'text', |
| 1123 | 1116 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 1124 | - // 'tab' => 'country', | |
| 1125 | 1117 | 'dependency' => [ |
| 1126 | 1118 | 'rules' => [ |
| 1127 | 1119 | [ |
| 1128 | 1120 | 'item' => 'general.shipping_form.shipping_address_1', |
| @@ -1135,9 +1127,8 @@ | ||
| 1135 | 1127 | 'shipping_address_2_heading' => [ |
| 1136 | 1128 | 'id' => 'shipping_address_2_heading', |
| 1137 | 1129 | 'type' => 'title', |
| 1138 | 1130 | 'label' => esc_html__( 'Address 2', 'shopbuilder' ), |
| 1139 | - // 'tab' => 'name', | |
| 1140 | 1131 | 'dependency' => [ |
| 1141 | 1132 | 'rules' => [ |
| 1142 | 1133 | [ |
| 1143 | 1134 | 'item' => 'general.shipping_form.shipping_address_1', |
| @@ -1159,9 +1150,8 @@ | ||
| 1159 | 1150 | 'label' => 'Show Address field?', |
| 1160 | 1151 | ], |
| 1161 | 1152 | ], |
| 1162 | 1153 | 'help' => esc_html__( 'if "Address 1" is hidden then this field also hides.', 'shopbuilder' ), |
| 1163 | - // 'tab' => 'country', | |
| 1164 | 1154 | 'dependency' => [ |
| 1165 | 1155 | 'rules' => [ |
| 1166 | 1156 | [ |
| 1167 | 1157 | 'item' => 'general.shipping_form.shipping_address_1', |
| @@ -1176,9 +1166,8 @@ | ||
| 1176 | 1166 | 'id' => 'shipping_address_2_label', |
| 1177 | 1167 | 'label' => esc_html__( 'Address 2 label', 'shopbuilder' ), |
| 1178 | 1168 | 'type' => 'text', |
| 1179 | 1169 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 1180 | - // 'tab' => 'country', | |
| 1181 | 1170 | 'dependency' => [ |
| 1182 | 1171 | 'rules' => [ |
| 1183 | 1172 | [ |
| 1184 | 1173 | 'item' => 'general.shipping_form.shipping_address_1', |
| @@ -1197,9 +1186,8 @@ | ||
| 1197 | 1186 | 'id' => 'shipping_address_2_placeholder', |
| 1198 | 1187 | 'label' => esc_html__( 'Address 2 Placeholder', 'shopbuilder' ), |
| 1199 | 1188 | 'type' => 'text', |
| 1200 | 1189 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 1201 | - // 'tab' => 'country', | |
| 1202 | 1190 | 'dependency' => [ |
| 1203 | 1191 | 'rules' => [ |
| 1204 | 1192 | [ |
| 1205 | 1193 | 'item' => 'general.shipping_form.shipping_address_1', |
| @@ -1217,9 +1205,8 @@ | ||
| 1217 | 1205 | 'shipping_city_heading' => [ |
| 1218 | 1206 | 'id' => 'shipping_city_heading', |
| 1219 | 1207 | 'type' => 'title', |
| 1220 | 1208 | 'label' => esc_html__( 'Town / City', 'shopbuilder' ), |
| 1221 | - // 'tab' => 'name', | |
| 1222 | 1209 | ], |
| 1223 | 1210 | 'shipping_city' => [ |
| 1224 | 1211 | 'id' => 'shipping_city', |
| 1225 | 1212 | 'label' => esc_html__( 'Town / City', 'shopbuilder' ), |
| @@ -1235,9 +1222,8 @@ | ||
| 1235 | 1222 | 'value' => 'required', |
| 1236 | 1223 | 'label' => 'Required Field', |
| 1237 | 1224 | ], |
| 1238 | 1225 | ], |
| 1239 | - // 'tab' => 'country', | |
| 1240 | 1226 | ], |
| 1241 | 1227 | 'shipping_city_label' => [ |
| 1242 | 1228 | 'id' => 'shipping_city_label', |
| 1243 | 1229 | 'label' => esc_html__( 'Town / City label', 'shopbuilder' ), |
| @@ -1242,9 +1228,8 @@ | ||
| 1242 | 1228 | 'id' => 'shipping_city_label', |
| 1243 | 1229 | 'label' => esc_html__( 'Town / City label', 'shopbuilder' ), |
| 1244 | 1230 | 'type' => 'text', |
| 1245 | 1231 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 1246 | - // 'tab' => 'country', | |
| 1247 | 1232 | 'dependency' => [ |
| 1248 | 1233 | 'rules' => [ |
| 1249 | 1234 | [ |
| 1250 | 1235 | 'item' => 'general.shipping_form.shipping_city', |
| @@ -1258,9 +1243,8 @@ | ||
| 1258 | 1243 | 'id' => 'shipping_city_placeholder', |
| 1259 | 1244 | 'label' => esc_html__( 'Shipping city placeholder', 'shopbuilder' ), |
| 1260 | 1245 | 'type' => 'text', |
| 1261 | 1246 | 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), |
| 1262 | - // 'tab' => 'country', | |
| 1263 | 1247 | 'dependency' => [ |
| 1264 | 1248 | 'rules' => [ |
| 1265 | 1249 | [ |
| 1266 | 1250 | 'item' => 'general.shipping_form.shipping_city', |
| @@ -1273,9 +1257,8 @@ | ||
| 1273 | 1257 | 'shipping_state_heading' => [ |
| 1274 | 1258 | 'id' => 'shipping_state_heading', |
| 1275 | 1259 | 'type' => 'title', |
| 1276 | 1260 | 'label' => esc_html__( 'Others', 'shopbuilder' ), |
| 1277 | - // 'tab' => 'name', | |
| 1278 | 1261 | ], |
| 1279 | 1262 | 'shipping_state' => [ |
| 1280 | 1263 | 'id' => 'shipping_state', |
| 1281 | 1264 | 'label' => esc_html__( 'State', 'shopbuilder' ), |
| @@ -1291,33 +1274,9 @@ | ||
| 1291 | 1274 | 'value' => 'required', |
| 1292 | 1275 | 'label' => 'Required Field', |
| 1293 | 1276 | ], |
| 1294 | 1277 | ], |
| 1295 | - // 'tab' => 'country', | |
| 1296 | 1278 | ], |
| 1297 | - // | |
| 1298 | - // 'shipping_state_label' => [ | |
| 1299 | - // 'id' => 'shipping_state_label', | |
| 1300 | - // 'label' => esc_html__( 'State label', 'shopbuilder' ), | |
| 1301 | - // 'type' => 'text', | |
| 1302 | - // 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), | |
| 1303 | - // 'tab' => 'country', | |
| 1304 | - // 'dependency' => [ | |
| 1305 | - // 'rules' => [ | |
| 1306 | - // [ | |
| 1307 | - // 'item' => 'general.shipping_form.shipping_state', | |
| 1308 | - // 'value' => 'show', | |
| 1309 | - // 'operator' => '==', // 'operator' => 'any','in', !in' only valid for multiple value // | |
| 1310 | - // ], | |
| 1311 | - // ], | |
| 1312 | - // ], | |
| 1313 | - // ], | |
| 1314 | - // 'shipping_postcode_heading' => [ | |
| 1315 | - // 'id' => 'shipping_postcode_heading', | |
| 1316 | - // 'type' => 'title', | |
| 1317 | - // 'label' => esc_html__( 'Postcode / ZIP', 'shopbuilder' ), | |
| 1318 | - // 'tab' => 'name', | |
| 1319 | - // ], | |
| 1320 | 1279 | 'shipping_postcode' => [ |
| 1321 | 1280 | 'id' => 'shipping_postcode', |
| 1322 | 1281 | 'label' => esc_html__( 'Postcode / ZIP', 'shopbuilder' ), |
| 1323 | 1282 | 'type' => 'checkbox', |
| @@ -1328,47 +1287,18 @@ | ||
| 1328 | 1287 | 'value' => 'show', |
| 1329 | 1288 | 'label' => 'Show Postcode / ZIP?', |
| 1330 | 1289 | ], |
| 1331 | 1290 | ], |
| 1332 | - // 'tab' => 'country', | |
| 1333 | 1291 | ], |
| 1334 | - // 'shipping_postcode_label' => [ | |
| 1335 | - // 'id' => 'shipping_postcode_label', | |
| 1336 | - // 'label' => esc_html__( 'Postcode / ZIP label', 'shopbuilder' ), | |
| 1337 | - // 'type' => 'text', | |
| 1338 | - // 'help' => esc_html__( 'Leave empty to set default. ', 'shopbuilder' ), | |
| 1339 | - // 'tab' => 'country', | |
| 1340 | - // 'dependency' => [ | |
| 1341 | - // 'rules' => [ | |
| 1342 | - // [ | |
| 1343 | - // 'item' => 'general.shipping_form.shipping_postcode', | |
| 1344 | - // 'value' => 'show', | |
| 1345 | - // 'operator' => '==', // 'operator' => 'any','in', !in' only valid for multiple value // | |
| 1346 | - // ], | |
| 1347 | - // ], | |
| 1348 | - // ], | |
| 1349 | - // ], | |
| 1350 | - // 'shipping_postcode_placeholder' => [ | |
| 1351 | - // 'id' => 'shipping_postcode_placeholder', | |
| 1352 | - // 'label' => esc_html__( 'Postcode / ZIP placeholder', 'shopbuilder' ), | |
| 1353 | - // 'type' => 'text', | |
| 1354 | - // 'help' => esc_html__( 'Leave empty to set default.', 'shopbuilder' ), | |
| 1355 | - // 'tab' => 'country', | |
| 1356 | - // 'dependency' => [ | |
| 1357 | - // 'rules' => [ | |
| 1358 | - // [ | |
| 1359 | - // 'item' => 'general.shipping_form.shipping_postcode', | |
| 1360 | - // 'value' => 'show', | |
| 1361 | - // 'operator' => '==', // 'operator' => 'any','in', !in' only valid for multiple value // | |
| 1362 | - // ], | |
| 1363 | - // ], | |
| 1364 | - // ], | |
| 1365 | - // ], | |
| 1366 | 1292 | |
| 1367 | 1293 | ], |
| 1368 | 1294 | ] |
| 1369 | 1295 | ), |
| 1370 | 1296 | ]; |
| 1297 | + | |
| 1298 | + if ( ! defined( 'ELEMENTOR_VERSION' ) ) { | |
| 1299 | + unset( $list['optimization']['fields']['load_elementor_scripts'] ); | |
| 1300 | + } | |
| 1371 | 1301 | |
| 1372 | 1302 | return apply_filters( 'rtsb/core/general_settings/raw_list', $list ); |
| 1373 | 1303 | } |
| 1374 | 1304 | } |