From aa14cf56259f7e7ffb4c18af013cdfcfc56953fa Mon Sep 17 00:00:00 2001 From: Jules Laplace Date: Thu, 10 May 2018 16:45:35 +0200 Subject: sizing footer. phook script --- StoneIsland/www/css/products.css | 2 +- StoneIsland/www/index.html | 2 +- StoneIsland/www/js/lib/products/ProductView.js | 27 ++++++++++++++++---------- 3 files changed, 19 insertions(+), 12 deletions(-) (limited to 'StoneIsland/www') diff --git a/StoneIsland/www/css/products.css b/StoneIsland/www/css/products.css index d78801f8..59bb403f 100755 --- a/StoneIsland/www/css/products.css +++ b/StoneIsland/www/css/products.css @@ -216,7 +216,7 @@ text-transform:uppercase; padding:12px 0 0; } -.product .fitFooter { +.product .fitHeader { clear:both; font-size:9px; letter-spacing:0.5px; diff --git a/StoneIsland/www/index.html b/StoneIsland/www/index.html index 9221d0be..92769657 100755 --- a/StoneIsland/www/index.html +++ b/StoneIsland/www/index.html @@ -278,7 +278,7 @@ SHARE +
Fits Large
-
+
Not Available In Canada
diff --git a/StoneIsland/www/js/lib/products/ProductView.js b/StoneIsland/www/js/lib/products/ProductView.js index 59726384..66554ce7 100755 --- a/StoneIsland/www/js/lib/products/ProductView.js +++ b/StoneIsland/www/js/lib/products/ProductView.js @@ -26,7 +26,7 @@ var ProductView = ScrollableView.extend({ this.$color = this.$(".color") this.$body = this.$(".body") this.$fit = this.$(".fit") - this.$fitFooter = this.$('.fitFooter') + this.$fitHeader = this.$('.fitHeader') this.$notAvailableInCanada = this.$(".notAvailableInCanada") this.$sizing = this.$(".sizing") this.$style = this.$(".style") @@ -211,20 +211,27 @@ var ProductView = ScrollableView.extend({ if (fits_large) { if (app.store.FitsLarge === 'use_alt_text' && (app.store.FitsLargeText || "").length) { var fit_lines = app.store.FitsLargeText.replace(//g, "&rt;").split('\n').join("
") - $('.fitFooter').html(fit_lines) - $('.fitFooter').show() + this.$fitHeader.html(fit_lines) + this.$fitHeader.show() } else { - $('.fitFooter').hide() + this.$fitHeader.hide() } - app.product.$fit.show() - app.product.$sizing.show() + this.$fit.show() } else { - $('.fitFooter').hide() - app.product.$fit.hide() - app.product.$sizing.hide() + this.$fitFooter.hide() + this.$fit.hide() } - + + if (app.store.SizingFooter === 'use_alt_text' && (app.store.SizingFooterText || "").length) { + var sizing_lines = app.store.SizingFooterText.replace(//g, "&rt;").split('\n').join("
") + this.$sizing.html(sizing_lines) + this.$sizing.show() + } + else { + this.$sizing.hide() + } + this.deferScrollToTop() }, -- cgit v1.2.3-70-g09d2