Repository: zeppelin
Updated Branches:
  refs/heads/master b02707975 -> e20f68be8


Revert layout change made by pr2356

### What is this PR for?
This PR reverts layout change made by #2356.

### What type of PR is it?
Fix

### Questions:
* Does the licenses files need update? no
* Is there breaking changes for older versions? no
* Does this needs documentation? no

Author: Lee moon soo <m...@apache.org>

Closes #2409 from Leemoonsoo/revert_layoutchange_from_pr2356 and squashes the 
following commits:

2abb91a [Lee moon soo] revert changes on test
391c5d9 [Lee moon soo] revert layout change made by 
https://github.com/apache/zeppelin/pull/2356


Project: http://git-wip-us.apache.org/repos/asf/zeppelin/repo
Commit: http://git-wip-us.apache.org/repos/asf/zeppelin/commit/e20f68be
Tree: http://git-wip-us.apache.org/repos/asf/zeppelin/tree/e20f68be
Diff: http://git-wip-us.apache.org/repos/asf/zeppelin/diff/e20f68be

Branch: refs/heads/master
Commit: e20f68be8d874701bc9fbd0fadc3fa0699d3d2ca
Parents: b027079
Author: Lee moon soo <m...@apache.org>
Authored: Sat Jun 10 16:14:22 2017 -0700
Committer: Lee moon soo <m...@apache.org>
Committed: Thu Jun 15 22:32:14 2017 -0700

----------------------------------------------------------------------
 .../integration/ParagraphActionsIT.java         | 14 +++----
 .../src/app/notebook/paragraph/paragraph.css    | 16 +++++---
 .../src/app/notebook/paragraph/paragraph.html   | 41 +++++++++-----------
 3 files changed, 36 insertions(+), 35 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/zeppelin/blob/e20f68be/zeppelin-server/src/test/java/org/apache/zeppelin/integration/ParagraphActionsIT.java
----------------------------------------------------------------------
diff --git 
a/zeppelin-server/src/test/java/org/apache/zeppelin/integration/ParagraphActionsIT.java
 
b/zeppelin-server/src/test/java/org/apache/zeppelin/integration/ParagraphActionsIT.java
index 414460b..fa5bed9 100644
--- 
a/zeppelin-server/src/test/java/org/apache/zeppelin/integration/ParagraphActionsIT.java
+++ 
b/zeppelin-server/src/test/java/org/apache/zeppelin/integration/ParagraphActionsIT.java
@@ -262,7 +262,7 @@ public class ParagraphActionsIT extends AbstractZeppelinIT {
     }
     try {
       String xpathToRunOnSelectionChangeCheckbox = getParagraphXPath(1) + 
"//ul/li/form/input[contains(@ng-checked, 'true')]";
-      String xpathToDropdownMenu = "(" + (getParagraphXPath(1) + 
"//select)[2]");
+      String xpathToDropdownMenu = getParagraphXPath(1) + "//select";
       String xpathToResultText = getParagraphXPath(1) + 
"//div[contains(@id,\"_html\")]";
 
       createNewNote();
@@ -592,7 +592,7 @@ public class ParagraphActionsIT extends AbstractZeppelinIT {
               driver.findElement(By.xpath(getParagraphXPath(1) + 
"//div[contains(@class, 'text plainTextContent')]")).getText(),
               CoreMatchers.equalTo("Howdy "));
 
-      Select dropDownMenu = new Select(driver.findElement(By.xpath("(" + 
(getParagraphXPath(1) + "//select)[2]"))));
+      Select dropDownMenu = new Select(driver.findElement(By.xpath("(" + 
(getParagraphXPath(1) + "//select)[1]"))));
 
       dropDownMenu.selectByVisibleText("Alice");
       collector.checkThat("After selection in drop down menu, output should 
display the newly selected option",
@@ -602,7 +602,7 @@ public class ParagraphActionsIT extends AbstractZeppelinIT {
       driver.findElement(By.xpath(getParagraphXPath(1) + 
"//span[@class='icon-settings']")).click();
       clickAndWait(By.xpath(getParagraphXPath(1) + 
"//ul/li/form/input[contains(@ng-checked, 'true')]"));
 
-      Select sameDropDownMenu = new Select(driver.findElement(By.xpath("(" + 
(getParagraphXPath(1) + "//select)[2]"))));
+      Select sameDropDownMenu = new Select(driver.findElement(By.xpath("(" + 
(getParagraphXPath(1) + "//select)[1]"))));
       sameDropDownMenu.selectByVisibleText("Bob");
       collector.checkThat("After 'Run on selection change' checkbox is 
unchecked, the paragraph should not run if selecting a different option",
               driver.findElement(By.xpath(getParagraphXPath(1) + 
"//div[contains(@class, 'text plainTextContent')]")).getText(),
@@ -632,7 +632,7 @@ public class ParagraphActionsIT extends AbstractZeppelinIT {
               driver.findElement(By.xpath(getParagraphXPath(1) + 
"//div[contains(@class, 'text plainTextContent')]")).getText(),
               CoreMatchers.containsString("Greetings han and leia and luke"));
 
-      WebElement firstCheckbox = driver.findElement(By.xpath("(" + 
getParagraphXPath(1) + "//input[@type='checkbox'])[2]"));
+      WebElement firstCheckbox = driver.findElement(By.xpath("(" + 
getParagraphXPath(1) + "//input[@type='checkbox'])[1]"));
       firstCheckbox.click();
       collector.checkThat("After unchecking one of the boxes, we can see the 
newly updated output without the option we unchecked",
               driver.findElement(By.xpath(getParagraphXPath(1) + 
"//div[contains(@class, 'text plainTextContent')]")).getText(),
@@ -641,7 +641,7 @@ public class ParagraphActionsIT extends AbstractZeppelinIT {
       driver.findElement(By.xpath(getParagraphXPath(1) + 
"//span[@class='icon-settings']")).click();
       clickAndWait(By.xpath(getParagraphXPath(1) + 
"//ul/li/form/input[contains(@ng-checked, 'true')]"));
 
-      WebElement secondCheckbox = driver.findElement(By.xpath("(" + 
getParagraphXPath(1) + "//input[@type='checkbox'])[3]"));
+      WebElement secondCheckbox = driver.findElement(By.xpath("(" + 
getParagraphXPath(1) + "//input[@type='checkbox'])[2]"));
       secondCheckbox.click();
       collector.checkThat("After 'Run on selection change' checkbox is 
unchecked, the paragraph should not run if check box state is modified",
               driver.findElement(By.xpath(getParagraphXPath(1) + 
"//div[contains(@class, 'text plainTextContent')]")).getText(),
@@ -676,7 +676,7 @@ public class ParagraphActionsIT extends AbstractZeppelinIT {
               driver.findElement(By.xpath(getParagraphXPath(1) + 
"//div[contains(@class, 'text plainTextContent')]")).getText(),
               CoreMatchers.equalTo("Howdy \nHowdy "));
 
-      Select dropDownMenu = new Select(driver.findElement(By.xpath("(" + 
(getParagraphXPath(1) + "//select)[2]"))));
+      Select dropDownMenu = new Select(driver.findElement(By.xpath("(" + 
(getParagraphXPath(1) + "//select)[1]"))));
       dropDownMenu.selectByVisibleText("Apple");
       collector.checkThat("After selection in drop down menu, output should 
display the new option we selected",
               driver.findElement(By.xpath(getParagraphXPath(1) + 
"//div[contains(@class, 'text plainTextContent')]")).getText(),
@@ -685,7 +685,7 @@ public class ParagraphActionsIT extends AbstractZeppelinIT {
       driver.findElement(By.xpath(getParagraphXPath(1) + 
"//span[@class='icon-settings']")).click();
       clickAndWait(By.xpath(getParagraphXPath(1) + 
"//ul/li/form/input[contains(@ng-checked, 'true')]"));
 
-      Select sameDropDownMenu = new Select(driver.findElement(By.xpath("(" + 
(getParagraphXPath(1) + "//select)[3]"))));
+      Select sameDropDownMenu = new Select(driver.findElement(By.xpath("(" + 
(getParagraphXPath(1) + "//select)[2]"))));
       sameDropDownMenu.selectByVisibleText("Earth");
       waitForParagraph(1, "FINISHED");
       collector.checkThat("After 'Run on selection change' checkbox is 
unchecked, the paragraph should not run if selecting a different option",

http://git-wip-us.apache.org/repos/asf/zeppelin/blob/e20f68be/zeppelin-web/src/app/notebook/paragraph/paragraph.css
----------------------------------------------------------------------
diff --git a/zeppelin-web/src/app/notebook/paragraph/paragraph.css 
b/zeppelin-web/src/app/notebook/paragraph/paragraph.css
index bebea60..8ecc7bb 100644
--- a/zeppelin-web/src/app/notebook/paragraph/paragraph.css
+++ b/zeppelin-web/src/app/notebook/paragraph/paragraph.css
@@ -174,12 +174,19 @@
 }
 
 .paragraph .control {
-  display: inline-block;
+  position: absolute;
   float: right;
   background: rgba(255,255,255,0.85);
   color: #999;
+  margin-top: 1px;
+  margin-right: 5px;
+  position: absolute;
+  clear: both;
+  right: 15px;
+  top: 16px;
+  text-align: right;
   font-size: 12px;
-  margin-top: 5px;
+  padding: 4px;
 }
 
 .paragraph .control li {
@@ -268,11 +275,8 @@ table.table-shortcut {
 */
 
 .paragraph .title {
-  display: inline-block;
-  float: left;
+  margin: 0;
   font-size: 12px;
-  margin-bottom: 7px;
-  min-height: 24px;
 }
 
 .paragraph .title div {

http://git-wip-us.apache.org/repos/asf/zeppelin/blob/e20f68be/zeppelin-web/src/app/notebook/paragraph/paragraph.html
----------------------------------------------------------------------
diff --git a/zeppelin-web/src/app/notebook/paragraph/paragraph.html 
b/zeppelin-web/src/app/notebook/paragraph/paragraph.html
index 367d3e7..0de5e64 100644
--- a/zeppelin-web/src/app/notebook/paragraph/paragraph.html
+++ b/zeppelin-web/src/app/notebook/paragraph/paragraph.html
@@ -15,29 +15,24 @@ limitations under the License.
 <div id="{{paragraph.id}}_container"
      ng-class="{'paragraph': !asIframe, 'paragraphAsIframe': asIframe}">
 
-  <div>
-    <div ng-if="paragraph.config.title"
-         id="{{paragraph.id}}_title"
-         ng-controller="ElasticInputCtrl as input"
-         class="title">
-      <input type="text"
-             pu-elastic-input
-             style="min-width: 400px; max-width: 80%;"
-             placeholder="Untitled"
-             ng-model="paragraph.title"
-             ng-if="input.showEditor"
-             ng-escape="input.showEditor = false; paragraph.title = oldTitle;"
-             ng-blur="setTitle(paragraph); input.showEditor = false"
-             ng-enter="setTitle(paragraph); input.showEditor = false"
-             focus-if="input.showEditor" />
-      <div ng-click="input.showEditor = !asIframe && !viewOnly && 
!revisionView; oldTitle = paragraph.title;"
-           ng-show="!input.showEditor"
-           ng-bind-html="paragraph.title || 'Untitled'">
-      </div>
+  <div ng-if="paragraph.config.title"
+       id="{{paragraph.id}}_title"
+       ng-controller="ElasticInputCtrl as input"
+       class="title">
+    <input type="text"
+           pu-elastic-input
+           style="min-width: 400px; max-width: 80%;"
+           placeholder="Untitled"
+           ng-model="paragraph.title"
+           ng-if="input.showEditor"
+           ng-escape="input.showEditor = false; paragraph.title = oldTitle;"
+           ng-blur="setTitle(paragraph); input.showEditor = false"
+           ng-enter="setTitle(paragraph); input.showEditor = false"
+           focus-if="input.showEditor" />
+    <div ng-click="input.showEditor = !asIframe && !viewOnly && !revisionView; 
oldTitle = paragraph.title;"
+         ng-show="!input.showEditor"
+         ng-bind-html="paragraph.title || 'Untitled'">
     </div>
-
-    <div ng-include 
src="'app/notebook/paragraph/paragraph-control.html'"></div>
-    <div style="display: inline-block; clear: both;"></div>
   </div>
 
   <div>
@@ -68,6 +63,8 @@ limitations under the License.
     </div>
   </div>
 
+  <div ng-include src="'app/notebook/paragraph/paragraph-control.html'"></div>
+
   <div ng-if="!asIframe" class="paragraphFooter">
     <div ng-show="!paragraph.config.tableHide && !viewOnly"
          id="{{paragraph.id}}_executionTime"

Reply via email to