class-wp-customize-new-menu-section.php 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. <?php
  2. /**
  3. * Customize API: WP_Customize_New_Menu_Section class
  4. *
  5. * @package WordPress
  6. * @subpackage Customize
  7. * @since 4.4.0
  8. * @deprecated 4.9.0 This file is no longer used as of the menu creation UX introduced in #40104.
  9. */
  10. _deprecated_file( basename( __FILE__ ), '4.9.0' );
  11. /**
  12. * Customize Menu Section Class
  13. *
  14. * @since 4.3.0
  15. * @deprecated 4.9.0 This class is no longer used as of the menu creation UX introduced in #40104.
  16. *
  17. * @see WP_Customize_Section
  18. */
  19. class WP_Customize_New_Menu_Section extends WP_Customize_Section {
  20. /**
  21. * Control type.
  22. *
  23. * @since 4.3.0
  24. * @var string
  25. */
  26. public $type = 'new_menu';
  27. /**
  28. * Constructor.
  29. *
  30. * Any supplied $args override class property defaults.
  31. *
  32. * @since 4.9.0
  33. * @deprecated 4.9.0
  34. *
  35. * @param WP_Customize_Manager $manager Customizer bootstrap instance.
  36. * @param string $id A specific ID of the section.
  37. * @param array $args Section arguments.
  38. */
  39. public function __construct( WP_Customize_Manager $manager, $id, array $args = array() ) {
  40. _deprecated_function( __METHOD__, '4.9.0' );
  41. parent::__construct( $manager, $id, $args );
  42. }
  43. /**
  44. * Render the section, and the controls that have been added to it.
  45. *
  46. * @since 4.3.0
  47. * @deprecated 4.9.0
  48. */
  49. protected function render() {
  50. _deprecated_function( __METHOD__, '4.9.0' );
  51. ?>
  52. <li id="accordion-section-<?php echo esc_attr( $this->id ); ?>" class="accordion-section-new-menu">
  53. <button type="button" class="button add-new-menu-item add-menu-toggle" aria-expanded="false">
  54. <?php echo esc_html( $this->title ); ?>
  55. </button>
  56. <ul class="new-menu-section-content"></ul>
  57. </li>
  58. <?php
  59. }
  60. }