From 37fae54a5957238a078b335a47c5ebaab3066005 Mon Sep 17 00:00:00 2001 From: Tina Quach Date: Mon, 22 Aug 2016 17:45:28 -0700 Subject: [PATCH] Block Factory: Nit UI Changes (#570) * switch block factory buttons, clarify exporter helper text,rename block selector * add space between navigation bar and content. hide toolbox content. * nit space * moved helper text out of the columns and moved currently selected blocks into export settings --- demos/blocklyfactory/block_exporter_view.js | 4 +-- demos/blocklyfactory/factory.css | 24 ++++++++++--- demos/blocklyfactory/index.html | 40 ++++++++++----------- 3 files changed, 40 insertions(+), 28 deletions(-) diff --git a/demos/blocklyfactory/block_exporter_view.js b/demos/blocklyfactory/block_exporter_view.js index ba6799036..c4297d77e 100644 --- a/demos/blocklyfactory/block_exporter_view.js +++ b/demos/blocklyfactory/block_exporter_view.js @@ -103,8 +103,8 @@ BlockExporterView.prototype.updateHelperText = function(newText, opt_append) { * @param {!Array.} selectedBlockTypes - Array of blocks selected in workspace. */ BlockExporterView.prototype.listSelectedBlocks = function(selectedBlockTypes) { - var selectedBlocksText = selectedBlockTypes.join(', '); - this.updateHelperText('Currently Selected: ' + selectedBlocksText); + var selectedBlocksText = selectedBlockTypes.join(",\n "); + goog.dom.getElement('selectedBlocksText').textContent = selectedBlocksText; }; /** diff --git a/demos/blocklyfactory/factory.css b/demos/blocklyfactory/factory.css index b49958ece..96736febd 100644 --- a/demos/blocklyfactory/factory.css +++ b/demos/blocklyfactory/factory.css @@ -164,7 +164,7 @@ button, .buttonStyle { visibility: hidden; } -#toolbox { +.toolbox { display: none; } @@ -191,7 +191,7 @@ button, .buttonStyle { #exportSelector { display: inline-block; float: left; - height: 75%; + height: 60%; width: 30%; } @@ -199,7 +199,23 @@ button, .buttonStyle { float: left; overflow: hidden; padding-left: 16px; - width: 30%; + width: 20%; +} + +#selectedBlocksTextContainer { + max-height: 200px; + overflow-y: scroll; + padding-bottom: 2em; +} + +::-webkit-scrollbar { + -webkit-appearance: none; + width: 7px; +} +::-webkit-scrollbar-thumb { + border-radius: 4px; + background-color: #ccc; + -webkit-box-shadow: 0 0 1px rgba(255,255,255,.5); } #exporterHiddenWorkspace { @@ -415,5 +431,3 @@ td { .shadowBlock>.blocklyPathDark { display: none; } - ->>>>>>> Starting to integrate workspacefactory diff --git a/demos/blocklyfactory/index.html b/demos/blocklyfactory/index.html index 9f5841292..4beb7f029 100644 --- a/demos/blocklyfactory/index.html +++ b/demos/blocklyfactory/index.html @@ -53,20 +53,22 @@
Exporter
-
+
+

First, select blocks from your block library by dragging them into your workspace. Then, use the Export Settings form to download starter code for selected blocks. +

+

Block Selector

-

Drag blocks into your workspace to select them for download.

-
@@ -75,19 +77,14 @@
+

Export Settings


- Toolbox Xml: - -
- Pre-loaded Workspace: - -
- Workspace Option(s): - -
-
+
+

Currently Selected:

+

+
Block Definition(s):
Language code: @@ -115,6 +112,7 @@
+

Preview Workspace:

@@ -268,8 +266,8 @@ - @@ -293,8 +291,8 @@ -