From ca79ab0252e226a604d725ac0886fec8c9d6f9aa Mon Sep 17 00:00:00 2001 From: Hugo Roussille Date: Mon, 12 Sep 2016 16:48:15 +0200 Subject: [PATCH] =?UTF-8?q?Correction=20de=202153a64=20pour=20g=C3=A9rer?= =?UTF-8?q?=20les=20tableaux?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- bda/templates/descriptions.html | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/bda/templates/descriptions.html b/bda/templates/descriptions.html index 3ed67e87..a993848a 100644 --- a/bda/templates/descriptions.html +++ b/bda/templates/descriptions.html @@ -18,7 +18,7 @@ } .descTable{ - width: auto; + width: 100%; margin: 0 auto 1em; border-bottom: 2px solid; border-collapse: collapse; @@ -70,6 +70,10 @@ // Correction de la taille des images $(document).ready(function() { + $(".descTable").each(function() { + $(this).width($("body").width()); + }); + $(".imgDesc").on("load", function() { // Dimensions @@ -78,7 +82,7 @@ w = $(this).width(); h = $(this).height(); r = w/h; // Ratio de l'image - maxWidth = $(this).parent().width(); + maxWidth = $("body").width(); if (r * origHeight > maxWidth) {