Njw has uploaded a new change for review. https://gerrit.wikimedia.org/r/99436
Change subject: Simplify and rename the HTML & CSS ...................................................................... Simplify and rename the HTML & CSS Change-Id: I829b7e5acdb058253b1a0a683ab09f0a7f30ee90 --- M Erudite.skin.php M assets/erudite.css M assets/erudite20em.css M assets/erudite40em.css M assets/erudite55em.css M assets/erudite60em.css M assets/print.css 7 files changed, 63 insertions(+), 97 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/skins/erudite refs/changes/36/99436/1 diff --git a/Erudite.skin.php b/Erudite.skin.php index 718fd8c..75c5c8a 100644 --- a/Erudite.skin.php +++ b/Erudite.skin.php @@ -68,36 +68,30 @@ <?php if( $this->data['showjumplinks'] ) { ?> <div class="mw-jump"> - <a href="#content"><?php $this->msg( 'erudite-skiptocontent' ) ?></a><?php $this->msg( 'comma-separator' ) ?> + <a href="#bodyContent"><?php $this->msg( 'erudite-skiptocontent' ) ?></a><?php $this->msg( 'comma-separator' ) ?> <a href="#search"><?php $this->msg( 'erudite-skiptosearch' ) ?></a> </div> <?php } ?> - <div id="wrapper" class="hfeed"> - <!-- header --> - <div id="header-wrap"> - - <div id="header" role="banner"> - <h1 id="siteTitle"><a href="<?php echo htmlspecialchars( $this->data['nav_urls']['mainpage']['href'] ) ?>" title="<?php $this->text( 'sitename' ); ?>" rel="home"><?php $this->text( 'sitename' ); ?></a></h1> + <div id="top-wrap" role="banner"> + <h1><a href="<?php echo htmlspecialchars( $this->data['nav_urls']['mainpage']['href'] ) ?>" title="<?php $this->text( 'sitename' ); ?>" rel="home"><?php $this->text( 'sitename' ); ?></a></h1> <div id="tagline"><?php $this->msg( 'tagline' ) ?></div> - </div> - <a id="menubutton" href="#menu">Menu</a> - <div id="access" role="navigation"> + <a id="menubutton" href="#menu">Menu</a> + <div id="nav" role="navigation"> <?php if( array_key_exists( 'navigation', $this->data['sidebar'] ) ) { - echo "<div id='menu'><ul id='menu-urs' class='menu'>\n"; + echo "<ul id='menu'>\n"; foreach( $this->data['sidebar']['navigation'] as $item ) { - printf( '<li id="menu-item-%s" class="menu-item">', Sanitizer::escapeId( $item['id'] ) ); + printf( '<li id="menu-item-%s">', Sanitizer::escapeId( $item['id'] ) ); printf( '<a href="%s">%s</a>', htmlspecialchars( $item['href'] ), htmlspecialchars( $item['text'] ) ); echo "</li>\n"; } - echo "</ul></div>\n"; + echo "</ul>\n"; } ?> + </div> </div> - </div> - <!-- /header --> <div id="mw-js-message"></div> <?php @@ -110,30 +104,24 @@ } ?> - <!-- content --> - <div id="container"> - <div id="content" class="mw-body" role="main"> - <div id="content-container"> - <h1 class="entry-title"><?php $this->html( 'title' ); ?></h1> + <div id="main" role="main"> + <div id="nav-meta"> + <?php + foreach ( $this->data['content_actions'] as $key => $tab ) { + echo $this->makeListItem( $key, $tab, array( 'tag' => 'span' ) ); + echo '<span class="meta-sep">|</span>'; + } + ?> + </div> + + <div id="bodyContent"> + <h1><?php $this->html( 'title' ); ?></h1> <?php if ( $this->data['subtitle'] ) { ?> <div class="subtitle"><?php $this->html( 'subtitle' ) ?></div> <?php } ?> - <div class="entry-meta"> - <?php - foreach ( $this->data['content_actions'] as $key => $tab ) { - echo $this->makeListItem( $key, $tab, array( 'tag' => 'span' ) ); - echo '<span class="meta-sep">|</span>'; - } - ?> - </div> - - <div id="bodyContent" class="entry-content"> - <?php $this->html( 'bodytext' ) ?> <?php $this->html( 'dataAfterContent' ); ?> - - </div> </div> <div id="footer"> @@ -159,13 +147,9 @@ </div> <?php $this->html( 'catlinks' ); ?> - </div> - </div> - <!-- /content --> - <!-- footer --> - <div id="footer-wrap"> + <div id="bottom-wrap"> <div id="footer-wrap-inner"> <div id="primary" class="footer"> @@ -284,10 +268,9 @@ </div> </div> - <!-- /footer --> - </div> <?php $this->printTrail(); ?> + </body> </html> <?php diff --git a/assets/erudite.css b/assets/erudite.css index 5670c4d..7e500f9 100644 --- a/assets/erudite.css +++ b/assets/erudite.css @@ -1,26 +1,16 @@ /* Layout */ -#container, -#header, -#access, +#main, +#top-wrap h1, +#tagline, +#nav, #footer-wrap-inner, .message { width: 90%; max-width: 80em; margin: 0 auto; - position: relative; } -#content { - padding: 1.5em 3.75em 0em; -} - - -/* Use dark stripes around edge to focus on content */ -#wrapper { - background: #fafafa url(images/stripes-dark.svg); -} - -#container { +#main { background: white; border-left-style: solid; border-right-style: solid; @@ -28,8 +18,8 @@ border-width: thin; } -/* Add borders so the sides line up with #container */ -#access { +/* Add borders so the sides line up with #main */ +#nav { border-left-style: solid; border-right-style: solid; border-color: #333; @@ -71,7 +61,7 @@ font-family: 'Linux Libertine', constantia, 'hoefler text', 'palatino linotype', serif; line-height: 1.4; font-size: 1.125em; - background: #fafafa; + background: #fafafa url(images/stripes-dark.svg); color: #333333; } @@ -82,9 +72,9 @@ h4, h5, h6, -.entry-meta, +#nav-meta, #menu, -#footer-wrap { +#bottom-wrap { font-family: 'Linux Biolinum', corbel, 'gill sans', 'gill sans mt', sans-serif; font-weight: normal; text-rendering: optimizeLegibility; @@ -165,7 +155,7 @@ } /* Header */ -#header-wrap { +#top-wrap { background-image: url(images/stripes.svg); background-color: #333333; background-repeat: repeat; @@ -173,14 +163,14 @@ color: #ffffff; } -#header h1 { +#top-wrap h1 { text-decoration: none; font-size: 2.25em; line-height: 1; - margin: 0; } -#header a { +#top-wrap a, +#top-wrap a:visited { color: #ffffff; } @@ -224,7 +214,7 @@ } /* Footer */ -#footer-wrap { +#bottom-wrap { background: #333333; clear: both; color: #ffffff; @@ -284,7 +274,7 @@ display: block; clear: both; text-align: right; - padding: 0.75em 0; + padding: 0.75em 3.75em; font-size: 0.75em; } @@ -293,10 +283,8 @@ } /* Content */ -#content-container { - position: relative; - margin: 0; - clear: both; +#bodyContent { + padding: 1.5em 3.75em; } hr { @@ -312,7 +300,7 @@ border: none; } -.entry-title { +#bodyContent > h1 { color: #555555; margin: 0 0 0.5em; } @@ -364,35 +352,35 @@ } /* Main Links */ -.entry-content a { +#bodyContent a { border-bottom: thin solid #aaaaaa; } -.entry-content a:hover, -.entry-content a:focus { +#bodyContent a:hover, +#bodyContent a:focus { border-color: #555555; } /* Meta (edit links etc.) */ -.entry-meta { +#nav-meta { float: right; + margin: 1.5em 3.75em 0 1em; padding-left: 1em; - margin-left: 1em; border-left: thin solid #aaaaaa; } -.entry-meta span { +#nav-meta span { display: block; font-size: 0.75em; font-style: italic; padding: 0.4em 0; } -.entry-meta .meta-sep { +#nav-meta .meta-sep { display: none; } -#content .printfooter { +.printfooter { display: none; } @@ -443,12 +431,12 @@ } /* Images */ -.entry-content img { +#bodyContent img { padding: 0.25em; margin-bottom: 0.5em; } -.entry-content .gallery a { +#bodyContent .gallery a { border-width: 0; } @@ -456,7 +444,6 @@ table.floatright { clear: right; float: right; - position: relative; margin: 0 0 0.5em 0.5em; border: 0; } @@ -469,7 +456,6 @@ table.floatleft { float: left; clear: left; - position: relative; margin: 0 0.5em 0.5em 0; border: 0; } @@ -637,10 +623,6 @@ img#logo { display: block; margin: 2em auto 0em; -} - -div#bodyContent { - padding-bottom: 1.5em; } /* Ensure edit form doesn't clear the right floated meta diff --git a/assets/erudite20em.css b/assets/erudite20em.css index 83a6877..346f214 100644 --- a/assets/erudite20em.css +++ b/assets/erudite20em.css @@ -1,4 +1,4 @@ /* Disable text justification (user preference) */ -#article, #bodyContent, #mw_content { +#bodyContent { text-align: left !important; } diff --git a/assets/erudite40em.css b/assets/erudite40em.css index ffae547..8e39b54 100644 --- a/assets/erudite40em.css +++ b/assets/erudite40em.css @@ -1,5 +1,5 @@ /* Reduce padding a bit further */ -#content { +#bodyContent { padding: 1em 1em 0em; } diff --git a/assets/erudite55em.css b/assets/erudite55em.css index a182d08..d1947d8 100644 --- a/assets/erudite55em.css +++ b/assets/erudite55em.css @@ -14,7 +14,7 @@ } /* Ensure header doesn't overlap with menu button */ -#header h1 { +#top-wrap h1 { margin-right: 2em; } diff --git a/assets/erudite60em.css b/assets/erudite60em.css index bcb08c7..b3a687b 100644 --- a/assets/erudite60em.css +++ b/assets/erudite60em.css @@ -1,13 +1,14 @@ /* Some of the padding is best dispatched with */ -#container, -#header, -#access, +#main, +#top-wrap h1, +#tagline, +#nav, #footer-wrap-inner, .message { width: 100%; border: 0; } -#content { +#bodyContent { padding: 1em 2em 0em; } diff --git a/assets/print.css b/assets/print.css index 1ecadbe..0d96f0e 100644 --- a/assets/print.css +++ b/assets/print.css @@ -1,8 +1,8 @@ /* Hide navigation elements */ -#header-wrap, +#top-wrap, #mw-js-message, -.entry-meta, -#footer-wrap { +#nav-meta, +#bottom-wrap { display:none; } -- To view, visit https://gerrit.wikimedia.org/r/99436 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I829b7e5acdb058253b1a0a683ab09f0a7f30ee90 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/skins/erudite Gerrit-Branch: master Gerrit-Owner: Njw <nick.wh...@durham.ac.uk> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits