For challenges like implementing new skins which are making use of HTML5 sectioning elements main, footer or nav and for interoperability between skins code should limited to only ids and classes and remove div mentions.
Proposal
- div#content becomes .mw-body, on some exceptions in order to prevent unforeseeable breakage #content.mw-body,
- Wikimedia deployed
- Documentation (enwiki, MediaWiki, ex div#content)
- Tech News Note on User styles (possibly scripts), examplified on enwiki
Current .mw-body selector, 2020-03-23 | core | Vector | MinervaNeue | Monobook | Timeless | Modern | CologneBlue |
---|---|---|---|---|---|---|---|
div#content | |||||||
#content or id equiv | #mw_contentholder | #article | |||||
.mw-body | |||||||
Note, CologneBlue also features #content, but it's used on parent element of #article.mw-body
Note, MinervaNeue uses .mw-body > .content over #bodyContent
- div.portal becomes .portal
- div#footer becomes .mw-footer, in rare occasions remains only #footer
Related
T240489: [Epic] Determine the optimum Vector DOM structure for a11y and performance