Permalink
Browse files

0.1

  • Loading branch information...
1 parent 03fd00a commit 726ddd0302a6dc94574d1507cf86146c96b004df @jameskoster committed Nov 28, 2012
View
@@ -0,0 +1,118 @@
+// MIXINS
+.clearfix() {
+ &:after {
+ content: "";
+ display: block;
+ clear: both;
+ }
+}
+.border_radius(@radius:10px)
+{
+ -webkit-border-radius:@radius;
+ -moz-border-radius:@radius;
+ border-radius:@radius;
+}
+
+.border_radius_right(@radius:10px)
+{
+ -webkit-border-top-right-radius: @radius;
+ -webkit-border-bottom-right-radius: @radius;
+ -moz-border-radius-topright: @radius;
+ -moz-border-radius-bottomright: @radius;
+ border-top-right-radius: @radius;
+ border-bottom-right-radius: @radius;
+}
+
+.border_radius_left(@radius:10px)
+{
+ -webkit-border-top-left-radius: @radius;
+ -webkit-border-bottom-left-radius: @radius;
+ -moz-border-radius-topleft: @radius;
+ -moz-border-radius-bottomleft: @radius;
+ border-top-left-radius: @radius;
+ border-bottom-left-radius: @radius;
+}
+
+.border_radius_bottom(@radius:10px)
+{
+ -webkit-border-bottom-left-radius: @radius;
+ -webkit-border-bottom-right-radius: @radius;
+ -moz-border-radius-bottomleft: @radius;
+ -moz-border-radius-bottomright: @radius;
+ border-bottom-left-radius: @radius;
+ border-bottom-right-radius: @radius;
+}
+
+.border_radius_top(@radius:10px)
+{
+ -webkit-border-top-left-radius: @radius;
+ -webkit-border-top-right-radius: @radius;
+ -moz-border-radius-topleft: @radius;
+ -moz-border-radius-topright: @radius;
+ border-top-left-radius: @radius;
+ border-top-right-radius: @radius;
+}
+
+.box_shadow(@shadow_x:3px, @shadow_y:3px, @shadow_rad:3px, @shadow_in:3px, @shadow_color:#888)
+{
+ box-shadow:@shadow_x @shadow_y @shadow_rad @shadow_in @shadow_color;
+ -webkit-box-shadow:@shadow_x @shadow_y @shadow_rad @shadow_in @shadow_color;
+}
+
+.inset_box_shadow(@shadow_x:3px, @shadow_y:3px, @shadow_rad:3px, @shadow_in:3px, @shadow_color:#888)
+{
+ box-shadow:inset @shadow_x @shadow_y @shadow_rad @shadow_in @shadow_color;
+ -webkit-box-shadow:inset @shadow_x @shadow_y @shadow_rad @shadow_in @shadow_color;
+}
+
+.text_shadow(@shadow_x:3px, @shadow_y:3px, @shadow_rad:3px, @shadow_color:#fff)
+{
+ text-shadow:@shadow_x @shadow_y @shadow_rad @shadow_color;
+}
+
+.vertical_gradient(@from: #000, @to: #FFF) {
+ background: @from;
+ background: -webkit-gradient(linear, left top, left bottom, from(@from), to(@to));
+ background: -webkit-linear-gradient(@from, @to);
+ background: -moz-linear-gradient(center top, @from 0%, @to 100%);
+ background: -moz-gradient(center top, @from 0%, @to 100%);
+ filter: e(%("progid:DXImageTransform.Microsoft.gradient(GradientType=0,startColorstr=%d,endColorstr=%d)", @from, @to));
+ -ms-filter: %("progid:DXImageTransform.Microsoft.gradient(GradientType=0,startColorstr=%d, endColorstr=%d)", @from, @to);
+}
+
+.transition(@selector:all, @animation:ease-in-out, @duration:.2s) {
+ -webkit-transition:@selector @animation @duration;
+ -moz-transition:@selector @animation @duration;
+ -o-transition:@selector @animation @duration;
+ transition:@selector @animation @duration;
+}
+
+.opacity(@opacity:0.75) {
+ filter:~"alpha(opacity=@opacity * 100)";
+ -moz-opacity:@opacity;
+ -khtml-opacity: @opacity;
+ opacity: @opacity;
+}
+
+.rotate(@degree:1deg) {
+ -webkit-transform:rotate(@degree);
+ -moz-transform:rotate(@degree);
+}
+
+.scale(@ratio:1.5){
+ -webkit-transform:scale(@ratio);
+ -moz-transform:scale(@ratio);
+ transform:scale(@ratio);
+}
+
+.radial_gradient(@from: #000, @to: #FFF) {
+ background: @from;
+ background: -webkit-gradient(radial, 50% 10%, 0, 50% 10%, 1000, from(@from), to(@to));
+ background: -moz-radial-gradient(center top, @from 0%, @to 100%);
+}
+
+.borderbox () {
+ -webkit-box-sizing: border-box; /* Safari/Chrome, other WebKit */
+ -moz-box-sizing: border-box; /* Firefox, other Gecko */
+ box-sizing: border-box; /* Opera/IE 8+ */
+}
View
@@ -0,0 +1,97 @@
+ul.products.grid div[itemprop="description"] {
+ display: none;
+}
+ul.products.grid hr {
+ display: none;
+}
+ul.products.list li.product {
+ float: none;
+ width: 100%;
+ text-align: left !important;
+}
+ul.products.list li.product:after {
+ content: "";
+ display: block;
+ clear: both;
+}
+ul.products.list li.product img {
+ width: 30.75%;
+ float: left;
+ margin-bottom: 1.5em;
+ -webkit-transition: none !important;
+}
+ul.products.list li.product h3,
+ul.products.list li.product div[itemprop="description"],
+ul.products.list li.product .price,
+ul.products.list li.product .gridlist-buttonwrap {
+ width: 65.4%;
+ float: right;
+ clear: none;
+}
+ul.products.list li.product div[itemprop="description"] {
+ display: block;
+}
+ul.products.list li.product .gridlist-buttonwrap {
+ margin-bottom: 1.5em;
+}
+ul.products.list li.product hr {
+ clear: both;
+}
+#gridlist-toggle {
+ display: inline-block;
+ border: 1px solid #555;
+ padding: 0 !important;
+ margin-bottom: 1.5em;
+ background: #eeeeee;
+ background: -webkit-gradient(linear, left top, left bottom, from(#eeeeee), to(#aaaaaa));
+ background: -webkit-linear-gradient(#eeeeee, #aaaaaa);
+ background: -moz-linear-gradient(center top, #eeeeee 0%, #aaaaaa 100%);
+ background: -moz-gradient(center top, #eeeeee 0%, #aaaaaa 100%);
+ filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0,startColorstr=#eeeeee,endColorstr=#aaaaaa);
+ -ms-filter: "progid:DXImageTransform.Microsoft.gradient(GradientType=0,startColorstr=#eeeeee, endColorstr=#aaaaaa)";
+ -webkit-border-radius: 3px;
+ -moz-border-radius: 3px;
+ border-radius: 3px;
+ line-height: 1em !important;
+ -webkit-box-shadow: inset 0 1px #eeeeee, inset 0 -1px #999999, 0 1px 2px rgba(0, 0, 0, 0.3);
+ box-shadow: inset 0 1px #eeeeee, inset 0 -1px #999999, 0 1px 2px rgba(0, 0, 0, 0.3);
+}
+#gridlist-toggle a {
+ display: inline-block;
+ width: 2em;
+ text-align: center;
+ text-shadow: 0 1px 0 #ffffff;
+ text-decoration: none !important;
+ font-weight: normal !important;
+ font-family: sans-serif !important;
+ font-size: 1em !important;
+ line-height: 1.5em !important;
+ color: #222 !important;
+ text-shadow: 0 1px 0 #eeeeee;
+ -webkit-transition: background ease-in-out 0.2s;
+ -webkit-box-shadow: inset 0 0 5px rgba(255, 255, 255, 0.7), inset 0 0 0 1px rgba(255, 255, 255, 0.4);
+ box-shadow: inset 0 0 5px rgba(255, 255, 255, 0.7), inset 0 0 0 1px rgba(255, 255, 255, 0.4);
+}
+#gridlist-toggle a#grid {
+ border-right: 1px solid #000;
+}
+#gridlist-toggle a span {
+ display: none;
+}
+#gridlist-toggle a:hover {
+ color: #000;
+ background: rgba(255, 255, 255, 0.2);
+}
+#gridlist-toggle a.active {
+ background: #444444;
+ background: -webkit-gradient(linear, left top, left bottom, from(#444444), to(#666666));
+ background: -webkit-linear-gradient(#444444, #666666);
+ background: -moz-linear-gradient(center top, #444444 0%, #666666 100%);
+ background: -moz-gradient(center top, #444444 0%, #666666 100%);
+ filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0,startColorstr=#444444,endColorstr=#666666);
+ -ms-filter: "progid:DXImageTransform.Microsoft.gradient(GradientType=0,startColorstr=#444444, endColorstr=#666666)";
+ color: #fff !important;
+ text-shadow: 0 1px 0 #000000;
+ -webkit-box-shadow: inset 0 1px 2px #444444, inset 0 -1px 0 #777777;
+ -moz-box-shadow: inset 0 1px 2px #444444, inset 0 -1px 0 #777777;
+}
View
@@ -0,0 +1,99 @@
+@import url(mixins.less);
+
+ul.products.grid {
+ div[itemprop="description"] {
+ display: none;
+ }
+ hr {
+ display: none;
+ }
+}
+
+ul.products.list {
+ li.product {
+ float: none;
+ width:100%;
+ .clearfix;
+ text-align: left !important;
+ img {
+ width:30.75%;
+ float: left;
+ margin-bottom:1.5em;
+ -webkit-transition:none !important;
+ }
+ h3, div[itemprop="description"], .price, .gridlist-buttonwrap {
+ width: 65.4%;
+ float: right;
+ clear: none;
+ }
+ div[itemprop="description"] {
+ display: block;
+ }
+ .gridlist-buttonwrap {
+ margin-bottom:1.5em;
+ }
+ hr {
+ clear: both;
+ }
+ }
+}
+
+#gridlist-toggle {
+ display: inline-block;
+ border:1px solid #555;
+ padding:0 !important;
+ margin-bottom:1.5em;
+ .vertical_gradient(#eee,#aaa);
+ .border_radius(3px);
+ line-height: 1em !important;
+ -webkit-box-shadow:
+ inset 0 1px #eee,
+ inset 0 -1px #999,
+ 0 1px 2px rgba(0,0,0,0.3);
+ box-shadow:
+ inset 0 1px #eee,
+ inset 0 -1px #999,
+ 0 1px 2px rgba(0,0,0,0.3);
+ a {
+ display: inline-block;
+ width:2em;
+ text-align: center;
+ .text_shadow(0,1px,0,#fff);
+ text-decoration:none !important;
+ font-weight: normal !important;
+ font-family: sans-serif !important;
+ font-size:1em !important;
+ line-height: 1.5em !important;
+ color: #222 !important;
+ .text_shadow(0,1px,0,#eee);
+ -webkit-transition:background ease-in-out .2s;
+ -webkit-box-shadow:
+ inset 0 0 5px rgba(255,255,255,0.7),
+ inset 0 0 0 1px rgba(255,255,255,0.4);
+ box-shadow:
+ inset 0 0 5px rgba(255,255,255,0.7),
+ inset 0 0 0 1px rgba(255,255,255,0.4);
+ &#grid {
+ border-right:1px solid #000;
+ }
+ span {
+ display: none;
+ }
+ &:hover {
+ color: #000;
+ background: rgba(255,255,255,0.2);
+ }
+ &.active {
+ .vertical_gradient(#444,#666);
+
+ color: #fff !important;
+ .text_shadow(0,1px,0,#000);
+ -webkit-box-shadow:
+ inset 0 1px 2px #444,
+ inset 0 -1px 0 #777;
+ -moz-box-shadow:
+ inset 0 1px 2px #444,
+ inset 0 -1px 0 #777;
+ }
+ }
+}
View
@@ -0,0 +1,72 @@
+/*jshint eqnull:true */
+/*!
+ * jQuery Cookie Plugin v1.2
+ * https://github.com/carhartl/jquery-cookie
+ *
+ * Copyright 2011, Klaus Hartl
+ * Dual licensed under the MIT or GPL Version 2 licenses.
+ * http://www.opensource.org/licenses/mit-license.php
+ * http://www.opensource.org/licenses/GPL-2.0
+ */
+(function ($, document, undefined) {
+
+ var pluses = /\+/g;
+
+ function raw(s) {
+ return s;
+ }
+
+ function decoded(s) {
+ return decodeURIComponent(s.replace(pluses, ' '));
+ }
+
+ $.cookie = function (key, value, options) {
+
+ // key and at least value given, set cookie...
+ if (value !== undefined && !/Object/.test(Object.prototype.toString.call(value))) {
+ options = $.extend({}, $.cookie.defaults, options);
+
+ if (value === null) {
+ options.expires = -1;
+ }
+
+ if (typeof options.expires === 'number') {
+ var days = options.expires, t = options.expires = new Date();
+ t.setDate(t.getDate() + days);
+ }
+
+ value = String(value);
+
+ return (document.cookie = [
+ encodeURIComponent(key), '=', options.raw ? value : encodeURIComponent(value),
+ options.expires ? '; expires=' + options.expires.toUTCString() : '', // use expires attribute, max-age is not supported by IE
+ options.path ? '; path=' + options.path : '',
+ options.domain ? '; domain=' + options.domain : '',
+ options.secure ? '; secure' : ''
+ ].join(''));
+ }
+
+ // key and possibly options given, get cookie...
+ options = value || $.cookie.defaults || {};
+ var decode = options.raw ? raw : decoded;
+ var cookies = document.cookie.split('; ');
+ for (var i = 0, parts; (parts = cookies[i] && cookies[i].split('=')); i++) {
+ if (decode(parts.shift()) === key) {
+ return decode(parts.join('='));
+ }
+ }
+
+ return null;
+ };
+
+ $.cookie.defaults = {};
+
+ $.removeCookie = function (key, options) {
+ if ($.cookie(key, options) !== null) {
+ $.cookie(key, null, options);
+ return true;
+ }
+ return false;
+ };
+
+})(jQuery, document);
Oops, something went wrong.

0 comments on commit 726ddd0

Please sign in to comment.