prettyPhoto.scss coding standards. #5606

This commit is contained in:
James Koster 2014-11-13 09:47:34 +00:00
parent 1c552374be
commit 72f5c80121
1 changed files with 382 additions and 295 deletions

View File

@ -6,8 +6,8 @@
// Load the WooCommerce font // Load the WooCommerce font
@font-face { @font-face {
font-family: 'WooCommerce'; font-family: 'WooCommerce';
src:url('../fonts/WooCommerce.eot'); src: url('../fonts/WooCommerce.eot');
src:url('../fonts/WooCommerce.eot?#iefix') format('embedded-opentype'), src: url('../fonts/WooCommerce.eot?#iefix') format('embedded-opentype'),
url('../fonts/WooCommerce.woff') format('woff'), url('../fonts/WooCommerce.woff') format('woff'),
url('../fonts/WooCommerce.ttf') format('truetype'), url('../fonts/WooCommerce.ttf') format('truetype'),
url('../fonts/WooCommerce.svg#WooCommerce') format('svg'); url('../fonts/WooCommerce.svg#WooCommerce') format('svg');
@ -18,14 +18,15 @@
// Mixins // Mixins
@mixin button() { @mixin button() {
border-radius: 100%; border-radius: 100%;
height:1em; height: 1em;
width:1em; width: 1em;
text-shadow:0 1px 2px rgba(0,0,0,0.5); text-shadow: 0 1px 2px rgba(0,0,0,0.5);
background-color: #444; background-color: #444;
color: #fff !important; color: #fff !important;
font-size:16px !important; font-size: 16px !important;
line-height: 1em; line-height: 1em;
@include transition(); @include transition();
&:hover { &:hover {
background-color: #000; background-color: #000;
} }
@ -37,31 +38,36 @@ div.pp_woocommerce {
background: #fff; background: #fff;
border-radius: 3px; border-radius: 3px;
box-shadow: 0 1px 30px rgba(0,0,0,0.25); box-shadow: 0 1px 30px rgba(0,0,0,0.25);
padding:20px 0; padding: 20px 0;
@include clearfix(); @include clearfix();
} }
.pp_loaderIcon { .pp_loaderIcon {
background: url(../images/ajax-loader.gif) center no-repeat; background: url(../images/ajax-loader.gif) center no-repeat;
} }
div.ppt { div.ppt {
color: black; color: black;
} }
.pp_gallery { .pp_gallery {
ul { ul {
li { li {
a { a {
border:1px solid rgba(0,0,0,0.5); border: 1px solid rgba(0,0,0,0.5);
background: #fff; background: #fff;
box-shadow: 0 1px 2px rgba(0,0,0,0.2); box-shadow: 0 1px 2px rgba(0,0,0,0.2);
border-radius: 2px; border-radius: 2px;
display: block; display: block;
&:hover { &:hover {
border-color:#000; border-color: #000;
} }
} }
&.selected { &.selected {
a { a {
border-color:#000; border-color: #000;
} }
} }
} }
@ -69,7 +75,8 @@ div.pp_woocommerce {
} }
// Next / Previous // Next / Previous
.pp_previous, .pp_next { .pp_previous,
.pp_next {
&:before { &:before {
@include button(); @include button();
font-family: 'WooCommerce'; font-family: 'WooCommerce';
@ -77,433 +84,513 @@ div.pp_woocommerce {
text-indent: 0; text-indent: 0;
display: none; display: none;
position: absolute; position: absolute;
top:50%; top: 50%;
margin-top:-10px; margin-top: -10px;
text-align: center; text-align: center;
} }
&:hover { &:hover {
&:before { &:before {
display: block; display: block;
} }
} }
} }
.pp_previous { .pp_previous {
&:before { &:before {
left:1em; left: 1em;
} }
} }
.pp_next { .pp_next {
&:before { &:before {
right:1em; right: 1em;
font-family: 'WooCommerce'; font-family: 'WooCommerce';
content: "\e008"; content: "\e008";
} }
} }
.pp_details { .pp_details {
margin:0; margin: 0;
padding-top:1em; padding-top: 1em;
} }
.pp_nav, .pp_description {
font-size:14px; .pp_nav,
.pp_description {
font-size: 14px;
} }
.pp_nav, .pp_nav p, .pp_play, .pp_nav .pp_pause, .pp_arrow_previous, .pp_arrow_next {
margin:0; .pp_nav,
.pp_nav p,
.pp_play,
.pp_nav .pp_pause,
.pp_arrow_previous,
.pp_arrow_next {
margin: 0;
} }
// Navigation // Navigation
.pp_nav { .pp_nav {
margin-right:1em; margin-right: 1em;
position: relative; position: relative;
} }
.pp_close { .pp_close {
@include button(); @include button();
top:-.5em; top: -.5em;
right:-.5em; right: -.5em;
font-size:1.618em !important; font-size: 1.618em !important;
&:before { &:before {
font-family: 'WooCommerce'; font-family: 'WooCommerce';
content:"\e013"; content: "\e013";
display: block; display: block;
position: absolute; position: absolute;
top:0; top: 0;
left:0; left: 0;
right:0; right: 0;
bottom:0; bottom: 0;
text-align: center; text-align: center;
text-indent: 0; text-indent: 0;
} }
} }
// Buttons // Buttons
.pp_arrow_previous, .pp_arrow_next { .pp_arrow_previous,
.pp_arrow_next {
@include button(); @include button();
position: relative; position: relative;
margin-top:-1px; margin-top: -1px;
&:before { &:before {
font-family: 'WooCommerce'; font-family: 'WooCommerce';
content:"\e00b"; content: "\e00b";
display: block; display: block;
position: absolute; position: absolute;
top:0; top: 0;
left:0; left: 0;
right:0; right: 0;
bottom:0; bottom: 0;
text-align: center; text-align: center;
text-indent: 0; text-indent: 0;
} }
} }
.pp_arrow_previous { .pp_arrow_previous {
margin-right:.5em; margin-right: .5em;
} }
.pp_arrow_next { .pp_arrow_next {
margin-left:.5em; margin-left: .5em;
&:before { &:before {
content: "\e008"; content: "\e008";
} }
} }
a.pp_expand, a.pp_contract {
a.pp_expand,
a.pp_contract {
@include button(); @include button();
right:auto; right: auto;
left:-.5em; left: -.5em;
top:-.5em; top: -.5em;
font-size:1.618em !important; font-size: 1.618em !important;
&:before { &:before {
font-family: 'WooCommerce'; font-family: 'WooCommerce';
content:"\e005"; content: "\e005";
display: block; display: block;
position: absolute; position: absolute;
top:0; top: 0;
left:0; left: 0;
right:0; right: 0;
bottom:0; bottom: 0;
text-align: center; text-align: center;
text-indent: 0; text-indent: 0;
} }
} }
a.pp_contract { a.pp_contract {
&:before { &:before {
content: "\e004"; content: "\e004";
} }
} }
#respond { #respond {
margin:0; margin: 0;
width:100%; width: 100%;
background: none; background: none;
border:none; border: none;
padding:0; padding: 0;
.form-submit { .form-submit {
margin-top:0; margin-top: 0;
float:none; float: none;
} }
} }
.pp_inline { .pp_inline {
padding:0!important; padding: 0!important;
} }
} }
@media only screen and (max-width: 768px) { @media only screen and (max-width: 768px) {
div.pp_woocommerce { div.pp_woocommerce {
left: 5% !important; left: 5% !important;
right:5% !important; right: 5% !important;
@include box-sizing(border-box); @include box-sizing(border-box);
width: 90% !important; width: 90% !important;
.pp_gallery, .pp_previous, .pp_next, .pp_expand, .pp_contract {
.pp_gallery,
.pp_previous,
.pp_next,
.pp_expand,
.pp_contract {
display: none !important; display: none !important;
} }
.pp_arrow_previous, .pp_arrow_next, .pp_close {
height:44px; .pp_arrow_previous,
width:44px; .pp_arrow_next,
font-size:44px; .pp_close {
height: 44px;
width: 44px;
font-size: 44px;
line-height: 44px; line-height: 44px;
&:before { &:before {
font-size:44px; font-size: 44px;
} }
} }
.pp_arrow_previous, .pp_arrow_next {
}
.pp_description { .pp_description {
display: none !important; display: none !important;
} }
.pp_details { .pp_details {
width:100% !important; width: 100% !important;
} }
} }
.pp_content { .pp_content {
width:100% !important; width: 100% !important;
#pp_full_res{ #pp_full_res{
& > img{ & > img{
width:100% !important; width: 100% !important;
height:auto !important; height: auto !important;
} }
} }
} }
.currentTextHolder { .currentTextHolder {
line-height: 3; line-height: 3;
} }
} }
/* ------------------------------------------------------------------------ /* ------------------------------------------------------------------------
DO NOT CHANGE DO NOT CHANGE
------------------------------------------------------------------------- */ ------------------------------------------------------------------------- */
div.pp_pic_holder a:focus { outline:none; } div.pp_pic_holder a:focus {
outline: none;
}
div.pp_overlay { div.pp_overlay {
background: #000; background: #000;
display: none; display: none;
left: 0; left: 0;
position: absolute; position: absolute;
top: 0; top: 0;
width: 100%; width: 100%;
z-index: 9999; z-index: 9999;
} }
div.pp_pic_holder { div.pp_pic_holder {
display: none; display: none;
position: absolute; position: absolute;
width: 100px; width: 100px;
z-index: 10000; z-index: 10000;
} }
.pp_top {
height: 20px;
position: relative;
}
.pp_top { * html .pp_top {
height: 20px; padding: 0 20px;
position: relative; }
}
* html .pp_top { padding: 0 20px; }
.pp_top .pp_left { .pp_top .pp_left {
height: 20px; height: 20px;
left: 0; left: 0;
position: absolute; position: absolute;
width: 20px; width: 20px;
} }
.pp_top .pp_middle {
height: 20px;
left: 20px;
position: absolute;
right: 20px;
}
* html .pp_top .pp_middle {
left: 0;
position: static;
}
.pp_top .pp_right { .pp_top .pp_middle {
height: 20px; height: 20px;
left: auto; left: 20px;
position: absolute; position: absolute;
right: 0; right: 20px;
top: 0; }
width: 20px;
}
.pp_content { height: 40px; min-width: 40px; } * html .pp_top .pp_middle {
* html .pp_content { width: 40px; } left: 0;
position: static;
}
.pp_fade { display: none; } .pp_top .pp_right {
height: 20px;
left: auto;
position: absolute;
right: 0;
top: 0;
width: 20px;
}
.pp_content_container { .pp_content {
position: relative; height: 40px;
text-align: left; min-width: 40px;
width: 100%; }
}
.pp_content_container .pp_left { padding-left: 20px; } * html .pp_content {
.pp_content_container .pp_right { padding-right: 20px; } width: 40px;
}
.pp_content_container .pp_details { .pp_fade {
float: left; display: none;
margin: 10px 0 2px 0; }
}
.pp_description {
display: none;
margin: 0;
}
.pp_social { float: left; margin: 0; } .pp_content_container {
.pp_social .facebook { float: left; margin-left: 5px; width: 55px; overflow: hidden; } position: relative;
.pp_social .twitter { float: left; } text-align: left;
width: 100%;
}
.pp_nav { .pp_content_container .pp_left {
clear: right; padding-left: 20px;
float: left; }
margin: 3px 10px 0 0;
}
.pp_nav p { .pp_content_container .pp_right {
float: left; padding-right: 20px;
margin: 2px 4px; }
white-space: nowrap;
}
.pp_nav .pp_play, .pp_content_container .pp_details {
.pp_nav .pp_pause { float: left;
float: left; margin: 10px 0 2px 0;
margin-right: 4px; }
text-indent: -10000px;
}
a.pp_arrow_previous, .pp_description {
a.pp_arrow_next { display: none;
display: block; margin: 0;
float: left; }
height: 15px;
margin-top: 3px;
text-indent: -100000px;
width: 14px;
}
.pp_hoverContainer { .pp_social {
position: absolute; float: left;
top: 0; margin: 0;
width: 100%; }
z-index: 2000;
}
.pp_gallery { .pp_social .facebook {
display: none; float: left;
left: 50%; margin-left: 5px;
margin-top: -50px; width: 55px; overflow: hidden;
position: absolute; }
z-index: 10000;
}
.pp_gallery div { .pp_social .twitter {
float: left; float: left;
overflow: hidden; }
position: relative;
}
.pp_gallery ul { .pp_nav {
float: left; clear: right;
height: 35px; float: left;
margin: 0 0 0 5px; margin: 3px 10px 0 0;
padding: 0; }
position: relative;
white-space: nowrap;
}
.pp_gallery ul a { .pp_nav p {
border: 1px #000 solid; float: left;
border: 1px rgba(0,0,0,0.5) solid; margin: 2px 4px;
display: block; white-space: nowrap;
float: left; }
height: 33px;
overflow: hidden;
}
.pp_gallery ul a:hover, .pp_nav .pp_play,
.pp_gallery li.selected a { border-color: #fff; } .pp_nav .pp_pause {
float: left;
margin-right: 4px;
text-indent: -10000px;
}
.pp_gallery ul a img { border: 0; } a.pp_arrow_previous,
a.pp_arrow_next {
display: block;
float: left;
height: 15px;
margin-top: 3px;
text-indent: -100000px;
width: 14px;
}
.pp_gallery li { .pp_hoverContainer {
display: block; position: absolute;
float: left; top: 0;
margin: 0 5px 0 0; width: 100%;
padding: 0; z-index: 2000;
} }
.pp_gallery li.default a { .pp_gallery {
display: block; display: none;
height: 33px; left: 50%;
width: 50px; margin-top: -50px;
} position: absolute;
z-index: 10000;
}
.pp_gallery li.default a img { display: none; } .pp_gallery div {
float: left;
overflow: hidden;
position: relative;
}
.pp_gallery .pp_arrow_previous, .pp_gallery ul {
.pp_gallery .pp_arrow_next { float: left;
margin-top: 7px !important; height: 35px;
} margin: 0 0 0 5px;
padding: 0;
position: relative;
white-space: nowrap;
}
a.pp_next { .pp_gallery ul a {
display: block; border: 1px #000 solid;
float: right; border: 1px rgba(0,0,0,0.5) solid;
height: 100%; display: block;
text-indent: -10000px; float: left;
width: 49%; height: 33px;
} overflow: hidden;
}
a.pp_previous { .pp_gallery ul a:hover,
display: block; .pp_gallery li.selected a {
float: left; border-color: #fff;
height: 100%; }
text-indent: -10000px;
width: 49%;
}
a.pp_expand, .pp_gallery ul a img {
a.pp_contract { border: 0;
cursor: pointer; }
display: none;
height: 20px;
position: absolute;
right: 30px;
text-indent: -10000px;
top: 10px;
width: 20px;
z-index: 20000;
}
a.pp_close { .pp_gallery li {
position: absolute; right: 0; top: 0; display: block;
display: block; float: left;
text-indent: -10000px; margin: 0 5px 0 0;
} padding: 0;
}
.pp_bottom { .pp_gallery li.default a {
height: 20px; display: block;
position: relative; height: 33px;
} width: 50px;
* html .pp_bottom { padding: 0 20px; } }
.pp_bottom .pp_left { .pp_gallery li.default a img {
height: 20px; display: none;
left: 0; }
position: absolute;
width: 20px;
}
.pp_bottom .pp_middle {
height: 20px;
left: 20px;
position: absolute;
right: 20px;
}
* html .pp_bottom .pp_middle {
left: 0;
position: static;
}
.pp_bottom .pp_right { .pp_gallery .pp_arrow_previous,
height: 20px; .pp_gallery .pp_arrow_next {
left: auto; margin-top: 7px !important;
position: absolute; }
right: 0;
top: 0;
width: 20px;
}
.pp_loaderIcon { a.pp_next {
display: block; display: block;
height: 24px; float: right;
left: 50%; height: 100%;
margin: -12px 0 0 -12px; text-indent: -10000px;
position: absolute; width: 49%;
top: 50%; }
width: 24px;
}
#pp_full_res .pp_inline { a.pp_previous {
text-align: left; display: block;
} float: left;
height: 100%;
text-indent: -10000px;
width: 49%;
}
div.ppt { a.pp_expand,
color: #fff !important; a.pp_contract {
font-weight: 700; cursor: pointer;
display: none; display: none;
font-size: 17px; height: 20px;
margin: 0 0 5px 15px; position: absolute;
z-index: 9999; right: 30px;
} text-indent: -10000px;
top: 10px;
width: 20px;
z-index: 20000;
}
a.pp_close {
position: absolute; right: 0; top: 0;
display: block;
text-indent: -10000px;
}
.pp_bottom {
height: 20px;
position: relative;
}
* html .pp_bottom {
padding: 0 20px;
}
.pp_bottom .pp_left {
height: 20px;
left: 0;
position: absolute;
width: 20px;
}
.pp_bottom .pp_middle {
height: 20px;
left: 20px;
position: absolute;
right: 20px;
}
* html .pp_bottom .pp_middle {
left: 0;
position: static;
}
.pp_bottom .pp_right {
height: 20px;
left: auto;
position: absolute;
right: 0;
top: 0;
width: 20px;
}
.pp_loaderIcon {
display: block;
height: 24px;
left: 50%;
margin: -12px 0 0 -12px;
position: absolute;
top: 50%;
width: 24px;
}
#pp_full_res .pp_inline {
text-align: left;
}
div.ppt {
color: #fff !important;
font-weight: 700;
display: none;
font-size: 17px;
margin: 0 0 5px 15px;
z-index: 9999;
}