Skip to content

Instantly share code, notes, and snippets.

@stacyk
Created January 22, 2015 16:47
Show Gist options
  • Save stacyk/305990feae0ee78e53bb to your computer and use it in GitHub Desktop.
Save stacyk/305990feae0ee78e53bb to your computer and use it in GitHub Desktop.
Generated by SassMeister.com.
<form role="search" method="get" class="search-form" action="http://msdn.wdslab.com/">
<label for="search-field">
<span class="screen-reader-text">Search for:</span>
<input type="search" class="search-field" value="" name="s">
</label>
<input type="submit" class="search-submit" value="Search">
</form>
// ----
// Sass (v3.4.9)
// Compass (v1.0.1)
// ----
// SVG Icon Background Settings
// ----------------------------------
@mixin svgicon($img, $width, $height) {
display: inline-block;
background-image: url($img);
background-position: 50% 50%;
background-repeat: no-repeat;
height: $height;
width: $width;
}
$orange: #FF8C00;
$search-height: 38px;
.search-submit {
background-color: $orange;
background-image: url('http://stacykvernmo.com/light/fallback/search.png');
@include svgicon('http://stacykvernmo.com/light/search.svg', $search-height, $search-height);
background-size: 150%;
border: none;
border-radius: 3px;
text-indent: -9999px;
right: 3px;
top: 3px;
}
.search-submit {
background-color: #FF8C00;
background-image: url("http://stacykvernmo.com/light/fallback/search.png");
display: inline-block;
background-image: url("http://stacykvernmo.com/light/search.svg");
background-position: 50% 50%;
background-repeat: no-repeat;
height: 38px;
width: 38px;
background-size: 150%;
border: none;
border-radius: 3px;
text-indent: -9999px;
right: 3px;
top: 3px;
}
<form role="search" method="get" class="search-form" action="http://msdn.wdslab.com/">
<label for="search-field">
<span class="screen-reader-text">Search for:</span>
<input type="search" class="search-field" value="" name="s">
</label>
<input type="submit" class="search-submit" value="Search">
</form>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment