Monica Kozbial
40ef586260
Refactoring Ui events in core ( #4418 )
...
* Ui events base (#4370 )
* Add constants for new ui event types
* Add property to indicate an event as UI event
* Click events (#4372 )
* Creating new ui base class.
* Refactor theme event (#4391 )
* Add themeName property to theme event
* Refactor marker move events. (#4389 )
* Refactor trashcan open event (#4392 )
* Refactor selected event (#4387 )
* Refactor toolbox item change event (#4394 )
* Refactor bubble open events (#4390 )
* Refactor block drag event (#4388 )
* Viewport events (#4395 )
* Fix event filtering for ui events (#4401 )
* Move events to new directory and rename Ui events base (#4400 )
* Move events to new directory and rename Ui events base
* Add missing fromJson implementation for click event (#4410 )
* Adding serialization tests for events
* Zoom controls event (#4407 )
* Refactor zoom event
* Rename IS_UI_EVENT to isUiEvent
2020-11-04 14:43:54 -08:00
Sam El-Husseini
fba35d342c
Add missing require Blockly.constants ( #4366 )
2020-10-12 17:56:42 -04:00
alschmiedt
3969f3129f
Fix bug in trashcan ( #4306 )
2020-09-22 16:35:22 -07:00
Sam El-Husseini
db40e44b7c
Move Blockly.utils.dom.SvgElementType to Blockly.utils.Svg ( #4285 )
...
* Move SVGElementType to its own file shaving off 2.7KB
2020-09-16 14:42:58 -07:00
Maribeth Bottorff
f6688d0339
Convert toolbox position to enum ( #4284 )
...
Convert toolbox position to enum
2020-09-16 10:54:17 -07:00
alschmiedt
22d598484f
Update blockToDom types to include document fragments ( #4280 )
2020-09-16 10:51:09 -07:00
Monica Kozbial
12b5658109
Rename trashcan api calls for open/close lid. ( #4110 )
...
* Rename trashcan api calls for open/close lid.
* Update comments.
2020-08-05 12:25:35 -07:00
alschmiedt
0f00f42580
Adds Ability to Add a Flyout as a Plugin ( #4059 )
2020-07-22 17:13:19 -07:00
Monica Kozbial
26993a120f
Emitting event on trashcan close. ( #4056 )
...
* Emitting event on trashcan close.
2020-07-21 13:14:29 -07:00
Sam El-Husseini
0f3db47fa5
Use generics to derive SVG element type ( #4036 )
...
* Encapsulate type in a generic to automatically derive type of SVG element when using createSvgElement
2020-07-13 10:40:31 -07:00
Monica Kozbial
d3b8b78035
Update click event handling for workspace and trashcan. ( #4024 )
...
* Update click event handling for workspace and trashcan.
* Fix typo
* Change event name for trashcan flyout open
2020-07-10 13:23:08 -07:00
alschmiedt
6bc60894db
Toolbox interface ( #3918 )
...
* Add toolbox interface
2020-05-27 10:06:18 -07:00
Sam El-Husseini
13ac939b91
Support passing renderer overrides in options ( #3734 )
...
* Support passing in renderer options through workspace options.
2020-03-10 18:36:29 -07: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
Beka Westberg
4416be2a30
Added const tags and fixed visibility.
2020-02-07 13:34:09 -08:00
Beka Westberg
b0cd803211
Added empty trashcan function.
2020-01-31 13:15:03 -08:00
Beka Westberg
c02f703629
Added constants to animation code.
2020-01-31 13:14:39 -08:00
Sam El-Husseini
70f42b3395
Fix parsing and passing of workspace options around Blockly ( #3616 )
2020-01-21 13:29:03 -08:00
Monica Kozbial
c84ee46a89
Setting default options in workspace constructor. ( #3592 )
...
* Setting default options in workspace constructor.
* Changing logic for parsing workspace options.
* Adding gridPattern declaration to options and updating options handling for workspace.
* Addressing PR comments.
* Moving objects to constructor.
* Using constructor instead of casting for Blockly.Options.
* fix eslint
* Adding types.
* Change in type.
* eslint fix.
* Fix typings.
2020-01-17 15:16:20 -08:00
Rachel Fenichel
13e4d671c3
Moved setHighlighted and setDisabled into the path object.
2019-11-01 14:28:51 -07:00
Neil Fraser
123f436e04
Add parens around inline assignments ( #3381 )
2019-10-31 15:17:35 -07:00
Sam El-Husseini
bfe62f98ca
Dispose makes the types we use inconsistent. Suppress checkTypes in dispose. ( #3336 )
2019-10-24 15:47:42 -04:00
Sam El-Husseini
4f02ceeba0
Make Blockly options an interface ( #3312 )
...
* Make workspace options an interface so it can be extended in the d.ts.
2019-10-22 14:20:26 -04:00
Sam El-Husseini
3c2c4677df
Fix 55 warnings related to flyouts. ( #3211 )
...
* Fix 55 warnings related to flyouts.
2019-10-16 12:13:37 -05:00
Beka Westberg
8f73fdb512
Fixed comments in trashcan.
2019-10-15 13:02:02 -07:00
Beka Westberg
b2a8172720
Fixed disabled blocks in trashcan.
2019-10-15 13:02:02 -07:00
Rachel Fenichel
79c2fa6688
Make trashcan setOpen package and update a few annotations.
2019-10-03 18:08:27 -07:00
Rachel Fenichel
79bedca5a7
Element -> SVGElement ( #3140 )
...
* Use SVGElement instead of Element for the results of createSvgElement
* More SVGElement annotations.
2019-10-02 16:12:31 -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
Neil Fraser
b701475984
Simplify trashcan code ( #3110 )
...
Also delete unused props in CSS.
2019-09-27 11:43:56 -07:00
Neil Fraser
6650ecf13f
Make dynamic variables be an optional module.
...
Also straighten out some dependencies.
2019-09-27 10:48:14 -07:00
Neil Fraser
6e76b6f49e
Make flyout buttons be an optional module.
2019-09-24 10:58:33 -07:00
Neil Fraser
ddb8e46b87
Make flyouts be optional modules.
...
No Blockly instances need both Horizontal and Vertical flyouts. Dropping one of these saves 2 KB. Some don’t need flyouts at all (e.g. Blockly Games Puzzle or readonly documentation blocks).
2019-09-23 22:02:59 -07:00
Neil Fraser
56e7a46f45
Add more missing dependencies
...
Submitted without review. From this bug:
https://github.com/google/blockly-games/issues/116
2019-09-21 08:48:27 -07:00
Sam El-Husseini
fc420b7037
Support for registering renderers and switching between them ( #3013 )
...
* Added support for registering renderers and for choosing which renderer the workspace wants to use.
2019-09-13 10:30:20 -07:00
Rachel Fenichel
16f0992764
Enable operator-linebreak rule
2019-07-31 09:45:27 -07:00
Beka Westberg
5a4cc7ae12
Removed textToDom Needing <xml> Documents ( #2585 )
...
* Removed textToDom needing <xml> documents.
* Fixed jsdoc.
* Followon changes resulting from lack of XML tag.
* Fix Mocha test.
2019-06-24 15:50:06 -07:00
Neil Fraser
6947010c49
Change Rect to use top/bottom/left/right
...
Instead of top/left/height/width. Given our uses of Rect, it makes the math slightly simpler.
This is a setup for using Rect in other places. Currently it is only used to describe delete areas.
2019-06-07 10:32:57 -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
Neil Fraser
f2c57dea1b
Remove goog.math.Rect dependency
2019-06-07 10:32:57 -07:00
Beka Westberg
985bf3af3b
Fixed how the trashcan handled shadow blocks. ( #2545 )
2019-06-05 09:53:56 -07:00
Neil Fraser
9f528922a7
Fix some dependencies
2019-05-24 15:45:05 -07:00
Neil Fraser
f118d33855
Corrections to JSDoc comments
2019-03-29 15:24:37 -07:00
Neil Fraser
e9de083361
Fix @return JSDocs.
2019-03-29 15:24:37 -07:00
Neil Fraser
405b1e4e78
Lint issues found while debugging.
2019-03-27 15:47:29 -07:00
Beka Westberg
772c501ac3
Fixed multiple trashcans on the same page leaking state.
2019-02-12 13:55:37 -08:00
Beka Westberg
4f51ea222c
Changed the trashcan lid to always open towards the workspace.
2019-01-28 18:04:37 -08:00
Rachel Fenichel
8fc4ea19ed
Merge pull request #2241 from BeksOmega/fixes/DisabledContentsBlocks
...
RetrieveDisabled Blocks from the Trashcan
2019-01-28 16:47:53 -08:00