Allow heading level to be specified when calling `do_meta_boxes()`
|Reported by:||jdgrimes||Owned by:|
|Focuses:||ui, accessibility, administration||Cc:|
In #33557 the do_meta_boxes() function was updated to use h2 headings instead of h3, for better accessibility for the post meta boxes. However, plugins use meta boxes on a variety of different admin screens with different structures, with the result that the correct heading level will vary from one group of meta boxes to the next. I propose that we introduce a new $heading_level parameter to the do_meta_boxes() function. That will let the heading level be specified for each group of meta boxes independently, resulting in improved document structure of plugin admin screens and thus better accessibility.
The only thing that will need to be considered is that the CSS styles currently probably only apply to h2 and h3 (back-compat) meta box headings. I'd need them to also work with h4 headings as well. I'm not sure if any JS would be affected, but I figure that most JS will be using classes to identify meta box headers.