Rachel Fenichel
615c403b44
Use @nocompress annotation to fix advanced compilation.
2018-03-01 12:35:55 -08:00
Mark Gibson
54f0e06e21
Customising field types using a register of fields #1584 ( #1594 )
...
Implement #1584 - Fields now registered by their JSON type name, allowing new custom fields and overriding of the standard fields. Replaces the manual switch statement for loading fields from JSON block definitions.
2018-02-14 10:14:59 -08:00
Mark Gibson
2308ae8c22
Remove underscore from fromJson_
2018-02-07 18:18:35 +00:00
Mark Gibson
d40ef474ae
See issue #1486 - adds fromJson_ fn to every Blockly.Field, removing Block.newField*FromJson_ helpers
2018-02-07 12:22:26 +00:00
Neil Fraser
4262b09002
Resolve 106 warnings.
2017-10-24 14:06:29 -07:00
Rachel Fenichel
4152542c2f
Fix some lint errors
2017-02-03 14:01:18 -08:00
Andrew n marshall
bf16f11dbd
Replace single quotes with double. ( #836 )
...
Fixes commits in #832 .
2017-01-18 09:24:29 -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
Rachel Fenichel
a74acd942e
Use isFinite instead of Number.isFinite
2016-08-19 15:04:07 -07:00
Neil Fraser
5c2c4d8400
Refactor validators to survive aggressive Closure compression.
2016-07-15 20:59:20 -07:00
Neil Fraser
8c48436c8f
Fix validation on number field.
2016-07-15 20:06:01 -07:00
Neil Fraser
efc2ca3d82
Add field_number to Block Factory.
2016-07-10 22:54:57 -07:00
Neil Fraser
555eac8b7f
Simplify field validator chaining.
2016-06-29 17:44:12 -07:00
Neil Fraser
0be0cc89c7
Second version of FieldNumber API.
2016-06-22 15:07:07 -07:00
Neil Fraser
732e9b0659
Start using field_number.
2016-06-21 04:10:32 -07:00
Rachel Fenichel
9a1f98b703
use correct class name
2016-05-05 12:31:22 -07:00
Rachel Fenichel
d89d8a2113
Add lightweight field_number
2016-05-04 13:30:18 -07:00