Commit Graph

279 Commits

Author SHA1 Message Date
Andrew n marshall
1956baa963 BlockFactory: Adding JSON/JavaScript import support (#1235)
Updates the BlockFactory main workspace based on the preview block generated from manual construction.

This is a continuation of PR #1216 by @JC-Orozco, rebased on latest develop branch. Bring it latest code up to Google styling and standards.
2017-08-17 12:40:58 -07:00
Tom
a6245f4c6e Compile messages with externs and demo with advanced optimizations (#1259)
* Revert "Fix synonyms when compiled. (#1248)"

This reverts commit f08afbb351.

* Revert "Compatibility for Closure Compiler. (#1240)" [fc8d4c9]

* Adding exports to all messages.

* Fixed missing dependency to Blockly.defineBlocksWithJsonArray()

* Adding a fully compiled demo draft (still simple optimizations).

* Demo optimizations switched to advanced and enabled exports (for Blockly.Msg).

* Message interpolation updated to use the exported (global) Blockly.Msg array.

* Adding some debug compilation options to the build script.

* Adding SVG externs.

* Fixed Blockly.inject's config array to work with compilation.

* Reverting all compiled code.

This fixes commit b307ba1151.
This fixes commit dec6910b67.

* Reverting all compiled code.

This fixes commit 824c806ec3.

* Removing old todo

* Merge commit 'fe96bec765f0eb58c5321101965100c2716760ed' into compile-messages-with-externs

* commit 'fe96bec765f0eb58c5321101965100c2716760ed':
  Fixes positional index for Czech translation (#1264)
  Missed one use of string instead of .property in extensions.js (#1262)
  Update extensions.js to be compatible with ADVANCED_OPTIMIZATIONS (#1253)
  Fix type tags and todo placement.
  Procedure block renames variable in mutator if there is a case change.

* Fixes based on review by @NeilFraser
- 80 cols
- using goog.global instead of window
- @export on the same line as messages

* BF: Moving the msg dependency earlier, since Blockly.Msg.en is filling the Blockly.Msg object, which is empty without Blockly.Msg.en (and the rest of the code is using it as Blockly.Msg).

* Updating some texts in the demo's html file to be more descriptive.

* Commenting the debug options in the build, to maximize the optimizations. They are not removed, to allow anybody to turn them on if needed (since they are not documented on the Closure Compiler's REST API pages).

* BF: fixed blocks_compressed.js compilation, as it now requires Blockly namespace to exist.

* SVG externs file updated based on the one in https://github.com/google/closure-compiler/blob/master/contrib/externs/svg.js (eliminating 2 warnings)
2017-08-08 11:16:49 -07:00
marisaleung
103c10eddb Change workspace name to playgroundWorkspace. 2017-08-02 17:03:22 -07:00
Andrew n marshall
abcc9b82a1 Adding BlocklyDevTools.Analytics (#1217)
Adding BlocklyDevTools.Analytics, an interface for integrating an analytics
library to track basic usage, including:
 * navigation.
 * saving, importing, and exporting.
 * warnings and errors.
2017-07-11 15:39:35 -07:00
CoryDCode
668d220faa Fixing an error with block messages and ordering. (#1171) 2017-06-20 12:55:27 -07:00
marisaleung
aff9c4867c Correctly named block events called. 2017-06-08 15:44:43 -07:00
CoryDCode
e2ee3aa9c9 Setting up accessible Blockly for Closure compilation. (#1134)
Moving closure compilation into the build file.

Fixing up goog.requires for accessible blockly. Adding accessible to the build script.
2017-05-26 10:43:02 -07:00
Andrew n marshall
10ad450176 Forgot update code demo (#1121) 2017-05-22 12:34:22 -07:00
Andrew n marshall
3840b3804f Replacing latest prettifier hosted in repo with latest version at rawgit CDN. (#1120) 2017-05-22 12:09:23 -07:00
Rachel Fenichel
65908e8874 Spelling. Spelling is hard. 2017-05-19 16:31:12 -07:00
Rachel Fenichel
7395c24bf0 Fix apostrophe in tooltips and helpurls (#1111) 2017-05-19 16:14:53 -07:00
Andrew n marshall
fb020f1c06 New jsinterpreter demo includes wait block. Both demos have improved UI for clarity. (#1001)
Refactor of interpreter demo
 * Renamed demos/interpreter/index.html as demos/interpreter/step-execution.html (including redirect), and added demos/interpreter/async-execution.html.
 * Refactored code to automatically generate/parse the blocks, eliminating the need for a "Parse JavaScript" button. Code is still shown in alert upon stepping to the first statement. Print statements now write to output <textarea> instead of modal dialogs.
2017-05-01 17:28:34 -07:00
Rachel Fenichel
db26c4c541 use goog.string.startswith instead of string.startswith (#1065) 2017-04-25 14:12:21 -07:00
vicng
ae2aaa2159 - Allows use of Blockly's messaging format for category name, colour,… (#1028)
...in toolbox XML.
- Updated code editor demo to use this message format
- Re-built blockly_compressed.js
2017-04-07 15:32:50 -07:00
CoryDCode
33355415df Adding the common modal class. (#1017)
Centralizes accessible modal behavior.
2017-04-05 16:06:45 -07:00
CoryDCode
8e199ec04b Adding an add variable modal to accessible Blockly. (#1015)
* Adding the remove variable modal and functionality to accessible Blockly.

* Adding the add variable modal for accessible Blockly.
2017-04-03 16:16:50 -07:00
Rachel Fenichel
1ad3359730 Merge pull request #965 from K-ran/feature/minimap
Adding new minimap demo.
2017-04-03 11:30:49 -07:00
Karan Purohit
619237c05d Minimap position bug fix for browsers other than chrome. Added touch support. 2017-04-02 13:31:46 +05:30
CoryDCode
537bf17b7d Adding the remove variable modal and functionality to accessible Blockly. (#1011) 2017-03-30 11:31:31 -07:00
CoryDCode
6cc6848961 Added the variable modal and component and implemented basic renaming functionality. (#991) 2017-03-23 13:47:26 -07:00
Karan Purohit
ac18e207a2 Registering mousemove and mouseup listener in mousedown event. Mousemove and Mouseup events are now listening over document. 2017-03-14 08:58:03 +05:30
Karan Purohit
4e9055a343 Adding horizontal scrolling. Changed scroll change callbacks from onScroll_ to setHandlePosition. onScroll_ is not challed when workspace is dragged. 2017-03-12 15:29:05 +05:30
Karan Purohit
f77325f289 Basic code style changes. Adding a few more comments. Return early if disableScrollChange in onScrollChange listener. 2017-03-08 10:17:38 +05:30
Karan Purohit
738d5d6669 Adding new minimap demo 2017-03-08 00:12:22 +05:30
Andrew n marshall
7e178af49c Fix #950: BlockFactory typo and copypasta 2017-02-23 08:53:01 -08:00
Sean Lip
4bef8cc329 Rename workspace-tree to workspace-block. 2017-01-17 13:32:33 -08:00
Rachel Fenichel
2867a3a85d Naming changes in mirror demo 2017-01-12 16:27:37 -08:00
picklesrus
bdc5a02922 Fix #698 by adjusting the regex to not have \. Still not 100% sure w… (#700)
* Fix #698 by adjusting the regex to not have \.  Still not 100% sure why that was there.
Also replaces bad names on input.  There are probably more invalid names but this is
a start.
2016-12-09 17:19:17 -08:00
picklesrus
ccbaa4664e remove overflow-y on the block exporter labels so scroll bars do not show upin firefox. Also fix up the styles on the labels so that they display better in firefox. (#699) 2016-12-09 16:34:33 -08:00
Sean Lip
30a4a1930f Fix issue with aria-liveregion not speaking. Allow sufficient time for alert noise to play before speaking the notification. 2016-12-08 19:55:42 -08:00
Rachel Fenichel
99c30007a7 Generate helpURL and tooltip for Javascript block definition 2016-12-08 14:41:40 -08:00
Rachel Fenichel
4871ff9fda Start getting helpurl and tooltip in 2016-12-08 14:26:53 -08:00
Rachel Fenichel
1d55e28610 Add colour block to the block factory base block initial state 2016-12-08 14:26:53 -08:00
Rachel Fenichel
17258990fd fix missing semicolon 2016-12-05 16:11:59 -08:00
Sean Lip
10efda6d9c Refactor and simplify marked spot logic. 2016-11-30 16:45:06 -08:00
Sean Lip
69d4ebb6dd Improve styling of sidebar buttons. 2016-11-29 19:01:34 -08:00
Sean Lip
4e623631dd Update config options for sidebar buttons. 2016-11-29 18:24:50 -08:00
Sean Lip
89e9f370b7 Add information regarding target screen reader and browser. 2016-11-28 16:37:12 -08:00
Sean Lip
5c79d2f36f When the workspace is empty, make it easy for the user to add a new group of blocks to it. 2016-11-22 15:53:45 -08:00
Neil Fraser
fbd9276e9c Lint 2016-11-18 20:26:56 -08:00
Sean Lip
602c1ba56e Delete the on-screen toolbox. 2016-11-17 17:45:12 -08:00
Sean Lip
6ab1244560 Add a contextual modal for the toolbox. 2016-11-17 15:58:23 -08:00
Sean Lip
a027ec8573 Move away from using a common modal service, since the block options and the toolbox modals are going to end up behaving fairly differently. 2016-11-16 16:47:26 -08:00
Sean Lip
25588fc7bd Break the sidebar out into its own individual component. 2016-11-15 17:19:01 -08:00
Neil Fraser
f6aef459fc API-breaking cleanup. But doubtful anyone will be affected. (#748)
* Make add/removeClass return whether they did anything.
* Move more functions onto utils.
* Move bind functions to Blockly.
* Routine recompile.
2016-11-15 13:54:33 -08:00
Rachel Fenichel
1f67654088 Merge pull request #736 from google/fraser-develop
Allow images in dropdown menus.
2016-11-15 13:07:46 -08:00
Sean Lip
b1109f47f0 Add correct focus behavior for the modal. Update boundary sounds. 2016-11-14 18:31:36 -08:00
Neil Fraser
98c341bcfb Allow images in dropdown menus. 2016-11-05 00:17:07 -07:00
Neil Fraser
5b033e2f7b Misc cleanup. 2016-11-05 00:15:39 -07:00
Andrew n marshall
52ffc64f6a Refactor variable rename to handle UI actions more directly. (#726)
FieldDropdown now has onItemSelected(..) method to handle the menu item selection action. Variable renames and deletes are now handled here, instead of during validation.

Also fixes an issue deleting variables used by less than two blocks.

Fixes #723.
2016-11-01 16:32:10 -07:00