diff --git a/i/style/_variables.styl b/i/style/_variables.styl index 9cf896ca..a80c3825 100644 --- a/i/style/_variables.styl +++ b/i/style/_variables.styl @@ -35,20 +35,21 @@ $footer-height = 200px; // Media queries - -$small-mobile-breakpoint = 480px; -$landscape-tablet-breakpoint = 1024px; -$portrait-tablet-breakpoint = 768px; -$small-notebook-breakpoint = 1200px; -$notebook-breakpoint = 1400px; - -$small-mobile = 'only screen and (max-width: $small-mobile-breakpoint)'; -$mobile = 'only screen and (max-width: $portrait-tablet-breakpoint - 1px)'; -$not-mobile = 'only screen and (min-width: $portrait-tablet-breakpoint)'; -$tablet = 'only screen and (max-width: $landscape-tablet-breakpoint) and (min-width: $portrait-tablet-breakpoint-breakpoint)'; -$landscape-tablet = 'only screen and (max-device-width: $landscape-tablet-breakpoint) and (min-device-width: $portrait-tablet-breakpoint-breakpoint) and (orientation: landscape)'; -$portrait-tablet = 'only screen and (max-device-width: $landscape-tablet-breakpoint) and (min-device-width: $portrait-tablet-breakpoint-breakpoint) and (orientation: portrait)'; -$small-notebook = 'only screen and (max-width: $small-notebook-breakpoint) and (min-width: $landscape-tablet-breakpoint + 1px)'; -$notebook = 'only screen and (max-width: $notebook-breakpoint) and (min-width: $landscape-tablet-breakpoint + 1px)'; -$desktop = 'only screen and (min-width: $landscape-tablet-breakpoint + 1px)'; -$handheld = 'only screen and (max-width: $landscape-tablet-breakpoint)'; \ No newline at end of file +$media-vars = json("../../js/src/media-queries-config.json", { hash: true }); + +$small-mobile-breakpoint = unit($media-vars.smallMobile, 'px'); +$landscape-tablet-breakpoint = unit($media-vars.tablet.landscape, 'px'); +$portrait-tablet-breakpoint = unit($media-vars.tablet.portrait, 'px'); +$small-notebook-breakpoint = unit($media-vars.smallNotebook, 'px'); +$notebook-breakpoint = unit($media-vars.notebook, 'px'); + +$small-mobile = "only screen and (max-width: $small-mobile-breakpoint)"; +$mobile = "only screen and (max-width: $portrait-tablet-breakpoint - 1px)"; +$not-mobile = "only screen and (min-width: $portrait-tablet-breakpoint)"; +$tablet = "only screen and (max-width: $landscape-tablet-breakpoint) and (min-width: $portrait-tablet-breakpoint-breakpoint)"; +$landscape-tablet = "only screen and (max-device-width: $landscape-tablet-breakpoint) and (min-device-width: $portrait-tablet-breakpoint-breakpoint) and (orientation: landscape)"; +$portrait-tablet = "only screen and (max-device-width: $landscape-tablet-breakpoint) and (min-device-width: $portrait-tablet-breakpoint-breakpoint) and (orientation: portrait)"; +$small-notebook = "only screen and (max-width: $small-notebook-breakpoint) and (min-width: $landscape-tablet-breakpoint + 1px)"; +$notebook = "only screen and (max-width: $notebook-breakpoint) and (min-width: $landscape-tablet-breakpoint + 1px)"; +$desktop = "only screen and (min-width: $landscape-tablet-breakpoint + 1px)"; +$handheld = "only screen and (max-width: $landscape-tablet-breakpoint)"; \ No newline at end of file diff --git a/js/compiled.js b/js/compiled.js index 9cce0756..f334874e 100644 --- a/js/compiled.js +++ b/js/compiled.js @@ -49,5 +49,5 @@ jQuery.fn.yiiactiveform&&(jQuery.fn.yiiactiveform.addFields=function(t,a){var e= !function(i){var e="tosrus",n="image";i[e].media[n]={filterAnchors:function(e){return i.inArray(e.attr("href").toLowerCase().split(".").pop().split("?")[0],["jpg","jpe","jpeg","gif","png"])>-1},initAnchors:function(n,r){i('').on(i[e]._e.load,function(r){r.stopPropagation(),n.removeClass(i[e]._c.loading).trigger(i[e]._e.loaded)}).appendTo(n).attr("src",r)},filterSlides:function(i){return i.is("img")},initSlides:function(){}},i[e].defaults.media[n]={}}(jQuery); !function(i){function t(t){function l(){f.length&&(f.attr("src",""),f.attr("src",h))}c||(e=i[s]._c,o=i[s]._d,a=i[s]._e,n=i[s]._f,r=i[s]._g,o.add("ratio maxWidth maxHeight"),c=!0);var f=t.children(),m=t.data(i[s]._d.anchor)||i(),h=f.attr("src"),u=m.data(o.ratio)||this.opts[d].ratio,g=m.data(o.maxWidth)||this.opts[d].maxWidth,p=m.data(o.maxHeight)||this.opts[d].maxHeight;t.removeClass(e.loading).trigger(a.loaded).on(a.loading,function(){n.resizeRatio(f,t,g,p,u)}),this.nodes.$wrpr.on(a.sliding,function(){l()}).on(a.opening,function(){n.resizeRatio(f,t,g,p,u)}).on(a.closing,function(){l()}),r.$wndw.on(a.resize,function(){n.resizeRatio(f,t,g,p,u)})}var e,o,a,n,r,s="tosrus",d="vimeo",c=!1;i[s].media[d]={filterAnchors:function(i){return i.attr("href").toLowerCase().indexOf("vimeo.com/")>-1},initAnchors:function(e,o){var a=this._uniqueID();o=o.split("vimeo.com/")[1].split("?")[0]+"?api=1&player_id="+a,i('