Skip to content

Commit

Permalink
rework markup
Browse files Browse the repository at this point in the history
  • Loading branch information
billerickson committed Aug 25, 2017
1 parent 24b0f28 commit ffdb953
Show file tree
Hide file tree
Showing 9 changed files with 38 additions and 67 deletions.
2 changes: 1 addition & 1 deletion assets/css/main.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion assets/css/main.css.map

Large diffs are not rendered by default.

27 changes: 27 additions & 0 deletions assets/scss/partials/_content-area.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,33 @@
/* Content Area
---------------------------------------------------------------------------------------------------- */

.site-inner {
padding: 20px 0;
@include media(">=medium") {
padding: 40px 0;
}
}

/* Single
--------------------------------------------- */

.layout-standard {

.site-main {
@include make-row;

.entry-header,
.entry-content,
.entry-footer,
.comments-area,
.post-navigation {
@include make-sm-column(12);
@include make-lg-column(10);
@include make-lg-column-offset(1);
}
}
}

/* Entries
--------------------------------------------- */

Expand Down
1 change: 1 addition & 0 deletions footer.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
* @license GPL-2.0+
**/

echo '</div>'; // .site-inner
tha_footer_before();
echo '<footer class="site-footer" role="contentinfo"><div class="wrap">';
echo '<div class="row"><div class="col-md-12">';
Expand Down
1 change: 0 additions & 1 deletion functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
require get_template_directory() . '/inc/tha-theme-hooks.php';
require get_template_directory() . '/inc/wordpress-cleanup.php';
require get_template_directory() . '/inc/helper-functions.php';
require get_template_directory() . '/inc/markup.php';
require get_template_directory() . '/inc/general.php';
require get_template_directory() . '/inc/navigation.php';
//require get_template_directory() . '/inc/sidebar-layouts.php';
Expand Down
1 change: 1 addition & 0 deletions header.php
Original file line number Diff line number Diff line change
Expand Up @@ -38,3 +38,4 @@
echo '</div></div>';
echo '</div></header>';
tha_header_after();
echo '<div class="site-inner" id="main-content">';
5 changes: 5 additions & 0 deletions inc/general.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,11 @@ function ea_archive_body_classes( $classes ) {
$classes[] = 'archive';
}

// Standard layout (content less wide then header/footer)
$standard = apply_filters( 'ea_standard_body_class', is_singular() || is_page() );
if( $standard )
$classes[] = 'layout-standard';

return $classes;
}
add_filter( 'body_class', 'ea_archive_body_classes' );
Expand Down
57 changes: 0 additions & 57 deletions inc/markup.php

This file was deleted.

9 changes: 2 additions & 7 deletions index.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,18 +12,13 @@

tha_content_before();

$classes = apply_filters( 'ea_site_main_class', array( 'col-md-12' ) );
if( !empty( $classes ) )
echo '<div class="' . join( ' ', $classes ) . '">';

echo '<div class="content-area wrap">';
echo '<main class="site-main" role="main">';
tha_content_top();
tha_content_loop();
tha_content_bottom();
echo '</main>';

if( !empty( $classes ) )
echo '</div>';
echo '</div>';

get_sidebar();

Expand Down

0 comments on commit ffdb953

Please sign in to comment.