Commit Graph

15 Commits

Author SHA1 Message Date
marisaleung 12ea998155 Created separate file for VariableMap 2017-05-03 17:04:15 -07:00
marisaleung 9577e5ddc4 Created a variable model with name, id, and type.
Created a jsunit test file for variable model.
2017-04-20 13:19:53 -07:00
Andrew n marshall 6b692a0802 Initial text block, with a mixin to generate quote image fields. (#923)
Text block now uses the extension "text_quotes", supported by Blockly.Constants.Text.QUOTE_IMAGE_MIXIN.quoteField_(fieldName), so that each platform can use the best platform appropriate image (size, density, etc.) for the quotes.
2017-02-13 15:00:02 -08:00
Rachel Fenichel 630863d9db Add isEditable to field, and add tests 2017-02-06 14:47:45 -08:00
Andrew n marshall fb0f1b05dd Unit tests for JSON block definitions (just the start) (#850)
* Beginnings of a JSON block definition unit test set.
 * Dispose of unit test workspaces and blocks in finally blocks.
 * Clarify JSON error message by echoing arg notation.
2017-01-20 14:18:33 -08:00
Andrew n marshall a47bd93f4c Adding extensions for JSON support of dynamic blocks. (#834)
Adding support for extensions, functions that can assist with loading blocks, much like init functions, but that can be referenced from JSON definitions. This allows JSON definitions to define dynamic blocks such as onchange handlers and mutators.

Rewrote math_number as an example pure JSON block.
2017-01-18 12:45:39 -08:00
Andrew n marshall 211d973054 FieldNumber & FieldAngle: Default value "0" (#832)
FieldNumber and FieldAngle previously accepted "undefined" as values, if not defined in JSON. This catches these and uses "0" for any NaN value.  The constructor value parameter is now optional. Includes tests.
2017-01-17 15:39:59 -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
Neil Fraser 99f332f749 Fix getBlockById unit test. Issue #323 2016-04-07 14:35:01 -07:00
Rachel Fenichel 9263e28263 Add tests for connection logic 2016-02-25 15:16:32 -08:00
Neil Fraser 3b3ef79fbd Create block id database. 2015-12-09 10:02:42 +01:00
Neil Fraser d702808f71 Add UUID generator. 2015-11-19 01:46:53 -08:00
Neil Fraser 6cc26f07ac Adding unit tests for workspace. 2015-01-11 14:18:50 -08:00
Neil Fraser a8414a0ecb Remove unneeded HTML attributes (Google style guide). 2014-12-02 18:22:46 -08:00
Neil Fraser 1467f746f6 Add XML unit tests. 2014-11-25 15:57:31 -08:00