Skip to content
This repository has been archived by the owner on Sep 16, 2019. It is now read-only.

Commit

Permalink
fix sidebar search to use input-group
Browse files Browse the repository at this point in the history
The sidebar should be using the correct foundation element "input-group"
instead of columns to display the search form. This fixes a disparity
betwen the text box and button heights, and makes the field take up the
full sidebar width. This also fixes an extra 15px padding on the sidebar
that shouldn't be there.
  • Loading branch information
Ryan Frawley committed Mar 7, 2016
1 parent 6705713 commit 54c7998
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 11 deletions.
4 changes: 2 additions & 2 deletions library/widget-areas.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ function foundationpress_sidebar_widgets() {
'id' => 'sidebar-widgets',
'name' => __( 'Sidebar widgets', 'foundationpress' ),
'description' => __( 'Drag widgets to this sidebar container.', 'foundationpress' ),
'before_widget' => '<article id="%1$s" class="row widget %2$s"><div class="small-12 columns">',
'after_widget' => '</div></article>',
'before_widget' => '<article id="%1$s" class="widget %2$s">',
'after_widget' => '</article>',
'before_title' => '<h6>',
'after_title' => '</h6>',
));
Expand Down
15 changes: 6 additions & 9 deletions searchform.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,13 @@

do_action( 'foundationpress_before_searchform' ); ?>
<form role="search" method="get" id="searchform" action="<?php echo home_url( '/' ); ?>">
<div class="row collapse">
<?php do_action( 'foundationpress_searchform_top' ); ?>
<div class="small-8 columns">
<input type="text" value="" name="s" id="s" placeholder="<?php esc_attr_e( 'Search', 'foundationpress' ); ?>">
</div>
<?php do_action( 'foundationpress_searchform_top' ); ?>
<div class="input-group">
<input type="text" class="input-group-field" value="" name="s" id="s" placeholder="<?php esc_attr_e( 'Search', 'foundationpress' ); ?>">
<?php do_action( 'foundationpress_searchform_before_search_button' ); ?>
<div class="small-4 columns">
<input type="submit" id="searchsubmit" value="<?php esc_attr_e( 'Search', 'foundationpress' ); ?>" class="prefix button">
<div class="input-group-button">
<input type="submit" id="searchsubmit" value="<?php esc_attr_e( 'Search', 'foundationpress' ); ?>" class="button">
</div>
<?php do_action( 'foundationpress_searchform_after_search_button' ); ?>
</div>
<?php do_action( 'foundationpress_searchform_after_search_button' ); ?>
</form>
<?php do_action( 'foundationpress_after_searchform' );

0 comments on commit 54c7998

Please sign in to comment.