Commit Graph

38 Commits

Author SHA1 Message Date
Beka Westberg
e2eaebec47 fix: convert the Workspace class to an ES6 class (#5977)
* fix: run conversion script on workspace

* fix: cleanup from conversion script

* fix: make debug build happy

* fix: tests

* fix: format

* fix: format
2022-03-16 13:22:03 -07:00
Christopher Allen
da16a66f33 refactor: msg.js: use named export, remove declareLegacyNamespace (#5768) 2021-12-02 16:47:27 +00:00
Rachel Fenichel
8ef0b20146 feat: clarify variable and procedure constants (#5743)
* chore: move dynamic category names into their respective files

* feat: create NameType enum on Names

* chore: use NameType enum for Names helper functions

* docs: update comments for category names
2021-11-30 09:13:36 -08:00
Rachel Fenichel
f14a1c8034 chore: fix more lint (#5676)
* chore: fix assorted lint

* chore: clang-format

* chore: clang-format
2021-11-08 16:41:52 -08:00
Aaron Dodson
3851b14627 refactor: Migrate to named exports (#5623)
* refactor: Migrate to named exports

* fix: Sort requires

* fix: Remove duplicate deps
2021-10-20 15:53:23 -07:00
Neil Fraser
90b3f75d82 Remove @author tags (#5601)
Our files are up to a decade old, and have churned so much, that the initial author of the file no longer has much meaning.

Furthermore, this will encourage developers to post to the developer group, rather than emailing Googlers (usually me) directly.
2021-10-15 09:50:46 -07:00
Monica Kozbial
d8fbe1b05b Add namespace and alias annotations to jsdoc (#5550)
* Add annotations to files under core/events

* Add annotations to files under core/interfaces

* Add annotations to files under core/keyboard_nav

* Add annotations to files under core/renderers

* Add annotations to files under core/serialization

* Add annotations to files under core/theme

* Add annotations to files under core/toolbox

* Add annotations to files under core/utils

* Add annotations to files under core
2021-09-27 14:42:54 -07:00
Christopher Allen
16b6d4526a refactor: Rename Blockly.Blocks, migrate to named exports (#5515)
* Rename Blockly.Blocks to Blockly.blocks
  Because it does not export a type as its default export.

  Part of #5073.

* Name default export of Blockly.blocks Blocks.

  Use named exports in Blockly.blocks by giving the former default
  export the name Blocks.

  Part of #5153.

* Reexport Blockly.blocks from blockly.js

* Document the format of renamings.js better.
2021-09-24 19:12:03 +01:00
Aaron Dodson
e0693a65d2 chore: Remove declareLegacyNamespace() from files in core (#5525)
* chore: Remove declareLegacyNamespace() from files in core

* fix: Update missing/errant re-exports in blockly.js
2021-09-23 14:48:52 -07:00
Aaron Dodson
ad66c531bd clang-format core/variables_dynamic.js 2021-07-30 12:32:38 -07:00
Aaron Dodson
8ded269a15 Migrate core/variables_dynamic.js to named requires 2021-07-30 12:32:01 -07:00
Aaron Dodson
99b8abfeb2 Migrate core/variables_dynamic.js to goog.module 2021-07-30 12:29:15 -07:00
Aaron Dodson
6faf3dbc46 Migrate core/variables_dynamic.js to ES6 const/let 2021-07-30 12:25:50 -07:00
Neil Fraser
d919b0af21 Update JSDoc from Array.<> to Array<>
Same with Object.
2021-05-27 21:30:26 -07:00
Sam El-Husseini
f97730e83c Sort requires (#4658)
* Cleanup gulp method to sort requires
2021-02-25 17:17:42 -08:00
Rachel Fenichel
2360a12493 Fix remaining trivial missing requireTypes 2021-02-19 13:17:14 -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
Neil Fraser
123f436e04 Add parens around inline assignments (#3381) 2019-10-31 15:17:35 -07:00
Sam El-Husseini
90ad0789f6 Fix 11 warnings related to variables and variable_model. (#3278)
* Fix 10 warnings related to variables and variable_model.
2019-10-22 14:26:59 -04: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
6650ecf13f Make dynamic variables be an optional module.
Also straighten out some dependencies.
2019-09-27 10:48:14 -07:00
Neil Fraser
a03660243e Code cleanup, drop some CSS.
Random improvements to require statements.

Removal of some obviously dead CSS.

.blocklyDropDownDiv no longer supresses text selection (see comment in PR).

This PR drops the compiled size by 4 KB, which is larger than I was expecting.
2019-09-25 10:34:34 -07:00
Neil Fraser
0e82677f27 Create stub for Node contstants.
Ironic that Node doesn’t have Node.  Not tested.
Fix two missing dependencies.
2019-07-15 14:37:27 -07:00
Neil Fraser
31a9c02362 Stop generating dynamic XML from text.
Removes last goog.string reference.
2019-07-15 14:37: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
9f528922a7 Fix some dependencies 2019-05-24 15:45:05 -07:00
Beka Westberg
863786eb06 Changed for dynamic variables as well. 2019-02-11 15:34:36 -08:00
Neil Fraser
db0dbc69ee Update todos and requires. 2018-10-16 11:34:10 -07:00
Neil Fraser
aa09ad9175 Line wrap at 80. 2018-10-16 11:34:10 -07:00
Neil Fraser
e62bb1af73 Remove all calls to goog.dom.createDom
All XML node cereations are now centralized.
2018-10-16 11:34:10 -07:00
Neil Fraser
c51cf0b79c Remove goog.dom.removeNode 2018-07-11 12:20:02 -07:00
Neil Fraser
03bf9f5e71 Remove goog.string 2018-07-11 12:20:02 -07:00
Neil Fraser
4cb4b42f8d Use named properties on Msg. 2018-04-27 11:50:51 -07:00
Rachel Fenichel
23666664fa Fix context menus on blocks with variables 2018-04-12 16:56:07 -07:00
Andrew n marshall
36993430e1 createVariable(..) => createVariableButtonHandler(..)
Clarifying the role of Blockly.Variables.createVariableButtonHandler(..).
Updating documentation a making sure it (and its deprecated previous name)
are properly exported.
2018-01-24 09:54:21 -08:00
Neil Fraser
7413db1089 Code style 2018-01-05 15:56:20 -08:00
RoboErikG
0142aa0e94 Don't require flyouts to run Blockly (#1502)
* Don't require flyouts to run Blockly

There was a bug with Dynamic Variables that made them required for Blockly
to run. This adds checks so that the flyouts only get registered if they're
included. Also does a rebuild of core to pick up the fix.

* Also fix dependencies so dynamic vars don't get stripped
2017-12-08 14:18:09 -08:00
Tianwei Du
492462e1d4 Develop (#1481)
* variables_dynamic

* make test , and i18n

* Issue #1470

* Blockly.Constants.VariablesDynamic.CUSTOM_CONTEXT_MENU_VARIABLE_MUTATION
to make sure setCheck before event trigger

* Update built files from develop.

* fix copyright ,quotes , comments ,  and optimize some flow.

* quotes,change UI , change category custom name

* single setter , remove mutator , colour typo , typed variables create button message

* undo the indent edits.
2017-12-08 08:53:24 -08:00