diff --git src/wp-includes/class-wp-customize-control.php src/wp-includes/class-wp-customize-control.php
index a0abfc5..ae577d1 100644
|
|
class WP_Customize_Control { |
84 | 84 | |
85 | 85 | /** |
86 | 86 | * @access public |
| 87 | * @var bool |
| 88 | */ |
| 89 | public $label_hidden = false; |
| 90 | |
| 91 | /** |
| 92 | * @access public |
87 | 93 | * @var string |
88 | 94 | */ |
89 | 95 | public $description = ''; |
… |
… |
class WP_Customize_Control { |
404 | 410 | * @since 3.4.0 |
405 | 411 | */ |
406 | 412 | protected function render_content() { |
| 413 | $label_class = 'customize-control-title'; |
| 414 | if ( true === $this->label_hidden ) { |
| 415 | $label_class .= ' screen-reader-text'; |
| 416 | } |
407 | 417 | switch( $this->type ) { |
408 | 418 | case 'checkbox': |
409 | 419 | ?> |
… |
… |
class WP_Customize_Control { |
423 | 433 | $name = '_customize-radio-' . $this->id; |
424 | 434 | |
425 | 435 | if ( ! empty( $this->label ) ) : ?> |
426 | | <span class="customize-control-title"><?php echo esc_html( $this->label ); ?></span> |
| 436 | <span class="<?php echo $label_class; ?>"><?php echo esc_html( $this->label ); ?></span> |
427 | 437 | <?php endif; |
428 | 438 | if ( ! empty( $this->description ) ) : ?> |
429 | 439 | <span class="description customize-control-description"><?php echo $this->description ; ?></span> |
… |
… |
class WP_Customize_Control { |
445 | 455 | ?> |
446 | 456 | <label> |
447 | 457 | <?php if ( ! empty( $this->label ) ) : ?> |
448 | | <span class="customize-control-title"><?php echo esc_html( $this->label ); ?></span> |
| 458 | <span class="<?php echo $label_class; ?>"><?php echo esc_html( $this->label ); ?></span> |
449 | 459 | <?php endif; |
450 | 460 | if ( ! empty( $this->description ) ) : ?> |
451 | 461 | <span class="description customize-control-description"><?php echo $this->description; ?></span> |
… |
… |
class WP_Customize_Control { |
464 | 474 | ?> |
465 | 475 | <label> |
466 | 476 | <?php if ( ! empty( $this->label ) ) : ?> |
467 | | <span class="customize-control-title"><?php echo esc_html( $this->label ); ?></span> |
| 477 | <span class="<?php echo $label_class; ?>"><?php echo esc_html( $this->label ); ?></span> |
468 | 478 | <?php endif; |
469 | 479 | if ( ! empty( $this->description ) ) : ?> |
470 | 480 | <span class="description customize-control-description"><?php echo $this->description; ?></span> |
… |
… |
class WP_Customize_Control { |
477 | 487 | ?> |
478 | 488 | <label> |
479 | 489 | <?php if ( ! empty( $this->label ) ) : ?> |
480 | | <span class="customize-control-title"><?php echo esc_html( $this->label ); ?></span> |
| 490 | <span class="<?php echo $label_class; ?>"><?php echo esc_html( $this->label ); ?></span> |
481 | 491 | <?php endif; |
482 | 492 | if ( ! empty( $this->description ) ) : ?> |
483 | 493 | <span class="description customize-control-description"><?php echo $this->description; ?></span> |
… |
… |
class WP_Customize_Control { |
504 | 514 | ?> |
505 | 515 | <label> |
506 | 516 | <?php if ( ! empty( $this->label ) ) : ?> |
507 | | <span class="customize-control-title"><?php echo esc_html( $this->label ); ?></span> |
| 517 | <span class="<?php echo $label_class; ?>"><?php echo esc_html( $this->label ); ?></span> |
508 | 518 | <?php endif; |
509 | 519 | if ( ! empty( $this->description ) ) : ?> |
510 | 520 | <span class="description customize-control-description"><?php echo $this->description; ?></span> |
diff --git src/wp-includes/class-wp-customize-nav-menus.php src/wp-includes/class-wp-customize-nav-menus.php
index adccacd..204b51c 100644
|
|
final class WP_Customize_Nav_Menus { |
566 | 566 | ) ); |
567 | 567 | |
568 | 568 | $this->manager->add_control( 'new_menu_name', array( |
569 | | 'label' => '', |
570 | | 'section' => 'add_menu', |
571 | | 'type' => 'text', |
572 | | 'input_attrs' => array( |
| 569 | 'label' => __( 'New menu name' ), |
| 570 | 'label_hidden' => true, |
| 571 | 'section' => 'add_menu', |
| 572 | 'type' => 'text', |
| 573 | 'input_attrs' => array( |
573 | 574 | 'class' => 'menu-name-field', |
574 | 575 | 'placeholder' => __( 'New menu name' ), |
575 | 576 | ), |