Sam El-Husseini
eb40ca44ba
Dynamic fonts ( #3698 )
...
* Piping themes into the renderer and ensuring fields update their size information when constants change.
2020-02-20 17:16:01 -08:00
Neil Fraser
4e2f8e6e02
Use SPDX licences.
...
This is a followup to #3127 .
At the time, SPDX licenses were pending approval by Google.
2020-02-11 13:27:20 -08:00
Sam El-Husseini
f6b5e9ebb4
Add test block for field image with a click handler ( #3642 )
2020-01-23 16:19:24 -08:00
Sam El-Husseini
986e965be8
Private/protected visibility cleanup ( #3263 )
...
* Fix a number of private visibility issues
2019-10-16 11:48:09 -05:00
Sam El-Husseini
2224bb2a4e
More field dispose ( #3201 )
...
* Dispose of element references in fields.
* Fewer warnings
2019-10-15 17:56:53 -05:00
Sam El-Husseini
d0772ad496
Fix compiler warnings related to fields. ( #3144 )
...
* Fix compiler warnings related to fields.
2019-10-03 15:58:46 -07:00
Neil Fraser
b46a4fe286
Bring our license format up to date ( #3127 )
...
* Google changed from an Inc to an LLC.
This happened back in 2017 but we didn’t notice. Officially we should update files from Inc to LLC when they are changed as part of regular edits, but this is a nightmare to remember for the next decade.
* Remove project description/titles from licenses
This is no longer part of Google’s header requirements. Our existing descriptions were useless (“Visual Blocks Editor”) or grossly obselete (“Visual Blocks Language”).
* License no longer requires URL.
* Fix license regexps.
2019-10-02 14:46:56 -07:00
Sam El-Husseini
a57c7ffb13
Clean up fields by passing the right type in fromJson ( #3095 )
2019-09-26 12:03:17 -07:00
Sam El-Husseini
8fae0411f7
Check if a type exists before testing instanceof ( #3031 )
...
* Check if a type exists before instance of
2019-09-17 16:28:18 -07:00
Beka Westberg
b149aabd16
Image Field Config ( #2983 )
...
* Added image field configuration.
2019-09-16 11:05:32 -07:00
Sam El-Husseini
f3f3329355
Fix configure method ( #2915 )
...
* Fix configure method.
2019-09-12 17:01:03 -07:00
Sam El-Husseini
8ab51c8639
Remove closure base file dependency ( #2976 )
...
* Trim down closure's base dependency even further by removing the dependency on closure's base file.
2019-09-11 17:30:51 -07:00
Sam El-Husseini
f23b659898
Remove this.text_ ( #2910 )
...
* Remove this.text_ and have every field handle its own properties.
2019-08-26 10:56:36 -07:00
Beka Westberg
0872d022e1
Changed utils.fields -> fieldRegistry. Also removed useless tooltip requires.
2019-08-16 09:57:28 -07:00
Beka Westberg
cdc90f4059
Refactored field utilities.
2019-08-16 09:57:27 -07:00
Rachel Fenichel
ed245a3c9e
Remove dealWithOffsetFields
2019-08-06 11:44:03 -07:00
Rachel Fenichel
c6463acc70
Cleanup and comments
2019-08-06 11:03:53 -07:00
Rachel Fenichel
3802a0c960
Remove getCorrectedSize for fields
2019-08-05 16:01:50 -07:00
Neil Fraser
45e5fb4157
More JSDoc and lint corrections
2019-07-30 17:00:40 -07:00
Sam El-Husseini
57868e7e83
Remove all calls to goog.math ( #2739 )
...
* Replace calls to goog.math.Size and goog.math.Coordinate with Blockly equivelants
2019-07-30 11:22:08 -07:00
Sam El-Husseini
4c626e7b76
Fix setOnClickHandler jsdoc casing ( #2730 )
2019-07-29 15:29:06 -07:00
Rachel Fenichel
08982ce55e
Merge pull request #2668 from BeksOmega/fixes/DeprecateSetText
...
Deprecated Field.setText
2019-07-26 13:02:35 -07:00
Sam El-Husseini
c1b49a1da7
Fix some jsdoc types ( #2701 )
...
* Fix JSDoc regarding type inconsistencies. Make image field src required and update image field tests.
2019-07-25 12:24:36 -07:00
Rachel Fenichel
5ab6977c89
Merge branch 'develop' into feature/SetOnClickImage
2019-07-24 14:23:54 -07:00
Rachel Fenichel
fc4372dbc2
Add TODOs with github issue number
2019-07-22 16:29:44 -07:00
Beka Westberg
ed41b7f900
Added a setOnClickHandler function to the image field.
2019-07-19 09:17:09 -07:00
Beka Westberg
20837da54f
Deprecated field setText function.
2019-07-19 08:57:34 -07:00
Rachel Fenichel
f469a388ed
Add getCorrectedSize functions to fields
2019-07-17 11:00:20 -07:00
Beka Westberg
303115953e
Moved to #2125 disposal. Cleaned up some doc.
2019-06-11 13:32:09 -07:00
Beka Westberg
0122f36450
Fixed field disposal, and reorganized editor creation.
2019-06-11 13:30:50 -07:00
Neil Fraser
98a98bcce6
Add Blockly.utils.dom.XLINK_NS
...
And fix provide/require mixup.
2019-06-07 10:32:57 -07:00
Neil Fraser
848d3a3509
Move setCssTransform & createSvgElement to dom.
...
Also move SVG_NS and HTML_NS properties.
2019-06-07 10:32:57 -07:00
Neil Fraser
d1a29739d8
Move utilities into own directory.
...
TODO: There are more functions which may be migrated into dom and string.
2019-06-07 10:32:57 -07:00
Beka Westberg
f0d6fbd192
Reorganized field view initialization.
2019-05-31 10:38:18 -07:00
Beka Westberg
e1e746b845
Fixed how fields handle size.
2019-05-31 07:32:43 -07:00
Neil Fraser
9f528922a7
Fix some dependencies
2019-05-24 15:45:05 -07:00
Beka Westberg
f16c9c0beb
Refactored field validation.
2019-05-24 14:23:42 -07:00
Beka Westberg
acd96aa2c5
Added Field Value Tests ( #2459 )
...
* Added field value tests.
* Fixed field image src param.
* Fixed falsy values with label fields.
* Fixed falsy values with text input fields.
* Fixed some angle field tests.
* Fixed other text input when editing tests.
* Fixed colour tests.
* Cleaned up some number and variable field tests.
* Added angle field > 360 degrees tests.
* Fixed variable validator tests.
* Split setValue tests into sub-suites.
* Fixed angle >360 tests
* Changed var declarations to property declarations.
2019-05-17 15:19:14 -07:00
Beka Westberg
354d402c49
Refactored field.init into field.initView and field.initModel
2019-05-03 07:12:46 -07:00
Beka Westberg
e8573bc0db
Added isSerializable function and SERIALIZABLE property to fields.
2019-04-21 08:28:37 -07:00
Neil Fraser
e9de083361
Fix @return JSDocs.
2019-03-29 15:24:37 -07:00
Beka Westberg
969687ec34
Added flipRtl Support for FieldImages ( #2203 )
...
* Added flipRtl support for FieldImages. Added a flipRtl test block.
* Added blockfactory support.
* Fixed JSDoc.
2019-01-10 08:59:35 -08:00
Sandeep Dubey
b5146036e1
Fix #1632 : Added alt attribute to the field image. ( #2178 )
...
* Added alt for field image.
* Removed lint issues.
2018-12-18 13:38:53 -08:00
Rachel Fenichel
3aa0cac22b
Fix setting tooltips in init
2018-10-17 13:27:32 -07:00
duzc2dtw@gmail.com
c92a4f31f5
fix #1887
2018-09-11 00:57:52 +08:00
Andrew n marshall
411ec9724e
Replacing node.parentNode.removeChild(node)
...
...with Blockly.utils.removeNode(..), which includes
a null/undefined check on parentNode before continuing.
2018-09-04 13:31:53 -07:00
Neil Fraser
c51cf0b79c
Remove goog.dom.removeNode
2018-07-11 12:20:02 -07:00
Neil Fraser
284b79407e
Require Blockly.utils where needed.
2018-07-11 12:20:02 -07:00
Neil Fraser
1d385f8d69
Require goog.userAgent in the correct files.
2018-04-11 16:59:35 -07:00
Rachel Fenichel
615c403b44
Use @nocompress annotation to fix advanced compilation.
2018-03-01 12:35:55 -08:00