Title: [211331] trunk
Revision
211331
Author
joep...@webkit.org
Date
2017-01-28 01:25:59 -0800 (Sat, 28 Jan 2017)

Log Message

Patch Review: EWS Bubbles wrap to multiple lines but can fit on one line
https://bugs.webkit.org/show_bug.cgi?id=167519

Reviewed by Ryosuke Niwa.

Tools:

* QueueStatusServer/templates/statusbubble.html:
To measure the bubbleContainer's width, it must not be wrapping based
on its parent container. So when measuring the width temporarily set
the parent to a very large width so as to not artificially wrap us.
Restore the parent's width after measuring.

Websites/bugs.webkit.org:

While we do post message to determine the size, the fact that we have
constrained the iframe to a size of 450px meant its body is 450px and
the div containing the bubbles wraps at 450px. Its full size (~458px)
is not returned. Although we solve this artifical constraint problem
inside of the bubble containerMetrics measuring, up this default value
from 450 to 460 to reduce UI jitter (the current measurement on my
machine is 458px).

* PrettyPatch/PrettyPatch.rb:

Modified Paths

Diff

Modified: trunk/Tools/ChangeLog (211330 => 211331)


--- trunk/Tools/ChangeLog	2017-01-28 08:19:19 UTC (rev 211330)
+++ trunk/Tools/ChangeLog	2017-01-28 09:25:59 UTC (rev 211331)
@@ -1,3 +1,16 @@
+2017-01-28  Joseph Pecoraro  <pecor...@apple.com>
+
+        Patch Review: EWS Bubbles wrap to multiple lines but can fit on one line
+        https://bugs.webkit.org/show_bug.cgi?id=167519
+
+        Reviewed by Ryosuke Niwa.
+
+        * QueueStatusServer/templates/statusbubble.html:
+        To measure the bubbleContainer's width, it must not be wrapping based
+        on its parent container. So when measuring the width temporarily set
+        the parent to a very large width so as to not artificially wrap us.
+        Restore the parent's width after measuring.
+
 2017-01-27  Andy Estes  <aes...@apple.com>
 
         [iOS] Add a test for _WKNSFileManagerExtras

Modified: trunk/Tools/QueueStatusServer/templates/statusbubble.html (211330 => 211331)


--- trunk/Tools/QueueStatusServer/templates/statusbubble.html	2017-01-28 08:19:19 UTC (rev 211330)
+++ trunk/Tools/QueueStatusServer/templates/statusbubble.html	2017-01-28 09:25:59 UTC (rev 211331)
@@ -54,7 +54,11 @@
 <script>
 window.addEventListener("message", function(e) {
   if (e.data ="" 'containerMetrics') {
+    var parentContainer = bubbleContainer.parentElement;
+    var originalWidth = parentContainer.style.width;
+    parentContainer.style.width = "1000px";
     var clientRect = bubbleContainer.getBoundingClientRect();
+    parentContainer.style.width = originalWidth;
     e.source.postMessage({'width': Math.ceil(clientRect.width), 'height': Math.ceil(clientRect.height)}, e.origin);
   } else
     console.log("Unknown postMessage: " + e.data);

Modified: trunk/Websites/bugs.webkit.org/ChangeLog (211330 => 211331)


--- trunk/Websites/bugs.webkit.org/ChangeLog	2017-01-28 08:19:19 UTC (rev 211330)
+++ trunk/Websites/bugs.webkit.org/ChangeLog	2017-01-28 09:25:59 UTC (rev 211331)
@@ -1,3 +1,20 @@
+2017-01-28  Joseph Pecoraro  <pecor...@apple.com>
+
+        Patch Review: EWS Bubbles wrap to multiple lines but can fit on one line
+        https://bugs.webkit.org/show_bug.cgi?id=167519
+
+        Reviewed by Ryosuke Niwa.
+
+        While we do post message to determine the size, the fact that we have
+        constrained the iframe to a size of 450px meant its body is 450px and
+        the div containing the bubbles wraps at 450px. Its full size (~458px)
+        is not returned. Although we solve this artifical constraint problem
+        inside of the bubble containerMetrics measuring, up this default value
+        from 450 to 460 to reduce UI jitter (the current measurement on my
+        machine is 458px).
+
+        * PrettyPatch/PrettyPatch.rb:
+
 2017-01-19  Timothy Hatcher  <timo...@hatcher.name>
 
         Bugzilla email autocomplete does not work on third email field of advanced search page

Modified: trunk/Websites/bugs.webkit.org/PrettyPatch/PrettyPatch.rb (211330 => 211331)


--- trunk/Websites/bugs.webkit.org/PrettyPatch/PrettyPatch.rb	2017-01-28 08:19:19 UTC (rev 211330)
+++ trunk/Websites/bugs.webkit.org/PrettyPatch/PrettyPatch.rb	2017-01-28 09:25:59 UTC (rev 211331)
@@ -490,7 +490,7 @@
 
 .statusBubble {
   /* The width/height get set to the bubble contents via postMessage on browsers that support it. */
-  width: 450px;
+  width: 460px;
   height: 20px;
   margin: 2px 2px 0 0;
   border: none;
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to