From 5099a60ffebb5581d41b9711fb6d28c1e5dad231 Mon Sep 17 00:00:00 2001 From: Catalin Zalog Date: Sun, 30 Oct 2016 23:43:10 +0200 Subject: [PATCH 1/2] Fix input group sizing in Firefox Firefox requires a width and flex-basis value to size the input field correctly. Despite the width being 1%, the input will size correctly at all parent widths. http://codepen.io/zalog/pen/bpMJmv --- scss/_input-group.scss | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/scss/_input-group.scss b/scss/_input-group.scss index 7eef23a9dd..17b9c84020 100644 --- a/scss/_input-group.scss +++ b/scss/_input-group.scss @@ -26,7 +26,10 @@ } @if $enable-flex { - flex: 1; + flex: 1 1 auto; + // Add width 1% and flex-basis auto to ensure that button will not wrap out + // the column. Applies to IE Edge+ and Firefox. Chrome do not require this. + width: 1%; } @else { // IE9 fubars the placeholder attribute in text inputs and the arrows on // select elements in input groups. To fix it, we float the input. Details: From bf439363775c98d900f7ef3d6d0297fa8887ef58 Mon Sep 17 00:00:00 2001 From: Ilias Date: Sun, 30 Oct 2016 23:47:14 +0200 Subject: [PATCH 2/2] Fix #17964 (#17997) * Fix #17964 Some browsers are lazy when updating dom elements after transition effects. This can be fixed by reading element properties such as offsetHeight or offsetWidth. However, creating a function using the Function constructor just to access such element, results in a violation of Content Security Policy (where applied), which in turn crashes the application. This fix actually reverts to the way this was handled in v3 and should work as intended. --- js/src/util.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/src/util.js b/js/src/util.js index f9e7f77fab..5ddbbbf133 100644 --- a/js/src/util.js +++ b/js/src/util.js @@ -121,7 +121,7 @@ const Util = (($) => { }, reflow(element) { - new Function('bs', 'return bs')(element.offsetHeight) + return element.offsetHeight }, triggerTransitionEnd(element) {